]> git.donarmstrong.com Git - lilypond.git/commitdiff
(make_trill): do set_parent also
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 4 Aug 2006 12:35:14 +0000 (12:35 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 4 Aug 2006 12:35:14 +0000 (12:35 +0000)
if no accidental.

ChangeLog
lily/pitched-trill-engraver.cc
scm/output-lib.scm

index 9077c550debfa377e43b313a946f108a1dfda938..7b3d20beac8f3c33958d4e061484a0a24c7d2d4d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2006-08-04  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
+       * lily/pitched-trill-engraver.cc (make_trill): do set_parent also
+       if no accidental.
+
        * lily/accidental-engraver.cc (process_acknowledged): don't create
        accidental for trill span event. This fixes spurious accidentals
        on trills.
index 84e391e231b301647120a5a9da73d00ef34d46d7..b514dfd10158e553744f12fff41e64123db25e4d 100644 (file)
@@ -82,8 +82,7 @@ Pitched_trill_engraver::make_trill (Music *mus)
 
   SCM handle = scm_assoc (key, keysig);
   bool print_acc
-    = (handle == SCM_BOOL_F)
-    || p->get_alteration () == 0;
+    = (handle == SCM_BOOL_F) || p->get_alteration () == 0;
 
   if (trill_head_)
     {
@@ -101,6 +100,7 @@ Pitched_trill_engraver::make_trill (Music *mus)
                                           + c0));
 
   trill_group_ = make_item ("TrillPitchGroup", mus->self_scm ());
+  trill_group_->set_parent (trill_head_, Y_AXIS);
 
   Axis_group_interface::add_element (trill_group_, trill_head_);
 
@@ -112,9 +112,8 @@ Pitched_trill_engraver::make_trill (Music *mus)
       trill_accidental_->set_property ("accidentals", scm_list_1 (scm_from_int (p->get_alteration ())));
       Side_position_interface::add_support (trill_accidental_, trill_head_);
       trill_head_->set_object ("accidental-grob", trill_accidental_->self_scm ());
-      trill_group_->set_parent (trill_head_, Y_AXIS);
-      Axis_group_interface::add_element (trill_group_, trill_accidental_);
       trill_accidental_->set_parent (trill_head_, Y_AXIS);
+      Axis_group_interface::add_element (trill_group_, trill_accidental_);
     }
 }
 
index dbc41d287d22e85f3c563e1ebca9cdbe39a0c858..66ffcb0314b5c3c734d1c0492b9b7f7cd7e79d28 100644 (file)
@@ -289,8 +289,7 @@ centered, X==1 is at the right, X == -1 is at the left."
 
 (define (parenthesize-elements grob . rest)
   (let*
-      (
-       (refp (if (null? rest)
+      ((refp (if (null? rest)
                 grob
                 (car rest)))
        (elts (ly:grob-object grob 'elements))
@@ -300,7 +299,7 @@ centered, X==1 is at the right, X == -1 is at the left."
        (lp (ly:font-get-glyph font "accidentals.leftparen"))
        (rp (ly:font-get-glyph font "accidentals.rightparen"))
        (padding (ly:grob-property grob 'padding 0.1)))
-
+    
     (ly:stencil-add
      (ly:stencil-translate-axis lp (- (car x-ext) padding) X)
      (ly:stencil-translate-axis rp (+ (cdr x-ext) padding) X))