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

@@ -10,11 +10,11 @@
}
\begin{verse}
Wir wo \chord{D}ll´n im grün \chord{A}en Wald e \chord{D}in \chord{A} f \chord{D}reies Lebe \chord{E}n \\
f \chord{A}ühren / und wer da hat ein fris \chord{D}chen Mut, / f \chord{G}rohes \\
Herz und jung \chord{A}es Blut, / der soll \chord{D} mit un \chord{A}s marsch \chord{G}ieren, \\
f \chord{D}a la la la la, soll mit u \chord{A}ns marschi \chord{G}eren, \\
f \chord{D}a la la la la, soll mit \chord{A}uns marsch \chord{D}ieren.
Wir \chord{D}woll´n im \chord{A}grünen Wald \chord{D}ein \chord{D}freies \chord{E}Leben \\
\chord{A}führen / und wer da hat ein \chord{D}frischen Mut, / \chord{G}frohes \\
Herz und \chord{A}junges Blut, / der soll \chord{D}mit \chord{A}uns \chord{G}marschieren, \\
\chord{D}fa la la la la, soll mit \chord{A}uns \chord{G}marschieren, \\
\chord{D}fa la la la la, soll mit \chord{A}uns \chord{D}marschieren.
\end{verse}
\begin{verse}