Skip to contents

This is a helper function to set options() that control style characteristics for glosses across the full document. It is called within use_glossr() but can be overridden later by setting the appropriate options.

Usage

set_style_options(styling = list())

Arguments

styling

Named list of styling options for specific elements of glosses.

Value

Set the appropriate options.

Details

There are four types of settings that can be provided in the list.

First, trans_quotes sets the characters that must surround the free translation in a gloss. If no value is specified, it will be double quotes. There are no real restrictions for this value.

Second, the following elements can set general styling instructions for different sections of a gloss, formatting them completely in italics OR bold. The items with a | indicate that various names are possible.

  • source|preamble: The line of the glosses where the source is rendered.

  • a|first: The first line of the glosses, with the original language text.

  • b|second: The second line of the glosses.

  • c|third: The third line of the glosses if it exists.

  • ft|trans|translation: The line of the glosses where the free translation is rendered.

Each of these items can take one of a few values:

  • i, it, italics and textit set italics.

  • b, bf, bold and textbf set boldface.

Third, there are a few LaTeX-specific settings documented in the expex documentation. In all cases the default value is 0 (0pt). (If you would like other settings to be supported, write up an Issue and I will look into it!)

  • exskip|par_spacing: Space above and below the example. The par_spacing name is allowed for backwards compatibility, but the actual name in expex is exskip.

  • belowglpreambleskip: Space under the preamble (where the source is printed).

  • aboveglftskip: The spacing above the free translation.

  • extraglskip: The spacing between the aligned lines.

Finally, there is one setting that is not available in LaTeX, particularly thinking of slides: numbering, that is, whether the glosses should be numbered (in HTML).