lilypond-user
[Top][All Lists]
Advanced

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

Re: Cue notes above rests


From: Ralph Palmer
Subject: Re: Cue notes above rests
Date: Thu, 23 Nov 2023 09:30:49 -0800

On Thu, Nov 23, 2023 at 8:56 AM Michael Werner <reznaeous@gmail.com> wrote:
Hi Ralph,

On Thu, Nov 23, 2023 at 11:26 AM Ralph Palmer <palmer.r.violin@gmail.com> wrote:
Greetings, All -

As ever, I'm grateful (Thankful, given it's Thanksgiving Day where I live) for LilyPond and for the help the other users give to each other. I used to give more help myself than I do now, mostly because others are so much more knowledgeable and quick to respond.

I'm having a problem with cue notes and the rests in the primary instrument. I don't know how to get the primary instrument's rests above the cue notes.

You almost had it. One small change:

\version "2.24.0"

\relative c' {
  a''2
  <<
    {
      r2 |
      r1 |
      r1 |
      r1 |
      r2
    }
    \\
    {
      \new CueVoice {
        a,2~ |
        a4 d, g2~ |
        g4 e a g |
        f4 g
      }
    }
  >>
  d'2\f |
}

Adding the \\ between the two sections puts both sections into their own context. And that produces:

image.png

Another option would be to explicitly assign voiceOne and voiceTwo, like:

\version "2.24.0"

\relative c' {
  a''2
  <<
    {
      \voiceTwo
      r2 |
      r1 |
      r1 |
      r1 |
      r2
    }
    {
      \voiceOne
      \new CueVoice {
        a,2~ |
        a4 d, g2~ |
        g4 e a g |
        f4 g
      }
    }
  >>
  \oneVoice
  d'2\f |
}

That gives the same result. Just make sure to add the \oneVoice afterward, to put everything back to the defaults.
--
Michael


Wonderful! Thanks for your quick and clear response, Michael.

All the best,

Ralph

______
Ralph Palmer
Seattle
USA
(he, him, his)

reply via email to

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