Jump to content

Forcing hyphens to be shown: Difference between revisions

From LilyPond wiki
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
mNo edit summary
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
If LilyPond does not think there is space for a hyphen, it will be omitted. The behaviour can be overridden with the <code>minimum-distance</code> property of <code>LyricHyphen</code>.
If LilyPond does not think there is space for a hyphen, it will be omitted. This behaviour can be overridden with the <code>minimum-distance</code> property of <code>LyricHyphen</code>.


<lilypond version="2.24">
<lilypond version="2.24">
Line 19: Line 19:
</lilypond>
</lilypond>


[[Category:Vocal music]]
[[Category:Included in the official documentation]]
[[Category:Included in the official documentation]]
[[Category:Vocal music]]
[[Category:Snippet]]

Latest revision as of 05:16, 13 December 2025

If LilyPond does not think there is space for a hyphen, it will be omitted. This behaviour can be overridden with the minimum-distance property of LyricHyphen.

\version "2.24"

\relative c'' {
  c32 c c c 
  c32 c c c 
  c32 c c c 
  c32 c c c 
}
\addlyrics {
  syl -- lab word word
  \override LyricHyphen.minimum-distance = #1.0
  syl -- lab word word
  \override LyricHyphen.minimum-distance = #2.0
  syl -- lab word word
  \revert LyricHyphen.minimum-distance
  syl -- lab word word
}