If you want to become pretty trendy , think of libraries like Pygments or highlight.js that will do full syntax coloring in addition to beautifully printing your code.
Snippets will be implemented in server-side Python; highlight.js works on the browser side.
OR: use a browser-based “code editor” such as Ace , which will then format / colorize the code ... and just use the read-only control.
Dan h source share