]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/percent-repeat-item.cc
lilypond-manuals.css: edit color scheme and some spacing
[lilypond.git] / lily / percent-repeat-item.cc
index 1e97753feecd95414538f4847f9613aac0d41b92..6799abc9ca18f253f31be362cc455553f253df59 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 2001--2011  Han-Wen Nienhuys <hanwen@xs4all.nl>
+  Copyright (C) 2001--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
@@ -37,8 +37,8 @@ Percent_repeat_item_interface::brew_slash (Grob *me, int count)
   Stencil slash = Lookup::repeat_slash (wid, slope, thick);
   Stencil m = slash;
 
-  Real slash_neg_kern =
-    robust_scm2double (me->get_property ("slash-negative-kern"), 1.6);
+  Real slash_neg_kern
+    robust_scm2double (me->get_property ("slash-negative-kern"), 1.6);
   for (int i = count - 1; i--;)
     m.add_at_edge (X_AXIS, RIGHT, slash, -slash_neg_kern);
 
@@ -51,8 +51,8 @@ Percent_repeat_item_interface::x_percent (Grob *me, int count)
 {
   Stencil m = brew_slash (me, count);
 
-  Real dot_neg_kern =
-    robust_scm2double (me->get_property ("dot-negative-kern"), 0.75);
+  Real dot_neg_kern
+    robust_scm2double (me->get_property ("dot-negative-kern"), 0.75);
 
   Stencil d1 = Font_interface::get_default_font (me)->find_by_name ("dots.dot");
   Stencil d2 = d1;
@@ -69,7 +69,7 @@ MAKE_SCHEME_CALLBACK (Percent_repeat_item_interface, double_percent, 1);
 SCM
 Percent_repeat_item_interface::double_percent (SCM grob)
 {
-  Grob *me = unsmob_grob (grob);
+  Grob *me = unsmob<Grob> (grob);
   Stencil m = x_percent (me, 2);
   m.translate_axis (-m.extent (X_AXIS).center (), X_AXIS);
   return m.smobbed_copy ();
@@ -79,8 +79,8 @@ MAKE_SCHEME_CALLBACK (Percent_repeat_item_interface, beat_slash, 1);
 SCM
 Percent_repeat_item_interface::beat_slash (SCM grob)
 {
-  Grob *me = unsmob_grob (grob);
-  Stream_event *cause = unsmob_stream_event (me->get_property ("cause"));
+  Grob *me = unsmob<Grob> (grob);
+  Stream_event *cause = unsmob<Stream_event> (me->get_property ("cause"));
   int count = robust_scm2int (cause->get_property ("slash-count"), 1);
 
   Stencil m;
@@ -93,11 +93,11 @@ Percent_repeat_item_interface::beat_slash (SCM grob)
 }
 
 ADD_INTERFACE (Percent_repeat_item_interface,
-              "Repeats that look like percent signs.",
-
-              /* properties */
-              "dot-negative-kern "
-              "slash-negative-kern "
-              "slope "
-              "thickness "
-              );
+               "Repeats that look like percent signs.",
+
+               /* properties */
+               "dot-negative-kern "
+               "slash-negative-kern "
+               "slope "
+               "thickness "
+              );