CVSROOT:        /cvsroot/lilypond
Module name:    lilypond
Branch:         
Changes by:     Han-Wen Nienhuys <[EMAIL PROTECTED]>    05/04/18 12:33:36

Modified files:
        lily           : line-interface.cc 

Log message:
        (make_arrow): new function. Patch by
        Jonatan Liljedahl <http://kymatica.com>
        (arrows): idem.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/line-interface.cc.diff?tr1=1.21&tr2=1.22&r1=text&r2=text

Patches:
Index: lilypond/lily/line-interface.cc
diff -u lilypond/lily/line-interface.cc:1.21 
lilypond/lily/line-interface.cc:1.22
--- lilypond/lily/line-interface.cc:1.21        Mon Apr 18 12:29:24 2005
+++ lilypond/lily/line-interface.cc     Mon Apr 18 12:33:36 2005
@@ -20,16 +20,14 @@
   Real angle = (end - begin).arg();
   Array<Offset> points;
   
-  //construct the arrow
   points.push (Offset (0, 0));
   points.push (Offset (-length, width));
   points.push (Offset (-length, -width));
 
-  // rotate and translate the arrow
   for (int i = 0; i < points.size(); i++)
     points[i] = points[i] * complex_exp (Offset (0, angle)) + end;
     
-  return (Lookup::round_filled_polygon (points, thick));
+  return Lookup::round_filled_polygon (points, thick);
 }
 
 Stencil
@@ -91,8 +89,10 @@
     {
       Real thick = Staff_symbol_referencer::line_thickness (me)
        * robust_scm2double (me->get_property ("thickness"), 1);
-      Real len = robust_scm2double (me->get_property ("arrow-length"), 1.3);
-      Real wid = robust_scm2double (me->get_property ("arrow-width"), 0.5);
+      Real ss =  Staff_symbol_referencer::staff_space (me);
+      
+      Real len = robust_scm2double (me->get_property ("arrow-length"), 1.3 * 
ss);
+      Real wid = robust_scm2double (me->get_property ("arrow-width"), 0.5 * 
ss);
 
       if (to_arrow)
         a.add_stencil (make_arrow (from, to, thick, len, wid));


_______________________________________________
Lilypond-cvs mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/lilypond-cvs

Reply via email to