Re: 4 hands piano pieces book
Greetings David, In fact, your process of determining pagebreaks is exactly what I do. I choose to write the breaks directly into my files. It's just a personal preference as I have never been fond of global settings or variables. On the subject of pdftk, I miswrote: it is the "shuffle" option which is used, like this: pdftk A=even.pdf B=odd.pdf shuffle A B output collated.pdf Or, mor practically, pdftk A=Secondo.pdf B=Primo.pdf shuffle A B output PerformanceScore.pdf VERY easy and straightforward. Hwaen Ch'uqi On 5/9/16, David Wrightwrote: > On Mon 09 May 2016 at 14:35:17 (-0400), Hwaen Ch'uqi wrote: >> I have been wwriting A LOT of four-hand music, and I agree in >> principle with most of what I have read in this thread. Even so, I >> thought to chime in with my approach. > > I bow to your experience... > >> In my experience, I have found that there can be no "master file" used >> for determining page breaks, due to the lovely but unpredictable way >> that LilyPond lays out pages. So this must still be done by trial and >> error. I do, however, use the Secondo file in the end as a "master" >> for generating a Table of Contents. > > ... but that *sounds* a bit hit-or-miss. Can you find fault with the > following? > > Set primo and secondo separately. Examine pairs of pages starting at > the beginning. If the page break occurs at the same bar, insert a > \pageBreak at that point in your master variable. Once you meet a > discrepancy, insert the \pageBreak at the earlier position. Rerun > LP. Re-examine from where you left off. > > (I don't know where the "master file" concept came in. However, you > certainly want a master *variable*, rather than inserting the page > breaks into the source at two different places.) > >> Finally, I also use pdftk to produce the full book, but the process >> outlined earlier can be extremely streamlined if you use the "collate" >> feature. You do not need to burst the files into separate pages; pdftk >> will automatically alternate the pages when combining the two files. > > Sorry not to suggest the collate option; I forget it exists because I > never use it, the reason being that I typically don't build files > from mere pairs of L and R pages, but from scanned pages which have > needed masking at the margins. I put different masked/offset copies > into different directories, then move the best version of each page > into the assembly-directory. Everything's quick and easy to that > point, but the final collation has to be done manually. I find > moving pages in Midnight Commander less error-prone even than using > page-ranges in pdftk. > > Cheers, > David. > ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Placing a section name at the start of a staff
On Mon 09 May 2016 at 16:52:44 (+0100), Wols Lists wrote: > On 08/05/16 21:30, David Wright wrote: > > On Sun 08 May 2016 at 19:06:27 (+0100), Anthonys Lists wrote: > >> Basically, I want to do pretty much what "instrument name" does in a > >> score - I want to put the name of the section in front of the start > >> of the staff. The problem is, as always, when you use a feature for > >> what it's not intended for, you can get unexpected side effects. > >> I've got four sections, so that'll mean four \score's. Will I get > >> unexpected (read - unwanted) headers between the scores? Basically, > >> if you don't notice the section name, you shouldn't realise that the > >> music doesn't just flow on. > > > > I don't foresee any issues. Have you not tried it? > > I have memories of the header code sticking stuff at the start of a > score part ... things like the section name :-) ... exactly what I don't > want to happen. I haven't tried that approach just yet, as it's majorly > different from my normal style of doing things. Reading the manual saves you having to remember everything. Read 3.2 Titles and headers. > >> My other approach to doing this sort of thing is "\stopStaff > >> \cadenzaOn ... \cadenzaOff \startStaff" but will this suppress > >> things like key signature etc at the start of the line? My initial > >> experiments in that respect haven't worked, although it seems > >> obvious to me why. But I don't want to carry on down that route if > >> it's going to turn into a rabbit's warren of tweaks and fixes to get > >> right. > > > > Without an example of whay you've done, I wouldn't like to comment. > > It seems more complicated. > > I use it to put text in the middle of a piece usually - some scores > break the part and put the word "Coda" in the middle, or in my most > recent case, "extended cadenza". I just expect if I try it at the start > of a piece, it's likely to collide with a lot of the stuff lilypond > "just does" for you. Well, if you've actually done it, then it should be simple to do again for the new case, ie the start of a piece. Or is it that you just want somebody to do it for you and then report back on what they find? > >> How do other people deal with section names? Especially, how do you > >> do it like the score I'm copying - at the start of the line ... > > > > I don't know what the score you're copying looks like. I think we've > > been here before... > > > I'm not a visual person - I tend to describe things as text ... I was > hoping someone who's done something similar would chime in - I would > expect them to recognise the description if they have. I don't like > repurposing stuff meant to be used otherwise - lily normally expects the > section name to be *above* the score part, as part of the header, iirc. What sort of reasoning is that? If you repurpose something successfully and report back on it, there's a chance that your case will be folded into the software. It may even happen that a generalisation is discovered that had been originally missed. † > And the instrument name normally doesn't change several times per part > ... :-) so if I put the section name in the instrument variable I'm not > expecting it work exactly as I would like ... and it'll probably come > with unwanted surprises. Use the short name; that can be changed on the fly. I use it when the number of staves changes so that singers know which line is theirs. † 1) It used to give me great satisfaction to sit down with a user of my software and watch them do things with it that I had never designed it for. It their methodology was not straightforward, I would then redesign things to make it easier and more efficient (which is why I sat with them in the first place). † 2) A picture is worth a thousand words. Cheers, David. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: 4 hands piano pieces book
On Mon 09 May 2016 at 14:35:17 (-0400), Hwaen Ch'uqi wrote: > I have been wwriting A LOT of four-hand music, and I agree in > principle with most of what I have read in this thread. Even so, I > thought to chime in with my approach. I bow to your experience... > In my experience, I have found that there can be no "master file" used > for determining page breaks, due to the lovely but unpredictable way > that LilyPond lays out pages. So this must still be done by trial and > error. I do, however, use the Secondo file in the end as a "master" > for generating a Table of Contents. ... but that *sounds* a bit hit-or-miss. Can you find fault with the following? Set primo and secondo separately. Examine pairs of pages starting at the beginning. If the page break occurs at the same bar, insert a \pageBreak at that point in your master variable. Once you meet a discrepancy, insert the \pageBreak at the earlier position. Rerun LP. Re-examine from where you left off. (I don't know where the "master file" concept came in. However, you certainly want a master *variable*, rather than inserting the page breaks into the source at two different places.) > Finally, I also use pdftk to produce the full book, but the process > outlined earlier can be extremely streamlined if you use the "collate" > feature. You do not need to burst the files into separate pages; pdftk > will automatically alternate the pages when combining the two files. Sorry not to suggest the collate option; I forget it exists because I never use it, the reason being that I typically don't build files from mere pairs of L and R pages, but from scanned pages which have needed masking at the margins. I put different masked/offset copies into different directories, then move the best version of each page into the assembly-directory. Everything's quick and easy to that point, but the final collation has to be done manually. I find moving pages in Midnight Commander less error-prone even than using page-ranges in pdftk. Cheers, David. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: format-mark function for A, B, C, …, X, Y, Z, Aa, Bb, Cc, …
Am 16.08.2015 um 22:00 schrieb Thomas Morley: 2015-08-16 21:21 GMT+02:00 Malte Meyn: Hi list, sometimes there are more than 25 or 26 rehearsal marks in a piece. LilyPond’s format-mark-(alphabet|letters) function and friends continue after X, Y, Z with AA, AB, AC, … I have never seen this in printed scores. Instead all scores I’ve seen continue with doubled letters (the second lowercase): Aa, Bb, Cc. And once I’ve even seen … Yy, Zz, Aaa, Bbb, … I made functions format-mark-(alphabet|letter)-var and boxed and circled variants which implement this behaviour (see attached patch). So now I would like to know: Is there an interest in having this behaviour in LilyPond (maybe as a variant)? Or have you seen something similar (f. e. everything uppercase)? If so, how to name these functions? And would I have to post this to bug- or dev-list? They’re not perfect yet, for example I didn’t know how to use vector-map ;) Or is this something for openlilylib instead of original LilyPond? Malte Hi Malte, you could discuss on -devel. Maybe I'd let the patch discuss after it is part of the usual review process. I.e. issue created, patch uploaded. I don’t have the time to discuss this and make a patch but if anyone is interested: Some time ago I implemented a single markFormatter function which can do this and some other things (roman numbers, oval frames, lowercase/mixed case marks). \version "2.19.40" #(set-global-staff-size 18) #(define mark-alphabets `((alphabet . ,(list->vector (string->list "ABCDEFGHIJKLMNOPQRSTUVWXYZ"))) (omit-i . ,(list->vector (string->list "ABCDEFGHJKLMNOPQRSTUVWXYZ"))) (omit-j . ,(list->vector (string->list "ABCDEFGHIKLMNOPQRSTUVWXYZ") #(define (mark-generic-string number alphabet uppercase? repeat?) (let* ((the-alphabet (assq-ref mark-alphabets alphabet)) (the-alphabet-length (vector-length the-alphabet)) (the-string (if repeat? (let ((the-length (1+ (quotient (1- number) the-alphabet-length))) (the-index (remainder (1- number) the-alphabet-length))) (make-string the-length (vector-ref the-alphabet the-index))) (let loop ((num (1- number))) (if (< num the-alphabet-length) (string (vector-ref the-alphabet num)) (string-append (loop (1- (quotient num the-alphabet-length))) (loop (remainder num the-alphabet-length (if uppercase? the-string (string-capitalize the-string #(define-markup-command (mark-generic layout props number alphabet uppercase? repeat?) (integer? symbol? boolean? boolean?) #:category other (ly:text-interface::interpret-markup layout props (mark-generic-string number alphabet uppercase? repeat?))) #(define (format-mark-generic alphabet framed bold? uppercase? repeat?) (lambda (number context) (let* ((the-string (case alphabet ((barnumbers) (number->string (ly:context-property context 'currentBarNumber))) ((arabic) (number->string number)) ((roman) (if uppercase? (format #f "~@r" number) (string-downcase (format #f "~@r" number (else (make-mark-generic-markup number alphabet uppercase? repeat? (the-framed-string (case framed ((box) (make-box-markup the-string)) ((circle) (make-circle-markup the-string)) ((oval) (make-oval-markup the-string)) ((#f) the-string (if bold? (make-bold-markup the-framed-string) the-framed-string \paper { indent = 0 ragged-last = ##f ragged-last-bottom = ##f score-system-spacing.basic-distance = 5 } \header { title = "format-mark-generic" subtitle = "a versatile markFormatter function" composer = "Malte Meyn" } foo = { R1 \mark 1 R \mark 8 R \mark 9 R \mark 10 R \mark 26 R \mark 27 R \mark 28 R \mark 52 R \mark 53 R } \markup "Use barnumbers, â¦" \new Score \with { markFormatter = #(format-mark-generic 'barnumbers #f #t '() '()) } \foo \markup "⦠arabic numbers, â¦" \new Score \with { markFormatter = #(format-mark-generic 'arabic #f #t '() '()) } \foo \markup "⦠roman numbers, â¦" \new Score \with { markFormatter = #(format-mark-generic 'roman #f #t #t '()) } \foo \markup "⦠or the latin alphabet (optionally omitting either I or J), â¦" \new Score \with { markFormatter = #(format-mark-generic 'alphabet #f #t #t #f) } \foo \new Score \with { markFormatter = #(format-mark-generic 'omit-i #f #t #t #f) } \foo \new Score \with { markFormatter = #(format-mark-generic 'omit-j #f #t #t #f) } \foo \markup "⦠combine letters after Z (as shown above) or use repeated letters, â¦" \new Score \with { markFormatter =
Re: \keepWithTag #'A {\keepWithTag #'B \music}
Dear David you wrote: [separating midi/layout] > I had wondered whether writing such things as "M" in the score would > make the midi sound bad, but T (H. S. Teoh) effectively answered that > question with some of his/her own examples. [...] Yes, the "M" markup would not be a problem: midi output is not affected by this. But as Teoh explains midi and layout sometimes need to be a bit "fixed". For example in the standard bass accordion notation the chords in the score are not written using the chord name nor specifying all the chord notes. The notation is just to write the root note in a specific position of the staff. On the other hand the midi output of this single note have to be a chords. That's why I need to separate the midi output from the screen output. Thanks again for you help David!! g. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Placing a section name at the start of a staff
2016-05-09 17:52 GMT+02:00 Wols Lists: > I'm not a visual person - I tend to describe things as text Well, as a non-native-speaker long describing texts without code (and image(s)) are always hard to understand for me and I tend to ignore those mails. As an (tiny) example: what is a > section name ? It's not a LilyPond-naming. I'd guess it's the book(part)-header, though you said, no, it isn't. So what? If you like to answer, please don't post a longish description. I'll probably not read it. If I read I'll probably not understand. If I actually read _and_ understood, it may very well be bedtime for me. So no reply from me... Post some code. Maybe with the remark "I'd prefer not how it is done here, but: "...whatever..." Post or link an image where it's done as you prefer. -Harm ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: 4 hands piano pieces book
Am 9. Mai 2016 20:50:05 MESZ, schrieb Hwaen Ch'uqi: >THAT would be brilliant! > >Hwaen Ch'uqi > Please (Alberto and Hwaen) send me a reminder in two weeks if necessary. I'll be attending a conference and may fail keeping this in mind until then. Best Urs > >On 5/9/16, Urs Liska wrote: >> >> >> Am 9. Mai 2016 20:35:17 MESZ, schrieb Hwaen Ch'uqi > : >>>Greetings Alberto, >>> >>>I have been wwriting A LOT of four-hand music, and I agree in >>>principle with most of what I have read in this thread. Even so, I >>>thought to chime in with my approach. As has been advised, I create >>>two separate book files, one for Secondo and one for Primo. The top >of >>>each file is headed with the following: >>> >>>#(define-markup-command (four-hand-page layout props offset) >(number?) >>> (let* ( >>>(two-hand (chain-assoc-get 'page:page-number-string props)) >>>(four-hand (number->string (+ offset (* 2 (string->number >>>two-hand)) >>>(interpret-markup layout props four-hand))) >>> >>>Then, in the \paper block, I include the following for the Secondo >>>part: >>> >>>oddHeaderMarkup = \markup \fill-line { >>> \four-hand-page #0 >>> " " >>>} >>>evenHeaderMarkup = ##f >>> >>>Or, for the Primo part: >>> >>>oddHeaderMarkup = \markup \fill-line { >>> " " >>> \four-hand-page #1 >>>} >>>evenHeaderMarkup = ##f >>> >>>In this way, each part will begin with the correct page number, and >>>the numbering will increase by two automatically. >>> >>>In my experience, I have found that there can be no "master file" >used >>>for determining page breaks, due to the lovely but unpredictable way >>>that LilyPond lays out pages. So this must still be done by trial and >>>error. I do, however, use the Secondo file in the end as a "master" >>>for generating a Table of Contents. >>> >>>Finally, I also use pdftk to produce the full book, but the process >>>outlined earlier can be extremely streamlined if you use the >"collate" >>>feature. You do not need to burst the files into separate pages; >pdftk >>>will automatically alternate the pages when combining the two files. >>> >>>I hope this has been helpful. >>> >>>Hwaen Ch'uqi >> >> This looks very interesting. Maybe we should try to wrap this into >the >> page-layout library. I would also like to try triggering the pdftk >stuff >> from within LilyPond. >> >> Urs >> >>> >>> >>>On 5/8/16, David Wright wrote: On Sun 08 May 2016 at 19:13:37 (+0200), Jacques Menu Muzhic wrote: > Would dynamics parts dedicated to breaks and pageBreaks, stored in > variables, be useful? They might contain only spacer rests and >such > breaks, and be used by Piano I and Piano II parts. > > I use this satisfactorily to produce director and musicians parts, >>>with > the same breaks in the first drafts to facilitate cross checking >of >>>the LP > input code. This seems to be the mainstream way of handling breaks and >pageBreaks (though I hadn't thought of specifically using a Dynamics context). > One would still have to place things in the right order in the >input >>>file > to build the left and right pages, of course. I wouldn't try to build the score in display order at all. In fact, if you want to be able to start a new piece halfway down the page, >I think you'd get into a real mess. I would typeset the primo and secondo in separate scores, using >>>\books to write separate PDF files. I would use breakbefore = ##t to get the titling out of the way on page 1. Consequently, primo would have its first music on page 2. All subsequent page breaks would be written: \pageBreak % skips to the next page... \markup { " " } \pageBreak % ...and that leaves a page blank (except the page >>>number). so that a blank page is left for secondo, and every odd page is >>>blank. (Probably put this construction in a variable.) Secondo would start with an immediate extra: \pageBreak % skips to the next page... \markup { " " } \pageBreak % ...and that leaves a page blank (except the page >>>number). so that its first music is on page 3. Continue as with primo, so >>>every even page is blank. If this looks familiar, it's because this is a rehash of >http://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00069.html Burst the two PDFs into two directories and delete all the empty >>>pages (ie every other file). Move the remaining files from either >directory into the other. Concatenate the PDFs exactly as before, except now >>>the output file is called interleaved-output.pdf instead of decimated-output.pdf. > [A.N.Other] said: > > The initial problem is getting the page breaks in sync. > > Once you've achieved that (presumably by manually adding page
Re: 4 hands piano pieces book
THAT would be brilliant! Hwaen Ch'uqi On 5/9/16, Urs Liskawrote: > > > Am 9. Mai 2016 20:35:17 MESZ, schrieb Hwaen Ch'uqi : >>Greetings Alberto, >> >>I have been wwriting A LOT of four-hand music, and I agree in >>principle with most of what I have read in this thread. Even so, I >>thought to chime in with my approach. As has been advised, I create >>two separate book files, one for Secondo and one for Primo. The top of >>each file is headed with the following: >> >>#(define-markup-command (four-hand-page layout props offset) (number?) >> (let* ( >>(two-hand (chain-assoc-get 'page:page-number-string props)) >>(four-hand (number->string (+ offset (* 2 (string->number >>two-hand)) >>(interpret-markup layout props four-hand))) >> >>Then, in the \paper block, I include the following for the Secondo >>part: >> >>oddHeaderMarkup = \markup \fill-line { >> \four-hand-page #0 >> " " >>} >>evenHeaderMarkup = ##f >> >>Or, for the Primo part: >> >>oddHeaderMarkup = \markup \fill-line { >> " " >> \four-hand-page #1 >>} >>evenHeaderMarkup = ##f >> >>In this way, each part will begin with the correct page number, and >>the numbering will increase by two automatically. >> >>In my experience, I have found that there can be no "master file" used >>for determining page breaks, due to the lovely but unpredictable way >>that LilyPond lays out pages. So this must still be done by trial and >>error. I do, however, use the Secondo file in the end as a "master" >>for generating a Table of Contents. >> >>Finally, I also use pdftk to produce the full book, but the process >>outlined earlier can be extremely streamlined if you use the "collate" >>feature. You do not need to burst the files into separate pages; pdftk >>will automatically alternate the pages when combining the two files. >> >>I hope this has been helpful. >> >>Hwaen Ch'uqi > > This looks very interesting. Maybe we should try to wrap this into the > page-layout library. I would also like to try triggering the pdftk stuff > from within LilyPond. > > Urs > >> >> >>On 5/8/16, David Wright wrote: >>> On Sun 08 May 2016 at 19:13:37 (+0200), Jacques Menu Muzhic wrote: Would dynamics parts dedicated to breaks and pageBreaks, stored in variables, be useful? They might contain only spacer rests and such breaks, and be used by Piano I and Piano II parts. I use this satisfactorily to produce director and musicians parts, >>with the same breaks in the first drafts to facilitate cross checking of >>the LP input code. >>> >>> This seems to be the mainstream way of handling breaks and pageBreaks >>> (though I hadn't thought of specifically using a Dynamics context). >>> One would still have to place things in the right order in the input >>file to build the left and right pages, of course. >>> >>> I wouldn't try to build the score in display order at all. In fact, >>> if you want to be able to start a new piece halfway down the page, I >>> think you'd get into a real mess. >>> >>> I would typeset the primo and secondo in separate scores, using >>\books >>> to write separate PDF files. >>> >>> I would use breakbefore = ##t to get the titling out of the way on >>> page 1. >>> >>> Consequently, primo would have its first music on page 2. All >>> subsequent page breaks would be written: >>> >>> \pageBreak % skips to the next page... >>> \markup { " " } >>> \pageBreak % ...and that leaves a page blank (except the page >>number). >>> >>> so that a blank page is left for secondo, and every odd page is >>blank. >>> (Probably put this construction in a variable.) >>> >>> Secondo would start with an immediate extra: >>> >>> \pageBreak % skips to the next page... >>> \markup { " " } >>> \pageBreak % ...and that leaves a page blank (except the page >>number). >>> >>> so that its first music is on page 3. Continue as with primo, so >>every >>> even page is blank. >>> >>> If this looks familiar, it's because this is a rehash of >>> http://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00069.html >>> >>> Burst the two PDFs into two directories and delete all the empty >>pages >>> (ie every other file). Move the remaining files from either directory >>> into the other. Concatenate the PDFs exactly as before, except now >>the >>> output file is called interleaved-output.pdf instead of >>> decimated-output.pdf. >>> [A.N.Other] said: >>> > The initial problem is getting the page breaks in sync. > Once you've achieved that (presumably by manually adding page >>breaks) > you can easily create two separate pdfs and use an external tool >>to > create the bound volume. >>> >>> Write your page breaks into *one* variable. Where you give this >>variable >>> to \new Dynamics in the \score structures, prefix *only* secondo with >>> an extra copy of the three-liner above. This approach guarantees the >>same >>> pagebreaks for the two players,
Re: 4 hands piano pieces book
Am 9. Mai 2016 20:35:17 MESZ, schrieb Hwaen Ch'uqi: >Greetings Alberto, > >I have been wwriting A LOT of four-hand music, and I agree in >principle with most of what I have read in this thread. Even so, I >thought to chime in with my approach. As has been advised, I create >two separate book files, one for Secondo and one for Primo. The top of >each file is headed with the following: > >#(define-markup-command (four-hand-page layout props offset) (number?) > (let* ( >(two-hand (chain-assoc-get 'page:page-number-string props)) >(four-hand (number->string (+ offset (* 2 (string->number >two-hand)) >(interpret-markup layout props four-hand))) > >Then, in the \paper block, I include the following for the Secondo >part: > >oddHeaderMarkup = \markup \fill-line { > \four-hand-page #0 > " " >} >evenHeaderMarkup = ##f > >Or, for the Primo part: > >oddHeaderMarkup = \markup \fill-line { > " " > \four-hand-page #1 >} >evenHeaderMarkup = ##f > >In this way, each part will begin with the correct page number, and >the numbering will increase by two automatically. > >In my experience, I have found that there can be no "master file" used >for determining page breaks, due to the lovely but unpredictable way >that LilyPond lays out pages. So this must still be done by trial and >error. I do, however, use the Secondo file in the end as a "master" >for generating a Table of Contents. > >Finally, I also use pdftk to produce the full book, but the process >outlined earlier can be extremely streamlined if you use the "collate" >feature. You do not need to burst the files into separate pages; pdftk >will automatically alternate the pages when combining the two files. > >I hope this has been helpful. > >Hwaen Ch'uqi This looks very interesting. Maybe we should try to wrap this into the page-layout library. I would also like to try triggering the pdftk stuff from within LilyPond. Urs > > >On 5/8/16, David Wright wrote: >> On Sun 08 May 2016 at 19:13:37 (+0200), Jacques Menu Muzhic wrote: >>> Would dynamics parts dedicated to breaks and pageBreaks, stored in >>> variables, be useful? They might contain only spacer rests and such >>> breaks, and be used by Piano I and Piano II parts. >>> >>> I use this satisfactorily to produce director and musicians parts, >with >>> the same breaks in the first drafts to facilitate cross checking of >the LP >>> input code. >> >> This seems to be the mainstream way of handling breaks and pageBreaks >> (though I hadn't thought of specifically using a Dynamics context). >> >>> One would still have to place things in the right order in the input >file >>> to build the left and right pages, of course. >> >> I wouldn't try to build the score in display order at all. In fact, >> if you want to be able to start a new piece halfway down the page, I >> think you'd get into a real mess. >> >> I would typeset the primo and secondo in separate scores, using >\books >> to write separate PDF files. >> >> I would use breakbefore = ##t to get the titling out of the way on >> page 1. >> >> Consequently, primo would have its first music on page 2. All >> subsequent page breaks would be written: >> >> \pageBreak % skips to the next page... >> \markup { " " } >> \pageBreak % ...and that leaves a page blank (except the page >number). >> >> so that a blank page is left for secondo, and every odd page is >blank. >> (Probably put this construction in a variable.) >> >> Secondo would start with an immediate extra: >> >> \pageBreak % skips to the next page... >> \markup { " " } >> \pageBreak % ...and that leaves a page blank (except the page >number). >> >> so that its first music is on page 3. Continue as with primo, so >every >> even page is blank. >> >> If this looks familiar, it's because this is a rehash of >> http://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00069.html >> >> Burst the two PDFs into two directories and delete all the empty >pages >> (ie every other file). Move the remaining files from either directory >> into the other. Concatenate the PDFs exactly as before, except now >the >> output file is called interleaved-output.pdf instead of >> decimated-output.pdf. >> >>> [A.N.Other] said: >> >>> > The initial problem is getting the page breaks in sync. >>> > Once you've achieved that (presumably by manually adding page >breaks) >>> > you can easily create two separate pdfs and use an external tool >to >>> > create the bound volume. >> >> Write your page breaks into *one* variable. Where you give this >variable >> to \new Dynamics in the \score structures, prefix *only* secondo with >> an extra copy of the three-liner above. This approach guarantees the >same >> pagebreaks for the two players, but pushes secondo forward by one >page. >> >> Cheers, >> David. >> >> ___ >> lilypond-user mailing list >> lilypond-user@gnu.org >> https://lists.gnu.org/mailman/listinfo/lilypond-user >> >
Re: 4 hands piano pieces book
Dear Hwaen, Thanks for your share. I will try to look to the different presented approaches and check which is more adequate for my needs. But, unfortunately, only in my next hobby time slice, next weekend :) Alberto On 09/05/16 19:35, Hwaen Ch'uqi wrote: Greetings Alberto, I have been wwriting A LOT of four-hand music, and I agree in principle with most of what I have read in this thread. Even so, I thought to chime in with my approach. As has been advised, I create two separate book files, one for Secondo and one for Primo. The top of each file is headed with the following: #(define-markup-command (four-hand-page layout props offset) (number?) (let* ( (two-hand (chain-assoc-get 'page:page-number-string props)) (four-hand (number->string (+ offset (* 2 (string->number two-hand)) (interpret-markup layout props four-hand))) Then, in the \paper block, I include the following for the Secondo part: oddHeaderMarkup = \markup \fill-line { \four-hand-page #0 " " } evenHeaderMarkup = ##f Or, for the Primo part: oddHeaderMarkup = \markup \fill-line { " " \four-hand-page #1 } evenHeaderMarkup = ##f In this way, each part will begin with the correct page number, and the numbering will increase by two automatically. In my experience, I have found that there can be no "master file" used for determining page breaks, due to the lovely but unpredictable way that LilyPond lays out pages. So this must still be done by trial and error. I do, however, use the Secondo file in the end as a "master" for generating a Table of Contents. Finally, I also use pdftk to produce the full book, but the process outlined earlier can be extremely streamlined if you use the "collate" feature. You do not need to burst the files into separate pages; pdftk will automatically alternate the pages when combining the two files. I hope this has been helpful. Hwaen Ch'uqi On 5/8/16, David Wrightwrote: On Sun 08 May 2016 at 19:13:37 (+0200), Jacques Menu Muzhic wrote: Would dynamics parts dedicated to breaks and pageBreaks, stored in variables, be useful? They might contain only spacer rests and such breaks, and be used by Piano I and Piano II parts. I use this satisfactorily to produce director and musicians parts, with the same breaks in the first drafts to facilitate cross checking of the LP input code. This seems to be the mainstream way of handling breaks and pageBreaks (though I hadn't thought of specifically using a Dynamics context). One would still have to place things in the right order in the input file to build the left and right pages, of course. I wouldn't try to build the score in display order at all. In fact, if you want to be able to start a new piece halfway down the page, I think you'd get into a real mess. I would typeset the primo and secondo in separate scores, using \books to write separate PDF files. I would use breakbefore = ##t to get the titling out of the way on page 1. Consequently, primo would have its first music on page 2. All subsequent page breaks would be written: \pageBreak % skips to the next page... \markup { " " } \pageBreak % ...and that leaves a page blank (except the page number). so that a blank page is left for secondo, and every odd page is blank. (Probably put this construction in a variable.) Secondo would start with an immediate extra: \pageBreak % skips to the next page... \markup { " " } \pageBreak % ...and that leaves a page blank (except the page number). so that its first music is on page 3. Continue as with primo, so every even page is blank. If this looks familiar, it's because this is a rehash of http://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00069.html Burst the two PDFs into two directories and delete all the empty pages (ie every other file). Move the remaining files from either directory into the other. Concatenate the PDFs exactly as before, except now the output file is called interleaved-output.pdf instead of decimated-output.pdf. [A.N.Other] said: The initial problem is getting the page breaks in sync. Once you've achieved that (presumably by manually adding page breaks) you can easily create two separate pdfs and use an external tool to create the bound volume. Write your page breaks into *one* variable. Where you give this variable to \new Dynamics in the \score structures, prefix *only* secondo with an extra copy of the three-liner above. This approach guarantees the same pagebreaks for the two players, but pushes secondo forward by one page. Cheers, David. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user ___ lilypond-user mailing list lilypond-user@gnu.org
Re: 4 hands piano pieces book
Greetings Alberto, I have been wwriting A LOT of four-hand music, and I agree in principle with most of what I have read in this thread. Even so, I thought to chime in with my approach. As has been advised, I create two separate book files, one for Secondo and one for Primo. The top of each file is headed with the following: #(define-markup-command (four-hand-page layout props offset) (number?) (let* ( (two-hand (chain-assoc-get 'page:page-number-string props)) (four-hand (number->string (+ offset (* 2 (string->number two-hand)) (interpret-markup layout props four-hand))) Then, in the \paper block, I include the following for the Secondo part: oddHeaderMarkup = \markup \fill-line { \four-hand-page #0 " " } evenHeaderMarkup = ##f Or, for the Primo part: oddHeaderMarkup = \markup \fill-line { " " \four-hand-page #1 } evenHeaderMarkup = ##f In this way, each part will begin with the correct page number, and the numbering will increase by two automatically. In my experience, I have found that there can be no "master file" used for determining page breaks, due to the lovely but unpredictable way that LilyPond lays out pages. So this must still be done by trial and error. I do, however, use the Secondo file in the end as a "master" for generating a Table of Contents. Finally, I also use pdftk to produce the full book, but the process outlined earlier can be extremely streamlined if you use the "collate" feature. You do not need to burst the files into separate pages; pdftk will automatically alternate the pages when combining the two files. I hope this has been helpful. Hwaen Ch'uqi On 5/8/16, David Wrightwrote: > On Sun 08 May 2016 at 19:13:37 (+0200), Jacques Menu Muzhic wrote: >> Would dynamics parts dedicated to breaks and pageBreaks, stored in >> variables, be useful? They might contain only spacer rests and such >> breaks, and be used by Piano I and Piano II parts. >> >> I use this satisfactorily to produce director and musicians parts, with >> the same breaks in the first drafts to facilitate cross checking of the LP >> input code. > > This seems to be the mainstream way of handling breaks and pageBreaks > (though I hadn't thought of specifically using a Dynamics context). > >> One would still have to place things in the right order in the input file >> to build the left and right pages, of course. > > I wouldn't try to build the score in display order at all. In fact, > if you want to be able to start a new piece halfway down the page, I > think you'd get into a real mess. > > I would typeset the primo and secondo in separate scores, using \books > to write separate PDF files. > > I would use breakbefore = ##t to get the titling out of the way on > page 1. > > Consequently, primo would have its first music on page 2. All > subsequent page breaks would be written: > > \pageBreak % skips to the next page... > \markup { " " } > \pageBreak % ...and that leaves a page blank (except the page number). > > so that a blank page is left for secondo, and every odd page is blank. > (Probably put this construction in a variable.) > > Secondo would start with an immediate extra: > > \pageBreak % skips to the next page... > \markup { " " } > \pageBreak % ...and that leaves a page blank (except the page number). > > so that its first music is on page 3. Continue as with primo, so every > even page is blank. > > If this looks familiar, it's because this is a rehash of > http://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00069.html > > Burst the two PDFs into two directories and delete all the empty pages > (ie every other file). Move the remaining files from either directory > into the other. Concatenate the PDFs exactly as before, except now the > output file is called interleaved-output.pdf instead of > decimated-output.pdf. > >> [A.N.Other] said: > >> > The initial problem is getting the page breaks in sync. >> > Once you've achieved that (presumably by manually adding page breaks) >> > you can easily create two separate pdfs and use an external tool to >> > create the bound volume. > > Write your page breaks into *one* variable. Where you give this variable > to \new Dynamics in the \score structures, prefix *only* secondo with > an extra copy of the three-liner above. This approach guarantees the same > pagebreaks for the two players, but pushes secondo forward by one page. > > Cheers, > David. > > ___ > lilypond-user mailing list > lilypond-user@gnu.org > https://lists.gnu.org/mailman/listinfo/lilypond-user > ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: \keepWithTag #'A {\keepWithTag #'B \music}
On Mon 09 May 2016 at 14:28:41 (+0200), Gianmaria Lari wrote: > David Wright wrote: > > > [...] use tag groups. > > (1) Thank you David, I didn't see this command (tagGroup) > (2) Very useful and interesting 'command'. If you use tags this is an > almost mandatory command! > (3) It works extremely well! I have been able to write the code as I wanted. > > Is there any way I can contribute to the manual? I think it would be > nice having more examples regarding this command. > > > BTW what does markup do to the midi output that you don't like? > > I'm sorry I don't understand your question. I had wondered whether writing such things as "M" in the score would make the midi sound bad, but T (H. S. Teoh) effectively answered that question with some of his/her own examples. Perhaps one of the reasons I haven't used tags is because I don't use midi output the way you both may do. For me, the midi output is great for proof reading (my main use), and I have occasionally sent midi files to singers to help them learn a piece. Trills, tremolos, dynamics, partcombines and transitory voices are not relevant in these contexts. Cheers, David. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Placing a section name at the start of a staff
On 08/05/16 21:30, David Wright wrote: > On Sun 08 May 2016 at 19:06:27 (+0100), Anthonys Lists wrote: >> Basically, I want to do pretty much what "instrument name" does in a >> score - I want to put the name of the section in front of the start >> of the staff. The problem is, as always, when you use a feature for >> what it's not intended for, you can get unexpected side effects. >> I've got four sections, so that'll mean four \score's. Will I get >> unexpected (read - unwanted) headers between the scores? Basically, >> if you don't notice the section name, you shouldn't realise that the >> music doesn't just flow on. > > I don't foresee any issues. Have you not tried it? I have memories of the header code sticking stuff at the start of a score part ... things like the section name :-) ... exactly what I don't want to happen. I haven't tried that approach just yet, as it's majorly different from my normal style of doing things. > >> My other approach to doing this sort of thing is "\stopStaff >> \cadenzaOn ... \cadenzaOff \startStaff" but will this suppress >> things like key signature etc at the start of the line? My initial >> experiments in that respect haven't worked, although it seems >> obvious to me why. But I don't want to carry on down that route if >> it's going to turn into a rabbit's warren of tweaks and fixes to get >> right. > > Without an example of whay you've done, I wouldn't like to comment. > It seems more complicated. I use it to put text in the middle of a piece usually - some scores break the part and put the word "Coda" in the middle, or in my most recent case, "extended cadenza". I just expect if I try it at the start of a piece, it's likely to collide with a lot of the stuff lilypond "just does" for you. > >> How do other people deal with section names? Especially, how do you >> do it like the score I'm copying - at the start of the line ... > > I don't know what the score you're copying looks like. I think we've > been here before... > I'm not a visual person - I tend to describe things as text ... I was hoping someone who's done something similar would chime in - I would expect them to recognise the description if they have. I don't like repurposing stuff meant to be used otherwise - lily normally expects the section name to be *above* the score part, as part of the header, iirc. And the instrument name normally doesn't change several times per part ... :-) so if I put the section name in the instrument variable I'm not expecting it work exactly as I would like ... and it'll probably come with unwanted surprises. Cheers, Wol ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: attachments and digest mode
On Fri, Apr 29, 2016 at 8:22 PM David Wrightwrote: > > Some are available through links; just not the ones given in the digest. > I don't know the particulars of your example because I had already > deleted it (not interested in chord mode) by the time I read your posting. ... > > I pointed this out to the powers that be at gnu.org a while back, > but that might have been sent too high up the chain of admin. So > I'll try copying David Linn into this email instead. > I have also pointed this out to the powers that be at gnu.org, specifically the GNU Mailman management team for list.gnu.org, and have never gotten a response. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: \keepWithTag #'A {\keepWithTag #'B \music}
David Wright wrote: > [...] use tag groups. (1) Thank you David, I didn't see this command (tagGroup) (2) Very useful and interesting 'command'. If you use tags this is an almost mandatory command! (3) It works extremely well! I have been able to write the code as I wanted. Is there any way I can contribute to the manual? I think it would be nice having more examples regarding this command. > BTW what does markup do to the midi output that you don't like? I'm sorry I don't understand your question. * * * Thanks again for your great help! g. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user