Re: Imprecise font scaling

2024-02-17 Thread Alexander Slávik
> https://gitlab.com/lilypond/lilypond/-/merge_requests/2258 Great, thanks! AS

Re: Imprecise font scaling

2024-02-16 Thread Werner LEMBERG
> I personally lacked this information on the page "1.8.2 Formatting > text – Selecting font and font size", mainly the fact that > text-font-size is in pt (as defined in other sections). https://gitlab.com/lilypond/lilypond/-/merge_requests/2258 Werner

Re: Imprecise font scaling

2024-02-16 Thread Werner LEMBERG
> This is perhaps not the best place to discuss that, but thinking > about it, I don't understand why text-font-size is dimensionless > (when it actually does have a dimension). Wouldn't text-font-size = > 12 \pt be more intuitive (and, at the same time, allowing also other > units)? This is du

Re: Imprecise font scaling

2024-02-15 Thread Alexander Slávik
This is perhaps not the best place to discuss that, but thinking about it, I don't understand why text-font-size is dimensionless (when it actually does have a dimension). Wouldn't text-font-size = 12 \pt be more intuitive (and, at the same time, allowing also other units)? AS

Re: Imprecise font scaling

2024-02-15 Thread Alexander Slávik
" Actually "NR 4.2.2 Setting the staff size" kind of document it: The default staff size is 20 points, which corresponds to a staff height of 7.03mm (one point is equal to 100/7227 of an inch, or 2540/7227 mm). " Thanks! Even more info on the units can be found "5.4.2 Distances and measu

Re: Imprecise font scaling

2024-02-15 Thread Xavier Scheuer
On Thu, 15 Feb 2024 at 12:35, Jean Abou Samra wrote: > > IMHO, this also falls in the "not worth documenting" category. But yes, > lily/include/dimensions.hh contains > > const Real INCH_TO_PT = 72.270; Hello, Actually "NR 4.2.2 Setting the staff size" kind of document it: The default staff size

Re: Imprecise font scaling

2024-02-15 Thread Jean Abou Samra
> Perhaps it might be worth clarifying what sort of "pt" does LilyPond use. Or > did I just overlook this information? IMHO, this also falls in the "not worth documenting" category. But yes, lily/include/dimensions.hh contains const Real INCH_TO_PT = 72.270; signature.asc Description: This i

Re: Imprecise font scaling

2024-02-15 Thread Alexander Slávik
Perhaps it might be worth clarifying what sort of "pt" does LilyPond use. Or did I just overlook this information? For instance, run \version "2.25.12" \pointAndClickOff \header { tagline = "" } \paper { text-font-size = 12 } \markup { LOL } and either use -dbackend=cairo --eps, or

Re: Imprecise font scaling

2024-02-11 Thread Ruud Harmsen
07:25 PM 2/10/2024, Jean Abou Samra: expects an integer size scaled by PANGO_SCALE, which is 1024. That is, we are limited to a precision of 1/1024 points on the font size. As I understand it from https://en.wikipedia.org/wiki/Point_(typography), nowadays a point is fixed to 1/72 inch or 0.3

Re: Imprecise font scaling

2024-02-10 Thread Jean Abou Samra
> Shall we document this somehow? Not everything is necessarily worth documenting. signature.asc Description: This is a digitally signed message part

Re: Imprecise font scaling

2024-02-10 Thread Alexander Slávik
" …expects an integer size scaled by PANGO_SCALE, which is 1024. That is, we are limited to a precision of 1/1024 points on the font size. " An "evidence" for this might be that the difference 7.73242188 - 7.73046876 is pretty close to 2/1024. AS

Re: Imprecise font scaling

2024-02-10 Thread Werner LEMBERG
>> However, 2 * 3.86523438 = 7.73046876 != 7.73242188. > I'm quite sure this is because of > > int pango_size = static_cast ( >     std::lround (static_cast (requested_size) * PANGO_SCALE)); > > > in lily/font-select.cc, which we cannot really do anything about, > because the Pango API >

Re: Imprecise font scaling

2024-02-10 Thread Jean Abou Samra
Sorry, my mail client changed the formatting in a way I didn't expect. Resending. > I'm running the following code > > \version "2.25.12" > \markup { LOL } > \markup { \magnify #2.0 LOL } > > and the results are not really precise. When producing --eps, the relevant > output lines are > > /C059

Re: Imprecise font scaling

2024-02-10 Thread Jean Abou Samra
I'm running the following code \version "2.25.12" \markup { LOL } \markup { \magnify #2.0 LOL } and the results are not really precise. When producing --eps, the relevant output lines are /C059-Roman 3.86523438 output-scale div selectfont /C059-Roman 7.73242188 output-scale div selectfont How

Imprecise font scaling

2024-02-02 Thread Alexander Slávik
Hello, I'm running the following code \version "2.25.12" \markup { LOL } \markup { \magnify #2.0 LOL } and the results are not really precise. When producing --eps, the relevant output lines are /C059-Roman 3.86523438 output-scale div selectfont /C059-Roman 7.73242188 output-scale div selectfo