lilypond-user
[Top][All Lists]
Advanced

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

Re: clef change in 1st ending


From: David Kastrup
Subject: Re: clef change in 1st ending
Date: Wed, 27 Oct 2021 12:13:22 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Lukas-Fabian Moser <lfm@gmx.de> writes:

>> \version "2.22.1"
>>
>> {
>>   \clef tenor
>>   \repeat volta 2 {
>>     c'1
>>     \clef bass
>>     c'1
>>   }
>>   \alternative {
>>     {
>>       c'1
>>       \set Staff.clefGlyph = "clefs.C"
>>     }
>>     { c'1 }
>>   }
>>   c'1
>> }
>
> While this is technically perfect, I'd strongly advise against doing
> it this way: It's a recipe for disaster regarding the start of the 2nd
> alternative. Half of your cellists (or whatever instrument uses tenor
> and bass clef here) is going to play a g' here, because there's this
> tenor clef directly in front of the the note, separated only by the
> bar line (which is what you're used to in any clef change).
>
> One could do something like
>
> \version "2.22.1"
>
> {
>   \clef tenor
>   \repeat volta 2 {
>     c'1
>     \clef bass
>     c'1
>   }
>   \alternative {
>     {
>       c'1
>       \set Staff.clefGlyph = "clefs.C"
>
>       \once \override Score.BarLine.stencil =
>         #(lambda (grob)
>           (grob-interpret-markup
>            grob
>            #{
>              \markup {
>                \stencil #(ly:bar-line::print grob)
>                \hspace #0.5
>                \fontsize #-2 \raise #1 \musicglyph "clefs.F"
>              } #}))
>     }
>     { c'1 }
>   }
>   c'1
> }
>
> (note that this is very unpolished; a real solution would have to
> check if there's a line break at the repeat sign)
>
> but usually it's much better to just change notation such that there
> is no clef change at the repeat sign at all.

I have

\version "2.22.1"

{
  % \override Score.BarNumber.break-visibility = #all-visible
  \clef tenor
  \repeat volta 2 {
    c'1
    \clef bass
    c'1
  }
  \alternative {
    {
      c'1
      \clef tenor
    }
    { \grace s128
      \once\hide Staff.BarLine \bar "|"
      \once \omit Score.BarNumber
      \clef bass c'1 }
  }
  c'1
}
but I think it may rely on issue 34 not getting fixed.  At least I find
the combination and order of things that "worked" here unconvincing.

-- 
David Kastrup

reply via email to

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