OLD | NEW |
1 /* | 1 /* |
2 This file is part of LilyPond, the GNU music typesetter. | 2 This file is part of LilyPond, the GNU music typesetter. |
3 | 3 |
4 Copyright (C) 1996--2015 Han-Wen Nienhuys | 4 Copyright (C) 1996--2015 Han-Wen Nienhuys |
5 | 5 |
6 LilyPond is free software: you can redistribute it and/or modify | 6 LilyPond is free software: you can redistribute it and/or modify |
7 it under the terms of the GNU General Public License as published by | 7 it under the terms of the GNU General Public License as published by |
8 the Free Software Foundation, either version 3 of the License, or | 8 the Free Software Foundation, either version 3 of the License, or |
9 (at your option) any later version. | 9 (at your option) any later version. |
10 | 10 |
11 LilyPond is distributed in the hope that it will be useful, | 11 LilyPond is distributed in the hope that it will be useful, |
12 but WITHOUT ANY WARRANTY; without even the implied warranty of | 12 but WITHOUT ANY WARRANTY; without even the implied warranty of |
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
14 GNU General Public License for more details. | 14 GNU General Public License for more details. |
15 | 15 |
16 You should have received a copy of the GNU General Public License | 16 You should have received a copy of the GNU General Public License |
17 along with LilyPond. If not, see <http://www.gnu.org/licenses/>. | 17 along with LilyPond. If not, see <http://www.gnu.org/licenses/>. |
18 */ | 18 */ |
19 | 19 |
20 #ifndef SYSTEM_HH | 20 #ifndef SYSTEM_HH |
21 #define SYSTEM_HH | 21 #define SYSTEM_HH |
22 | 22 |
| 23 #include <limits> |
| 24 |
23 #include "column-x-positions.hh" | 25 #include "column-x-positions.hh" |
24 #include "spanner.hh" | 26 #include "spanner.hh" |
25 #include "skyline.hh" | 27 #include "skyline.hh" |
26 | 28 |
27 /* | 29 /* |
28 If you keep following offset reference points, you will always end | 30 If you keep following offset reference points, you will always end |
29 up at the root object. This root object is called @ref{System}, and it | 31 up at the root object. This root object is called @ref{System}, and it |
30 represents a system (i.e. a line of music). | 32 represents a system (i.e. a line of music). |
31 */ | 33 */ |
32 class System : public Spanner | 34 class System : public Spanner |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 | 70 |
69 System (SCM); | 71 System (SCM); |
70 System (System const &); | 72 System (System const &); |
71 | 73 |
72 int element_count () const; | 74 int element_count () const; |
73 int spanner_count () const; | 75 int spanner_count () const; |
74 | 76 |
75 void break_into_pieces (vector<Column_x_positions> const &); | 77 void break_into_pieces (vector<Column_x_positions> const &); |
76 | 78 |
77 vector<Item *> broken_col_range (Item const *, Item const *) const; | 79 vector<Item *> broken_col_range (Item const *, Item const *) const; |
78 vector<Grob *> used_columns () const; | 80 vector<Grob *> used_columns_in_range (vsize start, vsize end) const; |
| 81 vector<Grob *> used_columns () const |
| 82 { |
| 83 return used_columns_in_range(0, std::numeric_limits<vsize>::max ()); |
| 84 } |
79 Paper_column *column (vsize i) const; | 85 Paper_column *column (vsize i) const; |
80 | 86 |
81 void add_column (Paper_column *); | 87 void add_column (Paper_column *); |
82 void typeset_grob (Grob *); | 88 void typeset_grob (Grob *); |
83 void pre_processing (); | 89 void pre_processing (); |
84 | 90 |
85 Interval begin_of_line_pure_height (vsize start, vsize end); | 91 Interval begin_of_line_pure_height (vsize start, vsize end); |
86 Interval rest_of_line_pure_height (vsize start, vsize end); | 92 Interval rest_of_line_pure_height (vsize start, vsize end); |
87 Interval pure_refpoint_extent (vsize start, vsize end); | 93 Interval pure_refpoint_extent (vsize start, vsize end); |
88 void collect_labels (Grob const *, SCM *); | 94 void collect_labels (Grob const *, SCM *); |
89 | 95 |
90 protected: | 96 protected: |
91 virtual void derived_mark () const; | 97 virtual void derived_mark () const; |
92 virtual System *clone () const { return new System (*this); } | 98 virtual System *clone () const { return new System (*this); } |
93 | 99 |
94 private: | 100 private: |
95 Interval part_of_line_pure_height (vsize start, vsize end, bool begin); | 101 Interval part_of_line_pure_height (vsize start, vsize end, bool begin); |
96 }; | 102 }; |
97 | 103 |
98 void set_loose_columns (System *which, Column_x_positions const *posns); | 104 void set_loose_columns (System *which, Column_x_positions const *posns); |
99 | 105 |
100 #endif /* SYSTEM_HH */ | 106 #endif /* SYSTEM_HH */ |
101 | 107 |
OLD | NEW |