Non-default tuplet numbers: Difference between revisions
Appearance
No edit summary |
m New category |
||
| Line 36: | Line 36: | ||
[[Category:Rhythms]] | [[Category:Rhythms]] | ||
[[Category:Included in the official documentation]][[Category:Snippet]] | [[Category:Included in the official documentation]] | ||
[[Category:Snippet]] | |||
Latest revision as of 23:31, 21 November 2025
LilyPond also provides formatting functions to print tuplet numbers different than the actual fraction, as well as to append a note value to the tuplet number or tuplet fraction.
\version "2.24"
\relative c'' {
\once \override TupletNumber.text =
#(tuplet-number::non-default-tuplet-denominator-text 7)
\tuplet 3/2 { c4. c4. c4. c4. }
\once \override TupletNumber.text =
#(tuplet-number::non-default-tuplet-fraction-text 12 7)
\tuplet 3/2 { c4. c4. c4. c4. }
\once \override TupletNumber.text =
#(tuplet-number::append-note-wrapper
(tuplet-number::non-default-tuplet-fraction-text 12 7)
(ly:make-duration 3 0))
\tuplet 3/2 { c4. c4. c4. c4. }
\once \override TupletNumber.text =
#(tuplet-number::append-note-wrapper
tuplet-number::calc-denominator-text
(ly:make-duration 2 0))
\tuplet 3/2 { c8 c8 c8 c8 c8 c8 }
\once \override TupletNumber.text =
#(tuplet-number::append-note-wrapper
tuplet-number::calc-fraction-text
(ly:make-duration 2 0))
\tuplet 3/2 { c8 c8 c8 c8 c8 c8 }
\once \override TupletNumber.text =
#(tuplet-number::fraction-with-notes
(ly:make-duration 2 1) (ly:make-duration 3 0))
\tuplet 3/2 { c4. c4. c4. c4. }
\once \override TupletNumber.text =
#(tuplet-number::non-default-fraction-with-notes 12
(ly:make-duration 3 0) 4 (ly:make-duration 2 0))
\tuplet 3/2 { c4. c4. c4. c4. }
}