LilyPond beginner here.

I am trying to set an easy shuffle beat rhythm for the drums as follows:

\version "2.24.2"

\new DrumStaff {
  \new DrumVoice {\voiceOne 
    \drummode{\repeat unfold 4 {\tuplet 3/2 {hh8 [ r hh]} }
  \new DrumVoice {\voiceTwo 
    \drummode{ bd4 sn bd \tuplet 3/2 {sn8 [r bd] }

Which produces the following output:

Drum staff with triplet swing (beamed eighth notes with an eighth rest under the beam) on the hi-hat in the upper voice, and bass and snare drums in the lower voice.  One of the eighth rests (near a snare note) is raised and colliding with the beam.

Why is the rest in the second triplet moved upwards? And how can I fix that?

1 Answer 1


The reason that that rest has moved upwards, is because LilyPond is trying to prevent it from colliding with the first snare drum note.

One way to fix this, is to explicitly set the height for rests in that voice:
\override Rest.staff-position = #4

To avoid this problem altogether you could write the triplets without rests; by doubling the written length of the first note:
\tuplet 3/2 {hh4 hh8}

  • 1
    Worth noting that the reason this doesn't happen on beat 4 is that the duration of the snare note doesn't overlap with the high-hat rest.
    – Aaron
    Commented Nov 8, 2023 at 11:22
  • Thanks! That explains and solves it. Just another quick question: why does \shiftOff nor work here? Commented Nov 8, 2023 at 11:28
  • @MarvinDippell That's because \shiftOff is for turning off the horizontal shift between voices with stems in the same direction (e.g. \voiceOne & \voiceThree). Commented Nov 8, 2023 at 11:36
  • Good job on becoming a moderator!
    – mathlander
    Commented Nov 8, 2023 at 20:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.