Re: cadenza_and_accidentals-take2
- Original Message - > From: "Jim Long" > To: bobr...@centrum.is > Cc: "Noeck" , lilypond-user@gnu.org > Sent: Sunday, March 29, 2015 2:51:41 AM > Subject: Re: cadenza_and_accidentals-take2 > > On Sat, Mar 28, 2015 at 07:45:51PM +, bobr...@centrum.is wrote: > > > > - Original Message - > > > From: "Noeck" > > > > > > A naive question: Could the \cadenzaOff command be changed in a way that > > > it automatically implies the end of a measure at that point. > > > > I can think of instances where the end of a cadenza might not be at the end > > of a measure. > > I am speculating wildly, and I also am not generally a cadenza > user, but perhaps \cadenzaOff could also be made to cooperate > with \partial: > > % simple case, without \partial: > > \cadenzaOn > > % lots of notes go here > > \cadenzaOff > > % a bar line appears here, and beat 1 follows > > | c1 > | c1 > > \bar "|." > > Or: > > % a less simple case, using \partial: > > \cadenzaOn > > % lots of notes go here > > \cadenzaOff > > \partial 4. > > b'8 c'' d'' > > % a bar line appears here, and beat 1 follows > > | c1 > | c1 > > \bar "|." > > > > This discussion got me motivated me to experiment a bit. I haven't had much cause to use cadenzas much, either. After playing with this I realized that the reason I was having accidental troubles following a cadenza was that, in this case, the cadenza was at the end of a measure. Once the measure is full, LilyPond draws a barline even if it is invisible. That leads to potential accidental issues. Jim's speculation about \cadenzoOff being made to cooperate with \partial is maybe second-cousin to my solution below. I reasoned that the problem with a cadenza at the end of a measure is that LilyPond has already drawn the barline. The solution? Don't *be* at the end of the measure just yet. Using \scaleDurations I leave a bit of measure left at the end of the cadenza, toss in a skip and then Lily draws a barline. No problems with bar numbres or accidentals. It's a bit of a kludge, but all I have to do is scale the measure, add the skip, and everything else takes care of itself. This might be a bit cumbersome in a large score, but I'm only dealing with a single line. -David % \version "2.18.0" startCadenza = { \cadenzaOn \teeny \stemUp } endCadenza = { \cadenzaOff \normalsize \stemNeutral } \score { { \override Score.BarNumber.break-visibility = ##(#t #t #t) c'2.^\markup{ Cadenza in the middle of a bar, no problem } \startCadenza d'16-[ f' e' g'-] a'-[ g' f' d'-] % \set Timing.measurePosition = #(ly:make-moment 2/4) \endCadenza g'4 c'1 } } \score { { c'1^\markup{ Cadenza at the beginning of a bar, no problem } \override Score.BarNumber.break-visibility = ##(#t #t #t) \startCadenza d'16-[ f' e' g'-] a'-[ g' f' d'-] \endCadenza cis'2. g'4 c'1 } } \score { { \override Score.BarNumber.break-visibility = ##(#t #t #t) c'1^\markup { \column { "Cadenza at the end of a bar requires manipulation." "Time management still leaves accidental trouble" "Bar numbers may also be affected" } } cis'2. \set Timing.measurePosition = #(ly:make-moment 1/4) g'4 %\bar "" \startCadenza d'16-[ f' e' g'-] a'-[ g' f' d'-] \endCadenza \bar "|" \set Timing.measurePosition = #(ly:make-moment 0/4) c'4 c' c' c' } } \score { { \override Score.BarNumber.break-visibility = ##(#t #t #t) c'1^\markup { \column { "Cadenza at the end of a bar requires manipulation." "Using \scaleDurations with a skip at the end works well." "Bar numbering remains unaffected and accidentals are well-behaved." } } \scaleDurations 63/64 { % scale the whole mesure down a bit cis'2. \startCadenza d'16-[ f' e' g'-] a'-[ g' f' d'-] \endCadenza g'4 %\bar "" \startCadenza d'16-[ f' e' g'-] a'-[ g' f' d'-] \endCadenza } s64 % add a skip at the very end \bar "|" c'1 } } % ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
On Sat, Mar 28, 2015 at 07:45:51PM +, bobr...@centrum.is wrote: > > - Original Message - > > From: "Noeck" > > > > A naive question: Could the \cadenzaOff command be changed in a way that > > it automatically implies the end of a measure at that point. > > I can think of instances where the end of a cadenza might not be at the end > of a measure. I am speculating wildly, and I also am not generally a cadenza user, but perhaps \cadenzaOff could also be made to cooperate with \partial: % simple case, without \partial: \cadenzaOn % lots of notes go here \cadenzaOff % a bar line appears here, and beat 1 follows | c1 | c1 \bar "|." Or: % a less simple case, using \partial: \cadenzaOn % lots of notes go here \cadenzaOff \partial 4. b'8 c'' d'' % a bar line appears here, and beat 1 follows | c1 | c1 \bar "|." ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
- Original Message - > From: "Noeck" > To: bobr...@centrum.is > Cc: lilypond-user@gnu.org > Sent: Saturday, March 28, 2015 7:53:58 PM > Subject: Re: cadenza_and_accidentals-take2 > > Hi David, > > > I recall thinking at some point that perhaps LilyPond would count up the > > stuff not between \cadenzaOn ... \cadenzaOff and place barlines in the > > correct place (it doesn't). > > What do you mean here differing from 1) (which is what I also proposed > in a previous mail)? I don't understand this sentence and I would like to. Well, actually it works the way I described as long as the measure contains the cadenza sandwiched between non-cadenza stuff: %%% \version "2.18.2" \score { \relative c' { g2 \cadenzaOn e8-[ e e e e e e e e e-] \cadenzaOff g4 b %% barline appears here just fine c1 g'2 a4 b %% barline appears here before I want it, unless next line un-commented %\bar "" \cadenzaOn f8-[ f f f f f f f f f-] %% barline does not appear here, unless next line un-commented %\bar "|" \cadenzaOff c1 } } %%% So it's all less mysterious than I thought. It rather depends on how the measure ends. If it ends with non-cadenza material barlines will take care of themselves. If it ends with cadenza material then 'manual' barline controls must be used. -David ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
Hi David, > I recall thinking at some point that perhaps LilyPond would count up the > stuff not between \cadenzaOn ... \cadenzaOff and place barlines in the > correct place (it doesn't). What do you mean here differing from 1) (which is what I also proposed in a previous mail)? I don't understand this sentence and I would like to. Best, Joram ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
- Original Message - > From: "Noeck" > To: lilypond-user@gnu.org > Sent: Saturday, March 28, 2015 3:55:07 PM > Subject: Re: cadenza_and_accidentals-take2 > > A naive question: Could the \cadenzaOff command be changed in a way that > it automatically implies the end of a measure at that point. Perhaps I > overlook cases where this is not wanted, but where I use this command, I > want a bar line and a new bar starting with beat one right after it. > > Any comments? > Joram > I can think of instances where the end of a cadenza might not be at the end of a measure. If a cadenza took place in the middle of a measure, then what? You certainly don't want a barline appearing there. I recall thinking at some point that perhaps LilyPond would count up the stuff not between \cadenzaOn ... \cadenzaOff and place barlines in the correct place (it doesn't). That is perhaps too much heavy lifting on the programming side and there may be reasons other than that for not doing it that way. It could well be that the current state of affairs which require either; 1) setting the end points of the cadenza so that everything at either end of the cadenza adds up to a full measure or 2) making the whole measure a cadenza and setting the measurePosition value to correctly place the next bar line and measure number increment ...may be the least troublesome. -David ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
A naive question: Could the \cadenzaOff command be changed in a way that it automatically implies the end of a measure at that point. Perhaps I overlook cases where this is not wanted, but where I use this command, I want a bar line and a new bar starting with beat one right after it. Any comments? Joram ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
Hi David, how about this: \version "2.18.2" \score { \relative c' { \clef F \key a \major r4-\fermata cis4 ~ cis8.-[ \grace { dis32 cis bis cis } dis!16-] \cadenzaOn e4 ~ \teeny \stemUp e32-[ dis e dis-] \cadenzaOff cis-[ bis! c b-] a-[ gis a gis-] %% 4/4 measure is completed here naturally \stemNeutral \normalsize g8[ e' dis! cis] %% no accidental on cis } } Here the \cadenzaOn/Off commands are put such that the whole cadenza part is kept counting a full measure: It counts the first 3/4, then it skips 3/8 (e4 and 4 1/32 notes) and then continues counting the last 8 32nd notes which add up to 1/4 and complete the measure. That way the bar naturally appears at the point where you switch back to \normalSize. That way the whole cadenza is counted as one measure - is that what you like? And no changes in the timing and bar lines are needed. Cheers, Joram ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
- Original Message - > From: "Mark Knoop" > To: "Lilypond User List" > Sent: Saturday, March 28, 2015 12:14:36 PM > Subject: Re: cadenza_and_accidentals-take2 > > At 10:49 on 28 Mar 2015, bobr...@centrum.is wrote: > >- Original Message - > >> From: "Andrew Bernard" > >Yes, I have accidentals in the cadenza section. As I stated, however, > >in the final measure the cadenza has been ended and a bar line has > >been crossed so the key signature is in full force again. All > >accidentals from the previous measure are now null and void. > >Obviously, LilyPond is behaving the way it does. My point and > >question still stand: > > The reason is because you have forced the barline to appear, but > LilyPond still thinks it is in the same bar for the purpose of > accidentals. It's not a "natural" barline so you need to tell > LilyPond where it is in the bar. Before \bar "|", add the line: > > \set Timing.measurePosition = #(ly:make-moment 4/4) > > and all will be well without forcing any accidentals. > This works exactly as you said. I experimented a bit. I'm actually in 2/4 time. Using: \set Timing.measurePosition = #(ly:make-moment 0/4) \set Timing.measurePosition = #(ly:make-moment 2/4) \set Timing.measurePosition = #(ly:make-moment 4/4) All produced the same result except with regard to measure numbers. By using: \set Timing.measurePosition = #(ly:make-moment 2/4) ...I was also able to dispense with 'correcting' the measure numbering. Thanks! -David ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
At 10:49 on 28 Mar 2015, bobr...@centrum.is wrote: >- Original Message - >> From: "Andrew Bernard" >Yes, I have accidentals in the cadenza section. As I stated, however, >in the final measure the cadenza has been ended and a bar line has >been crossed so the key signature is in full force again. All >accidentals from the previous measure are now null and void. >Obviously, LilyPond is behaving the way it does. My point and >question still stand: The reason is because you have forced the barline to appear, but LilyPond still thinks it is in the same bar for the purpose of accidentals. It's not a "natural" barline so you need to tell LilyPond where it is in the bar. Before \bar "|", add the line: \set Timing.measurePosition = #(ly:make-moment 4/4) and all will be well without forcing any accidentals. -- Mark Knoop ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
- Original Message - > From: "Andrew Bernard" > To: bobr...@centrum.is, "Lillypond Users Mailing List" > Sent: Saturday, March 28, 2015 10:23:40 AM > Subject: Re: cadenza_and_accidentals-take2 > > Well, you have a C natural in the group of 32s, and then in the last bar a > C#, so generally engravers will put a sharp to revert the previous natural > and let the performer know we are back to normal (cadenza or not). That’s > how I learned music (I think!). Yes, I have accidentals in the cadenza section. As I stated, however, in the final measure the cadenza has been ended and a bar line has been crossed so the key signature is in full force again. All accidentals from the previous measure are now null and void. Obviously, LilyPond is behaving the way it does. My point and question still stand: POINT: The documentation is not entirely clear on this issue. It is not spelled out when, precisely, the key signature/accidental rules are recognized as back in force. QUESTION: How do I suppress the accidental on the cis in the final measure? A related question is; why is it necessary to force the accidental on the dis in the final measure? I suspect it is for the same reason that the cis has the accidental. This somewhat more pared-down example illustrates what I mean: % \version "2.18.2" \score { \relative c' { \clef F \time 2/4 \key a \major r4-\fermata cis4 ~ \cadenzaOn cis8.-[ dis!16-] e4 \teeny dis16-[ c-] \cadenzaOff %% CADENZA IS OFF \normalsize \bar "|" %% NEW MEASURE g8-[ e' dis! cis-] %% WHY IS CIS WITH ACCIDENTAL/HOW TO SUPPRESS? } } % > > Also, when putting manual beaming, you have ‘-[‘ and ‘-]’ but you only need > the square brackets. It does not mess anything up but it is a lot of extra > typing. > I am aware of this. -David ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals-take2
Well, you have a C natural in the group of 32s, and then in the last bar a C#, so generally engravers will put a sharp to revert the previous natural and let the performer know we are back to normal (cadenza or not). That’s how I learned music (I think!). Also, when putting manual beaming, you have ‘-[‘ and ‘-]’ but you only need the square brackets. It does not mess anything up but it is a lot of extra typing. Andrew On 28 March 2015 at 21:04:27, bobr...@centrum.is (bobr...@centrum.is) wrote: I provided a bad example in my previous attempt in an effort to be minimal. Here goes with one that actually illustrates the issue: ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: cadenza_and_accidentals
Why don’t you remove the ! after the last cis? Andrew ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user