Re: Tie multiple voice music contained in variable
On 2019-11-13 3:37 am, Gianmaria Lari wrote: Ciao Aaron, [] And you can use tags if you need the tie to be conditional: \version "2.19.83" multipleVoiceConditionalTie = \fixed c' { << { g4 \tag #'tie a~ \tag #'noTie a } \\ { e2 } >> } Yes, I didn't forget tags; but to me they are syntactically difficult to use. I always make million of mistakes before my code compiles correctly so I keep them as a last resort. Well, it turns out I forgot that \tag can be used as a post-event, which means my earlier snippet can be simplified: \version "2.19.83" multipleVoiceConditionalTie = \fixed c' { << { g4 a-\tag #'tie ~ } \\ { e2 } >> } multipleVoiceFollowingPhraseI = \fixed c' { << { a2 } \\ { d4 f } >> } multipleVoiceFollowingPhraseII = \fixed c' { << { a4 b } \\ { f2 } >> } multipleVoiceFollowingPhraseIII = \fixed c' { << { b2 } \\ { g2 } >> } { \multipleVoiceConditionalTie \multipleVoiceFollowingPhraseI \multipleVoiceConditionalTie \multipleVoiceFollowingPhraseII \removeWithTag #'tie \multipleVoiceConditionalTie \multipleVoiceFollowingPhraseIII } The advantage here is that you do not have to duplicate the final note/chord when defining the variable since only the tie itself is tagged. Also, it is not needed to use \keepWithTag since the tie would come along for the ride anyway. So then you only need to use \removeWithTag in the case when you want to omit the tie. -- Aaron Hill
Re: Tie multiple voice music contained in variable
Ciao Aaron, [] > And you can use tags if you need the tie to be conditional: > > > \version "2.19.83" > > multipleVoiceConditionalTie = \fixed c' { ><< { g4 \tag #'tie a~ \tag #'noTie a } \\ { e2 } >> > } > Yes, I didn't forget tags; but to me they are syntactically difficult to use. I always make million of mistakes before my code compiles correctly so I keep them as a last resort. Thanks a lot! Ciao, Gianmaria
Re: Tie multiple voice music contained in variable
Ciao Harm, P.S. My apologies if I included the images in the email and not attached it > it's for clarity. Please let me know if you lilypond email users always > prefer to attach images at the end of the messages. > > Please always attach and use plain text ;) > Well, I saw my beard well grown and clearly gray so I hoped it was time to try again to include images. I'm joking Harm Ciao, Gianmaria
Re: Tie multiple voice music contained in variable
On 2019-11-13 2:37 am, Aaron Hill wrote: On 2019-11-13 2:16 am, Gianmaria Lari wrote: Probably it doesn't exist a simple solution and the best would to keep the last measure outside the variable. Embedding the tie within the variable seems to work: \version "2.19.83" multipleVoiceWithUnterminatedTie = \fixed c' { << { g4 a~ } \\ { e2 } >> } multipleVoiceFollowingPhraseI = \fixed c' { << { a2 } \\ { d4 f } >> } multipleVoiceFollowingPhraseII = \fixed c' { << { a4 b } \\ { f2 } >> } { \multipleVoiceWithUnterminatedTie \multipleVoiceFollowingPhraseI \multipleVoiceWithUnterminatedTie \multipleVoiceFollowingPhraseII } (Fixed typo in quoted code above, which may help with future searches.) And you can use tags if you need the tie to be conditional: \version "2.19.83" multipleVoiceConditionalTie = \fixed c' { << { g4 \tag #'tie a~ \tag #'noTie a } \\ { e2 } >> } multipleVoiceFollowingPhraseI = \fixed c' { << { a2 } \\ { d4 f } >> } multipleVoiceFollowingPhraseII = \fixed c' { << { a4 b } \\ { f2 } >> } multipleVoiceFollowingPhraseIII = \fixed c' { << { b2 } \\ { g2 } >> } { \keepWithTag #'tie \multipleVoiceConditionalTie \multipleVoiceFollowingPhraseI \keepWithTag #'tie \multipleVoiceConditionalTie \multipleVoiceFollowingPhraseII \keepWithTag #'noTie \multipleVoiceConditionalTie \multipleVoiceFollowingPhraseIII } -- Aaron Hill
Re: Tie multiple voice music contained in variable
Am Mi., 13. Nov. 2019 um 11:17 Uhr schrieb Gianmaria Lari < gianmarial...@gmail.com>: P.S. My apologies if I included the images in the email and not attached it it's for clarity. Please let me know if you lilypond email users always prefer to attach images at the end of the messages. Please always attach and use plain text ;) Cheers, Harm >
Re: Tie multiple voice music contained in variable
On 2019-11-13 2:16 am, Gianmaria Lari wrote: Probably it doesn't exist a simple solution and the best would to keep the last measure outside the variable. Embedding the tie within the variable seems to work: \version "2.19.83" multipleVoiceWithUnterimnatedTie = \fixed c' { << { g4 a~ } \\ { e2 } >> } multipleVoiceFollowingPhraseI = \fixed c' { << { a2 } \\ { d4 f } >> } multipleVoiceFollowingPhraseII = \fixed c' { << { a4 b } \\ { f2 } >> } { \multipleVoiceWithUnterimnatedTie \multipleVoiceFollowingPhraseI \multipleVoiceWithUnterimnatedTie \multipleVoiceFollowingPhraseII } -- Aaron Hill
Re: Tie multiple voice music contained in variable
Michael you gave me the solution! Or at least you gave me the solution for my simple example. The following works! \version "2.21.0" pa = {<< {e'1*~*}\\{c'1*~*}>>} { \pa \pa } Now I have to try in my real file code but I don't see any reason why it should not work Thank you! g. On Wed, 13 Nov 2019 at 11:16, Gianmaria Lari wrote: > > On Wed, 13 Nov 2019 at 10:01, Michael Käppler wrote: > >> Hi Gianmaria, >> Interesting, for me running 2.19.80 the first example does not compile, >> either. >> > > Yes, I vaguely remember that version 2.21 manage differently > ties/variable. And probably that was the reason why I decided to use it :) > > >> Was there a recent change regarding post-event handling? >> > > No idea about post-event handling. > > > The problem is that the tie is not a separate expression that you could >> concatenate with other >> musical expressions like >> > [.] > Thank you Michael for the explanations! > > >> What are you trying to achieve? Your second example does not make much >> sense to me, >> because if you want to tie two equally long notes you would normally use >> chords [] >> > > You're right Michael; to tie two equally long notes I would use a chord. > But my code was just a very simple example. > > Here it is the real situation. My phrase is in a variable. The end of the > phrase is the following: > > [image: image.png] > and that should be connected once with this > > [image: image.png] > > and once with this > [image: image.png] > > Probably it doesn't exist a simple solution and the best would to keep the > last measure outside the variable. > Thank you Michael!! > > P.S. My apologies if I included the images in the email and not attached > it it's for clarity. Please let me know if you lilypond email users always > prefer to attach images at the end of the messages. >
Re: Tie multiple voice music contained in variable
On Wed, 13 Nov 2019 at 10:01, Michael Käppler wrote: > Hi Gianmaria, > Interesting, for me running 2.19.80 the first example does not compile, > either. > Yes, I vaguely remember that version 2.21 manage differently ties/variable. And probably that was the reason why I decided to use it :) > Was there a recent change regarding post-event handling? > No idea about post-event handling. The problem is that the tie is not a separate expression that you could > concatenate with other > musical expressions like > [.] Thank you Michael for the explanations! > What are you trying to achieve? Your second example does not make much > sense to me, > because if you want to tie two equally long notes you would normally use > chords [] > You're right Michael; to tie two equally long notes I would use a chord. But my code was just a very simple example. Here it is the real situation. My phrase is in a variable. The end of the phrase is the following: [image: image.png] and that should be connected once with this [image: image.png] and once with this [image: image.png] Probably it doesn't exist a simple solution and the best would to keep the last measure outside the variable. Thank you Michael!! P.S. My apologies if I included the images in the email and not attached it it's for clarity. Please let me know if you lilypond email users always prefer to attach images at the end of the messages.
Re: Tie multiple voice music contained in variable
Hi Gianmaria, Interesting, for me running 2.19.80 the first example does not compile, either. Was there a recent change regarding post-event handling? The problem is that the tie is not a separate expression that you could concatenate with other musical expressions like bla = { e'1 } foo = { ~ } bar = { e'2 } { \bla \foo \bar } (AFAIK with 2.19.x, not sure for more recent versions) Instead it is a post-event which is internally added to the 'articulations property of the NoteEvent to which the tie belongs. Compare: \version "2.19.80" foo = { e'1 ~ } bar = { e'1 } \displayMusic \foo \displayMusic \bar What are you trying to achieve? Your second example does not make much sense to me, because if you want to tie two equally long notes you would normally use chords for it I think: foo = { 1 ~ q1 } { \foo } Of course you could do: foo = { 1~ } bar = { 1 } { \foo \bar } Have a nice day, Michael Am 13.11.2019 um 08:38 schrieb Gianmaria Lari: The following code containing a tie between variables, compiles and works perfectly: \version "2.21.0" pa = {e'1} *{ \pa~\pa } * %here is the tie! Is there any way to do the same in case the variable contains two voices like in the following code? \version "2.21.0" pa = {<< {e'1}\\{c'1}>>} { \pa~ \pa } %this does not compile Thank you, g.
Tie multiple voice music contained in variable
The following code containing a tie between variables, compiles and works perfectly: \version "2.21.0" pa = {e'1} *{ \pa~\pa } * %here is the tie! Is there any way to do the same in case the variable contains two voices like in the following code? \version "2.21.0" pa = {<< {e'1}\\{c'1}>>} { \pa~ \pa } %this does not compile Thank you, g.