--- /dev/null
+
+\header {
+
+ texidoc = "The rehearsal mark is put on top a breakable symbol,
+ according to the value of @code{rehearsalMarkAlignSymbol}."
+
+}
+
+\version "2.7.19"
+
+\relative {
+ c1 \mark "foo"
+ \key cis \major
+ \clef alto
+ \set Score.rehearsalMarkAlignSymbol = #'key-signature
+ \mark "on-key"
+ cis
+ \key ces \major
+ \set Score.rehearsalMarkAlignSymbol = #'clef
+ \clef treble
+ \mark "on clef"
+ ces
+}
void process_music ();
void stop_translation_timestep ();
- DECLARE_ACKNOWLEDGER (bar_line);
+ DECLARE_ACKNOWLEDGER (break_aligned);
};
Mark_engraver::Mark_engraver ()
}
void
-Mark_engraver::acknowledge_bar_line (Grob_info inf)
+Mark_engraver::acknowledge_break_aligned (Grob_info inf)
{
Grob *s = inf.grob ();
- if (text_)
+ if (text_
+ && (get_property ("rehearsalMarkAlignSymbol")
+ == s->get_property ("break-align-symbol")))
{
/*
TODO: make this configurable. RehearsalMark cannot be
#include "translator.icc"
-ADD_ACKNOWLEDGER (Mark_engraver, bar_line);
+ADD_ACKNOWLEDGER (Mark_engraver, break_aligned);
ADD_TRANSLATOR (Mark_engraver,
/* doc */ "This engraver will create RehearsalMark objects. "
"end up on the same Y-location",
/* create */ "RehearsalMark",
/* accept */ "mark-event",
- /* read */ "rehearsalMark markFormatter stavesFound",
+ /* read */ "rehearsalMark rehearsalMarkAlignSymbol markFormatter stavesFound",
/* write */ "");
whether they are processed in this context.")
(rehearsalMark ,integer? "The last rehearsal mark printed.")
+ (rehearsalMarkAlignSymbol ,symbol? "Which @code{break-align-symbol} to put the mark on? Example values: @code{clef}, @code{key-signature}.")
+
(repeatCommands ,list? "This property is read to find any command of the form @code{(volta . @var{x})}, where @var{x} is a string or @code{#f}")
(restNumberThreshold ,number?
"If a multimeasure rest has more measures
(stencil . ,Text_interface::print)
- (X-offset . ,Self_alignment_interface::x_aligned_on_self)
+ (X-offset . ,(ly:make-simple-closure
+ `(,+ ,(ly:make-simple-closure `(,Self_alignment_interface::x_aligned_on_self))
+ ,(ly:make-simple-closure `(,Self_alignment_interface::centered_on_x_parent)))
+ ))
(Y-offset . ,Side_position_interface::y_aligned_side)
(after-line-breaking . ,shift-right-at-line-begin)