lilypond-user
[Top][All Lists]
Advanced

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

Re: Modifying Stencil for Clef


From: David Kastrup
Subject: Re: Modifying Stencil for Clef
Date: Fri, 22 Feb 2019 18:03:45 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Richard Shann <address@hidden> writes:

> Thank you very much for this explanation - I can now go from the entry
> in the list of layout objects (via the links at the top of the entry)
> back to the engravers that create them and then from there (via the
> link at the end) to the context that the engraver is part of, and know
> that I should prefix the layout object name with that.
> I'm still left with a puzzle for the ClefModifier layout object:
>
> \version "2.18.2"
> { 
>   c'
>  \override Staff.ClefModifier.stencil = #ly:text-interface::print 
>  \once \override Staff.ClefModifier.text = \markup{T}
>  \clef "bass_8"
>   c'
> }
>
> which I was expecting to find the italic 8 replaced by the character T
> (I see that there is no need to replace the stencil in this case as it
> is by default ly:text-interface::print)

A markup is not a finished stencil but can be converted to one in a
variety of ways.  ly:text-interface::print uses whatever properties are
set in the text-interface related grob properties, and ClefModifier has
things like

        (color . ,(grob::inherit-parent-property
                   X 'color))
        (font-shape . italic)
        (font-size . -4)

in its definition.  You can override those, or you can use stuff like

    \once \override Staff.ClefModifier.text = \markup \normal-text "T"

in order to override the defaults in the grob definition.

-- 
David Kastrup



reply via email to

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