]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/rest.cc
Negative quote count for low quotes (,) in octave check. Fixes #201
[lilypond.git] / lily / rest.cc
index b274aab8725d90ab16f73616fdf7e0228e949dfd..e3543e4cb9545f2bef8eee0b2ce1b8b48fcf5afa 100644 (file)
@@ -16,6 +16,7 @@
 #include "paper-score.hh"
 #include "staff-symbol-referencer.hh"
 #include "stencil.hh"
+#include "grob.hh"
 
 // -> offset callback
 MAKE_SCHEME_CALLBACK (Rest, y_offset_callback, 1);
@@ -27,9 +28,9 @@ Rest::y_offset_callback (SCM smob)
   int line_count = Staff_symbol_referencer::line_count (me);
   Real ss = Staff_symbol_referencer::staff_space (me);
 
+  bool position_override = scm_is_number (me->get_property ("staff-position"));
   Real amount = robust_scm2double (me->get_property ("staff-position"), 0)
     * 0.5 * ss;
-  bool position_override = amount;
   
   if (line_count % 2)
     {
@@ -186,7 +187,7 @@ Rest::generic_extent_callback (Grob *me, Axis a)
   return ly_interval2scm (unsmob_stencil (m)->extent (a));
 }
 
-ADD_INTERFACE (Rest, "rest-interface",
+ADD_INTERFACE (Rest,
               "A rest symbol.",
 
               /* properties */