]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/slur.cc (print): only set font-size if not set yet.
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Thu, 6 Apr 2006 00:23:02 +0000 (00:23 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Thu, 6 Apr 2006 00:23:02 +0000 (00:23 +0000)
* lily/slur-configuration.cc (add_score): improved layout of debug
scoring output.

ChangeLog
lily/slur-configuration.cc
lily/slur-scoring.cc
lily/slur.cc
ly/declarations-init.ly
ps/music-drawing-routines.ps

index 80f7fb76fcff81e45edc8c7d871272360bd8528b..8a7142b698862db47d8bb82c233a31abb37ea202 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2006-04-06  Han-Wen Nienhuys  <hanwen@lilypond.org>
+
+       * lily/slur.cc (print): only set font-size if not set yet.
+
+       * lily/slur-configuration.cc (add_score): improved layout of debug
+       scoring output.
+
+2006-04-05  David Feuer  <David.Feuer@gmail.com>
+
+       * music-drawing-routines.ps (draw_round_box): removed testing artifact.
+       (draw_circle): Hopefully fixed regression.
+       Improved documentation for several procedures.
+       
 2006-03-04  Werner Lemberg  <wl@gnu.org>
 
        * ly/engraver-init.ly (\Score): Add beam-event to quotedEventTypes.
@@ -5,7 +18,7 @@
 2006-04-05  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
        * scripts/musicxml2ly.py (bindir): add dynamic
-       relocation. Backportme.
+       relocation. 
 
 2006-04-04  Graham Percival  <gpermus@gmail.com>
 
@@ -26,8 +39,8 @@
        (*SF, stroke_and_fill): new procedures.  Replaced stroke and fill
        with stroke_and_fill throughout.
        (euclidean_length, print_letter, draw_box): Deleted unused
-        procedures.  If someone needs draw_box, implement it using
-        draw_round_box; don't duplicate code.
+       procedures.  If someone needs draw_box, implement it using
+       draw_round_box; don't duplicate code.
        (print_glyphs, draw_round_box, draw_polygon, draw_repeat_slash):
        Refactored/cleaned up interfaces.
        (mark_URI): Moved.
@@ -61,7 +74,7 @@
 2006-04-03  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
        * scm/music-functions.scm (quote-substitute): set
-       iterators-ctor. Backportme.
+       iterators-ctor. 
 
 2006-03-31  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
index cd96fed4e32cd5fc320a6e161b519a609a09576d..3aabe8407da921647f503d701d13f8d2a3c9855e 100644 (file)
@@ -182,7 +182,9 @@ Slur_configuration::add_score (Real s, string desc)
   
   if (s)
     {
-      score_card_ += to_string ("%s=%.2f ", desc.c_str (), s);
+      if (score_card_.length () > 0)
+       score_card_ += ", ";
+      score_card_ += to_string ("%s=%.2f", desc.c_str (), s);
       score_ += s;
     }
 }
@@ -405,7 +407,9 @@ Slur_configuration::score_edges (Slur_score_state const &state)
       demerit *= exp (state.dir_ * d * slope
                      * state.parameters_.edge_slope_exponent_);
 
-      add_score (demerit, "edge");
+
+      string dir_str = d == LEFT ? "L" : "R";
+      add_score (demerit, dir_str + " edge");
     }
   while (flip (&d) != LEFT);
 }
