1 #LyX 2.1 created this file. For more info see http://www.lyx.org/
7 % DO NOT ALTER THIS PREAMBLE!!!
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
16 \usepackage{ifpdf} % part of the hyperref bundle
17 \ifpdf % if pdflatex is used
19 % set fonts for nicer pdf view
20 \IfFileExists{lmodern.sty}
21 {\usepackage{lmodern}}{}
23 \fi % end if pdflatex is used
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{%
30 \pdfbookmark[1]{\contentsname}{}
34 \options fleqn,bibliography=totoc,index=totoc,BCOR7.5mm,titlepage,captions=tableheading
35 \use_default_options false
39 \maintain_unincluded_children false
42 InsetLayout Flex:MenuItem
51 \newcommand*{\menuitem}[1]{{\sffamily #1}}
54 # In case we need to do with sans...
55 #InsetLayout CharStyle:Code
60 #\renewcommand{\code}[1]{{\sffamily #1}}
65 \language_package default
70 \font_typewriter default
72 \font_default_family default
73 \use_non_tex_fonts false
79 \default_output_format default
81 \bibtex_command default
82 \index_command default
86 \pdf_title "LyX Configuration Manual"
87 \pdf_author "LyX Team"
88 \pdf_subject "LyX-documentation Customization"
89 \pdf_keywords "LyX, documentation, customization"
91 \pdf_bookmarksnumbered true
92 \pdf_bookmarksopen true
93 \pdf_bookmarksopenlevel 1
98 \pdf_pdfusetitle false
99 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue,pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
102 \use_package amsmath 0
103 \use_package amssymb 0
104 \use_package cancel 0
106 \use_package mathdots 1
107 \use_package mathtools 0
108 \use_package mhchem 0
109 \use_package stackrel 0
110 \use_package stmaryrd 0
111 \use_package undertilde 0
113 \cite_engine_type numerical
117 \paperorientation portrait
132 \paragraph_separation indent
133 \paragraph_indentation default
134 \quotes_language english
137 \paperpagestyle headings
138 \tracking_changes true
139 \output_changes false
143 \author -712698321 "Jürgen Spitzmüller"
144 \author -195340706 "Georg Baum"
146 \author 155139281 "Jrgen Spitzmller"
147 \author 1082167584 "Kayvan Sylvan" kayvan@sylvan.com
148 \author 1414654397 "Richard Heck"
149 \author 2090807402 "usti"
155 Customizing LyX: Features for the Advanced User
163 \begin_layout Plain Layout
165 If you have comments or error corrections, please send them to the LyX Documenta
167 \begin_inset CommandInset href
169 target "lyx-docs@lists.lyx.org"
176 \begin_inset Quotes eld
180 \begin_inset Quotes erd
183 in the subject header, and please cc the current maintainer of this file,
184 Richard Heck <rgheck@comcast.net>.
190 \begin_inset Newline newline
194 \begin_inset Newline newline
198 \change_deleted -712698321 1357054389
200 \change_inserted -712698321 1357054389
206 \begin_layout Standard
207 \begin_inset CommandInset toc
208 LatexCommand tableofcontents
215 \begin_layout Standard
216 \begin_inset Note Note
219 \begin_layout Plain Layout
220 Please use change tracking when modifying this document.
221 This makes it easier for our translators to recognize things that have
222 been changed, and it helps the maintainer keep up-to-date with what's been
231 \begin_layout Chapter
235 \begin_layout Standard
236 This manual covers the customization features present in LyX.
237 In it, we discuss issues like keyboard shortcuts, screen previewing options,
238 printer options, sending commands to LyX via the LyX Server, internationalizati
239 on, installing new LaTeX classes and LyX layouts, etc.
240 We can't possibly hope to touch on everything you can change—our developers
241 add new features faster than we can document them—but we will explain the
242 most common customizations and hopefully point you in the right direction
243 for some of the more obscure ones.
246 \begin_layout Standard
247 \begin_inset Branch OutDated
250 \begin_layout Standard
251 Information from previous versions of this document that now seems to be
252 outdated is contained in the OutDated branch of this document.
253 By default, this information will not appear in the LaTeX output.
261 \begin_layout Chapter
262 LyX configuration files
265 \begin_layout Standard
266 This chapter aims to help you to find your way through the LyX configuration
268 Before continuing to read this chapter, you should find out where your
269 LyX library and user directories are by using
270 \begin_inset Flex MenuItem
273 \begin_layout Plain Layout
274 Help\SpecialChar \menuseparator
285 The library directory is the place where LyX places its system-wide configurati
286 on files; the user directory is where you can place your modified versions.
287 We will call the former
288 \begin_inset Flex Code
291 \begin_layout Plain Layout
298 \begin_inset Flex MenuItem
301 \begin_layout Plain Layout
307 in the remainder of this document.
311 \begin_layout Section
313 \begin_inset Flex Code
316 \begin_layout Plain Layout
325 \begin_layout Standard
326 \begin_inset Flex Code
329 \begin_layout Plain Layout
335 and its sub-directories contain a number of files and that can be used
336 to customize LyX's behavior.
337 You can change many of these files from within LyX itself through the
338 \begin_inset Flex MenuItem
341 \begin_layout Plain Layout
342 Tools\SpecialChar \menuseparator
349 Most customization that you will want to do in LyX is possible through
351 However, many other inner aspects of LyX can be customized by modifying
353 \begin_inset Flex Code
356 \begin_layout Plain Layout
363 These files fall in different categories, described in the following subsection
367 \begin_layout Subsection
368 Automatically generated files
371 \begin_layout Standard
372 The files, which are to be found in
373 \begin_inset Flex MenuItem
376 \begin_layout Plain Layout
382 , are generated when you configure LyX.
383 They contain various default values that are guessed by inspection.
384 In general, it is not a good idea to modify them, since they might be overwritt
388 \begin_layout Labeling
389 \labelwidthstring 00.00.0000
390 \begin_inset Flex Code
393 \begin_layout Plain Layout
399 contains defaults for various commands.
402 \begin_layout Labeling
403 \labelwidthstring 00.00.0000
404 \begin_inset Flex Code
407 \begin_layout Plain Layout
413 contains the list of packages that have been recognized by LyX.
414 It is currently unused by the LyX program itself, but the information extracted
415 , and more, is made available with
416 \begin_inset Flex MenuItem
419 \begin_layout Plain Layout
420 Help\SpecialChar \menuseparator
433 \begin_layout Labeling
434 \labelwidthstring 00.00.0000
435 \begin_inset Flex Code
438 \begin_layout Plain Layout
444 the list of text classes that have been found in your
445 \begin_inset Flex Code
448 \begin_layout Plain Layout
454 directories, along with the associated LaTeX document class and their descripti
458 \begin_layout Labeling
459 \labelwidthstring 00.00.0000
460 \begin_inset Flex Code
463 \begin_layout Plain Layout
469 the list of layout modules found in your
470 \begin_inset Flex Code
473 \begin_layout Plain Layout
482 \begin_layout Labeling
483 \labelwidthstring 00.00.0000
484 \begin_inset Flex Code
487 \begin_layout Plain Layout
493 lists of various sorts of LaTeX-related files found on your system
496 \begin_layout Labeling
497 \labelwidthstring 00.00.0000
498 \begin_inset Flex Code
501 \begin_layout Plain Layout
507 is automatically generated during configuration from the file
508 \begin_inset Flex Code
511 \begin_layout Plain Layout
518 It contains information on your LaTeX configuration.
521 \begin_layout Subsection
525 \begin_layout Standard
526 These directories are duplicated between
527 \begin_inset Flex Code
530 \begin_layout Plain Layout
537 \begin_inset Flex Code
540 \begin_layout Plain Layout
547 If a particular files exists in both places, the one in
548 \begin_inset Flex Code
551 \begin_layout Plain Layout
560 \begin_layout Labeling
561 \labelwidthstring 00.00.0000
562 \begin_inset Flex Code
565 \begin_layout Plain Layout
571 this directory contains files with the extension
572 \begin_inset Flex Code
575 \begin_layout Plain Layout
581 that define the keybindings used in LyX.
582 If there exists an internationalized version of the bind file named
583 \begin_inset Flex Code
586 \begin_layout Plain Layout
592 , that will be used first.
595 \begin_layout Labeling
596 \labelwidthstring 00.00.0000
597 \begin_inset Flex Code
600 \begin_layout Plain Layout
606 contains graphics files that can be included in documents.
610 \begin_layout Labeling
611 \labelwidthstring 00.00.0000
612 \begin_inset Flex Code
615 \begin_layout Plain Layout
621 contains LyX documentation files (including the one you are currently reading).
623 \begin_inset Flex Code
626 \begin_layout Plain Layout
632 deserves special attention, as noted above.
633 The internationalized help docs are in subdirectories
634 \begin_inset Flex Code
637 \begin_layout Plain Layout
644 \begin_inset Quotes eld
648 \begin_inset Quotes erd
651 is the ISO language code.
657 \begin_inset CommandInset ref
659 reference "cha:Internationalizing-LyX"
666 \begin_layout Labeling
667 \labelwidthstring 00.00.0000
668 \begin_inset Flex Code
671 \begin_layout Plain Layout
677 contains example files that explain how to use some features.
678 In the file browser, press the
679 \begin_inset Flex MenuItem
682 \begin_layout Plain Layout
691 \begin_layout Labeling
692 \labelwidthstring 00.00.0000
693 \begin_inset Flex Code
696 \begin_layout Plain Layout
702 contains image files that are used by the
703 \begin_inset Flex MenuItem
706 \begin_layout Plain Layout
713 In addition, it also contains the individual icons used in the toolbar
714 and the banners that can be shown when LyX is launched.
717 \begin_layout Labeling
718 \labelwidthstring 00.00.0000
719 \begin_inset Flex Code
722 \begin_layout Plain Layout
728 contains keyboard keymapping files.
734 \begin_inset CommandInset ref
736 reference "sec:International-Keymap-Stuff"
743 \begin_layout Labeling
744 \labelwidthstring 00.00.0000
745 \begin_inset Flex Code
748 \begin_layout Plain Layout
754 contains the text class and module files described in Chapter
759 \begin_inset CommandInset ref
761 reference "cha:Installing-New-Document"
768 \begin_layout Labeling
769 \labelwidthstring 00.00.0000
770 \begin_inset Flex Code
773 \begin_layout Plain Layout
780 \begin_inset Flex Code
783 \begin_layout Plain Layout
789 Python scripts used to convert between LyX versions.
790 These can be run from the command line if, say, you want to batch-convert
794 \begin_layout Labeling
795 \labelwidthstring 00.00.0000
796 \begin_inset Flex Code
799 \begin_layout Plain Layout
805 contains some files that demonstrate the capabilities of the
806 \begin_inset Flex MenuItem
809 \begin_layout Plain Layout
820 Also contains some scripts used by LyX itself.
823 \begin_layout Labeling
824 \labelwidthstring 00.00.0000
825 \begin_inset Flex Code
828 \begin_layout Plain Layout
834 contains the standard LyX template files described in Chapter
839 \begin_inset CommandInset ref
841 reference "sub:Creating-Templates"
848 \begin_layout Labeling
849 \labelwidthstring 00.00.0000
850 \begin_inset Flex Code
853 \begin_layout Plain Layout
859 contains files with the extension
860 \begin_inset Flex Code
863 \begin_layout Plain Layout
869 that define the user interface to LyX.
870 That is, the files define which items appear in which menus and the items
871 appearing on the toolbar.
874 \begin_layout Subsection
875 Files you don't want to modify
878 \begin_layout Standard
879 These files are used internally by LyX and you generally do not need to
880 modify them unless you are a developer.
883 \begin_layout Labeling
884 \labelwidthstring 00.00.0000
885 \begin_inset Flex Code
888 \begin_layout Plain Layout
894 this file contains the list of LyX developers.
895 The contents are displayed with the menu entry
896 \begin_inset Flex MenuItem
899 \begin_layout Plain Layout
900 Help\SpecialChar \menuseparator
913 \begin_layout Labeling
914 \labelwidthstring 00.00.0000
915 \begin_inset Flex Code
918 \begin_layout Plain Layout
924 this is a LaTeX script used during the configuration process.
928 \begin_layout Labeling
929 \labelwidthstring 00.00.0000
930 \begin_inset Flex Code
933 \begin_layout Plain Layout
939 this is the script that is used to re-configure LyX.
940 It creates configuration files in the directory it was run from.
943 \begin_layout Subsection
944 Other files needing a line or two
945 \change_deleted -712698321 1357054454
947 \change_inserted -712698321 1357054454
948 \SpecialChar \ldots{}
954 \begin_layout Labeling
955 \labelwidthstring 00.00.0000
956 \begin_inset Flex Code
959 \begin_layout Plain Layout
965 this contains tables describing how different character encodings can be
969 \begin_layout Labeling
970 \labelwidthstring 00.00.0000
971 \begin_inset Flex Code
974 \begin_layout Plain Layout
980 this file contains the templates available to the new
981 \begin_inset Flex MenuItem
984 \begin_layout Plain Layout
997 \begin_layout Labeling
998 \labelwidthstring 00.00.0000
999 \begin_inset Flex Code
1002 \begin_layout Plain Layout
1008 this file contains a list of all the languages currently supported by LyX.
1009 \change_inserted -712698321 1357054565
1013 \begin_layout Labeling
1014 \labelwidthstring 00.00.0000
1016 \change_inserted -712698321 1357054669
1017 \begin_inset Flex Code
1020 \begin_layout Plain Layout
1022 \change_inserted -712698321 1357054669
1030 contains information about the supported fonts.
1031 \change_inserted -195340706 1334775793
1035 \begin_layout Labeling
1036 \labelwidthstring 00.00.0000
1038 \change_inserted -195340706 1334775793
1039 \begin_inset Flex Code
1042 \begin_layout Plain Layout
1044 \change_inserted -195340706 1334775793
1050 this file contains translations for internationalized paragraph styles
1052 \begin_inset space \thinspace{}
1056 \begin_inset CommandInset ref
1058 reference "sub:I18n"
1063 \change_inserted -712698321 1357054494
1067 \begin_layout Labeling
1068 \labelwidthstring 00.00.0000
1070 \change_inserted -712698321 1357054554
1071 \begin_inset Flex Code
1074 \begin_layout Plain Layout
1076 \change_inserted -712698321 1357054508
1084 this file contains information about unicode-encoded glyphs and the way
1085 they are supported by LyX via LaTeX.
1090 \begin_layout Section
1091 Your local configuration directory
1094 \begin_layout Standard
1095 Even if you are using LyX as an unprivileged user, you might want to change
1096 LyX configuration for your own use.
1098 \begin_inset Flex Code
1101 \begin_layout Plain Layout
1107 directory contains all your personal configuration files.
1108 This is the directory described as
1109 \begin_inset Quotes eld
1113 \begin_inset Quotes erd
1117 \begin_inset Flex MenuItem
1120 \begin_layout Plain Layout
1121 Help\SpecialChar \menuseparator
1123 \begin_inset space ~
1132 This directory is used as a mirror of
1133 \begin_inset Flex Code
1136 \begin_layout Plain Layout
1142 , which means that every file in
1143 \begin_inset Flex Code
1146 \begin_layout Plain Layout
1152 is a replacement for the corresponding file in
1153 \begin_inset Flex Code
1156 \begin_layout Plain Layout
1163 Any configuration file described in the above sections can be placed either
1164 in the system-wide directory, in which case it will affect all users, or
1165 in your local directory for your own use.
1168 \begin_layout Standard
1169 To make things clearer, let's provide a few examples:
1172 \begin_layout Itemize
1173 The preferences set in the
1174 \begin_inset Flex MenuItem
1177 \begin_layout Plain Layout
1178 Tools\SpecialChar \menuseparator
1184 dialog are saved to a file
1185 \begin_inset Flex Code
1188 \begin_layout Plain Layout
1195 \begin_inset Flex Code
1198 \begin_layout Plain Layout
1207 \begin_layout Itemize
1208 When you reconfigure using
1209 \begin_inset Flex MenuItem
1212 \begin_layout Plain Layout
1213 Tools\SpecialChar \menuseparator
1220 \begin_inset Flex Code
1223 \begin_layout Plain Layout
1229 script, and the resulting files are written in your local configuration
1231 This means that any additional text class file that you might have added
1233 \begin_inset Flex Code
1236 \begin_layout Plain Layout
1242 will be added to the list of classes in the
1243 \begin_inset Flex MenuItem
1246 \begin_layout Plain Layout
1247 Document\SpecialChar \menuseparator
1256 \begin_layout Itemize
1257 If you get some updated documentation from LyX ftp site and cannot install
1258 it because you do not have sysadmin rights on your system, you can just
1260 \begin_inset Flex Code
1263 \begin_layout Plain Layout
1269 and the items in the
1270 \begin_inset Flex MenuItem
1273 \begin_layout Plain Layout
1279 menu will open them!
1282 \begin_layout Section
1283 Running LyX with multiple configurations
1286 \begin_layout Standard
1287 The configuration freedom of the local configuration directory may not suffice
1288 if you want to have more than one configuration at your disposal.
1289 For example, you may want to be use different key bindings or printer settings
1291 You can achieve this by having several such directories.
1292 You then specify which directory to use at run-time.
1295 \begin_layout Standard
1296 Invoking LyX with the command line switch
1297 \begin_inset Flex Code
1300 \begin_layout Plain Layout
1310 instructs the program to read the configuration from that directory, and
1311 not from the default directory.
1312 (You can determine the default directory by running LyX without the
1313 \begin_inset Flex Code
1316 \begin_layout Plain Layout
1322 switch.) If the specified directory does not exist, LyX offers to create
1323 it for you, just like it does for the default directory on the first time
1324 you run the program.
1325 You can modify the configuration options in this additional user directory
1326 exactly as you would for the default directory.
1327 These directories are completely independent (but read on).
1328 Note that setting the environment variable
1329 \begin_inset Flex Code
1332 \begin_layout Plain Layout
1338 to some value has exactly the same effect.
1341 \begin_layout Standard
1342 Having several configurations also requires more maintenance: if you want
1343 to add a new layout to
1344 \begin_inset Flex Code
1347 \begin_layout Plain Layout
1353 which you want available from all your configurations, you must add it
1354 to each directory separately.
1355 You can avoid this with the following trick: after LyX creates the additional
1356 directory, most of the subdirectories (see above) are empty.
1357 If you want the new configuration to mirror an existing one, replace the
1358 empty subdirectory with a symbolic link to the matching subdirectory in
1359 the existing configuration.
1361 \begin_inset Flex Code
1364 \begin_layout Plain Layout
1370 subdirectory, however, since it contains a file written by the configuration
1371 script (also accessible through
1372 \begin_inset Flex MenuItem
1375 \begin_layout Plain Layout
1376 Tools\SpecialChar \menuseparator
1382 ) which is configuration-specific.
1385 \begin_layout Chapter
1386 The Preferences dialog
1389 \begin_layout Standard
1390 All options of the preferences dialog are described in the Appendix
1392 The Preferences Dialog
1399 For some options you might find here more details.
1402 \begin_layout Section
1404 \begin_inset CommandInset label
1413 \begin_layout Standard
1414 The first step is to define your file formats if they are not already defined.
1416 \begin_inset Flex MenuItem
1419 \begin_layout Plain Layout
1420 Tools\SpecialChar \menuseparator
1428 \begin_inset Flex MenuItem
1431 \begin_layout Plain Layout
1432 File Handling\SpecialChar \menuseparator
1439 \begin_inset Flex MenuItem
1442 \begin_layout Plain Layout
1443 New\SpecialChar \ldots{}
1449 button to define your new format.
1451 \begin_inset Flex MenuItem
1454 \begin_layout Plain Layout
1460 field contains the name used to identify the format in the GUI.
1462 \begin_inset Flex MenuItem
1465 \begin_layout Plain Layout
1471 is used to identify the format internally.
1472 You will also need to enter a file extension.
1473 These are all required.
1475 \begin_inset Flex MenuItem
1478 \begin_layout Plain Layout
1484 field is used to provide a keyboard shortcut on the menus.
1485 (For example, pressing
1486 \begin_inset Flex MenuItem
1489 \begin_layout Plain Layout
1496 \begin_inset Flex MenuItem
1499 \begin_layout Plain Layout
1500 View\SpecialChar \menuseparator
1501 View (Other Formats)\SpecialChar \menuseparator
1510 \begin_layout Standard
1512 \begin_inset Flex MenuItem
1515 \begin_layout Plain Layout
1522 \begin_inset Flex MenuItem
1525 \begin_layout Plain Layout
1532 For example, you might want to use
1533 \begin_inset Flex MenuItem
1536 \begin_layout Plain Layout
1542 to view PostScript files.
1543 You can enter the command needed to start the program in the corresponding
1545 In defining this command, you can use the four variables listed in the
1547 The viewer is launched when you view an image in LyX or use the
1548 \begin_inset Flex MenuItem
1551 \begin_layout Plain Layout
1558 The editor is for example launched when you right-click on an image and
1560 \begin_inset Flex MenuItem
1563 \begin_layout Plain Layout
1569 in the appearing context menu.
1572 \begin_layout Standard
1574 \change_inserted -195340706 1329851811
1576 \begin_inset Flex MenuItem
1579 \begin_layout Plain Layout
1585 type of a format is optional, but if it is specified, it must be unique
1587 It is used to detect files of this format from the file contents.
1588 For some important file formats there is no MIME type officially registered
1590 \begin_inset CommandInset href
1593 target "http://www.iana.org/assignments/media-types/"
1598 Therefore LyX uses the extended list of MIME types as specified by
1599 \begin_inset CommandInset href
1601 name "freedesktop.org"
1602 target "http://www.freedesktop.org/wiki/Specifications/shared-mime-info-spec"
1609 \begin_layout Standard
1611 \begin_inset Flex MenuItem
1614 \begin_layout Plain Layout
1620 option tells LyX that a format is suitable for document export.
1621 If this is set and if a suitable conversion route exists (see sec.
1622 \begin_inset space \thinspace{}
1626 \begin_inset CommandInset ref
1628 reference "sec:Converters"
1632 ), the format will appear in the
1633 \begin_inset Flex MenuItem
1636 \begin_layout Plain Layout
1637 File\SpecialChar \menuseparator
1644 The format will also appear in the
1645 \begin_inset Flex MenuItem
1648 \begin_layout Plain Layout
1654 menu if a viewer is specified for the format.
1655 Pure image formats, such as
1656 \begin_inset Flex Code
1659 \begin_layout Plain Layout
1665 , should not use this option.
1666 Formats that can both represent vector graphics and documents like
1667 \begin_inset Flex Code
1670 \begin_layout Plain Layout
1679 \begin_layout Standard
1681 \begin_inset Flex MenuItem
1684 \begin_layout Plain Layout
1685 Vector graphics format
1690 tells LyX that a format can contain vector graphics.
1691 This information is used to determine the target format of included graphics
1693 \begin_inset Flex MenuItem
1696 \begin_layout Plain Layout
1703 Included graphics may need to be converted to either
1704 \begin_inset Flex MenuItem
1707 \begin_layout Plain Layout
1714 \begin_inset Flex MenuItem
1717 \begin_layout Plain Layout
1724 \begin_inset Flex MenuItem
1727 \begin_layout Plain Layout
1734 \begin_inset Flex MenuItem
1737 \begin_layout Plain Layout
1743 cannot handle other image formats.
1744 If an included graphic is not already in
1745 \begin_inset Flex MenuItem
1748 \begin_layout Plain Layout
1755 \begin_inset Flex MenuItem
1758 \begin_layout Plain Layout
1765 \begin_inset Flex MenuItem
1768 \begin_layout Plain Layout
1774 format, it is converted to
1775 \begin_inset Flex MenuItem
1778 \begin_layout Plain Layout
1784 if the vector format option is set, and otherwise to
1785 \begin_inset Flex MenuItem
1788 \begin_layout Plain Layout
1797 \begin_layout Section
1801 \begin_layout Standard
1802 Since all conversions from one format to another take place in LyX's temporary
1803 directory, it is sometimes necessary to modify a file before copying it
1804 to the temporary directory in order that the conversion may be performed.
1808 \begin_layout Plain Layout
1809 For example, the file may refer to other files—images, for example—using
1810 relative file names, and these may become invalid when the file is copied
1811 to the temporary directory.
1816 This is done by a Copier: It copies a file to (or from) the temporary directory
1817 and may modify it in the process.
1820 \begin_layout Standard
1821 The definitions of the copiers may use four variables:
1824 \begin_layout Labeling
1825 \labelwidthstring 00.00.0000
1826 \begin_inset Flex Code
1829 \begin_layout Plain Layout
1835 The LyX system directory (e.
1836 \begin_inset space \thinspace{}
1840 \begin_inset space \space{}
1844 \begin_inset Flex MenuItem
1847 \begin_layout Plain Layout
1856 \begin_layout Labeling
1857 \labelwidthstring 00.00.0000
1858 \begin_inset Flex Code
1861 \begin_layout Plain Layout
1870 \begin_layout Labeling
1871 \labelwidthstring 00.00.0000
1872 \begin_inset Flex Code
1875 \begin_layout Plain Layout
1882 \change_inserted 1082167584 1348453985
1886 \begin_layout Labeling
1887 \labelwidthstring 00.00.0000
1889 \change_inserted 1082167584 1348453986
1890 $$b The base name (without filename extension) in the LyX temporary directory
1893 \begin_layout Labeling
1894 \labelwidthstring 00.00.0000
1896 \change_inserted 1082167584 1348453986
1897 $$p The full directory path of the LyX temporary directory
1900 \begin_layout Labeling
1901 \labelwidthstring 00.00.0000
1903 \change_inserted 1082167584 1348453986
1904 $$r The full pathname to the original LyX file being processed
1907 \begin_layout Labeling
1908 \labelwidthstring 00.00.0000
1910 \change_inserted 1082167584 1348453986
1911 $$f The filename (without any directory path) of the LyX file.
1914 \begin_layout Labeling
1915 \labelwidthstring 00.00.0000
1916 \begin_inset Flex Code
1919 \begin_layout Plain Layout
1926 \change_inserted 1082167584 1348453720
1930 \begin_layout Standard
1931 The latter should be the filename as it would be used in a LaTeX's
1938 It is relevant only when exporting files suitable for such inclusion.
1941 \begin_layout Standard
1942 Copiers can be used to do almost anything with output files.
1943 For example, suppose you want generated pdf files to be copied to a special
1945 \begin_inset Flex Code
1948 \begin_layout Plain Layout
1955 Then you could write a shell script such as this one:
1958 \begin_layout Standard
1959 \begin_inset listings
1963 \begin_layout Plain Layout
1968 \begin_layout Plain Layout
1973 \begin_layout Plain Layout
1975 TOFILE=`basename $2`
1978 \begin_layout Plain Layout
1980 cp $FROMFILE /home/you/pdf/$TOFILE
1985 Save it in your local LyX directory—say,
1986 \begin_inset Flex Code
1989 \begin_layout Plain Layout
1990 /home/you/.lyx/scripts/pdfcopier.sh
1995 —and make it executable, if you need to do so on your platform.
1997 \begin_inset Flex MenuItem
2000 \begin_layout Plain Layout
2001 Tools\SpecialChar \menuseparator
2007 dialog, select under
2008 \begin_inset Flex MenuItem
2011 \begin_layout Plain Layout
2012 File Handling\SpecialChar \menuseparator
2019 \begin_inset Flex MenuItem
2022 \begin_layout Plain Layout
2028 format—or one of the other pdf formats—and enter
2029 \begin_inset Flex Code
2032 \begin_layout Plain Layout
2033 pdfcopier.sh $$i $$o
2039 \begin_inset Flex MenuItem
2042 \begin_layout Plain Layout
2052 \begin_layout Standard
2053 Copiers are used by LyX in various of its own conversions.
2054 For example, if appropriate programs are found, LyX will automatically
2055 install copiers for the
2056 \begin_inset Flex MenuItem
2059 \begin_layout Plain Layout
2066 \begin_inset Flex MenuItem
2069 \begin_layout Plain Layout
2071 \begin_inset space ~
2080 When these formats are exported, the copier sees that not just the main
2081 HTML file but various associated files (style files, images, etc.) are also
2083 All these files are written to a subdirectory of the directory in which
2084 the original LyX file was found.
2088 \begin_layout Plain Layout
2089 This copier can be customized.
2091 \begin_inset Quotes eld
2095 \begin_inset Quotes erd
2098 argument takes a comma-separated list of extensions to be copied; if it
2099 is omitted, all files will be copied.
2101 \begin_inset Quotes eld
2105 \begin_inset Quotes erd
2108 argument determines the extension added to the generated directory.
2110 \begin_inset Quotes eld
2114 \begin_inset Flex MenuItem
2117 \begin_layout Plain Layout
2124 \begin_inset Quotes erd
2127 , so HTML generated from
2128 \begin_inset Flex MenuItem
2131 \begin_layout Plain Layout
2132 /path/to/filename.lyx
2138 \begin_inset Flex MenuItem
2141 \begin_layout Plain Layout
2142 /path/to/filename.html.LyXconv
2156 \begin_layout Section
2158 \begin_inset CommandInset label
2160 name "sec:Converters"
2167 \begin_layout Standard
2168 You can define your own Converters to convert files between different formats.
2170 \begin_inset Flex MenuItem
2173 \begin_layout Plain Layout
2174 Tools\SpecialChar \menuseparator
2175 Preferences\SpecialChar \menuseparator
2176 File Handling\SpecialChar \menuseparator
2185 \begin_layout Standard
2186 To define a new converter, select the
2187 \begin_inset Flex MenuItem
2190 \begin_layout Plain Layout
2192 \begin_inset space ~
2201 \begin_inset Flex MenuItem
2204 \begin_layout Plain Layout
2206 \begin_inset space ~
2214 from the drop-down lists, enter the command needed for the conversion,
2216 \begin_inset Flex MenuItem
2219 \begin_layout Plain Layout
2226 Several variables can be used in the definition of converters:
2229 \begin_layout Labeling
2230 \labelwidthstring 00.00.0000
2231 \begin_inset Flex Code
2234 \begin_layout Plain Layout
2240 The LyX system directory
2243 \begin_layout Labeling
2244 \labelwidthstring 00.00.0000
2245 \begin_inset Flex Code
2248 \begin_layout Plain Layout
2257 \begin_layout Labeling
2258 \labelwidthstring 00.00.0000
2259 \begin_inset Flex Code
2262 \begin_layout Plain Layout
2271 \begin_layout Labeling
2272 \labelwidthstring 00.00.0000
2273 \begin_inset Flex Code
2276 \begin_layout Plain Layout
2282 The base filename of the input file (i.
2283 \begin_inset space \thinspace{}
2286 g., without the extension)
2289 \begin_layout Labeling
2290 \labelwidthstring 00.00.0000
2291 \begin_inset Flex Code
2294 \begin_layout Plain Layout
2300 The path to the input file
2303 \begin_layout Labeling
2304 \labelwidthstring 00.00.0000
2305 \begin_inset Flex Code
2308 \begin_layout Plain Layout
2314 The path to the original input file (this is different from $$p when a
2315 chain of converters is called)
2318 \begin_layout Labeling
2319 \labelwidthstring 00.00.0000
2320 \begin_inset Flex Code
2323 \begin_layout Plain Layout
2329 The iconv name for the encoding of the document.
2332 \begin_layout Standard
2334 \begin_inset Flex MenuItem
2337 \begin_layout Plain Layout
2339 \begin_inset space ~
2347 field you can enter the following flags, separated by commas:
2350 \begin_layout Labeling
2351 \labelwidthstring 00.00.0000
2352 \begin_inset Flex Code
2355 \begin_layout Plain Layout
2361 This converter runs some form of LaTeX.
2362 This will make LyX's LaTeX error logs available.
2365 \begin_layout Labeling
2366 \labelwidthstring 00.00.0000
2367 \begin_inset Flex Code
2370 \begin_layout Plain Layout
2377 \begin_inset Flex MenuItem
2380 \begin_layout Plain Layout
2386 file for the conversion.
2387 \change_inserted 1414654397 1337693117
2391 \begin_layout Labeling
2392 \labelwidthstring 00.00.0000
2394 \change_inserted 1414654397 1337693188
2395 \begin_inset Flex Code
2398 \begin_layout Plain Layout
2400 \change_inserted 1414654397 1337693129
2409 \begin_inset Quotes eld
2413 \begin_inset Quotes erd
2416 file from the backend, which in practice means a LaTeX file like the one
2417 we would export, without
2418 \begin_inset Flex Code
2421 \begin_layout Plain Layout
2423 \change_inserted 1414654397 1337693184
2436 \begin_layout Labeling
2437 \labelwidthstring 00.00.0000
2438 \begin_inset Flex Code
2441 \begin_layout Plain Layout
2450 \begin_layout Standard
2451 The following three flags are not really flags at all because they take
2453 \begin_inset Flex MenuItem
2456 \begin_layout Plain Layout
2458 \begin_inset space ~
2462 \begin_inset space ~
2473 \begin_layout Labeling
2474 \labelwidthstring 00.00.0000
2475 \begin_inset Flex Code
2478 \begin_layout Plain Layout
2484 If set, the converter's standard error will be redirected to a file
2485 \begin_inset Flex Code
2488 \begin_layout Plain Layout
2494 , and the script given as argument will be run as:
2495 \begin_inset Flex Code
2498 \begin_layout Plain Layout
2499 script < infile.out > infile.log
2505 The argument may contain
2506 \begin_inset Flex Code
2509 \begin_layout Plain Layout
2518 \begin_layout Labeling
2519 \labelwidthstring 00.00.0000
2520 \begin_inset Flex Code
2523 \begin_layout Plain Layout
2529 The name of the directory in which the converter will dump the generated
2531 LyX will not create this directory, and it does not copy anything into
2532 it, though it will copy this directory to the destination.
2533 The argument may contain
2534 \begin_inset Flex Code
2537 \begin_layout Plain Layout
2543 , which will be replaced by the base name of the input and output files,
2544 respectively, when the directory is copied.
2545 \begin_inset Newline newline
2548 Note that resultdir and usetempdir make no sense together.
2549 The latter will be ignored if the former is given.
2552 \begin_layout Labeling
2553 \labelwidthstring 00.00.0000
2554 \begin_inset Flex Code
2557 \begin_layout Plain Layout
2563 Determines the output file name and may, contain
2564 \begin_inset Flex Code
2567 \begin_layout Plain Layout
2574 Sensible only with resultdir and optional even then; if not given, it defaults
2578 \begin_layout Standard
2579 None of these last three are presently used in any of the converters that
2580 are installed with LyX.
2584 \begin_layout Standard
2585 You do not have to define converters for all formats between which you want
2587 For example, you will note that there is no `LyX to PostScript' converter,
2588 but LyX will export PostScript.
2589 It does so by first creating a LaTeX file (no converter needs to be defined
2590 for this) which is then converted to DVI using the `LaTeX to DVI' converter,
2591 and finally converting the resulting DVI file to PostScript.
2592 LyX finds such `chains' of converters automatically, and it will always
2593 choose the shortest possible chain.
2594 You can, though, still define multiple conversion methods between file
2596 For example, the standard LyX configuration provides
2597 \change_inserted -195340706 1363813100
2599 \change_deleted -195340706 1363813102
2602 ways to convert LaTeX to PDF: Directly, using
2603 \begin_inset Flex MenuItem
2606 \begin_layout Plain Layout
2612 ; via (DVI and) PostScript, using
2613 \begin_inset Flex MenuItem
2616 \begin_layout Plain Layout
2623 \change_deleted -195340706 1363813149
2627 \begin_inset Flex MenuItem
2630 \begin_layout Plain Layout
2637 \change_inserted -195340706 1363813143
2638 ; or directly using XeTeX or LuaTeX
2641 To define such alternate chains, you must define multiple target `file
2642 formats', as described in section
2643 \begin_inset CommandInset ref
2645 reference "sec:Formats"
2650 For example, in the standard configuration, the formats named
2651 \begin_inset Flex MenuItem
2654 \begin_layout Plain Layout
2661 \begin_inset Flex MenuItem
2664 \begin_layout Plain Layout
2671 \change_inserted -195340706 1363813075
2673 \begin_inset Flex MenuItem
2676 \begin_layout Plain Layout
2678 \change_inserted -195340706 1363813079
2685 \begin_inset Flex MenuItem
2688 \begin_layout Plain Layout
2690 \change_inserted -195340706 1363813082
2699 \begin_inset Flex MenuItem
2702 \begin_layout Plain Layout
2704 \change_inserted -195340706 1363813086
2706 \change_deleted -195340706 1363813086
2714 are defined, all of which share the extension
2715 \begin_inset Flex MenuItem
2718 \begin_layout Plain Layout
2724 , and which correspond to the conversion methods just mentioned.
2727 \begin_layout Chapter
2728 Internationalizing LyX
2729 \begin_inset CommandInset label
2731 name "cha:Internationalizing-LyX"
2738 \begin_layout Standard
2739 LyX supports using a translated interface.
2740 Last time we checked, LyX provided text in thirty languages.
2741 The language of choice is called your
2746 (For further reading on locale settings, see also the documentation for
2747 locale that comes with your operating system.
2748 For Linux, the manual page for
2749 \begin_inset Flex Code
2752 \begin_layout Plain Layout
2758 could be a good place to start).
2761 \begin_layout Standard
2762 Notice that these translations will work, but do contain a few flaws.
2763 In particular, all dialogs have been designed with the English text in
2764 mind, which means that some of the translated text will be too large to
2765 fit within the space allocated.
2766 This is only a display problem and will not cause any harm.
2767 Also, you will find that some of the translations do not define shortcut
2768 keys for everything.
2769 Sometimes, there are simply not enough free letters to do it.
2770 Other times, the translator just hasn't got around to doing it yet.
2771 Our localization team, which you may wish to join,
2775 \begin_layout Plain Layout
2776 If you are a fluent speaker of a language other than English, joining these
2777 teams is a great way to give back to the LyX community!
2782 will of course try to fix these shortcomings in future versions of LyX.
2785 \begin_layout Section
2789 \begin_layout Subsection
2790 Translating the graphical user interface (text messages).
2793 \begin_layout Standard
2795 \begin_inset Flex Code
2798 \begin_layout Plain Layout
2804 library to handle the internationalization of the interface.
2805 To have LyX speak your favorite language in all menus and dialogs, you
2807 \begin_inset Flex Code
2810 \begin_layout Plain Layout
2816 -file for that language.
2817 When this is available, you'll have to generate a
2818 \begin_inset Flex Code
2821 \begin_layout Plain Layout
2827 -file from it and install the
2828 \begin_inset Flex Code
2831 \begin_layout Plain Layout
2838 The process of doing all of this is explained in the documentation for
2840 \begin_inset Flex Code
2843 \begin_layout Plain Layout
2850 It is possible to do this just for yourself, but if you're going to do
2851 it, you might as well share the results of your labors with the rest of
2853 Send a message to the LyX developers' list for more information about how
2857 \begin_layout Standard
2858 In short, this is what you should do (xx denotes the language code):
2861 \begin_layout Itemize
2862 Check out the LyX source code.
2864 \begin_inset CommandInset href
2866 name "information on the web"
2867 target "http://www.lyx.org/HowToUseSVN"
2874 \begin_layout Itemize
2876 \begin_inset Flex Code
2879 \begin_layout Plain Layout
2885 to the folder of the
2886 \begin_inset Flex Code
2889 \begin_layout Plain Layout
2897 \begin_inset Flex Code
2900 \begin_layout Plain Layout
2908 \begin_inset Flex Code
2911 \begin_layout Plain Layout
2917 doesn't exist anywhere, it can be remade with the console command
2918 \begin_inset Flex Code
2921 \begin_layout Plain Layout
2927 in that directory, or you can use an existing po-file for some other language
2931 \begin_layout Itemize
2933 \begin_inset Flex Code
2936 \begin_layout Plain Layout
2946 \begin_layout Plain Layout
2947 This is just a text file, so it can be edited in any text editor.
2948 But there are also specialized programs that support such editing, such
2953 (for all platforms) or
2962 contains a `mode' for editing
2963 \begin_inset Flex Code
2966 \begin_layout Plain Layout
2977 For some menu- and widget-labels, there are also shortcut keys that should
2979 Those keys are marked after a `|', and should be translated according to
2980 the words and phrases of the language.
2981 You should also fill also out the information at the beginning of the new
2983 \begin_inset Flex Code
2986 \begin_layout Plain Layout
2992 -file with your email-address, etc., so people know where to reach you with
2993 suggestions and entertaining flames.
2996 \begin_layout Standard
2997 If you are just doing this on your own, then:
3000 \begin_layout Itemize
3002 \begin_inset Flex Code
3005 \begin_layout Plain Layout
3012 This can be done with
3013 \begin_inset Flex Code
3016 \begin_layout Plain Layout
3017 msgfmt -o xx.mo < xx.po
3025 \begin_layout Itemize
3027 \begin_inset Flex Code
3030 \begin_layout Plain Layout
3036 -file to your locale-tree, at the correct directory for application messages
3041 xx, and under the name
3042 \begin_inset Flex Code
3045 \begin_layout Plain Layout
3052 \begin_inset space \thinspace{}
3056 \begin_inset space \space{}
3060 \begin_inset Flex Code
3063 \begin_layout Plain Layout
3064 /usr/local/share/locale/xx/LC_MESSAGES/lyx.mo
3074 \begin_layout Standard
3075 As said, however, it would be best if the new
3076 \begin_inset Flex Code
3079 \begin_layout Plain Layout
3085 -file could be added to the LyX distribution, so others can use it.
3086 Adding it involves making additional changes to LyX.
3087 So send an email to the developers' mailing list if you're interested in
3091 \begin_layout Subsubsection
3095 \begin_layout Standard
3096 Sometimes it turns out that one English message needs to be translated into
3097 different messages in the target language.
3098 One example is the message
3099 \begin_inset Flex Code
3102 \begin_layout Plain Layout
3108 which has the German translation
3116 , depending upon exactly what the English
3117 \begin_inset Quotes eld
3121 \begin_inset Quotes erd
3126 \begin_inset Flex Code
3129 \begin_layout Plain Layout
3135 does not handle such ambiguous translations.
3136 Therefore you have to add some context information to the message: Instead
3138 \begin_inset Flex Code
3141 \begin_layout Plain Layout
3148 \begin_inset Flex Code
3151 \begin_layout Plain Layout
3152 To[[as in 'From format x to format y']]
3158 \begin_inset Flex Code
3161 \begin_layout Plain Layout
3162 To[[as in 'From page x to page y']].
3167 Now the two occurrences of
3168 \begin_inset Flex Code
3171 \begin_layout Plain Layout
3178 \begin_inset Flex Code
3181 \begin_layout Plain Layout
3187 and can be translated correctly to
3198 \begin_layout Standard
3199 Of course the context information needs to be stripped off the original
3200 message when no translation is used.
3201 Therefore you have to put it in double square brackets at the end of the
3202 message (see the example above).
3203 The translation mechanism of LyX ensures that everything in double square
3204 brackets at the end of messages is removed before displaying the message.
3207 \begin_layout Subsection
3208 Translating the documentation.
3211 \begin_layout Standard
3212 The online documentation (in the
3213 \begin_inset Flex MenuItem
3216 \begin_layout Plain Layout
3222 -menu) can (and should!) be translated.
3223 If there are translated versions of the documentation available
3227 \begin_layout Plain Layout
3228 As of March 2008, at least some of the documents have been translated into
3229 fourteen languages, with the Tutorial available in a few more.
3234 and the locale is set accordingly, these will be used automagically by
3236 LyX looks for translated versions as
3237 \begin_inset Flex Code
3240 \begin_layout Plain Layout
3241 LyXDir/doc/xx/DocName.lyx
3247 \begin_inset Flex Code
3250 \begin_layout Plain Layout
3256 is the code for the language currently in use.
3257 If there are no translated documents, the default English versions will
3259 Note that the translated versions must have the same filenames (
3260 \begin_inset Flex Code
3263 \begin_layout Plain Layout
3269 above) as the original.
3270 If you feel up to translating the documentation (an excellent way to proof-read
3271 the original documentation by the way!), there are a few things you should
3275 \begin_layout Itemize
3276 Check out the documentation translation web page at
3277 \begin_inset CommandInset href
3279 name "http://www.lyx.org/Translation"
3280 target "http://www.lyx.org/Translation"
3285 That way, you can find out which (if any) documents have already been translate
3286 d into your language.
3287 You can also find out who (if anyone) is organizing the effort to translate
3288 the documentation into your language.
3289 If no one is organizing the effort, please let us know that you're interested.
3292 \begin_layout Standard
3293 Once you get to actually translating, here's a few hints for you that may
3297 \begin_layout Itemize
3298 Join the documentation team! There is information on how to do that in
3299 \begin_inset Flex Code
3302 \begin_layout Plain Layout
3309 \begin_inset Flex MenuItem
3312 \begin_layout Plain Layout
3313 Help\SpecialChar \menuseparator
3319 ), which by the way is the first document you should translate.
3322 \begin_layout Itemize
3323 Learn the typographic conventions for the language you are translating to.
3324 Typography is an ancient art and over the centuries, a great variety of
3325 conventions have developed throughout different parts of the world.
3326 Also study the professional terminology amongst typographers in your country.
3327 Inventing your own terminology will only confuse the users.
3330 (Warning! Typography is addictive!)
3333 \begin_layout Itemize
3334 Make a copy of the document.
3335 This will be your working copy.
3336 You can use this as your personal translated help-file by placing it in
3338 \begin_inset Flex Code
3341 \begin_layout Plain Layout
3350 \begin_layout Itemize
3351 Sometimes the original document (from the LyX-team) will be updated.
3352 Use the source viewer at
3353 \begin_inset CommandInset href
3355 name "http://www.lyx.org/trac/timeline"
3356 target "http://www.lyx.org/trac/timeline"
3360 to see what has been changed.
3361 That way you can easily see which parts of the translated document need
3365 \begin_layout Standard
3366 If you ever find an error in the original document, fix it and notify the
3367 rest of the documentation team of the changes! (You didn't forget to join
3368 the documentation team, did you?)
3371 \begin_layout Standard
3372 \begin_inset Branch OutDated
3375 \begin_layout Section
3376 International Keyboard Support
3379 \begin_layout Standard
3382 [Editor's Note: The following section is by
3390 It needs to be fixed to conform to the new Documentation Style sheet and
3391 to make use of the new v1.0 features.
3392 The whole thing also needs to be merged with the section following it.-jw
3393 It may also be badly out of date.-rh (2008)]
3396 \begin_layout Subsection
3397 Defining Own Keymaps: Keymap File Format
3400 \begin_layout Standard
3401 Let's look at a keyboard definition file a little closer.
3402 It is a plain text file defining
3405 \begin_layout Itemize
3406 key-to-key or key-to-string translations
3409 \begin_layout Itemize
3413 \begin_layout Itemize
3414 dead keys exceptions
3417 \begin_layout Standard
3418 To define key-to-key or key-to-string translation, use this command:
3421 \begin_layout Quotation
3422 \begin_inset Flex Code
3425 \begin_layout Plain Layout
3434 \begin_inset Flex Code
3437 \begin_layout Plain Layout
3446 \begin_layout Standard
3448 \begin_inset Flex Code
3451 \begin_layout Plain Layout
3457 is the key to be translated and
3458 \begin_inset Flex Code
3461 \begin_layout Plain Layout
3467 is the string to be inserted into the document.
3468 To define dead keys, use:
3471 \begin_layout Quotation
3472 \begin_inset Flex Code
3475 \begin_layout Plain Layout
3484 \begin_inset Flex Code
3487 \begin_layout Plain Layout
3496 \begin_layout Standard
3498 \begin_inset Flex Code
3501 \begin_layout Plain Layout
3507 is a keyboard key and
3508 \begin_inset Flex Code
3511 \begin_layout Plain Layout
3518 The following dead keys are supported (shortcut name is in parentheses):
3521 \begin_layout Quotation
3525 \begin_inset space \hfill{}
3531 \begin_layout Quotation
3533 \begin_inset space \hfill{}
3539 \begin_layout Quotation
3541 \begin_inset space \hfill{}
3547 \begin_layout Quotation
3549 \begin_inset space \hfill{}
3555 \begin_layout Quotation
3557 \begin_inset space \hfill{}
3563 \begin_layout Quotation
3565 \begin_inset space \hfill{}
3572 \begin_layout Plain Layout
3584 \begin_layout Quotation
3586 \begin_inset space \hfill{}
3592 \begin_layout Quotation
3594 \begin_inset space \hfill{}
3601 \begin_layout Plain Layout
3613 \begin_layout Quotation
3615 \begin_inset space \hfill{}
3621 \begin_layout Quotation
3623 \begin_inset space \hfill{}
3629 \begin_layout Quotation
3631 \begin_inset space \hfill{}
3638 \begin_layout Plain Layout
3650 \begin_layout Quotation
3652 \begin_inset space \hfill{}
3659 \begin_layout Plain Layout
3671 \begin_layout Quotation
3673 \begin_inset space \hfill{}
3679 \begin_layout Quotation
3680 hungarian umlaut (hug)
3681 \begin_inset space \hfill{}
3687 \begin_layout Quotation
3689 \begin_inset space \hfill{}
3695 \begin_layout Quotation
3697 \begin_inset space \hfill{}
3704 \begin_layout Plain Layout
3716 \begin_layout Standard
3717 Since in many international keyboards there are exceptions to what some
3718 dead keys should do, you can define them using
3721 \begin_layout Quotation
3722 \begin_inset Flex Code
3725 \begin_layout Plain Layout
3733 deadkey key outstring
3736 \begin_layout Standard
3737 For example, on Slovak keyboard, if you enter caron-o, it generates circumflex-o
3741 \begin_layout Quotation
3742 \begin_inset Flex Code
3745 \begin_layout Plain Layout
3758 \begin_layout Standard
3759 to make it work correctly.
3760 Also, you have to define as exceptions dead keys over i and j, to remove
3761 the dot from them before inserting an accent mark.
3762 I will change this when the time comes, but so far I haven't had time.
3765 \begin_layout Standard
3766 Oh, and about characters: backslash is escaped, so to enter it, you'll need
3769 \begin_inset Flex Code
3772 \begin_layout Plain Layout
3778 have different meaning.
3780 \begin_inset Flex Code
3783 \begin_layout Plain Layout
3789 marks comments, quotes start and end LaTeX-style commands.
3790 To enter quote, you'll need to use
3791 \begin_inset Flex Code
3794 \begin_layout Plain Layout
3803 \begin_inset Flex Code
3806 \begin_layout Plain Layout
3813 \begin_inset Flex Code
3816 \begin_layout Plain Layout
3827 \begin_layout Standard
3828 If you make a keyboard description file that works for your language, please
3829 mail it to me, so I can include it in the next keymap distribution.
3832 \begin_layout Standard
3833 More keywords will be supported in keymap configuration file in future,
3837 \begin_layout Itemize
3838 \begin_inset Flex Code
3841 \begin_layout Plain Layout
3852 \begin_inset space \hfill{}
3856 \begin_inset Flex Code
3859 \begin_layout Plain Layout
3868 \begin_layout Itemize
3869 \begin_inset Flex Code
3872 \begin_layout Plain Layout
3883 \begin_inset space \hfill{}
3887 \begin_inset Flex Code
3890 \begin_layout Plain Layout
3896 an external keymap translation program
3899 \begin_layout Standard
3900 Also, it should look into
3901 \begin_inset Flex Code
3904 \begin_layout Plain Layout
3910 file for defaults, too (for example, a
3911 \begin_inset Flex Code
3914 \begin_layout Plain Layout
3922 option to include default keyboard).
3930 \begin_layout Section
3931 International Keymap Stuff
3932 \begin_inset CommandInset label
3934 name "sec:International-Keymap-Stuff"
3941 \begin_layout Standard
3942 \begin_inset Note Note
3945 \begin_layout Plain Layout
3946 In doing the revisions on this document in March 2008, I did not look over
3947 this stuff, as I do not understand it.
3948 It would be good if someone else could do so.
3957 \begin_layout Standard
3958 The next two sections describe the
3959 \begin_inset Flex Code
3962 \begin_layout Plain Layout
3971 \begin_inset Flex Code
3974 \begin_layout Plain Layout
3982 file syntax in detail.
3983 These sections should help you design your own key map if the ones provided
3984 do not meet your needs.
3987 \begin_layout Subsection
3991 \begin_layout Standard
3995 \begin_inset Flex Code
3998 \begin_layout Plain Layout
4004 file maps keystrokes to characters or strings.
4005 As the name suggests, it sets a keyboard mapping.
4007 \begin_inset Flex Code
4010 \begin_layout Plain Layout
4021 \begin_inset Flex Code
4024 \begin_layout Plain Layout
4039 \begin_inset Flex Code
4042 \begin_layout Plain Layout
4055 \begin_inset Flex Code
4058 \begin_layout Plain Layout
4067 \begin_inset Flex Code
4070 \begin_layout Plain Layout
4078 are described in this section.
4081 \begin_layout Labeling
4082 \labelwidthstring 00.00.0000
4083 \begin_inset Flex Code
4086 \begin_layout Plain Layout
4094 Map a character to a string
4097 \begin_layout LyX-Code
4112 \begin_layout Standard
4145 the double-quote (")
4162 must be escaped with a preceding backslash (
4173 \begin_layout Standard
4175 \begin_inset Flex MenuItem
4178 \begin_layout Plain Layout
4186 statement to cause the symbol
4187 \begin_inset Flex MenuItem
4190 \begin_layout Plain Layout
4198 to be output for the keystroke
4199 \begin_inset Flex MenuItem
4202 \begin_layout Plain Layout
4213 \begin_layout LyX-Code
4219 \begin_layout Labeling
4220 \labelwidthstring 00.00.0000
4221 \begin_inset Flex Code
4224 \begin_layout Plain Layout
4232 Specify an accent character
4235 \begin_layout LyX-Code
4244 \begin_layout Standard
4245 This will make the cha
4283 This is the dead key
4287 \begin_layout Plain Layout
4294 refers to a key that does not produce a character by itself, but when followed
4295 with another key, produces the desired accent character.
4296 For example, a German characte
4298 r with an umlaut like
4308 can be produced in this manner.
4317 \begin_layout Standard
4330 and then another key not in
4347 followed by the other, not allowed key, as output.
4351 \begin_inset Flex MenuItem
4354 \begin_layout Plain Layout
4362 cancels a dead key, so if
4373 \begin_inset Flex MenuItem
4376 \begin_layout Plain Layout
4385 , the cursor will not go one position backwards but will instead cancel
4401 might have had on the next keystroke.
4405 \begin_layout Standard
4406 The following example specifies that the character ' is to be an acute accent,
4407 allowed on the characters a, e, i, o, u, A, E, I, O, and U:
4410 \begin_layout LyX-Code
4413 kmod ' acute aeiouAEIOU
4416 \begin_layout Labeling
4417 \labelwidthstring 00.00.0000
4418 \begin_inset Flex Code
4421 \begin_layout Plain Layout
4427 Specify an exception to the accent character
4430 \begin_layout LyX-Code
4439 \begin_layout Standard
4440 This defines an exce
4481 have been assigned a keystroke with a previous
4484 \begin_inset Flex Code
4487 \begin_layout Plain Layout
4511 must not belong in the
4558 If such a declaration does not exist in
4566 \begin_inset Flex Code
4569 \begin_layout Plain Layout
4603 \begin_inset Flex Code
4606 \begin_layout Plain Layout
4620 \begin_layout Standard
4621 The following command produces causes äi to be produced when you enter acute-i
4625 \begin_layout LyX-Code
4639 \begin_layout Labeling
4640 \labelwidthstring 00.00.0000
4641 \begin_inset Flex Code
4644 \begin_layout Plain Layout
4650 Combine two accent characters
4653 \begin_layout LyX-Code
4659 accent1 accent2 allowed
4662 \begin_layout Standard
4663 This one is getting pretty esoteric.
4664 It allows you to combine the effect
4720 \begin_inset Flex Code
4723 \begin_layout Plain Layout
4751 \begin_layout Standard
4752 Consider this example from the
4753 \begin_inset Flex Code
4756 \begin_layout Plain Layout
4767 \begin_layout LyX-Code
4770 kmod ; acute aeioyvhAEIOYVH
4774 kcomb acute umlaut iyIY
4777 \begin_layout Standard
4778 This allows you to press
4779 \begin_inset Flex MenuItem
4782 \begin_layout Plain Layout
4790 and get the effect of
4791 \begin_inset Flex Code
4794 \begin_layout Plain Layout
4813 in this case cancels the last dead key, so if you press
4814 \begin_inset Flex MenuItem
4817 \begin_layout Plain Layout
4826 \begin_inset Flex Code
4829 \begin_layout Plain Layout
4842 \begin_layout Subsection
4846 \begin_layout Standard
4848 \begin_inset Flex Code
4851 \begin_layout Plain Layout
4859 mapping is performed, a
4860 \begin_inset Flex Code
4863 \begin_layout Plain Layout
4873 file maps the strings that the symbols generate to characters in the current
4875 The LyX distribution currently includes at least the
4876 \begin_inset Flex Code
4879 \begin_layout Plain Layout
4888 \begin_inset Flex Code
4891 \begin_layout Plain Layout
4902 \begin_layout Standard
4904 \begin_inset Flex Code
4907 \begin_layout Plain Layout
4915 file is a sequence of declarations of the form
4918 \begin_layout LyX-Code
4931 \begin_layout Standard
4932 For example, in order to map
4933 \begin_inset Flex MenuItem
4936 \begin_layout Plain Layout
4946 to the corresponding character in the iso-8859-1 set (233), the following
4950 \begin_layout LyX-Code
4958 \begin_layout Standard
4960 \begin_inset Flex Code
4963 \begin_layout Plain Layout
4972 \begin_inset Flex Code
4975 \begin_layout Plain Layout
4993 the same character can apply to more than one string.
4995 \begin_inset Flex Code
4998 \begin_layout Plain Layout
5009 \begin_layout LyX-Code
5021 \begin_inset Newline newline
5037 \begin_layout Standard
5038 If LyX cannot find a mapping for the string produced by the keystroke or
5039 a deadkey sequence, it will check if it looks like an accented char and
5040 try to draw an accent over the character on screen.
5043 \begin_layout Subsection
5047 \begin_layout Standard
5048 There is a second way to add support for international characters through
5049 so-called dead-keys.
5050 A dead-key works in combination with a letter to produce an accented character.
5051 Here, we'll explain how to create a really simple dead-key to illustrate
5055 \begin_layout Standard
5056 Suppose you happen to need the circumflex character,
5057 \begin_inset Quotes eld
5061 \begin_inset Quotes erd
5066 \begin_inset Flex MenuItem
5069 \begin_layout Plain Layout
5076 \begin_inset space ~
5080 \begin_inset Flex MenuItem
5083 \begin_layout Plain Layout
5089 ] to the LyX command
5090 \begin_inset Flex Code
5093 \begin_layout Plain Layout
5100 \begin_inset Flex Code
5103 \begin_layout Plain Layout
5110 Now, whenever you type the
5111 \begin_inset Flex MenuItem
5114 \begin_layout Plain Layout
5120 -key followed by a letter, that letter will have a circumflex accent on
5122 For example, the sequence
5123 \begin_inset Quotes eld
5127 \begin_inset Flex MenuItem
5130 \begin_layout Plain Layout
5137 \begin_inset Quotes erd
5140 produces the letter:
5141 \begin_inset Quotes eld
5145 \begin_inset Quotes erd
5149 If you tried to type
5150 \begin_inset Quotes eld
5154 \begin_inset Flex MenuItem
5157 \begin_layout Plain Layout
5164 \begin_inset Quotes erd
5167 , however, LyX will complain with a beep, since a
5168 \begin_inset Quotes eld
5172 \begin_inset Flex MenuItem
5175 \begin_layout Plain Layout
5182 \begin_inset Quotes erd
5185 never takes a circumflex accent.
5187 \begin_inset Flex MenuItem
5190 \begin_layout Plain Layout
5196 after a dead-key produces the bare-accent.
5197 Please note this last point! If you bind a key to a dead-key, you'll need
5198 to rebind the character on that key to yet another key.
5200 \begin_inset Flex MenuItem
5203 \begin_layout Plain Layout
5209 to a cedilla is a bad idea, since you'll only get cedillas instead of commas.
5212 \begin_layout Standard
5213 One common way to bind dead-keys is to use
5214 \begin_inset Flex MenuItem
5217 \begin_layout Plain Layout
5224 \begin_inset Flex MenuItem
5227 \begin_layout Plain Layout
5234 \begin_inset Flex MenuItem
5237 \begin_layout Plain Layout
5243 in combination with an accent, like
5244 \begin_inset Quotes eld
5248 \begin_inset Flex MenuItem
5251 \begin_layout Plain Layout
5258 \begin_inset Quotes erd
5262 \begin_inset Quotes eld
5266 \begin_inset Flex MenuItem
5269 \begin_layout Plain Layout
5276 \begin_inset Quotes erd
5280 \begin_inset Quotes eld
5284 \begin_inset Flex MenuItem
5287 \begin_layout Plain Layout
5294 \begin_inset Quotes erd
5298 Another way involves using
5299 \begin_inset Flex Code
5302 \begin_layout Plain Layout
5309 \begin_inset Flex Code
5312 \begin_layout Plain Layout
5318 to set up the special
5319 \begin_inset Flex Code
5322 \begin_layout Plain Layout
5330 \begin_inset Flex Code
5333 \begin_layout Plain Layout
5339 acts in some ways just like
5340 \begin_inset Flex MenuItem
5343 \begin_layout Plain Layout
5349 and permits you to bind keys to accented characters.
5350 You can also turn keys into dead-keys by binding them to something like
5352 \begin_inset Flex Code
5355 \begin_layout Plain Layout
5361 and then binding this symbolic key to the corresponding LyX command.
5365 \begin_layout Plain Layout
5370 : This is exactly what I do in my
5371 \begin_inset Flex Code
5374 \begin_layout Plain Layout
5381 \begin_inset Flex Code
5384 \begin_layout Plain Layout
5392 \begin_inset Flex MenuItem
5395 \begin_layout Plain Layout
5397 \begin_inset space ~
5406 \begin_inset Flex Code
5409 \begin_layout Plain Layout
5415 and a bunch of these
5416 \begin_inset Quotes eld
5420 \begin_inset Flex Code
5423 \begin_layout Plain Layout
5430 \begin_inset Quotes erd
5433 symbolic keys bound such things as
5434 \begin_inset Flex MenuItem
5437 \begin_layout Plain Layout
5439 \begin_inset space ~
5448 \begin_inset Flex MenuItem
5451 \begin_layout Plain Layout
5453 \begin_inset space ~
5462 This is how I produce my accented characters.
5467 You can make just about anything into the
5468 \begin_inset Flex Code
5471 \begin_layout Plain Layout
5478 \begin_inset Flex MenuItem
5481 \begin_layout Plain Layout
5487 keys, a spare function key, etc.
5488 As for the LyX commands that produce accents, check the entry for
5489 \begin_inset Flex Code
5492 \begin_layout Plain Layout
5503 You'll find the complete list there.
5506 \begin_layout Subsection
5507 Saving your Language Configuration
5510 \begin_layout Standard
5511 You can edit your preferences so that your desired language environment
5512 is automatically configured when LyX starts up, via the
5513 \begin_inset Flex MenuItem
5516 \begin_layout Plain Layout
5517 Edit\SpecialChar \menuseparator
5526 \begin_layout Chapter
5527 Installing New Document Classes, Layouts, and Templates
5528 \begin_inset CommandInset label
5530 name "cha:Installing-New-Document"
5535 \begin_inset Argument 1
5538 \begin_layout Plain Layout
5539 Installing New Document Classes
5547 \begin_layout Standard
5548 In this chapter, we describe the procedures for creating and installing
5549 new LyX layout and template files, as well as offer a refresher on correctly
5550 installing new LaTeX document classes.
5554 \begin_layout Standard
5555 First, let us a say a few words about how one ought to think about the relation
5556 between LyX and LaTeX.
5557 The thing to understand is that, in a certain sense, LyX doesn't know anything
5559 Indeed, from LyX's point of view, LaTeX is just one of several
5560 \begin_inset Quotes eld
5564 \begin_inset Quotes erd
5567 in which it is capable of producing output.
5568 Other such formats are DocBook, plaintext, and XHTML.
5569 LaTeX is, of course, a particularly important format, but very little of
5570 the information LyX has about LaTeX is actually contained in the program
5575 \begin_layout Plain Layout
5576 Some commands are sufficiently complex that they are
5577 \begin_inset Quotes eld
5581 \begin_inset Quotes erd
5585 But the developers generally regard this as a Bad Thing.
5590 Rather, that information, even for the standard classes like
5591 \begin_inset Flex Code
5594 \begin_layout Plain Layout
5600 , is contained in `layout files'.
5601 Similarly, LyX itself does not know much about DocBook or XHTML.
5602 What it knows is contained in layout files.
5605 \begin_layout Standard
5606 You can think of the layout file for a given document class as a translation
5607 manual between LyX constructs---paragraphs with their corresponding styles,
5608 certain sorts of insets, etc---and the corresponding LaTeX, DocBook, or
5610 Almost everything LyX knows about
5611 \begin_inset Flex Code
5614 \begin_layout Plain Layout
5620 , for example, is contained in the file
5621 \begin_inset Flex Code
5624 \begin_layout Plain Layout
5630 and in various other files it includes.
5631 For this reason, anyone intending to write layout files should plan to
5632 study the existing files.
5633 A good place to start is with
5634 \begin_inset Flex Code
5637 \begin_layout Plain Layout
5643 , which is included in
5644 \begin_inset Flex Code
5647 \begin_layout Plain Layout
5654 \begin_inset Flex Code
5657 \begin_layout Plain Layout
5663 , and many of the other layout files for document classes.
5664 This file is where sections and the like are defined:
5665 \begin_inset Flex Code
5668 \begin_layout Plain Layout
5674 tells LyX how paragraphs that are marked with the Section, Subsection,
5675 etc, styles can be translated into corresponding LaTeX, DocBook, and XHTML
5678 \begin_inset Flex Code
5681 \begin_layout Plain Layout
5687 file basically just includes several of these
5688 \begin_inset Flex Code
5691 \begin_layout Plain Layout
5700 \begin_layout Standard
5701 Defining the LyX--LaTeX correspondence is not the only thing layout files
5703 Their other job is to define how the LyX constructs themselves will appear
5705 The fact that layout files have these two jobs is often a source of confusion,
5706 because they are completely separate.
5707 Telling LyX how to translate a certain paragraph style into LaTeX does
5708 not tell LyX how to display it; conversely, telling LyX how to display
5709 a certain paragraph style does not tell LyX how to translate it into LaTeX
5710 (let alone tell LaTeX how to display it).
5711 So, in general, when you define a new LyX construct, you must always do
5712 two quite separate things: (i)
5713 \begin_inset space ~
5716 tell LyX how to translate it into LaTeX and (ii)
5717 \begin_inset space ~
5720 tell LyX how to display it.
5723 \begin_layout Standard
5724 Much the same is true, of course, as regards LyX's other backend formats,
5725 though XHTML is in some ways different, because in that case LyX
5729 able, to some extent, to use information about how it should display a
5730 paragraph on the screen to output information (in the form of CSS) about
5731 how the paragraph should be displayed in a browser.
5732 Even in this case, however, the distinction between what LyX does internally
5733 and how things are rendered externally remains in force, and the two can
5734 be controlled separately.
5736 \begin_inset CommandInset ref
5738 reference "sec:Tags-for-XHTML"
5745 \begin_layout Section
5746 Installing new LaTeX files
5749 \begin_layout Standard
5750 Some installations may not include a LaTeX package or class file that you
5751 would like to use within LyX.
5752 For example, you might need FoilTeX, a package for preparing slides for
5753 overhead projectors.
5754 Modern LaTeX distributions like TeXLive (2008 or newer) or MiKTeX provide
5755 a user interface for installing such packages.
5756 For example, with MiKTeX, you start the program
5757 \begin_inset Quotes eld
5761 \begin_inset space ~
5765 \begin_inset Quotes erd
5768 to get a list of available packages.
5769 To install one of them, right click on it or use the corresponding toolbar
5773 \begin_layout Standard
5774 If your LaTeX distribution does not provide such a `package manager', or
5775 if the package is not available from your distribution, then follow these
5776 steps to install it manually:
5779 \begin_layout Enumerate
5780 Get the package from
5781 \begin_inset CommandInset href
5784 target "http://www.ctan.org/"
5791 \begin_layout Enumerate
5792 If the package contains a file with the ending
5793 \begin_inset Quotes eld
5797 \begin_inset Flex Code
5800 \begin_layout Plain Layout
5807 \begin_inset Quotes erd
5810 (is the case for FoilTeX) then open a console, change to the folder of
5811 this file and execute the command
5812 \begin_inset Flex Code
5815 \begin_layout Plain Layout
5822 You have now unpacked the package and have all files to install it.
5823 Most LaTeX-packages are not packed and you can skip this step.
5826 \begin_layout Enumerate
5827 Now you need to decide if the package should be available for all users
5832 \begin_layout Enumerate
5833 On *nix systems (Linux, OSX, etc.), if you want the new package to be available
5834 for all users on your system, then install it in your `local' TeX tree,
5835 otherwise install it in your own `user' TeX tree.
5836 Where these trees should be created, if they do not already exist, depends
5838 To find this out, look in the file
5839 \begin_inset Flex Code
5842 \begin_layout Plain Layout
5852 \begin_layout Plain Layout
5853 This is usually in the directory
5854 \begin_inset Flex Code
5857 \begin_layout Plain Layout
5863 , though you can execute the command
5864 \begin_inset Flex Code
5867 \begin_layout Plain Layout
5878 The location of the `local' TeX tree is defined by the
5879 \begin_inset Flex Code
5882 \begin_layout Plain Layout
5888 variable; this is usually somewhere like
5889 \begin_inset Flex Code
5892 \begin_layout Plain Layout
5893 /usr/local/share/texmf
5899 The location of the `user' TeX tree is defined by
5900 \begin_inset Flex Code
5903 \begin_layout Plain Layout
5910 \begin_inset Flex Code
5913 \begin_layout Plain Layout
5920 (If these variables are not predefined, you have to define them.) You'll
5921 probably need root permissions to create or modify the `local' tree, but
5922 not for your `user' tree.
5923 \begin_inset Newline newline
5926 In general, it is recommended to install in the user tree because your user
5927 will not be modified or even overwritten when you upgrade your system.
5928 It will typically also be backed up together with everything else when
5929 you backup your home directory (which, of course, you do on a regular basis).
5932 \begin_layout Enumerate
5933 On Windows, if you want the new package to be available for all users on
5934 your system, change to the folder where LaTeX is installed and then change
5936 \begin_inset Flex Code
5939 \begin_layout Plain Layout
5950 (For MiKTeX, this would be by default the folder
5951 \begin_inset Flex Code
5954 \begin_layout Plain Layout
5972 \begin_layout Plain Layout
5973 Note that this will be the correct path only on English installations.
5974 On a German one, it would be
5975 \begin_inset Flex Code
5978 \begin_layout Plain Layout
5992 , and similarly for other languages.
5997 Create there a new folder
5998 \begin_inset Flex Code
6001 \begin_layout Plain Layout
6007 and copy all files of the package into it.
6009 \begin_inset Newline newline
6012 If the package should only available for you or you don't have admin permissions
6013 , do the same, but in the local LaTeX folder.
6015 \begin_inset space \thinspace{}
6019 \begin_inset space ~
6022 2.8 under Windows XP, this would be the folder:
6023 \begin_inset Newline newline
6029 \begin_inset Flex Code
6032 \begin_layout Plain Layout
6035 Documents and Settings
6047 \begin_inset Newline newline
6053 \begin_inset Phantom HPhantom
6056 \begin_layout Plain Layout
6067 \begin_inset Flex Code
6070 \begin_layout Plain Layout
6083 \begin_inset Newline newline
6086 On Vista, it would be:
6087 \begin_inset Newline newline
6091 \begin_inset Flex Code
6094 \begin_layout Plain Layout
6120 \begin_layout Enumerate
6121 Now one only need to tell LaTeX that there are new files.
6122 This depends on the used LaTeX-Distribution:
6126 \begin_layout Enumerate
6127 For TeXLive execute the command
6128 \begin_inset Flex Code
6131 \begin_layout Plain Layout
6138 If you installed the package for all users, then you will probably need
6139 to have root permissions for that.
6142 \begin_layout Enumerate
6143 For MiKTeX, if you have installed the package for all users, start the program
6145 \begin_inset Quotes eld
6149 \begin_inset space ~
6153 \begin_inset Quotes erd
6156 and press the button marked
6157 \begin_inset Quotes eld
6161 \begin_inset Quotes erd
6165 Otherwise start the program
6166 \begin_inset Quotes eld
6170 \begin_inset Quotes erd
6177 \begin_layout Enumerate
6178 Finally, you need to tell LyX that there are new packages available.
6179 So, in LyX, use the menu
6180 \begin_inset Flex MenuItem
6183 \begin_layout Plain Layout
6186 \SpecialChar \menuseparator
6192 and then restart LyX.
6195 \begin_layout Standard
6196 Now the package is installed.
6197 In our example, the document class
6198 \begin_inset Flex Code
6201 \begin_layout Plain Layout
6203 \begin_inset space ~
6210 \begin_layout Plain Layout
6222 will now be available under
6223 \begin_inset Flex MenuItem
6226 \begin_layout Plain Layout
6227 Document\SpecialChar \menuseparator
6228 Settings\SpecialChar \menuseparator
6238 \begin_layout Standard
6239 If you would like to use a LaTeX document class that is not even listed
6241 \begin_inset Flex MenuItem
6244 \begin_layout Plain Layout
6245 Document\SpecialChar \menuseparator
6246 Settings\SpecialChar \menuseparator
6252 , then you need to create a `layout' file for it.
6253 That is the topic of the next section.
6256 \begin_layout Section
6257 Types of layout files
6260 \begin_layout Standard
6261 This section describes the various sorts of LyX files that contain layout
6263 These files describe various paragraph and character styles, determining
6264 how LyX should display them and how they should be translated into LaTeX,
6265 DocBook, XHTML, or whatever output format is being used.
6269 \begin_layout Standard
6270 We shall try to provide a thorough description of the process of writing
6272 However, there are so many different types of documents supported even
6273 by just LaTeX that we can't hope to cover every different possibility or
6274 problem you might encounter.
6275 The LyX users' list is frequented by people with lots of experience with
6276 layout design who are willing to share what they've learned, so please
6277 feel free to ask questions there.
6280 \begin_layout Standard
6281 As you prepare to write a new layout, it is extremely helpful to look at
6282 the layouts distributed with LyX.
6283 If you write a LyX layout for a LaTeX document class that might also be
6284 used by others, or write a module that might be useful to others, then
6285 you should consider posting your layout to the
6286 \begin_inset CommandInset href
6288 name "layout section on the LyX wiki"
6289 target "http://wiki.lyx.org/Layouts/Layouts"
6293 or even to the LyX developers' list, so that it might be included in LyX
6298 \begin_layout Plain Layout
6299 Note that LyX is licensed under the General Public License, so any material
6300 that is contributed to LyX must be similarly licensed.
6308 \begin_layout Subsection
6310 \begin_inset CommandInset label
6312 name "sub:Layout-modules"
6319 \begin_layout Standard
6320 We have spoken to this point about `layout files'.
6321 But there are different sorts of files that contain layout information.
6322 Layout files, strictly so called, have the
6323 \begin_inset Flex Code
6326 \begin_layout Plain Layout
6332 extension and provide LyX with information about document classes.
6333 As of LyX 1.6, however, layout information can also be contained in layout
6339 \begin_inset Flex Code
6342 \begin_layout Plain Layout
6349 Modules are to LaTeX packages much as layouts are to LaTeX classes, and
6350 some modules—such as the
6351 \begin_inset Flex Code
6354 \begin_layout Plain Layout
6360 module—specifically provide support for one package.
6361 In a sense, layout modules are similar to included
6365 \begin_layout Plain Layout
6366 These can have any extension, but by convention have the
6367 \begin_inset Flex Code
6370 \begin_layout Plain Layout
6382 \begin_inset Flex Code
6385 \begin_layout Plain Layout
6391 —in that modules are not specific to a given document class but may be used
6392 with many different classes.
6393 The difference is that using an included file with
6394 \begin_inset Flex Code
6397 \begin_layout Plain Layout
6403 requires editing that file.
6404 Modules, by contrast, are selected in the
6405 \begin_inset Flex MenuItem
6408 \begin_layout Plain Layout
6409 Document\SpecialChar \menuseparator
6418 \begin_layout Standard
6419 Building modules is the easiest way to get started with layout editing,
6420 since it can be as simple as adding a single new paragraph style or flex
6422 But modules may, in principle, contain anything a layout file can contain.
6425 \begin_layout Standard
6426 After creating a new module and copying it to the
6427 \begin_inset Flex Code
6430 \begin_layout Plain Layout
6436 folder, you will need to reconfigure and then restart LyX for the module
6437 to appear in the menu.
6438 However, changes you make to the module will be seen immediately, if you
6440 \begin_inset Flex MenuItem
6443 \begin_layout Plain Layout
6444 Document\SpecialChar \menuseparator
6450 , highlight something, and then hit
6451 \begin_inset Quotes eld
6455 \begin_inset Quotes erd
6461 It is strongly recommended that you save your work before doing this
6466 it is strongly recommended that you not attempt to edit modules while simultaneo
6467 usly working on actual documents
6470 Though of course the developers strive to keep LyX stable in such situations,
6471 syntax errors and the like in your module file could cause strange behavior.
6474 \begin_layout Subsubsection
6478 \begin_layout Standard
6479 Modules are to LyX as packages are to LaTeX.
6480 Sometimes, however, you find yourself wanting a specific inset or character
6481 style just for one document and writing a module that will also be available
6482 to other documents makes little sense.
6483 What you need is LyX's
6484 \begin_inset Quotes eld
6488 \begin_inset Quotes erd
6494 \begin_layout Standard
6495 You will find it under
6497 Document\SpecialChar \menuseparator
6498 Settings\SpecialChar \menuseparator
6502 The large text box allows you to enter anything that you might enter in
6503 a layout file or module.
6504 You can think of a document's local layout, in fact, as a module that belongs
6506 So, in particular, you must enter a
6507 \begin_inset Flex Code
6510 \begin_layout Plain Layout
6517 Any format is acceptable, but one would normally use the format current
6519 (In LyX 2.0, the current layout format is 35.) You should be aware that local
6520 layout is not supported by versions of LyX prior to 1.6, so you should not
6521 use it if you want to be able to export your document to LyX 1.5 or earlier
6522 (without, that is, losing the local layout information).
6523 If you wish to be able to export to 1.6---local layout is supported in 1.6,
6524 though there is no UI for it---then you should use format 11 and, of course,
6525 use only layout constructs that were available in LyX 1.6.
6528 \begin_layout Standard
6529 When you have entered something in the
6530 \begin_inset Flex Code
6533 \begin_layout Plain Layout
6539 pane, LyX will enable the
6540 \begin_inset Quotes eld
6544 \begin_inset Quotes erd
6547 button at the bottom.
6548 Clicking this button will cause LyX to determine whether what you have
6549 entered is valid layout information for the chosen format.
6550 LyX will report the result but, unfortunately, will not tell you what errors
6551 there might have been.
6552 These will be written to the terminal, however, if LyX is started from
6554 You will not be permitted to save your local layout until you have entered
6558 \begin_layout Standard
6559 The warnings at the end of the previous section apply here, too.
6560 Do not play with local layout while you are actually working, especially
6561 if you have not saved your document.
6562 That said, using local layout with a test document can be a very convenient
6563 way to try out layout ideas, or even to start developing a module.
6566 \begin_layout Subsection
6568 \begin_inset Flex MenuItem
6571 \begin_layout Plain Layout
6580 \begin_layout Standard
6581 There are two situations you are likely to encounter when wanting to support
6582 a new LaTeX document class, involving style (
6583 \begin_inset Flex Code
6586 \begin_layout Plain Layout
6592 ) files and LaTeX2e class (
6593 \begin_inset Flex Code
6596 \begin_layout Plain Layout
6603 Supporting a style file is usually fairly easy.
6604 Supporting a new class file is a bit harder.
6605 We'll discuss the former in this section and the latter in the next.
6606 Similar remarks apply, of course, if you want to support a new DocBook
6610 \begin_layout Standard
6611 The easier case is the one in which your new document class is provided
6612 as a style file that is to be used in conjunction with an already supported
6614 For the sake of the example, we'll assume that the style file is called
6616 \begin_inset Flex MenuItem
6619 \begin_layout Plain Layout
6625 and that it is meant to be used with
6626 \begin_inset Flex MenuItem
6629 \begin_layout Plain Layout
6635 , which is a standard class.
6639 \begin_layout Standard
6640 Start by copying the existing class's layout file into your local directory:
6644 \begin_layout Plain Layout
6645 Of course, which directory is your local directory will vary by platform,
6646 and LyX allows you to specify your local directory on startup, too, using
6648 \begin_inset Flex Code
6651 \begin_layout Plain Layout
6665 \begin_layout LyX-Code
6666 cp report.layout ~/.lyx/layouts/myclass.layout
6669 \begin_layout Standard
6671 \begin_inset Flex Code
6674 \begin_layout Plain Layout
6680 and change the line:
6683 \begin_layout LyX-Code
6686 DeclareLaTeXClass{report}
6689 \begin_layout Standard
6693 \begin_layout LyX-Code
6696 DeclareLaTeXClass[report, myclass.sty]{report (myclass)}
6699 \begin_layout Standard
6703 \begin_layout LyX-Code
6705 \begin_inset Newline newline
6711 \begin_inset Newline newline
6717 \begin_layout Standard
6718 near the top of the file.
6721 \begin_layout Standard
6722 Start LyX and select
6723 \begin_inset Flex MenuItem
6726 \begin_layout Plain Layout
6727 Tools\SpecialChar \menuseparator
6734 Then restart LyX and try creating a new document.
6736 \begin_inset Flex MenuItem
6739 \begin_layout Plain Layout
6745 " as a document class option in the
6746 \begin_inset Flex MenuItem
6749 \begin_layout Plain Layout
6750 Document\SpecialChar \menuseparator
6757 It is likely that some of the sectioning commands and such in your new
6758 class will work differently from how they worked in the base class—
6759 \begin_inset Flex Code
6762 \begin_layout Plain Layout
6768 in this example—so you can fiddle around with the settings for the different
6769 sections if you wish.
6770 The layout information for sections is contained in
6771 \begin_inset Flex Code
6774 \begin_layout Plain Layout
6780 , but you do not need to copy and change this file.
6781 Instead, you can simply add your changes to your layout file, after the
6783 \begin_inset Flex Code
6786 \begin_layout Plain Layout
6792 , which itself includes
6793 \begin_inset Flex Code
6796 \begin_layout Plain Layout
6803 For example, you might add these lines:
6806 \begin_layout LyX-Code
6810 \begin_layout LyX-Code
6814 \begin_layout LyX-Code
6818 \begin_layout LyX-Code
6822 \begin_layout LyX-Code
6826 \begin_layout Standard
6827 to change the font for chapter headings to sans-serif.
6828 This will override (or, in this case, add to) the existing declaration
6829 for the Chapter style.
6833 \begin_layout Standard
6834 Your new package may also provide commands or environments not present in
6836 In this case, you will want to add these to the layout file.
6838 \begin_inset space ~
6842 \begin_inset CommandInset ref
6844 reference "sec:TextClass"
6848 for information on how to do so.
6851 \begin_layout Standard
6853 \begin_inset Flex MenuItem
6856 \begin_layout Plain Layout
6862 can be used with several different document classes, and even if it cannot,
6863 you might find it easiest just to write a module that you can load with
6865 The simplest possible such module would be:
6868 \begin_layout LyX-Code
6871 DeclareLyXModule{My Package}
6874 \begin_layout LyX-Code
6878 \begin_layout LyX-Code
6879 #Support for mypkg.sty.
6882 \begin_layout LyX-Code
6884 \begin_inset Newline newline
6890 \begin_layout LyX-Code
6892 \begin_inset Newline newline
6898 \begin_layout LyX-Code
6900 \begin_inset Newline newline
6906 \begin_inset Newline newline
6912 \begin_layout Standard
6913 A more complex module might modify the behavior of some existing constructs
6914 or define some new ones.
6916 \begin_inset space ~
6920 \begin_inset CommandInset ref
6922 reference "sec:TextClass"
6929 \begin_layout Subsection
6931 \begin_inset Flex MenuItem
6934 \begin_layout Plain Layout
6943 \begin_layout Standard
6944 There are two possibilities here.
6945 One is that the class file is itself based upon an existing document class.
6946 For example, many thesis classes are based upon
6947 \begin_inset Flex MenuItem
6950 \begin_layout Plain Layout
6957 To see whether yours is, look for a line like
6960 \begin_layout LyX-Code
6966 \begin_layout Standard
6968 If so, then you may proceed largely as in the previous section, though
6970 \begin_inset Flex Code
6973 \begin_layout Plain Layout
6979 line will be different.
6980 If your new class is
6981 \begin_inset Flex Code
6984 \begin_layout Plain Layout
6990 and it is based upon
6991 \begin_inset Flex Code
6994 \begin_layout Plain Layout
7000 , then the line should read:
7004 \begin_layout Plain Layout
7005 And it will be easiest if you save the file to
7006 \begin_inset Flex Code
7009 \begin_layout Plain Layout
7015 : LyX assumes that the document class has the same name as the layout file.
7024 \begin_layout LyX-Code
7027 DeclareLaTeXClass[thesis,book]{thesis}
7030 \begin_layout Standard
7031 If, on the other hand, the new class is not based upon an existing class,
7032 you will probably have to
7033 \begin_inset Quotes eld
7037 \begin_inset Quotes erd
7041 We strongly suggest copying an existing layout file which uses a similar
7042 LaTeX class and then modifying it, if you can do so.
7043 At least use an existing file as a starting point so you can find out what
7044 items you need to worry about.
7045 Again, the specifics are covered below.
7048 \begin_layout Subsection
7050 \begin_inset CommandInset label
7052 name "sub:Creating-Templates"
7059 \begin_layout Standard
7060 Once you have written a layout file for a new document class, you might
7061 want to consider writing a
7066 A template acts as a kind of tutorial for your layout, showing how it might
7067 be used, though containing dummy content.
7068 You can of course look at the various templates included with LyX for ideas.
7071 \begin_layout Standard
7072 Templates are created just like usual documents: using LyX.
7073 The only difference is that usual documents contain all possible settings,
7074 including the font scheme and the paper size.
7075 Usually a user doesn't want a template to overwrite his preferred settings
7076 for such parameters.
7077 For that reason, the designer of a template should remove the corresponding
7079 \begin_inset Flex Code
7082 \begin_layout Plain Layout
7091 \begin_inset Flex Code
7094 \begin_layout Plain Layout
7102 from the template LyX file.
7103 This can be done with any simple text-editor, for example
7104 \begin_inset Flex Code
7107 \begin_layout Plain Layout
7114 \begin_inset Flex Code
7117 \begin_layout Plain Layout
7126 \begin_layout Standard
7127 Put the edited template files you create in
7128 \begin_inset Flex Code
7131 \begin_layout Plain Layout
7137 , copy the ones you use from the global template directory in
7138 \begin_inset Flex Code
7141 \begin_layout Plain Layout
7147 to the same place, and redefine the template path in the
7148 \begin_inset Flex MenuItem
7151 \begin_layout Plain Layout
7152 Tools\SpecialChar \menuseparator
7153 Preferences\SpecialChar \menuseparator
7162 \begin_layout Standard
7163 Note, by the way, that there is a template which has a particular meaning:
7165 \begin_inset Flex Code
7168 \begin_layout Plain Layout
7175 This template is loaded every time you create a new document with
7176 \begin_inset Flex MenuItem
7179 \begin_layout Plain Layout
7180 File\SpecialChar \menuseparator
7186 in order to provide useful defaults.
7187 To create this template from inside LyX, all you have to do is to open
7188 a document with the correct settings, and use the
7189 \begin_inset Flex MenuItem
7192 \begin_layout Plain Layout
7193 Save as Document Defaults
7201 \begin_layout Subsection
7202 Upgrading old layout files
7205 \begin_layout Standard
7206 The format of layout files changes with each LyX release, so old layout
7207 files need to be converted to the new format.
7208 If LyX reads a layout file in an older format, it automatically calls the
7210 \begin_inset Flex Code
7213 \begin_layout Plain Layout
7219 to convert it to a temporary file in current format.
7220 The original file is left untouched.
7221 If you use the layout file often, then, you may want to convert it permanently,
7222 so that LyX does not have to do so itself every time.
7223 To do this, you can call the converter manually:
7226 \begin_layout Enumerate
7228 \begin_inset Flex Code
7231 \begin_layout Plain Layout
7238 \begin_inset Flex Code
7241 \begin_layout Plain Layout
7250 \begin_layout Enumerate
7252 \begin_inset Newline newline
7256 \begin_inset Flex Code
7259 \begin_layout Plain Layout
7260 python LyXDir/scripts/layout2layout.py myclass.old myclass.layout
7266 \begin_inset Newline newline
7270 \begin_inset Flex Code
7273 \begin_layout Plain Layout
7279 is the name of your LyX system directory.
7282 \begin_layout Standard
7283 Note that manual conversion does not affect included files, so these will
7284 have to be converted separately.
7287 \begin_layout Section
7288 \begin_inset CommandInset label
7290 name "sec:TextClass"
7294 The layout file format
7297 \begin_layout Standard
7298 The following sections describe how layout files are structured and written.
7299 Our advice is to go slowly, save and test often.
7300 It is really not that hard, except that the multitude of options can become
7301 overwhelming, especially if you try to check out too many at once.
7302 It becomes easier if you use existing layouts of LyX as examples/reference
7303 or if you modify an existing layout to your needs.
7306 \begin_layout Standard
7307 Note that all the tags used in layout files are case-insensitive.
7309 \begin_inset Flex Code
7312 \begin_layout Plain Layout
7319 \begin_inset Flex Code
7322 \begin_layout Plain Layout
7329 \begin_inset Flex Code
7332 \begin_layout Plain Layout
7338 are really the same tag.
7339 The possible arguments are printed in brackets after the tag's name.
7340 The default argument is typeset
7341 \begin_inset Flex Code
7344 \begin_layout Plain Layout
7353 If the argument has a data type like
7354 \begin_inset Quotes eld
7358 \begin_inset Quotes erd
7362 \begin_inset Quotes eld
7366 \begin_inset Quotes erd
7369 , the default is shown like this:
7370 \begin_inset Flex Code
7373 \begin_layout Plain Layout
7384 \begin_layout Subsection
7385 The document class declaration
7386 \change_inserted -712698321 1349766602
7392 \begin_layout Standard
7393 Lines in a layout file which begin with
7394 \begin_inset Flex Code
7397 \begin_layout Plain Layout
7404 There is one exception to this rule.
7406 \begin_inset Flex Code
7409 \begin_layout Plain Layout
7415 files should begin with
7416 \change_deleted -712698321 1349766533
7420 \change_inserted -712698321 1349766536
7426 \begin_layout LyX-Code
7429 #% Do not delete the line below; configure depends on this
7432 \begin_layout LyX-Code
7438 \change_deleted -712698321 1349766193
7440 \change_inserted -712698321 1349766201
7441 Article (Standard Class)
7444 \change_inserted -712698321 1349766538
7448 \begin_layout LyX-Code
7450 \change_inserted -712698321 1349766581
7455 DeclareCategory{Articles}
7460 \begin_layout Standard
7462 \change_inserted -712698321 1349766695
7466 \change_inserted -712698321 1349766626
7470 \change_deleted -712698321 1349766628
7472 \change_inserted -712698321 1349766628
7475 used when you (re)configure LyX.
7476 The layout file is read by the LaTeX script
7477 \begin_inset Flex Code
7480 \begin_layout Plain Layout
7486 , in a special mode where
7487 \begin_inset Flex Code
7490 \begin_layout Plain Layout
7497 The first line is just a LaTeX comment,
7498 \change_deleted -712698321 1349766656
7501 the second one contains the
7502 \change_inserted -712698321 1349766650
7505 declaration of the text class
7506 \change_inserted -712698321 1349766689
7507 , and the third line contains the optional classification of the class
7510 If these lines appear in a file named
7511 \begin_inset Flex Code
7514 \begin_layout Plain Layout
7520 , then they define a text class of name
7521 \begin_inset Flex Code
7524 \begin_layout Plain Layout
7530 (the name of the layout file) which uses the LaTeX document class
7531 \begin_inset Flex Code
7534 \begin_layout Plain Layout
7540 (the default is to use the same name as the layout).
7542 \begin_inset Quotes eld
7546 \change_deleted -712698321 1349766253
7548 \change_inserted -712698321 1349766260
7549 Article (Standard Class)
7552 \begin_inset Quotes erd
7555 that appears above is used as a description of the text class in the
7556 \begin_inset Flex MenuItem
7559 \begin_layout Plain Layout
7560 Document\SpecialChar \menuseparator
7568 \change_inserted -712698321 1349767097
7570 \begin_inset Quotes eld
7574 \begin_inset Quotes erd
7577 in the example) is also used in the
7578 \begin_inset Flex MenuItem
7581 \begin_layout Plain Layout
7583 \change_inserted -712698321 1349766801
7584 Document\SpecialChar \menuseparator
7590 dialog: the text classes are grouped by these categories (which are usually
7591 genres, so typical categories are
7592 \begin_inset Quotes eld
7596 \begin_inset Quotes erd
7600 \begin_inset Quotes eld
7604 \begin_inset Quotes erd
7608 \begin_inset Quotes eld
7612 \begin_inset Quotes erd
7616 \begin_inset Quotes eld
7620 \begin_inset Quotes erd
7624 \begin_inset Quotes eld
7628 \begin_inset Quotes erd
7632 \begin_inset Quotes eld
7636 \begin_inset Quotes erd
7640 If no category has been declared, the class will be put in the
7641 \begin_inset Quotes eld
7645 \begin_inset Quotes erd
7653 \begin_layout Standard
7654 Let's assume that you wrote your own text class that uses the
7655 \begin_inset Flex Code
7658 \begin_layout Plain Layout
7664 document class, but where you changed the appearance of the section headings.
7665 If you put it in a file
7666 \begin_inset Flex Code
7669 \begin_layout Plain Layout
7675 , the header of this file should be:
7678 \begin_layout LyX-Code
7681 #% Do not delete the line below; configure depends on this
7684 \begin_layout LyX-Code
7689 DeclareLaTeXClass[article]{
7690 \change_deleted -712698321 1349766303
7692 \change_inserted -712698321 1349766303
7696 \change_deleted -712698321 1349766338
7698 \change_inserted -712698321 1349766338
7702 \change_deleted -712698321 1349766340
7704 \change_inserted -712698321 1349766340
7708 \change_deleted -712698321 1349766343
7710 \change_inserted -712698321 1349766343
7714 \change_inserted -712698321 1349767223
7718 \begin_layout LyX-Code
7720 \change_inserted -712698321 1349767223
7725 DeclareCategory{Articles}
7730 \begin_layout Standard
7731 This declares a text class
7732 \begin_inset Flex Code
7735 \begin_layout Plain Layout
7741 , associated with the LaTeX document class
7742 \begin_inset Flex Code
7745 \begin_layout Plain Layout
7752 \begin_inset Quotes eld
7756 \change_deleted -712698321 1349766329
7758 \change_inserted -712698321 1349766329
7762 \change_deleted -712698321 1349766347
7764 \change_inserted -712698321 1349766347
7768 \change_deleted -712698321 1349766350
7770 \change_inserted -712698321 1349766350
7774 \change_deleted -712698321 1349766352
7776 \change_inserted -712698321 1349766352
7780 \begin_inset Quotes erd
7784 If your text class depends on several packages, you can declare it as:
7787 \begin_layout LyX-Code
7790 #% Do not delete the line below; configure depends on this
7793 \begin_layout LyX-Code
7798 DeclareLaTeXClass[article,foo.sty]{
7799 \change_deleted -712698321 1349766366
7801 \change_inserted -712698321 1349766366
7805 \change_deleted -712698321 1349766369
7807 \change_inserted -712698321 1349766369
7811 \change_deleted -712698321 1349766371
7813 \change_inserted -712698321 1349766371
7817 \change_deleted -712698321 1349766374
7819 \change_inserted -712698321 1349766374
7823 \change_inserted -712698321 1349767240
7827 \begin_layout LyX-Code
7829 \change_inserted -712698321 1349767240
7834 DeclareCategory{Articles}
7839 \begin_layout Standard
7840 This indicates that your text class uses the
7841 \begin_inset Flex Code
7844 \begin_layout Plain Layout
7851 Finally, it is also possible to declare classes for DocBook code.
7852 Typical declarations will look like:
7855 \begin_layout LyX-Code
7858 #% Do not delete the line below; configure depends on this
7861 \begin_layout LyX-Code
7866 DeclareDocBookClass[article]{SGML (DocBook
7867 \change_deleted -712698321 1349766387
7869 \change_inserted -712698321 1349766387
7873 \change_inserted -712698321 1349767247
7877 \begin_layout LyX-Code
7879 \change_inserted -712698321 1349767302
7884 DeclareCategory{Articles (DocBook)}
7889 \begin_layout Standard
7890 Note that these declarations can also be given an optional parameter declaring
7891 the name of the document class (but not a list).
7894 \begin_layout Standard
7895 So, to be as explicit as possible, the form of the layout declaration is:
7898 \begin_layout LyX-Code
7903 DeclareLaTeXClass[class,package.sty]{layout description}
7904 \change_inserted -712698321 1349767329
7908 \begin_layout LyX-Code
7910 \change_inserted -712698321 1349767339
7915 DeclareCategory{category}
7920 \begin_layout Standard
7921 The class need only be specified if the name of the LaTeX class file and
7922 the name of the layout file are different or if there are packages to load.
7923 If the name of the class file is not specified, then LyX will simply assume
7924 that it is the same as the name of the layout file.
7927 \begin_layout Standard
7928 When the text class has been modified to your taste, all you have to do
7929 is to copy it either to
7930 \begin_inset Flex Code
7933 \begin_layout Plain Layout
7940 \begin_inset Flex Code
7943 \begin_layout Plain Layout
7950 \begin_inset Flex MenuItem
7953 \begin_layout Plain Layout
7954 Tools\SpecialChar \menuseparator
7960 , exit LyX and restart.
7961 Then your new text class should be available along with the others.
7964 \begin_layout Standard
7965 Once the layout file is installed, you can edit it and see your changes
7966 without having to reconfigure or to restart LyX.
7971 \begin_layout Plain Layout
7972 In versions of LyX prior to 1.6, this was not true.
7973 As a result, editing layout files was very time consuming, since you had
7974 constantly to restart LyX to see changes.
7979 You can force a reload of the current layout by using the LyX function
7981 \begin_inset Flex MenuItem
7984 \begin_layout Plain Layout
7991 There is no default binding for this function—though, of course, you can
7992 bind it to a key yourself.
7993 But you will normally use this function simply by entering it in the mini-buffe
7998 \begin_layout Standard
8004 \begin_inset Flex MenuItem
8007 \begin_layout Plain Layout
8013 is very much an `advanced feature'.
8018 recommended that you save your work before using this function.
8023 recommended that you not attempt to edit layout information while simultaneousl
8024 y working on a document that you care about.
8025 Use a test document.
8026 Syntax errors and the like in your layout file could cause peculiar behavior.
8027 In particular, such errors could cause LyX to regard the current layout
8028 as invalid and to attempt to switch to some other layout.
8032 \begin_layout Plain Layout
8033 Really bad syntax errors may even caused LyX to exit.
8034 This is because certain sorts of errors may make LyX unable to read
8044 The LyX team strives to keep LyX stable in such situations, but safe is
8049 \begin_layout Plain Layout
8050 While we're giving advice: make regular backups.
8051 And be nice to your mother.
8059 \begin_layout Subsection
8060 The Module declaration
8063 \begin_layout Standard
8064 A module must begin with a line like the following:
8067 \begin_layout LyX-Code
8070 DeclareLyXModule[endnotes.sty]{Endnotes}
8073 \begin_layout Standard
8074 The mandatory argument, in curly brackets, is the name of the module, as
8076 \begin_inset Flex MenuItem
8079 \begin_layout Plain Layout
8080 Document\SpecialChar \menuseparator
8081 Settings\SpecialChar \menuseparator
8088 The argument in square brackets is optional: It declares any LaTeX packages
8089 on which the module depends.
8090 It is also possible to use the form
8091 \begin_inset Flex MenuItem
8094 \begin_layout Plain Layout
8100 as an optional argument, which declares that the module can only be used
8101 when there exists a conversion chain between the formats `
8102 \begin_inset Flex Code
8105 \begin_layout Plain Layout
8112 \begin_inset Flex Code
8115 \begin_layout Plain Layout
8124 \begin_layout Standard
8125 The module declaration should then be followed by lines like the following
8129 \begin_layout Plain Layout
8130 Preferably in English if the module should be published with LyX.
8131 This description will appear in the list of messages to be translated and
8132 will be thus translated with the next interface update.
8140 \begin_layout LyX-Code
8144 \begin_layout LyX-Code
8145 #Adds an endnote command, in addition to footnotes.
8149 \begin_layout LyX-Code
8150 #You will need to add
8152 theendnotes in TeX code where you
8155 \begin_layout LyX-Code
8156 #want the endnotes to appear.
8160 \begin_layout LyX-Code
8164 \begin_layout LyX-Code
8165 #Requires: somemodule | othermodule
8168 \begin_layout LyX-Code
8169 #Excludes: badmodule
8172 \begin_layout Standard
8173 The description is used in
8174 \begin_inset Flex MenuItem
8177 \begin_layout Plain Layout
8178 Document\SpecialChar \menuseparator
8179 Settings\SpecialChar \menuseparator
8185 to provide the user with information about what the module does.
8187 \begin_inset Flex Code
8190 \begin_layout Plain Layout
8196 line is used to identify other modules with which this one must be used;
8198 \begin_inset Flex Code
8201 \begin_layout Plain Layout
8207 line is used to identify modules with which this one may not be used.
8208 Both are optional, and, as shown, multiple modules should be separated
8209 with the pipe symbol: |.
8210 Note that the required modules are treated disjunctively:
8214 of the required modules must be used.
8219 excluded module may be used.
8220 Note that modules are identified here by their filenames without the
8221 \begin_inset Flex Code
8224 \begin_layout Plain Layout
8232 \begin_inset Flex Code
8235 \begin_layout Plain Layout
8242 \begin_inset Flex Code
8245 \begin_layout Plain Layout
8254 \begin_layout Subsection
8258 \begin_layout Standard
8259 The first non-comment line of any layout file, included file, or module
8264 contain the file format number:
8267 \begin_layout Description
8268 \begin_inset Flex Code
8271 \begin_layout Plain Layout
8278 \begin_inset Flex Code
8281 \begin_layout Plain Layout
8287 ] The format number of the layout file.
8290 \begin_layout Standard
8291 This tag was introduced with LyX
8292 \begin_inset space ~
8296 Layout files from older LyX versions do not have an explicit file format
8297 and are considered to have
8298 \begin_inset Flex Code
8301 \begin_layout Plain Layout
8303 \begin_inset space ~
8312 The format for the present version of LyX is format 35.
8313 But each version of LyX is capable of reading earlier versions' layout
8314 files, just as they are capable of reading files produced by earlier versions
8316 There is, however, no provision for converting to earlier formats.
8319 \begin_layout Subsection
8320 \begin_inset CommandInset label
8322 name "sub:General-text-class"
8326 General text class parameters
8329 \begin_layout Standard
8330 These are general parameters that govern the behavior of an entire document
8336 mean that they must appear in
8337 \begin_inset Flex Code
8340 \begin_layout Plain Layout
8346 files rather than in modules.
8347 A module can contain any layout tag.)
8350 \begin_layout Description
8351 \begin_inset Flex Code
8354 \begin_layout Plain Layout
8360 Adds information that will be output in the
8361 \begin_inset Flex Code
8364 \begin_layout Plain Layout
8370 block when the document is output to XHTML.
8371 Typically, this would be used to output CSS style information, but it can
8372 be used for anything that can appear in
8373 \begin_inset Flex Code
8376 \begin_layout Plain Layout
8384 \begin_inset Quotes eld
8388 \begin_inset Flex Code
8391 \begin_layout Plain Layout
8398 \begin_inset Quotes erd
8404 \begin_layout Description
8405 \begin_inset Flex Code
8408 \begin_layout Plain Layout
8414 Adds information to the document preamble.
8416 \begin_inset Newline newline
8420 \begin_inset Quotes eld
8424 \begin_inset Flex Code
8427 \begin_layout Plain Layout
8434 \begin_inset Quotes erd
8440 \begin_layout Description
8441 \begin_inset Flex Code
8444 \begin_layout Plain Layout
8450 Defines formats for use in the display of bibliographic information.
8452 \begin_inset CommandInset ref
8454 reference "sub:Citation-format-description"
8460 \begin_inset Quotes eld
8464 \begin_inset Flex Code
8467 \begin_layout Plain Layout
8474 \begin_inset Quotes erd
8480 \begin_layout Description
8481 \begin_inset Flex Code
8484 \begin_layout Plain Layout
8490 Describes various global options supported by the document class.
8492 \begin_inset space ~
8496 \begin_inset CommandInset ref
8498 reference "sub:ClassOptions"
8504 \begin_inset Quotes eld
8508 \begin_inset Flex Code
8511 \begin_layout Plain Layout
8518 \begin_inset Quotes erd
8524 \begin_layout Description
8525 \begin_inset Flex Code
8528 \begin_layout Plain Layout
8535 \begin_inset Flex Code
8538 \begin_layout Plain Layout
8547 \begin_inset space \thinspace{}
8551 \begin_inset Flex Code
8554 \begin_layout Plain Layout
8560 ] Whether the class should
8564 to having one or two columns.
8565 Can be changed in the
8566 \begin_inset Flex MenuItem
8569 \begin_layout Plain Layout
8570 Document\SpecialChar \menuseparator
8579 \begin_layout Description
8580 \begin_inset Flex Code
8583 \begin_layout Plain Layout
8590 \begin_inset Flex Code
8593 \begin_layout Plain Layout
8599 ] This sequence defines the properties for a counter.
8600 If the counter does not yet exist, it is created; if it does exist, it
8603 \begin_inset Quotes eld
8607 \begin_inset Flex Code
8610 \begin_layout Plain Layout
8617 \begin_inset Quotes erd
8621 \begin_inset Newline newline
8625 \begin_inset space ~
8629 \begin_inset CommandInset ref
8631 reference "sub:Counters"
8635 for details on counters.
8638 \begin_layout Description
8639 \begin_inset Flex Code
8642 \begin_layout Plain Layout
8648 Sets the default font used to display the document.
8650 \begin_inset space ~
8654 \begin_inset CommandInset ref
8656 reference "sub:Font-description"
8660 for how to declare fonts.
8662 \begin_inset Quotes eld
8666 \begin_inset Flex Code
8669 \begin_layout Plain Layout
8676 \begin_inset Quotes erd
8682 \begin_layout Description
8683 \begin_inset Flex Code
8686 \begin_layout Plain Layout
8693 \begin_inset Flex Code
8696 \begin_layout Plain Layout
8702 ] Specifies a module to be included by default with this document class.
8703 The module is specified as filename without the
8704 \begin_inset Flex Code
8707 \begin_layout Plain Layout
8714 The user can still remove the module, but it will be active at the outset.
8715 (This applies only when new files are created, or when this class is chosen
8716 for an existing document.)
8719 \begin_layout Description
8720 \begin_inset Flex Code
8723 \begin_layout Plain Layout
8730 \begin_inset Flex Code
8733 \begin_layout Plain Layout
8739 ] This is the style that will be assigned to new paragraphs, usually
8740 \begin_inset Flex MenuItem
8743 \begin_layout Plain Layout
8750 This will default to the first defined style if not given, but you are
8751 encouraged to use this directive.
8754 \begin_layout Description
8755 \begin_inset Flex Code
8758 \begin_layout Plain Layout
8765 \begin_inset Flex Code
8768 \begin_layout Plain Layout
8774 ] This tag indicates that the module (which is specified by filename without
8776 \begin_inset Flex Code
8779 \begin_layout Plain Layout
8785 extension) cannot be used with this document class.
8786 This might be used in a journal-specific layout file to prevent, say, the
8788 \begin_inset Flex Code
8791 \begin_layout Plain Layout
8797 module that numbers theorems by section.
8802 be used in a module.
8803 Modules have their own way of excluding other modules (see section
8804 \begin_inset space ~
8808 \begin_inset CommandInset ref
8810 reference "sub:Layout-modules"
8817 \begin_layout Description
8818 \begin_inset Flex Code
8821 \begin_layout Plain Layout
8827 Defines a new float.
8829 \begin_inset space ~
8833 \begin_inset CommandInset ref
8835 reference "sub:Floats"
8841 \begin_inset Quotes eld
8845 \begin_inset Flex Code
8848 \begin_layout Plain Layout
8855 \begin_inset Quotes erd
8861 \begin_layout Description
8862 \begin_inset Flex Code
8865 \begin_layout Plain Layout
8871 Sets the information that will be output in the
8872 \begin_inset Flex Code
8875 \begin_layout Plain Layout
8881 block when this document class is output to XHTML.
8882 Note that this will completely override any prior
8883 \begin_inset Flex Code
8886 \begin_layout Plain Layout
8893 \begin_inset Flex Code
8896 \begin_layout Plain Layout
8904 \begin_inset Newline newline
8908 \begin_inset Flex Code
8911 \begin_layout Plain Layout
8917 if you just want to add material to the preamble.) Must end with
8918 \begin_inset Quotes eld
8922 \begin_inset Flex Code
8925 \begin_layout Plain Layout
8932 \begin_inset Quotes erd
8938 \begin_layout Description
8939 \begin_inset Flex Code
8942 \begin_layout Plain Layout
8949 \begin_inset Flex Code
8952 \begin_layout Plain Layout
8958 ] The style to use for the table of contents, bibliography, and so forth,
8959 when the document is output to HTML.
8960 For articles, this should normally be
8961 \begin_inset Flex Code
8964 \begin_layout Plain Layout
8971 \begin_inset Flex Code
8974 \begin_layout Plain Layout
8981 If it is not given, then LyX will attempt to figure out which layout to
8985 \begin_layout Description
8986 \begin_inset Flex Code
8989 \begin_layout Plain Layout
8996 \begin_inset Flex Code
8999 \begin_layout Plain Layout
9005 ] Modifies the properties of the given counter.
9006 If the counter does not exist, the statement is ignored.
9008 \begin_inset Quotes eld
9012 \begin_inset Flex Code
9015 \begin_layout Plain Layout
9022 \begin_inset Quotes erd
9026 \begin_inset Newline newline
9030 \begin_inset space ~
9034 \begin_inset CommandInset ref
9036 reference "sub:Counters"
9040 for details on counters.
9043 \begin_layout Description
9044 \begin_inset Flex Code
9047 \begin_layout Plain Layout
9054 \begin_inset Flex Code
9057 \begin_layout Plain Layout
9063 ] Modifies the properties of the given paragraph style.
9064 If the style does not exist, the statement is ignored.
9066 \begin_inset Quotes eld
9070 \begin_inset Flex Code
9073 \begin_layout Plain Layout
9080 \begin_inset Quotes erd
9086 \begin_layout Description
9087 \begin_inset Flex Code
9090 \begin_layout Plain Layout
9097 \begin_inset Flex Code
9100 \begin_layout Plain Layout
9106 ] This allows you to include another layout definition file within yours
9107 to avoid duplicating commands.
9108 Common examples are the standard layout files, for example,
9109 \begin_inset Flex Code
9112 \begin_layout Plain Layout
9118 , which contains most of the basic layouts.
9121 \begin_layout Description
9122 \begin_inset Flex Code
9125 \begin_layout Plain Layout
9132 \begin_inset Flex Code
9135 \begin_layout Plain Layout
9141 ] This section (re-)defines the layout of an inset.
9142 It can be applied to an existing inset or to a new, user-defined inset,
9143 e.g., a new character style.
9145 \begin_inset Quotes eld
9149 \begin_inset Flex Code
9152 \begin_layout Plain Layout
9159 \begin_inset Quotes erd
9163 \begin_inset Newline newline
9167 \begin_inset space ~
9171 \begin_inset CommandInset ref
9173 reference "sub:Flex-insets-and"
9177 for more information.
9181 \begin_layout Description
9182 \begin_inset Flex Code
9185 \begin_layout Plain Layout
9192 \begin_inset Flex Code
9195 \begin_layout Plain Layout
9201 ] A string that indicates the width of the left margin on the screen, for
9203 \begin_inset Quotes eld
9207 \begin_inset Flex Code
9210 \begin_layout Plain Layout
9217 \begin_inset Quotes erd
9221 (Note that this is not a `length', like
9222 \begin_inset Quotes eld
9226 \begin_inset Quotes erd
9232 \begin_layout Description
9233 \begin_inset Flex Code
9236 \begin_layout Plain Layout
9243 \begin_inset Flex Code
9246 \begin_layout Plain Layout
9252 ] Deletes an existing counter, usually one defined in an included file.
9255 \begin_layout Description
9256 \begin_inset Flex Code
9259 \begin_layout Plain Layout
9266 \begin_inset Flex Code
9269 \begin_layout Plain Layout
9275 ] Deletes an existing float.
9276 This is particularly useful when you want to suppress a float that has
9277 been defined in an input file.
9280 \begin_layout Description
9281 \begin_inset Flex Code
9284 \begin_layout Plain Layout
9291 \begin_inset Flex Code
9294 \begin_layout Plain Layout
9300 ] Deletes an existing style.
9303 \begin_layout Description
9304 \begin_inset Flex Code
9307 \begin_layout Plain Layout
9314 \begin_inset Flex Code
9317 \begin_layout Plain Layout
9323 ] The file format (as defined in the LyX preferences) produced by this document
9325 It is mainly useful when
9326 \begin_inset Flex Code
9329 \begin_layout Plain Layout
9336 \begin_inset Flex Code
9339 \begin_layout Plain Layout
9345 and one wants to define a new type of literate document.
9346 The format is reset to
9347 \begin_inset Quotes eld
9351 \begin_inset Flex Code
9354 \begin_layout Plain Layout
9361 \begin_inset Quotes erd
9365 \begin_inset Quotes eld
9369 \begin_inset Flex Code
9372 \begin_layout Plain Layout
9379 \begin_inset Quotes erd
9382 when the corresponding
9383 \begin_inset Flex Code
9386 \begin_layout Plain Layout
9392 parameter is encountered.
9395 \begin_layout Description
9396 \begin_inset Flex Code
9399 \begin_layout Plain Layout
9406 \begin_inset Flex Code
9409 \begin_layout Plain Layout
9420 \begin_inset Flex Code
9423 \begin_layout Plain Layout
9430 \begin_inset Flex Code
9433 \begin_layout Plain Layout
9439 ] Specifies what sort of output documents using this class will produce.
9442 \begin_layout Description
9443 \begin_inset Flex Code
9446 \begin_layout Plain Layout
9453 \begin_inset Flex Code
9456 \begin_layout Plain Layout
9465 \begin_inset Flex Code
9468 \begin_layout Plain Layout
9475 \begin_inset Flex Code
9478 \begin_layout Plain Layout
9484 ] The default pagestyle.
9485 Can be changed in the
9486 \begin_inset Flex MenuItem
9489 \begin_layout Plain Layout
9490 Document\SpecialChar \menuseparator
9499 \begin_layout Description
9500 \begin_inset Flex Code
9503 \begin_layout Plain Layout
9509 Sets the preamble for the LaTeX document.
9510 Note that this will completely override any prior
9511 \begin_inset Flex Code
9514 \begin_layout Plain Layout
9521 \begin_inset Flex Code
9524 \begin_layout Plain Layout
9532 \begin_inset Flex Code
9535 \begin_layout Plain Layout
9541 if you just want to add material to the preamble.) Must end with
9542 \begin_inset Quotes eld
9546 \begin_inset Flex Code
9549 \begin_layout Plain Layout
9556 \begin_inset Quotes erd
9562 \begin_layout Description
9563 \begin_inset Flex Code
9566 \begin_layout Plain Layout
9573 \begin_inset Flex Code
9576 \begin_layout Plain Layout
9583 \begin_inset Flex Code
9586 \begin_layout Plain Layout
9595 \begin_inset space \thinspace{}
9599 \begin_inset Flex Code
9602 \begin_layout Plain Layout
9608 ] Whether the class already provides the feature
9609 \begin_inset Flex Code
9612 \begin_layout Plain Layout
9619 A feature is in general the name of a package (e.
9620 \begin_inset space \thinspace{}
9624 \begin_inset space \space{}
9628 \begin_inset Flex Code
9631 \begin_layout Plain Layout
9638 \begin_inset Flex Code
9641 \begin_layout Plain Layout
9648 \begin_inset space \thinspace{}
9652 \begin_inset space \space{}
9656 \begin_inset Flex Code
9659 \begin_layout Plain Layout
9666 \begin_inset Flex Code
9669 \begin_layout Plain Layout
9677 \begin_inset space ~
9681 \begin_inset CommandInset ref
9683 reference "chap:List-of-functions"
9687 for the list of features.
9690 \begin_layout Description
9691 \begin_inset Flex Code
9694 \begin_layout Plain Layout
9701 \begin_inset Flex Code
9704 \begin_layout Plain Layout
9710 ] Indicates that this layout provides the functionality of the module mentioned,
9711 which should be specified by the filename without the
9712 \begin_inset Flex Code
9715 \begin_layout Plain Layout
9722 This will typically be used if the layout includes the module directly,
9723 rather than using the
9724 \begin_inset Flex Code
9727 \begin_layout Plain Layout
9733 tag to indicate that it ought to be used.
9734 It could also be used in a module that provided an alternate implementation
9735 of the same functionality.
9738 \begin_layout Description
9739 \begin_inset Flex Code
9742 \begin_layout Plain Layout
9749 \begin_inset Flex Code
9752 \begin_layout Plain Layout
9758 ] Whether the class requires the feature
9759 \begin_inset Flex Code
9762 \begin_layout Plain Layout
9769 Multiple features must be separated by commas.
9770 Note that you can only request supported features.
9772 \begin_inset space ~
9776 \begin_inset CommandInset ref
9778 reference "chap:List-of-functions"
9782 for the list of features.)
9785 \begin_layout Description
9786 \begin_inset Flex Code
9789 \begin_layout Plain Layout
9796 \begin_inset Flex Code
9799 \begin_layout Plain Layout
9805 ] A string that indicates the width of the right margin on the screen, for
9807 \begin_inset Quotes eld
9811 \begin_inset Flex Code
9814 \begin_layout Plain Layout
9821 \begin_inset Quotes erd
9827 \begin_layout Description
9828 \begin_inset Flex Code
9831 \begin_layout Plain Layout
9838 \begin_inset Flex Code
9841 \begin_layout Plain Layout
9847 ] Sets which divisions get numbered.
9849 \begin_inset Newline newline
9853 \begin_inset Flex Code
9856 \begin_layout Plain Layout
9865 \begin_layout Description
9866 \begin_inset Flex Code
9869 \begin_layout Plain Layout
9876 \begin_inset Flex Code
9879 \begin_layout Plain Layout
9888 \begin_inset space \thinspace{}
9892 \begin_inset Flex Code
9895 \begin_layout Plain Layout
9901 ] Whether the class-default should be printing on one or both sides of the
9903 Can be changed in the
9904 \begin_inset Flex MenuItem
9907 \begin_layout Plain Layout
9908 Document\SpecialChar \menuseparator
9917 \begin_layout Description
9918 \begin_inset Flex Code
9921 \begin_layout Plain Layout
9928 \begin_inset Flex Code
9931 \begin_layout Plain Layout
9937 ] This sequence defines a paragraph style.
9938 If the style does not yet exist, it is created; if it does exist, its parameter
9941 \begin_inset Quotes eld
9945 \begin_inset Flex Code
9948 \begin_layout Plain Layout
9955 \begin_inset Quotes erd
9959 \begin_inset Newline newline
9963 \begin_inset space ~
9967 \begin_inset CommandInset ref
9969 reference "sub:Paragraph-Styles"
9973 for details on paragraph styles.
9976 \begin_layout Description
9977 \begin_inset Flex Code
9980 \begin_layout Plain Layout
9987 \begin_inset Flex Code
9990 \begin_layout Plain Layout
9996 ] The name of the command or environment to be used with
9997 \begin_inset Flex Code
10000 \begin_layout Plain Layout
10009 \begin_layout Description
10010 \begin_inset Flex Code
10013 \begin_layout Plain Layout
10020 \begin_inset Flex Code
10023 \begin_layout Plain Layout
10032 \begin_inset Flex Code
10035 \begin_layout Plain Layout
10041 ] Indicates what kind of markup is used to define the title of a document.
10043 \begin_inset Flex Code
10046 \begin_layout Plain Layout
10052 means that the macro with name
10053 \begin_inset Flex Code
10056 \begin_layout Plain Layout
10062 will be inserted after the last layout which has
10063 \begin_inset Quotes eld
10067 \begin_inset Flex Code
10070 \begin_layout Plain Layout
10072 \begin_inset space ~
10081 \begin_inset Quotes erd
10086 \begin_inset Flex Code
10089 \begin_layout Plain Layout
10095 corresponds to the case where all layouts which have
10096 \begin_inset Quotes eld
10100 \begin_inset Flex Code
10103 \begin_layout Plain Layout
10105 \begin_inset space ~
10114 \begin_inset Quotes erd
10117 should be enclosed into the
10118 \begin_inset Flex Code
10121 \begin_layout Plain Layout
10130 \begin_layout Description
10131 \begin_inset Flex Code
10134 \begin_layout Plain Layout
10141 \begin_inset Flex Code
10144 \begin_layout Plain Layout
10150 ] Sets which divisions are included in the table of contents.
10152 \begin_inset Flex Code
10155 \begin_layout Plain Layout
10164 \begin_layout Subsection
10165 \begin_inset Flex Code
10168 \begin_layout Plain Layout
10175 \begin_inset CommandInset label
10177 name "sub:ClassOptions"
10184 \begin_layout Standard
10186 \begin_inset Flex Code
10189 \begin_layout Plain Layout
10195 section can contain the following entries:
10198 \begin_layout Description
10199 \begin_inset Flex Code
10202 \begin_layout Plain Layout
10209 \begin_inset Flex Code
10212 \begin_layout Plain Layout
10218 ] The list of available font sizes for the document's main font, separated
10220 \begin_inset Quotes eld
10224 \begin_inset Flex Code
10227 \begin_layout Plain Layout
10234 \begin_inset Quotes erd
10240 \begin_layout Description
10241 \begin_inset Flex Code
10244 \begin_layout Plain Layout
10250 Used to set the DTD line with XML-based output classes.
10252 \begin_inset space \thinspace{}
10256 \begin_inset Quotes eld
10259 -//OASIS//DTD DocBook V4.2//EN
10260 \begin_inset Quotes erd
10266 \begin_layout Description
10267 \begin_inset Flex Code
10270 \begin_layout Plain Layout
10277 \begin_inset Flex Code
10280 \begin_layout Plain Layout
10281 string="empty|plain|headings|fancy"
10286 ] The list of available page sty\SpecialChar \-
10288 \begin_inset Quotes eld
10292 \begin_inset Flex Code
10295 \begin_layout Plain Layout
10302 \begin_inset Quotes erd
10308 \begin_layout Description
10309 \begin_inset Flex Code
10312 \begin_layout Plain Layout
10319 \begin_inset Flex Code
10322 \begin_layout Plain Layout
10328 ] Some document class options, separated by a comma, that will be added
10329 to the optional part of the
10330 \begin_inset Flex Code
10333 \begin_layout Plain Layout
10344 \begin_layout Standard
10346 \begin_inset Flex Code
10349 \begin_layout Plain Layout
10355 section must end with
10356 \begin_inset Quotes eld
10360 \begin_inset Flex Code
10363 \begin_layout Plain Layout
10370 \begin_inset Quotes erd
10376 \begin_layout Subsection
10378 \begin_inset CommandInset label
10380 name "sub:Paragraph-Styles"
10387 \begin_layout Standard
10388 A paragraph style description looks like this:
10392 \begin_layout Plain Layout
10393 Note that this will either define a new style or modify an existing one.
10401 \begin_layout LyX-Code
10408 \begin_layout LyX-Code
10412 \begin_layout LyX-Code
10416 \begin_layout Standard
10417 where the following commands are allowed:
10420 \begin_layout Description
10421 \begin_inset Flex Code
10424 \begin_layout Plain Layout
10431 \begin_inset Flex Code
10434 \begin_layout Plain Layout
10439 , left, right, center
10444 ] Paragraph alignment.
10447 \begin_layout Description
10448 \begin_inset Flex Code
10451 \begin_layout Plain Layout
10458 \begin_inset Flex Code
10461 \begin_layout Plain Layout
10466 , left, right, center
10471 ] A comma separated list of permitted alignments.
10472 (Some LaTeX styles prohibit certain alignments, since those wouldn't make
10474 For example a right-aligned or centered enumeration isn't possible.)
10475 \change_inserted -712698321 1353679769
10479 \begin_layout Description
10481 \change_inserted -712698321 1353680268
10482 \begin_inset Flex Code
10485 \begin_layout Plain Layout
10487 \change_inserted -712698321 1353679781
10494 \begin_inset Flex Code
10497 \begin_layout Plain Layout
10499 \change_inserted -712698321 1353679772
10505 ] Defines argument number <int> of a command\SpecialChar \slash{}
10506 environment associated with
10508 This is useful for things like section headings, and only makes sense with
10510 Every (optional or required) argument of a command or environment -- except
10511 for the required argument that is associated with the content of the paragraph
10512 itself -- has a separate definition, where the number specifies the order
10514 The definition must end with
10515 \begin_inset Flex Code
10518 \begin_layout Plain Layout
10520 \change_inserted -712698321 1353680069
10527 So a command with two optional arguments has:
10531 \begin_layout Quote
10533 \change_inserted -712698321 1353680127
10539 \begin_layout Quote
10541 \change_inserted -712698321 1353680195
10547 \begin_layout Quote
10549 \change_inserted -712698321 1353680135
10555 \begin_layout Quote
10557 \change_inserted -712698321 1353680140
10563 \begin_layout Quote
10565 \change_inserted -712698321 1353680197
10571 \begin_layout Quote
10573 \change_inserted -712698321 1353680147
10579 \begin_layout Standard
10581 \change_inserted -712698321 1353680528
10583 \begin_inset Flex Code
10586 \begin_layout Plain Layout
10588 \change_inserted -712698321 1353680412
10594 definition, the following specifications are possible:
10597 \begin_layout Itemize
10599 \change_inserted -712698321 1355076779
10600 \begin_inset Flex Code
10603 \begin_layout Plain Layout
10605 \change_inserted -712698321 1353680543
10614 \begin_inset Flex Code
10617 \begin_layout Plain Layout
10619 \change_inserted -712698321 1353680567
10625 The string that will appear both in the menu (to insert this argument)
10626 and on the argument inset button (unless you also specify a separate
10627 \begin_inset Flex Code
10630 \begin_layout Plain Layout
10632 \change_inserted -712698321 1355076779
10639 For the menu, you can define an accelerator by appending the respective
10640 character to the string, divided by
10641 \begin_inset Quotes eld
10645 \begin_inset Quotes erd
10649 \begin_inset space \thinspace{}
10654 \begin_inset Flex Code
10657 \begin_layout Plain Layout
10659 \change_inserted -712698321 1353691482
10660 \begin_inset Quotes eld
10664 \begin_inset Quotes erd
10677 \begin_layout Itemize
10679 \change_inserted -712698321 1355076754
10680 \begin_inset Flex Code
10683 \begin_layout Plain Layout
10685 \change_inserted -712698321 1355076658
10692 \begin_inset Flex Code
10695 \begin_layout Plain Layout
10697 \change_inserted -712698321 1355076654
10703 A separate string for the menu.
10704 You can define an accelerator by appending the respective character to
10705 the string, divided by
10706 \begin_inset Quotes eld
10710 \begin_inset Quotes erd
10714 \begin_inset space \thinspace{}
10719 \begin_inset Flex Code
10722 \begin_layout Plain Layout
10724 \change_inserted -712698321 1355076654
10725 \begin_inset Quotes eld
10729 \begin_inset Quotes erd
10738 This specification is optional.
10739 If it is not given the
10740 \begin_inset Flex Code
10743 \begin_layout Plain Layout
10745 \change_inserted -712698321 1355076736
10753 will be used instead for the menu.
10756 \begin_layout Itemize
10758 \change_inserted -712698321 1353680665
10759 \begin_inset Flex Code
10762 \begin_layout Plain Layout
10764 \change_inserted -712698321 1353680616
10771 \begin_inset Flex Code
10774 \begin_layout Plain Layout
10776 \change_inserted -712698321 1353680623
10782 A longer explanatory text that appears in the tooltip when hovering over
10783 the argument inset.
10786 \begin_layout Itemize
10788 \change_inserted -712698321 1353680874
10789 \begin_inset Flex Code
10792 \begin_layout Plain Layout
10794 \change_inserted -712698321 1353680732
10801 \begin_inset Flex Code
10804 \begin_layout Plain Layout
10806 \change_inserted -712698321 1353680738
10812 Declare if this is a mandatory
10813 \change_inserted 2090807402 1353765594
10815 \change_inserted -712698321 1353680874
10817 \change_inserted 2090807402 1353765599
10819 \change_inserted -712698321 1353680874
10821 Mandatory arguments will be output empty if not given, while optional arguments
10822 will not be output at all.
10823 By default, mandatory arguments are delimited by
10824 \begin_inset Flex Code
10827 \begin_layout Plain Layout
10829 \change_inserted -712698321 1353680808
10837 , while optional arguments are delimited by
10838 \begin_inset Flex Code
10841 \begin_layout Plain Layout
10843 \change_inserted -712698321 1353680833
10852 \begin_layout Itemize
10854 \change_inserted -712698321 1353917199
10855 \begin_inset Flex Code
10858 \begin_layout Plain Layout
10860 \change_inserted -712698321 1353680879
10867 \begin_inset Flex Code
10870 \begin_layout Plain Layout
10872 \change_inserted -712698321 1353680874
10878 defines another argument (by its number) which this argument requires to
10879 be output if it is itself output.
10881 \begin_inset space \thinspace{}
10884 g., in LaTeX commands, optional arguments often require previous optional
10885 arguments to be output (at least empty), as in
10886 \begin_inset Flex Code
10889 \begin_layout Plain Layout
10891 \change_inserted -712698321 1353688183
10894 command[][arg]{text}
10902 This can be achieved by the statement
10903 \begin_inset Flex Code
10906 \begin_layout Plain Layout
10908 \change_inserted -712698321 1353681031
10917 \begin_inset Flex Code
10920 \begin_layout Plain Layout
10922 \change_inserted -712698321 1353681045
10933 \begin_layout Itemize
10935 \change_inserted -712698321 1354263104
10936 \begin_inset Flex Code
10939 \begin_layout Plain Layout
10941 \change_inserted -712698321 1353681072
10950 \begin_inset Flex Code
10953 \begin_layout Plain Layout
10955 \change_inserted -712698321 1353681067
10961 defines a custom left delimiter (instead of
10962 \begin_inset Flex Code
10965 \begin_layout Plain Layout
10967 \change_inserted -712698321 1353681127
10976 \begin_inset Flex Code
10979 \begin_layout Plain Layout
10981 \change_inserted -712698321 1353681133
10990 A line break in the output can be indicated by
10991 \begin_inset Flex Code
10994 \begin_layout Plain Layout
10996 \change_inserted -712698321 1354263104
11007 \begin_layout Itemize
11009 \change_inserted -712698321 1355144479
11010 \begin_inset Flex Code
11013 \begin_layout Plain Layout
11015 \change_inserted -712698321 1353681149
11022 \begin_inset Flex Code
11025 \begin_layout Plain Layout
11027 \change_inserted -712698321 1353681146
11033 defines a custom right delimiter (instead of
11034 \begin_inset Flex Code
11037 \begin_layout Plain Layout
11039 \change_inserted -712698321 1353681158
11046 \begin_inset Flex Code
11049 \begin_layout Plain Layout
11051 \change_inserted -712698321 1353681161
11058 A line break in the output can be indicated by
11059 \begin_inset Flex Code
11062 \begin_layout Plain Layout
11064 \change_inserted -712698321 1354263106
11073 \begin_layout Itemize
11075 \change_inserted -712698321 1361701444
11076 \begin_inset Flex Code
11079 \begin_layout Plain Layout
11081 \change_inserted -712698321 1361701356
11088 \begin_inset Flex Code
11091 \begin_layout Plain Layout
11093 \change_inserted -712698321 1361701356
11099 defines an argument that is inserted if and only if no user-specified arguments
11101 \begin_inset space \thinspace{}
11105 if no argument inset has been inserted (note that also an empty argument
11106 inset omits the DefaultArg).
11107 Multiple arguments need to be separated by comma.
11110 \begin_layout Itemize
11112 \change_inserted -712698321 1361701337
11113 \begin_inset Flex Code
11116 \begin_layout Plain Layout
11118 \change_inserted -712698321 1355144487
11127 \begin_inset Flex Code
11130 \begin_layout Plain Layout
11132 \change_inserted -712698321 1355144500
11138 defines an argument that is inserted in any case (alone or in addition
11139 to user-specified arguments).
11140 Multiple arguments need to be separated by comma.
11143 \begin_layout Itemize
11145 \change_inserted -712698321 1353917320
11146 \begin_inset Flex Code
11149 \begin_layout Plain Layout
11151 \change_inserted -712698321 1353917320
11157 The font used for the argument content.
11159 \begin_inset space ~
11163 \begin_inset CommandInset ref
11165 reference "sub:Font-description"
11172 \begin_layout Itemize
11174 \change_inserted -712698321 1353917320
11175 \begin_inset Flex Code
11178 \begin_layout Plain Layout
11180 \change_inserted -712698321 1353917320
11186 The font used for the label.
11188 \begin_inset space ~
11192 \begin_inset CommandInset ref
11194 reference "sub:Font-description"
11201 \begin_layout Itemize
11203 \change_inserted -712698321 1355661048
11204 \begin_inset Flex Code
11207 \begin_layout Plain Layout
11209 \change_inserted -712698321 1353917320
11216 \begin_inset Flex Code
11219 \begin_layout Plain Layout
11221 \change_inserted -712698321 1353917320
11228 \begin_inset Flex Code
11231 \begin_layout Plain Layout
11233 \change_inserted -712698321 1353917320
11240 \begin_inset Flex Code
11243 \begin_layout Plain Layout
11245 \change_inserted -712698321 1353917320
11251 , describing the rendering style used for the inset's frame and buttons.
11253 \begin_inset Flex Code
11256 \begin_layout Plain Layout
11258 \change_inserted -712698321 1353917320
11267 \begin_layout Itemize
11269 \change_inserted -712698321 1355747298
11270 \begin_inset Flex Code
11273 \begin_layout Plain Layout
11275 \change_inserted -712698321 1355661057
11282 \begin_inset Flex Code
11285 \begin_layout Plain Layout
11287 \change_inserted -712698321 1355661049
11294 \begin_inset Flex Code
11297 \begin_layout Plain Layout
11299 \change_inserted -712698321 1355661077
11307 , this argument is automatically inserted when the respective style is selected.
11308 Currently, only one argument per style\SpecialChar \slash{}
11309 layout can be automatically inserted.
11310 \change_inserted 155139281 1354198988
11314 \begin_layout Standard
11316 \change_inserted -712698321 1356689813
11317 By default, the text entered in the LyX workarea in the respective layout
11318 is the last (mandatory) argument of a command if the
11319 \begin_inset Flex Code
11322 \begin_layout Plain Layout
11324 \change_inserted -712698321 1356689619
11333 \begin_inset Flex Code
11336 \begin_layout Plain Layout
11338 \change_inserted -712698321 1356689629
11347 However, arguments with the prefix
11348 \begin_inset Flex Code
11351 \begin_layout Plain Layout
11353 \change_inserted -712698321 1356689679
11361 are output after this workarea argument.
11362 Note that post-argument numbering restarts at 1, so the first argument
11363 following the workarea argument is
11364 \begin_inset Flex Code
11367 \begin_layout Plain Layout
11369 \change_inserted -712698321 1356689813
11378 Post-arguments are ignored in any other
11379 \begin_inset Flex Code
11382 \begin_layout Plain Layout
11384 \change_inserted -712698321 1356689801
11391 \begin_inset Flex Code
11394 \begin_layout Plain Layout
11396 \change_inserted -712698321 1356689801
11407 \begin_layout Standard
11409 \change_inserted 155139281 1354199102
11411 \begin_inset Flex Code
11414 \begin_layout Plain Layout
11416 \change_inserted 155139281 1354199013
11427 \begin_inset Flex Code
11430 \begin_layout Plain Layout
11432 \change_inserted 155139281 1354199102
11443 \begin_inset Flex Code
11446 \begin_layout Plain Layout
11448 \change_inserted 155139281 1354199044
11456 followed by the number (e.
11457 \begin_inset space \thinspace{}
11462 \begin_inset Flex Code
11465 \begin_layout Plain Layout
11467 \change_inserted 155139281 1354199064
11481 \begin_layout Description
11482 \begin_inset Flex Code
11485 \begin_layout Plain Layout
11491 Note that this will completely override any prior
11492 \begin_inset Flex Code
11495 \begin_layout Plain Layout
11501 declaration for this style.
11503 \begin_inset Quotes eld
11507 \begin_inset Flex Code
11510 \begin_layout Plain Layout
11517 \begin_inset Quotes erd
11522 \begin_inset space ~
11526 \begin_inset CommandInset ref
11528 reference "sub:I18n"
11532 for details on its use.
11535 \begin_layout Description
11536 \begin_inset Flex Code
11539 \begin_layout Plain Layout
11546 \begin_inset Flex Code
11549 \begin_layout Plain Layout
11559 \begin_layout Plain Layout
11560 Note that a `float' here is a real number, such as: 1.5.
11565 The vertical space with which the last of a chain of paragraphs with this
11566 style is separated from the following paragraph.
11567 If the next paragraph has another style, the separations are not simply
11568 added, but the maximum is taken.
11571 \begin_layout Description
11572 \begin_inset Flex Code
11575 \begin_layout Plain Layout
11582 \begin_inset Flex Code
11585 \begin_layout Plain Layout
11591 ] The category for this style.
11592 This is used to group related styles in the style combobox on the toolbar.
11593 Any string can be used, but you may want to use existing categories with
11598 \begin_layout Description
11599 \begin_inset Flex Code
11602 \begin_layout Plain Layout
11608 Depth of XML command.
11609 Used only with XML-type formats.
11612 \begin_layout Description
11613 \begin_inset Flex Code
11616 \begin_layout Plain Layout
11623 \begin_inset Flex Code
11626 \begin_layout Plain Layout
11632 ] Copies all the features of an existing style into the current one.
11636 \begin_layout Description
11637 \begin_inset Flex Code
11640 \begin_layout Plain Layout
11647 \begin_inset Flex Code
11650 \begin_layout Plain Layout
11656 ] The name of a style whose preamble should be output
11661 This allows to ensure some ordering of the preamble snippets when macros
11662 definitions depend on one another.
11666 \begin_layout Plain Layout
11667 Note that, besides that functionality, there is no way to ensure any ordering
11669 The ordering that you see in a given version of LyX may change without
11670 warning in later versions.
11678 \begin_layout Description
11679 \begin_inset Flex Code
11682 \begin_layout Plain Layout
11689 \begin_inset Flex Code
11692 \begin_layout Plain Layout
11697 , Box, Filled_Box, Static
11702 ] The type of label that stands at the end of the paragraph (or sequence
11704 \begin_inset Flex Code
11707 \begin_layout Plain Layout
11714 \begin_inset Newline newline
11718 \begin_inset Flex Code
11721 \begin_layout Plain Layout
11728 \begin_inset Flex Code
11731 \begin_layout Plain Layout
11738 \begin_inset Flex Code
11741 \begin_layout Plain Layout
11749 \begin_inset Flex Code
11752 \begin_layout Plain Layout
11759 \begin_inset Quotes eld
11763 \begin_inset Quotes erd
11767 \begin_inset Flex Code
11770 \begin_layout Plain Layout
11777 \begin_inset space \space{}
11781 \begin_inset Flex Code
11784 \begin_layout Plain Layout
11790 ) is a white (resp.
11791 \begin_inset space ~
11794 black) square suitable for end of proof markers,
11795 \begin_inset Flex Code
11798 \begin_layout Plain Layout
11804 is an explicit text string.
11807 \begin_layout Description
11808 \begin_inset Flex Code
11811 \begin_layout Plain Layout
11818 \begin_inset Flex Code
11821 \begin_layout Plain Layout
11827 ] The string used for a label with a
11828 \begin_inset Flex Code
11831 \begin_layout Plain Layout
11838 \begin_inset Newline newline
11842 \begin_inset Flex Code
11845 \begin_layout Plain Layout
11855 \begin_layout Description
11856 \begin_inset Flex Code
11859 \begin_layout Plain Layout
11865 The font used for both the text body
11871 \begin_inset space ~
11875 \begin_inset CommandInset ref
11877 reference "sub:Font-description"
11882 Note that defining this font automatically defines the
11883 \begin_inset Flex Code
11886 \begin_layout Plain Layout
11893 So you should define this one first if you also want to define
11894 \begin_inset Flex Code
11897 \begin_layout Plain Layout
11904 \change_inserted -195340706 1364753581
11908 \begin_layout Description
11910 \change_inserted -195340706 1364753581
11911 \begin_inset Flex Code
11914 \begin_layout Plain Layout
11916 \change_inserted -195340706 1364753581
11922 Used for backporting new styles to stable LyX versions.
11923 The first stable version that supports this tag is LyX 2.1.0.
11925 \begin_inset Flex Code
11928 \begin_layout Plain Layout
11930 \change_inserted -195340706 1364753581
11936 is a number which may either be 0 (this is the default if the tag is not
11937 given), -1 or any value greater than zero.
11939 \begin_inset Flex Code
11942 \begin_layout Plain Layout
11944 \change_inserted -195340706 1364753581
11950 flag of a style is greater than zero, it will always be written to the
11952 If a .lyx file is read, the style definitions from the document header are
11953 added to the document class.
11954 Therefore even older versions can handle the style.
11956 \begin_inset Flex Code
11959 \begin_layout Plain Layout
11961 \change_inserted -195340706 1364753581
11967 is a version number: If such a style is read, and the version number is
11968 less than the version number of the already existing style in the document
11969 class, the new style is ignored.
11970 If the version number is higher, the new style replaces the existing style.
11971 A value of -1 means an infinite version number, i.e.
11977 \begin_layout Description
11978 \begin_inset Flex Code
11981 \begin_layout Plain Layout
11988 \begin_inset Flex Code
11991 \begin_layout Plain Layout
12000 \begin_inset space \thinspace{}
12004 \begin_inset Flex Code
12007 \begin_layout Plain Layout
12013 ] Usually LyX does not allow you to insert more than one space between words,
12014 since a space is considered as the separation between two words, not a
12015 character or symbol of its own.
12016 This is a very fine thing but sometimes annoying, for example, when typing
12017 program code or plain LaTeX code.
12019 \begin_inset Flex Code
12022 \begin_layout Plain Layout
12029 Note that LyX will create protected blanks for the additional blanks when
12030 in another mode than LaTeX-mode.
12033 \begin_layout Description
12034 \begin_inset Flex Code
12037 \begin_layout Plain Layout
12043 These tags are used with XHTML output.
12045 \begin_inset CommandInset ref
12047 reference "sub:Paragraph-Style-XHTML"
12054 \begin_layout Description
12055 \begin_inset Flex Code
12058 \begin_layout Plain Layout
12064 [FIXME] (Used only with XML-type formats.)
12067 \begin_layout Description
12068 \begin_inset Flex Code
12071 \begin_layout Plain Layout
12078 \begin_inset Flex Code
12081 \begin_layout Plain Layout
12090 \begin_inset space \thinspace{}
12094 \begin_inset Flex Code
12097 \begin_layout Plain Layout
12104 \begin_inset Flex Code
12107 \begin_layout Plain Layout
12113 , marks the style as to be included in the document preamble and not in
12115 This is useful for document classes that want such information as the title
12116 and author to appear in the preamble.
12117 Note that this works only for styles for which the
12118 \begin_inset Flex Code
12121 \begin_layout Plain Layout
12128 \begin_inset Flex Code
12131 \begin_layout Plain Layout
12138 \begin_inset Flex Code
12141 \begin_layout Plain Layout
12150 \begin_layout Description
12151 \begin_inset Flex Code
12154 \begin_layout Plain Layout
12161 \begin_inset Flex Code
12164 \begin_layout Plain Layout
12173 \begin_inset space \thinspace{}
12177 \begin_inset Flex Code
12180 \begin_layout Plain Layout
12187 \begin_inset Flex Code
12190 \begin_layout Plain Layout
12196 , marks the style as being part of a title block (see also the
12197 \begin_inset Flex Code
12200 \begin_layout Plain Layout
12207 \begin_inset Flex Code
12210 \begin_layout Plain Layout
12219 \begin_layout Description
12221 \change_inserted -712698321 1355932296
12222 \begin_inset Flex Code
12225 \begin_layout Plain Layout
12227 \change_inserted -712698321 1355932178
12234 \begin_inset Flex Code
12237 \begin_layout Plain Layout
12239 \change_inserted -712698321 1355932181
12245 ] The LaTeX command sequence declaring an item in a list.
12246 The command is to be defined without the preceding backslash (the default
12248 \begin_inset Quotes eld
12252 \begin_inset Quotes erd
12256 \begin_inset Flex Code
12259 \begin_layout Plain Layout
12261 \change_inserted -712698321 1355932279
12271 in the LaTeX output).
12274 \begin_layout Description
12275 \begin_inset Flex Code
12278 \begin_layout Plain Layout
12285 \begin_inset Flex Code
12288 \begin_layout Plain Layout
12294 ] This provides extra space between paragraphs that have the same style.
12295 If you put other styles into an environment, each is separated with the
12297 \begin_inset Flex Code
12300 \begin_layout Plain Layout
12307 But the whole items of the environment are additionally separated with
12309 \begin_inset Flex Code
12312 \begin_layout Plain Layout
12319 Note that this is a
12324 \begin_layout Description
12325 \begin_inset Flex Code
12328 \begin_layout Plain Layout
12334 [FIXME] (Used only with XML-type formats.)
12337 \begin_layout Description
12338 \begin_inset Flex Code
12341 \begin_layout Plain Layout
12348 \begin_inset Flex Code
12351 \begin_layout Plain Layout
12360 \begin_inset space \thinspace{}
12364 \begin_inset Flex Code
12367 \begin_layout Plain Layout
12373 ] Usually LyX does not allow you to leave a paragraph empty, since it would
12374 lead to empty LaTeX output.
12375 There are some cases where this could be desirable however: in a letter
12376 template, the required fields can be provided as empty fields, so that
12377 people do not forget them; in some special classes, a style can be used
12378 as some kind of break, which does not contain actual text.
12381 \begin_layout Description
12382 \begin_inset Flex Code
12385 \begin_layout Plain Layout
12392 \begin_inset Flex Code
12395 \begin_layout Plain Layout
12401 ] The vertical space between the label and the text body.
12402 Only used for labels that are above the text body (
12403 \begin_inset Flex Code
12406 \begin_layout Plain Layout
12413 \begin_inset Newline newline
12417 \begin_inset Flex Code
12420 \begin_layout Plain Layout
12421 Centered_Top_Environment
12429 \begin_layout Description
12430 \begin_inset Flex Code
12433 \begin_layout Plain Layout
12440 \begin_inset Flex Code
12443 \begin_layout Plain Layout
12449 ] The name of the counter for automatic numbering.
12451 \change_inserted 1414654397 1360434581
12452 In order to have the counter appear with your label, you will need to reference
12453 it in the LabelString.
12454 This will work with
12455 \begin_inset Flex Code
12458 \begin_layout Plain Layout
12460 \change_inserted 1414654397 1360434565
12469 \begin_inset Flex Code
12472 \begin_layout Plain Layout
12474 \change_inserted 1414654397 1360434569
12483 \begin_inset Flex Code
12486 \begin_layout Plain Layout
12488 \change_inserted 1414654397 1360434574
12497 \begin_inset Flex Code
12500 \begin_layout Plain Layout
12502 \change_inserted 1414654397 1360434578
12513 \begin_inset Newline newline
12517 \change_deleted 1414654397 1360434393
12523 \begin_inset Flex Code
12526 \begin_layout Plain Layout
12533 \begin_inset Flex Code
12536 \begin_layout Plain Layout
12543 In that case, the counter will be stepped each time the style appears.
12544 \begin_inset Newline newline
12554 \begin_inset Flex Code
12557 \begin_layout Plain Layout
12564 \begin_inset Flex Code
12567 \begin_layout Plain Layout
12573 , though this case is a bit complicated.
12574 Suppose you declare
12575 \begin_inset Quotes eld
12579 \begin_inset Flex Code
12582 \begin_layout Plain Layout
12583 LabelCounter myenum
12589 \begin_inset Quotes erd
12593 Then the actual counters used are
12594 \begin_inset Flex Code
12597 \begin_layout Plain Layout
12604 \begin_inset Flex Code
12607 \begin_layout Plain Layout
12614 \begin_inset Flex Code
12617 \begin_layout Plain Layout
12624 \begin_inset Flex Code
12627 \begin_layout Plain Layout
12633 , much as in LaTeX.
12634 These counters must all be declared separately.
12635 \begin_inset Newline newline
12639 \begin_inset CommandInset ref
12641 reference "sub:Counters"
12645 for details on counters.
12648 \begin_layout Description
12649 \begin_inset Flex Code
12652 \begin_layout Plain Layout
12658 The font used for the label.
12660 \begin_inset space ~
12664 \begin_inset CommandInset ref
12666 reference "sub:Font-description"
12673 \begin_layout Description
12674 \begin_inset Flex Code
12677 \begin_layout Plain Layout
12684 \begin_inset Flex Code
12687 \begin_layout Plain Layout
12693 ] Text that indicates how far a label should be indented.
12696 \begin_layout Description
12697 \begin_inset Flex Code
12700 \begin_layout Plain Layout
12707 \begin_inset Flex Code
12710 \begin_layout Plain Layout
12716 ] Text that indicates the amount of horizontal space between the label and
12718 Only used for labels that are not above the text body.
12721 \begin_layout Description
12722 \begin_inset Flex Code
12725 \begin_layout Plain Layout
12732 \begin_inset Flex Code
12735 \begin_layout Plain Layout
12741 ] The string used for
12742 \change_inserted 1414654397 1360434358
12744 \change_deleted 1414654397 1360434353
12749 \begin_inset Flex Code
12752 \begin_layout Plain Layout
12758 is set, this string can be contain the special formatting commands described
12760 \begin_inset CommandInset ref
12762 reference "sub:Counters"
12769 \begin_layout Description
12770 \begin_inset Flex Code
12773 \begin_layout Plain Layout
12774 LabelStringAppendix
12780 \begin_inset Flex Code
12783 \begin_layout Plain Layout
12789 ] This is used inside the appendix instead of
12790 \begin_inset Newline newline
12794 \begin_inset Flex Code
12797 \begin_layout Plain Layout
12805 \begin_inset Flex Code
12808 \begin_layout Plain Layout
12815 \begin_inset Newline newline
12819 \begin_inset Flex Code
12822 \begin_layout Plain Layout
12823 LabelStringAppendix
12831 \begin_layout Description
12832 \begin_inset Flex Code
12835 \begin_layout Plain Layout
12841 [FIXME] (Used only with XML-type formats.)
12844 \begin_layout Description
12845 \begin_inset Flex Code
12848 \begin_layout Plain Layout
12855 \begin_inset Flex Code
12858 \begin_layout Plain Layout
12864 \change_inserted 1414654397 1360434611
12866 \change_deleted 1414654397 1360434612
12870 \begin_inset Newline newline
12874 \change_inserted 1414654397 1360434627
12876 \change_deleted 1414654397 1360434623
12877 _Top_Environment, Counter,
12879 Sensitive, Enumerate,
12880 \begin_inset Newline newline
12883 Itemize, Bibliography
12892 \begin_layout Description
12893 \begin_inset Flex Code
12896 \begin_layout Plain Layout
12902 means the label is the very first word (up to the first real blank).
12903 Use protected spaces if you want more than one word as the label.
12907 \begin_layout Description
12908 \begin_inset Flex Code
12911 \begin_layout Plain Layout
12917 means the label is simply what is declared as
12918 \begin_inset Flex Code
12921 \begin_layout Plain Layout
12929 \change_deleted 1414654397 1360434660
12930 Note that this really is `static'.
12932 \change_inserted 1414654397 1360434794
12933 This will be displayed
12934 \begin_inset Quotes eld
12938 \begin_inset Quotes erd
12941 , at the beginning of the paragraph.
12943 \begin_inset Flex Code
12946 \begin_layout Plain Layout
12948 \change_inserted 1414654397 1360434743
12957 \begin_inset Flex Code
12960 \begin_layout Plain Layout
12962 \change_inserted 1414654397 1360434747
12970 , then it will be displayed only in the first paragraph in any sequence
12971 of paragraphs with the same
12972 \begin_inset Flex Code
12975 \begin_layout Plain Layout
12977 \change_inserted 1414654397 1360434794
12990 \begin_layout Description
12991 \begin_inset Flex Code
12994 \begin_layout Plain Layout
12996 \change_deleted 1414654397 1360434641
12998 \change_inserted 1414654397 1360434643
13007 \begin_inset space ~
13011 \begin_inset space ~
13015 \begin_inset Flex Code
13018 \begin_layout Plain Layout
13020 \change_deleted 1414654397 1360434649
13028 are special cases of
13029 \begin_inset Flex Code
13032 \begin_layout Plain Layout
13039 The label will be printed above the paragraph
13040 \change_inserted 1414654397 1360434839
13041 either at the beginning of the line or centered
13042 \change_deleted 1414654397 1360434813
13043 , but only at the top of an environment or the top of a chain of paragraphs
13045 This might be used with the
13046 \begin_inset Flex MenuItem
13049 \begin_layout Plain Layout
13060 \begin_layout Description
13061 \begin_inset Flex Code
13064 \begin_layout Plain Layout
13070 is a special case for the caption-labels
13071 \begin_inset Quotes eld
13075 \begin_inset Quotes erd
13079 \begin_inset Quotes eld
13083 \begin_inset Quotes erd
13087 \begin_inset Newline newline
13091 \begin_inset Flex Code
13094 \begin_layout Plain Layout
13100 means the (hardcoded) label string depends on the kind of float: It is
13101 hardcoded to be `FloatType N', where N is the value of the counter associated
13103 For the case that a caption is inserted outside of a float
13104 \change_inserted 1414654397 1360434861
13108 \begin_inset Flex Code
13111 \begin_layout Plain Layout
13118 \change_inserted 1414654397 1360434866
13120 \change_deleted 1414654397 1360434868
13121 should be set to e.
13122 \begin_inset space \thinspace{}
13126 \begin_inset space \space{}
13132 \begin_inset Quotes eld
13136 \begin_inset Quotes erd
13142 \begin_layout Description
13144 \change_deleted 1414654397 1360434875
13145 \begin_inset Flex Code
13148 \begin_layout Plain Layout
13154 defines automatically numbered labels.
13156 \begin_inset Flex Code
13159 \begin_layout Plain Layout
13165 will be expanded to contain any counters: So the result will for example
13167 \begin_inset Quotes eld
13171 \begin_inset Flex Code
13174 \begin_layout Plain Layout
13185 \begin_inset Quotes erd
13190 \begin_inset space ~
13194 \begin_inset CommandInset ref
13196 reference "sub:Counters"
13200 for more information on counters.
13203 \begin_layout Description
13204 \begin_inset Flex Code
13207 \begin_layout Plain Layout
13213 produces the usual sort of enumeration labels.
13214 At present, it is hardcoded to use Arabic numerals, lowercase letters,
13215 small Roman numerals, and uppercase letters for the four possible depths.
13218 \begin_layout Description
13219 \begin_inset Flex Code
13222 \begin_layout Plain Layout
13228 produces various bullets at the different levels.
13229 It is also hardcoded.
13232 \begin_layout Description
13233 \begin_inset Flex Code
13236 \begin_layout Plain Layout
13243 \change_deleted 1414654397 1360434898
13244 is used internally by LyX and
13246 should be used only with
13247 \begin_inset Flex Code
13250 \begin_layout Plain Layout
13251 LatexType BibEnvironment
13260 \begin_layout Description
13261 \begin_inset Flex Code
13264 \begin_layout Plain Layout
13270 Note that this will completely override any prior
13271 \begin_inset Flex Code
13274 \begin_layout Plain Layout
13280 declaration for this style.
13282 \begin_inset Quotes eld
13286 \begin_inset Flex Code
13289 \begin_layout Plain Layout
13296 \begin_inset Quotes erd
13301 \begin_inset CommandInset ref
13303 reference "sub:I18n"
13307 for details on its use.
13310 \begin_layout Description
13311 \begin_inset Flex Code
13314 \begin_layout Plain Layout
13321 \begin_inset Flex Code
13324 \begin_layout Plain Layout
13330 ] The name of the corresponding LaTeX stuff.
13331 Either the environment or command name.
13334 \begin_layout Description
13335 \begin_inset Flex Code
13338 \begin_layout Plain Layout
13345 \begin_inset Flex Code
13348 \begin_layout Plain Layout
13354 ] An optional parameter for the corresponding
13355 \begin_inset Flex Code
13358 \begin_layout Plain Layout
13365 This parameter cannot be changed from within LyX
13366 \change_inserted -712698321 1355144804
13368 \begin_inset Flex Code
13371 \begin_layout Plain Layout
13373 \change_inserted -712698321 1355144804
13379 for customizable parameters)
13383 \change_inserted -712698321 1355144804
13384 This will be output as is after all LaTeX
13385 \begin_inset Flex Code
13388 \begin_layout Plain Layout
13390 \change_inserted -712698321 1355144658
13403 \begin_layout Description
13404 \begin_inset Flex Code
13407 \begin_layout Plain Layout
13414 \begin_inset Flex Code
13417 \begin_layout Plain Layout
13422 , Command, Environment, Item_Environment,
13423 \begin_inset Newline newline
13426 List_Environment, Bib_Environment
13431 ] How the style should be translated into LaTeX.
13435 \begin_layout Plain Layout
13436 \begin_inset Flex Code
13439 \begin_layout Plain Layout
13445 is perhaps a bit misleading, since these rules apply to SGML classes, too.
13446 Visit the SGML class files for specific examples.
13455 \begin_layout Description
13456 \begin_inset Flex Code
13459 \begin_layout Plain Layout
13465 means nothing special.
13468 \begin_layout Description
13469 \begin_inset Flex Code
13472 \begin_layout Plain Layout
13479 \begin_inset Flex Code
13482 \begin_layout Plain Layout
13489 {\SpecialChar \ldots{}
13498 \begin_layout Description
13499 \begin_inset Flex Code
13502 \begin_layout Plain Layout
13509 \begin_inset Flex Code
13512 \begin_layout Plain Layout
13519 }\SpecialChar \ldots{}
13535 \begin_layout Description
13536 \begin_inset Flex Code
13539 \begin_layout Plain Layout
13546 \begin_inset Flex Code
13549 \begin_layout Plain Layout
13556 \begin_inset Flex Code
13559 \begin_layout Plain Layout
13567 is generated for each paragraph of this environment.
13571 \begin_layout Description
13572 \begin_inset Flex Code
13575 \begin_layout Plain Layout
13582 \begin_inset Flex Code
13585 \begin_layout Plain Layout
13592 \begin_inset Newline newline
13596 \begin_inset Flex Code
13599 \begin_layout Plain Layout
13605 is passed as an argument to the environment.
13606 \begin_inset Newline newline
13610 \begin_inset Flex Code
13613 \begin_layout Plain Layout
13619 can be defined in the
13620 \begin_inset Flex MenuItem
13623 \begin_layout Plain Layout
13624 Edit\SpecialChar \menuseparator
13626 \begin_inset space ~
13637 \begin_layout Description
13638 \begin_inset Flex Code
13641 \begin_layout Plain Layout
13648 \begin_inset Flex Code
13651 \begin_layout Plain Layout
13657 but adds additionally the necessary mandatory argument (the longest label)
13658 to the begin statement of the bibliography environment:
13659 \begin_inset Newline newline
13663 \begin_inset Flex Code
13666 \begin_layout Plain Layout
13669 begin{thebibliography}{99}
13674 It is therefore only useful for bibliography environments.
13675 The default longest label
13676 \begin_inset Quotes eld
13680 \begin_inset Quotes erd
13683 can be changed by the user in the paragraph settings of a bibliography
13687 \begin_layout Standard
13688 Putting the last few things together, the LaTeX output will be either:
13691 \begin_layout LyX-Code
13694 LatexName[LatexParam]{\SpecialChar \ldots{}
13698 \begin_layout Standard
13702 \begin_layout LyX-Code
13705 begin{LatexName}[LatexParam] \SpecialChar \ldots{}
13711 \begin_layout Standard
13712 depending upon the LaTeX type.
13716 \begin_layout Description
13718 \change_inserted -712698321 1354263086
13719 \begin_inset Flex Code
13722 \begin_layout Plain Layout
13724 \change_inserted -712698321 1353866852
13731 \begin_inset Flex Code
13734 \begin_layout Plain Layout
13736 \change_inserted -712698321 1353866852
13742 ] A string that is put at the beginning of the style content.
13743 A line break in the output can be indicated by
13744 \begin_inset Flex Code
13747 \begin_layout Plain Layout
13749 \change_inserted -712698321 1354263086
13760 \begin_layout Description
13761 \begin_inset Flex Code
13764 \begin_layout Plain Layout
13771 \begin_inset Flex Code
13774 \begin_layout Plain Layout
13780 ] If you put styles into environments, the different
13781 \begin_inset Flex Code
13784 \begin_layout Plain Layout
13790 are not simply added, but added with a factor
13791 \begin_inset Formula $\frac{4}{\mathrm{depth}+4}$
13795 Note that this parameter is also used when
13796 \begin_inset Flex Code
13799 \begin_layout Plain Layout
13806 \begin_inset Flex Code
13809 \begin_layout Plain Layout
13816 \begin_inset Flex Code
13819 \begin_layout Plain Layout
13826 Then it is added to the manual or dynamic margin.
13827 \begin_inset Newline newline
13831 \begin_inset Quotes eld
13835 \begin_inset Flex Code
13838 \begin_layout Plain Layout
13845 \begin_inset Quotes erd
13848 means that the paragraph is indented with the width of
13849 \begin_inset Quotes eld
13853 \begin_inset Flex Code
13856 \begin_layout Plain Layout
13863 \begin_inset Quotes erd
13866 in the normal font.
13867 You can get a negative width by prefixing the string with
13868 \begin_inset Quotes eld
13872 \begin_inset Flex Code
13875 \begin_layout Plain Layout
13882 \begin_inset Quotes erd
13886 This way was chosen so that the look is the same with each used screen
13890 \begin_layout Description
13891 \begin_inset Flex Code
13894 \begin_layout Plain Layout
13901 \begin_inset Flex Code
13904 \begin_layout Plain Layout
13909 , Manual, Dynamic, First_Dynamic, Right_Address_Box
13915 \begin_inset Newline newline
13918 The kind of margin that the style has on the left side.
13922 \begin_layout Description
13923 \begin_inset Flex Code
13926 \begin_layout Plain Layout
13932 just means a fixed margin.
13935 \begin_layout Description
13936 \begin_inset Flex Code
13939 \begin_layout Plain Layout
13945 means that the left margin depends on the string entered in the
13946 \begin_inset Flex MenuItem
13949 \begin_layout Plain Layout
13950 Edit\SpecialChar \menuseparator
13952 \begin_inset space ~
13961 This is used to typeset nice lists without tabulators.
13964 \begin_layout Description
13965 \begin_inset Flex Code
13968 \begin_layout Plain Layout
13974 means that the margin depends on the size of the label.
13975 This is used for automatic enumerated headlines.
13976 It is obvious that the headline
13977 \begin_inset Quotes eld
13980 5.4.3.2.1 Very long headline
13981 \begin_inset Quotes erd
13984 must have a wider left margin (as wide as
13985 \begin_inset Quotes eld
13989 \begin_inset Quotes erd
13992 plus the space) than
13993 \begin_inset Quotes eld
13996 3.2 Very long headline
13997 \begin_inset Quotes erd
14001 \begin_inset Quotes eld
14005 \begin_inset Quotes erd
14008 are not able to do this.
14011 \begin_layout Description
14012 \begin_inset Flex Code
14015 \begin_layout Plain Layout
14021 is similar, but only the very first row of the paragraph is dynamic, while
14022 the others are static; this is used, for example, for descriptions.
14025 \begin_layout Description
14026 \begin_inset Flex Code
14029 \begin_layout Plain Layout
14035 means the margin is chosen in a way that the longest row of this paragraph
14036 fits to the right margin.
14037 This is used to typeset an address on the right edge of the page.
14041 \begin_layout Description
14042 \begin_inset Flex Code
14045 \begin_layout Plain Layout
14052 \begin_inset Flex Code
14055 \begin_layout Plain Layout
14064 \begin_inset space \thinspace{}
14068 \begin_inset Flex Code
14071 \begin_layout Plain Layout
14077 ] Whether fragile commands in this style should be
14078 \begin_inset Flex Code
14081 \begin_layout Plain Layout
14094 whether this command should itself be protected.)
14097 \begin_layout Description
14098 \begin_inset Flex Code
14101 \begin_layout Plain Layout
14108 \begin_inset Flex Code
14111 \begin_layout Plain Layout
14118 \begin_inset space \thinspace{}
14122 \begin_inset Flex Code
14125 \begin_layout Plain Layout
14133 ] Whether newlines are translated into LaTeX newlines (
14134 \begin_inset Flex Code
14137 \begin_layout Plain Layout
14148 The translation can be switched off to allow more comfortable LaTeX editing
14152 \begin_layout Description
14153 \begin_inset Flex Code
14156 \begin_layout Plain Layout
14163 \begin_inset Flex Code
14166 \begin_layout Plain Layout
14175 \begin_inset space \thinspace{}
14179 \begin_inset Flex Code
14182 \begin_layout Plain Layout
14188 ] If set to true, and if
14189 \begin_inset Flex Code
14192 \begin_layout Plain Layout
14199 \begin_inset Flex Code
14202 \begin_layout Plain Layout
14208 ) paragraphs are being indented, then the indentation of such a paragraph
14209 following one of this type will be suppressed.
14210 (So this will not affect the display of non-default paragraphs.)
14213 \begin_layout Description
14214 \begin_inset Flex Code
14217 \begin_layout Plain Layout
14224 \begin_inset Flex Code
14227 \begin_layout Plain Layout
14233 ] Name of a style that has replaced this style.
14234 This is used to rename a style, while keeping backward compatibility.
14237 \begin_layout Description
14239 \change_deleted -712698321 1353679722
14240 \begin_inset Flex Code
14243 \begin_layout Plain Layout
14250 \begin_inset Flex Code
14253 \begin_layout Plain Layout
14259 ] The number of optional arguments that can be used with this style.
14260 This is useful for things like section headings, and only makes sense with
14262 Note that, on output, the optional arguments will all precede any required
14263 arguments (see below).
14264 So one can have constructs like:
14268 \begin_layout LyX-Code
14270 \change_deleted -712698321 1353679722
14273 mycmd[opt1]{req1}{contents of paragraph}
14276 \begin_layout Standard
14278 \change_deleted -712698321 1353679722
14279 but one cannot have things like:
14282 \begin_layout LyX-Code
14284 \change_deleted -712698321 1353679722
14287 mycmd[opt1]{req1}[opt2]{contents of paragraph}
14290 \begin_layout Standard
14292 \change_deleted -712698321 1353679722
14293 at least, not without ERT (with which you can have anything).
14300 \begin_layout Description
14301 \begin_inset Flex Code
14304 \begin_layout Plain Layout
14311 \begin_inset Flex Code
14314 \begin_layout Plain Layout
14323 \begin_inset space \thinspace{}
14327 \begin_inset Flex Code
14330 \begin_layout Plain Layout
14336 ] Indicates that paragraphs will not be separated by an empty line in LaTeX
14337 output, but only by a line break; together with
14338 \begin_inset Flex Code
14341 \begin_layout Plain Layout
14347 , this allows to emulate a plain text editor (like the ERT inset).
14350 \begin_layout Description
14351 \begin_inset Flex Code
14354 \begin_layout Plain Layout
14361 \begin_inset Flex Code
14364 \begin_layout Plain Layout
14370 ] The indent of the very first line of a paragraph.
14372 \begin_inset Newline newline
14376 \begin_inset Flex Code
14379 \begin_layout Plain Layout
14385 will be fixed for a certain style.
14386 The exception is the default style, since the indentation for these paragraphs
14387 can be prohibited with
14388 \begin_inset Flex Code
14391 \begin_layout Plain Layout
14399 \begin_inset Flex Code
14402 \begin_layout Plain Layout
14408 style paragraphs inside environments use the
14409 \begin_inset Flex Code
14412 \begin_layout Plain Layout
14418 of the environment, not their native one.
14420 \begin_inset Flex Code
14423 \begin_layout Plain Layout
14429 paragraphs inside an enumeration are not indented.
14432 \begin_layout Description
14433 \begin_inset Flex Code
14436 \begin_layout Plain Layout
14443 \begin_inset Flex Code
14446 \begin_layout Plain Layout
14452 ] The vertical space between two paragraphs of this style.
14455 \begin_layout Description
14456 \begin_inset Flex Code
14459 \begin_layout Plain Layout
14466 \begin_inset Flex Code
14469 \begin_layout Plain Layout
14475 ] LyX allows the user to choose either
14476 \begin_inset Quotes eld
14480 \begin_inset Quotes erd
14484 \begin_inset Quotes eld
14488 \begin_inset Quotes erd
14491 to separate paragraphs.
14493 \begin_inset Quotes eld
14497 \begin_inset Quotes erd
14501 \begin_inset Flex Code
14504 \begin_layout Plain Layout
14512 \begin_inset Quotes eld
14516 \begin_inset Quotes erd
14520 \begin_inset Flex Code
14523 \begin_layout Plain Layout
14529 is ignored and all paragraphs are separated by the
14530 \begin_inset Flex Code
14533 \begin_layout Plain Layout
14540 The vertical space is calculated with
14541 \begin_inset Flex Code
14544 \begin_layout Plain Layout
14546 \begin_inset space ~
14555 \begin_inset Flex Code
14558 \begin_layout Plain Layout
14564 is the height of a row with the normal font.
14565 This way, the look stays the same with different screen fonts.
14568 \begin_layout Description
14569 \begin_inset Flex Code
14572 \begin_layout Plain Layout
14579 \begin_inset Flex Code
14582 \begin_layout Plain Layout
14591 \begin_inset space \thinspace{}
14595 \begin_inset Flex Code
14598 \begin_layout Plain Layout
14604 ] Whether the contents of this paragraph should be output in raw form, meaning
14605 without special translations that LaTeX would require.
14608 \begin_layout Description
14609 \begin_inset Flex Code
14612 \begin_layout Plain Layout
14618 Information to be included in the LaTeX preamble when this style is used.
14619 Used to define macros, load packages, etc., required by this particular
14622 \begin_inset Quotes eld
14626 \begin_inset Flex Code
14629 \begin_layout Plain Layout
14636 \begin_inset Quotes erd
14642 \begin_layout Description
14643 \begin_inset Flex Code
14646 \begin_layout Plain Layout
14653 \begin_inset Flex Code
14656 \begin_layout Plain Layout
14662 ] The prefix to use when creating labels referring to paragraphs of this
14664 This allows the use of formatted references.
14667 \begin_layout Description
14669 \change_deleted -712698321 1353681258
14670 \begin_inset Flex Code
14673 \begin_layout Plain Layout
14680 \begin_inset Flex Code
14683 \begin_layout Plain Layout
14689 ] The number of required arguments that the LaTeX command or environment
14690 corresponding to this style expects.
14691 In the case of a command, these are required arguments
14695 that associated with the content of the paragraph itself.
14696 These do not actually have to be provided: LyX will output empty arguments
14698 Note that optional arguments will be output before required arguments.
14699 See the discussion of the
14700 \begin_inset Flex Code
14703 \begin_layout Plain Layout
14709 tag above for more information.
14714 \begin_layout Description
14715 \begin_inset Flex Code
14718 \begin_layout Plain Layout
14725 \begin_inset Flex Code
14728 \begin_layout Plain Layout
14734 ] Whether the style requires the feature
14735 \begin_inset Flex Code
14738 \begin_layout Plain Layout
14745 See the description of
14746 \begin_inset Flex Code
14749 \begin_layout Plain Layout
14756 \begin_inset space ~
14760 \begin_inset CommandInset ref
14762 reference "sub:General-text-class"
14766 ) for information on `features'.
14769 \begin_layout Description
14771 \change_inserted -712698321 1353693371
14772 \begin_inset Flex Code
14775 \begin_layout Plain Layout
14777 \change_inserted -712698321 1353693146
14786 \begin_inset Flex Code
14789 \begin_layout Plain Layout
14791 \change_inserted -712698321 1353693235
14800 \begin_inset Flex Code
14803 \begin_layout Plain Layout
14805 \change_inserted -712698321 1353693235
14811 ] Resets the LaTeX arguments of this style (as defined via the
14812 \begin_inset Flex Code
14815 \begin_layout Plain Layout
14817 \change_inserted -712698321 1353693371
14826 This is useful if you have copied a style via
14827 \begin_inset Flex Code
14830 \begin_layout Plain Layout
14832 \change_inserted -712698321 1353693302
14840 , but you do not want to inherit its (required and optional) arguments.
14845 \begin_layout Description
14847 \change_inserted -712698321 1354263074
14848 \begin_inset Flex Code
14851 \begin_layout Plain Layout
14853 \change_inserted -712698321 1353866876
14860 \begin_inset Flex Code
14863 \begin_layout Plain Layout
14865 \change_inserted -712698321 1353866873
14871 ] A string that is put at the end of the layout content.
14872 A line break in the output can be indicated by
14873 \begin_inset Flex Code
14876 \begin_layout Plain Layout
14878 \change_inserted -712698321 1354263069
14889 \begin_layout Description
14890 \begin_inset Flex Code
14893 \begin_layout Plain Layout
14900 \begin_inset Flex Code
14903 \begin_layout Plain Layout
14910 \begin_inset Flex Code
14913 \begin_layout Plain Layout
14922 \begin_layout Description
14923 \begin_inset Flex Code
14926 \begin_layout Plain Layout
14933 \begin_inset Flex Code
14936 \begin_layout Plain Layout
14945 \begin_inset Flex Code
14948 \begin_layout Plain Layout
14955 \begin_inset Flex Code
14958 \begin_layout Plain Layout
14965 \begin_inset Flex Code
14968 \begin_layout Plain Layout
14970 \begin_inset space ~
14978 ] This defines what the default spacing should be in the style.
14980 \begin_inset Flex Code
14983 \begin_layout Plain Layout
14990 \begin_inset Flex Code
14993 \begin_layout Plain Layout
15000 \begin_inset Flex Code
15003 \begin_layout Plain Layout
15009 correspond respectively to a multiplier value of 1, 1.25 and 1.667.
15010 If you specify the argument
15011 \begin_inset Flex Code
15014 \begin_layout Plain Layout
15020 , then you must also provide a value argument which will be the actual multiplie
15022 Note that, contrary to other parameters,
15023 \begin_inset Flex Code
15026 \begin_layout Plain Layout
15032 implies the generation of specific LaTeX code, using the LaTeX package
15036 \begin_inset Flex Code
15039 \begin_layout Plain Layout
15048 \begin_layout Description
15049 \begin_inset Flex Code
15052 \begin_layout Plain Layout
15059 \begin_inset Flex Code
15062 \begin_layout Plain Layout
15069 \begin_inset space \thinspace{}
15073 \begin_inset Flex Code
15076 \begin_layout Plain Layout
15084 ] Allow spell-checking paragraphs of this style.
15088 \begin_layout Description
15089 \begin_inset Flex Code
15092 \begin_layout Plain Layout
15098 The font used for the text body .
15100 \begin_inset CommandInset ref
15102 reference "sub:Font-description"
15109 \begin_layout Description
15110 \begin_inset Flex Code
15113 \begin_layout Plain Layout
15122 \begin_inset Flex Code
15125 \begin_layout Plain Layout
15135 The level of the style in the table of contents.
15136 This is used for automatic numbering of section headings.
15139 \begin_layout Description
15140 \begin_inset Flex Code
15143 \begin_layout Plain Layout
15150 \begin_inset Flex Code
15153 \begin_layout Plain Layout
15159 ] The vertical space with which the very first of a chain of paragraphs
15160 with this style is separated from the previous paragraph.
15161 If the previous paragraph has another style, the separations are not simply
15162 added, but the maximum is taken.
15165 \begin_layout Subsection
15166 \begin_inset CommandInset label
15172 Internationalization of Paragraph Styles
15175 \begin_layout Standard
15176 LyX has long supported internationalization of layout information, but,
15177 until version 2.0, this applied only to the user interface and not to, say,
15179 Thus, French authors were forced to resort to ugly hacks if they wanted
15184 1' instead of `Theorem 1'.
15185 Thanks to Georg Baum, that is no longer the case.
15188 \begin_layout Standard
15190 \begin_inset Flex Code
15193 \begin_layout Plain Layout
15199 defines text that is to appear in the typeset document, it may use
15200 \begin_inset Flex Code
15203 \begin_layout Plain Layout
15210 \begin_inset Flex Code
15213 \begin_layout Plain Layout
15219 to support non-English and even multi-language documents correctly.
15220 The following excerpt (from the
15221 \begin_inset Flex Code
15224 \begin_layout Plain Layout
15230 file) shows how this works:
15233 \begin_layout LyX-Code
15238 \begin_layout LyX-Code
15241 theoremstyle{remark}
15244 \begin_layout LyX-Code
15247 newtheorem{claim}[thm]{
15254 \begin_layout LyX-Code
15258 \begin_layout LyX-Code
15262 \begin_layout LyX-Code
15267 claimname}{_(Claim)}
15270 \begin_layout LyX-Code
15274 \begin_layout LyX-Code
15278 \begin_layout LyX-Code
15287 claimname}{_(Claim)}}
15290 \begin_layout LyX-Code
15295 \begin_layout Standard
15296 In principle, any legal LaTeX may appear in the
15297 \begin_inset Flex Code
15300 \begin_layout Plain Layout
15307 \begin_inset Flex Code
15310 \begin_layout Plain Layout
15316 tags, but in practice they will typically look as they do here.
15317 The key to correct translation of the typeset text is the definition of
15319 \begin_inset Flex Code
15322 \begin_layout Plain Layout
15331 \begin_inset Flex Code
15334 \begin_layout Plain Layout
15346 \begin_layout Standard
15348 \begin_inset Flex Code
15351 \begin_layout Plain Layout
15357 tag provides for internationalization based upon the overall language of
15359 The contents of the tag will be included in the preamble, just as with
15361 \begin_inset Flex Code
15364 \begin_layout Plain Layout
15371 What makes it special is the use of the
15372 \begin_inset Quotes eld
15376 \begin_inset Quotes erd
15380 \begin_inset Flex Code
15383 \begin_layout Plain Layout
15389 , which will be replaced, when LyX produces LaTeX output, with the translation
15390 of its argument into the document language.
15393 \begin_layout Standard
15395 \begin_inset Flex Code
15398 \begin_layout Plain Layout
15404 tag is more complex, since it is meant to provide support for multi-language
15405 documents and so offers an interface to the
15406 \begin_inset Flex Code
15409 \begin_layout Plain Layout
15416 Its contents will be added to the preamble once for each language that
15417 appears in the document.
15418 In this case, the argument to
15419 \begin_inset Flex Code
15422 \begin_layout Plain Layout
15428 will be replaced with its translation into the language in question; the
15430 \begin_inset Flex Code
15433 \begin_layout Plain Layout
15439 is replaced by the language name (as used by the babel package).
15442 \begin_layout Standard
15443 A German document that also included a French section would thus have the
15444 following in the preamble:
15447 \begin_layout LyX-Code
15456 claimname}{Affirmation}}
15457 \begin_inset Newline newline
15468 claimname}{Behauptung}}
15469 \begin_inset Newline newline
15476 claimname}{Behauptung}
15479 \begin_layout Standard
15481 \begin_inset Flex Code
15484 \begin_layout Plain Layout
15490 will then conspire to produce the correct text in the output.
15493 \begin_layout Standard
15494 One important point to note here is that the translations are provided by
15495 LyX itself, through the
15496 \change_inserted -195340706 1334775793
15498 \begin_inset Flex Code
15501 \begin_layout Plain Layout
15503 \change_inserted -195340706 1334775793
15510 \change_deleted -195340706 1334775793
15511 same mechanism it uses for internationalization of the user interface
15514 This means, in effect, that
15515 \begin_inset Flex Code
15518 \begin_layout Plain Layout
15525 \begin_inset Flex Code
15528 \begin_layout Plain Layout
15534 are really only of use in layout files that are provided with LyX, since
15535 text entered in user-created layout files will not be seen by LyX's internation
15537 \change_inserted -195340706 1334775793
15539 \begin_inset Flex Code
15542 \begin_layout Plain Layout
15544 \change_inserted -195340706 1334775793
15550 file is modified accordingly
15553 That said, however, any layout created with the intention that it will
15554 be included with LyX should use these tags where appropriate.
15556 \change_inserted -195340706 1334775793
15557 Please note that the paragraph style translations provided by LyX will
15558 never change with a minor update (e.g.
15559 from version 2.1.x to 2.1.y).
15560 It is however quite likely that a major update (e.g.
15561 from 2.0.x to 2.1.y) will introduce new translations or corrections.
15566 \begin_layout Subsection
15568 \begin_inset CommandInset label
15577 \begin_layout Standard
15578 It is necessary to define the floats (
15579 \begin_inset Flex MenuItem
15582 \begin_layout Plain Layout
15589 \begin_inset Flex MenuItem
15592 \begin_layout Plain Layout
15598 , \SpecialChar \ldots{}
15599 ) in the text class itself.
15600 Standard floats are included in the file
15601 \begin_inset Flex Code
15604 \begin_layout Plain Layout
15610 , so you may have to do no more than add
15613 \begin_layout LyX-Code
15614 Input stdfloats.inc
15617 \begin_layout Standard
15618 to your layout file.
15619 If you want to implement a text class that proposes some other float types
15620 (like the AGU class bundled with LyX), the information below will hopefully
15624 \begin_layout Description
15625 \begin_inset Flex Code
15628 \begin_layout Plain Layout
15635 \begin_inset Flex Code
15638 \begin_layout Plain Layout
15645 \begin_inset Quotes erd
15649 \begin_inset Quotes erd
15652 ] The file name extension of an auxiliary file for the list of figures (or
15654 LaTeX writes the captions to this file.
15657 \begin_layout Description
15658 \begin_inset Flex Code
15661 \begin_layout Plain Layout
15668 \begin_inset Flex Code
15671 \begin_layout Plain Layout
15678 \begin_inset Quotes erd
15682 \begin_inset Quotes erd
15685 ] The string that will be used in the menus and also for the caption.
15686 This is translated to the current language if babel is used.
15689 \begin_layout Description
15690 \begin_inset Flex Code
15693 \begin_layout Plain Layout
15699 These tags control the XHTML output.
15701 \begin_inset space ~
15705 \begin_inset CommandInset ref
15707 reference "sec:Tags-for-XHTML"
15714 \begin_layout Description
15715 \begin_inset Flex Code
15718 \begin_layout Plain Layout
15727 \begin_inset Flex Code
15730 \begin_layout Plain Layout
15739 \begin_inset space \thinspace{}
15743 \begin_inset Flex Code
15746 \begin_layout Plain Layout
15752 ] Indicates whether the float is already defined in the document class or
15753 if instead the LaTeX package
15754 \begin_inset Flex Code
15757 \begin_layout Plain Layout
15763 needs to be loaded to define it on-the-fly.
15765 \begin_inset Flex Code
15768 \begin_layout Plain Layout
15775 \begin_inset Flex Code
15778 \begin_layout Plain Layout
15785 It should be set to
15786 \begin_inset Flex Code
15789 \begin_layout Plain Layout
15795 if the float is already defined by the LaTeX document class.
15798 \begin_layout Description
15799 \begin_inset Flex Code
15802 \begin_layout Plain Layout
15809 \begin_inset Flex Code
15812 \begin_layout Plain Layout
15819 \begin_inset Quotes erd
15823 \begin_inset Quotes erd
15826 ] The command used to generate a list of floats of this type; the leading
15835 \begin_inset Flex Code
15838 \begin_layout Plain Layout
15844 is false, since there is no standard way to generate this command.
15846 \begin_inset Flex Code
15849 \begin_layout Plain Layout
15855 is true, since in that case there is a standard way to define the command.
15858 \begin_layout Description
15859 \begin_inset Flex Code
15862 \begin_layout Plain Layout
15869 \begin_inset Flex Code
15872 \begin_layout Plain Layout
15879 \begin_inset Quotes erd
15883 \begin_inset Quotes erd
15886 ] A title for a list of floats of this kind (list of figures, tables, or
15888 It is used for the screen label within LyX, it is used by LaTeX for the
15889 title and it is used as the title in the XHTML output.
15890 It will be translated to the document language.
15893 \begin_layout Description
15894 \begin_inset Flex Code
15897 \begin_layout Plain Layout
15904 \begin_inset Flex Code
15907 \begin_layout Plain Layout
15914 \begin_inset Quotes erd
15918 \begin_inset Quotes erd
15921 ] This (optional) argument determines whether floats of this class will
15922 be numbered within some sectional unit of the document.
15924 \begin_inset Flex Code
15927 \begin_layout Plain Layout
15934 \begin_inset Quotes eld
15938 \begin_inset Flex Code
15941 \begin_layout Plain Layout
15948 \begin_inset Quotes erd
15951 , the floats will be numbered within chapters.
15955 \begin_layout Description
15956 \begin_inset Flex Code
15959 \begin_layout Plain Layout
15966 \begin_inset Flex Code
15969 \begin_layout Plain Layout
15976 \begin_inset Quotes erd
15980 \begin_inset Quotes erd
15983 ] The default placement for the given class of floats.
15984 The string should be as in standard LaTeX:
15985 \begin_inset Flex Code
15988 \begin_layout Plain Layout
15995 \begin_inset Flex Code
15998 \begin_layout Plain Layout
16005 \begin_inset Flex Code
16008 \begin_layout Plain Layout
16015 \begin_inset Flex Code
16018 \begin_layout Plain Layout
16024 for top, bottom, page, and here, respectively.
16028 \begin_layout Plain Layout
16029 Note that the order of these letters in the string is irrelevant, like in
16035 On top of that there is a new type,
16036 \begin_inset Flex Code
16039 \begin_layout Plain Layout
16045 , which does not really correspond to a float, since it means: put it
16046 \begin_inset Quotes eld
16050 \begin_inset Quotes erd
16054 Note however that the
16055 \begin_inset Flex Code
16058 \begin_layout Plain Layout
16064 specifier is special and, because of implementation details, cannot be
16065 used in non-built in float types.
16066 If you do not understand what this means, just use
16067 \begin_inset Quotes eld
16071 \begin_inset Flex Code
16074 \begin_layout Plain Layout
16081 \begin_inset Quotes erd
16087 \begin_layout Description
16088 \begin_inset Flex Code
16091 \begin_layout Plain Layout
16098 \begin_inset Flex Code
16101 \begin_layout Plain Layout
16107 ] The prefix to use when creating labels referring to floats of this type.
16108 This allows the use of formatted references.
16109 Note that you can remove any
16110 \begin_inset Flex Code
16113 \begin_layout Plain Layout
16119 set by a copied style by using the special value
16120 \begin_inset Quotes eld
16124 \begin_inset Quotes erd
16127 , which must be all caps.
16130 \begin_layout Description
16131 \begin_inset Flex Code
16134 \begin_layout Plain Layout
16141 \begin_inset Flex Code
16144 \begin_layout Plain Layout
16151 \begin_inset Quotes erd
16155 \begin_inset Quotes erd
16158 ] The style used when defining the float using
16159 \begin_inset Flex Code
16162 \begin_layout Plain Layout
16173 \begin_layout Description
16174 \begin_inset Flex Code
16177 \begin_layout Plain Layout
16184 \begin_inset Flex Code
16187 \begin_layout Plain Layout
16194 \begin_inset Quotes erd
16198 \begin_inset Quotes erd
16202 \begin_inset Quotes eld
16206 \begin_inset Quotes erd
16209 of the new class of floats, like program or algorithm.
16210 After the appropriate
16211 \begin_inset Flex Code
16214 \begin_layout Plain Layout
16223 \begin_inset Flex Code
16226 \begin_layout Plain Layout
16235 \begin_inset Flex Code
16238 \begin_layout Plain Layout
16249 \begin_layout Description
16250 \begin_inset Flex Code
16253 \begin_layout Plain Layout
16260 \begin_inset Flex Code
16263 \begin_layout Plain Layout
16270 \begin_inset space \thinspace{}
16274 \begin_inset Flex Code
16277 \begin_layout Plain Layout
16285 ] Specifies whether this float is defined using the LaTeX package
16286 \begin_inset Flex Code
16289 \begin_layout Plain Layout
16295 , either by the class file, another package or on-the-fly by LyX itself.
16298 \begin_layout Standard
16299 Note that defining a float with type
16300 \begin_inset Flex Code
16303 \begin_layout Plain Layout
16311 automatically defines the corresponding counter with name
16312 \begin_inset Flex Code
16315 \begin_layout Plain Layout
16326 \begin_layout Subsection
16327 Flex insets and InsetLayout
16328 \begin_inset CommandInset label
16330 name "sub:Flex-insets-and"
16337 \begin_layout Standard
16338 Flex insets come in three different kinds:
16341 \begin_layout Itemize
16343 \begin_inset Flex Code
16346 \begin_layout Plain Layout
16352 ): These define semantic markup corresponding to such LaTeX commands as
16354 \begin_inset Flex Code
16357 \begin_layout Plain Layout
16366 \begin_inset Flex Code
16369 \begin_layout Plain Layout
16380 \begin_layout Itemize
16382 \begin_inset Flex Code
16385 \begin_layout Plain Layout
16391 ): These can be used to define custom collapsible insets, similar to TeX
16392 code, footnote, and the like.
16393 An obvious example is an endnote inset, which is defined in the
16394 \begin_inset Flex Code
16397 \begin_layout Plain Layout
16406 \begin_layout Itemize
16408 \begin_inset Flex Code
16411 \begin_layout Plain Layout
16417 ): For use with DocBook classes.
16420 \begin_layout Standard
16421 Flex insets are defined using the
16422 \begin_inset Flex Code
16425 \begin_layout Plain Layout
16431 tag, which shall be explained in a moment.
16434 \begin_layout Standard
16436 \begin_inset Flex Code
16439 \begin_layout Plain Layout
16445 tag also serves another function: It can be used to customize the general
16446 layout of many different types of insets.
16448 \begin_inset Flex Code
16451 \begin_layout Plain Layout
16457 can be used to customize the layout parameters for footnotes, marginal
16458 notes, note insets, TeX code (ERT) insets, branches, listings, indexes,
16459 boxes, tables, algorithms, URLs, and
16460 \change_deleted -712698321 1356964515
16462 \change_inserted -712698321 1356964516
16465 s, as well as to define Flex insets.
16468 \begin_layout Standard
16470 \begin_inset Flex Code
16473 \begin_layout Plain Layout
16479 definition must begin with a line of the form:
16482 \begin_layout LyX-Code
16486 \begin_layout Standard
16488 \begin_inset Flex Code
16491 \begin_layout Plain Layout
16497 indicates the inset whose layout is being defined, and here there are
16498 \change_deleted -712698321 1356964888
16500 \change_inserted -712698321 1356964888
16502 \change_deleted 5863208 1334489267
16508 \begin_layout Enumerate
16509 The layout for a pre-existing inset is being modified.
16510 In this case, can be
16511 \begin_inset Flex Code
16514 \begin_layout Plain Layout
16520 any one of the following:
16521 \begin_inset Flex Code
16524 \begin_layout Plain Layout
16531 \begin_inset Flex Code
16534 \begin_layout Plain Layout
16541 \begin_inset Flex Code
16544 \begin_layout Plain Layout
16551 \begin_inset Flex Code
16554 \begin_layout Plain Layout
16561 \change_inserted -712698321 1356964563
16563 \begin_inset Flex Code
16566 \begin_layout Plain Layout
16568 \change_inserted -712698321 1356964560
16579 \begin_inset Flex Code
16582 \begin_layout Plain Layout
16589 \begin_inset Flex Code
16592 \begin_layout Plain Layout
16599 \begin_inset Flex Code
16602 \begin_layout Plain Layout
16609 \begin_inset Flex Code
16612 \begin_layout Plain Layout
16619 \begin_inset Flex Code
16622 \begin_layout Plain Layout
16629 \begin_inset Flex Code
16632 \begin_layout Plain Layout
16639 \begin_inset Flex Code
16642 \begin_layout Plain Layout
16649 \begin_inset Flex Code
16652 \begin_layout Plain Layout
16659 \begin_inset Flex Code
16662 \begin_layout Plain Layout
16669 \begin_inset Flex Code
16672 \begin_layout Plain Layout
16679 \begin_inset Flex Code
16682 \begin_layout Plain Layout
16689 \begin_inset Flex Code
16692 \begin_layout Plain Layout
16699 \begin_inset Flex Code
16702 \begin_layout Plain Layout
16709 \change_deleted -712698321 1356964592
16711 \begin_inset Flex Code
16714 \begin_layout Plain Layout
16716 \change_deleted -712698321 1353866704
16720 \change_inserted -712698321 1353866707
16731 \begin_inset Flex Code
16734 \begin_layout Plain Layout
16741 \begin_inset Flex Code
16744 \begin_layout Plain Layout
16753 \begin_layout Enumerate
16754 The layout for a Flex inset is being defined.
16756 \begin_inset Flex Code
16759 \begin_layout Plain Layout
16765 must be of the form
16766 \begin_inset Quotes eld
16770 \begin_inset Flex Code
16773 \begin_layout Plain Layout
16780 \begin_inset Quotes erd
16784 \begin_inset Flex Code
16787 \begin_layout Plain Layout
16793 may be be any valid identifier not used by a pre-existing Flex inset.
16794 The identifier may include spaces, but in that case the whole thing must
16795 be wrapped in quotes.
16796 Note that the definition of a flex inset
16801 \begin_inset Flex Code
16804 \begin_layout Plain Layout
16810 entry, declaring which type of inset it defines.
16811 \change_inserted 5863208 1334489312
16815 \begin_layout Enumerate
16817 \change_inserted 5863208 1334492248
16818 The layout for user specific branch is being defined.
16820 \begin_inset Flex Code
16823 \begin_layout Plain Layout
16825 \change_inserted 5863208 1334489384
16831 must be of the form
16832 \begin_inset Quotes eld
16836 \begin_inset Flex Code
16839 \begin_layout Plain Layout
16841 \change_inserted 5863208 1334489392
16848 \begin_inset Quotes erd
16852 \begin_inset Flex Code
16855 \begin_layout Plain Layout
16857 \change_inserted 5863208 1334489384
16863 may be be any valid identifier of branch defined in user's document.
16864 The identifier may include spaces, but in that case the whole thing must
16865 be wrapped in quotes.
16866 The main purpose of this feature is to allow LaTeX wrapping around specific
16867 branches as user needs.
16868 \change_inserted -712698321 1356964893
16872 \begin_layout Enumerate
16874 \change_inserted -712698321 1356965125
16875 The layout of a user (or class) specific caption is being defined.
16877 \begin_inset Flex Code
16880 \begin_layout Plain Layout
16882 \change_inserted -712698321 1356964939
16888 must be of the form
16889 \begin_inset Quotes eld
16893 \begin_inset Flex Code
16896 \begin_layout Plain Layout
16898 \change_inserted -712698321 1356964943
16905 \begin_inset Quotes erd
16909 \begin_inset Flex Code
16912 \begin_layout Plain Layout
16914 \change_inserted -712698321 1356964939
16920 specifies the name of the caption as it appears in the menu.
16921 Have a look at the standard caption (
16922 \begin_inset Flex Code
16925 \begin_layout Plain Layout
16927 \change_inserted -712698321 1356964987
16933 ), the specific captions of the KOMA-Script classes (
16934 \begin_inset Flex Code
16937 \begin_layout Plain Layout
16939 \change_inserted -712698321 1356965018
16946 \begin_inset Flex Code
16949 \begin_layout Plain Layout
16951 \change_inserted -712698321 1356965021
16962 \begin_inset Flex Code
16965 \begin_layout Plain Layout
16967 \change_inserted -712698321 1356965045
16973 ) for applications.
16978 \begin_layout Standard
16980 \begin_inset Flex Code
16983 \begin_layout Plain Layout
16989 definition can contain the following entries:
16992 \begin_layout Description
16994 \change_inserted -712698321 1353681390
16995 \begin_inset Flex Code
16998 \begin_layout Plain Layout
17000 \change_inserted -712698321 1353681344
17007 \begin_inset Flex Code
17010 \begin_layout Plain Layout
17012 \change_inserted -712698321 1353681344
17018 ] Defines argument number <int> of a command\SpecialChar \slash{}
17019 environment associated with
17020 the current layout.
17021 The definition must end with
17022 \begin_inset Flex Code
17025 \begin_layout Plain Layout
17027 \change_inserted -712698321 1353681344
17035 \begin_inset space ~
17039 \begin_inset CommandInset ref
17041 reference "sub:Paragraph-Styles"
17048 \begin_layout Description
17050 \change_inserted -195340706 1333913893
17051 \begin_inset Flex Code
17054 \begin_layout Plain Layout
17060 Preamble for changing languages.
17062 \begin_inset space ~
17066 \begin_inset CommandInset ref
17068 reference "sub:I18n"
17075 \begin_layout Description
17076 \begin_inset Flex Code
17079 \begin_layout Plain Layout
17086 \begin_inset Flex Code
17089 \begin_layout Plain Layout
17095 ] The color for the inset's background.
17097 \begin_inset space ~
17101 \begin_inset CommandInset ref
17103 reference "chap:Names-of-colors"
17107 for a list of the available color names.
17110 \begin_layout Description
17111 \begin_inset Flex Code
17114 \begin_layout Plain Layout
17121 \begin_inset Flex Code
17124 \begin_layout Plain Layout
17133 \begin_inset space \thinspace{}
17137 \begin_inset Flex Code
17140 \begin_layout Plain Layout
17146 ] Whether to use the content of the inset as the label, when the inset is
17151 \begin_layout Description
17152 \begin_inset Flex Code
17155 \begin_layout Plain Layout
17162 \begin_inset Flex Code
17165 \begin_layout Plain Layout
17171 ] As with paragraph styles, see sec.
17172 \begin_inset space ~
17176 \begin_inset CommandInset ref
17178 reference "sub:Paragraph-Styles"
17183 Note that you need to specify the complete type, e.
17184 \begin_inset space \thinspace{}
17188 \begin_inset space ~
17192 \begin_inset Flex Code
17195 \begin_layout Plain Layout
17196 CopyStyle Flex:<name>
17204 \begin_layout Description
17205 \begin_inset Flex Code
17208 \begin_layout Plain Layout
17215 \begin_inset Flex Code
17218 \begin_layout Plain Layout
17227 \begin_inset space \thinspace{}
17231 \begin_inset Flex Code
17234 \begin_layout Plain Layout
17240 ] Indicates whether the user may employ the Paragraph Settings dialog to
17241 customize the paragraph.
17244 \begin_layout Description
17245 \begin_inset Flex Code
17248 \begin_layout Plain Layout
17255 \begin_inset Flex Code
17258 \begin_layout Plain Layout
17265 \begin_inset Flex Code
17268 \begin_layout Plain Layout
17275 \begin_inset Flex Code
17278 \begin_layout Plain Layout
17284 , describing the rendering style used for the inset's frame and buttons.
17285 Footnotes generally use
17286 \begin_inset Flex Code
17289 \begin_layout Plain Layout
17295 , ERT insets generally
17296 \begin_inset Flex Code
17299 \begin_layout Plain Layout
17305 , and character styles
17306 \begin_inset Flex Code
17309 \begin_layout Plain Layout
17318 \begin_layout Description
17319 \begin_inset Flex Code
17322 \begin_layout Plain Layout
17329 \begin_inset Flex Code
17332 \begin_layout Plain Layout
17341 \begin_inset space \thinspace{}
17347 \begin_inset Flex Code
17350 \begin_layout Plain Layout
17359 \begin_inset Flex Code
17362 \begin_layout Plain Layout
17369 \begin_inset Flex Code
17372 \begin_layout Plain Layout
17379 Indicates whether the environment will stand on its own in the output or
17380 will appear inline with the surrounding text.
17381 If set to false, it is supposed that the LaTeX environment ignores white
17382 space (including one newline character) after the
17383 \begin_inset Flex Code
17386 \begin_layout Plain Layout
17399 \begin_inset Flex Code
17402 \begin_layout Plain Layout
17418 \begin_layout Description
17419 \begin_inset Flex Code
17422 \begin_layout Plain Layout
17428 Required at the end of the
17429 \begin_inset Flex Code
17432 \begin_layout Plain Layout
17441 \begin_layout Description
17442 \begin_inset Flex Code
17445 \begin_layout Plain Layout
17451 The font used for both the text body
17457 \begin_inset space ~
17461 \begin_inset CommandInset ref
17463 reference "sub:Font-description"
17468 Note that defining this font automatically defines the
17469 \begin_inset Flex Code
17472 \begin_layout Plain Layout
17478 to the same value, so define this first and define
17479 \begin_inset Flex Code
17482 \begin_layout Plain Layout
17488 later if you want them to be different.
17489 \change_inserted 155139281 1354130923
17493 \begin_layout Description
17495 \change_inserted 155139281 1354130923
17496 \begin_inset Flex Code
17499 \begin_layout Plain Layout
17501 \change_inserted 155139281 1354130923
17502 ForceLocalFontSwitch
17508 \begin_inset Flex Code
17511 \begin_layout Plain Layout
17513 \change_inserted 155139281 1354130923
17522 \begin_inset Flex Code
17525 \begin_layout Plain Layout
17527 \change_inserted 155139281 1354130923
17533 ] When using babel, always use a local font switch (
17534 \begin_inset Flex Code
17537 \begin_layout Plain Layout
17539 \change_inserted 155139281 1354130923
17547 ), never a global one (such as
17548 \begin_inset Flex Code
17551 \begin_layout Plain Layout
17553 \change_inserted 155139281 1354130923
17566 \begin_layout Description
17567 \begin_inset Flex Code
17570 \begin_layout Plain Layout
17577 \begin_inset Flex Code
17580 \begin_layout Plain Layout
17589 \begin_inset space \thinspace{}
17593 \begin_inset Flex Code
17596 \begin_layout Plain Layout
17603 \begin_inset Quotes eld
17607 \begin_inset Quotes erd
17610 language, leading to Left-to-Right (Latin) output, e.
17611 \begin_inset space \thinspace{}
17615 \begin_inset space \space{}
17618 in TeX code or URL.
17622 \begin_layout Description
17623 \begin_inset Flex Code
17626 \begin_layout Plain Layout
17633 \begin_inset Flex Code
17636 \begin_layout Plain Layout
17645 \begin_inset space \thinspace{}
17649 \begin_inset Flex Code
17652 \begin_layout Plain Layout
17658 ] Indicates whether the
17659 \begin_inset Flex Code
17662 \begin_layout Plain Layout
17668 should be used or, instead, the user can change the paragraph style used
17673 \begin_layout Description
17674 \begin_inset Flex Code
17677 \begin_layout Plain Layout
17684 \begin_inset Flex Code
17687 \begin_layout Plain Layout
17696 \begin_inset space \thinspace{}
17700 \begin_inset Flex Code
17703 \begin_layout Plain Layout
17709 ] As with paragraph styles, see sec.
17710 \begin_inset space ~
17714 \begin_inset CommandInset ref
17716 reference "sub:Paragraph-Styles"
17723 \begin_layout Description
17724 \begin_inset Flex Code
17727 \begin_layout Plain Layout
17733 These tags control the XHTML output.
17735 \begin_inset space ~
17739 \begin_inset CommandInset ref
17741 reference "sec:Tags-for-XHTML"
17748 \begin_layout Description
17749 \begin_inset Flex Code
17752 \begin_layout Plain Layout
17759 \begin_inset Flex Code
17762 \begin_layout Plain Layout
17771 \begin_inset space \thinspace{}
17775 \begin_inset Flex Code
17778 \begin_layout Plain Layout
17784 ] Whether to include the contents of this inset in the strings generated
17785 for the `Outline' pane.
17786 One would not, for example, want the content of a footnote in a section
17787 header to be included in the TOC displayed in the outline, but one would
17788 normally want the content of a character style displayed.
17789 Default is false: not to include.
17792 \begin_layout Description
17793 \begin_inset Flex Code
17796 \begin_layout Plain Layout
17805 \begin_inset Flex Code
17808 \begin_layout Plain Layout
17817 \begin_inset space \thinspace{}
17821 \begin_inset Flex Code
17824 \begin_layout Plain Layout
17830 ] As with paragraph styles, see sec.
17831 \begin_inset space ~
17835 \begin_inset CommandInset ref
17837 reference "sub:Paragraph-Styles"
17844 \begin_layout Description
17845 \begin_inset Flex Code
17848 \begin_layout Plain Layout
17854 The font used for the label.
17856 \begin_inset space ~
17860 \begin_inset CommandInset ref
17862 reference "sub:Font-description"
17867 Note that this definition can never appear before
17868 \begin_inset Flex Code
17871 \begin_layout Plain Layout
17877 , lest it be ineffective.
17880 \begin_layout Description
17881 \begin_inset Flex Code
17884 \begin_layout Plain Layout
17891 \begin_inset Flex Code
17894 \begin_layout Plain Layout
17901 \begin_inset Quotes erd
17905 \begin_inset Quotes erd
17908 ] What will be displayed on the button or elsewhere as the inset label.
17910 \begin_inset Flex Code
17913 \begin_layout Plain Layout
17920 \begin_inset Flex Code
17923 \begin_layout Plain Layout
17929 ) modify this label on the fly.
17932 \begin_layout Description
17934 \change_inserted -195340706 1333913893
17935 \begin_inset Flex Code
17938 \begin_layout Plain Layout
17944 Language dependent preamble.
17946 \begin_inset space ~
17950 \begin_inset CommandInset ref
17952 reference "sub:I18n"
17959 \begin_layout Description
17960 \begin_inset Flex Code
17963 \begin_layout Plain Layout
17970 \begin_inset Flex Code
17973 \begin_layout Plain Layout
17979 ] The name of the corresponding LaTeX stuff.
17980 Either the environment or command name.
17983 \begin_layout Description
17984 \begin_inset Flex Code
17987 \begin_layout Plain Layout
17994 \begin_inset Flex Code
17997 \begin_layout Plain Layout
18003 ] The optional parameter for the corresponding
18004 \begin_inset Flex Code
18007 \begin_layout Plain Layout
18013 stuff, including possible bracket pairs like
18014 \begin_inset Flex Code
18017 \begin_layout Plain Layout
18025 \change_inserted -712698321 1355144715
18026 This will be output as is after all LaTeX
18027 \begin_inset Flex Code
18030 \begin_layout Plain Layout
18032 \change_inserted -712698321 1355144713
18041 This parameter cannot be changed from within LyX
18042 \change_inserted -712698321 1355144775
18044 \begin_inset Flex Code
18047 \begin_layout Plain Layout
18049 \change_inserted -712698321 1355144747
18055 for customizable parameters)
18060 \begin_layout Description
18061 \begin_inset Flex Code
18064 \begin_layout Plain Layout
18071 \begin_inset Flex Code
18074 \begin_layout Plain Layout
18076 \change_deleted -712698321 1353867544
18083 Command, Environment,
18084 \change_inserted -712698321 1353867573
18086 \change_deleted -712698321 1353867557
18095 \begin_inset Flex Code
18098 \begin_layout Plain Layout
18100 \change_deleted -712698321 1353867564
18104 \change_deleted -712698321 1353867569
18112 ] How the style should be translated into LaTeX.
18116 \begin_layout Plain Layout
18117 \begin_inset Flex Code
18120 \begin_layout Plain Layout
18126 is perhaps a bit misleading, since these rules apply to SGML classes, too.
18127 Visit the SGML class files for specific examples.
18136 \begin_layout Description
18137 \begin_inset Flex Code
18140 \begin_layout Plain Layout
18142 \change_deleted -712698321 1353867582
18144 \change_inserted -712698321 1353867583
18152 means nothing special.
18156 \begin_layout Description
18157 \begin_inset Flex Code
18160 \begin_layout Plain Layout
18167 \begin_inset Flex Code
18170 \begin_layout Plain Layout
18177 {\SpecialChar \ldots{}
18186 \begin_layout Description
18187 \begin_inset Flex Code
18190 \begin_layout Plain Layout
18197 \begin_inset Flex Code
18200 \begin_layout Plain Layout
18207 }\SpecialChar \ldots{}
18223 \begin_layout Description
18225 \change_deleted -712698321 1353867600
18226 \begin_inset Flex Code
18229 \begin_layout Plain Layout
18236 \begin_inset Flex Code
18239 \begin_layout Plain Layout
18246 \begin_inset Flex Code
18249 \begin_layout Plain Layout
18257 is generated for each paragraph of this environment.
18261 \begin_layout Description
18263 \change_deleted -712698321 1353867600
18264 \begin_inset Flex Code
18267 \begin_layout Plain Layout
18274 \begin_inset Flex Code
18277 \begin_layout Plain Layout
18284 \begin_inset Flex Code
18287 \begin_layout Plain Layout
18293 is passed as an argument to the environment.
18295 \begin_inset Flex Code
18298 \begin_layout Plain Layout
18304 can be defined in the
18305 \begin_inset Flex MenuItem
18308 \begin_layout Plain Layout
18313 \SpecialChar \menuseparator
18319 \begin_inset space ~
18333 \begin_layout Standard
18334 Putting the last few things together, the LaTeX output will be either:
18337 \begin_layout LyX-Code
18341 \change_deleted 2090807402 1356919073
18343 \change_inserted 2090807402 1356919073
18347 \change_deleted 2090807402 1356919073
18349 \change_inserted 2090807402 1356919002
18352 ]{\SpecialChar \ldots{}
18356 \begin_layout Standard
18360 \begin_layout LyX-Code
18364 \change_deleted 2090807402 1356919013
18366 \change_inserted 2090807402 1356919014
18370 \change_deleted 2090807402 1356919013
18372 \change_inserted 2090807402 1356919008
18375 ] \SpecialChar \ldots{}
18379 \change_deleted 2090807402 1356919016
18381 \change_inserted 2090807402 1356919016
18387 \begin_layout Standard
18388 depending upon the LaTeX type.
18392 \begin_layout Description
18394 \change_inserted -712698321 1354263128
18395 \begin_inset Flex Code
18398 \begin_layout Plain Layout
18400 \change_inserted -712698321 1353866742
18409 \begin_inset Flex Code
18412 \begin_layout Plain Layout
18414 \change_inserted -712698321 1353866752
18420 ] A string that is put at the beginning of the layout content.
18421 A line break in the output can be indicated by
18422 \begin_inset Flex Code
18425 \begin_layout Plain Layout
18427 \change_inserted -712698321 1354263128
18438 \begin_layout Description
18439 \begin_inset Flex Code
18442 \begin_layout Plain Layout
18449 \begin_inset Flex Code
18452 \begin_layout Plain Layout
18459 \begin_inset Flex Code
18462 \begin_layout Plain Layout
18469 \begin_inset Flex Code
18472 \begin_layout Plain Layout
18479 \begin_inset Flex Code
18482 \begin_layout Plain Layout
18488 (indicating a dummy definition ending definitions of charstyles, etc).
18489 This entry is required in and is only meaningful for Flex insets.
18490 Among other things, it determines on which menu this inset will appear.
18492 \begin_inset Flex Code
18495 \begin_layout Plain Layout
18502 \begin_inset Flex Code
18505 \begin_layout Plain Layout
18511 will automatically set
18512 \begin_inset Flex Code
18515 \begin_layout Plain Layout
18523 \begin_inset Flex Code
18526 \begin_layout Plain Layout
18532 can be set to true for
18533 \begin_inset Flex Code
18536 \begin_layout Plain Layout
18542 insets by setting it
18547 \begin_inset Flex Code
18550 \begin_layout Plain Layout
18559 \begin_layout Description
18560 \begin_inset Flex Code
18563 \begin_layout Plain Layout
18570 \begin_inset Flex Code
18573 \begin_layout Plain Layout
18582 \begin_inset space \thinspace{}
18586 \begin_inset Flex Code
18589 \begin_layout Plain Layout
18595 ] Whether multiple paragraphs are permitted in this inset.
18597 \begin_inset Flex Code
18600 \begin_layout Plain Layout
18606 to the same value and
18607 \begin_inset Flex Code
18610 \begin_layout Plain Layout
18616 to the opposite value.
18617 These can be reset to other values, if they are used
18622 \begin_inset Flex Code
18625 \begin_layout Plain Layout
18635 \begin_layout Description
18636 \begin_inset Flex Code
18639 \begin_layout Plain Layout
18646 \begin_inset Flex Code
18649 \begin_layout Plain Layout
18658 \begin_inset space \thinspace{}
18662 \begin_inset Flex Code
18665 \begin_layout Plain Layout
18671 ] Whether fragile commands in this inset should be
18672 \begin_inset Flex Code
18675 \begin_layout Plain Layout
18688 whether the command should itself be protected.) Default is false.
18689 \change_inserted 1414654397 1360681873
18693 \begin_layout Description
18695 \change_inserted 1414654397 1360681892
18696 \begin_inset Flex Code
18699 \begin_layout Plain Layout
18701 \change_inserted 1414654397 1360681880
18708 \begin_inset Flex Code
18711 \begin_layout Plain Layout
18713 \change_inserted 1414654397 1360681883
18719 ] Deletes an existing
18720 \begin_inset Flex Code
18723 \begin_layout Plain Layout
18725 \change_inserted 1414654397 1360681892
18736 \begin_layout Description
18737 \begin_inset Flex Code
18740 \begin_layout Plain Layout
18747 \begin_inset Flex Code
18750 \begin_layout Plain Layout
18759 \begin_inset space \thinspace{}
18763 \begin_inset Flex Code
18766 \begin_layout Plain Layout
18772 ] As with paragraph styles, see sec.
18773 \begin_inset space ~
18777 \begin_inset CommandInset ref
18779 reference "sub:Paragraph-Styles"
18787 \begin_layout Description
18788 \begin_inset Flex Code
18791 \begin_layout Plain Layout
18798 \begin_inset Flex Code
18801 \begin_layout Plain Layout
18810 \begin_inset space \thinspace{}
18814 \begin_inset Flex Code
18817 \begin_layout Plain Layout
18823 ] As with paragraph styles, see sec.
18824 \begin_inset space ~
18828 \begin_inset CommandInset ref
18830 reference "sub:Paragraph-Styles"
18838 \begin_layout Description
18839 \begin_inset Flex Code
18842 \begin_layout Plain Layout
18848 As with paragraph styles, see sec.
18849 \begin_inset space ~
18853 \begin_inset CommandInset ref
18855 reference "sub:Paragraph-Styles"
18862 \begin_layout Description
18863 \begin_inset Flex Code
18866 \begin_layout Plain Layout
18873 \begin_inset Flex Code
18876 \begin_layout Plain Layout
18882 ] The prefix to use when creating labels referring to insets of this type.
18883 This allows the use of formatted references.
18886 \begin_layout Description
18887 \begin_inset Flex Code
18890 \begin_layout Plain Layout
18897 \begin_inset Flex Code
18900 \begin_layout Plain Layout
18906 ] As with paragraph styles, see sec.
18907 \begin_inset space ~
18911 \begin_inset CommandInset ref
18913 reference "sub:Paragraph-Styles"
18918 \change_inserted -712698321 1354439699
18922 \begin_layout Description
18924 \change_inserted -712698321 1354439705
18925 \begin_inset Flex Code
18928 \begin_layout Plain Layout
18930 \change_inserted -712698321 1354439699
18937 \begin_inset Flex Code
18940 \begin_layout Plain Layout
18942 \change_inserted -712698321 1354439699
18951 \begin_inset Flex Code
18954 \begin_layout Plain Layout
18956 \change_inserted -712698321 1354439699
18962 ] Resets the LaTeX arguments of this layout (as defined via the
18963 \begin_inset Flex Code
18966 \begin_layout Plain Layout
18968 \change_inserted -712698321 1354439699
18975 This is useful if you have copied a style via
18976 \begin_inset Flex Code
18979 \begin_layout Plain Layout
18981 \change_inserted -712698321 1354439699
18987 , but you do not want to inherit its (required and optional) arguments.
18989 \change_deleted -712698321 1354439698
18995 \begin_layout Description
18996 \begin_inset Flex Code
18999 \begin_layout Plain Layout
19006 \begin_inset Flex Code
19009 \begin_layout Plain Layout
19016 \begin_inset space \thinspace{}
19020 \begin_inset Flex Code
19023 \begin_layout Plain Layout
19031 ] Whether this inset should use the font of its surrounding environment
19033 Default is true: uses its own.
19036 \begin_layout Description
19038 \change_inserted -712698321 1354263134
19039 \begin_inset Flex Code
19042 \begin_layout Plain Layout
19044 \change_inserted -712698321 1353866810
19051 \begin_inset Flex Code
19054 \begin_layout Plain Layout
19056 \change_inserted -712698321 1353866806
19062 ] A string that is put at the end of the layout content.
19063 A line break in the output can be indicated by
19064 \begin_inset Flex Code
19067 \begin_layout Plain Layout
19069 \change_inserted -712698321 1354263134
19080 \begin_layout Description
19081 \begin_inset Flex Code
19084 \begin_layout Plain Layout
19091 \begin_inset Flex Code
19094 \begin_layout Plain Layout
19101 \begin_inset space \thinspace{}
19105 \begin_inset Flex Code
19108 \begin_layout Plain Layout
19116 ] Allow spell-checking the contents of this inset.
19120 \begin_layout Subsection
19122 \begin_inset CommandInset label
19124 name "sub:Counters"
19131 \begin_layout Standard
19132 It is necessary to define the counters (
19133 \begin_inset Flex MenuItem
19136 \begin_layout Plain Layout
19143 \begin_inset Flex MenuItem
19146 \begin_layout Plain Layout
19152 , \SpecialChar \ldots{}
19153 ) in the text class itself.
19154 The standard counters are defined in the file
19155 \begin_inset Flex Code
19158 \begin_layout Plain Layout
19164 , so you may have to do no more than add
19167 \begin_layout LyX-Code
19168 Input stdcounters.inc
19171 \begin_layout Standard
19172 to your layout file to get them to work.
19173 But if you want to define custom counters, then you can do so.
19174 The counter declaration must begin with:
19177 \begin_layout LyX-Code
19178 Counter CounterName
19181 \begin_layout Standard
19183 \begin_inset Flex Code
19186 \begin_layout Plain Layout
19192 ' is replaced by the name of the counter.
19193 And it must end with
19194 \begin_inset Quotes eld
19198 \begin_inset Flex Code
19201 \begin_layout Plain Layout
19208 \begin_inset Quotes erd
19212 The following parameters can also be used:
19215 \begin_layout Description
19216 \begin_inset Flex Code
19219 \begin_layout Plain Layout
19226 \begin_inset Flex Code
19229 \begin_layout Plain Layout
19236 \begin_inset Quotes erd
19240 \begin_inset Quotes erd
19243 ] When defined, this string defines how the counter is displayed.
19244 Setting this value sets
19245 \begin_inset Flex Code
19248 \begin_layout Plain Layout
19249 LabelStringAppendix
19255 The following special constructs can be used in the string:
19259 \begin_layout Itemize
19260 \begin_inset Flex Code
19263 \begin_layout Plain Layout
19271 will be replaced by the expansion of the
19272 \begin_inset Flex Code
19275 \begin_layout Plain Layout
19282 \begin_inset Flex Code
19285 \begin_layout Plain Layout
19286 LabelStringAppendix
19292 \begin_inset Flex Code
19295 \begin_layout Plain Layout
19305 \begin_layout Itemize
19306 counter values can be expressed using LaTeX-like macros
19307 \begin_inset Newline newline
19311 \begin_inset Flex Code
19314 \begin_layout Plain Layout
19331 \begin_inset Flex Code
19334 \begin_layout Plain Layout
19346 \begin_layout Plain Layout
19356 Actually, the situation is a bit more complicated: any
19375 other than those described below will produce arabic numerals.
19376 It would not be surprising to see this change in the future.
19382 \begin_inset Flex Code
19385 \begin_layout Plain Layout
19391 : 1, 2, 3,\SpecialChar \ldots{}
19393 \begin_inset Flex Code
19396 \begin_layout Plain Layout
19402 for lower-case letters: a, b, c, \SpecialChar \ldots{}
19404 \begin_inset Flex Code
19407 \begin_layout Plain Layout
19413 for upper-case letters: A, B, C, \SpecialChar \ldots{}
19415 \begin_inset Flex Code
19418 \begin_layout Plain Layout
19424 for lower-case roman numerals: i, ii, iii, \SpecialChar \ldots{}
19426 \begin_inset Flex Code
19429 \begin_layout Plain Layout
19435 for upper-case roman numerals: I, II, III\SpecialChar \ldots{}
19437 \begin_inset Flex Code
19440 \begin_layout Plain Layout
19446 for hebrew numerals.
19450 \begin_layout Standard
19451 If LabelString is not defined, a default value is constructed as follows:
19452 if the counter has a master counter
19453 \begin_inset Flex Code
19456 \begin_layout Plain Layout
19463 \begin_inset Flex Code
19466 \begin_layout Plain Layout
19473 \begin_inset Newline newline
19477 \begin_inset Flex Code
19480 \begin_layout Plain Layout
19490 is used; otherwise the string
19491 \begin_inset Flex Code
19494 \begin_layout Plain Layout
19505 \begin_layout Description
19506 \begin_inset Flex Code
19509 \begin_layout Plain Layout
19510 LabelStringAppendix
19516 \begin_inset Flex Code
19519 \begin_layout Plain Layout
19526 \begin_inset Quotes erd
19530 \begin_inset Quotes erd
19534 \begin_inset Flex Code
19537 \begin_layout Plain Layout
19543 , but for use in the Appendix.
19546 \begin_layout Description
19547 \begin_inset Flex Code
19550 \begin_layout Plain Layout
19557 \begin_inset Flex Code
19560 \begin_layout Plain Layout
19567 \begin_inset Quotes erd
19571 \begin_inset Quotes erd
19574 ] A format for use with formatted references to this counter.
19575 For example, one might want to have references to section numbers appear
19577 \begin_inset Quotes eld
19581 \begin_inset Quotes erd
19585 The string should contain
19586 \begin_inset Quotes eld
19590 \begin_inset Quotes erd
19594 This will be replaced by the counter number itself.
19595 So, for sections, it would be: Section ##.
19598 \begin_layout Description
19599 \begin_inset Flex Code
19602 \begin_layout Plain Layout
19609 \begin_inset Flex Code
19612 \begin_layout Plain Layout
19619 \begin_inset Quotes erd
19623 \begin_inset Quotes erd
19626 ] If this is set to the name of another counter, the present counter will
19627 be reset every time the other one is increased.
19629 \begin_inset Flex Code
19632 \begin_layout Plain Layout
19639 \begin_inset Flex Code
19642 \begin_layout Plain Layout
19651 \begin_layout Subsection
19653 \begin_inset CommandInset label
19655 name "sub:Font-description"
19662 \begin_layout Standard
19663 A font description looks like this:
19666 \begin_layout LyX-Code
19680 \begin_layout LyX-Code
19684 \begin_layout LyX-Code
19688 \begin_layout Standard
19689 The following commands are available:
19692 \begin_layout Description
19693 \begin_inset Flex Code
19696 \begin_layout Plain Layout
19703 \begin_inset Flex Code
19706 \begin_layout Plain Layout
19715 \begin_inset Flex Code
19718 \begin_layout Plain Layout
19725 \begin_inset Flex Code
19728 \begin_layout Plain Layout
19735 \begin_inset Flex Code
19738 \begin_layout Plain Layout
19745 \begin_inset Flex Code
19748 \begin_layout Plain Layout
19755 \begin_inset Flex Code
19758 \begin_layout Plain Layout
19765 \begin_inset Flex Code
19768 \begin_layout Plain Layout
19775 \begin_inset Flex Code
19778 \begin_layout Plain Layout
19785 \begin_inset Flex Code
19788 \begin_layout Plain Layout
19797 \begin_layout Description
19798 \begin_inset Flex Code
19801 \begin_layout Plain Layout
19808 \begin_inset Flex Code
19811 \begin_layout Plain Layout
19820 \begin_inset Flex Code
19823 \begin_layout Plain Layout
19830 \begin_inset Flex Code
19833 \begin_layout Plain Layout
19842 \begin_layout Description
19843 \begin_inset Flex Code
19846 \begin_layout Plain Layout
19853 \begin_inset Flex Code
19856 \begin_layout Plain Layout
19862 ] Valid arguments are:
19863 \begin_inset Flex Code
19866 \begin_layout Plain Layout
19873 \begin_inset Flex Code
19876 \begin_layout Plain Layout
19883 \begin_inset Flex Code
19886 \begin_layout Plain Layout
19893 \begin_inset Flex Code
19896 \begin_layout Plain Layout
19903 \begin_inset Flex Code
19906 \begin_layout Plain Layout
19913 \begin_inset Flex Code
19916 \begin_layout Plain Layout
19923 \begin_inset Flex Code
19926 \begin_layout Plain Layout
19933 \begin_inset Flex Code
19936 \begin_layout Plain Layout
19943 \begin_inset Flex Code
19946 \begin_layout Plain Layout
19953 \begin_inset Flex Code
19956 \begin_layout Plain Layout
19963 \begin_inset Flex Code
19966 \begin_layout Plain Layout
19973 \begin_inset Flex Code
19976 \begin_layout Plain Layout
19983 Each of these turns on or off the corresponding attribute.
19985 \begin_inset Flex Code
19988 \begin_layout Plain Layout
19994 turns on emphasis, and
19995 \begin_inset Flex Code
19998 \begin_layout Plain Layout
20006 \begin_inset Newline newline
20009 If the latter seems puzzling, remember that the font settings for the present
20010 context are generally inherited from the surrounding context.
20012 \begin_inset Flex Code
20015 \begin_layout Plain Layout
20021 would turn off the emphasis that was anyway in effect, say, in a theorem
20025 \begin_layout Description
20026 \begin_inset Flex Code
20029 \begin_layout Plain Layout
20036 \begin_inset Flex Code
20039 \begin_layout Plain Layout
20048 \begin_inset Flex Code
20051 \begin_layout Plain Layout
20060 \begin_layout Description
20061 \begin_inset Flex Code
20064 \begin_layout Plain Layout
20071 \begin_inset Flex Code
20074 \begin_layout Plain Layout
20083 \begin_inset Flex Code
20086 \begin_layout Plain Layout
20093 \begin_inset Flex Code
20096 \begin_layout Plain Layout
20103 \begin_inset Flex Code
20106 \begin_layout Plain Layout
20115 \begin_layout Description
20116 \begin_inset Flex Code
20119 \begin_layout Plain Layout
20126 \begin_inset Flex Code
20129 \begin_layout Plain Layout
20136 \begin_inset Flex Code
20139 \begin_layout Plain Layout
20146 \begin_inset Flex Code
20149 \begin_layout Plain Layout
20158 \begin_inset Flex Code
20161 \begin_layout Plain Layout
20168 \begin_inset Flex Code
20171 \begin_layout Plain Layout
20178 \begin_inset Flex Code
20181 \begin_layout Plain Layout
20188 \begin_inset Flex Code
20191 \begin_layout Plain Layout
20198 \begin_inset Flex Code
20201 \begin_layout Plain Layout
20210 \begin_layout Subsection
20211 \begin_inset CommandInset label
20213 name "sub:Citation-format-description"
20217 Citation format description
20220 \begin_layout Standard
20222 \begin_inset Flex Code
20225 \begin_layout Plain Layout
20231 blocks are used to describe how bibliographic information should be displayed,
20232 both within LyX itself (in the citation dialog and in tooltips, for example)
20233 and in XHTML output.
20234 Such a block might look like this:
20237 \begin_layout LyX-Code
20241 \begin_layout LyX-Code
20245 \begin_layout LyX-Code
20249 \begin_layout LyX-Code
20253 \begin_layout Standard
20254 The individual lines define how the bibliographic information associated
20255 with an article or book, respectively, is to be displayed, and such a definitio
20256 n can be given for any `entry type' that might be present in a BibTeX file.
20257 LyX defines a default format in the source code that will be used if no
20258 specific definition has been given.
20259 LyX predefines several formats in the file
20260 \begin_inset Flex Code
20263 \begin_layout Plain Layout
20269 , which is included in most of LyX's document classes.
20272 \begin_layout Standard
20273 The definitions use a simple language that allows BibTeX keys to be replaced
20275 Keys should be enclosed in
20276 \begin_inset Flex Code
20279 \begin_layout Plain Layout
20286 \begin_inset Flex Code
20289 \begin_layout Plain Layout
20296 So a simple definition might look like this:
20299 \begin_layout LyX-Code
20301 \begin_inset Quotes eld
20305 \begin_inset Quotes erd
20311 \begin_layout Standard
20312 This would print the author, followed by a comma, followed by the title,
20313 in quotes, followed by a period.
20316 \begin_layout Standard
20317 Of course, sometimes you may want to print a key only if it exists.
20318 This can be done by using a conditional construction, such as:
20319 \begin_inset Flex Code
20322 \begin_layout Plain Layout
20324 \begin_inset space ~
20334 \begin_inset Flex Code
20337 \begin_layout Plain Layout
20343 key exists, then print
20344 \begin_inset Quotes eld
20348 \begin_inset space ~
20352 \begin_inset Quotes erd
20355 followed by the volume key.
20356 It is also possible to have an else clause in the conditional, such as:
20357 \begin_inset Newline newline
20361 \begin_inset Flex Code
20364 \begin_layout Plain Layout
20365 {%author%[[%author%]][[%editor%, ed.]]}
20371 \begin_inset Newline newline
20375 \begin_inset Flex Code
20378 \begin_layout Plain Layout
20384 key is printed if it exists; otherwise, the editor key is printed, followed
20386 \begin_inset Quotes eld
20390 \begin_inset space ~
20394 \begin_inset Quotes erd
20397 Note that the key is again enclosed in
20398 \begin_inset Flex Code
20401 \begin_layout Plain Layout
20407 signs; the entire conditional is enclosed in braces; and the if and else
20408 clauses are enclosed in double brackets,
20409 \begin_inset Quotes eld
20413 \begin_inset Flex Code
20416 \begin_layout Plain Layout
20423 \begin_inset Quotes eld
20427 \begin_inset Quotes eld
20431 \begin_inset Flex Code
20434 \begin_layout Plain Layout
20441 \begin_inset Quotes erd
20445 There must be no space between any of these.
20448 \begin_layout Standard
20449 There is one other piece of syntax available in definitions, which looks
20451 \begin_inset Flex Code
20454 \begin_layout Plain Layout
20461 This defines a piece of formatting information that is to be used when
20463 \begin_inset Quotes eld
20467 \begin_inset Quotes erd
20471 Obviously, we do not want to output HTML tags when writing plain text,
20472 so they should be wrapped in
20473 \begin_inset Quotes eld
20477 \begin_inset Quotes erd
20481 \begin_inset Quotes eld
20485 \begin_inset Quotes erd
20491 \begin_layout Standard
20492 Two special sorts of definitions are also possible in a
20493 \begin_inset Flex Code
20496 \begin_layout Plain Layout
20503 An example of the first would be:
20506 \begin_layout LyX-Code
20508 \begin_inset Quotes eld
20512 \begin_inset Quotes erd
20518 \begin_layout Standard
20519 This is an abbreviation, or macro, and it can be used by treating it as
20521 \begin_inset Flex Code
20524 \begin_layout Plain Layout
20532 \begin_inset Flex Code
20535 \begin_layout Plain Layout
20541 exactly as it would treat its definition.
20542 So, let us issue the obvious
20550 \begin_layout LyX-Code
20554 \begin_layout Standard
20555 or anything like it.
20556 LyX shouldn't go into an infinite loop, but it may go into a long one before
20560 \begin_layout Standard
20561 The second sort of special definition might look like this:
20564 \begin_layout LyX-Code
20568 \begin_layout Standard
20569 This defines a translatable piece of text, which allows relevant parts of
20570 the bibliography to be translated.
20571 It can be included in a definition by treating it as a key:
20572 \begin_inset Flex Code
20575 \begin_layout Plain Layout
20582 Several of these are predefined in
20583 \begin_inset Flex Code
20586 \begin_layout Plain Layout
20593 Note that these are not macros, in the sense just defined.
20594 They will not be expanded.
20597 \begin_layout Standard
20598 So here then is an example that use all these features:
20599 \begin_inset VSpace defskip
20605 \begin_layout Standard
20609 !authoredit {%author%[[%author%, ]][[{%editor%[[%editor%, %_edtext%, ]]}]]}
20612 \begin_layout Standard
20613 \begin_inset VSpace defskip
20616 This defines a macro that prints the author, followed by a comma, if the
20618 \begin_inset Flex Code
20621 \begin_layout Plain Layout
20627 key is defined, or else prints the name of the editor, followed by the
20629 \begin_inset Flex Code
20632 \begin_layout Plain Layout
20638 or its translation (it is by default
20639 \begin_inset Quotes eld
20643 \begin_inset Quotes erd
20647 \begin_inset Flex Code
20650 \begin_layout Plain Layout
20657 Note that this is in fact defined in
20658 \begin_inset Flex Code
20661 \begin_layout Plain Layout
20667 , so you can use it in your own definitions, or re-definitions, if you load
20671 \begin_layout Section
20672 \begin_inset CommandInset label
20674 name "sec:Tags-for-XHTML"
20678 Tags for XHTML output
20681 \begin_layout Standard
20682 As with LaTeX or DocBook, the format of LyX's XHTML output is also controlled
20683 by layout information.
20684 In general, LyX provides sensible defaults and, as mentioned earlier, it
20685 will even construct default CSS style rules from the other layout tags.
20686 For example, LyX will attempt to use the information provided in the
20687 \begin_inset Flex Code
20690 \begin_layout Plain Layout
20696 declaration for the Chapter style to write CSS that will appropriately
20697 format chapter headings.
20700 \begin_layout Standard
20701 In many cases, then, you may not have to do anything at all to get acceptable
20702 XHTML output for your own environments, custom insets, and so forth.
20703 But in some cases you will, and so LyX provides a number of layout tags
20704 that can be used to customize the XHTML and CSS that are generated.
20707 \begin_layout Standard
20708 Note that there are two tags,
20709 \begin_inset Flex Code
20712 \begin_layout Plain Layout
20719 \begin_inset Flex Code
20722 \begin_layout Plain Layout
20728 that may appear outside style and inset declarations.
20730 \begin_inset CommandInset ref
20732 reference "sub:General-text-class"
20736 for details on these.
20739 \begin_layout Subsection
20740 \begin_inset CommandInset label
20742 name "sub:Paragraph-Style-XHTML"
20749 \begin_layout Standard
20750 The sort of XHTML LyX outputs for a paragraph depends upon whether we are
20751 dealing with a normal paragraph, a command, or an environment, where this
20752 is itself determined by the contents of the corresponding
20753 \begin_inset Flex Code
20756 \begin_layout Plain Layout
20766 \begin_layout Standard
20767 For a command or normal paragraph, the output XHTML has the following form:
20770 \begin_layout LyX-Code
20772 \begin_inset Quotes erd
20776 \begin_inset Quotes erd
20782 \begin_layout LyX-Code
20784 \begin_inset Quotes erd
20788 \begin_inset Quotes erd
20794 \begin_layout LyX-Code
20795 Contents of the paragraph.
20798 \begin_layout LyX-Code
20802 \begin_layout Standard
20803 The label tags are of course omitted if the paragraph does not have a label.
20806 \begin_layout Standard
20807 For an environment that is not some sort of list, the XHTML takes this form:
20810 \begin_layout LyX-Code
20812 \begin_inset Quotes erd
20816 \begin_inset Quotes erd
20822 \begin_layout LyX-Code
20824 \begin_inset Quotes erd
20828 \begin_inset Quotes erd
20832 \begin_inset Quotes erd
20836 \begin_inset Quotes erd
20839 >Environment Label</labeltag>First paragraph.</itemtag>
20842 \begin_layout LyX-Code
20843 <itemtag>Second paragraph.</itemtag>
20846 \begin_layout LyX-Code
20850 \begin_layout Standard
20851 Note that the label is output only for the first paragraph, as it should
20852 be for a theorem, for example.
20856 \begin_layout Standard
20857 For a list, we have one of these forms:
20860 \begin_layout LyX-Code
20862 \begin_inset Quotes erd
20866 \begin_inset Quotes erd
20872 \begin_layout LyX-Code
20874 \begin_inset Quotes erd
20878 \begin_inset Quotes erd
20882 \begin_inset Quotes erd
20886 \begin_inset Quotes erd
20889 >List Label</labeltag>First item.</itemtag>
20892 \begin_layout LyX-Code
20894 \begin_inset Quotes erd
20898 \begin_inset Quotes erd
20902 \begin_inset Quotes erd
20906 \begin_inset Quotes erd
20909 >List Label</labeltag>Second item.</itemtag>
20912 \begin_layout LyX-Code
20916 \begin_layout LyX-Code
20920 \begin_layout LyX-Code
20922 \begin_inset Quotes erd
20926 \begin_inset Quotes erd
20932 \begin_layout LyX-Code
20934 \begin_inset Quotes erd
20938 \begin_inset Quotes erd
20941 >List Label</labeltag><itemtag attr=
20942 \begin_inset Quotes erd
20946 \begin_inset Quotes erd
20949 >First item.</itemtag>
20952 \begin_layout LyX-Code
20954 \begin_inset Quotes erd
20958 \begin_inset Quotes erd
20961 >List Label</labeltag><itemtag attr=
20962 \begin_inset Quotes erd
20966 \begin_inset Quotes erd
20969 >Second item.</itemtag>
20972 \begin_layout LyX-Code
20976 \begin_layout Standard
20977 Note the different orders of
20978 \begin_inset Flex Code
20981 \begin_layout Plain Layout
20988 \begin_inset Flex Code
20991 \begin_layout Plain Layout
20998 Which order we get depends upon the setting of
20999 \begin_inset Flex Code
21002 \begin_layout Plain Layout
21009 \begin_inset Flex Code
21012 \begin_layout Plain Layout
21018 is false (the default), you get the first of these, with the label within
21019 the item; if true, you get the second, with the label outside the item.
21022 \begin_layout Standard
21023 The specific tags and attributes output for each paragraph type can be controlle
21024 d by means of the layout tags we are about to describe.
21025 As mentioned earlier, however, LyX uses sensible defaults for many of these,
21026 so you often may not need to do very much to get good XHTML output.
21027 Think of the available tags as there so you can tweak things to your liking.
21030 \begin_layout Description
21031 \begin_inset Flex Code
21034 \begin_layout Plain Layout
21041 \begin_inset Flex Code
21044 \begin_layout Plain Layout
21050 ] Specifies attribute information to be output with the main tag.
21052 \begin_inset Quotes eld
21056 \begin_inset Flex Code
21059 \begin_layout Plain Layout
21066 \begin_inset Quotes erd
21070 By default, LyX will output
21071 \begin_inset Quotes eld
21075 \begin_inset Flex Code
21078 \begin_layout Plain Layout
21085 \begin_inset Quotes erd
21089 \begin_inset Flex Code
21092 \begin_layout Plain Layout
21098 is the LyX name of the layout, made lowercase, for example: chapter.
21103 contain any style information.
21105 \begin_inset Flex Code
21108 \begin_layout Plain Layout
21117 \begin_layout Description
21118 \begin_inset Flex Code
21121 \begin_layout Plain Layout
21128 \begin_inset Flex Code
21131 \begin_layout Plain Layout
21141 ] Whether to output the default CSS information LyX generates for this layout,
21142 even if additional information is explicitly provided via
21143 \begin_inset Flex Code
21146 \begin_layout Plain Layout
21154 \begin_inset Flex Code
21157 \begin_layout Plain Layout
21163 allows you to alter or augment the generated CSS, rather than to override
21166 \begin_inset Flex Code
21169 \begin_layout Plain Layout
21178 \begin_layout Description
21179 \begin_inset Flex Code
21182 \begin_layout Plain Layout
21189 \begin_inset Flex Code
21192 \begin_layout Plain Layout
21198 ] The tag to be used for individual paragraphs of environments, replacing
21200 \begin_inset Flex Code
21203 \begin_layout Plain Layout
21209 in the examples above.
21211 \begin_inset Flex Code
21214 \begin_layout Plain Layout
21223 \begin_layout Description
21224 \begin_inset Flex Code
21227 \begin_layout Plain Layout
21234 \begin_inset Flex Code
21237 \begin_layout Plain Layout
21243 ] Attributes for the item tag.
21245 \begin_inset Quotes eld
21249 \begin_inset Flex Code
21252 \begin_layout Plain Layout
21253 class=`layoutname_item'
21259 \begin_inset Quotes erd
21267 contain any style information.
21269 \begin_inset Flex Code
21272 \begin_layout Plain Layout
21281 \begin_layout Description
21282 \begin_inset Flex Code
21285 \begin_layout Plain Layout
21292 \begin_inset Flex Code
21295 \begin_layout Plain Layout
21301 ] The tag to be used for paragraph and item labels, replacing
21302 \begin_inset Flex Code
21305 \begin_layout Plain Layout
21311 in the examples above.
21313 \begin_inset Flex Code
21316 \begin_layout Plain Layout
21323 \begin_inset Flex Code
21326 \begin_layout Plain Layout
21333 \begin_inset Flex Code
21336 \begin_layout Plain Layout
21343 \begin_inset Flex Code
21346 \begin_layout Plain Layout
21347 Centered_Top_Environment
21352 , in which case it defaults to
21353 \begin_inset Flex Code
21356 \begin_layout Plain Layout
21365 \begin_layout Description
21366 \begin_inset Flex Code
21369 \begin_layout Plain Layout
21376 \begin_inset Flex Code
21379 \begin_layout Plain Layout
21385 ] Attributes for the label tag.
21387 \begin_inset Quotes eld
21391 \begin_inset Flex Code
21394 \begin_layout Plain Layout
21395 class=`layoutname_label'
21401 \begin_inset Quotes erd
21409 contain any style information.
21411 \begin_inset Flex Code
21414 \begin_layout Plain Layout
21423 \begin_layout Description
21424 \begin_inset Flex Code
21427 \begin_layout Plain Layout
21434 \begin_inset Flex Code
21437 \begin_layout Plain Layout
21447 ] Meaningful only for list-like environments, this tag controls whether
21448 the label tag is output before or inside the item tag.
21449 This is used, for example, in the description environment, where we want
21451 \begin_inset Flex Code
21454 \begin_layout Plain Layout
21455 <dt>\SpecialChar \ldots{}
21456 </dt><dd>\SpecialChar \ldots{}
21464 \begin_inset Flex Code
21467 \begin_layout Plain Layout
21473 : The label tag is output inside the item tag.
21476 \begin_layout Description
21477 \begin_inset Flex Code
21480 \begin_layout Plain Layout
21486 Information to be output in the
21487 \begin_inset Flex Code
21490 \begin_layout Plain Layout
21496 section when this style is used.
21497 This might, for example, be used to include a
21498 \begin_inset Flex Code
21501 \begin_layout Plain Layout
21508 \begin_inset Flex Code
21511 \begin_layout Plain Layout
21520 \begin_layout Description
21521 \begin_inset Flex Code
21524 \begin_layout Plain Layout
21530 CSS style information to be included when this style is used.
21531 Note that this will automatically be wrapped in a layout-generated
21532 \begin_inset Flex Code
21535 \begin_layout Plain Layout
21541 block, so only the CSS itself need be included.
21543 \change_inserted 1414654397 1364133464
21545 \begin_inset Flex Code
21548 \begin_layout Plain Layout
21550 \change_inserted 1414654397 1364133462
21563 \begin_layout Description
21564 \begin_inset Flex Code
21567 \begin_layout Plain Layout
21574 \begin_inset Flex Code
21577 \begin_layout Plain Layout
21583 ] The tag to be used for the main label, replacing
21584 \begin_inset Flex Code
21587 \begin_layout Plain Layout
21593 in the examples above.
21595 \begin_inset Flex Code
21598 \begin_layout Plain Layout
21607 \begin_layout Description
21608 \begin_inset Flex Code
21611 \begin_layout Plain Layout
21618 \begin_inset Flex Code
21621 \begin_layout Plain Layout
21631 ] Marks this style as the one to be used to generate the
21632 \begin_inset Flex Code
21635 \begin_layout Plain Layout
21641 tag for the XHTML file.
21642 By default, it is false.
21644 \begin_inset Flex Code
21647 \begin_layout Plain Layout
21653 file sets it to true for the
21654 \begin_inset Flex Code
21657 \begin_layout Plain Layout
21667 \begin_layout Subsection
21671 \begin_layout Standard
21672 The XHTML output of insets can also be controlled by information in layout
21677 \begin_layout Plain Layout
21678 At present, this is true only for
21679 \begin_inset Quotes eld
21683 \begin_inset Quotes erd
21686 insets (insets you can type into) and is not true for
21687 \begin_inset Quotes eld
21691 \begin_inset Quotes erd
21694 insets (insets that are associated with dialog boxes).
21699 Here, too, LyX tries to provide sensible defaults, and it constructs default
21701 But everything can be customized.
21704 \begin_layout Standard
21705 The XHTML LyX outputs for an inset has the following form:
21708 \begin_layout LyX-Code
21710 \begin_inset Quotes erd
21714 \begin_inset Quotes erd
21720 \begin_layout LyX-Code
21721 <labeltag>Label</labeltag>
21724 \begin_layout LyX-Code
21726 \begin_inset Quotes erd
21730 \begin_inset Quotes erd
21733 >Contents of the inset.</innertag>
21736 \begin_layout LyX-Code
21740 \begin_layout Standard
21741 If the inset permits multiple paragraphs---that is, if
21742 \begin_inset Flex Code
21745 \begin_layout Plain Layout
21751 is true---then the contents of the inset will itself be output as paragraphs
21752 formatted according to the styles used for those paragraphs (standard,
21753 quote, and the like).
21754 The label tag is of course omitted if the paragraph does not have a label
21755 and, at present, is always
21756 \begin_inset Flex Code
21759 \begin_layout Plain Layout
21766 The inner tag is optional and, by default, does not appear.
21769 \begin_layout Standard
21770 The specific tags and attributes output for each inset can be controlled
21771 by means of the following layout tags.
21774 \begin_layout Description
21775 \begin_inset Flex Code
21778 \begin_layout Plain Layout
21785 \begin_inset Flex Code
21788 \begin_layout Plain Layout
21794 ] Specifies attribute information to be output with the main tag.
21796 \begin_inset Quotes eld
21800 \begin_inset Flex Code
21803 \begin_layout Plain Layout
21804 class=`myinset' onclick=`\SpecialChar \ldots{}
21811 \begin_inset Quotes erd
21815 By default, LyX will output
21816 \begin_inset Quotes eld
21820 \begin_inset Flex Code
21823 \begin_layout Plain Layout
21830 \begin_inset Quotes erd
21834 \begin_inset Flex Code
21837 \begin_layout Plain Layout
21843 is the LyX name of the inset, made lowercase and with non-alphanumeric
21844 characters converted to underscores, for example: footnote.
21847 \begin_layout Description
21848 \begin_inset Flex Code
21851 \begin_layout Plain Layout
21858 \begin_inset Flex Code
21861 \begin_layout Plain Layout
21871 ] Whether to output the default CSS information LyX generates for this layout,
21872 even if additional information is explicitly provided via
21873 \begin_inset Flex Code
21876 \begin_layout Plain Layout
21884 \begin_inset Flex Code
21887 \begin_layout Plain Layout
21893 allows you to alter or augment the generated CSS, rather than to override
21898 \begin_layout Description
21899 \begin_inset Flex Code
21902 \begin_layout Plain Layout
21909 \begin_inset Flex Code
21912 \begin_layout Plain Layout
21918 ] Attributes for the inner tag.
21920 \begin_inset Quotes eld
21924 \begin_inset Flex Code
21927 \begin_layout Plain Layout
21928 class=`insetname_inner'
21934 \begin_inset Quotes erd
21940 \begin_layout Description
21941 \begin_inset Flex Code
21944 \begin_layout Plain Layout
21951 \begin_inset Flex Code
21954 \begin_layout Plain Layout
21960 ] The inner tag, replacing
21961 \begin_inset Flex Code
21964 \begin_layout Plain Layout
21970 in the examples above.
21971 By default, there is none.
21974 \begin_layout Description
21975 \begin_inset Flex Code
21978 \begin_layout Plain Layout
21985 \begin_inset Flex Code
21988 \begin_layout Plain Layout
21996 ] Whether this inset represents a standalone block of text (such as a footnote)
21997 or instead represents material that is included in the surrounding text
21998 (such as a branch).
22002 \begin_layout Description
22003 \begin_inset Flex Code
22006 \begin_layout Plain Layout
22013 \begin_inset Flex Code
22016 \begin_layout Plain Layout
22022 ] A label for this inset, possibly including a reference to a counter.
22023 For example, for footnote, it might be:
22024 \begin_inset Flex Code
22027 \begin_layout Plain Layout
22036 This is optional, and there is no default.
22039 \begin_layout Description
22040 \begin_inset Flex Code
22043 \begin_layout Plain Layout
22049 Information to be output in the
22050 \begin_inset Flex Code
22053 \begin_layout Plain Layout
22059 section when this style is used.
22060 This might, for example, be used to include a
22061 \begin_inset Flex Code
22064 \begin_layout Plain Layout
22071 \begin_inset Flex Code
22074 \begin_layout Plain Layout
22083 \begin_layout Description
22084 \begin_inset Flex Code
22087 \begin_layout Plain Layout
22093 CSS style information to be included when this style is used.
22094 Note that this will automatically be wrapped in a layout-generated
22095 \begin_inset Flex Code
22098 \begin_layout Plain Layout
22104 block, so only the CSS itself need be included.
22107 \begin_layout Description
22108 \begin_inset Flex Code
22111 \begin_layout Plain Layout
22118 \begin_inset Flex Code
22121 \begin_layout Plain Layout
22127 ] The tag to be used for the main label, replacing
22128 \begin_inset Flex Code
22131 \begin_layout Plain Layout
22137 in the examples above.
22138 The default depends upon the setting of
22139 \begin_inset Flex Code
22142 \begin_layout Plain Layout
22149 \begin_inset Flex Code
22152 \begin_layout Plain Layout
22158 is true, the default is
22159 \begin_inset Flex Code
22162 \begin_layout Plain Layout
22168 ; if it is false, the default is
22169 \begin_inset Flex Code
22172 \begin_layout Plain Layout
22181 \begin_layout Subsection
22185 \begin_layout Standard
22186 The XHTML output for floats too can be controlled by layout information.
22187 The output has the following form:
22190 \begin_layout LyX-Code
22192 \begin_inset Quotes erd
22196 \begin_inset Quotes erd
22202 \begin_layout LyX-Code
22203 Contents of the float.
22206 \begin_layout LyX-Code
22210 \begin_layout Standard
22211 The caption, if there is one, is a separate inset and will be output as
22213 Its appearance can be controlled via the InsetLayout for caption insets.
22217 \begin_layout Description
22218 \begin_inset Flex Code
22221 \begin_layout Plain Layout
22228 \begin_inset Flex Code
22231 \begin_layout Plain Layout
22237 ] Specifies attribute information to be output with the main tag.
22239 \begin_inset Quotes eld
22243 \begin_inset Flex Code
22246 \begin_layout Plain Layout
22247 class=`myfloat' onclick=`\SpecialChar \ldots{}
22254 \begin_inset Quotes erd
22258 By default, LyX will output
22259 \begin_inset Quotes eld
22263 \begin_inset Flex Code
22266 \begin_layout Plain Layout
22267 class=`float float-floattype'
22273 \begin_inset Quotes erd
22277 \begin_inset Flex Code
22280 \begin_layout Plain Layout
22286 is LyX's name for this type of float, as determined by the float declaration
22288 \begin_inset CommandInset ref
22290 reference "sub:Floats"
22294 ), though made lowercase and with non-alphanumeric characters converted
22295 to underscores, for example: float-table.
22298 \begin_layout Description
22299 \begin_inset Flex Code
22302 \begin_layout Plain Layout
22308 CSS style information to be included when this float is used.
22309 Note that this will automatically be wrapped in a layout-generated
22310 \begin_inset Flex Code
22313 \begin_layout Plain Layout
22319 block, so only the CSS itself need be included.
22322 \begin_layout Description
22323 \begin_inset Flex Code
22326 \begin_layout Plain Layout
22333 \begin_inset Flex Code
22336 \begin_layout Plain Layout
22342 ] The tag to be used for this float, replacing
22343 \begin_inset Quotes eld
22347 \begin_inset Flex Code
22350 \begin_layout Plain Layout
22357 \begin_inset Quotes erd
22360 in the example above.
22362 \begin_inset Flex Code
22365 \begin_layout Plain Layout
22371 and will rarely need changing.
22374 \begin_layout Subsection
22375 Bibliography formatting
22378 \begin_layout Standard
22379 The bibliography can be formatted using
22380 \begin_inset Flex Code
22383 \begin_layout Plain Layout
22391 \begin_inset CommandInset ref
22393 reference "sub:Citation-format-description"
22400 \begin_layout Subsection
22404 \begin_layout Standard
22405 We have several times mentioned that LyX will generate default CSS style
22406 rules for both insets and paragraph styles, based upon the other layout
22407 information that is provided.
22408 In this section, we shall say a word about which layout information LyX
22412 \begin_layout Standard
22413 At present, LyX auto-generates CSS only for font information, making use
22415 \begin_inset Flex Code
22418 \begin_layout Plain Layout
22425 \begin_inset Flex Code
22428 \begin_layout Plain Layout
22435 \begin_inset Flex Code
22438 \begin_layout Plain Layout
22445 \begin_inset Flex Code
22448 \begin_layout Plain Layout
22455 \begin_inset Flex Code
22458 \begin_layout Plain Layout
22466 \begin_inset CommandInset ref
22468 reference "sub:Font-description"
22472 .) The translation is mostly straightforward and obvious.
22474 \begin_inset Quotes eld
22478 \begin_inset Flex Code
22481 \begin_layout Plain Layout
22488 \begin_inset Quotes erd
22492 \begin_inset Quotes eld
22496 \begin_inset Flex Code
22499 \begin_layout Plain Layout
22500 font-family: sans-serif;
22506 \begin_inset Quotes erd
22510 The correspondence of LyX sizes and CSS sizes is a little less obvious
22511 but nonetheless intuitive.
22513 \begin_inset Flex Code
22516 \begin_layout Plain Layout
22523 \begin_inset Flex URL
22526 \begin_layout Plain Layout
22536 \begin_layout Chapter
22537 Including External Material
22540 \begin_layout Standard
22541 \begin_inset Box Shadowbox
22551 height_special "totalheight"
22554 \begin_layout Plain Layout
22555 WARNING: This portion of the documentation has not been updated for some
22557 We certainly hope that it is still accurate, but there are no guarantees.
22565 \begin_layout Standard
22566 The use of material from sources external to LyX is covered in detail in
22572 This part of the manual covers what needs to happen behind the scenes for
22573 new sorts of material to be included.
22576 \begin_layout Section
22580 \begin_layout Standard
22581 The external material feature is based on the concept of a
22586 A template is a specification of how LyX should interface with a certain
22588 As bundled, LyX comes with predefined templates for Xfig figures, various
22589 raster format images, chess diagrams, and LilyPond music notation.
22590 You can check the actual list by using the menu
22591 \begin_inset Flex MenuItem
22594 \begin_layout Plain Layout
22595 Insert\SpecialChar \menuseparator
22596 File\SpecialChar \menuseparator
22603 Furthermore, it is possible to roll your own template to support a specific
22605 Later we'll describe in more detail what is involved, and hopefully you
22606 will submit all the templates you create so we can include them in a later
22610 \begin_layout Standard
22611 Another basic idea of the external material feature is to distinguish between
22612 the original file that serves as a base for final material and the produced
22613 file that is included in your exported or printed document.
22614 For example, consider the case of a figure produced with
22615 \begin_inset Flex Code
22618 \begin_layout Plain Layout
22625 The Xfig application itself works on an original file with the
22626 \begin_inset Flex Code
22629 \begin_layout Plain Layout
22636 Within Xfig, you create and change your figure, and when you are done,
22638 \begin_inset Flex Code
22641 \begin_layout Plain Layout
22648 When you want to include the figure in your document, you invoke
22649 \begin_inset Flex Code
22652 \begin_layout Plain Layout
22658 in order to create a PostScript file that can readily be included in your
22661 \begin_inset Flex Code
22664 \begin_layout Plain Layout
22670 file is the original file, and the PostScript file is the produced file.
22673 \begin_layout Standard
22674 This distinction is important in order to allow updating of the material
22675 while you are in the process of writing the document.
22676 Furthermore, it provides us with the flexibility that is needed to support
22677 multiple export formats.
22678 For instance, in the case of a plain text file, it is not exactly an award-winn
22679 ing idea to include the figure as raw PostScript.
22680 Instead, you would either prefer to just include a reference to the figure
22681 or try to invoke some graphics to ASCII converter to make the final result
22682 look similar to the real graphics.
22683 The external material management allows you to do this, because it is parametri
22684 zed on the different export formats that LyX supports.
22687 \begin_layout Standard
22688 Besides supporting the production of different products according to the
22689 exported format, it supports tight integration with editing and viewing
22691 In the case of an Xfig figure, you are able to invoke Xfig on the original
22692 file with a single click from within the external material dialog in LyX,
22693 and also preview the produced PostScript file with Ghostview with another
22695 No more fiddling around with the command line and/or file browsers to locate
22696 and manipulate the original or produced files.
22697 In this way, you are finally able to take full advantage of the many different
22698 applications that are relevant to use when you write your documents, and
22699 ultimately be more productive.
22702 \begin_layout Section
22703 The external template configuration file
22706 \begin_layout Standard
22707 It is relatively easy to add custom external template definitions to LyX.
22708 However, be aware that doing this in an careless manner most probably
22712 introduce an easily exploitable security hole.
22713 So before you do this, please read the discussion about security in section
22715 \begin_inset CommandInset ref
22717 reference "sec:Security-discussion"
22724 \begin_layout Standard
22725 Having said that, we encourage you to submit any interesting templates that
22730 \begin_layout Standard
22731 The external templates are defined in the
22732 \begin_inset Flex Code
22735 \begin_layout Plain Layout
22736 LyXDir/lib/external_templates
22742 You can place your own version in
22743 \begin_inset Flex Code
22746 \begin_layout Plain Layout
22747 UserDir/external_templates
22755 \begin_layout Standard
22756 A typical template looks like this:
22759 \begin_layout LyX-Code
22763 \begin_layout LyX-Code
22764 GuiName "XFig: $$AbsOrRelPathParent$$Basename"
22767 \begin_layout LyX-Code
22771 \begin_layout LyX-Code
22775 \begin_layout LyX-Code
22779 \begin_layout LyX-Code
22783 \begin_layout LyX-Code
22787 \begin_layout LyX-Code
22788 AutomaticProduction true
22791 \begin_layout LyX-Code
22795 \begin_layout LyX-Code
22799 \begin_layout LyX-Code
22803 \begin_layout LyX-Code
22804 TransformCommand Rotate RotationLatexCommand
22807 \begin_layout LyX-Code
22808 TransformCommand Resize ResizeLatexCommand
22811 \begin_layout LyX-Code
22812 Product "$$RotateFront$$ResizeFront
22815 \begin_layout LyX-Code
22820 input{$$AbsOrRelPathMaster$$Basename.pstex_t}
22823 \begin_layout LyX-Code
22824 $$ResizeBack$$RotateBack"
22827 \begin_layout LyX-Code
22831 \begin_layout LyX-Code
22832 UpdateResult "$$AbsPath$$Basename.pstex_t"
22835 \begin_layout LyX-Code
22836 Requirement "graphicx"
22839 \begin_layout LyX-Code
22840 ReferencedFile latex "$$AbsOrRelPathMaster$$Basename.pstex_t"
22843 \begin_layout LyX-Code
22844 ReferencedFile latex "$$AbsPath$$Basename.eps"
22847 \begin_layout LyX-Code
22848 ReferencedFile dvi "$$AbsPath$$Basename.eps"
22851 \begin_layout LyX-Code
22855 \begin_layout LyX-Code
22859 \begin_layout LyX-Code
22860 TransformCommand Rotate RotationLatexCommand
22863 \begin_layout LyX-Code
22864 TransformCommand Resize ResizeLatexCommand
22867 \begin_layout LyX-Code
22868 Product "$$RotateFront$$ResizeFront
22871 \begin_layout LyX-Code
22876 input{$$AbsOrRelPathMaster$$Basename.pdftex_t}
22879 \begin_layout LyX-Code
22880 $$ResizeBack$$RotateBack"
22883 \begin_layout LyX-Code
22884 UpdateFormat pdftex
22887 \begin_layout LyX-Code
22888 UpdateResult "$$AbsPath$$Basename.pdftex_t"
22891 \begin_layout LyX-Code
22892 Requirement "graphicx"
22895 \begin_layout LyX-Code
22896 ReferencedFile latex "$$AbsOrRelPathMaster$$Basename.pdftex_t"
22899 \begin_layout LyX-Code
22900 ReferencedFile latex "$$AbsPath$$Basename.pdf"
22903 \begin_layout LyX-Code
22907 \begin_layout LyX-Code
22911 \begin_layout LyX-Code
22912 Product "$$Contents(
22914 "$$AbsPath$$Basename.asc
22919 \begin_layout LyX-Code
22920 UpdateFormat asciixfig
22923 \begin_layout LyX-Code
22924 UpdateResult "$$AbsPath$$Basename.asc"
22927 \begin_layout LyX-Code
22931 \begin_layout LyX-Code
22935 \begin_layout LyX-Code
22936 Product "<graphic fileref=
22938 "$$AbsOrRelPathMaster$$Basename.eps
22943 \begin_layout LyX-Code
22947 \begin_layout LyX-Code
22951 \begin_layout LyX-Code
22952 UpdateResult "$$AbsPath$$Basename.eps"
22955 \begin_layout LyX-Code
22956 ReferencedFile docbook "$$AbsPath$$Basename.eps"
22959 \begin_layout LyX-Code
22960 ReferencedFile docbook-xml "$$AbsPath$$Basename.eps"
22963 \begin_layout LyX-Code
22967 \begin_layout LyX-Code
22968 Product "[XFig: $$FName]"
22971 \begin_layout LyX-Code
22975 \begin_layout LyX-Code
22979 \begin_layout Standard
22980 As you can see, the template is enclosed in
22981 \begin_inset Flex Code
22984 \begin_layout Plain Layout
22990 \SpecialChar \ldots{}
22992 \begin_inset Flex Code
22995 \begin_layout Plain Layout
23002 It contains a header specifying some general settings and, for each supported
23003 primary document file format, a section
23004 \begin_inset Flex Code
23007 \begin_layout Plain Layout
23013 \SpecialChar \ldots{}
23015 \begin_inset Flex Code
23018 \begin_layout Plain Layout
23027 \begin_layout Subsection
23028 The template header
23031 \begin_layout Description
23032 \begin_inset Flex Code
23035 \begin_layout Plain Layout
23036 AutomaticProduction
23037 \begin_inset space ~
23045 Whether the file represented by the template must be generated by LyX.
23046 This command must occur exactly once.
23049 \begin_layout Description
23050 \begin_inset Flex Code
23053 \begin_layout Plain Layout
23055 \begin_inset space ~
23063 A glob pattern that is used in the file dialog to filter out the desired
23065 If there is more than one possible file extension (e.
23066 \begin_inset space \thinspace{}
23070 \begin_inset space \space{}
23074 \begin_inset Flex Code
23077 \begin_layout Plain Layout
23084 \begin_inset Flex Code
23087 \begin_layout Plain Layout
23093 ), use something like
23094 \begin_inset Flex Code
23097 \begin_layout Plain Layout
23104 This command must occur exactly once.
23107 \begin_layout Description
23108 \begin_inset Flex Code
23111 \begin_layout Plain Layout
23113 \begin_inset space ~
23121 The text that is displayed on the button.
23122 This command must occur exactly once.
23125 \begin_layout Description
23126 \begin_inset Flex Code
23129 \begin_layout Plain Layout
23131 \begin_inset space ~
23135 \begin_inset space ~
23143 The help text that is used in the External dialog.
23144 Provide enough information to explain to the user just what the template
23145 can provide him with.
23146 This command must occur exactly once.
23149 \begin_layout Description
23150 \begin_inset Flex Code
23153 \begin_layout Plain Layout
23155 \begin_inset space ~
23163 The file format of the original file.
23164 This must be the name of a format that is known to LyX (see section
23165 \begin_inset space ~
23169 \begin_inset CommandInset ref
23171 reference "sec:Formats"
23177 \begin_inset Quotes eld
23181 \begin_inset Flex Code
23184 \begin_layout Plain Layout
23191 \begin_inset Quotes erd
23194 if the template can handle original files of more than one format.
23195 LyX will attempt to interrogate the file itself in order to deduce its
23196 format in this case.
23197 This command must occur exactly once.
23200 \begin_layout Description
23201 \begin_inset Flex Code
23204 \begin_layout Plain Layout
23206 \begin_inset space ~
23214 A unique name for the template.
23215 It must not contain substitution macros (see below).
23218 \begin_layout Description
23219 \begin_inset Flex Code
23222 \begin_layout Plain Layout
23224 \begin_inset space ~
23227 Rotate|Resize|Clip|Extra
23232 This command specifies which transformations are supported by this template.
23233 It may occur zero or more times.
23234 This command enables the corresponding tabs in the external dialog.
23236 \begin_inset Flex Code
23239 \begin_layout Plain Layout
23245 command must have either a corresponding
23246 \begin_inset Flex Code
23249 \begin_layout Plain Layout
23256 \begin_inset Flex Code
23259 \begin_layout Plain Layout
23266 \begin_inset Flex Code
23269 \begin_layout Plain Layout
23276 Otherwise the transformation will not be supported by that format.
23279 \begin_layout Subsection
23283 \begin_layout Description
23284 \begin_inset Flex Code
23287 \begin_layout Plain Layout
23289 \begin_inset space ~
23292 LaTeX|PDFLaTeX|PlainText|DocBook
23297 The primary document file format that this format definition is for.
23298 Not every template has a sensible representation in all document file formats.
23299 Please define nevertheless a
23300 \begin_inset Flex Code
23303 \begin_layout Plain Layout
23309 section for all templates.
23310 Use a dummy text when no representation is available.
23311 Then you can at least see a reference to the external material in the exported
23315 \begin_layout Description
23316 \begin_inset Flex Code
23319 \begin_layout Plain Layout
23321 \begin_inset space ~
23325 \begin_inset space ~
23333 This command defines an additional macro
23334 \begin_inset Flex Code
23337 \begin_layout Plain Layout
23343 for substitution in
23344 \begin_inset Flex Code
23347 \begin_layout Plain Layout
23355 \begin_inset Flex Code
23358 \begin_layout Plain Layout
23364 itself may contain substitution macros.
23365 The advantage over using
23366 \begin_inset Flex Code
23369 \begin_layout Plain Layout
23376 \begin_inset Flex Code
23379 \begin_layout Plain Layout
23385 is that the substituted value of
23386 \begin_inset Flex Code
23389 \begin_layout Plain Layout
23395 is sanitized so that it is a valid optional argument in the document format.
23396 This command may occur zero or more times.
23399 \begin_layout Description
23400 \begin_inset Flex Code
23403 \begin_layout Plain Layout
23405 \begin_inset space ~
23413 The text that is inserted in the exported document.
23414 This is actually the most important command and can be quite complex.
23415 This command must occur exactly once.
23418 \begin_layout Description
23419 \begin_inset Flex Code
23422 \begin_layout Plain Layout
23424 \begin_inset space ~
23432 This command specifies a preamble snippet that will be included in the
23434 It has to be defined using
23435 \begin_inset Flex Code
23438 \begin_layout Plain Layout
23444 \SpecialChar \ldots{}
23446 \begin_inset Flex Code
23449 \begin_layout Plain Layout
23456 This command may occur zero or more times.
23459 \begin_layout Description
23460 \begin_inset Flex Code
23463 \begin_layout Plain Layout
23465 \begin_inset space ~
23469 \begin_inset space ~
23477 This command denotes files that are created by the conversion process and
23478 are needed for a particular export format.
23479 If the filename is relative, it is interpreted relative to the master document.
23480 This command may be given zero or more times.
23483 \begin_layout Description
23484 \begin_inset Flex Code
23487 \begin_layout Plain Layout
23489 \begin_inset space ~
23497 The name of a required LaTeX package.
23498 The package is included via
23499 \begin_inset Flex Code
23502 \begin_layout Plain Layout
23510 in the LaTeX preamble.
23511 This command may occur zero or more times.
23514 \begin_layout Description
23515 \begin_inset Flex Code
23518 \begin_layout Plain Layout
23520 \begin_inset space ~
23524 \begin_inset space ~
23527 RotationLatexCommand
23532 This command specifies that the built in LaTeX command should be used for
23534 This command may occur once or not at all.
23537 \begin_layout Description
23538 \begin_inset Flex Code
23541 \begin_layout Plain Layout
23543 \begin_inset space ~
23547 \begin_inset space ~
23555 This command specifies that the built in LaTeX command should be used for
23557 This command may occur once or not at all.
23560 \begin_layout Description
23561 \begin_inset Flex Code
23564 \begin_layout Plain Layout
23566 \begin_inset space ~
23570 \begin_inset space ~
23573 RotationLatexOption
23578 This command specifies that rotation is done via an optional argument.
23579 This command may occur once or not at all.
23582 \begin_layout Description
23583 \begin_inset Flex Code
23586 \begin_layout Plain Layout
23588 \begin_inset space ~
23592 \begin_inset space ~
23600 This command specifies that resizing is done via an optional argument.
23601 This command may occur once or not at all.
23604 \begin_layout Description
23605 \begin_inset Flex Code
23608 \begin_layout Plain Layout
23610 \begin_inset space ~
23614 \begin_inset space ~
23622 This command specifies that clipping is done via an optional argument.
23623 This command may occur once or not at all.
23626 \begin_layout Description
23627 \begin_inset Flex Code
23630 \begin_layout Plain Layout
23632 \begin_inset space ~
23636 \begin_inset space ~
23644 This command specifies that an extra optional argument is used.
23645 This command may occur once or not at all.
23648 \begin_layout Description
23649 \begin_inset Flex Code
23652 \begin_layout Plain Layout
23654 \begin_inset space ~
23662 The file format of the converted file.
23663 This must be the name of a format that is known to LyX (see the
23664 \begin_inset Flex MenuItem
23667 \begin_layout Plain Layout
23672 ools\SpecialChar \menuseparator
23677 references\SpecialChar \menuseparator
23678 File Handling\SpecialChar \menuseparator
23685 This command must occur exactly once.
23687 \change_inserted -195340706 1363813305
23688 If the resulting file format is PDF, you need to specify the format
23689 \begin_inset Flex Code
23692 \begin_layout Plain Layout
23694 \change_inserted -195340706 1363813269
23701 This is the PDF format used for including graphics.
23702 The other defined PDF formats are for document export.
23707 \begin_layout Description
23708 \begin_inset Flex Code
23711 \begin_layout Plain Layout
23713 \begin_inset space ~
23721 The file name of the converted file.
23722 The file name must be absolute.
23723 This command must occur exactly once.
23726 \begin_layout Subsection
23727 Preamble definitions
23730 \begin_layout Standard
23731 The external template configuration file may contain additional preamble
23732 definitions enclosed by
23733 \begin_inset Flex Code
23736 \begin_layout Plain Layout
23742 \SpecialChar \ldots{}
23744 \begin_inset Flex Code
23747 \begin_layout Plain Layout
23754 They can be used by the templates in the
23755 \begin_inset Flex Code
23758 \begin_layout Plain Layout
23767 \begin_layout Section
23768 The substitution mechanism
23771 \begin_layout Standard
23772 When the external material facility invokes an external program, it is done
23773 on the basis of a command defined in the template configuration file.
23774 These commands can contain various macros that are expanded before execution.
23775 Execution always take place in the directory of the containing document.
23778 \begin_layout Standard
23779 Also, whenever external material is to be displayed, the name will be produced
23780 by the substitution mechanism, and most other commands in the template
23781 definition support substitution as well.
23784 \begin_layout Standard
23785 The available macros are the following:
23788 \begin_layout Description
23789 \begin_inset Flex Code
23792 \begin_layout Plain Layout
23793 $$AbsOrRelPathMaster
23798 The file path, absolute or relative to the master LyX document.
23801 \begin_layout Description
23802 \begin_inset Flex Code
23805 \begin_layout Plain Layout
23806 $$AbsOrRelPathParent
23811 The file path, absolute or relative to the LyX document.
23814 \begin_layout Description
23815 \begin_inset Flex Code
23818 \begin_layout Plain Layout
23824 The absolute file path.
23827 \begin_layout Description
23828 \begin_inset Flex Code
23831 \begin_layout Plain Layout
23837 The filename without path and without the extension.
23840 \begin_layout Description
23841 \begin_inset Flex Code
23844 \begin_layout Plain Layout
23846 \begin_inset Quotes eld
23850 \begin_inset Quotes erd
23858 This macro will expand to the contents of the file with the name
23859 \begin_inset Flex Code
23862 \begin_layout Plain Layout
23871 \begin_layout Description
23872 \begin_inset Flex Code
23875 \begin_layout Plain Layout
23881 The file extension (including the dot).
23884 \begin_layout Description
23885 \begin_inset Flex Code
23888 \begin_layout Plain Layout
23894 The filename of the file specified in the external material dialog.
23895 This is either an absolute name, or it is relative to the LyX document.
23898 \begin_layout Description
23899 \begin_inset Flex Code
23902 \begin_layout Plain Layout
23909 \begin_inset Flex Code
23912 \begin_layout Plain Layout
23918 (absolute name or relative to the LyX document).
23921 \begin_layout Description
23922 \begin_inset Flex Code
23925 \begin_layout Plain Layout
23931 The file path, relative to the master LyX document.
23934 \begin_layout Description
23935 \begin_inset Flex Code
23938 \begin_layout Plain Layout
23944 The file path, relative to the LyX document.
23947 \begin_layout Description
23948 \begin_inset Flex Code
23951 \begin_layout Plain Layout
23957 This macro will expand to the absolute path of the system directory.
23958 This is typically used to point to the various helper scripts that are
23962 \begin_layout Description
23963 \begin_inset Flex Code
23966 \begin_layout Plain Layout
23972 A name and full path to a temporary file which will be automatically deleted
23973 whenever the containing document is closed, or the external material insertion
23977 \begin_layout Standard
23978 All path macros contain a trailing directory separator, so you can construct
23980 \begin_inset space \thinspace{}
23984 \begin_inset space \space{}
23987 the absolute filename with
23988 \begin_inset Flex Code
23991 \begin_layout Plain Layout
23992 $$AbsPath$$Basename$$Extension
24000 \begin_layout Standard
24001 The macros above are substituted in all commands unless otherwise noted.
24003 \begin_inset Flex Code
24006 \begin_layout Plain Layout
24012 supports additionally the following substitutions if they are enabled by
24014 \begin_inset Flex Code
24017 \begin_layout Plain Layout
24024 \begin_inset Flex Code
24027 \begin_layout Plain Layout
24036 \begin_layout Description
24037 \begin_inset Flex Code
24040 \begin_layout Plain Layout
24046 The front part of the resize command.
24049 \begin_layout Description
24050 \begin_inset Flex Code
24053 \begin_layout Plain Layout
24059 The back part of the resize command.
24062 \begin_layout Description
24063 \begin_inset Flex Code
24066 \begin_layout Plain Layout
24072 The front part of the rotation command.
24075 \begin_layout Description
24076 \begin_inset Flex Code
24079 \begin_layout Plain Layout
24085 The back part of the rotation command.
24088 \begin_layout Standard
24089 The value string of the
24090 \begin_inset Flex Code
24093 \begin_layout Plain Layout
24099 command supports additionally the following substitutions if they are enabled
24101 \begin_inset Flex Code
24104 \begin_layout Plain Layout
24111 \begin_inset Flex Code
24114 \begin_layout Plain Layout
24123 \begin_layout Description
24124 \begin_inset Flex Code
24127 \begin_layout Plain Layout
24136 \begin_layout Description
24137 \begin_inset Flex Code
24140 \begin_layout Plain Layout
24149 \begin_layout Description
24150 \begin_inset Flex Code
24153 \begin_layout Plain Layout
24162 \begin_layout Description
24163 \begin_inset Flex Code
24166 \begin_layout Plain Layout
24172 The rotation option.
24175 \begin_layout Standard
24176 You may ask why there are so many path macros.
24177 There are mainly two reasons:
24180 \begin_layout Enumerate
24181 Relative and absolute file names should remain relative or absolute, respectivel
24183 Users may have reasons to prefer either form.
24184 Relative names are useful for portable documents that should work on different
24185 machines, for example.
24186 Absolute names may be required by some programs.
24189 \begin_layout Enumerate
24190 LaTeX treats relative file names differently than LyX and other programs
24191 in nested included files.
24192 For LyX, a relative file name is always relative to the document that contains
24194 For LaTeX, it is always relative to the master document.
24195 These two definitions are identical if you have only one document, but
24196 differ if you have a master document that includes part documents.
24197 That means that relative filenames must be transformed when presented to
24199 Fortunately LyX does this automatically for you if you choose the right
24203 \begin_layout Standard
24204 So which path macro should be used in new template definitions? The rule
24208 \begin_layout Itemize
24210 \begin_inset Flex Code
24213 \begin_layout Plain Layout
24219 if an absolute path is required.
24222 \begin_layout Itemize
24224 \begin_inset Flex Code
24227 \begin_layout Plain Layout
24228 $$AbsOrRelPathMaster
24233 if the substituted string is some kind of LaTeX input.
24236 \begin_layout Itemize
24238 \begin_inset Flex Code
24241 \begin_layout Plain Layout
24242 $$AbsOrRelPathParent
24247 in order to preserve the user's choice.
24250 \begin_layout Standard
24251 There are special cases where this rule does not work and e.
24252 \begin_inset space \thinspace{}
24256 \begin_inset space \space{}
24259 relative names are needed, but normally it will work just fine.
24260 One example for such a case is the command
24261 \begin_inset Flex Code
24264 \begin_layout Plain Layout
24265 ReferencedFile latex "$$AbsOrRelPathMaster$$Basename.pstex_t"
24270 in the XFig template above: We can't use the absolute name because the
24272 \begin_inset Flex Code
24275 \begin_layout Plain Layout
24281 files needs the relative name in order to rewrite the file content.
24284 \begin_layout Section
24285 Security discussion
24286 \begin_inset CommandInset label
24288 name "sec:Security-discussion"
24295 \begin_layout Standard
24296 The external material feature interfaces with a lot of external programs
24297 and does so automatically, so we have to consider the security implications
24299 In particular, since you have the option of including your own filenames
24300 and/or parameter strings and those are expanded into a command, it seems
24301 that it would be possible to create a malicious document which executes
24302 arbitrary commands when a user views or prints the document.
24303 This is something we definitely want to avoid.
24306 \begin_layout Standard
24307 However, since the external program commands are specified in the template
24308 configuration file only, there are no security issues if LyX is properly
24309 configured with safe templates only.
24310 This is so because the external programs are invoked with the
24311 \begin_inset Flex Code
24314 \begin_layout Plain Layout
24320 -system call rather than the
24321 \begin_inset Flex Code
24324 \begin_layout Plain Layout
24330 system-call, so it's not possible to execute arbitrary commands from the
24331 filename or parameter section via the shell.
24334 \begin_layout Standard
24335 This also implies that you are restricted in what command strings you can
24336 use in the external material templates.
24337 In particular, pipes and redirection are not readily available.
24338 This has to be so if LyX should remain safe.
24339 If you want to use some of the shell features, you should write a safe
24340 script to do this in a controlled manner, and then invoke the script from
24341 the command string.
24345 \begin_layout Standard
24346 It is possible to design a template that interacts directly with the shell,
24347 but since this would allow a malicious user to execute arbitrary commands
24348 by writing clever filenames and/or parameters, we generally recommend that
24349 you only use safe scripts that work with the
24350 \begin_inset Flex Code
24353 \begin_layout Plain Layout
24359 system call in a controlled manner.
24360 Of course, for use in a controlled environment, it can be tempting to just
24361 fall back to use ordinary shell scripts.
24362 If you do so, be aware that you
24366 provide an easily exploitable security hole in your system.
24367 Of course it stands to reason that such unsafe templates will never be
24368 included in the standard LyX distribution, although we do encourage people
24369 to submit new templates in the open source tradition.
24370 But LyX as shipped from the official distribution channels will never have
24374 \begin_layout Standard
24375 Including external material provides a lot of power, and you have to be
24376 careful not to introduce security hazards with this power.
24377 A subtle error in a single line in an innocent looking script can open
24378 the door to huge security problems.
24379 So if you do not fully understand the issues, we recommend that you consult
24380 a knowledgeable security professional or the LyX development team if you
24381 have any questions about whether a given template is safe or not.
24382 And do this before you use it in an uncontrolled environment.
24385 \begin_layout Chapter
24387 List of functions to be used in layouts
24388 \begin_inset CommandInset label
24390 name "chap:List-of-functions"
24397 \begin_layout Standard
24399 \begin_inset Tabular
24400 <lyxtabular version="3" rows="10" columns="6">
24401 <features rotate="0" tabularvalignment="middle">
24402 <column alignment="left" valignment="top" width="14col%">
24403 <column alignment="left" valignment="top" width="14col%">
24404 <column alignment="left" valignment="top" width="14col%">
24405 <column alignment="left" valignment="top" width="14col%">
24406 <column alignment="left" valignment="top" width="14col%">
24407 <column alignment="left" valignment="top" width="14col%">
24409 <cell alignment="left" valignment="top" usebox="none">
24412 \begin_layout Plain Layout
24418 <cell alignment="left" valignment="top" usebox="none">
24421 \begin_layout Plain Layout
24427 <cell alignment="left" valignment="top" usebox="none">
24430 \begin_layout Plain Layout
24436 <cell alignment="left" valignment="top" usebox="none">
24439 \begin_layout Plain Layout
24445 <cell alignment="left" valignment="top" usebox="none">
24448 \begin_layout Plain Layout
24454 <cell alignment="left" valignment="top" usebox="none">
24457 \begin_layout Plain Layout
24465 <cell alignment="left" valignment="top" usebox="none">
24468 \begin_layout Plain Layout
24474 <cell alignment="left" valignment="top" usebox="none">
24477 \begin_layout Plain Layout
24483 <cell alignment="left" valignment="top" usebox="none">
24486 \begin_layout Plain Layout
24492 <cell alignment="left" valignment="top" usebox="none">
24495 \begin_layout Plain Layout
24501 <cell alignment="left" valignment="top" usebox="none">
24504 \begin_layout Plain Layout
24510 <cell alignment="left" valignment="top" usebox="none">
24513 \begin_layout Plain Layout
24521 <cell alignment="left" valignment="top" usebox="none">
24524 \begin_layout Plain Layout
24530 <cell alignment="left" valignment="top" usebox="none">
24533 \begin_layout Plain Layout
24539 <cell alignment="left" valignment="top" usebox="none">
24542 \begin_layout Plain Layout
24548 <cell alignment="left" valignment="top" usebox="none">
24551 \begin_layout Plain Layout
24557 <cell alignment="left" valignment="top" usebox="none">
24560 \begin_layout Plain Layout
24566 <cell alignment="left" valignment="top" usebox="none">
24569 \begin_layout Plain Layout
24577 <cell alignment="left" valignment="top" usebox="none">
24580 \begin_layout Plain Layout
24586 <cell alignment="left" valignment="top" usebox="none">
24589 \begin_layout Plain Layout
24595 <cell alignment="left" valignment="top" usebox="none">
24598 \begin_layout Plain Layout
24604 <cell alignment="left" valignment="top" usebox="none">
24607 \begin_layout Plain Layout
24613 <cell alignment="left" valignment="top" usebox="none">
24616 \begin_layout Plain Layout
24622 <cell alignment="left" valignment="top" usebox="none">
24625 \begin_layout Plain Layout
24633 <cell alignment="left" valignment="top" usebox="none">
24636 \begin_layout Plain Layout
24642 <cell alignment="left" valignment="top" usebox="none">
24645 \begin_layout Plain Layout
24651 <cell alignment="left" valignment="top" usebox="none">
24654 \begin_layout Plain Layout
24660 <cell alignment="left" valignment="top" usebox="none">
24663 \begin_layout Plain Layout
24669 <cell alignment="left" valignment="top" usebox="none">
24672 \begin_layout Plain Layout
24678 <cell alignment="left" valignment="top" usebox="none">
24681 \begin_layout Plain Layout
24689 <cell alignment="left" valignment="top" usebox="none">
24692 \begin_layout Plain Layout
24698 <cell alignment="left" valignment="top" usebox="none">
24701 \begin_layout Plain Layout
24707 <cell alignment="left" valignment="top" usebox="none">
24710 \begin_layout Plain Layout
24716 <cell alignment="left" valignment="top" usebox="none">
24719 \begin_layout Plain Layout
24725 <cell alignment="left" valignment="top" usebox="none">
24728 \begin_layout Plain Layout
24734 <cell alignment="left" valignment="top" usebox="none">
24737 \begin_layout Plain Layout
24745 <cell alignment="left" valignment="top" usebox="none">
24748 \begin_layout Plain Layout
24754 <cell alignment="left" valignment="top" usebox="none">
24757 \begin_layout Plain Layout
24763 <cell alignment="left" valignment="top" usebox="none">
24766 \begin_layout Plain Layout
24772 <cell alignment="left" valignment="top" usebox="none">
24775 \begin_layout Plain Layout
24781 <cell alignment="left" valignment="top" usebox="none">
24784 \begin_layout Plain Layout
24790 <cell alignment="left" valignment="top" usebox="none">
24793 \begin_layout Plain Layout
24801 <cell alignment="left" valignment="top" usebox="none">
24804 \begin_layout Plain Layout
24810 <cell alignment="left" valignment="top" usebox="none">
24813 \begin_layout Plain Layout
24819 <cell alignment="left" valignment="top" usebox="none">
24822 \begin_layout Plain Layout
24828 <cell alignment="left" valignment="top" usebox="none">
24831 \begin_layout Plain Layout
24837 <cell alignment="left" valignment="top" usebox="none">
24840 \begin_layout Plain Layout
24846 <cell alignment="left" valignment="top" usebox="none">
24849 \begin_layout Plain Layout
24857 <cell alignment="left" valignment="top" usebox="none">
24860 \begin_layout Plain Layout
24866 <cell alignment="left" valignment="top" usebox="none">
24869 \begin_layout Plain Layout
24875 <cell alignment="left" valignment="top" usebox="none">
24878 \begin_layout Plain Layout
24884 <cell alignment="left" valignment="top" usebox="none">
24887 \begin_layout Plain Layout
24893 <cell alignment="left" valignment="top" usebox="none">
24896 \begin_layout Plain Layout
24902 <cell alignment="left" valignment="top" usebox="none">
24905 \begin_layout Plain Layout
24913 <cell alignment="left" valignment="top" usebox="none">
24916 \begin_layout Plain Layout
24922 <cell alignment="left" valignment="top" usebox="none">
24925 \begin_layout Plain Layout
24931 <cell alignment="left" valignment="top" usebox="none">
24934 \begin_layout Plain Layout
24940 <cell alignment="left" valignment="top" usebox="none">
24943 \begin_layout Plain Layout
24949 <cell alignment="left" valignment="top" usebox="none">
24952 \begin_layout Plain Layout
24958 <cell alignment="left" valignment="top" usebox="none">
24961 \begin_layout Plain Layout
24975 \begin_layout Standard
24977 \begin_inset Tabular
24978 <lyxtabular version="3" rows="10" columns="6">
24979 <features rotate="0" tabularvalignment="middle">
24980 <column alignment="left" valignment="top" width="14col%">
24981 <column alignment="left" valignment="top" width="14col%">
24982 <column alignment="left" valignment="top" width="14col%">
24983 <column alignment="left" valignment="top" width="14col%">
24984 <column alignment="left" valignment="top" width="14col%">
24985 <column alignment="left" valignment="top" width="14col%">
24987 <cell alignment="left" valignment="top" usebox="none">
24990 \begin_layout Plain Layout
24996 <cell alignment="left" valignment="top" usebox="none">
24999 \begin_layout Plain Layout
25005 <cell alignment="left" valignment="top" usebox="none">
25008 \begin_layout Plain Layout
25014 <cell alignment="left" valignment="top" usebox="none">
25017 \begin_layout Plain Layout
25023 <cell alignment="left" valignment="top" usebox="none">
25026 \begin_layout Plain Layout
25032 <cell alignment="left" valignment="top" usebox="none">
25035 \begin_layout Plain Layout
25043 <cell alignment="left" valignment="top" usebox="none">
25046 \begin_layout Plain Layout
25052 <cell alignment="left" valignment="top" usebox="none">
25055 \begin_layout Plain Layout
25061 <cell alignment="left" valignment="top" usebox="none">
25064 \begin_layout Plain Layout
25070 <cell alignment="left" valignment="top" usebox="none">
25073 \begin_layout Plain Layout
25079 <cell alignment="left" valignment="top" usebox="none">
25082 \begin_layout Plain Layout
25088 <cell alignment="left" valignment="top" usebox="none">
25091 \begin_layout Plain Layout
25099 <cell alignment="left" valignment="top" usebox="none">
25102 \begin_layout Plain Layout
25108 <cell alignment="left" valignment="top" usebox="none">
25111 \begin_layout Plain Layout
25117 <cell alignment="left" valignment="top" usebox="none">
25120 \begin_layout Plain Layout
25126 <cell alignment="left" valignment="top" usebox="none">
25129 \begin_layout Plain Layout
25135 <cell alignment="left" valignment="top" usebox="none">
25138 \begin_layout Plain Layout
25144 <cell alignment="left" valignment="top" usebox="none">
25147 \begin_layout Plain Layout
25155 <cell alignment="left" valignment="top" usebox="none">
25158 \begin_layout Plain Layout
25164 <cell alignment="left" valignment="top" usebox="none">
25167 \begin_layout Plain Layout
25173 <cell alignment="left" valignment="top" usebox="none">
25176 \begin_layout Plain Layout
25182 <cell alignment="left" valignment="top" usebox="none">
25185 \begin_layout Plain Layout
25191 <cell alignment="left" valignment="top" usebox="none">
25194 \begin_layout Plain Layout
25200 <cell alignment="left" valignment="top" usebox="none">
25203 \begin_layout Plain Layout
25211 <cell alignment="left" valignment="top" usebox="none">
25214 \begin_layout Plain Layout
25220 <cell alignment="left" valignment="top" usebox="none">
25223 \begin_layout Plain Layout
25229 <cell alignment="left" valignment="top" usebox="none">
25232 \begin_layout Plain Layout
25238 <cell alignment="left" valignment="top" usebox="none">
25241 \begin_layout Plain Layout
25247 <cell alignment="left" valignment="top" usebox="none">
25250 \begin_layout Plain Layout
25256 <cell alignment="left" valignment="top" usebox="none">
25259 \begin_layout Plain Layout
25267 <cell alignment="left" valignment="top" usebox="none">
25270 \begin_layout Plain Layout
25276 <cell alignment="left" valignment="top" usebox="none">
25279 \begin_layout Plain Layout
25285 <cell alignment="left" valignment="top" usebox="none">
25288 \begin_layout Plain Layout
25294 <cell alignment="left" valignment="top" usebox="none">
25297 \begin_layout Plain Layout
25303 <cell alignment="left" valignment="top" usebox="none">
25306 \begin_layout Plain Layout
25312 <cell alignment="left" valignment="top" usebox="none">
25315 \begin_layout Plain Layout
25323 <cell alignment="left" valignment="top" usebox="none">
25326 \begin_layout Plain Layout
25332 <cell alignment="left" valignment="top" usebox="none">
25335 \begin_layout Plain Layout
25341 <cell alignment="left" valignment="top" usebox="none">
25344 \begin_layout Plain Layout
25350 <cell alignment="left" valignment="top" usebox="none">
25353 \begin_layout Plain Layout
25359 <cell alignment="left" valignment="top" usebox="none">
25362 \begin_layout Plain Layout
25368 <cell alignment="left" valignment="top" usebox="none">
25371 \begin_layout Plain Layout
25379 <cell alignment="left" valignment="top" usebox="none">
25382 \begin_layout Plain Layout
25388 <cell alignment="left" valignment="top" usebox="none">
25391 \begin_layout Plain Layout
25397 <cell alignment="left" valignment="top" usebox="none">
25400 \begin_layout Plain Layout
25406 <cell alignment="left" valignment="top" usebox="none">
25409 \begin_layout Plain Layout
25415 <cell alignment="left" valignment="top" usebox="none">
25418 \begin_layout Plain Layout
25424 <cell alignment="left" valignment="top" usebox="none">
25427 \begin_layout Plain Layout
25435 <cell alignment="left" valignment="top" usebox="none">
25438 \begin_layout Plain Layout
25444 <cell alignment="left" valignment="top" usebox="none">
25447 \begin_layout Plain Layout
25453 <cell alignment="left" valignment="top" usebox="none">
25456 \begin_layout Plain Layout
25462 <cell alignment="left" valignment="top" usebox="none">
25465 \begin_layout Plain Layout
25471 <cell alignment="left" valignment="top" usebox="none">
25474 \begin_layout Plain Layout
25480 <cell alignment="left" valignment="top" usebox="none">
25483 \begin_layout Plain Layout
25491 <cell alignment="left" valignment="top" usebox="none">
25494 \begin_layout Plain Layout
25500 <cell alignment="left" valignment="top" usebox="none">
25503 \begin_layout Plain Layout
25509 <cell alignment="left" valignment="top" usebox="none">
25512 \begin_layout Plain Layout
25518 <cell alignment="left" valignment="top" usebox="none">
25521 \begin_layout Plain Layout
25527 <cell alignment="left" valignment="top" usebox="none">
25530 \begin_layout Plain Layout
25536 <cell alignment="left" valignment="top" usebox="none">
25539 \begin_layout Plain Layout
25553 \begin_layout Chapter
25554 List of supported LyX functions to be used in layouts
25557 \begin_layout Standard
25559 \begin_inset Tabular
25560 <lyxtabular version="3" rows="10" columns="8">
25561 <features rotate="0" tabularvalignment="middle">
25562 <column alignment="left" valignment="top" width="0">
25563 <column alignment="left" valignment="top" width="0">
25564 <column alignment="left" valignment="top" width="0">
25565 <column alignment="left" valignment="top" width="0">
25566 <column alignment="left" valignment="top" width="0">
25567 <column alignment="left" valignment="top" width="0">
25568 <column alignment="left" valignment="top" width="0">
25569 <column alignment="left" valignment="top" width="0">
25571 <cell alignment="left" valignment="top" usebox="none">
25574 \begin_layout Plain Layout
25580 <cell alignment="left" valignment="top" usebox="none">
25583 \begin_layout Plain Layout
25589 <cell alignment="left" valignment="top" usebox="none">
25592 \begin_layout Plain Layout
25598 <cell alignment="left" valignment="top" usebox="none">
25601 \begin_layout Plain Layout
25607 <cell alignment="center" valignment="top" usebox="none">
25610 \begin_layout Plain Layout
25616 <cell alignment="center" valignment="top" usebox="none">
25619 \begin_layout Plain Layout
25625 <cell alignment="center" valignment="top" usebox="none">
25628 \begin_layout Plain Layout
25634 <cell alignment="center" valignment="top" usebox="none">
25637 \begin_layout Plain Layout
25645 <cell alignment="left" valignment="top" usebox="none">
25648 \begin_layout Plain Layout
25654 <cell alignment="left" valignment="top" usebox="none">
25657 \begin_layout Plain Layout
25663 <cell alignment="left" valignment="top" usebox="none">
25666 \begin_layout Plain Layout
25672 <cell alignment="left" valignment="top" usebox="none">
25675 \begin_layout Plain Layout
25681 <cell alignment="center" valignment="top" usebox="none">
25684 \begin_layout Plain Layout
25690 <cell alignment="center" valignment="top" usebox="none">
25693 \begin_layout Plain Layout
25699 <cell alignment="center" valignment="top" usebox="none">
25702 \begin_layout Plain Layout
25708 <cell alignment="center" valignment="top" usebox="none">
25711 \begin_layout Plain Layout
25719 <cell alignment="left" valignment="top" usebox="none">
25722 \begin_layout Plain Layout
25728 <cell alignment="left" valignment="top" usebox="none">
25731 \begin_layout Plain Layout
25737 <cell alignment="left" valignment="top" usebox="none">
25740 \begin_layout Plain Layout
25746 <cell alignment="left" valignment="top" usebox="none">
25749 \begin_layout Plain Layout
25755 <cell alignment="center" valignment="top" usebox="none">
25758 \begin_layout Plain Layout
25764 <cell alignment="center" valignment="top" usebox="none">
25767 \begin_layout Plain Layout
25773 <cell alignment="center" valignment="top" usebox="none">
25776 \begin_layout Plain Layout
25782 <cell alignment="center" valignment="top" usebox="none">
25785 \begin_layout Plain Layout
25793 <cell alignment="left" valignment="top" usebox="none">
25796 \begin_layout Plain Layout
25802 <cell alignment="left" valignment="top" usebox="none">
25805 \begin_layout Plain Layout
25811 <cell alignment="left" valignment="top" usebox="none">
25814 \begin_layout Plain Layout
25820 <cell alignment="left" valignment="top" usebox="none">
25823 \begin_layout Plain Layout
25829 <cell alignment="center" valignment="top" usebox="none">
25832 \begin_layout Plain Layout
25838 <cell alignment="center" valignment="top" usebox="none">
25841 \begin_layout Plain Layout
25847 <cell alignment="center" valignment="top" usebox="none">
25850 \begin_layout Plain Layout
25856 <cell alignment="center" valignment="top" usebox="none">
25859 \begin_layout Plain Layout
25867 <cell alignment="left" valignment="top" usebox="none">
25870 \begin_layout Plain Layout
25876 <cell alignment="left" valignment="top" usebox="none">
25879 \begin_layout Plain Layout
25885 <cell alignment="left" valignment="top" usebox="none">
25888 \begin_layout Plain Layout
25894 <cell alignment="left" valignment="top" usebox="none">
25897 \begin_layout Plain Layout
25903 <cell alignment="center" valignment="top" usebox="none">
25906 \begin_layout Plain Layout
25912 <cell alignment="center" valignment="top" usebox="none">
25915 \begin_layout Plain Layout
25921 <cell alignment="center" valignment="top" usebox="none">
25924 \begin_layout Plain Layout
25930 <cell alignment="center" valignment="top" usebox="none">
25933 \begin_layout Plain Layout
25941 <cell alignment="left" valignment="top" usebox="none">
25944 \begin_layout Plain Layout
25950 <cell alignment="left" valignment="top" usebox="none">
25953 \begin_layout Plain Layout
25959 <cell alignment="left" valignment="top" usebox="none">
25962 \begin_layout Plain Layout
25968 <cell alignment="left" valignment="top" usebox="none">
25971 \begin_layout Plain Layout
25977 <cell alignment="center" valignment="top" usebox="none">
25980 \begin_layout Plain Layout
25986 <cell alignment="center" valignment="top" usebox="none">
25989 \begin_layout Plain Layout
25995 <cell alignment="center" valignment="top" usebox="none">
25998 \begin_layout Plain Layout
26004 <cell alignment="center" valignment="top" usebox="none">
26007 \begin_layout Plain Layout
26015 <cell alignment="left" valignment="top" usebox="none">
26018 \begin_layout Plain Layout
26024 <cell alignment="left" valignment="top" usebox="none">
26027 \begin_layout Plain Layout
26033 <cell alignment="left" valignment="top" usebox="none">
26036 \begin_layout Plain Layout
26042 <cell alignment="left" valignment="top" usebox="none">
26045 \begin_layout Plain Layout
26051 <cell alignment="center" valignment="top" usebox="none">
26054 \begin_layout Plain Layout
26060 <cell alignment="center" valignment="top" usebox="none">
26063 \begin_layout Plain Layout
26069 <cell alignment="center" valignment="top" usebox="none">
26072 \begin_layout Plain Layout
26078 <cell alignment="center" valignment="top" usebox="none">
26081 \begin_layout Plain Layout
26089 <cell alignment="left" valignment="top" usebox="none">
26092 \begin_layout Plain Layout
26098 <cell alignment="left" valignment="top" usebox="none">
26101 \begin_layout Plain Layout
26107 <cell alignment="left" valignment="top" usebox="none">
26110 \begin_layout Plain Layout
26116 <cell alignment="left" valignment="top" usebox="none">
26119 \begin_layout Plain Layout
26125 <cell alignment="center" valignment="top" usebox="none">
26128 \begin_layout Plain Layout
26134 <cell alignment="center" valignment="top" usebox="none">
26137 \begin_layout Plain Layout
26143 <cell alignment="center" valignment="top" usebox="none">
26146 \begin_layout Plain Layout
26152 <cell alignment="center" valignment="top" usebox="none">
26155 \begin_layout Plain Layout
26163 <cell alignment="left" valignment="top" usebox="none">
26166 \begin_layout Plain Layout
26172 <cell alignment="left" valignment="top" usebox="none">
26175 \begin_layout Plain Layout
26181 <cell alignment="left" valignment="top" usebox="none">
26184 \begin_layout Plain Layout
26190 <cell alignment="left" valignment="top" usebox="none">
26193 \begin_layout Plain Layout
26199 <cell alignment="center" valignment="top" usebox="none">
26202 \begin_layout Plain Layout
26208 <cell alignment="center" valignment="top" usebox="none">
26211 \begin_layout Plain Layout
26217 <cell alignment="center" valignment="top" usebox="none">
26220 \begin_layout Plain Layout
26226 <cell alignment="center" valignment="top" usebox="none">
26229 \begin_layout Plain Layout
26237 <cell alignment="left" valignment="top" usebox="none">
26240 \begin_layout Plain Layout
26246 <cell alignment="left" valignment="top" usebox="none">
26249 \begin_layout Plain Layout
26255 <cell alignment="left" valignment="top" usebox="none">
26258 \begin_layout Plain Layout
26264 <cell alignment="left" valignment="top" usebox="none">
26267 \begin_layout Plain Layout
26273 <cell alignment="center" valignment="top" usebox="none">
26276 \begin_layout Plain Layout
26282 <cell alignment="center" valignment="top" usebox="none">
26285 \begin_layout Plain Layout
26291 <cell alignment="center" valignment="top" usebox="none">
26294 \begin_layout Plain Layout
26300 <cell alignment="center" valignment="top" usebox="none">
26303 \begin_layout Plain Layout
26317 \begin_layout Standard
26318 accents amsbsy amscd amsmath amssymb amstext amsthm array ascii bbding bm
26319 booktabs calc CJK color covington csquotes dvipost endnotes enumitem esint
26320 fancybox feyn fixltx2e float framed graphicx hhline hyperref ifsym ifthen
26321 jurabib latexsym listings longtable lyxskak makeidx marvosym mathdesign
26322 mathdots mathrsfs mhchem multirow natbib nomencl pdfcolmk pdfpages pifont
26323 pmboxdraw polyglossia prettyref pxfonts refstyle rotating rotfloat setspace
26324 slashed soul splitidx subfig subscript textcomp textgreek tfrupee tipa
26325 tipx tone txfonts ulem undertilde units url varioref verbatim wasysym wrapfig
26326 xargs xcolor xy yhmath
26329 \begin_layout Chapter
26330 Names of available colors to be used in layouts
26331 \begin_inset CommandInset label
26333 name "chap:Names-of-colors"
26340 \begin_layout Standard
26341 The colors listed here are the standard colors and the those that you can
26342 adjust in the LyX preferences.
26345 \begin_layout Description
26358 No particular color -- clear or default
26361 \begin_layout Description
26365 \begin_layout Description
26369 \begin_layout Description
26373 \begin_layout Description
26377 \begin_layout Description
26381 \begin_layout Description
26385 \begin_layout Description
26389 \begin_layout Description
26393 \begin_layout Description
26394 cursor Cursor color
26397 \begin_layout Description
26398 background Background color
26401 \begin_layout Description
26402 foreground Foreground color
26405 \begin_layout Description
26406 selection Background color of selected text
26409 \begin_layout Description
26410 selectiontext Foreground color of selected text
26413 \begin_layout Description
26414 latex Text color in LaTeX mode
26417 \begin_layout Description
26418 preview The color used for previews
26421 \begin_layout Description
26422 inlinecompletion Inline completion color
26425 \begin_layout Description
26426 nonunique_inlinecompletion Inline completion color for the non-unique part
26429 \begin_layout Description
26430 notelabel Label color for notes
26433 \begin_layout Description
26434 notebg Background color of notes
26437 \begin_layout Description
26438 commentlabel Label color for comments
26441 \begin_layout Description
26442 commentbg Background color of comments
26445 \begin_layout Description
26446 greyedoutlabel Label color for greyedout insets
26449 \begin_layout Description
26450 greyedouttext Color for greyedout inset text
26453 \begin_layout Description
26454 greyedoutbg Background color of greyedout inset
26457 \begin_layout Description
26458 shadedbg Background color of shaded box
26461 \begin_layout Description
26462 listingsbg Background color of listings inset
26465 \begin_layout Description
26466 branchlabel Label color for branches
26469 \begin_layout Description
26470 footlabel Label color for footnotes
26473 \begin_layout Description
26474 indexlabel Label color for index insets
26477 \begin_layout Description
26478 marginlabel Label color for margin notes
26481 \begin_layout Description
26482 phantomtext Text color for phantom insets
26485 \begin_layout Description
26486 urllabel Label color for URL insets
26489 \begin_layout Description
26490 urltext Color for URL inset text
26493 \begin_layout Description
26494 depthbar Color for the depth bars in the margin
26497 \begin_layout Description
26498 language Color for marking foreign language words
26501 \begin_layout Description
26502 command Text color for command insets
26505 \begin_layout Description
26506 commandbg Background color for command insets
26509 \begin_layout Description
26510 commandframe Frame color for command insets
26513 \begin_layout Description
26514 special Special chars text color
26517 \begin_layout Description
26518 graphicsbg Graphics inset background color
26521 \begin_layout Description
26522 math Math inset text color
26525 \begin_layout Description
26526 mathbg Math inset background color
26529 \begin_layout Description
26530 mathmacrobg Macro math inset background color
26533 \begin_layout Description
26534 mathmacrohoverbg Macro math inset background color hovered
26537 \begin_layout Description
26538 mathmacrolabel Macro math label color
26541 \begin_layout Description
26542 mathmacroframe Macro math frame color
26545 \begin_layout Description
26546 mathmacroblend Macro math blended color
26549 \begin_layout Description
26550 mathmacrooldarg Macro template color for old parameters
26553 \begin_layout Description
26554 mathmacronewarg Macro template color for new parameters
26557 \begin_layout Description
26558 mathframe Math inset frame color under focus
26561 \begin_layout Description
26562 mathcorners Math inset frame color not under focus
26565 \begin_layout Description
26566 mathline Math line color
26569 \begin_layout Description
26570 collapsable Collapsable insets text
26573 \begin_layout Description
26574 collapsableframe Collapsable insets frame
26577 \begin_layout Description
26578 insetbg Inset marker background color
26581 \begin_layout Description
26582 insetframe Inset marker frame color
26585 \begin_layout Description
26586 error Error box text color
26589 \begin_layout Description
26590 eolmarker End of line marker color
26593 \begin_layout Description
26594 added_space Added space colour
26597 \begin_layout Description
26598 appendix Appendix marker color
26601 \begin_layout Description
26602 changebar Changebar color
26605 \begin_layout Description
26606 deletedtext Deleted text color
26609 \begin_layout Description
26610 addedtext Added text color
26613 \begin_layout Description
26614 changedtextauthor1 Changed text color author 1
26617 \begin_layout Description
26618 changedtextauthor2 Changed text color author 2
26621 \begin_layout Description
26622 changedtextauthor3 Changed text color author 3
26625 \begin_layout Description
26626 changedtextauthor4 Changed text color author 4
26629 \begin_layout Description
26630 changedtextauthor5 Changed text color author 5
26633 \begin_layout Description
26634 deletedtextmodifier Deleted text modifying color
26637 \begin_layout Description
26638 tabularline Table line color
26641 \begin_layout Description
26642 tabularonoffline Table line color
26645 \begin_layout Description
26646 bottomarea Bottom area color
26649 \begin_layout Description
26650 newpage New page color
26653 \begin_layout Description
26654 pagebreak Page break color
26657 \begin_layout Description
26658 buttonframe Color used for button frame
26661 \begin_layout Description
26662 buttonbg Color used for bottom background
26665 \begin_layout Description
26666 buttonhoverbg Color used for buttom under focus
26669 \begin_layout Description
26670 paragraphmarker Color used for the pilcrow sign to mark the end of a paragraph
26674 \begin_layout Description
26675 previewframe Preview frame color
26678 \begin_layout Description
26679 inherit Color is inherited
26682 \begin_layout Description
26683 regexpframe Color for regexp frame
26686 \begin_layout Description
26687 ignore For ignoring updates of a color