Tweaking your Chant Code

There are some tweaks that cannot be done in gabc code, and must be made, instead, in your tex file. Remember that if you include these in your “main” tex file, then they can be included in all of your scores. If you just want the tweaks in an individual score, then first run your gabc through Gregorio, and then place your tex tweaks in the resultant tex file.

Here are some links to some useful tex tutorials (in case this page doesn't have what you need).

Drop Caps

Fonts

The LaTex package fontspec lets you use TrueType (.ttf) fonts. You initiate them like this:

\usepackage{fontspec}

And then, if you've installed the font, you can set the font as the main font for your chant text. Now, notice below that Gentium is listed three times. That is because the actual font files are called “Gentium Basic Bold.ttf”, “Gentium Italic.ttf” and “Gentium.ttf”. So you need to make sure the font names match the font file names. (I think)

\documentclass{article}
\usepackage{fontspec}
\newfontfamily\Gentium[Ligatures=TeX]{Gentium}
\begin{document}%You can only have one of these declarations, so just make sure what is above is declared
This is in the normal font
\begin{center}
\Gentium\huge
This is in the Gentium font
\end{center}and back in the normal font.
\end{document}

Another thing you should probably do is to install two tex packages (you can use texlive just as well as gregorio, you know. texlive is its own application), called, koma-script and extsizes. To install them (in Windows), open your Tex Live Manager and find the “Match” box. The default repository will already be loaded. In the “status” groupbox on the left, make sure that “not installed” is checked.“ Just check the box and push the “install” button! That's it. It's pretty easy. Now that you've installed the two font sizing packages, you can add this to your tex code, just below \documentclass toward the top:

%increase the text size to 20for the entire document
\usepackage[fontsize=20]{scrextend}

Staff Width

%control the width of the staff and accompanying text
\textwidth 4.5in

Red Staff

% We set red lines here, comment it if you want black ones.
\redlines

Staff Break

Adding z or Z along with the gabc code will add space to the staff.
This is useful if you want to force-fill a line.

Custos

You can suppress the custos at the end of a staff by placing \greblockcustos in the tex template just after \begin{document} .

To add a custos within the staff, perhaps before the double-bars, try this: (z0::c4)

To manually place a custos anywhere, use g+ or h+ where the letter is the level you want the marker.

Nonbreaking Space

In the gabc file, there are several things you can do:

Try putting ! before spaces.

Put a regular space within the neum's parenthesis: g(g )

Put a space within the text area(the separators are just to show the boundary: (:) g (g)(:)

Another thing you can do is to use a neumatic cut, which is just this: / or //

And if you place a ! before a / then it makes the neumatic cut unbreakable across staves: !/

Increase spacing

These two tricks can be inserted in your main tex code just before the inclusion of your tex score.

\tolerance=9999%(or less)
\pretolerance=500%default is -1 This will spread your chant out over the bars

Forced Syllables

Say you need to force hyphens to appear between syllables. You can try placing this before the score in your tex template. This inidicates maximal space between two syllables for which we consider a dash is not needed. You may also try adjusting the value. A negative value (-20pt for example) may do the trick. The idea is to get a dimension that is just small enough.

\grechangedim{\gremaximumspacewithoutdash}{0pt}

Change Clefs

Changing Clefs midstaff is easy - just type your clef within the parentheses of the last double-bar, like this: (::c3).

Compress Space

Reduce the spacing between syllables or glyphs: \hspace{-.2ex}

or, put the syllables or glyphs between inside this: \mbox{…}

or, use ( z) to push the neums closer to the start of the staff. The more spaces in the parentheses, the more it crunches the space.

Indents

To remove any unwanted indentations, you can wrap your tex code with \begin{flushleft} and \end{flushleft}. But don't wrap your inclusion (\includescore{myscore.tex})!