Hello Michael, > my case consists of four instruments. Textmarks are repeated in the score - > is that good practise? I wish they'd only appear once. I understand the > conductor then cannot know what the players see... but still.
The whole reason why we have \textMark is that there can only be a single
rehearsal mark per timestep. So if you want no duplication the easiest thing
would be to simply use \mark "..." with potential changes to break-alignment,
self-alignment and break-visibility (of course "a tempo" is best suited as
metronome mark, since it is a tempo indication).
If you actually want to be able to have multiple marks at the same time but
want
to avoid having multiple marks you can create an engraver that tracks all text
marks created an allowing each text to appear just once:
%% EXAMPLE BEGIN
#(define (collapse-marks-engraver context)
(let ((mark-map (make-hash-table)))
(make-engraver
(acknowledgers
((text-mark-interface engraver grob source)
(let ((text (ly:grob-property grob 'text)))
(if (hash-ref mark-map text)
(ly:grob-suicide! grob)
(hash-set! mark-map text #t)))))
((stop-translation-timestep engraver)
(hash-clear! mark-map)))))
\layout {
\context {
\Score
\consists #collapse-marks-engraver
}
}
\version "2.26.0"
\book {
\score {
<<
\new Staff { \textMark \markup \italic"a tempo" c'4 f \textMark \markup
\italic"a tempo" g a }
\new Staff { \textMark \markup \italic"a tempo" a4 c' \textMark \markup
\italic"a tempo" d' f' }
\new Staff { \textMark \markup \italic"a tempo" a2 \textMark \markup
\italic"a tempo" c'2 }
\new Staff { \textMark \markup \italic"a tempo" c'4. d'8 \textMark
\markup \italic"a tempo" f'2 }
>>
}
}
%% EXAMPLE END
Cheers,
Tina
signature.asc
Description: This is a digitally signed message part.
