]> git.lyx.org Git - lyx.git/blob - lib/layouts/stdinsets.inc
5aca78800623e37067d1b2d2f7a090e8cf1b1a88
[lyx.git] / lib / layouts / stdinsets.inc
1 # Textclass definition file for LaTeX.
2 # Author : Martin vermeer <martin.vermeer@hut.fi>
3 # Inset layouts definition
4 #
5 # Detailed format description is available in the customization manual
6
7 Format 67
8
9 Provides stdinsets 1
10
11 OutlinerName marginalnote "Marginal notes"
12 OutlinerName footnote     "Footnotes"
13 OutlinerName note         "Notes"
14 OutlinerName branch       "Branches"
15 OutlinerName index        "Index Entries" #no AddToToc (built-in)
16 OutlinerName listing      "Listings" #no AddToToc (built-in)
17
18 InsetLayout Marginal
19         LabelString           margin
20         LatexType             command
21         LatexName             marginpar
22         Font
23           Size                Small
24         EndFont
25         LabelFont
26           Color               marginlabel
27           Size                Small
28         EndFont
29         MultiPar              true
30         NeedProtect           true
31         HTMLStyle
32                 div.marginal {
33                         border: 2px solid black;
34                         padding: 1ex;
35                         margin: 1ex;
36                         background-color: #F0F0F0;
37                         float:right;
38                         font-size: small;
39                         font-weight: medium;
40                         font-family: serif;
41                         font-variant: normal;
42                         font-style: normal;
43                 }
44         EndHTMLStyle
45         AddToToc              marginalnote
46         IsTocCaption          true
47 End
48
49 InsetLayout Foot
50         LabelString           foot
51         LatexType             Command
52         LatexName             footnote
53         Counter               footnote
54         Font
55           Size                Small
56         EndFont
57         LabelFont
58           Color               footlabel
59           Size                Small
60         EndFont
61         MultiPar              true
62         RefPrefix             fn
63         HTMLLabel             \arabic{footnote}
64         HTMLInnerTag          div
65         HTMLStyle
66                 span.foot_label {
67                         vertical-align: super;
68                         font-size: smaller;
69                         font-weight: bold;
70                         text-decoration: underline;
71                 }
72                 div.foot {
73                         display: inline;
74                         font-size: small;
75                         font-weight: medium;
76                         font-family: serif;
77                         font-variant: normal;
78                         font-style: normal;
79                 }
80                 div.foot_inner { display: none; }
81                 div.foot:hover div.foot_inner {
82                         display: block;
83                         border: 1px double black;
84                         margin: 0em 1em;
85                         padding: 1em;
86                 }
87         EndHTMLStyle
88         AddToToc              footnote
89         IsTocCaption          true
90 End
91
92 InsetLayout Foot:InTitle
93         CopyStyle             Foot
94         LatexName             thanks
95         NeedProtect           true
96         Counter               thanks
97         MultiPar              false
98         HTMLLabel             \fnsymbol{thanks}
99         HTMLInnerTag          span
100         HTMLStyle
101                 span.foot_intitle_label {
102                         vertical-align: super;
103                         font-size: smaller;
104                         font-weight: bold;
105                         text-decoration: underline;
106                 }
107                 span.foot_intitle {
108                         display: inline;
109                         font-size: small;
110                         font-weight: medium;
111                         font-family: serif;
112                         font-variant: normal;
113                         font-style: normal;
114                 }
115                 span.foot_intitle_inner { display: none; }
116                 span.foot_intitle:hover span.foot_intitle_inner {
117                         display: block;
118                         border: 1px double black;
119                         margin: 0em 1em;
120                         padding: 1em;
121                 }
122         EndHTMLStyle
123 End
124
125 InsetLayout Foot:InFloatTable
126         CopyStyle             Foot
127         LatexName             tablefootnote
128         Requires              tablefootnote
129 End
130
131
132 InsetLayout Note:Comment
133         LabelString           Comment
134         LatexType             environment
135         LatexName             comment
136         Requires              verbatim
137         BgColor               commentbg
138         LabelFont
139           Color               comment
140           Size                Small
141         EndFont
142         MultiPar              true
143         Display               false
144         HTMLTag               div
145         HTMLIsBlock           true
146         HTMLStyle
147         div.note_comment {
148                 display: none;
149         }
150         EndHTMLStyle
151         AddToToc              note
152         IsTocCaption          true
153         NeedCProtect          true
154 End
155
156
157 InsetLayout Note:Note
158         LabelString           Note
159         LatexType             command
160         LatexName             note
161         BgColor               notebg
162         LabelFont
163           Color               note
164           Size                Small
165         EndFont
166         MultiPar              true
167         # Not output for XHTML
168         AddToToc              note
169         IsTocCaption          true
170 End
171
172
173 InsetLayout Note:Greyedout
174         LabelString           Greyedout
175         LatexType             environment
176         LatexName             lyxgreyedout
177         Requires              color,lyxgreyedout
178         BgColor               greyedoutbg
179         Font
180           Color               greyedouttext
181         EndFont
182         LabelFont
183           Color               greyedout
184           Size                Small
185         EndFont
186         MultiPar              true
187         Display               false
188         HTMLInnerTag div
189         HTMLStyle
190                 div.note_greyedout {
191                         display: inline;
192                         color: #A0A0A0;
193                         padding-left: 1ex;
194                         padding-right: 1ex;
195                 }
196         EndHTMLStyle
197         HTMLIsBlock           false
198         AddToToc              note
199         IsTocCaption          true
200         NeedCProtect          true
201 End
202
203 InsetLayout ERT
204         LabelString           ERT
205         LatexType             none
206         Decoration            minimalistic
207         Font
208           Color               latex
209           Family              typewriter
210         EndFont
211         LabelFont
212           Color               latex
213           Size                Small
214         EndFont
215         MultiPar              true
216         CustomPars            false
217         ForcePlain            true
218         PassThru              true
219         ParbreakIsNewline     true
220         KeepEmpty             true
221         FreeSpacing           true
222         ForceLTR              true
223 End
224
225 InsetLayout Phantom
226         Decoration            minimalistic
227         Font
228           Color               phantomtext
229         EndFont
230         MultiPar              false
231         CustomPars            false
232         ForcePlain            true
233 End
234
235 InsetLayout IPADeco
236         Decoration            minimalistic
237         Font
238           Color               foreground
239         EndFont
240         MultiPar              false
241         CustomPars            false
242         ForcePlain            true
243 End
244
245 InsetLayout TOC
246   HTMLTag h2
247   HTMLStyle
248     div.toc {
249       margin: 2em 0em;
250       border-style: solid;
251       border-width: 2px 0px;
252       padding: 1em 0em;
253     }
254     h2.tochead { font-size: x-large; font-weight: bold; }
255     div.lyxtoc-0 {
256       margin: 2em 0em 0em 0em;
257       font-size: xx-large;
258       font-weight: bold;
259     }
260     div.lyxtoc-1 {
261       margin: 1em 0em 0em 0em;
262       font-size: x-large;
263       font-weight: bold;
264     }
265     div.lyxtoc-2 {
266       margin: 0em 0.1em 0em 1em;
267       font-size: large;
268       font-weight: normal;
269     }
270     div.lyxtoc-3 { margin: 0em 0.1em 0em 0.5em; font-size: medium; }
271     div.lyxtoc-4 { margin: 0em 0.1em 0em 0.5em; }
272     div.lyxtoc-5 { margin: 0em 0.1em 0em 0.5em; }
273     div.lyxtoc-6 { margin: 0em 0.1em 0em 0.5em; }
274     a.tocentry {
275       text-decoration: none;
276       color: black;
277     }
278     a.tocentry:visited { color: black; }
279   EndHTMLStyle
280 End
281
282 InsetLayout TOC:Listings
283         # We need the [[List of Listings]] context, since "Listings" is also
284         # the name of the inset and translated differently.
285         # "Listings[[List of Listings]]" is the name of the "List of listings"
286         # ("Listings" is the predefined english name) in listings.sty, so it
287         # must be used here as well.
288         BabelPreamble
289                 \addto\captions$$lang{\renewcommand{\lstlistlistingname}{_(Listings[[List of Listings]])}}
290         EndBabelPreamble
291         # The command does not need to be defined in LangPreamble, since
292         # listings.sty does that already. However it needs to be redefined
293         # in order to be used for non-english single-language documents.
294         LangPreamble
295                 \renewcommand{\lstlistlistingname}{_(Listings[[List of Listings]])}
296         EndLangPreamble
297         FixedWidthPreambleEncoding true
298   HTMLTag h2
299   HTMLStyle
300     div.lyxtoc-flat {
301       margin: 0em 0em 0em 1em;
302       font-size: large;
303       font-weight: normal;
304     }
305   EndHTMLStyle
306 End
307
308 InsetLayout TOC:MintedListings
309         # "List of Listings" is the name of the "List of listings"
310         # in minted.sty so it must be used here as well.
311         BabelPreamble
312                 \addto\captions$$lang{\renewcommand{\listoflistingscaption}{_(List of Listings)}}
313         EndBabelPreamble
314         # The command does not need to be defined in LangPreamble, since
315         # minted.sty does that already. However it needs to be redefined
316         # in order to be used for non-english single-language documents.
317         LangPreamble
318                 \renewcommand{\listoflistingscaption}{_(List of Listings)}
319         EndLangPreamble
320         FixedWidthPreambleEncoding false
321   HTMLTag h2
322   HTMLStyle
323     div.lyxtoc-flat {
324       margin: 0em 0em 0em 1em;
325       font-size: large;
326       font-weight: normal;
327     }
328   EndHTMLStyle
329 End
330
331 InsetLayout Include:Listings
332         BabelPreamble
333                 \addto\captions$$lang{\renewcommand{\lstlistingname}{_(Listing)}}
334         EndBabelPreamble
335         # The command does not need to be defined in LangPreamble, since
336         # listings.sty does that already. However it needs to be redefined
337         # in order to be used for non-english single-language documents.
338         LangPreamble
339                 \renewcommand{\lstlistingname}{_(Listing)}
340         EndLangPreamble
341         FixedWidthPreambleEncoding true
342 End
343
344 InsetLayout Listings
345         CopyStyle Include:Listings
346         LabelString           Listings[[inset]]
347         LatexType             none
348         Decoration            minimalistic
349         Font
350           Color               foreground
351           Family              typewriter
352         EndFont
353         LabelFont
354           Color               foreground
355           Size                Small
356         EndFont
357         BgColor               listingsbg
358         MultiPar              true
359         PassThru              true
360         ParbreakIsNewline     true
361         KeepEmpty             true
362         FreeSpacing           true
363         ForceLTR              true
364         RefPrefix             lst
365         HTMLTag               pre
366         HTMLStyle
367                 div.float-listings {
368                         border: 2px solid black;
369                         padding: 1ex;
370                         margin: 1ex;
371                 }
372                 div.listings-caption {
373                         text-align: center;
374                         border: 2px solid black;
375                         padding: 1ex;
376                         margin: 1ex;
377         }
378         EndHTMLStyle
379 End
380
381 InsetLayout MintedListings
382         CopyStyle Listings
383         BabelPreamble
384                 \addto\captions$$lang{\renewcommand{\listingscaption}{_(Listing)}}
385         EndBabelPreamble
386         # The command does not need to be defined in LangPreamble, since
387         # minted.sty does that already. However it needs to be redefined
388         # in order to be used for non-english single-language documents.
389         LangPreamble
390                 \renewcommand{\listingscaption}{_(Listing)}
391         EndLangPreamble
392         FixedWidthPreambleEncoding false
393 End
394
395 InsetLayout Branch
396         Decoration            classic
397         LabelFont
398           Color               branchlabel
399           Size                Small
400         EndFont
401         MultiPar              true
402         InToc                 true
403         HTMLIsBlock           false
404         AddToToc              branch
405         IsTocCaption          true
406 End
407
408 InsetLayout Index
409         LabelString           Idx
410         Decoration            classic
411         Font
412           Size                Small
413         EndFont
414         LabelFont
415           Color               indexlabel
416           Size                Small
417         EndFont
418         MultiPar              false
419         CustomPars            false
420         ForcePlain            true
421         ContentAsLabel        true
422         PassThruChars         @|!
423 End
424
425 InsetLayout Box
426         LabelFont
427           Color               foreground
428           Size                Small
429         EndFont
430         MultiPar              true
431 End
432
433 InsetLayout Box:Frameless
434         CopyStyle Box
435         HTMLStyle
436                 div.Frameless { margin: 1em; }
437         EndHTMLStyle
438 End
439
440 InsetLayout Box:Shaded
441         CopyStyle Box
442         BgColor shaded
443         HTMLStyle
444                 div.Shaded {
445                         background-color: gray;
446                         padding: 0.5ex;
447                 }
448         EndHTMLStyle
449 End
450
451 InsetLayout Box:Boxed
452         CopyStyle Box
453         HTMLStyle
454                 div.Boxed {
455                         border: solid thick black;
456                         padding: 0.5ex;
457                 }
458         EndHTMLStyle
459 End
460
461 InsetLayout Box:Framed
462         CopyStyle Box
463         HTMLStyle
464                 div.Framed {
465                         border: solid thick black;
466                         padding: 0.5ex;
467                 }
468         EndHTMLStyle
469 End
470
471 InsetLayout Box:ovalbox
472         CopyStyle Box
473         HTMLStyle
474                 div.ovalbox {
475                         border: groove medium black;
476                         padding: 0.5ex;
477                 }
478         EndHTMLStyle
479 End
480
481 InsetLayout Box:Ovalbox
482         CopyStyle Box
483         HTMLStyle
484                 div.Ovalbox {
485                         border: ridge thick black;
486                         padding: 0.5ex;
487                 }
488         EndHTMLStyle
489 End
490
491 InsetLayout Box:Shadowbox
492         CopyStyle Box
493         HTMLStyle
494                 div.Shadowbox { border: solid gray medium; border-bottom: solid black 1ex; border-right: solid black 1ex; padding: 0.5ex; }
495         EndHTMLStyle
496 End
497
498 InsetLayout Box:Doublebox
499         CopyStyle Box
500         HTMLStyle
501                 div.Doublebox {
502                         border: double thick black;
503                         padding: 0.5ex;
504                 }
505         EndHTMLStyle
506 End
507
508 InsetLayout Float
509         LabelFont
510           Color               collapsible
511           Size                Small
512         EndFont
513         MultiPar              true
514         HTMLStyle
515                 div.float {
516                         border: 2px solid black;
517                         text-align: center;
518                 }
519         EndHTMLStyle
520 End
521
522 #InsetWrap requires these, independently of whether stdfloats.inc is included
523 OutlinerName table        "Tables" #no AddToToc (built-in)
524 OutlinerName figure       "Figures" #no AddToToc (built-in)
525
526 InsetLayout Wrap
527         LabelFont
528           Color               collapsible
529           Size                Small
530         EndFont
531         MultiPar              true
532         RefPrefix             wrap
533         HTMLStyle
534                 div.wrap {
535                         float: right;
536                         border: 2px solid black;
537                         padding: 1ex;
538                         margin: 1ex;
539                 }
540         EndHTMLStyle
541 End
542
543 InsetLayout "Flex:URL"
544         LyXType               standard
545         Decoration            classic
546         LabelString           URL
547         ContentAsLabel        true
548         LatexName             url
549         LatexType             command
550         Requires              url
551         MultiPar              false
552         CustomPars            false
553         ForcePlain            true
554         PassThru              true
555         FreeSpacing           true
556         ForceLTR              true
557         NeedCProtect          true
558         Font
559           Family              Typewriter
560           Color               urltext
561         EndFont
562         LabelFont
563           Family              Typewriter
564           Color               urllabel
565           Size                Small
566         EndFont
567         HTMLIsBlock           false
568 End
569
570 InsetLayout Argument
571         LabelString           Argument
572         LabelFont
573           Color               collapsible
574           Size                Small
575         EndFont
576         MultiPar              false
577         ForceLocalFontSwitch  1
578 End
579
580 InsetLayout Info
581         Decoration            conglomerate
582         HTMLStyle
583                 span.info { font-family: sans-serif; }
584         EndHTMLStyle
585         HTMLTag               span
586         MultiPar              false
587 End
588
589 InsetLayout Info:menu
590         CopyStyle             Info
591         LatexType             command
592         LatexName             menuitem
593         Preamble
594           \providecommand{\menuitem}[1]{\textsf{#1}}
595         EndPreamble
596         Decoration            conglomerate
597         Font
598           Family              sans
599         EndFont
600         HTMLAttr              "class='info menu'"
601         HTMLStyle
602                 span.menu { font-family: sans-serif; }
603         EndHTMLStyle
604 End
605
606 InsetLayout Info:shortcut
607         CopyStyle             Info
608         LatexType             command
609         LatexName             shortcut
610         Preamble
611           \providecommand{\shortcut}[1]{\mbox{\textsf{#1}}}
612         EndPreamble
613         Decoration            conglomerate
614         Font
615           Family              sans
616         EndFont
617         HTMLAttr              "class='info shortcut'"
618         HTMLStyle
619                 span.shortcut { font-family: sans-serif; }
620         EndHTMLStyle
621 End
622
623 InsetLayout Info:shortcuts
624         CopyStyle             Info
625         LatexType             command
626         LatexName             shortcut
627         Preamble
628           \providecommand{\shortcut}[1]{\textsf{#1}}
629         EndPreamble
630         Decoration            conglomerate
631         Font
632           Family              sans
633         EndFont
634         HTMLAttr              "class='info shortcut'"
635         HTMLStyle
636                 span.shortcuts { font-family: sans-serif; }
637         EndHTMLStyle
638 End
639
640 InsetLayout Caption:Standard
641         LabelString          standard
642         LaTeXType            command
643         LatexName            caption
644         NeedProtect          1
645         MultiPar             false
646         Argument 1
647                 LabelString   "Short Title|S"
648                 Tooltip       "The caption as it appears in the list of figures/tables"
649                 InsertCotext  1
650         EndArgument
651         HTMLStyle
652                 div.float-caption {
653                         text-align: center;
654                         border: 2px solid black;
655                         padding: 1ex;
656                         margin: 1ex;
657                 }
658         EndHTMLStyle
659         HTMLAttr "class='float-caption float-caption-standard'"
660 End
661
662
663 InsetLayout Caption:Unnumbered
664         CopyStyle            Caption:Standard
665         LabelString          unlabelled
666         LatexName            caption*
667         ResetArgs            1
668 End
669
670
671 InsetLayout Preview
672         LabelString           Preview
673         Decoration            minimalistic
674         MultiPar              true
675 End
676
677
678 InsetLayout Script
679         LatexType       command
680         MultiPar        false
681         ForcePlain      1
682         CustomPars      0
683         InToc           1
684         HTMLIsBlock     0
685 End
686
687
688 InsetLayout Script:superscript
689         CopyStyle       Script
690         LaTeXName       textsuperscript
691         HTMLTag         sup
692 End
693
694
695 InsetLayout Script:subscript
696         CopyStyle       Script
697         Requires        subscript
698         LaTeXName       textsubscript
699         HTMLTag         sub
700 End
701
702
703 InsetLayout PrintNomencl
704         BabelPreamble
705                 \addto\captions$$lang{%
706                         \def\eqdeclaration#1{, _(see equation[[nomencl]])\nobreakspace(#1)}%
707                         \def\pagedeclaration#1{, _(page[[nomencl]])\nobreakspace#1}%
708                         \def\nomname{_(Nomenclature[[output]])}%
709                 }
710         EndBabelPreamble
711         # The command is defined for several languages in nomencl.sty. However, we need to define
712         # it anyway for the other, non suppported languages.
713         LangPreamble
714                 \def\eqdeclaration#1{, _(see equation[[nomencl]])\nobreakspace(#1)}
715                 \def\pagedeclaration#1{, _(page[[nomencl]])\nobreakspace#1}
716                 \def\nomname{_(Nomenclature[[output]])}
717         EndLangPreamble
718         HTMLTag h2
719 End
720
721 InsetLayout Tabular
722         HTMLStyle
723                 table {
724                         border-collapse: collapse;
725                         display: inline-block;
726                 }
727                 td {
728                         border: 1px solid black;
729                         padding: 0.5ex;
730                 }
731         EndHTMLStyle
732 End