On Tue, 2005-04-26 at 11:22 +0900, Steve B wrote:
> On an even more off topic note.. anybody know how use some nifty CSS
> or similar to take a block of text (code) and automaticly add line
> numbers? I guess I could use PHP but was looking for a CSS type style.

Nice idea, but I don't think the lines within a <code> block are
addressable by CSS, as they don't appear in the document tree and don't
have pseudo-element selectors (not even in CSS3, AFAICR).

Seeing as the code needs processing anyway to escape XML-semantic
characters, you may as well pass it through a syntax-colouring module;
that will do escaping, line numbering and syntax colouring all in one
go.

-- 
gentoo-user@gentoo.org mailing list

Reply via email to