1 #LyX 2.2 created this file. For more info see http://www.lyx.org/
5 \save_transient_properties true
6 \origin /systemlyxdir/doc/
9 % DO NOT ALTER THIS PREAMBLE!!!
11 % This preamble is designed to ensure that the manual prints
12 % out as advertised. If you mess with this preamble,
13 % parts of the manual may not print out as expected. If you
14 % have problems LaTeXing this file, please contact
15 % the documentation team
16 % email: lyx-docs@lists.lyx.org
18 % the pages of the TOC are numbered roman
19 % and a PDF-bookmark for the TOC is added
21 \let\myTOC\tableofcontents
22 \renewcommand{\tableofcontents}{%
23 \pdfbookmark[1]{\contentsname}{}
26 \pagenumbering{arabic}}
28 % extra space for tables
29 \newcommand{\extratablespace}[1]{\noalign{\vskip#1}}
31 \options fleqn,bibliography=totoc,index=totoc,BCOR7.5mm,titlepage,captions=tableheading
32 \use_default_options false
40 \maintain_unincluded_children false
42 \language_package default
45 \font_roman "lmodern" "default"
46 \font_sans "lmss" "default"
47 \font_typewriter "lmtt" "default"
48 \font_math "auto" "auto"
49 \font_default_family default
50 \use_non_tex_fonts false
53 \font_sf_scale 100 100
54 \font_tt_scale 100 100
56 \default_output_format pdf2
58 \bibtex_command default
59 \index_command default
63 \pdf_title "LyX's Additional Features manual"
64 \pdf_author "LyX Team"
65 \pdf_subject "LyX's additional features documentation"
66 \pdf_keywords "LyX, Documentation, Additional"
68 \pdf_bookmarksnumbered true
69 \pdf_bookmarksopen false
70 \pdf_bookmarksopenlevel 1
75 \pdf_pdfusetitle false
76 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
79 \use_package amsmath 1
80 \use_package amssymb 1
83 \use_package mathdots 1
84 \use_package mathtools 0
86 \use_package stackrel 0
87 \use_package stmaryrd 0
88 \use_package undertilde 0
90 \cite_engine_type default
94 \paperorientation portrait
98 \notefontcolor #0000ff
105 \paragraph_separation indent
106 \paragraph_indentation default
107 \quotes_language english
110 \paperpagestyle headings
111 \tracking_changes false
112 \output_changes false
121 Additional \SpecialChar LyX
125 \begin_layout Subtitle
130 by the \SpecialChar LyX
135 \begin_layout Plain Layout
137 Principal maintainer of this file is
142 If you have comments or error corrections, please send them to the \SpecialChar LyX
145 \begin_inset Flex Code
148 \begin_layout Plain Layout
150 <lyx-docs@lists.lyx.org>
163 \begin_layout Standard
164 \begin_inset CommandInset toc
165 LatexCommand tableofcontents
172 \begin_layout Chapter
176 \begin_layout Standard
177 This manual is essentially Part II of the
179 User's Guide\SpecialChar endofsentence
182 The reason for separating the two documents is simple: the
186 is already quite lengthy, and it contains information on all of the basic
187 features one needs to know in order to prepare most documents.
188 However, the \SpecialChar LyX
189 Team has worked to make \SpecialChar LyX
190 extensible through various configuration
191 files and external packages.
192 That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
194 create a layout file (or module) for it without having to alter \SpecialChar LyX
196 We've already had contributions of several new features this way, and some
197 of them are documented here.
198 There are also some more `advanced' features, such as how to control the
199 presentation of bibliographies and how to work with multi-part documents,
200 that are not covered in the
204 and are discussed here.
207 \begin_layout Standard
208 This manual also documents some special features, like fax support, version
209 control, and SGML support, which require additional software to work properly.
210 There is also a chapter on \SpecialChar LyX
212 And lastly, there's a chapter of \SpecialChar LaTeX
213 tools and tips, things you can use to
214 spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
216 After all, \SpecialChar LyX
221 only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
225 \begin_layout Standard
226 If you haven't read the
230 yet, you are definitely in the wrong manual.
235 is the first place to go, since it describes the notation and format of
237 You should also be thoroughly familiar with the
241 and all of the basic features of \SpecialChar LyX
242 before attempting to read this one.
245 \begin_layout Standard
246 Since many of the topics in this manual depend heavily on \SpecialChar LyX
248 with \SpecialChar LaTeX
249 , this first chapter covers the inner workings of \SpecialChar LyX
252 to generate exactly the \SpecialChar LaTeX
254 It is obviously for more seasoned \SpecialChar LyX
258 \begin_layout Chapter
260 and \SpecialChar LaTeX
264 \begin_layout Section
266 Uses \SpecialChar LaTeX
270 \begin_layout Standard
271 This chapter is for both \SpecialChar TeX
272 -nicians and the \SpecialChar LaTeX
274 In it, we'll explain how \SpecialChar LyX
275 and \SpecialChar LaTeX
276 work together to produce printable output.
277 This is the only place in any of the manuals where we assume you know something
278 about \SpecialChar LaTeX
282 \begin_layout Standard
283 At one time, \SpecialChar LyX
285 \begin_inset Quotes eld
288 WYSIWYM frontend to \SpecialChar LaTeX
290 \begin_inset Quotes erd
293 but that's no longer true.
294 There are frontends to \SpecialChar LaTeX
299 \begin_layout Plain Layout
300 Some familar ones are \SpecialChar TeX
301 maker and kile, on Linux, and \SpecialChar TeX
303 There are also the \SpecialChar LaTeX
304 modes for vi and emacs, of course.
309 These are basically text editors with the ability to run \SpecialChar LaTeX
311 errors in the file you're editing.
312 Although \SpecialChar LyX
321 run \SpecialChar LaTeX
322 , and it also indicates errors in the file, it also does much, much
324 For one thing, you don't need to know \SpecialChar LaTeX
325 to use \SpecialChar LyX
328 has added its own extensions to \SpecialChar LaTeX
330 Try the following sometime: select
331 \begin_inset Flex Noun
334 \begin_layout Plain Layout
335 Export\SpecialChar menuseparator
343 \begin_inset Flex Noun
346 \begin_layout Plain Layout
353 \begin_inset Flex Noun
356 \begin_layout Plain Layout
357 View\SpecialChar menuseparator
367 ), then look at the preamble of the resulting
368 \begin_inset Flex Code
371 \begin_layout Plain Layout
378 You'll notice a variety of new macros defined specifically by \SpecialChar LyX
380 These macros are defined automatically, according to the features you use
384 \begin_layout Standard
385 There are several commands that automatically invoke \SpecialChar LaTeX
390 \begin_layout Itemize
391 \begin_inset Flex Noun
394 \begin_layout Plain Layout
395 Document\SpecialChar menuseparator
404 \begin_layout Itemize
405 \begin_inset Flex Noun
408 \begin_layout Plain Layout
409 Document\SpecialChar menuseparator
418 \begin_layout Itemize
419 \begin_inset Flex Noun
422 \begin_layout Plain Layout
423 File\SpecialChar menuseparator
432 \begin_layout Itemize
433 \begin_inset Flex Noun
436 \begin_layout Plain Layout
437 File\SpecialChar menuseparator
446 \begin_layout Standard
447 They will only invoke \SpecialChar LaTeX
448 if the file has changed since the last time \SpecialChar LaTeX
454 \begin_layout Standard
455 When \SpecialChar LyX
456 runs \SpecialChar LaTeX
457 on the file you're editing, it performs these steps:
460 \begin_layout Enumerate
461 Convert the document to \SpecialChar LaTeX
462 and save to a file with the extension
463 \begin_inset Flex Code
466 \begin_layout Plain Layout
473 \begin_inset Flex Code
476 \begin_layout Plain Layout
485 \begin_layout Enumerate
486 Run \SpecialChar LaTeX
488 \begin_inset Flex Code
491 \begin_layout Plain Layout
497 file (maybe several times), and run any other commands (such as
498 \begin_inset Flex Code
501 \begin_layout Plain Layout
508 \begin_inset Flex Code
511 \begin_layout Plain Layout
517 ) needed to compile the \SpecialChar LaTeX
521 \begin_layout Enumerate
522 If there are any errors, show the error log.
525 \begin_layout Standard
526 If you have run \SpecialChar LaTeX
528 \begin_inset Flex Noun
531 \begin_layout Plain Layout
532 View\SpecialChar menuseparator
539 then runs a DVI viewer to display the DVI-file.
541 \begin_inset Flex Noun
544 \begin_layout Plain Layout
545 View\SpecialChar menuseparator
552 performs further steps:
555 \begin_layout Itemize
557 \begin_inset Flex Code
560 \begin_layout Plain Layout
566 to convert the DVI file to PostScript.
569 \begin_layout Itemize
570 Run a PostScript viewer, such as
571 \begin_inset Flex Code
574 \begin_layout Plain Layout
580 , to display the PostScript file.
583 \begin_layout Standard
585 does similar things when viewing, or exporting, other formats.
588 \begin_layout Section
589 Translating \SpecialChar LaTeX
590 files into \SpecialChar LyX
594 \begin_layout Standard
595 You can import a \SpecialChar LaTeX
596 file into \SpecialChar LyX
598 \begin_inset Flex Noun
601 \begin_layout Plain Layout
602 File\SpecialChar menuseparator
603 Import\SpecialChar menuseparator
610 command in \SpecialChar LyX
612 This will call a program named
613 \begin_inset Flex Code
616 \begin_layout Plain Layout
622 which will create a file
623 \begin_inset Flex Code
626 \begin_layout Plain Layout
633 \begin_inset Flex Code
636 \begin_layout Plain Layout
644 will then open that file.
648 \begin_layout Plain Layout
649 \begin_inset Flex Code
652 \begin_layout Plain Layout
658 can also be run from the command line, of course.
666 \begin_layout Standard
667 \begin_inset Flex Code
670 \begin_layout Plain Layout
676 will translate most legal \SpecialChar LaTeX
677 , but not everything.
678 It will put things it doesn't understand into \SpecialChar TeX
679 code, so after translating
681 \begin_inset Flex Code
684 \begin_layout Plain Layout
690 , you can look for \SpecialChar TeX
691 code and hand-edit it until it looks right.
694 \begin_layout Standard
695 If you don't know what \SpecialChar TeX
696 code is, read the next section.
699 \begin_layout Section
700 \begin_inset CommandInset label
702 name "sec:Inserting-TeX-Code"
706 Inserting \SpecialChar TeX
707 Code into \SpecialChar LyX
711 \begin_layout Standard
712 Anything you can do in \SpecialChar LaTeX
713 you can do in \SpecialChar LyX
714 , for a very simple reason: You can
715 always insert \SpecialChar TeX
716 code into any \SpecialChar LyX
719 cannot, and will never be able to, display every possible \SpecialChar LaTeX
721 If ever you need to insert \SpecialChar LaTeX
722 commands into your \SpecialChar LyX
723 document, you can use the
725 \begin_inset Flex Code
728 \begin_layout Plain Layout
735 box, which you can insert into your document with
736 \begin_inset Flex Noun
739 \begin_layout Plain Layout
740 Insert\SpecialChar menuseparator
750 or the keyboard shortcut
759 \begin_layout Standard
760 Here's an example of inserting \SpecialChar LaTeX
761 commands in a \SpecialChar LyX
763 The code looks like this:
766 \begin_layout LyX-Code
770 \begin_inset Newline newline
776 \begin_inset Newline newline
779 This is an example of a minipage environment.
781 \begin_inset Newline newline
784 can put nearly everything in it, even (non-floating)
785 \begin_inset Newline newline
790 \begin_inset Newline newline
796 \begin_inset Newline newline
800 \begin_inset Newline newline
806 \begin_inset Newline newline
812 \begin_inset Newline newline
818 \begin_inset Newline newline
823 \begin_inset Newline newline
829 \begin_inset Newline newline
835 \begin_inset Newline newline
841 \begin_inset Newline newline
849 \begin_layout LyX-Code
853 \begin_layout Standard
855 \begin_inset Flex Code
858 \begin_layout Plain Layout
865 box containing this text is directly after this paragraph.
866 Those of you reading the manual in \SpecialChar LyX
867 will only see the \SpecialChar TeX
869 Those reading a printed version of the manuals will see the actual results:
870 \begin_inset VSpace bigskip
876 \begin_layout Standard
880 \begin_layout Plain Layout
887 \begin_layout Plain Layout
894 \begin_layout Plain Layout
896 This is an example of a minipage environment.
897 You can put nearly everything in it, even (non-floating) figures and tables.
901 \begin_layout Plain Layout
908 \begin_layout Plain Layout
913 \begin_layout Plain Layout
920 \begin_layout Plain Layout
927 \begin_layout Plain Layout
934 \begin_layout Plain Layout
940 \begin_layout Plain Layout
947 \begin_layout Plain Layout
954 \begin_layout Plain Layout
961 \begin_layout Plain Layout
971 \begin_inset VSpace bigskip
977 \begin_layout Standard
978 In addition to using \SpecialChar TeX
979 code, you can also create a separate file containing
980 some complex \SpecialChar LaTeX
981 structure and then use
982 \begin_inset Flex Noun
985 \begin_layout Plain Layout
986 Insert\SpecialChar menuseparator
996 to include your file (you should select the type
997 \begin_inset Flex Code
1000 \begin_layout Plain Layout
1007 We recommend that you only do this if you have a
1008 \begin_inset Flex Code
1011 \begin_layout Plain Layout
1022 Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
1026 \begin_layout Standard
1027 There are a few last points to emphasize:
1030 \begin_layout Itemize
1036 check if your \SpecialChar LaTeX
1040 \begin_layout Itemize
1041 Beware of reinventing the wheel.
1044 \begin_layout Standard
1045 On that last point, \SpecialChar LyX
1046 does have quite a few features tucked into it, and
1048 Be sure to check the manuals to make sure that \SpecialChar LyX
1049 doesn't have such-and-such
1050 feature before you decide you have to do it by hand.
1051 Moreover, there are numerous \SpecialChar LaTeX
1052 packages out there to do all sorts of things,
1053 from labels to envelopes to fancy multipage tables.
1055 \begin_inset CommandInset href
1058 target "http://www.ctan.org/"
1065 \begin_layout Standard
1066 If you do need to do some wild and fancy things within your document, be
1067 sure to check out a good \SpecialChar LaTeX
1068 book for assistance.
1069 There are a number of them listed in the bibliography of the
1076 \begin_layout Section
1078 and the \SpecialChar LaTeX
1082 \begin_layout Subsection
1083 About the \SpecialChar LaTeX
1087 \begin_layout Standard
1088 If you already know \SpecialChar LaTeX
1089 , there is no need to explain here what the preamble
1091 If you don't, the following will give you some ideas—we recommend again
1092 that you consult a \SpecialChar LaTeX
1093 book for further information.
1094 In any case, you should read the points below, because they explain what
1095 you can do and what you don't need to do in the \SpecialChar LaTeX
1096 preamble of a \SpecialChar LyX
1100 \begin_layout Standard
1101 The \SpecialChar LaTeX
1102 preamble comes at the very beginning of a document,
1110 \begin_layout Itemize
1111 Declare the document class.
1113 \begin_inset Newline newline
1117 already does this for you.
1118 If you're a seasoned \SpecialChar LaTeX
1119 -nician, and you have a custom document class you
1120 want to use, check out the
1122 Customization Manual
1124 for information on how to make \SpecialChar LyX
1128 \begin_layout Itemize
1129 Declare the usage of packages.
1131 \begin_inset Newline newline
1135 packages provide special commands, which are only available within a document
1136 when the package has been declared in the preamble.
1137 In addition to providing special commands, the inclusion of a package can
1138 change the document.
1139 For example, the package
1140 \begin_inset Flex Code
1143 \begin_layout Plain Layout
1149 forces all paragraphs to be indented.
1150 There are other packages for labels, envelopes, margins, etc.
1154 \begin_layout Itemize
1155 Set counters, variables, lengths and widths.
1157 \begin_inset Newline newline
1160 There are several \SpecialChar LaTeX
1161 counters and variables that
1165 be set globally from within the preamble in order to have the desired effect.
1166 (There are variables that you can set and reset inside the document, too.)
1167 Margins are a good example of something that must be set in the preamble.
1168 Another example is the label format for lists.
1169 You can actually set these just about anywhere, but it's best to do it
1170 just once, inside the preamble.
1173 \begin_layout Itemize
1174 Declare user defined commands (with
1175 \begin_inset Flex Code
1178 \begin_layout Plain Layout
1187 \begin_inset Flex Code
1190 \begin_layout Plain Layout
1199 \begin_inset Newline newline
1202 These are abbreviations for \SpecialChar LaTeX
1203 commands which appear very often inside a document.
1204 Although the preamble is a good place to declare such commands, they
1208 be declared anywhere (before they are used for the first time, of course).
1209 This can be useful if there is a lot of raw \SpecialChar LaTeX
1210 code in your document, which
1211 normally should not be the case.
1214 \begin_layout Standard
1216 adds its own set of definitions to the preamble of the
1217 \begin_inset Flex Code
1220 \begin_layout Plain Layout
1227 This makes \SpecialChar LaTeX
1228 files generated by \SpecialChar LyX
1232 \begin_layout Subsection
1233 Changing the Preamble
1236 \begin_layout Standard
1237 The commands which \SpecialChar LyX
1238 adds to the preamble of a \SpecialChar LaTeX
1239 file are fixed; you can't
1240 change them without patching \SpecialChar LyX
1242 You can, however, add your own stuff to the preamble by selecting
1243 \begin_inset Flex Noun
1246 \begin_layout Plain Layout
1249 \begin_inset space ~
1258 \begin_inset Flex Noun
1261 \begin_layout Plain Layout
1262 Document\SpecialChar menuseparator
1270 adds anything in the
1271 \begin_inset Flex Noun
1274 \begin_layout Plain Layout
1280 dialog to its own built-in preamble.
1281 Before adding your own declarations in the preamble, you should make sure
1282 that \SpecialChar LyX
1283 doesn't already support what you want to do.
1284 (Remember what we said about reinventing the wheel?) Also,
1286 make sure your preamble code is correct
1290 doesn't check it for you.
1291 If there is an error, you're likely to get an error like
1292 \begin_inset Quotes eld
1296 \begin_inset Flex Code
1299 \begin_layout Plain Layout
1308 \begin_inset Quotes erd
1312 If you see this error, check your preamble.
1315 \begin_layout Subsection
1319 \begin_layout Standard
1320 Here are some examples of what you can add to a preamble, and what they
1324 \begin_layout Subsubsection
1328 \begin_layout Standard
1329 There are two variables under \SpecialChar LaTeX
1330 that control page position:
1331 \begin_inset Flex Code
1334 \begin_layout Plain Layout
1343 \begin_inset Flex Code
1346 \begin_layout Plain Layout
1355 Their names should be self-explanatory.
1356 These variables are useful if you think for a moment about computer labels.
1357 Sometimes, the size of a print medium and the area of the medium that you
1358 can actually print on aren't the same.
1360 \begin_inset Flex Code
1363 \begin_layout Plain Layout
1372 \begin_inset Flex Code
1375 \begin_layout Plain Layout
1386 \begin_layout Standard
1387 The default values for
1388 \begin_inset Flex Code
1391 \begin_layout Plain Layout
1400 \begin_inset Flex Code
1403 \begin_layout Plain Layout
1412 \begin_inset space \thinspace{}
1416 \begin_inset space \thinspace{}
1420 \begin_inset space \space{}
1423 the page isn't shifted.
1424 Unfortunately, some DVI drivers always seem to shift the page.
1425 We have no idea why, or why the sysadmin hasn't fixed such behavior.
1426 If you're using \SpecialChar LyX
1427 on a system that you don't personally maintain, and your
1428 sysadmin is a doofus,
1429 \begin_inset Flex Code
1432 \begin_layout Plain Layout
1441 \begin_inset Flex Code
1444 \begin_layout Plain Layout
1453 Suppose your left and top margins are always 0.5
1454 \begin_inset space \thinspace{}
1458 You can add this to the preamble:
1461 \begin_layout LyX-Code
1469 \begin_layout LyX-Code
1477 \begin_layout Standard
1478 and your margins should now be correct.
1481 \begin_layout Subsubsection
1485 \begin_layout Standard
1486 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1487 There's a rather nice package, available at your nearest CTAN archive,
1488 for printing sheets of labels:
1489 \begin_inset Flex Code
1492 \begin_layout Plain Layout
1499 Now, your system may not have this package installed by default.
1500 We leave that up to you to check.
1501 You'll also want to read the documentation for it; we're not going to do
1503 Since this is an example, however, we'll give you an example of how you
1507 \begin_layout Standard
1508 First, make sure you're using the
1509 \begin_inset Flex Code
1512 \begin_layout Plain Layout
1519 Next, you need to put the following in your preamble:
1522 \begin_layout LyX-Code
1528 \begin_layout LyX-Code
1534 \begin_layout LyX-Code
1540 \begin_layout LyX-Code
1546 \begin_layout LyX-Code
1552 \begin_layout LyX-Code
1558 \begin_layout LyX-Code
1564 \begin_layout Standard
1565 This sets things up for Avery label sheets, stock #5360.
1566 You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1569 \begin_inset Flex Code
1572 \begin_layout Plain Layout
1581 \begin_inset Flex Code
1584 \begin_layout Plain Layout
1592 around each label text.
1593 This and other special features of
1594 \begin_inset Flex Code
1597 \begin_layout Plain Layout
1603 are explained in its documentation.
1606 \begin_layout Standard
1607 Someday, someone may write a \SpecialChar LyX
1608 layout file to support this package directly.
1609 Maybe that someone is you.
1612 \begin_layout Subsubsection
1613 Example #3: Paragraph Indentation
1616 \begin_layout Standard
1617 Americans are trained to indent the first line of
1622 As with all of their other weird quirks, most Americans will whine and
1623 moan until they can have their way and indent the first line of all paragraphs.
1632 \begin_layout Standard
1633 Of course, this behavior isn't standard typography.
1634 In books, you typically only indent the first line of a paragraph
1638 it follows another one.
1639 The idea behind indenting the first line of a paragraph is to distinguish
1640 neighboring paragraphs from one another.
1641 If there is no previous paragraph—for example, if it follows a figure or
1642 is the first paragraph in a section—then there is no need for indentation.
1646 \begin_layout Standard
1647 If you're a typical American (we're still joking!), though, you don't care
1648 about such esoteric things; you want your indentation! Add this to the
1652 \begin_layout LyX-Code
1655 usepackage{indentfirst}
1658 \begin_layout Standard
1659 If your \SpecialChar TeX
1660 distribution isn't braindead, you'll have this package, and all
1661 of your paragraphs will get the indentation the Founding Fathers intended
1665 \begin_layout Subsubsection
1666 Example #4: This Document
1669 \begin_layout Standard
1670 You can also check out the preamble of this document to get an idea of some
1671 of the advanced things you can do.
1674 \begin_layout Section
1676 and \SpecialChar LaTeX
1680 \begin_layout Standard
1681 When \SpecialChar LyX
1682 calls \SpecialChar LaTeX
1683 , it tells \SpecialChar LaTeX
1684 to blithely ignore any errors and keep going.
1685 It then uses the logfile from the \SpecialChar LaTeX
1686 run to do a post-mortem.
1687 After analyzing the logfile, \SpecialChar LyX
1688 displays a dialog listing the errors.
1689 Clicking on any one of them will take you to the position in your \SpecialChar LyX
1691 where the error occurred.
1695 \begin_layout Plain Layout
1697 Analyzing the logfile is a tough job, and \SpecialChar LyX
1698 doesn't always go to the right
1700 There are also cases where \SpecialChar LaTeX
1701 reports the error on one line, but the actual
1703 This is not unlike forgetting a closing brace in a program: You'll get
1704 an error, but only later.
1712 \begin_layout Standard
1713 Some folks also like to look at the log file directly: It is available from
1715 \begin_inset Flex Noun
1718 \begin_layout Plain Layout
1719 Document\SpecialChar menuseparator
1721 \begin_inset space ~
1730 There are some fairly common error messages and warnings.
1731 We'll cover those here.
1732 You should look at a good \SpecialChar LaTeX
1733 book for a complete listing.
1736 \begin_layout Itemize
1737 \begin_inset Flex Code
1740 \begin_layout Plain Layout
1748 \begin_inset Newline newline
1751 Anything beginning with these words is a warning message for the purpose
1753 \begin_inset Quotes eld
1757 \begin_inset Quotes erd
1760 the \SpecialChar LaTeX
1762 You'll get messages like this if you added or changed cross-references
1763 or bibliography entries, in which case, \SpecialChar LaTeX
1764 is trying to tell you that you
1765 need to make another run.
1766 You can by-and-large ignore these.
1769 \begin_layout Itemize
1770 \begin_inset Flex Code
1773 \begin_layout Plain Layout
1781 \begin_inset Newline newline
1784 Another warning message, this time about fonts which \SpecialChar LaTeX
1786 The rest of the message will often say something about a replacement font
1787 that \SpecialChar LaTeX
1789 You can safely ignore these, too.
1792 \begin_layout Itemize
1793 \begin_inset Flex Code
1796 \begin_layout Plain Layout
1805 \begin_inset Newline newline
1814 They are warnings about lines that were too long and run past the right
1816 Almost always, this is unnoticeable in the final output.
1817 (It can be just a point or two.) Or, only one or two characters extend past
1820 seems to generate at least one of these messages for just about any document
1822 \begin_inset Newline newline
1825 You can ignore these messages.
1826 Your eyes will tell you if there's a problem with something that's too
1827 wide; just look at the output.
1831 \begin_layout Plain Layout
1832 You can also enable the `draft' option in
1833 \begin_inset Flex Noun
1836 \begin_layout Plain Layout
1837 Document\SpecialChar menuseparator
1843 , and then \SpecialChar LaTeX
1844 will draw a black box in the margin of lines that are overfull.
1852 \begin_layout Itemize
1853 \begin_inset Flex Code
1856 \begin_layout Plain Layout
1865 \begin_inset Newline newline
1868 Not quite as common as its cousin.
1870 seems to like to print lines that are a bit too wide as opposed to ones
1871 that are a bit too narrow.
1872 We have no idea why.
1875 \begin_layout Itemize
1876 \begin_inset Flex Code
1879 \begin_layout Plain Layout
1888 \begin_inset Flex Code
1891 \begin_layout Plain Layout
1900 \begin_inset Newline newline
1903 Warnings about troubles breaking the page.
1904 Once again, just look at the output.
1905 Your eyes will tell you where something has gone wrong.
1908 \begin_layout Itemize
1909 \begin_inset Flex Code
1912 \begin_layout Plain Layout
1915 \begin_inset Quotes els
1919 \begin_inset Quotes ers
1928 \begin_inset Newline newline
1932 \begin_inset Quotes eld
1936 \begin_inset Quotes erd
1939 isn't installed on this system.
1940 This usually appears because some package your document needs isn't installed.
1941 If you didn't touch the preamble or didn't use the
1942 \begin_inset Flex Code
1945 \begin_layout Plain Layout
1953 command, then one of the packages \SpecialChar LyX
1954 tried to load is missing.
1956 \begin_inset Flex Noun
1959 \begin_layout Plain Layout
1960 Help\SpecialChar menuseparator
1967 to get a list of packages that \SpecialChar LyX
1969 This file is updated whenever you reconfigure \SpecialChar LyX
1971 \begin_inset Flex Noun
1974 \begin_layout Plain Layout
1975 Tools\SpecialChar menuseparator
1981 ) and tells you which packages have been detected and what they do.
1982 \begin_inset Newline newline
1986 \begin_inset Flex Code
1989 \begin_layout Plain Layout
1997 command and the package in question isn't installed, then you'll need to
1998 install it yourself.
2001 \begin_layout Itemize
2002 \begin_inset Flex Code
2005 \begin_layout Plain Layout
2007 Error: Unknown option
2013 \begin_inset Newline newline
2016 Error messages beginning with this are trying to tell you that you specified
2017 a bad or undefined option to a package.
2018 Check the package's documentation.
2021 \begin_layout Itemize
2022 \begin_inset Flex Code
2025 \begin_layout Plain Layout
2026 Undefined control sequence
2032 \begin_inset Newline newline
2035 If you've inserted \SpecialChar LaTeX
2036 code into your document, but made a typo, you'll get
2038 You may have forgotten to load a package.
2039 In any case, this error message usually means that you used an undefined
2044 \begin_layout Standard
2045 There are other error and warning messages.
2046 Some are self-explanatory.
2047 These are usually \SpecialChar LaTeX
2049 Others are downright cryptic.
2050 These are usually \SpecialChar TeX
2051 error messages, and we really have
2055 what they mean or how to decipher them.
2059 \begin_layout Standard
2060 There's a general sequence you should follow if you get error messages:
2063 \begin_layout Enumerate
2064 Look at the \SpecialChar LaTeX
2065 code you inserted for typos.
2068 \begin_layout Enumerate
2069 If there are no typos, check that you used the command(s) correctly.
2072 \begin_layout Enumerate
2073 If you get a bunch of error boxes piled up at the very top of the document—and
2074 especially if you see a
2075 \begin_inset Quotes eld
2079 \begin_inset Flex Code
2082 \begin_layout Plain Layout
2091 \begin_inset Quotes erd
2094 error—it means that there are errors in the preamble.
2095 Start debugging your preamble.
2098 \begin_layout Enumerate
2099 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2101 document, the first suspect is your \SpecialChar LaTeX
2102 distribution itself.
2103 Check for missing packages and install them.
2106 \begin_layout Enumerate
2107 Okay, so there are no missing packages.
2108 Did you use any of the fine-tuning options in \SpecialChar LyX
2109 ? Specifically, did you
2113 any of them, like trying to manually insert lots of
2114 \begin_inset Flex Code
2117 \begin_layout Plain Layout
2119 \begin_inset space ~
2128 \begin_inset Flex Code
2131 \begin_layout Plain Layout
2138 \begin_inset Flex Code
2141 \begin_layout Plain Layout
2147 ? Did you try to kludge something together with these instead of using the
2148 appropriate paragraph environment?
2151 \begin_layout Enumerate
2152 All right, you didn't use any of the fine-tuning options, you played by
2154 Did you try to pull a fancy maneuver? Did you do something funky inside
2155 a table or an equation, like inserting a graphic into a table cell?
2158 \begin_layout Enumerate
2159 Do you have long sections of text where \SpecialChar LaTeX
2160 cannot find a place to break a
2161 line? By default, \SpecialChar LaTeX
2162 is rather strict about how much extra inter-word spacing
2163 it will add in order to break a line.
2164 Preferably, you should rework the paragraph to avoid the problem.
2167 \begin_layout Enumerate
2168 Did you go overboard with the nesting? \SpecialChar LyX
2169 (currently) doesn't check to make
2170 sure you're in the limits for nesting environments.
2171 If you nested a bunch of environments to the
2172 \begin_inset Formula $17^{\mathrm{th}}$
2175 level, that's the problem.
2176 (The limit in \SpecialChar LaTeX
2180 \begin_layout Enumerate
2181 Okay, you didn't get any error messages, but your output looks awful.
2182 If you have a table or figure that's too wide or long for the page, you
2184 \begin_inset Separator parbreak
2191 \begin_layout Enumerate
2192 rescale the figure so it fits.
2195 \begin_layout Enumerate
2196 trim down the table so it fits.
2200 \begin_layout Enumerate
2201 If something else is wrong with the output, and you didn't try to pull anything
2202 fancy or kludge the fine-tuning options, we're not sure what's wrong.
2205 \begin_layout Standard
2206 If all this doesn't help—well, then
2210 you might have found a bug in \SpecialChar LyX
2215 \begin_layout Chapter
2219 \begin_layout Section
2220 Customizing Bibliographies with Bib\SpecialChar TeX
2224 \begin_layout Standard
2225 The most basic information about how to use Bib\SpecialChar TeX
2226 with \SpecialChar LyX
2230 Bibliography databases (Bib\SpecialChar TeX
2238 The following subsections explain special bibliography features supported
2243 \begin_layout Subsection
2244 Alternative Citation Styles
2247 \begin_layout Standard
2248 Standard Bib\SpecialChar TeX
2250 \begin_inset space \thinspace{}
2254 \begin_inset space \space{}
2258 \begin_inset Quotes eld
2262 \begin_inset Quotes erd
2265 ) to refer to a cited work.
2266 However, in many scientific disciplines, other citation styles are in use.
2267 The most common one is the author-year style (e.
2268 \begin_inset space \thinspace{}
2272 \begin_inset space \space{}
2276 \begin_inset Quotes eld
2280 \begin_inset Quotes erd
2285 supports two packages that provide this style,
2286 \begin_inset Flex Code
2289 \begin_layout Plain Layout
2296 \begin_inset Flex Code
2299 \begin_layout Plain Layout
2306 Both packages have their pros and cons, which cannot be listed in detail.
2307 If you only want to have simple author-year (or author-numerical) style,
2308 or if you want to use one of the countless style files for
2309 \begin_inset Flex Code
2312 \begin_layout Plain Layout
2318 , then the established
2319 \begin_inset Flex Code
2322 \begin_layout Plain Layout
2328 package is probably your choice.
2329 If you need special features like short title references, ibidem etc., you
2331 \begin_inset Flex Code
2334 \begin_layout Plain Layout
2343 \begin_layout Standard
2344 The handling of both packages in \SpecialChar LyX
2345 is basically the same.
2347 \begin_inset Flex Noun
2350 \begin_layout Plain Layout
2351 Document\SpecialChar menuseparator
2358 \begin_inset Flex Noun
2361 \begin_layout Plain Layout
2368 \begin_inset Flex Noun
2371 \begin_layout Plain Layout
2378 \begin_inset Flex Noun
2381 \begin_layout Plain Layout
2388 With both packages, you will get some extra features in the citation dialog
2389 and you can select the style of the reference (
2390 \begin_inset Quotes eld
2394 \begin_inset Quotes erd
2398 \begin_inset Quotes eld
2402 \begin_inset Quotes erd
2406 \begin_inset Quotes eld
2410 \begin_inset Quotes erd
2414 \begin_inset Quotes eld
2418 \begin_inset Quotes erd
2422 Note that both packages need specifically designed style files.
2423 They both ship their own, but there are lots of additional style files,
2424 and there is even an interactive style file builder
2428 \begin_layout Plain Layout
2430 \begin_inset Flex URL
2433 \begin_layout Plain Layout
2435 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2446 \begin_inset Flex Code
2449 \begin_layout Plain Layout
2458 \begin_layout Subsection
2459 Sectioned Bibliographies
2462 \begin_layout Standard
2463 Sometimes you might need to divide your bibliography into several sections.
2464 If you are for instance a historian, the possibility to separate sources
2465 and scientific works is most likely a
2466 \begin_inset Quotes eld
2470 \begin_inset Quotes erd
2474 Unfortunately, Bib\SpecialChar TeX
2475 itself does not allow you to do this.
2476 But with the help of some \SpecialChar LaTeX
2477 packages, Bib\SpecialChar TeX
2478 can be extended to fit your needs.
2481 \begin_layout Standard
2483 provides native support for one of these packages,
2491 \begin_layout Plain Layout
2493 \begin_inset Flex URL
2496 \begin_layout Plain Layout
2498 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2508 The advantage of this package (compared to other packages like
2512 ) is that you don't need to define new citation commands.
2513 Instead, you need to prepare different bibliographic databases which include
2514 the entries for the different sections of the bibliography.
2515 For example: If you want to divide your bibliography into the sections
2517 \begin_inset Quotes eld
2521 \begin_inset Quotes erd
2525 \begin_inset Quotes eld
2529 \begin_inset Quotes erd
2532 , you first need to create two bibliographic databases, e.
2533 \begin_inset space \thinspace{}
2537 \begin_inset space \space{}
2541 \begin_inset Flex Code
2544 \begin_layout Plain Layout
2551 \begin_inset Flex Code
2554 \begin_layout Plain Layout
2564 \begin_layout Standard
2566 \begin_inset Flex Noun
2569 \begin_layout Plain Layout
2570 Document\SpecialChar menuseparator
2577 \begin_inset Flex Noun
2580 \begin_layout Plain Layout
2587 \begin_inset Flex Noun
2590 \begin_layout Plain Layout
2591 Sectioned bibliography
2597 Now you can insert multiple Bib\SpecialChar TeX
2598 bibliographies, one for each section of
2600 Returning to our example: Insert the Bib\SpecialChar TeX
2602 \begin_inset Flex Code
2605 \begin_layout Plain Layout
2611 and a second one for the database
2612 \begin_inset Flex Code
2615 \begin_layout Plain Layout
2622 You are free to use the same or different styles for each section.
2623 Additionally, you can choose if the bibliography section should contain
2625 \begin_inset Quotes eld
2628 all cited references
2629 \begin_inset Quotes erd
2632 of the specified database(s) (which is the default),
2633 \begin_inset Quotes eld
2636 all uncited references
2637 \begin_inset Quotes erd
2641 \begin_inset Quotes eld
2645 \begin_inset Quotes erd
2649 This might be useful if you would like to separate your bibliography into
2651 \begin_inset Quotes eld
2655 \begin_inset Quotes erd
2659 \begin_inset Quotes eld
2663 \begin_inset Quotes erd
2667 \begin_inset Quotes eld
2671 \begin_inset Quotes erd
2675 The titles for the sections can be added as ordinary sections or subsections.
2677 \begin_inset Flex Code
2680 \begin_layout Plain Layout
2686 removes the bibliography title, you have to manually re-add that, too (as
2687 a chapter* or section*, for instance).
2690 \begin_layout Subsection
2691 Multiple Bibliographies
2694 \begin_layout Standard
2695 Multiple bibliographies, e.
2696 \begin_inset space \thinspace{}
2700 \begin_inset space \space{}
2703 a bibliography for each section or chapter of the document, are not supported
2704 by Bib\SpecialChar TeX
2707 \begin_inset Flex Code
2710 \begin_layout Plain Layout
2716 package, which is used for the creation of sectioned bibliographies in
2718 (see the previous section), provides an easy way to solve this task, if
2719 you are willing to use some
2720 \begin_inset Flex Noun
2723 \begin_layout Plain Layout
2731 \begin_inset space ~
2735 \begin_inset CommandInset ref
2737 reference "sec:Inserting-TeX-Code"
2745 \begin_layout Plain Layout
2746 An alternative approach is to use the
2747 \begin_inset Flex Code
2750 \begin_layout Plain Layout
2757 \begin_inset Flex Code
2760 \begin_layout Plain Layout
2766 package, respectively.
2774 \begin_layout Standard
2776 \begin_inset Flex Noun
2779 \begin_layout Plain Layout
2780 Document\SpecialChar menuseparator
2787 \begin_inset Flex Noun
2790 \begin_layout Plain Layout
2797 \begin_inset Flex Noun
2800 \begin_layout Plain Layout
2801 Sectioned bibliography
2807 In the document, you have to enclose the sections, which shall contain
2808 their own bibliography (including the Bib\SpecialChar TeX
2809 bibliography itself), between
2811 \begin_inset Flex Code
2814 \begin_layout Plain Layout
2823 \begin_inset Flex Code
2826 \begin_layout Plain Layout
2834 (those commands have to be inserted as \SpecialChar TeX
2836 The bibliography will contain all references that have been cited in the
2838 \begin_inset Flex Code
2841 \begin_layout Plain Layout
2852 If you are using this approach, then every citation reference has to be
2854 \begin_inset Flex Code
2857 \begin_layout Plain Layout
2865 \begin_inset Flex Code
2868 \begin_layout Plain Layout
2877 \begin_layout Section
2881 \begin_layout Subsection
2885 \begin_layout Standard
2886 When you are working on a large file with many sections, it is often convenient
2887 to break up the document into several files, or perhaps you have something
2888 where a table may change from time to time, but the preceding text does
2890 In these cases, you should seriously consider using multipart documents.
2891 For example, scientific papers often have five major sections: the introduction
2892 , observations, results, discussion, and conclusion.
2893 Each of these could be its own separate \SpecialChar LyX
2895 \begin_inset Quotes eld
2899 \begin_inset Quotes erd
2902 file which contains the title, authors, abstract, references, etc., plus
2903 the five included files.
2904 It is important to note that each of these files is a full \SpecialChar LyX
2906 can be formatted and printed on its own, as well as included in a master
2908 Each of these files must have the same document class, however—don't attempt
2909 to mix book classes with article classes.
2910 You may also include \SpecialChar LaTeX
2911 files; however, these files must not have their own
2913 \begin_inset space \thinspace{}
2917 \begin_inset space \space{}
2920 everything up to and including the
2921 \begin_inset Flex Code
2924 \begin_layout Plain Layout
2933 \begin_inset Flex Code
2936 \begin_layout Plain Layout
2944 line must be deleted) or else errors will be generated when you try to
2948 \begin_layout Standard
2950 allows you to include files quite easily with
2951 \begin_inset Flex Noun
2954 \begin_layout Plain Layout
2955 Insert\SpecialChar menuseparator
2957 \begin_inset space ~
2966 When you click on this selection a small box is inserted into the file
2967 at the current cursor location.
2968 Clicking on the box raises a dialog which allows you to select the file
2969 to be included, and the method of its inclusion.
2973 \begin_layout Standard
2974 The file selection box should by now be obvious.
2975 The three inclusion methods are
2976 \begin_inset Quotes eld
2980 \begin_inset Quotes erd
2984 \begin_inset Quotes eld
2988 \begin_inset Quotes erd
2992 \begin_inset Quotes eld
2996 \begin_inset Quotes erd
3000 The difference between
3001 \begin_inset Quotes eld
3005 \begin_inset Quotes erd
3009 \begin_inset Quotes eld
3013 \begin_inset Quotes erd
3016 is really only meaningful to \SpecialChar LaTeX
3017 perts, but the practical difference is that
3019 \begin_inset Quotes eld
3023 \begin_inset Quotes erd
3026 are typeset beginning on a new page, while files that are
3027 \begin_inset Quotes eld
3031 \begin_inset Quotes erd
3034 are typeset starting on the current page.
3037 \begin_layout Standard
3038 Generally, the master file is converted into a full \SpecialChar LaTeX
3039 file before typesetting,
3040 while the included files are converted to \SpecialChar LaTeX
3041 files that do not have all the
3042 preamble information.
3045 \begin_layout Standard
3047 \begin_inset Quotes eld
3051 \begin_inset Quotes erd
3054 included file allows you to include a file typeset exactly as it appears
3056 \begin_inset space \thinspace{}
3060 \begin_inset space \space{}
3064 \begin_inset Flex Code
3067 \begin_layout Plain Layout
3073 mode, with the characters set in a fixed-width typewriter font.
3074 Normally, spaces in this file are invisible, though two consecutive spaces
3075 are conserved, unlike \SpecialChar LyX
3076 's normal treatment of spaces.
3077 However, setting the
3078 \begin_inset Flex Noun
3081 \begin_layout Plain Layout
3083 \begin_inset space ~
3087 \begin_inset space ~
3091 \begin_inset space ~
3099 checkbox typesets a mark to unambiguously define the presence of a space.
3103 \begin_layout Subsection
3104 Cross-References Between Files
3107 \begin_layout Standard
3108 \begin_inset Box Shadowbox
3118 height_special "totalheight"
3123 backgroundcolor "none"
3126 \begin_layout Plain Layout
3127 This section is somewhat out of date.
3128 Need to describe default master documents and how children are opened when
3138 \begin_layout Standard
3139 It is possible to set up cross-references between the different files.
3140 First, open all the files in question: let's call them A and B in a two
3141 file example, where B is included in A.
3142 Let's say you insert a label in A, then want to reference it in B.
3143 Open the cross-reference dialog whilst in document B, and you can select
3145 \begin_inset Quotes eld
3149 \begin_inset Quotes erd
3155 \begin_layout Subsection
3156 Bibliography Lists in all Subdocuments
3159 \begin_layout Standard
3160 \begin_inset Box Frameless
3170 height_special "totalheight"
3175 backgroundcolor "none"
3178 \begin_layout Plain Layout
3179 This section also needs updating.
3180 There is now material about this on the wiki, and it could be copied here.
3188 \begin_layout Standard
3189 Copy the bibliography list with all entries to all subdocuments and transform
3191 This way \SpecialChar LyX
3193 \begin_inset Flex Code
3196 \begin_layout Plain Layout
3202 -files and you can easily insert references without making the bibliography
3206 \begin_layout Standard
3207 As the bibliography list is in a comment, \SpecialChar LaTeX
3208 won't use it and the references
3209 will look like this: [?], instead of like this: [1].
3210 One solution is to use the \SpecialChar LaTeX
3212 \begin_inset Flex Code
3215 \begin_layout Plain Layout
3221 that will only include comments by processing the files separately.
3222 To do this, add in the \SpecialChar LaTeX
3223 preamble of every subdocument the following:
3226 \begin_layout LyX-Code
3232 \begin_layout LyX-Code
3235 includecomment{comment}
3238 \begin_layout Standard
3240 \begin_inset Flex URL
3243 \begin_layout Plain Layout
3245 http://wiki.lyx.org/FAQ/Unsorted#toc31
3253 \begin_layout Section
3258 \begin_layout Standard
3259 Users sometimes need to be able to
3260 \begin_inset Quotes eld
3264 \begin_inset Quotes erd
3268 file together with all the images (and other files) on which it depends,
3269 either for sending to a publisher or for sharing with a co-author.
3271 2.0 includes a Python script (
3272 \begin_inset Flex Code
3275 \begin_layout Plain Layout
3281 ) that automates this process.
3282 To use it, you must have either the
3283 \begin_inset Flex Code
3286 \begin_layout Plain Layout
3293 \begin_inset Flex Code
3296 \begin_layout Plain Layout
3302 python modules installed on your system.
3303 By default, the script prefers the
3304 \begin_inset Flex Code
3307 \begin_layout Plain Layout
3314 \begin_inset Flex Code
3317 \begin_layout Plain Layout
3323 format on Unix-like systems and the
3324 \begin_inset Flex Code
3327 \begin_layout Plain Layout
3336 \begin_layout Standard
3338 's configuration process will set the script up to export a `\SpecialChar LyX
3340 and this format will then be available under
3341 \begin_inset Flex Code
3344 \begin_layout Plain Layout
3345 File\SpecialChar menuseparator
3354 \begin_layout Standard
3355 Independently of the platform, the generation of a particular archive format
3356 can be forced by adding either the
3357 \begin_inset Flex Code
3360 \begin_layout Plain Layout
3367 \begin_inset Flex Code
3370 \begin_layout Plain Layout
3377 \begin_inset Flex Code
3380 \begin_layout Plain Layout
3387 \begin_inset Flex Code
3390 \begin_layout Plain Layout
3396 format) switch to the
3397 \begin_inset Flex Code
3400 \begin_layout Plain Layout
3402 \SpecialChar menuseparator
3410 \begin_inset Flex Code
3413 \begin_layout Plain Layout
3414 Tools\SpecialChar menuseparator
3415 Preferences\SpecialChar menuseparator
3416 File Handling\SpecialChar menuseparator
3423 (Make sure you add the switch after the script name, not before it.)
3426 \begin_layout Section
3427 Fancy Headers and Footers
3430 \begin_layout Standard
3431 The default page layout is rather plain; for an
3432 \begin_inset Flex Code
3435 \begin_layout Plain Layout
3441 document class, all you get is a centered page number at the bottom of
3443 This document uses KOMA-script's book class, so it appears to be a bit
3445 But to really put on a show, you need to set the document page style to
3447 \begin_inset Quotes eld
3451 \begin_inset Quotes erd
3454 , as mentioned in the
3459 This section describes the \SpecialChar LaTeX
3460 code you need to insert in your \SpecialChar LaTeX
3462 order to get the desired effects.
3465 \begin_layout Standard
3466 For more information on fancy headers, see the
3467 \begin_inset Flex Code
3470 \begin_layout Plain Layout
3476 package documentation.
3478 \begin_inset Flex URL
3481 \begin_layout Plain Layout
3483 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
3491 \begin_layout Standard
3492 The page header is divided into three fields, not surprisingly labeled
3493 \begin_inset Quotes eld
3497 \begin_inset Quotes erd
3501 \begin_inset Quotes eld
3505 \begin_inset Quotes erd
3509 \begin_inset Quotes eld
3513 \begin_inset Quotes erd
3517 The footer is also divided into these three fields.
3518 The \SpecialChar LaTeX
3519 commands to set these fields in the simplest manner are
3520 \begin_inset Flex Code
3523 \begin_layout Plain Layout
3532 \begin_inset Flex Code
3535 \begin_layout Plain Layout
3544 \begin_inset Flex Code
3547 \begin_layout Plain Layout
3556 \begin_inset Flex Code
3559 \begin_layout Plain Layout
3568 Suppose you wish to put your name in the upper left hand corner of each
3570 Simply insert the following command in the preamble:
3573 \begin_layout Standard
3582 \begin_layout Standard
3583 You will now see your name in the upper left.
3584 If a field has a default entry that you would like to get rid of (often
3585 the page number appears in the central footer) simply include a command
3586 with a blank argument, e.
3587 \begin_inset space \thinspace{}
3593 \begin_layout Standard
3601 \begin_layout Standard
3602 Let's get really fancy: lets put the section number with the word
3603 \begin_inset Quotes eld
3607 \begin_inset Quotes erd
3611 \begin_inset space \thinspace{}
3615 \begin_inset space \space{}
3618 Section 3) in the upper left, the page number (e.
3619 \begin_inset space \thinspace{}
3623 \begin_inset space \space{}
3626 Page 4) in the upper right, your name in the lower left, and the date in
3628 The following commands should now appear in the preamble:
3631 \begin_layout Standard
3641 \begin_layout Standard
3649 \begin_layout Standard
3659 \begin_layout Standard
3668 \begin_layout Standard
3676 \begin_layout Standard
3686 \begin_layout Standard
3688 \begin_inset Flex Code
3691 \begin_layout Plain Layout
3700 \begin_inset Flex Code
3703 \begin_layout Plain Layout
3711 access \SpecialChar LaTeX
3712 's section and page counters, and so print out the current section
3715 \begin_inset Flex Code
3718 \begin_layout Plain Layout
3726 simply prints out today's date.
3729 \begin_layout Standard
3730 The thicknesses of the horizontal rules drawn beneath the header and above
3731 the footer can also be modified.
3732 If you don't want one of the rules, set its thickness to 0.
3733 The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
3739 \begin_inset Flex Code
3742 \begin_layout Plain Layout
3747 headrulewidth}{0.4pt}
3753 \begin_inset Flex Code
3756 \begin_layout Plain Layout
3761 footrulewidth}{0.4pt}
3766 to set the thicknesses.
3769 \begin_layout Standard
3770 You can switch the header/footer settings on and off for individual pages
3772 \begin_inset Flex Code
3775 \begin_layout Plain Layout
3778 thispagestyle{empty}
3784 \begin_inset Flex Code
3787 \begin_layout Plain Layout
3790 thispagestyle{plain}
3796 \begin_inset Flex Code
3799 \begin_layout Plain Layout
3802 thispagestyle{fancy}
3808 Simply insert them in the text on the page you want changed and mark them
3811 In fact, title pages are marked as plain by default, while following pages
3812 are marked fancy when using the global fancy setting.
3815 \begin_layout Standard
3816 As a final example, it is possible to include an image in the header or
3818 Suppose you want to put a company logo in the upper lefthand corner.
3819 You might try something like
3822 \begin_layout Standard
3831 includegraphics{logo.eps}}}
3834 \begin_layout Standard
3836 (you may need to preface this with
3837 \begin_inset Flex Code
3840 \begin_layout Plain Layout
3844 usepackage{graphics}
3849 if you don't include graphics elsewhere in your document).
3852 \begin_layout Section
3853 Itemize Bullet Selection
3854 \begin_inset CommandInset label
3863 \begin_layout Standard
3869 \begin_layout Subsection
3873 \begin_layout Standard
3875 provides 216 bullet shapes that can be accessed from a simple dialog.
3876 Using this dialog you can easily specify what bullet shape to use at each
3877 level of an itemized list.
3878 These settings are document-wide so you won't be able to specify different
3879 sets of bullets for different paragraphs.
3883 \begin_layout Plain Layout
3884 Well, actually you can but you'll have to do it by hand.
3892 \begin_layout Subsection
3896 \begin_layout Standard
3897 Open the dialog by selecting the
3898 \begin_inset Flex Noun
3901 \begin_layout Plain Layout
3902 Document\SpecialChar menuseparator
3908 menu item and then select the
3909 \begin_inset Flex Noun
3912 \begin_layout Plain Layout
3921 \begin_layout Standard
3922 The dialog provides you with a table of bullet shapes.
3923 A column of buttons on the left of the table provides access to the six
3924 different panels of bullet shapes.
3925 The row of buttons across the top is used to select which bullet depth
3927 A text entry under the table shows the currently selected bullet shape's
3929 equivalent and this can be edited if desired.
3930 If you do modify the text you will also need to specify any needed packages
3931 in the \SpecialChar LaTeX
3935 \begin_layout Standard
3936 The six panels are divided up by the packages they require.
3937 The following table shows the mappings from button name to \SpecialChar LaTeX
3939 \begin_inset Separator parbreak
3945 \begin_layout Standard
3947 \begin_inset Tabular
3948 <lyxtabular version="3" rows="7" columns="2">
3949 <features tabularvalignment="middle">
3950 <column alignment="center" valignment="top" width="0pt">
3951 <column alignment="center" valignment="top" width="0pt">
3953 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3956 \begin_layout Plain Layout
3971 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3974 \begin_layout Plain Layout
3991 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3994 \begin_layout Plain Layout
4009 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4012 \begin_layout Plain Layout
4021 base \SpecialChar LaTeX
4029 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4032 \begin_layout Plain Layout
4047 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4050 \begin_layout Plain Layout
4067 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4070 \begin_layout Plain Layout
4085 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4088 \begin_layout Plain Layout
4105 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4108 \begin_layout Plain Layout
4123 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4126 \begin_layout Plain Layout
4143 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4146 \begin_layout Plain Layout
4161 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4164 \begin_layout Plain Layout
4181 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4184 \begin_layout Plain Layout
4199 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4202 \begin_layout Plain Layout
4225 \begin_layout Standard
4227 doesn't stop you using bullets from packages you don't have.
4228 If you get errors from \SpecialChar LaTeX
4229 when you try to view or print the file, then it
4230 is likely you are missing a package.
4234 \begin_layout Plain Layout
4236 doesn't restrict your use since you may be editing locally and exporting
4245 \begin_layout Subsection
4249 \begin_layout Standard
4250 Select which bullet depth you want to change then select the bullet shape
4252 Any changes will not be visible in \SpecialChar LyX
4253 , but are visible when viewing the document.
4256 \begin_layout Standard
4257 You can reset a bullet shape to the default simply by clicking your right
4258 mouse button on the appropriate bullet depth button.
4262 \begin_layout Plain Layout
4267 want to have multiple sets of paragraphs with different sets of bullets
4268 in each, then you're going to have to get your hands dirty with \SpecialChar TeX
4270 The bullet selection dialog can help though because it provides you with
4271 the \SpecialChar LaTeX
4272 code for a wide range of bullet shapes.
4273 To make your own custom paragraphs you have the following options:
4276 \begin_layout Plain Layout
4280 \begin_layout Plain Layout
4296 \begin_layout Plain Layout
4300 \begin_layout Plain Layout
4322 \begin_layout Itemize
4323 Use the \SpecialChar LaTeX
4325 \begin_inset Flex Code
4328 \begin_layout Plain Layout
4336 to specify a new bullet shape for a given depth.
4337 You'll also need to save the current bullet shape so you can restore it
4339 In this itemized list the following \SpecialChar LaTeX
4340 code was used to change the bullet
4341 used for the first depth.
4342 \begin_inset Separator parbreak
4349 \begin_layout LyX-Code
4359 \begin_layout LyX-Code
4376 \begin_layout Itemize
4377 Note that the itemize depth is specified in Roman numerals as part of the
4387 \begin_layout Itemize
4391 \begin_layout Plain Layout
4404 Specify each individual entry by starting each item with the bullet shape
4405 enclosed in square brackets and set as
4406 \begin_inset Flex Noun
4409 \begin_layout Plain Layout
4417 For example, this item was started with
4418 \begin_inset Flex Code
4421 \begin_layout Plain Layout
4436 \begin_layout Plain Layout
4440 \begin_layout Plain Layout
4456 \begin_layout Plain Layout
4457 You'll also need to revert the labelitem back to its previous setting for
4458 the global bullet shape settings to remain in effect.
4459 The way used here was:
4462 \begin_layout LyX-Code
4477 \begin_layout Chapter
4479 and the World Wide Web
4482 \begin_layout Standard
4484 has long supported the export of documents to various web-friendly formats,
4486 Before verson 2.0, however, HTML export was always accomplished by the use
4487 of external converters.
4491 \begin_layout Plain Layout
4492 For details on the use of external converters with \SpecialChar LyX
4497 section of the Customization manual.
4502 These fall into two large groups: there are converters that use \SpecialChar LaTeX
4504 intermediate format, such as
4505 \begin_inset Flex Code
4508 \begin_layout Plain Layout
4515 \begin_inset Flex Code
4518 \begin_layout Plain Layout
4525 \begin_inset Flex Code
4528 \begin_layout Plain Layout
4534 , relying upon \SpecialChar LyX
4535 to produce the \SpecialChar LaTeX
4536 ; and there is a converter that works directly
4539 \begin_inset Flex Code
4542 \begin_layout Plain Layout
4550 All of these have different advantages and disadvantages.
4554 \begin_layout Standard
4555 The \SpecialChar LaTeX
4556 -based converters have the advantage that, in principle, they know everythin
4557 g about the exported document that \SpecialChar LaTeX
4559 Such converters do not care, for example, if a certain block of code was
4560 produced by \SpecialChar LyX
4561 or was Evil Red Text.
4562 These converters know about
4563 \begin_inset Flex Code
4566 \begin_layout Plain Layout
4572 files, counters, and references, and can often make use of the
4573 \begin_inset Flex Code
4576 \begin_layout Plain Layout
4582 files generated by Bib\SpecialChar TeX
4584 On the other hand, \SpecialChar LaTeX
4585 is a very hard language to parse—it is sometimes said
4586 that only \SpecialChar TeX
4587 itself understands \SpecialChar TeX
4588 —and \SpecialChar LaTeX
4589 -based converters will often choke on
4590 what seem to be quite simple constructs; complex ones can throw them completely
4591 , and as of this writing, for example, the
4595 manual will not export with
4596 \begin_inset Flex Code
4599 \begin_layout Plain Layout
4605 , though the others will.
4606 The other issue concerns how math is handled.
4607 These converters typically convert the formulae into little pictures that
4608 are then linked from the HTML document.
4609 Since these are actually generated by \SpecialChar LaTeX
4610 , they are accurate.
4611 But they do not scale well, and just getting them to look as if they are
4612 actually meant to be in your document—so that the font sizes seem to be
4613 roughly the same—can be a challenge.
4616 \begin_layout Standard
4618 \begin_inset Flex Code
4621 \begin_layout Plain Layout
4629 \begin_inset CommandInset href
4631 name "http://elyxer.nongnu.org/"
4632 target "http://elyxer.nongnu.org/"
4636 ) solves some of these problems.
4637 In particular, the formulae it produces scale perfectly, since it renders
4638 math using a combination of HTML and CSS rather than converting the formulae
4640 But even moderately complex formula are rendered less well than with
4641 \begin_inset Flex Code
4644 \begin_layout Plain Layout
4650 ; this reflects the limitations of HTML.
4654 \begin_layout Plain Layout
4656 \begin_inset Flex Code
4659 \begin_layout Plain Layout
4666 can also use jsMath and MathJax for equations, but this setting is only
4667 available globally and requires one to have access to a server that runs
4673 More importantly (as of version 1.1.1, at least),
4674 \begin_inset Flex Code
4677 \begin_layout Plain Layout
4684 has limited support for math macros and no support for user-defined paragraph
4685 or character styles.
4686 These limitations make
4687 \begin_inset Flex Code
4690 \begin_layout Plain Layout
4697 unsuitable for many of the documents \SpecialChar LyX
4699 In principle, of course, these problems could be solved, but the \SpecialChar LyX
4701 have decided to follow a different path and have made \SpecialChar LyX
4703 writing XHTML, just as it is capable of writing \SpecialChar LaTeX
4704 , DocBook, and plaintext.
4707 \begin_layout Standard
4708 As of this writing, XHTML output remains under development and should probably
4710 \begin_inset Quotes eld
4714 \begin_inset Quotes erd
4721 \begin_layout Plain Layout
4723 \begin_inset Flex Code
4726 \begin_layout Plain Layout
4727 development/HTML.notes
4732 , which can be found in the \SpecialChar LyX
4734 \begin_inset CommandInset href
4736 name "accessed online"
4737 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
4741 , usually contains up-to-date information about the state of XHTML output.
4742 See also the list of XHTML bugs on
4743 \begin_inset CommandInset href
4745 name "the bug tracker"
4746 target "http://www.lyx.org/trac/query?status=reopened&status=assigned&status=new&max=0&component=xhtml+export&order=id&col=id&col=summary&col=reporter&col=keywords&keywords=%21%7Efixedintrunk&desc=1"
4755 Still, the developers have chosen this approach because it has several
4756 potential advantages over the other two.
4759 \begin_layout Standard
4760 These advantages are primarily due to the fact that the XHTML output routines,
4761 since they are part of \SpecialChar LyX
4762 , know everything \SpecialChar LyX
4763 knows about the document being
4768 \begin_layout Plain Layout
4769 Another advantage is that, since these routines are internal to \SpecialChar LyX
4771 immune to changes in \SpecialChar LyX
4772 's file format, or to changes in the semantics of
4778 So they know about the table of contents (as displayed in the outline),
4779 about the counters associated with different paragraph styles, and about
4780 user-defined styles.
4781 The XHTML output routines know what \SpecialChar LyX
4782 knows about internationalization,
4783 too, so they will output
4784 \begin_inset Quotes eld
4788 \begin_inset Quotes erd
4792 \begin_inset Quotes eld
4800 \begin_inset Quotes erd
4803 , depending upon the language in effect at the time.
4807 \begin_layout Standard
4808 Quite generally, the output routines know what \SpecialChar LyX
4809 knows about document layout,
4810 that is, about how the document is to be rendered on screen.
4811 We use this information when we output the document as XHTML.
4812 In particular, \SpecialChar LyX
4817 generates CSS style information corresponding to the layout information
4818 it uses to render the document on screen: if section headings are supposed
4819 to be sans-serif and bold as seen in \SpecialChar LyX
4820 , then (by default) they will be sans-seri
4821 f and bold when viewed in a web browser, too.
4822 And this is true not just for pre-defined styles, like Section, but for
4823 any style, including user-defined styles.
4824 Indeed, the XHTML output routines make no distinction between user-defined
4825 paragraph and character styles and \SpecialChar LyX
4826 's own pre-defined styles: in each case,
4827 everything \SpecialChar LyX
4828 knows about the styles is contained in the layout files.
4829 And much the same is true as regards pre-defined textual insets, such as
4830 footnotes, and various custom insets.
4834 \begin_layout Standard
4835 The result is that XHTML output can be customized and extended in exactly
4836 the same way \SpecialChar LaTeX
4837 output can be customized and extended: through layout files
4839 See chapter five of the
4843 manual for the details.
4846 \begin_layout Standard
4847 The remainder of this chapter contains more detailed information on XHTML
4848 output, its limitations, and ways to work around those limitations.
4851 \begin_layout Section
4852 Math Output in XHTML
4855 \begin_layout Standard
4857 offers four choices for how math is rendered.
4858 These have various advantages and disadvantages:
4861 \begin_layout Itemize
4863 \begin_inset Newline newline
4866 MathML is a dialect of XML designed specifically for mathematics on the
4867 web, and it typically renders very well in browsers that support it.
4868 The disadvantage is that not all browsers support MathML, and support is
4869 not complete even in the Gecko-based browsers, such as Firefox.
4870 \begin_inset Newline newline
4874 is unable to render a formula as MathML—for example, if the formula
4876 \begin_inset Flex Code
4879 \begin_layout Plain Layout
4885 package or ERT—then it will instead output the formula as an image.
4889 \begin_layout Itemize
4891 \begin_inset Newline newline
4895 \begin_inset Flex Code
4898 \begin_layout Plain Layout
4904 outputs math as HTML, styled by CSS.
4908 \begin_layout Plain Layout
4910 has borrowed some of the CSS for its HTML output from
4911 \begin_inset Flex Code
4914 \begin_layout Plain Layout
4925 For simple formulae, this can work quite well, though with more complicated
4926 formulae it tends to break down.
4927 Still, this method has the advantage that it is very widely supported and
4928 so it may be appropriate for documents that contain only a little, fairly
4930 \begin_inset Newline newline
4933 If Lyx is unable to render a formula as HTML—for example, if the formula
4935 \begin_inset Flex Code
4938 \begin_layout Plain Layout
4944 package or ERT—then it will instead output the formula as an image.
4948 \begin_layout Itemize
4950 \begin_inset Newline newline
4954 \begin_inset Flex Code
4957 \begin_layout Plain Layout
4964 will output formulae as images, the very same images, in fact, that are
4965 used for instant preview.
4969 \begin_layout Plain Layout
4970 Instant preview does
4974 have to be on for images to be output, however.
4979 The advantage to this method is that the images are simply generated by
4981 , so they are very accurate.
4982 The disadvantage, as mentioned earlier, is that these are bitmapped images,
4983 so they do not scale terribly well, and one cannot copy them, etc.
4984 (As of this writing, there are also problems about equation numbering.
4986 \begin_inset CommandInset href
4989 target "http://www.lyx.org/trac/ticket/6894"
4994 \begin_inset Newline newline
4997 The size of the images can be controlled by setting the
4998 \begin_inset Quotes eld
5002 \begin_inset Quotes erd
5006 \begin_inset Flex Noun
5009 \begin_layout Plain Layout
5010 Document\SpecialChar menuseparator
5011 Settings\SpecialChar menuseparator
5021 \begin_layout Plain Layout
5022 For those who want to know, this controls the resolution of the image in
5023 dots per inch and is based upon a default of 75 dpi.
5029 \begin_inset Newline newline
5033 for some reason fails to create an image for a formula (e.g., if a required
5035 package is not installed), then it will fall back to outputing the raw
5040 \begin_layout Itemize
5043 \begin_inset Newline newline
5046 Finally, \SpecialChar LyX
5047 will happily output math as \SpecialChar LaTeX
5049 As well as being the output of last resort, this method can be used with
5051 \begin_inset CommandInset href
5054 target "http://www.math.union.edu/~dpvc/jsMath/"
5058 , which uses JavaScript to render \SpecialChar LaTeX
5059 embedded in HTML documents.
5061 wraps the \SpecialChar LaTeX
5063 \begin_inset Flex Code
5066 \begin_layout Plain Layout
5072 (for inline formulas) or
5073 \begin_inset Flex Code
5076 \begin_layout Plain Layout
5082 (for displayed formulas) with
5083 \begin_inset Flex Code
5086 \begin_layout Plain Layout
5092 , as is required for jsMath.
5095 \begin_layout Standard
5096 One of these output methods must be selected under
5097 \begin_inset Flex Noun
5100 \begin_layout Plain Layout
5101 Document\SpecialChar menuseparator
5102 Settings\SpecialChar menuseparator
5109 By default, \SpecialChar LyX
5111 This is a document-wide setting, therefore.
5114 \begin_layout Standard
5115 Eventually, \SpecialChar LyX
5116 will offer the user the option to select an alternate output
5117 method for a particular inset, say, one that isn't being rendered very
5122 \begin_layout Plain Layout
5123 That said, since \SpecialChar LyX
5124 falls back to images if the inset contains ERT, then one
5125 can force output as an image by putting some harmless ERT into the math,
5127 \begin_inset Formula $a=b\relax$
5138 \begin_layout Section
5139 Bibliography and Citations
5142 \begin_layout Standard
5143 XHTML output fully supports bibliographies and citations.
5147 \begin_layout Standard
5148 Citation labels are generated by the same machinery that generates \SpecialChar LyX
5150 labels, so the labels will look in the output much as they do in \SpecialChar LyX
5153 If you are using numerical citations, then \SpecialChar LyX
5154 will output numerical labels,
5155 such as [1] or [17], rather than simply showing the citation key in square
5156 brackets, as it does on-screen.
5157 If you are using author-year citations, then \SpecialChar LyX
5158 will add lowercase letters
5159 to the years, just as Bib\SpecialChar TeX
5160 does, if it finds more than one citation for
5161 a given author-year combination.
5162 The labels will be printed with the bibliography entries.
5163 Note that there is, at present, no way to customize the appearance of the
5164 labels, for example, to choose between square brackets and parentheses.
5167 \begin_layout Standard
5168 Bibliography output is handled by the same machinery that handles the presentati
5169 on of reference information in the citation dialog, so you will see in the
5170 XHTML output pretty much what you would see if you were to look at a given
5171 entry in the citation dialog.
5172 The formatting can be customized in your layout file or, preferably, in
5178 manual for the details.
5181 \begin_layout Standard
5182 The main defect at present is that cross-referenced information is printed
5183 with every entry with which it is associated.
5184 So you can see things like this:
5189 \begin_inset Quotes eld
5192 Context and Logical Form
5193 \begin_inset Quotes erd
5198 Language in Context: Selected Essays
5200 (Oxford: Oxford University Press, 2007), pp.
5206 \begin_inset Quotes eld
5209 Semantics in Context
5210 \begin_inset Quotes erd
5215 Language in Context: Selected Essays
5217 (Oxford: Oxford University Press, 2007), pp.
5221 \begin_layout Standard
5222 This should be fixed before long.
5225 \begin_layout Standard
5226 There is no support at present for sectioned bibliographies.
5227 If you have multiple bibliographies, then \SpecialChar LyX
5228 will print the same bibliography
5232 \begin_layout Section
5236 \begin_layout Standard
5238 will happily export indexes as XHTML, but with certain limitations at the
5242 \begin_layout Standard
5243 Index export will be most reliable when you do not attempt to use the fancy
5244 constructs that are described in the section on indexes in the
5252 \begin_layout Plain Layout
5253 The main issue here is that \SpecialChar LyX
5254 itself does not really handle these.
5255 It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
5261 We'll describe how they are handled using the subsection headings from
5265 \begin_layout Itemize
5266 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
5267 makes an effort to support these,
5268 but the entries must be separated by
5269 \begin_inset Quotes eld
5273 \begin_inset Quotes erd
5276 , that is, there must be spaces around the exclamation point.
5277 This is because it is otherwise too difficult to check for escaped exclamation
5278 points, ones in math, and so forth.
5281 \begin_layout Itemize
5282 Page Ranges: There is no support at all for page ranges, since these make
5283 no sense with XHMTL.
5284 Instead, you will just get two index entries, one at either end.
5287 \begin_layout Itemize
5288 Cross-referencing: There is no support for cross-referencing.
5290 finds an entry containing the
5291 \begin_inset Quotes eld
5294 |see\SpecialChar ldots
5296 \begin_inset Quotes erd
5299 construct, it is just dropped, and the rest is treated as an ordinary index
5303 \begin_layout Itemize
5304 Index Entry Order: \SpecialChar LyX
5305 does support attempts to fix the sorting order.
5306 It will take what is before the first `@' it finds and use that for sorting,
5307 taking what follows the first `@' to be the actual entry.
5308 At present, \SpecialChar LyX
5309 does not check for escaped `@', so do not try to index email
5313 \begin_layout Itemize
5314 Index Entry Layout: You can format entries by using the text style dialog,
5315 or by using any other method available within \SpecialChar LyX
5317 There is no support for constructs like:
5318 \begin_inset Quotes eld
5322 \begin_inset Quotes erd
5326 Indeed, if \SpecialChar LyX
5327 finds a pipe symbol, `|', in an entry, it will delete it and
5328 everything that follows it.
5331 \begin_layout Itemize
5332 Multiple Indexes: There is no support for multiple indexes.
5333 Rather, all index entries will be printed as one large index.
5334 To avoid our printing several versions of the index, we print only the
5335 main index, so make sure you have one.
5338 \begin_layout Section
5339 Nomenclature and Glossary
5342 \begin_layout Standard
5343 There is at present no support for glossaries.
5344 Adding it would be fairly trivial, and welcome.
5347 \begin_layout Chapter
5348 The \SpecialChar LyX
5352 \begin_layout Section
5356 \begin_layout Standard
5357 The `\SpecialChar LyX
5358 server' allows other programs to talk to \SpecialChar LyX
5359 , invoke \SpecialChar LyX
5360 commands, and retrieve
5361 information about the \SpecialChar LyX
5363 This is only intended for advanced users, but they should find it useful.
5364 It is by writing to the \SpecialChar LyX
5365 server, for example, that bibliography managers,
5366 such as JabRef, are able to
5367 \begin_inset Quotes eld
5371 \begin_inset Quotes erd
5374 citations to \SpecialChar LyX
5378 \begin_layout Section
5379 Starting the \SpecialChar LyX
5383 \begin_layout Standard
5384 The \SpecialChar LyX
5385 server works through the use of a pair of named pipes.
5386 These are usually located in
5387 \begin_inset Flex Code
5390 \begin_layout Plain Layout
5396 , (except on Windows, where
5400 named pipes are special objects located in
5401 \begin_inset Flex Code
5404 \begin_layout Plain Layout
5416 ) and have the names
5417 \begin_inset Quotes eld
5421 \begin_inset Flex Code
5424 \begin_layout Plain Layout
5431 \begin_inset Quotes erd
5435 \begin_inset Quotes eld
5439 \begin_inset Flex Code
5442 \begin_layout Plain Layout
5449 \begin_inset Quotes erd
5453 External programs write into
5454 \begin_inset Flex Code
5457 \begin_layout Plain Layout
5463 and read back data from
5464 \begin_inset Flex Code
5467 \begin_layout Plain Layout
5474 The stem of the pipe names can be defined in the
5475 \begin_inset Flex Noun
5478 \begin_layout Plain Layout
5479 Tools\SpecialChar menuseparator
5486 \begin_inset Flex Code
5489 \begin_layout Plain Layout
5490 "/home/myhome/lyxpipe"
5496 \begin_inset Flex Code
5499 \begin_layout Plain Layout
5513 on Windows (where any working path instead of lyxpipe can be used, for
5515 \begin_inset Flex Code
5518 \begin_layout Plain Layout
5541 configure this manually in order for the server to start.
5544 \begin_layout Standard
5547 \begin_inset Flex Code
5550 \begin_layout Plain Layout
5557 \begin_inset Flex Code
5560 \begin_layout Plain Layout
5566 ' to create the pipes.
5567 If one of the pipes already exists, \SpecialChar LyX
5568 will assume that another \SpecialChar LyX
5570 is already running and will not start the server.
5571 On POSIX (Unix like) systems, if for some other reason, an unused
5572 \begin_inset Quotes eld
5576 \begin_inset Quotes erd
5579 pipe is left in existence when \SpecialChar LyX
5580 closes, then \SpecialChar LyX
5581 will try to delete it.
5582 If this fails for some reason, you will need to delete the pipes manually
5583 and then restart \SpecialChar LyX
5585 On Windows, pipes are deleted by the OS on program termination or crash,
5587 \begin_inset Quotes eld
5591 \begin_inset Quotes erd
5594 pipes should not be possible.
5597 \begin_layout Standard
5598 To have several \SpecialChar LyX
5599 processes with servers at the same time, you have to use
5600 different configurations, perhaps by using separate user directories, each
5602 \begin_inset Flex Code
5605 \begin_layout Plain Layout
5611 file, for each process.
5614 \begin_layout Standard
5615 If you are developing a client program, you might find it useful to enable
5616 debugging information from the \SpecialChar LyX
5618 Do this by starting \SpecialChar LyX
5620 \begin_inset Flex Code
5623 \begin_layout Plain Layout
5632 \begin_layout Standard
5633 You can find a complete example client written in C++ in the source distribution
5635 \begin_inset Flex Code
5638 \begin_layout Plain Layout
5639 development/lyxserver/server_monitor.cpp
5647 \begin_layout Standard
5648 Another useful tool is the command-line based client found in
5649 \begin_inset Flex Code
5652 \begin_layout Plain Layout
5653 src/client/lyxclient
5661 \begin_layout Section
5662 Normal communication
5665 \begin_layout Standard
5666 To issue a \SpecialChar LyX
5667 call, the client writes a line of ASCII text into the input
5669 This line has the following format:
5686 \begin_layout Description
5687 clientname is a name that the client can choose arbitrarily.
5688 Its only use is that \SpecialChar LyX
5689 will echo it if it sends an answer—so a client can
5690 dispatch results from different requesters.
5693 \begin_layout Description
5694 function is the function you want \SpecialChar LyX
5696 It is the same as the commands you'd use in the minibuffer.
5699 \begin_layout Description
5700 argument is an optional argument which is meaningful only to some functions
5702 \begin_inset Quotes eld
5706 \begin_inset Quotes erd
5709 LFUN will insert the argument as text at the cursor position).
5712 \begin_layout Standard
5713 The answer from \SpecialChar LyX
5714 will arrive in the output pipe and be of the form
5731 \begin_layout Standard
5740 are just echoed from the command request, while
5744 is more or less useful information filled according to how the command
5745 execution worked out.
5746 Some commands, such as
5747 \begin_inset Quotes eld
5751 \begin_inset Quotes erd
5754 , will return information about the internal state of \SpecialChar LyX
5756 return an empty data-response.
5757 This means that the command execution went fine.
5760 \begin_layout Standard
5761 In case of errors, the response from \SpecialChar LyX
5779 \begin_layout Standard
5784 should contain an explanation of why the command failed.
5787 \begin_layout Standard
5791 \begin_layout LyX-Code
5792 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
5793 \begin_inset Newline newline
5796 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
5797 \begin_inset Newline newline
5800 read a <~/.lyxpipe.out
5801 \begin_inset Newline newline
5807 \begin_layout Subsection
5808 AppleScript (Mac OS X)
5811 \begin_layout Standard
5812 Since \SpecialChar LyX
5813 2.1, \SpecialChar LyX
5814 supports basic interactions with AppleScript for normal communicatio
5815 n through the command run.
5816 This command takes a direct argument (the
5820 to perform) and an optional argument.
5821 It either returns the output of the function or triggers an error with
5822 the error message and code.
5825 \begin_layout Standard
5829 \begin_layout LyX-Code
5830 tell application "\SpecialChar LyX
5834 \begin_layout LyX-Code
5838 \begin_layout LyX-Code
5839 -- Stores the current file name into f
5842 \begin_layout LyX-Code
5843 set f to (run "server-get-filename" with argument "")
5846 \begin_layout LyX-Code
5847 on error the error_message number the error_number
5850 \begin_layout LyX-Code
5851 display dialog "Error: " & the error_number & ".
5855 \begin_layout LyX-Code
5856 & the error_message buttons {"OK"} default button 1
5859 \begin_layout LyX-Code
5863 \begin_layout LyX-Code
5867 \begin_layout Section
5871 \begin_layout Standard
5873 can notify clients of events going on asynchronously.
5874 Currently it will only do this if the user binds a key sequence with the
5876 \begin_inset Quotes eld
5880 \begin_inset Quotes erd
5884 The format of the string \SpecialChar LyX
5885 sends is as follows:
5889 \begin_inset Flex Code
5892 \begin_layout Plain Layout
5903 \begin_layout Standard
5908 is the printed representation of the key sequence that was actually typed
5912 \begin_layout Standard
5913 This mechanism can be used to extend \SpecialChar LyX
5914 's command set and implement macros.
5915 Bind some key sequence to
5916 \begin_inset Quotes eld
5920 \begin_inset Quotes erd
5924 Then start a client that listens on the output pipe, dispatches the command
5925 according to the sequence, and starts a function that may use \SpecialChar LyX
5928 requests to issue a command or a series of commands to \SpecialChar LyX
5932 \begin_layout Section
5933 The simple \SpecialChar LyX
5937 \begin_layout Standard
5939 implements a simple protocol that can be used for session management.
5940 All messages are of the form
5953 \begin_layout Standard
5959 \begin_inset Quotes eld
5963 \begin_inset Quotes erd
5967 \begin_inset Quotes eld
5971 \begin_inset Quotes erd
5976 \begin_inset Quotes eld
5980 \begin_inset Quotes erd
5983 is received from a client, \SpecialChar LyX
5984 will report back to inform the client that
5985 it's listening to it's messages, while
5986 \begin_inset Quotes eld
5990 \begin_inset Quotes erd
5993 sent from \SpecialChar LyX
5994 will inform clients that \SpecialChar LyX
5998 \begin_layout Section
5999 Reverse DVI/PDF search
6002 \begin_layout Standard
6003 Some DVI/PDF viewers
6007 \begin_layout Plain Layout
6008 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
6009 Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
6018 facility (also called
6023 This means that you can tell \SpecialChar LyX
6024 to put the cursor to a specific line in the
6025 document by clicking at the respective position in the DVI/PDF output.
6026 To achieve this, the viewer must be able to communicate with \SpecialChar LyX
6028 This is done via the \SpecialChar LyX
6029 server either by using the named pipe (
6033 ), or the UNIX domain socket (
6037 ) that \SpecialChar LyX
6038 creates in its temporary directory (this is the way the
6039 \begin_inset Flex Code
6042 \begin_layout Plain Layout
6048 program communicates with \SpecialChar LyX
6050 In some cases, you need a helper script that mediates between the viewer
6051 and \SpecialChar LyX
6052 , in others, the viewer can communicate with \SpecialChar LyX
6054 This depends on the selected viewer and on your operating system.
6055 The same applies to the way viewers need to be configured and the way the
6056 reverse search is actually performed.
6057 In what follows, we will thus describe how to setup reverse search for
6059 Before we turn to this, though, we will explain what needs to be done generally
6060 to enable reverse search in the DVI/PDF output.
6063 \begin_layout Subsection
6065 \begin_inset CommandInset label
6067 name "subsec:rev-search"
6074 \begin_layout Standard
6075 In most cases \SpecialChar LyX
6076 will do the work for you by enabling the option
6077 \begin_inset Flex Noun
6080 \begin_layout Plain Layout
6081 Synchronize with Output
6087 \begin_inset Flex Noun
6090 \begin_layout Plain Layout
6091 Document\SpecialChar menuseparator
6092 Settings\SpecialChar menuseparator
6099 In such a case \SpecialChar LyX
6100 will automatically insert the necessary Sync\SpecialChar TeX
6102 PDF) or load the srcltx package (for DVI) respectively.
6103 This option can be easily reached also on
6104 \begin_inset Flex Code
6107 \begin_layout Plain Layout
6116 \begin_layout Standard
6117 If you need a different setting, you can select or input a custom macro
6118 from the drop down box just below
6119 \begin_inset Flex Noun
6122 \begin_layout Plain Layout
6123 Document\SpecialChar menuseparator
6124 Settings\SpecialChar menuseparator
6125 Output\SpecialChar menuseparator
6126 Synchronize with Output
6134 \begin_layout Standard
6135 Note that the method
6136 \begin_inset Flex Code
6139 \begin_layout Plain Layout
6147 enables gzip compression.
6148 If your viewer does not support it, you should instead use
6149 \begin_inset Flex Code
6152 \begin_layout Plain Layout
6163 \begin_layout Standard
6164 Please also note that including the
6165 \begin_inset Flex Code
6168 \begin_layout Plain Layout
6175 \begin_inset Flex Code
6178 \begin_layout Plain Layout
6184 sometimes has an undesired impact on the typesetting.
6185 Thus, you should switch output synchronization off for the final typesetting
6187 \begin_inset Flex Code
6190 \begin_layout Plain Layout
6197 \begin_inset Flex Code
6200 \begin_layout Plain Layout
6210 \begin_layout Standard
6211 In case you need some more special settings that are not covered by the
6212 automatic settings, read the next section about how to set up output synchroniz
6214 If the automatic setup suits your needs, you can readily jump to section
6215 \begin_inset space ~
6219 \begin_inset CommandInset ref
6221 reference "subsec:configuring-viewers"
6225 , where the necessary configuration steps in your viewer – needed both with
6226 the automatic and the manual setup – are described.
6229 \begin_layout Subsection
6233 \begin_layout Standard
6235 provides several different methods for reverse search.
6236 Some are built-in in the
6237 \begin_inset Flex Code
6240 \begin_layout Plain Layout
6246 program, some are provided by external packages.
6247 Your choice depends on whether your \SpecialChar LaTeX
6248 distribution already provides a given
6249 method (the built-in methods are rather new) and whether your viewer can
6251 The available methods are described in the following.
6254 \begin_layout Subsubsection*
6255 Built-in DVI-search via src-specials (DVI only)
6258 \begin_layout Standard
6259 This method provides the DVI file with the necessary information for reverse
6261 It is available in \SpecialChar LaTeX
6262 since quite some time (any somewhat recent \SpecialChar LaTeX
6264 should include it), and it works reliably.
6265 To enable it, change the
6266 \begin_inset Flex Noun
6269 \begin_layout Plain Layout
6280 \begin_inset Flex Noun
6283 \begin_layout Plain Layout
6294 \begin_inset Flex Noun
6297 \begin_layout Plain Layout
6298 Preferences\SpecialChar menuseparator
6299 File Handling\SpecialChar menuseparator
6306 \begin_inset Flex Code
6309 \begin_layout Plain Layout
6310 latex -src-specials $$i
6316 If this doesn't work, check if your \SpecialChar TeX
6317 engine needs different options (the
6318 syntax might differ in some distributions).
6321 \begin_layout Subsubsection*
6322 External Packages (PDFSync and scrltx)
6325 \begin_layout Standard
6334 provide reverse search facility for PDF output (via pdflatex) and DVI output,
6336 In order to enable it, load the packages in the \SpecialChar LyX
6340 \begin_layout Itemize
6341 \begin_inset Flex Code
6344 \begin_layout Plain Layout
6352 for reverse PDF search,
6355 \begin_layout Itemize
6356 \begin_inset Flex Code
6359 \begin_layout Plain Layout
6362 usepackage[active]{srcltx}
6367 for reverse DVI search.
6370 \begin_layout Standard
6371 If you want to be able to perform both DVI and PDF reverse searches, you
6372 can also insert in the preamble the following lines
6375 \begin_layout LyX-Code
6379 \begin_inset Newline newline
6385 \begin_inset Newline newline
6391 \begin_inset Newline newline
6397 \begin_inset Newline newline
6402 usepackage[active]{srcltx}
6403 \begin_inset Newline newline
6411 \begin_layout Standard
6412 This way, you can preview the file as either DVI or PDF (pdflatex) and the
6413 right package will be used.
6416 \begin_layout Standard
6417 Note that PDFSync might affect the output layout of your document.
6418 It is therefore advised to disable PDFsync for final documents.
6421 \begin_layout Subsubsection*
6422 Built-in reverse search via Sync\SpecialChar TeX
6426 \begin_layout Standard
6428 \begin_inset Flex Code
6431 \begin_layout Plain Layout
6437 have built-in support for both PDF and DVI reverse search.
6440 Sync\SpecialChar TeX
6443 facility is basically the result of the integration of the PDFSync package
6444 to the pdftex program and its merge with the
6449 You need at least \SpecialChar TeX
6450 Live 2008 or a recent Mik\SpecialChar TeX
6451 distribution in order to use
6456 \begin_layout Plain Layout
6457 For some reason, Mik\SpecialChar TeX
6458 does not understand/obey the command \SpecialChar LyX
6460 the preamble when you check the "Enable Forward/Reverse Search" button
6461 in the toolbar and does not generate the necessary info.
6464 \begin_layout Plain Layout
6465 The generation of the required info can be forced by changing the converter
6467 (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
6468 from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
6469 the -synctex=1 switch).
6474 Also note that only a few PDF viewers (Okular and Qpdfview on Unix, Skim
6475 on the Mac, SumatraPDF on Windows) already provide Sync\SpecialChar TeX
6479 \begin_layout Standard
6480 To enable Sync\SpecialChar TeX
6481 for DVI output, change the
6482 \begin_inset Flex Noun
6485 \begin_layout Plain Layout
6496 \begin_inset Flex Noun
6499 \begin_layout Plain Layout
6510 \begin_inset Flex Noun
6513 \begin_layout Plain Layout
6514 Preferences\SpecialChar menuseparator
6515 File Handling\SpecialChar menuseparator
6522 \begin_inset Flex Code
6525 \begin_layout Plain Layout
6526 latex -synctex=1 $$i
6531 , and for PDF output, change the
6532 \begin_inset Flex Noun
6535 \begin_layout Plain Layout
6540 (pdflatex) -> PDF (pdflatex)
6546 \begin_inset Flex Code
6549 \begin_layout Plain Layout
6550 pdflatex -synctex=1 $$i
6556 Check the documentation of your viewer whether the viewer needs to be configure
6557 d for the use with Sync\SpecialChar TeX
6562 \begin_layout Plain Layout
6563 Note that the option
6564 \begin_inset Flex Code
6567 \begin_layout Plain Layout
6573 option enables gzip compression.
6574 If your viewer does not support it, you should instead use
6575 \begin_inset Flex Code
6578 \begin_layout Plain Layout
6592 \begin_layout Subsection
6593 Configuring and using specific viewers
6594 \begin_inset CommandInset label
6596 name "subsec:configuring-viewers"
6603 \begin_layout Subsubsection*
6604 Xdvi (all platforms)
6607 \begin_layout Standard
6609 \begin_inset Flex Code
6612 \begin_layout Plain Layout
6618 , you don't need to do anything else for performing a reverse DVI search,
6620 already provides the necessary hooks for automatically using the
6621 \begin_inset Flex Code
6624 \begin_layout Plain Layout
6631 Just setup your document as described above (reverse search is triggered
6632 by Ctrl-click or Alt-click on Mac OSX, respectively).
6635 \begin_layout Standard
6636 However, if for whatever reason you want to use the named pipe instead of
6637 the socket for communicating with \SpecialChar LyX
6638 , simply change the DVI viewer in
6639 \begin_inset Flex Noun
6642 \begin_layout Plain Layout
6643 Preferences\SpecialChar menuseparator
6644 File Handling\SpecialChar menuseparator
6654 \begin_layout Plain Layout
6655 On Mac OSX you have to use
6656 \begin_inset Flex Code
6659 \begin_layout Plain Layout
6660 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
6671 \begin_inset Flex Code
6674 \begin_layout Plain Layout
6675 xdvi -editor "lyxeditor.sh %f %l"
6681 \begin_inset Flex Code
6684 \begin_layout Plain Layout
6690 is a suitable script.
6691 For example, a minimal shell script is the following one:
6694 \begin_layout LyX-Code
6696 \begin_inset Newline newline
6699 LYXPIPE="/path/to/lyxpipe"
6700 \begin_inset Newline newline
6703 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
6704 \begin_inset Newline newline
6707 echo "$COMMAND" > "${LYXPIPE}".in || exit
6708 \begin_inset Newline newline
6711 read TMP < "${LYXPIPE}".out || exit
6714 \begin_layout Standard
6716 \begin_inset Flex Code
6719 \begin_layout Plain Layout
6729 \begin_layout Plain Layout
6736 XServer pipe path specified in
6737 \begin_inset Flex Noun
6740 \begin_layout Plain Layout
6741 Preferences\SpecialChar menuseparator
6751 \begin_layout Plain Layout
6753 \begin_inset Flex Code
6756 \begin_layout Plain Layout
6762 folder of a source distribution you can find a
6763 \begin_inset Flex Code
6766 \begin_layout Plain Layout
6772 script which is able to locate the
6776 based on your preferences.
6784 \begin_layout Subsubsection*
6788 \begin_layout Standard
6790 \begin_inset Flex Code
6793 \begin_layout Plain Layout
6794 /Applications/MacDviX_Folder/calleditor.script
6799 , add the following lines:
6802 \begin_layout LyX-Code
6807 \begin_layout Plain Layout
6814 X.app/Contents/MacOS/lyxeditor "$2" $1
6815 \begin_inset Newline newline
6821 \begin_layout Standard
6822 Modify the lines accordingly if you install \SpecialChar LyX
6823 somewhere else than in the
6824 Applications folder.
6827 \begin_layout Standard
6828 Reverse search is triggered by Alt-click (OPTION-click).
6831 \begin_layout Subsubsection*
6835 \begin_layout Standard
6837 \begin_inset Flex Code
6840 \begin_layout Plain Layout
6841 open -a Skim.app $$i
6846 to the viewer setting in
6847 \begin_inset Flex Noun
6850 \begin_layout Plain Layout
6851 Preferences\SpecialChar menuseparator
6852 File Handling\SpecialChar menuseparator
6853 File formats\SpecialChar menuseparator
6860 \begin_inset Flex Noun
6863 \begin_layout Plain Layout
6864 Skim\SpecialChar menuseparator
6865 Preferences\SpecialChar menuseparator
6872 \begin_inset Flex Noun
6875 \begin_layout Plain Layout
6881 preset and enter command
6882 \begin_inset Flex Noun
6885 \begin_layout Plain Layout
6886 /Applications/\SpecialChar LyX
6887 .app/Contents/MacOS/lyxeditor
6895 \begin_layout Standard
6896 Reverse search is triggered by COMMAND-SHIFT-click
6899 \begin_layout Subsubsection*
6903 \begin_layout Standard
6905 \begin_inset Flex Noun
6908 \begin_layout Plain Layout
6909 Settings\SpecialChar menuseparator
6910 Configure Okular\SpecialChar menuseparator
6917 \begin_inset Quotes eld
6921 \begin_inset Quotes erd
6925 \begin_inset Flex Code
6928 \begin_layout Plain Layout
6937 \begin_layout Standard
6938 Reverse search is triggered by SHIFT-click.
6941 \begin_layout Subsubsection*
6945 \begin_layout Standard
6946 Qpdfview supports Sync\SpecialChar TeX
6947 since version 0.3.5.
6949 \begin_inset Flex Noun
6952 \begin_layout Plain Layout
6953 Edit\SpecialChar menuseparator
6954 Settings\SpecialChar menuseparator
6960 , click on the input field of the
6961 \begin_inset Quotes eld
6965 \begin_inset Quotes erd
6968 item and add the command
6969 \begin_inset Flex Code
6972 \begin_layout Plain Layout
6981 \begin_layout Standard
6982 Reverse search is triggered by double-click.
6985 \begin_layout Subsubsection*
6989 \begin_layout Standard
6990 Launch yap, choose its
6991 \begin_inset Flex Noun
6994 \begin_layout Plain Layout
6995 View\SpecialChar menuseparator
7002 \begin_inset Quotes eld
7006 \begin_inset Quotes erd
7011 \begin_inset Quotes eld
7014 New\SpecialChar ldots
7016 \begin_inset Quotes erd
7019 button and, in the window that opens, enter
7020 \begin_inset Quotes eld
7025 \begin_inset Quotes erd
7028 (or any other name you like) in the
7029 \begin_inset Quotes eld
7033 \begin_inset Quotes erd
7037 Now click on the button labeled
7038 \begin_inset Quotes eld
7043 \begin_inset Quotes erd
7046 to open a file dialog and navigate to the directory containing the batch
7048 \begin_inset Flex Code
7051 \begin_layout Plain Layout
7059 \begin_inset Flex Code
7062 \begin_layout Plain Layout
7068 and then specify the program arguments as
7069 \begin_inset Flex Code
7072 \begin_layout Plain Layout
7080 \begin_inset Flex Code
7083 \begin_layout Plain Layout
7089 wrapper is used for communicating with \SpecialChar LyX
7097 \begin_layout LyX-Code
7099 \begin_inset Newline newline
7102 echo LYXCMD:revdvi:server-goto-file-row:%1 %2>
7111 \begin_inset Newline newline
7125 \begin_layout Standard
7126 Make sure that the \SpecialChar LyX
7127 Server pipe path you specified in \SpecialChar LyX
7129 \begin_inset Flex Code
7132 \begin_layout Plain Layout
7146 , otherwise change the
7147 \begin_inset Flex Code
7150 \begin_layout Plain Layout
7156 wrapper accordingly.
7159 \begin_layout Standard
7160 In yap, reverse search is triggered by double-click.
7163 \begin_layout Subsubsection*
7164 SumatraPDF (Windows)
7167 \begin_layout Standard
7168 In order to use SumatraPDF for inverse search, enter
7169 \begin_inset Flex Code
7172 \begin_layout Plain Layout
7173 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
7178 in the viewer setting in
7179 \begin_inset Flex Noun
7182 \begin_layout Plain Layout
7183 Preferences\SpecialChar menuseparator
7184 File Handling\SpecialChar menuseparator
7185 File formats\SpecialChar menuseparator
7192 \begin_inset Flex Code
7195 \begin_layout Plain Layout
7201 is the previous wrapper.
7202 If SumatraPDF.exe is not in your command PATH, use its full file name.
7205 \begin_layout Standard
7206 Reverse search is triggered by double-click.
7209 \begin_layout Subsubsection*
7213 \begin_layout Standard
7214 First of all, make sure that yap is your default DVI viewer in the Windows
7215 environment, then launch it, choose its
7216 \begin_inset Flex Noun
7219 \begin_layout Plain Layout
7220 View\SpecialChar menuseparator
7227 \begin_inset Quotes eld
7231 \begin_inset Quotes erd
7236 \begin_inset Quotes eld
7239 New\SpecialChar ldots
7241 \begin_inset Quotes erd
7244 button and, in the window that opens, enter
7245 \begin_inset Quotes eld
7250 \begin_inset Quotes erd
7253 (or any other name you like) in the
7254 \begin_inset Quotes eld
7258 \begin_inset Quotes erd
7262 Now click on the button labeled
7263 \begin_inset Quotes eld
7268 \begin_inset Quotes erd
7271 to open a file dialog and navigate to the directory containing the
7272 \begin_inset Flex Code
7275 \begin_layout Plain Layout
7281 program (which is installed by default on Cygwin along with the \SpecialChar LyX
7284 \begin_inset Flex Code
7287 \begin_layout Plain Layout
7293 and then specify the program arguments as
7294 \begin_inset Flex Code
7297 \begin_layout Plain Layout
7304 In this way, you will be using the
7308 for communicating with \SpecialChar LyX
7310 If, for whatever reason, you want to use the
7315 \begin_inset Flex Code
7318 \begin_layout Plain Layout
7324 option and be sure to specify the \SpecialChar LyX
7325 Server pipe path in the \SpecialChar LyX
7329 \begin_layout Standard
7330 In yap, reverse search is triggered by double-click.
7333 \begin_layout Subsubsection*
7337 \begin_layout Standard
7338 In order to use SumatraPDF for inverse search, enter
7339 \begin_inset Flex Code
7342 \begin_layout Plain Layout
7343 SumatraPDF -inverse-search "lyxeditor -g %f %l"
7348 in the viewer setting in
7349 \begin_inset Flex Noun
7352 \begin_layout Plain Layout
7353 Preferences\SpecialChar menuseparator
7354 File Handling\SpecialChar menuseparator
7355 File formats\SpecialChar menuseparator
7362 If SumatraPDF.exe is not in your command PATH, use its full posix path.
7364 \begin_inset Flex Code
7367 \begin_layout Plain Layout
7373 enables communication via the
7379 \begin_inset Flex Code
7382 \begin_layout Plain Layout
7388 option if you want to use the
7392 , and be sure to specify the \SpecialChar LyX
7393 Server pipe path in the \SpecialChar LyX
7397 \begin_layout Standard
7398 Reverse search is triggered by double-click.
7401 \begin_layout Section
7405 \begin_layout Standard
7406 Forward search is, as the name implies, in a sense the
7407 \begin_inset Quotes eld
7411 \begin_inset Quotes erd
7415 It allows you to let the viewer jump to a given position from within \SpecialChar LyX
7417 If forward search is set up (as described in what follows), you can put
7418 the cursor anywhere in your \SpecialChar LyX
7420 \begin_inset Flex Noun
7423 \begin_layout Plain Layout
7424 Navigate\SpecialChar menuseparator
7431 \begin_inset Flex Noun
7434 \begin_layout Plain Layout
7440 in the context menu via right mouse click), and then the viewer will jump
7441 to that position as well.
7442 This implies, of course, that your viewer supports this function.
7445 \begin_layout Standard
7446 To make forward search possible, you first need to provide the generated
7447 output PDF/DVI file with additional information about the \SpecialChar TeX
7449 This can be done via the methods described in the section
7450 \begin_inset CommandInset ref
7452 reference "subsec:rev-search"
7459 \begin_layout Standard
7460 Additionally, you need to configure \SpecialChar LyX
7461 for using your viewers in
7462 \begin_inset Flex Noun
7465 \begin_layout Plain Layout
7466 Tools\SpecialChar menuseparator
7467 Preferences\SpecialChar menuseparator
7468 Output\SpecialChar menuseparator
7475 We provide a range of tested configurations for some viewers, which you
7476 can select from the drop down list.
7477 If none of these configurations suits you, you have to find out and enter
7478 a suitable configuration yourself.
7479 The definition syntax uses the following placeholders:
7482 \begin_layout Itemize
7484 \begin_inset Flex Code
7487 \begin_layout Plain Layout
7496 \begin_layout Itemize
7498 \begin_inset Flex Code
7501 \begin_layout Plain Layout
7507 : name of the (temporary) exported .tex file (without path)
7510 \begin_layout Itemize
7512 \begin_inset Flex Code
7515 \begin_layout Plain Layout
7521 : name of the (temporary) exported .tex file (including path)
7524 \begin_layout Itemize
7526 \begin_inset Flex Code
7529 \begin_layout Plain Layout
7535 : name of the exported output file (either dvi or pdf, depending on which
7536 one exists in the temporary directory)
7539 \begin_layout Standard
7540 Note that only some of the viewers provide full forward search functionality,
7541 among them yap, xdvi, okular
7545 \begin_layout Plain Layout
7546 You might want to set
7547 \begin_inset Flex Code
7550 \begin_layout Plain Layout
7557 \begin_inset Flex Noun
7560 \begin_layout Plain Layout
7561 Tools\SpecialChar menuseparator
7562 Preferences\SpecialChar menuseparator
7563 File Handling\SpecialChar menuseparator
7565 \begin_inset space ~
7578 , qpdfview and SumatraPDF
7582 \begin_layout Plain Layout
7583 SumatraPDF can also use DDE commands through the external program CMCDDE
7585 \begin_inset CommandInset href
7587 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
7597 While many of the widespread PDF viewers (most notably Adobe Reader) do
7598 not support forward search at all, some other viewers – e.
7599 \begin_inset space \thinspace{}
7603 evince and xpdf – allow at least to reload the document and jump to a specific
7604 page of the file, so you can at least navigate
7605 \begin_inset Quotes eld
7609 \begin_inset Quotes erd
7613 This latter functionality is provided by an external call of synctex (see
7614 the predefined example configurations).
7618 \begin_layout Standard
7619 Forward search works both with DVI and PDF output.
7621 simply checks which preview format you have used before (i.
7622 \begin_inset space \thinspace{}
7625 e., which format is already there in the temporary directory) and chooses
7626 the appropriate configuration for the respective format.
7629 \begin_layout Chapter
7630 Special Document Classes
7633 \begin_layout Section
7637 \begin_layout Standard
7643 \begin_layout Subsection
7647 \begin_layout Standard
7648 This section describes how \SpecialChar LyX
7649 can be used to write articles for submission
7650 to the scientific journal
7652 Astronomy and Astrophysics
7655 \begin_inset Flex URL
7658 \begin_layout Plain Layout
7660 http://www.edpsciences.fr/aa/
7665 ) using Version 5.01 of the document class
7670 This package can be downloaded from the ftp site
7673 \begin_layout Standard
7674 \begin_inset VSpace medskip
7680 \begin_layout Standard
7682 \begin_inset Flex URL
7685 \begin_layout Plain Layout
7687 ftp://ftp.edpsciences.org/pub/aa/readme.html
7695 \begin_layout Standard
7696 \begin_inset VSpace medskip
7702 \begin_layout Standard
7703 A manual comes together with that package, and this text is not meant to
7704 replace the original manual but is merely a short guide in how to realize
7705 the correct form of your paper.
7709 \begin_layout Standard
7710 Please note that the publisher of the journal was changed from Springer
7711 to EDP Sciences starting January 1, 2001.
7712 That change involved also some slight changes to the style files, namely
7713 the removal of the thesaurus command.
7714 The \SpecialChar LyX
7715 class aa supports the newest version of these style files, V 5.01.
7716 If you have an older version installed, please upgrade.
7717 For compatibility, the old (version 4) layout has been kept as
7722 Please refer to the comments in
7725 Dir/layouts/aapaper.layout
7730 \begin_layout Subsection
7734 \begin_layout Standard
7735 It is recommended you start from the example template distributed with \SpecialChar LyX
7737 If you are not using a template, note the following settings:
7740 \begin_layout Itemize
7747 Document\SpecialChar menuseparator
7750 dialog (OK, that one was obvious).
7753 \begin_layout Itemize
7754 Don't change the option
7757 \begin_inset space ~
7767 The whole layout is done by the macros, you shouldn't change anything.
7770 \begin_layout Subsection
7774 \begin_layout Standard
7775 First thing to enter is the header information.
7776 It consists of seven entries, of which some are optional.
7780 \begin_layout Itemize
7788 \begin_layout Itemize
7796 \begin_layout Itemize
7804 \begin_layout Itemize
7812 \begin_layout Itemize
7817 : [optional] if more than one author: whom to contact for offprint requests.
7820 \begin_layout Itemize
7825 : [optional] mail address for contacts.
7828 \begin_layout Itemize
7836 Received: <date>; Accepted <date>
7839 \begin_layout Standard
7840 There is no need to issue the
7846 command, this is done automatically by \SpecialChar LyX
7847 when the header is finished.
7848 Although the order of the single header entries doesn't matter it is advised
7849 to keep the above sequence, just to get the best optics and meets the layout
7850 of the real document.
7853 \begin_layout Standard
7854 If you want to place footnotes in the header block, e.
7855 \begin_inset space \thinspace{}
7859 \begin_inset space \space{}
7862 to state your present address, just use the standard footnote via the menu
7865 Insert\SpecialChar menuseparator
7870 will automagically use the term
7879 \begin_layout Standard
7880 In addition to these topics, the macros use three additional \SpecialChar LaTeX
7882 have no counterpart in \SpecialChar LyX
7886 \begin_layout Itemize
7893 to separate different names for more than one author and institute, respectivel
7897 \begin_layout Itemize
7904 to mark corresponding author/institute pairs.
7905 The institutes are numbered sequentially as they appear in the
7909 field, so you have to put a marker to each author.
7912 \begin_layout Itemize
7919 to supply an email address for fast contact.
7922 \begin_layout Standard
7923 In all cases, the appropriate command has to be entered in \SpecialChar LyX
7931 \begin_layout Subsection
7935 \begin_layout Standard
7936 The abstract should immediately follow the header block.
7937 With version 5 the abstract environment was changed to a command, and there
7938 is now a resctriction to only one paragraph.
7939 In addition, it should contain an entry with the keywords.
7940 This is not yet implemented for \SpecialChar LyX
7941 , therefore you have to enter the \SpecialChar LaTeX
7949 by hand and mark it as \SpecialChar LaTeX
7951 Refer to the example paper.
7954 \begin_layout Subsection
7955 Supported environments
7958 \begin_layout Standard
7959 The A&A paper layout supports the following environments for structuring
7963 \begin_layout Itemize
7969 \begin_layout Itemize
7975 \begin_layout Itemize
7981 \begin_layout Itemize
7987 \begin_layout Itemize
7993 \begin_layout Itemize
7999 \begin_layout Itemize
8005 \begin_layout Itemize
8011 \begin_layout Itemize
8017 \begin_layout Itemize
8023 \begin_layout Itemize
8029 \begin_layout Itemize
8036 \begin_layout Subsection
8037 Commands not supported by \SpecialChar LyX
8041 \begin_layout Standard
8042 Some commands are not yet supported by the
8046 layout for \SpecialChar LyX
8048 Some have already been mentioned.
8049 For the sake of completeness, they are listed all together here:
8052 \begin_layout Itemize
8060 \begin_layout Itemize
8068 \begin_layout Itemize
8076 \begin_layout Itemize
8084 \begin_layout Itemize
8092 \begin_layout Itemize
8100 \begin_layout Itemize
8108 \begin_layout Itemize
8116 \begin_layout Standard
8117 If you want to use any of these commands, you have to enter them yourself.
8120 Do not forget to mark them as \SpecialChar LaTeX
8124 \begin_layout Subsection
8125 Figure and Table Floats
8128 \begin_layout Standard
8130 provides support for the necessary float environments
8132 figure, figure*, table
8138 , therefore we won't tell much about it here.
8142 \begin_inset space ~
8148 Just remember that tables should be left-aligned.
8149 For that, select the table and change the alignment in
8151 Edit\SpecialChar menuseparator
8153 \begin_inset space ~
8159 \begin_layout Standard
8160 There is only one special thing: the figures with caption besides the figure.
8161 To create such a figure, you have to do the following:
8164 \begin_layout Enumerate
8165 Create a wide figure float:
8167 Insert\SpecialChar menuseparator
8168 Float\SpecialChar menuseparator
8171 , then right click in the figure and select
8174 \begin_inset space ~
8182 \begin_layout Enumerate
8183 Enter your caption text.
8186 \begin_layout Enumerate
8191 to move the cursor above the caption.
8194 \begin_layout Enumerate
8198 \begin_layout Enumerate
8199 Position the cursor behind the figure and insert a horizontal fill:
8201 Insert\SpecialChar menuseparator
8203 \begin_inset space ~
8206 Character\SpecialChar menuseparator
8208 \begin_inset space ~
8216 \begin_layout Enumerate
8217 Switch to \SpecialChar LaTeX
8221 \begin_inset space ~
8229 \begin_layout Enumerate
8239 Do not close the brace!
8242 \begin_layout Enumerate
8243 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
8248 \begin_inset space ~
8260 \begin_layout Standard
8261 Also, refer to the figures in the example paper.
8264 \begin_layout Subsection
8268 \begin_layout Standard
8269 For submission, the paper has to be formated in a special double-spacing
8271 For this purpose, you have to give the option
8275 to the documentclass.
8276 This must be done using the extra class options field in the
8278 Document\SpecialChar menuseparator
8282 Just enter the string
8289 \begin_layout Subsection
8293 \begin_layout Standard
8298 directory contains an example paper written with \SpecialChar LyX
8300 It is the example paper from the original macro package, translated to
8303 Use it for inspiration, and compare the original \SpecialChar LaTeX
8304 code with \SpecialChar LyX
8308 \begin_layout Section
8313 \begin_layout Standard
8319 \begin_layout Subsection
8323 \begin_layout Standard
8325 is a set of macros produced by the American Astronomical Society to
8326 facilitate electronic manuscript submission to the three journals they
8327 publish: the Astrophysical Journal (including the Letters and Supplement),
8328 the Astronomical Journal, and the Publications of the Astronomical Society
8331 has proven to be an excellent tool for generating these documents, especially
8332 given its equation, citation, and figure handling capabilities.
8334 requires version 5.0 (or higher) of these macros; preferably 5.2, which
8335 is the version described here, or higher.
8336 Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
8337 2.09 and are fundamentally
8338 incompatible with \SpecialChar LyX
8340 The AAS\SpecialChar TeX
8341 package may be downloaded from the AAS\SpecialChar TeX
8345 \begin_layout Standard
8346 \begin_inset VSpace medskip
8352 \begin_layout Standard
8354 \begin_inset Flex URL
8357 \begin_layout Plain Layout
8359 https://aas.org/aastex/aastex-downloads
8367 \begin_layout Standard
8368 \begin_inset VSpace medskip
8374 \begin_layout Standard
8375 A complete user guide is contained in that package and you should familiarize
8376 yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
8379 will not reduce the need to figure out all the AAS\SpecialChar TeX
8380 commands, it will only
8381 reduce the drudgery of typing everything in.
8382 It is your responsibility to ensure that the final exported \SpecialChar LaTeX
8384 completely to the requirements of the journal to which you are submitting
8388 \begin_layout Subsection
8389 Starting a New Paper
8392 \begin_layout Standard
8393 I strongly suggest that you start with the AAS\SpecialChar TeX
8397 File\SpecialChar menuseparator
8404 , enter the new file name, then choose the
8409 This will show the most common fields found in a manuscript.
8410 Simply overwrite the existing text (including the brackets,
8414 ) with the correct information.
8415 Many of the AAS\SpecialChar TeX
8416 commands and environments can be implemented directly in
8418 , but some cannot: most noticeably
8430 , which should stick out like a sore thumb if you actually just opened the
8432 For commands such as these, the \SpecialChar LaTeX
8433 code must be entered directly and marked
8435 Such commands are referred to as \SpecialChar TeX
8436 code, or Evil Red Text.
8437 I tried to minimize the amount of \SpecialChar TeX
8438 code needed in an AAS\SpecialChar TeX
8440 there is still a bit more required than any of us would like.
8443 \begin_layout Subsection
8444 Finishing Your Paper
8447 \begin_layout Standard
8448 When the paper is finished to your satisfaction and previews/prints correctly,
8450 \begin_inset Quotes eld
8454 \begin_inset Quotes erd
8457 actions which need to be done before you submit it to the journals.
8461 \begin_layout Enumerate
8462 Export your paper as a \SpecialChar LaTeX
8465 File\SpecialChar menuseparator
8466 Export\SpecialChar menuseparator
8474 \begin_layout Enumerate
8479 file with your favorite text editor
8480 \begin_inset Separator parbreak
8487 \begin_layout Enumerate
8488 remove the comment lines before the
8497 \begin_layout Enumerate
8502 usepackage...{fontenc}
8504 line if it appears (usually just after
8519 \begin_layout Enumerate
8520 remove everything between (and including) the
8532 commands, except for any commands you specifically put into the \SpecialChar LaTeX
8534 (which should appear immediately after the
8535 \begin_inset Quotes eld
8538 User specified \SpecialChar LaTeX
8540 \begin_inset Quotes erd
8551 \begin_layout Enumerate
8552 Run the resulting file through \SpecialChar LaTeX
8553 to make sure it still processes correctly.
8556 \begin_layout Enumerate
8557 Reread the journal requirements to make sure your filenames and formats
8561 \begin_layout Enumerate
8565 \begin_layout Subsection
8566 Comments On Specific Commands
8569 \begin_layout Standard
8570 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
8577 ) gives a good description of each.
8578 Thus it's probably easiest for me to go down the list as found in the guide
8579 and offer comments where necessary.
8580 So let's begin \SpecialChar ldots
8584 \begin_layout Subsubsection
8585 Things that work as expected
8588 \begin_layout Standard
8589 Because they work as you might expect, I simply list them and the section
8690 begin{thebibliography}
8698 (2.13.2), all the cite commands and their variations (2.13.2), the generic
8699 graphicx figure commands (2.14.1),
8723 (2.15.4, amongst other places),
8750 \begin_layout Standard
8751 The following style options also work correctly:
8772 Simply put them in the
8778 Layout\SpecialChar menuseparator
8784 \begin_layout Subsubsection
8785 Things that work, but require more comment
8788 \begin_layout Standard
8789 The following items work, but require a little more discussion:
8792 \begin_layout Itemize
8793 These items are reserved for use by the journal editors, but you can put
8794 them into the \SpecialChar LaTeX
8795 preamble if you feel compelled to do so:
8828 \begin_layout Itemize
8829 These items may be placed in the \SpecialChar LaTeX
8830 preamble, and are included as blanks in
8852 \begin_layout Itemize
8859 (2.3) – can only be used
8860 \begin_inset Quotes eld
8864 \begin_inset Quotes erd
8867 , not in the middle of a paragraph.
8868 Use \SpecialChar TeX
8869 code if you need to embed it.
8872 \begin_layout Itemize
8879 (2.3) – will have extra {} after it.
8880 This should not cause an error.
8883 \begin_layout Itemize
8890 (2.6) – can only be used
8891 \begin_inset Quotes eld
8895 \begin_inset Quotes erd
8898 , not in the middle of a paragraph.
8899 Use \SpecialChar TeX
8900 code if you need to embed it.
8903 \begin_layout Itemize
8910 (2.8) – can't insert a cross-reference tag, you must type the tag name by
8914 \begin_layout Itemize
8928 \begin_layout Itemize
8935 (2.9) – will have extra {} after it.
8936 This should not cause an error.
8939 \begin_layout Itemize
8946 (2.11) – will have extra {} after it.
8947 This should not cause an error.
8950 \begin_layout Itemize
8957 (2.14.2) – you can insert an optional filename argument by placing the cursor
8958 at the beginning of the text and selecting
8960 Insert\SpecialChar menuseparator
8965 \begin_inset Quotes eld
8969 \begin_inset Quotes erd
8972 inserts an optional argument of the type needed by
8979 Hopefully it will be renamed someday.
8982 \begin_layout Itemize
8995 for the catalog ID optional parameter
8998 \begin_layout Itemize
9011 for the catalog ID optional parameter
9014 \begin_layout Subsubsection
9015 Things not implemented, use \SpecialChar TeX
9019 \begin_layout Standard
9042 setcounter{equation}
9044 (2.12), Journal name abbreviations (2.13.4),
9080 (2.15.4, insert it as the first element in the lefthand cell after where
9082 Don't use any of \SpecialChar LyX
9083 's rules in the table),
9095 (2.15.5), much of Misc (2.17, except
9146 \begin_layout Subsubsection
9147 Things that cannot be implemented
9150 \begin_layout Standard
9152 at least in any meaningful sort of way, so I suggest ignoring them.
9153 They are the references environment (2.13.3), and the deluxetable environment
9155 If you really, really need to use deluxetable, I suggest editing it in
9156 a separate file with a text editor, then using
9158 Insert\SpecialChar menuseparator
9160 \begin_inset space ~
9165 to include it in your \SpecialChar LyX
9171 file to see an example of this.
9174 \begin_layout Subsection
9175 FAQs, Tips, Tricks, and Other Ruminations
9178 \begin_layout Subsubsection
9179 Getting \SpecialChar LyX
9180 and AAS\SpecialChar TeX
9184 \begin_layout Standard
9185 It can be a bit tricky to get \SpecialChar LyX
9186 to recognize a new layout and document class.
9187 When all else fails, do this:
9190 \begin_layout Enumerate
9191 Make certain that \SpecialChar LaTeX
9192 can find AAS\SpecialChar TeX
9194 Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
9196 directory completely unrelated to \SpecialChar LaTeX
9197 or AAS\SpecialChar TeX
9198 and run \SpecialChar LaTeX
9206 \begin_layout Enumerate
9211 appears in \SpecialChar LyX
9219 \begin_layout Enumerate
9222 Tools\SpecialChar menuseparator
9226 , then restart \SpecialChar LyX
9230 \begin_layout Enumerate
9231 Open a regular new file, not from a template.
9232 Does AAS\SpecialChar TeX
9233 appear in the class list in
9235 Document\SpecialChar menuseparator
9241 \begin_layout Standard
9242 If you get a warning from an existing AAS\SpecialChar TeX
9243 document about not being able
9244 to find the AAS\SpecialChar TeX
9245 layout or a message about
9246 \begin_inset Quotes eld
9249 You should not mix title layouts with normal ones
9250 \begin_inset Quotes erd
9253 , things haven't been installed correctly.
9256 \begin_layout Subsubsection
9258 error processing a table
9261 \begin_layout Standard
9263 , by default, attempts to center the table caption/title.
9264 This seems to produce a bad interaction in AAS\SpecialChar TeX
9265 so you should click somewhere
9266 in the caption/title, then select
9268 Edit\SpecialChar menuseparator
9270 \begin_inset space ~
9284 This took care of it for me.
9287 \begin_layout Subsubsection
9291 \begin_layout Standard
9292 A couple of things: 1) I have noticed some funny spacing in the reference
9293 entries in the text.
9294 When you enter the bibliography item data, make sure their is
9298 space between the last author and the parenthesis setting off the year;
9302 \begin_inset space \thinspace{}
9306 \begin_inset space \space{}
9320 2) Entering the references at all is not obvious.
9321 The easiest thing is to start typing your first reference at the end of
9322 the document, then mark it as type
9327 That will put a small gray box in front of what you just typed.
9328 Click on the box to fill in the rest of the information.
9329 For new references, go to the end of an existing reference and press return.
9330 That will create a new line with its own box, etc.
9333 \begin_layout Subsubsection
9337 \begin_layout Standard
9338 Even though AAS\SpecialChar TeX
9339 provides its own figure commands (
9345 , for example), I much prefer \SpecialChar LaTeX
9346 's standard figure commands (with the default
9355 \begin_inset space ~
9358 commands as \SpecialChar TeX
9359 code into a Figure Float box if you desire, but I never have
9360 much luck getting the layout right.
9361 With the standard graphics, \SpecialChar LyX
9366 usepackage{graphicx}
9368 command into the \SpecialChar LaTeX
9369 preamble and handle the figures in the standard \SpecialChar LaTeX2e
9371 interspersing the figures in the text.
9372 I believe ApJ accepts figures exactly this way now; AJ might still use
9374 \begin_inset Quotes eld
9377 stack everything at the end
9378 \begin_inset Quotes erd
9384 \begin_layout Subsubsection
9385 Things I could have done, but didn't
9388 \begin_layout Standard
9390 \begin_inset Quotes eld
9394 \begin_inset Quotes erd
9397 things I could have implemented, but chose not to.
9398 For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
9400 even though it is double-spaced in the paper manuscript.
9401 Also, I chose not to make separate layouts for the preprint and preprint2
9403 Since I assume you will spend most of your time in the plain manuscript
9404 mode anyway, I decided not to chew up more disk space with this.
9408 \begin_layout Subsection
9412 \begin_layout Standard
9413 Your mileage may vary.
9414 I've now had papers published by both ApJ and AJ that have had 98% of the
9415 effort done in \SpecialChar LyX
9416 ; the last 2% was the \SpecialChar LaTeX
9417 post-processing and a few cleanups.
9418 I have had no trouble with the submission process, and I'm sure the journals
9419 were never aware that there might be a difference.
9420 So, go forth and publish!
9423 \begin_layout Section
9424 AMS \SpecialChar LaTeX
9428 \begin_layout Standard
9438 \begin_layout Standard
9439 \begin_inset VSpace bigskip
9445 \begin_layout Standard
9447 The AMS \SpecialChar LaTeX
9448 layouts are set up to conform to suggested styles for mathematical
9449 papers to be submitted to American Mathematical Society publications.
9450 The layouts are not tailored to a specific journal, but easily can be.
9451 You should refer to the AMS documentation for specific instructions for
9452 each journal (usually it will entail only changing a single line in the
9455 That documentation is available on the Web at
9456 \begin_inset Flex URL
9459 \begin_layout Plain Layout
9467 \begin_inset Flex URL
9470 \begin_layout Plain Layout
9472 ftp://ftp.ams.org/pub/tex/amslatex/
9478 These layouts are appropriate, and useful, for any mathematical writing.
9482 \begin_layout Standard
9483 There are two basic AMS \SpecialChar LaTeX
9487 \begin_layout Itemize
9488 amsart: The standard AMS article format.
9491 \begin_layout Itemize
9492 amsbook: the standard AMS book (really, monograph) format.
9496 \begin_layout Standard
9497 The layouts themselves contain only the minimum necessary to use the AMS
9499 They do not, in particular, contain any of the `theorem' environments used
9500 for setting theorems, lemmas, and the like.
9501 These are contained, instead, in the
9502 \begin_inset Flex Code
9505 \begin_layout Plain Layout
9511 module, which is loaded by default when you select one of the AMS classes.
9512 (It can also be used with other classes and can be removed, if you would
9513 rather use something else.) Less commonly used environments are in the
9514 \begin_inset Flex Code
9517 \begin_layout Plain Layout
9518 Theorems (AMS-Extended)
9523 module, which must be loaded manually.
9526 \begin_layout Standard
9527 By default, theorems and the like are numbered consecutively throughout
9528 the document, but this may be modified by loading the module
9529 \begin_inset Flex Code
9532 \begin_layout Plain Layout
9533 Theorems (Order by Section)
9538 or, if you are using
9539 \begin_inset Flex Code
9542 \begin_layout Plain Layout
9549 \begin_inset Flex Code
9552 \begin_layout Plain Layout
9553 Theorems (Order by Chapter)
9559 These will number the results as
9560 \begin_inset Formula $n.m$
9563 , where the first number refers to the section (or chapter) and the second
9564 refers to the total number of results so far in that section (or chapter).
9565 Many environments are also available unnumbered.
9566 These are indicated by an asterisk at the end.
9567 If you happen to want
9571 unnumbered results, the module
9572 \begin_inset Flex Code
9575 \begin_layout Plain Layout
9581 provides that option.
9584 \begin_layout Standard
9585 Note that these modules do not
9589 to be used with the AMS classes.
9590 It is perfectly possible to use the
9591 \begin_inset Flex Code
9594 \begin_layout Plain Layout
9600 module, and the others mentioned, with other classes, such as
9601 \begin_inset Flex Code
9604 \begin_layout Plain Layout
9611 \begin_inset Flex Code
9614 \begin_layout Plain Layout
9621 \begin_inset Flex Code
9624 \begin_layout Plain Layout
9633 \begin_layout Subsection
9634 What these layouts provide
9637 \begin_layout Standard
9638 There is a long list of included environments provided by these layouts.
9639 In AMS-\SpecialChar LaTeX
9640 , there is, in fact, an opportunity to define an unlimited variety
9641 of `theorem' environments.
9642 However, the AMS recommends the environments that are available in \SpecialChar LyX
9647 \begin_layout Standard
9648 The following environments—as well as the standard environments, such as
9650 \begin_inset Flex Noun
9653 \begin_layout Plain Layout
9660 \begin_inset Flex Noun
9663 \begin_layout Plain Layout
9670 \begin_inset Flex Noun
9673 \begin_layout Plain Layout
9680 \begin_inset Flex Noun
9683 \begin_layout Plain Layout
9690 \begin_inset Flex Noun
9693 \begin_layout Plain Layout
9700 \begin_inset Flex Code
9703 \begin_layout Plain Layout
9710 \begin_inset Flex Code
9713 \begin_layout Plain Layout
9722 \begin_layout Description
9723 Address This should be the author's permanent address.
9726 \begin_layout Description
9728 \begin_inset space ~
9731 Address This should be the author's temporary address at the time of submission,
9732 if different from the Address.
9735 \begin_layout Description
9736 Email Author's e-mail address
9739 \begin_layout Description
9740 URL Author's Web address, if desired.
9743 \begin_layout Description
9744 Keywords Key words or phrases used to identify specific topics discussed
9748 \begin_layout Description
9749 Subjectclass These refer to the AMS Subject Classifications, published and
9752 Mathematical Reviews
9755 These are also available online at the AMS cites listed above.
9758 \begin_layout Description
9762 \begin_layout Description
9766 \begin_layout Description
9770 \begin_layout Standard
9771 The following environments are provided by both the
9772 \begin_inset Flex Code
9775 \begin_layout Plain Layout
9782 \begin_inset Flex Code
9785 \begin_layout Plain Layout
9791 modules, in the latter case in both starred (unnumbered) and unstarred
9792 (numbered) versions.
9793 These same environments are provided only in the starred versions by the
9795 \begin_inset Flex Code
9798 \begin_layout Plain Layout
9807 \begin_layout Theorem
9808 This is typically used for the statements of major results.
9812 \begin_layout Corollary*
9813 This is used for statements which follow fairly directly from previous statement
9815 Again, these can be major results.
9820 These are smaller results needed to prove other statements.
9823 \begin_layout Proposition
9824 These are less major results which (hopefully) add to the general theory
9828 \begin_layout Conjecture
9829 These are statements provided without justification, which the author does
9830 not know how to prove, but which seem to be true (to the author, at least).
9833 \begin_layout Definition*
9834 Guess what this is for.
9835 The font is different for this environment than for the previous ones.
9839 \begin_layout Example*
9840 Used for examples illustrating proven results.
9843 \begin_layout Problem
9844 It's not really known what this is for.
9845 You should figure it out.
9848 \begin_layout Exercise*
9849 Write a description for this one.
9852 \begin_layout Remark
9853 This environment is also a type of theorem, usually a lesser sort of observation.
9856 \begin_layout Claim*
9857 Often used in the course of giving a proof of a larger result.
9861 Generally, these are used to break up long arguments, using specific instances
9867 The numbering scheme for cases is on its own, not together with other numbered
9873 At the end of this environment, a QED symbol (usually a square, but it can
9874 vary with different styles) is placed.
9875 If you want to have other environments within this one—for example, Case
9876 environments—and have the QED symbol appear only after them, then the other
9877 environments need to be nested within the proof environment.
9880 Nesting Environments
9886 for information on nesting.
9889 \begin_layout Standard
9890 And these environments are provided by
9891 \begin_inset Flex Code
9894 \begin_layout Plain Layout
9895 Theorems (AMS-Extended)
9903 \begin_layout Criterion*
9904 A required condition.
9907 \begin_layout Algorithm*
9908 A general procedure to be used.
9911 \begin_layout Axiom*
9912 This is a property or statement taken as true within the system being discussed.
9915 \begin_layout Condition*
9916 Sometimes used to state a condition assumed within the present context of
9921 Similar to a Remark.
9924 \begin_layout Notation*
9925 Used for the explanation of, yes, notation.
9928 \begin_layout Summary
9929 Do we really need to tell you?
9932 \begin_layout Acknowledgement*
9936 \begin_layout Conclusion*
9937 Sometimes used at the end of a long train of argument.
9941 Used in a way similar to Proposition, though perhaps lower on the scale.
9944 \begin_layout Standard
9945 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
9948 They need to be available on your system in order to use these environments.
9951 \begin_layout Section
9959 \begin_layout Standard
9965 \begin_layout Subsection
9969 \begin_layout Standard
9970 These are the layout files for some of the journals of the American Geophysical
9972 It is assumed that you have both the AGU's own class files and AGUplus
9973 installed (everything to be found at
9974 \begin_inset Flex URL
9977 \begin_layout Plain Layout
9979 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
9987 \begin_layout Subsection
9991 \begin_layout Standard
10001 They are still called this in the \SpecialChar LyX
10002 GUI, though their \SpecialChar LaTeX
10015 \begin_layout Standard
10016 Newly defined styles are
10053 These are mostly manuscript attributes and defined in the AGU class documentati
10057 \begin_layout Standard
10058 I suspect this is still badly incomplete.
10061 \begin_layout Subsection
10065 \begin_layout Standard
10082 \begin_layout Subsection
10086 \begin_layout Itemize
10089 Journal of Geophysical Research
10098 \begin_layout Standard
10099 Add your own, it isn't so hard! Look at the
10110 \begin_layout Subsection
10111 Bugs and things to remember
10114 \begin_layout Standard
10115 In order to use the new layouts, you must remember to do the following for
10119 \begin_layout Enumerate
10125 This can be done in the
10127 Layout\SpecialChar menuseparator
10132 Document\SpecialChar menuseparator
10136 (AGU articles are always in English, right? So
10140 choose a language.)
10143 \begin_layout Enumerate
10148 into the document's
10153 (Yes, this is a bug.)
10156 \begin_layout Enumerate
10157 Make sure you use the
10161 bibliography style, by entering
10165 into the second field of the Bib\SpecialChar TeX
10167 None of the standard styles will do.
10170 \begin_layout Section
10174 \begin_layout Standard
10180 \begin_layout Subsection
10184 \begin_layout Standard
10185 Broadway is for writing plays.
10186 The format is more decorative than Hollywood, and much less standardized.
10187 This format should be suitable for workshops.
10190 \begin_layout Subsection
10194 \begin_layout Standard
10195 The same as in Hollywood.
10198 \begin_layout Subsection
10202 \begin_layout Standard
10207 names as labels then cross-reference the label to insert the name.
10208 The cross-reference dialog will show the current cast of characters.
10211 \begin_layout Subsection
10212 Paper size and Margins
10215 \begin_layout Standard
10216 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10219 \begin_layout Subsection
10223 \begin_layout Standard
10224 The following environments are available.
10225 You can use broadway.bind to get the bind keys shown at the right.
10228 \begin_layout Itemize
10232 \begin_inset Newline newline
10237 You should not have to use this, but it is here for anything that does not
10241 \begin_layout Itemize
10245 \begin_inset space \hfill{}
10249 \begin_inset Newline newline
10254 Used to describe stage setting and the action.
10255 First use of speaker names in all CAPs.
10258 \begin_layout Itemize
10262 \begin_inset space \hfill{}
10266 \begin_inset Newline newline
10271 Automatically numbered.
10272 On screen it will be arabic, but will print as Roman.
10275 \begin_layout Itemize
10279 \begin_inset space \hfill{}
10283 \begin_inset Newline newline
10293 It is just centered text.
10296 \begin_layout Itemize
10300 \begin_inset space \hfill{}
10304 \begin_inset Newline newline
10309 Not automatically numbered.
10310 You supply the number.
10311 This is because I couldn't figure out how.
10314 \begin_layout Itemize
10318 \begin_inset space \hfill{}
10322 \begin_inset Newline newline
10327 A special case of Narrative to describe the setting and action as the curtain
10331 \begin_layout Itemize
10335 \begin_inset space \hfill{}
10339 \begin_inset Newline newline
10344 The speaker's (actor's) title, centered in all CAPS.
10347 \begin_layout Itemize
10351 \begin_inset space \hfill{}
10355 \begin_inset Newline newline
10360 Instructions to the speaker.
10361 The parentheses are automatically inserted.
10362 The ( will appear on screen, but both will be in the printed play.
10363 This environment is only used within
10370 \begin_layout Itemize
10374 \begin_inset space \hfill{}
10378 \begin_inset Newline newline
10383 What the Speaker says.
10386 \begin_layout Itemize
10390 \begin_inset space \hfill{}
10394 \begin_inset Newline newline
10399 The curtain comes down.
10402 \begin_layout Itemize
10406 \begin_inset space \hfill{}
10412 \begin_layout Itemize
10416 \begin_inset space \hfill{}
10422 \begin_layout Itemize
10426 \begin_inset space \hfill{}
10432 \begin_layout Standard
10436 \begin_layout Section
10440 \begin_layout Standard
10445 can be used to type letters according to German conventions.
10446 A template file is included in
10448 .../lyx/share/templates
10450 for you to use as a starting point.
10453 \begin_layout Section
10461 \begin_layout Standard
10467 \begin_layout Subsection
10471 \begin_layout Standard
10472 This is the layout file for the European Geophysical Society journals.
10477 can be downloaded from the web site of the EGS under
10478 \begin_inset Flex URL
10481 \begin_layout Plain Layout
10491 \begin_layout Subsection
10495 \begin_layout Standard
10498 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
10506 The current layout file is unfortunately very unmodular and would benefit
10507 from using the various
10514 \begin_layout Section
10518 \begin_layout Standard
10519 See the \SpecialChar LyX
10525 It contains all infos you need.
10528 \begin_layout Section
10531 Foil\SpecialChar TeX
10535 \begin_inset CommandInset label
10544 \begin_layout Standard
10550 \begin_layout Subsection
10554 \begin_layout Standard
10555 This section describes how to use \SpecialChar LyX
10556 to make slides for overhead projectors.
10557 There are two document classes that can do this: the default slides class
10560 Foil\SpecialChar TeX
10564 This section documents the latter.
10567 \begin_layout Standard
10568 I'm going to say this again, nice and clear, so that there's no misunderstanding
10572 \begin_layout Standard
10573 \begin_inset VSpace bigskip
10579 \begin_layout Standard
10583 This section documents the class
10584 \begin_inset Quotes eld
10592 \begin_inset Quotes erd
10600 \begin_layout Standard
10601 \begin_inset VSpace bigskip
10607 \begin_layout Standard
10608 If you're looking for the documentation for
10609 \begin_inset Quotes eld
10617 \begin_inset Quotes erd
10620 , check out section
10621 \begin_inset space ~
10625 \begin_inset CommandInset ref
10627 reference "sec:slitex"
10632 If your machine doesn't have the
10637 \begin_inset Quotes eld
10645 \begin_inset Quotes erd
10648 ] installed, you'll probably have to use the default
10652 class, which isn't quite as good as
10657 \begin_layout Standard
10662 class is designed for use with version 2.1 of the
10667 class file which is now an integral part of \SpecialChar LaTeX2e
10671 \begin_layout Subsection
10675 \begin_layout Standard
10676 Obviously, to use this document class, you need to select
10677 \begin_inset Quotes eld
10685 \begin_inset Quotes erd
10695 \begin_inset space ~
10701 There are some settings in the
10704 \begin_inset space ~
10709 dialog that you should know about that are specific to this class:
10712 \begin_layout Itemize
10713 Don't change the options
10724 \begin_inset space ~
10730 They're ignored by the
10737 \begin_layout Itemize
10738 The default font size is 20
10739 \begin_inset space \thinspace{}
10742 pt with the other options being 17
10743 \begin_inset space \thinspace{}
10747 \begin_inset space \thinspace{}
10751 \begin_inset space \thinspace{}
10757 \begin_layout Itemize
10758 The default font is
10766 but all math equations are still typeset in the usual roman font.
10769 \begin_layout Itemize
10772 Foil\SpecialChar TeX
10775 supports A4 and Letter paper sizes as well as a special size for working
10777 \begin_inset space \thinspace{}
10781 It doesn't support A5, B5, legal or executive paper sizes.
10784 \begin_layout Itemize
10785 Don't bother changing the
10789 settings because they are ignored anyway.
10790 All floats appear where they are defined in the text.
10793 \begin_layout Itemize
10798 setting behaves a bit differently for this class.
10801 Foil\SpecialChar TeX
10804 provides extensive footer and header capabilities including a user-defined
10807 \begin_inset space ~
10811 \begin_inset CommandInset ref
10813 reference "sec:foilfoot"
10818 The title page is treated differently to all other pages in the document
10827 has the logo centered at the bottom of the page (if one is defined).
10828 The possible page style choices and what they do are as follows:
10829 \begin_inset Separator parbreak
10836 \begin_layout Labeling
10837 \labelwidthstring MMMMMMM
10844 The final output contains no page numbers, or other headers or footers
10845 (except footnotes of course).
10849 \begin_layout Labeling
10850 \labelwidthstring MMMMMMM
10857 The final output contains page numbers centered at the bottom of the page.
10858 No other headings or footers (other than footnotes).
10861 \begin_layout Labeling
10862 \labelwidthstring MMMMMMM
10867 Page numbers in lower right corner.
10868 Additional headers and footers are also shown.
10869 This is also the default.
10872 \begin_layout Labeling
10873 \labelwidthstring MMMMMMM
10878 Gives you access to the
10882 package although its use with
10884 Foil\SpecialChar TeX
10887 is discouraged by the writer of the
10889 Foil\SpecialChar TeX
10892 package because of some potential page layout clashes.
10896 \begin_layout Subsubsection
10900 \begin_layout Standard
10901 The following options may be used in the extra class options in the
10903 Document\SpecialChar menuseparator
10909 \begin_layout Labeling
10910 \labelwidthstring MMMMMMx
10915 This sets up the page layout for 7.33
10916 \begin_inset space \thinspace{}
10920 \begin_inset space \thinspace{}
10923 in paper, which is about the same aspect ratio as a 35
10924 \begin_inset space \thinspace{}
10927 mm slide, making it a bit easier to work with this medium.
10930 \begin_layout Labeling
10931 \labelwidthstring MMMMMMx
10936 Places a rule across the page below the header on every page except the
10940 \begin_layout Labeling
10941 \labelwidthstring MMMMMMx
10946 Places a rule across the page above the footer on every page except the
10950 \begin_layout Labeling
10951 \labelwidthstring MMMMMMx
10956 This is automatically set each time you create a new
10963 Foil\SpecialChar TeX
10966 to use the dvips driver to rotate those pages that are set as landscape
10970 \begin_layout Labeling
10971 \labelwidthstring MMMMMMx
10976 Simply changes the page dimensions to those of a landscape page but doesn't
10978 Thus if you use this option you need to use an external program to rotate
10979 each page or feed your paper through your printer as landscape.
10980 Note that this option effectively reverses the roles of the
10988 environments (don't worry these are described in the next section).
10991 \begin_layout Labeling
10992 \labelwidthstring MMMMMMx
10997 Equation numbers on the left.
11000 \begin_layout Labeling
11001 \labelwidthstring MMMMMMx
11006 Flush-left equations.
11009 \begin_layout Subsection
11010 Supported Environments
11013 \begin_layout Standard
11014 Most of the environments commonly supported in other classes are also supported
11020 There are several additional environments provided by
11022 Foil\SpecialChar TeX
11025 as well as a couple added by \SpecialChar LyX
11027 The following environments are shared with other classes:
11030 \begin_layout Standard
11031 \begin_inset Flex Multiple Columns
11034 \begin_layout Itemize
11040 \begin_layout Itemize
11046 \begin_layout Itemize
11052 \begin_layout Itemize
11058 \begin_layout Itemize
11064 \begin_layout Itemize
11071 \begin_layout Itemize
11077 \begin_layout Itemize
11083 \begin_layout Itemize
11089 \begin_layout Itemize
11095 \begin_layout Itemize
11101 \begin_layout Itemize
11107 \begin_layout Itemize
11113 \begin_layout Itemize
11119 \begin_layout Itemize
11125 \begin_layout Itemize
11131 \begin_layout Itemize
11137 \begin_layout Itemize
11148 \begin_layout Standard
11149 That is, all the major environments apart from the sectioning environments.
11150 Since foils are essentially self-contained sections, with a title and body,
11153 Foil\SpecialChar TeX
11156 provides specific commands for starting new foils and these are:
11159 \begin_layout Itemize
11165 \begin_layout Itemize
11171 \begin_layout Standard
11173 also provides slightly modified versions of these two environments called:
11176 \begin_layout Itemize
11182 \begin_layout Itemize
11185 ShortRotatefoilhead
11188 \begin_layout Standard
11189 and the differences will be explained in the next section.
11192 \begin_layout Standard
11193 Since foils are often used in presenting ideas or new theorems and such
11196 Foil\SpecialChar TeX
11199 also provides a comprehensive box of goodies for presenting them:
11202 \begin_layout Standard
11203 \begin_inset Flex Multiple Columns
11206 \begin_layout Itemize
11212 \begin_layout Itemize
11218 \begin_layout Itemize
11224 \begin_layout Itemize
11230 \begin_layout Itemize
11236 \begin_layout Itemize
11242 \begin_layout Itemize
11248 \begin_layout Itemize
11254 \begin_layout Itemize
11260 \begin_layout Itemize
11266 \begin_layout Itemize
11277 \begin_layout Standard
11278 The starred versions are unnumbered while the unstarred versions are numbered.
11279 There are also two list environments added by \SpecialChar LyX
11283 \begin_layout Itemize
11289 \begin_layout Itemize
11295 \begin_layout Standard
11298 Foil\SpecialChar TeX
11301 provides some powerful header and footer capabilities that are best set
11302 in the preamble although they may be set at any point in a document.
11303 If you want to change these settings in your document the best place to
11304 do so is at the very top of a foil, i.
11305 \begin_inset space \thinspace{}
11311 \begin_inset space \space{}
11316 straight after the foilhead.
11319 \begin_layout Standard
11320 For this purpose, the following command styles are provided [
11327 \begin_layout Standard
11328 \begin_inset Flex Multiple Columns
11331 \begin_layout Itemize
11335 \begin_inset space ~
11341 \begin_layout Itemize
11347 \begin_layout Itemize
11351 \begin_inset space ~
11357 \begin_layout Itemize
11361 \begin_inset space ~
11367 \begin_layout Itemize
11371 \begin_inset space ~
11377 \begin_inset Separator parbreak
11384 \begin_layout Plain Layout
11385 \begin_inset space ~
11397 \begin_layout Standard
11398 There are also a few commands provided by
11400 Foil\SpecialChar TeX
11403 that aren't directly supported by \SpecialChar LyX
11404 but I'll tell you what they do and how
11405 to use them in section
11406 \begin_inset space ~
11410 \begin_inset CommandInset ref
11412 reference "sec:unsuppfoils"
11419 \begin_layout Subsection
11420 Building a Set of Foils
11423 \begin_layout Standard
11424 This section will give a simple introduction to using the different environments
11425 to build a set of foils.
11426 If you want to see an example set of foils, take a look at the
11430 file you find in \SpecialChar LyX
11438 \begin_layout Subsubsection
11439 Give It a Title Page
11442 \begin_layout Standard
11443 Unlike other classes that provide
11463 creates the title on a page of its own.
11464 If you leave out the
11468 environment \SpecialChar LaTeX
11469 will substitute the current date (every time you regenerate
11473 \begin_layout Subsubsection
11477 \begin_layout Standard
11478 As I mentioned earlier, there are four ways of starting a new foil.
11479 For portrait foils you should use
11488 The difference between these two environments is the amount of space between
11489 the title of the foil (the foilhead) and the body of the foil.
11492 \begin_layout Standard
11493 Landscape foils are generated using the
11499 ShortRotatefoilhead
11502 Again the only difference is the spacing between foilhead and body.
11503 Both of the short versions have 0.5
11504 \begin_inset space ~
11507 inches less separation between the foilhead and the body.
11511 \begin_layout Standard
11512 One problem with the support for landscape foils is the requirement that
11513 you have to use the
11517 driver to generate the PostScript output otherwise the foils won't be rotated.
11518 It is possible to get landscape foils even if you haven't got the
11522 driver provided you can feed your foils sideways through your printer ;-)
11525 \begin_layout Subsubsection
11526 Theorems, Lemmas, Proofs and more
11529 \begin_layout Standard
11530 Due to a small bug in \SpecialChar LyX
11531 you can't have two of the same type of these environments
11532 directly following each other.
11533 They must be separated by something.
11534 If you try, you will just be extending the previous environment as if you
11535 had merged the two environments together.
11536 So, how do you get around this problem? The simplest option is to insert
11537 some text between the two environments or add a
11542 environment between the two with just a
11543 \begin_inset Quotes eld
11551 \begin_inset Quotes erd
11555 This will force \SpecialChar LyX
11556 to produce two separate environments and hence the correct
11559 An example is provided in the example file included with the \SpecialChar LyX
11561 Remember, this problem only occurs if you are trying to place two of the
11562 same type of theorem-like environments one directly after the other.
11565 \begin_layout Subsubsection
11569 \begin_layout Standard
11570 You get all the commonly supported list styles found in other classes as
11571 well as two new ones.
11572 I'll only describe the new ones here.
11573 If you want to find out more about the other list environments check out
11579 If you intend to use itemized lists you might also want to read about the
11583 \begin_inset space ~
11587 \begin_inset space ~
11592 dialog described above in section
11593 \begin_inset space ~
11597 \begin_inset CommandInset ref
11599 reference "sec:bullet"
11606 \begin_layout Standard
11607 The two new list styles,
11615 , are designed to make it easier for you to create lists of do's and don'ts
11616 or right and wrong by providing dedicated environments that use a tick
11617 or a cross as the label of the list.
11618 These lists are in fact dedicated variants of the
11623 They do however require that you have the
11627 packages installed.
11630 \begin_layout Subsubsection
11634 \begin_layout Standard
11637 Foil\SpecialChar TeX
11640 redefines the floating tables and figures so that they appear exactly where
11641 they are in the text rather than pushing them to the top of the page or
11642 to some user specified location.
11643 In fact if you change the float placement settings they are simply ignored.
11646 \begin_layout Subsubsection
11647 Page Headers and Footers
11648 \begin_inset CommandInset label
11650 name "sec:foilfoot"
11657 \begin_layout Standard
11661 \begin_inset space ~
11670 are two commands used to control the left-footer text string.
11671 The first is meant to allow you to include a graphic logo on your foils
11673 \begin_inset Quotes eld
11678 Foil\SpecialChar TeX
11682 \begin_inset Quotes erd
11686 While the second is meant to provide a classification for the audience,
11690 \begin_inset space \thinspace{}
11696 \begin_inset space \space{}
11700 It is empty by default.
11703 \begin_layout Standard
11704 The remaining page corners can be filled by
11707 \begin_inset space ~
11712 (which defaults to page numbers),
11715 \begin_inset space ~
11723 \begin_inset space ~
11731 \begin_layout Subsection
11734 Foil\SpecialChar TeX
11738 \begin_inset CommandInset label
11740 name "sec:unsuppfoils"
11747 \begin_layout Standard
11748 All the commands mentioned below need to be set in a
11758 within another environment.
11761 \begin_layout Subsubsection
11765 \begin_layout Standard
11766 All lengths are adjusted using the
11789 should be replaced by the name given to the length you want to change and
11794 is the length value.
11795 All lengths should be specified in units of length such as inches (
11807 ) or relative to some document or font-based length such as
11817 \begin_layout Standard
11818 It's possible to change the spacing between a foilhead and the body of the
11819 foil by adjusting the length specified by
11826 For example, to make
11831 \begin_inset space \space{}
11834 in closer to their bodies put the following in the preamble:
11840 foilheadskip}{-0.5in}
11843 \begin_layout Standard
11844 The spacings around floats can be adjusted by setting these lengths:
11847 \begin_layout Labeling
11848 \labelwidthstring MMMMMMMMMMM
11855 Separation between the text and the top of the float
11858 \begin_layout Labeling
11859 \labelwidthstring MMMMMMMMMMM
11866 Separation between the float and the caption
11869 \begin_layout Labeling
11870 \labelwidthstring MMMMMMMMMMM
11877 Separation between the caption and the following text
11880 \begin_layout Labeling
11881 \labelwidthstring MMMMMMMMMMM
11888 You can make the captions narrower than the surrounding text by adjusting
11890 Best done relative to
11899 \begin_layout Standard
11900 There are also several title page related lengths that you may find useful
11901 if you have a long title or several authors:
11904 \begin_layout Labeling
11905 \labelwidthstring MMMMMMMMMMM
11912 Separation from headers to
11917 \begin_layout Labeling
11918 \labelwidthstring MMMMMMMMMMM
11936 \begin_layout Labeling
11937 \labelwidthstring MMMMMMMMMMM
11951 \begin_layout Labeling
11952 \labelwidthstring MMMMMMMMMMM
11968 \begin_layout Labeling
11969 \labelwidthstring MMMMMMMMMMM
11985 \begin_layout Standard
11986 The last length related command affects all the list environments.
11997 a list environment then all the vertical spacing between the list items
11999 Note that this is a command not a length so it doesn't require
12005 like the stuff mentioned above.
12008 \begin_layout Subsubsection
12009 Headers and Footers
12012 \begin_layout Standard
12025 commands control whether the logo in the
12029 definition appear on a given page.
12036 in the preamble then none of the foils will have the logo on them.
12037 If you don't want the logo on a particular page place the
12043 directly after the foilhead of that page and the
12049 directly after the next foilhead.
12052 \begin_layout Standard
12053 If you decide to use the
12057 page style setting in the
12060 \begin_inset space ~
12065 dialog you should probably add
12075 to your preamble so headers and footers on landscape pages are correctly
12076 placed when rotated.
12077 This is due to some clashes between the page layouts provided by the
12088 \begin_layout Section
12089 Hollywood (Hollywood spec scripts)
12092 \begin_layout Standard
12098 \begin_layout Subsection
12102 \begin_layout Standard
12103 Getting the format of a Hollywood script right is a
12104 \begin_inset Quotes eld
12108 \begin_inset Quotes erd
12111 It is designed to make the readers focus on content and to be easy and
12112 familiar for the actors to read.
12113 Each page of a script should be one minute of film.
12114 Nothing goes in a script that you cannot see or hear on screen.
12115 The courier 12 pt font should be used throughout.
12119 \begin_layout Subsection
12123 \begin_layout Standard
12124 Speakers' lines should NEVER break in mid-sentence.
12125 If a speaker's lines continue over a page break, repeat the
12129 title followed by (Cont'd).
12132 \begin_layout Subsection
12136 \begin_layout Standard
12141 names as labels then cross-reference the label to insert the name.
12142 The cross-reference dialog will show the current cast of characters.
12143 You can use this to insert the speaker name in narratives also.
12146 \begin_layout Subsection
12147 Paper size and Margins
12150 \begin_layout Standard
12151 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
12154 \begin_layout Subsection
12158 \begin_layout Standard
12159 The following environments are available.
12160 You can use hollywood.bind to get the bind keys shown at the right.
12163 \begin_layout Itemize
12167 \begin_inset Newline newline
12172 Used where nothing else works.
12176 \begin_layout Itemize
12182 \begin_inset space \hfill{}
12190 \begin_inset Newline newline
12193 Usually followed by something like
12194 \begin_inset Quotes eld
12197 on Sally waking up.
12198 \begin_inset Quotes erd
12204 \begin_layout Itemize
12208 \begin_inset space \hfill{}
12212 \begin_inset Newline newline
12217 Introduces a new INTERIOR camera set-up.
12218 Always followed by DAY or NIGHT, or something similar to define the lighting
12220 Everthing on this line in CAPS.
12223 \begin_layout Itemize
12227 \begin_inset space \hfill{}
12231 \begin_inset Newline newline
12236 Introduces a new EXTERIOR camera set-up.
12237 Everthing on this line in CAPS.
12240 \begin_layout Itemize
12244 \begin_inset space \hfill{}
12248 \begin_inset Newline newline
12253 The character speaking.
12256 \begin_layout Itemize
12260 \begin_inset space \hfill{}
12264 \begin_inset Newline newline
12269 Instructions to the speaker.
12270 The () are automatically inserted, but only the ( will show in \SpecialChar LyX
12272 Both will be printed.
12275 \begin_layout Itemize
12279 \begin_inset space \hfill{}
12283 \begin_inset Newline newline
12295 \begin_layout Itemize
12299 \begin_inset space \hfill{}
12303 \begin_inset Newline newline
12308 Camera movement instruction.
12310 \begin_inset space \thinspace{}
12314 \begin_inset space \space{}
12320 \begin_layout Itemize
12324 \begin_inset space \hfill{}
12330 \begin_layout Itemize
12334 \begin_inset space \hfill{}
12340 \begin_layout Itemize
12344 \begin_inset space \hfill{}
12350 \begin_layout Itemize
12354 \begin_inset space \hfill{}
12360 \begin_layout Subsection
12364 \begin_layout Itemize
12368 \begin_layout Itemize
12372 \begin_layout Itemize
12374 \begin_inset space \thinspace{}
12381 \begin_layout Itemize
12386 \begin_layout Itemize
12387 PAN — camera movement
12390 \begin_layout Itemize
12391 INSERT — cut to close-up of
12394 \begin_layout Section
12398 \begin_layout Standard
12401 Panayotis Papasotiriou
12404 \begin_layout Subsection
12408 \begin_layout Standard
12409 The ijmpc package is a set of macros that facilitates electronic manuscript
12412 International Journal of Modern Physics C
12415 Similarly, the ijmpd package is for creating manuscripts to be submitted
12418 International Journal of Modern Physics D
12421 Both journals are published by World Scientific.
12422 The corresponding document classes are named
12431 These files, together with instructions for the authors, can be downloaded
12433 \begin_inset Flex URL
12436 \begin_layout Plain Layout
12438 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
12444 \begin_inset Flex URL
12447 \begin_layout Plain Layout
12449 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
12455 Both packages are modified versions of the standard
12456 \begin_inset Quotes eld
12460 \begin_inset Quotes erd
12463 package, and they are almost (but not exactly) identical.
12464 Most of their features are supported by \SpecialChar LyX
12466 I have used \SpecialChar LyX
12467 successfully to write articles submitted to both journals
12468 without any problem.
12471 \begin_layout Subsection
12475 \begin_layout Standard
12476 As usual, the easiest way to write a paper is to start with a template.
12479 File\SpecialChar menuseparator
12495 This will give an (almost) empty document that includes the most common
12496 fields found in a manuscript.
12497 Simply overwrite the existing text (including the brackets,
12502 You should keep in mind the following remarks.
12505 \begin_layout Enumerate
12507 won't let you change the font size and the page style of the document,
12508 because such modifications are not allowed by both packages.
12511 \begin_layout Enumerate
12512 The language of the document should not be changed.
12513 Before previewing your paper, be sure that the babel package is not used.
12514 To do this, click on
12516 Tools\SpecialChar menuseparator
12527 checkbox in the language settings, and click on
12535 , if you wish to make this change permanent).
12538 \begin_layout Enumerate
12540 \begin_inset Quotes eld
12544 \begin_inset Quotes erd
12547 style must be used to define keywords.
12550 \begin_layout Enumerate
12551 The ijmpc package provides a style named
12552 \begin_inset Quotes eld
12555 Classification Codes
12556 \begin_inset Quotes erd
12559 , which can be used to define classification codes, such as PACS numbers.
12560 Note that this facility is not supported by the ijmpd package.
12563 \begin_layout Enumerate
12564 Several new environments are available:
12565 \begin_inset Quotes eld
12569 \begin_inset Quotes erd
12573 \begin_inset Quotes eld
12577 \begin_inset Quotes erd
12581 \begin_inset Quotes eld
12585 \begin_inset Quotes erd
12589 \begin_inset Quotes eld
12593 \begin_inset Quotes erd
12597 \begin_inset Quotes eld
12601 \begin_inset Quotes erd
12605 \begin_inset Quotes eld
12609 \begin_inset Quotes erd
12613 \begin_inset Quotes eld
12617 \begin_inset Quotes erd
12621 \begin_inset Quotes eld
12625 \begin_inset Quotes erd
12629 \begin_inset Quotes eld
12633 \begin_inset Quotes erd
12637 \begin_inset Quotes eld
12641 \begin_inset Quotes erd
12645 \begin_inset Quotes eld
12649 \begin_inset Quotes erd
12653 \begin_inset Quotes eld
12657 \begin_inset Quotes erd
12661 \begin_inset Quotes eld
12665 \begin_inset Quotes erd
12669 \begin_inset Quotes eld
12673 \begin_inset Quotes erd
12677 Their use is more or less obvious.
12679 supports all these environments; it will use the proper label, text style,
12680 and numbering scheme for each of them.
12683 \begin_layout Enumerate
12684 Both packages use basic citations; the natbib package should not be used.
12685 In \SpecialChar LyX
12686 , citation references are shown as usual; in the output, citations are
12687 shown as superscripts.
12688 If you want to use a citation as normal text, you should use the
12693 \begin_inset space \thinspace{}
12697 \begin_inset space \space{}
12701 \begin_inset Quotes eld
12705 \begin_inset space \space{}
12715 \begin_inset Quotes erd
12721 \begin_layout Enumerate
12723 \begin_inset Quotes eld
12727 \begin_inset Quotes erd
12730 section in both packages.
12731 To put acknowledgments, just use the
12732 \begin_inset Quotes eld
12736 \begin_inset Quotes erd
12742 \begin_layout Enumerate
12743 Appendices may be added to the paper,
12747 the Acknowledgments and
12753 provides a special environment, called
12754 \begin_inset Quotes eld
12758 \begin_inset Quotes erd
12761 which marks the beginning of the appendices.
12762 This environment should be left blank; it just sends a \SpecialChar LaTeX
12763 command, but nothing
12765 In \SpecialChar LyX
12767 \begin_inset Quotes eld
12771 \begin_inset Quotes erd
12774 is printed with blue letters, as a signal that all sections after that
12775 point are appendices.
12776 To write an appendix, use the
12777 \begin_inset Quotes eld
12781 \begin_inset Quotes erd
12786 will number each appendix with capital letters, as required by both journals.
12788 \begin_inset Quotes eld
12792 \begin_inset Quotes erd
12799 be present before the first appendix; if not, all appendices will be numbered
12800 as normal sections in the output.
12803 \begin_layout Enumerate
12804 The ijmpc and the ijmpd packages use the
12808 command to implement table captions.
12809 As a result, a table created by \SpecialChar LyX
12810 is printed correctly, but its caption
12812 However, you can use some \SpecialChar TeX
12813 code to overcome this problem, so that captions
12814 are printed as expected.
12815 To do so, create a float table as usual, remove the caption, and replace
12816 it with the \SpecialChar TeX
12827 (sic); you must also the \SpecialChar TeX
12832 immediately after the tabular material.
12833 Study the example table included in the template files to see how this
12834 trick is implemented.
12835 Alternatively, If you need table captions, you should implement the whole
12840 file, then include this file to the \SpecialChar LyX
12843 Insert\SpecialChar menuseparator
12844 File\SpecialChar menuseparator
12846 \begin_inset space ~
12852 Details on how to create a table float can be found in the files
12860 , included in the corresponding packages.
12863 \begin_layout Subsection
12864 Preparing a paper for submission
12867 \begin_layout Standard
12868 Before you submit your paper you must export the \SpecialChar LyX
12869 document as a \SpecialChar LaTeX
12872 File\SpecialChar menuseparator
12873 Export\SpecialChar menuseparator
12881 \begin_layout Plain Layout
12882 Actually you have the choice between \SpecialChar LaTeX
12883 (plain) and pdflatex.
12884 If you intend to use pdflatex to prepare the paper, you should use the
12885 pdflatex option so that included graphics are converted to PDF format,
12886 ready for use by pdflatex.
12891 , then make the following changes to the resulting
12898 \begin_layout Enumerate
12899 Remove the comment lines before the
12908 \begin_layout Enumerate
12909 Remove everything between (and including) the
12921 commands, except for any commands you specifically put into the \SpecialChar LaTeX
12925 \begin_layout Standard
12930 file should be saved and processed through \SpecialChar LaTeX
12931 as many times as necessary.
12932 You may also want to check the resulting
12939 \begin_layout Subsection
12940 Use of \SpecialChar TeX
12944 \begin_layout Standard
12945 The use of \SpecialChar TeX
12946 code is reduced to two commands, which must be placed at the
12947 top of the document.
12948 If you started writing your paper by using the
12956 template, the \SpecialChar TeX
12957 code needed is already in its place; you usually don't need
12959 You may only modify the first \SpecialChar TeX
12960 code to specify the information printed
12961 to the top of odd and even pages (authors' names and short paper's title,
12963 This \SpecialChar TeX
12964 code must have the form
12968 markboth{Authors' Names}{Short Paper's Title}
12973 \begin_layout Section
12977 \begin_layout Standard
12983 \begin_layout Subsection
12987 \begin_layout Standard
12988 The iopart package provides a document class to create electronic manuscript
12989 submission to the journals published by the Institute of Physics.
12990 Instructions for the authors how to create a paper using the iopart class
12991 can be downloaded together with the iopart package from the site
12992 \begin_inset Flex URL
12995 \begin_layout Plain Layout
12997 ftp://ftp.iop.org/pub/journals/latex2e
13005 \begin_layout Subsection
13009 \begin_layout Standard
13010 The easiest way to write a paper is to start with the file
13014 that is available in \SpecialChar LyX
13015 's examples files folder.
13016 Open this file, save it under a new name, and start writing.
13017 The example file explains how to use the special text environments.
13018 Here are the most important advices:
13021 \begin_layout Itemize
13022 To be able to compile your document to a PDF, PS, or DVI, ensure that the
13025 Use AMS math package
13027 in the document settings under
13034 \begin_layout Itemize
13037 The title environment defines the kind of your paper.
13038 So use one of the following environments for the title:
13041 \begin_inset Separator parbreak
13048 \begin_layout Itemize
13057 \begin_layout Itemize
13066 \begin_layout Itemize
13072 for a Topical review
13075 \begin_layout Itemize
13084 \begin_layout Itemize
13093 \begin_layout Itemize
13099 for a Paper (same as Title)
13102 \begin_layout Itemize
13108 for a Preliminary communication
13111 \begin_layout Itemize
13117 for a Rapid communication
13120 \begin_layout Itemize
13126 for a Letter to the editor
13130 \begin_layout Itemize
13133 All title environments except of
13137 can have an optional short title.
13140 \begin_layout Itemize
13141 There is a general title environment
13145 which is not directly supported by the \SpecialChar LyX
13147 This can be used as \SpecialChar TeX
13148 code when your document doesn't fit into one of the
13152 \begin_layout Standard
13153 For more informations like hints for special table and formula formatting,
13154 look at the IOP author guidelines.
13157 \begin_layout Section
13161 \begin_layout Standard
13164 Panayotis Papasotiriou
13167 \begin_layout Subsection
13171 \begin_layout Standard
13172 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
13173 that facilitates electronic manuscript submission to the journals they
13175 Most known of them (at least in my domain of interest) are
13177 Astrophysics and Space Science
13183 , but there are many others (see a complete list at
13184 \begin_inset Flex URL
13187 \begin_layout Plain Layout
13189 http://www.wkap.nl/jrnllist.htm/JRNLHOME
13195 The Kluwer package may be downloaded from the site
13196 \begin_inset Flex URL
13199 \begin_layout Plain Layout
13201 http://www.wkap.nl/kaphtml.htm/STYLEFILES
13207 A complete user guide is contained in that package (but it can also be
13208 downloaded separately).
13211 \begin_layout Standard
13213 supports many features of the package but not everything.
13214 However, the \SpecialChar TeX
13215 code needed is reduced to some
13216 \begin_inset Quotes eld
13220 \begin_inset Quotes erd
13223 commands of the package (see
13224 \begin_inset space ~
13228 \begin_inset CommandInset ref
13230 reference "subsec:kluwer_peculiarities"
13235 I have recently used \SpecialChar LyX
13236 to write an article submitted to the
13238 Astrophysics and Space Science
13240 without any problem.
13243 \begin_layout Subsection
13247 \begin_layout Standard
13248 The easiest way to write a paper is to start with the Kluwer template file.
13251 File\SpecialChar menuseparator
13263 This will give an (almost) empty document that includes the most common
13264 fields found in a manuscript and a short description of their use.
13265 As in most templates, simply overwrite the existing text (including the
13270 ) with the correct information.
13273 \begin_layout Subsection
13274 Preparing a paper for submission
13277 \begin_layout Standard
13278 As in the AAS\SpecialChar TeX
13279 package, before you submit your paper to a journal you must
13281 \begin_inset Quotes eld
13285 \begin_inset Quotes erd
13291 \begin_layout Enumerate
13292 Export your paper as a \SpecialChar LaTeX
13294 To do this, click on
13296 File\SpecialChar menuseparator
13297 Export\SpecialChar menuseparator
13305 \begin_layout Enumerate
13310 file with a text editor and make the following changes
13311 \begin_inset Separator parbreak
13318 \begin_layout Enumerate
13319 remove the comment lines before the
13328 \begin_layout Enumerate
13329 remove everything between (and including) the
13341 commands, except for any commands you specifically put into the \SpecialChar LaTeX
13345 \begin_layout Standard
13354 \begin_layout Enumerate
13359 file through \SpecialChar LaTeX
13360 as many times as necessary (usually up to three).
13363 \begin_layout Enumerate
13369 \begin_inset space \thinspace{}
13373 \begin_inset space \space{}
13380 , and check if everything is OK (it should, if you didn't make any mistake).
13383 \begin_layout Subsection
13384 \begin_inset Quotes eld
13388 \begin_inset Quotes erd
13391 of the Kluwer package
13392 \begin_inset CommandInset label
13394 name "subsec:kluwer_peculiarities"
13401 \begin_layout Standard
13402 The Kluwer package has the following
13403 \begin_inset Quotes eld
13407 \begin_inset Quotes erd
13413 \begin_layout Enumerate
13414 It is possible to write multiple articles in the same \SpecialChar LaTeX
13419 \begin_layout Plain Layout
13420 I can't imagine any good reason to do this.
13426 Each article must be included in the environment
13427 \begin_inset Quotes eld
13431 \begin_inset Quotes erd
13435 Unfortunately, this environment cannot be omitted, even if you write just
13437 Therefore, each article starts with the command
13443 and, obviously, ends with the command
13450 Although this can be implemented in \SpecialChar LyX
13451 , I didn't included it, since it looks
13452 ugly and can confuse the novice user.
13453 Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
13456 \begin_inset Quotes eld
13461 \begin_inset Quotes erd
13467 \begin_layout Enumerate
13468 Information given at the beginning of the article (i.
13469 \begin_inset space \thinspace{}
13473 \begin_inset space \space{}
13476 title, subtitle, author, institution, running title, running author, abstract
13477 and keywords) must be included in an environment called
13478 \begin_inset Quotes eld
13482 \begin_inset Quotes erd
13486 This is not implemented in \SpecialChar LyX
13487 , so you must enter title, subtitle etc.
13488 \begin_inset space ~
13491 between two \SpecialChar TeX
13507 \begin_layout Enumerate
13508 According to the user manual, the label of each bibliography item must be
13532 \begin_layout Standard
13537 template takes care of all these
13538 \begin_inset Quotes eld
13542 \begin_inset Quotes erd
13546 If you start a new paper using this template you don't need to do anything
13551 \begin_layout Enumerate
13552 don't delete the \SpecialChar TeX
13553 code included in the template, and
13556 \begin_layout Enumerate
13557 copy the example bibliography item included in the template and modify it
13558 as necessary to enter new bibliography items.
13561 \begin_layout Section
13565 \begin_layout Standard
13571 \begin_layout Subsection
13575 \begin_layout Standard
13576 The \SpecialChar LyX
13579 article (koma-script)
13583 report (koma-script)
13601 correspond to the \SpecialChar LaTeX
13619 \begin_inset space ~
13622 of the Koma-Script family.
13623 They are replacements for the standard document classes
13639 , resp., and fit better to European typography conventions in a number of
13643 \begin_layout Itemize
13644 Standard character size is 11pt in
13646 article (koma-script)
13650 report (koma-script)
13658 letter (koma-script)
13663 \begin_layout Itemize
13664 Headings, labels of the description environment, and a number of elements
13667 letter (koma-script)
13669 document class are set in a bold sans serif font.
13673 \begin_layout Plain Layout
13674 There is a big difference between the bold sans serif old cm fonts and new
13675 ec fonts, especially in the appearance of headings.
13676 In comparison, the ec bold sans serif fonts look a bit thin.
13677 Here the \SpecialChar LaTeX
13686 helps to produce the
13687 \begin_inset Quotes eld
13691 \begin_inset Quotes erd
13694 appearance when using the ec fonts.
13699 The numbering of chapter headings is made in the same way as the numbering
13700 of section headings, that is without the extra line
13701 \begin_inset Quotes eld
13704 Chapter\SpecialChar ldots
13706 \begin_inset Quotes erd
13710 In addition, the appearance of the headings can be modified by using a
13711 number of options (in \SpecialChar LyX
13712 to be entered in the field
13715 \begin_inset space ~
13722 Layout\SpecialChar menuseparator
13729 \begin_layout Itemize
13730 The main means in the Koma-Script document classes to design the type area
13739 (in \SpecialChar LyX
13740 to be entered in the extra class options field in the dialog
13742 Document\SpecialChar menuseparator
13746 They make a clearer modification of page margins possible as do the options
13749 Document\SpecialChar menuseparator
13756 \begin_layout Itemize
13757 The \SpecialChar LaTeX
13758 document classes of the Koma-Script family define a number of additional
13760 Those part of it which makes sense in \SpecialChar LyX
13761 is implemented in corresponding
13765 \begin_layout Standard
13766 Detailed descriptions of the \SpecialChar LaTeX
13767 document classes of the Koma-Script family
13768 can be found in the Koma-Script documentation
13779 \begin_layout Subsection
13780 article (koma-script), report (koma-script), and book (koma-script)
13783 \begin_layout Standard
13784 The document classes
13786 article (koma-script)
13790 report (koma-script)
13800 are implemented in the layout files
13813 They contain all the paragraph types of the corresponding standard document
13826 , resp., partly modified, with the exception of the \SpecialChar LyX
13831 -type, which is replaced by the new
13835 -type having the same functionality.
13840 -Type there is a number of new paragraph types added.
13847 letter (koma-script)
13852 \begin_layout Itemize
13861 : are equivalents to
13869 , resp., additionally inserting an entry in the table of contents.
13878 are not contained in
13880 article (koma-script)
13885 \begin_layout Itemize
13894 : behave exactly as
13902 , resp., additionally clearing running heads.
13907 is not contained in
13909 article (koma-script)
13915 \begin_layout Plain Layout
13928 report (koma-script)
13930 , but since this is identical to
13934 , is has not been implemented in \SpecialChar LyX
13943 \begin_layout Itemize
13948 : generates a heading directly above the following paragraph in the standard
13949 character size without affecting the structure of the document.
13952 \begin_layout Itemize
13961 are special captions which respect the different space settings needed
13962 for captions placed above or below an element (if you follow strict typographic
13963 rules, you might want to place table captions always above the table).
13964 You can also use the class option
13968 , which will switch
13981 You need at least Koma-Script version 2.8q to use this.
13984 \begin_layout Itemize
13989 : can be used to set a bonmot, e.
13990 \begin_inset space \thinspace{}
13994 \begin_inset space \space{}
13997 at the beginning of a chapter.
13998 If you use the optional argument (
14000 Insert\SpecialChar menuseparator
14002 \begin_inset space ~
14007 ), you can insert the dictum's author there.
14008 Dictum and author are separated by a line.
14009 You need at least Koma-Script version 2.8q to use this.
14014 is not contained in
14016 article (koma-script)
14021 \begin_layout Standard
14022 The following types, together with the standard types
14034 , form the title area of the document.
14035 They must be entered ahead of the first
14036 \begin_inset Quotes eld
14040 \begin_inset Quotes erd
14047 \begin_layout Plain Layout
14048 The corresponding \SpecialChar LaTeX
14049 commands must appear before the
14060 When such a type is used more than once, the latter usage overwrites the
14061 former one, that means, for every type only the latest usage is valid.
14062 The order of the different types however has, like
14074 , no effect on the appearance of the produced document.
14077 \begin_layout Itemize
14082 : produces a centered paragraph above the ordinary title (
14094 ) for the subject of the document.
14097 \begin_layout Itemize
14102 : produces a centered paragraph below the ordinary title (
14114 ) for the publishers' name.
14117 \begin_layout Itemize
14124 report (koma-script)
14130 produces a centered paragraph on its own page behind the title page, or
14133 article (koma-script)
14135 produces a centered paragraph below the ordinary title (
14151 ) for a dedication.
14154 \begin_layout Itemize
14159 : produces a left aligned paragraph above the ordinary title (
14175 ) for a document`s head.
14178 \begin_layout Itemize
14183 : produces in a double-sided print in
14185 report (koma-script)
14191 a left-aligned paragraph at the top of the title page`s back or has no
14192 effect in a single-sided print or in
14194 article (koma-script)
14199 \begin_layout Itemize
14204 : produces in a double-sided print in
14206 report (koma-script)
14212 a left-aligned paragraph at the bottom of the title page`s back or has
14213 no effect in a single-sided print or in
14215 article (koma-script)
14220 \begin_layout Itemize
14225 : produces a special
14226 \begin_inset Quotes eld
14230 \begin_inset Quotes erd
14233 page ahead of the actual document containing a paragraph without special
14237 \begin_layout Standard
14238 The layout files for the document classes
14240 article (koma-script)
14244 report (koma-script)
14250 do include the file
14255 This is thought of as a place to define your own types.
14260 in your personal layout directory and edit the file!
14263 \begin_layout Subsection
14264 letter (koma-script)
14267 \begin_layout Standard
14271 letter (koma-script)
14273 is implemented in the layout file
14278 It contains all the paragraph types of the corresponding standard document
14283 , partly modified, with the exception of the \SpecialChar LyX
14297 type, which is replaced by the new
14302 In addition, it contains, in contrast to the standard document class, the
14321 Furthermore, there are a number of new letter specific types.
14324 \begin_layout Standard
14325 The appearance of the letter produced by this document class can be controlled
14326 by a number of \SpecialChar LaTeX
14327 commands, which you can put in the \SpecialChar LaTeX
14332 \begin_layout Plain Layout
14333 For example, the standard appearance of the letter`s heading, consisting
14334 of name and address, is quite self-willed.
14336 \begin_inset Quotes eld
14340 \begin_inset Quotes erd
14343 heading is produced by the following \SpecialChar LaTeX
14344 commands in the preamble:
14347 \begin_layout LyX-Code
14357 \begin_layout LyX-Code
14373 \begin_layout LyX-Code
14383 \begin_layout LyX-Code
14403 A detailed German description of such \SpecialChar LaTeX
14404 commands can be found in the Koma-Script
14410 With it, the letter's author can produce his personal letter layout.
14413 \begin_layout Standard
14422 define the beginning of the letter and must be used in every letter.
14423 To emphasize them in the \SpecialChar LyX
14424 document class, they are marked with the letter
14434 \begin_inset space ~
14437 in the left margin.
14438 It is possible to write any number of letters in one file.
14443 type produces a new letter using the same addressee and a
14447 type produces a new addressee.
14464 are ordinary paragraph types and can also be used several times in one
14465 and the same letter.
14468 \begin_layout Itemize
14473 : produces a paragraph for the addressee and implicitly defines the beginning
14477 \begin_layout Itemize
14482 : produces a paragraph for the form of address and implicitly produces a
14486 \begin_layout Itemize
14491 : produces a paragraph for a close.
14494 \begin_layout Itemize
14499 : produces a paragraph for a postscript.
14502 \begin_layout Itemize
14507 : produces a paragraph for a distribution list.
14510 \begin_layout Itemize
14515 : produces a paragraph for enclosures.
14518 \begin_layout Standard
14559 are input types provided with a label to enter information, which will
14560 be processed by the document class.
14564 \begin_layout Plain Layout
14565 It could be seen as a matter of inconsequence, that the types
14573 described above are not such input types as well.
14574 Because of the special meaning of those types, however, I have implemented
14575 them as ordinary paragraph types with a one letter mark in the left margin.
14576 Moreover, it would affect my feeling of symmetry, if the
14584 type had such a serious different appearance.
14589 The types must be used ahead of the corresponding
14596 \begin_layout Standard
14597 An implementation of these types in a WYSIWYG fashion does not seem to make
14598 sense, because the real appearance of the produced letter does not only
14599 depend on the usage of the particular type, but also on other factors.
14600 For example, a signature entered in the
14604 type will in the standard behavior appear in the produced letter only,
14605 when in the same letter also a
14610 The entered value of the
14614 type will in the standard behavior not appear in the produced letter at
14616 The possibility to design the letter`s heading freely is already indicated
14617 in a footnote above.
14620 \begin_layout Standard
14621 The input types can also be used as empty paragraphs.
14622 This makes sense e.
14623 \begin_inset space \thinspace{}
14627 \begin_inset space \space{}
14639 type is not used at all, in the standard behavior the value of the
14643 type is used as signature, whereas if an empty
14647 type is used, no signature value is defined.
14650 \begin_layout Standard
14651 By using the input types it is possible to write a letter template, containing
14652 filled input types with your personal dates (name, address, etc.) and empty
14653 input types for other dates you want to enter.
14656 \begin_layout Itemize
14661 : sender's name, in the standard behavior appears as a centered paragraph
14662 in small caps in the letter`s heading.
14665 \begin_layout Itemize
14670 : sender's signature, in the standard behavior appears below the
14679 type is used, the value of the
14683 type appears instead.
14686 \begin_layout Itemize
14691 : sender's address, in the standard behavior appears in a centered paragraph
14692 in the letter`s heading below the sender's name.
14695 \begin_layout Itemize
14700 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
14711 \begin_layout Itemize
14716 : place of the letter`s making.
14719 \begin_layout Itemize
14724 : date of the letter`s making.
14733 , in the standard behavior, produce the place and the date in a right-aligned
14734 line below the addressee's field.
14739 type is used, neither place nor date appear, independent of the value of
14749 type is used, the date of the letter `s production is used.
14752 \begin_layout Itemize
14757 : sender`s back address, in the standard behavior appears above the addressee's
14758 field in a small sans serif font.
14761 \begin_layout Itemize
14766 : special mail information, in the standard behavior appears underlined
14767 above the addressee's field below the back address.
14770 \begin_layout Itemize
14775 : additional information, in the standard behavior appears on right side
14776 below the addressee`s field.
14779 \begin_layout Itemize
14784 : the letter's title, in the standard behavior appears in a big, bold, sans
14785 serif font above the subject.
14788 \begin_layout Itemize
14793 : the letter's subject, in the standard behavior appears in a bold font
14801 \begin_layout Standard
14822 produce a business letter like line above the
14826 line containing the fields
14827 \begin_inset Quotes eld
14831 \begin_inset Quotes erd
14835 \begin_inset Quotes eld
14839 \begin_inset Quotes erd
14843 \begin_inset Quotes eld
14847 \begin_inset Quotes erd
14851 \begin_inset Quotes eld
14855 \begin_inset Quotes erd
14859 \begin_inset Quotes eld
14863 \begin_inset Quotes erd
14867 \begin_inset Quotes eld
14871 \begin_inset Quotes erd
14875 For the date field, the value of the
14881 \begin_inset Quotes eld
14884 business letter types
14885 \begin_inset Quotes erd
14888 is used, the value of the
14892 type however does not appear, but only the \SpecialChar LaTeX
14900 The ordinary output of place and date in a right-aligned line below the
14901 addressee`s field is suppressed.
14902 The types are implemented as input types provided with a label and must
14903 be used ahead of the corresponding
14910 \begin_layout Itemize
14918 \begin_layout Itemize
14926 \begin_layout Itemize
14934 \begin_layout Itemize
14942 \begin_layout Itemize
14950 \begin_layout Subsection
14951 The new letter class: letter (koma-script v.2)
14954 \begin_layout Standard
14960 \begin_layout Standard
14961 \begin_inset VSpace medskip
14967 \begin_layout Standard
14969 Koma-Script version 2.8 has introduced a new letter class
14973 which supersedes the now unsupported
14978 It has — on the \SpecialChar LaTeX
14979 side — a completely new interface and is not compatible
14980 with the old class.
14981 Therefore, \SpecialChar LyX
14982 supports both, though it is recommended you use the new class.
14985 \begin_layout Standard
14986 This class covers the same functionality as
14988 letter (koma-script),
14991 The basic items are
14995 (receiver's address, same as
14999 in the old layout),
15012 will start a new letter (i.
15013 \begin_inset space \thinspace{}
15017 \begin_inset space \space{}
15020 you can write several letters per document).
15021 New elements are sender's
15037 and the possibility to use a
15043 Insert\SpecialChar menuseparator
15049 \begin_layout Standard
15050 The biggest improvement is, though, that the letter's layout is configurable
15051 to meet almost any needs.
15052 This can be done via the preamble or with a special style file (Letter
15053 Class Option, extension
15057 ), that will be read in as a class option.
15061 \begin_layout Plain Layout
15062 The KOMA package comes with some default
15067 There is, for instance, a
15071 file that follows german typesetting rules, or a
15075 that provides the default layout of the old
15080 The latter can be loaded with the class option
15086 Layout\SpecialChar menuseparator
15087 Document\SpecialChar menuseparator
15099 template that is included in \SpecialChar LyX
15101 A detailed description is to be found in the Koma-Script documentation
15109 \begin_layout Subsection
15113 \begin_layout Standard
15114 Visualizing the Koma-Script document classes in \SpecialChar LyX
15115 , the \SpecialChar LyX
15116 internals cause some
15120 \begin_layout Itemize
15121 The chapter number of a
15125 type appears on a line of its own above the chapter heading instead of
15126 appearing in the same line ahead of it.
15127 The cause for that is the \SpecialChar LyX
15128 internal behavior for the labeltype
15132 in the layout file.
15135 \begin_layout Itemize
15136 The headings of the types
15144 are only put in the
15145 \begin_inset Quotes eld
15149 \begin_inset Quotes erd
15153 table of contents, but not in the \SpecialChar LyX
15154 table of contents (
15156 Document\SpecialChar menuseparator
15158 \begin_inset space ~
15162 \begin_inset space ~
15170 \begin_layout Itemize
15171 The paragraphs in a
15175 document class appear in a skip separation mode, not indented.
15176 This is the standard behavior, no special \SpecialChar LaTeX
15177 commands are needed for that.
15180 Document\SpecialChar menuseparator
15183 dialog the corresponding radio button indicates
15192 value always has the effect that extra \SpecialChar LaTeX
15193 commands are inserted in the document
15194 to produce the gap, which is not what is wanted in this case.
15197 \begin_layout Section
15201 \begin_layout Standard
15207 \begin_layout Subsection
15211 \begin_layout Standard
15212 Memoir is a very powerful and constantly evolving class.
15213 It has been designed with regard to fictional and non-fictional literature.
15214 Its aim is to let the user have maximum control over the typesetting of
15216 Memoir is based on the standard book class, but it can also emulate the
15217 article class (see below).
15220 \begin_layout Standard
15221 Peter Wilson, the developer of Memoir, is known as the author of lots of
15222 useful packages in the \SpecialChar LaTeX
15224 Most of them have been merged with Memoir.
15225 Therefore, it is much easier to layout the table of contents, appendices,
15226 chapter designs and such.
15228 , though, does not support all of these goodies natively.
15229 Some of them might be added to forthcoming releases
15233 \begin_layout Plain Layout
15234 You are invited to send suggestions to
15235 \begin_inset Flex URL
15238 \begin_layout Plain Layout
15240 lyx-devel@lists.lyx.org
15250 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
15252 Of course you can still use all features with the help of some native \SpecialChar LaTeX
15254 commands (\SpecialChar TeX
15259 \begin_layout Plain Layout
15264 \begin_layout Plain Layout
15274 \begin_inset space ~
15278 \begin_inset CommandInset ref
15280 reference "sec:Inserting-TeX-Code"
15290 In this section, we can only list those features that are natively supported
15291 by \SpecialChar LyX
15293 For detailed descriptions (and for the rest of features) we recommend you
15294 have a look at the detailed manual of the Memoir class
15298 \begin_layout Plain Layout
15303 \begin_layout Plain Layout
15313 \begin_inset Flex URL
15316 \begin_layout Plain Layout
15318 CTAN:/macros/latex/memoir/memman.pdf
15328 , which is not only a user guide for the class, but also both a comprehensive
15329 description on good typesetting and a superb example for good typesetting
15333 \begin_layout Subsection
15334 Basic features and restrictions
15337 \begin_layout Standard
15338 Memoir supports basically all features of the standard book classes.
15339 There are, however, some differences, as follows:
15342 \begin_layout Description
15344 \begin_inset space ~
15347 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
15350 \begin_layout Description
15352 \begin_inset space ~
15355 style: The fancy page style is not supported, due to a command clash between
15356 Memoir and the fancyhdr package (they both define a command with the same
15357 name, which confuses \SpecialChar LaTeX
15359 Instead, Memoir comes with a number of its own page styles (see
15361 Layout\SpecialChar menuseparator
15362 Document\SpecialChar menuseparator
15364 \begin_inset space ~
15370 If you want to use these for the chapter pages, you have to use the command
15377 in the main text or in preamble (e.
15378 \begin_inset space \thinspace{}
15382 \begin_inset space \space{}
15389 chapterstyle{companion}
15394 \begin_layout Description
15395 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
15396 optional argument in the standard classes.
15397 With this, you can specify an alternative version of the title for the
15398 table of contents and the headers (for instance, if the title is too long).
15399 In \SpecialChar LyX
15400 , you can do this via
15402 Insert\SpecialChar menuseparator
15404 \begin_inset space ~
15409 at the beginning of a chapter/section.
15410 Memoir features a second optional argument and thus separates the table
15411 of contents from the header.
15412 You can define three variants of a title with this: one for the main text,
15413 one for the table of contents, and one for the headers.
15414 Simply insert two optional arguments if you need this feature, the first
15415 one containing the short title for the Table of Contents, the second one
15416 containing an alternative short title for the headers.
15419 \begin_layout Description
15420 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15421 of contents, the list of figures and the list of table start a new page
15423 Memoir does not follow this route.
15424 You have to insert a page break yourself, if you want to have one.
15427 \begin_layout Description
15428 Titlepage: For some unknown reason, Memoir uses pagination on the title
15429 page (in the standard classes, title pages are
15430 \begin_inset Quotes eld
15434 \begin_inset Quotes erd
15438 If you want an empty title page, type
15442 aliaspagestyle{title}{empty}
15447 \begin_layout Description
15448 Article: With the class option
15454 Layout\SpecialChar menuseparator
15455 Document\SpecialChar menuseparator
15457 \begin_inset space ~
15462 ), you can emulate article style.
15463 That is, counters (footnotes, figures, tables etc.) will not be reset on
15464 new chapters, chapters don't start a new page (but are—in contrary to
15465 \begin_inset Quotes eld
15469 \begin_inset Quotes erd
15472 article classes—still allowed), parts, though, use their own page, as in
15476 \begin_layout Description
15477 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15478 font commands, which have been used in the old \SpecialChar LaTeX
15480 \begin_inset space \thinspace{}
15484 \begin_inset space \space{}
15500 It produces an error and stops \SpecialChar LaTeX
15501 whenever such a command appears.
15506 reallows the commands and spits out warnings instead (which does at least
15507 not stop \SpecialChar LaTeX
15509 Since a lot of packages and particularly Bib\SpecialChar TeX
15510 style files are still using
15511 those commands, we have decided to use this option by default.
15514 \begin_layout Subsection
15518 \begin_layout Standard
15519 We will only describe the features supported by \SpecialChar LyX
15520 (which is not much currently).
15521 Please consult the Memoir manual
15525 \begin_layout Plain Layout
15530 \begin_layout Plain Layout
15540 \begin_inset Flex URL
15543 \begin_layout Plain Layout
15545 CTAN:/macros/latex/memoir/memman.pdf
15558 \begin_layout Description
15559 Abstract: You may wonder why an abstract is an extra feature.
15560 Well, it is in book class.
15561 Usually books don't have abstracts.
15562 Memoir, however, has.
15563 You can use it wherever and how often you like.
15566 \begin_layout Description
15567 Chapterprecis: You may know this older typesetting style: The contents of
15568 a chapter are summarized below the title and also in the table of contents
15570 \begin_inset space \thinspace{}
15574 \begin_inset space \space{}
15579 Our hero arrives in Troia; he loses some friends; he finds others
15582 Chapterprecis does exactly this.
15583 It is therefore only sensible below a chapter.
15586 \begin_layout Description
15587 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
15588 The epigraph environment provides an elegant way of typesetting such a
15590 The motto itself (text) and its author (source) are divided by a short
15592 Unfortunately, we have to fool \SpecialChar LyX
15593 a bit here again, since the environment
15594 needs two arguments (text and source).
15595 In this case, we have to use curly brackets (in \SpecialChar TeX
15596 mode) between the two
15607 <author of the slogan>.
15610 \begin_layout Description
15611 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
15612 complex figurative poems).
15614 can only support a few of them.
15615 One is poemtitle, which is a centered title for poems, which will also
15616 be added to the table of contents (verse is the standard environment for
15618 Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
15620 because they have to be nested inside regular verse environments, which
15621 is not possible with \SpecialChar LyX
15625 \begin_layout Description
15626 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
15629 \begin_layout Section
15630 Article (mwart), book (mwbk) and report (mwrep)
15631 \begin_inset Argument status
15634 \begin_layout Plain Layout
15647 \begin_layout Standard
15653 \begin_layout Standard
15654 The \SpecialChar LyX
15671 correspond to the \SpecialChar LaTeX
15685 They are replacements for the standard document classes
15697 , resp., and fit better to Polish typography conventions in a number of points.
15701 \begin_layout Standard
15705 \begin_layout Itemize
15706 Unnumbered titles (with star, e.
15707 \begin_inset space \thinspace{}
15711 \begin_inset space \space{}
15718 ) are added into table of contents,
15721 \begin_layout Itemize
15722 Additional page styles:
15723 \begin_inset Separator parbreak
15730 \begin_layout Description
15731 uheadings header with separated lines,
15734 \begin_layout Description
15735 myheadings custom header, contents headers via commands:
15750 \begin_layout Description
15751 myuheadings custom header with separated lines,
15754 \begin_layout Description
15755 outer page number is placed on outer side of page
15759 \begin_layout Itemize
15761 \begin_inset Separator parbreak
15768 \begin_layout Description
15769 rmheadings serif titles — default,
15772 \begin_layout Description
15773 sfheadings sansserif titles,
15776 \begin_layout Description
15777 authortitle on title page first placed is author next title — default,
15780 \begin_layout Description
15781 titleauthor on title page first placed is title next author,
15784 \begin_layout Description
15785 withmarginpar reserve place on page for margins.
15789 \begin_layout Section
15793 \begin_layout Standard
15798 provides an alternative to the standard
15803 It provides similar functionality, but you might prefer this layout with
15804 sans serif sections, headings, and more.
15807 \begin_layout Section
15808 Rev\SpecialChar TeX
15812 \begin_layout Standard
15818 \begin_layout Standard
15819 \begin_inset VSpace bigskip
15825 \begin_layout Standard
15830 \begin_inset space ~
15835 textclass works with the American Physical Sociey's Rev\SpecialChar TeX
15837 \begin_inset Formula $\beta$
15840 release of May, 1999) class.
15843 \begin_layout Standard
15849 textclass, which works with Rev\SpecialChar TeX
15851 However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
15853 That means that it doesn't interact very well with \SpecialChar LyX
15854 , which requires \SpecialChar LaTeX2e
15856 it has been kludged to work.
15857 Since Rev\SpecialChar TeX
15858 4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
15863 Rev\SpecialChar TeX
15865 \begin_inset space ~
15870 textclass should also be pretty easy to use.
15873 \begin_layout Standard
15874 These documents are supposed to be used in
15878 to the Rev\SpecialChar TeX
15879 4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
15881 and assume you'll know what to put in the preamble if necessary.
15884 \begin_layout Subsection
15888 \begin_layout Standard
15889 All you need to do is install Rev\SpecialChar TeX
15890 4, as described in the package's README
15892 The package can be found at The Rev\SpecialChar TeX
15894 \begin_inset Flex URL
15897 \begin_layout Plain Layout
15899 http://publish.aps.org/revtex4/
15905 Install it somewhere that \SpecialChar LaTeX
15907 Test it by trying to \SpecialChar LaTeX
15908 a short Rev\SpecialChar TeX
15909 4 document in some random directory (i.
15910 \begin_inset space \thinspace{}
15914 \begin_inset space \space{}
15917 not the directory where you installed the class file.) Then, if you reconfigure
15919 , it will find the class file and let you use the Rev\SpecialChar TeX
15923 \begin_layout Standard
15924 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
15933 \begin_inset space ~
15938 template, found in the templates directory.
15941 \begin_layout Subsection
15945 \begin_layout Standard
15946 Optional arguments to
15953 \begin_inset Quotes eld
15957 \begin_inset Quotes erd
15961 \begin_inset Quotes eld
15965 \begin_inset Quotes erd
15971 \begin_inset space ~
15979 \begin_inset space ~
15985 Remember that in Rev\SpecialChar TeX
15986 , at least one optional argument is required!
15989 \begin_layout Standard
15990 Other preamble matter, like
15997 \begin_inset space ~
16004 \begin_inset space ~
16009 dialog, also as usual.
16012 \begin_layout Subsection
16016 \begin_layout Standard
16017 The layouts basically correspond to the commands in Rev\SpecialChar TeX
16019 For example, the Email layout corresponds to
16026 Note that (at least as of Rev\SpecialChar TeX
16035 layouts are exactly equivalent, so you shouldn't need to use both.
16039 \begin_layout Plain Layout
16040 In case you're curious, both were included so that
16044 would be able to translate both
16064 \begin_layout Subsection
16068 \begin_layout Standard
16069 There are a couple of important unique aspects of Rev\SpecialChar TeX
16070 4 which might cause
16071 bugs that will be even more confusing in \SpecialChar LyX
16075 \begin_layout Standard
16076 In Rev\SpecialChar TeX
16094 The \SpecialChar LyX
16095 equivalent is that there is a separate Thanks layout.
16100 write footnotes in the
16104 layout, or weird things may happen.
16105 See the Rev\SpecialChar TeX
16106 4 documentation for more details.
16109 \begin_layout Standard
16113 \begin_inset space ~
16121 \begin_inset space ~
16130 layouts must be placed
16138 layout and the corresponding
16155 , the \SpecialChar LaTeX
16159 \begin_layout Subsection
16163 \begin_layout Standard
16164 The main problem with this layout is that you can't use the optional arguments
16165 to layouts like Email and Title.
16166 (The problem is not unique to this layout; you can't use optional arguments
16167 to the Section layouts either.) This means that after you export that file
16168 to \SpecialChar LaTeX
16169 (which you'll need to do eventually to send it in to APS), you'll need
16170 to edit the \SpecialChar LaTeX
16171 file with a text editor to add the optional arguments to set,
16173 \begin_inset space \thinspace{}
16177 \begin_inset space \space{}
16180 the running title for the page headers.
16181 Lacking these layouts makes the
16187 (and the equivalent
16193 ) useless, so the corresponding layouts don't exist, and will have to be
16198 \begin_layout Plain Layout
16203 actually, \SpecialChar LyX
16204 1.3.0 supports some forms of optional arguments, but this layout
16205 has not been updated yet to take advantage of it.
16213 \begin_layout Section
16214 Springer Journals (
16221 \begin_layout Standard
16227 \begin_layout Subsection
16231 \begin_layout Standard
16232 These are the layout files for some of the journal formats used by Springer
16233 Verlag and listed on
16234 \begin_inset Flex URL
16237 \begin_layout Plain Layout
16239 http://www.springer.de/author/tex/help-journals.html
16244 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
16246 It is a modular system: the things common to all journals are implemented
16251 , which journal-specific layout files (such as, e.
16252 \begin_inset space \thinspace{}
16256 \begin_inset space \space{}
16263 for Journal of Geodesy) can include.
16266 \begin_layout Standard
16267 This means that implementing support for any other Springer journal on this
16268 list is as simple as writing your own
16276 file following the outline given in
16284 \begin_layout Standard
16285 It is reasonably well tested only for the Journal of Geodesy.
16294 come with the standard \SpecialChar LyX
16296 Install the relevant class file (downloaded from Springer) in a proper
16297 directory, reconfigure \SpecialChar LaTeX
16298 (in the te\SpecialChar TeX
16303 , as root if necessary — doesn't \SpecialChar LyX
16304 take care of this?), reconfigure \SpecialChar LyX
16309 \begin_layout Subsection
16313 \begin_layout Standard
16314 A large number of theorem-like styles —
16326 \begin_layout Standard
16329 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
16330 _Title, Author_Running, Institute,
16331 Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
16334 See the Springer class file documentation for details.
16337 \begin_layout Subsection
16341 \begin_layout Itemize
16353 \begin_layout Itemize
16356 Probability Theory and Related Fields
16362 — Jean-Marc Lasgouttes
16365 \begin_layout Standard
16366 Add your own, it isn't so hard!
16369 \begin_layout Subsection
16373 \begin_layout Standard
16374 These files are partly based on the older
16378 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
16380 file from Springer.
16385 layout, are now defunct.
16386 Jean-Marc Lasgouttes helped out big in making me find my way around the
16388 layout file mechanism.
16391 \begin_layout Subsection
16395 \begin_layout Standard
16397 But probably less than in the old hacked-\SpecialChar LaTeX
16405 \begin_layout Standard
16407 \begin_inset space \thinspace{}
16410 g.: does not display the number for theorem-like layouts, just #.
16413 \begin_layout Section
16416 Sli\SpecialChar TeX
16420 \begin_inset CommandInset label
16429 \begin_layout Standard
16437 \begin_layout Subsection
16441 \begin_layout Standard
16442 This section describes how to use \SpecialChar LyX
16443 to make slides for overhead projectors.
16444 There are two document classes that can do this: the default slides class
16447 Foil\SpecialChar TeX
16451 This section documents the former.
16454 \begin_layout Standard
16455 I'm going to say this again, nice and clear, so that there's no misunderstanding
16459 \begin_layout Standard
16460 \begin_inset VSpace bigskip
16466 \begin_layout Standard
16470 This section documents the class
16471 \begin_inset Quotes eld
16479 \begin_inset Quotes erd
16487 \begin_layout Standard
16488 \begin_inset VSpace bigskip
16494 \begin_layout Standard
16495 If you're looking for the documentation for
16496 \begin_inset Quotes eld
16501 slides (Foil\SpecialChar TeX
16505 \begin_inset Quotes erd
16508 , check out section
16509 \begin_inset space ~
16513 \begin_inset CommandInset ref
16515 reference "sec:foiltex"
16525 \begin_inset Quotes eld
16530 slides (Foil\SpecialChar TeX
16534 \begin_inset Quotes erd
16537 ] is actually somewhat better than the default
16545 \begin_layout Plain Layout
16547 or so I've been told repeatedly by its advocates.
16548 Having never used it, I have no idea if this claim is true or not.
16553 which this section documents.
16556 \begin_layout Standard
16557 This class is the \SpecialChar LaTeX2e
16558 improvement of the old
16560 Sli\SpecialChar TeX
16564 Every \SpecialChar LaTeX2e
16565 distribution includes this class [which I'll just refer to as
16566 \begin_inset Quotes eld
16574 \begin_inset Quotes erd
16577 from now on], so you're bound to have it.
16578 As I noted earlier, there are other classes, such as
16582 , which also produce slides for overhead projectors and do a better job
16584 However, there are some things which
16588 can do which the others can't, such as generate overlays.
16589 Read on to learn more!
16592 \begin_layout Subsection
16594 \begin_inset CommandInset label
16596 name "sec:slidesetup"
16603 \begin_layout Standard
16604 Obviously, to use this document class, you need to select
16605 \begin_inset Quotes eld
16613 \begin_inset Quotes erd
16616 from the class list in the
16618 Document\SpecialChar menuseparator
16622 There are some other special things you should know about this class:
16625 \begin_layout Itemize
16626 Don't bother changing the options
16631 They're not supported by the
16638 \begin_layout Itemize
16642 \begin_inset space ~
16647 behaves a bit differently for this class.
16648 The possible choices and what they do are as follows:
16649 \begin_inset Separator parbreak
16656 \begin_layout Description
16661 The final output contains page numbers in the lower right corner.
16664 \begin_layout Description
16673 , but also prints out any time markers you've put in.
16674 This is the default.
16677 \begin_layout Description
16682 The final output contains no page numbers, time markers, or alignment markers.
16686 \begin_layout Itemize
16691 class has an extra option:
16697 \begin_inset Quotes eld
16705 \begin_inset Quotes erd
16708 in the extra class options.
16709 \begin_inset Separator parbreak
16716 \begin_layout Standard
16717 Using this options allows you to add time markers to
16723 \begin_inset space ~
16727 \begin_inset CommandInset ref
16729 reference "sec:slideNote"
16737 \begin_layout Standard
16738 You can also use the template file
16739 \begin_inset Quotes eld
16747 \begin_inset Quotes erd
16750 to automatically set up a document to use the
16756 File\SpecialChar menuseparator
16758 \begin_inset space ~
16762 \begin_inset space ~
16767 to open your new document].
16768 The template file also contains some examples of the special paragraph
16769 environments used by this class.
16770 I'll describe those next.
16773 \begin_layout Subsection
16774 Paragraph Environments
16777 \begin_layout Subsubsection
16778 Supported Environments
16781 \begin_layout Standard
16782 The first thing you'll notice when you start up a new
16786 document is the font size and type: it's the equivalent of the size
16787 \begin_inset Quotes eld
16795 \begin_inset Quotes erd
16801 \begin_inset space ~
16807 This is also what's used in the output.
16809 \begin_inset Quotes eld
16813 \begin_inset Quotes erd
16816 to remind you that this is a slide.
16817 Your final slides will use a larger font; ergo, you'll have less space.
16818 Of course, the larger default screen font isn't WYSIWYG, only a reminder.
16821 \begin_layout Standard
16822 The next thing that becomes obvious is the changes to the paragraph environment
16823 pull-down box [at the far-left end of the toolbar].
16824 Most of the paragraph environments you're used to seeing are missing.
16825 There are also five new ones.
16830 class itself only supports certain paragraph environments:
16833 \begin_layout Itemize
16839 \begin_layout Itemize
16845 \begin_layout Itemize
16851 \begin_layout Itemize
16857 \begin_layout Itemize
16863 \begin_layout Itemize
16869 \begin_layout Itemize
16875 \begin_layout Itemize
16881 \begin_layout Itemize
16887 \begin_layout Itemize
16894 \begin_layout Itemize
16900 \begin_layout Standard
16901 All of the other standard environments, including the section-heading environmen
16902 ts, aren't used in the
16909 \begin_layout Standard
16910 On the other hand, you'll notice the following new environments:
16913 \begin_layout Itemize
16919 \begin_layout Itemize
16925 \begin_layout Itemize
16931 \begin_layout Itemize
16937 \begin_layout Itemize
16943 \begin_layout Standard
16944 These five are kind of quirky, due to a
16945 \begin_inset Quotes eld
16949 \begin_inset Quotes erd
16952 in \SpecialChar LyX
16954 You see, \SpecialChar LyX
16955 doesn't permit you to nest any other paragraph environment into
16956 an empty environment.
16957 Now, that's fine and dandy, but it means that you wouldn't be able to start
16958 a slide with anything except plain text.
16959 To deal with this, I've performed a little
16960 \begin_inset Quotes eld
16965 \begin_inset Quotes erd
16971 \begin_layout Subsubsection
16972 Quirks of the New Environments
16973 \begin_inset CommandInset label
16975 name "sec:slideQuirk"
16982 \begin_layout Standard
16983 All five of the new paragraph environments are somewhat quirky due to inherent
16984 limitiations in the current version of \SpecialChar LyX
16986 As I just mentioned, \SpecialChar LyX
16987 forbids environments that begin with another environment.
16988 To get around this, the
16992 environment isn't a paragraph environment as described in the
17000 \begin_layout Standard
17001 You should consider
17014 \begin_inset Quotes eld
17017 pseudo-environments.
17018 \begin_inset Quotes erd
17021 They look like a section heading or a
17022 \begin_inset Quotes eld
17030 \begin_inset Quotes erd
17033 but really begin a [and, if necessary, end the previous] paragraph environment.
17043 \begin_inset Quotes eld
17047 \begin_inset Quotes erd
17050 These two perform some action.
17053 \begin_layout Standard
17054 A common feature of all five environments,
17074 , is a rather long-ish label.
17075 The text following this label — ordinarily the contents of the paragraph
17076 environment — is utterly irrelevant for
17098 completely ignores it.
17099 In fact, you can leave these five environments completely empty.
17103 \begin_layout Standard
17108 to put any text after the rather long-ish label, you might want to.
17109 This could be a short description of the contents of the
17114 In that case, enter your descriptive comment and hit
17118 as you normally would.
17121 \begin_layout Standard
17122 If, on the other hand, you don't want to enter any descriptive text, you'll
17123 hit another \SpecialChar LyX
17126 , like nature, abhors a vacuum, and will not let you start a new paragraph
17127 environment until you put something in the old one.
17131 \begin_layout Itemize
17132 Start entering the text that will
17160 \begin_layout Itemize
17161 Now move to the beginning of that paragraph.
17165 \begin_layout Itemize
17174 \begin_layout Itemize
17175 Finally, change this new, empty paragraph to a
17199 \begin_layout Standard
17200 Some future version of \SpecialChar LyX
17201 will, hopefully, resolve this quirkiness\SpecialChar ldots
17205 \begin_layout Subsection
17206 Making a Presentation with
17219 \begin_layout Subsubsection
17227 \begin_layout Standard
17228 If you're expecting this section to teach you how to actually make a presentatio
17229 n, you'll be sorely disappointed.
17230 Naturally, I'll describe all of the ways the
17234 class can assist you in preparing the materials for a presentation.
17235 Filling in the contents, however, is up to you.
17240 the \SpecialChar LyX
17244 \begin_layout Standard
17249 environment [in the manner described in section
17250 \begin_inset space ~
17254 \begin_inset CommandInset ref
17256 reference "sec:slideQuirk"
17260 ] tells \SpecialChar LyX
17261 to begin a new slide [duh].
17262 The label for this environment/
17263 \begin_inset Quotes erd
17267 \begin_inset Quotes erd
17271 \begin_inset Quotes eld
17275 \begin_inset Quotes erd
17278 in cool blue, followed by the label,
17279 \begin_inset Quotes eld
17283 \begin_inset Quotes erd
17287 Any text or paragraph environments that follow this one go on the new slide.
17291 \begin_layout Standard
17292 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
17294 (this can be specified in the
17299 In fact, you'll want to, once you finish entering the contents of one slide.
17300 If you've entered more text than can physically fit on a slide, the extra
17301 overflows onto a new slide.
17302 I don't recommend doing this, however, since the overflow slide won't have
17303 any page number on it.
17304 Furthermore, it may interfere with any
17308 you've made to accompany the oversized
17315 \begin_layout Standard
17324 environments work the same way as the
17329 They both create an
17330 \begin_inset Quotes eld
17334 \begin_inset Quotes erd
17337 followed by a label [
17338 \begin_inset Quotes eld
17342 \begin_inset Quotes erd
17346 \begin_inset Quotes eld
17350 \begin_inset Quotes erd
17354 The color is a stunning magenta instead of blue, and the
17355 \begin_inset Quotes eld
17359 \begin_inset Quotes erd
17362 will look different, in style and in length.
17363 The label fonts of all three also differ from one another.
17366 \begin_layout Standard
17371 , if the contents of a
17379 exceed the physical size of a slide or sheet of paper, the extra will overflow
17381 Again, you should avoid this.
17382 It defeats the whole purpose of
17393 \begin_layout Subsubsection
17403 \begin_layout Standard
17408 is a slide that sits atop another slide.
17409 Perhaps you wish to discuss a figure on the main
17413 before displaying the text associated with it.
17414 One way to accomplish this is tape a flap of dark paper over the part of
17419 you want to display later.
17420 This method fails, however, if you wish to overlap one graph with another,
17422 You would then have to fumble while speaking to align the two separate,
17427 s to align the two graphs.
17432 environment in both cases makes life much easier.
17435 \begin_layout Standard
17440 receives the page number of its
17441 \begin_inset Quotes eld
17445 \begin_inset Quotes erd
17453 \begin_inset Quotes eld
17461 \begin_inset Quotes erd
17468 \begin_layout Plain Layout
17469 Presumably, mutliple
17474 \begin_inset Quotes eld
17482 \begin_inset Quotes erd
17486 \begin_inset Quotes eld
17494 \begin_inset Quotes erd
17498 \begin_inset Quotes eld
17506 \begin_inset Quotes erd
17510 \begin_inset space ~
17513 appended to the page number of the parent
17523 Clearly, you want the contents of both the
17531 to each fit on a single physical slide! You should probably consider an
17537 \begin_inset Quotes eld
17541 \begin_inset Quotes erd
17549 Indeed, the \SpecialChar LyX
17554 class provides a visual cue for this: the label at the start of an
17558 is shorter than that at the start of a
17563 Lastly, when you generate printable output, you'll find alignment markers
17564 in all four corners of both the
17568 page and its parent
17573 These will assist you in lining up the two physical slides.
17576 \begin_layout Standard
17577 The major problem in overlaying two slides is aligning the contents of the
17578 two transparencies.
17579 How much space should you leave for that graph on the second slide? Worse
17580 still, what if you want a graph and a sentence on second slide, but there
17581 is text on the main transparency that goes in between them? You could try
17582 and insert vertical space of the right size.
17583 The better way is to use
17594 \begin_layout Standard
17595 As their names imply,
17603 are two command-like paragraph environments that make all subsequent text
17604 invisible and visible, respectively.
17606 \begin_inset space ~
17610 \begin_inset CommandInset ref
17612 reference "sec:slideQuirk"
17616 that you don't place anything
17620 these two environments, however.
17625 , it inserts a centered, sky-blue label into the page reading
17626 \begin_inset Quotes eld
17629 <Invisible Text Follows>
17630 \begin_inset Quotes erd
17634 For paragraphs following this label, the parts of the
17642 ; it doesn't matter which] where they would be contain instead blank space.
17646 \begin_layout Standard
17651 , the corresponding centered label is
17652 \begin_inset Quotes eld
17655 <Visible Text Follows>
17656 \begin_inset Quotes erd
17660 Paragraphs following this label behave normally.
17661 Note that the beginning of a new
17673 automatically shuts off an
17678 It's therefore not necessary to use
17689 \begin_layout Standard
17690 By now, it should be obvious how to create overlay transparencies using
17691 the proper combination of
17710 \begin_layout Enumerate
17715 , including everything that will appear on it, whether on the main slide
17723 \begin_layout Enumerate
17724 Before each figure or paragraph that will appear only on the
17733 If necessary, insert a
17737 environment after the
17744 \begin_layout Enumerate
17749 immediately following the
17756 \begin_layout Enumerate
17757 Copy the contents of this
17768 \begin_layout Enumerate
17773 , change all of the
17784 \begin_layout Standard
17786 You've just made an
17793 \begin_layout Standard
17794 There's one problem with the way I've designed the \SpecialChar LyX
17799 class: you can't make text in the middle of a paragraph invisible, nor
17800 make text in the middle of an invisible paragraph visible again.
17801 To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
17806 \begin_layout Plain Layout
17807 The commands of interest are:
17810 \begin_layout Itemize
17815 invisible \SpecialChar ldots
17819 \begin_layout Itemize
17824 visible \SpecialChar ldots
17828 \begin_layout Plain Layout
17830 and need to be marked as \SpecialChar TeX
17833 \begin_inset Quotes eld
17837 \begin_inset Quotes erd
17840 you wish to change goes in between the brackets [and after the
17853 If you don't know how to mark text as \SpecialChar TeX
17854 , see the appropriate section of
17867 \begin_layout Subsubsection
17877 \begin_inset CommandInset label
17879 name "sec:slideNote"
17886 \begin_layout Standard
17895 is associated with a
17896 \begin_inset Quotes eld
17900 \begin_inset Quotes erd
17908 Here, too, the \SpecialChar LyX
17913 class provides visual cues.
17918 is shorter than that of a
17922 [yet longer than that of an
17926 ] and, like the label of an
17930 is shockingly magenta.
17931 Additionally, the printed
17935 has the page number of its
17936 \begin_inset Quotes eld
17940 \begin_inset Quotes erd
17948 \begin_inset Quotes eld
17956 \begin_inset Quotes erd
17960 \begin_inset Quotes eld
17968 \begin_inset Quotes erd
17972 \begin_inset Quotes eld
17980 \begin_inset Quotes erd
17984 You can have multiple
17988 s associated with a single
18000 , you'll probably want to break up long
18004 s so that they fit on a single sheet of paper.
18007 \begin_layout Standard
18012 is obvious: it contains anything additional you might want to say about
18018 It could also be used as a sheet of reminders for a particular
18023 In the case of the latter, you might want to make use of time markers.
18024 Currently, the \SpecialChar LyX
18030 \begin_inset Quotes eld
18034 \begin_inset Quotes erd
18037 support for time markers, a
18039 Sli\SpecialChar TeX
18043 So, you'll have to resort to using the \SpecialChar LaTeX
18047 \begin_layout Standard
18048 To use time markers, you'll need to specify the extra class option
18049 \begin_inset Quotes eld
18057 \begin_inset Quotes erd
18061 \begin_inset space ~
18065 \begin_inset CommandInset ref
18067 reference "sec:slidesetup"
18072 This option turns on timing marks, which will appear in the lower-left-hand
18078 To set what appears in the time marker, you use the \SpecialChar LaTeX
18080 \begin_inset Quotes eld
18090 \begin_inset Quotes erd
18094 \begin_inset Quotes eld
18104 \begin_inset Quotes erd
18108 The arguments of both commands are time measured in seconds.
18110 \begin_inset Quotes eld
18120 \begin_inset Quotes erd
18123 sets the time marker to a given time.
18125 \begin_inset Quotes eld
18135 \begin_inset Quotes erd
18138 increments the time marker by the specified amount.
18139 Using time markers and
18143 s in this fashion, you can remind yourself how much time to spend on a particula
18151 \begin_layout Standard
18152 There's one last feature to describe.
18153 Clearly, you'd like to print out all of your
18161 s on transparencies while printing all of your
18178 with which it is associated.
18179 What's a person to do?
18182 \begin_layout Standard
18183 Luckily, there are two \SpecialChar LaTeX
18184 commands that allow you to select what to print
18186 Both must be placed into the preamble of your document.
18188 \begin_inset Quotes eld
18200 \begin_inset Quotes erd
18203 will cause the output to contain only the
18212 Correspondingly, the command
18213 \begin_inset Quotes eld
18225 \begin_inset Quotes erd
18228 prevents the output of anything but
18233 I'd advise placing both commands in the preamble and initially comment
18235 You can then preview your entire presentation as you write.
18236 When you're done writing, you can then uncomment one of the two to select
18237 what you want to print.
18238 I like to uncomment
18239 \begin_inset Quotes eld
18251 \begin_inset Quotes erd
18254 , print to a file with
18255 \begin_inset Quotes eld
18263 \begin_inset Quotes erd
18266 in its name, comment it back out, then uncomment
18267 \begin_inset Quotes eld
18279 \begin_inset Quotes erd
18283 \begin_inset Quotes eld
18291 \begin_inset Quotes erd
18295 I can then send either file to a printer, loading transparencies or plain
18296 paper as appropriate.
18299 \begin_layout Standard
18300 You can also provide other arguments to the
18301 \begin_inset Quotes eld
18311 \begin_inset Quotes erd
18315 \begin_inset Quotes eld
18325 \begin_inset Quotes erd
18329 See a good \SpecialChar LaTeX
18333 \begin_layout Subsection
18338 Class Template File
18341 \begin_layout Standard
18342 I have also provided a template file,
18343 \begin_inset Quotes eld
18351 \begin_inset Quotes erd
18359 To use it, begin your new presentation with
18361 File\SpecialChar menuseparator
18363 \begin_inset space ~
18367 \begin_inset space ~
18373 Your new \SpecialChar LyX
18374 presentation file will contain an example
18395 additionally contain an example of the use of
18404 Lastly, the preamble will contain:
18407 \begin_layout LyX-Code
18408 % Uncomment to print out only slides and overlays
18411 \begin_layout LyX-Code
18415 \begin_layout LyX-Code
18421 \begin_inset Newline newline
18427 \begin_layout LyX-Code
18428 % Uncomment to print out only notes
18431 \begin_layout LyX-Code
18435 \begin_layout LyX-Code
18443 \begin_layout Standard
18444 One final thing: I created this class to support the \SpecialChar LaTeX2e
18446 \begin_inset Quotes eld
18451 Sli\SpecialChar TeX
18455 \begin_inset Quotes erd
18458 class, one of the built-in \SpecialChar LaTeX2e
18460 Neither I nor the rest of the \SpecialChar LyX
18461 Team endorse or oppose the use of this built-in
18463 It's here if you want it or need it.
18464 There exist other \SpecialChar LaTeX2e
18465 classes for creating presentations, such as the
18470 \begin_inset space ~
18474 \begin_inset CommandInset ref
18476 reference "sec:foiltex"
18481 \begin_inset Quotes eld
18489 \begin_inset Quotes erd
18492 package [present on some \SpecialChar TeX
18494 The latter is not yet supported under \SpecialChar LyX
18499 \begin_layout Plain Layout
18500 Perhaps you can take on the task\SpecialChar ldots
18506 I know nothing about these other classes.
18507 Try them out to see what sort of alternative they provide.
18510 \begin_layout Chapter
18512 Features needing Extra Software
18515 \begin_layout Section
18516 Checking \SpecialChar TeX
18520 \begin_layout Standard
18526 \begin_layout Subsection
18530 \begin_layout Standard
18539 \begin_layout Plain Layout
18544 is not yet available when you are using the \SpecialChar LaTeX
18545 distribution MiK\SpecialChar TeX
18551 , you'll find in the
18558 \begin_inset space ~
18569 \begin_inset Newline newline
18573 \begin_inset CommandInset href
18575 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
18582 \begin_layout Standard
18585 Chk\SpecialChar TeX
18588 package is a program that was written by
18589 \begin_inset Flex Noun
18592 \begin_layout Plain Layout
18594 \begin_inset space ~
18602 in frustration because some constructs in \SpecialChar LaTeX
18603 are sometimes non-intuitive,
18604 and easy to forget.
18605 The program runs over your \SpecialChar LaTeX
18606 file, checks the integrity of the file, and
18607 flags some common errors.
18608 In other technical words, it is
18612 for \SpecialChar LaTeX
18616 \begin_layout Standard
18617 Well, what is a syntax checker doing in \SpecialChar LyX
18618 which is supposed to produce correct
18620 anyways? The answer is simple: Just as
18624 not only checks the
18628 of C programs, but also does
18632 checks for type-errors,
18634 Chk\SpecialChar TeX
18637 catches some common
18641 errors, in addition to the syntactical ones.
18644 Chk\SpecialChar TeX
18647 is capable of detecting several common errors, such as
18650 \begin_layout Itemize
18651 Ellipsis detection:
18652 \begin_inset Newline newline
18655 Use \SpecialChar ldots
18659 \begin_layout Itemize
18660 No space in front of/after parenthesis:
18661 \begin_inset Newline newline
18667 \begin_layout Itemize
18668 Enforcement of normal space after common abbreviations:
18669 \begin_inset Newline newline
18673 \begin_inset space \thinspace{}
18677 \begin_inset space \space{}
18680 is too wide spacing.
18683 \begin_layout Itemize
18684 Enforcement of end-of-sentence space when the last sentence ends with a
18686 \begin_inset Newline newline
18690 And this is wrong spacing.
18693 \begin_layout Itemize
18694 Space in front of labels and similar commands:
18695 \begin_inset Newline newline
18698 The label should stick right up to the text to avoid falling to a wrong
18701 \begin_inset CommandInset label
18711 \begin_layout Plain Layout
18712 This footnote is in danger of falling off to a wrong page
18717 The label is separated too much.
18720 \begin_layout Itemize
18721 Space in front of references, instead of hard spaces:
18722 \begin_inset Newline newline
18725 If you have bad luck, the text will break right between the referenced text
18726 and reference number, and that's a pity.
18728 \begin_inset CommandInset ref
18730 reference "sec:chktex"
18737 \begin_layout Itemize
18739 \begin_inset Quotes eld
18743 \begin_inset Quotes erd
18747 \begin_inset Formula $\times$
18751 \begin_inset Newline newline
18754 2x2 looks cheap compared to
18755 \begin_inset Formula $2\times2$
18761 \begin_layout Standard
18762 and more \SpecialChar ldots
18763 It is an invaluable tool when you are
18764 \begin_inset Quotes eld
18768 \begin_inset Quotes erd
18771 your document before printing, and you should run it right after the obligatory
18772 spelling check, and before you go fine tuning the typesetting.
18775 \begin_layout Subsection
18779 \begin_layout Standard
18780 If you have the program installed, usage is as simple as choosing
18782 Tools\SpecialChar menuseparator
18784 \begin_inset space ~
18790 This will make \SpecialChar LyX
18791 generate a \SpecialChar LaTeX
18792 file of your document, start
18794 Chk\SpecialChar TeX
18797 to check it, and then make \SpecialChar LyX
18799 \begin_inset Quotes eld
18803 \begin_inset Quotes erd
18806 with the warnings from
18808 Chk\SpecialChar TeX
18811 , if there were any.
18812 The warnings will be placed close to the point of the mistake, and you
18813 can quickly find them by using the
18815 Navigate\SpecialChar menuseparator
18818 menu item, or the shortcut key
18827 Open the error boxes by clicking on them with the mouse, or use the shortcut
18836 bindings, or the corresponding
18845 Read the warning and correct the mistake, if it is a mistake.
18846 If you have trouble understanding what the warning is about, you can safely
18848 Remember that there is a hidden layer between the document on screen and
18849 the technical details in invoking
18851 Chk\SpecialChar TeX
18854 , and this gap can make some warnings seem arcane or just plain silly.
18857 \begin_layout Standard
18858 This document is an excellent testing bed for the feature, and it should
18859 provide quite a few warnings for you to fiddle with.
18860 Since computers are only so smart, expect most of the warnings to be false
18864 \begin_layout Subsection
18865 How to fine tune it
18868 \begin_layout Standard
18869 Sometimes, you'll find that
18871 Chk\SpecialChar TeX
18874 makes more noise than suits your mood.
18875 Then you can choose not to use it, wait until your mood changes, or try
18878 Chk\SpecialChar TeX
18881 to get better along with you.
18884 \begin_layout Standard
18887 Chk\SpecialChar TeX
18894 very configurable and extensible, you should not expect to solve all problems
18897 Chk\SpecialChar TeX
18900 in \SpecialChar LyX
18902 Since \SpecialChar LyX
18903 has to generate a somewhat special \SpecialChar LaTeX
18904 file to be able to match the
18905 line numbers from the
18907 Chk\SpecialChar TeX
18914 \begin_layout Plain Layout
18915 You can inspect the specific output from
18921 Document\SpecialChar menuseparator
18924 \begin_inset space ~
18938 to the internal document structure, some of the warnings will not appear
18940 There are two things you can do about this:
18943 \begin_layout Itemize
18946 Chk\SpecialChar TeX
18949 invocation command line in
18950 \begin_inset Flex Noun
18953 \begin_layout Plain Layout
18954 Tools\SpecialChar menuseparator
18955 Preferences\SpecialChar menuseparator
18956 Output\SpecialChar menuseparator
18957 LaTeX\SpecialChar menuseparator
18965 Chk\SpecialChar TeX
18968 installation configuration file (usually with the file
18973 See below to learn what warnings can be enabled and disabled on the command
18977 \begin_layout Itemize
18978 Export your document as a raw \SpecialChar LaTeX
18981 File\SpecialChar menuseparator
18982 Export\SpecialChar menuseparator
18991 Invoked in this way, it can be a hassle to find the corresponding place
18992 in the document inside \SpecialChar LyX
18993 , but with a little patience, you should be able
18997 \begin_layout Standard
18998 Here follows the warning messages that can be enabled and disabled in
19007 to disable a warning, and
19011 to enable a warning.
19012 The emphasized entries are disabled by default, because the default is
19015 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19020 \begin_layout Standard
19021 Notice that you should only use the options that enable and disable warnings,
19022 because \SpecialChar LyX
19023 relies on some of the other command line parameters to be set
19024 in a specific way to have a chance to communicate with
19031 \begin_layout Enumerate
19035 Command terminated with space.
19038 \begin_layout Enumerate
19041 Non-breaking space (
19042 \begin_inset Quotes eld
19050 \begin_inset Quotes erd
19053 ) should have been used.
19056 \begin_layout Enumerate
19060 You should enclose the previous parenthesis with
19061 \begin_inset Quotes eld
19069 \begin_inset Quotes erd
19075 \begin_layout Enumerate
19078 Italic correction (
19079 \begin_inset Quotes eld
19089 \begin_inset Quotes erd
19092 ) found in non-italic buffer.
19095 \begin_layout Enumerate
19098 Italic correction (
19099 \begin_inset Quotes eld
19109 \begin_inset Quotes erd
19112 ) found more than once.
19115 \begin_layout Enumerate
19119 No italic correction (
19120 \begin_inset Quotes eld
19130 \begin_inset Quotes erd
19136 \begin_layout Enumerate
19140 \begin_inset Quotes eld
19148 \begin_inset Quotes erd
19152 \begin_inset Quotes eld
19160 \begin_inset Quotes erd
19166 \begin_layout Enumerate
19169 Wrong length of dash may have been used.
19172 \begin_layout Enumerate
19176 \begin_inset Quotes eld
19184 \begin_inset Quotes erd
19188 \begin_inset Quotes eld
19196 \begin_inset Quotes erd
19202 \begin_layout Enumerate
19206 \begin_inset Quotes eld
19214 \begin_inset Quotes erd
19220 \begin_layout Enumerate
19224 \begin_inset Quotes eld
19232 \begin_inset Quotes erd
19235 to achieve an ellipsis.
19238 \begin_layout Enumerate
19241 Inter-word spacing (
19242 \begin_inset Quotes eld
19252 \begin_inset Quotes eld
19255 ) should perhaps be used.
19258 \begin_layout Enumerate
19261 Inter-sentence spacing (
19262 \begin_inset Quotes eld
19272 \begin_inset Quotes erd
19275 ) should perhaps be used.
19278 \begin_layout Enumerate
19281 Could not find argument for command.
19284 \begin_layout Enumerate
19288 \begin_inset Quotes eld
19296 \begin_inset Quotes erd
19302 \begin_layout Enumerate
19305 Math mode still on at end of \SpecialChar LaTeX
19309 \begin_layout Enumerate
19313 \begin_inset Quotes eld
19321 \begin_inset Quotes erd
19324 doesn't match the number of
19325 \begin_inset Quotes eld
19333 \begin_inset Quotes erd
19339 \begin_layout Enumerate
19342 You should use either
19345 \begin_inset Quotes eld
19353 \begin_inset Quotes erd
19358 as an alternative to
19359 \begin_inset Quotes eld
19367 \begin_inset Quotes erd
19373 \begin_layout Enumerate
19380 " (ASCII 39) instead of "
19387 \begin_layout Enumerate
19390 User-specified pattern found.
19393 \begin_layout Enumerate
19396 This command might not be intended.
19399 \begin_layout Enumerate
19406 \begin_layout Enumerate
19424 \begin_layout Enumerate
19427 Delete this space to maintain correct page references.
19430 \begin_layout Enumerate
19434 You might wish to put this between a pair of
19435 \begin_inset Quotes eld
19443 \begin_inset Quotes erd
19449 \begin_layout Enumerate
19452 You ought to remove spaces in front of punctuation.
19455 \begin_layout Enumerate
19458 Could not execute \SpecialChar LaTeX
19462 \begin_layout Enumerate
19471 in front of small punctuation.
19474 \begin_layout Enumerate
19482 may look prettier here.
19485 \begin_layout Enumerate
19489 Multiple spaces detected in output.
19492 \begin_layout Enumerate
19495 This text may be ignored.
19498 \begin_layout Enumerate
19504 \begin_inset Quotes eld
19509 to begin quotation, not
19516 \begin_layout Enumerate
19523 to end quotation, not
19526 \begin_inset Quotes eld
19534 \begin_layout Enumerate
19540 \begin_layout Enumerate
19543 You should perhaps use
19544 \begin_inset Quotes eld
19552 \begin_inset Quotes erd
19558 \begin_layout Enumerate
19561 You should put a space in front of/after parenthesis.
19564 \begin_layout Enumerate
19567 You should avoid spaces in front of/after parenthesis.
19570 \begin_layout Enumerate
19574 You should not use punctuation in front of/after quotes.
19577 \begin_layout Enumerate
19580 Double space found.
19583 \begin_layout Enumerate
19586 You should put punctuation outside inner/inside display math mode.
19589 \begin_layout Enumerate
19592 You ought to not use primitive \SpecialChar TeX
19593 in \SpecialChar LaTeX
19597 \begin_layout Enumerate
19600 You should remove spaces in front of
19601 \begin_inset Quotes eld
19609 \begin_inset Quotes erd
19615 \begin_layout Enumerate
19618 \begin_inset Quotes eld
19626 \begin_inset Quotes erd
19629 is normally not followed by
19630 \begin_inset Quotes eld
19638 \begin_inset Quotes erd
19644 \begin_layout Standard
19645 In later versions of \SpecialChar LyX
19646 , we hope to provide a more complete interface to this
19647 tool (and it's smaller cousin
19651 ) to exploit the full power of it.
19652 But it's not exactly useless as it is now: go try it on one of your existing
19653 documents of a certain length and be surprised.
19656 \begin_layout Section
19657 Version Control in \SpecialChar LyX
19661 \begin_layout Standard
19664 Lars Gullik Bjønnes
19671 \begin_layout Subsection
19675 \begin_layout Standard
19677 supports some of the most basic RCS/CVS/SVN/GIT commands.
19678 If you need something a bit more sophisticated you will have to do that
19679 manually in a terminal.
19682 \begin_layout Standard
19683 Also note that CVS support is not as good as subversion support so we advise
19685 A good place to start learning Subversion is SVN Book
19689 \begin_layout Plain Layout
19690 \begin_inset CommandInset href
19692 target "http://svnbook.red-bean.com/"
19702 In the case of RCS you should read
19703 \begin_inset Quotes eld
19707 \begin_inset Quotes erd
19710 (a man file, read it with
19715 This file describes all the basic features of RCS.
19716 You should especially notice the comment about a RCS directory, and the
19717 notion of a master RCS file (the file ending in
19724 \begin_layout Standard
19725 Before you begin to use the version control features in \SpecialChar LyX
19727 familiar with RCS/CVS/SVN/GIT usage.
19728 The implementation in \SpecialChar LyX
19729 assumes a recent version of the GNU RCS or CVS/SVN
19730 package — no guarantees are made for older versions.
19731 Most of the log messages are not currently displayed after operations —
19732 you can check them in the Messages pane if unsure.
19733 Regular users of version control will appreciate VC toolbar, which can
19736 View\SpecialChar menuseparator
19737 Toolbars\SpecialChar menuseparator
19739 \begin_inset space ~
19747 \begin_layout Standard
19748 For introducing your own external commands consult vc-command in the manual
19749 of \SpecialChar LyX
19753 \begin_layout Standard
19754 It is strongly recommended to store documents in uncompressed format if
19755 using version control (uncheck
19757 Document\SpecialChar menuseparator
19760 if it is checked): Uncompressed LyX documents are text files and therefore
19761 for merging two different versions by version control systems.
19762 Compressed LyX documents are binary files, which cannot be merged by version
19766 \begin_layout Subsection
19767 RCS commands in \SpecialChar LyX
19771 \begin_layout Standard
19772 The following sections describe the RCS commands supported by \SpecialChar LyX
19774 You can find them in the
19776 File\SpecialChar menuseparator
19778 \begin_inset space ~
19785 was tested against RCS 5.7/5.8.
19788 \begin_layout Subsubsection
19794 \begin_layout Standard
19795 If your document is not under revision control, this is the only item shown
19797 And if it is under revision control, the
19801 item is not visible.
19805 \begin_layout Standard
19806 This command registers your document with RCS (unless you are under the
19807 directory managed by CVS)\SpecialChar endofsentence
19808 You are asked interactively to supply an initial
19809 description of the document.
19810 The document is now set in Read-Only mode and you have to
19813 \begin_inset space ~
19817 \begin_inset space ~
19821 \begin_inset space ~
19826 , before making any changes to it.
19827 A document under revision control has a
19828 \begin_inset Quotes eld
19831 [RCS:<version> <locker>]
19832 \begin_inset Quotes erd
19835 item tagged to the filename in the minibuffer.
19838 \begin_layout Standard
19839 RCS command that is run:
19841 ci -q -u -i -t-"<initial description>" <file-name>
19844 \begin_layout Standard
19849 to understand the switches.
19853 \begin_layout Subsubsection
19859 \begin_layout Standard
19860 When you are finished editing a file, you check in your changes.
19861 When you do this, you are asked for a description of the changes.
19862 This is stored in the history log.
19863 The version number is bumped, your changes are applied to the master RCS
19864 file, the document is unlocked and set to Read-Only mode.
19867 \begin_layout Standard
19870 ci -q -u -m"<description>" <file-name>
19873 \begin_layout Subsubsection
19879 \begin_layout Standard
19880 By doing this you lock the document so that only you can edit it.
19881 This will also make the document Read-Write only for you.
19882 You will usually continue editing for a while and when you are finished
19883 you check in your changes.
19884 The status line is changed to reflect that you have locked the file.
19887 \begin_layout Standard
19890 co -q -l <file-name>
19893 \begin_layout Subsubsection
19896 Revert To Repository Version
19899 \begin_layout Standard
19900 This will discard all changes made to the document since the last check
19902 You get a warning before changes are discarded.
19905 \begin_layout Standard
19908 co -f -u<version> <file-name>
19911 \begin_layout Subsubsection
19917 \begin_layout Standard
19918 This will create a copy of the current document.
19919 Since RCS does not support copy operations natively, the version history
19920 is not preserved, and the copy is added as a new file.
19921 It requires a clean document without any changes since the last checkin.
19922 You are asked for a file name and a description of the copy operation.
19923 After that the copy is created, both locally and in the repository.
19924 If the parent directories of the copied and original document differ, all
19925 relative paths of included files of the copy are adjusted (like in
19927 File\SpecialChar menuseparator
19932 Finally, the copy is loaded instead of the original document.
19935 \begin_layout Labeling
19936 \labelwidthstring 00.00.0000
19938 \begin_inset space ~
19942 \begin_inset space ~
19946 \begin_inset Newline newline
19950 \begin_inset Flex Code
19953 \begin_layout Plain Layout
19956 \begin_inset Quotes eld
19960 \begin_inset Quotes erd
19969 \begin_inset Flex Code
19972 \begin_layout Plain Layout
19975 \begin_inset Quotes eld
19979 \begin_inset Quotes erd
19988 \begin_inset Newline newline
19992 \begin_inset Flex Code
19995 \begin_layout Plain Layout
19999 \begin_inset Quotes eld
20003 \begin_inset Quotes erd
20014 \begin_layout Subsubsection
20020 \begin_layout Standard
20021 This makes as if the last check in never happened.
20022 No changes are made to the document loaded into \SpecialChar LyX
20023 , but the last version
20024 is removed from the master RCS file.
20027 \begin_layout Standard
20030 rcs -o<version> <file-name>
20033 \begin_layout Subsubsection
20039 \begin_layout Standard
20040 This shows the complete history of the RCS document.
20045 is shown in a browser.
20053 \begin_layout Subsubsection
20057 \begin_layout Standard
20059 supports RCS version number, author name, date and time of last commit.
20060 All those are extracted from
20062 rlog -r <file-name>
20066 \begin_inset CommandInset ref
20068 reference "subsec:VCS-Revision-Information"
20075 \begin_layout Subsection
20076 CVS commands in \SpecialChar LyX
20080 \begin_layout Standard
20081 A subset of CVS operations is supported by \SpecialChar LyX
20083 You can find the commands in the
20085 File\SpecialChar menuseparator
20087 \begin_inset space ~
20093 The version control system SVN is more powerful, so please use it instead
20094 of CVS if possible.
20097 \begin_layout Subsubsection
20103 \begin_layout Standard
20104 If you start from scratch with CVS you have to create your repository and
20105 checkout the working copy with external tools.
20106 If you're using a client-server setup you may need to login before doing
20107 the first repository checkout.
20110 \begin_layout Standard
20111 If your documents are under revision control and others are using the same
20112 repository problems arise when different changes to the same document at
20113 the same location happen.
20114 Standard CVS repositories don't operate with a file locking mechanism.
20115 This may be surprising, but conflicts only occur if people disagree on
20116 the proper content of the same part of a document.
20117 So, if co-workers are used to communicate regularly, these conflicts occur
20119 If they don't communicate they have a fundamental problem anyway.
20120 Nevertheless some people like to work with so called
20121 \begin_inset Quotes eld
20125 \begin_inset Quotes erd
20129 If they do so the working copy of all files is readonly when checked out
20130 first and the user starts editing after using a special command to make
20131 the working copy writable.
20132 When the changes are checked in the working copy returns to readonly state.
20133 With \SpecialChar LyX
20134 one has to edit the
20135 \begin_inset Flex Code
20138 \begin_layout Plain Layout
20144 file and add the line
20145 \begin_inset Flex Code
20148 \begin_layout Plain Layout
20154 to work with reserved checkouts.
20155 The benefit is the possibility to see who is using a writable copy of some
20157 It's not guaranteed only one user makes a copy writable.
20160 \begin_layout Standard
20162 tries to guess if you're using reserved or non-reserved checkouts.
20163 If your working copy is readonly or it is writable and an additional copy
20164 of your document exists in the CVS/Base sub-directory a reserved otherwise
20165 a non-reserved checkout is assumed.
20166 When a reserved checkout is detected you have to use
20167 \begin_inset Flex Noun
20170 \begin_layout Plain Layout
20176 to make your working copy writable if it's readonly.
20178 \begin_inset Flex Noun
20181 \begin_layout Plain Layout
20187 operation is possible and that makes your working copy readonly again after
20188 transferring your changes to the repository.
20191 \begin_layout Standard
20192 More information about CVS can be found here
20193 \begin_inset Flex URL
20196 \begin_layout Plain Layout
20198 http://www.nongnu.org/cvs
20204 \begin_inset Flex URL
20207 \begin_layout Plain Layout
20209 http://ximbiot.com/cvs
20217 \begin_layout Standard
20222 to understand the sub-commands and the switches mentioned below.
20225 \begin_layout Subsubsection
20231 \begin_layout Standard
20232 If your document is not under revision control, this is the only item shown
20234 And if it is under revision control, the
20238 item is not visible.
20242 \begin_layout Standard
20243 This command registers in CVS your document
20244 \begin_inset Flex Strong
20247 \begin_layout Plain Layout
20255 in the case you have already the documents directory under CVS control
20261 This means you have to create or checkout the archive by yourself using
20263 (In case you forget that step \SpecialChar LyX
20264 registers the document with RCS.)
20267 \begin_layout Standard
20268 Then you are asked interactively to supply an initial description of the
20270 Don't forget that registered file is not yet checked in.
20273 \begin_layout Standard
20274 CVS command that is run:
20276 cvs -q add -m"<entered message>" "<file-name>"
20279 \begin_layout Standard
20284 above and for all other CVS commands is an abbreviation for
20285 \begin_inset Quotes eld
20288 change the current working directory to file location and use the file name
20289 without path component as argument
20290 \begin_inset Quotes erd
20296 \begin_layout Subsubsection
20302 \begin_layout Standard
20303 When you are finished editing a file, you commit your changes.
20304 When you do this and you had changed the document, you are asked for a
20305 description of the changes.
20306 After that changes are written to the repository.
20307 In case you didn't change the document and a reserved checkout is detected
20308 the reservation made on
20309 \begin_inset Flex Noun
20312 \begin_layout Plain Layout
20321 \begin_layout Labeling
20322 \labelwidthstring 00.00.0000
20324 \begin_inset space ~
20328 \begin_inset space ~
20332 \begin_inset Newline newline
20336 \begin_inset Flex Code
20339 \begin_layout Plain Layout
20342 -q commit -m"<description>" "<file-name>"
20348 \begin_inset Newline newline
20352 \begin_inset Flex Code
20355 \begin_layout Plain Layout
20366 \begin_layout Subsubsection
20372 \begin_layout Standard
20373 When you are sharing a repository with others, you may have to incorporate
20374 their changes into your working copy.
20377 \begin_layout Standard
20380 cvs -q update "<file-name>"
20383 \begin_layout Standard
20384 If a readonly checkout is detected the working copy is made writable and
20388 \begin_layout Standard
20391 cvs -q edit "<file-name>"
20394 \begin_layout Subsubsection
20397 Revert To Repository Version
20400 \begin_layout Standard
20401 This will discard all changes made to the document since the last check
20403 You get a warning before changes are discarded.
20404 Firstly the file is deleted, secondly CVS update command is run.
20407 \begin_layout Standard
20410 cvs -q update "<file-name>"
20413 \begin_layout Standard
20414 If a reserved checkout is detected and the working copy has no changes only
20415 the reservation is undone.
20418 \begin_layout Standard
20421 cvs -q unedit "<file-name>"
20424 \begin_layout Subsubsection
20430 \begin_layout Standard
20431 This will create a copy of the current document.
20432 Since CVS does not support copy operations natively, the version history
20433 is not preserved, and the copy is added as a new file.
20434 It requires a clean document without any changes since the last checkin.
20435 You are asked for a file name and a description of the copy operation.
20436 After that the copy is created, both locally and in the repository.
20437 If the parent directories of the copied and original document differ, all
20438 relative paths of included files of the copy are adjusted (like in
20440 File\SpecialChar menuseparator
20445 Finally, the copy is loaded instead of the original document.
20448 \begin_layout Labeling
20449 \labelwidthstring 00.00.0000
20451 \begin_inset space ~
20455 \begin_inset space ~
20459 \begin_inset Newline newline
20463 \begin_inset Flex Code
20466 \begin_layout Plain Layout
20469 \begin_inset Quotes eld
20473 \begin_inset Quotes erd
20482 \begin_inset Flex Code
20485 \begin_layout Plain Layout
20488 \begin_inset Quotes eld
20492 \begin_inset Quotes erd
20501 \begin_inset Newline newline
20505 \begin_inset Flex Code
20508 \begin_layout Plain Layout
20512 \begin_inset Quotes eld
20516 \begin_inset Quotes erd
20527 \begin_layout Subsubsection
20533 \begin_layout Standard
20534 This will rename the current document.
20535 Since CVS does not support rename operations natively, the version history
20536 is not preserved, the renamed document is added as a new file, and the
20537 original document is deleted.
20538 It requires a clean document without any changes since the last checkin.
20539 You are asked for a file name and a description of the rename operation.
20540 After that the document is renamed, both locally and in the repository.
20541 If the parent directories of the new and old file names differ, all relative
20542 paths of included files are adjusted (like in
20544 File\SpecialChar menuseparator
20549 Finally, the document is reloaded using the new name.
20552 \begin_layout Labeling
20553 \labelwidthstring 00.00.0000
20555 \begin_inset space ~
20559 \begin_inset space ~
20563 \begin_inset Newline newline
20567 \begin_inset Flex Code
20570 \begin_layout Plain Layout
20573 \begin_inset Quotes eld
20577 \begin_inset Quotes erd
20586 \begin_inset Flex Code
20589 \begin_layout Plain Layout
20592 \begin_inset Quotes eld
20596 \begin_inset Quotes erd
20605 \begin_inset Newline newline
20609 \begin_inset Flex Code
20612 \begin_layout Plain Layout
20616 \begin_inset Quotes eld
20620 \begin_inset Quotes erd
20629 \begin_inset Newline newline
20633 \begin_inset Flex Code
20636 \begin_layout Plain Layout
20640 \begin_inset Quotes eld
20644 \begin_inset Quotes erd
20655 \begin_layout Subsubsection
20656 Update of the local directory checkout from repository
20659 \begin_layout Standard
20660 Once your documents gets more complex, containing sub-documents and pictures,
20662 \begin_inset Flex Code
20665 \begin_layout Plain Layout
20671 files and so on using version control becomes more complicated.
20673 supports updating the whole tree in which resides the document.
20674 This become especially useful once you cooperate with people which neither
20675 have detailed knowledge about CVS usage nor they have ambition to commit
20676 additional material to the repository.
20677 You have to organize the files structure so that all external files are
20678 in the same directory or subdirectories of the document.
20679 It's good practice anyway to store multipart documents in an extra directory.
20682 \begin_layout Standard
20684 \begin_inset Flex Code
20687 \begin_layout Plain Layout
20688 Update local directory from repository
20693 command updates the whole directory.
20694 If local changes are detected user is warned before update starts.
20695 In case of merge conflicts both versions of the conflicting document parts
20696 are placed in the final document.
20697 You have to review and correct the result of the merge.
20698 You'll find the conflicts enclosed in pairs of
20699 \begin_inset Flex Code
20702 \begin_layout Plain Layout
20709 \begin_inset Flex Code
20712 \begin_layout Plain Layout
20719 \begin_inset Flex Code
20722 \begin_layout Plain Layout
20729 The first part is your version as before the update operation with the
20730 document name prepended.
20731 The second one is the repository version with the version number after
20733 \begin_inset Flex Code
20736 \begin_layout Plain Layout
20745 \begin_layout Labeling
20746 \labelwidthstring 00.00.0000
20748 \begin_inset space ~
20752 \begin_inset space ~
20756 \begin_inset Newline newline
20760 \begin_inset Flex Code
20763 \begin_layout Plain Layout
20771 (Ask if changes are detected.)
20772 \begin_inset Newline newline
20776 \begin_inset Flex Code
20779 \begin_layout Plain Layout
20780 cd $path; cvs -q update
20790 \begin_layout Standard
20792 \begin_inset Flex Code
20795 \begin_layout Plain Layout
20801 stands for the path to the document.
20804 \begin_layout Subsubsection
20810 \begin_layout Standard
20811 This shows the complete history of the CVS document.
20814 cvs log "<file-name>"
20816 is shown in a browser.
20819 \begin_layout Subsubsection
20823 \begin_layout Standard
20825 supports CVS version number, author name, date and time of last commit.
20826 All those are extracted from
20828 cvs log -r <file-name>
20832 \begin_inset CommandInset ref
20834 reference "subsec:VCS-Revision-Information"
20841 \begin_layout Subsection
20842 SVN commands in \SpecialChar LyX
20846 \begin_layout Standard
20847 SVN is now partially supported by \SpecialChar LyX
20849 You can find the commands in the
20851 File\SpecialChar menuseparator
20853 \begin_inset space ~
20859 Please note that if you use password protected access to repository via
20860 ssh, you will be asked in terminal window.
20862 was tested against SVN 1.5, 1.6, 1.7 and 1.8
20866 \begin_layout Plain Layout
20867 Most of the commands will work with 1.4 too, see
20868 \begin_inset CommandInset ref
20870 reference "subsec:SVN-Repo-Update"
20875 There seems to be currently unresolved permissions problem under SVN 1.8
20876 with reverting changes when file is locked.
20884 \begin_layout Subsubsection
20890 \begin_layout Standard
20891 If your document is not under revision control, this is the only item shown
20893 And if it is under revision control, the
20897 item is not visible.
20900 \begin_layout Standard
20901 This command registers in SVN your document ONLY in case you have already
20902 the documents directory under SVN control (in particular
20907 This means you have to checkout the archive by yourself.
20910 \begin_layout Standard
20911 Then you are asked interactively to supply an initial description of the
20913 Don't forget that registered file is not yet commited.
20916 \begin_layout Standard
20917 SVN command that is run:
20920 \begin_inset Quotes eld
20924 \begin_inset Quotes erd
20930 \begin_layout Standard
20935 to understand the switches.
20938 \begin_layout Subsubsection
20944 \begin_layout Standard
20945 When you are finished editing a file, you commit your changes.
20946 When you do this, you are asked for a description of the changes.
20947 After that changes are commited.
20950 \begin_layout Standard
20955 \begin_layout Plain Layout
20956 In case locking is not enabled.
20958 \begin_inset CommandInset ref
20960 reference "subsec:SVN-File-Locking"
20971 svn commit -q -m"<description>" <file-name>
20974 \begin_layout Subsubsection
20980 \begin_layout Standard
20981 Updates the changes of this file from the repository.
20982 Be sure you understand SVN merging and conflicts resolving before using
20983 this function, because all conflicts has to be resolved manually by you!
20986 \begin_layout Standard
20991 \begin_layout Plain Layout
20999 svn update --non-interactive
21000 \begin_inset Quotes eld
21004 \begin_inset Quotes erd
21010 \begin_layout Subsubsection
21013 Revert To Repository Version
21016 \begin_layout Standard
21017 This will discard all changes made to the document since the last check
21019 You get a warning before changes are discarded.
21022 \begin_layout Standard
21026 \begin_inset Quotes eld
21030 \begin_inset Quotes erd
21036 \begin_layout Subsubsection
21042 \begin_layout Standard
21043 This will create a copy of the current document including the version history.
21044 It requires a clean document without any changes since the last checkin.
21045 You are asked for a file name and a description of the copy operation.
21046 After that the copy is created, both locally and in the repository.
21047 If the parent directories of the copied and original document differ, all
21048 relative paths of included files of the copy are adjusted (like in
21050 File\SpecialChar menuseparator
21055 Finally, the copy is loaded instead of the original document.
21058 \begin_layout Labeling
21059 \labelwidthstring 00.00.0000
21061 \begin_inset space ~
21065 \begin_inset space ~
21069 \begin_inset Newline newline
21073 \begin_inset Flex Code
21076 \begin_layout Plain Layout
21080 \begin_inset Quotes eld
21084 \begin_inset Quotes erd
21088 \begin_inset Quotes eld
21092 \begin_inset Quotes erd
21101 \begin_inset Newline newline
21105 \begin_inset Flex Code
21108 \begin_layout Plain Layout
21117 \begin_layout Subsubsection
21123 \begin_layout Standard
21124 This will rename the current document including the version history.
21125 It requires a clean document without any changes since the last checkin.
21126 You are asked for a file name and a description of the rename operation.
21127 After that the document is renamed, both locally and in the repository.
21128 If the parent directories of the new and old file names differ, all relative
21129 paths of included files are adjusted (like in
21131 File\SpecialChar menuseparator
21136 Finally, the document is reloaded using the new name.
21139 \begin_layout Labeling
21140 \labelwidthstring 00.00.0000
21142 \begin_inset space ~
21146 \begin_inset space ~
21150 \begin_inset Newline newline
21154 \begin_inset Flex Code
21157 \begin_layout Plain Layout
21161 \begin_inset Quotes eld
21165 \begin_inset Quotes erd
21169 \begin_inset Quotes eld
21173 \begin_inset Quotes erd
21182 \begin_inset Newline newline
21186 \begin_inset Flex Code
21189 \begin_layout Plain Layout
21198 \begin_layout Subsubsection
21199 \begin_inset CommandInset label
21201 name "subsec:SVN-Repo-Update"
21205 Update of the local directory checkout from repository
21209 \begin_layout Plain Layout
21210 Note that this command will work only with subversion
21211 \begin_inset Formula $\geqq1.5$
21222 \begin_layout Standard
21223 All the commands above have one shortcomming - they deal with the current
21225 Once your document contains pictures, includes external
21226 \begin_inset Flex Code
21229 \begin_layout Plain Layout
21235 files and so on administration becomes more complicated.
21237 now supports updating the whole tree in which resides the document
21241 \begin_layout Plain Layout
21242 One need to organize the files structure so that all external files are
21243 in the same directory or subdirectories of the document.
21250 This become especially useful once you cooperate with people which neither
21251 know about subversion management nor they have ambition to commit additional
21252 material to the repository.
21256 \begin_layout Standard
21257 \begin_inset Flex Code
21260 \begin_layout Plain Layout
21261 Update local directory from repository
21266 command updates the whole directory and in case of merge conflicts local
21267 version of the files are left, so no unintended data loss occurs.
21268 If local changes are detected user is warned before update starts.
21271 \begin_layout Labeling
21272 \labelwidthstring 00.00.0000
21274 \begin_inset space ~
21278 \begin_inset space ~
21282 \begin_inset Newline newline
21286 \begin_inset Flex Code
21289 \begin_layout Plain Layout
21295 (Ask if changes are detected.)
21296 \begin_inset Newline newline
21300 \begin_inset Flex Code
21303 \begin_layout Plain Layout
21304 svn update –accept mine-full $path
21312 \begin_layout Standard
21314 \begin_inset Flex Code
21317 \begin_layout Plain Layout
21323 stands for the path to the document.
21326 \begin_layout Subsubsection
21332 \begin_layout Standard
21333 This shows the complete history of the SVN document.
21337 \begin_inset Quotes eld
21341 \begin_inset Quotes erd
21346 is shown in a browser.
21349 \begin_layout Subsubsection
21351 \begin_inset CommandInset label
21353 name "subsec:SVN-File-Locking"
21360 \begin_layout Standard
21361 The file exchange through various revision control systems brings the problem
21362 of merge conflicts in case two different users try to edit the same (parts
21364 When such a conflict happens it needs manual resolving and one reasonable
21365 alternative is to provide some kind of locking mechanism, which guarantees
21366 that only one user is allowed to edit file at the given time.
21369 \begin_layout Standard
21370 SVN has two such mechanisms to provide mutual exclusivity for file access
21371 - locks and automatic setting of write permissions (see sec.
21373 \begin_inset CommandInset ref
21375 reference "subsec:Automatical-Locking-Property"
21380 \begin_inset Flex Code
21383 \begin_layout Plain Layout
21393 \begin_layout Plain Layout
21394 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
21400 If this property is detected for a given document \SpecialChar LyX
21401 starts to use SVN locks
21402 for document editing automatically and the whole check-in/out mechanism
21403 switches to the same regimen as for RCS.
21404 This in particular means there are two different modes of file use in \SpecialChar LyX
21408 \begin_layout Itemize
21410 The loaded file is in the read-only mode.
21411 For editing on needs to check-out.
21416 consists of updating from the repository and gaining write lock.
21417 If the lock is not possible to obtain, we remain in unlocked state.
21420 \begin_layout Itemize
21422 The loaded file is in the 'normal' edit mode.
21423 No other user is allowed to edit the file.
21428 consists of commiting changes and releasing write-lock.
21429 If no changes have been made to the document, no commit will be produced
21433 \begin_layout Plain Layout
21434 Don't be puzzled by the fact that you will be asked for commit message anyway.
21439 and only the write-lock will be released.
21442 \begin_layout Standard
21446 \begin_layout Labeling
21447 \labelwidthstring 00.00.0000
21450 svn commit -q -m"<description>" "<file-name>"
21451 \begin_inset Newline newline
21454 svn unlock "<file-name>"
21457 \begin_layout Labeling
21458 \labelwidthstring 00.00.0000
21461 svn update "<file-name>"
21462 \begin_inset Newline newline
21465 svn lock "<file-name>"
21468 \begin_layout Subsubsection
21471 \begin_inset CommandInset label
21473 name "subsec:Automatical-Locking-Property"
21479 Automatic Locking Property
21482 \begin_layout Standard
21483 The above mentioned automatic setting of write permissions of the .lyx file
21486 File\SpecialChar menuseparator
21488 \begin_inset space ~
21491 Control\SpecialChar menuseparator
21492 Toggle locking property
21495 This command is active only when the file is not locked on the svn server
21497 you need to check-out before proceeding).
21500 \begin_layout Labeling
21501 \labelwidthstring 00.00.0000
21503 \begin_inset space ~
21509 \begin_layout Labeling
21510 \labelwidthstring 00.00.0000
21513 svn propset svn:needs-lock ON "<file-name>"
21516 \begin_layout Labeling
21517 \labelwidthstring 00.00.0000
21520 svn propdel svn:needs-lock "<file-name>"
21523 \begin_layout Subsubsection
21524 \begin_inset CommandInset label
21526 name "subsec:VCS-Revision-Information"
21530 Revision Information in Documents
21533 \begin_layout Standard
21534 There are more possibilities how to activate revision information in our
21538 \begin_layout Itemize
21541 \begin_inset Separator parbreak
21548 \begin_layout Itemize
21549 tree revision information (
21550 \begin_inset Flex Code
21553 \begin_layout Plain Layout
21560 The result is the output of the
21561 \begin_inset Flex Code
21564 \begin_layout Plain Layout
21570 command, the following table gives you an idea, how to read the results.
21573 \begin_layout Standard
21575 \begin_inset Tabular
21576 <lyxtabular version="3" rows="6" columns="2">
21577 <features tabularvalignment="middle">
21578 <column alignment="center" valignment="top">
21579 <column alignment="center" valignment="top">
21581 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
21584 \begin_layout Plain Layout
21590 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
21593 \begin_layout Plain Layout
21601 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21604 \begin_layout Plain Layout
21610 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21613 \begin_layout Plain Layout
21614 mixed revision working copy
21621 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21624 \begin_layout Plain Layout
21630 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21633 \begin_layout Plain Layout
21634 modified working copy
21641 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21644 \begin_layout Plain Layout
21650 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21653 \begin_layout Plain Layout
21654 switched working copy
21661 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21664 \begin_layout Plain Layout
21670 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21673 \begin_layout Plain Layout
21674 partial working copy, from a sparse checkout
21681 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
21684 \begin_layout Plain Layout
21690 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
21693 \begin_layout Plain Layout
21694 mixed revision, modified, switched working copy
21707 \begin_layout Itemize
21708 file revision information.
21709 The result comes from parsing the output of
21710 \begin_inset Flex Code
21713 \begin_layout Plain Layout
21715 \begin_inset space ~
21719 \begin_inset space ~
21723 \begin_inset space ~
21732 Supported flags are:
21733 \begin_inset Separator parbreak
21740 \begin_layout Itemize
21741 version number of the last commit (
21742 \begin_inset Flex Code
21745 \begin_layout Plain Layout
21754 \begin_layout Itemize
21755 author of the last commit (
21756 \begin_inset Flex Code
21759 \begin_layout Plain Layout
21768 \begin_layout Itemize
21769 date of the last commit (
21770 \begin_inset Flex Code
21773 \begin_layout Plain Layout
21782 \begin_layout Itemize
21783 time of the last commit (
21784 \begin_inset Flex Code
21787 \begin_layout Plain Layout
21797 \begin_layout Standard
21798 You can obtain this info via InsetInfo (e.g.
21800 \begin_inset Flex Code
21803 \begin_layout Plain Layout
21804 info-insert buffer vcs-date
21810 The information will be available only when you have the file stored under
21811 svn managment (i.e.
21813 \begin_inset Flex Code
21816 \begin_layout Plain Layout
21822 directory is available with your document).
21826 \begin_layout Itemize
21827 Another—a hacking one—possibility is to use svn keywords
21831 \begin_layout Plain Layout
21832 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
21838 In short – you set file keywords property (e.g.
21841 svn propset svn:keywords 'Rev' file.lyx
21843 ) and then paste keyword \SpecialChar TeX
21848 \begin_layout Plain Layout
21849 This is an easy way how to ensure that \SpecialChar LyX
21850 won't break the line in the middle
21856 tag in your document (e.g.
21861 \begin_layout Plain Layout
21869 This way svn client will automatically substitute revision number (e.g.
21874 \begin_layout Plain Layout
21881 ) after each update and commit.
21882 There are more problems with this approach.
21883 Firstly, the '$' character is used in \SpecialChar TeX
21884 world for math equations, so any
21885 occurence of math formula
21886 \begin_inset Formula $Rev$
21890 \begin_inset Formula $Rev:59$
21893 in your \SpecialChar LyX
21895 Similarly for other keywords like Id, Date, Author, etc.
21896 Secondly svn output is dependent on your locales, so its very easy that
21897 svn would produce some problematic strings once Date is used.
21898 Thirdly you get the whole 'Rev: 59' string in your document instead of
21900 Until subversion implements user's custom keywords it will be hard to use
21901 this approach reliably or let \SpecialChar LyX
21902 to support it directly.
21905 \begin_layout Subsection
21906 SVN and Windows Environment
21909 \begin_layout Quote
21910 My inclination is to say that if the user cannot figure out the command
21911 line operations on their own fairly quickly, they would be well advised
21912 to use TortoiseSVN.
21918 \begin_layout Subsubsection
21922 \begin_layout Standard
21923 In addition to installing \SpecialChar LyX
21924 , and having access to a Subversion repository,
21925 the user will need to install the Subversion client program.
21926 A Windows installer for the client program is available from
21927 \begin_inset CommandInset href
21930 target "http://www.collab.net/nonav/downloads/subversion/"
21935 The user may also want to install
21936 \begin_inset CommandInset href
21939 target "http://tortoisesvn.tigris.org/"
21943 , which integrates Subversion operations into the context (rightclick) menu
21944 of Windows Explorer.
21945 Operations done outside \SpecialChar LyX
21946 will typically be more convenient using the Explorer
21948 Note that TortoiseSVN is not a replacement for the client program, which
21949 is what \SpecialChar LyX
21953 \begin_layout Subsubsection
21954 Bringing a document under Subversion control
21957 \begin_layout Standard
21958 Before a \SpecialChar LyX
21959 document can be brought under version control in Subversion, its
21960 parent directory needs to be under version control.
21961 If the document is being added to a project already in the repository,
21962 this is accomplished by checking the project out to the directory where
21963 the new document will be placed.
21964 If the project itself is not yet under version control (for instance, if
21965 this document starts a new project), the directory must be imported into
21967 This is done outside \SpecialChar LyX
21969 Both import and checkout are easily accomplished from the Explorer context
21970 menu using TortoiseSVN, or alternatively can be done using the command
21971 line client at a DOS prompt.
21972 The procedure for importing the project using TortoiseSVN is described
21973 below, assuming an existing repository and a new project being started
21981 For information on using the Subversion client program, run
21988 \begin_layout Enumerate
21995 in Windows Explorer, right click it, and select
21997 TortoiseSVN\SpecialChar menuseparator
22001 If necessary, adjust the URL for the repository, then click OK.
22004 \begin_layout Enumerate
22005 Right click the level of the repository under which you want to place the
22006 new project folder (typically the top level) and click
22010 Supply a name for the project folder and click OK.
22011 Add a message for the log file if desired, then click OK again.
22012 The new project folder should appear in the repository.
22013 Finally, click OK again to exit the repository browser.
22016 \begin_layout Enumerate
22017 Once again right click
22023 , this time selecting SVN Checkout\SpecialChar ldots
22024 Select the URL of the project folder
22025 you just created in the repository, and set the checkout directory to
22033 You will be warned about a non-empty folder; click OK to proceed.
22034 You should now have a
22045 \begin_layout Enumerate
22046 Create or open your document in \SpecialChar LyX
22049 File\SpecialChar menuseparator
22051 \begin_inset space ~
22054 Control\SpecialChar menuseparator
22058 Add a log message and click OK to commit the document to version control.
22061 \begin_layout Standard
22062 From this point onward, you should have full functionality in the
22064 File\SpecialChar menuseparator
22066 \begin_inset space ~
22072 You also have the option of checking the document in and out, viewing its
22074 using the TortoiseSVN context menu in Windows Explorer or the Subversion
22075 client program from a command prompt.
22078 \begin_layout Subsubsection
22079 SSH tunnel used with SVN under Windows
22082 \begin_layout Standard
22083 Compared with Linux setting up an svn client to communicate over ssh under
22084 Windows is a rather troublesome task.
22085 We will at least offer some hints how to setup the client side but prior
22086 knowledge about ssh and the Windows command line is needed, also be prepared
22087 for a great deal of frustration\SpecialChar ldots
22091 \begin_layout Enumerate
22092 Get an svn client for windows, as described in the previous sections.
22093 When it is a fresh install run some svn command (e.g.
22095 \begin_inset Flex Code
22098 \begin_layout Plain Layout
22104 ) to create config files, which you will need to change later on.
22107 \begin_layout Enumerate
22108 Choose an ssh client for Windows.
22109 There are several possibilities, we will use the one from Putty tools
22113 \begin_layout Plain Layout
22114 \begin_inset Flex URL
22117 \begin_layout Plain Layout
22119 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
22130 You will need to set the connection up so that the client doesn't ask for
22131 any password from you.
22132 To keep things easy we will use only keys without any additional password
22134 \begin_inset Separator parbreak
22141 \begin_layout Enumerate
22143 \begin_inset Flex Code
22146 \begin_layout Plain Layout
22153 Save your private .ppk key file and put the public one on the server side.
22154 If the SVN server runs on Linux, note that the format of the public key
22155 is not compatible with Linux openssh and you will need to direcly copy-paste
22158 Public key for pasting into OpenSSH authorized_keys file
22160 :” edit field into the server's
22161 \begin_inset Flex Code
22164 \begin_layout Plain Layout
22165 ~/.ssh/authorized_keys
22171 \begin_inset Flex Code
22174 \begin_layout Plain Layout
22183 \begin_layout Enumerate
22185 \begin_inset Flex Code
22188 \begin_layout Plain Layout
22195 In the SVN config file
22199 \begin_layout Plain Layout
22200 Exact path depends on Windows version, usually somewhere around
22201 \begin_inset Flex Code
22204 \begin_layout Plain Layout
22207 Documents and Settings
22221 \begin_inset Flex Code
22224 \begin_layout Plain Layout
22239 , section [tunnels], setup ssh command, e.g.
22241 \begin_inset Flex Code
22244 \begin_layout Plain Layout
22245 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
22254 \begin_layout Plain Layout
22255 It will usually take a lot of time to get exact command right and it depends
22257 For example do not have some remote server saved as a default session in
22259 If things fail, try to connect via plink without SVN first.
22268 \begin_layout Enumerate
22269 Checkout the SVN archive, e.
22270 \begin_inset space \thinspace{}
22274 \begin_inset Newline newline
22278 \begin_inset Flex Code
22281 \begin_layout Plain Layout
22282 svn co svn+ssh://user@server/repository_path
22290 \begin_layout Subsubsection
22291 End-of-Line Conversions
22294 \begin_layout Standard
22295 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
22297 use different line endings inside the .lyx files.
22298 This is not a problem as far as \SpecialChar LyX
22299 functionality is concerned, but the commit
22300 diffs will be huge and merge-conflicts prone.
22301 Fortunately SVN itself knows
22305 \begin_layout Plain Layout
22306 \begin_inset Flex URL
22309 \begin_layout Plain Layout
22311 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
22321 how to deal with CR/LF problems when switching .lyx files to the
22322 \begin_inset Flex Code
22325 \begin_layout Plain Layout
22335 \begin_layout Plain Layout
22337 \begin_inset Flex Code
22340 \begin_layout Plain Layout
22341 svn propset svn:eol-style native FILE_NAME
22354 \begin_layout Subsection
22355 GIT commands in \SpecialChar LyX
22359 \begin_layout Standard
22360 A minimal subset of GIT commands is now supported by \SpecialChar LyX
22362 You can find the commands in the
22364 File\SpecialChar menuseparator
22366 \begin_inset space ~
22372 Please note that if you use password protected access to repository via
22373 ssh, you will be asked in terminal window.
22375 was tested against GIT 1.7.
22379 \begin_layout Plain Layout
22380 Windows users please note that you need to ensure that git is on the path.
22381 This can be set from within \SpecialChar LyX
22384 Tools\SpecialChar menuseparator
22385 Preferences\SpecialChar menuseparator
22386 Paths\SpecialChar menuseparator
22397 \begin_layout Standard
22398 One big difference of GIT and the other supported version control systems
22399 is the distributed nature of GIT: With traditional version control systems
22400 there is one central server which hosts the repository.
22401 Users commit their changes to the server, and get updates made by other
22403 With GIT, users commit to a local repository.
22404 The local repository can be synchronized with one or more remote repositories
22406 \begin_inset Flex Code
22409 \begin_layout Plain Layout
22416 \begin_inset Flex Code
22419 \begin_layout Plain Layout
22427 does not interact in any way with remote GIT repositories.
22428 It works exclusively with the local repository in a very similar way as
22429 with a central CVS or SVN repository.
22430 If you use remote GIT repositories you need to do the
22431 \begin_inset Flex Code
22434 \begin_layout Plain Layout
22441 \begin_inset Flex Code
22444 \begin_layout Plain Layout
22450 operations with your favourite GIT client.
22453 \begin_layout Subsubsection
22459 \begin_layout Standard
22460 If your document is not under revision control, this is the only item shown
22462 And if it is under revision control, the
22466 item is not visible.
22469 \begin_layout Standard
22470 This command registers in GIT your document ONLY in case you have already
22471 the documents directory under GIT control (in particular
22476 This means you have to checkout the archive by yourself.
22479 \begin_layout Standard
22480 Then you are asked interactively to supply an initial description of the
22482 Don't forget that registered file is not yet commited.
22485 \begin_layout Standard
22486 GIT command that is run:
22489 \begin_inset Quotes eld
22493 \begin_inset Quotes erd
22499 \begin_layout Standard
22504 to understand the switches.
22507 \begin_layout Subsubsection
22513 \begin_layout Standard
22514 When you are finished editing a file, you commit your changes.
22515 When you do this, you are asked for a description of the changes.
22516 After that changes are commited.
22519 \begin_layout Standard
22522 git commit -q -m"<description>" <file-name>
22525 \begin_layout Subsubsection
22528 Revert To Repository Version
22531 \begin_layout Standard
22532 This will discard all changes made to the document since the last check
22534 You get a warning before changes are discarded.
22537 \begin_layout Standard
22541 \begin_inset Quotes eld
22545 \begin_inset Quotes erd
22551 \begin_layout Subsubsection
22557 \begin_layout Standard
22558 This will rename the current document including the version history.
22559 It requires a clean document without any changes since the last checkin.
22560 You are asked for a file name and a description of the rename operation.
22561 After that the document is renamed, both locally and in the repository.
22562 If the parent directories of the new and old file names differ, all relative
22563 paths of included files are adjusted (like in
22565 File\SpecialChar menuseparator
22570 Finally, the document is reloaded using the new name.
22573 \begin_layout Labeling
22574 \labelwidthstring 00.00.0000
22576 \begin_inset space ~
22580 \begin_inset space ~
22584 \begin_inset Newline newline
22588 \begin_inset Flex Code
22591 \begin_layout Plain Layout
22595 \begin_inset Quotes eld
22599 \begin_inset Quotes erd
22603 \begin_inset Quotes eld
22607 \begin_inset Quotes erd
22616 \begin_inset Newline newline
22620 \begin_inset Flex Code
22623 \begin_layout Plain Layout
22632 \begin_layout Subsubsection
22638 \begin_layout Standard
22639 This shows the complete history of the GIT document.
22643 \begin_inset Quotes eld
22647 \begin_inset Quotes erd
22652 is shown in a browser.
22655 \begin_layout Subsubsection
22659 \begin_layout Standard
22661 supports GIT hash number of the last commit to the file, author name, date
22662 and time of last commit.
22663 All those are extracted from
22665 git log -n 1 --pretty=format:%H%n%an%n%ai
22668 Tree version information is obtained via
22670 git describe --abbrev --dirty --long
22674 \begin_inset CommandInset ref
22676 reference "subsec:VCS-Revision-Information"
22683 \begin_layout Subsection
22687 \begin_layout Standard
22688 With the recent addition of the vc-command function \SpecialChar LyX
22689 power users are allowed
22690 to create their own commands for revision control.
22693 \begin_layout Standard
22694 As an example you can see how two TortoiseSVN commands could be integrated
22698 \begin_layout Description
22700 \begin_inset Flex Code
22703 \begin_layout Plain Layout
22704 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
22712 \begin_layout Description
22714 \begin_inset Flex Code
22717 \begin_layout Plain Layout
22718 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
22726 \begin_layout Subsection
22727 Version control and Document comparison
22730 \begin_layout Standard
22731 One of the typical uses of version control is to inspect the changes between
22732 revisions, usually by creating
22733 \begin_inset Flex Code
22736 \begin_layout Plain Layout
22743 While this is useful for plain text files, it is much less useful in the
22744 case of \SpecialChar LyX
22745 files, which have more a complicated structure.
22746 Hence we provide binding to the Document comparison feature.
22747 There are two ways of calling this feature - either by direct call of
22748 \begin_inset Flex Code
22751 \begin_layout Plain Layout
22758 function (for details see \SpecialChar LyX
22759 functions manual) or by icon/menu item
22760 \begin_inset Flex Noun
22763 \begin_layout Plain Layout
22764 Compare with older revision...
22770 One can either compare two chosen revisions of the document or he can simply
22771 compare the current version of edited text with older revisions (where
22773 \begin_inset Flex Noun
22776 \begin_layout Plain Layout
22782 ' revisions back means comparison of the edited file with last commited
22787 \begin_layout Standard
22788 This feature is supported for SVN and RCS though due to the more complicated
22789 versioning scheme of RCS there is a constraint – when addressing the revisions
22790 in dialog, numbers always point to the last number in RCS revision number,
22793 We don't currently support GIT addressing of revisions, one can just compare
22794 edited document with its revision X steps backs, where X is addressed as
22798 \begin_layout Section
22799 Literate Programming
22802 \begin_layout Standard
22807 (kayvan@sylvan.com)
22811 original documentation written by
22813 Edmar Wienskoski Jr.
22816 (edmar-w-jr@technologist.com)
22819 \begin_layout Subsection
22823 \begin_layout Standard
22824 The main purpose of this documentation is to show you how to use \SpecialChar LyX
22826 programming, where it is assumed that you are familiar with this programming
22827 technique, and know what
22828 \begin_inset Quotes eld
22832 \begin_inset Quotes erd
22836 \begin_inset Quotes eld
22840 \begin_inset Quotes erd
22844 If that is not the case, please follow the web links provided in the following
22846 There is a lot of good documentation out there covering old development
22847 history to the latest tools tips.
22850 \begin_layout Standard
22851 It is also assumed that you are familiar with \SpecialChar LyX
22852 itself to a point that you
22853 are comfortable changing your \SpecialChar LyX
22854 preferences, and X resources file.
22855 If that is not the case please refer to other \SpecialChar LyX
22856 documentation to cover your
22860 \begin_layout Subsection
22861 Literate Programming
22864 \begin_layout Standard
22865 From the Literate Programming FAQ:
22868 \begin_layout Quotation
22869 Literate programming is the combination of documentation and source together
22870 in a fashion suited for reading by human beings.
22871 In fact, literate programs should be enjoyable reading, even inviting!
22872 (Sorry Bob, I couldn't resist!) In general, literate programs combine source
22873 and documentation in a single file.
22874 Literate programming tools then parse the file to produce either readable
22875 documentation or compilable source.
22876 The WEB style of literate programming was created by D.
22877 \begin_inset space \thinspace{}
22881 Knuth during the development of his \SpecialChar TeX
22882 typesetting software.
22886 \begin_layout Standard
22887 Another excerpt says:
22890 \begin_layout Quotation
22893 How is literate programming different from verbose commenting?
22896 \begin_layout Quotation
22897 There are three distinguishing characteristics.
22898 In order of importance, they are:
22899 \begin_inset Separator parbreak
22906 \begin_layout Itemize
22907 flexible order of elaboration
22910 \begin_layout Itemize
22911 automatic support for browsing
22914 \begin_layout Itemize
22915 typeset documentation, especially diagrams and mathematics
22919 \begin_layout Standard
22920 Now that I sparked your curiosity, take a look in the references.
22923 \begin_layout Subsubsection
22927 \begin_layout Standard
22928 The complete Literate Programming FAQ can be found at:
22931 \begin_layout Quote
22932 Literate Programming FAQ
22933 \begin_inset Flex URL
22936 \begin_layout Plain Layout
22938 http://www.literateprogramming.com/lpfaq.pdf
22946 \begin_layout Standard
22947 The FAQ lists 23 (twenty three!) different literate programming tools.
22948 Where some are specialized or
22949 \begin_inset Quotes eld
22953 \begin_inset Quotes erd
22956 for particular programming languages, while other have general scope.
22961 for my own use for several reasons:
22964 \begin_layout Itemize
22965 It can generate the documentation either in \SpecialChar LaTeX
22969 \begin_layout Itemize
22970 It has a open architecture, i.
22971 \begin_inset space \thinspace{}
22975 \begin_inset space \space{}
22978 it is easy to plug in new filters and to perform special processing that
22983 \begin_layout Itemize
22984 There is a good selection of filters available already (the HTML is one
22988 \begin_layout Itemize
22992 \begin_layout Standard
22993 The Noweb web page can be found at:
22996 \begin_layout Quote
22998 \begin_inset Flex URL
23001 \begin_layout Plain Layout
23003 http://www.cs.virginia.edu/~nr/noweb/
23011 \begin_layout Standard
23012 Starting from there you can reach many other interesting links and even
23013 some literate program examples.
23016 \begin_layout Subsection
23018 and Literate Programming with Noweb
23021 \begin_layout Standard
23022 The \SpecialChar LyX
23023 support for Literate Programming is provided by using the generic \SpecialChar LyX
23025 converters mechanism.
23026 This support is provided in a
23027 \begin_inset Quotes eld
23031 \begin_inset Quotes erd
23035 \begin_inset space \thinspace{}
23039 \begin_inset space \space{}
23042 you will be able to use this new \SpecialChar LyX
23043 feature with some other literate programming
23044 tool of your choice by just changing your \SpecialChar LyX
23048 \begin_layout Subsubsection
23049 Generating documents and code (weaving and tangling)
23052 \begin_layout Paragraph
23053 Using the noweb module
23056 \begin_layout Standard
23057 If you have installed Noweb and \SpecialChar LyX
23058 successfully, whenever you open a new document,
23059 after you have chosen its document class, use the Document->Settings menu
23061 \begin_inset Quotes eld
23065 \begin_inset Quotes erd
23069 If Noweb is correctly installed, when you click on the
23070 \begin_inset Quotes eld
23074 \begin_inset Quotes erd
23077 link, you will see the
23078 \begin_inset Quotes eld
23082 \begin_inset Quotes erd
23085 module in the available list and you can add it to your document.
23088 \begin_layout Paragraph
23092 \begin_layout Standard
23094 enables you to write code with a layout named
23095 \begin_inset Flex Noun
23098 \begin_layout Plain Layout
23105 Noweb delimits chunks like this:
23108 \begin_layout LyX-Code
23112 \begin_layout LyX-Code
23116 \begin_layout LyX-Code
23120 \begin_layout LyX-Code
23124 \begin_layout LyX-Code
23128 \begin_layout Standard
23129 The problem is that whatever is written in between the << and the
23133 must be taken literally, i.
23134 \begin_inset space \thinspace{}
23138 \begin_inset space \space{}
23142 should be prevented from making any special interpretation of what has
23144 This is also handled by
23145 \begin_inset Flex Noun
23148 \begin_layout Plain Layout
23154 , that works like a normal paragraph but has a free spacing capability.
23157 \begin_layout Standard
23158 As a special note, you can also use the
23159 \begin_inset Quotes eld
23163 \begin_inset Quotes erd
23166 construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
23170 \begin_layout LyX-Code
23174 \begin_layout LyX-Code
23175 def some_function(args):
23178 \begin_layout LyX-Code
23179 "This is the doc string for this function."
23182 \begin_layout LyX-Code
23183 print "My args: ", args
23186 \begin_layout LyX-Code
23187 @ %def some_function
23190 \begin_layout Standard
23191 For an example of this usage and the resulting cross-reference output, look
23192 at the Literate python program in
23194 LIBDIR/examples/listerrors.lyx
23196 which should make this all clear.
23199 \begin_layout Paragraph
23200 Generating the documentation
23203 \begin_layout Standard
23204 At this point you already have a new document file with a proper document
23205 class, and with some code and text on it.
23206 How do I print it? The answer is simple, you select
23208 View\SpecialChar menuseparator
23212 Just like you would do for a plain document.
23213 No special procedure is required.
23216 \begin_layout Standard
23217 To help orientate you, I will now explain what happens inside \SpecialChar LyX
23221 \begin_layout Enumerate
23224 Update\SpecialChar menuseparator
23227 menu option is chosen, a \SpecialChar LaTeX
23230 \begin_inset Separator parbreak
23237 \begin_layout Standard
23238 If the document is of any literate class the generated file will be named
23239 with an extension name defined by the
23240 \begin_inset Quotes eld
23244 \begin_inset Quotes erd
23247 format (defined in the Preferences panel), otherwise the file will have
23256 \begin_layout Enumerate
23257 Note that the only difference so far is in the name of the file, no special
23258 processing is required by \SpecialChar LyX
23260 Given that you formatted the code using the
23261 \begin_inset Flex Noun
23264 \begin_layout Plain Layout
23270 layout that, by itself, takes care of the business.
23273 \begin_layout Enumerate
23274 If the document is of any literate class \SpecialChar LyX
23275 will then use the internal \SpecialChar LyX
23277 Noweb converter, followed by the Noweb to \SpecialChar LaTeX
23282 \begin_layout Plain Layout
23283 The converters are defined in the
23285 Tools\SpecialChar menuseparator
23289 \begin_inset Quotes eld
23293 \begin_inset Quotes erd
23305 manual for general information about converters.
23310 to generate the \SpecialChar LaTeX
23312 \begin_inset Separator parbreak
23319 \begin_layout Standard
23320 Otherwise it will just skip this step.
23324 \begin_layout Enumerate
23325 Finally, \SpecialChar LaTeX
23326 is invoked and the regular post processing continues as in a plain
23330 \begin_layout Standard
23331 Independence from a particular
23332 \begin_inset Quotes eld
23336 \begin_inset Quotes erd
23339 is easily achieved by changing the commands that are run by the various
23343 \begin_layout Paragraph
23344 Generating the code
23347 \begin_layout Standard
23348 When the build menu option is chosen or the corresponding button in the
23349 toolbar is pressed, a \SpecialChar LaTeX
23350 file is generated just like step 1 above.
23351 Next, \SpecialChar LyX
23357 This converter needs to be defined by the user and is not installed by
23358 default, though the Program format is.
23359 This converter (like any other converter) will have two parts:
23362 \begin_layout Enumerate
23363 The converter program itself.
23364 This program performs the conversion from the one format to the other (in
23365 this case, from the Noweb format to the Program pseudo-format).
23368 \begin_layout Enumerate
23369 The error log parser.
23370 This is a program whose sole purpose is to rewrite error messages in a
23371 format that \SpecialChar LyX
23373 This makes it possible for \SpecialChar LyX
23374 to place error boxes in the right places in
23378 \begin_layout Standard
23379 The first part, the
23380 \begin_inset Quotes eld
23384 \begin_inset Quotes erd
23387 setting, should be set to
23388 \begin_inset Newline newline
23392 \begin_inset Quotes eld
23400 \begin_inset Quotes erd
23404 \begin_inset Newline newline
23407 This basically means that \SpecialChar LyX
23409 \begin_inset Quotes eld
23413 \begin_inset Quotes erd
23416 (a program or script) with the name of the Noweb file (normally a file
23417 in the \SpecialChar LyX
23418 temp directory) and the directory path of the original \SpecialChar LyX
23423 \begin_layout Standard
23424 This is an implementation of
23425 \begin_inset Quotes eld
23429 \begin_inset Quotes erd
23432 that you can place in a directory on your path:
23435 \begin_layout Standard
23436 \begin_inset VSpace defskip
23442 \begin_layout Standard
23443 \begin_inset Newpage pagebreak
23449 \begin_layout Standard
23455 \begin_layout Standard
23461 \begin_layout Standard
23464 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
23467 \begin_layout Standard
23468 \begin_inset VSpace defskip
23474 \begin_layout Standard
23475 The next part of the converter setting is the
23476 \begin_inset Quotes eld
23480 \begin_inset Quotes erd
23483 which is to be set to
23484 \begin_inset Newline newline
23488 \begin_inset Quotes eld
23493 parselog=$$s/scripts/listerrors
23496 \begin_inset Quotes erd
23500 \begin_inset Newline newline
23503 This will run any errors that are generated by the
23504 \begin_inset Quotes eld
23508 \begin_inset Quotes erd
23511 process through the
23512 \begin_inset Quotes eld
23516 \begin_inset Quotes erd
23522 \begin_layout Standard
23523 The build will normally take place in \SpecialChar LyX
23524 's temporary directory, so the files
23525 produced by the conversion will be in that directory.
23527 will copy out what it regards as the `main' file, but the
23531 conversion may produce several files, and so most of these would then be
23532 deleted when \SpecialChar LyX
23534 This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
23535 the build-script chunk can place the generated files in that location.
23538 \begin_layout Paragraph
23539 Build instructions in the document
23542 \begin_layout Standard
23543 The last piece of the integration between \SpecialChar LyX
23545 \begin_inset Quotes eld
23549 \begin_inset Quotes erd
23553 Generally, the instructions for building your program should be embedded
23554 in a chunk of its own.
23556 \begin_inset Quotes eld
23560 \begin_inset Quotes erd
23563 above uses the notangle command to look for this chunk (called
23564 \begin_inset Quotes eld
23568 \begin_inset Quotes erd
23571 ) and runs its contents through
23572 \begin_inset Quotes eld
23576 \begin_inset Quotes erd
23582 \begin_layout Standard
23583 Typically, such a chunk would look something like this:
23586 \begin_layout LyX-Code
23590 \begin_layout LyX-Code
23592 \begin_inset Newline newline
23595 if [ -z "${NOWEB_SOURCE}" ]
23596 \begin_inset Newline newline
23602 \begin_layout LyX-Code
23603 NOWEB_SOURCE=myfile.nw
23604 \begin_inset Newline newline
23608 \begin_inset Newline newline
23612 code to extract files ...
23613 use NOWEB_OUTPUT_DIR here ...]
23614 \begin_inset Newline newline
23618 code to compile files ...]
23619 \begin_inset Newline newline
23625 \begin_layout Standard
23628 LIBDIR/examples/listerrors.lyx
23632 LIBDIR/examples/Literate.lyx
23634 which implement two versions of the
23635 \begin_inset Quotes eld
23639 \begin_inset Quotes erd
23642 program for some illustrations of how all of these pieces go together or
23645 LIBDIR/examples/noweb2lyx.lyx.
23648 Interestingly, these three files show off the language-indepence of the
23650 literate programming support since they are written in Python, C and Perl
23654 \begin_layout Subsubsection
23655 Configuring \SpecialChar LyX
23659 \begin_layout Standard
23660 All the Literate Programming support is configured by the
23662 Tools\SpecialChar menuseparator
23666 \begin_inset Quotes eld
23670 \begin_inset Quotes erd
23674 The important parts are:
23677 \begin_layout Description
23679 \begin_inset space ~
23683 \begin_inset Quotes eld
23687 \begin_inset Quotes erd
23691 \begin_inset space ~
23694 format Set up via the File Formats tab, this is where the Noweb-specific
23704 , the file extension is set to
23709 This tells \SpecialChar LyX
23710 to create a file with a
23714 extension in the first step of the conversion process.
23717 \begin_layout Description
23719 \begin_inset space ~
23727 \begin_inset space ~
23730 format This is an empty format whose sole purpose is to be the endpoint
23731 of a conversion (which then allows us to set up a converter for it).
23734 \begin_layout Description
23744 This converter performs the
23745 \begin_inset Quotes eld
23749 \begin_inset Quotes erd
23752 of the literate document.
23753 For Noweb, it is set to
23754 \begin_inset Quotes eld
23759 noweave -delay -index $$i > $$o
23762 \begin_inset Quotes erd
23768 \begin_layout Description
23778 \begin_inset Quotes eld
23782 \begin_inset Quotes erd
23786 As stated above, the Converter is set to
23787 \begin_inset Quotes eld
23795 \begin_inset Quotes erd
23798 , with Flags set to
23799 \begin_inset Newline newline
23803 \begin_inset Quotes eld
23808 parselog=$$s/scripts/listerrors
23811 \begin_inset Quotes erd
23817 \begin_layout Subsubsection
23821 \begin_layout Standard
23822 There is also a new function implemented in the \SpecialChar LyX
23824 \begin_inset Quotes eld
23827 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
23831 \begin_layout Standard
23832 When debugging code with ddd/gdb, it is possible to invoke a text editor
23833 at the current execution position with a single key stroke.
23834 The default ddd configuration for that is shift-ctrl-V.
23835 It happens that you can define the editor command line invocation in ddd
23838 Edit\SpecialChar menuseparator
23839 Preferences\SpecialChar menuseparator
23842 dialog and changing the "Edit Sources" entry.
23845 \begin_layout Standard
23846 I take advantage of the newly created \SpecialChar LyX
23847 server function and this ddd feature,
23849 \begin_inset Quotes eld
23853 \begin_inset Quotes erd
23859 \begin_layout Standard
23860 \begin_inset VSpace defskip
23866 \begin_layout Standard
23869 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
23872 \begin_layout Standard
23873 \begin_inset VSpace defskip
23879 \begin_layout Standard
23880 With this, whenever you are using ddd and find a point in the program that
23881 you want to edit, you just press shift-ctrl-V (in the ddd window), and
23882 ddd will forward this information to \SpecialChar LyX
23883 through the \SpecialChar LyX
23884 server and then the
23886 window will show the same file with the cursor at the same position ddd
23888 No more guessing or long scrolling to locate a point in the program back
23892 \begin_layout Standard
23893 Note however that you must enable the \SpecialChar LyX
23894 server to get this feature working
23895 (it is disabled by default).
23896 You can enable it in
23908 ) by entering in the
23914 \begin_inset Quotes eld
23919 /home/<your-home-directory>/.lyx/lyxpipe
23922 \begin_inset Quotes erd
23928 \begin_layout Standard
23929 Read the \SpecialChar LyX
23930 server documentation in the
23932 Customization Manual
23934 for further information.
23937 \begin_layout Subsubsection
23941 \begin_layout Standard
23942 There are six new buttons that can be added to your \SpecialChar LyX
23944 Five of these buttons are short cuts to layout styles:
23967 The last one is a short cut to the
23968 \begin_inset Quotes eld
23972 \begin_inset Quotes erd
23979 \begin_layout Standard
23981 has a range of buttons that are available for tool bar customization.
23982 In my toolbar I like to combine the six short cuts above with two more:
23987 \SpecialChar menuseparator
23992 \SpecialChar menuseparator
23999 Document\SpecialChar menuseparator
24000 View\SpecialChar menuseparator
24004 Here is how it looks like:
24007 \begin_layout LyX-Code
24011 \begin_layout LyX-Code
24015 \begin_layout LyX-Code
24016 Icon "layout Standard"
24019 \begin_layout LyX-Code
24020 Icon "layout Section"
24023 \begin_layout LyX-Code
24024 Icon "layout \SpecialChar LaTeX
24028 \begin_layout LyX-Code
24029 Icon "layout \SpecialChar LyX
24033 \begin_layout LyX-Code
24034 Icon "layout Chunk"
24037 \begin_layout LyX-Code
24041 \begin_layout LyX-Code
24045 \begin_layout LyX-Code
24046 Icon "buffer-typeset"
24049 \begin_layout LyX-Code
24050 Icon "build-program"
24053 \begin_layout LyX-Code
24057 \begin_layout LyX-Code
24061 \begin_layout LyX-Code
24065 \begin_layout LyX-Code
24069 \begin_layout LyX-Code
24073 \begin_layout Subsubsection
24074 Colors customization
24077 \begin_layout Standard
24078 There are a number of colors in \SpecialChar LyX
24079 that can be customized in
24084 One of the things that bothers people is the \SpecialChar LaTeX
24086 The default color is red, since the chunks uses \SpecialChar LaTeX
24087 font, and there is a lot
24088 of chunks in literate documents, you may get tired of seeing everything
24090 You can change it by going to the tabs
24099 \begin_layout Standard
24100 The next thing is the visible presence of the newline character in the screen.
24101 You can choose the color of this particular character and make it blend
24103 I recommend you choosing a color that is close to the background but not
24104 equal, that way you still can see it is there, but it is not bothering
24108 \begin_layout Subsection
24113 \begin_layout Standard
24122 is documented in the
24126 example file and in the Sweave manual (menu
24128 Help\SpecialChar menuseparator
24134 \begin_layout Chapter
24138 \begin_layout Standard
24139 You can do everything with \SpecialChar LyX
24140 that you can do with \SpecialChar LaTeX
24142 However, \SpecialChar LyX
24143 cannot support every \SpecialChar LaTeX
24145 But you can always use \SpecialChar TeX
24147 This chapter shows you some more special things you might want to use.
24148 For other special things you can do with figures, tables, floats, boxes
24149 and notes, have a look at the
24152 \begin_inset space ~
24160 \begin_layout Section
24161 Multiple Text Columns
24164 \begin_layout Standard
24165 This feature is independent of the option
24167 Two-column document
24169 in the document settings under
24174 If you want to have 2
24175 \begin_inset space ~
24178 columns for the whole document, it is recommended to use the
24180 Two-column document
24183 For all other cases use this feature.
24186 \begin_layout Standard
24187 To use multiple text columns in your document, you have to load the module
24194 Document\SpecialChar menuseparator
24195 Settings\SpecialChar menuseparator
24198 ) and must have the \SpecialChar LaTeX
24206 \begin_layout Standard
24207 Footnotes within multiple columns will be placed at the bottom of the page
24208 and not under each column.
24209 Within the different columns you can use everything, with the limitation
24210 that for floats you need to use the float option
24217 \begin_layout Subsection
24221 \begin_layout Standard
24222 If you want to have 2
24223 \begin_inset space ~
24226 columns in your text, insert a multicolumn inset via the menu
24228 Insert\SpecialChar menuseparator
24230 \begin_inset space ~
24233 Insets\SpecialChar menuseparator
24235 \begin_inset space ~
24240 where the columns should start.
24241 Write all text that should be printed in 2
24242 \begin_inset space ~
24245 columns into this inset.
24248 \begin_layout Standard
24249 Here is an example:
24252 \begin_layout Standard
24254 \begin_inset Flex Multiple Columns
24257 \begin_layout Plain Layout
24262 The Adventure of the Empty House
24265 \begin_inset Newline newline
24268 by Sir Arthur Conan Doyle
24271 \begin_layout Plain Layout
24274 It was in the spring of the year 1894 that all London was interested, and
24275 the fashionable world dismayed, by the murder of the Honourable Ronald
24276 Adair under most unusual and inexplicable circumstances.
24277 The public has already learned those particulars of the crime which came
24278 out in the police investigation, but a good deal was suppressed upon that
24279 occasion, since the case for the prosecution was so overwhelmingly strong
24280 that it was not necessary to bring forward all the facts.
24281 Only now, at the end of nearly ten years, am I allowed to supply those
24282 missing links which make up the whole of that remarkable chain.
24283 The crime was of interest in itself, but that interest was as nothing to
24284 me compared to the inconceivable sequel, which afforded me the greatest
24285 shock and surprise of any event in my adventurous life.
24286 Even now, after this long interval, I find myself thrilling as I think
24287 of it, and feeling once more that sudden flood of joy, amazement, and increduli
24288 ty which utterly submerged my mind.
24289 Let me say to that public, which has shown some interest in those glimpses
24290 which I have occasionally given them of the thoughts and actions of a very
24291 remarkable man, that they are not to blame me if I have not shared my knowledge
24292 with them, for I should have considered it my first duty to do so, had
24293 I not been barred by a positive prohibition from his own lips, which was
24294 only withdrawn upon the third of last month.
24302 \begin_layout Standard
24303 To get 3 or more columns, set the cursor into the multicolumn inset and
24306 Insert\SpecialChar menuseparator
24308 \begin_inset space ~
24312 \begin_inset space ~
24318 The number of the desired columns is written into that inset (for 3
24319 \begin_inset space ~
24323 \begin_inset Quotes eld
24327 \begin_inset Quotes erd
24331 \begin_inset Newline newline
24334 Here is an example with 3
24335 \begin_inset space ~
24341 \begin_layout Standard
24342 \begin_inset Flex Multiple Columns
24345 \begin_layout Plain Layout
24348 \begin_inset Argument 1
24351 \begin_layout Plain Layout
24357 It can be imagined that my close intimacy with Sherlock Holmes had interested
24358 me deeply in crime, and that after his disappearance I never failed to
24359 read with care the various problems which came before the public.
24360 And I even attempted, more than once, for my own private satisfaction,
24361 to employ his methods in their solution, though with indifferent success.
24362 There was none, however, which appealed to me like this tragedy of Ronald
24364 As I read the evidence at the inquest, which led up to a verdict of willful
24365 murder against some person or persons unknown, I realized more clearly
24366 than I had ever done the loss which the community had sustained by the
24367 death of Sherlock Holmes.
24368 There were points about this strange business which would, I was sure,
24369 have specially appealed to him, and the efforts of the police would have
24370 been supplemented, or more probably anticipated, by the trained observation
24371 and the alert mind of the first criminal agent in Europe.
24372 All day, as I drove upon my round, I turned over the case in my mind and
24373 found no explanation which appeared to me to be adequate.
24374 At the risk of telling a twice-told tale, I will recapitulate the facts
24375 as they were known to the public at the conclusion of the inquest.
24383 \begin_layout Standard
24384 You can have up to 10
24385 \begin_inset space ~
24388 columns if you want to, but that might not be very pleasant for the readers
24392 \begin_layout Standard
24393 \begin_inset Newpage newpage
24399 \begin_layout Subsection
24400 Columns inside Columns
24403 \begin_layout Standard
24404 You can also have columns inside columns:
24407 \begin_layout Standard
24408 \begin_inset Flex Multiple Columns
24411 \begin_layout Plain Layout
24414 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
24415 at that time governor of one of the Australian colonies.
24416 Adair's mother had returned from Australia to undergo the operation for
24417 cataract, and she, her son Ronald, and her daughter Hilda were living together
24421 \begin_layout Plain Layout
24422 \begin_inset Flex Multiple Columns
24425 \begin_layout Plain Layout
24428 The youth moved in the best society–had, so far as was known, no enemies
24429 and no particular vices.
24430 He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
24431 had been broken off by mutual consent some months before, and there was
24432 no sign that it had left any very profound feeling behind it.
24433 For the rest {sic} the man's life moved in a narrow and conventional circle,
24434 for his habits were quiet and his nature unemotional.
24435 Yet it was upon this easy-going young aristocrat that death came, in most
24436 strange and unexpected form, between the hours of ten and eleven-twenty
24437 on the night of March 30, 1894.
24445 \begin_layout Plain Layout
24448 Ronald Adair was fond of cards–playing continually, but never for such stakes
24450 He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
24451 It was shown that, after dinner on the day of his death, he had played
24452 a rubber of whist at the latter club.
24453 He had also played there in the afternoon.
24458 The evidence of those who had played with him– Mr.
24459 Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
24460 and that there was a fairly equal fall of the cards.
24461 Adair might have lost five pounds, but not more.
24462 His fortune was a considerable one, and such a loss could not in any way
24464 He had played nearly every day at one club or other, but he was a cautious
24465 player, and usually rose a winner.
24466 It came out in evidence that, in partnership with Colonel Moran, he had
24467 actually won as much as four hundred and twenty pounds in a sitting, some
24468 weeks before, from Godfrey Milner and Lord Balmoral.
24469 So much for his recent history as it came out at the inquest.
24477 \begin_layout Subsection
24481 \begin_layout Standard
24482 The examples in this section show some more special features of multiple
24486 \begin_layout Standard
24487 For more features of multiple columns, have a look at the documentation
24488 of the \SpecialChar LaTeX
24494 \begin_inset CommandInset citation
24503 \begin_layout Subsubsection
24507 \begin_layout Standard
24508 To add a preface text for multiple columns, set the cursor into the multicolumn
24509 inset and use the menu
24511 Insert\SpecialChar menuseparator
24515 Write your preface text into that inset.
24516 \begin_inset Newline newline
24519 This is an example with some preface text:
24522 \begin_layout Standard
24523 \begin_inset VSpace bigskip
24529 \begin_layout Standard
24530 \begin_inset Flex Multiple Columns
24533 \begin_layout Plain Layout
24534 \begin_inset Argument 2
24537 \begin_layout Plain Layout
24538 And the story continues and continues and continues and continues\SpecialChar ldots
24546 On the evening of the crime, he returned from the club exactly at ten.
24547 His mother and sister were out spending the evening with a relation.
24548 The servant deposed that she heard him enter the front room on the second
24549 floor, generally used as his sitting-room.
24550 She had lit a fire there, and as it smoked she had opened the window.
24551 No sound was heard from the room until eleven-twenty, the hour of the return
24552 of Lady Maynooth and her daughter.
24553 Desiring to say good-night, she attempted to enter her son's room.
24554 The door was locked on the inside, and no answer could be got to their
24555 cries and knocking.
24556 Help was obtained, and the door forced.
24557 The unfortunate young man was found lying near the table.
24558 His head had been horribly mutilated by an expanding revolver bullet, but
24559 no weapon of any sort was to be found in the room.
24567 \begin_layout Standard
24568 You can also use a section heading as the preface if you use a section command
24569 as \SpecialChar TeX
24571 For example the command
24574 \begin_layout Standard
24579 subsection{subsection title}
24582 \begin_layout Standard
24583 creates a subsection.
24584 In this example the preface is a subsubsection:
24587 \begin_layout Standard
24588 \begin_inset Flex Multiple Columns
24591 \begin_layout Plain Layout
24592 \begin_inset Argument 2
24595 \begin_layout Plain Layout
24599 \begin_layout Plain Layout
24608 This is a subsubsection heading as a preface
24612 \begin_layout Plain Layout
24626 A minute examination of the circumstances served only to make the case more
24628 In the first place, no reason could be given why the young man should have
24629 fastened the door upon the inside.
24630 There was the possibility that the murderer had done this, and had afterwards
24631 escaped by the window.
24632 The drop was at least twenty feet, however, and a bed of crocuses in full
24634 Neither the flowers nor the earth showed any sign of having been disturbed,
24635 nor were there any marks upon the narrow strip of grass which separated
24636 the house from the road.
24637 Apparently, therefore, it was the young man himself who had fastened the
24639 But how did he come by his death? No one could have climbed up to the window
24640 without leaving traces.
24641 Suppose a man had fired through the window, he would indeed be a remarkable
24642 shot who could with a revolver inflict so deadly a wound.
24643 Again, Park Lane is a frequented thoroughfare; there is a cab stand within
24644 a hundred yards of the house.
24645 No one had heard a shot.
24653 \begin_layout Standard
24654 If there is less vertical space than 6
24655 \begin_inset space ~
24658 text lines is left on the page at the beginning of the multiple columns,
24659 a page break will be inserted before the multiple columns.
24660 Depending on the number of lines of the preface text, you might want to
24662 This is done by setting the cursor into the mulitcolumn inset behind the
24663 preface (if there is any) and using the menu
24665 Insert\SpecialChar menuseparator
24667 \begin_inset space ~
24671 \begin_inset space ~
24675 \begin_inset space ~
24681 Insert into that inset the amount of space like e.
24682 \begin_inset space \thinspace{}
24686 \begin_inset space \space{}
24690 \begin_inset Quotes eld
24694 \begin_inset Quotes erd
24698 \begin_inset Newline newline
24701 In this example the space is set to 7
24702 \begin_inset space ~
24705 text lines by using
24706 \begin_inset Quotes eld
24712 \begin_inset Quotes erd
24721 needs to be inserted as \SpecialChar TeX
24725 \begin_layout Standard
24726 \begin_inset Flex Multiple Columns
24729 \begin_layout Plain Layout
24730 \begin_inset Argument 3
24733 \begin_layout Plain Layout
24738 \begin_layout Plain Layout
24754 On the evening of the crime, he returned from the club exactly at ten.
24755 His mother and sister were out spending the evening with a relation.
24756 The servant deposed that she heard him enter the front room on the second
24757 floor, generally used as his sitting-room.
24758 She had lit a fire there, and as it smoked she had opened the window.
24759 No sound was heard from the room until eleven-twenty, the hour of the return
24760 of Lady Maynooth and her daughter.
24761 Desiring to say good-night, she attempted to enter her son's room.
24762 The door was locked on the inside, and no answer could be got to their
24763 cries and knocking.
24764 Help was obtained, and the door forced.
24765 The unfortunate young man was found lying near the table.
24766 His head had been horribly mutilated by an expanding revolver bullet, but
24767 no weapon of any sort was to be found in the room.
24775 \begin_layout Subsubsection
24779 \begin_layout Standard
24780 The amount of space before and after multiple columns can be changed by
24781 changing the length
24788 For example the command
24791 \begin_layout Standard
24801 \begin_layout Standard
24802 in \SpecialChar TeX
24803 Code changes its value to 3
24804 \begin_inset space \thinspace{}
24808 The change must be made before the multiple columns' start.
24809 The predefined value is 13
24810 \begin_inset space \thinspace{}
24816 \begin_layout Standard
24824 \begin_inset space \thinspace{}
24830 \begin_layout Standard
24834 \begin_layout Plain Layout
24840 multicolsep}{2.5cm}
24848 \begin_layout Standard
24849 \begin_inset Flex Multiple Columns
24852 \begin_layout Plain Layout
24855 All day I turned these facts over in my mind, endeavouring to hit upon some
24856 theory which could reconcile them all, and to find that line of least resistanc
24857 e which my poor friend had declared to be the starting-point of every investigat
24859 I confess that I made little progress.
24860 In the evening I strolled across the Park, and found myself about six o'clock
24861 at the Oxford Street end of Park Lane.
24862 A group of loafers upon the pavements, all staring up at a particular window,
24863 directed me to the house which I had come to see.
24864 A tall, thin man with coloured glasses, whom I strongly suspected of being
24865 a plain-clothes detective, was pointing out some theory of his own, while
24866 the others crowded round to listen to what he said.
24867 I got as near him as I could, but his observations seemed to me to be absurd,
24868 so I withdrew again in some disgust.
24869 As I did so I struck against an elderly, deformed man, who had been behind
24870 me, and I knocked down several books which he was carrying.
24878 \begin_layout Standard
24879 \begin_inset Note Greyedout
24882 \begin_layout Plain Layout
24887 The values you set with
24893 will be used for all following multiple columns until you change them again.
24901 \begin_layout Standard
24905 \begin_layout Plain Layout
24917 \begin_inset Note Note
24920 \begin_layout Plain Layout
24921 go back to the default
24929 \begin_layout Standard
24930 \begin_inset Newpage newpage
24936 \begin_layout Subsubsection
24940 \begin_layout Standard
24941 A column break can be forced by inserting the command
24947 as \SpecialChar TeX
24948 Code to that position in the text where the column should be broken.
24949 Note that this leads in most cases to whitespace in the text.
24950 \begin_inset Newline newline
24953 Here is an example:
24956 \begin_layout Standard
24957 \begin_inset Flex Multiple Columns
24960 \begin_layout Plain Layout
24963 \begin_inset Quotes eld
24966 You're surprised to see me, sir,
24967 \begin_inset Quotes erd
24970 said he, in a strange, croaking voice.
24973 \begin_layout Plain Layout
24976 I acknowledged that I was.
24979 \begin_layout Plain Layout
24982 \begin_inset Quotes eld
24985 Well, I've a conscience, sir, and when I chanced to see you go into this
24986 house, as I came hobbling after you, I thought to myself, I'll just step
24987 in and see that kind gentleman, and tell him that if I was a bit gruff
24988 in my manner there was not any harm meant, and that I am much obliged to
24989 him for picking up my books.
24990 \begin_inset Quotes erd
24996 \begin_layout Plain Layout
24999 \begin_inset Quotes eld
25002 You make too much of a trifle,
25003 \begin_inset Quotes erd
25008 \begin_inset Quotes eld
25011 May I ask how you knew who I was?
25012 \begin_inset Quotes erd
25015 AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
25019 \begin_layout Plain Layout
25031 \begin_layout Plain Layout
25034 \begin_inset Quotes eld
25037 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25038 you'll find my little bookshop at the corner of Church Street, and very
25039 happy to see you, I am sure.
25040 Maybe you collect yourself, sir.
25044 \begin_inset space ~
25057 –a bargain, every one of them.
25058 With five volumes you could just fill that gap on that second shelf.
25059 It looks untidy, does it not, sir?
25060 \begin_inset Quotes erd
25071 \begin_layout Subsubsection
25075 \begin_layout Standard
25076 The width of the columns is automatically calculated, but you can modify
25077 the space between the columns.
25078 This is done by changing the length
25085 Its predefined value is 10
25086 \begin_inset space \thinspace{}
25090 Here is an example where
25097 \begin_inset space \thinspace{}
25103 \begin_layout Standard
25107 \begin_layout Plain Layout
25121 \begin_layout Standard
25122 \begin_inset Flex Multiple Columns
25125 \begin_layout Plain Layout
25128 My observations of No.
25129 \begin_inset space \space{}
25132 427 Park Lane did little to clear up the problem in which I was interested.
25133 The house was separated from the street by a low wall and railing, the
25134 whole not more than five feet high.
25135 It was perfectly easy, therefore, for anyone to get into the garden, but
25136 the window was entirely inaccessible, since there was no water pipe or
25137 anything which could help the most active man to climb it.
25138 More puzzled than ever, I retraced my steps to Kensington.
25139 I had not been in my study five minutes when the maid entered to say that
25140 a person desired to see me.
25141 To my astonishment it was none other than my strange old book collector,
25142 his sharp, wizened face peering out from a frame of white hair, and his
25143 precious volumes, a dozen of them at least, wedged under his right arm.
25151 \begin_layout Standard
25155 \begin_layout Plain Layout
25167 \begin_inset Note Note
25170 \begin_layout Plain Layout
25171 go back to the default
25179 \begin_layout Subsubsection
25183 \begin_layout Standard
25184 Between the columns a rule with a width of the length
25191 If this rule width is set to 0
25192 \begin_inset space \thinspace{}
25195 pt (this is the default), the rule is suppressed.
25196 In the following example the rule is 2
25197 \begin_inset space \thinspace{}
25203 \begin_layout Standard
25207 \begin_layout Plain Layout
25213 columnseprule}{2pt}
25221 \begin_layout Standard
25222 \begin_inset Flex Multiple Columns
25225 \begin_layout Plain Layout
25228 \begin_inset Quotes eld
25231 You're surprised to see me, sir,
25232 \begin_inset Quotes erd
25235 said he, in a strange, croaking voice.
25238 \begin_layout Plain Layout
25241 I acknowledged that I was.
25244 \begin_layout Plain Layout
25247 \begin_inset Quotes eld
25250 Well, I've a conscience, sir, and when I chanced to see you go into this
25251 house, as I came hobbling after you, I thought to myself, I'll just step
25252 in and see that kind gentleman, and tell him that if I was a bit gruff
25253 in my manner there was not any harm meant, and that I am much obliged to
25254 him for picking up my books.
25255 \begin_inset Quotes erd
25261 \begin_layout Plain Layout
25264 \begin_inset Quotes eld
25267 You make too much of a trifle,
25268 \begin_inset Quotes erd
25273 \begin_inset Quotes eld
25276 May I ask how you knew who I was?
25277 \begin_inset Quotes erd
25283 \begin_layout Plain Layout
25286 \begin_inset Quotes eld
25289 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25290 you'll find my little bookshop at the corner of Church Street, and very
25291 happy to see you, I am sure.
25292 Maybe you collect yourself, sir.
25296 \begin_inset space ~
25309 –a bargain, every one of them.
25310 With five volumes you could just fill that gap on that second shelf.
25311 It looks untidy, does it not, sir?
25312 \begin_inset Quotes erd
25323 \begin_layout Standard
25324 \begin_inset VSpace defskip
25330 \begin_layout Standard
25331 The rule can be colored by redefining the command
25338 This is done by inserting the command
25339 \begin_inset Newline newline
25348 columnseprulecolor}{
25353 \begin_inset Newline newline
25356 as \SpecialChar TeX
25357 Code before the multicolumn inset.
25362 in this command by a color of your choice.
25363 You can use all pre- and self-defined colors.
25371 \begin_inset space ~
25376 for more information about pre- and self-defined colors.
25377 To go back to the default color insert the command
25378 \begin_inset Newline newline
25387 columnseprulecolor}{
25392 \begin_inset Newline newline
25395 Here is the example with a cyan rule and 1
25396 \begin_inset space \thinspace{}
25399 cm column separation:
25402 \begin_layout Standard
25406 \begin_layout Plain Layout
25415 \begin_layout Plain Layout
25421 columnseprulecolor}{
25431 \begin_layout Standard
25432 \begin_inset Flex Multiple Columns
25435 \begin_layout Plain Layout
25438 \begin_inset Quotes eld
25441 You're surprised to see me, sir,
25442 \begin_inset Quotes erd
25445 said he, in a strange, croaking voice.
25448 \begin_layout Plain Layout
25451 I acknowledged that I was.
25454 \begin_layout Plain Layout
25457 \begin_inset Quotes eld
25460 Well, I've a conscience, sir, and when I chanced to see you go into this
25461 house, as I came hobbling after you, I thought to myself, I'll just step
25462 in and see that kind gentleman, and tell him that if I was a bit gruff
25463 in my manner there was not any harm meant, and that I am much obliged to
25464 him for picking up my books.
25465 \begin_inset Quotes erd
25471 \begin_layout Plain Layout
25474 \begin_inset Quotes eld
25477 You make too much of a trifle,
25478 \begin_inset Quotes erd
25483 \begin_inset Quotes eld
25486 May I ask how you knew who I was?
25487 \begin_inset Quotes erd
25493 \begin_layout Plain Layout
25496 \begin_inset Quotes eld
25499 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25500 you'll find my little bookshop at the corner of Church Street, and very
25501 happy to see you, I am sure.
25502 Maybe you collect yourself, sir.
25506 \begin_inset space ~
25519 –a bargain, every one of them.
25520 With five volumes you could just fill that gap on that second shelf.
25521 It looks untidy, does it not, sir?
25522 \begin_inset Quotes erd
25533 \begin_layout Standard
25537 \begin_layout Plain Layout
25543 columnseprule}{0pt}
25546 \begin_layout Plain Layout
25552 columnseprulecolor}{
25560 \begin_inset Note Note
25563 \begin_layout Plain Layout
25564 go back to the default
25572 \begin_layout Section
25573 Non-standard Paragraph Shapes
25576 \begin_layout Standard
25579 as well as any other text processor uses by default rectangular paragraphs.
25580 For special cases like for example posters, invitation cards or poems you
25581 can modify the paragraph shape to one of your choice.
25582 This can be done by using the \SpecialChar LaTeX
25587 which is loaded by using in the document settings the module
25589 Custom paragraph shapes
25594 \begin_layout Subsection
25598 \begin_layout Standard
25603 provides the following shapes:
25606 \begin_layout Standard
25607 \begin_inset Tabular
25608 <lyxtabular version="3" rows="13" columns="3">
25609 <features booktabs="true" islongtable="true" longtabularalignment="center">
25610 <column alignment="center" valignment="middle" width="16col%">
25611 <column alignment="center" valignment="middle" width="40col%">
25612 <column alignment="center" valignment="middle" width="35col%">
25613 <row endhead="true">
25614 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25617 \begin_layout Plain Layout
25623 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25626 \begin_layout Plain Layout
25632 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
25635 \begin_layout Plain Layout
25643 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25646 \begin_layout Plain Layout
25652 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25655 \begin_layout Plain Layout
25656 Circle with circular hole (in the size of a CD/DVD)
25661 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25664 \begin_layout Plain Layout
25665 Cannot be scaled, take care there is not too much text
25672 <cell alignment="center" valignment="top" topline="true" usebox="none">
25675 \begin_layout Plain Layout
25681 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25684 \begin_layout Plain Layout
25690 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25693 \begin_layout Plain Layout
25694 Fragile, calculation might fail
25701 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25704 \begin_layout Plain Layout
25710 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25713 \begin_layout Plain Layout
25714 Rhomboid (symbolizing a
25715 \begin_inset Quotes eld
25719 \begin_inset Quotes erd
25727 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25730 \begin_layout Plain Layout
25738 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25741 \begin_layout Plain Layout
25747 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25750 \begin_layout Plain Layout
25756 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25759 \begin_layout Plain Layout
25767 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25770 \begin_layout Plain Layout
25776 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25779 \begin_layout Plain Layout
25785 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25788 \begin_layout Plain Layout
25796 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25799 \begin_layout Plain Layout
25805 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25808 \begin_layout Plain Layout
25809 Nut for bolt (hexagon with circular hole)
25814 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25817 \begin_layout Plain Layout
25825 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25828 \begin_layout Plain Layout
25834 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25837 \begin_layout Plain Layout
25843 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25846 \begin_layout Plain Layout
25854 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25857 \begin_layout Plain Layout
25863 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25866 \begin_layout Plain Layout
25872 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
25875 \begin_layout Plain Layout
25883 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25886 \begin_layout Plain Layout
25892 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25895 \begin_layout Plain Layout
25901 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25904 \begin_layout Plain Layout
25912 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25915 \begin_layout Plain Layout
25921 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25924 \begin_layout Plain Layout
25925 Normal/reversed rain drop
25930 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25933 \begin_layout Plain Layout
25934 Fragile, calculation might fail
25941 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25944 \begin_layout Plain Layout
25951 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25954 \begin_layout Plain Layout
25955 The \SpecialChar TeX
25961 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25964 \begin_layout Plain Layout
25972 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25975 \begin_layout Plain Layout
25977 \begin_inset Newline newline
25985 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25988 \begin_layout Plain Layout
25989 Triangles in different orientations
25994 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
25997 \begin_layout Plain Layout
26011 \begin_layout Standard
26012 To use a shape for your paragraph, simply select it in \SpecialChar LyX
26014 for environments in the toolbar.
26017 \begin_layout Standard
26018 \begin_inset Newpage newpage
26024 \begin_layout Standard
26025 Here is an example paragraph in the shape of a nut:
26028 \begin_layout Standard
26029 \begin_inset VSpace bigskip
26038 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26039 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26041 At vero eos et accusam et justo duo dolores et ea rebum.
26042 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26044 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26045 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26049 \begin_layout Standard
26050 \begin_inset VSpace bigskip
26056 \begin_layout Standard
26057 \begin_inset Note Greyedout
26060 \begin_layout Plain Layout
26065 : shapepar paragraphs cannot run over a page break.
26073 \begin_layout Standard
26074 \begin_inset VSpace bigskip
26080 \begin_layout Standard
26085 takes care that the shape will always be preserved, no matter how much
26086 text is in the paragraph.
26087 Therefore the paragraph size changes with the amount of contained text.
26088 This can lead to paragraph sizes exceeding the page margins.
26089 To demonstrate the size scaling, here is the same example paragraph but
26090 with twice as much text:
26093 \begin_layout Standard
26094 \begin_inset Newpage newpage
26103 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26104 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26106 At vero eos et accusam et justo duo dolores et ea rebum.
26107 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26109 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26110 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26112 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26113 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26115 At vero eos et accusam et justo duo dolores et ea rebum.
26116 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26118 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26119 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26123 \begin_layout Standard
26124 \begin_inset VSpace bigskip
26130 \begin_layout Standard
26131 An exception is the shape
26136 It cannot be scaled because it must fit the size of a CD/DVD.
26137 Therefore the amount of text that fits into the shape is limited.
26138 \begin_inset Newline newline
26149 shape are fragile, meaning that the calculation of their size can fail,
26150 depending on the amount of text.
26151 You will then get the \SpecialChar LaTeX
26153 \begin_inset Quotes eld
26156 Arithmetic overflow
26157 \begin_inset Quotes erd
26161 In this case one can try to remove or add some text; if nothing works one
26162 has to use another shape.
26165 \begin_layout Standard
26166 \begin_inset VSpace bigskip
26172 \begin_layout Standard
26173 For shapes with tips you will maybe see that \SpecialChar LaTeX
26174 's hyphenation routine fails
26175 for text in the tips.
26176 Therefore it is often necessary to add hyphenation points
26181 arg "specialchar-insert hyphenation"
26186 ) to the corresponding text parts.
26189 \begin_layout Standard
26190 \begin_inset VSpace bigskip
26196 \begin_layout Standard
26197 Shapepar paragraphs are either always centered or placed on the page so
26198 that their left border touches the left page margin.
26199 You can therefore not use the paragraph dialog to align such paragraphs.
26200 A solution is to put the paragraph into a minipage or parbox and align
26202 The problem is hereby to find the right width for the box.
26203 Because if it is too wide and you center the box, the paragraph is not
26204 centered too because it sticks at the left side of the box.
26205 So you might have to play a bit with the width until it fits.
26206 Here are two heart-shaped paragraphs, the first one is not aligned, the
26207 second one is right-aligned:
26210 \begin_layout Standard
26211 \begin_inset Newpage newpage
26217 \begin_layout Heart
26221 Lo\SpecialChar softhyphen
26222 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26223 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26225 At vero eos et accusam et justo duo dolores et ea rebum.
26226 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26230 \begin_layout Standard
26231 \begin_inset VSpace bigskip
26237 \begin_layout Standard
26240 \begin_inset Box Frameless
26250 height_special "totalheight"
26255 backgroundcolor "none"
26258 \begin_layout Heart
26262 Lo\SpecialChar softhyphen
26263 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26264 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26266 At vero eos et accusam et justo duo dolores et ea rebum.
26267 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26276 \begin_layout Subsection
26280 \begin_layout Standard
26281 You can define any shape you want.
26282 Doing this manually is a lot of work because every coordinate must be specified.
26283 But there is a way to let the computer calculate the coordinates:
26286 \begin_layout Enumerate
26287 Install the program
26288 \begin_inset CommandInset href
26291 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
26298 \begin_layout Enumerate
26305 TeX/LaTeX\SpecialChar menuseparator
26306 Settings\SpecialChar menuseparator
26309 and select the font size you are using in your document.
26310 For example this document uses the size 12
26311 \begin_inset space \thinspace{}
26317 \begin_layout Enumerate
26321 \begin_layout Enumerate
26324 TeX/LaTeX\SpecialChar menuseparator
26327 to export the shape to coordinates.
26328 In the appearing dialog use either the outline of your shape for the coordinate
26329 s or the path itself.
26333 \begin_layout Plain Layout
26334 For more information see
26335 \begin_inset CommandInset href
26337 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
26349 \begin_layout Standard
26350 The coordinates are written into a \SpecialChar TeX
26352 To use it for your \SpecialChar LyX
26356 \begin_layout Enumerate
26357 Place the cursor before the first character of your paragraph (or into a
26361 \begin_layout Enumerate
26362 Open in \SpecialChar LyX
26365 Insert\SpecialChar menuseparator
26366 File\SpecialChar menuseparator
26368 \begin_inset space ~
26373 , select the file and use
26382 \begin_layout Standard
26383 \begin_inset VSpace defskip
26389 \begin_layout Standard
26390 \begin_inset Note Greyedout
26393 \begin_layout Plain Layout
26398 : The changed shape only applies to the current paragraph; everything is
26399 reset to normal for the next paragraph.
26400 Therefore the shape definition file must be input into every paragraph
26401 with the desired shape.
26409 \begin_layout Standard
26410 \begin_inset VSpace bigskip
26416 \begin_layout Standard
26417 Here is an example:
26420 \begin_layout Standard
26421 \begin_inset VSpace bigskip
26427 \begin_layout Standard
26428 \begin_inset CommandInset include
26430 filename "SpecialParagraphShape.tex"
26436 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26437 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26439 At vero eos et accusam et justo duo dolores et ea rebum.
26440 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26442 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26443 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26447 \begin_layout Standard
26448 \begin_inset VSpace bigskip
26454 \begin_layout Standard
26459 to draw complexer shapes in
26463 you can draw the shape in a program of your choice and import the resulting
26469 Then you only need to draw a line or spline along the outline of the image.
26472 \begin_layout Standard
26473 \begin_inset VSpace bigskip
26479 \begin_layout Standard
26482 Custom paragraph shapes
26484 also provides the two commands
26492 which can be used to define custom shapes coordinate by coordinate.
26496 \begin_layout Plain Layout
26497 These commands are internally used for all shapes described here.
26502 For information how these styles are used and about further customization
26503 possibilities, have a look at the documentation of the package
26508 \begin_inset CommandInset citation
26517 \begin_layout Bibliography
26518 \begin_inset CommandInset bibitem
26519 LatexCommand bibitem
26524 Documentation of the \SpecialChar LaTeX
26526 \begin_inset CommandInset href
26529 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
26536 \begin_layout Bibliography
26537 \begin_inset CommandInset bibitem
26538 LatexCommand bibitem
26543 Documentation of the \SpecialChar LaTeX
26545 \begin_inset CommandInset href
26548 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"