2 p-col.hh -- declare Paper_column
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--1999 Han-Wen Nienhuys <hanwen@cs.uu.nl>
13 #include "axis-group-item.hh"
18 stuff grouped vertically.
19 This is a class to address items vertically. It contains the data for:
26 the linespacing problem
30 class Paper_column : public Axis_group_item {
32 VIRTUAL_COPY_CONS(Score_element);
33 Drul_array<Array<Column_rod> > minimal_dists_arr_drul_;
36 /// set a minimum distance
37 void add_rod (Paper_column * to, Real distance);
39 /** prebreak is put before end of line.
40 if broken here, then (*this) column is discarded, and prebreak
41 is put at end of line, owned by Col
43 Paper_column *prebreak_l() const;
45 /// postbreak at beginning of the new line
46 Paper_column *postbreak_l() const;
48 virtual Paper_column * column_l () const;
49 /// if lines are broken then this column is in #line#
50 Line_of_score *line_l_;
52 virtual Line_of_score *line_l () const;
54 /// which one (left =0)
57 bool breakpoint_b() const;
58 void add_item (Item *i);
63 which col comes first?.
64 signed compare on columns.
66 @return < 0 if c1 < c2.
68 static int compare (const Paper_column &c1, const Paper_column &c2);
72 virtual void do_print() const;
76 The ranking: left is smaller than right
85 INSTANTIATE_COMPARE(Paper_column &, Paper_column::compare);