1 #LyX 1.3 created this file. For more info see http://www.lyx.org/
6 \IfFileExists{isolatin.def}
7 {\usepackage[isolatin]{inputenc}}
8 {\usepackage[latin1]{inputenc}}
11 \inputencoding default
14 \paperfontsize default
21 \use_numerical_citations 0
22 \paperorientation portrait
25 \paragraph_separation indent
27 \quotes_language english
31 \paperpagestyle headings
35 Customizing LyX: Features for the Advanced User
44 Principal maintainer of this file is
49 If you have comments or error corrections, please send them to the LyX
50 Documentation mailing list, <lyx-docs@lists.lyx.org>.
57 \begin_inset LatexCommand \tableofcontents{}
67 This manual covers the customization features present in LyX.
68 In it, we discuss issues like keyboard shortcuts, screen previewing options,
69 printer options, sending commands to LyX via the LyX Server, internationalizati
70 on, installing new LaTeX classes and LyX layouts, etc.
71 We can't possibly hope to touch on everything you can change---our developers
72 add new features faster than we can document them---but we will explain
73 the most common customizations and hopefully point you in the right direction
74 for some of the more obscure ones.
77 LyX configuration files
81 \begin_inset LatexCommand \label{chap:config}
85 This chapter aims to help you to find your way through the LyX configuration
87 Before continuing to read this chapter, you should find out where your
88 LyX library directory is by using
93 elp\SpecialChar \menuseparator
101 This directory is the place where LyX places its system-wide configuration
102 files, and we will simply name it
106 in the remainder of this document.
121 and its sub-directories contain a number of files and that can be used
122 to customise LyX's behaviour.
123 You can change many of these files from within LyX itself through the
128 ools\SpecialChar \menuseparator
136 Most customization that you might want to do to LyX is possible through
138 However, many other inner aspects of LyX can be customized by modifying
144 They fall in different categories, described in the following subsections.
147 Automatically generated files
150 These files are generated when you configure LyX.
151 They contain various default values that are guessed by inspection.
152 In general, it is not a good idea to modify them, since they might be overwritt
155 \labelwidthstring 00.00.0000
163 contains defaults for various commands.
165 \labelwidthstring 00.00.0000
173 contains the list of packages that have been recognized by LyX.
174 It is currently unused by the LyX program itself, but the information extracted
175 , and more, is made available with
180 elp\SpecialChar \menuseparator
190 \labelwidthstring 00.00.0000
198 is the list of text classes that have been found in your
202 directory, along with the associated LaTeX document class and their description.
204 \labelwidthstring 00.00.0000
210 is automatically generated during configuration from the file
219 \labelwidthstring 00.00.0000
227 this directory contains files with the extension
231 that define the keybindings used in LyX (see section\SpecialChar ~
233 \begin_inset LatexCommand \ref{sec:bindings}
238 If there exists an internationalized version of the bindfile named
242 , that will be used first.
243 See Chapter\SpecialChar ~
245 \begin_inset LatexCommand \ref{chap:i18n}
250 \begin_inset LatexCommand \ref{sec:bindings}
256 \labelwidthstring 00.00.0000
264 contains graphics files that can be included in documents.
267 \labelwidthstring 00.00.0000
275 contains LyX documentation files (including the one you are currently reading).
280 deserves special attention, as noted above.
281 If there exists an internationalized version of the help-document with
286 prepended to the name, that will be used first.
287 See Chapter\SpecialChar ~
289 \begin_inset LatexCommand \ref{chap:i18n}
295 \labelwidthstring 00.00.0000
303 contains example files that explain how to use some features.
304 In the file browser, press the
310 \labelwidthstring 00.00.0000
316 contains image files that are used by the
321 In addition, it also contains the individual icons used in the toolbar
322 and the banners that can be shown when LyX is launched.
324 \labelwidthstring 00.00.0000
332 contains keyboard keymapping files.
333 See Chapter\SpecialChar ~
335 \begin_inset LatexCommand \ref{sec:keymap}
341 \labelwidthstring 00.00.0000
349 contains the text class files described in Chapter\SpecialChar ~
351 \begin_inset LatexCommand \ref{chap:textclass}
357 \labelwidthstring 00.00.0000
363 contains lots of files that together make up reLyX, the translator of
364 \begin_inset Quotes eld
368 \begin_inset Quotes erd
373 \labelwidthstring 00.00.0000
379 contains some files that demonstrate the capabilities of the
381 External\SpecialChar ~
386 \labelwidthstring 00.00.0000
392 contains the standard LyX template files described in Chapter\SpecialChar ~
394 \begin_inset LatexCommand \ref{sec:templates}
400 \labelwidthstring 00.00.0000
406 contains some LaTeX cls files distributed with LyX.
408 \labelwidthstring 00.00.0000
414 contains files with the extension
418 that define the user interface to LyX.
419 That is, the files define which items appear in which menus and the items
420 appearing on the toolbar.
421 See Chapter\SpecialChar ~
423 \begin_inset LatexCommand \ref{sec:ui}
430 Files you don't want to modify
433 These files are used internally by LyX and you generally do not need to
434 modify them unless you are a developer.
436 \labelwidthstring 00.00.0000
444 this file contains the list of LyX developers.
445 The contents are displayed with the menu entry
450 elp\SpecialChar \menuseparator
456 \labelwidthstring 00.00.0000
464 this is a LaTeX script used during the configuration process.
467 \labelwidthstring 00.00.0000
475 this is the script that is used to re-configure LyX.
476 It creates configuration files in the directory it was run from.
479 Other files needing a line or two...
481 \labelwidthstring 00.00.0000
487 this contains tables describing how different character encodings can be
490 \labelwidthstring 00.00.0000
496 this file contains the templates available to the new
498 External\SpecialChar ~
503 \labelwidthstring 00.00.0000
509 this file contains a list of all the languages currently supported by LyX.
511 \labelwidthstring 00.00.0000
517 Deprecated and definitely obfuscated.
518 This is the old style preferences file.
519 It will probably disappear in the near future.
522 Your local configuration directory
525 Even if you are using LyX as an unprivileged user, you might want to change
526 LyX configuration for your own use.
531 directory contains all your personal configuration files.
532 This is the directory described as
533 \begin_inset Quotes eld
537 \begin_inset Quotes erd
545 elp\SpecialChar \menuseparator
550 This directory is used as a mirror of
554 , which means that every file in
558 is a replacement for the corresponding file in
563 Any configuration file described in the above sections can be placed either
564 in the system-wide directory, in which case it will affect all users, or
565 in your local directory for your own use.
568 To make things clearer, let's provide a few examples:
571 The preferences set in the
576 ools\SpecialChar \menuseparator
583 dialog are saved to a file
594 When you reconfigure using
599 ools\SpecialChar \menuseparator
610 and the resulting files are written in your local configuration directory
611 (see section\SpecialChar ~
613 \begin_inset LatexCommand \ref{sec:autodetected}
617 to have a list of the
621 settings affected by this section).
622 This means that any additional text class file that you might have added
627 will be added to the list of classes in the
632 ayout\SpecialChar \menuseparator
642 Similarly, if you have installed some LaTeX document classes in your home
643 directory, that LaTeX can find with your
647 path, they will show up in your list of text classes.
653 as long as LyX or yourself have a
657 file for it, of course.
663 If you get some updated documentation from LyX ftp site and cannot install
664 it because you do not have sysadmin rights on your system, you can just
679 Running LyX with multiple configurations
682 The configuration freedom of the local configuration directory may not suffice
683 if you want to have more than one configuration at your disposal.
684 For example, you may want to be use different key bindings or printer settings
686 You can achieve this by having several such directories.
687 You then specify which directory to use at run-time.
690 Invoking LyX with the command line switch
697 instructs the program to read the configuration from that directory, and
698 not from the default directory (you can determine the default directory
699 by running LyX without this switch as described above).
700 If this directory does not exist, LyX offers to create it for you, just
701 like it does for the default directory on the first time you run the program.
702 You can modify the configuration options in this additional
706 exactly as you would for the default directory.
707 These directories are completely independent (but read on).
708 Note that setting the environment variable
712 to some value has exactly the same effect
717 Having several configurations also requires more maintenance: if you want
718 to add a new layout to
722 which you want available from all your configurations, you must add it
723 to each directory separately.
724 You can avoid this with the following trick: after LyX creates the additional
725 directory, most of the subdirectories (see above) are empty.
726 If you want the new configuration to mirror an existing one, replace the
727 empty subdirectory with a symbolic link to the matching subdirectory in
728 the existing configuration.
735 subirectory, however, since it contains a file written by the configuration
736 script (also accessible through
741 ools\SpecialChar \menuseparator
747 \begin_inset LatexCommand \ref{sec:autodetected}
753 which is configuration-specific.
766 Using the dialog for the first time
773 file will contain only changes that you have made to the default behaviour,
774 some of which is hard-coded into LyX and some of which is contained in
777 LyXDir/lyxrc.defaults
780 Note that in both files lines beginning with a
781 \begin_inset Quotes eld
789 \begin_inset Quotes erd
792 are just comments and not interpreted.
793 However, only system administrators should edit
804 ools\SpecialChar \menuseparator
811 dialog to create and modify their own
823 ools\SpecialChar \menuseparator
830 dialog will be largely self-explanatory.
831 Almost all the commands have an associated comment, so you shouldn't have
832 too much trouble modifying it to taste.
833 Before we highlight a few of the more important commands below, however,
838 ing some of your changes (e.g., screen fonts) will have an instant effect.
840 changing the bind file) will not.
841 If nothing appears to have changed, just
845 the changes and restart LyX.
851 The font used to display your documents on the LyX screen is very important,
852 since you'll be reading all your documents with this font.
853 Therefore it is important that the font is as readable and good-looking
855 The LyX team tried to provide the best possible default font for you, but
856 since practically all X11 systems are different, it's likely that the default
857 fonts will be sub-optimal on your system.
858 Fortunately, you can do something about this.
859 Before we explain how to do this, you should learn a bit more about fonts
860 so that you are better prepared for choosing your fonts, because it is
861 a trade-off that is specific to your preferences and the capabilities of
865 Notice that this section only deals with the fonts on the
869 inside the LyX window.
870 The fonts that appear on the
878 are independent from these fonts, and are determined by the document class.
883 to learn how to change the font of the printed version of your document.
886 Basically, screen fonts come in two different kinds: scalable outline fonts
887 and non-scalable bitmap fonts.
888 This distinction seems a bit arbitrary, since non-scalable fonts are actually
889 scalable in most modern font renderers.
890 The difference lies in the
894 of the scaling, and the
899 The most important decision is thus whether you should use non-scalable
900 bitmap fonts or scalable outline fonts.
903 The scalable fonts are built from
907 of the single glyphs (i.e.
908 characters) in the font.
909 This means that each glyph is defined using mathematical curves that are
910 well suited for scaling to any requested size.
911 This mathematical definition is interpreted by the font renderer and turned
912 into a small picture composed of pixels according to which size and glyph,
913 the programmer requests.
914 This means that scalable fonts will look pretty good in all sizes.
915 Well, almost all sizes.
916 Since scalable fonts are defined in an abstract way, it can be hard to
917 provide a good rendering at small sizes, where each pixel has to be very
918 carefully computed to provide a good image.
919 Technically it is possible to do this from the mathematical definition,
920 but in order to keep the rendering reasonably fast, tradeoffs have to be
921 made, and the result is that scalable fonts can be difficult to read at
925 Bitmap fonts on the other hand, are defined by bitmap graphics from the
926 start, so they will look good at all the sizes they are meant for.
927 However, they don't scale well, because in order to scale a glyph, each
928 pixel is enlarged into several pixels.
929 It is the same effect that happens if you try to enlarge a picture in
933 or any other picture manipulation program.
934 In order to relieve this effect, bitmap fonts are typically provided in
935 several fixed sizes typically from around 8 pixels high up to 34 pixels
936 or so high in steps according to what is believed to be useful.
937 The advantage of bitmap fonts is that no complicated computations are necessary
938 to display each glyph, so bitmap fonts are thus faster displayed than scalable
940 The disadvantage is that sizes that don't exists as fixed versions have
941 to be scaled by doubling pixels, and thus look bad.
944 The net result of all this, is that bitmap fonts are generally best for
945 the small sizes, where they are available, while scalable fonts are generally
946 best for large sizes.
947 The logical conclusion would thus be to use bitmap fonts for the small
948 sizes, and scalable fonts for the large sizes.
949 Unfortunately, this is not a good idea, since bitmap fonts and scalable
950 fonts are not designed to be used together, so the overall look of such
951 a scheme would be bad.
952 The best you can do is thus to try both schemes and decide for yourself
956 By default, LyX uses non-scalable bitmap fonts (when using the XForms frontend).
961 is used, for sans serif fonts,
969 is used as the monospaced/typewriter font.
972 In the following, we will describe what to do if the text does not look
974 We'll start with the most important parameters: DPI and font zoom.
977 DPI setting and Font Zoom
980 LyX automatically tries to scale the fonts to look as close as the paper
981 output size as possible, except for the so-called font zoom factor.
984 In order for this to work on all systems, it relies on the screen DPI (dots
985 per inch) setting to be correct.
986 The DPI setting for your system is autodetected by LyX using the information
987 the X server can provide.
988 You can check what LyX autodetects the DPI setting to, by running LyX as
996 On many systems, X is not set up correctly, so you should check that it
999 \begin_inset Quotes eld
1007 \begin_inset Quotes erd
1010 and write down what the DPI is for the resolution you use (this will be
1011 close to the value LyX detects).
1012 It is the number mentioned as
1013 \begin_inset Quotes eld
1017 \begin_inset Quotes erd
1021 Also write down the number of pixels you have in the width (the first number
1023 \begin_inset Quotes eld
1027 \begin_inset Quotes erd
1033 Then get the good old ruler out of the closet, and measure the width of
1034 the visible screen-image on your monitor.
1035 Convert this measurement to inches if you used a centimeter ruler by dividing
1037 Now you can determine the correct DPI setting for your screen by dividing
1038 the number of pixels in the width by the width of the screen-image on the
1040 If this number is more than, say, 5 DPI from the detected value, you should
1041 either fix the X setup, or at least tell LyX that the DPI is different
1042 than the detected value.
1045 If you can't fix the X setup (which of course is best since other programs
1046 than LyX will benefit from this as well), you can tell LyX the correct
1054 If the text is too small or too big for your taste, you should fiddle with
1055 the font zoom setting.
1056 This setting is used to scale the point size of the text.
1057 If your DPI setting is correct, and the font zoom setting is set to 100,
1058 this means that LyX will try to display the text exactly the same size
1059 as it will appear on the paper-output.
1060 If you set the zoom factor to 200, the text will try to be 2 times as big
1062 Of course, this will only happen if LyX can find a font that has the appropriat
1063 e size, which you can't count on.
1064 Since LyX is a WYSIWYM system anyways, this limitation isn't much of an
1068 The default font zoom setting is 150, since a monitor is typically wider
1069 than a piece of paper, but you should try to fiddle with it through the
1083 dialog to find a size that you like.
1084 When you've found a setting that seems to work nicely for you (tip: use
1092 button to keep the dialog open while you experiment), you can make this
1093 setting the default by using the
1103 While it is often possible to find a suitable size for the text on the screen,
1104 this doesn't necessarily mean that the fonts are the best ones available
1106 In order to help you get the most out of your system, you can use the font
1107 definition commands to fine-tune the look of the text in greater detail
1111 Font definition commands
1114 As mentioned, LyX uses non-scalable bitmap fonts by default with the XForms
1120 is used, for sans serif fonts,
1128 is used as the monospaced/typewriter font.
1131 You can change all of these from within the
1136 The number of fonts that are available on different systems vary, but the
1141 should be available everywhere.
1142 Use that program to find candidate fonts.
1143 When you've found a font that you like, try to insert the first two elements
1145 \begin_inset Quotes eld
1149 \begin_inset Quotes erd
1153 \begin_inset Quotes eld
1157 \begin_inset Quotes erd
1164 ) in the appropriate field in the
1176 LyX will then reformat your document using the new font, and if you like
1177 the font, you should
1185 One place to start for a new font is to see if the scalable font
1186 \begin_inset Quotes eld
1190 \begin_inset Quotes erd
1194 Tip: You can see whether a font is a bitmap font or a scalable font by
1196 \begin_inset Quotes eld
1200 \begin_inset Quotes erd
1204 \begin_inset Quotes eld
1208 \begin_inset Quotes erd
1216 If the value 0 is available, the font is scalable.
1217 If the value 0 isn't available, the font is a bitmap font.
1220 Before you go about scrapping a bitmap font because the larger sizes look
1222 \begin_inset Quotes eld
1226 \begin_inset Quotes erd
1229 , you should toggle the
1230 \begin_inset Quotes eld
1234 \begin_inset Quotes erd
1238 This is only useful if you use bitmap fonts, because only these don't scale
1240 If you define this flag, LyX will only use the fixed font sizes that are
1241 available, and this guarantees that all bitmap fonts look well.
1242 (You can see which individual font sizes are available with the
1251 .) However, the prize is that the difference between the size of the fonts
1252 on screen and the size of fonts on paper will be larger because LyX will
1253 have to be satisfied with the closest available size, and not try to scale
1255 Also, you can risk that some logically different sizes, such as
1263 , will be mapped to the same screen font, making it hard for you to see
1264 the difference on screen.
1265 We've decided not to use scalable fonts by default because of these artifacts,
1266 but since LyX is a WYSIWYM system, many people like to use the flag anyways,
1267 well-knowing that the font size on the screen can't be trusted.
1268 But remember that this flag only makes a difference when you use bitmap
1270 Scalable fonts won't be affected for reasons you should understand by now.
1273 One final note regarding this flag: you should know that there is nothing
1274 wrong with using bitmap and scalable fonts at the same time for different
1276 For instance, it's common to use the scalable
1277 \begin_inset Quotes eld
1281 \begin_inset Quotes erd
1284 for the serif text together with a bitmap version of
1285 \begin_inset Quotes eld
1289 \begin_inset Quotes erd
1293 And you can safely select the
1294 \begin_inset Quotes eld
1298 \begin_inset Quotes erd
1301 button without worries: It will only apply to the Helvetica font.
1304 Sometimes the artifacts introduced by use of the flag can be relieved by
1305 using the fine-detail screen font sizes which defines which point sizes
1306 the different logical font sizes correspond to.
1311 to see exactly what concrete fonts the logical sizes map to, and try adjusting
1312 the corresponding entries in the
1316 dialog until you've managed to hit the nail and get the fonts you want.
1317 This can be hard to do, because LyX uses the DPI setting and the font zoom
1318 settings to calculate which exact screen font size to ask the X server
1319 for, thus obfuscating the mapping.
1320 If you can't make it by trial-and-error, you can make the process more
1321 transparent if you set both the DPI setting and font zoom settings to 100---eve
1322 n when this is known to be wrong.
1323 This will of course make your scalable fonts look weird, so use with care.
1329 By default, LyX will use fonts meant to write Western European text, including
1330 all kinds of English.
1331 This is defined through the so-called
1340 If you want to use LyX to write for instance Eastern European text, Cyrillic
1341 or any other language not covered by the ISO-8859-1 font encoding, you
1342 can define a different one with the encoding setting.
1343 This requires you to have special fonts installed.
1348 to see whether this is the case: check the
1349 \begin_inset Quotes eld
1353 \begin_inset Quotes erd
1357 \begin_inset Quotes eld
1361 \begin_inset Quotes erd
1364 fields for ISO-8859-X values different from ISO-8859-1, and search for
1365 one that contains the national characters of your language.
1366 If you find any, enter this encoding in the dialog.
1367 If not, go searching the Web for appropriate fonts.
1368 For the Qt frontend, it's recommended you use an iso646 font set.
1371 When you've set LyX up to use a different font encoding, you should also
1372 consider changing the font used by dialog windows in LyX.
1379 dialog will not be understandable unless you tell LyX to use a different
1381 By default the menu font is set to
1383 -*-helvetica-medium-r
1385 , but often Helvetica is not available in the font encoding you need, so
1386 the dialog allows this to be changed.
1389 As you can see, there are quite a few options that can be used to fine tune
1390 the look of your fonts.
1391 This should not scare you from fiddling with the settings, because after
1392 all, you will hopefully be using LyX for many hours in the future.
1393 And contrary to real WYSIWYG word processors where you are tied to using
1394 fonts that have to look good both on paper and on screen, LyX gives you
1395 the possibility of using fonts that are designed to look good on the screen
1396 while using a different set of fonts to look good on paper.
1400 \begin_inset LatexCommand \label{sec:bindings}
1407 Bindings are used to, well, bind a function to a key.
1408 Several prepackaged binding files are available: a CUA set of bindings
1409 (familiar as the typical set of PC and CDE set of keyboard shortcuts),
1410 an Emacs set of bindings, for those of us who follow the One True Way and
1411 refuse to lower our standards,
1417 I'm kidding here, of course!
1420 as well as specialty bindings (broadway and hollywood) and other languages
1421 (French, German, etc.).
1424 If, however, you'd like to customise the keybindings to your own exacting
1425 tastes, then copy the best-fit file in
1434 Don't forget to load this new file into LyX using the
1439 (For the moment you'll have to restart LyX for these changes to take effect.)
1442 LyX supports internationalization of the user interface (see Chapter\SpecialChar ~
1444 \begin_inset LatexCommand \ref{chap:i18n}
1453 is set, with the environment variable
1457 , LyX will try to use bindfiles by prepending
1462 For example, you can put a translated copy of some standard bind file in
1467 directory, and LyX will use it automatically.
1474 files is straightforward:
1481 bind <key combination> <lyx-function>
1484 Both key combination and lyx-function (including any arguments) must be
1485 enclosed in "double quotes".
1486 All the LyX functions are listed in the
1494 \begin_inset LatexCommand \label{sec:ui}
1501 The appearance of both the menu and toolbar may both be changed using the
1516 For the moment, only one file exists,
1520 , but feel free to experiment.
1521 Just copy the file to the
1525 directory and play! Note that, for the moment, you'll have to restart LyX
1526 for these changes to take effect.
1533 files is straightforward: have a look at
1546 entries must be ended with an explicit
1571 s and in the case of the
1572 \begin_inset Quotes eld
1576 \begin_inset Quotes erd
1584 One small word of warning.
1589 s may be inserted in a
1597 , but they are defined as
1608 Converters, Formats and Viewers
1611 LyX has a new and powerful mechanism to convert to and from any file format
1612 using external programs.
1613 Define a pair of formats, e.g.
1623 Now define a converter from one format to the other.
1624 In our example, two possible mechanisms exist.
1627 A direct conversion, from LaTeX to PDF using pdflatex
1630 A more convoluted route using intermediate formats and converters: LaTeX
1631 to DVI (using latex) to PostScript® (using dvips) to PDF (using ps2pdf).
1634 LyX will always choose the shortest possible route, so you must specify
1635 two different Format names for
1639 files to be able to use either.
1640 Both are included by default in the
1645 Have a look and then invent your own!
1648 Moreover, each Format can have a Viewer associated with it.
1649 For example, you might want to use
1653 to examine PostScript® files, or
1657 to preview the LaTeX output.
1658 You can alter the viewer to use (and what options to pass to it) via the
1664 ools\SpecialChar \menuseparator
1669 references:Converters
1672 For example, to change the
1680 format in the dialog, change the viewer to be
1684 (or whatever), and hit
1694 BibTeX and makeindex
1697 Both the bibliography generating command (default
1701 ) and the index generating command (default
1714 As an alternative for
1726 The command to enter is
1731 makeindex.sh -m $$lang
1734 where the placeholder
1738 will be replaced by the chosen document (babel) language.
1742 have installed the packages
1759 at a shell prompt for a help page.
1762 ASCII export options
1764 \added_space_top bigskip \noindent
1765 There are a couple of commands that can be used to
1766 \begin_inset Quotes eld
1770 \begin_inset Quotes erd
1773 exported ASCII text files.
1774 Note that LyX automatically detects and uses the best settings for your
1775 system at installation time, but you can modify them if you disagree with
1787 This option defines the command used to produce better ASCII tables with
1792 UNIX-commands (refer to their manpages for more information about them).
1793 Setting this as empty tells LyX to use the internal (inferior) formatter.
1805 With this command you can set the default line length of the ASCII output
1807 Setting it to 0 means endless lines.
1813 There are a bunch of configuration options that are used for interaction
1814 with the external print command from LyX.
1815 Normally the defaults are fine: if, however, your print command takes different
1816 option names, you can modify them here.
1822 You can change the colors used by LyX on-screen using the new
1827 Alternatively, if you're feeling particularly perverse you could use the
1832 bindable function (see the
1837 Input would have the format:
1842 set-color LyXName X11Color
1845 Here is a (partial) list of the functions and default colors:
1849 \begin_inset Tabular
1850 <lyxtabular version="3" rows="10" columns="3">
1852 <column alignment="left" valignment="top" leftline="true" width="0pt">
1853 <column alignment="left" valignment="top" leftline="true" width="0pt">
1854 <column alignment="center" valignment="top" leftline="true" rightline="true" width="0pt">
1855 <row topline="true" bottomline="true">
1856 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
1873 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
1890 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
1908 <row topline="true">
1909 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
1926 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
1943 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
1961 <row topline="true">
1962 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
1979 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
1996 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2014 <row topline="true">
2015 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2032 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2049 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2067 <row topline="true">
2068 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2085 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2102 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2120 <row topline="true">
2121 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2138 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2152 fraction Lines, brackets, etc.
2155 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2173 <row topline="true">
2174 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2191 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2198 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2216 <row topline="true">
2217 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2234 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2241 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2259 <row topline="true">
2260 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2277 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2284 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2302 <row topline="true" bottomline="true">
2303 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2320 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
2334 selection background
2337 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
2362 The autodetected settings
2366 \begin_inset LatexCommand \label{sec:autodetected}
2370 There are several items that are detected for you when you run
2377 \SpecialChar \menuseparator
2383 In this section, we list those which pertain to the user preferences.
2406 , depending on what is available.
2421 plus a bunch of options.
2436 on systems (so-called System V) who have this command, and
2440 otherwise (BSD systems).
2448 print_spool_printerprefix
2459 , depending on whether
2486 fonts are found and LaTeX has support for these fonts built-in.
2487 You can set it manually if you only have the so-called
2497 There are many other configuration options that can be used to customize
2499 We still need to document them here, but again, most should be fairly obvious.
2500 Please ask on the mailing lists if you need some more information; it may
2501 even prompt us to expand this section.
2504 Internationalizing LyX
2505 \begin_inset LatexCommand \label{chap:i18n}
2512 LyX supports using a translated interface.
2513 Last time we checked, LyX provided text in 14 languages together with the
2514 default English text.
2515 The language of choice is called your
2520 (For further reading on locale settings, see also the documentation for
2521 locale that comes with your operating system.
2522 For Linux, the manual page for locale(5) could be a good place to start).
2525 Notice that these translations will work, but do contain a few flaws.
2526 In particular, all dialogs have been designed with the English text in
2527 mind, which means that some of the translated text will be too large to
2528 fit within the space allocated.
2529 This is only a display problem and will not cause any harm.
2530 Also, you will find that some of the translations do not define short-cut
2531 keys for everything.
2532 Sometimes, there are simply not enough free letters to do it.
2533 Other times, the translator just hasn't got around to doing it yet.
2534 We'll try to fix these shortcomings in future versions of LyX.
2537 Selecting an alternative language for the user interface
2540 This feature is disabled by default, meaning that the text will be English.
2541 To enable an alternative language, you have to set an appropriate environment
2549 for csh class shells
2564 with the two letter code for the language you want.
2572 Normally, you'll want to put the appropriate line in
2580 so that the translation is on by default.
2581 Remember that if LyX is configured and compiled with
2582 \begin_inset Quotes eld
2590 \begin_inset Quotes erd
2593 , this will not work.
2599 Translating the graphical user interface (text messages).
2606 library to handle the internationalization of the interface.
2607 To have LyX speak your favorite language in all menus and dialogs, you
2612 -file for that language.
2613 When this is available, you'll have to generate a mo-file from it and install
2619 The process of doing all of this is explained in the documentation for
2624 , but in short, this is what you do (
2628 denotes the language code):
2646 LYX-SOURCE-DIR/po/lyx.pot
2659 doesn't exist, it can be remade with
2663 in that directory, or you can use an existing po-file for some other language
2675 We recommend that you use Emacs to do this, since the
2679 distribution includes a nice mode that supports you in doing this.
2685 For some menu- and widget-labels, there are also shortcut keys that should
2687 Those keys are marked after a `|', and should be translated according to
2688 the words and phrases of the
2693 There is a tool named
2697 written in Prolog in
2699 LYX-SOURCE-DIR/development/tools/
2701 that may be useful to help determine short-cut keys.
2702 Note that XForms (version 0.86 at least) can't handle anything but 7-bit
2703 characters as shortcut keys.
2704 You should also fill also out the information at the beginning of the new
2709 -file with your email-address, etc., so people know where to reach you with
2710 suggestions and entertaining flames.
2721 This can be done with
2744 -file to your locale-tree, at the correct directory for application messages
2749 , and under the name
2758 /usr/local/share/locale/
2782 Adding a new po-file to the
2786 of LyX involves altering the configure scripts and more, but the way
2790 works, you don't actually need the source-code of LyX to translate it---having
2806 If you've written a translation file for a language that LyX does not currently
2807 support, feel free to submit it for inclusion by sending a patch.
2808 In this case, we recommend that you read the
2816 directory for more instructions.
2817 \layout Subsubsection
2822 Sometimes it turns out that one english message needs to be translated into
2823 different messages in the target language.
2824 One example is the message
2828 which has the german translation
2845 does not handle such ambigous translations.
2846 Therefore you have to add some context information to the message: Instead
2853 To[[as in 'From format x to format y']]
2857 To[[as in 'From page x to page y']].
2860 Now the two occurences of
2868 and can be translated correctly to
2883 Of course the context information needs to be stripped off the original
2884 message when no translation is used.
2885 Therefore you have to put it in double square brackets at the end of the
2886 message (see the example above).
2887 The translation mechanism of LyX ensures that everything in double square
2888 brackets at the end of messages is removed before displaying the message.
2891 Translating the documentation.
2894 The online documentation (in the
2901 -menu) can (and should!) be translated.
2902 If there are translated versions of the documentation available
2908 As of February 2003, almost all of the docs have been translated into German
2914 has been translated into at least 12 other languages, with other translations
2916 The library of translated documents is growing rapidly.
2919 , and the locale is set accordingly, these will be used automagically by
2921 LyX looks for translated versions as
2935 denotes the language as set by the environmental variable
2940 If there are none, the default English versions will be displayed.
2941 Note that the translated versions must have the same filenames (
2945 above) as the original.
2946 If you feel up to translating the documentation (an excellent way to proof-read
2947 the original documentation BTW!), there are a few things you should do
2955 , the guide to writing LyX documentation.
2956 Pay special attention to the translator's section.
2959 Check out the documentation translation web page at
2960 \begin_inset LatexCommand \url[The LyX Developer's Web Site]{http://www.devel.lyx.org}
2965 That way, you can find out which (if any) documents have already been translate
2966 d into your language.
2967 You can also find out who (if anyone) is organizing the effort to translate
2968 the documentation into your language.
2969 If no one is organizing the effort, please let us know that you're interested.
2972 Once you get to actually translating, here's a few hints for you that may
2976 Join the documentation team! There is information on how to do that in
2985 elp\SpecialChar \menuseparator
2992 ), which by the way is the first document you should translate.
2995 Learn the typographic conventions for the language you are translating to.
2996 Typography is an ancient art and over the centuries, a great variety of
2997 conventions have developed throughout different parts of the world.
2998 Also study the professional terminology amongst typographers in your country.
2999 Inventing your own terminology will only confuse the users.
3002 (Warning! Typography is addictive!)
3005 Make a copy of the document.
3006 This will be your working copy.
3007 You can use this as your personal translated help-file by placing it in
3015 Sometimes the original document (from the LyX-team) will be updated.
3016 Use the ViewCVS tool available at
3017 \begin_inset LatexCommand \htmlurl{http://www.lyx.org/viewcvs.cgi/lyxdoc/}
3021 to see what has been changed
3027 Alternatively, you can keep a copy of the latest version of the English
3028 document which you've translated.
3032 That way you can easily see which parts of the translated document need
3036 If you ever find an error in the original document, fix it and notify the
3037 rest of the documentation team of the changes! (You didn't forget to join
3038 the documentation team did you?)
3041 International Keyboard Support
3046 [Editor's Note: The following section is by
3051 It needs to be fixed to conform to the new Documentation Style sheet and
3052 to make use of the new v1.0 features.
3053 The whole thing also needs to be merged with the section following it.-jw]
3056 Defining Own Keymaps: Keymap File Format
3059 Let's look at a keyboard definition file a little closer.
3060 It is a plain ASCII file defining
3063 key-to-key or key-to-string translations
3069 dead keys exceptions
3072 To define key-to-key or key-to-string translation, use this command:
3094 is the key to be translated and
3098 is the string to be inserted into the document.
3099 To define dead keys, use:
3126 The following dead keys are supported (shortcut name is in parentheses):
3243 hungarian umlaut (hug)
3271 Since in many international keyboards there are exceptions to what some
3272 dead keys should do, you can define them using
3283 deadkey key outstring
3286 For example, on Slovak keyboard, if you enter caron-o, it generates circumflex-o
3303 to make it work correctly.
3304 Also, you have to define as exceptions dead keys over i and j, to remove
3305 the dot from them before inserting an accent mark.
3306 I will change this when the time comes, but so far I haven't had time.
3309 Oh, and about characters: backslash is escaped, so to enter it, you'll need
3315 have different meaning.
3320 marks comments, quotes start and end LaTeX-style commands.
3321 To enter quote, you'll need to use
3340 If you make a keyboard description file that works for your language, please
3341 mail it to me, so I can include it in the next keymap distribution.
3344 More keywords will be supported in keymap configuration file in future,
3379 an external keymap translation program
3382 Also, it should look into
3386 file for defaults, too (for example, a
3392 option to include default keyboard).
3395 International Keymap Stuff
3396 \begin_inset LatexCommand \label{sec:keymap}
3403 The next two sections describe the
3415 file syntax in detail.
3416 These sections should help you design your own key map if the ones provided
3417 do not meet your needs.
3431 file maps keystrokes to characters or strings.
3432 As the name suggests it sets a keyboard mapping.
3457 are described in this section.
3459 \labelwidthstring 00.00.0000
3467 Map a character to a string
3499 the double-quote (")
3507 must be escaped with a preceding backslash (
3524 statement to cause the symbol
3530 to be output for the keystroke
3543 \labelwidthstring 00.00.0000
3551 Specify an accent character
3563 This will make the cha
3578 This is the dead key
3590 refers to a key that does not produce a character by itself, but when followed
3591 with another key, produces the desired accent character.
3592 For example, a German characte
3594 r with an umlaut like
3598 can be produced in this manner.
3611 and then another key not in
3619 followed by the other, unallowed key, as output.
3628 cancels a dead key, so if
3639 , the cursor will not go one position backwards but will instead cancel
3646 might have had on the next keystroke.
3650 The following example specifies that the character ' is to be an acute accent,
3651 allowed on the characters a, e, i, o, u, A, E, I, O, and U:
3656 kmod ' acute aeiouAEIOU
3658 \labelwidthstring 00.00.0000
3664 Specify an exception to the accent character
3677 This defines an exce
3696 have been assigned a keystroke with a previous
3710 must not belong in the
3730 If such a declaration does not exist in
3767 The following command produces causes äi to be produced when you enter acute-i
3783 \labelwidthstring 00.00.0000
3789 Combine two accent characters
3797 accent1 accent2 allowed
3800 This one is getting pretty esoteric.
3801 It allows you to combine the effect
3846 Consider this example from the
3857 kmod ; acute aeioyvhAEIOYVH
3861 kcomb acute umlaut iyIY
3864 This allows you to press
3870 and get the effect of
3887 in this case cancels the last dead key, so if you press
3915 mapping is performed, a
3922 file maps the strings that the symbols generate to characters in the current
3924 The LyX distribution currently includes at least the
3947 file is a sequence of declarations of the form
3960 For example, in order to map
3968 to the corresponding character in the iso-8859-1 set (233), the following
3998 the same character can apply to more than one string.
4036 If LyX cannot find a mapping for the string produced by the keystroke or
4037 a deadkey sequence, it will check if it looks like an accented char and
4038 try to draw an accent over the character on screen.
4044 There is a second way to add support for international characters through
4045 so-called dead-keys.
4046 A dead-key works in combination with a letter to produce an accented character.
4047 Here, we'll explain how to create a really simple dead-key to illustrate
4051 Suppose you happen to need the circumflex character,
4052 \begin_inset Quotes eld
4057 \begin_inset Quotes erd
4065 -key [a.k.a.\SpecialChar ~
4070 ] to the LyX command
4079 Now, whenever you type the
4083 -key followed by a letter, that letter will have a circumflex accent on
4085 For example, the sequence
4086 \begin_inset Quotes eld
4094 \begin_inset Quotes erd
4097 produces the letter:
4098 \begin_inset Quotes eld
4102 \begin_inset Quotes erd
4106 If you tried to type
4107 \begin_inset Quotes eld
4115 \begin_inset Quotes erd
4118 , however, LyX will complain with a beep, since a
4119 \begin_inset Quotes eld
4127 \begin_inset Quotes erd
4130 never takes a circumflex accent.
4135 after a dead-key produces the bare-accent.
4136 Please note this last point! If you bind a key to a dead-key, you'll need
4137 to rebind the character on that key to yet another key.
4142 to a cedilla is a bad idea, since you'll only get cedillas instead of commas.
4145 One common way to bind dead-keys is to use
4157 in combination with an accent, like
4158 \begin_inset Quotes eld
4166 \begin_inset Quotes erd
4170 \begin_inset Quotes eld
4178 \begin_inset Quotes erd
4182 \begin_inset Quotes eld
4190 \begin_inset Quotes erd
4194 Another way involves using
4202 [remember them from section?] to set up the special
4211 acts in some ways just like
4215 and permits you to bind keys to accented characters.
4216 You can also turn keys into dead-keys by binding them to something like
4221 and then binding this symbolic key to the corresponding LyX command.
4231 : This is exactly what I do in my
4242 Scroll\SpecialChar ~
4249 and a bunch of these
4250 \begin_inset Quotes eld
4258 \begin_inset Quotes erd
4261 symbolic keys bound such things as
4263 Scroll\SpecialChar ~
4268 Scroll\SpecialChar ~
4272 This is how I produce my accented characters.
4275 You can make just about anything into the
4283 keys, a spare function key, etc.
4284 As for the LyX commands that produce accents, check the entry for
4293 You'll find the complete list there.
4296 Saving your Language Configuration
4300 \begin_inset LatexCommand \label{sec:savlang}
4304 You can edit your preferences so that your desired language environment
4305 is automatically configured when LyX starts up, via the
4310 dit\SpecialChar \menuseparator
4320 Installing New Document Classes, Layouts, and Templates
4321 \begin_inset LatexCommand \label{chap:textclass}
4331 Installing New Document Classes
4337 In this chapter, we describe the procedures for creating and installing
4338 new LyX layout and template files, as well as offer a refresher on correctly
4339 installing new LaTeX document classes.
4340 Some definitions: a document class is a LaTeX file (usually ending in
4348 ) which describes the format of a document such as an article, report, journal
4350 and all the commands needed to realize that format.
4351 A layout file is a LyX file which corresponds to a LaTeX document class
4352 and which tells LyX how to
4353 \begin_inset Quotes eld
4357 \begin_inset Quotes erd
4360 things on the screen to make the display look something like the final
4362 More precisely, a layout file describes a
4363 \begin_inset Quotes eld
4367 \begin_inset Quotes erd
4370 which is the internal construct LyX uses to render the screen display.
4372 \begin_inset Quotes eld
4376 \begin_inset Quotes erd
4380 \begin_inset Quotes eld
4384 \begin_inset Quotes erd
4387 can be used somewhat interchangeably, but it is better to refer to the
4388 file as the layout, and the thing living in LyX's memory as the text class.
4389 A template file is simply a LyX document which contains a set of predefined
4390 entries for a given document class which are generally required for that
4392 Templates are especially useful for things like journal manuscripts which
4393 are to be submitted electronically.
4396 Installing a new LaTeX package
4399 Some installations may not include a LaTeX package that you would like to
4401 For example, you might need FoilTeX, a common (and very powerful) package
4402 for preparing slides or viewgraphs for overhead projectors.
4403 Here are the formal steps involved in getting the package up and running
4404 if you are using teTeX or some other web2c based distribution.
4408 Get the package from CTAN or wherever.
4416 Inventory of your LaTeX configuration
4418 manual for details of what CTAN is and where supported document classes
4429 (this usually lives in the directory
4433 , though you can run
4438 It describes how to add a local
4442 directory; follow the instructions.
4443 You need to insert the name of your local
4456 is a logical place to install software that did not come with your distribution
4462 Usually, you will have to modify only two things:
4470 to the directory you chose; e.g.
4475 TEXMFLOCAL = /usr/local/texmf
4491 TEXMF = {$HOMETEXMF,!!$TEXMFLOCAL,!!$TEXMFMAIN}
4505 You must follow the directory structure of your existing
4509 directory (for example, latex packages should go under
4511 /usr/local/texmf/tex/latex/
4516 Install the package.
4517 For example, you would unpack the FoilTeX tarball and create
4519 /usr/local/texmf/tex/latex/foiltex
4526 directory contains various files.
4536 /usr/local/texmf/ls-R
4541 From within LyX, do:
4546 ools\SpecialChar \menuseparator
4557 Now you should see your new package---for example
4566 ayout\SpecialChar \menuseparator
4581 Note that there are simpler ways of installing packages: you can add a
4582 link to the new package directory in the system LaTeX directory (
4586 , don't forget to then run
4590 ), or sometimes simply set the
4594 environment variable to include the new package.
4595 However, the formal procedure described in
4599 is guaranteed to work, so you should follow it unless circumstances absolutely
4600 prevent it: such as, when you don't have superuser access.
4606 This section describes how to write and install your own LyX layout files
4607 (also known as text classes) and walks through the
4611 text class format as an example.
4616 files describe what paragraph styles are available for a given document
4617 class and how LyX should display them.
4618 We try to provide a thorough description of the process here; however,
4619 there are so many different types of documents supported by LaTeX classes
4620 we can't hope to cover every different possibility or problem you might
4625 When you plan to write a new layout, it is extremely helpful to look at
4626 the example layouts distributed with LyX.
4627 If you use a nice LaTeX document class that might be of interest for others,
4628 too, and have a nice corresponding LyX layout, feel free to contribute
4629 the stuff to us, so we may put it into the distribution.
4632 All the tags described in this chapter are case-insensitive; this means
4645 are really the same command.
4646 The possible values are printed in brackets after the feature's name.
4647 The default value if a feature isn't specified inside a text class-description
4655 If the argument has a datatype like
4656 \begin_inset Quotes eld
4660 \begin_inset Quotes erd
4664 \begin_inset Quotes eld
4668 \begin_inset Quotes erd
4671 , the default is shown like this:
4681 Supporting new document classes
4684 There are two situations you are likely to encounter when wanting to support
4685 a new LaTeX document class, involving LaTeX2e class (
4703 If your new document class is provided as a style file that is used in conjuncti
4704 on with an existing, supported document class, start by copying the existing
4705 class's layout file into your local directory.
4706 For the sake of example we'll assume that the style file is called
4710 and it is meant to be used with
4714 which is a standard class.
4717 cp report.layout ~/.lyx/layouts/myclass.layout
4724 and change the line:
4729 DeclareLaTeXClass{report}
4737 DeclareLaTeXClass[report, myclass.sty]{report (myclass)}
4752 near the top of the file.
4755 Start LyX and select
4760 ools\SpecialChar \menuseparator
4768 Restart LyX and try creating a new document.
4773 " as a document class option in the
4778 ocument\SpecialChar \menuseparator
4786 It is likely that some of the sectioning commands and such will differ
4787 from how the base class
4800 works, so you can fiddle around with the settings for the different sections
4802 See below for more discussion on this.
4812 In this case, you will probably have to
4813 \begin_inset Quotes eld
4817 \begin_inset Quotes erd
4821 We strongly suggest copying an existing layout file which uses a similar
4822 LaTeX class and modifying it if at all possible.
4823 At least use an existing file as a starting point so you can find out what
4824 items you need to worry about.
4825 Again, the specifics are covered below.
4828 Declaring a new text class
4831 When it's finally time to get your hands dirty and create or edit your own
4832 layout file, the following sections describe what you're up against.
4833 Our advice is to go slowly, save and test often, listen to soothing music,
4834 and enjoy one or two of your favorite adult beverages; more if you are
4835 getting particularly stuck.
4836 It's really not that hard, except that the multitude of options can become
4837 overwhelming if you try to do to much in one sitting.
4838 Go have another adult beverage, just for good measure.
4844 Lines in a layout file which begin with a
4849 There is one exception to this rule: all layouts should begin with lines
4855 #% Do not delete the line below; configure depends on this
4862 DeclareLaTeXClass{article}
4865 The second line is used when you configure LyX.
4866 The layout file is read by the LaTeX script
4870 , in a special mode where
4875 The first line is just a LaTeX comment, and the second one contains the
4876 declaration of the text class.
4877 If these lines appear in a file named
4881 , then they define a text class of name
4885 (the name of the layout file) which uses the LaTeX document class
4889 (the default is to use the same name as the layout).
4891 \begin_inset Quotes eld
4895 \begin_inset Quotes erd
4898 that appears above is used as a description of the text class in the
4903 ocument\SpecialChar \menuseparator
4913 Let's assume that you wrote your own text class that uses the
4917 documentclass, but where you changed the appearance of the section headings.
4918 If you put it in a file
4922 , the header of this file should be:
4927 #% Do not delete the line below; configure depends on this
4934 DeclareLaTeXClass[article]{article (with my own headings)}
4937 This declares a text class
4941 , associated with the LaTeX document class
4946 \begin_inset Quotes eld
4949 article (with my own headings)
4950 \begin_inset Quotes erd
4954 If your text class depends on several packages, you can declare it as:
4959 #% Do not delete the line below; configure depends on this
4966 DeclareLaTeXClass[article,foo.sty]{article (with my own headings)}
4969 This indicates that your text class uses the foo.sty package.
4970 Finally, it is also possible to declare classes for SGML and DocBook code.
4971 Typical declarations will look like
4976 #% Do not delete the line below; configure depends on this
4983 DeclareSGMLClass{SGML (LinuxDoc)}
4989 #% Do not delete the line below; configure depends on this
4994 DeclareDocBookClass[article]{SGML (DocBook article)}
4997 Note that these declarations can also be given an optional parameter declaring
4998 the name of the document class (but not a list).
5001 When the text class has been modified to your taste, all you have to do
5002 is to copy it either in
5015 ools\SpecialChar \menuseparator
5023 Exit LyX and restart it; then your new text class should be available along
5027 General text class parameters
5030 These are the general parameters which describe the form of the entire document:
5059 ] Whether the class-default should have one or two columns.
5060 Can be changed in the
5065 ocument\SpecialChar \menuseparator
5076 This setting (same goes for
5080 , too) is important: if your text class has two columns by default but you
5081 forget to set it correctly, the
5089 be output when you select
5098 ocument\SpecialChar \menuseparator
5119 ] Whether the class-default should be printing on one or both sides of the
5121 Can be changed in the
5129 ocument\SpecialChar \menuseparator
5153 ] The class default pagestyle.
5154 Can be changed in the
5159 ocument\SpecialChar \menuseparator
5183 , Counter_Section, Counter_Subsection, Counter_Subsubsection, Counter_Paragraph,
5186 Counter_Subparagraph, Counter_EnumI, Counter_EnumII,
5188 Counter_EnumIII, Counter_EnumIV
5190 ] The highest level of automatic enumeration.
5195 for a book or report and
5200 If there is no enumeration needed at all, for example inside a letter class,
5216 ClassOptions\SpecialChar \ldots{}
5220 This section describes various global options supported by the document
5222 See Section\SpecialChar ~
5224 \begin_inset LatexCommand \ref{sec:classoptions}
5244 ] Whether the class already loads the
5249 This is the case of the
5273 ] Whether the class already provides the functionality of the
5278 This is the case of the
5302 ] Whether the class already provides the functionality of the
5307 This is the case of the
5320 This is used to describe the default font of the document.
5321 See Section\SpecialChar ~
5323 \begin_inset LatexCommand \ref{sec:fonts}
5340 ] This is the style that will be assigned to new paragraphs, usually
5345 This will default to the first defined style if not given, but you are
5346 highly encouraged to use this directive.
5365 ] Indicates what kind of markup is used to define the title of a document.
5370 means that the macro with name
5374 will be inserted after the last layout which has
5375 \begin_inset Quotes eld
5383 \begin_inset Quotes erd
5391 corresponds to the case where the block of paragraphs which have
5392 \begin_inset Quotes eld
5400 \begin_inset Quotes erd
5403 should be enclosed into the
5422 ] The name of the command/environment mentionned above.
5428 Preamble\SpecialChar \ldots{}
5432 A set of macro definitions that will be output at the beginning of the
5434 Use this for global definitions.
5443 As its name implies, this command allows you to include another layout
5444 definition file within yours to avoid duplicating commands.
5445 Common examples are the standard layout files, for example,
5449 , which contains most of the basic layouts.
5455 Style\SpecialChar \ldots{}
5459 This sequence defines a new style.
5460 See Section\SpecialChar ~
5462 \begin_inset LatexCommand \ref{sec:style}
5475 This command deletes an existing style.
5476 This is particularly useful when you want to suppress a style that has
5477 be defined in an input file.
5483 Float\SpecialChar \ldots{}
5487 This sequance defines a new float.
5488 See Section\SpecialChar ~
5490 \begin_inset LatexCommand \ref{sec:floats}
5503 This command deletes an existing float.
5504 This is particularly useful when you want to suppress a float that has
5505 be defined in an input file.
5511 Counter\SpecialChar \ldots{}
5515 This sequence defines a new counter.
5516 See Section\SpecialChar ~
5518 \begin_inset LatexCommand \ref{sec:counter}
5546 \begin_inset LatexCommand \label{sec:classoptions}
5554 section can contain the following entries:
5567 ] The list of available font sizes for the document's main font, separated
5569 \begin_inset Quotes eld
5577 \begin_inset Quotes erd
5591 string="empty|plain|headings|fancy"
5593 ] The list of available page styles, separated by
5594 \begin_inset Quotes eld
5602 \begin_inset Quotes erd
5618 ] Some document class options, separated by a comma, that will be added
5619 to the optional part of the
5628 Specific Paragraph Layouts
5632 \begin_inset LatexCommand \label{sec:style}
5636 A paragraph layout description looks like this
5642 Note that this will either define a new layout or modify an existing one.
5660 where the following commands are allowed:
5682 This is used to copy all the features of an existing layout into the current
5698 , Command, Environment, Item_Environment,
5704 ] How the layout should be translated into LaTeX.
5709 means nothing special.
5722 {\SpecialChar \ldots{}
5737 }\SpecialChar \ldots{}
5761 is generated for each paragraph of this environment.
5774 is passed as an argument to the environment.
5779 can be defined in the
5784 ayout\SpecialChar \menuseparator
5798 is perhaps a bit misleading, since these rules apply to SGML classes, too.
5799 Visit the SGML class files for specific examples.
5809 If 1, marks the layout as being part of a title block (see also the
5826 The name of the corresponding LaTeX stuff.
5827 Either the environment or command name.
5836 The optional parameter for the corresponding
5843 This parameter cannot be changed from within LyX.
5857 , Manual, Dynamic, First_Dynamic, Right_Address_Box
5861 The kind of margin that the layout has on the left side.
5866 just means a fixed margin.
5871 means that the left margin depends on the string entered in the
5876 dit\SpecialChar \menuseparator
5881 aragraph\SpecialChar ~
5885 This is used to typeset nice lists without tabulators.
5890 means that the margin depends on the size of the label.
5891 This is used for automatic enumerated headlines.
5892 It is obvious that the headline
5893 \begin_inset Quotes eld
5896 5.4.3.2.1 Very long headline
5897 \begin_inset Quotes erd
5900 must have a wider left margin (as wide as
5901 \begin_inset Quotes eld
5905 \begin_inset Quotes erd
5908 plus the space) than
5909 \begin_inset Quotes eld
5912 3.2 Very long headline
5913 \begin_inset Quotes erd
5916 , even if other word processors are not able to do this.
5921 is similar, but only the very first row of the paragraph is dynamic, while
5922 the others are static; this is used, for example, for descriptions.
5927 means the margin is chosen in a way that the longest row of this paragraph
5928 fits to the right margin.
5929 This is used to typeset an address on the right edge of the page.
5945 ] Whether the following Paragraph is allowed to indent its very first row.
5950 means that it is not allowed to do so,
5954 means it could do so if it wants to.
5967 ] The indent of the very first line of a paragraph.
5968 The argument is passed as a string.
5973 means that the paragraph is indented with the width of
5982 You can get a negative width by prefixing the string with
5987 This way was chosen so that the look is the same with each used screen
5993 will be fixed for a certain layout.
5994 The exception is Standard layout, since the indentation of a Standard layout
5995 paragraph can be prohibited with
6000 Also, Standard layout paragraphs inside environments use the
6004 of the environment, not their native one.
6005 For example, Standard paragraphs inside an enumeration are not indented.
6018 ] LyX allows to choose either
6019 \begin_inset Quotes eld
6023 \begin_inset Quotes erd
6027 \begin_inset Quotes eld
6031 \begin_inset Quotes erd
6034 to typeset a document.
6036 \begin_inset Quotes eld
6040 \begin_inset Quotes erd
6043 is chosen, this value is completely ignored.
6045 \begin_inset Quotes eld
6049 \begin_inset Quotes erd
6052 is chosen, the parindent of a LaTeXtype
6053 \begin_inset Quotes eld
6057 \begin_inset Quotes erd
6060 layout is ignored and all paragraphs are additionally separated by this
6062 The vertical space is calculated with
6064 value*DefaultHeight()
6070 is the height of a row with the normal font.
6071 This way, the look stays the same with different screen fonts.
6084 ] The vertical space with which the very first of a chain of paragraphs
6085 with this layout is separated from the previous paragraph.
6086 If the previous paragraph has another layout, the separations are not simply
6087 added, but the maximum is taken.
6104 for the very last paragraph.
6117 ] The vertical space between two paragraphs of this layout.
6130 ] This is an extra space between the paragraphs of an environment layout.
6131 If you put other layouts into an environment, each is separated with the
6137 But the whole items of the environment are additionally separated with
6156 ] If you put layouts into environments, the leftmargins are not simply added,
6157 but added with a factor
6158 \begin_inset Formula $\frac{4}{depth+4}$
6162 Note that this parameter is also used when the border is defined as
6171 Then it is added to the manual or dynamic border.
6172 This string has the same meaning as for
6207 , Manual, Static, Top_Environment,
6209 Centered_Top_Environment, Sensitive, Counter_Chapter,
6211 Counter_Section, Counter_Subsection, Counter_Subsubsection,
6213 Counter_Paragraph, Counter_Subparagraph, Counter_EnumI,
6219 Counter_EnumII, Counter_EnumIII, Counter_EnumIV
6227 means the label is the very first word (up to the first real blank).
6232 means it is defined in the layout (see
6243 Centered_Top_Environment
6245 are special cases of
6250 The label will be printed above the paragraph, but only at the top of an
6251 environment or the top of a chain of paragraphs with this layout.
6252 Usage is for example the
6261 This is also the case for
6265 labels with latex type
6269 , in order to make layouts for theorems work correctly.
6274 is a special case for the caption-labels
6275 \begin_inset Quotes eld
6279 \begin_inset Quotes erd
6283 \begin_inset Quotes eld
6287 \begin_inset Quotes erd
6295 means the (hardcoded) label string depends on the kind of float.
6300 label types should be self explanatory.
6313 ] The horizontal space between the label and the text body.
6314 Only used for labels that are not above the text body.
6323 [float=0] The vertical space between the label and the text body.
6324 Only used for labels that are above the text body (
6330 Centered_Top_Environment
6345 ] The string used for a label with a
6354 this string is also used as a suggestion for the
6358 that can be set in the
6363 dit\SpecialChar \menuseparator
6368 aragraph\SpecialChar ~
6372 When the labeltype is
6379 , this string is prepended to the counter.
6393 , Box, Filled_Box, Static
6395 ] The type of label that stands at the end of the paragraph (or sequence
6418 \begin_inset Quotes eld
6422 \begin_inset Quotes erd
6434 ) is a white (resp.\SpecialChar ~
6435 black) square suitable for end of proof markers,
6439 is an explicit text string.
6452 ] The string used for a label with a
6475 , left, right, center
6477 ] Paragraph alignment.
6491 , left, right, center
6498 Some LaTeX styles prohibit certain alignments, since those wouldn't make
6500 For example a right-aligned or centered enumeration isn't possible.
6516 ] With this parameter the
6521 \begin_inset Quotes eld
6524 Vertical space above
6525 \begin_inset Quotes erd
6533 dit\SpecialChar \menuseparator
6538 aragraph\SpecialChar ~
6541 dialog can be set when initializing a paragraph with this layout
6549 Note from Jean-Marc:
6551 I'm not sure that this setting has much use, and it should probably be removed
6592 ] Whether fragile commands in this layout should be
6614 ] Whether newlines are translated into LaTeX newlines (
6623 The translation can be switched off to allow more comfortable LaTeX editing
6640 ] Whether the contents of this paragraph should be output in raw form, meaning
6641 without special translations that LaTeX would require.
6642 This somehow replaces the older
6662 ] Usually LyX doesn't allow you to insert more than one space between words,
6663 since a space is considered as the separation between two words, not a
6664 character or symbol of its own.
6665 This is a very fine thing but sometimes annoying, for example when typing
6666 program code or plain LaTeX code.
6672 Note that LyX will create protected blanks for the additional blanks when
6673 in another mode than LaTeX-mode.
6689 ] Usually LyX does not allow you to leave a paragraph empty, since it would
6690 lead to empty LaTeX output.
6691 There are some cases where this could be desirable however: in a letter
6692 template, the required fields can be provided as empty fields, so that
6693 people do not forget them; in some special classes, a layout can be used
6694 as some kind of break, which does not contain actual text.
6708 , onehalf, double, other
6713 ] This defines what the default spacing should be in the layout.
6726 correspond respectively to a multiplier value of 1, 1.25 and 1.667.
6727 If you specify the argument
6731 , then you should also provide a numerical argument which will be the actual
6733 Note that, contrary to other parameters,
6737 implies the generation of specific LaTeX code, using the package
6751 The font used for both the text body
6756 See section\SpecialChar ~
6758 \begin_inset LatexCommand \ref{sec:fonts}
6763 Note that defining this font automatically defines the
6776 The font used for the text body .
6777 See section\SpecialChar ~
6779 \begin_inset LatexCommand \ref{sec:fonts}
6792 The font used for the label.
6793 See section\SpecialChar ~
6795 \begin_inset LatexCommand \ref{sec:fonts}
6805 Preamble\SpecialChar \ldots{}
6809 A set of macro definitions that will be output at the beginning of the
6810 LaTeX files when the layout is used.
6811 Use this to define the macros needed by this particular layout.
6820 the name of a style which preamble should be output
6824 the one mentionned above.
6825 This allows to ensure some ordering of the preamble snippets when macros
6826 definitions depend on one another
6832 Note that, besides that functionality, there is no way to ensure any ordering
6834 The ordering that you see in a given version of LyX may change without
6835 warning in later versions).
6858 \begin_inset LatexCommand \label{sec:floats}
6862 Since version 1.3.0 of LyX, it is necessary to define the floats (
6870 , \SpecialChar \ldots{}
6871 ) in the text class itself.
6872 If you are looking here to learn how to upgrade an existing text class,
6873 it will probably turn out that all you have to do is to add
6879 at a reasonable location of the text class.
6885 Don't forget to also have a look at counters in next section.
6888 If you want to implement a text class that proposes some other float types
6889 (like the AGU class bundled with LyX), the information below will hopefully
6904 \begin_inset Quotes erd
6908 \begin_inset Quotes erd
6912 \begin_inset Quotes eld
6916 \begin_inset Quotes erd
6919 of the new class of floats, like program or algorithm.
6920 After the appropriate
6952 \begin_inset Quotes erd
6956 \begin_inset Quotes erd
6959 ] The string that will be used in the menus and also for the caption.
6982 if the float is already defined by the documentclass.
6987 , the float will be defined using the LaTeX package
7005 \begin_inset Quotes erd
7009 \begin_inset Quotes erd
7012 ] This (optional) argument determines whether floats of this class will
7013 be numbered within some sectional unit of the document.
7014 For example, if within is equal to
7018 , the floats will be numbered within chapters.
7033 \begin_inset Quotes erd
7037 \begin_inset Quotes erd
7040 ] The style used when defining the float using
7060 \begin_inset Quotes erd
7064 \begin_inset Quotes erd
7067 ] The default placement for the given class of floats.
7068 They are like in standard LaTeX:
7084 for top, bottom, page, and here, respectively.
7090 Note that the order of these letters in the string is irrelevant, like in
7094 On top of that there is a new type,
7098 , which does not really correspond to a float, since it means: put it
7099 \begin_inset Quotes eld
7103 \begin_inset Quotes erd
7107 Note, however that the
7111 specifier is special and, because of implementation details cannot be used
7112 in non-builtin float types.
7113 If you do not understand what this means, just use
7131 \begin_inset Quotes erd
7135 \begin_inset Quotes erd
7138 ] The file name extension of an auxiliary file for the list of figures (or
7140 LaTeX writes the captions to this file.
7154 \begin_inset Quotes erd
7158 \begin_inset Quotes erd
7161 ] The heading used for the list of floats.
7168 \begin_inset LatexCommand \label{sec:counter}
7172 Since version 1.3.0 of LyX, it is necessary to define the counters (
7180 , \SpecialChar \ldots{}
7181 ) in the text class itself.
7182 If you are looking here to learn how to upgrade an existing text class,
7183 it will probably turn out that all you have to do is to add
7186 Input stdcounters.inc
7189 The definition of counters if presently a bit primitive in LyX, since many
7190 things are still hardcoded.
7191 The following two parameters can be used:
7205 \begin_inset Quotes erd
7209 \begin_inset Quotes erd
7212 ] The name of the counter
7226 \begin_inset Quotes erd
7230 \begin_inset Quotes erd
7233 ] If this is set to the name of another counter, the present counter will
7234 be reset everytime the other one is increased (is that unclear enough?).
7241 \begin_inset LatexCommand \label{sec:fonts}
7245 A font description looks like that:
7263 and the following commands are available:
7309 , Italic, SmallCaps, Slanted
7326 , large, larger, largest, huge, giant
7343 , black, white, red, green, blue, cyan, magenta, yellow
7349 \begin_inset LatexCommand \label{sec:templates}
7356 Templates are created just like usual documents.
7357 The only difference is that usual documents contain all possible settings,
7358 including the fontscheme and the papersize.
7359 Usually a user doesn't want a template to overwrite his defaults in these
7361 For that reason, the designer of a template should remove the corresponding
7374 from the template LyX file.
7375 This can be done with any simple text-editor, for example
7387 Put the edited template files you create in
7391 , copy the ones you use from the global template directory in
7395 to the same place, and redefine the template path in the
7400 dit\SpecialChar \menuseparator
7419 Note that there is a template which has a particular meaning:
7424 This template is loaded everytime you create a new document with
7431 \SpecialChar \menuseparator
7439 in order to provide useful defaults.
7440 To create this template from inside LyX, all you have to do is to open
7441 a document with the correct settings, and use the
7447 e as Document Defaults
7452 Including External Material
7458 One often requested feature from LyX users is to be able to interface LyX
7459 with XFig, Dia, or other similar applications that specialize in producing
7460 a certain kind of diagram, figure, schematic or whatever material might
7461 be relevant to include in your document.
7462 Previously, it was only possible to include boring, static, fixed images
7463 in LyX documents with the graphics feature, but there are several limitations
7464 attached to this approach:
7467 If you want to change the figure, you have to invoke an external program
7471 LyX does not notice that the referenced files change, so the on-screen display
7472 can fast become obsolete, and this is aggravated by the lack of a means
7473 of updating the display
7476 The graphics stuff does not provide any mechanisms for coping with different
7477 exported formats such as DocBook, HTML or raw Ascii
7480 The external material facility attempts to solve all of these problems
7486 Even if the graphics facility can't solve all problems, it is still valuable
7487 because it does provide in-line preview of the graphics, and supports advanced
7488 geometric transformations with a comfortable user interface.
7492 It does this by offering a general method to interface LyX to external
7494 Instead of introducing a long list of different constructs tailored for
7495 each specific application, we chose to sacrifice the in-line displaying
7496 of the included material in order to provide a general construct to cover
7497 a wide range of applications.
7498 The result is the external material construct.
7499 External material presents itself in the document simply as a button, but
7500 don't let this fool you.
7501 When you click on it, a dialog will appear that allows you to chose exactly
7502 what material to include, and in the following sections you will learn
7503 that this is indeed a powerful mechanism that can solve all of the above
7510 The external material feature is based on the concept of a
7515 A template is a specification of how LyX should interface with a certain
7517 As bundled, LyX comes with predefined templates for XFig figures, Dia diagrams,
7518 various raster format images, gnuplot, and more.
7519 You can check the actual list by using the
7521 Insert\SpecialChar \menuseparator
7530 Furthermore, it is possible to roll your own template to support a specific
7532 Later we'll describe in more detail what is involved, and hopefully you
7533 will submit all the templates you create so we can include them in a later
7537 Another basic idea of the external material feature is to distinguish between
7538 the original file that serves as a base for final material and the produced
7539 file that is included in your exported or printed document.
7540 For example, consider the case of a figure produced with XFig.
7541 The XFig application itself works on an original file with the
7546 Within XFig, you create and change your figure, and when you are done,
7552 When you want to include the figure in your document, you invoke
7556 in order to create a PostScript file that can readily be included in your
7562 file is the original file, and the PostScript file is the produced file.
7565 This distinction is important in order to allow updating of the material
7566 while you are in the process of writing the document.
7567 Furthermore, it provides us with the flexibility that is needed to support
7568 multiple export formats.
7569 For instance, in the case of an Ascii resulting file, it is not exactly
7570 an award-winning idea to include the figure as raw PostScript.
7571 Instead, you'd either prefer to just include a reference to the figure,
7572 or try to invoke some graphics to Ascii converter to make the final result
7573 look similar to the real graphics.
7574 The external material management allows you to do this, because it is parameter
7575 ized on the different export formats that LyX supports.
7578 Besides supporting the production of different products according to the
7579 exported format, it supports tight integration with editing and viewing
7581 In the case of an XFig figure, you are able to invoke
7585 on the original file with a single click from within the external material
7586 dialog in LyX, and also preview the produced PostScript file with
7591 No more fiddling around with the command line and/or file browsers to locate
7592 and manipulate the original or produced files.
7593 In this way, you are finally able to take full advantage of the many different
7594 applications that are relevant to use when you write your documents, and
7595 ultimately be more productive.
7598 So, all in all, LyX has information about a number of different programs
7599 to use behind the scenes in order to realize all of this machinery.
7600 This information, in fact, is exactly what is contained in the templates.
7601 To each template, there is associated a list of command lines that are
7602 used to invoke applications, convert the original file to the produced
7604 This mechanism allows the advanced user to extend the capabilities of LyX
7605 without fiddling with the source code.
7606 It requires some footwork to define all the different commands and flags,
7607 but luckily, the LyX team did all the hard work and specified these for
7611 But before the trees grow into the skies, we have to admit that we did take
7613 Since you can produce many different kinds of files to go with each exported
7614 format, one could also expect that it would be possible to preview each
7616 The LyX team decided against this in order to keep the user interface simple.
7617 Instead of providing a button for each exported file format, we decided
7618 to introduce the concept of the primary file format and just have one button.
7628 in the external material dialog, you will get a view of the produced file
7629 in the primary file format.
7630 And the primary file format is specified by your document class.
7631 For most document classes, the primary file format is LaTeX, but for the
7632 DocBook document classes, the primary file format is DocBook.
7633 So, when you view the produced file, keep in mind that it will only be
7634 a preview of what the main result will be.
7635 If you want to see how other exported formats turn out, you have to export
7636 them and preview them by hand.
7639 The external material dialog
7642 You insert external material from the
7650 When you do this, a button is inserted into your document, and the external
7651 material dialog is shown.
7652 This dialog allows you to describe exactly what material should be included,
7653 and also how it should be included.
7654 Furthermore, it provides access to the external applications to either
7655 view, edit or produce the material that is used in the resulting file.
7658 At the top of this dialog, there is a drop-down list where you can chose
7659 which template should be used.
7660 Just below the template drop-down, there's a text area with a short blurb
7661 about the chosen template that should help you use it.
7662 Most often, it will provide a short description of the template, and a
7663 few hints on how to parameterize the use of it.
7664 Further down, you'll find a filename input field along with a
7665 \begin_inset Quotes eld
7669 \begin_inset Quotes erd
7672 button that allows you to chose which file should be included with the
7673 standard file browser.
7674 Thus this field specifies the original file.
7675 Since the produced file is automatically generated when needed, there is
7676 no need to give access to it in the user interface.
7679 At the bottom of the dialog, you'll find a general input box called
7684 This box is generally used to parameterize the specific template.
7685 The specific use should be covered in the help blurb associated with the
7686 template, but it typically allows you to define variations on how the produced
7687 file should be generated.
7690 At the right side of the dialog, you'll find three buttons:
7718 These in turn allow you to edit your original file with the appropriate
7719 editing application, view the produced file as included in the primary
7720 format document, and finally force an update of the resulting material
7721 in the primary format.
7731 button will be disabled, because most templates are configured to automatically
7732 update the produced file when needed.
7733 In those cases, there is no need to force the production of a new produced
7735 However, some templates are configured to not be automatically producing
7736 the residual product, because the cost of producing the produced file might
7737 be so large that it would be a pain to do it all the time.
7738 Those types are known as
7743 In those cases, you can use the button to force the production of the produced
7744 file exactly when you need it, and thus control the amount of work that
7750 responsibility to do this to keep the produced files current at all times:
7751 before printing, before exporting, before viewing, etc.
7752 At some time in the future, it might be possible that LyX will help you
7753 with this task.Any changes in the template, filename or parameters are actually
7754 applied whenever you press
7782 In this section, we should include some examples of use of the external
7784 Those examples could include:
7787 External raster images
7790 External XFig figures
7799 The use of makefiles
7802 Recursive external LyX templates
7805 The external template configuration file
7808 It is relatively easy to add custom external template definitions to LyX.
7809 However, be aware this doing this in an careless manner most probably
7813 introduce an easily exploitable security hole.
7814 So before you do this, please read the discussion about security which
7818 Having said that, we encourage you to submit any interesting templates that
7823 The external templates are defined in the
7825 lib/external_templates
7828 You can place your own version in
7830 .lyx/external_templates
7833 At some point in time, hopefully somebody will document the template contents,
7834 and the syntax used to define your templates.
7837 The substitution mechanism
7840 When the external material facility invokes an external program, it is done
7841 on the basis of a command defined in the template configuration file.
7842 These commands can contain various macros that are expanded before execution.
7843 Execution always take place in the directory of the containing document.
7846 Also, whenever external material is to be displayed, the name will be produced
7847 by the substitution mechanism.
7850 The available macros are the following:
7853 $$FName The filename of the file specified in the external material dialog.
7856 $$Basename The filename without the extension.
7859 $$Tempname A name and full path to a temporary file which will be automatically
7860 deleted whenever the containing document is closed, or the external material
7865 \begin_inset Quotes eld
7869 \begin_inset Quotes erd
7872 ) This macro will expand to the contents of the file with the name
7879 $$Sysdir This macro will expand to the absolute path of the system directory.
7880 This is typically used to point to the various helper scripts that are
7884 In addition to these, the facility will expand general environment variables
7895 The external material feature interfaces with a lot of external programs
7896 and does so automatically, so we have to consider the security implications
7898 In particular, since you have the option of including your own filenames
7899 and/or parameter strings and those are expanded into a command, it seems
7900 that it would be possible to create a malicious document which executes
7901 arbitrary commands when a user views or prints the document.
7902 This is something we definately want to avoid.
7905 However, since the external program commands are specified in the template
7906 configuration file only, there are no security issues if LyX is properly
7907 configured with safe templates only.
7908 This is so because the external programs are invoked with the
7912 -system call rather than the
7916 system-call, so it's not possible to execute arbitrary commands from the
7917 filename or parameter section via the shell.
7920 This also implies that you are restricted in what command strings you can
7921 use in the external material templates.
7922 In particular, pipes and redirection are not readily available.
7923 This has to be so if LyX should remain safe.
7924 If you want to use some of the shell features, you should write a safe
7925 script to do this in a controlled manner, and then invoke the script from
7931 directory of the LyX installation, you can find a safe wrapper script
7933 general_command_wrapper.py
7935 that supports redirection of input and output.
7936 That can serve as an example for how to write safe template scripts.
7937 For a more advanced example that uses
7941 and friends, take a look at the
7948 It is possible to design a template that interacts directly with the shell,
7949 but since this would allow a malicious user to execute arbitrary commands
7950 by writing clever filenames and/or parameters, we generally recommend that
7951 you only use safe scripts that work with the
7955 system call in a controlled manner.
7956 Of course, for use in a controlled environment, it can be tempting to just
7957 fall back to use ordinary shell scripts.
7958 If you do so, be aware that you
7962 provide an easily exploitable security hole in your system.
7963 Of course it stands to reason that such unsafe templates will never be
7964 included in the standard LyX distribution, although we do encourage people
7965 to submit new templates in the open source tradition.
7966 But LyX as shipped from the official distribution channels will never have
7970 Including external material provides a lot of power, and you have to be
7971 careful not to introduce security hazards with this power.
7972 A subtle error in a single line in an innocent looking script can open
7973 the door to huge security problems.
7974 So if you do not fully understand the issues, we recommend that you consult
7975 a knowledgable security professional or the LyX development team if you
7976 have any questions about whether a given template is safe or not.
7977 And do this before you use it in an uncontrolled environment.
7986 The LyX server is a method implemented in LyX that will enable other programs
7987 to talk to LyX, invoke LyX commands, and retrieve information about the
7989 This is only intended for advanced users, but they should find it useful.
7992 Starting the LyX Server
7995 The LyX server works through the use of a pair of named pipes.
7996 These are usually located in your home directory and have the names
7997 \begin_inset Quotes eld
8005 \begin_inset Quotes erd
8009 \begin_inset Quotes eld
8017 \begin_inset Quotes erd
8021 External programs write into
8025 and read back data from
8030 The stem of the pipe names can be defined in the
8035 ools\SpecialChar \menuseparator
8044 "/home/myhome/.lyxpipe"
8057 ' to create the pipes.
8058 The above setting also has the effect of activating the LyX server.
8059 If one of the pipes already exists, LyX will assume that another LyX process
8060 is already running and will not start the server.
8061 To have several LyX processes with servers at the same time, you have to
8062 change the configuration between the start of the programs.
8065 If you are developing a client program, you might find it useful to enable
8066 debugging information from the LyX server.
8067 Do this by starting LyX as
8072 Warning: if LyX crashes, it may not manage to remove the pipes; in this
8073 case you must remove them manually.
8074 If LyX starts and the pipes exist already, it will not start any server.
8077 Other than this, there are a few points to consider:
8080 Both server and clients must run on UNIX or OS/2 machines.
8081 Communications between LyX on UNIX and clients on OS/2 or vice versa is
8082 not possible right now.
8085 On OS/2, only one client can connect to LyXServer at a time.
8088 On OS/2, clients must open inpipe with
8095 You can find a complete example client written in C in the source distribution
8098 development/server_monitor.c
8103 Normal communication
8106 To issue a LyX call, the client writes a line of ASCII text into the input
8108 This line has the following format:
8128 is a name that the client can choose arbitrarily.
8129 Its only use is that LyX will echo it if it sends an answer - so a client
8130 can dispatch results from different requesters.
8137 is the function you want LyX to perform.
8138 It is the same as the commands you'd use in the minibuffer.
8145 is an optional argument which is meaningful only to some functions (for
8147 \begin_inset Quotes eld
8151 \begin_inset Quotes erd
8154 which will insert the argument as text at the cursor position.)
8157 The answer from LyX will arrive in the output pipe and be of the form
8181 are just echoed from the command request, while
8185 is more or less useful information filled according to how the command
8186 execution worked out.
8187 Some commands will return information about the internal state of LyX,
8189 \begin_inset Quotes eld
8193 \begin_inset Quotes erd
8196 , while other will return an empty data-response.
8197 This means that the command execution went fine.
8200 In case of errors, the response from LyX will have this form
8220 should contain an explanation of why the command failed.
8226 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
8229 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
8231 read a <~/.lyxpipe.out
8239 LyX can notify clients of events going on asynchronously.
8240 Currently it will only do this if the user binds a key sequence with the
8242 \begin_inset Quotes eld
8246 \begin_inset Quotes erd
8250 The format of the string LyX sends is as follows:
8265 is the printed representation of the key sequence that was actually typed
8269 This mechanism can be used to extend LyX's command set and implement macros:
8270 bind some key sequence to
8271 \begin_inset Quotes eld
8275 \begin_inset Quotes erd
8278 , start a client that listens on the out pipe, dispatches the command according
8279 to the sequence and starts a function that may use LyX calls and LyX requests
8280 to issue a command or a series of commands to LyX.
8283 The simple LyX Server Protocol
8286 LyX implements a simple protocol that can be used for session management.
8287 All messages are of the form
8304 \begin_inset Quotes eld
8308 \begin_inset Quotes erd
8312 \begin_inset Quotes eld
8316 \begin_inset Quotes erd
8321 \begin_inset Quotes eld
8325 \begin_inset Quotes erd
8328 is received from a client, LyX will report back to inform the client that
8329 it's listening to it's messages, while
8330 \begin_inset Quotes eld
8334 \begin_inset Quotes erd
8337 sent from LyX will inform clients that LyX is closing.
8343 This appendix is a huge cross-reference to all the English language keybindings.
8344 Originally, we simply wanted to list all of the key bindings followed by
8345 the function it's bound to.
8346 That way, a user can look up a key to find out what it does.
8347 We then decided, what the hey, why not include the default toolbar and
8349 Please note this section is likely to be very out of date.
8352 The form is really self-explanatory, but here are a few tips: all entries
8353 are arranged roughly alphabetically for a given modifier (
8362 For the general keyboard layout, simpler prefixes precede the more complex
8372 All entries were gleaned from the default user interface and binding files
8373 located in the directories
8375 \SpecialChar \ldots{}
8380 \SpecialChar \ldots{}
8383 ; they should be treated as the final word on the bindings.
8386 As a final note, be aware that some window managers (such as FVWM) take
8387 control of some of the function keys or motion keys.
8392 is listed here as generating
8396 , but FVWM grabs it and uses it to change virtual desktops instead.
8397 Very annoying unless you instruct your window manager to stop intercepting
8455 Icon "footnote-insert"
8458 Icon "marginpar-insert"
8467 Icon "figure-insert"
8470 Icon "dialog-tabular-insert"
8481 \labelwidthstring 00.00.0000
8490 \labelwidthstring 00.00.0000
8501 \labelwidthstring 00.00.0000
8512 \labelwidthstring 00.00.0000
8525 \labelwidthstring 00.00.0000
8534 \labelwidthstring 00.00.0000
8547 \labelwidthstring 00.00.0000
8556 \labelwidthstring 00.00.0000
8567 \labelwidthstring 00.00.0000
8578 \labelwidthstring 00.00.0000
8589 \labelwidthstring 00.00.0000
8598 \labelwidthstring 00.00.0000
8610 \labelwidthstring 00.00.0000
8618 \labelwidthstring 00.00.0000
8626 \labelwidthstring 00.00.0000
8634 \labelwidthstring 00.00.0000
8642 \labelwidthstring 00.00.0000
8650 \labelwidthstring 00.00.0000
8659 \labelwidthstring 00.00.0000
8671 \labelwidthstring 00.00.0000
8682 \labelwidthstring 00.00.0000
8693 \labelwidthstring 00.00.0000
8704 \labelwidthstring 00.00.0000
8715 \labelwidthstring 00.00.0000
8726 \labelwidthstring 00.00.0000
8737 \labelwidthstring 00.00.0000
8751 \labelwidthstring 00.00.0000
8759 tabular-feature append-row
8761 \labelwidthstring 00.00.0000
8769 tabular-feature toggle-line-bottom
8771 \labelwidthstring 00.00.0000
8779 tabular-feature align-center
8781 \labelwidthstring 00.00.0000
8789 tabular-feature delete-column
8791 \labelwidthstring 00.00.0000
8799 tabular-feature align-left
8801 \labelwidthstring 00.00.0000
8809 tabular-feature align-right
8811 \labelwidthstring 00.00.0000
8819 tabular-feature toggle-line-left
8821 \labelwidthstring 00.00.0000
8829 tabular-feature multicolumn
8831 \labelwidthstring 00.00.0000
8839 tabular-feature valign-center
8841 \labelwidthstring 00.00.0000
8849 tabular-feature valign-top
8851 \labelwidthstring 00.00.0000
8859 tabular-feature toggle-line-right
8861 \labelwidthstring 00.00.0000
8869 tabular-feature toggle-line-top
8871 \labelwidthstring 00.00.0000
8879 tabular-feature append-column
8881 \labelwidthstring 00.00.0000
8889 tabular-feature valign-bottom
8891 \labelwidthstring 00.00.0000
8899 tabular-feature delete-row
8902 \labelwidthstring 00.00.0000
8914 \labelwidthstring 00.00.0000
8920 floats-operate openfoot
8922 \labelwidthstring 00.00.0000
8928 floats-operate closefoot
8930 \labelwidthstring 00.00.0000
8936 floats-operate openfig
8938 \labelwidthstring 00.00.0000
8946 \labelwidthstring 00.00.0000
8954 \labelwidthstring 00.00.0000
8960 floats-operate closefig
8963 \labelwidthstring 00.00.0000
8974 \labelwidthstring 00.00.0000
8987 \labelwidthstring 00.00.0000
8998 \labelwidthstring 00.00.0000
9009 \labelwidthstring 00.00.0000
9022 \labelwidthstring 00.00.0000
9031 \labelwidthstring 00.00.0000
9043 \labelwidthstring 00.00.0000
9051 primary-selection-paste
9053 \labelwidthstring 00.00.0000
9061 primary-selection-paste paragraph
9067 \labelwidthstring 00.00.0000
9081 \labelwidthstring 00.00.0000
9089 buffer-float-insert algorithm
9091 \labelwidthstring 00.00.0000
9099 buffer-float-insert wide-tab
9101 \labelwidthstring 00.00.0000
9109 buffer-float-insert figure
9111 \labelwidthstring 00.00.0000
9119 buffer-float-insert table
9121 \labelwidthstring 00.00.0000
9129 buffer-float-insert wide-fig
9132 \labelwidthstring 00.00.0000
9141 dialog-tabular-insert
9143 \labelwidthstring 00.00.0000
9154 \labelwidthstring 00.00.0000
9165 \labelwidthstring 00.00.0000
9176 \labelwidthstring 00.00.0000
9187 \labelwidthstring 00.00.0000
9198 \labelwidthstring 00.00.0000
9209 \labelwidthstring 00.00.0000
9220 \labelwidthstring 00.00.0000
9231 \labelwidthstring 00.00.0000
9242 \labelwidthstring 00.00.0000
9253 \labelwidthstring 00.00.0000
9267 \labelwidthstring 00.00.0000
9277 \labelwidthstring 00.00.0000
9287 \labelwidthstring 00.00.0000
9297 \labelwidthstring 00.00.0000
9307 \labelwidthstring 00.00.0000
9317 \labelwidthstring 00.00.0000
9328 \labelwidthstring 00.00.0000
9339 \labelwidthstring 00.00.0000
9353 \labelwidthstring 00.00.0000
9361 protected-space-insert
9363 \labelwidthstring 00.00.0000
9371 end-of-sentence-period-insert
9373 \labelwidthstring 00.00.0000
9383 \labelwidthstring 00.00.0000
9393 \labelwidthstring 00.00.0000
9403 \labelwidthstring 00.00.0000
9411 menu-separator-insert
9413 \labelwidthstring 00.00.0000
9421 hyphenation-point-insert
9423 \labelwidthstring 00.00.0000
9433 \labelwidthstring 00.00.0000
9441 command-sequence math-insert ^;math-mode;
9443 \labelwidthstring 00.00.0000
9451 command-sequence math-insert _;math-mode;
9454 \labelwidthstring 00.00.0000
9468 \labelwidthstring 00.00.0000
9476 file-insert-ascii lines
9478 \labelwidthstring 00.00.0000
9486 file-insert-ascii paragraphs
9488 \labelwidthstring 00.00.0000
9499 \labelwidthstring 00.00.0000
9510 \labelwidthstring 00.00.0000
9521 \labelwidthstring 00.00.0000
9535 \labelwidthstring 00.00.0000
9546 \labelwidthstring 00.00.0000
9557 \labelwidthstring 00.00.0000
9568 \labelwidthstring 00.00.0000
9579 \labelwidthstring 00.00.0000
9590 \labelwidthstring 00.00.0000
9601 \labelwidthstring 00.00.0000
9612 \labelwidthstring 00.00.0000
9623 \labelwidthstring 00.00.0000
9634 \labelwidthstring 00.00.0000
9645 \labelwidthstring 00.00.0000
9656 \labelwidthstring 00.00.0000
9666 \layout Subsubsection
9670 ayout\SpecialChar \menuseparator
9675 \labelwidthstring 00.00.0000
9684 \labelwidthstring 00.00.0000
9693 \labelwidthstring 00.00.0000
9702 \labelwidthstring 00.00.0000
9711 \labelwidthstring 00.00.0000
9722 \labelwidthstring 00.00.0000
9731 \labelwidthstring 00.00.0000
9740 \labelwidthstring 00.00.0000
9749 \labelwidthstring 00.00.0000
9758 \labelwidthstring 00.00.0000
9767 \labelwidthstring 00.00.0000
9776 \labelwidthstring 00.00.0000
9785 \labelwidthstring 00.00.0000
9794 \labelwidthstring 00.00.0000
9803 \labelwidthstring 00.00.0000
9814 \labelwidthstring 00.00.0000
9825 \labelwidthstring 00.00.0000
9836 \labelwidthstring 00.00.0000
9847 \labelwidthstring 00.00.0000
9856 \labelwidthstring 00.00.0000
9867 \labelwidthstring 00.00.0000
9878 \labelwidthstring 00.00.0000
9887 \labelwidthstring 00.00.0000
9898 \labelwidthstring 00.00.0000
9909 \labelwidthstring 00.00.0000
9920 \labelwidthstring 00.00.0000
9931 \labelwidthstring 00.00.0000
9940 \labelwidthstring 00.00.0000
9949 \labelwidthstring 00.00.0000
9960 \labelwidthstring 00.00.0000
9971 \labelwidthstring 00.00.0000
9982 \labelwidthstring 00.00.0000
9991 \labelwidthstring 00.00.0000
10012 \labelwidthstring 00.00.0000
10023 \labelwidthstring 00.00.0000
10034 \labelwidthstring 00.00.0000
10045 \labelwidthstring 00.00.0000
10056 \labelwidthstring 00.00.0000
10067 \labelwidthstring 00.00.0000
10076 layout ShortFoilhead
10078 \labelwidthstring 00.00.0000
10089 \labelwidthstring 00.00.0000
10100 \labelwidthstring 00.00.0000
10111 \labelwidthstring 00.00.0000
10122 \labelwidthstring 00.00.0000
10131 layout ShortRotatefoilhead
10133 \labelwidthstring 00.00.0000
10144 \labelwidthstring 00.00.0000
10155 \labelwidthstring 00.00.0000
10166 \labelwidthstring 00.00.0000
10175 drop-layouts-choice
10177 \labelwidthstring 00.00.0000
10191 \labelwidthstring 00.00.0000
10205 \labelwidthstring 00.00.0000
10216 \labelwidthstring 00.00.0000
10227 \labelwidthstring 00.00.0000
10236 layout Subsubsection
10238 \labelwidthstring 00.00.0000
10249 \labelwidthstring 00.00.0000
10258 layout Subparagraph
10260 \labelwidthstring 00.00.0000
10265 asterisk\SpecialChar ~
10272 \labelwidthstring 00.00.0000
10277 asterisk\SpecialChar ~
10284 \labelwidthstring 00.00.0000
10289 asterisk\SpecialChar ~
10296 \labelwidthstring 00.00.0000
10301 asterisk\SpecialChar ~
10308 \labelwidthstring 00.00.0000
10313 asterisk\SpecialChar ~
10318 layout Subsubsection*
10320 \labelwidthstring 00.00.0000
10325 asterisk\SpecialChar ~
10332 \labelwidthstring 00.00.0000
10337 asterisk\SpecialChar ~
10342 layout Subparagraph*
10344 \labelwidthstring 00.00.0000
10355 \labelwidthstring 00.00.0000
10364 layout Bibliography
10366 \labelwidthstring 00.00.0000
10377 \labelwidthstring 00.00.0000
10388 \labelwidthstring 00.00.0000
10399 \labelwidthstring 00.00.0000
10410 \labelwidthstring 00.00.0000
10421 \labelwidthstring 00.00.0000
10430 layout Rotatefoilhead
10432 \labelwidthstring 00.00.0000
10441 layout RightAddress
10443 \labelwidthstring 00.00.0000
10454 \labelwidthstring 00.00.0000
10465 \labelwidthstring 00.00.0000
10476 \labelwidthstring 00.00.0000
10488 These ones are kept for backwards compatibility, but only make sense on
10491 \labelwidthstring 00.00.0000
10502 \labelwidthstring 00.00.0000
10511 layout Subsubsection*
10513 \labelwidthstring 00.00.0000
10532 \labelwidthstring 00.00.0000
10542 \labelwidthstring 00.00.0000
10552 \labelwidthstring 00.00.0000
10562 \labelwidthstring 00.00.0000
10572 \labelwidthstring 00.00.0000
10582 \labelwidthstring 00.00.0000
10592 \labelwidthstring 00.00.0000
10600 hyphenation-point-insert
10602 \labelwidthstring 00.00.0000
10612 \labelwidthstring 00.00.0000
10620 line-delete-forward
10622 \labelwidthstring 00.00.0000
10632 \labelwidthstring 00.00.0000
10642 \labelwidthstring 00.00.0000
10652 \labelwidthstring 00.00.0000
10662 \labelwidthstring 00.00.0000
10672 \labelwidthstring 00.00.0000
10680 \labelwidthstring 00.00.0000
10690 \labelwidthstring 00.00.0000
10700 \labelwidthstring 00.00.0000
10710 \labelwidthstring 00.00.0000
10720 \labelwidthstring 00.00.0000
10730 \labelwidthstring 00.00.0000
10740 \labelwidthstring 00.00.0000
10751 \labelwidthstring 00.00.0000
10762 \labelwidthstring 00.00.0000
10773 \labelwidthstring 00.00.0000
10784 \labelwidthstring 00.00.0000
10796 \labelwidthstring 00.00.0000
10807 \labelwidthstring 00.00.0000
10818 \labelwidthstring 00.00.0000
10829 \labelwidthstring 00.00.0000
10840 \labelwidthstring 00.00.0000
10852 \labelwidthstring 00.00.0000
10863 \labelwidthstring 00.00.0000
10874 \labelwidthstring 00.00.0000
10886 \labelwidthstring 00.00.0000
10898 \labelwidthstring 00.00.0000
10910 \labelwidthstring 00.00.0000
10922 \labelwidthstring 00.00.0000
10934 \labelwidthstring 00.00.0000
10946 \labelwidthstring 00.00.0000
10957 \labelwidthstring 00.00.0000
10968 \labelwidthstring 00.00.0000
10979 \labelwidthstring 00.00.0000
10988 menu-open Documents
10990 \labelwidthstring 00.00.0000
11001 \labelwidthstring 00.00.0000
11012 \labelwidthstring 00.00.0000
11023 \labelwidthstring 00.00.0000
11034 \labelwidthstring 00.00.0000
11045 \labelwidthstring 00.00.0000
11054 buffer-toggle-read-only
11056 \labelwidthstring 00.00.0000
11067 \labelwidthstring 00.00.0000
11078 \labelwidthstring 00.00.0000
11089 \labelwidthstring 00.00.0000
11099 \labelwidthstring 00.00.0000
11109 \labelwidthstring 00.00.0000
11119 \labelwidthstring 00.00.0000
11129 \labelwidthstring 00.00.0000
11139 \labelwidthstring 00.00.0000
11149 \labelwidthstring 00.00.0000
11159 \labelwidthstring 00.00.0000
11169 \labelwidthstring 00.00.0000
11179 \labelwidthstring 00.00.0000
11189 \labelwidthstring 00.00.0000
11199 \labelwidthstring 00.00.0000
11209 \labelwidthstring 00.00.0000
11219 \labelwidthstring 00.00.0000
11229 \labelwidthstring 00.00.0000
11237 word-delete-forward
11239 \labelwidthstring 00.00.0000
11247 word-delete-backward
11249 \labelwidthstring 00.00.0000
11259 \labelwidthstring 00.00.0000
11267 end-of-sentence-period-insert
11269 \labelwidthstring 00.00.0000
11277 protected-space-insert
11279 \labelwidthstring 00.00.0000
11289 \labelwidthstring 00.00.0000
11299 \labelwidthstring 00.00.0000
11309 \labelwidthstring 00.00.0000
11319 \labelwidthstring 00.00.0000
11329 \labelwidthstring 00.00.0000
11339 \labelwidthstring 00.00.0000
11347 buffer-begin-select
11349 \labelwidthstring 00.00.0000
11359 \labelwidthstring 00.00.0000
11367 paragraph-up-select
11369 \labelwidthstring 00.00.0000
11377 paragraph-down-select
11379 \labelwidthstring 00.00.0000
11387 word-backward-select
11389 \labelwidthstring 00.00.0000
11397 word-forward-select
11399 \labelwidthstring 00.00.0000
11409 \labelwidthstring 00.00.0000
11417 word-delete-forward
11419 \labelwidthstring 00.00.0000
11429 \labelwidthstring 00.00.0000
11439 \labelwidthstring 00.00.0000
11449 \labelwidthstring 00.00.0000
11459 \labelwidthstring 00.00.0000
11467 break-paragraph-keep-layout
11469 \labelwidthstring 00.00.0000
11482 \labelwidthstring 00.00.0000
11492 \labelwidthstring 00.00.0000
11502 \labelwidthstring 00.00.0000
11512 \labelwidthstring 00.00.0000
11522 \labelwidthstring 00.00.0000
11532 \labelwidthstring 00.00.0000
11542 \labelwidthstring 00.00.0000
11552 \labelwidthstring 00.00.0000
11562 \labelwidthstring 00.00.0000
11572 \labelwidthstring 00.00.0000
11582 \labelwidthstring 00.00.0000
11592 \labelwidthstring 00.00.0000
11602 \labelwidthstring 00.00.0000
11612 \labelwidthstring 00.00.0000
11622 \labelwidthstring 00.00.0000
11632 \labelwidthstring 00.00.0000
11642 \labelwidthstring 00.00.0000
11652 \labelwidthstring 00.00.0000
11662 \labelwidthstring 00.00.0000
11672 \labelwidthstring 00.00.0000
11682 \labelwidthstring 00.00.0000
11692 \labelwidthstring 00.00.0000
11702 \labelwidthstring 00.00.0000
11710 protected-space-insert
11712 \labelwidthstring 00.00.0000
11722 \labelwidthstring 00.00.0000
11732 \labelwidthstring 00.00.0000
11742 \labelwidthstring 00.00.0000
11750 buffer-new-template
11752 \labelwidthstring 00.00.0000
11762 \labelwidthstring 00.00.0000
11772 \labelwidthstring 00.00.0000
11782 \labelwidthstring 00.00.0000
11792 \labelwidthstring 00.00.0000
11802 \labelwidthstring 00.00.0000
11812 \labelwidthstring 00.00.0000
11822 \labelwidthstring 00.00.0000
11830 end-of-sentence-period-insert
11832 \labelwidthstring 00.00.0000
11842 \labelwidthstring 00.00.0000
11852 \labelwidthstring 00.00.0000
11860 hyphenation-point-insert
11862 \labelwidthstring 00.00.0000
11872 \labelwidthstring 00.00.0000
11880 protected-space-insert
11882 \labelwidthstring 00.00.0000
11892 \labelwidthstring 00.00.0000
11902 \labelwidthstring 00.00.0000
11912 \labelwidthstring 00.00.0000
11922 \labelwidthstring 00.00.0000
11932 \labelwidthstring 00.00.0000
11942 \labelwidthstring 00.00.0000
11952 \labelwidthstring 00.00.0000
11962 \labelwidthstring 00.00.0000
11972 \labelwidthstring 00.00.0000
11982 \labelwidthstring 00.00.0000
11992 \labelwidthstring 00.00.0000
12002 \labelwidthstring 00.00.0000
12012 \labelwidthstring 00.00.0000
12022 \labelwidthstring 00.00.0000
12032 \labelwidthstring 00.00.0000
12040 word-delete-forward
12042 \labelwidthstring 00.00.0000
12050 word-delete-backward
12052 \labelwidthstring 00.00.0000
12062 \labelwidthstring 00.00.0000
12072 \labelwidthstring 00.00.0000
12082 \labelwidthstring 00.00.0000
12092 \labelwidthstring 00.00.0000
12100 paragraph-down-select
12102 \labelwidthstring 00.00.0000
12112 \labelwidthstring 00.00.0000
12120 buffer-begin-select
12122 \labelwidthstring 00.00.0000
12130 word-backward-select
12132 \labelwidthstring 00.00.0000
12140 word-forward-select
12142 \labelwidthstring 00.00.0000
12150 paragraph-up-select
12152 \labelwidthstring 00.00.0000
12162 \labelwidthstring 00.00.0000
12170 break-paragraph-keep-layout
12172 \labelwidthstring 00.00.0000
12182 \labelwidthstring 00.00.0000
12192 \labelwidthstring 00.00.0000
12202 \labelwidthstring 00.00.0000
12212 \labelwidthstring 00.00.0000
12222 \labelwidthstring 00.00.0000
12230 \labelwidthstring 00.00.0000
12240 \labelwidthstring 00.00.0000
12250 \labelwidthstring 00.00.0000
12260 \labelwidthstring 00.00.0000
12270 \labelwidthstring 00.00.0000
12286 These are LyX keyboard definitions for mathematics, similar to those of
12290 The bindings file and the present documentation were prepared by Serge Winitzki
12291 with assistance from Jean-Marc Lasgouttes.
12292 Version 1.3, for LyX 1.2.x and 1.3.x.
12295 These definitions make it a lot easier to type equations without using the
12296 mouse, especially for people familiar with Scientific Word.
12297 The standard LyX bindings such as
12308 Tip: to find the "LyX bind name" for a key, look at the status bar after
12309 typing some non-existent key combination.
12311 to find how "Ctrl-&" is referenced, press Ctrl-S and then Ctrl-&: the status
12312 bar shows "C-s S-C-ampersand." (This does not work in LyX 1.3.0!)
12314 \labelwidthstring 00.00.0000
12324 -- Copy, cut, paste is as in Sciword,
12338 \labelwidthstring 00.00.0000
12348 -- Display equation toggle: type
12352 to insert a displayed formula (
12357 \begin_inset Quotes eld
12361 \begin_inset Quotes erd
12369 in a displayed formula to convert it back to an inline formula.
12371 \labelwidthstring 00.00.0000
12387 to insert a fraction (
12392 \begin_inset Quotes eld
12396 \begin_inset Quotes erd
12400 You can also select an expression and type
12404 to convert it to the numerator of a fraction.
12413 end of the denominator will delete the numerator and convert the denominator
12416 \labelwidthstring 00.00.0000
12429 \begin_inset Formula $\int$
12437 \begin_inset Quotes eld
12441 \begin_inset Quotes erd
12446 \labelwidthstring 00.00.0000
12454 line-delete-forward
12456 -- Emacs-like binding: delete forward of cursor to end of line.
12458 \labelwidthstring 00.00.0000
12468 -- A text/math toggle (
12473 \begin_inset Quotes eld
12477 \begin_inset Quotes erd
12480 ): switches to math in text mode, and also inserts roman text in math mode.
12490 \begin_inset Quotes eld
12494 \begin_inset Quotes erd
12499 \labelwidthstring 00.00.0000
12509 -- Add/remove numbering in a single equation.
12511 \labelwidthstring 00.00.0000
12521 -- Add/remove numbering at a line in equation arrays.
12524 The above commands are toggles that control the numbering of equations (
12529 \begin_inset Quotes eld
12533 \begin_inset Quotes erd
12537 Note: when deleting a number in a labeled eqnarray, the label is not really
12538 removed (the TeX code becomes
12539 \begin_inset Quotes eld
12551 \begin_inset Quotes erd
12554 ) and this generates a (harmless) LaTeX warning.
12556 \labelwidthstring 00.00.0000
12566 -- Open a new document.
12569 \labelwidthstring 00.00.0000
12579 -- Insert a quote character " (
12584 \begin_inset Quotes eld
12588 \begin_inset Quotes erd
12593 \begin_inset Quotes eld
12597 \begin_inset Quotes erd
12600 double quote character that you get by default.
12602 \labelwidthstring 00.00.0000
12614 -- Square root sign
12615 \begin_inset Formula $\sqrt{x}$
12623 \begin_inset Quotes eld
12627 \begin_inset Quotes erd
12632 \labelwidthstring 00.00.0000
12645 \begin_inset Formula $\sqrt[n]{x}$
12650 \labelwidthstring 00.00.0000
12660 -- Another binding for a switch between the text and the math mode (
12665 \begin_inset Quotes eld
12669 \begin_inset Quotes erd
12673 Note that the roman text inserted in math mode is special.
12675 \labelwidthstring 00.00.0000
12689 the selected text (text mode only, use things like
12703 \labelwidthstring 00.00.0000
12713 -- W*ndows heritage.
12715 \labelwidthstring 00.00.0000
12725 -- Close the current document (again, a W*ndows heritage).
12727 \labelwidthstring 00.00.0000
12737 \labelwidthstring 00.00.0000
12747 \labelwidthstring 00.00.0000
12758 \begin_inset Quotes eld
12762 \begin_inset Quotes erd
12766 \begin_inset Quotes eld
12770 \begin_inset Quotes erd
12776 Bracket delimiters: press
12780 -<bracket key> to insert a matching pair of delimiters.
12785 inserts a pair of parentheses
12786 \begin_inset Formula $\left[\right]$
12794 does the same thing.) It will switch to math mode if needed.
12795 The supported characters are ( [ { < |.
12796 It is the same to press the right or the left bracket.
12797 The corresponding delimiters are
12798 \begin_inset Formula $\left(\right)$
12802 \begin_inset Formula $\left[\right]$
12806 \begin_inset Formula $\left\{ \right\} $
12810 \begin_inset Formula $\left\langle \right\rangle $
12814 \begin_inset Formula $\left|\right|$
12819 \begin_inset Quotes eld
12823 \begin_inset Quotes erd
12826 and resize with their contents.
12827 Use Math Panel to get other or non-matching delimiters.
12828 Press backspace on the
12832 delimiter to remove both
12833 \begin_inset Quotes eld
12837 \begin_inset Quotes erd
12840 delimiters without removing their contents.
12842 \labelwidthstring 00.00.0000
12852 -- for convenience, pressing
12864 \labelwidthstring 00.00.0000
12874 \labelwidthstring 00.00.0000
12884 \labelwidthstring 00.00.0000
12894 \labelwidthstring 00.00.0000
12904 \labelwidthstring 00.00.0000
12914 \labelwidthstring 00.00.0000
12922 math-delim langle rangle
12924 -- angular delimiters
12925 \begin_inset Formula $\left\langle \right\rangle $
12928 , not to confuse with ordinary < > signs.
12930 \labelwidthstring 00.00.0000
12938 math-delim langle rangle
12941 The bar bracket: on some keyboards (e.g.\SpecialChar ~
12942 some British ones), the bar character
12947 -something and on some wayward Unices to "brokenbar".
12948 So we define all of these keys as well.
12950 \labelwidthstring 00.00.0000
12960 \labelwidthstring 00.00.0000
12970 \labelwidthstring 00.00.0000
12980 \labelwidthstring 00.00.0000
12990 \labelwidthstring 00.00.0000
13001 Accents are in most cases
13005 -<accent key>, e.g.\SpecialChar ~
13019 for tilde (you also need to press
13025 \begin_inset Quotes eld
13037 \begin_inset Quotes erd
13041 Some accents work only in math mode and others only in text mode.
13043 \labelwidthstring 00.00.0000
13053 -- overdot accent, \i \.{a}
13056 \labelwidthstring 00.00.0000
13069 \begin_inset Formula $\dot{a}$
13072 (math mode only -- in physics this denotes a first derivative).
13074 \labelwidthstring 00.00.0000
13086 -- Vector accent over math
13087 \begin_inset Formula $\overrightarrow{x}$
13092 \labelwidthstring 00.00.0000
13102 -- umlaut accent, ä (text mode only)
13104 \labelwidthstring 00.00.0000
13116 -- double dot accent,
13117 \begin_inset Formula $\ddot{a}$
13120 (math mode only -- in physics this denotes a second derivative).
13121 To get a triple dot in math mode, use
13127 \labelwidthstring 00.00.0000
13137 -- grave accent à (text mode only, use
13145 \labelwidthstring 00.00.0000
13155 -- tilde accent ã (text mode only, use
13163 \labelwidthstring 00.00.0000
13173 -- acute accent á (text mode only, use
13181 \labelwidthstring 00.00.0000
13191 -- circumflex (caret) accent â (text mode only, use
13201 The new key S-F2 for creating a LaTeX file seems handy.
13203 \labelwidthstring 00.00.0000
13213 -- Save current document.
13215 \labelwidthstring 00.00.0000
13223 buffer-export latex
13225 -- Write a LaTeX file for the current document.
13227 \labelwidthstring 00.00.0000
13237 -- Find and replace dialog.
13239 \labelwidthstring 00.00.0000
13255 \labelwidthstring 00.00.0000
13269 to quit LyX is the W*ndows w*ndow manager's mnemonic.
13280 are used to switch fonts.
13285 to switch back to the normal font.
13286 The non-default font switches
13294 all work as toggles.
13295 They also work on the whole word if you put the cursor in the middle of
13296 the word, or if you select some text.
13298 \labelwidthstring 00.00.0000
13308 -- stop using any special font
13310 \labelwidthstring 00.00.0000
13326 \labelwidthstring 00.00.0000
13342 \labelwidthstring 00.00.0000
13358 \labelwidthstring 00.00.0000
13373 (Used sometimes for people's names.)
13381 \begin_inset Quotes eld
13385 \begin_inset Quotes erd
13392 key (useful e.g.\SpecialChar ~
13393 if the keyboard has no working
13400 Here are some Sciword-inspired mnemonics for frequently used math symbols.
13401 Many symbols start with a
13410 cannot be itself bound to anything.
13412 \labelwidthstring 00.00.0000
13425 \begin_inset Quotes eld
13429 \begin_inset Quotes erd
13433 \begin_inset Formula $\prime$
13437 This is frequently unnecessary: in most cases the normal apostrophe works
13440 \begin_inset Formula $x'+2x=0$
13443 , but in some cases this would generate a double superscript error in LaTeX.
13445 \begin_inset Formula $x^{\prime2}$
13449 \begin_inset Formula $x$
13452 prime squared) must be entered with the prime character.
13454 \labelwidthstring 00.00.0000
13463 command-sequence math-superscript; math-insert
13467 -- Insert a prime as a superscript (see example above).
13469 \labelwidthstring 00.00.0000
13479 -- Insert an upper index.
13484 \labelwidthstring 00.00.0000
13494 -- Insert a lower index.
13499 \labelwidthstring 00.00.0000
13512 -- Partial derivative symbol
13513 \begin_inset Formula $\partial$
13518 \labelwidthstring 00.00.0000
13531 -- Summation symbol
13532 \begin_inset Formula $\sum$
13535 (not the same as the Greek letter uppercase Sigma
13536 \begin_inset Formula $\Sigma$
13539 because it can resize and allows smart upper/lower limits).
13541 \labelwidthstring 00.00.0000
13555 \begin_inset Formula $\prod$
13558 (not the same as the Greek letter uppercase Pi,
13559 \begin_inset Formula $\Pi$
13564 \labelwidthstring 00.00.0000
13578 \begin_inset Formula $\infty$
13583 \labelwidthstring 00.00.0000
13597 \begin_inset Formula $\times$
13602 \labelwidthstring 00.00.0000
13613 -- Insert a stacked array
13614 \begin_inset Formula $\begin{array}{c}
13616 \\\end{array}\end{array}$
13620 (Frequently useful in formulae.)
13622 \labelwidthstring 00.00.0000
13634 \begin_inset Formula $\times$
13638 \begin_inset Formula $\begin{array}{ccc}
13643 (Then you can modify its size using the
13645 Edit\SpecialChar \menuseparator
13650 \labelwidthstring 00.00.0000
13664 \begin_inset Quotes eld
13668 \begin_inset Quotes erd
13672 \begin_inset Formula $\dagger$
13677 \labelwidthstring 00.00.0000
13691 \begin_inset Quotes eld
13695 \begin_inset Quotes erd
13699 \begin_inset Formula $\equiv$
13704 \labelwidthstring 00.00.0000
13717 \begin_inset Quotes eld
13720 Approximate equality
13721 \begin_inset Quotes erd
13725 \begin_inset Formula $\approx$
13730 \labelwidthstring 00.00.0000
13743 \begin_inset Quotes eld
13747 \begin_inset Quotes erd
13751 \begin_inset Formula $\sim$
13756 \labelwidthstring 00.00.0000
13769 \begin_inset Formula $\rightarrow$
13773 \begin_inset Formula $\lim_{x\rightarrow0}$
13778 \labelwidthstring 00.00.0000
13791 \begin_inset Formula $\leq$
13796 \labelwidthstring 00.00.0000
13808 -- Greater-or-equal
13809 \begin_inset Formula $\geq$
13814 \labelwidthstring 00.00.0000
13828 \begin_inset Quotes eld
13832 \begin_inset Quotes erd
13836 \begin_inset Formula $\ll$
13839 (useful in physics)
13841 \labelwidthstring 00.00.0000
13855 \begin_inset Quotes eld
13859 \begin_inset Quotes erd
13863 \begin_inset Formula $\gg$
13869 Standard math bindings
13871 \labelwidthstring 00.00.0000
13884 \labelwidthstring 00.00.0000
13895 \labelwidthstring 00.00.0000
13906 \labelwidthstring 00.00.0000
13919 \labelwidthstring 00.00.0000
13930 \labelwidthstring 00.00.0000
13941 \labelwidthstring 00.00.0000
13954 \labelwidthstring 00.00.0000
13965 \labelwidthstring 00.00.0000
13976 \labelwidthstring 00.00.0000
13987 \labelwidthstring 00.00.0000
14000 \labelwidthstring 00.00.0000
14013 \labelwidthstring 00.00.0000
14026 \labelwidthstring 00.00.0000
14039 \labelwidthstring 00.00.0000
14052 \labelwidthstring 00.00.0000
14065 \labelwidthstring 00.00.0000
14076 \labelwidthstring 00.00.0000
14089 \labelwidthstring 00.00.0000
14100 \labelwidthstring 00.00.0000
14111 \labelwidthstring 00.00.0000
14122 \labelwidthstring 00.00.0000
14133 \labelwidthstring 00.00.0000
14146 \labelwidthstring 00.00.0000
14157 \labelwidthstring 00.00.0000
14168 \labelwidthstring 00.00.0000
14179 \labelwidthstring 00.00.0000
14188 math-delim langle rangle
14190 \labelwidthstring 00.00.0000
14199 math-delim rangle langle
14201 \labelwidthstring 00.00.0000
14212 \labelwidthstring 00.00.0000
14225 \labelwidthstring 00.00.0000
14241 \labelwidthstring 00.00.0000
14250 \labelwidthstring 00.00.0000
14259 \labelwidthstring 00.00.0000
14268 \labelwidthstring 00.00.0000
14277 \labelwidthstring 00.00.0000