Am Di., 11. Dez. 2018 um 13:56 Uhr schrieb David Sumbler <[email protected]>:
> 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.
I doubt.
Here a hack, hackish as hackish could be. with the need to do a
plethora of manual adjustments. Fragile like hell and with a lot of
limitations.
And _very_ expensive. You'll experience a slow-down even in the small example.
I can't recommend to use it --- but, well, here you are (also, see
inline comments):
\version "2.19.82"
\paper {
%% indent needs to be zero
indent = 0
}
#(define val -1)
sc =
\score {
{
\repeat unfold 20 { a'16 b' c' d'' }
\break
\repeat unfold 4 { a'16 b' c' d'' }
}
\layout {
%% indent needs to be zero
indent = 0
\omit Score.BarNumber
}
}
m = {
\time 2/4 b4 b
\time 3/8 b4 b8
\time 6/8 b4. b4 b8
\break
\time 5/8 b2 b8
\time 2/4 \repeat unfold 8 b16
\break
\time 8/8 b1 b
}
<<
\new Staff
\with {
%% Probably needs to be adjusted
\override VerticalAxisGroup.staff-staff-spacing =
#'((basic-distance . 12)
(minimum-distance . 18)
(padding . 1))
}
\m
\new Lyrics
\lyricmode {
\override LyricText.after-line-breaking =
#(lambda (grob)
(set! val (1+ val))
(let* ((paper-score
(ly:score-embedded-format
sc
(ly:grob-layout grob)))
(pap-sys-vector
(ly:paper-score-paper-systems paper-score))
(pap-sys-ls
(vector->list pap-sys-vector))
(pap-sys-stils
(map
(lambda (pap-sys)
(ly:prob-property pap-sys 'stencil))
pap-sys-ls)))
(ly:grob-set-property! grob 'stencil (list-ref pap-sys-stils val))))
%% Likely this has to be repeated frequently with adjusted values
\override LyricText.before-line-breaking =
#(lambda (grob) (ly:grob-translate-axis! grob -8.6 X))
%% Always need to adjust the duration, it needs to be the duration
%% of the line of music above (or below)
\withMusicProperty #'duration #(ly:make-duration 3 0 13)
"foo"
\withMusicProperty #'duration #(ly:make-duration 3 0 9)
"foo"
\withMusicProperty #'duration #(ly:make-duration 3 0 16)
"foo"
}
\new Staff \m
>>
Cheers,
Harm
_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user