]> git.lyx.org Git - lyx.git/blob - lib/doc/Additional.lyx
Update docs. LFUN_SERVER_GOTO_FILE_ROW doesn't fail anymore when the
[lyx.git] / lib / doc / Additional.lyx
1 #LyX 2.0.0svn created this file. For more info see http://www.lyx.org/
2 \lyxformat 374
3 \begin_document
4 \begin_header
5 \textclass scrbook
6 \begin_preamble
7 % DO NOT ALTER THIS PREAMBLE!!!
8 %
9 % This preamble is designed to ensure that the manual prints
10 % out as advertised. If you mess with this preamble,
11 % parts of the manual may not print out as expected.  If you
12 % have problems LaTeXing this file, please contact 
13 % the documentation team
14 % email: lyx-docs@lists.lyx.org
15
16 % if pdflatex is used
17 \usepackage{ifpdf}
18 \ifpdf
19
20  % set fonts for nicer pdf view
21  \IfFileExists{lmodern.sty}
22   {\usepackage{lmodern}}{}
23
24 \fi % end if pdflatex is used
25
26 % the pages of the TOC are numbered roman
27 % and a PDF-bookmark for the TOC is added
28 \pagenumbering{roman}
29 \let\myTOC\tableofcontents
30 \renewcommand{\tableofcontents}{%
31  \pdfbookmark[1]{\contentsname}{}
32  \myTOC
33  \cleardoublepage
34  \pagenumbering{arabic}}
35
36 % redefine the \LyX macro for PDF bookmarks
37 \def\LyX{\texorpdfstring{%
38   L\kern-.1667em\lower.25em\hbox{Y}\kern-.125emX\@}
39   {LyX}}
40
41 % used for multi-column text
42 \usepackage{multicol}
43
44 % extra space for tables
45 \newcommand{\extratablespace}[1]{\noalign{\vskip#1}}
46 \end_preamble
47 \options fleqn,liststotoc,bibtotoc,idxtotoc,BCOR7.5mm,titlepage,tablecaptionabove
48 \use_default_options false
49 \begin_modules
50 logicalmkup
51 theorems-ams
52 theorems-ams-extended
53 \end_modules
54 \begin_local_layout
55 Format 7
56 InsetLayout CharStyle:MenuItem
57 LyxType               charstyle
58 LabelString           menu
59 LatexType             command
60 LatexName             menuitem
61 Font
62 Family              Sans
63 EndFont
64 Preamble
65 \newcommand*{\menuitem}[1]{{\sffamily #1}}
66 EndPreamble
67 End
68 \end_local_layout
69 \language english
70 \inputencoding latin1
71 \fontencoding global
72 \font_roman default
73 \font_sans default
74 \font_typewriter default
75 \font_default_family default
76 \use_xetex false
77 \font_sc false
78 \font_osf false
79 \font_sf_scale 100
80 \font_tt_scale 100
81
82 \graphics default
83 \default_output_format default
84 \bibtex_command default
85 \index_command default
86 \paperfontsize 12
87 \spacing single
88 \use_hyperref true
89 \pdf_title "LyX's Additional Features manual"
90 \pdf_author "LyX Team"
91 \pdf_subject "LyX's additional features documentation"
92 \pdf_keywords "LyX, Documentation, Additional"
93 \pdf_bookmarks true
94 \pdf_bookmarksnumbered true
95 \pdf_bookmarksopen false
96 \pdf_bookmarksopenlevel 1
97 \pdf_breaklinks false
98 \pdf_pdfborder false
99 \pdf_colorlinks true
100 \pdf_backref false
101 \pdf_pdfusetitle false
102 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue,  pdfpagelayout=OneColumn, pdfnewwindow=true,  pdfstartview=XYZ, plainpages=false, pdfpagelabels"
103 \papersize default
104 \use_geometry false
105 \use_amsmath 0
106 \use_esint 0
107 \use_mhchem 1
108 \cite_engine basic
109 \use_bibtopic false
110 \use_indices false
111 \paperorientation portrait
112 \suppress_date false
113 \index Index
114 \shortcut idx
115 \color #008000
116 \end_index
117 \secnumdepth 3
118 \tocdepth 3
119 \paragraph_separation indent
120 \paragraph_indentation default
121 \quotes_language english
122 \papercolumns 1
123 \papersides 2
124 \paperpagestyle headings
125 \tracking_changes false
126 \output_changes false
127 \html_use_mathml true
128 \html_be_strict true
129 \end_header
130
131 \begin_body
132
133 \begin_layout Title
134 Additional LyX Features
135 \end_layout
136
137 \begin_layout Author
138 by the LyX Team
139 \begin_inset Foot
140 status collapsed
141
142 \begin_layout Plain Layout
143 \noindent
144 Principal maintainer of this file is
145 \noun on
146  Richard Heck
147 \noun default
148 .
149  If you have comments or error corrections, please send them to the LyX
150  Documentation mailing list, 
151 \begin_inset Flex CharStyle:Code
152 status collapsed
153
154 \begin_layout Plain Layout
155 \noindent
156 <lyx-docs@lists.lyx.org>
157 \end_layout
158
159 \end_inset
160
161 .
162 \end_layout
163
164 \end_inset
165
166  
167 \end_layout
168
169 \begin_layout Standard
170 \begin_inset CommandInset toc
171 LatexCommand tableofcontents
172
173 \end_inset
174
175
176 \end_layout
177
178 \begin_layout Chapter
179 Introduction
180 \end_layout
181
182 \begin_layout Standard
183 This manual is essentially Part II of the 
184 \emph on
185 User's Guide\SpecialChar \@.
186
187 \emph default
188  The reason for separating this document out is simple: the 
189 \emph on
190 User's Guide
191 \emph default
192  is already quite lengthy, and it contains information on all of the basic
193  features one needs to know in order to prepare most documents.
194  However, the LyX Team has worked to LyX extensible through various configuratio
195 n files and external packages.
196  That means that if you want to support the Fizzwizzle LaTeX package, you
197  can create a layout file (or module) for it without having to alter LyX
198  itself.
199  We've already had contributions of several new features this way.
200  This is the place where all of those get documented.
201 \end_layout
202
203 \begin_layout Standard
204 This manual also documents some special features, like fax support, version
205  control, and SGML support, which require additional software to work properly.
206  Lastly, there's a chapter of LaTeX tools and tips, things you can use to
207  spruce up your documents by directly using the powerful features of LaTeX.
208  After all, LyX 
209 \emph on
210 is
211 \emph default
212  only WYSIWYM and will only ever interface to some, not all, LaTeX features.
213 \end_layout
214
215 \begin_layout Standard
216 If you haven't read the 
217 \emph on
218 Introduction
219 \emph default
220  yet, you are definitely in the wrong manual.
221  The 
222 \emph on
223 Introduction
224 \emph default
225  is the first place to go, since it describes the notation and format of
226  all of the manuals.
227  You should also be thoroughly familiar with the 
228 \emph on
229 User's Guide
230 \emph default
231  and all of the basic features of LyX before attempting to read this one.
232 \end_layout
233
234 \begin_layout Standard
235 Since all the topics in this manual depend heavily on LyX's interaction
236  with LaTeX, this first chapter covers the inner workings of LyX and how
237  to direct LyX to generate exactly the LaTeX code you want.
238  It is obviously for more seasoned LyX users.
239 \end_layout
240
241 \begin_layout Chapter
242 LyX and LaTeX
243 \end_layout
244
245 \begin_layout Section
246 How LyX Uses LaTeX
247 \end_layout
248
249 \begin_layout Standard
250 This chapter is for both TeX-nicians and the LaTeX-curious.
251  In it, we'll explain how LyX and LaTeX work together to produce printable
252  output.
253  This is the only place in any of the manuals where we assume you know something
254  about LaTeX.
255 \end_layout
256
257 \begin_layout Standard
258 At one time, LyX was called a 
259 \begin_inset Quotes eld
260 \end_inset
261
262 WYSIWYM frontend to LaTeX,
263 \begin_inset Quotes erd
264 \end_inset
265
266  but that's no longer true.
267  There are frontends to LaTeX out there.
268 \begin_inset Foot
269 status collapsed
270
271 \begin_layout Plain Layout
272 Some familar ones are TeXmaker and kile, on Linux, and TeXshop, OSX.
273  There are also the LaTeX modes for vi and emacs, of course.
274 \end_layout
275
276 \end_inset
277
278  These are basically text editors with the ability to run LaTeX and mark
279  any errors in the file you're editing.
280  Although LyX 
281 \emph on
282 is
283 \emph default
284  an editor, and it 
285 \emph on
286 does
287 \emph default
288  run LaTeX, and it also indicates errors in the file, it also does much,
289  much more.
290  For one thing, you don't need to know LaTeX to use LyX effectively.
291  And LyX has added its own extensions to LaTeX.
292  Try the following sometime: select 
293 \begin_inset Flex CharStyle:MenuItem
294 status collapsed
295
296 \begin_layout Plain Layout
297 Export\SpecialChar \menuseparator
298 LaTeX
299 \end_layout
300
301 \end_inset
302
303  from the 
304 \begin_inset Flex CharStyle:MenuItem
305 status collapsed
306
307 \begin_layout Plain Layout
308 File
309 \end_layout
310
311 \end_inset
312
313  menu (or 
314 \begin_inset Flex CharStyle:MenuItem
315 status collapsed
316
317 \begin_layout Plain Layout
318 View\SpecialChar \menuseparator
319 Source
320 \end_layout
321
322 \end_inset
323
324 ), then look at the preamble of the resulting 
325 \begin_inset Flex CharStyle:Code
326 status collapsed
327
328 \begin_layout Plain Layout
329 .tex
330 \end_layout
331
332 \end_inset
333
334  file.
335  You'll notice a variety of new macros defined specifically by LyX.
336  These macros are defined automatically, according to the features you use
337  in the document.
338 \end_layout
339
340 \begin_layout Standard
341 There are several commands that automatically invoke LaTeX.
342  They are:
343 \end_layout
344
345 \begin_layout Itemize
346 \begin_inset Flex CharStyle:MenuItem
347 status collapsed
348
349 \begin_layout Plain Layout
350 View\SpecialChar \menuseparator
351 Format
352 \end_layout
353
354 \end_inset
355
356
357 \end_layout
358
359 \begin_layout Itemize
360 \begin_inset Flex CharStyle:MenuItem
361 status collapsed
362
363 \begin_layout Plain Layout
364 View\SpecialChar \menuseparator
365 Update\SpecialChar \menuseparator
366 Format
367 \end_layout
368
369 \end_inset
370
371
372 \end_layout
373
374 \begin_layout Itemize
375 \begin_inset Flex CharStyle:MenuItem
376 status collapsed
377
378 \begin_layout Plain Layout
379 File\SpecialChar \menuseparator
380 Print
381 \end_layout
382
383 \end_inset
384
385
386 \end_layout
387
388 \begin_layout Itemize
389 \begin_inset Flex CharStyle:MenuItem
390 status collapsed
391
392 \begin_layout Plain Layout
393 File\SpecialChar \menuseparator
394 Fax
395 \end_layout
396
397 \end_inset
398
399
400 \end_layout
401
402 \begin_layout Standard
403 They will only invoke LaTeX if the file has changed since the last time
404  LaTeX was run.
405  
406 \end_layout
407
408 \begin_layout Standard
409 When LyX runs LaTeX on the file you're editing, it performs these steps:
410 \end_layout
411
412 \begin_layout Enumerate
413 Convert the document to LaTeX and save to a file with the extension 
414 \begin_inset Flex CharStyle:Code
415 status collapsed
416
417 \begin_layout Plain Layout
418 .tex
419 \end_layout
420
421 \end_inset
422
423  in place of 
424 \begin_inset Flex CharStyle:Code
425 status collapsed
426
427 \begin_layout Plain Layout
428 .lyx
429 \end_layout
430
431 \end_inset
432
433 .
434 \end_layout
435
436 \begin_layout Enumerate
437 Run LaTeX on the 
438 \begin_inset Flex CharStyle:Code
439 status collapsed
440
441 \begin_layout Plain Layout
442 .tex
443 \end_layout
444
445 \end_inset
446
447  file (maybe several times), and run any other commands (such as 
448 \begin_inset Flex CharStyle:Code
449 status collapsed
450
451 \begin_layout Plain Layout
452 bibtex
453 \end_layout
454
455 \end_inset
456
457  or 
458 \begin_inset Flex CharStyle:Code
459 status collapsed
460
461 \begin_layout Plain Layout
462 makeindex
463 \end_layout
464
465 \end_inset
466
467 ) needed to compile the LaTeX file.
468 \end_layout
469
470 \begin_layout Enumerate
471 If there are any errors, show the error log.
472 \end_layout
473
474 \begin_layout Standard
475 If you've run LaTeX using 
476 \begin_inset Flex CharStyle:MenuItem
477 status collapsed
478
479 \begin_layout Plain Layout
480 View
481 \bar under
482 \SpecialChar \menuseparator
483
484 \bar default
485 DVI
486 \end_layout
487
488 \end_inset
489
490 , LyX then runs a DVI viewer to display the DVI-file.
491  If you've used 
492 \begin_inset Flex CharStyle:MenuItem
493 status collapsed
494
495 \begin_layout Plain Layout
496 View
497 \bar under
498 \SpecialChar \menuseparator
499
500 \bar default
501 PostScript
502 \end_layout
503
504 \end_inset
505
506 , LyX performs further steps:
507 \end_layout
508
509 \begin_layout Itemize
510 Run 
511 \begin_inset Flex CharStyle:Code
512 status collapsed
513
514 \begin_layout Plain Layout
515 dvips
516 \end_layout
517
518 \end_inset
519
520  to convert the DVI file to PostScript.
521 \end_layout
522
523 \begin_layout Itemize
524 Run a PostScript viewer, such as 
525 \begin_inset Flex CharStyle:Code
526 status collapsed
527
528 \begin_layout Plain Layout
529 ghostview
530 \end_layout
531
532 \end_inset
533
534 , to display the PostScript file.
535 \end_layout
536
537 \begin_layout Standard
538 LyX does similar things when viewing, or exporting, other formats.
539 \end_layout
540
541 \begin_layout Section
542 Translating LaTeX files into LyX
543 \end_layout
544
545 \begin_layout Standard
546 You can import a LaTeX file into LyX by using the 
547 \begin_inset Flex CharStyle:MenuItem
548 status collapsed
549
550 \begin_layout Plain Layout
551 File\SpecialChar \menuseparator
552 Import\SpecialChar \menuseparator
553 LaTeX
554 \end_layout
555
556 \end_inset
557
558  command in LyX.
559  This will call a program named 
560 \begin_inset Flex CharStyle:Code
561 status collapsed
562
563 \begin_layout Plain Layout
564 tex2lyx
565 \end_layout
566
567 \end_inset
568
569  which will create a file 
570 \begin_inset Flex CharStyle:Code
571 status collapsed
572
573 \begin_layout Plain Layout
574 foo.lyx
575 \end_layout
576
577 \end_inset
578
579  from the file 
580 \begin_inset Flex CharStyle:Code
581 status collapsed
582
583 \begin_layout Plain Layout
584 foo.tex
585 \end_layout
586
587 \end_inset
588
589 .
590  LyX will then open that file.
591 \begin_inset Foot
592 status collapsed
593
594 \begin_layout Plain Layout
595 \begin_inset Flex CharStyle:Code
596 status collapsed
597
598 \begin_layout Plain Layout
599 tex2lyx
600 \end_layout
601
602 \end_inset
603
604  can also be run from the command line, of course.
605 \end_layout
606
607 \end_inset
608
609
610 \end_layout
611
612 \begin_layout Standard
613 \begin_inset Flex CharStyle:Code
614 status collapsed
615
616 \begin_layout Plain Layout
617 tex2lyx
618 \end_layout
619
620 \end_inset
621
622  will translate most legal LaTeX, but not everything.
623  It will put things it doesn't understand into TeX code, so after translating
624  a file with 
625 \begin_inset Flex CharStyle:Code
626 status collapsed
627
628 \begin_layout Plain Layout
629 tex2lyx
630 \end_layout
631
632 \end_inset
633
634 , you can look for TeX code and hand-edit it until it looks right.
635 \end_layout
636
637 \begin_layout Standard
638 If you don't know what TeX code is, read the next section.
639 \end_layout
640
641 \begin_layout Section
642 \begin_inset CommandInset label
643 LatexCommand label
644 name "sec:Inserting-TeX-Code"
645
646 \end_inset
647
648 Inserting TeX Code into LyX Documents 
649 \end_layout
650
651 \begin_layout Standard
652 Anything you can do in LaTeX you can do in LyX, for a very simple reason:
653  You can always insert TeX code into any LyX document.
654  LyX cannot, and will never be able to, display every possible LaTeX construct.
655  If ever you need to insert LaTeX commands into your LyX document, you can
656  use the 
657 \begin_inset Flex CharStyle:Code
658 status collapsed
659
660 \begin_layout Plain Layout
661 TeX Code
662 \end_layout
663
664 \end_inset
665
666  box, which you can insert into your document with 
667 \begin_inset Flex CharStyle:MenuItem
668 status collapsed
669
670 \begin_layout Plain Layout
671 Insert\SpecialChar \menuseparator
672 TeX Code
673 \end_layout
674
675 \end_inset
676
677 .
678 \end_layout
679
680 \begin_layout Standard
681 Here's an example of inserting LaTeX commands in a LyX document.
682  The code looks like this:
683 \end_layout
684
685 \begin_layout LyX-Code
686
687 \backslash
688 begin{tabular}{ll}
689 \begin_inset Newline newline
690 \end_inset
691
692
693 \backslash
694 begin{minipage}{5cm}
695 \begin_inset Newline newline
696 \end_inset
697
698 This is an example for a minipage environment.
699  You 
700 \begin_inset Newline newline
701 \end_inset
702
703 can put nearly everything in it, even (non-floating) 
704 \begin_inset Newline newline
705 \end_inset
706
707 figures and tables.
708  
709 \begin_inset Newline newline
710 \end_inset
711
712
713 \backslash
714 end{minipage}
715 \begin_inset Newline newline
716 \end_inset
717
718 &
719 \begin_inset Newline newline
720 \end_inset
721
722
723 \backslash
724 begin{minipage}{5cm}
725 \begin_inset Newline newline
726 \end_inset
727
728
729 \backslash
730 begin{verbatim}
731 \begin_inset Newline newline
732 \end_inset
733
734
735 \backslash
736 begin{minipage}{5cm}
737 \begin_inset Newline newline
738 \end_inset
739
740 This ...
741  
742 \begin_inset Newline newline
743 \end_inset
744
745
746 \backslash
747 end{minipage}
748 \begin_inset Newline newline
749 \end_inset
750
751
752 \backslash
753 end{verbatim}
754 \begin_inset Newline newline
755 \end_inset
756
757
758 \backslash
759 end{minipage}
760 \begin_inset Newline newline
761 \end_inset
762
763
764 \backslash
765 end{tabular}
766 \end_layout
767
768 \begin_layout LyX-Code
769
770 \end_layout
771
772 \begin_layout Standard
773 The 
774 \begin_inset Flex CharStyle:Code
775 status collapsed
776
777 \begin_layout Plain Layout
778 TeX Code
779 \end_layout
780
781 \end_inset
782
783  box containing this text is directly after this paragraph.
784  Those of you reading the manual in LyX will only see the TeX code inset.
785  Those reading a printed version of the manuals will see the actual results:
786 \end_layout
787
788 \begin_layout Standard
789 \begin_inset ERT
790 status collapsed
791
792 \begin_layout Plain Layout
793
794
795 \backslash
796 begin{tabular}{ll}
797 \end_layout
798
799 \begin_layout Plain Layout
800
801
802 \backslash
803 begin{minipage}{5cm}
804 \end_layout
805
806 \begin_layout Plain Layout
807
808 This is an example for a minipage environment.
809  You can put nearly everything in it, even (non-floating) figures and tables.
810  
811 \end_layout
812
813 \begin_layout Plain Layout
814
815
816 \backslash
817 end{minipage}
818 \end_layout
819
820 \begin_layout Plain Layout
821
822 &
823 \end_layout
824
825 \begin_layout Plain Layout
826
827
828 \backslash
829 begin{minipage}{5cm}
830 \end_layout
831
832 \begin_layout Plain Layout
833
834
835 \backslash
836 begin{verbatim}
837 \end_layout
838
839 \begin_layout Plain Layout
840
841
842 \backslash
843 begin{minipage}{5cm}
844 \end_layout
845
846 \begin_layout Plain Layout
847
848 This ...
849  
850 \end_layout
851
852 \begin_layout Plain Layout
853
854
855 \backslash
856 end{minipage}
857 \end_layout
858
859 \begin_layout Plain Layout
860
861
862 \backslash
863 end{verbatim}
864 \end_layout
865
866 \begin_layout Plain Layout
867
868
869 \backslash
870 end{minipage}
871 \end_layout
872
873 \begin_layout Plain Layout
874
875
876 \backslash
877 end{tabular}
878 \end_layout
879
880 \end_inset
881
882
883 \end_layout
884
885 \begin_layout Standard
886 In addition to using TeX code, you can also create a separate file containing
887  some complex LaTeX structure and then use 
888 \begin_inset Flex CharStyle:MenuItem
889 status collapsed
890
891 \begin_layout Plain Layout
892 Insert\SpecialChar \menuseparator
893 Child
894 \begin_inset space ~
895 \end_inset
896
897 Document
898 \end_layout
899
900 \end_inset
901
902  to include your file (you should select the type 
903 \begin_inset Flex CharStyle:Code
904 status collapsed
905
906 \begin_layout Plain Layout
907 Input
908 \end_layout
909
910 \end_inset
911
912 ).
913  We recommend that you only do this if you have a 
914 \begin_inset Flex CharStyle:Code
915 status collapsed
916
917 \begin_layout Plain Layout
918 .tex
919 \end_layout
920
921 \end_inset
922
923  file which you 
924 \emph on
925 know
926 \emph default
927  works already.
928  Otherwise, you'll have a big job tracking down LaTeX errors.
929 \end_layout
930
931 \begin_layout Standard
932 There are a few last points to emphasize:
933 \end_layout
934
935 \begin_layout Itemize
936 LyX 
937 \emph on
938 does not
939 \emph default
940  check if your LaTeX code is correct.
941 \end_layout
942
943 \begin_layout Itemize
944 Beware reinventing the wheel.
945 \end_layout
946
947 \begin_layout Standard
948 On that last point, LyX does have quite a few features tucked into it, and
949  more are coming.
950  Be sure to check the manuals to make sure that LyX doesn't have such-and-such
951  feature before you decide you have to do it by hand.
952  Moreover, there are numerous LaTeX packages out there to do all sorts of
953  things, from labels to envelopes to fancy multipage tables.
954  Check out 
955 \begin_inset CommandInset href
956 LatexCommand href
957 name "CTAN"
958 target "http://www.ctan.org/"
959
960 \end_inset
961
962  for details, and see chapter 
963 \begin_inset CommandInset ref
964 LatexCommand ref
965 reference "cha:secrets"
966
967 \end_inset
968
969 .
970 \end_layout
971
972 \begin_layout Standard
973 If you do need to do some wild and fancy things within your document, be
974  sure to check out a good LaTeX book for assistance.
975  There are a number of them listed in the bibliography of the 
976 \emph on
977 User's Guide
978 \emph default
979 .
980 \end_layout
981
982 \begin_layout Section
983 LyX and the LaTeX Preamble
984 \end_layout
985
986 \begin_layout Subsection
987 About the LaTeX Preamble
988 \end_layout
989
990 \begin_layout Standard
991 If you already know LaTeX, there is no need to explain here what the preamble
992  is good for.
993  If you don't, the following will give you some ideas—we recommend again
994  that you consult a LaTeX book for further information.
995  In any case, you should read the points below, because they explain what
996  you can do and what you don't need to do in the LaTeX preamble of a LyX
997  document.
998 \end_layout
999
1000 \begin_layout Standard
1001 The LaTeX preamble comes at the very beginning of a document, 
1002 \emph on
1003 before
1004 \emph default
1005  the text.
1006  It serves to:
1007 \end_layout
1008
1009 \begin_layout Itemize
1010 Declare the document class.
1011  
1012 \begin_inset Newline newline
1013 \end_inset
1014
1015 LyX already does this for you.
1016  If you're a seasoned LaTeX-nician, and you have a custom document class
1017  you want to use, check out the 
1018 \emph on
1019 Customization Manual
1020 \emph default
1021  for information on how to make LyX interface to it.
1022 \end_layout
1023
1024 \begin_layout Itemize
1025 Declare the usage of packages.
1026  
1027 \begin_inset Newline newline
1028 \end_inset
1029
1030 LaTeX packages provide special commands, which are only available within
1031  a document when the package has been declared in the preamble.
1032  For example, the package 
1033 \begin_inset Flex CharStyle:Code
1034 status collapsed
1035
1036 \begin_layout Plain Layout
1037 indentfirst
1038 \end_layout
1039
1040 \end_inset
1041
1042  forces all paragraphs to be indented.
1043  There are other packages for labels, envelopes, margins, etc.
1044  
1045 \end_layout
1046
1047 \begin_layout Itemize
1048 Set counters, variables, lengths and widths.
1049  
1050 \begin_inset Newline newline
1051 \end_inset
1052
1053 There are several LaTeX counters and variables which 
1054 \emph on
1055 must
1056 \emph default
1057  be set globally from within the preamble in order to have the desired effect.
1058  (There are variables which you can set and reset inside the document, too.)
1059  Margins are a good example of something which must be set in the preamble.
1060  Another example is the label format for lists.
1061  You can actually set these just about anywhere, but it's best to do it
1062  just once, inside the preamble.
1063 \end_layout
1064
1065 \begin_layout Itemize
1066 Declare user defined commands (with 
1067 \begin_inset Flex CharStyle:Code
1068 status collapsed
1069
1070 \begin_layout Plain Layout
1071
1072 \backslash
1073 newcommand
1074 \end_layout
1075
1076 \end_inset
1077
1078  or 
1079 \begin_inset Flex CharStyle:Code
1080 status collapsed
1081
1082 \begin_layout Plain Layout
1083
1084 \backslash
1085 renewcommand
1086 \end_layout
1087
1088 \end_inset
1089
1090 ).
1091 \begin_inset Newline newline
1092 \end_inset
1093
1094 These are abbreviations for LaTeX commands which appear very often inside
1095  a document.
1096  Although the preamble is a good place to declare such commands, they 
1097 \emph on
1098 can
1099 \emph default
1100  be declared anywhere (before they are used for the first time, of course).
1101  This can be useful if there is a lot of raw LaTeX code in your document,
1102  which normally should not be the case.
1103 \end_layout
1104
1105 \begin_layout Standard
1106 LyX adds its own set of definitions to the preamble of the 
1107 \begin_inset Flex CharStyle:Code
1108 status collapsed
1109
1110 \begin_layout Plain Layout
1111 .tex
1112 \end_layout
1113
1114 \end_inset
1115
1116  file it produces.
1117  This makes LaTeX files generated by LyX portable.
1118 \end_layout
1119
1120 \begin_layout Subsection
1121 Changing the Preamble
1122 \end_layout
1123
1124 \begin_layout Standard
1125 The commands which LyX adds to the preamble of a LaTeX file are fixed; you
1126  can't change them without patching LyX itself.
1127  You can, however, add your own stuff to the preamble by selecting 
1128 \begin_inset Flex CharStyle:MenuItem
1129 status collapsed
1130
1131 \begin_layout Plain Layout
1132 LaTeX
1133 \begin_inset space ~
1134 \end_inset
1135
1136 Preamble
1137 \end_layout
1138
1139 \end_inset
1140
1141  in the 
1142 \begin_inset Flex CharStyle:MenuItem
1143 status collapsed
1144
1145 \begin_layout Plain Layout
1146 Document\SpecialChar \menuseparator
1147 Settings
1148 \end_layout
1149
1150 \end_inset
1151
1152  dialog.
1153  LyX adds anything in the 
1154 \begin_inset Flex CharStyle:MenuItem
1155 status collapsed
1156
1157 \begin_layout Plain Layout
1158 Preamble
1159 \end_layout
1160
1161 \end_inset
1162
1163  dialog to its own built-in preamble.
1164  Before adding your own declarations in the preamble, you should make sure
1165  that LyX doesn't already support what you want to do.
1166  (Remember what we said about reinventing the wheel?) Also, 
1167 \emph on
1168 make sure your preamble code is correct
1169 \emph default
1170 .
1171  LyX doesn't check it for you.
1172  If there is an error, you're likely to get an error like 
1173 \begin_inset Quotes eld
1174 \end_inset
1175
1176
1177 \begin_inset Flex CharStyle:Code
1178 status collapsed
1179
1180 \begin_layout Plain Layout
1181 Missing 
1182 \backslash
1183 begin{document}
1184 \end_layout
1185
1186 \end_inset
1187
1188
1189 \begin_inset Quotes erd
1190 \end_inset
1191
1192 .
1193  If you see this error, check your preamble.
1194 \end_layout
1195
1196 \begin_layout Subsection
1197 Examples
1198 \end_layout
1199
1200 \begin_layout Standard
1201 Here are some examples of what you can add to a preamble, and what they
1202  do.
1203 \end_layout
1204
1205 \begin_layout Subsubsection
1206 Example #1: Offsets
1207 \end_layout
1208
1209 \begin_layout Standard
1210 There are two variables under LaTeX that control page position: 
1211 \begin_inset Flex CharStyle:Code
1212 status collapsed
1213
1214 \begin_layout Plain Layout
1215
1216 \backslash
1217 hoffset
1218 \end_layout
1219
1220 \end_inset
1221
1222  and 
1223 \begin_inset Flex CharStyle:Code
1224 status collapsed
1225
1226 \begin_layout Plain Layout
1227
1228 \backslash
1229 voffset
1230 \end_layout
1231
1232 \end_inset
1233
1234 .
1235  Their names should be self-explanatory.
1236  These variables are useful if you think for a moment about computer labels.
1237  Sometimes, the size of a print medium and the area of the medium that you
1238  can actually print on aren't the same.
1239  This is where 
1240 \begin_inset Flex CharStyle:Code
1241 status collapsed
1242
1243 \begin_layout Plain Layout
1244
1245 \backslash
1246 hoffset
1247 \end_layout
1248
1249 \end_inset
1250
1251  and 
1252 \begin_inset Flex CharStyle:Code
1253 status collapsed
1254
1255 \begin_layout Plain Layout
1256
1257 \backslash
1258 voffset
1259 \end_layout
1260
1261 \end_inset
1262
1263  come in.
1264 \end_layout
1265
1266 \begin_layout Standard
1267 The default values for 
1268 \begin_inset Flex CharStyle:Code
1269 status collapsed
1270
1271 \begin_layout Plain Layout
1272
1273 \backslash
1274 hoffset
1275 \end_layout
1276
1277 \end_inset
1278
1279  and 
1280 \begin_inset Flex CharStyle:Code
1281 status collapsed
1282
1283 \begin_layout Plain Layout
1284
1285 \backslash
1286 voffset
1287 \end_layout
1288
1289 \end_inset
1290
1291  are both 0
1292 \begin_inset space \thinspace{}
1293 \end_inset
1294
1295 points, i.
1296 \begin_inset space \thinspace{}
1297 \end_inset
1298
1299 g.
1300 \begin_inset space \space{}
1301 \end_inset
1302
1303 the page isn't shifted.
1304  Unfortunately, some DVI drivers always seem to shift the page.
1305  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1306  If you're using LyX on a system that you don't personally maintain, and
1307  your sysadmin is a doofus, 
1308 \begin_inset Flex CharStyle:Code
1309 status collapsed
1310
1311 \begin_layout Plain Layout
1312
1313 \backslash
1314 hoffset
1315 \end_layout
1316
1317 \end_inset
1318
1319  and 
1320 \begin_inset Flex CharStyle:Code
1321 status collapsed
1322
1323 \begin_layout Plain Layout
1324
1325 \backslash
1326 voffset
1327 \end_layout
1328
1329 \end_inset
1330
1331  can save the day.
1332  Suppose you're left and top margins are always 0.5
1333 \begin_inset space \thinspace{}
1334 \end_inset
1335
1336 inches too big.
1337  You can add this to the preamble:
1338 \end_layout
1339
1340 \begin_layout LyX-Code
1341
1342 \backslash
1343 setlength{
1344 \backslash
1345 hoffset}{-0.5 in}
1346 \end_layout
1347
1348 \begin_layout LyX-Code
1349
1350 \backslash
1351 setlength{
1352 \backslash
1353 voffset}{-0.5 in}
1354 \end_layout
1355
1356 \begin_layout Standard
1357 and your margins should now be correct.
1358 \end_layout
1359
1360 \begin_layout Subsubsection
1361 Example #2: Labels
1362 \end_layout
1363
1364 \begin_layout Standard
1365 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1366  There's a rather nice package, available at your nearest CTAN archive,
1367  for printing sheets of labels: 
1368 \begin_inset Flex CharStyle:Code
1369 status collapsed
1370
1371 \begin_layout Plain Layout
1372 labels.sty
1373 \end_layout
1374
1375 \end_inset
1376
1377 .
1378  Now, your system may not have this package installed by default.
1379  We leave that up to you to check.
1380  You'll also want to read the documentation for it; we're not going to do
1381  that for you.
1382  Since this is an example, however, we'll give you an example of how you
1383  use this package.
1384 \end_layout
1385
1386 \begin_layout Standard
1387 First, make sure you're using the 
1388 \begin_inset Flex CharStyle:Code
1389 status collapsed
1390
1391 \begin_layout Plain Layout
1392 article
1393 \end_layout
1394
1395 \end_inset
1396
1397  document class.
1398  Next, you need to put the following in your preamble:
1399 \end_layout
1400
1401 \begin_layout LyX-Code
1402
1403 \backslash
1404 usepackage{labels}
1405 \end_layout
1406
1407 \begin_layout LyX-Code
1408
1409 \backslash
1410 LabelCols=3
1411 \end_layout
1412
1413 \begin_layout LyX-Code
1414
1415 \backslash
1416 LabelRows=7
1417 \end_layout
1418
1419 \begin_layout LyX-Code
1420
1421 \backslash
1422 LeftBorder=8mm
1423 \end_layout
1424
1425 \begin_layout LyX-Code
1426
1427 \backslash
1428 RightBorder=8mm
1429 \end_layout
1430
1431 \begin_layout LyX-Code
1432
1433 \backslash
1434 TopBorder=9mm
1435 \end_layout
1436
1437 \begin_layout LyX-Code
1438
1439 \backslash
1440 BottomBorder=2mm
1441 \end_layout
1442
1443 \begin_layout Standard
1444 This sets things up for Avery label sheets, stock #5360.
1445  You're now ready to print labels, but you'll need to insert LaTeX code,
1446  placing the commands 
1447 \begin_inset Flex CharStyle:Code
1448 status collapsed
1449
1450 \begin_layout Plain Layout
1451
1452 \backslash
1453 begin{labels}
1454 \end_layout
1455
1456 \end_inset
1457
1458  and 
1459 \begin_inset Flex CharStyle:Code
1460 status collapsed
1461
1462 \begin_layout Plain Layout
1463
1464 \backslash
1465 end{labels}
1466 \end_layout
1467
1468 \end_inset
1469
1470  around each label text.
1471  This and other special features of 
1472 \begin_inset Flex CharStyle:Code
1473 status collapsed
1474
1475 \begin_layout Plain Layout
1476 labels.sty
1477 \end_layout
1478
1479 \end_inset
1480
1481  are explained in its documentation.
1482 \end_layout
1483
1484 \begin_layout Standard
1485 Someday, someone may write a LyX layout file to support this package directly.
1486  Maybe that someone is you.
1487 \end_layout
1488
1489 \begin_layout Subsubsection
1490 Example #3: Paragraph Indentation
1491 \end_layout
1492
1493 \begin_layout Standard
1494 Americans are trained to indent the first line of 
1495 \emph on
1496 every
1497 \emph default
1498  paragraph.
1499  As with all of their other weird quirks, most Americans will whine and
1500  moan until they can have their way and indent the first line of all paragraphs.
1501  (Yes, we're joking.
1502  (We are?) 
1503 \emph on
1504 Yeah
1505 \emph default
1506 , we are.)
1507 \end_layout
1508
1509 \begin_layout Standard
1510 Of course, this behavior isn't standard typography.
1511  In books, you typically only indent the first line of a paragraph 
1512 \emph on
1513 if
1514 \emph default
1515  it follows another one.
1516  The idea behind indenting the first line of a paragraph is to distinguish
1517  neighboring paragraphs from one another.
1518  If there is no previous paragraph—for example, if it follows a figure or
1519  is the first paragraph in a section—then there is no need for indentation.
1520  
1521 \end_layout
1522
1523 \begin_layout Standard
1524 If you're a typical American (we're still joking!), though, you don't care
1525  about such esoteric things; you want your indentation! Add this to the
1526  preamble:
1527 \end_layout
1528
1529 \begin_layout LyX-Code
1530
1531 \backslash
1532 usepackage{indentfirst}
1533 \end_layout
1534
1535 \begin_layout Standard
1536 If your TeX distribution isn't braindead, you'll have this package, and
1537  all of your paragraphs will get the indentation the Founding Fathers intended
1538  they should have.
1539 \end_layout
1540
1541 \begin_layout Subsubsection
1542 Example #4: This Document
1543 \end_layout
1544
1545 \begin_layout Standard
1546 You can also check out the preamble of this document to get an idea of some
1547  of the advanced things you can do.
1548  Also, there are more examples and an assortment of LaTeX 
1549 \begin_inset Quotes eld
1550 \end_inset
1551
1552 dirty tricks
1553 \begin_inset Quotes erd
1554 \end_inset
1555
1556  given in Chapter
1557 \begin_inset space ~
1558 \end_inset
1559
1560
1561 \begin_inset CommandInset ref
1562 LatexCommand ref
1563 reference "cha:secrets"
1564
1565 \end_inset
1566
1567 .
1568  
1569 \end_layout
1570
1571 \begin_layout Section
1572 LyX and LaTeX Errors
1573 \end_layout
1574
1575 \begin_layout Standard
1576 When LyX calls LaTeX, it tells LaTeX to blithely ignore any errors and keep
1577  going.
1578  It then uses the logfile from the LaTeX run to do a post-mortem.
1579  After analyzing the logfile,LyX displays a dialog listing the errors.
1580  Clicking on any one of them will take you to the position in your LyX file
1581  where the error occurred.
1582 \begin_inset Foot
1583 status collapsed
1584
1585 \begin_layout Plain Layout
1586 Well, usually.
1587  Analyzing the logfile is a tough job, and LyX doesn't always go to the
1588  right line.
1589  There are also cases where LaTeX reports the error on one line, but the
1590  actual error is earlier.
1591  This is not unlike forgetting a closing brace in a program: You'll get
1592  an error, but only later.
1593 \end_layout
1594
1595 \end_inset
1596
1597
1598 \end_layout
1599
1600 \begin_layout Standard
1601 Some folks also like to look at the log file directly: It is available from
1602  
1603 \begin_inset Flex CharStyle:MenuItem
1604 status collapsed
1605
1606 \begin_layout Plain Layout
1607 Document
1608 \bar under
1609 \SpecialChar \menuseparator
1610
1611 \bar default
1612 Latex
1613 \begin_inset space ~
1614 \end_inset
1615
1616 Log
1617 \end_layout
1618
1619 \end_inset
1620
1621 .
1622  There are some fairly common error messages and warnings.
1623  We'll cover those here.
1624  You should look at a good LaTeX book for a complete listing.
1625 \end_layout
1626
1627 \begin_layout Itemize
1628 \begin_inset Flex CharStyle:Code
1629 status collapsed
1630
1631 \begin_layout Plain Layout
1632 LaTeX Warning
1633 \end_layout
1634
1635 \end_inset
1636
1637
1638 \begin_inset Newline newline
1639 \end_inset
1640
1641 Anything beginning with these words is a warning message for the purpose
1642  of 
1643 \begin_inset Quotes eld
1644 \end_inset
1645
1646 debugging
1647 \begin_inset Quotes erd
1648 \end_inset
1649
1650  the LaTeX code itself.
1651  You'll get messages like this if you added or changed cross-references
1652  or bibliography entries, in which case, LaTeX is trying to tell you that
1653  you need to make another run.
1654  You can by-and-large ignore these.
1655 \end_layout
1656
1657 \begin_layout Itemize
1658 \begin_inset Flex CharStyle:Code
1659 status collapsed
1660
1661 \begin_layout Plain Layout
1662 LaTeX Font Warning
1663 \end_layout
1664
1665 \end_inset
1666
1667
1668 \begin_inset Newline newline
1669 \end_inset
1670
1671 Another warning message, this time about fonts which LaTeX couldn't find.
1672  The rest of the message will often say something about a replacement font
1673  that LaTeX used.
1674  You can safely ignore these, too.
1675 \end_layout
1676
1677 \begin_layout Itemize
1678 \begin_inset Flex CharStyle:Code
1679 status collapsed
1680
1681 \begin_layout Plain Layout
1682 Overfull 
1683 \backslash
1684 hbox
1685 \end_layout
1686
1687 \end_inset
1688
1689
1690 \begin_inset Newline newline
1691 \end_inset
1692
1693 LaTeX absolutely 
1694 \emph on
1695 loves
1696 \emph default
1697  to spew these out.
1698  They are warnings about lines that were too long and run past the right
1699  margin.
1700  Almost always, this is unnoticeable in the final output.
1701  (It can be just a point or two.) Or, only one or two characters extend past
1702  the margin.
1703  LaTeX seems to generate at least one of these messages for just about any
1704  document you write.
1705 \begin_inset Newline newline
1706 \end_inset
1707
1708 You can ignore these messages.
1709  Your eyes will tell you if there's a problem with something that's too
1710  wide; just look at the output.
1711 \begin_inset Foot
1712 status collapsed
1713
1714 \begin_layout Plain Layout
1715 You can also enable the `draft' option in 
1716 \begin_inset Flex CharStyle:MenuItem
1717 status collapsed
1718
1719 \begin_layout Plain Layout
1720 Document
1721 \bar under
1722 \SpecialChar \menuseparator
1723
1724 \bar default
1725 Settings
1726 \end_layout
1727
1728 \end_inset
1729
1730 , and then LaTeX will draw a black box in the margin of lines that are overfull.
1731 \end_layout
1732
1733 \end_inset
1734
1735
1736 \end_layout
1737
1738 \begin_layout Itemize
1739 \begin_inset Flex CharStyle:Code
1740 status collapsed
1741
1742 \begin_layout Plain Layout
1743 Underfull 
1744 \backslash
1745 hbox
1746 \end_layout
1747
1748 \end_inset
1749
1750
1751 \begin_inset Newline newline
1752 \end_inset
1753
1754 Not quite as common as its cousin.
1755  LaTeX seems to like to print lines that are a bit too wide as opposed to
1756  ones that are a bit too narrow.
1757  We have no idea why.
1758 \end_layout
1759
1760 \begin_layout Itemize
1761 \begin_inset Flex CharStyle:Code
1762 status collapsed
1763
1764 \begin_layout Plain Layout
1765 Overfull 
1766 \backslash
1767 vbox
1768 \end_layout
1769
1770 \end_inset
1771
1772  and 
1773 \begin_inset Flex CharStyle:Code
1774 status collapsed
1775
1776 \begin_layout Plain Layout
1777 Underfull 
1778 \backslash
1779 vbox
1780 \end_layout
1781
1782 \end_inset
1783
1784
1785 \begin_inset Newline newline
1786 \end_inset
1787
1788 Warnings about troubles breaking the page.
1789  Once again, just look at the output.
1790  Your eyes will tell you where something has gone wrong.
1791 \end_layout
1792
1793 \begin_layout Itemize
1794 \begin_inset Flex CharStyle:Code
1795 status collapsed
1796
1797 \begin_layout Plain Layout
1798  LaTeX Error: File 
1799 \begin_inset Quotes els
1800 \end_inset
1801
1802 Xxxx
1803 \begin_inset Quotes ers
1804 \end_inset
1805
1806  not found
1807 \end_layout
1808
1809 \end_inset
1810
1811
1812 \begin_inset Newline newline
1813 \end_inset
1814
1815 The file 
1816 \begin_inset Quotes eld
1817 \end_inset
1818
1819 Xxxx
1820 \begin_inset Quotes erd
1821 \end_inset
1822
1823  isn't installed on this system.
1824  This usually appears because some package your document needs isn't installed.
1825  If you didn't touch the preamble or didn't use the 
1826 \begin_inset Flex CharStyle:Code
1827 status collapsed
1828
1829 \begin_layout Plain Layout
1830
1831 \backslash
1832 usepackage{}
1833 \end_layout
1834
1835 \end_inset
1836
1837  command, then one of the packages LyX tried to load is missing.
1838  Use 
1839 \begin_inset Flex CharStyle:MenuItem
1840 status collapsed
1841
1842 \begin_layout Plain Layout
1843 Help\SpecialChar \menuseparator
1844 LaTeX Configuration
1845 \end_layout
1846
1847 \end_inset
1848
1849  to get a list of packages that LyX knows about.
1850  This file is updated whenever you reconfigure LyX (using 
1851 \begin_inset Flex CharStyle:MenuItem
1852 status collapsed
1853
1854 \begin_layout Plain Layout
1855 Tools\SpecialChar \menuseparator
1856 Reconfigure
1857 \end_layout
1858
1859 \end_inset
1860
1861 ) and tells you which packages have been detected and what they do.
1862 \begin_inset Newline newline
1863 \end_inset
1864
1865 If you did use the 
1866 \begin_inset Flex CharStyle:Code
1867 status collapsed
1868
1869 \begin_layout Plain Layout
1870
1871 \backslash
1872 usepackage{}
1873 \end_layout
1874
1875 \end_inset
1876
1877  command and the package in question isn't installed, then you'll need to
1878  install it yourself.
1879 \end_layout
1880
1881 \begin_layout Itemize
1882 \begin_inset Flex CharStyle:Code
1883 status collapsed
1884
1885 \begin_layout Plain Layout
1886 LaTeX Error: Unknown option
1887 \end_layout
1888
1889 \end_inset
1890
1891
1892 \begin_inset Newline newline
1893 \end_inset
1894
1895 Error messages beginning with this are trying to tell you that you specified
1896  a bad or undefined option to a package.
1897  Check the package's documentation.
1898 \end_layout
1899
1900 \begin_layout Itemize
1901 \begin_inset Flex CharStyle:Code
1902 status collapsed
1903
1904 \begin_layout Plain Layout
1905 Undefined control sequence
1906 \end_layout
1907
1908 \end_inset
1909
1910
1911 \begin_inset Newline newline
1912 \end_inset
1913
1914 If you've inserted LaTeX code into your document, but made a typo, you'll
1915  get one of these.
1916  You may have forgotten to load a package.
1917  In any case, this error message usually means that you used an undefined
1918  command.
1919  
1920 \end_layout
1921
1922 \begin_layout Standard
1923 There are other error and warning messages.
1924  Some are self-explanatory.
1925  These are usually LaTeX messages.
1926  Others are downright cryptic.
1927  These are usually TeX error messages, and we really have 
1928 \emph on
1929 no clue
1930 \emph default
1931  what they mean or how to decipher them.
1932  No-one does.
1933 \end_layout
1934
1935 \begin_layout Standard
1936 There's a general sequence you should follow if you get error messages:
1937 \end_layout
1938
1939 \begin_layout Enumerate
1940 Look at the LaTeX code you inserted for typos.
1941 \end_layout
1942
1943 \begin_layout Enumerate
1944 If there are no typos, check that you used the command(s) correctly.
1945 \end_layout
1946
1947 \begin_layout Enumerate
1948 If you get a bunch of error boxes piled up at the very top of the document—and
1949  especially if you see a 
1950 \begin_inset Quotes eld
1951 \end_inset
1952
1953
1954 \begin_inset Flex CharStyle:Code
1955 status collapsed
1956
1957 \begin_layout Plain Layout
1958 Missing 
1959 \backslash
1960 begin{document}
1961 \end_layout
1962
1963 \end_inset
1964
1965
1966 \begin_inset Quotes erd
1967 \end_inset
1968
1969  error—it means that there are errors in the preamble.
1970  Start debugging your preamble.
1971 \end_layout
1972
1973 \begin_layout Enumerate
1974 If you didn't add anything to the preamble and didn't add any LaTeX code
1975  to the document, the first suspect is your LaTeX distribution itself.
1976  Check for missing packages and install them.
1977 \end_layout
1978
1979 \begin_layout Enumerate
1980 Okay, so there are no missing packages.
1981  Did you use any of the fine-tuning options in LyX? Specifically, did you
1982  
1983 \emph on
1984 misuse
1985 \emph default
1986  any of them, like trying to manually insert lots of 
1987 \begin_inset Flex CharStyle:Code
1988 status collapsed
1989
1990 \begin_layout Plain Layout
1991 Protected
1992 \begin_inset space ~
1993 \end_inset
1994
1995 Blanks
1996 \end_layout
1997
1998 \end_inset
1999
2000
2001 \begin_inset Flex CharStyle:Code
2002 status collapsed
2003
2004 \begin_layout Plain Layout
2005 Linebreaks
2006 \end_layout
2007
2008 \end_inset
2009
2010 , or 
2011 \begin_inset Flex CharStyle:Code
2012 status collapsed
2013
2014 \begin_layout Plain Layout
2015 Pagebreaks
2016 \end_layout
2017
2018 \end_inset
2019
2020 ? Did you try to kludge something together with these instead of using the
2021  appropriate paragraph environment?
2022 \end_layout
2023
2024 \begin_layout Enumerate
2025 All right, you didn't use any of the fine-tuning options, you played by
2026  the rules.
2027  Did you try to pull a fancy maneuver? Did you do something funky inside
2028  a table or an equation, like inserting a graphic into a table cell?
2029 \end_layout
2030
2031 \begin_layout Enumerate
2032 Do you have long sections of text where LaTeX cannot find a place to break
2033  a line? By default, LaTeX is rather strict about how much extra inter-word
2034  spacing it will add in order to break a line.
2035  Preferably, you should rework the paragraph to avoid the problem.
2036  If this isn't an option, you can wrap your text in 
2037 \begin_inset Flex CharStyle:Code
2038 status collapsed
2039
2040 \begin_layout Plain Layout
2041
2042 \backslash
2043 sloppypar
2044 \end_layout
2045
2046 \end_inset
2047
2048  to make LaTeX's line breaking more, well, sloppy.
2049 \end_layout
2050
2051 \begin_layout Enumerate
2052 Did you go overboard with the nesting? LyX (currently) doesn't check to
2053  make sure you're in the limits for nesting environments.
2054  If you nested a bunch of environments to the 
2055 \begin_inset Formula $17^{\mathrm{th}}$
2056 \end_inset
2057
2058  level, that's the problem.
2059  (The limit in LaTeX is five.)
2060 \end_layout
2061
2062 \begin_layout Enumerate
2063 Okay, you didn't get any error messages, but your output looks awful.
2064  If you have a table or figure that's too wide or long for the page, you
2065  need to:
2066 \end_layout
2067
2068 \begin_deeper
2069 \begin_layout Enumerate
2070 rescale the figure so it fits.
2071 \end_layout
2072
2073 \begin_layout Enumerate
2074 trim down the table so it fits.
2075 \end_layout
2076
2077 \end_deeper
2078 \begin_layout Enumerate
2079 If something else is wrong with the output, and you didn't try to pull anything
2080  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2081 \end_layout
2082
2083 \begin_layout Standard
2084 If all this doesn't help—well, then 
2085 \emph on
2086 perhaps
2087 \emph default
2088  you might have found a bug in LyX\SpecialChar \ldots{}
2089 .
2090 \end_layout
2091
2092 \begin_layout Chapter
2093 Supplemental Tools
2094 \end_layout
2095
2096 \begin_layout Section
2097 Customizing Bibliographies with BibTeX
2098 \end_layout
2099
2100 \begin_layout Standard
2101 The basics how to use BibTeX are explained in section 
2102 \emph on
2103 Bibliography databases (BibTeX)
2104 \emph default
2105  of the 
2106 \emph on
2107 User's Guide
2108 \emph default
2109 .
2110  The following subsections explain special bibliography features supported
2111  by LyX.
2112 \end_layout
2113
2114 \begin_layout Subsection
2115 Alternative Citation Styles
2116 \end_layout
2117
2118 \begin_layout Standard
2119 Standard BibTeX uses numbers (e.
2120 \begin_inset space \thinspace{}
2121 \end_inset
2122
2123 g.
2124 \begin_inset space \space{}
2125 \end_inset
2126
2127
2128 \begin_inset Quotes eld
2129 \end_inset
2130
2131 [12]
2132 \begin_inset Quotes erd
2133 \end_inset
2134
2135 ) to refer to a cited work.
2136  However, in many scientific disciplines, other citation styles are in use.
2137  The most common one is the author-year style (e.
2138 \begin_inset space \thinspace{}
2139 \end_inset
2140
2141 g.
2142 \begin_inset space \space{}
2143 \end_inset
2144
2145
2146 \begin_inset Quotes eld
2147 \end_inset
2148
2149 Knuth 1984a
2150 \begin_inset Quotes erd
2151 \end_inset
2152
2153 ).
2154  LyX supports two packages that provide this style, 
2155 \begin_inset Flex CharStyle:Code
2156 status collapsed
2157
2158 \begin_layout Plain Layout
2159 natbib
2160 \end_layout
2161
2162 \end_inset
2163
2164  and 
2165 \begin_inset Flex CharStyle:Code
2166 status collapsed
2167
2168 \begin_layout Plain Layout
2169 jurabib
2170 \end_layout
2171
2172 \end_inset
2173
2174 .
2175  Both packages have their pros and cons, which cannot be listed in detail.
2176  If you only want to have simple author-year (or author-numerical) style,
2177  or if you want to use one of the countless style files for 
2178 \begin_inset Flex CharStyle:Code
2179 status collapsed
2180
2181 \begin_layout Plain Layout
2182 natbib
2183 \end_layout
2184
2185 \end_inset
2186
2187 , than the established 
2188 \begin_inset Flex CharStyle:Code
2189 status collapsed
2190
2191 \begin_layout Plain Layout
2192 natbib
2193 \end_layout
2194
2195 \end_inset
2196
2197  package is probably your choice.
2198  If you need special features like short title references, ibidem etc., you
2199  might consider the 
2200 \begin_inset Flex CharStyle:Code
2201 status collapsed
2202
2203 \begin_layout Plain Layout
2204 jurabib
2205 \end_layout
2206
2207 \end_inset
2208
2209  package.
2210 \end_layout
2211
2212 \begin_layout Standard
2213 The handling of both packages in LyX is basically the same.
2214  Go to 
2215 \begin_inset Flex CharStyle:MenuItem
2216 status collapsed
2217
2218 \begin_layout Plain Layout
2219 Document\SpecialChar \menuseparator
2220 Settings
2221 \end_layout
2222
2223 \end_inset
2224
2225  and select under 
2226 \begin_inset Flex CharStyle:MenuItem
2227 status collapsed
2228
2229 \begin_layout Plain Layout
2230 Bibliography
2231 \end_layout
2232
2233 \end_inset
2234
2235  the option 
2236 \begin_inset Flex CharStyle:MenuItem
2237 status collapsed
2238
2239 \begin_layout Plain Layout
2240 Natbib
2241 \end_layout
2242
2243 \end_inset
2244
2245  or 
2246 \begin_inset Flex CharStyle:MenuItem
2247 status collapsed
2248
2249 \begin_layout Plain Layout
2250 Jurabib
2251 \end_layout
2252
2253 \end_inset
2254
2255 .
2256  With both packages, you will get some extra features in the citation dialog
2257  and you can select the style of the reference (
2258 \begin_inset Quotes eld
2259 \end_inset
2260
2261 Knuth 1984
2262 \begin_inset Quotes erd
2263 \end_inset
2264
2265
2266 \begin_inset Quotes eld
2267 \end_inset
2268
2269 Knuth (1984)
2270 \begin_inset Quotes erd
2271 \end_inset
2272
2273
2274 \begin_inset Quotes eld
2275 \end_inset
2276
2277 Knuth, 1984
2278 \begin_inset Quotes erd
2279 \end_inset
2280
2281
2282 \begin_inset Quotes eld
2283 \end_inset
2284
2285 1984
2286 \begin_inset Quotes erd
2287 \end_inset
2288
2289  etc.).
2290  Note that both packages need specifically designed style files.
2291  They both ship their own, but there are lots of additional style files,
2292  and there is even an interactive style file builder
2293 \begin_inset Foot
2294 status collapsed
2295
2296 \begin_layout Plain Layout
2297 See 
2298 \begin_inset Flex URL
2299 status open
2300
2301 \begin_layout Plain Layout
2302
2303 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2304 \end_layout
2305
2306 \end_inset
2307
2308
2309 \end_layout
2310
2311 \end_inset
2312
2313  for 
2314 \begin_inset Flex CharStyle:Code
2315 status collapsed
2316
2317 \begin_layout Plain Layout
2318 natbib
2319 \end_layout
2320
2321 \end_inset
2322
2323 .
2324 \end_layout
2325
2326 \begin_layout Subsection
2327 Sectioned Bibliographies
2328 \end_layout
2329
2330 \begin_layout Standard
2331 Sometimes you might need to divide your bibliography into several sections.
2332  If you are for instance a historian, the possibility to separate sources
2333  and scientific works is most likely a 
2334 \begin_inset Quotes eld
2335 \end_inset
2336
2337 must have
2338 \begin_inset Quotes erd
2339 \end_inset
2340
2341 .
2342  Unfortunately, BibTeX itself does not allow you to do this.
2343  But with the help of some LaTeX packages, BibTeX can be extended to fit
2344  your needs.
2345 \end_layout
2346
2347 \begin_layout Standard
2348 LyX provides native support for one of these packages, 
2349 \family typewriter
2350 bibtopic
2351 \family default
2352 .
2353 \begin_inset Foot
2354 status collapsed
2355
2356 \begin_layout Plain Layout
2357 Available from 
2358 \begin_inset Flex URL
2359 status open
2360
2361 \begin_layout Plain Layout
2362
2363 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2364 \end_layout
2365
2366 \end_inset
2367
2368
2369 \end_layout
2370
2371 \end_inset
2372
2373  The advantage of this package (compared to other packages like 
2374 \family typewriter
2375 multibib
2376 \family default
2377 ) is that you don't need to define new citation commands.
2378  Instead, you need to prepare different bibliographic databases which include
2379  the entries for the different sections of the bibliography.
2380  For example: If you want to divide your bibliography into the sections
2381  
2382 \begin_inset Quotes eld
2383 \end_inset
2384
2385 Sources
2386 \begin_inset Quotes erd
2387 \end_inset
2388
2389  and 
2390 \begin_inset Quotes eld
2391 \end_inset
2392
2393 Scientific works
2394 \begin_inset Quotes erd
2395 \end_inset
2396
2397 , you first need to create two bibliographic databases, e.
2398 \begin_inset space \thinspace{}
2399 \end_inset
2400
2401 g.
2402 \begin_inset space \space{}
2403 \end_inset
2404
2405
2406 \begin_inset Flex CharStyle:Code
2407 status collapsed
2408
2409 \begin_layout Plain Layout
2410 sources.bib
2411 \end_layout
2412
2413 \end_inset
2414
2415  and 
2416 \begin_inset Flex CharStyle:Code
2417 status collapsed
2418
2419 \begin_layout Plain Layout
2420 scientific.bib
2421 \end_layout
2422
2423 \end_inset
2424
2425 .
2426  
2427 \end_layout
2428
2429 \begin_layout Standard
2430 Go to 
2431 \begin_inset Flex CharStyle:MenuItem
2432 status collapsed
2433
2434 \begin_layout Plain Layout
2435 Document\SpecialChar \menuseparator
2436 Settings
2437 \end_layout
2438
2439 \end_inset
2440
2441  and check under 
2442 \begin_inset Flex CharStyle:MenuItem
2443 status collapsed
2444
2445 \begin_layout Plain Layout
2446 Bibliography
2447 \end_layout
2448
2449 \end_inset
2450
2451  the option 
2452 \begin_inset Flex CharStyle:MenuItem
2453 status collapsed
2454
2455 \begin_layout Plain Layout
2456 Sectioned bibliography
2457 \end_layout
2458
2459 \end_inset
2460
2461 .
2462  Now you can insert multiple BibTeX bibliographies, one for each section
2463  of your bibliography.
2464  Returning to our example: Insert the BibTeX bibliography 
2465 \begin_inset Flex CharStyle:Code
2466 status collapsed
2467
2468 \begin_layout Plain Layout
2469 sources.bib
2470 \end_layout
2471
2472 \end_inset
2473
2474  and a second one for the database 
2475 \begin_inset Flex CharStyle:Code
2476 status collapsed
2477
2478 \begin_layout Plain Layout
2479 scientific.bib
2480 \end_layout
2481
2482 \end_inset
2483
2484 .
2485  You are free to use the same or different styles for each section.
2486  Additionally, you can chose if the bibliography section should contain
2487  
2488 \begin_inset Quotes eld
2489 \end_inset
2490
2491 all cited references
2492 \begin_inset Quotes erd
2493 \end_inset
2494
2495  of the specified database(s) (which is the default), 
2496 \begin_inset Quotes eld
2497 \end_inset
2498
2499 all uncited references
2500 \begin_inset Quotes erd
2501 \end_inset
2502
2503  or even 
2504 \begin_inset Quotes eld
2505 \end_inset
2506
2507 all references
2508 \begin_inset Quotes erd
2509 \end_inset
2510
2511 .
2512  This might be useful if you would like to separate your bibliography into
2513  three sections: 
2514 \begin_inset Quotes eld
2515 \end_inset
2516
2517 Cited sources
2518 \begin_inset Quotes erd
2519 \end_inset
2520
2521
2522 \begin_inset Quotes eld
2523 \end_inset
2524
2525 Uncited sources
2526 \begin_inset Quotes erd
2527 \end_inset
2528
2529 , and 
2530 \begin_inset Quotes eld
2531 \end_inset
2532
2533 Scientific works
2534 \begin_inset Quotes erd
2535 \end_inset
2536
2537 .
2538  The titles for the sections can be added as ordinary sections or subsections.
2539  Since 
2540 \begin_inset Flex CharStyle:Code
2541 status collapsed
2542
2543 \begin_layout Plain Layout
2544 bibtopic
2545 \end_layout
2546
2547 \end_inset
2548
2549  removes the bibliography title, you have manually re-add that, too (as
2550  a chapter* or section*, for instance).
2551 \end_layout
2552
2553 \begin_layout Subsection
2554 Multiple Bibliographies
2555 \end_layout
2556
2557 \begin_layout Standard
2558 Multiple bibliographies, e.
2559 \begin_inset space \thinspace{}
2560 \end_inset
2561
2562 g.
2563 \begin_inset space \space{}
2564 \end_inset
2565
2566 a bibliography for each section or chapter of the document, are not supported
2567  by BibTeX itself.
2568  But the 
2569 \begin_inset Flex CharStyle:Code
2570 status collapsed
2571
2572 \begin_layout Plain Layout
2573 bibtopic
2574 \end_layout
2575
2576 \end_inset
2577
2578  package, which is used for the creation of sectioned bibliographies in
2579  LyX (see the previous section), provides an easy way to solve this task,
2580  if you are willing to use some 
2581 \begin_inset Flex CharStyle:MenuItem
2582 status collapsed
2583
2584 \begin_layout Plain Layout
2585 TeX Code
2586 \end_layout
2587
2588 \end_inset
2589
2590  (see section
2591 \begin_inset space ~
2592 \end_inset
2593
2594
2595 \begin_inset CommandInset ref
2596 LatexCommand ref
2597 reference "sec:Inserting-TeX-Code"
2598
2599 \end_inset
2600
2601 ).
2602 \begin_inset Foot
2603 status collapsed
2604
2605 \begin_layout Plain Layout
2606 An alternative approach is to use the 
2607 \begin_inset Flex CharStyle:Code
2608 status collapsed
2609
2610 \begin_layout Plain Layout
2611 chapterbib
2612 \end_layout
2613
2614 \end_inset
2615
2616  or 
2617 \begin_inset Flex CharStyle:Code
2618 status collapsed
2619
2620 \begin_layout Plain Layout
2621 bibunits
2622 \end_layout
2623
2624 \end_inset
2625
2626  package, respectively.
2627 \end_layout
2628
2629 \end_inset
2630
2631
2632 \end_layout
2633
2634 \begin_layout Standard
2635 First go to 
2636 \begin_inset Flex CharStyle:MenuItem
2637 status collapsed
2638
2639 \begin_layout Plain Layout
2640 Document\SpecialChar \menuseparator
2641 Settings
2642 \end_layout
2643
2644 \end_inset
2645
2646  and under 
2647 \begin_inset Flex CharStyle:MenuItem
2648 status collapsed
2649
2650 \begin_layout Plain Layout
2651 Bibliography
2652 \end_layout
2653
2654 \end_inset
2655
2656  check 
2657 \begin_inset Flex CharStyle:MenuItem
2658 status collapsed
2659
2660 \begin_layout Plain Layout
2661 Sectioned bibliography
2662 \end_layout
2663
2664 \end_inset
2665
2666 .
2667  In the document, you have to enclose the sections, which shall contain
2668  their own bibliography (including the BibTeX bibliography itself), between
2669  
2670 \begin_inset Flex CharStyle:Code
2671 status collapsed
2672
2673 \begin_layout Plain Layout
2674
2675 \backslash
2676 begin{btUnit}
2677 \end_layout
2678
2679 \end_inset
2680
2681  and 
2682 \begin_inset Flex CharStyle:Code
2683 status collapsed
2684
2685 \begin_layout Plain Layout
2686
2687 \backslash
2688 end{btUnit}
2689 \end_layout
2690
2691 \end_inset
2692
2693  (those commands have to be inserted as TeX code).
2694  The bibliography will contain all references which have been cited in the
2695  current 
2696 \begin_inset Flex CharStyle:Code
2697 status collapsed
2698
2699 \begin_layout Plain Layout
2700 btUnit
2701 \end_layout
2702
2703 \end_inset
2704
2705 .
2706  
2707 \series bold
2708 Note:
2709 \series default
2710  If you are using this approach, then every citation reference has to be
2711  inside some 
2712 \begin_inset Flex CharStyle:Code
2713 status collapsed
2714
2715 \begin_layout Plain Layout
2716 btUnit
2717 \end_layout
2718
2719 \end_inset
2720
2721 .
2722  Also, the 
2723 \begin_inset Flex CharStyle:Code
2724 status collapsed
2725
2726 \begin_layout Plain Layout
2727 btUnit
2728 \end_layout
2729
2730 \end_inset
2731
2732 s cannot be nested.
2733 \end_layout
2734
2735 \begin_layout Section
2736 Multipart Documents
2737 \end_layout
2738
2739 \begin_layout Subsection
2740 General Operation
2741 \end_layout
2742
2743 \begin_layout Standard
2744 When you are working on a large file with many sections, it is often convenient
2745  to break up the document into several files, or perhaps you have something
2746  where a table may change from time to time, but the preceding text does
2747  not.
2748  In these cases, you should seriously consider using multipart documents.
2749  For example, scientific papers often have five major sections: the introduction
2750 , observations, results, discussion, and conclusion.
2751  Each of these could be its own separate LyX file, with one 
2752 \begin_inset Quotes eld
2753 \end_inset
2754
2755 master
2756 \begin_inset Quotes erd
2757 \end_inset
2758
2759  file which contains the title, authors, abstract, references, etc., plus
2760  the five included files.
2761  It is important to note that each of these files is a full LyX file which
2762  can be formatted and printed on its own, as well as included in a master
2763  file.
2764  Each of these files must have the same document class, however—don't attempt
2765  to mix book classes with article classes.
2766  You may also include LaTeX files; however, these files must not have their
2767  own preamble (i.
2768 \begin_inset space \thinspace{}
2769 \end_inset
2770
2771 g.
2772 \begin_inset space \space{}
2773 \end_inset
2774
2775 everything up to and including the 
2776 \begin_inset Flex CharStyle:Code
2777 status collapsed
2778
2779 \begin_layout Plain Layout
2780
2781 \backslash
2782 begin{document}
2783 \end_layout
2784
2785 \end_inset
2786
2787  line as well as the 
2788 \begin_inset Flex CharStyle:Code
2789 status collapsed
2790
2791 \begin_layout Plain Layout
2792
2793 \backslash
2794 end{document}
2795 \end_layout
2796
2797 \end_inset
2798
2799  line must be deleted) or else errors will be generated when you try to
2800  make a DVI file.
2801 \end_layout
2802
2803 \begin_layout Standard
2804 LyX allows you to include files quite easily with 
2805 \begin_inset Flex CharStyle:MenuItem
2806 status collapsed
2807
2808 \begin_layout Plain Layout
2809 Insert\SpecialChar \menuseparator
2810 ChiId
2811 \begin_inset space ~
2812 \end_inset
2813
2814 Document
2815 \end_layout
2816
2817 \end_inset
2818
2819 .
2820  When you click on this selection a small box is inserted into the file
2821  at the current cursor location.
2822  Clicking on the box raises a dialog which allows you to select the file
2823  to be included, and the method of its inclusion.
2824  
2825 \end_layout
2826
2827 \begin_layout Standard
2828 The file selection box should by now be obvious.
2829  The three inclusion methods are 
2830 \begin_inset Quotes eld
2831 \end_inset
2832
2833 include
2834 \begin_inset Quotes erd
2835 \end_inset
2836
2837
2838 \begin_inset Quotes eld
2839 \end_inset
2840
2841 input
2842 \begin_inset Quotes erd
2843 \end_inset
2844
2845 , and 
2846 \begin_inset Quotes eld
2847 \end_inset
2848
2849 verbatim
2850 \begin_inset Quotes erd
2851 \end_inset
2852
2853 .
2854  The difference between 
2855 \begin_inset Quotes eld
2856 \end_inset
2857
2858 include
2859 \begin_inset Quotes erd
2860 \end_inset
2861
2862  and 
2863 \begin_inset Quotes eld
2864 \end_inset
2865
2866 input
2867 \begin_inset Quotes erd
2868 \end_inset
2869
2870  is really only meaningful to LaTeXperts, but the practical difference is
2871  that files which are 
2872 \begin_inset Quotes eld
2873 \end_inset
2874
2875 included
2876 \begin_inset Quotes erd
2877 \end_inset
2878
2879  are typeset beginning on a new page, while files which are 
2880 \begin_inset Quotes eld
2881 \end_inset
2882
2883 inputted
2884 \begin_inset Quotes erd
2885 \end_inset
2886
2887  are typeset starting on the current page.
2888 \end_layout
2889
2890 \begin_layout Standard
2891 Generally, the master file is converted into a full LaTeX file before typesettin
2892 g, while the included files are converted to LaTeX files which do not have
2893  all the preamble information.
2894 \end_layout
2895
2896 \begin_layout Standard
2897
2898 \begin_inset Quotes eld
2899 \end_inset
2900
2901 verbatim
2902 \begin_inset Quotes erd
2903 \end_inset
2904
2905  included file allows you to include a file typeset exactly as it appears
2906  in the file, i.
2907 \begin_inset space \thinspace{}
2908 \end_inset
2909
2910 g.
2911 \begin_inset space \space{}
2912 \end_inset
2913
2914 in 
2915 \begin_inset Flex CharStyle:Code
2916 status collapsed
2917
2918 \begin_layout Plain Layout
2919 verbatim
2920 \end_layout
2921
2922 \end_inset
2923
2924  mode, with the characters set in a fixed-width typewriter font.
2925  Normally, spaces in this file are invisible, though two consecutive spaces
2926  are conserved, unlike LyX's normal treatment of spaces.
2927  However, setting the 
2928 \begin_inset Flex CharStyle:MenuItem
2929 status collapsed
2930
2931 \begin_layout Plain Layout
2932 Mark
2933 \begin_inset space ~
2934 \end_inset
2935
2936 spaces
2937 \begin_inset space ~
2938 \end_inset
2939
2940 in
2941 \begin_inset space ~
2942 \end_inset
2943
2944 output
2945 \end_layout
2946
2947 \end_inset
2948
2949  checkbox typesets a mark to unambiguously define the presence of a space.
2950  
2951 \end_layout
2952
2953 \begin_layout Subsection
2954 Cross-References Between Files
2955 \end_layout
2956
2957 \begin_layout Standard
2958 \begin_inset Box Shadowbox
2959 position "t"
2960 hor_pos "c"
2961 has_inner_box 1
2962 inner_pos "t"
2963 use_parbox 0
2964 width "100col%"
2965 special "none"
2966 height "1in"
2967 height_special "totalheight"
2968 status open
2969
2970 \begin_layout Plain Layout
2971 This section is somewhat out of date.
2972  Need to describe default master documents and how children are opened when
2973  the master is.
2974  [[FIXME]]
2975 \end_layout
2976
2977 \end_inset
2978
2979
2980 \end_layout
2981
2982 \begin_layout Standard
2983 It is possible to set up cross-references between the different files.
2984  First, open all the files in question: let's call them A and B in a two
2985  file example, where B is included in A.
2986  Let's say you insert a label in A, then want to reference it in B.
2987  Open the cross-reference dialog in whilst in document B, and you can select
2988  the 
2989 \begin_inset Quotes eld
2990 \end_inset
2991
2992 buffer
2993 \begin_inset Quotes erd
2994 \end_inset
2995
2996  to use.
2997 \end_layout
2998
2999 \begin_layout Subsection
3000 Bibliography Lists in all Subdocuments
3001 \end_layout
3002
3003 \begin_layout Standard
3004 \begin_inset Box Frameless
3005 position "t"
3006 hor_pos "c"
3007 has_inner_box 1
3008 inner_pos "t"
3009 use_parbox 0
3010 width "100col%"
3011 special "none"
3012 height "1in"
3013 height_special "totalheight"
3014 status open
3015
3016 \begin_layout Plain Layout
3017 This section also needs updating.
3018  There is now material about this on the wiki, and it could be copied here.
3019 \end_layout
3020
3021 \end_inset
3022
3023
3024 \end_layout
3025
3026 \begin_layout Standard
3027 Copy the bibliography list with all entries to all subdocuments and transform
3028  them to a comment.
3029  This way LyX will find the 
3030 \begin_inset Flex CharStyle:Code
3031 status collapsed
3032
3033 \begin_layout Plain Layout
3034 .bib
3035 \end_layout
3036
3037 \end_inset
3038
3039 -files and you can easily insert references without making the bibliography
3040  list visible.
3041 \end_layout
3042
3043 \begin_layout Standard
3044 As the bibliography list is in a comment, LaTeX won't use use it and the
3045  references will look like this: [?], instead of like this: [1].
3046  One solution is to use the LaTeX-package 
3047 \begin_inset Flex CharStyle:Code
3048 status collapsed
3049
3050 \begin_layout Plain Layout
3051 comment
3052 \end_layout
3053
3054 \end_inset
3055
3056  that will only include comments by processing the files separately.
3057  To do this, add in the LaTeX preamble of every subdocument the following:
3058 \end_layout
3059
3060 \begin_layout LyX-Code
3061
3062 \backslash
3063 usepackage{comment}
3064 \end_layout
3065
3066 \begin_layout LyX-Code
3067
3068 \backslash
3069 includecomment{comment}
3070 \end_layout
3071
3072 \begin_layout Standard
3073 See also 
3074 \begin_inset Flex URL
3075 status collapsed
3076
3077 \begin_layout Plain Layout
3078
3079 http://wiki.lyx.org/FAQ/Unsorted#toc31
3080 \end_layout
3081
3082 \end_inset
3083
3084 .
3085 \end_layout
3086
3087 \begin_layout Section
3088 Fancy Headers and Footers
3089 \end_layout
3090
3091 \begin_layout Standard
3092 The default page layout is rather plain; for an 
3093 \begin_inset Flex CharStyle:Code
3094 status collapsed
3095
3096 \begin_layout Plain Layout
3097 article
3098 \end_layout
3099
3100 \end_inset
3101
3102  document class, all you get is a centered page number at the bottom of
3103  the page.
3104  This document uses KOMA-script's book class, so it appears to be a bit
3105  fancier.
3106  But to really put on a show, you need to set the document page style to
3107  
3108 \begin_inset Quotes eld
3109 \end_inset
3110
3111 fancy
3112 \begin_inset Quotes erd
3113 \end_inset
3114
3115 , as mentioned in the 
3116 \emph on
3117 User Guide
3118 \emph default
3119 .
3120  This section describes the LaTeX code you need to insert in your LaTeX
3121  preamble in order to get the desired effects.
3122 \end_layout
3123
3124 \begin_layout Standard
3125 For more information on fancy headers, see the 
3126 \begin_inset Flex CharStyle:Code
3127 status collapsed
3128
3129 \begin_layout Plain Layout
3130 fancyhdr
3131 \end_layout
3132
3133 \end_inset
3134
3135  package documentation.
3136  This can be found in the file 
3137 \begin_inset Flex CharStyle:Code
3138 status collapsed
3139
3140 \begin_layout Plain Layout
3141 fancyhdr.dvi
3142 \end_layout
3143
3144 \end_inset
3145
3146 , which should have been installed with your LaTeX distribution, or 
3147 \begin_inset CommandInset href
3148 LatexCommand href
3149 name "online"
3150 target "http://www.ctan.org/tex-archive/macros/latex/contrib/fancyhdr/"
3151
3152 \end_inset
3153
3154 .
3155 \end_layout
3156
3157 \begin_layout Standard
3158 The page header is divided into three fields, not surprisingly labeled 
3159 \begin_inset Quotes eld
3160 \end_inset
3161
3162 left
3163 \begin_inset Quotes erd
3164 \end_inset
3165
3166
3167 \begin_inset Quotes eld
3168 \end_inset
3169
3170 center
3171 \begin_inset Quotes erd
3172 \end_inset
3173
3174 , and 
3175 \begin_inset Quotes eld
3176 \end_inset
3177
3178 right
3179 \begin_inset Quotes erd
3180 \end_inset
3181
3182 .
3183  The footer is also divided into these three fields.
3184  The LaTeX commands to set these fields in the simplest manner are 
3185 \begin_inset Flex CharStyle:Code
3186 status collapsed
3187
3188 \begin_layout Plain Layout
3189
3190 \backslash
3191 lhead
3192 \end_layout
3193
3194 \end_inset
3195
3196
3197 \begin_inset Flex CharStyle:Code
3198 status collapsed
3199
3200 \begin_layout Plain Layout
3201
3202 \backslash
3203 chead
3204 \end_layout
3205
3206 \end_inset
3207
3208
3209 \begin_inset Flex CharStyle:Code
3210 status collapsed
3211
3212 \begin_layout Plain Layout
3213
3214 \backslash
3215 rhead
3216 \end_layout
3217
3218 \end_inset
3219
3220
3221 \begin_inset Flex CharStyle:Code
3222 status collapsed
3223
3224 \begin_layout Plain Layout
3225
3226 \backslash
3227 lfoot
3228 \end_layout
3229
3230 \end_inset
3231
3232 , etc.
3233  Suppose you wish to put your name in the upper left hand corner of each
3234  page.
3235  Simply insert the following command in the preamble: 
3236 \end_layout
3237
3238 \begin_layout Standard
3239
3240 \family typewriter
3241
3242 \backslash
3243 lhead{John Q.
3244  DocWriter}
3245 \end_layout
3246
3247 \begin_layout Standard
3248 You will now see your name in the upper left.
3249  If a field has a default entry that you would like to get rid of (often
3250  the page number appears in the central footer, simply include a command
3251  with a blank argument, e.
3252 \begin_inset space \thinspace{}
3253 \end_inset
3254
3255 g.:
3256 \end_layout
3257
3258 \begin_layout Standard
3259
3260 \family typewriter
3261
3262 \backslash
3263 cfoot{}
3264 \end_layout
3265
3266 \begin_layout Standard
3267 Let's get really fancy: lets put the section number with the word 
3268 \begin_inset Quotes eld
3269 \end_inset
3270
3271 Section
3272 \begin_inset Quotes erd
3273 \end_inset
3274
3275  (e.
3276 \begin_inset space \thinspace{}
3277 \end_inset
3278
3279 g.
3280 \begin_inset space \space{}
3281 \end_inset
3282
3283 Section 3) in the upper left, the page number (e.
3284 \begin_inset space \thinspace{}
3285 \end_inset
3286
3287 g.
3288 \begin_inset space \space{}
3289 \end_inset
3290
3291 Page 4) in the upper right, your name in the lower left, and the date in
3292  the lower right.
3293  The following commands should now appear in the preamble:
3294 \end_layout
3295
3296 \begin_layout Standard
3297
3298 \family typewriter
3299
3300 \backslash
3301 lhead{Section 
3302 \backslash
3303 thesection}
3304 \end_layout
3305
3306 \begin_layout Standard
3307
3308 \family typewriter
3309
3310 \backslash
3311 chead{}
3312 \end_layout
3313
3314 \begin_layout Standard
3315
3316 \family typewriter
3317
3318 \backslash
3319 rhead{Page 
3320 \backslash
3321 thepage}
3322 \end_layout
3323
3324 \begin_layout Standard
3325
3326 \family typewriter
3327
3328 \backslash
3329 lfoot{John Q.
3330  DocWriter}
3331 \end_layout
3332
3333 \begin_layout Standard
3334
3335 \family typewriter
3336
3337 \backslash
3338 cfoot{}
3339 \end_layout
3340
3341 \begin_layout Standard
3342
3343 \family typewriter
3344
3345 \backslash
3346 rfoot{
3347 \backslash
3348 today}
3349 \end_layout
3350
3351 \begin_layout Standard
3352 The commands 
3353 \begin_inset Flex CharStyle:Code
3354 status collapsed
3355
3356 \begin_layout Plain Layout
3357
3358 \backslash
3359 thesection
3360 \end_layout
3361
3362 \end_inset
3363
3364  and 
3365 \begin_inset Flex CharStyle:Code
3366 status collapsed
3367
3368 \begin_layout Plain Layout
3369
3370 \backslash
3371 thepage
3372 \end_layout
3373
3374 \end_inset
3375
3376  access LaTeX's section and page counters, and so print out the current
3377  section and page numbers.
3378  
3379 \begin_inset Flex CharStyle:Code
3380 status collapsed
3381
3382 \begin_layout Plain Layout
3383
3384 \backslash
3385 today
3386 \end_layout
3387
3388 \end_inset
3389
3390  simply prints out today's date.
3391 \end_layout
3392
3393 \begin_layout Standard
3394 The thicknesses of the horizontal rules drawn beneath the header and above
3395  the footer can also be modified.
3396  If you don't want one of the rules, set its thickness to 0.
3397  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
3398  Use commands
3399 \family typewriter
3400  
3401 \family default
3402 like 
3403 \begin_inset Flex CharStyle:Code
3404 status collapsed
3405
3406 \begin_layout Plain Layout
3407
3408 \backslash
3409 renewcommand{
3410 \backslash
3411 headrulewidth}{0.4pt}
3412 \end_layout
3413
3414 \end_inset
3415
3416  and 
3417 \begin_inset Flex CharStyle:Code
3418 status collapsed
3419
3420 \begin_layout Plain Layout
3421
3422 \backslash
3423 renewcommand{
3424 \backslash
3425 footrulewidth}{0.4pt}
3426 \end_layout
3427
3428 \end_inset
3429
3430  to set the thicknesses.
3431 \end_layout
3432
3433 \begin_layout Standard
3434 You can switch the header/footer settings on and off for individual pages
3435  using commands like 
3436 \begin_inset Flex CharStyle:Code
3437 status collapsed
3438
3439 \begin_layout Plain Layout
3440
3441 \backslash
3442 thispagestyle{empty}
3443 \end_layout
3444
3445 \end_inset
3446
3447
3448 \begin_inset Flex CharStyle:Code
3449 status collapsed
3450
3451 \begin_layout Plain Layout
3452
3453 \backslash
3454 thispagestyle{plain}
3455 \end_layout
3456
3457 \end_inset
3458
3459 , and 
3460 \begin_inset Flex CharStyle:Code
3461 status collapsed
3462
3463 \begin_layout Plain Layout
3464
3465 \backslash
3466 thispagestyle{fancy}
3467 \end_layout
3468
3469 \end_inset
3470
3471 .
3472  Simply insert them in the text on the page you want changed and mark them
3473  as TeX code.
3474  In fact, title pages are marked as plain by default, while following pages
3475  are marked fancy when using the global fancy setting.
3476 \end_layout
3477
3478 \begin_layout Standard
3479 As a final example, it is possible to include an image in the header or
3480  footer.
3481  Suppose you want to put a company logo in the upper lefthand corner.
3482  You might try something like
3483 \end_layout
3484
3485 \begin_layout Standard
3486
3487 \family typewriter
3488
3489 \backslash
3490 lhead{
3491 \backslash
3492 resizebox{1in}{!}{
3493 \backslash
3494 includegraphics{logo.eps}}}
3495 \end_layout
3496
3497 \begin_layout Standard
3498 \noindent
3499 (you may need to preface this with 
3500 \begin_inset Flex CharStyle:Code
3501 status collapsed
3502
3503 \begin_layout Plain Layout
3504 \noindent
3505
3506 \backslash
3507 usepackage{graphics}
3508 \end_layout
3509
3510 \end_inset
3511
3512  if you don't include graphics elsewhere in your document).
3513 \end_layout
3514
3515 \begin_layout Section
3516 Itemize Bullet Selection
3517 \begin_inset CommandInset label
3518 LatexCommand label
3519 name "sec:bullet"
3520
3521 \end_inset
3522
3523
3524 \end_layout
3525
3526 \begin_layout Standard
3527 by
3528 \noun on
3529  Allan Rae
3530 \end_layout
3531
3532 \begin_layout Subsection
3533 Introduction
3534 \end_layout
3535
3536 \begin_layout Standard
3537 LyX provides 216 bullet shapes that can be accessed from a simple dialog.
3538  Using this dialog you can easily specify what bullet shape to use at each
3539  level of an itemized list.
3540  These settings are document-wide so you won't be able to specify different
3541  sets of bullets for different paragraphs.
3542 \begin_inset Foot
3543 status collapsed
3544
3545 \begin_layout Plain Layout
3546 Well, actually you can but you'll have to do it by hand.
3547 \end_layout
3548
3549 \end_inset
3550
3551
3552 \end_layout
3553
3554 \begin_layout Subsection
3555 How it looks
3556 \end_layout
3557
3558 \begin_layout Standard
3559 Open the dialog by selecting the 
3560 \begin_inset Flex CharStyle:MenuItem
3561 status collapsed
3562
3563 \begin_layout Plain Layout
3564 Document\SpecialChar \menuseparator
3565 Settings
3566 \end_layout
3567
3568 \end_inset
3569
3570  menu item and then select the 
3571 \begin_inset Flex CharStyle:MenuItem
3572 status collapsed
3573
3574 \begin_layout Plain Layout
3575 Bullets
3576 \end_layout
3577
3578 \end_inset
3579
3580  tab.
3581 \end_layout
3582
3583 \begin_layout Standard
3584 The dialog provides you with a table of bullet shapes.
3585  A column of buttons on the left of the table provides access to the six
3586  different panels of bullet shapes.
3587  The row of buttons across the top is used to select which bullet depth
3588  you are changing.
3589  A text entry under the table shows the currently selected bullet shape's
3590  LaTeX equivalent and this can be edited if desired.
3591  If you do modify the text you will also need to specify any needed packages
3592  in the LaTeX preamble.
3593 \end_layout
3594
3595 \begin_layout Standard
3596 The six panels are divided up by the packages they require.
3597  The following table shows the mappings from button name to LaTeX packages.
3598 \end_layout
3599
3600 \begin_layout Standard
3601 \align center
3602 \begin_inset Tabular
3603 <lyxtabular version="3" rows="7" columns="2">
3604 <features tabularvalignment="middle">
3605 <column alignment="center" valignment="top" width="0pt">
3606 <column alignment="center" valignment="top" width="0pt">
3607 <row>
3608 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3609 \begin_inset Text
3610
3611 \begin_layout Plain Layout
3612
3613 \family roman
3614 \series medium
3615 \shape up
3616 \size normal
3617 \emph off
3618 \bar no
3619 \noun off
3620 \color none
3621 Button
3622 \end_layout
3623
3624 \end_inset
3625 </cell>
3626 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3627 \begin_inset Text
3628
3629 \begin_layout Plain Layout
3630
3631 \family roman
3632 \series medium
3633 \shape up
3634 \size normal
3635 \emph off
3636 \bar no
3637 \noun off
3638 \color none
3639 Packages Required
3640 \end_layout
3641
3642 \end_inset
3643 </cell>
3644 </row>
3645 <row>
3646 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3647 \begin_inset Text
3648
3649 \begin_layout Plain Layout
3650
3651 \family sans
3652 \series medium
3653 \shape up
3654 \size normal
3655 \emph off
3656 \bar no
3657 \noun off
3658 \color none
3659 Standard
3660 \end_layout
3661
3662 \end_inset
3663 </cell>
3664 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3665 \begin_inset Text
3666
3667 \begin_layout Plain Layout
3668
3669 \series medium
3670 \shape up
3671 \size normal
3672 \emph off
3673 \bar no
3674 \noun off
3675 \color none
3676 base LaTeX
3677 \end_layout
3678
3679 \end_inset
3680 </cell>
3681 </row>
3682 <row>
3683 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3684 \begin_inset Text
3685
3686 \begin_layout Plain Layout
3687
3688 \family sans
3689 \series medium
3690 \shape up
3691 \size normal
3692 \emph off
3693 \bar no
3694 \noun off
3695 \color none
3696 Maths
3697 \end_layout
3698
3699 \end_inset
3700 </cell>
3701 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3702 \begin_inset Text
3703
3704 \begin_layout Plain Layout
3705
3706 \family typewriter
3707 \series medium
3708 \shape up
3709 \size normal
3710 \emph off
3711 \bar no
3712 \noun off
3713 \color none
3714 amssymb.sty
3715 \end_layout
3716
3717 \end_inset
3718 </cell>
3719 </row>
3720 <row>
3721 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3722 \begin_inset Text
3723
3724 \begin_layout Plain Layout
3725
3726 \family sans
3727 \series medium
3728 \shape up
3729 \size normal
3730 \emph off
3731 \bar no
3732 \noun off
3733 \color none
3734 Ding1
3735 \end_layout
3736
3737 \end_inset
3738 </cell>
3739 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3740 \begin_inset Text
3741
3742 \begin_layout Plain Layout
3743
3744 \family typewriter
3745 \series medium
3746 \shape up
3747 \size normal
3748 \emph off
3749 \bar no
3750 \noun off
3751 \color none
3752 pifont.sty
3753 \end_layout
3754
3755 \end_inset
3756 </cell>
3757 </row>
3758 <row>
3759 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3760 \begin_inset Text
3761
3762 \begin_layout Plain Layout
3763
3764 \family sans
3765 \series medium
3766 \shape up
3767 \size normal
3768 \emph off
3769 \bar no
3770 \noun off
3771 \color none
3772 Ding2
3773 \end_layout
3774
3775 \end_inset
3776 </cell>
3777 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3778 \begin_inset Text
3779
3780 \begin_layout Plain Layout
3781
3782 \family typewriter
3783 \series medium
3784 \shape up
3785 \size normal
3786 \emph off
3787 \bar no
3788 \noun off
3789 \color none
3790 pifont.sty
3791 \end_layout
3792
3793 \end_inset
3794 </cell>
3795 </row>
3796 <row>
3797 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3798 \begin_inset Text
3799
3800 \begin_layout Plain Layout
3801
3802 \family sans
3803 \series medium
3804 \shape up
3805 \size normal
3806 \emph off
3807 \bar no
3808 \noun off
3809 \color none
3810 Ding3
3811 \end_layout
3812
3813 \end_inset
3814 </cell>
3815 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3816 \begin_inset Text
3817
3818 \begin_layout Plain Layout
3819
3820 \family typewriter
3821 \series medium
3822 \shape up
3823 \size normal
3824 \emph off
3825 \bar no
3826 \noun off
3827 \color none
3828 pifont.sty
3829 \end_layout
3830
3831 \end_inset
3832 </cell>
3833 </row>
3834 <row>
3835 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3836 \begin_inset Text
3837
3838 \begin_layout Plain Layout
3839
3840 \family sans
3841 \series medium
3842 \shape up
3843 \size normal
3844 \emph off
3845 \bar no
3846 \noun off
3847 \color none
3848 Ding4
3849 \end_layout
3850
3851 \end_inset
3852 </cell>
3853 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3854 \begin_inset Text
3855
3856 \begin_layout Plain Layout
3857
3858 \family typewriter
3859 \series medium
3860 \shape up
3861 \size normal
3862 \emph off
3863 \bar no
3864 \noun off
3865 \color none
3866 pifont.sty
3867 \end_layout
3868
3869 \end_inset
3870 </cell>
3871 </row>
3872 </lyxtabular>
3873
3874 \end_inset
3875
3876
3877 \end_layout
3878
3879 \begin_layout Standard
3880 LyX doesn't stop you using bullets from packages you don't have.
3881  If you get errors from LaTeX when you try to view or print the file, then
3882  it is likely you are missing a package.
3883 \begin_inset Foot
3884 status collapsed
3885
3886 \begin_layout Plain Layout
3887 LyX doesn't restrict your use since you may be editing locally and exporting
3888  elsewhere.
3889 \end_layout
3890
3891 \end_inset
3892
3893
3894 \end_layout
3895
3896 \begin_layout Subsection
3897 How to use it
3898 \end_layout
3899
3900 \begin_layout Standard
3901 Select which bullet depth you want to change then select the bullet shape
3902  and size.
3903  Any changes will not be visible in LyX, but are visible when viewing the
3904  document.
3905 \end_layout
3906
3907 \begin_layout Standard
3908 You can reset a bullet shape to the default simply by clicking your right
3909  mouse button on the appropriate bullet depth button.
3910 \begin_inset Foot
3911 status collapsed
3912
3913 \begin_layout Plain Layout
3914 If you 
3915 \emph on
3916 really
3917 \emph default
3918  want to have multiple sets of paragraphs with different sets of bullets
3919  in each, then you're going to have to get your hands dirty with TeX code.
3920  The bullet selection dialog can help though because it provides you with
3921  the LaTeX code for a wide range of bullet shapes.
3922  To make your own custom paragraphs you have the following options:
3923 \end_layout
3924
3925 \begin_layout Plain Layout
3926 \begin_inset ERT
3927 status open
3928
3929 \begin_layout Plain Layout
3930
3931
3932 \backslash
3933 let
3934 \backslash
3935 savelabelitemi=
3936 \backslash
3937 labelitemi
3938 \end_layout
3939
3940 \end_inset
3941
3942
3943 \end_layout
3944
3945 \begin_layout Plain Layout
3946 \begin_inset ERT
3947 status open
3948
3949 \begin_layout Plain Layout
3950
3951
3952 \backslash
3953 renewcommand
3954 \backslash
3955 labelitemi[0]{
3956 \backslash
3957 small
3958 \backslash
3959 (
3960 \backslash
3961 sharp
3962 \backslash
3963 )}
3964 \end_layout
3965
3966 \end_inset
3967
3968
3969 \end_layout
3970
3971 \begin_layout Itemize
3972 Use the LaTeX command 
3973 \begin_inset Flex CharStyle:Code
3974 status collapsed
3975
3976 \begin_layout Plain Layout
3977
3978 \backslash
3979 renewcommand{}{}
3980 \end_layout
3981
3982 \end_inset
3983
3984  to specify a new bullet shape for a given depth.
3985  You'll also need to save the current bullet shape so you can restore it
3986  again afterwards.
3987  In this itemized list the following LaTeX code was used to change the bullet
3988  used for the first depth.
3989 \end_layout
3990
3991 \begin_deeper
3992 \begin_layout LyX-Code
3993
3994 \backslash
3995 let
3996 \backslash
3997 savelabelitemi=
3998 \backslash
3999 labelitemi 
4000 \end_layout
4001
4002 \begin_layout LyX-Code
4003
4004 \backslash
4005 renewcommand
4006 \backslash
4007 labelitemi[0]{
4008 \backslash
4009 small
4010 \backslash
4011 (
4012 \backslash
4013 sharp
4014 \backslash
4015 )}
4016 \end_layout
4017
4018 \end_deeper
4019 \begin_layout Itemize
4020 Note that the itemize depth is specified in Roman numerals as part of the
4021  
4022 \family typewriter
4023
4024 \backslash
4025 labelitem
4026 \family default
4027  command.
4028 \end_layout
4029
4030 \begin_layout Itemize
4031 \begin_inset ERT
4032 status open
4033
4034 \begin_layout Plain Layout
4035
4036 [
4037 \backslash
4038 (
4039 \backslash
4040 star
4041 \backslash
4042 )]
4043 \end_layout
4044
4045 \end_inset
4046
4047  Specify each individual entry by starting each item with the bullet shape
4048  enclosed in square brackets and set as 
4049 \begin_inset Flex CharStyle:MenuItem
4050 status collapsed
4051
4052 \begin_layout Plain Layout
4053 TeX Code
4054 \end_layout
4055
4056 \end_inset
4057
4058 .
4059  For example, this item was started with 
4060 \begin_inset Flex CharStyle:Code
4061 status collapsed
4062
4063 \begin_layout Plain Layout
4064 [
4065 \backslash
4066 (
4067 \backslash
4068 star
4069 \backslash
4070 )]
4071 \end_layout
4072
4073 \end_inset
4074
4075 .
4076 \end_layout
4077
4078 \begin_layout Plain Layout
4079 \begin_inset ERT
4080 status open
4081
4082 \begin_layout Plain Layout
4083
4084
4085 \backslash
4086 renewcommand
4087 \backslash
4088 labelitemi[0]{
4089 \backslash
4090 savelabelitemi}
4091 \end_layout
4092
4093 \end_inset
4094
4095
4096 \end_layout
4097
4098 \begin_layout Plain Layout
4099 You'll also need to revert the labelitem back to its previous setting for
4100  the global bullet shape settings to remain in effect.
4101  The way used here was:
4102 \end_layout
4103
4104 \begin_layout LyX-Code
4105
4106 \backslash
4107 renewcommand
4108 \backslash
4109 labelitemi[0]{
4110 \backslash
4111 savelabelitemi}
4112 \end_layout
4113
4114 \end_inset
4115
4116
4117 \end_layout
4118
4119 \begin_layout Chapter
4120 The LyX Server
4121 \end_layout
4122
4123 \begin_layout Section
4124 Introduction
4125 \end_layout
4126
4127 \begin_layout Standard
4128 The `LyX server' allows other programs to talk to LyX, invoke LyX commands,
4129  and retrieve information about the LyX internal state.
4130  This is only intended for advanced users, but they should find it useful.
4131  It is by writing to the LyX server, for example, that bibliography managers,
4132  such as JabRef, are able to 
4133 \begin_inset Quotes eld
4134 \end_inset
4135
4136 push
4137 \begin_inset Quotes erd
4138 \end_inset
4139
4140  citations to LyX.
4141 \end_layout
4142
4143 \begin_layout Section
4144 Starting the LyX Server
4145 \end_layout
4146
4147 \begin_layout Standard
4148 The LyX server works through the use of a pair of named pipes.
4149  These are usually located in 
4150 \begin_inset Flex CharStyle:Code
4151 status collapsed
4152
4153 \begin_layout Plain Layout
4154 UserDir
4155 \end_layout
4156
4157 \end_inset
4158
4159
4160 \begin_inset Foot
4161 status collapsed
4162
4163 \begin_layout Plain Layout
4164 On Windows, 
4165 \emph on
4166 local
4167 \emph default
4168  named pipes are special objects located in 
4169 \begin_inset Flex CharStyle:Code
4170 status collapsed
4171
4172 \begin_layout Plain Layout
4173
4174 \backslash
4175
4176 \backslash
4177 .
4178 \backslash
4179 pipe
4180 \end_layout
4181
4182 \end_inset
4183
4184 .
4185 \end_layout
4186
4187 \end_inset
4188
4189  and have the names 
4190 \begin_inset Quotes eld
4191 \end_inset
4192
4193
4194 \begin_inset Flex CharStyle:Code
4195 status collapsed
4196
4197 \begin_layout Plain Layout
4198 lyxpipe.in
4199 \end_layout
4200
4201 \end_inset
4202
4203
4204 \begin_inset Quotes erd
4205 \end_inset
4206
4207  and 
4208 \begin_inset Quotes eld
4209 \end_inset
4210
4211
4212 \begin_inset Flex CharStyle:Code
4213 status collapsed
4214
4215 \begin_layout Plain Layout
4216 lyxpipe.out
4217 \end_layout
4218
4219 \end_inset
4220
4221
4222 \begin_inset Quotes erd
4223 \end_inset
4224
4225 .
4226  External programs write into 
4227 \begin_inset Flex CharStyle:Code
4228 status collapsed
4229
4230 \begin_layout Plain Layout
4231 lyxpipe.in
4232 \end_layout
4233
4234 \end_inset
4235
4236  and read back data from 
4237 \begin_inset Flex CharStyle:Code
4238 status collapsed
4239
4240 \begin_layout Plain Layout
4241 lyxpipe.out
4242 \end_layout
4243
4244 \end_inset
4245
4246 .
4247  The stem of the pipe names can be defined in the 
4248 \begin_inset Flex CharStyle:MenuItem
4249 status collapsed
4250
4251 \begin_layout Plain Layout
4252 Tools\SpecialChar \menuseparator
4253 Preferences
4254 \end_layout
4255
4256 \end_inset
4257
4258  dialog, for example 
4259 \begin_inset Flex CharStyle:Code
4260 status collapsed
4261
4262 \begin_layout Plain Layout
4263 "/home/myhome/lyxpipe"
4264 \end_layout
4265
4266 \end_inset
4267
4268 , or 
4269 \begin_inset Flex CharStyle:Code
4270 status collapsed
4271
4272 \begin_layout Plain Layout
4273 "
4274 \backslash
4275
4276 \backslash
4277 .
4278 \backslash
4279 pipe
4280 \backslash
4281 lyxpipe"
4282 \end_layout
4283
4284 \end_inset
4285
4286  on Windows.
4287  You 
4288 \emph on
4289 must
4290 \emph default
4291  configure this manually in order for the server to start.
4292 \end_layout
4293
4294 \begin_layout Standard
4295 LyX will add the '
4296 \begin_inset Flex CharStyle:Code
4297 status collapsed
4298
4299 \begin_layout Plain Layout
4300 .in
4301 \end_layout
4302
4303 \end_inset
4304
4305 ' and '
4306 \begin_inset Flex CharStyle:Code
4307 status collapsed
4308
4309 \begin_layout Plain Layout
4310 .out
4311 \end_layout
4312
4313 \end_inset
4314
4315 ' to create the pipes.
4316  If one of the pipes already exists, LyX will assume that another LyX process
4317  is already running and will not start the server.
4318  On POSIX (Unix like) systems, if for some other reason, an unused 
4319 \begin_inset Quotes eld
4320 \end_inset
4321
4322 stale
4323 \begin_inset Quotes erd
4324 \end_inset
4325
4326  pipe is left in existence when LyX closes, then LyX will try to delete
4327  it.
4328  If this fails for some reason, you will need to delete the pipes manually
4329  and then restart LyX.
4330  On Windows, pipes are deleted by the OS on program termination or crash,
4331  so 
4332 \begin_inset Quotes eld
4333 \end_inset
4334
4335 stale
4336 \begin_inset Quotes erd
4337 \end_inset
4338
4339  pipes should not be possible.
4340 \end_layout
4341
4342 \begin_layout Standard
4343 To have several LyX processes with servers at the same time, you have to
4344  use different configurations, perhaps by using separate user directories,
4345  each with its own 
4346 \begin_inset Flex CharStyle:Code
4347 status collapsed
4348
4349 \begin_layout Plain Layout
4350 preferences
4351 \end_layout
4352
4353 \end_inset
4354
4355  file, for each process.
4356 \end_layout
4357
4358 \begin_layout Standard
4359 If you are developing a client program, you might find it useful to enable
4360  debugging information from the LyX server.
4361  Do this by starting LyX as 
4362 \begin_inset Flex CharStyle:Code
4363 status collapsed
4364
4365 \begin_layout Plain Layout
4366 lyx -dbg lyxserver
4367 \end_layout
4368
4369 \end_inset
4370
4371 .
4372 \end_layout
4373
4374 \begin_layout Standard
4375 You can find a complete example client written in C in the source distribution
4376  as 
4377 \begin_inset Flex CharStyle:Code
4378 status collapsed
4379
4380 \begin_layout Plain Layout
4381 development/lyxserver/server_monitor.c
4382 \end_layout
4383
4384 \end_inset
4385
4386 .
4387 \end_layout
4388
4389 \begin_layout Standard
4390 Another useful tool is command-line based client you will find in 
4391 \begin_inset Flex CharStyle:Code
4392 status collapsed
4393
4394 \begin_layout Plain Layout
4395 src/client/lyxclient
4396 \end_layout
4397
4398 \end_inset
4399
4400 .
4401 \end_layout
4402
4403 \begin_layout Section
4404 Normal communication
4405 \end_layout
4406
4407 \begin_layout Standard
4408 To issue a LyX call, the client writes a line of ASCII text into the input
4409  pipe.
4410  This line has the following format:
4411 \end_layout
4412
4413 \begin_layout Quote
4414 LYXCMD:
4415 \emph on
4416 clientname
4417 \emph default
4418 :
4419 \emph on
4420 function
4421 \emph default
4422 :
4423 \emph on
4424 argument
4425 \end_layout
4426
4427 \begin_layout Description
4428 clientname is a name that the client can choose arbitrarily.
4429  Its only use is that LyX will echo it if it sends an answer—so a client
4430  can dispatch results from different requesters.
4431 \end_layout
4432
4433 \begin_layout Description
4434 function is the function you want LyX to perform.
4435  It is the same as the commands you'd use in the minibuffer.
4436 \end_layout
4437
4438 \begin_layout Description
4439 argument is an optional argument which is meaningful only to some functions
4440  (for instance, the 
4441 \begin_inset Quotes eld
4442 \end_inset
4443
4444 self-insert
4445 \begin_inset Quotes erd
4446 \end_inset
4447
4448  LFUN will insert the argument as text at the cursor position).
4449 \end_layout
4450
4451 \begin_layout Standard
4452 The answer from LyX will arrive in the output pipe and be of the form
4453 \end_layout
4454
4455 \begin_layout Quote
4456 INFO:
4457 \emph on
4458 clientname
4459 \emph default
4460 :
4461 \emph on
4462 function
4463 \emph default
4464 :
4465 \emph on
4466 data
4467 \end_layout
4468
4469 \begin_layout Standard
4470 where 
4471 \emph on
4472 clientname
4473 \emph default
4474  and 
4475 \emph on
4476 function
4477 \emph default
4478  are just echoed from the command request, while 
4479 \emph on
4480 data
4481 \emph default
4482  is more or less useful information filled according to how the command
4483  execution worked out.
4484  Some commands, such as 
4485 \begin_inset Quotes eld
4486 \end_inset
4487
4488 font-state
4489 \begin_inset Quotes erd
4490 \end_inset
4491
4492 , will return information about the internal state of LyX, while other will
4493  return an empty data-response.
4494  This means that the command execution went fine.
4495 \end_layout
4496
4497 \begin_layout Standard
4498 In case of errors, the response from LyX will have this form
4499 \end_layout
4500
4501 \begin_layout Quote
4502 ERROR:
4503 \emph on
4504 clientname
4505 \emph default
4506 :
4507 \emph on
4508 function
4509 \emph default
4510 :
4511 \emph on
4512 error message
4513 \end_layout
4514
4515 \begin_layout Standard
4516 where the 
4517 \emph on
4518 error message
4519 \emph default
4520  should contain an explanation of why the command failed.
4521 \end_layout
4522
4523 \begin_layout Standard
4524 Examples:
4525 \end_layout
4526
4527 \begin_layout LyX-Code
4528 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
4529 \begin_inset Newline newline
4530 \end_inset
4531
4532 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
4533 \begin_inset Newline newline
4534 \end_inset
4535
4536 read a <~/.lyxpipe.out
4537 \begin_inset Newline newline
4538 \end_inset
4539
4540 echo $a
4541 \end_layout
4542
4543 \begin_layout Section
4544 Notification
4545 \end_layout
4546
4547 \begin_layout Standard
4548 LyX can notify clients of events going on asynchronously.
4549  Currently it will only do this if the user binds a key sequence with the
4550  function 
4551 \begin_inset Quotes eld
4552 \end_inset
4553
4554 notify
4555 \begin_inset Quotes erd
4556 \end_inset
4557
4558 .
4559  The format of the string LyX sends is as follows:
4560 \end_layout
4561
4562 \begin_layout Quote
4563 \begin_inset Flex CharStyle:Code
4564 status collapsed
4565
4566 \begin_layout Plain Layout
4567 NOTIFY:
4568 \end_layout
4569
4570 \end_inset
4571
4572
4573 \emph on
4574 key-sequence
4575 \end_layout
4576
4577 \begin_layout Standard
4578 where 
4579 \emph on
4580 key-sequence
4581 \emph default
4582  is the printed representation of the key sequence that was actually typed
4583  by the user.
4584 \end_layout
4585
4586 \begin_layout Standard
4587 This mechanism can be used to extend LyX's command set and implement macros.
4588  Bind some key sequence to 
4589 \begin_inset Quotes eld
4590 \end_inset
4591
4592 notify
4593 \begin_inset Quotes erd
4594 \end_inset
4595
4596 .
4597  Then start a client that listens on the output pipe, dispatches the command
4598  according to the sequence, and starts a function that may use LyX calls
4599  and LyX requests to issue a command or a series of commands to LyX.
4600 \end_layout
4601
4602 \begin_layout Section
4603 The simple LyX Server Protocol
4604 \end_layout
4605
4606 \begin_layout Standard
4607 LyX implements a simple protocol that can be used for session management.
4608  All messages are of the form
4609 \end_layout
4610
4611 \begin_layout Quote
4612 LYXSRV:
4613 \emph on
4614 clientname
4615 \emph default
4616 :
4617 \emph on
4618 protocol message
4619 \end_layout
4620
4621 \begin_layout Standard
4622 where 
4623 \emph on
4624 protocol message
4625 \emph default
4626  can be 
4627 \begin_inset Quotes eld
4628 \end_inset
4629
4630 hello
4631 \begin_inset Quotes erd
4632 \end_inset
4633
4634  or 
4635 \begin_inset Quotes eld
4636 \end_inset
4637
4638 bye
4639 \begin_inset Quotes erd
4640 \end_inset
4641
4642 .
4643  If 
4644 \begin_inset Quotes eld
4645 \end_inset
4646
4647 hello
4648 \begin_inset Quotes erd
4649 \end_inset
4650
4651  is received from a client, LyX will report back to inform the client that
4652  it's listening to it's messages, while 
4653 \begin_inset Quotes eld
4654 \end_inset
4655
4656 bye
4657 \begin_inset Quotes erd
4658 \end_inset
4659
4660  sent from LyX will inform clients that LyX is closing.
4661 \end_layout
4662
4663 \begin_layout Section
4664 Reverse DVI/PDF search
4665 \end_layout
4666
4667 \begin_layout Standard
4668 Some DVI/PDF viewers
4669 \begin_inset Foot
4670 status collapsed
4671
4672 \begin_layout Plain Layout
4673 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
4674  Skim on Mac OSX and SumatraPDF on Windows.
4675 \end_layout
4676
4677 \end_inset
4678
4679  provide 
4680 \emph on
4681 reverse search
4682 \emph default
4683  facility (also called 
4684 \emph on
4685 inverse search
4686 \emph default
4687 ).
4688  This means that you can tell LyX to put the cursor to a specific line in
4689  the document by clicking at the respective position in the DVI/PDF output.
4690  To achieve this, the viewer must be able to communicate with LyX.
4691  This is done via the LyX server either by using the named pipe (
4692 \emph on
4693 lyxpipe
4694 \emph default
4695 ), or the UNIX domain socket (
4696 \emph on
4697 lyxsocket
4698 \emph default
4699 ) that LyX creates in its temporary directory (this is the way the 
4700 \begin_inset Flex CharStyle:Code
4701 status collapsed
4702
4703 \begin_layout Plain Layout
4704 lyxclient
4705 \end_layout
4706
4707 \end_inset
4708
4709  program communicates with LyX).
4710  In some cases, you need a helper script that mediates between the viewer
4711  and LyX, in others, the viewer can communicate with LyX directly.
4712  This depends on the selected viewer and on your operating system.
4713  The same applies to the way viewers need to be configured and the way the
4714  reverse search is actually performed.
4715  In what follows, we will thus describe how to setup reverse search for
4716  specific viewers.
4717  Before we turn to this, though, we will explain what needs to be done generally
4718  to enable reverse search in the DVI/PDF output.
4719 \end_layout
4720
4721 \begin_layout Subsection
4722 Enabling reverse search
4723 \end_layout
4724
4725 \begin_layout Standard
4726 LaTeX provides several different methods for reverse search.
4727  Some are built-in in the 
4728 \begin_inset Flex CharStyle:Code
4729 status collapsed
4730
4731 \begin_layout Plain Layout
4732 latex/pdflatex
4733 \end_layout
4734
4735 \end_inset
4736
4737  program, some are provided by external packages.
4738  Your choice depends on whether your LaTeX distribution already provides
4739  a given method (the built-in methods are rather new) and whether your viewer
4740  can cope with it.
4741  The available methods are described in the following.
4742 \end_layout
4743
4744 \begin_layout Subsubsection*
4745 Built-in DVI-search via src-specials (DVI only) 
4746 \end_layout
4747
4748 \begin_layout Standard
4749 This method provides the DVI file with the necessary information for reverse
4750  search.
4751  It is available in LaTeX since quite some time (any somewhat recent LaTeX
4752  distribution should include it), and it works reliably.
4753  To enable it, change the 
4754 \begin_inset Flex CharStyle:MenuItem
4755 status collapsed
4756
4757 \begin_layout Plain Layout
4758 LaT
4759 \begin_inset ERT
4760 status collapsed
4761
4762 \begin_layout Plain Layout
4763
4764 {}
4765 \end_layout
4766
4767 \end_inset
4768
4769 eX (plain)->DVI
4770 \end_layout
4771
4772 \end_inset
4773
4774  or 
4775 \begin_inset Flex CharStyle:MenuItem
4776 status collapsed
4777
4778 \begin_layout Plain Layout
4779 LaT
4780 \begin_inset ERT
4781 status collapsed
4782
4783 \begin_layout Plain Layout
4784
4785 {}
4786 \end_layout
4787
4788 \end_inset
4789
4790 eX (plain)->DraftDVI
4791 \end_layout
4792
4793 \end_inset
4794
4795  converter in 
4796 \begin_inset Flex CharStyle:MenuItem
4797 status collapsed
4798
4799 \begin_layout Plain Layout
4800 Preferences\SpecialChar \menuseparator
4801 File Handling\SpecialChar \menuseparator
4802 Converters
4803 \end_layout
4804
4805 \end_inset
4806
4807  to 
4808 \begin_inset Flex CharStyle:Code
4809 status collapsed
4810
4811 \begin_layout Plain Layout
4812 latex -src-specials $$i
4813 \end_layout
4814
4815 \end_inset
4816
4817 .
4818  If this doesn't work, check if your TeX engine needs different options
4819  (the syntax might differ in some distributions).
4820 \end_layout
4821
4822 \begin_layout Subsubsection*
4823 External Packages (PDFSync and scrltx) 
4824 \end_layout
4825
4826 \begin_layout Standard
4827 The packages 
4828 \emph on
4829 pdfsync
4830 \emph default
4831  and 
4832 \emph on
4833 scrltx
4834 \emph default
4835  provide reverse search facility for PDF output (via pdflatex) and DVI output,
4836  respectively.
4837  In order to enable it, load the packages in the LyX preamble: 
4838 \end_layout
4839
4840 \begin_layout Itemize
4841 \begin_inset Flex CharStyle:Code
4842 status collapsed
4843
4844 \begin_layout Plain Layout
4845
4846 \backslash
4847 usepackage{pdfsync}
4848 \end_layout
4849
4850 \end_inset
4851
4852  for reverse PDF search,
4853 \end_layout
4854
4855 \begin_layout Itemize
4856  
4857 \begin_inset Flex CharStyle:Code
4858 status collapsed
4859
4860 \begin_layout Plain Layout
4861
4862 \backslash
4863 usepackage[active]{srcltx}
4864 \end_layout
4865
4866 \end_inset
4867
4868  for reverse DVI search.
4869 \end_layout
4870
4871 \begin_layout Standard
4872 If you want to be able to perform both DVI and PDF reverse searches, you
4873  can also insert in the preamble the following lines
4874 \end_layout
4875
4876 \begin_layout LyX-Code
4877
4878 \backslash
4879 usepackage{ifpdf}
4880 \begin_inset Newline newline
4881 \end_inset
4882
4883
4884 \backslash
4885 ifpdf
4886 \begin_inset Newline newline
4887 \end_inset
4888
4889   
4890 \backslash
4891 usepackage{pdfsync}
4892 \begin_inset Newline newline
4893 \end_inset
4894
4895
4896 \backslash
4897 else
4898 \begin_inset Newline newline
4899 \end_inset
4900
4901   
4902 \backslash
4903 usepackage[active]{srcltx}
4904 \begin_inset Newline newline
4905 \end_inset
4906
4907
4908 \backslash
4909 fi
4910 \end_layout
4911
4912 \begin_layout Standard
4913 This way, you can preview the file as either DVI or PDF (pdflatex) and the
4914  right package will be used.
4915 \end_layout
4916
4917 \begin_layout Standard
4918 Note that PDFSync might affect the output layout of your document.
4919  It is therefore advised to disable PDFsync for final documents.
4920 \end_layout
4921
4922 \begin_layout Subsubsection*
4923 Built-in reverse search via SyncTeX (DVI and PDF) 
4924 \end_layout
4925
4926 \begin_layout Standard
4927 Recent versions of 
4928 \begin_inset Flex CharStyle:Code
4929 status collapsed
4930
4931 \begin_layout Plain Layout
4932 (pdf)latex
4933 \end_layout
4934
4935 \end_inset
4936
4937  have built-in support for both PDF and DVI reverse search.
4938  This so-called 
4939 \emph on
4940 SyncTeX
4941 \emph default
4942  facility is basically the result of the integration of the PDFSync package
4943  to the pdftex program and its merge with the 
4944 \emph on
4945 scr-specials
4946 \emph default
4947  approach.
4948  You need at least TeXLive 2008 or a recent MikTeX distribution in order
4949  to use it.
4950  Also note that only a few PDF viewers (Skim on the Mac, SumatraPDF on Windows)
4951  already provide SyncTeX support.
4952 \end_layout
4953
4954 \begin_layout Standard
4955 To enable SyncTeX for DVI output, change the 
4956 \begin_inset Flex CharStyle:MenuItem
4957 status collapsed
4958
4959 \begin_layout Plain Layout
4960 LaT
4961 \begin_inset ERT
4962 status collapsed
4963
4964 \begin_layout Plain Layout
4965
4966 {}
4967 \end_layout
4968
4969 \end_inset
4970
4971 eX (plain) -> DVI
4972 \end_layout
4973
4974 \end_inset
4975
4976  or 
4977 \begin_inset Flex CharStyle:MenuItem
4978 status collapsed
4979
4980 \begin_layout Plain Layout
4981 LaT
4982 \begin_inset ERT
4983 status collapsed
4984
4985 \begin_layout Plain Layout
4986
4987 {}
4988 \end_layout
4989
4990 \end_inset
4991
4992 eX (plain) -> DraftDVI
4993 \end_layout
4994
4995 \end_inset
4996
4997  converter in 
4998 \begin_inset Flex CharStyle:MenuItem
4999 status collapsed
5000
5001 \begin_layout Plain Layout
5002 Preferences\SpecialChar \menuseparator
5003 File Handling\SpecialChar \menuseparator
5004 Converters
5005 \end_layout
5006
5007 \end_inset
5008
5009  to 
5010 \begin_inset Flex CharStyle:Code
5011 status collapsed
5012
5013 \begin_layout Plain Layout
5014 latex -synctex=1 $$i
5015 \end_layout
5016
5017 \end_inset
5018
5019 , and for PDF output, change the 
5020 \begin_inset Flex CharStyle:MenuItem
5021 status collapsed
5022
5023 \begin_layout Plain Layout
5024 LaT
5025 \begin_inset ERT
5026 status collapsed
5027
5028 \begin_layout Plain Layout
5029
5030 {}
5031 \end_layout
5032
5033 \end_inset
5034
5035 eX (pdflatex) -> PDF (pdflatex)
5036 \end_layout
5037
5038 \end_inset
5039
5040  or converter to 
5041 \begin_inset Flex CharStyle:Code
5042 status collapsed
5043
5044 \begin_layout Plain Layout
5045 pdflatex -synctex=1 $$i
5046 \end_layout
5047
5048 \end_inset
5049
5050 .
5051  Check the documentation of your viewer whether the viewer needs to be configure
5052 d for the use with SyncTeX.
5053 \begin_inset Foot
5054 status collapsed
5055
5056 \begin_layout Plain Layout
5057 The 
5058 \begin_inset Flex CharStyle:Code
5059 status collapsed
5060
5061 \begin_layout Plain Layout
5062 -synctex=1
5063 \end_layout
5064
5065 \end_inset
5066
5067  option enables gzip compression.
5068  If your viewer does not support it, you should instead use 
5069 \begin_inset Flex CharStyle:Code
5070 status collapsed
5071
5072 \begin_layout Plain Layout
5073 -synctex=-1
5074 \end_layout
5075
5076 \end_inset
5077
5078 .
5079 \end_layout
5080
5081 \end_inset
5082
5083
5084 \end_layout
5085
5086 \begin_layout Subsection
5087 Configuring and using specific viewers
5088 \end_layout
5089
5090 \begin_layout Subsubsection*
5091 Xdvi (all platforms)
5092 \end_layout
5093
5094 \begin_layout Standard
5095 If you use 
5096 \begin_inset Flex CharStyle:Code
5097 status collapsed
5098
5099 \begin_layout Plain Layout
5100 xdvi
5101 \end_layout
5102
5103 \end_inset
5104
5105 , you don't need to do anything else for performing a reverse DVI search,
5106  as LyX already provides the necessary hooks for automatically using the
5107  
5108 \begin_inset Flex CharStyle:Code
5109 status collapsed
5110
5111 \begin_layout Plain Layout
5112 lyxclient
5113 \end_layout
5114
5115 \end_inset
5116
5117  program.
5118  Just setup your document as described above (reverse search is triggered
5119  by Ctrl-click or Alt-click on Mac OSX, respectively).
5120 \end_layout
5121
5122 \begin_layout Standard
5123 However, if for whatever reason you want to use the named pipe instead of
5124  the socket for communicating with LyX, simply change the DVI viewer in
5125  
5126 \begin_inset Flex CharStyle:MenuItem
5127 status collapsed
5128
5129 \begin_layout Plain Layout
5130 Preferences\SpecialChar \menuseparator
5131 File Handling\SpecialChar \menuseparator
5132 File formats
5133 \end_layout
5134
5135 \end_inset
5136
5137  to
5138 \begin_inset Foot
5139 status collapsed
5140
5141 \begin_layout Plain Layout
5142 On Mac OSX you have to use 
5143 \begin_inset Flex CharStyle:Code
5144 status collapsed
5145
5146 \begin_layout Plain Layout
5147 DISPLAY=:0.0 xdvi -editor 'lyxeditor.sh %f %l'
5148 \end_layout
5149
5150 \end_inset
5151
5152
5153 \end_layout
5154
5155 \end_inset
5156
5157  
5158 \begin_inset Flex CharStyle:Code
5159 status collapsed
5160
5161 \begin_layout Plain Layout
5162 xdvi -editor 'lyxeditor.sh %f %l'
5163 \end_layout
5164
5165 \end_inset
5166
5167 , where 
5168 \begin_inset Flex CharStyle:Code
5169 status collapsed
5170
5171 \begin_layout Plain Layout
5172 lyxeditor.sh
5173 \end_layout
5174
5175 \end_inset
5176
5177  is a suitable script.
5178  For example, a minimal shell script is the following one:
5179 \end_layout
5180
5181 \begin_layout LyX-Code
5182 #!/bin/sh
5183 \begin_inset Newline newline
5184 \end_inset
5185
5186 LYXPIPE="/path/to/lyxpipe"
5187 \begin_inset Newline newline
5188 \end_inset
5189
5190 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
5191 \begin_inset Newline newline
5192 \end_inset
5193
5194 echo "$COMMAND" > "${LYXPIPE}".in || exit
5195 \begin_inset Newline newline
5196 \end_inset
5197
5198 read < "${LYXPIPE}".out || exit
5199 \end_layout
5200
5201 \begin_layout Standard
5202 where 
5203 \begin_inset Flex CharStyle:Code
5204 status collapsed
5205
5206 \begin_layout Plain Layout
5207 /path/to/lyxpipe
5208 \end_layout
5209
5210 \end_inset
5211
5212  is the Ly
5213 \begin_inset ERT
5214 status collapsed
5215
5216 \begin_layout Plain Layout
5217
5218 {}
5219 \end_layout
5220
5221 \end_inset
5222
5223 XServer pipe path specified in 
5224 \begin_inset Flex CharStyle:MenuItem
5225 status collapsed
5226
5227 \begin_layout Plain Layout
5228 Preferences\SpecialChar \menuseparator
5229 Paths
5230 \end_layout
5231
5232 \end_inset
5233
5234 .
5235 \begin_inset Foot
5236 status collapsed
5237
5238 \begin_layout Plain Layout
5239 In the 
5240 \begin_inset Flex CharStyle:Code
5241 status collapsed
5242
5243 \begin_layout Plain Layout
5244 development/tools
5245 \end_layout
5246
5247 \end_inset
5248
5249  folder of a source distribution you can find a 
5250 \begin_inset Flex CharStyle:Code
5251 status collapsed
5252
5253 \begin_layout Plain Layout
5254 lyxeditor
5255 \end_layout
5256
5257 \end_inset
5258
5259  script which is able to locate the 
5260 \emph on
5261 lyxpipe
5262 \emph default
5263  based on your preferences.
5264 \end_layout
5265
5266 \end_inset
5267
5268
5269 \end_layout
5270
5271 \begin_layout Subsubsection*
5272 MacDviX (Mac OSX)
5273 \end_layout
5274
5275 \begin_layout Standard
5276 At the end of 
5277 \begin_inset Flex CharStyle:Code
5278 status collapsed
5279
5280 \begin_layout Plain Layout
5281 /Applications/MacDviX_Folder/calleditor.script
5282 \end_layout
5283
5284 \end_inset
5285
5286 , add the following lines:
5287 \end_layout
5288
5289 \begin_layout LyX-Code
5290 /Applications/Ly
5291 \begin_inset ERT
5292 status collapsed
5293
5294 \begin_layout Plain Layout
5295
5296 {}
5297 \end_layout
5298
5299 \end_inset
5300
5301 X.app/Contents/MacOS/lyxeditor "$2" $1
5302 \begin_inset Newline newline
5303 \end_inset
5304
5305 exit 1
5306 \end_layout
5307
5308 \begin_layout Standard
5309 Modify the lines accordingly if you install LyX somewhere else than in the
5310  Applications folder.
5311 \end_layout
5312
5313 \begin_layout Standard
5314 Reverse search is triggered by Alt-click (OPTION-click).
5315 \end_layout
5316
5317 \begin_layout Subsubsection*
5318 Skim (Mac OSX)
5319 \end_layout
5320
5321 \begin_layout Standard
5322 Enter 
5323 \begin_inset Flex CharStyle:Code
5324 status collapsed
5325
5326 \begin_layout Plain Layout
5327 open -a Skim.app $$i
5328 \end_layout
5329
5330 \end_inset
5331
5332  to the viewer setting in 
5333 \begin_inset Flex CharStyle:MenuItem
5334 status collapsed
5335
5336 \begin_layout Plain Layout
5337 Preferences\SpecialChar \menuseparator
5338 File Handling\SpecialChar \menuseparator
5339 File formats\SpecialChar \menuseparator
5340 PDF (pdflatex)
5341 \end_layout
5342
5343 \end_inset
5344
5345 , and then in 
5346 \begin_inset Flex CharStyle:MenuItem
5347 status collapsed
5348
5349 \begin_layout Plain Layout
5350 Skim\SpecialChar \menuseparator
5351 Preferences\SpecialChar \menuseparator
5352 Sync
5353 \end_layout
5354
5355 \end_inset
5356
5357  select Ly
5358 \begin_inset ERT
5359 status collapsed
5360
5361 \begin_layout Plain Layout
5362
5363 {}
5364 \end_layout
5365
5366 \end_inset
5367
5368 X.
5369 \end_layout
5370
5371 \begin_layout Standard
5372 Reverse search is triggered by COMMAND-SHIFT-click
5373 \end_layout
5374
5375 \begin_layout Subsubsection*
5376 Okular (KDE)
5377 \end_layout
5378
5379 \begin_layout Standard
5380 Go to 
5381 \begin_inset Flex CharStyle:MenuItem
5382 status collapsed
5383
5384 \begin_layout Plain Layout
5385 Settings\SpecialChar \menuseparator
5386 Configure Okular\SpecialChar \ldots{}
5387 \SpecialChar \menuseparator
5388 Editor
5389 \end_layout
5390
5391 \end_inset
5392
5393 , select 
5394 \begin_inset Quotes eld
5395 \end_inset
5396
5397 Custom Text Editor
5398 \begin_inset Quotes erd
5399 \end_inset
5400
5401  and add the command 
5402 \begin_inset Flex CharStyle:Code
5403 status collapsed
5404
5405 \begin_layout Plain Layout
5406 lyxclient -g %f %l
5407 \end_layout
5408
5409 \end_inset
5410
5411 .
5412 \end_layout
5413
5414 \begin_layout Standard
5415 Reverse search is triggered by SHIFT-click.
5416 \end_layout
5417
5418 \begin_layout Subsubsection*
5419 YAP (Windows)
5420 \end_layout
5421
5422 \begin_layout Standard
5423 Launch yap, choose its 
5424 \begin_inset Flex CharStyle:MenuItem
5425 status collapsed
5426
5427 \begin_layout Plain Layout
5428 View\SpecialChar \menuseparator
5429 Options
5430 \end_layout
5431
5432 \end_inset
5433
5434  menu and select the 
5435 \begin_inset Quotes eld
5436 \end_inset
5437
5438 Inverse DVI Search
5439 \begin_inset Quotes erd
5440 \end_inset
5441
5442  tab.
5443  Click on the 
5444 \begin_inset Quotes eld
5445 \end_inset
5446
5447 New\SpecialChar \ldots{}
5448
5449 \begin_inset Quotes erd
5450 \end_inset
5451
5452  button and, in the window that opens, enter 
5453 \begin_inset Quotes eld
5454 \end_inset
5455
5456 LyX Editor
5457 \begin_inset Quotes erd
5458 \end_inset
5459
5460  (or any other name you like) in the 
5461 \begin_inset Quotes eld
5462 \end_inset
5463
5464 Name:
5465 \begin_inset Quotes erd
5466 \end_inset
5467
5468  field.
5469  Now click on the button labeled 
5470 \begin_inset Quotes eld
5471 \end_inset
5472
5473 \SpecialChar \ldots{}
5474
5475 \begin_inset Quotes erd
5476 \end_inset
5477
5478  to open a file dialog and navigate to the directory containing the batch
5479  file 
5480 \begin_inset Flex CharStyle:Code
5481 status collapsed
5482
5483 \begin_layout Plain Layout
5484 lyxeditor.bat
5485 \end_layout
5486
5487 \end_inset
5488
5489  (see below).
5490  Select 
5491 \begin_inset Flex CharStyle:Code
5492 status collapsed
5493
5494 \begin_layout Plain Layout
5495 lyxeditor.bat
5496 \end_layout
5497
5498 \end_inset
5499
5500  and then specify the program arguments as 
5501 \begin_inset Flex CharStyle:Code
5502 status collapsed
5503
5504 \begin_layout Plain Layout
5505 %f %l
5506 \end_layout
5507
5508 \end_inset
5509
5510 .
5511  The 
5512 \begin_inset Flex CharStyle:Code
5513 status collapsed
5514
5515 \begin_layout Plain Layout
5516 lyxeditor.bat
5517 \end_layout
5518
5519 \end_inset
5520
5521  wrapper is used for communicating with LyX through the 
5522 \emph on
5523 lyxpipe
5524 \emph default
5525  and is as follows:
5526 \end_layout
5527
5528 \begin_layout LyX-Code
5529 @echo off
5530 \begin_inset Newline newline
5531 \end_inset
5532
5533 echo LYXCMD:revdvi:server-goto-file-row:%1 %2> 
5534 \backslash
5535
5536 \backslash
5537 .
5538 \backslash
5539 pipe
5540 \backslash
5541 lyxpipe.in
5542 \begin_inset Newline newline
5543 \end_inset
5544
5545 type 
5546 \backslash
5547
5548 \backslash
5549 .
5550 \backslash
5551 pipe
5552 \backslash
5553 lyxpipe.out
5554 \end_layout
5555
5556 \begin_layout Standard
5557 Make sure that the LyXServer pipe path you specified in LyX is 
5558 \begin_inset Flex CharStyle:Code
5559 status collapsed
5560
5561 \begin_layout Plain Layout
5562
5563 \backslash
5564
5565 \backslash
5566 .
5567 \backslash
5568 pipe
5569 \backslash
5570 lyxpipe
5571 \end_layout
5572
5573 \end_inset
5574
5575 , otherwise change the 
5576 \begin_inset Flex CharStyle:Code
5577 status collapsed
5578
5579 \begin_layout Plain Layout
5580 lyxeditor.bat
5581 \end_layout
5582
5583 \end_inset
5584
5585  wrapper accordingly.
5586 \end_layout
5587
5588 \begin_layout Standard
5589 In yap, reverse search is triggered by double-click.
5590 \end_layout
5591
5592 \begin_layout Subsubsection*
5593 SumatraPDF (Windows)
5594 \end_layout
5595
5596 \begin_layout Standard
5597 In order to use SumatraPDF for inverse search, enter 
5598 \begin_inset Flex CharStyle:Code
5599 status collapsed
5600
5601 \begin_layout Plain Layout
5602 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
5603 \end_layout
5604
5605 \end_inset
5606
5607  in the viewer setting in 
5608 \begin_inset Flex CharStyle:MenuItem
5609 status collapsed
5610
5611 \begin_layout Plain Layout
5612 Preferences\SpecialChar \menuseparator
5613 File Handling\SpecialChar \menuseparator
5614 File formats\SpecialChar \menuseparator
5615 PDF (pdflatex)
5616 \end_layout
5617
5618 \end_inset
5619
5620 , where 
5621 \begin_inset Flex CharStyle:Code
5622 status collapsed
5623
5624 \begin_layout Plain Layout
5625 lyxeditor.bat
5626 \end_layout
5627
5628 \end_inset
5629
5630  is the previous wrapper.
5631  If SumatraPDF.exe is not in your command PATH, use its full file name.
5632 \end_layout
5633
5634 \begin_layout Standard
5635 Reverse search is triggered by double-click.
5636 \end_layout
5637
5638 \begin_layout Subsubsection*
5639 YAP (Cygwin)
5640 \end_layout
5641
5642 \begin_layout Standard
5643 First of all, make sure that yap is your default DVI viewer in the Windows
5644  environment, then launch it, choose its 
5645 \begin_inset Flex CharStyle:MenuItem
5646 status collapsed
5647
5648 \begin_layout Plain Layout
5649 View\SpecialChar \menuseparator
5650 Options
5651 \end_layout
5652
5653 \end_inset
5654
5655  menu and select the 
5656 \begin_inset Quotes eld
5657 \end_inset
5658
5659 Inverse DVI Search
5660 \begin_inset Quotes erd
5661 \end_inset
5662
5663  tab.
5664  Click on the 
5665 \begin_inset Quotes eld
5666 \end_inset
5667
5668 New\SpecialChar \ldots{}
5669
5670 \begin_inset Quotes erd
5671 \end_inset
5672
5673  button and, in the window that opens, enter 
5674 \begin_inset Quotes eld
5675 \end_inset
5676
5677 LyX Editor
5678 \begin_inset Quotes erd
5679 \end_inset
5680
5681  (or any other name you like) in the 
5682 \begin_inset Quotes eld
5683 \end_inset
5684
5685 Name:
5686 \begin_inset Quotes erd
5687 \end_inset
5688
5689  field.
5690  Now click on the button labeled 
5691 \begin_inset Quotes eld
5692 \end_inset
5693
5694 \SpecialChar \ldots{}
5695
5696 \begin_inset Quotes erd
5697 \end_inset
5698
5699  to open a file dialog and navigate to the directory containing the 
5700 \begin_inset Flex CharStyle:Code
5701 status collapsed
5702
5703 \begin_layout Plain Layout
5704 lyxeditor.exe
5705 \end_layout
5706
5707 \end_inset
5708
5709  program (which is installed by default on Cygwin along with the LyX executable).
5710  Select 
5711 \begin_inset Flex CharStyle:Code
5712 status collapsed
5713
5714 \begin_layout Plain Layout
5715 lyxeditor.exe
5716 \end_layout
5717
5718 \end_inset
5719
5720  and then specify the program arguments as 
5721 \begin_inset Flex CharStyle:Code
5722 status collapsed
5723
5724 \begin_layout Plain Layout
5725 -g %f %l
5726 \end_layout
5727
5728 \end_inset
5729
5730 .
5731  In this way, you will be using the 
5732 \emph on
5733 lyxsocket
5734 \emph default
5735  for communicating with LyX.
5736  If, for whatever reason, you want to use the 
5737 \emph on
5738 lyxpipe
5739 \emph default
5740 , omit the 
5741 \begin_inset Flex CharStyle:Code
5742 status collapsed
5743
5744 \begin_layout Plain Layout
5745 -g
5746 \end_layout
5747
5748 \end_inset
5749
5750  option and be sure to specify the LyXServer pipe path in the LyX preferences.
5751 \end_layout
5752
5753 \begin_layout Standard
5754 In yap, reverse search is triggered by double-click.
5755 \end_layout
5756
5757 \begin_layout Subsubsection*
5758 SumatraPDF (Cygwin)
5759 \end_layout
5760
5761 \begin_layout Standard
5762 In order to use SumatraPDF for inverse search, enter 
5763 \begin_inset Flex CharStyle:Code
5764 status collapsed
5765
5766 \begin_layout Plain Layout
5767 SumatraPDF.sh
5768 \end_layout
5769
5770 \end_inset
5771
5772  in the viewer setting in 
5773 \begin_inset Flex CharStyle:MenuItem
5774 status collapsed
5775
5776 \begin_layout Plain Layout
5777 Preferences\SpecialChar \menuseparator
5778 File Handling\SpecialChar \menuseparator
5779 File formats\SpecialChar \menuseparator
5780 PDF (pdflatex)
5781 \end_layout
5782
5783 \end_inset
5784
5785 , where 
5786 \begin_inset Flex CharStyle:Code
5787 status collapsed
5788
5789 \begin_layout Plain Layout
5790 SumatraPDF.sh
5791 \end_layout
5792
5793 \end_inset
5794
5795  is the following script (to be placed in your command PATH, 
5796 \begin_inset Flex CharStyle:Code
5797 status collapsed
5798
5799 \begin_layout Plain Layout
5800 /usr/local/bin
5801 \end_layout
5802
5803 \end_inset
5804
5805  being the best choice):
5806 \end_layout
5807
5808 \begin_layout LyX-Code
5809 #!/bin/bash
5810 \begin_inset Newline newline
5811 \end_inset
5812
5813 cd $(dirname $1)
5814 \begin_inset Newline newline
5815 \end_inset
5816
5817 SumatraPDF -inverse-search "lyxeditor -g %f %l" $(basename $1)
5818 \end_layout
5819
5820 \begin_layout Standard
5821 This wrapper script is needed because SumatraPDF is a native Windows application
5822  and does not understand the posix paths used by the Cygwin version of LyX.
5823  If SumatraPDF.exe is not in your command PATH, use its full posix path in
5824  the script above.
5825  The 
5826 \begin_inset Flex CharStyle:Code
5827 status collapsed
5828
5829 \begin_layout Plain Layout
5830 -g
5831 \end_layout
5832
5833 \end_inset
5834
5835  enables communication via the 
5836 \emph on
5837 lyxsocket
5838 \emph default
5839 .
5840  Again, omit the 
5841 \begin_inset Flex CharStyle:Code
5842 status collapsed
5843
5844 \begin_layout Plain Layout
5845 -g
5846 \end_layout
5847
5848 \end_inset
5849
5850  option if you want to use the 
5851 \emph on
5852 lyxpipe
5853 \emph default
5854 , and be sure to specify the LyXServer pipe path in the LyX preferences.
5855 \end_layout
5856
5857 \begin_layout Standard
5858 Reverse search is triggered by double-click.
5859 \end_layout
5860
5861 \begin_layout Chapter
5862 Special Document Classes
5863 \end_layout
5864
5865 \begin_layout Section
5866 A&A Paper
5867 \end_layout
5868
5869 \begin_layout Standard
5870 by 
5871 \noun on
5872 Peter Sütterlin
5873 \end_layout
5874
5875 \begin_layout Subsection
5876 Introduction
5877 \end_layout
5878
5879 \begin_layout Standard
5880 This section describes how LyX can be used to write articles for submission
5881  to the scientific journal 
5882 \emph on
5883 Astronomy and Astrophysics
5884 \emph default
5885  (www.edpsciences.fr/aa/ 
5886 \begin_inset Flex URL
5887 status collapsed
5888
5889 \begin_layout Plain Layout
5890
5891 http://www.edpsciences.fr/aa/
5892 \end_layout
5893
5894 \end_inset
5895
5896 ) using Version 5.01 of the document class 
5897 \family typewriter
5898 aa.cls
5899 \family default
5900 .
5901  This package can be downloaded from the ftp site
5902 \end_layout
5903
5904 \begin_layout Standard
5905 \begin_inset VSpace medskip
5906 \end_inset
5907
5908
5909 \end_layout
5910
5911 \begin_layout Standard
5912 \align center
5913 \begin_inset Flex URL
5914 status collapsed
5915
5916 \begin_layout Plain Layout
5917
5918 ftp://ftp.edpsciences.org/pub/aa/readme.html
5919 \end_layout
5920
5921 \end_inset
5922
5923
5924 \end_layout
5925
5926 \begin_layout Standard
5927 \begin_inset VSpace medskip
5928 \end_inset
5929
5930
5931 \end_layout
5932
5933 \begin_layout Standard
5934 A manual comes together with that package, and this text is not meant to
5935  replace the original manual but merely a short guide how to realize the
5936  correct form of your paper.
5937  
5938 \end_layout
5939
5940 \begin_layout Standard
5941 Please note that the publisher of the journal was changed from Springer
5942  to EDP Sciences starting January 1, 2001.
5943  That change implicated also some slight changes of the style files, namely
5944  the removal of the thesaurus command.
5945  The LyX class aa supports the newest version of these style files, V 5.01.
5946  If you have an older version installed, please upgrade.
5947  For compatibility, the old (version 4) layout has been kept as 
5948 \family sans
5949 article (A&A V4)
5950 \family default
5951 .
5952  Please refer to the comments in 
5953 \family typewriter
5954 LyXDir/layouts/aapaper.layout
5955 \family default
5956 .
5957 \end_layout
5958
5959 \begin_layout Subsection
5960 Getting started
5961 \end_layout
5962
5963 \begin_layout Standard
5964 It is recommended you start from the example template distributed with LyX.
5965  If you are not using a template, note the following settings:
5966 \end_layout
5967
5968 \begin_layout Itemize
5969 Select 
5970 \family sans
5971 article (A&A)
5972 \family default
5973  in the 
5974 \family sans
5975 Document\SpecialChar \menuseparator
5976 Settings
5977 \family default
5978  dialog (OK, that one was obvious).
5979 \end_layout
5980
5981 \begin_layout Itemize
5982 Don't change the option 
5983 \family sans
5984 Page
5985 \begin_inset space ~
5986 \end_inset
5987
5988 style
5989 \family default
5990 : Leave it set to 
5991 \family sans
5992 default
5993 \family default
5994 .
5995  The whole layout is done by the macros, you shouldn't change anything.
5996 \end_layout
5997
5998 \begin_layout Subsection
5999 The header block
6000 \end_layout
6001
6002 \begin_layout Standard
6003 First thing to enter is the header information.
6004  It consists of seven entries, of which some are optional.
6005  They are
6006 \end_layout
6007
6008 \begin_layout Itemize
6009
6010 \family sans
6011 Title
6012 \family default
6013 : [required] 
6014 \end_layout
6015
6016 \begin_layout Itemize
6017
6018 \family sans
6019 Subtitle
6020 \family default
6021 : [optional] 
6022 \end_layout
6023
6024 \begin_layout Itemize
6025
6026 \family sans
6027 Author
6028 \family default
6029 : [required]
6030 \end_layout
6031
6032 \begin_layout Itemize
6033
6034 \family sans
6035 Address
6036 \family default
6037 : [required]
6038 \end_layout
6039
6040 \begin_layout Itemize
6041
6042 \family sans
6043 Offprints
6044 \family default
6045 : [optional] if more than one author: whom to contact for offprint requests.
6046 \end_layout
6047
6048 \begin_layout Itemize
6049
6050 \family sans
6051 Mail
6052 \family default
6053 : [optional] mail address for contacts.
6054 \end_layout
6055
6056 \begin_layout Itemize
6057
6058 \family sans
6059 Date
6060 \family default
6061 : [required].
6062  Suggested format is 
6063 \family typewriter
6064 Received: <date>; Accepted <date> 
6065 \end_layout
6066
6067 \begin_layout Standard
6068 There is no need to issue the 
6069 \family typewriter
6070
6071 \backslash
6072 maketitle
6073 \family default
6074  command, this is done automatically by LyX when the header is finished.
6075  Although the order of the single header entries doesn't matter it is advised
6076  to keep the above sequence, just to get the best optics and meets the layout
6077  of the real document.
6078 \end_layout
6079
6080 \begin_layout Standard
6081 If you want to place footnotes in the header block, e.
6082 \begin_inset space \thinspace{}
6083 \end_inset
6084
6085 g.
6086 \begin_inset space \space{}
6087 \end_inset
6088
6089 to state your present address, just use the standard footnote via the menu
6090  
6091 \family sans
6092 Insert\SpecialChar \menuseparator
6093 Footnote.
6094
6095 \family default
6096  LyX will automagically use the term 
6097 \family typewriter
6098
6099 \backslash
6100 thanks{}
6101 \family default
6102  in that case.
6103 \end_layout
6104
6105 \begin_layout Standard
6106 In addition to these topics, the macros use three additional LaTeX commands
6107  that have no counterpart in LyX:
6108 \end_layout
6109
6110 \begin_layout Itemize
6111
6112 \family typewriter
6113
6114 \backslash
6115 and
6116 \family default
6117  to separate different names for more than one author and institute, respectivel
6118 y.
6119 \end_layout
6120
6121 \begin_layout Itemize
6122
6123 \family typewriter
6124
6125 \backslash
6126 inst{<nr>}
6127 \family default
6128 to mark corresponding author/institute pairs.
6129  The institutes are numbered sequentially as they appear in the 
6130 \family sans
6131 Address
6132 \family default
6133  field, so you have to put a marker to each author.
6134 \end_layout
6135
6136 \begin_layout Itemize
6137
6138 \family typewriter
6139
6140 \backslash
6141 email{address}
6142 \family default
6143  to supply an email address for fast contact.
6144 \end_layout
6145
6146 \begin_layout Standard
6147 In all cases, the appropriate command has to be entered in LyX and marked
6148  as LaTeX code.
6149  See the examples.
6150  
6151 \end_layout
6152
6153 \begin_layout Subsection
6154 The abstract
6155 \end_layout
6156
6157 \begin_layout Standard
6158 The abstract should immediately follow the header block.
6159  With version 5 the abstract environment was changed to a command, and there
6160  is now a resctriction to only one paragraph.
6161  In addition, it should contain an entry with the keywords.
6162  This is not yet implemented for LyX, therefore you have to enter the LaTeX
6163  command 
6164 \family typewriter
6165
6166 \backslash
6167 keywords{}
6168 \family default
6169  by hand and mark it as LaTeX code.
6170  Refer to the example paper.
6171 \end_layout
6172
6173 \begin_layout Subsection
6174 Supported environments
6175 \end_layout
6176
6177 \begin_layout Standard
6178 The A&A paper layout supports the following environments for structuring
6179  your text:
6180 \end_layout
6181
6182 \begin_layout Itemize
6183
6184 \family sans
6185 Standard
6186 \end_layout
6187
6188 \begin_layout Itemize
6189
6190 \family sans
6191 Section
6192 \end_layout
6193
6194 \begin_layout Itemize
6195
6196 \family sans
6197 Subsection
6198 \end_layout
6199
6200 \begin_layout Itemize
6201
6202 \family sans
6203 Subsubsection
6204 \end_layout
6205
6206 \begin_layout Itemize
6207
6208 \family sans
6209 Itemize
6210 \end_layout
6211
6212 \begin_layout Itemize
6213
6214 \family sans
6215 Enumerate
6216 \end_layout
6217
6218 \begin_layout Itemize
6219
6220 \family sans
6221 Description
6222 \end_layout
6223
6224 \begin_layout Itemize
6225
6226 \family sans
6227 Caption
6228 \end_layout
6229
6230 \begin_layout Itemize
6231
6232 \family sans
6233 Abstract
6234 \end_layout
6235
6236 \begin_layout Itemize
6237
6238 \family sans
6239 Acknowledgment
6240 \end_layout
6241
6242 \begin_layout Itemize
6243
6244 \family sans
6245 Bibliography
6246 \end_layout
6247
6248 \begin_layout Itemize
6249
6250 \family sans
6251 LaTeX
6252 \end_layout
6253
6254 \begin_layout Subsection
6255 Commands not supported by LyX
6256 \end_layout
6257
6258 \begin_layout Standard
6259 Some commands are not yet supported by the 
6260 \family sans
6261 paper (A&A)
6262 \family default
6263  layout for LyX.
6264  Some have already been mentioned.
6265  For the sake of completeness, they are listed all together here:
6266 \end_layout
6267
6268 \begin_layout Itemize
6269
6270 \family typewriter
6271
6272 \backslash
6273 and
6274 \end_layout
6275
6276 \begin_layout Itemize
6277
6278 \family typewriter
6279
6280 \backslash
6281 email
6282 \end_layout
6283
6284 \begin_layout Itemize
6285
6286 \family typewriter
6287
6288 \backslash
6289 appendix
6290 \end_layout
6291
6292 \begin_layout Itemize
6293
6294 \family typewriter
6295
6296 \backslash
6297 authorrunning
6298 \end_layout
6299
6300 \begin_layout Itemize
6301
6302 \family typewriter
6303
6304 \backslash
6305 inst{}
6306 \end_layout
6307
6308 \begin_layout Itemize
6309
6310 \family typewriter
6311
6312 \backslash
6313 keywords{}
6314 \end_layout
6315
6316 \begin_layout Itemize
6317
6318 \family typewriter
6319
6320 \backslash
6321 object{}
6322 \end_layout
6323
6324 \begin_layout Itemize
6325
6326 \family typewriter
6327
6328 \backslash
6329 titlerunning{}
6330 \end_layout
6331
6332 \begin_layout Standard
6333 If you want to use any of these commands, you have to enter them yourself.
6334  
6335 \series bold
6336 Do not forget to mark them as LaTeX code!
6337 \end_layout
6338
6339 \begin_layout Subsection
6340 Figure and Table Floats
6341 \end_layout
6342
6343 \begin_layout Standard
6344 LyX provides support for the necessary float environments 
6345 \family sans
6346 figure, figure*, table
6347 \family default
6348  and 
6349 \family sans
6350 table*
6351 \family default
6352 , therefore we won't tell much about it here.
6353  Refer to the 
6354 \emph on
6355 User's
6356 \begin_inset space ~
6357 \end_inset
6358
6359 Guide
6360 \emph default
6361 .
6362  Just remember that tables should be left-aligned.
6363  For that, select the table and change the alignment in 
6364 \family sans
6365 Edit\SpecialChar \menuseparator
6366 Paragraph
6367 \begin_inset space ~
6368 \end_inset
6369
6370 Settings.
6371 \end_layout
6372
6373 \begin_layout Standard
6374 There is only one special thing: the figures with caption besides the figure.
6375  To create such a figure, you have to do the following:
6376 \end_layout
6377
6378 \begin_layout Enumerate
6379 Create a wide figure float: 
6380 \family sans
6381 Insert\SpecialChar \menuseparator
6382 Float\SpecialChar \menuseparator
6383 Figure
6384 \family default
6385 , then right click in the figure and select 
6386 \family sans
6387 \bar under
6388 S
6389 \bar default
6390 pan
6391 \begin_inset space ~
6392 \end_inset
6393
6394 columns
6395 \family default
6396 .
6397 \end_layout
6398
6399 \begin_layout Enumerate
6400 Enter your caption text.
6401 \end_layout
6402
6403 \begin_layout Enumerate
6404 Press 
6405 \family sans
6406 Return
6407 \family default
6408  to move the cursor above the caption.
6409 \end_layout
6410
6411 \begin_layout Enumerate
6412 Insert your figure
6413 \end_layout
6414
6415 \begin_layout Enumerate
6416 Position the cursor behind the figure and insert a horizontal fill: 
6417 \family sans
6418 Insert\SpecialChar \menuseparator
6419 Special
6420 \begin_inset space ~
6421 \end_inset
6422
6423 Character\SpecialChar \menuseparator
6424 Horizontal
6425 \begin_inset space ~
6426 \end_inset
6427
6428 Fill
6429 \family default
6430 .
6431 \end_layout
6432
6433 \begin_layout Enumerate
6434 Switch to LaTeX mode: 
6435 \family sans
6436 M-c
6437 \begin_inset space ~
6438 \end_inset
6439
6440 t
6441 \family default
6442 .
6443 \end_layout
6444
6445 \begin_layout Enumerate
6446 Enter 
6447 \family typewriter
6448
6449 \backslash
6450 parbox[b]{55mm}{
6451 \family default
6452 .
6453  
6454 \series bold
6455 Do not close the brace!
6456 \end_layout
6457
6458 \begin_layout Enumerate
6459 Position the cursor behind the caption text, switch to LaTeX mode and insert
6460  the closing brace: 
6461 \family sans
6462 M-c
6463 \begin_inset space ~
6464 \end_inset
6465
6466 t
6467 \family default
6468  
6469 \family typewriter
6470 }
6471 \family default
6472 .
6473 \end_layout
6474
6475 \begin_layout Standard
6476 Also, refer to the figures in the example paper.
6477 \end_layout
6478
6479 \begin_layout Subsection
6480 Referee layout
6481 \end_layout
6482
6483 \begin_layout Standard
6484 For submission, the paper has to be formated in a special double-spacing
6485  layout.
6486  For this purpose, you have to give the option 
6487 \family typewriter
6488 referee
6489 \family default
6490  to the documentclass.
6491  This must be done using the extra class options field in the 
6492 \family sans
6493 Document\SpecialChar \menuseparator
6494 Settings
6495 \family default
6496  dialog.
6497  Just enter the string 
6498 \family typewriter
6499 referee
6500 \family default
6501  there.
6502 \end_layout
6503
6504 \begin_layout Subsection
6505 The example paper
6506 \end_layout
6507
6508 \begin_layout Standard
6509 The 
6510 \family sans
6511 Examples
6512 \family default
6513  directory contains an example paper written with LyX.
6514  It is the example paper from the original macro package, translated to
6515  LyX.
6516  Use it for inspiration, and compare the original LaTeX code with LyX way
6517  of writing.
6518 \end_layout
6519
6520 \begin_layout Section
6521 AASTeX
6522 \end_layout
6523
6524 \begin_layout Standard
6525 by 
6526 \noun on
6527 Mike Ressler
6528 \end_layout
6529
6530 \begin_layout Subsection
6531 Introduction
6532 \end_layout
6533
6534 \begin_layout Standard
6535 AASTeX is a set of macros produced by the American Astronomical Society
6536  to facilitate electronic manuscript submission to the three journals they
6537  publish: the Astrophysical Journal (including the Letters and Supplement),
6538  the Astronomical Journal, and the Publications of the Astronomical Society
6539  of the Pacific.
6540  LyX has proven to be an excellent tool for generating these documents,
6541  especially given its equation, citation, and figure handling capabilities.
6542  LyX requires version 5.0 (or higher) of these macros; preferably 5.2, which
6543  is the version described here, or higher.
6544  Versions prior to 5.0 are intended for use with LaTeX2.09 and are fundamentally
6545  incompatible with LyX.
6546  The AASTeX package may be downloaded from the AASTeX Web site
6547 \end_layout
6548
6549 \begin_layout Standard
6550 \begin_inset VSpace medskip
6551 \end_inset
6552
6553
6554 \end_layout
6555
6556 \begin_layout Standard
6557 \align center
6558 \begin_inset Flex URL
6559 status collapsed
6560
6561 \begin_layout Plain Layout
6562
6563 http://www.journals.uchicago.edu/AAS/AASTeX
6564 \end_layout
6565
6566 \end_inset
6567
6568
6569 \end_layout
6570
6571 \begin_layout Standard
6572 \begin_inset VSpace medskip
6573 \end_inset
6574
6575
6576 \end_layout
6577
6578 \begin_layout Standard
6579 A complete user guide is contained in that package and you should familiarize
6580  yourself with it thoroughly before embarking on writing a paper in LyX.
6581  LyX will not reduce the need to figure out all the AASTeX commands, it
6582  will only reduce the drudgery of typing everything in.
6583  It is your responsibility to ensure that the final exported LaTeX document
6584  conforms completely to the requirements of the journal to which you are
6585  submitting your paper.
6586 \end_layout
6587
6588 \begin_layout Subsection
6589 Starting a New Paper
6590 \end_layout
6591
6592 \begin_layout Standard
6593 I strongly suggest that you start with the AASTeX template file.
6594  Click on 
6595 \family sans
6596 File\SpecialChar \menuseparator
6597 New from
6598 \family default
6599  
6600 \family sans
6601 Template
6602 \family default
6603 , enter the new file name, then choose the 
6604 \family typewriter
6605 aastex.lyx
6606 \family default
6607  template.
6608  This will show the most common fields found in a manuscript.
6609  Simply overwrite the existing text (including the brackets, 
6610 \family typewriter
6611 <>
6612 \family default
6613 ) with the correct information.
6614  Many of the AASTeX commands and environments can be implemented directly
6615  in LyX, but some cannot: most noticeably 
6616 \family typewriter
6617
6618 \backslash
6619 altaffilmark
6620 \family default
6621  and 
6622 \family typewriter
6623
6624 \backslash
6625 altaffiltext
6626 \family default
6627 , which should stick out like a sore thumb if you actually just opened the
6628  template file.
6629  For commands such as these, the LaTeX code must be entered directly and
6630  marked as such.
6631  Such commands are referred to as TeX code, or Evil Red Text.
6632  I tried to minimize the amount of TeX code needed in an AASTeX document,
6633  but there is still a bit more required than any of us would like.
6634 \end_layout
6635
6636 \begin_layout Subsection
6637 Finishing Your Paper
6638 \end_layout
6639
6640 \begin_layout Standard
6641 When the paper is finished to your satisfaction and previews/prints correctly,
6642  there are a few 
6643 \begin_inset Quotes eld
6644 \end_inset
6645
6646 postprocessing
6647 \begin_inset Quotes erd
6648 \end_inset
6649
6650  actions which need to be done before you submit it to the journals.
6651  
6652 \end_layout
6653
6654 \begin_layout Enumerate
6655 Export your paper as a LaTeX file (
6656 \family sans
6657 File\SpecialChar \menuseparator
6658 Export\SpecialChar \menuseparator
6659 LaTeX
6660 \family default
6661 ).
6662  
6663 \end_layout
6664
6665 \begin_layout Enumerate
6666 Edit the resulting 
6667 \family typewriter
6668 .tex
6669 \family default
6670  file with your favorite text editor
6671 \end_layout
6672
6673 \begin_deeper
6674 \begin_layout Enumerate
6675 remove the comment lines before the 
6676 \family typewriter
6677
6678 \backslash
6679 documentclass
6680 \family default
6681  command
6682 \end_layout
6683
6684 \begin_layout Enumerate
6685 remove the 
6686 \family typewriter
6687
6688 \backslash
6689 usepackage...{fontenc}
6690 \family default
6691  line if it appears (usually just after 
6692 \family typewriter
6693
6694 \backslash
6695 documentclass
6696 \family default
6697 }; also remove the 
6698 \family typewriter
6699
6700 \backslash
6701 secnumdepth
6702 \family default
6703  line if it appears.
6704 \end_layout
6705
6706 \begin_layout Enumerate
6707 remove everything between (and including) the 
6708 \family typewriter
6709
6710 \backslash
6711 makeatletter
6712 \family default
6713  and 
6714 \family typewriter
6715
6716 \backslash
6717 makeatother
6718 \family default
6719  commands, except for any commands you specifically put into the LaTeX preamble
6720  (which should appear immediately after the 
6721 \begin_inset Quotes eld
6722 \end_inset
6723
6724 User specified LaTeX commands
6725 \begin_inset Quotes erd
6726 \end_inset
6727
6728  comment in the 
6729 \family typewriter
6730 .tex
6731 \family default
6732  file).
6733 \end_layout
6734
6735 \end_deeper
6736 \begin_layout Enumerate
6737 Run the resulting file through LaTeX to make sure it still processes correctly.
6738 \end_layout
6739
6740 \begin_layout Enumerate
6741 Reread the journal requirements to make sure your filenames and formats
6742  are correct.
6743 \end_layout
6744
6745 \begin_layout Enumerate
6746 Submit it.
6747 \end_layout
6748
6749 \begin_layout Subsection
6750 Comments On Specific Commands
6751 \end_layout
6752
6753 \begin_layout Standard
6754 I will not describe the detailed usage of the individual AASTeX commands:
6755  the AASTeX User Guide (
6756 \family typewriter
6757 aasguide.tex
6758 \family default
6759 ) gives a good description of each.
6760  Thus it's probably easiest for me to go down the list as found in the guide
6761  and offer comments where necessary.
6762  So let's begin \SpecialChar \ldots{}
6763
6764 \end_layout
6765
6766 \begin_layout Subsubsection
6767 Things that work as expected
6768 \end_layout
6769
6770 \begin_layout Standard
6771 \begin_inset ERT
6772 status open
6773
6774 \begin_layout Plain Layout
6775
6776
6777 \backslash
6778 begin{sloppypar}
6779 \end_layout
6780
6781 \end_inset
6782
6783
6784 \end_layout
6785
6786 \begin_layout Standard
6787 Because they work as you might expect, I simply list them and the section
6788  they are found in: 
6789 \family typewriter
6790
6791 \backslash
6792 documentclass
6793 \family default
6794  (2.1.1), 
6795 \family typewriter
6796
6797 \backslash
6798 begin{document}
6799 \family default
6800  (2.2), 
6801 \family typewriter
6802
6803 \backslash
6804 title
6805 \family default
6806  (2.3), 
6807 \family typewriter
6808
6809 \backslash
6810 author
6811 \family default
6812  (2.3), 
6813 \family typewriter
6814
6815 \backslash
6816 affil
6817 \family default
6818  (2.3), 
6819 \family typewriter
6820
6821 \backslash
6822 abstract
6823 \family default
6824  (2.4), 
6825 \family typewriter
6826
6827 \backslash
6828 keywords
6829 \family default
6830  (2.5), 
6831 \family typewriter
6832
6833 \backslash
6834 section
6835 \family default
6836  (2.7), 
6837 \family typewriter
6838
6839 \backslash
6840 subsection
6841 \family default
6842  (2.7), 
6843 \family typewriter
6844
6845 \backslash
6846 subsubsection
6847 \family default
6848  (2.7), 
6849 \family typewriter
6850
6851 \backslash
6852 paragraph
6853 \family default
6854  (2.7), 
6855 \family typewriter
6856
6857 \backslash
6858 facility
6859 \family default
6860  (2.10), 
6861 \family typewriter
6862
6863 \backslash
6864 begin{displaymath}
6865 \family default
6866  (2.12), 
6867 \family typewriter
6868
6869 \backslash
6870 begin{equation}
6871 \family default
6872  (2.12), 
6873 \family typewriter
6874
6875 \backslash
6876 begin{eqnarray}
6877 \family default
6878  (2.12), 
6879 \family typewriter
6880
6881 \backslash
6882 begin{mathletters}
6883 \family default
6884  (2.12), 
6885 \family typewriter
6886
6887 \backslash
6888 begin{thebibliography}
6889 \family default
6890  (2.13.1), 
6891 \family typewriter
6892
6893 \backslash
6894 bibitem
6895 \family default
6896  (2.13.2), all the cite commands and their variations (2.13.2), the generic
6897  graphicx figure commands (2.14.1), 
6898 \family typewriter
6899
6900 \backslash
6901 begin{table}
6902 \family default
6903  (2.15.4), 
6904 \family typewriter
6905
6906 \backslash
6907 begin{tabular}
6908 \family default
6909  (2.15.4), 
6910 \family typewriter
6911
6912 \backslash
6913 caption
6914 \family default
6915  (2.15.4), 
6916 \family typewriter
6917
6918 \backslash
6919 label
6920 \family default
6921  (2.15.4, amongst other places), 
6922 \family typewriter
6923
6924 \backslash
6925 tablerefs
6926 \family default
6927  (2.15.5), 
6928 \family typewriter
6929
6930 \backslash
6931 tablecomments
6932 \family default
6933  (2.15.5), 
6934 \family typewriter
6935
6936 \backslash
6937 url
6938 \family default
6939  (2.17.4), 
6940 \family typewriter
6941
6942 \backslash
6943 end{document}
6944 \family default
6945  (2.18).
6946 \end_layout
6947
6948 \begin_layout Standard
6949 The following style options also work correctly: 
6950 \family typewriter
6951 longabstract
6952 \family default
6953  (2.4), 
6954 \family typewriter
6955 preprint
6956 \family default
6957  (3.2.1), 
6958 \family typewriter
6959 preprint2
6960 \family default
6961  (3.2.2), 
6962 \family typewriter
6963 eqsecnum
6964 \family default
6965  (3.3), 
6966 \family typewriter
6967 flushrt
6968 \family default
6969  (3.4).
6970  Simply put them in the 
6971 \family sans
6972 Options
6973 \family default
6974  box in 
6975 \family sans
6976 Layout\SpecialChar \menuseparator
6977 Document
6978 \family default
6979 .
6980 \end_layout
6981
6982 \begin_layout Standard
6983 \begin_inset ERT
6984 status open
6985
6986 \begin_layout Plain Layout
6987
6988
6989 \backslash
6990 end{sloppypar}
6991 \end_layout
6992
6993 \end_inset
6994
6995
6996 \end_layout
6997
6998 \begin_layout Subsubsection
6999 Things that work, but require more comment
7000 \end_layout
7001
7002 \begin_layout Standard
7003 The following items work, but require a little more discussion:
7004 \end_layout
7005
7006 \begin_layout Itemize
7007 These items are reserved for use by the journal editors, but you can put
7008  them into the LaTeX preamble if you feel compelled to do so: 
7009 \family typewriter
7010
7011 \backslash
7012 received
7013 \family default
7014
7015 \family typewriter
7016
7017 \backslash
7018 revised
7019 \family default
7020
7021 \family typewriter
7022
7023 \backslash
7024 accepted
7025 \family default
7026
7027 \family typewriter
7028
7029 \backslash
7030 ccc
7031 \family default
7032
7033 \family typewriter
7034
7035 \backslash
7036 cpright
7037 \family default
7038  (all from 2.1.3)
7039 \end_layout
7040
7041 \begin_layout Itemize
7042 These items may be placed in the LaTeX preamble, and are included as blanks
7043  in the template file: 
7044 \family typewriter
7045
7046 \backslash
7047 slugcomment
7048 \family default
7049  (2.1.4), 
7050 \family typewriter
7051
7052 \backslash
7053 shorttitle
7054 \family default
7055  (2.1.5), 
7056 \family typewriter
7057
7058 \backslash
7059 shortauthors
7060 \family default
7061  (2.1.5)
7062 \end_layout
7063
7064 \begin_layout Itemize
7065
7066 \family typewriter
7067
7068 \backslash
7069 email
7070 \family default
7071  (2.3) â€“ can only be used 
7072 \begin_inset Quotes eld
7073 \end_inset
7074
7075 standalone
7076 \begin_inset Quotes erd
7077 \end_inset
7078
7079 , not in the middle of a paragraph.
7080  Use TeX code if you need to embed it.
7081 \end_layout
7082
7083 \begin_layout Itemize
7084
7085 \family typewriter
7086
7087 \backslash
7088 and
7089 \family default
7090  (2.3) â€“ will have extra {} after it.
7091  This should not cause an error.
7092 \end_layout
7093
7094 \begin_layout Itemize
7095
7096 \family typewriter
7097
7098 \backslash
7099 notetoeditor
7100 \family default
7101  (2.6) â€“ can only be used 
7102 \begin_inset Quotes eld
7103 \end_inset
7104
7105 standalone
7106 \begin_inset Quotes erd
7107 \end_inset
7108
7109 , not in the middle of a paragraph.
7110  Use TeX code if you need to embed it.
7111 \end_layout
7112
7113 \begin_layout Itemize
7114
7115 \family typewriter
7116
7117 \backslash
7118 placetable
7119 \family default
7120  (2.8) â€“ can't insert a cross-reference tag, you must type the tag name by
7121  hand
7122 \end_layout
7123
7124 \begin_layout Itemize
7125
7126 \family typewriter
7127
7128 \backslash
7129 placefigure
7130 \family default
7131  (2.8) â€“ same as for 
7132 \family typewriter
7133
7134 \backslash
7135 placetable
7136 \end_layout
7137
7138 \begin_layout Itemize
7139
7140 \family typewriter
7141
7142 \backslash
7143 acknowledgements
7144 \family default
7145  (2.9) â€“ will have extra {} after it.
7146  This should not cause an error.
7147 \end_layout
7148
7149 \begin_layout Itemize
7150
7151 \family typewriter
7152
7153 \backslash
7154 appendix
7155 \family default
7156  (2.11) â€“ will have extra {} after it.
7157  This should not cause an error.
7158 \end_layout
7159
7160 \begin_layout Itemize
7161
7162 \family typewriter
7163
7164 \backslash
7165 figcaption
7166 \family default
7167  (2.14.2) â€“ you can insert an optional filename argument by placing the cursor
7168  at the beginning of the text and selecting 
7169 \family sans
7170 Insert\SpecialChar \menuseparator
7171 Short Title
7172 \family default
7173 .
7174  
7175 \begin_inset Quotes eld
7176 \end_inset
7177
7178 Short Title
7179 \begin_inset Quotes erd
7180 \end_inset
7181
7182  inserts an optional argument of the type needed by 
7183 \family typewriter
7184
7185 \backslash
7186 figcaption
7187 \family default
7188 .
7189  Hopefully it will be renamed someday.
7190 \end_layout
7191
7192 \begin_layout Itemize
7193
7194 \family typewriter
7195
7196 \backslash
7197 objectname
7198 \family default
7199  (2.17.1) â€“ same as 
7200 \family typewriter
7201
7202 \backslash
7203 figcaption
7204 \family default
7205  for the catalog ID optional parameter
7206 \end_layout
7207
7208 \begin_layout Itemize
7209
7210 \family typewriter
7211
7212 \backslash
7213 dataset
7214 \family default
7215  (2.17.1) â€“ same as 
7216 \family typewriter
7217
7218 \backslash
7219 figcaption
7220 \family default
7221  for the catalog ID optional parameter
7222 \end_layout
7223
7224 \begin_layout Subsubsection
7225 Things not implemented, use TeX code
7226 \end_layout
7227
7228 \begin_layout Standard
7229 \begin_inset ERT
7230 status open
7231
7232 \begin_layout Plain Layout
7233
7234
7235 \backslash
7236 begin{sloppypar}
7237 \end_layout
7238
7239 \end_inset
7240
7241
7242 \end_layout
7243
7244 \begin_layout Standard
7245
7246 \family typewriter
7247
7248 \backslash
7249 altaffilmark
7250 \family default
7251  (2.3), 
7252 \family typewriter
7253
7254 \backslash
7255 altaffiltext
7256 \family default
7257  (2.3), 
7258 \family typewriter
7259
7260 \backslash
7261 eqnum
7262 \family default
7263  (2.12), 
7264 \family typewriter
7265
7266 \backslash
7267 setcounter{equation}
7268 \family default
7269  (2.12), Journal name abbreviations (2.13.4), 
7270 \family typewriter
7271
7272 \backslash
7273 figurenum
7274 \family default
7275  (2.14.1), 
7276 \family typewriter
7277
7278 \backslash
7279 epsscale
7280 \family default
7281  (2.14.1), 
7282 \family typewriter
7283
7284 \backslash
7285 plotone
7286 \family default
7287  (2.14.1), 
7288 \family typewriter
7289
7290 \backslash
7291 plottwo
7292 \family default
7293  (2.14.1), 
7294 \family typewriter
7295
7296 \backslash
7297 tablenum
7298 \family default
7299  (2.15.4), 
7300 \family typewriter
7301
7302 \backslash
7303 tableline
7304 \family default
7305  (2.15.4, insert it as the first element in the lefthand cell after where
7306  you want it.
7307  Don't use any of LyX's rules in the table), 
7308 \family typewriter
7309
7310 \backslash
7311 tablenotemark
7312 \family default
7313  (2.15.5), 
7314 \family typewriter
7315
7316 \backslash
7317 tablenotetext
7318 \family default
7319  (2.15.5), much of Misc (2.17, except 
7320 \family typewriter
7321
7322 \backslash
7323 objectname
7324 \family default
7325
7326 \family typewriter
7327
7328 \backslash
7329 dataset
7330 \family default
7331
7332 \family typewriter
7333
7334 \backslash
7335 url
7336 \family default
7337 , and 
7338 \family typewriter
7339
7340 \backslash
7341 email
7342 \family default
7343 ; see above), 
7344 \family typewriter
7345
7346 \backslash
7347 singlespace
7348 \family default
7349  (3.1), 
7350 \family typewriter
7351
7352 \backslash
7353 doublespace
7354 \family default
7355  (3.1), 
7356 \family typewriter
7357
7358 \backslash
7359 onecolumn
7360 \family default
7361  (3.2), 
7362 \family typewriter
7363
7364 \backslash
7365 twocolumn
7366 \family default
7367  (3.2)
7368 \end_layout
7369
7370 \begin_layout Standard
7371 \begin_inset ERT
7372 status open
7373
7374 \begin_layout Plain Layout
7375
7376
7377 \backslash
7378 end{sloppypar}
7379 \end_layout
7380
7381 \end_inset
7382
7383
7384 \end_layout
7385
7386 \begin_layout Subsubsection
7387 Things that cannot be implemented
7388 \end_layout
7389
7390 \begin_layout Standard
7391 \SpecialChar \ldots{}
7392  at least in any meaningful sort of way, so I suggest ignoring them.
7393  They are the references environment (2.13.3), and the deluxetable environment
7394  (2.15).
7395  If you really, really need to use deluxetable, I suggest editing it in
7396  a separate file with a text editor, then using 
7397 \family sans
7398 Insert\SpecialChar \menuseparator
7399 Child
7400 \begin_inset space ~
7401 \end_inset
7402
7403 Document
7404 \family default
7405  to include it in your LyX document.
7406  See the 
7407 \family typewriter
7408 aas_sample.lyx
7409 \family default
7410  file to see an example of this.
7411 \end_layout
7412
7413 \begin_layout Subsection
7414 FAQs, Tips, Tricks, and Other Ruminations
7415 \end_layout
7416
7417 \begin_layout Subsubsection
7418 Getting LyX and AASTeX to cooperate
7419 \end_layout
7420
7421 \begin_layout Standard
7422 It can be a bit tricky to get LyX to recognize a new layout and document
7423  class.
7424  When all else fails, do this:
7425 \end_layout
7426
7427 \begin_layout Enumerate
7428 Make certain that LaTeX can find AASTeX.
7429  Copy sample.tex (and perhaps table.tex) from the AASTeX distribution into
7430  a directory completely unrelated to LaTeX or AASTeX and run LaTeX on 
7431 \family typewriter
7432 sample.tex
7433 \family default
7434 .
7435 \end_layout
7436
7437 \begin_layout Enumerate
7438 Make certain that 
7439 \family typewriter
7440 aastex.layout
7441 \family default
7442  appears in LyX's 
7443 \family typewriter
7444 layouts
7445 \family default
7446  folder
7447 \end_layout
7448
7449 \begin_layout Enumerate
7450 Rerun 
7451 \family sans
7452 Tools\SpecialChar \menuseparator
7453 Reconfigure
7454 \family default
7455  in LyX, then restart LyX.
7456 \end_layout
7457
7458 \begin_layout Enumerate
7459 Open a regular new file, not from a template.
7460  Does AASTeX appear in the class list in 
7461 \family sans
7462 Document\SpecialChar \menuseparator
7463 Settings
7464 \family default
7465 ?
7466 \end_layout
7467
7468 \begin_layout Standard
7469 If you get a warning from an existing AASTeX document about not being able
7470  to find the AASTeX layout or a message about 
7471 \begin_inset Quotes eld
7472 \end_inset
7473
7474 You should not mix title layouts with normal ones
7475 \begin_inset Quotes erd
7476 \end_inset
7477
7478 , things haven't been installed correctly.
7479 \end_layout
7480
7481 \begin_layout Subsubsection
7482 LaTeX error processing a table 
7483 \end_layout
7484
7485 \begin_layout Standard
7486 LyX, by default, attempts to center the table caption/title.
7487  This seems to produce a bad interaction in AASTeX so you should click somewhere
7488  in the caption/title, then select 
7489 \family sans
7490 Edit\SpecialChar \menuseparator
7491 Paragraph
7492 \begin_inset space ~
7493 \end_inset
7494
7495 Settings
7496 \family default
7497 , then set the 
7498 \family sans
7499 Alignment
7500 \family default
7501  to 
7502 \family sans
7503 Block
7504 \family default
7505 .
7506  This took care of it for me.
7507 \end_layout
7508
7509 \begin_layout Subsubsection
7510 References
7511 \end_layout
7512
7513 \begin_layout Standard
7514 A couple of things: 1) I have noticed some funny spacing in the reference
7515  entries in the text.
7516  When you enter the bibliography item data, make sure their is 
7517 \emph on
7518 no
7519 \emph default
7520  space between the last author and the parenthesis setting off the year;
7521  
7522 \emph on
7523 e.
7524 \begin_inset space \thinspace{}
7525 \end_inset
7526
7527 g.
7528 \begin_inset space \space{}
7529 \end_inset
7530
7531
7532 \emph default
7533 type 
7534 \family typewriter
7535 Ressler(1992)
7536 \family default
7537 , not 
7538 \family typewriter
7539 Ressler (1992)
7540 \family default
7541 .
7542  2) Entering the references at all is not obvious.
7543  The easiest thing is to start typing your first reference at the end of
7544  the document, then mark it as type 
7545 \family sans
7546 References
7547 \family default
7548 .
7549  That will put a small gray box in front of what you just typed.
7550  Click on the box to fill in the rest of the information.
7551  For new references, go to the end of an existing reference and press return.
7552  That will create a new line with its own box, etc.
7553 \end_layout
7554
7555 \begin_layout Subsubsection
7556 Including EPS files
7557 \end_layout
7558
7559 \begin_layout Standard
7560 Even though AASTeX provides its own figure commands (
7561 \family typewriter
7562
7563 \backslash
7564 plotone
7565 \family default
7566 , for example), I much prefer LaTeX's standard figure commands (with the
7567  default graphicx).
7568  You can insert the 
7569 \family typewriter
7570
7571 \backslash
7572 plotone
7573 \family default
7574 , etc.
7575 \begin_inset space ~
7576 \end_inset
7577
7578 commands as TeX code into a Figure Float box if you desire, but I never
7579  have much luck getting the layout right.
7580  With the standard graphics, LyX will insert a 
7581 \family typewriter
7582
7583 \backslash
7584 usepackage{graphicx}
7585 \family default
7586  command into the LaTeX preamble and handle the figures in the standard
7587  LaTeX2e way, interspersing the figures in the text.
7588  I believe ApJ accepts figures exactly this way now; AJ might still use
7589  the 
7590 \begin_inset Quotes eld
7591 \end_inset
7592
7593 stack everything at the end
7594 \begin_inset Quotes erd
7595 \end_inset
7596
7597  technique.
7598 \end_layout
7599
7600 \begin_layout Subsubsection
7601 Things I could have done, but didn't
7602 \end_layout
7603
7604 \begin_layout Standard
7605 There are a few 
7606 \begin_inset Quotes eld
7607 \end_inset
7608
7609 pretty
7610 \begin_inset Quotes erd
7611 \end_inset
7612
7613  things I could have implemented, but chose not to.
7614  For instance, I saw no point in double-spacing the text in the LyX window,
7615  even though it is double-spaced in the paper manuscript.
7616  Also, I chose not to make separate layouts for the preprint and preprint2
7617  styles.
7618  Since I assume you will spend most of your time in the plain manuscript
7619  mode anyway, I decided not to chew up more disk space with this.
7620  
7621 \end_layout
7622
7623 \begin_layout Subsection
7624 Final Caveat
7625 \end_layout
7626
7627 \begin_layout Standard
7628 Your mileage may vary.
7629  I've now had papers published by both ApJ and AJ that have had 98% of the
7630  effort done in LyX; the last 2% was the LaTeX post-processing and a few
7631  cleanups.
7632  I have had no trouble with the submission process, and I'm sure the journals
7633  were never aware that there might be a difference.
7634  So, go forth and publish!
7635 \end_layout
7636
7637 \begin_layout Section
7638 AMS LaTeX
7639 \end_layout
7640
7641 \begin_layout Standard
7642 by 
7643 \noun on
7644 David Johnson; updated by Richard Heck
7645 \end_layout
7646
7647 \begin_layout Standard
7648 \begin_inset VSpace bigskip
7649 \end_inset
7650
7651
7652 \end_layout
7653
7654 \begin_layout Standard
7655 \noindent
7656 The AMS LaTeX layouts are set up to conform to suggested styles for mathematical
7657  papers to be submitted to American Mathematical Society publications.
7658  The layouts are not tailored to a specific journal, but easily can be.
7659  You should refer to the AMS documentation for specific instructions for
7660  each journal (usually it will entail only changing a single line in the
7661  TeX output).
7662  That documentation is available on the Web at 
7663 \begin_inset Flex URL
7664 status open
7665
7666 \begin_layout Plain Layout
7667
7668 http://www.ams.org
7669 \end_layout
7670
7671 \end_inset
7672
7673  or by ftp at 
7674 \begin_inset Flex URL
7675 status open
7676
7677 \begin_layout Plain Layout
7678
7679 ftp://ftp.ams.org/pub/tex/amslatex/
7680 \end_layout
7681
7682 \end_inset
7683
7684 .
7685  These layouts are appropriate, and useful, for any mathematical writing.
7686  
7687 \end_layout
7688
7689 \begin_layout Standard
7690 There are two basic AMS LaTeX layouts: 
7691 \end_layout
7692
7693 \begin_layout Itemize
7694 amsart: The standard AMS article format.
7695 \end_layout
7696
7697 \begin_layout Itemize
7698 amsbook: the standard AMS book (really, monograph) format.
7699  
7700 \end_layout
7701
7702 \begin_layout Standard
7703 The layouts themselves contain only the minimum necessary to use the AMS
7704  classes.
7705  They do not, in particular, contain any of the `theorem' environments used
7706  for setting theorems, lemmas, and the like.
7707  These are contained, instead, in the 
7708 \begin_inset Flex CharStyle:Code
7709 status collapsed
7710
7711 \begin_layout Plain Layout
7712 Theorems (AMS)
7713 \end_layout
7714
7715 \end_inset
7716
7717  module, which is loaded by default when when you select one of the AMS
7718  classes.
7719  (It can also be used with other classes and can be removed, if you would
7720  rather use something else.) Less commonly used environments are in the 
7721 \begin_inset Flex CharStyle:Code
7722 status collapsed
7723
7724 \begin_layout Plain Layout
7725 Theorems (AMS-Extended)
7726 \end_layout
7727
7728 \end_inset
7729
7730  module, which must be loaded manually.
7731 \end_layout
7732
7733 \begin_layout Standard
7734 By default, theorems and the like are numbered consecutively throughout
7735  the document, but this may be modified by loading the module 
7736 \begin_inset Flex CharStyle:Code
7737 status collapsed
7738
7739 \begin_layout Plain Layout
7740 Theorems (Order by Section)
7741 \end_layout
7742
7743 \end_inset
7744
7745  or, if you are using 
7746 \begin_inset Flex CharStyle:Code
7747 status collapsed
7748
7749 \begin_layout Plain Layout
7750 book (AMS)
7751 \end_layout
7752
7753 \end_inset
7754
7755 , the module 
7756 \begin_inset Flex CharStyle:Code
7757 status collapsed
7758
7759 \begin_layout Plain Layout
7760 Theorems (Order by Chapter)
7761 \end_layout
7762
7763 \end_inset
7764
7765 .
7766  These will number the results as 
7767 \begin_inset Formula $n.m$
7768 \end_inset
7769
7770 , where the first number refers to the section (or chapter) and the second
7771  refers to the total number of results so far in that section (or chapter).
7772  Many environments are also available unnumbered.
7773  These are indicated by an asterisk at the end.
7774  If you happen to want 
7775 \emph on
7776 only
7777 \emph default
7778  unnumbered results, the the module 
7779 \begin_inset Flex CharStyle:Code
7780 status collapsed
7781
7782 \begin_layout Plain Layout
7783 Theorems (Starred)
7784 \end_layout
7785
7786 \end_inset
7787
7788  provides that option.
7789 \end_layout
7790
7791 \begin_layout Standard
7792 Note that these modules do not 
7793 \emph on
7794 have
7795 \emph default
7796  to be used with the AMS classes.
7797  It is perfectly possible to use the 
7798 \begin_inset Flex CharStyle:Code
7799 status collapsed
7800
7801 \begin_layout Plain Layout
7802 Theorems (AMS)
7803 \end_layout
7804
7805 \end_inset
7806
7807  module, and the others mentioned, with other classes, such as 
7808 \begin_inset Flex CharStyle:Code
7809 status collapsed
7810
7811 \begin_layout Plain Layout
7812 article
7813 \end_layout
7814
7815 \end_inset
7816
7817
7818 \begin_inset Flex CharStyle:Code
7819 status collapsed
7820
7821 \begin_layout Plain Layout
7822 report
7823 \end_layout
7824
7825 \end_inset
7826
7827
7828 \begin_inset Flex CharStyle:Code
7829 status collapsed
7830
7831 \begin_layout Plain Layout
7832 book (KOMA-script)
7833 \end_layout
7834
7835 \end_inset
7836
7837 , and so forth.
7838 \end_layout
7839
7840 \begin_layout Subsection
7841 What these layouts provide
7842 \end_layout
7843
7844 \begin_layout Standard
7845 There is a long list of included environments provided by these layouts.
7846  In AMS-LaTeX, there is, in fact, an opportunity to define an unlimited
7847  variety of `theorem' environments.
7848  However, the AMS recommends the environments that are available in LyX.
7849  
7850 \end_layout
7851
7852 \begin_layout Standard
7853 The following environments—as well as the standard environments, such as
7854  
7855 \begin_inset Flex CharStyle:Noun
7856 status collapsed
7857
7858 \begin_layout Plain Layout
7859 section
7860 \end_layout
7861
7862 \end_inset
7863
7864
7865 \begin_inset Flex CharStyle:Noun
7866 status collapsed
7867
7868 \begin_layout Plain Layout
7869 bibliography
7870 \end_layout
7871
7872 \end_inset
7873
7874
7875 \begin_inset Flex CharStyle:Noun
7876 status collapsed
7877
7878 \begin_layout Plain Layout
7879 title
7880 \end_layout
7881
7882 \end_inset
7883
7884
7885 \begin_inset Flex CharStyle:Noun
7886 status collapsed
7887
7888 \begin_layout Plain Layout
7889 author
7890 \end_layout
7891
7892 \end_inset
7893
7894 , and 
7895 \begin_inset Flex CharStyle:Noun
7896 status collapsed
7897
7898 \begin_layout Plain Layout
7899 date
7900 \end_layout
7901
7902 \end_inset
7903
7904 —are provided by 
7905 \begin_inset Flex CharStyle:Code
7906 status collapsed
7907
7908 \begin_layout Plain Layout
7909 article (AMS)
7910 \end_layout
7911
7912 \end_inset
7913
7914  and 
7915 \begin_inset Flex CharStyle:Code
7916 status collapsed
7917
7918 \begin_layout Plain Layout
7919 book (AMS)
7920 \end_layout
7921
7922 \end_inset
7923
7924 :
7925 \end_layout
7926
7927 \begin_layout Description
7928 Address This should be the author's permanent address.
7929 \end_layout
7930
7931 \begin_layout Description
7932 Current
7933 \begin_inset space ~
7934 \end_inset
7935
7936 Address This should be the author's temporary address at the time of submission,
7937  if different from the Address.
7938 \end_layout
7939
7940 \begin_layout Description
7941 Email Author's e-mail address
7942 \end_layout
7943
7944 \begin_layout Description
7945 URL Author's Web address, if desired.
7946 \end_layout
7947
7948 \begin_layout Description
7949 Keywords Key words or phrases used to identify specific topics discussed
7950  in the paper.
7951 \end_layout
7952
7953 \begin_layout Description
7954 Subjectclass These refer to the AMS Subject Classifications, published and
7955  described in 
7956 \emph on
7957 Mathematical Reviews
7958 \emph default
7959 .
7960  These are also available online at the AMS cites listed above.
7961 \end_layout
7962
7963 \begin_layout Description
7964 Thanks
7965 \end_layout
7966
7967 \begin_layout Description
7968 Dedicatory
7969 \end_layout
7970
7971 \begin_layout Description
7972 Translator
7973 \end_layout
7974
7975 \begin_layout Standard
7976 The following environments are provided by both the 
7977 \begin_inset Flex CharStyle:Code
7978 status collapsed
7979
7980 \begin_layout Plain Layout
7981 Theorems
7982 \end_layout
7983
7984 \end_inset
7985
7986  and 
7987 \begin_inset Flex CharStyle:Code
7988 status collapsed
7989
7990 \begin_layout Plain Layout
7991 Theorems (AMS)
7992 \end_layout
7993
7994 \end_inset
7995
7996  modules, in the latter case in both starred (unnumbered) and unstarred
7997  (numbered) versions.
7998  These same environments are provided only in the starred versions by the
7999  
8000 \begin_inset Flex CharStyle:Code
8001 status collapsed
8002
8003 \begin_layout Plain Layout
8004 Theorems (Starred)
8005 \end_layout
8006
8007 \end_inset
8008
8009  module:
8010 \end_layout
8011
8012 \begin_layout Theorem
8013 This is typically used for the statements of major results.
8014  
8015 \end_layout
8016
8017 \begin_layout Corollary*
8018 This is used for statements which follow fairly directly from previous statement
8019 s.
8020  Again, these can be major results.
8021  
8022 \end_layout
8023
8024 \begin_layout Lemma
8025 These are smaller results needed to prove other statements.
8026 \end_layout
8027
8028 \begin_layout Proposition
8029 These are less major results which (hopefully) add to the general theory
8030  being discussed.
8031 \end_layout
8032
8033 \begin_layout Conjecture
8034 These are statements provided without justification, which the author does
8035  not know how to prove, but which seem to be true (to the author, at least).
8036 \end_layout
8037
8038 \begin_layout Definition*
8039 Guess what this is for.
8040  The font is different for this environment than for the previous ones.
8041  
8042 \end_layout
8043
8044 \begin_layout Example*
8045 Used for examples illustrating proven results.
8046 \end_layout
8047
8048 \begin_layout Problem
8049 It's not really known what this is for.
8050  You should figure it out.
8051 \end_layout
8052
8053 \begin_layout Exercise*
8054 Write a description for this one.
8055 \end_layout
8056
8057 \begin_layout Remark
8058 This environment is also a type of theorem, usually a lesser sort of observation.
8059 \end_layout
8060
8061 \begin_layout Claim*
8062 Often used in the course of giving a proof of a larger result.
8063 \end_layout
8064
8065 \begin_layout Case
8066 Generally, these are used to break up long arguments, using specific instances
8067  of some condition.
8068  
8069 \end_layout
8070
8071 \begin_layout Case
8072 The numbering scheme for cases is on its own, not together with other numbered
8073  statements.
8074  
8075 \end_layout
8076
8077 \begin_layout Proof
8078 At the end of this environment, a QED symbol (usually a square, but it can
8079  vary with different styles) is placed.
8080  If you want to have other environments within this one—for example, Case
8081  environments—and have the QED symbol appear only after them, then the other
8082  environments need to be nested within the proof environment.
8083  See the section 
8084 \emph on
8085 Nesting Environments
8086 \emph default
8087  of the 
8088 \emph on
8089 User's Guide
8090 \emph default
8091  for information on nesting.
8092 \end_layout
8093
8094 \begin_layout Standard
8095 And these environments are provided by 
8096 \begin_inset Flex CharStyle:Code
8097 status collapsed
8098
8099 \begin_layout Plain Layout
8100 Theorems (AMS-Extended)
8101 \end_layout
8102
8103 \end_inset
8104
8105 :
8106 \end_layout
8107
8108 \begin_layout Criterion*
8109 A required condition.
8110 \end_layout
8111
8112 \begin_layout Algorithm*
8113 A general procedure to be used.
8114 \end_layout
8115
8116 \begin_layout Axiom*
8117 This is a property or statement taken as true within the system being discussed.
8118 \end_layout
8119
8120 \begin_layout Condition*
8121 Sometimes used to state a condition assumed within the present context of
8122  discussion.
8123 \end_layout
8124
8125 \begin_layout Note*
8126 Similar to a Remark.
8127 \end_layout
8128
8129 \begin_layout Notation*
8130 Used for the explanation of, yes, notation.
8131 \end_layout
8132
8133 \begin_layout Summary
8134 Do we really need to tell you? 
8135 \end_layout
8136
8137 \begin_layout Acknowledgement*
8138 Acknowledgement.
8139 \end_layout
8140
8141 \begin_layout Conclusion*
8142 Sometimes used at the end of a long train of argument.
8143 \end_layout
8144
8145 \begin_layout Fact
8146 Used in a way similar to Proposition, though perhaps lower on the scale.
8147 \end_layout
8148
8149 \begin_layout Standard
8150 In addition, the AMS classes automatically provide the AMS LaTeX and AMS
8151  fonts packages.
8152  They need to be available on your system in order to use these environments.
8153 \end_layout
8154
8155 \begin_layout Section
8156 AGU journals (
8157 \family sans
8158 aguplus
8159 \family default
8160 )
8161 \end_layout
8162
8163 \begin_layout Standard
8164 by 
8165 \shape smallcaps
8166 Martin Vermeer
8167 \end_layout
8168
8169 \begin_layout Subsection
8170 Description
8171 \end_layout
8172
8173 \begin_layout Standard
8174 These are the layout files for some of the journals of the American Geophysical
8175  Society.
8176  It is assumed that you have both the AGU's own class files and AGUplus
8177  installed (everything to be found at
8178 \begin_inset Flex URL
8179 status collapsed
8180
8181 \begin_layout Plain Layout
8182
8183 ftp://ftp.agu.org/journals/latex/journals
8184 \end_layout
8185
8186 \end_inset
8187
8188 ).
8189 \end_layout
8190
8191 \begin_layout Subsection
8192 New styles
8193 \end_layout
8194
8195 \begin_layout Standard
8196 Redefined are 
8197 \family sans
8198 Paragraph
8199 \family default
8200
8201 \family sans
8202 Paragraph*
8203 \family default
8204 .
8205  They are still called this in the LyX GUI, though their LaTeX equivalents
8206  in the AGU classes are 
8207 \family sans
8208 Subsubsubsection
8209 \family default
8210  and 
8211 \family sans
8212 Subsubsubsection*
8213 \family default
8214 .
8215 \end_layout
8216
8217 \begin_layout Standard
8218 Newly defined styles are 
8219 \family sans
8220 Left_Header
8221 \family default
8222
8223 \family sans
8224 Right_Header
8225 \family default
8226
8227 \family sans
8228 Received
8229 \family default
8230
8231 \family sans
8232 Revised
8233 \family default
8234
8235 \family sans
8236 Accepted
8237 \family default
8238
8239 \family sans
8240 CCC
8241 \family default
8242
8243 \family sans
8244 PaperId
8245 \family default
8246
8247 \family sans
8248 AuthorAddr
8249 \family default
8250
8251 \family sans
8252 SlugComment
8253 \family default
8254 .
8255  These are mostly manuscript attributes and defined in the AGU class documentati
8256 on.
8257 \end_layout
8258
8259 \begin_layout Standard
8260 I suspect this is still badly incomplete.
8261 \end_layout
8262
8263 \begin_layout Subsection
8264 New floats
8265 \end_layout
8266
8267 \begin_layout Standard
8268
8269 \family sans
8270 Planotable
8271 \family default
8272  and 
8273 \family sans
8274 Plate
8275 \family default
8276 .
8277  We also have a new 
8278 \family sans
8279 Table_Caption
8280 \family default
8281 .
8282 \end_layout
8283
8284 \begin_layout Subsection
8285 Supported journals
8286 \end_layout
8287
8288 \begin_layout Itemize
8289
8290 \emph on
8291 Journal of Geophysical Research
8292 \emph default
8293
8294 \family typewriter
8295 jgrga.layout
8296 \family default
8297  â€” Martin Vermeer
8298 \end_layout
8299
8300 \begin_layout Standard
8301 Add your own, it isn't so hard! Look at the 
8302 \family typewriter
8303 jgrga.layout
8304 \family default
8305  example and 
8306 \family typewriter
8307 aguplus.inc
8308 \family default
8309 .
8310 \end_layout
8311
8312 \begin_layout Subsection
8313 Bugs and things to remember
8314 \end_layout
8315
8316 \begin_layout Standard
8317 In order to use the new layouts, you must remember to do the following for
8318  a new document:
8319 \end_layout
8320
8321 \begin_layout Enumerate
8322
8323 \emph on
8324 Turn off babel
8325 \emph default
8326 .
8327  This can be done in the 
8328 \family sans
8329 Layout\SpecialChar \menuseparator
8330 Document
8331 \family default
8332  or 
8333 \family sans
8334 Document\SpecialChar \menuseparator
8335 Settings
8336 \family default
8337  menu item.
8338  (AGU articles are always in English, right? So 
8339 \emph on
8340 don't
8341 \emph default
8342  choose a language.)
8343 \end_layout
8344
8345 \begin_layout Enumerate
8346 Enter 
8347 \family typewriter
8348 jgrga
8349 \family default
8350  into the document's 
8351 \family sans
8352 Extra Options
8353 \family default
8354  field.
8355  (Yes, this is a bug.)
8356 \end_layout
8357
8358 \begin_layout Enumerate
8359 Make sure you use the 
8360 \family typewriter
8361 agu.bst
8362 \family default
8363  bibliography style, by entering 
8364 \family sans
8365 agu
8366 \family default
8367  into the second field of the BibTeX inset.
8368  None of the standard styles will do.
8369 \end_layout
8370
8371 \begin_layout Section
8372 Broadway
8373 \end_layout
8374
8375 \begin_layout Standard
8376 by 
8377 \shape smallcaps
8378 Garst Reese
8379 \end_layout
8380
8381 \begin_layout Subsection
8382 Introduction
8383 \end_layout
8384
8385 \begin_layout Standard
8386 Broadway is for writing plays.
8387  The format is more decorative than Hollywood, and much less standardized.
8388  This format should be suitable for workshops.
8389 \end_layout
8390
8391 \begin_layout Subsection
8392 Special problems
8393 \end_layout
8394
8395 \begin_layout Standard
8396 The same as in Hollywood.
8397 \end_layout
8398
8399 \begin_layout Subsection
8400 Special features
8401 \end_layout
8402
8403 \begin_layout Standard
8404 Insert the 
8405 \family sans
8406 Speaker
8407 \family default
8408  names as labels then cross-reference the label to insert the name.
8409  The cross-reference dialog will show the current cast of characters.
8410 \end_layout
8411
8412 \begin_layout Subsection
8413 Paper size and Margins
8414 \end_layout
8415
8416 \begin_layout Standard
8417 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
8418 \end_layout
8419
8420 \begin_layout Subsection
8421 Environments
8422 \end_layout
8423
8424 \begin_layout Standard
8425 The following environments are available.
8426  You can use broadway.bind to get the bind keys shown at the right.
8427 \end_layout
8428
8429 \begin_layout Itemize
8430
8431 \family sans
8432 Standard
8433 \begin_inset Newline newline
8434 \end_inset
8435
8436
8437 \family default
8438 You should not have to use this, but it is here for anything that does not
8439  fit otherwise.
8440 \end_layout
8441
8442 \begin_layout Itemize
8443
8444 \family sans
8445 Narrative
8446 \begin_inset space \hfill{}
8447 \end_inset
8448
8449 M-z n
8450 \begin_inset Newline newline
8451 \end_inset
8452
8453
8454 \family default
8455 Used to describe stage setting and the action.
8456  First use of speaker names in all CAPs.
8457 \end_layout
8458
8459 \begin_layout Itemize
8460
8461 \family sans
8462 ACT
8463 \begin_inset space \hfill{}
8464 \end_inset
8465
8466 M-z a
8467 \begin_inset Newline newline
8468 \end_inset
8469
8470
8471 \family default
8472 Automatically numbered.
8473  On screen it will be arabic, but will print as Roman.
8474 \end_layout
8475
8476 \begin_layout Itemize
8477
8478 \family sans
8479 ACT*
8480 \begin_inset space \hfill{}
8481 \end_inset
8482
8483 M-z S at
8484 \begin_inset Newline newline
8485 \end_inset
8486
8487
8488 \family default
8489 Subtitle for 
8490 \family sans
8491 ACT.
8492
8493 \family default
8494  It is just centered text.
8495 \end_layout
8496
8497 \begin_layout Itemize
8498
8499 \family sans
8500 SCENE
8501 \begin_inset space \hfill{}
8502 \end_inset
8503
8504 M-z S-S
8505 \begin_inset Newline newline
8506 \end_inset
8507
8508
8509 \family default
8510 Not automatically numbered.
8511  You supply the number.
8512  This is because I couldn't figure out how.
8513 \end_layout
8514
8515 \begin_layout Itemize
8516
8517 \family sans
8518 AT_RISE:
8519 \begin_inset space \hfill{}
8520 \end_inset
8521
8522 M-z S-R
8523 \begin_inset Newline newline
8524 \end_inset
8525
8526
8527 \family default
8528 A special case of Narrative to describe the setting and action as the curtain
8529  rises.
8530 \end_layout
8531
8532 \begin_layout Itemize
8533
8534 \family sans
8535 Speaker
8536 \begin_inset space \hfill{}
8537 \end_inset
8538
8539 M-z s
8540 \begin_inset Newline newline
8541 \end_inset
8542
8543
8544 \family default
8545 The speaker's (actor's) title, centered in all CAPS.
8546 \end_layout
8547
8548 \begin_layout Itemize
8549
8550 \family sans
8551 Parenthetical
8552 \begin_inset space \hfill{}
8553 \end_inset
8554
8555 M-z p
8556 \begin_inset Newline newline
8557 \end_inset
8558
8559
8560 \family default
8561 Instructions to the speaker.
8562  The parentheses are automatically inserted.
8563  The ( will appear on screen, but both will be in the printed play.
8564  This environment is only used within 
8565 \family sans
8566 Dialogue
8567 \family default
8568 .
8569 \end_layout
8570
8571 \begin_layout Itemize
8572
8573 \family sans
8574 Dialogue
8575 \begin_inset space \hfill{}
8576 \end_inset
8577
8578 M-z d
8579 \begin_inset Newline newline
8580 \end_inset
8581
8582
8583 \family default
8584 What the Speaker says.
8585 \end_layout
8586
8587 \begin_layout Itemize
8588
8589 \family sans
8590 CURTAIN
8591 \begin_inset space \hfill{}
8592 \end_inset
8593
8594 M-z S-C
8595 \begin_inset Newline newline
8596 \end_inset
8597
8598
8599 \family default
8600 The curtain comes down.
8601 \end_layout
8602
8603 \begin_layout Itemize
8604
8605 \family sans
8606 Title
8607 \begin_inset space \hfill{}
8608 \end_inset
8609
8610 M-z S-T
8611 \end_layout
8612
8613 \begin_layout Itemize
8614
8615 \family sans
8616 Author
8617 \begin_inset space \hfill{}
8618 \end_inset
8619
8620 M-z S-A
8621 \end_layout
8622
8623 \begin_layout Itemize
8624
8625 \family sans
8626 Right_Address
8627 \begin_inset space \hfill{}
8628 \end_inset
8629
8630 M-z r
8631 \end_layout
8632
8633 \begin_layout Standard
8634 Hello there.
8635 \end_layout
8636
8637 \begin_layout Section
8638 Dinbrief
8639 \end_layout
8640
8641 \begin_layout Standard
8642 The document class 
8643 \family sans
8644 dinbrief
8645 \family default
8646  can be used to type letters according to German conventions.
8647  A template file is included in 
8648 \family typewriter
8649 .../lyx/share/templates
8650 \family default
8651  for you to use as a starting point.
8652 \end_layout
8653
8654 \begin_layout Section
8655 EGS journals (
8656 \family sans
8657 egs
8658 \family default
8659 )
8660 \end_layout
8661
8662 \begin_layout Standard
8663 by 
8664 \shape smallcaps
8665 Martin Vermeer
8666 \end_layout
8667
8668 \begin_layout Subsection
8669 Description
8670 \end_layout
8671
8672 \begin_layout Standard
8673 This is the layout file for the European Geophysical Society journals.
8674  The needed 
8675 \family typewriter
8676 egs.cls
8677 \family default
8678  can be downloaded from the web site of the EGS under 
8679 \begin_inset Flex URL
8680 status collapsed
8681
8682 \begin_layout Plain Layout
8683
8684 www.copernicus.org
8685 \end_layout
8686
8687 \end_inset
8688
8689 .
8690 \end_layout
8691
8692 \begin_layout Subsection
8693 New styles
8694 \end_layout
8695
8696 \begin_layout Standard
8697
8698 \family sans
8699 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
8700  Accepted
8701 \family default
8702
8703 \family sans
8704 Offsets
8705 \family default
8706 .
8707  The current layout file is unfortunately very unmodular and would benefit
8708  from using the various 
8709 \family typewriter
8710 std*.inc
8711 \family default
8712  file inclusions.
8713 \end_layout
8714
8715 \begin_layout Section
8716 Elsevier Journals
8717 \end_layout
8718
8719 \begin_layout Standard
8720 By 
8721 \noun on
8722 Rod Pinna
8723 \end_layout
8724
8725 \begin_layout Standard
8726 Elsevier Science Publishers B.V.
8727  provides a standard LaTeX document class (
8728 \family typewriter
8729 elsart.cls
8730 \family default
8731 ) for submitting articles to their various journals.
8732  The style file can be downloaded directly from their web site: 
8733 \begin_inset Flex URL
8734 status collapsed
8735
8736 \begin_layout Plain Layout
8737
8738 http://authors.elsevier.com/
8739 \end_layout
8740
8741 \end_inset
8742
8743 .
8744  Instructions are supplied along with the class file, which details the
8745  requirements of the publishers.
8746  LyX includes package that allows for the use of this class, by a layout
8747  and a template file.
8748  Installation of the class file is the same as for any other LaTeX package;
8749  instructions are provided in the Elsevier documentation.
8750 \end_layout
8751
8752 \begin_layout Standard
8753 To make use of 
8754 \family typewriter
8755 elsart.cls
8756 \family default
8757 , a file 
8758 \family typewriter
8759 elsart.layout
8760 \family default
8761  is supplied.
8762  As the Elsevier class file is based mainly on the standard article class,
8763  most of the normal functionality is provided.
8764  The Elsevier class defines a number of mathematical environments, which
8765  are similar to the AMS environments.
8766  These commands are all described in the Elsevier documentation, and are
8767  available in LyX.
8768 \end_layout
8769
8770 \begin_layout Standard
8771 The easiest way to use the Elsevier style is to base documents on the included
8772  template file.
8773  It is best not to use options such as fancy headings or the geometry package,
8774  as elements such as these are defined by Elsevier in their style file.
8775  Ideally, no extra packages except those mentioned in the Elsevier documentation
8776  should be used.
8777  Essentially, Elsevier require as 
8778 \begin_inset Quotes eld
8779 \end_inset
8780
8781 clean
8782 \begin_inset Quotes erd
8783 \end_inset
8784
8785  a LaTeX file as possible, as their intention is to take the supplied file
8786  and replace the class file with one for the particular journal to which
8787  the paper has been submitted.
8788  This also means that not too much time should be spent on the formating
8789  of the document.
8790  When it comes to be published, this will change anyway.
8791  The rest of the usage for this layout is substantially the same as for
8792  the normal article class.
8793  For details of what Elsevier do and don't allow, refer to their documentation.
8794 \end_layout
8795
8796 \begin_layout Section
8797 Foils [aka 
8798 \family sans
8799 FoilTeX
8800 \family default
8801 ]
8802 \begin_inset CommandInset label
8803 LatexCommand label
8804 name "sec:foiltex"
8805
8806 \end_inset
8807
8808
8809 \end_layout
8810
8811 \begin_layout Standard
8812 by 
8813 \noun on
8814 Allan Rae
8815 \end_layout
8816
8817 \begin_layout Subsection
8818 Introduction
8819 \end_layout
8820
8821 \begin_layout Standard
8822 This section describes how to use LyX to make slides for overhead projectors.
8823  There are two document classes that can do this: the default slides class
8824  and the 
8825 \family sans
8826 FoilTeX
8827 \family default
8828  slides class.
8829  This section documents the latter.
8830 \end_layout
8831
8832 \begin_layout Standard
8833 I'm going to say this again, nice and clear, so that there's no misunderstanding
8834 :
8835 \end_layout
8836
8837 \begin_layout Standard
8838 \begin_inset VSpace bigskip
8839 \end_inset
8840
8841
8842 \end_layout
8843
8844 \begin_layout Standard
8845 \align center
8846
8847 \size large
8848 This section documents the class 
8849 \begin_inset Quotes eld
8850 \end_inset
8851
8852
8853 \family sans
8854 slides (FoilTeX)
8855 \family default
8856
8857 \begin_inset Quotes erd
8858 \end_inset
8859
8860  
8861 \emph on
8862 only.
8863 \end_layout
8864
8865 \begin_layout Standard
8866 \begin_inset VSpace bigskip
8867 \end_inset
8868
8869
8870 \end_layout
8871
8872 \begin_layout Standard
8873 If you're looking for the documentation for 
8874 \begin_inset Quotes eld
8875 \end_inset
8876
8877
8878 \family sans
8879 slides (default)
8880 \family default
8881
8882 \begin_inset Quotes erd
8883 \end_inset
8884
8885 , check out section
8886 \begin_inset space ~
8887 \end_inset
8888
8889
8890 \begin_inset CommandInset ref
8891 LatexCommand ref
8892 reference "sec:slitex"
8893
8894 \end_inset
8895
8896 .
8897  If your machine doesn't have the 
8898 \family sans
8899 foils
8900 \family default
8901  class [
8902 \begin_inset Quotes eld
8903 \end_inset
8904
8905
8906 \family sans
8907 slides (FoilTeX)
8908 \family default
8909
8910 \begin_inset Quotes erd
8911 \end_inset
8912
8913 ] installed, you'll probably have to use the default 
8914 \family sans
8915 slides
8916 \family default
8917  class, which isn't quite as good as 
8918 \family sans
8919 foils.
8920 \end_layout
8921
8922 \begin_layout Standard
8923 The 
8924 \family sans
8925 foils
8926 \family default
8927  class is designed for use with version 2.1 of the 
8928 \family sans
8929 foils.cls
8930 \family default
8931  LaTeX class file which is now an integral part of LaTeX2e.
8932 \end_layout
8933
8934 \begin_layout Subsection
8935 Getting Started
8936 \end_layout
8937
8938 \begin_layout Standard
8939 Obviously, to use this document class, you need to select 
8940 \begin_inset Quotes eld
8941 \end_inset
8942
8943
8944 \family sans
8945 slides (FoilTeX)
8946 \family default
8947
8948 \begin_inset Quotes erd
8949 \end_inset
8950
8951  from the 
8952 \family sans
8953 Class
8954 \family default
8955  entry in the 
8956 \family sans
8957 Document
8958 \begin_inset space ~
8959 \end_inset
8960
8961 Layout
8962 \family default
8963  dialog.
8964  There are some settings in the 
8965 \family sans
8966 Document
8967 \begin_inset space ~
8968 \end_inset
8969
8970 Layout
8971 \family default
8972  dialog that you should know about that are specific to this class:
8973 \end_layout
8974
8975 \begin_layout Itemize
8976 Don't change the options 
8977 \family sans
8978 Sides
8979 \family default
8980  and 
8981 \family sans
8982 Columns
8983 \family default
8984  on the 
8985 \family sans
8986 Document
8987 \begin_inset space ~
8988 \end_inset
8989
8990 Layout
8991 \family default
8992  dialog.
8993  They're ignored by the 
8994 \family sans
8995 foils
8996 \family default
8997  class.
8998 \end_layout
8999
9000 \begin_layout Itemize
9001 The default font size is 20
9002 \begin_inset space \thinspace{}
9003 \end_inset
9004
9005 pt with the other options being 17
9006 \begin_inset space \thinspace{}
9007 \end_inset
9008
9009 pt, 25
9010 \begin_inset space \thinspace{}
9011 \end_inset
9012
9013 pt and 30
9014 \begin_inset space \thinspace{}
9015 \end_inset
9016
9017 pt.
9018 \end_layout
9019
9020 \begin_layout Itemize
9021 The default font is 
9022 \family sans
9023 sans
9024 \family default
9025  
9026 \family sans
9027 serif
9028 \family default
9029  but all math equations are still typeset in the usual roman font.
9030 \end_layout
9031
9032 \begin_layout Itemize
9033
9034 \family sans
9035 FoilTeX
9036 \family default
9037  supports A4 and Letter paper sizes as well as a special size for working
9038  with 35
9039 \begin_inset space \thinspace{}
9040 \end_inset
9041
9042 mm slides.
9043  It doesn't support A5, B5, legal or executive paper sizes.
9044 \end_layout
9045
9046 \begin_layout Itemize
9047 Don't bother changing the 
9048 \family sans
9049 Float Placement
9050 \family default
9051  settings because they are ignored anyway.
9052  All floats appear where they are defined in the text.
9053 \end_layout
9054
9055 \begin_layout Itemize
9056 The 
9057 \family sans
9058 Pagestyle
9059 \family default
9060  setting behaves a bit differently for this class.
9061  
9062 \family sans
9063 FoilTeX
9064 \family default
9065  provides extensive footer and header capabilities including a user-defined
9066  logo.
9067  See section
9068 \begin_inset space ~
9069 \end_inset
9070
9071
9072 \begin_inset CommandInset ref
9073 LatexCommand ref
9074 reference "sec:foilfoot"
9075
9076 \end_inset
9077
9078  for more details.
9079  The title page is treated differently to all other pages in the document
9080  and is 
9081 \emph on
9082 always
9083 \emph default
9084  unnumbered and 
9085 \emph on
9086 always
9087 \emph default
9088  has the logo centered at the bottom of the page (if one is defined).
9089  The possible page style choices and what they do are as follows:
9090 \end_layout
9091
9092 \begin_deeper
9093 \begin_layout Labeling
9094 \labelwidthstring MMMMMMM
9095
9096 \family sans
9097 \series bold
9098 empty
9099 \family default
9100 \series default
9101  The final output contains no page numbers, or other headers or footers
9102  (except footnotes of course).
9103  
9104 \end_layout
9105
9106 \begin_layout Labeling
9107 \labelwidthstring MMMMMMM
9108
9109 \family sans
9110 \series bold
9111 plain
9112 \family default
9113 \series default
9114  The final output contains page numbers centered at the bottom of the page.
9115  No other headings or footers (other than footnotes).
9116 \end_layout
9117
9118 \begin_layout Labeling
9119 \labelwidthstring MMMMMMM
9120
9121 \series bold
9122 foilheadings
9123 \series default
9124  Page numbers in lower right corner.
9125  Additional headers and footers are also shown.
9126  This is also the default.
9127 \end_layout
9128
9129 \begin_layout Labeling
9130 \labelwidthstring MMMMMMM
9131
9132 \series bold
9133 fancy
9134 \series default
9135  Gives you access to the 
9136 \family sans
9137 fancyheadings
9138 \family default
9139  package although its use with 
9140 \family sans
9141 FoilTeX
9142 \family default
9143  is discouraged by the writer of the 
9144 \family sans
9145 FoilTeX
9146 \family default
9147  package because of some potential page layout clashes.
9148 \end_layout
9149
9150 \end_deeper
9151 \begin_layout Subsubsection
9152 Extra Options
9153 \end_layout
9154
9155 \begin_layout Standard
9156 The following options may be used in the extra class options in the 
9157 \family sans
9158 Document\SpecialChar \menuseparator
9159 Settings
9160 \family default
9161  dialog.
9162 \end_layout
9163
9164 \begin_layout Labeling
9165 \labelwidthstring MMMMMMx
9166
9167 \series bold
9168 35mmSlide
9169 \series default
9170  This sets up the page layout for 7.33
9171 \begin_inset space \thinspace{}
9172 \end_inset
9173
9174 in by 11
9175 \begin_inset space \thinspace{}
9176 \end_inset
9177
9178 in paper, which is about the same aspect ratio as a 35
9179 \begin_inset space \thinspace{}
9180 \end_inset
9181
9182 mm slide, making it a bit easier to work with this medium.
9183 \end_layout
9184
9185 \begin_layout Labeling
9186 \labelwidthstring MMMMMMx
9187
9188 \series bold
9189 headrule
9190 \series default
9191  Places a rule across the page below the header on every page except the
9192  title page.
9193 \end_layout
9194
9195 \begin_layout Labeling
9196 \labelwidthstring MMMMMMx
9197
9198 \series bold
9199 footrule
9200 \series default
9201  Places a rule across the page above the footer on every page except the
9202  title page.
9203 \end_layout
9204
9205 \begin_layout Labeling
9206 \labelwidthstring MMMMMMx
9207
9208 \series bold
9209 dvips
9210 \series default
9211  This is automatically set each time you create a new 
9212 \family sans
9213 foils
9214 \family default
9215  document.
9216  This option tells 
9217 \family sans
9218 FoilTeX
9219 \family default
9220  to use the dvips driver to rotate those pages that are set as landscape
9221  foils.
9222 \end_layout
9223
9224 \begin_layout Labeling
9225 \labelwidthstring MMMMMMx
9226
9227 \series bold
9228 landscape
9229 \series default
9230  Simply changes the page dimensions to those of a landscape page but doesn't
9231  do any rotation.
9232  Thus if you use this option you need to use an external program to rotate
9233  each page or feed your paper through your printer as landscape.
9234  Note that this option effectively reverses the roles of the 
9235 \family sans
9236 Foilhead
9237 \family default
9238  and 
9239 \family sans
9240 Rotatefoilhead
9241 \family default
9242  environments (don't worry these are described in the next section).
9243 \end_layout
9244
9245 \begin_layout Labeling
9246 \labelwidthstring MMMMMMx
9247
9248 \series bold
9249 leqno
9250 \series default
9251  Equation numbers on the left.
9252 \end_layout
9253
9254 \begin_layout Labeling
9255 \labelwidthstring MMMMMMx
9256
9257 \series bold
9258 fleqn
9259 \series default
9260  Flush-left equations.
9261 \end_layout
9262
9263 \begin_layout Subsection
9264 Supported Environments
9265 \end_layout
9266
9267 \begin_layout Standard
9268 Most of the environments commonly supported in other classes are also supported
9269  by the 
9270 \family sans
9271 foils
9272 \family default
9273  class.
9274  There are several additional environments provided by 
9275 \family sans
9276 FoilTeX
9277 \family default
9278  as well as a couple added by LyX.
9279  The following environments are shared with other classes:
9280 \end_layout
9281
9282 \begin_layout Standard
9283 \begin_inset ERT
9284 status open
9285
9286 \begin_layout Plain Layout
9287
9288
9289 \backslash
9290 begin{multicols}{2}
9291 \end_layout
9292
9293 \end_inset
9294
9295
9296 \end_layout
9297
9298 \begin_layout Itemize
9299
9300 \family sans
9301 Standard
9302 \end_layout
9303
9304 \begin_layout Itemize
9305
9306 \family sans
9307 Itemize
9308 \end_layout
9309
9310 \begin_layout Itemize
9311
9312 \family sans
9313 Enumerate
9314 \end_layout
9315
9316 \begin_layout Itemize
9317
9318 \family sans
9319 Description
9320 \end_layout
9321
9322 \begin_layout Itemize
9323
9324 \family sans
9325 List
9326 \end_layout
9327
9328 \begin_layout Itemize
9329
9330 \family sans
9331 LyX-Code
9332 \end_layout
9333
9334 \begin_layout Itemize
9335
9336 \family sans
9337 Verse
9338 \end_layout
9339
9340 \begin_layout Itemize
9341
9342 \family sans
9343 Quote
9344 \end_layout
9345
9346 \begin_layout Itemize
9347
9348 \family sans
9349 Quotation
9350 \end_layout
9351
9352 \begin_layout Itemize
9353
9354 \family sans
9355 Title
9356 \end_layout
9357
9358 \begin_layout Itemize
9359
9360 \family sans
9361 Author
9362 \end_layout
9363
9364 \begin_layout Itemize
9365
9366 \family sans
9367 Date
9368 \end_layout
9369
9370 \begin_layout Itemize
9371
9372 \family sans
9373 Abstract
9374 \end_layout
9375
9376 \begin_layout Itemize
9377
9378 \family sans
9379 Bibliography
9380 \end_layout
9381
9382 \begin_layout Itemize
9383
9384 \family sans
9385 Address
9386 \end_layout
9387
9388 \begin_layout Itemize
9389
9390 \family sans
9391 RightAddress
9392 \end_layout
9393
9394 \begin_layout Itemize
9395
9396 \family sans
9397 Caption
9398 \end_layout
9399
9400 \begin_layout Itemize
9401
9402 \family sans
9403 Comment
9404 \end_layout
9405
9406 \begin_layout Standard
9407 \begin_inset ERT
9408 status open
9409
9410 \begin_layout Plain Layout
9411
9412
9413 \backslash
9414 end{multicols}
9415 \end_layout
9416
9417 \end_inset
9418
9419
9420 \end_layout
9421
9422 \begin_layout Standard
9423 That is, all the major environments apart from the sectioning environments.
9424  Since foils are essentially self-contained sections, with a title and body,
9425  
9426 \family sans
9427 FoilTeX
9428 \family default
9429  provides specific commands for starting new foils and these are:
9430 \end_layout
9431
9432 \begin_layout Itemize
9433
9434 \family sans
9435 Foilhead
9436 \end_layout
9437
9438 \begin_layout Itemize
9439
9440 \family sans
9441 Rotatefoilhead
9442 \end_layout
9443
9444 \begin_layout Standard
9445 LyX also provides slightly modified versions of these two environments called:
9446 \end_layout
9447
9448 \begin_layout Itemize
9449
9450 \family sans
9451 ShortFoilhead
9452 \end_layout
9453
9454 \begin_layout Itemize
9455
9456 \family sans
9457 ShortRotatefoilhead
9458 \end_layout
9459
9460 \begin_layout Standard
9461 and the differences will be explained in the next section.
9462 \end_layout
9463
9464 \begin_layout Standard
9465 Since foils are often used in presenting ideas or new theorems and such
9466  
9467 \family sans
9468 FoilTeX
9469 \family default
9470  also provides a comprehensive box of goodies for presenting them:
9471 \end_layout
9472
9473 \begin_layout Standard
9474 \begin_inset ERT
9475 status open
9476
9477 \begin_layout Plain Layout
9478
9479
9480 \backslash
9481 begin{multicols}{2}
9482 \end_layout
9483
9484 \end_inset
9485
9486
9487 \end_layout
9488
9489 \begin_layout Itemize
9490
9491 \family sans
9492 Theorem
9493 \end_layout
9494
9495 \begin_layout Itemize
9496
9497 \family sans
9498 Lemma
9499 \end_layout
9500
9501 \begin_layout Itemize
9502
9503 \family sans
9504 Corollary
9505 \end_layout
9506
9507 \begin_layout Itemize
9508
9509 \family sans
9510 Proposition
9511 \end_layout
9512
9513 \begin_layout Itemize
9514
9515 \family sans
9516 Definition
9517 \end_layout
9518
9519 \begin_layout Itemize
9520
9521 \family sans
9522 Proof
9523 \end_layout
9524
9525 \begin_layout Itemize
9526
9527 \family sans
9528 Theorem*
9529 \end_layout
9530
9531 \begin_layout Itemize
9532
9533 \family sans
9534 Lemma*
9535 \end_layout
9536
9537 \begin_layout Itemize
9538
9539 \family sans
9540 Corollary*
9541 \end_layout
9542
9543 \begin_layout Itemize
9544
9545 \family sans
9546 Proposition*
9547 \end_layout
9548
9549 \begin_layout Itemize
9550
9551 \family sans
9552 Definition*
9553 \end_layout
9554
9555 \begin_layout Standard
9556 \begin_inset ERT
9557 status open
9558
9559 \begin_layout Plain Layout
9560
9561
9562 \backslash
9563 end{multicols}
9564 \end_layout
9565
9566 \end_inset
9567
9568
9569 \end_layout
9570
9571 \begin_layout Standard
9572 The starred versions are unnumbered while the unstarred versions are numbered.
9573  There are also two list environments added by LyX and these are:
9574 \end_layout
9575
9576 \begin_layout Itemize
9577
9578 \family sans
9579 TickList
9580 \end_layout
9581
9582 \begin_layout Itemize
9583
9584 \family sans
9585 CrossList
9586 \end_layout
9587
9588 \begin_layout Standard
9589
9590 \family sans
9591 FoilTeX
9592 \family default
9593  provides some powerful header and footer capabilities that are best set
9594  in the preamble although they may be set at any point in a document.
9595  If you want to change these settings in your document the best place to
9596  do so is at the very top of a foil, i.
9597 \begin_inset space \thinspace{}
9598 \end_inset
9599
9600 g.
9601 \emph on
9602
9603 \begin_inset space \space{}
9604 \end_inset
9605
9606
9607 \emph default
9608 straight after the foilhead.
9609 \end_layout
9610
9611 \begin_layout Standard
9612 For this purpose, the following command styles are provided [
9613 \shape smallcaps
9614 Martin Vermeer
9615 \shape default
9616 ]:
9617 \end_layout
9618
9619 \begin_layout Standard
9620 \begin_inset ERT
9621 status open
9622
9623 \begin_layout Plain Layout
9624
9625
9626 \backslash
9627 begin{multicols}{2}
9628 \end_layout
9629
9630 \end_inset
9631
9632
9633 \end_layout
9634
9635 \begin_layout Itemize
9636
9637 \family sans
9638 My
9639 \begin_inset space ~
9640 \end_inset
9641
9642 Logo
9643 \end_layout
9644
9645 \begin_layout Itemize
9646
9647 \family sans
9648 Restriction
9649 \end_layout
9650
9651 \begin_layout Itemize
9652
9653 \family sans
9654 Right
9655 \begin_inset space ~
9656 \end_inset
9657
9658 Footer
9659 \end_layout
9660
9661 \begin_layout Itemize
9662
9663 \family sans
9664 Right
9665 \begin_inset space ~
9666 \end_inset
9667
9668 Header
9669 \end_layout
9670
9671 \begin_layout Itemize
9672
9673 \family sans
9674 Left
9675 \begin_inset space ~
9676 \end_inset
9677
9678 Header
9679 \end_layout
9680
9681 \begin_deeper
9682 \begin_layout Standard
9683 \begin_inset space ~
9684 \end_inset
9685
9686
9687 \end_layout
9688
9689 \end_deeper
9690 \begin_layout Standard
9691 \begin_inset ERT
9692 status open
9693
9694 \begin_layout Plain Layout
9695
9696
9697 \backslash
9698 end{multicols}
9699 \end_layout
9700
9701 \end_inset
9702
9703
9704 \end_layout
9705
9706 \begin_layout Standard
9707 There are also a few commands provided by 
9708 \family sans
9709 FoilTeX
9710 \family default
9711  that aren't directly supported by LyX but I'll tell you what they do and
9712  how to use them in section
9713 \begin_inset space ~
9714 \end_inset
9715
9716
9717 \begin_inset CommandInset ref
9718 LatexCommand ref
9719 reference "sec:unsuppfoils"
9720
9721 \end_inset
9722
9723 .
9724 \end_layout
9725
9726 \begin_layout Subsection
9727 Building a Set of Foils
9728 \end_layout
9729
9730 \begin_layout Standard
9731 This section will give a simple introduction to using the different environments
9732  to build a set of foils.
9733  If you want to see an example set of foils, take a look at the 
9734 \family typewriter
9735 Foils.lyx
9736 \family default
9737  file you find in LyX's 
9738 \family typewriter
9739 examples
9740 \family default
9741  folder.
9742 \end_layout
9743
9744 \begin_layout Subsubsection
9745 Give It a Title Page
9746 \end_layout
9747
9748 \begin_layout Standard
9749 Unlike other classes that provide 
9750 \family sans
9751 Title
9752 \family default
9753
9754 \family sans
9755 Author
9756 \family default
9757
9758 \family sans
9759 Date
9760 \family default
9761  and 
9762 \family sans
9763 Abstract
9764 \family default
9765  environments, 
9766 \family sans
9767 foils
9768 \family default
9769  creates the title on a page of its own.
9770  If you leave out the 
9771 \family sans
9772 Date
9773 \family default
9774  environment LaTeX will substitute the current date (every time you regenerate
9775  the output).
9776 \end_layout
9777
9778 \begin_layout Subsubsection
9779 Start a New Foil
9780 \end_layout
9781
9782 \begin_layout Standard
9783 As I mentioned earlier, there are four ways of starting a new foil.
9784  For portrait foils you should use 
9785 \family sans
9786 Foilhead
9787 \family default
9788  or 
9789 \family sans
9790 ShortFoilhead.
9791
9792 \family default
9793  The difference between these two environments is the amount of space between
9794  the title of the foil (the foilhead) and the body of the foil.
9795 \end_layout
9796
9797 \begin_layout Standard
9798 Landscape foils are generated using the 
9799 \family sans
9800 Rotatefoilhead
9801 \family default
9802  and 
9803 \family sans
9804 ShortRotatefoilhead
9805 \family default
9806  environments.
9807  Again the only difference is the spacing between foilhead and body.
9808  Both of the short versions have 0.5 inches less separation between the foilhead
9809  and the body.
9810  
9811 \end_layout
9812
9813 \begin_layout Standard
9814 One problem with the support for landscape foils is the requirement that
9815  you have to use the 
9816 \family typewriter
9817 dvips
9818 \family default
9819  driver to generate the PostScript output otherwise the foils won't be rotated.
9820  It is possible to get landscape foils even if you haven't got the 
9821 \family typewriter
9822 dvips
9823 \family default
9824  driver provided you can feed your foils sideways through your printer ;-)
9825 \end_layout
9826
9827 \begin_layout Subsubsection
9828 Theorems, Lemmas, Proofs and more
9829 \end_layout
9830
9831 \begin_layout Standard
9832 Due to a small bug in LyX you can't have two of the same type of these environme
9833 nts directly following each other.
9834  They must be separated by something.
9835  If you try, you will just be extending the previous environment as if you
9836  had merged the two environments together.
9837  So, how do you get around this problem? The simplest option is to insert
9838  some text between the two environments or add a 
9839 \family sans
9840 LaTeX
9841 \family default
9842  environment between the two with just a 
9843 \begin_inset Quotes eld
9844 \end_inset
9845
9846
9847 \family typewriter
9848 %
9849 \family default
9850
9851 \begin_inset Quotes erd
9852 \end_inset
9853
9854  in it.
9855  This will force LyX to produce two separate environments and hence the
9856  correct LaTeX output.
9857  An example is provided in the example file included with the LyX distribution.
9858  Remember, this problem only occurs if you are trying to place two of the
9859  same type of theorem-like environments one directly after the other.
9860 \end_layout
9861
9862 \begin_layout Subsubsection
9863 Lists
9864 \end_layout
9865
9866 \begin_layout Standard
9867 You get all the commonly supported list styles found in other classes as
9868  well as two new ones.
9869  I'll only describe the new ones here.
9870  If you want to find out more about the other list environments check out
9871  the 
9872 \emph on
9873 User's Guide.
9874
9875 \emph default
9876  If you intend to use itemized lists you might also want to read about the
9877  
9878 \family sans
9879 Itemize
9880 \begin_inset space ~
9881 \end_inset
9882
9883 Bullet
9884 \begin_inset space ~
9885 \end_inset
9886
9887 Selection
9888 \family default
9889  dialog described above in section
9890 \begin_inset space ~
9891 \end_inset
9892
9893
9894 \begin_inset CommandInset ref
9895 LatexCommand ref
9896 reference "sec:bullet"
9897
9898 \end_inset
9899
9900 .
9901 \end_layout
9902
9903 \begin_layout Standard
9904 The two new list styles, 
9905 \family sans
9906 TickList
9907 \family default
9908  and 
9909 \family sans
9910 CrossList
9911 \family default
9912 , are designed to make it easier for you to create lists of do's and don'ts
9913  or right and wrong by providing dedicated environments that use a tick
9914  or a cross as the label of the list.
9915  These lists are in fact dedicated variants of the 
9916 \family sans
9917 Itemize
9918 \family default
9919  environment.
9920  They do however require that you have the 
9921 \family typewriter
9922 psnfss
9923 \family default
9924  packages installed.
9925 \end_layout
9926
9927 \begin_layout Subsubsection
9928 Figures and Tables
9929 \end_layout
9930
9931 \begin_layout Standard
9932
9933 \family sans
9934 FoilTeX
9935 \family default
9936  redefines the floating tables and figures so that they appear exactly where
9937  they are in the text rather than pushing them to the top of the page or
9938  to some user specified location.
9939  In fact if you change the float placement settings they are simply ignored.
9940 \end_layout
9941
9942 \begin_layout Subsubsection
9943 Page Headers and Footers
9944 \begin_inset CommandInset label
9945 LatexCommand label
9946 name "sec:foilfoot"
9947
9948 \end_inset
9949
9950
9951 \end_layout
9952
9953 \begin_layout Standard
9954
9955 \family sans
9956 My
9957 \begin_inset space ~
9958 \end_inset
9959
9960 Logo
9961 \family default
9962  and 
9963 \family sans
9964 Restriction
9965 \family default
9966  are two commands used to control the left-footer text string.
9967  The first is meant to allow you to include a graphic logo on your foils
9968  and defaults to 
9969 \begin_inset Quotes eld
9970 \end_inset
9971
9972 -Typeset by 
9973 \family sans
9974 FoilTeX
9975 \family default
9976 -
9977 \begin_inset Quotes erd
9978 \end_inset
9979
9980 .
9981  While the second is meant to provide a classification for the audience,
9982  
9983 \emph on
9984 e.
9985 \begin_inset space \thinspace{}
9986 \end_inset
9987
9988 g.
9989 \emph default
9990
9991 \begin_inset space \space{}
9992 \end_inset
9993
9994 Confidential.
9995  It is empty by default.
9996 \end_layout
9997
9998 \begin_layout Standard
9999 The remaining page corners can be filled by 
10000 \family sans
10001 Right
10002 \begin_inset space ~
10003 \end_inset
10004
10005 Footer
10006 \family default
10007  (which defaults to page numbers), 
10008 \family sans
10009 Right
10010 \begin_inset space ~
10011 \end_inset
10012
10013 Header
10014 \family default
10015  (top right) and 
10016 \family sans
10017 Left
10018 \begin_inset space ~
10019 \end_inset
10020
10021 Header
10022 \family default
10023  (top left).
10024 \end_layout
10025
10026 \begin_layout Subsection
10027 Unsupported 
10028 \family sans
10029 FoilTeX
10030 \family default
10031  Goodies
10032 \begin_inset CommandInset label
10033 LatexCommand label
10034 name "sec:unsuppfoils"
10035
10036 \end_inset
10037
10038
10039 \end_layout
10040
10041 \begin_layout Standard
10042 All the commands mentioned below need to be set in a 
10043 \family sans
10044 LaTeX
10045 \family default
10046  environment or as 
10047 \family sans
10048 TeX
10049 \family default
10050  within another environment.
10051 \end_layout
10052
10053 \begin_layout Subsubsection
10054 Lengths
10055 \end_layout
10056
10057 \begin_layout Standard
10058 All lengths are adjusted using the 
10059 \family typewriter
10060
10061 \backslash
10062 setlength{
10063 \family default
10064 \emph on
10065 lengthname
10066 \family typewriter
10067 \emph default
10068 }{
10069 \family default
10070 \emph on
10071 newlength
10072 \family typewriter
10073 \emph default
10074 }
10075 \family default
10076  command.
10077  Where 
10078 \emph on
10079 lengthname
10080 \emph default
10081  should be replaced by the name given to the length you want to change and
10082  
10083 \emph on
10084 newlength
10085 \emph default
10086  is the length value.
10087  All lengths should be specified in units of length such as inches (
10088 \family typewriter
10089 in
10090 \family default
10091 ), millimeters (
10092 \family typewriter
10093 mm
10094 \family default
10095 ) or points (
10096 \family typewriter
10097 pt
10098 \family default
10099 ) or relative to some document or font-based length such as 
10100 \family typewriter
10101
10102 \backslash
10103 textwidth
10104 \family default
10105 .
10106  
10107 \end_layout
10108
10109 \begin_layout Standard
10110 It's possible to change the spacing between a foilhead and the body of the
10111  foil by adjusting the length specified by 
10112 \family typewriter
10113
10114 \backslash
10115 foilheadskip
10116 \family default
10117 .
10118  For example, to make 
10119 \emph on
10120 all
10121 \emph default
10122  foilheads 0.5
10123 \begin_inset space \space{}
10124 \end_inset
10125
10126 in closer to their bodies put the following in the preamble: 
10127 \family typewriter
10128
10129 \backslash
10130 setlength{
10131 \backslash
10132 foilheadskip}{-0.5in}
10133 \end_layout
10134
10135 \begin_layout Standard
10136 The spacings around floats can be adjusted by setting these lengths:
10137 \end_layout
10138
10139 \begin_layout Labeling
10140 \labelwidthstring MMMMMMMMMMM
10141
10142 \family typewriter
10143
10144 \backslash
10145 abovefloatskip
10146 \family default
10147  Separation between the text and the top of the float
10148 \end_layout
10149
10150 \begin_layout Labeling
10151 \labelwidthstring MMMMMMMMMMM
10152
10153 \family typewriter
10154
10155 \backslash
10156 abovecaptionskip
10157 \family default
10158  Separation between the float and the caption
10159 \end_layout
10160
10161 \begin_layout Labeling
10162 \labelwidthstring MMMMMMMMMMM
10163
10164 \family typewriter
10165
10166 \backslash
10167 belowcaptionskip
10168 \family default
10169  Separation between the caption and the following text
10170 \end_layout
10171
10172 \begin_layout Labeling
10173 \labelwidthstring MMMMMMMMMMM
10174
10175 \family typewriter
10176
10177 \backslash
10178 captionwidth
10179 \family default
10180  You can make the captions narrower than the surrounding text by adjusting
10181  this length.
10182  Best done relative to 
10183 \family typewriter
10184
10185 \backslash
10186 textwidth
10187 \family default
10188 .
10189 \end_layout
10190
10191 \begin_layout Standard
10192 There are also several title page related lengths that you may find useful
10193  if you have a long title or several authors:
10194 \end_layout
10195
10196 \begin_layout Labeling
10197 \labelwidthstring MMMMMMMMMMM
10198
10199 \family typewriter
10200
10201 \backslash
10202 abovetitleskip
10203 \family default
10204  Separation from headers to 
10205 \family sans
10206 Title
10207 \end_layout
10208
10209 \begin_layout Labeling
10210 \labelwidthstring MMMMMMMMMMM
10211
10212 \family typewriter
10213
10214 \backslash
10215 titleauthorskip
10216 \family default
10217  between 
10218 \family sans
10219 Title
10220 \family default
10221  and 
10222 \family sans
10223 Author
10224 \family default
10225  environments
10226 \end_layout
10227
10228 \begin_layout Labeling
10229 \labelwidthstring MMMMMMMMMMM
10230
10231 \family typewriter
10232
10233 \backslash
10234 authorauthorskip
10235 \family default
10236  between multiple 
10237 \family sans
10238 Author
10239 \family default
10240  lines
10241 \end_layout
10242
10243 \begin_layout Labeling
10244 \labelwidthstring MMMMMMMMMMM
10245
10246 \family typewriter
10247
10248 \backslash
10249 authordateskip
10250 \family default
10251  between the 
10252 \family sans
10253 Author
10254 \family default
10255  and the 
10256 \family sans
10257 Date
10258 \end_layout
10259
10260 \begin_layout Labeling
10261 \labelwidthstring MMMMMMMMMMM
10262
10263 \family typewriter
10264
10265 \backslash
10266 dateabstractskip
10267 \family default
10268  between the 
10269 \family sans
10270 Date
10271 \family default
10272  and the 
10273 \family sans
10274 Abstract
10275 \end_layout
10276
10277 \begin_layout Standard
10278 The last length related command affects all the list environments.
10279  If you place 
10280 \family typewriter
10281
10282 \backslash
10283 zerolistvertdimens
10284 \family default
10285  
10286 \emph on
10287 inside
10288 \emph default
10289  a list environment then all the vertical spacing between the list items
10290  is removed.
10291  Note that this is a command not a length so it doesn't require 
10292 \family typewriter
10293
10294 \backslash
10295 setlength
10296 \family default
10297  like the stuff mentioned above.
10298 \end_layout
10299
10300 \begin_layout Subsubsection
10301 Headers and Footers
10302 \end_layout
10303
10304 \begin_layout Standard
10305 The 
10306 \family typewriter
10307
10308 \backslash
10309 LogoOn
10310 \family default
10311  and 
10312 \family typewriter
10313
10314 \backslash
10315 LogoOff
10316 \family default
10317  commands control whether the logo in the 
10318 \family sans
10319 MyLogo
10320 \family default
10321  definition appear on a given page.
10322  If you put 
10323 \family typewriter
10324
10325 \backslash
10326 LogoOff
10327 \family default
10328  in the preamble then none of the foils will have the logo on them.
10329  If you don't want the logo on a particular page place the 
10330 \family typewriter
10331
10332 \backslash
10333 LogoOff
10334 \family default
10335  directly after the foilhead of that page and the 
10336 \family typewriter
10337
10338 \backslash
10339 LogoOn
10340 \family default
10341  directly after the next foilhead.
10342 \end_layout
10343
10344 \begin_layout Standard
10345 If you decide to use the 
10346 \family sans
10347 fancy
10348 \family default
10349  page style setting in the 
10350 \family sans
10351 Document
10352 \begin_inset space ~
10353 \end_inset
10354
10355 Layout
10356 \family default
10357  dialog you should probably add 
10358 \family typewriter
10359
10360 \backslash
10361 let
10362 \backslash
10363 headwidth
10364 \backslash
10365 textwidth
10366 \family default
10367  to your preamble so headers and footers on landscape pages are correctly
10368  placed when rotated.
10369  This is due to some clashes between the page layouts provided by the 
10370 \family sans
10371 fancyheadings
10372 \family default
10373  package and the 
10374 \family sans
10375 foils
10376 \family default
10377  class.
10378 \end_layout
10379
10380 \begin_layout Section
10381 Hollywood (Hollywood spec scripts)
10382 \end_layout
10383
10384 \begin_layout Standard
10385 by 
10386 \shape smallcaps
10387 Garst Reese
10388 \end_layout
10389
10390 \begin_layout Subsection
10391 Introduction
10392 \end_layout
10393
10394 \begin_layout Standard
10395 Getting the format of a Hollywood script right is a 
10396 \begin_inset Quotes eld
10397 \end_inset
10398
10399 rite of passage.
10400 \begin_inset Quotes erd
10401 \end_inset
10402
10403  It is designed to make the readers focus on content and to be easy and
10404  familiar for the actors to read.
10405  Each page of a script should be one minute of film.
10406  Nothing goes in a script that you cannot see or hear on screen.
10407  The courier 12 pt font should be used throughout.
10408  No italics.
10409 \end_layout
10410
10411 \begin_layout Subsection
10412 Special problems
10413 \end_layout
10414
10415 \begin_layout Standard
10416 Speakers' lines should NEVER break in mid-sentence.
10417  If a speaker's lines continue over a page break, repeat the 
10418 \family sans
10419 Speaker
10420 \family default
10421  title followed by (Cont'd).
10422 \end_layout
10423
10424 \begin_layout Subsection
10425 Special features
10426 \end_layout
10427
10428 \begin_layout Standard
10429 Insert the 
10430 \family sans
10431 Speaker
10432 \family default
10433  names as labels then cross-reference the label to insert the name.
10434  The cross-reference dialog will show the current cast of characters.
10435  You can use this to insert the speaker name in narratives also.
10436 \end_layout
10437
10438 \begin_layout Subsection
10439 Paper size and Margins
10440 \end_layout
10441
10442 \begin_layout Standard
10443 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10444 \end_layout
10445
10446 \begin_layout Subsection
10447 Environments
10448 \end_layout
10449
10450 \begin_layout Standard
10451 The following environments are available.
10452  You can use hollywood.bind to get the bind keys shown at the right.
10453 \end_layout
10454
10455 \begin_layout Itemize
10456
10457 \family sans
10458 Standard
10459 \begin_inset Newline newline
10460 \end_inset
10461
10462
10463 \family default
10464 Used where nothing else works.
10465  Try to avoid it.
10466 \end_layout
10467
10468 \begin_layout Itemize
10469
10470 \family sans
10471 FADE_IN
10472 \family default
10473 :
10474 \begin_inset space \hfill{}
10475 \end_inset
10476
10477
10478 \family sans
10479 M-z S-I
10480 \family default
10481
10482 \begin_inset Newline newline
10483 \end_inset
10484
10485 Usually followed by something like 
10486 \begin_inset Quotes eld
10487 \end_inset
10488
10489 on Sally waking up.
10490 \begin_inset Quotes erd
10491 \end_inset
10492
10493
10494 \end_layout
10495
10496 \begin_layout Itemize
10497
10498 \family sans
10499 INT:
10500 \begin_inset space \hfill{}
10501 \end_inset
10502
10503 M-z i
10504 \begin_inset Newline newline
10505 \end_inset
10506
10507
10508 \family default
10509 Introduces a new INTERIOR camera set-up.
10510  Always followed by DAY or NIGHT, or something similar to define the lighting
10511  required.
10512  Everthing on this line in CAPS.
10513 \end_layout
10514
10515 \begin_layout Itemize
10516
10517 \family sans
10518 EXT:
10519 \begin_inset space \hfill{}
10520 \end_inset
10521
10522 M-z e
10523 \begin_inset Newline newline
10524 \end_inset
10525
10526
10527 \family default
10528 Introduces a new EXTERIOR camera set-up.
10529  Everthing on this line in CAPS.
10530 \end_layout
10531
10532 \begin_layout Itemize
10533
10534 \family sans
10535 Speaker
10536 \begin_inset space \hfill{}
10537 \end_inset
10538
10539 M-z s
10540 \begin_inset Newline newline
10541 \end_inset
10542
10543
10544 \family default
10545 The character speaking.
10546 \end_layout
10547
10548 \begin_layout Itemize
10549
10550 \family sans
10551 Parenthetical
10552 \begin_inset space \hfill{}
10553 \end_inset
10554
10555 M-z p
10556 \begin_inset Newline newline
10557 \end_inset
10558
10559
10560 \family default
10561 Instructions to the speaker.
10562  The () are automatically inserted, but only the ( will show in LyX.
10563  Both will be printed.
10564 \end_layout
10565
10566 \begin_layout Itemize
10567
10568 \family sans
10569 Dialogue
10570 \begin_inset space \hfill{}
10571 \end_inset
10572
10573 M-z d
10574 \begin_inset Newline newline
10575 \end_inset
10576
10577
10578 \family default
10579 What the 
10580 \family sans
10581 Speaker
10582 \family default
10583  says.
10584 \end_layout
10585
10586 \begin_layout Itemize
10587
10588 \family sans
10589 Transition
10590 \begin_inset space \hfill{}
10591 \end_inset
10592
10593 M-z t
10594 \begin_inset Newline newline
10595 \end_inset
10596
10597
10598 \family default
10599 Camera movement instruction.
10600  e.
10601 \begin_inset space \thinspace{}
10602 \end_inset
10603
10604 g.
10605 \begin_inset space \space{}
10606 \end_inset
10607
10608 CUT TO:
10609 \end_layout
10610
10611 \begin_layout Itemize
10612
10613 \family sans
10614 FADE OUT:
10615 \begin_inset space \hfill{}
10616 \end_inset
10617
10618 M-z S-I
10619 \end_layout
10620
10621 \begin_layout Itemize
10622
10623 \family sans
10624 Author
10625 \begin_inset space \hfill{}
10626 \end_inset
10627
10628 M-z S-A
10629 \end_layout
10630
10631 \begin_layout Itemize
10632
10633 \family sans
10634 Title
10635 \begin_inset space \hfill{}
10636 \end_inset
10637
10638 M-z S-T
10639 \end_layout
10640
10641 \begin_layout Itemize
10642
10643 \family sans
10644 Right_Address
10645 \begin_inset space \hfill{}
10646 \end_inset
10647
10648 M-z r
10649 \end_layout
10650
10651 \begin_layout Subsection
10652 Script jargon
10653 \end_layout
10654
10655 \begin_layout Itemize
10656 (O.S) â€” off screen
10657 \end_layout
10658
10659 \begin_layout Itemize
10660 (V.0) â€” voice over
10661 \end_layout
10662
10663 \begin_layout Itemize
10664 b.
10665 \begin_inset space \thinspace{}
10666 \end_inset
10667
10668 g.
10669  â€” background
10670 \end_layout
10671
10672 \begin_layout Itemize
10673 C.U.
10674  â€” close-up
10675 \end_layout
10676
10677 \begin_layout Itemize
10678 PAN â€” camera movement
10679 \end_layout
10680
10681 \begin_layout Itemize
10682 INSERT â€” cut to close-up of
10683 \end_layout
10684
10685 \begin_layout Section
10686 ijmpc and ijmpd
10687 \end_layout
10688
10689 \begin_layout Standard
10690 by 
10691 \noun on
10692 Panayotis Papasotiriou
10693 \end_layout
10694
10695 \begin_layout Subsection
10696 Overview
10697 \end_layout
10698
10699 \begin_layout Standard
10700 The ijmpc package is a set of macros that facilitates electronic manuscript
10701  submission to the 
10702 \emph on
10703 International Journal of Modern Physics C
10704 \emph default
10705 .
10706  Similarly, the ijmpd package is for creating manuscripts to be submitted
10707  to the 
10708 \emph on
10709 International Journal of Modern Physics D
10710 \emph default
10711 .
10712  Both journals are published by World Scientific.
10713  The corresponding document classes are named 
10714 \family typewriter
10715 ws-ijmpc.cls
10716 \family default
10717  and 
10718 \family typewriter
10719 ws-ijmpd.cls
10720 \family default
10721 , respectively.
10722  These files, together with instructions for the authors, can be downloaded
10723  from the sites 
10724 \begin_inset Flex URL
10725 status collapsed
10726
10727 \begin_layout Plain Layout
10728
10729 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
10730 \end_layout
10731
10732 \end_inset
10733
10734  and 
10735 \begin_inset Flex URL
10736 status collapsed
10737
10738 \begin_layout Plain Layout
10739
10740 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
10741 \end_layout
10742
10743 \end_inset
10744
10745 .
10746  Both packages are modified versions of the standard 
10747 \begin_inset Quotes eld
10748 \end_inset
10749
10750 article
10751 \begin_inset Quotes erd
10752 \end_inset
10753
10754  package, and they are almost (but not exactly) identical.
10755  Most of their features are supported by LyX.
10756  I have used LyX successfully to write articles submitted to both journals
10757  without any problem.
10758 \end_layout
10759
10760 \begin_layout Subsection
10761 Writing a paper
10762 \end_layout
10763
10764 \begin_layout Standard
10765 As usual, the easiest way to write a paper is to start with a template.
10766  Click on 
10767 \family sans
10768 File\SpecialChar \menuseparator
10769 New from
10770 \family default
10771  
10772 \family sans
10773 \bar under
10774 T
10775 \bar default
10776 emplate
10777 \family default
10778 , then choose the 
10779 \family typewriter
10780 ijmpc.lyx
10781 \family default
10782  or 
10783 \family typewriter
10784 ijmpd.lyx
10785 \family default
10786  template.
10787  This will give an (almost) empty document that includes the most common
10788  fields found in a manuscript.
10789  Simply overwrite the existing text (including the brackets, 
10790 \family typewriter
10791 <>
10792 \family default
10793 ) with your text.
10794  You should keep in mind the following remarks.
10795 \end_layout
10796
10797 \begin_layout Enumerate
10798 LyX won't let you change the font size and the page style of the document,
10799  because such modifications are not allowed by both packages.
10800 \end_layout
10801
10802 \begin_layout Enumerate
10803 The language of the document should not be changed.
10804  Before previewing your paper, be sure that the babel package is not used.
10805  To do this, click on 
10806 \family sans
10807 Tools\SpecialChar \menuseparator
10808 Preferences
10809 \family default
10810 , select the 
10811 \family sans
10812 Lang Opts
10813 \family default
10814  tab, deselect the 
10815 \family sans
10816 Use babel
10817 \family default
10818  checkbox in the language settings, and click on 
10819 \family sans
10820 Apply
10821 \family default
10822  (or 
10823 \family sans
10824 Save
10825 \family default
10826 , if you wish to make this change permanent).
10827 \end_layout
10828
10829 \begin_layout Enumerate
10830 The 
10831 \begin_inset Quotes eld
10832 \end_inset
10833
10834 Keywords
10835 \begin_inset Quotes erd
10836 \end_inset
10837
10838  style must be used to define keywords.
10839 \end_layout
10840
10841 \begin_layout Enumerate
10842 The ijmpc package provides a style named 
10843 \begin_inset Quotes eld
10844 \end_inset
10845
10846 Classification Codes
10847 \begin_inset Quotes erd
10848 \end_inset
10849
10850 , which can be used to define classification codes, such as PACS numbers.
10851  Note that this facility is not supported by the ijmpd package.
10852 \end_layout
10853
10854 \begin_layout Enumerate
10855 Several new environments are available: 
10856 \begin_inset Quotes eld
10857 \end_inset
10858
10859 Definition
10860 \begin_inset Quotes erd
10861 \end_inset
10862
10863
10864 \begin_inset Quotes eld
10865 \end_inset
10866
10867 Step
10868 \begin_inset Quotes erd
10869 \end_inset
10870
10871
10872 \begin_inset Quotes eld
10873 \end_inset
10874
10875 Example
10876 \begin_inset Quotes erd
10877 \end_inset
10878
10879
10880 \begin_inset Quotes eld
10881 \end_inset
10882
10883 Remark
10884 \begin_inset Quotes erd
10885 \end_inset
10886
10887
10888 \begin_inset Quotes eld
10889 \end_inset
10890
10891 Notation
10892 \begin_inset Quotes erd
10893 \end_inset
10894
10895
10896 \begin_inset Quotes eld
10897 \end_inset
10898
10899 Theorem
10900 \begin_inset Quotes erd
10901 \end_inset
10902
10903
10904 \begin_inset Quotes eld
10905 \end_inset
10906
10907 Proof
10908 \begin_inset Quotes erd
10909 \end_inset
10910
10911
10912 \begin_inset Quotes eld
10913 \end_inset
10914
10915 Corollary
10916 \begin_inset Quotes erd
10917 \end_inset
10918
10919
10920 \begin_inset Quotes eld
10921 \end_inset
10922
10923 Lemma
10924 \begin_inset Quotes erd
10925 \end_inset
10926
10927
10928 \begin_inset Quotes eld
10929 \end_inset
10930
10931 Proposition
10932 \begin_inset Quotes erd
10933 \end_inset
10934
10935
10936 \begin_inset Quotes eld
10937 \end_inset
10938
10939 Prop
10940 \begin_inset Quotes erd
10941 \end_inset
10942
10943
10944 \begin_inset Quotes eld
10945 \end_inset
10946
10947 Question
10948 \begin_inset Quotes erd
10949 \end_inset
10950
10951
10952 \begin_inset Quotes eld
10953 \end_inset
10954
10955 Claim
10956 \begin_inset Quotes erd
10957 \end_inset
10958
10959 , and 
10960 \begin_inset Quotes eld
10961 \end_inset
10962
10963 Conjecture
10964 \begin_inset Quotes erd
10965 \end_inset
10966
10967 .
10968  Their use is more or less obvious.
10969  LyX supports all these environments; it will use the proper label, text
10970  style, and numbering scheme for each of them.
10971 \end_layout
10972
10973 \begin_layout Enumerate
10974 Both packages use basic citations; the natbib package should not be used.
10975  In LyX, citation references are shown as usual; in the output, citations
10976  are shown as superscripts.
10977  If you want to use a citation as normal text, you should use the 
10978 \family typewriter
10979 refcite
10980 \family default
10981  command, e.
10982 \begin_inset space \thinspace{}
10983 \end_inset
10984
10985 g.
10986 \begin_inset space \space{}
10987 \end_inset
10988
10989
10990 \begin_inset Quotes eld
10991 \end_inset
10992
10993 See Ref.
10994 \begin_inset space \space{}
10995 \end_inset
10996
10997
10998 \family typewriter
10999
11000 \backslash
11001 refcite{key}
11002 \family default
11003
11004 \begin_inset Quotes erd
11005 \end_inset
11006
11007 .
11008 \end_layout
11009
11010 \begin_layout Enumerate
11011 There is no 
11012 \begin_inset Quotes eld
11013 \end_inset
11014
11015 Acknowledgments
11016 \begin_inset Quotes erd
11017 \end_inset
11018
11019  section in both packages.
11020  To put acknowledgments, just use the 
11021 \begin_inset Quotes eld
11022 \end_inset
11023
11024 Section*
11025 \begin_inset Quotes erd
11026 \end_inset
11027
11028  environment.
11029 \end_layout
11030
11031 \begin_layout Enumerate
11032 Appendices may be added to the paper, 
11033 \emph on
11034 after
11035 \emph default
11036  the Acknowledgments and 
11037 \shape italic
11038 before
11039 \shape default
11040  the References.
11041  LyX provides a special environment, called 
11042 \begin_inset Quotes eld
11043 \end_inset
11044
11045 Appendices Section
11046 \begin_inset Quotes erd
11047 \end_inset
11048
11049  which marks the beginning of the appendices.
11050  This environment should be left blank; it just sends a LaTeX command, but
11051  nothing is really printed.
11052  In LyX, the word 
11053 \begin_inset Quotes eld
11054 \end_inset
11055
11056 Appendix
11057 \begin_inset Quotes erd
11058 \end_inset
11059
11060  is printed with blue letters, as a signal that all sections after that
11061  point are appendices.
11062  To write an appendix, use the 
11063 \begin_inset Quotes eld
11064 \end_inset
11065
11066 Appendix
11067 \begin_inset Quotes erd
11068 \end_inset
11069
11070  environment.
11071  LyX will number each appendix with capital letters, as required by both
11072  journals.
11073  Note that 
11074 \begin_inset Quotes eld
11075 \end_inset
11076
11077 Appendices Section
11078 \begin_inset Quotes erd
11079 \end_inset
11080
11081  
11082 \emph on
11083 must
11084 \emph default
11085  be present before the first appendix; if not, all appendices will be numbered
11086  as normal sections in the output.
11087 \end_layout
11088
11089 \begin_layout Enumerate
11090 The ijmpc and the ijmpd packages use the 
11091 \family typewriter
11092 tbl
11093 \family default
11094  command to implement table captions.
11095  As a result, a table created by LyX is printed correctly, but its caption
11096  is ignored.
11097  However, you can use some TeX code to overpass this problem, so that captions
11098  are printed as expected.
11099  To do so, create a float table as usual, remove the caption, and replace
11100  it with the TeX code 
11101 \family typewriter
11102
11103 \backslash
11104 tbl{
11105 \emph on
11106 your table caption
11107 \emph default
11108 }{
11109 \family default
11110  (sic); you must also the TeX code 
11111 \family typewriter
11112 }
11113 \family default
11114  immediately after the tabular material.
11115  Study the example table included in the template files to see how this
11116  trick is implemented.
11117  Alternatively, If you need table captions, you should implement the whole
11118  table float in a 
11119 \family typewriter
11120 .tex
11121 \family default
11122  file, then include this file to the LyX document (
11123 \family sans
11124 Insert\SpecialChar \menuseparator
11125 File\SpecialChar \menuseparator
11126 Child
11127 \begin_inset space ~
11128 \end_inset
11129
11130 Document
11131 \family default
11132 ).
11133  Details on how to create a table float can be found in the files 
11134 \family typewriter
11135 ws-ijmpc.tex
11136 \family default
11137  and 
11138 \family typewriter
11139 ws-ijmpd.tex
11140 \family default
11141 , included in the corresponding packages.
11142 \end_layout
11143
11144 \begin_layout Subsection
11145 Preparing a paper for submission
11146 \end_layout
11147
11148 \begin_layout Standard
11149 Before you submit your paper you must export the LyX document as a LaTeX
11150  file (
11151 \family sans
11152 File\SpecialChar \menuseparator
11153 Export\SpecialChar \menuseparator
11154 LaTeX
11155 \family default
11156 )
11157 \begin_inset Foot
11158 status open
11159
11160 \begin_layout Plain Layout
11161 Actually you have the choice between LaTeX (plain) and pdflatex.
11162  If you intend to use pdflatex to prepare the paper, you should use the
11163  pdflatex option so that included graphics are converted to PDF format,
11164  ready for use by pdflatex.
11165 \end_layout
11166
11167 \end_inset
11168
11169 , then make the following changes to the resulting 
11170 \family typewriter
11171 .tex
11172 \family default
11173  file.
11174 \end_layout
11175
11176 \begin_layout Enumerate
11177 Remove the comment lines before the 
11178 \family typewriter
11179
11180 \backslash
11181 documentclass
11182 \family default
11183  command.
11184 \end_layout
11185
11186 \begin_layout Enumerate
11187 Remove everything between (and including) the 
11188 \family typewriter
11189
11190 \backslash
11191 makeatletter
11192 \family default
11193  and 
11194 \family typewriter
11195
11196 \backslash
11197 makeatother
11198 \family default
11199  commands, except for any commands you specifically put into the LaTeX preamble.
11200 \end_layout
11201
11202 \begin_layout Standard
11203 The modified 
11204 \family typewriter
11205 .tex
11206 \family default
11207  file should be saved and processed through LaTeX as many times as necessary.
11208  You may also want to check the resulting 
11209 \family typewriter
11210 .dvi
11211 \family default
11212  document.
11213 \end_layout
11214
11215 \begin_layout Subsection
11216 Use of TeX code
11217 \end_layout
11218
11219 \begin_layout Standard
11220 The use of TeX code is reduced to two commands, which must be placed at
11221  the top of the document.
11222  If you started writing your paper by using the 
11223 \family typewriter
11224 ijmpc.lyx
11225 \family default
11226  or the 
11227 \family typewriter
11228 ijmpd.lyx
11229 \family default
11230  template, the TeX code needed is already in its place; you usually don't
11231  need to delete it.
11232  You may only modify the first TeX code to specify the information printed
11233  to the top of odd and even pages (authors' names and short paper's title,
11234  respectively).
11235  This TeX code must have the form 
11236 \family typewriter
11237
11238 \backslash
11239 markboth{Authors' Names}{Short Paper's Title}
11240 \family default
11241 .
11242 \end_layout
11243
11244 \begin_layout Section
11245 iopart
11246 \end_layout
11247
11248 \begin_layout Standard
11249 by 
11250 \noun on
11251 Uwe Stöhr
11252 \end_layout
11253
11254 \begin_layout Subsection
11255 Overview
11256 \end_layout
11257
11258 \begin_layout Standard
11259 The iopart package provides a document class to create electronic manuscript
11260  submission to the journals published by the Institute of Physics.
11261  Instructions for the authors how to create a paper using the iopart class
11262  can be downloaded together with the iopart package from the site 
11263 \begin_inset Flex URL
11264 status collapsed
11265
11266 \begin_layout Plain Layout
11267
11268 ftp://ftp.iop.org/pub/journals/latex2e
11269 \end_layout
11270
11271 \end_inset
11272
11273 .
11274 \end_layout
11275
11276 \begin_layout Subsection
11277 Writing a paper
11278 \end_layout
11279
11280 \begin_layout Standard
11281 The easiest way to write a paper is to start with the file 
11282 \emph on
11283 IOP-article.lyx
11284 \emph default
11285  that is available in LyX's examples files folder.
11286  Open this file, save it under a new name, and start writing.
11287  The example file explains how to use the special text environments.
11288  Here are the most important advices:
11289 \end_layout
11290
11291 \begin_layout Itemize
11292 To be able to compile your document to a PDF, PS, or DVI, assure that the
11293  two options 
11294 \family sans
11295 Use AMS math package
11296 \family default
11297  in the document settings under 
11298 \family sans
11299 Math Options
11300 \family default
11301  are not used!
11302 \end_layout
11303
11304 \begin_layout Itemize
11305
11306 \size normal
11307 The title environment defines the kind of your paper.
11308  So use one of the following environments for the title:
11309 \end_layout
11310
11311 \begin_deeper
11312 \begin_layout Itemize
11313
11314 \family sans
11315 \size normal
11316 Title
11317 \family default
11318  for a Paper
11319 \end_layout
11320
11321 \begin_layout Itemize
11322
11323 \family sans
11324 \size normal
11325 Review
11326 \family default
11327  for a Review
11328 \end_layout
11329
11330 \begin_layout Itemize
11331
11332 \family sans
11333 \size normal
11334 Topical
11335 \family default
11336  for a Topical review
11337 \end_layout
11338
11339 \begin_layout Itemize
11340
11341 \family sans
11342 \size normal
11343 Comment
11344 \family default
11345  for a Comment
11346 \end_layout
11347
11348 \begin_layout Itemize
11349
11350 \family sans
11351 \size normal
11352 Note
11353 \family default
11354  for a Note
11355 \end_layout
11356
11357 \begin_layout Itemize
11358
11359 \family sans
11360 \size normal
11361 Paper
11362 \family default
11363  for a Paper (same as Title)
11364 \end_layout
11365
11366 \begin_layout Itemize
11367
11368 \family sans
11369 \size normal
11370 Prelim
11371 \family default
11372  for a Preliminary communication
11373 \end_layout
11374
11375 \begin_layout Itemize
11376
11377 \family sans
11378 \size normal
11379 Rapid
11380 \family default
11381  for a Rapid communication
11382 \end_layout
11383
11384 \begin_layout Itemize
11385
11386 \family sans
11387 \size normal
11388 Letter
11389 \family default
11390  for a Letter to the editor
11391 \end_layout
11392
11393 \end_deeper
11394 \begin_layout Itemize
11395
11396 \size normal
11397 All title environments except of 
11398 \family sans
11399 Letter
11400 \family default
11401  can have an optional short title.
11402 \end_layout
11403
11404 \begin_layout Itemize
11405 There is a general title environment 
11406 \family sans
11407 Article
11408 \family default
11409  which is not directly supported by the LyX.
11410  This can be used as TeX code when your document doesn't fit into one of
11411  the other title types.
11412 \end_layout
11413
11414 \begin_layout Standard
11415 For more informations like hints for special table and formula formatting,
11416  look at the IOP author guidelines.
11417 \end_layout
11418
11419 \begin_layout Section
11420 Kluwer
11421 \end_layout
11422
11423 \begin_layout Standard
11424 by 
11425 \noun on
11426 Panayotis Papasotiriou
11427 \end_layout
11428
11429 \begin_layout Subsection
11430 Overview
11431 \end_layout
11432
11433 \begin_layout Standard
11434 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
11435  that facilitates electronic manuscript submission to the journals they
11436  publish.
11437  Most known of them (at least in my domain of interest) are 
11438 \emph on
11439 Astrophysics and Space Science
11440 \emph default
11441  and 
11442 \emph on
11443 Solar Physics
11444 \emph default
11445 , but there are many others (see a complete list at 
11446 \begin_inset Flex URL
11447 status collapsed
11448
11449 \begin_layout Plain Layout
11450
11451 http://www.wkap.nl/jrnllist.htm/JRNLHOME
11452 \end_layout
11453
11454 \end_inset
11455
11456 ).
11457  The Kluwer package may be downloaded from the site 
11458 \begin_inset Flex URL
11459 status collapsed
11460
11461 \begin_layout Plain Layout
11462
11463 http://www.wkap.nl/kaphtml.htm/STYLEFILES
11464 \end_layout
11465
11466 \end_inset
11467
11468 .
11469  A complete user guide is contained in that package (but it can also be
11470  downloaded separately).
11471 \end_layout
11472
11473 \begin_layout Standard
11474 LyX supports many features of the package but not everything.
11475  However, the TeX code needed is reduced to some 
11476 \begin_inset Quotes eld
11477 \end_inset
11478
11479 peculiar
11480 \begin_inset Quotes erd
11481 \end_inset
11482
11483  commands of the package (see
11484 \begin_inset space ~
11485 \end_inset
11486
11487
11488 \begin_inset CommandInset ref
11489 LatexCommand ref
11490 reference "subsec:kluwer_peculiarities"
11491
11492 \end_inset
11493
11494 ).
11495  I have recently used LyX to write an article submitted to the 
11496 \emph on
11497 Astrophysics and Space Science
11498 \emph default
11499  without any problem.
11500 \end_layout
11501
11502 \begin_layout Subsection
11503 Writing a paper
11504 \end_layout
11505
11506 \begin_layout Standard
11507 The easiest way to write a paper is to start with the Kluwer template file.
11508  Click on 
11509 \family sans
11510 File\SpecialChar \menuseparator
11511 New from
11512 \family default
11513  
11514 \family sans
11515 Template
11516 \family default
11517 , then choose the 
11518 \family typewriter
11519 kluwer.lyx
11520 \family default
11521  template.
11522  This will give an (almost) empty document that includes the most common
11523  fields found in a manuscript and a short description of their use.
11524  As in most templates, simply overwrite the existing text (including the
11525  brackets, 
11526 \family typewriter
11527 <>
11528 \family default
11529 ) with the correct information.
11530 \end_layout
11531
11532 \begin_layout Subsection
11533 Preparing a paper for submission
11534 \end_layout
11535
11536 \begin_layout Standard
11537 As in the AASTeX package, before you submit your paper to a journal you
11538  must 
11539 \begin_inset Quotes eld
11540 \end_inset
11541
11542 postprocess
11543 \begin_inset Quotes erd
11544 \end_inset
11545
11546  it as follows.
11547 \end_layout
11548
11549 \begin_layout Enumerate
11550 Export your paper as a LaTeX file.
11551  To do this, click on 
11552 \family sans
11553 File\SpecialChar \menuseparator
11554 Export\SpecialChar \menuseparator
11555 LaTeX
11556 \family default
11557 .
11558  
11559 \end_layout
11560
11561 \begin_layout Enumerate
11562 Edit the resulting 
11563 \family typewriter
11564 .tex
11565 \family default
11566  file with a text editor and make the following changes
11567 \end_layout
11568
11569 \begin_deeper
11570 \begin_layout Enumerate
11571 remove the comment lines before the 
11572 \family typewriter
11573
11574 \backslash
11575 documentclass
11576 \family default
11577  command,
11578 \end_layout
11579
11580 \begin_layout Enumerate
11581 remove everything between (and including) the 
11582 \family typewriter
11583
11584 \backslash
11585 makeatletter
11586 \family default
11587  and 
11588 \family typewriter
11589
11590 \backslash
11591 makeatother
11592 \family default
11593  commands, except for any commands you specifically put into the LaTeX preamble.
11594 \end_layout
11595
11596 \begin_layout Standard
11597 Save the resulting 
11598 \family typewriter
11599 .tex
11600 \family default
11601  file.
11602 \end_layout
11603
11604 \end_deeper
11605 \begin_layout Enumerate
11606 Run the 
11607 \family typewriter
11608 .tex
11609 \family default
11610  file through LaTeX as many times as necessary (usually up to three).
11611 \end_layout
11612
11613 \begin_layout Enumerate
11614 View the resulting 
11615 \family typewriter
11616 .dvi
11617 \family default
11618  document using, e.
11619 \begin_inset space \thinspace{}
11620 \end_inset
11621
11622 g.
11623 \begin_inset space \space{}
11624 \end_inset
11625
11626
11627 \family sans
11628 xdvi
11629 \family default
11630 , and check if everything is OK (it should, if you didn't make any mistake).
11631 \end_layout
11632
11633 \begin_layout Subsection
11634 \begin_inset Quotes eld
11635 \end_inset
11636
11637 Peculiarities
11638 \begin_inset Quotes erd
11639 \end_inset
11640
11641  of the Kluwer package
11642 \begin_inset CommandInset label
11643 LatexCommand label
11644 name "subsec:kluwer_peculiarities"
11645
11646 \end_inset
11647
11648
11649 \end_layout
11650
11651 \begin_layout Standard
11652 The Kluwer package has the following 
11653 \begin_inset Quotes eld
11654 \end_inset
11655
11656 peculiarities
11657 \begin_inset Quotes erd
11658 \end_inset
11659
11660 .
11661 \end_layout
11662
11663 \begin_layout Enumerate
11664 It is possible to write multiple articles in the same LaTeX file
11665 \begin_inset Foot
11666 status collapsed
11667
11668 \begin_layout Plain Layout
11669 I can't imagine any good reason to do this.
11670 \end_layout
11671
11672 \end_inset
11673
11674 .
11675  Each article must be included in the environment 
11676 \begin_inset Quotes eld
11677 \end_inset
11678
11679 article
11680 \begin_inset Quotes erd
11681 \end_inset
11682
11683 .
11684  Unfortunately, this environment cannot be omitted, even if you write just
11685  one article.
11686  Therefore, each article starts with the command 
11687 \family typewriter
11688
11689 \backslash
11690 begin{article}
11691 \family default
11692  and, obviously, ends with the command 
11693 \family typewriter
11694
11695 \backslash
11696 end{article}
11697 \family default
11698 .
11699  Although this can be implemented in LyX, I didn't included it, since it
11700  looks ugly and can confuse the novice user.
11701  Therefore, you need to enter them directly and mark them as LaTeX code
11702  (the well-known 
11703 \begin_inset Quotes eld
11704 \end_inset
11705
11706 TeX code
11707 \begin_inset Quotes erd
11708 \end_inset
11709
11710 ).
11711 \end_layout
11712
11713 \begin_layout Enumerate
11714 Information given at the beginning of the article (i.
11715 \begin_inset space \thinspace{}
11716 \end_inset
11717
11718 g.
11719 \begin_inset space \space{}
11720 \end_inset
11721
11722 title, subtitle, author, institution, running title, running author, abstract
11723  and keywords) must be included in an environment called 
11724 \begin_inset Quotes eld
11725 \end_inset
11726
11727 opening
11728 \begin_inset Quotes erd
11729 \end_inset
11730
11731 .
11732  This is not implemented in LyX, so you must enter title, subtitle etc.
11733 \begin_inset space ~
11734 \end_inset
11735
11736 between two TeX code lines (
11737 \family typewriter
11738
11739 \backslash
11740 begin{opening}
11741 \family default
11742  and 
11743 \family typewriter
11744
11745 \backslash
11746 end{opening}
11747 \family default
11748 ).
11749 \end_layout
11750
11751 \begin_layout Enumerate
11752 According to the user manual, the label of each bibliography item must be
11753  written as 
11754 \family typewriter
11755
11756 \backslash
11757 protect
11758 \backslash
11759 citeauthoryear{
11760 \family default
11761 \emph on
11762 author(s)
11763 \family typewriter
11764 \emph default
11765 }{
11766 \family default
11767 \emph on
11768 year
11769 \family typewriter
11770 \emph default
11771 }
11772 \family default
11773 .
11774 \end_layout
11775
11776 \begin_layout Standard
11777 The 
11778 \family typewriter
11779 kluwer.lyx
11780 \family default
11781  template takes care of all these 
11782 \begin_inset Quotes eld
11783 \end_inset
11784
11785 peculiarities
11786 \begin_inset Quotes erd
11787 \end_inset
11788
11789 .
11790  If you start a new paper using this template you don't need to do anything
11791  special.
11792  Just 
11793 \end_layout
11794
11795 \begin_layout Enumerate
11796 don't delete the TeX code included in the template, and
11797 \end_layout
11798
11799 \begin_layout Enumerate
11800 copy the example bibliography item included in the template and modify it
11801  as necessary to enter new bibliography items.
11802 \end_layout
11803
11804 \begin_layout Section
11805 Koma-Script
11806 \end_layout
11807
11808 \begin_layout Standard
11809 by 
11810 \noun on
11811 Bernd Rellermeyer
11812 \end_layout
11813
11814 \begin_layout Subsection
11815 Overview
11816 \end_layout
11817
11818 \begin_layout Standard
11819 The LyX document classes 
11820 \emph on
11821 article (koma-script)
11822 \emph default
11823
11824 \emph on
11825 report (koma-script)
11826 \emph default
11827
11828 \emph on
11829 book
11830 \emph default
11831  
11832 \emph on
11833 (koma-script)
11834 \emph default
11835 , and 
11836 \emph on
11837 letter
11838 \emph default
11839  
11840 \emph on
11841 (koma-script)
11842 \emph default
11843  correspond to the LaTeX document classes 
11844 \family typewriter
11845 scrartcl.cls
11846 \family default
11847
11848 \family typewriter
11849 scrreprt.cls
11850 \family default
11851
11852 \family typewriter
11853 scrbook.cls
11854 \family default
11855 , and 
11856 \family typewriter
11857 scrlettr.cls
11858 \family default
11859 , resp.
11860 \begin_inset space ~
11861 \end_inset
11862
11863 of the Koma-Script family.
11864  They are replacements for the standard document classes 
11865 \family typewriter
11866 article.cls
11867 \family default
11868
11869 \family typewriter
11870 report.cls
11871 \family default
11872
11873 \family typewriter
11874 book.cls
11875 \family default
11876  and 
11877 \family typewriter
11878 letter.cls
11879 \family default
11880 , resp., and fit better to European typography conventions in a number of
11881  points.
11882 \end_layout
11883
11884 \begin_layout Itemize
11885 Standard character size is 11pt in 
11886 \emph on
11887 article (koma-script)
11888 \emph default
11889
11890 \emph on
11891 report (koma-script)
11892 \emph default
11893 , and 
11894 \emph on
11895 book (koma-script)
11896 \emph default
11897 , and 12pt in 
11898 \emph on
11899 letter (koma-script)
11900 \emph default
11901 .
11902 \end_layout
11903
11904 \begin_layout Itemize
11905 Headings, labels of the description environment, and a number of elements
11906  of the 
11907 \emph on
11908 letter (koma-script)
11909 \emph default
11910  document class are set in a bold sans serif font.
11911 \begin_inset Foot
11912 status collapsed
11913
11914 \begin_layout Plain Layout
11915 There is a big difference between the bold sans serif old cm fonts and new
11916  ec fonts, especially in the appearance of headings.
11917  In comparison, the ec bold sans serif fonts look a bit thin.
11918  Here the LaTeX package 
11919 \family typewriter
11920 cmsd.sty by
11921 \family default
11922  
11923 \shape smallcaps
11924 Walter Schmidt
11925 \shape default
11926  helps to produce the 
11927 \begin_inset Quotes eld
11928 \end_inset
11929
11930 usual
11931 \begin_inset Quotes erd
11932 \end_inset
11933
11934  appearance when using the ec fonts.
11935 \end_layout
11936
11937 \end_inset
11938
11939  The numbering of chapter headings is made in the same way as the numbering
11940  of section headings, that is without the extra line 
11941 \begin_inset Quotes eld
11942 \end_inset
11943
11944 Chapter\SpecialChar \ldots{}
11945
11946 \begin_inset Quotes erd
11947 \end_inset
11948
11949 .
11950  In addition, the appearance of the headings can be modified by using a
11951  number of options (in LyX to be entered in the field 
11952 \family sans
11953 Extra
11954 \begin_inset space ~
11955 \end_inset
11956
11957 Options
11958 \family default
11959  of the dialog 
11960 \family sans
11961 Layout\SpecialChar \menuseparator
11962 Document
11963 \family default
11964 ).
11965  A detailed German description of these options can be found in the Koma-Script
11966  documentation 
11967 \emph on
11968 scrguide
11969 \emph default
11970 .
11971 \end_layout
11972
11973 \begin_layout Itemize
11974 The main means in the Koma-Script document classes to design the type area
11975  are the options 
11976 \family sans
11977 BCOR
11978 \family default
11979  and 
11980 \family sans
11981 DIV
11982 \family default
11983  (in LyX to be entered in the extra class options field in the dialog 
11984 \family sans
11985 Document\SpecialChar \menuseparator
11986 Settings
11987 \family default
11988 ).
11989  They make a clearer modification of page margins possible as do the options
11990  of the dialog 
11991 \family sans
11992 Document\SpecialChar \menuseparator
11993 Settings
11994 \family default
11995 .
11996  A detailed German description of these and other type area options can
11997  be found in the Koma-Script documentation 
11998 \emph on
11999 scrguide
12000 \emph default
12001 .
12002 \end_layout
12003
12004 \begin_layout Itemize
12005 The LaTeX document classes of the Koma-Script family define a number of
12006  additional commands.
12007  Those part of it which makes sense in LyX is implemented in corresponding
12008  paragraph types.
12009 \end_layout
12010
12011 \begin_layout Standard
12012 A detailed German description of the LaTeX document classes of the Koma-Script
12013  family can be found in the Koma-Script documentation 
12014 \emph on
12015 scrguide
12016 \emph default
12017 .
12018 \begin_inset Foot
12019 status collapsed
12020
12021 \begin_layout Plain Layout
12022 There is an English translation 
12023 \emph on
12024 screnggu
12025 \emph default
12026 , but it is not a complete one.
12027 \end_layout
12028
12029 \end_inset
12030
12031  The following sections describe only those aspects, which are relevant
12032  in LyX.
12033 \end_layout
12034
12035 \begin_layout Subsection
12036 article (koma-script), report (koma-script), and book (koma-script)
12037 \end_layout
12038
12039 \begin_layout Standard
12040 The document classes 
12041 \emph on
12042 article (koma-script)
12043 \emph default
12044
12045 \emph on
12046 report (koma-script)
12047 \emph default
12048 , and 
12049 \emph on
12050 book
12051 \emph default
12052  
12053 \emph on
12054 (koma-script)
12055 \emph default
12056  are implemented in the layout files 
12057 \family typewriter
12058 scrartcl.layout
12059 \family default
12060
12061 \family typewriter
12062 scrreprt.layout
12063 \family default
12064 , and 
12065 \family typewriter
12066 scrbook.layout
12067 \family default
12068 , resp.
12069  They contain all the paragraph types of the corresponding standard document
12070  classes 
12071 \emph on
12072 article
12073 \emph default
12074
12075 \emph on
12076 report
12077 \emph default
12078 , and 
12079 \emph on
12080 book
12081 \emph default
12082 , resp., partly modified, with the exception of the LyX specific 
12083 \family sans
12084 List
12085 \family default
12086 -type, which is replaced by the new 
12087 \family sans
12088 Labeling
12089 \family default
12090 -type having the same functionality.
12091  Beside the 
12092 \family sans
12093 Labeling
12094 \family default
12095 -Type there is a number of new paragraph types added.
12096  They are 
12097 \emph on
12098 not
12099 \emph default
12100  part of 
12101 \emph on
12102 letter (koma-script)
12103 \emph default
12104 .
12105 \end_layout
12106
12107 \begin_layout Itemize
12108
12109 \family sans
12110 Addpart, Addchap
12111 \family default
12112
12113 \family sans
12114 Addsec
12115 \family default
12116 : are equivalents to 
12117 \family sans
12118 Part*, Chapter*
12119 \family default
12120  and 
12121 \family sans
12122 Section*
12123 \family default
12124 , resp., additionally inserting an entry in the table of contents.
12125  
12126 \family sans
12127 Addpart
12128 \family default
12129  and 
12130 \family sans
12131 Addchap
12132 \family default
12133  are not contained in 
12134 \emph on
12135 article (koma-script)
12136 \emph default
12137 .
12138 \end_layout
12139
12140 \begin_layout Itemize
12141
12142 \family sans
12143 Addchap*
12144 \family default
12145
12146 \family sans
12147 Addsec*
12148 \family default
12149 : behave exactly as 
12150 \family sans
12151 Addchap
12152 \family default
12153  and 
12154 \family sans
12155 Addsec
12156 \family default
12157 , resp., additionally clearing running heads.
12158  
12159 \family sans
12160 Addchap*
12161 \family default
12162  is not contained in 
12163 \emph on
12164 article (koma-script)
12165 \emph default
12166 .
12167 \begin_inset Foot
12168 status collapsed
12169
12170 \begin_layout Plain Layout
12171 There is also an 
12172 \family typewriter
12173
12174 \backslash
12175 addpart*
12176 \family default
12177  command in 
12178 \emph on
12179 book (koma-script)
12180 \emph default
12181  and in 
12182 \emph on
12183 report (koma-script)
12184 \emph default
12185 , but since this is identical to 
12186 \family sans
12187 Part*
12188 \family default
12189 , is has not been implemented in LyX.
12190 \end_layout
12191
12192 \end_inset
12193
12194
12195 \end_layout
12196
12197 \begin_layout Itemize
12198
12199 \family sans
12200 Minisec
12201 \family default
12202 : generates a heading directly above the following paragraph in the standard
12203  character size without affecting the structure of the document.
12204 \end_layout
12205
12206 \begin_layout Itemize
12207
12208 \family sans
12209 Captionabove
12210 \family default
12211  and 
12212 \family sans
12213 Captionbelow
12214 \family default
12215  are special captions which respect the different space settings needed
12216  for captions placed above or below an element (if you follow strict typographic
12217  rules, you might want to place table captions always above the table).
12218  You can also use the class option 
12219 \family typewriter
12220 tablecaptionsabove
12221 \family default
12222 , which will switch 
12223 \family sans
12224 caption
12225 \family default
12226  to 
12227 \family sans
12228 captionabove
12229 \family default
12230  for tables and 
12231 \family sans
12232 captionbelow
12233 \family default
12234  for figures.
12235  You need at least Koma-Script version 2.8q to use this.
12236 \end_layout
12237
12238 \begin_layout Itemize
12239
12240 \family sans
12241 Dictum
12242 \family default
12243 : can be used to set a bonmot, e.
12244 \begin_inset space \thinspace{}
12245 \end_inset
12246
12247 g.
12248 \begin_inset space \space{}
12249 \end_inset
12250
12251 at the beginning of a chapter.
12252  If you use the optional argument (
12253 \family sans
12254 Insert\SpecialChar \menuseparator
12255 Short
12256 \begin_inset space ~
12257 \end_inset
12258
12259 Title
12260 \family default
12261 ), you can insert the dictum's author there.
12262  Dictum and author are separated by a line.
12263  You need at least Koma-Script version 2.8q to use this.
12264  
12265 \family sans
12266 Dictum
12267 \family default
12268  is not contained in 
12269 \emph on
12270 article (koma-script)
12271 \emph default
12272 .
12273 \end_layout
12274
12275 \begin_layout Standard
12276 The following types, together with the standard types 
12277 \family sans
12278 Title
12279 \family default
12280
12281 \family sans
12282 Author
12283 \family default
12284 , and 
12285 \family sans
12286 Date
12287 \family default
12288 , form the title area of the document.
12289  They must be entered ahead of the first 
12290 \begin_inset Quotes eld
12291 \end_inset
12292
12293 ordinary
12294 \begin_inset Quotes erd
12295 \end_inset
12296
12297  paragraph.
12298 \begin_inset Foot
12299 status collapsed
12300
12301 \begin_layout Plain Layout
12302 The corresponding LaTeX commands must appear before the 
12303 \family typewriter
12304
12305 \backslash
12306 maketitle
12307 \family default
12308  command.
12309 \end_layout
12310
12311 \end_inset
12312
12313  When such a type is used more than once, the latter usage overwrites the
12314  former one, that means, for every type only the latest usage is valid.
12315  The order of the different types however has, like 
12316 \family sans
12317 Title
12318 \family default
12319
12320 \family sans
12321 Author
12322 \family default
12323 , and 
12324 \family sans
12325 Date
12326 \family default
12327 , no effect on the appearance of the produced document.
12328 \end_layout
12329
12330 \begin_layout Itemize
12331
12332 \family sans
12333 Subject
12334 \family default
12335 : produces a centered paragraph above the ordinary title (
12336 \family sans
12337 Title
12338 \family default
12339
12340 \family sans
12341 Author
12342 \family default
12343
12344 \family sans
12345 Date
12346 \family default
12347 ) for the subject of the document.
12348 \end_layout
12349
12350 \begin_layout Itemize
12351
12352 \family sans
12353 Publishers
12354 \family default
12355 : produces a centered paragraph below the ordinary title (
12356 \family sans
12357 Title
12358 \family default
12359
12360 \family sans
12361 Author
12362 \family default
12363
12364 \family sans
12365 Date
12366 \family default
12367 ) for the publishers' name.
12368 \end_layout
12369
12370 \begin_layout Itemize
12371
12372 \family sans
12373 Dedication
12374 \family default
12375 : in 
12376 \emph on
12377 report (koma-script)
12378 \emph default
12379  and 
12380 \emph on
12381 book (koma-script)
12382 \emph default
12383  produces a centered paragraph on its own page behind the title page, or
12384  in 
12385 \emph on
12386 article (koma-script)
12387 \emph default
12388  produces a centered paragraph below the ordinary title (
12389 \family sans
12390 Title
12391 \family default
12392
12393 \family sans
12394 Author
12395 \family default
12396
12397 \family sans
12398 Date
12399 \family default
12400
12401 \family sans
12402 Publishers
12403 \family default
12404 ) for a dedication.
12405 \end_layout
12406
12407 \begin_layout Itemize
12408
12409 \family sans
12410 Titlehead
12411 \family default
12412 : produces a left aligned paragraph above the ordinary title (
12413 \family sans
12414 Title
12415 \family default
12416
12417 \family sans
12418 Author
12419 \family default
12420
12421 \family sans
12422 Date
12423 \family default
12424
12425 \family sans
12426 Subject
12427 \family default
12428 ) for a document`s head.
12429 \end_layout
12430
12431 \begin_layout Itemize
12432
12433 \family sans
12434 Uppertitleback
12435 \family default
12436 : produces in a double-sided print in 
12437 \emph on
12438 report (koma-script)
12439 \emph default
12440  and 
12441 \emph on
12442 book (koma-script)
12443 \emph default
12444  a left-aligned paragraph at the top of the title page`s back or has no
12445  effect in a single-sided print or in 
12446 \emph on
12447 article (koma-script)
12448 \emph default
12449 .
12450 \end_layout
12451
12452 \begin_layout Itemize
12453
12454 \family sans
12455 Lowertitleback
12456 \family default
12457 : produces in a double-sided print in 
12458 \emph on
12459 report (koma-script)
12460 \emph default
12461  and 
12462 \emph on
12463 book (koma-script)
12464 \emph default
12465  a left-aligned paragraph at the bottom of the title page`s back or has
12466  no effect in a single-sided print or in 
12467 \emph on
12468 article (koma-script)
12469 \emph default
12470 .
12471 \end_layout
12472
12473 \begin_layout Itemize
12474
12475 \family sans
12476 Extratitle
12477 \family default
12478 : produces a special 
12479 \begin_inset Quotes eld
12480 \end_inset
12481
12482 dirty
12483 \begin_inset Quotes erd
12484 \end_inset
12485
12486  page ahead of the actual document containing a paragraph without special
12487  formatting.
12488 \end_layout
12489
12490 \begin_layout Standard
12491 The layout files for the document classes 
12492 \emph on
12493 article (koma-script)
12494 \emph default
12495
12496 \emph on
12497 report (koma-script)
12498 \emph default
12499 , and 
12500 \emph on
12501 book (koma-script)
12502 \emph default
12503  do include the file 
12504 \family typewriter
12505 scrmacros.inc
12506 \family default
12507 .
12508  This is thought of as a place to define your own types.
12509  Copy scrmacros
12510 \family typewriter
12511 .inc
12512 \family default
12513  in your personal layout directory and edit the file!
12514 \end_layout
12515
12516 \begin_layout Subsection
12517 letter (koma-script)
12518 \end_layout
12519
12520 \begin_layout Standard
12521 \begin_inset ERT
12522 status open
12523
12524 \begin_layout Plain Layout
12525
12526
12527 \backslash
12528 begin{sloppypar}
12529 \end_layout
12530
12531 \end_inset
12532
12533
12534 \end_layout
12535
12536 \begin_layout Standard
12537 \noindent
12538 The document class 
12539 \emph on
12540 letter (koma-script)
12541 \emph default
12542  is implemented in the layout file 
12543 \family typewriter
12544 scrlettr.layout
12545 \family default
12546 .
12547  It contains all the paragraph types of the corresponding standard document
12548  class 
12549 \emph on
12550 letter
12551 \emph default
12552 , partly modified, with the exception of the LyX specific types 
12553 \family sans
12554 LyX-Code
12555 \family default
12556  and 
12557 \family sans
12558 Comment
12559 \family default
12560  and the 
12561 \family sans
12562 List
12563 \family default
12564  type, which is replaced by the new 
12565 \family sans
12566 Labeling
12567 \family default
12568  type.
12569  In addition, it contains, in contrast to the standard document class, the
12570  standard types 
12571 \family sans
12572 LaTeX
12573 \family default
12574
12575 \family sans
12576 Quotation
12577 \family default
12578
12579 \family sans
12580 Quote
12581 \family default
12582 , and 
12583 \family sans
12584 Verse
12585 \family default
12586 .
12587  Furthermore, there are a number of new letter specific types.
12588 \end_layout
12589
12590 \begin_layout Standard
12591 \begin_inset ERT
12592 status open
12593
12594 \begin_layout Plain Layout
12595
12596
12597 \backslash
12598 end{sloppypar}
12599 \end_layout
12600
12601 \end_inset
12602
12603
12604 \end_layout
12605
12606 \begin_layout Standard
12607 The appearance of the letter produced by this document class can be controlled
12608  by a number of LaTeX commands, which you can put in the LaTeX preamble.
12609 \begin_inset Foot
12610 status collapsed
12611
12612 \begin_layout Plain Layout
12613 For example, the standard appearance of the letter`s heading, consisting
12614  of name and address, is quite self-willed.
12615  An 
12616 \begin_inset Quotes eld
12617 \end_inset
12618
12619 ordinary
12620 \begin_inset Quotes erd
12621 \end_inset
12622
12623  heading is produced by the following LaTeX commands in the preamble:
12624 \end_layout
12625
12626 \begin_layout LyX-Code
12627
12628 \backslash
12629 firsthead{
12630 \backslash
12631 parbox[b]{
12632 \backslash
12633 textwidth}
12634 \end_layout
12635
12636 \begin_layout LyX-Code
12637   {
12638 \backslash
12639 ignorespaces 
12640 \backslash
12641 fromname
12642 \backslash
12643
12644 \backslash
12645  
12646 \backslash
12647 ignorespaces 
12648 \backslash
12649 fromaddress}} 
12650 \end_layout
12651
12652 \begin_layout LyX-Code
12653
12654 \backslash
12655 nexthead{
12656 \backslash
12657 parbox[b]{
12658 \backslash
12659 textwidth}
12660 \end_layout
12661
12662 \begin_layout LyX-Code
12663   {
12664 \backslash
12665 ignorespaces 
12666 \backslash
12667 fromname 
12668 \backslash
12669 hfill 
12670 \backslash
12671 ignorespaces 
12672 \backslash
12673 pagename
12674 \backslash
12675  
12676 \backslash
12677 thepage}}
12678 \end_layout
12679
12680 \end_inset
12681
12682  A detailed German description of such LaTeX commands can be found in the
12683  Koma-Script documentation 
12684 \emph on
12685 scrguide
12686 \emph default
12687 .
12688  With it, the letter's author can produce his personal letter layout.
12689 \end_layout
12690
12691 \begin_layout Standard
12692 The types 
12693 \family sans
12694 Letter
12695 \family default
12696  and 
12697 \family sans
12698 Opening
12699 \family default
12700  define the beginning of the letter and must be used in every letter.
12701  To emphasize them in the LyX document class, they are marked with the letter
12702  
12703 \shape italic
12704 L
12705 \shape default
12706  or 
12707 \shape italic
12708 O
12709 \shape default
12710 , resp.
12711 \begin_inset space ~
12712 \end_inset
12713
12714 in the left margin.
12715  It is possible to write any number of letters in one file.
12716  An 
12717 \family sans
12718 Opening
12719 \family default
12720  type produces a new letter using the same addressee and a 
12721 \family sans
12722 Letter
12723 \family default
12724  type produces a new addressee.
12725  The types 
12726 \family sans
12727 Closing
12728 \family default
12729
12730 \family sans
12731 PS
12732 \family default
12733
12734 \family sans
12735 CC
12736 \family default
12737 , and 
12738 \family sans
12739 Encl
12740 \family default
12741  are ordinary paragraph types and can also be used several times in one
12742  and the same letter.
12743 \end_layout
12744
12745 \begin_layout Itemize
12746
12747 \family sans
12748 Letter
12749 \family default
12750 : produces a paragraph for the addressee and implicitly defines the beginning
12751  of the letter.
12752 \end_layout
12753
12754 \begin_layout Itemize
12755
12756 \family sans
12757 Opening
12758 \family default
12759 : produces a paragraph for the form of address and implicitly produces a
12760  new letter.
12761 \end_layout
12762
12763 \begin_layout Itemize
12764
12765 \family sans
12766 Closing
12767 \family default
12768 : produces a paragraph for a close.
12769 \end_layout
12770
12771 \begin_layout Itemize
12772
12773 \family sans
12774 PS
12775 \family default
12776 : produces a paragraph for a postscript.
12777 \end_layout
12778
12779 \begin_layout Itemize
12780
12781 \family sans
12782 CC
12783 \family default
12784 : produces a paragraph for a distribution list.
12785 \end_layout
12786
12787 \begin_layout Itemize
12788
12789 \family sans
12790 Encl
12791 \family default
12792 : produces a paragraph for enclosures.
12793 \end_layout
12794
12795 \begin_layout Standard
12796 The types 
12797 \family sans
12798 Name
12799 \family default
12800
12801 \family sans
12802 Signature
12803 \family default
12804
12805 \family sans
12806 Address
12807 \family default
12808
12809 \family sans
12810 Telephone
12811 \family default
12812
12813 \family sans
12814 Place
12815 \family default
12816
12817 \family sans
12818 Backaddress
12819 \family default
12820
12821 \family sans
12822 Specialmail
12823 \family default
12824
12825 \family sans
12826 Location
12827 \family default
12828
12829 \family sans
12830 Title
12831 \family default
12832 , and 
12833 \family sans
12834 Subject
12835 \family default
12836  are input types provided with a label to enter information, which will
12837  be processed by the document class.
12838 \begin_inset Foot
12839 status open
12840
12841 \begin_layout Plain Layout
12842 It could be seen as a matter of inconsequence, that the types 
12843 \family sans
12844 Letter
12845 \family default
12846  and 
12847 \family sans
12848 Opening
12849 \family default
12850  described above are not such input types as well.
12851  Because of the special meaning of those types, however, I have implemented
12852  them as ordinary paragraph types with a one letter mark in the left margin.
12853  Moreover, it would affect my feeling of symmetry, if the 
12854 \family sans
12855 Opening
12856 \family default
12857  type and the 
12858 \family sans
12859 Closing
12860 \family default
12861  type had such a serious different appearance.
12862 \end_layout
12863
12864 \end_inset
12865
12866  The types must be used ahead of the corresponding 
12867 \family sans
12868 Opening
12869 \family default
12870  type.
12871 \end_layout
12872
12873 \begin_layout Standard
12874 An implementation of these types in a WYSIWYG fashion does not seem to make
12875  sense, because the real appearance of the produced letter does not only
12876  depend on the usage of the particular type, but also on other factors.
12877  For example, a signature entered in the 
12878 \family sans
12879 Signature
12880 \family default
12881  type will in the standard behavior appear in the produced letter only,
12882  when in the same letter also a 
12883 \family sans
12884 Closing
12885 \family default
12886  type is used.
12887  The entered value of the 
12888 \family sans
12889 Telephone
12890 \family default
12891  type will in the standard behavior not appear in the produced letter at
12892  all.
12893  The possibility to design the letter`s heading freely is already indicated
12894  in a footnote above.
12895 \end_layout
12896
12897 \begin_layout Standard
12898 The input types can also be used as empty paragraphs.
12899  This makes sense e.
12900 \begin_inset space \thinspace{}
12901 \end_inset
12902
12903 g.
12904 \begin_inset space \space{}
12905 \end_inset
12906
12907 for the 
12908 \family sans
12909 Signature
12910 \family default
12911  type.
12912  If the 
12913 \family sans
12914 Signature
12915 \family default
12916  type is not used at all, in the standard behavior the value of the 
12917 \family sans
12918 Name
12919 \family default
12920  type is used as signature, whereas if an empty 
12921 \family sans
12922 Signature
12923 \family default
12924  type is used, no signature value is defined.
12925 \end_layout
12926
12927 \begin_layout Standard
12928 By using the input types it is possible to write a letter template, containing
12929  filled input types with your personal dates (name, address, etc.) and empty
12930  input types for other dates you want to enter.
12931 \end_layout
12932
12933 \begin_layout Itemize
12934
12935 \family sans
12936 Name
12937 \family default
12938 : sender's name, in the standard behavior appears as a centered paragraph
12939  in small caps in the letter`s heading.
12940 \end_layout
12941
12942 \begin_layout Itemize
12943
12944 \family sans
12945 Signature
12946 \family default
12947 : sender's signature, in the standard behavior appears below the 
12948 \family sans
12949 Closing
12950 \family default
12951  type.
12952  If no 
12953 \family sans
12954 Signature
12955 \family default
12956  type is used, the value of the 
12957 \family sans
12958 Name
12959 \family default
12960  type appears instead.
12961 \end_layout
12962
12963 \begin_layout Itemize
12964
12965 \family sans
12966 Address
12967 \family default
12968 : sender's address, in the standard behavior appears in a centered paragraph
12969  in the letter`s heading below the sender's name.
12970 \end_layout
12971
12972 \begin_layout Itemize
12973
12974 \family sans
12975 Telephone
12976 \family default
12977 : sender's telephone number, in the standard behavior only sets the LaTeX
12978  variable 
12979 \family typewriter
12980
12981 \backslash
12982 telephonenum
12983 \family default
12984 .
12985 \end_layout
12986
12987 \begin_layout Itemize
12988
12989 \family sans
12990 Place
12991 \family default
12992 : place of the letter`s making.
12993 \end_layout
12994
12995 \begin_layout Itemize
12996
12997 \family sans
12998 Date
12999 \family default
13000 : date of the letter`s making.
13001  
13002 \family sans
13003 Place
13004 \family default
13005  and 
13006 \family sans
13007 Date
13008 \family default
13009 , in the standard behavior, produce the place and the date in a right-aligned
13010  line below the addressee's field.
13011  If an empty 
13012 \family sans
13013 Date
13014 \family default
13015  type is used, neither place nor date appear, independent of the value of
13016  the 
13017 \family sans
13018 Place
13019 \family default
13020  type.
13021  If no 
13022 \family sans
13023 Date
13024 \family default
13025  type is used, the date of the letter `s production is used.
13026 \end_layout
13027
13028 \begin_layout Itemize
13029
13030 \family sans
13031 Backaddress
13032 \family default
13033 : sender`s back address, in the standard behavior appears above the addressee's
13034  field in a small sans serif font.
13035 \end_layout
13036
13037 \begin_layout Itemize
13038
13039 \family sans
13040 Specialmail
13041 \family default
13042 : special mail information, in the standard behavior appears underlined
13043  above the addressee's field below the back address.
13044 \end_layout
13045
13046 \begin_layout Itemize
13047
13048 \family sans
13049 Location
13050 \family default
13051 : additional information, in the standard behavior appears on right side
13052  below the addressee`s field.
13053 \end_layout
13054
13055 \begin_layout Itemize
13056
13057 \family sans
13058 Title
13059 \family default
13060 : the letter's title, in the standard behavior appears in a big, bold, sans
13061  serif font above the subject.
13062 \end_layout
13063
13064 \begin_layout Itemize
13065
13066 \family sans
13067 Subject
13068 \family default
13069 : the letter's subject, in the standard behavior appears in a bold font
13070  above the 
13071 \family sans
13072 Opening
13073 \family default
13074  paragraph.
13075 \end_layout
13076
13077 \begin_layout Standard
13078 The types 
13079 \family sans
13080 Yourref
13081 \family default
13082
13083 \family sans
13084 Yourmail
13085 \family default
13086
13087 \family sans
13088 Myref
13089 \family default
13090
13091 \family sans
13092 Customer
13093 \family default
13094 , and 
13095 \family sans
13096 Invoice
13097 \family default
13098  produce a business letter like line above the 
13099 \family sans
13100 Title
13101 \family default
13102  line containing the fields 
13103 \begin_inset Quotes eld
13104 \end_inset
13105
13106 Your ref.
13107 \begin_inset Quotes erd
13108 \end_inset
13109
13110
13111 \begin_inset Quotes eld
13112 \end_inset
13113
13114 Your letter of
13115 \begin_inset Quotes erd
13116 \end_inset
13117
13118
13119 \begin_inset Quotes eld
13120 \end_inset
13121
13122 Our ref.
13123 \begin_inset Quotes erd
13124 \end_inset
13125
13126
13127 \begin_inset Quotes eld
13128 \end_inset
13129
13130 Customer no.
13131 \begin_inset Quotes erd
13132 \end_inset
13133
13134
13135 \begin_inset Quotes eld
13136 \end_inset
13137
13138 Invoice no.
13139 \begin_inset Quotes erd
13140 \end_inset
13141
13142 , and 
13143 \begin_inset Quotes eld
13144 \end_inset
13145
13146 Date
13147 \begin_inset Quotes erd
13148 \end_inset
13149
13150 .
13151  For the date field, the value of the 
13152 \family sans
13153 Date
13154 \family default
13155  type is used.
13156  If one of these 
13157 \begin_inset Quotes eld
13158 \end_inset
13159
13160 business letter types
13161 \begin_inset Quotes erd
13162 \end_inset
13163
13164  is used, the value of the 
13165 \family sans
13166 Place
13167 \family default
13168  type however does not appear, but only the LaTeX variable 
13169 \family typewriter
13170
13171 \backslash
13172 fromplace
13173 \family default
13174  is set.
13175  The ordinary output of place and date in a right-aligned line below the
13176  addressee`s field is suppressed.
13177  The types are implemented as input types provided with a label and must
13178  be used ahead of the corresponding 
13179 \family sans
13180 Opening
13181 \family default
13182  type.
13183 \end_layout
13184
13185 \begin_layout Itemize
13186
13187 \family sans
13188 Yourref
13189 \family default
13190 : Your ref.
13191 \end_layout
13192
13193 \begin_layout Itemize
13194
13195 \family sans
13196 Yourmail
13197 \family default
13198 : Your letter of.
13199 \end_layout
13200
13201 \begin_layout Itemize
13202
13203 \family sans
13204 Myref
13205 \family default
13206 : Our ref.
13207 \end_layout
13208
13209 \begin_layout Itemize
13210
13211 \family sans
13212 Customer
13213 \family default
13214 : Customer no.
13215 \end_layout
13216
13217 \begin_layout Itemize
13218
13219 \family sans
13220 Invoice
13221 \family default
13222 : Invoice no.
13223 \end_layout
13224
13225 \begin_layout Subsection
13226 The new letter class: letter (koma-script v.2)
13227 \end_layout
13228
13229 \begin_layout Standard
13230 by 
13231 \noun on
13232 Jürgen Spitzmüller
13233 \end_layout
13234
13235 \begin_layout Standard
13236 \begin_inset VSpace medskip
13237 \end_inset
13238
13239
13240 \end_layout
13241
13242 \begin_layout Standard
13243 \noindent
13244 Koma-Script version 2.8 has introduced a new letter class 
13245 \family typewriter
13246 scrlttr2
13247 \family default
13248  which supersedes the now unsupported 
13249 \family typewriter
13250 scrlettr
13251 \family default
13252 .
13253  It has â€” on the LaTeX side â€” a completely new interface and is not compatible
13254  with the old class.
13255  Therefore, LyX supports both, though it is recommended to use the new class.
13256 \end_layout
13257
13258 \begin_layout Standard
13259 This class covers the same functionality as 
13260 \emph on
13261 letter (koma-script),
13262 \emph default
13263  and a few more.
13264  The basic items are 
13265 \family sans
13266 Address
13267 \family default
13268  (receiver's address, same as 
13269 \family sans
13270 Letter
13271 \family default
13272  in the old layout), 
13273 \family sans
13274 Opening
13275 \family default
13276 , and 
13277 \family sans
13278 Closing
13279 \family default
13280 .
13281  
13282 \family sans
13283 NextAddress
13284 \family default
13285  will start a new letter (i.
13286 \begin_inset space \thinspace{}
13287 \end_inset
13288
13289 g.
13290 \begin_inset space \space{}
13291 \end_inset
13292
13293 you can write several letters per document).
13294  New elements are sender's 
13295 \family sans
13296 E-Mail
13297 \family default
13298
13299 \family sans
13300 URL
13301 \family default
13302
13303 \family sans
13304 Fax
13305 \family default
13306
13307 \family sans
13308 Bank
13309 \family default
13310  and the possibility to use a 
13311 \family sans
13312 Logo
13313 \family default
13314  (via 
13315 \family sans
13316 Insert\SpecialChar \menuseparator
13317 Graphics
13318 \family default
13319 ) in the header.
13320 \end_layout
13321
13322 \begin_layout Standard
13323 The biggest improvement is, though, that the letter's layout is configurable
13324  at almost any needs.
13325  This can be done via the preamble or with a special style file (Letter
13326  Class Option, extension 
13327 \family typewriter
13328 *.lco
13329 \family default
13330 ), that will be read in as a class option.
13331 \begin_inset Foot
13332 status collapsed
13333
13334 \begin_layout Plain Layout
13335 The KOMA package comes with some default 
13336 \family typewriter
13337 *.lco
13338 \family default
13339  files.
13340  There is, for instance, a 
13341 \family typewriter
13342 DIN.lco
13343 \family default
13344  file that follows german typesetting rules, or a 
13345 \family typewriter
13346 KOMAold.lco
13347 \family default
13348  that provides the default layout of the old 
13349 \family typewriter
13350 scrlettr
13351 \family default
13352  class.
13353  The latter can be loaded with the class option 
13354 \family typewriter
13355 KOMAold
13356 \family default
13357 , inserted via the 
13358 \family sans
13359 \bar under
13360 L
13361 \bar default
13362 ayout\SpecialChar \menuseparator
13363
13364 \bar under
13365 D
13366 \bar default
13367 ocument\SpecialChar \menuseparator
13368 Extra Options
13369 \family default
13370  field.
13371 \end_layout
13372
13373 \end_inset
13374
13375  Have a look at the 
13376 \emph on
13377 koma-letter2
13378 \emph default
13379  template that is included in LyX for examples.
13380  A detailed description is to be found in the Koma-Script documentation
13381  (
13382 \emph on
13383 scrguide
13384 \emph default
13385 ).
13386 \end_layout
13387
13388 \begin_layout Subsection
13389 Problems
13390 \end_layout
13391
13392 \begin_layout Standard
13393 Visualizing the Koma-Script document classes in LyX, the LyX internals cause
13394  some problems.
13395 \end_layout
13396
13397 \begin_layout Itemize
13398 The chapter number of a 
13399 \family sans
13400 Chapter
13401 \family default
13402  type appears on a line of its own above the chapter heading instead of
13403  appearing in the same line ahead of it.
13404  The cause for that is the LyX internal behavior for the labeltype 
13405 \family sans
13406 Counter_Chapter
13407 \family default
13408  in the layout file.
13409 \end_layout
13410
13411 \begin_layout Itemize
13412 The headings of the types 
13413 \family sans
13414 Addchap
13415 \family default
13416  and 
13417 \family sans
13418 Addsec
13419 \family default
13420  are only put in the 
13421 \begin_inset Quotes eld
13422 \end_inset
13423
13424 true
13425 \begin_inset Quotes erd
13426 \end_inset
13427
13428  LaTeX table of contents, but not in the LyX table of contents (
13429 \family sans
13430 Document\SpecialChar \menuseparator
13431 Table
13432 \begin_inset space ~
13433 \end_inset
13434
13435 of
13436 \begin_inset space ~
13437 \end_inset
13438
13439 Contents
13440 \family default
13441 ).
13442 \end_layout
13443
13444 \begin_layout Itemize
13445 The paragraphs in a 
13446 \emph on
13447 letter
13448 \emph default
13449  document class appear in a skip separation mode, not indented.
13450  This is the standard behavior, no special LaTeX commands are needed for
13451  that.
13452  But in the 
13453 \family sans
13454 Document\SpecialChar \menuseparator
13455 Settings
13456 \family default
13457  dialog the corresponding radio button indicates 
13458 \family sans
13459 Indent
13460 \family default
13461 .
13462  A 
13463 \family sans
13464 Skip
13465 \family default
13466  value always has the effect that extra LaTeX commands are inserted in the
13467  document to produce the gap, which is not what is wanted in this case.
13468 \end_layout
13469
13470 \begin_layout Section
13471 Latex8 (IEEE Conference Papers)
13472 \end_layout
13473
13474 \begin_layout Standard
13475 by 
13476 \noun on
13477 Allan Rae
13478 \end_layout
13479
13480 \begin_layout Subsection
13481 Introduction
13482 \end_layout
13483
13484 \begin_layout Standard
13485 Since this class is specifically for writing submissions to IEEE sponsored
13486  conferences I strongly recommend that you get a copy of their Authors Kit.
13487  The 
13488 \family sans
13489 latex.sty
13490 \family default
13491  package and associated bibliography style file is included in the kit.
13492  The Authors Kit is usually sent out by email once your initial submission
13493  has been accepted.
13494  There is a lot of useful information in the Authors Kit explaining formatting
13495  restrictions and so on and I will assume you have read this since that
13496  means I don't have to repeat it all here.
13497 \end_layout
13498
13499 \begin_layout Subsection
13500 Getting Started
13501 \end_layout
13502
13503 \begin_layout Standard
13504 [AR\SpecialChar \@.
13505  more to come]
13506 \end_layout
13507
13508 \begin_layout Subsection
13509 Supported Environments
13510 \end_layout
13511
13512 \begin_layout Itemize
13513
13514 \family sans
13515 Standard
13516 \end_layout
13517
13518 \begin_layout Itemize
13519
13520 \family sans
13521 Title
13522 \end_layout
13523
13524 \begin_layout Itemize
13525
13526 \family sans
13527 Author
13528 \end_layout
13529
13530 \begin_layout Itemize
13531
13532 \family sans
13533 E-mail
13534 \end_layout
13535
13536 \begin_layout Itemize
13537
13538 \family sans
13539 Affiliation
13540 \end_layout
13541
13542 \begin_layout Itemize
13543
13544 \family sans
13545 Abstract
13546 \end_layout
13547
13548 \begin_layout Itemize
13549
13550 \family sans
13551 Section
13552 \end_layout
13553
13554 \begin_layout Itemize
13555
13556 \family sans
13557 SubSection
13558 \end_layout
13559
13560 \begin_layout Itemize
13561
13562 \family sans
13563 Caption
13564 \end_layout
13565
13566 \begin_layout Subsection
13567 Differences Between Screen and Paper
13568 \end_layout
13569
13570 \begin_layout Standard
13571 There are slight differences in appearance mainly with the presentation
13572  of section counters.
13573  On screen the trailing period of the section counter is missing but it
13574  will appear in the output so don't let this worry you.
13575 \end_layout
13576
13577 \begin_layout Section
13578 Memoir
13579 \end_layout
13580
13581 \begin_layout Standard
13582 By 
13583 \noun on
13584 Jürgen Spitzmüller
13585 \end_layout
13586
13587 \begin_layout Subsection
13588 Overview
13589 \end_layout
13590
13591 \begin_layout Standard
13592 Memoir is a very powerful and constantly evolving class.
13593  It has been designed with regard to fictional and non-fictional literature.
13594  Its aim is to let the user have maximum control over the typesetting of
13595  his document.
13596  Memoir is based on the standard book class, but it can also emulate the
13597  article class (see below).
13598 \end_layout
13599
13600 \begin_layout Standard
13601 Peter Wilson, the developer of Memoir, is known as the author of lots of
13602  useful packages in the LaTeX world.
13603  Most of them have been merged with Memoir.
13604  Therefore, it is much easier to layout the table of contents, appendices,
13605  chapter designs and such.
13606  LyX, though, does not support all of these goodies natively.
13607  Some of them might be added to forthcoming releases
13608 \begin_inset Foot
13609 status collapsed
13610
13611 \begin_layout Plain Layout
13612 You are invited to send suggestions to 
13613 \begin_inset Flex URL
13614 status collapsed
13615
13616 \begin_layout Plain Layout
13617
13618 lyx-devel@lists.lyx.org
13619 \end_layout
13620
13621 \end_inset
13622
13623 .
13624 \end_layout
13625
13626 \end_inset
13627
13628 , lots will probably never, due to the limitations of LyX's framework.
13629  Of course you can still use all features with the help of some native LaTeX
13630  commands (TeX code
13631 \begin_inset Foot
13632 status collapsed
13633
13634 \begin_layout Plain Layout
13635 Cf.
13636 \begin_inset ERT
13637 status collapsed
13638
13639 \begin_layout Plain Layout
13640
13641
13642 \backslash
13643  
13644 \end_layout
13645
13646 \end_inset
13647
13648 section
13649 \begin_inset space ~
13650 \end_inset
13651
13652
13653 \begin_inset CommandInset ref
13654 LatexCommand ref
13655 reference "sec:Inserting-TeX-Code"
13656
13657 \end_inset
13658
13659  for details.
13660 \end_layout
13661
13662 \end_inset
13663
13664 ).
13665  In this section, we can only list those features which are natively supported
13666  by LyX.
13667  For detailed descriptions (and for the rest of features) we are recommending
13668  to have a look at the detailed manual of the Memoir class
13669 \begin_inset Foot
13670 status collapsed
13671
13672 \begin_layout Plain Layout
13673 Cf.
13674 \begin_inset ERT
13675 status collapsed
13676
13677 \begin_layout Plain Layout
13678
13679
13680 \backslash
13681  
13682 \end_layout
13683
13684 \end_inset
13685
13686
13687 \begin_inset Flex URL
13688 status collapsed
13689
13690 \begin_layout Plain Layout
13691
13692 CTAN:/macros/latex/memoir/memman.pdf
13693 \end_layout
13694
13695 \end_inset
13696
13697 .
13698 \end_layout
13699
13700 \end_inset
13701
13702 , which is not only a user guide for the class, but also both a comprehensive
13703  description on good typesetting and a superb example for good typesetting
13704  itself.
13705 \end_layout
13706
13707 \begin_layout Subsection
13708 Basic features and restrictions
13709 \end_layout
13710
13711 \begin_layout Standard
13712 Memoir supports basically all features of the standard book classes.
13713  There are, however, some differences, as follows:
13714 \end_layout
13715
13716 \begin_layout Description
13717 Font
13718 \begin_inset space ~
13719 \end_inset
13720
13721 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
13722 \end_layout
13723
13724 \begin_layout Description
13725 Page
13726 \begin_inset space ~
13727 \end_inset
13728
13729 style: The fancy page style is not supported, due to a command clash between
13730  Memoir and the fancyhdr package (they are both defining a command with
13731  the same name, which confuses LaTeX).
13732  Instead, Memoir comes with a bunch of own page styles (see 
13733 \family sans
13734 Layout\SpecialChar \menuseparator
13735 Document\SpecialChar \menuseparator
13736 Page
13737 \begin_inset space ~
13738 \end_inset
13739
13740 Style
13741 \family default
13742 ).
13743  If you want to use these for the chapter pages, you have to use the command
13744  
13745 \family typewriter
13746
13747 \backslash
13748 chapterstyle
13749 \family default
13750  in the main text or in preamble (e.
13751 \begin_inset space \thinspace{}
13752 \end_inset
13753
13754 g.
13755 \begin_inset space \space{}
13756 \end_inset
13757
13758
13759 \family typewriter
13760
13761 \backslash
13762 chapterstyle{companion}
13763 \family default
13764 ).
13765 \end_layout
13766
13767 \begin_layout Description
13768 Sectioning: Sectionings (chapter, section, subsection etc.) are coming with
13769  an optional argument in the standard classes.
13770  With this, you can specify an alternative version of the title for the
13771  table of contents and the headers (for instance, if the title is too long).
13772  In LyX, you can do this via 
13773 \family sans
13774 Insert\SpecialChar \menuseparator
13775 Short
13776 \begin_inset space ~
13777 \end_inset
13778
13779 Title
13780 \family default
13781  at the beginning of a chapter/section.
13782  Memoir features a second optional argument and thus separates the table
13783  of contents from the header.
13784  You can define three variants of a title with this: one for the main text,
13785  one for the table of contents, and one for the headers.
13786  Simply insert two optional arguments if you need this feature, the first
13787  one containing the short title for the Table of Contents, the second one
13788  containing an alternative short title for the headers.
13789 \end_layout
13790
13791 \begin_layout Description
13792 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
13793  of contents, the list of figures and the list of table start a new page
13794  automatically.
13795  Memoir does not follow this route.
13796  You have to insert a page break yourself, if you want to have one.
13797 \end_layout
13798
13799 \begin_layout Description
13800 Titlepage: For some unknown reason, Memoir uses pagination on the title
13801  page (in the standard classes, title pages are 
13802 \begin_inset Quotes eld
13803 \end_inset
13804
13805 empty
13806 \begin_inset Quotes erd
13807 \end_inset
13808
13809 , i.
13810 \begin_inset space \thinspace{}
13811 \end_inset
13812
13813 g.
13814 \begin_inset space \space{}
13815 \end_inset
13816
13817 without pagina).
13818  If you want an empty title page, type 
13819 \family typewriter
13820
13821 \backslash
13822 aliaspagestyle{title}{empty}
13823 \family default
13824  in the preamble.
13825 \end_layout
13826
13827 \begin_layout Description
13828 Article: With the class option 
13829 \emph on
13830 article
13831 \emph default
13832  (to be inserted in 
13833 \family sans
13834 Layout\SpecialChar \menuseparator
13835 Document\SpecialChar \menuseparator
13836 Extra
13837 \begin_inset space ~
13838 \end_inset
13839
13840 Options
13841 \family default
13842 ), you can emulate article style.
13843  That is, counters (footnotes, figures, tables etc.) will not be reset on
13844  new chapters, chapters don't start a new page (but are—in contrary to 
13845 \begin_inset Quotes eld
13846 \end_inset
13847
13848 real
13849 \begin_inset Quotes erd
13850 \end_inset
13851
13852  article classes—still allowed), parts, though, use their own page, as in
13853  book.
13854 \end_layout
13855
13856 \begin_layout Description
13857 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
13858  font commands, which have been used in the old LaTeX version 2.09 (e.
13859 \begin_inset space \thinspace{}
13860 \end_inset
13861
13862 g.
13863 \begin_inset space \space{}
13864 \end_inset
13865
13866
13867 \family typewriter
13868
13869 \backslash
13870 rm
13871 \family default
13872
13873 \family typewriter
13874
13875 \backslash
13876 it
13877 \family default
13878 ).
13879  It produces an error and stops LaTeX whenever such a command appears.
13880  The class option 
13881 \emph on
13882 oldfontcommands
13883 \emph default
13884  reallows the commands and spits out warnings instead (which does at least
13885  not stop LaTeX).
13886  Since a lot of packages and particularly BibTeX style files are still using
13887  those commands, we have decided to use this option by default.
13888 \end_layout
13889
13890 \begin_layout Subsection
13891 Extra features
13892 \end_layout
13893
13894 \begin_layout Standard
13895 We will only describe the features supported by LyX (which is not much currently
13896 ).
13897  Please consult the Memoir manual
13898 \begin_inset Foot
13899 status collapsed
13900
13901 \begin_layout Plain Layout
13902 Cf.
13903 \begin_inset ERT
13904 status collapsed
13905
13906 \begin_layout Plain Layout
13907
13908
13909 \backslash
13910  
13911 \end_layout
13912
13913 \end_inset
13914
13915
13916 \begin_inset Flex URL
13917 status collapsed
13918
13919 \begin_layout Plain Layout
13920
13921 CTAN:/macros/latex/memoir/memman.pdf
13922 \end_layout
13923
13924 \end_inset
13925
13926 .
13927 \end_layout
13928
13929 \end_inset
13930
13931  for details.
13932 \end_layout
13933
13934 \begin_layout Description
13935 Abstract: You may wonder why an abstract is an extra feature.
13936  Well, it is in book class.
13937  Usually books don't have abstracts.
13938  Memoir, however, has.
13939  You can use it wherever and how often you like.
13940 \end_layout
13941
13942 \begin_layout Description
13943 Chapterprecis: You may know this from belletristic: The contents of a chapter
13944  is shortly described below the title and also in the table of contents
13945  (e.
13946 \begin_inset space \thinspace{}
13947 \end_inset
13948
13949 g.
13950 \begin_inset space \space{}
13951 \end_inset
13952
13953
13954 \emph on
13955 Our hero arrives in Troia; he loses some friends; he finds others
13956 \emph default
13957 ).
13958  Chapterprecis does exactly this.
13959  It is therefore only sensible below a chapter.
13960 \end_layout
13961
13962 \begin_layout Description
13963 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
13964  The epigraph environment provides an elegant way of typesetting such a
13965  motto.
13966  The motto itself (text) and its author (source) are divided by a short
13967  line.
13968  Unfortunately, we have to fool LyX a bit here again, since the environment
13969  needs two arguments (text and source).
13970  In this case, we have to use curly brackets (in TeX mode) between the two
13971  arguments: 
13972 \emph on
13973 <smart slogan>
13974 \emph default
13975  
13976 \family typewriter
13977 }{
13978 \family default
13979  
13980 \emph on
13981 <author of the slogan>.
13982 \end_layout
13983
13984 \begin_layout Description
13985 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
13986  complex figurative poems).
13987  LyX can only support a few of them.
13988  One is poemtitle, which is a centered title for poems, which will also
13989  be added to the table of contents (verse is the standard environment for
13990  poems.
13991  Memoir has some enhanced versions of verse, but you need to use TeX code,
13992  because they have to be nested inside regular verse environments, which
13993  is not possible with LyX).
13994 \end_layout
13995
13996 \begin_layout Description
13997 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
13998 \end_layout
13999
14000 \begin_layout Section
14001 Article (mwart), book (mwbk) and report (mwrep)
14002 \begin_inset OptArg
14003 status collapsed
14004
14005 \begin_layout Plain Layout
14006 The 
14007 \family typewriter
14008 mw
14009 \family default
14010  Classes
14011 \end_layout
14012
14013 \end_inset
14014
14015
14016 \end_layout
14017
14018 \begin_layout Standard
14019 by 
14020 \noun on
14021 Tomasz Luczak
14022 \end_layout
14023
14024 \begin_layout Standard
14025 The LyX document classes 
14026 \emph on
14027 article (mwart)
14028 \emph default
14029
14030 \emph on
14031 report (mwrep)
14032 \emph default
14033  and 
14034 \emph on
14035 book
14036 \emph default
14037  
14038 \emph on
14039 (mwbk)
14040 \emph default
14041  correspond to the LaTeX document classes 
14042 \family typewriter
14043 mwart.cls
14044 \family default
14045
14046 \family typewriter
14047 mwrep.cls
14048 \family default
14049  and 
14050 \family typewriter
14051 mwbk.cls
14052 \family default
14053 , resp.
14054  They are replacements for the standard document classes 
14055 \family typewriter
14056 article.cls
14057 \family default
14058
14059 \family typewriter
14060 report.cls
14061 \family default
14062  and 
14063 \family typewriter
14064 book.cls
14065 \family default
14066 , resp., and fit better to Polish typography conventions in a number of points.
14067  
14068 \end_layout
14069
14070 \begin_layout Standard
14071 Basic differences:
14072 \end_layout
14073
14074 \begin_layout Itemize
14075 Unnumbered titles (with star, e.
14076 \begin_inset space \thinspace{}
14077 \end_inset
14078
14079 g.
14080 \begin_inset space \space{}
14081 \end_inset
14082
14083
14084 \family sans
14085 Section*
14086 \family default
14087 ) are added into table of contents,
14088 \end_layout
14089
14090 \begin_layout Itemize
14091 Additional page styles:
14092 \end_layout
14093
14094 \begin_deeper
14095 \begin_layout Description
14096 uheadings header with separated lines,
14097 \end_layout
14098
14099 \begin_layout Description
14100 myheadings custom header, contents headers via commands: 
14101 \family typewriter
14102
14103 \backslash
14104 markright
14105 \family default
14106  and 
14107 \family typewriter
14108
14109 \backslash
14110 markboth
14111 \family default
14112 ,
14113 \end_layout
14114
14115 \begin_layout Description
14116 myuheadings custom header with separated lines,
14117 \end_layout
14118
14119 \begin_layout Description
14120 outer page number is placed on outer side of page
14121 \end_layout
14122
14123 \end_deeper
14124 \begin_layout Itemize
14125 Options 
14126 \end_layout
14127
14128 \begin_deeper
14129 \begin_layout Description
14130 rmheadings serif titles â€” default,
14131 \end_layout
14132
14133 \begin_layout Description
14134 sfheadings sansserif titles,
14135 \end_layout
14136
14137 \begin_layout Description
14138 authortitle on title page first placed is author next title â€” default,
14139 \end_layout
14140
14141 \begin_layout Description
14142 titleauthor on title page first placed is title next author,
14143 \end_layout
14144
14145 \begin_layout Description
14146 withmarginpar reserve place on page for margins.
14147 \end_layout
14148
14149 \end_deeper
14150 \begin_layout Section
14151 Paper
14152 \end_layout
14153
14154 \begin_layout Standard
14155 The document class 
14156 \family sans
14157 paper
14158 \family default
14159  provides an alternative to the standard 
14160 \family sans
14161 article
14162 \family default
14163  class.
14164  It provides similar functionality, but you might prefer this layout with
14165  sans serif sections, headings, and more.
14166 \end_layout
14167
14168 \begin_layout Section
14169 RevTeX4
14170 \end_layout
14171
14172 \begin_layout Standard
14173 by 
14174 \noun on
14175 Amir Karger
14176 \end_layout
14177
14178 \begin_layout Standard
14179 \begin_inset VSpace bigskip
14180 \end_inset
14181
14182
14183 \end_layout
14184
14185 \begin_layout Standard
14186 \noindent
14187 The 
14188 \family sans
14189 Revtex
14190 \begin_inset space ~
14191 \end_inset
14192
14193 4
14194 \family default
14195  textclass works with the American Physical Sociey's RevTeX 4.0 (the 
14196 \begin_inset Formula $\beta$
14197 \end_inset
14198
14199  release of May, 1999) class.
14200 \end_layout
14201
14202 \begin_layout Standard
14203 LyX has a 
14204 \family sans
14205 Revtex
14206 \family default
14207  textclass, which works with RevTeX 3.1.
14208  However, v3.1 is basically obsolete, as it works with LaTeX 2.09.
14209  That means that it doesn't interact very well with LyX, which requires
14210  LaTeX2e, although it has been kludged to work.
14211  Since RevTeX 4.0 has been designed to work much more cleanly with LaTeX2e,
14212  LyX with the 
14213 \family sans
14214 RevTeX
14215 \begin_inset space ~
14216 \end_inset
14217
14218 4
14219 \family default
14220  textclass should also be pretty easy to use.
14221 \end_layout
14222
14223 \begin_layout Standard
14224 These documents are supposed to be used in 
14225 \emph on
14226 addition
14227 \emph default
14228  to the RevTeX 4.0 documents, so we don't describe any of the special RevTeX
14229  macros, and assume you'll know what to put in the preamble if necessary.
14230 \end_layout
14231
14232 \begin_layout Subsection
14233 Installation
14234 \end_layout
14235
14236 \begin_layout Standard
14237 All you need to do is install RevTeX 4, as described in the package's README
14238  file.
14239  The package can be found at The RevTeX 4 Web Site 
14240 \begin_inset Flex URL
14241 status collapsed
14242
14243 \begin_layout Plain Layout
14244
14245 http://publish.aps.org/revtex4/
14246 \end_layout
14247
14248 \end_inset
14249
14250 .
14251  Install it somewhere that LaTeX can see it.
14252  Test it by trying to LaTeX a short RevTeX 4 document in some random directory
14253  (i.
14254 \begin_inset space \thinspace{}
14255 \end_inset
14256
14257 g.
14258 \begin_inset space \space{}
14259 \end_inset
14260
14261 not the directory where you installed the class file.) Then, if you reconfigure
14262  LyX, it will find the class file and let you use the RevTeX4 textclass.
14263 \end_layout
14264
14265 \begin_layout Standard
14266 Probably the easiest way to get started is either to import a RevTeX 4 document
14267  using 
14268 \family typewriter
14269 tex2lyx
14270 \family default
14271 , or to use the 
14272 \family sans
14273 Revtex
14274 \begin_inset space ~
14275 \end_inset
14276
14277 4
14278 \family default
14279  template, found in the templates directory.
14280 \end_layout
14281
14282 \begin_layout Subsection
14283 Preamble Matter
14284 \end_layout
14285
14286 \begin_layout Standard
14287 Optional arguments to 
14288 \family typewriter
14289
14290 \backslash
14291 documentclass
14292 \family default
14293 , like 
14294 \begin_inset Quotes eld
14295 \end_inset
14296
14297 preprint
14298 \begin_inset Quotes erd
14299 \end_inset
14300
14301  and 
14302 \begin_inset Quotes eld
14303 \end_inset
14304
14305 aps
14306 \begin_inset Quotes erd
14307 \end_inset
14308
14309 , go in the 
14310 \family sans
14311 E
14312 \bar under
14313 x
14314 \bar default
14315 tra
14316 \begin_inset space ~
14317 \end_inset
14318
14319 Options
14320 \family default
14321  field in the 
14322 \family sans
14323 Document
14324 \begin_inset space ~
14325 \end_inset
14326
14327 Layout
14328 \family default
14329  dialog, as usual.
14330  Remember that in RevTeX, at least one optional argument is required! 
14331 \end_layout
14332
14333 \begin_layout Standard
14334 Other preamble matter, like 
14335 \family typewriter
14336
14337 \backslash
14338 draft
14339 \family default
14340  etc.
14341 \begin_inset space ~
14342 \end_inset
14343
14344 goes in the 
14345 \family sans
14346 LaTeX
14347 \begin_inset space ~
14348 \end_inset
14349
14350 Preamble
14351 \family default
14352  dialog, also as usual.
14353 \end_layout
14354
14355 \begin_layout Subsection
14356 Layouts
14357 \end_layout
14358
14359 \begin_layout Standard
14360 The layouts basically correspond to the commands in RevTeX4.0.
14361  For example, the Email layout corresponds to 
14362 \family typewriter
14363
14364 \backslash
14365 email{}
14366 \family default
14367 .
14368  Note that (at least as of RevTeX 4.0 Beta), the 
14369 \family sans
14370 Address
14371 \family default
14372  and 
14373 \family sans
14374 Affiliation
14375 \family default
14376  layouts are exactly equivalent, so you shouldn't need to use both.
14377 \begin_inset Foot
14378 status collapsed
14379
14380 \begin_layout Plain Layout
14381 In case you're curious, both were included so that 
14382 \family typewriter
14383 tex2lyx
14384 \family default
14385  would be able to translate both 
14386 \family typewriter
14387
14388 \backslash
14389 address
14390 \family default
14391  and 
14392 \family typewriter
14393
14394 \backslash
14395 affiliation
14396 \family default
14397 .
14398 \end_layout
14399
14400 \end_inset
14401
14402
14403 \end_layout
14404
14405 \begin_layout Subsection
14406 Important Notes
14407 \end_layout
14408
14409 \begin_layout Standard
14410 There are a couple of important unique aspects of RevTeX 4 which might cause
14411  bugs that will be even more confusing in LyX.
14412 \end_layout
14413
14414 \begin_layout Standard
14415 In RevTeX, the 
14416 \family typewriter
14417
14418 \backslash
14419 thanks
14420 \family default
14421  command goes 
14422 \emph on
14423 outside
14424 \emph default
14425  the 
14426 \family typewriter
14427
14428 \backslash
14429 author
14430 \family default
14431  command.
14432  The LyX equivalent is that there is a separate Thanks layout.
14433  Do 
14434 \emph on
14435 not
14436 \emph default
14437  write footnotes in the 
14438 \family sans
14439 Author
14440 \family default
14441  layout, or weird things may happen.
14442  See the RevTeX 4 documentation for more details.
14443 \end_layout
14444
14445 \begin_layout Standard
14446 Also, the 
14447 \family sans
14448 Author
14449 \begin_inset space ~
14450 \end_inset
14451
14452 Email
14453 \family default
14454
14455 \family sans
14456 Author
14457 \begin_inset space ~
14458 \end_inset
14459
14460 URL
14461 \family default
14462 , and 
14463 \family sans
14464 Thanks
14465 \family default
14466  layouts must be placed 
14467 \emph on
14468 in between
14469 \emph default
14470  the 
14471 \family sans
14472 Author
14473 \family default
14474  layout and the corresponding 
14475 \family sans
14476 Address
14477 \family default
14478  (or equivalent 
14479 \family sans
14480 Affiliation
14481 \family default
14482 ) layout.
14483  If you put the 
14484 \family sans
14485 Thanks
14486 \family default
14487  after the 
14488 \family sans
14489 Address
14490 \family default
14491 , the LaTeX won't compile.
14492 \end_layout
14493
14494 \begin_layout Subsection
14495 Drawbacks
14496 \end_layout
14497
14498 \begin_layout Standard
14499 The main problem with this layout is that you can't use the optional arguments
14500  to layouts like Email and Title.
14501  (The problem is not unique to this layout; you can't use optional arguments
14502  to the Section layouts either.) This means that after you export that file
14503  to LaTeX (which you'll need to do eventually to send it in to APS), you'll
14504  need to edit the LaTeX file with a text editor to add the optional arguments
14505  to set, e.
14506 \begin_inset space \thinspace{}
14507 \end_inset
14508
14509 g.
14510 \begin_inset space \space{}
14511 \end_inset
14512
14513 the running title for the page headers.
14514  Lacking these layouts makes the 
14515 \family typewriter
14516
14517 \backslash
14518 altaffiliation
14519 \family default
14520  (and the equivalent 
14521 \family typewriter
14522
14523 \backslash
14524 altaddress
14525 \family default
14526 ) useless, so the corresponding layouts don't exist, and will have to be
14527  added by hand.
14528 \begin_inset Foot
14529 status collapsed
14530
14531 \begin_layout Plain Layout
14532
14533 \emph on
14534 Note from JMarc:
14535 \emph default
14536  actually, LyX 1.3.0 supports some forms of optional arguments, but this layout
14537  has not been updated yet to take advantage of it.
14538 \end_layout
14539
14540 \end_inset
14541
14542  
14543 \end_layout
14544
14545 \begin_layout Section
14546 Springer Journals (
14547 \family sans
14548 svjour
14549 \family default
14550 )
14551 \end_layout
14552
14553 \begin_layout Standard
14554 by 
14555 \noun on
14556 Martin Vermeer
14557 \end_layout
14558
14559 \begin_layout Subsection
14560 Description
14561 \end_layout
14562
14563 \begin_layout Standard
14564 These are the layout files for some of the journal formats used by Springer
14565  Verlag and listed on 
14566 \begin_inset Flex URL
14567 status collapsed
14568
14569 \begin_layout Plain Layout
14570
14571 http://www.springer.de/author/tex/help-journals.html
14572 \end_layout
14573
14574 \end_inset
14575
14576 , where you should also go to fetch the class files (yes, these are LaTeX2e
14577  now!).
14578  It is a modular system: the things common to all journals are implemented
14579  in 
14580 \family typewriter
14581 svjour.inc
14582 \family default
14583 , which journal-specific layout files (such as, e.
14584 \begin_inset space \thinspace{}
14585 \end_inset
14586
14587 g.
14588 \begin_inset space \space{}
14589 \end_inset
14590
14591
14592 \family typewriter
14593 svjog.layout
14594 \family default
14595  for Journal of Geodesy) can include.
14596 \end_layout
14597
14598 \begin_layout Standard
14599 This means that implementing support for any other Springer journal on this
14600  list is as simple as writing your own 
14601 \family typewriter
14602 sv
14603 \family default
14604 <myjournal>
14605 \family typewriter
14606 .layout
14607 \family default
14608  file following the outline given in 
14609 \family typewriter
14610 svjog.layout
14611 \family default
14612 .
14613  
14614 \end_layout
14615
14616 \begin_layout Standard
14617 It is reasonably well tested only for the Journal of Geodesy.
14618  
14619 \family typewriter
14620 svjour
14621 \family default
14622  and 
14623 \family typewriter
14624 svjog
14625 \family default
14626  come with the standard LyX distribution.
14627  Install the relevant class file (downloaded from Springer) in a proper
14628  directory, reconfigure LaTeX (in the teTeX case by running 
14629 \family typewriter
14630 texhash
14631 \family default
14632 , as root if necessary â€” doesn't LyX take care of this?), reconfigure LyX
14633  and it should work.
14634 \end_layout
14635
14636 \begin_layout Subsection
14637 New styles
14638 \end_layout
14639
14640 \begin_layout Standard
14641 A large number of theorem-like styles â€” 
14642 \family sans
14643 Claim, Conjecture,
14644 \family default
14645  
14646 \family sans
14647 \SpecialChar \ldots{}
14648 Theorem
14649 \family default
14650 .
14651 \end_layout
14652
14653 \begin_layout Standard
14654
14655 \family sans
14656 Headnote, Dedication, Subtitle, Running_LaTeX_Title, Author_Running, Institute,
14657  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
14658 \family default
14659 .
14660  See the Springer class file documentation for details.
14661 \end_layout
14662
14663 \begin_layout Subsection
14664 Supported journals
14665 \end_layout
14666
14667 \begin_layout Itemize
14668
14669 \emph on
14670 Journal of Geodesy
14671 \emph default
14672
14673 \family typewriter
14674 svjog.layout
14675 \family default
14676  â€” Martin Vermeer
14677 \end_layout
14678
14679 \begin_layout Itemize
14680
14681 \emph on
14682 Probability Theory and Related Fields
14683 \emph default
14684
14685 \family typewriter
14686 svprobth.layout
14687 \family default
14688  â€” Jean-Marc Lasgouttes
14689 \end_layout
14690
14691 \begin_layout Standard
14692 Add your own, it isn't so hard!
14693 \end_layout
14694
14695 \begin_layout Subsection
14696 Credits
14697 \end_layout
14698
14699 \begin_layout Standard
14700 These files are partly based on the older 
14701 \family typewriter
14702 ejour2.layout
14703 \family default
14704 , which was again based on a tinkered-with version of an old LaTeX 2.09 style
14705  file from Springer.
14706  All this, and the 
14707 \family typewriter
14708 ejour2
14709 \family default
14710  layout, are now defunct.
14711  Jean-Marc Lasgouttes helped out big in making me find my way around the
14712  LyX layout file mechanism.
14713 \end_layout
14714
14715 \begin_layout Subsection
14716 Bugs
14717 \end_layout
14718
14719 \begin_layout Standard
14720 Probably.
14721  But probably less than in the old hacked-LaTeX 
14722 \family typewriter
14723 ejour2
14724 \family default
14725 .
14726 \end_layout
14727
14728 \begin_layout Standard
14729 Limitations e.
14730 \begin_inset space \thinspace{}
14731 \end_inset
14732
14733 g.: does not display the number for theorem-like layouts, just #.
14734 \end_layout
14735
14736 \begin_layout Section
14737 Slides [aka 
14738 \noun on
14739 SliTeX
14740 \noun default
14741 ]
14742 \begin_inset CommandInset label
14743 LatexCommand label
14744 name "sec:slitex"
14745
14746 \end_inset
14747
14748
14749 \end_layout
14750
14751 \begin_layout Standard
14752 by 
14753 \noun on
14754 John Weiss
14755 \noun default
14756  
14757 \end_layout
14758
14759 \begin_layout Subsection
14760 Introduction
14761 \end_layout
14762
14763 \begin_layout Standard
14764 This section describes how to use LyX to make slides for overhead projectors.
14765  There are two document classes that can do this: the default slides class
14766  and the 
14767 \family sans
14768 FoilTeX
14769 \family default
14770  slides class.
14771  This section documents the former.
14772 \end_layout
14773
14774 \begin_layout Standard
14775 I'm going to say this again, nice and clear, so that there's no misunderstanding
14776 :
14777 \end_layout
14778
14779 \begin_layout Standard
14780 \begin_inset VSpace bigskip
14781 \end_inset
14782
14783
14784 \end_layout
14785
14786 \begin_layout Standard
14787 \align center
14788
14789 \size large
14790 This section documents the class 
14791 \begin_inset Quotes eld
14792 \end_inset
14793
14794
14795 \family sans
14796 slides (default)
14797 \family default
14798
14799 \begin_inset Quotes erd
14800 \end_inset
14801
14802  
14803 \emph on
14804 only.
14805 \end_layout
14806
14807 \begin_layout Standard
14808 \begin_inset VSpace bigskip
14809 \end_inset
14810
14811
14812 \end_layout
14813
14814 \begin_layout Standard
14815 If you're looking for the documentation for 
14816 \begin_inset Quotes eld
14817 \end_inset
14818
14819
14820 \family sans
14821 slides (FoilTeX)
14822 \family default
14823
14824 \begin_inset Quotes erd
14825 \end_inset
14826
14827 , check out section
14828 \begin_inset space ~
14829 \end_inset
14830
14831
14832 \begin_inset CommandInset ref
14833 LatexCommand ref
14834 reference "sec:foiltex"
14835
14836 \end_inset
14837
14838 .
14839  The 
14840 \family sans
14841 foils
14842 \family default
14843  class [
14844 \begin_inset Quotes eld
14845 \end_inset
14846
14847
14848 \family sans
14849 slides (FoilTeX)
14850 \family default
14851
14852 \begin_inset Quotes erd
14853 \end_inset
14854
14855 ] is actually somewhat better than the default 
14856 \family sans
14857 slides
14858 \family default
14859  class,
14860 \begin_inset Foot
14861 status collapsed
14862
14863 \begin_layout Plain Layout
14864 \SpecialChar \ldots{}
14865 or so I've been told repeatedly by its advocates.
14866  Having never used it, I have no idea if this claim is true or not.
14867 \end_layout
14868
14869 \end_inset
14870
14871  which this section documents.
14872 \end_layout
14873
14874 \begin_layout Standard
14875 This class is the LaTeX2e improvement of the old 
14876 \noun on
14877 SliTeX
14878 \noun default
14879  package.
14880  Every LaTeX2e distribution includes this class [which I'll just refer to
14881  as 
14882 \begin_inset Quotes eld
14883 \end_inset
14884
14885
14886 \family sans
14887 slides
14888 \family default
14889
14890 \begin_inset Quotes erd
14891 \end_inset
14892
14893  from now on], so you're bound to have it.
14894  As I noted earlier, there are other classes, such as 
14895 \family sans
14896 foils
14897 \family default
14898 , which also produce slides for overhead projectors and do a better job
14899  at it.
14900  However, there are some things which 
14901 \family sans
14902 slides
14903 \family default
14904  can do which the others can't, such as generate overlays.
14905  Read on to learn more!
14906 \end_layout
14907
14908 \begin_layout Subsection
14909 Getting Started
14910 \begin_inset CommandInset label
14911 LatexCommand label
14912 name "sec:slidesetup"
14913
14914 \end_inset
14915
14916
14917 \end_layout
14918
14919 \begin_layout Standard
14920 Obviously, to use this document class, you need to select 
14921 \begin_inset Quotes eld
14922 \end_inset
14923
14924
14925 \family sans
14926 slides (default)
14927 \family default
14928
14929 \begin_inset Quotes erd
14930 \end_inset
14931
14932  from the class list in the 
14933 \family sans
14934 Document\SpecialChar \menuseparator
14935 Settings
14936 \family default
14937  dialog.
14938  There are some other special things you should know about this class:
14939 \end_layout
14940
14941 \begin_layout Itemize
14942 Don't bother changing the options 
14943 \family sans
14944 Sides and Columns
14945 \family default
14946 .
14947  They're not supported by the 
14948 \family sans
14949 slides
14950 \family default
14951  class, anyways.
14952 \end_layout
14953
14954 \begin_layout Itemize
14955 The option 
14956 \family sans
14957 Page
14958 \begin_inset space ~
14959 \end_inset
14960
14961 style
14962 \family default
14963  behaves a bit differently for this class.
14964  The possible choices and what they do are as follows:
14965 \end_layout
14966
14967 \begin_deeper
14968 \begin_layout Description
14969
14970 \family sans
14971 plain
14972 \family default
14973  The final output contains page numbers in the lower right corner.
14974 \end_layout
14975
14976 \begin_layout Description
14977
14978 \family sans
14979 headings
14980 \family default
14981  Like 
14982 \family sans
14983 plain
14984 \family default
14985 , but also prints out any time markers you've put in.
14986  This is the default.
14987 \end_layout
14988
14989 \begin_layout Description
14990
14991 \family sans
14992 empty
14993 \family default
14994  The final output contains no page numbers, time markers, or alignment markers.
14995 \end_layout
14996
14997 \end_deeper
14998 \begin_layout Itemize
14999 The 
15000 \family sans
15001 slides
15002 \family default
15003  class has an extra option: 
15004 \family typewriter
15005 clock
15006 \family default
15007 .
15008  To use it, put 
15009 \begin_inset Quotes eld
15010 \end_inset
15011
15012
15013 \family typewriter
15014 clock
15015 \family default
15016
15017 \begin_inset Quotes erd
15018 \end_inset
15019
15020  in the extra class options.
15021 \end_layout
15022
15023 \begin_deeper
15024 \begin_layout Standard
15025 Using this options allows you to add time markers to 
15026 \family sans
15027 Note
15028 \family default
15029 s.
15030  See section
15031 \begin_inset space ~
15032 \end_inset
15033
15034
15035 \begin_inset CommandInset ref
15036 LatexCommand ref
15037 reference "sec:slideNote"
15038
15039 \end_inset
15040
15041  for more details.
15042 \end_layout
15043
15044 \end_deeper
15045 \begin_layout Standard
15046 You can also use the template file 
15047 \begin_inset Quotes eld
15048 \end_inset
15049
15050
15051 \family typewriter
15052 slides.lyx
15053 \family default
15054
15055 \begin_inset Quotes erd
15056 \end_inset
15057
15058  to automatically set up a document to use the 
15059 \family sans
15060 slides
15061 \family default
15062  class [using 
15063 \family sans
15064 File\SpecialChar \menuseparator
15065 New
15066 \begin_inset space ~
15067 \end_inset
15068
15069 from
15070 \begin_inset space ~
15071 \end_inset
15072
15073 Template
15074 \family default
15075  to open your new document].
15076  The template file also contains some examples of the special paragraph
15077  environments used by this class.
15078  I'll describe those next.
15079 \end_layout
15080
15081 \begin_layout Subsection
15082 Paragraph Environments
15083 \end_layout
15084
15085 \begin_layout Subsubsection
15086 Supported Environments
15087 \end_layout
15088
15089 \begin_layout Standard
15090 The first thing you'll notice when you start up a new 
15091 \family sans
15092 slides
15093 \family default
15094  document is the font size and type: it's the equivalent of the size 
15095 \begin_inset Quotes eld
15096 \end_inset
15097
15098
15099 \family sans
15100 Largest
15101 \family default
15102
15103 \begin_inset Quotes erd
15104 \end_inset
15105
15106  in the 
15107 \family sans
15108 Sans
15109 \begin_inset space ~
15110 \end_inset
15111
15112 Serif
15113 \family default
15114  font.
15115  This is also what's used in the output.
15116  Think of this as a 
15117 \begin_inset Quotes eld
15118 \end_inset
15119
15120 visual cue
15121 \begin_inset Quotes erd
15122 \end_inset
15123
15124  to remind you that this is a slide.
15125  Your final slides will use a larger font; ergo, you'll have less space.
15126  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
15127 \end_layout
15128
15129 \begin_layout Standard
15130 The next thing that becomes obvious is the changes to the paragraph environment
15131  pull-down box [at the far-left end of the toolbar].
15132  Most of the paragraph environments you're used to seeing are missing.
15133  There are also five new ones.
15134  That's because the 
15135 \family sans
15136 slides
15137 \family default
15138  class itself only supports certain paragraph environments:
15139 \end_layout
15140
15141 \begin_layout Itemize
15142
15143 \family sans
15144 Standard
15145 \end_layout
15146
15147 \begin_layout Itemize
15148
15149 \family sans
15150 Itemize
15151 \end_layout
15152
15153 \begin_layout Itemize
15154
15155 \family sans
15156 Enumerate
15157 \end_layout
15158
15159 \begin_layout Itemize
15160
15161 \family sans
15162 Description
15163 \end_layout
15164
15165 \begin_layout Itemize
15166
15167 \family sans
15168 List
15169 \end_layout
15170
15171 \begin_layout Itemize
15172
15173 \family sans
15174 Quotation
15175 \end_layout
15176
15177 \begin_layout Itemize
15178
15179 \family sans
15180 Quote
15181 \end_layout
15182
15183 \begin_layout Itemize
15184
15185 \family sans
15186 Verse
15187 \end_layout
15188
15189 \begin_layout Itemize
15190
15191 \family sans
15192 Caption
15193 \end_layout
15194
15195 \begin_layout Itemize
15196
15197 \family sans
15198 LyX-Code
15199 \end_layout
15200
15201 \begin_layout Itemize
15202
15203 \family sans
15204 Comment
15205 \end_layout
15206
15207 \begin_layout Standard
15208 All of the other standard environments, including the section-heading environmen
15209 ts, aren't used in the 
15210 \family sans
15211 slides
15212 \family default
15213  class.
15214 \end_layout
15215
15216 \begin_layout Standard
15217 On the other hand, you'll notice the following new environments:
15218 \end_layout
15219
15220 \begin_layout Itemize
15221
15222 \family sans
15223 Slide
15224 \end_layout
15225
15226 \begin_layout Itemize
15227
15228 \family sans
15229 Overlay
15230 \end_layout
15231
15232 \begin_layout Itemize
15233
15234 \family sans
15235 Note
15236 \end_layout
15237
15238 \begin_layout Itemize
15239
15240 \family sans
15241 InvisibleText
15242 \end_layout
15243
15244 \begin_layout Itemize
15245
15246 \family sans
15247 VisibleText
15248 \end_layout
15249
15250 \begin_layout Standard
15251 These five are kind of quirky, due to a 
15252 \begin_inset Quotes eld
15253 \end_inset
15254
15255 feature
15256 \begin_inset Quotes erd
15257 \end_inset
15258
15259  in LyX.
15260  You see, LyX doesn't permit you to nest any other paragraph environment
15261  into an empty environment.
15262  Now, that's fine and dandy, but it means that you wouldn't be able to start
15263  a slide with anything except plain text.
15264  To deal with this, I've performed a little 
15265 \begin_inset Quotes eld
15266 \end_inset
15267
15268 LaTeX magic.
15269 \begin_inset Quotes erd
15270 \end_inset
15271
15272  
15273 \end_layout
15274
15275 \begin_layout Subsubsection
15276 Quirks of the New Environments
15277 \begin_inset CommandInset label
15278 LatexCommand label
15279 name "sec:slideQuirk"
15280
15281 \end_inset
15282
15283
15284 \end_layout
15285
15286 \begin_layout Standard
15287 All five of the new paragraph environments are somewhat quirky due to inherent
15288  limitiations in the current version of LyX.
15289  As I just mentioned, LyX forbids environments that begin with another environme
15290 nt.
15291  To get around this, the 
15292 \family sans
15293 Slide
15294 \family default
15295  environment isn't a paragraph environment as described in the 
15296 \emph on
15297 User's Guide
15298 \emph default
15299 .
15300  
15301 \end_layout
15302
15303 \begin_layout Standard
15304 You should consider 
15305 \family sans
15306 Slide
15307 \family default
15308
15309 \family sans
15310 Overlay
15311 \family default
15312 , and 
15313 \family sans
15314 Note
15315 \family default
15316  to be 
15317 \begin_inset Quotes eld
15318 \end_inset
15319
15320 pseudo-environments.
15321 \begin_inset Quotes erd
15322 \end_inset
15323
15324  They look like a section heading or a 
15325 \begin_inset Quotes eld
15326 \end_inset
15327
15328
15329 \family sans
15330 Caption
15331 \family default
15332 ,
15333 \begin_inset Quotes erd
15334 \end_inset
15335
15336  but really begin a [and, if necessary, end the previous] paragraph environment.
15337  Likewise, treat 
15338 \family sans
15339 InvisibleText
15340 \family default
15341  and 
15342 \family sans
15343 VisibleText
15344 \family default
15345  as 
15346 \begin_inset Quotes eld
15347 \end_inset
15348
15349 pseudo-commands.
15350 \begin_inset Quotes erd
15351 \end_inset
15352
15353  These two perform some action.
15354 \end_layout
15355
15356 \begin_layout Standard
15357 A common feature of all five environments, 
15358 \family sans
15359 Slide
15360 \family default
15361
15362 \family sans
15363 Overlay
15364 \family default
15365
15366 \family sans
15367 Note
15368 \family default
15369
15370 \family sans
15371 InvisibleText
15372 \family default
15373  and 
15374 \family sans
15375 VisibleText
15376 \family default
15377 , is a rather long-ish label.
15378  The text following this label â€” ordinarily the contents of the paragraph
15379  environment â€” is utterly irrelevant for 
15380 \family sans
15381 Slide
15382 \family default
15383
15384 \family sans
15385 Overlay
15386 \family default
15387
15388 \family sans
15389 Note
15390 \family default
15391
15392 \family sans
15393 InvisibleText
15394 \family default
15395  and 
15396 \family sans
15397 VisibleText
15398 \family default
15399 .
15400  LyX completely ignores it.
15401  In fact, you can leave these five environments completely empty.
15402  
15403 \end_layout
15404
15405 \begin_layout Standard
15406 While you don't 
15407 \emph on
15408 have
15409 \emph default
15410  to put any text after the rather long-ish label, you might want to.
15411  This could be a short description of the contents of the 
15412 \family sans
15413 Slide
15414 \family default
15415 , for example.
15416  In that case, enter in your descriptive comment and hit 
15417 \family sans
15418 Return
15419 \family default
15420  as you normally would.
15421 \end_layout
15422
15423 \begin_layout Standard
15424 If, on the other hand, you don't want to enter in any descriptive text,
15425  you'll hit another LyX quirk.
15426  LyX, like nature, abhors a vacuum, and will not let you start a new paragraph
15427  environment until you put something in the old one.
15428  So, do this:
15429 \end_layout
15430
15431 \begin_layout Itemize
15432 Start entering the text that will 
15433 \emph on
15434 follow
15435 \emph default
15436  the new 
15437 \family sans
15438 Slide
15439 \family default
15440
15441 \family sans
15442 Overlay
15443 \family default
15444
15445 \family sans
15446 Note
15447 \family default
15448
15449 \family sans
15450 InvisibleText
15451 \family default
15452  or 
15453 \family sans
15454 VisibleText
15455 \family default
15456 .
15457  
15458 \end_layout
15459
15460 \begin_layout Itemize
15461 Now move to the beginning of that paragraph.
15462  
15463 \end_layout
15464
15465 \begin_layout Itemize
15466 Next, hit 
15467 \family sans
15468 Return
15469 \family default
15470 .
15471  
15472 \end_layout
15473
15474 \begin_layout Itemize
15475 Finally, change this new, empty paragraph to a 
15476 \family sans
15477 Slide
15478 \family default
15479
15480 \family sans
15481 Overlay
15482 \family default
15483
15484 \family sans
15485 Note
15486 \family default
15487
15488 \family sans
15489 InvisibleText
15490 \family default
15491  or 
15492 \family sans
15493 VisibleText
15494 \family default
15495 .
15496  
15497 \end_layout
15498
15499 \begin_layout Standard
15500 Some future version of LyX will, hopefully, resolve this quirkiness\SpecialChar \ldots{}
15501
15502 \end_layout
15503
15504 \begin_layout Subsection
15505 Making a Presentation with 
15506 \family sans
15507 Slide
15508 \family default
15509
15510 \family sans
15511 Overlay
15512 \family default
15513  and 
15514 \family sans
15515 Note
15516 \end_layout
15517
15518 \begin_layout Subsubsection
15519 Using the 
15520 \family sans
15521 Slide
15522 \family default
15523  Environment
15524 \end_layout
15525
15526 \begin_layout Standard
15527 If you're expecting this section to teach you how to actually make a presentatio
15528 n, you'll be sorely disappointed.
15529  Naturally, I'll describe all of the ways the 
15530 \family sans
15531 slides
15532 \family default
15533  class can assist you in preparing the materials for a presentation.
15534  Filling in the contents, however, is up to you.
15535  [Then again, that 
15536 \emph on
15537 is
15538 \emph default
15539  the LyX philosophy.]
15540 \end_layout
15541
15542 \begin_layout Standard
15543 Choosing the 
15544 \family sans
15545 Slide
15546 \family default
15547  environment [in the manner described in section
15548 \begin_inset space ~
15549 \end_inset
15550
15551
15552 \begin_inset CommandInset ref
15553 LatexCommand ref
15554 reference "sec:slideQuirk"
15555
15556 \end_inset
15557
15558 ] tells LyX to begin a new slide [duh].
15559  The label for this environment/
15560 \begin_inset Quotes erd
15561 \end_inset
15562
15563 pseudo-command
15564 \begin_inset Quotes erd
15565 \end_inset
15566
15567  is an 
15568 \begin_inset Quotes eld
15569 \end_inset
15570
15571 ASCII line,
15572 \begin_inset Quotes erd
15573 \end_inset
15574
15575  in cool blue, followed by the label, 
15576 \begin_inset Quotes eld
15577 \end_inset
15578
15579 NewSlide:
15580 \begin_inset Quotes erd
15581 \end_inset
15582
15583 .
15584  Any text or paragraph environments that follow this one go on the new slide.
15585  It's that simple.
15586 \end_layout
15587
15588 \begin_layout Standard
15589 Slides are probably the only time you'll need to forcibly end pages in LyX
15590  (this can be specified in the 
15591 \family sans
15592 Paragraph Layout
15593 \family default
15594  dialog).
15595  In fact, you'll want to, once you finish entering the contents of one slide.
15596  If you've entered more text than can physically fit on a slide, the extra
15597  overflows onto a new slide.
15598  I don't recommend doing this, however, since the overflow slide won't have
15599  any page number on it.
15600  Furthermore, it may interfere with any 
15601 \family sans
15602 Overlay
15603 \family default
15604  you've made to accompany the oversized 
15605 \family sans
15606 Slide
15607 \family default
15608 .
15609 \end_layout
15610
15611 \begin_layout Standard
15612 The 
15613 \family sans
15614 Overlay
15615 \family default
15616  and 
15617 \family sans
15618 Note
15619 \family default
15620  environments work the same way as the 
15621 \family sans
15622 Slide
15623 \family default
15624  environment.
15625  They both create an 
15626 \begin_inset Quotes eld
15627 \end_inset
15628
15629 ASCII line
15630 \begin_inset Quotes erd
15631 \end_inset
15632
15633  followed by a label [
15634 \begin_inset Quotes eld
15635 \end_inset
15636
15637 NewOverlay:
15638 \begin_inset Quotes erd
15639 \end_inset
15640
15641  and 
15642 \begin_inset Quotes eld
15643 \end_inset
15644
15645 NewNote:
15646 \begin_inset Quotes erd
15647 \end_inset
15648
15649 , respectively].
15650  The color is a stunning magenta instead of blue, and the 
15651 \begin_inset Quotes eld
15652 \end_inset
15653
15654 ASCII line
15655 \begin_inset Quotes erd
15656 \end_inset
15657
15658  will look different, in style and in length.
15659  The label fonts of all three also differ from one another.
15660 \end_layout
15661
15662 \begin_layout Standard
15663 As with a 
15664 \family sans
15665 Slide
15666 \family default
15667 , if the contents of a 
15668 \family sans
15669 Note
15670 \family default
15671  or 
15672 \family sans
15673 Overlay
15674 \family default
15675  exceed the physical size of a slide or sheet of paper, the extra will overflow
15676  onto a new sheet.
15677  Again, you should avoid this.
15678  It defeats the whole purpose of 
15679 \family sans
15680 Note
15681 \family default
15682 s and 
15683 \family sans
15684 Overlay
15685 \family default
15686 s.
15687 \end_layout
15688
15689 \begin_layout Subsubsection
15690 Using 
15691 \family sans
15692 Overlay
15693 \family default
15694  with 
15695 \family sans
15696 Slide
15697 \end_layout
15698
15699 \begin_layout Standard
15700 The idea behind an 
15701 \family sans
15702 Overlay
15703 \family default
15704  is a slide that sits atop another slide.
15705  Perhaps you wish to discuss a figure on the main 
15706 \family sans
15707 Slide
15708 \family default
15709  before displaying the text associated with it.
15710  One way to accomplish this is tape a flap of dark paper over the part of
15711  the 
15712 \family sans
15713 Slide
15714 \family default
15715  you want to display later.
15716  This method fails, however, if you wish to overlap one graph with another,
15717  for example.
15718  You would then have to fumble while speaking to align the two separate,
15719  overlapping 
15720 \family sans
15721 Slide
15722 \family default
15723 s to align the two graphs.
15724  The use of an 
15725 \family sans
15726 Overlay
15727 \family default
15728  environment in both cases makes life much easier.
15729 \end_layout
15730
15731 \begin_layout Standard
15732 Each 
15733 \family sans
15734 Overlay
15735 \family default
15736  receives the page number of its 
15737 \begin_inset Quotes eld
15738 \end_inset
15739
15740 parent
15741 \begin_inset Quotes erd
15742 \end_inset
15743
15744  
15745 \family sans
15746 Slide
15747 \family default
15748 , appended by 
15749 \begin_inset Quotes eld
15750 \end_inset
15751
15752
15753 \family typewriter
15754 -a
15755 \family default
15756
15757 \begin_inset Quotes erd
15758 \end_inset
15759
15760 .
15761 \begin_inset Foot
15762 status collapsed
15763
15764 \begin_layout Plain Layout
15765 Presumably, mutliple 
15766 \family sans
15767 Overlay
15768 \family default
15769 s would have 
15770 \begin_inset Quotes eld
15771 \end_inset
15772
15773
15774 \family typewriter
15775 -a
15776 \family default
15777
15778 \begin_inset Quotes erd
15779 \end_inset
15780
15781
15782 \begin_inset Quotes eld
15783 \end_inset
15784
15785
15786 \family typewriter
15787 -b
15788 \family default
15789
15790 \begin_inset Quotes erd
15791 \end_inset
15792
15793
15794 \begin_inset Quotes eld
15795 \end_inset
15796
15797
15798 \family typewriter
15799 -c
15800 \family default
15801
15802 \begin_inset Quotes erd
15803 \end_inset
15804
15805 , etc.
15806 \begin_inset space ~
15807 \end_inset
15808
15809 appended to the page number of the parent 
15810 \family sans
15811 Slide
15812 \family default
15813 .
15814  
15815 \end_layout
15816
15817 \end_inset
15818
15819  Clearly, you want the contents of both the 
15820 \family sans
15821 Slide
15822 \family default
15823  and the 
15824 \family sans
15825 Overlay
15826 \family default
15827  to each fit on a single physical slide! You should probably consider an
15828  
15829 \family sans
15830 Overlay
15831 \family default
15832  as 
15833 \begin_inset Quotes eld
15834 \end_inset
15835
15836 part of
15837 \begin_inset Quotes erd
15838 \end_inset
15839
15840  a 
15841 \family sans
15842 Slide
15843 \family default
15844 .
15845  Indeed, the LyX 
15846 \family sans
15847 slides
15848 \family default
15849  class provides a visual cue for this: the label at the start of an 
15850 \family sans
15851 Overlay
15852 \family default
15853  is shorter than that at the start of a 
15854 \family sans
15855 Slide
15856 \family default
15857 .
15858  Lastly, when you generate printable output, you'll find alignment markers
15859  in all four corners of both the 
15860 \family sans
15861 Overlay
15862 \family default
15863  page and its parent 
15864 \family sans
15865 Slide
15866 \family default
15867 .
15868  These will assist you in lining up the two physical slides.
15869 \end_layout
15870
15871 \begin_layout Standard
15872 The major problem in overlaying two slides is aligning the contents of the
15873  two transparencies.
15874  How much space should you leave for that graph on the second slide? Worse
15875  still, what if you want a graph and a sentence on second slide, but there
15876  is text on the main transparency that goes in between them? You could try
15877  and insert vertical space of the right size.
15878  The better way is to use 
15879 \family sans
15880 InvisibleText
15881 \family default
15882  and 
15883 \family sans
15884 VisibleText
15885 \family default
15886 .
15887 \end_layout
15888
15889 \begin_layout Standard
15890 As their names imply, 
15891 \family sans
15892 InvisibleText
15893 \family default
15894  and 
15895 \family sans
15896 VisibleText
15897 \family default
15898  are two command-like paragraph environments that make all subsequent text
15899  invisible and visible, respectively.
15900  Note from section
15901 \begin_inset space ~
15902 \end_inset
15903
15904
15905 \begin_inset CommandInset ref
15906 LatexCommand ref
15907 reference "sec:slideQuirk"
15908
15909 \end_inset
15910
15911  that you don't place anything 
15912 \emph on
15913 into
15914 \emph default
15915  these two environments, however.
15916  When you create an 
15917 \family sans
15918 InvisibleText
15919 \family default
15920 , it inserts a centered, sky-blue label into the page reading 
15921 \begin_inset Quotes eld
15922 \end_inset
15923
15924 <Invisible Text Follows>
15925 \begin_inset Quotes erd
15926 \end_inset
15927
15928 .
15929  For paragraphs following this label, the parts of the 
15930 \family sans
15931 Slide
15932 \family default
15933  [or 
15934 \family sans
15935 Overlay
15936 \family default
15937 ; it doesn't matter which] where they would be contain instead blank space.
15938  
15939 \end_layout
15940
15941 \begin_layout Standard
15942 For 
15943 \family sans
15944 VisibleText
15945 \family default
15946 , the corresponding centered label is 
15947 \begin_inset Quotes eld
15948 \end_inset
15949
15950 <Visible Text Follows>
15951 \begin_inset Quotes erd
15952 \end_inset
15953
15954  in blazing green.
15955  Paragraphs following this label behave normally.
15956  Note that the beginning of a new 
15957 \family sans
15958 Slide
15959 \family default
15960
15961 \family sans
15962 Overlay
15963 \family default
15964 , or 
15965 \family sans
15966 Note
15967 \family default
15968  automatically shuts off an 
15969 \family sans
15970 InvisibleText
15971 \family default
15972 .
15973  It's therefore not necessary to use 
15974 \family sans
15975 VisibleText
15976 \family default
15977  at the end of a 
15978 \family sans
15979 Slide
15980 \family default
15981 .
15982 \end_layout
15983
15984 \begin_layout Standard
15985 By now, it should be obvious how to create overlay transparencies using
15986  the proper combination of 
15987 \family sans
15988 InvisibleText
15989 \family default
15990  and 
15991 \family sans
15992 VisibleText
15993 \family default
15994  on a 
15995 \family sans
15996 Slide
15997 \family default
15998  and 
15999 \family sans
16000 Overlay
16001 \family default
16002 :
16003 \end_layout
16004
16005 \begin_layout Enumerate
16006 Create a 
16007 \family sans
16008 Slide
16009 \family default
16010 , including everything that will appear on it, whether on the main slide
16011  or on the 
16012 \family sans
16013 Overlay
16014 \family default
16015 .
16016 \end_layout
16017
16018 \begin_layout Enumerate
16019 Before each figure or paragraph that will appear only on the 
16020 \family sans
16021 Overlay
16022 \family default
16023 , insert an 
16024 \family sans
16025 InvisibleText
16026 \family default
16027  environment.
16028  If necessary, insert a 
16029 \family sans
16030 VisibleText
16031 \family default
16032  environment after the 
16033 \family sans
16034 Overlay
16035 \family default
16036 -only text.
16037 \end_layout
16038
16039 \begin_layout Enumerate
16040 Start an 
16041 \family sans
16042 Overlay
16043 \family default
16044  immediately following the 
16045 \family sans
16046 Slide
16047 \family default
16048 .
16049 \end_layout
16050
16051 \begin_layout Enumerate
16052 Copy the contents of this 
16053 \family sans
16054 Slide
16055 \family default
16056  into the 
16057 \family sans
16058 Overlay
16059 \family default
16060 .
16061 \end_layout
16062
16063 \begin_layout Enumerate
16064 Within the 
16065 \family sans
16066 Overlay
16067 \family default
16068 , change all of the 
16069 \family sans
16070 InvisibleText
16071 \family default
16072  lines to 
16073 \family sans
16074 VisibleText
16075 \family default
16076  and vice-versa.
16077 \end_layout
16078
16079 \begin_layout Standard
16080 That's it.
16081  You've just made an 
16082 \family sans
16083 Overlay
16084 \family default
16085 .
16086 \end_layout
16087
16088 \begin_layout Standard
16089 There's one problem with the way I've designed the LyX 
16090 \family sans
16091 slides
16092 \family default
16093  class: you can't make text in the middle of a paragraph invisible, nor
16094  make text in the middle of an invisible paragraph visible again.
16095  To accomplish this feat, you'll need to use some inlined LaTeX codes.
16096 \begin_inset Foot
16097 status collapsed
16098
16099 \begin_layout Plain Layout
16100 The commands of interest are: 
16101 \end_layout
16102
16103 \begin_layout Itemize
16104
16105 \family typewriter
16106 {
16107 \backslash
16108 invisible \SpecialChar \ldots{}
16109  }
16110 \end_layout
16111
16112 \begin_layout Itemize
16113
16114 \family typewriter
16115 {
16116 \backslash
16117 visible \SpecialChar \ldots{}
16118  }
16119 \end_layout
16120
16121 \begin_layout Plain Layout
16122 \SpecialChar \ldots{}
16123 and need to be marked as TeX.
16124  The text whose 
16125 \begin_inset Quotes eld
16126 \end_inset
16127
16128 visibility
16129 \begin_inset Quotes erd
16130 \end_inset
16131
16132  you wish to change goes in between the brackets [and after the 
16133 \family typewriter
16134
16135 \backslash
16136 invisible
16137 \family default
16138  or 
16139 \family typewriter
16140
16141 \backslash
16142 visible
16143 \family default
16144  command].
16145  If you don't know how to mark text as TeX, see the appropriate section
16146  of the 
16147 \emph on
16148 User's Guide
16149 \emph default
16150 .
16151 \end_layout
16152
16153 \end_inset
16154
16155
16156 \end_layout
16157
16158 \begin_layout Subsubsection
16159 Using 
16160 \family sans
16161 Note
16162 \family default
16163  with 
16164 \family sans
16165 Slide
16166 \family default
16167
16168 \begin_inset CommandInset label
16169 LatexCommand label
16170 name "sec:slideNote"
16171
16172 \end_inset
16173
16174
16175 \end_layout
16176
16177 \begin_layout Standard
16178 Like an 
16179 \family sans
16180 Overlay
16181 \family default
16182 , a 
16183 \family sans
16184 Note
16185 \family default
16186  is associated with a 
16187 \begin_inset Quotes eld
16188 \end_inset
16189
16190 parent
16191 \begin_inset Quotes erd
16192 \end_inset
16193
16194  
16195 \family sans
16196 Slide
16197 \family default
16198 .
16199  Here, too, the LyX 
16200 \family sans
16201 slides
16202 \family default
16203  class provides visual cues.
16204  The label for a 
16205 \family sans
16206 Note
16207 \family default
16208  is shorter than that of a 
16209 \family sans
16210 Slide
16211 \family default
16212  [yet longer than that of an 
16213 \family sans
16214 Overlay
16215 \family default
16216 ] and, like the label of an 
16217 \family sans
16218 Overlay
16219 \family default
16220  is shockingly magenta.
16221  Additionally, the printed 
16222 \family sans
16223 Note
16224 \family default
16225  has the page number of its 
16226 \begin_inset Quotes eld
16227 \end_inset
16228
16229 parent
16230 \begin_inset Quotes erd
16231 \end_inset
16232
16233  
16234 \family sans
16235 Slide
16236 \family default
16237 , appended by 
16238 \begin_inset Quotes eld
16239 \end_inset
16240
16241
16242 \family typewriter
16243 -
16244 \family default
16245 1
16246 \begin_inset Quotes erd
16247 \end_inset
16248
16249
16250 \begin_inset Quotes eld
16251 \end_inset
16252
16253
16254 \family typewriter
16255 -
16256 \family default
16257 2
16258 \begin_inset Quotes erd
16259 \end_inset
16260
16261
16262 \begin_inset Quotes eld
16263 \end_inset
16264
16265
16266 \family typewriter
16267 -
16268 \family default
16269 3
16270 \begin_inset Quotes erd
16271 \end_inset
16272
16273 , etc.
16274  You can have multiple 
16275 \family sans
16276 Note
16277 \family default
16278 s associated with a single 
16279 \family sans
16280 Slide
16281 \family default
16282 , and, as with 
16283 \family sans
16284 Slide
16285 \family default
16286  and 
16287 \family sans
16288 Overlay
16289 \family default
16290 , you'll probably want to break up long 
16291 \family sans
16292 Note
16293 \family default
16294 s so that they fit on a single sheet of paper.
16295 \end_layout
16296
16297 \begin_layout Standard
16298 The purpose of a 
16299 \family sans
16300 Note
16301 \family default
16302  is obvious: it contains anything additional you might want to say about
16303  a 
16304 \family sans
16305 Slide
16306 \family default
16307 .
16308  It could also be used as a sheet of reminders for a particular 
16309 \family sans
16310 Slide
16311 \family default
16312 .
16313  In the case of the latter, you might want to make use of time markers.
16314  Currently, the LyX 
16315 \family sans
16316 slides
16317 \family default
16318  class has no 
16319 \begin_inset Quotes eld
16320 \end_inset
16321
16322 native
16323 \begin_inset Quotes erd
16324 \end_inset
16325
16326  support for time markers, a 
16327 \noun on
16328 SliTeX
16329 \noun default
16330  feature.
16331  So, you'll have to resort to using the LaTeX codes.
16332 \end_layout
16333
16334 \begin_layout Standard
16335 To use time markers, you'll need to specify the extra class option 
16336 \begin_inset Quotes eld
16337 \end_inset
16338
16339
16340 \family typewriter
16341 clock
16342 \family default
16343
16344 \begin_inset Quotes erd
16345 \end_inset
16346
16347  [see section
16348 \begin_inset space ~
16349 \end_inset
16350
16351
16352 \begin_inset CommandInset ref
16353 LatexCommand ref
16354 reference "sec:slidesetup"
16355
16356 \end_inset
16357
16358 ].
16359  This option turns on timing marks, which will appear in the lower-left-hand
16360  corner of every 
16361 \family sans
16362 Note
16363 \family default
16364  you generate.
16365  To set what appears in the time marker, you use the LaTeX commands 
16366 \begin_inset Quotes eld
16367 \end_inset
16368
16369
16370 \family typewriter
16371
16372 \backslash
16373 settime{}
16374 \family default
16375
16376 \begin_inset Quotes erd
16377 \end_inset
16378
16379  and 
16380 \begin_inset Quotes eld
16381 \end_inset
16382
16383
16384 \family typewriter
16385
16386 \backslash
16387 addtime{}
16388 \family default
16389
16390 \begin_inset Quotes erd
16391 \end_inset
16392
16393 .
16394  The arguments of both commands are time measured in seconds.
16395  
16396 \begin_inset Quotes eld
16397 \end_inset
16398
16399
16400 \family typewriter
16401
16402 \backslash
16403 settime{}
16404 \family default
16405
16406 \begin_inset Quotes erd
16407 \end_inset
16408
16409  sets the time marker to a given time.
16410  
16411 \begin_inset Quotes eld
16412 \end_inset
16413
16414
16415 \family typewriter
16416
16417 \backslash
16418 addtime{}
16419 \family default
16420
16421 \begin_inset Quotes erd
16422 \end_inset
16423
16424  increments the time marker by the specified amount.
16425  Using time markers and 
16426 \family sans
16427 Note
16428 \family default
16429 s in this fashion, you can remind yourself how much time to spend on a particula
16430
16431 \family sans
16432 Slide
16433 \family default
16434 .
16435 \end_layout
16436
16437 \begin_layout Standard
16438 There's one last feature to describe.
16439  Clearly, you'd like to print out all of your 
16440 \family sans
16441 Slide
16442 \family default
16443 s and 
16444 \family sans
16445 Overlay
16446 \family default
16447 s on transparencies while printing all of your 
16448 \family sans
16449 Note
16450 \family default
16451 s on plain paper.
16452  However, a 
16453 \family sans
16454 Note
16455 \family default
16456  
16457 \emph on
16458 must
16459 \emph default
16460  follow the 
16461 \family sans
16462 Slide
16463 \family default
16464  with which it is associated.
16465  What's a person to do?
16466 \end_layout
16467
16468 \begin_layout Standard
16469 Luckily, there are two LaTeX commands that allow you to select what to print
16470  out.
16471  Both must be placed into the preamble of your document.
16472  The command 
16473 \begin_inset Quotes eld
16474 \end_inset
16475
16476
16477 \family typewriter
16478
16479 \backslash
16480 onlyslides{
16481 \backslash
16482 slides}
16483 \family default
16484
16485 \begin_inset Quotes erd
16486 \end_inset
16487
16488  will cause the output to contain only the 
16489 \family sans
16490 Slide
16491 \family default
16492 s and 
16493 \family sans
16494 Overlay
16495 \family default
16496 s.
16497  Correspondingly, the command 
16498 \begin_inset Quotes eld
16499 \end_inset
16500
16501
16502 \family typewriter
16503
16504 \backslash
16505 onlynotes{
16506 \backslash
16507 notes}
16508 \family default
16509
16510 \begin_inset Quotes erd
16511 \end_inset
16512
16513  prevents the output of anything but 
16514 \family sans
16515 Note
16516 \family default
16517 s.
16518  I'd advise placing both commands in the preamble and initially comment
16519  both out.
16520  You can then preview your entire presentation as you write.
16521  When you're done writing, you can then uncomment one of the two to select
16522  what you want to print.
16523  I like to uncomment 
16524 \begin_inset Quotes eld
16525 \end_inset
16526
16527
16528 \family typewriter
16529
16530 \backslash
16531 onlyslides{
16532 \backslash
16533 slides}
16534 \family default
16535
16536 \begin_inset Quotes erd
16537 \end_inset
16538
16539  , print to a file with 
16540 \begin_inset Quotes eld
16541 \end_inset
16542
16543
16544 \family typewriter
16545 -slides
16546 \family default
16547
16548 \begin_inset Quotes erd
16549 \end_inset
16550
16551  in its name, comment it back out, then uncomment 
16552 \begin_inset Quotes eld
16553 \end_inset
16554
16555
16556 \family typewriter
16557
16558 \backslash
16559 onlynotes{
16560 \backslash
16561 notes}
16562 \family default
16563
16564 \begin_inset Quotes erd
16565 \end_inset
16566
16567  and print to a 
16568 \begin_inset Quotes eld
16569 \end_inset
16570
16571
16572 \family typewriter
16573 *-notes.ps
16574 \family default
16575
16576 \begin_inset Quotes erd
16577 \end_inset
16578
16579  file.
16580  I can then send either file to a printer, loading transparencies or plain
16581  paper as appropriate.
16582 \end_layout
16583
16584 \begin_layout Standard
16585 You can also provide other arguments to the 
16586 \begin_inset Quotes eld
16587 \end_inset
16588
16589
16590 \family typewriter
16591
16592 \backslash
16593 onlyslides{}
16594 \family default
16595
16596 \begin_inset Quotes erd
16597 \end_inset
16598
16599  and 
16600 \begin_inset Quotes eld
16601 \end_inset
16602
16603
16604 \family typewriter
16605
16606 \backslash
16607 onlynotes{}
16608 \family default
16609
16610 \begin_inset Quotes erd
16611 \end_inset
16612
16613  commands.
16614  See a good LaTeX book for details.
16615 \end_layout
16616
16617 \begin_layout Subsection
16618 The 
16619 \family sans
16620 slides
16621 \family default
16622  Class Template File
16623 \end_layout
16624
16625 \begin_layout Standard
16626 I have also provided a template file, 
16627 \begin_inset Quotes eld
16628 \end_inset
16629
16630
16631 \family typewriter
16632 slides.lyx
16633 \family default
16634
16635 \begin_inset Quotes erd
16636 \end_inset
16637
16638 , with the 
16639 \family sans
16640 slides
16641 \family default
16642  class.
16643  To use it, begin your new presentation with 
16644 \family sans
16645 \bar under
16646 F
16647 \bar default
16648 ile\SpecialChar \menuseparator
16649 New
16650 \begin_inset space ~
16651 \end_inset
16652
16653 from
16654 \begin_inset space ~
16655 \end_inset
16656
16657
16658 \bar under
16659 T
16660 \bar default
16661 emplate
16662 \family default
16663 .
16664  Your new LyX presentation file will contain an example 
16665 \family sans
16666 Slide
16667 \family default
16668  â€“ 
16669 \family sans
16670 Overlay
16671 \family default
16672  â€“ 
16673 \family sans
16674 Note
16675 \family default
16676  triplet.
16677  The 
16678 \family sans
16679 Slide
16680 \family default
16681  and 
16682 \family sans
16683 Overlay
16684 \family default
16685  additionally contain an example of the use of 
16686 \family sans
16687 InvisibleText
16688 \family default
16689  and 
16690 \family sans
16691 VisibleText
16692 \family default
16693 .
16694  Lastly, the preamble will contain:
16695 \end_layout
16696
16697 \begin_layout LyX-Code
16698 % Uncomment to print out only slides and overlays
16699 \end_layout
16700
16701 \begin_layout LyX-Code
16702 %
16703 \end_layout
16704
16705 \begin_layout LyX-Code
16706 %
16707 \backslash
16708 onlyslides{
16709 \backslash
16710 slides}
16711 \begin_inset Newline newline
16712 \end_inset
16713
16714  
16715 \end_layout
16716
16717 \begin_layout LyX-Code
16718 % Uncomment to print out only notes
16719 \end_layout
16720
16721 \begin_layout LyX-Code
16722 %
16723 \end_layout
16724
16725 \begin_layout LyX-Code
16726 %
16727 \backslash
16728 onlynotes{
16729 \backslash
16730 notes}
16731 \end_layout
16732
16733 \begin_layout Standard
16734 One final thing: I created this class to support the LaTeX2e 
16735 \begin_inset Quotes eld
16736 \end_inset
16737
16738
16739 \noun on
16740 SliTeX
16741 \noun default
16742  emulation
16743 \begin_inset Quotes erd
16744 \end_inset
16745
16746  class, one of the built-in LaTeX2e classes.
16747  Neither I nor the rest of the LyX Team endorse or oppose the use of this
16748  built-in slide class.
16749  It's here if you want it or need it.
16750  There exist other LaTeX2e classes for creating presentations, such as the
16751  
16752 \family sans
16753 Foils
16754 \family default
16755  class [see section
16756 \begin_inset space ~
16757 \end_inset
16758
16759
16760 \begin_inset CommandInset ref
16761 LatexCommand ref
16762 reference "sec:foiltex"
16763
16764 \end_inset
16765
16766 ] or the 
16767 \begin_inset Quotes eld
16768 \end_inset
16769
16770
16771 \family typewriter
16772 seminar
16773 \family default
16774
16775 \begin_inset Quotes erd
16776 \end_inset
16777
16778  package [present on some TeX distributions].
16779  The latter is not yet supported under LyX.
16780 \begin_inset Foot
16781 status collapsed
16782
16783 \begin_layout Plain Layout
16784 Perhaps you can take on the task\SpecialChar \ldots{}
16785
16786 \end_layout
16787
16788 \end_inset
16789
16790  I know nothing about these other classes.
16791  Try them out to see what sort of alternative they provide.
16792 \end_layout
16793
16794 \begin_layout Chapter
16795 LyX Features needing Extra Software
16796 \end_layout
16797
16798 \begin_layout Section
16799 Checking TeX
16800 \end_layout
16801
16802 \begin_layout Standard
16803 by 
16804 \noun on
16805 Asger Alstrup
16806 \end_layout
16807
16808 \begin_layout Subsection
16809 Introduction
16810 \end_layout
16811
16812 \begin_layout Standard
16813 If you have the 
16814 \family typewriter
16815 chktex
16816 \family default
16817  program installed
16818 \begin_inset Foot
16819 status collapsed
16820
16821 \begin_layout Plain Layout
16822
16823 \family typewriter
16824 chktex
16825 \family default
16826  is not yet available when you are using the LaTeX distribution MiKTeX.
16827 \end_layout
16828
16829 \end_inset
16830
16831 , you'll find in the 
16832 \family sans
16833 Tools
16834 \family default
16835  menu the entry: 
16836 \family sans
16837 Check
16838 \begin_inset space ~
16839 \end_inset
16840
16841 TeX
16842 \family default
16843 .
16844  You can get 
16845 \family typewriter
16846 chktex
16847 \family default
16848  it from CTAN, 
16849 \begin_inset CommandInset href
16850 LatexCommand href
16851 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
16852
16853 \end_inset
16854
16855 .
16856 \end_layout
16857
16858 \begin_layout Standard
16859 The 
16860 \family sans
16861 ChkTeX
16862 \family default
16863  package is a program that was written by 
16864 \begin_inset Flex CharStyle:Noun
16865 status collapsed
16866
16867 \begin_layout Plain Layout
16868 Jens T.
16869 \begin_inset space ~
16870 \end_inset
16871
16872 Berger Thielemann
16873 \end_layout
16874
16875 \end_inset
16876
16877  in frustration because some constructs in LaTeX are sometimes non-intuitive,
16878  and easy to forget.
16879  The program runs over your LaTeX file, checks the integrity of the file,
16880  and flags some common errors.
16881  In other technical words, it is 
16882 \family typewriter
16883 lint
16884 \family default
16885  for LaTeX.
16886 \end_layout
16887
16888 \begin_layout Standard
16889 Well, what is a syntax checker doing in LyX which is supposed to produce
16890  correct LaTeX anyways? The answer is simple: Just as 
16891 \family typewriter
16892 Lint
16893 \family default
16894  not only checks the 
16895 \emph on
16896 syntax
16897 \emph default
16898  of C programs, but also does 
16899 \emph on
16900 semantic
16901 \emph default
16902  checks for type-errors, 
16903 \family sans
16904 ChkTeX
16905 \family default
16906  catches some common 
16907 \emph on
16908 typographic
16909 \emph default
16910  errors, in addition to the syntactical ones.
16911  Specifically, 
16912 \family sans
16913 ChkTeX
16914 \family default
16915  is capable of detecting several common errors, such as
16916 \end_layout
16917
16918 \begin_layout Itemize
16919 Ellipsis detection:
16920 \begin_inset Newline newline
16921 \end_inset
16922
16923 Use \SpecialChar \ldots{}
16924  instead of ...
16925 \end_layout
16926
16927 \begin_layout Itemize
16928 No space in front of/after parenthesis:
16929 \begin_inset Newline newline
16930 \end_inset
16931
16932 ( wrong spacing )
16933 \end_layout
16934
16935 \begin_layout Itemize
16936 Enforcement of normal space after common abbreviations:
16937 \begin_inset Newline newline
16938 \end_inset
16939
16940 e.
16941 \begin_inset space \thinspace{}
16942 \end_inset
16943
16944 g.
16945 \begin_inset space \space{}
16946 \end_inset
16947
16948 is too wide spacing.
16949 \end_layout
16950
16951 \begin_layout Itemize
16952 Enforcement of end-of-sentence space when the last sentence ends with a
16953  capital letter:
16954 \begin_inset Newline newline
16955 \end_inset
16956
16957 This is a TEST.
16958  And this is wrong spacing.
16959 \end_layout
16960
16961 \begin_layout Itemize
16962 Space in front of labels and similar commands:
16963 \begin_inset Newline newline
16964 \end_inset
16965
16966 The label should stick right up to the text to avoid falling to a wrong
16967  page.
16968  
16969 \begin_inset CommandInset label
16970 LatexCommand label
16971 name "sec:chktex"
16972
16973 \end_inset
16974
16975  
16976 \begin_inset Foot
16977 status collapsed
16978
16979 \begin_layout Plain Layout
16980 This footnote is in danger of falling off to a wrong page
16981 \end_layout
16982
16983 \end_inset
16984
16985  The label is separated too much.
16986 \end_layout
16987
16988 \begin_layout Itemize
16989 Space in front of references, instead of hard spaces:
16990 \begin_inset Newline newline
16991 \end_inset
16992
16993 In you are in bad luck, the text will break right between the referenced
16994  text and reference number, and that's a pity.
16995  See section 
16996 \begin_inset CommandInset ref
16997 LatexCommand ref
16998 reference "sec:chktex"
16999
17000 \end_inset
17001
17002 .
17003 \end_layout
17004
17005 \begin_layout Itemize
17006 Use of 
17007 \begin_inset Quotes eld
17008 \end_inset
17009
17010 x
17011 \begin_inset Quotes erd
17012 \end_inset
17013
17014  instead of 
17015 \begin_inset Formula $\times$
17016 \end_inset
17017
17018  between numbers:
17019 \begin_inset Newline newline
17020 \end_inset
17021
17022 2x2 looks cheap compared to 
17023 \begin_inset Formula $2\times2$
17024 \end_inset
17025
17026 .
17027 \end_layout
17028
17029 \begin_layout Standard
17030 and more \SpecialChar \ldots{}
17031  It is an invaluable tool when you are 
17032 \begin_inset Quotes eld
17033 \end_inset
17034
17035 finishing up
17036 \begin_inset Quotes erd
17037 \end_inset
17038
17039  your document before printing, and you should run it right after the obligatory
17040  spelling check, and before you go fine tuning the typesetting.
17041 \end_layout
17042
17043 \begin_layout Subsection
17044 How to use it
17045 \end_layout
17046
17047 \begin_layout Standard
17048 If you have the program installed, usage is as simple as choosing 
17049 \family sans
17050 Tools\SpecialChar \menuseparator
17051 Check
17052 \begin_inset space ~
17053 \end_inset
17054
17055 TeX
17056 \family default
17057 .
17058  This will make LyX generate a LaTeX file of your document, start 
17059 \family sans
17060 ChkTeX
17061 \family default
17062  to check it, and then make LyX insert 
17063 \begin_inset Quotes eld
17064 \end_inset
17065
17066 error boxes
17067 \begin_inset Quotes erd
17068 \end_inset
17069
17070  with the warnings from 
17071 \family sans
17072 ChkTeX
17073 \family default
17074 , if there were any.
17075  The warnings will be placed close to the point of the mistake, and you
17076  can quickly find them by using the 
17077 \family sans
17078 Navigate\SpecialChar \menuseparator
17079 Error
17080 \family default
17081  menu item, or the shortcut key 
17082 \family sans
17083 C-g
17084 \family default
17085  from the default 
17086 \family typewriter
17087 cua
17088 \family default
17089  bind file.
17090  Open the error boxes by clicking on them with the mouse, or use the shortcut
17091  key 
17092 \family sans
17093 C-i
17094 \family default
17095  from 
17096 \family typewriter
17097 cua
17098 \family default
17099  bindings, or the corresponding 
17100 \family sans
17101 C-o
17102 \family default
17103  for the alternate 
17104 \family typewriter
17105 emacs
17106 \family default
17107  bind file.
17108  Read the warning and correct the mistake, if it is a mistake.
17109  If you have trouble understanding what the warning is about, you can safely
17110  ignore it.
17111  Remember that there is a hidden layer between the document on screen and
17112  the technical details in invoking 
17113 \family sans
17114 ChkTeX
17115 \family default
17116 , and this gap can make some warnings seem arcane or just right down plain
17117  silly.
17118 \end_layout
17119
17120 \begin_layout Standard
17121 This document is an excellent testing bed for the feature, and it should
17122  provide quite a few warnings for you to fiddle with.
17123  Since computers are only so smart, expect most of the warnings to be false
17124  alarms, though.
17125 \end_layout
17126
17127 \begin_layout Subsection
17128 How to fine tune it
17129 \end_layout
17130
17131 \begin_layout Standard
17132 Sometimes, you'll find that 
17133 \family sans
17134 ChkTeX
17135 \family default
17136  makes more noise than suits your mood.
17137  Then you can choose not to use it, wait until your mood changes, or try
17138  to customize 
17139 \family sans
17140 ChkTeX
17141 \family default
17142  to get better along with you.
17143  Another choice in the most desperate situations is to use 
17144 \family sans
17145 View\SpecialChar \menuseparator
17146 Remove
17147 \begin_inset space ~
17148 \end_inset
17149
17150 All
17151 \begin_inset space ~
17152 \end_inset
17153
17154 Error
17155 \begin_inset space ~
17156 \end_inset
17157
17158 Boxes
17159 \family default
17160 , which will get rid of all warnings instantly.
17161 \end_layout
17162
17163 \begin_layout Standard
17164 Although 
17165 \family sans
17166 ChkTeX
17167 \family default
17168  
17169 \emph on
17170 is
17171 \emph default
17172  very configurable and extensible, you shouldn't expect to solve all problems
17173  with 
17174 \family sans
17175 ChkTeX
17176 \family default
17177  in LyX this way.
17178  Since LyX has to generate a somewhat special LaTeX file to be able to match
17179  the line numbers from the 
17180 \family sans
17181 ChkTeX
17182 \family default
17183  output
17184 \begin_inset Foot
17185 status collapsed
17186
17187 \begin_layout Plain Layout
17188 You can inspect the specific output from 
17189 \family sans
17190 chktex
17191 \family default
17192  by using 
17193 \family sans
17194 Edit\SpecialChar \menuseparator
17195 View
17196 \begin_inset space ~
17197 \end_inset
17198
17199 LaTeX
17200 \begin_inset space ~
17201 \end_inset
17202
17203 Log
17204 \family default
17205  right after a 
17206 \family sans
17207 chktex
17208 \family default
17209  run.
17210 \end_layout
17211
17212 \end_inset
17213
17214  to the internal document structure, some of the warnings will not seen
17215  to appear correctly.
17216  There are two things you can do about this:
17217 \end_layout
17218
17219 \begin_layout Itemize
17220 Fine tune the 
17221 \family sans
17222 ChkTeX
17223 \family default
17224  invocation command line in 
17225 \family sans
17226 Preferences
17227 \family default
17228  (tabs 
17229 \family sans
17230 Outputs
17231 \family default
17232
17233 \family sans
17234 Misc
17235 \family default
17236 ), or the global 
17237 \family sans
17238 ChkTeX
17239 \family default
17240  installation configuration file (usually with the file 
17241 \family typewriter
17242 chktexrc
17243 \family default
17244 ).
17245  See below to learn what warnings can be enabled and disabled on the command
17246  line.
17247  
17248 \end_layout
17249
17250 \begin_layout Itemize
17251 Export your document as a raw LaTeX file using 
17252 \family sans
17253 File\SpecialChar \menuseparator
17254 Export\SpecialChar \menuseparator
17255 LaTeX
17256 \family default
17257  and run 
17258 \family typewriter
17259 chktex
17260 \family default
17261  manually on that.
17262  Invoked in this way, it can be a hassle to find the corresponding place
17263  in the document inside LyX, but with a little patience, you should be able
17264  to do it.
17265 \end_layout
17266
17267 \begin_layout Standard
17268 Here follows the warning messages that can be enabled and disabled in 
17269 \family sans
17270 Preferences
17271 \family default
17272 .
17273  Use 
17274 \family typewriter
17275 -n#
17276 \family default
17277  to disable a warning, and 
17278 \family typewriter
17279 -w#
17280 \family default
17281  to enable a warning.
17282  The emphasized entries are disabled by default, because the default is
17283  "
17284 \family typewriter
17285 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
17286 \family default
17287 ".
17288 \end_layout
17289
17290 \begin_layout Standard
17291 Notice that you should only use the options that enable and disable warnings,
17292  because LyX relies on some of the other command line parameters to be set
17293  in a specific way to have a chance to communicate with 
17294 \family typewriter
17295 chktex
17296 \family default
17297 .
17298 \end_layout
17299
17300 \begin_layout Enumerate
17301
17302 \size small
17303 \emph on
17304 Command terminated with space.
17305 \end_layout
17306
17307 \begin_layout Enumerate
17308
17309 \size small
17310 Non-breaking space (
17311 \begin_inset Quotes eld
17312 \end_inset
17313
17314
17315 \family typewriter
17316 ~
17317 \family default
17318
17319 \begin_inset Quotes erd
17320 \end_inset
17321
17322 ) should have been used.
17323 \end_layout
17324
17325 \begin_layout Enumerate
17326
17327 \size small
17328 \emph on
17329 You should enclose the previous parenthesis with 
17330 \begin_inset Quotes eld
17331 \end_inset
17332
17333
17334 \family typewriter
17335 {}
17336 \family default
17337
17338 \begin_inset Quotes erd
17339 \end_inset
17340
17341 .
17342 \end_layout
17343
17344 \begin_layout Enumerate
17345
17346 \size small
17347 Italic correction (
17348 \begin_inset Quotes eld
17349 \end_inset
17350
17351
17352 \family typewriter
17353
17354 \backslash
17355 /
17356 \family default
17357
17358 \begin_inset Quotes erd
17359 \end_inset
17360
17361 ) found in non-italic buffer.
17362 \end_layout
17363
17364 \begin_layout Enumerate
17365
17366 \size small
17367 Italic correction (
17368 \begin_inset Quotes eld
17369 \end_inset
17370
17371
17372 \family typewriter
17373
17374 \backslash
17375 /
17376 \family default
17377
17378 \begin_inset Quotes erd
17379 \end_inset
17380
17381 ) found more than once.
17382 \end_layout
17383
17384 \begin_layout Enumerate
17385
17386 \size small
17387 \emph on
17388 No italic correction (
17389 \begin_inset Quotes eld
17390 \end_inset
17391
17392
17393 \family typewriter
17394
17395 \backslash
17396 /
17397 \family default
17398
17399 \begin_inset Quotes erd
17400 \end_inset
17401
17402 ) found.
17403 \end_layout
17404
17405 \begin_layout Enumerate
17406
17407 \size small
17408 Accent command 
17409 \begin_inset Quotes eld
17410 \end_inset
17411
17412
17413 \family typewriter
17414 cmd
17415 \family default
17416
17417 \begin_inset Quotes erd
17418 \end_inset
17419
17420  needs use of 
17421 \begin_inset Quotes eld
17422 \end_inset
17423
17424
17425 \family typewriter
17426 cmd
17427 \family default
17428
17429 \begin_inset Quotes erd
17430 \end_inset
17431
17432 .
17433 \end_layout
17434
17435 \begin_layout Enumerate
17436
17437 \size small
17438 Wrong length of dash may have been used.
17439 \end_layout
17440
17441 \begin_layout Enumerate
17442
17443 \size small
17444 \emph on
17445 \begin_inset Quotes eld
17446 \end_inset
17447
17448
17449 \family typewriter
17450 %s
17451 \family default
17452
17453 \begin_inset Quotes erd
17454 \end_inset
17455
17456  expected, found 
17457 \begin_inset Quotes eld
17458 \end_inset
17459
17460
17461 \family typewriter
17462 %s
17463 \family default
17464
17465 \begin_inset Quotes erd
17466 \end_inset
17467
17468 .
17469 \end_layout
17470
17471 \begin_layout Enumerate
17472
17473 \size small
17474 Solo 
17475 \begin_inset Quotes eld
17476 \end_inset
17477
17478
17479 \family typewriter
17480 %s
17481 \family default
17482
17483 \begin_inset Quotes erd
17484 \end_inset
17485
17486  found.
17487 \end_layout
17488
17489 \begin_layout Enumerate
17490
17491 \size small
17492 You should use 
17493 \begin_inset Quotes eld
17494 \end_inset
17495
17496
17497 \family typewriter
17498 %s
17499 \family default
17500
17501 \begin_inset Quotes erd
17502 \end_inset
17503
17504  to achieve an ellipsis.
17505 \end_layout
17506
17507 \begin_layout Enumerate
17508
17509 \size small
17510 Inter-word spacing (
17511 \begin_inset Quotes eld
17512 \end_inset
17513
17514
17515 \family typewriter
17516
17517 \backslash
17518
17519 \family default
17520  
17521 \begin_inset Quotes eld
17522 \end_inset
17523
17524 ) should perhaps be used.
17525 \end_layout
17526
17527 \begin_layout Enumerate
17528
17529 \size small
17530 Inter-sentence spacing (
17531 \begin_inset Quotes eld
17532 \end_inset
17533
17534
17535 \family typewriter
17536
17537 \backslash
17538 @
17539 \family default
17540
17541 \begin_inset Quotes erd
17542 \end_inset
17543
17544 ) should perhaps be used.
17545 \end_layout
17546
17547 \begin_layout Enumerate
17548
17549 \size small
17550 Could not find argument for command.
17551 \end_layout
17552
17553 \begin_layout Enumerate
17554
17555 \size small
17556 No match found for 
17557 \begin_inset Quotes eld
17558 \end_inset
17559
17560
17561 \family typewriter
17562 %s
17563 \family default
17564
17565 \begin_inset Quotes erd
17566 \end_inset
17567
17568 .
17569 \end_layout
17570
17571 \begin_layout Enumerate
17572
17573 \size small
17574 Math mode still on at end of LaTeX file.
17575 \end_layout
17576
17577 \begin_layout Enumerate
17578
17579 \size small
17580 Number of 
17581 \begin_inset Quotes eld
17582 \end_inset
17583
17584
17585 \family typewriter
17586 char
17587 \family default
17588
17589 \begin_inset Quotes erd
17590 \end_inset
17591
17592  doesn't match the number of 
17593 \begin_inset Quotes eld
17594 \end_inset
17595
17596
17597 \family typewriter
17598 char
17599 \family default
17600
17601 \begin_inset Quotes erd
17602 \end_inset
17603
17604 .
17605 \end_layout
17606
17607 \begin_layout Enumerate
17608
17609 \size small
17610 You should use either 
17611 \family typewriter
17612
17613 \begin_inset Quotes eld
17614 \end_inset
17615
17616
17617 \family default
17618  or 
17619 \family typewriter
17620
17621 \begin_inset Quotes erd
17622 \end_inset
17623
17624
17625 \family default
17626  as an alternative to 
17627 \begin_inset Quotes eld
17628 \end_inset
17629
17630
17631 \family typewriter
17632 "
17633 \family default
17634
17635 \begin_inset Quotes erd
17636 \end_inset
17637
17638 .
17639 \end_layout
17640
17641 \begin_layout Enumerate
17642
17643 \size small
17644 You should use "
17645 \family typewriter
17646 '
17647 \family default
17648 " (ASCII 39) instead of "
17649 \family typewriter
17650 ´
17651 \family default
17652 " (ASCII 180).
17653 \end_layout
17654
17655 \begin_layout Enumerate
17656
17657 \size small
17658 User-specified pattern found.
17659 \end_layout
17660
17661 \begin_layout Enumerate
17662
17663 \size small
17664 This command might not be intended.
17665 \end_layout
17666
17667 \begin_layout Enumerate
17668
17669 \size small
17670 \emph on
17671 Comment displayed.
17672 \end_layout
17673
17674 \begin_layout Enumerate
17675
17676 \size small
17677 Either 
17678 \family typewriter
17679 ''
17680 \backslash
17681 ,'
17682 \family default
17683  or 
17684 \family typewriter
17685 '
17686 \backslash
17687 ,''
17688 \family default
17689  will look better.
17690 \end_layout
17691
17692 \begin_layout Enumerate
17693
17694 \size small
17695 Delete this space to maintain correct page references.
17696 \end_layout
17697
17698 \begin_layout Enumerate
17699
17700 \size small
17701 \emph on
17702 You might wish to put this between a pair of 
17703 \begin_inset Quotes eld
17704 \end_inset
17705
17706
17707 \family typewriter
17708 {}
17709 \family default
17710
17711 \begin_inset Quotes erd
17712 \end_inset
17713
17714 .
17715 \end_layout
17716
17717 \begin_layout Enumerate
17718
17719 \size small
17720 You ought to remove spaces in front of punctuation.
17721 \end_layout
17722
17723 \begin_layout Enumerate
17724
17725 \size small
17726 Could not execute LaTeX command.
17727 \end_layout
17728
17729 \begin_layout Enumerate
17730
17731 \size small
17732 Don't use 
17733 \family typewriter
17734
17735 \backslash
17736 /
17737 \family default
17738  in front of small punctuation.
17739 \end_layout
17740
17741 \begin_layout Enumerate
17742
17743 \family typewriter
17744 \size small
17745 $
17746 \backslash
17747 times$
17748 \family default
17749  may look prettier here.
17750 \end_layout
17751
17752 \begin_layout Enumerate
17753
17754 \size small
17755 \emph on
17756 Multiple spaces detected in output.
17757 \end_layout
17758
17759 \begin_layout Enumerate
17760
17761 \size small
17762 This text may be ignored.
17763 \end_layout
17764
17765 \begin_layout Enumerate
17766
17767 \size small
17768 Use 
17769 \family typewriter
17770
17771 \begin_inset Quotes eld
17772 \end_inset
17773
17774
17775 \family default
17776  to begin quotation, not 
17777 \family typewriter
17778 '
17779 \family default
17780 .
17781 \end_layout
17782
17783 \begin_layout Enumerate
17784
17785 \size small
17786 Use 
17787 \family typewriter
17788 '
17789 \family default
17790  to end quotation, not 
17791 \family typewriter
17792
17793 \begin_inset Quotes eld
17794 \end_inset
17795
17796
17797 \family default
17798 .
17799 \end_layout
17800
17801 \begin_layout Enumerate
17802
17803 \size small
17804 Don't mix quotes.
17805 \end_layout
17806
17807 \begin_layout Enumerate
17808
17809 \size small
17810 You should perhaps use 
17811 \begin_inset Quotes eld
17812 \end_inset
17813
17814
17815 \family typewriter
17816 cmd
17817 \family default
17818
17819 \begin_inset Quotes erd
17820 \end_inset
17821
17822  instead.
17823 \end_layout
17824
17825 \begin_layout Enumerate
17826
17827 \size small
17828 You should put a space in front of/after parenthesis.
17829 \end_layout
17830
17831 \begin_layout Enumerate
17832
17833 \size small
17834 You should avoid spaces in front of/after parenthesis.
17835 \end_layout
17836
17837 \begin_layout Enumerate
17838
17839 \size small
17840 \emph on
17841 You should not use punctuation in front of/after quotes.
17842 \end_layout
17843
17844 \begin_layout Enumerate
17845
17846 \size small
17847 Double space found.
17848 \end_layout
17849
17850 \begin_layout Enumerate
17851
17852 \size small
17853 You should put punctuation outside inner/inside display math mode.
17854 \end_layout
17855
17856 \begin_layout Enumerate
17857
17858 \size small
17859 You ought to not use primitive TeX in LaTeX code.
17860 \end_layout
17861
17862 \begin_layout Enumerate
17863
17864 \size small
17865 You should remove spaces in front of 
17866 \begin_inset Quotes eld
17867 \end_inset
17868
17869
17870 \family typewriter
17871 %s
17872 \family default
17873
17874 \begin_inset Quotes erd
17875 \end_inset
17876
17877
17878 \end_layout
17879
17880 \begin_layout Enumerate
17881
17882 \size small
17883 \begin_inset Quotes eld
17884 \end_inset
17885
17886
17887 \family typewriter
17888 %s
17889 \family default
17890
17891 \begin_inset Quotes erd
17892 \end_inset
17893
17894  is normally not followed by 
17895 \begin_inset Quotes eld
17896 \end_inset
17897
17898
17899 \family typewriter
17900 %c
17901 \family default
17902
17903 \begin_inset Quotes erd
17904 \end_inset
17905
17906 .
17907 \end_layout
17908
17909 \begin_layout Standard
17910 In later versions of LyX, we hope to provide a more complete interface to
17911  this tool (and it's smaller cousin 
17912 \family typewriter
17913 lacheck
17914 \family default
17915 ) to exploit the full power of it.
17916  But it's not exactly useless as it is now: go try it on one of your existing
17917  documents of a certain length and be surprised.
17918 \end_layout
17919
17920 \begin_layout Section
17921 Version Control in LyX
17922 \end_layout
17923
17924 \begin_layout Standard
17925 by
17926 \noun on
17927  Lars Gullik Bjønnes, 
17928 \noun default
17929 updated by 
17930 \noun on
17931 Pavel Sanda
17932 \end_layout
17933
17934 \begin_layout Subsection
17935 Introduction
17936 \end_layout
17937
17938 \begin_layout Standard
17939 A friend of mine wanted to try LyX for a group project.
17940  When he didn't find support for version control or file locking, he dropped
17941  it.
17942  This angered me a bit, so I thought that I should at least make support
17943  for RCS (with the possibility of CVS and/or SCCS as a future improvement.)
17944  This has now been done.
17945  LyX now supports some of the most basic RCS commands.
17946  If you need to something a bit more sophisticated you will have to do that
17947  manually in an xterm.
17948 \end_layout
17949
17950 \begin_layout Standard
17951 Before you begin to use the version control features in LyX, you should
17952  read 
17953 \begin_inset Quotes eld
17954 \end_inset
17955
17956 rcsintro
17957 \begin_inset Quotes erd
17958 \end_inset
17959
17960  (a man file, read it with 
17961 \family typewriter
17962 man rcsintro
17963 \family default
17964 ).
17965  This file describes all the basic features of RCS.
17966  You should especially notice the comment about a RCS directory, and the
17967  notion of a master RCS file (the file ending in 
17968 \family typewriter
17969 ,v
17970 \family default
17971 ).
17972 \end_layout
17973
17974 \begin_layout Standard
17975 Later basic CVS/SVN support was added.
17976  You should be familiar with CVS/SVN usage before start using it under LyX.
17977  Most of the log messages are not currently displayed after operations -
17978  you can check them in terminal window if unsure.
17979 \end_layout
17980
17981 \begin_layout Standard
17982 The implementation in LyX assumes a recent version of the GNU RCS or CVS/SVN
17983  package—no guarantees are made for older versions.
17984 \end_layout
17985
17986 \begin_layout Standard
17987 For introducing your own external commands consult vc-command in the manual
17988  of LyX functions.
17989 \end_layout
17990
17991 \begin_layout Subsection
17992 RCS commands in LyX
17993 \end_layout
17994
17995 \begin_layout Standard
17996 The following sections describe the RCS commands supported by LyX.
17997  You can find them in the 
17998 \family sans
17999 File\SpecialChar \menuseparator
18000 Version
18001 \begin_inset space ~
18002 \end_inset
18003
18004 Control
18005 \family default
18006  submenu.
18007  LyX was tested against RCS 5.7.
18008 \end_layout
18009
18010 \begin_layout Subsubsection
18011
18012 \family sans
18013 Register
18014 \end_layout
18015
18016 \begin_layout Standard
18017 If your document is not under revision control, this is the only item shown
18018  in the menu.
18019  And if it is under revision control, the 
18020 \family sans
18021 Register
18022 \family default
18023  item is not visible.
18024  
18025 \end_layout
18026
18027 \begin_layout Standard
18028 This command registers your document with RCS (unless you are under the
18029  directory managed by CVS)\SpecialChar \@.
18030  You are asked interactively to supply an initial
18031  description of the document.
18032  The document is now set in Read-Only mode and you have to 
18033 \family sans
18034 Check
18035 \begin_inset space ~
18036 \end_inset
18037
18038 Out
18039 \begin_inset space ~
18040 \end_inset
18041
18042 For
18043 \begin_inset space ~
18044 \end_inset
18045
18046 Edit
18047 \family default
18048 , before making any changes to it.
18049  A document under revision control has a 
18050 \begin_inset Quotes eld
18051 \end_inset
18052
18053 [RCS:<version> <locker>]
18054 \begin_inset Quotes erd
18055 \end_inset
18056
18057  item tagged to the filename in the minibuffer.
18058 \end_layout
18059
18060 \begin_layout Standard
18061 RCS command that is run: 
18062 \family typewriter
18063 ci -q -u -i -t-"<initial description>" <file-name>
18064 \end_layout
18065
18066 \begin_layout Standard
18067 Read 
18068 \family typewriter
18069 man ci
18070 \family default
18071  to understand the switches.
18072  
18073 \end_layout
18074
18075 \begin_layout Subsubsection
18076
18077 \family sans
18078 Check In Changes
18079 \end_layout
18080
18081 \begin_layout Standard
18082 When you are finished editing a file, you check in your changes.
18083  When you do this, you are asked for a description of the changes.
18084  This is stored in the history log.
18085  The version number is bumped, your changes are applied to the master RCS
18086  file, the document is unlocked and set to Read-Only mode.
18087  
18088 \end_layout
18089
18090 \begin_layout Standard
18091 RCS command: 
18092 \family typewriter
18093 ci -q -u -m"<description>" <file-name>
18094 \end_layout
18095
18096 \begin_layout Subsubsection
18097
18098 \family sans
18099 Check Out For Edit
18100 \end_layout
18101
18102 \begin_layout Standard
18103 By doing this you lock the document so that only you can edit it.
18104  This will also make the document Read-Write only for you.
18105  You will usually continue editing for a while and when you are finished
18106  you check in your changes.
18107  The status line is changed to reflect that you have locked the file.
18108  
18109 \end_layout
18110
18111 \begin_layout Standard
18112 RCS command: 
18113 \family typewriter
18114 co -q -l <file-name>
18115 \end_layout
18116
18117 \begin_layout Subsubsection
18118
18119 \family sans
18120 Revert To Repository Version
18121 \end_layout
18122
18123 \begin_layout Standard
18124 This will discard all changes made to the document since the last check
18125  in.
18126  You get a warning before changes are discarded.
18127 \end_layout
18128
18129 \begin_layout Standard
18130 RCS command: 
18131 \family typewriter
18132 co -f -u<version> <file-name>
18133 \end_layout
18134
18135 \begin_layout Subsubsection
18136
18137 \family sans
18138 Undo Last Checkin
18139 \end_layout
18140
18141 \begin_layout Standard
18142 This makes as if the last check in never happened.
18143  No changes are made to the document loaded into LyX, but the last version
18144  is removed from the master RCS file.
18145  
18146 \end_layout
18147
18148 \begin_layout Standard
18149 RCS command: 
18150 \family typewriter
18151 rcs -o<version> <file-name>
18152 \end_layout
18153
18154 \begin_layout Subsubsection
18155
18156 \family sans
18157 Show History
18158 \end_layout
18159
18160 \begin_layout Standard
18161 This show the complete history of the RCS document.
18162  The output of 
18163 \family typewriter
18164 rlog <file-name>
18165 \family default
18166  is shown in a browser.
18167  See 
18168 \family typewriter
18169 man rlog
18170 \family default
18171  for more info.
18172 \end_layout
18173
18174 \begin_layout Subsection
18175 CVS commands in LyX
18176 \end_layout
18177
18178 \begin_layout Standard
18179 CVS is now partially supported by LyX.
18180  You can find the commands in the 
18181 \family sans
18182 File\SpecialChar \menuseparator
18183 Version
18184 \begin_inset space ~
18185 \end_inset
18186
18187 Control
18188 \family default
18189  submenu.
18190 \end_layout
18191
18192 \begin_layout Subsubsection
18193
18194 \family sans
18195 Register
18196 \end_layout
18197
18198 \begin_layout Standard
18199 If your document is not under revision control, this is the only item shown
18200  in the menu.
18201  And if it is under revision control, the 
18202 \family sans
18203 \bar under
18204 R
18205 \bar default
18206 egister
18207 \family default
18208  item is not visible.
18209  
18210 \end_layout
18211
18212 \begin_layout Standard
18213 This command registers in CVS your document ONLY in case you have already
18214  the documents directory under CVS control (in particular 
18215 \family typewriter
18216 CVS/Entries
18217 \family default
18218  file exists).
18219  This means you have to checkout the archive by yourself.
18220  
18221 \end_layout
18222
18223 \begin_layout Standard
18224 Then you are asked interactively to supply an initial description of the
18225  document.
18226  Don't forget that registered file is not yet commited.
18227 \end_layout
18228
18229 \begin_layout Standard
18230 CVS command that is run: 
18231 \family typewriter
18232 cvs -q add -m
18233 \begin_inset Quotes erd
18234 \end_inset
18235
18236 <entered message>" 
18237 \begin_inset Quotes eld
18238 \end_inset
18239
18240 <file-name>
18241 \begin_inset Quotes erd
18242 \end_inset
18243
18244
18245 \end_layout
18246
18247 \begin_layout Standard
18248 Read 
18249 \family typewriter
18250 man svn
18251 \family default
18252  to understand the switches.
18253  
18254 \end_layout
18255
18256 \begin_layout Subsubsection
18257
18258 \family sans
18259 Check In Changes
18260 \end_layout
18261
18262 \begin_layout Standard
18263 When you are finished editing a file, you commit your changes.
18264  When you do this, you are asked for a description of the changes.
18265  After that changes are commited.
18266 \end_layout
18267
18268 \begin_layout Standard
18269 CVS command: 
18270 \family typewriter
18271 cvs -q commit -m"<description>" "<file-name>"
18272 \end_layout
18273
18274 \begin_layout Subsubsection
18275
18276 \family sans
18277 Revert To Repository Version
18278 \end_layout
18279
18280 \begin_layout Standard
18281 This will discard all changes made to the document since the last check
18282  in.
18283  You get a warning before changes are discarded.
18284  Firstly the file is deleted, secondly CVS update command is run.
18285 \end_layout
18286
18287 \begin_layout Standard
18288 CVS command: 
18289 \family typewriter
18290 cvs update 
18291 \begin_inset Quotes eld
18292 \end_inset
18293
18294 <file-name>
18295 \begin_inset Quotes erd
18296 \end_inset
18297
18298
18299 \end_layout
18300
18301 \begin_layout Subsubsection
18302
18303 \family sans
18304 Show History
18305 \end_layout
18306
18307 \begin_layout Standard
18308 This show the complete history of the CVS document.
18309  The output of 
18310 \family typewriter
18311 cvs log 
18312 \begin_inset Quotes eld
18313 \end_inset
18314
18315 <file-name>
18316 \begin_inset Quotes erd
18317 \end_inset
18318
18319
18320 \family default
18321  is shown in a browser.
18322 \end_layout
18323
18324 \begin_layout Subsection
18325 SVN commands in LyX
18326 \end_layout
18327
18328 \begin_layout Standard
18329 SVN is now partially supported by LyX.
18330  You can find the commands in the 
18331 \family sans
18332 File\SpecialChar \menuseparator
18333 Version
18334 \begin_inset space ~
18335 \end_inset
18336
18337 Control
18338 \family default
18339  submenu.
18340  Please note that if you use password protected access to repository via
18341  ssh, you will be asked in terminal window.
18342  LyX was tested against SVN 1.5 and 1.6
18343 \begin_inset Foot
18344 status collapsed
18345
18346 \begin_layout Plain Layout
18347 Most of the commands will work with 1.4 too, see 
18348 \begin_inset CommandInset ref
18349 LatexCommand ref
18350 reference "sub:SVN-Repo-Update"
18351
18352 \end_inset
18353
18354 .
18355 \end_layout
18356
18357 \end_inset
18358
18359
18360 \end_layout
18361
18362 \begin_layout Subsubsection
18363
18364 \family sans
18365 Register
18366 \end_layout
18367
18368 \begin_layout Standard
18369 If your document is not under revision control, this is the only item shown
18370  in the menu.
18371  And if it is under revision control, the 
18372 \family sans
18373 \bar under
18374 R
18375 \bar default
18376 egister
18377 \family default
18378  item is not visible.
18379  
18380 \end_layout
18381
18382 \begin_layout Standard
18383 This command registers in SVN your document ONLY in case you have already
18384  the documents directory under SVN control (in particular 
18385 \family typewriter
18386 .svn/entries
18387 \family default
18388  file exists).
18389  This means you have to checkout the archive by yourself.
18390  
18391 \end_layout
18392
18393 \begin_layout Standard
18394 Then you are asked interactively to supply an initial description of the
18395  document.
18396  Don't forget that registered file is not yet commited.
18397 \end_layout
18398
18399 \begin_layout Standard
18400 SVN command that is run: 
18401 \family typewriter
18402 svn add -q 
18403 \begin_inset Quotes eld
18404 \end_inset
18405
18406 <file-name>
18407 \begin_inset Quotes erd
18408 \end_inset
18409
18410
18411 \end_layout
18412
18413 \begin_layout Standard
18414 Read 
18415 \family typewriter
18416 man svn
18417 \family default
18418  to understand the switches.
18419  
18420 \end_layout
18421
18422 \begin_layout Subsubsection
18423
18424 \family sans
18425 Check In Changes
18426 \end_layout
18427
18428 \begin_layout Standard
18429 When you are finished editing a file, you commit your changes.
18430  When you do this, you are asked for a description of the changes.
18431  After that changes are commited.
18432 \end_layout
18433
18434 \begin_layout Standard
18435 SVN command:
18436 \begin_inset Foot
18437 status collapsed
18438
18439 \begin_layout Plain Layout
18440 In case locking is not enabled.
18441  See Section 
18442 \begin_inset CommandInset ref
18443 LatexCommand ref
18444 reference "subsec:SVN-File-Locking"
18445
18446 \end_inset
18447
18448 .
18449 \end_layout
18450
18451 \end_inset
18452
18453  
18454 \family typewriter
18455 svn commit -q -m"<description>" <file-name>
18456 \end_layout
18457
18458 \begin_layout Subsubsection
18459
18460 \family sans
18461 Check Out For Edit
18462 \end_layout
18463
18464 \begin_layout Standard
18465 Updates the changes of this file from the repository.
18466  Be sure you understand SVN merging and conflicts resolving before using
18467  this function, because all conflicts has to be resolved manually by you!
18468 \end_layout
18469
18470 \begin_layout Standard
18471 SVN command:
18472 \begin_inset Foot
18473 status collapsed
18474
18475 \begin_layout Plain Layout
18476 Ditto.
18477 \end_layout
18478
18479 \end_inset
18480
18481  
18482 \family typewriter
18483 svn update 
18484 \begin_inset Quotes eld
18485 \end_inset
18486
18487 <file-name>
18488 \begin_inset Quotes erd
18489 \end_inset
18490
18491
18492 \end_layout
18493
18494 \begin_layout Subsubsection
18495
18496 \family sans
18497 Revert To Repository Version
18498 \end_layout
18499
18500 \begin_layout Standard
18501 This will discard all changes made to the document since the last check
18502  in.
18503  You get a warning before changes are discarded.
18504  
18505 \end_layout
18506
18507 \begin_layout Standard
18508 SVN command: 
18509 \family typewriter
18510 svn revert -q 
18511 \begin_inset Quotes eld
18512 \end_inset
18513
18514 <file-name>
18515 \begin_inset Quotes erd
18516 \end_inset
18517
18518
18519 \end_layout
18520
18521 \begin_layout Subsubsection
18522 \begin_inset CommandInset label
18523 LatexCommand label
18524 name "sub:SVN-Repo-Update"
18525
18526 \end_inset
18527
18528 Update of the local directory checkout from repository
18529 \begin_inset Foot
18530 status collapsed
18531
18532 \begin_layout Plain Layout
18533 Note that this command will work only with subversion 
18534 \begin_inset Formula $\geqq1.5$
18535 \end_inset
18536
18537
18538 \end_layout
18539
18540 \end_inset
18541
18542
18543 \end_layout
18544
18545 \begin_layout Standard
18546 All the commands above have one shortcomming - they deal with the current
18547  document only.
18548  Once your document contains pictures, includes external 
18549 \begin_inset Flex CharStyle:Code
18550 status collapsed
18551
18552 \begin_layout Plain Layout
18553 .tex
18554 \end_layout
18555
18556 \end_inset
18557
18558  files and so on administration becomes more complicated.
18559  LyX now supports updating the whole tree in which resides the document
18560 \begin_inset Foot
18561 status collapsed
18562
18563 \begin_layout Plain Layout
18564 One need to organize the files structure so that all external files are
18565  in the same directory or subdirectories of the document.
18566  
18567 \end_layout
18568
18569 \end_inset
18570
18571 .
18572  This become especially useful once you cooperate with people which neither
18573  know about subversion management nor they have ambition to commit additional
18574  material to the repository.
18575  
18576 \end_layout
18577
18578 \begin_layout Standard
18579 \begin_inset Flex CharStyle:Code
18580 status collapsed
18581
18582 \begin_layout Plain Layout
18583 Update local directory from repository
18584 \end_layout
18585
18586 \end_inset
18587
18588  command updates the whole directory and in case of merge conflicts local
18589  version of the files are left, so no unintended data loss occurs.
18590  If local changes are detected user is warned before update starts.
18591 \end_layout
18592
18593 \begin_layout Labeling
18594 \labelwidthstring 00.00.0000
18595 SVN
18596 \begin_inset space ~
18597 \end_inset
18598
18599 commands: 
18600 \begin_inset space ~
18601 \end_inset
18602
18603
18604 \begin_inset Newline newline
18605 \end_inset
18606
18607
18608 \begin_inset Flex CharStyle:Code
18609 status collapsed
18610
18611 \begin_layout Plain Layout
18612 svn diff $path
18613 \end_layout
18614
18615 \end_inset
18616
18617  (Ask if changes are detected.)
18618 \begin_inset Newline newline
18619 \end_inset
18620
18621
18622 \begin_inset Flex CharStyle:Code
18623 status collapsed
18624
18625 \begin_layout Plain Layout
18626 svn update --accept mine-full $path
18627 \end_layout
18628
18629 \end_inset
18630
18631
18632 \end_layout
18633
18634 \begin_layout Standard
18635 where 
18636 \begin_inset Flex CharStyle:Code
18637 status collapsed
18638
18639 \begin_layout Plain Layout
18640 $path
18641 \end_layout
18642
18643 \end_inset
18644
18645  stands for the path to the document.
18646 \end_layout
18647
18648 \begin_layout Subsubsection
18649
18650 \family sans
18651 Show History
18652 \end_layout
18653
18654 \begin_layout Standard
18655 This show the complete history of the SVN document.
18656  The output of 
18657 \family typewriter
18658 svn log 
18659 \begin_inset Quotes eld
18660 \end_inset
18661
18662 <file-name>
18663 \begin_inset Quotes erd
18664 \end_inset
18665
18666
18667 \family default
18668  is shown in a browser.
18669 \end_layout
18670
18671 \begin_layout Subsubsection
18672 File Locking
18673 \begin_inset CommandInset label
18674 LatexCommand label
18675 name "subsec:SVN-File-Locking"
18676
18677 \end_inset
18678
18679
18680 \end_layout
18681
18682 \begin_layout Standard
18683 The file exchange through various revision control systems brings the problem
18684  of merge conflicts in case two different users try to edit the same (parts
18685  of) document.
18686  When such conflict happens it needs manual resolving and one reasonable
18687  alternative is to provide some kind of locking mechanism, which guarantees
18688  that only one user is allowed to edit file at the given time.
18689 \end_layout
18690
18691 \begin_layout Standard
18692 SVN has two mechanisms to provide such kind of mutual exclusivity for file
18693  access - locks and automatical setting of write permissions (see sec.
18694  
18695 \begin_inset CommandInset ref
18696 LatexCommand ref
18697 reference "subsec:Automatical-Locking-Property"
18698
18699 \end_inset
18700
18701 ) based on 
18702 \begin_inset Flex CharStyle:Code
18703 status collapsed
18704
18705 \begin_layout Plain Layout
18706 svn:needs-lock
18707 \end_layout
18708
18709 \end_inset
18710
18711  file svn property
18712 \begin_inset Foot
18713 status open
18714
18715 \begin_layout Plain Layout
18716 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
18717 \end_layout
18718
18719 \end_inset
18720
18721 .
18722  In a case this property is detected for a given document LyX starts to
18723  use SVN locks for document editing automatically and the whole check-in/out
18724  mechanism switches to the same regimen as for RCS.
18725  This in particular means there are two different modes how file is used
18726  in LyX:
18727 \end_layout
18728
18729 \begin_layout Itemize
18730 Unlocked state.
18731  The loaded file is in the read-only mode.
18732  For editation on needs to check-out.
18733  
18734 \emph on
18735 Check-out
18736 \emph default
18737  consists of update from repository and gaining write lock.
18738  If the lock is not possible to obtain, we remain in unlocked state.
18739 \end_layout
18740
18741 \begin_layout Itemize
18742 Locked state.
18743  The loaded file is in the 'normal' edit mode.
18744  No other user is allowed to edit the file.
18745  
18746 \emph on
18747 Check-in
18748 \emph default
18749  consists of commiting changes and releasing write-lock.
18750  If no changes have been made to the document, no commit will be produced
18751 \begin_inset Foot
18752 status collapsed
18753
18754 \begin_layout Plain Layout
18755 Don't be puzzled by the fact that you will be asked for commit message anyway.
18756 \end_layout
18757
18758 \end_inset
18759
18760  and only the write-lock will be released.
18761 \end_layout
18762
18763 \begin_layout Standard
18764 SVN commands:
18765 \end_layout
18766
18767 \begin_layout Labeling
18768 \labelwidthstring 00.00.0000
18769 Check-in:
18770 \family typewriter
18771  svn commit -q -m"<description>" "<file-name>"
18772 \begin_inset Newline newline
18773 \end_inset
18774
18775 svn unlock "<file-name>"
18776 \end_layout
18777
18778 \begin_layout Labeling
18779 \labelwidthstring 00.00.0000
18780 Check-out: 
18781 \family typewriter
18782 svn update "<file-name>"
18783 \begin_inset Newline newline
18784 \end_inset
18785
18786 svn lock "<file-name>"
18787 \end_layout
18788
18789 \begin_layout Subsubsection
18790
18791 \family typewriter
18792 \begin_inset CommandInset label
18793 LatexCommand label
18794 name "subsec:Automatical-Locking-Property"
18795
18796 \end_inset
18797
18798
18799 \family default
18800 Automatical Locking Property
18801 \end_layout
18802
18803 \begin_layout Standard
18804 The above mentioned automatical setting of write permissions of the .lyx
18805  file can be set through
18806 \family sans
18807 \bar under
18808  F
18809 \bar default
18810 ile\SpecialChar \menuseparator
18811
18812 \bar under
18813 V
18814 \bar default
18815 ersion
18816 \begin_inset space ~
18817 \end_inset
18818
18819 Control\SpecialChar \menuseparator
18820
18821 \bar under
18822 T
18823 \bar default
18824 oggle locking property
18825 \family default
18826 .
18827  This command is active only when the file is not locked on the svn server
18828  (i.e.
18829  you need to check-out before proceeding).
18830 \end_layout
18831
18832 \begin_layout Labeling
18833 \labelwidthstring 00.00.0000
18834 SVN
18835 \begin_inset space ~
18836 \end_inset
18837
18838 commands:
18839 \end_layout
18840
18841 \begin_layout Labeling
18842 \labelwidthstring 00.00.0000
18843 Set:
18844 \family typewriter
18845  svn propset svn:needs-lock ON "<file-name>"
18846 \end_layout
18847
18848 \begin_layout Labeling
18849 \labelwidthstring 00.00.0000
18850 Unset: 
18851 \family typewriter
18852 svn propdel svn:needs-lock "<file-name>"
18853 \end_layout
18854
18855 \begin_layout Subsubsection
18856 Revision Information in Documents
18857 \end_layout
18858
18859 \begin_layout Standard
18860 Currently there is no way how to provide such kind of information directly
18861  from LyX.
18862  There are possibilities how to activate it with the help of svn features,
18863  but each has its own drawbacks.
18864 \end_layout
18865
18866 \begin_layout Standard
18867 One possibility is to use svn keywords
18868 \begin_inset Foot
18869 status collapsed
18870
18871 \begin_layout Plain Layout
18872 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
18873 \end_layout
18874
18875 \end_inset
18876
18877 .
18878  In short -- you set file keywords property (e.g.
18879  
18880 \family sans
18881 svn propset svn:keywords 'Rev' file.lyx
18882 \family default
18883 ) and then paste keyword ERT
18884 \begin_inset Foot
18885 status collapsed
18886
18887 \begin_layout Plain Layout
18888 This is an easy way how to ensure that LyX won't break the line in the middle
18889  of keyword tag.
18890 \end_layout
18891
18892 \end_inset
18893
18894  tag in your document (e.g.
18895  
18896 \begin_inset ERT
18897 status open
18898
18899 \begin_layout Plain Layout
18900
18901 $Rev$
18902 \end_layout
18903
18904 \end_inset
18905
18906 ).
18907  This way svn client will automatically substitute revision number (e.g.
18908  
18909 \begin_inset ERT
18910 status open
18911
18912 \begin_layout Plain Layout
18913
18914 $Rev: 59 $
18915 \end_layout
18916
18917 \end_inset
18918
18919 ) after each update and commit.
18920  There are more problems with this approach.
18921  Firstly, the '$' character is used in TeX world for math equations, so
18922  any occurence of math formula 
18923 \begin_inset Formula $Rev$
18924 \end_inset
18925
18926  become 
18927 \begin_inset Formula $Rev:59$
18928 \end_inset
18929
18930  in your LyX document.
18931  Similarly for other keywords like Id, Date, Author, etc.
18932  Secondly svn output is dependent on your locales, so its very easy that
18933  svn would produce some problematic strings once Date is used.
18934  Thirdly you get the whole 'Rev: 59' string in your document instead of
18935  the plain number.
18936  Until subversion implements user's custom keywords it will be hard to use
18937  this approach reliably or let LyX to support it directly .
18938 \end_layout
18939
18940 \begin_layout Standard
18941 The second possibility would be to write your own external-material template
18942  which calls either 
18943 \begin_inset Flex CharStyle:Code
18944 status collapsed
18945
18946 \begin_layout Plain Layout
18947 svnversion
18948 \end_layout
18949
18950 \end_inset
18951
18952  utility or parses the output of 
18953 \begin_inset Flex CharStyle:Code
18954 status collapsed
18955
18956 \begin_layout Plain Layout
18957 svn info file.lyx
18958 \end_layout
18959
18960 \end_inset
18961
18962  command and returns the result back, when typeseting the document.
18963 \end_layout
18964
18965 \begin_layout Subsection
18966 SVN and Windows Environment
18967 \end_layout
18968
18969 \begin_layout Quote
18970 My inclination is to say that if the user cannot figure out the command
18971  line operations on their own fairly quickly, they would be well advised
18972  to use TortoiseSVN.
18973  ---P.
18974  A.
18975  Rubin
18976 \end_layout
18977
18978 \begin_layout Subsubsection
18979 Preparation
18980 \end_layout
18981
18982 \begin_layout Standard
18983 In addition to installing LyX, and having access to a Subversion repository,
18984  the user will need to install the Subversion client program.
18985  A Windows installer for the client program is available from 
18986 \begin_inset CommandInset href
18987 LatexCommand href
18988 name "CollabNet"
18989 target "http://www.collab.net/nonav/downloads/subversion/"
18990
18991 \end_inset
18992
18993 .
18994  The user may also want to install 
18995 \begin_inset CommandInset href
18996 LatexCommand href
18997 name "TortoiseSVN"
18998 target "http://tortoisesvn.tigris.org/"
18999
19000 \end_inset
19001
19002 , which integrates Subversion operations into the context (rightclick) menu
19003  of Windows Explorer.
19004  Operations done outside LyX will typically be more convenient using the
19005  Explorer context menu.
19006  Note that TortoiseSVN is not a replacement for the client program, which
19007  is what LyX itself will use.
19008 \end_layout
19009
19010 \begin_layout Subsubsection
19011 Bringing a document under Subversion control
19012 \end_layout
19013
19014 \begin_layout Standard
19015 Before a LyX document can be brought under version control in Subversion,
19016  its parent directory needs to be under version control.
19017  If the document is being added to a project already in the repository,
19018  this is accomplished by checking the project out to the directory where
19019  the new document will be placed.
19020  If the project itself is not yet under version control (for instance, if
19021  this document starts a new project), the directory must be imported into
19022  the repository.
19023  This is done outside LyX.
19024  Both import and checkout are easily accomplished from the Explorer context
19025  menu using TortoiseSVN, or alternatively can be done using the command
19026  line client at a DOS prompt.
19027  The procedure for importing the project using TortoiseSVN is described
19028  below, assuming an existing repository and a new project being started
19029  in 
19030 \family typewriter
19031 C:
19032 \backslash
19033 new project
19034 \family default
19035 .
19036  For information on using the Subversion client program, run 
19037 \family typewriter
19038 svn --help 
19039 \family default
19040 in a DOS shell.
19041 \end_layout
19042
19043 \begin_layout Enumerate
19044 Locate 
19045 \family typewriter
19046 C:
19047 \backslash
19048 new project 
19049 \family default
19050 in Windows Explorer, right click it, and select 
19051 \family typewriter
19052 TortoiseSVN > Repo-browser
19053 \family default
19054 .
19055  If necessary, adjust the URL for the repository, then click OK.
19056 \end_layout
19057
19058 \begin_layout Enumerate
19059 Right click the level of the repository under which you want to place the
19060  new project folder (typically the top level) and click 
19061 \family typewriter
19062 Create folder\SpecialChar \ldots{}
19063
19064 \family default
19065  Supply a name for the project folder and click OK.
19066  Add a message for the log file if desired, then click OK again.
19067  The new project folder should appear in the repository.
19068  Finally, click OK again to exit the repository browser.
19069 \end_layout
19070
19071 \begin_layout Enumerate
19072 Once again right click 
19073 \family typewriter
19074 C:
19075 \backslash
19076 new project
19077 \family default
19078 , this time selecting SVN Checkout\SpecialChar \ldots{}
19079  Select the URL of the project folder
19080  you just created in the repository, and set the checkout directory to 
19081 \family typewriter
19082 C:
19083 \backslash
19084 new project.
19085
19086 \family default
19087  Click OK.
19088  You will be warned about a non-empty folder; click OK to proceed.
19089  You should now have a 
19090 \family typewriter
19091 .svn
19092 \family default
19093  directory under 
19094 \family typewriter
19095 C:
19096 \backslash
19097 new project.
19098 \end_layout
19099
19100 \begin_layout Enumerate
19101 Create or open your document in LyX and click 
19102 \family sans
19103 \bar under
19104 F
19105 \bar default
19106 ile\SpecialChar \menuseparator
19107
19108 \bar under
19109 V
19110 \bar default
19111 ersion
19112 \begin_inset space ~
19113 \end_inset
19114
19115 Control\SpecialChar \menuseparator
19116
19117 \bar under
19118 R
19119 \bar default
19120 egister.
19121  
19122 \family default
19123 Add a log message and click OK to commit the document to version control.
19124 \end_layout
19125
19126 \begin_layout Standard
19127 From this point onward, you should have full functionality in the 
19128 \family sans
19129 \bar under
19130 F
19131 \bar default
19132 ile\SpecialChar \menuseparator
19133
19134 \bar under
19135 V
19136 \bar default
19137 ersion
19138 \begin_inset space ~
19139 \end_inset
19140
19141 Control
19142 \family default
19143  menu.
19144  You also have the option of checking the document in and out, viewing its
19145  history, etc.
19146  using the TortoiseSVN context menu in Windows Explorer or the Subversion
19147  client program from a command prompt.
19148 \end_layout
19149
19150 \begin_layout Subsection
19151 Further tuning
19152 \end_layout
19153
19154 \begin_layout Standard
19155 With the recent addition of the vc-command function LyX power users are
19156  allowed to create their own commands for revision control.
19157 \end_layout
19158
19159 \begin_layout Standard
19160 As an example you can see how two TortoiseSVN commands could be integrated
19161  directly:
19162 \end_layout
19163
19164 \begin_layout Description
19165 Commit: 
19166 \begin_inset Flex CharStyle:Code
19167 status collapsed
19168
19169 \begin_layout Plain Layout
19170 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
19171 \end_layout
19172
19173 \end_inset
19174
19175
19176 \end_layout
19177
19178 \begin_layout Description
19179 Revert: 
19180 \begin_inset Flex CharStyle:Code
19181 status collapsed
19182
19183 \begin_layout Plain Layout
19184 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
19185 \end_layout
19186
19187 \end_inset
19188
19189
19190 \end_layout
19191
19192 \begin_layout Section
19193 Literate Programming
19194 \end_layout
19195
19196 \begin_layout Standard
19197 Updated by 
19198 \noun on
19199 Kayvan Sylvan 
19200 \noun default
19201 (kayvan@sylvan.com)
19202 \noun on
19203
19204 \noun default
19205 original documentation written by 
19206 \noun on
19207 Edmar Wienskoski Jr.
19208
19209 \noun default
19210  (edmar-w-jr@technologist.com)
19211 \end_layout
19212
19213 \begin_layout Subsection
19214 Introduction
19215 \end_layout
19216
19217 \begin_layout Standard
19218 The main purpose of this documentation is to show you how to use LyX for
19219  literate programming.
19220  Where it is assumed that you are familiar with this programming technique,
19221  and know what 
19222 \begin_inset Quotes eld
19223 \end_inset
19224
19225 tangling
19226 \begin_inset Quotes erd
19227 \end_inset
19228
19229  and 
19230 \begin_inset Quotes eld
19231 \end_inset
19232
19233 weaving
19234 \begin_inset Quotes erd
19235 \end_inset
19236
19237  means.
19238  If that is not the case, please follow the web links provided in the following
19239  sections.
19240  There is a lot of good documentation out there covering old development
19241  history to the latest tools tips.
19242 \end_layout
19243
19244 \begin_layout Standard
19245 It is also assumed that you are familiar with LyX itself to a point that
19246  you are comfortable changing your LyX preferences, and X resources file.
19247  If that is not the case please refer to other LyX documentation to cover
19248  your specific needs.
19249 \end_layout
19250
19251 \begin_layout Subsection
19252 Literate Programming
19253 \end_layout
19254
19255 \begin_layout Standard
19256 From the Literate Programming FAQ: 
19257 \end_layout
19258
19259 \begin_layout Quotation
19260 Literate programming is the combination of documentation and source together
19261  in a fashion suited for reading by human beings.
19262  In fact, literate programs should be enjoyable reading, even inviting!
19263  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
19264  and documentation in a single file.
19265  Literate programming tools then parse the file to produce either readable
19266  documentation or compilable source.
19267  The WEB style of literate programming was created by D.
19268 \begin_inset space \thinspace{}
19269 \end_inset
19270
19271 g.
19272  Knuth during the development of his TeX typesetting software.
19273  
19274 \end_layout
19275
19276 \begin_layout Standard
19277 Another excerpt says:
19278 \end_layout
19279
19280 \begin_layout Quotation
19281
19282 \emph on
19283 How is literate programming different from verbose commenting?
19284 \end_layout
19285
19286 \begin_layout Quotation
19287 There are three distinguishing characteristics.
19288  In order of importance, they are: 
19289 \end_layout
19290
19291 \begin_deeper
19292 \begin_layout Itemize
19293 flexible order of elaboration 
19294 \end_layout
19295
19296 \begin_layout Itemize
19297 automatic support for browsing 
19298 \end_layout
19299
19300 \begin_layout Itemize
19301 typeset documentation, especially diagrams and mathematics 
19302 \end_layout
19303
19304 \end_deeper
19305 \begin_layout Standard
19306 Now that I sparked your curiosity, take a look in the references.
19307 \end_layout
19308
19309 \begin_layout Subsubsection
19310 References
19311 \end_layout
19312
19313 \begin_layout Standard
19314 The complete Literate Programming FAQ can be found at:
19315 \end_layout
19316
19317 \begin_layout Quote
19318 Literate Programming FAQ 
19319 \begin_inset Flex URL
19320 status collapsed
19321
19322 \begin_layout Plain Layout
19323
19324 http://shelob.ce.ttu.edu/daves/lpfaq/faq.html
19325 \end_layout
19326
19327 \end_inset
19328
19329
19330 \end_layout
19331
19332 \begin_layout Standard
19333 The FAQ lists 23 (twenty three!) different literate programming tools.
19334  Where some are specialized or 
19335 \begin_inset Quotes eld
19336 \end_inset
19337
19338 tailored
19339 \begin_inset Quotes erd
19340 \end_inset
19341
19342  for particular programming languages, while other have general scope.
19343  I selected 
19344 \noun on
19345 Noweb
19346 \noun default
19347  for my own use for several reasons:
19348 \end_layout
19349
19350 \begin_layout Itemize
19351 It can generate the documentation either in LaTeX or HTML.
19352 \end_layout
19353
19354 \begin_layout Itemize
19355 It has a open architecture, i.
19356 \begin_inset space \thinspace{}
19357 \end_inset
19358
19359 g.
19360 \begin_inset space \space{}
19361 \end_inset
19362
19363 it is easy to plug in new filters and to perform special processing that
19364  you may need.
19365  
19366 \end_layout
19367
19368 \begin_layout Itemize
19369 There is a good selection of filters available already (the HTML is one
19370  of them).
19371 \end_layout
19372
19373 \begin_layout Itemize
19374 It is free.
19375 \end_layout
19376
19377 \begin_layout Standard
19378 The Noweb web page can be found at: 
19379 \end_layout
19380
19381 \begin_layout Quote
19382 Noweb home page 
19383 \begin_inset Flex URL
19384 status collapsed
19385
19386 \begin_layout Plain Layout
19387
19388 http://www.cs.virginia.edu/~nr/noweb/
19389 \end_layout
19390
19391 \end_inset
19392
19393
19394 \end_layout
19395
19396 \begin_layout Standard
19397 Starting from there you can reach many other interesting links and even
19398  some literate program examples.
19399 \end_layout
19400
19401 \begin_layout Subsection
19402 LyX and Literate Programming
19403 \end_layout
19404
19405 \begin_layout Standard
19406 The LyX support for Literate Programming is provided by using the generic
19407  LyX converters mechanism.
19408  This support is provided in a 
19409 \begin_inset Quotes eld
19410 \end_inset
19411
19412 Noweb independent
19413 \begin_inset Quotes erd
19414 \end_inset
19415
19416  way, i.
19417 \begin_inset space \thinspace{}
19418 \end_inset
19419
19420 g.
19421 \begin_inset space \space{}
19422 \end_inset
19423
19424 you will be able to use this new LyX feature with some other literate programmin
19425 g tool of your choice by just changing your LyX preferences.
19426 \end_layout
19427
19428 \begin_layout Subsubsection
19429 Generating documents and code (weaving and tangling)
19430 \end_layout
19431
19432 \begin_layout Paragraph
19433 Selecting the document class
19434 \end_layout
19435
19436 \begin_layout Standard
19437 If you have installed Noweb and LyX successfully, whenever you open a new
19438  document or try to change the document class of an existing one, you will
19439  find that there are three new document classes available:
19440 \end_layout
19441
19442 \begin_layout Itemize
19443 Article (Noweb)
19444 \end_layout
19445
19446 \begin_layout Itemize
19447 Book (Noweb)
19448 \end_layout
19449
19450 \begin_layout Itemize
19451 Report (Noweb)
19452 \end_layout
19453
19454 \begin_layout Standard
19455 You must select one of them to create your literate documents from.
19456  
19457 \end_layout
19458
19459 \begin_layout Standard
19460 Note that literate documents are not limited to these three classes.
19461  New classes can be generated from other styles like letter or in combination
19462  with other class variations like Article (AMS).
19463  If you have special needs that cannot be covered by one of the existing
19464  classes, let the LyX developers list (lyx-devel@lists.lyx.org) know and we
19465  will arrange to insert a new entry, or teach you how to do it.
19466 \begin_inset Foot
19467 status collapsed
19468
19469 \begin_layout Plain Layout
19470 It is very simple, it involves the creation of a file with four lines, and
19471  re-running of the auto configuration.
19472 \end_layout
19473
19474 \end_inset
19475
19476  Moreover, if you use a literate tool other than Noweb you may need to create
19477  a new set of document classes for it.
19478 \end_layout
19479
19480 \begin_layout Paragraph
19481 Typing code in
19482 \end_layout
19483
19484 \begin_layout Standard
19485 LyX enables you to write code with a layout named 
19486 \noun on
19487 Scrap
19488 \noun default
19489 .
19490 \begin_inset Foot
19491 status collapsed
19492
19493 \begin_layout Plain Layout
19494 The equivalent Noweb term is 
19495 \begin_inset Quotes eld
19496 \end_inset
19497
19498 Chunk
19499 \begin_inset Quotes erd
19500 \end_inset
19501
19502 .
19503  For historical reasons, I got used to the term 
19504 \begin_inset Quotes eld
19505 \end_inset
19506
19507 scrap
19508 \begin_inset Quotes erd
19509 \end_inset
19510
19511  introduced by other literate tool named Nuweb, which I used for many years
19512  before rendering myself to Noweb.
19513 \end_layout
19514
19515 \end_inset
19516
19517  Noweb delimits scraps like this:
19518 \end_layout
19519
19520 \begin_layout LyX-Code
19521 <<My scrap>>=
19522 \end_layout
19523
19524 \begin_layout LyX-Code
19525   code
19526 \end_layout
19527
19528 \begin_layout LyX-Code
19529   more code
19530 \end_layout
19531
19532 \begin_layout LyX-Code
19533   even more code
19534 \end_layout
19535
19536 \begin_layout LyX-Code
19537   @
19538 \end_layout
19539
19540 \begin_layout Standard
19541 The problem is that whatever is written in between the << and the 
19542 \family typewriter
19543 @
19544 \family default
19545  must be taken literally, i.
19546 \begin_inset space \thinspace{}
19547 \end_inset
19548
19549 g.
19550 \begin_inset space \space{}
19551 \end_inset
19552
19553 LyX should be prevented from making any special interpretation of what has
19554  been written.
19555  This is handled by a special layout named Scrap, that works like a normal
19556  paragraph but has a free spacing capability.
19557 \end_layout
19558
19559 \begin_layout Standard
19560 The down side of the Scrap paragraph layout is that consecutive paragraphs
19561  of code will be spaced with one empty line in the source code and also
19562  in the printed documentation.
19563  The work around is to enter each line of code within a single Scrap, with
19564  a newline (ctrl-return).
19565  The example above will look like this:
19566 \begin_inset Foot
19567 status collapsed
19568
19569 \begin_layout Plain Layout
19570 If you have a printed version of this document you will not see any difference
19571  between the previous example and this one.
19572 \end_layout
19573
19574 \end_inset
19575
19576
19577 \end_layout
19578
19579 \begin_layout LyX-Code
19580 <<My scrap>>=
19581 \begin_inset Newline newline
19582 \end_inset
19583
19584   code
19585 \begin_inset Newline newline
19586 \end_inset
19587
19588   more code
19589 \begin_inset Newline newline
19590 \end_inset
19591
19592   even more code
19593 \begin_inset Newline newline
19594 \end_inset
19595
19596   @
19597 \end_layout
19598
19599 \begin_layout Standard
19600 This layout works fine.
19601  The only real inconvenience is that you have to type ctrl-return instead
19602  of a plain return.
19603 \begin_inset Foot
19604 status collapsed
19605
19606 \begin_layout Plain Layout
19607 It is in my list of 
19608 \begin_inset Quotes eld
19609 \end_inset
19610
19611 improvements
19612 \begin_inset Quotes erd
19613 \end_inset
19614
19615  to fix that.
19616 \end_layout
19617
19618 \end_inset
19619
19620
19621 \end_layout
19622
19623 \begin_layout Standard
19624 As a special note, you can also use the 
19625 \begin_inset Quotes eld
19626 \end_inset
19627
19628 %def
19629 \begin_inset Quotes erd
19630 \end_inset
19631
19632  construct of Noweb in your scraps to add items to Noweb's identifier cross-refe
19633 rence:
19634 \end_layout
19635
19636 \begin_layout LyX-Code
19637 <<My scrap>>=
19638 \begin_inset Newline newline
19639 \end_inset
19640
19641   def some_function(args):
19642 \begin_inset Newline newline
19643 \end_inset
19644
19645     "This is the doc string for this function."
19646 \begin_inset Newline newline
19647 \end_inset
19648
19649     print "My args: ", args
19650 \end_layout
19651
19652 \begin_layout LyX-Code
19653 @ %def some_function
19654 \end_layout
19655
19656 \begin_layout Standard
19657 For an example of this usage and the resulting cross-reference output, look
19658  at the Literate python program in 
19659 \emph on
19660 LIBDIR/examples/listerrors.lyx
19661 \emph default
19662  which should make this all clear.
19663 \end_layout
19664
19665 \begin_layout Paragraph
19666 Generating the documentation
19667 \end_layout
19668
19669 \begin_layout Standard
19670 At this point you already have a new document file with a proper document
19671  class, and with some code and text on it.
19672  How do I print it? The answer is simple, you select 
19673 \family sans
19674 View\SpecialChar \menuseparator
19675 DVI,
19676 \family default
19677  etc.
19678  Just like you would do for a plain document.
19679  No special procedure is required.
19680 \end_layout
19681
19682 \begin_layout Standard
19683 To help orientate you, I will now explain what happens inside LyX:
19684 \end_layout
19685
19686 \begin_layout Enumerate
19687 When the 
19688 \family sans
19689 Update\SpecialChar \menuseparator
19690 DVI
19691 \family default
19692  menu option is chosen, a LaTeX file is generated.
19693  
19694 \end_layout
19695
19696 \begin_deeper
19697 \begin_layout Standard
19698 If the document is of any literate class the generated file will be named
19699  with an extension name defined by the 
19700 \begin_inset Quotes eld
19701 \end_inset
19702
19703 literate
19704 \begin_inset Quotes erd
19705 \end_inset
19706
19707  format (defined in the Preferences panel), otherwise the file will have
19708  the usual 
19709 \family typewriter
19710 .tex
19711 \family default
19712  extension.
19713 \end_layout
19714
19715 \end_deeper
19716 \begin_layout Enumerate
19717 Note that the only difference so far is in the name of the file, no special
19718  processing is required by LyX.
19719  Given that you formatted the code using the Scrap layout that, by itself,
19720  takes care of the business.
19721 \end_layout
19722
19723 \begin_layout Enumerate
19724 If the document is of any literate class LyX will then use the internal
19725  LyX to Noweb converter, followed by the Noweb to LaTeX converter
19726 \begin_inset Foot
19727 status collapsed
19728
19729 \begin_layout Plain Layout
19730 The converters are defined in the 
19731 \family sans
19732 Tools\SpecialChar \menuseparator
19733 Preferences
19734 \family default
19735  panel, under the 
19736 \begin_inset Quotes eld
19737 \end_inset
19738
19739 Conversion
19740 \begin_inset Quotes erd
19741 \end_inset
19742
19743  tab.
19744  See section 
19745 \emph on
19746 Converters
19747 \emph default
19748  of the 
19749 \emph on
19750 Customization
19751 \emph default
19752  manual for general information about converters.
19753 \end_layout
19754
19755 \end_inset
19756
19757  to generate the LaTeX file.
19758 \end_layout
19759
19760 \begin_deeper
19761 \begin_layout Standard
19762 Otherwise it will just skip this step.
19763 \end_layout
19764
19765 \end_deeper
19766 \begin_layout Enumerate
19767 Finally, LaTeX is invoked and the regular post processing continues as in
19768  a plain document.
19769 \end_layout
19770
19771 \begin_layout Standard
19772 Independence from a particular 
19773 \begin_inset Quotes eld
19774 \end_inset
19775
19776 literate tool
19777 \begin_inset Quotes erd
19778 \end_inset
19779
19780  is easily achieved by changing the commands that are run by the various
19781  converters.
19782 \end_layout
19783
19784 \begin_layout Paragraph
19785 Generating the code
19786 \end_layout
19787
19788 \begin_layout Standard
19789 When the build menu option is chosen or the corresponding button in the
19790  toolbar is pressed, a LaTeX file is generated just like step 1 above.
19791  Next, LyX invokes the 
19792 \family typewriter
19793 Noweb->Program
19794 \family default
19795  converter.
19796  This converter needs to be defined by the user and is not installed by
19797  default, though the Program format is.
19798  This converter (like any other converter) will have two parts:
19799 \end_layout
19800
19801 \begin_layout Enumerate
19802 The converter program itself.
19803  This program performs the conversion from the one format to the other (in
19804  this case, from the Noweb format to the Program pseudo-format).
19805 \end_layout
19806
19807 \begin_layout Enumerate
19808 The error log parser.
19809  This is a program whose sole purpose is to rewrite error messages in a
19810  format that LyX understands.
19811  This makes it possible for LyX to place error boxes in the right places
19812  in the file buffer.
19813 \end_layout
19814
19815 \begin_layout Standard
19816 The first part, the 
19817 \begin_inset Quotes eld
19818 \end_inset
19819
19820 Converter
19821 \begin_inset Quotes erd
19822 \end_inset
19823
19824  setting, should be set to 
19825 \begin_inset Quotes eld
19826 \end_inset
19827
19828
19829 \family typewriter
19830 build-script $$i
19831 \family default
19832
19833 \begin_inset Quotes erd
19834 \end_inset
19835
19836 .
19837  This basically means that LyX will call 
19838 \begin_inset Quotes eld
19839 \end_inset
19840
19841 build-script
19842 \begin_inset Quotes erd
19843 \end_inset
19844
19845  (a program or script) with the name of the Noweb file (normally a file
19846  in the LyX temp directory).
19847  
19848 \end_layout
19849
19850 \begin_layout Standard
19851 This is an implementation of 
19852 \begin_inset Quotes eld
19853 \end_inset
19854
19855 build-script
19856 \begin_inset Quotes erd
19857 \end_inset
19858
19859  that you can place in a directory on your path:
19860 \end_layout
19861
19862 \begin_layout LyX-Code
19863 #!/bin/sh
19864 \end_layout
19865
19866 \begin_layout LyX-Code
19867 #
19868 \end_layout
19869
19870 \begin_layout LyX-Code
19871 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 sh
19872 \end_layout
19873
19874 \begin_layout Standard
19875 The next part of the converter setting is the 
19876 \begin_inset Quotes eld
19877 \end_inset
19878
19879 Flags
19880 \begin_inset Quotes erd
19881 \end_inset
19882
19883  which is to be set to 
19884 \begin_inset Quotes eld
19885 \end_inset
19886
19887
19888 \family typewriter
19889 parselog=listerrors
19890 \family default
19891
19892 \begin_inset Quotes erd
19893 \end_inset
19894
19895 .
19896  This will run any errors that are generated by the 
19897 \begin_inset Quotes eld
19898 \end_inset
19899
19900 build-script
19901 \begin_inset Quotes erd
19902 \end_inset
19903
19904  process through the 
19905 \begin_inset Quotes eld
19906 \end_inset
19907
19908 listerrors
19909 \begin_inset Quotes erd
19910 \end_inset
19911
19912  program.
19913 \end_layout
19914
19915 \begin_layout Standard
19916 The converter code looks in 
19917 \emph on
19918 MYLYXDIR/scripts
19919 \emph default
19920  first, then in 
19921 \emph on
19922 LIBDIR/scripts
19923 \emph default
19924  then on the path for the 
19925 \begin_inset Quotes eld
19926 \end_inset
19927
19928 listerrors
19929 \begin_inset Quotes erd
19930 \end_inset
19931
19932  program.
19933 \end_layout
19934
19935 \begin_layout Standard
19936 The build will normally take place in LyX's temporary directory, so the
19937  files produced by the conversion will be in that directory.
19938  LyX will copy out what it regards as the `main' file, but the 
19939 \family typewriter
19940 Noweb->Program
19941 \family default
19942  conversion may produce several files, and so most of these would then be
19943  deleted when LyX was closed.
19944  The present solution is to use a `copier',
19945 \begin_inset Foot
19946 status collapsed
19947
19948 \begin_layout Plain Layout
19949 See section 
19950 \emph on
19951 Copiers
19952 \emph default
19953  of the 
19954 \emph on
19955 Customization
19956 \emph default
19957  manual for information on these.
19958 \end_layout
19959
19960 \end_inset
19961
19962  in this case, the 
19963 \family typewriter
19964 ext_copy.py
19965 \family default
19966  script in its default mode, so that the entire contents of the temporary
19967  directory is copied.
19968  More will get copied than is needed, to be sure, but nothing will be lost.
19969  If, however, you know what extensions the generated files will have, this
19970  can be improved by using the 
19971 \family typewriter
19972 -e
19973 \family default
19974  option to 
19975 \family typewriter
19976 ext_copy
19977 \family default
19978 .
19979  This option takes a comma-separated list of extensions to copy.
19980  So, for example, if the conversion will generate only files with the extensions
19981  
19982 \family typewriter
19983 .c
19984 \family default
19985  and 
19986 \family typewriter
19987 .h
19988 \family default
19989 , then the correct definition would be:
19990 \end_layout
19991
19992 \begin_layout LyX-Code
19993 python -tt $$s/scripts/ext_copy.py -e c,h $$i $$o
19994 \end_layout
19995
19996 \begin_layout Standard
19997 The result will be that only files with these two extensions will be copied
19998  out.
19999 \end_layout
20000
20001 \begin_layout Paragraph
20002 Build instructions in the document
20003 \end_layout
20004
20005 \begin_layout Standard
20006 The last piece of the integration between LyX and noweb is the 
20007 \begin_inset Quotes eld
20008 \end_inset
20009
20010 build-script
20011 \begin_inset Quotes erd
20012 \end_inset
20013
20014  scrap.
20015  Generally, the instructions for building your program should be embedded
20016  in a scrap of its own.
20017  The noweb-specific 
20018 \begin_inset Quotes eld
20019 \end_inset
20020
20021 build-script
20022 \begin_inset Quotes erd
20023 \end_inset
20024
20025  above uses the notangle command to look for this scrap (called 
20026 \begin_inset Quotes eld
20027 \end_inset
20028
20029 build-script
20030 \begin_inset Quotes erd
20031 \end_inset
20032
20033 ) and runs its contents through 
20034 \begin_inset Quotes eld
20035 \end_inset
20036
20037 sh
20038 \begin_inset Quotes erd
20039 \end_inset
20040
20041 .
20042 \end_layout
20043
20044 \begin_layout Standard
20045 Typically, such a scrap would look something like this:
20046 \end_layout
20047
20048 \begin_layout LyX-Code
20049 <<build-script>>=
20050 \begin_inset Newline newline
20051 \end_inset
20052
20053 #!/bin/sh
20054 \begin_inset Newline newline
20055 \end_inset
20056
20057
20058 \begin_inset Newline newline
20059 \end_inset
20060
20061 if [ -z "${NOWEB_SOURCE}" ]
20062 \begin_inset Newline newline
20063 \end_inset
20064
20065 then
20066 \begin_inset Newline newline
20067 \end_inset
20068
20069   NOWEB_SOURCE=myfile.nw
20070 \begin_inset Newline newline
20071 \end_inset
20072
20073 fi
20074 \begin_inset Newline newline
20075 \end_inset
20076
20077 [...
20078  code to extract files ...]
20079 \begin_inset Newline newline
20080 \end_inset
20081
20082 [...
20083  code to compile files ...]
20084 \begin_inset Newline newline
20085 \end_inset
20086
20087 @
20088 \end_layout
20089
20090 \begin_layout Standard
20091 Look in 
20092 \emph on
20093 LIBDIR/examples/listerrors.lyx
20094 \emph default
20095  or in 
20096 \emph on
20097 LIBDIR/examples/Literate.lyx
20098 \emph default
20099  which implement two versions of the 
20100 \begin_inset Quotes eld
20101 \end_inset
20102
20103 listerrors
20104 \begin_inset Quotes erd
20105 \end_inset
20106
20107  program for some illustrations of how all of these pieces go together or
20108  in 
20109 \emph on
20110 LIBDIR/examples/noweb2lyx.lyx.
20111
20112 \emph default
20113  Interestingly, these three files show off the language-indepence of the
20114  LyX literate programming support since they are written in Python, C and
20115  Perl respectively.
20116 \end_layout
20117
20118 \begin_layout Subsubsection
20119 Configuring LyX
20120 \end_layout
20121
20122 \begin_layout Standard
20123 All the Literate Programming support is configured by the 
20124 \family sans
20125 Tools\SpecialChar \menuseparator
20126 Preferences
20127 \family default
20128  panel in the 
20129 \begin_inset Quotes eld
20130 \end_inset
20131
20132 Conversion
20133 \begin_inset Quotes erd
20134 \end_inset
20135
20136  tab.
20137  The important parts are:
20138 \end_layout
20139
20140 \begin_layout Description
20141 the
20142 \begin_inset space ~
20143 \end_inset
20144
20145
20146 \begin_inset Quotes eld
20147 \end_inset
20148
20149 literate
20150 \begin_inset Quotes erd
20151 \end_inset
20152
20153
20154 \begin_inset space ~
20155 \end_inset
20156
20157 format Set up via the Formats tab, this is where the Noweb-specific pieces
20158  are set up.
20159  The 
20160 \family sans
20161 GUI Name
20162 \family default
20163  is set to 
20164 \family typewriter
20165 NoWeb
20166 \family default
20167 , the file extension is set to 
20168 \family typewriter
20169 .nw
20170 \family default
20171 .
20172  This tells LyX to create a file with a 
20173 \family typewriter
20174 .nw
20175 \family default
20176  extension in the first step of the conversion process.
20177 \end_layout
20178
20179 \begin_layout Description
20180 the
20181 \begin_inset space ~
20182 \end_inset
20183
20184
20185 \family sans
20186 Program
20187 \family default
20188
20189 \begin_inset space ~
20190 \end_inset
20191
20192 format This is an empty format whose sole purpose is to be the endpoint
20193  of a conversion (which then allows us to set up a converter for it).
20194 \end_layout
20195
20196 \begin_layout Description
20197
20198 \family sans
20199 NoWeb
20200 \family default
20201 ->
20202 \family sans
20203 LaTeX
20204 \family default
20205  This converter performs the 
20206 \begin_inset Quotes eld
20207 \end_inset
20208
20209 weaving
20210 \begin_inset Quotes erd
20211 \end_inset
20212
20213  of the literate document.
20214  For Noweb, it is set to 
20215 \begin_inset Quotes eld
20216 \end_inset
20217
20218
20219 \family typewriter
20220 noweave -delay -index $$i > $$o
20221 \family default
20222
20223 \begin_inset Quotes erd
20224 \end_inset
20225
20226
20227 \end_layout
20228
20229 \begin_layout Description
20230
20231 \family sans
20232 NoWeb
20233 \family default
20234 ->
20235 \family sans
20236 Program
20237 \family default
20238  This performs the 
20239 \begin_inset Quotes eld
20240 \end_inset
20241
20242 tangling step
20243 \begin_inset Quotes erd
20244 \end_inset
20245
20246 .
20247  As stated above, the Converter is set to 
20248 \begin_inset Quotes eld
20249 \end_inset
20250
20251
20252 \family typewriter
20253 build-script $$i
20254 \family default
20255
20256 \begin_inset Quotes erd
20257 \end_inset
20258
20259 , with Flags set to 
20260 \begin_inset Quotes eld
20261 \end_inset
20262
20263
20264 \family typewriter
20265 originaldir,parselog=listerrors
20266 \family default
20267
20268 \begin_inset Quotes erd
20269 \end_inset
20270
20271 .
20272 \end_layout
20273
20274 \begin_layout Subsubsection
20275 Debug extensions
20276 \end_layout
20277
20278 \begin_layout Standard
20279 There is also a new function implemented in the LyX server, the 
20280 \begin_inset Quotes eld
20281 \end_inset
20282
20283 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
20284  
20285 \end_layout
20286
20287 \begin_layout Standard
20288 When debugging code with ddd/gdb, it is possible to invoke a text editor
20289  at the current execution position with a single key stroke.
20290  The default ddd configuration for that is shift-ctrl-V.
20291  It happens that you can define the editor command line invocation in ddd
20292  by accessing the 
20293 \family sans
20294 Edit\SpecialChar \menuseparator
20295 Preferences\SpecialChar \menuseparator
20296 Helpers
20297 \family default
20298  dialog and changing the "Edit Sources" entry.
20299 \end_layout
20300
20301 \begin_layout Standard
20302 I take advantage of the new created LyX server function and this ddd feature,
20303  and set 
20304 \begin_inset Quotes eld
20305 \end_inset
20306
20307 Edit Sources
20308 \begin_inset Quotes erd
20309 \end_inset
20310
20311  to:
20312 \end_layout
20313
20314 \begin_layout LyX-Code
20315 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
20316 \end_layout
20317
20318 \begin_layout Standard
20319 With this, whenever you are using ddd and find a point in the program that
20320  you want to edit, you just press shift-ctrl-V (in the ddd window), and
20321  ddd you forward this information to LyX through the LyX server and then
20322  the LyX window will show the same file with the cursor at the same position
20323  ddd was pointing to.
20324  No more guessing or long scrolling to locate a point in the program back
20325  from debugging !
20326 \end_layout
20327
20328 \begin_layout Standard
20329 Note however that you must enable the LyX server to get this feature working
20330  (it is disabled by default).
20331  You can enable it in 
20332 \family sans
20333 Preferences
20334 \family default
20335  (tabs 
20336 \family sans
20337 Inputs
20338 \family default
20339
20340 \family sans
20341 Paths
20342 \family default
20343 ) by entering in the 
20344 \family sans
20345 LyXserver pipe
20346 \family default
20347  a path like 
20348 \begin_inset Quotes eld
20349 \end_inset
20350
20351
20352 \family typewriter
20353 /home/<your-home-directory>/.lyx/lyxpipe
20354 \family default
20355
20356 \begin_inset Quotes erd
20357 \end_inset
20358
20359
20360 \end_layout
20361
20362 \begin_layout Standard
20363 Read the LyX server documentation in the 
20364 \emph on
20365 Customization Manual
20366 \emph default
20367  for further information.
20368 \end_layout
20369
20370 \begin_layout Subsubsection
20371 Toolbar extensions
20372 \end_layout
20373
20374 \begin_layout Standard
20375 There are six new buttons that can be added to your LyX toolbar.
20376  Five of these buttons are short cuts to layout styles: 
20377 \family sans
20378 Standard
20379 \family default
20380
20381 \family sans
20382 Section
20383 \family default
20384
20385 \family sans
20386 LaTeX
20387 \family default
20388
20389 \family sans
20390 LyX-Code
20391 \family default
20392 , and 
20393 \family sans
20394 Scrap
20395 \family default
20396 .
20397  The last one is a short cut to the 
20398 \begin_inset Quotes eld
20399 \end_inset
20400
20401 Build Program
20402 \begin_inset Quotes erd
20403 \end_inset
20404
20405  File menu entry.
20406  
20407 \end_layout
20408
20409 \begin_layout Standard
20410 LyX has a range of buttons that are available for tool bar customization.
20411  In my toolbar I like to combine the six short cuts above with two more:
20412  One for 
20413 \family sans
20414 View
20415 \family default
20416 \SpecialChar \menuseparator
20417
20418 \family sans
20419 Update
20420 \family default
20421 \SpecialChar \menuseparator
20422
20423 \family sans
20424 DVI
20425 \family default
20426  and the other for 
20427 \family sans
20428 View\SpecialChar \menuseparator
20429 DVI
20430 \family default
20431  File menu entries.
20432  Here is how it looks like:
20433 \end_layout
20434
20435 \begin_layout LyX-Code
20436 Toolbar
20437 \end_layout
20438
20439 \begin_layout LyX-Code
20440   Layouts
20441 \end_layout
20442
20443 \begin_layout LyX-Code
20444   Icon "layout Standard"
20445 \end_layout
20446
20447 \begin_layout LyX-Code
20448   Icon "layout Section"
20449 \end_layout
20450
20451 \begin_layout LyX-Code
20452   Icon "layout LaTeX"
20453 \end_layout
20454
20455 \begin_layout LyX-Code
20456   Icon "layout LyX-Code"
20457 \end_layout
20458
20459 \begin_layout LyX-Code
20460   Icon "layout Scrap"
20461 \end_layout
20462
20463 \begin_layout LyX-Code
20464   Separator
20465 \end_layout
20466
20467 \begin_layout LyX-Code
20468   Icon "buffer-view"
20469 \end_layout
20470
20471 \begin_layout LyX-Code
20472   Icon "buffer-typeset"
20473 \end_layout
20474
20475 \begin_layout LyX-Code
20476   Icon "build-program"
20477 \end_layout
20478
20479 \begin_layout LyX-Code
20480   Separator
20481 \end_layout
20482
20483 \begin_layout LyX-Code
20484 .
20485 \end_layout
20486
20487 \begin_layout LyX-Code
20488 .
20489 \end_layout
20490
20491 \begin_layout LyX-Code
20492 .
20493 \end_layout
20494
20495 \begin_layout LyX-Code
20496 End
20497 \end_layout
20498
20499 \begin_layout Subsubsection
20500 Colors customization
20501 \end_layout
20502
20503 \begin_layout Standard
20504 There are a number of colors in LyX that can be customized in 
20505 \family sans
20506 Preferences
20507 \family default
20508 .
20509  One of the things that bothers people is the LaTeX font color.
20510  The default color is red, since the scraps uses LaTeX font, and there is
20511  a lot of scraps in literate documents, you may get tired of seeing everything
20512  in red.
20513  You can change it by going to the tabs 
20514 \family sans
20515 Look&Feel
20516 \family default
20517
20518 \family sans
20519 Colors.
20520 \end_layout
20521
20522 \begin_layout Standard
20523 The next thing is the visible presence of the newline character in the screen.
20524  You can choose the color of this particular character and make it blend
20525  in the background.
20526  I recommend you choosing a color that is close to the background but not
20527  equal, that way you still can see it is there, but it is not bothering
20528  you anymore.
20529  
20530 \end_layout
20531
20532 \begin_layout Chapter
20533 Secrets of the LaTeX Masters
20534 \begin_inset CommandInset label
20535 LatexCommand label
20536 name "cha:secrets"
20537
20538 \end_inset
20539
20540
20541 \end_layout
20542
20543 \begin_layout Standard
20544 Though LyX is a powerful tool, it cannot hope to support everything that
20545  can be done with pure TeX/LaTeX.
20546  However, many familiar dirty TeX and LaTeX tricks can be done within LyX,
20547  as long as you are not afraid to use that 
20548 \begin_inset Quotes eld
20549 \end_inset
20550
20551 TeX
20552 \begin_inset Quotes erd
20553 \end_inset
20554
20555  button on the toolbar or add things to the LaTeX preamble.
20556  This section lists some tips, tricks, and otherwise cool ideas to give
20557  your document that extra little flair.
20558  
20559 \emph on
20560 Do try this at home
20561 \emph default
20562 , just start with something a little smaller and less important than your
20563  dissertation!
20564 \end_layout
20565
20566 \begin_layout Standard
20567 Most ideas in this section require less common files in your LaTeX installation.
20568  If you have a system like teTeX, most will already be available.
20569  A few, however, will need to be downloaded from one of the CTAN archives.
20570  Often, there are several ways to do something, or several LaTeX style files
20571  which do the same thing.
20572  We do not endorse one choice over another, we simply claim that we have
20573  done a particular task with a particular file.
20574  Put on your wizard hat, keep an eye out for dragons, and let us begin.
20575 \end_layout
20576
20577 \begin_layout Section
20578 Multiple Columns
20579 \end_layout
20580
20581 \begin_layout Standard
20582 by 
20583 \noun on
20584 Lars Gullik Bjønnes
20585 \end_layout
20586
20587 \begin_layout Subsection
20588 Purpose
20589 \end_layout
20590
20591 \begin_layout Standard
20592 The aim for this chapter
20593 \begin_inset Foot
20594 status collapsed
20595
20596 \begin_layout Plain Layout
20597 Editor's note: Lars' original chapter was a masterful description of how
20598  to use the 
20599 \family typewriter
20600 multicol
20601 \family default
20602  package.
20603  However, it was too long to flow smoothly in this document.
20604  I have therefore chosen to excerpt the most important sections here (sorry,
20605  Lars); you can read the original chapter (and more of the story!) in the
20606  example file 
20607 \family typewriter
20608 examples/multicol.lyx
20609 \family default
20610 .
20611  â€” mer
20612 \end_layout
20613
20614 \end_inset
20615
20616  is to show how the LaTeX package 
20617 \family typewriter
20618 multicol
20619 \family default
20620  can be used in a LyX document.
20621  As LyX doesn't support the 
20622 \family typewriter
20623 multicol
20624 \family default
20625  package natively yet, we have to use some small hacks.
20626  By reading this section it should be obvious how to do this.
20627 \end_layout
20628
20629 \begin_layout Subsection
20630 Limitations 
20631 \end_layout
20632
20633 \begin_layout Standard
20634 The 
20635 \family typewriter
20636 multicol
20637 \family default
20638  package allows switching between one and multicolumn format on the same
20639  page.
20640  Footnotes are handled correctly (for the most part), but will be placed
20641  at the bottom of the page and not under each column.
20642  LaTeX's float mechanism, however, is partly disabled in the current implementat
20643 ion.
20644  At the moment only page-wide floats can be used within the scope of the
20645  environment.
20646 \end_layout
20647
20648 \begin_layout Subsection
20649 Examples
20650 \end_layout
20651
20652 \begin_layout Subsubsection
20653 Two columns
20654 \end_layout
20655
20656 \begin_layout Standard
20657 If you want to have two columns in your text, you have use LaTeX mode to
20658  insert 
20659 \family typewriter
20660
20661 \backslash
20662 begin{multicols}{2}
20663 \family default
20664  at the point where you want the two column layout to start, and then 
20665 \family typewriter
20666
20667 \backslash
20668 end{multicols}
20669 \family default
20670  where you want it to end.
20671  Like this:
20672 \end_layout
20673
20674 \begin_layout Standard
20675 \begin_inset ERT
20676 status open
20677
20678 \begin_layout Plain Layout
20679
20680
20681 \backslash
20682 begin{multicols}{2}
20683 \end_layout
20684
20685 \end_inset
20686
20687
20688 \end_layout
20689
20690 \begin_layout Standard
20691 \noindent
20692
20693 \series bold
20694 \size small
20695 The Adventure of the Empty House
20696 \series default
20697
20698 \begin_inset Newline newline
20699 \end_inset
20700
20701 by 
20702 \noun on
20703 Sir Arthur Conan Doyle
20704 \end_layout
20705
20706 \begin_layout Standard
20707
20708 \size small
20709 It was in the spring of the year 1894 that all London was interested, and
20710  the fashionable world dismayed, by the murder of the Honourable Ronald
20711  Adair under most unusual and inexplicable circumstances.
20712  The public has already learned those particulars of the crime which came
20713  out in the police investigation, but a good deal was suppressed upon that
20714  occasion, since the case for the prosecution was so overwhelmingly strong
20715  that it was not necessary to bring forward all the facts.
20716  Only now, at the end of nearly ten years, am I allowed to supply those
20717  missing links which make up the whole of that remarkable chain.
20718  The crime was of interest in itself, but that interest was as nothing to
20719  me compared to the inconceivable sequel, which afforded me the greatest
20720  shock and surprise of any event in my adventurous life.
20721  Even now, after this long interval, I find myself thrilling as I think
20722  of it, and feeling once more that sudden flood of joy, amazement, and increduli
20723 ty which utterly submerged my mind.
20724  Let me say to that public, which has shown some interest in those glimpses
20725  which I have occasionally given them of the thoughts and actions of a very
20726  remarkable man, that they are not to blame me if I have not shared my knowledge
20727  with them, for I should have considered it my first duty to do so, had
20728  I not been barred by a positive prohibition from his own lips, which was
20729  only withdrawn upon the third of last month.
20730 \end_layout
20731
20732 \begin_layout Standard
20733 \begin_inset ERT
20734 status open
20735
20736 \begin_layout Plain Layout
20737
20738
20739 \backslash
20740 end{multicols}
20741 \end_layout
20742
20743 \end_inset
20744
20745
20746 \end_layout
20747
20748 \begin_layout Subsubsection
20749 Multiple columns
20750 \end_layout
20751
20752 \begin_layout Standard
20753 The same pattern is used when you want more than two columns:
20754 \end_layout
20755
20756 \begin_layout Standard
20757 \begin_inset ERT
20758 status open
20759
20760 \begin_layout Plain Layout
20761
20762
20763 \backslash
20764 begin{multicols}{3}
20765 \end_layout
20766
20767 \end_inset
20768
20769
20770 \end_layout
20771
20772 \begin_layout Standard
20773
20774 \size footnotesize
20775 It can be imagined that my close intimacy with Sherlock Holmes had interested
20776  me deeply in crime, and that after his disappearance I never failed to
20777  read with care the various problems which came before the public.
20778  And I even attempted, more than once, for my own private satisfaction,
20779  to employ his methods in their solution, though with indifferent success.
20780  There was none, however, which appealed to me like this tragedy of Ronald
20781  Adair.
20782  As I read the evidence at the inquest, which led up to a verdict of willful
20783  murder against some person or persons unknown, I realized more clearly
20784  than I had ever done the loss which the community had sustained by the
20785  death of Sherlock Holmes.
20786  There were points about this strange business which would, I was sure,
20787  have specially appealed to him, and the efforts of the police would have
20788  been supplemented, or more probably anticipated, by the trained observation
20789  and the alert mind of the first criminal agent in Europe.
20790  All day, as I drove upon my round, I turned over the case in my mind and
20791  found no explanation which appeared to me to be adequate.
20792  At the risk of telling a twice-told tale, I will recapitulate the facts
20793  as they were known to the public at the conclusion of the inquest.
20794 \end_layout
20795
20796 \begin_layout Standard
20797 \begin_inset ERT
20798 status open
20799
20800 \begin_layout Plain Layout
20801
20802
20803 \backslash
20804 end{multicols}
20805 \end_layout
20806
20807 \end_inset
20808
20809
20810 \end_layout
20811
20812 \begin_layout Standard
20813 You can have more than 3 columns if you want to, but that might not be very
20814  pleasant for the eye.
20815 \end_layout
20816
20817 \begin_layout Subsubsection
20818 Columns inside columns
20819 \end_layout
20820
20821 \begin_layout Standard
20822 You can even have columns inside columns:
20823 \end_layout
20824
20825 \begin_layout Standard
20826 \begin_inset ERT
20827 status open
20828
20829 \begin_layout Plain Layout
20830
20831
20832 \backslash
20833 begin{multicols}{2}
20834 \end_layout
20835
20836 \end_inset
20837
20838
20839 \end_layout
20840
20841 \begin_layout Standard
20842
20843 \size footnotesize
20844 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
20845  at that time governor of one of the Australian colonies.
20846  Adair's mother had returned from Australia to undergo the operation for
20847  cataract, and she, her son Ronald, and her daughter Hilda were living together
20848  at 427 Park Lane.
20849 \end_layout
20850
20851 \begin_layout Standard
20852 \begin_inset ERT
20853 status open
20854
20855 \begin_layout Plain Layout
20856
20857
20858 \backslash
20859 begin{multicols}{2}
20860 \end_layout
20861
20862 \end_inset
20863
20864
20865 \end_layout
20866
20867 \begin_layout Standard
20868
20869 \size footnotesize
20870 The youth moved in the best society–had, so far as was known, no enemies
20871  and no particular vices.
20872  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
20873  had been broken off by mutual consent some months before, and there was
20874  no sign that it had left any very profound feeling behind it.
20875  For the rest {sic} the man's life moved in a narrow and conventional circle,
20876  for his habits were quiet and his nature unemotional.
20877  Yet it was upon this easy-going young aristocrat that death came, in most
20878  strange and unexpected form, between the hours of ten and eleven-twenty
20879  on the night of March 30, 1894.
20880 \end_layout
20881
20882 \begin_layout Standard
20883 \begin_inset ERT
20884 status open
20885
20886 \begin_layout Plain Layout
20887
20888
20889 \backslash
20890 end{multicols}
20891 \end_layout
20892
20893 \end_inset
20894
20895
20896 \end_layout
20897
20898 \begin_layout Standard
20899
20900 \size footnotesize
20901 Ronald Adair was fond of cards–playing continually, but never for such stakes
20902  as would hurt him.
20903  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
20904  It was shown that, after dinner on the day of his death, he had played
20905  a rubber of whist at the latter club.
20906  He had also played there in the afternoon.
20907
20908 \size default
20909  
20910 \size footnotesize
20911 The evidence of those who had played with him– Mr.
20912  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
20913  and that there was a fairly equal fall of the cards.
20914  Adair might have lost five pounds, but not more.
20915  His fortune was a considerable one, and such a loss could not in any way
20916  affect him.
20917  He had played nearly every day at one club or other, but he was a cautious
20918  player, and usually rose a winner.
20919  It came out in evidence that, in partnership with Colonel Moran, he had
20920  actually won as much as four hundred and twenty pounds in a sitting, some
20921  weeks before, from Godfrey Milner and Lord Balmoral.
20922  So much for his recent history as it came out at the inquest.
20923 \end_layout
20924
20925 \begin_layout Standard
20926 \begin_inset ERT
20927 status open
20928
20929 \begin_layout Plain Layout
20930
20931
20932 \backslash
20933 end{multicols}
20934 \end_layout
20935
20936 \end_inset
20937
20938
20939 \end_layout
20940
20941 \begin_layout Standard
20942 Please do read the file 
20943 \family typewriter
20944 examples/multicol.lyx
20945 \family default
20946  for more advanced examples including column and header spacing, vertical
20947  separator lines, and more.
20948 \end_layout
20949
20950 \begin_layout Section
20951 Numbering in the 
20952 \family sans
20953 Enumerate
20954 \family default
20955  Paragraph Environment
20956 \begin_inset OptArg
20957 status collapsed
20958
20959 \begin_layout Plain Layout
20960 Numbering in Enumerate
20961 \end_layout
20962
20963 \end_inset
20964
20965
20966 \end_layout
20967
20968 \begin_layout Standard
20969 by 
20970 \noun on
20971 John Weiss
20972 \end_layout
20973
20974 \begin_layout Standard
20975 \begin_inset VSpace bigskip
20976 \end_inset
20977
20978
20979 \end_layout
20980
20981 \begin_layout Standard
20982 \noindent
20983 The default numbering for the 
20984 \family sans
20985 Enumerate
20986 \family default
20987  paragraph environment begins with Arabic numbers and ends with uppercase
20988  letters.
20989  Suppose, however, you wanted a different type of numbering scheme.
20990  Here's a quickie example of how to change the numbering scheme:
20991 \end_layout
20992
20993 \begin_layout LyX-Code
20994
20995 \backslash
20996 renewcommand{
20997 \backslash
20998 labelenumi}{
20999 \backslash
21000 Roman{enumi}.}
21001 \end_layout
21002
21003 \begin_layout LyX-Code
21004
21005 \backslash
21006 renewcommand{
21007 \backslash
21008 labelenumii}{
21009 \backslash
21010 Alph{enumii}.}
21011 \end_layout
21012
21013 \begin_layout LyX-Code
21014
21015 \backslash
21016 renewcommand{
21017 \backslash
21018 labelenumiii}{
21019 \backslash
21020 arabic{enumiii}.}
21021 \end_layout
21022
21023 \begin_layout LyX-Code
21024
21025 \backslash
21026 renewcommand{
21027 \backslash
21028 labelenumiv}{
21029 \backslash
21030 alph{enumiv}.)}
21031 \end_layout
21032
21033 \begin_layout Standard
21034 \SpecialChar \ldots{}
21035  which changes the numbering scheme to uppercase Roman numerals, uppercase
21036  letters, Arabic numbers, and lowercase letter.
21037 \end_layout
21038
21039 \begin_layout Standard
21040 Additionally, the previous example also adds a little bit extra to the numbering
21041  scheme.
21042  For example, the first level label actually looks like: 
21043 \begin_inset Quotes eld
21044 \end_inset
21045
21046 I.
21047 \begin_inset Quotes erd
21048 \end_inset
21049
21050 .
21051  For ease of reading, we'll describe what the numbering schemes look like
21052  using a notation something like this: <
21053 \begin_inset Quotes eld
21054 \end_inset
21055
21056 I.
21057 \begin_inset Quotes erd
21058 \end_inset
21059
21060 ,
21061 \begin_inset space ~
21062 \end_inset
21063
21064
21065 \begin_inset Quotes erd
21066 \end_inset
21067
21068 A.
21069 \begin_inset Quotes erd
21070 \end_inset
21071
21072 ,
21073 \begin_inset space ~
21074 \end_inset
21075
21076
21077 \begin_inset Quotes erd
21078 \end_inset
21079
21080 1.
21081 \begin_inset Quotes erd
21082 \end_inset
21083
21084 ,
21085 \begin_inset space ~
21086 \end_inset
21087
21088
21089 \begin_inset Quotes eld
21090 \end_inset
21091
21092 a.)
21093 \begin_inset Quotes erd
21094 \end_inset
21095
21096 >.
21097  
21098 \end_layout
21099
21100 \begin_layout Standard
21101 As you can see in the example, there is a label command for each nesting
21102  level, 
21103 \family typewriter
21104
21105 \backslash
21106 labelenumi
21107 \family default
21108  \SpecialChar \ldots{}
21109  
21110 \family typewriter
21111
21112 \backslash
21113 labelenumiv
21114 \family default
21115 , as well as a counter, 
21116 \family typewriter
21117 enumi
21118 \family default
21119  \SpecialChar \ldots{}
21120  
21121 \family typewriter
21122 enumiv
21123 \family default
21124 .
21125  There are also five 
21126 \begin_inset Quotes eld
21127 \end_inset
21128
21129 number printing
21130 \begin_inset Quotes erd
21131 \end_inset
21132
21133  commands, 
21134 \family typewriter
21135
21136 \backslash
21137 arabic{}
21138 \family default
21139
21140 \family typewriter
21141
21142 \backslash
21143 roman{}
21144 \family default
21145
21146 \family typewriter
21147
21148 \backslash
21149 Roman{}
21150 \family default
21151
21152 \family typewriter
21153
21154 \backslash
21155 alph{}
21156 \family default
21157 , and 
21158 \family typewriter
21159
21160 \backslash
21161 Alph{}
21162 \family default
21163 , each of which take one counter as an argument.
21164  You can add characters before or after these, but there's no need to add
21165  spaces.
21166 \end_layout
21167
21168 \begin_layout Standard
21169 You can get really fancy with these.
21170  For example:
21171 \end_layout
21172
21173 \begin_layout LyX-Code
21174
21175 \backslash
21176 renewcommand{
21177 \backslash
21178 labelenumi}{
21179 \backslash
21180 #
21181 \backslash
21182 Alph{enumi}
21183 \backslash
21184 #}
21185 \end_layout
21186
21187 \begin_layout LyX-Code
21188
21189 \backslash
21190 renewcommand{
21191 \backslash
21192 labelenumii}{
21193 \backslash
21194 Alph{enumi}.
21195 \backslash
21196 arabic{enumii}}
21197 \end_layout
21198
21199 \begin_layout LyX-Code
21200
21201 \backslash
21202 renewcommand{
21203 \backslash
21204 labelenumiii}{
21205 \backslash
21206 alph{enumiii}+}
21207 \end_layout
21208
21209 \begin_layout LyX-Code
21210
21211 \backslash
21212 renewcommand{
21213 \backslash
21214 labelenumiv}{(
21215 \backslash
21216 roman{enumiv})}
21217 \end_layout
21218
21219 \begin_layout Standard
21220 produces the somewhat out of hand numbering scheme: <
21221 \begin_inset Quotes eld
21222 \end_inset
21223
21224 #A#
21225 \begin_inset Quotes erd
21226 \end_inset
21227
21228 ,
21229 \begin_inset space ~
21230 \end_inset
21231
21232
21233 \begin_inset Quotes erd
21234 \end_inset
21235
21236 A.1
21237 \begin_inset Quotes erd
21238 \end_inset
21239
21240 ,
21241 \begin_inset space ~
21242 \end_inset
21243
21244
21245 \begin_inset Quotes erd
21246 \end_inset
21247
21248 a+
21249 \begin_inset Quotes erd
21250 \end_inset
21251
21252 ,
21253 \begin_inset space ~
21254 \end_inset
21255
21256
21257 \begin_inset Quotes eld
21258 \end_inset
21259
21260 (i)
21261 \begin_inset Quotes erd
21262 \end_inset
21263
21264 >.
21265  
21266 \end_layout
21267
21268 \begin_layout Standard
21269
21270 \end_layout
21271
21272 \begin_layout Section
21273 Dropped Capitals
21274 \end_layout
21275
21276 \begin_layout Standard
21277 by 
21278 \noun on
21279 Mike Ressler
21280 \end_layout
21281
21282 \begin_layout Standard
21283 \begin_inset VSpace bigskip
21284 \end_inset
21285
21286
21287 \end_layout
21288
21289 \begin_layout Standard
21290 \noindent
21291 \begin_inset ERT
21292 status collapsed
21293
21294 \begin_layout Plain Layout
21295
21296
21297 \backslash
21298 newfont{
21299 \backslash
21300 tmpfont}{cmr17 scaled 2500}{
21301 \backslash
21302 tmpfont T}
21303 \backslash
21304 vspace*{-8.4ex}
21305 \end_layout
21306
21307 \end_inset
21308
21309
21310 \end_layout
21311
21312 \begin_layout Standard
21313 \noindent
21314 \begin_inset ERT
21315 status open
21316
21317 \begin_layout Plain Layout
21318
21319
21320 \backslash
21321 hangindent=3.3em 
21322 \backslash
21323 hangafter=-3
21324 \end_layout
21325
21326 \end_inset
21327
21328  hose of you who like the style of old books probably also like 
21329 \begin_inset Quotes eld
21330 \end_inset
21331
21332 dropped capitals
21333 \begin_inset Quotes erd
21334 \end_inset
21335
21336 —those large capital letters which begin each new chapter or section.
21337  Implementing them with plain LyX/LaTeX is straightforward (assuming you
21338  know some plain TeX!) but does require a lot of work and many iterations,
21339  as you can see by all the ugly TeX-mode stuff at the beginning of this
21340  paragraph.
21341 \end_layout
21342
21343 \begin_layout Standard
21344 \begin_inset ERT
21345 status open
21346
21347 \begin_layout Plain Layout
21348
21349
21350 \backslash
21351 verb+
21352 \backslash
21353 bigdrop{-1em}{3}{ptmri}{T}+
21354 \end_layout
21355
21356 \end_inset
21357
21358 here is a much easier way of doing this, of course.
21359  The 
21360 \family typewriter
21361 dropcaps
21362 \family default
21363  (or the newer 
21364 \family typewriter
21365 dropping
21366 \family default
21367 ) package from CTAN allows a simple way to add such letters to your documents.
21368  Since this package is not a standard part of teTeX, I can't demonstrate
21369  it within this document, but if you copy this paragraph to a new document,
21370  delete the 
21371 \begin_inset Quotes eld
21372 \end_inset
21373
21374
21375 \family typewriter
21376
21377 \backslash
21378 verb
21379 \family default
21380
21381 \begin_inset Quotes erd
21382 \end_inset
21383
21384  and the pluses from the TeX code at the beginning of the paragraph, and
21385  add 
21386 \family typewriter
21387
21388 \backslash
21389 usepackage{dropcaps}
21390 \family default
21391  to your LaTeX preamble, you will get a nice Times Roman Italic 
21392 \begin_inset Quotes eld
21393 \end_inset
21394
21395 T
21396 \begin_inset Quotes erd
21397 \end_inset
21398
21399 , whose height is three lines of text and which protrudes 1 em into the
21400  margin.
21401  (Make certain you have copied 
21402 \begin_inset Quotes eld
21403 \end_inset
21404
21405
21406 \family typewriter
21407 dropcaps.sty
21408 \family default
21409
21410 \begin_inset Quotes erd
21411 \end_inset
21412
21413  into a directory where TeX can see it.) The first argument is the amount
21414  of indentation; in this case the negative sign moves it into the margin.
21415  The second argument is the height of the letter in number of lines of text.
21416  The third argument is the font name: virtually anything which has a tfm
21417  file should work (wade through the 
21418 \family typewriter
21419 .../texmf/fonts/tfm
21420 \family default
21421  directory for possibilities).
21422  My personal favorite is 
21423 \begin_inset Quotes eld
21424 \end_inset
21425
21426
21427 \family typewriter
21428 yinit
21429 \family default
21430
21431 \begin_inset Quotes erd
21432 \end_inset
21433
21434 , a fancy German font specifically designed for dropped capitals.
21435  The fourth argument is the letter (or letters) to be dropped.
21436  The 
21437 \family typewriter
21438 dropping
21439 \family default
21440  package also offers the 
21441 \family typewriter
21442
21443 \backslash
21444 bigdrop
21445 \family default
21446  command, as well as a slightly simplified 
21447 \family typewriter
21448
21449 \backslash
21450 dropping
21451 \family default
21452  command.
21453 \end_layout
21454
21455 \begin_layout Section
21456 Non-standard Paragraph Shapes
21457 \end_layout
21458
21459 \begin_layout Standard
21460 by 
21461 \noun on
21462 Mike Ressler
21463 \end_layout
21464
21465 \begin_layout Standard
21466 \begin_inset VSpace bigskip
21467 \end_inset
21468
21469
21470 \end_layout
21471
21472 \begin_layout Standard
21473 \begin_inset ERT
21474 status collapsed
21475
21476 \begin_layout Plain Layout
21477
21478
21479 \backslash
21480 begin{sloppypar}
21481 \end_layout
21482
21483 \end_inset
21484
21485
21486 \end_layout
21487
21488 \begin_layout Standard
21489 \begin_inset ERT
21490 status collapsed
21491
21492 \begin_layout Plain Layout
21493
21494
21495 \backslash
21496 newdimen
21497 \backslash
21498 varunit 
21499 \end_layout
21500
21501 \begin_layout Plain Layout
21502
21503
21504 \backslash
21505 setlength{
21506 \backslash
21507 varunit}{4.5in}
21508 \end_layout
21509
21510 \end_inset
21511
21512
21513 \end_layout
21514
21515 \begin_layout Standard
21516 \noindent
21517 \begin_inset ERT
21518 status collapsed
21519
21520 \begin_layout Plain Layout
21521
21522
21523 \backslash
21524 parshape 19 0.45
21525 \backslash
21526 varunit 0.332
21527 \backslash
21528 varunit
21529 \end_layout
21530
21531 \begin_layout Plain Layout
21532
21533 0.40
21534 \backslash
21535 varunit 0.300
21536 \backslash
21537 varunit
21538 \end_layout
21539
21540 \begin_layout Plain Layout
21541
21542 0.35
21543 \backslash
21544 varunit 0.293
21545 \backslash
21546 varunit
21547 \end_layout
21548
21549 \begin_layout Plain Layout
21550
21551 0.30
21552 \backslash
21553 varunit 0.300
21554 \backslash
21555 varunit
21556 \end_layout
21557
21558 \begin_layout Plain Layout
21559
21560 0.25
21561 \backslash
21562 varunit 0.317
21563 \backslash
21564 varunit
21565 \end_layout
21566
21567 \begin_layout Plain Layout
21568
21569 0.20
21570 \backslash
21571 varunit 0.342
21572 \backslash
21573 varunit
21574 \end_layout
21575
21576 \begin_layout Plain Layout
21577
21578 0.15
21579 \backslash
21580 varunit 0.373
21581 \backslash
21582 varunit
21583 \end_layout
21584
21585 \begin_layout Plain Layout
21586
21587 0.10
21588 \backslash
21589 varunit 0.410
21590 \backslash
21591 varunit
21592 \end_layout
21593
21594 \begin_layout Plain Layout
21595
21596 0.05
21597 \backslash
21598 varunit 0.453
21599 \backslash
21600 varunit
21601 \end_layout
21602
21603 \begin_layout Plain Layout
21604
21605 0.00
21606 \backslash
21607 varunit 0.500
21608 \backslash
21609 varunit
21610 \end_layout
21611
21612 \begin_layout Plain Layout
21613
21614 0.05
21615 \backslash
21616 varunit 0.453
21617 \backslash
21618 varunit
21619 \end_layout
21620
21621 \begin_layout Plain Layout
21622
21623 0.10
21624 \backslash
21625 varunit 0.410
21626 \backslash
21627 varunit
21628 \end_layout
21629
21630 \begin_layout Plain Layout
21631
21632 0.15
21633 \backslash
21634 varunit 0.373
21635 \backslash
21636 varunit
21637 \end_layout
21638
21639 \begin_layout Plain Layout
21640
21641 0.20
21642 \backslash
21643 varunit 0.342
21644 \backslash
21645 varunit
21646 \end_layout
21647
21648 \begin_layout Plain Layout
21649
21650 0.25
21651 \backslash
21652 varunit 0.317
21653 \backslash
21654 varunit
21655 \end_layout
21656
21657 \begin_layout Plain Layout
21658
21659 0.30
21660 \backslash
21661 varunit 0.300
21662 \backslash
21663 varunit
21664 \end_layout
21665
21666 \begin_layout Plain Layout
21667
21668 0.35
21669 \backslash
21670 varunit 0.293
21671 \backslash
21672 varunit
21673 \end_layout
21674
21675 \begin_layout Plain Layout
21676
21677 0.40
21678 \backslash
21679 varunit 0.300
21680 \backslash
21681 varunit
21682 \end_layout
21683
21684 \begin_layout Plain Layout
21685
21686 0.45
21687 \backslash
21688 varunit 0.332
21689 \backslash
21690 varunit
21691 \end_layout
21692
21693 \begin_layout Plain Layout
21694
21695 \end_layout
21696
21697 \end_inset
21698
21699 There are times when the tyranny of rectangular paragraphs must be overthrown.
21700  In such situations, a call to the delightful plain TeX command 
21701 \family typewriter
21702
21703 \backslash
21704 parshape
21705 \family default
21706  is called for.
21707  As you can see, completely arbitrary shapes can be laid out with a suitable
21708  set of linelength definitions.
21709  While this parshape may look a bit silly and useless, one could conceive
21710  of situations such as finely tuned dropped capitals, word wrapping around
21711  non-rectangular graphics, etc.
21712  which will benefit from such handcrafting.
21713 \end_layout
21714
21715 \begin_layout Standard
21716 \begin_inset VSpace bigskip
21717 \end_inset
21718
21719
21720 \end_layout
21721
21722 \begin_layout Standard
21723 The syntax is 
21724 \family typewriter
21725
21726 \backslash
21727 parshape numlines #1indent #1length #2indent #2length \SpecialChar \ldots{}
21728  #nindent #nlength
21729 \family default
21730 , where 
21731 \family typewriter
21732 numlines
21733 \family default
21734  is the number of lines of text which define the paragraph.
21735  If there turn out to be fewer lines, the shape is truncated; if there are
21736  more, the excess lines have the same dimensions as the last line of the
21737  definition.
21738  The 
21739 \family typewriter
21740 #nindent
21741 \family default
21742  and 
21743 \family typewriter
21744 #nlength
21745 \family default
21746  entries specify the indentation of the line from the left margin, and the
21747  length of the line as measured from that point.
21748  The shape applies only to the current paragraph; everything is reset to
21749  normal for the next paragraph.
21750 \end_layout
21751
21752 \begin_layout Standard
21753 \begin_inset ERT
21754 status collapsed
21755
21756 \begin_layout Plain Layout
21757
21758
21759 \backslash
21760 end{sloppypar}
21761 \end_layout
21762
21763 \end_inset
21764
21765
21766 \end_layout
21767
21768 \begin_layout Section
21769 Summary
21770 \end_layout
21771
21772 \begin_layout Standard
21773 As you can see, the examples in this section range from the useful to the
21774  whimsical.
21775  While I don't expect that anyone will ever need the paragraph shape demonstrate
21776 d in the last section, the important point is that you can do almost anything
21777  you want in LyX if you are willing to figure out how to do it in TeX and
21778  LaTeX.
21779  TeX is a fantastically powerful typesetting system and all that power is
21780  available to you since LyX uses it as its backend.
21781  Happy LyXing!
21782 \end_layout
21783
21784 \end_body
21785 \end_document