LEFT | RIGHT |
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) 2006--2011 Joe Neeman <joeneeman@gmail.com> | 4 Copyright (C) 2006--2011 Joe Neeman <joeneeman@gmail.com> |
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 |
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
177 compressed.compressed_lines_count_ = old.compressed_lines_count_ + 1; | 177 compressed.compressed_lines_count_ = old.compressed_lines_count_ + 1; |
178 compressed.compressed_nontitle_lines_count_ | 178 compressed.compressed_nontitle_lines_count_ |
179 = old.compressed_nontitle_lines_count_ + (compressed.title_ ? 0 : 1)
; | 179 = old.compressed_nontitle_lines_count_ + (compressed.title_ ? 0 : 1)
; |
180 | 180 |
181 // compressed.title_ is true if and only if the first of its | 181 // compressed.title_ is true if and only if the first of its |
182 // compressed lines was a title. | 182 // compressed lines was a title. |
183 compressed.title_ = old.title_; | 183 compressed.title_ = old.title_; |
184 | 184 |
185 // adds footnotes of one line to the footnotes of another | 185 // adds footnotes of one line to the footnotes of another |
186 compressed.footnote_heights_.insert (compressed.footnote_heights_.begi
n (), | 186 compressed.footnote_heights_.insert (compressed.footnote_heights_.begi
n (), |
187 old.footnote_heights_.begin (), o
ld.footnote_heights_.end ()); | 187 old.footnote_heights_.begin (), |
| 188 old.footnote_heights_.end ()); |
188 compressed.in_note_heights_.insert (compressed.in_note_heights_.begin
(), | 189 compressed.in_note_heights_.insert (compressed.in_note_heights_.begin
(), |
189 old.in_note_heights_.begin (), old
.in_note_heights_.end ()); | 190 old.in_note_heights_.begin (), |
| 191 old.in_note_heights_.end ()); |
190 | 192 |
191 ret.back () = compressed; | 193 ret.back () = compressed; |
192 } | 194 } |
193 else | 195 else |
194 { | 196 { |
195 ret.push_back (orig[i]); | 197 ret.push_back (orig[i]); |
196 ret.back ().force_ = 0; | 198 ret.back ().force_ = 0; |
197 } | 199 } |
198 } | 200 } |
199 return ret; | 201 return ret; |
(...skipping 1451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1651 // FIXME: take into account the height of the footer | 1653 // FIXME: take into account the height of the footer |
1652 Real translate = min (line.shape_.begin_[DOWN], line.shape_.rest_[DOWN]); | 1654 Real translate = min (line.shape_.begin_[DOWN], line.shape_.rest_[DOWN]); |
1653 return max (0.0, max (padding, min_distance + translate)); | 1655 return max (0.0, max (padding, min_distance + translate)); |
1654 } | 1656 } |
1655 | 1657 |
1656 int | 1658 int |
1657 Page_breaking::orphan_penalty () const | 1659 Page_breaking::orphan_penalty () const |
1658 { | 1660 { |
1659 return orphan_penalty_; | 1661 return orphan_penalty_; |
1660 } | 1662 } |
LEFT | RIGHT |