On Monday, October 8, 2012 8:45:27 PM UTC+11, Lex Trotman wrote: > > [...] > >> However, I have a followup :-) >> >> Is there any way to get syntax highlighting for examples? >> I tried: >> >> .Optional Title >> [source,Perl] >> >> ====== >> >> die 'connect: '.$dbh->errstr; >> >> ====== >> >> >> but it just puts everything into a 'boring' <para>... no highlighting and >> (in more complex examples) the newlines are lost. >> >> > Docbook example entities are not syntax highlighted, only program-listing > entities are. You have to put the listing block (with [source, perl]) > inside the example block. >
Aha! That makes sense. Thanks!! /me <--- another happy customer :) > > .Optional Title > ==== > > [source, perl] > die 'etc'; > > ==== > > Gives > > <example> > <title>Optional Title</title> > <programlisting language="perl" linenumbering="unnumbered">die > 'etc';</programlisting> > </example> > > Cheers > Lex > > >> >> Any suggestions? >> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "asciidoc" group. >> To view this discussion on the web visit >> https://groups.google.com/d/msg/asciidoc/-/yaXNBT41NysJ. >> >> To post to this group, send email to [email protected]<javascript:> >> . >> To unsubscribe from this group, send email to >> [email protected] <javascript:>. >> For more options, visit this group at >> http://groups.google.com/group/asciidoc?hl=en. >> > > -- You received this message because you are subscribed to the Google Groups "asciidoc" group. To view this discussion on the web visit https://groups.google.com/d/msg/asciidoc/-/96yGN5WwPqIJ. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/asciidoc?hl=en.
