2 score-align-reg.cc -- implement Score_priority_engraver
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--1999 Han-Wen Nienhuys <hanwen@cs.uu.nl>
9 #include "dimension-cache.hh"
10 #include "axis-group-item.hh"
11 #include "score-priority-engraver.hh"
13 #include "dictionary-iter.hh"
14 #include "break-align-item.hh"
17 Score_priority_engraver::Score_priority_engraver()
23 Score_priority_engraver::do_pre_move_processing()
25 for (int i=0; i < column_p_arr_.size ();i++)
26 typeset_element (column_p_arr_[i]);
27 column_p_arr_.clear ();
31 typeset_element (halign_p_);
37 TODO: move this logic into Break_align_item
40 Score_priority_engraver::acknowledge_element (Score_element_info inf)
42 if (Item * item_l = dynamic_cast <Item *> (inf.elem_l_))
44 if (item_l->empty_b (X_AXIS) || item_l->parent_l (X_AXIS))
47 SCM bp=item_l->remove_elt_property ("breakable");
48 bool breakable = (bp != SCM_UNDEFINED);
55 halign_p_ = new Break_align_item;
56 halign_p_->set_elt_property ("breakable", SCM_BOOL_T);
57 announce_element (Score_element_info (halign_p_,0));
60 halign_p_->add_breakable_item (item_l);
64 ADD_THIS_TRANSLATOR(Score_priority_engraver);