]> git.lyx.org Git - lyx.git/blob - lib/layouts/linguistics.module
Update non-counter layouts to format 10.
[lyx.git] / lib / layouts / linguistics.module
1 #\DeclareLyXModule[covington.sty]{Linguistics}
2 #DescriptionBegin
3 #Defines some special environments useful for linguistics (numbered examples,
4 #glosses, semantic markup, tableau floats).
5 #See linguistics.lyx file in examples.
6 #DescriptionEnd
7
8 # Author: Jürgen Spitzmüller <spitz@lyx.org>
9
10 Format 10
11
12 # single numbered example with covington.sty
13 Style Numbered_Example_(multiline)
14         LatexType             Environment
15         LatexName             example
16         NextNoIndent          1
17         LeftMargin            XExample:
18         LabelSep              xx
19         ParSkip               0.0
20         ItemSep               0.2
21         TopSep                0.7
22         BottomSep             0.7
23         ParSep                0.3
24         Align                 Block
25         AlignPossible         Block, Left
26         LabelType             Static
27         LabelString           "Example:"
28         LabelFont
29                 Shape         Italic
30                 Color         Blue
31         EndFont
32         Requires              covington
33 End
34
35
36 # multiple numbered examples with covington.sty
37 Style Numbered_Examples_(consecutive)
38         CopyStyle             Numbered_Example_(multiline)
39         Margin                Static
40         LeftMargin            XExamples:
41         LatexType             Item_Environment
42         LatexName             examples
43         LabelString           "Examples:"
44 End
45
46
47 # multiple numbered example with covington.sty
48 Style Subexample
49         CopyStyle             Numbered_Example_(multiline)
50         Margin                Static
51         LatexType             Item_Environment
52         LatexName             subexample
53         LeftMargin            XSubexample:
54         LabelString           "Subexample:"
55         Requires              covington,enumitem
56         Preamble
57                 \newenvironment{subexample}{%
58                         \begin{example}\begin{enumerate}[leftmargin=1.7em]
59                         \renewcommand\theenumi{\alph{enumi}}
60                         \renewcommand\labelenumi{(\theenumi)}
61                         \renewcommand\p@enumi{\theequation\,}}%
62                         {\end{enumerate}\end{example}}
63         EndPreamble
64 End
65
66
67 # glosse (2 lines) with covington.sty
68 # mandatory translation must be entered verbatim!
69 InsetLayout Custom:Glosse
70         LyXType               custom
71         LabelString           Glosse
72         LatexType             environment
73         LatexName             linggloss
74         Decoration            minimalistic
75         LabelFont
76           Size                Small
77         EndFont
78         MultiPar              true
79         CustomPars            false
80         ForcePlain            true
81         PassThru              true
82         FreeSpacing           true
83         Requires              covington
84         Preamble
85                 \@ifundefined{linggloss}{%
86                 \newenvironment{linggloss}[1]{%
87                         \gll #1}
88                 {\glend}}{}
89         EndPreamble
90 End
91
92
93 # glosse (3 lines) with covington.sty
94 # mandatory translation must be entered verbatim!
95 InsetLayout Custom:Tri-Glosse
96         LyXType               custom
97         LabelString           Tri-Glosse
98         LatexType             environment
99         LatexName             lingglosss
100         Decoration            minimalistic
101         LabelFont
102           Size                Small
103         EndFont
104         MultiPar              true
105         CustomPars            false
106         ForcePlain            true
107         PassThru              true
108         FreeSpacing           true
109         Requires              covington
110         Preamble
111                 \@ifundefined{lingglosss}{%
112                 \newenvironment{lingglosss}[1]{%
113                         \glll #1}
114                 {\glend}}{}
115         EndPreamble
116 End
117
118
119 # Some semantik markup for Semantics
120 InsetLayout CharStyle:Expression
121         LyxType               charstyle
122         LabelString           expr.
123         LatexType             command
124         LatexName             lingexpr
125         Font
126           Shape               Italic
127         EndFont
128         Preamble
129                 \newcommand{\lingexpr}[1]{\emph{#1}}
130         EndPreamble
131 End
132
133
134 InsetLayout CharStyle:Concepts
135         LyxType               charstyle
136         LabelString           concept
137         LatexType             command
138         LatexName             lingconcept
139         Font
140           Shape               Smallcaps
141         EndFont
142         Preamble
143                 \newcommand{\lingconcept}[1]{\textsc{#1}}
144         EndPreamble
145 End
146
147
148 InsetLayout CharStyle:Meaning
149         LyxType               charstyle
150         LabelString           meaning
151         LatexType             command
152         LatexName             lingmeaning
153         Requires              csquotes
154         Preamble
155                 \newcommand{\lingmeaning}[1]{\enquote*{#1}}
156         EndPreamble
157 End
158
159
160 # Tableaux for Optimality Theory
161 Float
162         Type                  tableau
163         GuiName               Tableau
164         Placement             tbp
165         Extension             otl
166         NumberWithin          none
167         Style                 plain
168         ListName              "List of Tableaux"
169         LaTeXBuiltin          false
170 End
171
172 InsetLayout tableau
173         LabelString           Tableau
174         LabelFont
175           Color               collapsable
176           Size                Small
177         EndFont
178         MultiPar              true
179 End