gregorio
gregorio copied to clipboard
Translation throws off staff spacing
Adding a translation to chant text is not providing expected spacing results.
The following image is from my current project. Note how the third line staff is being pushed up into the second line of text by the translation text:

It seems to be the case generally that translations are messing with staff spacing, even when there's a translation on every line.
MWE:
\documentclass[12pt]{article}
\usepackage{geometry}
\geometry{paperwidth=16cm,paperheight=20cm}
\usepackage{gregoriotex}
\usepackage{fullpage}
\usepackage{fontspec}
\defaultfontfeatures{Ligatures=TeX}
\setmainfont{Linux Libertine O}
\pagestyle{empty}
\begin{document}
\gabcsnippet{(f3)Ju(f)das(ef..) (,) * mer(f)cá(f)tor(f) pés(f)si(f)mus(f) ó(f)scu(f)lo(f) pé(f)ti(f)it(g) Dó(h)mi(g)num:(g.) (:) il(h)le(h) ut(h) a[* Denariorum.](h)gnus(h) ín(h)no(h)cens(h) non(h) ne(h)gá(h)vit(h) Ju(h)dæ(h) ó(h)scu(f)lum:(f.) (:) * De[* Denariorum.](f)na(f)ri(f)ó(f)rum(f) nú(f)me(f)ro(f) Chri(f)stum(f) Ju(f)dǽ(e)is(c) trá(e)di(f)dit.(gf..) (::) <sp>V/</sp>. Mé(h)li(h)us(h') il(h)li(h') e(g)rat,(gh..) (;) si(h) na(h)tus(h') non[* Denariorum.](g) fu(e')ís(g)set.(f.) (::)}
\end{document}

Every other line is too tight.
Hmm... I think this might be #1375 in another guise. I.e. it's more a matter of it not being totally clear how GregoiroTeX's space settings interact with the way LaTeX makes spacing decisions, than anything being actually wrong. This is something that always confuses the hell out of me.
I have been experiencing the same issue in a project I am working on. I am adding translations to all the chants, and in most cases they look fine. I think I have figured out what is different. Most of the chants have a (c4) clef. It is the chants that have lower clefs (like in @fiat96's example) which show this issue.
The crux seems to be that the higher clefs extend above the top line, thus pushing it down. If you change (f3) to (c4) in that example, the spacing looks fine (but obviously the music is then quite wrong). You can also see that the spacing between the second * Denariorum and the third line is a little better than the other cases. This is because of the custos on the third line extending a little above it.
The solution that I have found is to set spaceabovelines to something greater than 0cm (the default). I have found .25cm to be a good value (that is half of the translationheight of .5cm).
\grechangedim{spaceabovelines}{.25cm}{scalable}
Happily, I can use that setting for all of my scores, not just the ones with vertical translation spacing issues. I have not noticed any ill effects. Scores that already had enough space still look the same; they don't get additional spaced added.