source file of the GNU LilyPond music typesetter
- (c) 1997--2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ (c) 1997--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
Jan Nieuwenhuizen <janneke@gnu.org>
*/
}
else
{
- /*
- ugh.
-
- can happen in stem-tremolo case.
- TODO: fixme.
- */
- d = Stem::get_default_dir (stems[0]);
+ d = to_dir (stems[0]->get_property ("default-direction"));
}
}
}
}
- return SCM_BOOL_T;
+ return SCM_EOL;
}
/*
if (is_direction (stem_dir_scm))
stem_dir = to_dir (stem_dir_scm);
else
- stem_dir = Stem::get_default_dir (s);
+ stem_dir = to_dir (s->get_property ("default-direction"));
+
+ if (!stem_dir)
+ stem_dir = to_dir (s->get_property ("neutral-direction"));
if (stem_dir)
{
}
Direction dir = CENTER;
-
- if (Direction d = (Direction) sign (count[UP] - count[DOWN]))
+ Direction d = CENTER;
+ if ((d = (Direction) sign (count[UP] - count[DOWN])))
dir = d;
- else if (Direction d = (Direction) sign (total[UP] / count[UP] - total[DOWN]/count[DOWN]))
+ else if (count[UP]
+ && count[DOWN]
+ && (d = (Direction) sign (total[UP] / count[UP] - total[DOWN]/count[DOWN])))
dir = d;
- else if (Direction d = (Direction) sign (total[UP] - total[DOWN]))
+ else if ((d = (Direction) sign (total[UP] - total[DOWN])))
dir = d;
else
dir = to_dir (me->get_property ("neutral-direction"));
/* I can imagine counting those boundaries as a half forced stem,
but let's count them full for now. */
+ Direction defdir = to_dir (s->get_property ("default-direction"));
+
if (abs (Stem::chord_start_y (s)) > 0.1
- && (get_grob_direction (s) != Stem::get_default_dir (s)))
+ && defdir
+ && get_grob_direction (s) != defdir)
f++;
}
return f;
Drul_array<Grob*> visible_stems (first_visible_stem (beam),
last_visible_stem (beam));
-
- Grob *common = visible_stems[RIGHT]
- ->common_refpoint (visible_stems[LEFT], X_AXIS);
+ extract_grob_set (beam, "stems", stems);
+
+ Grob *common = common_refpoint_of_array (stems, beam, X_AXIS);
Real x0 = visible_stems[LEFT]->relative_coordinate (common, X_AXIS);
Real dx = visible_stems[RIGHT]->relative_coordinate (common, X_AXIS) - x0;
"A beam. \n\n"
"The @code{thickness} property is the weight of beams, "
- "measured in staffspace. The @code{direction} property is not user-serviceable. Use "
+ "measured in staffspace. The @code{direction} "
+ "property is not user-serviceable. Use "
"the @code{direction} property of @code{Stem} instead. "
,
/* properties */
"auto-knee-gap "
"beamed-stem-shorten "
+ "beaming "
"break-overshoot "
"chord-tremolo "
"concaveness "