Okay, getting a line where the staff lines appear to change color partway through the line is possible, but takes some substantial manual work. All the work below assumes that you are using v4.0.0-beta or later. It should be possible with v3.0.3 as well, but you'll need to change the command names to the old names.

To accomplish this you'll need a separate score for each section of the score where the lines are to change color. In the case of your example, that's three scores:

score1.gabc:

<c>V.</c> Il(e) Sig(f)no(g)re(g) si(e)a(e) con(f) vo(g)i.(f) (::)

score2.gabc:

<c>R.</c> E(e) con(f) il(g) tu(e)o(f) spi(g)ri(f)to.(f)

score3.gabc:

<c>V.</c>(::) In(g) al(h)to(g)

Of course, each score file will need it's proper header. In particular, you'll want to make sure that initial-style is 0 for score2 and score3 (your example would have it be 0 for score1 too, but that isn't strictly necessary).

Also, if the music is to continue beyond the end of the line, you will need a new score to start the next line.

Next, each score needs to be included inside a minipage environment of the appropriate size (note in the example below I've picked arbitrary numbers, you'll have to adjust accordingly):

\noindent%
\begin{minipage}[t]{2in}%
        \gregorioscore{score1}%
\end{minipage}%
\begin{minipage}[t]{2in}%
        \gresetlinecolor{gregoriocolor}%
        \gresetclef{invisible}%
        \gregorioscore{score2}%
\end{minipage}%
\begin{minipage}[t]{1in}%
        \gresetclef{invisible}%
        \gregorioscore{score3}%
\end{minipage}%

Note that each line ends with a % character. This ensures that TeX doesn't put any space between the scores.

Also note that you must supress the cleff (`\gresetclef{invisible}`) on each and every score except the first. Further it is not necessary to change the line color back to black for the third score. This is because the minipage environment, as an environment, is a group and so settings will automatically revert to their previous values at the end of the environment. You could change these settings outside the minipage environments, in which case they would be inherited by the environment, but I think the document is clearer like this.

Note, since you must use very short lines, you could also do this with `\gabcsnippet` instead of `\gregorioscore`:

\noindent%
\begin{minipage}[t]{2in}%
\gabcsnippet[0]{<c>V.</c> Il(e) Sig(f)no(g)re(g) si(e)a(e) con(f) vo(g)i.(f) (::)}%
\end{minipage}%
\begin{minipage}[t]{2in}%
        \gresetlinecolor{gregoriocolor}%
        \gresetclef{invisible}%
        \gabcsnippet[0]{<c>R.</c> E(e) con(f) il(g) tu(e)o(f) 
spi(g)ri(f)to.(f)}%
\end{minipage}%
\begin{minipage}[t]{1in}%
        \gresetclef{invisible}%
        \gabcsnippet[0]{<c>V.</c>(::) In(g) al(h)to(g)}%
\end{minipage}%


Finally, a word of warning: aligning the minipages just right can be frustrating. For instance, if I remove the `[t]` from the above examples, the last box will be positioned slightly lower than the first two because none of the lyrics in it have a descender (a letter which goes below the baseline like "g" or "p") while the first two do. Notes above or below the staff in one of the snippets but not the others would create similar problems. Depending on your real world needs you may need to align the minipages on the top, bottom, or center or even manually raise and lower them by placing them inside a `\raisebox`. In any case, you can't skip the minipage environment because GregorioTeX takes it's score width from `\hsize` and only the minipage environment actually changes this parameter for its contents. The other box commands will let the score see the document `\hsize`, which will be the full width of the line, not the size of the box.
✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝
Br. Samuel, OSB
(R. Padraic Springuel)

PAX ☧ ΧΡΙΣΤΟΣ

_______________________________________________
Gregorio-users mailing list
[email protected]
https://mail.gna.org/listinfo/gregorio-users

Reply via email to