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