]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/tuplet-number.cc
Run grand-replace (issue 3765)
[lilypond.git] / lily / tuplet-number.cc
index aaa862395d7163651e74918e45622b9e61e1820d..e062e67c9b6860195646eea7f0a7b7d5ad48190e 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 2005--2011 Han-Wen Nienhuys <hanwen@xs4all.nl>
+  Copyright (C) 2005--2014 Han-Wen Nienhuys <hanwen@xs4all.nl>
 
 
   LilyPond is free software: you can redistribute it and/or modify
@@ -78,9 +78,8 @@ Tuplet_number::calc_y_offset (SCM smob)
   Spanner *me = unsmob_spanner (smob);
   Spanner *tuplet = unsmob_spanner (me->get_object ("bracket"));
 
-  Interval positions = robust_scm2interval (tuplet->get_property ("positions"), Interval (0.0, 0.0));
-
-  return scm_from_double (positions.center ());
+  Drul_array<Real> positions = robust_scm2drul (tuplet->get_property ("positions"), Drul_array<Real> (0.0, 0.0));
+  return scm_from_double ((positions[LEFT] + positions[RIGHT]) / 2.0);
 }
 
 MAKE_SCHEME_CALLBACK (Tuplet_number, calc_cross_staff, 1)