[Top][All Lists]

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

Re: \markup \sans ... does not always give sans-serif output in svgs in

From: James Lowe
Subject: Re: \markup \sans ... does not always give sans-serif output in svgs in 2.19.36
Date: Tue, 16 Feb 2016 21:17:40 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0


On 13/02/16 20:50, Paul Morris wrote:
Looking closer at the SVG files produced...  In 2.18 we have this:

   <text … font-family="sans-serif” … > some text </text>

Whereas in 2.19 we have this:

   <text … font-family="LilyPond Sans Serif” … > some text </text>

And when I manually edit the 2.19 svg file so it has font-family="sans-serif” 
then that fixes it and the text appears as sans-serif.  Elsewhere in the svg files I 
see that:

2.18 svg has:  font-family="Century Schoolbook L”
2.19 svg has:  font-family="LilyPond Serif"

 From this thread:

and this commit:

we see that “LilyPond Sans Serif” and “LilyPond Serif” are aliases.  So it appears that 
the code that produces the svgs is including the alias names for “font-family" 
rather than what the alias refers to (e.g. “sans-serif” or "Century Schoolbook L”).
From usage:


*Note for backend svg output:* LilyPond’s default fonts (|LilyPond Serif|, |LilyPond Sans Serif| and |LilyPond Monospace|) are just /local/ font aliases. Therefore, when using the backend |svg| command you must explicitly define the default fonts in your source file;

   \paper  {
      #(define fonts
        (make-pango-font-tree "TeX Gyre Schola"
                              "TeX Gyre Heros"
                              "TeX Gyre Cursor"
                              (/ staff-height pt 20)))



B8F4 5395 CBE2 ED37 7513 B075 FF32 5682 A84B D8BE

reply via email to

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