On Thu, May 26, 2011 at 1:27 AM, Trevor Bača <trevorb...@gmail.com> wrote:

> Hi,
>
> I'm looking to vertically lay out systems in a very rigid and regular way.
> (This is the method I documented a while back in 4.4.2 'Explicit staff and
> system positioning' using the Y-offset and alignment-distances attributes of
> line-break-system-details.) The challenge is that this method produces
> different visual results than it used to now that the new vertical spacing
> code has been added into the system. Examples are the easiest way to show
> the difference.
>
>
> Here's an example of explicit system positioning:
>
> %%% EX 1: EXPLICIT SYSTEM POSITIONING W/ JUMPING STAVES %%%
>
> \version "2.13.61"
>
> \paper {
>    evenHeaderMarkup = \markup \fill-line { " " }
>    indent = #0
>    oddHeaderMarkup = \markup \fill-line { " " }
>    top-margin = 20\mm
> }
>
> \new Staff {
>
>    %%% PAGE 1 %%%%
>
>    \overrideProperty #"Score.NonMusicalPaperColumn"
>    #'line-break-system-details #'((Y-offset . 0))
>    c'1 \pageBreak
>
>    \overrideProperty #"Score.NonMusicalPaperColumn"
>    #'line-break-system-details #'((Y-offset . 0))
>    c''''1
>
> }
>
> %%% END EX 1 %%%
>
> Rendering example 1 shows two pages of music with one system per page. The
> thing to notice is that staves jump around on the page and appear at two
> different vertical positions on the two pages. Lily's visual output in cases
> like this used to be different.
>

Yes, this seems to be something that changed unintentionally with the new
spacing code. I have a patch that gets back the old behaviour, but it has
the disadvantage that it introduces millions of false positives to the
automatic regression checker (the signature-based one, probably not the
pixel-based one).

FWIW, I would consider Carl's solution with top-system-spacing to be
"recommended" for most uses, because it allows you to fix the top system on
each page, but still have lilypond do everything else automatically. But if
you really want to fix the position of every system and you're happy to do
manual breaks and everything, then line-break-system-details 'Y-offset is
still the way to go.

Cheers,
Joe
From 5d673418525d929fe6d520124d84932edf9e97e0 Mon Sep 17 00:00:00 2001
From: Joe Neeman <joenee...@gmail.com>
Date: Fri, 27 May 2011 09:06:27 +0300
Subject: [PATCH] Make the system refpoint the refpoint of its first spaceable
 staff.

Apparently this used to be the default, but the new spacing code
changed the system refpoint to be the top of the tallest grob
in the system.  If the system refpoint is the refpoint of its
first spaceable staff, it is easier to do manual page layouts.
---
 lily/page-layout-problem.cc |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/lily/page-layout-problem.cc b/lily/page-layout-problem.cc
index fa4bd9c..507b7c4 100644
--- a/lily/page-layout-problem.cc
+++ b/lily/page-layout-problem.cc
@@ -488,11 +488,8 @@ Page_layout_problem::find_system_offsets ()
 	  // that it is consistent with the usual up/down sign conventions in
 	  // Lilypond. Then this would be less confusing.
 
-	  // These two positions are relative to the page (with positive numbers being
-	  // down).
-	  Real first_staff_position = solution_[spring_idx];
-	  Real first_staff_min_translation = elements_[i].min_offsets.size () ? elements_[i].min_offsets[0] : 0;
-	  Real system_position = first_staff_position + first_staff_min_translation;
+	  // These is relative to the page (ie. positive numbers are down).
+	  Real system_position = solution_[spring_idx];
 
 	  // Position the staves within this system.
 	  Real translation = 0;
-- 
1.7.5.2

_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to