On Fri, 2008-03-07 at 17:59 +1100, Joe Neeman wrote: > On Thu, 2008-03-06 at 13:46 +0000, Mark Knoop wrote: > > I'm trying to use the line-break-penalty property of the > > paper-column-interface to set some preferred line-breaking positions > > (e.g. to prefer a line break at the start of a variation in a set of > > variations, or at a repeat sign). > > > > However I'd prefer not to _force_ a line-break with \break as I want the > > source to be usable for different paper and staff sizes. (LaTeX does > > this well with \linebreak[2], for example.) > > > > I'm using: > > > > \once \override Score.PaperColumn #'line-break-penalty = #-20 > > > > but it doesn't seem to be having any effect. Any ideas? > > There are 3 things I can think of: first, you need to override > Score.NonMusicalPaperColumn instead of Score.PaperColumn (the > PaperColumn contains only notes and other musical objects while the > NonMusicalPaperColumn containes bar lines; line breaks always occur in a > NonMusicalPaperColumn). > > The second thing is something that applies whenever you override a paper > column: the override has to be one timestep _before_ the place where it > takes affect. Don't ask me why. > > And the third thing is that you may want a value smaller than -20. I > used -100 to no effect (admittedly not on a real-world example).
Thanks Joe, I did some more experimenting and have found something that works. Actually the value doesn't have to be very big (-10 works in the following example), but for some reason \once \override doesn't have any effect whereas plain \override followed by \revert does work. \version "2.11.40" \score { { \repeat unfold 12 { c'' c'' c'' c'' } d'' d'' d'' \override Score.NonMusicalPaperColumn #'line-break-penalty = #-10 d'' \revert Score.NonMusicalPaperColumn #'line-break-penalty e''4 e'' e'' e'' \repeat unfold 24 { c'' c'' c'' c'' } } } -- Mark Knoop _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user