lilypond-user
[Top][All Lists]
Advanced

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

Re: Trouble with notation fonts when resizing


From: David Sumbler
Subject: Re: Trouble with notation fonts when resizing
Date: Sat, 12 May 2018 17:57:19 +0100

On Sat, 2018-05-12 at 03:45 -0700, Torsten Hämmerle wrote:
> David Sumbler wrote
> > 
> > set-global-staff-size seems to be very buggy, and the newer
> > magnify-
> > staff (see Notation Ref. section 4.2.2) is recommended
> Hi David,
> 
> I wouldn't call set-global-staff-size buggy, it's still the way to go
> if you
> want to change the global stave size.
> 
> \magnifyStaff is inteded to be used for scaling single staves within
> a score
> and spacing will behave accordingly.
> 
> The problem Brent ran into is neither new nor does it come
> unexpected: When
> using custom fonts (no difference between text and music fonts here),
> you'll
> have to tell LilyPond which size to use, and consequently you always
> had to
> scaling factors.
> 
> Examples:
> When changing a document's default fonts by using pango-make-font-
> tree,
> there should alway be a scaling factor such as
> (/ staff-height pt 20)
> if you want to use non-standard stave-sizes (i.e. stave-sizes other
> than 20
> pt)
> 
> The same holds true for music fonts.
> 
> Therefore, Andrew's approach is the way to go.
> There is a nice  essay on alternative notations fonts
> <http://lilypondblog.org/2015/03/managing-alternative-fonts-with-lily
> pond/>  
> by Urs Liska, giving an example:
> 
> \paper {
>   #(define fonts
>     (set-global-fonts
>       #:music "emmentaler"
>       #:brace "emmentaler"
>       #:roman "Century Schoolbook L"
>       #:sans "sans-serif"
>       #:typewriter "monospace"
>       #:factor (/ staff-height pt 20)
>   ))
> }
> 
> In Brent's original post, this #:factor entry was missing and that's
> the
> reason why the gonville font wasn't properly sized.
> 
> All the best,
> Torsten

The problem I found over a year ago, and rediscovered yesterday is
that, even without changing any fonts from the default, using set-
global-staff-size more than once in the same input file (but relating
to separate output files) causes huge problems with the layout of text
in the second (or later) output file.  It is as if using this command
sets various parameters, but then using it a second time (for a
different output file) does not set those parameters correctly.  I
would certainly call that buggy, particularly as the documentation
implies that it ought to be set-able independently for every individual
\book section in an output file.

I haven't looked at the source code, and probably wouldn't be able to
fathom it if I did, but I wonder if set-global-staff-size alters some
parameters on the assumption that they are at their default values,
which of course can give a wrong result after a previous call.

Certainly for my purposes I have found set-global-staff-size virtually
unusable, because it can produce crazy text layouts such as having
adjacent letters in a word overlapping each other.  However I am
delighted to say that putting (for instance)
\layout { Staff \magnifyStaff #4/5 }
at the appropriate point in a file gives me 16-point staves without
messing up the layout of titles etc.

David



reply via email to

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