g4.~ g8-\fermata g8 g |
as4 as8 g4 g8 |
fis4 fis8 r8 g g |
- a4 a8 g4 g8 |
+ a!4 a8 g4 g8 |
fis4 fis8 d'16[ c b a] g[ f] |
e4 g8 d4 g8 e4 r8 b'16[ c d b] g[ f] |
e4 g8 d4 a'16[ g] |
}
pianoLH = \notes \relative c'' \repeat volta 2 {
-
+ \modernAccidentals
g16( fis a g fis g f e d c b a) |
\clef bass g4.( c,8) r r
\clef treble r4 <bes' c>8([ <a c>)] r <f c'> |
\new PianoStaff <<
\property PianoStaff.instrument = \markup {
\bold
- \bigger\bigger \huge "2. " }
+ \bigger\bigger\bigger\bigger \huge "2. " }
\new Staff \pianoRH
\new Staff \pianoLH
>>
const int MUSICAL_DIRECTION_FACTOR = 400;
const int IDEAL_SLOPE_FACTOR = 10;
+const Real ROUND_TO_ZERO_SLOPE = 0.05;
const int ROUND_TO_ZERO_POINTS = 4;
extern bool debug_beam_quanting_flag;
bool xstaff)
{
Real dy = yr - yl;
-
Real dem = 0.0;
/*
DAMPING_DIRECTION_PENALTY is a very harsh measure, while for
complex beaming patterns, horizontal is often a good choice.
+
+ TODO: find a way to incorporate the complexity of the beam in this
+ penalty.
*/
- if (sign (dy)
+ if (fabs (dy/dx) > ROUND_TO_ZERO_SLOPE
&& sign (dy_damp) != sign (dy))
{
dem += DAMPING_DIRECTION_PENALTY;
almost zero slopes look like errors in horizontal beams.
*/
if (fabs (dy) > 1e-3
- && (dy / dx < 0.05))
+ && fabs (dy / dx) < ROUND_TO_ZERO_SLOPE)
dem += ROUND_TO_ZERO_POINTS;
return dem;
Link_array<Grob> heads (Pointer_group_interface__extract_grobs (me, (Grob*)0,
"heads"));
+ if (!heads.size ())
+ return SCM_EOL;
+
common = common_refpoint_of_array (heads, common, X_AXIS);
Real left_point = 0.0;
- if (!heads.size()
- || l->internal_has_interface (ly_symbol2scm ("lyric-syllable-interface")))
+ if (l->internal_has_interface (ly_symbol2scm ("lyric-syllable-interface")))
left_point = l->extent (common, X_AXIS)[RIGHT];
else
left_point = heads[0]->extent (common, X_AXIS)[LEFT];
Real right_point
= left_point + (gh_number_p (minlen) ? gh_scm2double (minlen) : 0.0);
- if (heads.size ())
- right_point = right_point >? heads.top ()->extent (common, X_AXIS)[RIGHT];
+ right_point = right_point >? heads.top ()->extent (common, X_AXIS)[RIGHT];
Real h = sl * gh_scm2double (me->get_grob_property ("thickness"));
-
- right_point = right_point <? (r->extent (common, X_AXIS)[LEFT] - h);
+ Real pad = 2* h;
+ right_point = right_point <? (r->extent (common, X_AXIS)[LEFT] - pad);
if (isinf (right_point))
return SCM_EOL;
- right_point += h;
+ right_point += pad;
Real w = right_point - left_point;