dim.set_minimum_height (0.0);
}
- // Ditto - seems kludgy, but this time logic of SystemStartBrackets
- if (my_dim.is_empty ())
- {
- my_dim = Skyline (my_dim.direction ());
- my_dim.set_minimum_height (isinf (max_raise) ? 0.0 : max_raise);
- }
-
// Many cross-staff grobs do not have good height estimations.
// We give the grob the best chance of not colliding by shifting
// it to the maximum height in the case of cross-staff alignment.
? Interval (-infinity_f, infinity_f)
: me->maybe_pure_extent (me, Y_AXIS, pure, beg, end);
- // In horizontal spacing, there are grobs like SystemStartBracket
- // that take up no vertical spcae. So, if the y extent is empty,
- // we use the entire Y extent ot make the X a sort of horizontal wall.
- // Ditto for vertical spacing and grobs like BassFigureAlginmentPositioning.
- if (a == Y_AXIS && yex.is_empty ())
- yex.set_full ();
-
- if (a == X_AXIS && xex.is_empty ())
- xex.set_full ();
-
if (xex.is_empty () || yex.is_empty ())
return Skyline_pair ().smobbed_copy ();
Grob *me = unsmob_grob (smob);
int beg = robust_scm2int (begscm, 0);
int end = robust_scm2int (endscm, INT_MAX);
+ // We cannot measure the width of a spanner before line breaking,
+ // so we assume that the width is infinite.
return maybe_pure_internal_simple_skylines_from_extents (me, X_AXIS, true, beg, end, dynamic_cast<Spanner *> (me), false);
}
Grob *me = unsmob_grob (smob);
int beg = robust_scm2int (begscm, 0);
int end = robust_scm2int (endscm, INT_MAX);
+ // If the grob is cross staff, we cannot measure its Y-extent before
+ // wayyyy downstream (after spacing of axis groups is done).
+ // Thus, we assume that the Y extent is infinite for cross staff grobs.
return maybe_pure_internal_simple_skylines_from_extents (me, Y_AXIS, true, beg, end, false, to_boolean (me->get_property ("cross-staff")));
}
Grob::simple_horizontal_skylines_from_extents (SCM smob)
{
Grob *me = unsmob_grob (smob);
+ // See comment in function above.
return maybe_pure_internal_simple_skylines_from_extents (me, Y_AXIS, false, 0, 0, false, to_boolean (me->get_property ("cross-staff")));
}
(padding . 0.2)
(positioning-done . ,ly:align-interface::align-to-minimum-distances)
(stacking-dir . ,DOWN)
+ (X-extent . ,ly:axis-group-interface::width)
(Y-extent . ,axis-group-interface::height)
(meta . ((class . Spanner)
(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
(padding . 0.5)
(side-axis . ,Y)
(staff-padding . 1.0)
+ (X-extent . ,ly:axis-group-interface::width)
(Y-extent . ,axis-group-interface::height)
(Y-offset . ,side-position-interface::y-aligned-side)
(meta . ((class . Spanner)
(adjacent-pure-heights . ,ly:axis-group-interface::adjacent-pure-heights)
(axes . (,Y))
(vertical-skylines . ,ly:axis-group-interface::calc-skylines)
+ (X-extent . ,ly:axis-group-interface::width)
(Y-extent . ,axis-group-interface::height)
(meta . ((class . Spanner)
(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
(collapse-height . 5.0)
(direction . ,LEFT)
+ (cross-staff . #t)
;; ugh--hardcoded.
(padding . -0.1) ;; bar must cover rounded ending of staff line.
(stencil . ,ly:system-start-delimiter::print)
(collapse-height . 5.0)
(direction . ,LEFT)
(font-encoding . fetaBraces)
+ (cross-staff . #t)
(padding . 0.3)
(stencil . ,ly:system-start-delimiter::print)
(style . brace)
. (
(collapse-height . 5.0)
(direction . ,LEFT)
+ (cross-staff . #t)
(padding . 0.8)
(stencil . ,ly:system-start-delimiter::print)
(style . bracket)
(SystemStartSquare
. (
(direction . ,LEFT)
+ (cross-staff . #t)
(stencil . ,ly:system-start-delimiter::print)
(style . line-bracket)
(thickness . 1.0)