Quote:
Originally Posted by twobits
In html you are supposed to use the code tag instead of the pre tag, though the effect in browsers is usually the same. Does the epub xhtml not support that tag?
|
They don't do the same thing. <pre> preserves the layout (line breaks, whitespace) from the source file. <code> designates a phrase as code. An easy way to display indented code is to nest <code> within <pre>.
It is problematic at times on an eReader. I'll probably go with Falcao's solution - offer longer code snippets as a separate download. If I decide to take the plunge, that is.