2003-01-04 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+ * lily/new-fingering-engraver.cc (position_scripts): use
+ fingerHorizontalDirection to determine fingering horizontal
+ directions.
+
+ * lily/accidental-engraver.cc (acknowledge_grob): add accidental to
+ fingering support.
+
* scripts/convert-ly.py (FatalConversionError.conv): add style
conversion rule.
fermata. This can be corrected by the following property setting
@example
\property Score.RehearsalMark \override
- #'visibility-lambda = #begin-of-line-invisible
+ #'break-visibility = #begin-of-line-invisible
@end example
@cindex fermatas
<< c-1 e-3>> 4
<< c-1 e-3 g-5 >> 4
<< c-1 e-2 g-3 b-5 >> 4
- \property Voice.fingersHorizontal = ##t
- << c-1 e-3 g-5 >> 4
- \property Voice.fingersHorizontal = ##t
- << c-1 e-2 g-3 b-5 >> 4
+ \property Voice.fingerHorizontalDirection = #LEFT
+ << c-1 es-3 g-5 >> 4
+ \property Voice.fingerHorizontalDirection = #RIGHT
+ << c-1 e-2 g-3 b-5 >> 4-\arpeggio
}
#include "engraver.hh"
#include "arpeggio.hh"
#include "warn.hh"
-
#include "translator-group.hh"
/**
Urgh. Since the accidentals depend on lots of variables, we have to
store all information before we can really create the accidentals.
*/
- Link_array<Grob> arpeggios_;
+ Link_array<Grob> left_objects_;
+ Link_array<Grob> right_objects_;
Grob * accidental_placement_;
-
/*
The next
*/
Array<Accidental_entry> accidentals_;
-
Link_array<Grob> ties_;
-
-
};
accidentals.
*/
- for (int i = 0; i < arpeggios_.size (); i++)
- Side_position_interface::add_support (arpeggios_[i], a);
+ for (int i = 0; i < left_objects_.size (); i++)
+ Side_position_interface::add_support (left_objects_[i], a);
+ for (int i = 0; i < right_objects_.size (); i++)
+ Side_position_interface::add_support (a, right_objects_[i]);
}
accidental_placement_ = 00;
accidentals_.clear();
- arpeggios_.clear ();
+ left_objects_.clear ();
+ right_objects_.clear ();
ties_.clear ();
}
}
else if (Arpeggio::has_interface (info.grob_))
{
- arpeggios_.push (info.grob_);
+ left_objects_.push (info.grob_);
+ }
+ else if (info.grob_->internal_has_interface (ly_symbol2scm("finger-interface")))
+ {
+ left_objects_.push (info.grob_);
}
-
}
void
" with note heads), this needs to be in a context higher than Tie_engraver.",
"Accidental",
/* accepts */ "",
- "rhythmic-head-interface tie-interface arpeggio-interface",
+ "finger-interface rhythmic-head-interface tie-interface arpeggio-interface",
"localKeySignature extraNatural autoAccidentals autoCautionaries",
"localKeySignature");
}
fingerings_.sort (&Finger_tuple::compare);
- if (to_boolean (get_property ("fingersHorizontal")))
+ SCM fhd = get_property ("fingerHorizontalDirection");
+
+ if (ly_dir_p (fhd))
{
up.push (fingerings_.pop());
down.push (fingerings_[0]);
f->add_offset_callback (Self_alignment_interface::centered_on_parent_proc, Y_AXIS);
f->add_offset_callback (Self_alignment_interface::aligned_on_self_proc, Y_AXIS);
f->add_offset_callback (Side_position_interface::aligned_side_proc, X_AXIS);
- f->set_grob_property( "direction", gh_int2scm (RIGHT));
+
+ f->set_grob_property( "direction", fhd);
typeset_grob (f);
}
if (fingerings_.size ())
{
position_scripts();
- fingerings_.clear ();
+ fingerings_.clear ();
}
for (int i = articulations_.size(); i--;)
scripts left or right of note heads. Support for this is limited.
Accidentals will collide with scripts.
")
-(translator-property-description 'fingersHorizontal boolean? "Put the middle fingerings to the
-right side of the note head.")
+(translator-property-description 'fingerHorizontalDirection integer?
+ "If set, put the middle fingerings to
+the side of the note head. Use LEFT, RIGHT or unset.")
(translator-property-description 'skipBars boolean? " Set to true to
skip the empty bars that are produced by multimeasure notes and rests.