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) 1998--2020 Han-Wen Nienhuys <hanwen@xs4all.nl> | 4 Copyright (C) 1998--2020 Han-Wen Nienhuys <hanwen@xs4all.nl> |
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 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
242 } | 242 } |
243 } | 243 } |
244 | 244 |
245 void | 245 void |
246 Beam_engraver::acknowledge_rest (Grob_info info) | 246 Beam_engraver::acknowledge_rest (Grob_info info) |
247 { | 247 { |
248 if (beam_ | 248 if (beam_ |
249 && !scm_is_number (info.grob ()->get_property_data ("staff-position"))) | 249 && !scm_is_number (info.grob ()->get_property_data ("staff-position"))) |
250 chain_offset_callback (info.grob (), | 250 chain_offset_callback (info.grob (), |
251 Unpure_pure_container::make_smob | 251 Unpure_pure_container::make_smob |
252 (Beam::rest_collision_callback_proc, | 252 (Beam::rest_collision_callback_proc, |
253 Beam::pure_rest_collision_callback_proc), | 253 Beam::pure_rest_collision_callback_proc), |
254 Y_AXIS); | 254 Y_AXIS); |
255 } | 255 } |
256 | 256 |
257 void | 257 void |
258 Beam_engraver::acknowledge_stem (Grob_info info) | 258 Beam_engraver::acknowledge_stem (Grob_info info) |
259 { | 259 { |
260 if (!beam_) | 260 if (!beam_) |
261 return; | 261 return; |
262 | 262 |
263 Moment now = now_mom (); | 263 Moment now = now_mom (); |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
305 stem->set_property ("duration-log", scm_from_int (durlog)); | 305 stem->set_property ("duration-log", scm_from_int (durlog)); |
306 Moment stem_location = now - beam_start_mom_ + beam_start_location_; | 306 Moment stem_location = now - beam_start_mom_ + beam_start_location_; |
307 beam_info_->add_stem (stem_location, | 307 beam_info_->add_stem (stem_location, |
308 std::max (durlog - 2, 0), | 308 std::max (durlog - 2, 0), |
309 Stem::is_invisible (stem), | 309 Stem::is_invisible (stem), |
310 stem_duration->factor (), | 310 stem_duration->factor (), |
311 (to_boolean (stem->get_property ("tuplet-start")))); | 311 (to_boolean (stem->get_property ("tuplet-start")))); |
312 Beam::add_stem (beam_, stem); | 312 Beam::add_stem (beam_, stem); |
313 } | 313 } |
314 | 314 |
315 | |
316 void | 315 void |
317 Beam_engraver::boot () | 316 Beam_engraver::boot () |
318 { | 317 { |
319 ADD_LISTENER (Beam_engraver, beam); | 318 ADD_LISTENER (Beam_engraver, beam); |
320 ADD_ACKNOWLEDGER (Beam_engraver, stem); | 319 ADD_ACKNOWLEDGER (Beam_engraver, stem); |
321 ADD_ACKNOWLEDGER (Beam_engraver, rest); | 320 ADD_ACKNOWLEDGER (Beam_engraver, rest); |
322 } | 321 } |
323 | 322 |
324 ADD_TRANSLATOR (Beam_engraver, | 323 ADD_TRANSLATOR (Beam_engraver, |
325 /* doc */ | 324 /* doc */ |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
389 /* read */ | 388 /* read */ |
390 "baseMoment " | 389 "baseMoment " |
391 "beamMelismaBusy " | 390 "beamMelismaBusy " |
392 "beatStructure " | 391 "beatStructure " |
393 "subdivideBeams ", | 392 "subdivideBeams ", |
394 | 393 |
395 /* write */ | 394 /* write */ |
396 "" | 395 "" |
397 ); | 396 ); |
398 | 397 |
OLD | NEW |