-
Notifications
You must be signed in to change notification settings - Fork 0
/
covington.tex
1945 lines (1760 loc) · 89.9 KB
/
covington.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% File covington.tex
%%
%% Documentation of covington
%%
%% This file is part of the covington LaTeX package
%%
%% Original author:
%% ================
%% Michael A. Covington
%% Artificial Intelligence Programs
%% The University of Georgia
%% Athens, Georgia 30602-7415 USA
%%
%% Current maintainer:
%% ===================
%% Juergen Spitzmueller <[email protected]>
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3
%% of this license or (at your option) any later version.
%% The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
%% and version 1.3 or later is part of all distributions of LaTeX
%% version 2003/12/01 or later.
%%
%% This work has the LPPL maintenance status "maintained".
%%
%% The Current Maintainer of this work is Juergen Spitzmueller.
%%
%% Code repository and issue tracker: https://github.com/jspitz/covington
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[english]{article}
\usepackage{metre}
\usepackage[libertine]{newtxmath}
\usepackage[osf]{libertine}
\usepackage[scaled=0.75]{beramono}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage{covington}
\usepackage{url}
\usepackage[bookmarks=true,
bookmarksnumbered=false,
bookmarksopen=false,
breaklinks=false,
pdfborder={0 0 0},
backref=false,
colorlinks=false
]{hyperref}
\hypersetup{%
pdftitle={The covington manual},
pdfauthor={Jürgen Spitzmüller},
pdfkeywords={latex,linguistics}
}
\usepackage{microtype}
% Tweak the TOC (make it more compact)
\usepackage{tocloft}
\setlength{\cftbeforesecskip}{0pt}
\renewcommand{\cfttoctitlefont}{\normalsize\bfseries}
\renewcommand{\cftsecfont}{\small}
\renewcommand{\cftsecpagefont}{\small}
\renewcommand{\cftsubsecfont}{\small}
\renewcommand{\cftsubsecpagefont}{\small}
\renewcommand{\cftsubsubsecfont}{\footnotesize}
\renewcommand{\cftsubsubsecpagefont}{\footnotesize}
\tocloftpagestyle{empty}
\usepackage{babel}
\usepackage{listings}
\lstset{language={[LaTeX]TeX},
basicstyle={\small\ttfamily},
frame=single}
% markup
\newcommand*\jmacro[1]{\textbf{\texttt{#1}}}
\newcommand*\jenv[1]{\textbf{\texttt{#1}}}
\newcommand*\jcsmacro[1]{\jmacro{\textbackslash{#1}}}
\newcommand*\joption[1]{\textbf{\texttt{#1}}}
\newcommand*\jfmacro[1]{\texttt{#1}}
\newcommand*\jfenv[1]{\texttt{#1}}
\newcommand*\jfcsmacro[1]{\jfmacro{\textbackslash{#1}}}
\newcommand*\jparam[1]{\angus #1\angud}
% Strings
\newcommand*{\cvt}{\textsf{covington}}
\newcommand*{\Cvt}{\textsf{Covington}}
%
% Titling
%
\def\pversion{Version 2.14}
\def\pdate{December 11, 2023}
\title{\textbf{The \cvt\ Package\\\Large Macros for Linguistics}}
\author{Michael A. Covington \and J\"urgen Spitzm\"uller\thanks{Current maintainer.
Please report issues via \protect\url{https://github.com/jspitz/covington}}}
\date{\pversion, \pdate}
\begin{document}
\maketitle
\begin{abstract}
\noindent This package, initially a collection of Michael A. Covington's private macros, provides
numerous customizable \LaTeX\ macros that are helpful for linguists, including macros that allow
for multiple diacritics on the same letter, numbered linguistic examples, interlinear glosses
(word-by-word translations), Discourse Representation Structures, phrase structure rules and disjunctions,
linguistic feature structures, and for semantic markup commonly used in linguistic notation.
\end{abstract}
\enlargethispage{2\baselineskip}
\tableofcontents
\section{Introduction}\label{sec:intro}
This is the documentation for \MakeLowercase{\pversion}
of \cvt\ (\pdate), which is a \LaTeX\ package providing macros
for typing some special notations common in linguistics.%
\footnote{The package has a long history. It started off as a collection of private macros back in the
\LaTeX\ 2.09 days and was initially released as \texttt{covingtn.sty} (following the old 8.3 \textsc{fat}
file name limit). In em\TeX\ under \textsc{ms-dos}, the file was distributed as \texttt{covingto.sty}.
Eventually, it has been renamed to \cvt\ and adapted to \LaTeXe. The current version requires a reasonably
recent version of \LaTeXe, as it employs some newer kernel features.}
To use \cvt, load the package as usual by adding the command
\begin{lstlisting}
\usepackage[<options>]{covington}
\end{lstlisting}
to your document preamble. The package has the following options to customize its behavior:
\begin{description}
\item{\joption{force=\jparam{true|false}}} Default: \emph{false}.
Enforce the redefinition of environments that have already been defined by other packages or the class.
This applies to the \jenv{example}, \jenv{examples}, \jenv{subexamples} and \jenv{exercise} environments,
which are by default not touched if they have already been defined before \cvt\ is loaded.
See sec.~\ref{sec:ex}, \ref{sec:exs}, \ref{sec:subexs} and \ref{sec:exercises} for details.
\item{\joption{keeplayout=\jparam{true|false}}} Default: \emph{false}. Do not tweak the layout.
\Cvt\ sets \jfcsmacro{raggedbottom} and redefines the value of the \jfcsmacro{textfloatsep} length.
This just follows the preferences of the original package author and is not necessary
for the package's functionality. Yet for backwards compatibility reasons, we cannot change this.
Thus, we provide the option described here to opt out this presetting. And we actually encourage you to use it.
\item{\joption{noglossbreaks=\jparam{true|false}}} Default: \emph{false}.
If this option is set to \joption{true}, \cvt\ will try hard to prevent page breaks within glosses.
If this option is not set, page breaks can occur between interlinearized text and free translation of a gloss, as
well as between gloss preamble and interlinearized text, which is usually not what you will want.
Nonetheless the option is not set by default. This is for backwards compatibility reasons (in order to not change
page breaking of existing documents). Note that page breaks might still occur in some cases even if the option is set.
In order to prevent them definitely, you can put the gloss in a parbox or minipage.
\item{\joption{owncounter=\jparam{true|false}}} Default: \emph{false}. Use an own counter for numbered examples.
By default, \cvt\ uses \LaTeX's equation counter for example numbering, so that if you use equations and numbered examples
in the same paper, you get a single continuous series of numbers. While some people (including the original author of this package)
consider this a feature, others might prefer to number equations and linguistic examples separately. If you count to the latter sort,
use this option. Note that the default appearance of the own counter and the equation counter differs if the document has chapters.
See sec.~\ref{sec:cbc} for details.
\item{\joption{fnexamplecounter=\jparam{main|own|own-reset}}} Default: \emph{main}.
Specifics of the counter for numbered examples in footnotes.
By default, \cvt\ numbers examples in footnotes in sequence with the numbering used in the main text (this conforms to
the default value of this option, \joption{fnexamplecounter=main}). If you set \joption{fnexamplecounter=own},
examples in footnotes get a different numbering which is incremented throughout the whole footnote apparatus.%
\footnote{The previous option \joption{ownfncounter} is still supported,
but deprecated.}
If you set \joption{fnexamplecounter=own-reset}, examples in footnotes get an own counter as well, but this variant
resets the counter at each footnote (similar to \textsf{linguex} and \textsf{gb4e}).\footnote{The previous option
\joption{ownfncounter*} is still supported, but deprecated.}
Both own counters use lowercase Roman numbering by default (see sec.~\ref{sec:ex} on how to change this)
\end{description}
%
Please note the following package-related caveats:
\begin{itemize}
\item If you are using \cvt\ and the \textsf{uga} (University of Georgia thesis style) package together, you should load \textsf{uga} before \cvt.
\item If you are using \cvt\ with \textsf{beamer-article}, you should load \textsf{beamer-article} before \cvt.
\item If you are using \cvt\ with the \textsf{drs} package, you should load \textsf{drs} before \cvt. See sec.~\ref{sec:drs}.
\end{itemize}
%
In what follows we presume that you know how to use \LaTeX\ and have
access to \LaTeX\ manuals.
\section{Stacked diacritics}\label{sec:accents}
\LaTeX\ provides a generous range of diacritics that can be placed on or below any
letter, such as:
\begin{flushleft}
\`{x} \'{x} \^{x} \"{x} \~{x} \={x} \H{x} \t{xx} \c{x} \d{x} \b{x}
\end{flushleft}
which are typed, respectively, as:
\begin{lstlisting}
\`{x} \'{x} \^{x} \"{x} \~{x} \={x} \H{x} \t{xx} \c{x} \d{x} \b{x}
\end{lstlisting}
Out of the box, however, \LaTeX\ doesn't give you a convenient way to put \emph{two}
diacritical marks on the same letter. To fill this gap, \cvt\ provides
the following macros:
\begin{flushleft}
\jcsmacro{twodias\{<upper diac.>\}\{<lower diac.>\}\{<char>\}}\\to combine any two diacritics, e.\,g.,
\lstinline[moretexcs={twodias}].\twodias{\~}{\=}{a}. = \twodias{\~}{\=}{a}\\[6pt]
\jcsmacro{acm\{\ldots\}} \quad for acute over macron, e.\,g., \lstinline[moretexcs={acm}].\acm{a}. = \acm{a}\\
\jcsmacro{grm\{\ldots\}} \quad for grave over macron, e.\,g., \lstinline[moretexcs={grm}].\grm{a}. = \grm{a}\\
\jcsmacro{cim\{\ldots\}} \quad for circumflex over macron, e.\,g., \lstinline[moretexcs={cim}].\cim{a}. = \cim{a}
\end{flushleft}
The first of these is the general case\footnote{%
Alternatively, there's also the old syntax \jcsmacro{twoacc[<upper diac.>|<char with lower diacr.>],}
e.\,g. \jfcsmacro{twoacc[\textbackslash\textasciitilde|\textbackslash=\{a\}]} to the same effect, which is however discouraged
due to its rather odd form.} and the latter three are special
cases that are often used in Greek transcription. Now you can type
\emph{Koin\acm{e}} with both accents in place.
The vertical distance between the two diacritics can be adjusted via the macro \jcsmacro{SetDiaOffset\{<length>\}}
which lets you increase or decrease the vertical space that is currently in effect.
If you'd use \verb"\SetDiaOffset{-0.25ex}", the above examples would come out as
\SetDiaOffset{-.25ex}
\begin{flushleft}
\jcsmacro{twodias\{<upper diac.>\}\{<lower diac.>\}\{<char>\}}\\to combine any two diacritics, e.\,g.,
\lstinline[moretexcs={twodias}].\twodias{\~}{\=}{a}. = \twodias{\~}{\=}{a}\\[6pt]
\jcsmacro{acm\{\ldots\}} \quad for acute over macron, e.\,g., \lstinline[moretexcs={acm}].\acm{a}. = \acm{a}\\
\jcsmacro{grm\{\ldots\}} \quad for grave over macron, e.\,g., \lstinline[moretexcs={grm}].\grm{a}. = \grm{a}\\
\jcsmacro{cim\{\ldots\}} \quad for circumflex over macron, e.\,g., \lstinline[moretexcs={cim}].\cim{a}. = \cim{a}
\end{flushleft}
with a slightly better matching distance for the font used here.
Note that not all accent macros work in the \jfenv{tabbing} environment.
Use the \jfenv{Tabbing} package or refer to \cite{pakin} for alternative solutions.
\section{Numbered examples}
Linguistic papers often include numbered examples. With \cvt, generating those is straightforward.
In this section, we describe how you can typeset a self-stepping example number (see section~\ref{sec:exno}),
a single numbered example (sec.~\ref{sec:ex}), a consecutive range of numbered examples (sec.~\ref{sec:exs}),
and alpha-numerically labeled sub-examples (sec.~\ref{sec:subexs}).
\Cvt's numbered examples can be customized in many ways. For instance, you can make them by default be
typeset in italics, as common in linguistics, you can adjust the way the numbers
are displayed, and you can customize the spacing and indentation if the default
settings do not suit you. This can be achieved via example options that can be set locally to a specific
environment as optional arguments or globally via the \jcsmacro{setexampleoptions} macro (see sec.~\ref{sec:ex}
for details).
All numbered examples can be referred to in the text via \jfcsmacro{label} and \jfcsmacro{ref} as usual,
or with a convenience macro \jcsmacro{pxref} that adds the parentheses that are usually used
in example references (see sec.~\ref{sec:ref} for details).
\subsection{Example numbers}\label{sec:exno}
The macro \jcsmacro{exampleno} generates a new example number, stepped by 1. It can be
used anywhere you want the number to appear. For example, to display a
sentence with a number at the extreme right, do this:
\begin{lstlisting}[moretexcs={exampleno}]
\begin{flushleft}
This is a sentence. \hfill (\exampleno)
\end{flushleft}
\end{lstlisting}
Here's what you get:
\begin{flushleft}
This is a sentence. \hfill (\exampleno)
\end{flushleft}
If you want to output the (current) number without stepping it at the same time, the starred form
\jcsmacro{exampleno*} will do that.
Normally, however, you do not need to manually place \jcsmacro{exampleno} yourselves,
as in the example above. For the common case where example numbers in parentheses are
placed left to the example, \cvt\ provides more convenient solutions. These are described in turn.
\subsection[The \jenv{example} environment]{The \jenv{example} environment}\label{sec:ex}
The \jenv{example} environment (alias \jenv{covexample}\footnote{\label{fn:fallbacks}%
As of version 1.1, \cvt\ checks if there is already an \jfenv{example} environment defined (e.\,g., by the class).
If so, \cvt\ does not define its own one. The alias environment \jenv{covexample} which can be used in order to
produce \texttt{covington's} example, however, is always defined and can be used in such cases.
If you use the package option \joption{force}, \cvt\ will override existing \jfenv{example} environments.
In any case, the package will issue a warning if \jfenv{example} is already defined (this is the case,
for instance, if you use \cvt\ with the \texttt{beamer} class).}%
) displays a single example
with a generated example number to the left of it.
If you type
\begin{lstlisting}
\begin{example}
This is a sentence.
\end{example}
\end{lstlisting}
or
\begin{lstlisting}
\begin{covexample}
This is a sentence.
\end{covexample}
\end{lstlisting}
you get:
\begin{example}
This is a sentence.\label{expl}
\end{example}
The example can be of any length; it can consist of many lines (separated by \verb"\\"), or even whole paragraphs.
The \jenv{example} environment provides the following options which also allow for customization of their appearance:
\begin{description}
\item[\joption{fs=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Adjusts the font settings of the example text.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\item[\joption{fsno=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Adjusts the font settings of the example number.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\item[\joption{judge=\{\jparam{arbitrary text}\}}] Insert grammaticality judgments (such as * or ?)
to an example. This will be inserted before the example text with a small space and uses its own
markup. For convenience, the following shorthand options are also provided:
\joption{*}, \joption{?}, \joption{*?}, \joption{??}, and \joption{\#} (as alias to
\joption{judge=*} etc.).
\item[\joption{fsjudge=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Adjusts the font settings of the grammaticality judgment.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\item[\joption{preamble=\{\jparam{arbitrary text}\}}] Arbitrary text that is inserted on an own line
after the example number (preceding the example text). This might be useful, for instance,
to give context information, to specify the language or the source in case of cited examples.
The advantage over just adding a line manually in the example is that you can globally or locally
set the markup with the \joption{fspreamble} option. Also, judgment markers are properly set
after the preamble.
\item[\joption{postamble=\{\jparam{arbitrary text}\}}] Arbitrary text that is appended to the example
(on the same line after a space).
This might be useful to add a reference or an explanation to the translation.
The advantage over just adding text manually in the example is that that you can globally or locally
set the markup with the \joption{fspostamble} option.
\item[\joption{postamble*=\{\jparam{arbitrary text}\}}] A variant of \joption{postamble} that does not add
a space. This might be preferred if you want to add a footnote.
Note that \joption{postamble} and \joption{postamble*} are mutually exclusive.
If you want the postamble text to be on a line of its own, simply add a line break
(i.\,e., \verb|postamble={\\Text}| or, to the same effect, \verb|postamble*={\\Text}|).
\item[\joption{fspreamble=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Adjusts the font settings of the preamble text.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\item[\joption{fspostamble=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Adjusts the font settings of the postamble text.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\item[\joption{leftmargin=\{\jparam{length}\}}] Default: \verb|{0pt}|.
Lets you change the indentation of examples (including number). Positive values will increase,
negative values will decrease the indentation of the example.
\item[\joption{addnumbersep=\{\jparam{length}\}}] Default: \verb|{0pt}|.
Increases or (with negative values) decreases the spacing between example number and example.
\item[\joption{judgewidth=\{\jparam{text}\}}]
Sets the width that is reserved for the judgment marker. This is automatically set to the input
of \joption{judge}. By default and notably in the \jenv{examples} and \jenv{examples} environments
which use an angular \jcsmacro{item} argument rather than the \joption{judge} option,
this is preset to \verb|{?}|.
\item[\joption{addjudgesep=\{\jparam{length}\}}] Default: \verb|{0pt}|.
Increases or (with negative values) decreases the spacing between judgment mark and example
(which amounts to 0.2\,em by default).
\item[\joption{numberformat=\{\jparam{template}\}}] Default: \verb|{(1)}|.
The format of the example number. The option takes templates as known from the \textsf{enumerate}
package \cite{enumerate}.
Arabic numbering is represented by \jparam{1}, Roman by \jparam{i} and \jparam{I}, alphabetic by
\jparam{a} and \jparam{A}. Any text before and after the number are inserted as is.
For instance, \verb|numberformat={[a.]}| results in lower alphabetic numbering followed by a dot,
embraced in brackets.
Note that if the equation counter is used with chapters, this resets the separator between chapter
number and example number to the default (a dot). To override this, you might redefine the macro
\jcsmacro{covchapexsep}, which is predefined to \verb|{.}|.
\item[\joption{fnnumberformat=\{\jparam{template}\}}] Default: \verb|{(i)}|.
The format of the example number if \joption{fnexamplecounter=own} or \joption{fnexamplecounter=own-reset}
and example is in a footnote. For the template format, see \joption{numberformat}.
\end{description}
%
If you pass them to an environment (as optional argument of the environment), the options will only apply to that
very environment. If you want to make a global change, you can use the macro
\begin{lstlisting}[moretexcs={setexampleoptions}]
\setexampleoptions{<options>}
\end{lstlisting}
and pass either of the above options to it (as usual separated by comma). This will apply to all subsequent examples
(the \jenv{example} environment described here as well as \jenv{examples}, \jenv{subexamples} and glosses with the
\joption{ex} option) until further global change and unless an option is altered locally via optional argument.
Please refer to sec.~\ref{sec:exex} for exemplifications of the options.
\subsection[The \jenv{examples} environment]{The \jenv{examples} environment}\label{sec:exs}
To display a series of examples together, each with its own example number, use \jenv{examples}
(or \jenv{covexamples}\footnote{%
The fallback mechanism described in footnote~\ref{fn:fallbacks} for \jfenv{example} apply here, too.%
}) instead of \jenv{example} or \jenv{covexample}.
There can be more than one example with this environment, and each of them has to be introduced
by \jfcsmacro{item}, like this:
\begin{lstlisting}
\begin{examples}
\item This is the first sentence.
\item This is the second sentence.
\end{examples}
\end{lstlisting}
or, respectively:
\begin{lstlisting}
\begin{covexamples}
\item This is the first sentence.
\item This is the second sentence.
\end{covexamples}
\end{lstlisting}
This prints as:
\begin{examples}
\item This is the first sentence.
\item This is the second sentence.
\end{examples}
%
Besides to the normal optional item argument (see below), the examples environment provides an optional angular
argument which allows you to pass a judgment marker. Consider:
\begin{lstlisting}
\begin{examples}
\item<*> This sentence not is well-formed.
\item This is a well-formed sentence.
\end{examples}
\end{lstlisting}
%
This is printed as:
\begin{examples}
\item<*> This sentence not is well-formed.
\item This is a well-formed sentence.
\end{examples}
%
If you use a wider marker such as \jparam{??}, you need to adjust the width of the reserved space for the marker.
To this end, the option \joption{judgewidth=\{\jparam{text}\}} is provided (e.\,g., \verb|judgewidth={??}|).
With even wider markers, you might also need to adjust \joption{addnumbersep} to prevent the marker from coming too
close to the example number.
The \jenv{examples} environments accepts the same options than the \jenv{example} environment (please refer to
sec.~\ref{sec:ex} for details).
However, there are some notable deviations and exceptions due to the fact that we are dealing with multiple examples
in a row here:
\begin{itemize}
\item \joption{judge=\{\jparam{arbitrary text}\}} and its shorthand aliases (\joption{*}, \joption{?}, \joption{*?},
\joption{??}, and \joption{\#}) set the default judgment marker for all items in the environment.
It also sets the appropriate \joption{judgewidth} for the selected marker.
Use the aforementioned angular \jcsmacro{item} option to overwrite the preset marker or to set
one for indivual examples only.
\item \joption{preamble} and \joption{postamble[*]} do not have any effect at all. Preambles and postambles,
after all, belong to individual examples in the set rather than to the whole set of examples (or their
first and last item, respectively).
Instead of these options, we thus provide per-item solutions, which are documented in what follows.
\end{itemize}
%
For preambles and postambles, we provide specific macros, namely \jcsmacro{expreamble} and \jcsmacro{expostamble},
which can be placed where they should appear in the example, and which take the same markup than the texts passed
via \joption{preamble} or \joption{postamble} option in the \jenv{example} environment.
Hence, also here, the advantage over just adding text as is in the example is that an own, globally settable markup is used.
This is particularly relevant if you globally set examples to be italicized via the \joption{fs} option (as we have done it
in our examples in sec.~\ref{sec:exex}). Also, judgment markers are properly set after the preamble.\pagebreak[2]
\noindent Consider:
\begin{lstlisting}[moretexcs={expreamble}]
\begin{examples}
\item \expreamble{Here is Jakobson's famous poetic example:}
I like Ike!
\item \expreamble{Here is the less poetic variant:}
I am in favor of Mr. Eisenhower.
\end{examples}
\end{lstlisting}
%
This prints as follows:
\begin{examples}
\item \expreamble{Here is Jakobson's famous poetic example:}
I like Ike!
\item \expreamble{Here is the less poetic variant:}
I am in favor of Mr. Eisenhower.
\end{examples}
%
To see the advantage more clearly, let us locally set the markup of the example text:
\begin{lstlisting}[moretexcs={expreamble},morekeywords=fs]
\begin{examples}[fs={\itshape}]
\item \expreamble{Here is Jakobson's famous poetic example:}
I like Ike!
\item \expreamble{Here is the less poetic variant:}
I am in favor of Mr. Eisenhower.
\end{examples}
\end{lstlisting}
%
As you can see, the preamble text is untouched:
\begin{examples}[fs={\itshape}]
\item \expreamble{Here is Jakobson's famous poetic example:}
I like Ike!
\item \expreamble{Here is the less poetic variant:}
I am in favor of Mr. Eisenhower.
\end{examples}
%
Along the same line, consider:
\begin{lstlisting}[moretexcs={expostamble},morekeywords=fs]
\begin{examples}[fs={\itshape}]
\item I like Ike! \expostamble{(Jakobson 1960: 357)}
\item I am in favor of Mr. Eisenhower.\expostamble{\footnote{He actually wasn't.}}
\end{examples}
\end{lstlisting}
%
which results in:
\begin{examples}[fs={\itshape}]
\item I like Ike! \expostamble{(Jakobson 1960: 357)}
\item I am in favor of Mr. Eisenhower.\expostamble{\footnote{He actually wasn't.}}
\end{examples}
%
Like in any other \LaTeX\ list, the numbering can be freely set via the optional argument of \jfcsmacro{item}.
For a somewhat realistic example, observe how:
\begin{lstlisting}[moretexcs={covexnumber,exampleno}]
\begin{examples}
\item A proposition.
\item[\covexnumber{\exampleno*'}] An alternative proposition.
\end{examples}
\end{lstlisting}
%
results in:
\begin{examples}
\item A proposition.
\item[\covexnumber{\exampleno*'}] An alternative proposition.
\end{examples}
%
If you need an angular (judgment) argument and an optional argument, pass the judgment argument first
(i.\,e., \verb|\item<judgment>[custom label]|).
\subsection[The \jenv{subexamples} environment]{The \jenv{subexamples} environment}\label{sec:subexs}
Sometimes a set of (paradigmatic) sub-examples gets only one main example number with alphabetic sub-numbering,
as in \pxref{sbex} below. An ad-hoc way to achieve this is to use \jfenv{itemize} or \jfenv{enumerate}
within an example with customized items, like this:
\begin{lstlisting}
\begin{example}
\begin{itemize}
\item[(a)] This is the first sentence.
\item[(b)] This is the second sentence.
\end{itemize}
\end{example}
\end{lstlisting}
This prints as:
\begin{example}
\begin{itemize}
\item[(a)] This is the first sentence.
\item[(b)] This is the second sentence.
\end{itemize}
\end{example}
However, the \jenv{subexamples} (or \jenv{covsubexamples}\footnote{The fallback mechanism described in
footnote~\ref{fn:fallbacks} for \jfenv{example} apply here, too.%
}) environment, described in this section, is usually more convenient for
this task.
As opposed to \jenv{examples}\slash \jenv{covexamples}, this environment sub-numbers its items. Thus
\begin{lstlisting}
\begin{subexamples}
\item This is the first sentence.
\item This is the second sentence.
\end{subexamples}
\end{lstlisting}
or, respectively:
\begin{lstlisting}
\begin{covsubexamples}
\item This is the first sentence.
\item This is the second sentence.
\end{covsubexamples}
\end{lstlisting}
prints as:
\begin{subexamples}
\item This is the first sentence.\label{sbex}
\item This is the second sentence.
\end{subexamples}
%
Similar to the \jenv{examples} environment, the \jenv{subexamples} environment's item has an angular argument
to pass grammaticality judgment markers, as in:
%
\begin{subexamples}
\item This is a well-formed sentence.
\item<*> This not well-formed is.
\end{subexamples}
%
which was typed as:
\begin{lstlisting}
\begin{subexamples}
\item This is a well-formed sentence.
\item<*> This not well-formed is.
\end{subexamples}
\end{lstlisting}
%
The settings of the judgment markers (spacing and markup) is done via the options described in
sec.~\ref{sec:ex}.
The \jenv{subexamples}/\jenv{covsubexamples} environment provides the same options than the \jenv{example}
and \jenv{examples} environment (see sec.~\ref{sec:ex}) with the following deviations and additions:
\begin{description}
\item[\joption{judge=\{\jparam{arbitrary text}\}}] and its shorthand aliases (\joption{*}, \joption{?},
\joption{*?}, \joption{??}, and \joption{\#}) set the default judgment marker for all items in the environment.
It also sets the appropriate \joption{judgewidth} for the selected marker.
Use the aforementioned angular \jcsmacro{item} option to overwrite the preset marker or to set
one for indivual subexamples only.
\item[\joption{preamble=\{\jparam{arbitrary text}\}}] Arbitrary text is inserted here on the first line
(after the main number and before the first sub-example, which then follows on a new line).
This might be useful, for instance, to give context information, to specify the language or the source
in case of cited sub-examples.
\item[\joption{postamble=\{\jparam{arbitrary text}\}}] Arbitrary text is appended here after all sub-examples (on a
new line). This might be useful to add a reference or an explanation to the whole set.
\item[\joption{addsubnumbersep=\{\jparam{length}\}}] Default: \verb|{0pt}|.
Increases or (with negative values) decreases the spacing between example subnumber and example text.
\item[\joption{subnumberformat=\{\jparam{template}\}}] Default: \verb|{(a)}|.
The format of the sub-example number. For the template format, consult the documentation of
\joption{numberformat} in sec.~\ref{sec:ex}.
\end{description}
%
Also note that, if you set options globally via \jcsmacro{setexampleoptions}, the following derivating options
should be used to distinguish the \jenv{subexample} from the \jenv{example} case.
\begin{description}
\item[\joption{subjudge=\{\jparam{text}\}}] sets the default judge marker for subexamples.
\item[\joption{subpreamble=\{\jparam{arbitrary text}\}}] For a global preamble presetting in subexamples.
\item[\joption{subpostamble=\{\jparam{arbitrary text}\}}] For a global postamble presetting in subexamples.
\item[\joption{fssubpreamble=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Adjusts the font settings of subexample's preamble text and the \jcsmacro{subexpreamble}
macro described below.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\item[\joption{fssubpostamble=\{\jparam{font settings}\}}] Default: \verb|{\normalfont\upshape}|.
Tweaks the sub\-example's postamble text font settings and the \jcsmacro{subexpostamble}
macro described below.
Valid values are \LaTeX\ font switches such as \jfcsmacro{itshape}, \jfcsmacro{bfseries} etc.
\end{description}
%
For convenience, all these options actually also work (as aliases) in optional arguments passed to
\jenv{subexamples} environment.
To add additional text preceding or following specific subitems, you can principally use the \jcsmacro{expreamble} and
\jcsmacro{expostamble} macros desribed in sec.~\ref{sec:exs}. To allow for separating the markup of such texts
in subexample from the example case, we also provide specific macros, \jcsmacro{subexpreamble} and
\jcsmacro{subexpostamble} which use their own font settings (and the same than the \joption{preamble} and
\joption{postamble} options of this environment). With all these macros, judgment markers are properly set after
the preamble.
For example:
\begin{lstlisting}[moretexcs={subexpreamble},morekeywords=preamble]
\begin{covsubexamples}[preamble={Here are two sentences:}]
\item \subexpreamble{English:} This is the first sentence.
\item \subexpreamble{German:} Das ist der zweite Satz.
\end{covsubexamples}
\end{lstlisting}
%
\begin{covsubexamples}[preamble={Here are two sentences:}]
\item \subexpreamble{English:}
This is the first sentence.
\item \subexpreamble{German:}
Das ist der zweite Satz.
\end{covsubexamples}
%
Analoguously, with:
\begin{lstlisting}[moretexcs={subexpostamble}]
\begin{subexamples}
\item This is the first sentence. \subexpostamble{(Miller 2022: 15)}
\item This is the second sentence.\subexpostamble{\footnote{My own.}}
\end{subexamples}
\end{lstlisting}
%
you will get:
\begin{subexamples}
\item This is the first sentence. \subexpostamble{(Miller 2022: 15)}
\item This is the second sentence.\subexpostamble{\footnote{My own.}}
\end{subexamples}
%
More customization possibilities of examples and subexamples are elaborated in the following section.
\subsection{Examples of examples}\label{sec:exex}
As already noted, all example environments can be customized in many aspects via the example options.
If passed as an optional argument to the respective environment, the change only applies to this very environment.
If passed via \jcsmacro{setexampleoptions}, the change will apply to any subsequent \jenv{example}, \jenv{examples},
or \jenv{subexamples} environment unless a local option overrides a setting.
For this section and the purpose of demonstration, we globally set the markup of example sentences to italics,
as common in linguistics. As you now already know, this is very easy to do, via:
\begin{lstlisting}[morekeywords=fs,moretexcs={setexampleoptions}]
\setexampleoptions{fs=\itshape}
\end{lstlisting}
\setexampleoptions{fs=\itshape}
%
which applies from now on. If we now enter:
\begin{lstlisting}[morekeywords={preamble,postamble}]
\begin{example}[preamble={Consider this example:},
postamble={(German)}]
Das ist ein Satz.
\end{example}
\end{lstlisting}
%
We will get:
\begin{example}[preamble={Consider this example:},
postamble={(German)}]
Das ist ein Satz.
\end{example}
%
And with a similar subexample:
\begin{lstlisting}[morekeywords={preamble,postamble}]
\begin{subexamples}[preamble={Here are two sentences},
postamble={(Doe 1974: 12)}]
\item This is the first sentence.
\item This is the second sentence.
\end{subexamples}
\end{lstlisting}
we get the following output:
\begin{subexamples}[preamble={Here are two sentences},postamble={(Doe 1974: 12)}]
\item This is the first sentence.
\item This is the second sentence.
\end{subexamples}
%
Let us briefly demonstrate the judgment feature. If we want to mark an example as being ungrammatical,
we use the conventional asterisk mark, like this:
\begin{lstlisting}[morekeywords=judge]
\begin{example}[judge=*]
Dies ein ungrammatischem Satz ist.
\end{example}
\end{lstlisting}
%
or, shorter:
\begin{lstlisting}[morekeywords={*}, alsoletter={*}]
\begin{example}[*]
Dies ein ungrammatischem Satz ist.
\end{example}
\end{lstlisting}
%
to get:
\begin{example}[judge=*]
Dies ein ungrammatischem Satz ist.
\end{example}
%
With the \jenv{examples} and \jenv{subexamples} environment, we need to pass the marker to the item's
angular argument instead, as already demonstrated in sec.~\ref{sec:exs}:
\begin{lstlisting}
\begin{examples}
\item<*> Dies ein ungrammatischem Satz ist.
\item Dies ist ein grammatisch wohlgeformter Satz.
\end{examples}
\end{lstlisting}
%
\begin{examples}
\item<*> Dies ein ungrammatischem Satz ist.
\item Dies ist ein grammatisch wohlgeformter Satz.
\end{examples}
%
With wider markers, we need to adjust the marker width via \joption{judgewidth}, and
since we have a larger count of examples now, we also adjust \joption{addnumbersep}
to have a good space to the number:
\begin{lstlisting}[morekeywords={judgewidth,addnumbersep}]
\begin{examples}[judgewidth={??},addnumbersep={1ex}]
\item<??> Kann ich ein gratis Bier haben?
\item Kann ich ein Bier gratis haben?
\end{examples}
\end{lstlisting}
%
\begin{examples}[judgewidth={??},addnumbersep={1ex}]
\item<??> Kann ich ein gratis Bier haben?
\item Kann ich ein Bier gratis haben?
\end{examples}
%
\Cvt\ takes care that judgment markers are also properly set with preambles (with the
\jcsmacro{expreamble} and \jcsmacro{subexpreamble} macros, this requires an extra
\LaTeX\ pass). Observe how:
%
\begin{lstlisting}[moretexcs={expreamble}]
\begin{examples}
\item \expreamble{Compare this:} Oh, I am so well-formed!
\item<*> \expreamble{with this:} Lucky are you!
\end{examples}
\end{lstlisting}
%
comes out as expected:
\begin{examples}
\item \expreamble{Compare this:}
Oh, I am so well-formed!
\item<*> \expreamble{with this:}
Lucky are you!
\end{examples}
%
In what follows, we demonstrate further adjustments of the spacing of examples.
The space between the example number and the text (or the subnumber in case of subexamples)
can be adjusted, as documented above, by means of the \joption{addnumbersep} example option.
So, for instance,
\begin{lstlisting}[morekeywords={addnumbersep}]
\begin{example}[addnumbersep={2em}]
Look, I am shifted right!
\end{example}
\end{lstlisting}
will come out like this:
\begin{example}[addnumbersep={2em}]
Look, I am shifted right!
\end{example}
%
The indentation (left margin) of examples and subexamples is controlled by the \joption{leftmargin}
example option. Doing \joption{leftmargin=1em}, for instance, will increase the indentation by 1\,em,
negative values will decrease it accordingly.
For the latter, consider:
\begin{lstlisting}[morekeywords={leftmargin}]
\begin{example}[leftmargin={-2.6em}]
This is a marginal case.
\end{example}
\end{lstlisting}
which will come out like this:
%
\begin{example}[leftmargin={-2.6em}]
This is a marginal case.
\end{example}
%
In case of \jenv{subexamples}, the distance between example subnumber and text can be changed
via the \joption{addsubnumbersep} option.
Again, a positive value will increase, a negative value will decrease the distance.
Doing
\begin{lstlisting}[morekeywords={addnumbersep,addsubnumbersep}]
\begin{subexamples}[addnumbersep={-0.4em},addsubnumbersep={0.4em}]
\item My numbers have been moved.
\item Mine as well.
\end{subexamples}
\end{lstlisting}
for instance, will yield:
\begin{subexamples}[addnumbersep={-0.4em},addsubnumbersep={0.4em}]
\item My numbers have been moved.
\item Mine as well.
\end{subexamples}
%
The example also demonstrates how, in subexamples, \joption{addnumbersep} alters (here: decreases) the spacing
between main number and subnumber.
Next, we showcase how to change the display of the example number or subnumber via the \joption{numberformat} and
\joption{subnumberformat} options. As described in sec.~\ref{sec:ex}, these take a `mini template' as known from
the \textsf{enumerate} package \cite{enumerate}. In these templates, the first occurrence of the characters \jparam{1},
\jparam{i}, \jparam{I}, \jparam{a}, and \jparam{A} represents the numeric system where the respective character marks
the first positive value. All the rest of the template (including following occurrences of the mentioned characters)
is interpreted literally.
For instance, \jparam{(1)} is an alphabetic number in parentheses, \jparam{a.} a lower alphabetic value followed by a dot,
etc.
So to equip the examples with a dot after the number, we use \joption{numberformat=\{(1.)\}}
To remove the parentheses from the subexample letter, for instance, we can use \joption{subnumberformat=\{a\}}.
The following example demonstrates both options:
\begin{lstlisting}[morekeywords={numberformat,subnumberformat}]
\begin{subexamples}[numberformat={(1.)},subnumberformat={a}]
\item This is a statement.
\item This is an adjacent statement.
\end{subexamples}
\end{lstlisting}
%
And we get what we want:
\begin{subexamples}[numberformat={(1.)}, subnumberformat={a}]
\item This is a statement.
\item This is an adjacent statement.
\end{subexamples}
%
Note that the \joption{numberformat} option by default also changes the numbers of examples in footnotes, even if
\joption{fnexamplecounter=own[-reset]} is used. This does not apply to the counter format,
however. So \joption{numberformat=\{[1.])\}} will also make the example numbers in footnote appear in brackets and with the
dot, but it will still use the lower Roman numbering. Use \joption{fnnumberformat} to fully change the appearance.
With the last examples, we return to example markup. Remember, we have globally set the markup of example sentences to italics
at the beginning of this section. Now if we want to have it bold instead for one single occurence, we can reset it for the one
case via the environment options (if we wanted to change it globally from now on, we would use \jcsmacro{setexampleoptions} once more).
Observe how:
\begin{lstlisting}[morekeywords={fs,preamble,postamble}]
\begin{example}[fs=\bfseries,preamble={Note:},
postamble={(in any respect)}]
This is a bold statement!
\end{example}
\end{lstlisting}
%
results in:
\begin{example}[fs=\bfseries,preamble={Note:},
postamble={(in any respect)}]
This is a bold statement!
\end{example}
%
As outlined in sec.~\ref{sec:ex} and \ref{sec:subexs}, all elements of examples and subexamples
(number, actual example text, pre- and postamble) can be marked up independently via \joption{fsno},
\joption{fspreamble}, \joption{fspostamble}, etc. Hence, many useful (and also lots of nonsensical)
example formats are easily achievable.
\subsection{Referring to examples}\label{sec:ref}
References to examples and sub-examples can be made the usual way via the \jcsmacro{ref} command
(which refers to a \jcsmacro{label} that is placed in the respective example paragraph).
The references do not have parentheses by default, i.\,e., a reference to the example
in section~\ref{sec:ex} would be printed as \ref{expl}, a reference to the sub-example
in section~\ref{sec:subexs} as \ref{sbex}.
For convenience, though, \cvt\ provides a command \jcsmacro{pxref} that also prints the parentheses,
as in \pxref{expl} and \pxref{sbex}. It is defined as follows and can be redefined if needed:
\begin{lstlisting}[moretexcs={providecommand,pxref}]
\providecommand*\pxref[1]{(\ref{#1})}
\end{lstlisting}
\subsection{Numbering per chapter or continuously}\label{sec:cbc}
With the default (equation) counter which is used for examples, examples automatically get numbered
per chapter if the document has chapters (e.g., (2.1) for the first example in chapter~2).
If you want continuously numbered examples instead, use
\begin{lstlisting}[moretexcs={counterwithout}]
\counterwithout{equation}{chapter}
\end{lstlisting}
which also will change the equation numbering behavior.
With \joption{owncounter}, on the other hand, examples are always continuously numbered by default.
If you want examples numbered per chapter, do:
\begin{lstlisting}[moretexcs={counterwithin,ownexcounterprep}]
\counterwithin*{covex}{chapter}
\renewcommand\ownexcounterprep{\thechapter.}
\end{lstlisting}
\section{Glossing sentences word-by-word}\label{sec:gloss}
To gloss a sentence is to annotate it word-by-word. Most commonly, a
sentence in a foreign language is followed by a word-for-word
translation (with the words lined up vertically) and then a smooth
translation (not lined up), like this:
\digloss{Dit is een Nederlands voorbeeld}
{This is a Dutch example}
{This is an example in Dutch.}
\Cvt\ provides different ways to typeset such glosses. The most convenient
way is via gloss macros (see sec.~\ref{sec:gmacros}), an alternative (and the
traditional) way is via a set of commands (see sec.~\ref{sec:glosscmds}).
Both are described in turn.
\subsection{Gloss macros}\label{sec:gmacros}
\Cvt\ provides two gloss macros:
\begin{lstlisting}[moretexcs={digloss}]
\digloss[<options>]
{<gloss line 1>}[<optional comment line 1>]
{<gloss line 2>}[<optional comment line 2>]
{<free translation>}
\end{lstlisting}
typesets two-line glosses with a translation line, and optionally comments to the right side
of the gloss lines (the macro name puns on Greek \lexp{diglossía}, lit. \lmean{two tongues},
\lmean{bilingualism}).
\begin{lstlisting}[moretexcs={trigloss}]
\trigloss[<options>]
{<gloss line 1>}[<optional comment line 1>]
{<gloss line 2>}[<optional comment line 2>]
{<gloss line 3>}[<optional comment line 3>]
{<free translation>}
\end{lstlisting}
typesets three-line\footnote{The additional line can be useful for instance
to gloss cited forms, morphology, or an additional translation.
See sec.~\ref{sec:glossex} for examples.}
glosses with a translation line and optional comments (cf. Greek \lexp{triglossía},
lit. \lmean{three tongues}, \lmean{trilingualism}).
The example given above would thus be typed as:
\begin{lstlisting}[moretexcs={digloss}]
\digloss{Dit is een Nederlands voorbeeld}
{This is a Dutch example}
{This is an example in Dutch.}
\end{lstlisting}
%
Note that:
\begin{itemize}
\item The \jparam{free translation} argument can be left empty. In this case, no translation line is added
(and no extra space taken).
\item The macros automatically markup the lines.
By default, the first gloss line is in italics, subsequent lines are set upright, and the
free translation in single quotation marks (using the language-sensitive \textsf{csquotes}
\cite{csquotes} macros if this package is loaded). This can be customized, though, via the
macro options or globally via the macro \jcsmacro{setglossoptions} which will be documented below.
\item By default, page breaks might occur within glosses. In order to prevent it, the package option
\joption{noglossbreaks} (see sec.~\ref{sec:intro}) will help in many cases.
If it doesn't, you can wrap the whole gloss into a minipage or parbox.
\item The words do not have to be typed lining up; \TeX\ counts and aligns them.
\item On the other hand, multiple blanks are ignored, so you can, but do not need to,
use the space key to line up the words to your liking in the \TeX\ file.
The example above could thus also have been input like this, with no change to the output:
\begin{lstlisting}[moretexcs={digloss}]
\digloss{Dit is een Nederlands voorbeeld}
{This is a Dutch example}
{This is an example in Dutch.}
\end{lstlisting}
\item If the words in the two languages do not correspond one-to-one, you can use curly brackets
to group words and a pair of empty curly brackets to mark null forms.
For example, to print
\digloss{Dit is een voorbeeldje in het Nederlands}
{This is a {little example} in {} Dutch}
{This is a little example in Dutch.}
you would type:
\begin{lstlisting}[moretexcs={digloss}]
\digloss{Dit is een voorbeeldje in het Nederlands}
{This is a {little example} in {} Dutch}
{This is a little example in Dutch.}
\end{lstlisting}
\end{itemize}
\medskip
\noindent The following \joption{\jparam{options}} (key-value pairs) are provided for the two gloss macro:%
\footnote{Please consult sec.~\ref{sec:glossex} below for examples that showcase these options.}
\begin{description}
\item[\joption{ex=\jparam{true|false}}] Default: \emph{false}. Wraps the gloss in an example environment
(i.\,e., it is numbered). In this case, any example settings done via \jcsmacro{setexampleoptions}
(sec.~\ref{sec:ex}) apply.