Le 20/12/2021 à 17:01, Patrice Dumas a écrit :
On Wed, Nov 24, 2021 at 03:17:22PM +0000, Werner LEMBERG wrote:
Hello Gavin,


For the LilyPond documentation we are going to use `pygments` to do
automatic colour highlighting of LilyPond snippets.  We also want to
support this feature in the PDF manuals.  To do so I ask you to apply
something like the following patch to make `@setcolor` work in
`@example` environments, too.
I don't know if it is relevant or not, but, for HTML, there is an init
file, tp/init/highligh_syntax.pm that uses source-highlight to highlight
@example blocks based on the language argument.


Thanks for the heads-up, I didn't know about that.
Unfortunately, it will not work for us, for several
reasons: first, we are still using texi2html, not
makeinfo (and even the decade-old texi2html 1.82!),
and second, the highlighting is done by Pygments,
not by source-highlight. While source-highlight does
have some level of support for LilyPond, it is old,
a number of syntactic features are not supported, and
the lexer has not been updated for newer LilyPond
versions.

Best regards,
Jean


Reply via email to