lilypond-user
[Top][All Lists]
Advanced

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

Re: how to insert text inside a hairpin?


From: Jean Abou Samra
Subject: Re: how to insert text inside a hairpin?
Date: Fri, 3 Sep 2021 21:46:56 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0



Le 03/09/2021 à 20:52, Kenneth Wolcott a écrit :
Hi;

   I am engraving some music that has a "poco rit." embedded inside a hairpin.

   See attached image.

   How do I do that in Lilypond?

   I'm using Lilypond 2.22.0

Thanks,
Ken Wolcott


Try this:

\version "2.22.1"

\relative {
  % Make sure the hairpin will be drawn below the text
  % (this can depend on unrelated circumstances).
  \once \override Hairpin.layer = -2
  a'4--->\>
  % Set distance from the staff.
  \once \override TextScript.Y-offset = -2
  % Prevent the hairpin from moving away to avoid the text.
  \once \override TextScript.vertical-skylines = ##f
  % Print a white background around the text.
  \once \override TextScript.whiteout = 10
  % Make sure the text is above the hairpin but below other grobs
  % (such as the slur).
  \once \override TextScript.layer = -1
  a8(_\markup \italic "poco rit." bes a g f4)\fermata\!
}

Take a look at
http://lilypond.org/doc/v2.22/Documentation/notation/visibility-of-objects#painting-objects-white

Best,
Jean




reply via email to

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