- Real hw = hd.length ()/4;
- out.add_molecule (Note_head::ledger_lines (me, ledger_take_space, streepjes_i, dir,
- Interval (hd[LEFT] - hw,
- hd[RIGHT] + hw)));
+ Real left_ledger_protusion = hd.length ()/4;
+ Real right_ledger_protusion = left_ledger_protusion;
+
+ if (unsmob_grob(me->get_grob_property ("accidentals-grob")))
+ {
+ /*
+ make a little room for accidentals.
+
+ TODO: this will look silly if a chord has ledger lines,
+ and only the bottom note has an accidental.
+ */
+
+ left_ledger_protusion *= 0.66;
+ right_ledger_protusion *= 0.8;
+ }
+
+ Interval l_extents = Interval (hd[LEFT] - left_ledger_protusion,
+ hd[RIGHT] + right_ledger_protusion);
+ out.add_molecule (Note_head::ledger_lines (me, ledger_take_space,
+ streepjes_i, dir, l_extents));