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

@@ -21,10 +21,10 @@
% und bald illegalen Gruppen im gesamten Deutschen Reich gesungen.
\begin{verse}
\chord{H7}Im Morgenn \chord{e}ebel schwimmen T \chord{H7}al und W \chord{e}älder, dur \chord{D}chs \\
Heimatl \chord{G}and zieht \chord{C} schweigend u \chord{D7}ns´re \chord{G}Schar. \\
/: \chord{E}Wi \chord{D}r \chord{h}se \chord{a}hen Hügel, Wiese, D \chord{D}orf und Feld \chord{e}er, \\
wie es vor Ja \chord{a}hren \chord{H7}immer wieder \chord{e}war. :/
\chord{H7}Im \chord{e}Morgennebel schwimmen \chord{H7}Tal und \chord{e}Wälder, \chord{D}durchs \\
\chord{G}Heimatland zieht \chord{C}schweigend \chord{D7}uns´re \chord{G}Schar. \\
/: \chord{D}Wir \chord{a}sehen Hügel, Wiese, \chord{D}Dorf und \chord{e}Felder, \\
wie es vor \chord{a}Jahren \chord{H7}immer wieder \chord{e}war. :/
\end{verse}
\begin{verse}