On 2018-11-17 9:05 am, Kieren MacMillan wrote:
Hi Aaron,

Ah, but the 7 and 5 in that font in fact have descenders. The baseline is not the same as the bottom extent of a glyph.

Yes — we’re saying the same thing.  =)

Oh, I'm a dumb dumb.

Your issue is that the padding between staff and markup is using the bottom extent, not the baseline, hence it looks off.

You might just want to clip the descenders on offending lines. Not recommended for general use, but try:

%%%%
\version "2.19.82"

#(define-markup-command (trim-descenders layout props args) (markup?)
  (let* ((stencil (interpret-markup layout props args))
         (x-extent (ly:stencil-extent stencil 0))
         (y-extent (ly:stencil-extent stencil 1)))
    (interpret-markup layout props (markup
      #:with-dimensions x-extent (cons 0 (cdr y-extent)) args))))

\fixed c'' {
  \override Fingering.font-name = #"Alegreya"
  \override Fingering.font-size = #4
  g8-\finger "q"
  g8-\finger "x"
  g8-\finger "b"
  g8-\finger \markup \trim-descenders "q"
}
%%%%

Side effect is, of course, overlapping. But the padding should now be relative to the baseline (Y-coord zero) regardless of descenders.

-- Aaron Hill
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to