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