Jump to content

Permitting line breaks within beamed tuplets: Difference between revisions

From LilyPond wiki
Import snippet from LSR
 
m Replace version="2.24.0" with version="2.24" now that the LilyWiki extension supports auto-selecting the latest release in a stable series
Line 3: Line 3:
This feature only works with manually beamed tuplets.
This feature only works with manually beamed tuplets.


<lilypond version="2.24.0" full>
<lilypond version="2.24" full>
\layout {
\layout {
   \context {
   \context {

Revision as of 18:50, 16 November 2025

These artificial examples show how both manual and automatic line breaks may be permitted within beamed tuplets that can't be rhythmically split in an exact way.

This feature only works with manually beamed tuplets.

\version "2.24"

\layout {
  \context {
    \Voice
    % Permit automatic line breaks within tuplets.
    \remove "Forbid_line_break_engraver"
    % Allow beams to be broken at line breaks.
    \override Beam.breakable = ##t
  }
}

\relative c'' {
  <>^"manually forced line break"
  a8
  \repeat unfold 5 { \tuplet 3/2 { c8[ b g16 a] } }
  \tuplet 3/2 { c8[ b \break g16 a] }
  \repeat unfold 5 { \tuplet 3/2 { c8[ b g16 a] } }
  c8 \bar "||"
}

\relative c'' {
  <>^"automatic line break"
  \repeat unfold 28 a16
  \tuplet 11/8 { a16[ b c d e f e d c b a] }
  \repeat unfold 28 a16 \bar "||"
}

\paper { tagline = ##f }