Am Do., 16. Mai 2019 um 13:25 Uhr schrieb Alexander Kobel <a-ko...@a-kobel.de>: > > Hi David, hi Mike, hi all, > > I sometimes (still use Lilypond, and when I do, I typically use) your > wonderful snippet for snapping "close" syllables into a single token. > > (For those who don't know this contribution: it's meant to get rid of > unpleasant thin-space gaps between syllables in cramped conditions, when > LyricHyphens are not shown, but there's a "kerning" problem due to the > fact that syllables are engraved as separate entities.) > > Now I stumbled across an issue with that: two syllables are combined > which are clearly far apart; see the attached screenshot and reduced > working example from an actual engraving. It's not exactly minimal, but > at least it's reasonably short and shows the problem. And the exact > circumstances when the bug occurs are not clear to me, and it's somewhat > sensitive to reduction. > > According to my tests, it's related to the facts that there is > > (1) a hyphen *before* the syllable "bor" in "ver -- bor -- gen" in the > alto part; > > (2) a line break exactly there (moving the break "remedies" the > problem); and > > (3) another voice/staff simultaneously (commenting out the soprano > mitigates the issue as well). > > It's not, however, related to the accidental in the soprano, or the fact > that the whole note in the lower voice is wider than the quarter in the > upper voice (replacing d'1 by d'4*4 doesn't help). > > > Any thoughts on what goes wrong here, and about a possible fix or > workarounds? > > > [ In case you wonder: it's an excerpt of Heinrich Schütz' "Die Himmel > erzählen", converted from James Gibb's contribution 46745 to CPDL > (engraved in Capella) via musicxml2ly. I mainly want to fix a couple of > minor spelling errors; the conversion worked fairly pleasant in general. ] > > > Cheers, > Alex
Hi, I tried to have a look at it ... Though, I'm too tired to be verbose, please refer to the pdf. First a minimal, then some debugging output with a probably significant difference. Currently I've no idea for a fix, though. \version "2.19.82" \include "lyric-syllable-magnetic-snap-orig.ily" \markup \box \fill-line { minimal } \new Lyrics \lyricmode { \override LyricWord.after-line-breaking = #(lyric-word-compressor 0.5) foo8 -- bar _4 one2 -- \break two1 -- three } good = \lyricmode { _4 foo8 -- bar one2 -- \break two1 -- three } bad = \lyricmode { %% !!!!!!!!!!!!!!!! foo8 -- bar _4 one2 -- \break two1 -- three } tst = \override LyricWord.after-line-breaking = #(lambda (grob) (newline) (pretty-print (map (lambda (elt) (cons elt (ly:grob-property elt 'text))) (ly:grob-array->list (ly:grob-object grob 'text-items)))) ((lyric-word-compressor 0.5) grob)) \markup \box \fill-line { \column { BAD-OUTPUT "terminal:" "[...]" \with-color #red "((#<Grob LyricHyphen >)" "(#<Grob LyricText > . \"two\")" "(#<Grob LyricHyphen >" "(#<Grob LyricText > . \"three\")))" } } \new Lyrics \lyricmode { \tst \bad } \markup \box \fill-line { \column { GOOD-OUTPUT "terminal:" "[...]" \with-color #red "((#<Grob Spanner >)" "(#<Grob LyricText > . \"two\")" "(#<Grob LyricHyphen >" "(#<Grob LyricText > . \"three\")))" } } \new Lyrics \lyricmode { \tst \good } } Cheers, Harm _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user