1 #\DeclareLyXModule[covington.sty,enumitem.sty,forest.sty]{Linguistics}
3 #Defines some special environments useful for linguistics (numbered examples,
4 #glosses, semantic markup, tableau floats).
5 #See linguistics.lyx file in examples.
8 # Author: Jürgen Spitzmüller <spitz@lyx.org>
14 LabelString "(\arabic{example})"
19 LabelString "(\arabic{examplei})"
24 LabelString "\theexamplei (\alph{subexample})"
29 LabelString "\theexamplei (\alph{subexamplei})"
32 # single numbered example with covington.sty
33 Style Numbered_Example_(multiline)
46 AlignPossible Block, Left
48 LabelCounter "examplei"
54 % Backwards compatibility with covington < 1.1
55 % This code can be removed eventually
56 \@ifundefined{covexample}{%
57 \newenvironment{covexample}{\begin{example}}{\end{example}}%
64 # multiple numbered examples with covington.sty
65 Style Numbered_Examples_(consecutive)
66 CopyStyle Numbered_Example_(multiline)
67 LatexType Item_Environment
70 LabelCounter "example"
73 LabelString "Custom Numbering|s"
74 Tooltip "Customize the numeration"
77 % Backwards compatibility with covington < 1.1
78 % This code can be removed eventually
79 \@ifundefined{covexamples}{%
80 \newenvironment{covexamples}{\begin{examples}}{\end{examples}}%
86 # multiple numbered example with covington.sty
88 CopyStyle Numbered_Examples_(consecutive)
90 LabelCounter "subexample"
91 StepMasterCounter true
92 Requires covington,enumitem
94 \newenvironment{subexample}{%
95 \begin{example}\begin{enumerate}[leftmargin=1.7em]
96 \renewcommand\theenumi{\alph{enumi}}
97 \renewcommand\labelenumi{(\theenumi)}
98 \renewcommand\p@enumi{\theequation\,}}%
99 {\end{enumerate}\end{example}}
104 # glosse (2 lines) with covington.sty
105 InsetLayout Flex:Glosse
108 LatexType environment
110 Decoration minimalistic
117 ParbreakIsNewline true
122 \@ifundefined{linggloss}{%
123 \newenvironment{linggloss}[2][]{
124 \def\glosstr{\glt #1}%
131 Decoration conglomerate
132 LabelString "Translation"
133 MenuString "Glosse Translation|s"
134 Tooltip "Add a translation for the glosse"
139 # glosse (3 lines) with covington.sty
140 InsetLayout Flex:Tri-Glosse
142 LabelString Tri-Glosse
143 LatexType environment
145 Decoration minimalistic
152 ParbreakIsNewline true
158 \@ifundefined{lingglosss}{%
159 \newenvironment{lingglosss}[2][]{
160 \def\glosstr{\glt #1}%
166 Decoration conglomerate
167 LabelString "Translation"
168 MenuString "Glosse Translation|s"
169 Tooltip "Add a translation for the glosse"
174 # Structure trees via the forest package
175 InsetLayout Flex:Structure_Tree
178 LatexType environment
186 ParbreakIsNewline true
192 % Load forest linguistics library, if available
193 \@ifpackagelater{forest}{2016/02/20}{%
194 \useforestlibrary*{linguistics}
200 # Some semantik markup for Semantics
201 InsetLayout Flex:Expression
210 \newcommand{\lingexpr}[1]{\emph{#1}}
217 InsetLayout Flex:Concepts
221 LatexName lingconcept
226 \newcommand{\lingconcept}[1]{\textsc{#1}}
233 InsetLayout Flex:Meaning
237 LatexName lingmeaning
240 \newcommand{\lingmeaning}[1]{\enquote*{#1}}
247 # A helper to group words in Glosses
248 InsetLayout Flex:GroupGlossedWords
257 # Tableaux for Optimality Theory
265 ListName "List of Tableaux"