]> git.lyx.org Git - lyx.git/blob - lib/doc/Customization.lyx
14199577f8474a2a82b23776ad3cdc9d5ca1f160
[lyx.git] / lib / doc / Customization.lyx
1 #LyX 2.1 created this file. For more info see http://www.lyx.org/
2 \lyxformat 476
3 \begin_document
4 \begin_header
5 \textclass scrbook
6 \begin_preamble
7 % DO NOT ALTER THIS PREAMBLE!!!
8 %
9 % This preamble is designed to ensure that this document prints
10 % out as advertised. If you mess with this preamble,
11 % parts of this document may not print out as expected.  If you
12 % have problems LaTeXing this file, please contact 
13 % the documentation team
14 % email: lyx-docs@lists.lyx.org
15
16 \usepackage{ifpdf} % part of the hyperref bundle
17 \ifpdf % if pdflatex is used
18
19  % set fonts for nicer pdf view
20  \IfFileExists{lmodern.sty}
21   {\usepackage{lmodern}}{}
22
23 \fi % end if pdflatex is used
24
25 % the pages of the TOC is numbered roman
26 % and a pdf-bookmark for the TOC is added
27 \let\myTOC\tableofcontents
28 \renewcommand\tableofcontents{%
29   \frontmatter
30   \pdfbookmark[1]{\contentsname}{}
31   \myTOC
32   \mainmatter }
33
34 % increase link area for cross-references and autoname them,
35 \AtBeginDocument{\renewcommand{\ref}[1]{\mbox{\autoref{#1}}}}
36 \@ifundefined{extrasenglish}{\usepackage[english]{babel}}{}
37 \addto\extrasenglish{%
38  \renewcommand*{\equationautorefname}[1]{}%
39  \renewcommand{\sectionautorefname}{sec.\negthinspace}%
40  \renewcommand{\subsectionautorefname}{sec.\negthinspace}%
41  \renewcommand{\subsubsectionautorefname}{sec.\negthinspace}%
42 }
43 \end_preamble
44 \options fleqn,bibliography=totoc,index=totoc,BCOR7.5mm,titlepage,captions=tableheading
45 \use_default_options false
46 \begin_modules
47 logicalmkup
48 \end_modules
49 \maintain_unincluded_children false
50 \begin_local_layout
51 Format 35
52 InsetLayout Flex:MenuItem
53 LyxType               charstyle
54 LabelString           menu
55 LatexType             command
56 LatexName             menuitem
57 Font
58 Family              Sans
59 EndFont
60 Preamble
61 \newcommand*{\menuitem}[1]{{\sffamily #1}}
62 EndPreamble
63 End
64 # In case we need to do with sans...
65 #InsetLayout CharStyle:Code
66 #Font
67 #Family              Sans
68 #EndFont
69 #Preamble
70 #\renewcommand{\code}[1]{{\sffamily #1}}
71 #EndPreamble
72 #End
73 \end_local_layout
74 \language english
75 \language_package default
76 \inputencoding auto
77 \fontencoding global
78 \font_roman default
79 \font_sans default
80 \font_typewriter default
81 \font_math auto
82 \font_default_family default
83 \use_non_tex_fonts false
84 \font_sc false
85 \font_osf false
86 \font_sf_scale 100
87 \font_tt_scale 100
88 \graphics default
89 \default_output_format default
90 \output_sync 0
91 \bibtex_command default
92 \index_command default
93 \paperfontsize 12
94 \spacing single
95 \use_hyperref true
96 \pdf_title "LyX Configuration Manual"
97 \pdf_author "LyX Team"
98 \pdf_subject "LyX-documentation Customization"
99 \pdf_keywords "LyX, documentation, customization"
100 \pdf_bookmarks true
101 \pdf_bookmarksnumbered true
102 \pdf_bookmarksopen true
103 \pdf_bookmarksopenlevel 1
104 \pdf_breaklinks false
105 \pdf_pdfborder false
106 \pdf_colorlinks true
107 \pdf_backref false
108 \pdf_pdfusetitle false
109 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue,pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
110 \papersize default
111 \use_geometry false
112 \use_package amsmath 0
113 \use_package amssymb 0
114 \use_package cancel 0
115 \use_package esint 0
116 \use_package mathdots 1
117 \use_package mathtools 0
118 \use_package mhchem 0
119 \use_package stackrel 0
120 \use_package stmaryrd 0
121 \use_package undertilde 0
122 \cite_engine basic
123 \cite_engine_type default
124 \biblio_style plain
125 \use_bibtopic false
126 \use_indices false
127 \paperorientation portrait
128 \suppress_date false
129 \justification true
130 \use_refstyle 0
131 \branch OutDated
132 \selected 0
133 \filename_suffix 0
134 \color #f5fae7
135 \end_branch
136 \index Index
137 \shortcut idx
138 \color #008000
139 \end_index
140 \secnumdepth 3
141 \tocdepth 3
142 \paragraph_separation indent
143 \paragraph_indentation default
144 \quotes_language english
145 \papercolumns 1
146 \papersides 2
147 \paperpagestyle headings
148 \tracking_changes true
149 \output_changes false
150 \html_math_output 0
151 \html_css_as_file 0
152 \html_be_strict true
153 \author -712698321 "Jürgen Spitzmüller" 
154 \end_header
155
156 \begin_body
157
158 \begin_layout Title
159 Customizing LyX: Features for the Advanced User
160 \end_layout
161
162 \begin_layout Author
163 by the LyX Team
164 \begin_inset Foot
165 status collapsed
166
167 \begin_layout Plain Layout
168 \noindent
169 If you have comments or error corrections, please send them to the LyX Documenta
170 tion mailing list, 
171 \begin_inset CommandInset href
172 LatexCommand href
173 target "lyx-docs@lists.lyx.org"
174 type "mailto:"
175
176 \end_inset
177
178 .
179  Include 
180 \begin_inset Quotes eld
181 \end_inset
182
183 [Customization]
184 \begin_inset Quotes erd
185 \end_inset
186
187  in the subject header, and please cc the current maintainer of this file,
188  Richard Heck <rgheck@comcast.net>.
189 \end_layout
190
191 \end_inset
192
193
194 \begin_inset Newline newline
195 \end_inset
196
197
198 \begin_inset Newline newline
199 \end_inset
200
201 Version 2.1.x 
202 \end_layout
203
204 \begin_layout Standard
205 \begin_inset CommandInset toc
206 LatexCommand tableofcontents
207
208 \end_inset
209
210
211 \end_layout
212
213 \begin_layout Standard
214 \begin_inset Note Note
215 status open
216
217 \begin_layout Plain Layout
218 Please use change tracking when modifying this document.
219  This makes it easier for our translators to recognize things that have
220  been changed, and it helps the maintainer keep up-to-date with what's been
221  done.
222 \end_layout
223
224 \end_inset
225
226
227 \end_layout
228
229 \begin_layout Chapter
230 Introduction
231 \end_layout
232
233 \begin_layout Standard
234 This manual covers the customization features present in LyX.
235  In it, we discuss issues like keyboard shortcuts, screen previewing options,
236  printer options, sending commands to LyX via the LyX Server, internationalizati
237 on, installing new LaTeX classes and LyX layouts, etc.
238  We can't possibly hope to touch on everything you can change—our developers
239  add new features faster than we can document them—but we will explain the
240  most common customizations and hopefully point you in the right direction
241  for some of the more obscure ones.
242 \end_layout
243
244 \begin_layout Standard
245 \begin_inset Branch OutDated
246 status collapsed
247
248 \begin_layout Standard
249 Information from previous versions of this document that now seems to be
250  outdated is contained in the OutDated branch of this document.
251  By default, this information will not appear in the LaTeX output.
252 \end_layout
253
254 \end_inset
255
256
257 \end_layout
258
259 \begin_layout Chapter
260 LyX configuration files
261 \end_layout
262
263 \begin_layout Standard
264 This chapter aims to help you to find your way through the LyX configuration
265  files.
266  Before continuing to read this chapter, you should find out where your
267  LyX library and user directories are by using 
268 \begin_inset Flex MenuItem
269 status collapsed
270
271 \begin_layout Plain Layout
272 Help\SpecialChar \menuseparator
273 About
274 \begin_inset space ~
275 \end_inset
276
277 LyX
278 \end_layout
279
280 \end_inset
281
282 .
283  The library directory is the place where LyX places its system-wide configurati
284 on files; the user directory is where you can place your modified versions.
285  We will call the former 
286 \begin_inset Flex Code
287 status collapsed
288
289 \begin_layout Plain Layout
290 LyXDir
291 \end_layout
292
293 \end_inset
294
295  and the latter 
296 \begin_inset Flex MenuItem
297 status collapsed
298
299 \begin_layout Plain Layout
300 UserDir
301 \end_layout
302
303 \end_inset
304
305  in the remainder of this document.
306  
307 \end_layout
308
309 \begin_layout Section
310 What's in 
311 \begin_inset Flex Code
312 status collapsed
313
314 \begin_layout Plain Layout
315 LyXDir
316 \end_layout
317
318 \end_inset
319
320 ?
321 \end_layout
322
323 \begin_layout Standard
324 \begin_inset Flex Code
325 status collapsed
326
327 \begin_layout Plain Layout
328 LyXDir
329 \end_layout
330
331 \end_inset
332
333  and its sub-directories contain a number of files and that can be used
334  to customize LyX's behavior.
335  You can change many of these files from within LyX itself through the 
336 \begin_inset Flex MenuItem
337 status collapsed
338
339 \begin_layout Plain Layout
340 Tools\SpecialChar \menuseparator
341 Preferences
342 \end_layout
343
344 \end_inset
345
346  dialog.
347  Most customization that you will want to do in LyX is possible through
348  this dialog.
349  However, many other inner aspects of LyX can be customized by modifying
350  the files in 
351 \begin_inset Flex Code
352 status collapsed
353
354 \begin_layout Plain Layout
355 LyXDir
356 \end_layout
357
358 \end_inset
359
360 .
361  These files fall in different categories, described in the following subsection
362 s.
363 \end_layout
364
365 \begin_layout Subsection
366 Automatically generated files
367 \end_layout
368
369 \begin_layout Standard
370 The files, which are to be found in 
371 \begin_inset Flex MenuItem
372 status collapsed
373
374 \begin_layout Plain Layout
375 UserDir
376 \end_layout
377
378 \end_inset
379
380 , are generated when you configure LyX.
381  They contain various default values that are guessed by inspection.
382  In general, it is not a good idea to modify them, since they might be overwritt
383 en at any time.
384 \end_layout
385
386 \begin_layout Labeling
387 \labelwidthstring 00.00.0000
388 \begin_inset Flex Code
389 status collapsed
390
391 \begin_layout Plain Layout
392 lyxrc.defaults
393 \end_layout
394
395 \end_inset
396
397  contains defaults for various commands.
398 \end_layout
399
400 \begin_layout Labeling
401 \labelwidthstring 00.00.0000
402 \begin_inset Flex Code
403 status collapsed
404
405 \begin_layout Plain Layout
406 packages.lst
407 \end_layout
408
409 \end_inset
410
411  contains the list of packages that have been recognized by LyX.
412  It is currently unused by the LyX program itself, but the information extracted
413 , and more, is made available with 
414 \begin_inset Flex MenuItem
415 status collapsed
416
417 \begin_layout Plain Layout
418 Help\SpecialChar \menuseparator
419 LaTeX
420 \begin_inset space ~
421 \end_inset
422
423 Configuration
424 \end_layout
425
426 \end_inset
427
428 .
429 \end_layout
430
431 \begin_layout Labeling
432 \labelwidthstring 00.00.0000
433 \begin_inset Flex Code
434 status collapsed
435
436 \begin_layout Plain Layout
437 textclass.lst
438 \end_layout
439
440 \end_inset
441
442  the list of text classes that have been found in your 
443 \begin_inset Flex Code
444 status collapsed
445
446 \begin_layout Plain Layout
447 layout/
448 \end_layout
449
450 \end_inset
451
452  directories, along with the associated LaTeX document class and their descripti
453 on.
454 \end_layout
455
456 \begin_layout Labeling
457 \labelwidthstring 00.00.0000
458 \begin_inset Flex Code
459 status collapsed
460
461 \begin_layout Plain Layout
462 lyxmodules.lst
463 \end_layout
464
465 \end_inset
466
467  the list of layout modules found in your 
468 \begin_inset Flex Code
469 status collapsed
470
471 \begin_layout Plain Layout
472 layout/
473 \end_layout
474
475 \end_inset
476
477  directories
478 \end_layout
479
480 \begin_layout Labeling
481 \labelwidthstring 00.00.0000
482 \begin_inset Flex Code
483 status collapsed
484
485 \begin_layout Plain Layout
486 *files.lst
487 \end_layout
488
489 \end_inset
490
491  lists of various sorts of LaTeX-related files found on your system
492 \end_layout
493
494 \begin_layout Labeling
495 \labelwidthstring 00.00.0000
496 \begin_inset Flex Code
497 status collapsed
498
499 \begin_layout Plain Layout
500 doc/LaTeXConfig.lyx
501 \end_layout
502
503 \end_inset
504
505  is automatically generated during configuration from the file 
506 \begin_inset Flex Code
507 status collapsed
508
509 \begin_layout Plain Layout
510 LaTeXConfig.lyx.in
511 \end_layout
512
513 \end_inset
514
515 .
516  It contains information on your LaTeX configuration.
517 \end_layout
518
519 \begin_layout Subsection
520 Directories
521 \end_layout
522
523 \begin_layout Standard
524 These directories are duplicated between 
525 \begin_inset Flex Code
526 status collapsed
527
528 \begin_layout Plain Layout
529 LyXDir
530 \end_layout
531
532 \end_inset
533
534  and 
535 \begin_inset Flex Code
536 status collapsed
537
538 \begin_layout Plain Layout
539 UserDir
540 \end_layout
541
542 \end_inset
543
544 .
545  If a particular files exists in both places, the one in 
546 \begin_inset Flex Code
547 status collapsed
548
549 \begin_layout Plain Layout
550 UserDir
551 \end_layout
552
553 \end_inset
554
555  will be used.
556 \end_layout
557
558 \begin_layout Labeling
559 \labelwidthstring 00.00.0000
560 \begin_inset Flex Code
561 status collapsed
562
563 \begin_layout Plain Layout
564 bind/
565 \end_layout
566
567 \end_inset
568
569  this directory contains files with the extension 
570 \begin_inset Flex Code
571 status collapsed
572
573 \begin_layout Plain Layout
574 .bind
575 \end_layout
576
577 \end_inset
578
579  that define the keybindings used in LyX.
580  If there exists an internationalized version of the bind file named 
581 \begin_inset Flex Code
582 status collapsed
583
584 \begin_layout Plain Layout
585 $LANG_xxx.bind
586 \end_layout
587
588 \end_inset
589
590 , that will be used first.
591 \end_layout
592
593 \begin_layout Labeling
594 \labelwidthstring 00.00.0000
595 \begin_inset Flex Code
596 status collapsed
597
598 \begin_layout Plain Layout
599 clipart/
600 \end_layout
601
602 \end_inset
603
604  contains graphics files that can be included in documents.
605  
606 \end_layout
607
608 \begin_layout Labeling
609 \labelwidthstring 00.00.0000
610 \begin_inset Flex Code
611 status collapsed
612
613 \begin_layout Plain Layout
614 doc/
615 \end_layout
616
617 \end_inset
618
619  contains LyX documentation files (including the one you are currently reading).
620  The file 
621 \begin_inset Flex Code
622 status collapsed
623
624 \begin_layout Plain Layout
625 LaTeXConfig.lyx
626 \end_layout
627
628 \end_inset
629
630  deserves special attention, as noted above.
631  The internationalized help docs are in subdirectories 
632 \begin_inset Flex Code
633 status collapsed
634
635 \begin_layout Plain Layout
636 doc/xx
637 \end_layout
638
639 \end_inset
640
641  where 
642 \begin_inset Quotes eld
643 \end_inset
644
645 xx
646 \begin_inset Quotes erd
647 \end_inset
648
649  is the ISO language code.
650  See 
651 \begin_inset CommandInset ref
652 LatexCommand ref
653 reference "cha:Internationalizing-LyX"
654
655 \end_inset
656
657  for details.
658 \end_layout
659
660 \begin_layout Labeling
661 \labelwidthstring 00.00.0000
662 \begin_inset Flex Code
663 status collapsed
664
665 \begin_layout Plain Layout
666 examples/
667 \end_layout
668
669 \end_inset
670
671  contains example files that explain how to use some features.
672  In the file browser, press the 
673 \begin_inset Flex MenuItem
674 status collapsed
675
676 \begin_layout Plain Layout
677 Examples
678 \end_layout
679
680 \end_inset
681
682  button to get there.
683 \end_layout
684
685 \begin_layout Labeling
686 \labelwidthstring 00.00.0000
687 \begin_inset Flex Code
688 status collapsed
689
690 \begin_layout Plain Layout
691 images/
692 \end_layout
693
694 \end_inset
695
696  contains image files that are used by the 
697 \begin_inset Flex MenuItem
698 status collapsed
699
700 \begin_layout Plain Layout
701 Document
702 \end_layout
703
704 \end_inset
705
706  dialog.
707  In addition, it also contains the individual icons used in the toolbar
708  and the banners that can be shown when LyX is launched.
709 \end_layout
710
711 \begin_layout Labeling
712 \labelwidthstring 00.00.0000
713 \begin_inset Flex Code
714 status collapsed
715
716 \begin_layout Plain Layout
717 kbd/
718 \end_layout
719
720 \end_inset
721
722  contains keyboard keymapping files.
723  See 
724 \begin_inset CommandInset ref
725 LatexCommand ref
726 reference "sec:International-Keymap-Stuff"
727
728 \end_inset
729
730  for details.
731 \end_layout
732
733 \begin_layout Labeling
734 \labelwidthstring 00.00.0000
735 \begin_inset Flex Code
736 status collapsed
737
738 \begin_layout Plain Layout
739 layouts/
740 \end_layout
741
742 \end_inset
743
744  contains the text class and module files described in 
745 \begin_inset CommandInset ref
746 LatexCommand ref
747 reference "cha:Installing-New-Document"
748
749 \end_inset
750
751 .
752 \end_layout
753
754 \begin_layout Labeling
755 \labelwidthstring 00.00.0000
756 \begin_inset Flex Code
757 status collapsed
758
759 \begin_layout Plain Layout
760 lyx2lyx
761 \end_layout
762
763 \end_inset
764
765  contains the 
766 \begin_inset Flex Code
767 status collapsed
768
769 \begin_layout Plain Layout
770 lyx2lyx
771 \end_layout
772
773 \end_inset
774
775  Python scripts used to convert between LyX versions.
776  These can be run from the command line if, say, you want to batch-convert
777  files.
778 \end_layout
779
780 \begin_layout Labeling
781 \labelwidthstring 00.00.0000
782 \begin_inset Flex Code
783 status collapsed
784
785 \begin_layout Plain Layout
786 scripts/
787 \end_layout
788
789 \end_inset
790
791  contains some files that demonstrate the capabilities of the 
792 \begin_inset Flex MenuItem
793 status collapsed
794
795 \begin_layout Plain Layout
796 External
797 \begin_inset space ~
798 \end_inset
799
800 Template
801 \end_layout
802
803 \end_inset
804
805  feature.
806  Also contains some scripts used by LyX itself.
807 \end_layout
808
809 \begin_layout Labeling
810 \labelwidthstring 00.00.0000
811 \begin_inset Flex Code
812 status collapsed
813
814 \begin_layout Plain Layout
815 templates/
816 \end_layout
817
818 \end_inset
819
820  contains the standard LyX template files described in 
821 \begin_inset CommandInset ref
822 LatexCommand ref
823 reference "sub:Creating-Templates"
824
825 \end_inset
826
827 .
828 \end_layout
829
830 \begin_layout Labeling
831 \labelwidthstring 00.00.0000
832 \begin_inset Flex Code
833 status collapsed
834
835 \begin_layout Plain Layout
836 ui/
837 \end_layout
838
839 \end_inset
840
841  contains files with the extension 
842 \begin_inset Flex Code
843 status collapsed
844
845 \begin_layout Plain Layout
846 .ui
847 \end_layout
848
849 \end_inset
850
851  that define the user interface to LyX.
852  That is, the files define which items appear in which menus and the items
853  appearing on the toolbar.
854 \end_layout
855
856 \begin_layout Subsection
857 Files you don't want to modify
858 \end_layout
859
860 \begin_layout Standard
861 These files are used internally by LyX and you generally do not need to
862  modify them unless you are a developer.
863 \end_layout
864
865 \begin_layout Labeling
866 \labelwidthstring 00.00.0000
867 \begin_inset Flex Code
868 status collapsed
869
870 \begin_layout Plain Layout
871 CREDITS
872 \end_layout
873
874 \end_inset
875
876  this file contains the list of LyX developers.
877  The contents are displayed with the menu entry 
878 \begin_inset Flex MenuItem
879 status collapsed
880
881 \begin_layout Plain Layout
882 Help\SpecialChar \menuseparator
883 About
884 \begin_inset space ~
885 \end_inset
886
887 LyX
888 \end_layout
889
890 \end_inset
891
892 .
893 \end_layout
894
895 \begin_layout Labeling
896 \labelwidthstring 00.00.0000
897 \begin_inset Flex Code
898 status collapsed
899
900 \begin_layout Plain Layout
901 chkconfig.ltx
902 \end_layout
903
904 \end_inset
905
906  this is a LaTeX script used during the configuration process.
907  Do not run directly.
908 \end_layout
909
910 \begin_layout Labeling
911 \labelwidthstring 00.00.0000
912 \begin_inset Flex Code
913 status collapsed
914
915 \begin_layout Plain Layout
916 configure.py
917 \end_layout
918
919 \end_inset
920
921  this is a Python script that is used to re-configure LyX.
922  It creates configuration files in the directory it was run from.
923 \end_layout
924
925 \begin_layout Subsection
926 Other files needing a line or two
927 \end_layout
928
929 \begin_layout Labeling
930 \labelwidthstring 00.00.0000
931 \begin_inset Flex Code
932 status collapsed
933
934 \begin_layout Plain Layout
935 encodings
936 \end_layout
937
938 \end_inset
939
940  this contains tables describing how different character encodings can be
941  mapped to Unicode
942 \end_layout
943
944 \begin_layout Labeling
945 \labelwidthstring 00.00.0000
946 \begin_inset Flex Code
947 status collapsed
948
949 \begin_layout Plain Layout
950 external_templates
951 \end_layout
952
953 \end_inset
954
955  this file contains the templates available to the new 
956 \begin_inset Flex MenuItem
957 status collapsed
958
959 \begin_layout Plain Layout
960 External
961 \begin_inset space ~
962 \end_inset
963
964 Template
965 \end_layout
966
967 \end_inset
968
969  feature, see 
970 \begin_inset CommandInset ref
971 LatexCommand ref
972 reference "chap:Including-External-Material"
973
974 \end_inset
975
976 .
977 \end_layout
978
979 \begin_layout Labeling
980 \labelwidthstring 00.00.0000
981 \begin_inset Flex Code
982 status collapsed
983
984 \begin_layout Plain Layout
985 languages
986 \end_layout
987
988 \end_inset
989
990  this file contains a list of all the languages currently supported by LyX.
991 \end_layout
992
993 \begin_layout Labeling
994 \labelwidthstring 00.00.0000
995 \begin_inset Flex Code
996 status collapsed
997
998 \begin_layout Plain Layout
999 latexfonts
1000 \end_layout
1001
1002 \end_inset
1003
1004  contains information about the supported fonts.
1005 \end_layout
1006
1007 \begin_layout Labeling
1008 \labelwidthstring 00.00.0000
1009 \begin_inset Flex Code
1010 status collapsed
1011
1012 \begin_layout Plain Layout
1013 layouttranslations
1014 \end_layout
1015
1016 \end_inset
1017
1018  this file contains translations for internationalized paragraph styles
1019  (see 
1020 \begin_inset CommandInset ref
1021 LatexCommand ref
1022 reference "sub:I18n"
1023
1024 \end_inset
1025
1026 ).
1027 \end_layout
1028
1029 \begin_layout Labeling
1030 \labelwidthstring 00.00.0000
1031 \begin_inset Flex Code
1032 status collapsed
1033
1034 \begin_layout Plain Layout
1035 unicodesymbols
1036 \end_layout
1037
1038 \end_inset
1039
1040  this file contains information about unicode-encoded glyphs and the way
1041  they are supported by LyX via LaTeX.
1042 \end_layout
1043
1044 \begin_layout Section
1045 Your local configuration directory
1046 \end_layout
1047
1048 \begin_layout Standard
1049 Even if you are using LyX as an unprivileged user, you might want to change
1050  LyX configuration for your own use.
1051  The 
1052 \begin_inset Flex Code
1053 status collapsed
1054
1055 \begin_layout Plain Layout
1056 UserDir
1057 \end_layout
1058
1059 \end_inset
1060
1061  directory contains all your personal configuration files.
1062  This is the directory described as 
1063 \begin_inset Quotes eld
1064 \end_inset
1065
1066 user directory
1067 \begin_inset Quotes erd
1068 \end_inset
1069
1070  in 
1071 \begin_inset Flex MenuItem
1072 status collapsed
1073
1074 \begin_layout Plain Layout
1075 Help\SpecialChar \menuseparator
1076 About
1077 \begin_inset space ~
1078 \end_inset
1079
1080 LyX
1081 \end_layout
1082
1083 \end_inset
1084
1085 .
1086  This directory is used as a mirror of 
1087 \begin_inset Flex Code
1088 status collapsed
1089
1090 \begin_layout Plain Layout
1091 LyXDir
1092 \end_layout
1093
1094 \end_inset
1095
1096 , which means that every file in 
1097 \begin_inset Flex Code
1098 status collapsed
1099
1100 \begin_layout Plain Layout
1101 UserDir
1102 \end_layout
1103
1104 \end_inset
1105
1106  is a replacement for the corresponding file in 
1107 \begin_inset Flex Code
1108 status collapsed
1109
1110 \begin_layout Plain Layout
1111 LyXDir
1112 \end_layout
1113
1114 \end_inset
1115
1116 .
1117  Any configuration file described in the above sections can be placed either
1118  in the system-wide directory, in which case it will affect all users, or
1119  in your local directory for your own use.
1120 \end_layout
1121
1122 \begin_layout Standard
1123 To make things clearer, let's provide a few examples:
1124 \end_layout
1125
1126 \begin_layout Itemize
1127 The preferences set in the 
1128 \begin_inset Flex MenuItem
1129 status collapsed
1130
1131 \begin_layout Plain Layout
1132 Tools\SpecialChar \menuseparator
1133 Preferences
1134 \end_layout
1135
1136 \end_inset
1137
1138  dialog are saved to a file 
1139 \begin_inset Flex Code
1140 status collapsed
1141
1142 \begin_layout Plain Layout
1143 preferences
1144 \end_layout
1145
1146 \end_inset
1147
1148  in 
1149 \begin_inset Flex Code
1150 status collapsed
1151
1152 \begin_layout Plain Layout
1153 UserDir
1154 \end_layout
1155
1156 \end_inset
1157
1158 .
1159 \end_layout
1160
1161 \begin_layout Itemize
1162 When you reconfigure using 
1163 \begin_inset Flex MenuItem
1164 status collapsed
1165
1166 \begin_layout Plain Layout
1167 Tools\SpecialChar \menuseparator
1168 Reconfigure
1169 \end_layout
1170
1171 \end_inset
1172
1173 , LyX runs the 
1174 \begin_inset Flex Code
1175 status collapsed
1176
1177 \begin_layout Plain Layout
1178 configure.py
1179 \end_layout
1180
1181 \end_inset
1182
1183  script, and the resulting files are written in your local configuration
1184  directory.
1185  This means that any additional text class file that you might have added
1186  in 
1187 \begin_inset Flex Code
1188 status collapsed
1189
1190 \begin_layout Plain Layout
1191 UserDir/layouts
1192 \end_layout
1193
1194 \end_inset
1195
1196  will be added to the list of classes in the 
1197 \begin_inset Flex MenuItem
1198 status collapsed
1199
1200 \begin_layout Plain Layout
1201 Document\SpecialChar \menuseparator
1202 Settings
1203 \end_layout
1204
1205 \end_inset
1206
1207  dialog.
1208 \end_layout
1209
1210 \begin_layout Itemize
1211 If you get some updated documentation from LyX ftp site and cannot install
1212  it because you do not have sysadmin rights on your system, you can just
1213  copy the files in 
1214 \begin_inset Flex Code
1215 status collapsed
1216
1217 \begin_layout Plain Layout
1218 UserDir/doc/
1219 \end_layout
1220
1221 \end_inset
1222
1223  and the items in the 
1224 \begin_inset Flex MenuItem
1225 status collapsed
1226
1227 \begin_layout Plain Layout
1228 Help
1229 \end_layout
1230
1231 \end_inset
1232
1233  menu will open them!
1234 \end_layout
1235
1236 \begin_layout Section
1237 Running LyX with multiple configurations
1238 \end_layout
1239
1240 \begin_layout Standard
1241 The configuration freedom of the local configuration directory may not suffice
1242  if you want to have more than one configuration at your disposal.
1243  For example, you may want to be use different key bindings or printer settings
1244  at different times.
1245  You can achieve this by having several such directories.
1246  You then specify which directory to use at run-time.
1247 \end_layout
1248
1249 \begin_layout Standard
1250 Invoking LyX with the command line switch 
1251 \begin_inset Flex Code
1252 status collapsed
1253
1254 \begin_layout Plain Layout
1255 -userdir
1256 \end_layout
1257
1258 \end_inset
1259
1260  
1261 \emph on
1262 <some directory>
1263 \emph default
1264  instructs the program to read the configuration from that directory, and
1265  not from the default directory.
1266  (You can determine the default directory by running LyX without the 
1267 \begin_inset Flex Code
1268 status collapsed
1269
1270 \begin_layout Plain Layout
1271 -userdir
1272 \end_layout
1273
1274 \end_inset
1275
1276  switch.) If the specified directory does not exist, LyX offers to create
1277  it for you, just like it does for the default directory on the first time
1278  you run the program.
1279  You can modify the configuration options in this additional user directory
1280  exactly as you would for the default directory.
1281  These directories are completely independent (but read on).
1282  Note that setting the environment variable 
1283 \begin_inset Flex Code
1284 status collapsed
1285
1286 \begin_layout Plain Layout
1287 LYX_USERDIR_VER
1288 \end_layout
1289
1290 \end_inset
1291
1292  to some value has exactly the same effect.
1293 \end_layout
1294
1295 \begin_layout Standard
1296 Having several configurations also requires more maintenance: if you want
1297  to add a new layout to 
1298 \begin_inset Flex Code
1299 status collapsed
1300
1301 \begin_layout Plain Layout
1302 NewUserDir/layouts
1303 \end_layout
1304
1305 \end_inset
1306
1307  which you want available from all your configurations, you must add it
1308  to each directory separately.
1309  You can avoid this with the following trick: after LyX creates the additional
1310  directory, most of the subdirectories (see above) are empty.
1311  If you want the new configuration to mirror an existing one, replace the
1312  empty subdirectory with a symbolic link to the matching subdirectory in
1313  the existing configuration.
1314  Take care with the 
1315 \begin_inset Flex Code
1316 status collapsed
1317
1318 \begin_layout Plain Layout
1319 doc/
1320 \end_layout
1321
1322 \end_inset
1323
1324  subdirectory, however, since it contains a file written by the configuration
1325  script (also accessible through 
1326 \begin_inset Flex MenuItem
1327 status collapsed
1328
1329 \begin_layout Plain Layout
1330 Tools\SpecialChar \menuseparator
1331 Reconfigure
1332 \end_layout
1333
1334 \end_inset
1335
1336 ) which is configuration-specific.
1337 \end_layout
1338
1339 \begin_layout Chapter
1340 The Preferences dialog
1341 \end_layout
1342
1343 \begin_layout Standard
1344 All options of the preferences dialog are described in the Appendix 
1345 \emph on
1346 The Preferences Dialog
1347 \emph default
1348  in the 
1349 \emph on
1350 User's Guide
1351 \emph default
1352 .
1353  For some options you might find here more details.
1354 \end_layout
1355
1356 \begin_layout Section
1357 Formats
1358 \begin_inset CommandInset label
1359 LatexCommand label
1360 name "sec:Formats"
1361
1362 \end_inset
1363
1364
1365 \end_layout
1366
1367 \begin_layout Standard
1368 The first step is to define your file formats if they are not already defined.
1369  To do so, open the 
1370 \begin_inset Flex MenuItem
1371 status collapsed
1372
1373 \begin_layout Plain Layout
1374 Tools\SpecialChar \menuseparator
1375 Preferences
1376 \end_layout
1377
1378 \end_inset
1379
1380  dialog.
1381  Under 
1382 \begin_inset Flex MenuItem
1383 status collapsed
1384
1385 \begin_layout Plain Layout
1386 File Handling\SpecialChar \menuseparator
1387 File formats
1388 \end_layout
1389
1390 \end_inset
1391
1392  press the 
1393 \begin_inset Flex MenuItem
1394 status collapsed
1395
1396 \begin_layout Plain Layout
1397 New
1398 \end_layout
1399
1400 \end_inset
1401
1402  button to define your new format.
1403  The 
1404 \begin_inset Flex MenuItem
1405 status collapsed
1406
1407 \begin_layout Plain Layout
1408 Format
1409 \end_layout
1410
1411 \end_inset
1412
1413  field contains the name used to identify the format in the GUI.
1414  The 
1415 \begin_inset Flex MenuItem
1416 status collapsed
1417
1418 \begin_layout Plain Layout
1419 Short Name
1420 \end_layout
1421
1422 \end_inset
1423
1424  is used to identify the format internally.
1425  You will also need to enter a file extension.
1426  These are all required.
1427  The optional 
1428 \begin_inset Flex MenuItem
1429 status collapsed
1430
1431 \begin_layout Plain Layout
1432 Shortcut
1433 \end_layout
1434
1435 \end_inset
1436
1437  field is used to provide a keyboard shortcut on the menus.
1438  (For example, pressing 
1439 \begin_inset Flex MenuItem
1440 status collapsed
1441
1442 \begin_layout Plain Layout
1443 Ctrl+D
1444 \end_layout
1445
1446 \end_inset
1447
1448  will 
1449 \begin_inset Flex MenuItem
1450 status collapsed
1451
1452 \begin_layout Plain Layout
1453 Document\SpecialChar \menuseparator
1454 View (Other Formats)\SpecialChar \menuseparator
1455 DVI
1456 \end_layout
1457
1458 \end_inset
1459
1460 .) 
1461 \end_layout
1462
1463 \begin_layout Standard
1464 A Format can have a 
1465 \begin_inset Flex MenuItem
1466 status collapsed
1467
1468 \begin_layout Plain Layout
1469 Viewer
1470 \end_layout
1471
1472 \end_inset
1473
1474  and an 
1475 \begin_inset Flex MenuItem
1476 status collapsed
1477
1478 \begin_layout Plain Layout
1479 Editor
1480 \end_layout
1481
1482 \end_inset
1483
1484  associated with it.
1485  For example, you might want to use 
1486 \begin_inset Flex MenuItem
1487 status collapsed
1488
1489 \begin_layout Plain Layout
1490 Ghostview
1491 \end_layout
1492
1493 \end_inset
1494
1495  to view PostScript files.
1496  You can enter the command needed to start the program in the corresponding
1497  fields.
1498  In defining this command, you can use the four variables listed in the
1499  next section.
1500  The viewer is launched when you view an image in LyX or use the 
1501 \begin_inset Flex MenuItem
1502 status collapsed
1503
1504 \begin_layout Plain Layout
1505 Document\SpecialChar \menuseparator
1506 View
1507 \end_layout
1508
1509 \end_inset
1510
1511  menu.
1512  The editor is for example launched when you right-click on an image and
1513  choose 
1514 \begin_inset Flex MenuItem
1515 status collapsed
1516
1517 \begin_layout Plain Layout
1518 Edit externally
1519 \end_layout
1520
1521 \end_inset
1522
1523  in the appearing context menu.
1524 \end_layout
1525
1526 \begin_layout Standard
1527 The 
1528 \begin_inset Flex MenuItem
1529 status collapsed
1530
1531 \begin_layout Plain Layout
1532 MIME
1533 \end_layout
1534
1535 \end_inset
1536
1537  type of a format is optional, but if it is specified, it must be unique
1538  across all formats.
1539  It is used to detect files of this format from the file contents.
1540  For some important file formats there is no MIME type officially registered
1541  with the 
1542 \begin_inset CommandInset href
1543 LatexCommand href
1544 name "IANA"
1545 target "http://www.iana.org/assignments/media-types/"
1546
1547 \end_inset
1548
1549 .
1550  Therefore LyX uses the extended list of MIME types as specified by 
1551 \begin_inset CommandInset href
1552 LatexCommand href
1553 name "freedesktop.org"
1554 target "http://www.freedesktop.org/wiki/Specifications/shared-mime-info-spec"
1555
1556 \end_inset
1557
1558 .
1559 \end_layout
1560
1561 \begin_layout Standard
1562 The 
1563 \begin_inset Flex MenuItem
1564 status collapsed
1565
1566 \begin_layout Plain Layout
1567 Document format
1568 \end_layout
1569
1570 \end_inset
1571
1572  option tells LyX that a format is suitable for document export.
1573  If this is set and if a suitable conversion route exists (see 
1574 \begin_inset CommandInset ref
1575 LatexCommand ref
1576 reference "sec:Converters"
1577
1578 \end_inset
1579
1580 ), the format will appear in the 
1581 \begin_inset Flex MenuItem
1582 status collapsed
1583
1584 \begin_layout Plain Layout
1585 File\SpecialChar \menuseparator
1586 Export
1587 \end_layout
1588
1589 \end_inset
1590
1591  menu.
1592  The format will also appear in the 
1593 \begin_inset Flex MenuItem
1594 status collapsed
1595
1596 \begin_layout Plain Layout
1597 Document\SpecialChar \menuseparator
1598 View
1599 \end_layout
1600
1601 \end_inset
1602
1603  menu if a viewer is specified for the format.
1604  Pure image formats, such as 
1605 \begin_inset Flex Code
1606 status collapsed
1607
1608 \begin_layout Plain Layout
1609 png
1610 \end_layout
1611
1612 \end_inset
1613
1614 , should not use this option.
1615  Formats that can both represent vector graphics and documents like 
1616 \begin_inset Flex Code
1617 status collapsed
1618
1619 \begin_layout Plain Layout
1620 pdf
1621 \end_layout
1622
1623 \end_inset
1624
1625  should use it.
1626 \end_layout
1627
1628 \begin_layout Standard
1629 The option 
1630 \begin_inset Flex MenuItem
1631 status collapsed
1632
1633 \begin_layout Plain Layout
1634 Vector graphics format
1635 \end_layout
1636
1637 \end_inset
1638
1639  tells LyX that a format can contain vector graphics.
1640  This information is used to determine the target format of included graphics
1641  for 
1642 \begin_inset Flex MenuItem
1643 status collapsed
1644
1645 \begin_layout Plain Layout
1646 pdflatex
1647 \end_layout
1648
1649 \end_inset
1650
1651  export.
1652  Included graphics may need to be converted to either 
1653 \begin_inset Flex MenuItem
1654 status collapsed
1655
1656 \begin_layout Plain Layout
1657 pdf
1658 \end_layout
1659
1660 \end_inset
1661
1662
1663 \begin_inset Flex MenuItem
1664 status collapsed
1665
1666 \begin_layout Plain Layout
1667 png
1668 \end_layout
1669
1670 \end_inset
1671
1672 , or 
1673 \begin_inset Flex MenuItem
1674 status collapsed
1675
1676 \begin_layout Plain Layout
1677 jpg
1678 \end_layout
1679
1680 \end_inset
1681
1682 , since 
1683 \begin_inset Flex MenuItem
1684 status collapsed
1685
1686 \begin_layout Plain Layout
1687 pdflatex
1688 \end_layout
1689
1690 \end_inset
1691
1692  cannot handle other image formats.
1693  If an included graphic is not already in 
1694 \begin_inset Flex MenuItem
1695 status collapsed
1696
1697 \begin_layout Plain Layout
1698 pdf
1699 \end_layout
1700
1701 \end_inset
1702
1703
1704 \begin_inset Flex MenuItem
1705 status collapsed
1706
1707 \begin_layout Plain Layout
1708 png
1709 \end_layout
1710
1711 \end_inset
1712
1713 , or 
1714 \begin_inset Flex MenuItem
1715 status collapsed
1716
1717 \begin_layout Plain Layout
1718 jpg
1719 \end_layout
1720
1721 \end_inset
1722
1723  format, it is converted to 
1724 \begin_inset Flex MenuItem
1725 status collapsed
1726
1727 \begin_layout Plain Layout
1728 pdf
1729 \end_layout
1730
1731 \end_inset
1732
1733  if the vector format option is set, and otherwise to 
1734 \begin_inset Flex MenuItem
1735 status collapsed
1736
1737 \begin_layout Plain Layout
1738 png
1739 \end_layout
1740
1741 \end_inset
1742
1743 .
1744 \end_layout
1745
1746 \begin_layout Section
1747 Copiers
1748 \end_layout
1749
1750 \begin_layout Standard
1751 Since all conversions from one format to another take place in LyX's temporary
1752  directory, it is sometimes necessary to modify a file before copying it
1753  to the temporary directory in order that the conversion may be performed.
1754 \begin_inset Foot
1755 status collapsed
1756
1757 \begin_layout Plain Layout
1758 For example, the file may refer to other files—images, for example—using
1759  relative file names, and these may become invalid when the file is copied
1760  to the temporary directory.
1761 \end_layout
1762
1763 \end_inset
1764
1765  This is done by a Copier: It copies a file to (or from) the temporary directory
1766  and may modify it in the process.
1767 \end_layout
1768
1769 \begin_layout Standard
1770 The definitions of the copiers may use four variables:
1771 \end_layout
1772
1773 \begin_layout Labeling
1774 \labelwidthstring 00.00.0000
1775 \begin_inset Flex Code
1776 status collapsed
1777
1778 \begin_layout Plain Layout
1779 $$s
1780 \end_layout
1781
1782 \end_inset
1783
1784  The LyX system directory (e.
1785 \begin_inset space \thinspace{}
1786 \end_inset
1787
1788 g.
1789 \begin_inset space \space{}
1790 \end_inset
1791
1792
1793 \begin_inset Flex MenuItem
1794 status collapsed
1795
1796 \begin_layout Plain Layout
1797 /usr/share/lyx
1798 \end_layout
1799
1800 \end_inset
1801
1802 ).
1803 \end_layout
1804
1805 \begin_layout Labeling
1806 \labelwidthstring 00.00.0000
1807 \begin_inset Flex Code
1808 status collapsed
1809
1810 \begin_layout Plain Layout
1811 $$i
1812 \end_layout
1813
1814 \end_inset
1815
1816  The input file
1817 \end_layout
1818
1819 \begin_layout Labeling
1820 \labelwidthstring 00.00.0000
1821 \begin_inset Flex Code
1822 status collapsed
1823
1824 \begin_layout Plain Layout
1825 $$o
1826 \end_layout
1827
1828 \end_inset
1829
1830  The output file
1831 \end_layout
1832
1833 \begin_layout Labeling
1834 \labelwidthstring 00.00.0000
1835 \begin_inset Flex Code
1836 status collapsed
1837
1838 \begin_layout Plain Layout
1839 $$b
1840 \end_layout
1841
1842 \end_inset
1843
1844  The base name (without filename extension) in the LyX temporary directory
1845 \end_layout
1846
1847 \begin_layout Labeling
1848 \labelwidthstring 00.00.0000
1849 \begin_inset Flex Code
1850 status collapsed
1851
1852 \begin_layout Plain Layout
1853 $$p
1854 \end_layout
1855
1856 \end_inset
1857
1858  The full directory path of the LyX temporary directory
1859 \end_layout
1860
1861 \begin_layout Labeling
1862 \labelwidthstring 00.00.0000
1863 \begin_inset Flex Code
1864 status collapsed
1865
1866 \begin_layout Plain Layout
1867 $$r
1868 \end_layout
1869
1870 \end_inset
1871
1872  The full pathname to the original LyX file being processed
1873 \end_layout
1874
1875 \begin_layout Labeling
1876 \labelwidthstring 00.00.0000
1877 \begin_inset Flex Code
1878 status collapsed
1879
1880 \begin_layout Plain Layout
1881 $$f
1882 \end_layout
1883
1884 \end_inset
1885
1886  The filename (without any directory path) of the LyX file.
1887 \end_layout
1888
1889 \begin_layout Labeling
1890 \labelwidthstring 00.00.0000
1891 \begin_inset Flex Code
1892 status collapsed
1893
1894 \begin_layout Plain Layout
1895 $$l
1896 \end_layout
1897
1898 \end_inset
1899
1900  The `LaTeX name'
1901 \end_layout
1902
1903 \begin_layout Standard
1904 The latter should be the filename as it would be used in a LaTeX's 
1905 \series bold
1906
1907 \backslash
1908 include
1909 \series default
1910  command.
1911  It is relevant only when exporting files suitable for such inclusion.
1912 \end_layout
1913
1914 \begin_layout Standard
1915 Copiers can be used to do almost anything with output files.
1916  For example, suppose you want generated pdf files to be copied to a special
1917  directory, 
1918 \begin_inset Flex Code
1919 status collapsed
1920
1921 \begin_layout Plain Layout
1922 /home/you/pdf/
1923 \end_layout
1924
1925 \end_inset
1926
1927 .
1928  Then you could write a shell script such as this one:
1929 \end_layout
1930
1931 \begin_layout Standard
1932 \begin_inset listings
1933 inline false
1934 status open
1935
1936 \begin_layout Plain Layout
1937
1938 #!/bin/bash
1939 \end_layout
1940
1941 \begin_layout Plain Layout
1942
1943 FROMFILE=$1
1944 \end_layout
1945
1946 \begin_layout Plain Layout
1947
1948 TOFILE=`basename $2`
1949 \end_layout
1950
1951 \begin_layout Plain Layout
1952
1953 cp $FROMFILE /home/you/pdf/$TOFILE
1954 \end_layout
1955
1956 \end_inset
1957
1958 Save it in your local LyX directory—say, 
1959 \begin_inset Flex Code
1960 status collapsed
1961
1962 \begin_layout Plain Layout
1963 /home/you/.lyx/scripts/pdfcopier.sh
1964 \end_layout
1965
1966 \end_inset
1967
1968 —and make it executable, if you need to do so on your platform.
1969  Then, in the 
1970 \begin_inset Flex MenuItem
1971 status collapsed
1972
1973 \begin_layout Plain Layout
1974 Tools\SpecialChar \menuseparator
1975 Preferences
1976 \end_layout
1977
1978 \end_inset
1979
1980  dialog, select under 
1981 \begin_inset Flex MenuItem
1982 status collapsed
1983
1984 \begin_layout Plain Layout
1985 File Handling\SpecialChar \menuseparator
1986 File formats
1987 \end_layout
1988
1989 \end_inset
1990
1991  the 
1992 \begin_inset Flex MenuItem
1993 status collapsed
1994
1995 \begin_layout Plain Layout
1996 PDF(pdflatex)
1997 \end_layout
1998
1999 \end_inset
2000
2001  format—or one of the other pdf formats—and enter 
2002 \begin_inset Flex Code
2003 status collapsed
2004
2005 \begin_layout Plain Layout
2006 pdfcopier.sh $$i $$o
2007 \end_layout
2008
2009 \end_inset
2010
2011  into the 
2012 \begin_inset Flex MenuItem
2013 status collapsed
2014
2015 \begin_layout Plain Layout
2016 Copier
2017 \end_layout
2018
2019 \end_inset
2020
2021  field.
2022  
2023 \end_layout
2024
2025 \begin_layout Standard
2026 Copiers are used by LyX in various of its own conversions.
2027  For example, if appropriate programs are found, LyX will automatically
2028  install copiers for the 
2029 \begin_inset Flex MenuItem
2030 status collapsed
2031
2032 \begin_layout Plain Layout
2033 HTML
2034 \end_layout
2035
2036 \end_inset
2037
2038  and 
2039 \begin_inset Flex MenuItem
2040 status collapsed
2041
2042 \begin_layout Plain Layout
2043 HTML
2044 \begin_inset space ~
2045 \end_inset
2046
2047 (MS Word)
2048 \end_layout
2049
2050 \end_inset
2051
2052  formats.
2053  When these formats are exported, the copier sees that not just the main
2054  HTML file but various associated files (style files, images, etc.) are also
2055  copied.
2056  All these files are written to a subdirectory of the directory in which
2057  the original LyX file was found.
2058 \begin_inset Foot
2059 status collapsed
2060
2061 \begin_layout Plain Layout
2062 This copier can be customized.
2063  The optional 
2064 \begin_inset Quotes eld
2065 \end_inset
2066
2067 -e
2068 \begin_inset Quotes erd
2069 \end_inset
2070
2071  argument takes a comma-separated list of extensions to be copied; if it
2072  is omitted, all files will be copied.
2073  The 
2074 \begin_inset Quotes eld
2075 \end_inset
2076
2077 -t
2078 \begin_inset Quotes erd
2079 \end_inset
2080
2081  argument determines the extension added to the generated directory.
2082  By default, it is 
2083 \begin_inset Quotes eld
2084 \end_inset
2085
2086
2087 \begin_inset Flex MenuItem
2088 status collapsed
2089
2090 \begin_layout Plain Layout
2091 LyXconv
2092 \end_layout
2093
2094 \end_inset
2095
2096
2097 \begin_inset Quotes erd
2098 \end_inset
2099
2100 , so HTML generated from 
2101 \begin_inset Flex MenuItem
2102 status collapsed
2103
2104 \begin_layout Plain Layout
2105 /path/to/filename.lyx
2106 \end_layout
2107
2108 \end_inset
2109
2110  will end up in 
2111 \begin_inset Flex MenuItem
2112 status collapsed
2113
2114 \begin_layout Plain Layout
2115 /path/to/filename.html.LyXconv
2116 \end_layout
2117
2118 \end_inset
2119
2120 .
2121  
2122 \end_layout
2123
2124 \end_inset
2125
2126
2127 \end_layout
2128
2129 \begin_layout Section
2130 Converters
2131 \begin_inset CommandInset label
2132 LatexCommand label
2133 name "sec:Converters"
2134
2135 \end_inset
2136
2137
2138 \end_layout
2139
2140 \begin_layout Standard
2141 You can define your own Converters to convert files between different formats.
2142  This is done in the 
2143 \begin_inset Flex MenuItem
2144 status collapsed
2145
2146 \begin_layout Plain Layout
2147 Tools\SpecialChar \menuseparator
2148 Preferences\SpecialChar \menuseparator
2149 File Handling\SpecialChar \menuseparator
2150 Converters
2151 \end_layout
2152
2153 \end_inset
2154
2155  dialog.
2156 \end_layout
2157
2158 \begin_layout Standard
2159 To define a new converter, select the 
2160 \begin_inset Flex MenuItem
2161 status collapsed
2162
2163 \begin_layout Plain Layout
2164 From
2165 \begin_inset space ~
2166 \end_inset
2167
2168 format
2169 \end_layout
2170
2171 \end_inset
2172
2173  and 
2174 \begin_inset Flex MenuItem
2175 status collapsed
2176
2177 \begin_layout Plain Layout
2178 To
2179 \begin_inset space ~
2180 \end_inset
2181
2182 format
2183 \end_layout
2184
2185 \end_inset
2186
2187  from the drop-down lists, enter the command needed for the conversion,
2188  and then press the 
2189 \begin_inset Flex MenuItem
2190 status collapsed
2191
2192 \begin_layout Plain Layout
2193 Add
2194 \end_layout
2195
2196 \end_inset
2197
2198  button.
2199  Several variables can be used in the definition of converters:
2200 \end_layout
2201
2202 \begin_layout Labeling
2203 \labelwidthstring 00.00.0000
2204 \begin_inset Flex Code
2205 status collapsed
2206
2207 \begin_layout Plain Layout
2208 $$s
2209 \end_layout
2210
2211 \end_inset
2212
2213  The LyX system directory
2214 \end_layout
2215
2216 \begin_layout Labeling
2217 \labelwidthstring 00.00.0000
2218 \begin_inset Flex Code
2219 status collapsed
2220
2221 \begin_layout Plain Layout
2222 $$i
2223 \end_layout
2224
2225 \end_inset
2226
2227  The input file
2228 \end_layout
2229
2230 \begin_layout Labeling
2231 \labelwidthstring 00.00.0000
2232 \begin_inset Flex Code
2233 status collapsed
2234
2235 \begin_layout Plain Layout
2236 $$o
2237 \end_layout
2238
2239 \end_inset
2240
2241  The output file
2242 \end_layout
2243
2244 \begin_layout Labeling
2245 \labelwidthstring 00.00.0000
2246 \begin_inset Flex Code
2247 status collapsed
2248
2249 \begin_layout Plain Layout
2250 $$b
2251 \end_layout
2252
2253 \end_inset
2254
2255  The base filename of the input file (i.
2256 \begin_inset space \thinspace{}
2257 \end_inset
2258
2259 g., without the extension)
2260 \end_layout
2261
2262 \begin_layout Labeling
2263 \labelwidthstring 00.00.0000
2264 \begin_inset Flex Code
2265 status collapsed
2266
2267 \begin_layout Plain Layout
2268 $$p
2269 \end_layout
2270
2271 \end_inset
2272
2273  The path to the input file
2274 \end_layout
2275
2276 \begin_layout Labeling
2277 \labelwidthstring 00.00.0000
2278 \begin_inset Flex Code
2279 status collapsed
2280
2281 \begin_layout Plain Layout
2282 $$r
2283 \end_layout
2284
2285 \end_inset
2286
2287  The path to the original input file (this is different from $$p when a
2288  chain of converters is called)
2289 \end_layout
2290
2291 \begin_layout Labeling
2292 \labelwidthstring 00.00.0000
2293 \begin_inset Flex Code
2294 status collapsed
2295
2296 \begin_layout Plain Layout
2297 $$e
2298 \end_layout
2299
2300 \end_inset
2301
2302  The iconv name for the encoding of the document.
2303 \end_layout
2304
2305 \begin_layout Standard
2306 In the 
2307 \begin_inset Flex MenuItem
2308 status collapsed
2309
2310 \begin_layout Plain Layout
2311 Extra
2312 \begin_inset space ~
2313 \end_inset
2314
2315 Flag
2316 \end_layout
2317
2318 \end_inset
2319
2320  field you can enter the following flags, separated by commas:
2321 \end_layout
2322
2323 \begin_layout Labeling
2324 \labelwidthstring 00.00.0000
2325 \begin_inset Flex Code
2326 status collapsed
2327
2328 \begin_layout Plain Layout
2329 latex
2330 \end_layout
2331
2332 \end_inset
2333
2334  This converter runs some form of LaTeX.
2335  This will make LyX's LaTeX error logs available.
2336 \end_layout
2337
2338 \begin_layout Labeling
2339 \labelwidthstring 00.00.0000
2340 \begin_inset Flex Code
2341 status collapsed
2342
2343 \begin_layout Plain Layout
2344 needaux
2345 \end_layout
2346
2347 \end_inset
2348
2349  Needs the LaTeX 
2350 \begin_inset Flex MenuItem
2351 status collapsed
2352
2353 \begin_layout Plain Layout
2354 .aux
2355 \end_layout
2356
2357 \end_inset
2358
2359  file for the conversion.
2360 \end_layout
2361
2362 \begin_layout Labeling
2363 \labelwidthstring 00.00.0000
2364 \begin_inset Flex Code
2365 status collapsed
2366
2367 \begin_layout Plain Layout
2368 nice
2369 \end_layout
2370
2371 \end_inset
2372
2373  Needs a 
2374 \begin_inset Quotes eld
2375 \end_inset
2376
2377 nice
2378 \begin_inset Quotes erd
2379 \end_inset
2380
2381  file from the backend, which in practice means a LaTeX file like the one
2382  we would export, without 
2383 \begin_inset Flex Code
2384 status collapsed
2385
2386 \begin_layout Plain Layout
2387 input@path
2388 \end_layout
2389
2390 \end_inset
2391
2392 .
2393 \end_layout
2394
2395 \begin_layout Labeling
2396 \labelwidthstring 00.00.0000
2397 \begin_inset Flex Code
2398 status collapsed
2399
2400 \begin_layout Plain Layout
2401 xml
2402 \end_layout
2403
2404 \end_inset
2405
2406  Output is XML.
2407 \end_layout
2408
2409 \begin_layout Standard
2410 The following three flags are not really flags at all because they take
2411  an argument in the 
2412 \begin_inset Flex MenuItem
2413 status collapsed
2414
2415 \begin_layout Plain Layout
2416 key
2417 \begin_inset space ~
2418 \end_inset
2419
2420 =
2421 \begin_inset space ~
2422 \end_inset
2423
2424 value
2425 \end_layout
2426
2427 \end_inset
2428
2429  format:
2430 \end_layout
2431
2432 \begin_layout Labeling
2433 \labelwidthstring 00.00.0000
2434 \begin_inset Flex Code
2435 status collapsed
2436
2437 \begin_layout Plain Layout
2438 parselog
2439 \end_layout
2440
2441 \end_inset
2442
2443  If set, the converter's standard error will be redirected to a file 
2444 \begin_inset Flex Code
2445 status collapsed
2446
2447 \begin_layout Plain Layout
2448 infile.out
2449 \end_layout
2450
2451 \end_inset
2452
2453 , and the script given as argument will be run as: 
2454 \begin_inset Flex Code
2455 status collapsed
2456
2457 \begin_layout Plain Layout
2458 script < infile.out > infile.log
2459 \end_layout
2460
2461 \end_inset
2462
2463 .
2464  The argument may contain 
2465 \begin_inset Flex Code
2466 status collapsed
2467
2468 \begin_layout Plain Layout
2469 $$s
2470 \end_layout
2471
2472 \end_inset
2473
2474 .
2475 \end_layout
2476
2477 \begin_layout Labeling
2478 \labelwidthstring 00.00.0000
2479 \begin_inset Flex Code
2480 status collapsed
2481
2482 \begin_layout Plain Layout
2483 resultdir
2484 \end_layout
2485
2486 \end_inset
2487
2488  The name of the directory in which the converter will dump the generated
2489  files.
2490  LyX will not create this directory, and it does not copy anything into
2491  it, though it will copy this directory to the destination.
2492  The argument may contain 
2493 \begin_inset Flex Code
2494 status collapsed
2495
2496 \begin_layout Plain Layout
2497 $$b
2498 \end_layout
2499
2500 \end_inset
2501
2502 , which will be replaced by the base name of the input and output files,
2503  respectively, when the directory is copied.
2504 \begin_inset Newline newline
2505 \end_inset
2506
2507 Note that resultdir and usetempdir make no sense together.
2508  The latter will be ignored if the former is given.
2509 \end_layout
2510
2511 \begin_layout Labeling
2512 \labelwidthstring 00.00.0000
2513 \begin_inset Flex Code
2514 status collapsed
2515
2516 \begin_layout Plain Layout
2517 resultfile
2518 \end_layout
2519
2520 \end_inset
2521
2522  Determines the output file name and may, contain 
2523 \begin_inset Flex Code
2524 status collapsed
2525
2526 \begin_layout Plain Layout
2527 $$b
2528 \end_layout
2529
2530 \end_inset
2531
2532 .
2533  Sensible only with resultdir and optional even then; if not given, it defaults
2534  to `index'.
2535 \end_layout
2536
2537 \begin_layout Standard
2538 None of these last three are presently used in any of the converters that
2539  are installed with LyX.
2540  
2541 \end_layout
2542
2543 \begin_layout Standard
2544 You do not have to define converters for all formats between which you want
2545  to convert.
2546  For example, you will note that there is no `LyX to PostScript' converter,
2547  but LyX will export PostScript.
2548  It does so by first creating a LaTeX file (no converter needs to be defined
2549  for this) which is then converted to DVI using the `LaTeX to DVI' converter,
2550  and finally converting the resulting DVI file to PostScript.
2551  LyX finds such `chains' of converters automatically, and it will always
2552  choose the shortest possible chain.
2553  You can, though, still define multiple conversion methods between file
2554  formats.
2555  For example, the standard LyX configuration provides five ways to convert
2556  LaTeX to PDF:
2557 \end_layout
2558
2559 \begin_layout Enumerate
2560 Directly, using 
2561 \begin_inset Flex MenuItem
2562 status collapsed
2563
2564 \begin_layout Plain Layout
2565 pdflatex
2566 \end_layout
2567
2568 \end_inset
2569
2570
2571 \end_layout
2572
2573 \begin_layout Enumerate
2574 via (DVI and) PostScript, using 
2575 \begin_inset Flex MenuItem
2576 status collapsed
2577
2578 \begin_layout Plain Layout
2579 ps2pdf
2580 \end_layout
2581
2582 \end_inset
2583
2584
2585 \end_layout
2586
2587 \begin_layout Enumerate
2588 via DVI, using 
2589 \begin_inset Flex MenuItem
2590 status collapsed
2591
2592 \begin_layout Plain Layout
2593 dvipdfm
2594 \end_layout
2595
2596 \end_inset
2597
2598
2599 \end_layout
2600
2601 \begin_layout Enumerate
2602 directly using 
2603 \begin_inset Flex MenuItem
2604 status collapsed
2605
2606 \begin_layout Plain Layout
2607 XeTeX
2608 \end_layout
2609
2610 \end_inset
2611
2612
2613 \end_layout
2614
2615 \begin_layout Enumerate
2616 directly using 
2617 \begin_inset Flex MenuItem
2618 status collapsed
2619
2620 \begin_layout Plain Layout
2621 LuaTeX
2622 \end_layout
2623
2624 \end_inset
2625
2626
2627 \end_layout
2628
2629 \begin_layout Standard
2630 To define such alternate chains, you must define multiple target `file formats',
2631  as described in 
2632 \begin_inset CommandInset ref
2633 LatexCommand ref
2634 reference "sec:Formats"
2635
2636 \end_inset
2637
2638 .
2639  For example, in the standard configuration, the formats named 
2640 \begin_inset Flex MenuItem
2641 status collapsed
2642
2643 \begin_layout Plain Layout
2644 pdf
2645 \end_layout
2646
2647 \end_inset
2648
2649  (for 
2650 \begin_inset Flex MenuItem
2651 status collapsed
2652
2653 \begin_layout Plain Layout
2654 ps2pdf
2655 \end_layout
2656
2657 \end_inset
2658
2659 ), 
2660 \begin_inset Flex MenuItem
2661 status collapsed
2662
2663 \begin_layout Plain Layout
2664 pdf2
2665 \end_layout
2666
2667 \end_inset
2668
2669  (for 
2670 \begin_inset Flex MenuItem
2671 status collapsed
2672
2673 \begin_layout Plain Layout
2674 pdflatex
2675 \end_layout
2676
2677 \end_inset
2678
2679 ), 
2680 \begin_inset Flex MenuItem
2681 status collapsed
2682
2683 \begin_layout Plain Layout
2684 pdf3
2685 \end_layout
2686
2687 \end_inset
2688
2689  (for 
2690 \begin_inset Flex MenuItem
2691 status collapsed
2692
2693 \begin_layout Plain Layout
2694 dvipdfm
2695 \end_layout
2696
2697 \end_inset
2698
2699 ), 
2700 \begin_inset Flex MenuItem
2701 status collapsed
2702
2703 \begin_layout Plain Layout
2704 pdf4
2705 \end_layout
2706
2707 \end_inset
2708
2709  (for 
2710 \begin_inset Flex MenuItem
2711 status collapsed
2712
2713 \begin_layout Plain Layout
2714 XeTeX
2715 \end_layout
2716
2717 \end_inset
2718
2719 ), and 
2720 \begin_inset Flex MenuItem
2721 status collapsed
2722
2723 \begin_layout Plain Layout
2724 pdf5
2725 \end_layout
2726
2727 \end_inset
2728
2729  (for 
2730 \begin_inset Flex MenuItem
2731 status collapsed
2732
2733 \begin_layout Plain Layout
2734 LuaTeX
2735 \end_layout
2736
2737 \end_inset
2738
2739 ) are defined, all of which share the extension 
2740 \begin_inset Flex MenuItem
2741 status collapsed
2742
2743 \begin_layout Plain Layout
2744 .pdf
2745 \end_layout
2746
2747 \end_inset
2748
2749 , and which correspond to the conversion methods just mentioned.
2750 \end_layout
2751
2752 \begin_layout Chapter
2753 Internationalizing LyX
2754 \begin_inset CommandInset label
2755 LatexCommand label
2756 name "cha:Internationalizing-LyX"
2757
2758 \end_inset
2759
2760
2761 \end_layout
2762
2763 \begin_layout Standard
2764 LyX supports using a translated interface.
2765  Last time we checked, LyX provided text in thirty languages.
2766  The language of choice is called your 
2767 \emph on
2768 locale
2769 \emph default
2770 .
2771  (For further reading on locale settings, see also the documentation for
2772  locale that comes with your operating system.
2773  For Linux, the manual page for 
2774 \begin_inset Flex Code
2775 status collapsed
2776
2777 \begin_layout Plain Layout
2778 locale(5)
2779 \end_layout
2780
2781 \end_inset
2782
2783  could be a good place to start).
2784 \end_layout
2785
2786 \begin_layout Standard
2787 Notice that these translations will work, but do contain a few flaws.
2788  In particular, all dialogs have been designed with the English text in
2789  mind, which means that some of the translated text will be too large to
2790  fit within the space allocated.
2791  This is only a display problem and will not cause any harm.
2792  Also, you will find that some of the translations do not define shortcut
2793  keys for everything.
2794  Sometimes, there are simply not enough free letters to do it.
2795  Other times, the translator just hasn't got around to doing it yet.
2796  Our localization team, which you may wish to join,
2797 \begin_inset Foot
2798 status collapsed
2799
2800 \begin_layout Plain Layout
2801 If you are a fluent speaker of a language other than English, joining these
2802  teams is a great way to give back to the LyX community!
2803 \end_layout
2804
2805 \end_inset
2806
2807  will of course try to fix these shortcomings in future versions of LyX.
2808 \end_layout
2809
2810 \begin_layout Section
2811 Translating LyX
2812 \end_layout
2813
2814 \begin_layout Subsection
2815 Translating the graphical user interface (text messages).
2816 \end_layout
2817
2818 \begin_layout Standard
2819 LyX uses the GNU 
2820 \begin_inset Flex Code
2821 status collapsed
2822
2823 \begin_layout Plain Layout
2824 gettext
2825 \end_layout
2826
2827 \end_inset
2828
2829  library to handle the internationalization of the interface.
2830  To have LyX speak your favorite language in all menus and dialogs, you
2831  need a 
2832 \begin_inset Flex Code
2833 status collapsed
2834
2835 \begin_layout Plain Layout
2836 po
2837 \end_layout
2838
2839 \end_inset
2840
2841 -file for that language.
2842  When this is available, you'll have to generate a 
2843 \begin_inset Flex Code
2844 status collapsed
2845
2846 \begin_layout Plain Layout
2847 mo
2848 \end_layout
2849
2850 \end_inset
2851
2852 -file from it and install the 
2853 \begin_inset Flex Code
2854 status collapsed
2855
2856 \begin_layout Plain Layout
2857 mo
2858 \end_layout
2859
2860 \end_inset
2861
2862 -file.
2863  The process of doing all of this is explained in the documentation for
2864  GNU 
2865 \begin_inset Flex Code
2866 status collapsed
2867
2868 \begin_layout Plain Layout
2869 gettext
2870 \end_layout
2871
2872 \end_inset
2873
2874 .
2875  It is possible to do this just for yourself, but if you're going to do
2876  it, you might as well share the results of your labors with the rest of
2877  the LyX community.
2878  Send a message to the LyX developers' list for more information about how
2879  to proceed.
2880 \end_layout
2881
2882 \begin_layout Standard
2883 In short, this is what you should do (xx denotes the language code):
2884 \end_layout
2885
2886 \begin_layout Itemize
2887 Check out the LyX source code.
2888  (See the 
2889 \begin_inset CommandInset href
2890 LatexCommand href
2891 name "information on the web"
2892 target "http://www.lyx.org/HowToUseSVN"
2893
2894 \end_inset
2895
2896 .)
2897 \end_layout
2898
2899 \begin_layout Itemize
2900 Copy the file 
2901 \begin_inset Flex Code
2902 status collapsed
2903
2904 \begin_layout Plain Layout
2905 lyx.pot
2906 \end_layout
2907
2908 \end_inset
2909
2910  to the folder of the 
2911 \begin_inset Flex Code
2912 status collapsed
2913
2914 \begin_layout Plain Layout
2915 **.po
2916 \end_layout
2917
2918 \end_inset
2919
2920  files.
2921  Then rename it to 
2922 \begin_inset Flex Code
2923 status collapsed
2924
2925 \begin_layout Plain Layout
2926 xx.po
2927 \end_layout
2928
2929 \end_inset
2930
2931 .
2932  (If 
2933 \begin_inset Flex Code
2934 status collapsed
2935
2936 \begin_layout Plain Layout
2937 lyx.pot
2938 \end_layout
2939
2940 \end_inset
2941
2942  doesn't exist anywhere, it can be remade with the console command 
2943 \begin_inset Flex Code
2944 status collapsed
2945
2946 \begin_layout Plain Layout
2947 make lyx.pot
2948 \end_layout
2949
2950 \end_inset
2951
2952  in that directory, or you can use an existing po-file for some other language
2953  as a template).
2954 \end_layout
2955
2956 \begin_layout Itemize
2957 Edit 
2958 \begin_inset Flex Code
2959 status collapsed
2960
2961 \begin_layout Plain Layout
2962 xx.po
2963 \end_layout
2964
2965 \end_inset
2966
2967 .
2968 \begin_inset Foot
2969 status collapsed
2970
2971 \begin_layout Plain Layout
2972 This is just a text file, so it can be edited in any text editor.
2973  But there are also specialized programs that support such editing, such
2974  as 
2975 \family typewriter
2976 Poedit
2977 \family default
2978  (for all platforms) or 
2979 \family typewriter
2980 KBabel
2981 \family default
2982  (for KDE).
2983  
2984 \family typewriter
2985 Emacs
2986 \family default
2987  contains a `mode' for editing 
2988 \begin_inset Flex Code
2989 status collapsed
2990
2991 \begin_layout Plain Layout
2992 po
2993 \end_layout
2994
2995 \end_inset
2996
2997  files, as well.
2998 \end_layout
2999
3000 \end_inset
3001
3002  For some menu- and widget-labels, there are also shortcut keys that should
3003  be translated.
3004  Those keys are marked after a `|', and should be translated according to
3005  the words and phrases of the language.
3006  You should also fill also out the information at the beginning of the new
3007  
3008 \begin_inset Flex Code
3009 status collapsed
3010
3011 \begin_layout Plain Layout
3012 po
3013 \end_layout
3014
3015 \end_inset
3016
3017 -file with your email-address, etc., so people know where to reach you with
3018  suggestions and entertaining flames.
3019 \end_layout
3020
3021 \begin_layout Standard
3022 If you are just doing this on your own, then:
3023 \end_layout
3024
3025 \begin_layout Itemize
3026 Generate 
3027 \begin_inset Flex Code
3028 status collapsed
3029
3030 \begin_layout Plain Layout
3031 xx.mo
3032 \end_layout
3033
3034 \end_inset
3035
3036 .
3037  This can be done with 
3038 \begin_inset Flex Code
3039 status collapsed
3040
3041 \begin_layout Plain Layout
3042 msgfmt -o xx.mo < xx.po
3043 \end_layout
3044
3045 \end_inset
3046
3047 .
3048 \end_layout
3049
3050 \begin_layout Itemize
3051 Copy the 
3052 \begin_inset Flex Code
3053 status collapsed
3054
3055 \begin_layout Plain Layout
3056 mo
3057 \end_layout
3058
3059 \end_inset
3060
3061 -file to your locale-tree, at the correct directory for application messages
3062  for the language
3063 \series bold
3064  
3065 \series default
3066 xx, and under the name 
3067 \begin_inset Flex Code
3068 status collapsed
3069
3070 \begin_layout Plain Layout
3071 lyx.mo
3072 \end_layout
3073
3074 \end_inset
3075
3076  (e.
3077 \begin_inset space \thinspace{}
3078 \end_inset
3079
3080 g.
3081 \begin_inset space \space{}
3082 \end_inset
3083
3084
3085 \begin_inset Flex Code
3086 status collapsed
3087
3088 \begin_layout Plain Layout
3089 /usr/local/share/locale/xx/LC_MESSAGES/lyx.mo
3090 \end_layout
3091
3092 \end_inset
3093
3094
3095 \series bold
3096 .
3097 \end_layout
3098
3099 \begin_layout Standard
3100 As said, however, it would be best if the new 
3101 \begin_inset Flex Code
3102 status collapsed
3103
3104 \begin_layout Plain Layout
3105 po
3106 \end_layout
3107
3108 \end_inset
3109
3110 -file could be added to the LyX distribution, so others can use it.
3111  Adding it involves making additional changes to LyX.
3112  So send an email to the developers' mailing list if you're interested in
3113  doing that.
3114 \end_layout
3115
3116 \begin_layout Subsubsection
3117 Ambiguous messages
3118 \end_layout
3119
3120 \begin_layout Standard
3121 Sometimes it turns out that one English message needs to be translated into
3122  different messages in the target language.
3123  One example is the message 
3124 \begin_inset Flex Code
3125 status collapsed
3126
3127 \begin_layout Plain Layout
3128 To
3129 \end_layout
3130
3131 \end_inset
3132
3133  which has the German translation 
3134 \lang german
3135 Nach
3136 \lang english
3137  or 
3138 \lang german
3139 Bis
3140 \lang english
3141 , depending upon exactly what the English 
3142 \begin_inset Quotes eld
3143 \end_inset
3144
3145 to
3146 \begin_inset Quotes erd
3147 \end_inset
3148
3149  means.
3150  GNU 
3151 \begin_inset Flex Code
3152 status collapsed
3153
3154 \begin_layout Plain Layout
3155 gettext
3156 \end_layout
3157
3158 \end_inset
3159
3160  does not handle such ambiguous translations.
3161  Therefore you have to add some context information to the message: Instead
3162  of 
3163 \begin_inset Flex Code
3164 status collapsed
3165
3166 \begin_layout Plain Layout
3167 To
3168 \end_layout
3169
3170 \end_inset
3171
3172  it becomes 
3173 \begin_inset Flex Code
3174 status collapsed
3175
3176 \begin_layout Plain Layout
3177 To[[as in 'From format x to format y']]
3178 \end_layout
3179
3180 \end_inset
3181
3182  and 
3183 \begin_inset Flex Code
3184 status collapsed
3185
3186 \begin_layout Plain Layout
3187 To[[as in 'From page x to page y']].
3188 \end_layout
3189
3190 \end_inset
3191
3192  Now the two occurrences of 
3193 \begin_inset Flex Code
3194 status collapsed
3195
3196 \begin_layout Plain Layout
3197 To
3198 \end_layout
3199
3200 \end_inset
3201
3202  are different for 
3203 \begin_inset Flex Code
3204 status collapsed
3205
3206 \begin_layout Plain Layout
3207 gettext
3208 \end_layout
3209
3210 \end_inset
3211
3212  and can be translated correctly to 
3213 \lang german
3214 Nach
3215 \lang english
3216  and 
3217 \lang german
3218 Bis
3219 \lang english
3220 , respectively.
3221 \end_layout
3222
3223 \begin_layout Standard
3224 Of course the context information needs to be stripped off the original
3225  message when no translation is used.
3226  Therefore you have to put it in double square brackets at the end of the
3227  message (see the example above).
3228  The translation mechanism of LyX ensures that everything in double square
3229  brackets at the end of messages is removed before displaying the message.
3230 \end_layout
3231
3232 \begin_layout Subsection
3233 Translating the documentation.
3234 \end_layout
3235
3236 \begin_layout Standard
3237 The online documentation (in the 
3238 \begin_inset Flex MenuItem
3239 status collapsed
3240
3241 \begin_layout Plain Layout
3242 Help
3243 \end_layout
3244
3245 \end_inset
3246
3247 -menu) can (and should!) be translated.
3248  If there are translated versions of the documentation available
3249 \begin_inset Foot
3250 status collapsed
3251
3252 \begin_layout Plain Layout
3253 As of March 2008, at least some of the documents have been translated into
3254  fourteen languages, with the Tutorial available in a few more.
3255 \end_layout
3256
3257 \end_inset
3258
3259  and the locale is set accordingly, these will be used automagically by
3260  LyX.
3261  LyX looks for translated versions as 
3262 \begin_inset Flex Code
3263 status collapsed
3264
3265 \begin_layout Plain Layout
3266 LyXDir/doc/xx/DocName.lyx
3267 \end_layout
3268
3269 \end_inset
3270
3271 , where 
3272 \begin_inset Flex Code
3273 status collapsed
3274
3275 \begin_layout Plain Layout
3276 xx
3277 \end_layout
3278
3279 \end_inset
3280
3281  is the code for the language currently in use.
3282  If there are no translated documents, the default English versions will
3283  be displayed.
3284  Note that the translated versions must have the same filenames (
3285 \begin_inset Flex Code
3286 status collapsed
3287
3288 \begin_layout Plain Layout
3289 DocName
3290 \end_layout
3291
3292 \end_inset
3293
3294  above) as the original.
3295  If you feel up to translating the documentation (an excellent way to proof-read
3296  the original documentation by the way!), there are a few things you should
3297  do right away:
3298 \end_layout
3299
3300 \begin_layout Itemize
3301 Check out the documentation translation web page at 
3302 \begin_inset CommandInset href
3303 LatexCommand href
3304 name "http://www.lyx.org/Translation"
3305 target "http://www.lyx.org/Translation"
3306
3307 \end_inset
3308
3309 .
3310  That way, you can find out which (if any) documents have already been translate
3311 d into your language.
3312  You can also find out who (if anyone) is organizing the effort to translate
3313  the documentation into your language.
3314  If no one is organizing the effort, please let us know that you're interested.
3315 \end_layout
3316
3317 \begin_layout Standard
3318 Once you get to actually translating, here's a few hints for you that may
3319  save you trouble:
3320 \end_layout
3321
3322 \begin_layout Itemize
3323 Join the documentation team! There is information on how to do that in 
3324 \begin_inset Flex Code
3325 status collapsed
3326
3327 \begin_layout Plain Layout
3328 Intro.lyx
3329 \end_layout
3330
3331 \end_inset
3332
3333  (
3334 \begin_inset Flex MenuItem
3335 status collapsed
3336
3337 \begin_layout Plain Layout
3338 Help\SpecialChar \menuseparator
3339 Introduction
3340 \end_layout
3341
3342 \end_inset
3343
3344 ), which by the way is the first document you should translate.
3345 \end_layout
3346
3347 \begin_layout Itemize
3348 Learn the typographic conventions for the language you are translating to.
3349  Typography is an ancient art and over the centuries, a great variety of
3350  conventions have developed throughout different parts of the world.
3351  Also study the professional terminology amongst typographers in your country.
3352  Inventing your own terminology will only confuse the users.
3353  
3354 \emph on
3355 (Warning! Typography is addictive!)
3356 \end_layout
3357
3358 \begin_layout Itemize
3359 Make a copy of the document.
3360  This will be your working copy.
3361  You can use this as your personal translated help-file by placing it in
3362  your 
3363 \begin_inset Flex Code
3364 status collapsed
3365
3366 \begin_layout Plain Layout
3367 UserDir/doc/xx/
3368 \end_layout
3369
3370 \end_inset
3371
3372  directory.
3373 \end_layout
3374
3375 \begin_layout Itemize
3376 Sometimes the original document (from the LyX-team) will be updated.
3377  Use the source viewer at 
3378 \begin_inset CommandInset href
3379 LatexCommand href
3380 name "http://www.lyx.org/trac/timeline"
3381 target "http://www.lyx.org/trac/timeline"
3382
3383 \end_inset
3384
3385  to see what has been changed.
3386  That way you can easily see which parts of the translated document need
3387  to be updated.
3388 \end_layout
3389
3390 \begin_layout Standard
3391 If you ever find an error in the original document, fix it and notify the
3392  rest of the documentation team of the changes! (You didn't forget to join
3393  the documentation team, did you?)
3394 \end_layout
3395
3396 \begin_layout Standard
3397 \begin_inset Branch OutDated
3398 status collapsed
3399
3400 \begin_layout Section
3401 International Keyboard Support
3402 \end_layout
3403
3404 \begin_layout Standard
3405
3406 \emph on
3407 [Editor's Note: The following section is by
3408 \emph default
3409  
3410 \shape smallcaps
3411 \emph on
3412 Ivan Schreter
3413 \shape default
3414 .
3415  It needs to be fixed to conform to the new Documentation Style sheet and
3416  to make use of the new v1.0 features.
3417  The whole thing also needs to be merged with the section following it.-jw
3418  It may also be badly out of date.-rh (2008)]
3419 \end_layout
3420
3421 \begin_layout Subsection
3422 Defining Own Keymaps: Keymap File Format
3423 \end_layout
3424
3425 \begin_layout Standard
3426 Let's look at a keyboard definition file a little closer.
3427  It is a plain text file defining
3428 \end_layout
3429
3430 \begin_layout Itemize
3431 key-to-key or key-to-string translations
3432 \end_layout
3433
3434 \begin_layout Itemize
3435 dead keys
3436 \end_layout
3437
3438 \begin_layout Itemize
3439 dead keys exceptions
3440 \end_layout
3441
3442 \begin_layout Standard
3443 To define key-to-key or key-to-string translation, use this command:
3444 \end_layout
3445
3446 \begin_layout Quotation
3447 \begin_inset Flex Code
3448 status collapsed
3449
3450 \begin_layout Plain Layout
3451
3452 \backslash
3453 kmap
3454 \end_layout
3455
3456 \end_inset
3457
3458  
3459 \begin_inset Flex Code
3460 status collapsed
3461
3462 \begin_layout Plain Layout
3463 key
3464 \end_layout
3465
3466 \end_inset
3467
3468  outstring 
3469 \end_layout
3470
3471 \begin_layout Standard
3472 where 
3473 \begin_inset Flex Code
3474 status collapsed
3475
3476 \begin_layout Plain Layout
3477 key
3478 \end_layout
3479
3480 \end_inset
3481
3482  is the key to be translated and 
3483 \begin_inset Flex Code
3484 status collapsed
3485
3486 \begin_layout Plain Layout
3487 outstring
3488 \end_layout
3489
3490 \end_inset
3491
3492  is the string to be inserted into the document.
3493  To define dead keys, use:
3494 \end_layout
3495
3496 \begin_layout Quotation
3497 \begin_inset Flex Code
3498 status collapsed
3499
3500 \begin_layout Plain Layout
3501
3502 \backslash
3503 kmod
3504 \end_layout
3505
3506 \end_inset
3507
3508  
3509 \begin_inset Flex Code
3510 status collapsed
3511
3512 \begin_layout Plain Layout
3513 key
3514 \end_layout
3515
3516 \end_inset
3517
3518  deadkey
3519 \end_layout
3520
3521 \begin_layout Standard
3522 where 
3523 \begin_inset Flex Code
3524 status collapsed
3525
3526 \begin_layout Plain Layout
3527 key
3528 \end_layout
3529
3530 \end_inset
3531
3532  is a keyboard key and 
3533 \begin_inset Flex Code
3534 status collapsed
3535
3536 \begin_layout Plain Layout
3537 deadkey
3538 \end_layout
3539
3540 \end_inset
3541
3542  is dead key name.
3543  The following dead keys are supported (shortcut name is in parentheses):
3544 \end_layout
3545
3546 \begin_layout Quotation
3547
3548 \emph on
3549 Name
3550 \begin_inset space \hfill{}
3551 \end_inset
3552
3553 Example
3554 \end_layout
3555
3556 \begin_layout Quotation
3557 acute (acu)
3558 \begin_inset space \hfill{}
3559 \end_inset
3560
3561 áéíóú
3562 \end_layout
3563
3564 \begin_layout Quotation
3565 grave (gra)
3566 \begin_inset space \hfill{}
3567 \end_inset
3568
3569 àèìòù
3570 \end_layout
3571
3572 \begin_layout Quotation
3573 macron (mac)
3574 \begin_inset space \hfill{}
3575 \end_inset
3576
3577  ō
3578 \end_layout
3579
3580 \begin_layout Quotation
3581 tilde (til)
3582 \begin_inset space \hfill{}
3583 \end_inset
3584
3585 ñÑ
3586 \end_layout
3587
3588 \begin_layout Quotation
3589 underbar (underb)
3590 \begin_inset space \hfill{}
3591 \end_inset
3592
3593
3594 \begin_inset ERT
3595 status open
3596
3597 \begin_layout Plain Layout
3598
3599
3600 \backslash
3601 b o
3602 \end_layout
3603
3604 \end_inset
3605
3606
3607 \end_layout
3608
3609 \begin_layout Quotation
3610 cedilla (ced)
3611 \begin_inset space \hfill{}
3612 \end_inset
3613
3614 çÇ
3615 \end_layout
3616
3617 \begin_layout Quotation
3618 underdot (underd)
3619 \begin_inset space \hfill{}
3620 \end_inset
3621
3622
3623 \begin_inset ERT
3624 status open
3625
3626 \begin_layout Plain Layout
3627
3628
3629 \backslash
3630 d o
3631 \end_layout
3632
3633 \end_inset
3634
3635
3636 \end_layout
3637
3638 \begin_layout Quotation
3639 circumflex (circu)
3640 \begin_inset space \hfill{}
3641 \end_inset
3642
3643 âêîôû
3644 \end_layout
3645
3646 \begin_layout Quotation
3647 circle (circl)
3648 \begin_inset space \hfill{}
3649 \end_inset
3650
3651 ÅůŮ
3652 \end_layout
3653
3654 \begin_layout Quotation
3655 tie (tie)
3656 \begin_inset space \hfill{}
3657 \end_inset
3658
3659
3660 \begin_inset ERT
3661 status open
3662
3663 \begin_layout Plain Layout
3664
3665
3666 \backslash
3667 t o
3668 \end_layout
3669
3670 \end_inset
3671
3672
3673 \end_layout
3674
3675 \begin_layout Quotation
3676 breve (bre)
3677 \begin_inset space \hfill{}
3678 \end_inset
3679
3680 ă
3681 \begin_inset ERT
3682 status open
3683
3684 \begin_layout Plain Layout
3685
3686
3687 \backslash
3688 u o
3689 \end_layout
3690
3691 \end_inset
3692
3693
3694 \end_layout
3695
3696 \begin_layout Quotation
3697 caron (car)
3698 \begin_inset space \hfill{}
3699 \end_inset
3700
3701 čšž
3702 \end_layout
3703
3704 \begin_layout Quotation
3705 hungarian umlaut (hug)
3706 \begin_inset space \hfill{}
3707 \end_inset
3708
3709 őű
3710 \end_layout
3711
3712 \begin_layout Quotation
3713 umlaut (uml)
3714 \begin_inset space \hfill{}
3715 \end_inset
3716
3717 äöü
3718 \end_layout
3719
3720 \begin_layout Quotation
3721 dot (dot)
3722 \begin_inset space \hfill{}
3723 \end_inset
3724
3725 ż
3726 \begin_inset ERT
3727 status open
3728
3729 \begin_layout Plain Layout
3730
3731
3732 \backslash
3733 .s
3734 \end_layout
3735
3736 \end_inset
3737
3738
3739 \end_layout
3740
3741 \begin_layout Standard
3742 Since in many international keyboards there are exceptions to what some
3743  dead keys should do, you can define them using
3744 \end_layout
3745
3746 \begin_layout Quotation
3747 \begin_inset Flex Code
3748 status collapsed
3749
3750 \begin_layout Plain Layout
3751
3752 \backslash
3753 kxmod
3754 \end_layout
3755
3756 \end_inset
3757
3758  deadkey key outstring
3759 \end_layout
3760
3761 \begin_layout Standard
3762 For example, on Slovak keyboard, if you enter caron-o, it generates circumflex-o
3763 , so you put in
3764 \end_layout
3765
3766 \begin_layout Quotation
3767 \begin_inset Flex Code
3768 status collapsed
3769
3770 \begin_layout Plain Layout
3771
3772 \backslash
3773 kxmod
3774 \end_layout
3775
3776 \end_inset
3777
3778  caron o "
3779 \backslash
3780 ^o"
3781 \end_layout
3782
3783 \begin_layout Standard
3784 to make it work correctly.
3785  Also, you have to define as exceptions dead keys over i and j, to remove
3786  the dot from them before inserting an accent mark.
3787  I will change this when the time comes, but so far I haven't had time.
3788 \end_layout
3789
3790 \begin_layout Standard
3791 Oh, and about characters: backslash is escaped, so to enter it, you'll need
3792  double backslash.
3793  Also, quotes and 
3794 \begin_inset Flex Code
3795 status collapsed
3796
3797 \begin_layout Plain Layout
3798 #
3799 \end_layout
3800
3801 \end_inset
3802
3803  have different meaning.
3804  
3805 \begin_inset Flex Code
3806 status collapsed
3807
3808 \begin_layout Plain Layout
3809 #
3810 \end_layout
3811
3812 \end_inset
3813
3814  marks comments, quotes start and end LaTeX-style commands.
3815  To enter quote, you'll need to use 
3816 \begin_inset Flex Code
3817 status collapsed
3818
3819 \begin_layout Plain Layout
3820
3821 \backslash
3822 "
3823 \end_layout
3824
3825 \end_inset
3826
3827 , to enter 
3828 \begin_inset Flex Code
3829 status collapsed
3830
3831 \begin_layout Plain Layout
3832 #
3833 \end_layout
3834
3835 \end_inset
3836
3837 , use 
3838 \begin_inset Flex Code
3839 status collapsed
3840
3841 \begin_layout Plain Layout
3842
3843 \backslash
3844 #
3845 \end_layout
3846
3847 \end_inset
3848
3849 .
3850 \end_layout
3851
3852 \begin_layout Standard
3853 If you make a keyboard description file that works for your language, please
3854  mail it to me, so I can include it in the next keymap distribution.
3855 \end_layout
3856
3857 \begin_layout Standard
3858 More keywords will be supported in keymap configuration file in future,
3859  like
3860 \end_layout
3861
3862 \begin_layout Itemize
3863 \begin_inset Flex Code
3864 status collapsed
3865
3866 \begin_layout Plain Layout
3867
3868 \backslash
3869 kinclude filename
3870 \end_layout
3871
3872 \end_inset
3873
3874
3875 \emph on
3876
3877 \begin_inset space \hfill{}
3878 \end_inset
3879
3880
3881 \begin_inset Flex Code
3882 status collapsed
3883
3884 \begin_layout Plain Layout
3885 include
3886 \end_layout
3887
3888 \end_inset
3889
3890  another file
3891 \end_layout
3892
3893 \begin_layout Itemize
3894 \begin_inset Flex Code
3895 status collapsed
3896
3897 \begin_layout Plain Layout
3898
3899 \backslash
3900 kprog program
3901 \end_layout
3902
3903 \end_inset
3904
3905
3906 \emph on
3907
3908 \begin_inset space \hfill{}
3909 \end_inset
3910
3911
3912 \begin_inset Flex Code
3913 status collapsed
3914
3915 \begin_layout Plain Layout
3916 define
3917 \end_layout
3918
3919 \end_inset
3920
3921  an external keymap translation program 
3922 \end_layout
3923
3924 \begin_layout Standard
3925 Also, it should look into 
3926 \begin_inset Flex Code
3927 status collapsed
3928
3929 \begin_layout Plain Layout
3930 lyxrc
3931 \end_layout
3932
3933 \end_inset
3934
3935  file for defaults, too (for example, a 
3936 \begin_inset Flex Code
3937 status collapsed
3938
3939 \begin_layout Plain Layout
3940
3941 \backslash
3942 kinclude
3943 \end_layout
3944
3945 \end_inset
3946
3947  option to include default keyboard).
3948 \end_layout
3949
3950 \end_inset
3951
3952
3953 \end_layout
3954
3955 \begin_layout Section
3956 International Keymap Stuff
3957 \begin_inset CommandInset label
3958 LatexCommand label
3959 name "sec:International-Keymap-Stuff"
3960
3961 \end_inset
3962
3963
3964 \end_layout
3965
3966 \begin_layout Standard
3967 \begin_inset Note Note
3968 status open
3969
3970 \begin_layout Plain Layout
3971 In doing the revisions on this document in March 2008, I did not look over
3972  this stuff, as I do not understand it.
3973  It would be good if someone else could do so.
3974  (RH)
3975 \end_layout
3976
3977 \end_inset
3978
3979
3980 \end_layout
3981
3982 \begin_layout Standard
3983 The next two sections describe the 
3984 \begin_inset Flex Code
3985 status collapsed
3986
3987 \begin_layout Plain Layout
3988
3989 \shape up
3990 .kmap
3991 \end_layout
3992
3993 \end_inset
3994
3995  and 
3996 \begin_inset Flex Code
3997 status collapsed
3998
3999 \begin_layout Plain Layout
4000
4001 \shape up
4002 .cdef
4003 \end_layout
4004
4005 \end_inset
4006
4007  file syntax in detail.
4008  These sections should help you design your own key map if the ones provided
4009  do not meet your needs.
4010 \end_layout
4011
4012 \begin_layout Subsection
4013 The .kmap File
4014 \end_layout
4015
4016 \begin_layout Standard
4017
4018 \shape up
4019 .
4020 \begin_inset Flex Code
4021 status collapsed
4022
4023 \begin_layout Plain Layout
4024 kmap
4025 \end_layout
4026
4027 \end_inset
4028
4029  file maps keystrokes to characters or strings.
4030  As the name suggests, it sets a keyboard mapping.
4031  The 
4032 \begin_inset Flex Code
4033 status collapsed
4034
4035 \begin_layout Plain Layout
4036 .kmap
4037 \end_layout
4038
4039 \end_inset
4040
4041
4042 \shape default
4043  file keywords 
4044 \shape up
4045
4046 \begin_inset Flex Code
4047 status collapsed
4048
4049 \begin_layout Plain Layout
4050
4051 \shape up
4052 kmap
4053 \end_layout
4054
4055 \end_inset
4056
4057
4058 \shape default
4059 ,
4060 \shape up
4061  
4062 \shape default
4063
4064 \begin_inset Flex Code
4065 status collapsed
4066
4067 \begin_layout Plain Layout
4068
4069 \shape up
4070 kmod
4071 \end_layout
4072
4073 \end_inset
4074
4075 ,
4076 \shape up
4077  
4078 \shape default
4079
4080 \begin_inset Flex Code
4081 status collapsed
4082
4083 \begin_layout Plain Layout
4084
4085 \shape up
4086 kxmod
4087 \end_layout
4088
4089 \end_inset
4090
4091 , and 
4092 \begin_inset Flex Code
4093 status collapsed
4094
4095 \begin_layout Plain Layout
4096
4097 \shape up
4098 kcomb
4099 \end_layout
4100
4101 \end_inset
4102
4103  are described in this section.
4104 \end_layout
4105
4106 \begin_layout Labeling
4107 \labelwidthstring 00.00.0000
4108 \begin_inset Flex Code
4109 status collapsed
4110
4111 \begin_layout Plain Layout
4112
4113 \shape up
4114 kmap
4115 \end_layout
4116
4117 \end_inset
4118
4119  Map a character to a string
4120 \end_layout
4121
4122 \begin_layout LyX-Code
4123
4124 \backslash
4125 kmap 
4126 \family roman
4127 \emph on
4128 char
4129 \family default
4130 \emph default
4131  
4132 \family roman
4133 \emph on
4134 string
4135 \end_layout
4136
4137 \begin_layout Standard
4138 This will ma
4139 \family roman
4140 p
4141 \family default
4142  
4143 \family roman
4144 \emph on
4145 char
4146 \family default
4147 \emph default
4148  
4149 \family roman
4150 to
4151 \family default
4152  
4153 \family roman
4154 \emph on
4155 string
4156 \emph default
4157 .
4158  Note that in
4159 \family default
4160  
4161 \family roman
4162 \emph on
4163 string
4164 \emph default
4165 ,
4166 \family default
4167  
4168 \family roman
4169 \shape up
4170 the double-quote (")
4171 \family default
4172 \shape default
4173  
4174 \family roman
4175 and
4176 \family default
4177  
4178 \family roman
4179 \shape up
4180 the backslash (
4181 \backslash
4182 )
4183 \family default
4184 \shape default
4185  
4186 \family roman
4187 must be escaped with a preceding backslash (
4188 \shape up
4189
4190 \backslash
4191
4192 \shape default
4193 )
4194 \family default
4195 .
4196 \end_layout
4197
4198 \begin_layout Standard
4199 An example of a 
4200 \begin_inset Flex MenuItem
4201 status collapsed
4202
4203 \begin_layout Plain Layout
4204
4205 \shape up
4206 kmap
4207 \end_layout
4208
4209 \end_inset
4210
4211  statement to cause the symbol 
4212 \begin_inset Flex MenuItem
4213 status collapsed
4214
4215 \begin_layout Plain Layout
4216
4217 \shape up
4218 /
4219 \end_layout
4220
4221 \end_inset
4222
4223  to be output for the keystroke 
4224 \begin_inset Flex MenuItem
4225 status collapsed
4226
4227 \begin_layout Plain Layout
4228
4229 \shape up
4230 &
4231 \end_layout
4232
4233 \end_inset
4234
4235  is:
4236 \end_layout
4237
4238 \begin_layout LyX-Code
4239
4240 \backslash
4241 kmap & /
4242 \end_layout
4243
4244 \begin_layout Labeling
4245 \labelwidthstring 00.00.0000
4246 \begin_inset Flex Code
4247 status collapsed
4248
4249 \begin_layout Plain Layout
4250
4251 \shape up
4252 kmod
4253 \end_layout
4254
4255 \end_inset
4256
4257  Specify an accent character
4258 \end_layout
4259
4260 \begin_layout LyX-Code
4261
4262 \backslash
4263 kmod 
4264 \family roman
4265 \emph on
4266 char accent allowed
4267 \end_layout
4268
4269 \begin_layout Standard
4270 This will make the cha
4271 \family roman
4272 racter
4273 \family default
4274  
4275 \family roman
4276 \emph on
4277 char
4278 \family default
4279 \emph default
4280  
4281 \family roman
4282 \shape up
4283 \emph on
4284 be an accent
4285 \family default
4286 \shape default
4287 \emph default
4288  
4289 \family roman
4290 \shape up
4291 on the
4292 \family default
4293 \shape default
4294  
4295 \family roman
4296 \shape up
4297 \emph on
4298 allowed
4299 \family default
4300 \shape default
4301 \emph default
4302  
4303 \family roman
4304 \shape up
4305 cha
4306 \family default
4307 racter(s).
4308  This is the dead key
4309 \begin_inset Foot
4310 status collapsed
4311
4312 \begin_layout Plain Layout
4313 The term 
4314 \family roman
4315 \emph on
4316 dead key
4317 \family default
4318 \emph default
4319  refers to a key that does not produce a character by itself, but when followed
4320  with another key, produces the desired accent character.
4321  For example, a German characte
4322 \family roman
4323 r with an umlaut like
4324 \family default
4325  
4326 \family roman
4327 \emph on
4328 ä
4329 \family default
4330 \emph default
4331  
4332 \family roman
4333 can be produced in this manner.
4334 \end_layout
4335
4336 \end_inset
4337
4338  mechanism.
4339  
4340 \end_layout
4341
4342 \begin_layout Standard
4343 If you 
4344 \family roman
4345 hit
4346 \family default
4347  
4348 \family roman
4349 \emph on
4350 char
4351 \family default
4352 \emph default
4353  
4354 \family roman
4355 and then another key not in
4356 \family default
4357  
4358 \family roman
4359 \emph on
4360 allowed
4361 \emph default
4362 , you will get a
4363 \family default
4364  
4365 \family roman
4366 \emph on
4367 char
4368 \family default
4369 \emph default
4370  
4371 \family roman
4372 followed by the other, not allowed key, as output.
4373
4374 \family default
4375  Note that a 
4376 \begin_inset Flex MenuItem
4377 status collapsed
4378
4379 \begin_layout Plain Layout
4380
4381 \shape up
4382 Backspace
4383 \end_layout
4384
4385 \end_inset
4386
4387  cancels a dead key, so if 
4388 \family roman
4389 you hit
4390 \family default
4391  
4392 \family roman
4393 \emph on
4394 char
4395 \family default
4396 \emph default
4397  
4398 \begin_inset Flex MenuItem
4399 status collapsed
4400
4401 \begin_layout Plain Layout
4402
4403 \shape up
4404 \emph on
4405 Backspace
4406 \end_layout
4407
4408 \end_inset
4409
4410 , the cursor will not go one position backwards but will instead cancel
4411  the effect t
4412 \family roman
4413 hat
4414 \family default
4415  
4416 \family roman
4417 \shape up
4418 \emph on
4419 char
4420 \family default
4421 \shape default
4422 \emph default
4423  
4424 \family roman
4425 \shape up
4426 might have had on the next keystroke.
4427  
4428 \end_layout
4429
4430 \begin_layout Standard
4431 The following example specifies that the character ' is to be an acute accent,
4432  allowed on the characters a, e, i, o, u, A, E, I, O, and U:
4433 \end_layout
4434
4435 \begin_layout LyX-Code
4436
4437 \backslash
4438 kmod ' acute aeiouAEIOU
4439 \end_layout
4440
4441 \begin_layout Labeling
4442 \labelwidthstring 00.00.0000
4443 \begin_inset Flex Code
4444 status collapsed
4445
4446 \begin_layout Plain Layout
4447 kxmod
4448 \end_layout
4449
4450 \end_inset
4451
4452  Specify an exception to the accent character
4453 \end_layout
4454
4455 \begin_layout LyX-Code
4456
4457 \backslash
4458 kxmod  
4459 \family roman
4460 \emph on
4461 accent char result
4462 \end_layout
4463
4464 \begin_layout Standard
4465 This defines an exce
4466 \family roman
4467 ption for
4468 \family default
4469  
4470 \family roman
4471 \emph on
4472 accent
4473 \family default
4474 \emph default
4475  
4476 \family roman
4477 on
4478 \family default
4479  
4480 \family roman
4481 \emph on
4482 char
4483 \emph default
4484 .
4485  T
4486 \shape up
4487 he
4488 \family default
4489 \shape default
4490  
4491 \family roman
4492 \shape up
4493 \emph on
4494 accent
4495 \family default
4496 \shape default
4497 \emph default
4498  
4499 \family roman
4500 \shape up
4501 must
4502 \family default
4503 \shape default
4504  
4505 \shape up
4506 have been assigned a keystroke with a previous
4507 \shape default
4508  
4509 \begin_inset Flex Code
4510 status collapsed
4511
4512 \begin_layout Plain Layout
4513
4514 \shape up
4515
4516 \backslash
4517 kmo
4518 \shape default
4519 d
4520 \end_layout
4521
4522 \end_inset
4523
4524  declar
4525 \family roman
4526 ation and
4527 \family default
4528  
4529 \family roman
4530 \emph on
4531 char
4532 \family default
4533 \emph default
4534  
4535 \family roman
4536 must not belong in the
4537 \family default
4538  
4539 \family roman
4540 \emph on
4541 allowed
4542 \family default
4543 \emph default
4544  
4545 \family roman
4546 set of
4547 \family default
4548  
4549 \family roman
4550 \emph on
4551 accent
4552 \emph default
4553 .
4554  When
4555 \family default
4556  
4557 \family roman
4558 \shape up
4559 you enter the
4560 \family default
4561 \shape default
4562  
4563 \family roman
4564 \shape up
4565 \emph on
4566 accent char
4567 \family default
4568 \shape default
4569 \emph default
4570  
4571 \family roman
4572 \shape up
4573 sequence,
4574 \family default
4575 \shape default
4576  
4577 \family roman
4578 \shape up
4579 \emph on
4580 result
4581 \emph default
4582  is produced.
4583  If such a declaration does not exist in
4584 \family default
4585 \shape default
4586  
4587 \shape up
4588 the
4589 \shape default
4590  
4591 \begin_inset Flex Code
4592 status collapsed
4593
4594 \begin_layout Plain Layout
4595
4596 \shape up
4597 .kmap
4598 \end_layout
4599
4600 \end_inset
4601
4602  file and yo
4603 \family roman
4604 u enter
4605 \family default
4606  
4607 \family roman
4608 \emph on
4609 accent char
4610 \emph default
4611 , you get
4612 \family default
4613  
4614 \family roman
4615 \emph on
4616 accent_key char
4617 \emph default
4618  where
4619 \family default
4620  
4621 \family roman
4622 \emph on
4623 accent_key
4624 \emph default
4625  is the first arg
4626 \family default
4627 ument of the 
4628 \begin_inset Flex Code
4629 status collapsed
4630
4631 \begin_layout Plain Layout
4632
4633 \shape up
4634
4635 \backslash
4636 kmod
4637 \end_layout
4638
4639 \end_inset
4640
4641  declaration.
4642  
4643 \end_layout
4644
4645 \begin_layout Standard
4646 The following command produces causes äi to be produced when you enter acute-i
4647  ('i):
4648 \end_layout
4649
4650 \begin_layout LyX-Code
4651
4652 \backslash
4653 kxmod acute i "
4654 \backslash
4655
4656 \backslash
4657 '{
4658 \backslash
4659
4660 \backslash
4661 i}"
4662 \end_layout
4663
4664 \begin_layout Labeling
4665 \labelwidthstring 00.00.0000
4666 \begin_inset Flex Code
4667 status collapsed
4668
4669 \begin_layout Plain Layout
4670 kcomb
4671 \end_layout
4672
4673 \end_inset
4674
4675  Combine two accent characters
4676 \end_layout
4677
4678 \begin_layout LyX-Code
4679
4680 \backslash
4681 kcomb 
4682 \family roman
4683 \emph on
4684 accent1 accent2 allowed
4685 \end_layout
4686
4687 \begin_layout Standard
4688 This one is getting pretty esoteric.
4689  It allows you to combine the effect 
4690 \family roman
4691 of
4692 \family default
4693  
4694 \family roman
4695 \emph on
4696 accent1
4697 \family default
4698 \emph default
4699  
4700 \family roman
4701 and
4702 \family default
4703  
4704 \family roman
4705 \emph on
4706 accent2
4707 \family default
4708 \emph default
4709  
4710 \family roman
4711 (in that order!) on
4712 \family default
4713  
4714 \family roman
4715 \emph on
4716 allowed
4717 \family default
4718 \emph default
4719  
4720 \family roman
4721 chars.
4722  The keystrokes for
4723 \family default
4724  
4725 \family roman
4726 \emph on
4727 accent1
4728 \family default
4729 \emph default
4730  
4731 \family roman
4732 and
4733 \family default
4734  
4735 \family roman
4736 \emph on
4737 accent2
4738 \family default
4739 \emph default
4740  
4741 \family roman
4742 must have be
4743 \family default
4744 en set with a 
4745 \begin_inset Flex Code
4746 status collapsed
4747
4748 \begin_layout Plain Layout
4749
4750 \shape up
4751
4752 \backslash
4753 kmod
4754 \end_layout
4755
4756 \end_inset
4757
4758  command at 
4759 \family roman
4760 a
4761 \family default
4762  
4763 \family roman
4764 \emph on
4765 previous
4766 \family default
4767 \emph default
4768  
4769 \family roman
4770 point in the
4771 \family default
4772  file.
4773  
4774 \end_layout
4775
4776 \begin_layout Standard
4777 Consider this example from the 
4778 \begin_inset Flex Code
4779 status collapsed
4780
4781 \begin_layout Plain Layout
4782
4783 \shape up
4784 greek.kmap
4785 \end_layout
4786
4787 \end_inset
4788
4789  file:
4790 \end_layout
4791
4792 \begin_layout LyX-Code
4793
4794 \backslash
4795 kmod ; acute aeioyvhAEIOYVH 
4796 \backslash
4797 kmod : umlaut iyIY 
4798 \backslash
4799 kcomb acute umlaut iyIY
4800 \end_layout
4801
4802 \begin_layout Standard
4803 This allows you to press 
4804 \begin_inset Flex MenuItem
4805 status collapsed
4806
4807 \begin_layout Plain Layout
4808
4809 \shape up
4810 ;:i
4811 \end_layout
4812
4813 \end_inset
4814
4815  and get the effect of 
4816 \begin_inset Flex Code
4817 status collapsed
4818
4819 \begin_layout Plain Layout
4820
4821 \shape up
4822
4823 \backslash
4824 '{
4825 \backslash
4826 "{i}}
4827 \end_layout
4828
4829 \end_inset
4830
4831 .
4832  
4833 \family roman
4834 \shape up
4835 A backspace
4836 \family default
4837 \shape default
4838  in this case cancels the last dead key, so if you press 
4839 \begin_inset Flex MenuItem
4840 status collapsed
4841
4842 \begin_layout Plain Layout
4843
4844 \shape up
4845 ;: Backspace i
4846 \end_layout
4847
4848 \end_inset
4849
4850  you get 
4851 \begin_inset Flex Code
4852 status collapsed
4853
4854 \begin_layout Plain Layout
4855
4856 \shape up
4857
4858 \backslash
4859 '{i}
4860 \end_layout
4861
4862 \end_inset
4863
4864 .
4865 \end_layout
4866
4867 \begin_layout Subsection
4868 The .cdef File
4869 \end_layout
4870
4871 \begin_layout Standard
4872 After the 
4873 \begin_inset Flex Code
4874 status collapsed
4875
4876 \begin_layout Plain Layout
4877
4878 \shape up
4879 .kmap
4880 \end_layout
4881
4882 \end_inset
4883
4884  mapping is performed, a 
4885 \begin_inset Flex Code
4886 status collapsed
4887
4888 \begin_layout Plain Layout
4889
4890 \shape up
4891 .cde
4892 \shape default
4893 f
4894 \end_layout
4895
4896 \end_inset
4897
4898  file maps the strings that the symbols generate to characters in the current
4899  font.
4900  The LyX distribution currently includes at least the 
4901 \begin_inset Flex Code
4902 status collapsed
4903
4904 \begin_layout Plain Layout
4905
4906 \shape up
4907 iso8859-1.cdef
4908 \end_layout
4909
4910 \end_inset
4911
4912  and 
4913 \begin_inset Flex Code
4914 status collapsed
4915
4916 \begin_layout Plain Layout
4917
4918 \shape up
4919 iso8859-2.cdef
4920 \end_layout
4921
4922 \end_inset
4923
4924  files.
4925 \end_layout
4926
4927 \begin_layout Standard
4928 In general the 
4929 \begin_inset Flex Code
4930 status collapsed
4931
4932 \begin_layout Plain Layout
4933
4934 \shape up
4935 .cdef
4936 \end_layout
4937
4938 \end_inset
4939
4940  file is a sequence of declarations of the form
4941 \end_layout
4942
4943 \begin_layout LyX-Code
4944
4945 \family roman
4946 \emph on
4947 char_index_in_set
4948 \family default
4949 \emph default
4950  
4951 \family roman
4952 \emph on
4953  string
4954 \end_layout
4955
4956 \begin_layout Standard
4957 For example, in order to map 
4958 \begin_inset Flex MenuItem
4959 status collapsed
4960
4961 \begin_layout Plain Layout
4962
4963 \shape up
4964
4965 \backslash
4966 '{e}
4967 \end_layout
4968
4969 \end_inset
4970
4971  to the corresponding character in the iso-8859-1 set (233), the following
4972  declaration is used
4973 \end_layout
4974
4975 \begin_layout LyX-Code
4976 233 "
4977 \backslash
4978
4979 \backslash
4980 '{e}"
4981 \end_layout
4982
4983 \begin_layout Standard
4984 with 
4985 \begin_inset Flex Code
4986 status collapsed
4987
4988 \begin_layout Plain Layout
4989
4990 \backslash
4991
4992 \end_layout
4993
4994 \end_inset
4995
4996  and 
4997 \begin_inset Flex Code
4998 status collapsed
4999
5000 \begin_layout Plain Layout
5001 "
5002 \end_layout
5003
5004 \end_inset
5005
5006  being escap
5007 \family roman
5008 ed in
5009 \family default
5010  
5011 \family roman
5012 \emph on
5013 string
5014 \emph default
5015 .
5016  Note that
5017 \family default
5018  the same character can apply to more than one string.
5019  In the 
5020 \begin_inset Flex Code
5021 status collapsed
5022
5023 \begin_layout Plain Layout
5024 i
5025 \shape up
5026 so-8859-7.cdef
5027 \end_layout
5028
5029 \end_inset
5030
5031  file you have
5032 \end_layout
5033
5034 \begin_layout LyX-Code
5035 192 "
5036 \backslash
5037
5038 \backslash
5039 '{
5040 \backslash
5041
5042 \backslash
5043
5044 \backslash
5045 "{i}}"
5046 \begin_inset Newline newline
5047 \end_inset
5048
5049 192 "
5050 \backslash
5051
5052 \backslash
5053
5054 \backslash
5055 "{
5056 \backslash
5057
5058 \backslash
5059 '{i}}"
5060 \end_layout
5061
5062 \begin_layout Standard
5063 If LyX cannot find a mapping for the string produced by the keystroke or
5064  a deadkey sequence, it will check if it looks like an accented char and
5065  try to draw an accent over the character on screen.
5066 \end_layout
5067
5068 \begin_layout Subsection
5069 Dead Keys
5070 \end_layout
5071
5072 \begin_layout Standard
5073 There is a second way to add support for international characters through
5074  so-called dead-keys.
5075  A dead-key works in combination with a letter to produce an accented character.
5076  Here, we'll explain how to create a really simple dead-key to illustrate
5077  how they work.
5078 \end_layout
5079
5080 \begin_layout Standard
5081 Suppose you happen to need the circumflex character, 
5082 \begin_inset Quotes eld
5083 \end_inset
5084
5085  ̂
5086 \begin_inset Quotes erd
5087 \end_inset
5088
5089 .
5090  You could bind the 
5091 \begin_inset Flex MenuItem
5092 status collapsed
5093
5094 \begin_layout Plain Layout
5095 ^
5096 \end_layout
5097
5098 \end_inset
5099
5100 -key [a.k.a.
5101 \begin_inset space ~
5102 \end_inset
5103
5104
5105 \begin_inset Flex MenuItem
5106 status collapsed
5107
5108 \begin_layout Plain Layout
5109 Shift-6
5110 \end_layout
5111
5112 \end_inset
5113
5114 ] to the LyX command 
5115 \begin_inset Flex Code
5116 status collapsed
5117
5118 \begin_layout Plain Layout
5119 accent-circumflex
5120 \end_layout
5121
5122 \end_inset
5123
5124  in your 
5125 \begin_inset Flex Code
5126 status collapsed
5127
5128 \begin_layout Plain Layout
5129 lyxrc
5130 \end_layout
5131
5132 \end_inset
5133
5134  file.
5135  Now, whenever you type the 
5136 \begin_inset Flex MenuItem
5137 status collapsed
5138
5139 \begin_layout Plain Layout
5140 ^
5141 \end_layout
5142
5143 \end_inset
5144
5145 -key followed by a letter, that letter will have a circumflex accent on
5146  it.
5147  For example, the sequence 
5148 \begin_inset Quotes eld
5149 \end_inset
5150
5151
5152 \begin_inset Flex MenuItem
5153 status collapsed
5154
5155 \begin_layout Plain Layout
5156 ^e
5157 \end_layout
5158
5159 \end_inset
5160
5161
5162 \begin_inset Quotes erd
5163 \end_inset
5164
5165  produces the letter: 
5166 \begin_inset Quotes eld
5167 \end_inset
5168
5169 ê
5170 \begin_inset Quotes erd
5171 \end_inset
5172
5173 .
5174  If you tried to type 
5175 \begin_inset Quotes eld
5176 \end_inset
5177
5178
5179 \begin_inset Flex MenuItem
5180 status collapsed
5181
5182 \begin_layout Plain Layout
5183 ^t
5184 \end_layout
5185
5186 \end_inset
5187
5188
5189 \begin_inset Quotes erd
5190 \end_inset
5191
5192 , however, LyX will complain with a beep, since a 
5193 \begin_inset Quotes eld
5194 \end_inset
5195
5196
5197 \begin_inset Flex MenuItem
5198 status collapsed
5199
5200 \begin_layout Plain Layout
5201 t
5202 \end_layout
5203
5204 \end_inset
5205
5206
5207 \begin_inset Quotes erd
5208 \end_inset
5209
5210  never takes a circumflex accent.
5211  Hitting 
5212 \begin_inset Flex MenuItem
5213 status collapsed
5214
5215 \begin_layout Plain Layout
5216 Space
5217 \end_layout
5218
5219 \end_inset
5220
5221  after a dead-key produces the bare-accent.
5222  Please note this last point! If you bind a key to a dead-key, you'll need
5223  to rebind the character on that key to yet another key.
5224  Binding the 
5225 \begin_inset Flex MenuItem
5226 status collapsed
5227
5228 \begin_layout Plain Layout
5229 ,-key
5230 \end_layout
5231
5232 \end_inset
5233
5234  to a cedilla is a bad idea, since you'll only get cedillas instead of commas.
5235 \end_layout
5236
5237 \begin_layout Standard
5238 One common way to bind dead-keys is to use 
5239 \begin_inset Flex MenuItem
5240 status collapsed
5241
5242 \begin_layout Plain Layout
5243 Meta-
5244 \end_layout
5245
5246 \end_inset
5247
5248
5249 \begin_inset Flex MenuItem
5250 status collapsed
5251
5252 \begin_layout Plain Layout
5253 Ctrl-
5254 \end_layout
5255
5256 \end_inset
5257
5258 , and 
5259 \begin_inset Flex MenuItem
5260 status collapsed
5261
5262 \begin_layout Plain Layout
5263 Shift-
5264 \end_layout
5265
5266 \end_inset
5267
5268  in combination with an accent, like 
5269 \begin_inset Quotes eld
5270 \end_inset
5271
5272
5273 \begin_inset Flex MenuItem
5274 status collapsed
5275
5276 \begin_layout Plain Layout
5277 ~
5278 \end_layout
5279
5280 \end_inset
5281
5282
5283 \begin_inset Quotes erd
5284 \end_inset
5285
5286  or 
5287 \begin_inset Quotes eld
5288 \end_inset
5289
5290
5291 \begin_inset Flex MenuItem
5292 status collapsed
5293
5294 \begin_layout Plain Layout
5295 ,
5296 \end_layout
5297
5298 \end_inset
5299
5300
5301 \begin_inset Quotes erd
5302 \end_inset
5303
5304  or 
5305 \begin_inset Quotes eld
5306 \end_inset
5307
5308
5309 \begin_inset Flex MenuItem
5310 status collapsed
5311
5312 \begin_layout Plain Layout
5313 ^
5314 \end_layout
5315
5316 \end_inset
5317
5318
5319 \begin_inset Quotes erd
5320 \end_inset
5321
5322 .
5323  Another way involves using 
5324 \begin_inset Flex Code
5325 status collapsed
5326
5327 \begin_layout Plain Layout
5328 xmodmap
5329 \end_layout
5330
5331 \end_inset
5332
5333  and 
5334 \begin_inset Flex Code
5335 status collapsed
5336
5337 \begin_layout Plain Layout
5338 xkeycaps
5339 \end_layout
5340
5341 \end_inset
5342
5343  to set up the special 
5344 \begin_inset Flex Code
5345 status collapsed
5346
5347 \begin_layout Plain Layout
5348 Mode_Switch
5349 \end_layout
5350
5351 \end_inset
5352
5353  key.
5354  The 
5355 \begin_inset Flex Code
5356 status collapsed
5357
5358 \begin_layout Plain Layout
5359 Mode_Switch
5360 \end_layout
5361
5362 \end_inset
5363
5364  acts in some ways just like 
5365 \begin_inset Flex MenuItem
5366 status collapsed
5367
5368 \begin_layout Plain Layout
5369 Shift
5370 \end_layout
5371
5372 \end_inset
5373
5374  and permits you to bind keys to accented characters.
5375  You can also turn keys into dead-keys by binding them to something like
5376  
5377 \begin_inset Flex Code
5378 status collapsed
5379
5380 \begin_layout Plain Layout
5381 usldead_cedilla
5382 \end_layout
5383
5384 \end_inset
5385
5386  and then binding this symbolic key to the corresponding LyX command.
5387 \begin_inset Foot
5388 status collapsed
5389
5390 \begin_layout Plain Layout
5391 Note from 
5392 \noun on
5393 John Weiss
5394 \noun default
5395 : This is exactly what I do in my 
5396 \begin_inset Flex Code
5397 status collapsed
5398
5399 \begin_layout Plain Layout
5400 ~/.lyx/lyxrc
5401 \end_layout
5402
5403 \end_inset
5404
5405  and my 
5406 \begin_inset Flex Code
5407 status collapsed
5408
5409 \begin_layout Plain Layout
5410 ~/.xmodmap
5411 \end_layout
5412
5413 \end_inset
5414
5415  files.
5416  I have my 
5417 \begin_inset Flex MenuItem
5418 status collapsed
5419
5420 \begin_layout Plain Layout
5421 Scroll
5422 \begin_inset space ~
5423 \end_inset
5424
5425 Lock
5426 \end_layout
5427
5428 \end_inset
5429
5430  key set up as 
5431 \begin_inset Flex Code
5432 status collapsed
5433
5434 \begin_layout Plain Layout
5435 Mode_Shift
5436 \end_layout
5437
5438 \end_inset
5439
5440  and a bunch of these 
5441 \begin_inset Quotes eld
5442 \end_inset
5443
5444
5445 \begin_inset Flex Code
5446 status collapsed
5447
5448 \begin_layout Plain Layout
5449 usldead_*
5450 \end_layout
5451
5452 \end_inset
5453
5454
5455 \begin_inset Quotes erd
5456 \end_inset
5457
5458  symbolic keys bound such things as 
5459 \begin_inset Flex MenuItem
5460 status collapsed
5461
5462 \begin_layout Plain Layout
5463 Scroll
5464 \begin_inset space ~
5465 \end_inset
5466
5467 Lock-^
5468 \end_layout
5469
5470 \end_inset
5471
5472  and 
5473 \begin_inset Flex MenuItem
5474 status collapsed
5475
5476 \begin_layout Plain Layout
5477 Scroll
5478 \begin_inset space ~
5479 \end_inset
5480
5481 Lock-~
5482 \end_layout
5483
5484 \end_inset
5485
5486 .
5487  This is how I produce my accented characters.
5488 \end_layout
5489
5490 \end_inset
5491
5492  You can make just about anything into the 
5493 \begin_inset Flex Code
5494 status collapsed
5495
5496 \begin_layout Plain Layout
5497 Mode_Switch
5498 \end_layout
5499
5500 \end_inset
5501
5502  key: One of the 
5503 \begin_inset Flex MenuItem
5504 status collapsed
5505
5506 \begin_layout Plain Layout
5507 Ctrl-
5508 \end_layout
5509
5510 \end_inset
5511
5512  keys, a spare function key, etc.
5513  As for the LyX commands that produce accents, check the entry for 
5514 \begin_inset Flex Code
5515 status collapsed
5516
5517 \begin_layout Plain Layout
5518 accent-acute
5519 \end_layout
5520
5521 \end_inset
5522
5523  in the 
5524 \emph on
5525 Reference Manual
5526 \emph default
5527 .
5528  You'll find the complete list there.
5529 \end_layout
5530
5531 \begin_layout Subsection
5532 Saving your Language Configuration
5533 \end_layout
5534
5535 \begin_layout Standard
5536 You can edit your preferences so that your desired language environment
5537  is automatically configured when LyX starts up, via the 
5538 \begin_inset Flex MenuItem
5539 status collapsed
5540
5541 \begin_layout Plain Layout
5542 Edit\SpecialChar \menuseparator
5543 Preferences
5544 \end_layout
5545
5546 \end_inset
5547
5548  dialog.
5549 \end_layout
5550
5551 \begin_layout Chapter
5552 Installing New Document Classes, Layouts, and Templates
5553 \begin_inset CommandInset label
5554 LatexCommand label
5555 name "cha:Installing-New-Document"
5556
5557 \end_inset
5558
5559
5560 \begin_inset Argument 1
5561 status collapsed
5562
5563 \begin_layout Plain Layout
5564 Installing New Document Classes
5565 \end_layout
5566
5567 \end_inset
5568
5569
5570 \end_layout
5571
5572 \begin_layout Standard
5573 In this chapter, we describe the procedures for creating and installing
5574  new LyX layout and template files, as well as offer a refresher on correctly
5575  installing new LaTeX document classes.
5576  
5577 \end_layout
5578
5579 \begin_layout Standard
5580 First, let us a say a few words about how one ought to think about the relation
5581  between LyX and LaTeX.
5582  The thing to understand is that, in a certain sense, LyX doesn't know anything
5583  about LaTeX.
5584  Indeed, from LyX's point of view, LaTeX is just one of several 
5585 \begin_inset Quotes eld
5586 \end_inset
5587
5588 backend formats
5589 \begin_inset Quotes erd
5590 \end_inset
5591
5592  in which it is capable of producing output.
5593  Other such formats are DocBook, plaintext, and XHTML.
5594  LaTeX is, of course, a particularly important format, but very little of
5595  the information LyX has about LaTeX is actually contained in the program
5596  itself.
5597 \begin_inset Foot
5598 status collapsed
5599
5600 \begin_layout Plain Layout
5601 Some commands are sufficiently complex that they are 
5602 \begin_inset Quotes eld
5603 \end_inset
5604
5605 hardcoded
5606 \begin_inset Quotes erd
5607 \end_inset
5608
5609  into LyX.
5610  But the developers generally regard this as a Bad Thing.
5611 \end_layout
5612
5613 \end_inset
5614
5615  Rather, that information, even for the standard classes like 
5616 \begin_inset Flex Code
5617 status collapsed
5618
5619 \begin_layout Plain Layout
5620 article.cls
5621 \end_layout
5622
5623 \end_inset
5624
5625 , is contained in `layout files'.
5626  Similarly, LyX itself does not know much about DocBook or XHTML.
5627  What it knows is contained in layout files.
5628 \end_layout
5629
5630 \begin_layout Standard
5631 You can think of the layout file for a given document class as a translation
5632  manual between LyX constructs---paragraphs with their corresponding styles,
5633  certain sorts of insets, etc---and the corresponding LaTeX, DocBook, or
5634  XHTML constructs.
5635  Almost everything LyX knows about 
5636 \begin_inset Flex Code
5637 status collapsed
5638
5639 \begin_layout Plain Layout
5640 article.cls
5641 \end_layout
5642
5643 \end_inset
5644
5645 , for example, is contained in the file 
5646 \begin_inset Flex Code
5647 status collapsed
5648
5649 \begin_layout Plain Layout
5650 article.layout
5651 \end_layout
5652
5653 \end_inset
5654
5655  and in various other files it includes.
5656  For this reason, anyone intending to write layout files should plan to
5657  study the existing files.
5658  A good place to start is with 
5659 \begin_inset Flex Code
5660 status collapsed
5661
5662 \begin_layout Plain Layout
5663 stdsections.inc
5664 \end_layout
5665
5666 \end_inset
5667
5668 , which is included in 
5669 \begin_inset Flex Code
5670 status collapsed
5671
5672 \begin_layout Plain Layout
5673 article.layout
5674 \end_layout
5675
5676 \end_inset
5677
5678
5679 \begin_inset Flex Code
5680 status collapsed
5681
5682 \begin_layout Plain Layout
5683 book.layout
5684 \end_layout
5685
5686 \end_inset
5687
5688 , and many of the other layout files for document classes.
5689  This file is where sections and the like are defined: 
5690 \begin_inset Flex Code
5691 status collapsed
5692
5693 \begin_layout Plain Layout
5694 stdsections.inc
5695 \end_layout
5696
5697 \end_inset
5698
5699  tells LyX how paragraphs that are marked with the Section, Subsection,
5700  etc, styles can be translated into corresponding LaTeX, DocBook, and XHTML
5701  commands and tags.
5702  The 
5703 \begin_inset Flex Code
5704 status collapsed
5705
5706 \begin_layout Plain Layout
5707 article.layout
5708 \end_layout
5709
5710 \end_inset
5711
5712  file basically just includes several of these 
5713 \begin_inset Flex Code
5714 status collapsed
5715
5716 \begin_layout Plain Layout
5717 std*.inc
5718 \end_layout
5719
5720 \end_inset
5721
5722  files.
5723 \end_layout
5724
5725 \begin_layout Standard
5726 Defining the LyX--LaTeX correspondence is not the only thing layout files
5727  do, though.
5728  Their other job is to define how the LyX constructs themselves will appear
5729  on-screen.
5730  The fact that layout files have these two jobs is often a source of confusion,
5731  because they are completely separate.
5732  Telling LyX how to translate a certain paragraph style into LaTeX does
5733  not tell LyX how to display it; conversely, telling LyX how to display
5734  a certain paragraph style does not tell LyX how to translate it into LaTeX
5735  (let alone tell LaTeX how to display it).
5736  So, in general, when you define a new LyX construct, you must always do
5737  two quite separate things: (i)
5738 \begin_inset space ~
5739 \end_inset
5740
5741 tell LyX how to translate it into LaTeX and (ii)
5742 \begin_inset space ~
5743 \end_inset
5744
5745 tell LyX how to display it.
5746 \end_layout
5747
5748 \begin_layout Standard
5749 Much the same is true, of course, as regards LyX's other backend formats,
5750  though XHTML is in some ways different, because in that case LyX 
5751 \emph on
5752 is
5753 \emph default
5754  able, to some extent, to use information about how it should display a
5755  paragraph on the screen to output information (in the form of CSS) about
5756  how the paragraph should be displayed in a browser.
5757  Even in this case, however, the distinction between what LyX does internally
5758  and how things are rendered externally remains in force, and the two can
5759  be controlled separately.
5760  See 
5761 \begin_inset CommandInset ref
5762 LatexCommand ref
5763 reference "sec:Tags-for-XHTML"
5764
5765 \end_inset
5766
5767  for the details.
5768 \end_layout
5769
5770 \begin_layout Section
5771 Installing new LaTeX files
5772 \end_layout
5773
5774 \begin_layout Standard
5775 Some installations may not include a LaTeX package or class file that you
5776  would like to use within LyX.
5777  For example, you might need FoilTeX, a package for preparing slides for
5778  overhead projectors.
5779  Modern LaTeX distributions like TeXLive (2008 or newer) or MiKTeX provide
5780  a user interface for installing such packages.
5781  For example, with MiKTeX, you start the program 
5782 \begin_inset Quotes eld
5783 \end_inset
5784
5785 Package
5786 \begin_inset space ~
5787 \end_inset
5788
5789 Manager
5790 \begin_inset Quotes erd
5791 \end_inset
5792
5793  to get a list of available packages.
5794  To install one of them, right click on it or use the corresponding toolbar
5795  button.
5796 \end_layout
5797
5798 \begin_layout Standard
5799 If your LaTeX distribution does not provide such a `package manager', or
5800  if the package is not available from your distribution, then follow these
5801  steps to install it manually:
5802 \end_layout
5803
5804 \begin_layout Enumerate
5805 Get the package from 
5806 \begin_inset CommandInset href
5807 LatexCommand href
5808 name "CTAN"
5809 target "http://www.ctan.org/"
5810
5811 \end_inset
5812
5813  or wherever.
5814 \end_layout
5815
5816 \begin_layout Enumerate
5817 If the package contains a file with the ending 
5818 \begin_inset Quotes eld
5819 \end_inset
5820
5821
5822 \begin_inset Flex Code
5823 status collapsed
5824
5825 \begin_layout Plain Layout
5826 .ins
5827 \end_layout
5828
5829 \end_inset
5830
5831
5832 \begin_inset Quotes erd
5833 \end_inset
5834
5835  (is the case for FoilTeX) then open a console, change to the folder of
5836  this file and execute the command 
5837 \begin_inset Flex Code
5838 status collapsed
5839
5840 \begin_layout Plain Layout
5841 latex foiltex.ins
5842 \end_layout
5843
5844 \end_inset
5845
5846 .
5847  You have now unpacked the package and have all files to install it.
5848  Most LaTeX-packages are not packed and you can skip this step.
5849 \end_layout
5850
5851 \begin_layout Enumerate
5852 Now you need to decide if the package should be available for all users
5853  or only for you.
5854 \begin_inset Separator parbreak
5855 \end_inset
5856
5857
5858 \end_layout
5859
5860 \begin_deeper
5861 \begin_layout Enumerate
5862 On *nix systems (Linux, OSX, etc.), if you want the new package to be available
5863  for all users on your system, then install it in your `local' TeX tree,
5864  otherwise install it in your own `user' TeX tree.
5865  Where these trees should be created, if they do not already exist, depends
5866  on your system.
5867  To find this out, look in the file 
5868 \begin_inset Flex Code
5869 status collapsed
5870
5871 \begin_layout Plain Layout
5872 texmf.cnf
5873 \end_layout
5874
5875 \end_inset
5876
5877 .
5878 \begin_inset Foot
5879 status collapsed
5880
5881 \begin_layout Plain Layout
5882 This is usually in the directory 
5883 \begin_inset Flex Code
5884 status collapsed
5885
5886 \begin_layout Plain Layout
5887 $TEXMF/web2c
5888 \end_layout
5889
5890 \end_inset
5891
5892 , though you can execute the command 
5893 \begin_inset Flex Code
5894 status collapsed
5895
5896 \begin_layout Plain Layout
5897 kpsewhich texmf.cnf
5898 \end_layout
5899
5900 \end_inset
5901
5902  to locate it.
5903 \end_layout
5904
5905 \end_inset
5906
5907  The location of the `local' TeX tree is defined by the 
5908 \begin_inset Flex Code
5909 status collapsed
5910
5911 \begin_layout Plain Layout
5912 TEXMFLOCAL
5913 \end_layout
5914
5915 \end_inset
5916
5917  variable; this is usually somewhere like 
5918 \begin_inset Flex Code
5919 status collapsed
5920
5921 \begin_layout Plain Layout
5922 /usr/local/share/texmf
5923 \end_layout
5924
5925 \end_inset
5926
5927 .
5928  The location of the `user' TeX tree is defined by 
5929 \begin_inset Flex Code
5930 status collapsed
5931
5932 \begin_layout Plain Layout
5933 TEXMFHOME
5934 \end_layout
5935
5936 \end_inset
5937
5938  and is commonly 
5939 \begin_inset Flex Code
5940 status collapsed
5941
5942 \begin_layout Plain Layout
5943 $HOME/texmf
5944 \end_layout
5945
5946 \end_inset
5947
5948 .
5949  (If these variables are not predefined, you have to define them.) You'll
5950  probably need root permissions to create or modify the `local' tree, but
5951  not for your `user' tree.
5952 \begin_inset Newline newline
5953 \end_inset
5954
5955 In general, it is recommended to install in the user tree because your user
5956  will not be modified or even overwritten when you upgrade your system.
5957  It will typically also be backed up together with everything else when
5958  you backup your home directory (which, of course, you do on a regular basis).
5959 \end_layout
5960
5961 \begin_layout Enumerate
5962 On Windows, if you want the new package to be available for all users on
5963  your system, change to the folder where LaTeX is installed and then change
5964  to the subfolder 
5965 \begin_inset Flex Code
5966 status collapsed
5967
5968 \begin_layout Plain Layout
5969 ~
5970 \backslash
5971 tex
5972 \backslash
5973 latex
5974 \end_layout
5975
5976 \end_inset
5977
5978 .
5979  (For MiKTeX, this would be by default the folder 
5980 \begin_inset Flex Code
5981 status collapsed
5982
5983 \begin_layout Plain Layout
5984 ~:
5985 \backslash
5986 Programs
5987 \backslash
5988 MiKTeX
5989 \backslash
5990 tex
5991 \backslash
5992 latex
5993 \end_layout
5994
5995 \end_inset
5996
5997 .)
5998 \begin_inset Foot
5999 status open
6000
6001 \begin_layout Plain Layout
6002 Note that this will be the correct path only on English installations.
6003  On a German one, it would be 
6004 \begin_inset Flex Code
6005 status collapsed
6006
6007 \begin_layout Plain Layout
6008 ~:
6009 \backslash
6010 Programme
6011 \backslash
6012 MiKTeX
6013 \backslash
6014 tex
6015 \backslash
6016 latex
6017 \end_layout
6018
6019 \end_inset
6020
6021 , and similarly for other languages.
6022 \end_layout
6023
6024 \end_inset
6025
6026  Create there a new folder 
6027 \begin_inset Flex Code
6028 status collapsed
6029
6030 \begin_layout Plain Layout
6031 foiltex
6032 \end_layout
6033
6034 \end_inset
6035
6036  and copy all files of the package into it.
6037  
6038 \begin_inset Newline newline
6039 \end_inset
6040
6041 If the package should only available for you or you don't have admin permissions
6042 , do the same, but in the local LaTeX folder.
6043  E.
6044 \begin_inset space \thinspace{}
6045 \end_inset
6046
6047 g., for MiKTeX
6048 \begin_inset space ~
6049 \end_inset
6050
6051 2.8 under Windows XP, this would be the folder:
6052 \begin_inset Newline newline
6053 \end_inset
6054
6055
6056 \family sans
6057
6058 \begin_inset Flex Code
6059 status collapsed
6060
6061 \begin_layout Plain Layout
6062 ~:
6063 \backslash
6064 Documents and Settings
6065 \backslash
6066 <username>
6067 \backslash
6068 Application Data
6069 \backslash
6070
6071 \end_layout
6072
6073 \end_inset
6074
6075
6076 \begin_inset Newline newline
6077 \end_inset
6078
6079
6080 \family default
6081
6082 \begin_inset Phantom HPhantom
6083 status open
6084
6085 \begin_layout Plain Layout
6086
6087 \family sans
6088 ~:
6089 \backslash
6090
6091 \end_layout
6092
6093 \end_inset
6094
6095
6096 \begin_inset Flex Code
6097 status collapsed
6098
6099 \begin_layout Plain Layout
6100 MiKTeX
6101 \backslash
6102 2.8
6103 \backslash
6104 tex
6105 \backslash
6106 latex
6107 \end_layout
6108
6109 \end_inset
6110
6111
6112 \begin_inset Newline newline
6113 \end_inset
6114
6115 On Vista, it would be:
6116 \begin_inset Newline newline
6117 \end_inset
6118
6119
6120 \begin_inset Flex Code
6121 status collapsed
6122
6123 \begin_layout Plain Layout
6124 ~:
6125 \backslash
6126 Users
6127 \backslash
6128 <username>
6129 \backslash
6130 AppData
6131 \backslash
6132 Roaming
6133 \backslash
6134 2.8
6135 \backslash
6136 MiKTeX
6137 \backslash
6138 tex
6139 \backslash
6140 latex
6141 \end_layout
6142
6143 \end_inset
6144
6145
6146 \end_layout
6147
6148 \end_deeper
6149 \begin_layout Enumerate
6150 Now one only need to tell LaTeX that there are new files.
6151  This depends on the used LaTeX-Distribution:
6152 \begin_inset Separator parbreak
6153 \end_inset
6154
6155
6156 \end_layout
6157
6158 \begin_deeper
6159 \begin_layout Enumerate
6160 For TeXLive execute the command 
6161 \begin_inset Flex Code
6162 status collapsed
6163
6164 \begin_layout Plain Layout
6165 texhash
6166 \end_layout
6167
6168 \end_inset
6169
6170  from a console.
6171  If you installed the package for all users, then you will probably need
6172  to have root permissions for that.
6173 \end_layout
6174
6175 \begin_layout Enumerate
6176 For MiKTeX, if you have installed the package for all users, start the program
6177  
6178 \begin_inset Quotes eld
6179 \end_inset
6180
6181 Settings
6182 \begin_inset space ~
6183 \end_inset
6184
6185 (Admin)
6186 \begin_inset Quotes erd
6187 \end_inset
6188
6189  and press the button marked 
6190 \begin_inset Quotes eld
6191 \end_inset
6192
6193 Refresh FNDB
6194 \begin_inset Quotes erd
6195 \end_inset
6196
6197 .
6198  Otherwise start the program 
6199 \begin_inset Quotes eld
6200 \end_inset
6201
6202 Settings
6203 \begin_inset Quotes erd
6204 \end_inset
6205
6206  and do the same.
6207 \end_layout
6208
6209 \end_deeper
6210 \begin_layout Enumerate
6211 Finally, you need to tell LyX that there are new packages available.
6212  So, in LyX, use the menu 
6213 \begin_inset Flex MenuItem
6214 status collapsed
6215
6216 \begin_layout Plain Layout
6217 Tools
6218 \family sans
6219 \SpecialChar \menuseparator
6220 Reconfigure
6221 \end_layout
6222
6223 \end_inset
6224
6225  and then restart LyX.
6226 \end_layout
6227
6228 \begin_layout Standard
6229 Now the package is installed.
6230  In our example, the document class 
6231 \begin_inset Flex Code
6232 status collapsed
6233
6234 \begin_layout Plain Layout
6235 Slides
6236 \begin_inset space ~
6237 \end_inset
6238
6239 (FoilTe
6240 \begin_inset ERT
6241 status collapsed
6242
6243 \begin_layout Plain Layout
6244
6245 {}
6246 \end_layout
6247
6248 \end_inset
6249
6250 x)
6251 \end_layout
6252
6253 \end_inset
6254
6255  will now be available under 
6256 \begin_inset Flex MenuItem
6257 status collapsed
6258
6259 \begin_layout Plain Layout
6260 Document\SpecialChar \menuseparator
6261 Settings\SpecialChar \menuseparator
6262 Document Class
6263 \end_layout
6264
6265 \end_inset
6266
6267 .
6268  
6269 \end_layout
6270
6271 \begin_layout Standard
6272 If you would like to use a LaTeX document class that is not even listed
6273  in the menu 
6274 \begin_inset Flex MenuItem
6275 status collapsed
6276
6277 \begin_layout Plain Layout
6278 Document\SpecialChar \menuseparator
6279 Settings\SpecialChar \menuseparator
6280 Document Class
6281 \end_layout
6282
6283 \end_inset
6284
6285 , then you need to create a `layout' file for it.
6286  That is the topic of the next section.
6287 \end_layout
6288
6289 \begin_layout Section
6290 Types of layout files
6291 \end_layout
6292
6293 \begin_layout Standard
6294 This section describes the various sorts of LyX files that contain layout
6295  information.
6296  These files describe various paragraph and character styles, determining
6297  how LyX should display them and how they should be translated into LaTeX,
6298  DocBook, XHTML, or whatever output format is being used.
6299  
6300 \end_layout
6301
6302 \begin_layout Standard
6303 We shall try to provide a thorough description of the process of writing
6304  layout files here.
6305  However, there are so many different types of documents supported even
6306  by just LaTeX that we can't hope to cover every different possibility or
6307  problem you might encounter.
6308  The LyX users' list is frequented by people with lots of experience with
6309  layout design who are willing to share what they've learned, so please
6310  feel free to ask questions there.
6311 \end_layout
6312
6313 \begin_layout Standard
6314 As you prepare to write a new layout, it is extremely helpful to look at
6315  the layouts distributed with LyX.
6316  If you write a LyX layout for a LaTeX document class that might also be
6317  used by others, or write a module that might be useful to others, then
6318  you should consider posting your layout to the 
6319 \begin_inset CommandInset href
6320 LatexCommand href
6321 name "layout section on the LyX wiki"
6322 target "http://wiki.lyx.org/Layouts/Layouts"
6323
6324 \end_inset
6325
6326  or even to the LyX developers' list, so that it might be included in LyX
6327  itself.
6328 \begin_inset Foot
6329 status collapsed
6330
6331 \begin_layout Plain Layout
6332 Note that LyX is licensed under the General Public License, so any material
6333  that is contributed to LyX must be similarly licensed.
6334 \end_layout
6335
6336 \end_inset
6337
6338
6339 \end_layout
6340
6341 \begin_layout Subsection
6342 Layout modules
6343 \begin_inset CommandInset label
6344 LatexCommand label
6345 name "sub:Layout-modules"
6346
6347 \end_inset
6348
6349
6350 \end_layout
6351
6352 \begin_layout Standard
6353 We have spoken to this point about `layout files'.
6354  But there are different sorts of files that contain layout information.
6355  Layout files, strictly so called, have the 
6356 \begin_inset Flex Code
6357 status collapsed
6358
6359 \begin_layout Plain Layout
6360 .layout
6361 \end_layout
6362
6363 \end_inset
6364
6365  extension and provide LyX with information about document classes.
6366  Since LyX 1.6 layout information can also be contained in layout 
6367 \emph on
6368 modules
6369 \emph default
6370 , which have the 
6371 \begin_inset Flex Code
6372 status collapsed
6373
6374 \begin_layout Plain Layout
6375 .module
6376 \end_layout
6377
6378 \end_inset
6379
6380  extension.
6381  Modules are to LaTeX packages much as layouts are to LaTeX classes, and
6382  some modules—such as the 
6383 \begin_inset Flex Code
6384 status collapsed
6385
6386 \begin_layout Plain Layout
6387 endnotes
6388 \end_layout
6389
6390 \end_inset
6391
6392  module—specifically provide support for one package.
6393  In a sense, layout modules are similar to included
6394 \begin_inset Foot
6395 status collapsed
6396
6397 \begin_layout Plain Layout
6398 These can have any extension, but by convention have the 
6399 \begin_inset Flex Code
6400 status collapsed
6401
6402 \begin_layout Plain Layout
6403 .inc
6404 \end_layout
6405
6406 \end_inset
6407
6408  extension.
6409 \end_layout
6410
6411 \end_inset
6412
6413  files—files like 
6414 \begin_inset Flex Code
6415 status collapsed
6416
6417 \begin_layout Plain Layout
6418 stdsections.inc
6419 \end_layout
6420
6421 \end_inset
6422
6423 —in that modules are not specific to a given document class but may be used
6424  with many different classes.
6425  The difference is that using an included file with 
6426 \begin_inset Flex Code
6427 status collapsed
6428
6429 \begin_layout Plain Layout
6430 article.cls
6431 \end_layout
6432
6433 \end_inset
6434
6435  requires editing that file.
6436  Modules, by contrast, are selected in the 
6437 \begin_inset Flex MenuItem
6438 status collapsed
6439
6440 \begin_layout Plain Layout
6441 Document\SpecialChar \menuseparator
6442 Settings
6443 \end_layout
6444
6445 \end_inset
6446
6447  dialog.
6448 \end_layout
6449
6450 \begin_layout Standard
6451 Building modules is the easiest way to get started with layout editing,
6452  since it can be as simple as adding a single new paragraph style or flex
6453  inset.
6454  But modules may, in principle, contain anything a layout file can contain.
6455 \end_layout
6456
6457 \begin_layout Standard
6458 After creating a new module and copying it to the 
6459 \begin_inset Flex Code
6460 status collapsed
6461
6462 \begin_layout Plain Layout
6463 layouts/
6464 \end_layout
6465
6466 \end_inset
6467
6468  folder, you will need to reconfigure and then restart LyX for the module
6469  to appear in the menu.
6470  However, changes you make to the module will be seen immediately, if you
6471  open 
6472 \begin_inset Flex MenuItem
6473 status collapsed
6474
6475 \begin_layout Plain Layout
6476 Document\SpecialChar \menuseparator
6477 Settings
6478 \end_layout
6479
6480 \end_inset
6481
6482 , highlight something, and then hit 
6483 \begin_inset Quotes eld
6484 \end_inset
6485
6486 OK
6487 \begin_inset Quotes erd
6488 \end_inset
6489
6490 .
6491  
6492 \emph on
6493 It is strongly recommended that you save your work before doing this
6494 \emph default
6495 .
6496  In fact, 
6497 \emph on
6498 it is strongly recommended that you not attempt to edit modules while simultaneo
6499 usly working on actual documents
6500 \emph default
6501 .
6502  Though of course the developers strive to keep LyX stable in such situations,
6503  syntax errors and the like in your module file could cause strange behavior.
6504 \end_layout
6505
6506 \begin_layout Subsubsection
6507 Local Layout
6508 \end_layout
6509
6510 \begin_layout Standard
6511 Modules are to LyX as packages are to LaTeX.
6512  Sometimes, however, you find yourself wanting a specific inset or character
6513  style just for one document and writing a module that will also be available
6514  to other documents makes little sense.
6515  What you need is LyX's 
6516 \begin_inset Quotes eld
6517 \end_inset
6518
6519 Local Layout
6520 \begin_inset Quotes erd
6521 \end_inset
6522
6523 .
6524 \end_layout
6525
6526 \begin_layout Standard
6527 You will find it under 
6528 \family sans
6529 Document\SpecialChar \menuseparator
6530 Settings\SpecialChar \menuseparator
6531 Local Layout
6532 \family default
6533 .
6534  The large text box allows you to enter anything that you might enter in
6535  a layout file or module.
6536  You can think of a document's local layout, in fact, as a module that belongs
6537  just to it.
6538  So, in particular, you must enter a 
6539 \begin_inset Flex Code
6540 status collapsed
6541
6542 \begin_layout Plain Layout
6543 Format
6544 \end_layout
6545
6546 \end_inset
6547
6548  tag.
6549  Any format is acceptable, but one would normally use the format current
6550  at the time.
6551  (In LyX 2.1, the current layout format is 48.) You should be aware that local
6552  layout is not supported by versions of LyX prior to 1.6, so you should not
6553  use it if you want to be able to export your document to LyX 1.5 or earlier
6554  (without, that is, losing the local layout information).
6555  If you wish to be able to export to 1.6---local layout is supported in 1.6,
6556  though there is no UI for it---then you should use format 11 and, of course,
6557  use only layout constructs that were available in LyX 1.6.
6558 \end_layout
6559
6560 \begin_layout Standard
6561 When you have entered something in the 
6562 \begin_inset Flex Code
6563 status collapsed
6564
6565 \begin_layout Plain Layout
6566 Local Layout
6567 \end_layout
6568
6569 \end_inset
6570
6571  pane, LyX will enable the 
6572 \begin_inset Quotes eld
6573 \end_inset
6574
6575 Validate
6576 \begin_inset Quotes erd
6577 \end_inset
6578
6579  button at the bottom.
6580  Clicking this button will cause LyX to determine whether what you have
6581  entered is valid layout information for the chosen format.
6582  LyX will report the result but, unfortunately, will not tell you what errors
6583  there might have been.
6584  These will be written to the terminal, however, if LyX is started from
6585  a terminal.
6586  You will not be permitted to save your local layout until you have entered
6587  something valid.
6588 \end_layout
6589
6590 \begin_layout Standard
6591 The warnings at the end of the previous section apply here, too.
6592  Do not play with local layout while you are actually working, especially
6593  if you have not saved your document.
6594  That said, using local layout with a test document can be a very convenient
6595  way to try out layout ideas, or even to start developing a module.
6596 \end_layout
6597
6598 \begin_layout Subsection
6599 Layout for 
6600 \begin_inset Flex MenuItem
6601 status collapsed
6602
6603 \begin_layout Plain Layout
6604 .sty
6605 \end_layout
6606
6607 \end_inset
6608
6609  files
6610 \end_layout
6611
6612 \begin_layout Standard
6613 There are two situations you are likely to encounter when wanting to support
6614  a new LaTeX document class, involving style (
6615 \begin_inset Flex Code
6616 status collapsed
6617
6618 \begin_layout Plain Layout
6619 .sty
6620 \end_layout
6621
6622 \end_inset
6623
6624 ) files and LaTeX2e class (
6625 \begin_inset Flex Code
6626 status collapsed
6627
6628 \begin_layout Plain Layout
6629 .cls
6630 \end_layout
6631
6632 \end_inset
6633
6634 ) .
6635  Supporting a style file is usually fairly easy.
6636  Supporting a new class file is a bit harder.
6637  We'll discuss the former in this section and the latter in the next.
6638  Similar remarks apply, of course, if you want to support a new DocBook
6639  DTD.
6640 \end_layout
6641
6642 \begin_layout Standard
6643 The easier case is the one in which your new document class is provided
6644  as a style file that is to be used in conjunction with an already supported
6645  document class.
6646  For the sake of the example, we'll assume that the style file is called
6647  
6648 \begin_inset Flex MenuItem
6649 status collapsed
6650
6651 \begin_layout Plain Layout
6652 myclass.sty
6653 \end_layout
6654
6655 \end_inset
6656
6657  and that it is meant to be used with 
6658 \begin_inset Flex MenuItem
6659 status collapsed
6660
6661 \begin_layout Plain Layout
6662 report.cls
6663 \end_layout
6664
6665 \end_inset
6666
6667 , which is a standard class.
6668  
6669 \end_layout
6670
6671 \begin_layout Standard
6672 Start by copying the existing class's layout file into your local directory:
6673 \begin_inset Foot
6674 status collapsed
6675
6676 \begin_layout Plain Layout
6677 Of course, which directory is your local directory will vary by platform,
6678  and LyX allows you to specify your local directory on startup, too, using
6679  the 
6680 \begin_inset Flex Code
6681 status collapsed
6682
6683 \begin_layout Plain Layout
6684 -userdir
6685 \end_layout
6686
6687 \end_inset
6688
6689  option.
6690 \end_layout
6691
6692 \end_inset
6693
6694
6695 \end_layout
6696
6697 \begin_layout LyX-Code
6698 cp report.layout ~/.lyx/layouts/myclass.layout
6699 \end_layout
6700
6701 \begin_layout Standard
6702 Then edit 
6703 \begin_inset Flex Code
6704 status collapsed
6705
6706 \begin_layout Plain Layout
6707 myclass.layout
6708 \end_layout
6709
6710 \end_inset
6711
6712  and change the line: 
6713 \end_layout
6714
6715 \begin_layout LyX-Code
6716
6717 \backslash
6718 DeclareLaTeXClass{report}
6719 \end_layout
6720
6721 \begin_layout Standard
6722 to read
6723 \end_layout
6724
6725 \begin_layout LyX-Code
6726
6727 \backslash
6728 DeclareLaTeXClass[report, myclass.sty]{report (myclass)}
6729 \end_layout
6730
6731 \begin_layout Standard
6732 Then add:
6733 \end_layout
6734
6735 \begin_layout LyX-Code
6736 Preamble 
6737 \begin_inset Newline newline
6738 \end_inset
6739
6740     
6741 \backslash
6742 usepackage{myclass}
6743 \begin_inset Newline newline
6744 \end_inset
6745
6746 EndPreamble
6747 \end_layout
6748
6749 \begin_layout Standard
6750 near the top of the file.
6751 \end_layout
6752
6753 \begin_layout Standard
6754 Start LyX and select 
6755 \begin_inset Flex MenuItem
6756 status collapsed
6757
6758 \begin_layout Plain Layout
6759 Tools\SpecialChar \menuseparator
6760 Reconfigure
6761 \end_layout
6762
6763 \end_inset
6764
6765 .
6766  Then restart LyX and try creating a new document.
6767  You should see "
6768 \begin_inset Flex MenuItem
6769 status collapsed
6770
6771 \begin_layout Plain Layout
6772 report (myclass)
6773 \end_layout
6774
6775 \end_inset
6776
6777 " as a document class option in the 
6778 \begin_inset Flex MenuItem
6779 status collapsed
6780
6781 \begin_layout Plain Layout
6782 Document\SpecialChar \menuseparator
6783 Settings
6784 \end_layout
6785
6786 \end_inset
6787
6788  dialog.
6789  It is likely that some of the sectioning commands and such in your new
6790  class will work differently from how they worked in the base class—
6791 \begin_inset Flex Code
6792 status collapsed
6793
6794 \begin_layout Plain Layout
6795 report
6796 \end_layout
6797
6798 \end_inset
6799
6800  in this example—so you can fiddle around with the settings for the different
6801  sections if you wish.
6802  The layout information for sections is contained in 
6803 \begin_inset Flex Code
6804 status collapsed
6805
6806 \begin_layout Plain Layout
6807 stdsections.inc
6808 \end_layout
6809
6810 \end_inset
6811
6812 , but you do not need to copy and change this file.
6813  Instead, you can simply add your changes to your layout file, after the
6814  line 
6815 \begin_inset Flex Code
6816 status collapsed
6817
6818 \begin_layout Plain Layout
6819 Input stdclass.inc
6820 \end_layout
6821
6822 \end_inset
6823
6824 , which itself includes 
6825 \begin_inset Flex Code
6826 status collapsed
6827
6828 \begin_layout Plain Layout
6829 stdsections.inc
6830 \end_layout
6831
6832 \end_inset
6833
6834 .
6835  For example, you might add these lines:
6836 \end_layout
6837
6838 \begin_layout LyX-Code
6839 Style Chapter
6840 \end_layout
6841
6842 \begin_layout LyX-Code
6843     Font
6844 \end_layout
6845
6846 \begin_layout LyX-Code
6847         Family Sans
6848 \end_layout
6849
6850 \begin_layout LyX-Code
6851     EndFont
6852 \end_layout
6853
6854 \begin_layout LyX-Code
6855 End
6856 \end_layout
6857
6858 \begin_layout Standard
6859 to change the font for chapter headings to sans-serif.
6860  This will override (or, in this case, add to) the existing declaration
6861  for the Chapter style.
6862  
6863 \end_layout
6864
6865 \begin_layout Standard
6866 Your new package may also provide commands or environments not present in
6867  the base class.
6868  In this case, you will want to add these to the layout file.
6869  See 
6870 \begin_inset CommandInset ref
6871 LatexCommand ref
6872 reference "sec:TextClass"
6873
6874 \end_inset
6875
6876  for information on how to do so.
6877 \end_layout
6878
6879 \begin_layout Standard
6880 If 
6881 \begin_inset Flex MenuItem
6882 status collapsed
6883
6884 \begin_layout Plain Layout
6885 myclass.sty
6886 \end_layout
6887
6888 \end_inset
6889
6890  can be used with several different document classes, and even if it cannot,
6891  you might find it easiest just to write a module that you can load with
6892  the base class.
6893  The simplest possible such module would be:
6894 \end_layout
6895
6896 \begin_layout LyX-Code
6897 #
6898 \backslash
6899 DeclareLyXModule{My Package} 
6900 \end_layout
6901
6902 \begin_layout LyX-Code
6903 #DescriptionBegin 
6904 \end_layout
6905
6906 \begin_layout LyX-Code
6907 #Support for mypkg.sty.
6908 \end_layout
6909
6910 \begin_layout LyX-Code
6911 #DescriptionEnd
6912 \begin_inset Newline newline
6913 \end_inset
6914
6915
6916 \end_layout
6917
6918 \begin_layout LyX-Code
6919 Format 35
6920 \begin_inset Newline newline
6921 \end_inset
6922
6923
6924 \end_layout
6925
6926 \begin_layout LyX-Code
6927 Preamble
6928 \begin_inset Newline newline
6929 \end_inset
6930
6931     
6932 \backslash
6933 usepackage{mypkg}
6934 \begin_inset Newline newline
6935 \end_inset
6936
6937 EndPreamble
6938 \end_layout
6939
6940 \begin_layout Standard
6941 A more complex module might modify the behavior of some existing constructs
6942  or define some new ones.
6943  Again, see 
6944 \begin_inset CommandInset ref
6945 LatexCommand ref
6946 reference "sec:TextClass"
6947
6948 \end_inset
6949
6950  for discussion.
6951 \end_layout
6952
6953 \begin_layout Subsection
6954 Layout for 
6955 \begin_inset Flex MenuItem
6956 status collapsed
6957
6958 \begin_layout Plain Layout
6959 .cls
6960 \end_layout
6961
6962 \end_inset
6963
6964  files
6965 \end_layout
6966
6967 \begin_layout Standard
6968 There are two possibilities here.
6969  One is that the class file is itself based upon an existing document class.
6970  For example, many thesis classes are based upon 
6971 \begin_inset Flex MenuItem
6972 status collapsed
6973
6974 \begin_layout Plain Layout
6975 book.cls
6976 \end_layout
6977
6978 \end_inset
6979
6980 .
6981  To see whether yours is, look for a line like
6982 \end_layout
6983
6984 \begin_layout LyX-Code
6985
6986 \backslash
6987 LoadClass{book}
6988 \end_layout
6989
6990 \begin_layout Standard
6991 in the file.
6992  If so, then you may proceed largely as in the previous section, though
6993  the 
6994 \begin_inset Flex Code
6995 status collapsed
6996
6997 \begin_layout Plain Layout
6998 DeclareLaTeXClass
6999 \end_layout
7000
7001 \end_inset
7002
7003  line will be different.
7004  If your new class is 
7005 \begin_inset Flex Code
7006 status collapsed
7007
7008 \begin_layout Plain Layout
7009 thesis
7010 \end_layout
7011
7012 \end_inset
7013
7014  and it is based upon 
7015 \begin_inset Flex Code
7016 status collapsed
7017
7018 \begin_layout Plain Layout
7019 book
7020 \end_layout
7021
7022 \end_inset
7023
7024 , then the line should read:
7025 \begin_inset Foot
7026 status collapsed
7027
7028 \begin_layout Plain Layout
7029 And it will be easiest if you save the file to 
7030 \begin_inset Flex Code
7031 status collapsed
7032
7033 \begin_layout Plain Layout
7034 thesis.layout
7035 \end_layout
7036
7037 \end_inset
7038
7039 : LyX assumes that the document class has the same name as the layout file.
7040  
7041 \end_layout
7042
7043 \end_inset
7044
7045
7046 \end_layout
7047
7048 \begin_layout LyX-Code
7049
7050 \backslash
7051 DeclareLaTeXClass[thesis,book]{thesis}
7052 \end_layout
7053
7054 \begin_layout Standard
7055 If, on the other hand, the new class is not based upon an existing class,
7056  you will probably have to 
7057 \begin_inset Quotes eld
7058 \end_inset
7059
7060 roll your own
7061 \begin_inset Quotes erd
7062 \end_inset
7063
7064  layout.
7065  We strongly suggest copying an existing layout file which uses a similar
7066  LaTeX class and then modifying it, if you can do so.
7067  At least use an existing file as a starting point so you can find out what
7068  items you need to worry about.
7069  Again, the specifics are covered below.
7070 \end_layout
7071
7072 \begin_layout Subsection
7073 Creating templates
7074 \begin_inset CommandInset label
7075 LatexCommand label
7076 name "sub:Creating-Templates"
7077
7078 \end_inset
7079
7080
7081 \end_layout
7082
7083 \begin_layout Standard
7084 Once you have written a layout file for a new document class, you might
7085  want to consider writing a 
7086 \emph on
7087 template
7088 \emph default
7089  for it, too.
7090  A template acts as a kind of tutorial for your layout, showing how it might
7091  be used, though containing dummy content.
7092  You can of course look at the various templates included with LyX for ideas.
7093 \end_layout
7094
7095 \begin_layout Standard
7096 Templates are created just like usual documents: using LyX.
7097  The only difference is that usual documents contain all possible settings,
7098  including the font scheme and the paper size.
7099  Usually a user doesn't want a template to overwrite his preferred settings
7100  for such parameters.
7101  For that reason, the designer of a template should remove the corresponding
7102  commands like 
7103 \begin_inset Flex Code
7104 status collapsed
7105
7106 \begin_layout Plain Layout
7107
7108 \backslash
7109 font_roman
7110 \end_layout
7111
7112 \end_inset
7113
7114  or 
7115 \begin_inset Flex Code
7116 status collapsed
7117
7118 \begin_layout Plain Layout
7119
7120 \backslash
7121 papersize
7122 \end_layout
7123
7124 \end_inset
7125
7126  from the template LyX file.
7127  This can be done with any simple text-editor, for example 
7128 \begin_inset Flex Code
7129 status collapsed
7130
7131 \begin_layout Plain Layout
7132 vi
7133 \end_layout
7134
7135 \end_inset
7136
7137  or 
7138 \begin_inset Flex Code
7139 status collapsed
7140
7141 \begin_layout Plain Layout
7142 notepad
7143 \end_layout
7144
7145 \end_inset
7146
7147 .
7148 \end_layout
7149
7150 \begin_layout Standard
7151 Put the edited template files you create in 
7152 \begin_inset Flex Code
7153 status collapsed
7154
7155 \begin_layout Plain Layout
7156 UserDir/templates/
7157 \end_layout
7158
7159 \end_inset
7160
7161 , copy the ones you use from the global template directory in 
7162 \begin_inset Flex Code
7163 status collapsed
7164
7165 \begin_layout Plain Layout
7166 LyXDir/templates/
7167 \end_layout
7168
7169 \end_inset
7170
7171  to the same place, and redefine the template path in the 
7172 \begin_inset Flex MenuItem
7173 status collapsed
7174
7175 \begin_layout Plain Layout
7176 Tools\SpecialChar \menuseparator
7177 Preferences\SpecialChar \menuseparator
7178 Paths
7179 \end_layout
7180
7181 \end_inset
7182
7183  dialog.
7184 \end_layout
7185
7186 \begin_layout Standard
7187 Note, by the way, that there is a template which has a particular meaning:
7188  
7189 \begin_inset Flex Code
7190 status collapsed
7191
7192 \begin_layout Plain Layout
7193 defaults.lyx
7194 \end_layout
7195
7196 \end_inset
7197
7198 .
7199  This template is loaded every time you create a new document with 
7200 \begin_inset Flex MenuItem
7201 status collapsed
7202
7203 \begin_layout Plain Layout
7204 File\SpecialChar \menuseparator
7205 New
7206 \end_layout
7207
7208 \end_inset
7209
7210  in order to provide useful defaults.
7211  To create this template from inside LyX, all you have to do is to open
7212  a document with the correct settings, and use the 
7213 \begin_inset Flex MenuItem
7214 status collapsed
7215
7216 \begin_layout Plain Layout
7217 Save as Document Defaults
7218 \end_layout
7219
7220 \end_inset
7221
7222  button.
7223 \end_layout
7224
7225 \begin_layout Subsection
7226 Upgrading old layout files
7227 \end_layout
7228
7229 \begin_layout Standard
7230 The format of layout files changes with each LyX release, so old layout
7231  files need to be converted to the new format.
7232  If LyX reads a layout file in an older format, it automatically calls the
7233  script 
7234 \begin_inset Flex Code
7235 status collapsed
7236
7237 \begin_layout Plain Layout
7238 layout2layout.py
7239 \end_layout
7240
7241 \end_inset
7242
7243  to convert it to a temporary file in current format.
7244  The original file is left untouched.
7245  If you use the layout file often, then, you may want to convert it permanently,
7246  so that LyX does not have to do so itself every time.
7247  To do this, you can call the converter manually:
7248 \end_layout
7249
7250 \begin_layout Enumerate
7251 rename the file 
7252 \begin_inset Flex Code
7253 status collapsed
7254
7255 \begin_layout Plain Layout
7256 myclass.layout
7257 \end_layout
7258
7259 \end_inset
7260
7261  to 
7262 \begin_inset Flex Code
7263 status collapsed
7264
7265 \begin_layout Plain Layout
7266 myclass.old
7267 \end_layout
7268
7269 \end_inset
7270
7271
7272 \end_layout
7273
7274 \begin_layout Enumerate
7275 Call the command
7276 \begin_inset Newline newline
7277 \end_inset
7278
7279
7280 \begin_inset Flex Code
7281 status collapsed
7282
7283 \begin_layout Plain Layout
7284 python LyXDir/scripts/layout2layout.py myclass.old myclass.layout
7285 \end_layout
7286
7287 \end_inset
7288
7289
7290 \begin_inset Newline newline
7291 \end_inset
7292
7293 where 
7294 \begin_inset Flex Code
7295 status collapsed
7296
7297 \begin_layout Plain Layout
7298 LyXDir
7299 \end_layout
7300
7301 \end_inset
7302
7303  is the name of your LyX system directory.
7304 \end_layout
7305
7306 \begin_layout Standard
7307 Note that manual conversion does not affect included files, so these will
7308  have to be converted separately.
7309 \end_layout
7310
7311 \begin_layout Section
7312 \begin_inset CommandInset label
7313 LatexCommand label
7314 name "sec:TextClass"
7315
7316 \end_inset
7317
7318 The layout file format
7319 \end_layout
7320
7321 \begin_layout Standard
7322 The following sections describe how layout files are structured and written.
7323  Our advice is to go slowly, save and test often.
7324  It is really not that hard, except that the multitude of options can become
7325  overwhelming, especially if you try to check out too many at once.
7326  It becomes easier if you use existing layouts of LyX as examples/reference
7327  or if you modify an existing layout to your needs.
7328 \end_layout
7329
7330 \begin_layout Standard
7331 Note that all the tags used in layout files are case-insensitive.
7332  This means that 
7333 \begin_inset Flex Code
7334 status collapsed
7335
7336 \begin_layout Plain Layout
7337 Style
7338 \end_layout
7339
7340 \end_inset
7341
7342
7343 \begin_inset Flex Code
7344 status collapsed
7345
7346 \begin_layout Plain Layout
7347 style
7348 \end_layout
7349
7350 \end_inset
7351
7352  and 
7353 \begin_inset Flex Code
7354 status collapsed
7355
7356 \begin_layout Plain Layout
7357 StYlE
7358 \end_layout
7359
7360 \end_inset
7361
7362  are really the same tag.
7363  The possible arguments are printed in brackets after the tag's name.
7364  The default argument is typeset 
7365 \begin_inset Flex Code
7366 status collapsed
7367
7368 \begin_layout Plain Layout
7369
7370 \emph on
7371 emphasized
7372 \end_layout
7373
7374 \end_inset
7375
7376 .
7377  If the argument has a data type like 
7378 \begin_inset Quotes eld
7379 \end_inset
7380
7381 string
7382 \begin_inset Quotes erd
7383 \end_inset
7384
7385  or 
7386 \begin_inset Quotes eld
7387 \end_inset
7388
7389 float
7390 \begin_inset Quotes erd
7391 \end_inset
7392
7393 , the default is shown like this: 
7394 \begin_inset Flex Code
7395 status collapsed
7396
7397 \begin_layout Plain Layout
7398 float=
7399 \emph on
7400 default
7401 \end_layout
7402
7403 \end_inset
7404
7405 .
7406 \end_layout
7407
7408 \begin_layout Subsection
7409 The document class declaration and classification
7410 \end_layout
7411
7412 \begin_layout Standard
7413 Lines in a layout file which begin with 
7414 \begin_inset Flex Code
7415 status collapsed
7416
7417 \begin_layout Plain Layout
7418 #
7419 \end_layout
7420
7421 \end_inset
7422
7423  are comments.
7424  There is one exception to this rule.
7425  All 
7426 \begin_inset Flex Code
7427 status collapsed
7428
7429 \begin_layout Plain Layout
7430 *.layout
7431 \end_layout
7432
7433 \end_inset
7434
7435  files should begin with lines like:
7436 \end_layout
7437
7438 \begin_layout LyX-Code
7439
7440 \size small
7441 #% Do not delete the line below; configure depends on this 
7442 \end_layout
7443
7444 \begin_layout LyX-Code
7445
7446 \size small
7447 #  
7448 \backslash
7449 DeclareLaT
7450 \size default
7451
7452 \begin_inset ERT
7453 status collapsed
7454
7455 \begin_layout Plain Layout
7456
7457 {}
7458 \end_layout
7459
7460 \end_inset
7461
7462
7463 \size small
7464 eXClass{Article (Standard Class)}
7465 \end_layout
7466
7467 \begin_layout LyX-Code
7468
7469 \size small
7470 #  
7471 \backslash
7472 DeclareCategory{Articles}
7473 \end_layout
7474
7475 \begin_layout Standard
7476 The second and third lines are used when you (re)configure LyX.
7477  The layout file is read by the LaTeX script 
7478 \begin_inset Flex Code
7479 status collapsed
7480
7481 \begin_layout Plain Layout
7482 chkconfig.ltx
7483 \end_layout
7484
7485 \end_inset
7486
7487 , in a special mode where 
7488 \begin_inset Flex Code
7489 status collapsed
7490
7491 \begin_layout Plain Layout
7492 #
7493 \end_layout
7494
7495 \end_inset
7496
7497  is ignored.
7498  The first line is just a LaTeX comment, the second one contains the mandatory
7499  declaration of the text class and the third line contains the optional
7500  classification of the class.
7501  If these lines appear in a file named 
7502 \begin_inset Flex Code
7503 status collapsed
7504
7505 \begin_layout Plain Layout
7506 article.layout
7507 \end_layout
7508
7509 \end_inset
7510
7511 , then they define a text class of name 
7512 \begin_inset Flex Code
7513 status collapsed
7514
7515 \begin_layout Plain Layout
7516 article
7517 \end_layout
7518
7519 \end_inset
7520
7521  (the name of the layout file) which uses the LaTeX document class 
7522 \begin_inset Flex Code
7523 status collapsed
7524
7525 \begin_layout Plain Layout
7526 article.cls
7527 \end_layout
7528
7529 \end_inset
7530
7531  (the default is to use the same name as the layout).
7532  The string 
7533 \begin_inset Quotes eld
7534 \end_inset
7535
7536 Article (Standard Class)
7537 \begin_inset Quotes erd
7538 \end_inset
7539
7540  that appears above is used as a description of the text class in the 
7541 \begin_inset Flex MenuItem
7542 status collapsed
7543
7544 \begin_layout Plain Layout
7545 Document\SpecialChar \menuseparator
7546 Settings
7547 \end_layout
7548
7549 \end_inset
7550
7551  dialog.
7552  The category (
7553 \begin_inset Quotes eld
7554 \end_inset
7555
7556 Articles
7557 \begin_inset Quotes erd
7558 \end_inset
7559
7560  in the example) is also used in the 
7561 \begin_inset Flex MenuItem
7562 status collapsed
7563
7564 \begin_layout Plain Layout
7565 Document\SpecialChar \menuseparator
7566 Settings
7567 \end_layout
7568
7569 \end_inset
7570
7571  dialog: the text classes are grouped by these categories (which are usually
7572  genres, so typical categories are 
7573 \begin_inset Quotes eld
7574 \end_inset
7575
7576 Articles
7577 \begin_inset Quotes erd
7578 \end_inset
7579
7580
7581 \begin_inset Quotes eld
7582 \end_inset
7583
7584 Books
7585 \begin_inset Quotes erd
7586 \end_inset
7587
7588
7589 \begin_inset Quotes eld
7590 \end_inset
7591
7592 Reports
7593 \begin_inset Quotes erd
7594 \end_inset
7595
7596
7597 \begin_inset Quotes eld
7598 \end_inset
7599
7600 Letters
7601 \begin_inset Quotes erd
7602 \end_inset
7603
7604
7605 \begin_inset Quotes eld
7606 \end_inset
7607
7608 Presentations
7609 \begin_inset Quotes erd
7610 \end_inset
7611
7612
7613 \begin_inset Quotes eld
7614 \end_inset
7615
7616 Curricula Vitae
7617 \begin_inset Quotes erd
7618 \end_inset
7619
7620  etc.).
7621  If no category has been declared, the class will be put in the 
7622 \begin_inset Quotes eld
7623 \end_inset
7624
7625 Uncategorized
7626 \begin_inset Quotes erd
7627 \end_inset
7628
7629  group.
7630 \end_layout
7631
7632 \begin_layout Standard
7633 Let's assume that you wrote your own text class that uses the 
7634 \begin_inset Flex Code
7635 status collapsed
7636
7637 \begin_layout Plain Layout
7638 article.cls
7639 \end_layout
7640
7641 \end_inset
7642
7643  document class, but where you changed the appearance of the section headings.
7644  If you put it in a file 
7645 \begin_inset Flex Code
7646 status collapsed
7647
7648 \begin_layout Plain Layout
7649 myarticle.layout
7650 \end_layout
7651
7652 \end_inset
7653
7654 , the header of this file should be:
7655 \end_layout
7656
7657 \begin_layout LyX-Code
7658
7659 \size small
7660 #% Do not delete the line below; configure depends on this 
7661 \end_layout
7662
7663 \begin_layout LyX-Code
7664
7665 \size small
7666 #  
7667 \backslash
7668 DeclareLaT
7669 \size default
7670
7671 \begin_inset ERT
7672 status collapsed
7673
7674 \begin_layout Plain Layout
7675
7676 {}
7677 \end_layout
7678
7679 \end_inset
7680
7681
7682 \size small
7683 eXClass[article]{Article (with My Own Headings)}
7684 \end_layout
7685
7686 \begin_layout LyX-Code
7687
7688 \size small
7689 #  
7690 \backslash
7691 DeclareCategory{Articles}
7692 \end_layout
7693
7694 \begin_layout Standard
7695 This declares a text class 
7696 \begin_inset Flex Code
7697 status collapsed
7698
7699 \begin_layout Plain Layout
7700 myarticle
7701 \end_layout
7702
7703 \end_inset
7704
7705 , associated with the LaTeX document class 
7706 \begin_inset Flex Code
7707 status collapsed
7708
7709 \begin_layout Plain Layout
7710 article.cls
7711 \end_layout
7712
7713 \end_inset
7714
7715  and described as 
7716 \begin_inset Quotes eld
7717 \end_inset
7718
7719 Article (with My Own Headings)
7720 \begin_inset Quotes erd
7721 \end_inset
7722
7723 .
7724  If your text class depends on several packages, you can declare it as:
7725 \end_layout
7726
7727 \begin_layout LyX-Code
7728
7729 \size small
7730 #% Do not delete the line below; configure depends on this 
7731 \end_layout
7732
7733 \begin_layout LyX-Code
7734
7735 \size small
7736 #  
7737 \backslash
7738 DeclareLaT
7739 \size default
7740
7741 \begin_inset ERT
7742 status collapsed
7743
7744 \begin_layout Plain Layout
7745
7746 {}
7747 \end_layout
7748
7749 \end_inset
7750
7751
7752 \size small
7753 eXClass[article,foo.sty]{Article (with My Own Headings)}
7754 \end_layout
7755
7756 \begin_layout LyX-Code
7757
7758 \size small
7759 #  
7760 \backslash
7761 DeclareCategory{Articles}
7762 \end_layout
7763
7764 \begin_layout Standard
7765 This indicates that your text class uses the 
7766 \begin_inset Flex Code
7767 status collapsed
7768
7769 \begin_layout Plain Layout
7770 foo.sty
7771 \end_layout
7772
7773 \end_inset
7774
7775  package.
7776  Finally, it is also possible to declare classes for DocBook code.
7777  Typical declarations will look like:
7778 \end_layout
7779
7780 \begin_layout LyX-Code
7781
7782 \size small
7783 #% Do not delete the line below; configure depends on this 
7784 \end_layout
7785
7786 \begin_layout LyX-Code
7787
7788 \size small
7789
7790 \backslash
7791 DeclareDocBookClass[article]{SGML (DocBook Article)}
7792 \end_layout
7793
7794 \begin_layout LyX-Code
7795
7796 \size small
7797
7798 \backslash
7799 DeclareCategory{Articles (DocBook)}
7800 \end_layout
7801
7802 \begin_layout Standard
7803 Note that these declarations can also be given an optional parameter declaring
7804  the name of the document class (but not a list).
7805 \end_layout
7806
7807 \begin_layout Standard
7808 So, to be as explicit as possible, the form of the layout declaration is:
7809 \end_layout
7810
7811 \begin_layout LyX-Code
7812
7813 \size small
7814 #  
7815 \backslash
7816 DeclareLaT
7817 \size default
7818
7819 \begin_inset ERT
7820 status collapsed
7821
7822 \begin_layout Plain Layout
7823
7824 {}
7825 \end_layout
7826
7827 \end_inset
7828
7829
7830 \size small
7831 eXClass[class,package.sty]{layout description}
7832 \end_layout
7833
7834 \begin_layout LyX-Code
7835
7836 \size small
7837 #  
7838 \backslash
7839 DeclareCategory{category}
7840 \end_layout
7841
7842 \begin_layout Standard
7843 The class need only be specified if the name of the LaTeX class file and
7844  the name of the layout file are different or if there are packages to load.
7845  If the name of the class file is not specified, then LyX will simply assume
7846  that it is the same as the name of the layout file.
7847 \end_layout
7848
7849 \begin_layout Standard
7850 When the text class has been modified to your taste, all you have to do
7851  is to copy it either to 
7852 \begin_inset Flex Code
7853 status collapsed
7854
7855 \begin_layout Plain Layout
7856 LyXDir/layouts/
7857 \end_layout
7858
7859 \end_inset
7860
7861  or to 
7862 \begin_inset Flex Code
7863 status collapsed
7864
7865 \begin_layout Plain Layout
7866 UserDir/layouts
7867 \end_layout
7868
7869 \end_inset
7870
7871 , run 
7872 \begin_inset Flex MenuItem
7873 status collapsed
7874
7875 \begin_layout Plain Layout
7876 Tools\SpecialChar \menuseparator
7877 Reconfigure
7878 \end_layout
7879
7880 \end_inset
7881
7882 , exit LyX and restart.
7883  Then your new text class should be available along with the others.
7884 \end_layout
7885
7886 \begin_layout Standard
7887 Once the layout file is installed, you can edit it and see your changes
7888  without having to reconfigure or to restart LyX.
7889  
7890 \begin_inset Foot
7891 status collapsed
7892
7893 \begin_layout Plain Layout
7894 In versions of LyX prior to 1.6, this was not true.
7895  As a result, editing layout files was very time consuming, since you had
7896  constantly to restart LyX to see changes.
7897 \end_layout
7898
7899 \end_inset
7900
7901  You can force a reload of the current layout by using the LyX function
7902  
7903 \begin_inset Flex MenuItem
7904 status collapsed
7905
7906 \begin_layout Plain Layout
7907 layout-reload
7908 \end_layout
7909
7910 \end_inset
7911
7912 .
7913  There is no default binding for this function—though, of course, you can
7914  bind it to a key yourself.
7915  But you will normally use this function simply by entering it in the mini-buffe
7916 r.
7917  
7918 \end_layout
7919
7920 \begin_layout Standard
7921
7922 \emph on
7923 Warning
7924 \emph default
7925
7926 \begin_inset Flex MenuItem
7927 status collapsed
7928
7929 \begin_layout Plain Layout
7930 layout-reload
7931 \end_layout
7932
7933 \end_inset
7934
7935  is very much an `advanced feature'.
7936  It is 
7937 \emph on
7938 strongly
7939 \emph default
7940  recommended that you save your work before using this function.
7941  In fact, it is 
7942 \emph on
7943 strongly
7944 \emph default
7945  recommended that you not attempt to edit layout information while simultaneousl
7946 y working on a document that you care about.
7947  Use a test document.
7948  Syntax errors and the like in your layout file could cause peculiar behavior.
7949  In particular, such errors could cause LyX to regard the current layout
7950  as invalid and to attempt to switch to some other layout.
7951 \begin_inset Foot
7952 status collapsed
7953
7954 \begin_layout Plain Layout
7955 Really bad syntax errors may even caused LyX to exit.
7956  This is because certain sorts of errors may make LyX unable to read 
7957 \emph on
7958 any
7959 \emph default
7960  layout information.
7961  Please be careful.
7962 \end_layout
7963
7964 \end_inset
7965
7966  The LyX team strives to keep LyX stable in such situations, but safe is
7967  better than sorry.
7968 \begin_inset Foot
7969 status collapsed
7970
7971 \begin_layout Plain Layout
7972 While we're giving advice: make regular backups.
7973  And be nice to your mother.
7974 \end_layout
7975
7976 \end_inset
7977
7978
7979 \end_layout
7980
7981 \begin_layout Subsection
7982 The Module declaration
7983 \end_layout
7984
7985 \begin_layout Standard
7986 A module must begin with a line like the following:
7987 \end_layout
7988
7989 \begin_layout LyX-Code
7990 #
7991 \backslash
7992 DeclareL
7993 \begin_inset ERT
7994 status collapsed
7995
7996 \begin_layout Plain Layout
7997
7998 {}
7999 \end_layout
8000
8001 \end_inset
8002
8003 yXModule[endnotes.sty]{Endnotes} 
8004 \end_layout
8005
8006 \begin_layout Standard
8007 The mandatory argument, in curly brackets, is the name of the module, as
8008  it should appear in 
8009 \begin_inset Flex MenuItem
8010 status collapsed
8011
8012 \begin_layout Plain Layout
8013 Document\SpecialChar \menuseparator
8014 Settings\SpecialChar \menuseparator
8015 Modules
8016 \end_layout
8017
8018 \end_inset
8019
8020 .
8021  The argument in square brackets is optional: It declares any LaTeX packages
8022  on which the module depends.
8023  It is also possible to use the form 
8024 \begin_inset Flex MenuItem
8025 status collapsed
8026
8027 \begin_layout Plain Layout
8028 from->to
8029 \end_layout
8030
8031 \end_inset
8032
8033  as an optional argument, which declares that the module can only be used
8034  when there exists a conversion chain between the formats `
8035 \begin_inset Flex Code
8036 status collapsed
8037
8038 \begin_layout Plain Layout
8039 from
8040 \end_layout
8041
8042 \end_inset
8043
8044 ' and `
8045 \begin_inset Flex Code
8046 status collapsed
8047
8048 \begin_layout Plain Layout
8049 to
8050 \end_layout
8051
8052 \end_inset
8053
8054 '.
8055 \end_layout
8056
8057 \begin_layout Standard
8058 The module declaration should then be followed by lines like the following
8059 \begin_inset Foot
8060 status collapsed
8061
8062 \begin_layout Plain Layout
8063 Preferably in English if the module should be published with LyX.
8064  This description will appear in the list of messages to be translated and
8065  will be thus translated with the next interface update.
8066 \end_layout
8067
8068 \end_inset
8069
8070 :
8071 \end_layout
8072
8073 \begin_layout LyX-Code
8074 #DescriptionBegin 
8075 \end_layout
8076
8077 \begin_layout LyX-Code
8078 #Adds an endnote command, in addition to footnotes.
8079  
8080 \end_layout
8081
8082 \begin_layout LyX-Code
8083 #You will need to add  
8084 \backslash
8085 theendnotes in TeX code where you 
8086 \end_layout
8087
8088 \begin_layout LyX-Code
8089 #want the endnotes to appear.
8090  
8091 \end_layout
8092
8093 \begin_layout LyX-Code
8094 #DescriptionEnd 
8095 \end_layout
8096
8097 \begin_layout LyX-Code
8098 #Requires: somemodule | othermodule
8099 \end_layout
8100
8101 \begin_layout LyX-Code
8102 #Excludes: badmodule
8103 \end_layout
8104
8105 \begin_layout Standard
8106 The description is used in 
8107 \begin_inset Flex MenuItem
8108 status collapsed
8109
8110 \begin_layout Plain Layout
8111 Document\SpecialChar \menuseparator
8112 Settings\SpecialChar \menuseparator
8113 Modules
8114 \end_layout
8115
8116 \end_inset
8117
8118  to provide the user with information about what the module does.
8119  The 
8120 \begin_inset Flex Code
8121 status collapsed
8122
8123 \begin_layout Plain Layout
8124 Requires
8125 \end_layout
8126
8127 \end_inset
8128
8129  line is used to identify other modules with which this one must be used;
8130  the 
8131 \begin_inset Flex Code
8132 status collapsed
8133
8134 \begin_layout Plain Layout
8135 Excludes
8136 \end_layout
8137
8138 \end_inset
8139
8140  line is used to identify modules with which this one may not be used.
8141  Both are optional, and, as shown, multiple modules should be separated
8142  with the pipe symbol: |.
8143  Note that the required modules are treated disjunctively: 
8144 \emph on
8145 at least one
8146 \emph default
8147  of the required modules must be used.
8148  Similarly, 
8149 \emph on
8150 no
8151 \emph default
8152  excluded module may be used.
8153  Note that modules are identified here by their filenames without the 
8154 \begin_inset Flex Code
8155 status collapsed
8156
8157 \begin_layout Plain Layout
8158 .module
8159 \end_layout
8160
8161 \end_inset
8162
8163  extension.
8164  So 
8165 \begin_inset Flex Code
8166 status collapsed
8167
8168 \begin_layout Plain Layout
8169 somemodule
8170 \end_layout
8171
8172 \end_inset
8173
8174  is really 
8175 \begin_inset Flex Code
8176 status collapsed
8177
8178 \begin_layout Plain Layout
8179 somemodule.module
8180 \end_layout
8181
8182 \end_inset
8183
8184 .
8185 \end_layout
8186
8187 \begin_layout Subsection
8188 Format number
8189 \end_layout
8190
8191 \begin_layout Standard
8192 The first non-comment line of any layout file, included file, or module
8193  
8194 \emph on
8195 must
8196 \emph default
8197  contain the file format number:
8198 \end_layout
8199
8200 \begin_layout Description
8201 \begin_inset Flex Code
8202 status collapsed
8203
8204 \begin_layout Plain Layout
8205 Format
8206 \end_layout
8207
8208 \end_inset
8209
8210  [
8211 \begin_inset Flex Code
8212 status collapsed
8213
8214 \begin_layout Plain Layout
8215 int
8216 \end_layout
8217
8218 \end_inset
8219
8220 ] The format number of the layout file.
8221 \end_layout
8222
8223 \begin_layout Standard
8224 This tag was introduced with LyX
8225 \begin_inset space ~
8226 \end_inset
8227
8228 1.4.0.
8229  Layout files from older LyX versions do not have an explicit file format
8230  and are considered to have 
8231 \begin_inset Flex Code
8232 status collapsed
8233
8234 \begin_layout Plain Layout
8235 Format
8236 \begin_inset space ~
8237 \end_inset
8238
8239 1
8240 \end_layout
8241
8242 \end_inset
8243
8244 .
8245  The format for the present version of LyX is format 35.
8246  But each version of LyX is capable of reading earlier versions' layout
8247  files, just as they are capable of reading files produced by earlier versions
8248  of LyX.
8249  There is, however, no provision for converting to earlier formats.
8250 \end_layout
8251
8252 \begin_layout Subsection
8253 \begin_inset CommandInset label
8254 LatexCommand label
8255 name "sub:General-text-class"
8256
8257 \end_inset
8258
8259 General text class parameters
8260 \end_layout
8261
8262 \begin_layout Standard
8263 These are general parameters that govern the behavior of an entire document
8264  class.
8265  (This does 
8266 \emph on
8267 not
8268 \emph default
8269  mean that they must appear in 
8270 \begin_inset Flex Code
8271 status collapsed
8272
8273 \begin_layout Plain Layout
8274 .layout
8275 \end_layout
8276
8277 \end_inset
8278
8279  files rather than in modules.
8280  A module can contain any layout tag.)
8281 \end_layout
8282
8283 \begin_layout Description
8284 \begin_inset Flex Code
8285 status collapsed
8286
8287 \begin_layout Plain Layout
8288 AddToHTMLPreamble
8289 \end_layout
8290
8291 \end_inset
8292
8293  Adds information that will be output in the 
8294 \begin_inset Flex Code
8295 status collapsed
8296
8297 \begin_layout Plain Layout
8298 <head>
8299 \end_layout
8300
8301 \end_inset
8302
8303  block when the document is output to XHTML.
8304  Typically, this would be used to output CSS style information, but it can
8305  be used for anything that can appear in 
8306 \begin_inset Flex Code
8307 status collapsed
8308
8309 \begin_layout Plain Layout
8310 <head>
8311 \end_layout
8312
8313 \end_inset
8314
8315 .
8316  Must end with 
8317 \begin_inset Quotes eld
8318 \end_inset
8319
8320
8321 \begin_inset Flex Code
8322 status collapsed
8323
8324 \begin_layout Plain Layout
8325 EndPreamble
8326 \end_layout
8327
8328 \end_inset
8329
8330
8331 \begin_inset Quotes erd
8332 \end_inset
8333
8334 .
8335 \end_layout
8336
8337 \begin_layout Description
8338 \begin_inset Flex Code
8339 status collapsed
8340
8341 \begin_layout Plain Layout
8342 AddToPreamble
8343 \end_layout
8344
8345 \end_inset
8346
8347  Adds information to the document preamble.
8348  Must end with
8349 \begin_inset Newline newline
8350 \end_inset
8351
8352
8353 \begin_inset Quotes eld
8354 \end_inset
8355
8356
8357 \begin_inset Flex Code
8358 status collapsed
8359
8360 \begin_layout Plain Layout
8361 EndPreamble
8362 \end_layout
8363
8364 \end_inset
8365
8366
8367 \begin_inset Quotes erd
8368 \end_inset
8369
8370 .
8371 \end_layout
8372
8373 \begin_layout Description
8374 \begin_inset Flex Code
8375 status collapsed
8376
8377 \begin_layout Plain Layout
8378 CiteFormat
8379 \end_layout
8380
8381 \end_inset
8382
8383  Defines formats for use in the display of bibliographic information.
8384  See 
8385 \begin_inset CommandInset ref
8386 LatexCommand ref
8387 reference "sub:Citation-format-description"
8388
8389 \end_inset
8390
8391  for details.
8392  Must end with 
8393 \begin_inset Quotes eld
8394 \end_inset
8395
8396
8397 \begin_inset Flex Code
8398 status collapsed
8399
8400 \begin_layout Plain Layout
8401 End
8402 \end_layout
8403
8404 \end_inset
8405
8406
8407 \begin_inset Quotes erd
8408 \end_inset
8409
8410 .
8411 \end_layout
8412
8413 \begin_layout Description
8414 \begin_inset Flex Code
8415 status collapsed
8416
8417 \begin_layout Plain Layout
8418 ClassOptions
8419 \end_layout
8420
8421 \end_inset
8422
8423  Describes various global options supported by the document class.
8424  See 
8425 \begin_inset CommandInset ref
8426 LatexCommand ref
8427 reference "sub:ClassOptions"
8428
8429 \end_inset
8430
8431  for a description.
8432  Must end with 
8433 \begin_inset Quotes eld
8434 \end_inset
8435
8436
8437 \begin_inset Flex Code
8438 status collapsed
8439
8440 \begin_layout Plain Layout
8441 End
8442 \end_layout
8443
8444 \end_inset
8445
8446
8447 \begin_inset Quotes erd
8448 \end_inset
8449
8450 .
8451 \end_layout
8452
8453 \begin_layout Description
8454 \begin_inset Flex Code
8455 status collapsed
8456
8457 \begin_layout Plain Layout
8458 Columns
8459 \end_layout
8460
8461 \end_inset
8462
8463  [
8464 \begin_inset Flex Code
8465 status collapsed
8466
8467 \begin_layout Plain Layout
8468
8469 \emph on
8470 1
8471 \end_layout
8472
8473 \end_inset
8474
8475 ,
8476 \begin_inset space \thinspace{}
8477 \end_inset
8478
8479
8480 \begin_inset Flex Code
8481 status collapsed
8482
8483 \begin_layout Plain Layout
8484 2
8485 \end_layout
8486
8487 \end_inset
8488
8489 ] Whether the class should 
8490 \emph on
8491 default
8492 \emph default
8493  to having one or two columns.
8494  Can be changed in the 
8495 \begin_inset Flex MenuItem
8496 status collapsed
8497
8498 \begin_layout Plain Layout
8499 Document\SpecialChar \menuseparator
8500 Settings
8501 \end_layout
8502
8503 \end_inset
8504
8505  dialog.
8506 \end_layout
8507
8508 \begin_layout Description
8509 \begin_inset Flex Code
8510 status collapsed
8511
8512 \begin_layout Plain Layout
8513 Counter
8514 \end_layout
8515
8516 \end_inset
8517
8518  [
8519 \begin_inset Flex Code
8520 status collapsed
8521
8522 \begin_layout Plain Layout
8523 string
8524 \end_layout
8525
8526 \end_inset
8527
8528 ] This sequence defines the properties for a counter.
8529  If the counter does not yet exist, it is created; if it does exist, it
8530  is modified.
8531  Must end with 
8532 \begin_inset Quotes eld
8533 \end_inset
8534
8535
8536 \begin_inset Flex Code
8537 status collapsed
8538
8539 \begin_layout Plain Layout
8540 End
8541 \end_layout
8542
8543 \end_inset
8544
8545
8546 \begin_inset Quotes erd
8547 \end_inset
8548
8549 .
8550 \begin_inset Newline newline
8551 \end_inset
8552
8553 See 
8554 \begin_inset CommandInset ref
8555 LatexCommand ref
8556 reference "sub:Counters"
8557
8558 \end_inset
8559
8560  for details on counters.
8561 \end_layout
8562
8563 \begin_layout Description
8564 \begin_inset Flex Code
8565 status collapsed
8566
8567 \begin_layout Plain Layout
8568 DefaultFont
8569 \end_layout
8570
8571 \end_inset
8572
8573  Sets the default font used to display the document.
8574  See 
8575 \begin_inset CommandInset ref
8576 LatexCommand ref
8577 reference "sub:Font-description"
8578
8579 \end_inset
8580
8581  for how to declare fonts.
8582  Must end with 
8583 \begin_inset Quotes eld
8584 \end_inset
8585
8586
8587 \begin_inset Flex Code
8588 status collapsed
8589
8590 \begin_layout Plain Layout
8591 EndFont
8592 \end_layout
8593
8594 \end_inset
8595
8596
8597 \begin_inset Quotes erd
8598 \end_inset
8599
8600 .
8601 \end_layout
8602
8603 \begin_layout Description
8604 \begin_inset Flex Code
8605 status collapsed
8606
8607 \begin_layout Plain Layout
8608 DefaultModule
8609 \end_layout
8610
8611 \end_inset
8612
8613  [
8614 \begin_inset Flex Code
8615 status collapsed
8616
8617 \begin_layout Plain Layout
8618 <module>
8619 \end_layout
8620
8621 \end_inset
8622
8623 ] Specifies a module to be included by default with this document class.
8624  The module is specified as filename without the 
8625 \begin_inset Flex Code
8626 status collapsed
8627
8628 \begin_layout Plain Layout
8629 .module
8630 \end_layout
8631
8632 \end_inset
8633
8634  extension.
8635  The user can still remove the module, but it will be active at the outset.
8636  (This applies only when new files are created, or when this class is chosen
8637  for an existing document.)
8638 \end_layout
8639
8640 \begin_layout Description
8641 \begin_inset Flex Code
8642 status collapsed
8643
8644 \begin_layout Plain Layout
8645 DefaultStyle
8646 \end_layout
8647
8648 \end_inset
8649
8650  [
8651 \begin_inset Flex Code
8652 status collapsed
8653
8654 \begin_layout Plain Layout
8655 <style>
8656 \end_layout
8657
8658 \end_inset
8659
8660 ] This is the style that will be assigned to new paragraphs, usually 
8661 \begin_inset Flex MenuItem
8662 status collapsed
8663
8664 \begin_layout Plain Layout
8665 Standard
8666 \end_layout
8667
8668 \end_inset
8669
8670 .
8671  This will default to the first defined style if not given, but you are
8672  encouraged to use this directive.
8673 \end_layout
8674
8675 \begin_layout Description
8676 \begin_inset Flex Code
8677 status collapsed
8678
8679 \begin_layout Plain Layout
8680 ExcludesModule
8681 \end_layout
8682
8683 \end_inset
8684
8685  [
8686 \begin_inset Flex Code
8687 status collapsed
8688
8689 \begin_layout Plain Layout
8690 <module>
8691 \end_layout
8692
8693 \end_inset
8694
8695 ] This tag indicates that the module (which is specified by filename without
8696  the 
8697 \begin_inset Flex Code
8698 status collapsed
8699
8700 \begin_layout Plain Layout
8701 .module
8702 \end_layout
8703
8704 \end_inset
8705
8706  extension) cannot be used with this document class.
8707  This might be used in a journal-specific layout file to prevent, say, the
8708  use of the 
8709 \begin_inset Flex Code
8710 status collapsed
8711
8712 \begin_layout Plain Layout
8713 theorems-sec
8714 \end_layout
8715
8716 \end_inset
8717
8718  module that numbers theorems by section.
8719  This tag may 
8720 \emph on
8721 not
8722 \emph default
8723  be used in a module.
8724  Modules have their own way of excluding other modules (see 
8725 \begin_inset CommandInset ref
8726 LatexCommand ref
8727 reference "sub:Layout-modules"
8728
8729 \end_inset
8730
8731 ).
8732 \end_layout
8733
8734 \begin_layout Description
8735 \begin_inset Flex Code
8736 status collapsed
8737
8738 \begin_layout Plain Layout
8739 Float
8740 \end_layout
8741
8742 \end_inset
8743
8744  Defines a new float.
8745  See 
8746 \begin_inset CommandInset ref
8747 LatexCommand ref
8748 reference "sub:Floats"
8749
8750 \end_inset
8751
8752  for details.
8753  Must end with 
8754 \begin_inset Quotes eld
8755 \end_inset
8756
8757
8758 \begin_inset Flex Code
8759 status collapsed
8760
8761 \begin_layout Plain Layout
8762 End
8763 \end_layout
8764
8765 \end_inset
8766
8767
8768 \begin_inset Quotes erd
8769 \end_inset
8770
8771 .
8772 \end_layout
8773
8774 \begin_layout Description
8775 \begin_inset Flex Code
8776 status collapsed
8777
8778 \begin_layout Plain Layout
8779 HTMLPreamble
8780 \end_layout
8781
8782 \end_inset
8783
8784  Sets the information that will be output in the 
8785 \begin_inset Flex Code
8786 status collapsed
8787
8788 \begin_layout Plain Layout
8789 <head>
8790 \end_layout
8791
8792 \end_inset
8793
8794  block when this document class is output to XHTML.
8795  Note that this will completely override any prior 
8796 \begin_inset Flex Code
8797 status collapsed
8798
8799 \begin_layout Plain Layout
8800 HTMLPreamble
8801 \end_layout
8802
8803 \end_inset
8804
8805  or 
8806 \begin_inset Flex Code
8807 status collapsed
8808
8809 \begin_layout Plain Layout
8810 AddToHTMLPreamble
8811 \end_layout
8812
8813 \end_inset
8814
8815  declarations.
8816  (Use
8817 \begin_inset Newline newline
8818 \end_inset
8819
8820
8821 \begin_inset Flex Code
8822 status collapsed
8823
8824 \begin_layout Plain Layout
8825 AddToHTMLPreamble
8826 \end_layout
8827
8828 \end_inset
8829
8830  if you just want to add material to the preamble.) Must end with 
8831 \begin_inset Quotes eld
8832 \end_inset
8833
8834
8835 \begin_inset Flex Code
8836 status collapsed
8837
8838 \begin_layout Plain Layout
8839 EndPreamble
8840 \end_layout
8841
8842 \end_inset
8843
8844
8845 \begin_inset Quotes erd
8846 \end_inset
8847
8848 .
8849 \end_layout
8850
8851 \begin_layout Description
8852 \begin_inset Flex Code
8853 status collapsed
8854
8855 \begin_layout Plain Layout
8856 HTMLTOCSection
8857 \end_layout
8858
8859 \end_inset
8860
8861  [
8862 \begin_inset Flex Code
8863 status collapsed
8864
8865 \begin_layout Plain Layout
8866 <style>
8867 \end_layout
8868
8869 \end_inset
8870
8871 ] The style to use for the table of contents, bibliography, and so forth,
8872  when the document is output to HTML.
8873  For articles, this should normally be 
8874 \begin_inset Flex Code
8875 status collapsed
8876
8877 \begin_layout Plain Layout
8878 Section
8879 \end_layout
8880
8881 \end_inset
8882
8883 ; for books 
8884 \begin_inset Flex Code
8885 status collapsed
8886
8887 \begin_layout Plain Layout
8888 Chapter
8889 \end_layout
8890
8891 \end_inset
8892
8893 .
8894  If it is not given, then LyX will attempt to figure out which layout to
8895  use.
8896 \end_layout
8897
8898 \begin_layout Description
8899 \begin_inset Flex Code
8900 status collapsed
8901
8902 \begin_layout Plain Layout
8903 IfCounter
8904 \end_layout
8905
8906 \end_inset
8907
8908  [
8909 \begin_inset Flex Code
8910 status collapsed
8911
8912 \begin_layout Plain Layout
8913 <counter>
8914 \end_layout
8915
8916 \end_inset
8917
8918 ] Modifies the properties of the given counter.
8919  If the counter does not exist, the statement is ignored.
8920  Must end with 
8921 \begin_inset Quotes eld
8922 \end_inset
8923
8924
8925 \begin_inset Flex Code
8926 status collapsed
8927
8928 \begin_layout Plain Layout
8929 End
8930 \end_layout
8931
8932 \end_inset
8933
8934
8935 \begin_inset Quotes erd
8936 \end_inset
8937
8938 .
8939 \begin_inset Newline newline
8940 \end_inset
8941
8942 See 
8943 \begin_inset CommandInset ref
8944 LatexCommand ref
8945 reference "sub:Counters"
8946
8947 \end_inset
8948
8949  for details on counters.
8950 \end_layout
8951
8952 \begin_layout Description
8953 \begin_inset Flex Code
8954 status collapsed
8955
8956 \begin_layout Plain Layout
8957 IfStyle
8958 \end_layout
8959
8960 \end_inset
8961
8962  [
8963 \begin_inset Flex Code
8964 status collapsed
8965
8966 \begin_layout Plain Layout
8967 <style>
8968 \end_layout
8969
8970 \end_inset
8971
8972 ] Modifies the properties of the given paragraph style.
8973  If the style does not exist, the statement is ignored.
8974  Must end with 
8975 \begin_inset Quotes eld
8976 \end_inset
8977
8978
8979 \begin_inset Flex Code
8980 status collapsed
8981
8982 \begin_layout Plain Layout
8983 End
8984 \end_layout
8985
8986 \end_inset
8987
8988
8989 \begin_inset Quotes erd
8990 \end_inset
8991
8992 .
8993 \end_layout
8994
8995 \begin_layout Description
8996 \begin_inset Flex Code
8997 status collapsed
8998
8999 \begin_layout Plain Layout
9000 Input
9001 \end_layout
9002
9003 \end_inset
9004
9005  [
9006 \begin_inset Flex Code
9007 status collapsed
9008
9009 \begin_layout Plain Layout
9010 <filename>
9011 \end_layout
9012
9013 \end_inset
9014
9015 ] This allows you to include another layout definition file within yours
9016  to avoid duplicating commands.
9017  Common examples are the standard layout files, for example, 
9018 \begin_inset Flex Code
9019 status collapsed
9020
9021 \begin_layout Plain Layout
9022 stdclass.inc
9023 \end_layout
9024
9025 \end_inset
9026
9027 , which contains most of the basic layouts.
9028 \end_layout
9029
9030 \begin_layout Description
9031 \begin_inset Flex Code
9032 status collapsed
9033
9034 \begin_layout Plain Layout
9035 InsetLayout
9036 \end_layout
9037
9038 \end_inset
9039
9040  [
9041 \begin_inset Flex Code
9042 status collapsed
9043
9044 \begin_layout Plain Layout
9045 <type>
9046 \end_layout
9047
9048 \end_inset
9049
9050 ] This section (re-)defines the layout of an inset.
9051  It can be applied to an existing inset or to a new, user-defined inset,
9052  e.g., a new character style.
9053  Must end with 
9054 \begin_inset Quotes eld
9055 \end_inset
9056
9057
9058 \begin_inset Flex Code
9059 status collapsed
9060
9061 \begin_layout Plain Layout
9062 End
9063 \end_layout
9064
9065 \end_inset
9066
9067
9068 \begin_inset Quotes erd
9069 \end_inset
9070
9071 .
9072 \begin_inset Newline newline
9073 \end_inset
9074
9075 See 
9076 \begin_inset CommandInset ref
9077 LatexCommand ref
9078 reference "sub:Flex-insets-and"
9079
9080 \end_inset
9081
9082  for more information.
9083  
9084 \end_layout
9085
9086 \begin_layout Description
9087 \begin_inset Flex Code
9088 status collapsed
9089
9090 \begin_layout Plain Layout
9091 LeftMargin
9092 \end_layout
9093
9094 \end_inset
9095
9096  [
9097 \begin_inset Flex Code
9098 status collapsed
9099
9100 \begin_layout Plain Layout
9101 string
9102 \end_layout
9103
9104 \end_inset
9105
9106 ] A string that indicates the width of the left margin on the screen, for
9107  example, 
9108 \begin_inset Quotes eld
9109 \end_inset
9110
9111
9112 \begin_inset Flex Code
9113 status collapsed
9114
9115 \begin_layout Plain Layout
9116 MMMMM
9117 \end_layout
9118
9119 \end_inset
9120
9121
9122 \begin_inset Quotes erd
9123 \end_inset
9124
9125 .
9126  (Note that this is not a `length', like 
9127 \begin_inset Quotes eld
9128 \end_inset
9129
9130 2ex
9131 \begin_inset Quotes erd
9132 \end_inset
9133
9134 .)
9135 \end_layout
9136
9137 \begin_layout Description
9138 \begin_inset Flex Code
9139 status collapsed
9140
9141 \begin_layout Plain Layout
9142 NoCounter
9143 \end_layout
9144
9145 \end_inset
9146
9147  [
9148 \begin_inset Flex Code
9149 status collapsed
9150
9151 \begin_layout Plain Layout
9152 <counter>
9153 \end_layout
9154
9155 \end_inset
9156
9157 ] Deletes an existing counter, usually one defined in an included file.
9158 \end_layout
9159
9160 \begin_layout Description
9161 \begin_inset Flex Code
9162 status collapsed
9163
9164 \begin_layout Plain Layout
9165 NoFloat
9166 \end_layout
9167
9168 \end_inset
9169
9170  [
9171 \begin_inset Flex Code
9172 status collapsed
9173
9174 \begin_layout Plain Layout
9175 <float>
9176 \end_layout
9177
9178 \end_inset
9179
9180 ] Deletes an existing float.
9181  This is particularly useful when you want to suppress a float that has
9182  been defined in an input file.
9183 \end_layout
9184
9185 \begin_layout Description
9186 \begin_inset Flex Code
9187 status collapsed
9188
9189 \begin_layout Plain Layout
9190 NoStyle
9191 \end_layout
9192
9193 \end_inset
9194
9195  [
9196 \begin_inset Flex Code
9197 status collapsed
9198
9199 \begin_layout Plain Layout
9200 <style>
9201 \end_layout
9202
9203 \end_inset
9204
9205 ] Deletes an existing style.
9206 \end_layout
9207
9208 \begin_layout Description
9209 \begin_inset Flex Code
9210 status collapsed
9211
9212 \begin_layout Plain Layout
9213 OutputFormat
9214 \end_layout
9215
9216 \end_inset
9217
9218  [
9219 \begin_inset Flex Code
9220 status collapsed
9221
9222 \begin_layout Plain Layout
9223 <format>
9224 \end_layout
9225
9226 \end_inset
9227
9228 ] The file format (as defined in the LyX preferences) produced by this document
9229  class.
9230  It is mainly useful when 
9231 \begin_inset Flex Code
9232 status collapsed
9233
9234 \begin_layout Plain Layout
9235 OutputType
9236 \end_layout
9237
9238 \end_inset
9239
9240  is 
9241 \begin_inset Flex Code
9242 status collapsed
9243
9244 \begin_layout Plain Layout
9245 literate
9246 \end_layout
9247
9248 \end_inset
9249
9250  and one wants to define a new type of literate document.
9251  The format is reset to 
9252 \begin_inset Quotes eld
9253 \end_inset
9254
9255
9256 \begin_inset Flex Code
9257 status collapsed
9258
9259 \begin_layout Plain Layout
9260 docbook
9261 \end_layout
9262
9263 \end_inset
9264
9265
9266 \begin_inset Quotes erd
9267 \end_inset
9268
9269  or 
9270 \begin_inset Quotes eld
9271 \end_inset
9272
9273
9274 \begin_inset Flex Code
9275 status collapsed
9276
9277 \begin_layout Plain Layout
9278 latex
9279 \end_layout
9280
9281 \end_inset
9282
9283
9284 \begin_inset Quotes erd
9285 \end_inset
9286
9287  when the corresponding 
9288 \begin_inset Flex Code
9289 status collapsed
9290
9291 \begin_layout Plain Layout
9292 OutputType
9293 \end_layout
9294
9295 \end_inset
9296
9297  parameter is encountered.
9298 \end_layout
9299
9300 \begin_layout Description
9301 \begin_inset Flex Code
9302 status collapsed
9303
9304 \begin_layout Plain Layout
9305 OutputType
9306 \end_layout
9307
9308 \end_inset
9309
9310  [
9311 \begin_inset Flex Code
9312 status collapsed
9313
9314 \begin_layout Plain Layout
9315
9316 \emph on
9317 lat
9318 \emph default
9319 ex
9320 \end_layout
9321
9322 \end_inset
9323
9324
9325 \begin_inset Flex Code
9326 status collapsed
9327
9328 \begin_layout Plain Layout
9329 docbook
9330 \end_layout
9331
9332 \end_inset
9333
9334
9335 \begin_inset Flex Code
9336 status collapsed
9337
9338 \begin_layout Plain Layout
9339 literate
9340 \end_layout
9341
9342 \end_inset
9343
9344 ] Specifies what sort of output documents using this class will produce.
9345 \end_layout
9346
9347 \begin_layout Description
9348 \begin_inset Flex Code
9349 status collapsed
9350
9351 \begin_layout Plain Layout
9352 PackageOptions
9353 \end_layout
9354
9355 \end_inset
9356
9357  [
9358 \begin_inset Flex Code
9359 status collapsed
9360
9361 \begin_layout Plain Layout
9362 string
9363 \end_layout
9364
9365 \end_inset
9366
9367  
9368 \begin_inset Flex Code
9369 status collapsed
9370
9371 \begin_layout Plain Layout
9372 string
9373 \end_layout
9374
9375 \end_inset
9376
9377 ] Specifies options, given in the second string, for the package named by
9378  the first string.
9379  For example, 
9380 \begin_inset Quotes eld
9381 \end_inset
9382
9383
9384 \begin_inset Flex Code
9385 status collapsed
9386
9387 \begin_layout Plain Layout
9388 PackageOptions natbib square
9389 \end_layout
9390
9391 \end_inset
9392
9393
9394 \begin_inset Quotes erd
9395 \end_inset
9396
9397  will cause 
9398 \begin_inset Flex Code
9399 status collapsed
9400
9401 \begin_layout Plain Layout
9402 natbib
9403 \end_layout
9404
9405 \end_inset
9406
9407  to be loaded with the 
9408 \begin_inset Flex Code
9409 status collapsed
9410
9411 \begin_layout Plain Layout
9412 square
9413 \end_layout
9414
9415 \end_inset
9416
9417  option.
9418  (For TeXperts, this causes LyX to output: 
9419 \begin_inset Flex Code
9420 status collapsed
9421
9422 \begin_layout Plain Layout
9423
9424 \backslash
9425 PassOptionsToPackage{natbib}{square}
9426 \end_layout
9427
9428 \end_inset
9429
9430  prior to loading 
9431 \begin_inset Flex Code
9432 status collapsed
9433
9434 \begin_layout Plain Layout
9435 natbib
9436 \end_layout
9437
9438 \end_inset
9439
9440 .)
9441 \end_layout
9442
9443 \begin_layout Description
9444 \begin_inset Flex Code
9445 status collapsed
9446
9447 \begin_layout Plain Layout
9448 PageStyle
9449 \end_layout
9450
9451 \end_inset
9452
9453  [
9454 \begin_inset Flex Code
9455 status collapsed
9456
9457 \begin_layout Plain Layout
9458
9459 \emph on
9460 plain
9461 \end_layout
9462
9463 \end_inset
9464
9465
9466 \begin_inset Flex Code
9467 status collapsed
9468
9469 \begin_layout Plain Layout
9470 empty
9471 \end_layout
9472
9473 \end_inset
9474
9475
9476 \begin_inset Flex Code
9477 status collapsed
9478
9479 \begin_layout Plain Layout
9480 headings
9481 \end_layout
9482
9483 \end_inset
9484
9485 ] The default pagestyle.
9486  Can be changed in the 
9487 \begin_inset Flex MenuItem
9488 status collapsed
9489
9490 \begin_layout Plain Layout
9491 Document\SpecialChar \menuseparator
9492 Settings
9493 \end_layout
9494
9495 \end_inset
9496
9497  dialog.
9498 \end_layout
9499
9500 \begin_layout Description
9501 \begin_inset Flex Code
9502 status collapsed
9503
9504 \begin_layout Plain Layout
9505 Preamble
9506 \end_layout
9507
9508 \end_inset
9509
9510  Sets the preamble for the LaTeX document.
9511  Note that this will completely override any prior 
9512 \begin_inset Flex Code
9513 status collapsed
9514
9515 \begin_layout Plain Layout
9516 Preamble
9517 \end_layout
9518
9519 \end_inset
9520
9521  or 
9522 \begin_inset Flex Code
9523 status collapsed
9524
9525 \begin_layout Plain Layout
9526 AddToPreamble
9527 \end_layout
9528
9529 \end_inset
9530
9531  declarations.
9532  (Use 
9533 \begin_inset Flex Code
9534 status collapsed
9535
9536 \begin_layout Plain Layout
9537 AddToPreamble
9538 \end_layout
9539
9540 \end_inset
9541
9542  if you just want to add material to the preamble.) Must end with 
9543 \begin_inset Quotes eld
9544 \end_inset
9545
9546
9547 \begin_inset Flex Code
9548 status collapsed
9549
9550 \begin_layout Plain Layout
9551 EndPreamble
9552 \end_layout
9553
9554 \end_inset
9555
9556
9557 \begin_inset Quotes erd
9558 \end_inset
9559
9560 .
9561 \end_layout
9562
9563 \begin_layout Description
9564 \begin_inset Flex Code
9565 status collapsed
9566
9567 \begin_layout Plain Layout
9568 Provides
9569 \end_layout
9570
9571 \end_inset
9572
9573  [
9574 \begin_inset Flex Code
9575 status collapsed
9576
9577 \begin_layout Plain Layout
9578 string
9579 \end_layout
9580
9581 \end_inset
9582
9583 ] [
9584 \begin_inset Flex Code
9585 status collapsed
9586
9587 \begin_layout Plain Layout
9588
9589 \emph on
9590 0
9591 \end_layout
9592
9593 \end_inset
9594
9595 ,
9596 \begin_inset space \thinspace{}
9597 \end_inset
9598
9599
9600 \begin_inset Flex Code
9601 status collapsed
9602
9603 \begin_layout Plain Layout
9604 1
9605 \end_layout
9606
9607 \end_inset
9608
9609 ] Whether the class already provides the feature 
9610 \begin_inset Flex Code
9611 status collapsed
9612
9613 \begin_layout Plain Layout
9614 string
9615 \end_layout
9616
9617 \end_inset
9618
9619 .
9620  A feature is in general the name of a package (e.
9621 \begin_inset space \thinspace{}
9622 \end_inset
9623
9624 g.
9625 \begin_inset space \space{}
9626 \end_inset
9627
9628
9629 \begin_inset Flex Code
9630 status collapsed
9631
9632 \begin_layout Plain Layout
9633 amsmath
9634 \end_layout
9635
9636 \end_inset
9637
9638  or 
9639 \begin_inset Flex Code
9640 status collapsed
9641
9642 \begin_layout Plain Layout
9643 makeidx
9644 \end_layout
9645
9646 \end_inset
9647
9648 ) or a macro (e.
9649 \begin_inset space \thinspace{}
9650 \end_inset
9651
9652 g.
9653 \begin_inset space \space{}
9654 \end_inset
9655
9656
9657 \begin_inset Flex Code
9658 status collapsed
9659
9660 \begin_layout Plain Layout
9661 url
9662 \end_layout
9663
9664 \end_inset
9665
9666  or 
9667 \begin_inset Flex Code
9668 status collapsed
9669
9670 \begin_layout Plain Layout
9671 boldsymbol
9672 \end_layout
9673
9674 \end_inset
9675
9676 ).
9677  See 
9678 \begin_inset CommandInset ref
9679 LatexCommand ref
9680 reference "chap:List-of-functions"
9681
9682 \end_inset
9683
9684  for the list of features.
9685 \end_layout
9686
9687 \begin_layout Description
9688 \begin_inset Flex Code
9689 status collapsed
9690
9691 \begin_layout Plain Layout
9692 ProvidesModule
9693 \end_layout
9694
9695 \end_inset
9696
9697  [
9698 \begin_inset Flex Code
9699 status collapsed
9700
9701 \begin_layout Plain Layout
9702 string
9703 \end_layout
9704
9705 \end_inset
9706
9707 ] Indicates that this layout provides the functionality of the module mentioned,
9708  which should be specified by the filename without the 
9709 \begin_inset Flex Code
9710 status collapsed
9711
9712 \begin_layout Plain Layout
9713 .module
9714 \end_layout
9715
9716 \end_inset
9717
9718  extension.
9719  This will typically be used if the layout includes the module directly,
9720  rather than using the 
9721 \begin_inset Flex Code
9722 status collapsed
9723
9724 \begin_layout Plain Layout
9725 DefaultModule
9726 \end_layout
9727
9728 \end_inset
9729
9730  tag to indicate that it ought to be used.
9731  It could also be used in a module that provided an alternate implementation
9732  of the same functionality.
9733 \end_layout
9734
9735 \begin_layout Description
9736 \begin_inset Flex Code
9737 status collapsed
9738
9739 \begin_layout Plain Layout
9740 Requires
9741 \end_layout
9742
9743 \end_inset
9744
9745  [
9746 \begin_inset Flex Code
9747 status collapsed
9748
9749 \begin_layout Plain Layout
9750 string
9751 \end_layout
9752
9753 \end_inset
9754
9755 ] Whether the class requires the feature 
9756 \begin_inset Flex Code
9757 status collapsed
9758
9759 \begin_layout Plain Layout
9760 string
9761 \end_layout
9762
9763 \end_inset
9764
9765 .
9766  Multiple features must be separated by commas.
9767  Note that you can only request supported features.
9768  (See 
9769 \begin_inset CommandInset ref
9770 LatexCommand ref
9771 reference "chap:List-of-functions"
9772
9773 \end_inset
9774
9775  for the list of features.)
9776 \end_layout
9777
9778 \begin_layout Description
9779 \begin_inset Flex Code
9780 status collapsed
9781
9782 \begin_layout Plain Layout
9783 RightMargin
9784 \end_layout
9785
9786 \end_inset
9787
9788  [
9789 \begin_inset Flex Code
9790 status collapsed
9791
9792 \begin_layout Plain Layout
9793 string
9794 \end_layout
9795
9796 \end_inset
9797
9798 ] A string that indicates the width of the right margin on the screen, for
9799  example, 
9800 \begin_inset Quotes eld
9801 \end_inset
9802
9803
9804 \begin_inset Flex Code
9805 status collapsed
9806
9807 \begin_layout Plain Layout
9808 MMMMM
9809 \end_layout
9810
9811 \end_inset
9812
9813
9814 \begin_inset Quotes erd
9815 \end_inset
9816
9817 .
9818 \end_layout
9819
9820 \begin_layout Description
9821 \begin_inset Flex Code
9822 status collapsed
9823
9824 \begin_layout Plain Layout
9825 SecNumDepth
9826 \end_layout
9827
9828 \end_inset
9829
9830  [
9831 \begin_inset Flex Code
9832 status collapsed
9833
9834 \begin_layout Plain Layout
9835 int=3
9836 \end_layout
9837
9838 \end_inset
9839
9840 ] Sets which divisions get numbered.
9841  Corresponds to the
9842 \begin_inset Newline newline
9843 \end_inset
9844
9845
9846 \begin_inset Flex Code
9847 status collapsed
9848
9849 \begin_layout Plain Layout
9850 secnumdepth
9851 \end_layout
9852
9853 \end_inset
9854
9855  counter in LaTeX.
9856 \end_layout
9857
9858 \begin_layout Description
9859 \begin_inset Flex Code
9860 status collapsed
9861
9862 \begin_layout Plain Layout
9863 Sides
9864 \end_layout
9865
9866 \end_inset
9867
9868  [
9869 \begin_inset Flex Code
9870 status collapsed
9871
9872 \begin_layout Plain Layout
9873
9874 \emph on
9875 1
9876 \end_layout
9877
9878 \end_inset
9879
9880 ,
9881 \begin_inset space \thinspace{}
9882 \end_inset
9883
9884
9885 \begin_inset Flex Code
9886 status collapsed
9887
9888 \begin_layout Plain Layout
9889 2
9890 \end_layout
9891
9892 \end_inset
9893
9894 ] Whether the class-default should be printing on one or both sides of the
9895  paper.
9896  Can be changed in the 
9897 \begin_inset Flex MenuItem
9898 status collapsed
9899
9900 \begin_layout Plain Layout
9901 Document\SpecialChar \menuseparator
9902 Settings
9903 \end_layout
9904
9905 \end_inset
9906
9907  dialog.
9908 \end_layout
9909
9910 \begin_layout Description
9911 \begin_inset Flex Code
9912 status collapsed
9913
9914 \begin_layout Plain Layout
9915 Style
9916 \end_layout
9917
9918 \end_inset
9919
9920  [
9921 \begin_inset Flex Code
9922 status collapsed
9923
9924 \begin_layout Plain Layout
9925 <name>
9926 \end_layout
9927
9928 \end_inset
9929
9930 ] This sequence defines a paragraph style.
9931  If the style does not yet exist, it is created; if it does exist, its parameter
9932 s are modified.
9933  Must end with 
9934 \begin_inset Quotes eld
9935 \end_inset
9936
9937
9938 \begin_inset Flex Code
9939 status collapsed
9940
9941 \begin_layout Plain Layout
9942 End
9943 \end_layout
9944
9945 \end_inset
9946
9947
9948 \begin_inset Quotes erd
9949 \end_inset
9950
9951 .
9952 \begin_inset Newline newline
9953 \end_inset
9954
9955 See 
9956 \begin_inset CommandInset ref
9957 LatexCommand ref
9958 reference "sub:Paragraph-Styles"
9959
9960 \end_inset
9961
9962  for details on paragraph styles.
9963 \end_layout
9964
9965 \begin_layout Description
9966 \begin_inset Flex Code
9967 status collapsed
9968
9969 \begin_layout Plain Layout
9970 TitleLatexName
9971 \end_layout
9972
9973 \end_inset
9974
9975  [
9976 \begin_inset Flex Code
9977 status collapsed
9978
9979 \begin_layout Plain Layout
9980 string="maketitle"
9981 \end_layout
9982
9983 \end_inset
9984
9985 ] The name of the command or environment to be used with 
9986 \begin_inset Flex Code
9987 status collapsed
9988
9989 \begin_layout Plain Layout
9990 TitleLatexType
9991 \end_layout
9992
9993 \end_inset
9994
9995 .
9996 \end_layout
9997
9998 \begin_layout Description
9999 \begin_inset Flex Code
10000 status collapsed
10001
10002 \begin_layout Plain Layout
10003 TitleLatexType
10004 \end_layout
10005
10006 \end_inset
10007
10008  [
10009 \begin_inset Flex Code
10010 status collapsed
10011
10012 \begin_layout Plain Layout
10013
10014 \emph on
10015 CommandAfter
10016 \end_layout
10017
10018 \end_inset
10019
10020
10021 \begin_inset Flex Code
10022 status collapsed
10023
10024 \begin_layout Plain Layout
10025 Environment
10026 \end_layout
10027
10028 \end_inset
10029
10030 ] Indicates what kind of markup is used to define the title of a document.
10031  
10032 \begin_inset Flex Code
10033 status collapsed
10034
10035 \begin_layout Plain Layout
10036 CommandAfter
10037 \end_layout
10038
10039 \end_inset
10040
10041  means that the macro with name 
10042 \begin_inset Flex Code
10043 status collapsed
10044
10045 \begin_layout Plain Layout
10046 TitleLatexName
10047 \end_layout
10048
10049 \end_inset
10050
10051  will be inserted after the last layout which has 
10052 \begin_inset Quotes eld
10053 \end_inset
10054
10055
10056 \begin_inset Flex Code
10057 status collapsed
10058
10059 \begin_layout Plain Layout
10060 InTitle
10061 \begin_inset space ~
10062 \end_inset
10063
10064 1
10065 \end_layout
10066
10067 \end_inset
10068
10069
10070 \begin_inset Quotes erd
10071 \end_inset
10072
10073 .
10074  
10075 \begin_inset Flex Code
10076 status collapsed
10077
10078 \begin_layout Plain Layout
10079 Environment
10080 \end_layout
10081
10082 \end_inset
10083
10084  corresponds to the case where all layouts which have 
10085 \begin_inset Quotes eld
10086 \end_inset
10087
10088
10089 \begin_inset Flex Code
10090 status collapsed
10091
10092 \begin_layout Plain Layout
10093 InTitle
10094 \begin_inset space ~
10095 \end_inset
10096
10097 1
10098 \end_layout
10099
10100 \end_inset
10101
10102
10103 \begin_inset Quotes erd
10104 \end_inset
10105
10106  should be enclosed into the 
10107 \begin_inset Flex Code
10108 status collapsed
10109
10110 \begin_layout Plain Layout
10111 TitleLatexName
10112 \end_layout
10113
10114 \end_inset
10115
10116  environment.
10117 \end_layout
10118
10119 \begin_layout Description
10120 \begin_inset Flex Code
10121 status collapsed
10122
10123 \begin_layout Plain Layout
10124 TocDepth
10125 \end_layout
10126
10127 \end_inset
10128
10129  [
10130 \begin_inset Flex Code
10131 status collapsed
10132
10133 \begin_layout Plain Layout
10134 int=3
10135 \end_layout
10136
10137 \end_inset
10138
10139 ] Sets which divisions are included in the table of contents.
10140  Corresponds to the 
10141 \begin_inset Flex Code
10142 status collapsed
10143
10144 \begin_layout Plain Layout
10145 tocdepth
10146 \end_layout
10147
10148 \end_inset
10149
10150  counter in LaTeX.
10151 \end_layout
10152
10153 \begin_layout Subsection
10154 \begin_inset Flex Code
10155 status collapsed
10156
10157 \begin_layout Plain Layout
10158 ClassOptions
10159 \end_layout
10160
10161 \end_inset
10162
10163  section
10164 \begin_inset CommandInset label
10165 LatexCommand label
10166 name "sub:ClassOptions"
10167
10168 \end_inset
10169
10170
10171 \end_layout
10172
10173 \begin_layout Standard
10174 The 
10175 \begin_inset Flex Code
10176 status collapsed
10177
10178 \begin_layout Plain Layout
10179 ClassOptions
10180 \end_layout
10181
10182 \end_inset
10183
10184  section can contain the following entries:
10185 \end_layout
10186
10187 \begin_layout Description
10188 \begin_inset Flex Code
10189 status collapsed
10190
10191 \begin_layout Plain Layout
10192 FontSize
10193 \end_layout
10194
10195 \end_inset
10196
10197  [
10198 \begin_inset Flex Code
10199 status collapsed
10200
10201 \begin_layout Plain Layout
10202 string="10|11|12"
10203 \end_layout
10204
10205 \end_inset
10206
10207 ] The list of available font sizes for the document's main font, separated
10208  by 
10209 \begin_inset Quotes eld
10210 \end_inset
10211
10212
10213 \begin_inset Flex Code
10214 status collapsed
10215
10216 \begin_layout Plain Layout
10217 |
10218 \end_layout
10219
10220 \end_inset
10221
10222
10223 \begin_inset Quotes erd
10224 \end_inset
10225
10226 .
10227 \end_layout
10228
10229 \begin_layout Description
10230 \begin_inset Flex Code
10231 status collapsed
10232
10233 \begin_layout Plain Layout
10234 Header
10235 \end_layout
10236
10237 \end_inset
10238
10239  Used to set the DTD line with XML-based output classes.
10240  E.
10241 \begin_inset space \thinspace{}
10242 \end_inset
10243
10244 g.: PUBLIC 
10245 \begin_inset Quotes eld
10246 \end_inset
10247
10248 -//OASIS//DTD DocBook V4.2//EN
10249 \begin_inset Quotes erd
10250 \end_inset
10251
10252 .
10253 \end_layout
10254
10255 \begin_layout Description
10256 \begin_inset Flex Code
10257 status collapsed
10258
10259 \begin_layout Plain Layout
10260 PageStyle
10261 \end_layout
10262
10263 \end_inset
10264
10265  [
10266 \begin_inset Flex Code
10267 status collapsed
10268
10269 \begin_layout Plain Layout
10270 string="empty|plain|headings|fancy"
10271 \end_layout
10272
10273 \end_inset
10274
10275 ] The list of available page sty\SpecialChar \-
10276 les, separated by 
10277 \begin_inset Quotes eld
10278 \end_inset
10279
10280
10281 \begin_inset Flex Code
10282 status collapsed
10283
10284 \begin_layout Plain Layout
10285 |
10286 \end_layout
10287
10288 \end_inset
10289
10290
10291 \begin_inset Quotes erd
10292 \end_inset
10293
10294 .
10295 \end_layout
10296
10297 \begin_layout Description
10298 \begin_inset Flex Code
10299 status collapsed
10300
10301 \begin_layout Plain Layout
10302 Other
10303 \end_layout
10304
10305 \end_inset
10306
10307  [
10308 \begin_inset Flex Code
10309 status collapsed
10310
10311 \begin_layout Plain Layout
10312 string=""
10313 \end_layout
10314
10315 \end_inset
10316
10317 ] Some document class options, separated by a comma, that will be added
10318  to the optional part of the 
10319 \begin_inset Flex Code
10320 status collapsed
10321
10322 \begin_layout Plain Layout
10323
10324 \backslash
10325 documentclass
10326 \end_layout
10327
10328 \end_inset
10329
10330  command.
10331 \end_layout
10332
10333 \begin_layout Standard
10334 The 
10335 \begin_inset Flex Code
10336 status collapsed
10337
10338 \begin_layout Plain Layout
10339 ClassOptions
10340 \end_layout
10341
10342 \end_inset
10343
10344  section must end with 
10345 \begin_inset Quotes eld
10346 \end_inset
10347
10348
10349 \begin_inset Flex Code
10350 status collapsed
10351
10352 \begin_layout Plain Layout
10353 End
10354 \end_layout
10355
10356 \end_inset
10357
10358
10359 \begin_inset Quotes erd
10360 \end_inset
10361
10362 .
10363 \end_layout
10364
10365 \begin_layout Subsection
10366 Paragraph styles
10367 \begin_inset CommandInset label
10368 LatexCommand label
10369 name "sub:Paragraph-Styles"
10370
10371 \end_inset
10372
10373
10374 \end_layout
10375
10376 \begin_layout Standard
10377 A paragraph style description looks like this:
10378 \begin_inset Foot
10379 status collapsed
10380
10381 \begin_layout Plain Layout
10382 Note that this will either define a new style or modify an existing one.
10383 \end_layout
10384
10385 \end_inset
10386
10387
10388 \end_layout
10389
10390 \begin_layout LyX-Code
10391 Style 
10392 \family roman
10393 \emph on
10394 name
10395 \end_layout
10396
10397 \begin_layout LyX-Code
10398  ...
10399 \end_layout
10400
10401 \begin_layout LyX-Code
10402 End
10403 \end_layout
10404
10405 \begin_layout Standard
10406 where the following commands are allowed:
10407 \end_layout
10408
10409 \begin_layout Description
10410 \begin_inset Flex Code
10411 status collapsed
10412
10413 \begin_layout Plain Layout
10414 Align
10415 \end_layout
10416
10417 \end_inset
10418
10419  [
10420 \begin_inset Flex Code
10421 status collapsed
10422
10423 \begin_layout Plain Layout
10424
10425 \emph on
10426 block
10427 \emph default
10428 , left, right, center
10429 \end_layout
10430
10431 \end_inset
10432
10433 ] Paragraph alignment.
10434 \end_layout
10435
10436 \begin_layout Description
10437 \begin_inset Flex Code
10438 status collapsed
10439
10440 \begin_layout Plain Layout
10441 AlignPossible
10442 \end_layout
10443
10444 \end_inset
10445
10446  [
10447 \begin_inset Flex Code
10448 status collapsed
10449
10450 \begin_layout Plain Layout
10451
10452 \emph on
10453 block
10454 \emph default
10455 , left, right, center
10456 \end_layout
10457
10458 \end_inset
10459
10460 ] A comma separated list of permitted alignments.
10461  (Some LaTeX styles prohibit certain alignments, since those wouldn't make
10462  sense.
10463  For example a right-aligned or centered enumeration isn't possible.)
10464 \end_layout
10465
10466 \begin_layout Description
10467 \begin_inset Flex Code
10468 status collapsed
10469
10470 \begin_layout Plain Layout
10471 Argument
10472 \end_layout
10473
10474 \end_inset
10475
10476  [
10477 \begin_inset Flex Code
10478 status collapsed
10479
10480 \begin_layout Plain Layout
10481 int
10482 \end_layout
10483
10484 \end_inset
10485
10486 ] Defines argument number <int> of a command\SpecialChar \slash{}
10487 environment associated with
10488  the current style.
10489  This is useful for things like section headings, and only makes sense with
10490  LaTeX.
10491  Every (optional or required) argument of a command or environment -- except
10492  for the required argument that is associated with the content of the paragraph
10493  itself -- has a separate definition, where the number specifies the order
10494  of the arguments.
10495  The definition must end with 
10496 \begin_inset Flex Code
10497 status collapsed
10498
10499 \begin_layout Plain Layout
10500 EndArgument
10501 \end_layout
10502
10503 \end_inset
10504
10505 .
10506  So a command with two optional arguments has:
10507 \begin_inset Separator parbreak
10508 \end_inset
10509
10510
10511 \end_layout
10512
10513 \begin_deeper
10514 \begin_layout Quote
10515
10516 \family typewriter
10517 Argument 1
10518 \end_layout
10519
10520 \begin_layout Quote
10521
10522 \family typewriter
10523 ...
10524 \end_layout
10525
10526 \begin_layout Quote
10527
10528 \family typewriter
10529 EndArgument
10530 \end_layout
10531
10532 \begin_layout Quote
10533
10534 \family typewriter
10535 Argument 2
10536 \end_layout
10537
10538 \begin_layout Quote
10539
10540 \family typewriter
10541 ...
10542 \end_layout
10543
10544 \begin_layout Quote
10545
10546 \family typewriter
10547 EndArgument
10548 \end_layout
10549
10550 \begin_layout Standard
10551 Inside the 
10552 \begin_inset Flex Code
10553 status collapsed
10554
10555 \begin_layout Plain Layout
10556 Argument
10557 \end_layout
10558
10559 \end_inset
10560
10561  definition, the following specifications are possible:
10562 \end_layout
10563
10564 \begin_layout Itemize
10565 \begin_inset Flex Code
10566 status collapsed
10567
10568 \begin_layout Plain Layout
10569 LabelString
10570 \end_layout
10571
10572 \end_inset
10573
10574  
10575 \begin_inset Flex Code
10576 status collapsed
10577
10578 \begin_layout Plain Layout
10579 [string]
10580 \end_layout
10581
10582 \end_inset
10583
10584  The string that will appear both in the menu (to insert this argument)
10585  and on the argument inset button (unless you also specify a separate 
10586 \begin_inset Flex Code
10587 status collapsed
10588
10589 \begin_layout Plain Layout
10590 MenuString
10591 \end_layout
10592
10593 \end_inset
10594
10595 ).
10596  For the menu, you can define an accelerator by appending the respective
10597  character to the string, divided by 
10598 \begin_inset Quotes eld
10599 \end_inset
10600
10601 |
10602 \begin_inset Quotes erd
10603 \end_inset
10604
10605  (e.
10606 \begin_inset space \thinspace{}
10607 \end_inset
10608
10609 g.
10610 \begin_inset space \space{}
10611 \end_inset
10612
10613
10614 \begin_inset Quotes eld
10615 \end_inset
10616
10617
10618 \begin_inset Flex Code
10619 status collapsed
10620
10621 \begin_layout Plain Layout
10622 Short Title|S
10623 \end_layout
10624
10625 \end_inset
10626
10627
10628 \begin_inset Quotes erd
10629 \end_inset
10630
10631 ).
10632 \end_layout
10633
10634 \begin_layout Itemize
10635 \begin_inset Flex Code
10636 status collapsed
10637
10638 \begin_layout Plain Layout
10639 MenuString
10640 \end_layout
10641
10642 \end_inset
10643
10644  
10645 \begin_inset Flex Code
10646 status collapsed
10647
10648 \begin_layout Plain Layout
10649 [string]
10650 \end_layout
10651
10652 \end_inset
10653
10654  A separate string for the menu.
10655  You can define an accelerator by appending the respective character to
10656  the string, divided by 
10657 \begin_inset Quotes eld
10658 \end_inset
10659
10660 |
10661 \begin_inset Quotes erd
10662 \end_inset
10663
10664  (e.
10665 \begin_inset space \thinspace{}
10666 \end_inset
10667
10668 g.
10669 \begin_inset space \space{}
10670 \end_inset
10671
10672
10673 \begin_inset Quotes eld
10674 \end_inset
10675
10676
10677 \begin_inset Flex Code
10678 status collapsed
10679
10680 \begin_layout Plain Layout
10681 Short Title|S
10682 \end_layout
10683
10684 \end_inset
10685
10686
10687 \begin_inset Quotes erd
10688 \end_inset
10689
10690 ).
10691  This specification is optional.
10692  If it is not given the 
10693 \begin_inset Flex Code
10694 status collapsed
10695
10696 \begin_layout Plain Layout
10697 LabelString
10698 \end_layout
10699
10700 \end_inset
10701
10702  will be used instead for the menu.
10703 \end_layout
10704
10705 \begin_layout Itemize
10706 \begin_inset Flex Code
10707 status collapsed
10708
10709 \begin_layout Plain Layout
10710 Tooltip
10711 \end_layout
10712
10713 \end_inset
10714
10715  
10716 \begin_inset Flex Code
10717 status collapsed
10718
10719 \begin_layout Plain Layout
10720 [string]
10721 \end_layout
10722
10723 \end_inset
10724
10725  A longer explanatory text that appears in the tooltip when hovering over
10726  the argument inset.
10727 \end_layout
10728
10729 \begin_layout Itemize
10730 \begin_inset Flex Code
10731 status collapsed
10732
10733 \begin_layout Plain Layout
10734 Mandatory
10735 \end_layout
10736
10737 \end_inset
10738
10739  [
10740 \begin_inset Flex Code
10741 status collapsed
10742
10743 \begin_layout Plain Layout
10744
10745 \emph on
10746 0
10747 \end_layout
10748
10749 \end_inset
10750
10751 ,
10752 \begin_inset space \thinspace{}
10753 \end_inset
10754
10755
10756 \begin_inset Flex Code
10757 status collapsed
10758
10759 \begin_layout Plain Layout
10760 1
10761 \end_layout
10762
10763 \end_inset
10764
10765 ] Declare if this is a mandatory (1) or an optional (0) argument.
10766  Mandatory arguments will be output empty if not given, while optional arguments
10767  will not be output at all.
10768  By default, mandatory arguments are delimited by 
10769 \begin_inset Flex Code
10770 status collapsed
10771
10772 \begin_layout Plain Layout
10773 {...}
10774 \end_layout
10775
10776 \end_inset
10777
10778 , while optional arguments are delimited by 
10779 \begin_inset Flex Code
10780 status collapsed
10781
10782 \begin_layout Plain Layout
10783 [...]
10784 \end_layout
10785
10786 \end_inset
10787
10788
10789 \end_layout
10790
10791 \begin_layout Itemize
10792 \begin_inset Flex Code
10793 status collapsed
10794
10795 \begin_layout Plain Layout
10796 Requires
10797 \end_layout
10798
10799 \end_inset
10800
10801  
10802 \begin_inset Flex Code
10803 status collapsed
10804
10805 \begin_layout Plain Layout
10806 [int=0]
10807 \end_layout
10808
10809 \end_inset
10810
10811  defines another argument (by its number) which this argument requires to
10812  be output if it is itself output.
10813  E.
10814 \begin_inset space \thinspace{}
10815 \end_inset
10816
10817 g., in LaTeX commands, optional arguments often require previous optional
10818  arguments to be output (at least empty), as in 
10819 \begin_inset Flex Code
10820 status collapsed
10821
10822 \begin_layout Plain Layout
10823
10824 \backslash
10825 command[][argument]{text}
10826 \end_layout
10827
10828 \end_inset
10829
10830 .
10831  This can be achieved by the statement 
10832 \begin_inset Flex Code
10833 status collapsed
10834
10835 \begin_layout Plain Layout
10836 Requires 1
10837 \end_layout
10838
10839 \end_inset
10840
10841  within 
10842 \begin_inset Flex Code
10843 status collapsed
10844
10845 \begin_layout Plain Layout
10846 Argument 2
10847 \end_layout
10848
10849 \end_inset
10850
10851 .
10852 \end_layout
10853
10854 \begin_layout Itemize
10855 \begin_inset Flex Code
10856 status collapsed
10857
10858 \begin_layout Plain Layout
10859 LeftDelim
10860 \end_layout
10861
10862 \end_inset
10863
10864  
10865 \begin_inset Flex Code
10866 status collapsed
10867
10868 \begin_layout Plain Layout
10869 [string]
10870 \end_layout
10871
10872 \end_inset
10873
10874  defines a custom left delimiter (instead of 
10875 \begin_inset Flex Code
10876 status collapsed
10877
10878 \begin_layout Plain Layout
10879 {
10880 \end_layout
10881
10882 \end_inset
10883
10884  or 
10885 \begin_inset Flex Code
10886 status collapsed
10887
10888 \begin_layout Plain Layout
10889 [
10890 \end_layout
10891
10892 \end_inset
10893
10894 ).
10895  A line break in the output can be indicated by 
10896 \begin_inset Flex Code
10897 status collapsed
10898
10899 \begin_layout Plain Layout
10900 <br/>
10901 \end_layout
10902
10903 \end_inset
10904
10905 .
10906 \end_layout
10907
10908 \begin_layout Itemize
10909 \begin_inset Flex Code
10910 status collapsed
10911
10912 \begin_layout Plain Layout
10913 RightDelim
10914 \end_layout
10915
10916 \end_inset
10917
10918  
10919 \begin_inset Flex Code
10920 status collapsed
10921
10922 \begin_layout Plain Layout
10923 [string]
10924 \end_layout
10925
10926 \end_inset
10927
10928  defines a custom right delimiter (instead of 
10929 \begin_inset Flex Code
10930 status collapsed
10931
10932 \begin_layout Plain Layout
10933 }
10934 \end_layout
10935
10936 \end_inset
10937
10938  or 
10939 \begin_inset Flex Code
10940 status collapsed
10941
10942 \begin_layout Plain Layout
10943 ]
10944 \end_layout
10945
10946 \end_inset
10947
10948 ).
10949  A line break in the output can be indicated by 
10950 \begin_inset Flex Code
10951 status collapsed
10952
10953 \begin_layout Plain Layout
10954 <br/>
10955 \end_layout
10956
10957 \end_inset
10958
10959 .
10960 \end_layout
10961
10962 \begin_layout Itemize
10963 \begin_inset Flex Code
10964 status collapsed
10965
10966 \begin_layout Plain Layout
10967 DefaultArg
10968 \end_layout
10969
10970 \end_inset
10971
10972  
10973 \begin_inset Flex Code
10974 status collapsed
10975
10976 \begin_layout Plain Layout
10977 [string]
10978 \end_layout
10979
10980 \end_inset
10981
10982  defines an argument that is inserted if and only if no user-specified arguments
10983  were given, i.
10984 \begin_inset space \thinspace{}
10985 \end_inset
10986
10987 e.
10988 \begin_inset space \space{}
10989 \end_inset
10990
10991 if no argument inset has been inserted (note that also an empty argument
10992  inset omits the DefaultArg).
10993  Multiple arguments need to be separated by comma.
10994 \end_layout
10995
10996 \begin_layout Itemize
10997 \begin_inset Flex Code
10998 status collapsed
10999
11000 \begin_layout Plain Layout
11001 PresetArg
11002 \end_layout
11003
11004 \end_inset
11005
11006  
11007 \begin_inset Flex Code
11008 status collapsed
11009
11010 \begin_layout Plain Layout
11011 [string]
11012 \end_layout
11013
11014 \end_inset
11015
11016  defines an argument that is inserted in any case (alone or in addition
11017  to user-specified arguments).
11018  Multiple arguments need to be separated by comma.
11019 \end_layout
11020
11021 \begin_layout Itemize
11022 \begin_inset Flex Code
11023 status collapsed
11024
11025 \begin_layout Plain Layout
11026 Font
11027 \end_layout
11028
11029 \end_inset
11030
11031  The font used for the argument content, see 
11032 \begin_inset CommandInset ref
11033 LatexCommand ref
11034 reference "sub:Font-description"
11035
11036 \end_inset
11037
11038 .
11039 \end_layout
11040
11041 \begin_layout Itemize
11042 \begin_inset Flex Code
11043 status collapsed
11044
11045 \begin_layout Plain Layout
11046 LabelFont
11047 \end_layout
11048
11049 \end_inset
11050
11051  The font used for the label; see 
11052 \begin_inset CommandInset ref
11053 LatexCommand ref
11054 reference "sub:Font-description"
11055
11056 \end_inset
11057
11058 .
11059 \end_layout
11060
11061 \begin_layout Itemize
11062 \begin_inset Flex Code
11063 status collapsed
11064
11065 \begin_layout Plain Layout
11066 Decoration
11067 \end_layout
11068
11069 \end_inset
11070
11071  [
11072 \begin_inset Flex Code
11073 status collapsed
11074
11075 \begin_layout Plain Layout
11076
11077 \emph on
11078 Classic
11079 \emph default
11080 , Minimalistic, Conglomerate
11081 \end_layout
11082
11083 \end_inset
11084
11085 ] describes the rendering style used for the inset's frame and buttons.
11086 \end_layout
11087
11088 \begin_layout Itemize
11089 \begin_inset Flex Code
11090 status collapsed
11091
11092 \begin_layout Plain Layout
11093 AutoInsert
11094 \end_layout
11095
11096 \end_inset
11097
11098  
11099 \begin_inset Flex Code
11100 status collapsed
11101
11102 \begin_layout Plain Layout
11103 [int=0]
11104 \end_layout
11105
11106 \end_inset
11107
11108  If this is set to 
11109 \begin_inset Flex Code
11110 status collapsed
11111
11112 \begin_layout Plain Layout
11113 1
11114 \end_layout
11115
11116 \end_inset
11117
11118 , this argument is automatically inserted when the respective style is selected.
11119  Currently, only one argument per style\SpecialChar \slash{}
11120 layout can be automatically inserted.
11121 \end_layout
11122
11123 \begin_layout Standard
11124 By default, the text entered in the LyX workarea in the respective layout
11125  is the last (mandatory) argument of a command if the 
11126 \begin_inset Flex Code
11127 status collapsed
11128
11129 \begin_layout Plain Layout
11130 LatexType
11131 \end_layout
11132
11133 \end_inset
11134
11135  is 
11136 \begin_inset Flex Code
11137 status collapsed
11138
11139 \begin_layout Plain Layout
11140 Command
11141 \end_layout
11142
11143 \end_inset
11144
11145 .
11146  However, arguments with the prefix 
11147 \begin_inset Flex Code
11148 status collapsed
11149
11150 \begin_layout Plain Layout
11151 post:
11152 \end_layout
11153
11154 \end_inset
11155
11156  are output after this workarea argument.
11157  Note that post-argument numbering restarts at 1, so the first argument
11158  following the workarea argument is 
11159 \begin_inset Flex Code
11160 status collapsed
11161
11162 \begin_layout Plain Layout
11163 post:1
11164 \end_layout
11165
11166 \end_inset
11167
11168 .
11169  Post-arguments are ignored in any other 
11170 \begin_inset Flex Code
11171 status collapsed
11172
11173 \begin_layout Plain Layout
11174 LatexType
11175 \end_layout
11176
11177 \end_inset
11178
11179  than 
11180 \begin_inset Flex Code
11181 status collapsed
11182
11183 \begin_layout Plain Layout
11184 Command
11185 \end_layout
11186
11187 \end_inset
11188
11189 .
11190 \end_layout
11191
11192 \begin_layout Standard
11193 Arguments for list 
11194 \begin_inset Flex Code
11195 status collapsed
11196
11197 \begin_layout Plain Layout
11198
11199 \backslash
11200 item
11201 \end_layout
11202
11203 \end_inset
11204
11205 s (as in 
11206 \begin_inset Flex Code
11207 status collapsed
11208
11209 \begin_layout Plain Layout
11210
11211 \backslash
11212 item[foo]
11213 \end_layout
11214
11215 \end_inset
11216
11217 ) have the prefix 
11218 \begin_inset Flex Code
11219 status collapsed
11220
11221 \begin_layout Plain Layout
11222 item:
11223 \end_layout
11224
11225 \end_inset
11226
11227  followed by the number (e.
11228 \begin_inset space \thinspace{}
11229 \end_inset
11230
11231 g.
11232 \begin_inset space \space{}
11233 \end_inset
11234
11235
11236 \begin_inset Flex Code
11237 status collapsed
11238
11239 \begin_layout Plain Layout
11240 Argument item:1
11241 \end_layout
11242
11243 \end_inset
11244
11245 )
11246 \end_layout
11247
11248 \end_deeper
11249 \begin_layout Description
11250 \begin_inset Flex Code
11251 status collapsed
11252
11253 \begin_layout Plain Layout
11254 BabelPreamble
11255 \end_layout
11256
11257 \end_inset
11258
11259  Note that this will completely override any prior 
11260 \begin_inset Flex Code
11261 status collapsed
11262
11263 \begin_layout Plain Layout
11264 BabelPreamble
11265 \end_layout
11266
11267 \end_inset
11268
11269  declaration for this style.
11270  Must end with 
11271 \begin_inset Quotes eld
11272 \end_inset
11273
11274
11275 \begin_inset Flex Code
11276 status collapsed
11277
11278 \begin_layout Plain Layout
11279 EndBabelPreamble
11280 \end_layout
11281
11282 \end_inset
11283
11284
11285 \begin_inset Quotes erd
11286 \end_inset
11287
11288 .
11289  See 
11290 \begin_inset CommandInset ref
11291 LatexCommand ref
11292 reference "sub:I18n"
11293
11294 \end_inset
11295
11296  for details on its use.
11297 \end_layout
11298
11299 \begin_layout Description
11300 \begin_inset Flex Code
11301 status collapsed
11302
11303 \begin_layout Plain Layout
11304 BottomSep
11305 \end_layout
11306
11307 \end_inset
11308
11309  [
11310 \begin_inset Flex Code
11311 status collapsed
11312
11313 \begin_layout Plain Layout
11314 float=0
11315 \end_layout
11316
11317 \end_inset
11318
11319 ]
11320 \begin_inset Foot
11321 status collapsed
11322
11323 \begin_layout Plain Layout
11324 Note that a `float' here is a real number, such as: 1.5.
11325 \end_layout
11326
11327 \end_inset
11328
11329  The vertical space with which the last of a chain of paragraphs with this
11330  style is separated from the following paragraph.
11331  If the next paragraph has another style, the separations are not simply
11332  added, but the maximum is taken.
11333 \end_layout
11334
11335 \begin_layout Description
11336 \begin_inset Flex Code
11337 status collapsed
11338
11339 \begin_layout Plain Layout
11340 Category
11341 \end_layout
11342
11343 \end_inset
11344
11345  [
11346 \begin_inset Flex Code
11347 status collapsed
11348
11349 \begin_layout Plain Layout
11350 string
11351 \end_layout
11352
11353 \end_inset
11354
11355 ] The category for this style.
11356  This is used to group related styles in the style combobox on the toolbar.
11357  Any string can be used, but you may want to use existing categories with
11358  your own styles.
11359  
11360 \end_layout
11361
11362 \begin_layout Description
11363 \begin_inset Flex Code
11364 status collapsed
11365
11366 \begin_layout Plain Layout
11367 CommandDepth
11368 \end_layout
11369
11370 \end_inset
11371
11372  Depth of XML command.
11373  Used only with XML-type formats.
11374 \end_layout
11375
11376 \begin_layout Description
11377 \begin_inset Flex Code
11378 status collapsed
11379
11380 \begin_layout Plain Layout
11381 CopyStyle
11382 \end_layout
11383
11384 \end_inset
11385
11386  [
11387 \begin_inset Flex Code
11388 status collapsed
11389
11390 \begin_layout Plain Layout
11391 string
11392 \end_layout
11393
11394 \end_inset
11395
11396 ] Copies all the features of an existing style into the current one.
11397  
11398 \end_layout
11399
11400 \begin_layout Description
11401 \begin_inset Flex Code
11402 status collapsed
11403
11404 \begin_layout Plain Layout
11405 DependsOn
11406 \end_layout
11407
11408 \end_inset
11409
11410  [
11411 \begin_inset Flex Code
11412 status collapsed
11413
11414 \begin_layout Plain Layout
11415 <name>
11416 \end_layout
11417
11418 \end_inset
11419
11420 ] The name of a style whose preamble should be output 
11421 \emph on
11422 before
11423 \emph default
11424  this one.
11425  This allows to ensure some ordering of the preamble snippets when macros
11426  definitions depend on one another.
11427 \begin_inset Foot
11428 status collapsed
11429
11430 \begin_layout Plain Layout
11431 Note that, besides that functionality, there is no way to ensure any ordering
11432  of preambles.
11433  The ordering that you see in a given version of LyX may change without
11434  warning in later versions.
11435 \end_layout
11436
11437 \end_inset
11438
11439
11440 \end_layout
11441
11442 \begin_layout Description
11443 \begin_inset Flex Code
11444 status collapsed
11445
11446 \begin_layout Plain Layout
11447 EndLabeltype
11448 \end_layout
11449
11450 \end_inset
11451
11452  [
11453 \begin_inset Flex Code
11454 status collapsed
11455
11456 \begin_layout Plain Layout
11457
11458 \emph on
11459 No_Label
11460 \emph default
11461 , Box, Filled_Box, Static
11462 \end_layout
11463
11464 \end_inset
11465
11466 ] The type of label that stands at the end of the paragraph (or sequence
11467  of paragraphs if 
11468 \begin_inset Flex Code
11469 status collapsed
11470
11471 \begin_layout Plain Layout
11472 LatexType
11473 \end_layout
11474
11475 \end_inset
11476
11477  is
11478 \begin_inset Newline newline
11479 \end_inset
11480
11481
11482 \begin_inset Flex Code
11483 status collapsed
11484
11485 \begin_layout Plain Layout
11486 Environment
11487 \end_layout
11488
11489 \end_inset
11490
11491
11492 \begin_inset Flex Code
11493 status collapsed
11494
11495 \begin_layout Plain Layout
11496 Item_Environment
11497 \end_layout
11498
11499 \end_inset
11500
11501  or 
11502 \begin_inset Flex Code
11503 status collapsed
11504
11505 \begin_layout Plain Layout
11506 List_Environment
11507 \end_layout
11508
11509 \end_inset
11510
11511 ).
11512  
11513 \begin_inset Flex Code
11514 status collapsed
11515
11516 \begin_layout Plain Layout
11517 No_Label
11518 \end_layout
11519
11520 \end_inset
11521
11522  means 
11523 \begin_inset Quotes eld
11524 \end_inset
11525
11526 nothing
11527 \begin_inset Quotes erd
11528 \end_inset
11529
11530
11531 \begin_inset Flex Code
11532 status collapsed
11533
11534 \begin_layout Plain Layout
11535 Box
11536 \end_layout
11537
11538 \end_inset
11539
11540  (resp.
11541 \begin_inset space \space{}
11542 \end_inset
11543
11544
11545 \begin_inset Flex Code
11546 status collapsed
11547
11548 \begin_layout Plain Layout
11549 Filled_Box
11550 \end_layout
11551
11552 \end_inset
11553
11554 ) is a white (resp.
11555 \begin_inset space ~
11556 \end_inset
11557
11558 black) square suitable for end of proof markers, 
11559 \begin_inset Flex Code
11560 status collapsed
11561
11562 \begin_layout Plain Layout
11563 Static
11564 \end_layout
11565
11566 \end_inset
11567
11568  is an explicit text string.
11569 \end_layout
11570
11571 \begin_layout Description
11572 \begin_inset Flex Code
11573 status collapsed
11574
11575 \begin_layout Plain Layout
11576 EndLabelString
11577 \end_layout
11578
11579 \end_inset
11580
11581  [
11582 \begin_inset Flex Code
11583 status collapsed
11584
11585 \begin_layout Plain Layout
11586 string=""
11587 \end_layout
11588
11589 \end_inset
11590
11591 ] The string used for a label with a 
11592 \begin_inset Flex Code
11593 status collapsed
11594
11595 \begin_layout Plain Layout
11596 Static
11597 \end_layout
11598
11599 \end_inset
11600
11601
11602 \begin_inset Newline newline
11603 \end_inset
11604
11605
11606 \begin_inset Flex Code
11607 status collapsed
11608
11609 \begin_layout Plain Layout
11610 EndLabelType
11611 \end_layout
11612
11613 \end_inset
11614
11615 .
11616  
11617 \end_layout
11618
11619 \begin_layout Description
11620 \begin_inset Flex Code
11621 status collapsed
11622
11623 \begin_layout Plain Layout
11624 Font
11625 \end_layout
11626
11627 \end_inset
11628
11629  The font used for both the text body 
11630 \emph on
11631 and
11632 \emph default
11633  the label.
11634  See 
11635 \begin_inset CommandInset ref
11636 LatexCommand ref
11637 reference "sub:Font-description"
11638
11639 \end_inset
11640
11641 .
11642  Note that defining this font automatically defines the 
11643 \begin_inset Flex Code
11644 status collapsed
11645
11646 \begin_layout Plain Layout
11647 LabelFont
11648 \end_layout
11649
11650 \end_inset
11651
11652  to the same value.
11653  So you should define this one first if you also want to define 
11654 \begin_inset Flex Code
11655 status collapsed
11656
11657 \begin_layout Plain Layout
11658 LabelFont
11659 \end_layout
11660
11661 \end_inset
11662
11663 .
11664 \end_layout
11665
11666 \begin_layout Description
11667 \begin_inset Flex Code
11668 status collapsed
11669
11670 \begin_layout Plain Layout
11671 ForceLocal
11672 \end_layout
11673
11674 \end_inset
11675
11676  [
11677 \begin_inset Flex Code
11678 status collapsed
11679
11680 \begin_layout Plain Layout
11681 int=0
11682 \end_layout
11683
11684 \end_inset
11685
11686 ] Used for backporting new styles to stable LyX versions.
11687  The first stable version that supports this tag is LyX 2.1.0.
11688  The argument is a number which may either be 0, -1 or any value greater
11689  than zero.
11690  If the 
11691 \begin_inset Flex Code
11692 status collapsed
11693
11694 \begin_layout Plain Layout
11695 ForceLocal
11696 \end_layout
11697
11698 \end_inset
11699
11700  flag of a style is greater than zero, it will always be written to the
11701  document header.
11702  If a .lyx file is read, the style definitions from the document header are
11703  added to the document class.
11704  Therefore even older LyX versions can handle the style.
11705  The argument of 
11706 \begin_inset Flex Code
11707 status collapsed
11708
11709 \begin_layout Plain Layout
11710 ForceLocal
11711 \end_layout
11712
11713 \end_inset
11714
11715  is a version number: If the style is read, and the version number is less
11716  than the version number of the already existing style in the document class,
11717  the new style is ignored.
11718  If the version number is greater, the new style replaces the existing style.
11719  A value of -1 means an infinite version number, i.
11720 \begin_inset space \thinspace{}
11721 \end_inset
11722
11723 e.
11724 \begin_inset space \space{}
11725 \end_inset
11726
11727 the style is always used.
11728 \end_layout
11729
11730 \begin_layout Description
11731 \begin_inset Flex Code
11732 status collapsed
11733
11734 \begin_layout Plain Layout
11735 FreeSpacing
11736 \end_layout
11737
11738 \end_inset
11739
11740  [
11741 \begin_inset Flex Code
11742 status collapsed
11743
11744 \begin_layout Plain Layout
11745
11746 \emph on
11747 0
11748 \end_layout
11749
11750 \end_inset
11751
11752 ,
11753 \begin_inset space \thinspace{}
11754 \end_inset
11755
11756
11757 \begin_inset Flex Code
11758 status collapsed
11759
11760 \begin_layout Plain Layout
11761 1
11762 \end_layout
11763
11764 \end_inset
11765
11766 ] Usually LyX does not allow you to insert more than one space between words,
11767  since a space is considered as the separation between two words, not a
11768  character or symbol of its own.
11769  This is a very fine thing but sometimes annoying, for example, when typing
11770  program code or plain LaTeX code.
11771  For this reason, 
11772 \begin_inset Flex Code
11773 status collapsed
11774
11775 \begin_layout Plain Layout
11776 FreeSpacing
11777 \end_layout
11778
11779 \end_inset
11780
11781  can be enabled.
11782  Note that LyX will create protected blanks for the additional blanks when
11783  in another mode than LaTeX-mode.
11784 \end_layout
11785
11786 \begin_layout Description
11787 \begin_inset Flex Code
11788 status collapsed
11789
11790 \begin_layout Plain Layout
11791 HTML*
11792 \end_layout
11793
11794 \end_inset
11795
11796  These tags are used with XHTML output.
11797  See 
11798 \begin_inset CommandInset ref
11799 LatexCommand ref
11800 reference "sub:Paragraph-Style-XHTML"
11801
11802 \end_inset
11803
11804 .
11805 \end_layout
11806
11807 \begin_layout Description
11808 \begin_inset Flex Code
11809 status collapsed
11810
11811 \begin_layout Plain Layout
11812 InnerTag
11813 \end_layout
11814
11815 \end_inset
11816
11817  [FIXME] (Used only with XML-type formats.)
11818 \end_layout
11819
11820 \begin_layout Description
11821 \begin_inset Flex Code
11822 status collapsed
11823
11824 \begin_layout Plain Layout
11825 InPreamble
11826 \end_layout
11827
11828 \end_inset
11829
11830  [
11831 \begin_inset Flex Code
11832 status collapsed
11833
11834 \begin_layout Plain Layout
11835
11836 \emph on
11837 0
11838 \end_layout
11839
11840 \end_inset
11841
11842 ,
11843 \begin_inset space \thinspace{}
11844 \end_inset
11845
11846
11847 \begin_inset Flex Code
11848 status collapsed
11849
11850 \begin_layout Plain Layout
11851 1
11852 \end_layout
11853
11854 \end_inset
11855
11856 ] If 
11857 \begin_inset Flex Code
11858 status collapsed
11859
11860 \begin_layout Plain Layout
11861 1
11862 \end_layout
11863
11864 \end_inset
11865
11866 , marks the style as to be included in the document preamble and not in
11867  the document body.
11868  This is useful for document classes that want such information as the title
11869  and author to appear in the preamble.
11870  Note that this works only for styles for which the 
11871 \begin_inset Flex Code
11872 status collapsed
11873
11874 \begin_layout Plain Layout
11875 LatexType
11876 \end_layout
11877
11878 \end_inset
11879
11880  is 
11881 \begin_inset Flex Code
11882 status collapsed
11883
11884 \begin_layout Plain Layout
11885 Command
11886 \end_layout
11887
11888 \end_inset
11889
11890  or 
11891 \begin_inset Flex Code
11892 status collapsed
11893
11894 \begin_layout Plain Layout
11895 Paragraph
11896 \end_layout
11897
11898 \end_inset
11899
11900 .
11901 \end_layout
11902
11903 \begin_layout Description
11904 \begin_inset Flex Code
11905 status collapsed
11906
11907 \begin_layout Plain Layout
11908 InTitle
11909 \end_layout
11910
11911 \end_inset
11912
11913  [
11914 \begin_inset Flex Code
11915 status collapsed
11916
11917 \begin_layout Plain Layout
11918
11919 \emph on
11920 0
11921 \end_layout
11922
11923 \end_inset
11924
11925 ,
11926 \begin_inset space \thinspace{}
11927 \end_inset
11928
11929
11930 \begin_inset Flex Code
11931 status collapsed
11932
11933 \begin_layout Plain Layout
11934 1
11935 \end_layout
11936
11937 \end_inset
11938
11939 ] If 
11940 \begin_inset Flex Code
11941 status collapsed
11942
11943 \begin_layout Plain Layout
11944 1
11945 \end_layout
11946
11947 \end_inset
11948
11949 , marks the style as being part of a title block (see also the 
11950 \begin_inset Flex Code
11951 status collapsed
11952
11953 \begin_layout Plain Layout
11954 TitleLatexType
11955 \end_layout
11956
11957 \end_inset
11958
11959  and 
11960 \begin_inset Flex Code
11961 status collapsed
11962
11963 \begin_layout Plain Layout
11964 TitleLatexName
11965 \end_layout
11966
11967 \end_inset
11968
11969  global entries).
11970 \end_layout
11971
11972 \begin_layout Description
11973 \begin_inset Flex Code
11974 status collapsed
11975
11976 \begin_layout Plain Layout
11977 ItemCommand
11978 \end_layout
11979
11980 \end_inset
11981
11982  [
11983 \begin_inset Flex Code
11984 status collapsed
11985
11986 \begin_layout Plain Layout
11987 string="item"
11988 \end_layout
11989
11990 \end_inset
11991
11992 ] The LaTeX command sequence declaring an item in a list.
11993  The command is to be defined without the preceding backslash (the default
11994  is 
11995 \begin_inset Quotes eld
11996 \end_inset
11997
11998 item
11999 \begin_inset Quotes erd
12000 \end_inset
12001
12002 , resulting in 
12003 \begin_inset Flex Code
12004 status collapsed
12005
12006 \begin_layout Plain Layout
12007
12008 \backslash
12009 item
12010 \end_layout
12011
12012 \end_inset
12013
12014  in the LaTeX output).
12015 \end_layout
12016
12017 \begin_layout Description
12018 \begin_inset Flex Code
12019 status collapsed
12020
12021 \begin_layout Plain Layout
12022 ItemSep
12023 \end_layout
12024
12025 \end_inset
12026
12027  [
12028 \begin_inset Flex Code
12029 status collapsed
12030
12031 \begin_layout Plain Layout
12032 float=0
12033 \end_layout
12034
12035 \end_inset
12036
12037 ] This provides extra space between paragraphs that have the same style.
12038  If you put other styles into an environment, each is separated with the
12039  environment's 
12040 \begin_inset Flex Code
12041 status collapsed
12042
12043 \begin_layout Plain Layout
12044 ParSep
12045 \end_layout
12046
12047 \end_inset
12048
12049 .
12050  But the whole items of the environment are additionally separated with
12051  this 
12052 \begin_inset Flex Code
12053 status collapsed
12054
12055 \begin_layout Plain Layout
12056 ItemSep
12057 \end_layout
12058
12059 \end_inset
12060
12061 .
12062  Note that this is a
12063 \emph on
12064  multiplier.
12065 \end_layout
12066
12067 \begin_layout Description
12068 \begin_inset Flex Code
12069 status collapsed
12070
12071 \begin_layout Plain Layout
12072 ItemTag
12073 \end_layout
12074
12075 \end_inset
12076
12077  [FIXME] (Used only with XML-type formats.)
12078 \end_layout
12079
12080 \begin_layout Description
12081 \begin_inset Flex Code
12082 status collapsed
12083
12084 \begin_layout Plain Layout
12085 KeepEmpty
12086 \end_layout
12087
12088 \end_inset
12089
12090  [
12091 \begin_inset Flex Code
12092 status collapsed
12093
12094 \begin_layout Plain Layout
12095
12096 \emph on
12097 0
12098 \end_layout
12099
12100 \end_inset
12101
12102 ,
12103 \begin_inset space \thinspace{}
12104 \end_inset
12105
12106
12107 \begin_inset Flex Code
12108 status collapsed
12109
12110 \begin_layout Plain Layout
12111 1
12112 \end_layout
12113
12114 \end_inset
12115
12116 ] Usually LyX does not allow you to leave a paragraph empty, since it would
12117  lead to empty LaTeX output.
12118  There are some cases where this could be desirable however: in a letter
12119  template, the required fields can be provided as empty fields, so that
12120  people do not forget them; in some special classes, a style can be used
12121  as some kind of break, which does not contain actual text.
12122 \end_layout
12123
12124 \begin_layout Description
12125 \begin_inset Flex Code
12126 status collapsed
12127
12128 \begin_layout Plain Layout
12129 LabelBottomsep
12130 \end_layout
12131
12132 \end_inset
12133
12134  [
12135 \begin_inset Flex Code
12136 status collapsed
12137
12138 \begin_layout Plain Layout
12139 float=0
12140 \end_layout
12141
12142 \end_inset
12143
12144 ] The vertical space between the label and the text body.
12145  Only used for labels that are above the text body (
12146 \begin_inset Flex Code
12147 status collapsed
12148
12149 \begin_layout Plain Layout
12150 Top_Environment
12151 \end_layout
12152
12153 \end_inset
12154
12155  and
12156 \begin_inset Newline newline
12157 \end_inset
12158
12159
12160 \begin_inset Flex Code
12161 status collapsed
12162
12163 \begin_layout Plain Layout
12164 Centered_Top_Environment
12165 \end_layout
12166
12167 \end_inset
12168
12169 ).
12170 \end_layout
12171
12172 \begin_layout Description
12173 \begin_inset Flex Code
12174 status collapsed
12175
12176 \begin_layout Plain Layout
12177 LabelCounter
12178 \end_layout
12179
12180 \end_inset
12181
12182  [
12183 \begin_inset Flex Code
12184 status collapsed
12185
12186 \begin_layout Plain Layout
12187 string=""
12188 \end_layout
12189
12190 \end_inset
12191
12192 ] The name of the counter for automatic numbering.
12193  In order to have the counter appear with your label, you will need to reference
12194  it in the 
12195 \begin_inset Flex Code
12196 status collapsed
12197
12198 \begin_layout Plain Layout
12199
12200 \family typewriter
12201 LabelString
12202 \end_layout
12203
12204 \end_inset
12205
12206 .
12207  This will work with 
12208 \begin_inset Flex Code
12209 status collapsed
12210
12211 \begin_layout Plain Layout
12212 LabelType
12213 \end_layout
12214
12215 \end_inset
12216
12217 s, 
12218 \begin_inset Flex Code
12219 status collapsed
12220
12221 \begin_layout Plain Layout
12222 Static
12223 \end_layout
12224
12225 \end_inset
12226
12227
12228 \begin_inset Flex Code
12229 status collapsed
12230
12231 \begin_layout Plain Layout
12232 Above
12233 \end_layout
12234
12235 \end_inset
12236
12237  and 
12238 \begin_inset Flex Code
12239 status collapsed
12240
12241 \begin_layout Plain Layout
12242 Centered
12243 \end_layout
12244
12245 \end_inset
12246
12247 , at least.
12248 \begin_inset Newline newline
12249 \end_inset
12250
12251 This 
12252 \emph on
12253 may
12254 \emph default
12255  also be given if 
12256 \begin_inset Flex Code
12257 status collapsed
12258
12259 \begin_layout Plain Layout
12260 LabelType
12261 \end_layout
12262
12263 \end_inset
12264
12265  is 
12266 \begin_inset Flex Code
12267 status collapsed
12268
12269 \begin_layout Plain Layout
12270 Enumerate
12271 \end_layout
12272
12273 \end_inset
12274
12275 , though this case is a bit complicated.
12276  Suppose you declare 
12277 \begin_inset Quotes eld
12278 \end_inset
12279
12280
12281 \begin_inset Flex Code
12282 status collapsed
12283
12284 \begin_layout Plain Layout
12285 LabelCounter myenum
12286 \end_layout
12287
12288 \end_inset
12289
12290
12291 \begin_inset Quotes erd
12292 \end_inset
12293
12294 .
12295  Then the actual counters used are 
12296 \begin_inset Flex Code
12297 status collapsed
12298
12299 \begin_layout Plain Layout
12300 myenumi
12301 \end_layout
12302
12303 \end_inset
12304
12305
12306 \begin_inset Flex Code
12307 status collapsed
12308
12309 \begin_layout Plain Layout
12310 myenumii
12311 \end_layout
12312
12313 \end_inset
12314
12315
12316 \begin_inset Flex Code
12317 status collapsed
12318
12319 \begin_layout Plain Layout
12320 myenumiii
12321 \end_layout
12322
12323 \end_inset
12324
12325  and 
12326 \begin_inset Flex Code
12327 status collapsed
12328
12329 \begin_layout Plain Layout
12330 myenumiv
12331 \end_layout
12332
12333 \end_inset
12334
12335 , much as in LaTeX.
12336  These counters must all be declared separately.
12337 \begin_inset Newline newline
12338 \end_inset
12339
12340 See 
12341 \begin_inset CommandInset ref
12342 LatexCommand ref
12343 reference "sub:Counters"
12344
12345 \end_inset
12346
12347  for details on counters.
12348 \end_layout
12349
12350 \begin_layout Description
12351 \begin_inset Flex Code
12352 status collapsed
12353
12354 \begin_layout Plain Layout
12355 LabelFont
12356 \end_layout
12357
12358 \end_inset
12359
12360  The font used for the label.
12361  See 
12362 \begin_inset CommandInset ref
12363 LatexCommand ref
12364 reference "sub:Font-description"
12365
12366 \end_inset
12367
12368 .
12369 \end_layout
12370
12371 \begin_layout Description
12372 \begin_inset Flex Code
12373 status collapsed
12374
12375 \begin_layout Plain Layout
12376 LabelIndent
12377 \end_layout
12378
12379 \end_inset
12380
12381  [
12382 \begin_inset Flex Code
12383 status collapsed
12384
12385 \begin_layout Plain Layout
12386 string=""
12387 \end_layout
12388
12389 \end_inset
12390
12391 ] Text that indicates how far a label should be indented.
12392 \end_layout
12393
12394 \begin_layout Description
12395 \begin_inset Flex Code
12396 status collapsed
12397
12398 \begin_layout Plain Layout
12399 LabelSep
12400 \end_layout
12401
12402 \end_inset
12403
12404  [
12405 \begin_inset Flex Code
12406 status collapsed
12407
12408 \begin_layout Plain Layout
12409 string=""
12410 \end_layout
12411
12412 \end_inset
12413
12414 ] Text that indicates the amount of horizontal space between the label and
12415  the text body.
12416  Only used for labels that are not above the text body.
12417 \end_layout
12418
12419 \begin_layout Description
12420 \begin_inset Flex Code
12421 status collapsed
12422
12423 \begin_layout Plain Layout
12424 LabelString
12425 \end_layout
12426
12427 \end_inset
12428
12429  [
12430 \begin_inset Flex Code
12431 status collapsed
12432
12433 \begin_layout Plain Layout
12434 string=""
12435 \end_layout
12436
12437 \end_inset
12438
12439 ] The string used for the label.
12440  When 
12441 \begin_inset Flex Code
12442 status collapsed
12443
12444 \begin_layout Plain Layout
12445 LabelCounter
12446 \end_layout
12447
12448 \end_inset
12449
12450  is set, this string can be contain the special formatting commands described
12451  in 
12452 \begin_inset CommandInset ref
12453 LatexCommand ref
12454 reference "sub:Counters"
12455
12456 \end_inset
12457
12458 .
12459 \end_layout
12460
12461 \begin_layout Description
12462 \begin_inset Flex Code
12463 status collapsed
12464
12465 \begin_layout Plain Layout
12466 LabelStringAppendix
12467 \end_layout
12468
12469 \end_inset
12470
12471  [
12472 \begin_inset Flex Code
12473 status collapsed
12474
12475 \begin_layout Plain Layout
12476 string=""
12477 \end_layout
12478
12479 \end_inset
12480
12481 ] This is used inside the appendix instead of
12482 \begin_inset Newline newline
12483 \end_inset
12484
12485
12486 \begin_inset Flex Code
12487 status collapsed
12488
12489 \begin_layout Plain Layout
12490 LabelString
12491 \end_layout
12492
12493 \end_inset
12494
12495 .
12496  Note that every 
12497 \begin_inset Flex Code
12498 status collapsed
12499
12500 \begin_layout Plain Layout
12501 LabelString
12502 \end_layout
12503
12504 \end_inset
12505
12506  statement resets
12507 \begin_inset Newline newline
12508 \end_inset
12509
12510
12511 \begin_inset Flex Code
12512 status collapsed
12513
12514 \begin_layout Plain Layout
12515 LabelStringAppendix
12516 \end_layout
12517
12518 \end_inset
12519
12520  too.
12521 \end_layout
12522
12523 \begin_layout Description
12524 \begin_inset Flex Code
12525 status collapsed
12526
12527 \begin_layout Plain Layout
12528 LabelTag
12529 \end_layout
12530
12531 \end_inset
12532
12533  [FIXME] (Used only with XML-type formats.)
12534 \end_layout
12535
12536 \begin_layout Description
12537 \begin_inset Flex Code
12538 status collapsed
12539
12540 \begin_layout Plain Layout
12541 LabelType
12542 \end_layout
12543
12544 \end_inset
12545
12546  [
12547 \begin_inset Flex Code
12548 status collapsed
12549
12550 \begin_layout Plain Layout
12551
12552 \emph on
12553 No_Label
12554 \emph default
12555 , Manual, Static, Above, 
12556 \begin_inset Newline newline
12557 \end_inset
12558
12559 Centered, Sensitive, Enumerate,
12560 \begin_inset Newline newline
12561 \end_inset
12562
12563 Itemize, Bibliography
12564 \end_layout
12565
12566 \end_inset
12567
12568 ]
12569 \begin_inset Separator parbreak
12570 \end_inset
12571
12572
12573 \end_layout
12574
12575 \begin_deeper
12576 \begin_layout Description
12577 \begin_inset Flex Code
12578 status collapsed
12579
12580 \begin_layout Plain Layout
12581 Manual
12582 \end_layout
12583
12584 \end_inset
12585
12586  means the label is the very first word (up to the first real blank).
12587  Use protected spaces if you want more than one word as the label.
12588  
12589 \end_layout
12590
12591 \begin_layout Description
12592 \begin_inset Flex Code
12593 status collapsed
12594
12595 \begin_layout Plain Layout
12596 Static
12597 \end_layout
12598
12599 \end_inset
12600
12601  means the label is simply what is declared as 
12602 \begin_inset Flex Code
12603 status collapsed
12604
12605 \begin_layout Plain Layout
12606 LabelString
12607 \end_layout
12608
12609 \end_inset
12610
12611 .
12612  This will be displayed 
12613 \begin_inset Quotes eld
12614 \end_inset
12615
12616 inline
12617 \begin_inset Quotes erd
12618 \end_inset
12619
12620 , at the beginning of the paragraph.
12621  If the 
12622 \begin_inset Flex Code
12623 status collapsed
12624
12625 \begin_layout Plain Layout
12626 LatexType
12627 \end_layout
12628
12629 \end_inset
12630
12631  is 
12632 \begin_inset Flex Code
12633 status collapsed
12634
12635 \begin_layout Plain Layout
12636 Environment
12637 \end_layout
12638
12639 \end_inset
12640
12641 , then it will be displayed only in the first paragraph of any sequence
12642  of paragraphs with the same 
12643 \begin_inset Flex Code
12644 status collapsed
12645
12646 \begin_layout Plain Layout
12647 Style
12648 \end_layout
12649
12650 \end_inset
12651
12652 .
12653 \end_layout
12654
12655 \begin_layout Description
12656 \begin_inset Flex Code
12657 status collapsed
12658
12659 \begin_layout Plain Layout
12660 Above
12661 \end_layout
12662
12663 \end_inset
12664
12665
12666 \begin_inset space ~
12667 \end_inset
12668
12669 and
12670 \begin_inset space ~
12671 \end_inset
12672
12673
12674 \begin_inset Flex Code
12675 status collapsed
12676
12677 \begin_layout Plain Layout
12678 Centered
12679 \end_layout
12680
12681 \end_inset
12682
12683  are special cases of 
12684 \begin_inset Flex Code
12685 status collapsed
12686
12687 \begin_layout Plain Layout
12688 Static
12689 \end_layout
12690
12691 \end_inset
12692
12693 .
12694  The label will be printed above the paragraph either at the beginning of
12695  the line or centered.
12696 \end_layout
12697
12698 \begin_layout Description
12699 \begin_inset Flex Code
12700 status collapsed
12701
12702 \begin_layout Plain Layout
12703 Sensitive
12704 \end_layout
12705
12706 \end_inset
12707
12708  is a special case for the caption-labels 
12709 \begin_inset Quotes eld
12710 \end_inset
12711
12712 Figure
12713 \begin_inset Quotes erd
12714 \end_inset
12715
12716  and 
12717 \begin_inset Quotes eld
12718 \end_inset
12719
12720 Table
12721 \begin_inset Quotes erd
12722 \end_inset
12723
12724 .
12725 \begin_inset Newline newline
12726 \end_inset
12727
12728
12729 \begin_inset Flex Code
12730 status collapsed
12731
12732 \begin_layout Plain Layout
12733 Sensitive
12734 \end_layout
12735
12736 \end_inset
12737
12738  means the (hardcoded) label string depends on the kind of float: It is
12739  hardcoded to be `FloatType N', where N is the value of the counter associated
12740  with the float.
12741  For the case that a caption is inserted outside of a float the 
12742 \begin_inset Flex Code
12743 status collapsed
12744
12745 \begin_layout Plain Layout
12746 LabelString
12747 \end_layout
12748
12749 \end_inset
12750
12751  will appear as 
12752 \begin_inset Quotes eld
12753 \end_inset
12754
12755 Senseless!
12756 \begin_inset Quotes erd
12757 \end_inset
12758
12759 .
12760 \end_layout
12761
12762 \begin_layout Description
12763 \begin_inset Flex Code
12764 status collapsed
12765
12766 \begin_layout Plain Layout
12767 Enumerate
12768 \end_layout
12769
12770 \end_inset
12771
12772  produces the usual sort of enumeration labels.
12773  At present, it is hardcoded to use Arabic numerals, lowercase letters,
12774  small Roman numerals, and uppercase letters for the four possible depths.
12775 \end_layout
12776
12777 \begin_layout Description
12778 \begin_inset Flex Code
12779 status collapsed
12780
12781 \begin_layout Plain Layout
12782 Itemize
12783 \end_layout
12784
12785 \end_inset
12786
12787  produces various bullets at the different levels.
12788  It is also hardcoded.
12789 \end_layout
12790
12791 \begin_layout Description
12792 \begin_inset Flex Code
12793 status collapsed
12794
12795 \begin_layout Plain Layout
12796 Bibliography
12797 \end_layout
12798
12799 \end_inset
12800
12801  should be used only with 
12802 \begin_inset Flex Code
12803 status collapsed
12804
12805 \begin_layout Plain Layout
12806 LatexType BibEnvironment
12807 \end_layout
12808
12809 \end_inset
12810
12811 .
12812 \end_layout
12813
12814 \end_deeper
12815 \begin_layout Description
12816 \begin_inset Flex Code
12817 status collapsed
12818
12819 \begin_layout Plain Layout
12820 LangPreamble
12821 \end_layout
12822
12823 \end_inset
12824
12825  Note that this will completely override any prior 
12826 \begin_inset Flex Code
12827 status collapsed
12828
12829 \begin_layout Plain Layout
12830 LangPreamble
12831 \end_layout
12832
12833 \end_inset
12834
12835  declaration for this style.
12836  Must end with 
12837 \begin_inset Quotes eld
12838 \end_inset
12839
12840
12841 \begin_inset Flex Code
12842 status collapsed
12843
12844 \begin_layout Plain Layout
12845 EndLangPreamble
12846 \end_layout
12847
12848 \end_inset
12849
12850
12851 \begin_inset Quotes erd
12852 \end_inset
12853
12854 .
12855  See 
12856 \begin_inset CommandInset ref
12857 LatexCommand ref
12858 reference "sub:I18n"
12859
12860 \end_inset
12861
12862  for details on its use.
12863 \end_layout
12864
12865 \begin_layout Description
12866 \begin_inset Flex Code
12867 status collapsed
12868
12869 \begin_layout Plain Layout
12870 LatexName
12871 \end_layout
12872
12873 \end_inset
12874
12875  [
12876 \begin_inset Flex Code
12877 status collapsed
12878
12879 \begin_layout Plain Layout
12880 <name>
12881 \end_layout
12882
12883 \end_inset
12884
12885 ] The name of the corresponding LaTeX stuff.
12886  Either the environment or command name.
12887 \end_layout
12888
12889 \begin_layout Description
12890 \begin_inset Flex Code
12891 status collapsed
12892
12893 \begin_layout Plain Layout
12894 LatexParam
12895 \end_layout
12896
12897 \end_inset
12898
12899  [
12900 \begin_inset Flex Code
12901 status collapsed
12902
12903 \begin_layout Plain Layout
12904 <parameter>
12905 \end_layout
12906
12907 \end_inset
12908
12909 ] An optional parameter for the corresponding 
12910 \begin_inset Flex Code
12911 status collapsed
12912
12913 \begin_layout Plain Layout
12914 LatexName
12915 \end_layout
12916
12917 \end_inset
12918
12919  stuff.
12920  This parameter cannot be changed from within LyX (use 
12921 \begin_inset Flex Code
12922 status collapsed
12923
12924 \begin_layout Plain Layout
12925 Argument
12926 \end_layout
12927
12928 \end_inset
12929
12930  for customizable parameters).
12931  This will be output as is after all LaTeX 
12932 \begin_inset Flex Code
12933 status collapsed
12934
12935 \begin_layout Plain Layout
12936 Argument
12937 \end_layout
12938
12939 \end_inset
12940
12941 s.
12942 \end_layout
12943
12944 \begin_layout Description
12945 \begin_inset Flex Code
12946 status collapsed
12947
12948 \begin_layout Plain Layout
12949 LatexType
12950 \end_layout
12951
12952 \end_inset
12953
12954  [
12955 \begin_inset Flex Code
12956 status collapsed
12957
12958 \begin_layout Plain Layout
12959
12960 \emph on
12961 Paragraph
12962 \emph default
12963 , Command, Environment, Item_Environment,
12964 \begin_inset Newline newline
12965 \end_inset
12966
12967 List_Environment, Bib_Environment
12968 \end_layout
12969
12970 \end_inset
12971
12972 ] How the style should be translated into LaTeX.
12973 \begin_inset Foot
12974 status collapsed
12975
12976 \begin_layout Plain Layout
12977 \begin_inset Flex Code
12978 status collapsed
12979
12980 \begin_layout Plain Layout
12981 LatexType
12982 \end_layout
12983
12984 \end_inset
12985
12986  is perhaps a bit misleading, since these rules apply to SGML classes, too.
12987  Visit the SGML class files for specific examples.
12988 \end_layout
12989
12990 \end_inset
12991
12992
12993 \begin_inset Separator parbreak
12994 \end_inset
12995
12996
12997 \end_layout
12998
12999 \begin_deeper
13000 \begin_layout Description
13001 \begin_inset Flex Code
13002 status collapsed
13003
13004 \begin_layout Plain Layout
13005 Paragraph
13006 \end_layout
13007
13008 \end_inset
13009
13010  means nothing special.
13011 \end_layout
13012
13013 \begin_layout Description
13014 \begin_inset Flex Code
13015 status collapsed
13016
13017 \begin_layout Plain Layout
13018 Command
13019 \end_layout
13020
13021 \end_inset
13022
13023  means 
13024 \begin_inset Flex Code
13025 status collapsed
13026
13027 \begin_layout Plain Layout
13028
13029 \backslash
13030
13031 \emph on
13032 LatexName
13033 \emph default
13034 {\SpecialChar \ldots{}
13035 }
13036 \end_layout
13037
13038 \end_inset
13039
13040 .
13041 \end_layout
13042
13043 \begin_layout Description
13044 \begin_inset Flex Code
13045 status collapsed
13046
13047 \begin_layout Plain Layout
13048 Environment
13049 \end_layout
13050
13051 \end_inset
13052
13053  means 
13054 \begin_inset Flex Code
13055 status collapsed
13056
13057 \begin_layout Plain Layout
13058
13059 \backslash
13060 begin{
13061 \emph on
13062 LatexName
13063 \emph default
13064 }\SpecialChar \ldots{}
13065
13066 \backslash
13067 end{
13068 \emph on
13069 LatexName
13070 \emph default
13071 }
13072 \end_layout
13073
13074 \end_inset
13075
13076 .
13077  
13078 \end_layout
13079
13080 \begin_layout Description
13081 \begin_inset Flex Code
13082 status collapsed
13083
13084 \begin_layout Plain Layout
13085 Item_Environment
13086 \end_layout
13087
13088 \end_inset
13089
13090  is the same as 
13091 \begin_inset Flex Code
13092 status collapsed
13093
13094 \begin_layout Plain Layout
13095 Environment
13096 \end_layout
13097
13098 \end_inset
13099
13100 , except that an 
13101 \begin_inset Flex Code
13102 status collapsed
13103
13104 \begin_layout Plain Layout
13105
13106 \backslash
13107 item
13108 \end_layout
13109
13110 \end_inset
13111
13112  is generated for each paragraph of this environment.
13113  
13114 \end_layout
13115
13116 \begin_layout Description
13117 \begin_inset Flex Code
13118 status collapsed
13119
13120 \begin_layout Plain Layout
13121 List_Environment
13122 \end_layout
13123
13124 \end_inset
13125
13126  is the same as 
13127 \begin_inset Flex Code
13128 status collapsed
13129
13130 \begin_layout Plain Layout
13131 Item_Environment
13132 \end_layout
13133
13134 \end_inset
13135
13136 , except that
13137 \begin_inset Newline newline
13138 \end_inset
13139
13140
13141 \begin_inset Flex Code
13142 status collapsed
13143
13144 \begin_layout Plain Layout
13145 LabelWidthString
13146 \end_layout
13147
13148 \end_inset
13149
13150  is passed as an argument to the environment.
13151 \begin_inset Newline newline
13152 \end_inset
13153
13154
13155 \begin_inset Flex Code
13156 status collapsed
13157
13158 \begin_layout Plain Layout
13159 LabelWidthString
13160 \end_layout
13161
13162 \end_inset
13163
13164  can be defined in the 
13165 \begin_inset Flex MenuItem
13166 status collapsed
13167
13168 \begin_layout Plain Layout
13169 Edit\SpecialChar \menuseparator
13170 Paragraph
13171 \begin_inset space ~
13172 \end_inset
13173
13174 settings
13175 \end_layout
13176
13177 \end_inset
13178
13179  dialog.
13180 \end_layout
13181
13182 \begin_layout Description
13183 \begin_inset Flex Code
13184 status collapsed
13185
13186 \begin_layout Plain Layout
13187 Bib_Environment
13188 \end_layout
13189
13190 \end_inset
13191
13192  is like 
13193 \begin_inset Flex Code
13194 status collapsed
13195
13196 \begin_layout Plain Layout
13197 Environment
13198 \end_layout
13199
13200 \end_inset
13201
13202  but adds additionally the necessary mandatory argument (the longest label)
13203  to the begin statement of the bibliography environment:
13204 \begin_inset Newline newline
13205 \end_inset
13206
13207
13208 \begin_inset Flex Code
13209 status collapsed
13210
13211 \begin_layout Plain Layout
13212
13213 \backslash
13214 begin{thebibliography}{99}
13215 \end_layout
13216
13217 \end_inset
13218
13219  It is therefore only useful for bibliography environments.
13220  The default longest label 
13221 \begin_inset Quotes eld
13222 \end_inset
13223
13224 99
13225 \begin_inset Quotes erd
13226 \end_inset
13227
13228  can be changed by the user in the paragraph settings of a bibliography
13229  item.
13230 \end_layout
13231
13232 \begin_layout Standard
13233 Putting the last few things together, the LaTeX output will be either: 
13234 \end_layout
13235
13236 \begin_layout LyX-Code
13237
13238 \backslash
13239 LatexName[LatexParam]{\SpecialChar \ldots{}
13240 }
13241 \end_layout
13242
13243 \begin_layout Standard
13244 or: 
13245 \end_layout
13246
13247 \begin_layout LyX-Code
13248
13249 \backslash
13250 begin{LatexName}[LatexParam] \SpecialChar \ldots{}
13251  
13252 \backslash
13253 end{LatexName}.
13254 \end_layout
13255
13256 \begin_layout Standard
13257 depending upon the LaTeX type.
13258 \end_layout
13259
13260 \end_deeper
13261 \begin_layout Description
13262 \begin_inset Flex Code
13263 status collapsed
13264
13265 \begin_layout Plain Layout
13266 LeftDelim
13267 \end_layout
13268
13269 \end_inset
13270
13271  [
13272 \begin_inset Flex Code
13273 status collapsed
13274
13275 \begin_layout Plain Layout
13276 string
13277 \end_layout
13278
13279 \end_inset
13280
13281 ] A string that is put at the beginning of the style content.
13282  A line break in the output can be indicated by 
13283 \begin_inset Flex Code
13284 status collapsed
13285
13286 \begin_layout Plain Layout
13287 <br/>
13288 \end_layout
13289
13290 \end_inset
13291
13292 .
13293 \end_layout
13294
13295 \begin_layout Description
13296 \begin_inset Flex Code
13297 status collapsed
13298
13299 \begin_layout Plain Layout
13300 LeftMargin
13301 \end_layout
13302
13303 \end_inset
13304
13305  [
13306 \begin_inset Flex Code
13307 status collapsed
13308
13309 \begin_layout Plain Layout
13310 string=""
13311 \end_layout
13312
13313 \end_inset
13314
13315 ] If you put styles into environments, the different 
13316 \begin_inset Flex Code
13317 status collapsed
13318
13319 \begin_layout Plain Layout
13320 LeftMargin
13321 \end_layout
13322
13323 \end_inset
13324
13325  are not simply added, but added with a factor 
13326 \begin_inset Formula $\frac{4}{\mathrm{depth}+4}$
13327 \end_inset
13328
13329 .
13330  Note that this parameter is also used when 
13331 \begin_inset Flex Code
13332 status collapsed
13333
13334 \begin_layout Plain Layout
13335 Margin
13336 \end_layout
13337
13338 \end_inset
13339
13340  is defined as 
13341 \begin_inset Flex Code
13342 status collapsed
13343
13344 \begin_layout Plain Layout
13345 Manual
13346 \end_layout
13347
13348 \end_inset
13349
13350  or 
13351 \begin_inset Flex Code
13352 status collapsed
13353
13354 \begin_layout Plain Layout
13355 Dynamic
13356 \end_layout
13357
13358 \end_inset
13359
13360 .
13361  Then it is added to the manual or dynamic margin.
13362 \begin_inset Newline newline
13363 \end_inset
13364
13365 For example 
13366 \begin_inset Quotes eld
13367 \end_inset
13368
13369
13370 \begin_inset Flex Code
13371 status collapsed
13372
13373 \begin_layout Plain Layout
13374 MM
13375 \end_layout
13376
13377 \end_inset
13378
13379
13380 \begin_inset Quotes erd
13381 \end_inset
13382
13383  means that the paragraph is indented with the width of 
13384 \begin_inset Quotes eld
13385 \end_inset
13386
13387
13388 \begin_inset Flex Code
13389 status collapsed
13390
13391 \begin_layout Plain Layout
13392 MM
13393 \end_layout
13394
13395 \end_inset
13396
13397
13398 \begin_inset Quotes erd
13399 \end_inset
13400
13401  in the normal font.
13402  You can get a negative width by prefixing the string with 
13403 \begin_inset Quotes eld
13404 \end_inset
13405
13406
13407 \begin_inset Flex Code
13408 status collapsed
13409
13410 \begin_layout Plain Layout
13411 -
13412 \end_layout
13413
13414 \end_inset
13415
13416
13417 \begin_inset Quotes erd
13418 \end_inset
13419
13420 .
13421  This way was chosen so that the look is the same with each used screen
13422  font.
13423 \end_layout
13424
13425 \begin_layout Description
13426 \begin_inset Flex Code
13427 status collapsed
13428
13429 \begin_layout Plain Layout
13430 Margin
13431 \end_layout
13432
13433 \end_inset
13434
13435  [
13436 \begin_inset Flex Code
13437 status collapsed
13438
13439 \begin_layout Plain Layout
13440
13441 \emph on
13442 Static
13443 \emph default
13444 , Manual, Dynamic, First_Dynamic, Right_Address_Box
13445 \end_layout
13446
13447 \end_inset
13448
13449
13450 \begin_inset Newline newline
13451 \end_inset
13452
13453 The kind of margin that the style has on the left side.
13454 \begin_inset Separator parbreak
13455 \end_inset
13456
13457
13458 \end_layout
13459
13460 \begin_deeper
13461 \begin_layout Description
13462 \begin_inset Flex Code
13463 status collapsed
13464
13465 \begin_layout Plain Layout
13466 Static
13467 \end_layout
13468
13469 \end_inset
13470
13471  just means a fixed margin.
13472 \end_layout
13473
13474 \begin_layout Description
13475 \begin_inset Flex Code
13476 status collapsed
13477
13478 \begin_layout Plain Layout
13479 Manual
13480 \end_layout
13481
13482 \end_inset
13483
13484  means that the left margin depends on the string entered in the 
13485 \begin_inset Flex MenuItem
13486 status collapsed
13487
13488 \begin_layout Plain Layout
13489 Edit\SpecialChar \menuseparator
13490 Paragraph
13491 \begin_inset space ~
13492 \end_inset
13493
13494 Settings
13495 \end_layout
13496
13497 \end_inset
13498
13499  dialog.
13500  This is used to typeset nice lists without tabulators.
13501 \end_layout
13502
13503 \begin_layout Description
13504 \begin_inset Flex Code
13505 status collapsed
13506
13507 \begin_layout Plain Layout
13508 Dynamic
13509 \end_layout
13510
13511 \end_inset
13512
13513  means that the margin depends on the size of the label.
13514  This is used for automatic enumerated headlines.
13515  It is obvious that the headline 
13516 \begin_inset Quotes eld
13517 \end_inset
13518
13519 5.4.3.2.1 Very long headline
13520 \begin_inset Quotes erd
13521 \end_inset
13522
13523  must have a wider left margin (as wide as 
13524 \begin_inset Quotes eld
13525 \end_inset
13526
13527 5.4.3.2.1
13528 \begin_inset Quotes erd
13529 \end_inset
13530
13531  plus the space) than 
13532 \begin_inset Quotes eld
13533 \end_inset
13534
13535 3.2 Very long headline
13536 \begin_inset Quotes erd
13537 \end_inset
13538
13539 , even if standard 
13540 \begin_inset Quotes eld
13541 \end_inset
13542
13543 word processors
13544 \begin_inset Quotes erd
13545 \end_inset
13546
13547  are not able to do this.
13548 \end_layout
13549
13550 \begin_layout Description
13551 \begin_inset Flex Code
13552 status collapsed
13553
13554 \begin_layout Plain Layout
13555 First_Dynamic
13556 \end_layout
13557
13558 \end_inset
13559
13560  is similar, but only the very first row of the paragraph is dynamic, while
13561  the others are static; this is used, for example, for descriptions.
13562 \end_layout
13563
13564 \begin_layout Description
13565 \begin_inset Flex Code
13566 status collapsed
13567
13568 \begin_layout Plain Layout
13569 Right_Address_Box
13570 \end_layout
13571
13572 \end_inset
13573
13574  means the margin is chosen in a way that the longest row of this paragraph
13575  fits to the right margin.
13576  This is used to typeset an address on the right edge of the page.
13577 \end_layout
13578
13579 \end_deeper
13580 \begin_layout Description
13581 \begin_inset Flex Code
13582 status collapsed
13583
13584 \begin_layout Plain Layout
13585 NeedProtect
13586 \end_layout
13587
13588 \end_inset
13589
13590  [
13591 \begin_inset Flex Code
13592 status collapsed
13593
13594 \begin_layout Plain Layout
13595
13596 \emph on
13597 0
13598 \end_layout
13599
13600 \end_inset
13601
13602 ,
13603 \begin_inset space \thinspace{}
13604 \end_inset
13605
13606
13607 \begin_inset Flex Code
13608 status collapsed
13609
13610 \begin_layout Plain Layout
13611 1
13612 \end_layout
13613
13614 \end_inset
13615
13616 ] Whether fragile commands in this style should be 
13617 \begin_inset Flex Code
13618 status collapsed
13619
13620 \begin_layout Plain Layout
13621
13622 \backslash
13623 protect
13624 \end_layout
13625
13626 \end_inset
13627
13628 'ed.
13629  (Note: This is 
13630 \emph on
13631 not
13632 \emph default
13633  whether this command should itself be protected.)
13634 \end_layout
13635
13636 \begin_layout Description
13637 \begin_inset Flex Code
13638 status collapsed
13639
13640 \begin_layout Plain Layout
13641 Newline
13642 \end_layout
13643
13644 \end_inset
13645
13646  [
13647 \begin_inset Flex Code
13648 status collapsed
13649
13650 \begin_layout Plain Layout
13651 0
13652 \end_layout
13653
13654 \end_inset
13655
13656 ,
13657 \begin_inset space \thinspace{}
13658 \end_inset
13659
13660
13661 \begin_inset Flex Code
13662 status collapsed
13663
13664 \begin_layout Plain Layout
13665
13666 \emph on
13667 1
13668 \end_layout
13669
13670 \end_inset
13671
13672 ] Whether newlines are translated into LaTeX newlines (
13673 \begin_inset Flex Code
13674 status collapsed
13675
13676 \begin_layout Plain Layout
13677
13678 \backslash
13679
13680 \backslash
13681
13682 \end_layout
13683
13684 \end_inset
13685
13686 ) or not.
13687  The translation can be switched off to allow more comfortable LaTeX editing
13688  inside LyX.
13689 \end_layout
13690
13691 \begin_layout Description
13692 \begin_inset Flex Code
13693 status collapsed
13694
13695 \begin_layout Plain Layout
13696 NextNoIndent
13697 \end_layout
13698
13699 \end_inset
13700
13701  [
13702 \begin_inset Flex Code
13703 status collapsed
13704
13705 \begin_layout Plain Layout
13706
13707 \emph on
13708 0
13709 \end_layout
13710
13711 \end_inset
13712
13713 ,
13714 \begin_inset space \thinspace{}
13715 \end_inset
13716
13717
13718 \begin_inset Flex Code
13719 status collapsed
13720
13721 \begin_layout Plain Layout
13722 1
13723 \end_layout
13724
13725 \end_inset
13726
13727 ] If set to true, and if 
13728 \begin_inset Flex Code
13729 status collapsed
13730
13731 \begin_layout Plain Layout
13732 DefaultStyle
13733 \end_layout
13734
13735 \end_inset
13736
13737  (usually 
13738 \begin_inset Flex Code
13739 status collapsed
13740
13741 \begin_layout Plain Layout
13742 Standard
13743 \end_layout
13744
13745 \end_inset
13746
13747 ) paragraphs are being indented, then the indentation of such a paragraph
13748  following one of this type will be suppressed.
13749  (So this will not affect the display of non-default paragraphs.)
13750 \end_layout
13751
13752 \begin_layout Description
13753 \begin_inset Flex Code
13754 status collapsed
13755
13756 \begin_layout Plain Layout
13757 ObsoletedBy
13758 \end_layout
13759
13760 \end_inset
13761
13762  [
13763 \begin_inset Flex Code
13764 status collapsed
13765
13766 \begin_layout Plain Layout
13767 <name>
13768 \end_layout
13769
13770 \end_inset
13771
13772 ] Name of a style that has replaced this style.
13773  This is used to rename a style, while keeping backward compatibility.
13774 \end_layout
13775
13776 \begin_layout Description
13777 \begin_inset Flex Code
13778 status collapsed
13779
13780 \begin_layout Plain Layout
13781 ParbreakIsNewline
13782 \end_layout
13783
13784 \end_inset
13785
13786  [
13787 \begin_inset Flex Code
13788 status collapsed
13789
13790 \begin_layout Plain Layout
13791
13792 \emph on
13793 0
13794 \end_layout
13795
13796 \end_inset
13797
13798 ,
13799 \begin_inset space \thinspace{}
13800 \end_inset
13801
13802
13803 \begin_inset Flex Code
13804 status collapsed
13805
13806 \begin_layout Plain Layout
13807 1
13808 \end_layout
13809
13810 \end_inset
13811
13812 ] Indicates that paragraphs will not be separated by an empty line in LaTeX
13813  output, but only by a line break; together with 
13814 \begin_inset Flex Code
13815 status collapsed
13816
13817 \begin_layout Plain Layout
13818 PassThru 1
13819 \end_layout
13820
13821 \end_inset
13822
13823 , this allows to emulate a plain text editor (like the ERT inset).
13824 \end_layout
13825
13826 \begin_layout Description
13827 \begin_inset Flex Code
13828 status collapsed
13829
13830 \begin_layout Plain Layout
13831 ParIndent
13832 \end_layout
13833
13834 \end_inset
13835
13836  [
13837 \begin_inset Flex Code
13838 status collapsed
13839
13840 \begin_layout Plain Layout
13841 string=""
13842 \end_layout
13843
13844 \end_inset
13845
13846 ] The indent of the very first line of a paragraph.
13847  The
13848 \begin_inset Newline newline
13849 \end_inset
13850
13851
13852 \begin_inset Flex Code
13853 status collapsed
13854
13855 \begin_layout Plain Layout
13856 Parindent
13857 \end_layout
13858
13859 \end_inset
13860
13861  will be fixed for a certain style.
13862  The exception is the default style, since the indentation for these paragraphs
13863  can be prohibited with 
13864 \begin_inset Flex Code
13865 status collapsed
13866
13867 \begin_layout Plain Layout
13868 NextNoIndent
13869 \end_layout
13870
13871 \end_inset
13872
13873 .
13874  Also, 
13875 \begin_inset Flex Code
13876 status collapsed
13877
13878 \begin_layout Plain Layout
13879 Standard
13880 \end_layout
13881
13882 \end_inset
13883
13884  style paragraphs inside environments use the 
13885 \begin_inset Flex Code
13886 status collapsed
13887
13888 \begin_layout Plain Layout
13889 Parindent
13890 \end_layout
13891
13892 \end_inset
13893
13894  of the environment, not their native one.
13895  For example, 
13896 \begin_inset Flex Code
13897 status collapsed
13898
13899 \begin_layout Plain Layout
13900 Standard
13901 \end_layout
13902
13903 \end_inset
13904
13905  paragraphs inside an enumeration are not indented.
13906 \end_layout
13907
13908 \begin_layout Description
13909 \begin_inset Flex Code
13910 status collapsed
13911
13912 \begin_layout Plain Layout
13913 ParSep
13914 \end_layout
13915
13916 \end_inset
13917
13918  [
13919 \begin_inset Flex Code
13920 status collapsed
13921
13922 \begin_layout Plain Layout
13923 float=0
13924 \end_layout
13925
13926 \end_inset
13927
13928 ] The vertical space between two paragraphs of this style.
13929 \end_layout
13930
13931 \begin_layout Description
13932 \begin_inset Flex Code
13933 status collapsed
13934
13935 \begin_layout Plain Layout
13936 Parskip
13937 \end_layout
13938
13939 \end_inset
13940
13941  [
13942 \begin_inset Flex Code
13943 status collapsed
13944
13945 \begin_layout Plain Layout
13946 float=0
13947 \end_layout
13948
13949 \end_inset
13950
13951 ] LyX allows the user to choose either 
13952 \begin_inset Quotes eld
13953 \end_inset
13954
13955 indent
13956 \begin_inset Quotes erd
13957 \end_inset
13958
13959  or 
13960 \begin_inset Quotes eld
13961 \end_inset
13962
13963 skip
13964 \begin_inset Quotes erd
13965 \end_inset
13966
13967  to separate paragraphs.
13968  When 
13969 \begin_inset Quotes eld
13970 \end_inset
13971
13972 indent
13973 \begin_inset Quotes erd
13974 \end_inset
13975
13976  is chosen, 
13977 \begin_inset Flex Code
13978 status collapsed
13979
13980 \begin_layout Plain Layout
13981 Parskip
13982 \end_layout
13983
13984 \end_inset
13985
13986  is ignored.
13987  When 
13988 \begin_inset Quotes eld
13989 \end_inset
13990
13991 skip
13992 \begin_inset Quotes erd
13993 \end_inset
13994
13995  is chosen, 
13996 \begin_inset Flex Code
13997 status collapsed
13998
13999 \begin_layout Plain Layout
14000 ParIndent
14001 \end_layout
14002
14003 \end_inset
14004
14005  is ignored and all paragraphs are separated by the 
14006 \begin_inset Flex Code
14007 status collapsed
14008
14009 \begin_layout Plain Layout
14010 Parskip
14011 \end_layout
14012
14013 \end_inset
14014
14015  argument.
14016  The vertical space is calculated with 
14017 \begin_inset Flex Code
14018 status collapsed
14019
14020 \begin_layout Plain Layout
14021 Parskip
14022 \begin_inset space ~
14023 \end_inset
14024
14025 * DefaultHeight
14026 \end_layout
14027
14028 \end_inset
14029
14030  where 
14031 \begin_inset Flex Code
14032 status collapsed
14033
14034 \begin_layout Plain Layout
14035 DefaultHeight
14036 \end_layout
14037
14038 \end_inset
14039
14040  is the height of a row with the normal font.
14041  This way, the look stays the same with different screen fonts.
14042 \end_layout
14043
14044 \begin_layout Description
14045 \begin_inset Flex Code
14046 status collapsed
14047
14048 \begin_layout Plain Layout
14049 PassThru
14050 \end_layout
14051
14052 \end_inset
14053
14054  [
14055 \begin_inset Flex Code
14056 status collapsed
14057
14058 \begin_layout Plain Layout
14059
14060 \emph on
14061 0
14062 \end_layout
14063
14064 \end_inset
14065
14066 ,
14067 \begin_inset space \thinspace{}
14068 \end_inset
14069
14070
14071 \begin_inset Flex Code
14072 status collapsed
14073
14074 \begin_layout Plain Layout
14075 1
14076 \end_layout
14077
14078 \end_inset
14079
14080 ] Whether the contents of this paragraph should be output in raw form, meaning
14081  without special translations that LaTeX would require.
14082 \end_layout
14083
14084 \begin_layout Description
14085 \begin_inset Flex Code
14086 status collapsed
14087
14088 \begin_layout Plain Layout
14089 Preamble
14090 \end_layout
14091
14092 \end_inset
14093
14094  Information to be included in the LaTeX preamble when this style is used.
14095  Used to define macros, load packages, etc., required by this particular
14096  style.
14097  Must end with 
14098 \begin_inset Quotes eld
14099 \end_inset
14100
14101
14102 \begin_inset Flex Code
14103 status collapsed
14104
14105 \begin_layout Plain Layout
14106 EndPreamble
14107 \end_layout
14108
14109 \end_inset
14110
14111
14112 \begin_inset Quotes erd
14113 \end_inset
14114
14115 .
14116 \end_layout
14117
14118 \begin_layout Description
14119 \begin_inset Flex Code
14120 status collapsed
14121
14122 \begin_layout Plain Layout
14123 RefPrefix
14124 \end_layout
14125
14126 \end_inset
14127
14128  [
14129 \begin_inset Flex Code
14130 status collapsed
14131
14132 \begin_layout Plain Layout
14133 string
14134 \end_layout
14135
14136 \end_inset
14137
14138 ] The prefix to use when creating labels referring to paragraphs of this
14139  type.
14140  This allows the use of formatted references.
14141 \end_layout
14142
14143 \begin_layout Description
14144 \begin_inset Flex Code
14145 status collapsed
14146
14147 \begin_layout Plain Layout
14148 Requires 
14149 \end_layout
14150
14151 \end_inset
14152
14153  [
14154 \begin_inset Flex Code
14155 status collapsed
14156
14157 \begin_layout Plain Layout
14158 string
14159 \end_layout
14160
14161 \end_inset
14162
14163 ] Whether the style requires the feature 
14164 \begin_inset Flex Code
14165 status collapsed
14166
14167 \begin_layout Plain Layout
14168 string
14169 \end_layout
14170
14171 \end_inset
14172
14173 .
14174  See the description of 
14175 \begin_inset Flex Code
14176 status collapsed
14177
14178 \begin_layout Plain Layout
14179 Provides
14180 \end_layout
14181
14182 \end_inset
14183
14184  above (
14185 \begin_inset CommandInset ref
14186 LatexCommand ref
14187 reference "sub:General-text-class"
14188
14189 \end_inset
14190
14191 ) for information on `features'.
14192 \end_layout
14193
14194 \begin_layout Description
14195 \begin_inset Flex Code
14196 status collapsed
14197
14198 \begin_layout Plain Layout
14199 ResetArgs
14200 \end_layout
14201
14202 \end_inset
14203
14204  [
14205 \begin_inset Flex Code
14206 status collapsed
14207
14208 \begin_layout Plain Layout
14209
14210 \emph on
14211 0
14212 \end_layout
14213
14214 \end_inset
14215
14216 ,
14217 \begin_inset Flex Code
14218 status collapsed
14219
14220 \begin_layout Plain Layout
14221 1
14222 \end_layout
14223
14224 \end_inset
14225
14226 ] Resets the LaTeX arguments of this style (as defined via the 
14227 \begin_inset Flex Code
14228 status collapsed
14229
14230 \begin_layout Plain Layout
14231 Argument
14232 \end_layout
14233
14234 \end_inset
14235
14236  tag).
14237  This is useful if you have copied a style via 
14238 \begin_inset Flex Code
14239 status collapsed
14240
14241 \begin_layout Plain Layout
14242 CopyStyle
14243 \end_layout
14244
14245 \end_inset
14246
14247 , but you do not want to inherit its (required and optional) arguments.
14248 \end_layout
14249
14250 \begin_layout Description
14251 \begin_inset Flex Code
14252 status collapsed
14253
14254 \begin_layout Plain Layout
14255 RightDelim
14256 \end_layout
14257
14258 \end_inset
14259
14260  [
14261 \begin_inset Flex Code
14262 status collapsed
14263
14264 \begin_layout Plain Layout
14265 string
14266 \end_layout
14267
14268 \end_inset
14269
14270 ] A string that is put at the end of the layout content.
14271  A line break in the output can be indicated by 
14272 \begin_inset Flex Code
14273 status collapsed
14274
14275 \begin_layout Plain Layout
14276 <br/>
14277 \end_layout
14278
14279 \end_inset
14280
14281 .
14282 \end_layout
14283
14284 \begin_layout Description
14285 \begin_inset Flex Code
14286 status collapsed
14287
14288 \begin_layout Plain Layout
14289 RightMargin
14290 \end_layout
14291
14292 \end_inset
14293
14294  [
14295 \begin_inset Flex Code
14296 status collapsed
14297
14298 \begin_layout Plain Layout
14299 string=""
14300 \end_layout
14301
14302 \end_inset
14303
14304 ] Similar to 
14305 \begin_inset Flex Code
14306 status collapsed
14307
14308 \begin_layout Plain Layout
14309 LeftMargin
14310 \end_layout
14311
14312 \end_inset
14313
14314 .
14315 \end_layout
14316
14317 \begin_layout Description
14318 \begin_inset Flex Code
14319 status collapsed
14320
14321 \begin_layout Plain Layout
14322 Spacing
14323 \end_layout
14324
14325 \end_inset
14326
14327  [
14328 \begin_inset Flex Code
14329 status collapsed
14330
14331 \begin_layout Plain Layout
14332
14333 \emph on
14334 single
14335 \end_layout
14336
14337 \end_inset
14338
14339
14340 \begin_inset Flex Code
14341 status collapsed
14342
14343 \begin_layout Plain Layout
14344 onehalf
14345 \end_layout
14346
14347 \end_inset
14348
14349
14350 \begin_inset Flex Code
14351 status collapsed
14352
14353 \begin_layout Plain Layout
14354 double
14355 \end_layout
14356
14357 \end_inset
14358
14359
14360 \begin_inset Flex Code
14361 status collapsed
14362
14363 \begin_layout Plain Layout
14364 other
14365 \begin_inset space ~
14366 \end_inset
14367
14368 <value>
14369 \end_layout
14370
14371 \end_inset
14372
14373 ] This defines what the default spacing should be in the style.
14374  The arguments 
14375 \begin_inset Flex Code
14376 status collapsed
14377
14378 \begin_layout Plain Layout
14379 single
14380 \end_layout
14381
14382 \end_inset
14383
14384
14385 \begin_inset Flex Code
14386 status collapsed
14387
14388 \begin_layout Plain Layout
14389 onehalf
14390 \end_layout
14391
14392 \end_inset
14393
14394  and 
14395 \begin_inset Flex Code
14396 status collapsed
14397
14398 \begin_layout Plain Layout
14399 double
14400 \end_layout
14401
14402 \end_inset
14403
14404  correspond respectively to a multiplier value of 1, 1.25 and 1.667.
14405  If you specify the argument 
14406 \begin_inset Flex Code
14407 status collapsed
14408
14409 \begin_layout Plain Layout
14410 other
14411 \end_layout
14412
14413 \end_inset
14414
14415 , then you must also provide a value argument which will be the actual multiplie
14416 r value.
14417  Note that, contrary to other parameters, 
14418 \begin_inset Flex Code
14419 status collapsed
14420
14421 \begin_layout Plain Layout
14422 Spacing
14423 \end_layout
14424
14425 \end_inset
14426
14427  implies the generation of specific LaTeX code, using the LaTeX package
14428  
14429 \family roman
14430
14431 \begin_inset Flex Code
14432 status collapsed
14433
14434 \begin_layout Plain Layout
14435 setspace
14436 \end_layout
14437
14438 \end_inset
14439
14440 .
14441 \end_layout
14442
14443 \begin_layout Description
14444 \begin_inset Flex Code
14445 status collapsed
14446
14447 \begin_layout Plain Layout
14448 Spellcheck
14449 \end_layout
14450
14451 \end_inset
14452
14453  [
14454 \begin_inset Flex Code
14455 status collapsed
14456
14457 \begin_layout Plain Layout
14458 0
14459 \end_layout
14460
14461 \end_inset
14462
14463 ,
14464 \begin_inset space \thinspace{}
14465 \end_inset
14466
14467
14468 \begin_inset Flex Code
14469 status collapsed
14470
14471 \begin_layout Plain Layout
14472
14473 \emph on
14474 1
14475 \end_layout
14476
14477 \end_inset
14478
14479 ] Allow spell-checking paragraphs of this style.
14480  Default is true.
14481 \end_layout
14482
14483 \begin_layout Description
14484 \begin_inset Flex Code
14485 status collapsed
14486
14487 \begin_layout Plain Layout
14488 TextFont
14489 \end_layout
14490
14491 \end_inset
14492
14493  The font used for the text body .
14494  See 
14495 \begin_inset CommandInset ref
14496 LatexCommand ref
14497 reference "sub:Font-description"
14498
14499 \end_inset
14500
14501 .
14502 \end_layout
14503
14504 \begin_layout Description
14505 \begin_inset Flex Code
14506 status collapsed
14507
14508 \begin_layout Plain Layout
14509 TocLevel
14510 \end_layout
14511
14512 \end_inset
14513
14514
14515 \series medium
14516  [
14517 \begin_inset Flex Code
14518 status collapsed
14519
14520 \begin_layout Plain Layout
14521
14522 \series medium
14523 int=3
14524 \end_layout
14525
14526 \end_inset
14527
14528 ]
14529 \series default
14530  The level of the style in the table of contents.
14531  This is used for automatic numbering of section headings.
14532 \change_inserted -712698321 1401363541
14533
14534 \end_layout
14535
14536 \begin_layout Description
14537
14538 \change_inserted -712698321 1401363906
14539 \begin_inset Flex Code
14540 status collapsed
14541
14542 \begin_layout Plain Layout
14543
14544 \change_inserted -712698321 1401363547
14545 ToggleIndent
14546 \end_layout
14547
14548 \end_inset
14549
14550  [
14551 \emph on
14552
14553 \begin_inset Flex Code
14554 status collapsed
14555
14556 \begin_layout Plain Layout
14557
14558 \change_inserted -712698321 1401363664
14559
14560 \emph on
14561 default
14562 \change_unchanged
14563
14564 \end_layout
14565
14566 \end_inset
14567
14568
14569 \emph default
14570
14571 \begin_inset Flex Code
14572 status collapsed
14573
14574 \begin_layout Plain Layout
14575
14576 \change_inserted -712698321 1401363669
14577 always
14578 \change_unchanged
14579
14580 \end_layout
14581
14582 \end_inset
14583
14584
14585 \begin_inset Flex Code
14586 status collapsed
14587
14588 \begin_layout Plain Layout
14589
14590 \change_inserted -712698321 1401363675
14591 never
14592 \change_unchanged
14593
14594 \end_layout
14595
14596 \end_inset
14597
14598 ] This tag determines whether the first line indentation of this paragraph
14599  can be toggled via the Paragraph settings dialog.
14600  If 
14601 \emph on
14602
14603 \begin_inset Flex Code
14604 status collapsed
14605
14606 \begin_layout Plain Layout
14607
14608 \change_inserted -712698321 1401363761
14609
14610 \emph off
14611 default
14612 \end_layout
14613
14614 \end_inset
14615
14616
14617 \emph default
14618  is set, indentation can be toggled if the document settings use 
14619 \begin_inset Quotes eld
14620 \end_inset
14621
14622 indent
14623 \begin_inset Quotes erd
14624 \end_inset
14625
14626  paragraph style, with 
14627 \begin_inset Flex Code
14628 status collapsed
14629
14630 \begin_layout Plain Layout
14631
14632 \change_inserted -712698321 1401363844
14633 always
14634 \end_layout
14635
14636 \end_inset
14637
14638 , indentation can always be toggled, notwithstanding the document settings,
14639  with 
14640 \begin_inset Flex Code
14641 status collapsed
14642
14643 \begin_layout Plain Layout
14644
14645 \change_inserted -712698321 1401363901
14646 never
14647 \end_layout
14648
14649 \end_inset
14650
14651 , indentation can never be toggled.
14652 \change_unchanged
14653
14654 \end_layout
14655
14656 \begin_layout Description
14657 \begin_inset Flex Code
14658 status collapsed
14659
14660 \begin_layout Plain Layout
14661 TopSep
14662 \end_layout
14663
14664 \end_inset
14665
14666  [
14667 \begin_inset Flex Code
14668 status collapsed
14669
14670 \begin_layout Plain Layout
14671 float=0
14672 \end_layout
14673
14674 \end_inset
14675
14676 ] The vertical space with which the very first of a chain of paragraphs
14677  with this style is separated from the previous paragraph.
14678  If the previous paragraph has another style, the separations are not simply
14679  added, but the maximum is taken.
14680 \end_layout
14681
14682 \begin_layout Subsection
14683 \begin_inset CommandInset label
14684 LatexCommand label
14685 name "sub:I18n"
14686
14687 \end_inset
14688
14689 Internationalization of Paragraph Styles
14690 \end_layout
14691
14692 \begin_layout Standard
14693 LyX has long supported internationalization of layout information, but,
14694  until version 2.0, this applied only to the user interface and not to, say,
14695  PDF output.
14696  Thus, French authors were forced to resort to ugly hacks if they wanted
14697  `
14698 \lang french
14699 Théorème
14700 \lang english
14701  1' instead of `Theorem 1'.
14702  Thanks to Georg Baum, that is no longer the case.
14703 \end_layout
14704
14705 \begin_layout Standard
14706 If a 
14707 \begin_inset Flex Code
14708 status collapsed
14709
14710 \begin_layout Plain Layout
14711 Style
14712 \end_layout
14713
14714 \end_inset
14715
14716  defines text that is to appear in the typeset document, it may use 
14717 \begin_inset Flex Code
14718 status collapsed
14719
14720 \begin_layout Plain Layout
14721 LangPreamble
14722 \end_layout
14723
14724 \end_inset
14725
14726  and 
14727 \begin_inset Flex Code
14728 status collapsed
14729
14730 \begin_layout Plain Layout
14731 BabelPreamble
14732 \end_layout
14733
14734 \end_inset
14735
14736  to support non-English and even multi-language documents correctly.
14737  The following excerpt (from the 
14738 \begin_inset Flex Code
14739 status collapsed
14740
14741 \begin_layout Plain Layout
14742 theorems-ams.inc
14743 \end_layout
14744
14745 \end_inset
14746
14747  file) shows how this works:
14748 \end_layout
14749
14750 \begin_layout LyX-Code
14751 Preamble
14752 \begin_inset Separator parbreak
14753 \end_inset
14754
14755
14756 \end_layout
14757
14758 \begin_deeper
14759 \begin_layout LyX-Code
14760   
14761 \backslash
14762 theoremstyle{remark}
14763 \end_layout
14764
14765 \begin_layout LyX-Code
14766   
14767 \backslash
14768 newtheorem{claim}[thm]{
14769 \backslash
14770 protect
14771 \backslash
14772 claimname}
14773 \end_layout
14774
14775 \begin_layout LyX-Code
14776 EndPreamble
14777 \end_layout
14778
14779 \begin_layout LyX-Code
14780 LangPreamble
14781 \end_layout
14782
14783 \begin_layout LyX-Code
14784   
14785 \backslash
14786 providecommand{
14787 \backslash
14788 claimname}{_(Claim)}
14789 \end_layout
14790
14791 \begin_layout LyX-Code
14792 EndLangPreamble
14793 \end_layout
14794
14795 \begin_layout LyX-Code
14796 BabelPreamble
14797 \end_layout
14798
14799 \begin_layout LyX-Code
14800     
14801 \backslash
14802 addto
14803 \backslash
14804 captions$$lang{
14805 \backslash
14806 renewcommand{
14807 \backslash
14808 claimname}{_(Claim)}}
14809 \end_layout
14810
14811 \begin_layout LyX-Code
14812 EndBabelPreamble
14813 \end_layout
14814
14815 \end_deeper
14816 \begin_layout Standard
14817 In principle, any legal LaTeX may appear in the 
14818 \begin_inset Flex Code
14819 status collapsed
14820
14821 \begin_layout Plain Layout
14822 LangPreamble
14823 \end_layout
14824
14825 \end_inset
14826
14827  and 
14828 \begin_inset Flex Code
14829 status collapsed
14830
14831 \begin_layout Plain Layout
14832 BabelPreamble
14833 \end_layout
14834
14835 \end_inset
14836
14837  tags, but in practice they will typically look as they do here.
14838  The key to correct translation of the typeset text is the definition of
14839  the LaTeX command 
14840 \begin_inset Flex Code
14841 status collapsed
14842
14843 \begin_layout Plain Layout
14844
14845 \backslash
14846 claimname
14847 \end_layout
14848
14849 \end_inset
14850
14851  and its use in 
14852 \begin_inset Flex Code
14853 status collapsed
14854
14855 \begin_layout Plain Layout
14856
14857 \backslash
14858 newtheorem
14859 \end_layout
14860
14861 \end_inset
14862
14863 .
14864  
14865 \end_layout
14866
14867 \begin_layout Standard
14868 The 
14869 \begin_inset Flex Code
14870 status collapsed
14871
14872 \begin_layout Plain Layout
14873 LangPreamble
14874 \end_layout
14875
14876 \end_inset
14877
14878  tag provides for internationalization based upon the overall language of
14879  the document.
14880  The contents of the tag will be included in the preamble, just as with
14881  the 
14882 \begin_inset Flex Code
14883 status collapsed
14884
14885 \begin_layout Plain Layout
14886 Preamble
14887 \end_layout
14888
14889 \end_inset
14890
14891  tag.
14892  What makes it special is the use of the 
14893 \begin_inset Quotes eld
14894 \end_inset
14895
14896 function
14897 \begin_inset Quotes erd
14898 \end_inset
14899
14900  
14901 \begin_inset Flex Code
14902 status collapsed
14903
14904 \begin_layout Plain Layout
14905 _()
14906 \end_layout
14907
14908 \end_inset
14909
14910 , which will be replaced, when LyX produces LaTeX output, with the translation
14911  of its argument into the document language.
14912 \end_layout
14913
14914 \begin_layout Standard
14915 The 
14916 \begin_inset Flex Code
14917 status collapsed
14918
14919 \begin_layout Plain Layout
14920 BabelPreamble
14921 \end_layout
14922
14923 \end_inset
14924
14925  tag is more complex, since it is meant to provide support for multi-language
14926  documents and so offers an interface to the 
14927 \begin_inset Flex Code
14928 status collapsed
14929
14930 \begin_layout Plain Layout
14931 babel
14932 \end_layout
14933
14934 \end_inset
14935
14936  package.
14937  Its contents will be added to the preamble once for each language that
14938  appears in the document.
14939  In this case, the argument to 
14940 \begin_inset Flex Code
14941 status collapsed
14942
14943 \begin_layout Plain Layout
14944 _()
14945 \end_layout
14946
14947 \end_inset
14948
14949  will be replaced with its translation into the language in question; the
14950  expression 
14951 \begin_inset Flex Code
14952 status collapsed
14953
14954 \begin_layout Plain Layout
14955 $$lang
14956 \end_layout
14957
14958 \end_inset
14959
14960  is replaced by the language name (as used by the babel package).
14961 \end_layout
14962
14963 \begin_layout Standard
14964 A German document that also included a French section would thus have the
14965  following in the preamble:
14966 \end_layout
14967
14968 \begin_layout LyX-Code
14969
14970 \backslash
14971 addto
14972 \backslash
14973 captionsfrench{
14974 \backslash
14975 renewcommand{
14976 \backslash
14977 claimname}{Affirmation}}
14978 \begin_inset Newline newline
14979 \end_inset
14980
14981
14982 \backslash
14983 addto
14984 \backslash
14985 captionsngerman{
14986 \backslash
14987 renewcommand{
14988 \backslash
14989 claimname}{Behauptung}}
14990 \begin_inset Newline newline
14991 \end_inset
14992
14993
14994 \backslash
14995 providecommand{
14996 \backslash
14997 claimname}{Behauptung}
14998 \end_layout
14999
15000 \begin_layout Standard
15001 LaTeX and 
15002 \begin_inset Flex Code
15003 status collapsed
15004
15005 \begin_layout Plain Layout
15006 babel
15007 \end_layout
15008
15009 \end_inset
15010
15011  will then conspire to produce the correct text in the output.
15012 \end_layout
15013
15014 \begin_layout Standard
15015 One important point to note here is that the translations are provided by
15016  LyX itself, through the file 
15017 \begin_inset Flex Code
15018 status collapsed
15019
15020 \begin_layout Plain Layout
15021 layouttranslations
15022 \end_layout
15023
15024 \end_inset
15025
15026 .
15027  This means, in effect, that 
15028 \begin_inset Flex Code
15029 status collapsed
15030
15031 \begin_layout Plain Layout
15032 LangPreamble
15033 \end_layout
15034
15035 \end_inset
15036
15037  and 
15038 \begin_inset Flex Code
15039 status collapsed
15040
15041 \begin_layout Plain Layout
15042 BabelPreamble
15043 \end_layout
15044
15045 \end_inset
15046
15047  are really only of use in layout files that are provided with LyX, since
15048  text entered in user-created layout files will not be seen by LyX's internation
15049 alization routines unless the 
15050 \begin_inset Flex Code
15051 status collapsed
15052
15053 \begin_layout Plain Layout
15054 layouttranslations
15055 \end_layout
15056
15057 \end_inset
15058
15059  file is modified accordingly.
15060  That said, however, any layout created with the intention that it will
15061  be included with LyX should use these tags where appropriate.
15062  Please note that the paragraph style translations provided by LyX will
15063  never change with a minor update (e.
15064 \begin_inset space \thinspace{}
15065 \end_inset
15066
15067 g.
15068 \begin_inset space \space{}
15069 \end_inset
15070
15071 from version 2.1.x to 2.1.y).
15072  It is however quite likely that a major update (e.
15073 \begin_inset space \thinspace{}
15074 \end_inset
15075
15076 g.
15077 \begin_inset space \space{}
15078 \end_inset
15079
15080 from 2.0.x to 2.1.y) will introduce new translations or corrections.
15081 \end_layout
15082
15083 \begin_layout Subsection
15084 Floats
15085 \begin_inset CommandInset label
15086 LatexCommand label
15087 name "sub:Floats"
15088
15089 \end_inset
15090
15091
15092 \end_layout
15093
15094 \begin_layout Standard
15095 It is necessary to define the floats (
15096 \begin_inset Flex MenuItem
15097 status collapsed
15098
15099 \begin_layout Plain Layout
15100 figure
15101 \end_layout
15102
15103 \end_inset
15104
15105
15106 \begin_inset Flex MenuItem
15107 status collapsed
15108
15109 \begin_layout Plain Layout
15110 table
15111 \end_layout
15112
15113 \end_inset
15114
15115 , \SpecialChar \ldots{}
15116 ) in the text class itself.
15117  Standard floats are included in the file 
15118 \begin_inset Flex Code
15119 status collapsed
15120
15121 \begin_layout Plain Layout
15122 stdfloats.inc
15123 \end_layout
15124
15125 \end_inset
15126
15127 , so you may have to do no more than add
15128 \end_layout
15129
15130 \begin_layout LyX-Code
15131 Input stdfloats.inc
15132 \end_layout
15133
15134 \begin_layout Standard
15135 to your layout file.
15136  If you want to implement a text class that proposes some other float types
15137  (like the AGU class bundled with LyX), the information below will hopefully
15138  help you:
15139 \end_layout
15140
15141 \begin_layout Description
15142 \begin_inset Flex Code
15143 status collapsed
15144
15145 \begin_layout Plain Layout
15146 Extension
15147 \end_layout
15148
15149 \end_inset
15150
15151  [
15152 \begin_inset Flex Code
15153 status collapsed
15154
15155 \begin_layout Plain Layout
15156 string
15157 \end_layout
15158
15159 \end_inset
15160
15161 =
15162 \begin_inset Quotes erd
15163 \end_inset
15164
15165
15166 \begin_inset Quotes erd
15167 \end_inset
15168
15169 ] The file name extension of an auxiliary file for the list of figures (or
15170  whatever).
15171  LaTeX writes the captions to this file.
15172 \end_layout
15173
15174 \begin_layout Description
15175 \begin_inset Flex Code
15176 status collapsed
15177
15178 \begin_layout Plain Layout
15179 GuiName
15180 \end_layout
15181
15182 \end_inset
15183
15184  [
15185 \begin_inset Flex Code
15186 status collapsed
15187
15188 \begin_layout Plain Layout
15189 string
15190 \end_layout
15191
15192 \end_inset
15193
15194 =
15195 \begin_inset Quotes erd
15196 \end_inset
15197
15198
15199 \begin_inset Quotes erd
15200 \end_inset
15201
15202 ] The string that will be used in the menus and also for the caption.
15203  This is translated to the current language if babel is used.
15204 \end_layout
15205
15206 \begin_layout Description
15207 \begin_inset Flex Code
15208 status collapsed
15209
15210 \begin_layout Plain Layout
15211 HTML*
15212 \end_layout
15213
15214 \end_inset
15215
15216  These tags control the XHTML output.
15217  See 
15218 \begin_inset CommandInset ref
15219 LatexCommand ref
15220 reference "sec:Tags-for-XHTML"
15221
15222 \end_inset
15223
15224 .
15225 \end_layout
15226
15227 \begin_layout Description
15228 \begin_inset Flex Code
15229 status collapsed
15230
15231 \begin_layout Plain Layout
15232 IsPredefined
15233 \end_layout
15234
15235 \end_inset
15236
15237  [
15238 \emph on
15239
15240 \begin_inset Flex Code
15241 status collapsed
15242
15243 \begin_layout Plain Layout
15244 0
15245 \end_layout
15246
15247 \end_inset
15248
15249
15250 \emph default
15251 ,
15252 \begin_inset space \thinspace{}
15253 \end_inset
15254
15255
15256 \begin_inset Flex Code
15257 status collapsed
15258
15259 \begin_layout Plain Layout
15260 1
15261 \end_layout
15262
15263 \end_inset
15264
15265 ] Indicates whether the float is already defined in the document class or
15266  if instead the LaTeX package 
15267 \begin_inset Flex Code
15268 status collapsed
15269
15270 \begin_layout Plain Layout
15271 float
15272 \end_layout
15273
15274 \end_inset
15275
15276  needs to be loaded to define it on-the-fly.
15277  The default is 
15278 \begin_inset Flex Code
15279 status collapsed
15280
15281 \begin_layout Plain Layout
15282 0
15283 \end_layout
15284
15285 \end_inset
15286
15287 , which means: 
15288 \begin_inset Flex Code
15289 status collapsed
15290
15291 \begin_layout Plain Layout
15292 float
15293 \end_layout
15294
15295 \end_inset
15296
15297  is used.
15298  It should be set to 
15299 \begin_inset Flex Code
15300 status collapsed
15301
15302 \begin_layout Plain Layout
15303 1
15304 \end_layout
15305
15306 \end_inset
15307
15308  if the float is already defined by the LaTeX document class.
15309 \end_layout
15310
15311 \begin_layout Description
15312 \begin_inset Flex Code
15313 status collapsed
15314
15315 \begin_layout Plain Layout
15316 ListCommand
15317 \end_layout
15318
15319 \end_inset
15320
15321  [
15322 \begin_inset Flex Code
15323 status collapsed
15324
15325 \begin_layout Plain Layout
15326 string
15327 \end_layout
15328
15329 \end_inset
15330
15331 =
15332 \begin_inset Quotes erd
15333 \end_inset
15334
15335
15336 \begin_inset Quotes erd
15337 \end_inset
15338
15339 ] The command used to generate a list of floats of this type; the leading
15340  `
15341 \backslash
15342 ' must be omitted.
15343  This 
15344 \emph on
15345 must
15346 \emph default
15347  be given if 
15348 \begin_inset Flex Code
15349 status collapsed
15350
15351 \begin_layout Plain Layout
15352 UsesFloatPkg
15353 \end_layout
15354
15355 \end_inset
15356
15357  is false, since there is no standard way to generate this command.
15358  It is ignored if 
15359 \begin_inset Flex Code
15360 status collapsed
15361
15362 \begin_layout Plain Layout
15363 UsesFloatPkg
15364 \end_layout
15365
15366 \end_inset
15367
15368  is true, since in that case there is a standard way to define the command.
15369 \end_layout
15370
15371 \begin_layout Description
15372 \begin_inset Flex Code
15373 status collapsed
15374
15375 \begin_layout Plain Layout
15376 ListName
15377 \end_layout
15378
15379 \end_inset
15380
15381  [
15382 \begin_inset Flex Code
15383 status collapsed
15384
15385 \begin_layout Plain Layout
15386 string
15387 \end_layout
15388
15389 \end_inset
15390
15391 =
15392 \begin_inset Quotes erd
15393 \end_inset
15394
15395
15396 \begin_inset Quotes erd
15397 \end_inset
15398
15399 ] A title for a list of floats of this kind (list of figures, tables, or
15400  whatever).
15401  It is used for the screen label within LyX, it is used by LaTeX for the
15402  title and it is used as the title in the XHTML output.
15403  It will be translated to the document language.
15404 \end_layout
15405
15406 \begin_layout Description
15407 \begin_inset Flex Code
15408 status collapsed
15409
15410 \begin_layout Plain Layout
15411 NumberWithin
15412 \end_layout
15413
15414 \end_inset
15415
15416  [
15417 \begin_inset Flex Code
15418 status collapsed
15419
15420 \begin_layout Plain Layout
15421 string
15422 \end_layout
15423
15424 \end_inset
15425
15426 =
15427 \begin_inset Quotes erd
15428 \end_inset
15429
15430
15431 \begin_inset Quotes erd
15432 \end_inset
15433
15434 ] This (optional) argument determines whether floats of this class will
15435  be numbered within some sectional unit of the document.
15436  For example, if 
15437 \begin_inset Flex Code
15438 status collapsed
15439
15440 \begin_layout Plain Layout
15441 NumberWithin
15442 \end_layout
15443
15444 \end_inset
15445
15446  is set to 
15447 \begin_inset Quotes eld
15448 \end_inset
15449
15450
15451 \begin_inset Flex Code
15452 status collapsed
15453
15454 \begin_layout Plain Layout
15455 chapter
15456 \end_layout
15457
15458 \end_inset
15459
15460
15461 \begin_inset Quotes erd
15462 \end_inset
15463
15464 , the floats will be numbered within chapters.
15465  
15466 \end_layout
15467
15468 \begin_layout Description
15469 \begin_inset Flex Code
15470 status collapsed
15471
15472 \begin_layout Plain Layout
15473 Placement
15474 \end_layout
15475
15476 \end_inset
15477
15478  [
15479 \begin_inset Flex Code
15480 status collapsed
15481
15482 \begin_layout Plain Layout
15483 string
15484 \end_layout
15485
15486 \end_inset
15487
15488 =
15489 \begin_inset Quotes erd
15490 \end_inset
15491
15492
15493 \begin_inset Quotes erd
15494 \end_inset
15495
15496 ] The default placement for the given class of floats.
15497  The string should be as in standard LaTeX: 
15498 \begin_inset Flex Code
15499 status collapsed
15500
15501 \begin_layout Plain Layout
15502 t
15503 \end_layout
15504
15505 \end_inset
15506
15507
15508 \begin_inset Flex Code
15509 status collapsed
15510
15511 \begin_layout Plain Layout
15512 b
15513 \end_layout
15514
15515 \end_inset
15516
15517
15518 \begin_inset Flex Code
15519 status collapsed
15520
15521 \begin_layout Plain Layout
15522 p
15523 \end_layout
15524
15525 \end_inset
15526
15527  and 
15528 \begin_inset Flex Code
15529 status collapsed
15530
15531 \begin_layout Plain Layout
15532 h
15533 \end_layout
15534
15535 \end_inset
15536
15537  for top, bottom, page, and here, respectively.
15538 \begin_inset Foot
15539 status collapsed
15540
15541 \begin_layout Plain Layout
15542 Note that the order of these letters in the string is irrelevant, like in
15543  LaTeX.
15544 \end_layout
15545
15546 \end_inset
15547
15548  On top of that there is a new type, 
15549 \begin_inset Flex Code
15550 status collapsed
15551
15552 \begin_layout Plain Layout
15553 H
15554 \end_layout
15555
15556 \end_inset
15557
15558 , which does not really correspond to a float, since it means: put it 
15559 \begin_inset Quotes eld
15560 \end_inset
15561
15562 here
15563 \begin_inset Quotes erd
15564 \end_inset
15565
15566  and nowhere else.
15567  Note however that the 
15568 \begin_inset Flex Code
15569 status collapsed
15570
15571 \begin_layout Plain Layout
15572 H
15573 \end_layout
15574
15575 \end_inset
15576
15577  specifier is special and, because of implementation details, cannot be
15578  used in non-built in float types.
15579  If you do not understand what this means, just use 
15580 \begin_inset Quotes eld
15581 \end_inset
15582
15583
15584 \begin_inset Flex Code
15585 status collapsed
15586
15587 \begin_layout Plain Layout
15588 tbp
15589 \end_layout
15590
15591 \end_inset
15592
15593
15594 \begin_inset Quotes erd
15595 \end_inset
15596
15597 .
15598 \end_layout
15599
15600 \begin_layout Description
15601 \begin_inset Flex Code
15602 status collapsed
15603
15604 \begin_layout Plain Layout
15605 RefPrefix
15606 \end_layout
15607
15608 \end_inset
15609
15610  [
15611 \begin_inset Flex Code
15612 status collapsed
15613
15614 \begin_layout Plain Layout
15615 string
15616 \end_layout
15617
15618 \end_inset
15619
15620 ] The prefix to use when creating labels referring to floats of this type.
15621  This allows the use of formatted references.
15622  Note that you can remove any 
15623 \begin_inset Flex Code
15624 status collapsed
15625
15626 \begin_layout Plain Layout
15627 RefPrefix
15628 \end_layout
15629
15630 \end_inset
15631
15632  set by a copied style by using the special value 
15633 \begin_inset Quotes eld
15634 \end_inset
15635
15636 OFF
15637 \begin_inset Quotes erd
15638 \end_inset
15639
15640 , which must be all caps.
15641 \end_layout
15642
15643 \begin_layout Description
15644 \begin_inset Flex Code
15645 status collapsed
15646
15647 \begin_layout Plain Layout
15648 Style
15649 \end_layout
15650
15651 \end_inset
15652
15653  [
15654 \begin_inset Flex Code
15655 status collapsed
15656
15657 \begin_layout Plain Layout
15658 string
15659 \end_layout
15660
15661 \end_inset
15662
15663 =
15664 \begin_inset Quotes erd
15665 \end_inset
15666
15667
15668 \begin_inset Quotes erd
15669 \end_inset
15670
15671 ] The style used when defining the float using 
15672 \begin_inset Flex Code
15673 status collapsed
15674
15675 \begin_layout Plain Layout
15676
15677 \backslash
15678 newfloat
15679 \end_layout
15680
15681 \end_inset
15682
15683 .
15684 \end_layout
15685
15686 \begin_layout Description
15687 \begin_inset Flex Code
15688 status collapsed
15689
15690 \begin_layout Plain Layout
15691 Type
15692 \end_layout
15693
15694 \end_inset
15695
15696  [
15697 \begin_inset Flex Code
15698 status collapsed
15699
15700 \begin_layout Plain Layout
15701 string
15702 \end_layout
15703
15704 \end_inset
15705
15706 =
15707 \begin_inset Quotes erd
15708 \end_inset
15709
15710
15711 \begin_inset Quotes erd
15712 \end_inset
15713
15714 ] The 
15715 \begin_inset Quotes eld
15716 \end_inset
15717
15718 type
15719 \begin_inset Quotes erd
15720 \end_inset
15721
15722  of the new class of floats, like program or algorithm.
15723  After the appropriate 
15724 \begin_inset Flex Code
15725 status collapsed
15726
15727 \begin_layout Plain Layout
15728
15729 \backslash
15730 newfloat
15731 \end_layout
15732
15733 \end_inset
15734
15735 , commands such as 
15736 \begin_inset Flex Code
15737 status collapsed
15738
15739 \begin_layout Plain Layout
15740
15741 \backslash
15742 begin{program}
15743 \end_layout
15744
15745 \end_inset
15746
15747  or 
15748 \begin_inset Flex Code
15749 status collapsed
15750
15751 \begin_layout Plain Layout
15752
15753 \backslash
15754 end{algorithm*}
15755 \end_layout
15756
15757 \end_inset
15758
15759  will be available.
15760 \end_layout
15761
15762 \begin_layout Description
15763 \begin_inset Flex Code
15764 status collapsed
15765
15766 \begin_layout Plain Layout
15767 UsesFloatPkg
15768 \end_layout
15769
15770 \end_inset
15771
15772  [
15773 \begin_inset Flex Code
15774 status collapsed
15775
15776 \begin_layout Plain Layout
15777 0
15778 \end_layout
15779
15780 \end_inset
15781
15782 ,
15783 \begin_inset space \thinspace{}
15784 \end_inset
15785
15786
15787 \begin_inset Flex Code
15788 status collapsed
15789
15790 \begin_layout Plain Layout
15791
15792 \emph on
15793 1
15794 \end_layout
15795
15796 \end_inset
15797
15798 ] Specifies whether this float is defined using the LaTeX package 
15799 \begin_inset Flex Code
15800 status collapsed
15801
15802 \begin_layout Plain Layout
15803 float
15804 \end_layout
15805
15806 \end_inset
15807
15808 , either by the class file, another package or on-the-fly by LyX itself.
15809 \end_layout
15810
15811 \begin_layout Standard
15812 Note that defining a float with type 
15813 \begin_inset Flex Code
15814 status collapsed
15815
15816 \begin_layout Plain Layout
15817
15818 \emph on
15819 type
15820 \end_layout
15821
15822 \end_inset
15823
15824  automatically defines the corresponding counter with name 
15825 \begin_inset Flex Code
15826 status collapsed
15827
15828 \begin_layout Plain Layout
15829
15830 \emph on
15831 type
15832 \end_layout
15833
15834 \end_inset
15835
15836 .
15837 \end_layout
15838
15839 \begin_layout Subsection
15840 Flex insets and InsetLayout
15841 \begin_inset CommandInset label
15842 LatexCommand label
15843 name "sub:Flex-insets-and"
15844
15845 \end_inset
15846
15847
15848 \end_layout
15849
15850 \begin_layout Standard
15851 Flex insets come in three different kinds: 
15852 \end_layout
15853
15854 \begin_layout Itemize
15855 character style (
15856 \begin_inset Flex Code
15857 status collapsed
15858
15859 \begin_layout Plain Layout
15860 CharStyle
15861 \end_layout
15862
15863 \end_inset
15864
15865 ): These define semantic markup corresponding to such LaTeX commands as
15866  
15867 \begin_inset Flex Code
15868 status collapsed
15869
15870 \begin_layout Plain Layout
15871
15872 \backslash
15873 noun
15874 \end_layout
15875
15876 \end_inset
15877
15878  and 
15879 \begin_inset Flex Code
15880 status collapsed
15881
15882 \begin_layout Plain Layout
15883
15884 \backslash
15885 code
15886 \end_layout
15887
15888 \end_inset
15889
15890 .
15891 \end_layout
15892
15893 \begin_layout Itemize
15894 user custom (
15895 \begin_inset Flex Code
15896 status collapsed
15897
15898 \begin_layout Plain Layout
15899 Custom
15900 \end_layout
15901
15902 \end_inset
15903
15904 ): These can be used to define custom collapsible insets, similar to TeX
15905  code, footnote, and the like.
15906  An obvious example is an endnote inset, which is defined in the 
15907 \begin_inset Flex Code
15908 status collapsed
15909
15910 \begin_layout Plain Layout
15911 endnote
15912 \end_layout
15913
15914 \end_inset
15915
15916  module.
15917 \end_layout
15918
15919 \begin_layout Itemize
15920 XML elements (
15921 \begin_inset Flex Code
15922 status collapsed
15923
15924 \begin_layout Plain Layout
15925 Element
15926 \end_layout
15927
15928 \end_inset
15929
15930 ): For use with DocBook classes.
15931 \end_layout
15932
15933 \begin_layout Standard
15934 Flex insets are defined using the 
15935 \begin_inset Flex Code
15936 status collapsed
15937
15938 \begin_layout Plain Layout
15939 InsetLayout
15940 \end_layout
15941
15942 \end_inset
15943
15944  tag, which shall be explained in a moment.
15945 \end_layout
15946
15947 \begin_layout Standard
15948 The 
15949 \begin_inset Flex Code
15950 status collapsed
15951
15952 \begin_layout Plain Layout
15953 InsetLayout
15954 \end_layout
15955
15956 \end_inset
15957
15958  tag also serves another function: It can be used to customize the general
15959  layout of many different types of insets.
15960  Currently, 
15961 \begin_inset Flex Code
15962 status collapsed
15963
15964 \begin_layout Plain Layout
15965 InsetLayout
15966 \end_layout
15967
15968 \end_inset
15969
15970  can be used to customize the layout parameters for footnotes, marginal
15971  notes, note insets, TeX code (ERT) insets, branches, listings, indexes,
15972  boxes, tables, algorithms, URLs, and captions, as well as to define Flex
15973  insets.
15974 \end_layout
15975
15976 \begin_layout Standard
15977 The 
15978 \begin_inset Flex Code
15979 status collapsed
15980
15981 \begin_layout Plain Layout
15982 InsetLayout
15983 \end_layout
15984
15985 \end_inset
15986
15987  definition must begin with a line of the form:
15988 \end_layout
15989
15990 \begin_layout LyX-Code
15991 InsetLayout <type>
15992 \end_layout
15993
15994 \begin_layout Standard
15995 Here 
15996 \begin_inset Flex Code
15997 status collapsed
15998
15999 \begin_layout Plain Layout
16000 <Type>
16001 \end_layout
16002
16003 \end_inset
16004
16005  indicates the inset whose layout is being defined, and here there are four
16006  cases.
16007 \end_layout
16008
16009 \begin_layout Enumerate
16010 The layout for a pre-existing inset is being modified.
16011  In this case, can be 
16012 \begin_inset Flex Code
16013 status collapsed
16014
16015 \begin_layout Plain Layout
16016 <Type>
16017 \end_layout
16018
16019 \end_inset
16020
16021  any one of the following: 
16022 \begin_inset Flex Code
16023 status collapsed
16024
16025 \begin_layout Plain Layout
16026 Algorithm
16027 \end_layout
16028
16029 \end_inset
16030
16031
16032 \begin_inset Flex Code
16033 status collapsed
16034
16035 \begin_layout Plain Layout
16036 Branch
16037 \end_layout
16038
16039 \end_inset
16040
16041
16042 \begin_inset Flex Code
16043 status collapsed
16044
16045 \begin_layout Plain Layout
16046 Box
16047 \end_layout
16048
16049 \end_inset
16050
16051
16052 \begin_inset Flex Code
16053 status collapsed
16054
16055 \begin_layout Plain Layout
16056 Box:shaded
16057 \end_layout
16058
16059 \end_inset
16060
16061
16062 \begin_inset Flex Code
16063 status collapsed
16064
16065 \begin_layout Plain Layout
16066 Caption:Standard
16067 \end_layout
16068
16069 \end_inset
16070
16071
16072 \begin_inset Flex Code
16073 status collapsed
16074
16075 \begin_layout Plain Layout
16076 ERT
16077 \end_layout
16078
16079 \end_inset
16080
16081
16082 \begin_inset Flex Code
16083 status collapsed
16084
16085 \begin_layout Plain Layout
16086 Figure
16087 \end_layout
16088
16089 \end_inset
16090
16091
16092 \begin_inset Flex Code
16093 status collapsed
16094
16095 \begin_layout Plain Layout
16096 Foot
16097 \end_layout
16098
16099 \end_inset
16100
16101
16102 \begin_inset Flex Code
16103 status collapsed
16104
16105 \begin_layout Plain Layout
16106 Index
16107 \end_layout
16108
16109 \end_inset
16110
16111
16112 \begin_inset Flex Code
16113 status collapsed
16114
16115 \begin_layout Plain Layout
16116 Info
16117 \end_layout
16118
16119 \end_inset
16120
16121
16122 \begin_inset Flex Code
16123 status collapsed
16124
16125 \begin_layout Plain Layout
16126 Info:menu
16127 \end_layout
16128
16129 \end_inset
16130
16131
16132 \begin_inset Flex Code
16133 status collapsed
16134
16135 \begin_layout Plain Layout
16136 Info:shortcut
16137 \end_layout
16138
16139 \end_inset
16140
16141
16142 \begin_inset Flex Code
16143 status collapsed
16144
16145 \begin_layout Plain Layout
16146 Info:shortcuts
16147 \end_layout
16148
16149 \end_inset
16150
16151
16152 \begin_inset Flex Code
16153 status collapsed
16154
16155 \begin_layout Plain Layout
16156 Listings
16157 \end_layout
16158
16159 \end_inset
16160
16161
16162 \begin_inset Flex Code
16163 status collapsed
16164
16165 \begin_layout Plain Layout
16166 Marginal
16167 \end_layout
16168
16169 \end_inset
16170
16171
16172 \begin_inset Flex Code
16173 status collapsed
16174
16175 \begin_layout Plain Layout
16176 Note:Comment
16177 \end_layout
16178
16179 \end_inset
16180
16181
16182 \begin_inset Flex Code
16183 status collapsed
16184
16185 \begin_layout Plain Layout
16186 Note:Note
16187 \end_layout
16188
16189 \end_inset
16190
16191
16192 \begin_inset Flex Code
16193 status collapsed
16194
16195 \begin_layout Plain Layout
16196 Note:Greyedout
16197 \end_layout
16198
16199 \end_inset
16200
16201
16202 \begin_inset Flex Code
16203 status collapsed
16204
16205 \begin_layout Plain Layout
16206 Table
16207 \end_layout
16208
16209 \end_inset
16210
16211 , or 
16212 \begin_inset Flex Code
16213 status collapsed
16214
16215 \begin_layout Plain Layout
16216 URL
16217 \end_layout
16218
16219 \end_inset
16220
16221 .
16222 \end_layout
16223
16224 \begin_layout Enumerate
16225 The layout for a Flex inset is being defined.
16226  In this case, 
16227 \begin_inset Flex Code
16228 status collapsed
16229
16230 \begin_layout Plain Layout
16231 <Type>
16232 \end_layout
16233
16234 \end_inset
16235
16236  must be of the form 
16237 \begin_inset Quotes eld
16238 \end_inset
16239
16240
16241 \begin_inset Flex Code
16242 status collapsed
16243
16244 \begin_layout Plain Layout
16245 Flex:<name>
16246 \end_layout
16247
16248 \end_inset
16249
16250
16251 \begin_inset Quotes erd
16252 \end_inset
16253
16254 , where 
16255 \begin_inset Flex Code
16256 status collapsed
16257
16258 \begin_layout Plain Layout
16259 name
16260 \end_layout
16261
16262 \end_inset
16263
16264  may be be any valid identifier not used by a pre-existing Flex inset.
16265  The identifier may include spaces, but in that case the whole thing must
16266  be wrapped in quotes.
16267  Note that the definition of a flex inset 
16268 \emph on
16269 must 
16270 \emph default
16271 also include a 
16272 \begin_inset Flex Code
16273 status collapsed
16274
16275 \begin_layout Plain Layout
16276 LyXType
16277 \end_layout
16278
16279 \end_inset
16280
16281  entry, declaring which type of inset it defines.
16282 \end_layout
16283
16284 \begin_layout Enumerate
16285 The layout for user specific branch is being defined.
16286  In this case, 
16287 \begin_inset Flex Code
16288 status collapsed
16289
16290 \begin_layout Plain Layout
16291 <Type>
16292 \end_layout
16293
16294 \end_inset
16295
16296  must be of the form 
16297 \begin_inset Quotes eld
16298 \end_inset
16299
16300
16301 \begin_inset Flex Code
16302 status collapsed
16303
16304 \begin_layout Plain Layout
16305 Branch:<name>
16306 \end_layout
16307
16308 \end_inset
16309
16310
16311 \begin_inset Quotes erd
16312 \end_inset
16313
16314 , where 
16315 \begin_inset Flex Code
16316 status collapsed
16317
16318 \begin_layout Plain Layout
16319 name
16320 \end_layout
16321
16322 \end_inset
16323
16324  may be be any valid identifier of branch defined in user's document.
16325  The identifier may include spaces, but in that case the whole thing must
16326  be wrapped in quotes.
16327  The main purpose of this feature is to allow LaTeX wrapping around specific
16328  branches as user needs.
16329 \end_layout
16330
16331 \begin_layout Enumerate
16332 The layout of a user (or class) specific caption is being defined.
16333  In this case, 
16334 \begin_inset Flex Code
16335 status collapsed
16336
16337 \begin_layout Plain Layout
16338 <Type>
16339 \end_layout
16340
16341 \end_inset
16342
16343  must be of the form 
16344 \begin_inset Quotes eld
16345 \end_inset
16346
16347
16348 \begin_inset Flex Code
16349 status collapsed
16350
16351 \begin_layout Plain Layout
16352 Caption:<name>
16353 \end_layout
16354
16355 \end_inset
16356
16357
16358 \begin_inset Quotes erd
16359 \end_inset
16360
16361 , where 
16362 \begin_inset Flex Code
16363 status collapsed
16364
16365 \begin_layout Plain Layout
16366 name
16367 \end_layout
16368
16369 \end_inset
16370
16371  specifies the name of the caption as it appears in the menu.
16372  Have a look at the standard caption (
16373 \begin_inset Flex Code
16374 status collapsed
16375
16376 \begin_layout Plain Layout
16377 Caption:Standard
16378 \end_layout
16379
16380 \end_inset
16381
16382 ), the specific captions of the KOMA-Script classes (
16383 \begin_inset Flex Code
16384 status collapsed
16385
16386 \begin_layout Plain Layout
16387 Caption:Above
16388 \end_layout
16389
16390 \end_inset
16391
16392
16393 \begin_inset Flex Code
16394 status collapsed
16395
16396 \begin_layout Plain Layout
16397 Caption:Below
16398 \end_layout
16399
16400 \end_inset
16401
16402 ) or the module 
16403 \family sans
16404 Multilingual
16405 \begin_inset space ~
16406 \end_inset
16407
16408 Captions 
16409 \family default
16410 (
16411 \begin_inset Flex Code
16412 status collapsed
16413
16414 \begin_layout Plain Layout
16415 Caption:Bicaption
16416 \end_layout
16417
16418 \end_inset
16419
16420 ) for applications.
16421 \end_layout
16422
16423 \begin_layout Standard
16424 The 
16425 \begin_inset Flex Code
16426 status collapsed
16427
16428 \begin_layout Plain Layout
16429 InsetLayout
16430 \end_layout
16431
16432 \end_inset
16433
16434  definition can contain the following entries:
16435 \end_layout
16436
16437 \begin_layout Description
16438 \begin_inset Flex Code
16439 status collapsed
16440
16441 \begin_layout Plain Layout
16442 Argument
16443 \end_layout
16444
16445 \end_inset
16446
16447  [
16448 \begin_inset Flex Code
16449 status collapsed
16450
16451 \begin_layout Plain Layout
16452 int
16453 \end_layout
16454
16455 \end_inset
16456
16457 ] Defines argument number of a command\SpecialChar \slash{}
16458 environment associated with the current
16459  layout.
16460  The definition must end with 
16461 \begin_inset Flex Code
16462 status collapsed
16463
16464 \begin_layout Plain Layout
16465 EndArgument
16466 \end_layout
16467
16468 \end_inset
16469
16470 .
16471  See 
16472 \begin_inset CommandInset ref
16473 LatexCommand ref
16474 reference "sub:Paragraph-Styles"
16475
16476 \end_inset
16477
16478  for details.
16479 \end_layout
16480
16481 \begin_layout Description
16482 \begin_inset Flex Code
16483 status collapsed
16484
16485 \begin_layout Plain Layout
16486 BabelPreamble
16487 \end_layout
16488
16489 \end_inset
16490
16491  Preamble for changing language commands; see 
16492 \begin_inset CommandInset ref
16493 LatexCommand ref
16494 reference "sub:I18n"
16495
16496 \end_inset
16497
16498 .
16499 \end_layout
16500
16501 \begin_layout Description
16502 \begin_inset Flex Code
16503 status collapsed
16504
16505 \begin_layout Plain Layout
16506 BgColor
16507 \end_layout
16508
16509 \end_inset
16510
16511  [
16512 \begin_inset Flex Code
16513 status collapsed
16514
16515 \begin_layout Plain Layout
16516 <name>
16517 \end_layout
16518
16519 \end_inset
16520
16521 ] The color for the inset's background.
16522  See 
16523 \begin_inset CommandInset ref
16524 LatexCommand ref
16525 reference "chap:Names-of-colors"
16526
16527 \end_inset
16528
16529  for a list of the available color names.
16530 \end_layout
16531
16532 \begin_layout Description
16533 \begin_inset Flex Code
16534 status collapsed
16535
16536 \begin_layout Plain Layout
16537 ContentAsLabel
16538 \end_layout
16539
16540 \end_inset
16541
16542  [
16543 \begin_inset Flex Code
16544 status collapsed
16545
16546 \begin_layout Plain Layout
16547
16548 \emph on
16549 0
16550 \end_layout
16551
16552 \end_inset
16553
16554 ,
16555 \begin_inset space \thinspace{}
16556 \end_inset
16557
16558
16559 \begin_inset Flex Code
16560 status collapsed
16561
16562 \begin_layout Plain Layout
16563 1
16564 \end_layout
16565
16566 \end_inset
16567
16568 ] Whether to use the content of the inset as the label, when the inset is
16569  closed.
16570  Default is false.
16571 \end_layout
16572
16573 \begin_layout Description
16574 \begin_inset Flex Code
16575 status collapsed
16576
16577 \begin_layout Plain Layout
16578 CopyStyle
16579 \end_layout
16580
16581 \end_inset
16582
16583  [
16584 \begin_inset Flex Code
16585 status collapsed
16586
16587 \begin_layout Plain Layout
16588 <type>
16589 \end_layout
16590
16591 \end_inset
16592
16593 ] As with paragraph styles, see 
16594 \begin_inset CommandInset ref
16595 LatexCommand ref
16596 reference "sub:Paragraph-Styles"
16597
16598 \end_inset
16599
16600 .
16601  Note that you need to specify the complete type, e.
16602 \begin_inset space \thinspace{}
16603 \end_inset
16604
16605 g.
16606 \begin_inset space ~
16607 \end_inset
16608
16609
16610 \begin_inset Flex Code
16611 status collapsed
16612
16613 \begin_layout Plain Layout
16614 CopyStyle Flex:<name>
16615 \end_layout
16616
16617 \end_inset
16618
16619 .
16620 \end_layout
16621
16622 \begin_layout Description
16623 \begin_inset Flex Code
16624 status collapsed
16625
16626 \begin_layout Plain Layout
16627 CustomPars
16628 \end_layout
16629
16630 \end_inset
16631
16632  [
16633 \begin_inset Flex Code
16634 status collapsed
16635
16636 \begin_layout Plain Layout
16637
16638 \emph on
16639 0
16640 \end_layout
16641
16642 \end_inset
16643
16644 ,
16645 \begin_inset space \thinspace{}
16646 \end_inset
16647
16648
16649 \begin_inset Flex Code
16650 status collapsed
16651
16652 \begin_layout Plain Layout
16653 1
16654 \end_layout
16655
16656 \end_inset
16657
16658 ] Indicates whether the user may employ the Paragraph Settings dialog to
16659  customize the paragraph.
16660 \end_layout
16661
16662 \begin_layout Description
16663 \begin_inset Flex Code
16664 status collapsed
16665
16666 \begin_layout Plain Layout
16667 Decoration
16668 \end_layout
16669
16670 \end_inset
16671
16672  can be 
16673 \begin_inset Flex Code
16674 status collapsed
16675
16676 \begin_layout Plain Layout
16677 Classic
16678 \end_layout
16679
16680 \end_inset
16681
16682
16683 \begin_inset Flex Code
16684 status collapsed
16685
16686 \begin_layout Plain Layout
16687 Minimalistic
16688 \end_layout
16689
16690 \end_inset
16691
16692 , or 
16693 \begin_inset Flex Code
16694 status collapsed
16695
16696 \begin_layout Plain Layout
16697 Conglomerate
16698 \end_layout
16699
16700 \end_inset
16701
16702 , describing the rendering style used for the inset's frame and buttons.
16703  Footnotes generally use 
16704 \begin_inset Flex Code
16705 status collapsed
16706
16707 \begin_layout Plain Layout
16708 Classic
16709 \end_layout
16710
16711 \end_inset
16712
16713 , ERT insets generally 
16714 \begin_inset Flex Code
16715 status collapsed
16716
16717 \begin_layout Plain Layout
16718 Minimalistic
16719 \end_layout
16720
16721 \end_inset
16722
16723 , and character styles 
16724 \begin_inset Flex Code
16725 status collapsed
16726
16727 \begin_layout Plain Layout
16728 Conglomerate
16729 \end_layout
16730
16731 \end_inset
16732
16733 .
16734 \end_layout
16735
16736 \begin_layout Description
16737 \begin_inset Flex Code
16738 status collapsed
16739
16740 \begin_layout Plain Layout
16741 Display
16742 \end_layout
16743
16744 \end_inset
16745
16746  [
16747 \begin_inset Flex Code
16748 status collapsed
16749
16750 \begin_layout Plain Layout
16751 0
16752 \end_layout
16753
16754 \end_inset
16755
16756 ,
16757 \emph on
16758
16759 \begin_inset space \thinspace{}
16760 \end_inset
16761
16762
16763 \emph default
16764
16765 \begin_inset Flex Code
16766 status collapsed
16767
16768 \begin_layout Plain Layout
16769
16770 \emph on
16771 1
16772 \end_layout
16773
16774 \end_inset
16775
16776 ] Only useful if 
16777 \begin_inset Flex Code
16778 status collapsed
16779
16780 \begin_layout Plain Layout
16781 LatexType
16782 \end_layout
16783
16784 \end_inset
16785
16786  is 
16787 \begin_inset Flex Code
16788 status collapsed
16789
16790 \begin_layout Plain Layout
16791 Environment
16792 \end_layout
16793
16794 \end_inset
16795
16796 .
16797  Indicates whether the environment will stand on its own in the output or
16798  will appear inline with the surrounding text.
16799  If set to false, it is supposed that the LaTeX environment ignores white
16800  space (including one newline character) after the 
16801 \begin_inset Flex Code
16802 status collapsed
16803
16804 \begin_layout Plain Layout
16805
16806 \backslash
16807 begin{
16808 \emph on
16809 LatexName
16810 \emph default
16811 }
16812 \end_layout
16813
16814 \end_inset
16815
16816  and 
16817 \begin_inset Flex Code
16818 status collapsed
16819
16820 \begin_layout Plain Layout
16821
16822 \backslash
16823 end{
16824 \emph on
16825 LatexName
16826 \emph default
16827 }
16828 \end_layout
16829
16830 \end_inset
16831
16832  tags.
16833  Default is true.
16834 \end_layout
16835
16836 \begin_layout Description
16837 \begin_inset Flex Code
16838 status collapsed
16839
16840 \begin_layout Plain Layout
16841 End
16842 \end_layout
16843
16844 \end_inset
16845
16846  Required at the end of the 
16847 \begin_inset Flex Code
16848 status collapsed
16849
16850 \begin_layout Plain Layout
16851 InsetLayout
16852 \end_layout
16853
16854 \end_inset
16855
16856  declarations.
16857 \end_layout
16858
16859 \begin_layout Description
16860 \begin_inset Flex Code
16861 status collapsed
16862
16863 \begin_layout Plain Layout
16864 Font
16865 \end_layout
16866
16867 \end_inset
16868
16869  The font used for both the text body 
16870 \emph on
16871 and
16872 \emph default
16873  the label.
16874  See 
16875 \begin_inset CommandInset ref
16876 LatexCommand ref
16877 reference "sub:Font-description"
16878
16879 \end_inset
16880
16881 .
16882  Note that defining this font automatically defines the 
16883 \begin_inset Flex Code
16884 status collapsed
16885
16886 \begin_layout Plain Layout
16887 LabelFont
16888 \end_layout
16889
16890 \end_inset
16891
16892  to the same value, so define this first and define 
16893 \begin_inset Flex Code
16894 status collapsed
16895
16896 \begin_layout Plain Layout
16897 LabelFont
16898 \end_layout
16899
16900 \end_inset
16901
16902  later if you want them to be different.
16903 \end_layout
16904
16905 \begin_layout Description
16906 \begin_inset Flex Code
16907 status collapsed
16908
16909 \begin_layout Plain Layout
16910 ForceLocalFontSwitch
16911 \end_layout
16912
16913 \end_inset
16914
16915  [
16916 \begin_inset Flex Code
16917 status collapsed
16918
16919 \begin_layout Plain Layout
16920
16921 \emph on
16922 0
16923 \end_layout
16924
16925 \end_inset
16926
16927 ,
16928 \begin_inset space \thinspace{}
16929 \end_inset
16930
16931
16932 \begin_inset Flex Code
16933 status collapsed
16934
16935 \begin_layout Plain Layout
16936 1
16937 \end_layout
16938
16939 \end_inset
16940
16941 ] When using babel, always use a local font switch (
16942 \begin_inset Flex Code
16943 status collapsed
16944
16945 \begin_layout Plain Layout
16946
16947 \backslash
16948 foreignlanguage
16949 \end_layout
16950
16951 \end_inset
16952
16953 ), never a global one (such as 
16954 \begin_inset Flex Code
16955 status collapsed
16956
16957 \begin_layout Plain Layout
16958
16959 \backslash
16960 selectlanguage
16961 \end_layout
16962
16963 \end_inset
16964
16965 ).
16966 \end_layout
16967
16968 \begin_layout Description
16969 \begin_inset Flex Code
16970 status collapsed
16971
16972 \begin_layout Plain Layout
16973 ForceLTR
16974 \end_layout
16975
16976 \end_inset
16977
16978  [
16979 \begin_inset Flex Code
16980 status collapsed
16981
16982 \begin_layout Plain Layout
16983
16984 \emph on
16985 0
16986 \end_layout
16987
16988 \end_inset
16989
16990 ,
16991 \begin_inset space \thinspace{}
16992 \end_inset
16993
16994
16995 \begin_inset Flex Code
16996 status collapsed
16997
16998 \begin_layout Plain Layout
16999 1
17000 \end_layout
17001
17002 \end_inset
17003
17004 ] Force the 
17005 \begin_inset Quotes eld
17006 \end_inset
17007
17008 latex
17009 \begin_inset Quotes erd
17010 \end_inset
17011
17012  language, leading to Left-to-Right (Latin) output, e.
17013 \begin_inset space \thinspace{}
17014 \end_inset
17015
17016 g.
17017 \begin_inset space \space{}
17018 \end_inset
17019
17020 in TeX code or URL.
17021  A kludge.
17022 \end_layout
17023
17024 \begin_layout Description
17025 \begin_inset Flex Code
17026 status collapsed
17027
17028 \begin_layout Plain Layout
17029 ForcePlain
17030 \end_layout
17031
17032 \end_inset
17033
17034  [
17035 \begin_inset Flex Code
17036 status collapsed
17037
17038 \begin_layout Plain Layout
17039
17040 \emph on
17041 0
17042 \end_layout
17043
17044 \end_inset
17045
17046 ,
17047 \begin_inset space \thinspace{}
17048 \end_inset
17049
17050
17051 \begin_inset Flex Code
17052 status collapsed
17053
17054 \begin_layout Plain Layout
17055 1
17056 \end_layout
17057
17058 \end_inset
17059
17060 ] Indicates whether the 
17061 \begin_inset Flex Code
17062 status collapsed
17063
17064 \begin_layout Plain Layout
17065 PlainLayout
17066 \end_layout
17067
17068 \end_inset
17069
17070  should be used or, instead, the user can change the paragraph style used
17071  in the inset.
17072  Default is false.
17073 \end_layout
17074
17075 \begin_layout Description
17076 \begin_inset Flex Code
17077 status collapsed
17078
17079 \begin_layout Plain Layout
17080 FreeSpacing
17081 \end_layout
17082
17083 \end_inset
17084
17085  [
17086 \begin_inset Flex Code
17087 status collapsed
17088
17089 \begin_layout Plain Layout
17090
17091 \emph on
17092 0
17093 \end_layout
17094
17095 \end_inset
17096
17097 ,
17098 \begin_inset space \thinspace{}
17099 \end_inset
17100
17101
17102 \begin_inset Flex Code
17103 status collapsed
17104
17105 \begin_layout Plain Layout
17106 1
17107 \end_layout
17108
17109 \end_inset
17110
17111 ] As with paragraph styles, see 
17112 \begin_inset CommandInset ref
17113 LatexCommand ref
17114 reference "sub:Paragraph-Styles"
17115
17116 \end_inset
17117
17118 .
17119 \end_layout
17120
17121 \begin_layout Description
17122 \begin_inset Flex Code
17123 status collapsed
17124
17125 \begin_layout Plain Layout
17126 HTML*
17127 \end_layout
17128
17129 \end_inset
17130
17131  These tags control the XHTML output.
17132  See 
17133 \begin_inset CommandInset ref
17134 LatexCommand ref
17135 reference "sec:Tags-for-XHTML"
17136
17137 \end_inset
17138
17139 .
17140 \end_layout
17141
17142 \begin_layout Description
17143 \begin_inset Flex Code
17144 status collapsed
17145
17146 \begin_layout Plain Layout
17147 InToc
17148 \end_layout
17149
17150 \end_inset
17151
17152  [
17153 \begin_inset Flex Code
17154 status collapsed
17155
17156 \begin_layout Plain Layout
17157
17158 \emph on
17159 0
17160 \end_layout
17161
17162 \end_inset
17163
17164 ,
17165 \begin_inset space \thinspace{}
17166 \end_inset
17167
17168
17169 \begin_inset Flex Code
17170 status collapsed
17171
17172 \begin_layout Plain Layout
17173 1
17174 \end_layout
17175
17176 \end_inset
17177
17178 ] Whether to include the contents of this inset in the strings generated
17179  for the `Outline' pane.
17180  One would not, for example, want the content of a footnote in a section
17181  header to be included in the TOC displayed in the outline, but one would
17182  normally want the content of a character style displayed.
17183  Default is false: not to include.
17184 \end_layout
17185
17186 \begin_layout Description
17187 \begin_inset Flex Code
17188 status collapsed
17189
17190 \begin_layout Plain Layout
17191 KeepEmpty
17192 \end_layout
17193
17194 \end_inset
17195
17196  [
17197 \emph on
17198
17199 \begin_inset Flex Code
17200 status collapsed
17201
17202 \begin_layout Plain Layout
17203 0
17204 \end_layout
17205
17206 \end_inset
17207
17208
17209 \emph default
17210 ,
17211 \begin_inset space \thinspace{}
17212 \end_inset
17213
17214
17215 \begin_inset Flex Code
17216 status collapsed
17217
17218 \begin_layout Plain Layout
17219 1
17220 \end_layout
17221
17222 \end_inset
17223
17224 ] As with paragraph styles, see 
17225 \begin_inset CommandInset ref
17226 LatexCommand ref
17227 reference "sub:Paragraph-Styles"
17228
17229 \end_inset
17230
17231 .
17232 \end_layout
17233
17234 \begin_layout Description
17235 \begin_inset Flex Code
17236 status collapsed
17237
17238 \begin_layout Plain Layout
17239 LabelFont
17240 \end_layout
17241
17242 \end_inset
17243
17244  The font used for the label.
17245  See 
17246 \begin_inset CommandInset ref
17247 LatexCommand ref
17248 reference "sub:Font-description"
17249
17250 \end_inset
17251
17252 .
17253  Note that this definition can never appear before 
17254 \begin_inset Flex Code
17255 status collapsed
17256
17257 \begin_layout Plain Layout
17258 Font
17259 \end_layout
17260
17261 \end_inset
17262
17263 , lest it be ineffective.
17264 \end_layout
17265
17266 \begin_layout Description
17267 \begin_inset Flex Code
17268 status collapsed
17269
17270 \begin_layout Plain Layout
17271 LabelString
17272 \end_layout
17273
17274 \end_inset
17275
17276  [
17277 \begin_inset Flex Code
17278 status collapsed
17279
17280 \begin_layout Plain Layout
17281 string
17282 \end_layout
17283
17284 \end_inset
17285
17286 =
17287 \begin_inset Quotes erd
17288 \end_inset
17289
17290
17291 \begin_inset Quotes erd
17292 \end_inset
17293
17294 ] What will be displayed on the button or elsewhere as the inset label.
17295  Some inset types (
17296 \begin_inset Flex Code
17297 status collapsed
17298
17299 \begin_layout Plain Layout
17300 TeX code
17301 \end_layout
17302
17303 \end_inset
17304
17305  and 
17306 \begin_inset Flex Code
17307 status collapsed
17308
17309 \begin_layout Plain Layout
17310 Branch
17311 \end_layout
17312
17313 \end_inset
17314
17315 ) modify this label on the fly.
17316 \end_layout
17317
17318 \begin_layout Description
17319 \begin_inset Flex Code
17320 status collapsed
17321
17322 \begin_layout Plain Layout
17323 LangPreamble
17324 \end_layout
17325
17326 \end_inset
17327
17328  Language dependent preamble; see 
17329 \begin_inset CommandInset ref
17330 LatexCommand ref
17331 reference "sub:I18n"
17332
17333 \end_inset
17334
17335 .
17336 \end_layout
17337
17338 \begin_layout Description
17339 \begin_inset Flex Code
17340 status collapsed
17341
17342 \begin_layout Plain Layout
17343 LatexName
17344 \end_layout
17345
17346 \end_inset
17347
17348  [
17349 \begin_inset Flex Code
17350 status collapsed
17351
17352 \begin_layout Plain Layout
17353 <name>
17354 \end_layout
17355
17356 \end_inset
17357
17358 ] The name of the corresponding LaTeX stuff.
17359  Either the environment or command name.
17360 \end_layout
17361
17362 \begin_layout Description
17363 \begin_inset Flex Code
17364 status collapsed
17365
17366 \begin_layout Plain Layout
17367 LatexParam
17368 \end_layout
17369
17370 \end_inset
17371
17372  [
17373 \begin_inset Flex Code
17374 status collapsed
17375
17376 \begin_layout Plain Layout
17377 <parameter>
17378 \end_layout
17379
17380 \end_inset
17381
17382 ] The optional parameter for the corresponding 
17383 \begin_inset Flex Code
17384 status collapsed
17385
17386 \begin_layout Plain Layout
17387 LatexName
17388 \end_layout
17389
17390 \end_inset
17391
17392  stuff, including possible bracket pairs like 
17393 \begin_inset Flex Code
17394 status collapsed
17395
17396 \begin_layout Plain Layout
17397 []
17398 \end_layout
17399
17400 \end_inset
17401
17402 .
17403  This parameter cannot be changed from within LyX (use 
17404 \begin_inset Flex Code
17405 status collapsed
17406
17407 \begin_layout Plain Layout
17408 Argument
17409 \end_layout
17410
17411 \end_inset
17412
17413  for customizable parameters).
17414  It will be output as is after all LaTeX 
17415 \begin_inset Flex Code
17416 status collapsed
17417
17418 \begin_layout Plain Layout
17419 Argument
17420 \end_layout
17421
17422 \end_inset
17423
17424 s.
17425 \end_layout
17426
17427 \begin_layout Description
17428 \begin_inset Flex Code
17429 status collapsed
17430
17431 \begin_layout Plain Layout
17432 LatexType
17433 \end_layout
17434
17435 \end_inset
17436
17437  [
17438 \begin_inset Flex Code
17439 status collapsed
17440
17441 \begin_layout Plain Layout
17442 Command, Environment, None
17443 \end_layout
17444
17445 \end_inset
17446
17447 ] How the style should be translated into LaTeX.
17448 \begin_inset Foot
17449 status collapsed
17450
17451 \begin_layout Plain Layout
17452 \begin_inset Flex Code
17453 status collapsed
17454
17455 \begin_layout Plain Layout
17456 LatexType
17457 \end_layout
17458
17459 \end_inset
17460
17461  is perhaps a bit misleading, since these rules apply to SGML classes too.
17462  Visit the SGML class files for specific examples.
17463 \end_layout
17464
17465 \end_inset
17466
17467
17468 \begin_inset Separator parbreak
17469 \end_inset
17470
17471
17472 \end_layout
17473
17474 \begin_deeper
17475 \begin_layout Description
17476 \begin_inset Flex Code
17477 status collapsed
17478
17479 \begin_layout Plain Layout
17480 None
17481 \end_layout
17482
17483 \end_inset
17484
17485  means nothing special
17486 \end_layout
17487
17488 \begin_layout Description
17489 \begin_inset Flex Code
17490 status collapsed
17491
17492 \begin_layout Plain Layout
17493 Command
17494 \end_layout
17495
17496 \end_inset
17497
17498  means 
17499 \begin_inset Flex Code
17500 status collapsed
17501
17502 \begin_layout Plain Layout
17503
17504 \backslash
17505
17506 \emph on
17507 LatexName
17508 \emph default
17509 {\SpecialChar \ldots{}
17510 }
17511 \end_layout
17512
17513 \end_inset
17514
17515
17516 \end_layout
17517
17518 \begin_layout Description
17519 \begin_inset Flex Code
17520 status collapsed
17521
17522 \begin_layout Plain Layout
17523 Environment
17524 \end_layout
17525
17526 \end_inset
17527
17528  means 
17529 \begin_inset Flex Code
17530 status collapsed
17531
17532 \begin_layout Plain Layout
17533
17534 \backslash
17535 begin{
17536 \emph on
17537 LatexName
17538 \emph default
17539 }\SpecialChar \ldots{}
17540
17541 \backslash
17542 end{
17543 \emph on
17544 LatexName
17545 \emph default
17546 }
17547 \end_layout
17548
17549 \end_inset
17550
17551
17552 \end_layout
17553
17554 \begin_layout Standard
17555 Putting the last few things together, the LaTeX output will be either: 
17556 \end_layout
17557
17558 \begin_layout LyX-Code
17559
17560 \backslash
17561 LatexName[LatexParam]{\SpecialChar \ldots{}
17562 }
17563 \end_layout
17564
17565 \begin_layout Standard
17566 or: 
17567 \end_layout
17568
17569 \begin_layout LyX-Code
17570
17571 \backslash
17572 begin{LatexName}[LatexParam] \SpecialChar \ldots{}
17573  
17574 \backslash
17575 end{LatexName}
17576 \end_layout
17577
17578 \begin_layout Standard
17579 depending upon the LaTeX type.
17580 \end_layout
17581
17582 \end_deeper
17583 \begin_layout Description
17584 \begin_inset Flex Code
17585 status collapsed
17586
17587 \begin_layout Plain Layout
17588 LeftDelim
17589 \end_layout
17590
17591 \end_inset
17592
17593  [
17594 \begin_inset Flex Code
17595 status collapsed
17596
17597 \begin_layout Plain Layout
17598 string
17599 \end_layout
17600
17601 \end_inset
17602
17603 ] A string that is put at the beginning of the layout content.
17604  A line break in the output can be indicated by 
17605 \begin_inset Flex Code
17606 status collapsed
17607
17608 \begin_layout Plain Layout
17609 <br/>
17610 \end_layout
17611
17612 \end_inset
17613
17614 .
17615 \end_layout
17616
17617 \begin_layout Description
17618 \begin_inset Flex Code
17619 status collapsed
17620
17621 \begin_layout Plain Layout
17622 LyxType
17623 \end_layout
17624
17625 \end_inset
17626
17627  Can be 
17628 \begin_inset Flex Code
17629 status collapsed
17630
17631 \begin_layout Plain Layout
17632 charstyle
17633 \end_layout
17634
17635 \end_inset
17636
17637
17638 \begin_inset Flex Code
17639 status collapsed
17640
17641 \begin_layout Plain Layout
17642 custom
17643 \end_layout
17644
17645 \end_inset
17646
17647
17648 \begin_inset Flex Code
17649 status collapsed
17650
17651 \begin_layout Plain Layout
17652 element
17653 \end_layout
17654
17655 \end_inset
17656
17657  or 
17658 \begin_inset Flex Code
17659 status collapsed
17660
17661 \begin_layout Plain Layout
17662 end
17663 \end_layout
17664
17665 \end_inset
17666
17667  (indicating a dummy definition ending definitions of charstyles, etc).
17668  This entry is required in and is only meaningful for Flex insets.
17669  Among other things, it determines on which menu this inset will appear.
17670  Setting 
17671 \begin_inset Flex Code
17672 status collapsed
17673
17674 \begin_layout Plain Layout
17675 LyXType
17676 \end_layout
17677
17678 \end_inset
17679
17680  to 
17681 \begin_inset Flex Code
17682 status collapsed
17683
17684 \begin_layout Plain Layout
17685 charstyle
17686 \end_layout
17687
17688 \end_inset
17689
17690  will automatically set 
17691 \begin_inset Flex Code
17692 status collapsed
17693
17694 \begin_layout Plain Layout
17695 MultiPar
17696 \end_layout
17697
17698 \end_inset
17699
17700  to false.
17701  
17702 \begin_inset Flex Code
17703 status collapsed
17704
17705 \begin_layout Plain Layout
17706 MultiPar
17707 \end_layout
17708
17709 \end_inset
17710
17711  can be set to true for 
17712 \begin_inset Flex Code
17713 status collapsed
17714
17715 \begin_layout Plain Layout
17716 charstyle
17717 \end_layout
17718
17719 \end_inset
17720
17721  insets by setting it 
17722 \emph on
17723 after
17724 \emph default
17725  you set the 
17726 \begin_inset Flex Code
17727 status collapsed
17728
17729 \begin_layout Plain Layout
17730 LyXType
17731 \end_layout
17732
17733 \end_inset
17734
17735 .
17736 \end_layout
17737
17738 \begin_layout Description
17739 \begin_inset Flex Code
17740 status collapsed
17741
17742 \begin_layout Plain Layout
17743 MultiPar
17744 \end_layout
17745
17746 \end_inset
17747
17748  [
17749 \begin_inset Flex Code
17750 status collapsed
17751
17752 \begin_layout Plain Layout
17753
17754 \emph on
17755 0
17756 \end_layout
17757
17758 \end_inset
17759
17760 ,
17761 \begin_inset space \thinspace{}
17762 \end_inset
17763
17764
17765 \begin_inset Flex Code
17766 status collapsed
17767
17768 \begin_layout Plain Layout
17769 1
17770 \end_layout
17771
17772 \end_inset
17773
17774 ] Whether multiple paragraphs are permitted in this inset.
17775  This will also set 
17776 \begin_inset Flex Code
17777 status collapsed
17778
17779 \begin_layout Plain Layout
17780 CustomPars
17781 \end_layout
17782
17783 \end_inset
17784
17785  to the same value and 
17786 \begin_inset Flex Code
17787 status collapsed
17788
17789 \begin_layout Plain Layout
17790 ForcePlain
17791 \end_layout
17792
17793 \end_inset
17794
17795  to the opposite value.
17796  These can be reset to other values, if they are used 
17797 \emph on
17798 after
17799 \emph default
17800  
17801 \begin_inset Flex Code
17802 status collapsed
17803
17804 \begin_layout Plain Layout
17805 MultiPar
17806 \end_layout
17807
17808 \end_inset
17809
17810 .
17811  Default is true.
17812 \end_layout
17813
17814 \begin_layout Description
17815 \begin_inset Flex Code
17816 status collapsed
17817
17818 \begin_layout Plain Layout
17819 NeedProtect
17820 \end_layout
17821
17822 \end_inset
17823
17824  [
17825 \begin_inset Flex Code
17826 status collapsed
17827
17828 \begin_layout Plain Layout
17829
17830 \emph on
17831 0
17832 \end_layout
17833
17834 \end_inset
17835
17836 ,
17837 \begin_inset space \thinspace{}
17838 \end_inset
17839
17840
17841 \begin_inset Flex Code
17842 status collapsed
17843
17844 \begin_layout Plain Layout
17845 1
17846 \end_layout
17847
17848 \end_inset
17849
17850 ] Whether fragile commands in this inset should be 
17851 \begin_inset Flex Code
17852 status collapsed
17853
17854 \begin_layout Plain Layout
17855
17856 \backslash
17857 protect
17858 \end_layout
17859
17860 \end_inset
17861
17862 'ed.
17863  (Note: This is 
17864 \emph on
17865 not
17866 \emph default
17867  whether the command should itself be protected.) Default is false.
17868 \end_layout
17869
17870 \begin_layout Description
17871 \begin_inset Flex Code
17872 status collapsed
17873
17874 \begin_layout Plain Layout
17875 NoInsetLayout
17876 \end_layout
17877
17878 \end_inset
17879
17880  [
17881 \begin_inset Flex Code
17882 status collapsed
17883
17884 \begin_layout Plain Layout
17885 <layout>
17886 \end_layout
17887
17888 \end_inset
17889
17890 ] Deletes an existing 
17891 \begin_inset Flex Code
17892 status collapsed
17893
17894 \begin_layout Plain Layout
17895 InsetLayout
17896 \end_layout
17897
17898 \end_inset
17899
17900 .
17901 \end_layout
17902
17903 \begin_layout Description
17904 \begin_inset Flex Code
17905 status collapsed
17906
17907 \begin_layout Plain Layout
17908 ParbreakIsNewline
17909 \end_layout
17910
17911 \end_inset
17912
17913  [
17914 \begin_inset Flex Code
17915 status collapsed
17916
17917 \begin_layout Plain Layout
17918
17919 \emph on
17920 0
17921 \end_layout
17922
17923 \end_inset
17924
17925 ,
17926 \begin_inset space \thinspace{}
17927 \end_inset
17928
17929
17930 \begin_inset Flex Code
17931 status collapsed
17932
17933 \begin_layout Plain Layout
17934 1
17935 \end_layout
17936
17937 \end_inset
17938
17939 ] As with paragraph styles, see 
17940 \begin_inset CommandInset ref
17941 LatexCommand ref
17942 reference "sub:Paragraph-Styles"
17943
17944 \end_inset
17945
17946 .
17947  Default is false.
17948 \end_layout
17949
17950 \begin_layout Description
17951 \begin_inset Flex Code
17952 status collapsed
17953
17954 \begin_layout Plain Layout
17955 PassThru
17956 \end_layout
17957
17958 \end_inset
17959
17960  [
17961 \begin_inset Flex Code
17962 status collapsed
17963
17964 \begin_layout Plain Layout
17965
17966 \emph on
17967 0
17968 \end_layout
17969
17970 \end_inset
17971
17972 ,
17973 \begin_inset space \thinspace{}
17974 \end_inset
17975
17976
17977 \begin_inset Flex Code
17978 status collapsed
17979
17980 \begin_layout Plain Layout
17981 1
17982 \end_layout
17983
17984 \end_inset
17985
17986 ] As with paragraph styles, see 
17987 \begin_inset CommandInset ref
17988 LatexCommand ref
17989 reference "sub:Paragraph-Styles"
17990
17991 \end_inset
17992
17993 .
17994  Default is false.
17995 \end_layout
17996
17997 \begin_layout Description
17998 \begin_inset Flex Code
17999 status collapsed
18000
18001 \begin_layout Plain Layout
18002 Preamble
18003 \end_layout
18004
18005 \end_inset
18006
18007  As with paragraph styles, see 
18008 \begin_inset CommandInset ref
18009 LatexCommand ref
18010 reference "sub:Paragraph-Styles"
18011
18012 \end_inset
18013
18014 .
18015 \end_layout
18016
18017 \begin_layout Description
18018 \begin_inset Flex Code
18019 status collapsed
18020
18021 \begin_layout Plain Layout
18022 RefPrefix
18023 \end_layout
18024
18025 \end_inset
18026
18027  [
18028 \begin_inset Flex Code
18029 status collapsed
18030
18031 \begin_layout Plain Layout
18032 string
18033 \end_layout
18034
18035 \end_inset
18036
18037 ] The prefix to use when creating labels referring to insets of this type.
18038  This allows the use of formatted references.
18039 \end_layout
18040
18041 \begin_layout Description
18042 \begin_inset Flex Code
18043 status collapsed
18044
18045 \begin_layout Plain Layout
18046 Requires
18047 \end_layout
18048
18049 \end_inset
18050
18051  [
18052 \begin_inset Flex Code
18053 status collapsed
18054
18055 \begin_layout Plain Layout
18056 string
18057 \end_layout
18058
18059 \end_inset
18060
18061 ] As with paragraph styles, see 
18062 \begin_inset CommandInset ref
18063 LatexCommand ref
18064 reference "sub:Paragraph-Styles"
18065
18066 \end_inset
18067
18068 .
18069 \end_layout
18070
18071 \begin_layout Description
18072 \begin_inset Flex Code
18073 status collapsed
18074
18075 \begin_layout Plain Layout
18076 ResetArgs
18077 \end_layout
18078
18079 \end_inset
18080
18081  [
18082 \begin_inset Flex Code
18083 status collapsed
18084
18085 \begin_layout Plain Layout
18086
18087 \emph on
18088 0
18089 \end_layout
18090
18091 \end_inset
18092
18093 ,
18094 \begin_inset space \thinspace{}
18095 \end_inset
18096
18097
18098 \begin_inset Flex Code
18099 status collapsed
18100
18101 \begin_layout Plain Layout
18102 1
18103 \end_layout
18104
18105 \end_inset
18106
18107 ] Resets the LaTeX arguments of this layout (as defined via the 
18108 \begin_inset Flex Code
18109 status collapsed
18110
18111 \begin_layout Plain Layout
18112 Argument
18113 \end_layout
18114
18115 \end_inset
18116
18117  tag).
18118  This is useful if you have copied a style via 
18119 \begin_inset Flex Code
18120 status collapsed
18121
18122 \begin_layout Plain Layout
18123 CopyStyle
18124 \end_layout
18125
18126 \end_inset
18127
18128 , but you do not want to inherit its (required and optional) arguments.
18129 \end_layout
18130
18131 \begin_layout Description
18132 \begin_inset Flex Code
18133 status collapsed
18134
18135 \begin_layout Plain Layout
18136 ResetsFont
18137 \end_layout
18138
18139 \end_inset
18140
18141  [
18142 \begin_inset Flex Code
18143 status collapsed
18144
18145 \begin_layout Plain Layout
18146 0
18147 \end_layout
18148
18149 \end_inset
18150
18151 ,
18152 \begin_inset space \thinspace{}
18153 \end_inset
18154
18155
18156 \begin_inset Flex Code
18157 status collapsed
18158
18159 \begin_layout Plain Layout
18160
18161 \emph on
18162 1
18163 \end_layout
18164
18165 \end_inset
18166
18167 ] Whether this inset should use the font of its surrounding environment
18168  or uses its own.
18169  Default is false: use the font of the surrounding environment.
18170 \end_layout
18171
18172 \begin_layout Description
18173 \begin_inset Flex Code
18174 status collapsed
18175
18176 \begin_layout Plain Layout
18177 RightDelim
18178 \end_layout
18179
18180 \end_inset
18181
18182  [
18183 \begin_inset Flex Code
18184 status collapsed
18185
18186 \begin_layout Plain Layout
18187 string
18188 \end_layout
18189
18190 \end_inset
18191
18192 ] A string that is put at the end of the layout content.
18193  A line break in the output can be indicated by 
18194 \begin_inset Flex Code
18195 status collapsed
18196
18197 \begin_layout Plain Layout
18198 <br/>
18199 \end_layout
18200
18201 \end_inset
18202
18203 .
18204 \end_layout
18205
18206 \begin_layout Description
18207 \begin_inset Flex Code
18208 status collapsed
18209
18210 \begin_layout Plain Layout
18211 Spellcheck
18212 \end_layout
18213
18214 \end_inset
18215
18216  [
18217 \begin_inset Flex Code
18218 status collapsed
18219
18220 \begin_layout Plain Layout
18221 0
18222 \end_layout
18223
18224 \end_inset
18225
18226 ,
18227 \begin_inset space \thinspace{}
18228 \end_inset
18229
18230
18231 \begin_inset Flex Code
18232 status collapsed
18233
18234 \begin_layout Plain Layout
18235
18236 \emph on
18237 1
18238 \end_layout
18239
18240 \end_inset
18241
18242 ] Allow spell-checking the contents of this inset.
18243  Default is true.
18244 \end_layout
18245
18246 \begin_layout Subsection
18247 Counters
18248 \begin_inset CommandInset label
18249 LatexCommand label
18250 name "sub:Counters"
18251
18252 \end_inset
18253
18254
18255 \end_layout
18256
18257 \begin_layout Standard
18258 It is necessary to define the counters (
18259 \begin_inset Flex MenuItem
18260 status collapsed
18261
18262 \begin_layout Plain Layout
18263 chapter
18264 \end_layout
18265
18266 \end_inset
18267
18268
18269 \begin_inset Flex MenuItem
18270 status collapsed
18271
18272 \begin_layout Plain Layout
18273 figure
18274 \end_layout
18275
18276 \end_inset
18277
18278 , \SpecialChar \ldots{}
18279 ) in the text class itself.
18280  The standard counters are defined in the file 
18281 \begin_inset Flex Code
18282 status collapsed
18283
18284 \begin_layout Plain Layout
18285 stdcounters.inc
18286 \end_layout
18287
18288 \end_inset
18289
18290 , so you may have to do no more than add
18291 \end_layout
18292
18293 \begin_layout LyX-Code
18294 Input stdcounters.inc
18295 \end_layout
18296
18297 \begin_layout Standard
18298 to your layout file to get them to work.
18299  But if you want to define custom counters, then you can do so.
18300  The counter declaration must begin with:
18301 \end_layout
18302
18303 \begin_layout LyX-Code
18304 Counter CounterName
18305 \end_layout
18306
18307 \begin_layout Standard
18308 where of course `
18309 \begin_inset Flex Code
18310 status collapsed
18311
18312 \begin_layout Plain Layout
18313 CounterName
18314 \end_layout
18315
18316 \end_inset
18317
18318 ' is replaced by the name of the counter.
18319  And it must end with 
18320 \begin_inset Quotes eld
18321 \end_inset
18322
18323
18324 \begin_inset Flex Code
18325 status collapsed
18326
18327 \begin_layout Plain Layout
18328 End
18329 \end_layout
18330
18331 \end_inset
18332
18333
18334 \begin_inset Quotes erd
18335 \end_inset
18336
18337 .
18338  The following parameters can also be used:
18339 \end_layout
18340
18341 \begin_layout Description
18342 \begin_inset Flex Code
18343 status collapsed
18344
18345 \begin_layout Plain Layout
18346 InitialValue
18347 \end_layout
18348
18349 \end_inset
18350
18351  [
18352 \begin_inset Flex Code
18353 status collapsed
18354
18355 \begin_layout Plain Layout
18356 int=1
18357 \end_layout
18358
18359 \end_inset
18360
18361 ] Sets the initial value for the counter, to which it will be reset whenever
18362  that happens.
18363  Normally, one will want the default, 1.
18364 \end_layout
18365
18366 \begin_layout Description
18367 \begin_inset Flex Code
18368 status collapsed
18369
18370 \begin_layout Plain Layout
18371 LabelString
18372 \end_layout
18373
18374 \end_inset
18375
18376  [
18377 \begin_inset Flex Code
18378 status collapsed
18379
18380 \begin_layout Plain Layout
18381 string
18382 \end_layout
18383
18384 \end_inset
18385
18386 =
18387 \begin_inset Quotes erd
18388 \end_inset
18389
18390
18391 \begin_inset Quotes erd
18392 \end_inset
18393
18394 ] When defined, this string defines how the counter is displayed.
18395  Setting this value sets 
18396 \begin_inset Flex Code
18397 status collapsed
18398
18399 \begin_layout Plain Layout
18400 LabelStringAppendix
18401 \end_layout
18402
18403 \end_inset
18404
18405  to the same value.
18406  The following special constructs can be used in the string:
18407 \begin_inset Separator parbreak
18408 \end_inset
18409
18410
18411 \end_layout
18412
18413 \begin_deeper
18414 \begin_layout Itemize
18415 \begin_inset Flex Code
18416 status collapsed
18417
18418 \begin_layout Plain Layout
18419
18420 \backslash
18421 thecounter
18422 \end_layout
18423
18424 \end_inset
18425
18426  will be replaced by the expansion of the 
18427 \begin_inset Flex Code
18428 status collapsed
18429
18430 \begin_layout Plain Layout
18431 LabelString
18432 \end_layout
18433
18434 \end_inset
18435
18436  (or 
18437 \begin_inset Flex Code
18438 status collapsed
18439
18440 \begin_layout Plain Layout
18441 LabelStringAppendix
18442 \end_layout
18443
18444 \end_inset
18445
18446 ) of the counter 
18447 \begin_inset Flex Code
18448 status collapsed
18449
18450 \begin_layout Plain Layout
18451 counter
18452 \end_layout
18453
18454 \end_inset
18455
18456 .
18457  
18458 \end_layout
18459
18460 \begin_layout Itemize
18461 counter values can be expressed using LaTeX-like macros
18462 \begin_inset Newline newline
18463 \end_inset
18464
18465
18466 \begin_inset Flex Code
18467 status collapsed
18468
18469 \begin_layout Plain Layout
18470
18471 \backslash
18472
18473 \emph on
18474 numbertype
18475 \emph default
18476 {
18477 \emph on
18478 counter
18479 \emph default
18480 }
18481 \end_layout
18482
18483 \end_inset
18484
18485 , where 
18486 \begin_inset Flex Code
18487 status collapsed
18488
18489 \begin_layout Plain Layout
18490
18491 \emph on
18492 numbertype
18493 \end_layout
18494
18495 \end_inset
18496
18497  can be:
18498 \begin_inset Foot
18499 status collapsed
18500
18501 \begin_layout Plain Layout
18502
18503 \family roman
18504 \series medium
18505 \shape up
18506 \size normal
18507 \emph off
18508 \bar no
18509 \noun off
18510 \color none
18511 Actually, the situation is a bit more complicated: any
18512 \family default
18513 \series default
18514 \shape default
18515 \emph default
18516 \bar default
18517  
18518 \size default
18519 \emph on
18520 \noun default
18521 \color inherit
18522 numbertype
18523 \family roman
18524 \series medium
18525 \shape up
18526 \size normal
18527 \emph off
18528 \bar no
18529 \noun off
18530  other than those described below will produce arabic numerals.
18531  It would not be surprising to see this change in the future.
18532 \end_layout
18533
18534 \end_inset
18535
18536  
18537 \begin_inset Flex Code
18538 status collapsed
18539
18540 \begin_layout Plain Layout
18541 arabic
18542 \end_layout
18543
18544 \end_inset
18545
18546 : 1, 2, 3,\SpecialChar \ldots{}
18547
18548 \begin_inset Flex Code
18549 status collapsed
18550
18551 \begin_layout Plain Layout
18552 alph
18553 \end_layout
18554
18555 \end_inset
18556
18557  for lower-case letters: a, b, c, \SpecialChar \ldots{}
18558
18559 \begin_inset Flex Code
18560 status collapsed
18561
18562 \begin_layout Plain Layout
18563 Alph
18564 \end_layout
18565
18566 \end_inset
18567
18568  for upper-case letters: A, B, C, \SpecialChar \ldots{}
18569
18570 \begin_inset Flex Code
18571 status collapsed
18572
18573 \begin_layout Plain Layout
18574 roman
18575 \end_layout
18576
18577 \end_inset
18578
18579  for lower-case roman numerals: i, ii, iii, \SpecialChar \ldots{}
18580
18581 \begin_inset Flex Code
18582 status collapsed
18583
18584 \begin_layout Plain Layout
18585 Roman
18586 \end_layout
18587
18588 \end_inset
18589
18590  for upper-case roman numerals: I, II, III\SpecialChar \ldots{}
18591
18592 \begin_inset Flex Code
18593 status collapsed
18594
18595 \begin_layout Plain Layout
18596 hebrew
18597 \end_layout
18598
18599 \end_inset
18600
18601  for hebrew numerals.
18602 \end_layout
18603
18604 \end_deeper
18605 \begin_layout Standard
18606 If LabelString is not defined, a default value is constructed as follows:
18607  if the counter has a master counter 
18608 \begin_inset Flex Code
18609 status collapsed
18610
18611 \begin_layout Plain Layout
18612 master
18613 \end_layout
18614
18615 \end_inset
18616
18617  (defined via 
18618 \begin_inset Flex Code
18619 status collapsed
18620
18621 \begin_layout Plain Layout
18622 Within
18623 \end_layout
18624
18625 \end_inset
18626
18627 ), the string
18628 \begin_inset Newline newline
18629 \end_inset
18630
18631
18632 \begin_inset Flex Code
18633 status collapsed
18634
18635 \begin_layout Plain Layout
18636
18637 \backslash
18638 themaster.
18639 \backslash
18640 arabic{counter}
18641 \end_layout
18642
18643 \end_inset
18644
18645  is used; otherwise the string 
18646 \begin_inset Flex Code
18647 status collapsed
18648
18649 \begin_layout Plain Layout
18650
18651 \backslash
18652 arabic{counter}
18653 \end_layout
18654
18655 \end_inset
18656
18657  is used.
18658 \end_layout
18659
18660 \begin_layout Description
18661 \begin_inset Flex Code
18662 status collapsed
18663
18664 \begin_layout Plain Layout
18665 LabelStringAppendix
18666 \end_layout
18667
18668 \end_inset
18669
18670  [
18671 \begin_inset Flex Code
18672 status collapsed
18673
18674 \begin_layout Plain Layout
18675 string
18676 \end_layout
18677
18678 \end_inset
18679
18680 =
18681 \begin_inset Quotes erd
18682 \end_inset
18683
18684
18685 \begin_inset Quotes erd
18686 \end_inset
18687
18688 ] Same as 
18689 \begin_inset Flex Code
18690 status collapsed
18691
18692 \begin_layout Plain Layout
18693 LabelString
18694 \end_layout
18695
18696 \end_inset
18697
18698 , but for use in the Appendix.
18699 \end_layout
18700
18701 \begin_layout Description
18702 \begin_inset Flex Code
18703 status collapsed
18704
18705 \begin_layout Plain Layout
18706 PrettyFormat
18707 \end_layout
18708
18709 \end_inset
18710
18711  [
18712 \begin_inset Flex Code
18713 status collapsed
18714
18715 \begin_layout Plain Layout
18716 string
18717 \end_layout
18718
18719 \end_inset
18720
18721 =
18722 \begin_inset Quotes erd
18723 \end_inset
18724
18725
18726 \begin_inset Quotes erd
18727 \end_inset
18728
18729 ] A format for use with formatted references to this counter.
18730  For example, one might want to have references to section numbers appear
18731  as 
18732 \begin_inset Quotes eld
18733 \end_inset
18734
18735 Section 2.4
18736 \begin_inset Quotes erd
18737 \end_inset
18738
18739 .
18740  The string should contain 
18741 \begin_inset Quotes eld
18742 \end_inset
18743
18744 ##
18745 \begin_inset Quotes erd
18746 \end_inset
18747
18748 .
18749  This will be replaced by the counter number itself.
18750  So, for sections, it would be: Section ##.
18751 \end_layout
18752
18753 \begin_layout Description
18754 \begin_inset Flex Code
18755 status collapsed
18756
18757 \begin_layout Plain Layout
18758 Within
18759 \end_layout
18760
18761 \end_inset
18762
18763  [
18764 \begin_inset Flex Code
18765 status collapsed
18766
18767 \begin_layout Plain Layout
18768 string
18769 \end_layout
18770
18771 \end_inset
18772
18773 =
18774 \begin_inset Quotes erd
18775 \end_inset
18776
18777
18778 \begin_inset Quotes erd
18779 \end_inset
18780
18781 ] If this is set to the name of another counter, the present counter will
18782  be reset every time the other one is increased.
18783  For example, 
18784 \begin_inset Flex Code
18785 status collapsed
18786
18787 \begin_layout Plain Layout
18788 subsection
18789 \end_layout
18790
18791 \end_inset
18792
18793  is numbered inside 
18794 \begin_inset Flex Code
18795 status collapsed
18796
18797 \begin_layout Plain Layout
18798 section
18799 \end_layout
18800
18801 \end_inset
18802
18803 .
18804 \end_layout
18805
18806 \begin_layout Subsection
18807 Font description
18808 \begin_inset CommandInset label
18809 LatexCommand label
18810 name "sub:Font-description"
18811
18812 \end_inset
18813
18814
18815 \end_layout
18816
18817 \begin_layout Standard
18818 A font description looks like this:
18819 \end_layout
18820
18821 \begin_layout LyX-Code
18822 Font 
18823 \family roman
18824 \emph on
18825 or
18826 \family default
18827 \emph default
18828  LabelFont
18829 \emph on
18830  or
18831 \emph default
18832  DefaultFont
18833 \end_layout
18834
18835 \begin_layout LyX-Code
18836  ...
18837 \end_layout
18838
18839 \begin_layout LyX-Code
18840 EndFont
18841 \end_layout
18842
18843 \begin_layout Standard
18844 The following commands are available:
18845 \end_layout
18846
18847 \begin_layout Description
18848 \begin_inset Flex Code
18849 status collapsed
18850
18851 \begin_layout Plain Layout
18852 Color
18853 \end_layout
18854
18855 \end_inset
18856
18857  [
18858 \begin_inset Flex Code
18859 status collapsed
18860
18861 \begin_layout Plain Layout
18862
18863 \emph on
18864 none
18865 \end_layout
18866
18867 \end_inset
18868
18869
18870 \begin_inset Flex Code
18871 status collapsed
18872
18873 \begin_layout Plain Layout
18874 black
18875 \end_layout
18876
18877 \end_inset
18878
18879
18880 \begin_inset Flex Code
18881 status collapsed
18882
18883 \begin_layout Plain Layout
18884 white
18885 \end_layout
18886
18887 \end_inset
18888
18889
18890 \begin_inset Flex Code
18891 status collapsed
18892
18893 \begin_layout Plain Layout
18894 red
18895 \end_layout
18896
18897 \end_inset
18898
18899
18900 \begin_inset Flex Code
18901 status collapsed
18902
18903 \begin_layout Plain Layout
18904 green
18905 \end_layout
18906
18907 \end_inset
18908
18909
18910 \begin_inset Flex Code
18911 status collapsed
18912
18913 \begin_layout Plain Layout
18914 blue
18915 \end_layout
18916
18917 \end_inset
18918
18919
18920 \begin_inset Flex Code
18921 status collapsed
18922
18923 \begin_layout Plain Layout
18924 cyan
18925 \end_layout
18926
18927 \end_inset
18928
18929
18930 \begin_inset Flex Code
18931 status collapsed
18932
18933 \begin_layout Plain Layout
18934 magenta
18935 \end_layout
18936
18937 \end_inset
18938
18939
18940 \begin_inset Flex Code
18941 status collapsed
18942
18943 \begin_layout Plain Layout
18944 yellow
18945 \end_layout
18946
18947 \end_inset
18948
18949 ]
18950 \end_layout
18951
18952 \begin_layout Description
18953 \begin_inset Flex Code
18954 status collapsed
18955
18956 \begin_layout Plain Layout
18957 Family
18958 \end_layout
18959
18960 \end_inset
18961
18962  [
18963 \begin_inset Flex Code
18964 status collapsed
18965
18966 \begin_layout Plain Layout
18967
18968 \emph on
18969 Roman
18970 \end_layout
18971
18972 \end_inset
18973
18974
18975 \begin_inset Flex Code
18976 status collapsed
18977
18978 \begin_layout Plain Layout
18979 Sans
18980 \end_layout
18981
18982 \end_inset
18983
18984
18985 \begin_inset Flex Code
18986 status collapsed
18987
18988 \begin_layout Plain Layout
18989 Typewriter
18990 \end_layout
18991
18992 \end_inset
18993
18994 ]
18995 \end_layout
18996
18997 \begin_layout Description
18998 \begin_inset Flex Code
18999 status collapsed
19000
19001 \begin_layout Plain Layout
19002 Misc
19003 \end_layout
19004
19005 \end_inset
19006
19007  [
19008 \begin_inset Flex Code
19009 status collapsed
19010
19011 \begin_layout Plain Layout
19012 string
19013 \end_layout
19014
19015 \end_inset
19016
19017 ] Valid arguments are: 
19018 \begin_inset Flex Code
19019 status collapsed
19020
19021 \begin_layout Plain Layout
19022 emph
19023 \end_layout
19024
19025 \end_inset
19026
19027
19028 \begin_inset Flex Code
19029 status collapsed
19030
19031 \begin_layout Plain Layout
19032 noun
19033 \end_layout
19034
19035 \end_inset
19036
19037
19038 \begin_inset Flex Code
19039 status collapsed
19040
19041 \begin_layout Plain Layout
19042 strikeout
19043 \end_layout
19044
19045 \end_inset
19046
19047
19048 \begin_inset Flex Code
19049 status collapsed
19050
19051 \begin_layout Plain Layout
19052 underbar
19053 \end_layout
19054
19055 \end_inset
19056
19057
19058 \begin_inset Flex Code
19059 status collapsed
19060
19061 \begin_layout Plain Layout
19062 uuline
19063 \end_layout
19064
19065 \end_inset
19066
19067
19068 \begin_inset Flex Code
19069 status collapsed
19070
19071 \begin_layout Plain Layout
19072 uwave
19073 \end_layout
19074
19075 \end_inset
19076
19077
19078 \begin_inset Flex Code
19079 status collapsed
19080
19081 \begin_layout Plain Layout
19082 no_emph
19083 \end_layout
19084
19085 \end_inset
19086
19087
19088 \begin_inset Flex Code
19089 status collapsed
19090
19091 \begin_layout Plain Layout
19092 no_noun
19093 \end_layout
19094
19095 \end_inset
19096
19097
19098 \begin_inset Flex Code
19099 status collapsed
19100
19101 \begin_layout Plain Layout
19102 no_strikeout
19103 \end_layout
19104
19105 \end_inset
19106
19107
19108 \begin_inset Flex Code
19109 status collapsed
19110
19111 \begin_layout Plain Layout
19112 no_bar
19113 \end_layout
19114
19115 \end_inset
19116
19117
19118 \begin_inset Flex Code
19119 status collapsed
19120
19121 \begin_layout Plain Layout
19122 no_uuline
19123 \end_layout
19124
19125 \end_inset
19126
19127  and 
19128 \begin_inset Flex Code
19129 status collapsed
19130
19131 \begin_layout Plain Layout
19132 no_uwave
19133 \end_layout
19134
19135 \end_inset
19136
19137 .
19138  Each of these turns on or off the corresponding attribute.
19139  For example, 
19140 \begin_inset Flex Code
19141 status collapsed
19142
19143 \begin_layout Plain Layout
19144 emph
19145 \end_layout
19146
19147 \end_inset
19148
19149  turns on emphasis, and 
19150 \begin_inset Flex Code
19151 status collapsed
19152
19153 \begin_layout Plain Layout
19154 no_emph
19155 \end_layout
19156
19157 \end_inset
19158
19159  turns it off.
19160  
19161 \begin_inset Newline newline
19162 \end_inset
19163
19164 If the latter seems puzzling, remember that the font settings for the present
19165  context are generally inherited from the surrounding context.
19166  So 
19167 \begin_inset Flex Code
19168 status collapsed
19169
19170 \begin_layout Plain Layout
19171 no_emph
19172 \end_layout
19173
19174 \end_inset
19175
19176  would turn off the emphasis that was anyway in effect, say, in a theorem
19177  environment.
19178 \end_layout
19179
19180 \begin_layout Description
19181 \begin_inset Flex Code
19182 status collapsed
19183
19184 \begin_layout Plain Layout
19185 Series
19186 \end_layout
19187
19188 \end_inset
19189
19190  [
19191 \begin_inset Flex Code
19192 status collapsed
19193
19194 \begin_layout Plain Layout
19195
19196 \emph on
19197 Medium
19198 \end_layout
19199
19200 \end_inset
19201
19202
19203 \begin_inset Flex Code
19204 status collapsed
19205
19206 \begin_layout Plain Layout
19207 Bold
19208 \end_layout
19209
19210 \end_inset
19211
19212
19213 \end_layout
19214
19215 \begin_layout Description
19216 \begin_inset Flex Code
19217 status collapsed
19218
19219 \begin_layout Plain Layout
19220 Shape
19221 \end_layout
19222
19223 \end_inset
19224
19225  [
19226 \begin_inset Flex Code
19227 status collapsed
19228
19229 \begin_layout Plain Layout
19230
19231 \emph on
19232 Up
19233 \end_layout
19234
19235 \end_inset
19236
19237
19238 \begin_inset Flex Code
19239 status collapsed
19240
19241 \begin_layout Plain Layout
19242 Italic
19243 \end_layout
19244
19245 \end_inset
19246
19247
19248 \begin_inset Flex Code
19249 status collapsed
19250
19251 \begin_layout Plain Layout
19252 SmallCaps
19253 \end_layout
19254
19255 \end_inset
19256
19257
19258 \begin_inset Flex Code
19259 status collapsed
19260
19261 \begin_layout Plain Layout
19262 Slanted
19263 \end_layout
19264
19265 \end_inset
19266
19267
19268 \end_layout
19269
19270 \begin_layout Description
19271 \begin_inset Flex Code
19272 status collapsed
19273
19274 \begin_layout Plain Layout
19275 Size
19276 \end_layout
19277
19278 \end_inset
19279
19280  [
19281 \begin_inset Flex Code
19282 status collapsed
19283
19284 \begin_layout Plain Layout
19285 tiny
19286 \end_layout
19287
19288 \end_inset
19289
19290
19291 \begin_inset Flex Code
19292 status collapsed
19293
19294 \begin_layout Plain Layout
19295 small
19296 \end_layout
19297
19298 \end_inset
19299
19300
19301 \begin_inset Flex Code
19302 status collapsed
19303
19304 \begin_layout Plain Layout
19305
19306 \emph on
19307 normal
19308 \end_layout
19309
19310 \end_inset
19311
19312
19313 \begin_inset Flex Code
19314 status collapsed
19315
19316 \begin_layout Plain Layout
19317 large
19318 \end_layout
19319
19320 \end_inset
19321
19322
19323 \begin_inset Flex Code
19324 status collapsed
19325
19326 \begin_layout Plain Layout
19327 larger
19328 \end_layout
19329
19330 \end_inset
19331
19332
19333 \begin_inset Flex Code
19334 status collapsed
19335
19336 \begin_layout Plain Layout
19337 largest
19338 \end_layout
19339
19340 \end_inset
19341
19342
19343 \begin_inset Flex Code
19344 status collapsed
19345
19346 \begin_layout Plain Layout
19347 huge
19348 \end_layout
19349
19350 \end_inset
19351
19352
19353 \begin_inset Flex Code
19354 status collapsed
19355
19356 \begin_layout Plain Layout
19357 giant
19358 \end_layout
19359
19360 \end_inset
19361
19362 ]
19363 \end_layout
19364
19365 \begin_layout Subsection
19366 \begin_inset CommandInset label
19367 LatexCommand label
19368 name "sub:Citation-format-description"
19369
19370 \end_inset
19371
19372 Citation format description
19373 \end_layout
19374
19375 \begin_layout Standard
19376 The 
19377 \begin_inset Flex Code
19378 status collapsed
19379
19380 \begin_layout Plain Layout
19381 CiteFormat
19382 \end_layout
19383
19384 \end_inset
19385
19386  blocks are used to describe how bibliographic information should be displayed,
19387  both within LyX itself (in the citation dialog and in tooltips, for example)
19388  and in XHTML output.
19389  Such a block might look like this:
19390 \end_layout
19391
19392 \begin_layout LyX-Code
19393 CiteFormat
19394 \end_layout
19395
19396 \begin_layout LyX-Code
19397  article ...
19398 \end_layout
19399
19400 \begin_layout LyX-Code
19401  book ...
19402 \end_layout
19403
19404 \begin_layout LyX-Code
19405 End
19406 \end_layout
19407
19408 \begin_layout Standard
19409 The individual lines define how the bibliographic information associated
19410  with an article or book, respectively, is to be displayed, and such a definitio
19411 n can be given for any `entry type' that might be present in a BibTeX file.
19412  LyX defines a default format in the source code that will be used if no
19413  specific definition has been given.
19414  LyX predefines several formats in the file 
19415 \begin_inset Flex Code
19416 status collapsed
19417
19418 \begin_layout Plain Layout
19419 stdciteformats.inc
19420 \end_layout
19421
19422 \end_inset
19423
19424 , which is included in most of LyX's document classes.
19425 \end_layout
19426
19427 \begin_layout Standard
19428 The definitions use a simple language that allows BibTeX keys to be replaced
19429  with their values.
19430  Keys should be enclosed in 
19431 \begin_inset Flex Code
19432 status collapsed
19433
19434 \begin_layout Plain Layout
19435 %
19436 \end_layout
19437
19438 \end_inset
19439
19440  signs, e.g.: 
19441 \begin_inset Flex Code
19442 status collapsed
19443
19444 \begin_layout Plain Layout
19445 %author%
19446 \end_layout
19447
19448 \end_inset
19449
19450 .
19451  So a simple definition might look like this:
19452 \end_layout
19453
19454 \begin_layout LyX-Code
19455 misc %author%, 
19456 \begin_inset Quotes eld
19457 \end_inset
19458
19459 %title
19460 \begin_inset Quotes erd
19461 \end_inset
19462
19463 .
19464 \end_layout
19465
19466 \begin_layout Standard
19467 This would print the author, followed by a comma, followed by the title,
19468  in quotes, followed by a period.
19469 \end_layout
19470
19471 \begin_layout Standard
19472 Of course, sometimes you may want to print a key only if it exists.
19473  This can be done by using a conditional construction, such as: 
19474 \begin_inset Flex Code
19475 status collapsed
19476
19477 \begin_layout Plain Layout
19478 {%volume%[[vol.
19479 \begin_inset space ~
19480 \end_inset
19481
19482 %volume%]]}
19483 \end_layout
19484
19485 \end_inset
19486
19487 .
19488  This says: If the 
19489 \begin_inset Flex Code
19490 status collapsed
19491
19492 \begin_layout Plain Layout
19493 volume
19494 \end_layout
19495
19496 \end_inset
19497
19498  key exists, then print 
19499 \begin_inset Quotes eld
19500 \end_inset
19501
19502 vol.
19503 \begin_inset space ~
19504 \end_inset
19505
19506
19507 \begin_inset Quotes erd
19508 \end_inset
19509
19510  followed by the volume key.
19511  It is also possible to have an else clause in the conditional, such as:
19512 \begin_inset Newline newline
19513 \end_inset
19514
19515
19516 \begin_inset Flex Code
19517 status collapsed
19518
19519 \begin_layout Plain Layout
19520 {%author%[[%author%]][[%editor%, ed.]]}
19521 \end_layout
19522
19523 \end_inset
19524
19525 .
19526 \begin_inset Newline newline
19527 \end_inset
19528
19529 Here, the 
19530 \begin_inset Flex Code
19531 status collapsed
19532
19533 \begin_layout Plain Layout
19534 author
19535 \end_layout
19536
19537 \end_inset
19538
19539  key is printed if it exists; otherwise, the editor key is printed, followed
19540  by 
19541 \begin_inset Quotes eld
19542 \end_inset
19543
19544 ,
19545 \begin_inset space ~
19546 \end_inset
19547
19548 ed.
19549 \begin_inset Quotes erd
19550 \end_inset
19551
19552  Note that the key is again enclosed in 
19553 \begin_inset Flex Code
19554 status collapsed
19555
19556 \begin_layout Plain Layout
19557 %
19558 \end_layout
19559
19560 \end_inset
19561
19562  signs; the entire conditional is enclosed in braces; and the if and else
19563  clauses are enclosed in double brackets, 
19564 \begin_inset Quotes eld
19565 \end_inset
19566
19567
19568 \begin_inset Flex Code
19569 status collapsed
19570
19571 \begin_layout Plain Layout
19572 [[
19573 \end_layout
19574
19575 \end_inset
19576
19577
19578 \begin_inset Quotes eld
19579 \end_inset
19580
19581  and 
19582 \begin_inset Quotes eld
19583 \end_inset
19584
19585
19586 \begin_inset Flex Code
19587 status collapsed
19588
19589 \begin_layout Plain Layout
19590 ]]
19591 \end_layout
19592
19593 \end_inset
19594
19595
19596 \begin_inset Quotes erd
19597 \end_inset
19598
19599 .
19600  There must be no space between any of these.
19601 \end_layout
19602
19603 \begin_layout Standard
19604 There is one other piece of syntax available in definitions, which looks
19605  like this: 
19606 \begin_inset Flex Code
19607 status collapsed
19608
19609 \begin_layout Plain Layout
19610 {!<i>!}
19611 \end_layout
19612
19613 \end_inset
19614
19615 .
19616  This defines a piece of formatting information that is to be used when
19617  creating 
19618 \begin_inset Quotes eld
19619 \end_inset
19620
19621 rich text
19622 \begin_inset Quotes erd
19623 \end_inset
19624
19625 .
19626  Obviously, we do not want to output HTML tags when writing plain text,
19627  so they should be wrapped in 
19628 \begin_inset Quotes eld
19629 \end_inset
19630
19631 {!
19632 \begin_inset Quotes erd
19633 \end_inset
19634
19635  and 
19636 \begin_inset Quotes eld
19637 \end_inset
19638
19639 !}
19640 \begin_inset Quotes erd
19641 \end_inset
19642
19643 .
19644 \end_layout
19645
19646 \begin_layout Standard
19647 Two special sorts of definitions are also possible in a 
19648 \begin_inset Flex Code
19649 status collapsed
19650
19651 \begin_layout Plain Layout
19652 CiteFormat
19653 \end_layout
19654
19655 \end_inset
19656
19657  block.
19658  An example of the first would be:
19659 \end_layout
19660
19661 \begin_layout LyX-Code
19662 !quotetitle 
19663 \begin_inset Quotes eld
19664 \end_inset
19665
19666 %title%
19667 \begin_inset Quotes erd
19668 \end_inset
19669
19670
19671 \end_layout
19672
19673 \begin_layout Standard
19674 This is an abbreviation, or macro, and it can be used by treating it as
19675  if it were a key: 
19676 \begin_inset Flex Code
19677 status collapsed
19678
19679 \begin_layout Plain Layout
19680 %!quotetitle%
19681 \end_layout
19682
19683 \end_inset
19684
19685 .
19686  LyX will treat 
19687 \begin_inset Flex Code
19688 status collapsed
19689
19690 \begin_layout Plain Layout
19691 %!quotetitle%
19692 \end_layout
19693
19694 \end_inset
19695
19696  exactly as it would treat its definition.
19697  So, let us issue the obvious 
19698 \emph on
19699 warning
19700 \emph default
19701 .
19702  Do not do this:
19703 \end_layout
19704
19705 \begin_layout LyX-Code
19706 !funfun %funfun%
19707 \end_layout
19708
19709 \begin_layout Standard
19710 or anything like it.
19711  LyX shouldn't go into an infinite loop, but it may go into a long one before
19712  it gives up.
19713 \end_layout
19714
19715 \begin_layout Standard
19716 The second sort of special definition might look like this:
19717 \end_layout
19718
19719 \begin_layout LyX-Code
19720 _pptext pp.
19721 \end_layout
19722
19723 \begin_layout Standard
19724 This defines a translatable piece of text, which allows relevant parts of
19725  the bibliography to be translated.
19726  It can be included in a definition by treating it as a key: 
19727 \begin_inset Flex Code
19728 status collapsed
19729
19730 \begin_layout Plain Layout
19731 %_pptext%
19732 \end_layout
19733
19734 \end_inset
19735
19736 .
19737  Several of these are predefined in 
19738 \begin_inset Flex Code
19739 status collapsed
19740
19741 \begin_layout Plain Layout
19742 stdciteformats.inc
19743 \end_layout
19744
19745 \end_inset
19746
19747 .
19748  Note that these are not macros, in the sense just defined.
19749  They will not be expanded.
19750 \end_layout
19751
19752 \begin_layout Standard
19753 So here then is an example that use all these features:
19754 \begin_inset VSpace defskip
19755 \end_inset
19756
19757
19758 \end_layout
19759
19760 \begin_layout Standard
19761 \noindent
19762
19763 \family typewriter
19764 !authoredit {%author%[[%author%, ]][[{%editor%[[%editor%, %_edtext%, ]]}]]}
19765 \end_layout
19766
19767 \begin_layout Standard
19768 \begin_inset VSpace defskip
19769 \end_inset
19770
19771 This defines a macro that prints the author, followed by a comma, if the
19772  
19773 \begin_inset Flex Code
19774 status collapsed
19775
19776 \begin_layout Plain Layout
19777 author
19778 \end_layout
19779
19780 \end_inset
19781
19782  key is defined, or else prints the name of the editor, followed by the
19783  
19784 \begin_inset Flex Code
19785 status collapsed
19786
19787 \begin_layout Plain Layout
19788 _edtext
19789 \end_layout
19790
19791 \end_inset
19792
19793  or its translation (it is by default 
19794 \begin_inset Quotes eld
19795 \end_inset
19796
19797 ed.
19798 \begin_inset Quotes erd
19799 \end_inset
19800
19801 ), if the 
19802 \begin_inset Flex Code
19803 status collapsed
19804
19805 \begin_layout Plain Layout
19806 editor
19807 \end_layout
19808
19809 \end_inset
19810
19811  key is defined.
19812  Note that this is in fact defined in 
19813 \begin_inset Flex Code
19814 status collapsed
19815
19816 \begin_layout Plain Layout
19817 stdciteformats.inc
19818 \end_layout
19819
19820 \end_inset
19821
19822 , so you can use it in your own definitions, or re-definitions, if you load
19823  that file first.
19824 \end_layout
19825
19826 \begin_layout Section
19827 \begin_inset CommandInset label
19828 LatexCommand label
19829 name "sec:Tags-for-XHTML"
19830
19831 \end_inset
19832
19833 Tags for XHTML output
19834 \end_layout
19835
19836 \begin_layout Standard
19837 As with LaTeX or DocBook, the format of LyX's XHTML output is also controlled
19838  by layout information.
19839  In general, LyX provides sensible defaults and, as mentioned earlier, it
19840  will even construct default CSS style rules from the other layout tags.
19841  For example, LyX will attempt to use the information provided in the 
19842 \begin_inset Flex Code
19843 status collapsed
19844
19845 \begin_layout Plain Layout
19846 Font
19847 \end_layout
19848
19849 \end_inset
19850
19851  declaration for the Chapter style to write CSS that will appropriately
19852  format chapter headings.
19853 \end_layout
19854
19855 \begin_layout Standard
19856 In many cases, then, you may not have to do anything at all to get acceptable
19857  XHTML output for your own environments, custom insets, and so forth.
19858  But in some cases you will, and so LyX provides a number of layout tags
19859  that can be used to customize the XHTML and CSS that are generated.
19860 \end_layout
19861
19862 \begin_layout Standard
19863 Note that there are two tags, 
19864 \begin_inset Flex Code
19865 status collapsed
19866
19867 \begin_layout Plain Layout
19868 HTMLPreamble
19869 \end_layout
19870
19871 \end_inset
19872
19873  and 
19874 \begin_inset Flex Code
19875 status collapsed
19876
19877 \begin_layout Plain Layout
19878 AddToHTMLPreamble
19879 \end_layout
19880
19881 \end_inset
19882
19883  that may appear outside style and inset declarations.
19884  See 
19885 \begin_inset CommandInset ref
19886 LatexCommand ref
19887 reference "sub:General-text-class"
19888
19889 \end_inset
19890
19891  for details on these.
19892 \end_layout
19893
19894 \begin_layout Subsection
19895 \begin_inset CommandInset label
19896 LatexCommand label
19897 name "sub:Paragraph-Style-XHTML"
19898
19899 \end_inset
19900
19901 Paragraph styles
19902 \end_layout
19903
19904 \begin_layout Standard
19905 The sort of XHTML LyX outputs for a paragraph depends upon whether we are
19906  dealing with a normal paragraph, a command, or an environment, where this
19907  is itself determined by the contents of the corresponding 
19908 \begin_inset Flex Code
19909 status collapsed
19910
19911 \begin_layout Plain Layout
19912 LaTeXType
19913 \end_layout
19914
19915 \end_inset
19916
19917  tag.
19918  
19919 \end_layout
19920
19921 \begin_layout Standard
19922 For a command or normal paragraph, the output XHTML has the following form:
19923 \end_layout
19924
19925 \begin_layout LyX-Code
19926 <tag attr=
19927 \begin_inset Quotes erd
19928 \end_inset
19929
19930 value
19931 \begin_inset Quotes erd
19932 \end_inset
19933
19934 >
19935 \end_layout
19936
19937 \begin_layout LyX-Code
19938 <labeltag attr=
19939 \begin_inset Quotes erd
19940 \end_inset
19941
19942 value
19943 \begin_inset Quotes erd
19944 \end_inset
19945
19946 >Label</labeltag>
19947 \end_layout
19948
19949 \begin_layout LyX-Code
19950 Contents of the paragraph.
19951 \end_layout
19952
19953 \begin_layout LyX-Code
19954 </tag>
19955 \end_layout
19956
19957 \begin_layout Standard
19958 The label tags are of course omitted if the paragraph does not have a label.
19959 \end_layout
19960
19961 \begin_layout Standard
19962 For an environment that is not some sort of list, the XHTML takes this form:
19963 \end_layout
19964
19965 \begin_layout LyX-Code
19966 <tag attr=
19967 \begin_inset Quotes erd
19968 \end_inset
19969
19970 value
19971 \begin_inset Quotes erd
19972 \end_inset
19973
19974 >
19975 \end_layout
19976
19977 \begin_layout LyX-Code
19978 <itemtag attr=
19979 \begin_inset Quotes erd
19980 \end_inset
19981
19982 value
19983 \begin_inset Quotes erd
19984 \end_inset
19985
19986 ><labeltag attr=
19987 \begin_inset Quotes erd
19988 \end_inset
19989
19990 value
19991 \begin_inset Quotes erd
19992 \end_inset
19993
19994 >Environment Label</labeltag>First paragraph.</itemtag>
19995 \end_layout
19996
19997 \begin_layout LyX-Code
19998 <itemtag>Second paragraph.</itemtag>
19999 \end_layout
20000
20001 \begin_layout LyX-Code
20002 </tag>
20003 \end_layout
20004
20005 \begin_layout Standard
20006 Note that the label is output only for the first paragraph, as it should
20007  be for a theorem, for example.
20008  
20009 \end_layout
20010
20011 \begin_layout Standard
20012 For a list, we have one of these forms:
20013 \end_layout
20014
20015 \begin_layout LyX-Code
20016 <tag attr=
20017 \begin_inset Quotes erd
20018 \end_inset
20019
20020 value
20021 \begin_inset Quotes erd
20022 \end_inset
20023
20024 >
20025 \end_layout
20026
20027 \begin_layout LyX-Code
20028 <itemtag attr=
20029 \begin_inset Quotes erd
20030 \end_inset
20031
20032 value
20033 \begin_inset Quotes erd
20034 \end_inset
20035
20036 ><labeltag attr=
20037 \begin_inset Quotes erd
20038 \end_inset
20039
20040 value
20041 \begin_inset Quotes erd
20042 \end_inset
20043
20044 >List Label</labeltag>First item.</itemtag>
20045 \end_layout
20046
20047 \begin_layout LyX-Code
20048 <itemtag attr=
20049 \begin_inset Quotes erd
20050 \end_inset
20051
20052 value
20053 \begin_inset Quotes erd
20054 \end_inset
20055
20056 ><labeltag attr=
20057 \begin_inset Quotes erd
20058 \end_inset
20059
20060 value
20061 \begin_inset Quotes erd
20062 \end_inset
20063
20064 >List Label</labeltag>Second item.</itemtag>
20065 \end_layout
20066
20067 \begin_layout LyX-Code
20068 </tag>
20069 \end_layout
20070
20071 \begin_layout LyX-Code
20072
20073 \end_layout
20074
20075 \begin_layout LyX-Code
20076 <tag attr=
20077 \begin_inset Quotes erd
20078 \end_inset
20079
20080 value
20081 \begin_inset Quotes erd
20082 \end_inset
20083
20084 >
20085 \end_layout
20086
20087 \begin_layout LyX-Code
20088 <labeltag attr=
20089 \begin_inset Quotes erd
20090 \end_inset
20091
20092 value
20093 \begin_inset Quotes erd
20094 \end_inset
20095
20096 >List Label</labeltag><itemtag attr=
20097 \begin_inset Quotes erd
20098 \end_inset
20099
20100 value
20101 \begin_inset Quotes erd
20102 \end_inset
20103
20104 >First item.</itemtag>
20105 \end_layout
20106
20107 \begin_layout LyX-Code
20108 <labeltag attr=
20109 \begin_inset Quotes erd
20110 \end_inset
20111
20112 value
20113 \begin_inset Quotes erd
20114 \end_inset
20115
20116 >List Label</labeltag><itemtag attr=
20117 \begin_inset Quotes erd
20118 \end_inset
20119
20120 value
20121 \begin_inset Quotes erd
20122 \end_inset
20123
20124 >Second item.</itemtag>
20125 \end_layout
20126
20127 \begin_layout LyX-Code
20128 </tag>
20129 \end_layout
20130
20131 \begin_layout Standard
20132 Note the different orders of 
20133 \begin_inset Flex Code
20134 status collapsed
20135
20136 \begin_layout Plain Layout
20137 labeltag
20138 \end_layout
20139
20140 \end_inset
20141
20142  and 
20143 \begin_inset Flex Code
20144 status collapsed
20145
20146 \begin_layout Plain Layout
20147 itemtag
20148 \end_layout
20149
20150 \end_inset
20151
20152 .
20153  Which order we get depends upon the setting of 
20154 \begin_inset Flex Code
20155 status collapsed
20156
20157 \begin_layout Plain Layout
20158 HTMLLabelFirst
20159 \end_layout
20160
20161 \end_inset
20162
20163 : If 
20164 \begin_inset Flex Code
20165 status collapsed
20166
20167 \begin_layout Plain Layout
20168 HTMLLabelFirst
20169 \end_layout
20170
20171 \end_inset
20172
20173  is false (the default), you get the first of these, with the label within
20174  the item; if true, you get the second, with the label outside the item.
20175 \end_layout
20176
20177 \begin_layout Standard
20178 The specific tags and attributes output for each paragraph type can be controlle
20179 d by means of the layout tags we are about to describe.
20180  As mentioned earlier, however, LyX uses sensible defaults for many of these,
20181  so you often may not need to do very much to get good XHTML output.
20182  Think of the available tags as there so you can tweak things to your liking.
20183 \end_layout
20184
20185 \begin_layout Description
20186 \begin_inset Flex Code
20187 status collapsed
20188
20189 \begin_layout Plain Layout
20190 HTMLAttr
20191 \end_layout
20192
20193 \end_inset
20194
20195  [
20196 \begin_inset Flex Code
20197 status collapsed
20198
20199 \begin_layout Plain Layout
20200 string
20201 \end_layout
20202
20203 \end_inset
20204
20205 ] Specifies attribute information to be output with the main tag.
20206  For example, 
20207 \begin_inset Quotes eld
20208 \end_inset
20209
20210
20211 \begin_inset Flex Code
20212 status collapsed
20213
20214 \begin_layout Plain Layout
20215 class=`mydiv'
20216 \end_layout
20217
20218 \end_inset
20219
20220
20221 \begin_inset Quotes erd
20222 \end_inset
20223
20224 .
20225  By default, LyX will output 
20226 \begin_inset Quotes eld
20227 \end_inset
20228
20229
20230 \begin_inset Flex Code
20231 status collapsed
20232
20233 \begin_layout Plain Layout
20234 class=`layoutname'
20235 \end_layout
20236
20237 \end_inset
20238
20239
20240 \begin_inset Quotes erd
20241 \end_inset
20242
20243 , where 
20244 \begin_inset Flex Code
20245 status collapsed
20246
20247 \begin_layout Plain Layout
20248 layoutname
20249 \end_layout
20250
20251 \end_inset
20252
20253  is the LyX name of the layout, made lowercase, for example: chapter.
20254  This should 
20255 \emph on
20256 not
20257 \emph default
20258  contain any style information.
20259  Use 
20260 \begin_inset Flex Code
20261 status collapsed
20262
20263 \begin_layout Plain Layout
20264 HTMLStyle
20265 \end_layout
20266
20267 \end_inset
20268
20269  for that purpose.
20270 \end_layout
20271
20272 \begin_layout Description
20273 \begin_inset Flex Code
20274 status collapsed
20275
20276 \begin_layout Plain Layout
20277 HTMLForceCSS
20278 \end_layout
20279
20280 \end_inset
20281
20282  [
20283 \begin_inset Flex Code
20284 status collapsed
20285
20286 \begin_layout Plain Layout
20287
20288 \emph on
20289 0
20290 \emph default
20291 ,1
20292 \end_layout
20293
20294 \end_inset
20295
20296 ] Whether to output the default CSS information LyX generates for this layout,
20297  even if additional information is explicitly provided via 
20298 \begin_inset Flex Code
20299 status collapsed
20300
20301 \begin_layout Plain Layout
20302 HTMLStyle
20303 \end_layout
20304
20305 \end_inset
20306
20307 .
20308  Setting this to 
20309 \begin_inset Flex Code
20310 status collapsed
20311
20312 \begin_layout Plain Layout
20313 1
20314 \end_layout
20315
20316 \end_inset
20317
20318  allows you to alter or augment the generated CSS, rather than to override
20319  it completely.
20320  Default is 
20321 \begin_inset Flex Code
20322 status collapsed
20323
20324 \begin_layout Plain Layout
20325 0
20326 \end_layout
20327
20328 \end_inset
20329
20330 .
20331 \end_layout
20332
20333 \begin_layout Description
20334 \begin_inset Flex Code
20335 status collapsed
20336
20337 \begin_layout Plain Layout
20338 HTMLItem
20339 \end_layout
20340
20341 \end_inset
20342
20343  [
20344 \begin_inset Flex Code
20345 status collapsed
20346
20347 \begin_layout Plain Layout
20348 string
20349 \end_layout
20350
20351 \end_inset
20352
20353 ] The tag to be used for individual paragraphs of environments, replacing
20354  
20355 \begin_inset Flex Code
20356 status collapsed
20357
20358 \begin_layout Plain Layout
20359 itemtag
20360 \end_layout
20361
20362 \end_inset
20363
20364  in the examples above.
20365  Defaults to 
20366 \begin_inset Flex Code
20367 status collapsed
20368
20369 \begin_layout Plain Layout
20370 div
20371 \end_layout
20372
20373 \end_inset
20374
20375 .
20376 \end_layout
20377
20378 \begin_layout Description
20379 \begin_inset Flex Code
20380 status collapsed
20381
20382 \begin_layout Plain Layout
20383 HTMLItemAttr
20384 \end_layout
20385
20386 \end_inset
20387
20388  [
20389 \begin_inset Flex Code
20390 status collapsed
20391
20392 \begin_layout Plain Layout
20393 string
20394 \end_layout
20395
20396 \end_inset
20397
20398 ] Attributes for the item tag.
20399  Defaults to 
20400 \begin_inset Quotes eld
20401 \end_inset
20402
20403
20404 \begin_inset Flex Code
20405 status collapsed
20406
20407 \begin_layout Plain Layout
20408 class=`layoutname_item'
20409 \end_layout
20410
20411 \end_inset
20412
20413
20414 \begin_inset Quotes erd
20415 \end_inset
20416
20417 .
20418  This should 
20419 \emph on
20420 not
20421 \emph default
20422  contain any style information.
20423  Use 
20424 \begin_inset Flex Code
20425 status collapsed
20426
20427 \begin_layout Plain Layout
20428 HTMLStyle
20429 \end_layout
20430
20431 \end_inset
20432
20433  for that purpose.
20434 \end_layout
20435
20436 \begin_layout Description
20437 \begin_inset Flex Code
20438 status collapsed
20439
20440 \begin_layout Plain Layout
20441 HTMLLabel
20442 \end_layout
20443
20444 \end_inset
20445
20446  [
20447 \begin_inset Flex Code
20448 status collapsed
20449
20450 \begin_layout Plain Layout
20451 string
20452 \end_layout
20453
20454 \end_inset
20455
20456 ] The tag to be used for paragraph and item labels, replacing 
20457 \begin_inset Flex Code
20458 status collapsed
20459
20460 \begin_layout Plain Layout
20461 labeltag
20462 \end_layout
20463
20464 \end_inset
20465
20466  in the examples above.
20467  Defaults to 
20468 \begin_inset Flex Code
20469 status collapsed
20470
20471 \begin_layout Plain Layout
20472 span
20473 \end_layout
20474
20475 \end_inset
20476
20477 , unless 
20478 \begin_inset Flex Code
20479 status collapsed
20480
20481 \begin_layout Plain Layout
20482 LabelType
20483 \end_layout
20484
20485 \end_inset
20486
20487  is either 
20488 \begin_inset Flex Code
20489 status collapsed
20490
20491 \begin_layout Plain Layout
20492 Top_Environment
20493 \end_layout
20494
20495 \end_inset
20496
20497  or 
20498 \begin_inset Flex Code
20499 status collapsed
20500
20501 \begin_layout Plain Layout
20502 Centered_Top_Environment
20503 \end_layout
20504
20505 \end_inset
20506
20507 , in which case it defaults to 
20508 \begin_inset Flex Code
20509 status collapsed
20510
20511 \begin_layout Plain Layout
20512 div
20513 \end_layout
20514
20515 \end_inset
20516
20517 .
20518 \end_layout
20519
20520 \begin_layout Description
20521 \begin_inset Flex Code
20522 status collapsed
20523
20524 \begin_layout Plain Layout
20525 HTMLLabelAttr
20526 \end_layout
20527
20528 \end_inset
20529
20530  [
20531 \begin_inset Flex Code
20532 status collapsed
20533
20534 \begin_layout Plain Layout
20535 string
20536 \end_layout
20537
20538 \end_inset
20539
20540 ] Attributes for the label tag.
20541  Defaults to 
20542 \begin_inset Quotes eld
20543 \end_inset
20544
20545
20546 \begin_inset Flex Code
20547 status collapsed
20548
20549 \begin_layout Plain Layout
20550 class=`layoutname_label'
20551 \end_layout
20552
20553 \end_inset
20554
20555
20556 \begin_inset Quotes erd
20557 \end_inset
20558
20559 .
20560  This should 
20561 \emph on
20562 not
20563 \emph default
20564  contain any style information.
20565  Use 
20566 \begin_inset Flex Code
20567 status collapsed
20568
20569 \begin_layout Plain Layout
20570 HTMLStyle
20571 \end_layout
20572
20573 \end_inset
20574
20575  for that purpose.
20576 \end_layout
20577
20578 \begin_layout Description
20579 \begin_inset Flex Code
20580 status collapsed
20581
20582 \begin_layout Plain Layout
20583 HTMLLabelFirst
20584 \end_layout
20585
20586 \end_inset
20587
20588  [
20589 \begin_inset Flex Code
20590 status collapsed
20591
20592 \begin_layout Plain Layout
20593
20594 \emph on
20595 0
20596 \emph default
20597 ,1
20598 \end_layout
20599
20600 \end_inset
20601
20602 ] Meaningful only for list-like environments, this tag controls whether
20603  the label tag is output before or inside the item tag.
20604  This is used, for example, in the description environment, where we want
20605  `
20606 \begin_inset Flex Code
20607 status collapsed
20608
20609 \begin_layout Plain Layout
20610 <dt>\SpecialChar \ldots{}
20611 </dt><dd>\SpecialChar \ldots{}
20612 </dd>
20613 \end_layout
20614
20615 \end_inset
20616
20617 .
20618  Default is 
20619 \begin_inset Flex Code
20620 status collapsed
20621
20622 \begin_layout Plain Layout
20623 0
20624 \end_layout
20625
20626 \end_inset
20627
20628 : The label tag is output inside the item tag.
20629 \end_layout
20630
20631 \begin_layout Description
20632 \begin_inset Flex Code
20633 status collapsed
20634
20635 \begin_layout Plain Layout
20636 HTMLPreamble
20637 \end_layout
20638
20639 \end_inset
20640
20641  Information to be output in the 
20642 \begin_inset Flex Code
20643 status collapsed
20644
20645 \begin_layout Plain Layout
20646 <head>
20647 \end_layout
20648
20649 \end_inset
20650
20651  section when this style is used.
20652  This might, for example, be used to include a 
20653 \begin_inset Flex Code
20654 status collapsed
20655
20656 \begin_layout Plain Layout
20657 <script>
20658 \end_layout
20659
20660 \end_inset
20661
20662  block defining an 
20663 \begin_inset Flex Code
20664 status collapsed
20665
20666 \begin_layout Plain Layout
20667 onclick
20668 \end_layout
20669
20670 \end_inset
20671
20672  handler.
20673 \end_layout
20674
20675 \begin_layout Description
20676 \begin_inset Flex Code
20677 status collapsed
20678
20679 \begin_layout Plain Layout
20680 HTMLStyle
20681 \end_layout
20682
20683 \end_inset
20684
20685  CSS style information to be included when this style is used.
20686  Note that this will automatically be wrapped in a layout-generated 
20687 \begin_inset Flex Code
20688 status collapsed
20689
20690 \begin_layout Plain Layout
20691 <style>
20692 \end_layout
20693
20694 \end_inset
20695
20696  block, so only the CSS itself need be included.
20697  Must end with 
20698 \begin_inset Flex Code
20699 status collapsed
20700
20701 \begin_layout Plain Layout
20702 EndHTMLStyle
20703 \end_layout
20704
20705 \end_inset
20706
20707 .
20708 \end_layout
20709
20710 \begin_layout Description
20711 \begin_inset Flex Code
20712 status collapsed
20713
20714 \begin_layout Plain Layout
20715 HTMLTag
20716 \end_layout
20717
20718 \end_inset
20719
20720  [
20721 \begin_inset Flex Code
20722 status collapsed
20723
20724 \begin_layout Plain Layout
20725 string
20726 \end_layout
20727
20728 \end_inset
20729
20730 ] The tag to be used for the main label, replacing 
20731 \begin_inset Flex Code
20732 status collapsed
20733
20734 \begin_layout Plain Layout
20735 tag
20736 \end_layout
20737
20738 \end_inset
20739
20740  in the examples above.
20741  Defaults to 
20742 \begin_inset Flex Code
20743 status collapsed
20744
20745 \begin_layout Plain Layout
20746 div
20747 \end_layout
20748
20749 \end_inset
20750
20751 .
20752 \end_layout
20753
20754 \begin_layout Description
20755 \begin_inset Flex Code
20756 status collapsed
20757
20758 \begin_layout Plain Layout
20759 HTMLTitle
20760 \end_layout
20761
20762 \end_inset
20763
20764  [
20765 \begin_inset Flex Code
20766 status collapsed
20767
20768 \begin_layout Plain Layout
20769
20770 \emph on
20771 0
20772 \emph default
20773 ,1
20774 \end_layout
20775
20776 \end_inset
20777
20778 ] Marks this style as the one to be used to generate the 
20779 \begin_inset Flex Code
20780 status collapsed
20781
20782 \begin_layout Plain Layout
20783 <title>
20784 \end_layout
20785
20786 \end_inset
20787
20788  tag for the XHTML file.
20789  By default, it is false.
20790  The 
20791 \begin_inset Flex Code
20792 status collapsed
20793
20794 \begin_layout Plain Layout
20795 stdtitle.inc
20796 \end_layout
20797
20798 \end_inset
20799
20800  file sets it to true for the 
20801 \begin_inset Flex Code
20802 status collapsed
20803
20804 \begin_layout Plain Layout
20805 title
20806 \end_layout
20807
20808 \end_inset
20809
20810  environment.
20811  
20812 \end_layout
20813
20814 \begin_layout Subsection
20815 InsetLayout XHTML
20816 \end_layout
20817
20818 \begin_layout Standard
20819 The XHTML output of insets can also be controlled by information in layout
20820  files.
20821 \begin_inset Foot
20822 status collapsed
20823
20824 \begin_layout Plain Layout
20825 At present, this is true only for 
20826 \begin_inset Quotes eld
20827 \end_inset
20828
20829 text
20830 \begin_inset Quotes erd
20831 \end_inset
20832
20833  insets (insets you can type into) and is not true for 
20834 \begin_inset Quotes eld
20835 \end_inset
20836
20837 command
20838 \begin_inset Quotes erd
20839 \end_inset
20840
20841  insets (insets that are associated with dialog boxes).
20842 \end_layout
20843
20844 \end_inset
20845
20846  Here, too, LyX tries to provide sensible defaults, and it constructs default
20847  CSS style rules.
20848  But everything can be customized.
20849 \end_layout
20850
20851 \begin_layout Standard
20852 The XHTML LyX outputs for an inset has the following form:
20853 \end_layout
20854
20855 \begin_layout LyX-Code
20856 <tag attr=
20857 \begin_inset Quotes erd
20858 \end_inset
20859
20860 value
20861 \begin_inset Quotes erd
20862 \end_inset
20863
20864 >
20865 \end_layout
20866
20867 \begin_layout LyX-Code
20868 <labeltag>Label</labeltag>
20869 \end_layout
20870
20871 \begin_layout LyX-Code
20872 <innertag attr=
20873 \begin_inset Quotes erd
20874 \end_inset
20875
20876 value
20877 \begin_inset Quotes erd
20878 \end_inset
20879
20880 >Contents of the inset.</innertag>
20881 \end_layout
20882
20883 \begin_layout LyX-Code
20884 </tag>
20885 \end_layout
20886
20887 \begin_layout Standard
20888 If the inset permits multiple paragraphs---that is, if 
20889 \begin_inset Flex Code
20890 status collapsed
20891
20892 \begin_layout Plain Layout
20893 MultiPar
20894 \end_layout
20895
20896 \end_inset
20897
20898  is true---then the contents of the inset will itself be output as paragraphs
20899  formatted according to the styles used for those paragraphs (standard,
20900  quote, and the like).
20901  The label tag is of course omitted if the paragraph does not have a label
20902  and, at present, is always 
20903 \begin_inset Flex Code
20904 status collapsed
20905
20906 \begin_layout Plain Layout
20907 span
20908 \end_layout
20909
20910 \end_inset
20911
20912 .
20913  The inner tag is optional and, by default, does not appear.
20914 \end_layout
20915
20916 \begin_layout Standard
20917 The specific tags and attributes output for each inset can be controlled
20918  by means of the following layout tags.
20919 \end_layout
20920
20921 \begin_layout Description
20922 \begin_inset Flex Code
20923 status collapsed
20924
20925 \begin_layout Plain Layout
20926 HTMLAttr
20927 \end_layout
20928
20929 \end_inset
20930
20931  [
20932 \begin_inset Flex Code
20933 status collapsed
20934
20935 \begin_layout Plain Layout
20936 string
20937 \end_layout
20938
20939 \end_inset
20940
20941 ] Specifies attribute information to be output with the main tag.
20942  For example, 
20943 \begin_inset Quotes eld
20944 \end_inset
20945
20946
20947 \begin_inset Flex Code
20948 status collapsed
20949
20950 \begin_layout Plain Layout
20951 class=`myinset' onclick=`\SpecialChar \ldots{}
20952 '
20953 \end_layout
20954
20955 \end_inset
20956
20957
20958 \begin_inset Quotes erd
20959 \end_inset
20960
20961 .
20962  By default, LyX will output 
20963 \begin_inset Quotes eld
20964 \end_inset
20965
20966
20967 \begin_inset Flex Code
20968 status collapsed
20969
20970 \begin_layout Plain Layout
20971 class=`insetname'
20972 \end_layout
20973
20974 \end_inset
20975
20976
20977 \begin_inset Quotes erd
20978 \end_inset
20979
20980 , where 
20981 \begin_inset Flex Code
20982 status collapsed
20983
20984 \begin_layout Plain Layout
20985 insetname
20986 \end_layout
20987
20988 \end_inset
20989
20990  is the LyX name of the inset, made lowercase and with non-alphanumeric
20991  characters converted to underscores, for example: footnote.
20992 \end_layout
20993
20994 \begin_layout Description
20995 \begin_inset Flex Code
20996 status collapsed
20997
20998 \begin_layout Plain Layout
20999 HTMLForceCSS
21000 \end_layout
21001
21002 \end_inset
21003
21004  [
21005 \begin_inset Flex Code
21006 status collapsed
21007
21008 \begin_layout Plain Layout
21009
21010 \emph on
21011 0
21012 \emph default
21013 ,1
21014 \end_layout
21015
21016 \end_inset
21017
21018 ] Whether to output the default CSS information LyX generates for this layout,
21019  even if additional information is explicitly provided via 
21020 \begin_inset Flex Code
21021 status collapsed
21022
21023 \begin_layout Plain Layout
21024 HTMLStyle
21025 \end_layout
21026
21027 \end_inset
21028
21029 .
21030  Setting this to 
21031 \begin_inset Flex Code
21032 status collapsed
21033
21034 \begin_layout Plain Layout
21035 1
21036 \end_layout
21037
21038 \end_inset
21039
21040  allows you to alter or augment the generated CSS, rather than to override
21041  it completely.
21042  Default is 0.
21043 \end_layout
21044
21045 \begin_layout Description
21046 \begin_inset Flex Code
21047 status collapsed
21048
21049 \begin_layout Plain Layout
21050 HTMLInnerAttr
21051 \end_layout
21052
21053 \end_inset
21054
21055  [
21056 \begin_inset Flex Code
21057 status collapsed
21058
21059 \begin_layout Plain Layout
21060 string
21061 \end_layout
21062
21063 \end_inset
21064
21065 ] Attributes for the inner tag.
21066  Defaults to 
21067 \begin_inset Quotes eld
21068 \end_inset
21069
21070
21071 \begin_inset Flex Code
21072 status collapsed
21073
21074 \begin_layout Plain Layout
21075 class=`insetname_inner'
21076 \end_layout
21077
21078 \end_inset
21079
21080
21081 \begin_inset Quotes erd
21082 \end_inset
21083
21084 .
21085 \end_layout
21086
21087 \begin_layout Description
21088 \begin_inset Flex Code
21089 status collapsed
21090
21091 \begin_layout Plain Layout
21092 HTMLInnerTag
21093 \end_layout
21094
21095 \end_inset
21096
21097  [
21098 \begin_inset Flex Code
21099 status collapsed
21100
21101 \begin_layout Plain Layout
21102 string
21103 \end_layout
21104
21105 \end_inset
21106
21107 ] The inner tag, replacing 
21108 \begin_inset Flex Code
21109 status collapsed
21110
21111 \begin_layout Plain Layout
21112 innertag
21113 \end_layout
21114
21115 \end_inset
21116
21117  in the examples above.
21118  By default, there is none.
21119 \end_layout
21120
21121 \begin_layout Description
21122 \begin_inset Flex Code
21123 status collapsed
21124
21125 \begin_layout Plain Layout
21126 HTMLIsBlock
21127 \end_layout
21128
21129 \end_inset
21130
21131  [
21132 \begin_inset Flex Code
21133 status collapsed
21134
21135 \begin_layout Plain Layout
21136 0,
21137 \emph on
21138 1
21139 \end_layout
21140
21141 \end_inset
21142
21143 ] Whether this inset represents a standalone block of text (such as a footnote)
21144  or instead represents material that is included in the surrounding text
21145  (such as a branch).
21146  Defaults to 1.
21147 \end_layout
21148
21149 \begin_layout Description
21150 \begin_inset Flex Code
21151 status collapsed
21152
21153 \begin_layout Plain Layout
21154 HTMLLabel
21155 \end_layout
21156
21157 \end_inset
21158
21159  [
21160 \begin_inset Flex Code
21161 status collapsed
21162
21163 \begin_layout Plain Layout
21164 string
21165 \end_layout
21166
21167 \end_inset
21168
21169 ] A label for this inset, possibly including a reference to a counter.
21170  For example, for footnote, it might be: 
21171 \begin_inset Flex Code
21172 status collapsed
21173
21174 \begin_layout Plain Layout
21175
21176 \backslash
21177 arabic{footnote}
21178 \end_layout
21179
21180 \end_inset
21181
21182 .
21183  This is optional, and there is no default.
21184 \end_layout
21185
21186 \begin_layout Description
21187 \begin_inset Flex Code
21188 status collapsed
21189
21190 \begin_layout Plain Layout
21191 HTMLPreamble
21192 \end_layout
21193
21194 \end_inset
21195
21196  Information to be output in the 
21197 \begin_inset Flex Code
21198 status collapsed
21199
21200 \begin_layout Plain Layout
21201 <head>
21202 \end_layout
21203
21204 \end_inset
21205
21206  section when this style is used.
21207  This might, for example, be used to include a 
21208 \begin_inset Flex Code
21209 status collapsed
21210
21211 \begin_layout Plain Layout
21212 <script>
21213 \end_layout
21214
21215 \end_inset
21216
21217  block defining an 
21218 \begin_inset Flex Code
21219 status collapsed
21220
21221 \begin_layout Plain Layout
21222 onclick
21223 \end_layout
21224
21225 \end_inset
21226
21227  handler.
21228 \end_layout
21229
21230 \begin_layout Description
21231 \begin_inset Flex Code
21232 status collapsed
21233
21234 \begin_layout Plain Layout
21235 HTMLStyle
21236 \end_layout
21237
21238 \end_inset
21239
21240  CSS style information to be included when this style is used.
21241  Note that this will automatically be wrapped in a layout-generated 
21242 \begin_inset Flex Code
21243 status collapsed
21244
21245 \begin_layout Plain Layout
21246 <style>
21247 \end_layout
21248
21249 \end_inset
21250
21251  block, so only the CSS itself need be included.
21252 \end_layout
21253
21254 \begin_layout Description
21255 \begin_inset Flex Code
21256 status collapsed
21257
21258 \begin_layout Plain Layout
21259 HTMLTag
21260 \end_layout
21261
21262 \end_inset
21263
21264  [
21265 \begin_inset Flex Code
21266 status collapsed
21267
21268 \begin_layout Plain Layout
21269 string
21270 \end_layout
21271
21272 \end_inset
21273
21274 ] The tag to be used for the main label, replacing 
21275 \begin_inset Flex Code
21276 status collapsed
21277
21278 \begin_layout Plain Layout
21279 tag
21280 \end_layout
21281
21282 \end_inset
21283
21284  in the examples above.
21285  The default depends upon the setting of 
21286 \begin_inset Flex Code
21287 status collapsed
21288
21289 \begin_layout Plain Layout
21290 MultiPar
21291 \end_layout
21292
21293 \end_inset
21294
21295 : If 
21296 \begin_inset Flex Code
21297 status collapsed
21298
21299 \begin_layout Plain Layout
21300 MultiPar
21301 \end_layout
21302
21303 \end_inset
21304
21305  is true, the default is 
21306 \begin_inset Flex Code
21307 status collapsed
21308
21309 \begin_layout Plain Layout
21310 div
21311 \end_layout
21312
21313 \end_inset
21314
21315 ; if it is false, the default is 
21316 \begin_inset Flex Code
21317 status collapsed
21318
21319 \begin_layout Plain Layout
21320 span
21321 \end_layout
21322
21323 \end_inset
21324
21325 .
21326 \end_layout
21327
21328 \begin_layout Subsection
21329 Float XHTML
21330 \end_layout
21331
21332 \begin_layout Standard
21333 The XHTML output for floats too can be controlled by layout information.
21334  The output has the following form:
21335 \end_layout
21336
21337 \begin_layout LyX-Code
21338 <tag attr=
21339 \begin_inset Quotes erd
21340 \end_inset
21341
21342 value
21343 \begin_inset Quotes erd
21344 \end_inset
21345
21346 >
21347 \end_layout
21348
21349 \begin_layout LyX-Code
21350 Contents of the float.
21351 \end_layout
21352
21353 \begin_layout LyX-Code
21354 </tag>
21355 \end_layout
21356
21357 \begin_layout Standard
21358 The caption, if there is one, is a separate inset and will be output as
21359  such.
21360  Its appearance can be controlled via the InsetLayout for caption insets.
21361  
21362 \end_layout
21363
21364 \begin_layout Description
21365 \begin_inset Flex Code
21366 status collapsed
21367
21368 \begin_layout Plain Layout
21369 HTMLAttr
21370 \end_layout
21371
21372 \end_inset
21373
21374  [
21375 \begin_inset Flex Code
21376 status collapsed
21377
21378 \begin_layout Plain Layout
21379 string
21380 \end_layout
21381
21382 \end_inset
21383
21384 ] Specifies attribute information to be output with the main tag.
21385  For example, 
21386 \begin_inset Quotes eld
21387 \end_inset
21388
21389
21390 \begin_inset Flex Code
21391 status collapsed
21392
21393 \begin_layout Plain Layout
21394 class=`myfloat' onclick=`\SpecialChar \ldots{}
21395 '
21396 \end_layout
21397
21398 \end_inset
21399
21400
21401 \begin_inset Quotes erd
21402 \end_inset
21403
21404 .
21405  By default, LyX will output 
21406 \begin_inset Quotes eld
21407 \end_inset
21408
21409
21410 \begin_inset Flex Code
21411 status collapsed
21412
21413 \begin_layout Plain Layout
21414 class=`float float-floattype'
21415 \end_layout
21416
21417 \end_inset
21418
21419
21420 \begin_inset Quotes erd
21421 \end_inset
21422
21423 , where 
21424 \begin_inset Flex Code
21425 status collapsed
21426
21427 \begin_layout Plain Layout
21428 floattype
21429 \end_layout
21430
21431 \end_inset
21432
21433  is LyX's name for this type of float, as determined by the float declaration
21434  (see 
21435 \begin_inset CommandInset ref
21436 LatexCommand ref
21437 reference "sub:Floats"
21438
21439 \end_inset
21440
21441 ), though made lowercase and with non-alphanumeric characters converted
21442  to underscores, for example: float-table.
21443 \end_layout
21444
21445 \begin_layout Description
21446 \begin_inset Flex Code
21447 status collapsed
21448
21449 \begin_layout Plain Layout
21450 HTMLStyle
21451 \end_layout
21452
21453 \end_inset
21454
21455  CSS style information to be included when this float is used.
21456  Note that this will automatically be wrapped in a layout-generated 
21457 \begin_inset Flex Code
21458 status collapsed
21459
21460 \begin_layout Plain Layout
21461 <style>
21462 \end_layout
21463
21464 \end_inset
21465
21466  block, so only the CSS itself need be included.
21467 \end_layout
21468
21469 \begin_layout Description
21470 \begin_inset Flex Code
21471 status collapsed
21472
21473 \begin_layout Plain Layout
21474 HTMLTag
21475 \end_layout
21476
21477 \end_inset
21478
21479  [
21480 \begin_inset Flex Code
21481 status collapsed
21482
21483 \begin_layout Plain Layout
21484 string
21485 \end_layout
21486
21487 \end_inset
21488
21489 ] The tag to be used for this float, replacing 
21490 \begin_inset Quotes eld
21491 \end_inset
21492
21493
21494 \begin_inset Flex Code
21495 status collapsed
21496
21497 \begin_layout Plain Layout
21498 tag
21499 \end_layout
21500
21501 \end_inset
21502
21503
21504 \begin_inset Quotes erd
21505 \end_inset
21506
21507  in the example above.
21508  The default is 
21509 \begin_inset Flex Code
21510 status collapsed
21511
21512 \begin_layout Plain Layout
21513 div
21514 \end_layout
21515
21516 \end_inset
21517
21518  and will rarely need changing.
21519 \end_layout
21520
21521 \begin_layout Subsection
21522 Bibliography formatting
21523 \end_layout
21524
21525 \begin_layout Standard
21526 The bibliography can be formatted using 
21527 \begin_inset Flex Code
21528 status collapsed
21529
21530 \begin_layout Plain Layout
21531 CiteFormat
21532 \end_layout
21533
21534 \end_inset
21535
21536  blocks.
21537  See 
21538 \begin_inset CommandInset ref
21539 LatexCommand ref
21540 reference "sub:Citation-format-description"
21541
21542 \end_inset
21543
21544  for the details.
21545 \end_layout
21546
21547 \begin_layout Subsection
21548 LyX-generated CSS
21549 \end_layout
21550
21551 \begin_layout Standard
21552 We have several times mentioned that LyX will generate default CSS style
21553  rules for both insets and paragraph styles, based upon the other layout
21554  information that is provided.
21555  In this section, we shall say a word about which layout information LyX
21556  uses and how.
21557 \end_layout
21558
21559 \begin_layout Standard
21560 At present, LyX auto-generates CSS only for font information, making use
21561  of the 
21562 \begin_inset Flex Code
21563 status collapsed
21564
21565 \begin_layout Plain Layout
21566 Family
21567 \end_layout
21568
21569 \end_inset
21570
21571
21572 \begin_inset Flex Code
21573 status collapsed
21574
21575 \begin_layout Plain Layout
21576 Series
21577 \end_layout
21578
21579 \end_inset
21580
21581
21582 \begin_inset Flex Code
21583 status collapsed
21584
21585 \begin_layout Plain Layout
21586 Shape
21587 \end_layout
21588
21589 \end_inset
21590
21591 , and 
21592 \begin_inset Flex Code
21593 status collapsed
21594
21595 \begin_layout Plain Layout
21596 Size
21597 \end_layout
21598
21599 \end_inset
21600
21601  specified in the 
21602 \begin_inset Flex Code
21603 status collapsed
21604
21605 \begin_layout Plain Layout
21606 Font
21607 \end_layout
21608
21609 \end_inset
21610
21611  declaration (see 
21612 \begin_inset CommandInset ref
21613 LatexCommand ref
21614 reference "sub:Font-description"
21615
21616 \end_inset
21617
21618 ).
21619  The translation is mostly straightforward and obvious.
21620  For example, 
21621 \begin_inset Quotes eld
21622 \end_inset
21623
21624
21625 \begin_inset Flex Code
21626 status collapsed
21627
21628 \begin_layout Plain Layout
21629 Family Sans
21630 \end_layout
21631
21632 \end_inset
21633
21634
21635 \begin_inset Quotes erd
21636 \end_inset
21637
21638  becomes 
21639 \begin_inset Quotes eld
21640 \end_inset
21641
21642
21643 \begin_inset Flex Code
21644 status collapsed
21645
21646 \begin_layout Plain Layout
21647 font-family: sans-serif;
21648 \end_layout
21649
21650 \end_inset
21651
21652
21653 \begin_inset Quotes erd
21654 \end_inset
21655
21656 .
21657  The correspondence of LyX sizes and CSS sizes is a little less obvious
21658  but nonetheless intuitive.
21659  See the 
21660 \begin_inset Flex Code
21661 status collapsed
21662
21663 \begin_layout Plain Layout
21664 getSizeCSS()
21665 \end_layout
21666
21667 \end_inset
21668
21669  function in 
21670 \begin_inset Flex URL
21671 status collapsed
21672
21673 \begin_layout Plain Layout
21674
21675 src/FontInfo.cpp
21676 \end_layout
21677
21678 \end_inset
21679
21680  for the details.
21681 \end_layout
21682
21683 \begin_layout Chapter
21684 Including External Material
21685 \begin_inset CommandInset label
21686 LatexCommand label
21687 name "chap:Including-External-Material"
21688
21689 \end_inset
21690
21691
21692 \end_layout
21693
21694 \begin_layout Standard
21695 \begin_inset Box Shadowbox
21696 position "t"
21697 hor_pos "c"
21698 has_inner_box 1
21699 inner_pos "t"
21700 use_parbox 0
21701 use_makebox 0
21702 width "100col%"
21703 special "none"
21704 height "1in"
21705 height_special "totalheight"
21706 status open
21707
21708 \begin_layout Plain Layout
21709 WARNING: This portion of the documentation has not been updated for some
21710  time.
21711  We certainly hope that it is still accurate, but there are no guarantees.
21712 \end_layout
21713
21714 \end_inset
21715
21716
21717 \end_layout
21718
21719 \begin_layout Standard
21720 The use of material from sources external to LyX is covered in detail in
21721  the 
21722 \emph on
21723 Embedded Objects
21724 \emph default
21725  manual.
21726  This part of the manual covers what needs to happen behind the scenes for
21727  new sorts of material to be included.
21728 \end_layout
21729
21730 \begin_layout Section
21731 How does it work?
21732 \end_layout
21733
21734 \begin_layout Standard
21735 The external material feature is based on the concept of a 
21736 \emph on
21737 template
21738 \emph default
21739 .
21740  A template is a specification of how LyX should interface with a certain
21741  kind of material.
21742  As bundled, LyX comes with predefined templates for Xfig figures, various
21743  raster format images, chess diagrams, and LilyPond music notation.
21744  You can check the actual list by using the menu 
21745 \begin_inset Flex MenuItem
21746 status collapsed
21747
21748 \begin_layout Plain Layout
21749 Insert\SpecialChar \menuseparator
21750 File\SpecialChar \menuseparator
21751 External Material
21752 \end_layout
21753
21754 \end_inset
21755
21756 .
21757  Furthermore, it is possible to roll your own template to support a specific
21758  kind of material.
21759  Later we'll describe in more detail what is involved, and hopefully you
21760  will submit all the templates you create so we can include them in a later
21761  LyX version.
21762 \end_layout
21763
21764 \begin_layout Standard
21765 Another basic idea of the external material feature is to distinguish between
21766  the original file that serves as a base for final material and the produced
21767  file that is included in your exported or printed document.
21768  For example, consider the case of a figure produced with 
21769 \begin_inset Flex Code
21770 status collapsed
21771
21772 \begin_layout Plain Layout
21773 Xfig
21774 \end_layout
21775
21776 \end_inset
21777
21778 .
21779  The Xfig application itself works on an original file with the 
21780 \begin_inset Flex Code
21781 status collapsed
21782
21783 \begin_layout Plain Layout
21784 .fig
21785 \end_layout
21786
21787 \end_inset
21788
21789  extension.
21790  Within Xfig, you create and change your figure, and when you are done,
21791  you save the 
21792 \begin_inset Flex Code
21793 status collapsed
21794
21795 \begin_layout Plain Layout
21796 fig
21797 \end_layout
21798
21799 \end_inset
21800
21801 -file.
21802  When you want to include the figure in your document, you invoke 
21803 \begin_inset Flex Code
21804 status collapsed
21805
21806 \begin_layout Plain Layout
21807 transfig
21808 \end_layout
21809
21810 \end_inset
21811
21812  in order to create a PostScript file that can readily be included in your
21813  LaTeX file.
21814  In this case, the 
21815 \begin_inset Flex Code
21816 status collapsed
21817
21818 \begin_layout Plain Layout
21819 .fig
21820 \end_layout
21821
21822 \end_inset
21823
21824  file is the original file, and the PostScript file is the produced file.
21825 \end_layout
21826
21827 \begin_layout Standard
21828 This distinction is important in order to allow updating of the material
21829  while you are in the process of writing the document.
21830  Furthermore, it provides us with the flexibility that is needed to support
21831  multiple export formats.
21832  For instance, in the case of a plain text file, it is not exactly an award-winn
21833 ing idea to include the figure as raw PostScript.
21834  Instead, you would either prefer to just include a reference to the figure
21835  or try to invoke some graphics to ASCII converter to make the final result
21836  look similar to the real graphics.
21837  The external material management allows you to do this, because it is parametri
21838 zed on the different export formats that LyX supports.
21839 \end_layout
21840
21841 \begin_layout Standard
21842 Besides supporting the production of different products according to the
21843  exported format, it supports tight integration with editing and viewing
21844  applications.
21845  In the case of an Xfig figure, you are able to invoke Xfig on the original
21846  file with a single click from within the external material dialog in LyX,
21847  and also preview the produced PostScript file with Ghostview with another
21848  click.
21849  No more fiddling around with the command line and/or file browsers to locate
21850  and manipulate the original or produced files.
21851  In this way, you are finally able to take full advantage of the many different
21852  applications that are relevant to use when you write your documents, and
21853  ultimately be more productive.
21854 \end_layout
21855
21856 \begin_layout Section
21857 The external template configuration file
21858 \end_layout
21859
21860 \begin_layout Standard
21861 It is relatively easy to add custom external template definitions to LyX.
21862  However, be aware that doing this in an careless manner most probably 
21863 \emph on
21864 will
21865 \emph default
21866  introduce an easily exploitable security hole.
21867  So before you do this, please read the discussion about security in 
21868 \begin_inset CommandInset ref
21869 LatexCommand ref
21870 reference "sec:Security-discussion"
21871
21872 \end_inset
21873
21874 .
21875 \end_layout
21876
21877 \begin_layout Standard
21878 Having said that, we encourage you to submit any interesting templates that
21879  you create.
21880  
21881 \end_layout
21882
21883 \begin_layout Standard
21884 The external templates are defined in the 
21885 \begin_inset Flex Code
21886 status collapsed
21887
21888 \begin_layout Plain Layout
21889 LyXDir/lib/external_templates
21890 \end_layout
21891
21892 \end_inset
21893
21894  file.
21895  You can place your own version in 
21896 \begin_inset Flex Code
21897 status collapsed
21898
21899 \begin_layout Plain Layout
21900 UserDir/external_templates
21901 \end_layout
21902
21903 \end_inset
21904
21905 .
21906 \end_layout
21907
21908 \begin_layout Standard
21909 A typical template looks like this:
21910 \end_layout
21911
21912 \begin_layout LyX-Code
21913 Template XFig
21914 \end_layout
21915
21916 \begin_layout LyX-Code
21917 GuiName "XFig: $$AbsOrRelPathParent$$Basename"
21918 \end_layout
21919
21920 \begin_layout LyX-Code
21921 HelpText
21922 \end_layout
21923
21924 \begin_layout LyX-Code
21925 An XFig figure.
21926 \end_layout
21927
21928 \begin_layout LyX-Code
21929 HelpTextEnd
21930 \end_layout
21931
21932 \begin_layout LyX-Code
21933 InputFormat fig
21934 \end_layout
21935
21936 \begin_layout LyX-Code
21937 FileFilter "*.fig"
21938 \end_layout
21939
21940 \begin_layout LyX-Code
21941 AutomaticProduction true
21942 \end_layout
21943
21944 \begin_layout LyX-Code
21945 Transform Rotate
21946 \end_layout
21947
21948 \begin_layout LyX-Code
21949 Transform Resize
21950 \end_layout
21951
21952 \begin_layout LyX-Code
21953 Format LaTeX
21954 \end_layout
21955
21956 \begin_layout LyX-Code
21957 TransformCommand Rotate RotationLatexCommand
21958 \end_layout
21959
21960 \begin_layout LyX-Code
21961 TransformCommand Resize ResizeLatexCommand
21962 \end_layout
21963
21964 \begin_layout LyX-Code
21965 Product "$$RotateFront$$ResizeFront
21966 \end_layout
21967
21968 \begin_layout LyX-Code
21969          
21970 \backslash
21971
21972 \backslash
21973 input{$$AbsOrRelPathMaster$$Basename.pstex_t}
21974 \end_layout
21975
21976 \begin_layout LyX-Code
21977          $$ResizeBack$$RotateBack"
21978 \end_layout
21979
21980 \begin_layout LyX-Code
21981 UpdateFormat pstex
21982 \end_layout
21983
21984 \begin_layout LyX-Code
21985 UpdateResult "$$AbsPath$$Basename.pstex_t"
21986 \end_layout
21987
21988 \begin_layout LyX-Code
21989 Requirement "graphicx"
21990 \end_layout
21991
21992 \begin_layout LyX-Code
21993 ReferencedFile latex "$$AbsOrRelPathMaster$$Basename.pstex_t"
21994 \end_layout
21995
21996 \begin_layout LyX-Code
21997 ReferencedFile latex "$$AbsPath$$Basename.eps"
21998 \end_layout
21999
22000 \begin_layout LyX-Code
22001 ReferencedFile dvi "$$AbsPath$$Basename.eps"
22002 \end_layout
22003
22004 \begin_layout LyX-Code
22005 FormatEnd
22006 \end_layout
22007
22008 \begin_layout LyX-Code
22009 Format PDFLaTeX
22010 \end_layout
22011
22012 \begin_layout LyX-Code
22013 TransformCommand Rotate RotationLatexCommand
22014 \end_layout
22015
22016 \begin_layout LyX-Code
22017 TransformCommand Resize ResizeLatexCommand
22018 \end_layout
22019
22020 \begin_layout LyX-Code
22021 Product "$$RotateFront$$ResizeFront
22022 \end_layout
22023
22024 \begin_layout LyX-Code
22025          
22026 \backslash
22027
22028 \backslash
22029 input{$$AbsOrRelPathMaster$$Basename.pdftex_t}
22030 \end_layout
22031
22032 \begin_layout LyX-Code
22033          $$ResizeBack$$RotateBack"
22034 \end_layout
22035
22036 \begin_layout LyX-Code
22037 UpdateFormat pdftex
22038 \end_layout
22039
22040 \begin_layout LyX-Code
22041 UpdateResult "$$AbsPath$$Basename.pdftex_t"
22042 \end_layout
22043
22044 \begin_layout LyX-Code
22045 Requirement "graphicx"
22046 \end_layout
22047
22048 \begin_layout LyX-Code
22049 ReferencedFile latex "$$AbsOrRelPathMaster$$Basename.pdftex_t"
22050 \end_layout
22051
22052 \begin_layout LyX-Code
22053 ReferencedFile latex "$$AbsPath$$Basename.pdf"
22054 \end_layout
22055
22056 \begin_layout LyX-Code
22057 FormatEnd
22058 \end_layout
22059
22060 \begin_layout LyX-Code
22061 Format Ascii
22062 \end_layout
22063
22064 \begin_layout LyX-Code
22065 Product "$$Contents(
22066 \backslash
22067 "$$AbsPath$$Basename.asc
22068 \backslash
22069 ")"
22070 \end_layout
22071
22072 \begin_layout LyX-Code
22073 UpdateFormat asciixfig
22074 \end_layout
22075
22076 \begin_layout LyX-Code
22077 UpdateResult "$$AbsPath$$Basename.asc"
22078 \end_layout
22079
22080 \begin_layout LyX-Code
22081 FormatEnd
22082 \end_layout
22083
22084 \begin_layout LyX-Code
22085 Format DocBook
22086 \end_layout
22087
22088 \begin_layout LyX-Code
22089 Product "<graphic fileref=
22090 \backslash
22091 "$$AbsOrRelPathMaster$$Basename.eps
22092 \backslash
22093 ">
22094 \end_layout
22095
22096 \begin_layout LyX-Code
22097          </graphic>"
22098 \end_layout
22099
22100 \begin_layout LyX-Code
22101 UpdateFormat eps
22102 \end_layout
22103
22104 \begin_layout LyX-Code
22105 UpdateResult "$$AbsPath$$Basename.eps"
22106 \end_layout
22107
22108 \begin_layout LyX-Code
22109 ReferencedFile docbook "$$AbsPath$$Basename.eps"
22110 \end_layout
22111
22112 \begin_layout LyX-Code
22113 ReferencedFile docbook-xml "$$AbsPath$$Basename.eps"
22114 \end_layout
22115
22116 \begin_layout LyX-Code
22117 FormatEnd
22118 \end_layout
22119
22120 \begin_layout LyX-Code
22121 Product "[XFig: $$FName]"
22122 \end_layout
22123
22124 \begin_layout LyX-Code
22125 FormatEnd
22126 \end_layout
22127
22128 \begin_layout LyX-Code
22129 TemplateEnd
22130 \end_layout
22131
22132 \begin_layout Standard
22133 As you can see, the template is enclosed in 
22134 \begin_inset Flex Code
22135 status collapsed
22136
22137 \begin_layout Plain Layout
22138 Template
22139 \end_layout
22140
22141 \end_inset
22142
22143  \SpecialChar \ldots{}
22144  
22145 \begin_inset Flex Code
22146 status collapsed
22147
22148 \begin_layout Plain Layout
22149 TemplateEnd
22150 \end_layout
22151
22152 \end_inset
22153
22154 .
22155  It contains a header specifying some general settings and, for each supported
22156  primary document file format, a section 
22157 \begin_inset Flex Code
22158 status collapsed
22159
22160 \begin_layout Plain Layout
22161 Format
22162 \end_layout
22163
22164 \end_inset
22165
22166  \SpecialChar \ldots{}
22167  
22168 \begin_inset Flex Code
22169 status collapsed
22170
22171 \begin_layout Plain Layout
22172 FormatEnd
22173 \end_layout
22174
22175 \end_inset
22176
22177 .
22178 \end_layout
22179
22180 \begin_layout Subsection
22181 The template header
22182 \end_layout
22183
22184 \begin_layout Description
22185 \begin_inset Flex Code
22186 status collapsed
22187
22188 \begin_layout Plain Layout
22189 AutomaticProduction
22190 \begin_inset space ~
22191 \end_inset
22192
22193 true|false
22194 \end_layout
22195
22196 \end_inset
22197
22198  Whether the file represented by the template must be generated by LyX.
22199  This command must occur exactly once.
22200 \end_layout
22201
22202 \begin_layout Description
22203 \begin_inset Flex Code
22204 status collapsed
22205
22206 \begin_layout Plain Layout
22207 FileFilter
22208 \begin_inset space ~
22209 \end_inset
22210
22211 <pattern>
22212 \end_layout
22213
22214 \end_inset
22215
22216  A glob pattern that is used in the file dialog to filter out the desired
22217  files.
22218  If there is more than one possible file extension (e.
22219 \begin_inset space \thinspace{}
22220 \end_inset
22221
22222 g.
22223 \begin_inset space \space{}
22224 \end_inset
22225
22226 tgif has 
22227 \begin_inset Flex Code
22228 status collapsed
22229
22230 \begin_layout Plain Layout
22231 .obj
22232 \end_layout
22233
22234 \end_inset
22235
22236  and 
22237 \begin_inset Flex Code
22238 status collapsed
22239
22240 \begin_layout Plain Layout
22241 .tgo
22242 \end_layout
22243
22244 \end_inset
22245
22246 ), use something like 
22247 \begin_inset Flex Code
22248 status collapsed
22249
22250 \begin_layout Plain Layout
22251 "*.{obj,tgo}"
22252 \end_layout
22253
22254 \end_inset
22255
22256 .
22257  This command must occur exactly once.
22258 \end_layout
22259
22260 \begin_layout Description
22261 \begin_inset Flex Code
22262 status collapsed
22263
22264 \begin_layout Plain Layout
22265 GuiName
22266 \begin_inset space ~
22267 \end_inset
22268
22269 <guiname>
22270 \end_layout
22271
22272 \end_inset
22273
22274  The text that is displayed on the button.
22275  This command must occur exactly once.
22276 \end_layout
22277
22278 \begin_layout Description
22279 \begin_inset Flex Code
22280 status collapsed
22281
22282 \begin_layout Plain Layout
22283 HelpText
22284 \begin_inset space ~
22285 \end_inset
22286
22287 <text>
22288 \begin_inset space ~
22289 \end_inset
22290
22291 HelpTextEnd
22292 \end_layout
22293
22294 \end_inset
22295
22296  The help text that is used in the External dialog.
22297  Provide enough information to explain to the user just what the template
22298  can provide him with.
22299  This command must occur exactly once.
22300 \end_layout
22301
22302 \begin_layout Description
22303 \begin_inset Flex Code
22304 status collapsed
22305
22306 \begin_layout Plain Layout
22307 InputFormat
22308 \begin_inset space ~
22309 \end_inset
22310
22311 <format>
22312 \end_layout
22313
22314 \end_inset
22315
22316  The file format of the original file.
22317  This must be the name of a format that is known to LyX (see 
22318 \begin_inset CommandInset ref
22319 LatexCommand ref
22320 reference "sec:Formats"
22321
22322 \end_inset
22323
22324 ).
22325  Use 
22326 \begin_inset Quotes eld
22327 \end_inset
22328
22329
22330 \begin_inset Flex Code
22331 status collapsed
22332
22333 \begin_layout Plain Layout
22334 *
22335 \end_layout
22336
22337 \end_inset
22338
22339
22340 \begin_inset Quotes erd
22341 \end_inset
22342
22343  if the template can handle original files of more than one format.
22344  LyX will attempt to interrogate the file itself in order to deduce its
22345  format in this case.
22346  This command must occur exactly once.
22347 \end_layout
22348
22349 \begin_layout Description
22350 \begin_inset Flex Code
22351 status collapsed
22352
22353 \begin_layout Plain Layout
22354 Template
22355 \begin_inset space ~
22356 \end_inset
22357
22358 <id>
22359 \end_layout
22360
22361 \end_inset
22362
22363  A unique name for the template.
22364  It must not contain substitution macros (see below).
22365 \end_layout
22366
22367 \begin_layout Description
22368 \begin_inset Flex Code
22369 status collapsed
22370
22371 \begin_layout Plain Layout
22372 Transform
22373 \begin_inset space ~
22374 \end_inset
22375
22376 Rotate|Resize|Clip|Extra
22377 \end_layout
22378
22379 \end_inset
22380
22381  This command specifies which transformations are supported by this template.
22382  It may occur zero or more times.
22383  This command enables the corresponding tabs in the external dialog.
22384  Each 
22385 \begin_inset Flex Code
22386 status collapsed
22387
22388 \begin_layout Plain Layout
22389 Transform
22390 \end_layout
22391
22392 \end_inset
22393
22394  command must have either a corresponding 
22395 \begin_inset Flex Code
22396 status collapsed
22397
22398 \begin_layout Plain Layout
22399 TransformCommand
22400 \end_layout
22401
22402 \end_inset
22403
22404  or a 
22405 \begin_inset Flex Code
22406 status collapsed
22407
22408 \begin_layout Plain Layout
22409 TransformOption
22410 \end_layout
22411
22412 \end_inset
22413
22414  command in the 
22415 \begin_inset Flex Code
22416 status collapsed
22417
22418 \begin_layout Plain Layout
22419 Format
22420 \end_layout
22421
22422 \end_inset
22423
22424  section.
22425  Otherwise the transformation will not be supported by that format.
22426 \end_layout
22427
22428 \begin_layout Subsection
22429 The Format section
22430 \end_layout
22431
22432 \begin_layout Description
22433 \begin_inset Flex Code
22434 status collapsed
22435
22436 \begin_layout Plain Layout
22437 Format
22438 \begin_inset space ~
22439 \end_inset
22440
22441 LaTeX|PDFLaTeX|PlainText|DocBook
22442 \end_layout
22443
22444 \end_inset
22445
22446  The primary document file format that this format definition is for.
22447  Not every template has a sensible representation in all document file formats.
22448  Please define nevertheless a 
22449 \begin_inset Flex Code
22450 status collapsed
22451
22452 \begin_layout Plain Layout
22453 Format
22454 \end_layout
22455
22456 \end_inset
22457
22458  section for all templates.
22459  Use a dummy text when no representation is available.
22460  Then you can at least see a reference to the external material in the exported
22461  document.
22462 \end_layout
22463
22464 \begin_layout Description
22465 \begin_inset Flex Code
22466 status collapsed
22467
22468 \begin_layout Plain Layout
22469 Option
22470 \begin_inset space ~
22471 \end_inset
22472
22473 <name>
22474 \begin_inset space ~
22475 \end_inset
22476
22477 <value>
22478 \end_layout
22479
22480 \end_inset
22481
22482  This command defines an additional macro 
22483 \begin_inset Flex Code
22484 status collapsed
22485
22486 \begin_layout Plain Layout
22487 $$<name>
22488 \end_layout
22489
22490 \end_inset
22491
22492  for substitution in 
22493 \begin_inset Flex Code
22494 status collapsed
22495
22496 \begin_layout Plain Layout
22497 Product
22498 \end_layout
22499
22500 \end_inset
22501
22502 .
22503  
22504 \begin_inset Flex Code
22505 status collapsed
22506
22507 \begin_layout Plain Layout
22508 <value>
22509 \end_layout
22510
22511 \end_inset
22512
22513  itself may contain substitution macros.
22514  The advantage over using 
22515 \begin_inset Flex Code
22516 status collapsed
22517
22518 \begin_layout Plain Layout
22519 <value>
22520 \end_layout
22521
22522 \end_inset
22523
22524  directly in 
22525 \begin_inset Flex Code
22526 status collapsed
22527
22528 \begin_layout Plain Layout
22529 Product
22530 \end_layout
22531
22532 \end_inset
22533
22534  is that the substituted value of 
22535 \begin_inset Flex Code
22536 status collapsed
22537
22538 \begin_layout Plain Layout
22539 $$<name>
22540 \end_layout
22541
22542 \end_inset
22543
22544  is sanitized so that it is a valid optional argument in the document format.
22545  This command may occur zero or more times.
22546 \end_layout
22547
22548 \begin_layout Description
22549 \begin_inset Flex Code
22550 status collapsed
22551
22552 \begin_layout Plain Layout
22553 Product
22554 \begin_inset space ~
22555 \end_inset
22556
22557 <text>
22558 \end_layout
22559
22560 \end_inset
22561
22562  The text that is inserted in the exported document.
22563  This is actually the most important command and can be quite complex.
22564  This command must occur exactly once.
22565 \end_layout
22566
22567 \begin_layout Description
22568 \begin_inset Flex Code
22569 status collapsed
22570
22571 \begin_layout Plain Layout
22572 Preamble
22573 \begin_inset space ~
22574 \end_inset
22575
22576 <name>
22577 \end_layout
22578
22579 \end_inset
22580
22581  This command specifies a preamble snippet that will be included in the
22582  LaTeX preamble.
22583  It has to be defined using 
22584 \begin_inset Flex Code
22585 status collapsed
22586
22587 \begin_layout Plain Layout
22588 PreambleDef
22589 \end_layout
22590
22591 \end_inset
22592
22593  \SpecialChar \ldots{}
22594  
22595 \begin_inset Flex Code
22596 status collapsed
22597
22598 \begin_layout Plain Layout
22599 PreambleDefEnd
22600 \end_layout
22601
22602 \end_inset
22603
22604 .
22605  This command may occur zero or more times.
22606 \end_layout
22607
22608 \begin_layout Description
22609 \begin_inset Flex Code
22610 status collapsed
22611
22612 \begin_layout Plain Layout
22613 ReferencedFile
22614 \begin_inset space ~
22615 \end_inset
22616
22617 <format>
22618 \begin_inset space ~
22619 \end_inset
22620
22621 <filename>
22622 \end_layout
22623
22624 \end_inset
22625
22626  This command denotes files that are created by the conversion process and
22627  are needed for a particular export format.
22628  If the filename is relative, it is interpreted relative to the master document.
22629  This command may be given zero or more times.
22630 \end_layout
22631
22632 \begin_layout Description
22633 \begin_inset Flex Code
22634 status collapsed
22635
22636 \begin_layout Plain Layout
22637 Requirement
22638 \begin_inset space ~
22639 \end_inset
22640
22641 <package>
22642 \end_layout
22643
22644 \end_inset
22645
22646  The name of a required LaTeX package.
22647  The package is included via 
22648 \begin_inset Flex Code
22649 status collapsed
22650
22651 \begin_layout Plain Layout
22652
22653 \backslash
22654 usepackage{}
22655 \end_layout
22656
22657 \end_inset
22658
22659  in the LaTeX preamble.
22660  This command may occur zero or more times.
22661 \end_layout
22662
22663 \begin_layout Description
22664 \begin_inset Flex Code
22665 status collapsed
22666
22667 \begin_layout Plain Layout
22668 TransformCommand
22669 \begin_inset space ~
22670 \end_inset
22671
22672 Rotate
22673 \begin_inset space ~
22674 \end_inset
22675
22676 RotationLatexCommand
22677 \end_layout
22678
22679 \end_inset
22680
22681  This command specifies that the built in LaTeX command should be used for
22682  rotation.
22683  This command may occur once or not at all.
22684 \end_layout
22685
22686 \begin_layout Description
22687 \begin_inset Flex Code
22688 status collapsed
22689
22690 \begin_layout Plain Layout
22691 TransformCommand
22692 \begin_inset space ~
22693 \end_inset
22694
22695 Resize
22696 \begin_inset space ~
22697 \end_inset
22698
22699 ResizeLatexCommand
22700 \end_layout
22701
22702 \end_inset
22703
22704  This command specifies that the built in LaTeX command should be used for
22705  resizing.
22706  This command may occur once or not at all.
22707 \end_layout
22708
22709 \begin_layout Description
22710 \begin_inset Flex Code
22711 status collapsed
22712
22713 \begin_layout Plain Layout
22714 TransformOption
22715 \begin_inset space ~
22716 \end_inset
22717
22718 Rotate
22719 \begin_inset space ~
22720 \end_inset
22721
22722 RotationLatexOption
22723 \end_layout
22724
22725 \end_inset
22726
22727  This command specifies that rotation is done via an optional argument.
22728  This command may occur once or not at all.
22729 \end_layout
22730
22731 \begin_layout Description
22732 \begin_inset Flex Code
22733 status collapsed
22734
22735 \begin_layout Plain Layout
22736 TransformOption
22737 \begin_inset space ~
22738 \end_inset
22739
22740 Resize
22741 \begin_inset space ~
22742 \end_inset
22743
22744 ResizeLatexOption
22745 \end_layout
22746
22747 \end_inset
22748
22749  This command specifies that resizing is done via an optional argument.
22750  This command may occur once or not at all.
22751 \end_layout
22752
22753 \begin_layout Description
22754 \begin_inset Flex Code
22755 status collapsed
22756
22757 \begin_layout Plain Layout
22758 TransformOption
22759 \begin_inset space ~
22760 \end_inset
22761
22762 Clip
22763 \begin_inset space ~
22764 \end_inset
22765
22766 ClipLatexOption
22767 \end_layout
22768
22769 \end_inset
22770
22771  This command specifies that clipping is done via an optional argument.
22772  This command may occur once or not at all.
22773 \end_layout
22774
22775 \begin_layout Description
22776 \begin_inset Flex Code
22777 status collapsed
22778
22779 \begin_layout Plain Layout
22780 TransformOption
22781 \begin_inset space ~
22782 \end_inset
22783
22784 Extra
22785 \begin_inset space ~
22786 \end_inset
22787
22788 ExtraLatexOption
22789 \end_layout
22790
22791 \end_inset
22792
22793  This command specifies that an extra optional argument is used.
22794  This command may occur once or not at all.
22795 \end_layout
22796
22797 \begin_layout Description
22798 \begin_inset Flex Code
22799 status collapsed
22800
22801 \begin_layout Plain Layout
22802 UpdateFormat
22803 \begin_inset space ~
22804 \end_inset
22805
22806 <format>
22807 \end_layout
22808
22809 \end_inset
22810
22811  The file format of the converted file.
22812  This must be the name of a format that is known to LyX (see the 
22813 \begin_inset Flex MenuItem
22814 status collapsed
22815
22816 \begin_layout Plain Layout
22817 Tools\SpecialChar \menuseparator
22818 Preferences\SpecialChar \menuseparator
22819 File Handling\SpecialChar \menuseparator
22820 File Format
22821 \end_layout
22822
22823 \end_inset
22824
22825  dialog).
22826  This command must occur exactly once.
22827  If the resulting file format is PDF, you need to specify the format 
22828 \begin_inset Flex Code
22829 status collapsed
22830
22831 \begin_layout Plain Layout
22832 pdf6
22833 \end_layout
22834
22835 \end_inset
22836
22837 .
22838  This is the PDF format used for including graphics.
22839  The other defined PDF formats are for document export.
22840 \end_layout
22841
22842 \begin_layout Description
22843 \begin_inset Flex Code
22844 status collapsed
22845
22846 \begin_layout Plain Layout
22847 UpdateResult
22848 \begin_inset space ~
22849 \end_inset
22850
22851 <filename>
22852 \end_layout
22853
22854 \end_inset
22855
22856  The file name of the converted file.
22857  The file name must be absolute.
22858  This command must occur exactly once.
22859 \end_layout
22860
22861 \begin_layout Subsection
22862 Preamble definitions
22863 \end_layout
22864
22865 \begin_layout Standard
22866 The external template configuration file may contain additional preamble
22867  definitions enclosed by 
22868 \begin_inset Flex Code
22869 status collapsed
22870
22871 \begin_layout Plain Layout
22872 PreambleDef
22873 \end_layout
22874
22875 \end_inset
22876
22877  \SpecialChar \ldots{}
22878  
22879 \begin_inset Flex Code
22880 status collapsed
22881
22882 \begin_layout Plain Layout
22883 PreambleDefEnd
22884 \end_layout
22885
22886 \end_inset
22887
22888 .
22889  They can be used by the templates in the 
22890 \begin_inset Flex Code
22891 status collapsed
22892
22893 \begin_layout Plain Layout
22894 Format
22895 \end_layout
22896
22897 \end_inset
22898
22899  section.
22900 \end_layout
22901
22902 \begin_layout Section
22903 The substitution mechanism
22904 \end_layout
22905
22906 \begin_layout Standard
22907 When the external material facility invokes an external program, it is done
22908  on the basis of a command defined in the template configuration file.
22909  These commands can contain various macros that are expanded before execution.
22910  Execution always take place in the directory of the containing document.
22911 \end_layout
22912
22913 \begin_layout Standard
22914 Also, whenever external material is to be displayed, the name will be produced
22915  by the substitution mechanism, and most other commands in the template
22916  definition support substitution as well.
22917 \end_layout
22918
22919 \begin_layout Standard
22920 The available macros are the following:
22921 \end_layout
22922
22923 \begin_layout Description
22924 \begin_inset Flex Code
22925 status collapsed
22926
22927 \begin_layout Plain Layout
22928 $$AbsOrRelPathMaster
22929 \end_layout
22930
22931 \end_inset
22932
22933  The file path, absolute or relative to the master LyX document.
22934 \end_layout
22935
22936 \begin_layout Description
22937 \begin_inset Flex Code
22938 status collapsed
22939
22940 \begin_layout Plain Layout
22941 $$AbsOrRelPathParent
22942 \end_layout
22943
22944 \end_inset
22945
22946  The file path, absolute or relative to the LyX document.
22947 \end_layout
22948
22949 \begin_layout Description
22950 \begin_inset Flex Code
22951 status collapsed
22952
22953 \begin_layout Plain Layout
22954 $$AbsPath
22955 \end_layout
22956
22957 \end_inset
22958
22959  The absolute file path.
22960 \end_layout
22961
22962 \begin_layout Description
22963 \begin_inset Flex Code
22964 status collapsed
22965
22966 \begin_layout Plain Layout
22967 $$Basename
22968 \end_layout
22969
22970 \end_inset
22971
22972  The filename without path and without the extension.
22973 \end_layout
22974
22975 \begin_layout Description
22976 \begin_inset Flex Code
22977 status collapsed
22978
22979 \begin_layout Plain Layout
22980 $$Contents(
22981 \begin_inset Quotes eld
22982 \end_inset
22983
22984 filename.ext
22985 \begin_inset Quotes erd
22986 \end_inset
22987
22988 )
22989 \end_layout
22990
22991 \end_inset
22992
22993  This macro will expand to the contents of the file with the name 
22994 \begin_inset Flex Code
22995 status collapsed
22996
22997 \begin_layout Plain Layout
22998 filename.ext
22999 \end_layout
23000
23001 \end_inset
23002
23003 .
23004 \end_layout
23005
23006 \begin_layout Description
23007 \begin_inset Flex Code
23008 status collapsed
23009
23010 \begin_layout Plain Layout
23011 $$Extension
23012 \end_layout
23013
23014 \end_inset
23015
23016  The file extension (including the dot).
23017 \end_layout
23018
23019 \begin_layout Description
23020 \begin_inset Flex Code
23021 status collapsed
23022
23023 \begin_layout Plain Layout
23024 $$FName
23025 \end_layout
23026
23027 \end_inset
23028
23029  The filename of the file specified in the external material dialog.
23030  This is either an absolute name, or it is relative to the LyX document.
23031 \end_layout
23032
23033 \begin_layout Description
23034 \begin_inset Flex Code
23035 status collapsed
23036
23037 \begin_layout Plain Layout
23038 $$FPath
23039 \end_layout
23040
23041 \end_inset
23042
23043  The path part of 
23044 \begin_inset Flex Code
23045 status collapsed
23046
23047 \begin_layout Plain Layout
23048 $$FName
23049 \end_layout
23050
23051 \end_inset
23052
23053  (absolute name or relative to the LyX document).
23054 \end_layout
23055
23056 \begin_layout Description
23057 \begin_inset Flex Code
23058 status collapsed
23059
23060 \begin_layout Plain Layout
23061 $$RelPathMaster
23062 \end_layout
23063
23064 \end_inset
23065
23066  The file path, relative to the master LyX document.
23067 \end_layout
23068
23069 \begin_layout Description
23070 \begin_inset Flex Code
23071 status collapsed
23072
23073 \begin_layout Plain Layout
23074 $$RelPathParent
23075 \end_layout
23076
23077 \end_inset
23078
23079  The file path, relative to the LyX document.
23080 \end_layout
23081
23082 \begin_layout Description
23083 \begin_inset Flex Code
23084 status collapsed
23085
23086 \begin_layout Plain Layout
23087 $$Sysdir
23088 \end_layout
23089
23090 \end_inset
23091
23092  This macro will expand to the absolute path of the system directory.
23093  This is typically used to point to the various helper scripts that are
23094  bundled with LyX.
23095 \end_layout
23096
23097 \begin_layout Description
23098 \begin_inset Flex Code
23099 status collapsed
23100
23101 \begin_layout Plain Layout
23102 $$Tempname
23103 \end_layout
23104
23105 \end_inset
23106
23107  A name and full path to a temporary file which will be automatically deleted
23108  whenever the containing document is closed, or the external material insertion
23109  deleted.
23110 \end_layout
23111
23112 \begin_layout Standard
23113 All path macros contain a trailing directory separator, so you can construct
23114  e.
23115 \begin_inset space \thinspace{}
23116 \end_inset
23117
23118 g.
23119 \begin_inset space \space{}
23120 \end_inset
23121
23122 the absolute filename with 
23123 \begin_inset Flex Code
23124 status collapsed
23125
23126 \begin_layout Plain Layout
23127 $$AbsPath$$Basename$$Extension
23128 \end_layout
23129
23130 \end_inset
23131
23132 .
23133 \end_layout
23134
23135 \begin_layout Standard
23136 The macros above are substituted in all commands unless otherwise noted.
23137  The command 
23138 \begin_inset Flex Code
23139 status collapsed
23140
23141 \begin_layout Plain Layout
23142 Product
23143 \end_layout
23144
23145 \end_inset
23146
23147  supports additionally the following substitutions if they are enabled by
23148  the 
23149 \begin_inset Flex Code
23150 status collapsed
23151
23152 \begin_layout Plain Layout
23153 Transform
23154 \end_layout
23155
23156 \end_inset
23157
23158  and 
23159 \begin_inset Flex Code
23160 status collapsed
23161
23162 \begin_layout Plain Layout
23163 TransformCommand
23164 \end_layout
23165
23166 \end_inset
23167
23168  commands:
23169 \end_layout
23170
23171 \begin_layout Description
23172 \begin_inset Flex Code
23173 status collapsed
23174
23175 \begin_layout Plain Layout
23176 $$ResizeFront
23177 \end_layout
23178
23179 \end_inset
23180
23181  The front part of the resize command.
23182 \end_layout
23183
23184 \begin_layout Description
23185 \begin_inset Flex Code
23186 status collapsed
23187
23188 \begin_layout Plain Layout
23189 $$ResizeBack
23190 \end_layout
23191
23192 \end_inset
23193
23194  The back part of the resize command.
23195 \end_layout
23196
23197 \begin_layout Description
23198 \begin_inset Flex Code
23199 status collapsed
23200
23201 \begin_layout Plain Layout
23202 $$RotateFront
23203 \end_layout
23204
23205 \end_inset
23206
23207  The front part of the rotation command.
23208 \end_layout
23209
23210 \begin_layout Description
23211 \begin_inset Flex Code
23212 status collapsed
23213
23214 \begin_layout Plain Layout
23215 $$RotateBack
23216 \end_layout
23217
23218 \end_inset
23219
23220  The back part of the rotation command.
23221 \end_layout
23222
23223 \begin_layout Standard
23224 The value string of the 
23225 \begin_inset Flex Code
23226 status collapsed
23227
23228 \begin_layout Plain Layout
23229 Option
23230 \end_layout
23231
23232 \end_inset
23233
23234  command supports additionally the following substitutions if they are enabled
23235  by the 
23236 \begin_inset Flex Code
23237 status collapsed
23238
23239 \begin_layout Plain Layout
23240 Transform
23241 \end_layout
23242
23243 \end_inset
23244
23245  and 
23246 \begin_inset Flex Code
23247 status collapsed
23248
23249 \begin_layout Plain Layout
23250 TransformOption
23251 \end_layout
23252
23253 \end_inset
23254
23255  commands:
23256 \end_layout
23257
23258 \begin_layout Description
23259 \begin_inset Flex Code
23260 status collapsed
23261
23262 \begin_layout Plain Layout
23263 $$Clip
23264 \end_layout
23265
23266 \end_inset
23267
23268  The clip option.
23269 \end_layout
23270
23271 \begin_layout Description
23272 \begin_inset Flex Code
23273 status collapsed
23274
23275 \begin_layout Plain Layout
23276 $$Extra
23277 \end_layout
23278
23279 \end_inset
23280
23281  The extra option.
23282 \end_layout
23283
23284 \begin_layout Description
23285 \begin_inset Flex Code
23286 status collapsed
23287
23288 \begin_layout Plain Layout
23289 $$Resize
23290 \end_layout
23291
23292 \end_inset
23293
23294  The resize option.
23295 \end_layout
23296
23297 \begin_layout Description
23298 \begin_inset Flex Code
23299 status collapsed
23300
23301 \begin_layout Plain Layout
23302 $$Rotate
23303 \end_layout
23304
23305 \end_inset
23306
23307  The rotation option.
23308 \end_layout
23309
23310 \begin_layout Standard
23311 You may ask why there are so many path macros.
23312  There are mainly two reasons:
23313 \end_layout
23314
23315 \begin_layout Enumerate
23316 Relative and absolute file names should remain relative or absolute, respectivel
23317 y.
23318  Users may have reasons to prefer either form.
23319  Relative names are useful for portable documents that should work on different
23320  machines, for example.
23321  Absolute names may be required by some programs.
23322 \end_layout
23323
23324 \begin_layout Enumerate
23325 LaTeX treats relative file names differently than LyX and other programs
23326  in nested included files.
23327  For LyX, a relative file name is always relative to the document that contains
23328  the file name.
23329  For LaTeX, it is always relative to the master document.
23330  These two definitions are identical if you have only one document, but
23331  differ if you have a master document that includes part documents.
23332  That means that relative filenames must be transformed when presented to
23333  LaTeX.
23334  Fortunately LyX does this automatically for you if you choose the right
23335  macros.
23336 \end_layout
23337
23338 \begin_layout Standard
23339 So which path macro should be used in new template definitions? The rule
23340  is not difficult:
23341 \end_layout
23342
23343 \begin_layout Itemize
23344 Use 
23345 \begin_inset Flex Code
23346 status collapsed
23347
23348 \begin_layout Plain Layout
23349 $$AbsPath
23350 \end_layout
23351
23352 \end_inset
23353
23354  if an absolute path is required.
23355 \end_layout
23356
23357 \begin_layout Itemize
23358 Use 
23359 \begin_inset Flex Code
23360 status collapsed
23361
23362 \begin_layout Plain Layout
23363 $$AbsOrRelPathMaster
23364 \end_layout
23365
23366 \end_inset
23367
23368  if the substituted string is some kind of LaTeX input.
23369 \end_layout
23370
23371 \begin_layout Itemize
23372 Else use 
23373 \begin_inset Flex Code
23374 status collapsed
23375
23376 \begin_layout Plain Layout
23377 $$AbsOrRelPathParent
23378 \end_layout
23379
23380 \end_inset
23381
23382  in order to preserve the user's choice.
23383 \end_layout
23384
23385 \begin_layout Standard
23386 There are special cases where this rule does not work and e.
23387 \begin_inset space \thinspace{}
23388 \end_inset
23389
23390 g.
23391 \begin_inset space \space{}
23392 \end_inset
23393
23394 relative names are needed, but normally it will work just fine.
23395  One example for such a case is the command 
23396 \begin_inset Flex Code
23397 status collapsed
23398
23399 \begin_layout Plain Layout
23400 ReferencedFile latex "$$AbsOrRelPathMaster$$Basename.pstex_t"
23401 \end_layout
23402
23403 \end_inset
23404
23405  in the XFig template above: We can't use the absolute name because the
23406  copier for 
23407 \begin_inset Flex Code
23408 status collapsed
23409
23410 \begin_layout Plain Layout
23411 .pstex_t
23412 \end_layout
23413
23414 \end_inset
23415
23416  files needs the relative name in order to rewrite the file content.
23417 \end_layout
23418
23419 \begin_layout Section
23420 Security discussion
23421 \begin_inset CommandInset label
23422 LatexCommand label
23423 name "sec:Security-discussion"
23424
23425 \end_inset
23426
23427
23428 \end_layout
23429
23430 \begin_layout Standard
23431 The external material feature interfaces with a lot of external programs
23432  and does so automatically, so we have to consider the security implications
23433  of this.
23434  In particular, since you have the option of including your own filenames
23435  and/or parameter strings and those are expanded into a command, it seems
23436  that it would be possible to create a malicious document which executes
23437  arbitrary commands when a user views or prints the document.
23438  This is something we definitely want to avoid.
23439 \end_layout
23440
23441 \begin_layout Standard
23442 However, since the external program commands are specified in the template
23443  configuration file only, there are no security issues if LyX is properly
23444  configured with safe templates only.
23445  This is so because the external programs are invoked with the 
23446 \begin_inset Flex Code
23447 status collapsed
23448
23449 \begin_layout Plain Layout
23450 execvp
23451 \end_layout
23452
23453 \end_inset
23454
23455 -system call rather than the 
23456 \begin_inset Flex Code
23457 status collapsed
23458
23459 \begin_layout Plain Layout
23460 system
23461 \end_layout
23462
23463 \end_inset
23464
23465  system-call, so it's not possible to execute arbitrary commands from the
23466  filename or parameter section via the shell.
23467 \end_layout
23468
23469 \begin_layout Standard
23470 This also implies that you are restricted in what command strings you can
23471  use in the external material templates.
23472  In particular, pipes and redirection are not readily available.
23473  This has to be so if LyX should remain safe.
23474  If you want to use some of the shell features, you should write a safe
23475  script to do this in a controlled manner, and then invoke the script from
23476  the command string.
23477  
23478 \end_layout
23479
23480 \begin_layout Standard
23481 It is possible to design a template that interacts directly with the shell,
23482  but since this would allow a malicious user to execute arbitrary commands
23483  by writing clever filenames and/or parameters, we generally recommend that
23484  you only use safe scripts that work with the 
23485 \begin_inset Flex Code
23486 status collapsed
23487
23488 \begin_layout Plain Layout
23489 execvp
23490 \end_layout
23491
23492 \end_inset
23493
23494  system call in a controlled manner.
23495  Of course, for use in a controlled environment, it can be tempting to just
23496  fall back to use ordinary shell scripts.
23497  If you do so, be aware that you 
23498 \emph on
23499 will
23500 \emph default
23501  provide an easily exploitable security hole in your system.
23502  Of course it stands to reason that such unsafe templates will never be
23503  included in the standard LyX distribution, although we do encourage people
23504  to submit new templates in the open source tradition.
23505  But LyX as shipped from the official distribution channels will never have
23506  unsafe templates.
23507 \end_layout
23508
23509 \begin_layout Standard
23510 Including external material provides a lot of power, and you have to be
23511  careful not to introduce security hazards with this power.
23512  A subtle error in a single line in an innocent looking script can open
23513  the door to huge security problems.
23514  So if you do not fully understand the issues, we recommend that you consult
23515  a knowledgeable security professional or the LyX development team if you
23516  have any questions about whether a given template is safe or not.
23517  And do this before you use it in an uncontrolled environment.
23518 \end_layout
23519
23520 \begin_layout Chapter
23521 \start_of_appendix
23522 List of supported LyX functions to be used in layouts
23523 \begin_inset CommandInset label
23524 LatexCommand label
23525 name "chap:List-of-functions"
23526
23527 \end_inset
23528
23529
23530 \end_layout
23531
23532 \begin_layout Standard
23533 \align center
23534 \begin_inset Tabular
23535 <lyxtabular version="3" rows="11" columns="8">
23536 <features rotate="0" tabularvalignment="middle">
23537 <column alignment="left" valignment="top">
23538 <column alignment="left" valignment="top">
23539 <column alignment="left" valignment="top">
23540 <column alignment="left" valignment="top">
23541 <column alignment="left" valignment="top">
23542 <column alignment="left" valignment="top">
23543 <column alignment="left" valignment="top">
23544 <column alignment="left" valignment="top">
23545 <row>
23546 <cell alignment="left" valignment="top" usebox="none">
23547 \begin_inset Text
23548
23549 \begin_layout Plain Layout
23550 accents
23551 \end_layout
23552
23553 \end_inset
23554 </cell>
23555 <cell alignment="left" valignment="top" usebox="none">
23556 \begin_inset Text
23557
23558 \begin_layout Plain Layout
23559 booktabs
23560 \end_layout
23561
23562 \end_inset
23563 </cell>
23564 <cell alignment="left" valignment="top" usebox="none">
23565 \begin_inset Text
23566
23567 \begin_layout Plain Layout
23568 feyn
23569 \end_layout
23570
23571 \end_inset
23572 </cell>
23573 <cell alignment="left" valignment="top" usebox="none">
23574 \begin_inset Text
23575
23576 \begin_layout Plain Layout
23577 listings
23578 \end_layout
23579
23580 \end_inset
23581 </cell>
23582 <cell alignment="center" valignment="top" usebox="none">
23583 \begin_inset Text
23584
23585 \begin_layout Plain Layout
23586 natbib
23587 \end_layout
23588
23589 \end_inset
23590 </cell>
23591 <cell alignment="center" valignment="top" usebox="none">
23592 \begin_inset Text
23593
23594 \begin_layout Plain Layout
23595 rotfloat
23596 \end_layout
23597
23598 \end_inset
23599 </cell>
23600 <cell alignment="center" valignment="top" usebox="none">
23601 \begin_inset Text
23602
23603 \begin_layout Plain Layout
23604 tfrupee
23605 \end_layout
23606
23607 \end_inset
23608 </cell>
23609 <cell alignment="center" valignment="top" usebox="none">
23610 \begin_inset Text
23611
23612 \begin_layout Plain Layout
23613 wasysym
23614 \end_layout
23615
23616 \end_inset
23617 </cell>
23618 </row>
23619 <row>
23620 <cell alignment="left" valignment="top" usebox="none">
23621 \begin_inset Text
23622
23623 \begin_layout Plain Layout
23624 amsbsy
23625 \end_layout
23626
23627 \end_inset
23628 </cell>
23629 <cell alignment="left" valignment="top" usebox="none">
23630 \begin_inset Text
23631
23632 \begin_layout Plain Layout
23633 calc
23634 \end_layout
23635
23636 \end_inset
23637 </cell>
23638 <cell alignment="left" valignment="top" usebox="none">
23639 \begin_inset Text
23640
23641 \begin_layout Plain Layout
23642 fixltx2e
23643 \end_layout
23644
23645 \end_inset
23646 </cell>
23647 <cell alignment="left" valignment="top" usebox="none">
23648 \begin_inset Text
23649
23650 \begin_layout Plain Layout
23651 longtable
23652 \end_layout
23653
23654 \end_inset
23655 </cell>
23656 <cell alignment="center" valignment="top" usebox="none">
23657 \begin_inset Text
23658
23659 \begin_layout Plain Layout
23660 nomencl
23661 \end_layout
23662
23663 \end_inset
23664 </cell>
23665 <cell alignment="center" valignment="top" usebox="none">
23666 \begin_inset Text
23667
23668 \begin_layout Plain Layout
23669 rsphrase
23670 \end_layout
23671
23672 \end_inset
23673 </cell>
23674 <cell alignment="center" valignment="top" usebox="none">
23675 \begin_inset Text
23676
23677 \begin_layout Plain Layout
23678 tipa
23679 \end_layout
23680
23681 \end_inset
23682 </cell>
23683 <cell alignment="center" valignment="top" usebox="none">
23684 \begin_inset Text
23685
23686 \begin_layout Plain Layout
23687 wrapfig
23688 \end_layout
23689
23690 \end_inset
23691 </cell>
23692 </row>
23693 <row>
23694 <cell alignment="left" valignment="top" usebox="none">
23695 \begin_inset Text
23696
23697 \begin_layout Plain Layout
23698 amscd
23699 \end_layout
23700
23701 \end_inset
23702 </cell>
23703 <cell alignment="left" valignment="top" usebox="none">
23704 \begin_inset Text
23705
23706 \begin_layout Plain Layout
23707 CJK
23708 \end_layout
23709
23710 \end_inset
23711 </cell>
23712 <cell alignment="left" valignment="top" usebox="none">
23713 \begin_inset Text
23714
23715 \begin_layout Plain Layout
23716 float
23717 \end_layout
23718
23719 \end_inset
23720 </cell>
23721 <cell alignment="left" valignment="top" usebox="none">
23722 \begin_inset Text
23723
23724 \begin_layout Plain Layout
23725 lyxskak
23726 \end_layout
23727
23728 \end_inset
23729 </cell>
23730 <cell alignment="center" valignment="top" usebox="none">
23731 \begin_inset Text
23732
23733 \begin_layout Plain Layout
23734 pdfcolmk
23735 \end_layout
23736
23737 \end_inset
23738 </cell>
23739 <cell alignment="center" valignment="top" usebox="none">
23740 \begin_inset Text
23741
23742 \begin_layout Plain Layout
23743 setspace
23744 \end_layout
23745
23746 \end_inset
23747 </cell>
23748 <cell alignment="center" valignment="top" usebox="none">
23749 \begin_inset Text
23750
23751 \begin_layout Plain Layout
23752 tipx
23753 \end_layout
23754
23755 \end_inset
23756 </cell>
23757 <cell alignment="center" valignment="top" usebox="none">
23758 \begin_inset Text
23759
23760 \begin_layout Plain Layout
23761 xargs
23762 \end_layout
23763
23764 \end_inset
23765 </cell>
23766 </row>
23767 <row>
23768 <cell alignment="left" valignment="top" usebox="none">
23769 \begin_inset Text
23770
23771 \begin_layout Plain Layout
23772 amsmath
23773 \end_layout
23774
23775 \end_inset
23776 </cell>
23777 <cell alignment="left" valignment="top" usebox="none">
23778 \begin_inset Text
23779
23780 \begin_layout Plain Layout
23781 color
23782 \end_layout
23783
23784 \end_inset
23785 </cell>
23786 <cell alignment="left" valignment="top" usebox="none">
23787 \begin_inset Text
23788
23789 \begin_layout Plain Layout
23790 framed
23791 \end_layout
23792
23793 \end_inset
23794 </cell>
23795 <cell alignment="left" valignment="top" usebox="none">
23796 \begin_inset Text
23797
23798 \begin_layout Plain Layout
23799 makeidx
23800 \end_layout
23801
23802 \end_inset
23803 </cell>
23804 <cell alignment="center" valignment="top" usebox="none">
23805 \begin_inset Text
23806
23807 \begin_layout Plain Layout
23808 pdfpages
23809 \end_layout
23810
23811 \end_inset
23812 </cell>
23813 <cell alignment="center" valignment="top" usebox="none">
23814 \begin_inset Text
23815
23816 \begin_layout Plain Layout
23817 shapepar
23818 \end_layout
23819
23820 \end_inset
23821 </cell>
23822 <cell alignment="center" valignment="top" usebox="none">
23823 \begin_inset Text
23824
23825 \begin_layout Plain Layout
23826 tone
23827 \end_layout
23828
23829 \end_inset
23830 </cell>
23831 <cell alignment="center" valignment="top" usebox="none">
23832 \begin_inset Text
23833
23834 \begin_layout Plain Layout
23835 xcolor
23836 \end_layout
23837
23838 \end_inset
23839 </cell>
23840 </row>
23841 <row>
23842 <cell alignment="left" valignment="top" usebox="none">
23843 \begin_inset Text
23844
23845 \begin_layout Plain Layout
23846 amssymb
23847 \end_layout
23848
23849 \end_inset
23850 </cell>
23851 <cell alignment="left" valignment="top" usebox="none">
23852 \begin_inset Text
23853
23854 \begin_layout Plain Layout
23855 covington
23856 \end_layout
23857
23858 \end_inset
23859 </cell>
23860 <cell alignment="left" valignment="top" usebox="none">
23861 \begin_inset Text
23862
23863 \begin_layout Plain Layout
23864 graphicx
23865 \end_layout
23866
23867 \end_inset
23868 </cell>
23869 <cell alignment="left" valignment="top" usebox="none">
23870 \begin_inset Text
23871
23872 \begin_layout Plain Layout
23873 marvosym
23874 \end_layout
23875
23876 \end_inset
23877 </cell>
23878 <cell alignment="center" valignment="top" usebox="none">
23879 \begin_inset Text
23880
23881 \begin_layout Plain Layout
23882 pifont
23883 \end_layout
23884
23885 \end_inset
23886 </cell>
23887 <cell alignment="center" valignment="top" usebox="none">
23888 \begin_inset Text
23889
23890 \begin_layout Plain Layout
23891 slashed
23892 \end_layout
23893
23894 \end_inset
23895 </cell>
23896 <cell alignment="center" valignment="top" usebox="none">
23897 \begin_inset Text
23898
23899 \begin_layout Plain Layout
23900 txfonts
23901 \end_layout
23902
23903 \end_inset
23904 </cell>
23905 <cell alignment="center" valignment="top" usebox="none">
23906 \begin_inset Text
23907
23908 \begin_layout Plain Layout
23909 xy
23910 \end_layout
23911
23912 \end_inset
23913 </cell>
23914 </row>
23915 <row>
23916 <cell alignment="left" valignment="top" usebox="none">
23917 \begin_inset Text
23918
23919 \begin_layout Plain Layout
23920 amstext
23921 \end_layout
23922
23923 \end_inset
23924 </cell>
23925 <cell alignment="left" valignment="top" usebox="none">
23926 \begin_inset Text
23927
23928 \begin_layout Plain Layout
23929 csquotes
23930 \end_layout
23931
23932 \end_inset
23933 </cell>
23934 <cell alignment="left" valignment="top" usebox="none">
23935 \begin_inset Text
23936
23937 \begin_layout Plain Layout
23938 hhline
23939 \end_layout
23940
23941 \end_inset
23942 </cell>
23943 <cell alignment="left" valignment="top" usebox="none">
23944 \begin_inset Text
23945
23946 \begin_layout Plain Layout
23947 mathdesign
23948 \end_layout
23949
23950 \end_inset
23951 </cell>
23952 <cell alignment="center" valignment="top" usebox="none">
23953 \begin_inset Text
23954
23955 \begin_layout Plain Layout
23956 pmboxdraw
23957 \end_layout
23958
23959 \end_inset
23960 </cell>
23961 <cell alignment="center" valignment="top" usebox="none">
23962 \begin_inset Text
23963
23964 \begin_layout Plain Layout
23965 soul
23966 \end_layout
23967
23968 \end_inset
23969 </cell>
23970 <cell alignment="center" valignment="top" usebox="none">
23971 \begin_inset Text
23972
23973 \begin_layout Plain Layout
23974 ulem
23975 \end_layout
23976
23977 \end_inset
23978 </cell>
23979 <cell alignment="center" valignment="top" usebox="none">
23980 \begin_inset Text
23981
23982 \begin_layout Plain Layout
23983 yhmath
23984 \end_layout
23985
23986 \end_inset
23987 </cell>
23988 </row>
23989 <row>
23990 <cell alignment="left" valignment="top" usebox="none">
23991 \begin_inset Text
23992
23993 \begin_layout Plain Layout
23994 amsthm
23995 \end_layout
23996
23997 \end_inset
23998 </cell>
23999 <cell alignment="left" valignment="top" usebox="none">
24000 \begin_inset Text
24001
24002 \begin_layout Plain Layout
24003 dvipost
24004 \end_layout
24005
24006 \end_inset
24007 </cell>
24008 <cell alignment="left" valignment="top" usebox="none">
24009 \begin_inset Text
24010
24011 \begin_layout Plain Layout
24012 hyperref
24013 \end_layout
24014
24015 \end_inset
24016 </cell>
24017 <cell alignment="left" valignment="top" usebox="none">
24018 \begin_inset Text
24019
24020 \begin_layout Plain Layout
24021 mathdots
24022 \end_layout
24023
24024 \end_inset
24025 </cell>
24026 <cell alignment="center" valignment="top" usebox="none">
24027 \begin_inset Text
24028
24029 \begin_layout Plain Layout
24030 polyglossia
24031 \end_layout
24032
24033 \end_inset
24034 </cell>
24035 <cell alignment="center" valignment="top" usebox="none">
24036 \begin_inset Text
24037
24038 \begin_layout Plain Layout
24039 splitidx
24040 \end_layout
24041
24042 \end_inset
24043 </cell>
24044 <cell alignment="center" valignment="top" usebox="none">
24045 \begin_inset Text
24046
24047 \begin_layout Plain Layout
24048 undertilde
24049 \end_layout
24050
24051 \end_inset
24052 </cell>
24053 <cell alignment="center" valignment="top" usebox="none">
24054 \begin_inset Text
24055
24056 \begin_layout Plain Layout
24057
24058 \end_layout
24059
24060 \end_inset
24061 </cell>
24062 </row>
24063 <row>
24064 <cell alignment="left" valignment="top" usebox="none">
24065 \begin_inset Text
24066
24067 \begin_layout Plain Layout
24068 array
24069 \end_layout
24070
24071 \end_inset
24072 </cell>
24073 <cell alignment="left" valignment="top" usebox="none">
24074 \begin_inset Text
24075
24076 \begin_layout Plain Layout
24077 endnotes
24078 \end_layout
24079
24080 \end_inset
24081 </cell>
24082 <cell alignment="left" valignment="top" usebox="none">
24083 \begin_inset Text
24084
24085 \begin_layout Plain Layout
24086 ifsym
24087 \end_layout
24088
24089 \end_inset
24090 </cell>
24091 <cell alignment="left" valignment="top" usebox="none">
24092 \begin_inset Text
24093
24094 \begin_layout Plain Layout
24095 mathrsfs
24096 \end_layout
24097
24098 \end_inset
24099 </cell>
24100 <cell alignment="center" valignment="top" usebox="none">
24101 \begin_inset Text
24102
24103 \begin_layout Plain Layout
24104 prettyref
24105 \end_layout
24106
24107 \end_inset
24108 </cell>
24109 <cell alignment="center" valignment="top" usebox="none">
24110 \begin_inset Text
24111
24112 \begin_layout Plain Layout
24113 subfig
24114 \end_layout
24115
24116 \end_inset
24117 </cell>
24118 <cell alignment="center" valignment="top" usebox="none">
24119 \begin_inset Text
24120
24121 \begin_layout Plain Layout
24122 units
24123 \end_layout
24124
24125 \end_inset
24126 </cell>
24127 <cell alignment="center" valignment="top" usebox="none">
24128 \begin_inset Text
24129
24130 \begin_layout Plain Layout
24131
24132 \end_layout
24133
24134 \end_inset
24135 </cell>
24136 </row>
24137 <row>
24138 <cell alignment="left" valignment="top" usebox="none">
24139 \begin_inset Text
24140
24141 \begin_layout Plain Layout
24142 ascii
24143 \end_layout
24144
24145 \end_inset
24146 </cell>
24147 <cell alignment="left" valignment="top" usebox="none">
24148 \begin_inset Text
24149
24150 \begin_layout Plain Layout
24151 enumitem
24152 \end_layout
24153
24154 \end_inset
24155 </cell>
24156 <cell alignment="left" valignment="top" usebox="none">
24157 \begin_inset Text
24158
24159 \begin_layout Plain Layout
24160 ifthen
24161 \end_layout
24162
24163 \end_inset
24164 </cell>
24165 <cell alignment="left" valignment="top" usebox="none">
24166 \begin_inset Text
24167
24168 \begin_layout Plain Layout
24169 mhchem
24170 \end_layout
24171
24172 \end_inset
24173 </cell>
24174 <cell alignment="center" valignment="top" usebox="none">
24175 \begin_inset Text
24176
24177 \begin_layout Plain Layout
24178 pxfonts
24179 \end_layout
24180
24181 \end_inset
24182 </cell>
24183 <cell alignment="center" valignment="top" usebox="none">
24184 \begin_inset Text
24185
24186 \begin_layout Plain Layout
24187 subscript
24188 \end_layout
24189
24190 \end_inset
24191 </cell>
24192 <cell alignment="center" valignment="top" usebox="none">
24193 \begin_inset Text
24194
24195 \begin_layout Plain Layout
24196 url
24197 \end_layout
24198
24199 \end_inset
24200 </cell>
24201 <cell alignment="center" valignment="top" usebox="none">
24202 \begin_inset Text
24203
24204 \begin_layout Plain Layout
24205
24206 \end_layout
24207
24208 \end_inset
24209 </cell>
24210 </row>
24211 <row>
24212 <cell alignment="left" valignment="top" usebox="none">
24213 \begin_inset Text
24214
24215 \begin_layout Plain Layout
24216 bbding
24217 \end_layout
24218
24219 \end_inset
24220 </cell>
24221 <cell alignment="left" valignment="top" usebox="none">
24222 \begin_inset Text
24223
24224 \begin_layout Plain Layout
24225 esint
24226 \end_layout
24227
24228 \end_inset
24229 </cell>
24230 <cell alignment="left" valignment="top" usebox="none">
24231 \begin_inset Text
24232
24233 \begin_layout Plain Layout
24234 jurabib
24235 \end_layout
24236
24237 \end_inset
24238 </cell>
24239 <cell alignment="left" valignment="top" usebox="none">
24240 \begin_inset Text
24241
24242 \begin_layout Plain Layout
24243 multicol
24244 \end_layout
24245
24246 \end_inset
24247 </cell>
24248 <cell alignment="center" valignment="top" usebox="none">
24249 \begin_inset Text
24250
24251 \begin_layout Plain Layout
24252 refstyle
24253 \end_layout
24254
24255 \end_inset
24256 </cell>
24257 <cell alignment="center" valignment="top" usebox="none">
24258 \begin_inset Text
24259
24260 \begin_layout Plain Layout
24261 textcomp
24262 \end_layout
24263
24264 \end_inset
24265 </cell>
24266 <cell alignment="center" valignment="top" usebox="none">
24267 \begin_inset Text
24268
24269 \begin_layout Plain Layout
24270 varioref
24271 \end_layout
24272
24273 \end_inset
24274 </cell>
24275 <cell alignment="center" valignment="top" usebox="none">
24276 \begin_inset Text
24277
24278 \begin_layout Plain Layout
24279
24280 \end_layout
24281
24282 \end_inset
24283 </cell>
24284 </row>
24285 <row>
24286 <cell alignment="center" valignment="top" usebox="none">
24287 \begin_inset Text
24288
24289 \begin_layout Plain Layout
24290 bm
24291 \end_layout
24292
24293 \end_inset
24294 </cell>
24295 <cell alignment="center" valignment="top" usebox="none">
24296 \begin_inset Text
24297
24298 \begin_layout Plain Layout
24299 fancybox
24300 \end_layout
24301
24302 \end_inset
24303 </cell>
24304 <cell alignment="center" valignment="top" usebox="none">
24305 \begin_inset Text
24306
24307 \begin_layout Plain Layout
24308 latexsym
24309 \end_layout
24310
24311 \end_inset
24312 </cell>
24313 <cell alignment="center" valignment="top" usebox="none">
24314 \begin_inset Text
24315
24316 \begin_layout Plain Layout
24317 multirow
24318 \end_layout
24319
24320 \end_inset
24321 </cell>
24322 <cell alignment="center" valignment="top" usebox="none">
24323 \begin_inset Text
24324
24325 \begin_layout Plain Layout
24326 rotating
24327 \end_layout
24328
24329 \end_inset
24330 </cell>
24331 <cell alignment="center" valignment="top" usebox="none">
24332 \begin_inset Text
24333
24334 \begin_layout Plain Layout
24335 textgreek
24336 \end_layout
24337
24338 \end_inset
24339 </cell>
24340 <cell alignment="center" valignment="top" usebox="none">
24341 \begin_inset Text
24342
24343 \begin_layout Plain Layout
24344 verbatim
24345 \end_layout
24346
24347 \end_inset
24348 </cell>
24349 <cell alignment="center" valignment="top" usebox="none">
24350 \begin_inset Text
24351
24352 \begin_layout Plain Layout
24353
24354 \end_layout
24355
24356 \end_inset
24357 </cell>
24358 </row>
24359 </lyxtabular>
24360
24361 \end_inset
24362
24363
24364 \end_layout
24365
24366 \begin_layout Chapter
24367 Names of available colors to be used in layouts
24368 \begin_inset CommandInset label
24369 LatexCommand label
24370 name "chap:Names-of-colors"
24371
24372 \end_inset
24373
24374
24375 \end_layout
24376
24377 \begin_layout Standard
24378 The colors listed here are the standard colors and the those that you can
24379  adjust in the LyX preferences.
24380 \end_layout
24381
24382 \begin_layout Description
24383 none
24384 \family roman
24385 \series medium
24386 \shape up
24387 \size normal
24388 \emph off
24389 \bar no
24390 \strikeout off
24391 \uuline off
24392 \uwave off
24393 \noun off
24394 \color none
24395  No particular color -- clear or default
24396 \end_layout
24397
24398 \begin_layout Description
24399 black
24400 \end_layout
24401
24402 \begin_layout Description
24403 white
24404 \end_layout
24405
24406 \begin_layout Description
24407 red
24408 \end_layout
24409
24410 \begin_layout Description
24411 green
24412 \end_layout
24413
24414 \begin_layout Description
24415 blue
24416 \end_layout
24417
24418 \begin_layout Description
24419 cyan
24420 \end_layout
24421
24422 \begin_layout Description
24423 magenta
24424 \end_layout
24425
24426 \begin_layout Description
24427 yellow
24428 \end_layout
24429
24430 \begin_layout Description
24431 added_space Added space marker color
24432 \end_layout
24433
24434 \begin_layout Description
24435 addedtext Added text color
24436 \end_layout
24437
24438 \begin_layout Description
24439 appendix Appendix marker color
24440 \end_layout
24441
24442 \begin_layout Description
24443 background Background color
24444 \end_layout
24445
24446 \begin_layout Description
24447 bottomarea Bottom area color
24448 \end_layout
24449
24450 \begin_layout Description
24451 branchlabel Label color for branches
24452 \end_layout
24453
24454 \begin_layout Description
24455 buttonbg Color used for bottom background
24456 \end_layout
24457
24458 \begin_layout Description
24459 buttonhoverbg Color used for button background under focus
24460 \end_layout
24461
24462 \begin_layout Description
24463 buttonframe Color for inset button frames
24464 \end_layout
24465
24466 \begin_layout Description
24467 changebar Changebar color
24468 \end_layout
24469
24470 \begin_layout Description
24471 changedtextauthor1 Changed text color author 1
24472 \end_layout
24473
24474 \begin_layout Description
24475 changedtextauthor2 Changed text color author 2
24476 \end_layout
24477
24478 \begin_layout Description
24479 changedtextauthor3 Changed text color author 3
24480 \end_layout
24481
24482 \begin_layout Description
24483 changedtextauthor4 Changed text color author 4
24484 \end_layout
24485
24486 \begin_layout Description
24487 changedtextauthor5 Changed text color author 5
24488 \end_layout
24489
24490 \begin_layout Description
24491 collapsable_inset_frame Collapsable insets framecolor
24492 \end_layout
24493
24494 \begin_layout Description
24495 collapsable_inset_text Collapsable insets text color
24496 \end_layout
24497
24498 \begin_layout Description
24499 command Text color for command insets
24500 \end_layout
24501
24502 \begin_layout Description
24503 commandbg Background color for command insets
24504 \end_layout
24505
24506 \begin_layout Description
24507 commandframe Frame color for command insets
24508 \end_layout
24509
24510 \begin_layout Description
24511 comment color for comments
24512 \end_layout
24513
24514 \begin_layout Description
24515 commentbg Background color of comments
24516 \end_layout
24517
24518 \begin_layout Description
24519 cursor Cursor color
24520 \end_layout
24521
24522 \begin_layout Description
24523 deletedtext Deleted text color
24524 \end_layout
24525
24526 \begin_layout Description
24527 deletedtextmodifier Deleted text modifying color
24528 \end_layout
24529
24530 \begin_layout Description
24531 depthbar Color for the depth bars in the margin
24532 \end_layout
24533
24534 \begin_layout Description
24535 eolmarker End of line marker color
24536 \end_layout
24537
24538 \begin_layout Description
24539 error Color of the LaTeX error box
24540 \end_layout
24541
24542 \begin_layout Description
24543 footlabel Label color for footnotes
24544 \end_layout
24545
24546 \begin_layout Description
24547 graphicsbg Graphics inset background color
24548 \end_layout
24549
24550 \begin_layout Description
24551 greyedout Label color for greyedout insets
24552 \end_layout
24553
24554 \begin_layout Description
24555 greyedoutbg Background color of greyedout inset
24556 \end_layout
24557
24558 \begin_layout Description
24559 greyedouttext Color for greyedout inset text
24560 \end_layout
24561
24562 \begin_layout Description
24563 indexlabel Label color for index insets
24564 \end_layout
24565
24566 \begin_layout Description
24567 ignore The color is ignored
24568 \end_layout
24569
24570 \begin_layout Description
24571 inherit The color is inherited
24572 \end_layout
24573
24574 \begin_layout Description
24575 inlinecompletion Inline completion color
24576 \end_layout
24577
24578 \begin_layout Description
24579 insetbg Inset marker background color
24580 \end_layout
24581
24582 \begin_layout Description
24583 insetframe Inset marker frame color
24584 \end_layout
24585
24586 \begin_layout Description
24587 language Color for marking foreign language words
24588 \end_layout
24589
24590 \begin_layout Description
24591 latex Text color in LaTeX mode
24592 \end_layout
24593
24594 \begin_layout Description
24595 listingsbg Background color of listings inset
24596 \end_layout
24597
24598 \begin_layout Description
24599 marginlabel Label color for margin notes
24600 \end_layout
24601
24602 \begin_layout Description
24603 math Math inset text color
24604 \end_layout
24605
24606 \begin_layout Description
24607 mathbg Math inset background color
24608 \end_layout
24609
24610 \begin_layout Description
24611 mathcorners Math inset frame color not under focus
24612 \end_layout
24613
24614 \begin_layout Description
24615 mathframe Math inset frame color under focus
24616 \end_layout
24617
24618 \begin_layout Description
24619 mathline Math line color
24620 \end_layout
24621
24622 \begin_layout Description
24623 mathmacrobg Macro math inset background color
24624 \end_layout
24625
24626 \begin_layout Description
24627 mathmacroblend Macro math blended color
24628 \end_layout
24629
24630 \begin_layout Description
24631 mathmacroframe Macro math frame color
24632 \end_layout
24633
24634 \begin_layout Description
24635 mathmacrohoverbg Macro math inset background color hovered
24636 \end_layout
24637
24638 \begin_layout Description
24639 mathmacrolabel Macro math label color
24640 \end_layout
24641
24642 \begin_layout Description
24643 mathmacronewarg Macro template color for new parameters
24644 \end_layout
24645
24646 \begin_layout Description
24647 mathmacrooldarg Macro template color for old parameters
24648 \end_layout
24649
24650 \begin_layout Description
24651 newpage New page color
24652 \end_layout
24653
24654 \begin_layout Description
24655 nonunique_inlinecompletion Inline completion color for the non-unique part
24656 \end_layout
24657
24658 \begin_layout Description
24659 notebg Background color of notes
24660 \end_layout
24661
24662 \begin_layout Description
24663 notelabel Label color for notes
24664 \end_layout
24665
24666 \begin_layout Description
24667 pagebreak Page break/line break color
24668 \end_layout
24669
24670 \begin_layout Description
24671 paragraphmarker Color used for the pilcrow sign to mark the end of a paragraph
24672 \end_layout
24673
24674 \begin_layout Description
24675 phantomtext Text color for phantom insets
24676 \end_layout
24677
24678 \begin_layout Description
24679 preview The color used for previews
24680 \end_layout
24681
24682 \begin_layout Description
24683 previewframe Preview frame color
24684 \end_layout
24685
24686 \begin_layout Description
24687 regexpframe Color for regexp frame
24688 \end_layout
24689
24690 \begin_layout Description
24691 selection Background color of selected text
24692 \end_layout
24693
24694 \begin_layout Description
24695 selectiontext Foreground color of selected text
24696 \end_layout
24697
24698 \begin_layout Description
24699 shadedbg Background color of shaded box
24700 \end_layout
24701
24702 \begin_layout Description
24703 special Special chars text color
24704 \end_layout
24705
24706 \begin_layout Description
24707 tabularline Table line color
24708 \end_layout
24709
24710 \begin_layout Description
24711 tabularonoffline Table line color
24712 \end_layout
24713
24714 \begin_layout Description
24715 urllabel Label color for URL insets
24716 \end_layout
24717
24718 \begin_layout Description
24719 urltext Color for URL inset text
24720 \end_layout
24721
24722 \end_body
24723 \end_document