lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Definition of repeats using segno and coda


From: Volodymyr Prokopyuk
Subject: Re: Definition of repeats using segno and coda
Date: Sun, 26 Feb 2023 22:26:54 +0100

Thank you very much, David!

Your suggestion fixed both the minimal example and my real use case! I'm impressed with the reactivity and quality of Lilypond support!

Minimal example that produces the desired result

\version "2.24.0"

\relative {
  \clef treble
  \key c \major
  \time 4/4
  \repeat segno 2 {
    \repeat volta 2 { a'1 1 1 1 }
    {
      \alternative {
        \volta 1 {
          \repeat volta 2 { b1 1 1 1 }
        }
        \volta 2 { \section \sectionLabel "Coda" }
      }
    }
  }
  c1 1 1 1
}

image.png
Thank you very much David and Jean!
Vlad

On Sun, Feb 26, 2023 at 10:09 PM David Kastrup <dak@gnu.org> wrote:
Volodymyr Prokopyuk <volodymyrprokopyuk@gmail.com> writes:

> Hi Jean,
>
> I've produced the minimal example reflecting my real use case. This example
> does not produce the desired result. The difference between the minimal
> working example and my real use case is that both section A and section B
> are \repeat volta 2 themselves. In this situation the minimal working
> example from above stops working.
>
>
> *Minimal example that does not produce the desired result*
>
> \version "2.24.0"
>
> \relative {
>   \clef treble
>   \key c \major
>   \time 4/4
>   \repeat segno 2 {
>     \repeat volta 2 { a'1 1 1 1 }
>     \alternative {
>       \volta 1 {
>         \repeat volta 2 { b1 1 1 1 }
>       }
>       \volta 2 { \section \sectionLabel "Coda" }
>     }
>   }
>   c1 1 1 1
> }

Well, the old syntax compatibility sets in, drawing \alternative to the
inner \repeat volta.  You could put { } before \alternative to block
that.

--
David Kastrup

reply via email to

[Prev in Thread] Current Thread [Next in Thread]