X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fnote-spacing.cc;h=a894be25394c9a41ba44a5db8870e79e686c574b;hb=97a0169312a260933246ab224e4f8b0969871dd5;hp=63a35874759be647da88217fba3a5da53799dce5;hpb=59a6d1a06432fc0ca88c3023c646182f389ec1b5;p=lilypond.git diff --git a/lily/note-spacing.cc b/lily/note-spacing.cc index 63a3587475..a894be2539 100644 --- a/lily/note-spacing.cc +++ b/lily/note-spacing.cc @@ -35,8 +35,6 @@ #include "stem.hh" #include "warn.hh" -using std::vector; - /* Adjust the ideal and minimum distance between note columns, based on the notehead size, skylines, and optical illusions. @@ -78,7 +76,7 @@ Note_spacing::get_spacing (Grob *me, Item *right_col, Real ideal = base.distance () - increment + left_head_end; Drul_array skys = Spacing_interface::skylines (me, right_col); Real distance = skys[LEFT].distance (skys[RIGHT], robust_scm2double (right_col->get_property ("skyline-vertical-padding"), 0.0)); - Real min_dist = std::max (0.0, distance); + Real min_dist = max (0.0, distance); base.set_min_distance (min_dist); /* If we have a NonMusical column on the right, we measure the ideal distance @@ -99,13 +97,13 @@ Note_spacing::get_spacing (Grob *me, Item *right_col, but keep at least half the gap we would have had to a note */ Real min_desired_space = (ideal + min_dist) / 2.0; ideal -= right_col->extent (right_col, X_AXIS)[RIGHT]; - ideal = std::max (ideal, min_desired_space); + ideal = max (ideal, min_desired_space); } } stem_dir_correction (me, right_col, increment, &ideal); - base.set_distance (std::max (0.0, ideal)); + base.set_distance (max (0.0, ideal)); return base; } @@ -147,7 +145,7 @@ different_directions_correction (Grob *note_spacing, /* Ugh. 7 is hardcoded. */ - ret = std::min (ret / 7, 1.0) + ret = min (ret / 7, 1.0) * left_stem_dir * robust_scm2double (note_spacing->get_property ("stem-spacing-correction"), 0); }