lilypond-user
[Top][All Lists]
Advanced

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

Re: strange font change in Score.repeatCommands


From: David Kastrup
Subject: Re: strange font change in Score.repeatCommands
Date: Mon, 23 Sep 2013 15:16:11 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Simon Bailey <address@hidden> writes:

> On 23 Sep 2013, at 14:46, David Kastrup wrote:
>
>> Wim van Dommelen <address@hidden> writes:
>> 
>>> I'm trying to engrave a simple volta repeat with specific text on the
>>> alternatives. In itself this works fine, I just copied the commands
>>> from the notation manual. But in doing so I see strange font-change
>>> for some (but not all !) of the characters in the text.
>> 
>> There is no font change, I think: rather the text seems to use the
>> dynamics font for some reason, and that font has a limited subset of
>> letters just sufficient to typeset rsfz, mp and a few others.  So you
>> get to see those letters in your texts, and the rest is take from some
>> fallback generic font.
>> 
>> As a workaround, you can try replacing your strings with markups that
>> also select a suitable font.
>> 
>> Of course that is not meant to imply that this behavior is in any way
>> desirable.
>
>
> this has been the behaviour since i've been working with lilypond
> (that's since 2001) -- it uses the feta-font for the volta, these are
> the "pretty" numbers also used for figured bass, etc.
>
> i haven't done it for a long time, but i think there used to be a way
> to change the font used in the voltaBracket equivalent to:
>
> <<<
> \override Score.VoltaBracket.font-family = #'roman
>>>>
>
> this doesn't do anything in this snippet however.
>
> to use markup, the steps are fairly weird:
>
> 1: define the markup: [this isn't weird]
> <<<
> repeatadlib = \markup {\normal-text \bold "repeat ad lib."}
>>>>
>
> 2. use the markup at the correct place: [this is weird]
> <<<
> \set Score.repeatCommands = #(list(list 'volta repeatadlib))
>>>>
>
> why two nested lists? removing the outer list makes the volta bracket 
> disappear. 
> writing #'(volta repeatadlib) -- which in my warped way of thinking is
> probably equivalent to #'(volta "2.") -- also doesn't work. why not?
>
> no criticism, just questions. :)

Looks far too complex.  Just take the original and insert #{ \markup
\normal-text ... #} instead of "...".  Let's see:

Oh, we have to deal with "xxx" being used as part of quoted constants
too, but that's fairly manageable.

%\version "2.16.0"
\version "2.17.26"

music = \relative f {
    \clef bass
        c4 c c c |
%\repeat volta 2 {
\set Score.repeatCommands = #'(start-repeat)
        g2_\markup { \bold \italic "ad lib. vamp" }
        g2 |
% alternatives:
\set Score.repeatCommands = #`((volta ,#{ \markup \normal-text "repeat ad lib." 
#}))
        c2 c c r2
\set Score.repeatCommands = #`((volta #f) (volta ,#{ \markup \normal-text "last 
time" #}) end-repeat)
        d2 d
\set Score.repeatCommands = #'((volta #f))
        f2 f f r |
}

\score {
        \music
}

-- 
David Kastrup

reply via email to

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