Re: ragged-bottom and spacing for individual pages
Hi Paul, I have a separate voice where I put all my breaks and pageBreaks. I haven't been able to make a blank markup. TIA on how to do that. e.g.: \version "2.25.1" \paper { indent = 0 ragged-bottom = ##f } { \repeat unfold 2 { c'1 \break c'1 \pageBreak } c'1 \break c'1-\tweak padding 132 _\markup " " \pageBreak \repeat unfold 2 { c'1 \break c'1 \pageBreak } } Hope that helps! Kieren.
Re: ragged-bottom and spacing for individual pages
On 3/20/24 12:44 PM, Kieren MacMillan wrote: Hi Paul, 1. How can I cause an individual page other than the last page of a score to have ragged-bottom? As far as I know, you can’t… To fake that behaviour, I usually just inject an appropriately-sized blank markup below the last system I want on a given page (attached to anything in that system, e.g., the last BarLine). Sounds great! I have a separate voice where I put all my breaks and pageBreaks. I haven't been able to make a blank markup. TIA on how to do that. Paul
Re: ragged-bottom and spacing for individual pages
Hi Paul, > 1. How can I cause an individual page other than the last page of a score to > have ragged-bottom? As far as I know, you can’t… To fake that behaviour, I usually just inject an appropriately-sized blank markup below the last system I want on a given page (attached to anything in that system, e.g., the last BarLine). Hope that helps! Kieren. __ My work day may look different than your work day. Please do not feel obligated to read or respond to this email outside of your normal working hours.
Re: ragged-bottom and spacing for individual pages
On Wed, 20 Mar 2024 at 19:47, Paul Scott wrote: > > 1. How can I cause an individual page other than the last page of a > score to have ragged-bottom? Hello, I don't think this is possible. Personally I would produce 2 different PDFs and then split and merge the pages as desired. > 2. How can I change the vertical spacing for a page that uses raged-bottom? For a ragged-bottom score the usual variables can be used: system-system-spacing, top-system-spacing, last-bottom-spacing and within-system spacing properties. You could use as well Explicit staff and system positioning, see NR 4.4.2. Kind regards, Xavier
ragged-bottom and spacing for individual pages
1. How can I cause an individual page other than the last page of a score to have ragged-bottom? 2. How can I change the vertical spacing for a page that uses raged-bottom? TIA, Paul
Re: How to use define-music-function?
On 2024-03-20 8:53 am, enejati--- via LilyPond user discussion wrote: Hello, I'm a new lilypond user. I want to create multiple scores in a single file. These scores have some values on common. So I want to use `define-music-function` in order to avoid repetition. [ . . . ] A few things. Firstly, you must prefix make-score with a slash, just like any other music function. Secondly, define-music-function is not structured the same as Scheme's define. The procedure name will go outside: myFunction = #(define-music-function (arg1 arg2) (type? type?) ...) Lastly, a music function must return what LilyPond considers music. Top-level things like a \score or \book will not count. Instead, what you will need is define-void-function, which does not return anything. Within this function, you can call the internal functions for processing scores and books directly: make-score = #(define-void-function (instrumentName bookSuffix musicContent) (string? string? ly:music?) (toplevel-score-handler #{ \score { \new Staff \with { instrumentName = #instrumentName } { #musicContent } \layout { } } #}) (toplevel-book-handler #{ \book { \bookOutputSuffix #bookSuffix \score { \new Staff \with { midiInstrument = "piccolo" } { #musicContent } \midi { \tempo 4 = 80 } } } #})) % Usage \make-score "۱" "1" { b'4 4 2 } \make-score "۲" "2" { b'4 4 2 } \make-score "3" "3" { b'4 4 2 } -- Aaron Hill
Re: Troubles with StaffGrouper
Ah wonderful thanks! So basically what was happening is that a global VericalAxisGroup will override the StaffGrouper, and so I needed to only locally change the VerticalAxisGroup. Then the StaffGrouper actually worked! On Wed, Mar 20, 2024 at 1:38 AM Xavier Scheuer wrote: > On Wed, 20 Mar 2024 at 04:48, Ben Bradshaw > wrote: > > > > Hello, > > I think I must not be understanding how the StaffGrouper works. I'm > doing a score with instrument and piano accompaniment, and have the piano > music in a PianoStaff. I'm trying to get more space between the solo staff > and the piano staff. This is what I tried... > > > > \layout{ > > \context { > > \Score > > \override VerticalAxisGroup.staff-staff-spacing.minimum-distance = #14 > > \override StaffGrouper.staff-staff-spacing.minimum-distance = #6 > > } > > > > But it seems the StaffGrouper spacing isn't applied, and what I get is > big space between all three lines. I thought that the StaffGrouper was > supposed to override settings in the VerticalAxisGroup, but maybe I have to > do it a different way? Any help would be greatly appreciated. > > Hello, > > Well, apparently that's the case if you don't change the default values of > VerticalAxisGroup.staff-staff-spacing (maybe that's a bug). > In your case I would change the value of > VerticalAxisGroup.staff-staff-spacing for the staff above the PianoStaff. > > \score { > << > \new Staff \with { > \override VerticalAxisGroup.staff-staff-spacing = #'((basic-distance > . 12) > (minimum-distance . 11) > (padding . 1)) > } { c'1 } > \new PianoStaff << > \new Staff { c'1 } > \new Staff { c'1 } > >> > >> > } > > Kind regards, > Xavier > >
How to use define-music-function?
Hello, I'm a new lilypond user. I want to create multiple scores in a single file. These scores have some values on common. So I want to use `define-music-function` in order to avoid repetition. Here is my code now: \score { \new Staff \with { instrumentName = "۱" } \one \layout { } } \book { \bookOutputSuffix "1" \score { \new Staff \with { midiInstrument = "piccolo" } \one \layout { } \midi { \tempo 4=80 } } } \score { \new Staff \with { instrumentName = "۲" } \two \layout { } } \book { \bookOutputSuffix "2" \score { \new Staff \with { midiInstrument = "piccolo" } \two \midi { \tempo 4=80 } } } \score { \new Staff \with { instrumentName = "۳" } \three \layout { } } \book { \bookOutputSuffix "3" \score { \new Staff \with { midiInstrument = "piccolo" } \three \midi { \tempo 4=80 } } } I tried to make a generator function something like this: #(define-music-function (make-score instrumentName bookSuffix musicContent) (string? string? ly:music?) #{ \score { \new Staff \with { instrumentName = $instrumentName } $musicContent \layout { } } \book { \bookOutputSuffix $bookSuffix \score { \new Staff \with { midiInstrument = "piccolo" } $musicContent \midi { \tempo 4=80 } } } #}) % Usage make-score "۱" "1" \one make-score "۲" "2" \two make-score "3" "3" \three However I stumbled upon the following error which I can't make a sense of: error: syntax error, unexpected STRING, expecting '.' or '=' make-score "۱ " "1" \one -- Ebrahim Nejati https://nejati.net Key: rsa4096/0xDB2CBC2428686000
Re: Troubles with StaffGrouper
On Wed, 20 Mar 2024 at 04:48, Ben Bradshaw wrote: > > Hello, > I think I must not be understanding how the StaffGrouper works. I'm doing a score with instrument and piano accompaniment, and have the piano music in a PianoStaff. I'm trying to get more space between the solo staff and the piano staff. This is what I tried... > > \layout{ > \context { > \Score > \override VerticalAxisGroup.staff-staff-spacing.minimum-distance = #14 > \override StaffGrouper.staff-staff-spacing.minimum-distance = #6 > } > > But it seems the StaffGrouper spacing isn't applied, and what I get is big space between all three lines. I thought that the StaffGrouper was supposed to override settings in the VerticalAxisGroup, but maybe I have to do it a different way? Any help would be greatly appreciated. Hello, Well, apparently that's the case if you don't change the default values of VerticalAxisGroup.staff-staff-spacing (maybe that's a bug). In your case I would change the value of VerticalAxisGroup.staff-staff-spacing for the staff above the PianoStaff. \score { << \new Staff \with { \override VerticalAxisGroup.staff-staff-spacing = #'((basic-distance . 12) (minimum-distance . 11) (padding . 1)) } { c'1 } \new PianoStaff << \new Staff { c'1 } \new Staff { c'1 } >> >> } Kind regards, Xavier