How to print two rehearsal marks above and below the same barline (method 1) [obsolete in 2.23]

This method prints two 'rehearsal marks', one on top of the other. It shifts the lower rehearsal mark below the staff and then adds padding above it in order to place the upper rehearsal mark above the staff.

By adjusting the extra-offset and baseline-skip values you can increase or decrease the overall space between the rehearsal mark and the staff.

Because nearly every type of glyph or string can be made to behave like a rehearsal mark it is possible to centre those above and below a bar line.

Adding the appropriate 'break visibility' as shown in snippet 1 will allow you to position two marks at the end of a line as well.

Note: Method 1 is less complex than Method 2 but does not really allow for fine tuning of placement of one of the rehearsal marks without affecting the other. It may also give some problems with vertical spacing, since using extra-offset does not change the bounding box of the mark from its original value.

This snippet is obsolete starting from LilyPond version 2.23.14, which introduces the \textMark and \textEndMark commands. There is no restriction similar to rehearsal marks: there can be several text marks at the same moment.

Thus unapproving it --Harm