]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/lyric-hyphen.cc
(descend-to-context, context-spec-music): optional arguments id mods
[lilypond.git] / lily / lyric-hyphen.cc
index 0e3a67e3482f0e6e5a455ebb2618f8d55c020d44..236e7e315aef9d0c5f234010f820333ba80ee5b5 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 2003--2012 Han-Wen Nienhuys <hanwen@xs4all.nl>
+  Copyright (C) 2003--2015 Han-Wen Nienhuys <hanwen@xs4all.nl>
 
   LilyPond is free software: you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
@@ -35,7 +35,7 @@ MAKE_SCHEME_CALLBACK (Lyric_hyphen, print, 1);
 SCM
 Lyric_hyphen::print (SCM smob)
 {
-  Spanner *me = unsmob_spanner (smob);
+  Spanner *me = unsmob<Spanner> (smob);
   Drul_array<Item *> bounds (me->get_bound (LEFT),
                              me->get_bound (RIGHT));
 
@@ -81,7 +81,7 @@ Lyric_hyphen::print (SCM smob)
       && !bounds[RIGHT]->break_status_dir ())
     {
       Real minimum_length = robust_scm2double (me->get_property ("minimum-length"), .3);
-      dash_length = max ((l - 2 * padding), minimum_length);
+      dash_length = std::max ((l - 2 * padding), minimum_length);
     }
 
   Real space_left = l - dash_length - (n - 1) * dash_period;
@@ -94,7 +94,7 @@ Lyric_hyphen::print (SCM smob)
       && !bounds[RIGHT]->break_status_dir ())
     return SCM_EOL;
 
-  space_left = max (space_left, 0.0);
+  space_left = std::max (space_left, 0.0);
 
   Box b (Interval (0, dash_length), Interval (h, h + th));
   Stencil dash_mol (Lookup::round_filled_box (b, 0.8 * lt));
@@ -115,7 +115,7 @@ MAKE_SCHEME_CALLBACK (Lyric_hyphen, set_spacing_rods, 1);
 SCM
 Lyric_hyphen::set_spacing_rods (SCM smob)
 {
-  Grob *me = unsmob_grob (smob);
+  Grob *me = unsmob<Grob> (smob);
 
   Rod r;
   Spanner *sp = dynamic_cast<Spanner *> (me);