lilypond-user
[Top][All Lists]
Advanced

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

Re: ChordNames on Staff


From: Aaron Hill
Subject: Re: ChordNames on Staff
Date: Wed, 06 Feb 2019 14:48:29 -0800
User-agent: Roundcube Webmail/1.3.8

On 2019-02-06 12:25 pm, Robert Hennig wrote:
Dear lilypond community,

I would like to print the ChordNames casually directly on the staff, Not
above the staff. Using extra-offset works if there are no other objects
which adjusts the spacing. What is the proper way to get the ChordNames
fixed to the staff?
I would like to create lead sheets which contain lots of remarks, only
sometimes there are notes in the staff.
Uncomment the Annotation to see what I mean.
Regards Robert

\version "2.19.82"
<<
  \new ChordNames \chordmode {
    \override ChordNames.ChordName #'extra-offset = #'(0 . -3.5)
    c1
  }
  s1%^"Text"


You need to change the nonstaff-relatedstaff-spacing so that the baselines between the ChordNames and Staff align. The key is setting padding to a large enough negative number, which permits the stencils to overlap. You will still need an additional extra-offset if you want the text to sit on the next lower staff line:

%%%%
\version "2.19.82"
<<
  \new ChordNames \with {
    \override VerticalAxisGroup.nonstaff-relatedstaff-spacing =
      #'((basic-distance . 0)(minimum-distance . 0)(padding . -10))
    \override ChordName.extra-offset = #'(0 . -1)
  }
  \chordmode { c1 | dis1:m | ees1/g }
  { s1-"Text" | s1^"Text" | s1_"Text" }

%%%%

-- Aaron Hill

Attachment: chordnames-on-staff.cropped.png
Description: PNG image


reply via email to

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