]> git.lyx.org Git - lyx.git/blob - lib/layouts/linguistics.module
Current covington requires varwidth
[lyx.git] / lib / layouts / linguistics.module
1 #\DeclareLyXModule[covington.sty,drs.sty,forest.sty,pict2e.sty,varwidth.sty]{Linguistics}
2 #\DeclareCategory{Academic Field Specifics}
3 #DescriptionBegin
4 #Defines some special environments useful for linguistics (numbered examples,
5 #glosses, semantic markup, tableau floats).
6 #See Help > Specific Manuals > Linguistics.
7 #DescriptionEnd
8
9 # Author: Jürgen Spitzmüller <spitz@lyx.org>
10
11 Format 100
12
13 #
14 # Counters
15 #
16
17 Counter example
18         GuiName Example
19         Within               chapter
20         LabelString          "(\arabic{example})"
21 End
22
23 Counter examplei
24         GuiName              "Numbered Example (Multiline)"
25         Within               chapter
26         LabelString          "(\arabic{examplei})"
27 End
28
29 Counter subexample
30         GuiName              Subexample
31         Within               examplei
32         LabelString          "\theexamplei (\alph{subexample})"
33 End
34
35 Counter subexamplei
36         GuiName              Subexample
37         Within               examplei
38         LabelString          "\theexamplei (\alph{subexamplei})"
39 End
40
41 Counter subexampleii
42         GuiName              Subexample
43         Within               examplei
44         LabelString          "\theexamplei (\alph{subexampleii})"
45 End
46
47 Counter subexampleiii
48         GuiName              Subexample
49         Within               examplei
50         LabelString          "\theexamplei (\alph{subexampleiii})"
51 End
52
53 Counter subexampleiv
54         GuiName              Subexample
55         Within               examplei
56         LabelString          "\theexamplei (\alph{subexampleiv})"
57 End
58
59 #
60 # Numbered Examples
61 #
62
63 # Single numbered example with covington.sty
64 Style Numbered_Example_(multiline)
65         LatexType             Environment
66         LatexName             covexample
67         NextNoIndent          1
68         Margin                First_Dynamic
69         ParIndent             (1)x
70         LabelSep              xx
71         ParSkip               0.0
72         ItemSep               0.2
73         TopSep                0.7
74         BottomSep             0.7
75         ParSep                0.3
76         Align                 Block
77         AlignPossible         Block, Left
78         LabelType             Static
79         LabelCounter          "examplei"
80         LabelFont
81                 Color         textlabel1
82         EndFont
83         Requires              covington
84         Argument 1
85                 LabelString   "Example options"
86                 MenuString    "Examples options|s"
87                 Tooltip       "Add examples options here"
88                 PassThru       1
89         EndArgument
90         Category              Linguistics
91         DocBookWrapperTag     informalexample
92         DocBookWrapperAttr    role='numbered'
93         DocBookWrapperMergeWithPrevious  true
94         DocBookTag            para
95 End
96
97
98 # Multiple numbered examples with covington.sty
99 Style Numbered_Examples_(consecutive)
100         CopyStyle             Numbered_Example_(multiline)
101         LatexType             Item_Environment
102         LatexName             covexamples
103         LabelType             Enumerate
104         LabelCounter          "example"
105         ResumeCounter         true
106         Argument listpreamble:1
107                 LabelString    "List preamble"
108                 MenuString     "List Preamble"
109                 Tooltip        "LaTeX code to be inserted before the first item"
110                 PassThru       1
111                 Font
112                         Family typewriter
113                         Color latex
114                 EndFont
115         EndArgument
116         Argument item:1
117                 LabelString   "Judgment|J"
118                 Tooltip       "Grammaticality judgment marker"
119                 LeftDelim     <
120                 RightDelim    >
121         EndArgument
122         Argument item:2
123                 LabelString   "Custom Numbering|s"
124                 Tooltip       "Customize the numeration"
125         EndArgument
126         DocBookWrapperTag     informalexample
127         DocBookWrapperAttr    role='consecutive'
128         DocBookWrapperMergeWithPrevious  true
129         DocBookTag            para
130         HTMLClass             NumberedExample
131 End
132
133
134 # Sub-examples with covington.sty
135 Style Subexample
136         CopyStyle             Numbered_Examples_(consecutive)
137         LatexName             covsubexamples
138         LabelCounter          "subexample"
139         StepParentCounter     true
140         Requires              covington
141         Argument 1
142                 LabelString   "Subexamples options"
143                 MenuString    "Subexamples options|s"
144                 Tooltip       "Add subexamples options here"
145                 PassThru       1
146         EndArgument
147         HTMLClass          SubExample
148 End
149
150 InsetLayout Flex:Example_Preamble
151         LyXType               custom
152         Decoration            classic
153         LatexType             command
154         LatexName             expreamble
155         LabelString           "Ex. Preamble"
156         ResetsFont            true
157 End
158
159 InsetLayout Flex:Subexample_Preamble
160         CopyStyle             Flex:Example_Preamble
161         LatexName             subexpreamble
162         LabelString           "Subex. Preamble"
163 End
164
165
166 InsetLayout Flex:Example_Postamble
167         CopyStyle             Flex:Example_Preamble
168         LatexName             expostamble
169         LabelString           "Ex. Postamble"
170 End
171
172 InsetLayout Flex:Subexample_Postamble
173         CopyStyle             Flex:Example_Preamble
174         LatexName             subexpostamble
175         LabelString           "Subex. Postamble"
176 End
177
178
179 #
180 # Interlinear Glosses
181 #
182
183 # Two-Line gloss with covington.sty
184 InsetLayout Flex:Interlinear_Gloss_(2_Lines)
185         LyXType               custom
186         LabelString           Gloss
187         LatexType             command
188         LatexName             digloss
189         Decoration            minimalistic
190         LabelFont
191           Size                Small
192         EndFont
193         MultiPar              true
194         CustomPars            false
195         ForcePlain            true
196         ParbreakIgnored       true
197         FreeSpacing           true
198         Requires              covington,csquotes
199         InToc                 true
200         ResetsFont            true
201         Argument 1
202                 LabelString   "Gloss options"
203                 MenuString    "Gloss Options|s"
204                 Tooltip       "Add digloss options here"
205         EndArgument
206         Argument post:1
207                 LabelString   "Sentence Comment"
208                 MenuString    "Sentence Comment"
209                 Tooltip       "Add an optional sentence comment here"
210         EndArgument
211         Argument post:2
212                 Decoration    conglomerate
213                 LabelString   "Interlinear Gloss"
214                 MenuString    "Interlinear Gloss"
215                 Tooltip       "Add the inter-linear gloss here"
216                 AutoInsert    true
217                 Mandatory     true
218                 FreeSpacing   true
219                 InsertOnNewline true
220         EndArgument
221         Argument post:3
222                 LabelString   "Gloss Comment"
223                 MenuString    "Gloss Comment"
224                 Tooltip       "Add an optional gloss comment here"
225         EndArgument
226         Argument post:4
227                 Decoration    conglomerate
228                 LabelString   "Translation"
229                 MenuString    "Gloss Translation"
230                 Tooltip       "Add a free translation for the gloss"
231                 AutoInsert    true
232                 Mandatory     true
233                 FreeSpacing   true
234                 InsertOnNewline true
235         EndArgument
236 End
237
238
239 # Three-Line gloss with covington.sty
240 InsetLayout Flex:Interlinear_Gloss_(3_Lines)
241         LyXType               custom
242         LabelString           Tri-Gloss
243         LatexType             command
244         LatexName             trigloss
245         Decoration            minimalistic
246         LabelFont
247           Size                Small
248         EndFont
249         MultiPar              true
250         CustomPars            false
251         ForcePlain            true
252         ParbreakIgnored       true
253         FreeSpacing           true
254         InToc                 true
255         Requires              covington,csquotes
256         ResetsFont            true
257         Argument 1
258                 LabelString   "Gloss options"
259                 MenuString    "Gloss Options|s"
260                 Tooltip       "Add trigloss options here"
261         EndArgument
262         Argument post:1
263                 LabelString   "Sentence Comment"
264                 MenuString    "Sentence Comment"
265                 Tooltip       "Add an optional sentence comment here"
266         EndArgument
267         Argument post:2
268                 Decoration    conglomerate
269                 LabelString   "Interlinear Gloss (1)"
270                 MenuString    "Interlinear Gloss (Line 1)|1"
271                 Tooltip       "Add the first inter-linear gloss line here"
272                 Mandatory     true
273                 AutoInsert    true
274                 FreeSpacing   true
275                 InsertOnNewline true
276         EndArgument
277         Argument post:3
278                 LabelString   "Gloss Comment (1)"
279                 MenuString    "Gloss Comment (Line 1)"
280                 Tooltip       "Add an optional gloss comment here"
281         EndArgument
282         Argument post:4
283                 Decoration    conglomerate
284                 LabelString   "Interlinear Gloss (2)"
285                 MenuString    "Interlinear Gloss (Line 2)|2"
286                 Tooltip       "Add the second inter-linear gloss line here"
287                 Mandatory     true
288                 AutoInsert    true
289                 FreeSpacing   true
290                 InsertOnNewline true
291         EndArgument
292         Argument post:5
293                 LabelString   "Gloss Comment (2)"
294                 MenuString    "Gloss Comment (Line 2)"
295                 Tooltip       "Add an optional gloss comment here"
296         EndArgument
297         Argument post:6
298                 Decoration    conglomerate
299                 LabelString   "Translation"
300                 MenuString    "Gloss Translation"
301                 Tooltip       "Add a translation for the glosse"
302                 Mandatory     true
303                 AutoInsert    true
304                 InsertOnNewline true
305         EndArgument
306 End
307
308
309 # A helper to group words in glosses
310 InsetLayout Flex:GroupGlossedWords
311         LyxType               charstyle
312         LabelString           Group
313         LeftDelim             {
314         RightDelim            }
315         ResetsFont            true
316 End
317
318
319 #
320 # Trees
321 #
322
323 # Structure trees via the forest package
324 InsetLayout Flex:Structure_Tree
325         LyXType               custom
326         LabelString           Tree
327         LatexType             environment
328         LatexName             forest
329         Decoration            classic
330         LabelFont
331           Size                Small
332         EndFont
333         MultiPar              true
334         CustomPars            false
335         ParbreakIsNewline     true
336         FreeSpacing           true
337         Requires              forest
338         ResetsFont            true
339         PassThruChars         []
340         Preamble
341         % Load forest linguistics library, if available
342         \@ifpackagelater{forest}{2016/02/20}{%
343         \useforestlibrary*{linguistics}
344         }{}
345         EndPreamble
346     DocBookRenderAsImage  true
347 End
348
349
350 #
351 # Discourse Representation Structures
352 #
353
354 InsetLayout Flex:DRS
355         LyXType               custom
356         LabelString           DRS
357         MenuString            "Discourse Representation Structure|D"
358         LatexType             command
359         LatexName             drs
360         Decoration            classic
361         MultiPar              true
362         CustomPars            false
363         ParbreakIsNewline     true
364         FreeSpacing           true
365         Requires              drs
366         ResetsFont            true
367         Argument 1
368                 Decoration    conglomerate
369                 LabelString   "Referents"
370                 MenuString    "DRS Referents"
371                 Tooltip       "Add the DRS referents (universe) here"
372                 Mandatory     true
373                 AutoInsert    true
374         EndArgument
375 End
376
377
378 InsetLayout Flex:DRS*
379         CopyStyle             Flex:DRS
380         LabelString           DRS*
381         MenuString            "Discourse Representation Structure (unspaced)|u"
382         LatexName             drs*
383 End
384
385
386 InsetLayout Flex:IfThen-DRS
387         CopyStyle             Flex:DRS
388         LabelString           "If-Then DRS"
389         MenuString            "If-Then DRS"
390         LatexName             ifdrs
391         Argument post:1
392                 Decoration    classic
393                 LabelString   "Then-Referents"
394                 MenuString    "DRS Then-Referents"
395                 Tooltip       "Add the DRS then-referents (universe) here"
396                 Mandatory     true
397                 AutoInsert    true
398                 InsertOnNewline true
399         EndArgument
400         Argument post:2
401                 Decoration    classic
402                 LabelString   "Then-Conditions"
403                 MenuString    "DRS Then-Referents"
404                 Tooltip       "Add the DRS then-conditions here"
405                 Mandatory     true
406                 AutoInsert    true
407                 InsertOnNewline true
408         EndArgument
409 End
410
411
412 InsetLayout Flex:Cond-DRS
413         CopyStyle             Flex:DRS
414         LabelString           "Cond. DRS"
415         MenuString            "Conditional DRS"
416         LatexName             condrs
417         Argument post:1
418                 Decoration    classic
419                 LabelString   "Cond."
420                 MenuString    "DRS Condition"
421                 Tooltip       "Add the DRS condition here"
422                 Mandatory     true
423                 AutoInsert    true
424                 InsertOnNewline true
425         EndArgument
426         Argument post:2
427                 Decoration    classic
428                 LabelString   "Then-Referents"
429                 MenuString    "DRS Then-Referents"
430                 Tooltip       "Add the DRS then-referents (universe) here"
431                 Mandatory     true
432                 AutoInsert    true
433                 InsertOnNewline true
434         EndArgument
435         Argument post:3
436                 Decoration    classic
437                 LabelString   "Then-Conditions"
438                 MenuString    "DRS Then-Referents"
439                 Tooltip       "Add the DRS then-conditions here"
440                 Mandatory     true
441                 AutoInsert    true
442                 InsertOnNewline true
443         EndArgument
444 End
445
446
447 InsetLayout Flex:QDRS
448         CopyStyle             Flex:DRS
449         LabelString           "Dupl. Cond. DRS"
450         MenuString            "Duplex Condition DRS"
451         LatexName             qdrs
452         Argument post:1
453                 Decoration    classic
454                 LabelString   "Quant."
455                 MenuString    "DRS Quantifier"
456                 Tooltip       "Add the DRS duplex quantifier here"
457                 Mandatory     true
458                 AutoInsert    true
459                 InsertOnNewline true
460         EndArgument
461         Argument post:2
462                 Decoration    classic
463                 LabelString   "Quant. Var."
464                 MenuString    "DRS Quantifier Variable"
465                 Tooltip       "Add the DRS duplex quantifier variables here"
466                 Mandatory     true
467                 AutoInsert    true
468                 InsertOnNewline true
469         EndArgument
470         Argument post:3
471                 Decoration    classic
472                 LabelString   "Then-Referents"
473                 MenuString    "DRS Then-Referents"
474                 Tooltip       "Add the DRS then-referents (universe) here"
475                 Mandatory     true
476                 AutoInsert    true
477                 InsertOnNewline true
478         EndArgument
479         Argument post:4
480                 Decoration    classic
481                 LabelString   "Then-Conditions"
482                 MenuString    "DRS Then-Referents"
483                 Tooltip       "Add the DRS then-conditions here"
484                 Mandatory     true
485                 AutoInsert    true
486                 InsertOnNewline true
487         EndArgument
488         Requires              drs,pict2e
489 End
490
491
492 InsetLayout Flex:NegDRS
493         CopyStyle             Flex:DRS
494         LabelString           "Neg. DRS"
495         MenuString            "Negated DRS"
496         LatexName             negdrs
497 End
498
499
500 InsetLayout Flex:SDRS
501         CopyStyle             Flex:DRS
502         LabelString           "Sent. DRS"
503         MenuString            "DRS with Sentence above"
504         LatexName             sdrs
505         Argument 1
506                 Decoration    conglomerate
507                 LabelString   "Sentence"
508                 MenuString    "DRS Sentence"
509                 Tooltip       "Add the sentence here"
510                 Mandatory     true
511                 AutoInsert    true
512                 InsertOnNewline true
513         EndArgument
514         Argument 2
515                 Decoration    conglomerate
516                 LabelString   "Referents"
517                 MenuString    "DRS Referents"
518                 Tooltip       "Add the DRS referents (universe) here"
519                 Mandatory     true
520                 AutoInsert    true
521                 InsertOnNewline true
522         EndArgument
523 End
524
525
526 #
527 # Semantic Markup
528 #
529
530 InsetLayout Flex:Expression
531         LyxType               charstyle
532         LabelString           expr.
533         LatexType             command
534         LatexName             lexp
535         Requires              covington
536         Font
537           Shape               Italic
538         EndFont
539         InToc                 true
540         ResetsFont            true
541 End
542
543
544 InsetLayout Flex:Concepts
545         LyxType               charstyle
546         LabelString           concept
547         LatexType             command
548         LatexName             lcon
549         Requires              covington
550         Font
551           Shape               Smallcaps
552         EndFont
553         InToc                 true
554         ResetsFont            true
555 End
556
557
558 InsetLayout Flex:Meaning
559         LyxType               charstyle
560         LabelString           meaning
561         LatexType             command
562         LatexName             lmean
563         Requires              covington,csquotes
564         InToc                 true
565         ResetsFont            true
566 End
567
568
569 #
570 # OT Tableaux
571 #
572
573 OutlinerName tableau        "Tableaux" #no AddToToc
574
575 Float
576         Type                  tableau
577         GuiName               Tableau
578         Placement             tbp
579         Extension             otl
580         NumberWithin          none
581         Style                 plain
582         ListName              "List of Tableaux"
583         IsPredefined          false
584         UsesFloatPkg          true
585 End
586