-----Original Message----- From: David Sumbler <da...@aeolia.co.uk> Reply-To: da...@aeolia.co.uk To: Thomas Morley <thomasmorle...@gmail.com> CC: lilypond-user <lilypond-user@gnu.org> Subject: Re: Line-breaking with non-aligned barlines - again! Date: Mon, 10 Dec 2018 22:58:58 +0000
-----Original Message----- From: Thomas Morley <thomasmorle...@gmail.com> To: David Sumbler <da...@aeolia.co.uk> CC: lilypond-user <lilypond-user@gnu.org> Subject: Re: Line-breaking with non-aligned barlines - again! Date: Mon, 10 Dec 2018 22:00:51 +0100 Well, you could try like below, but it has it's own short-comings: \version "2.19.82" \paper { ragged-right = ##f } harps = { \time 2/4 \scaleDurations 8/11 { b16[ b b b] b[ b b b] \bar "|" \noBreak b[ b b \bar "" } \noBreak \override Staff.TimeSignature.stencil = ##f \time 3/8 \scaleDurations 3/4 { b16] b[ b b b] \bar "|" \noBreak b[ b b \bar "" } \noBreak \time 5/8 \scaleDurations 10/13 { b16] b[ b b b] \bar "|" \noBreak b[ b b b] b[ b b b] } } \score { \new Staff { \time 2/4 \repeat unfold 32 b16 } } \score { \new Staff { \harps } } \score { << \new Staff { \harps } \new Staff { \time 2/4 b4 b | \time 3/8 b4 b8 | \time 5/8 b4 b b8 | } >> \layout { \context { \Score \remove "Timing_translator" \remove "Default_bar_line_engraver" %% !!!!! \override SpacingSpanner.strict-note-spacing = ##t } \context { \Staff \consists "Timing_translator" \consists "Default_bar_line_engraver" } } } I'm not really convinced, thus I didn't post this before... Cheers, Harm -------------------------------------------------------- I was very excited when I saw the output of the above with its one extra line. Although the upper line looked slightly oddly spaced, it would certainly be acceptable in the full score. Unfortunately the real orchestral parts are considerably more complicated than the line of crotchets and quavers I used in the example, and the short-comings of strict-note-spacing became clear: notes in the orchestra were actually being printed over the time signatures. I wondered what would happen if I removed SpacingSpanner from the Score context and added it to Staff. Then, just in the harpsichord part, I could add \override Staff.SpacingSpanner.strict-note-spacing = ##t at the relevant point. Sure enough, the orchestra parts were correctly lined up just as they normally would be; but unfortunately the harpsichord part was also still spaced to conform with them, just as in my original version. But thanks for the suggestion - and it has also directed my attention to some parts of the Lilypond "engine" that I didn't know about previously. David --------------------------------------------------------- Having slept on this, I came up with a new idea. I have changed the crotchets and quavers in the lower part of the example into semiquavers, to illustrate the sort of problem that occurs in the "orchestra" parts using strict-note-spacing. Then I used \scaleDurations to reposition things in that line too. This is the result: \version "2.19.82" \paper { ragged-right = ##f } harps = { \time 2/4 \scaleDurations 8/11 { b16[ b b b] b[ b b b] \bar "|" \noBreak b[ b b \bar "" } \noBreak \override Staff.TimeSignature.stencil = ##f \time 3/8 \scaleDurations 3/4 { b16] b[ b b b] \bar "|" \noBreak b[ b b \bar "" } \noBreak \time 5/8 \scaleDurations 10/13 { b16] b[ b b b] \bar "|" \noBreak b[ b b b] b[ b b b] } } \score { \new Staff { \time 2/4 \repeat unfold 32 b16 } } \score { \new Staff { \harps } } \score { << \new Staff { \harps } \new Staff { \time 2/4 \scaleDurations 11/12 { b16[ b b b] b[ b b } b16*19/12] | \time 3/8 \scaleDurations 8/9 { b16[ b b b b } b16*14/9] | \time 5/8 b16[ b b b b b] b[ b b b] | } >> \layout { \context { \Score \remove "Timing_translator" \remove "Default_bar_line_engraver" \override SpacingSpanner.strict-note-spacing = ##t } \context { \Staff \consists "Timing_translator" \consists "Default_bar_line_engraver" } } } This looks pretty good and the arithmetic is simple, although it could be further tweaked to make it look even better. This may well be the answer I need for my full score. But now that you have introduced me to "strict-note-spacing" etc., I am again wondering whether there might perhaps be a way of getting Lilypond to make 2 separate calculations of spacing, one for the harpsichord and another for the rest of the orchestra; or, in the case of my small example, one for the top stave and one for the bottom. Perhaps this can be done by modifying the stavesFound variable, but I have little idea of how to go about this. David _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user