May 19, 2009 00:10
You can convert your buffer in emacs to HTML using: M-x htmlize-buffer
The default is for it to use CSS with the style names in the header of the HTML. That's fine if you're putting it into a webpage of your own design, but not if you're putting it in a blog post like LiveJournal.
You can set it to use "inline css," instead:
M-x set-variable RET htmlize-output-type RET inline-css
That's the setting I used for my previous post which showed the preprocessor output of the protothread code. (The post before that which actually showed the protothread and FSM code was generated using a plugin for jEdit. Or was it Vim's :2html command? I don't remember. Amnesia?)
In addition to the default of css and inline-css, you can also use font as a possible value for htmlize-output-type.
html,
printing,
emacs,
computer