Fix chord alignment: snap to word boundaries

Improve merge_chord_lyric() to snap chord positions to the start
of the word they fall within, instead of splitting words mid-way.
Fixes artifacts like "Liebespaar \chord{C}e" → "\chord{C}Liebespaare".

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
shahondin1624
2026-04-02 16:36:06 +02:00
parent d875fd225b
commit 7b99778f67
295 changed files with 1804 additions and 1782 deletions

View File

@@ -8,12 +8,12 @@
}
\begin{verse}
Noch la \chord{C}nge saßen wir auf den Fels \chord{d}enbänken dort, \\
und die \chord{C}mmerung wob längst ihr Kleid. \\
Gegen Mitt \chord{F}ernacht zogen schweige \chord{C}nd weiter fort, \\
ja die St \chord{a}raße nach No \chord{d}rden \chord{G}hrt we \chord{C}it. \\
/: \chord{C}Und wenn wir fa \chord{F}hr \chord{G}e \chord{C}n, tr \chord{F}eibt uns der Wi \chord{G}nd dann \\
we \chord{G7}ite \chord{C}r fort, weht \chord{C7}uns nach J \chord{F}ah \chord{G}r \chord{C}en \chord{F}, oft wieder \chord{G} an \\
Noch \chord{C}lange saßen wir auf den \chord{d}Felsenbänken dort, \\
und die \chord{C}mmerung wob längst ihr Kleid. \\
Gegen \chord{F}Mitternacht zogen \chord{C}schweigend weiter fort, \\
ja die \chord{a}Straße nach \chord{d}Norden \chord{G}hrt \chord{C}weit. \\
/: \chord{C}Und wenn wir \chord{C}fahren, \chord{F}treibt uns der \chord{G}Wind dann \\
\chord{C}weiter fort, weht \chord{C7}uns nach \chord{F}Jahren, oft wieder \chord{G}an \\
den alten \chord{C}Ort. :/
\end{verse}