1 #LyX 2.3 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
57 \default_output_format pdf2
59 \bibtex_command default
60 \index_command default
64 \pdf_title "LyX's Additional Features manual"
65 \pdf_author "LyX Team"
66 \pdf_subject "LyX's additional features documentation"
67 \pdf_keywords "LyX, Documentation, Additional"
69 \pdf_bookmarksnumbered true
70 \pdf_bookmarksopen false
71 \pdf_bookmarksopenlevel 1
76 \pdf_pdfusetitle false
77 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
80 \use_package amsmath 1
81 \use_package amssymb 1
84 \use_package mathdots 1
85 \use_package mathtools 0
87 \use_package stackrel 0
88 \use_package stmaryrd 0
89 \use_package undertilde 0
91 \cite_engine_type default
95 \paperorientation portrait
99 \notefontcolor #0000ff
106 \paragraph_separation indent
107 \paragraph_indentation default
108 \quotes_language english
111 \paperpagestyle headings
112 \tracking_changes true
113 \output_changes false
117 \author 424524441 "rgheck"
118 \author 893223064 "John Robert Hudson" j.r.hudson@virginmedia.com
124 Additional \SpecialChar LyX
128 \begin_layout Subtitle
130 \change_inserted 424524441 1467174349
132 \change_deleted 424524441 1467174348
139 by the \SpecialChar LyX
144 \begin_layout Plain Layout
146 Principal maintainer of this file is
151 If you have comments or error corrections, please send them to the \SpecialChar LyX
154 \begin_inset Flex Code
157 \begin_layout Plain Layout
159 <lyx-docs@lists.lyx.org>
172 \begin_layout Standard
173 \begin_inset CommandInset toc
174 LatexCommand tableofcontents
181 \begin_layout Chapter
185 \begin_layout Standard
186 This manual is essentially Part II of the
188 User's Guide\SpecialChar endofsentence
191 The reason for separating the two documents is simple: the
195 is already quite lengthy, and it contains information on all of the basic
196 features one needs to know in order to prepare most documents.
197 However, the \SpecialChar LyX
198 Team has worked to make \SpecialChar LyX
199 extensible through various configuration
200 files and external packages.
201 That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
203 create a layout file (or module) for it without having to alter \SpecialChar LyX
205 We've already had contributions of several new features this way, and some
206 of them are documented here.
207 There are also some more `advanced' features, such as how to control the
208 presentation of bibliographies and how to work with multi-part documents,
209 that are not covered in the
213 and are discussed here.
216 \begin_layout Standard
217 This manual also documents some special features, like fax support, version
218 control, and SGML support, which require additional software to work properly.
219 There is also a chapter on \SpecialChar LyX
221 And lastly, there's a chapter of \SpecialChar LaTeX
222 tools and tips, things you can use to
223 spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
225 After all, \SpecialChar LyX
230 only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
234 \begin_layout Standard
235 If you haven't read the
239 yet, you are definitely in the wrong manual.
244 is the first place to go, since it describes the notation and format of
246 You should also be thoroughly familiar with the
250 and all of the basic features of \SpecialChar LyX
251 before attempting to read this one.
254 \begin_layout Standard
255 Since many of the topics in this manual depend heavily on \SpecialChar LyX
257 with \SpecialChar LaTeX
258 , this first chapter covers the inner workings of \SpecialChar LyX
261 to generate exactly the \SpecialChar LaTeX
263 It is obviously for more seasoned \SpecialChar LyX
267 \begin_layout Chapter
269 and \SpecialChar LaTeX
273 \begin_layout Section
275 Uses \SpecialChar LaTeX
279 \begin_layout Standard
280 This chapter is for both \SpecialChar TeX
281 -nicians and the \SpecialChar LaTeX
283 In it, we'll explain how \SpecialChar LyX
284 and \SpecialChar LaTeX
285 work together to produce printable output.
286 This is the only place in any of the manuals where we assume you know something
287 about \SpecialChar LaTeX
291 \begin_layout Standard
292 At one time, \SpecialChar LyX
294 \begin_inset Quotes eld
297 WYSIWYM frontend to \SpecialChar LaTeX
299 \begin_inset Quotes erd
302 but that's no longer true.
303 There are frontends to \SpecialChar LaTeX
308 \begin_layout Plain Layout
309 Some familar ones are \SpecialChar TeX
310 maker and kile, on Linux, and \SpecialChar TeX
312 There are also the \SpecialChar LaTeX
313 modes for vi and emacs, of course.
318 These are basically text editors with the ability to run \SpecialChar LaTeX
320 errors in the file you're editing.
321 Although \SpecialChar LyX
330 run \SpecialChar LaTeX
331 , and it also indicates errors in the file, it also does much, much
333 For one thing, you don't need to know \SpecialChar LaTeX
334 to use \SpecialChar LyX
337 has added its own extensions to \SpecialChar LaTeX
339 Try the following sometime: select
340 \begin_inset Flex Noun
343 \begin_layout Plain Layout
344 Export\SpecialChar menuseparator
351 \begin_inset Flex Noun
354 \begin_layout Plain Layout
361 \begin_inset Flex Noun
364 \begin_layout Plain Layout
365 View\SpecialChar menuseparator
375 ), then look at the preamble of the resulting
376 \begin_inset Flex Code
379 \begin_layout Plain Layout
386 You'll notice a variety of new macros defined specifically by \SpecialChar LyX
388 These macros are defined automatically, according to the features you use
392 \begin_layout Standard
393 There are several commands that automatically invoke \SpecialChar LaTeX
398 \begin_layout Itemize
399 \begin_inset Flex Noun
402 \begin_layout Plain Layout
403 Document\SpecialChar menuseparator
412 \begin_layout Itemize
413 \begin_inset Flex Noun
416 \begin_layout Plain Layout
417 Document\SpecialChar menuseparator
426 \begin_layout Standard
427 They will only invoke \SpecialChar LaTeX
428 if the file has changed since the last time \SpecialChar LaTeX
434 \begin_layout Standard
435 When \SpecialChar LyX
436 runs \SpecialChar LaTeX
437 on the file you're editing, it performs these steps:
440 \begin_layout Enumerate
441 Convert the document to \SpecialChar LaTeX
442 and save to a file with the extension
443 \begin_inset Flex Code
446 \begin_layout Plain Layout
453 \begin_inset Flex Code
456 \begin_layout Plain Layout
465 \begin_layout Enumerate
466 Run \SpecialChar LaTeX
468 \begin_inset Flex Code
471 \begin_layout Plain Layout
477 file (maybe several times), and run any other commands (such as
478 \begin_inset Flex Code
481 \begin_layout Plain Layout
488 \begin_inset Flex Code
491 \begin_layout Plain Layout
497 ) needed to compile the \SpecialChar LaTeX
501 \begin_layout Enumerate
502 If there are any errors, show the error log.
505 \begin_layout Standard
506 If you have run \SpecialChar LaTeX
508 \begin_inset Flex Noun
511 \begin_layout Plain Layout
512 View\SpecialChar menuseparator
519 then runs a DVI viewer to display the DVI-file.
521 \begin_inset Flex Noun
524 \begin_layout Plain Layout
525 View\SpecialChar menuseparator
532 performs further steps:
535 \begin_layout Itemize
537 \begin_inset Flex Code
540 \begin_layout Plain Layout
546 to convert the DVI file to PostScript.
549 \begin_layout Itemize
550 Run a PostScript viewer, such as
551 \begin_inset Flex Code
554 \begin_layout Plain Layout
560 , to display the PostScript file.
563 \begin_layout Standard
565 does similar things when viewing, or exporting, other formats.
568 \begin_layout Section
569 Translating \SpecialChar LaTeX
570 files into \SpecialChar LyX
574 \begin_layout Standard
575 You can import a \SpecialChar LaTeX
576 file into \SpecialChar LyX
578 \begin_inset Flex Noun
581 \begin_layout Plain Layout
582 File\SpecialChar menuseparator
583 Import\SpecialChar menuseparator
589 command in \SpecialChar LyX
591 This will call a program named
592 \begin_inset Flex Code
595 \begin_layout Plain Layout
601 which will create a file
602 \begin_inset Flex Code
605 \begin_layout Plain Layout
612 \begin_inset Flex Code
615 \begin_layout Plain Layout
623 will then open that file.
627 \begin_layout Plain Layout
628 \begin_inset Flex Code
631 \begin_layout Plain Layout
637 can also be run from the command line, of course.
645 \begin_layout Standard
646 \begin_inset Flex Code
649 \begin_layout Plain Layout
655 will translate most legal \SpecialChar LaTeX
656 , but not everything.
657 It will put things it doesn't understand into \SpecialChar TeX
658 code, so after translating
660 \begin_inset Flex Code
663 \begin_layout Plain Layout
669 , you can look for \SpecialChar TeX
670 code and hand-edit it until it looks right.
673 \begin_layout Standard
674 If you don't know what \SpecialChar TeX
675 code is, read the next section.
678 \begin_layout Section
679 \begin_inset CommandInset label
681 name "sec:Inserting-TeX-Code"
685 Inserting \SpecialChar TeX
686 Code into \SpecialChar LyX
690 \begin_layout Standard
691 Anything you can do in \SpecialChar LaTeX
692 you can do in \SpecialChar LyX
693 , for a very simple reason: You can
694 always insert \SpecialChar TeX
695 code into any \SpecialChar LyX
698 cannot, and will never be able to, display every possible \SpecialChar LaTeX
700 If ever you need to insert \SpecialChar LaTeX
701 commands into your \SpecialChar LyX
702 document, you can use the
704 \begin_inset Flex Code
707 \begin_layout Plain Layout
714 box, which you can insert into your document with
715 \begin_inset Flex Noun
718 \begin_layout Plain Layout
719 Insert\SpecialChar menuseparator
729 or the keyboard shortcut
738 \begin_layout Standard
739 Here's an example of inserting \SpecialChar LaTeX
740 commands in a \SpecialChar LyX
742 The code looks like this:
745 \begin_layout LyX-Code
749 \begin_inset Newline newline
755 \begin_inset Newline newline
758 This is an example of a minipage environment.
760 \begin_inset Newline newline
763 can put nearly everything in it, even (non-floating)
764 \begin_inset Newline newline
769 \begin_inset Newline newline
775 \begin_inset Newline newline
779 \begin_inset Newline newline
785 \begin_inset Newline newline
791 \begin_inset Newline newline
797 \begin_inset Newline newline
802 \begin_inset Newline newline
808 \begin_inset Newline newline
814 \begin_inset Newline newline
820 \begin_inset Newline newline
828 \begin_layout LyX-Code
832 \begin_layout Standard
834 \begin_inset Flex Code
837 \begin_layout Plain Layout
844 box containing this text is directly after this paragraph.
845 Those of you reading the manual in \SpecialChar LyX
846 will only see the \SpecialChar TeX
848 Those reading a printed version of the manuals will see the actual results:
849 \begin_inset VSpace bigskip
855 \begin_layout Standard
859 \begin_layout Plain Layout
866 \begin_layout Plain Layout
873 \begin_layout Plain Layout
875 This is an example of a minipage environment.
876 You can put nearly everything in it, even (non-floating) figures and tables.
880 \begin_layout Plain Layout
887 \begin_layout Plain Layout
892 \begin_layout Plain Layout
899 \begin_layout Plain Layout
906 \begin_layout Plain Layout
913 \begin_layout Plain Layout
919 \begin_layout Plain Layout
926 \begin_layout Plain Layout
933 \begin_layout Plain Layout
940 \begin_layout Plain Layout
950 \begin_inset VSpace bigskip
956 \begin_layout Standard
957 In addition to using \SpecialChar TeX
958 code, you can also create a separate file containing
959 some complex \SpecialChar LaTeX
960 structure and then use
961 \begin_inset Flex Noun
964 \begin_layout Plain Layout
965 Insert\SpecialChar menuseparator
975 to include your file (you should select the type
976 \begin_inset Flex Code
979 \begin_layout Plain Layout
986 We recommend that you only do this if you have a
987 \begin_inset Flex Code
990 \begin_layout Plain Layout
1001 Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
1005 \begin_layout Standard
1006 There are a few last points to emphasize:
1009 \begin_layout Itemize
1015 check if your \SpecialChar LaTeX
1019 \begin_layout Itemize
1020 Beware of reinventing the wheel.
1023 \begin_layout Standard
1024 On that last point, \SpecialChar LyX
1025 does have quite a few features tucked into it, and
1027 Be sure to check the manuals to make sure that \SpecialChar LyX
1028 doesn't have such-and-such
1029 feature before you decide you have to do it by hand.
1030 Moreover, there are numerous \SpecialChar LaTeX
1031 packages out there to do all sorts of things,
1032 from labels to envelopes to fancy multipage tables.
1034 \begin_inset CommandInset href
1037 target "http://www.ctan.org/"
1044 \begin_layout Standard
1045 If you do need to do some wild and fancy things within your document, be
1046 sure to check out a good \SpecialChar LaTeX
1047 book for assistance.
1048 There are a number of them listed in the bibliography of the
1055 \begin_layout Section
1057 and the \SpecialChar LaTeX
1061 \begin_layout Subsection
1062 About the \SpecialChar LaTeX
1066 \begin_layout Standard
1067 If you already know \SpecialChar LaTeX
1068 , there is no need to explain here what the preamble
1070 If you don't, the following will give you some ideas—we recommend again
1071 that you consult a \SpecialChar LaTeX
1072 book for further information.
1073 In any case, you should read the points below, because they explain what
1074 you can do and what you don't need to do in the \SpecialChar LaTeX
1075 preamble of a \SpecialChar LyX
1079 \begin_layout Standard
1080 The \SpecialChar LaTeX
1081 preamble comes at the very beginning of a document,
1089 \begin_layout Itemize
1090 Declare the document class.
1092 \begin_inset Newline newline
1096 already does this for you.
1097 If you're a seasoned \SpecialChar LaTeX
1098 -nician, and you have a custom document class you
1099 want to use, check out the
1101 Customization Manual
1103 for information on how to make \SpecialChar LyX
1107 \begin_layout Itemize
1108 Declare the usage of packages.
1110 \begin_inset Newline newline
1114 packages provide special commands, which are only available within a document
1115 when the package has been declared in the preamble.
1116 In addition to providing special commands, the inclusion of a package can
1117 change the document.
1118 For example, the package
1119 \begin_inset Flex Code
1122 \begin_layout Plain Layout
1128 forces all paragraphs to be indented.
1129 There are other packages for labels, envelopes, margins, etc.
1133 \begin_layout Itemize
1134 Set counters, variables, lengths and widths.
1136 \begin_inset Newline newline
1139 There are several \SpecialChar LaTeX
1140 counters and variables that
1144 be set globally from within the preamble in order to have the desired effect.
1145 (There are variables that you can set and reset inside the document, too.)
1146 Margins are a good example of something that must be set in the preamble.
1147 Another example is the label format for lists.
1148 You can actually set these just about anywhere, but it's best to do it
1149 just once, inside the preamble.
1152 \begin_layout Itemize
1153 Declare user defined commands (with
1154 \begin_inset Flex Code
1157 \begin_layout Plain Layout
1166 \begin_inset Flex Code
1169 \begin_layout Plain Layout
1178 \begin_inset Newline newline
1181 These are abbreviations for \SpecialChar LaTeX
1182 commands which appear very often inside a document.
1183 Although the preamble is a good place to declare such commands, they
1187 be declared anywhere (before they are used for the first time, of course).
1188 This can be useful if there is a lot of raw \SpecialChar LaTeX
1189 code in your document, which
1190 normally should not be the case.
1193 \begin_layout Standard
1195 adds its own set of definitions to the preamble of the
1196 \begin_inset Flex Code
1199 \begin_layout Plain Layout
1206 This makes \SpecialChar LaTeX
1207 files generated by \SpecialChar LyX
1211 \begin_layout Subsection
1212 Changing the Preamble
1215 \begin_layout Standard
1216 The commands which \SpecialChar LyX
1217 adds to the preamble of a \SpecialChar LaTeX
1218 file are fixed; you can't
1219 change them without patching \SpecialChar LyX
1221 You can, however, add your own stuff to the preamble by selecting
1222 \begin_inset Flex Noun
1225 \begin_layout Plain Layout
1228 \begin_inset space ~
1237 \begin_inset Flex Noun
1240 \begin_layout Plain Layout
1241 Document\SpecialChar menuseparator
1249 adds anything in the
1250 \begin_inset Flex Noun
1253 \begin_layout Plain Layout
1259 dialog to its own built-in preamble.
1260 Before adding your own declarations in the preamble, you should make sure
1261 that \SpecialChar LyX
1262 doesn't already support what you want to do.
1263 (Remember what we said about reinventing the wheel?) Also,
1265 make sure your preamble code is correct
1269 doesn't check it for you.
1270 If there is an error, you're likely to get an error like
1271 \begin_inset Quotes eld
1275 \begin_inset Flex Code
1278 \begin_layout Plain Layout
1287 \begin_inset Quotes erd
1291 If you see this error, check your preamble.
1294 \begin_layout Subsection
1298 \begin_layout Standard
1299 Here are some examples of what you can add to a preamble, and what they
1303 \begin_layout Subsubsection
1307 \begin_layout Standard
1308 There are two variables under \SpecialChar LaTeX
1309 that control page position:
1310 \begin_inset Flex Code
1313 \begin_layout Plain Layout
1322 \begin_inset Flex Code
1325 \begin_layout Plain Layout
1334 Their names should be self-explanatory.
1335 These variables are useful if you think for a moment about computer labels.
1336 Sometimes, the size of a print medium and the area of the medium that you
1337 can actually print on aren't the same.
1339 \begin_inset Flex Code
1342 \begin_layout Plain Layout
1351 \begin_inset Flex Code
1354 \begin_layout Plain Layout
1365 \begin_layout Standard
1366 The default values for
1367 \begin_inset Flex Code
1370 \begin_layout Plain Layout
1379 \begin_inset Flex Code
1382 \begin_layout Plain Layout
1391 \begin_inset space \thinspace{}
1395 \begin_inset space \thinspace{}
1399 \begin_inset space \space{}
1402 the page isn't shifted.
1403 Unfortunately, some DVI drivers always seem to shift the page.
1404 We have no idea why, or why the sysadmin hasn't fixed such behavior.
1405 If you're using \SpecialChar LyX
1406 on a system that you don't personally maintain, and your
1407 sysadmin is a doofus,
1408 \begin_inset Flex Code
1411 \begin_layout Plain Layout
1420 \begin_inset Flex Code
1423 \begin_layout Plain Layout
1432 Suppose your left and top margins are always 0.5
1433 \begin_inset space \thinspace{}
1437 You can add this to the preamble:
1440 \begin_layout LyX-Code
1448 \begin_layout LyX-Code
1456 \begin_layout Standard
1457 and your margins should now be correct.
1460 \begin_layout Subsubsection
1464 \begin_layout Standard
1465 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1466 There's a rather nice package, available at your nearest CTAN archive,
1467 for printing sheets of labels:
1468 \begin_inset Flex Code
1471 \begin_layout Plain Layout
1478 Now, your system may not have this package installed by default.
1479 We leave that up to you to check.
1480 You'll also want to read the documentation for it; we're not going to do
1482 Since this is an example, however, we'll give you an example of how you
1486 \begin_layout Standard
1487 First, make sure you're using the
1488 \begin_inset Flex Code
1491 \begin_layout Plain Layout
1498 Next, you need to put the following in your preamble:
1501 \begin_layout LyX-Code
1507 \begin_layout LyX-Code
1513 \begin_layout LyX-Code
1519 \begin_layout LyX-Code
1525 \begin_layout LyX-Code
1531 \begin_layout LyX-Code
1537 \begin_layout LyX-Code
1543 \begin_layout Standard
1544 This sets things up for Avery label sheets, stock #5360.
1545 You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1548 \begin_inset Flex Code
1551 \begin_layout Plain Layout
1560 \begin_inset Flex Code
1563 \begin_layout Plain Layout
1571 around each label text.
1572 This and other special features of
1573 \begin_inset Flex Code
1576 \begin_layout Plain Layout
1582 are explained in its documentation.
1585 \begin_layout Standard
1586 Someday, someone may write a \SpecialChar LyX
1587 layout file to support this package directly.
1588 Maybe that someone is you.
1591 \begin_layout Subsubsection
1592 Example #3: Paragraph Indentation
1595 \begin_layout Standard
1596 Americans are trained to indent the first line of
1601 As with all of their other weird quirks, most Americans will whine and
1602 moan until they can have their way and indent the first line of all paragraphs.
1611 \begin_layout Standard
1612 Of course, this behavior isn't standard typography.
1613 In books, you typically only indent the first line of a paragraph
1617 it follows another one.
1618 The idea behind indenting the first line of a paragraph is to distinguish
1619 neighboring paragraphs from one another.
1620 If there is no previous paragraph—for example, if it follows a figure or
1621 is the first paragraph in a section—then there is no need for indentation.
1625 \begin_layout Standard
1626 If you're a typical American (we're still joking!), though, you don't care
1627 about such esoteric things; you want your indentation! Add this to the
1631 \begin_layout LyX-Code
1634 usepackage{indentfirst}
1637 \begin_layout Standard
1638 If your \SpecialChar TeX
1639 distribution isn't braindead, you'll have this package, and all
1640 of your paragraphs will get the indentation the Founding Fathers intended
1644 \begin_layout Subsubsection
1645 Example #4: This Document
1648 \begin_layout Standard
1649 You can also check out the preamble of this document to get an idea of some
1650 of the advanced things you can do.
1653 \begin_layout Section
1655 and \SpecialChar LaTeX
1659 \begin_layout Standard
1660 When \SpecialChar LyX
1661 calls \SpecialChar LaTeX
1662 , it tells \SpecialChar LaTeX
1663 to blithely ignore any errors and keep going.
1664 It then uses the logfile from the \SpecialChar LaTeX
1665 run to do a post-mortem.
1666 After analyzing the logfile, \SpecialChar LyX
1667 displays a dialog listing the errors.
1668 Clicking on any one of them will take you to the position in your \SpecialChar LyX
1670 where the error occurred.
1674 \begin_layout Plain Layout
1676 Analyzing the logfile is a tough job, and \SpecialChar LyX
1677 doesn't always go to the right
1679 There are also cases where \SpecialChar LaTeX
1680 reports the error on one line, but the actual
1682 This is not unlike forgetting a closing brace in a program: You'll get
1683 an error, but only later.
1691 \begin_layout Standard
1692 Some folks also like to look at the log file directly: It is available from
1694 \begin_inset Flex Noun
1697 \begin_layout Plain Layout
1698 Document\SpecialChar menuseparator
1700 \begin_inset space ~
1709 There are some fairly common error messages and warnings.
1710 We'll cover those here.
1711 You should look at a good \SpecialChar LaTeX
1712 book for a complete listing.
1715 \begin_layout Itemize
1716 \begin_inset Flex Code
1719 \begin_layout Plain Layout
1726 \begin_inset Newline newline
1729 Anything beginning with these words is a warning message for the purpose
1731 \begin_inset Quotes eld
1735 \begin_inset Quotes erd
1738 the \SpecialChar LaTeX
1740 You'll get messages like this if you added or changed cross-references
1741 or bibliography entries, in which case, \SpecialChar LaTeX
1742 is trying to tell you that you
1743 need to make another run.
1744 You can by-and-large ignore these.
1747 \begin_layout Itemize
1748 \begin_inset Flex Code
1751 \begin_layout Plain Layout
1758 \begin_inset Newline newline
1761 Another warning message, this time about fonts which \SpecialChar LaTeX
1763 The rest of the message will often say something about a replacement font
1764 that \SpecialChar LaTeX
1766 You can safely ignore these, too.
1769 \begin_layout Itemize
1770 \begin_inset Flex Code
1773 \begin_layout Plain Layout
1782 \begin_inset Newline newline
1791 They are warnings about lines that were too long and run past the right
1793 Almost always, this is unnoticeable in the final output.
1794 (It can be just a point or two.) Or, only one or two characters extend past
1797 seems to generate at least one of these messages for just about any document
1799 \begin_inset Newline newline
1802 You can ignore these messages.
1803 Your eyes will tell you if there's a problem with something that's too
1804 wide; just look at the output.
1808 \begin_layout Plain Layout
1809 You can also enable the `draft' option in
1810 \begin_inset Flex Noun
1813 \begin_layout Plain Layout
1814 Document\SpecialChar menuseparator
1820 , and then \SpecialChar LaTeX
1821 will draw a black box in the margin of lines that are overfull.
1829 \begin_layout Itemize
1830 \begin_inset Flex Code
1833 \begin_layout Plain Layout
1842 \begin_inset Newline newline
1845 Not quite as common as its cousin.
1847 seems to like to print lines that are a bit too wide as opposed to ones
1848 that are a bit too narrow.
1849 We have no idea why.
1852 \begin_layout Itemize
1853 \begin_inset Flex Code
1856 \begin_layout Plain Layout
1865 \begin_inset Flex Code
1868 \begin_layout Plain Layout
1877 \begin_inset Newline newline
1880 Warnings about troubles breaking the page.
1881 Once again, just look at the output.
1882 Your eyes will tell you where something has gone wrong.
1885 \begin_layout Itemize
1886 \begin_inset Flex Code
1889 \begin_layout Plain Layout
1891 \begin_inset Quotes els
1895 \begin_inset Quotes ers
1904 \begin_inset Newline newline
1908 \begin_inset Quotes eld
1912 \begin_inset Quotes erd
1915 isn't installed on this system.
1916 This usually appears because some package your document needs isn't installed.
1917 If you didn't touch the preamble or didn't use the
1918 \begin_inset Flex Code
1921 \begin_layout Plain Layout
1929 command, then one of the packages \SpecialChar LyX
1930 tried to load is missing.
1932 \begin_inset Flex Noun
1935 \begin_layout Plain Layout
1936 Help\SpecialChar menuseparator
1943 to get a list of packages that \SpecialChar LyX
1945 This file is updated whenever you reconfigure \SpecialChar LyX
1947 \begin_inset Flex Noun
1950 \begin_layout Plain Layout
1951 Tools\SpecialChar menuseparator
1957 ) and tells you which packages have been detected and what they do.
1958 \begin_inset Newline newline
1962 \begin_inset Flex Code
1965 \begin_layout Plain Layout
1973 command and the package in question isn't installed, then you'll need to
1974 install it yourself.
1977 \begin_layout Itemize
1978 \begin_inset Flex Code
1981 \begin_layout Plain Layout
1982 LaTeX Error: Unknown option
1988 \begin_inset Newline newline
1991 Error messages beginning with this are trying to tell you that you specified
1992 a bad or undefined option to a package.
1993 Check the package's documentation.
1996 \begin_layout Itemize
1997 \begin_inset Flex Code
2000 \begin_layout Plain Layout
2001 Undefined control sequence
2007 \begin_inset Newline newline
2010 If you've inserted \SpecialChar LaTeX
2011 code into your document, but made a typo, you'll get
2013 You may have forgotten to load a package.
2014 In any case, this error message usually means that you used an undefined
2019 \begin_layout Standard
2020 There are other error and warning messages.
2021 Some are self-explanatory.
2022 These are usually \SpecialChar LaTeX
2024 Others are downright cryptic.
2025 These are usually \SpecialChar TeX
2026 error messages, and we really have
2030 what they mean or how to decipher them.
2034 \begin_layout Standard
2035 There's a general sequence you should follow if you get error messages:
2038 \begin_layout Enumerate
2039 Look at the \SpecialChar LaTeX
2040 code you inserted for typos.
2043 \begin_layout Enumerate
2044 If there are no typos, check that you used the command(s) correctly.
2047 \begin_layout Enumerate
2048 If you get a bunch of error boxes piled up at the very top of the document—and
2049 especially if you see a
2050 \begin_inset Quotes eld
2054 \begin_inset Flex Code
2057 \begin_layout Plain Layout
2066 \begin_inset Quotes erd
2069 error—it means that there are errors in the preamble.
2070 Start debugging your preamble.
2073 \begin_layout Enumerate
2074 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2076 document, the first suspect is your \SpecialChar LaTeX
2077 distribution itself.
2078 Check for missing packages and install them.
2081 \begin_layout Enumerate
2082 Okay, so there are no missing packages.
2083 Did you use any of the fine-tuning options in \SpecialChar LyX
2084 ? Specifically, did you
2088 any of them, like trying to manually insert lots of
2089 \begin_inset Flex Code
2092 \begin_layout Plain Layout
2094 \begin_inset space ~
2103 \begin_inset Flex Code
2106 \begin_layout Plain Layout
2113 \begin_inset Flex Code
2116 \begin_layout Plain Layout
2122 ? Did you try to kludge something together with these instead of using the
2123 appropriate paragraph environment?
2126 \begin_layout Enumerate
2127 All right, you didn't use any of the fine-tuning options, you played by
2129 Did you try to pull a fancy maneuver? Did you do something funky inside
2130 a table or an equation, like inserting a graphic into a table cell?
2133 \begin_layout Enumerate
2134 Do you have long sections of text where \SpecialChar LaTeX
2135 cannot find a place to break a
2136 line? By default, \SpecialChar LaTeX
2137 is rather strict about how much extra inter-word spacing
2138 it will add in order to break a line.
2139 Preferably, you should rework the paragraph to avoid the problem.
2142 \begin_layout Enumerate
2143 Did you go overboard with the nesting? \SpecialChar LyX
2144 (currently) doesn't check to make
2145 sure you're in the limits for nesting environments.
2146 If you nested a bunch of environments to the
2147 \begin_inset Formula $17^{\mathrm{th}}$
2150 level, that's the problem.
2151 (The limit in \SpecialChar LaTeX
2155 \begin_layout Enumerate
2156 Okay, you didn't get any error messages, but your output looks awful.
2157 If you have a table or figure that's too wide or long for the page, you
2162 \begin_layout Enumerate
2163 rescale the figure so it fits.
2166 \begin_layout Enumerate
2167 trim down the table so it fits.
2171 \begin_layout Enumerate
2172 If something else is wrong with the output, and you didn't try to pull anything
2173 fancy or kludge the fine-tuning options, we're not sure what's wrong.
2176 \begin_layout Standard
2177 If all this doesn't help—well, then
2181 you might have found a bug in \SpecialChar LyX
2186 \begin_layout Chapter
2188 \change_inserted 893223064 1464851738
2192 \begin_layout Standard
2194 \change_inserted 893223064 1464852146
2195 This section will be updated in due course.
2198 \begin_layout Standard
2199 Special Document Classes
2202 \begin_layout Section
2206 \begin_layout Standard
2212 \begin_layout Subsection
2216 \begin_layout Standard
2217 This section describes how \SpecialChar LyX
2218 can be used to write articles for submission
2219 to the scientific journal
2221 Astronomy and Astrophysics
2224 \begin_inset Flex URL
2227 \begin_layout Plain Layout
2229 http://www.edpsciences.fr/aa/
2234 ) using Version 5.01 of the document class
2239 This package can be downloaded from the ftp site
2242 \begin_layout Standard
2243 \begin_inset VSpace medskip
2249 \begin_layout Standard
2251 \begin_inset Flex URL
2254 \begin_layout Plain Layout
2256 ftp://ftp.edpsciences.org/pub/aa/readme.html
2264 \begin_layout Standard
2265 \begin_inset VSpace medskip
2271 \begin_layout Standard
2272 A manual comes together with that package, and this text is not meant to
2273 replace the original manual but is merely a short guide in how to realize
2274 the correct form of your paper.
2278 \begin_layout Standard
2279 Please note that the publisher of the journal was changed from Springer
2280 to EDP Sciences starting January 1, 2001.
2281 That change involved also some slight changes to the style files, namely
2282 the removal of the thesaurus command.
2283 The \SpecialChar LyX
2284 class aa supports the newest version of these style files, V 5.01.
2285 If you have an older version installed, please upgrade.
2286 For compatibility, the old (version 4) layout has been kept as
2291 Please refer to the comments in
2294 Dir/layouts/aapaper.layout
2299 \begin_layout Subsection
2303 \begin_layout Standard
2304 It is recommended you start from the example template distributed with \SpecialChar LyX
2306 If you are not using a template, note the following settings:
2309 \begin_layout Itemize
2316 Document\SpecialChar menuseparator
2319 dialog (OK, that one was obvious).
2322 \begin_layout Itemize
2323 Don't change the option
2326 \begin_inset space ~
2336 The whole layout is done by the macros, you shouldn't change anything.
2339 \begin_layout Subsection
2343 \begin_layout Standard
2344 First thing to enter is the header information.
2345 It consists of seven entries, of which some are optional.
2349 \begin_layout Itemize
2357 \begin_layout Itemize
2365 \begin_layout Itemize
2373 \begin_layout Itemize
2381 \begin_layout Itemize
2386 : [optional] if more than one author: whom to contact for offprint requests.
2389 \begin_layout Itemize
2394 : [optional] mail address for contacts.
2397 \begin_layout Itemize
2405 Received: <date>; Accepted <date>
2408 \begin_layout Standard
2409 There is no need to issue the
2415 command, this is done automatically by \SpecialChar LyX
2416 when the header is finished.
2417 Although the order of the single header entries doesn't matter it is advised
2418 to keep the above sequence, just to get the best optics and meets the layout
2419 of the real document.
2422 \begin_layout Standard
2423 If you want to place footnotes in the header block, e.
2424 \begin_inset space \thinspace{}
2428 \begin_inset space \space{}
2431 to state your present address, just use the standard footnote via the menu
2434 Insert\SpecialChar menuseparator
2439 will automagically use the term
2448 \begin_layout Standard
2449 In addition to these topics, the macros use three additional \SpecialChar LaTeX
2451 have no counterpart in \SpecialChar LyX
2455 \begin_layout Itemize
2462 to separate different names for more than one author and institute, respectivel
2466 \begin_layout Itemize
2473 to mark corresponding author/institute pairs.
2474 The institutes are numbered sequentially as they appear in the
2478 field, so you have to put a marker to each author.
2481 \begin_layout Itemize
2488 to supply an email address for fast contact.
2491 \begin_layout Standard
2492 In all cases, the appropriate command has to be entered in \SpecialChar LyX
2500 \begin_layout Subsection
2504 \begin_layout Standard
2505 The abstract should immediately follow the header block.
2506 With version 5 the abstract environment was changed to a command, and there
2507 is now a resctriction to only one paragraph.
2508 In addition, it should contain an entry with the keywords.
2509 This is not yet implemented for \SpecialChar LyX
2510 , therefore you have to enter the \SpecialChar LaTeX
2518 by hand and mark it as \SpecialChar LaTeX
2520 Refer to the example paper.
2523 \begin_layout Subsection
2524 Supported environments
2527 \begin_layout Standard
2528 The A&A paper layout supports the following environments for structuring
2532 \begin_layout Itemize
2538 \begin_layout Itemize
2544 \begin_layout Itemize
2550 \begin_layout Itemize
2556 \begin_layout Itemize
2562 \begin_layout Itemize
2568 \begin_layout Itemize
2574 \begin_layout Itemize
2580 \begin_layout Itemize
2586 \begin_layout Itemize
2592 \begin_layout Itemize
2598 \begin_layout Itemize
2605 \begin_layout Subsection
2606 Commands not supported by \SpecialChar LyX
2610 \begin_layout Standard
2611 Some commands are not yet supported by the
2615 layout for \SpecialChar LyX
2617 Some have already been mentioned.
2618 For the sake of completeness, they are listed all together here:
2621 \begin_layout Itemize
2629 \begin_layout Itemize
2637 \begin_layout Itemize
2645 \begin_layout Itemize
2653 \begin_layout Itemize
2661 \begin_layout Itemize
2669 \begin_layout Itemize
2677 \begin_layout Itemize
2685 \begin_layout Standard
2686 If you want to use any of these commands, you have to enter them yourself.
2689 Do not forget to mark them as \SpecialChar LaTeX
2693 \begin_layout Subsection
2694 Figure and Table Floats
2697 \begin_layout Standard
2699 provides support for the necessary float environments
2701 figure, figure*, table
2707 , therefore we won't tell much about it here.
2711 \begin_inset space ~
2717 Just remember that tables should be left-aligned.
2718 For that, select the table and change the alignment in
2720 Edit\SpecialChar menuseparator
2722 \begin_inset space ~
2728 \begin_layout Standard
2729 There is only one special thing: the figures with caption besides the figure.
2730 To create such a figure, you have to do the following:
2733 \begin_layout Enumerate
2734 Create a wide figure float:
2736 Insert\SpecialChar menuseparator
2737 Float\SpecialChar menuseparator
2740 , then right click in the figure and select
2743 \begin_inset space ~
2751 \begin_layout Enumerate
2752 Enter your caption text.
2755 \begin_layout Enumerate
2760 to move the cursor above the caption.
2763 \begin_layout Enumerate
2767 \begin_layout Enumerate
2768 Position the cursor behind the figure and insert a horizontal fill:
2770 Insert\SpecialChar menuseparator
2772 \begin_inset space ~
2775 Character\SpecialChar menuseparator
2777 \begin_inset space ~
2785 \begin_layout Enumerate
2786 Switch to \SpecialChar LaTeX
2790 \begin_inset space ~
2798 \begin_layout Enumerate
2808 Do not close the brace!
2811 \begin_layout Enumerate
2812 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
2817 \begin_inset space ~
2829 \begin_layout Standard
2830 Also, refer to the figures in the example paper.
2833 \begin_layout Subsection
2837 \begin_layout Standard
2838 For submission, the paper has to be formated in a special double-spacing
2840 For this purpose, you have to give the option
2844 to the documentclass.
2845 This must be done using the extra class options field in the
2847 Document\SpecialChar menuseparator
2851 Just enter the string
2858 \begin_layout Subsection
2862 \begin_layout Standard
2867 directory contains an example paper written with \SpecialChar LyX
2869 It is the example paper from the original macro package, translated to
2872 Use it for inspiration, and compare the original \SpecialChar LaTeX
2873 code with \SpecialChar LyX
2877 \begin_layout Section
2882 \begin_layout Standard
2888 \begin_layout Subsection
2892 \begin_layout Standard
2894 is a set of macros produced by the American Astronomical Society to
2895 facilitate electronic manuscript submission to the three journals they
2896 publish: the Astrophysical Journal (including the Letters and Supplement),
2897 the Astronomical Journal, and the Publications of the Astronomical Society
2900 has proven to be an excellent tool for generating these documents, especially
2901 given its equation, citation, and figure handling capabilities.
2903 requires version 5.0 (or higher) of these macros; preferably 5.2, which
2904 is the version described here, or higher.
2905 Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
2906 2.09 and are fundamentally
2907 incompatible with \SpecialChar LyX
2909 The AAS\SpecialChar TeX
2910 package may be downloaded from the AAS\SpecialChar TeX
2914 \begin_layout Standard
2915 \begin_inset VSpace medskip
2921 \begin_layout Standard
2923 \begin_inset Flex URL
2926 \begin_layout Plain Layout
2928 https://aas.org/aastex/aastex-downloads
2936 \begin_layout Standard
2937 \begin_inset VSpace medskip
2943 \begin_layout Standard
2944 A complete user guide is contained in that package and you should familiarize
2945 yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
2948 will not reduce the need to figure out all the AAS\SpecialChar TeX
2949 commands, it will only
2950 reduce the drudgery of typing everything in.
2951 It is your responsibility to ensure that the final exported \SpecialChar LaTeX
2953 completely to the requirements of the journal to which you are submitting
2957 \begin_layout Subsection
2958 Starting a New Paper
2961 \begin_layout Standard
2962 I strongly suggest that you start with the AAS\SpecialChar TeX
2966 File\SpecialChar menuseparator
2973 , enter the new file name, then choose the
2978 This will show the most common fields found in a manuscript.
2979 Simply overwrite the existing text (including the brackets,
2983 ) with the correct information.
2984 Many of the AAS\SpecialChar TeX
2985 commands and environments can be implemented directly in
2987 , but some cannot: most noticeably
2999 , which should stick out like a sore thumb if you actually just opened the
3001 For commands such as these, the \SpecialChar LaTeX
3002 code must be entered directly and marked
3004 Such commands are referred to as \SpecialChar TeX
3005 code, or Evil Red Text.
3006 I tried to minimize the amount of \SpecialChar TeX
3007 code needed in an AAS\SpecialChar TeX
3009 there is still a bit more required than any of us would like.
3012 \begin_layout Subsection
3013 Finishing Your Paper
3016 \begin_layout Standard
3017 When the paper is finished to your satisfaction and previews/prints correctly,
3019 \begin_inset Quotes eld
3023 \begin_inset Quotes erd
3026 actions which need to be done before you submit it to the journals.
3030 \begin_layout Enumerate
3031 Export your paper as a \SpecialChar LaTeX
3034 File\SpecialChar menuseparator
3035 Export\SpecialChar menuseparator
3043 \begin_layout Enumerate
3048 file with your favorite text editor
3052 \begin_layout Enumerate
3053 remove the comment lines before the
3062 \begin_layout Enumerate
3067 usepackage...{fontenc}
3069 line if it appears (usually just after
3084 \begin_layout Enumerate
3085 remove everything between (and including) the
3097 commands, except for any commands you specifically put into the \SpecialChar LaTeX
3099 (which should appear immediately after the
3100 \begin_inset Quotes eld
3103 User specified \SpecialChar LaTeX
3105 \begin_inset Quotes erd
3116 \begin_layout Enumerate
3117 Run the resulting file through \SpecialChar LaTeX
3118 to make sure it still processes correctly.
3121 \begin_layout Enumerate
3122 Reread the journal requirements to make sure your filenames and formats
3126 \begin_layout Enumerate
3130 \begin_layout Subsection
3131 Comments On Specific Commands
3134 \begin_layout Standard
3135 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
3142 ) gives a good description of each.
3143 Thus it's probably easiest for me to go down the list as found in the guide
3144 and offer comments where necessary.
3145 So let's begin \SpecialChar ldots
3149 \begin_layout Subsubsection
3150 Things that work as expected
3153 \begin_layout Standard
3154 Because they work as you might expect, I simply list them and the section
3255 begin{thebibliography}
3263 (2.13.2), all the cite commands and their variations (2.13.2), the generic
3264 graphicx figure commands (2.14.1),
3288 (2.15.4, amongst other places),
3315 \begin_layout Standard
3316 The following style options also work correctly:
3337 Simply put them in the
3343 Layout\SpecialChar menuseparator
3349 \begin_layout Subsubsection
3350 Things that work, but require more comment
3353 \begin_layout Standard
3354 The following items work, but require a little more discussion:
3357 \begin_layout Itemize
3358 These items are reserved for use by the journal editors, but you can put
3359 them into the \SpecialChar LaTeX
3360 preamble if you feel compelled to do so:
3393 \begin_layout Itemize
3394 These items may be placed in the \SpecialChar LaTeX
3395 preamble, and are included as blanks in
3417 \begin_layout Itemize
3424 (2.3) – can only be used
3425 \begin_inset Quotes eld
3429 \begin_inset Quotes erd
3432 , not in the middle of a paragraph.
3433 Use \SpecialChar TeX
3434 code if you need to embed it.
3437 \begin_layout Itemize
3444 (2.3) – will have extra {} after it.
3445 This should not cause an error.
3448 \begin_layout Itemize
3455 (2.6) – can only be used
3456 \begin_inset Quotes eld
3460 \begin_inset Quotes erd
3463 , not in the middle of a paragraph.
3464 Use \SpecialChar TeX
3465 code if you need to embed it.
3468 \begin_layout Itemize
3475 (2.8) – can't insert a cross-reference tag, you must type the tag name by
3479 \begin_layout Itemize
3493 \begin_layout Itemize
3500 (2.9) – will have extra {} after it.
3501 This should not cause an error.
3504 \begin_layout Itemize
3511 (2.11) – will have extra {} after it.
3512 This should not cause an error.
3515 \begin_layout Itemize
3522 (2.14.2) – you can insert an optional filename argument by placing the cursor
3523 at the beginning of the text and selecting
3525 Insert\SpecialChar menuseparator
3530 \begin_inset Quotes eld
3534 \begin_inset Quotes erd
3537 inserts an optional argument of the type needed by
3544 Hopefully it will be renamed someday.
3547 \begin_layout Itemize
3560 for the catalog ID optional parameter
3563 \begin_layout Itemize
3576 for the catalog ID optional parameter
3579 \begin_layout Subsubsection
3580 Things not implemented, use \SpecialChar TeX
3584 \begin_layout Standard
3607 setcounter{equation}
3609 (2.12), Journal name abbreviations (2.13.4),
3645 (2.15.4, insert it as the first element in the lefthand cell after where
3647 Don't use any of \SpecialChar LyX
3648 's rules in the table),
3660 (2.15.5), much of Misc (2.17, except
3711 \begin_layout Subsubsection
3712 Things that cannot be implemented
3715 \begin_layout Standard
3717 at least in any meaningful sort of way, so I suggest ignoring them.
3718 They are the references environment (2.13.3), and the deluxetable environment
3720 If you really, really need to use deluxetable, I suggest editing it in
3721 a separate file with a text editor, then using
3723 Insert\SpecialChar menuseparator
3725 \begin_inset space ~
3730 to include it in your \SpecialChar LyX
3736 file to see an example of this.
3739 \begin_layout Subsection
3740 FAQs, Tips, Tricks, and Other Ruminations
3743 \begin_layout Subsubsection
3744 Getting \SpecialChar LyX
3745 and AAS\SpecialChar TeX
3749 \begin_layout Standard
3750 It can be a bit tricky to get \SpecialChar LyX
3751 to recognize a new layout and document class.
3752 When all else fails, do this:
3755 \begin_layout Enumerate
3756 Make certain that \SpecialChar LaTeX
3757 can find AAS\SpecialChar TeX
3759 Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
3761 directory completely unrelated to \SpecialChar LaTeX
3762 or AAS\SpecialChar TeX
3763 and run \SpecialChar LaTeX
3771 \begin_layout Enumerate
3776 appears in \SpecialChar LyX
3784 \begin_layout Enumerate
3787 Tools\SpecialChar menuseparator
3791 , then restart \SpecialChar LyX
3795 \begin_layout Enumerate
3796 Open a regular new file, not from a template.
3797 Does AAS\SpecialChar TeX
3798 appear in the class list in
3800 Document\SpecialChar menuseparator
3806 \begin_layout Standard
3807 If you get a warning from an existing AAS\SpecialChar TeX
3808 document about not being able
3809 to find the AAS\SpecialChar TeX
3810 layout or a message about
3811 \begin_inset Quotes eld
3814 You should not mix title layouts with normal ones
3815 \begin_inset Quotes erd
3818 , things haven't been installed correctly.
3821 \begin_layout Subsubsection
3823 error processing a table
3826 \begin_layout Standard
3828 , by default, attempts to center the table caption/title.
3829 This seems to produce a bad interaction in AAS\SpecialChar TeX
3830 so you should click somewhere
3831 in the caption/title, then select
3833 Edit\SpecialChar menuseparator
3835 \begin_inset space ~
3849 This took care of it for me.
3852 \begin_layout Subsubsection
3856 \begin_layout Standard
3857 A couple of things: 1) I have noticed some funny spacing in the reference
3858 entries in the text.
3859 When you enter the bibliography item data, make sure their is
3863 space between the last author and the parenthesis setting off the year;
3867 \begin_inset space \thinspace{}
3871 \begin_inset space \space{}
3885 2) Entering the references at all is not obvious.
3886 The easiest thing is to start typing your first reference at the end of
3887 the document, then mark it as type
3892 That will put a small gray box in front of what you just typed.
3893 Click on the box to fill in the rest of the information.
3894 For new references, go to the end of an existing reference and press return.
3895 That will create a new line with its own box, etc.
3898 \begin_layout Subsubsection
3902 \begin_layout Standard
3903 Even though AAS\SpecialChar TeX
3904 provides its own figure commands (
3910 , for example), I much prefer \SpecialChar LaTeX
3911 's standard figure commands (with the default
3920 \begin_inset space ~
3923 commands as \SpecialChar TeX
3924 code into a Figure Float box if you desire, but I never have
3925 much luck getting the layout right.
3926 With the standard graphics, \SpecialChar LyX
3931 usepackage{graphicx}
3933 command into the \SpecialChar LaTeX
3934 preamble and handle the figures in the standard \SpecialChar LaTeX2e
3936 interspersing the figures in the text.
3937 I believe ApJ accepts figures exactly this way now; AJ might still use
3939 \begin_inset Quotes eld
3942 stack everything at the end
3943 \begin_inset Quotes erd
3949 \begin_layout Subsubsection
3950 Things I could have done, but didn't
3953 \begin_layout Standard
3955 \begin_inset Quotes eld
3959 \begin_inset Quotes erd
3962 things I could have implemented, but chose not to.
3963 For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
3965 even though it is double-spaced in the paper manuscript.
3966 Also, I chose not to make separate layouts for the preprint and preprint2
3968 Since I assume you will spend most of your time in the plain manuscript
3969 mode anyway, I decided not to chew up more disk space with this.
3973 \begin_layout Subsection
3977 \begin_layout Standard
3978 Your mileage may vary.
3979 I've now had papers published by both ApJ and AJ that have had 98% of the
3980 effort done in \SpecialChar LyX
3981 ; the last 2% was the \SpecialChar LaTeX
3982 post-processing and a few cleanups.
3983 I have had no trouble with the submission process, and I'm sure the journals
3984 were never aware that there might be a difference.
3985 So, go forth and publish!
3988 \begin_layout Section
3989 AMS \SpecialChar LaTeX
3993 \begin_layout Standard
4003 \begin_layout Standard
4004 \begin_inset VSpace bigskip
4010 \begin_layout Standard
4012 The AMS \SpecialChar LaTeX
4013 layouts are set up to conform to suggested styles for mathematical
4014 papers to be submitted to American Mathematical Society publications.
4015 The layouts are not tailored to a specific journal, but easily can be.
4016 You should refer to the AMS documentation for specific instructions for
4017 each journal (usually it will entail only changing a single line in the
4020 That documentation is available on the Web at
4021 \begin_inset Flex URL
4024 \begin_layout Plain Layout
4032 \begin_inset Flex URL
4035 \begin_layout Plain Layout
4037 ftp://ftp.ams.org/pub/tex/amslatex/
4043 These layouts are appropriate, and useful, for any mathematical writing.
4047 \begin_layout Standard
4048 There are two basic AMS \SpecialChar LaTeX
4052 \begin_layout Itemize
4053 amsart: The standard AMS article format.
4056 \begin_layout Itemize
4057 amsbook: the standard AMS book (really, monograph) format.
4061 \begin_layout Standard
4062 The layouts themselves contain only the minimum necessary to use the AMS
4064 They do not, in particular, contain any of the `theorem' environments used
4065 for setting theorems, lemmas, and the like.
4066 These are contained, instead, in the
4067 \begin_inset Flex Code
4070 \begin_layout Plain Layout
4076 module, which is loaded by default when you select one of the AMS classes.
4077 (It can also be used with other classes and can be removed, if you would
4078 rather use something else.) Less commonly used environments are in the
4079 \begin_inset Flex Code
4082 \begin_layout Plain Layout
4083 Theorems (AMS-Extended)
4088 module, which must be loaded manually.
4091 \begin_layout Standard
4092 By default, theorems and the like are numbered consecutively throughout
4093 the document, but this may be modified by loading the module
4094 \begin_inset Flex Code
4097 \begin_layout Plain Layout
4098 Theorems (Order by Section)
4103 or, if you are using
4104 \begin_inset Flex Code
4107 \begin_layout Plain Layout
4114 \begin_inset Flex Code
4117 \begin_layout Plain Layout
4118 Theorems (Order by Chapter)
4124 These will number the results as
4125 \begin_inset Formula $n.m$
4128 , where the first number refers to the section (or chapter) and the second
4129 refers to the total number of results so far in that section (or chapter).
4130 Many environments are also available unnumbered.
4131 These are indicated by an asterisk at the end.
4132 If you happen to want
4136 unnumbered results, the module
4137 \begin_inset Flex Code
4140 \begin_layout Plain Layout
4146 provides that option.
4149 \begin_layout Standard
4150 Note that these modules do not
4154 to be used with the AMS classes.
4155 It is perfectly possible to use the
4156 \begin_inset Flex Code
4159 \begin_layout Plain Layout
4165 module, and the others mentioned, with other classes, such as
4166 \begin_inset Flex Code
4169 \begin_layout Plain Layout
4176 \begin_inset Flex Code
4179 \begin_layout Plain Layout
4186 \begin_inset Flex Code
4189 \begin_layout Plain Layout
4198 \begin_layout Subsection
4199 What these layouts provide
4202 \begin_layout Standard
4203 There is a long list of included environments provided by these layouts.
4204 In AMS-\SpecialChar LaTeX
4205 , there is, in fact, an opportunity to define an unlimited variety
4206 of `theorem' environments.
4207 However, the AMS recommends the environments that are available in \SpecialChar LyX
4212 \begin_layout Standard
4213 The following environments—as well as the standard environments, such as
4215 \begin_inset Flex Noun
4218 \begin_layout Plain Layout
4225 \begin_inset Flex Noun
4228 \begin_layout Plain Layout
4235 \begin_inset Flex Noun
4238 \begin_layout Plain Layout
4245 \begin_inset Flex Noun
4248 \begin_layout Plain Layout
4255 \begin_inset Flex Noun
4258 \begin_layout Plain Layout
4265 \begin_inset Flex Code
4268 \begin_layout Plain Layout
4275 \begin_inset Flex Code
4278 \begin_layout Plain Layout
4287 \begin_layout Description
4288 Address This should be the author's permanent address.
4291 \begin_layout Description
4293 \begin_inset space ~
4296 Address This should be the author's temporary address at the time of submission,
4297 if different from the Address.
4300 \begin_layout Description
4301 Email Author's e-mail address
4304 \begin_layout Description
4305 URL Author's Web address, if desired.
4308 \begin_layout Description
4309 Keywords Key words or phrases used to identify specific topics discussed
4313 \begin_layout Description
4314 Subjectclass These refer to the AMS Subject Classifications, published and
4317 Mathematical Reviews
4320 These are also available online at the AMS cites listed above.
4323 \begin_layout Description
4327 \begin_layout Description
4331 \begin_layout Description
4335 \begin_layout Standard
4336 The following environments are provided by both the
4337 \begin_inset Flex Code
4340 \begin_layout Plain Layout
4347 \begin_inset Flex Code
4350 \begin_layout Plain Layout
4356 modules, in the latter case in both starred (unnumbered) and unstarred
4357 (numbered) versions.
4358 These same environments are provided only in the starred versions by the
4360 \begin_inset Flex Code
4363 \begin_layout Plain Layout
4372 \begin_layout Theorem
4373 This is typically used for the statements of major results.
4377 \begin_layout Corollary*
4378 This is used for statements which follow fairly directly from previous statement
4380 Again, these can be major results.
4385 These are smaller results needed to prove other statements.
4388 \begin_layout Proposition
4389 These are less major results which (hopefully) add to the general theory
4393 \begin_layout Conjecture
4394 These are statements provided without justification, which the author does
4395 not know how to prove, but which seem to be true (to the author, at least).
4398 \begin_layout Definition*
4399 Guess what this is for.
4400 The font is different for this environment than for the previous ones.
4404 \begin_layout Example*
4405 Used for examples illustrating proven results.
4408 \begin_layout Problem
4409 It's not really known what this is for.
4410 You should figure it out.
4413 \begin_layout Exercise*
4414 Write a description for this one.
4417 \begin_layout Remark
4418 This environment is also a type of theorem, usually a lesser sort of observation.
4421 \begin_layout Claim*
4422 Often used in the course of giving a proof of a larger result.
4426 Generally, these are used to break up long arguments, using specific instances
4432 The numbering scheme for cases is on its own, not together with other numbered
4438 At the end of this environment, a QED symbol (usually a square, but it can
4439 vary with different styles) is placed.
4440 If you want to have other environments within this one—for example, Case
4441 environments—and have the QED symbol appear only after them, then the other
4442 environments need to be nested within the proof environment.
4445 Nesting Environments
4451 for information on nesting.
4454 \begin_layout Standard
4455 And these environments are provided by
4456 \begin_inset Flex Code
4459 \begin_layout Plain Layout
4460 Theorems (AMS-Extended)
4468 \begin_layout Criterion*
4469 A required condition.
4472 \begin_layout Algorithm*
4473 A general procedure to be used.
4476 \begin_layout Axiom*
4477 This is a property or statement taken as true within the system being discussed.
4480 \begin_layout Condition*
4481 Sometimes used to state a condition assumed within the present context of
4486 Similar to a Remark.
4489 \begin_layout Notation*
4490 Used for the explanation of, yes, notation.
4493 \begin_layout Summary
4494 Do we really need to tell you?
4497 \begin_layout Acknowledgement*
4501 \begin_layout Conclusion*
4502 Sometimes used at the end of a long train of argument.
4506 Used in a way similar to Proposition, though perhaps lower on the scale.
4509 \begin_layout Standard
4510 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
4513 They need to be available on your system in order to use these environments.
4516 \begin_layout Section
4524 \begin_layout Standard
4530 \begin_layout Subsection
4534 \begin_layout Standard
4535 These are the layout files for some of the journals of the American Geophysical
4537 It is assumed that you have both the AGU's own class files and AGUplus
4538 installed (everything to be found at
4539 \begin_inset Flex URL
4542 \begin_layout Plain Layout
4544 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
4552 \begin_layout Subsection
4556 \begin_layout Standard
4566 They are still called this in the \SpecialChar LyX
4567 GUI, though their \SpecialChar LaTeX
4580 \begin_layout Standard
4581 Newly defined styles are
4618 These are mostly manuscript attributes and defined in the AGU class documentati
4622 \begin_layout Standard
4623 I suspect this is still badly incomplete.
4626 \begin_layout Subsection
4630 \begin_layout Standard
4647 \begin_layout Subsection
4651 \begin_layout Itemize
4654 Journal of Geophysical Research
4663 \begin_layout Standard
4664 Add your own, it isn't so hard! Look at the
4675 \begin_layout Subsection
4676 Bugs and things to remember
4679 \begin_layout Standard
4680 In order to use the new layouts, you must remember to do the following for
4684 \begin_layout Enumerate
4690 This can be done in the
4692 Layout\SpecialChar menuseparator
4697 Document\SpecialChar menuseparator
4701 (AGU articles are always in English, right? So
4708 \begin_layout Enumerate
4718 (Yes, this is a bug.)
4721 \begin_layout Enumerate
4722 Make sure you use the
4726 bibliography style, by entering
4730 into the second field of the Bib\SpecialChar TeX
4732 None of the standard styles will do.
4735 \begin_layout Section
4739 \begin_layout Standard
4745 \begin_layout Subsection
4749 \begin_layout Standard
4750 Broadway is for writing plays.
4751 The format is more decorative than Hollywood, and much less standardized.
4752 This format should be suitable for workshops.
4755 \begin_layout Subsection
4759 \begin_layout Standard
4760 The same as in Hollywood.
4763 \begin_layout Subsection
4767 \begin_layout Standard
4772 names as labels then cross-reference the label to insert the name.
4773 The cross-reference dialog will show the current cast of characters.
4776 \begin_layout Subsection
4777 Paper size and Margins
4780 \begin_layout Standard
4781 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
4784 \begin_layout Subsection
4788 \begin_layout Standard
4789 The following environments are available.
4790 You can use broadway.bind to get the bind keys shown at the right.
4793 \begin_layout Itemize
4797 \begin_inset Newline newline
4802 You should not have to use this, but it is here for anything that does not
4806 \begin_layout Itemize
4810 \begin_inset space \hfill{}
4814 \begin_inset Newline newline
4819 Used to describe stage setting and the action.
4820 First use of speaker names in all CAPs.
4823 \begin_layout Itemize
4827 \begin_inset space \hfill{}
4831 \begin_inset Newline newline
4836 Automatically numbered.
4837 On screen it will be arabic, but will print as Roman.
4840 \begin_layout Itemize
4844 \begin_inset space \hfill{}
4848 \begin_inset Newline newline
4858 It is just centered text.
4861 \begin_layout Itemize
4865 \begin_inset space \hfill{}
4869 \begin_inset Newline newline
4874 Not automatically numbered.
4875 You supply the number.
4876 This is because I couldn't figure out how.
4879 \begin_layout Itemize
4883 \begin_inset space \hfill{}
4887 \begin_inset Newline newline
4892 A special case of Narrative to describe the setting and action as the curtain
4896 \begin_layout Itemize
4900 \begin_inset space \hfill{}
4904 \begin_inset Newline newline
4909 The speaker's (actor's) title, centered in all CAPS.
4912 \begin_layout Itemize
4916 \begin_inset space \hfill{}
4920 \begin_inset Newline newline
4925 Instructions to the speaker.
4926 The parentheses are automatically inserted.
4927 The ( will appear on screen, but both will be in the printed play.
4928 This environment is only used within
4935 \begin_layout Itemize
4939 \begin_inset space \hfill{}
4943 \begin_inset Newline newline
4948 What the Speaker says.
4951 \begin_layout Itemize
4955 \begin_inset space \hfill{}
4959 \begin_inset Newline newline
4964 The curtain comes down.
4967 \begin_layout Itemize
4971 \begin_inset space \hfill{}
4977 \begin_layout Itemize
4981 \begin_inset space \hfill{}
4987 \begin_layout Itemize
4991 \begin_inset space \hfill{}
4997 \begin_layout Standard
5001 \begin_layout Section
5005 \begin_layout Standard
5010 can be used to type letters according to German conventions.
5011 A template file is included in
5013 .../lyx/share/templates
5015 for you to use as a starting point.
5018 \begin_layout Section
5026 \begin_layout Standard
5032 \begin_layout Subsection
5036 \begin_layout Standard
5037 This is the layout file for the European Geophysical Society journals.
5042 can be downloaded from the web site of the EGS under
5043 \begin_inset Flex URL
5046 \begin_layout Plain Layout
5056 \begin_layout Subsection
5060 \begin_layout Standard
5063 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
5071 The current layout file is unfortunately very unmodular and would benefit
5072 from using the various
5079 \begin_layout Section
5083 \begin_layout Standard
5084 See the \SpecialChar LyX
5090 It contains all infos you need.
5093 \begin_layout Section
5096 Foil\SpecialChar TeX
5100 \begin_inset CommandInset label
5109 \begin_layout Standard
5115 \begin_layout Subsection
5119 \begin_layout Standard
5120 This section describes how to use \SpecialChar LyX
5121 to make slides for overhead projectors.
5122 There are two document classes that can do this: the default slides class
5125 Foil\SpecialChar TeX
5129 This section documents the latter.
5132 \begin_layout Standard
5133 I'm going to say this again, nice and clear, so that there's no misunderstanding
5137 \begin_layout Standard
5138 \begin_inset VSpace bigskip
5144 \begin_layout Standard
5148 This section documents the class
5149 \begin_inset Quotes eld
5157 \begin_inset Quotes erd
5165 \begin_layout Standard
5166 \begin_inset VSpace bigskip
5172 \begin_layout Standard
5173 If you're looking for the documentation for
5174 \begin_inset Quotes eld
5182 \begin_inset Quotes erd
5186 \begin_inset space ~
5190 \begin_inset CommandInset ref
5192 reference "sec:slitex"
5197 If your machine doesn't have the
5205 installed, you'll probably have to use the default
5209 class, which isn't quite as good as
5214 \begin_layout Standard
5219 class is designed for use with version
5220 \begin_inset space ~
5228 class file which is now an integral part of \SpecialChar LaTeX2e
5232 \begin_layout Subsection
5236 \begin_layout Standard
5237 Obviously, to use this document class, you need to select
5248 \begin_inset space ~
5254 There are some settings in the
5257 \begin_inset space ~
5262 dialog that you should know about that are specific to this class:
5265 \begin_layout Itemize
5266 Don't change the options
5277 \begin_inset space ~
5283 They're ignored by the
5290 \begin_layout Itemize
5291 The default font size is 20
5292 \begin_inset space \thinspace{}
5295 pt with the other options being 17
5296 \begin_inset space \thinspace{}
5300 \begin_inset space \thinspace{}
5304 \begin_inset space \thinspace{}
5310 \begin_layout Itemize
5319 but all math equations are still typeset in the usual roman font.
5322 \begin_layout Itemize
5325 Foil\SpecialChar TeX
5328 supports A4 and Letter paper sizes as well as a special size for working
5330 \begin_inset space \thinspace{}
5334 It doesn't support A5, B5, legal or executive paper sizes.
5337 \begin_layout Itemize
5338 Don't bother changing the
5342 settings because they are ignored anyway.
5343 All floats appear where they are defined in the text.
5346 \begin_layout Itemize
5351 setting behaves a bit differently for this class.
5354 Foil\SpecialChar TeX
5357 provides extensive footer and header capabilities including a user-defined
5360 \begin_inset space ~
5364 \begin_inset CommandInset ref
5366 reference "sec:foilfoot"
5371 The title page is treated differently to all other pages in the document
5380 has the logo centered at the bottom of the page (if one is defined).
5381 The possible page style choices and what they do are as follows:
5385 \begin_layout Labeling
5386 \labelwidthstring MMMMMMM
5393 The final output contains no page numbers, or other headers or footers
5394 (except footnotes of course).
5398 \begin_layout Labeling
5399 \labelwidthstring MMMMMMM
5406 The final output contains page numbers centered at the bottom of the page.
5407 No other headings or footers (other than footnotes).
5410 \begin_layout Labeling
5411 \labelwidthstring MMMMMMM
5416 Page numbers in lower right corner.
5417 Additional headers and footers are also shown.
5418 This is also the default.
5421 \begin_layout Labeling
5422 \labelwidthstring MMMMMMM
5427 Gives you access to the
5431 package although its use with
5433 Foil\SpecialChar TeX
5436 is discouraged by the writer of the
5438 Foil\SpecialChar TeX
5441 package because of some potential page layout clashes.
5445 \begin_layout Subsubsection
5449 \begin_layout Standard
5450 The following options may be used in the extra class options in the
5452 Document\SpecialChar menuseparator
5458 \begin_layout Labeling
5459 \labelwidthstring MMMMMMx
5464 This sets up the page layout for 7.33
5465 \begin_inset space \thinspace{}
5469 \begin_inset space \thinspace{}
5472 in paper, which is about the same aspect ratio as a 35
5473 \begin_inset space \thinspace{}
5476 mm slide, making it a bit easier to work with this medium.
5479 \begin_layout Labeling
5480 \labelwidthstring MMMMMMx
5485 Places a rule across the page below the header on every page except the
5489 \begin_layout Labeling
5490 \labelwidthstring MMMMMMx
5495 Places a rule across the page above the footer on every page except the
5499 \begin_layout Labeling
5500 \labelwidthstring MMMMMMx
5505 This is automatically set each time you create a new
5512 Foil\SpecialChar TeX
5515 to use the dvips driver to rotate those pages that are set as landscape
5519 \begin_layout Labeling
5520 \labelwidthstring MMMMMMx
5525 Simply changes the page dimensions to those of a landscape page but doesn't
5527 Thus if you use this option you need to use an external program to rotate
5528 each page or feed your paper through your printer as landscape.
5529 Note that this option effectively reverses the roles of the
5537 environments (don't worry these are described in the next section).
5540 \begin_layout Labeling
5541 \labelwidthstring MMMMMMx
5546 Equation numbers on the left.
5549 \begin_layout Labeling
5550 \labelwidthstring MMMMMMx
5555 Flush-left equations.
5558 \begin_layout Subsection
5559 Supported Environments
5562 \begin_layout Standard
5563 Most of the environments commonly supported in other classes are also supported
5569 There are several additional environments provided by
5571 Foil\SpecialChar TeX
5574 as well as a couple added by \SpecialChar LyX
5576 The following environments are shared with other classes:
5579 \begin_layout Standard
5580 \begin_inset Flex Multiple Columns
5583 \begin_layout Itemize
5589 \begin_layout Itemize
5595 \begin_layout Itemize
5601 \begin_layout Itemize
5607 \begin_layout Itemize
5613 \begin_layout Itemize
5620 \begin_layout Itemize
5626 \begin_layout Itemize
5632 \begin_layout Itemize
5638 \begin_layout Itemize
5644 \begin_layout Itemize
5650 \begin_layout Itemize
5656 \begin_layout Itemize
5662 \begin_layout Itemize
5668 \begin_layout Itemize
5674 \begin_layout Itemize
5680 \begin_layout Itemize
5686 \begin_layout Itemize
5697 \begin_layout Standard
5698 That is, all the major environments apart from the sectioning environments.
5699 Since foils are essentially self-contained sections, with a title and body,
5702 Foil\SpecialChar TeX
5705 provides specific commands for starting new foils and these are:
5708 \begin_layout Itemize
5714 \begin_layout Itemize
5720 \begin_layout Standard
5722 also provides slightly modified versions of these two environments called:
5725 \begin_layout Itemize
5731 \begin_layout Itemize
5737 \begin_layout Standard
5738 and the differences will be explained in the next section.
5741 \begin_layout Standard
5742 Since foils are often used in presenting ideas or new theorems and such
5745 Foil\SpecialChar TeX
5748 also provides a comprehensive box of goodies for presenting them:
5751 \begin_layout Standard
5752 \begin_inset Flex Multiple Columns
5755 \begin_layout Itemize
5761 \begin_layout Itemize
5767 \begin_layout Itemize
5773 \begin_layout Itemize
5779 \begin_layout Itemize
5785 \begin_layout Itemize
5791 \begin_layout Itemize
5797 \begin_layout Itemize
5803 \begin_layout Itemize
5809 \begin_layout Itemize
5815 \begin_layout Itemize
5826 \begin_layout Standard
5827 The starred versions are unnumbered while the unstarred versions are numbered.
5828 There are also two list environments added by \SpecialChar LyX
5832 \begin_layout Itemize
5838 \begin_layout Itemize
5844 \begin_layout Standard
5847 Foil\SpecialChar TeX
5850 provides some powerful header and footer capabilities that are best set
5851 in the preamble although they may be set at any point in a document.
5852 If you want to change these settings in your document the best place to
5853 do so is at the very top of a foil, i.
5854 \begin_inset space \thinspace{}
5860 \begin_inset space \space{}
5865 straight after the foilhead.
5868 \begin_layout Standard
5869 For this purpose, the following command styles are provided [
5876 \begin_layout Standard
5877 \begin_inset Flex Multiple Columns
5880 \begin_layout Itemize
5884 \begin_inset space ~
5890 \begin_layout Itemize
5896 \begin_layout Itemize
5900 \begin_inset space ~
5906 \begin_layout Itemize
5910 \begin_inset space ~
5916 \begin_layout Itemize
5920 \begin_inset space ~
5929 \begin_layout Plain Layout
5930 \begin_inset space ~
5942 \begin_layout Standard
5943 There are also a few commands provided by
5945 Foil\SpecialChar TeX
5948 that aren't directly supported by \SpecialChar LyX
5949 but I'll tell you what they do and how
5950 to use them in section
5951 \begin_inset space ~
5955 \begin_inset CommandInset ref
5957 reference "sec:unsuppfoils"
5964 \begin_layout Subsection
5965 Building a Set of Foils
5968 \begin_layout Standard
5969 This section will give a simple introduction to using the different environments
5970 to build a set of foils.
5971 If you want to see an example set of foils, take a look at the
5975 file you find in \SpecialChar LyX
5983 \begin_layout Subsubsection
5984 Give It a Title Page
5987 \begin_layout Standard
5988 Unlike other classes that provide
6008 creates the title on a page of its own.
6009 If you leave out the
6013 environment \SpecialChar LaTeX
6014 will substitute the current date (every time you regenerate
6018 \begin_layout Subsubsection
6022 \begin_layout Standard
6023 As I mentioned earlier, there are four ways of starting a new foil.
6024 For portrait foils you should use
6033 The difference between these two environments is the amount of space between
6034 the title of the foil (the foilhead) and the body of the foil.
6037 \begin_layout Standard
6038 Landscape foils are generated using the
6047 Again the only difference is the spacing between foilhead and body.
6048 Both of the short versions have 0.5
6049 \begin_inset space ~
6052 inches less separation between the foilhead and the body.
6056 \begin_layout Standard
6057 One problem with the support for landscape foils is the requirement that
6062 driver to generate the PostScript output otherwise the foils won't be rotated.
6063 It is possible to get landscape foils even if you haven't got the
6067 driver provided you can feed your foils sideways through your printer ;-)
6070 \begin_layout Subsubsection
6071 Theorems, Lemmas, Proofs and more
6074 \begin_layout Standard
6075 Due to a small bug in \SpecialChar LyX
6076 you can't have two of the same type of these environments
6077 directly following each other.
6078 They must be separated by something.
6079 If you try, you will just be extending the previous environment as if you
6080 had merged the two environments together.
6081 So, how do you get around this problem? The simplest option is to insert
6082 some text between the two environments or add a
6087 environment between the two with just a
6088 \begin_inset Quotes eld
6096 \begin_inset Quotes erd
6100 This will force \SpecialChar LyX
6101 to produce two separate environments and hence the correct
6104 An example is provided in the example file included with the \SpecialChar LyX
6106 Remember, this problem only occurs if you are trying to place two of the
6107 same type of theorem-like environments one directly after the other.
6110 \begin_layout Subsubsection
6114 \begin_layout Standard
6115 You get all the commonly supported list styles found in other classes as
6116 well as two new ones.
6117 I'll only describe the new ones here.
6118 If you want to find out more about the other list environments check out
6124 If you intend to use itemized lists you might also want to read about the
6128 \begin_inset space ~
6132 \begin_inset space ~
6137 dialog described above in section
6138 \begin_inset space ~
6142 \begin_inset CommandInset ref
6144 reference "sec:bullet"
6151 \begin_layout Standard
6152 The two new list styles,
6160 , are designed to make it easier for you to create lists of do's and don'ts
6161 or right and wrong by providing dedicated environments that use a tick
6162 or a cross as the label of the list.
6163 These lists are in fact dedicated variants of the
6168 They do however require that you have the
6175 \begin_layout Subsubsection
6179 \begin_layout Standard
6182 Foil\SpecialChar TeX
6185 redefines the floating tables and figures so that they appear exactly where
6186 they are in the text rather than pushing them to the top of the page or
6187 to some user specified location.
6188 In fact if you change the float placement settings they are simply ignored.
6191 \begin_layout Subsubsection
6192 Page Headers and Footers
6193 \begin_inset CommandInset label
6202 \begin_layout Standard
6206 \begin_inset space ~
6215 are two commands used to control the left-footer text string.
6216 The first is meant to allow you to include a graphic logo on your foils
6218 \begin_inset Quotes eld
6223 Foil\SpecialChar TeX
6227 \begin_inset Quotes erd
6231 While the second is meant to provide a classification for the audience,
6235 \begin_inset space \thinspace{}
6241 \begin_inset space \space{}
6245 It is empty by default.
6248 \begin_layout Standard
6249 The remaining page corners can be filled by
6252 \begin_inset space ~
6257 (which defaults to page numbers),
6260 \begin_inset space ~
6268 \begin_inset space ~
6276 \begin_layout Subsection
6279 Foil\SpecialChar TeX
6283 \begin_inset CommandInset label
6285 name "sec:unsuppfoils"
6292 \begin_layout Standard
6293 All the commands mentioned below need to be set in a
6303 within another environment.
6306 \begin_layout Subsubsection
6310 \begin_layout Standard
6311 All lengths are adjusted using the
6334 should be replaced by the name given to the length you want to change and
6339 is the length value.
6340 All lengths should be specified in units of length such as inches (
6352 ) or relative to some document or font-based length such as
6362 \begin_layout Standard
6363 It's possible to change the spacing between a foilhead and the body of the
6364 foil by adjusting the length specified by
6371 For example, to make
6376 \begin_inset space \space{}
6379 in closer to their bodies put the following in the preamble:
6385 foilheadskip}{-0.5in}
6388 \begin_layout Standard
6389 The spacings around floats can be adjusted by setting these lengths:
6392 \begin_layout Labeling
6393 \labelwidthstring MMMMMMMMMMM
6400 Separation between the text and the top of the float
6403 \begin_layout Labeling
6404 \labelwidthstring MMMMMMMMMMM
6411 Separation between the float and the caption
6414 \begin_layout Labeling
6415 \labelwidthstring MMMMMMMMMMM
6422 Separation between the caption and the following text
6425 \begin_layout Labeling
6426 \labelwidthstring MMMMMMMMMMM
6433 You can make the captions narrower than the surrounding text by adjusting
6435 Best done relative to
6444 \begin_layout Standard
6445 There are also several title page related lengths that you may find useful
6446 if you have a long title or several authors:
6449 \begin_layout Labeling
6450 \labelwidthstring MMMMMMMMMMM
6457 Separation from headers to
6462 \begin_layout Labeling
6463 \labelwidthstring MMMMMMMMMMM
6481 \begin_layout Labeling
6482 \labelwidthstring MMMMMMMMMMM
6496 \begin_layout Labeling
6497 \labelwidthstring MMMMMMMMMMM
6513 \begin_layout Labeling
6514 \labelwidthstring MMMMMMMMMMM
6530 \begin_layout Standard
6531 The last length related command affects all the list environments.
6542 a list environment then all the vertical spacing between the list items
6544 Note that this is a command not a length so it doesn't require
6550 like the stuff mentioned above.
6553 \begin_layout Subsubsection
6557 \begin_layout Standard
6570 commands control whether the logo in the
6574 definition appear on a given page.
6581 in the preamble then none of the foils will have the logo on them.
6582 If you don't want the logo on a particular page place the
6588 directly after the foilhead of that page and the
6594 directly after the next foilhead.
6597 \begin_layout Standard
6598 If you decide to use the
6602 page style setting in the
6605 \begin_inset space ~
6610 dialog you should probably add
6620 to your preamble so headers and footers on landscape pages are correctly
6621 placed when rotated.
6622 This is due to some clashes between the page layouts provided by the
6633 \begin_layout Section
6634 Hollywood (Hollywood spec scripts)
6637 \begin_layout Standard
6643 \begin_layout Subsection
6647 \begin_layout Standard
6648 Getting the format of a Hollywood script right is a
6649 \begin_inset Quotes eld
6653 \begin_inset Quotes erd
6656 It is designed to make the readers focus on content and to be easy and
6657 familiar for the actors to read.
6658 Each page of a script should be one minute of film.
6659 Nothing goes in a script that you cannot see or hear on screen.
6660 The courier 12 pt font should be used throughout.
6664 \begin_layout Subsection
6668 \begin_layout Standard
6669 Speakers' lines should NEVER break in mid-sentence.
6670 If a speaker's lines continue over a page break, repeat the
6674 title followed by (Cont'd).
6677 \begin_layout Subsection
6681 \begin_layout Standard
6686 names as labels then cross-reference the label to insert the name.
6687 The cross-reference dialog will show the current cast of characters.
6688 You can use this to insert the speaker name in narratives also.
6691 \begin_layout Subsection
6692 Paper size and Margins
6695 \begin_layout Standard
6696 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
6699 \begin_layout Subsection
6703 \begin_layout Standard
6704 The following environments are available.
6705 You can use hollywood.bind to get the bind keys shown at the right.
6708 \begin_layout Itemize
6712 \begin_inset Newline newline
6717 Used where nothing else works.
6721 \begin_layout Itemize
6727 \begin_inset space \hfill{}
6735 \begin_inset Newline newline
6738 Usually followed by something like
6739 \begin_inset Quotes eld
6743 \begin_inset Quotes erd
6749 \begin_layout Itemize
6753 \begin_inset space \hfill{}
6757 \begin_inset Newline newline
6762 Introduces a new INTERIOR camera set-up.
6763 Always followed by DAY or NIGHT, or something similar to define the lighting
6765 Everthing on this line in CAPS.
6768 \begin_layout Itemize
6772 \begin_inset space \hfill{}
6776 \begin_inset Newline newline
6781 Introduces a new EXTERIOR camera set-up.
6782 Everthing on this line in CAPS.
6785 \begin_layout Itemize
6789 \begin_inset space \hfill{}
6793 \begin_inset Newline newline
6798 The character speaking.
6801 \begin_layout Itemize
6805 \begin_inset space \hfill{}
6809 \begin_inset Newline newline
6814 Instructions to the speaker.
6815 The () are automatically inserted, but only the ( will show in \SpecialChar LyX
6817 Both will be printed.
6820 \begin_layout Itemize
6824 \begin_inset space \hfill{}
6828 \begin_inset Newline newline
6840 \begin_layout Itemize
6844 \begin_inset space \hfill{}
6848 \begin_inset Newline newline
6853 Camera movement instruction.
6855 \begin_inset space \thinspace{}
6859 \begin_inset space \space{}
6865 \begin_layout Itemize
6869 \begin_inset space \hfill{}
6875 \begin_layout Itemize
6879 \begin_inset space \hfill{}
6885 \begin_layout Itemize
6889 \begin_inset space \hfill{}
6895 \begin_layout Itemize
6899 \begin_inset space \hfill{}
6905 \begin_layout Subsection
6909 \begin_layout Itemize
6913 \begin_layout Itemize
6917 \begin_layout Itemize
6919 \begin_inset space \thinspace{}
6926 \begin_layout Itemize
6931 \begin_layout Itemize
6932 PAN — camera movement
6935 \begin_layout Itemize
6936 INSERT — cut to close-up of
6939 \begin_layout Section
6943 \begin_layout Standard
6946 Panayotis Papasotiriou
6949 \begin_layout Subsection
6953 \begin_layout Standard
6954 The ijmpc package is a set of macros that facilitates electronic manuscript
6957 International Journal of Modern Physics C
6960 Similarly, the ijmpd package is for creating manuscripts to be submitted
6963 International Journal of Modern Physics D
6966 Both journals are published by World Scientific.
6967 The corresponding document classes are named
6976 These files, together with instructions for the authors, can be downloaded
6978 \begin_inset Flex URL
6981 \begin_layout Plain Layout
6983 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
6989 \begin_inset Flex URL
6992 \begin_layout Plain Layout
6994 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
7000 Both packages are modified versions of the standard
7001 \begin_inset Quotes eld
7005 \begin_inset Quotes erd
7008 package, and they are almost (but not exactly) identical.
7009 Most of their features are supported by \SpecialChar LyX
7011 I have used \SpecialChar LyX
7012 successfully to write articles submitted to both journals
7013 without any problem.
7016 \begin_layout Subsection
7020 \begin_layout Standard
7021 As usual, the easiest way to write a paper is to start with a template.
7024 File\SpecialChar menuseparator
7040 This will give an (almost) empty document that includes the most common
7041 fields found in a manuscript.
7042 Simply overwrite the existing text (including the brackets,
7047 You should keep in mind the following remarks.
7050 \begin_layout Enumerate
7052 won't let you change the font size and the page style of the document,
7053 because such modifications are not allowed by both packages.
7056 \begin_layout Enumerate
7057 The language of the document should not be changed.
7058 Before previewing your paper, be sure that the babel package is not used.
7059 To do this, click on
7061 Tools\SpecialChar menuseparator
7072 checkbox in the language settings, and click on
7080 , if you wish to make this change permanent).
7083 \begin_layout Enumerate
7085 \begin_inset Quotes eld
7089 \begin_inset Quotes erd
7092 style must be used to define keywords.
7095 \begin_layout Enumerate
7096 The ijmpc package provides a style named
7097 \begin_inset Quotes eld
7100 Classification Codes
7101 \begin_inset Quotes erd
7104 , which can be used to define classification codes, such as PACS numbers.
7105 Note that this facility is not supported by the ijmpd package.
7108 \begin_layout Enumerate
7109 Several new environments are available:
7110 \begin_inset Quotes eld
7114 \begin_inset Quotes erd
7118 \begin_inset Quotes eld
7122 \begin_inset Quotes erd
7126 \begin_inset Quotes eld
7130 \begin_inset Quotes erd
7134 \begin_inset Quotes eld
7138 \begin_inset Quotes erd
7142 \begin_inset Quotes eld
7146 \begin_inset Quotes erd
7150 \begin_inset Quotes eld
7154 \begin_inset Quotes erd
7158 \begin_inset Quotes eld
7162 \begin_inset Quotes erd
7166 \begin_inset Quotes eld
7170 \begin_inset Quotes erd
7174 \begin_inset Quotes eld
7178 \begin_inset Quotes erd
7182 \begin_inset Quotes eld
7186 \begin_inset Quotes erd
7190 \begin_inset Quotes eld
7194 \begin_inset Quotes erd
7198 \begin_inset Quotes eld
7202 \begin_inset Quotes erd
7206 \begin_inset Quotes eld
7210 \begin_inset Quotes erd
7214 \begin_inset Quotes eld
7218 \begin_inset Quotes erd
7222 Their use is more or less obvious.
7224 supports all these environments; it will use the proper label, text style,
7225 and numbering scheme for each of them.
7228 \begin_layout Enumerate
7229 Both packages use basic citations; the natbib package should not be used.
7231 , citation references are shown as usual; in the output, citations are
7232 shown as superscripts.
7233 If you want to use a citation as normal text, you should use the
7238 \begin_inset space \thinspace{}
7242 \begin_inset space \space{}
7246 \begin_inset Quotes eld
7250 \begin_inset space \space{}
7260 \begin_inset Quotes erd
7266 \begin_layout Enumerate
7268 \begin_inset Quotes eld
7272 \begin_inset Quotes erd
7275 section in both packages.
7276 To put acknowledgments, just use the
7277 \begin_inset Quotes eld
7281 \begin_inset Quotes erd
7287 \begin_layout Enumerate
7288 Appendices may be added to the paper,
7292 the Acknowledgments and
7298 provides a special environment, called
7299 \begin_inset Quotes eld
7303 \begin_inset Quotes erd
7306 which marks the beginning of the appendices.
7307 This environment should be left blank; it just sends a \SpecialChar LaTeX
7308 command, but nothing
7312 \begin_inset Quotes eld
7316 \begin_inset Quotes erd
7319 is printed with blue letters, as a signal that all sections after that
7320 point are appendices.
7321 To write an appendix, use the
7322 \begin_inset Quotes eld
7326 \begin_inset Quotes erd
7331 will number each appendix with capital letters, as required by both journals.
7333 \begin_inset Quotes eld
7337 \begin_inset Quotes erd
7344 be present before the first appendix; if not, all appendices will be numbered
7345 as normal sections in the output.
7348 \begin_layout Enumerate
7349 The ijmpc and the ijmpd packages use the
7353 command to implement table captions.
7354 As a result, a table created by \SpecialChar LyX
7355 is printed correctly, but its caption
7357 However, you can use some \SpecialChar TeX
7358 code to overcome this problem, so that captions
7359 are printed as expected.
7360 To do so, create a float table as usual, remove the caption, and replace
7361 it with the \SpecialChar TeX
7372 (sic); you must also the \SpecialChar TeX
7377 immediately after the tabular material.
7378 Study the example table included in the template files to see how this
7379 trick is implemented.
7380 Alternatively, If you need table captions, you should implement the whole
7385 file, then include this file to the \SpecialChar LyX
7388 Insert\SpecialChar menuseparator
7389 File\SpecialChar menuseparator
7391 \begin_inset space ~
7397 Details on how to create a table float can be found in the files
7405 , included in the corresponding packages.
7408 \begin_layout Subsection
7409 Preparing a paper for submission
7412 \begin_layout Standard
7413 Before you submit your paper you must export the \SpecialChar LyX
7414 document as a \SpecialChar LaTeX
7417 File\SpecialChar menuseparator
7418 Export\SpecialChar menuseparator
7426 \begin_layout Plain Layout
7427 Actually you have the choice between \SpecialChar LaTeX
7428 (plain) and pdflatex.
7429 If you intend to use pdflatex to prepare the paper, you should use the
7430 pdflatex option so that included graphics are converted to PDF format,
7431 ready for use by pdflatex.
7436 , then make the following changes to the resulting
7443 \begin_layout Enumerate
7444 Remove the comment lines before the
7453 \begin_layout Enumerate
7454 Remove everything between (and including) the
7466 commands, except for any commands you specifically put into the \SpecialChar LaTeX
7470 \begin_layout Standard
7475 file should be saved and processed through \SpecialChar LaTeX
7476 as many times as necessary.
7477 You may also want to check the resulting
7484 \begin_layout Subsection
7485 Use of \SpecialChar TeX
7489 \begin_layout Standard
7490 The use of \SpecialChar TeX
7491 code is reduced to two commands, which must be placed at the
7492 top of the document.
7493 If you started writing your paper by using the
7501 template, the \SpecialChar TeX
7502 code needed is already in its place; you usually don't need
7504 You may only modify the first \SpecialChar TeX
7505 code to specify the information printed
7506 to the top of odd and even pages (authors' names and short paper's title,
7508 This \SpecialChar TeX
7509 code must have the form
7513 markboth{Authors' Names}{Short Paper's Title}
7518 \begin_layout Section
7522 \begin_layout Standard
7528 \begin_layout Subsection
7532 \begin_layout Standard
7533 The iopart package provides a document class to create electronic manuscript
7534 submission to the journals published by the Institute of Physics.
7535 Instructions for the authors how to create a paper using the iopart class
7536 can be downloaded together with the iopart package from the site
7537 \begin_inset Flex URL
7540 \begin_layout Plain Layout
7542 ftp://ftp.iop.org/pub/journals/latex2e
7550 \begin_layout Subsection
7554 \begin_layout Standard
7555 The easiest way to write a paper is to start with the file
7559 that is available in \SpecialChar LyX
7560 's examples files folder.
7561 Open this file, save it under a new name, and start writing.
7562 The example file explains how to use the special text environments.
7563 Here are the most important advices:
7566 \begin_layout Itemize
7567 To be able to compile your document to a PDF, PS, or DVI, ensure that the
7570 Use AMS math package
7572 in the document settings under
7579 \begin_layout Itemize
7582 The title environment defines the kind of your paper.
7583 So use one of the following environments for the title:
7589 \begin_layout Itemize
7598 \begin_layout Itemize
7607 \begin_layout Itemize
7613 for a Topical review
7616 \begin_layout Itemize
7625 \begin_layout Itemize
7634 \begin_layout Itemize
7640 for a Paper (same as Title)
7643 \begin_layout Itemize
7649 for a Preliminary communication
7652 \begin_layout Itemize
7658 for a Rapid communication
7661 \begin_layout Itemize
7667 for a Letter to the editor
7671 \begin_layout Itemize
7674 All title environments except of
7678 can have an optional short title.
7681 \begin_layout Itemize
7682 There is a general title environment
7686 which is not directly supported by the \SpecialChar LyX
7688 This can be used as \SpecialChar TeX
7689 code when your document doesn't fit into one of the
7693 \begin_layout Standard
7694 For more informations like hints for special table and formula formatting,
7695 look at the IOP author guidelines.
7698 \begin_layout Section
7702 \begin_layout Standard
7705 Panayotis Papasotiriou
7708 \begin_layout Subsection
7712 \begin_layout Standard
7713 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
7714 that facilitates electronic manuscript submission to the journals they
7716 Most known of them (at least in my domain of interest) are
7718 Astrophysics and Space Science
7724 , but there are many others (see a complete list at
7725 \begin_inset Flex URL
7728 \begin_layout Plain Layout
7730 http://www.wkap.nl/jrnllist.htm/JRNLHOME
7736 The Kluwer package may be downloaded from the site
7737 \begin_inset Flex URL
7740 \begin_layout Plain Layout
7742 http://www.wkap.nl/kaphtml.htm/STYLEFILES
7748 A complete user guide is contained in that package (but it can also be
7749 downloaded separately).
7752 \begin_layout Standard
7754 supports many features of the package but not everything.
7755 However, the \SpecialChar TeX
7756 code needed is reduced to some
7757 \begin_inset Quotes eld
7761 \begin_inset Quotes erd
7764 commands of the package (see
7765 \begin_inset space ~
7769 \begin_inset CommandInset ref
7771 reference "subsec:kluwer_peculiarities"
7776 I have recently used \SpecialChar LyX
7777 to write an article submitted to the
7779 Astrophysics and Space Science
7781 without any problem.
7784 \begin_layout Subsection
7788 \begin_layout Standard
7789 The easiest way to write a paper is to start with the Kluwer template file.
7792 File\SpecialChar menuseparator
7804 This will give an (almost) empty document that includes the most common
7805 fields found in a manuscript and a short description of their use.
7806 As in most templates, simply overwrite the existing text (including the
7811 ) with the correct information.
7814 \begin_layout Subsection
7815 Preparing a paper for submission
7818 \begin_layout Standard
7819 As in the AAS\SpecialChar TeX
7820 package, before you submit your paper to a journal you must
7822 \begin_inset Quotes eld
7826 \begin_inset Quotes erd
7832 \begin_layout Enumerate
7833 Export your paper as a \SpecialChar LaTeX
7835 To do this, click on
7837 File\SpecialChar menuseparator
7838 Export\SpecialChar menuseparator
7846 \begin_layout Enumerate
7851 file with a text editor and make the following changes
7855 \begin_layout Enumerate
7856 remove the comment lines before the
7865 \begin_layout Enumerate
7866 remove everything between (and including) the
7878 commands, except for any commands you specifically put into the \SpecialChar LaTeX
7882 \begin_layout Standard
7891 \begin_layout Enumerate
7896 file through \SpecialChar LaTeX
7897 as many times as necessary (usually up to three).
7900 \begin_layout Enumerate
7906 \begin_inset space \thinspace{}
7910 \begin_inset space \space{}
7917 , and check if everything is OK (it should, if you didn't make any mistake).
7920 \begin_layout Subsection
7921 \begin_inset Quotes eld
7925 \begin_inset Quotes erd
7928 of the Kluwer package
7929 \begin_inset CommandInset label
7931 name "subsec:kluwer_peculiarities"
7938 \begin_layout Standard
7939 The Kluwer package has the following
7940 \begin_inset Quotes eld
7944 \begin_inset Quotes erd
7950 \begin_layout Enumerate
7951 It is possible to write multiple articles in the same \SpecialChar LaTeX
7956 \begin_layout Plain Layout
7957 I can't imagine any good reason to do this.
7963 Each article must be included in the environment
7964 \begin_inset Quotes eld
7968 \begin_inset Quotes erd
7972 Unfortunately, this environment cannot be omitted, even if you write just
7974 Therefore, each article starts with the command
7980 and, obviously, ends with the command
7987 Although this can be implemented in \SpecialChar LyX
7988 , I didn't included it, since it looks
7989 ugly and can confuse the novice user.
7990 Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
7993 \begin_inset Quotes eld
7998 \begin_inset Quotes erd
8004 \begin_layout Enumerate
8005 Information given at the beginning of the article (i.
8006 \begin_inset space \thinspace{}
8010 \begin_inset space \space{}
8013 title, subtitle, author, institution, running title, running author, abstract
8014 and keywords) must be included in an environment called
8015 \begin_inset Quotes eld
8019 \begin_inset Quotes erd
8023 This is not implemented in \SpecialChar LyX
8024 , so you must enter title, subtitle etc.
8025 \begin_inset space ~
8028 between two \SpecialChar TeX
8044 \begin_layout Enumerate
8045 According to the user manual, the label of each bibliography item must be
8069 \begin_layout Standard
8074 template takes care of all these
8075 \begin_inset Quotes eld
8079 \begin_inset Quotes erd
8083 If you start a new paper using this template you don't need to do anything
8088 \begin_layout Enumerate
8089 don't delete the \SpecialChar TeX
8090 code included in the template, and
8093 \begin_layout Enumerate
8094 copy the example bibliography item included in the template and modify it
8095 as necessary to enter new bibliography items.
8098 \begin_layout Section
8102 \begin_layout Standard
8108 \begin_layout Subsection
8112 \begin_layout Standard
8113 The \SpecialChar LyX
8116 article (koma-script)
8120 report (koma-script)
8138 correspond to the \SpecialChar LaTeX
8156 \begin_inset space ~
8159 of the Koma-Script family.
8160 They are replacements for the standard document classes
8176 , resp., and fit better to European typography conventions in a number of
8180 \begin_layout Itemize
8181 Standard character size is 11pt in
8183 article (koma-script)
8187 report (koma-script)
8195 letter (koma-script)
8200 \begin_layout Itemize
8201 Headings, labels of the description environment, and a number of elements
8204 letter (koma-script)
8206 document class are set in a bold sans serif font.
8210 \begin_layout Plain Layout
8211 There is a big difference between the bold sans serif old cm fonts and new
8212 ec fonts, especially in the appearance of headings.
8213 In comparison, the ec bold sans serif fonts look a bit thin.
8214 Here the \SpecialChar LaTeX
8223 helps to produce the
8224 \begin_inset Quotes eld
8228 \begin_inset Quotes erd
8231 appearance when using the ec fonts.
8236 The numbering of chapter headings is made in the same way as the numbering
8237 of section headings, that is without the extra line
8238 \begin_inset Quotes eld
8241 Chapter\SpecialChar ldots
8243 \begin_inset Quotes erd
8247 In addition, the appearance of the headings can be modified by using a
8248 number of options (in \SpecialChar LyX
8249 to be entered in the field
8252 \begin_inset space ~
8259 Layout\SpecialChar menuseparator
8266 \begin_layout Itemize
8267 The main means in the Koma-Script document classes to design the type area
8276 (in \SpecialChar LyX
8277 to be entered in the extra class options field in the dialog
8279 Document\SpecialChar menuseparator
8283 They make a clearer modification of page margins possible as do the options
8286 Document\SpecialChar menuseparator
8293 \begin_layout Itemize
8294 The \SpecialChar LaTeX
8295 document classes of the Koma-Script family define a number of additional
8297 Those part of it which makes sense in \SpecialChar LyX
8298 is implemented in corresponding
8302 \begin_layout Standard
8303 Detailed descriptions of the \SpecialChar LaTeX
8304 document classes of the Koma-Script family
8305 can be found in the Koma-Script documentation
8316 \begin_layout Subsection
8317 article (koma-script), report (koma-script), and book (koma-script)
8320 \begin_layout Standard
8321 The document classes
8323 article (koma-script)
8327 report (koma-script)
8337 are implemented in the layout files
8350 They contain all the paragraph types of the corresponding standard document
8363 , resp., partly modified, with the exception of the \SpecialChar LyX
8368 -type, which is replaced by the new
8372 -type having the same functionality.
8377 -Type there is a number of new paragraph types added.
8384 letter (koma-script)
8389 \begin_layout Itemize
8398 : are equivalents to
8406 , resp., additionally inserting an entry in the table of contents.
8415 are not contained in
8417 article (koma-script)
8422 \begin_layout Itemize
8439 , resp., additionally clearing running heads.
8446 article (koma-script)
8452 \begin_layout Plain Layout
8465 report (koma-script)
8467 , but since this is identical to
8471 , is has not been implemented in \SpecialChar LyX
8480 \begin_layout Itemize
8485 : generates a heading directly above the following paragraph in the standard
8486 character size without affecting the structure of the document.
8489 \begin_layout Itemize
8498 are special captions which respect the different space settings needed
8499 for captions placed above or below an element (if you follow strict typographic
8500 rules, you might want to place table captions always above the table).
8501 You can also use the class option
8518 You need at least Koma-Script version 2.8q to use this.
8521 \begin_layout Itemize
8526 : can be used to set a bonmot, e.
8527 \begin_inset space \thinspace{}
8531 \begin_inset space \space{}
8534 at the beginning of a chapter.
8535 If you use the optional argument (
8537 Insert\SpecialChar menuseparator
8539 \begin_inset space ~
8544 ), you can insert the dictum's author there.
8545 Dictum and author are separated by a line.
8546 You need at least Koma-Script version 2.8q to use this.
8553 article (koma-script)
8558 \begin_layout Standard
8559 The following types, together with the standard types
8571 , form the title area of the document.
8572 They must be entered ahead of the first
8573 \begin_inset Quotes eld
8577 \begin_inset Quotes erd
8584 \begin_layout Plain Layout
8585 The corresponding \SpecialChar LaTeX
8586 commands must appear before the
8597 When such a type is used more than once, the latter usage overwrites the
8598 former one, that means, for every type only the latest usage is valid.
8599 The order of the different types however has, like
8611 , no effect on the appearance of the produced document.
8614 \begin_layout Itemize
8619 : produces a centered paragraph above the ordinary title (
8631 ) for the subject of the document.
8634 \begin_layout Itemize
8639 : produces a centered paragraph below the ordinary title (
8651 ) for the publishers' name.
8654 \begin_layout Itemize
8661 report (koma-script)
8667 produces a centered paragraph on its own page behind the title page, or
8670 article (koma-script)
8672 produces a centered paragraph below the ordinary title (
8691 \begin_layout Itemize
8696 : produces a left aligned paragraph above the ordinary title (
8712 ) for a document`s head.
8715 \begin_layout Itemize
8720 : produces in a double-sided print in
8722 report (koma-script)
8728 a left-aligned paragraph at the top of the title page`s back or has no
8729 effect in a single-sided print or in
8731 article (koma-script)
8736 \begin_layout Itemize
8741 : produces in a double-sided print in
8743 report (koma-script)
8749 a left-aligned paragraph at the bottom of the title page`s back or has
8750 no effect in a single-sided print or in
8752 article (koma-script)
8757 \begin_layout Itemize
8762 : produces a special
8763 \begin_inset Quotes eld
8767 \begin_inset Quotes erd
8770 page ahead of the actual document containing a paragraph without special
8774 \begin_layout Standard
8775 The layout files for the document classes
8777 article (koma-script)
8781 report (koma-script)
8792 This is thought of as a place to define your own types.
8797 in your personal layout directory and edit the file!
8800 \begin_layout Subsection
8801 letter (koma-script)
8804 \begin_layout Standard
8808 letter (koma-script)
8810 is implemented in the layout file
8815 It contains all the paragraph types of the corresponding standard document
8820 , partly modified, with the exception of the \SpecialChar LyX
8834 type, which is replaced by the new
8839 In addition, it contains, in contrast to the standard document class, the
8858 Furthermore, there are a number of new letter specific types.
8861 \begin_layout Standard
8862 The appearance of the letter produced by this document class can be controlled
8863 by a number of \SpecialChar LaTeX
8864 commands, which you can put in the \SpecialChar LaTeX
8869 \begin_layout Plain Layout
8870 For example, the standard appearance of the letter`s heading, consisting
8871 of name and address, is quite self-willed.
8873 \begin_inset Quotes eld
8877 \begin_inset Quotes erd
8880 heading is produced by the following \SpecialChar LaTeX
8881 commands in the preamble:
8884 \begin_layout LyX-Code
8894 \begin_layout LyX-Code
8910 \begin_layout LyX-Code
8920 \begin_layout LyX-Code
8940 A detailed German description of such \SpecialChar LaTeX
8941 commands can be found in the Koma-Script
8947 With it, the letter's author can produce his personal letter layout.
8950 \begin_layout Standard
8959 define the beginning of the letter and must be used in every letter.
8960 To emphasize them in the \SpecialChar LyX
8961 document class, they are marked with the letter
8971 \begin_inset space ~
8975 It is possible to write any number of letters in one file.
8980 type produces a new letter using the same addressee and a
8984 type produces a new addressee.
9001 are ordinary paragraph types and can also be used several times in one
9002 and the same letter.
9005 \begin_layout Itemize
9010 : produces a paragraph for the addressee and implicitly defines the beginning
9014 \begin_layout Itemize
9019 : produces a paragraph for the form of address and implicitly produces a
9023 \begin_layout Itemize
9028 : produces a paragraph for a close.
9031 \begin_layout Itemize
9036 : produces a paragraph for a postscript.
9039 \begin_layout Itemize
9044 : produces a paragraph for a distribution list.
9047 \begin_layout Itemize
9052 : produces a paragraph for enclosures.
9055 \begin_layout Standard
9096 are input types provided with a label to enter information, which will
9097 be processed by the document class.
9101 \begin_layout Plain Layout
9102 It could be seen as a matter of inconsequence, that the types
9110 described above are not such input types as well.
9111 Because of the special meaning of those types, however, I have implemented
9112 them as ordinary paragraph types with a one letter mark in the left margin.
9113 Moreover, it would affect my feeling of symmetry, if the
9121 type had such a serious different appearance.
9126 The types must be used ahead of the corresponding
9133 \begin_layout Standard
9134 An implementation of these types in a WYSIWYG fashion does not seem to make
9135 sense, because the real appearance of the produced letter does not only
9136 depend on the usage of the particular type, but also on other factors.
9137 For example, a signature entered in the
9141 type will in the standard behavior appear in the produced letter only,
9142 when in the same letter also a
9147 The entered value of the
9151 type will in the standard behavior not appear in the produced letter at
9153 The possibility to design the letter`s heading freely is already indicated
9154 in a footnote above.
9157 \begin_layout Standard
9158 The input types can also be used as empty paragraphs.
9160 \begin_inset space \thinspace{}
9164 \begin_inset space \space{}
9176 type is not used at all, in the standard behavior the value of the
9180 type is used as signature, whereas if an empty
9184 type is used, no signature value is defined.
9187 \begin_layout Standard
9188 By using the input types it is possible to write a letter template, containing
9189 filled input types with your personal dates (name, address, etc.) and empty
9190 input types for other dates you want to enter.
9193 \begin_layout Itemize
9198 : sender's name, in the standard behavior appears as a centered paragraph
9199 in small caps in the letter`s heading.
9202 \begin_layout Itemize
9207 : sender's signature, in the standard behavior appears below the
9216 type is used, the value of the
9220 type appears instead.
9223 \begin_layout Itemize
9228 : sender's address, in the standard behavior appears in a centered paragraph
9229 in the letter`s heading below the sender's name.
9232 \begin_layout Itemize
9237 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
9248 \begin_layout Itemize
9253 : place of the letter`s making.
9256 \begin_layout Itemize
9261 : date of the letter`s making.
9270 , in the standard behavior, produce the place and the date in a right-aligned
9271 line below the addressee's field.
9276 type is used, neither place nor date appear, independent of the value of
9286 type is used, the date of the letter `s production is used.
9289 \begin_layout Itemize
9294 : sender`s back address, in the standard behavior appears above the addressee's
9295 field in a small sans serif font.
9298 \begin_layout Itemize
9303 : special mail information, in the standard behavior appears underlined
9304 above the addressee's field below the back address.
9307 \begin_layout Itemize
9312 : additional information, in the standard behavior appears on right side
9313 below the addressee`s field.
9316 \begin_layout Itemize
9321 : the letter's title, in the standard behavior appears in a big, bold, sans
9322 serif font above the subject.
9325 \begin_layout Itemize
9330 : the letter's subject, in the standard behavior appears in a bold font
9338 \begin_layout Standard
9359 produce a business letter like line above the
9363 line containing the fields
9364 \begin_inset Quotes eld
9368 \begin_inset Quotes erd
9372 \begin_inset Quotes eld
9376 \begin_inset Quotes erd
9380 \begin_inset Quotes eld
9384 \begin_inset Quotes erd
9388 \begin_inset Quotes eld
9392 \begin_inset Quotes erd
9396 \begin_inset Quotes eld
9400 \begin_inset Quotes erd
9404 \begin_inset Quotes eld
9408 \begin_inset Quotes erd
9412 For the date field, the value of the
9418 \begin_inset Quotes eld
9421 business letter types
9422 \begin_inset Quotes erd
9425 is used, the value of the
9429 type however does not appear, but only the \SpecialChar LaTeX
9437 The ordinary output of place and date in a right-aligned line below the
9438 addressee`s field is suppressed.
9439 The types are implemented as input types provided with a label and must
9440 be used ahead of the corresponding
9447 \begin_layout Itemize
9455 \begin_layout Itemize
9463 \begin_layout Itemize
9471 \begin_layout Itemize
9479 \begin_layout Itemize
9487 \begin_layout Subsection
9488 The new letter class: letter (koma-script v.2)
9491 \begin_layout Standard
9497 \begin_layout Standard
9498 \begin_inset VSpace medskip
9504 \begin_layout Standard
9506 Koma-Script version 2.8 has introduced a new letter class
9510 which supersedes the now unsupported
9515 It has — on the \SpecialChar LaTeX
9516 side — a completely new interface and is not compatible
9518 Therefore, \SpecialChar LyX
9519 supports both, though it is recommended you use the new class.
9522 \begin_layout Standard
9523 This class covers the same functionality as
9525 letter (koma-script),
9532 (receiver's address, same as
9549 will start a new letter (i.
9550 \begin_inset space \thinspace{}
9554 \begin_inset space \space{}
9557 you can write several letters per document).
9558 New elements are sender's
9574 and the possibility to use a
9580 Insert\SpecialChar menuseparator
9586 \begin_layout Standard
9587 The biggest improvement is, though, that the letter's layout is configurable
9588 to meet almost any needs.
9589 This can be done via the preamble or with a special style file (Letter
9590 Class Option, extension
9594 ), that will be read in as a class option.
9598 \begin_layout Plain Layout
9599 The KOMA package comes with some default
9604 There is, for instance, a
9608 file that follows german typesetting rules, or a
9612 that provides the default layout of the old
9617 The latter can be loaded with the class option
9623 Layout\SpecialChar menuseparator
9624 Document\SpecialChar menuseparator
9636 template that is included in \SpecialChar LyX
9638 A detailed description is to be found in the Koma-Script documentation
9646 \begin_layout Subsection
9650 \begin_layout Standard
9651 Visualizing the Koma-Script document classes in \SpecialChar LyX
9652 , the \SpecialChar LyX
9653 internals cause some
9657 \begin_layout Itemize
9658 The chapter number of a
9662 type appears on a line of its own above the chapter heading instead of
9663 appearing in the same line ahead of it.
9664 The cause for that is the \SpecialChar LyX
9665 internal behavior for the labeltype
9672 \begin_layout Itemize
9673 The headings of the types
9682 \begin_inset Quotes eld
9686 \begin_inset Quotes erd
9690 table of contents, but not in the \SpecialChar LyX
9693 Document\SpecialChar menuseparator
9695 \begin_inset space ~
9699 \begin_inset space ~
9707 \begin_layout Itemize
9712 document class appear in a skip separation mode, not indented.
9713 This is the standard behavior, no special \SpecialChar LaTeX
9714 commands are needed for that.
9717 Document\SpecialChar menuseparator
9720 dialog the corresponding radio button indicates
9729 value always has the effect that extra \SpecialChar LaTeX
9730 commands are inserted in the document
9731 to produce the gap, which is not what is wanted in this case.
9734 \begin_layout Section
9738 \begin_layout Standard
9744 \begin_layout Subsection
9748 \begin_layout Standard
9749 Memoir is a very powerful and constantly evolving class.
9750 It has been designed with regard to fictional and non-fictional literature.
9751 Its aim is to let the user have maximum control over the typesetting of
9753 Memoir is based on the standard book class, but it can also emulate the
9754 article class (see below).
9757 \begin_layout Standard
9758 Peter Wilson, the developer of Memoir, is known as the author of lots of
9759 useful packages in the \SpecialChar LaTeX
9761 Most of them have been merged with Memoir.
9762 Therefore, it is much easier to layout the table of contents, appendices,
9763 chapter designs and such.
9765 , though, does not support all of these goodies natively.
9766 Some of them might be added to forthcoming releases
9770 \begin_layout Plain Layout
9771 You are invited to send suggestions to
9772 \begin_inset Flex URL
9775 \begin_layout Plain Layout
9777 lyx-devel@lists.lyx.org
9787 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
9789 Of course you can still use all features with the help of some native \SpecialChar LaTeX
9791 commands (\SpecialChar TeX
9796 \begin_layout Plain Layout
9801 \begin_layout Plain Layout
9811 \begin_inset space ~
9815 \begin_inset CommandInset ref
9817 reference "sec:Inserting-TeX-Code"
9827 In this section, we can only list those features that are natively supported
9830 For detailed descriptions (and for the rest of features) we recommend you
9831 have a look at the detailed manual of the Memoir class
9835 \begin_layout Plain Layout
9840 \begin_layout Plain Layout
9850 \begin_inset Flex URL
9853 \begin_layout Plain Layout
9855 CTAN:/macros/latex/memoir/memman.pdf
9865 , which is not only a user guide for the class, but also both a comprehensive
9866 description on good typesetting and a superb example for good typesetting
9870 \begin_layout Subsection
9871 Basic features and restrictions
9874 \begin_layout Standard
9875 Memoir supports basically all features of the standard book classes.
9876 There are, however, some differences, as follows:
9879 \begin_layout Description
9881 \begin_inset space ~
9884 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
9887 \begin_layout Description
9889 \begin_inset space ~
9892 style: The fancy page style is not supported, due to a command clash between
9893 Memoir and the fancyhdr package (they both define a command with the same
9894 name, which confuses \SpecialChar LaTeX
9896 Instead, Memoir comes with a number of its own page styles (see
9898 Layout\SpecialChar menuseparator
9899 Document\SpecialChar menuseparator
9901 \begin_inset space ~
9907 If you want to use these for the chapter pages, you have to use the command
9914 in the main text or in preamble (e.
9915 \begin_inset space \thinspace{}
9919 \begin_inset space \space{}
9926 chapterstyle{companion}
9931 \begin_layout Description
9932 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
9933 optional argument in the standard classes.
9934 With this, you can specify an alternative version of the title for the
9935 table of contents and the headers (for instance, if the title is too long).
9937 , you can do this via
9939 Insert\SpecialChar menuseparator
9941 \begin_inset space ~
9946 at the beginning of a chapter/section.
9947 Memoir features a second optional argument and thus separates the table
9948 of contents from the header.
9949 You can define three variants of a title with this: one for the main text,
9950 one for the table of contents, and one for the headers.
9951 Simply insert two optional arguments if you need this feature, the first
9952 one containing the short title for the Table of Contents, the second one
9953 containing an alternative short title for the headers.
9956 \begin_layout Description
9957 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
9958 of contents, the list of figures and the list of table start a new page
9960 Memoir does not follow this route.
9961 You have to insert a page break yourself, if you want to have one.
9964 \begin_layout Description
9965 Titlepage: For some unknown reason, Memoir uses pagination on the title
9966 page (in the standard classes, title pages are
9967 \begin_inset Quotes eld
9971 \begin_inset Quotes erd
9975 If you want an empty title page, type
9979 aliaspagestyle{title}{empty}
9984 \begin_layout Description
9985 Article: With the class option
9991 Layout\SpecialChar menuseparator
9992 Document\SpecialChar menuseparator
9994 \begin_inset space ~
9999 ), you can emulate article style.
10000 That is, counters (footnotes, figures, tables etc.) will not be reset on
10001 new chapters, chapters don't start a new page (but are—in contrary to
10002 \begin_inset Quotes eld
10006 \begin_inset Quotes erd
10009 article classes—still allowed), parts, though, use their own page, as in
10013 \begin_layout Description
10014 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
10015 font commands, which have been used in the old \SpecialChar LaTeX
10017 \begin_inset space \thinspace{}
10021 \begin_inset space \space{}
10037 It produces an error and stops \SpecialChar LaTeX
10038 whenever such a command appears.
10043 reallows the commands and spits out warnings instead (which does at least
10044 not stop \SpecialChar LaTeX
10046 Since a lot of packages and particularly Bib\SpecialChar TeX
10047 style files are still using
10048 those commands, we have decided to use this option by default.
10051 \begin_layout Subsection
10055 \begin_layout Standard
10056 We will only describe the features supported by \SpecialChar LyX
10057 (which is not much currently).
10058 Please consult the Memoir manual
10062 \begin_layout Plain Layout
10067 \begin_layout Plain Layout
10077 \begin_inset Flex URL
10080 \begin_layout Plain Layout
10082 CTAN:/macros/latex/memoir/memman.pdf
10095 \begin_layout Description
10096 Abstract: You may wonder why an abstract is an extra feature.
10097 Well, it is in book class.
10098 Usually books don't have abstracts.
10099 Memoir, however, has.
10100 You can use it wherever and how often you like.
10103 \begin_layout Description
10104 Chapterprecis: You may know this older typesetting style: The contents of
10105 a chapter are summarized below the title and also in the table of contents
10107 \begin_inset space \thinspace{}
10111 \begin_inset space \space{}
10116 Our hero arrives in Troia; he loses some friends; he finds others
10119 Chapterprecis does exactly this.
10120 It is therefore only sensible below a chapter.
10123 \begin_layout Description
10124 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
10125 The epigraph environment provides an elegant way of typesetting such a
10127 The motto itself (text) and its author (source) are divided by a short
10129 Unfortunately, we have to fool \SpecialChar LyX
10130 a bit here again, since the environment
10131 needs two arguments (text and source).
10132 In this case, we have to use curly brackets (in \SpecialChar TeX
10133 mode) between the two
10144 <author of the slogan>.
10147 \begin_layout Description
10148 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
10149 complex figurative poems).
10151 can only support a few of them.
10152 One is poemtitle, which is a centered title for poems, which will also
10153 be added to the table of contents (verse is the standard environment for
10155 Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
10157 because they have to be nested inside regular verse environments, which
10158 is not possible with \SpecialChar LyX
10162 \begin_layout Description
10163 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
10166 \begin_layout Section
10167 Article (mwart), book (mwbk) and report (mwrep)
10168 \begin_inset Argument status
10171 \begin_layout Plain Layout
10184 \begin_layout Standard
10190 \begin_layout Standard
10191 The \SpecialChar LyX
10208 correspond to the \SpecialChar LaTeX
10222 They are replacements for the standard document classes
10234 , resp., and fit better to Polish typography conventions in a number of points.
10238 \begin_layout Standard
10242 \begin_layout Itemize
10243 Unnumbered titles (with star, e.
10244 \begin_inset space \thinspace{}
10248 \begin_inset space \space{}
10255 ) are added into table of contents,
10258 \begin_layout Itemize
10259 Additional page styles:
10263 \begin_layout Description
10264 uheadings header with separated lines,
10267 \begin_layout Description
10268 myheadings custom header, contents headers via commands:
10283 \begin_layout Description
10284 myuheadings custom header with separated lines,
10287 \begin_layout Description
10288 outer page number is placed on outer side of page
10292 \begin_layout Itemize
10297 \begin_layout Description
10298 rmheadings serif titles — default,
10301 \begin_layout Description
10302 sfheadings sansserif titles,
10305 \begin_layout Description
10306 authortitle on title page first placed is author next title — default,
10309 \begin_layout Description
10310 titleauthor on title page first placed is title next author,
10313 \begin_layout Description
10314 withmarginpar reserve place on page for margins.
10318 \begin_layout Section
10322 \begin_layout Standard
10327 provides an alternative to the standard
10332 It provides similar functionality, but you might prefer this layout with
10333 sans serif sections, headings, and more.
10336 \begin_layout Section
10337 Rev\SpecialChar TeX
10341 \begin_layout Standard
10347 \begin_layout Standard
10348 \begin_inset VSpace bigskip
10354 \begin_layout Standard
10359 \begin_inset space ~
10364 textclass works with the American Physical Sociey's Rev\SpecialChar TeX
10366 \begin_inset Formula $\beta$
10369 release of May, 1999) class.
10372 \begin_layout Standard
10378 textclass, which works with Rev\SpecialChar TeX
10380 However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
10382 That means that it doesn't interact very well with \SpecialChar LyX
10383 , which requires \SpecialChar LaTeX2e
10385 it has been kludged to work.
10386 Since Rev\SpecialChar TeX
10387 4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
10392 Rev\SpecialChar TeX
10394 \begin_inset space ~
10399 textclass should also be pretty easy to use.
10402 \begin_layout Standard
10403 These documents are supposed to be used in
10407 to the Rev\SpecialChar TeX
10408 4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
10410 and assume you'll know what to put in the preamble if necessary.
10413 \begin_layout Subsection
10417 \begin_layout Standard
10418 All you need to do is install Rev\SpecialChar TeX
10419 4, as described in the package's README
10421 The package can be found at The Rev\SpecialChar TeX
10423 \begin_inset Flex URL
10426 \begin_layout Plain Layout
10428 http://publish.aps.org/revtex4/
10434 Install it somewhere that \SpecialChar LaTeX
10436 Test it by trying to \SpecialChar LaTeX
10437 a short Rev\SpecialChar TeX
10438 4 document in some random directory (i.
10439 \begin_inset space \thinspace{}
10443 \begin_inset space \space{}
10446 not the directory where you installed the class file.) Then, if you reconfigure
10448 , it will find the class file and let you use the Rev\SpecialChar TeX
10452 \begin_layout Standard
10453 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
10462 \begin_inset space ~
10467 template, found in the templates directory.
10470 \begin_layout Subsection
10474 \begin_layout Standard
10475 Optional arguments to
10482 \begin_inset Quotes eld
10486 \begin_inset Quotes erd
10490 \begin_inset Quotes eld
10494 \begin_inset Quotes erd
10500 \begin_inset space ~
10508 \begin_inset space ~
10514 Remember that in Rev\SpecialChar TeX
10515 , at least one optional argument is required!
10518 \begin_layout Standard
10519 Other preamble matter, like
10526 \begin_inset space ~
10533 \begin_inset space ~
10538 dialog, also as usual.
10541 \begin_layout Subsection
10545 \begin_layout Standard
10546 The layouts basically correspond to the commands in Rev\SpecialChar TeX
10548 For example, the Email layout corresponds to
10555 Note that (at least as of Rev\SpecialChar TeX
10564 layouts are exactly equivalent, so you shouldn't need to use both.
10568 \begin_layout Plain Layout
10569 In case you're curious, both were included so that
10573 would be able to translate both
10593 \begin_layout Subsection
10597 \begin_layout Standard
10598 There are a couple of important unique aspects of Rev\SpecialChar TeX
10599 4 which might cause
10600 bugs that will be even more confusing in \SpecialChar LyX
10604 \begin_layout Standard
10605 In Rev\SpecialChar TeX
10623 The \SpecialChar LyX
10624 equivalent is that there is a separate Thanks layout.
10629 write footnotes in the
10633 layout, or weird things may happen.
10634 See the Rev\SpecialChar TeX
10635 4 documentation for more details.
10638 \begin_layout Standard
10642 \begin_inset space ~
10650 \begin_inset space ~
10659 layouts must be placed
10667 layout and the corresponding
10684 , the \SpecialChar LaTeX
10688 \begin_layout Subsection
10692 \begin_layout Standard
10693 The main problem with this layout is that you can't use the optional arguments
10694 to layouts like Email and Title.
10695 (The problem is not unique to this layout; you can't use optional arguments
10696 to the Section layouts either.) This means that after you export that file
10697 to \SpecialChar LaTeX
10698 (which you'll need to do eventually to send it in to APS), you'll need
10699 to edit the \SpecialChar LaTeX
10700 file with a text editor to add the optional arguments to set,
10702 \begin_inset space \thinspace{}
10706 \begin_inset space \space{}
10709 the running title for the page headers.
10710 Lacking these layouts makes the
10716 (and the equivalent
10722 ) useless, so the corresponding layouts don't exist, and will have to be
10727 \begin_layout Plain Layout
10732 actually, \SpecialChar LyX
10733 1.3.0 supports some forms of optional arguments, but this layout
10734 has not been updated yet to take advantage of it.
10742 \begin_layout Section
10743 Springer Journals (
10750 \begin_layout Standard
10756 \begin_layout Subsection
10760 \begin_layout Standard
10761 These are the layout files for some of the journal formats used by Springer
10762 Verlag and listed on
10763 \begin_inset Flex URL
10766 \begin_layout Plain Layout
10768 http://www.springer.de/author/tex/help-journals.html
10773 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
10775 It is a modular system: the things common to all journals are implemented
10780 , which journal-specific layout files (such as, e.
10781 \begin_inset space \thinspace{}
10785 \begin_inset space \space{}
10792 for Journal of Geodesy) can include.
10795 \begin_layout Standard
10796 This means that implementing support for any other Springer journal on this
10797 list is as simple as writing your own
10805 file following the outline given in
10813 \begin_layout Standard
10814 It is reasonably well tested only for the Journal of Geodesy.
10823 come with the standard \SpecialChar LyX
10825 Install the relevant class file (downloaded from Springer) in a proper
10826 directory, reconfigure \SpecialChar LaTeX
10827 (in the te\SpecialChar TeX
10832 , as root if necessary — doesn't \SpecialChar LyX
10833 take care of this?), reconfigure \SpecialChar LyX
10838 \begin_layout Subsection
10842 \begin_layout Standard
10843 A large number of theorem-like styles —
10855 \begin_layout Standard
10858 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
10859 _Title, Author_Running, Institute,
10860 Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
10863 See the Springer class file documentation for details.
10866 \begin_layout Subsection
10870 \begin_layout Itemize
10882 \begin_layout Itemize
10885 Probability Theory and Related Fields
10891 — Jean-Marc Lasgouttes
10894 \begin_layout Standard
10895 Add your own, it isn't so hard!
10898 \begin_layout Subsection
10902 \begin_layout Standard
10903 These files are partly based on the older
10907 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
10909 file from Springer.
10914 layout, are now defunct.
10915 Jean-Marc Lasgouttes helped out big in making me find my way around the
10917 layout file mechanism.
10920 \begin_layout Subsection
10924 \begin_layout Standard
10926 But probably less than in the old hacked-\SpecialChar LaTeX
10934 \begin_layout Standard
10936 \begin_inset space \thinspace{}
10939 g.: does not display the number for theorem-like layouts, just #.
10942 \begin_layout Section
10945 Sli\SpecialChar TeX
10949 \begin_inset CommandInset label
10958 \begin_layout Standard
10966 \begin_layout Subsection
10970 \begin_layout Standard
10971 This section describes how to use \SpecialChar LyX
10972 to make slides for overhead projectors.
10973 There are two document classes that can do this: the default slides class
10976 Foil\SpecialChar TeX
10980 This section documents the former.
10983 \begin_layout Standard
10984 I'm going to say this again, nice and clear, so that there's no misunderstanding
10988 \begin_layout Standard
10989 \begin_inset VSpace bigskip
10995 \begin_layout Standard
10999 This section documents the class
11000 \begin_inset Quotes eld
11008 \begin_inset Quotes erd
11016 \begin_layout Standard
11017 \begin_inset VSpace bigskip
11023 \begin_layout Standard
11024 If you're looking for the documentation for
11025 \begin_inset Quotes eld
11030 slides (Foil\SpecialChar TeX
11034 \begin_inset Quotes erd
11037 , check out section
11038 \begin_inset space ~
11042 \begin_inset CommandInset ref
11044 reference "sec:foiltex"
11054 \begin_inset Quotes eld
11059 slides (Foil\SpecialChar TeX
11063 \begin_inset Quotes erd
11066 ] is actually somewhat better than the default
11074 \begin_layout Plain Layout
11076 or so I've been told repeatedly by its advocates.
11077 Having never used it, I have no idea if this claim is true or not.
11082 which this section documents.
11085 \begin_layout Standard
11086 This class is the \SpecialChar LaTeX2e
11087 improvement of the old
11089 Sli\SpecialChar TeX
11093 Every \SpecialChar LaTeX2e
11094 distribution includes this class [which I'll just refer to as
11095 \begin_inset Quotes eld
11103 \begin_inset Quotes erd
11106 from now on], so you're bound to have it.
11107 As I noted earlier, there are other classes, such as
11111 , which also produce slides for overhead projectors and do a better job
11113 However, there are some things which
11117 can do which the others can't, such as generate overlays.
11118 Read on to learn more!
11121 \begin_layout Subsection
11123 \begin_inset CommandInset label
11125 name "sec:slidesetup"
11132 \begin_layout Standard
11133 Obviously, to use this document class, you need to select
11134 \begin_inset Quotes eld
11142 \begin_inset Quotes erd
11145 from the class list in the
11147 Document\SpecialChar menuseparator
11151 There are some other special things you should know about this class:
11154 \begin_layout Itemize
11155 Don't bother changing the options
11160 They're not supported by the
11167 \begin_layout Itemize
11171 \begin_inset space ~
11176 behaves a bit differently for this class.
11177 The possible choices and what they do are as follows:
11181 \begin_layout Description
11186 The final output contains page numbers in the lower right corner.
11189 \begin_layout Description
11198 , but also prints out any time markers you've put in.
11199 This is the default.
11202 \begin_layout Description
11207 The final output contains no page numbers, time markers, or alignment markers.
11211 \begin_layout Itemize
11216 class has an extra option:
11222 \begin_inset Quotes eld
11230 \begin_inset Quotes erd
11233 in the extra class options.
11237 \begin_layout Standard
11238 Using this options allows you to add time markers to
11244 \begin_inset space ~
11248 \begin_inset CommandInset ref
11250 reference "sec:slideNote"
11258 \begin_layout Standard
11259 You can also use the template file
11260 \begin_inset Quotes eld
11268 \begin_inset Quotes erd
11271 to automatically set up a document to use the
11277 File\SpecialChar menuseparator
11279 \begin_inset space ~
11283 \begin_inset space ~
11288 to open your new document].
11289 The template file also contains some examples of the special paragraph
11290 environments used by this class.
11291 I'll describe those next.
11294 \begin_layout Subsection
11295 Paragraph Environments
11298 \begin_layout Subsubsection
11299 Supported Environments
11302 \begin_layout Standard
11303 The first thing you'll notice when you start up a new
11307 document is the font size and type: it's the equivalent of the size
11308 \begin_inset Quotes eld
11316 \begin_inset Quotes erd
11322 \begin_inset space ~
11328 This is also what's used in the output.
11330 \begin_inset Quotes eld
11334 \begin_inset Quotes erd
11337 to remind you that this is a slide.
11338 Your final slides will use a larger font; ergo, you'll have less space.
11339 Of course, the larger default screen font isn't WYSIWYG, only a reminder.
11342 \begin_layout Standard
11343 The next thing that becomes obvious is the changes to the paragraph environment
11344 pull-down box [at the far-left end of the toolbar].
11345 Most of the paragraph environments you're used to seeing are missing.
11346 There are also five new ones.
11351 class itself only supports certain paragraph environments:
11354 \begin_layout Itemize
11360 \begin_layout Itemize
11366 \begin_layout Itemize
11372 \begin_layout Itemize
11378 \begin_layout Itemize
11384 \begin_layout Itemize
11390 \begin_layout Itemize
11396 \begin_layout Itemize
11402 \begin_layout Itemize
11408 \begin_layout Itemize
11415 \begin_layout Itemize
11421 \begin_layout Standard
11422 All of the other standard environments, including the section-heading environmen
11423 ts, aren't used in the
11430 \begin_layout Standard
11431 On the other hand, you'll notice the following new environments:
11434 \begin_layout Itemize
11440 \begin_layout Itemize
11446 \begin_layout Itemize
11452 \begin_layout Itemize
11458 \begin_layout Itemize
11464 \begin_layout Standard
11465 These five are kind of quirky, due to a
11466 \begin_inset Quotes eld
11470 \begin_inset Quotes erd
11473 in \SpecialChar LyX
11475 You see, \SpecialChar LyX
11476 doesn't permit you to nest any other paragraph environment into
11477 an empty environment.
11478 Now, that's fine and dandy, but it means that you wouldn't be able to start
11479 a slide with anything except plain text.
11480 To deal with this, I've performed a little
11481 \begin_inset Quotes eld
11486 \begin_inset Quotes erd
11492 \begin_layout Subsubsection
11493 Quirks of the New Environments
11494 \begin_inset CommandInset label
11496 name "sec:slideQuirk"
11503 \begin_layout Standard
11504 All five of the new paragraph environments are somewhat quirky due to inherent
11505 limitiations in the current version of \SpecialChar LyX
11507 As I just mentioned, \SpecialChar LyX
11508 forbids environments that begin with another environment.
11509 To get around this, the
11513 environment isn't a paragraph environment as described in the
11521 \begin_layout Standard
11522 You should consider
11535 \begin_inset Quotes eld
11538 pseudo-environments.
11539 \begin_inset Quotes erd
11542 They look like a section heading or a
11543 \begin_inset Quotes eld
11551 \begin_inset Quotes erd
11554 but really begin a [and, if necessary, end the previous] paragraph environment.
11564 \begin_inset Quotes eld
11568 \begin_inset Quotes erd
11571 These two perform some action.
11574 \begin_layout Standard
11575 A common feature of all five environments,
11595 , is a rather long-ish label.
11596 The text following this label — ordinarily the contents of the paragraph
11597 environment — is utterly irrelevant for
11619 completely ignores it.
11620 In fact, you can leave these five environments completely empty.
11624 \begin_layout Standard
11629 to put any text after the rather long-ish label, you might want to.
11630 This could be a short description of the contents of the
11635 In that case, enter your descriptive comment and hit
11639 as you normally would.
11642 \begin_layout Standard
11643 If, on the other hand, you don't want to enter any descriptive text, you'll
11644 hit another \SpecialChar LyX
11647 , like nature, abhors a vacuum, and will not let you start a new paragraph
11648 environment until you put something in the old one.
11652 \begin_layout Itemize
11653 Start entering the text that will
11681 \begin_layout Itemize
11682 Now move to the beginning of that paragraph.
11686 \begin_layout Itemize
11695 \begin_layout Itemize
11696 Finally, change this new, empty paragraph to a
11720 \begin_layout Standard
11721 Some future version of \SpecialChar LyX
11722 will, hopefully, resolve this quirkiness\SpecialChar ldots
11726 \begin_layout Subsection
11727 Making a Presentation with
11740 \begin_layout Subsubsection
11748 \begin_layout Standard
11749 If you're expecting this section to teach you how to actually make a presentatio
11750 n, you'll be sorely disappointed.
11751 Naturally, I'll describe all of the ways the
11755 class can assist you in preparing the materials for a presentation.
11756 Filling in the contents, however, is up to you.
11761 the \SpecialChar LyX
11765 \begin_layout Standard
11770 environment [in the manner described in section
11771 \begin_inset space ~
11775 \begin_inset CommandInset ref
11777 reference "sec:slideQuirk"
11781 ] tells \SpecialChar LyX
11782 to begin a new slide [duh].
11783 The label for this environment/
11784 \begin_inset Quotes erd
11788 \begin_inset Quotes erd
11792 \begin_inset Quotes eld
11796 \begin_inset Quotes erd
11799 in cool blue, followed by the label,
11800 \begin_inset Quotes eld
11804 \begin_inset Quotes erd
11808 Any text or paragraph environments that follow this one go on the new slide.
11812 \begin_layout Standard
11813 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
11815 (this can be specified in the
11820 In fact, you'll want to, once you finish entering the contents of one slide.
11821 If you've entered more text than can physically fit on a slide, the extra
11822 overflows onto a new slide.
11823 I don't recommend doing this, however, since the overflow slide won't have
11824 any page number on it.
11825 Furthermore, it may interfere with any
11829 you've made to accompany the oversized
11836 \begin_layout Standard
11845 environments work the same way as the
11850 They both create an
11851 \begin_inset Quotes eld
11855 \begin_inset Quotes erd
11858 followed by a label [
11859 \begin_inset Quotes eld
11863 \begin_inset Quotes erd
11867 \begin_inset Quotes eld
11871 \begin_inset Quotes erd
11875 The color is a stunning magenta instead of blue, and the
11876 \begin_inset Quotes eld
11880 \begin_inset Quotes erd
11883 will look different, in style and in length.
11884 The label fonts of all three also differ from one another.
11887 \begin_layout Standard
11892 , if the contents of a
11900 exceed the physical size of a slide or sheet of paper, the extra will overflow
11902 Again, you should avoid this.
11903 It defeats the whole purpose of
11914 \begin_layout Subsubsection
11924 \begin_layout Standard
11929 is a slide that sits atop another slide.
11930 Perhaps you wish to discuss a figure on the main
11934 before displaying the text associated with it.
11935 One way to accomplish this is tape a flap of dark paper over the part of
11940 you want to display later.
11941 This method fails, however, if you wish to overlap one graph with another,
11943 You would then have to fumble while speaking to align the two separate,
11948 s to align the two graphs.
11953 environment in both cases makes life much easier.
11956 \begin_layout Standard
11961 receives the page number of its
11962 \begin_inset Quotes eld
11966 \begin_inset Quotes erd
11974 \begin_inset Quotes eld
11982 \begin_inset Quotes erd
11989 \begin_layout Plain Layout
11990 Presumably, mutliple
11995 \begin_inset Quotes eld
12003 \begin_inset Quotes erd
12007 \begin_inset Quotes eld
12015 \begin_inset Quotes erd
12019 \begin_inset Quotes eld
12027 \begin_inset Quotes erd
12031 \begin_inset space ~
12034 appended to the page number of the parent
12044 Clearly, you want the contents of both the
12052 to each fit on a single physical slide! You should probably consider an
12058 \begin_inset Quotes eld
12062 \begin_inset Quotes erd
12070 Indeed, the \SpecialChar LyX
12075 class provides a visual cue for this: the label at the start of an
12079 is shorter than that at the start of a
12084 Lastly, when you generate printable output, you'll find alignment markers
12085 in all four corners of both the
12089 page and its parent
12094 These will assist you in lining up the two physical slides.
12097 \begin_layout Standard
12098 The major problem in overlaying two slides is aligning the contents of the
12099 two transparencies.
12100 How much space should you leave for that graph on the second slide? Worse
12101 still, what if you want a graph and a sentence on second slide, but there
12102 is text on the main transparency that goes in between them? You could try
12103 and insert vertical space of the right size.
12104 The better way is to use
12115 \begin_layout Standard
12116 As their names imply,
12124 are two command-like paragraph environments that make all subsequent text
12125 invisible and visible, respectively.
12127 \begin_inset space ~
12131 \begin_inset CommandInset ref
12133 reference "sec:slideQuirk"
12137 that you don't place anything
12141 these two environments, however.
12146 , it inserts a centered, sky-blue label into the page reading
12147 \begin_inset Quotes eld
12150 <Invisible Text Follows>
12151 \begin_inset Quotes erd
12155 For paragraphs following this label, the parts of the
12163 ; it doesn't matter which] where they would be contain instead blank space.
12167 \begin_layout Standard
12172 , the corresponding centered label is
12173 \begin_inset Quotes eld
12176 <Visible Text Follows>
12177 \begin_inset Quotes erd
12181 Paragraphs following this label behave normally.
12182 Note that the beginning of a new
12194 automatically shuts off an
12199 It's therefore not necessary to use
12210 \begin_layout Standard
12211 By now, it should be obvious how to create overlay transparencies using
12212 the proper combination of
12231 \begin_layout Enumerate
12236 , including everything that will appear on it, whether on the main slide
12244 \begin_layout Enumerate
12245 Before each figure or paragraph that will appear only on the
12254 If necessary, insert a
12258 environment after the
12265 \begin_layout Enumerate
12270 immediately following the
12277 \begin_layout Enumerate
12278 Copy the contents of this
12289 \begin_layout Enumerate
12294 , change all of the
12305 \begin_layout Standard
12307 You've just made an
12314 \begin_layout Standard
12315 There's one problem with the way I've designed the \SpecialChar LyX
12320 class: you can't make text in the middle of a paragraph invisible, nor
12321 make text in the middle of an invisible paragraph visible again.
12322 To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
12327 \begin_layout Plain Layout
12328 The commands of interest are:
12331 \begin_layout Itemize
12336 invisible \SpecialChar ldots
12340 \begin_layout Itemize
12345 visible \SpecialChar ldots
12349 \begin_layout Plain Layout
12351 and need to be marked as \SpecialChar TeX
12354 \begin_inset Quotes eld
12358 \begin_inset Quotes erd
12361 you wish to change goes in between the brackets [and after the
12374 If you don't know how to mark text as \SpecialChar TeX
12375 , see the appropriate section of
12388 \begin_layout Subsubsection
12398 \begin_inset CommandInset label
12400 name "sec:slideNote"
12407 \begin_layout Standard
12416 is associated with a
12417 \begin_inset Quotes eld
12421 \begin_inset Quotes erd
12429 Here, too, the \SpecialChar LyX
12434 class provides visual cues.
12439 is shorter than that of a
12443 [yet longer than that of an
12447 ] and, like the label of an
12451 is shockingly magenta.
12452 Additionally, the printed
12456 has the page number of its
12457 \begin_inset Quotes eld
12461 \begin_inset Quotes erd
12469 \begin_inset Quotes eld
12477 \begin_inset Quotes erd
12481 \begin_inset Quotes eld
12489 \begin_inset Quotes erd
12493 \begin_inset Quotes eld
12501 \begin_inset Quotes erd
12505 You can have multiple
12509 s associated with a single
12521 , you'll probably want to break up long
12525 s so that they fit on a single sheet of paper.
12528 \begin_layout Standard
12533 is obvious: it contains anything additional you might want to say about
12539 It could also be used as a sheet of reminders for a particular
12544 In the case of the latter, you might want to make use of time markers.
12545 Currently, the \SpecialChar LyX
12551 \begin_inset Quotes eld
12555 \begin_inset Quotes erd
12558 support for time markers, a
12560 Sli\SpecialChar TeX
12564 So, you'll have to resort to using the \SpecialChar LaTeX
12568 \begin_layout Standard
12569 To use time markers, you'll need to specify the extra class option
12570 \begin_inset Quotes eld
12578 \begin_inset Quotes erd
12582 \begin_inset space ~
12586 \begin_inset CommandInset ref
12588 reference "sec:slidesetup"
12593 This option turns on timing marks, which will appear in the lower-left-hand
12599 To set what appears in the time marker, you use the \SpecialChar LaTeX
12601 \begin_inset Quotes eld
12611 \begin_inset Quotes erd
12615 \begin_inset Quotes eld
12625 \begin_inset Quotes erd
12629 The arguments of both commands are time measured in seconds.
12631 \begin_inset Quotes eld
12641 \begin_inset Quotes erd
12644 sets the time marker to a given time.
12646 \begin_inset Quotes eld
12656 \begin_inset Quotes erd
12659 increments the time marker by the specified amount.
12660 Using time markers and
12664 s in this fashion, you can remind yourself how much time to spend on a particula
12672 \begin_layout Standard
12673 There's one last feature to describe.
12674 Clearly, you'd like to print out all of your
12682 s on transparencies while printing all of your
12699 with which it is associated.
12700 What's a person to do?
12703 \begin_layout Standard
12704 Luckily, there are two \SpecialChar LaTeX
12705 commands that allow you to select what to print
12707 Both must be placed into the preamble of your document.
12709 \begin_inset Quotes eld
12721 \begin_inset Quotes erd
12724 will cause the output to contain only the
12733 Correspondingly, the command
12734 \begin_inset Quotes eld
12746 \begin_inset Quotes erd
12749 prevents the output of anything but
12754 I'd advise placing both commands in the preamble and initially comment
12756 You can then preview your entire presentation as you write.
12757 When you're done writing, you can then uncomment one of the two to select
12758 what you want to print.
12759 I like to uncomment
12760 \begin_inset Quotes eld
12772 \begin_inset Quotes erd
12775 , print to a file with
12776 \begin_inset Quotes eld
12784 \begin_inset Quotes erd
12787 in its name, comment it back out, then uncomment
12788 \begin_inset Quotes eld
12800 \begin_inset Quotes erd
12804 \begin_inset Quotes eld
12812 \begin_inset Quotes erd
12816 I can then send either file to a printer, loading transparencies or plain
12817 paper as appropriate.
12820 \begin_layout Standard
12821 You can also provide other arguments to the
12822 \begin_inset Quotes eld
12832 \begin_inset Quotes erd
12836 \begin_inset Quotes eld
12846 \begin_inset Quotes erd
12850 See a good \SpecialChar LaTeX
12854 \begin_layout Subsection
12859 Class Template File
12862 \begin_layout Standard
12863 I have also provided a template file,
12864 \begin_inset Quotes eld
12872 \begin_inset Quotes erd
12880 To use it, begin your new presentation with
12882 File\SpecialChar menuseparator
12884 \begin_inset space ~
12888 \begin_inset space ~
12894 Your new \SpecialChar LyX
12895 presentation file will contain an example
12916 additionally contain an example of the use of
12925 Lastly, the preamble will contain:
12928 \begin_layout LyX-Code
12929 % Uncomment to print out only slides and overlays
12932 \begin_layout LyX-Code
12936 \begin_layout LyX-Code
12942 \begin_inset Newline newline
12948 \begin_layout LyX-Code
12949 % Uncomment to print out only notes
12952 \begin_layout LyX-Code
12956 \begin_layout LyX-Code
12964 \begin_layout Standard
12965 One final thing: I created this class to support the \SpecialChar LaTeX2e
12967 \begin_inset Quotes eld
12972 Sli\SpecialChar TeX
12976 \begin_inset Quotes erd
12979 class, one of the built-in \SpecialChar LaTeX2e
12981 Neither I nor the rest of the \SpecialChar LyX
12982 Team endorse or oppose the use of this built-in
12984 It's here if you want it or need it.
12985 There exist other \SpecialChar LaTeX2e
12986 classes for creating presentations, such as the
12991 \begin_inset space ~
12995 \begin_inset CommandInset ref
12997 reference "sec:foiltex"
13002 \begin_inset Quotes eld
13010 \begin_inset Quotes erd
13013 package [present on some \SpecialChar TeX
13015 The latter is not yet supported under \SpecialChar LyX
13020 \begin_layout Plain Layout
13021 Perhaps you can take on the task\SpecialChar ldots
13027 I know nothing about these other classes.
13028 Try them out to see what sort of alternative they provide.
13031 \begin_layout Chapter
13033 \change_inserted 893223064 1464851900
13037 \begin_layout Standard
13039 \change_inserted 893223064 1464851910
13040 This is a holder for prepared text.
13043 \begin_layout Chapter
13045 \change_inserted 893223064 1464851939
13049 \begin_layout Standard
13051 \change_inserted 893223064 1464851945
13052 This is a holder for prepared text.
13055 \begin_layout Section
13059 \begin_layout Standard
13060 You can do everything with \SpecialChar LyX
13061 that you can do with \SpecialChar LaTeX
13063 However, \SpecialChar LyX
13064 cannot support every \SpecialChar LaTeX
13066 But you can always use \SpecialChar TeX
13068 This chapter shows you some more special things you might want to use.
13069 For other special things you can do with figures, tables, floats, boxes
13070 and notes, have a look at the
13073 \begin_inset space ~
13081 \begin_layout Section
13082 Fancy Headers and Footers
13085 \begin_layout Standard
13086 The default page layout is rather plain; for an
13087 \begin_inset Flex Code
13090 \begin_layout Plain Layout
13096 document class, all you get is a centered page number at the bottom of
13098 This document uses KOMA-script's book class, so it appears to be a bit
13100 But to really put on a show, you need to set the document page style to
13102 \begin_inset Quotes eld
13106 \begin_inset Quotes erd
13109 , as mentioned in the
13114 This section describes the \SpecialChar LaTeX
13115 code you need to insert in your \SpecialChar LaTeX
13117 order to get the desired effects.
13120 \begin_layout Standard
13121 For more information on fancy headers, see the
13122 \begin_inset Flex Code
13125 \begin_layout Plain Layout
13131 package documentation.
13133 \begin_inset Flex URL
13136 \begin_layout Plain Layout
13138 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
13146 \begin_layout Standard
13147 The page header is divided into three fields, not surprisingly labeled
13148 \begin_inset Quotes eld
13152 \begin_inset Quotes erd
13156 \begin_inset Quotes eld
13160 \begin_inset Quotes erd
13164 \begin_inset Quotes eld
13168 \begin_inset Quotes erd
13172 The footer is also divided into these three fields.
13173 The \SpecialChar LaTeX
13174 commands to set these fields in the simplest manner are
13175 \begin_inset Flex Code
13178 \begin_layout Plain Layout
13187 \begin_inset Flex Code
13190 \begin_layout Plain Layout
13199 \begin_inset Flex Code
13202 \begin_layout Plain Layout
13211 \begin_inset Flex Code
13214 \begin_layout Plain Layout
13223 Suppose you wish to put your name in the upper left hand corner of each
13225 Simply insert the following command in the preamble:
13228 \begin_layout Standard
13237 \begin_layout Standard
13238 You will now see your name in the upper left.
13239 If a field has a default entry that you would like to get rid of (often
13240 the page number appears in the central footer) simply include a command
13241 with a blank argument, e.
13242 \begin_inset space \thinspace{}
13248 \begin_layout Standard
13256 \begin_layout Standard
13257 Let's get really fancy: lets put the section number with the word
13258 \begin_inset Quotes eld
13262 \begin_inset Quotes erd
13266 \begin_inset space \thinspace{}
13270 \begin_inset space \space{}
13273 Section 3) in the upper left, the page number (e.
13274 \begin_inset space \thinspace{}
13278 \begin_inset space \space{}
13281 Page 4) in the upper right, your name in the lower left, and the date in
13283 The following commands should now appear in the preamble:
13286 \begin_layout Standard
13296 \begin_layout Standard
13304 \begin_layout Standard
13314 \begin_layout Standard
13323 \begin_layout Standard
13331 \begin_layout Standard
13341 \begin_layout Standard
13343 \begin_inset Flex Code
13346 \begin_layout Plain Layout
13355 \begin_inset Flex Code
13358 \begin_layout Plain Layout
13366 access \SpecialChar LaTeX
13367 's section and page counters, and so print out the current section
13370 \begin_inset Flex Code
13373 \begin_layout Plain Layout
13381 simply prints out today's date.
13384 \begin_layout Standard
13385 The thicknesses of the horizontal rules drawn beneath the header and above
13386 the footer can also be modified.
13387 If you don't want one of the rules, set its thickness to 0.
13388 The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
13394 \begin_inset Flex Code
13397 \begin_layout Plain Layout
13402 headrulewidth}{0.4pt}
13408 \begin_inset Flex Code
13411 \begin_layout Plain Layout
13416 footrulewidth}{0.4pt}
13421 to set the thicknesses.
13424 \begin_layout Standard
13425 You can switch the header/footer settings on and off for individual pages
13426 using commands like
13427 \begin_inset Flex Code
13430 \begin_layout Plain Layout
13433 thispagestyle{empty}
13439 \begin_inset Flex Code
13442 \begin_layout Plain Layout
13445 thispagestyle{plain}
13451 \begin_inset Flex Code
13454 \begin_layout Plain Layout
13457 thispagestyle{fancy}
13463 Simply insert them in the text on the page you want changed and mark them
13464 as \SpecialChar TeX
13466 In fact, title pages are marked as plain by default, while following pages
13467 are marked fancy when using the global fancy setting.
13470 \begin_layout Standard
13471 As a final example, it is possible to include an image in the header or
13473 Suppose you want to put a company logo in the upper lefthand corner.
13474 You might try something like
13477 \begin_layout Standard
13486 includegraphics{logo.eps}}}
13489 \begin_layout Standard
13491 (you may need to preface this with
13492 \begin_inset Flex Code
13495 \begin_layout Plain Layout
13499 usepackage{graphics}
13504 if you don't include graphics elsewhere in your document).
13507 \begin_layout Section
13508 Multiple Text Columns
13511 \begin_layout Standard
13512 This feature is independent of the option
13514 Two-column document
13516 in the document settings under
13521 If you want to have 2
13522 \begin_inset space ~
13525 columns for the whole document, it is recommended to use the
13527 Two-column document
13530 For all other cases use this feature.
13533 \begin_layout Standard
13534 To use multiple text columns in your document, you have to load the module
13541 Document\SpecialChar menuseparator
13542 Settings\SpecialChar menuseparator
13545 ) and must have the \SpecialChar LaTeX
13553 \begin_layout Standard
13554 Footnotes within multiple columns will be placed at the bottom of the page
13555 and not under each column.
13556 Within the different columns you can use everything, with the limitation
13557 that for floats you need to use the float option
13564 \begin_layout Subsection
13568 \begin_layout Standard
13569 If you want to have 2
13570 \begin_inset space ~
13573 columns in your text, insert a multicolumn inset via the menu
13575 Insert\SpecialChar menuseparator
13577 \begin_inset space ~
13580 Insets\SpecialChar menuseparator
13582 \begin_inset space ~
13587 where the columns should start.
13588 Write all text that should be printed in 2
13589 \begin_inset space ~
13592 columns into this inset.
13595 \begin_layout Standard
13596 Here is an example:
13599 \begin_layout Standard
13601 \begin_inset Flex Multiple Columns
13604 \begin_layout Plain Layout
13609 The Adventure of the Empty House
13612 \begin_inset Newline newline
13615 by Sir Arthur Conan Doyle
13618 \begin_layout Plain Layout
13621 It was in the spring of the year 1894 that all London was interested, and
13622 the fashionable world dismayed, by the murder of the Honourable Ronald
13623 Adair under most unusual and inexplicable circumstances.
13624 The public has already learned those particulars of the crime which came
13625 out in the police investigation, but a good deal was suppressed upon that
13626 occasion, since the case for the prosecution was so overwhelmingly strong
13627 that it was not necessary to bring forward all the facts.
13628 Only now, at the end of nearly ten years, am I allowed to supply those
13629 missing links which make up the whole of that remarkable chain.
13630 The crime was of interest in itself, but that interest was as nothing to
13631 me compared to the inconceivable sequel, which afforded me the greatest
13632 shock and surprise of any event in my adventurous life.
13633 Even now, after this long interval, I find myself thrilling as I think
13634 of it, and feeling once more that sudden flood of joy, amazement, and increduli
13635 ty which utterly submerged my mind.
13636 Let me say to that public, which has shown some interest in those glimpses
13637 which I have occasionally given them of the thoughts and actions of a very
13638 remarkable man, that they are not to blame me if I have not shared my knowledge
13639 with them, for I should have considered it my first duty to do so, had
13640 I not been barred by a positive prohibition from his own lips, which was
13641 only withdrawn upon the third of last month.
13649 \begin_layout Standard
13650 To get 3 or more columns, set the cursor into the multicolumn inset and
13653 Insert\SpecialChar menuseparator
13655 \begin_inset space ~
13659 \begin_inset space ~
13665 The number of the desired columns is written into that inset (for 3
13666 \begin_inset space ~
13670 \begin_inset Quotes eld
13674 \begin_inset Quotes erd
13678 \begin_inset Newline newline
13681 Here is an example with 3
13682 \begin_inset space ~
13688 \begin_layout Standard
13689 \begin_inset Flex Multiple Columns
13692 \begin_layout Plain Layout
13695 \begin_inset Argument 1
13698 \begin_layout Plain Layout
13704 It can be imagined that my close intimacy with Sherlock Holmes had interested
13705 me deeply in crime, and that after his disappearance I never failed to
13706 read with care the various problems which came before the public.
13707 And I even attempted, more than once, for my own private satisfaction,
13708 to employ his methods in their solution, though with indifferent success.
13709 There was none, however, which appealed to me like this tragedy of Ronald
13711 As I read the evidence at the inquest, which led up to a verdict of willful
13712 murder against some person or persons unknown, I realized more clearly
13713 than I had ever done the loss which the community had sustained by the
13714 death of Sherlock Holmes.
13715 There were points about this strange business which would, I was sure,
13716 have specially appealed to him, and the efforts of the police would have
13717 been supplemented, or more probably anticipated, by the trained observation
13718 and the alert mind of the first criminal agent in Europe.
13719 All day, as I drove upon my round, I turned over the case in my mind and
13720 found no explanation which appeared to me to be adequate.
13721 At the risk of telling a twice-told tale, I will recapitulate the facts
13722 as they were known to the public at the conclusion of the inquest.
13730 \begin_layout Standard
13731 You can have up to 10
13732 \begin_inset space ~
13735 columns if you want to, but that might not be very pleasant for the readers
13739 \begin_layout Standard
13740 \begin_inset Newpage newpage
13746 \begin_layout Subsection
13747 Columns inside Columns
13750 \begin_layout Standard
13751 You can also have columns inside columns:
13754 \begin_layout Standard
13755 \begin_inset Flex Multiple Columns
13758 \begin_layout Plain Layout
13761 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
13762 at that time governor of one of the Australian colonies.
13763 Adair's mother had returned from Australia to undergo the operation for
13764 cataract, and she, her son Ronald, and her daughter Hilda were living together
13768 \begin_layout Plain Layout
13769 \begin_inset Flex Multiple Columns
13772 \begin_layout Plain Layout
13775 The youth moved in the best society–had, so far as was known, no enemies
13776 and no particular vices.
13777 He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
13778 had been broken off by mutual consent some months before, and there was
13779 no sign that it had left any very profound feeling behind it.
13780 For the rest {sic} the man's life moved in a narrow and conventional circle,
13781 for his habits were quiet and his nature unemotional.
13782 Yet it was upon this easy-going young aristocrat that death came, in most
13783 strange and unexpected form, between the hours of ten and eleven-twenty
13784 on the night of March 30, 1894.
13792 \begin_layout Plain Layout
13795 Ronald Adair was fond of cards–playing continually, but never for such stakes
13797 He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
13798 It was shown that, after dinner on the day of his death, he had played
13799 a rubber of whist at the latter club.
13800 He had also played there in the afternoon.
13805 The evidence of those who had played with him– Mr.
13806 Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
13807 and that there was a fairly equal fall of the cards.
13808 Adair might have lost five pounds, but not more.
13809 His fortune was a considerable one, and such a loss could not in any way
13811 He had played nearly every day at one club or other, but he was a cautious
13812 player, and usually rose a winner.
13813 It came out in evidence that, in partnership with Colonel Moran, he had
13814 actually won as much as four hundred and twenty pounds in a sitting, some
13815 weeks before, from Godfrey Milner and Lord Balmoral.
13816 So much for his recent history as it came out at the inquest.
13824 \begin_layout Subsection
13828 \begin_layout Standard
13829 The examples in this section show some more special features of multiple
13833 \begin_layout Standard
13834 For more features of multiple columns, have a look at the documentation
13835 of the \SpecialChar LaTeX
13841 \begin_inset CommandInset citation
13850 \begin_layout Subsubsection
13854 \begin_layout Standard
13855 To add a preface text for multiple columns, set the cursor into the multicolumn
13856 inset and use the menu
13858 Insert\SpecialChar menuseparator
13862 Write your preface text into that inset.
13863 \begin_inset Newline newline
13866 This is an example with some preface text:
13869 \begin_layout Standard
13870 \begin_inset VSpace bigskip
13876 \begin_layout Standard
13877 \begin_inset Flex Multiple Columns
13880 \begin_layout Plain Layout
13881 \begin_inset Argument 2
13884 \begin_layout Plain Layout
13885 And the story continues and continues and continues and continues\SpecialChar ldots
13893 On the evening of the crime, he returned from the club exactly at ten.
13894 His mother and sister were out spending the evening with a relation.
13895 The servant deposed that she heard him enter the front room on the second
13896 floor, generally used as his sitting-room.
13897 She had lit a fire there, and as it smoked she had opened the window.
13898 No sound was heard from the room until eleven-twenty, the hour of the return
13899 of Lady Maynooth and her daughter.
13900 Desiring to say good-night, she attempted to enter her son's room.
13901 The door was locked on the inside, and no answer could be got to their
13902 cries and knocking.
13903 Help was obtained, and the door forced.
13904 The unfortunate young man was found lying near the table.
13905 His head had been horribly mutilated by an expanding revolver bullet, but
13906 no weapon of any sort was to be found in the room.
13914 \begin_layout Standard
13915 You can also use a section heading as the preface if you use a section command
13916 as \SpecialChar TeX
13918 For example the command
13921 \begin_layout Standard
13926 subsection{subsection title}
13929 \begin_layout Standard
13930 creates a subsection.
13931 In this example the preface is a subsubsection:
13934 \begin_layout Standard
13935 \begin_inset Flex Multiple Columns
13938 \begin_layout Plain Layout
13939 \begin_inset Argument 2
13942 \begin_layout Plain Layout
13946 \begin_layout Plain Layout
13955 This is a subsubsection heading as a preface
13959 \begin_layout Plain Layout
13973 A minute examination of the circumstances served only to make the case more
13975 In the first place, no reason could be given why the young man should have
13976 fastened the door upon the inside.
13977 There was the possibility that the murderer had done this, and had afterwards
13978 escaped by the window.
13979 The drop was at least twenty feet, however, and a bed of crocuses in full
13981 Neither the flowers nor the earth showed any sign of having been disturbed,
13982 nor were there any marks upon the narrow strip of grass which separated
13983 the house from the road.
13984 Apparently, therefore, it was the young man himself who had fastened the
13986 But how did he come by his death? No one could have climbed up to the window
13987 without leaving traces.
13988 Suppose a man had fired through the window, he would indeed be a remarkable
13989 shot who could with a revolver inflict so deadly a wound.
13990 Again, Park Lane is a frequented thoroughfare; there is a cab stand within
13991 a hundred yards of the house.
13992 No one had heard a shot.
14000 \begin_layout Standard
14001 If there is less vertical space than 6
14002 \begin_inset space ~
14005 text lines is left on the page at the beginning of the multiple columns,
14006 a page break will be inserted before the multiple columns.
14007 Depending on the number of lines of the preface text, you might want to
14009 This is done by setting the cursor into the mulitcolumn inset behind the
14010 preface (if there is any) and using the menu
14012 Insert\SpecialChar menuseparator
14014 \begin_inset space ~
14018 \begin_inset space ~
14022 \begin_inset space ~
14028 Insert into that inset the amount of space like e.
14029 \begin_inset space \thinspace{}
14033 \begin_inset space \space{}
14037 \begin_inset Quotes eld
14041 \begin_inset Quotes erd
14045 \begin_inset Newline newline
14048 In this example the space is set to 7
14049 \begin_inset space ~
14052 text lines by using
14053 \begin_inset Quotes eld
14059 \begin_inset Quotes erd
14068 needs to be inserted as \SpecialChar TeX
14072 \begin_layout Standard
14073 \begin_inset Flex Multiple Columns
14076 \begin_layout Plain Layout
14077 \begin_inset Argument 3
14080 \begin_layout Plain Layout
14085 \begin_layout Plain Layout
14101 On the evening of the crime, he returned from the club exactly at ten.
14102 His mother and sister were out spending the evening with a relation.
14103 The servant deposed that she heard him enter the front room on the second
14104 floor, generally used as his sitting-room.
14105 She had lit a fire there, and as it smoked she had opened the window.
14106 No sound was heard from the room until eleven-twenty, the hour of the return
14107 of Lady Maynooth and her daughter.
14108 Desiring to say good-night, she attempted to enter her son's room.
14109 The door was locked on the inside, and no answer could be got to their
14110 cries and knocking.
14111 Help was obtained, and the door forced.
14112 The unfortunate young man was found lying near the table.
14113 His head had been horribly mutilated by an expanding revolver bullet, but
14114 no weapon of any sort was to be found in the room.
14122 \begin_layout Subsubsection
14126 \begin_layout Standard
14127 The amount of space before and after multiple columns can be changed by
14128 changing the length
14135 For example the command
14138 \begin_layout Standard
14148 \begin_layout Standard
14149 in \SpecialChar TeX
14150 Code changes its value to 3
14151 \begin_inset space \thinspace{}
14155 The change must be made before the multiple columns' start.
14156 The predefined value is 13
14157 \begin_inset space \thinspace{}
14163 \begin_layout Standard
14171 \begin_inset space \thinspace{}
14177 \begin_layout Standard
14181 \begin_layout Plain Layout
14187 multicolsep}{2.5cm}
14195 \begin_layout Standard
14196 \begin_inset Flex Multiple Columns
14199 \begin_layout Plain Layout
14202 All day I turned these facts over in my mind, endeavouring to hit upon some
14203 theory which could reconcile them all, and to find that line of least resistanc
14204 e which my poor friend had declared to be the starting-point of every investigat
14206 I confess that I made little progress.
14207 In the evening I strolled across the Park, and found myself about six o'clock
14208 at the Oxford Street end of Park Lane.
14209 A group of loafers upon the pavements, all staring up at a particular window,
14210 directed me to the house which I had come to see.
14211 A tall, thin man with coloured glasses, whom I strongly suspected of being
14212 a plain-clothes detective, was pointing out some theory of his own, while
14213 the others crowded round to listen to what he said.
14214 I got as near him as I could, but his observations seemed to me to be absurd,
14215 so I withdrew again in some disgust.
14216 As I did so I struck against an elderly, deformed man, who had been behind
14217 me, and I knocked down several books which he was carrying.
14225 \begin_layout Standard
14226 \begin_inset Note Greyedout
14229 \begin_layout Plain Layout
14234 The values you set with
14240 will be used for all following multiple columns until you change them again.
14248 \begin_layout Standard
14252 \begin_layout Plain Layout
14264 \begin_inset Note Note
14267 \begin_layout Plain Layout
14268 go back to the default
14276 \begin_layout Standard
14277 \begin_inset Newpage newpage
14283 \begin_layout Subsubsection
14287 \begin_layout Standard
14288 A column break can be forced by inserting the command
14294 as \SpecialChar TeX
14295 Code to that position in the text where the column should be broken.
14296 Note that this leads in most cases to whitespace in the text.
14297 \begin_inset Newline newline
14300 Here is an example:
14303 \begin_layout Standard
14304 \begin_inset Flex Multiple Columns
14307 \begin_layout Plain Layout
14310 \begin_inset Quotes eld
14313 You're surprised to see me, sir,
14314 \begin_inset Quotes erd
14317 said he, in a strange, croaking voice.
14320 \begin_layout Plain Layout
14323 I acknowledged that I was.
14326 \begin_layout Plain Layout
14329 \begin_inset Quotes eld
14332 Well, I've a conscience, sir, and when I chanced to see you go into this
14333 house, as I came hobbling after you, I thought to myself, I'll just step
14334 in and see that kind gentleman, and tell him that if I was a bit gruff
14335 in my manner there was not any harm meant, and that I am much obliged to
14336 him for picking up my books.
14337 \begin_inset Quotes erd
14343 \begin_layout Plain Layout
14346 \begin_inset Quotes eld
14349 You make too much of a trifle,
14350 \begin_inset Quotes erd
14355 \begin_inset Quotes eld
14358 May I ask how you knew who I was?
14359 \begin_inset Quotes erd
14362 AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
14366 \begin_layout Plain Layout
14378 \begin_layout Plain Layout
14381 \begin_inset Quotes eld
14384 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14385 you'll find my little bookshop at the corner of Church Street, and very
14386 happy to see you, I am sure.
14387 Maybe you collect yourself, sir.
14391 \begin_inset space ~
14404 –a bargain, every one of them.
14405 With five volumes you could just fill that gap on that second shelf.
14406 It looks untidy, does it not, sir?
14407 \begin_inset Quotes erd
14418 \begin_layout Subsubsection
14422 \begin_layout Standard
14423 The width of the columns is automatically calculated, but you can modify
14424 the space between the columns.
14425 This is done by changing the length
14432 Its predefined value is 10
14433 \begin_inset space \thinspace{}
14437 Here is an example where
14444 \begin_inset space \thinspace{}
14450 \begin_layout Standard
14454 \begin_layout Plain Layout
14468 \begin_layout Standard
14469 \begin_inset Flex Multiple Columns
14472 \begin_layout Plain Layout
14475 My observations of No.
14476 \begin_inset space \space{}
14479 427 Park Lane did little to clear up the problem in which I was interested.
14480 The house was separated from the street by a low wall and railing, the
14481 whole not more than five feet high.
14482 It was perfectly easy, therefore, for anyone to get into the garden, but
14483 the window was entirely inaccessible, since there was no water pipe or
14484 anything which could help the most active man to climb it.
14485 More puzzled than ever, I retraced my steps to Kensington.
14486 I had not been in my study five minutes when the maid entered to say that
14487 a person desired to see me.
14488 To my astonishment it was none other than my strange old book collector,
14489 his sharp, wizened face peering out from a frame of white hair, and his
14490 precious volumes, a dozen of them at least, wedged under his right arm.
14498 \begin_layout Standard
14502 \begin_layout Plain Layout
14514 \begin_inset Note Note
14517 \begin_layout Plain Layout
14518 go back to the default
14526 \begin_layout Subsubsection
14530 \begin_layout Standard
14531 Between the columns a rule with a width of the length
14538 If this rule width is set to 0
14539 \begin_inset space \thinspace{}
14542 pt (this is the default), the rule is suppressed.
14543 In the following example the rule is 2
14544 \begin_inset space \thinspace{}
14550 \begin_layout Standard
14554 \begin_layout Plain Layout
14560 columnseprule}{2pt}
14568 \begin_layout Standard
14569 \begin_inset Flex Multiple Columns
14572 \begin_layout Plain Layout
14575 \begin_inset Quotes eld
14578 You're surprised to see me, sir,
14579 \begin_inset Quotes erd
14582 said he, in a strange, croaking voice.
14585 \begin_layout Plain Layout
14588 I acknowledged that I was.
14591 \begin_layout Plain Layout
14594 \begin_inset Quotes eld
14597 Well, I've a conscience, sir, and when I chanced to see you go into this
14598 house, as I came hobbling after you, I thought to myself, I'll just step
14599 in and see that kind gentleman, and tell him that if I was a bit gruff
14600 in my manner there was not any harm meant, and that I am much obliged to
14601 him for picking up my books.
14602 \begin_inset Quotes erd
14608 \begin_layout Plain Layout
14611 \begin_inset Quotes eld
14614 You make too much of a trifle,
14615 \begin_inset Quotes erd
14620 \begin_inset Quotes eld
14623 May I ask how you knew who I was?
14624 \begin_inset Quotes erd
14630 \begin_layout Plain Layout
14633 \begin_inset Quotes eld
14636 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14637 you'll find my little bookshop at the corner of Church Street, and very
14638 happy to see you, I am sure.
14639 Maybe you collect yourself, sir.
14643 \begin_inset space ~
14656 –a bargain, every one of them.
14657 With five volumes you could just fill that gap on that second shelf.
14658 It looks untidy, does it not, sir?
14659 \begin_inset Quotes erd
14670 \begin_layout Standard
14671 \begin_inset VSpace defskip
14677 \begin_layout Standard
14678 The rule can be colored by redefining the command
14685 This is done by inserting the command
14686 \begin_inset Newline newline
14695 columnseprulecolor}{
14700 \begin_inset Newline newline
14703 as \SpecialChar TeX
14704 Code before the multicolumn inset.
14709 in this command by a color of your choice.
14710 You can use all pre- and self-defined colors.
14718 \begin_inset space ~
14723 for more information about pre- and self-defined colors.
14724 To go back to the default color insert the command
14725 \begin_inset Newline newline
14734 columnseprulecolor}{
14739 \begin_inset Newline newline
14742 Here is the example with a cyan rule and 1
14743 \begin_inset space \thinspace{}
14746 cm column separation:
14749 \begin_layout Standard
14753 \begin_layout Plain Layout
14762 \begin_layout Plain Layout
14768 columnseprulecolor}{
14778 \begin_layout Standard
14779 \begin_inset Flex Multiple Columns
14782 \begin_layout Plain Layout
14785 \begin_inset Quotes eld
14788 You're surprised to see me, sir,
14789 \begin_inset Quotes erd
14792 said he, in a strange, croaking voice.
14795 \begin_layout Plain Layout
14798 I acknowledged that I was.
14801 \begin_layout Plain Layout
14804 \begin_inset Quotes eld
14807 Well, I've a conscience, sir, and when I chanced to see you go into this
14808 house, as I came hobbling after you, I thought to myself, I'll just step
14809 in and see that kind gentleman, and tell him that if I was a bit gruff
14810 in my manner there was not any harm meant, and that I am much obliged to
14811 him for picking up my books.
14812 \begin_inset Quotes erd
14818 \begin_layout Plain Layout
14821 \begin_inset Quotes eld
14824 You make too much of a trifle,
14825 \begin_inset Quotes erd
14830 \begin_inset Quotes eld
14833 May I ask how you knew who I was?
14834 \begin_inset Quotes erd
14840 \begin_layout Plain Layout
14843 \begin_inset Quotes eld
14846 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14847 you'll find my little bookshop at the corner of Church Street, and very
14848 happy to see you, I am sure.
14849 Maybe you collect yourself, sir.
14853 \begin_inset space ~
14866 –a bargain, every one of them.
14867 With five volumes you could just fill that gap on that second shelf.
14868 It looks untidy, does it not, sir?
14869 \begin_inset Quotes erd
14880 \begin_layout Standard
14884 \begin_layout Plain Layout
14890 columnseprule}{0pt}
14893 \begin_layout Plain Layout
14899 columnseprulecolor}{
14907 \begin_inset Note Note
14910 \begin_layout Plain Layout
14911 go back to the default
14919 \begin_layout Chapter
14921 \change_inserted 893223064 1464852301
14925 \begin_layout Section
14926 Non-standard Paragraph Shapes
14929 \begin_layout Standard
14932 as well as any other text processor uses by default rectangular paragraphs.
14933 For special cases like for example posters, invitation cards or poems you
14934 can modify the paragraph shape to one of your choice.
14935 This can be done by using the \SpecialChar LaTeX
14940 which is loaded by using in the document settings the module
14942 Custom paragraph shapes
14947 \begin_layout Subsection
14951 \begin_layout Standard
14956 provides the following shapes:
14959 \begin_layout Standard
14960 \begin_inset Tabular
14961 <lyxtabular version="3" rows="13" columns="3">
14962 <features booktabs="true" islongtable="true" longtabularalignment="center">
14963 <column alignment="center" valignment="middle" width="16col%">
14964 <column alignment="center" valignment="middle" width="40col%">
14965 <column alignment="center" valignment="middle" width="35col%">
14966 <row endhead="true">
14967 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
14970 \begin_layout Plain Layout
14976 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
14979 \begin_layout Plain Layout
14985 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
14988 \begin_layout Plain Layout
14996 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
14999 \begin_layout Plain Layout
15005 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15008 \begin_layout Plain Layout
15009 Circle with circular hole (in the size of a CD/DVD)
15014 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15017 \begin_layout Plain Layout
15018 Cannot be scaled, take care there is not too much text
15025 <cell alignment="center" valignment="top" topline="true" usebox="none">
15028 \begin_layout Plain Layout
15034 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15037 \begin_layout Plain Layout
15043 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15046 \begin_layout Plain Layout
15047 Fragile, calculation might fail
15054 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15057 \begin_layout Plain Layout
15063 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15066 \begin_layout Plain Layout
15067 Rhomboid (symbolizing a
15068 \begin_inset Quotes eld
15072 \begin_inset Quotes erd
15080 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15083 \begin_layout Plain Layout
15091 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15094 \begin_layout Plain Layout
15100 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15103 \begin_layout Plain Layout
15109 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15112 \begin_layout Plain Layout
15120 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15123 \begin_layout Plain Layout
15129 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15132 \begin_layout Plain Layout
15138 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15141 \begin_layout Plain Layout
15149 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15152 \begin_layout Plain Layout
15158 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15161 \begin_layout Plain Layout
15162 Nut for bolt (hexagon with circular hole)
15167 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15170 \begin_layout Plain Layout
15178 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15181 \begin_layout Plain Layout
15187 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15190 \begin_layout Plain Layout
15196 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15199 \begin_layout Plain Layout
15207 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15210 \begin_layout Plain Layout
15216 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15219 \begin_layout Plain Layout
15225 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
15228 \begin_layout Plain Layout
15236 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15239 \begin_layout Plain Layout
15245 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15248 \begin_layout Plain Layout
15254 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15257 \begin_layout Plain Layout
15265 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15268 \begin_layout Plain Layout
15274 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15277 \begin_layout Plain Layout
15278 Normal/reversed rain drop
15283 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15286 \begin_layout Plain Layout
15287 Fragile, calculation might fail
15294 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15297 \begin_layout Plain Layout
15304 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15307 \begin_layout Plain Layout
15308 The \SpecialChar TeX
15314 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15317 \begin_layout Plain Layout
15325 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15328 \begin_layout Plain Layout
15330 \begin_inset Newline newline
15338 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15341 \begin_layout Plain Layout
15342 Triangles in different orientations
15347 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
15350 \begin_layout Plain Layout
15364 \begin_layout Standard
15365 To use a shape for your paragraph, simply select it in \SpecialChar LyX
15367 for environments in the toolbar.
15370 \begin_layout Standard
15371 \begin_inset Newpage newpage
15377 \begin_layout Standard
15378 Here is an example paragraph in the shape of a nut:
15381 \begin_layout Standard
15382 \begin_inset VSpace bigskip
15391 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15392 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15394 At vero eos et accusam et justo duo dolores et ea rebum.
15395 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15397 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15398 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15402 \begin_layout Standard
15403 \begin_inset VSpace bigskip
15409 \begin_layout Standard
15410 \begin_inset Note Greyedout
15413 \begin_layout Plain Layout
15418 : shapepar paragraphs cannot run over a page break.
15426 \begin_layout Standard
15427 \begin_inset VSpace bigskip
15433 \begin_layout Standard
15438 takes care that the shape will always be preserved, no matter how much
15439 text is in the paragraph.
15440 Therefore the paragraph size changes with the amount of contained text.
15441 This can lead to paragraph sizes exceeding the page margins.
15442 To demonstrate the size scaling, here is the same example paragraph but
15443 with twice as much text:
15446 \begin_layout Standard
15447 \begin_inset Newpage newpage
15456 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15457 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15459 At vero eos et accusam et justo duo dolores et ea rebum.
15460 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15462 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15463 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15465 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15466 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15468 At vero eos et accusam et justo duo dolores et ea rebum.
15469 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15471 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15472 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15476 \begin_layout Standard
15477 \begin_inset VSpace bigskip
15483 \begin_layout Standard
15484 An exception is the shape
15489 It cannot be scaled because it must fit the size of a CD/DVD.
15490 Therefore the amount of text that fits into the shape is limited.
15491 \begin_inset Newline newline
15502 shape are fragile, meaning that the calculation of their size can fail,
15503 depending on the amount of text.
15504 You will then get the \SpecialChar LaTeX
15506 \begin_inset Quotes eld
15509 Arithmetic overflow
15510 \begin_inset Quotes erd
15514 In this case one can try to remove or add some text; if nothing works one
15515 has to use another shape.
15518 \begin_layout Standard
15519 \begin_inset VSpace bigskip
15525 \begin_layout Standard
15526 For shapes with tips you will maybe see that \SpecialChar LaTeX
15527 's hyphenation routine fails
15528 for text in the tips.
15529 Therefore it is often necessary to add hyphenation points
15534 arg "specialchar-insert hyphenation"
15539 ) to the corresponding text parts.
15542 \begin_layout Standard
15543 \begin_inset VSpace bigskip
15549 \begin_layout Standard
15550 Shapepar paragraphs are either always centered or placed on the page so
15551 that their left border touches the left page margin.
15552 You can therefore not use the paragraph dialog to align such paragraphs.
15553 A solution is to put the paragraph into a minipage or parbox and align
15555 The problem is hereby to find the right width for the box.
15556 Because if it is too wide and you center the box, the paragraph is not
15557 centered too because it sticks at the left side of the box.
15558 So you might have to play a bit with the width until it fits.
15559 Here are two heart-shaped paragraphs, the first one is not aligned, the
15560 second one is right-aligned:
15563 \begin_layout Standard
15564 \begin_inset Newpage newpage
15570 \begin_layout Heart
15574 Lo\SpecialChar softhyphen
15575 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15576 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15578 At vero eos et accusam et justo duo dolores et ea rebum.
15579 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15583 \begin_layout Standard
15584 \begin_inset VSpace bigskip
15590 \begin_layout Standard
15593 \begin_inset Box Frameless
15603 height_special "totalheight"
15608 backgroundcolor "none"
15611 \begin_layout Heart
15615 Lo\SpecialChar softhyphen
15616 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15617 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15619 At vero eos et accusam et justo duo dolores et ea rebum.
15620 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15629 \begin_layout Subsection
15633 \begin_layout Standard
15634 You can define any shape you want.
15635 Doing this manually is a lot of work because every coordinate must be specified.
15636 But there is a way to let the computer calculate the coordinates:
15639 \begin_layout Enumerate
15640 Install the program
15641 \begin_inset CommandInset href
15644 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
15651 \begin_layout Enumerate
15658 TeX/LaTeX\SpecialChar menuseparator
15659 Settings\SpecialChar menuseparator
15662 and select the font size you are using in your document.
15663 For example this document uses the size 12
15664 \begin_inset space \thinspace{}
15670 \begin_layout Enumerate
15674 \begin_layout Enumerate
15677 TeX/LaTeX\SpecialChar menuseparator
15680 to export the shape to coordinates.
15681 In the appearing dialog use either the outline of your shape for the coordinate
15682 s or the path itself.
15686 \begin_layout Plain Layout
15687 For more information see
15688 \begin_inset CommandInset href
15690 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
15702 \begin_layout Standard
15703 The coordinates are written into a \SpecialChar TeX
15705 To use it for your \SpecialChar LyX
15709 \begin_layout Enumerate
15710 Place the cursor before the first character of your paragraph (or into a
15714 \begin_layout Enumerate
15715 Open in \SpecialChar LyX
15718 Insert\SpecialChar menuseparator
15719 File\SpecialChar menuseparator
15721 \begin_inset space ~
15726 , select the file and use
15735 \begin_layout Standard
15736 \begin_inset VSpace defskip
15742 \begin_layout Standard
15743 \begin_inset Note Greyedout
15746 \begin_layout Plain Layout
15751 : The changed shape only applies to the current paragraph; everything is
15752 reset to normal for the next paragraph.
15753 Therefore the shape definition file must be input into every paragraph
15754 with the desired shape.
15762 \begin_layout Standard
15763 \begin_inset VSpace bigskip
15769 \begin_layout Standard
15770 Here is an example:
15773 \begin_layout Standard
15774 \begin_inset VSpace bigskip
15780 \begin_layout Standard
15781 \begin_inset CommandInset include
15783 filename "/usr/share/lyx/doc/SpecialParagraphShape.tex"
15789 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15790 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15792 At vero eos et accusam et justo duo dolores et ea rebum.
15793 Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15795 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15796 eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15800 \begin_layout Standard
15801 \begin_inset VSpace bigskip
15807 \begin_layout Standard
15812 to draw complexer shapes in
15816 you can draw the shape in a program of your choice and import the resulting
15822 Then you only need to draw a line or spline along the outline of the image.
15825 \begin_layout Standard
15826 \begin_inset VSpace bigskip
15832 \begin_layout Standard
15835 Custom paragraph shapes
15837 also provides the two commands
15845 which can be used to define custom shapes coordinate by coordinate.
15849 \begin_layout Plain Layout
15850 These commands are internally used for all shapes described here.
15855 For information how these styles are used and about further customization
15856 possibilities, have a look at the documentation of the package
15861 \begin_inset CommandInset citation
15870 \begin_layout Bibliography
15871 \begin_inset CommandInset bibitem
15872 LatexCommand bibitem
15877 Documentation of the \SpecialChar LaTeX
15879 \begin_inset CommandInset href
15882 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
15889 \begin_layout Bibliography
15890 \begin_inset CommandInset bibitem
15891 LatexCommand bibitem
15896 Documentation of the \SpecialChar LaTeX
15898 \begin_inset CommandInset href
15901 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"
15908 \begin_layout Chapter
15910 \change_inserted 893223064 1464852414
15911 Bibliographic databases
15912 \change_deleted 893223064 1464852406
15918 \begin_layout Section
15919 Customizing Bibliographies with Bib\SpecialChar TeX
15923 \begin_layout Standard
15924 The most basic information about how to use Bib\SpecialChar TeX
15925 with \SpecialChar LyX
15926 is contained in the
15929 Bibliography databases (Bib\SpecialChar TeX
15937 The following subsections explain special bibliography features supported
15938 by \SpecialChar LyX
15942 \begin_layout Subsection
15943 Alternative Citation Styles
15946 \begin_layout Standard
15947 Standard Bib\SpecialChar TeX
15949 \begin_inset space \thinspace{}
15953 \begin_inset space \space{}
15957 \begin_inset Quotes eld
15961 \begin_inset Quotes erd
15964 ) to refer to a cited work.
15965 However, in many scientific disciplines, other citation styles are in use.
15966 The most common one is the author-year style (e.
15967 \begin_inset space \thinspace{}
15971 \begin_inset space \space{}
15975 \begin_inset Quotes eld
15979 \begin_inset Quotes erd
15984 supports two packages that provide this style,
15985 \begin_inset Flex Code
15988 \begin_layout Plain Layout
15995 \begin_inset Flex Code
15998 \begin_layout Plain Layout
16005 Both packages have their pros and cons, which cannot be listed in detail.
16006 If you only want to have simple author-year (or author-numerical) style,
16007 or if you want to use one of the countless style files for
16008 \begin_inset Flex Code
16011 \begin_layout Plain Layout
16017 , then the established
16018 \begin_inset Flex Code
16021 \begin_layout Plain Layout
16027 package is probably your choice.
16028 If you need special features like short title references, ibidem etc., you
16030 \begin_inset Flex Code
16033 \begin_layout Plain Layout
16042 \begin_layout Standard
16043 The handling of both packages in \SpecialChar LyX
16044 is basically the same.
16046 \begin_inset Flex Noun
16049 \begin_layout Plain Layout
16050 Document\SpecialChar menuseparator
16057 \begin_inset Flex Noun
16060 \begin_layout Plain Layout
16067 \begin_inset Flex Noun
16070 \begin_layout Plain Layout
16077 \begin_inset Flex Noun
16080 \begin_layout Plain Layout
16087 With both packages, you will get some extra features in the citation dialog
16088 and you can select the style of the reference (
16089 \begin_inset Quotes eld
16093 \begin_inset Quotes erd
16097 \begin_inset Quotes eld
16101 \begin_inset Quotes erd
16105 \begin_inset Quotes eld
16109 \begin_inset Quotes erd
16113 \begin_inset Quotes eld
16117 \begin_inset Quotes erd
16121 Note that both packages need specifically designed style files.
16122 They both ship their own, but there are lots of additional style files,
16123 and there is even an interactive style file builder
16127 \begin_layout Plain Layout
16129 \begin_inset Flex URL
16132 \begin_layout Plain Layout
16134 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
16145 \begin_inset Flex Code
16148 \begin_layout Plain Layout
16157 \begin_layout Subsection
16158 Sectioned Bibliographies
16161 \begin_layout Standard
16162 Sometimes you might need to divide your bibliography into several sections.
16163 If you are for instance a historian, the possibility to separate sources
16164 and scientific works is most likely a
16165 \begin_inset Quotes eld
16169 \begin_inset Quotes erd
16173 Unfortunately, Bib\SpecialChar TeX
16174 itself does not allow you to do this.
16175 But with the help of some \SpecialChar LaTeX
16176 packages, Bib\SpecialChar TeX
16177 can be extended to fit your needs.
16180 \begin_layout Standard
16182 provides native support for one of these packages,
16190 \begin_layout Plain Layout
16192 \begin_inset Flex URL
16195 \begin_layout Plain Layout
16197 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
16207 The advantage of this package (compared to other packages like
16211 ) is that you don't need to define new citation commands.
16212 Instead, you need to prepare different bibliographic databases which include
16213 the entries for the different sections of the bibliography.
16214 For example: If you want to divide your bibliography into the sections
16216 \begin_inset Quotes eld
16220 \begin_inset Quotes erd
16224 \begin_inset Quotes eld
16228 \begin_inset Quotes erd
16231 , you first need to create two bibliographic databases, e.
16232 \begin_inset space \thinspace{}
16236 \begin_inset space \space{}
16240 \begin_inset Flex Code
16243 \begin_layout Plain Layout
16250 \begin_inset Flex Code
16253 \begin_layout Plain Layout
16263 \begin_layout Standard
16265 \begin_inset Flex Noun
16268 \begin_layout Plain Layout
16269 Document\SpecialChar menuseparator
16276 \begin_inset Flex Noun
16279 \begin_layout Plain Layout
16286 \begin_inset Flex Noun
16289 \begin_layout Plain Layout
16290 Sectioned bibliography
16296 Now you can insert multiple Bib\SpecialChar TeX
16297 bibliographies, one for each section of
16299 Returning to our example: Insert the Bib\SpecialChar TeX
16301 \begin_inset Flex Code
16304 \begin_layout Plain Layout
16310 and a second one for the database
16311 \begin_inset Flex Code
16314 \begin_layout Plain Layout
16321 You are free to use the same or different styles for each section.
16322 Additionally, you can choose if the bibliography section should contain
16324 \begin_inset Quotes eld
16327 all cited references
16328 \begin_inset Quotes erd
16331 of the specified database(s) (which is the default),
16332 \begin_inset Quotes eld
16335 all uncited references
16336 \begin_inset Quotes erd
16340 \begin_inset Quotes eld
16344 \begin_inset Quotes erd
16348 This might be useful if you would like to separate your bibliography into
16350 \begin_inset Quotes eld
16354 \begin_inset Quotes erd
16358 \begin_inset Quotes eld
16362 \begin_inset Quotes erd
16366 \begin_inset Quotes eld
16370 \begin_inset Quotes erd
16374 The titles for the sections can be added as ordinary sections or subsections.
16376 \begin_inset Flex Code
16379 \begin_layout Plain Layout
16385 removes the bibliography title, you have to manually re-add that, too (as
16386 a chapter* or section*, for instance).
16389 \begin_layout Subsection
16390 Multiple Bibliographies
16393 \begin_layout Standard
16394 Multiple bibliographies, e.
16395 \begin_inset space \thinspace{}
16399 \begin_inset space \space{}
16402 a bibliography for each section or chapter of the document, are not supported
16403 by Bib\SpecialChar TeX
16406 \begin_inset Flex Code
16409 \begin_layout Plain Layout
16415 package, which is used for the creation of sectioned bibliographies in
16417 (see the previous section), provides an easy way to solve this task, if
16418 you are willing to use some
16419 \begin_inset Flex Noun
16422 \begin_layout Plain Layout
16430 \begin_inset space ~
16434 \begin_inset CommandInset ref
16436 reference "sec:Inserting-TeX-Code"
16444 \begin_layout Plain Layout
16445 An alternative approach is to use the
16446 \begin_inset Flex Code
16449 \begin_layout Plain Layout
16456 \begin_inset Flex Code
16459 \begin_layout Plain Layout
16465 package, respectively.
16473 \begin_layout Standard
16475 \begin_inset Flex Noun
16478 \begin_layout Plain Layout
16479 Document\SpecialChar menuseparator
16486 \begin_inset Flex Noun
16489 \begin_layout Plain Layout
16496 \begin_inset Flex Noun
16499 \begin_layout Plain Layout
16500 Sectioned bibliography
16506 In the document, you have to enclose the sections, which shall contain
16507 their own bibliography (including the Bib\SpecialChar TeX
16508 bibliography itself), between
16510 \begin_inset Flex Code
16513 \begin_layout Plain Layout
16522 \begin_inset Flex Code
16525 \begin_layout Plain Layout
16533 (those commands have to be inserted as \SpecialChar TeX
16535 The bibliography will contain all references that have been cited in the
16537 \begin_inset Flex Code
16540 \begin_layout Plain Layout
16551 If you are using this approach, then every citation reference has to be
16553 \begin_inset Flex Code
16556 \begin_layout Plain Layout
16564 \begin_inset Flex Code
16567 \begin_layout Plain Layout
16573 s cannot be nested.
16576 \begin_layout Chapter
16577 Multipart Documents
16580 \begin_layout Section
16584 \begin_layout Standard
16585 When you are working on a large file with many sections, it is often convenient
16586 to break up the document into several files, or perhaps you have something
16587 where a table may change from time to time, but the preceding text does
16589 In these cases, you should seriously consider using multipart documents.
16590 For example, scientific papers often have five major sections: the introduction
16591 , observations, results, discussion, and conclusion.
16592 Each of these could be its own separate \SpecialChar LyX
16594 \begin_inset Quotes eld
16598 \begin_inset Quotes erd
16601 file which contains the title, authors, abstract, references, etc., plus
16602 the five included files.
16603 It is important to note that each of these files is a full \SpecialChar LyX
16605 can be formatted and printed on its own, as well as included in a master
16607 Each of these files must have the same document class, however—don't attempt
16608 to mix book classes with article classes.
16609 You may also include \SpecialChar LaTeX
16610 files; however, these files must not have their own
16612 \begin_inset space \thinspace{}
16616 \begin_inset space \space{}
16619 everything up to and including the
16620 \begin_inset Flex Code
16623 \begin_layout Plain Layout
16631 line as well as the
16632 \begin_inset Flex Code
16635 \begin_layout Plain Layout
16643 line must be deleted) or else errors will be generated when you try to
16647 \begin_layout Standard
16649 allows you to include files quite easily with
16650 \begin_inset Flex Noun
16653 \begin_layout Plain Layout
16654 Insert\SpecialChar menuseparator
16656 \begin_inset space ~
16665 When you click on this selection a small box is inserted into the file
16666 at the current cursor location.
16667 Clicking on the box raises a dialog which allows you to select the file
16668 to be included, and the method of its inclusion.
16672 \begin_layout Standard
16673 The file selection box should by now be obvious.
16674 The three inclusion methods are
16675 \begin_inset Quotes eld
16679 \begin_inset Quotes erd
16683 \begin_inset Quotes eld
16687 \begin_inset Quotes erd
16691 \begin_inset Quotes eld
16695 \begin_inset Quotes erd
16699 The difference between
16700 \begin_inset Quotes eld
16704 \begin_inset Quotes erd
16708 \begin_inset Quotes eld
16712 \begin_inset Quotes erd
16715 is really only meaningful to \SpecialChar LaTeX
16716 perts, but the practical difference is that
16718 \begin_inset Quotes eld
16722 \begin_inset Quotes erd
16725 are typeset beginning on a new page, while files that are
16726 \begin_inset Quotes eld
16730 \begin_inset Quotes erd
16733 are typeset starting on the current page.
16736 \begin_layout Standard
16737 Generally, the master file is converted into a full \SpecialChar LaTeX
16738 file before typesetting,
16739 while the included files are converted to \SpecialChar LaTeX
16740 files that do not have all the
16741 preamble information.
16744 \begin_layout Standard
16746 \begin_inset Quotes eld
16750 \begin_inset Quotes erd
16753 included file allows you to include a file typeset exactly as it appears
16755 \begin_inset space \thinspace{}
16759 \begin_inset space \space{}
16763 \begin_inset Flex Code
16766 \begin_layout Plain Layout
16772 mode, with the characters set in a fixed-width typewriter font.
16773 Normally, spaces in this file are invisible, though two consecutive spaces
16774 are conserved, unlike \SpecialChar LyX
16775 's normal treatment of spaces.
16776 However, setting the
16777 \begin_inset Flex Noun
16780 \begin_layout Plain Layout
16782 \begin_inset space ~
16786 \begin_inset space ~
16790 \begin_inset space ~
16798 checkbox typesets a mark to unambiguously define the presence of a space.
16802 \begin_layout Section
16803 Cross-References Between Files
16806 \begin_layout Standard
16807 \begin_inset Box Shadowbox
16817 height_special "totalheight"
16822 backgroundcolor "none"
16825 \begin_layout Plain Layout
16826 This section is somewhat out of date.
16827 Need to describe default master documents and how children are opened when
16837 \begin_layout Standard
16838 It is possible to set up cross-references between the different files.
16839 First, open all the files in question: let's call them A and B in a two
16840 file example, where B is included in A.
16841 Let's say you insert a label in A, then want to reference it in B.
16842 Open the cross-reference dialog whilst in document B, and you can select
16844 \begin_inset Quotes eld
16848 \begin_inset Quotes erd
16854 \begin_layout Section
16855 Bibliography Lists in all Subdocuments
16858 \begin_layout Standard
16859 \begin_inset Box Frameless
16869 height_special "totalheight"
16874 backgroundcolor "none"
16877 \begin_layout Plain Layout
16878 This section also needs updating.
16879 There is now material about this on the wiki, and it could be copied here.
16887 \begin_layout Standard
16888 Copy the bibliography list with all entries to all subdocuments and transform
16890 This way \SpecialChar LyX
16892 \begin_inset Flex Code
16895 \begin_layout Plain Layout
16901 -files and you can easily insert references without making the bibliography
16905 \begin_layout Standard
16906 As the bibliography list is in a comment, \SpecialChar LaTeX
16907 won't use it and the references
16908 will look like this: [?], instead of like this: [1].
16909 One solution is to use the \SpecialChar LaTeX
16911 \begin_inset Flex Code
16914 \begin_layout Plain Layout
16920 that will only include comments by processing the files separately.
16921 To do this, add in the \SpecialChar LaTeX
16922 preamble of every subdocument the following:
16925 \begin_layout LyX-Code
16928 usepackage{comment}
16931 \begin_layout LyX-Code
16934 includecomment{comment}
16937 \begin_layout Standard
16939 \begin_inset Flex URL
16942 \begin_layout Plain Layout
16944 http://wiki.lyx.org/FAQ/Unsorted#toc31
16952 \begin_layout Section
16953 Itemize Bullet Selection
16954 \begin_inset CommandInset label
16963 \begin_layout Standard
16969 \begin_layout Subsection
16973 \begin_layout Standard
16975 provides 216 bullet shapes that can be accessed from a simple dialog.
16976 Using this dialog you can easily specify what bullet shape to use at each
16977 level of an itemized list.
16978 These settings are document-wide so you won't be able to specify different
16979 sets of bullets for different paragraphs.
16983 \begin_layout Plain Layout
16984 Well, actually you can but you'll have to do it by hand.
16992 \begin_layout Subsection
16996 \begin_layout Standard
16997 Open the dialog by selecting the
16998 \begin_inset Flex Noun
17001 \begin_layout Plain Layout
17002 Document\SpecialChar menuseparator
17008 menu item and then select the
17009 \begin_inset Flex Noun
17012 \begin_layout Plain Layout
17021 \begin_layout Standard
17022 The dialog provides you with a table of bullet shapes.
17023 A column of buttons on the left of the table provides access to the six
17024 different panels of bullet shapes.
17025 The row of buttons across the top is used to select which bullet depth
17027 A text entry under the table shows the currently selected bullet shape's
17029 equivalent and this can be edited if desired.
17030 If you do modify the text you will also need to specify any needed packages
17031 in the \SpecialChar LaTeX
17035 \begin_layout Standard
17036 The six panels are divided up by the packages they require.
17037 The following table shows the mappings from button name to \SpecialChar LaTeX
17039 \begin_inset Separator latexpar
17045 \begin_layout Standard
17047 \begin_inset Tabular
17048 <lyxtabular version="3" rows="7" columns="2">
17049 <features tabularvalignment="middle">
17050 <column alignment="center" valignment="top" width="0pt">
17051 <column alignment="center" valignment="top" width="0pt">
17053 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
17056 \begin_layout Plain Layout
17071 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
17074 \begin_layout Plain Layout
17091 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17094 \begin_layout Plain Layout
17109 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17112 \begin_layout Plain Layout
17121 base \SpecialChar LaTeX
17129 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17132 \begin_layout Plain Layout
17147 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17150 \begin_layout Plain Layout
17167 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17170 \begin_layout Plain Layout
17185 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17188 \begin_layout Plain Layout
17205 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17208 \begin_layout Plain Layout
17223 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17226 \begin_layout Plain Layout
17243 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17246 \begin_layout Plain Layout
17261 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17264 \begin_layout Plain Layout
17281 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
17284 \begin_layout Plain Layout
17299 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
17302 \begin_layout Plain Layout
17325 \begin_layout Standard
17327 doesn't stop you using bullets from packages you don't have.
17328 If you get errors from \SpecialChar LaTeX
17329 when you try to view or print the file, then it
17330 is likely you are missing a package.
17334 \begin_layout Plain Layout
17336 doesn't restrict your use since you may be editing locally and exporting
17345 \begin_layout Subsection
17349 \begin_layout Standard
17350 Select which bullet depth you want to change then select the bullet shape
17352 Any changes will not be visible in \SpecialChar LyX
17353 , but are visible when viewing the document.
17356 \begin_layout Standard
17357 You can reset a bullet shape to the default simply by clicking your right
17358 mouse button on the appropriate bullet depth button.
17362 \begin_layout Plain Layout
17367 want to have multiple sets of paragraphs with different sets of bullets
17368 in each, then you're going to have to get your hands dirty with \SpecialChar TeX
17370 The bullet selection dialog can help though because it provides you with
17371 the \SpecialChar LaTeX
17372 code for a wide range of bullet shapes.
17373 To make your own custom paragraphs you have the following options:
17376 \begin_layout Plain Layout
17380 \begin_layout Plain Layout
17396 \begin_layout Plain Layout
17400 \begin_layout Plain Layout
17422 \begin_layout Itemize
17423 Use the \SpecialChar LaTeX
17425 \begin_inset Flex Code
17428 \begin_layout Plain Layout
17436 to specify a new bullet shape for a given depth.
17437 You'll also need to save the current bullet shape so you can restore it
17439 In this itemized list the following \SpecialChar LaTeX
17440 code was used to change the bullet
17441 used for the first depth.
17442 \begin_inset Separator latexpar
17449 \begin_layout LyX-Code
17459 \begin_layout LyX-Code
17476 \begin_layout Itemize
17477 Note that the itemize depth is specified in Roman numerals as part of the
17487 \begin_layout Itemize
17491 \begin_layout Plain Layout
17504 Specify each individual entry by starting each item with the bullet shape
17505 enclosed in square brackets and set as
17506 \begin_inset Flex Noun
17509 \begin_layout Plain Layout
17517 For example, this item was started with
17518 \begin_inset Flex Code
17521 \begin_layout Plain Layout
17536 \begin_layout Plain Layout
17540 \begin_layout Plain Layout
17556 \begin_layout Plain Layout
17557 You'll also need to revert the labelitem back to its previous setting for
17558 the global bullet shape settings to remain in effect.
17559 The way used here was:
17562 \begin_layout LyX-Code
17577 \begin_layout Chapter
17579 Features needing Extra Software
17582 \begin_layout Section
17583 Checking \SpecialChar TeX
17587 \begin_layout Standard
17593 \begin_layout Subsection
17597 \begin_layout Standard
17606 \begin_layout Plain Layout
17611 is not yet available when you are using the \SpecialChar LaTeX
17612 distribution MiK\SpecialChar TeX
17618 , you'll find in the
17625 \begin_inset space ~
17636 \begin_inset Newline newline
17640 \begin_inset CommandInset href
17642 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
17649 \begin_layout Standard
17652 Chk\SpecialChar TeX
17655 package is a program that was written by
17656 \begin_inset Flex Noun
17659 \begin_layout Plain Layout
17661 \begin_inset space ~
17669 in frustration because some constructs in \SpecialChar LaTeX
17670 are sometimes non-intuitive,
17671 and easy to forget.
17672 The program runs over your \SpecialChar LaTeX
17673 file, checks the integrity of the file, and
17674 flags some common errors.
17675 In other technical words, it is
17679 for \SpecialChar LaTeX
17683 \begin_layout Standard
17684 Well, what is a syntax checker doing in \SpecialChar LyX
17685 which is supposed to produce correct
17687 anyways? The answer is simple: Just as
17691 not only checks the
17695 of C programs, but also does
17699 checks for type-errors,
17701 Chk\SpecialChar TeX
17704 catches some common
17708 errors, in addition to the syntactical ones.
17711 Chk\SpecialChar TeX
17714 is capable of detecting several common errors, such as
17717 \begin_layout Itemize
17718 Ellipsis detection:
17719 \begin_inset Newline newline
17722 Use \SpecialChar ldots
17726 \begin_layout Itemize
17727 No space in front of/after parenthesis:
17728 \begin_inset Newline newline
17734 \begin_layout Itemize
17735 Enforcement of normal space after common abbreviations:
17736 \begin_inset Newline newline
17740 \begin_inset space \thinspace{}
17744 \begin_inset space \space{}
17747 is too wide spacing.
17750 \begin_layout Itemize
17751 Enforcement of end-of-sentence space when the last sentence ends with a
17753 \begin_inset Newline newline
17757 And this is wrong spacing.
17760 \begin_layout Itemize
17761 Space in front of labels and similar commands:
17762 \begin_inset Newline newline
17765 The label should stick right up to the text to avoid falling to a wrong
17768 \begin_inset CommandInset label
17778 \begin_layout Plain Layout
17779 This footnote is in danger of falling off to a wrong page
17784 The label is separated too much.
17787 \begin_layout Itemize
17788 Space in front of references, instead of hard spaces:
17789 \begin_inset Newline newline
17792 If you have bad luck, the text will break right between the referenced text
17793 and reference number, and that's a pity.
17795 \begin_inset CommandInset ref
17797 reference "sec:chktex"
17804 \begin_layout Itemize
17806 \begin_inset Quotes eld
17810 \begin_inset Quotes erd
17814 \begin_inset Formula $\times$
17818 \begin_inset Newline newline
17821 2x2 looks cheap compared to
17822 \begin_inset Formula $2\times2$
17828 \begin_layout Standard
17829 and more \SpecialChar ldots
17830 It is an invaluable tool when you are
17831 \begin_inset Quotes eld
17835 \begin_inset Quotes erd
17838 your document before printing, and you should run it right after the obligatory
17839 spelling check, and before you go fine tuning the typesetting.
17842 \begin_layout Subsection
17846 \begin_layout Standard
17847 If you have the program installed, usage is as simple as choosing
17849 Tools\SpecialChar menuseparator
17851 \begin_inset space ~
17857 This will make \SpecialChar LyX
17858 generate a \SpecialChar LaTeX
17859 file of your document, start
17861 Chk\SpecialChar TeX
17864 to check it, and then make \SpecialChar LyX
17866 \begin_inset Quotes eld
17870 \begin_inset Quotes erd
17873 with the warnings from
17875 Chk\SpecialChar TeX
17878 , if there were any.
17879 The warnings will be placed close to the point of the mistake, and you
17880 can quickly find them by using the
17882 Navigate\SpecialChar menuseparator
17885 menu item, or the shortcut key
17894 Open the error boxes by clicking on them with the mouse, or use the shortcut
17903 bindings, or the corresponding
17912 Read the warning and correct the mistake, if it is a mistake.
17913 If you have trouble understanding what the warning is about, you can safely
17915 Remember that there is a hidden layer between the document on screen and
17916 the technical details in invoking
17918 Chk\SpecialChar TeX
17921 , and this gap can make some warnings seem arcane or just plain silly.
17924 \begin_layout Standard
17925 This document is an excellent testing bed for the feature, and it should
17926 provide quite a few warnings for you to fiddle with.
17927 Since computers are only so smart, expect most of the warnings to be false
17931 \begin_layout Subsection
17932 How to fine tune it
17935 \begin_layout Standard
17936 Sometimes, you'll find that
17938 Chk\SpecialChar TeX
17941 makes more noise than suits your mood.
17942 Then you can choose not to use it, wait until your mood changes, or try
17945 Chk\SpecialChar TeX
17948 to get better along with you.
17951 \begin_layout Standard
17954 Chk\SpecialChar TeX
17961 very configurable and extensible, you should not expect to solve all problems
17964 Chk\SpecialChar TeX
17967 in \SpecialChar LyX
17969 Since \SpecialChar LyX
17970 has to generate a somewhat special \SpecialChar LaTeX
17971 file to be able to match the
17972 line numbers from the
17974 Chk\SpecialChar TeX
17981 \begin_layout Plain Layout
17982 You can inspect the specific output from
17988 Document\SpecialChar menuseparator
17991 \begin_inset space ~
18005 to the internal document structure, some of the warnings will not appear
18007 There are two things you can do about this:
18010 \begin_layout Itemize
18013 Chk\SpecialChar TeX
18016 invocation command line in
18017 \begin_inset Flex Noun
18020 \begin_layout Plain Layout
18021 Tools\SpecialChar menuseparator
18022 Preferences\SpecialChar menuseparator
18023 Output\SpecialChar menuseparator
18024 LaTeX\SpecialChar menuseparator
18032 Chk\SpecialChar TeX
18035 installation configuration file (usually with the file
18040 See below to learn what warnings can be enabled and disabled on the command
18044 \begin_layout Itemize
18045 Export your document as a raw \SpecialChar LaTeX
18048 File\SpecialChar menuseparator
18049 Export\SpecialChar menuseparator
18058 Invoked in this way, it can be a hassle to find the corresponding place
18059 in the document inside \SpecialChar LyX
18060 , but with a little patience, you should be able
18064 \begin_layout Standard
18065 Here follows the warning messages that can be enabled and disabled in
18074 to disable a warning, and
18078 to enable a warning.
18079 The emphasized entries are disabled by default, because the default is
18082 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
18087 \begin_layout Standard
18088 Notice that you should only use the options that enable and disable warnings,
18089 because \SpecialChar LyX
18090 relies on some of the other command line parameters to be set
18091 in a specific way to have a chance to communicate with
18098 \begin_layout Enumerate
18102 Command terminated with space.
18105 \begin_layout Enumerate
18108 Non-breaking space (
18109 \begin_inset Quotes eld
18117 \begin_inset Quotes erd
18120 ) should have been used.
18123 \begin_layout Enumerate
18127 You should enclose the previous parenthesis with
18128 \begin_inset Quotes eld
18136 \begin_inset Quotes erd
18142 \begin_layout Enumerate
18145 Italic correction (
18146 \begin_inset Quotes eld
18156 \begin_inset Quotes erd
18159 ) found in non-italic buffer.
18162 \begin_layout Enumerate
18165 Italic correction (
18166 \begin_inset Quotes eld
18176 \begin_inset Quotes erd
18179 ) found more than once.
18182 \begin_layout Enumerate
18186 No italic correction (
18187 \begin_inset Quotes eld
18197 \begin_inset Quotes erd
18203 \begin_layout Enumerate
18207 \begin_inset Quotes eld
18215 \begin_inset Quotes erd
18219 \begin_inset Quotes eld
18227 \begin_inset Quotes erd
18233 \begin_layout Enumerate
18236 Wrong length of dash may have been used.
18239 \begin_layout Enumerate
18243 \begin_inset Quotes eld
18251 \begin_inset Quotes erd
18255 \begin_inset Quotes eld
18263 \begin_inset Quotes erd
18269 \begin_layout Enumerate
18273 \begin_inset Quotes eld
18281 \begin_inset Quotes erd
18287 \begin_layout Enumerate
18291 \begin_inset Quotes eld
18299 \begin_inset Quotes erd
18302 to achieve an ellipsis.
18305 \begin_layout Enumerate
18308 Inter-word spacing (
18309 \begin_inset Quotes eld
18319 \begin_inset Quotes eld
18322 ) should perhaps be used.
18325 \begin_layout Enumerate
18328 Inter-sentence spacing (
18329 \begin_inset Quotes eld
18339 \begin_inset Quotes erd
18342 ) should perhaps be used.
18345 \begin_layout Enumerate
18348 Could not find argument for command.
18351 \begin_layout Enumerate
18355 \begin_inset Quotes eld
18363 \begin_inset Quotes erd
18369 \begin_layout Enumerate
18372 Math mode still on at end of \SpecialChar LaTeX
18376 \begin_layout Enumerate
18380 \begin_inset Quotes eld
18388 \begin_inset Quotes erd
18391 doesn't match the number of
18392 \begin_inset Quotes eld
18400 \begin_inset Quotes erd
18406 \begin_layout Enumerate
18409 You should use either
18412 \begin_inset Quotes eld
18420 \begin_inset Quotes erd
18425 as an alternative to
18426 \begin_inset Quotes eld
18434 \begin_inset Quotes erd
18440 \begin_layout Enumerate
18447 " (ASCII 39) instead of "
18454 \begin_layout Enumerate
18457 User-specified pattern found.
18460 \begin_layout Enumerate
18463 This command might not be intended.
18466 \begin_layout Enumerate
18473 \begin_layout Enumerate
18491 \begin_layout Enumerate
18494 Delete this space to maintain correct page references.
18497 \begin_layout Enumerate
18501 You might wish to put this between a pair of
18502 \begin_inset Quotes eld
18510 \begin_inset Quotes erd
18516 \begin_layout Enumerate
18519 You ought to remove spaces in front of punctuation.
18522 \begin_layout Enumerate
18525 Could not execute \SpecialChar LaTeX
18529 \begin_layout Enumerate
18538 in front of small punctuation.
18541 \begin_layout Enumerate
18549 may look prettier here.
18552 \begin_layout Enumerate
18556 Multiple spaces detected in output.
18559 \begin_layout Enumerate
18562 This text may be ignored.
18565 \begin_layout Enumerate
18571 \begin_inset Quotes eld
18576 to begin quotation, not
18583 \begin_layout Enumerate
18590 to end quotation, not
18593 \begin_inset Quotes eld
18601 \begin_layout Enumerate
18607 \begin_layout Enumerate
18610 You should perhaps use
18611 \begin_inset Quotes eld
18619 \begin_inset Quotes erd
18625 \begin_layout Enumerate
18628 You should put a space in front of/after parenthesis.
18631 \begin_layout Enumerate
18634 You should avoid spaces in front of/after parenthesis.
18637 \begin_layout Enumerate
18641 You should not use punctuation in front of/after quotes.
18644 \begin_layout Enumerate
18647 Double space found.
18650 \begin_layout Enumerate
18653 You should put punctuation outside inner/inside display math mode.
18656 \begin_layout Enumerate
18659 You ought to not use primitive \SpecialChar TeX
18660 in \SpecialChar LaTeX
18664 \begin_layout Enumerate
18667 You should remove spaces in front of
18668 \begin_inset Quotes eld
18676 \begin_inset Quotes erd
18682 \begin_layout Enumerate
18685 \begin_inset Quotes eld
18693 \begin_inset Quotes erd
18696 is normally not followed by
18697 \begin_inset Quotes eld
18705 \begin_inset Quotes erd
18711 \begin_layout Standard
18712 In later versions of \SpecialChar LyX
18713 , we hope to provide a more complete interface to this
18714 tool (and it's smaller cousin
18718 ) to exploit the full power of it.
18719 But it's not exactly useless as it is now: go try it on one of your existing
18720 documents of a certain length and be surprised.
18723 \begin_layout Section
18724 Version Control in \SpecialChar LyX
18728 \begin_layout Standard
18731 Lars Gullik Bjønnes
18738 \begin_layout Subsection
18742 \begin_layout Standard
18744 supports some of the most basic RCS/CVS/SVN/GIT commands.
18745 If you need something a bit more sophisticated you will have to do that
18746 manually in a terminal.
18749 \begin_layout Standard
18750 Also note that CVS support is not as good as subversion support so we advise
18752 A good place to start learning Subversion is SVN Book
18756 \begin_layout Plain Layout
18757 \begin_inset CommandInset href
18759 target "http://svnbook.red-bean.com/"
18769 In the case of RCS you should read
18770 \begin_inset Quotes eld
18774 \begin_inset Quotes erd
18777 (a man file, read it with
18782 This file describes all the basic features of RCS.
18783 You should especially notice the comment about a RCS directory, and the
18784 notion of a master RCS file (the file ending in
18791 \begin_layout Standard
18792 Before you begin to use the version control features in \SpecialChar LyX
18794 familiar with RCS/CVS/SVN/GIT usage.
18795 The implementation in \SpecialChar LyX
18796 assumes a recent version of the GNU RCS or CVS/SVN
18797 package — no guarantees are made for older versions.
18798 Most of the log messages are not currently displayed after operations —
18799 you can check them in the Messages pane if unsure.
18800 Regular users of version control will appreciate VC toolbar, which can
18803 View\SpecialChar menuseparator
18804 Toolbars\SpecialChar menuseparator
18806 \begin_inset space ~
18814 \begin_layout Standard
18815 For introducing your own external commands consult vc-command in the manual
18816 of \SpecialChar LyX
18820 \begin_layout Standard
18821 It is strongly recommended to store documents in uncompressed format if
18822 using version control (uncheck
18824 Document\SpecialChar menuseparator
18827 if it is checked): Uncompressed LyX documents are text files and therefore
18828 for merging two different versions by version control systems.
18829 Compressed LyX documents are binary files, which cannot be merged by version
18833 \begin_layout Subsection
18834 RCS commands in \SpecialChar LyX
18838 \begin_layout Standard
18839 The following sections describe the RCS commands supported by \SpecialChar LyX
18841 You can find them in the
18843 File\SpecialChar menuseparator
18845 \begin_inset space ~
18852 was tested against RCS 5.7/5.8.
18855 \begin_layout Subsubsection
18861 \begin_layout Standard
18862 If your document is not under revision control, this is the only item shown
18864 And if it is under revision control, the
18868 item is not visible.
18872 \begin_layout Standard
18873 This command registers your document with RCS (unless you are under the
18874 directory managed by CVS)\SpecialChar endofsentence
18875 You are asked interactively to supply an initial
18876 description of the document.
18877 The document is now set in Read-Only mode and you have to
18880 \begin_inset space ~
18884 \begin_inset space ~
18888 \begin_inset space ~
18893 , before making any changes to it.
18894 A document under revision control has a
18895 \begin_inset Quotes eld
18898 [RCS:<version> <locker>]
18899 \begin_inset Quotes erd
18902 item tagged to the filename in the minibuffer.
18905 \begin_layout Standard
18906 RCS command that is run:
18908 ci -q -u -i -t-"<initial description>" <file-name>
18911 \begin_layout Standard
18916 to understand the switches.
18920 \begin_layout Subsubsection
18926 \begin_layout Standard
18927 When you are finished editing a file, you check in your changes.
18928 When you do this, you are asked for a description of the changes.
18929 This is stored in the history log.
18930 The version number is bumped, your changes are applied to the master RCS
18931 file, the document is unlocked and set to Read-Only mode.
18934 \begin_layout Standard
18937 ci -q -u -m"<description>" <file-name>
18940 \begin_layout Subsubsection
18946 \begin_layout Standard
18947 By doing this you lock the document so that only you can edit it.
18948 This will also make the document Read-Write only for you.
18949 You will usually continue editing for a while and when you are finished
18950 you check in your changes.
18951 The status line is changed to reflect that you have locked the file.
18954 \begin_layout Standard
18957 co -q -l <file-name>
18960 \begin_layout Subsubsection
18963 Revert To Repository Version
18966 \begin_layout Standard
18967 This will discard all changes made to the document since the last check
18969 You get a warning before changes are discarded.
18972 \begin_layout Standard
18975 co -f -u<version> <file-name>
18978 \begin_layout Subsubsection
18984 \begin_layout Standard
18985 This will create a copy of the current document.
18986 Since RCS does not support copy operations natively, the version history
18987 is not preserved, and the copy is added as a new file.
18988 It requires a clean document without any changes since the last checkin.
18989 You are asked for a file name and a description of the copy operation.
18990 After that the copy is created, both locally and in the repository.
18991 If the parent directories of the copied and original document differ, all
18992 relative paths of included files of the copy are adjusted (like in
18994 File\SpecialChar menuseparator
18999 Finally, the copy is loaded instead of the original document.
19002 \begin_layout Labeling
19003 \labelwidthstring 00.00.0000
19005 \begin_inset space ~
19009 \begin_inset space ~
19013 \begin_inset Newline newline
19017 \begin_inset Flex Code
19020 \begin_layout Plain Layout
19023 \begin_inset Quotes eld
19027 \begin_inset Quotes erd
19036 \begin_inset Flex Code
19039 \begin_layout Plain Layout
19042 \begin_inset Quotes eld
19046 \begin_inset Quotes erd
19055 \begin_inset Newline newline
19059 \begin_inset Flex Code
19062 \begin_layout Plain Layout
19066 \begin_inset Quotes eld
19070 \begin_inset Quotes erd
19081 \begin_layout Subsubsection
19087 \begin_layout Standard
19088 This makes as if the last check in never happened.
19089 No changes are made to the document loaded into \SpecialChar LyX
19090 , but the last version
19091 is removed from the master RCS file.
19094 \begin_layout Standard
19097 rcs -o<version> <file-name>
19100 \begin_layout Subsubsection
19106 \begin_layout Standard
19107 This shows the complete history of the RCS document.
19112 is shown in a browser.
19120 \begin_layout Subsubsection
19124 \begin_layout Standard
19126 supports RCS version number, author name, date and time of last commit.
19127 All those are extracted from
19129 rlog -r <file-name>
19133 \begin_inset CommandInset ref
19135 reference "subsec:VCS-Revision-Information"
19142 \begin_layout Subsection
19143 CVS commands in \SpecialChar LyX
19147 \begin_layout Standard
19148 A subset of CVS operations is supported by \SpecialChar LyX
19150 You can find the commands in the
19152 File\SpecialChar menuseparator
19154 \begin_inset space ~
19160 The version control system SVN is more powerful, so please use it instead
19161 of CVS if possible.
19164 \begin_layout Subsubsection
19170 \begin_layout Standard
19171 If you start from scratch with CVS you have to create your repository and
19172 checkout the working copy with external tools.
19173 If you're using a client-server setup you may need to login before doing
19174 the first repository checkout.
19177 \begin_layout Standard
19178 If your documents are under revision control and others are using the same
19179 repository problems arise when different changes to the same document at
19180 the same location happen.
19181 Standard CVS repositories don't operate with a file locking mechanism.
19182 This may be surprising, but conflicts only occur if people disagree on
19183 the proper content of the same part of a document.
19184 So, if co-workers are used to communicate regularly, these conflicts occur
19186 If they don't communicate they have a fundamental problem anyway.
19187 Nevertheless some people like to work with so called
19188 \begin_inset Quotes eld
19192 \begin_inset Quotes erd
19196 If they do so the working copy of all files is readonly when checked out
19197 first and the user starts editing after using a special command to make
19198 the working copy writable.
19199 When the changes are checked in the working copy returns to readonly state.
19200 With \SpecialChar LyX
19201 one has to edit the
19202 \begin_inset Flex Code
19205 \begin_layout Plain Layout
19211 file and add the line
19212 \begin_inset Flex Code
19215 \begin_layout Plain Layout
19221 to work with reserved checkouts.
19222 The benefit is the possibility to see who is using a writable copy of some
19224 It's not guaranteed only one user makes a copy writable.
19227 \begin_layout Standard
19229 tries to guess if you're using reserved or non-reserved checkouts.
19230 If your working copy is readonly or it is writable and an additional copy
19231 of your document exists in the CVS/Base sub-directory a reserved otherwise
19232 a non-reserved checkout is assumed.
19233 When a reserved checkout is detected you have to use
19234 \begin_inset Flex Noun
19237 \begin_layout Plain Layout
19243 to make your working copy writable if it's readonly.
19245 \begin_inset Flex Noun
19248 \begin_layout Plain Layout
19254 operation is possible and that makes your working copy readonly again after
19255 transferring your changes to the repository.
19258 \begin_layout Standard
19259 More information about CVS can be found here
19260 \begin_inset Flex URL
19263 \begin_layout Plain Layout
19265 http://www.nongnu.org/cvs
19271 \begin_inset Flex URL
19274 \begin_layout Plain Layout
19276 http://ximbiot.com/cvs
19284 \begin_layout Standard
19289 to understand the sub-commands and the switches mentioned below.
19292 \begin_layout Subsubsection
19298 \begin_layout Standard
19299 If your document is not under revision control, this is the only item shown
19301 And if it is under revision control, the
19305 item is not visible.
19309 \begin_layout Standard
19310 This command registers in CVS your document
19311 \begin_inset Flex Strong
19314 \begin_layout Plain Layout
19322 in the case you have already the documents directory under CVS control
19328 This means you have to create or checkout the archive by yourself using
19330 (In case you forget that step \SpecialChar LyX
19331 registers the document with RCS.)
19334 \begin_layout Standard
19335 Then you are asked interactively to supply an initial description of the
19337 Don't forget that registered file is not yet checked in.
19340 \begin_layout Standard
19341 CVS command that is run:
19343 cvs -q add -m"<entered message>" "<file-name>"
19346 \begin_layout Standard
19351 above and for all other CVS commands is an abbreviation for
19352 \begin_inset Quotes eld
19355 change the current working directory to file location and use the file name
19356 without path component as argument
19357 \begin_inset Quotes erd
19363 \begin_layout Subsubsection
19369 \begin_layout Standard
19370 When you are finished editing a file, you commit your changes.
19371 When you do this and you had changed the document, you are asked for a
19372 description of the changes.
19373 After that changes are written to the repository.
19374 In case you didn't change the document and a reserved checkout is detected
19375 the reservation made on
19376 \begin_inset Flex Noun
19379 \begin_layout Plain Layout
19388 \begin_layout Labeling
19389 \labelwidthstring 00.00.0000
19391 \begin_inset space ~
19395 \begin_inset space ~
19399 \begin_inset Newline newline
19403 \begin_inset Flex Code
19406 \begin_layout Plain Layout
19409 -q commit -m"<description>" "<file-name>"
19415 \begin_inset Newline newline
19419 \begin_inset Flex Code
19422 \begin_layout Plain Layout
19433 \begin_layout Subsubsection
19439 \begin_layout Standard
19440 When you are sharing a repository with others, you may have to incorporate
19441 their changes into your working copy.
19444 \begin_layout Standard
19447 cvs -q update "<file-name>"
19450 \begin_layout Standard
19451 If a readonly checkout is detected the working copy is made writable and
19455 \begin_layout Standard
19458 cvs -q edit "<file-name>"
19461 \begin_layout Subsubsection
19464 Revert To Repository Version
19467 \begin_layout Standard
19468 This will discard all changes made to the document since the last check
19470 You get a warning before changes are discarded.
19471 Firstly the file is deleted, secondly CVS update command is run.
19474 \begin_layout Standard
19477 cvs -q update "<file-name>"
19480 \begin_layout Standard
19481 If a reserved checkout is detected and the working copy has no changes only
19482 the reservation is undone.
19485 \begin_layout Standard
19488 cvs -q unedit "<file-name>"
19491 \begin_layout Subsubsection
19497 \begin_layout Standard
19498 This will create a copy of the current document.
19499 Since CVS does not support copy operations natively, the version history
19500 is not preserved, and the copy is added as a new file.
19501 It requires a clean document without any changes since the last checkin.
19502 You are asked for a file name and a description of the copy operation.
19503 After that the copy is created, both locally and in the repository.
19504 If the parent directories of the copied and original document differ, all
19505 relative paths of included files of the copy are adjusted (like in
19507 File\SpecialChar menuseparator
19512 Finally, the copy is loaded instead of the original document.
19515 \begin_layout Labeling
19516 \labelwidthstring 00.00.0000
19518 \begin_inset space ~
19522 \begin_inset space ~
19526 \begin_inset Newline newline
19530 \begin_inset Flex Code
19533 \begin_layout Plain Layout
19536 \begin_inset Quotes eld
19540 \begin_inset Quotes erd
19549 \begin_inset Flex Code
19552 \begin_layout Plain Layout
19555 \begin_inset Quotes eld
19559 \begin_inset Quotes erd
19568 \begin_inset Newline newline
19572 \begin_inset Flex Code
19575 \begin_layout Plain Layout
19579 \begin_inset Quotes eld
19583 \begin_inset Quotes erd
19594 \begin_layout Subsubsection
19600 \begin_layout Standard
19601 This will rename the current document.
19602 Since CVS does not support rename operations natively, the version history
19603 is not preserved, the renamed document is added as a new file, and the
19604 original document is deleted.
19605 It requires a clean document without any changes since the last checkin.
19606 You are asked for a file name and a description of the rename operation.
19607 After that the document is renamed, both locally and in the repository.
19608 If the parent directories of the new and old file names differ, all relative
19609 paths of included files are adjusted (like in
19611 File\SpecialChar menuseparator
19616 Finally, the document is reloaded using the new name.
19619 \begin_layout Labeling
19620 \labelwidthstring 00.00.0000
19622 \begin_inset space ~
19626 \begin_inset space ~
19630 \begin_inset Newline newline
19634 \begin_inset Flex Code
19637 \begin_layout Plain Layout
19640 \begin_inset Quotes eld
19644 \begin_inset Quotes erd
19653 \begin_inset Flex Code
19656 \begin_layout Plain Layout
19659 \begin_inset Quotes eld
19663 \begin_inset Quotes erd
19672 \begin_inset Newline newline
19676 \begin_inset Flex Code
19679 \begin_layout Plain Layout
19683 \begin_inset Quotes eld
19687 \begin_inset Quotes erd
19696 \begin_inset Newline newline
19700 \begin_inset Flex Code
19703 \begin_layout Plain Layout
19707 \begin_inset Quotes eld
19711 \begin_inset Quotes erd
19722 \begin_layout Subsubsection
19723 Update of the local directory checkout from repository
19726 \begin_layout Standard
19727 Once your documents gets more complex, containing sub-documents and pictures,
19729 \begin_inset Flex Code
19732 \begin_layout Plain Layout
19738 files and so on using version control becomes more complicated.
19740 supports updating the whole tree in which resides the document.
19741 This become especially useful once you cooperate with people which neither
19742 have detailed knowledge about CVS usage nor they have ambition to commit
19743 additional material to the repository.
19744 You have to organize the files structure so that all external files are
19745 in the same directory or subdirectories of the document.
19746 It's good practice anyway to store multipart documents in an extra directory.
19749 \begin_layout Standard
19751 \begin_inset Flex Code
19754 \begin_layout Plain Layout
19755 Update local directory from repository
19760 command updates the whole directory.
19761 If local changes are detected user is warned before update starts.
19762 In case of merge conflicts both versions of the conflicting document parts
19763 are placed in the final document.
19764 You have to review and correct the result of the merge.
19765 You'll find the conflicts enclosed in pairs of
19766 \begin_inset Flex Code
19769 \begin_layout Plain Layout
19776 \begin_inset Flex Code
19779 \begin_layout Plain Layout
19786 \begin_inset Flex Code
19789 \begin_layout Plain Layout
19796 The first part is your version as before the update operation with the
19797 document name prepended.
19798 The second one is the repository version with the version number after
19800 \begin_inset Flex Code
19803 \begin_layout Plain Layout
19812 \begin_layout Labeling
19813 \labelwidthstring 00.00.0000
19815 \begin_inset space ~
19819 \begin_inset space ~
19823 \begin_inset Newline newline
19827 \begin_inset Flex Code
19830 \begin_layout Plain Layout
19838 (Ask if changes are detected.)
19839 \begin_inset Newline newline
19843 \begin_inset Flex Code
19846 \begin_layout Plain Layout
19847 cd $path; cvs -q update
19857 \begin_layout Standard
19859 \begin_inset Flex Code
19862 \begin_layout Plain Layout
19868 stands for the path to the document.
19871 \begin_layout Subsubsection
19877 \begin_layout Standard
19878 This shows the complete history of the CVS document.
19881 cvs log "<file-name>"
19883 is shown in a browser.
19886 \begin_layout Subsubsection
19890 \begin_layout Standard
19892 supports CVS version number, author name, date and time of last commit.
19893 All those are extracted from
19895 cvs log -r <file-name>
19899 \begin_inset CommandInset ref
19901 reference "subsec:VCS-Revision-Information"
19908 \begin_layout Subsection
19909 SVN commands in \SpecialChar LyX
19913 \begin_layout Standard
19914 SVN is now partially supported by \SpecialChar LyX
19916 You can find the commands in the
19918 File\SpecialChar menuseparator
19920 \begin_inset space ~
19926 Please note that if you use password protected access to repository via
19927 ssh, you will be asked in terminal window.
19929 was tested against SVN 1.5, 1.6, 1.7 and 1.8
19933 \begin_layout Plain Layout
19934 Most of the commands will work with 1.4 too, see
19935 \begin_inset CommandInset ref
19937 reference "subsec:SVN-Repo-Update"
19942 There seems to be currently unresolved permissions problem under SVN 1.8
19943 with reverting changes when file is locked.
19951 \begin_layout Subsubsection
19957 \begin_layout Standard
19958 If your document is not under revision control, this is the only item shown
19960 And if it is under revision control, the
19964 item is not visible.
19967 \begin_layout Standard
19968 This command registers in SVN your document ONLY in case you have already
19969 the documents directory under SVN control (in particular
19974 This means you have to checkout the archive by yourself.
19977 \begin_layout Standard
19978 Then you are asked interactively to supply an initial description of the
19980 Don't forget that registered file is not yet commited.
19983 \begin_layout Standard
19984 SVN command that is run:
19987 \begin_inset Quotes eld
19991 \begin_inset Quotes erd
19997 \begin_layout Standard
20002 to understand the switches.
20005 \begin_layout Subsubsection
20011 \begin_layout Standard
20012 When you are finished editing a file, you commit your changes.
20013 When you do this, you are asked for a description of the changes.
20014 After that changes are commited.
20017 \begin_layout Standard
20022 \begin_layout Plain Layout
20023 In case locking is not enabled.
20025 \begin_inset CommandInset ref
20027 reference "subsec:SVN-File-Locking"
20038 svn commit -q -m"<description>" <file-name>
20041 \begin_layout Subsubsection
20047 \begin_layout Standard
20048 Updates the changes of this file from the repository.
20049 Be sure you understand SVN merging and conflicts resolving before using
20050 this function, because all conflicts has to be resolved manually by you!
20053 \begin_layout Standard
20058 \begin_layout Plain Layout
20066 svn update --non-interactive
20067 \begin_inset Quotes eld
20071 \begin_inset Quotes erd
20077 \begin_layout Subsubsection
20080 Revert To Repository Version
20083 \begin_layout Standard
20084 This will discard all changes made to the document since the last check
20086 You get a warning before changes are discarded.
20089 \begin_layout Standard
20093 \begin_inset Quotes eld
20097 \begin_inset Quotes erd
20103 \begin_layout Subsubsection
20109 \begin_layout Standard
20110 This will create a copy of the current document including the version history.
20111 It requires a clean document without any changes since the last checkin.
20112 You are asked for a file name and a description of the copy operation.
20113 After that the copy is created, both locally and in the repository.
20114 If the parent directories of the copied and original document differ, all
20115 relative paths of included files of the copy are adjusted (like in
20117 File\SpecialChar menuseparator
20122 Finally, the copy is loaded instead of the original document.
20125 \begin_layout Labeling
20126 \labelwidthstring 00.00.0000
20128 \begin_inset space ~
20132 \begin_inset space ~
20136 \begin_inset Newline newline
20140 \begin_inset Flex Code
20143 \begin_layout Plain Layout
20147 \begin_inset Quotes eld
20151 \begin_inset Quotes erd
20155 \begin_inset Quotes eld
20159 \begin_inset Quotes erd
20168 \begin_inset Newline newline
20172 \begin_inset Flex Code
20175 \begin_layout Plain Layout
20184 \begin_layout Subsubsection
20190 \begin_layout Standard
20191 This will rename the current document including the version history.
20192 It requires a clean document without any changes since the last checkin.
20193 You are asked for a file name and a description of the rename operation.
20194 After that the document is renamed, both locally and in the repository.
20195 If the parent directories of the new and old file names differ, all relative
20196 paths of included files are adjusted (like in
20198 File\SpecialChar menuseparator
20203 Finally, the document is reloaded using the new name.
20206 \begin_layout Labeling
20207 \labelwidthstring 00.00.0000
20209 \begin_inset space ~
20213 \begin_inset space ~
20217 \begin_inset Newline newline
20221 \begin_inset Flex Code
20224 \begin_layout Plain Layout
20228 \begin_inset Quotes eld
20232 \begin_inset Quotes erd
20236 \begin_inset Quotes eld
20240 \begin_inset Quotes erd
20249 \begin_inset Newline newline
20253 \begin_inset Flex Code
20256 \begin_layout Plain Layout
20265 \begin_layout Subsubsection
20266 \begin_inset CommandInset label
20268 name "subsec:SVN-Repo-Update"
20272 Update of the local directory checkout from repository
20276 \begin_layout Plain Layout
20277 Note that this command will work only with subversion
20278 \begin_inset Formula $\geqq1.5$
20289 \begin_layout Standard
20290 All the commands above have one shortcomming - they deal with the current
20292 Once your document contains pictures, includes external
20293 \begin_inset Flex Code
20296 \begin_layout Plain Layout
20302 files and so on administration becomes more complicated.
20304 now supports updating the whole tree in which resides the document
20308 \begin_layout Plain Layout
20309 One need to organize the files structure so that all external files are
20310 in the same directory or subdirectories of the document.
20317 This become especially useful once you cooperate with people which neither
20318 know about subversion management nor they have ambition to commit additional
20319 material to the repository.
20323 \begin_layout Standard
20324 \begin_inset Flex Code
20327 \begin_layout Plain Layout
20328 Update local directory from repository
20333 command updates the whole directory and in case of merge conflicts local
20334 version of the files are left, so no unintended data loss occurs.
20335 If local changes are detected user is warned before update starts.
20338 \begin_layout Labeling
20339 \labelwidthstring 00.00.0000
20341 \begin_inset space ~
20345 \begin_inset space ~
20349 \begin_inset Newline newline
20353 \begin_inset Flex Code
20356 \begin_layout Plain Layout
20362 (Ask if changes are detected.)
20363 \begin_inset Newline newline
20367 \begin_inset Flex Code
20370 \begin_layout Plain Layout
20371 svn update –accept mine-full $path
20379 \begin_layout Standard
20381 \begin_inset Flex Code
20384 \begin_layout Plain Layout
20390 stands for the path to the document.
20393 \begin_layout Subsubsection
20399 \begin_layout Standard
20400 This shows the complete history of the SVN document.
20404 \begin_inset Quotes eld
20408 \begin_inset Quotes erd
20413 is shown in a browser.
20416 \begin_layout Subsubsection
20418 \begin_inset CommandInset label
20420 name "subsec:SVN-File-Locking"
20427 \begin_layout Standard
20428 The file exchange through various revision control systems brings the problem
20429 of merge conflicts in case two different users try to edit the same (parts
20431 When such a conflict happens it needs manual resolving and one reasonable
20432 alternative is to provide some kind of locking mechanism, which guarantees
20433 that only one user is allowed to edit file at the given time.
20436 \begin_layout Standard
20437 SVN has two such mechanisms to provide mutual exclusivity for file access
20438 - locks and automatic setting of write permissions (see sec.
20440 \begin_inset CommandInset ref
20442 reference "subsec:Automatical-Locking-Property"
20447 \begin_inset Flex Code
20450 \begin_layout Plain Layout
20460 \begin_layout Plain Layout
20461 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
20467 If this property is detected for a given document \SpecialChar LyX
20468 starts to use SVN locks
20469 for document editing automatically and the whole check-in/out mechanism
20470 switches to the same regimen as for RCS.
20471 This in particular means there are two different modes of file use in \SpecialChar LyX
20475 \begin_layout Itemize
20477 The loaded file is in the read-only mode.
20478 For editing on needs to check-out.
20483 consists of updating from the repository and gaining write lock.
20484 If the lock is not possible to obtain, we remain in unlocked state.
20487 \begin_layout Itemize
20489 The loaded file is in the 'normal' edit mode.
20490 No other user is allowed to edit the file.
20495 consists of commiting changes and releasing write-lock.
20496 If no changes have been made to the document, no commit will be produced
20500 \begin_layout Plain Layout
20501 Don't be puzzled by the fact that you will be asked for commit message anyway.
20506 and only the write-lock will be released.
20509 \begin_layout Standard
20513 \begin_layout Labeling
20514 \labelwidthstring 00.00.0000
20517 svn commit -q -m"<description>" "<file-name>"
20518 \begin_inset Newline newline
20521 svn unlock "<file-name>"
20524 \begin_layout Labeling
20525 \labelwidthstring 00.00.0000
20528 svn update "<file-name>"
20529 \begin_inset Newline newline
20532 svn lock "<file-name>"
20535 \begin_layout Subsubsection
20538 \begin_inset CommandInset label
20540 name "subsec:Automatical-Locking-Property"
20546 Automatic Locking Property
20549 \begin_layout Standard
20550 The above mentioned automatic setting of write permissions of the .lyx file
20553 File\SpecialChar menuseparator
20555 \begin_inset space ~
20558 Control\SpecialChar menuseparator
20559 Toggle locking property
20562 This command is active only when the file is not locked on the svn server
20564 you need to check-out before proceeding).
20567 \begin_layout Labeling
20568 \labelwidthstring 00.00.0000
20570 \begin_inset space ~
20576 \begin_layout Labeling
20577 \labelwidthstring 00.00.0000
20580 svn propset svn:needs-lock ON "<file-name>"
20583 \begin_layout Labeling
20584 \labelwidthstring 00.00.0000
20587 svn propdel svn:needs-lock "<file-name>"
20590 \begin_layout Subsubsection
20591 \begin_inset CommandInset label
20593 name "subsec:VCS-Revision-Information"
20597 Revision Information in Documents
20600 \begin_layout Standard
20601 There are more possibilities how to activate revision information in our
20605 \begin_layout Itemize
20611 \begin_layout Itemize
20612 tree revision information (
20613 \begin_inset Flex Code
20616 \begin_layout Plain Layout
20623 The result is the output of the
20624 \begin_inset Flex Code
20627 \begin_layout Plain Layout
20633 command, the following table gives you an idea, how to read the results.
20636 \begin_layout Standard
20638 \begin_inset Tabular
20639 <lyxtabular version="3" rows="6" columns="2">
20640 <features tabularvalignment="middle">
20641 <column alignment="center" valignment="top">
20642 <column alignment="center" valignment="top">
20644 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20647 \begin_layout Plain Layout
20653 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20656 \begin_layout Plain Layout
20664 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20667 \begin_layout Plain Layout
20673 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20676 \begin_layout Plain Layout
20677 mixed revision working copy
20684 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20687 \begin_layout Plain Layout
20693 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20696 \begin_layout Plain Layout
20697 modified working copy
20704 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20707 \begin_layout Plain Layout
20713 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20716 \begin_layout Plain Layout
20717 switched working copy
20724 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20727 \begin_layout Plain Layout
20733 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20736 \begin_layout Plain Layout
20737 partial working copy, from a sparse checkout
20744 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20747 \begin_layout Plain Layout
20753 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20756 \begin_layout Plain Layout
20757 mixed revision, modified, switched working copy
20770 \begin_layout Itemize
20771 file revision information.
20772 The result comes from parsing the output of
20773 \begin_inset Flex Code
20776 \begin_layout Plain Layout
20778 \begin_inset space ~
20782 \begin_inset space ~
20786 \begin_inset space ~
20795 Supported flags are:
20799 \begin_layout Itemize
20800 version number of the last commit (
20801 \begin_inset Flex Code
20804 \begin_layout Plain Layout
20813 \begin_layout Itemize
20814 author of the last commit (
20815 \begin_inset Flex Code
20818 \begin_layout Plain Layout
20827 \begin_layout Itemize
20828 date of the last commit (
20829 \begin_inset Flex Code
20832 \begin_layout Plain Layout
20841 \begin_layout Itemize
20842 time of the last commit (
20843 \begin_inset Flex Code
20846 \begin_layout Plain Layout
20856 \begin_layout Standard
20857 You can obtain this info via InsetInfo (e.g.
20859 \begin_inset Flex Code
20862 \begin_layout Plain Layout
20863 info-insert buffer vcs-date
20869 The information will be available only when you have the file stored under
20870 svn managment (i.e.
20872 \begin_inset Flex Code
20875 \begin_layout Plain Layout
20881 directory is available with your document).
20885 \begin_layout Itemize
20886 Another—a hacking one—possibility is to use svn keywords
20890 \begin_layout Plain Layout
20891 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
20897 In short – you set file keywords property (e.g.
20900 svn propset svn:keywords 'Rev' file.lyx
20902 ) and then paste keyword \SpecialChar TeX
20907 \begin_layout Plain Layout
20908 This is an easy way how to ensure that \SpecialChar LyX
20909 won't break the line in the middle
20915 tag in your document (e.g.
20920 \begin_layout Plain Layout
20928 This way svn client will automatically substitute revision number (e.g.
20933 \begin_layout Plain Layout
20940 ) after each update and commit.
20941 There are more problems with this approach.
20942 Firstly, the '$' character is used in \SpecialChar TeX
20943 world for math equations, so any
20944 occurence of math formula
20945 \begin_inset Formula $Rev$
20949 \begin_inset Formula $Rev:59$
20952 in your \SpecialChar LyX
20954 Similarly for other keywords like Id, Date, Author, etc.
20955 Secondly svn output is dependent on your locales, so its very easy that
20956 svn would produce some problematic strings once Date is used.
20957 Thirdly you get the whole 'Rev: 59' string in your document instead of
20959 Until subversion implements user's custom keywords it will be hard to use
20960 this approach reliably or let \SpecialChar LyX
20961 to support it directly.
20964 \begin_layout Subsection
20965 SVN and Windows Environment
20968 \begin_layout Quote
20969 My inclination is to say that if the user cannot figure out the command
20970 line operations on their own fairly quickly, they would be well advised
20971 to use TortoiseSVN.
20977 \begin_layout Subsubsection
20981 \begin_layout Standard
20982 In addition to installing \SpecialChar LyX
20983 , and having access to a Subversion repository,
20984 the user will need to install the Subversion client program.
20985 A Windows installer for the client program is available from
20986 \begin_inset CommandInset href
20989 target "http://www.collab.net/nonav/downloads/subversion/"
20994 The user may also want to install
20995 \begin_inset CommandInset href
20998 target "http://tortoisesvn.tigris.org/"
21002 , which integrates Subversion operations into the context (rightclick) menu
21003 of Windows Explorer.
21004 Operations done outside \SpecialChar LyX
21005 will typically be more convenient using the Explorer
21007 Note that TortoiseSVN is not a replacement for the client program, which
21008 is what \SpecialChar LyX
21012 \begin_layout Subsubsection
21013 Bringing a document under Subversion control
21016 \begin_layout Standard
21017 Before a \SpecialChar LyX
21018 document can be brought under version control in Subversion, its
21019 parent directory needs to be under version control.
21020 If the document is being added to a project already in the repository,
21021 this is accomplished by checking the project out to the directory where
21022 the new document will be placed.
21023 If the project itself is not yet under version control (for instance, if
21024 this document starts a new project), the directory must be imported into
21026 This is done outside \SpecialChar LyX
21028 Both import and checkout are easily accomplished from the Explorer context
21029 menu using TortoiseSVN, or alternatively can be done using the command
21030 line client at a DOS prompt.
21031 The procedure for importing the project using TortoiseSVN is described
21032 below, assuming an existing repository and a new project being started
21040 For information on using the Subversion client program, run
21047 \begin_layout Enumerate
21054 in Windows Explorer, right click it, and select
21056 TortoiseSVN\SpecialChar menuseparator
21060 If necessary, adjust the URL for the repository, then click OK.
21063 \begin_layout Enumerate
21064 Right click the level of the repository under which you want to place the
21065 new project folder (typically the top level) and click
21069 Supply a name for the project folder and click OK.
21070 Add a message for the log file if desired, then click OK again.
21071 The new project folder should appear in the repository.
21072 Finally, click OK again to exit the repository browser.
21075 \begin_layout Enumerate
21076 Once again right click
21082 , this time selecting SVN Checkout\SpecialChar ldots
21083 Select the URL of the project folder
21084 you just created in the repository, and set the checkout directory to
21092 You will be warned about a non-empty folder; click OK to proceed.
21093 You should now have a
21104 \begin_layout Enumerate
21105 Create or open your document in \SpecialChar LyX
21108 File\SpecialChar menuseparator
21110 \begin_inset space ~
21113 Control\SpecialChar menuseparator
21117 Add a log message and click OK to commit the document to version control.
21120 \begin_layout Standard
21121 From this point onward, you should have full functionality in the
21123 File\SpecialChar menuseparator
21125 \begin_inset space ~
21131 You also have the option of checking the document in and out, viewing its
21133 using the TortoiseSVN context menu in Windows Explorer or the Subversion
21134 client program from a command prompt.
21137 \begin_layout Subsubsection
21138 SSH tunnel used with SVN under Windows
21141 \begin_layout Standard
21142 Compared with Linux setting up an svn client to communicate over ssh under
21143 Windows is a rather troublesome task.
21144 We will at least offer some hints how to setup the client side but prior
21145 knowledge about ssh and the Windows command line is needed, also be prepared
21146 for a great deal of frustration\SpecialChar ldots
21150 \begin_layout Enumerate
21151 Get an svn client for windows, as described in the previous sections.
21152 When it is a fresh install run some svn command (e.g.
21154 \begin_inset Flex Code
21157 \begin_layout Plain Layout
21163 ) to create config files, which you will need to change later on.
21166 \begin_layout Enumerate
21167 Choose an ssh client for Windows.
21168 There are several possibilities, we will use the one from Putty tools
21172 \begin_layout Plain Layout
21173 \begin_inset Flex URL
21176 \begin_layout Plain Layout
21178 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
21189 You will need to set the connection up so that the client doesn't ask for
21190 any password from you.
21191 To keep things easy we will use only keys without any additional password
21196 \begin_layout Enumerate
21198 \begin_inset Flex Code
21201 \begin_layout Plain Layout
21208 Save your private .ppk key file and put the public one on the server side.
21209 If the SVN server runs on Linux, note that the format of the public key
21210 is not compatible with Linux openssh and you will need to direcly copy-paste
21213 Public key for pasting into OpenSSH authorized_keys file
21215 :” edit field into the server's
21216 \begin_inset Flex Code
21219 \begin_layout Plain Layout
21220 ~/.ssh/authorized_keys
21226 \begin_inset Flex Code
21229 \begin_layout Plain Layout
21238 \begin_layout Enumerate
21240 \begin_inset Flex Code
21243 \begin_layout Plain Layout
21250 In the SVN config file
21254 \begin_layout Plain Layout
21255 Exact path depends on Windows version, usually somewhere around
21256 \begin_inset Flex Code
21259 \begin_layout Plain Layout
21262 Documents and Settings
21276 \begin_inset Flex Code
21279 \begin_layout Plain Layout
21294 , section [tunnels], setup ssh command, e.g.
21296 \begin_inset Flex Code
21299 \begin_layout Plain Layout
21300 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
21309 \begin_layout Plain Layout
21310 It will usually take a lot of time to get exact command right and it depends
21312 For example do not have some remote server saved as a default session in
21314 If things fail, try to connect via plink without SVN first.
21323 \begin_layout Enumerate
21324 Checkout the SVN archive, e.
21325 \begin_inset space \thinspace{}
21329 \begin_inset Newline newline
21333 \begin_inset Flex Code
21336 \begin_layout Plain Layout
21337 svn co svn+ssh://user@server/repository_path
21345 \begin_layout Subsubsection
21346 End-of-Line Conversions
21349 \begin_layout Standard
21350 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
21352 use different line endings inside the .lyx files.
21353 This is not a problem as far as \SpecialChar LyX
21354 functionality is concerned, but the commit
21355 diffs will be huge and merge-conflicts prone.
21356 Fortunately SVN itself knows
21360 \begin_layout Plain Layout
21361 \begin_inset Flex URL
21364 \begin_layout Plain Layout
21366 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
21376 how to deal with CR/LF problems when switching .lyx files to the
21377 \begin_inset Flex Code
21380 \begin_layout Plain Layout
21390 \begin_layout Plain Layout
21392 \begin_inset Flex Code
21395 \begin_layout Plain Layout
21396 svn propset svn:eol-style native FILE_NAME
21409 \begin_layout Subsection
21410 GIT commands in \SpecialChar LyX
21414 \begin_layout Standard
21415 A minimal subset of GIT commands is now supported by \SpecialChar LyX
21417 You can find the commands in the
21419 File\SpecialChar menuseparator
21421 \begin_inset space ~
21427 Please note that if you use password protected access to repository via
21428 ssh, you will be asked in terminal window.
21430 was tested against GIT 1.7.
21434 \begin_layout Plain Layout
21435 Windows users please note that you need to ensure that git is on the path.
21436 This can be set from within \SpecialChar LyX
21439 Tools\SpecialChar menuseparator
21440 Preferences\SpecialChar menuseparator
21441 Paths\SpecialChar menuseparator
21452 \begin_layout Standard
21453 One big difference of GIT and the other supported version control systems
21454 is the distributed nature of GIT: With traditional version control systems
21455 there is one central server which hosts the repository.
21456 Users commit their changes to the server, and get updates made by other
21458 With GIT, users commit to a local repository.
21459 The local repository can be synchronized with one or more remote repositories
21461 \begin_inset Flex Code
21464 \begin_layout Plain Layout
21471 \begin_inset Flex Code
21474 \begin_layout Plain Layout
21482 does not interact in any way with remote GIT repositories.
21483 It works exclusively with the local repository in a very similar way as
21484 with a central CVS or SVN repository.
21485 If you use remote GIT repositories you need to do the
21486 \begin_inset Flex Code
21489 \begin_layout Plain Layout
21496 \begin_inset Flex Code
21499 \begin_layout Plain Layout
21505 operations with your favourite GIT client.
21508 \begin_layout Subsubsection
21514 \begin_layout Standard
21515 If your document is not under revision control, this is the only item shown
21517 And if it is under revision control, the
21521 item is not visible.
21524 \begin_layout Standard
21525 This command registers in GIT your document ONLY in case you have already
21526 the documents directory under GIT control (in particular
21531 This means you have to checkout the archive by yourself.
21534 \begin_layout Standard
21535 Then you are asked interactively to supply an initial description of the
21537 Don't forget that registered file is not yet commited.
21540 \begin_layout Standard
21541 GIT command that is run:
21544 \begin_inset Quotes eld
21548 \begin_inset Quotes erd
21554 \begin_layout Standard
21559 to understand the switches.
21562 \begin_layout Subsubsection
21568 \begin_layout Standard
21569 When you are finished editing a file, you commit your changes.
21570 When you do this, you are asked for a description of the changes.
21571 After that changes are commited.
21574 \begin_layout Standard
21577 git commit -q -m"<description>" <file-name>
21580 \begin_layout Subsubsection
21583 Revert To Repository Version
21586 \begin_layout Standard
21587 This will discard all changes made to the document since the last check
21589 You get a warning before changes are discarded.
21592 \begin_layout Standard
21596 \begin_inset Quotes eld
21600 \begin_inset Quotes erd
21606 \begin_layout Subsubsection
21612 \begin_layout Standard
21613 This will rename the current document including the version history.
21614 It requires a clean document without any changes since the last checkin.
21615 You are asked for a file name and a description of the rename operation.
21616 After that the document is renamed, both locally and in the repository.
21617 If the parent directories of the new and old file names differ, all relative
21618 paths of included files are adjusted (like in
21620 File\SpecialChar menuseparator
21625 Finally, the document is reloaded using the new name.
21628 \begin_layout Labeling
21629 \labelwidthstring 00.00.0000
21631 \begin_inset space ~
21635 \begin_inset space ~
21639 \begin_inset Newline newline
21643 \begin_inset Flex Code
21646 \begin_layout Plain Layout
21650 \begin_inset Quotes eld
21654 \begin_inset Quotes erd
21658 \begin_inset Quotes eld
21662 \begin_inset Quotes erd
21671 \begin_inset Newline newline
21675 \begin_inset Flex Code
21678 \begin_layout Plain Layout
21687 \begin_layout Subsubsection
21693 \begin_layout Standard
21694 This shows the complete history of the GIT document.
21698 \begin_inset Quotes eld
21702 \begin_inset Quotes erd
21707 is shown in a browser.
21710 \begin_layout Subsubsection
21714 \begin_layout Standard
21716 supports GIT hash number of the last commit to the file, author name, date
21717 and time of last commit.
21718 All those are extracted from
21720 git log -n 1 --pretty=format:%H%n%an%n%ai
21723 Tree version information is obtained via
21725 git describe --abbrev --dirty --long
21729 \begin_inset CommandInset ref
21731 reference "subsec:VCS-Revision-Information"
21738 \begin_layout Subsection
21742 \begin_layout Standard
21743 With the recent addition of the vc-command function \SpecialChar LyX
21744 power users are allowed
21745 to create their own commands for revision control.
21748 \begin_layout Standard
21749 As an example you can see how two TortoiseSVN commands could be integrated
21753 \begin_layout Description
21755 \begin_inset Flex Code
21758 \begin_layout Plain Layout
21759 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
21767 \begin_layout Description
21769 \begin_inset Flex Code
21772 \begin_layout Plain Layout
21773 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
21781 \begin_layout Subsection
21782 Version control and Document comparison
21785 \begin_layout Standard
21786 One of the typical uses of version control is to inspect the changes between
21787 revisions, usually by creating
21788 \begin_inset Flex Code
21791 \begin_layout Plain Layout
21798 While this is useful for plain text files, it is much less useful in the
21799 case of \SpecialChar LyX
21800 files, which have more a complicated structure.
21801 Hence we provide binding to the Document comparison feature.
21802 There are two ways of calling this feature - either by direct call of
21803 \begin_inset Flex Code
21806 \begin_layout Plain Layout
21813 function (for details see \SpecialChar LyX
21814 functions manual) or by icon/menu item
21815 \begin_inset Flex Noun
21818 \begin_layout Plain Layout
21819 Compare with older revision...
21825 One can either compare two chosen revisions of the document or he can simply
21826 compare the current version of edited text with older revisions (where
21828 \begin_inset Flex Noun
21831 \begin_layout Plain Layout
21837 ' revisions back means comparison of the edited file with last commited
21842 \begin_layout Standard
21843 This feature is supported for SVN and RCS though due to the more complicated
21844 versioning scheme of RCS there is a constraint – when addressing the revisions
21845 in dialog, numbers always point to the last number in RCS revision number,
21848 We don't currently support GIT addressing of revisions, one can just compare
21849 edited document with its revision X steps backs, where X is addressed as
21853 \begin_layout Section
21854 Literate Programming
21857 \begin_layout Standard
21862 (kayvan@sylvan.com)
21866 original documentation written by
21868 Edmar Wienskoski Jr.
21871 (edmar-w-jr@technologist.com)
21874 \begin_layout Subsection
21878 \begin_layout Standard
21879 The main purpose of this documentation is to show you how to use \SpecialChar LyX
21881 programming, where it is assumed that you are familiar with this programming
21882 technique, and know what
21883 \begin_inset Quotes eld
21887 \begin_inset Quotes erd
21891 \begin_inset Quotes eld
21895 \begin_inset Quotes erd
21899 If that is not the case, please follow the web links provided in the following
21901 There is a lot of good documentation out there covering old development
21902 history to the latest tools tips.
21905 \begin_layout Standard
21906 It is also assumed that you are familiar with \SpecialChar LyX
21907 itself to a point that you
21908 are comfortable changing your \SpecialChar LyX
21909 preferences, and X resources file.
21910 If that is not the case please refer to other \SpecialChar LyX
21911 documentation to cover your
21915 \begin_layout Subsection
21916 Literate Programming
21919 \begin_layout Standard
21920 From the Literate Programming FAQ:
21923 \begin_layout Quotation
21924 Literate programming is the combination of documentation and source together
21925 in a fashion suited for reading by human beings.
21926 In fact, literate programs should be enjoyable reading, even inviting!
21927 (Sorry Bob, I couldn't resist!) In general, literate programs combine source
21928 and documentation in a single file.
21929 Literate programming tools then parse the file to produce either readable
21930 documentation or compilable source.
21931 The WEB style of literate programming was created by D.
21932 \begin_inset space \thinspace{}
21936 Knuth during the development of his \SpecialChar TeX
21937 typesetting software.
21941 \begin_layout Standard
21942 Another excerpt says:
21945 \begin_layout Quotation
21948 How is literate programming different from verbose commenting?
21951 \begin_layout Quotation
21952 There are three distinguishing characteristics.
21953 In order of importance, they are:
21957 \begin_layout Itemize
21958 flexible order of elaboration
21961 \begin_layout Itemize
21962 automatic support for browsing
21965 \begin_layout Itemize
21966 typeset documentation, especially diagrams and mathematics
21970 \begin_layout Standard
21971 Now that I sparked your curiosity, take a look in the references.
21974 \begin_layout Subsubsection
21978 \begin_layout Standard
21979 The complete Literate Programming FAQ can be found at:
21982 \begin_layout Quote
21983 Literate Programming FAQ
21984 \begin_inset Flex URL
21987 \begin_layout Plain Layout
21989 http://www.literateprogramming.com/lpfaq.pdf
21997 \begin_layout Standard
21998 The FAQ lists 23 (twenty three!) different literate programming tools.
21999 Where some are specialized or
22000 \begin_inset Quotes eld
22004 \begin_inset Quotes erd
22007 for particular programming languages, while other have general scope.
22012 for my own use for several reasons:
22015 \begin_layout Itemize
22016 It can generate the documentation either in \SpecialChar LaTeX
22020 \begin_layout Itemize
22021 It has a open architecture, i.
22022 \begin_inset space \thinspace{}
22026 \begin_inset space \space{}
22029 it is easy to plug in new filters and to perform special processing that
22034 \begin_layout Itemize
22035 There is a good selection of filters available already (the HTML is one
22039 \begin_layout Itemize
22043 \begin_layout Standard
22044 The Noweb web page can be found at:
22047 \begin_layout Quote
22049 \begin_inset Flex URL
22052 \begin_layout Plain Layout
22054 http://www.cs.virginia.edu/~nr/noweb/
22062 \begin_layout Standard
22063 Starting from there you can reach many other interesting links and even
22064 some literate program examples.
22067 \begin_layout Subsection
22069 and Literate Programming with Noweb
22072 \begin_layout Standard
22073 The \SpecialChar LyX
22074 support for Literate Programming is provided by using the generic \SpecialChar LyX
22076 converters mechanism.
22077 This support is provided in a
22078 \begin_inset Quotes eld
22082 \begin_inset Quotes erd
22086 \begin_inset space \thinspace{}
22090 \begin_inset space \space{}
22093 you will be able to use this new \SpecialChar LyX
22094 feature with some other literate programming
22095 tool of your choice by just changing your \SpecialChar LyX
22099 \begin_layout Subsubsection
22100 Generating documents and code (weaving and tangling)
22103 \begin_layout Paragraph
22104 Using the noweb module
22107 \begin_layout Standard
22108 If you have installed Noweb and \SpecialChar LyX
22109 successfully, whenever you open a new document,
22110 after you have chosen its document class, use the Document->Settings menu
22112 \begin_inset Quotes eld
22116 \begin_inset Quotes erd
22120 If Noweb is correctly installed, when you click on the
22121 \begin_inset Quotes eld
22125 \begin_inset Quotes erd
22128 link, you will see the
22129 \begin_inset Quotes eld
22133 \begin_inset Quotes erd
22136 module in the available list and you can add it to your document.
22139 \begin_layout Paragraph
22143 \begin_layout Standard
22145 enables you to write code with a layout named
22146 \begin_inset Flex Noun
22149 \begin_layout Plain Layout
22156 Noweb delimits chunks like this:
22159 \begin_layout LyX-Code
22163 \begin_layout LyX-Code
22167 \begin_layout LyX-Code
22171 \begin_layout LyX-Code
22175 \begin_layout LyX-Code
22179 \begin_layout Standard
22180 The problem is that whatever is written in between the << and the
22184 must be taken literally, i.
22185 \begin_inset space \thinspace{}
22189 \begin_inset space \space{}
22193 should be prevented from making any special interpretation of what has
22195 This is also handled by
22196 \begin_inset Flex Noun
22199 \begin_layout Plain Layout
22205 , that works like a normal paragraph but has a free spacing capability.
22208 \begin_layout Standard
22209 As a special note, you can also use the
22210 \begin_inset Quotes eld
22214 \begin_inset Quotes erd
22217 construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
22221 \begin_layout LyX-Code
22225 \begin_layout LyX-Code
22226 def some_function(args):
22229 \begin_layout LyX-Code
22230 "This is the doc string for this function."
22233 \begin_layout LyX-Code
22234 print "My args: ", args
22237 \begin_layout LyX-Code
22238 @ %def some_function
22241 \begin_layout Standard
22242 For an example of this usage and the resulting cross-reference output, look
22243 at the Literate python program in
22245 LIBDIR/examples/listerrors.lyx
22247 which should make this all clear.
22250 \begin_layout Paragraph
22251 Generating the documentation
22254 \begin_layout Standard
22255 At this point you already have a new document file with a proper document
22256 class, and with some code and text on it.
22257 How do I print it? The answer is simple, you select
22259 View\SpecialChar menuseparator
22263 Just like you would do for a plain document.
22264 No special procedure is required.
22267 \begin_layout Standard
22268 To help orientate you, I will now explain what happens inside \SpecialChar LyX
22272 \begin_layout Enumerate
22275 Update\SpecialChar menuseparator
22278 menu option is chosen, a \SpecialChar LaTeX
22284 \begin_layout Standard
22285 If the document is of any literate class the generated file will be named
22286 with an extension name defined by the
22287 \begin_inset Quotes eld
22291 \begin_inset Quotes erd
22294 format (defined in the Preferences panel), otherwise the file will have
22303 \begin_layout Enumerate
22304 Note that the only difference so far is in the name of the file, no special
22305 processing is required by \SpecialChar LyX
22307 Given that you formatted the code using the
22308 \begin_inset Flex Noun
22311 \begin_layout Plain Layout
22317 layout that, by itself, takes care of the business.
22320 \begin_layout Enumerate
22321 If the document is of any literate class \SpecialChar LyX
22322 will then use the internal \SpecialChar LyX
22324 Noweb converter, followed by the Noweb to \SpecialChar LaTeX
22329 \begin_layout Plain Layout
22330 The converters are defined in the
22332 Tools\SpecialChar menuseparator
22336 \begin_inset Quotes eld
22340 \begin_inset Quotes erd
22352 manual for general information about converters.
22357 to generate the \SpecialChar LaTeX
22362 \begin_layout Standard
22363 Otherwise it will just skip this step.
22367 \begin_layout Enumerate
22368 Finally, \SpecialChar LaTeX
22369 is invoked and the regular post processing continues as in a plain
22373 \begin_layout Standard
22374 Independence from a particular
22375 \begin_inset Quotes eld
22379 \begin_inset Quotes erd
22382 is easily achieved by changing the commands that are run by the various
22386 \begin_layout Paragraph
22387 Generating the code
22390 \begin_layout Standard
22391 When the build menu option is chosen or the corresponding button in the
22392 toolbar is pressed, a \SpecialChar LaTeX
22393 file is generated just like step 1 above.
22394 Next, \SpecialChar LyX
22400 This converter needs to be defined by the user and is not installed by
22401 default, though the Program format is.
22402 This converter (like any other converter) will have two parts:
22405 \begin_layout Enumerate
22406 The converter program itself.
22407 This program performs the conversion from the one format to the other (in
22408 this case, from the Noweb format to the Program pseudo-format).
22411 \begin_layout Enumerate
22412 The error log parser.
22413 This is a program whose sole purpose is to rewrite error messages in a
22414 format that \SpecialChar LyX
22416 This makes it possible for \SpecialChar LyX
22417 to place error boxes in the right places in
22421 \begin_layout Standard
22422 The first part, the
22423 \begin_inset Quotes eld
22427 \begin_inset Quotes erd
22430 setting, should be set to
22431 \begin_inset Newline newline
22435 \begin_inset Quotes eld
22443 \begin_inset Quotes erd
22447 \begin_inset Newline newline
22450 This basically means that \SpecialChar LyX
22452 \begin_inset Quotes eld
22456 \begin_inset Quotes erd
22459 (a program or script) with the name of the Noweb file (normally a file
22460 in the \SpecialChar LyX
22461 temp directory) and the directory path of the original \SpecialChar LyX
22466 \begin_layout Standard
22467 This is an implementation of
22468 \begin_inset Quotes eld
22472 \begin_inset Quotes erd
22475 that you can place in a directory on your path:
22478 \begin_layout Standard
22479 \begin_inset VSpace defskip
22485 \begin_layout Standard
22486 \begin_inset Newpage pagebreak
22492 \begin_layout Standard
22498 \begin_layout Standard
22504 \begin_layout Standard
22507 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
22510 \begin_layout Standard
22511 \begin_inset VSpace defskip
22517 \begin_layout Standard
22518 The next part of the converter setting is the
22519 \begin_inset Quotes eld
22523 \begin_inset Quotes erd
22526 which is to be set to
22527 \begin_inset Newline newline
22531 \begin_inset Quotes eld
22536 parselog=$$s/scripts/listerrors
22539 \begin_inset Quotes erd
22543 \begin_inset Newline newline
22546 This will run any errors that are generated by the
22547 \begin_inset Quotes eld
22551 \begin_inset Quotes erd
22554 process through the
22555 \begin_inset Quotes eld
22559 \begin_inset Quotes erd
22565 \begin_layout Standard
22566 The build will normally take place in \SpecialChar LyX
22567 's temporary directory, so the files
22568 produced by the conversion will be in that directory.
22570 will copy out what it regards as the `main' file, but the
22574 conversion may produce several files, and so most of these would then be
22575 deleted when \SpecialChar LyX
22577 This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
22578 the build-script chunk can place the generated files in that location.
22581 \begin_layout Paragraph
22582 Build instructions in the document
22585 \begin_layout Standard
22586 The last piece of the integration between \SpecialChar LyX
22588 \begin_inset Quotes eld
22592 \begin_inset Quotes erd
22596 Generally, the instructions for building your program should be embedded
22597 in a chunk of its own.
22599 \begin_inset Quotes eld
22603 \begin_inset Quotes erd
22606 above uses the notangle command to look for this chunk (called
22607 \begin_inset Quotes eld
22611 \begin_inset Quotes erd
22614 ) and runs its contents through
22615 \begin_inset Quotes eld
22619 \begin_inset Quotes erd
22625 \begin_layout Standard
22626 Typically, such a chunk would look something like this:
22629 \begin_layout LyX-Code
22633 \begin_layout LyX-Code
22635 \begin_inset Newline newline
22638 if [ -z "${NOWEB_SOURCE}" ]
22639 \begin_inset Newline newline
22645 \begin_layout LyX-Code
22646 NOWEB_SOURCE=myfile.nw
22647 \begin_inset Newline newline
22651 \begin_inset Newline newline
22655 code to extract files ...
22656 use NOWEB_OUTPUT_DIR here ...]
22657 \begin_inset Newline newline
22661 code to compile files ...]
22662 \begin_inset Newline newline
22668 \begin_layout Standard
22671 LIBDIR/examples/listerrors.lyx
22675 LIBDIR/examples/Literate.lyx
22677 which implement two versions of the
22678 \begin_inset Quotes eld
22682 \begin_inset Quotes erd
22685 program for some illustrations of how all of these pieces go together or
22688 LIBDIR/examples/noweb2lyx.lyx.
22691 Interestingly, these three files show off the language-indepence of the
22693 literate programming support since they are written in Python, C and Perl
22697 \begin_layout Subsubsection
22698 Configuring \SpecialChar LyX
22702 \begin_layout Standard
22703 All the Literate Programming support is configured by the
22705 Tools\SpecialChar menuseparator
22709 \begin_inset Quotes eld
22713 \begin_inset Quotes erd
22717 The important parts are:
22720 \begin_layout Description
22722 \begin_inset space ~
22726 \begin_inset Quotes eld
22730 \begin_inset Quotes erd
22734 \begin_inset space ~
22737 format Set up via the File Formats tab, this is where the Noweb-specific
22747 , the file extension is set to
22752 This tells \SpecialChar LyX
22753 to create a file with a
22757 extension in the first step of the conversion process.
22760 \begin_layout Description
22762 \begin_inset space ~
22770 \begin_inset space ~
22773 format This is an empty format whose sole purpose is to be the endpoint
22774 of a conversion (which then allows us to set up a converter for it).
22777 \begin_layout Description
22787 This converter performs the
22788 \begin_inset Quotes eld
22792 \begin_inset Quotes erd
22795 of the literate document.
22796 For Noweb, it is set to
22797 \begin_inset Quotes eld
22802 noweave -delay -index $$i > $$o
22805 \begin_inset Quotes erd
22811 \begin_layout Description
22821 \begin_inset Quotes eld
22825 \begin_inset Quotes erd
22829 As stated above, the Converter is set to
22830 \begin_inset Quotes eld
22838 \begin_inset Quotes erd
22841 , with Flags set to
22842 \begin_inset Newline newline
22846 \begin_inset Quotes eld
22851 parselog=$$s/scripts/listerrors
22854 \begin_inset Quotes erd
22860 \begin_layout Subsubsection
22864 \begin_layout Standard
22865 There is also a new function implemented in the \SpecialChar LyX
22867 \begin_inset Quotes eld
22870 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
22874 \begin_layout Standard
22875 When debugging code with ddd/gdb, it is possible to invoke a text editor
22876 at the current execution position with a single key stroke.
22877 The default ddd configuration for that is shift-ctrl-V.
22878 It happens that you can define the editor command line invocation in ddd
22881 Edit\SpecialChar menuseparator
22882 Preferences\SpecialChar menuseparator
22885 dialog and changing the "Edit Sources" entry.
22888 \begin_layout Standard
22889 I take advantage of the newly created \SpecialChar LyX
22890 server function and this ddd feature,
22892 \begin_inset Quotes eld
22896 \begin_inset Quotes erd
22902 \begin_layout Standard
22903 \begin_inset VSpace defskip
22909 \begin_layout Standard
22912 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
22915 \begin_layout Standard
22916 \begin_inset VSpace defskip
22922 \begin_layout Standard
22923 With this, whenever you are using ddd and find a point in the program that
22924 you want to edit, you just press shift-ctrl-V (in the ddd window), and
22925 ddd will forward this information to \SpecialChar LyX
22926 through the \SpecialChar LyX
22927 server and then the
22929 window will show the same file with the cursor at the same position ddd
22931 No more guessing or long scrolling to locate a point in the program back
22935 \begin_layout Standard
22936 Note however that you must enable the \SpecialChar LyX
22937 server to get this feature working
22938 (it is disabled by default).
22939 You can enable it in
22951 ) by entering in the
22957 \begin_inset Quotes eld
22962 /home/<your-home-directory>/.lyx/lyxpipe
22965 \begin_inset Quotes erd
22971 \begin_layout Standard
22972 Read the \SpecialChar LyX
22973 server documentation in the
22975 Customization Manual
22977 for further information.
22980 \begin_layout Subsubsection
22984 \begin_layout Standard
22985 There are six new buttons that can be added to your \SpecialChar LyX
22987 Five of these buttons are short cuts to layout styles:
23010 The last one is a short cut to the
23011 \begin_inset Quotes eld
23015 \begin_inset Quotes erd
23022 \begin_layout Standard
23024 has a range of buttons that are available for tool bar customization.
23025 In my toolbar I like to combine the six short cuts above with two more:
23030 \SpecialChar menuseparator
23035 \SpecialChar menuseparator
23042 Document\SpecialChar menuseparator
23043 View\SpecialChar menuseparator
23047 Here is how it looks like:
23050 \begin_layout LyX-Code
23054 \begin_layout LyX-Code
23058 \begin_layout LyX-Code
23059 Icon "layout Standard"
23062 \begin_layout LyX-Code
23063 Icon "layout Section"
23066 \begin_layout LyX-Code
23067 Icon "layout \SpecialChar LaTeX
23071 \begin_layout LyX-Code
23072 Icon "layout \SpecialChar LyX
23076 \begin_layout LyX-Code
23077 Icon "layout Chunk"
23080 \begin_layout LyX-Code
23084 \begin_layout LyX-Code
23088 \begin_layout LyX-Code
23089 Icon "buffer-typeset"
23092 \begin_layout LyX-Code
23093 Icon "build-program"
23096 \begin_layout LyX-Code
23100 \begin_layout LyX-Code
23104 \begin_layout LyX-Code
23108 \begin_layout LyX-Code
23112 \begin_layout LyX-Code
23116 \begin_layout Subsubsection
23117 Colors customization
23120 \begin_layout Standard
23121 There are a number of colors in \SpecialChar LyX
23122 that can be customized in
23127 One of the things that bothers people is the \SpecialChar LaTeX
23129 The default color is red, since the chunks uses \SpecialChar LaTeX
23130 font, and there is a lot
23131 of chunks in literate documents, you may get tired of seeing everything
23133 You can change it by going to the tabs
23142 \begin_layout Standard
23143 The next thing is the visible presence of the newline character in the screen.
23144 You can choose the color of this particular character and make it blend
23146 I recommend you choosing a color that is close to the background but not
23147 equal, that way you still can see it is there, but it is not bothering
23151 \begin_layout Subsection
23156 \begin_layout Standard
23165 is documented in the
23169 example file and in the Sweave manual (menu
23171 Help\SpecialChar menuseparator
23177 \begin_layout Chapter
23182 \begin_layout Standard
23183 Users sometimes need to be able to
23184 \begin_inset Quotes eld
23188 \begin_inset Quotes erd
23192 file together with all the images (and other files) on which it depends,
23193 either for sending to a publisher or for sharing with a co-author.
23195 2.0 includes a Python script (
23196 \begin_inset Flex Code
23199 \begin_layout Plain Layout
23205 ) that automates this process.
23206 To use it, you must have either the
23207 \begin_inset Flex Code
23210 \begin_layout Plain Layout
23217 \begin_inset Flex Code
23220 \begin_layout Plain Layout
23226 python modules installed on your system.
23227 By default, the script prefers the
23228 \begin_inset Flex Code
23231 \begin_layout Plain Layout
23238 \begin_inset Flex Code
23241 \begin_layout Plain Layout
23247 format on Unix-like systems and the
23248 \begin_inset Flex Code
23251 \begin_layout Plain Layout
23260 \begin_layout Standard
23262 's configuration process will set the script up to export a `\SpecialChar LyX
23264 and this format will then be available under
23265 \begin_inset Flex Code
23268 \begin_layout Plain Layout
23269 File\SpecialChar menuseparator
23278 \begin_layout Standard
23279 Independently of the platform, the generation of a particular archive format
23280 can be forced by adding either the
23281 \begin_inset Flex Code
23284 \begin_layout Plain Layout
23291 \begin_inset Flex Code
23294 \begin_layout Plain Layout
23301 \begin_inset Flex Code
23304 \begin_layout Plain Layout
23311 \begin_inset Flex Code
23314 \begin_layout Plain Layout
23320 format) switch to the
23321 \begin_inset Flex Code
23324 \begin_layout Plain Layout
23326 \SpecialChar menuseparator
23334 \begin_inset Flex Code
23337 \begin_layout Plain Layout
23338 Tools\SpecialChar menuseparator
23339 Preferences\SpecialChar menuseparator
23340 File Handling\SpecialChar menuseparator
23347 (Make sure you add the switch after the script name, not before it.)
23350 \begin_layout Chapter
23352 and the World Wide Web
23355 \begin_layout Standard
23357 has long supported the export of documents to various web-friendly formats,
23359 Before verson 2.0, however, HTML export was always accomplished by the use
23360 of external converters.
23364 \begin_layout Plain Layout
23365 For details on the use of external converters with \SpecialChar LyX
23370 section of the Customization manual.
23375 These fall into two large groups: there are converters that use \SpecialChar LaTeX
23377 intermediate format, such as
23378 \begin_inset Flex Code
23381 \begin_layout Plain Layout
23388 \begin_inset Flex Code
23391 \begin_layout Plain Layout
23398 \begin_inset Flex Code
23401 \begin_layout Plain Layout
23407 , relying upon \SpecialChar LyX
23408 to produce the \SpecialChar LaTeX
23409 ; and there is a converter that works directly
23410 on \SpecialChar LyX
23412 \begin_inset Flex Code
23415 \begin_layout Plain Layout
23423 All of these have different advantages and disadvantages.
23427 \begin_layout Standard
23428 The \SpecialChar LaTeX
23429 -based converters have the advantage that, in principle, they know everythin
23430 g about the exported document that \SpecialChar LaTeX
23432 Such converters do not care, for example, if a certain block of code was
23433 produced by \SpecialChar LyX
23434 or was Evil Red Text.
23435 These converters know about
23436 \begin_inset Flex Code
23439 \begin_layout Plain Layout
23445 files, counters, and references, and can often make use of the
23446 \begin_inset Flex Code
23449 \begin_layout Plain Layout
23455 files generated by Bib\SpecialChar TeX
23457 On the other hand, \SpecialChar LaTeX
23458 is a very hard language to parse—it is sometimes said
23459 that only \SpecialChar TeX
23460 itself understands \SpecialChar TeX
23461 —and \SpecialChar LaTeX
23462 -based converters will often choke on
23463 what seem to be quite simple constructs; complex ones can throw them completely
23464 , and as of this writing, for example, the
23468 manual will not export with
23469 \begin_inset Flex Code
23472 \begin_layout Plain Layout
23478 , though the others will.
23479 The other issue concerns how math is handled.
23480 These converters typically convert the formulae into little pictures that
23481 are then linked from the HTML document.
23482 Since these are actually generated by \SpecialChar LaTeX
23483 , they are accurate.
23484 But they do not scale well, and just getting them to look as if they are
23485 actually meant to be in your document—so that the font sizes seem to be
23486 roughly the same—can be a challenge.
23489 \begin_layout Standard
23491 \begin_inset Flex Code
23494 \begin_layout Plain Layout
23502 \begin_inset CommandInset href
23504 name "http://elyxer.nongnu.org/"
23505 target "http://elyxer.nongnu.org/"
23509 ) solves some of these problems.
23510 In particular, the formulae it produces scale perfectly, since it renders
23511 math using a combination of HTML and CSS rather than converting the formulae
23513 But even moderately complex formula are rendered less well than with
23514 \begin_inset Flex Code
23517 \begin_layout Plain Layout
23523 ; this reflects the limitations of HTML.
23527 \begin_layout Plain Layout
23529 \begin_inset Flex Code
23532 \begin_layout Plain Layout
23539 can also use jsMath and MathJax for equations, but this setting is only
23540 available globally and requires one to have access to a server that runs
23546 More importantly (as of version 1.1.1, at least),
23547 \begin_inset Flex Code
23550 \begin_layout Plain Layout
23557 has limited support for math macros and no support for user-defined paragraph
23558 or character styles.
23559 These limitations make
23560 \begin_inset Flex Code
23563 \begin_layout Plain Layout
23570 unsuitable for many of the documents \SpecialChar LyX
23572 In principle, of course, these problems could be solved, but the \SpecialChar LyX
23574 have decided to follow a different path and have made \SpecialChar LyX
23576 writing XHTML, just as it is capable of writing \SpecialChar LaTeX
23577 , DocBook, and plaintext.
23580 \begin_layout Standard
23581 As of this writing, XHTML output remains under development and should probably
23583 \begin_inset Quotes eld
23587 \begin_inset Quotes erd
23594 \begin_layout Plain Layout
23596 \begin_inset Flex Code
23599 \begin_layout Plain Layout
23600 development/HTML.notes
23605 , which can be found in the \SpecialChar LyX
23607 \begin_inset CommandInset href
23609 name "accessed online"
23610 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
23614 , usually contains up-to-date information about the state of XHTML output.
23615 See also the list of XHTML bugs on
23616 \begin_inset CommandInset href
23618 name "the bug tracker"
23619 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"
23628 Still, the developers have chosen this approach because it has several
23629 potential advantages over the other two.
23632 \begin_layout Standard
23633 These advantages are primarily due to the fact that the XHTML output routines,
23634 since they are part of \SpecialChar LyX
23635 , know everything \SpecialChar LyX
23636 knows about the document being
23641 \begin_layout Plain Layout
23642 Another advantage is that, since these routines are internal to \SpecialChar LyX
23644 immune to changes in \SpecialChar LyX
23645 's file format, or to changes in the semantics of
23651 So they know about the table of contents (as displayed in the outline),
23652 about the counters associated with different paragraph styles, and about
23653 user-defined styles.
23654 The XHTML output routines know what \SpecialChar LyX
23655 knows about internationalization,
23656 too, so they will output
23657 \begin_inset Quotes eld
23661 \begin_inset Quotes erd
23665 \begin_inset Quotes eld
23673 \begin_inset Quotes erd
23676 , depending upon the language in effect at the time.
23680 \begin_layout Standard
23681 Quite generally, the output routines know what \SpecialChar LyX
23682 knows about document layout,
23683 that is, about how the document is to be rendered on screen.
23684 We use this information when we output the document as XHTML.
23685 In particular, \SpecialChar LyX
23690 generates CSS style information corresponding to the layout information
23691 it uses to render the document on screen: if section headings are supposed
23692 to be sans-serif and bold as seen in \SpecialChar LyX
23693 , then (by default) they will be sans-seri
23694 f and bold when viewed in a web browser, too.
23695 And this is true not just for pre-defined styles, like Section, but for
23696 any style, including user-defined styles.
23697 Indeed, the XHTML output routines make no distinction between user-defined
23698 paragraph and character styles and \SpecialChar LyX
23699 's own pre-defined styles: in each case,
23700 everything \SpecialChar LyX
23701 knows about the styles is contained in the layout files.
23702 And much the same is true as regards pre-defined textual insets, such as
23703 footnotes, and various custom insets.
23707 \begin_layout Standard
23708 The result is that XHTML output can be customized and extended in exactly
23709 the same way \SpecialChar LaTeX
23710 output can be customized and extended: through layout files
23712 See chapter five of the
23716 manual for the details.
23719 \begin_layout Standard
23720 The remainder of this chapter contains more detailed information on XHTML
23721 output, its limitations, and ways to work around those limitations.
23724 \begin_layout Section
23725 Math Output in XHTML
23728 \begin_layout Standard
23730 offers four choices for how math is rendered.
23731 These have various advantages and disadvantages:
23734 \begin_layout Itemize
23736 \begin_inset Newline newline
23739 MathML is a dialect of XML designed specifically for mathematics on the
23740 web, and it typically renders very well in browsers that support it.
23741 The disadvantage is that not all browsers support MathML, and support is
23742 not complete even in the Gecko-based browsers, such as Firefox.
23743 \begin_inset Newline newline
23746 If \SpecialChar LyX
23747 is unable to render a formula as MathML—for example, if the formula
23749 \begin_inset Flex Code
23752 \begin_layout Plain Layout
23758 package or ERT—then it will instead output the formula as an image.
23762 \begin_layout Itemize
23764 \begin_inset Newline newline
23767 As mentioned above,
23768 \begin_inset Flex Code
23771 \begin_layout Plain Layout
23777 outputs math as HTML, styled by CSS.
23781 \begin_layout Plain Layout
23783 has borrowed some of the CSS for its HTML output from
23784 \begin_inset Flex Code
23787 \begin_layout Plain Layout
23798 For simple formulae, this can work quite well, though with more complicated
23799 formulae it tends to break down.
23800 Still, this method has the advantage that it is very widely supported and
23801 so it may be appropriate for documents that contain only a little, fairly
23803 \begin_inset Newline newline
23806 If Lyx is unable to render a formula as HTML—for example, if the formula
23808 \begin_inset Flex Code
23811 \begin_layout Plain Layout
23817 package or ERT—then it will instead output the formula as an image.
23821 \begin_layout Itemize
23823 \begin_inset Newline newline
23827 \begin_inset Flex Code
23830 \begin_layout Plain Layout
23837 will output formulae as images, the very same images, in fact, that are
23838 used for instant preview.
23842 \begin_layout Plain Layout
23843 Instant preview does
23847 have to be on for images to be output, however.
23852 The advantage to this method is that the images are simply generated by
23854 , so they are very accurate.
23855 The disadvantage, as mentioned earlier, is that these are bitmapped images,
23856 so they do not scale terribly well, and one cannot copy them, etc.
23857 (As of this writing, there are also problems about equation numbering.
23859 \begin_inset CommandInset href
23862 target "http://www.lyx.org/trac/ticket/6894"
23867 \begin_inset Newline newline
23870 The size of the images can be controlled by setting the
23871 \begin_inset Quotes eld
23874 Math Images Scaling
23875 \begin_inset Quotes erd
23879 \begin_inset Flex Noun
23882 \begin_layout Plain Layout
23883 Document\SpecialChar menuseparator
23884 Settings\SpecialChar menuseparator
23894 \begin_layout Plain Layout
23895 For those who want to know, this controls the resolution of the image in
23896 dots per inch and is based upon a default of 75 dpi.
23902 \begin_inset Newline newline
23905 If \SpecialChar LyX
23906 for some reason fails to create an image for a formula (e.g., if a required
23908 package is not installed), then it will fall back to outputing the raw
23913 \begin_layout Itemize
23916 \begin_inset Newline newline
23919 Finally, \SpecialChar LyX
23920 will happily output math as \SpecialChar LaTeX
23922 As well as being the output of last resort, this method can be used with
23924 \begin_inset CommandInset href
23927 target "http://www.math.union.edu/~dpvc/jsMath/"
23931 , which uses JavaScript to render \SpecialChar LaTeX
23932 embedded in HTML documents.
23934 wraps the \SpecialChar LaTeX
23936 \begin_inset Flex Code
23939 \begin_layout Plain Layout
23945 (for inline formulas) or
23946 \begin_inset Flex Code
23949 \begin_layout Plain Layout
23955 (for displayed formulas) with
23956 \begin_inset Flex Code
23959 \begin_layout Plain Layout
23965 , as is required for jsMath.
23968 \begin_layout Standard
23969 One of these output methods must be selected under
23970 \begin_inset Flex Noun
23973 \begin_layout Plain Layout
23974 Document\SpecialChar menuseparator
23975 Settings\SpecialChar menuseparator
23982 By default, \SpecialChar LyX
23984 This is a document-wide setting, therefore.
23987 \begin_layout Standard
23988 Eventually, \SpecialChar LyX
23989 will offer the user the option to select an alternate output
23990 method for a particular inset, say, one that isn't being rendered very
23995 \begin_layout Plain Layout
23996 That said, since \SpecialChar LyX
23997 falls back to images if the inset contains ERT, then one
23998 can force output as an image by putting some harmless ERT into the math,
24000 \begin_inset Formula $a=b\relax$
24011 \begin_layout Section
24012 Bibliography and Citations
24015 \begin_layout Standard
24016 XHTML output fully supports bibliographies and citations.
24020 \begin_layout Standard
24021 Citation labels are generated by the same machinery that generates \SpecialChar LyX
24023 labels, so the labels will look in the output much as they do in \SpecialChar LyX
24026 If you are using numerical citations, then \SpecialChar LyX
24027 will output numerical labels,
24028 such as [1] or [17], rather than simply showing the citation key in square
24029 brackets, as it does on-screen.
24030 If you are using author-year citations, then \SpecialChar LyX
24031 will add lowercase letters
24032 to the years, just as Bib\SpecialChar TeX
24033 does, if it finds more than one citation for
24034 a given author-year combination.
24035 The labels will be printed with the bibliography entries.
24036 Note that there is, at present, no way to customize the appearance of the
24037 labels, for example, to choose between square brackets and parentheses.
24040 \begin_layout Standard
24041 Bibliography output is handled by the same machinery that handles the presentati
24042 on of reference information in the citation dialog, so you will see in the
24043 XHTML output pretty much what you would see if you were to look at a given
24044 entry in the citation dialog.
24045 The formatting can be customized in your layout file or, preferably, in
24051 manual for the details.
24054 \begin_layout Standard
24055 The main defect at present is that cross-referenced information is printed
24056 with every entry with which it is associated.
24057 So you can see things like this:
24060 \begin_layout Quote
24062 \begin_inset Quotes eld
24065 Context and Logical Form
24066 \begin_inset Quotes erd
24071 Language in Context: Selected Essays
24073 (Oxford: Oxford University Press, 2007), pp.
24077 \begin_layout Quote
24079 \begin_inset Quotes eld
24082 Semantics in Context
24083 \begin_inset Quotes erd
24088 Language in Context: Selected Essays
24090 (Oxford: Oxford University Press, 2007), pp.
24094 \begin_layout Standard
24095 This should be fixed before long.
24098 \begin_layout Standard
24099 There is no support at present for sectioned bibliographies.
24100 If you have multiple bibliographies, then \SpecialChar LyX
24101 will print the same bibliography
24105 \begin_layout Section
24109 \begin_layout Standard
24111 will happily export indexes as XHTML, but with certain limitations at the
24115 \begin_layout Standard
24116 Index export will be most reliable when you do not attempt to use the fancy
24117 constructs that are described in the section on indexes in the
24125 \begin_layout Plain Layout
24126 The main issue here is that \SpecialChar LyX
24127 itself does not really handle these.
24128 It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
24134 We'll describe how they are handled using the subsection headings from
24138 \begin_layout Itemize
24139 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
24140 makes an effort to support these,
24141 but the entries must be separated by
24142 \begin_inset Quotes eld
24146 \begin_inset Quotes erd
24149 , that is, there must be spaces around the exclamation point.
24150 This is because it is otherwise too difficult to check for escaped exclamation
24151 points, ones in math, and so forth.
24154 \begin_layout Itemize
24155 Page Ranges: There is no support at all for page ranges, since these make
24156 no sense with XHMTL.
24157 Instead, you will just get two index entries, one at either end.
24160 \begin_layout Itemize
24161 Cross-referencing: There is no support for cross-referencing.
24162 If \SpecialChar LyX
24163 finds an entry containing the
24164 \begin_inset Quotes eld
24167 |see\SpecialChar ldots
24169 \begin_inset Quotes erd
24172 construct, it is just dropped, and the rest is treated as an ordinary index
24176 \begin_layout Itemize
24177 Index Entry Order: \SpecialChar LyX
24178 does support attempts to fix the sorting order.
24179 It will take what is before the first `@' it finds and use that for sorting,
24180 taking what follows the first `@' to be the actual entry.
24181 At present, \SpecialChar LyX
24182 does not check for escaped `@', so do not try to index email
24186 \begin_layout Itemize
24187 Index Entry Layout: You can format entries by using the text style dialog,
24188 or by using any other method available within \SpecialChar LyX
24190 There is no support for constructs like:
24191 \begin_inset Quotes eld
24195 \begin_inset Quotes erd
24199 Indeed, if \SpecialChar LyX
24200 finds a pipe symbol, `|', in an entry, it will delete it and
24201 everything that follows it.
24204 \begin_layout Itemize
24205 Multiple Indexes: There is no support for multiple indexes.
24206 Rather, all index entries will be printed as one large index.
24207 To avoid our printing several versions of the index, we print only the
24208 main index, so make sure you have one.
24211 \begin_layout Section
24212 Nomenclature and Glossary
24215 \begin_layout Standard
24216 There is at present no support for glossaries.
24217 Adding it would be fairly trivial, and welcome.
24220 \begin_layout Chapter
24221 The \SpecialChar LyX
24225 \begin_layout Section
24229 \begin_layout Standard
24230 The `\SpecialChar LyX
24231 server' allows other programs to talk to \SpecialChar LyX
24232 , invoke \SpecialChar LyX
24233 commands, and retrieve
24234 information about the \SpecialChar LyX
24236 This is only intended for advanced users, but they should find it useful.
24237 It is by writing to the \SpecialChar LyX
24238 server, for example, that bibliography managers,
24239 such as JabRef, are able to
24240 \begin_inset Quotes eld
24244 \begin_inset Quotes erd
24247 citations to \SpecialChar LyX
24251 \begin_layout Section
24252 Starting the \SpecialChar LyX
24256 \begin_layout Standard
24257 The \SpecialChar LyX
24258 server works through the use of a pair of named pipes.
24259 These are usually located in
24260 \begin_inset Flex Code
24263 \begin_layout Plain Layout
24269 , (except on Windows, where
24273 named pipes are special objects located in
24274 \begin_inset Flex Code
24277 \begin_layout Plain Layout
24289 ) and have the names
24290 \begin_inset Quotes eld
24294 \begin_inset Flex Code
24297 \begin_layout Plain Layout
24304 \begin_inset Quotes erd
24308 \begin_inset Quotes eld
24312 \begin_inset Flex Code
24315 \begin_layout Plain Layout
24322 \begin_inset Quotes erd
24326 External programs write into
24327 \begin_inset Flex Code
24330 \begin_layout Plain Layout
24336 and read back data from
24337 \begin_inset Flex Code
24340 \begin_layout Plain Layout
24347 The stem of the pipe names can be defined in the
24348 \begin_inset Flex Noun
24351 \begin_layout Plain Layout
24352 Tools\SpecialChar menuseparator
24358 dialog, for example
24359 \begin_inset Flex Code
24362 \begin_layout Plain Layout
24363 "/home/myhome/lyxpipe"
24369 \begin_inset Flex Code
24372 \begin_layout Plain Layout
24386 on Windows (where any working path instead of lyxpipe can be used, for
24388 \begin_inset Flex Code
24391 \begin_layout Plain Layout
24414 configure this manually in order for the server to start.
24417 \begin_layout Standard
24420 \begin_inset Flex Code
24423 \begin_layout Plain Layout
24430 \begin_inset Flex Code
24433 \begin_layout Plain Layout
24439 ' to create the pipes.
24440 If one of the pipes already exists, \SpecialChar LyX
24441 will assume that another \SpecialChar LyX
24443 is already running and will not start the server.
24444 On POSIX (Unix like) systems, if for some other reason, an unused
24445 \begin_inset Quotes eld
24449 \begin_inset Quotes erd
24452 pipe is left in existence when \SpecialChar LyX
24453 closes, then \SpecialChar LyX
24454 will try to delete it.
24455 If this fails for some reason, you will need to delete the pipes manually
24456 and then restart \SpecialChar LyX
24458 On Windows, pipes are deleted by the OS on program termination or crash,
24460 \begin_inset Quotes eld
24464 \begin_inset Quotes erd
24467 pipes should not be possible.
24470 \begin_layout Standard
24471 To have several \SpecialChar LyX
24472 processes with servers at the same time, you have to use
24473 different configurations, perhaps by using separate user directories, each
24475 \begin_inset Flex Code
24478 \begin_layout Plain Layout
24484 file, for each process.
24487 \begin_layout Standard
24488 If you are developing a client program, you might find it useful to enable
24489 debugging information from the \SpecialChar LyX
24491 Do this by starting \SpecialChar LyX
24493 \begin_inset Flex Code
24496 \begin_layout Plain Layout
24505 \begin_layout Standard
24506 You can find a complete example client written in C++ in the source distribution
24508 \begin_inset Flex Code
24511 \begin_layout Plain Layout
24512 development/lyxserver/server_monitor.cpp
24520 \begin_layout Standard
24521 Another useful tool is the command-line based client found in
24522 \begin_inset Flex Code
24525 \begin_layout Plain Layout
24526 src/client/lyxclient
24534 \begin_layout Section
24535 Normal communication
24538 \begin_layout Standard
24539 To issue a \SpecialChar LyX
24540 call, the client writes a line of ASCII text into the input
24542 This line has the following format:
24545 \begin_layout Quote
24559 \begin_layout Description
24560 clientname is a name that the client can choose arbitrarily.
24561 Its only use is that \SpecialChar LyX
24562 will echo it if it sends an answer—so a client can
24563 dispatch results from different requesters.
24566 \begin_layout Description
24567 function is the function you want \SpecialChar LyX
24569 It is the same as the commands you'd use in the minibuffer.
24572 \begin_layout Description
24573 argument is an optional argument which is meaningful only to some functions
24575 \begin_inset Quotes eld
24579 \begin_inset Quotes erd
24582 LFUN will insert the argument as text at the cursor position).
24585 \begin_layout Standard
24586 The answer from \SpecialChar LyX
24587 will arrive in the output pipe and be of the form
24590 \begin_layout Quote
24604 \begin_layout Standard
24613 are just echoed from the command request, while
24617 is more or less useful information filled according to how the command
24618 execution worked out.
24619 Some commands, such as
24620 \begin_inset Quotes eld
24624 \begin_inset Quotes erd
24627 , will return information about the internal state of \SpecialChar LyX
24629 return an empty data-response.
24630 This means that the command execution went fine.
24633 \begin_layout Standard
24634 In case of errors, the response from \SpecialChar LyX
24635 will have this form
24638 \begin_layout Quote
24652 \begin_layout Standard
24657 should contain an explanation of why the command failed.
24660 \begin_layout Standard
24664 \begin_layout LyX-Code
24665 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
24666 \begin_inset Newline newline
24669 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
24670 \begin_inset Newline newline
24673 read a <~/.lyxpipe.out
24674 \begin_inset Newline newline
24680 \begin_layout Subsection
24681 AppleScript (Mac OS X)
24684 \begin_layout Standard
24685 Since \SpecialChar LyX
24686 2.1, \SpecialChar LyX
24687 supports basic interactions with AppleScript for normal communicatio
24688 n through the command run.
24689 This command takes a direct argument (the
24693 to perform) and an optional argument.
24694 It either returns the output of the function or triggers an error with
24695 the error message and code.
24698 \begin_layout Standard
24702 \begin_layout LyX-Code
24703 tell application "\SpecialChar LyX
24707 \begin_layout LyX-Code
24711 \begin_layout LyX-Code
24712 -- Stores the current file name into f
24715 \begin_layout LyX-Code
24716 set f to (run "server-get-filename" with argument "")
24719 \begin_layout LyX-Code
24720 on error the error_message number the error_number
24723 \begin_layout LyX-Code
24724 display dialog "Error: " & the error_number & ".
24728 \begin_layout LyX-Code
24729 & the error_message buttons {"OK"} default button 1
24732 \begin_layout LyX-Code
24736 \begin_layout LyX-Code
24740 \begin_layout Section
24744 \begin_layout Standard
24746 can notify clients of events going on asynchronously.
24747 Currently it will only do this if the user binds a key sequence with the
24749 \begin_inset Quotes eld
24753 \begin_inset Quotes erd
24757 The format of the string \SpecialChar LyX
24758 sends is as follows:
24761 \begin_layout Quote
24762 \begin_inset Flex Code
24765 \begin_layout Plain Layout
24776 \begin_layout Standard
24781 is the printed representation of the key sequence that was actually typed
24785 \begin_layout Standard
24786 This mechanism can be used to extend \SpecialChar LyX
24787 's command set and implement macros.
24788 Bind some key sequence to
24789 \begin_inset Quotes eld
24793 \begin_inset Quotes erd
24797 Then start a client that listens on the output pipe, dispatches the command
24798 according to the sequence, and starts a function that may use \SpecialChar LyX
24801 requests to issue a command or a series of commands to \SpecialChar LyX
24805 \begin_layout Section
24806 The simple \SpecialChar LyX
24810 \begin_layout Standard
24812 implements a simple protocol that can be used for session management.
24813 All messages are of the form
24816 \begin_layout Quote
24826 \begin_layout Standard
24832 \begin_inset Quotes eld
24836 \begin_inset Quotes erd
24840 \begin_inset Quotes eld
24844 \begin_inset Quotes erd
24849 \begin_inset Quotes eld
24853 \begin_inset Quotes erd
24856 is received from a client, \SpecialChar LyX
24857 will report back to inform the client that
24858 it's listening to it's messages, while
24859 \begin_inset Quotes eld
24863 \begin_inset Quotes erd
24866 sent from \SpecialChar LyX
24867 will inform clients that \SpecialChar LyX
24871 \begin_layout Section
24872 Reverse DVI/PDF search
24875 \begin_layout Standard
24876 Some DVI/PDF viewers
24880 \begin_layout Plain Layout
24881 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
24882 Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
24891 facility (also called
24896 This means that you can tell \SpecialChar LyX
24897 to put the cursor to a specific line in the
24898 document by clicking at the respective position in the DVI/PDF output.
24899 To achieve this, the viewer must be able to communicate with \SpecialChar LyX
24901 This is done via the \SpecialChar LyX
24902 server either by using the named pipe (
24906 ), or the UNIX domain socket (
24910 ) that \SpecialChar LyX
24911 creates in its temporary directory (this is the way the
24912 \begin_inset Flex Code
24915 \begin_layout Plain Layout
24921 program communicates with \SpecialChar LyX
24923 In some cases, you need a helper script that mediates between the viewer
24924 and \SpecialChar LyX
24925 , in others, the viewer can communicate with \SpecialChar LyX
24927 This depends on the selected viewer and on your operating system.
24928 The same applies to the way viewers need to be configured and the way the
24929 reverse search is actually performed.
24930 In what follows, we will thus describe how to setup reverse search for
24932 Before we turn to this, though, we will explain what needs to be done generally
24933 to enable reverse search in the DVI/PDF output.
24936 \begin_layout Subsection
24938 \begin_inset CommandInset label
24940 name "subsec:rev-search"
24947 \begin_layout Standard
24948 In most cases \SpecialChar LyX
24949 will do the work for you by enabling the option
24950 \begin_inset Flex Noun
24953 \begin_layout Plain Layout
24954 Synchronize with Output
24960 \begin_inset Flex Noun
24963 \begin_layout Plain Layout
24964 Document\SpecialChar menuseparator
24965 Settings\SpecialChar menuseparator
24972 In such a case \SpecialChar LyX
24973 will automatically insert the necessary Sync\SpecialChar TeX
24975 PDF) or load the srcltx package (for DVI) respectively.
24976 This option can be easily reached also on
24977 \begin_inset Flex Code
24980 \begin_layout Plain Layout
24989 \begin_layout Standard
24990 If you need a different setting, you can select or input a custom macro
24991 from the drop down box just below
24992 \begin_inset Flex Noun
24995 \begin_layout Plain Layout
24996 Document\SpecialChar menuseparator
24997 Settings\SpecialChar menuseparator
24998 Output\SpecialChar menuseparator
24999 Synchronize with Output
25007 \begin_layout Standard
25008 Note that the method
25009 \begin_inset Flex Code
25012 \begin_layout Plain Layout
25020 enables gzip compression.
25021 If your viewer does not support it, you should instead use
25022 \begin_inset Flex Code
25025 \begin_layout Plain Layout
25036 \begin_layout Standard
25037 Please also note that including the
25038 \begin_inset Flex Code
25041 \begin_layout Plain Layout
25048 \begin_inset Flex Code
25051 \begin_layout Plain Layout
25057 sometimes has an undesired impact on the typesetting.
25058 Thus, you should switch output synchronization off for the final typesetting
25060 \begin_inset Flex Code
25063 \begin_layout Plain Layout
25070 \begin_inset Flex Code
25073 \begin_layout Plain Layout
25083 \begin_layout Standard
25084 In case you need some more special settings that are not covered by the
25085 automatic settings, read the next section about how to set up output synchroniz
25087 If the automatic setup suits your needs, you can readily jump to section
25088 \begin_inset space ~
25092 \begin_inset CommandInset ref
25094 reference "subsec:configuring-viewers"
25098 , where the necessary configuration steps in your viewer – needed both with
25099 the automatic and the manual setup – are described.
25102 \begin_layout Subsection
25106 \begin_layout Standard
25108 provides several different methods for reverse search.
25109 Some are built-in in the
25110 \begin_inset Flex Code
25113 \begin_layout Plain Layout
25119 program, some are provided by external packages.
25120 Your choice depends on whether your \SpecialChar LaTeX
25121 distribution already provides a given
25122 method (the built-in methods are rather new) and whether your viewer can
25124 The available methods are described in the following.
25127 \begin_layout Subsubsection*
25128 Built-in DVI-search via src-specials (DVI only)
25131 \begin_layout Standard
25132 This method provides the DVI file with the necessary information for reverse
25134 It is available in \SpecialChar LaTeX
25135 since quite some time (any somewhat recent \SpecialChar LaTeX
25137 should include it), and it works reliably.
25138 To enable it, change the
25139 \begin_inset Flex Noun
25142 \begin_layout Plain Layout
25153 \begin_inset Flex Noun
25156 \begin_layout Plain Layout
25167 \begin_inset Flex Noun
25170 \begin_layout Plain Layout
25171 Preferences\SpecialChar menuseparator
25172 File Handling\SpecialChar menuseparator
25179 \begin_inset Flex Code
25182 \begin_layout Plain Layout
25183 latex -src-specials $$i
25189 If this doesn't work, check if your \SpecialChar TeX
25190 engine needs different options (the
25191 syntax might differ in some distributions).
25194 \begin_layout Subsubsection*
25195 External Packages (PDFSync and scrltx)
25198 \begin_layout Standard
25207 provide reverse search facility for PDF output (via pdflatex) and DVI output,
25209 In order to enable it, load the packages in the \SpecialChar LyX
25213 \begin_layout Itemize
25214 \begin_inset Flex Code
25217 \begin_layout Plain Layout
25220 usepackage{pdfsync}
25225 for reverse PDF search,
25228 \begin_layout Itemize
25229 \begin_inset Flex Code
25232 \begin_layout Plain Layout
25235 usepackage[active]{srcltx}
25240 for reverse DVI search.
25243 \begin_layout Standard
25244 If you want to be able to perform both DVI and PDF reverse searches, you
25245 can also insert in the preamble the following lines
25248 \begin_layout LyX-Code
25252 \begin_inset Newline newline
25258 \begin_inset Newline newline
25263 usepackage{pdfsync}
25264 \begin_inset Newline newline
25270 \begin_inset Newline newline
25275 usepackage[active]{srcltx}
25276 \begin_inset Newline newline
25284 \begin_layout Standard
25285 This way, you can preview the file as either DVI or PDF (pdflatex) and the
25286 right package will be used.
25289 \begin_layout Standard
25290 Note that PDFSync might affect the output layout of your document.
25291 It is therefore advised to disable PDFsync for final documents.
25294 \begin_layout Subsubsection*
25295 Built-in reverse search via Sync\SpecialChar TeX
25299 \begin_layout Standard
25301 \begin_inset Flex Code
25304 \begin_layout Plain Layout
25310 have built-in support for both PDF and DVI reverse search.
25313 Sync\SpecialChar TeX
25316 facility is basically the result of the integration of the PDFSync package
25317 to the pdftex program and its merge with the
25322 You need at least \SpecialChar TeX
25323 Live 2008 or a recent Mik\SpecialChar TeX
25324 distribution in order to use
25329 \begin_layout Plain Layout
25330 For some reason, Mik\SpecialChar TeX
25331 does not understand/obey the command \SpecialChar LyX
25333 the preamble when you check the "Enable Forward/Reverse Search" button
25334 in the toolbar and does not generate the necessary info.
25337 \begin_layout Plain Layout
25338 The generation of the required info can be forced by changing the converter
25339 "\SpecialChar LaTeX
25340 (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
25341 from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
25342 the -synctex=1 switch).
25347 Also note that only a few PDF viewers (Okular and Qpdfview on Unix, Skim
25348 on the Mac, SumatraPDF on Windows) already provide Sync\SpecialChar TeX
25352 \begin_layout Standard
25353 To enable Sync\SpecialChar TeX
25354 for DVI output, change the
25355 \begin_inset Flex Noun
25358 \begin_layout Plain Layout
25369 \begin_inset Flex Noun
25372 \begin_layout Plain Layout
25377 (plain) -> DraftDVI
25383 \begin_inset Flex Noun
25386 \begin_layout Plain Layout
25387 Preferences\SpecialChar menuseparator
25388 File Handling\SpecialChar menuseparator
25395 \begin_inset Flex Code
25398 \begin_layout Plain Layout
25399 latex -synctex=1 $$i
25404 , and for PDF output, change the
25405 \begin_inset Flex Noun
25408 \begin_layout Plain Layout
25413 (pdflatex) -> PDF (pdflatex)
25419 \begin_inset Flex Code
25422 \begin_layout Plain Layout
25423 pdflatex -synctex=1 $$i
25429 Check the documentation of your viewer whether the viewer needs to be configure
25430 d for the use with Sync\SpecialChar TeX
25435 \begin_layout Plain Layout
25436 Note that the option
25437 \begin_inset Flex Code
25440 \begin_layout Plain Layout
25446 option enables gzip compression.
25447 If your viewer does not support it, you should instead use
25448 \begin_inset Flex Code
25451 \begin_layout Plain Layout
25465 \begin_layout Subsection
25466 Configuring and using specific viewers
25467 \begin_inset CommandInset label
25469 name "subsec:configuring-viewers"
25476 \begin_layout Subsubsection*
25477 Xdvi (all platforms)
25480 \begin_layout Standard
25482 \begin_inset Flex Code
25485 \begin_layout Plain Layout
25491 , you don't need to do anything else for performing a reverse DVI search,
25492 as \SpecialChar LyX
25493 already provides the necessary hooks for automatically using the
25494 \begin_inset Flex Code
25497 \begin_layout Plain Layout
25504 Just setup your document as described above (reverse search is triggered
25505 by Ctrl-click or Alt-click on Mac OSX, respectively).
25508 \begin_layout Standard
25509 However, if for whatever reason you want to use the named pipe instead of
25510 the socket for communicating with \SpecialChar LyX
25511 , simply change the DVI viewer in
25512 \begin_inset Flex Noun
25515 \begin_layout Plain Layout
25516 Preferences\SpecialChar menuseparator
25517 File Handling\SpecialChar menuseparator
25527 \begin_layout Plain Layout
25528 On Mac OSX you have to use
25529 \begin_inset Flex Code
25532 \begin_layout Plain Layout
25533 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
25544 \begin_inset Flex Code
25547 \begin_layout Plain Layout
25548 xdvi -editor "lyxeditor.sh %f %l"
25554 \begin_inset Flex Code
25557 \begin_layout Plain Layout
25563 is a suitable script.
25564 For example, a minimal shell script is the following one:
25567 \begin_layout LyX-Code
25569 \begin_inset Newline newline
25572 LYXPIPE="/path/to/lyxpipe"
25573 \begin_inset Newline newline
25576 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
25577 \begin_inset Newline newline
25580 echo "$COMMAND" > "${LYXPIPE}".in || exit
25581 \begin_inset Newline newline
25584 read TMP < "${LYXPIPE}".out || exit
25587 \begin_layout Standard
25589 \begin_inset Flex Code
25592 \begin_layout Plain Layout
25602 \begin_layout Plain Layout
25609 XServer pipe path specified in
25610 \begin_inset Flex Noun
25613 \begin_layout Plain Layout
25614 Preferences\SpecialChar menuseparator
25624 \begin_layout Plain Layout
25626 \begin_inset Flex Code
25629 \begin_layout Plain Layout
25635 folder of a source distribution you can find a
25636 \begin_inset Flex Code
25639 \begin_layout Plain Layout
25645 script which is able to locate the
25649 based on your preferences.
25657 \begin_layout Subsubsection*
25661 \begin_layout Standard
25663 \begin_inset Flex Code
25666 \begin_layout Plain Layout
25667 /Applications/MacDviX_Folder/calleditor.script
25672 , add the following lines:
25675 \begin_layout LyX-Code
25680 \begin_layout Plain Layout
25687 X.app/Contents/MacOS/lyxeditor "$2" $1
25688 \begin_inset Newline newline
25694 \begin_layout Standard
25695 Modify the lines accordingly if you install \SpecialChar LyX
25696 somewhere else than in the
25697 Applications folder.
25700 \begin_layout Standard
25701 Reverse search is triggered by Alt-click (OPTION-click).
25704 \begin_layout Subsubsection*
25708 \begin_layout Standard
25710 \begin_inset Flex Code
25713 \begin_layout Plain Layout
25714 open -a Skim.app $$i
25719 to the viewer setting in
25720 \begin_inset Flex Noun
25723 \begin_layout Plain Layout
25724 Preferences\SpecialChar menuseparator
25725 File Handling\SpecialChar menuseparator
25726 File formats\SpecialChar menuseparator
25733 \begin_inset Flex Noun
25736 \begin_layout Plain Layout
25737 Skim\SpecialChar menuseparator
25738 Preferences\SpecialChar menuseparator
25745 \begin_inset Flex Noun
25748 \begin_layout Plain Layout
25754 preset and enter command
25755 \begin_inset Flex Noun
25758 \begin_layout Plain Layout
25759 /Applications/\SpecialChar LyX
25760 .app/Contents/MacOS/lyxeditor
25768 \begin_layout Standard
25769 Reverse search is triggered by COMMAND-SHIFT-click
25772 \begin_layout Subsubsection*
25776 \begin_layout Standard
25778 \begin_inset Flex Noun
25781 \begin_layout Plain Layout
25782 Settings\SpecialChar menuseparator
25783 Configure Okular\SpecialChar menuseparator
25790 \begin_inset Quotes eld
25794 \begin_inset Quotes erd
25797 and add the command
25798 \begin_inset Flex Code
25801 \begin_layout Plain Layout
25810 \begin_layout Standard
25811 Reverse search is triggered by SHIFT-click.
25814 \begin_layout Subsubsection*
25818 \begin_layout Standard
25819 Qpdfview supports Sync\SpecialChar TeX
25820 since version 0.3.5.
25822 \begin_inset Flex Noun
25825 \begin_layout Plain Layout
25826 Edit\SpecialChar menuseparator
25827 Settings\SpecialChar menuseparator
25833 , click on the input field of the
25834 \begin_inset Quotes eld
25838 \begin_inset Quotes erd
25841 item and add the command
25842 \begin_inset Flex Code
25845 \begin_layout Plain Layout
25854 \begin_layout Standard
25855 Reverse search is triggered by double-click.
25858 \begin_layout Subsubsection*
25862 \begin_layout Standard
25863 Launch yap, choose its
25864 \begin_inset Flex Noun
25867 \begin_layout Plain Layout
25868 View\SpecialChar menuseparator
25874 menu and select the
25875 \begin_inset Quotes eld
25879 \begin_inset Quotes erd
25884 \begin_inset Quotes eld
25887 New\SpecialChar ldots
25889 \begin_inset Quotes erd
25892 button and, in the window that opens, enter
25893 \begin_inset Quotes eld
25898 \begin_inset Quotes erd
25901 (or any other name you like) in the
25902 \begin_inset Quotes eld
25906 \begin_inset Quotes erd
25910 Now click on the button labeled
25911 \begin_inset Quotes eld
25916 \begin_inset Quotes erd
25919 to open a file dialog and navigate to the directory containing the batch
25921 \begin_inset Flex Code
25924 \begin_layout Plain Layout
25932 \begin_inset Flex Code
25935 \begin_layout Plain Layout
25941 and then specify the program arguments as
25942 \begin_inset Flex Code
25945 \begin_layout Plain Layout
25953 \begin_inset Flex Code
25956 \begin_layout Plain Layout
25962 wrapper is used for communicating with \SpecialChar LyX
25970 \begin_layout LyX-Code
25972 \begin_inset Newline newline
25975 echo LYXCMD:revdvi:server-goto-file-row:%1 %2>
25984 \begin_inset Newline newline
25998 \begin_layout Standard
25999 Make sure that the \SpecialChar LyX
26000 Server pipe path you specified in \SpecialChar LyX
26002 \begin_inset Flex Code
26005 \begin_layout Plain Layout
26019 , otherwise change the
26020 \begin_inset Flex Code
26023 \begin_layout Plain Layout
26029 wrapper accordingly.
26032 \begin_layout Standard
26033 In yap, reverse search is triggered by double-click.
26036 \begin_layout Subsubsection*
26037 SumatraPDF (Windows)
26040 \begin_layout Standard
26041 In order to use SumatraPDF for inverse search, enter
26042 \begin_inset Flex Code
26045 \begin_layout Plain Layout
26046 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
26051 in the viewer setting in
26052 \begin_inset Flex Noun
26055 \begin_layout Plain Layout
26056 Preferences\SpecialChar menuseparator
26057 File Handling\SpecialChar menuseparator
26058 File formats\SpecialChar menuseparator
26065 \begin_inset Flex Code
26068 \begin_layout Plain Layout
26074 is the previous wrapper.
26075 If SumatraPDF.exe is not in your command PATH, use its full file name.
26078 \begin_layout Standard
26079 Reverse search is triggered by double-click.
26082 \begin_layout Subsubsection*
26086 \begin_layout Standard
26087 First of all, make sure that yap is your default DVI viewer in the Windows
26088 environment, then launch it, choose its
26089 \begin_inset Flex Noun
26092 \begin_layout Plain Layout
26093 View\SpecialChar menuseparator
26099 menu and select the
26100 \begin_inset Quotes eld
26104 \begin_inset Quotes erd
26109 \begin_inset Quotes eld
26112 New\SpecialChar ldots
26114 \begin_inset Quotes erd
26117 button and, in the window that opens, enter
26118 \begin_inset Quotes eld
26123 \begin_inset Quotes erd
26126 (or any other name you like) in the
26127 \begin_inset Quotes eld
26131 \begin_inset Quotes erd
26135 Now click on the button labeled
26136 \begin_inset Quotes eld
26141 \begin_inset Quotes erd
26144 to open a file dialog and navigate to the directory containing the
26145 \begin_inset Flex Code
26148 \begin_layout Plain Layout
26154 program (which is installed by default on Cygwin along with the \SpecialChar LyX
26157 \begin_inset Flex Code
26160 \begin_layout Plain Layout
26166 and then specify the program arguments as
26167 \begin_inset Flex Code
26170 \begin_layout Plain Layout
26177 In this way, you will be using the
26181 for communicating with \SpecialChar LyX
26183 If, for whatever reason, you want to use the
26188 \begin_inset Flex Code
26191 \begin_layout Plain Layout
26197 option and be sure to specify the \SpecialChar LyX
26198 Server pipe path in the \SpecialChar LyX
26202 \begin_layout Standard
26203 In yap, reverse search is triggered by double-click.
26206 \begin_layout Subsubsection*
26207 SumatraPDF (Cygwin)
26210 \begin_layout Standard
26211 In order to use SumatraPDF for inverse search, enter
26212 \begin_inset Flex Code
26215 \begin_layout Plain Layout
26216 SumatraPDF -inverse-search "lyxeditor -g %f %l"
26221 in the viewer setting in
26222 \begin_inset Flex Noun
26225 \begin_layout Plain Layout
26226 Preferences\SpecialChar menuseparator
26227 File Handling\SpecialChar menuseparator
26228 File formats\SpecialChar menuseparator
26235 If SumatraPDF.exe is not in your command PATH, use its full posix path.
26237 \begin_inset Flex Code
26240 \begin_layout Plain Layout
26246 enables communication via the
26252 \begin_inset Flex Code
26255 \begin_layout Plain Layout
26261 option if you want to use the
26265 , and be sure to specify the \SpecialChar LyX
26266 Server pipe path in the \SpecialChar LyX
26270 \begin_layout Standard
26271 Reverse search is triggered by double-click.
26274 \begin_layout Section
26278 \begin_layout Standard
26279 Forward search is, as the name implies, in a sense the
26280 \begin_inset Quotes eld
26284 \begin_inset Quotes erd
26288 It allows you to let the viewer jump to a given position from within \SpecialChar LyX
26290 If forward search is set up (as described in what follows), you can put
26291 the cursor anywhere in your \SpecialChar LyX
26293 \begin_inset Flex Noun
26296 \begin_layout Plain Layout
26297 Navigate\SpecialChar menuseparator
26304 \begin_inset Flex Noun
26307 \begin_layout Plain Layout
26313 in the context menu via right mouse click), and then the viewer will jump
26314 to that position as well.
26315 This implies, of course, that your viewer supports this function.
26318 \begin_layout Standard
26319 To make forward search possible, you first need to provide the generated
26320 output PDF/DVI file with additional information about the \SpecialChar TeX
26322 This can be done via the methods described in the section
26323 \begin_inset CommandInset ref
26325 reference "subsec:rev-search"
26332 \begin_layout Standard
26333 Additionally, you need to configure \SpecialChar LyX
26334 for using your viewers in
26335 \begin_inset Flex Noun
26338 \begin_layout Plain Layout
26339 Tools\SpecialChar menuseparator
26340 Preferences\SpecialChar menuseparator
26341 Output\SpecialChar menuseparator
26348 We provide a range of tested configurations for some viewers, which you
26349 can select from the drop down list.
26350 If none of these configurations suits you, you have to find out and enter
26351 a suitable configuration yourself.
26352 The definition syntax uses the following placeholders:
26355 \begin_layout Itemize
26357 \begin_inset Flex Code
26360 \begin_layout Plain Layout
26369 \begin_layout Itemize
26371 \begin_inset Flex Code
26374 \begin_layout Plain Layout
26380 : name of the (temporary) exported .tex file (without path)
26383 \begin_layout Itemize
26385 \begin_inset Flex Code
26388 \begin_layout Plain Layout
26394 : name of the (temporary) exported .tex file (including path)
26397 \begin_layout Itemize
26399 \begin_inset Flex Code
26402 \begin_layout Plain Layout
26408 : name of the exported output file (either dvi or pdf, depending on which
26409 one exists in the temporary directory)
26412 \begin_layout Standard
26413 Note that only some of the viewers provide full forward search functionality,
26414 among them yap, xdvi, okular
26418 \begin_layout Plain Layout
26419 You might want to set
26420 \begin_inset Flex Code
26423 \begin_layout Plain Layout
26430 \begin_inset Flex Noun
26433 \begin_layout Plain Layout
26434 Tools\SpecialChar menuseparator
26435 Preferences\SpecialChar menuseparator
26436 File Handling\SpecialChar menuseparator
26438 \begin_inset space ~
26451 , qpdfview and SumatraPDF
26455 \begin_layout Plain Layout
26456 SumatraPDF can also use DDE commands through the external program CMCDDE
26457 — downloadable from
26458 \begin_inset CommandInset href
26460 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
26470 While many of the widespread PDF viewers (most notably Adobe Reader) do
26471 not support forward search at all, some other viewers – e.
26472 \begin_inset space \thinspace{}
26476 evince and xpdf – allow at least to reload the document and jump to a specific
26477 page of the file, so you can at least navigate
26478 \begin_inset Quotes eld
26482 \begin_inset Quotes erd
26486 This latter functionality is provided by an external call of synctex (see
26487 the predefined example configurations).
26491 \begin_layout Standard
26492 Forward search works both with DVI and PDF output.
26494 simply checks which preview format you have used before (i.
26495 \begin_inset space \thinspace{}
26498 e., which format is already there in the temporary directory) and chooses
26499 the appropriate configuration for the respective format.