6

The documentation for \markup alignment lists two essentially different padding commands: \pad-around or \pad-markup, which adds the same amount of space all around the element, and \pad-x, which adds left and right padding while leaving the top and bottom unpadded.

Is there any one command that only adds vertical padding? Or do I need to do something like

\pad-around #0.5 \pad-x #-0.5 { STUFF }

to achieve that?

ETA: My overarching goal is to correctly white out the parts of bar lines that would otherwise intersect with expressive marks, like so:

a score with "sostenuto" crossing a barline

The full code can be found here at LilyBin.

Richard
  • 84,447
  • 18
  • 194
  • 369
Micah
  • 1,639
  • 14
  • 27

2 Answers2

4

You should be able to use \vspace, e.g.

    \markup{ 
       \vspace #10
        stuff
       \vspace #10
    }

as per this question

Dave
  • 17,808
  • 10
  • 60
  • 98
  • Thanks. Hoist by my own petard! Unfortunately, I don't think this quite does what I want; Lilypond is a lot more aggressive about removing \vspace inside staves than it is about removing padding. – Micah Sep 01 '14 at 19:32
2

This is a late answer, but are you familiar with the /whiteout command? It's a pre-defined tool that explicitly handles your "overarching" goal of barlines interfering with expressive marks. Something like d^\markup { \italic \whiteout { sostenuto } } will do the trick:

enter image description here

Full code here at LilyBin.

Richard
  • 84,447
  • 18
  • 194
  • 369