index 77a5a22c0f39903fdac5a94d01de7480ca38a925..f4b312e5bdad78f18f9b3723d7fa55c573b8b0ca 100644 (file)
@@ -383,7 +383,7 @@ Slur_score_state::get_best_curve ()
       if (opt_idx >= 0)
        {
          total = configurations_[opt_idx]->card ();
-         total += to_string ("TOTAL=%.2f idx=%d", configurations_[opt_idx]->score (), opt_idx); 
+         total += to_string (" TOTAL=%.2f idx=%d", configurations_[opt_idx]->score (), opt_idx); 
        }
       else
        {
index e482763a5bff05dd9fb2ba3e7248955e248cce99..16b63bef8dd9d51014a74e2eea969b74b620326e 100644 (file)
@@ -115,8 +115,11 @@ Slur::print (SCM smob)
       string str;
       SCM properties = Font_interface::text_font_alist_chain (me);
 
-      properties = scm_cons (scm_acons (ly_symbol2scm ("font-size"), scm_from_int (-6), SCM_EOL),
-                                properties);
+
+      if (!scm_is_number (me->get_property ("font-size")))
+       properties = scm_cons (scm_acons (ly_symbol2scm ("font-size"), scm_from_int (-6), SCM_EOL),
+                            properties);
+      
       Stencil tm = *unsmob_stencil (Text_interface::interpret_markup
                                    (me->layout ()->self_scm (), properties,
                                     quant_score));
index 7dbc3b3c298c4ebefd8a8a85cc51bf887528d4de..f60c9f4578ba2004ecfe1bbebffe7aefc4711291 100644 (file)
@@ -98,7 +98,6 @@ partCombineListener = \layout {
     }
     \context {
        \Score
-       ignoreQuotes = ##t 
        skipTypesetting = ##t
        ignoreBarChecks = ##t 
     }
index 1ceab9a64bc6efa8aa4326b541ef42974b71191b..35c3d23a55274a49f53a022a1e13a72ce3916e53 100644 (file)
@@ -128,29 +128,18 @@ bind def
 } bind def
 
 /draw_round_box % width height x y blot
-currentdict /testing known
-{{
-       setlinewidth
-       0 setlinecap
-       1 setlinejoin
-       
-       rmoveto
-       currentpoint
-       4 2 roll
-       rectstroke
-}}
-{{
-       setlinewidth
+{
+       setlinewidth % w h x y
        0 setlinecap
        1 setlinejoin
 
-       rmoveto
-       currentpoint
-       4 2 roll
+       rmoveto % w h
+       currentpoint % w h x1 y1
+       4 2 roll % x1 y1 w h
        4 copy
        rectfill
        rectstroke
-}} ifelse bind def
+} bind def
 
 /draw_polygon % fill? x(n) y(n) x(n-1) y(n-1) ... x(0) y(0) n blot
 {
@@ -174,7 +163,7 @@ currentdict /testing known
        } ifelse
 } bind def
 
-/draw_repeat_slash % x-width width height
+/draw_repeat_slash % x-width width height draw_repeat_slash
 {
        2 index % duplicate x-width
        1 setlinecap
@@ -203,7 +192,7 @@ currentdict /testing known
        grestore
 } bind def
 
-/draw_dot % radius x y
+/draw_dot % radius x y draw_dot
 {
        rmoveto
        currentpoint
@@ -211,11 +200,12 @@ currentdict /testing known
        0 360 arc closepath stroke_and_fill
 } bind def
 
-/draw_circle % F R T
+/draw_circle % filled? radius thickness draw_circle
 {
-       setlinewidth
+       setlinewidth    % f? r
+       currentpoint    % f? r x0 y0
+       3 2 roll        % f? x0 y0 r
        dup 0 rmoveto
-       currentpoint 3 2 roll
        0 360 arc closepath
                { stroke_and_fill } 
                { stroke }
@@ -223,22 +213,22 @@ currentdict /testing known
 } bind def
 
 
-/draw_line % dx dy x1 y1 thickness
+/draw_line % dx dy x1 y1 thickness draw_line
 {
-       setlinewidth
+       setlinewidth % dx dy x1 y1
        1 setlinecap
        1 setlinejoin
-       rmoveto
+       rmoveto % dx dy
        rlineto
        stroke
 } bind def
 
-/draw_dashed_line % dx dy thickness dashpattern
+/draw_dashed_line % dx dy thickness dashpattern draw_dashed_line
 {
        1 setlinecap
        1 setlinejoin
-       setdash
-       setlinewidth
+       setdash % dx dy thickness
+       setlinewidth %dx dy
        rlineto
        stroke
 } bind def
@@ -257,12 +247,13 @@ gsave
 grestore
 } bind def
 
-/print_glyphs {
+/print_glyphs % dx dy glyph print_glyphs
+{
        {
-               currentpoint
-               3 2 roll
-               glyphshow
-               moveto
+               currentpoint %dx dy glyph x0 y0
+               3 2 roll %dx dy x0 y0 glyph
+               glyphshow % dx dy x0 y0
+               moveto % dx dy
                rmoveto
        }repeat
 }bind def