Jump to content

Extending a trill spanner: Difference between revisions

From LilyPond wiki
No edit summary
m Lemzwerg moved page Extending a TrillSpanner to Extending a trill spanner without leaving a redirect
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
For <code>TrillSpanner</code>, the <code>minimum-length</code> property becomes effective only if the <code>set-spacing-rods</code> procedure is called explicitly.
For <code>TrillSpanner</code> grobs, the <code>minimum-length</code> property becomes effective only if the <code>set-spacing-rods</code> procedure is called explicitly.


To do this, the <code>springs-and-rods</code> property should be set to <code>ly:spanner::set-spacing-rods</code>.
To do this, the <code>springs-and-rods</code> property should be set to <code>ly:spanner::set-spacing-rods</code>.
Line 10: Line 10:
   \once\override TrillSpanner.minimum-length = #15
   \once\override TrillSpanner.minimum-length = #15
   \once\override TrillSpanner.springs-and-rods = #ly:spanner::set-spacing-rods
   \once\override TrillSpanner.springs-and-rods = #ly:spanner::set-spacing-rods
   \afterGrace es4
   \afterGrace es4\startTrillSpan { d16[(\stopTrillSpan es)] }
  \startTrillSpan { d16[( \stopTrillSpan es)] }
   c( c' g es c g' es d
   c( c' g es c g' es d
  \hideNotes
   c8)
   c8)
}
}
Line 21: Line 19:
[[Category:Syntax and expressions]]
[[Category:Syntax and expressions]]
[[Category:Tweaks and overrides]]
[[Category:Tweaks and overrides]]
[[Category:Included in the official documentation]][[Category:Snippet]]
[[Category:Included in the official documentation]]
[[Category:Snippet]]

Latest revision as of 09:58, 10 December 2025

For TrillSpanner grobs, the minimum-length property becomes effective only if the set-spacing-rods procedure is called explicitly.

To do this, the springs-and-rods property should be set to ly:spanner::set-spacing-rods.

\version "2.24"

\relative c' {
  \key c\minor
  \time 2/4
  c16( as') c,-. des-.
  \once\override TrillSpanner.minimum-length = #15
  \once\override TrillSpanner.springs-and-rods = #ly:spanner::set-spacing-rods
  \afterGrace es4\startTrillSpan { d16[(\stopTrillSpan es)] }
  c( c' g es c g' es d
  c8)
}