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