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

@@ -7,13 +7,13 @@
}
\begin{verse}
Wir ha \chord{D}ben das Sehen nicht verlernt, \\
in die Ferne zu sch \chord{A}auen. \\
Auf st \chord{D}einigem Boden, auf f \chord{G}elsigem \chord{D}Riff \\
uns´re Zelt \chord{G}e \chord{D}zu \chord{A} b \chord{D}auen. \\
Wir \chord{D}haben das Sehen nicht verlernt, \\
in die Ferne zu \chord{A}schauen. \\
Auf \chord{D}steinigem Boden, auf \chord{G}felsigem \chord{D}Riff \\
uns´re \chord{G}Zelte \chord{D}zu \chord{D}bauen. \\
Ref.: \\
/: R \chord{G}uhlos wir s \chord{D}ind, u \chord{A}ns treibt der W \chord{D}ind, \\
nirg \chord{A}ends s \chord{D}in \chord{G}d wir zu Ha \chord{A}us \chord{D}e. :/
/: \chord{G}Ruhlos wir \chord{D}sind, \chord{A}uns treibt der \chord{D}Wind, \\
\chord{A}nirgends \chord{G}sind wir zu \chord{D}Hause. :/
\end{verse}
\begin{verse}