From 025f0236ebab947e6fe2047f20b7f74f4cec3fc4 Mon Sep 17 00:00:00 2001 From: Keith OHara Date: Fri, 1 Nov 2013 17:12:33 -0700 Subject: [PATCH] page-layout: nonstaff lines, follow-up commit 7a60a342 --- .../regression/page-spacing-nonstaff-lines-and-markup.ly | 8 +++++++- lily/page-layout-problem.cc | 6 +++--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/input/regression/page-spacing-nonstaff-lines-and-markup.ly b/input/regression/page-spacing-nonstaff-lines-and-markup.ly index 1e26dfe317..1f7f6ef350 100644 --- a/input/regression/page-spacing-nonstaff-lines-and-markup.ly +++ b/input/regression/page-spacing-nonstaff-lines-and-markup.ly @@ -16,6 +16,12 @@ the page layout engine." \new Lyrics \lyricsto "asdf" \lyricmode { a b c d } >> } - \markup "blah blah blah" + \markup "next song" + \score { + << + \new Lyrics \lyricmode {la1 la } + \new Staff \new Voice { a'1 a'1 } + >> + } } diff --git a/lily/page-layout-problem.cc b/lily/page-layout-problem.cc index 95635140bf..5885a66135 100644 --- a/lily/page-layout-problem.cc +++ b/lily/page-layout-problem.cc @@ -652,8 +652,6 @@ Page_layout_problem::append_system (System *sys, Spring const &spring, Real inde : 0; // Corner case: there was only one staff, and it wasn't spaceable. - // Mark it spaceable, because we do not allow non-spaceable staves - // to be at the top or bottom of a system. if (!found_spaceable_staff && elts.size ()) mark_as_spaceable (elts[0]); } @@ -667,7 +665,8 @@ Page_layout_problem::append_prob (Prob *prob, Spring const &spring, Real padding if (sky) { - minimum_distance = (*sky)[UP].distance (bottom_skyline_); + minimum_distance = max ((*sky)[UP].distance (bottom_skyline_), + bottom_loose_baseline_); bottom_skyline_ = (*sky)[DOWN]; } else if (Stencil *sten = unsmob_stencil (prob->get_property ("stencil"))) @@ -678,6 +677,7 @@ Page_layout_problem::append_prob (Prob *prob, Spring const &spring, Real padding bottom_skyline_.clear (); bottom_skyline_.set_minimum_height (iv[DOWN]); } + bottom_loose_baseline_ = 0.0; Spring spring_copy = spring; if (tight_spacing) -- 2.39.5