lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: pygments: `\foo` not always rendered as bold


From: Werner LEMBERG
Subject: Re: pygments: `\foo` not always rendered as bold
Date: Tue, 20 Sep 2022 12:18:36 +0000 (UTC)

> \open is lexed as Token.Name.Builtin.Articulation, which the PDF
> style in book_highlight.py explicitly doesn't make bold:
> 
> 
> # A custom black-and-white style designed for the PDF documentation.
> pdf_styles = {
>     Token: "",
>     Token.Whitespace: "",
>     Token.Text: "",
>     Token.Keyword: "bold",
>     Token.Comment: "italic",
>     Token.String: "",
>     Token.String.Escape: "",
>     Token.String.Symbol: "",
>     Token.Pitch: "",
>     Token.Number: "",
>     Token.ChordModifier: "",
>     Token.Name.Lvalue: "bold",
>     Token.Name.BackslashReference: "bold",
>     Token.Name.Builtin.MusicCommand: "bold",
>     Token.Name.Builtin.PaperVariable: "bold italic",
>     Token.Name.Builtin.HeaderVariable: "bold italic",
>     Token.Name.Builtin.MusicFunction: "bold",
>     Token.Name.Builtin.Clef: "",
>     Token.Name.Builtin.Scale: "bold",
>     Token.Name.Builtin.RepeatType: "",
>     Token.Name.Builtin.Dynamic: "",
>     Token.Name.Builtin.Articulation: "",
>     Token.Name.Builtin.SchemeFunction: "bold",
>     Token.Name.Builtin.SchemeBuiltin: "bold",
>     Token.Name.Builtin.MarkupCommand: "bold",
>     Token.Name.Builtin.Context: "bold italic",
>     Token.Name.Builtin.ContextProperty: "bold italic",
>     Token.Name.Builtin.Grob: "italic",
>     Token.Name.Builtin.GrobProperty: "italic",
>     Token.Name.Builtin.Translator: "bold italic",
> }
> 
> 
> Remind me who wrote this style, already? :-)

Well :-)

I will prepare a MR to improve this.

BTW, I've just seen that `\maxima` gets handled differently than
`\longa` (see attached image) – *this* looks like a bug not related to
the above table, or am I missing something?


    Werner

PNG image


reply via email to

[Prev in Thread] Current Thread [Next in Thread]