]> git.lyx.org Git - lyx.git/blob - lib/doc/Extended.lyx
add new galician file
[lyx.git] / lib / doc / Extended.lyx
1 #LyX 1.4.3 created this file. For more info see http://www.lyx.org/
2 \lyxformat 245
3 \begin_document
4 \begin_header
5 \textclass book
6 \begin_preamble
7 \usepackage{multicol}
8 \newcommand{\extratablespace}[1]{\noalign{\vskip#1}}
9 \end_preamble
10 \language english
11 \inputencoding latin1
12 \fontscheme default
13 \graphics default
14 \paperfontsize default
15 \spacing single
16 \papersize default
17 \use_geometry false
18 \use_amsmath 0
19 \cite_engine basic
20 \use_bibtopic false
21 \paperorientation portrait
22 \secnumdepth 3
23 \tocdepth 3
24 \paragraph_separation indent
25 \defskip medskip
26 \quotes_language english
27 \papercolumns 1
28 \papersides 2
29 \paperpagestyle headings
30 \tracking_changes false
31 \output_changes true
32 \end_header
33
34 \begin_body
35
36 \begin_layout Title
37 Extended LyX Features
38 \end_layout
39
40 \begin_layout Author
41 by the LyX Team
42 \begin_inset Foot
43 status collapsed
44
45 \begin_layout Standard
46 \noindent
47 Principal maintainer of this file is
48 \noun on
49  Mike Ressler
50 \noun default
51 .
52  If you have comments or error corrections, please send them to the LyX
53  Documentation mailing list, <lyx-docs@lists.lyx.org>.
54 \end_layout
55
56 \end_inset
57
58  
59 \end_layout
60
61 \begin_layout Standard
62 \begin_inset LatexCommand \tableofcontents{}
63
64 \end_inset
65
66
67 \end_layout
68
69 \begin_layout Chapter
70 Introduction
71 \end_layout
72
73 \begin_layout Standard
74 The 
75 \emph on
76 Extended LyX Features
77 \emph default
78  manual, which you are now reading, is essentially Part II of the 
79 \emph on
80 User's Guide\SpecialChar \@.
81
82 \emph default
83  The reason for splitting this document is simple: the 
84 \emph on
85 User's Guide
86 \emph default
87  is already huge, and it contains all of the basic features one needs to
88  know in order to prepare most documents.
89  However, the LyX Team has a long-term goal of making LyX extensible through
90  various configuration files and external packages.
91  That means that if you want to support the Fizzwizzle LaTeX package, you
92  can create a layout file for it without having to alter LyX itself.
93  We've already had contributions of several new features this way.
94  This is the place where all of that gets documented.
95 \end_layout
96
97 \begin_layout Standard
98 This manual also documents some special features, like fax support, version
99  control, and SGML support, which require additional software to work properly.
100  Lastly, there's a chapter of LaTeX tools and tips, things you can use to
101  spruce up your documents by directly using the powerful features of LaTeX.
102  After all, LyX 
103 \emph on
104 is
105 \emph default
106  only WYSIWYM, and will only ever interface to certain LaTeX features.
107 \end_layout
108
109 \begin_layout Standard
110 Of course, with all of this extra documentation, 
111 \emph on
112 Extended LyX Features
113 \emph default
114  may itself grow too big for its britches.
115  In that case, you can just call it the 
116 \begin_inset Quotes eld
117 \end_inset
118
119 Overextended Manual
120 \begin_inset Quotes erd
121 \end_inset
122
123  for fun!
124 \end_layout
125
126 \begin_layout Standard
127 If you haven't read the 
128 \emph on
129 Introduction 
130 \emph default
131 yet, you are definitely in the wrong manual.
132  The 
133 \emph on
134 Introduction
135 \emph default
136  is the first place to go, since it will direct you to the correct manual,
137  and it also describes the notation and format of all of the manuals.
138  You should also be thoroughly familiar with the 
139 \emph on
140 User's Guide
141 \emph default
142  and all of the basic features of LyX.
143  
144 \end_layout
145
146 \begin_layout Standard
147 In this document, many sections are independent articles contributed by
148  an individual and are noted as such.
149  This person is generally whoever wrote the layout file for the new document
150  class or LaTeX package, or implemented the feature.
151  If there is no mention of an author to a chapter [or chapter sections],
152  that means it was written by the LyX Documentation Team.
153 \end_layout
154
155 \begin_layout Standard
156 Since all the topics in this manual depend heavily on LyX's interaction
157  with LaTeX, this first chapter covers
158 \emph on
159  
160 \emph default
161 the inner workings of LyX and how to direct LyX to generate exactly the
162  LaTeX code you want.
163  It is obviously for more seasoned LyX users.
164 \end_layout
165
166 \begin_layout Chapter
167 LyX and LaTeX
168 \end_layout
169
170 \begin_layout Section
171 How LyX Uses LaTeX
172 \end_layout
173
174 \begin_layout Standard
175 \begin_inset LatexCommand \label{sec:lyxandlatex}
176
177 \end_inset
178
179 This chapter is for both TeX-nicians and the LaTeX-curious.
180  In it, we'll explain how LyX and LaTeX work together to produce printable
181  output.
182  This is the only place in any of the manuals where we assume you know something
183  about LaTeX.
184 \end_layout
185
186 \begin_layout Standard
187 At one time, we called LyX a 
188 \begin_inset Quotes eld
189 \end_inset
190
191 WYSIWYM frontend to LaTeX,
192 \begin_inset Quotes erd
193 \end_inset
194
195  but that's no longer true.
196  There are frontends to LaTeX out there.
197  They are basically editors with the ability to run LaTeX and mark any errors
198  in the file you're editing.
199  Although LyX 
200 \emph on
201 is
202 \emph default
203  an editor, and it 
204 \emph on
205 does
206 \emph default
207  run LaTeX, and it also marks errors in the file, it also does much, much
208  more.
209  Thanks to the WYSIWYM concept, you don't need LaTeX to use LyX effectively.
210  LyX has also added a few extensions to LaTeX.
211  Try the following sometime: select 
212 \family sans
213 Export\SpecialChar \menuseparator
214 LaTeX
215 \family default
216  from the 
217 \family sans
218 \bar under
219 F
220 \bar default
221 ile
222 \family default
223  menu, then look at the preamble of the resulting 
224 \family typewriter
225 .tex
226 \family default
227  file.
228  You'll notice a variety of new macros defined specifically by LyX.
229  These macros are defined automatically, according to the features you use
230  in the document.
231 \end_layout
232
233 \begin_layout Standard
234 There are several commands that automatically invoke LaTeX.
235  They are:
236 \end_layout
237
238 \begin_layout Itemize
239
240 \family sans
241 \bar under
242 V
243 \bar default
244 iew\SpecialChar \menuseparator
245 View\InsetSpace ~
246
247 \emph on
248 Format
249 \end_layout
250
251 \begin_layout Itemize
252
253 \family sans
254 \bar under
255 V
256 \bar default
257 iew\SpecialChar \menuseparator
258
259 \bar under
260 U
261 \bar default
262 pdate\SpecialChar \menuseparator
263
264 \emph on
265 Format
266 \end_layout
267
268 \begin_layout Itemize
269
270 \family sans
271 \bar under
272 F
273 \bar default
274 ile
275 \bar under
276 \SpecialChar \menuseparator
277 P
278 \bar default
279 rint
280 \end_layout
281
282 \begin_layout Itemize
283
284 \family sans
285 \bar under
286 F
287 \bar default
288 ile
289 \bar under
290 \SpecialChar \menuseparator
291 F
292 \bar default
293 ax
294 \end_layout
295
296 \begin_layout Standard
297 They will only invoke LaTeX if the file has changed since the last time
298  LaTeX was run.
299  
300 \end_layout
301
302 \begin_layout Standard
303 When you run LaTeX on the file you're editing, LyX performs these steps:
304 \end_layout
305
306 \begin_layout Enumerate
307 Convert the document to LaTeX and save to a file with the extension 
308 \family typewriter
309 .tex
310 \family default
311  in place of 
312 \family typewriter
313 .lyx
314 \family default
315 .
316 \end_layout
317
318 \begin_layout Enumerate
319 Run LaTeX on the 
320 \family typewriter
321 .tex
322 \family default
323  file (maybe several times).
324 \end_layout
325
326 \begin_layout Enumerate
327 If there are any errors, insert error boxes in the document to mark where
328  they are.
329  These boxes are transient and are not saved along with the document.
330 \end_layout
331
332 \begin_layout Standard
333 If you've run LaTeX using 
334 \family sans
335 View\InsetSpace ~
336 DVI
337 \family default
338 , LyX then executes 
339 \family typewriter
340 xdvi
341 \family default
342  on the Dvi file.
343  If you've used 
344 \family sans
345 View\InsetSpace ~
346 PostScript
347 \family default
348  or 
349 \family sans
350 \bar under
351 P
352 \bar default
353 rint
354 \family default
355 , LyX performs two more steps:
356 \end_layout
357
358 \begin_layout Itemize
359 Run 
360 \family typewriter
361 dvips
362 \family default
363  to convert the DVI file to PostScript®:
364 \end_layout
365
366 \begin_deeper
367 \begin_layout Itemize
368 For 
369 \family sans
370 View\InsetSpace ~
371 PostScript
372 \family default
373 , the output file has the extension 
374 \family typewriter
375 .ps_tmp
376 \end_layout
377
378 \begin_layout Itemize
379 For 
380 \family sans
381 \bar under
382 P
383 \bar default
384 rint
385 \family default
386 \InsetSpace ~
387 , the output file has the extension 
388 \family typewriter
389 .ps
390 \family default
391 , as expected.
392 \end_layout
393
394 \end_deeper
395 \begin_layout Itemize
396 Execute 
397 \family typewriter
398 ghostview
399 \family default
400  or send the PostScript® file to the printer.
401 \end_layout
402
403 \begin_layout Section
404 \begin_inset Quotes eld
405 \end_inset
406
407 Help! LyX generated an unreadable 
408 \family typewriter
409 .tex
410 \family default
411  file!
412 \begin_inset Quotes erd
413 \end_inset
414
415
416 \end_layout
417
418 \begin_layout Standard
419 Die-hard LaTeX users will scream and howl this into the night, then declare
420  LyX useless, simply because they didn't RTFM.
421 \end_layout
422
423 \begin_layout Standard
424 We're going to set the record straight.
425  LyX produces two kinds of LaTeX files.
426  One is human readable.
427  The other is LyX readable.
428  Every time LyX executes LaTeX, it produces a LaTeX file that it can easily
429  scan for errors.
430  The resulting 
431 \family typewriter
432 .tex
433 \family default
434  file is not human readable.
435  Don't even try to read it.
436  If you want a 
437 \family typewriter
438 .tex
439 \family default
440  file that you can send to a colleague, select 
441 \family sans
442 \bar under
443 E
444 \bar default
445 xport\SpecialChar \menuseparator
446
447 \bar under
448 L
449 \bar default
450 aTeX
451 \family default
452  from the 
453 \family sans
454 \bar under
455 F
456 \bar default
457 ile
458 \family default
459  menu.
460 \end_layout
461
462 \begin_layout Section
463 Translating LaTeX files into LyX
464 \end_layout
465
466 \begin_layout Standard
467 You can import a LaTeX file into LyX by using the 
468 \family sans
469 \bar under
470 F
471 \bar default
472 ile\SpecialChar \menuseparator
473
474 \bar under
475 I
476 \bar default
477 mport\SpecialChar \menuseparator
478
479 \bar under
480 L
481 \bar default
482 aTeX
483 \family default
484  command in LyX.
485  This will call a Perl script named 
486 \family typewriter
487 reLyX
488 \family default
489 ---which will create a file 
490 \family typewriter
491 foo.lyx
492 \family default
493  from the file 
494 \family typewriter
495 foo.tex
496 \family default
497 ---and then open that file.
498  If the translation doesn't work, you can try calling 
499 \family typewriter
500 reLyX
501 \family default
502  from the command line, possibly using fancier options.
503 \end_layout
504
505 \begin_layout Standard
506
507 \family typewriter
508 reLyX
509 \family default
510  will translate most legal LaTeX, but not everything.
511  It will leave things it doesn't understand in TeX mode, so after translating
512  a file with 
513 \family typewriter
514 reLyX
515 \family default
516 , you can look for red text and hand-edit it to look right.
517 \end_layout
518
519 \begin_layout Standard
520
521 \family typewriter
522 reLyX
523 \family default
524  has its own section in the 
525 \emph on
526 Extended Features
527 \emph default
528  manual (as well as a Unix manpage equivalent), which you should read to
529  find out about what LaTeX isn't supported, bugs (and how to get around
530  them), and how to use the various options.
531 \end_layout
532
533 \begin_layout Standard
534 If you can't get 
535 \family typewriter
536 reLyX
537 \family default
538  to work, or you just want to put a piece of LaTeX code into a LyX file,
539  see Section
540 \begin_inset LatexCommand \ref{sec:latexcodes}
541
542 \end_inset
543
544 .
545 \end_layout
546
547 \begin_layout Section
548 Inserting LaTeX Code into LyX Documents 
549 \begin_inset LatexCommand \label{sec:Inserting-LaTeX-Code}
550
551 \end_inset
552
553
554 \end_layout
555
556 \begin_layout Standard
557 \begin_inset LatexCommand \label{sec:latexcodes}
558
559 \end_inset
560
561  This is a rather important point: You can always insert LaTeX code into
562  any LyX document.
563  LyX simply cannot, and will probably never be able to, display every possible
564  LaTeX construct.
565  If ever you need to insert LaTeX commands into your LyX document, you can
566  use the ERT box, which you can insert into your document with 
567 \family sans
568 \bar under
569 I
570 \bar default
571 nsert\SpecialChar \menuseparator
572
573 \bar under
574 T
575 \bar default
576 eX
577 \family default
578 .
579  The ERT box comes in three forms: collapsed, open, and inlined.
580  The first two are used just like any other collapsible (foldable) box (such
581  as footnotes), and are useful for significant amounts of LaTeX commands.
582  An 
583 \begin_inset Quotes eld
584 \end_inset
585
586 inlined
587 \begin_inset Quotes erd
588 \end_inset
589
590  ERT box displays its content as part of the button, and is useful for very
591  short sections of LaTeX commands.
592  
593 \begin_inset ERT
594 status inlined
595
596 \begin_layout Standard
597
598 % like this
599 \end_layout
600
601 \end_inset
602
603
604 \end_layout
605
606 \begin_layout Standard
607 You can switch between all three by right-clicking on the ERT.
608  Note that if you want more than one line of LaTeX commands, you cannot
609  use the inlined mode.
610 \end_layout
611
612 \begin_layout Standard
613 Here's an example of inserting LaTeX commands in a LyX document.
614  The code looks like this:
615 \end_layout
616
617 \begin_layout LyX-Code
618
619 \backslash
620 begin{tabular}{ll}
621 \newline
622
623 \backslash
624 begin{minipage}{5cm}
625 \newline
626 This is an example for a minipage environment.
627  You 
628 \newline
629 can put nearly everything in it, even (non-floating) 
630 \newline
631 figures and tables.
632  
633 \newline
634
635 \backslash
636 end{minipage}
637 \newline
638 &
639 \newline
640
641 \backslash
642 begin{minipage}{5cm}
643 \newline
644
645 \backslash
646 begin{verbatim}
647 \newline
648
649 \backslash
650 begin{minipage}{5cm}
651 \newline
652 This ...
653  
654 \newline
655
656 \backslash
657 end{minipage}
658 \newline
659
660 \backslash
661 end{verbatim}
662 \newline
663
664 \backslash
665 end{minipage}
666 \newline
667
668 \backslash
669 end{tabular}
670 \end_layout
671
672 \begin_layout LyX-Code
673
674 \end_layout
675
676 \begin_layout Standard
677 The ERT box containing this text is directly after this paragraph.
678  Those of you reading the manual online will only see a bunch of funky text
679  in red.
680  Those reading a printed version of the manuals will see the actual results:
681 \end_layout
682
683 \begin_layout Standard
684 \begin_inset ERT
685 status collapsed
686
687 \begin_layout Standard
688
689
690 \backslash
691 begin{tabular}{ll}
692 \end_layout
693
694 \begin_layout Standard
695
696
697 \backslash
698 begin{minipage}{5cm}
699 \end_layout
700
701 \begin_layout Standard
702
703 This is an example for a minipage environment.
704  You can put nearly everything in it, even (non-floating) figures and tables.
705  
706 \end_layout
707
708 \begin_layout Standard
709
710
711 \backslash
712 end{minipage}
713 \end_layout
714
715 \begin_layout Standard
716
717 &
718 \end_layout
719
720 \begin_layout Standard
721
722
723 \backslash
724 begin{minipage}{5cm}
725 \end_layout
726
727 \begin_layout Standard
728
729
730 \backslash
731 begin{verbatim}
732 \end_layout
733
734 \begin_layout Standard
735
736
737 \backslash
738 begin{minipage}{5cm}
739 \end_layout
740
741 \begin_layout Standard
742
743 This ...
744  
745 \end_layout
746
747 \begin_layout Standard
748
749
750 \backslash
751 end{minipage}
752 \end_layout
753
754 \begin_layout Standard
755
756
757 \backslash
758 end{verbatim}
759 \end_layout
760
761 \begin_layout Standard
762
763
764 \backslash
765 end{minipage}
766 \end_layout
767
768 \begin_layout Standard
769
770
771 \backslash
772 end{tabular}
773 \end_layout
774
775 \end_inset
776
777
778 \end_layout
779
780 \begin_layout Standard
781 In addition to these two methods, you can also create a separate file containing
782  some complex LaTeX structure.
783  You can then use 
784 \family sans
785 \bar under
786 I
787 \bar default
788 nsert\SpecialChar \menuseparator
789 Chil
790 \bar under
791 d
792 \bar default
793 \InsetSpace ~
794 Document
795 \family default
796  to include your file (you should select the type 
797 \family sans
798 Input
799 \family default
800 ).
801  We recommend that you only do this if you have a 
802 \family typewriter
803 .tex
804 \family default
805  file which you 
806 \emph on
807 know
808 \emph default
809  works already.
810  Otherwise, you'll have a big job tracking down LaTeX errors\SpecialChar \ldots{}
811
812 \end_layout
813
814 \begin_layout Standard
815 There are a few last notes to emphasize:
816 \end_layout
817
818 \begin_layout Itemize
819 Inside of LyX, LaTeX code appears 
820 \emph on
821 in red
822 \end_layout
823
824 \begin_layout Itemize
825 LyX 
826 \emph on
827 does not
828 \emph default
829  check if your LaTeX code is correct.
830 \end_layout
831
832 \begin_layout Itemize
833 Beware reinventing the wheel.
834 \end_layout
835
836 \begin_layout Standard
837 That last note refers to two things.
838  First, LyX does have quite a few features tucked into it, and more are
839  coming.
840  Be sure to check the manuals to make sure that LyX doesn't have such-and-such
841  feature before you go off merrily coding LaTeX.
842  Second, there are numerous LaTeX packages out there to do all sorts of
843  things, from labels to envelopes to fancy multipage tables.
844  Check out a CTAN site for details (see Section 
845 \begin_inset Quotes eld
846 \end_inset
847
848 Requirements
849 \begin_inset Quotes erd
850 \end_inset
851
852  of the 
853 \emph on
854 User's Guide
855 \emph default
856 ).
857 \begin_inset Foot
858 status open
859
860 \begin_layout Standard
861 Note from 
862 \noun on
863 John Weiss
864 \noun default
865 : I seem to do this an awful lot.
866  Sat down and merrily began coding something to print out labels, only to
867  learn that there were already 2 different LaTeX packages to do this.
868  Worse yet --- I had them already!
869 \end_layout
870
871 \end_inset
872
873
874 \end_layout
875
876 \begin_layout Standard
877 If you do need to do some wild and fancy things within your document, be
878  sure to check out a good LaTeX book for assistance.
879  There are a number of them listed in the bibliography of the 
880 \emph on
881 User's Guide
882 \emph default
883 .
884 \end_layout
885
886 \begin_layout Standard
887 There are a number of LaTeX commands which have to be placed before the
888  beginning of the actual text.
889  They go into the preamble, and this is explained in the next section.
890 \end_layout
891
892 \begin_layout Section
893 LyX and the LaTeX Preamble
894 \end_layout
895
896 \begin_layout Subsection
897 About the LaTeX Preamble
898 \end_layout
899
900 \begin_layout Standard
901 \begin_inset LatexCommand \label{sec:preamble}
902
903 \end_inset
904
905 If you already know LaTeX, there is no need to explain here what the preamble
906  is good for.
907  If you don't, the following will give you some ideas --- we recommend again
908  that you consult a LaTeX book for further information.
909  In any case, you should read the points below, because they explain what
910  you can do and what you don't need to do in the LaTeX preamble of a LyX
911  document.
912 \end_layout
913
914 \begin_layout Standard
915 The LaTeX preamble comes at the very beginning of a document, 
916 \emph on
917 before 
918 \emph default
919 the text.
920  It serves to:
921 \end_layout
922
923 \begin_layout Itemize
924 declare the document class.
925  LyX already does this for you.
926 \end_layout
927
928 \begin_deeper
929 \begin_layout Standard
930 If you're a seasoned LaTeX-nician, and you have some custom document class
931  you want to use, check out the 
932 \emph on
933 Customization Manual
934 \emph default
935  for information on how to make LyX interface to it.
936  Be sure to submit your efforts to the LyX Team for inclusion in future
937  versions!
938 \end_layout
939
940 \end_deeper
941 \begin_layout Itemize
942 declare the usage of packages.
943  LaTeX packages provide special commands, which are only available within
944  a document when the package has been declared in the preamble.
945  For example, the
946 \family typewriter
947  
948 \family default
949 package 
950 \family typewriter
951 indentfirst
952 \family default
953  forces all paragraphs to be indented.
954  There are other packages for labels, envelopes, margins, etc.
955  
956 \end_layout
957
958 \begin_layout Itemize
959 set counters, variables, lengths and widths.
960  There are several LaTeX counters and variables which 
961 \emph on
962 must
963 \emph default
964  be set globally from within the preamble in order to have the desired effect.
965  [There are other variables which you can set and reset inside the document,
966  too.] Margins are a good example of something which must be set in the preamble.
967  Another example is the label format for lists.
968  You can actually set these just about anywhere, but it's best to do it
969  just once, inside the preamble.
970 \end_layout
971
972 \begin_layout Itemize
973 declare user defined commands [with 
974 \family typewriter
975
976 \backslash
977 newcommand 
978 \family default
979 or 
980 \family typewriter
981
982 \backslash
983 renewcommand
984 \family default
985 ], mostly abbreviations for LaTeX commands which appear very often inside
986  a document.
987  Although the preamble is a good place to declare such commands, they 
988 \emph on
989 can
990 \emph default
991  be declared anywhere else [but 
992 \emph on
993 before
994 \emph default
995  they are used for the first time, of course\SpecialChar \ldots{}
996 ].
997  This can be useful if there is a lot of raw LaTeX code in your document,
998  which normally should not be the case.
999 \end_layout
1000
1001 \begin_layout Standard
1002 LyX adds its own set of definitions to the preamble of the 
1003 \family typewriter
1004 .tex
1005 \family default
1006  file it produces.
1007  This makes LaTeX files generated by LyX portable.
1008 \end_layout
1009
1010 \begin_layout Subsection
1011 Changing the Preamble
1012 \end_layout
1013
1014 \begin_layout Standard
1015 The commands which LyX adds to the preamble of a LaTeX file are fixed; you
1016  can't change them without patching LyX itself.
1017  You can, however, add your own stuff to the preamble.
1018  There are two ways to do this:
1019 \end_layout
1020
1021 \begin_layout Enumerate
1022 Select 
1023 \family sans
1024 \bar under
1025 L
1026 \bar default
1027 aTeX\InsetSpace ~
1028
1029 \bar under
1030 P
1031 \bar default
1032 reamble
1033 \family default
1034  from the 
1035 \family sans
1036 \bar under
1037 D
1038 \bar default
1039 ocument
1040 \family default
1041  menu, or via the 
1042 \family sans
1043 \bar under
1044 D
1045 \bar default
1046 ocument
1047 \family default
1048 \SpecialChar \menuseparator
1049
1050 \family sans
1051 \bar under
1052 S
1053 \bar default
1054 ettings
1055 \family default
1056  dialog, depending on your frontend.
1057  Note that the LyX keybindings will not work in this dialog, alas.
1058 \end_layout
1059
1060 \begin_layout Enumerate
1061 Use the preamble contents you've added as your default template (see 
1062 \begin_inset Quotes eld
1063 \end_inset
1064
1065 Basic LyX Setup
1066 \begin_inset Quotes erd
1067 \end_inset
1068
1069  in the 
1070 \emph on
1071 User's Guide
1072 \emph default
1073 ), so that it will be the default preamble for any file you create.
1074 \end_layout
1075
1076 \begin_layout Standard
1077 LyX adds anything in the 
1078 \family sans
1079 \bar under
1080 P
1081 \bar default
1082 reamble
1083 \family default
1084  dialog to its own built-in preamble.
1085  Before adding your own declarations in the preamble, you should make sure
1086  that LyX doesn't already support what you want to do (remember what we
1087  said about reinventing the wheel?).
1088  Also, 
1089 \emph on
1090 make sure your preamble code is correct
1091 \emph default
1092 .
1093  LyX doesn't check it.
1094 \end_layout
1095
1096 \begin_layout Subsection
1097 Examples
1098 \end_layout
1099
1100 \begin_layout Standard
1101 Here are some examples of what you can add to a preamble, and what they
1102  do:
1103 \end_layout
1104
1105 \begin_layout Subsubsection
1106 Example #1: Offsets
1107 \end_layout
1108
1109 \begin_layout Standard
1110 There are two variables under LaTeX that control page position: 
1111 \family typewriter
1112
1113 \backslash
1114 hoffset
1115 \family default
1116  and 
1117 \family typewriter
1118
1119 \backslash
1120 voffset
1121 \family default
1122 .
1123  Their names should be self-explanatory.
1124  These variables are useful if you think for a moment about computer labels.
1125  Sometimes, the size of a print medium and the area of the medium that you
1126  can actually print on aren't the same.
1127  This is where 
1128 \family typewriter
1129
1130 \backslash
1131 hoffset
1132 \family default
1133  and 
1134 \family typewriter
1135
1136 \backslash
1137 voffset
1138 \family default
1139  come in.
1140 \end_layout
1141
1142 \begin_layout Standard
1143 The default values for 
1144 \family typewriter
1145
1146 \backslash
1147 hoffset
1148 \family default
1149  and 
1150 \family typewriter
1151
1152 \backslash
1153 voffset
1154 \family default
1155  are both 0 pt.,\InsetSpace ~
1156 i.\InsetSpace ~
1157 e.\InsetSpace ~
1158 the page isn't shifted.
1159 \end_layout
1160
1161 \begin_layout Standard
1162 Unfortunately, some DVI drivers always seem to shift the page.
1163  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1164  If you're using LyX on a system that you don't personally maintain, and
1165  your sysadmin is a doofus, 
1166 \family typewriter
1167
1168 \backslash
1169 hoffset
1170 \family default
1171  and 
1172 \family typewriter
1173
1174 \backslash
1175 voffset
1176 \family default
1177  can save the day.
1178  Suppose you're left and top margins are always 0.5 inches too big.
1179  You can add this to the preamble:
1180 \end_layout
1181
1182 \begin_layout LyX-Code
1183
1184 \backslash
1185 setlength{
1186 \backslash
1187 hoffset}{-0.5 in}
1188 \end_layout
1189
1190 \begin_layout LyX-Code
1191
1192 \backslash
1193 setlength{
1194 \backslash
1195 voffset}{-0.5 in}
1196 \end_layout
1197
1198 \begin_layout Standard
1199 \SpecialChar \ldots{}
1200 and your margins should now be correct.
1201 \end_layout
1202
1203 \begin_layout Subsubsection
1204 Example #2: Labels
1205 \end_layout
1206
1207 \begin_layout Standard
1208 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1209  There's a rather nice package, available at your nearest CTAN archive,
1210  for printing sheets of labels, called 
1211 \family typewriter
1212 labels.sty
1213 \family default
1214 .
1215  Now, your system may not have this package installed by default.
1216  We leave that up to you to check.
1217  You'll also want to read the documentation for it; we're not going to do
1218  that for you.
1219  Since this is an example, however, we'll give you an example of how you
1220  use this package.
1221 \end_layout
1222
1223 \begin_layout Standard
1224 First, make sure you're using the 
1225 \family sans
1226 article 
1227 \family default
1228 document class.
1229  Next, you need to put the following in your preamble:
1230 \end_layout
1231
1232 \begin_layout LyX-Code
1233
1234 \backslash
1235 usepackage{labels}
1236 \end_layout
1237
1238 \begin_layout LyX-Code
1239
1240 \backslash
1241 LabelCols=3
1242 \end_layout
1243
1244 \begin_layout LyX-Code
1245
1246 \backslash
1247 LabelRows=7
1248 \end_layout
1249
1250 \begin_layout LyX-Code
1251
1252 \backslash
1253 LeftBorder=8mm
1254 \end_layout
1255
1256 \begin_layout LyX-Code
1257
1258 \backslash
1259 RightBorder=8mm
1260 \end_layout
1261
1262 \begin_layout LyX-Code
1263
1264 \backslash
1265 TopBorder=9mm
1266 \end_layout
1267
1268 \begin_layout LyX-Code
1269
1270 \backslash
1271 BottomBorder=2mm
1272 \end_layout
1273
1274 \begin_layout Standard
1275 This sets things up for Avery® label sheets, stock #5360.
1276  You're now ready to print labels, but you'll need to insert LaTeX code,
1277  placing the commands 
1278 \family typewriter
1279
1280 \backslash
1281 begin{labels}
1282 \family default
1283  and 
1284 \family typewriter
1285
1286 \backslash
1287 end{labels}
1288 \family default
1289  around each label text.
1290  This and other special features of 
1291 \family typewriter
1292 labels.sty
1293 \family default
1294  are explained in its documentation.
1295 \end_layout
1296
1297 \begin_layout Standard
1298 Someday, someone may write a LyX layout file to support this package directly.
1299  Maybe that someone is you.
1300 \end_layout
1301
1302 \begin_layout Subsubsection
1303 Example #3: Paragraph Indentation
1304 \end_layout
1305
1306 \begin_layout Standard
1307 Americans are trained to indent the first line of 
1308 \emph on
1309 every
1310 \emph default
1311  paragraph.
1312  As with all of their other weird quirks, most Americans will whine and
1313  moan until they can have their way and indent the first line of all paragraphs.
1314 \begin_inset Foot
1315 status collapsed
1316
1317 \begin_layout Standard
1318 Note from 
1319 \noun on
1320 John Weiss
1321 \noun default
1322 : This was written by an American --- 
1323 \emph on
1324 me
1325 \emph default
1326 ! It's my perception of my fellow countrymen.
1327  Tough if you don't like it.
1328  Thpbpbpbpbpbpbpbp!
1329 \end_layout
1330
1331 \end_inset
1332
1333
1334 \end_layout
1335
1336 \begin_layout Standard
1337 Of course, this behavior isn't standard typography.
1338  In books, you typically only indent the first line of a paragraph 
1339 \emph on
1340 if
1341 \emph default
1342  it follows another one.
1343  The idea behind indenting the first line of a paragraph is to distinguish
1344  neighboring paragraphs from one another.
1345  If there is no previous paragraph, for example, it follows a figure, or
1346  is the first paragraph in a section, then there is no special indentation.
1347  
1348 \end_layout
1349
1350 \begin_layout Standard
1351 If you're a typical American, though, you don't care about such esoteric
1352  things; you want your indentation! Add this to the preamble:
1353 \end_layout
1354
1355 \begin_layout LyX-Code
1356
1357 \backslash
1358 usepackage{indentfirst}
1359 \end_layout
1360
1361 \begin_layout Standard
1362 If your TeX distribution isn't a braindead one, you'll have this package,
1363  and all of your paragraphs will get the indentation you think they deserve.
1364 \end_layout
1365
1366 \begin_layout Subsubsection
1367 Example #4: This Document
1368 \end_layout
1369
1370 \begin_layout Standard
1371 You can also check out the preamble of this document to get an idea of some
1372  of the advanced things you can do.
1373  You'll probably need to make the 
1374 \family sans
1375 \bar under
1376 P
1377 \bar default
1378 reamble\SpecialChar \ldots{}
1379
1380 \family default
1381  dialog full-screen to see most of it.
1382  Also, there are more examples and an assortment of LaTeX 
1383 \begin_inset Quotes eld
1384 \end_inset
1385
1386 dirty tricks
1387 \begin_inset Quotes erd
1388 \end_inset
1389
1390  given in Chapter\InsetSpace ~
1391
1392 \begin_inset LatexCommand \ref{cha:secrets}
1393
1394 \end_inset
1395
1396 .
1397  
1398 \end_layout
1399
1400 \begin_layout Section
1401 LyX and LaTeX Errors
1402 \end_layout
1403
1404 \begin_layout Standard
1405 When LyX calls LaTeX, it tells LaTeX to blithely ignore any errors and keep
1406  going.
1407  It then uses the log-file from the LaTeX run to do a post-mortem.
1408  As we stated earlier in the chapter, LyX generates two kinds of 
1409 \family typewriter
1410 .tex
1411 \family default
1412  files, one of which it uses to locate errors in the document.
1413  If there was an error someplace, LyX will put a box with the word 
1414 \begin_inset Quotes eld
1415 \end_inset
1416
1417 Error
1418 \begin_inset Quotes erd
1419 \end_inset
1420
1421  at the appropriate place in the document.
1422 \begin_inset Foot
1423 status collapsed
1424
1425 \begin_layout Standard
1426 LyX will occasionally misguess where the error was.
1427  This will typically happen with tables, figures, math, and the preamble.
1428 \end_layout
1429
1430 \end_inset
1431
1432  It will also display a message alerting you to the fact that there were
1433  errors.
1434 \end_layout
1435
1436 \begin_layout Standard
1437 You can navigate through the errors by using 
1438 \family sans
1439 \bar under
1440 E
1441 \bar default
1442 rror
1443 \family default
1444  in the 
1445 \family sans
1446 \bar under
1447 N
1448 \bar default
1449 avigate
1450 \family default
1451  menu.
1452  You can 
1453 \begin_inset Quotes eld
1454 \end_inset
1455
1456 open
1457 \begin_inset Quotes erd
1458 \end_inset
1459
1460  the error-boxes and view the error message LaTeX produced by clicking on
1461  it.
1462 \end_layout
1463
1464 \begin_layout Standard
1465 Some folks also like to look at the log file directly, accessible from
1466 \family sans
1467  
1468 \bar under
1469 D
1470 \bar default
1471 ocument\SpecialChar \menuseparator
1472
1473 \bar under
1474 L
1475 \bar default
1476 aTeX\InsetSpace ~
1477 Log\InsetSpace ~
1478 File
1479 \family default
1480 .
1481  There are some fairly common error messages and warnings.
1482  We'll cover those here.
1483  You should look at a good LaTeX book for a complete listing.
1484 \end_layout
1485
1486 \begin_layout Itemize
1487 \begin_inset Quotes eld
1488 \end_inset
1489
1490
1491 \family typewriter
1492 LaTeX Warning:
1493 \family default
1494
1495 \begin_inset Quotes eld
1496 \end_inset
1497
1498
1499 \end_layout
1500
1501 \begin_deeper
1502 \begin_layout Standard
1503 Anything beginning with these word is a warning message for the purpose
1504  of 
1505 \begin_inset Quotes eld
1506 \end_inset
1507
1508 debugging
1509 \begin_inset Quotes erd
1510 \end_inset
1511
1512  the LaTeX code itself.
1513  You'll get messages like this if you added or changed cross-references
1514  or bibliography entries, in which case, LaTeX is trying to tell you that
1515  you need to make another run.
1516 \end_layout
1517
1518 \begin_layout Standard
1519 You can by-and-large ignore these.
1520 \end_layout
1521
1522 \end_deeper
1523 \begin_layout Itemize
1524 \begin_inset Quotes eld
1525 \end_inset
1526
1527
1528 \family typewriter
1529 LaTeX Font Warning:
1530 \family default
1531
1532 \begin_inset Quotes erd
1533 \end_inset
1534
1535
1536 \end_layout
1537
1538 \begin_deeper
1539 \begin_layout Standard
1540 Another warning message, this time about fonts which LaTeX couldn't find.
1541  The rest of the message will often say something about a replacement font
1542  that LaTeX used.
1543 \end_layout
1544
1545 \begin_layout Standard
1546 You can safely ignore these.
1547 \end_layout
1548
1549 \end_deeper
1550 \begin_layout Itemize
1551 \begin_inset Quotes eld
1552 \end_inset
1553
1554
1555 \family typewriter
1556 Overfull 
1557 \backslash
1558 hbox
1559 \family default
1560
1561 \begin_inset Quotes erd
1562 \end_inset
1563
1564
1565 \end_layout
1566
1567 \begin_deeper
1568 \begin_layout Standard
1569 LaTeX absolutely 
1570 \emph on
1571 loves
1572 \emph default
1573  to spew these out.
1574  They are warning you about lines that were too long and run past the right
1575  margin.
1576  Almost always, this is unnoticeable in the final output.
1577  Or, only one or two characters extend past the margin.
1578  LaTeX seems to generate at least one of these messages for just about any
1579  document you write.
1580 \end_layout
1581
1582 \begin_layout Standard
1583 You can ignore these stupid messages.
1584  Your eyes will tell you if there's a problem with something that's too
1585  wide; just look at the output.
1586 \end_layout
1587
1588 \end_deeper
1589 \begin_layout Itemize
1590 \begin_inset Quotes eld
1591 \end_inset
1592
1593
1594 \family typewriter
1595 Underfull 
1596 \backslash
1597 hbox
1598 \family default
1599
1600 \begin_inset Quotes erd
1601 \end_inset
1602
1603
1604 \end_layout
1605
1606 \begin_deeper
1607 \begin_layout Standard
1608 Not quite as common as its cousin.
1609  LaTeX seems to like to print lines that are a bit too wide as opposed to
1610  ones that are a bit too narrow.
1611  We have no idea why.
1612 \end_layout
1613
1614 \begin_layout Standard
1615 You can ignore these, too.
1616 \end_layout
1617
1618 \end_deeper
1619 \begin_layout Itemize
1620 \begin_inset Quotes eld
1621 \end_inset
1622
1623
1624 \family typewriter
1625 Overfull 
1626 \backslash
1627 vbox
1628 \family default
1629
1630 \begin_inset Quotes erd
1631 \end_inset
1632
1633  and 
1634 \begin_inset Quotes eld
1635 \end_inset
1636
1637
1638 \family typewriter
1639 Underfull 
1640 \backslash
1641 vbox
1642 \family default
1643
1644 \begin_inset Quotes erd
1645 \end_inset
1646
1647
1648 \end_layout
1649
1650 \begin_deeper
1651 \begin_layout Standard
1652 Warnings about troubles breaking the page.
1653  Once again, just look at the output.
1654  Your eyes will tell you where something has gone wrong.
1655 \end_layout
1656
1657 \end_deeper
1658 \begin_layout Itemize
1659 \begin_inset Quotes eld
1660 \end_inset
1661
1662  
1663 \family typewriter
1664 LaTeX Error: File 
1665 \begin_inset Quotes els
1666 \end_inset
1667
1668 Xxxx
1669 \begin_inset Quotes ers
1670 \end_inset
1671
1672  not found
1673 \family default
1674
1675 \begin_inset Quotes erd
1676 \end_inset
1677
1678  
1679 \end_layout
1680
1681 \begin_deeper
1682 \begin_layout Standard
1683 The file 
1684 \begin_inset Quotes eld
1685 \end_inset
1686
1687 Xxxx
1688 \begin_inset Quotes erd
1689 \end_inset
1690
1691  isn't installed on this system.
1692  This usually appears because some package your document needs isn't installed.
1693  If you didn't touch the preamble or didn't use the 
1694 \family typewriter
1695
1696 \backslash
1697 usepackage{}
1698 \family default
1699  command, then one of the packages LyX tried to load is missing.
1700  Use 
1701 \family sans
1702 \bar under
1703 H
1704 \bar default
1705 elp\SpecialChar \menuseparator
1706 L
1707 \bar under
1708 a
1709 \bar default
1710 TeX Configuration
1711 \family default
1712 , to get a list of packages that LyX knows about.
1713  This file is updated whenever you reconfigure LyX (using 
1714 \family sans
1715 \bar under
1716 T
1717 \bar default
1718 ools
1719 \bar under
1720 \SpecialChar \menuseparator
1721 R
1722 \bar default
1723 econfigure
1724 \family default
1725 ) and tells you which packages have been detected and what they do.
1726 \end_layout
1727
1728 \begin_layout Standard
1729 If you 
1730 \emph on
1731 did
1732 \emph default
1733  use the 
1734 \family typewriter
1735
1736 \backslash
1737 usepackage{}
1738 \family default
1739  command, and the package in question isn't installed, you'll need to install
1740  it yourself.
1741 \end_layout
1742
1743 \end_deeper
1744 \begin_layout Itemize
1745 \begin_inset Quotes eld
1746 \end_inset
1747
1748
1749 \family typewriter
1750 LaTeX Error: Unknown option
1751 \family default
1752
1753 \begin_inset Quotes erd
1754 \end_inset
1755
1756
1757 \end_layout
1758
1759 \begin_deeper
1760 \begin_layout Standard
1761 Error messages beginning with this are trying to tell you that you specified
1762  a bad or undefined option to a package.
1763  Check the package's documentation.
1764 \end_layout
1765
1766 \end_deeper
1767 \begin_layout Itemize
1768 \begin_inset Quotes eld
1769 \end_inset
1770
1771
1772 \family typewriter
1773 Undefined control sequence
1774 \family default
1775
1776 \begin_inset Quotes erd
1777 \end_inset
1778
1779
1780 \end_layout
1781
1782 \begin_deeper
1783 \begin_layout Standard
1784 If you've inserted LaTeX code into your document, but made a typo, you'll
1785  get one of these.
1786  You may have forgotten to load a package.
1787  In any case, this error message usually means that you used an undefined
1788  command.
1789 \end_layout
1790
1791 \end_deeper
1792 \begin_layout Standard
1793 There are other error and warning messages.
1794  Some are self-explanatory.
1795  These are usually LaTeX messages.
1796  Others are downright cryptic.
1797  These are actually TeX error messages, and we really have 
1798 \emph on
1799 no clue
1800 \emph default
1801  what they mean or how to decipher them.
1802 \end_layout
1803
1804 \begin_layout Standard
1805 There's a general sequence you should follow if you get error messages:
1806 \end_layout
1807
1808 \begin_layout Enumerate
1809 Look at the LaTeX code you inserted for typos.
1810 \end_layout
1811
1812 \begin_layout Enumerate
1813 If there are no typos, check and see that you used the command(s) correctly.
1814 \end_layout
1815
1816 \begin_layout Enumerate
1817 If you get a bunch of error boxes piled up at the very top of the document,
1818  it means that there are errors in the preamble.
1819  Start debugging your preamble.
1820 \end_layout
1821
1822 \begin_layout Enumerate
1823 If you didn't add anything to the preamble and didn't add any LaTeX code
1824  to the document, the first suspect is your LaTeX distribution itself.
1825  Check for missing packages and install them.
1826 \end_layout
1827
1828 \begin_layout Enumerate
1829 Okay, so there are no missing packages.
1830  Did you use any of the fine-tuning options in LyX? Specifically, did you
1831  
1832 \emph on
1833 misuse
1834 \emph default
1835  any of them, like trying to manually insert lots of 
1836 \family sans
1837 Protected\InsetSpace ~
1838 Blank
1839 \family default
1840 s, 
1841 \family sans
1842 Linebreak
1843 \family default
1844 s, or 
1845 \family sans
1846 Pagebreak
1847 \family default
1848 s? Did you try to kludge something together with these instead of using
1849  the appropriate paragraph environment?
1850 \end_layout
1851
1852 \begin_layout Enumerate
1853 All right, you didn't use any of the fine-tuning options, you played by
1854  the rules.
1855  Did you try to pull a fancy maneuver? Did you do something funky inside
1856  a table or an equation, like inserting a graphic into a table cell?
1857 \end_layout
1858
1859 \begin_layout Enumerate
1860 Do you have long sections of text where LaTeX cannot find a place to break
1861  a line? By default, LaTeX is rather strict about how much extra inter-word
1862  spacing it will add in order to break a line.
1863  Preferably, you should rework the paragraph to avoid the problem.
1864  If this isn't an option, you can wrap your text in 
1865 \family typewriter
1866
1867 \backslash
1868 sloppypar
1869 \family default
1870  to make LaTeX's line breaking more, well, sloppy.
1871 \end_layout
1872
1873 \begin_layout Enumerate
1874 Did you go overboard with the nesting? LyX (currently) doesn't check to
1875  make sure you're in the limits for nesting environments.
1876  If you nested a bunch of environments to the 
1877 \begin_inset Formula $17^{\mathrm{th}}$
1878 \end_inset
1879
1880  level, that's the problem.
1881 \end_layout
1882
1883 \begin_layout Enumerate
1884 Okay, you didn't get any error messages, but your output looks whacked.
1885  If you have a table or figure that's too wide or long for the page, you
1886  need to:
1887 \end_layout
1888
1889 \begin_deeper
1890 \begin_layout Enumerate
1891 rescale the figure so it fits.
1892 \end_layout
1893
1894 \begin_layout Enumerate
1895 trim down the table so it fits.
1896 \end_layout
1897
1898 \begin_layout Standard
1899 If something else is wrong with the output, and you didn't try to pull anything
1900  fancy or kludge the fine-tuning options, we're not sure what's wrong.
1901 \end_layout
1902
1903 \end_deeper
1904 \begin_layout Standard
1905 If all this doesn't help --- well, then 
1906 \emph on
1907 perhaps
1908 \emph default
1909  you might have found a bug in LyX\SpecialChar \ldots{}
1910
1911 \end_layout
1912
1913 \begin_layout Chapter
1914 Supplemental Tools
1915 \end_layout
1916
1917 \begin_layout Section
1918 Preparing a Bibliography with BibTeX
1919 \begin_inset LatexCommand \label{sec:Preparing-a-Bibliography}
1920
1921 \end_inset
1922
1923
1924 \end_layout
1925
1926 \begin_layout Standard
1927 by 
1928 \noun on
1929 Mike Ressler
1930 \noun default
1931  and 
1932 \noun on
1933 Jürgen Spitzmüller
1934 \end_layout
1935
1936 \begin_layout Standard
1937 \begin_inset VSpace bigskip
1938 \end_inset
1939
1940
1941 \end_layout
1942
1943 \begin_layout Standard
1944 \noindent
1945 STOP! If you don't know what BibTeX is, or have a reasonably good idea of
1946  how to use it (
1947 \emph on
1948 e.g.
1949
1950 \emph default
1951  setting up your own bibliographic databases), 
1952 \emph on
1953 run
1954 \emph default
1955 , do not walk, to your nearest copy of the 2nd edition of Lamport's 
1956 \emph on
1957 LaTeX: A Document Preparation System
1958 \emph default
1959 , particularly Appendix B.
1960  The rest of this discussion assumes you have created a correct bibliography
1961  file, that you have all relevant environment variables set correctly (esp.
1962  
1963 \family typewriter
1964 BIBINPUTS
1965 \family default
1966
1967 \family typewriter
1968 BSTINPUTS
1969 \family default
1970 , and 
1971 \family typewriter
1972 TEXINPUTS
1973 \family default
1974 ), and that if sufficiently desperate, you could create and 
1975 \begin_inset Quotes eld
1976 \end_inset
1977
1978 TeX
1979 \begin_inset Quotes erd
1980 \end_inset
1981
1982  a LaTeX file with a BibTeX database.
1983  
1984 \end_layout
1985
1986 \begin_layout Standard
1987 For those who don't know what BibTeX is, it is a system for creating a large
1988  database of your most used journal references.
1989  For all future articles you write, you only need to include this standard
1990  database and reference the appropriate key to each reference.
1991  Even if you write only a few papers with handful of references each, it
1992  is well worth your time to examine BibTeX and decide whether it will be
1993  useful to you.
1994 \end_layout
1995
1996 \begin_layout Standard
1997 To use BibTeX with LyX, first read the 
1998 \emph on
1999 User Guide
2000 \emph default
2001  where it describes how to insert citations.
2002  The basic mechanism for inserting BibTeX references is the same.
2003  Then, at the very end of your document, select 
2004 \family sans
2005 Insert\SpecialChar \menuseparator
2006 List
2007 \family default
2008  / 
2009 \family sans
2010 TOC\SpecialChar \menuseparator
2011 BibTeX Reference
2012 \family default
2013 .
2014  In the resulting dialog, fill out the dialog boxes as follows: 
2015 \end_layout
2016
2017 \begin_layout Description
2018 Database: enter the name of your 
2019 \family typewriter
2020 .bib
2021 \family default
2022  file 
2023 \emph on
2024 without
2025 \emph default
2026  the 
2027 \family typewriter
2028 .bib
2029 \family default
2030  extension.
2031  For searching multiple 
2032 \family typewriter
2033 .bib
2034 \family default
2035  files, just enter them in the desired order, separated by commas.
2036  
2037 \end_layout
2038
2039 \begin_layout Description
2040 Style: enter the name of your BibTeX style file *without* the 
2041 \family typewriter
2042 .bst
2043 \family default
2044  extension.
2045  The default style is 
2046 \family typewriter
2047 plain
2048 \family default
2049  (which should be included in your LaTeX distribution, so you don't have
2050  to worry about creating it).
2051 \end_layout
2052
2053 \begin_layout Standard
2054 For each citation, assuming that the source is in the 
2055 \family typewriter
2056 .bib
2057 \family default
2058  file, just call 
2059 \family sans
2060 \bar under
2061 I
2062 \bar default
2063 nsert\SpecialChar \menuseparator
2064
2065 \bar under
2066 C
2067 \bar default
2068 itation Reference
2069 \family default
2070  at the correct location in the text, and enter the appropriate reference
2071  key.
2072  Nothing else is required; when invoking 
2073 \family sans
2074 \bar under
2075 V
2076 \bar default
2077 iew\SpecialChar \menuseparator
2078
2079 \bar under
2080 D
2081 \bar default
2082 VI
2083 \family default
2084 , for example, you should see that BibTeX and LaTeX are invoked as needed,
2085  including multiple invocations of LaTeX.
2086  
2087 \end_layout
2088
2089 \begin_layout Subsection
2090 Alternative Citation Styles
2091 \end_layout
2092
2093 \begin_layout Standard
2094 Standard BibTeX uses numbers (e.\InsetSpace \thinspace{}
2095 g.\InsetSpace \space{}
2096
2097 \begin_inset Quotes eld
2098 \end_inset
2099
2100 [12]
2101 \begin_inset Quotes erd
2102 \end_inset
2103
2104 ) to refer to a cited work.
2105  However, in many scientific disciplines, other citation styles are in use.
2106  The most common one is the author-year style (e.\InsetSpace \thinspace{}
2107 g.\InsetSpace \space{}
2108
2109 \begin_inset Quotes eld
2110 \end_inset
2111
2112 Knuth 1984a
2113 \begin_inset Quotes erd
2114 \end_inset
2115
2116 ).
2117  LyX supports two packages that provide this style, 
2118 \family typewriter
2119 natbib
2120 \family default
2121  and 
2122 \family typewriter
2123 jurabib
2124 \family default
2125 .
2126  Both packages have their own pros and cons, which cannot be listed in detail.
2127  If you only want to have simple author-year (or author-numerical) style
2128  or if you want to use one of the countless style files for natbib, than
2129  the established 
2130 \family typewriter
2131 natbib
2132 \family default
2133  package is probably your choice.
2134  If you need special features like short title references, ibidem etc., you
2135  might consider the fairly new 
2136 \family typewriter
2137 jurabib
2138 \family default
2139  package.
2140 \end_layout
2141
2142 \begin_layout Standard
2143 The handling of both packages in LyX is basically the same.
2144  Go to 
2145 \family sans
2146 \bar under
2147 D
2148 \bar default
2149 ocument\SpecialChar \menuseparator
2150
2151 \bar under
2152 S
2153 \bar default
2154 ettings 
2155 \family default
2156 and select the 
2157 \family sans
2158 Bibliography
2159 \family default
2160  pane (with the xforms frontend: the 
2161 \family sans
2162 Extras
2163 \family default
2164  tab).
2165  Then select 
2166 \family sans
2167 Natbib
2168 \family default
2169  or 
2170 \family sans
2171 Jurabib
2172 \family default
2173 .
2174  With both packages, you will get some extra features in the citation dialog
2175  and you can select the style of the reference (
2176 \begin_inset Quotes eld
2177 \end_inset
2178
2179 Knuth 1984
2180 \begin_inset Quotes erd
2181 \end_inset
2182
2183
2184 \begin_inset Quotes eld
2185 \end_inset
2186
2187 Knuth (1984)
2188 \begin_inset Quotes erd
2189 \end_inset
2190
2191
2192 \begin_inset Quotes eld
2193 \end_inset
2194
2195 Knuth, 1984
2196 \begin_inset Quotes erd
2197 \end_inset
2198
2199
2200 \begin_inset Quotes eld
2201 \end_inset
2202
2203 1984
2204 \begin_inset Quotes erd
2205 \end_inset
2206
2207  etc.).
2208  Note that both packages need specifically designed style files (they both
2209  ship their own, while there are lots of additional style files and even
2210  an interactive style file builder
2211 \begin_inset Foot
2212 status collapsed
2213
2214 \begin_layout Standard
2215 See 
2216 \begin_inset LatexCommand \url{ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/}
2217
2218 \end_inset
2219
2220
2221 \end_layout
2222
2223 \end_inset
2224
2225  for 
2226 \family typewriter
2227 natbib
2228 \family default
2229  available).
2230 \end_layout
2231
2232 \begin_layout Subsection
2233 Sectionated Bibliographies
2234 \begin_inset LatexCommand \label{sub:Sectionated-Bibliographies}
2235
2236 \end_inset
2237
2238
2239 \end_layout
2240
2241 \begin_layout Standard
2242 Sometimes you might need to divide your bibliography into several sections.
2243  If you are, for instance, a historian, the possibility to separate sources
2244  and scientific works is most likely a 
2245 \begin_inset Quotes eld
2246 \end_inset
2247
2248 must have
2249 \begin_inset Quotes erd
2250 \end_inset
2251
2252 .
2253  Unfortunately, BibTeX itself does not allow you to do this.
2254  The good news is, though: With the help of some LaTeX packages, BibTeX
2255  can be extended to fit your historical needs.
2256 \end_layout
2257
2258 \begin_layout Standard
2259 As of version 1.4, LyX provides native support for one of these packages,
2260  Stefan Ulrich's 
2261 \family typewriter
2262 bibtopic
2263 \family default
2264 .
2265 \begin_inset Foot
2266 status collapsed
2267
2268 \begin_layout Standard
2269 Available from 
2270 \begin_inset LatexCommand \url{ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/}
2271
2272 \end_inset
2273
2274
2275 \end_layout
2276
2277 \end_inset
2278
2279  The advantage of this package (compared to other packages like 
2280 \family typewriter
2281 multibib
2282 \family default
2283 ) is that you don't need to define new citation commands.
2284  Instead, you need to prepare different bibliographic databases which include
2285  the entries for the different sections of the bibliography.
2286  For example: If you want to divide your bibliography into the sections
2287  
2288 \begin_inset Quotes eld
2289 \end_inset
2290
2291 Sources
2292 \begin_inset Quotes erd
2293 \end_inset
2294
2295  and 
2296 \begin_inset Quotes eld
2297 \end_inset
2298
2299 Scientific works
2300 \begin_inset Quotes erd
2301 \end_inset
2302
2303 , you first need to create two bibliographic databases, e.\InsetSpace \thinspace{}
2304 g.\InsetSpace \space{}
2305
2306 \family typewriter
2307 sources.bib
2308 \family default
2309  and 
2310 \family typewriter
2311 scientific.bib
2312 \family default
2313 .
2314  
2315 \end_layout
2316
2317 \begin_layout Standard
2318 In LyX, go to 
2319 \family sans
2320 \bar under
2321 D
2322 \bar default
2323 ocument\SpecialChar \menuseparator
2324
2325 \bar under
2326 S
2327 \bar default
2328 ettings 
2329 \family default
2330 and select the 
2331 \family sans
2332 Bibliography
2333 \family default
2334  pane (with the xforms frontend: the 
2335 \family sans
2336 Extras
2337 \family default
2338  tab).
2339  Check 
2340 \family sans
2341 Sectionated\InsetSpace ~
2342 bibliography
2343 \family default
2344 .
2345  Now you can insert multiple BibTeX references (as described in section\InsetSpace ~
2346
2347 \begin_inset LatexCommand \ref{sec:Preparing-a-Bibliography}
2348
2349 \end_inset
2350
2351 ), one for each section of your bibliography.
2352  Returning to our example: Insert a BibTeX reference for the database 
2353 \family typewriter
2354 sources.bib
2355 \family default
2356  and a second one for the database 
2357 \family typewriter
2358 scientific.bib
2359 \family default
2360 .
2361  You are free to use the same or different styles for each section.
2362  Additionally, you can chose if the bibliography section should contain
2363  
2364 \begin_inset Quotes eld
2365 \end_inset
2366
2367 all cited references
2368 \begin_inset Quotes erd
2369 \end_inset
2370
2371  of the specified database(s) (which is the default), 
2372 \begin_inset Quotes eld
2373 \end_inset
2374
2375 all uncited references
2376 \begin_inset Quotes erd
2377 \end_inset
2378
2379  or even 
2380 \begin_inset Quotes eld
2381 \end_inset
2382
2383 all references
2384 \begin_inset Quotes erd
2385 \end_inset
2386
2387 .
2388  This might be useful if you would like to separate your bibliography into
2389  three sections: 
2390 \begin_inset Quotes eld
2391 \end_inset
2392
2393 Cited sources
2394 \begin_inset Quotes erd
2395 \end_inset
2396
2397
2398 \begin_inset Quotes eld
2399 \end_inset
2400
2401 Uncited sources
2402 \begin_inset Quotes erd
2403 \end_inset
2404
2405 , and 
2406 \begin_inset Quotes eld
2407 \end_inset
2408
2409 Scientific works
2410 \begin_inset Quotes erd
2411 \end_inset
2412
2413 .
2414  The titles for the sections can be added as ordinary sections or subsections.
2415  Since 
2416 \family typewriter
2417 bibtopic
2418 \family default
2419  removes the bibliography title, you have manually re-add that, too (as
2420  a chapter* or section*, for instance).
2421 \end_layout
2422
2423 \begin_layout Subsection
2424 Multiple Bibliographies
2425 \end_layout
2426
2427 \begin_layout Standard
2428 Multiple bibliographies, e.\InsetSpace \thinspace{}
2429 g.\InsetSpace \space{}
2430 a bibliography for each section or chapter of
2431  the document, are not supported by BibTeX itself.
2432  But the 
2433 \family typewriter
2434 bibtopic
2435 \family default
2436  package, which is used for the creation of sectionated bibliographies in
2437  LyX (cf.\InsetSpace ~
2438 section\InsetSpace ~
2439
2440 \begin_inset LatexCommand \ref{sub:Sectionated-Bibliographies}
2441
2442 \end_inset
2443
2444 ), provides an easy way to solve this task, if you are willing to use some
2445  LaTeX-Code (ERT, cf.\InsetSpace ~
2446 section\InsetSpace ~
2447
2448 \begin_inset LatexCommand \ref{sec:Inserting-LaTeX-Code}
2449
2450 \end_inset
2451
2452 ).
2453 \begin_inset Foot
2454 status collapsed
2455
2456 \begin_layout Standard
2457 An alternative approach is to use the 
2458 \family typewriter
2459 chapterbib
2460 \family default
2461  or 
2462 \family typewriter
2463 bibunits
2464 \family default
2465  package, respectively.
2466 \end_layout
2467
2468 \end_inset
2469
2470
2471 \end_layout
2472
2473 \begin_layout Standard
2474 First, go to 
2475 \family sans
2476 \bar under
2477 D
2478 \bar default
2479 ocument\SpecialChar \menuseparator
2480
2481 \bar under
2482 S
2483 \bar default
2484 ettings 
2485 \family default
2486 and select the 
2487 \family sans
2488 Bibliography
2489 \family default
2490  pane (with the xforms frontend: the 
2491 \family sans
2492 Extras
2493 \family default
2494  tab).
2495  Check 
2496 \family sans
2497 Sectionated\InsetSpace ~
2498 bibliography
2499 \family default
2500 .
2501  In the document, you have to enclose the sections, which shall contain
2502  their own bibliography (including the BibTeX reference itself), between
2503  
2504 \family typewriter
2505
2506 \backslash
2507 begin{btUnit}
2508 \family default
2509  and 
2510 \family typewriter
2511
2512 \backslash
2513 end{btUnit}
2514 \family default
2515  (those commands have to be inserted as ERT).
2516  The bibliography will contain all references which have been cited in the
2517  current btUnit.
2518  N.\InsetSpace \thinspace{}
2519 B.: If you are using this approach, then 
2520 \emph on
2521 every
2522 \emph default
2523  citation reference has to be inside some btUnit.
2524  Also, the btUnits cannot be nested.
2525 \end_layout
2526
2527 \begin_layout Section
2528 Making an Index
2529 \end_layout
2530
2531 \begin_layout Standard
2532 A good index is one of the hardest things to make in a lengthy document,
2533  but LyX helps make things a bit simpler by interfacing to the 
2534 \family typewriter
2535 makeindex
2536 \family default
2537  program which is found in most recent LaTeX distributions.
2538 \begin_inset Foot
2539 status collapsed
2540
2541 \begin_layout Standard
2542
2543 \family roman
2544 \series medium
2545 \shape up
2546 \size normal
2547 \emph off
2548 \bar no
2549 \noun off
2550 \color none
2551 In the 
2552 \family sans
2553 \series default
2554 \shape default
2555 \size default
2556 \emph default
2557 \bar default
2558 \noun default
2559 Outputs\SpecialChar \menuseparator
2560 LaT\SpecialChar \textcompwordmark{}
2561 eX
2562 \family roman
2563 \series medium
2564 \shape up
2565 \size normal
2566 \emph off
2567 \bar no
2568 \noun off
2569  section of the preferences dialog, however, you can customize the index
2570  command, if you prefer an alternative program like 
2571 \family typewriter
2572 \series default
2573 \shape default
2574 \size default
2575 \emph default
2576 \bar default
2577 \noun default
2578 xindy
2579 \family roman
2580 \series medium
2581 \shape up
2582 \size normal
2583 \emph off
2584 \bar no
2585 \noun off
2586 .
2587 \end_layout
2588
2589 \end_inset
2590
2591  Inserting an index and marking words to include in it works much the same
2592  way as preparing a bibliography as mentioned in the last section.
2593 \end_layout
2594
2595 \begin_layout Standard
2596 First, go to the end of your file and select 
2597 \family sans
2598 \bar under
2599 I
2600 \bar default
2601 nsert\SpecialChar \menuseparator
2602 List
2603 \family default
2604 \InsetSpace ~
2605 /\InsetSpace ~
2606
2607 \family sans
2608 T
2609 \bar under
2610 O
2611 \bar default
2612 C\SpecialChar \menuseparator
2613
2614 \bar under
2615 I
2616 \bar default
2617 ndex
2618 \family default
2619 \InsetSpace ~
2620
2621 \family sans
2622 List
2623 \family default
2624 .
2625  Then, for each word you would like to include in the index, go to the end
2626  of that word and click on 
2627 \family sans
2628 \bar under
2629 I
2630 \bar default
2631 nsert\SpecialChar \menuseparator
2632
2633 \bar under
2634 I
2635 \bar default
2636 ndex
2637 \family default
2638 \InsetSpace ~
2639
2640 \family sans
2641 Entry
2642 \family default
2643 .
2644  This will insert a tag showing the word as it will appear in the index.
2645  That's all there is to it; LyX will automatically call 
2646 \family typewriter
2647 makeindex
2648 \family default
2649  for you and create the index itself.
2650  The text in the dialog available from right-clicking on the index button
2651  accepts LaTeX, so you'll need to be careful to avoid using any special
2652  characters.
2653  On the positive side, you can use the advanced options - have a look at
2654  the documentation which comes with your LaTeX distribution to find out
2655  how to do things like 
2656 \begin_inset Quotes eld
2657 \end_inset
2658
2659 nested entries
2660 \begin_inset Quotes erd
2661 \end_inset
2662
2663 , etc.
2664 \end_layout
2665
2666 \begin_layout Standard
2667 Be careful not to put spaces between the word in the text and the index
2668  marker; apparently the wrong page number can be produced if this happens.
2669 \end_layout
2670
2671 \begin_layout Section
2672 Glossaries
2673 \end_layout
2674
2675 \begin_layout Standard
2676 by 
2677 \noun on
2678 Özgür U\i \~{g}
2679 ra\i \c{s}
2680  Baran
2681 \end_layout
2682
2683 \begin_layout Standard
2684 Sometimes you need to compile a list of symbols that are mentioned in your
2685  document with a brief explanation of them.
2686  A LaTeX package named 
2687 \family typewriter
2688 nomencl
2689 \family default
2690  provides an easy way of compiling such lists.
2691  
2692 \family typewriter
2693 nomencl
2694 \family default
2695  is included in most standard Linux distributions.
2696  If your distribution doesn't contain it, you should download it from a
2697  CTAN mirror and install the package in order to use this feature of LyX.
2698 \end_layout
2699
2700 \begin_layout Standard
2701 A glossary entry is created if you place the cursor after a symbol entry
2702  and then use the menu 
2703 \family sans
2704 Insert\SpecialChar \menuseparator
2705 Glossary\InsetSpace ~
2706 Entry
2707 \family default
2708 .
2709  A gray box labeled 
2710 \begin_inset Quotes eld
2711 \end_inset
2712
2713
2714 \family sans
2715 Not
2716 \family default
2717
2718 \begin_inset Quotes erd
2719 \end_inset
2720
2721  is inserted and a window pops up asking for the glossary entry.
2722  A glossary entry consists of two main entries.
2723  The first is the symbol that you want to refer to.
2724  You should enter a valid LaTeX code for the corresponding field in the
2725  glossary dialog.
2726  The second is the description of the symbol.
2727  You should fill the corresponding field to complete the glossary entry.
2728 \end_layout
2729
2730 \begin_layout Subsection
2731 Sort Order of Glossary Entries
2732 \end_layout
2733
2734 \begin_layout Standard
2735 Suppose you have two glossary entries for the symbols 
2736 \begin_inset Formula $a$
2737 \end_inset
2738
2739  and 
2740 \begin_inset Formula $\sigma$
2741 \end_inset
2742
2743 .
2744  The 
2745 \family typewriter
2746 nomencl
2747 \family default
2748  package automatically sorts these two entries considering the symbol entry,
2749  while printing the Glossary.
2750  However, this can lead to an undesired sort order.
2751  For the example given, the first entry appears as 
2752 \family typewriter
2753 $a$
2754 \family default
2755 , while the second is 
2756 \family typewriter
2757 $
2758 \backslash
2759 sigma$
2760 \family default
2761 .
2762  Note that, in this case 
2763 \begin_inset Formula $\sigma$
2764 \end_inset
2765
2766  is located in front of the 
2767 \begin_inset Formula $a$
2768 \end_inset
2769
2770 , since the character 
2771 \begin_inset Quotes eld
2772 \end_inset
2773
2774
2775 \backslash
2776
2777 \begin_inset Quotes erd
2778 \end_inset
2779
2780  is considered in sorting.
2781  In order to control the sort order, you can edit the 
2782 \family sans
2783 Sort\InsetSpace ~
2784 as
2785 \family default
2786  field of the glossary dialog.
2787  For the given example, you can edit this field as 
2788 \family typewriter
2789 a
2790 \family default
2791  and 
2792 \family typewriter
2793 sigma 
2794 \family default
2795 correspondingly.
2796  Then, these entries will be effective in the sort ordering and 
2797 \begin_inset Formula $a$
2798 \end_inset
2799
2800  will be located before 
2801 \begin_inset Formula $\sigma$
2802 \end_inset
2803
2804 .
2805 \end_layout
2806
2807 \begin_layout Standard
2808 This feature provides exciting ways of ordering the entries.
2809  For subgrouping and tips for using sort entries see the official nomencl
2810  documentation.
2811 \end_layout
2812
2813 \begin_layout Subsection
2814 Referencing
2815 \end_layout
2816
2817 \begin_layout Standard
2818 You can turn on referencing to the equations and pages in the glossary entries.
2819  For this purpose, you should add referencing options commands at the end
2820  of description field.
2821  There are six referencing options in nomencl package:
2822 \end_layout
2823
2824 \begin_layout Paragraph*
2825
2826 \backslash
2827 refeq:
2828 \end_layout
2829
2830 \begin_layout Standard
2831 Adds reference to the equation by adding the phrase 
2832 \begin_inset Quotes eld
2833 \end_inset
2834
2835 , see equation (#)
2836 \begin_inset Quotes erd
2837 \end_inset
2838
2839
2840 \end_layout
2841
2842 \begin_layout Paragraph*
2843
2844 \backslash
2845 refpage:
2846 \end_layout
2847
2848 \begin_layout Standard
2849 Adds reference to the page by adding the phrase 
2850 \begin_inset Quotes eld
2851 \end_inset
2852
2853 , page (#)
2854 \begin_inset Quotes erd
2855 \end_inset
2856
2857
2858 \end_layout
2859
2860 \begin_layout Paragraph*
2861
2862 \backslash
2863 refeqpage:
2864 \end_layout
2865
2866 \begin_layout Standard
2867 Is the short notation of 
2868 \backslash
2869 refeq
2870 \backslash
2871 refpage.
2872 \end_layout
2873
2874 \begin_layout Paragraph*
2875
2876 \backslash
2877 norefeq, 
2878 \backslash
2879 norefpag, 
2880 \backslash
2881 norefeqpage:
2882 \end_layout
2883
2884 \begin_layout Standard
2885 Turns off corresponding referencing options if they are turned on globally
2886  (see reference documentation of nomencl).
2887 \end_layout
2888
2889 \begin_layout Subsection
2890 Printing Glossary
2891 \end_layout
2892
2893 \begin_layout Standard
2894 You can insert the glossary with the menu 
2895 \family sans
2896 Insert\SpecialChar \menuseparator
2897 Lists\InsetSpace ~
2898 &TOC\SpecialChar \menuseparator
2899 Glossary
2900 \family default
2901 .
2902  A light blue box labeled 
2903 \begin_inset Quotes eld
2904 \end_inset
2905
2906
2907 \family sans
2908 Glossary
2909 \family default
2910
2911 \begin_inset Quotes erd
2912 \end_inset
2913
2914  will show the place where the index is printed in the output.
2915  The index list box is not clickable like other LyX-boxes.
2916  In the printed output the title of the glossary appears as 
2917 \series bold
2918 Nomenclature
2919 \series default
2920
2921 \begin_inset Foot
2922 status collapsed
2923
2924 \begin_layout Standard
2925 This is translated to the document language for a small number of languages,
2926  amongst others French and German
2927 \end_layout
2928
2929 \end_inset
2930
2931 .
2932  If you are not happy with the title, you can change it by re-defining the
2933  command 
2934 \family typewriter
2935
2936 \backslash
2937 nomname
2938 \family default
2939  in the preamble.
2940  For example, in order to change the title 
2941 \emph on
2942 List of Symbols
2943 \emph default
2944  for the 
2945 \emph on
2946 Glossary
2947 \emph default
2948  add the following line to the preamble.
2949 \end_layout
2950
2951 \begin_layout LyX-Code
2952
2953 \backslash
2954 renewcommand{
2955 \backslash
2956 nomname}{List of Symbols}
2957 \end_layout
2958
2959 \begin_layout Standard
2960  If you're unhappy with the amount of space for symbols, you can alter it
2961  by adding following line to the preamble.
2962 \end_layout
2963
2964 \begin_layout LyX-Code
2965
2966 \backslash
2967 renewcommand{
2968 \backslash
2969 nomlabelwidth}{3.0cm}
2970 \end_layout
2971
2972 \begin_layout Standard
2973
2974 \end_layout
2975
2976 \begin_layout Section
2977 Multipart Documents
2978 \end_layout
2979
2980 \begin_layout Subsection
2981 General Operation
2982 \end_layout
2983
2984 \begin_layout Standard
2985 When you are working on a large file with many sections, it is often convenient
2986  to break up the document into several files, or perhaps you have something
2987  where a table may change from time to time, but the preceding text does
2988  not.
2989  In these cases, you should seriously consider using multipart documents.
2990  For example, scientific papers often have five major sections: the introduction
2991 , observations, results, discussion, and conclusion.
2992  Each of these could be its own separate LyX file, with one 
2993 \begin_inset Quotes eld
2994 \end_inset
2995
2996 master
2997 \begin_inset Quotes erd
2998 \end_inset
2999
3000  file which contains the title, authors, abstract, references, etc., plus
3001  the five included files.
3002  It is important to note that each of these files is a full LyX file which
3003  can be formatted and printed on its own, as well as included in a master
3004  file.
3005  Each of these files must have the same document class, however--- don't
3006  attempt to mix book classes with article classes.
3007  You may also include LaTeX files; however, these files must not have their
3008  own preamble 
3009 \emph on
3010 (i.e.
3011
3012 \emph default
3013  everything up to and including the 
3014 \family typewriter
3015
3016 \backslash
3017 begin{document}
3018 \family default
3019  line as well as the 
3020 \family typewriter
3021
3022 \backslash
3023 end{document}
3024 \family default
3025  line must be deleted) or else errors will be generated when you try to
3026  make a DVI file.
3027 \end_layout
3028
3029 \begin_layout Standard
3030 LyX allows you to include files quite easily with 
3031 \family sans
3032 \bar under
3033 I
3034 \bar default
3035 nsert\SpecialChar \menuseparator
3036 ChiI
3037 \bar under
3038 d
3039 \bar default
3040 \InsetSpace ~
3041 Document
3042 \family default
3043 .
3044  When you click on this selection a small box is inserted into the file
3045  at the current cursor location.
3046  Clicking on the box raises a dialog which allows you to select the file
3047  to be included, and the method of its inclusion.
3048  
3049 \end_layout
3050
3051 \begin_layout Standard
3052 The file selection box should by now be obvious.
3053  The three inclusion methods are 
3054 \begin_inset Quotes eld
3055 \end_inset
3056
3057 include
3058 \begin_inset Quotes erd
3059 \end_inset
3060
3061
3062 \begin_inset Quotes eld
3063 \end_inset
3064
3065 input
3066 \begin_inset Quotes erd
3067 \end_inset
3068
3069 , and 
3070 \begin_inset Quotes eld
3071 \end_inset
3072
3073 verbatim
3074 \begin_inset Quotes erd
3075 \end_inset
3076
3077 .
3078  The difference between 
3079 \begin_inset Quotes eld
3080 \end_inset
3081
3082 include
3083 \begin_inset Quotes erd
3084 \end_inset
3085
3086  and 
3087 \begin_inset Quotes eld
3088 \end_inset
3089
3090 input
3091 \begin_inset Quotes erd
3092 \end_inset
3093
3094  is really only meaningful to LaTeXperts, but the practical difference is
3095  that files which are 
3096 \begin_inset Quotes eld
3097 \end_inset
3098
3099 included
3100 \begin_inset Quotes erd
3101 \end_inset
3102
3103  are typeset beginning on a new page, while files which are 
3104 \begin_inset Quotes eld
3105 \end_inset
3106
3107 inputted
3108 \begin_inset Quotes erd
3109 \end_inset
3110
3111  are typeset starting on the current page.
3112  Perhaps the labeling in LyX will be changed someday to reflect this.
3113 \end_layout
3114
3115 \begin_layout Standard
3116 Generally, the master file is converted into a full LaTeX file before typesettin
3117 g, while the included files are converted to LaTeX files which do not have
3118  all the preamble information.
3119  Checking the 
3120 \family sans
3121 Don't
3122 \family default
3123 \InsetSpace ~
3124
3125 \family sans
3126 typeset
3127 \family default
3128  button prevents this conversion.
3129 \end_layout
3130
3131 \begin_layout Standard
3132
3133 \begin_inset Quotes eld
3134 \end_inset
3135
3136 verbatim
3137 \begin_inset Quotes erd
3138 \end_inset
3139
3140  included file allows you to include a file typeset exactly as it appears
3141  in the file, i.e.\InsetSpace ~
3142 verbatim mode, with the characters set in a fixed-width
3143  typewriter font.
3144  Normally, spaces in this file are invisible, though two consecutive spaces
3145  are conserved, unlike LyX's normal treatment of spaces.
3146  However, setting the 
3147 \family sans
3148 \bar under
3149 M
3150 \bar default
3151 ark\InsetSpace ~
3152 spaces\InsetSpace ~
3153 in\InsetSpace ~
3154 output
3155 \family default
3156  checkbox typesets a mark to unambiguously define the presence of a space.
3157
3158 \emph on
3159  
3160 \end_layout
3161
3162 \begin_layout Subsection
3163 Cross-References Between Files
3164 \end_layout
3165
3166 \begin_layout Standard
3167 It is possible to set up cross-references between the different files.
3168  First, open all the files in question: let's call them A and B in a two
3169  file example, where B is included in A.
3170  Let's say you insert a label in A, then want to reference it in B.
3171  Open the cross-reference dialog in whilst in document B, and you can select
3172  the 
3173 \begin_inset Quotes eld
3174 \end_inset
3175
3176 buffer
3177 \begin_inset Quotes erd
3178 \end_inset
3179
3180  to use.
3181 \end_layout
3182
3183 \begin_layout Section
3184 Algorithms
3185 \end_layout
3186
3187 \begin_layout Standard
3188 The package 
3189 \family sans
3190 algorithm
3191 \family default
3192  is needed by LyX to be able to output algorithm floats.
3193  These are useful in placing short algorithms across page breaks and support
3194  an index of algorithms too.
3195 \end_layout
3196
3197 \begin_layout Section
3198 Subfigures
3199 \end_layout
3200
3201 \begin_layout Standard
3202 The package
3203 \family sans
3204  subfigure 
3205 \family default
3206 is used by LyX when you select ``subfigure'' in the graphics dialog and
3207  enter the subfigure caption.
3208  Several figures marked in this way can be packed into a single float with
3209  individual sub-captions.
3210 \end_layout
3211
3212 \begin_layout Section
3213 Fancy Headers and Footers
3214 \end_layout
3215
3216 \begin_layout Standard
3217 The default page layout is rather plain; for an article document class,
3218  all you get is a centered page number at the bottom of the page.
3219  This document is the book class, so it appears to be a bit fancier, but
3220  to really put on a show, you need to set the document page style to 
3221 \begin_inset Quotes eld
3222 \end_inset
3223
3224 fancy
3225 \begin_inset Quotes erd
3226 \end_inset
3227
3228 , as mentioned in the 
3229 \family sans
3230 User\InsetSpace ~
3231 Guide
3232 \family default
3233 .
3234  This section describes the LaTeX codes you need to insert in your LaTeX
3235  preamble or the text in order to get the desired effects.
3236 \end_layout
3237
3238 \begin_layout Standard
3239 The page header is divided into three fields, not surprisingly labeled 
3240 \begin_inset Quotes eld
3241 \end_inset
3242
3243 left
3244 \begin_inset Quotes erd
3245 \end_inset
3246
3247
3248 \begin_inset Quotes eld
3249 \end_inset
3250
3251 center
3252 \begin_inset Quotes erd
3253 \end_inset
3254
3255 , and 
3256 \begin_inset Quotes eld
3257 \end_inset
3258
3259 right
3260 \begin_inset Quotes erd
3261 \end_inset
3262
3263 .
3264  The footer is also divided into these three fields.
3265  The LaTeX commands to set these fields in the simplest manner are 
3266 \family typewriter
3267
3268 \backslash
3269 lhead
3270 \family default
3271
3272 \family typewriter
3273
3274 \backslash
3275 chead
3276 \family default
3277
3278 \family typewriter
3279
3280 \backslash
3281 rhead
3282 \family default
3283
3284 \family typewriter
3285
3286 \backslash
3287 lfoot
3288 \family default
3289 , etc.
3290  Suppose you wish to put your name in the upper left hand corner of each
3291  page.
3292  Simply insert the following command in the preamble: 
3293 \end_layout
3294
3295 \begin_layout Standard
3296
3297 \family typewriter
3298
3299 \backslash
3300 lhead{John Q.
3301  DocWriter}
3302 \end_layout
3303
3304 \begin_layout Standard
3305 You will now see your name in the upper left.
3306  If a field has a default entry that you would like to get rid of (often
3307  the page number appears in the central footer, simply include a command
3308  with a blank argument, e.g.
3309 \end_layout
3310
3311 \begin_layout Standard
3312
3313 \family typewriter
3314
3315 \backslash
3316 cfoot{}
3317 \end_layout
3318
3319 \begin_layout Standard
3320 Let's get really fancy: lets put the section number with the word 
3321 \begin_inset Quotes eld
3322 \end_inset
3323
3324 Section
3325 \begin_inset Quotes erd
3326 \end_inset
3327
3328  (e.g.
3329  Section 3) in the upper left, the page number (e.g.
3330  Page 4) in the upper right, your name in the lower left, and the date in
3331  the lower right.
3332  The following commands should now appear in the preamble:
3333 \end_layout
3334
3335 \begin_layout Standard
3336
3337 \family typewriter
3338
3339 \backslash
3340 lhead{Section 
3341 \backslash
3342 thesection}
3343 \end_layout
3344
3345 \begin_layout Standard
3346
3347 \family typewriter
3348
3349 \backslash
3350 chead{}
3351 \end_layout
3352
3353 \begin_layout Standard
3354
3355 \family typewriter
3356
3357 \backslash
3358 rhead{Page 
3359 \backslash
3360 thepage}
3361 \end_layout
3362
3363 \begin_layout Standard
3364
3365 \family typewriter
3366
3367 \backslash
3368 lfoot{John Q.
3369  DocWriter}
3370 \end_layout
3371
3372 \begin_layout Standard
3373
3374 \family typewriter
3375
3376 \backslash
3377 cfoot{}
3378 \end_layout
3379
3380 \begin_layout Standard
3381
3382 \family typewriter
3383
3384 \backslash
3385 rfoot{
3386 \backslash
3387 today}
3388 \end_layout
3389
3390 \begin_layout Standard
3391 The codes 
3392 \family typewriter
3393
3394 \backslash
3395 thesection
3396 \family default
3397  and 
3398 \family typewriter
3399
3400 \backslash
3401 thepage
3402 \family default
3403  access LaTeX's section and page counters, and so print out the current
3404  section and page numbers.
3405  
3406 \family typewriter
3407
3408 \backslash
3409 today
3410 \family default
3411  simply prints out today's date.
3412 \end_layout
3413
3414 \begin_layout Standard
3415 The thicknesses of the horizontal rules drawn beneath the header and above
3416  the footer can also be modified.
3417  If you don't want one of the headers, set its thickness to 0.
3418  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
3419  Use the commands, e.g.
3420  
3421 \family typewriter
3422
3423 \backslash
3424 renewcommand{
3425 \backslash
3426 headrulewidth}{0.4pt}
3427 \family default
3428  and 
3429 \family typewriter
3430
3431 \backslash
3432 renewcommand{
3433 \backslash
3434 footrulewidth}{0.4pt}
3435 \family default
3436  to set the thicknesses.
3437 \end_layout
3438
3439 \begin_layout Standard
3440 You can switch the header/footer settings on and off for individual pages
3441  using commands like 
3442 \family typewriter
3443
3444 \backslash
3445 thispagestyle{empty}
3446 \family default
3447
3448 \family typewriter
3449
3450 \backslash
3451 thispagestyle{plain}
3452 \family default
3453 , and 
3454 \family typewriter
3455
3456 \backslash
3457 thispagestyle{fancy}
3458 \family default
3459 .
3460  Simply insert them in the text on the page you want changed and mark them
3461  as TeX code.
3462  In fact, title pages are marked as plain by default, while following pages
3463  are marked fancy when using the global fancy setting.
3464 \end_layout
3465
3466 \begin_layout Standard
3467 There are more complex commands which will let you insert things in the
3468  upper left on odd numbered pages, etc., but I will refer you to the 
3469 \family typewriter
3470 fancyhdr
3471 \family default
3472  package documentation for more descriptions.
3473  For example, if you have a teTeX installation, look for 
3474 \family typewriter
3475 /usr/share/texmf/doc/latex/fancyhdr/\SpecialChar \-
3476 fancyhdr.dvi
3477 \family default
3478 .
3479 \end_layout
3480
3481 \begin_layout Standard
3482 As a final example, it is possible to include an Encapsulated PostScript®
3483  file in the header or footer.
3484  Suppose you want to put a company logo in the upper lefthand corner.
3485  You might try something like
3486 \end_layout
3487
3488 \begin_layout Standard
3489
3490 \family typewriter
3491
3492 \backslash
3493 lhead{
3494 \backslash
3495 resizebox{1in}{!}{
3496 \backslash
3497 includegraphics{logo.eps}}}
3498 \end_layout
3499
3500 \begin_layout Standard
3501 \noindent
3502 (you may need to preface this with 
3503 \family typewriter
3504
3505 \backslash
3506 usepackage{graphics}
3507 \family default
3508  if you don't include EPS files elsewhere in your document).
3509 \end_layout
3510
3511 \begin_layout Section
3512 Minipages
3513 \end_layout
3514
3515 \begin_layout Standard
3516 LaTeX provides a mechanism to produce essentially a page within a page,
3517  called minipages.
3518  Within a minipage, all the usual rules of indentation, line wrapping, etc.\InsetSpace ~
3519 apply.
3520  LyX also provides some of the minipage capability.
3521 \end_layout
3522
3523 \begin_layout Standard
3524 Minipages in LyX have their own collapsable box; insert one via 
3525 \family sans
3526 \bar under
3527 I
3528 \bar default
3529 nsert\SpecialChar \menuseparator
3530 Mini
3531 \bar under
3532 p
3533 \bar default
3534 age
3535 \family default
3536 .
3537  Right-clicking on the box allows you to alter the minipage's width and
3538  alignment within the page.
3539  Warning: if the minipage is too long to fit on a page, it is truncated,
3540  not wrapped onto the next page.
3541 \end_layout
3542
3543 \begin_layout Standard
3544 If you place two minipages side-by-side, you can use 
3545 \family sans
3546 \bar under
3547 I
3548 \bar default
3549 nsert\SpecialChar \menuseparator
3550
3551 \bar under
3552 S
3553 \bar default
3554 pecial\InsetSpace ~
3555 Character
3556 \family default
3557  to insert a special instruction known in the LaTeX world as an 
3558 \family typewriter
3559 hfill
3560 \family default
3561  to put a maximum amount of space between them; it forces one minipage to
3562  the left edge, the other to the right edge.
3563  The examples below show the difference.
3564 \end_layout
3565
3566 \begin_layout Standard
3567 \begin_inset Box Frameless
3568 position "t"
3569 hor_pos "c"
3570 has_inner_box 1
3571 inner_pos "c"
3572 use_parbox 0
3573 width "1.5in"
3574 special "none"
3575 height "1pt"
3576 height_special "totalheight"
3577 status open
3578
3579 \begin_layout Standard
3580 This is a minipage which does not use hfill.
3581  This is the second sentence of a minipage which does not use hfill.
3582 \end_layout
3583
3584 \end_inset
3585
3586
3587 \end_layout
3588
3589 \begin_layout Standard
3590 \begin_inset Box Frameless
3591 position "t"
3592 hor_pos "c"
3593 has_inner_box 1
3594 inner_pos "c"
3595 use_parbox 0
3596 width "1.5in"
3597 special "none"
3598 height "1pt"
3599 height_special "totalheight"
3600 status open
3601
3602 \begin_layout Standard
3603 This is a second minipage which does not use hfill.
3604  This is the second sentence of a second minipage which does not use hfill.
3605 \end_layout
3606
3607 \end_inset
3608
3609
3610 \end_layout
3611
3612 \begin_layout Standard
3613 \begin_inset VSpace medskip
3614 \end_inset
3615
3616
3617 \end_layout
3618
3619 \begin_layout Standard
3620 Here is some normal text to separate the two examples.
3621 \end_layout
3622
3623 \begin_layout Standard
3624 \begin_inset VSpace medskip
3625 \end_inset
3626
3627
3628 \end_layout
3629
3630 \begin_layout Standard
3631 \begin_inset Box Frameless
3632 position "t"
3633 hor_pos "c"
3634 has_inner_box 1
3635 inner_pos "c"
3636 use_parbox 0
3637 width "1.5in"
3638 special "none"
3639 height "1pt"
3640 height_special "totalheight"
3641 status open
3642
3643 \begin_layout Standard
3644 This is a minipage which does use hfill.
3645  This is the second sentence of a minipage which does use hfill.
3646 \end_layout
3647
3648 \end_inset
3649
3650
3651 \hfill
3652
3653 \begin_inset Box Frameless
3654 position "t"
3655 hor_pos "c"
3656 has_inner_box 1
3657 inner_pos "c"
3658 use_parbox 0
3659 width "1.5in"
3660 special "none"
3661 height "1pt"
3662 height_special "totalheight"
3663 status open
3664
3665 \begin_layout Standard
3666 This is a second minipage which does use hfill.
3667  This is the second sentence of a second minipage which does use hfill.
3668 \end_layout
3669
3670 \end_inset
3671
3672
3673 \end_layout
3674
3675 \begin_layout Section
3676 Wrapping Text Around Figures
3677 \begin_inset LatexCommand \label{sec:floatflt}
3678
3679 \end_inset
3680
3681
3682 \end_layout
3683
3684 \begin_layout Standard
3685 \begin_inset Wrap figure
3686 placement r
3687 width "6cm"
3688 status open
3689
3690 \begin_layout Standard
3691 \begin_inset Graphics
3692         filename mobius.eps
3693         display color
3694         width 40col%
3695         rotateOrigin center
3696
3697 \end_inset
3698
3699
3700 \end_layout
3701
3702 \begin_layout Caption
3703 This is a wrapped figure, and this is the brilliant caption that describes
3704  it
3705 \end_layout
3706
3707 \end_inset
3708
3709
3710 \end_layout
3711
3712 \begin_layout Standard
3713 A very frequently asked question is whether text can be made to 
3714 \begin_inset Quotes eld
3715 \end_inset
3716
3717 wrap
3718 \begin_inset Quotes erd
3719 \end_inset
3720
3721  around figures so that a figure occupies some fraction of the column width
3722  and text fills the rest.
3723  If you have the LaTeX package 
3724 \family typewriter
3725 floatflt
3726 \family default
3727  installed (you can find out about it in the 
3728 \emph on
3729 LaTeX Configuration
3730 \emph default
3731  manual) you can do this.
3732 \end_layout
3733
3734 \begin_layout Standard
3735 At the right is a figure of a mobius strip---you should have already seen
3736  this in the 
3737 \emph on
3738 User's Guide
3739 \emph default
3740 .
3741  To wrap the text like this insert a wrap box via 
3742 \family sans
3743 \bar under
3744 I
3745 \bar default
3746 nsert\SpecialChar \menuseparator
3747 Flo
3748 \bar under
3749 a
3750 \bar default
3751 ts\SpecialChar \menuseparator
3752 Floatflt Figure
3753 \family default
3754 .
3755 \end_layout
3756
3757 \begin_layout Standard
3758 Note: this package is very fragile! For example, having a figure too close
3759  to the bottom of the page will mess things up, as will having two figures
3760  close together.
3761  Use this package sparingly and do read the documentation that came with
3762  it (which will also tell you how to wrap text around tables).
3763 \end_layout
3764
3765 \begin_layout Section
3766 Extra Table Options
3767 \end_layout
3768
3769 \begin_layout Standard
3770 While the standard table layout will suffice in 99% of all tables you generate,
3771  occasionally you will run into one which requires a bit of extra tweaking.
3772  The table dialog which appears on a right-click of a table allows these
3773  tweaks to be made.
3774  It will give you access to some extra column alignment parameters.
3775  A little bit of LaTeX background is useful here: when you set up a table
3776  in LaTeX, each column is given an alignment type.
3777  For example, you would give it 
3778 \begin_inset Quotes eld
3779 \end_inset
3780
3781
3782 \family typewriter
3783 l
3784 \family default
3785
3786 \begin_inset Quotes erd
3787 \end_inset
3788
3789
3790 \begin_inset Quotes eld
3791 \end_inset
3792
3793
3794 \family typewriter
3795 c
3796 \family default
3797
3798 \begin_inset Quotes erd
3799 \end_inset
3800
3801 , or 
3802 \begin_inset Quotes eld
3803 \end_inset
3804
3805
3806 \family typewriter
3807 r
3808 \family default
3809
3810 \begin_inset Quotes erd
3811 \end_inset
3812
3813  for left-aligned, centered, and right-aligned columns respectively (which
3814  appear as the left/center/right radio buttons in LyX).
3815  A fourth type is 
3816 \begin_inset Quotes eld
3817 \end_inset
3818
3819
3820 \family typewriter
3821 p
3822 \family default
3823
3824 \begin_inset Quotes erd
3825 \end_inset
3826
3827 , which will make a column of a specified width (the width box in LyX),
3828  and will wrap text within that box.
3829  A fifth type is 
3830 \begin_inset Quotes eld
3831 \end_inset
3832
3833
3834 \family typewriter
3835 |
3836 \family default
3837
3838 \begin_inset Quotes erd
3839 \end_inset
3840
3841  (vertical bar) which rather than making a column will make a vertical rule
3842  at that point; this manifests itself in LyX as the 
3843 \begin_inset Quotes eld
3844 \end_inset
3845
3846 borders
3847 \begin_inset Quotes erd
3848 \end_inset
3849
3850  buttons.
3851  Finally, there is a type 
3852 \begin_inset Quotes eld
3853 \end_inset
3854
3855
3856 \family typewriter
3857 @
3858 \family default
3859
3860 \begin_inset Quotes erd
3861 \end_inset
3862
3863 , which allows you to use whatever is enclosed in the accompanying braces
3864  as the column separator, including a null argument.
3865  The reasons for doing this may not be obvious, but they can be very powerful.
3866  They are best demonstrated by example.
3867 \end_layout
3868
3869 \begin_layout Subsection
3870 Removing Extra Column Space
3871 \end_layout
3872
3873 \begin_layout Standard
3874 Here is a standard table:
3875 \end_layout
3876
3877 \begin_layout Standard
3878 \align center
3879 \begin_inset Tabular
3880 <lyxtabular version="3" rows="3" columns="2">
3881 <features>
3882 <column alignment="left" valignment="top" width="0pt">
3883 <column alignment="left" valignment="top" leftline="true" width="0pt">
3884 <row bottomline="true">
3885 <cell alignment="left" valignment="top" topline="true" usebox="none">
3886 \begin_inset Text
3887
3888 \begin_layout Standard
3889
3890 \family roman
3891 \series medium
3892 \shape up
3893 \size normal
3894 \emph off
3895 \bar no
3896 \noun off
3897 \color none
3898 Type
3899 \end_layout
3900
3901 \end_inset
3902 </cell>
3903 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
3904 \begin_inset Text
3905
3906 \begin_layout Standard
3907
3908 \family roman
3909 \series medium
3910 \shape up
3911 \size normal
3912 \emph off
3913 \bar no
3914 \noun off
3915 \color none
3916 Example
3917 \end_layout
3918
3919 \end_inset
3920 </cell>
3921 </row>
3922 <row>
3923 <cell alignment="left" valignment="top" topline="true" usebox="none">
3924 \begin_inset Text
3925
3926 \begin_layout Standard
3927
3928 \family roman
3929 \series medium
3930 \shape up
3931 \size normal
3932 \emph off
3933 \bar no
3934 \noun off
3935 \color none
3936 Rock
3937 \end_layout
3938
3939 \end_inset
3940 </cell>
3941 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3942 \begin_inset Text
3943
3944 \begin_layout Standard
3945
3946 \family roman
3947 \series medium
3948 \shape up
3949 \size normal
3950 \emph off
3951 \bar no
3952 \noun off
3953 \color none
3954 Granite
3955 \end_layout
3956
3957 \end_inset
3958 </cell>
3959 </row>
3960 <row>
3961 <cell alignment="center" valignment="top" topline="true" usebox="none">
3962 \begin_inset Text
3963
3964 \begin_layout Standard
3965
3966 \family roman
3967 \series medium
3968 \shape up
3969 \size normal
3970 \emph off
3971 \bar no
3972 \noun off
3973 \color none
3974 Mineral
3975 \end_layout
3976
3977 \end_inset
3978 </cell>
3979 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3980 \begin_inset Text
3981
3982 \begin_layout Standard
3983
3984 \family roman
3985 \series medium
3986 \shape up
3987 \size normal
3988 \emph off
3989 \bar no
3990 \noun off
3991 \color none
3992 Quartz
3993 \end_layout
3994
3995 \end_inset
3996 </cell>
3997 </row>
3998 </lyxtabular>
3999
4000 \end_inset
4001
4002
4003 \end_layout
4004
4005 \begin_layout Standard
4006 Notice that the horizontal rule extends a bit past the text on both sides.
4007  If you wanted the line to end even with the text, we can put a null separator
4008  on the ends to get rid of the bit of extra space LaTeX adds by default.
4009  Here is the example:
4010 \end_layout
4011
4012 \begin_layout Standard
4013 \align center
4014 \begin_inset Tabular
4015 <lyxtabular version="3" rows="3" columns="2">
4016 <features>
4017 <column alignment="left" valignment="top" width="0pt" special="@{} l">
4018 <column alignment="left" valignment="top" leftline="true" width="0pt" special="l @{}">
4019 <row bottomline="true">
4020 <cell alignment="left" valignment="top" topline="true" usebox="none">
4021 \begin_inset Text
4022
4023 \begin_layout Standard
4024
4025 \family roman
4026 \series medium
4027 \shape up
4028 \size normal
4029 \emph off
4030 \bar no
4031 \noun off
4032 \color none
4033 Type
4034 \end_layout
4035
4036 \end_inset
4037 </cell>
4038 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
4039 \begin_inset Text
4040
4041 \begin_layout Standard
4042
4043 \family roman
4044 \series medium
4045 \shape up
4046 \size normal
4047 \emph off
4048 \bar no
4049 \noun off
4050 \color none
4051 Example
4052 \end_layout
4053
4054 \end_inset
4055 </cell>
4056 </row>
4057 <row>
4058 <cell alignment="left" valignment="top" topline="true" usebox="none">
4059 \begin_inset Text
4060
4061 \begin_layout Standard
4062
4063 \family roman
4064 \series medium
4065 \shape up
4066 \size normal
4067 \emph off
4068 \bar no
4069 \noun off
4070 \color none
4071 Rock
4072 \end_layout
4073
4074 \end_inset
4075 </cell>
4076 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4077 \begin_inset Text
4078
4079 \begin_layout Standard
4080
4081 \family roman
4082 \series medium
4083 \shape up
4084 \size normal
4085 \emph off
4086 \bar no
4087 \noun off
4088 \color none
4089 Granite
4090 \end_layout
4091
4092 \end_inset
4093 </cell>
4094 </row>
4095 <row>
4096 <cell alignment="center" valignment="top" topline="true" usebox="none">
4097 \begin_inset Text
4098
4099 \begin_layout Standard
4100
4101 \family roman
4102 \series medium
4103 \shape up
4104 \size normal
4105 \emph off
4106 \bar no
4107 \noun off
4108 \color none
4109 Mineral
4110 \end_layout
4111
4112 \end_inset
4113 </cell>
4114 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4115 \begin_inset Text
4116
4117 \begin_layout Standard
4118
4119 \family roman
4120 \series medium
4121 \shape up
4122 \size normal
4123 \emph off
4124 \bar no
4125 \noun off
4126 \color none
4127 Quartz
4128 \end_layout
4129
4130 \end_inset
4131 </cell>
4132 </row>
4133 </lyxtabular>
4134
4135 \end_inset
4136
4137
4138 \end_layout
4139
4140 \begin_layout Standard
4141 In this case, the column specifier for the left column was set to 
4142 \begin_inset Quotes eld
4143 \end_inset
4144
4145
4146 \family typewriter
4147 @{} l
4148 \family default
4149
4150 \begin_inset Quotes erd
4151 \end_inset
4152
4153 , while the right column was set to 
4154 \begin_inset Quotes eld
4155 \end_inset
4156
4157
4158 \family typewriter
4159 l @{}
4160 \family default
4161
4162 \begin_inset Quotes erd
4163 \end_inset
4164
4165 , in order to put the null characters on the edges.
4166  
4167 \end_layout
4168
4169 \begin_layout Subsection
4170 Changing the Column Separator Character
4171 \end_layout
4172
4173 \begin_layout Standard
4174 Now suppose you really wanted, for reasons that are completely opaque, to
4175  use 
4176 \begin_inset Formula $\sqrt{\pi}$
4177 \end_inset
4178
4179  with some space around it for the column separator.
4180  Simply turn off the vertical border, then set the right column specifier
4181  to 
4182 \begin_inset Quotes eld
4183 \end_inset
4184
4185
4186 \family typewriter
4187 @{~$
4188 \backslash
4189 sqrt{
4190 \backslash
4191 pi}$~} l
4192 \family default
4193
4194 \begin_inset Quotes erd
4195 \end_inset
4196
4197 .
4198  You could now make a table like this:
4199 \end_layout
4200
4201 \begin_layout Standard
4202 \align center
4203 \begin_inset Tabular
4204 <lyxtabular version="3" rows="3" columns="2">
4205 <features>
4206 <column alignment="left" valignment="top" width="0pt">
4207 <column alignment="left" valignment="top" width="0in" special="@{~$\sqrt{\pi}$~}l">
4208 <row bottomline="true">
4209 <cell alignment="left" valignment="top" topline="true" usebox="none">
4210 \begin_inset Text
4211
4212 \begin_layout Standard
4213
4214 \family roman
4215 \series medium
4216 \shape up
4217 \size normal
4218 \emph off
4219 \bar no
4220 \noun off
4221 \color none
4222 Type
4223 \end_layout
4224
4225 \end_inset
4226 </cell>
4227 <cell alignment="left" valignment="top" topline="true" usebox="none">
4228 \begin_inset Text
4229
4230 \begin_layout Standard
4231
4232 \family roman
4233 \series medium
4234 \shape up
4235 \size normal
4236 \emph off
4237 \bar no
4238 \noun off
4239 \color none
4240 Example
4241 \end_layout
4242
4243 \end_inset
4244 </cell>
4245 </row>
4246 <row>
4247 <cell alignment="left" valignment="top" topline="true" usebox="none">
4248 \begin_inset Text
4249
4250 \begin_layout Standard
4251
4252 \family roman
4253 \series medium
4254 \shape up
4255 \size normal
4256 \emph off
4257 \bar no
4258 \noun off
4259 \color none
4260 Rock
4261 \end_layout
4262
4263 \end_inset
4264 </cell>
4265 <cell alignment="center" valignment="top" topline="true" usebox="none">
4266 \begin_inset Text
4267
4268 \begin_layout Standard
4269
4270 \family roman
4271 \series medium
4272 \shape up
4273 \size normal
4274 \emph off
4275 \bar no
4276 \noun off
4277 \color none
4278 Granite
4279 \end_layout
4280
4281 \end_inset
4282 </cell>
4283 </row>
4284 <row>
4285 <cell alignment="center" valignment="top" topline="true" usebox="none">
4286 \begin_inset Text
4287
4288 \begin_layout Standard
4289
4290 \family roman
4291 \series medium
4292 \shape up
4293 \size normal
4294 \emph off
4295 \bar no
4296 \noun off
4297 \color none
4298 Mineral
4299 \end_layout
4300
4301 \end_inset
4302 </cell>
4303 <cell alignment="center" valignment="top" topline="true" usebox="none">
4304 \begin_inset Text
4305
4306 \begin_layout Standard
4307
4308 \family roman
4309 \series medium
4310 \shape up
4311 \size normal
4312 \emph off
4313 \bar no
4314 \noun off
4315 \color none
4316 Quartz
4317 \end_layout
4318
4319 \end_inset
4320 </cell>
4321 </row>
4322 </lyxtabular>
4323
4324 \end_inset
4325
4326
4327 \end_layout
4328
4329 \begin_layout Subsection
4330 Making a Decimal Point Aligned Column
4331 \end_layout
4332
4333 \begin_layout Standard
4334 Okay, that last example was very silly, but here is one that is not.
4335  Suppose you want to make a table that has a column which is aligned on
4336  a decimal point.
4337  A standard LaTeX trick to do this is to set the whole number part in a
4338  right-aligned column, use a decimal point for the column separator, then
4339  set the fractional part as a left-aligned column.
4340  A variation on this is to include the decimal point explicitly with the
4341  whole part, then use just a null separator in between.
4342  The latter variation is demonstrated here:
4343 \end_layout
4344
4345 \begin_layout Standard
4346 \align center
4347 \begin_inset Tabular
4348 <lyxtabular version="3" rows="5" columns="3">
4349 <features>
4350 <column alignment="center" valignment="top" width="0pt">
4351 <column alignment="right" valignment="top" leftline="true" width="0pt">
4352 <column alignment="center" valignment="top" width="0pt" special="@{} l">
4353 <row bottomline="true">
4354 <cell alignment="center" valignment="top" topline="true" usebox="none">
4355 \begin_inset Text
4356
4357 \begin_layout Standard
4358
4359 \family roman
4360 \series medium
4361 \shape up
4362 \size normal
4363 \emph off
4364 \bar no
4365 \noun off
4366 \color none
4367 Expression
4368 \end_layout
4369
4370 \end_inset
4371 </cell>
4372 <cell multicolumn="1" alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
4373 \begin_inset Text
4374
4375 \begin_layout Standard
4376
4377 \family roman
4378 \series medium
4379 \shape up
4380 \size normal
4381 \emph off
4382 \bar no
4383 \noun off
4384 \color none
4385 Value 
4386 \end_layout
4387
4388 \end_inset
4389 </cell>
4390 <cell multicolumn="2" alignment="center" valignment="top" topline="true" usebox="none">
4391 \begin_inset Text
4392
4393 \begin_layout Standard
4394
4395 \end_layout
4396
4397 \end_inset
4398 </cell>
4399 </row>
4400 <row>
4401 <cell alignment="center" valignment="top" topline="true" usebox="none">
4402 \begin_inset Text
4403
4404 \begin_layout Standard
4405
4406 \family roman
4407 \series medium
4408 \shape up
4409 \size normal
4410 \emph off
4411 \bar no
4412 \noun off
4413 \color none
4414 \begin_inset Formula $\pi$
4415 \end_inset
4416
4417
4418 \end_layout
4419
4420 \end_inset
4421 </cell>
4422 <cell alignment="right" valignment="top" topline="true" leftline="true" usebox="none">
4423 \begin_inset Text
4424
4425 \begin_layout Standard
4426
4427 \family roman
4428 \series medium
4429 \shape up
4430 \size normal
4431 \emph off
4432 \bar no
4433 \noun off
4434 \color none
4435 3.
4436 \end_layout
4437
4438 \end_inset
4439 </cell>
4440 <cell alignment="center" valignment="top" topline="true" usebox="none">
4441 \begin_inset Text
4442
4443 \begin_layout Standard
4444
4445 \family roman
4446 \series medium
4447 \shape up
4448 \size normal
4449 \emph off
4450 \bar no
4451 \noun off
4452 \color none
4453 1416
4454 \end_layout
4455
4456 \end_inset
4457 </cell>
4458 </row>
4459 <row>
4460 <cell alignment="center" valignment="top" topline="true" usebox="none">
4461 \begin_inset Text
4462
4463 \begin_layout Standard
4464
4465 \family roman
4466 \series medium
4467 \shape up
4468 \size normal
4469 \emph off
4470 \bar no
4471 \noun off
4472 \color none
4473 \begin_inset Formula $\pi^{\pi}$
4474 \end_inset
4475
4476
4477 \end_layout
4478
4479 \end_inset
4480 </cell>
4481 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4482 \begin_inset Text
4483
4484 \begin_layout Standard
4485
4486 \family roman
4487 \series medium
4488 \shape up
4489 \size normal
4490 \emph off
4491 \bar no
4492 \noun off
4493 \color none
4494 36.
4495 \end_layout
4496
4497 \end_inset
4498 </cell>
4499 <cell alignment="center" valignment="top" topline="true" usebox="none">
4500 \begin_inset Text
4501
4502 \begin_layout Standard
4503
4504 \family roman
4505 \series medium
4506 \shape up
4507 \size normal
4508 \emph off
4509 \bar no
4510 \noun off
4511 \color none
4512 462
4513 \end_layout
4514
4515 \end_inset
4516 </cell>
4517 </row>
4518 <row>
4519 <cell alignment="center" valignment="top" topline="true" usebox="none">
4520 \begin_inset Text
4521
4522 \begin_layout Standard
4523
4524 \family roman
4525 \series medium
4526 \shape up
4527 \size normal
4528 \emph off
4529 \bar no
4530 \noun off
4531 \color none
4532 \begin_inset Formula $(\pi^{\pi})^{\pi}$
4533 \end_inset
4534
4535
4536 \end_layout
4537
4538 \end_inset
4539 </cell>
4540 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4541 \begin_inset Text
4542
4543 \begin_layout Standard
4544
4545 \family roman
4546 \series medium
4547 \shape up
4548 \size normal
4549 \emph off
4550 \bar no
4551 \noun off
4552 \color none
4553 80663.
4554 \end_layout
4555
4556 \end_inset
4557 </cell>
4558 <cell alignment="center" valignment="top" topline="true" usebox="none">
4559 \begin_inset Text
4560
4561 \begin_layout Standard
4562
4563 \end_layout
4564
4565 \end_inset
4566 </cell>
4567 </row>
4568 <row>
4569 <cell alignment="center" valignment="top" topline="true" usebox="none">
4570 \begin_inset Text
4571
4572 \begin_layout Standard
4573
4574 \family roman
4575 \series medium
4576 \shape up
4577 \size normal
4578 \emph off
4579 \bar no
4580 \noun off
4581 \color none
4582 \begin_inset Formula $\pi^{\pi^{\pi}}$
4583 \end_inset
4584
4585
4586 \end_layout
4587
4588 \end_inset
4589 </cell>
4590 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4591 \begin_inset Text
4592
4593 \begin_layout Standard
4594
4595 \family roman
4596 \series medium
4597 \shape up
4598 \size normal
4599 \emph off
4600 \bar no
4601 \noun off
4602 \color none
4603 1.
4604 \end_layout
4605
4606 \end_inset
4607 </cell>
4608 <cell alignment="center" valignment="top" topline="true" usebox="none">
4609 \begin_inset Text
4610
4611 \begin_layout Standard
4612
4613 \family roman
4614 \series medium
4615 \shape up
4616 \size normal
4617 \emph off
4618 \bar no
4619 \noun off
4620 \color none
4621 3402
4622 \begin_inset Formula $\times10^{18}$
4623 \end_inset
4624
4625
4626 \end_layout
4627
4628 \end_inset
4629 </cell>
4630 </row>
4631 </lyxtabular>
4632
4633 \end_inset
4634
4635
4636 \end_layout
4637
4638 \begin_layout Standard
4639 Though it appears a bit funny in LyX, on paper it will produce what appears
4640  to be a 2-column table in which the right column is aligned on the decimal
4641  point and the header appears to be centered over it.
4642 \end_layout
4643
4644 \begin_layout Standard
4645 Perhaps it is best if I described just what I did: first, create a 3
4646 \begin_inset Formula $\times$
4647 \end_inset
4648
4649 3 table and remove all the borders.
4650  Then re-add a bottom border to the top row, and a right border to the first
4651  column.
4652  Type in the values for the first column and set its alignment to 
4653 \family sans
4654 center
4655 \family default
4656 .
4657  Type in the 
4658 \family typewriter
4659 3.
4660 \family default
4661
4662 \family typewriter
4663 36.
4664 \family default
4665
4666 \family typewriter
4667 80663.
4668 \family default
4669 , and 
4670 \family typewriter
4671 1.
4672
4673 \family default
4674  and set that column's alignment to 
4675 \family sans
4676 right
4677 \family default
4678 .
4679  Type in the 
4680 \family typewriter
4681 1416
4682 \family default
4683
4684 \family typewriter
4685 462
4686 \family default
4687 , and 
4688 \family typewriter
4689 3402
4690 \begin_inset Formula $\times10^{18}$
4691 \end_inset
4692
4693
4694 \family default
4695  and set the extra column alignment to 
4696 \family typewriter
4697 @{} l
4698 \family default
4699 .
4700  Finally type in the word 
4701 \family typewriter
4702 Value
4703 \family default
4704  in the middle column, highlight it and the blank entry to its right, and
4705  check the 
4706 \family sans
4707 Special Cell
4708 \family default
4709  entry 
4710 \family sans
4711 multicolumn
4712 \family default
4713 .
4714  Easy, right? 
4715 \end_layout
4716
4717 \begin_layout Subsection
4718 A Better Decimal-Alignment Solution
4719 \end_layout
4720
4721 \begin_layout Standard
4722 An alternative way to have decimal alignment in tables is through the 
4723 \family typewriter
4724 dcolumn
4725 \family default
4726  package.
4727  Add the following to the LaTeX preamble:
4728 \end_layout
4729
4730 \begin_layout LyX-Code
4731
4732 \backslash
4733 usepackage{dcolumn}
4734 \end_layout
4735
4736 \begin_layout LyX-Code
4737
4738 \backslash
4739 newcolumntype{d}[1]{D{.}{.}{#1}}
4740 \end_layout
4741
4742 \begin_layout Standard
4743 To have a column decimally aligned, enter in the 
4744 \family sans
4745 Special Column Alignment
4746 \family default
4747  box of the 
4748 \family sans
4749 Table
4750 \family default
4751  dialog the following:
4752 \end_layout
4753
4754 \begin_layout LyX-Code
4755 d{number of decimals of the data}
4756 \end_layout
4757
4758 \begin_layout Standard
4759 To create extra column space just increase the number of decimals in 
4760 \family typewriter
4761 d{}
4762 \family default
4763 .
4764  Setting the multicolumn attribute for a single cell makes it insensitive
4765  to the decimal alignment which comes in handy as well.
4766  A drawback of this method is that math mode is not allowed in a column
4767  with decimal alignment except if the multicolumn attribute is set.
4768 \end_layout
4769
4770 \begin_layout Standard
4771 This method offers the same flexibility as the 
4772 \family typewriter
4773 dcolumn
4774 \family default
4775  package.
4776  One could, for example, change the alignment separator, and have different
4777  alignment separators for different columns by defining multiple column
4778  types in the preamble.
4779  The syntax is as follows: 
4780 \end_layout
4781
4782 \begin_layout LyX-Code
4783 D{inputsep}{outputsep}{decimal places}
4784 \end_layout
4785
4786 \begin_layout Standard
4787 The interested reader is directed towards the 
4788 \family typewriter
4789 dcolumn
4790 \family default
4791  package documentation for more details.
4792 \end_layout
4793
4794 \begin_layout Section
4795 Itemize Bullet Selection
4796 \begin_inset LatexCommand \label{sec:bullet}
4797
4798 \end_inset
4799
4800
4801 \end_layout
4802
4803 \begin_layout Standard
4804 by
4805 \noun on
4806  Allan Rae
4807 \end_layout
4808
4809 \begin_layout Subsection
4810 Introduction
4811 \end_layout
4812
4813 \begin_layout Standard
4814 LyX provides 216 bullet shapes that can be accessed from a simple dialog.
4815  Using this dialog you can easily specify what bullet shape to use at each
4816  level of an itemized list.
4817  These settings are document-wide so you won't be able to specify different
4818  sets of bullets for different paragraphs
4819 \begin_inset Foot
4820 status collapsed
4821
4822 \begin_layout Standard
4823 Well, actually you can but you'll have to do it by hand.
4824 \end_layout
4825
4826 \end_inset
4827
4828 .
4829 \end_layout
4830
4831 \begin_layout Subsection
4832 How it looks
4833 \end_layout
4834
4835 \begin_layout Standard
4836 Open the dialog by selecting the 
4837 \family sans
4838 \bar under
4839 D
4840 \bar default
4841 ocument\SpecialChar \menuseparator
4842
4843 \bar under
4844 S
4845 \bar default
4846 ettings
4847 \family default
4848  menu item and then select the 
4849 \family sans
4850 \bar under
4851 B
4852 \bar default
4853 ullets
4854 \family default
4855  tab.
4856 \end_layout
4857
4858 \begin_layout Standard
4859 The dialog provides you with a table of bullet shapes.
4860  A column of buttons on the left of the table provides access to the six
4861  different panels of bullet shapes.
4862  The row of buttons across the top is used to select which bullet depth
4863  you are changing.
4864  A text entry under the table shows the currently selected bullet shape's
4865  LaTeX equivalent and this can be edited if desired.
4866  If you do modify the text you will also need to specify any needed packages
4867  in the LaTeX preamble.
4868 \end_layout
4869
4870 \begin_layout Standard
4871 The six panels are divided up by the packages they require.
4872  The following table shows the mappings from button name to LaTeX packages.
4873 \end_layout
4874
4875 \begin_layout Standard
4876 \align center
4877 \begin_inset Tabular
4878 <lyxtabular version="3" rows="7" columns="2">
4879 <features>
4880 <column alignment="center" valignment="top" leftline="true" width="0pt">
4881 <column alignment="center" valignment="top" leftline="true" rightline="true" width="0pt">
4882 <row topline="true" bottomline="true">
4883 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4884 \begin_inset Text
4885
4886 \begin_layout Standard
4887
4888 \family roman
4889 \series medium
4890 \shape up
4891 \size normal
4892 \emph off
4893 \bar no
4894 \noun off
4895 \color none
4896 Button
4897 \end_layout
4898
4899 \end_inset
4900 </cell>
4901 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4902 \begin_inset Text
4903
4904 \begin_layout Standard
4905
4906 \family roman
4907 \series medium
4908 \shape up
4909 \size normal
4910 \emph off
4911 \bar no
4912 \noun off
4913 \color none
4914 Packages Required
4915 \end_layout
4916
4917 \end_inset
4918 </cell>
4919 </row>
4920 <row topline="true">
4921 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4922 \begin_inset Text
4923
4924 \begin_layout Standard
4925
4926 \family sans
4927 \series medium
4928 \shape up
4929 \size normal
4930 \emph off
4931 \bar no
4932 \noun off
4933 \color none
4934 Standard
4935 \end_layout
4936
4937 \end_inset
4938 </cell>
4939 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4940 \begin_inset Text
4941
4942 \begin_layout Standard
4943
4944 \series medium
4945 \shape up
4946 \size normal
4947 \emph off
4948 \bar no
4949 \noun off
4950 \color none
4951 base LaTeX
4952 \end_layout
4953
4954 \end_inset
4955 </cell>
4956 </row>
4957 <row topline="true">
4958 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4959 \begin_inset Text
4960
4961 \begin_layout Standard
4962
4963 \family sans
4964 \series medium
4965 \shape up
4966 \size normal
4967 \emph off
4968 \bar no
4969 \noun off
4970 \color none
4971 Maths
4972 \end_layout
4973
4974 \end_inset
4975 </cell>
4976 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4977 \begin_inset Text
4978
4979 \begin_layout Standard
4980
4981 \family typewriter
4982 \series medium
4983 \shape up
4984 \size normal
4985 \emph off
4986 \bar no
4987 \noun off
4988 \color none
4989 amssymb.sty
4990 \end_layout
4991
4992 \end_inset
4993 </cell>
4994 </row>
4995 <row topline="true">
4996 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4997 \begin_inset Text
4998
4999 \begin_layout Standard
5000
5001 \family sans
5002 \series medium
5003 \shape up
5004 \size normal
5005 \emph off
5006 \bar no
5007 \noun off
5008 \color none
5009 Ding1
5010 \end_layout
5011
5012 \end_inset
5013 </cell>
5014 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
5015 \begin_inset Text
5016
5017 \begin_layout Standard
5018
5019 \family typewriter
5020 \series medium
5021 \shape up
5022 \size normal
5023 \emph off
5024 \bar no
5025 \noun off
5026 \color none
5027 pifont.sty
5028 \end_layout
5029
5030 \end_inset
5031 </cell>
5032 </row>
5033 <row topline="true">
5034 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
5035 \begin_inset Text
5036
5037 \begin_layout Standard
5038
5039 \family sans
5040 \series medium
5041 \shape up
5042 \size normal
5043 \emph off
5044 \bar no
5045 \noun off
5046 \color none
5047 Ding2
5048 \end_layout
5049
5050 \end_inset
5051 </cell>
5052 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
5053 \begin_inset Text
5054
5055 \begin_layout Standard
5056
5057 \family typewriter
5058 \series medium
5059 \shape up
5060 \size normal
5061 \emph off
5062 \bar no
5063 \noun off
5064 \color none
5065 pifont.sty
5066 \end_layout
5067
5068 \end_inset
5069 </cell>
5070 </row>
5071 <row topline="true">
5072 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
5073 \begin_inset Text
5074
5075 \begin_layout Standard
5076
5077 \family sans
5078 \series medium
5079 \shape up
5080 \size normal
5081 \emph off
5082 \bar no
5083 \noun off
5084 \color none
5085 Ding3
5086 \end_layout
5087
5088 \end_inset
5089 </cell>
5090 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
5091 \begin_inset Text
5092
5093 \begin_layout Standard
5094
5095 \family typewriter
5096 \series medium
5097 \shape up
5098 \size normal
5099 \emph off
5100 \bar no
5101 \noun off
5102 \color none
5103 pifont.sty
5104 \end_layout
5105
5106 \end_inset
5107 </cell>
5108 </row>
5109 <row topline="true" bottomline="true">
5110 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
5111 \begin_inset Text
5112
5113 \begin_layout Standard
5114
5115 \family sans
5116 \series medium
5117 \shape up
5118 \size normal
5119 \emph off
5120 \bar no
5121 \noun off
5122 \color none
5123 Ding4
5124 \end_layout
5125
5126 \end_inset
5127 </cell>
5128 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
5129 \begin_inset Text
5130
5131 \begin_layout Standard
5132
5133 \family typewriter
5134 \series medium
5135 \shape up
5136 \size normal
5137 \emph off
5138 \bar no
5139 \noun off
5140 \color none
5141 pifont.sty
5142 \end_layout
5143
5144 \end_inset
5145 </cell>
5146 </row>
5147 </lyxtabular>
5148
5149 \end_inset
5150
5151
5152 \end_layout
5153
5154 \begin_layout Standard
5155 LyX doesn't stop you using bullets from packages you don't have.
5156  If you get errors from LaTeX when you try to view or print the file then
5157  its likely you are missing a package.
5158  LyX doesn't restrict your use since you may be editing locally and exporting
5159  elsewhere.
5160 \end_layout
5161
5162 \begin_layout Subsection
5163 How to use it
5164 \end_layout
5165
5166 \begin_layout Standard
5167 Select which bullet depth you want to change then select the bullet shape
5168  and size.
5169
5170 \family sans
5171  
5172 \family default
5173 Any changes will not be visible in LyX, but are visible when viewing the
5174  document using xdvi or ghostview.
5175 \end_layout
5176
5177 \begin_layout Standard
5178 You can reset a bullet shape to the default simply by clicking your right
5179  mouse button on the appropriate bullet depth button.
5180 \end_layout
5181
5182 \begin_layout Standard
5183 If you 
5184 \emph on
5185 really
5186 \emph default
5187  want to have multiple sets of paragraphs with different sets of bullets
5188  in each then you're going to have to get your hands dirty.
5189  The itemize bullet selection dialog can help though because it provides
5190  you with the LaTeX code for a wide range of bullet shapes.
5191  To make your own custom paragraphs you have the following options:
5192 \end_layout
5193
5194 \begin_layout Standard
5195 \begin_inset ERT
5196 status inlined
5197
5198 \begin_layout Standard
5199
5200
5201 \backslash
5202 let
5203 \backslash
5204 savelabelitemi=
5205 \backslash
5206 labelitemi
5207 \end_layout
5208
5209 \end_inset
5210
5211
5212 \end_layout
5213
5214 \begin_layout Standard
5215 \begin_inset ERT
5216 status inlined
5217
5218 \begin_layout Standard
5219
5220
5221 \backslash
5222 renewcommand
5223 \backslash
5224 labelitemi[0]{
5225 \backslash
5226 small
5227 \backslash
5228 (
5229 \backslash
5230 sharp
5231 \backslash
5232 )}
5233 \end_layout
5234
5235 \end_inset
5236
5237
5238 \end_layout
5239
5240 \begin_layout Itemize
5241 Use the LaTeX command 
5242 \family typewriter
5243
5244 \backslash
5245 renewcommand{}{}
5246 \family default
5247  to specify a new bullet shape for a given depth.
5248  You'll also need to save the current bullet shape so you can restore it
5249  again afterwards.
5250  In this itemized list the following LaTeX code was used to change the bullet
5251  used for the first depth.
5252 \newline
5253
5254 \family typewriter
5255
5256 \backslash
5257 let
5258 \backslash
5259 savelabelitemi=
5260 \backslash
5261 labelitemi
5262 \family default
5263  
5264 \family typewriter
5265
5266 \newline
5267
5268 \backslash
5269 renewcommand
5270 \backslash
5271 labelitemi[0]{
5272 \backslash
5273 small
5274 \backslash
5275 (
5276 \backslash
5277 sharp
5278 \backslash
5279 )}
5280 \newline
5281
5282 \family default
5283 Note that the itemize depth is specified in Roman numerals as part of the
5284  
5285 \family typewriter
5286
5287 \backslash
5288 labelitem
5289 \family default
5290  command.
5291 \end_layout
5292
5293 \begin_layout Itemize
5294 \begin_inset ERT
5295 status inlined
5296
5297 \begin_layout Standard
5298
5299 [
5300 \backslash
5301 (
5302 \backslash
5303 star
5304 \backslash
5305 )]
5306 \end_layout
5307
5308 \end_inset
5309
5310  Specify each individual entry by starting each item with the bullet shape
5311  enclosed in square brackets and set as TeX.
5312  For example, this item was started with 
5313 \family typewriter
5314 [
5315 \backslash
5316 (
5317 \backslash
5318 star
5319 \backslash
5320 )]
5321 \family default
5322 .
5323 \end_layout
5324
5325 \begin_layout Standard
5326 \begin_inset ERT
5327 status inlined
5328
5329 \begin_layout Standard
5330
5331
5332 \backslash
5333 renewcommand
5334 \backslash
5335 labelitemi[0]{
5336 \backslash
5337 savelabelitemi}
5338 \end_layout
5339
5340 \end_inset
5341
5342
5343 \end_layout
5344
5345 \begin_layout Standard
5346 You'll also need to revert the labelitem back to its previous setting for
5347  the global bullet shape settings to remain in effect.
5348  The way used here was:
5349 \newline
5350
5351 \family typewriter
5352
5353 \backslash
5354 renewcommand
5355 \backslash
5356 labelitemi[0]{
5357 \backslash
5358 savelabelitemi}
5359 \end_layout
5360
5361 \begin_layout Chapter
5362 Special Document Classes
5363 \end_layout
5364
5365 \begin_layout Section
5366 AMS LaTeX
5367 \end_layout
5368
5369 \begin_layout Standard
5370 by 
5371 \noun on
5372 David Johnson
5373 \end_layout
5374
5375 \begin_layout Standard
5376 \begin_inset VSpace bigskip
5377 \end_inset
5378
5379
5380 \end_layout
5381
5382 \begin_layout Standard
5383 \noindent
5384 The AMS LaTeX layouts are set up to conform to suggested styles for mathematical
5385  papers to be submitted to American Mathematical Society publications.
5386  The layouts are not tailored to a specific journal, but easily can be.
5387  You should refer to the AMS documentation for specific instructions for
5388  each journal (usually it will entail only changing a single line in the
5389  TeX output).
5390  That documentation is available on the Web at 
5391 \begin_inset LatexCommand \url{http://www.ams.org}
5392
5393 \end_inset
5394
5395  or by ftp at 
5396 \begin_inset LatexCommand \url{ftp://ftp.ams.org/pub/tex/amslatex/}
5397
5398 \end_inset
5399
5400 .These layouts are appropriate, and useful, for any mathematical writing.
5401  There are currently 4 distinct AMS LaTeX layouts: 
5402 \end_layout
5403
5404 \begin_layout Enumerate
5405 amsart: The standard AMS-article format.
5406  All results and similar statements are numbered as 
5407 \begin_inset Formula $(n.m)$
5408 \end_inset
5409
5410 , where the first number refers to the section, and the second refers to
5411  the total number of results (Theorems, Corollaries, Propositions, Definitions
5412  and Remarks, etc.) in that section.
5413  There are also many (but not all) environments available unnumbered, which
5414  is occasionally needed.
5415  Unnumbered environments indicated by an asterisk at the end.
5416 \end_layout
5417
5418 \begin_layout Enumerate
5419 amsart-seq: Here, numbering for each type of statement is in its own sequence,
5420  with no reference to the section number.
5421  There are also many (but not all) environments available unnumbered, which
5422  is occasionally needed.
5423  Unnumbered environments indicated by an asterisk at the end.
5424 \end_layout
5425
5426 \begin_layout Enumerate
5427 amsart-plain: This one is even more terse, since all the environments are
5428  unnumbered.
5429 \end_layout
5430
5431 \begin_layout Enumerate
5432 amsbook: the standard AMS book (really, monograph) format.
5433  Numbering is similar to the amsart layout, except that all numbering is
5434  by 
5435 \begin_inset Formula $(n.m.p)$
5436 \end_inset
5437
5438 , where the first number refers to the chapter, the second to the section,
5439  and the third is the number of the results (Theorems, Corollaries, Propositions
5440 , Definitions and Remarks, etc.) in that section.
5441  There are also many (but not all) environments available unnumbered, which
5442  is occasionally needed.
5443  Unnumbered environments indicated by an asterisk at the end.
5444 \end_layout
5445
5446 \begin_layout Standard
5447 Any AMS LyX file can be converted to either of the numbering schemes by
5448  simply changing the document class in the 
5449 \family sans
5450 \bar under
5451 D
5452 \bar default
5453 ocument\SpecialChar \menuseparator
5454
5455 \bar under
5456 S
5457 \bar default
5458 ettings
5459 \family default
5460  dialog.
5461  
5462 \end_layout
5463
5464 \begin_layout Subsection
5465 What these layouts provide
5466 \end_layout
5467
5468 \begin_layout Standard
5469 There is a long list of included environments provided by these layouts.
5470  Most mathematical papers or books will set as special statements most of
5471  these environments, in AMS-LaTeX there is an opportunity to define an unlimited
5472  variety of such declarations.
5473  However, the AMS recommends the environments that are available in LyX.
5474  The list of environments (not counting the standard environments such as
5475  
5476 \family sans
5477 sections, bibliography, title, author, date
5478 \family default
5479 ), is:
5480 \end_layout
5481
5482 \begin_layout Description
5483 Theorem This is typically used for the statements of major results.
5484  The word 
5485 \begin_inset Quotes eld
5486 \end_inset
5487
5488
5489 \family sans
5490 Theorem
5491 \family default
5492
5493 \begin_inset Quotes erd
5494 \end_inset
5495
5496  appears in bold type, along with an automatically-determined number (an
5497  unnumbered version, 
5498 \family sans
5499 Theorem*
5500 \family default
5501 , is also available).
5502  The text is italicized.
5503 \end_layout
5504
5505 \begin_layout Description
5506 Corollary This is used for statements which follow fairly directly from
5507  previous statements.
5508  Again, these can be major results.
5509  Unnumbered version 
5510 \family sans
5511 Corollary*
5512 \family default
5513  is available.
5514 \end_layout
5515
5516 \begin_layout Description
5517 Lemma These are smaller results needed to prove other statements.
5518 \end_layout
5519
5520 \begin_layout Description
5521 Proposition These are less major results which (hopefully) add to the general
5522  theory being discussed.
5523 \end_layout
5524
5525 \begin_layout Description
5526 Conjecture These are statements provided without justification, which the
5527  author does not know how to prove, but which seem to be true (to the author,
5528  at least).
5529 \end_layout
5530
5531 \begin_layout Description
5532 Criterion A required condition.
5533 \end_layout
5534
5535 \begin_layout Description
5536 Algorithm A general procedure to be used.
5537 \end_layout
5538
5539 \begin_layout Description
5540 Axiom This is a property or statement taken as true within the system being
5541  discussed.
5542 \end_layout
5543
5544 \begin_layout Description
5545 Definition Guess what this is for.
5546  The font, both on-screen and in the output, is different for this environment
5547  than for the previous ones.
5548  The heading (
5549 \begin_inset Quotes eld
5550 \end_inset
5551
5552 definition
5553 \begin_inset Quotes erd
5554 \end_inset
5555
5556 ) is still set in boldface, along with the number, if any, but the rest
5557  is set upright.
5558 \end_layout
5559
5560 \begin_layout Description
5561 Example Typeset similarly to Definition.
5562 \end_layout
5563
5564 \begin_layout Description
5565 Condition
5566 \end_layout
5567
5568 \begin_layout Description
5569 Problem
5570 \end_layout
5571
5572 \begin_layout Description
5573 Exercise
5574 \end_layout
5575
5576 \begin_layout Description
5577 Remark This environment is also a new type of theorem.
5578  This is set with the word Remark in italics, and the rest upright.
5579 \end_layout
5580
5581 \begin_layout Description
5582 Note Set similarly to the Remark environment.
5583 \end_layout
5584
5585 \begin_layout Description
5586 Notation
5587 \end_layout
5588
5589 \begin_layout Description
5590 Claim
5591 \end_layout
5592
5593 \begin_layout Description
5594 Summary
5595 \end_layout
5596
5597 \begin_layout Description
5598 Acknowledgement
5599 \end_layout
5600
5601 \begin_layout Description
5602 Case Generally, these are used to break up long arguments, using specific
5603  instances of some condition.
5604  The numbering scheme for cases is on its own, not together with other numbered
5605  statements.
5606  
5607 \end_layout
5608
5609 \begin_layout Description
5610 Conclusion
5611 \end_layout
5612
5613 \begin_layout Description
5614 Fact 
5615 \end_layout
5616
5617 \begin_layout Description
5618 Proof The word 
5619 \begin_inset Quotes eld
5620 \end_inset
5621
5622
5623 \shape italic
5624 Proof
5625 \shape default
5626
5627 \begin_inset Quotes erd
5628 \end_inset
5629
5630  is set in italics, but the rest is set upright.
5631  At the end of this environment (other environments can be nested within
5632  this one, of course) a QED symbol (usually a square, but it can vary with
5633  different styles) is placed.
5634 \end_layout
5635
5636 \begin_layout Description
5637 Address This should be the author's permanent address.
5638 \end_layout
5639
5640 \begin_layout Description
5641 Current\InsetSpace ~
5642 Address This should be the author's temporary address at the time
5643  of submission, if different from the Address.
5644 \end_layout
5645
5646 \begin_layout Description
5647 Email Author's e-mail address
5648 \end_layout
5649
5650 \begin_layout Description
5651 URL Author's Web address, if desired.
5652 \end_layout
5653
5654 \begin_layout Description
5655 Keywords Key words or phrases used to identify specific topics discussed
5656  in the paper.
5657 \end_layout
5658
5659 \begin_layout Description
5660 Subjectclass These refer to the AMS Subject Classifications, published and
5661  described in 
5662 \emph on
5663 Mathematical Reviews
5664 \emph default
5665 .
5666  These are also available online at the AMS cites listed above.
5667 \end_layout
5668
5669 \begin_layout Description
5670 Thanks
5671 \end_layout
5672
5673 \begin_layout Description
5674 Dedicatory
5675 \end_layout
5676
5677 \begin_layout Description
5678 Translator
5679 \end_layout
5680
5681 \begin_layout Standard
5682 In addition, these environments automatically provide the AMS LaTeX and
5683  AMS fonts packages.
5684  They need to be available on your system in order to use these environments.
5685 \end_layout
5686
5687 \begin_layout Section
5688 Dinbrief
5689 \end_layout
5690
5691 \begin_layout Standard
5692 The document class 
5693 \family sans
5694 dinbrief
5695 \family default
5696  can be used to type letters according to German conventions.
5697  A template file is included in 
5698 \family typewriter
5699 .../lyx/share/templates
5700 \family default
5701  for you to use as a starting point.
5702 \end_layout
5703
5704 \begin_layout Section
5705 Paper
5706 \end_layout
5707
5708 \begin_layout Standard
5709 The document class 
5710 \family sans
5711 paper
5712 \family default
5713  provides an alternative to the standard 
5714 \family sans
5715 article
5716 \family default
5717  class.
5718  It provides similar functionality, but you might prefer this layout with
5719  sans serif sections, headings, and more.
5720 \end_layout
5721
5722 \begin_layout Section
5723 A&A Paper
5724 \end_layout
5725
5726 \begin_layout Standard
5727 by 
5728 \noun on
5729 Peter Sütterlin
5730 \end_layout
5731
5732 \begin_layout Subsection
5733 Introduction
5734 \end_layout
5735
5736 \begin_layout Standard
5737 This section describes how LyX can be used to write articles for submission
5738  to the scientific journal 
5739 \emph on
5740 Astronomy and Astrophysics
5741 \emph default
5742  (
5743 \begin_inset LatexCommand \url[www.edpsciences.fr/aa/]{http://www.edpsciences.fr/aa/}
5744
5745 \end_inset
5746
5747 )
5748 \emph on
5749  
5750 \emph default
5751 using
5752 \emph on
5753  
5754 \emph default
5755 Version 5.01 of the document class 
5756 \family typewriter
5757 aa.cls
5758 \family default
5759 .
5760  This package can be downloaded from the ftp site
5761 \end_layout
5762
5763 \begin_layout Standard
5764 \begin_inset VSpace medskip
5765 \end_inset
5766
5767
5768 \end_layout
5769
5770 \begin_layout Standard
5771 \align center
5772 \begin_inset LatexCommand \url{ftp://ftp.edpsciences.org/pub/aa/readme.html}
5773
5774 \end_inset
5775
5776
5777 \end_layout
5778
5779 \begin_layout Standard
5780 \begin_inset VSpace medskip
5781 \end_inset
5782
5783
5784 \end_layout
5785
5786 \begin_layout Standard
5787 A manual comes together with that package, and this text is not meant to
5788  replace the original manual but merely a short guide how to realize the
5789  correct form of your paper.
5790  
5791 \end_layout
5792
5793 \begin_layout Standard
5794 Please note that the publisher of the journal was changed from Springer
5795  to EDP Sciences starting January 1, 2001.
5796  That change implicated also some slight changes of the style files, namely
5797  the removal of the thesaurus command.
5798  The LyX class aa supports the newest version of these style files, V 5.01.
5799  If you have an older version installed, please upgrade.
5800  For compatibility, the old (version 4) layout has been kept as 
5801 \family sans
5802 article (A&A V4)
5803 \family default
5804 .
5805  Please refer to the comments in 
5806 \family typewriter
5807 LyXDir/layouts/aapaper.layout
5808 \family default
5809 .
5810 \end_layout
5811
5812 \begin_layout Subsection
5813 Getting started
5814 \end_layout
5815
5816 \begin_layout Standard
5817 It is recommended you start from the example template distributed with LyX.
5818  If you are not using a template, note the following settings:
5819 \end_layout
5820
5821 \begin_layout Itemize
5822 Select 
5823 \family sans
5824 article (A&A)
5825 \family default
5826  in the 
5827 \family sans
5828 \bar under
5829 D
5830 \bar default
5831 ocument\SpecialChar \menuseparator
5832
5833 \bar under
5834 S
5835 \bar default
5836 ettings
5837 \family default
5838  dialog (OK, that one was obvious).
5839 \end_layout
5840
5841 \begin_layout Itemize
5842 Don't change the option 
5843 \family sans
5844 Page\InsetSpace ~
5845 style
5846 \family default
5847 : Leave it set to 
5848 \family sans
5849 default
5850 \family default
5851 .
5852  The whole layout is done by the macros, you shouldn't change anything.
5853 \end_layout
5854
5855 \begin_layout Subsection
5856 The header block
5857 \end_layout
5858
5859 \begin_layout Standard
5860 First thing to enter is the header information.
5861  It consists of seven entries, of which some are optional.
5862  They are
5863 \end_layout
5864
5865 \begin_layout Itemize
5866
5867 \family sans
5868 Title
5869 \family default
5870 : [required] 
5871 \end_layout
5872
5873 \begin_layout Itemize
5874
5875 \family sans
5876 Subtitle
5877 \family default
5878 : [optional] 
5879 \end_layout
5880
5881 \begin_layout Itemize
5882
5883 \family sans
5884 Author
5885 \family default
5886 : [required]
5887 \end_layout
5888
5889 \begin_layout Itemize
5890
5891 \family sans
5892 Address
5893 \family default
5894 : [required]
5895 \end_layout
5896
5897 \begin_layout Itemize
5898
5899 \family sans
5900 Offprints
5901 \family default
5902 : [optional] if more than one author: whom to contact for offprint requests.
5903 \end_layout
5904
5905 \begin_layout Itemize
5906
5907 \family sans
5908 Mail
5909 \family default
5910 : [optional] mail address for contacts.
5911 \end_layout
5912
5913 \begin_layout Itemize
5914
5915 \family sans
5916 Date
5917 \family default
5918 : [required].
5919  Suggested format is 
5920 \family typewriter
5921 Received: <date>; Accepted <date> 
5922 \end_layout
5923
5924 \begin_layout Standard
5925 There is no need to issue the 
5926 \family typewriter
5927
5928 \backslash
5929 maketitle
5930 \family default
5931  command, this is done automatically by LyX when the header is finished.
5932  Although the order of the single header entries doesn't matter it is advised
5933  to keep the above sequence, just to get the best optics and meets the layout
5934  of the real document.
5935 \end_layout
5936
5937 \begin_layout Standard
5938 If you want to place footnotes in the header block, e.g.
5939 \begin_inset ERT
5940 status collapsed
5941
5942 \begin_layout Standard
5943
5944
5945 \backslash
5946  
5947 \end_layout
5948
5949 \end_inset
5950
5951 to state your present address, just use the standard footnote via 
5952 \family sans
5953 \bar under
5954 I
5955 \bar default
5956 nsert\SpecialChar \menuseparator
5957
5958 \bar under
5959 F
5960 \bar default
5961 ootnote.
5962  
5963 \family default
5964 LyX will automagically use the term 
5965 \family typewriter
5966
5967 \backslash
5968 thanks{}
5969 \family default
5970  in that case.
5971 \end_layout
5972
5973 \begin_layout Standard
5974 In addition to these topics, the macros use three additional LaTeX commands
5975  that have no counterpart in LyX:
5976 \end_layout
5977
5978 \begin_layout Itemize
5979
5980 \family typewriter
5981
5982 \backslash
5983 and
5984 \family default
5985  to separate different names for more than one author and institute, respectivel
5986 y.
5987 \end_layout
5988
5989 \begin_layout Itemize
5990
5991 \family typewriter
5992
5993 \backslash
5994 inst{<nr>}
5995 \family default
5996 to mark corresponding author/institute pairs.
5997  The institutes are numbered sequentially as they appear in the 
5998 \family sans
5999 Address
6000 \family default
6001  field, so you have to put a marker to each author.
6002 \end_layout
6003
6004 \begin_layout Itemize
6005
6006 \family typewriter
6007
6008 \backslash
6009 email{address}
6010 \family default
6011  to supply an email address for fast contact.
6012 \end_layout
6013
6014 \begin_layout Standard
6015 In all cases, the appropriate command has to be entered in LyX and marked
6016  as LaTeX code.
6017  See the examples.
6018  
6019 \end_layout
6020
6021 \begin_layout Subsection
6022 The abstract
6023 \end_layout
6024
6025 \begin_layout Standard
6026 The abstract should immediately follow the header block.
6027  With version 5 the abstract environment was changed to a command, and there
6028  is now a resctriction to only one paragraph.
6029  In addition, it should contain an entry with the keywords.
6030  This is not yet implemented for LyX, therefore you have to enter the LaTeX
6031  command 
6032 \family typewriter
6033
6034 \backslash
6035 keywords{}
6036 \family default
6037  by hand and mark it as LaTeX code.
6038  Refer to the example paper.
6039 \end_layout
6040
6041 \begin_layout Subsection
6042 Supported environments
6043 \end_layout
6044
6045 \begin_layout Standard
6046 The A&A paper layout supports the following environments for structuring
6047  your text:
6048 \end_layout
6049
6050 \begin_layout Itemize
6051
6052 \family sans
6053 Standard
6054 \end_layout
6055
6056 \begin_layout Itemize
6057
6058 \family sans
6059 Section
6060 \end_layout
6061
6062 \begin_layout Itemize
6063
6064 \family sans
6065 Subsection
6066 \end_layout
6067
6068 \begin_layout Itemize
6069
6070 \family sans
6071 Subsubsection
6072 \end_layout
6073
6074 \begin_layout Itemize
6075
6076 \family sans
6077 Itemize
6078 \end_layout
6079
6080 \begin_layout Itemize
6081
6082 \family sans
6083 Enumerate
6084 \end_layout
6085
6086 \begin_layout Itemize
6087
6088 \family sans
6089 Description
6090 \end_layout
6091
6092 \begin_layout Itemize
6093
6094 \family sans
6095 Caption
6096 \end_layout
6097
6098 \begin_layout Itemize
6099
6100 \family sans
6101 Abstract
6102 \end_layout
6103
6104 \begin_layout Itemize
6105
6106 \family sans
6107 Acknowledgment
6108 \end_layout
6109
6110 \begin_layout Itemize
6111
6112 \family sans
6113 Bibliography
6114 \end_layout
6115
6116 \begin_layout Itemize
6117
6118 \family sans
6119 LaTeX
6120 \end_layout
6121
6122 \begin_layout Subsection
6123 Commands not supported by LyX
6124 \end_layout
6125
6126 \begin_layout Standard
6127 Some commands are not yet supported by the 
6128 \family sans
6129 paper (A&A)
6130 \family default
6131  layout for LyX.
6132  Some have already been mentioned.
6133  For the sake of completeness, they are listed all together here:
6134 \end_layout
6135
6136 \begin_layout Itemize
6137
6138 \family typewriter
6139
6140 \backslash
6141 and
6142 \end_layout
6143
6144 \begin_layout Itemize
6145
6146 \family typewriter
6147
6148 \backslash
6149 email
6150 \end_layout
6151
6152 \begin_layout Itemize
6153
6154 \family typewriter
6155
6156 \backslash
6157 appendix
6158 \end_layout
6159
6160 \begin_layout Itemize
6161
6162 \family typewriter
6163
6164 \backslash
6165 authorrunning
6166 \end_layout
6167
6168 \begin_layout Itemize
6169
6170 \family typewriter
6171
6172 \backslash
6173 inst{}
6174 \end_layout
6175
6176 \begin_layout Itemize
6177
6178 \family typewriter
6179
6180 \backslash
6181 keywords{}
6182 \end_layout
6183
6184 \begin_layout Itemize
6185
6186 \family typewriter
6187
6188 \backslash
6189 object{}
6190 \end_layout
6191
6192 \begin_layout Itemize
6193
6194 \family typewriter
6195
6196 \backslash
6197 titlerunning{}
6198 \end_layout
6199
6200 \begin_layout Standard
6201 If you want to use any of these commands, you have to enter them yourself.
6202  
6203 \series bold
6204 Do not forget to mark them as LaTeX code!
6205 \end_layout
6206
6207 \begin_layout Subsection
6208 Figure and Table Floats
6209 \end_layout
6210
6211 \begin_layout Standard
6212 LyX provides support for the necessary float environments 
6213 \family sans
6214 figure, figure*, table 
6215 \family default
6216 and 
6217 \family sans
6218 table*
6219 \family default
6220 , therefore we won't tell much about it here.
6221  Refer to the 
6222 \emph on
6223 User's\InsetSpace ~
6224 Guide
6225 \emph default
6226 .
6227  Just remember that tables should be left-aligned.
6228  For that, select the table and change the alignment in 
6229 \family sans
6230 \bar under
6231 E
6232 \bar default
6233 dit\SpecialChar \menuseparator
6234
6235 \bar under
6236 P
6237 \bar default
6238 aragraph\InsetSpace ~
6239 Settings.
6240 \end_layout
6241
6242 \begin_layout Standard
6243 There is
6244 \family sans
6245  
6246 \family default
6247 only one special thing: the figures with caption besides the figure.
6248  To create such a figure, you have to do the following:
6249 \end_layout
6250
6251 \begin_layout Enumerate
6252 Create a wide figure float: 
6253 \family sans
6254 \bar under
6255 I
6256 \bar default
6257 nsert\SpecialChar \menuseparator
6258 Flo
6259 \bar under
6260 a
6261 \bar default
6262 t\SpecialChar \menuseparator
6263 Figure
6264 \family default
6265 , then right click in the figure and select
6266 \family sans
6267  
6268 \bar under
6269 S
6270 \bar default
6271 pan\InsetSpace ~
6272 columns
6273 \family default
6274 .
6275 \end_layout
6276
6277 \begin_layout Enumerate
6278 Enter your caption text.
6279 \end_layout
6280
6281 \begin_layout Enumerate
6282 Press 
6283 \family sans
6284 Return
6285 \family default
6286  to move the cursor above the caption.
6287 \end_layout
6288
6289 \begin_layout Enumerate
6290 Insert your figure
6291 \end_layout
6292
6293 \begin_layout Enumerate
6294 Position the cursor behind the figure and insert a horizontal fill: 
6295 \family sans
6296 \bar under
6297 I
6298 \bar default
6299 nsert\SpecialChar \menuseparator
6300
6301 \bar under
6302 S
6303 \bar default
6304 pecial\InsetSpace ~
6305 Character
6306 \bar under
6307 \SpecialChar \menuseparator
6308 H
6309 \bar default
6310 orizontal\InsetSpace ~
6311 Fill
6312 \family default
6313 .
6314 \end_layout
6315
6316 \begin_layout Enumerate
6317 Switch to LaTeX mode: 
6318 \family sans
6319 M-c\InsetSpace ~
6320 t
6321 \family default
6322 .
6323 \end_layout
6324
6325 \begin_layout Enumerate
6326 Enter 
6327 \family typewriter
6328
6329 \backslash
6330 parbox[b]{55mm}{
6331 \family default
6332 .
6333  
6334 \series bold
6335 Do not close the brace!
6336 \end_layout
6337
6338 \begin_layout Enumerate
6339 Position the cursor behind the caption text, switch to LaTeX mode and insert
6340  the closing brace: 
6341 \family sans
6342 M-c\InsetSpace ~
6343
6344 \family typewriter
6345 }
6346 \family default
6347 .
6348 \end_layout
6349
6350 \begin_layout Standard
6351 Also, refer to the figures in the example paper.
6352 \end_layout
6353
6354 \begin_layout Subsection
6355 Referee layout
6356 \end_layout
6357
6358 \begin_layout Standard
6359 For submission, the paper has to be formated in a special double-spacing
6360  layout.
6361  For this purpose, you have to give the option 
6362 \family typewriter
6363 referee
6364 \family default
6365  to the documentclass.
6366  This must be done using the extra class options field in the 
6367 \family sans
6368 \bar under
6369 D
6370 \bar default
6371 ocument\SpecialChar \menuseparator
6372
6373 \bar under
6374 S
6375 \bar default
6376 ettings
6377 \family default
6378  dialog.
6379  Just enter the string 
6380 \family typewriter
6381 referee
6382 \family default
6383  there.
6384 \end_layout
6385
6386 \begin_layout Subsection
6387 The example paper
6388 \end_layout
6389
6390 \begin_layout Standard
6391 The 
6392 \family sans
6393 Examples
6394 \family default
6395  directory contains an example paper written with LyX.
6396  It is the example paper from the original macro package, translated to
6397  LyX.
6398  Use it for inspiration, and compare the original LaTeX code with LyX way
6399  of writing.
6400 \end_layout
6401
6402 \begin_layout Section
6403 AASTeX
6404 \end_layout
6405
6406 \begin_layout Standard
6407 by 
6408 \noun on
6409 Mike Ressler
6410 \end_layout
6411
6412 \begin_layout Subsection
6413 Introduction
6414 \end_layout
6415
6416 \begin_layout Standard
6417 AASTeX is a set of macros produced by the American Astronomical Society
6418  to facilitate electronic manuscript submission to the three journals they
6419  publish: the Astrophysical Journal (including the Letters and Supplement),
6420  the Astronomical Journal, and the Publications of the Astronomical Society
6421  of the Pacific.
6422  LyX has proven to be an excellent tool for generating these documents,
6423  especially given its equation, citation, and figure handling capabilities.
6424  LyX requires version 5.0 (or higher) of these macros; preferably 5.2, which
6425  is the version described here, or higher.
6426  Versions prior to 5.0 are intended for use with LaTeX2.09 and are fundamentally
6427  incompatible with LyX.
6428  The AASTeX package may be downloaded from the AASTeX Web site
6429 \end_layout
6430
6431 \begin_layout Standard
6432 \begin_inset VSpace medskip
6433 \end_inset
6434
6435
6436 \end_layout
6437
6438 \begin_layout Standard
6439 \align center
6440 \begin_inset LatexCommand \url{http://www.journals.uchicago.edu/AAS/AASTeX}
6441
6442 \end_inset
6443
6444
6445 \end_layout
6446
6447 \begin_layout Standard
6448 \begin_inset VSpace medskip
6449 \end_inset
6450
6451
6452 \end_layout
6453
6454 \begin_layout Standard
6455 A complete user guide is contained in that package and you should familiarize
6456  yourself with it thoroughly before embarking on writing a paper in LyX.
6457  LyX will not reduce the need to figure out all the AASTeX commands, it
6458  will only reduce the drudgery of typing everything in.
6459  It is your responsibility to ensure that the final exported LaTeX document
6460  conforms completely to the requirements of the journal to which you are
6461  submitting your paper.
6462 \end_layout
6463
6464 \begin_layout Subsection
6465 Starting a New Paper
6466 \end_layout
6467
6468 \begin_layout Standard
6469 I strongly suggest that you start with the AASTeX template file.
6470  Click on 
6471 \family sans
6472 \bar under
6473 F
6474 \bar default
6475 ile\SpecialChar \menuseparator
6476 New from 
6477 \bar under
6478 T
6479 \bar default
6480 emplate
6481 \family default
6482 , enter the new file name, then choose the 
6483 \family typewriter
6484 aastex.lyx
6485 \family default
6486  template.
6487  This will show the most common fields found in a manuscript.
6488  Simply overwrite the existing text (including the brackets, 
6489 \family typewriter
6490 <>
6491 \family default
6492 ) with the correct information.
6493  Many of the AASTeX commands and environments can be implemented directly
6494  in LyX, but some cannot: most noticeably 
6495 \family typewriter
6496
6497 \backslash
6498 altaffilmark
6499 \family default
6500  and 
6501 \family typewriter
6502
6503 \backslash
6504 altaffiltext
6505 \family default
6506 , which should stick out like a sore thumb if you actually just opened the
6507  template file.
6508  For commands such as these, the LaTeX code must be entered directly and
6509  marked as such.
6510  Such commands are referred to as ERT, or Evil Red Text.
6511  I tried to minimize the amount of ERT needed in an AASTeX document, but
6512  there is still a bit more required than any of us would like.
6513 \end_layout
6514
6515 \begin_layout Subsection
6516 Finishing Your Paper
6517 \end_layout
6518
6519 \begin_layout Standard
6520 When the paper is finished to your satisfaction and previews/prints correctly,
6521  there are a few 
6522 \begin_inset Quotes eld
6523 \end_inset
6524
6525 postprocessing
6526 \begin_inset Quotes erd
6527 \end_inset
6528
6529  actions which need to be done before you submit it to the journals.
6530  
6531 \end_layout
6532
6533 \begin_layout Enumerate
6534 Export your paper as a LaTeX file (
6535 \family sans
6536 \bar under
6537 F
6538 \bar default
6539 ile\SpecialChar \menuseparator
6540
6541 \bar under
6542 E
6543 \bar default
6544 xport\SpecialChar \menuseparator
6545
6546 \bar under
6547 L
6548 \bar default
6549 aTeX
6550 \family default
6551 ).
6552  
6553 \end_layout
6554
6555 \begin_layout Enumerate
6556 Edit the resulting 
6557 \family typewriter
6558 .tex
6559 \family default
6560  file with your favorite text editor
6561 \end_layout
6562
6563 \begin_deeper
6564 \begin_layout Enumerate
6565 remove the comment lines before the 
6566 \family typewriter
6567
6568 \backslash
6569 documentclass
6570 \family default
6571  command
6572 \end_layout
6573
6574 \begin_layout Enumerate
6575 remove the 
6576 \family typewriter
6577
6578 \backslash
6579 usepackage...{fontenc}
6580 \family default
6581  line if it appears (usually just after 
6582 \family typewriter
6583
6584 \backslash
6585 documentclass
6586 \family default
6587 }; also remove the 
6588 \family typewriter
6589
6590 \backslash
6591 secnumdepth
6592 \family default
6593  line if it appears.
6594 \end_layout
6595
6596 \begin_layout Enumerate
6597 remove everything between (and including) the 
6598 \family typewriter
6599
6600 \backslash
6601 makeatletter
6602 \family default
6603  and 
6604 \family typewriter
6605
6606 \backslash
6607 makeatother
6608 \family default
6609  commands, except for any commands you specifically put into the LaTeX preamble
6610  (which should appear immediately after the 
6611 \begin_inset Quotes eld
6612 \end_inset
6613
6614 User specified LaTeX commands
6615 \begin_inset Quotes erd
6616 \end_inset
6617
6618  comment in the 
6619 \family typewriter
6620 .tex
6621 \family default
6622  file).
6623 \end_layout
6624
6625 \end_deeper
6626 \begin_layout Enumerate
6627 Run the resulting file through LaTeX to make sure it still processes correctly.
6628 \end_layout
6629
6630 \begin_layout Enumerate
6631 Reread the journal requirements to make sure your filenames and formats
6632  are correct.
6633 \end_layout
6634
6635 \begin_layout Enumerate
6636 Submit it.
6637 \end_layout
6638
6639 \begin_layout Subsection
6640 Comments On Specific Commands
6641 \end_layout
6642
6643 \begin_layout Standard
6644 I will not describe the detailed usage of the individual AASTeX commands:
6645  the AASTeX User Guide (
6646 \family typewriter
6647 aasguide.tex
6648 \family default
6649 ) gives a good description of each.
6650  Thus it's probably easiest for me to go down the list as found in the guide
6651  and offer comments where necessary.
6652  So let's begin \SpecialChar \ldots{}
6653
6654 \end_layout
6655
6656 \begin_layout Subsubsection
6657 Things that work as expected
6658 \end_layout
6659
6660 \begin_layout Standard
6661 \begin_inset ERT
6662 status inlined
6663
6664 \begin_layout Standard
6665
6666
6667 \backslash
6668 begin{sloppypar}
6669 \end_layout
6670
6671 \end_inset
6672
6673
6674 \end_layout
6675
6676 \begin_layout Standard
6677 Because they work as you might expect, I simply list them and the section
6678  they are found in: 
6679 \family typewriter
6680
6681 \backslash
6682 documentclass
6683 \family default
6684  (2.1.1), 
6685 \family typewriter
6686
6687 \backslash
6688 begin{document}
6689 \family default
6690  (2.2), 
6691 \family typewriter
6692
6693 \backslash
6694 title
6695 \family default
6696  (2.3), 
6697 \family typewriter
6698
6699 \backslash
6700 author
6701 \family default
6702  (2.3), 
6703 \family typewriter
6704
6705 \backslash
6706 affil
6707 \family default
6708  (2.3), 
6709 \family typewriter
6710
6711 \backslash
6712 abstract
6713 \family default
6714  (2.4), 
6715 \family typewriter
6716
6717 \backslash
6718 keywords
6719 \family default
6720  (2.5), 
6721 \family typewriter
6722
6723 \backslash
6724 section
6725 \family default
6726  (2.7), 
6727 \family typewriter
6728
6729 \backslash
6730 subsection
6731 \family default
6732  (2.7), 
6733 \family typewriter
6734
6735 \backslash
6736 subsubsection
6737 \family default
6738  (2.7), 
6739 \family typewriter
6740
6741 \backslash
6742 paragraph
6743 \family default
6744  (2.7),
6745 \family typewriter
6746  
6747 \backslash
6748 facility
6749 \family default
6750  (2.10), 
6751 \family typewriter
6752
6753 \backslash
6754 begin{displaymath}
6755 \family default
6756  (2.12), 
6757 \family typewriter
6758
6759 \backslash
6760 begin{equation}
6761 \family default
6762  (2.12), 
6763 \family typewriter
6764
6765 \backslash
6766 begin{eqnarray}
6767 \family default
6768  (2.12), 
6769 \family typewriter
6770
6771 \backslash
6772 begin{mathletters}
6773 \family default
6774  (2.12), 
6775 \family typewriter
6776
6777 \backslash
6778 begin{thebibliography}
6779 \family default
6780  (2.13.1), 
6781 \family typewriter
6782
6783 \backslash
6784 bibitem
6785 \family default
6786  (2.13.2), all the cite commands and their variations (2.13.2), the generic
6787  graphicx figure commands (2.14.1),
6788 \family typewriter
6789  
6790 \backslash
6791 begin{table}
6792 \family default
6793  (2.15.4), 
6794 \family typewriter
6795
6796 \backslash
6797 begin{tabular}
6798 \family default
6799  (2.15.4), 
6800 \family typewriter
6801
6802 \backslash
6803 caption
6804 \family default
6805  (2.15.4), 
6806 \family typewriter
6807
6808 \backslash
6809 label
6810 \family default
6811  (2.15.4, amongst other places), 
6812 \family typewriter
6813
6814 \backslash
6815 tablerefs
6816 \family default
6817  (2.15.5), 
6818 \family typewriter
6819
6820 \backslash
6821 tablecomments
6822 \family default
6823  (2.15.5), 
6824 \family typewriter
6825
6826 \backslash
6827 url
6828 \family default
6829  (2.17.4), 
6830 \family typewriter
6831
6832 \backslash
6833 end{document}
6834 \family default
6835  (2.18).
6836 \end_layout
6837
6838 \begin_layout Standard
6839 The following style options also work correctly: 
6840 \family typewriter
6841 longabstract
6842 \family default
6843  (2.4), 
6844 \family typewriter
6845 preprint
6846 \family default
6847  (3.2.1), 
6848 \family typewriter
6849 preprint2
6850 \family default
6851  (3.2.2), 
6852 \family typewriter
6853 eqsecnum
6854 \family default
6855  (3.3), 
6856 \family typewriter
6857 flushrt
6858 \family default
6859  (3.4).
6860  Simply put them in the 
6861 \family sans
6862 Options
6863 \family default
6864  box in 
6865 \family sans
6866 Layout\SpecialChar \menuseparator
6867 Document
6868 \family default
6869 .
6870 \end_layout
6871
6872 \begin_layout Standard
6873 \begin_inset ERT
6874 status inlined
6875
6876 \begin_layout Standard
6877
6878
6879 \backslash
6880 end{sloppypar}
6881 \end_layout
6882
6883 \end_inset
6884
6885
6886 \end_layout
6887
6888 \begin_layout Subsubsection
6889 Things that work, but require more comment
6890 \end_layout
6891
6892 \begin_layout Standard
6893 The following items work, but require a little more discussion:
6894 \end_layout
6895
6896 \begin_layout Itemize
6897 These items are reserved for use by the journal editors, but you can put
6898  them into the LaTeX preamble if you feel compelled to do so: 
6899 \family typewriter
6900
6901 \backslash
6902 received
6903 \family default
6904
6905 \family typewriter
6906
6907 \backslash
6908 revised
6909 \family default
6910
6911 \family typewriter
6912
6913 \backslash
6914 accepted
6915 \family default
6916
6917 \family typewriter
6918
6919 \backslash
6920 ccc
6921 \family default
6922
6923 \family typewriter
6924
6925 \backslash
6926 cpright
6927 \family default
6928  (all from 2.1.3)
6929 \end_layout
6930
6931 \begin_layout Itemize
6932 These items may be placed in the LaTeX preamble, and are included as blanks
6933  in the template file: 
6934 \family typewriter
6935
6936 \backslash
6937 slugcomment
6938 \family default
6939  (2.1.4), 
6940 \family typewriter
6941
6942 \backslash
6943 shorttitle
6944 \family default
6945  (2.1.5), 
6946 \family typewriter
6947
6948 \backslash
6949 shortauthors
6950 \family default
6951  (2.1.5)
6952 \end_layout
6953
6954 \begin_layout Itemize
6955
6956 \family typewriter
6957
6958 \backslash
6959 email
6960 \family default
6961  (2.3) -- can only be used 
6962 \begin_inset Quotes eld
6963 \end_inset
6964
6965 standalone
6966 \begin_inset Quotes erd
6967 \end_inset
6968
6969 , not in the middle of a paragraph.
6970  Use ERT if you need to embed it.
6971 \end_layout
6972
6973 \begin_layout Itemize
6974
6975 \family typewriter
6976
6977 \backslash
6978 and
6979 \family default
6980  (2.3) -- will have extra {} after it.
6981  This should not cause an error.
6982 \end_layout
6983
6984 \begin_layout Itemize
6985
6986 \family typewriter
6987
6988 \backslash
6989 notetoeditor
6990 \family default
6991  (2.6) -- can only be used 
6992 \begin_inset Quotes eld
6993 \end_inset
6994
6995 standalone
6996 \begin_inset Quotes erd
6997 \end_inset
6998
6999 , not in the middle of a paragraph.
7000  Use ERT if you need to embed it.
7001 \end_layout
7002
7003 \begin_layout Itemize
7004
7005 \family typewriter
7006
7007 \backslash
7008 placetable
7009 \family default
7010  (2.8) -- can't insert a cross-reference tag, you must type the tag name
7011  by hand
7012 \end_layout
7013
7014 \begin_layout Itemize
7015
7016 \family typewriter
7017
7018 \backslash
7019 placefigure
7020 \family default
7021  (2.8) -- same as for 
7022 \family typewriter
7023
7024 \backslash
7025 placetable
7026 \end_layout
7027
7028 \begin_layout Itemize
7029
7030 \family typewriter
7031
7032 \backslash
7033 acknowledgements
7034 \family default
7035  (2.9) -- will have extra {} after it.
7036  This should not cause an error.
7037 \end_layout
7038
7039 \begin_layout Itemize
7040
7041 \family typewriter
7042
7043 \backslash
7044 appendix
7045 \family default
7046  (2.11) -- will have extra {} after it.
7047  This should not cause an error.
7048 \end_layout
7049
7050 \begin_layout Itemize
7051
7052 \family typewriter
7053
7054 \backslash
7055 figcaption
7056 \family default
7057  (2.14.2) -- you can insert an optional filename argument by placing the cursor
7058  at the beginning of the text and selecting 
7059 \family sans
7060 Insert\SpecialChar \menuseparator
7061 Short Title
7062 \family default
7063 .
7064  
7065 \begin_inset Quotes eld
7066 \end_inset
7067
7068 Short Title
7069 \begin_inset Quotes erd
7070 \end_inset
7071
7072  inserts an optional argument of the type needed by 
7073 \family typewriter
7074
7075 \backslash
7076 figcaption
7077 \family default
7078 .
7079  Hopefully it will be renamed someday.
7080 \end_layout
7081
7082 \begin_layout Itemize
7083
7084 \family typewriter
7085
7086 \backslash
7087 objectname
7088 \family default
7089  (2.17.1) -- same as 
7090 \family typewriter
7091
7092 \backslash
7093 figcaption
7094 \family default
7095  for the catalog ID optional parameter
7096 \end_layout
7097
7098 \begin_layout Itemize
7099
7100 \family typewriter
7101
7102 \backslash
7103 dataset
7104 \family default
7105  (2.17.1) -- same as 
7106 \family typewriter
7107
7108 \backslash
7109 figcaption
7110 \family default
7111  for the catalog ID optional parameter
7112 \end_layout
7113
7114 \begin_layout Subsubsection
7115 Things not implemented, use ERT
7116 \end_layout
7117
7118 \begin_layout Standard
7119 \begin_inset ERT
7120 status inlined
7121
7122 \begin_layout Standard
7123
7124
7125 \backslash
7126 begin{sloppypar}
7127 \end_layout
7128
7129 \end_inset
7130
7131
7132 \end_layout
7133
7134 \begin_layout Standard
7135
7136 \family typewriter
7137
7138 \backslash
7139 altaffilmark
7140 \family default
7141  (2.3), 
7142 \family typewriter
7143
7144 \backslash
7145 altaffiltext
7146 \family default
7147  (2.3), 
7148 \family typewriter
7149
7150 \backslash
7151 eqnum
7152 \family default
7153  (2.12), 
7154 \family typewriter
7155
7156 \backslash
7157 setcounter{equation}
7158 \family default
7159  (2.12), Journal name abbreviations (2.13.4), 
7160 \family typewriter
7161
7162 \backslash
7163 figurenum
7164 \family default
7165  (2.14.1), 
7166 \family typewriter
7167
7168 \backslash
7169 epsscale
7170 \family default
7171  (2.14.1), 
7172 \family typewriter
7173
7174 \backslash
7175 plotone
7176 \family default
7177  (2.14.1), 
7178 \family typewriter
7179
7180 \backslash
7181 plottwo
7182 \family default
7183  (2.14.1), 
7184 \family typewriter
7185
7186 \backslash
7187 tablenum
7188 \family default
7189  (2.15.4), 
7190 \family typewriter
7191
7192 \backslash
7193 tableline
7194 \family default
7195  (2.15.4, insert it as the first element in the lefthand cell after where
7196  you want it.
7197  Don't use any of LyX's rules in the table), 
7198 \family typewriter
7199
7200 \backslash
7201 tablenotemark
7202 \family default
7203  (2.15.5), 
7204 \family typewriter
7205
7206 \backslash
7207 tablenotetext
7208 \family default
7209  (2.15.5), much of Misc (2.17, except 
7210 \family typewriter
7211
7212 \backslash
7213 objectname
7214 \family default
7215 ,
7216 \family typewriter
7217  
7218 \backslash
7219 dataset
7220 \family default
7221 ,
7222 \family typewriter
7223  
7224 \backslash
7225 url
7226 \family default
7227 , and 
7228 \family typewriter
7229
7230 \backslash
7231 email
7232 \family default
7233 ; see above), 
7234 \family typewriter
7235
7236 \backslash
7237 singlespace
7238 \family default
7239  (3.1), 
7240 \family typewriter
7241
7242 \backslash
7243 doublespace
7244 \family default
7245  (3.1), 
7246 \family typewriter
7247
7248 \backslash
7249 onecolumn
7250 \family default
7251  (3.2), 
7252 \family typewriter
7253
7254 \backslash
7255 twocolumn
7256 \family default
7257  (3.2)
7258 \end_layout
7259
7260 \begin_layout Standard
7261 \begin_inset ERT
7262 status inlined
7263
7264 \begin_layout Standard
7265
7266
7267 \backslash
7268 end{sloppypar}
7269 \end_layout
7270
7271 \end_inset
7272
7273
7274 \end_layout
7275
7276 \begin_layout Subsubsection
7277 Things that cannot be implemented
7278 \end_layout
7279
7280 \begin_layout Standard
7281 \SpecialChar \ldots{}
7282  at least in any meaningful sort of way, so I suggest ignoring them.
7283  They are the references environment (2.13.3), and the deluxetable environment
7284  (2.15).
7285  If you really, really need to use deluxetable, I suggest editing it in
7286  a separate file with a text editor, then using 
7287 \family sans
7288 \bar under
7289 I
7290 \bar default
7291 nsert\SpecialChar \menuseparator
7292 Chil
7293 \bar under
7294 d
7295 \bar default
7296 \InsetSpace ~
7297 Document
7298 \family default
7299  to include it in your LyX document.
7300  See the 
7301 \family typewriter
7302 aas_sample.lyx
7303 \family default
7304  file to see an example of this.
7305 \end_layout
7306
7307 \begin_layout Subsection
7308 FAQs, Tips, Tricks, and Other Ruminations
7309 \end_layout
7310
7311 \begin_layout Subsubsection
7312 Getting LyX and AASTeX to cooperate
7313 \end_layout
7314
7315 \begin_layout Standard
7316 It can be a bit tricky to get LyX to recognize a new layout and document
7317  class.
7318  When all else fails, do this:
7319 \end_layout
7320
7321 \begin_layout Enumerate
7322 Make certain that LaTeX can find AASTeX.
7323  Copy sample.tex (and perhaps table.tex) from the AASTeX distribution into
7324  a directory completely unrelated to LaTeX or AASTeX and run LaTeX on 
7325 \family typewriter
7326 sample.tex
7327 \family default
7328 .
7329 \end_layout
7330
7331 \begin_layout Enumerate
7332 Make certain that 
7333 \family typewriter
7334 aastex.layout
7335 \family default
7336  appears in 
7337 \family typewriter
7338 /usr/.../share/lyx/layouts
7339 \family default
7340  or 
7341 \family typewriter
7342 ~/.lyx/layouts
7343 \family default
7344 .
7345 \end_layout
7346
7347 \begin_layout Enumerate
7348 Rerun 
7349 \family sans
7350 \bar under
7351 T
7352 \bar default
7353 ools\SpecialChar \menuseparator
7354
7355 \bar under
7356 R
7357 \bar default
7358 econfigure
7359 \family default
7360  in LyX, then restart LyX.
7361 \end_layout
7362
7363 \begin_layout Enumerate
7364 Open a regular new file, not from a template.
7365  Does AASTeX appear in the class list in 
7366 \family sans
7367 \bar under
7368 D
7369 \bar default
7370 ocument\SpecialChar \menuseparator
7371
7372 \bar under
7373 S
7374 \bar default
7375 ettings
7376 \family default
7377 ?
7378 \end_layout
7379
7380 \begin_layout Standard
7381 If you get a warning from an existing AASTeX document about not being able
7382  to find the AASTeX layout or a message about 
7383 \begin_inset Quotes eld
7384 \end_inset
7385
7386 You should not mix title layouts with normal ones
7387 \begin_inset Quotes erd
7388 \end_inset
7389
7390 , things haven't been installed correctly.
7391 \end_layout
7392
7393 \begin_layout Subsubsection
7394 LaTeX error processing a table 
7395 \end_layout
7396
7397 \begin_layout Standard
7398 LyX, by default, attempts to center the table caption/title.
7399  This seems to produce a bad interaction in AASTeX so you should click somewhere
7400  in the caption/title, then select 
7401 \family sans
7402 \bar under
7403 E
7404 \bar default
7405 dit\SpecialChar \menuseparator
7406
7407 \bar under
7408 P
7409 \bar default
7410 aragraph\InsetSpace ~
7411 Settings
7412 \family default
7413 , then set the 
7414 \family sans
7415 Alignment
7416 \family default
7417  to 
7418 \family sans
7419 \bar under
7420 B
7421 \bar default
7422 lock
7423 \family default
7424 .
7425  This took care of it for me.
7426 \end_layout
7427
7428 \begin_layout Subsubsection
7429 References
7430 \begin_inset LatexCommand \label{cite}
7431
7432 \end_inset
7433
7434
7435 \end_layout
7436
7437 \begin_layout Standard
7438 A couple of things: 1) I have noticed some funny spacing in the reference
7439  entries in the text.
7440  When you enter the bibliography item data, make sure their is 
7441 \emph on
7442 no
7443 \emph default
7444  space between the last author and the parenthesis setting off the year;
7445  
7446 \emph on
7447 e.g.
7448  
7449 \emph default
7450 type
7451 \family typewriter
7452  Ressler(1992)
7453 \family default
7454 , not 
7455 \family typewriter
7456 Ressler (1992)
7457 \family default
7458 .
7459  2) Entering the references at all is not obvious.
7460  The easiest thing is to start typing your first reference at the end of
7461  the document, then mark it as type 
7462 \family sans
7463 References
7464 \family default
7465 .
7466  That will put a small gray box in front of what you just typed.
7467  Click on the box to fill in the rest of the information.
7468  For new references, go to the end of an existing reference and press return.
7469  That will create a new line with its own box, etc.
7470 \end_layout
7471
7472 \begin_layout Subsubsection
7473 Including EPS files
7474 \end_layout
7475
7476 \begin_layout Standard
7477 Even though AASTeX provides its own figure commands (
7478 \family typewriter
7479
7480 \backslash
7481 plotone
7482 \family default
7483 , for example), I much prefer LaTeX's standard figure commands (with the
7484  default graphicx).
7485  You can insert the 
7486 \family typewriter
7487
7488 \backslash
7489 plotone
7490 \family default
7491 , etc.\InsetSpace ~
7492 commands as ERT into a Figure Float box if you desire, but I never
7493  have much luck getting the layout right.
7494  With the standard graphics, LyX will insert a 
7495 \family typewriter
7496
7497 \backslash
7498 usepackage{graphicx}
7499 \family default
7500  command into the LaTeX preamble and handle the figures in the standard
7501  LaTeX2e way, interspersing the figures in the text.
7502  I believe ApJ accepts figures exactly this way now; AJ might still use
7503  the 
7504 \begin_inset Quotes eld
7505 \end_inset
7506
7507 stack everything at the end
7508 \begin_inset Quotes erd
7509 \end_inset
7510
7511  technique.
7512 \end_layout
7513
7514 \begin_layout Subsubsection
7515 Things I could have done, but didn't
7516 \end_layout
7517
7518 \begin_layout Standard
7519 There are a few 
7520 \begin_inset Quotes eld
7521 \end_inset
7522
7523 pretty
7524 \begin_inset Quotes erd
7525 \end_inset
7526
7527  things I could have implemented, but chose not to.
7528  For instance, I saw no point in double-spacing the text in the LyX window,
7529  even though it is double-spaced in the paper manuscript.
7530  Also, I chose not to make separate layouts for the preprint and preprint2
7531  styles.
7532  Since I assume you will spend most of your time in the plain manuscript
7533  mode anyway, I decided not to chew up more disk space with this.
7534  
7535 \end_layout
7536
7537 \begin_layout Subsection
7538 Final Caveat
7539 \end_layout
7540
7541 \begin_layout Standard
7542 Your mileage may vary.
7543  I've now had papers published by both ApJ and AJ that have had 98% of the
7544  effort done in LyX; the last 2% was the LaTeX post-processing and a few
7545  cleanups.
7546  I have had no trouble with the submission process, and I'm sure the journals
7547  were never aware that there might be a difference.
7548  So, go forth and publish!
7549 \end_layout
7550
7551 \begin_layout Section
7552 qijmpc and ijmpd
7553 \end_layout
7554
7555 \begin_layout Standard
7556 by 
7557 \noun on
7558 Panayotis Papasotiriou
7559 \end_layout
7560
7561 \begin_layout Subsection
7562 Overview
7563 \end_layout
7564
7565 \begin_layout Standard
7566 The ijmpc package is a set of macros that facilitates electronic manuscript
7567  submission to the 
7568 \emph on
7569 International Journal of Modern Physics C
7570 \emph default
7571 .
7572  Similarly, the ijmpd package is for creating manuscripts to be submitted
7573  to the 
7574 \emph on
7575 International Journal of Modern Physics D
7576 \emph default
7577 .
7578  Both journals are published by World Scientific.
7579  The corresponding document classes are named 
7580 \family typewriter
7581 ws-ijmpc.cls
7582 \family default
7583  and 
7584 \family typewriter
7585 ws-ijmpd.cls
7586 \family default
7587 , respectively.
7588  These files, together with instructions for the authors, can be downloaded
7589  from the sites 
7590 \begin_inset LatexCommand \url{http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml}
7591
7592 \end_inset
7593
7594  and 
7595 \begin_inset LatexCommand \url{http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml}
7596
7597 \end_inset
7598
7599 .
7600  Both packages are modified versions of the standard 
7601 \begin_inset Quotes eld
7602 \end_inset
7603
7604 article
7605 \begin_inset Quotes erd
7606 \end_inset
7607
7608  package, and they are almost (but not exactly) identical.
7609  Most of their features are supported by LyX.
7610  I have used LyX successfully to write articles submitted to both journals
7611  without any problem.
7612 \end_layout
7613
7614 \begin_layout Subsection
7615 Writing a paper
7616 \end_layout
7617
7618 \begin_layout Standard
7619 As usual, the easiest way to write a paper is to start with a template.
7620  Click on 
7621 \family sans
7622 \bar under
7623 F
7624 \bar default
7625 ile\SpecialChar \menuseparator
7626 New from 
7627 \bar under
7628 T
7629 \bar default
7630 emplate
7631 \family default
7632 , then choose the 
7633 \family typewriter
7634 ijmpc.lyx
7635 \family default
7636  or 
7637 \family typewriter
7638 ijmpd.lyx
7639 \family default
7640  template.
7641  This will give an (almost) empty document that includes the most common
7642  fields found in a manuscript.
7643  Simply overwrite the existing text (including the brackets, 
7644 \family typewriter
7645 <>
7646 \family default
7647 ) with your text.
7648  You should keep in mind the following remarks.
7649 \end_layout
7650
7651 \begin_layout Enumerate
7652 LyX won't let you change the font size and the page style of the document,
7653  because such modifications are not allowed by both packages.
7654 \end_layout
7655
7656 \begin_layout Enumerate
7657 The language of the document should not be changed.
7658  Before previewing your paper, be sure that the babel package is not used.
7659  To do this, click on 
7660 \family sans
7661 \bar under
7662 T
7663 \bar default
7664 ools\SpecialChar \menuseparator
7665
7666 \bar under
7667 P
7668 \bar default
7669 references
7670 \family default
7671 , select the 
7672 \family sans
7673 Lang Opts
7674 \family default
7675  tab, deselect the 
7676 \family sans
7677 \bar under
7678 U
7679 \bar default
7680 se babel
7681 \family default
7682  checkbox in the language settings, and click on 
7683 \family sans
7684 \bar under
7685 A
7686 \bar default
7687 pply
7688 \family default
7689  (or 
7690 \family sans
7691 Save
7692 \family default
7693 , if you wish to make this change permanent).
7694 \end_layout
7695
7696 \begin_layout Enumerate
7697 The 
7698 \begin_inset Quotes eld
7699 \end_inset
7700
7701 Keywords
7702 \begin_inset Quotes erd
7703 \end_inset
7704
7705  style must be used to define keywords.
7706 \end_layout
7707
7708 \begin_layout Enumerate
7709 The ijmpc package provides a style named 
7710 \begin_inset Quotes eld
7711 \end_inset
7712
7713 Classification Codes
7714 \begin_inset Quotes erd
7715 \end_inset
7716
7717 , which can be used to define classification codes, such as PACS numbers.
7718  Note that this facility is not supported by the ijmpd package.
7719 \end_layout
7720
7721 \begin_layout Enumerate
7722 Several new environments are available: 
7723 \begin_inset Quotes eld
7724 \end_inset
7725
7726 Definition
7727 \begin_inset Quotes erd
7728 \end_inset
7729
7730
7731 \begin_inset Quotes eld
7732 \end_inset
7733
7734 Step
7735 \begin_inset Quotes erd
7736 \end_inset
7737
7738
7739 \begin_inset Quotes eld
7740 \end_inset
7741
7742 Example
7743 \begin_inset Quotes erd
7744 \end_inset
7745
7746
7747 \begin_inset Quotes eld
7748 \end_inset
7749
7750 Remark
7751 \begin_inset Quotes erd
7752 \end_inset
7753
7754
7755 \begin_inset Quotes eld
7756 \end_inset
7757
7758 Notation
7759 \begin_inset Quotes erd
7760 \end_inset
7761
7762
7763 \begin_inset Quotes eld
7764 \end_inset
7765
7766 Theorem
7767 \begin_inset Quotes erd
7768 \end_inset
7769
7770
7771 \begin_inset Quotes eld
7772 \end_inset
7773
7774 Proof
7775 \begin_inset Quotes erd
7776 \end_inset
7777
7778
7779 \begin_inset Quotes eld
7780 \end_inset
7781
7782 Corollary
7783 \begin_inset Quotes erd
7784 \end_inset
7785
7786
7787 \begin_inset Quotes eld
7788 \end_inset
7789
7790 Lemma
7791 \begin_inset Quotes erd
7792 \end_inset
7793
7794
7795 \begin_inset Quotes eld
7796 \end_inset
7797
7798 Proposition
7799 \begin_inset Quotes erd
7800 \end_inset
7801
7802
7803 \begin_inset Quotes eld
7804 \end_inset
7805
7806 Prop
7807 \begin_inset Quotes erd
7808 \end_inset
7809
7810
7811 \begin_inset Quotes eld
7812 \end_inset
7813
7814 Question
7815 \begin_inset Quotes erd
7816 \end_inset
7817
7818
7819 \begin_inset Quotes eld
7820 \end_inset
7821
7822 Claim
7823 \begin_inset Quotes erd
7824 \end_inset
7825
7826 , and 
7827 \begin_inset Quotes eld
7828 \end_inset
7829
7830 Conjecture
7831 \begin_inset Quotes erd
7832 \end_inset
7833
7834 .
7835  Their use is more or less obvious.
7836  LyX supports all these environments; it will use the proper label, text
7837  style, and numbering scheme for each of them.
7838 \end_layout
7839
7840 \begin_layout Enumerate
7841 Both packages use basic citations; the natbib package should not be used.
7842  In LyX, citation references are shown as usual; in the output, citations
7843  are shown as superscripts.
7844  If you want to use a citation as normal text, you should use the 
7845 \family typewriter
7846 refcite
7847 \family default
7848  command, e.g., 
7849 \begin_inset Quotes eld
7850 \end_inset
7851
7852 See Ref.\InsetSpace ~
7853
7854 \family typewriter
7855
7856 \backslash
7857 refcite{key}
7858 \family default
7859
7860 \begin_inset Quotes erd
7861 \end_inset
7862
7863 .
7864 \end_layout
7865
7866 \begin_layout Enumerate
7867 There is no 
7868 \begin_inset Quotes eld
7869 \end_inset
7870
7871 Acknowledgments
7872 \begin_inset Quotes erd
7873 \end_inset
7874
7875  section in both packages.
7876  To put acknowledgments, just use the 
7877 \begin_inset Quotes eld
7878 \end_inset
7879
7880 Section*
7881 \begin_inset Quotes erd
7882 \end_inset
7883
7884  environment.
7885 \end_layout
7886
7887 \begin_layout Enumerate
7888 Appendices may be added to the paper, 
7889 \emph on
7890 after
7891 \emph default
7892  the Acknowledgments and 
7893 \shape italic
7894 before
7895 \shape default
7896  the References.
7897  LyX provides a special environment, called 
7898 \begin_inset Quotes eld
7899 \end_inset
7900
7901 Appendices Section
7902 \begin_inset Quotes erd
7903 \end_inset
7904
7905  which marks the beginning of the appendices.
7906  This environment should be left blank; it just sends a LaTeX command, but
7907  nothing is really printed.
7908  In LyX, the word 
7909 \begin_inset Quotes eld
7910 \end_inset
7911
7912 Appendix
7913 \begin_inset Quotes erd
7914 \end_inset
7915
7916  is printed with blue letters, as a signal that all sections after that
7917  point are appendices.
7918  To write an appendix, use the 
7919 \begin_inset Quotes eld
7920 \end_inset
7921
7922 Appendix
7923 \begin_inset Quotes erd
7924 \end_inset
7925
7926  environment.
7927  LyX will number each appendix with capital letters, as required by both
7928  journals.
7929  Note that 
7930 \begin_inset Quotes eld
7931 \end_inset
7932
7933 Appendices Section
7934 \begin_inset Quotes erd
7935 \end_inset
7936
7937  
7938 \emph on
7939 must
7940 \emph default
7941  be present before the first appendix; if not, all appendices will be numbered
7942  as normal sections in the output.
7943 \end_layout
7944
7945 \begin_layout Enumerate
7946 The ijmpc and the ijmpd packages use the 
7947 \family typewriter
7948 tbl
7949 \family default
7950  command to implement table captions.
7951  As a result, a table created by LyX is printed correctly, but its caption
7952  is ignored.
7953  However, you can use some ERT to overpass this problem, so that captions
7954  are printed as expected.
7955  To do so, create a float table as usual, remove the caption, and replace
7956  it with the ERT 
7957 \family typewriter
7958
7959 \backslash
7960 tbl{
7961 \emph on
7962 your table caption
7963 \emph default
7964 }{
7965 \family default
7966  (sic); you must also the ERT 
7967 \family typewriter
7968 }
7969 \family default
7970  immediately after the tabular material.
7971  Study the example table included in the template files to see how this
7972  trick is implemented.
7973  Alternatively, If you need table captions, you should implement the whole
7974  table float in a 
7975 \family typewriter
7976 .tex
7977 \family default
7978  file, then include this file to the LyX document (
7979 \family sans
7980 \bar under
7981 I
7982 \bar default
7983 nsert\SpecialChar \menuseparator
7984 Fil
7985 \bar under
7986 e
7987 \bar default
7988 \SpecialChar \menuseparator
7989 Chil
7990 \bar under
7991 d
7992 \bar default
7993 \InsetSpace ~
7994 Document
7995 \family default
7996 ).
7997  Details on how to create a table float can be found in the files 
7998 \family typewriter
7999 ws-ijmpc.tex
8000 \family default
8001  and 
8002 \family typewriter
8003 ws-ijmpd.tex
8004 \family default
8005 , included in the corresponding packages.
8006 \end_layout
8007
8008 \begin_layout Subsection
8009 Preparing a paper for submission
8010 \end_layout
8011
8012 \begin_layout Standard
8013 Before you submit your paper you must export the LyX document as a LaTeX
8014  file (
8015 \family sans
8016 \bar under
8017 F
8018 \bar default
8019 ile\SpecialChar \menuseparator
8020
8021 \bar under
8022 E
8023 \bar default
8024 xport\SpecialChar \menuseparator
8025
8026 \bar under
8027 L
8028 \bar default
8029 aTeX
8030 \family default
8031 )
8032 \begin_inset Foot
8033 status open
8034
8035 \begin_layout Standard
8036 Actually you have the choice between LaTeX (plain) and pdflatex.
8037  If you intend to use pdflatex to prepare the paper, you should use the
8038  pdflatex option so that included graphics are converted to PDF format,
8039  ready for use by pdflatex.
8040 \end_layout
8041
8042 \end_inset
8043
8044 , then make the following changes to the resulting 
8045 \family typewriter
8046 .tex
8047 \family default
8048  file.
8049 \end_layout
8050
8051 \begin_layout Enumerate
8052 Remove the comment lines before the 
8053 \family typewriter
8054
8055 \backslash
8056 documentclass
8057 \family default
8058  command.
8059 \end_layout
8060
8061 \begin_layout Enumerate
8062 Remove everything between (and including) the 
8063 \family typewriter
8064
8065 \backslash
8066 makeatletter
8067 \family default
8068  and 
8069 \family typewriter
8070
8071 \backslash
8072 makeatother
8073 \family default
8074  commands, except for any commands you specifically put into the LaTeX preamble.
8075 \end_layout
8076
8077 \begin_layout Standard
8078 The modified 
8079 \family typewriter
8080 .tex
8081 \family default
8082  file should be saved and processed through LaTeX as many times as necessary.
8083  You may also want to check the resulting 
8084 \family typewriter
8085 .dvi
8086 \family default
8087  document.
8088 \end_layout
8089
8090 \begin_layout Subsection
8091 Use of ERT
8092 \end_layout
8093
8094 \begin_layout Standard
8095 The use of ERT is reduced to two commands, which must be placed at the top
8096  of the document.
8097  If you started writing your paper by using the 
8098 \family typewriter
8099 ijmpc.lyx
8100 \family default
8101  or the 
8102 \family typewriter
8103 ijmpd.lyx
8104 \family default
8105  template, the ERT needed is already in its place; you usually don't need
8106  to delete it.
8107  You may only modify the first ERT to specify the information printed to
8108  the top of odd and even pages (authors' names and short paper's title,
8109  respectively).
8110  This ERT must have the form 
8111 \family typewriter
8112
8113 \backslash
8114 markboth{Authors' Names}{Short Paper's Title}
8115 \family default
8116 .
8117 \end_layout
8118
8119 \begin_layout Section
8120 Kluwer
8121 \end_layout
8122
8123 \begin_layout Standard
8124 by 
8125 \noun on
8126 Panayotis Papasotiriou
8127 \end_layout
8128
8129 \begin_layout Subsection
8130 Overview
8131 \end_layout
8132
8133 \begin_layout Standard
8134 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
8135  that facilitates electronic manuscript submission to the journals they
8136  publish.
8137  Most known of them (at least in my domain of interest) are 
8138 \emph on
8139 Astrophysics and Space Science
8140 \emph default
8141  and 
8142 \emph on
8143 Solar Physics
8144 \emph default
8145 , but there are many others (see a complete list at 
8146 \begin_inset LatexCommand \url{http://www.wkap.nl/jrnllist.htm/JRNLHOME}
8147
8148 \end_inset
8149
8150 ).
8151  The Kluwer package may be downloaded from the site 
8152 \begin_inset LatexCommand \url{http://www.wkap.nl/kaphtml.htm/STYLEFILES}
8153
8154 \end_inset
8155
8156 .
8157  A complete user guide is contained in that package (but it can also be
8158  downloaded separately).
8159 \end_layout
8160
8161 \begin_layout Standard
8162 LyX supports many features of the package but not everything.
8163  However, the ERT needed is reduced to some 
8164 \begin_inset Quotes eld
8165 \end_inset
8166
8167 peculiar
8168 \begin_inset Quotes erd
8169 \end_inset
8170
8171  commands of the package (see\InsetSpace ~
8172
8173 \begin_inset LatexCommand \ref{subsec:kluwer_peculiarities}
8174
8175 \end_inset
8176
8177 ).
8178  I have recently used LyX to write an article submitted to the 
8179 \emph on
8180 Astrophysics and Space Science
8181 \emph default
8182  without any problem.
8183 \end_layout
8184
8185 \begin_layout Subsection
8186 Writing a paper
8187 \end_layout
8188
8189 \begin_layout Standard
8190 The easiest way to write a paper is to start with the Kluwer template file.
8191  Click on 
8192 \family sans
8193 File\SpecialChar \menuseparator
8194 New from 
8195 \bar under
8196 T
8197 \bar default
8198 emplate
8199 \family default
8200 , then choose the 
8201 \family typewriter
8202 kluwer.lyx
8203 \family default
8204  template.
8205  This will give an (almost) empty document that includes the most common
8206  fields found in a manuscript and a short description of their use.
8207  As in most templates, simply overwrite the existing text (including the
8208  brackets, 
8209 \family typewriter
8210 <>
8211 \family default
8212 ) with the correct information.
8213 \end_layout
8214
8215 \begin_layout Subsection
8216 Preparing a paper for submission
8217 \end_layout
8218
8219 \begin_layout Standard
8220 As in the AASTeX package, before you submit your paper to a journal you
8221  must 
8222 \begin_inset Quotes eld
8223 \end_inset
8224
8225 postprocess
8226 \begin_inset Quotes erd
8227 \end_inset
8228
8229  it as follows.
8230 \end_layout
8231
8232 \begin_layout Enumerate
8233 Export your paper as a LaTeX file.
8234  To do this, click on 
8235 \family sans
8236 \bar under
8237 F
8238 \bar default
8239 ile\SpecialChar \menuseparator
8240
8241 \bar under
8242 E
8243 \bar default
8244 xport\SpecialChar \menuseparator
8245
8246 \bar under
8247 L
8248 \bar default
8249 aTeX
8250 \family default
8251  (plain).
8252  
8253 \end_layout
8254
8255 \begin_layout Enumerate
8256 Edit the resulting 
8257 \family typewriter
8258 .tex
8259 \family default
8260  file with a text editor and make the following changes
8261 \end_layout
8262
8263 \begin_deeper
8264 \begin_layout Enumerate
8265 remove the comment lines before the 
8266 \family typewriter
8267
8268 \backslash
8269 documentclass
8270 \family default
8271  command,
8272 \end_layout
8273
8274 \begin_layout Enumerate
8275 remove everything between (and including) the 
8276 \family typewriter
8277
8278 \backslash
8279 makeatletter
8280 \family default
8281  and 
8282 \family typewriter
8283
8284 \backslash
8285 makeatother
8286 \family default
8287  commands, except for any commands you specifically put into the LaTeX preamble.
8288 \end_layout
8289
8290 \begin_layout Standard
8291 Save the resulting 
8292 \family typewriter
8293 .tex
8294 \family default
8295  file.
8296 \end_layout
8297
8298 \end_deeper
8299 \begin_layout Enumerate
8300 Run the 
8301 \family typewriter
8302 .tex
8303 \family default
8304  file through LaTeX as many times as necessary (usually up to three).
8305 \end_layout
8306
8307 \begin_layout Enumerate
8308 View the resulting 
8309 \family typewriter
8310 .dvi
8311 \family default
8312  document using, e.g., 
8313 \family sans
8314 xdvi
8315 \family default
8316 , and check if everything is OK (it should, if you didn't make any mistakes).
8317 \end_layout
8318
8319 \begin_layout Subsection
8320 \begin_inset Quotes eld
8321 \end_inset
8322
8323 Peculiarities
8324 \begin_inset Quotes erd
8325 \end_inset
8326
8327  of the Kluwer package
8328 \begin_inset LatexCommand \label{subsec:kluwer_peculiarities}
8329
8330 \end_inset
8331
8332
8333 \end_layout
8334
8335 \begin_layout Standard
8336 The Kluwer package has the following 
8337 \begin_inset Quotes eld
8338 \end_inset
8339
8340 peculiarities
8341 \begin_inset Quotes erd
8342 \end_inset
8343
8344 .
8345 \end_layout
8346
8347 \begin_layout Enumerate
8348 It is possible to write multiple articles in the same LaTeX file
8349 \begin_inset Foot
8350 status collapsed
8351
8352 \begin_layout Standard
8353 I can't imagine any good reason to do this.
8354 \end_layout
8355
8356 \end_inset
8357
8358 .
8359  Each article must be included in the environment 
8360 \begin_inset Quotes eld
8361 \end_inset
8362
8363 article
8364 \begin_inset Quotes erd
8365 \end_inset
8366
8367 .
8368  Unfortunately, this environment cannot be omitted, even if you write just
8369  one article.
8370  Therefore, each article starts with the command 
8371 \family typewriter
8372
8373 \backslash
8374 begin{article}
8375 \family default
8376  and, obviously, ends with the command 
8377 \family typewriter
8378
8379 \backslash
8380 end{article}
8381 \family default
8382 .
8383  Although this can be implemented in LyX, I didn't included it, since it
8384  looks ugly and can confuse the novice user.
8385  Therefore, you need to enter them directly and mark them as LaTeX code
8386  (the well-known 
8387 \begin_inset Quotes eld
8388 \end_inset
8389
8390 ERT
8391 \begin_inset Quotes erd
8392 \end_inset
8393
8394 ).
8395 \end_layout
8396
8397 \begin_layout Enumerate
8398 Information given at the beginning of the article (i.e., title, subtitle,
8399  author, institution, running title, running author, abstract and keywords)
8400  must be included in an environment called 
8401 \begin_inset Quotes eld
8402 \end_inset
8403
8404 opening
8405 \begin_inset Quotes erd
8406 \end_inset
8407
8408 .
8409  This is not implemented in LyX, so you must enter title, subtitle etc.\InsetSpace \space{}
8410 between
8411  two ERT lines (
8412 \family typewriter
8413
8414 \backslash
8415 begin{opening}
8416 \family default
8417  and 
8418 \family typewriter
8419
8420 \backslash
8421 end{opening}
8422 \family default
8423 ).
8424 \end_layout
8425
8426 \begin_layout Enumerate
8427 According to the user manual, the label of each bibliography item must be
8428  written as 
8429 \family typewriter
8430
8431 \backslash
8432 protect
8433 \backslash
8434 citeauthoryear{
8435 \family default
8436 \emph on
8437 author(s)
8438 \family typewriter
8439 \emph default
8440 }{
8441 \family default
8442 \emph on
8443 year
8444 \family typewriter
8445 \emph default
8446 }
8447 \family default
8448 .
8449 \end_layout
8450
8451 \begin_layout Standard
8452 The 
8453 \family typewriter
8454 kluwer.lyx
8455 \family default
8456  template takes care of all these 
8457 \begin_inset Quotes eld
8458 \end_inset
8459
8460 peculiarities
8461 \begin_inset Quotes erd
8462 \end_inset
8463
8464 .
8465  If you start a new paper using this template you don't need to do anything
8466  special.
8467  Just 
8468 \end_layout
8469
8470 \begin_layout Enumerate
8471 don't delete the ERT included in the template, and
8472 \end_layout
8473
8474 \begin_layout Enumerate
8475 copy the example bibliography item included in the template and modify it
8476  as necessary to enter new bibliography items.
8477 \end_layout
8478
8479 \begin_layout Section
8480 Koma-Script
8481 \end_layout
8482
8483 \begin_layout Standard
8484 by 
8485 \noun on
8486 Bernd Rellermeyer
8487 \end_layout
8488
8489 \begin_layout Subsection
8490 Overview
8491 \end_layout
8492
8493 \begin_layout Standard
8494 The LyX document classes
8495 \emph on
8496  article (koma-script)
8497 \emph default
8498
8499 \emph on
8500 report (koma-script)
8501 \emph default
8502
8503 \emph on
8504 book
8505 \emph default
8506  
8507 \emph on
8508 (koma-script)
8509 \emph default
8510 , and 
8511 \emph on
8512 letter
8513 \emph default
8514  
8515 \emph on
8516 (koma-script)
8517 \emph default
8518  correspond to the LaTeX document classes 
8519 \family typewriter
8520 scrartcl.cls
8521 \family default
8522
8523 \family typewriter
8524 scrreprt.cls
8525 \family default
8526
8527 \family typewriter
8528 scrbook.cls
8529 \family default
8530 , and 
8531 \family typewriter
8532 scrlettr.cls
8533 \family default
8534 , resp.
8535  of the Koma-Script family.
8536  They are replacements for the standard document classes 
8537 \family typewriter
8538 article.cls
8539 \family default
8540
8541 \family typewriter
8542 report.cls
8543 \family default
8544
8545 \family typewriter
8546 book.cls
8547 \family default
8548  and 
8549 \family typewriter
8550 letter.cls
8551 \family default
8552 , resp., and fit better to European typography conventions in a number of
8553  points.
8554 \end_layout
8555
8556 \begin_layout Itemize
8557 Standard character size is 11pt in 
8558 \emph on
8559 article (koma-script)
8560 \emph default
8561
8562 \emph on
8563 report (koma-script)
8564 \emph default
8565 , and 
8566 \emph on
8567 book (koma-script)
8568 \emph default
8569 , and 12pt in 
8570 \emph on
8571 letter (koma-script)
8572 \emph default
8573 .
8574 \end_layout
8575
8576 \begin_layout Itemize
8577 Headings, labels of the description environment, and a number of elements
8578  of the 
8579 \emph on
8580 letter (koma-script) 
8581 \emph default
8582 document class are set in a bold sans serif font.
8583 \begin_inset Foot
8584 status collapsed
8585
8586 \begin_layout Standard
8587 There is a big difference between the bold sans serif old cm fonts and new
8588  ec fonts, especially in the appearance of headings.
8589  In comparison, the ec bold sans serif fonts look a bit thin.
8590  Here the LaTeX package 
8591 \family typewriter
8592 cmsd.sty by 
8593 \family default
8594 \shape smallcaps
8595 Walter Schmidt
8596 \shape default
8597  helps to produce the 
8598 \begin_inset Quotes eld
8599 \end_inset
8600
8601 usual
8602 \begin_inset Quotes erd
8603 \end_inset
8604
8605  appearance when using the ec fonts.
8606 \end_layout
8607
8608 \end_inset
8609
8610  The numbering of chapter headings is made in the same way as the numbering
8611  of section headings, that is without the extra line 
8612 \begin_inset Quotes eld
8613 \end_inset
8614
8615 Chapter\SpecialChar \ldots{}
8616
8617 \begin_inset Quotes erd
8618 \end_inset
8619
8620 .
8621  In addition, the appearance of the headings can be modified by using a
8622  number of options (in LyX to be entered in the field 
8623 \family sans
8624 E
8625 \bar under
8626 x
8627 \bar default
8628 tra\InsetSpace ~
8629 Options
8630 \family default
8631  of the dialog 
8632 \family sans
8633 \bar under
8634 L
8635 \bar default
8636 ayout\SpecialChar \menuseparator
8637
8638 \bar under
8639 D
8640 \bar default
8641 ocument
8642 \family default
8643 ).
8644  A detailed German description of these options can be found in the Koma-Script
8645  documentation 
8646 \emph on
8647 scrguide
8648 \emph default
8649 .
8650 \end_layout
8651
8652 \begin_layout Itemize
8653 The main means in the Koma-Script document classes to design the type area
8654  are the options 
8655 \family sans
8656 BCOR
8657 \family default
8658  and 
8659 \family sans
8660 DIV
8661 \family default
8662  (in LyX to be entered in the extra class options field in the dialog 
8663 \family sans
8664 \bar under
8665 D
8666 \bar default
8667 ocument\SpecialChar \menuseparator
8668
8669 \bar under
8670 S
8671 \bar default
8672 ettings
8673 \family default
8674 ).
8675  They make a clearer modification of page margins possible as do the options
8676  of the dialog 
8677 \family sans
8678 \bar under
8679 D
8680 \bar default
8681 ocument\SpecialChar \menuseparator
8682
8683 \bar under
8684 S
8685 \bar default
8686 ettings
8687 \family default
8688 .
8689  A detailed German description of these and other type area options can
8690  be found in the Koma-Script documentation 
8691 \emph on
8692 scrguide
8693 \emph default
8694 .
8695 \end_layout
8696
8697 \begin_layout Itemize
8698 The LaTeX document classes of the Koma-Script family define a number of
8699  additional commands.
8700  Those part of it which makes sense in LyX is implemented in corresponding
8701  paragraph types.
8702 \end_layout
8703
8704 \begin_layout Standard
8705 A detailed German description of the LaTeX document classes of the Koma-Script
8706  family can be found in the Koma-Script documentation 
8707 \emph on
8708 scrguide
8709 \emph default
8710 .
8711 \begin_inset Foot
8712 status collapsed
8713
8714 \begin_layout Standard
8715 There is an English translation 
8716 \emph on
8717 screnggu
8718 \emph default
8719 , but it is not a complete one.
8720 \end_layout
8721
8722 \end_inset
8723
8724  The following sections describe only those aspects, which are relevant
8725  in LyX.
8726 \end_layout
8727
8728 \begin_layout Subsection
8729 article (koma-script), report (koma-script), and book (koma-script)
8730 \end_layout
8731
8732 \begin_layout Standard
8733 The document classes 
8734 \emph on
8735 article (koma-script)
8736 \emph default
8737
8738 \emph on
8739 report (koma-script)
8740 \emph default
8741 , and 
8742 \emph on
8743 book
8744 \emph default
8745  
8746 \emph on
8747 (koma-script)
8748 \emph default
8749  are implemented in the layout files 
8750 \family typewriter
8751 scrartcl.layout
8752 \family default
8753
8754 \family typewriter
8755 scrreprt.layout
8756 \family default
8757 , and 
8758 \family typewriter
8759 scrbook.layout
8760 \family default
8761 , resp.
8762  They contain all the paragraph types of the corresponding standard document
8763  classes 
8764 \emph on
8765 article
8766 \emph default
8767
8768 \emph on
8769 report
8770 \emph default
8771 , and 
8772 \emph on
8773 book
8774 \emph default
8775 , resp., partly modified, with the exception of the LyX specific 
8776 \family sans
8777 List
8778 \family default
8779 -type, which is replaced by the new 
8780 \family sans
8781 Labeling
8782 \family default
8783 -type having the same functionality.
8784  Beside the 
8785 \family sans
8786 Labeling
8787 \family default
8788 -Type there is a number of new paragraph types added.
8789  They are 
8790 \emph on
8791 not
8792 \emph default
8793  part of 
8794 \emph on
8795 letter (koma-script)
8796 \emph default
8797 .
8798 \end_layout
8799
8800 \begin_layout Itemize
8801
8802 \family sans
8803 Addpart, Addchap
8804 \family default
8805
8806 \family sans
8807 Addsec
8808 \family default
8809 : are equivalents to 
8810 \family sans
8811 Part*, Chapter*
8812 \family default
8813  and 
8814 \family sans
8815 Section*
8816 \family default
8817 , resp., additionally inserting an entry in the table of contents.
8818  
8819 \family sans
8820 Addpart 
8821 \family default
8822 and
8823 \family sans
8824  Addchap
8825 \family default
8826  are not contained in 
8827 \emph on
8828 article (koma-script)
8829 \emph default
8830 .
8831 \end_layout
8832
8833 \begin_layout Itemize
8834
8835 \family sans
8836 Addchap*
8837 \family default
8838
8839 \family sans
8840 Addsec*
8841 \family default
8842 : behave exactly as 
8843 \family sans
8844 Addchap
8845 \family default
8846  and 
8847 \family sans
8848 Addsec
8849 \family default
8850 , resp., additionally clearing running heads.
8851
8852 \family sans
8853  Addchap*
8854 \family default
8855  is not contained in 
8856 \emph on
8857 article (koma-script)
8858 \emph default
8859 .
8860 \begin_inset Foot
8861 status collapsed
8862
8863 \begin_layout Standard
8864 There is also an 
8865 \family typewriter
8866
8867 \backslash
8868 addpart*
8869 \family default
8870  command in 
8871 \emph on
8872 book (koma-script)
8873 \emph default
8874  and in 
8875 \emph on
8876 report (koma-script)
8877 \emph default
8878 , but since this is identical to 
8879 \family sans
8880 Part*
8881 \family default
8882 , is has not been implemented in LyX.
8883 \end_layout
8884
8885 \end_inset
8886
8887
8888 \end_layout
8889
8890 \begin_layout Itemize
8891
8892 \family sans
8893 Minisec
8894 \family default
8895 : generates a heading directly above the following paragraph in the standard
8896  character size without affecting the structure of the document.
8897 \end_layout
8898
8899 \begin_layout Itemize
8900
8901 \family sans
8902 Captionabove
8903 \family default
8904  and 
8905 \family sans
8906 Captionbelow 
8907 \family default
8908 are special captions which respect the different space settings needed for
8909  captions placed above or below an element (if you follow strict typographic
8910  rules, you might want to place table captions always above the table).
8911  You can also use the class option 
8912 \family typewriter
8913 tablecaptionsabove
8914 \family default
8915 , which will switch 
8916 \family sans
8917 caption
8918 \family default
8919  to 
8920 \family sans
8921 captionabove
8922 \family default
8923  for tables and 
8924 \family sans
8925 captionbelow
8926 \family default
8927  for figures.
8928  You need at least Koma-Script version 2.8q to use this.
8929 \end_layout
8930
8931 \begin_layout Itemize
8932
8933 \family sans
8934 Dictum
8935 \family default
8936 : can be used to set a bonmot, e.
8937 \begin_inset ERT
8938 status collapsed
8939
8940 \begin_layout Standard
8941
8942
8943 \backslash
8944 ,
8945 \end_layout
8946
8947 \end_inset
8948
8949 g.
8950 \begin_inset ERT
8951 status collapsed
8952
8953 \begin_layout Standard
8954
8955
8956 \backslash
8957  
8958 \end_layout
8959
8960 \end_inset
8961
8962 at the beginning of a chapter.
8963  If you use the optional argument (
8964 \family sans
8965 \bar under
8966 I
8967 \bar default
8968 nsert\SpecialChar \menuseparator
8969 Short\InsetSpace ~
8970 Title
8971 \family default
8972 ), you can insert the dictum's author there.
8973  Dictum and author are separated by a line.
8974  You need at least Koma-Script version 2.8q to use this.
8975  
8976 \family sans
8977 Dictum
8978 \family default
8979  is not contained in 
8980 \emph on
8981 article (koma-script)
8982 \emph default
8983 .
8984 \end_layout
8985
8986 \begin_layout Standard
8987 The following types, together with the standard types 
8988 \family sans
8989 Title
8990 \family default
8991
8992 \family sans
8993 Author
8994 \family default
8995 , and 
8996 \family sans
8997 Date
8998 \family default
8999 , form the title area of the document.
9000  They must be entered ahead of the first 
9001 \begin_inset Quotes eld
9002 \end_inset
9003
9004 ordinary
9005 \begin_inset Quotes erd
9006 \end_inset
9007
9008  paragraph.
9009 \begin_inset Foot
9010 status collapsed
9011
9012 \begin_layout Standard
9013 The corresponding LaTeX commands must appear before the 
9014 \family typewriter
9015
9016 \backslash
9017 maketitle
9018 \family default
9019  command.
9020 \end_layout
9021
9022 \end_inset
9023
9024  When such a type is used more than once, the latter usage overwrites the
9025  former one, that means, for every type only the latest usage is valid.
9026  The order of the different types however has, like 
9027 \family sans
9028 Title
9029 \family default
9030
9031 \family sans
9032 Author
9033 \family default
9034 , and 
9035 \family sans
9036 Date
9037 \family default
9038 , no effect on the appearance of the produced document.
9039 \end_layout
9040
9041 \begin_layout Itemize
9042
9043 \family sans
9044 Subject
9045 \family default
9046 : produces a centered paragraph above the ordinary title (
9047 \family sans
9048 Title
9049 \family default
9050
9051 \family sans
9052 Author
9053 \family default
9054
9055 \family sans
9056 Date
9057 \family default
9058 ) for the subject of the document.
9059 \end_layout
9060
9061 \begin_layout Itemize
9062
9063 \family sans
9064 Publishers
9065 \family default
9066 : produces a centered paragraph below the ordinary title (
9067 \family sans
9068 Title
9069 \family default
9070
9071 \family sans
9072 Author
9073 \family default
9074
9075 \family sans
9076 Date
9077 \family default
9078 ) for the publishers' name.
9079 \end_layout
9080
9081 \begin_layout Itemize
9082
9083 \family sans
9084 Dedication
9085 \family default
9086 : in 
9087 \emph on
9088 report (koma-script)
9089 \emph default
9090  and 
9091 \emph on
9092 book (koma-script)
9093 \emph default
9094  produces a centered paragraph on its own page behind the title page, or
9095  in 
9096 \emph on
9097 article (koma-script)
9098 \emph default
9099  produces a centered paragraph below the ordinary title (
9100 \family sans
9101 Title
9102 \family default
9103
9104 \family sans
9105 Author
9106 \family default
9107
9108 \family sans
9109 Date
9110 \family default
9111
9112 \family sans
9113 Publishers
9114 \family default
9115 ) for a dedication.
9116 \end_layout
9117
9118 \begin_layout Itemize
9119
9120 \family sans
9121 Titlehead
9122 \family default
9123 : produces a left aligned paragraph above the ordinary title (
9124 \family sans
9125 Title
9126 \family default
9127
9128 \family sans
9129 Author
9130 \family default
9131
9132 \family sans
9133 Date
9134 \family default
9135
9136 \family sans
9137 Subject
9138 \family default
9139 ) for a document`s head.
9140 \end_layout
9141
9142 \begin_layout Itemize
9143
9144 \family sans
9145 Uppertitleback
9146 \family default
9147 : produces in a double-sided print in 
9148 \emph on
9149 report (koma-script)
9150 \emph default
9151  and 
9152 \emph on
9153 book (koma-script)
9154 \emph default
9155  a left-aligned paragraph at the top of the title page`s back or has no
9156  effect in a single-sided print or in 
9157 \emph on
9158 article (koma-script)
9159 \emph default
9160 .
9161 \end_layout
9162
9163 \begin_layout Itemize
9164
9165 \family sans
9166 Lowertitleback
9167 \family default
9168 : produces in a double-sided print in 
9169 \emph on
9170 report (koma-script)
9171 \emph default
9172  and 
9173 \emph on
9174 book (koma-script)
9175 \emph default
9176  a left-aligned paragraph at the bottom of the title page`s back or has
9177  no effect in a single-sided print or in 
9178 \emph on
9179 article (koma-script)
9180 \emph default
9181 .
9182 \end_layout
9183
9184 \begin_layout Itemize
9185
9186 \family sans
9187 Extratitle
9188 \family default
9189 : produces a special 
9190 \begin_inset Quotes eld
9191 \end_inset
9192
9193 dirty
9194 \begin_inset Quotes erd
9195 \end_inset
9196
9197  page ahead of the actual document containing a paragraph without special
9198  formatting.
9199 \end_layout
9200
9201 \begin_layout Standard
9202 The layout files for the document classes 
9203 \emph on
9204 article (koma-script)
9205 \emph default
9206
9207 \emph on
9208 report (koma-script)
9209 \emph default
9210 , and 
9211 \emph on
9212 book (koma-script)
9213 \emph default
9214  do include the file 
9215 \family typewriter
9216 scrmacros.inc
9217 \family default
9218 .
9219  This is thought of as a place to define your own types.
9220  Copy s
9221 \family typewriter
9222 crmacros.inc
9223 \family default
9224  in your personal layout directory and edit the file!
9225 \end_layout
9226
9227 \begin_layout Subsection
9228 letter (koma-script)
9229 \end_layout
9230
9231 \begin_layout Standard
9232 \begin_inset ERT
9233 status inlined
9234
9235 \begin_layout Standard
9236
9237
9238 \backslash
9239 begin{sloppypar}
9240 \end_layout
9241
9242 \end_inset
9243
9244
9245 \end_layout
9246
9247 \begin_layout Standard
9248 \noindent
9249 The document class 
9250 \emph on
9251 letter (koma-script)
9252 \emph default
9253  is implemented in the layout file 
9254 \family typewriter
9255 scrlettr.layout
9256 \family default
9257 .
9258  It contains all the paragraph types of the corresponding standard document
9259  class 
9260 \emph on
9261 letter
9262 \emph default
9263 , partly modified, with the exception of the LyX specific types 
9264 \family sans
9265 LyX-Code
9266 \family default
9267  and 
9268 \family sans
9269 Comment
9270 \family default
9271  and the 
9272 \family sans
9273 List
9274 \family default
9275  type, which is replaced by the new 
9276 \family sans
9277 Labeling
9278 \family default
9279  type.
9280  In addition, it contains, in contrast to the standard document class, the
9281  standard types 
9282 \family sans
9283 LaTeX
9284 \family default
9285
9286 \family sans
9287 Quotation
9288 \family default
9289
9290 \family sans
9291 Quote
9292 \family default
9293 , and 
9294 \family sans
9295 Verse
9296 \family default
9297 .
9298  Furthermore, there are a number of new letter specific types.
9299 \end_layout
9300
9301 \begin_layout Standard
9302 \begin_inset ERT
9303 status inlined
9304
9305 \begin_layout Standard
9306
9307
9308 \backslash
9309 end{sloppypar}
9310 \end_layout
9311
9312 \end_inset
9313
9314
9315 \end_layout
9316
9317 \begin_layout Standard
9318 The appearance of the letter produced by this document class can be controlled
9319  by a number of LaTeX commands, which you can put in the LaTeX preamble.
9320 \begin_inset Foot
9321 status collapsed
9322
9323 \begin_layout Standard
9324 For example, the standard appearance of the letter`s heading, consisting
9325  of name and address, is quite self-willed.
9326  An 
9327 \begin_inset Quotes eld
9328 \end_inset
9329
9330 ordinary
9331 \begin_inset Quotes erd
9332 \end_inset
9333
9334  heading is produced by the following LaTeX commands in the preamble:
9335 \end_layout
9336
9337 \begin_layout LyX-Code
9338
9339 \backslash
9340 firsthead{
9341 \backslash
9342 parbox[b]{
9343 \backslash
9344 textwidth}
9345 \end_layout
9346
9347 \begin_layout LyX-Code
9348   {
9349 \backslash
9350 ignorespaces 
9351 \backslash
9352 fromname
9353 \backslash
9354
9355 \backslash
9356  
9357 \backslash
9358 ignorespaces 
9359 \backslash
9360 fromaddress}} 
9361 \end_layout
9362
9363 \begin_layout LyX-Code
9364
9365 \backslash
9366 nexthead{
9367 \backslash
9368 parbox[b]{
9369 \backslash
9370 textwidth}
9371 \end_layout
9372
9373 \begin_layout LyX-Code
9374   {
9375 \backslash
9376 ignorespaces 
9377 \backslash
9378 fromname 
9379 \backslash
9380 hfill 
9381 \backslash
9382 ignorespaces 
9383 \backslash
9384 pagename
9385 \backslash
9386  
9387 \backslash
9388 thepage}}
9389 \end_layout
9390
9391 \end_inset
9392
9393  A detailed German description of such LaTeX commands can be found in the
9394  Koma-Script documentation 
9395 \emph on
9396 scrguide
9397 \emph default
9398 .
9399  With it, the letter's author can produce his personal letter layout.
9400 \end_layout
9401
9402 \begin_layout Standard
9403 The types 
9404 \family sans
9405 Letter 
9406 \family default
9407 and 
9408 \family sans
9409 Opening
9410 \family default
9411  define the beginning of the letter and must be used in every letter.
9412  To emphasize them in the LyX document class, they are marked with the letter
9413  
9414 \shape italic
9415 L
9416 \shape default
9417  or 
9418 \shape italic
9419 O
9420 \shape default
9421 , resp.\InsetSpace \space{}
9422 in the left margin.
9423  It is possible to write any number of letters in one file.
9424  An 
9425 \family sans
9426 Opening
9427 \family default
9428  type produces a new letter using the same addressee and a 
9429 \family sans
9430 Letter
9431 \family default
9432  type produces a new addressee.
9433  The types 
9434 \family sans
9435 Closing
9436 \family default
9437
9438 \family sans
9439 PS
9440 \family default
9441
9442 \family sans
9443 CC
9444 \family default
9445 , and 
9446 \family sans
9447 Encl
9448 \family default
9449  are ordinary paragraph types and can also be used several times in one
9450  and the same letter.
9451 \end_layout
9452
9453 \begin_layout Itemize
9454
9455 \family sans
9456 Letter
9457 \family default
9458 : produces a paragraph for the addressee and implicitly defines the beginning
9459  of the letter.
9460 \end_layout
9461
9462 \begin_layout Itemize
9463
9464 \family sans
9465 Opening
9466 \family default
9467 : produces a paragraph for the form of address and implicitly produces a
9468  new letter.
9469 \end_layout
9470
9471 \begin_layout Itemize
9472
9473 \family sans
9474 Closing
9475 \family default
9476 : produces a paragraph for a close.
9477 \end_layout
9478
9479 \begin_layout Itemize
9480
9481 \family sans
9482 PS
9483 \family default
9484 : produces a paragraph for a postscript.
9485 \end_layout
9486
9487 \begin_layout Itemize
9488
9489 \family sans
9490 CC
9491 \family default
9492 : produces a paragraph for a distribution list.
9493 \end_layout
9494
9495 \begin_layout Itemize
9496
9497 \family sans
9498 Encl
9499 \family default
9500 : produces a paragraph for enclosures.
9501 \end_layout
9502
9503 \begin_layout Standard
9504 The types 
9505 \family sans
9506 Name
9507 \family default
9508
9509 \family sans
9510 Signature
9511 \family default
9512
9513 \family sans
9514 Address
9515 \family default
9516 ,
9517 \family sans
9518  Telephone
9519 \family default
9520
9521 \family sans
9522 Place
9523 \family default
9524
9525 \family sans
9526 Backaddress
9527 \family default
9528
9529 \family sans
9530 Specialmail
9531 \family default
9532
9533 \family sans
9534 Location
9535 \family default
9536
9537 \family sans
9538 Title
9539 \family default
9540 , and 
9541 \family sans
9542 Subject
9543 \family default
9544  are input types provided with a label to enter information, which will
9545  be processed by the document class.
9546 \begin_inset Foot
9547 status collapsed
9548
9549 \begin_layout Standard
9550 It could be seen as inconsequential, that the types 
9551 \family sans
9552 Letter
9553 \family default
9554  and 
9555 \family sans
9556 Opening
9557 \family default
9558  described above are not such input types as well.
9559  Because of the special meaning of those types, however, I have implemented
9560  them as ordinary paragraph types with a one letter mark in the left margin.
9561  Moreover, it would affect my feeling of symmetry, if the 
9562 \family sans
9563 Opening
9564 \family default
9565  type and the 
9566 \family sans
9567 Closing
9568 \family default
9569  type had such a serious different appearance.
9570 \end_layout
9571
9572 \end_inset
9573
9574  The types must be used ahead of the corresponding 
9575 \family sans
9576 Opening
9577 \family default
9578  type.
9579 \end_layout
9580
9581 \begin_layout Standard
9582 An implementation of these types in a WYSIWYG fashion does not seem to make
9583  sense, because the real appearance of the produced letter does not only
9584  depend on the usage of the particular type, but also on other factors.
9585  For example, a signature entered in the 
9586 \family sans
9587 Signature
9588 \family default
9589  type will in the standard behavior appear in the produced letter only,
9590  when in the same letter also a 
9591 \family sans
9592 Closing
9593 \family default
9594  type is used.
9595  The entered value of the 
9596 \family sans
9597 Telephone
9598 \family default
9599  type will in the standard behavior not appear in the produced letter at
9600  all.
9601  The possibility to design the letter`s heading freely is already indicated
9602  in a footnote above.
9603 \end_layout
9604
9605 \begin_layout Standard
9606 The input types can also be used as empty paragraphs.
9607  This makes sense e.\InsetSpace ~
9608 g.\InsetSpace \space{}
9609 for the 
9610 \family sans
9611 Signature
9612 \family default
9613  type.
9614  If the 
9615 \family sans
9616 Signature
9617 \family default
9618  type is not used at all, in the standard behavior the value of the 
9619 \family sans
9620 Name
9621 \family default
9622  type is used as signature, whereas if an empty 
9623 \family sans
9624 Signature
9625 \family default
9626  type is used, no signature value is defined.
9627 \end_layout
9628
9629 \begin_layout Standard
9630 By using the input types it is possible to write a letter template, containing
9631  filled input types with your personal dates (name, address, etc.) and empty
9632  input types for other dates you want to enter.
9633 \end_layout
9634
9635 \begin_layout Itemize
9636
9637 \family sans
9638 Name
9639 \family default
9640 : sender's name, in the standard behavior appears as a centered paragraph
9641  in small caps in the letter`s heading.
9642 \end_layout
9643
9644 \begin_layout Itemize
9645
9646 \family sans
9647 Signature
9648 \family default
9649 : sender's signature, in the standard behavior appears below the 
9650 \family sans
9651 Closing
9652 \family default
9653  type.
9654  If no 
9655 \family sans
9656 Signature
9657 \family default
9658  type is used, the value of the 
9659 \family sans
9660 Name
9661 \family default
9662  type appears instead.
9663 \end_layout
9664
9665 \begin_layout Itemize
9666
9667 \family sans
9668 Address
9669 \family default
9670 : sender's address, in the standard behavior appears in a centered paragraph
9671  in the letter`s heading below the sender's name.
9672 \end_layout
9673
9674 \begin_layout Itemize
9675
9676 \family sans
9677 Telephone
9678 \family default
9679 : sender's telephone number, in the standard behavior only sets the LaTeX
9680  variable 
9681 \family typewriter
9682
9683 \backslash
9684 telephonenum
9685 \family default
9686 .
9687 \end_layout
9688
9689 \begin_layout Itemize
9690
9691 \family sans
9692 Place
9693 \family default
9694 : place of the letter`s making.
9695 \end_layout
9696
9697 \begin_layout Itemize
9698
9699 \family sans
9700 Date
9701 \family default
9702 : date of the letter`s making.
9703  
9704 \family sans
9705 Place
9706 \family default
9707  and 
9708 \family sans
9709 Date
9710 \family default
9711 , in the standard behavior, produce the place and the date in a right-aligned
9712  line below the addressee's field.
9713  If an empty 
9714 \family sans
9715 Date
9716 \family default
9717  type is used, neither place nor date appear, independent of the value of
9718  the 
9719 \family sans
9720 Place
9721 \family default
9722  type.
9723  If no 
9724 \family sans
9725 Date
9726 \family default
9727  type is used, the date of the letter `s production is used.
9728 \end_layout
9729
9730 \begin_layout Itemize
9731
9732 \family sans
9733 Backaddress
9734 \family default
9735 : sender`s back address, in the standard behavior appears above the addressee's
9736  field in a small sans serif font.
9737 \end_layout
9738
9739 \begin_layout Itemize
9740
9741 \family sans
9742 Specialmail
9743 \family default
9744 : special mail information, in the standard behavior appears underlined
9745  above the addressee's field below the back address.
9746 \end_layout
9747
9748 \begin_layout Itemize
9749
9750 \family sans
9751 Location
9752 \family default
9753 : additional information, in the standard behavior appears on right side
9754  below the addressee`s field.
9755 \end_layout
9756
9757 \begin_layout Itemize
9758
9759 \family sans
9760 Title
9761 \family default
9762 : the letter's title, in the standard behavior appears in a big, bold, sans
9763  serif font above the subject.
9764 \end_layout
9765
9766 \begin_layout Itemize
9767
9768 \family sans
9769 Subject
9770 \family default
9771 : the letter's subject, in the standard behavior appears in a bold font
9772  above the 
9773 \family sans
9774 Opening
9775 \family default
9776  paragraph.
9777 \end_layout
9778
9779 \begin_layout Standard
9780 The types 
9781 \family sans
9782 Yourref
9783 \family default
9784
9785 \family sans
9786 Yourmail
9787 \family default
9788
9789 \family sans
9790 Myref
9791 \family default
9792
9793 \family sans
9794 Customer
9795 \family default
9796 , and 
9797 \family sans
9798 Invoice
9799 \family default
9800  produce a business letter like line above the 
9801 \family sans
9802 Title
9803 \family default
9804  line containing the fields 
9805 \begin_inset Quotes eld
9806 \end_inset
9807
9808 Your ref.
9809 \begin_inset Quotes erd
9810 \end_inset
9811
9812
9813 \begin_inset Quotes eld
9814 \end_inset
9815
9816 Your letter of
9817 \begin_inset Quotes erd
9818 \end_inset
9819
9820
9821 \begin_inset Quotes eld
9822 \end_inset
9823
9824 Our ref.
9825 \begin_inset Quotes erd
9826 \end_inset
9827
9828
9829 \begin_inset Quotes eld
9830 \end_inset
9831
9832 Customer no.
9833 \begin_inset Quotes erd
9834 \end_inset
9835
9836
9837 \begin_inset Quotes eld
9838 \end_inset
9839
9840 Invoice no.
9841 \begin_inset Quotes erd
9842 \end_inset
9843
9844 , and 
9845 \begin_inset Quotes eld
9846 \end_inset
9847
9848 Date
9849 \begin_inset Quotes erd
9850 \end_inset
9851
9852 .
9853  For the date field, the value of the 
9854 \family sans
9855 Date
9856 \family default
9857  type is used.
9858  If one of these 
9859 \begin_inset Quotes eld
9860 \end_inset
9861
9862 business letter types
9863 \begin_inset Quotes erd
9864 \end_inset
9865
9866  is used, the value of the 
9867 \family sans
9868 Place
9869 \family default
9870  type however does not appear, but only the LaTeX variable 
9871 \family typewriter
9872
9873 \backslash
9874 fromplace
9875 \family default
9876  is set.
9877  The ordinary output of place and date in a right-aligned line below the
9878  addressee`s field is suppressed.
9879  The types are implemented as input types provided with a label and must
9880  be used ahead of the corresponding 
9881 \family sans
9882 Opening
9883 \family default
9884  type.
9885 \end_layout
9886
9887 \begin_layout Itemize
9888
9889 \family sans
9890 Yourref
9891 \family default
9892 : Your ref.
9893 \end_layout
9894
9895 \begin_layout Itemize
9896
9897 \family sans
9898 Yourmail
9899 \family default
9900 : Your letter of.
9901 \end_layout
9902
9903 \begin_layout Itemize
9904
9905 \family sans
9906 Myref
9907 \family default
9908 : Our ref.
9909 \end_layout
9910
9911 \begin_layout Itemize
9912
9913 \family sans
9914 Customer
9915 \family default
9916 : Customer no.
9917 \end_layout
9918
9919 \begin_layout Itemize
9920
9921 \family sans
9922 Invoice
9923 \family default
9924 : Invoice no.
9925 \end_layout
9926
9927 \begin_layout Subsection
9928 The new letter class: letter (koma-script v.2)
9929 \end_layout
9930
9931 \begin_layout Standard
9932 by 
9933 \noun on
9934 Jürgen Spitzmüller
9935 \end_layout
9936
9937 \begin_layout Standard
9938 \begin_inset VSpace medskip
9939 \end_inset
9940
9941
9942 \end_layout
9943
9944 \begin_layout Standard
9945 \noindent
9946 Koma-Script version 2.8 has introduced a new letter class 
9947 \family typewriter
9948 scrlttr2
9949 \family default
9950  which supersedes the now unsupported 
9951 \family typewriter
9952 scrlettr
9953 \family default
9954 .
9955  It has --- on the LaTeX side --- a completely new interface and is not
9956  compatible with the old class.
9957  Therefore, LyX supports both, though it is recommended to use the new class.
9958 \end_layout
9959
9960 \begin_layout Standard
9961 This class covers the same functionality as 
9962 \emph on
9963 letter (koma-script),
9964 \emph default
9965  and a few more.
9966  The basic items are 
9967 \family sans
9968 Address
9969 \family default
9970  (receiver's address, same as 
9971 \family sans
9972 Letter
9973 \family default
9974  in the old layout), 
9975 \family sans
9976 Opening
9977 \family default
9978 , and 
9979 \family sans
9980 Closing
9981 \family default
9982 .
9983  
9984 \family sans
9985 NextAddress
9986 \family default
9987  will start a new letter (i.
9988 \begin_inset ERT
9989 status collapsed
9990
9991 \begin_layout Standard
9992
9993
9994 \backslash
9995 ,
9996 \end_layout
9997
9998 \end_inset
9999
10000 e.
10001 \begin_inset ERT
10002 status collapsed
10003
10004 \begin_layout Standard
10005
10006
10007 \backslash
10008  
10009 \end_layout
10010
10011 \end_inset
10012
10013 you can write several letters per document).
10014  New elements are sender's 
10015 \family sans
10016 E-Mail
10017 \family default
10018
10019 \family sans
10020 URL
10021 \family default
10022
10023 \family sans
10024 Fax
10025 \family default
10026
10027 \family sans
10028 Bank
10029 \family default
10030  and the possibility to use a 
10031 \family sans
10032 Logo
10033 \family default
10034  (via 
10035 \family sans
10036 \bar under
10037 I
10038 \bar default
10039 nsert\SpecialChar \menuseparator
10040
10041 \bar under
10042 G
10043 \bar default
10044 raphics
10045 \family default
10046 ) in the header.
10047 \end_layout
10048
10049 \begin_layout Standard
10050 The biggest improvement is, though, that the letter's layout is configurable
10051  at almost any needs.
10052  This can be done via the preamble or with a special style file (Letter
10053  Class Option, extension 
10054 \family typewriter
10055 *.lco
10056 \family default
10057 ), that will be read in as a class option.
10058 \begin_inset Foot
10059 status collapsed
10060
10061 \begin_layout Standard
10062 The KOMA package comes with some default 
10063 \family typewriter
10064 *.lco
10065 \family default
10066  files.
10067  There is, for instance, a 
10068 \family typewriter
10069 DIN.lco
10070 \family default
10071  file that follows german typesetting rules, or a 
10072 \family typewriter
10073 KOMAold.lco
10074 \family default
10075  that provides the default layout of the old 
10076 \family typewriter
10077 scrlettr
10078 \family default
10079  class.
10080  The latter can be loaded with the class option 
10081 \family typewriter
10082 KOMAold
10083 \family default
10084 , inserted via the 
10085 \family sans
10086 \bar under
10087 L
10088 \bar default
10089 ayout\SpecialChar \menuseparator
10090
10091 \bar under
10092 D
10093 \bar default
10094 ocument\SpecialChar \menuseparator
10095 Extra Options 
10096 \family default
10097 field.
10098 \end_layout
10099
10100 \end_inset
10101
10102  Have a look at the 
10103 \emph on
10104 koma-letter2
10105 \emph default
10106  template that is included in LyX for examples.
10107  A detailed description is to be found in the Koma-Script documentation
10108  (
10109 \emph on
10110 scrguide
10111 \emph default
10112 ).
10113 \end_layout
10114
10115 \begin_layout Subsection
10116 Problems
10117 \end_layout
10118
10119 \begin_layout Standard
10120 Visualizing the Koma-Script document classes in LyX, the LyX internals cause
10121  some problems.
10122 \end_layout
10123
10124 \begin_layout Itemize
10125 The chapter number of a 
10126 \family sans
10127 Chapter
10128 \family default
10129  type appears on a line of its own above the chapter heading instead of
10130  appearing in the same line ahead of it.
10131  The cause for that is the LyX internal behavior for the labeltype 
10132 \family sans
10133 Counter_Chapter
10134 \family default
10135  in the layout file.
10136 \end_layout
10137
10138 \begin_layout Itemize
10139 The headings of the types 
10140 \family sans
10141 Addchap
10142 \family default
10143  and 
10144 \family sans
10145 Addsec
10146 \family default
10147  are only put in the 
10148 \begin_inset Quotes eld
10149 \end_inset
10150
10151 true
10152 \begin_inset Quotes erd
10153 \end_inset
10154
10155  LaTeX table of contents, but not in the LyX table of contents (
10156 \family sans
10157 \bar under
10158 D
10159 \bar default
10160 ocument\SpecialChar \menuseparator
10161
10162 \bar under
10163 T
10164 \bar default
10165 able\InsetSpace ~
10166 of\InsetSpace ~
10167 Contents
10168 \family default
10169 ).
10170 \end_layout
10171
10172 \begin_layout Itemize
10173 The paragraphs in a 
10174 \emph on
10175 letter
10176 \emph default
10177  document class appear in a skip separation mode, not indented.
10178  This is the standard behavior, no special LaTeX commands are needed for
10179  that.
10180  But in the 
10181 \family sans
10182 \bar under
10183 D
10184 \bar default
10185 ocument\SpecialChar \menuseparator
10186
10187 \bar under
10188 S
10189 \bar default
10190 ettings
10191 \family default
10192  dialog the corresponding radio button indicates 
10193 \family sans
10194 \bar under
10195 I
10196 \bar default
10197 ndent
10198 \family default
10199 .
10200  A 
10201 \family sans
10202 S
10203 \bar under
10204 k
10205 \bar default
10206 ip
10207 \family default
10208  value always has the effect that extra LaTeX commands are inserted in the
10209  document to produce the gap, which is not what is wanted in this case.
10210 \end_layout
10211
10212 \begin_layout Section
10213 Springer Journals (
10214 \family sans
10215 svjour
10216 \family default
10217 )
10218 \end_layout
10219
10220 \begin_layout Standard
10221 by 
10222 \noun on
10223 Martin Vermeer
10224 \end_layout
10225
10226 \begin_layout Subsection
10227 Description
10228 \end_layout
10229
10230 \begin_layout Standard
10231 These are the layout files for some of the journal formats used by Springer
10232  Verlag and listed on 
10233 \begin_inset LatexCommand \url{http://www.springer.de/author/tex/help-journals.html}
10234
10235 \end_inset
10236
10237 , where you should also go to fetch the class files (yes, these are LaTeX2e
10238  now!).
10239  It is a modular system: the things common to all journals are implemented
10240  in 
10241 \family typewriter
10242 svjour.inc
10243 \family default
10244 , which journal-specific layout files (such as, e.g., 
10245 \family typewriter
10246 svjog.layout
10247 \family default
10248  for Journal of Geodesy) can include.
10249 \end_layout
10250
10251 \begin_layout Standard
10252 This means that implementing support for any other Springer journal on this
10253  list is as simple as writing your own 
10254 \family typewriter
10255 sv
10256 \family default
10257 <myjournal>
10258 \family typewriter
10259 .layout
10260 \family default
10261  file following the outline given in 
10262 \family typewriter
10263 svjog.layout
10264 \family default
10265 .
10266  
10267 \end_layout
10268
10269 \begin_layout Standard
10270 It is reasonably well tested only for the Journal of Geodesy.
10271  
10272 \family typewriter
10273 svjour
10274 \family default
10275  and 
10276 \family typewriter
10277 svjog
10278 \family default
10279  come with the standard LyX distribution.
10280  Install the relevant class file (downloaded from Springer) in a proper
10281  directory, reconfigure LaTeX (in the teTeX case by running 
10282 \family typewriter
10283 texhash
10284 \family default
10285 , as root if necessary --- doesn't LyX take care of this?), reconfigure
10286  LyX and it should work.
10287 \end_layout
10288
10289 \begin_layout Subsection
10290 New styles
10291 \end_layout
10292
10293 \begin_layout Standard
10294 A large number of theorem-like styles --- 
10295 \family sans
10296 Claim, Conjecture,
10297 \family default
10298  
10299 \family sans
10300 \SpecialChar \ldots{}
10301 Theorem
10302 \family default
10303 .
10304 \end_layout
10305
10306 \begin_layout Standard
10307
10308 \family sans
10309 Headnote, Dedication, Subtitle, Running_LaTeX_Title, Author_Running, Institute,
10310  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
10311 \family default
10312 .
10313  See the Springer class file documentation for details.
10314 \end_layout
10315
10316 \begin_layout Subsection
10317 Supported journals
10318 \end_layout
10319
10320 \begin_layout Itemize
10321
10322 \emph on
10323 Journal of Geodesy
10324 \emph default
10325
10326 \family typewriter
10327 svjog.layout 
10328 \family default
10329 --- Martin Vermeer
10330 \end_layout
10331
10332 \begin_layout Itemize
10333
10334 \emph on
10335 Probability Theory and Related Fields
10336 \emph default
10337
10338 \family typewriter
10339 svprobth.layout
10340 \family default
10341  --- Jean-Marc Lasgouttes
10342 \end_layout
10343
10344 \begin_layout Standard
10345 Add your own, it isn't so hard!
10346 \end_layout
10347
10348 \begin_layout Subsection
10349 Credits
10350 \end_layout
10351
10352 \begin_layout Standard
10353 These files are partly based on the older 
10354 \family typewriter
10355 ejour2.layout
10356 \family default
10357 , which was again based on a tinkered-with version of an old LaTeX 2.09 style
10358  file from Springer.
10359  All this, and the 
10360 \family typewriter
10361 ejour2
10362 \family default
10363  layout, are now defunct.
10364  Jean-Marc Lasgouttes helped out big in making me find my way around the
10365  LyX layout file mechanism.
10366 \end_layout
10367
10368 \begin_layout Subsection
10369 Bugs
10370 \end_layout
10371
10372 \begin_layout Standard
10373 Probably.
10374  But probably less than in the old hacked-LaTeX 
10375 \family typewriter
10376 ejour2
10377 \family default
10378 .
10379 \end_layout
10380
10381 \begin_layout Standard
10382 Limitations e.g.: does not display the number for theorem-like layouts, just
10383  #.
10384 \end_layout
10385
10386 \begin_layout Section
10387 AGU journals (
10388 \family sans
10389 aguplus
10390 \family default
10391 )
10392 \end_layout
10393
10394 \begin_layout Standard
10395 by 
10396 \shape smallcaps
10397 Martin Vermeer
10398 \end_layout
10399
10400 \begin_layout Subsection
10401 Description
10402 \end_layout
10403
10404 \begin_layout Standard
10405 These are the layout files for some of the journals of the American Geophysical
10406  Society.
10407  It is assumed that you have both the AGU's own class files and AGUplus
10408  installed (everything to be found at
10409 \begin_inset LatexCommand \url{ftp://ftp.agu.org/journals/latex/journals}
10410
10411 \end_inset
10412
10413 ).
10414 \end_layout
10415
10416 \begin_layout Subsection
10417 New styles
10418 \end_layout
10419
10420 \begin_layout Standard
10421 Redefined are 
10422 \family sans
10423 Paragraph
10424 \family default
10425
10426 \family sans
10427 Paragraph*
10428 \family default
10429 .
10430  They are still called this in the LyX GUI, though their LaTeX equivalents
10431  in the AGU classes are 
10432 \family sans
10433 Subsubsubsection
10434 \family default
10435  and 
10436 \family sans
10437 Subsubsubsection*
10438 \family default
10439 .
10440 \end_layout
10441
10442 \begin_layout Standard
10443 Newly defined styles are 
10444 \family sans
10445 Left_Header
10446 \family default
10447
10448 \family sans
10449 Right_Header
10450 \family default
10451
10452 \family sans
10453 Received
10454 \family default
10455
10456 \family sans
10457 Revised
10458 \family default
10459
10460 \family sans
10461 Accepted
10462 \family default
10463
10464 \family sans
10465 CCC
10466 \family default
10467
10468 \family sans
10469 PaperId
10470 \family default
10471
10472 \family sans
10473 AuthorAddr
10474 \family default
10475
10476 \family sans
10477 SlugComment
10478 \family default
10479 .
10480  These are mostly manuscript attributes and defined in the AGU class documentati
10481 on.
10482 \end_layout
10483
10484 \begin_layout Standard
10485 I suspect this is still badly incomplete.
10486 \end_layout
10487
10488 \begin_layout Subsection
10489 New floats
10490 \end_layout
10491
10492 \begin_layout Standard
10493
10494 \family sans
10495 Planotable
10496 \family default
10497  and 
10498 \family sans
10499 Plate
10500 \family default
10501 .
10502  We also have a new 
10503 \family sans
10504 Table_Caption
10505 \family default
10506 .
10507 \end_layout
10508
10509 \begin_layout Subsection
10510 Supported journals
10511 \end_layout
10512
10513 \begin_layout Itemize
10514
10515 \emph on
10516 Journal of Geophysical Research
10517 \emph default
10518
10519 \family typewriter
10520 jgrga.layout 
10521 \family default
10522 --- Martin Vermeer
10523 \end_layout
10524
10525 \begin_layout Standard
10526 Add your own, it isn't so hard! Look at the 
10527 \family typewriter
10528 jgrga.layout
10529 \family default
10530  example and 
10531 \family typewriter
10532 aguplus.inc
10533 \family default
10534 .
10535 \end_layout
10536
10537 \begin_layout Subsection
10538 Bugs and things to remember
10539 \end_layout
10540
10541 \begin_layout Standard
10542 In order to use the new layouts, you must remember to do the following for
10543  a new document:
10544 \end_layout
10545
10546 \begin_layout Enumerate
10547
10548 \emph on
10549 Turn off babel
10550 \emph default
10551 .
10552  This can be done in the 
10553 \family sans
10554 layout\SpecialChar \menuseparator
10555 document
10556 \family default
10557  or 
10558 \family sans
10559 document\SpecialChar \menuseparator
10560 settings
10561 \family default
10562  menu item.
10563  (AGU articles are always in English, right? So 
10564 \emph on
10565 don't
10566 \emph default
10567  choose a language.)
10568 \end_layout
10569
10570 \begin_layout Enumerate
10571 Enter 
10572 \family typewriter
10573 jgrga
10574 \family default
10575  into the document's 
10576 \family sans
10577 Extra Options
10578 \family default
10579  field.
10580  (Yes, this is a bug.)
10581 \end_layout
10582
10583 \begin_layout Enumerate
10584 Make sure you use the 
10585 \family typewriter
10586 agu.bst
10587 \family default
10588  bibliography style, by entering 
10589 \family sans
10590 agu
10591 \family default
10592  into the second field of the BibTeX inset.
10593  None of the standard styles will do.
10594 \end_layout
10595
10596 \begin_layout Section
10597 EGS journals (
10598 \family sans
10599 egs
10600 \family default
10601 )
10602 \end_layout
10603
10604 \begin_layout Standard
10605 by 
10606 \shape smallcaps
10607 Martin Vermeer
10608 \end_layout
10609
10610 \begin_layout Subsection
10611 Description
10612 \end_layout
10613
10614 \begin_layout Standard
10615 This is the layout file for the European Geophysical Society journals.
10616  The needed 
10617 \family typewriter
10618 egs.cls
10619 \family default
10620  can be downloaded from the web site of the EGS under 
10621 \begin_inset LatexCommand \url{www.copernicus.org}
10622
10623 \end_inset
10624
10625 .
10626 \end_layout
10627
10628 \begin_layout Subsection
10629 New styles
10630 \end_layout
10631
10632 \begin_layout Standard
10633
10634 \family sans
10635 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
10636  Accepted
10637 \family default
10638
10639 \family sans
10640 Offsets
10641 \family default
10642 .
10643  The current layout file is unfortunately very unmodular and would benefit
10644  from using the various 
10645 \family typewriter
10646 std*.inc
10647 \family default
10648  file inclusions.
10649 \end_layout
10650
10651 \begin_layout Section
10652 Slides [aka 
10653 \noun on
10654 Sli
10655 \noun default
10656 TeX]
10657 \begin_inset LatexCommand \label{sec:slitex}
10658
10659 \end_inset
10660
10661
10662 \end_layout
10663
10664 \begin_layout Standard
10665 by 
10666 \noun on
10667 John Weiss
10668 \noun default
10669  
10670 \end_layout
10671
10672 \begin_layout Subsection
10673 Introduction
10674 \end_layout
10675
10676 \begin_layout Standard
10677 This section describes how to use LyX to make slides for overhead projectors.
10678  There are two document classes that can do this: the default slides class
10679  and the 
10680 \family sans
10681 Foil
10682 \family default
10683 TeX slides class.
10684  This section documents the former.
10685 \end_layout
10686
10687 \begin_layout Standard
10688 I'm going to say this again, nice and clear, so that there's no misunderstanding
10689 :
10690 \end_layout
10691
10692 \begin_layout Standard
10693 \begin_inset VSpace bigskip
10694 \end_inset
10695
10696
10697 \end_layout
10698
10699 \begin_layout Standard
10700 \align center
10701
10702 \size large
10703 This section documents the class 
10704 \begin_inset Quotes eld
10705 \end_inset
10706
10707
10708 \family sans
10709 slides (default)
10710 \family default
10711
10712 \begin_inset Quotes erd
10713 \end_inset
10714
10715  
10716 \emph on
10717 only.
10718 \end_layout
10719
10720 \begin_layout Standard
10721 \begin_inset VSpace bigskip
10722 \end_inset
10723
10724
10725 \end_layout
10726
10727 \begin_layout Standard
10728 If you're looking for the documentation for 
10729 \begin_inset Quotes eld
10730 \end_inset
10731
10732
10733 \family sans
10734 slides (FoilTeX)
10735 \family default
10736
10737 \begin_inset Quotes erd
10738 \end_inset
10739
10740 , check out section\InsetSpace ~
10741
10742 \begin_inset LatexCommand \ref{sec:foiltex}
10743
10744 \end_inset
10745
10746 .
10747  The 
10748 \family sans
10749 foils 
10750 \family default
10751 class [
10752 \begin_inset Quotes eld
10753 \end_inset
10754
10755
10756 \family sans
10757 slides (FoilTeX)
10758 \family default
10759
10760 \begin_inset Quotes erd
10761 \end_inset
10762
10763 ] is actually somewhat better than the default 
10764 \family sans
10765 slides
10766 \family default
10767  class,
10768 \begin_inset Foot
10769 status collapsed
10770
10771 \begin_layout Standard
10772 \SpecialChar \ldots{}
10773 or so I've been told repeatedly by its advocates.
10774  Having never used it, I have no idea if this claim is true or not.
10775 \end_layout
10776
10777 \end_inset
10778
10779  which this section documents.
10780 \end_layout
10781
10782 \begin_layout Standard
10783 This class is the LaTeX2e improvement of the old 
10784 \noun on
10785 Sli
10786 \noun default
10787 TeX package.
10788  Every LaTeX2e distribution includes this class [which I'll just refer to
10789  as 
10790 \begin_inset Quotes eld
10791 \end_inset
10792
10793
10794 \family sans
10795 slides
10796 \family default
10797
10798 \begin_inset Quotes erd
10799 \end_inset
10800
10801  from now on], so you're bound to have it.
10802  As I noted earlier, there are other classes, such as 
10803 \family sans
10804 foils
10805 \family default
10806 , which also produce slides for overhead projectors and do a better job
10807  at it.
10808  However, there are some things which 
10809 \family sans
10810 slides
10811 \family default
10812  can do which the others can't, such as generate overlays.
10813  Read on to learn more!
10814 \end_layout
10815
10816 \begin_layout Subsection
10817 Getting Started
10818 \begin_inset LatexCommand \label{sec:slidesetup}
10819
10820 \end_inset
10821
10822
10823 \end_layout
10824
10825 \begin_layout Standard
10826 Obviously, to use this document class, you need to select 
10827 \begin_inset Quotes eld
10828 \end_inset
10829
10830
10831 \family sans
10832 slides (default)
10833 \family default
10834
10835 \begin_inset Quotes erd
10836 \end_inset
10837
10838  from the class list in the 
10839 \family sans
10840 \bar under
10841 D
10842 \bar default
10843 ocument\SpecialChar \menuseparator
10844
10845 \bar under
10846 S
10847 \bar default
10848 ettings
10849 \family default
10850  dialog.
10851  There are some other special things you should know about this class:
10852 \end_layout
10853
10854 \begin_layout Itemize
10855 Don't bother changing the options 
10856 \family sans
10857 Sides and Columns
10858 \family default
10859 .
10860  They're not supported by the 
10861 \family sans
10862 slides
10863 \family default
10864  class, anyways.
10865 \end_layout
10866
10867 \begin_layout Itemize
10868 The option 
10869 \family sans
10870 \bar under
10871 P
10872 \bar default
10873 age\InsetSpace ~
10874 style
10875 \family default
10876  behaves a bit differently for this class.
10877  The possible choices and what they do are as follows:
10878 \end_layout
10879
10880 \begin_deeper
10881 \begin_layout Description
10882
10883 \family sans
10884 plain
10885 \family default
10886  The final output contains page numbers in the lower right corner.
10887 \end_layout
10888
10889 \begin_layout Description
10890
10891 \family sans
10892 headings
10893 \family default
10894  Like 
10895 \family sans
10896 plain
10897 \family default
10898 , but also prints out any time markers you've put in.
10899  This is the default.
10900 \end_layout
10901
10902 \begin_layout Description
10903
10904 \family sans
10905 empty
10906 \family default
10907  The final output contains no page numbers, time markers, or alignment markers.
10908 \end_layout
10909
10910 \end_deeper
10911 \begin_layout Itemize
10912 The 
10913 \family sans
10914 slides
10915 \family default
10916  class has an extra option: 
10917 \family typewriter
10918 clock
10919 \family default
10920 .
10921  To use it, put 
10922 \begin_inset Quotes eld
10923 \end_inset
10924
10925
10926 \family typewriter
10927 clock
10928 \family default
10929
10930 \begin_inset Quotes erd
10931 \end_inset
10932
10933  in the extra class options.
10934 \end_layout
10935
10936 \begin_deeper
10937 \begin_layout Standard
10938 Using this options allows you to add time markers to 
10939 \family sans
10940 Note
10941 \family default
10942 s.
10943  See section\InsetSpace ~
10944
10945 \begin_inset LatexCommand \ref{sec:slideNote}
10946
10947 \end_inset
10948
10949  for more details.
10950 \end_layout
10951
10952 \end_deeper
10953 \begin_layout Standard
10954 You can also use the template file 
10955 \begin_inset Quotes eld
10956 \end_inset
10957
10958
10959 \family typewriter
10960 slides.lyx
10961 \family default
10962
10963 \begin_inset Quotes erd
10964 \end_inset
10965
10966  to automatically set up a document to use the 
10967 \family sans
10968 slides 
10969 \family default
10970 class [using 
10971 \family sans
10972 \bar under
10973 F
10974 \bar default
10975 ile\SpecialChar \menuseparator
10976 New\InsetSpace ~
10977 from\InsetSpace ~
10978
10979 \bar under
10980 T
10981 \bar default
10982 emplate
10983 \family default
10984  to open your new document].
10985  The template file also contains some examples of the special paragraph
10986  environments used by this class.
10987  I'll describe those next.
10988 \end_layout
10989
10990 \begin_layout Subsection
10991 Paragraph Environments
10992 \end_layout
10993
10994 \begin_layout Subsubsection
10995 Supported Environments
10996 \end_layout
10997
10998 \begin_layout Standard
10999 The first thing you'll notice when you start up a new 
11000 \family sans
11001 slides 
11002 \family default
11003 document is the font size and type: it's the equivalent of the size 
11004 \begin_inset Quotes eld
11005 \end_inset
11006
11007
11008 \family sans
11009 Largest
11010 \family default
11011
11012 \begin_inset Quotes erd
11013 \end_inset
11014
11015  in the 
11016 \family sans
11017 Sans\InsetSpace ~
11018 Serif
11019 \family default
11020  font.
11021  This is also what's used in the output.
11022  Think of this as a 
11023 \begin_inset Quotes eld
11024 \end_inset
11025
11026 visual cue
11027 \begin_inset Quotes erd
11028 \end_inset
11029
11030  to remind you that this is a slide.
11031  Your final slides will use a larger font; ergo, you'll have less space.
11032  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
11033 \end_layout
11034
11035 \begin_layout Standard
11036 The next thing that becomes obvious is the changes to the paragraph environment
11037  pull-down box [at the far-left end of the toolbar].
11038  Most of the paragraph environments you're used to seeing are missing.
11039  There are also five new ones.
11040  That's because the 
11041 \family sans
11042 slides
11043 \family default
11044  class itself only supports certain paragraph environments:
11045 \end_layout
11046
11047 \begin_layout Itemize
11048
11049 \family sans
11050 Standard
11051 \end_layout
11052
11053 \begin_layout Itemize
11054
11055 \family sans
11056 Itemize
11057 \end_layout
11058
11059 \begin_layout Itemize
11060
11061 \family sans
11062 Enumerate
11063 \end_layout
11064
11065 \begin_layout Itemize
11066
11067 \family sans
11068 Description
11069 \end_layout
11070
11071 \begin_layout Itemize
11072
11073 \family sans
11074 List
11075 \end_layout
11076
11077 \begin_layout Itemize
11078
11079 \family sans
11080 Quotation
11081 \end_layout
11082
11083 \begin_layout Itemize
11084
11085 \family sans
11086 Quote
11087 \end_layout
11088
11089 \begin_layout Itemize
11090
11091 \family sans
11092 Verse
11093 \end_layout
11094
11095 \begin_layout Itemize
11096
11097 \family sans
11098 Caption
11099 \end_layout
11100
11101 \begin_layout Itemize
11102
11103 \family sans
11104 LyX-Code
11105 \end_layout
11106
11107 \begin_layout Itemize
11108
11109 \family sans
11110 Comment
11111 \end_layout
11112
11113 \begin_layout Standard
11114 All of the other standard environments, including the section-heading environmen
11115 ts, aren't used in the 
11116 \family sans
11117 slides
11118 \family default
11119  class.
11120 \end_layout
11121
11122 \begin_layout Standard
11123 On the other hand, you'll notice the following new environments:
11124 \end_layout
11125
11126 \begin_layout Itemize
11127
11128 \family sans
11129 Slide
11130 \end_layout
11131
11132 \begin_layout Itemize
11133
11134 \family sans
11135 Overlay
11136 \end_layout
11137
11138 \begin_layout Itemize
11139
11140 \family sans
11141 Note
11142 \end_layout
11143
11144 \begin_layout Itemize
11145
11146 \family sans
11147 InvisibleText
11148 \end_layout
11149
11150 \begin_layout Itemize
11151
11152 \family sans
11153 VisibleText
11154 \end_layout
11155
11156 \begin_layout Standard
11157 These five are kind of quirky, due to a 
11158 \begin_inset Quotes eld
11159 \end_inset
11160
11161 feature
11162 \begin_inset Quotes erd
11163 \end_inset
11164
11165  in LyX.
11166  You see, LyX doesn't permit you to nest any other paragraph environment
11167  into an empty environment.
11168  Now, that's fine and dandy, but it means that you wouldn't be able to start
11169  a slide with anything except plain text.
11170  To deal with this, I've performed a little 
11171 \begin_inset Quotes eld
11172 \end_inset
11173
11174 LaTeX magic.
11175 \begin_inset Quotes erd
11176 \end_inset
11177
11178  
11179 \end_layout
11180
11181 \begin_layout Subsubsection
11182 Quirks of the New Environments
11183 \begin_inset LatexCommand \label{sec:slideQuirk}
11184
11185 \end_inset
11186
11187
11188 \end_layout
11189
11190 \begin_layout Standard
11191 All five of the new paragraph environments are somewhat quirky due to inherent
11192  limitiations in the current version of LyX.
11193  As I just mentioned, LyX forbids environments that begin with another environme
11194 nt.
11195  To get around this, the 
11196 \family sans
11197 Slide
11198 \family default
11199  environment isn't a paragraph environment as described in the 
11200 \emph on
11201 User's Guide
11202 \emph default
11203 .
11204  
11205 \end_layout
11206
11207 \begin_layout Standard
11208 You should consider 
11209 \family sans
11210 Slide
11211 \family default
11212
11213 \family sans
11214 Overlay
11215 \family default
11216 , and 
11217 \family sans
11218 Note
11219 \family default
11220  to be 
11221 \begin_inset Quotes eld
11222 \end_inset
11223
11224 pseudo-environments.
11225 \begin_inset Quotes erd
11226 \end_inset
11227
11228  They look like a section heading or a 
11229 \begin_inset Quotes eld
11230 \end_inset
11231
11232
11233 \family sans
11234 Caption
11235 \family default
11236 ,
11237 \begin_inset Quotes erd
11238 \end_inset
11239
11240  but really begin a [and, if necessary, end the previous] paragraph environment.
11241  Likewise, treat 
11242 \family sans
11243 InvisibleText
11244 \family default
11245  and 
11246 \family sans
11247 VisibleText
11248 \family default
11249  as 
11250 \begin_inset Quotes eld
11251 \end_inset
11252
11253 pseudo-commands.
11254 \begin_inset Quotes erd
11255 \end_inset
11256
11257  These two perform some action.
11258 \end_layout
11259
11260 \begin_layout Standard
11261 A common feature of all five environments, 
11262 \family sans
11263 Slide
11264 \family default
11265
11266 \family sans
11267 Overlay
11268 \family default
11269
11270 \family sans
11271 Note
11272 \family default
11273
11274 \family sans
11275 InvisibleText
11276 \family default
11277  and 
11278 \family sans
11279 VisibleText
11280 \family default
11281 , is a rather long-ish label.
11282  The text following this label --- ordinarily the contents of the paragraph
11283  environment --- is utterly irrelevant for 
11284 \family sans
11285 Slide
11286 \family default
11287
11288 \family sans
11289 Overlay
11290 \family default
11291
11292 \family sans
11293 Note
11294 \family default
11295
11296 \family sans
11297 InvisibleText
11298 \family default
11299  and 
11300 \family sans
11301 VisibleText
11302 \family default
11303 .
11304  LyX completely ignores it.
11305  In fact, you can leave these five environments completely empty.
11306  
11307 \end_layout
11308
11309 \begin_layout Standard
11310 While you don't 
11311 \emph on
11312 have
11313 \emph default
11314  to put any text after the rather long-ish label, you might want to.
11315  This could be a short description of the contents of the 
11316 \family sans
11317 Slide
11318 \family default
11319 , for example.
11320  In that case, enter in your descriptive comment and hit 
11321 \family sans
11322 Return
11323 \family default
11324  as you normally would.
11325 \end_layout
11326
11327 \begin_layout Standard
11328 If, on the other hand, you don't want to enter in any descriptive text,
11329  you'll hit another LyX quirk.
11330  LyX, like nature, abhors a vacuum, and will not let you start a new paragraph
11331  environment until you put something in the old one.
11332  So, do this:
11333 \end_layout
11334
11335 \begin_layout Itemize
11336 Start entering the text that will 
11337 \emph on
11338 follow
11339 \emph default
11340  the new 
11341 \family sans
11342 Slide
11343 \family default
11344
11345 \family sans
11346 Overlay
11347 \family default
11348
11349 \family sans
11350 Note
11351 \family default
11352
11353 \family sans
11354 InvisibleText
11355 \family default
11356  or 
11357 \family sans
11358 VisibleText
11359 \family default
11360 .
11361  
11362 \end_layout
11363
11364 \begin_layout Itemize
11365 Now move to the beginning of that paragraph.
11366  
11367 \end_layout
11368
11369 \begin_layout Itemize
11370 Next, hit 
11371 \family sans
11372 Return
11373 \family default
11374 .
11375  
11376 \end_layout
11377
11378 \begin_layout Itemize
11379 Finally, change this new, empty paragraph to a 
11380 \family sans
11381 Slide
11382 \family default
11383
11384 \family sans
11385 Overlay
11386 \family default
11387
11388 \family sans
11389 Note
11390 \family default
11391
11392 \family sans
11393 InvisibleText
11394 \family default
11395  or 
11396 \family sans
11397 VisibleText
11398 \family default
11399 .
11400  
11401 \end_layout
11402
11403 \begin_layout Standard
11404 Some future version of LyX will, hopefully, resolve this quirkiness\SpecialChar \ldots{}
11405
11406 \end_layout
11407
11408 \begin_layout Subsection
11409 Making a Presentation with 
11410 \family sans
11411 Slide
11412 \family default
11413 ,
11414 \family sans
11415  Overlay
11416 \family default
11417  and 
11418 \family sans
11419 Note
11420 \end_layout
11421
11422 \begin_layout Subsubsection
11423 Using the 
11424 \family sans
11425 Slide
11426 \family default
11427  Environment
11428 \end_layout
11429
11430 \begin_layout Standard
11431 If you're expecting this section to teach you how to actually make a presentatio
11432 n, you'll be sorely disappointed.
11433  Naturally, I'll describe all of the ways the 
11434 \family sans
11435 slides
11436 \family default
11437  class can assist you in preparing the materials for a presentation.
11438  Filling in the contents, however, is up to you.
11439  [Then again, that 
11440 \emph on
11441 is
11442 \emph default
11443  the LyX philosophy.]
11444 \end_layout
11445
11446 \begin_layout Standard
11447 Choosing the 
11448 \family sans
11449 Slide
11450 \family default
11451  environment [in the manner described in section\InsetSpace ~
11452
11453 \begin_inset LatexCommand \ref{sec:slideQuirk}
11454
11455 \end_inset
11456
11457 ] tells LyX to begin a new slide [duh].
11458  The label for this environment/
11459 \begin_inset Quotes erd
11460 \end_inset
11461
11462 pseudo-command
11463 \begin_inset Quotes erd
11464 \end_inset
11465
11466  is an 
11467 \begin_inset Quotes eld
11468 \end_inset
11469
11470 ASCII line,
11471 \begin_inset Quotes erd
11472 \end_inset
11473
11474  in cool blue, followed by the label, 
11475 \begin_inset Quotes eld
11476 \end_inset
11477
11478 NewSlide:
11479 \begin_inset Quotes erd
11480 \end_inset
11481
11482 .
11483  Any text or paragraph environments that follow this one go on the new slide.
11484  It's that simple.
11485 \end_layout
11486
11487 \begin_layout Standard
11488 Slides are probably the only time you'll need to forcibly end pages in LyX
11489  (this can be specified in the 
11490 \family sans
11491 Paragraph Layout
11492 \family default
11493  dialog).
11494  In fact, you'll want to, once you finish entering the contents of one slide.
11495  If you've entered more text than can physically fit on a slide, the extra
11496  overflows onto a new slide.
11497  I don't recommend doing this, however, since the overflow slide won't have
11498  any page number on it.
11499  Furthermore, it may interfere with any 
11500 \family sans
11501 Overlay
11502 \family default
11503  you've made to accompany the oversized 
11504 \family sans
11505 Slide
11506 \family default
11507 .
11508 \end_layout
11509
11510 \begin_layout Standard
11511 The 
11512 \family sans
11513 Overlay
11514 \family default
11515  and 
11516 \family sans
11517 Note
11518 \family default
11519  environments work the same way as the 
11520 \family sans
11521 Slide 
11522 \family default
11523 environment.
11524  They both create an 
11525 \begin_inset Quotes eld
11526 \end_inset
11527
11528 ASCII line
11529 \begin_inset Quotes erd
11530 \end_inset
11531
11532  followed by a label [
11533 \begin_inset Quotes eld
11534 \end_inset
11535
11536 NewOverlay:
11537 \begin_inset Quotes erd
11538 \end_inset
11539
11540  and 
11541 \begin_inset Quotes eld
11542 \end_inset
11543
11544 NewNote:
11545 \begin_inset Quotes erd
11546 \end_inset
11547
11548 , respectively].
11549  The color is a stunning magenta instead of blue, and the 
11550 \begin_inset Quotes eld
11551 \end_inset
11552
11553 ASCII line
11554 \begin_inset Quotes erd
11555 \end_inset
11556
11557  will look different, in style and in length.
11558  The label fonts of all three also differ from one another.
11559 \end_layout
11560
11561 \begin_layout Standard
11562 As with a 
11563 \family sans
11564 Slide
11565 \family default
11566 , if the contents of a 
11567 \family sans
11568 Note
11569 \family default
11570  or 
11571 \family sans
11572 Overlay
11573 \family default
11574  exceed the physical size of a slide or sheet of paper, the extra will overflow
11575  onto a new sheet.
11576  Again, you should avoid this.
11577  It defeats the whole purpose of 
11578 \family sans
11579 Note
11580 \family default
11581 s and 
11582 \family sans
11583 Overlay
11584 \family default
11585 s.
11586 \end_layout
11587
11588 \begin_layout Subsubsection
11589 Using 
11590 \family sans
11591 Overlay
11592 \family default
11593  with 
11594 \family sans
11595 Slide
11596 \end_layout
11597
11598 \begin_layout Standard
11599 The idea behind an 
11600 \family sans
11601 Overlay
11602 \family default
11603  is a slide that sits atop another slide.
11604  Perhaps you wish to discuss a figure on the main 
11605 \family sans
11606 Slide
11607 \family default
11608  before displaying the text associated with it.
11609  One way to accomplish this is tape a flap of dark paper over the part of
11610  the 
11611 \family sans
11612 Slide
11613 \family default
11614  you want to display later.
11615  This method fails, however, if you wish to overlap one graph with another,
11616  for example.
11617  You would then have to fumble while speaking to align the two separate,
11618  overlapping 
11619 \family sans
11620 Slide
11621 \family default
11622 s to align the two graphs.
11623  The use of an 
11624 \family sans
11625 Overlay
11626 \family default
11627  environment in both cases makes life much easier.
11628 \end_layout
11629
11630 \begin_layout Standard
11631 Each 
11632 \family sans
11633 Overlay
11634 \family default
11635  receives the page number of its 
11636 \begin_inset Quotes eld
11637 \end_inset
11638
11639 parent
11640 \begin_inset Quotes erd
11641 \end_inset
11642
11643  
11644 \family sans
11645 Slide
11646 \family default
11647 , appended by 
11648 \begin_inset Quotes eld
11649 \end_inset
11650
11651
11652 \family typewriter
11653 -a
11654 \family default
11655
11656 \begin_inset Quotes erd
11657 \end_inset
11658
11659 .
11660 \begin_inset Foot
11661 status collapsed
11662
11663 \begin_layout Standard
11664 Presumably, mutliple 
11665 \family sans
11666 Overlay
11667 \family default
11668 s would have 
11669 \begin_inset Quotes eld
11670 \end_inset
11671
11672
11673 \family typewriter
11674 -a
11675 \family default
11676
11677 \begin_inset Quotes erd
11678 \end_inset
11679
11680
11681 \begin_inset Quotes eld
11682 \end_inset
11683
11684
11685 \family typewriter
11686 -b
11687 \family default
11688
11689 \begin_inset Quotes erd
11690 \end_inset
11691
11692
11693 \begin_inset Quotes eld
11694 \end_inset
11695
11696
11697 \family typewriter
11698 -c
11699 \family default
11700
11701 \begin_inset Quotes erd
11702 \end_inset
11703
11704 , etc.\InsetSpace ~
11705 appended to the page number of the parent 
11706 \family sans
11707 Slide
11708 \family default
11709 .
11710  
11711 \end_layout
11712
11713 \end_inset
11714
11715  Clearly, you want the contents of both the 
11716 \family sans
11717 Slide
11718 \family default
11719  and the 
11720 \family sans
11721 Overlay
11722 \family default
11723  to each fit on a single physical slide! You should probably consider an
11724  
11725 \family sans
11726 Overlay
11727 \family default
11728  as 
11729 \begin_inset Quotes eld
11730 \end_inset
11731
11732 part of
11733 \begin_inset Quotes erd
11734 \end_inset
11735
11736  a 
11737 \family sans
11738 Slide
11739 \family default
11740 .
11741  Indeed, the LyX 
11742 \family sans
11743 slides
11744 \family default
11745  class provides a visual cue for this: the label at the start of an 
11746 \family sans
11747 Overlay
11748 \family default
11749  is shorter than that at the start of a 
11750 \family sans
11751 Slide
11752 \family default
11753 .
11754  Lastly, when you generate printable output, you'll find alignment markers
11755  in all four corners of both the 
11756 \family sans
11757 Overlay
11758 \family default
11759  page and its parent 
11760 \family sans
11761 Slide
11762 \family default
11763 .
11764  These will assist you in lining up the two physical slides.
11765 \end_layout
11766
11767 \begin_layout Standard
11768 The major problem in overlaying two slides is aligning the contents of the
11769  two transparencies.
11770  How much space should you leave for that graph on the second slide? Worse
11771  still, what if you want a graph and a sentence on second slide, but there
11772  is text on the main transparency that goes in between them? You could try
11773  and insert vertical space of the right size.
11774  The better way is to use 
11775 \family sans
11776 InvisibleText
11777 \family default
11778  and 
11779 \family sans
11780 VisibleText
11781 \family default
11782 .
11783 \end_layout
11784
11785 \begin_layout Standard
11786 As their names imply, 
11787 \family sans
11788 InvisibleText
11789 \family default
11790  and 
11791 \family sans
11792 VisibleText
11793 \family default
11794  are two command-like paragraph environments that make all subsequent text
11795  invisible and visible, respectively.
11796  Note from section\InsetSpace ~
11797
11798 \begin_inset LatexCommand \ref{sec:slideQuirk}
11799
11800 \end_inset
11801
11802  that you don't place anything 
11803 \emph on
11804 into
11805 \emph default
11806  these two environments, however.
11807  When you create an 
11808 \family sans
11809 InvisibleText
11810 \family default
11811 , it inserts a centered, sky-blue label into the page reading 
11812 \begin_inset Quotes eld
11813 \end_inset
11814
11815 <Invisible Text Follows>
11816 \begin_inset Quotes erd
11817 \end_inset
11818
11819 .
11820  For paragraphs following this label, the parts of the 
11821 \family sans
11822 Slide
11823 \family default
11824  [or 
11825 \family sans
11826 Overlay
11827 \family default
11828 ; it doesn't matter which] where they would be contain instead blank space.
11829  
11830 \end_layout
11831
11832 \begin_layout Standard
11833 For 
11834 \family sans
11835 VisibleText
11836 \family default
11837 , the corresponding centered label is 
11838 \begin_inset Quotes eld
11839 \end_inset
11840
11841 <Visible Text Follows>
11842 \begin_inset Quotes erd
11843 \end_inset
11844
11845  in blazing green.
11846  Paragraphs following this label behave normally.
11847  Note that the beginning of a new 
11848 \family sans
11849 Slide
11850 \family default
11851
11852 \family sans
11853 Overlay
11854 \family default
11855 , or 
11856 \family sans
11857 Note
11858 \family default
11859  automatically shuts off an 
11860 \family sans
11861 InvisibleText
11862 \family default
11863 .
11864  It's therefore not necessary to use 
11865 \family sans
11866 VisibleText
11867 \family default
11868  at the end of a 
11869 \family sans
11870 Slide
11871 \family default
11872 .
11873 \end_layout
11874
11875 \begin_layout Standard
11876 By now, it should be obvious how to create overlay transparencies using
11877  the proper combination of 
11878 \family sans
11879 InvisibleText
11880 \family default
11881  and 
11882 \family sans
11883 VisibleText
11884 \family default
11885  on a 
11886 \family sans
11887 Slide
11888 \family default
11889  and 
11890 \family sans
11891 Overlay
11892 \family default
11893 :
11894 \end_layout
11895
11896 \begin_layout Enumerate
11897 Create a 
11898 \family sans
11899 Slide
11900 \family default
11901 , including everything that will appear on it, whether on the main slide
11902  or on the 
11903 \family sans
11904 Overlay
11905 \family default
11906 .
11907 \end_layout
11908
11909 \begin_layout Enumerate
11910 Before each figure or paragraph that will appear only on the 
11911 \family sans
11912 Overlay
11913 \family default
11914 , insert an 
11915 \family sans
11916 InvisibleText
11917 \family default
11918  environment.
11919  If necessary, insert a 
11920 \family sans
11921 VisibleText
11922 \family default
11923  environment after the 
11924 \family sans
11925 Overlay
11926 \family default
11927 -only text.
11928 \end_layout
11929
11930 \begin_layout Enumerate
11931 Start an 
11932 \family sans
11933 Overlay
11934 \family default
11935  immediately following the 
11936 \family sans
11937 Slide
11938 \family default
11939 .
11940 \end_layout
11941
11942 \begin_layout Enumerate
11943 Copy the contents of this 
11944 \family sans
11945 Slide
11946 \family default
11947  into the 
11948 \family sans
11949 Overlay
11950 \family default
11951 .
11952 \end_layout
11953
11954 \begin_layout Enumerate
11955 Within the 
11956 \family sans
11957 Overlay
11958 \family default
11959 , change all of the 
11960 \family sans
11961 InvisibleText
11962 \family default
11963  lines to 
11964 \family sans
11965 VisibleText
11966 \family default
11967  and vice-versa.
11968 \end_layout
11969
11970 \begin_layout Standard
11971 That's it.
11972  You've just made an 
11973 \family sans
11974 Overlay
11975 \family default
11976 .
11977 \end_layout
11978
11979 \begin_layout Standard
11980 There's one problem with the way I've designed the LyX 
11981 \family sans
11982 slides
11983 \family default
11984  class: you can't make text in the middle of a paragraph invisible, nor
11985  make text in the middle of an invisible paragraph visible again.
11986  To accomplish this feat, you'll need to use some inlined LaTeX codes.
11987 \begin_inset Foot
11988 status collapsed
11989
11990 \begin_layout Standard
11991 The commands of interest are: 
11992 \end_layout
11993
11994 \begin_layout Itemize
11995
11996 \family typewriter
11997 {
11998 \backslash
11999 invisible \SpecialChar \ldots{}
12000  }
12001 \end_layout
12002
12003 \begin_layout Itemize
12004
12005 \family typewriter
12006 {
12007 \backslash
12008 visible \SpecialChar \ldots{}
12009  }
12010 \end_layout
12011
12012 \begin_layout Standard
12013 \SpecialChar \ldots{}
12014 and need to be marked as TeX.
12015  The text whose 
12016 \begin_inset Quotes eld
12017 \end_inset
12018
12019 visibility
12020 \begin_inset Quotes erd
12021 \end_inset
12022
12023  you wish to change goes in between the brackets [and after the 
12024 \family typewriter
12025
12026 \backslash
12027 invisible
12028 \family default
12029  or 
12030 \family typewriter
12031
12032 \backslash
12033 visible
12034 \family default
12035  command].
12036  If you don't know how to mark text as TeX, see the appropriate section
12037  of the 
12038 \emph on
12039 User's Guide
12040 \emph default
12041 .
12042 \end_layout
12043
12044 \end_inset
12045
12046
12047 \end_layout
12048
12049 \begin_layout Subsubsection
12050 Using 
12051 \family sans
12052 Note
12053 \family default
12054  with 
12055 \family sans
12056 Slide
12057 \family default
12058
12059 \begin_inset LatexCommand \label{sec:slideNote}
12060
12061 \end_inset
12062
12063
12064 \end_layout
12065
12066 \begin_layout Standard
12067 Like an 
12068 \family sans
12069 Overlay
12070 \family default
12071 , a 
12072 \family sans
12073 Note
12074 \family default
12075  is associated with a 
12076 \begin_inset Quotes eld
12077 \end_inset
12078
12079 parent
12080 \begin_inset Quotes erd
12081 \end_inset
12082
12083  
12084 \family sans
12085 Slide
12086 \family default
12087 .
12088  Here, too, the LyX 
12089 \family sans
12090 slides
12091 \family default
12092  class provides visual cues.
12093  The label for a 
12094 \family sans
12095 Note
12096 \family default
12097  is shorter than that of a 
12098 \family sans
12099 Slide
12100 \family default
12101  [yet longer than that of an 
12102 \family sans
12103 Overlay
12104 \family default
12105 ] and, like the label of an 
12106 \family sans
12107 Overlay
12108 \family default
12109  is shockingly magenta.
12110  Additionally, the printed 
12111 \family sans
12112 Note
12113 \family default
12114  has the page number of its 
12115 \begin_inset Quotes eld
12116 \end_inset
12117
12118 parent
12119 \begin_inset Quotes erd
12120 \end_inset
12121
12122  
12123 \family sans
12124 Slide
12125 \family default
12126 , appended by 
12127 \begin_inset Quotes eld
12128 \end_inset
12129
12130
12131 \family typewriter
12132 -
12133 \family default
12134 1
12135 \begin_inset Quotes erd
12136 \end_inset
12137
12138
12139 \begin_inset Quotes eld
12140 \end_inset
12141
12142
12143 \family typewriter
12144 -
12145 \family default
12146 2
12147 \begin_inset Quotes erd
12148 \end_inset
12149
12150
12151 \begin_inset Quotes eld
12152 \end_inset
12153
12154
12155 \family typewriter
12156 -
12157 \family default
12158 3
12159 \begin_inset Quotes erd
12160 \end_inset
12161
12162 , etc.
12163  You can have multiple 
12164 \family sans
12165 Note
12166 \family default
12167 s associated with a single 
12168 \family sans
12169 Slide
12170 \family default
12171 , and, as with 
12172 \family sans
12173 Slide
12174 \family default
12175  and 
12176 \family sans
12177 Overlay
12178 \family default
12179 , you'll probably want to break up long 
12180 \family sans
12181 Note
12182 \family default
12183 s so that they fit on a single sheet of paper.
12184 \end_layout
12185
12186 \begin_layout Standard
12187 The purpose of a 
12188 \family sans
12189 Note
12190 \family default
12191  is obvious: it contains anything additional you might want to say about
12192  a 
12193 \family sans
12194 Slide
12195 \family default
12196 .
12197  It could also be used as a sheet of reminders for a particular 
12198 \family sans
12199 Slide
12200 \family default
12201 .
12202  In the case of the latter, you might want to make use of time markers.
12203  Currently, the LyX 
12204 \family sans
12205 slides
12206 \family default
12207  class has no 
12208 \begin_inset Quotes eld
12209 \end_inset
12210
12211 native
12212 \begin_inset Quotes erd
12213 \end_inset
12214
12215  support for time markers, a 
12216 \noun on
12217 Sli
12218 \noun default
12219 TeX feature.
12220  So, you'll have to resort to using the LaTeX codes.
12221 \end_layout
12222
12223 \begin_layout Standard
12224 To use time markers, you'll need to specify the extra class option 
12225 \begin_inset Quotes eld
12226 \end_inset
12227
12228
12229 \family typewriter
12230 clock
12231 \family default
12232
12233 \begin_inset Quotes erd
12234 \end_inset
12235
12236  [see section\InsetSpace ~
12237
12238 \begin_inset LatexCommand \ref{sec:slidesetup}
12239
12240 \end_inset
12241
12242 ].
12243  This option turns on timing marks, which will appear in the lower-left-hand
12244  corner of every 
12245 \family sans
12246 Note
12247 \family default
12248  you generate.
12249  To set what appears in the time marker, you use the LaTeX commands 
12250 \begin_inset Quotes eld
12251 \end_inset
12252
12253
12254 \family typewriter
12255
12256 \backslash
12257 settime{}
12258 \family default
12259
12260 \begin_inset Quotes erd
12261 \end_inset
12262
12263  and 
12264 \begin_inset Quotes eld
12265 \end_inset
12266
12267
12268 \family typewriter
12269
12270 \backslash
12271 addtime{}
12272 \family default
12273
12274 \begin_inset Quotes erd
12275 \end_inset
12276
12277 .
12278  The arguments of both commands are time measured in seconds.
12279  
12280 \begin_inset Quotes eld
12281 \end_inset
12282
12283
12284 \family typewriter
12285
12286 \backslash
12287 settime{}
12288 \family default
12289
12290 \begin_inset Quotes erd
12291 \end_inset
12292
12293  sets the time marker to a given time.
12294  
12295 \begin_inset Quotes eld
12296 \end_inset
12297
12298
12299 \family typewriter
12300
12301 \backslash
12302 addtime{}
12303 \family default
12304
12305 \begin_inset Quotes erd
12306 \end_inset
12307
12308  increments the time marker by the specified amount.
12309  Using time markers and 
12310 \family sans
12311 Note
12312 \family default
12313 s in this fashion, you can remind yourself how much time to spend on a particula
12314
12315 \family sans
12316 Slide
12317 \family default
12318 .
12319 \end_layout
12320
12321 \begin_layout Standard
12322 There's one last feature to describe.
12323  Clearly, you'd like to print out all of your 
12324 \family sans
12325 Slide
12326 \family default
12327 s and 
12328 \family sans
12329 Overlay
12330 \family default
12331 s on transparencies while printing all of your 
12332 \family sans
12333 Note
12334 \family default
12335 s on plain paper.
12336  However, a 
12337 \family sans
12338 Note
12339 \family default
12340  
12341 \emph on
12342 must
12343 \emph default
12344  follow the 
12345 \family sans
12346 Slide
12347 \family default
12348  with which it is associated.
12349  What's a person to do?
12350 \end_layout
12351
12352 \begin_layout Standard
12353 Luckily, there are two LaTeX commands that allow you to select what to print
12354  out.
12355  Both must be placed into the preamble of your document.
12356  The command 
12357 \begin_inset Quotes eld
12358 \end_inset
12359
12360
12361 \family typewriter
12362
12363 \backslash
12364 onlyslides{
12365 \backslash
12366 slides}
12367 \family default
12368
12369 \begin_inset Quotes erd
12370 \end_inset
12371
12372  will cause the output to contain only the 
12373 \family sans
12374 Slide
12375 \family default
12376 s and 
12377 \family sans
12378 Overlay
12379 \family default
12380 s.
12381  Correspondingly, the command 
12382 \begin_inset Quotes eld
12383 \end_inset
12384
12385
12386 \family typewriter
12387
12388 \backslash
12389 onlynotes{
12390 \backslash
12391 notes}
12392 \family default
12393
12394 \begin_inset Quotes erd
12395 \end_inset
12396
12397  prevents the output of anything but 
12398 \family sans
12399 Note
12400 \family default
12401 s.
12402  I'd advise placing both commands in the preamble and initially comment
12403  both out.
12404  You can then preview your entire presentation as you write.
12405  When you're done writing, you can then uncomment one of the two to select
12406  what you want to print.
12407  I like to uncomment 
12408 \begin_inset Quotes eld
12409 \end_inset
12410
12411
12412 \family typewriter
12413
12414 \backslash
12415 onlyslides{
12416 \backslash
12417 slides}
12418 \family default
12419
12420 \begin_inset Quotes erd
12421 \end_inset
12422
12423  , print to a file with 
12424 \begin_inset Quotes eld
12425 \end_inset
12426
12427
12428 \family typewriter
12429 -slides
12430 \family default
12431
12432 \begin_inset Quotes erd
12433 \end_inset
12434
12435  in its name, comment it back out, then uncomment 
12436 \begin_inset Quotes eld
12437 \end_inset
12438
12439
12440 \family typewriter
12441
12442 \backslash
12443 onlynotes{
12444 \backslash
12445 notes}
12446 \family default
12447
12448 \begin_inset Quotes erd
12449 \end_inset
12450
12451  and print to a 
12452 \begin_inset Quotes eld
12453 \end_inset
12454
12455
12456 \family typewriter
12457 *-notes.ps
12458 \family default
12459
12460 \begin_inset Quotes erd
12461 \end_inset
12462
12463  file.
12464  I can then send either file to a printer, loading transparencies or plain
12465  paper as appropriate.
12466 \end_layout
12467
12468 \begin_layout Standard
12469 You can also provide other arguments to the 
12470 \begin_inset Quotes eld
12471 \end_inset
12472
12473
12474 \family typewriter
12475
12476 \backslash
12477 onlyslides{}
12478 \family default
12479
12480 \begin_inset Quotes erd
12481 \end_inset
12482
12483  and 
12484 \begin_inset Quotes eld
12485 \end_inset
12486
12487
12488 \family typewriter
12489
12490 \backslash
12491 onlynotes{}
12492 \family default
12493
12494 \begin_inset Quotes erd
12495 \end_inset
12496
12497  commands.
12498  See a good LaTeX book for details.
12499 \end_layout
12500
12501 \begin_layout Subsection
12502 The 
12503 \family sans
12504 slides
12505 \family default
12506  Class Template File
12507 \end_layout
12508
12509 \begin_layout Standard
12510 I have also provided a template file, 
12511 \begin_inset Quotes eld
12512 \end_inset
12513
12514
12515 \family typewriter
12516 slides.lyx
12517 \family default
12518
12519 \begin_inset Quotes erd
12520 \end_inset
12521
12522 , with the 
12523 \family sans
12524 slides
12525 \family default
12526  class.
12527  To use it, begin your new presentation with 
12528 \family sans
12529 \bar under
12530 F
12531 \bar default
12532 ile\SpecialChar \menuseparator
12533 New\InsetSpace ~
12534 from\InsetSpace ~
12535
12536 \bar under
12537 T
12538 \bar default
12539 emplate
12540 \family default
12541 .
12542  Your new LyX presentation file will contain an example 
12543 \family sans
12544 Slide
12545 \family default
12546  -- 
12547 \family sans
12548 Overlay
12549 \family default
12550  --
12551 \family sans
12552  Note
12553 \family default
12554  triplet.
12555  The 
12556 \family sans
12557 Slide
12558 \family default
12559  and 
12560 \family sans
12561 Overlay
12562 \family default
12563  additionally contain an example of the use of 
12564 \family sans
12565 InvisibleText
12566 \family default
12567  and 
12568 \family sans
12569 VisibleText
12570 \family default
12571 .
12572  Lastly, the preamble will contain:
12573 \end_layout
12574
12575 \begin_layout LyX-Code
12576 % Uncomment to print out only slides and overlays
12577 \end_layout
12578
12579 \begin_layout LyX-Code
12580 %
12581 \end_layout
12582
12583 \begin_layout LyX-Code
12584 %
12585 \backslash
12586 onlyslides{
12587 \backslash
12588 slides}
12589 \newline
12590  
12591 \end_layout
12592
12593 \begin_layout LyX-Code
12594 % Uncomment to print out only notes
12595 \end_layout
12596
12597 \begin_layout LyX-Code
12598 %
12599 \end_layout
12600
12601 \begin_layout LyX-Code
12602 %
12603 \backslash
12604 onlynotes{
12605 \backslash
12606 notes}
12607 \end_layout
12608
12609 \begin_layout Standard
12610 One final thing: I created this class to support the LaTeX2e 
12611 \begin_inset Quotes eld
12612 \end_inset
12613
12614
12615 \noun on
12616 Sli
12617 \noun default
12618 TeX emulation
12619 \begin_inset Quotes erd
12620 \end_inset
12621
12622  class, one of the built-in LaTeX2e classes.
12623  Neither I nor the rest of the LyX Team endorse or oppose the use of this
12624  built-in slide class.
12625  It's here if you want it or need it.
12626  There exist other LaTeX2e classes for creating presentations, such as the
12627  
12628 \family sans
12629 Foils
12630 \family default
12631  class [see section\InsetSpace ~
12632
12633 \begin_inset LatexCommand \ref{sec:foiltex}
12634
12635 \end_inset
12636
12637 ] or the 
12638 \begin_inset Quotes eld
12639 \end_inset
12640
12641
12642 \family typewriter
12643 seminar
12644 \family default
12645
12646 \begin_inset Quotes erd
12647 \end_inset
12648
12649  package [present on some TeX distributions].
12650  The latter is not yet supported under LyX.
12651 \begin_inset Foot
12652 status collapsed
12653
12654 \begin_layout Standard
12655 Perhaps you can take on the task\SpecialChar \ldots{}
12656
12657 \end_layout
12658
12659 \end_inset
12660
12661  I know nothing about these other classes.
12662  Try them out to see what sort of alternative they provide.
12663 \end_layout
12664
12665 \begin_layout Section
12666 Foils [aka 
12667 \family sans
12668 Foil
12669 \family default
12670 \noun on
12671 TeX
12672 \noun default
12673 ]
12674 \begin_inset LatexCommand \label{sec:foiltex}
12675
12676 \end_inset
12677
12678
12679 \end_layout
12680
12681 \begin_layout Standard
12682 by 
12683 \noun on
12684 Allan Rae
12685 \end_layout
12686
12687 \begin_layout Subsection
12688 Introduction
12689 \end_layout
12690
12691 \begin_layout Standard
12692 This section describes how to use LyX to make slides for overhead projectors.
12693  There are two document classes that can do this: the default slides class
12694  and the 
12695 \family sans
12696 Foil
12697 \family default
12698 TeX slides class.
12699  This section documents the latter.
12700 \end_layout
12701
12702 \begin_layout Standard
12703 I'm going to say this again, nice and clear, so that there's no misunderstanding
12704 :
12705 \end_layout
12706
12707 \begin_layout Standard
12708 \begin_inset VSpace bigskip
12709 \end_inset
12710
12711
12712 \end_layout
12713
12714 \begin_layout Standard
12715 \align center
12716
12717 \size large
12718 This section documents the class 
12719 \begin_inset Quotes eld
12720 \end_inset
12721
12722
12723 \family sans
12724 slides (FoilTeX)
12725 \family default
12726
12727 \begin_inset Quotes erd
12728 \end_inset
12729
12730  
12731 \emph on
12732 only.
12733 \end_layout
12734
12735 \begin_layout Standard
12736 \begin_inset VSpace bigskip
12737 \end_inset
12738
12739
12740 \end_layout
12741
12742 \begin_layout Standard
12743 If you're looking for the documentation for 
12744 \begin_inset Quotes eld
12745 \end_inset
12746
12747
12748 \family sans
12749 slides (default)
12750 \family default
12751
12752 \begin_inset Quotes erd
12753 \end_inset
12754
12755 , check out section\InsetSpace ~
12756
12757 \begin_inset LatexCommand \ref{sec:slitex}
12758
12759 \end_inset
12760
12761 .
12762  If your machine doesn't have the 
12763 \family sans
12764 foils 
12765 \family default
12766 class [
12767 \begin_inset Quotes eld
12768 \end_inset
12769
12770
12771 \family sans
12772 slides (FoilTeX)
12773 \family default
12774
12775 \begin_inset Quotes erd
12776 \end_inset
12777
12778 ] installed, you'll probably have to use the default 
12779 \family sans
12780 slides
12781 \family default
12782  class, which isn't quite as good as 
12783 \family sans
12784 foils.
12785 \end_layout
12786
12787 \begin_layout Standard
12788 The 
12789 \family sans
12790 foils
12791 \family default
12792  class is designed for use with version 2.1 of the 
12793 \family sans
12794 foils.cls
12795 \family default
12796  LaTeX class file which is now an integral part of LaTeX2e.
12797 \end_layout
12798
12799 \begin_layout Subsection
12800 Getting Started
12801 \end_layout
12802
12803 \begin_layout Standard
12804 Obviously, to use this document class, you need to select 
12805 \begin_inset Quotes eld
12806 \end_inset
12807
12808
12809 \family sans
12810 slides (FoilTeX)
12811 \family default
12812
12813 \begin_inset Quotes erd
12814 \end_inset
12815
12816  from the 
12817 \family sans
12818 \bar under
12819 C
12820 \bar default
12821 lass
12822 \family default
12823  entry in the 
12824 \family sans
12825 Document\InsetSpace ~
12826 Layout
12827 \family default
12828  dialog.
12829  There are some settings in the 
12830 \family sans
12831 Document\InsetSpace ~
12832 Layout
12833 \family default
12834  dialog that you should know about that are specific to this class:
12835 \end_layout
12836
12837 \begin_layout Itemize
12838 Don't change the options 
12839 \family sans
12840 Sides
12841 \family default
12842  and 
12843 \family sans
12844 Columns
12845 \family default
12846  on the 
12847 \family sans
12848 Document\InsetSpace ~
12849 Layout
12850 \family default
12851  dialog.
12852  They're ignored by the 
12853 \family sans
12854 foils
12855 \family default
12856  class.
12857 \end_layout
12858
12859 \begin_layout Itemize
12860 The default font size is 20pt with the other options being 17pt, 25pt and
12861  30pt.
12862 \end_layout
12863
12864 \begin_layout Itemize
12865 The default font is 
12866 \family sans
12867 sans
12868 \family default
12869  
12870 \family sans
12871 serif
12872 \family default
12873  but all math equations are still typeset in the usual roman font.
12874 \end_layout
12875
12876 \begin_layout Itemize
12877
12878 \family sans
12879 Foil
12880 \family default
12881 TeX supports A4 and Letter paper sizes as well as a special size for working
12882  with 35mm slides.
12883  It doesn't support A5, B5, legal or executive paper sizes.
12884 \end_layout
12885
12886 \begin_layout Itemize
12887 Don't bother changing the 
12888 \family sans
12889 Float Placement
12890 \family default
12891  settings because they are ignored anyway.
12892  All floats appear where they are defined in the text.
12893 \end_layout
12894
12895 \begin_layout Itemize
12896 The 
12897 \family sans
12898 \bar under
12899 P
12900 \bar default
12901 agestyle
12902 \family default
12903  setting behaves a bit differently for this class.
12904  
12905 \family sans
12906 Foil
12907 \family default
12908 TeX provides extensive footer and header capabilities including a user-defined
12909  logo.
12910  See section\InsetSpace ~
12911
12912 \begin_inset LatexCommand \ref{sec:foilfoot}
12913
12914 \end_inset
12915
12916  for more details.
12917  The title page is treated differently to all other pages in the document
12918  and is 
12919 \emph on
12920 always
12921 \emph default
12922  unnumbered and 
12923 \emph on
12924 always
12925 \emph default
12926  has the logo centered at the bottom of the page (if one is defined).
12927  The possible page style choices and what they do are as follows:
12928 \end_layout
12929
12930 \begin_deeper
12931 \begin_layout List
12932 \labelwidthstring MMMMMMM
12933
12934 \family sans
12935 \series bold
12936 empty
12937 \family default
12938 \series default
12939  The final output contains no page numbers, or other headers or footers
12940  (except footnotes of course).
12941  
12942 \end_layout
12943
12944 \begin_layout List
12945 \labelwidthstring MMMMMMM
12946
12947 \family sans
12948 \series bold
12949 plain
12950 \family default
12951 \series default
12952  The final output contains page numbers centered at the bottom of the page.
12953  No other headings or footers (other than footnotes).
12954 \end_layout
12955
12956 \begin_layout List
12957 \labelwidthstring MMMMMMM
12958
12959 \series bold
12960 foilheadings
12961 \series default
12962  Page numbers in lower right corner.
12963  Additional headers and footers are also shown.
12964  This is also the default.
12965 \end_layout
12966
12967 \begin_layout List
12968 \labelwidthstring MMMMMMM
12969
12970 \series bold
12971 fancy
12972 \series default
12973  Gives you access to the 
12974 \family sans
12975 fancyheadings
12976 \family default
12977  package although its use with 
12978 \family sans
12979 Foil
12980 \family default
12981 TeX is discouraged by the writer of the 
12982 \family sans
12983 Foil
12984 \family default
12985 TeX package because of some potential page layout clashes.
12986 \end_layout
12987
12988 \end_deeper
12989 \begin_layout Subsubsection
12990 Extra Options
12991 \end_layout
12992
12993 \begin_layout Standard
12994 The following options may be used in the extra class options in the 
12995 \family sans
12996 \bar under
12997 D
12998 \bar default
12999 ocument\SpecialChar \menuseparator
13000
13001 \bar under
13002 S
13003 \bar default
13004 ettings
13005 \family default
13006  dialog.
13007 \end_layout
13008
13009 \begin_layout List
13010 \labelwidthstring MMMMMMx
13011
13012 \series bold
13013 35mmSlide
13014 \series default
13015  This sets up the page layout for 7.33in by 11in paper, which is about the
13016  same aspect ratio as a 35mm slide, making it a bit easier to work with
13017  this medium.
13018 \end_layout
13019
13020 \begin_layout List
13021 \labelwidthstring MMMMMMx
13022
13023 \series bold
13024 headrule
13025 \series default
13026  Places a rule across the page below the header on every page except the
13027  title page.
13028 \end_layout
13029
13030 \begin_layout List
13031 \labelwidthstring MMMMMMx
13032
13033 \series bold
13034 footrule
13035 \series default
13036  Places a rule across the page above the footer on every page except the
13037  title page.
13038 \end_layout
13039
13040 \begin_layout List
13041 \labelwidthstring MMMMMMx
13042
13043 \series bold
13044 dvips
13045 \series default
13046  This is automatically set each time you create a new 
13047 \family sans
13048 foils
13049 \family default
13050  document.
13051  This option tells 
13052 \family sans
13053 Foil
13054 \family default
13055 TeX to use the dvips driver to rotate those pages that are set as landscape
13056  foils.
13057 \end_layout
13058
13059 \begin_layout List
13060 \labelwidthstring MMMMMMx
13061
13062 \series bold
13063 landscape
13064 \series default
13065  Simply changes the page dimensions to those of a landscape page but doesn't
13066  do any rotation.
13067  Thus if you use this option you need to use an external program to rotate
13068  each page or feed your paper through your printer as landscape.
13069  Note that this option effectively reverses the roles of the 
13070 \family sans
13071 Foilhead
13072 \family default
13073  and 
13074 \family sans
13075 Rotatefoilhead
13076 \family default
13077  environments (don't worry these are described in the next section).
13078 \end_layout
13079
13080 \begin_layout List
13081 \labelwidthstring MMMMMMx
13082
13083 \series bold
13084 leqno
13085 \series default
13086  Equation numbers on the left.
13087 \end_layout
13088
13089 \begin_layout List
13090 \labelwidthstring MMMMMMx
13091
13092 \series bold
13093 fleqn
13094 \series default
13095  Flush-left equations.
13096 \end_layout
13097
13098 \begin_layout Subsection
13099 Supported Environments
13100 \end_layout
13101
13102 \begin_layout Standard
13103 Most of the environments commonly supported in other classes are also supported
13104  by the 
13105 \family sans
13106 foils
13107 \family default
13108  class.
13109  There are several additional environments provided by 
13110 \family sans
13111 Foil
13112 \family default
13113 TeX as well as a couple added by LyX.
13114  The following environments are shared with other classes:
13115 \end_layout
13116
13117 \begin_layout Standard
13118 \begin_inset ERT
13119 status inlined
13120
13121 \begin_layout Standard
13122
13123
13124 \backslash
13125 begin{multicols}{2}
13126 \end_layout
13127
13128 \end_inset
13129
13130
13131 \end_layout
13132
13133 \begin_layout Itemize
13134
13135 \family sans
13136 Standard
13137 \end_layout
13138
13139 \begin_layout Itemize
13140
13141 \family sans
13142 Itemize
13143 \end_layout
13144
13145 \begin_layout Itemize
13146
13147 \family sans
13148 Enumerate
13149 \end_layout
13150
13151 \begin_layout Itemize
13152
13153 \family sans
13154 Description
13155 \end_layout
13156
13157 \begin_layout Itemize
13158
13159 \family sans
13160 List
13161 \end_layout
13162
13163 \begin_layout Itemize
13164
13165 \family sans
13166 LyX-Code
13167 \end_layout
13168
13169 \begin_layout Itemize
13170
13171 \family sans
13172 Verse
13173 \end_layout
13174
13175 \begin_layout Itemize
13176
13177 \family sans
13178 Quote
13179 \end_layout
13180
13181 \begin_layout Itemize
13182
13183 \family sans
13184 Quotation
13185 \end_layout
13186
13187 \begin_layout Itemize
13188
13189 \family sans
13190 Title
13191 \end_layout
13192
13193 \begin_layout Itemize
13194
13195 \family sans
13196 Author
13197 \end_layout
13198
13199 \begin_layout Itemize
13200
13201 \family sans
13202 Date
13203 \end_layout
13204
13205 \begin_layout Itemize
13206
13207 \family sans
13208 Abstract
13209 \end_layout
13210
13211 \begin_layout Itemize
13212
13213 \family sans
13214 Bibliography
13215 \end_layout
13216
13217 \begin_layout Itemize
13218
13219 \family sans
13220 Address
13221 \end_layout
13222
13223 \begin_layout Itemize
13224
13225 \family sans
13226 RightAddress
13227 \end_layout
13228
13229 \begin_layout Itemize
13230
13231 \family sans
13232 Caption
13233 \end_layout
13234
13235 \begin_layout Itemize
13236
13237 \family sans
13238 Comment
13239 \end_layout
13240
13241 \begin_layout Standard
13242 \begin_inset ERT
13243 status inlined
13244
13245 \begin_layout Standard
13246
13247
13248 \backslash
13249 end{multicols}
13250 \end_layout
13251
13252 \end_inset
13253
13254
13255 \end_layout
13256
13257 \begin_layout Standard
13258 That is, all the major environments apart from the sectioning environments.
13259  Since foils are essentially self-contained sections, with a title and body,
13260  
13261 \family sans
13262 Foil
13263 \family default
13264 TeX provides specific commands for starting new foils and these are:
13265 \end_layout
13266
13267 \begin_layout Itemize
13268
13269 \family sans
13270 Foilhead
13271 \end_layout
13272
13273 \begin_layout Itemize
13274
13275 \family sans
13276 Rotatefoilhead
13277 \end_layout
13278
13279 \begin_layout Standard
13280 LyX also provides slightly modified versions of these two environments called:
13281 \end_layout
13282
13283 \begin_layout Itemize
13284
13285 \family sans
13286 ShortFoilhead
13287 \end_layout
13288
13289 \begin_layout Itemize
13290
13291 \family sans
13292 ShortRotatefoilhead
13293 \end_layout
13294
13295 \begin_layout Standard
13296 and the differences will be explained in the next section.
13297 \end_layout
13298
13299 \begin_layout Standard
13300 Since foils are often used in presenting ideas or new theorems and such
13301  
13302 \family sans
13303 Foil
13304 \family default
13305 TeX also provides a comprehensive box of goodies for presenting them:
13306 \end_layout
13307
13308 \begin_layout Standard
13309 \begin_inset ERT
13310 status inlined
13311
13312 \begin_layout Standard
13313
13314
13315 \backslash
13316 begin{multicols}{2}
13317 \end_layout
13318
13319 \end_inset
13320
13321
13322 \end_layout
13323
13324 \begin_layout Itemize
13325
13326 \family sans
13327 Theorem
13328 \end_layout
13329
13330 \begin_layout Itemize
13331
13332 \family sans
13333 Lemma
13334 \end_layout
13335
13336 \begin_layout Itemize
13337
13338 \family sans
13339 Corollary
13340 \end_layout
13341
13342 \begin_layout Itemize
13343
13344 \family sans
13345 Proposition
13346 \end_layout
13347
13348 \begin_layout Itemize
13349
13350 \family sans
13351 Definition
13352 \end_layout
13353
13354 \begin_layout Itemize
13355
13356 \family sans
13357 Proof
13358 \end_layout
13359
13360 \begin_layout Itemize
13361
13362 \family sans
13363 Theorem*
13364 \end_layout
13365
13366 \begin_layout Itemize
13367
13368 \family sans
13369 Lemma*
13370 \end_layout
13371
13372 \begin_layout Itemize
13373
13374 \family sans
13375 Corollary*
13376 \end_layout
13377
13378 \begin_layout Itemize
13379
13380 \family sans
13381 Proposition*
13382 \end_layout
13383
13384 \begin_layout Itemize
13385
13386 \family sans
13387 Definition*
13388 \end_layout
13389
13390 \begin_layout Standard
13391 \begin_inset ERT
13392 status inlined
13393
13394 \begin_layout Standard
13395
13396
13397 \backslash
13398 end{multicols}
13399 \end_layout
13400
13401 \end_inset
13402
13403
13404 \end_layout
13405
13406 \begin_layout Standard
13407 The starred versions are unnumbered while the unstarred versions are numbered.
13408  There are also two list environments added by LyX and these are:
13409 \end_layout
13410
13411 \begin_layout Itemize
13412
13413 \family sans
13414 TickList
13415 \end_layout
13416
13417 \begin_layout Itemize
13418
13419 \family sans
13420 CrossList
13421 \end_layout
13422
13423 \begin_layout Standard
13424
13425 \family sans
13426 Foil
13427 \family default
13428 TeX provides some powerful header and footer capabilities that are best
13429  set in the preamble although they may be set at any point in a document.
13430  If you want to change these settings in your document the best place to
13431  do so is at the very top of a foil, 
13432 \emph on
13433 i.e.
13434
13435 \emph default
13436  straight after the foilhead.
13437 \end_layout
13438
13439 \begin_layout Standard
13440 For this purpose, the following command styles are provided [
13441 \shape smallcaps
13442 Martin Vermeer
13443 \shape default
13444 ]:
13445 \end_layout
13446
13447 \begin_layout Standard
13448 \begin_inset ERT
13449 status inlined
13450
13451 \begin_layout Standard
13452
13453
13454 \backslash
13455 begin{multicols}{2}
13456 \end_layout
13457
13458 \end_inset
13459
13460
13461 \end_layout
13462
13463 \begin_layout Itemize
13464
13465 \family sans
13466 My\InsetSpace ~
13467 Logo
13468 \end_layout
13469
13470 \begin_layout Itemize
13471
13472 \family sans
13473 Restriction
13474 \end_layout
13475
13476 \begin_layout Itemize
13477
13478 \family sans
13479 Right\InsetSpace ~
13480 Footer
13481 \end_layout
13482
13483 \begin_layout Itemize
13484
13485 \family sans
13486 Right\InsetSpace ~
13487 Header
13488 \end_layout
13489
13490 \begin_layout Itemize
13491
13492 \family sans
13493 Left\InsetSpace ~
13494 Header
13495 \end_layout
13496
13497 \begin_deeper
13498 \begin_layout Standard
13499 \InsetSpace ~
13500
13501 \end_layout
13502
13503 \end_deeper
13504 \begin_layout Standard
13505 \begin_inset ERT
13506 status inlined
13507
13508 \begin_layout Standard
13509
13510
13511 \backslash
13512 end{multicols}
13513 \end_layout
13514
13515 \end_inset
13516
13517
13518 \end_layout
13519
13520 \begin_layout Standard
13521 There are also a few commands provided by 
13522 \family sans
13523 Foil
13524 \family default
13525 TeX that aren't directly supported by LyX but I'll tell you what they do
13526  and how to use them in section\InsetSpace ~
13527
13528 \begin_inset LatexCommand \ref{sec:unsuppfoils}
13529
13530 \end_inset
13531
13532 .
13533 \end_layout
13534
13535 \begin_layout Subsection
13536 Building a Set of Foils
13537 \end_layout
13538
13539 \begin_layout Standard
13540 This section will give a simple introduction to using the different environments
13541  to build a set of foils.
13542  If you want to see an example set of foils take a look at the 
13543 \family typewriter
13544 Foils.lyx
13545 \family default
13546  file accessible from the 
13547 \family sans
13548 \bar under
13549 F
13550 \bar default
13551 ile\SpecialChar \menuseparator
13552
13553 \bar under
13554 O
13555 \bar default
13556 pen\SpecialChar \ldots{}
13557
13558 \family default
13559  dialog under the 
13560 \family sans
13561 Examples
13562 \family default
13563  button.
13564  
13565 \end_layout
13566
13567 \begin_layout Subsubsection
13568 Give It a Title Page
13569 \end_layout
13570
13571 \begin_layout Standard
13572 Unlike other classes that provide 
13573 \family sans
13574 Title
13575 \family default
13576
13577 \family sans
13578 Author
13579 \family default
13580
13581 \family sans
13582 Date
13583 \family default
13584  and 
13585 \family sans
13586 Abstract
13587 \family default
13588  environments, 
13589 \family sans
13590 foils
13591 \family default
13592  creates the title on a page of its own.
13593  If you leave out the 
13594 \family sans
13595 Date
13596 \family default
13597  environment LaTeX will substitute the current date (every time you regenerate
13598  the output).
13599 \end_layout
13600
13601 \begin_layout Subsubsection
13602 Start a New Foil
13603 \end_layout
13604
13605 \begin_layout Standard
13606 As I mentioned earlier, there are four ways of starting a new foil.
13607  For portrait foils you should use 
13608 \family sans
13609 Foilhead
13610 \family default
13611  or 
13612 \family sans
13613 ShortFoilhead.
13614
13615 \family default
13616  The difference between these two environments is the amount of space between
13617  the title of the foil (the foilhead) and the body of the foil.
13618 \end_layout
13619
13620 \begin_layout Standard
13621 Landscape foils are generated using the 
13622 \family sans
13623 Rotatefoilhead
13624 \family default
13625  and 
13626 \family sans
13627 ShortRotatefoilhead
13628 \family default
13629  environments.
13630  Again the only difference is the spacing between foilhead and body.
13631  Both of the short versions have 0.5 inches less separation between the foilhead
13632  and the body.
13633  
13634 \end_layout
13635
13636 \begin_layout Standard
13637 One problem with the support for landscape foils is the requirement that
13638  you have to use the 
13639 \family typewriter
13640 dvips
13641 \family default
13642  driver to generate the PostScript® output otherwise the foils won't be
13643  rotated.
13644  It is possible to get landscape foils even if you haven't got the 
13645 \family typewriter
13646 dvips
13647 \family default
13648  driver provided you can feed your foils sideways through your printer ;-)
13649 \end_layout
13650
13651 \begin_layout Subsubsection
13652 Theorems, Lemmas, Proofs and more
13653 \end_layout
13654
13655 \begin_layout Standard
13656 Due to a small bug in LyX you can't have two of the same type of these environme
13657 nts directly following each other.
13658  They must be separated by something.
13659  If you try, you will just be extending the previous environment as if you
13660  had merged the two environments together.
13661  So, how do you get around this problem? The simplest option is to insert
13662  some text between the two environments or add a 
13663 \family sans
13664 LaTeX
13665 \family default
13666  environment between the two with just a 
13667 \begin_inset Quotes eld
13668 \end_inset
13669
13670
13671 \family typewriter
13672 %
13673 \family default
13674
13675 \begin_inset Quotes erd
13676 \end_inset
13677
13678  in it.
13679  This will force LyX to produce two separate environments and hence the
13680  correct LaTeX output.
13681  An example is provided in the example file included with the LyX distribution.
13682  Remember, this problem only occurs if you are trying to place two of the
13683  same type of theorem-like environments one directly after the other.
13684 \end_layout
13685
13686 \begin_layout Subsubsection
13687 Lists
13688 \end_layout
13689
13690 \begin_layout Standard
13691 You get all the commonly supported list styles found in other classes as
13692  well as two new ones.
13693  I'll only describe the new ones here.
13694  If you want to find out more about the other list environments check out
13695  the 
13696 \emph on
13697 User's Guide.
13698
13699 \emph default
13700  If you intend to use itemized lists you might also want to read about the
13701  
13702 \family sans
13703 Itemize\InsetSpace ~
13704 Bullet\InsetSpace ~
13705 Selection
13706 \family default
13707  dialog described above in section\InsetSpace ~
13708
13709 \begin_inset LatexCommand \ref{sec:bullet}
13710
13711 \end_inset
13712
13713 .
13714 \end_layout
13715
13716 \begin_layout Standard
13717 The two new list styles, 
13718 \family sans
13719 TickList 
13720 \family default
13721 and 
13722 \family sans
13723 CrossList
13724 \family default
13725 , are designed to make it easier for you to create lists of do's and don'ts
13726  or right and wrong by providing dedicated environments that use a tick
13727  or a cross as the label of the list.
13728  These lists are in fact dedicated variants of the 
13729 \family sans
13730 Itemize
13731 \family default
13732  environment.
13733  They do however require that you have the 
13734 \family typewriter
13735 psnfss
13736 \family default
13737  packages installed.
13738 \end_layout
13739
13740 \begin_layout Subsubsection
13741 Figures and Tables
13742 \end_layout
13743
13744 \begin_layout Standard
13745
13746 \family sans
13747 Foil
13748 \family default
13749 TeX redefines the floating tables and figures so that they appear exactly
13750  where they are in the text rather than pushing them to the top of the page
13751  or to some user specified location.
13752  In fact if you change the float placement settings they are simply ignored.
13753 \end_layout
13754
13755 \begin_layout Subsubsection
13756 Page Headers and Footers
13757 \begin_inset LatexCommand \label{sec:foilfoot}
13758
13759 \end_inset
13760
13761
13762 \end_layout
13763
13764 \begin_layout Standard
13765
13766 \family sans
13767 My\InsetSpace ~
13768 Logo
13769 \family default
13770  and 
13771 \family sans
13772 Restriction
13773 \family default
13774  are two commands used to control the left-footer text string.
13775  The first is meant to allow you to include a graphic logo on your foils
13776  and defaults to 
13777 \begin_inset Quotes eld
13778 \end_inset
13779
13780 -Typeset by 
13781 \family sans
13782 Foil
13783 \family default
13784 TeX-
13785 \begin_inset Quotes erd
13786 \end_inset
13787
13788 .
13789  While the second is meant to provide a classification for the audience,
13790  
13791 \emph on
13792 e.g.
13793
13794 \emph default
13795  Confidential.
13796  It is empty by default.
13797 \end_layout
13798
13799 \begin_layout Standard
13800 The remaining page corners can be filled by
13801 \family sans
13802  Right\InsetSpace ~
13803 Footer
13804 \family default
13805  (which defaults to page numbers), 
13806 \family sans
13807 Right\InsetSpace ~
13808 Header
13809 \family default
13810  (top right) and 
13811 \family sans
13812 Left\InsetSpace ~
13813 Header
13814 \family default
13815  (top left).
13816 \end_layout
13817
13818 \begin_layout Subsection
13819 Unsupported 
13820 \family sans
13821 Foil
13822 \family default
13823 TeX Goodies
13824 \begin_inset LatexCommand \label{sec:unsuppfoils}
13825
13826 \end_inset
13827
13828
13829 \end_layout
13830
13831 \begin_layout Standard
13832 All the commands mentioned below need to be set in a 
13833 \family sans
13834 LaTeX
13835 \family default
13836  environment or as 
13837 \family sans
13838 TeX
13839 \family default
13840  within another environment.
13841 \end_layout
13842
13843 \begin_layout Subsubsection
13844 Lengths
13845 \end_layout
13846
13847 \begin_layout Standard
13848 All lengths are adjusted using the 
13849 \family typewriter
13850
13851 \backslash
13852 setlength{
13853 \family default
13854 \emph on
13855 lengthname
13856 \family typewriter
13857 \emph default
13858 }{
13859 \family default
13860 \emph on
13861 newlength
13862 \family typewriter
13863 \emph default
13864 }
13865 \family default
13866  command.
13867  Where 
13868 \emph on
13869 lengthname
13870 \emph default
13871  should be replaced by the name given to the length you want to change and
13872  
13873 \emph on
13874 newlength
13875 \emph default
13876  is the length value.
13877  All lengths should be specified in units of length such as inches (
13878 \family typewriter
13879 in
13880 \family default
13881 ), millimeters (
13882 \family typewriter
13883 mm
13884 \family default
13885 ) or points (
13886 \family typewriter
13887 pt
13888 \family default
13889 ) or relative to some document or font-based length such as 
13890 \family typewriter
13891
13892 \backslash
13893 textwidth
13894 \family default
13895 .
13896  
13897 \end_layout
13898
13899 \begin_layout Standard
13900 It's possible to change the spacing between a foilhead and the body of the
13901  foil by adjusting the length specified by 
13902 \family typewriter
13903
13904 \backslash
13905 foilheadskip
13906 \family default
13907 .
13908  For example, to make 
13909 \emph on
13910 all
13911 \emph default
13912  foilheads 0.5 inches closer to their bodies put the following in the preamble:
13913  
13914 \family typewriter
13915
13916 \backslash
13917 setlength{
13918 \backslash
13919 foilheadskip}{-0.5in}
13920 \end_layout
13921
13922 \begin_layout Standard
13923 The spacings around floats can be adjusted by setting these lengths:
13924 \end_layout
13925
13926 \begin_layout List
13927 \labelwidthstring MMMMMMMMMMM
13928
13929 \family typewriter
13930
13931 \backslash
13932 abovefloatskip 
13933 \family default
13934 Separation between the text and the top of the float
13935 \end_layout
13936
13937 \begin_layout List
13938 \labelwidthstring MMMMMMMMMMM
13939
13940 \family typewriter
13941
13942 \backslash
13943 abovecaptionskip 
13944 \family default
13945 Separation between the float and the caption
13946 \end_layout
13947
13948 \begin_layout List
13949 \labelwidthstring MMMMMMMMMMM
13950
13951 \family typewriter
13952
13953 \backslash
13954 belowcaptionskip 
13955 \family default
13956 Separation between the caption and the following text
13957 \end_layout
13958
13959 \begin_layout List
13960 \labelwidthstring MMMMMMMMMMM
13961
13962 \family typewriter
13963
13964 \backslash
13965 captionwidth
13966 \family default
13967  You can make the captions narrower than the surrounding text by adjusting
13968  this length.
13969  Best done relative to 
13970 \family typewriter
13971
13972 \backslash
13973 textwidth
13974 \family default
13975 .
13976 \end_layout
13977
13978 \begin_layout Standard
13979 There are also several title page related lengths that you may find useful
13980  if you have a long title or several authors:
13981 \end_layout
13982
13983 \begin_layout List
13984 \labelwidthstring MMMMMMMMMMM
13985
13986 \family typewriter
13987
13988 \backslash
13989 abovetitleskip
13990 \family default
13991  Separation from headers to 
13992 \family sans
13993 Title
13994 \end_layout
13995
13996 \begin_layout List
13997 \labelwidthstring MMMMMMMMMMM
13998
13999 \family typewriter
14000
14001 \backslash
14002 titleauthorskip
14003 \family default
14004  between 
14005 \family sans
14006 Title
14007 \family default
14008  and 
14009 \family sans
14010 Author
14011 \family default
14012  environments
14013 \end_layout
14014
14015 \begin_layout List
14016 \labelwidthstring MMMMMMMMMMM
14017
14018 \family typewriter
14019
14020 \backslash
14021 authorauthorskip
14022 \family default
14023  between multiple 
14024 \family sans
14025 Author
14026 \family default
14027  lines
14028 \end_layout
14029
14030 \begin_layout List
14031 \labelwidthstring MMMMMMMMMMM
14032
14033 \family typewriter
14034
14035 \backslash
14036 authordateskip
14037 \family default
14038  between the 
14039 \family sans
14040 Author
14041 \family default
14042  and the 
14043 \family sans
14044 Date
14045 \end_layout
14046
14047 \begin_layout List
14048 \labelwidthstring MMMMMMMMMMM
14049
14050 \family typewriter
14051
14052 \backslash
14053 dateabstractskip
14054 \family default
14055  between the 
14056 \family sans
14057 Date
14058 \family default
14059  and the 
14060 \family sans
14061 Abstract
14062 \end_layout
14063
14064 \begin_layout Standard
14065 The last length related command affects all the list environments.
14066  If you place
14067 \family typewriter
14068  
14069 \backslash
14070 zerolistvertdimens
14071 \family default
14072  
14073 \emph on
14074 inside
14075 \emph default
14076  a list environment then all the vertical spacing between the list items
14077  is removed.
14078  Note that this is a command not a length so it doesn't require 
14079 \family typewriter
14080
14081 \backslash
14082 setlength
14083 \family default
14084  like the stuff mentioned above.
14085 \end_layout
14086
14087 \begin_layout Subsubsection
14088 Headers and Footers
14089 \end_layout
14090
14091 \begin_layout Standard
14092 The 
14093 \family typewriter
14094
14095 \backslash
14096 LogoOn
14097 \family default
14098  and 
14099 \family typewriter
14100
14101 \backslash
14102 LogoOff
14103 \family default
14104  commands control whether the logo in the 
14105 \family sans
14106 MyLogo
14107 \family default
14108  definition appear on a given page.
14109  If you put 
14110 \family typewriter
14111
14112 \backslash
14113 LogoOff
14114 \family default
14115  in the preamble then none of the foils will have the logo on them.
14116  If you don't want the logo on a particular page place the 
14117 \family typewriter
14118
14119 \backslash
14120 LogoOff
14121 \family default
14122  directly after the foilhead of that page and the 
14123 \family typewriter
14124
14125 \backslash
14126 LogoOn
14127 \family default
14128  directly after the next foilhead.
14129 \end_layout
14130
14131 \begin_layout Standard
14132 If you decide to use the 
14133 \family sans
14134 fancy
14135 \family default
14136  page style setting in the 
14137 \family sans
14138 Document\InsetSpace ~
14139 Layout
14140 \family default
14141  dialog you should probably add 
14142 \family typewriter
14143
14144 \backslash
14145 let
14146 \backslash
14147 headwidth
14148 \backslash
14149 textwidth
14150 \family default
14151  to your preamble so headers and footers on landscape pages are correctly
14152  placed when rotated.
14153  This is due to some clashes between the page layouts provided by the 
14154 \family sans
14155 fancyheadings
14156 \family default
14157  package and the 
14158 \family sans
14159 foils
14160 \family default
14161  class.
14162 \end_layout
14163
14164 \begin_layout Section
14165 Latex8 (IEEE Conference Papers)
14166 \end_layout
14167
14168 \begin_layout Standard
14169 by 
14170 \noun on
14171 Allan Rae
14172 \end_layout
14173
14174 \begin_layout Subsection
14175 Introduction
14176 \end_layout
14177
14178 \begin_layout Standard
14179 Since this class is specifically for writing submissions to IEEE sponsored
14180  conferences I strongly recommend that you get a copy of their Authors Kit.
14181  The 
14182 \family sans
14183 latex.sty
14184 \family default
14185  package and associated bibliography style file is included in the kit.
14186  The Authors Kit is usually sent out by email once your initial submission
14187  has been accepted.
14188  There is a lot of useful information in the Authors Kit explaining formatting
14189  restrictions and so on and I will assume you have read this since that
14190  means I don't have to repeat it all here.
14191 \end_layout
14192
14193 \begin_layout Subsection
14194 Getting Started
14195 \end_layout
14196
14197 \begin_layout Standard
14198 [AR\SpecialChar \@.
14199  more to come]
14200 \end_layout
14201
14202 \begin_layout Subsection
14203 Supported Environments
14204 \end_layout
14205
14206 \begin_layout Itemize
14207
14208 \family sans
14209 Standard
14210 \end_layout
14211
14212 \begin_layout Itemize
14213
14214 \family sans
14215 Title
14216 \end_layout
14217
14218 \begin_layout Itemize
14219
14220 \family sans
14221 Author
14222 \end_layout
14223
14224 \begin_layout Itemize
14225
14226 \family sans
14227 E-mail
14228 \end_layout
14229
14230 \begin_layout Itemize
14231
14232 \family sans
14233 Affiliation
14234 \end_layout
14235
14236 \begin_layout Itemize
14237
14238 \family sans
14239 Abstract
14240 \end_layout
14241
14242 \begin_layout Itemize
14243
14244 \family sans
14245 Section
14246 \end_layout
14247
14248 \begin_layout Itemize
14249
14250 \family sans
14251 SubSection
14252 \end_layout
14253
14254 \begin_layout Itemize
14255
14256 \family sans
14257 Caption
14258 \end_layout
14259
14260 \begin_layout Subsection
14261 Differences Between Screen and Paper
14262 \end_layout
14263
14264 \begin_layout Standard
14265 There are slight differences in appearance mainly with the presentation
14266  of section counters.
14267  On screen the trailing period of the section counter is missing but it
14268  will appear in the output so don't let this worry you.
14269 \end_layout
14270
14271 \begin_layout Section
14272 Hollywood (Hollywood spec scripts)
14273 \end_layout
14274
14275 \begin_layout Standard
14276 by 
14277 \shape smallcaps
14278 Garst Reese
14279 \end_layout
14280
14281 \begin_layout Subsection
14282 Introduction
14283 \end_layout
14284
14285 \begin_layout Standard
14286 Getting the format of a Hollywood script right is a 
14287 \begin_inset Quotes eld
14288 \end_inset
14289
14290 rite of passage.
14291 \begin_inset Quotes erd
14292 \end_inset
14293
14294  It is designed to make the readers focus on content and to be easy and
14295  familiar for the actors to read.
14296  Each page of a script should be one minute of film.
14297  Nothing goes in a script that you cannot see or hear on screen.
14298  The courier 12 pt font should be used throughout.
14299  No italics.
14300 \end_layout
14301
14302 \begin_layout Subsection
14303 Special problems
14304 \end_layout
14305
14306 \begin_layout Standard
14307 Speakers' lines should NEVER break in mid-sentence.
14308  If a speaker's lines continue over a page break, repeat the 
14309 \family sans
14310 Speaker
14311 \family default
14312  title followed by (Cont'd).
14313 \end_layout
14314
14315 \begin_layout Subsection
14316 Special features
14317 \end_layout
14318
14319 \begin_layout Standard
14320 Insert the 
14321 \family sans
14322 Speaker
14323 \family default
14324  names as labels then cross-reference the label to insert the name.
14325  The cross-reference dialog will show the current cast of characters.
14326  You can use this to insert the speaker name in narratives also.
14327 \end_layout
14328
14329 \begin_layout Subsection
14330 Paper size and Margins
14331 \end_layout
14332
14333 \begin_layout Standard
14334 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
14335 \end_layout
14336
14337 \begin_layout Subsection
14338 Environments
14339 \end_layout
14340
14341 \begin_layout Standard
14342 The following environments are available.
14343  You can use hollywood.bind to get the bind keys shown at the right.
14344 \end_layout
14345
14346 \begin_layout Itemize
14347
14348 \family sans
14349 Standard
14350 \newline
14351
14352 \family default
14353 Used where nothing else works.
14354  Try to avoid it.
14355 \end_layout
14356
14357 \begin_layout Itemize
14358
14359 \family sans
14360 FADE_IN
14361 \family default
14362 :
14363 \hfill
14364
14365 \family sans
14366 M-z S-I
14367 \family default
14368
14369 \newline
14370 Usually followed by something like 
14371 \begin_inset Quotes eld
14372 \end_inset
14373
14374 on Sally waking up.
14375 \begin_inset Quotes erd
14376 \end_inset
14377
14378
14379 \end_layout
14380
14381 \begin_layout Itemize
14382
14383 \family sans
14384 INT:
14385 \hfill
14386 M-z i
14387 \newline
14388
14389 \family default
14390 Introduces a new INTERIOR camera set-up.
14391  Always followed by DAY or NIGHT, or something similar to define the lighting
14392  required.
14393  Everthing on this line in CAPS.
14394 \end_layout
14395
14396 \begin_layout Itemize
14397
14398 \family sans
14399 EXT:
14400 \hfill
14401 M-z e
14402 \newline
14403
14404 \family default
14405 Introduces a new EXTERIOR camera set-up.
14406  Everthing on this line in CAPS.
14407 \end_layout
14408
14409 \begin_layout Itemize
14410
14411 \family sans
14412 Speaker
14413 \hfill
14414 M-z s
14415 \newline
14416
14417 \family default
14418 The character speaking.
14419 \end_layout
14420
14421 \begin_layout Itemize
14422
14423 \family sans
14424 Parenthetical
14425 \hfill
14426 M-z p
14427 \newline
14428
14429 \family default
14430 Instructions to the speaker.
14431  The () are automatically inserted, but only the ( will show in LyX.
14432  Both will be printed.
14433 \end_layout
14434
14435 \begin_layout Itemize
14436
14437 \family sans
14438 Dialogue
14439 \hfill
14440 M-z d
14441 \newline
14442
14443 \family default
14444 What the 
14445 \family sans
14446 Speaker
14447 \family default
14448  says.
14449 \end_layout
14450
14451 \begin_layout Itemize
14452
14453 \family sans
14454 Transition
14455 \hfill
14456 M-z t
14457 \newline
14458
14459 \family default
14460 Camera movement instruction.\InsetSpace \space{}
14461 e.g.
14462  CUT TO:
14463 \end_layout
14464
14465 \begin_layout Itemize
14466
14467 \family sans
14468 FADE OUT:
14469 \hfill
14470 M-z S-I
14471 \end_layout
14472
14473 \begin_layout Itemize
14474
14475 \family sans
14476 Author
14477 \hfill
14478 M-z S-A
14479 \end_layout
14480
14481 \begin_layout Itemize
14482
14483 \family sans
14484 Title
14485 \hfill
14486 M-z S-T
14487 \end_layout
14488
14489 \begin_layout Itemize
14490
14491 \family sans
14492 Right_Address
14493 \hfill
14494 M-z r
14495 \end_layout
14496
14497 \begin_layout Subsection
14498 Script jargon
14499 \end_layout
14500
14501 \begin_layout Itemize
14502 (O.S) --- off screen
14503 \end_layout
14504
14505 \begin_layout Itemize
14506 (V.0) --- voice over
14507 \end_layout
14508
14509 \begin_layout Itemize
14510 b.g.
14511  --- background
14512 \end_layout
14513
14514 \begin_layout Itemize
14515 C.U.
14516  --- close-up
14517 \end_layout
14518
14519 \begin_layout Itemize
14520 PAN --- camera movement
14521 \end_layout
14522
14523 \begin_layout Itemize
14524 INSERT --- cut to close-up of
14525 \end_layout
14526
14527 \begin_layout Section
14528 Broadway
14529 \end_layout
14530
14531 \begin_layout Standard
14532 by 
14533 \shape smallcaps
14534 Garst Reese
14535 \end_layout
14536
14537 \begin_layout Subsection
14538 Introduction
14539 \end_layout
14540
14541 \begin_layout Standard
14542 Broadway is for writing plays.
14543  The format is more decorative than Hollywood, and much less standardized.
14544  This format should be suitable for workshops.
14545 \end_layout
14546
14547 \begin_layout Subsection
14548 Special problems
14549 \end_layout
14550
14551 \begin_layout Standard
14552 The same as in Hollywood.
14553 \end_layout
14554
14555 \begin_layout Subsection
14556 Special features
14557 \end_layout
14558
14559 \begin_layout Standard
14560 Insert the 
14561 \family sans
14562 Speaker
14563 \family default
14564  names as labels then cross-reference the label to insert the name.
14565  The cross-reference dialog will show the current cast of characters.
14566 \end_layout
14567
14568 \begin_layout Subsection
14569 Paper size and Margins
14570 \end_layout
14571
14572 \begin_layout Standard
14573 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
14574 \end_layout
14575
14576 \begin_layout Subsection
14577 Environments
14578 \end_layout
14579
14580 \begin_layout Standard
14581 The following environments are available.
14582  You can use broadway.bind to get the bind keys shown at the right.
14583 \end_layout
14584
14585 \begin_layout Itemize
14586
14587 \family sans
14588 Standard
14589 \newline
14590
14591 \family default
14592 You should not have to use this, but it is here for anything that does not
14593  fit otherwise.
14594 \end_layout
14595
14596 \begin_layout Itemize
14597
14598 \family sans
14599 Narrative
14600 \hfill
14601 M-z n
14602 \newline
14603
14604 \family default
14605 Used to describe stage setting and the action.
14606  First use of speaker names in all CAPs.
14607 \end_layout
14608
14609 \begin_layout Itemize
14610
14611 \family sans
14612 ACT
14613 \hfill
14614 M-z a
14615 \newline
14616
14617 \family default
14618 Automatically numbered.
14619  On screen it will be arabic, but will print as Roman.
14620 \end_layout
14621
14622 \begin_layout Itemize
14623
14624 \family sans
14625 ACT*
14626 \hfill
14627 M-z S at
14628 \newline
14629
14630 \family default
14631 Subtitle for 
14632 \family sans
14633 ACT.
14634  
14635 \family default
14636 It is just centered text.
14637 \end_layout
14638
14639 \begin_layout Itemize
14640
14641 \family sans
14642 SCENE
14643 \hfill
14644 M-z S-S
14645 \newline
14646
14647 \family default
14648 Not automatically numbered.
14649  You supply the number.
14650  This is because I couldn't figure out how.
14651 \end_layout
14652
14653 \begin_layout Itemize
14654
14655 \family sans
14656 AT_RISE:
14657 \hfill
14658 M-z S-R
14659 \newline
14660
14661 \family default
14662 A special case of Narrative to describe the setting and action as the curtain
14663  rises.
14664 \end_layout
14665
14666 \begin_layout Itemize
14667
14668 \family sans
14669 Speaker
14670 \hfill
14671 M-z s
14672 \newline
14673
14674 \family default
14675 The speaker's (actor's) title, centered in all CAPS.
14676 \end_layout
14677
14678 \begin_layout Itemize
14679
14680 \family sans
14681 Parenthetical
14682 \hfill
14683 M-z p
14684 \newline
14685
14686 \family default
14687 Instructions to the speaker.
14688  The parentheses are automatically inserted.
14689  The ( will appear on screen, but both will be in the printed play.
14690  This environment is only used within 
14691 \family sans
14692 Dialogue
14693 \family default
14694 .
14695 \end_layout
14696
14697 \begin_layout Itemize
14698
14699 \family sans
14700 Dialogue
14701 \hfill
14702 M-z d
14703 \newline
14704
14705 \family default
14706 What the Speaker says.
14707 \end_layout
14708
14709 \begin_layout Itemize
14710
14711 \family sans
14712 CURTAIN
14713 \hfill
14714 M-z S-C
14715 \newline
14716
14717 \family default
14718 The curtain comes down.
14719 \end_layout
14720
14721 \begin_layout Itemize
14722
14723 \family sans
14724 Title
14725 \hfill
14726 M-z S-T
14727 \end_layout
14728
14729 \begin_layout Itemize
14730
14731 \family sans
14732 Author
14733 \hfill
14734 M-z S-A
14735 \end_layout
14736
14737 \begin_layout Itemize
14738
14739 \family sans
14740 Right_Address
14741 \hfill
14742 M-z r
14743 \end_layout
14744
14745 \begin_layout Standard
14746 Hello there.
14747 \end_layout
14748
14749 \begin_layout Section
14750 RevTeX4
14751 \end_layout
14752
14753 \begin_layout Standard
14754 by 
14755 \noun on
14756 Amir Karger
14757 \end_layout
14758
14759 \begin_layout Standard
14760 \begin_inset VSpace bigskip
14761 \end_inset
14762
14763
14764 \end_layout
14765
14766 \begin_layout Standard
14767 \noindent
14768 The 
14769 \family sans
14770 Revtex\InsetSpace ~
14771 4
14772 \family default
14773  textclass works with the American Physical Sociey's RevTeX 4.0 (the 
14774 \begin_inset Formula $\beta$
14775 \end_inset
14776
14777  release of May, 1999) class.
14778 \end_layout
14779
14780 \begin_layout Standard
14781 LyX has a 
14782 \family sans
14783 Revtex
14784 \family default
14785  textclass, which works with RevTeX 3.1.
14786  However, v3.1 is basically obsolete, as it works with LaTeX 2.09.
14787  That means that it doesn't interact very well with LyX, which requires
14788  LaTeX2e, although it has been kludged to work.
14789  Since RevTeX 4.0 has been designed to work much more cleanly with LaTeX2e,
14790  LyX with the 
14791 \family sans
14792 RevTeX\InsetSpace ~
14793 4
14794 \family default
14795  textclass should also be pretty easy to use.
14796 \end_layout
14797
14798 \begin_layout Standard
14799 These documents are supposed to be used in 
14800 \emph on
14801 addition
14802 \emph default
14803  to the RevTeX 4.0 documents, so we don't describe any of the special RevTeX
14804  macros, and assume you'll know what to put in the preamble if necessary.
14805 \end_layout
14806
14807 \begin_layout Subsection
14808 Installation
14809 \end_layout
14810
14811 \begin_layout Standard
14812 All you need to do is install RevTeX 4, as described in the package's README
14813  file.
14814  The package can be found at 
14815 \begin_inset LatexCommand \url[The RevTeX 4 Web Site]{http://publish.aps.org/revtex4/}
14816
14817 \end_inset
14818
14819 .
14820  Install it somewhere that LaTeX can see it.
14821  Test it by trying to LaTeX a short RevTeX 4 document in some random directory
14822  (i.e., not the directory where you installed the class file.) Then, if you
14823  reconfigure LyX, it will find the class file and let you use the RevTeX4
14824  textclass.
14825 \end_layout
14826
14827 \begin_layout Standard
14828 Probably the easiest way to get started is either to import a RevTeX 4 document
14829  using 
14830 \family typewriter
14831 reLyX
14832 \family default
14833 , or to use the 
14834 \family sans
14835 Revtex\InsetSpace ~
14836 4
14837 \family default
14838  template, found in the templates directory.
14839 \end_layout
14840
14841 \begin_layout Subsection
14842 Preamble Matter
14843 \end_layout
14844
14845 \begin_layout Standard
14846 Optional arguments to 
14847 \family typewriter
14848
14849 \backslash
14850 documentclass
14851 \family default
14852 , like 
14853 \begin_inset Quotes eld
14854 \end_inset
14855
14856 preprint
14857 \begin_inset Quotes erd
14858 \end_inset
14859
14860  and 
14861 \begin_inset Quotes eld
14862 \end_inset
14863
14864 aps
14865 \begin_inset Quotes erd
14866 \end_inset
14867
14868 , go in the 
14869 \family sans
14870 E
14871 \bar under
14872 x
14873 \bar default
14874 tra\InsetSpace ~
14875 Options
14876 \family default
14877  field in the 
14878 \family sans
14879 Document\InsetSpace ~
14880 Layout
14881 \family default
14882  dialog, as usual.
14883  Remember that in RevTeX, at least one optional argument is required! 
14884 \end_layout
14885
14886 \begin_layout Standard
14887 Other preamble matter, like 
14888 \family typewriter
14889
14890 \backslash
14891 draft
14892 \family default
14893  etc.\InsetSpace \space{}
14894 goes in the 
14895 \family sans
14896 Latex\InsetSpace ~
14897 Preamble
14898 \family default
14899  dialog, also as usual.
14900 \end_layout
14901
14902 \begin_layout Subsection
14903 Layouts
14904 \end_layout
14905
14906 \begin_layout Standard
14907 The layouts basically correspond to the commands in RevTeX4.0.
14908  For example, the Email layout corresponds to 
14909 \family typewriter
14910
14911 \backslash
14912 email{}
14913 \family default
14914 .
14915  Note that (at least as of RevTeX 4.0 Beta), the 
14916 \family sans
14917 Address
14918 \family default
14919  and 
14920 \family sans
14921 Affiliation
14922 \family default
14923  layouts are exactly equivalent, so you shouldn't need to use both.
14924 \begin_inset Foot
14925 status collapsed
14926
14927 \begin_layout Standard
14928 In case you're curious, both were included so that 
14929 \family typewriter
14930 reLyX
14931 \family default
14932  would be able to translate both 
14933 \family typewriter
14934
14935 \backslash
14936 address
14937 \family default
14938  and 
14939 \family typewriter
14940
14941 \backslash
14942 affiliation
14943 \family default
14944 .
14945 \end_layout
14946
14947 \end_inset
14948
14949
14950 \end_layout
14951
14952 \begin_layout Subsection
14953 Important Notes
14954 \end_layout
14955
14956 \begin_layout Standard
14957 There are a couple of important unique aspects of RevTeX 4 which might cause
14958  bugs that will be even more confusing in LyX.
14959 \end_layout
14960
14961 \begin_layout Standard
14962 In RevTeX, the 
14963 \family typewriter
14964
14965 \backslash
14966 thanks
14967 \family default
14968  command goes 
14969 \emph on
14970 outside
14971 \emph default
14972  the 
14973 \family typewriter
14974
14975 \backslash
14976 author
14977 \family default
14978  command.
14979  The LyX equivalent is that there is a separate Thanks layout.
14980  Do 
14981 \emph on
14982 not
14983 \emph default
14984  write footnotes in the 
14985 \family sans
14986 Author
14987 \family default
14988  layout, or weird things may happen.
14989  See the RevTeX 4 documentation for more details.
14990 \end_layout
14991
14992 \begin_layout Standard
14993 Also, the 
14994 \family sans
14995 Author\InsetSpace ~
14996 Email
14997 \family default
14998
14999 \family sans
15000 Author\InsetSpace ~
15001 URL
15002 \family default
15003 , and 
15004 \family sans
15005 Thanks
15006 \family default
15007  layouts must be placed 
15008 \emph on
15009 in between
15010 \emph default
15011  the 
15012 \family sans
15013 Author
15014 \family default
15015  layout and the corresponding 
15016 \family sans
15017 Address
15018 \family default
15019  (or equivalent 
15020 \family sans
15021 Affiliation
15022 \family default
15023 ) layout.
15024  If you put the 
15025 \family sans
15026 Thanks
15027 \family default
15028  after the 
15029 \family sans
15030 Address
15031 \family default
15032 , the LaTeX won't compile.
15033 \end_layout
15034
15035 \begin_layout Subsection
15036 Drawbacks
15037 \end_layout
15038
15039 \begin_layout Standard
15040 The main problem with this layout is that you can't use the optional arguments
15041  to layouts like Email and Title.
15042  (The problem is not unique to this layout; you can't use optional arguments
15043  to the Section layouts either.) This means that after you export that file
15044  to LaTeX (which you'll need to do eventually to send it in to APS), you'll
15045  need to edit the LaTeX file with a text editor to add the optional arguments
15046  to set, e.g., the running title for the page headers.
15047  Lacking these layouts makes the 
15048 \family typewriter
15049
15050 \backslash
15051 altaffiliation
15052 \family default
15053  (and the equivalent 
15054 \family typewriter
15055
15056 \backslash
15057 altaddress
15058 \family default
15059 ) useless, so the corresponding layouts don't exist, and will have to be
15060  added by hand.
15061 \begin_inset Foot
15062 status collapsed
15063
15064 \begin_layout Standard
15065
15066 \emph on
15067 Note from JMarc:
15068 \emph default
15069  actually, LyX 1.3.0 supports some forms of optional arguments, but this layout
15070  has not been updated yet to take advantage of it.
15071 \end_layout
15072
15073 \end_inset
15074
15075  
15076 \end_layout
15077
15078 \begin_layout Section
15079 Article (mwart), book (mwbk) and report (mwrep)
15080 \begin_inset OptArg
15081 status collapsed
15082
15083 \begin_layout Standard
15084 The 
15085 \family typewriter
15086 mw
15087 \family default
15088  Classes
15089 \end_layout
15090
15091 \end_inset
15092
15093
15094 \end_layout
15095
15096 \begin_layout Standard
15097 by 
15098 \noun on
15099 Tomasz Luczak
15100 \end_layout
15101
15102 \begin_layout Standard
15103 The LyX document classes
15104 \emph on
15105  article (mwart)
15106 \emph default
15107
15108 \emph on
15109 report (mwrep)
15110 \emph default
15111  and 
15112 \emph on
15113 book
15114 \emph default
15115  
15116 \emph on
15117 (mwbk)
15118 \emph default
15119  correspond to the LaTeX document classes 
15120 \family typewriter
15121 mwart.cls
15122 \family default
15123
15124 \family typewriter
15125 mwrep.cls
15126 \family default
15127  and 
15128 \family typewriter
15129 mwbk.cls
15130 \family default
15131 , resp.
15132  They are replacements for the standard document classes 
15133 \family typewriter
15134 article.cls
15135 \family default
15136
15137 \family typewriter
15138 report.cls
15139 \family default
15140  and 
15141 \family typewriter
15142 book.cls
15143 \family default
15144 , resp., and fit better to Polish typography conventions in a number of points.
15145  
15146 \end_layout
15147
15148 \begin_layout Standard
15149 Basic differences:
15150 \end_layout
15151
15152 \begin_layout Itemize
15153 Unnumbered titles (with star, eg.
15154  
15155 \family sans
15156 Section*
15157 \family default
15158 ) are added into table of contents,
15159 \end_layout
15160
15161 \begin_layout Itemize
15162 Additional page styles:
15163 \end_layout
15164
15165 \begin_deeper
15166 \begin_layout Description
15167 uheadings header with separated lines,
15168 \end_layout
15169
15170 \begin_layout Description
15171 myheadings custom header, contents headers via commands: 
15172 \family typewriter
15173
15174 \backslash
15175 markright
15176 \family default
15177  and 
15178 \family typewriter
15179
15180 \backslash
15181 markboth
15182 \family default
15183 ,
15184 \end_layout
15185
15186 \begin_layout Description
15187 myuheadings custom header with separated lines,
15188 \end_layout
15189
15190 \begin_layout Description
15191 outer page number is placed on outer side of page
15192 \end_layout
15193
15194 \end_deeper
15195 \begin_layout Itemize
15196 Options 
15197 \end_layout
15198
15199 \begin_deeper
15200 \begin_layout Description
15201 rmheadings serif titles --- default,
15202 \end_layout
15203
15204 \begin_layout Description
15205 sfheadings sansserif titles,
15206 \end_layout
15207
15208 \begin_layout Description
15209 authortitle on title page first placed is author next title --- default,
15210 \end_layout
15211
15212 \begin_layout Description
15213 titleauthor on title page first placed is title next author,
15214 \end_layout
15215
15216 \begin_layout Description
15217 withmarginpar reserve place on page for margins.
15218 \end_layout
15219
15220 \end_deeper
15221 \begin_layout Section
15222 Elsevier Journals
15223 \end_layout
15224
15225 \begin_layout Standard
15226 By 
15227 \noun on
15228 Rod Pinna
15229 \end_layout
15230
15231 \begin_layout Standard
15232 Elsevier Science Publishers B.V.
15233  provides a standard LaTeX document class (
15234 \family typewriter
15235 elsart.cls
15236 \family default
15237 ) for submitting articles to their various journals.
15238  The style file can be downloaded directly from their web site: 
15239 \begin_inset LatexCommand \url{http://authors.elsevier.com/}
15240
15241 \end_inset
15242
15243 .
15244  Instructions are supplied along with the class file, which details the
15245  requirements of the publishers.
15246  LyX includes package that allows for the use of this class, by a layout
15247  and a template file.
15248  Installation of the class file is the same as for any other LaTeX package;
15249  instructions are provided in the Elsevier documentation.
15250 \end_layout
15251
15252 \begin_layout Standard
15253 To make use of 
15254 \family typewriter
15255 elsart.cls
15256 \family default
15257 , a file 
15258 \family typewriter
15259 elsart.layout
15260 \family default
15261  is supplied.
15262  As the Elsevier class file is based mainly on the standard article class,
15263  most of the normal functionality is provided.
15264  The Elsevier class defines a number of mathematical environments, which
15265  are similar to the AMS environments.
15266  These commands are all described in the Elsevier documentation, and are
15267  available in LyX.
15268 \end_layout
15269
15270 \begin_layout Standard
15271 The easiest way to use the Elsevier style is to base documents on the included
15272  template file.
15273  It is best not to use options such as fancy headings or the geometry package,
15274  as elements such as these are defined by Elsevier in their style file.
15275  Ideally, no extra packages except those mentioned in the Elsevier documentation
15276  should be used.
15277  Essentially, Elsevier require as 
15278 \begin_inset Quotes eld
15279 \end_inset
15280
15281 clean
15282 \begin_inset Quotes erd
15283 \end_inset
15284
15285  a 
15286 \begin_inset ERT
15287 status collapsed
15288
15289 \begin_layout Standard
15290
15291
15292 \backslash
15293 LaTeX
15294 \end_layout
15295
15296 \end_inset
15297
15298  file as possible, as their intention is to take the supplied file and replace
15299  the class file with one for the particular journal to which the paper has
15300  been submitted.
15301  This also means that not too much time should be spent on the formating
15302  of the document.
15303  When it comes to be published, this will change anyway.
15304  The rest of the usage for this layout is substantially the same as for
15305  the normal article class.
15306  For details of what Elsevier do and don't allow, refer to their documentation.
15307 \end_layout
15308
15309 \begin_layout Section
15310 Memoir
15311 \end_layout
15312
15313 \begin_layout Standard
15314 By 
15315 \noun on
15316 Jürgen Spitzmüller
15317 \end_layout
15318
15319 \begin_layout Subsection
15320 Overview
15321 \end_layout
15322
15323 \begin_layout Standard
15324 Memoir is a very powerful and constantly evolving class.
15325  It has been designed with regard to fictional and non-fictional literature.
15326  Its aim is to let the user have maximum control over the typesetting of
15327  his document.
15328  Memoir is based on the standard book class, but it can also emulate the
15329  article class (see below).
15330 \end_layout
15331
15332 \begin_layout Standard
15333 Peter Wilson, the developer of Memoir, is known as the author of lots of
15334  useful packages in the LaTeX world.
15335  Most of them have been merged with Memoir.
15336  Therefore, it is much easier to layout the table of contents, appendices,
15337  chapter designs and such.
15338  LyX, though, does not support all of these goodies natively.
15339  Some of them might be added to forthcoming releases
15340 \begin_inset Foot
15341 status collapsed
15342
15343 \begin_layout Standard
15344 You are invited to send suggestions to 
15345 \begin_inset LatexCommand \url{lyx-devel@lists.lyx.org}
15346
15347 \end_inset
15348
15349 .
15350 \end_layout
15351
15352 \end_inset
15353
15354 , lots will probably never, due to the limitations of LyX's framework.
15355  Of course you can still use all features with the help of some native LaTeX
15356  commands (ERT
15357 \begin_inset Foot
15358 status collapsed
15359
15360 \begin_layout Standard
15361 Cf.
15362 \begin_inset ERT
15363 status collapsed
15364
15365 \begin_layout Standard
15366
15367
15368 \backslash
15369  
15370 \end_layout
15371
15372 \end_inset
15373
15374 section\InsetSpace ~
15375
15376 \begin_inset LatexCommand \ref{sec:Inserting-LaTeX-Code}
15377
15378 \end_inset
15379
15380  for details.
15381 \end_layout
15382
15383 \end_inset
15384
15385 ).
15386  In this section, we can only list those features which are natively supported
15387  by LyX.
15388  For detailed descriptions (and for the rest of features) we are recommending
15389  to have a look at the detailed manual of the Memoir class
15390 \begin_inset Foot
15391 status collapsed
15392
15393 \begin_layout Standard
15394 Cf.
15395 \begin_inset ERT
15396 status collapsed
15397
15398 \begin_layout Standard
15399
15400
15401 \backslash
15402  
15403 \end_layout
15404
15405 \end_inset
15406
15407
15408 \begin_inset LatexCommand \url{CTAN:/macros/latex/memoir/memman.pdf}
15409
15410 \end_inset
15411
15412 .
15413 \end_layout
15414
15415 \end_inset
15416
15417 , which is not only a user guide for the class, but also both a comprehensive
15418  description on good typesetting and a superb example for good typesetting
15419  itself.
15420 \end_layout
15421
15422 \begin_layout Subsection
15423 Basic features and restrictions
15424 \end_layout
15425
15426 \begin_layout Standard
15427 Memoir supports basically all features of the standard book classes.
15428  There are, however, some differences, as follows:
15429 \end_layout
15430
15431 \begin_layout Description
15432 Font\InsetSpace ~
15433 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14,
15434  17
15435 \end_layout
15436
15437 \begin_layout Description
15438 Page\InsetSpace ~
15439 style: The fancy page style is not supported, due to a command clash
15440  between Memoir and the fancyhdr package (they are both defining a command
15441  with the same name, which confuses LaTeX).
15442  Instead, Memoir comes with a bunch of own page styles (see 
15443 \family sans
15444 Layout\SpecialChar \menuseparator
15445 Document\SpecialChar \menuseparator
15446 Page\InsetSpace ~
15447 Style
15448 \family default
15449 ).
15450  If you want to use these for the chapter pages, you have to use the command
15451  
15452 \family typewriter
15453
15454 \backslash
15455 chapterstyle
15456 \family default
15457  in the main text or in preamble (e.
15458 \begin_inset ERT
15459 status collapsed
15460
15461 \begin_layout Standard
15462
15463
15464 \backslash
15465 ,
15466 \end_layout
15467
15468 \end_inset
15469
15470 g.
15471 \begin_inset ERT
15472 status collapsed
15473
15474 \begin_layout Standard
15475
15476
15477 \backslash
15478  
15479 \end_layout
15480
15481 \end_inset
15482
15483
15484 \family typewriter
15485
15486 \backslash
15487 chapterstyle{companion}
15488 \family default
15489 ).
15490 \end_layout
15491
15492 \begin_layout Description
15493 Sectioning: Sectionings (chapter, section, subsection etc.) are coming with
15494  an optional argument in the standard classes.
15495  With this, you can specify an alternative version of the title for the
15496  table of contents and the headers (for instance, if the title is too long).
15497  In LyX, you can do this via 
15498 \family sans
15499 Insert\SpecialChar \menuseparator
15500 Short\InsetSpace ~
15501 Title
15502 \family default
15503  at the beginning of a chapter/section.
15504  Memoir features a second optional argument and thus separates the table
15505  of contents from the header.
15506  You can define three variants of a title with this: one for the main text,
15507  one for the table of contents, and one for the headers.
15508  Simply insert two optional arguments if you need this feature, the first
15509  one containing the short title for the Table of Contents, the second one
15510  containing an alternative short title for the headers.
15511 \end_layout
15512
15513 \begin_layout Description
15514 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15515  of contents, the list of figures and the list of table start a new page
15516  automatically.
15517  Memoir does not follow this route.
15518  You have to insert a page break yourself, if you want to have one.
15519 \end_layout
15520
15521 \begin_layout Description
15522 Titlepage: For some unknown reason, Memoir uses pagination on the title
15523  page (in the standard classes, title pages are 
15524 \begin_inset Quotes eld
15525 \end_inset
15526
15527 empty
15528 \begin_inset Quotes erd
15529 \end_inset
15530
15531 , i.
15532 \begin_inset ERT
15533 status collapsed
15534
15535 \begin_layout Standard
15536
15537
15538 \backslash
15539 ,
15540 \end_layout
15541
15542 \end_inset
15543
15544 e.
15545 \begin_inset ERT
15546 status collapsed
15547
15548 \begin_layout Standard
15549
15550
15551 \backslash
15552  
15553 \end_layout
15554
15555 \end_inset
15556
15557 without pagina).
15558  If you want an empty title page, type 
15559 \family typewriter
15560
15561 \backslash
15562 aliaspagestyle{title}{empty} 
15563 \family default
15564 in the preamble.
15565 \end_layout
15566
15567 \begin_layout Description
15568 Article: With the class option 
15569 \emph on
15570 article 
15571 \emph default
15572 (to be inserted in 
15573 \family sans
15574 Layout\SpecialChar \menuseparator
15575 Document\SpecialChar \menuseparator
15576 Extra\InsetSpace ~
15577 Options
15578 \family default
15579 ), you can emulate article style.
15580  That is, counters (footnotes, figures, tables etc.) will not be reset on
15581  new chapters, chapters don't start a new page (but are---in contrary to
15582  
15583 \begin_inset Quotes eld
15584 \end_inset
15585
15586 real
15587 \begin_inset Quotes erd
15588 \end_inset
15589
15590  article classes---still allowed), parts, though, use their own page, as
15591  in book.
15592 \end_layout
15593
15594 \begin_layout Description
15595 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15596  font commands, which have been used in the old LaTeX version 2.09 (e.
15597 \begin_inset ERT
15598 status collapsed
15599
15600 \begin_layout Standard
15601
15602
15603 \backslash
15604 ,
15605 \end_layout
15606
15607 \end_inset
15608
15609 g.
15610 \begin_inset ERT
15611 status collapsed
15612
15613 \begin_layout Standard
15614
15615
15616 \backslash
15617  
15618 \end_layout
15619
15620 \end_inset
15621
15622
15623 \family typewriter
15624
15625 \backslash
15626 rm
15627 \family default
15628
15629 \family typewriter
15630
15631 \backslash
15632 it
15633 \family default
15634 ).
15635  It produces an error and stops LaTeX whenever such a command appears.
15636  The class option 
15637 \emph on
15638 oldfontcommands
15639 \emph default
15640  reallows the commands and spits out warnings instead (which does at least
15641  not stop LaTeX).
15642  Since a lot of packages and particularly BibTeX style files are still using
15643  those commands, we have decided to use this option by default.
15644 \end_layout
15645
15646 \begin_layout Subsection
15647 Extra features
15648 \end_layout
15649
15650 \begin_layout Standard
15651 We will only describe the features supported by LyX (which is not much currently
15652 ).
15653  Please consult the Memoir manual
15654 \begin_inset Foot
15655 status collapsed
15656
15657 \begin_layout Standard
15658 Cf.
15659 \begin_inset ERT
15660 status collapsed
15661
15662 \begin_layout Standard
15663
15664
15665 \backslash
15666  
15667 \end_layout
15668
15669 \end_inset
15670
15671
15672 \begin_inset LatexCommand \url{CTAN:/macros/latex/memoir/memman.pdf}
15673
15674 \end_inset
15675
15676 .
15677 \end_layout
15678
15679 \end_inset
15680
15681  for details.
15682 \end_layout
15683
15684 \begin_layout Description
15685 Abstract: You may wonder why an abstract is an extra feature.
15686  Well, it is in book class.
15687  Usually books don't have abstracts.
15688  Memoir, however, has.
15689  You can use it wherever and how often you like.
15690 \end_layout
15691
15692 \begin_layout Description
15693 Chapterprecis: You may know this from belletristic: The contents of a chapter
15694  is shortly described below the title and also in the table of contents
15695  (e.
15696 \begin_inset ERT
15697 status collapsed
15698
15699 \begin_layout Standard
15700
15701
15702 \backslash
15703 ,
15704 \end_layout
15705
15706 \end_inset
15707
15708 g.
15709 \begin_inset ERT
15710 status collapsed
15711
15712 \begin_layout Standard
15713
15714
15715 \backslash
15716  
15717 \end_layout
15718
15719 \end_inset
15720
15721
15722 \emph on
15723 Our hero arrives in Troia; he loses some friends; he finds others
15724 \emph default
15725 ).
15726  Chapterprecis does exactly this.
15727  It is therefore only sensible below a chapter.
15728 \end_layout
15729
15730 \begin_layout Description
15731 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
15732  The epigraph environment provides an elegant way of typesetting such a
15733  motto.
15734  The motto itself (text) and its author (source) are divided by a short
15735  line.
15736  Unfortunately, we have to fool LyX a bit here again, since the environment
15737  needs two arguments (text and source).
15738  In this case, we have to use curly brackets (in TeX mode) between the two
15739  arguments: 
15740 \emph on
15741 <smart slogan>
15742 \emph default
15743  
15744 \family typewriter
15745 }{
15746 \family default
15747  
15748 \emph on
15749 <author of the slogan>.
15750 \end_layout
15751
15752 \begin_layout Description
15753 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
15754  complex figurative poems).
15755  LyX can only support a few of them.
15756  One is poemtitle, which is a centered title for poems, which will also
15757  be added to the table of contents (verse is the standard environment for
15758  poems.
15759  Memoir has some enhanced versions of verse, but you need to use ERT, because
15760  they have to be nested inside regular verse environments, which is not
15761  possible with LyX).
15762 \end_layout
15763
15764 \begin_layout Description
15765 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
15766 \end_layout
15767
15768 \begin_layout Chapter
15769 Importing and Exporting Alternate File Formats
15770 \begin_inset OptArg
15771 status collapsed
15772
15773 \begin_layout Standard
15774 Importing and Exporting
15775 \end_layout
15776
15777 \end_inset
15778
15779
15780 \end_layout
15781
15782 \begin_layout Section
15783 Considerations
15784 \end_layout
15785
15786 \begin_layout Standard
15787 Importing and exporting LyX documents from/to other formats has been touched
15788  on briefly in the 
15789 \emph on
15790 User Guide
15791 \emph default
15792 .
15793  Here we describe more of the gory details needed to understand just what
15794  is going on when you click on the 
15795 \family sans
15796 \bar under
15797 F
15798 \bar default
15799 ile\SpecialChar \menuseparator
15800
15801 \bar under
15802 I
15803 \bar default
15804 mport
15805 \family default
15806  and 
15807 \family sans
15808 \bar under
15809 F
15810 \bar default
15811 ile\SpecialChar \menuseparator
15812 E
15813 \bar under
15814 x
15815 \bar default
15816 port
15817 \family default
15818  menu items.
15819  
15820 \end_layout
15821
15822 \begin_layout Section
15823 Importing Other Formats
15824 \end_layout
15825
15826 \begin_layout Subsection
15827 LaTeX
15828 \end_layout
15829
15830 \begin_layout Standard
15831 Translating from LaTeX into LyX is performed by a Perl script called reLyX.
15832  Although it is a standalone program which can be called from the command
15833  line, LyX will call it automatically when a LaTeX document is imported.
15834  See section\InsetSpace ~
15835
15836 \begin_inset LatexCommand \ref{sec:reLyX}
15837
15838 \end_inset
15839
15840  for a complete description.
15841  There are no user tunable parameters for reLyX within LyX.
15842 \end_layout
15843
15844 \begin_layout Subsection
15845 ASCII Text
15846 \end_layout
15847
15848 \begin_layout Standard
15849 When importing plain ASCII text, there are two methods of reading the file.
15850  Importing 
15851 \begin_inset Quotes eld
15852 \end_inset
15853
15854 as lines
15855 \begin_inset Quotes erd
15856 \end_inset
15857
15858  preserves all the linebreaks in the ASCII; to LyX, then, each line looks
15859  like a paragraph.
15860  Importing 
15861 \begin_inset Quotes eld
15862 \end_inset
15863
15864 as paragraphs
15865 \begin_inset Quotes erd
15866 \end_inset
15867
15868  assumes that consecutive lines separated by only a single linebreak form
15869  a single paragraph.
15870  Successive linebreaks with no intervening text are thus assumed to be paragraph
15871  delimiters.
15872 \end_layout
15873
15874 \begin_layout Subsection
15875 Noweb
15876 \end_layout
15877
15878 \begin_layout Standard
15879
15880 \emph on
15881 [Editor's note: Needs to be written, obviously - any volunteers? --- mer]
15882 \end_layout
15883
15884 \begin_layout Section
15885 Exporting Other Formats
15886 \end_layout
15887
15888 \begin_layout Subsection
15889 LaTeX
15890 \end_layout
15891
15892 \begin_layout Standard
15893 LyX generates two types of LaTeX files: stripped down versions for the normal
15894  processing (
15895 \family sans
15896 View DVI
15897 \family default
15898 , etc.) which one normally never sees
15899 \begin_inset Foot
15900 status collapsed
15901
15902 \begin_layout Standard
15903 The resulting file is a perfectly valid LaTeX file, though the preamble
15904  might look a bit strange since it includes some definitions used by LyX
15905  which wouldn't show up in most human-written files.
15906 \end_layout
15907
15908 \end_inset
15909
15910 , and human readable forms which are suitable for exchanging with your colleague
15911 s.
15912  The only settable option for the translation is the line length of the
15913  output file.
15914  The default is 65 characters, but it can be set in 
15915 \family sans
15916 \bar under
15917 T
15918 \bar default
15919 ools
15920 \family default
15921 \SpecialChar \menuseparator
15922
15923 \family sans
15924 \bar under
15925 P
15926 \bar default
15927 references
15928 \family default
15929  using the 
15930 \family sans
15931 \bar under
15932 A
15933 \bar default
15934 scii\InsetSpace ~
15935 line\InsetSpace ~
15936 length
15937 \family default
15938  field.
15939  
15940 \end_layout
15941
15942 \begin_layout Subsection
15943 Device Independent Files
15944 \end_layout
15945
15946 \begin_layout Standard
15947 Device Independent files (DVI files) are produced by running LaTeX on your
15948  document.
15949  There are no user settable options.
15950 \end_layout
15951
15952 \begin_layout Subsection
15953 PostScript
15954 \end_layout
15955
15956 \begin_layout Standard
15957 The next step in the conversion chain is converting a DVI file into Postscript®.
15958  You can either use 
15959 \family sans
15960 \bar under
15961 F
15962 \bar default
15963 ile
15964 \family default
15965 \SpecialChar \menuseparator
15966
15967 \family sans
15968 \bar under
15969 E
15970 \bar default
15971 xport
15972 \family default
15973 \SpecialChar \menuseparator
15974
15975 \family sans
15976 Pos
15977 \bar under
15978 t
15979 \bar default
15980 script
15981 \family default
15982  or, if you need more control on the result, 
15983 \family sans
15984 \bar under
15985 F
15986 \bar default
15987 ile
15988 \family default
15989 \SpecialChar \menuseparator
15990
15991 \family sans
15992 \bar under
15993 P
15994 \bar default
15995 rint
15996 \family default
15997 .
15998  If you use the later, note that it is possible to configure, in 
15999 \family sans
16000 \bar under
16001 T
16002 \bar default
16003 ools
16004 \family default
16005 \SpecialChar \menuseparator
16006
16007 \family sans
16008 \bar under
16009 P
16010 \bar default
16011 references
16012 \family default
16013 , the options passed to the dvips program to achieve different effects.
16014 \end_layout
16015
16016 \begin_layout Subsection
16017 ASCII text
16018 \end_layout
16019
16020 \begin_layout Standard
16021 Exporting as ASCII attempts to preserve the 
16022 \begin_inset Quotes eld
16023 \end_inset
16024
16025 shape
16026 \begin_inset Quotes erd
16027 \end_inset
16028
16029  of the document as well as possible, but things like centering and indentation
16030  are thrown out; paragraphs are separated by blank lines.
16031  Section numbering and cross-references are done correctly, so the resulting
16032  text files is remarkably readable.
16033  The only changeable option is the length of lines, as for LaTeX output.
16034 \end_layout
16035
16036 \begin_layout Subsection
16037 HTML
16038 \end_layout
16039
16040 \begin_layout Standard
16041 LyX documents can be converted to hypertext markup, usually by converting
16042  to LaTeX first, then converting that to HTML\SpecialChar \@.
16043  Four LaTeX
16044 \begin_inset Formula $\rightarrow$
16045 \end_inset
16046
16047 HTML converters are currently known to LyX: 
16048 \family typewriter
16049 tth
16050 \family default
16051
16052 \family typewriter
16053 latex2html
16054 \family default
16055
16056 \family typewriter
16057 hevea
16058 \family default
16059  and 
16060 \family typewriter
16061 htlatex
16062 \family default
16063 .
16064  Though they are autodetected, you can overide the selection in preferences.
16065  You can also include further command line options in this dialog.
16066  
16067 \end_layout
16068
16069 \begin_layout Subsection
16070 PDF
16071 \end_layout
16072
16073 \begin_layout Standard
16074 by 
16075 \noun on
16076 Dekel Tsur
16077 \noun default
16078  (mostly)
16079 \end_layout
16080
16081 \begin_layout Standard
16082 \begin_inset VSpace bigskip
16083 \end_inset
16084
16085
16086 \end_layout
16087
16088 \begin_layout Standard
16089 The fastest way to generate a basic PDF file (no tags, links, etc.) with
16090  any version of LyX is to save the document as a Postscript® file, then
16091  run the 
16092 \family typewriter
16093 ps2pdf
16094 \family default
16095  command on it.
16096  Starting with version 1.1.6, the menu item 
16097 \family sans
16098 File->Export->PDF
16099 \family default
16100  will do all this for you.
16101  There are some issues with fonts that you need to pay attention to: see
16102  Section\InsetSpace ~
16103
16104 \begin_inset LatexCommand \ref{sec:badfonts}
16105
16106 \end_inset
16107
16108 .
16109  Also, as of version 1.1.6, there is a better method that will generate much
16110  more sophisticated files.
16111 \end_layout
16112
16113 \begin_layout Subsubsection
16114 Use pdfLaTeX
16115 \end_layout
16116
16117 \begin_layout Standard
16118 With pdfLaTeX you need to convert your eps figures to PDF (see Section\InsetSpace ~
16119
16120 \begin_inset LatexCommand \ref{sec:pdfeps}
16121
16122 \end_inset
16123
16124 ), and you cannot use pstricks.
16125  On the other hand, with pdfLaTeX it is possible to insert directly images
16126  in JPEG or PNG format, use TrueType fonts, and more.
16127 \end_layout
16128
16129 \begin_layout Subsubsection
16130 Why does the text look so bad when viewed with Acrobat Reader?
16131 \begin_inset LatexCommand \label{sec:badfonts}
16132
16133 \end_inset
16134
16135
16136 \begin_inset OptArg
16137 status collapsed
16138
16139 \begin_layout Standard
16140 Bad Fonts in Acrobat Reader
16141 \end_layout
16142
16143 \end_inset
16144
16145
16146 \end_layout
16147
16148 \begin_layout Standard
16149 The problem is that bitmap fonts are displayed poorly by Acrobat Reader.
16150  When creating a PDF from the LyX file, you need to use outline font instead
16151  of the default bitmap fonts (in fact, you should also use outline fonts
16152  for Postscript files).
16153  Recent LaTeX distributions come with Postscript® Type 1 version of the
16154  standard (Computer Modern) fonts.
16155  pdfLaTeX uses these font by default.
16156  Dvips doesn't use these fonts by default, so to make it use them, add the
16157  following to lines to your 
16158 \family typewriter
16159 ~/.dvipsrc
16160 \family default
16161  file
16162 \end_layout
16163
16164 \begin_layout LyX-Code
16165 p+ psfonts.cmz
16166 \end_layout
16167
16168 \begin_layout LyX-Code
16169 p+ psfonts.amz
16170 \end_layout
16171
16172 \begin_layout Standard
16173 If the default LaTeX font encoding (OT1) is used, nothing else need to be
16174  done.
16175  However, if the T1 font encoding is used, then LaTeX uses the newer EC
16176  fonts, for which there are no Type1 version.
16177  There are two solutions in this case: Either use the 
16178 \begin_inset Quotes eld
16179 \end_inset
16180
16181 ae font
16182 \begin_inset Quotes erd
16183 \end_inset
16184
16185  (which is in fact a 
16186 \begin_inset Quotes eld
16187 \end_inset
16188
16189 virtual
16190 \begin_inset Quotes erd
16191 \end_inset
16192
16193  font that emulates T1 coded fonts using the standard CM fonts).
16194  This is done by selecting 
16195 \begin_inset Quotes eld
16196 \end_inset
16197
16198 AE (Almost European)
16199 \begin_inset Quotes erd
16200 \end_inset
16201
16202  from 
16203 \family sans
16204 Document\SpecialChar \menuseparator
16205 Settings\SpecialChar \menuseparator
16206  Fonts\SpecialChar \menuseparator
16207 Roman
16208 \family default
16209 .
16210  However, some glyphs are missing from the CM fonts (e.g.
16211  eth, thorn), and they are taken from the EC fonts.
16212  Therefore you get these glyphs as bitmaps.
16213  Or use the 
16214 \begin_inset Quotes eld
16215 \end_inset
16216
16217 Latin Modern
16218 \begin_inset Quotes erd
16219 \end_inset
16220
16221  font from 
16222 \family sans
16223 Document\SpecialChar \menuseparator
16224 Settings\SpecialChar \menuseparator
16225  Fonts\SpecialChar \menuseparator
16226 Roman
16227 \family default
16228 .
16229  It is a newer and probably the best Postscript® Type 1 version of cm.
16230  Basically, we recommend this over the 
16231 \begin_inset Quotes eld
16232 \end_inset
16233
16234 ae
16235 \begin_inset Quotes erd
16236 \end_inset
16237
16238  solution.
16239  However, the Latin Modern fonts differ from cm in some visual aspects,
16240  which does not please everybody.
16241 \end_layout
16242
16243 \begin_layout Standard
16244 Note: LyX uses by default the T1 font encoding.
16245  If you wish to use the default font encoding (this is not recommended,
16246  unless you only write English documents), clear the field 
16247 \family sans
16248 \bar under
16249 T
16250 \bar default
16251 eX\InsetSpace ~
16252 encoding
16253 \family default
16254  in preferences (tabs 
16255 \family sans
16256 Outputs
16257 \family default
16258
16259 \family sans
16260 Misc
16261 \family default
16262 ).
16263  
16264 \end_layout
16265
16266 \begin_layout Standard
16267 An alternate option is to use the standard Postscript® fonts instead of
16268  the Computer Modern fonts.
16269  To do that, you just need to select one of the fonts listed in the document
16270  layout dialog (except for 
16271 \begin_inset Quotes eld
16272 \end_inset
16273
16274 default
16275 \begin_inset Quotes erd
16276 \end_inset
16277
16278  and 
16279 \begin_inset Quotes eld
16280 \end_inset
16281
16282 computer modern
16283 \begin_inset Quotes erd
16284 \end_inset
16285
16286 , they're all Postscript® fonts).
16287  When using the Postscript® fonts, the result PDF file is smaller as the
16288  fonts are not saved into the file.
16289  Furthermore, the Postscript® fonts include all T1 glyphs.
16290  On the other hand, the Postscript® fonts have no bold symbol font, so poor
16291  man's bold must be used (see Section\InsetSpace ~
16292
16293 \begin_inset LatexCommand \ref{sec:pdfbold}
16294
16295 \end_inset
16296
16297 ).
16298  The Postscript® fonts also look different from the Computer Modern fonts.
16299 \end_layout
16300
16301 \begin_layout Standard
16302 To sum up, both the Computer Modern and the Postscript® fonts gives good
16303  results (with few exceptions).
16304  The decision of which one to use is a matter of taste.
16305 \end_layout
16306
16307 \begin_layout Subsubsection
16308 Why doesn't the 
16309 \backslash
16310 boldsymbol{} command work when I use pslatex?
16311 \begin_inset LatexCommand \label{sec:pdfbold}
16312
16313 \end_inset
16314
16315
16316 \begin_inset OptArg
16317 status collapsed
16318
16319 \begin_layout Standard
16320
16321 \family typewriter
16322
16323 \backslash
16324 boldsymbol{}
16325 \family default
16326  and 
16327 \family typewriter
16328 pslatex
16329 \end_layout
16330
16331 \end_inset
16332
16333
16334 \end_layout
16335
16336 \begin_layout Standard
16337 The Postscript® fonts do not have a bold symbol font.
16338  The solution is to use the 
16339 \family typewriter
16340
16341 \backslash
16342 pmb{}
16343 \family default
16344  (poor man's bold) command.
16345 \end_layout
16346
16347 \begin_layout Standard
16348 It is possible to redefine the 
16349 \family typewriter
16350
16351 \backslash
16352 boldsymbol
16353 \family default
16354  command to use 
16355 \family typewriter
16356
16357 \backslash
16358 pmb
16359 \family default
16360  by putting
16361 \end_layout
16362
16363 \begin_layout LyX-Code
16364
16365 \backslash
16366 renewcommand{
16367 \backslash
16368 boldsymbol}[1]{
16369 \backslash
16370 pmb{#1}}
16371 \end_layout
16372
16373 \begin_layout Standard
16374 in the preamble.
16375 \end_layout
16376
16377 \begin_layout Subsubsection
16378 Is it possible to do write LaTeX code which is processed only when running
16379  pdfLaTeX?
16380 \begin_inset OptArg
16381 status collapsed
16382
16383 \begin_layout Standard
16384 Conditionals with pdfLaTeX
16385 \end_layout
16386
16387 \end_inset
16388
16389
16390 \end_layout
16391
16392 \begin_layout Standard
16393 Yes, you can do this with the 
16394 \family typewriter
16395 ifpdf.sty
16396 \family default
16397  package.
16398  Here is an example:
16399 \end_layout
16400
16401 \begin_layout LyX-Code
16402
16403 \end_layout
16404
16405 \begin_layout LyX-Code
16406
16407 \end_layout
16408
16409 \begin_layout LyX-Code
16410
16411 \end_layout
16412
16413 \begin_layout LyX-Code
16414
16415 \end_layout
16416
16417 \begin_layout LyX-Code
16418
16419 \end_layout
16420
16421 \begin_layout LyX-Code
16422
16423 \end_layout
16424
16425 \begin_layout LyX-Code
16426
16427 \backslash
16428 usepackage{ifpdf} 
16429 \end_layout
16430
16431 \begin_layout LyX-Code
16432
16433 \backslash
16434 ifpdf
16435 \end_layout
16436
16437 \begin_layout LyX-Code
16438    
16439 \backslash
16440 pdfinfo { /Author (your name and e-mail address)
16441 \end_layout
16442
16443 \begin_layout LyX-Code
16444       /Title (official title -- i.e., title element)
16445 \end_layout
16446
16447 \begin_layout LyX-Code
16448       /Subject (one line description of the document)
16449 \end_layout
16450
16451 \begin_layout LyX-Code
16452    }
16453 \end_layout
16454
16455 \begin_layout LyX-Code
16456    
16457 \backslash
16458 pdfcatalog { /PageMode (/UseNone)
16459 \end_layout
16460
16461 \begin_layout LyX-Code
16462    % /OpenAction (fitbh)
16463 \end_layout
16464
16465 \begin_layout LyX-Code
16466    }
16467 \end_layout
16468
16469 \begin_layout LyX-Code
16470    
16471 \backslash
16472 usepackage[pdftex]{hyperref}
16473 \end_layout
16474
16475 \begin_layout LyX-Code
16476
16477 \backslash
16478 else
16479 \end_layout
16480
16481 \begin_layout LyX-Code
16482    
16483 \backslash
16484 usepackage[ps2pdf]{hyperref}
16485 \end_layout
16486
16487 \begin_layout LyX-Code
16488
16489 \backslash
16490 fi
16491 \end_layout
16492
16493 \begin_layout LyX-Code
16494
16495 \end_layout
16496
16497 \begin_layout Subsubsection
16498 How can I make URLs clickable?
16499 \end_layout
16500
16501 \begin_layout Standard
16502 See the references here:
16503 \end_layout
16504
16505 \begin_layout Standard
16506 \begin_inset LatexCommand \url{http://wiki.lyx.org/pmwiki.php/FAQ/PDF}
16507
16508 \end_inset
16509
16510
16511 \end_layout
16512
16513 \begin_layout Subsection
16514 Custom
16515 \end_layout
16516
16517 \begin_layout Standard
16518 Custom exports are possible if you have some particularly weird format you
16519  wish to convert to, assuming you have the relevant converter, of course.
16520  The format of the 
16521 \emph on
16522 input
16523 \emph default
16524  file can be chosen in the 
16525 \family sans
16526 \bar under
16527 F
16528 \bar default
16529 ile\SpecialChar \menuseparator
16530
16531 \bar under
16532 E
16533 \bar default
16534 xport\SpecialChar \menuseparator
16535
16536 \bar under
16537 C
16538 \bar default
16539 ustom 
16540 \family default
16541 dialog; LyX will automatically convert the file to this point, then feed
16542  it to your custom converter.
16543  The possible values are all formats that LyX can produce from its own documents.
16544  
16545 \end_layout
16546
16547 \begin_layout Standard
16548 The converter command is also specified in the dialog.
16549  It should be a completely qualified command line which uses the variable
16550  
16551 \family typewriter
16552 $$FName
16553 \family default
16554  to specify the name of the file.
16555  If this variable is not given, then the file will be sent to the standard
16556  input of your command.
16557  You may have to apply a bit of ingenuity to escape this sequence correctly
16558  so that it is compatible with your shell.
16559  
16560 \end_layout
16561
16562 \begin_layout Standard
16563 While it is not possible to save this command using the 
16564 \family sans
16565 Preferences 
16566 \family default
16567 dialog, you can manually edit your 
16568 \family typewriter
16569 .lyx/preferences
16570 \family default
16571  to add a line like
16572 \end_layout
16573
16574 \begin_layout LyX-Code
16575
16576 \backslash
16577 custom_export_command "mycommand $$FName"
16578 \end_layout
16579
16580 \begin_layout Section
16581 The Complete reLyX Description
16582 \begin_inset LatexCommand \label{sec:reLyX}
16583
16584 \end_inset
16585
16586
16587 \end_layout
16588
16589 \begin_layout Subsection
16590 Synopsis
16591 \end_layout
16592
16593 \begin_layout Standard
16594 The simplest way to use reLyX is via the 
16595 \family sans
16596 \bar under
16597 F
16598 \bar default
16599 ile\SpecialChar \menuseparator
16600
16601 \bar under
16602 I
16603 \bar default
16604 mport
16605 \family default
16606  command in LyX.
16607  That runs reLyX on the given file and loads the resulting file into LyX.
16608  You should try that first, and call it from the command line only if you
16609  need to use more complicated options.
16610 \end_layout
16611
16612 \begin_layout Standard
16613
16614 \series bold
16615 reLyX
16616 \series default
16617  [ 
16618 \series bold
16619 -c
16620 \series default
16621  
16622 \shape italic
16623 textclass
16624 \shape default
16625  ] [ 
16626 \series bold
16627 -df
16628 \series default
16629  ] [ 
16630 \series bold
16631 -o
16632 \series default
16633  
16634 \shape italic
16635 outputdir
16636 \shape default
16637  ] [
16638 \series bold
16639  -r
16640 \series default
16641 \shape italic
16642  renv1
16643 \shape default
16644 [,
16645 \shape italic
16646 renv2
16647 \shape default
16648 ...]] [
16649 \series bold
16650  -s
16651 \series default
16652 \shape italic
16653  sfile1
16654 \shape default
16655 [,
16656 \shape italic
16657 sfile2
16658 \shape default
16659 ...]] 
16660 \emph on
16661 inputfile
16662 \end_layout
16663
16664 \begin_layout Standard
16665
16666 \series bold
16667 reLyX
16668 \series default
16669  
16670 \series bold
16671 -p
16672 \series default
16673  
16674 \series bold
16675 -c
16676 \series default
16677  
16678 \shape italic
16679 textclass
16680 \shape default
16681  [ 
16682 \series bold
16683 -df
16684 \series default
16685  ] [ 
16686 \series bold
16687 -o
16688 \series default
16689  
16690 \shape italic
16691 outputdir
16692 \shape default
16693  ] [
16694 \series bold
16695  -r
16696 \series default
16697 \shape italic
16698  renv1
16699 \shape default
16700 [,
16701 \shape italic
16702 renv2
16703 \shape default
16704 ...]] [
16705 \series bold
16706  -s
16707 \series default
16708 \shape italic
16709  sfile1
16710 \shape default
16711 [,
16712 \shape italic
16713 sfile2
16714 \shape default
16715 ...]] 
16716 \emph on
16717 inputfiles
16718 \end_layout
16719
16720 \begin_layout Standard
16721
16722 \series bold
16723 reLyX
16724 \series default
16725  
16726 \series bold
16727 -h
16728 \end_layout
16729
16730 \begin_layout Subsection
16731 Options
16732 \end_layout
16733
16734 \begin_layout Description
16735
16736 \series bold
16737 -c
16738 \series default
16739  Class.
16740  By default, when reLyX sees a 
16741 \family typewriter
16742
16743 \backslash
16744 documentclass{foo}
16745 \family default
16746  command, it creates a file of textclass 
16747 \begin_inset Quotes eld
16748 \end_inset
16749
16750 foo
16751 \begin_inset Quotes erd
16752 \end_inset
16753
16754  and reads the LyX layout file for that class.
16755   Use 
16756 \series bold
16757 -c
16758 \series default
16759  to declare a different textclass (and read a different layout file).
16760 \end_layout
16761
16762 \begin_layout Description
16763
16764 \series bold
16765 -d
16766 \series default
16767  Debug.
16768  By default, reLyX gives sparse output and deletes the temporary files which
16769  were created during translation.
16770  Using the 
16771 \series bold
16772 -d
16773 \series default
16774  flag will create much more output (both to stdout and stderr) and leave
16775  the temporary files around.
16776 \end_layout
16777
16778 \begin_layout Description
16779
16780 \series bold
16781 -f
16782 \series default
16783  Force.
16784  reLyX will not run if the 
16785 \family typewriter
16786 .lyx
16787 \family default
16788  file it would generate already exists Use the 
16789 \series bold
16790 -f
16791 \series default
16792  option (carefully) to clobber any existing files.
16793 \end_layout
16794
16795 \begin_layout Description
16796
16797 \series bold
16798 -h
16799 \series default
16800  Help.
16801  Print out usage information and quit
16802 \end_layout
16803
16804 \begin_layout Description
16805
16806 \series bold
16807 -o
16808 \series default
16809  Output directory.
16810  With this option, all temporary files and LyX output files (for the given
16811  input file, for any included files, or for any file fragments given with
16812  the 
16813 \series bold
16814 -p
16815 \series default
16816  option) will be put into 
16817 \shape italic
16818 outputdir
16819 \shape default
16820 .
16821  Otherwise, for each file 
16822 \emph on
16823 dir/foo.tex
16824 \emph default
16825 , the temporary files and the LyX output file will be created in 
16826 \emph on
16827 dir
16828 \emph default
16829 .
16830  This can be useful if a file includes files from other directories which
16831  you want to consolidate in one directory, or if you don't have write permission
16832  on the directory the LaTeX files are in.
16833 \end_layout
16834
16835 \begin_layout Description
16836
16837 \series bold
16838 -p
16839 \series default
16840  Partial file.
16841  The input files are LaTeX fragments, with no preamble matter or 
16842 \family typewriter
16843
16844 \backslash
16845 begin{document}
16846 \family default
16847  commands.
16848  This option requires the 
16849 \series bold
16850 -c
16851 \series default
16852  option, since there are no 
16853 \family typewriter
16854
16855 \backslash
16856 documentclass
16857 \family default
16858  commands in the files reLyX is translating.
16859  When using this option, you can translate more than one file, as long as
16860  all files are the same class.
16861  The LyX file created by reLyX can be included in an existing LyX file using
16862  
16863 \family sans
16864 \bar under
16865 I
16866 \bar default
16867 nsert\SpecialChar \menuseparator
16868 Fil
16869 \bar under
16870 e
16871 \bar default
16872 \SpecialChar \menuseparator
16873 Ly
16874 \bar under
16875 X
16876 \bar default
16877 \InsetSpace ~
16878 Document
16879 \family default
16880 .
16881 \end_layout
16882
16883 \begin_layout Description
16884
16885 \series bold
16886 -r
16887 \series default
16888  Regular environments (see the Section\InsetSpace ~
16889
16890 \begin_inset LatexCommand \ref{sub:relyx-syntax}
16891
16892 \end_inset
16893
16894 ).
16895   If you give more than one environment, separate them with commas (not
16896  spaces).
16897  You'll probably need to quote the environment list, especially if it has
16898  asterisk environments (foo*) in it.
16899  If you use this command often, considering creating a personal syntax file.
16900 \end_layout
16901
16902 \begin_layout Description
16903
16904 \series bold
16905 -s
16906 \series default
16907  Syntax files.
16908  Input (one or more quoted, comma-separated) syntax files to read in addition
16909  to the default.
16910  (see Section\InsetSpace ~
16911
16912 \begin_inset LatexCommand \ref{sub:relyx-syntax}
16913
16914 \end_inset
16915
16916  for details).
16917 \end_layout
16918
16919 \begin_layout Subsection
16920 Description
16921 \end_layout
16922
16923 \begin_layout Subsubsection
16924 Introduction
16925 \end_layout
16926
16927 \begin_layout Standard
16928 reLyX will create a LyX file 
16929 \emph on
16930 dir/foo.lyx
16931 \emph default
16932  from the LaTeX file 
16933 \emph on
16934 dir/foo.tex
16935 \emph default
16936  (unless the 
16937 \series bold
16938 -o
16939 \series default
16940  option is used).
16941 \end_layout
16942
16943 \begin_layout Standard
16944 Suffixes 
16945 \family typewriter
16946 .tex
16947 \family default
16948
16949 \family typewriter
16950 .ltx
16951 \family default
16952  and 
16953 \family typewriter
16954 .latex
16955 \family default
16956  are supported.
16957  If 
16958 \emph on
16959 inputfile
16960 \emph default
16961  does not exist and does not have one of these suffixes, reLyX will try
16962  to translate 
16963 \emph on
16964 inputfile.tex
16965 \emph default
16966 .
16967  (This is similar to the behavior of LaTeX.)
16968 \end_layout
16969
16970 \begin_layout Standard
16971 The purpose of reLyX is to translate 
16972 \shape italic
16973 well-behaved
16974 \shape default
16975  LaTeX2e into LyX.
16976  If your LaTeX file doesn't compile---or if you do weird things, like redefining
16977  standard LaTeX commands---it may choke.
16978  LaTeX209 will often be translated correctly, but it's not guaranteed.
16979 \end_layout
16980
16981 \begin_layout Standard
16982 reLyX has some bugs and lacks a few features.
16983  However, its main goals are:
16984 \end_layout
16985
16986 \begin_layout Itemize
16987 Get through a well-behaved LaTeX2e file without crashing
16988 \end_layout
16989
16990 \begin_layout Itemize
16991 Translate a lot of that file.
16992 \end_layout
16993
16994 \begin_layout Itemize
16995 Localize the parts that can't be translated and copy them in TeX mode
16996 \end_layout
16997
16998 \begin_layout Standard
16999 It achieves these main goals pretty well on most files.
17000 \end_layout
17001
17002 \begin_layout Standard
17003 There are many improvements that can and will be made to reLyX in the future.
17004  However, we wanted to get reLyX out there early on, to make it easier for
17005  new LyX users to read in their existing LaTeX files.
17006 \end_layout
17007
17008 \begin_layout Subsubsection
17009 Usage
17010 \end_layout
17011
17012 \begin_layout Standard
17013 Here's a more lengthy description of what you should do to translate a LaTeX
17014  document into LyX.
17015 \end_layout
17016
17017 \begin_layout Itemize
17018 Run reLyX.
17019 \end_layout
17020
17021 \begin_deeper
17022 \begin_layout Standard
17023 reLyX will inform you of its progress and give any warnings to stderr, so
17024  if you don't want any output at all, try (in csh) 
17025 \begin_inset Quotes eld
17026 \end_inset
17027
17028
17029 \family typewriter
17030 reLyX foo.tex >& /dev/null
17031 \family default
17032
17033 \begin_inset Quotes erd
17034 \end_inset
17035
17036  or (in bash) 
17037 \begin_inset Quotes eld
17038 \end_inset
17039
17040
17041 \family typewriter
17042 reLyX foo.tex
17043 \family default
17044  
17045 \family typewriter
17046 2>&1 >/dev/null
17047 \family default
17048
17049 \begin_inset Quotes erd
17050 \end_inset
17051
17052 .
17053  You should NOT redirect standard output to 
17054 \family typewriter
17055 foo.lyx
17056 \family default
17057 .
17058  
17059 \end_layout
17060
17061 \end_deeper
17062 \begin_layout Itemize
17063 Run LyX on the resulting .lyx file.
17064 \end_layout
17065
17066 \begin_deeper
17067 \begin_layout Standard
17068 In theory, most of the file will have been translated, and anything that's
17069  untranslatable will be highlighted in red (TeX mode).
17070  In theory, LyX will be able to read in the file, and to create printed
17071  documents from it, because all that untranslated red stuff will be passed
17072  directly back to LaTeX, which LyX  uses as a backend.
17073  Unfortunately, reality doesn't always reflect theory.
17074  If reLyX crashes, or LyX cannot read the generated LyX file, see Section\InsetSpace ~
17075
17076 \begin_inset LatexCommand \ref{sub:relyx-bugs}
17077
17078 \end_inset
17079
17080  or the 
17081 \family typewriter
17082 BUGS
17083 \family default
17084  file.
17085 \end_layout
17086
17087 \end_deeper
17088 \begin_layout Itemize
17089 Change things that are in ERT boxes (TeX code) by hand in LyX.
17090 \end_layout
17091
17092 \begin_deeper
17093 \begin_layout Standard
17094 As mentioned above, you should be able to print out the LyX file even without
17095  doing this.
17096  However, changing a command in TeX mode to the corresponding LyX object
17097  will allow you to take advantage of LyX's WYSIWYM editing.
17098 \end_layout
17099
17100 \begin_layout Standard
17101 reLyX is not guaranteed to create a LyX file which generates exactly the
17102  same output as the LaTeX file, but it should come close.
17103  reLyX will generally err on the side of translating less to ensure that
17104  DVI or PostScript® files are accurate, even though this leads to more 
17105 \begin_inset Quotes eld
17106 \end_inset
17107
17108 evil red text
17109 \begin_inset Quotes erd
17110 \end_inset
17111
17112  and less WYSIWYM.
17113 \end_layout
17114
17115 \end_deeper
17116 \begin_layout Itemize
17117 PROOFREAD THE DOCUMENT!!
17118 \end_layout
17119
17120 \begin_deeper
17121 \begin_layout Standard
17122 I'm sure you were planning on doing this anyway, but it's particularly important
17123  after translating a LaTeX document.
17124  reLyX is, at least now, better at 
17125 \begin_inset Quotes eld
17126 \end_inset
17127
17128 macro-translating
17129 \begin_inset Quotes erd
17130 \end_inset
17131
17132  (translating the whole document) than 
17133 \begin_inset Quotes eld
17134 \end_inset
17135
17136 micro-translating
17137 \begin_inset Quotes erd
17138 \end_inset
17139
17140  (translating every little detail).
17141  For example, you may see extra spaces or deleted spaces.
17142  Space handling has improved, but it's not perfect.
17143 \end_layout
17144
17145 \end_deeper
17146 \begin_layout Subsubsection
17147 What reLyX Can Handle
17148 \end_layout
17149
17150 \begin_layout Standard
17151 reLyX understands many LaTeX commands.
17152  It will translate:
17153 \end_layout
17154
17155 \begin_layout Itemize
17156 regular text, including mini-commands like ~, '', 
17157 \family typewriter
17158
17159 \backslash
17160 @
17161 \family default
17162
17163 \family typewriter
17164
17165 \backslash
17166 TeX
17167 \family default
17168 , as well as accented characters like 
17169 \family typewriter
17170
17171 \backslash
17172 '{a}
17173 \family default
17174 , and the special cases ?` and !`
17175 \end_layout
17176
17177 \begin_layout Itemize
17178 title commands like 
17179 \family typewriter
17180
17181 \backslash
17182 author
17183 \family default
17184
17185 \family typewriter
17186
17187 \backslash
17188 date
17189 \family default
17190
17191 \family typewriter
17192
17193 \backslash
17194 title
17195 \family default
17196
17197 \family typewriter
17198
17199 \backslash
17200 thanks
17201 \family default
17202  and the abstract environment
17203 \end_layout
17204
17205 \begin_layout Itemize
17206 heading commands like 
17207 \family typewriter
17208
17209 \backslash
17210 section
17211 \family default
17212  including starred commands (
17213 \family typewriter
17214
17215 \backslash
17216 section*
17217 \family default
17218 )
17219 \end_layout
17220
17221 \begin_layout Itemize
17222 Environments: 
17223 \family typewriter
17224 quote
17225 \family default
17226
17227 \family typewriter
17228 quotation
17229 \family default
17230 , and 
17231 \family typewriter
17232 verse
17233 \family default
17234
17235 \family typewriter
17236 center
17237 \family default
17238
17239 \family typewriter
17240 flushright
17241 \family default
17242 , and 
17243 \family typewriter
17244 flushleft
17245 \end_layout
17246
17247 \begin_layout Itemize
17248
17249 \family typewriter
17250 itemize
17251 \family default
17252
17253 \family typewriter
17254 enumerate
17255 \family default
17256 , and 
17257 \family typewriter
17258 description
17259 \family default
17260  environments, and their 
17261 \family typewriter
17262
17263 \backslash
17264 item
17265 \family default
17266  commands.
17267  Also, well-behaved nested lists
17268 \end_layout
17269
17270 \begin_layout Itemize
17271 cross-referencing commands: 
17272 \family typewriter
17273
17274 \backslash
17275 ref
17276 \family default
17277
17278 \family typewriter
17279
17280 \backslash
17281 pageref
17282 \family default
17283
17284 \family typewriter
17285
17286 \backslash
17287 label
17288 \family default
17289 , and 
17290 \family typewriter
17291
17292 \backslash
17293 cite
17294 \end_layout
17295
17296 \begin_layout Itemize
17297
17298 \family typewriter
17299
17300 \backslash
17301 footnote
17302 \family default
17303  and 
17304 \family typewriter
17305
17306 \backslash
17307 margin
17308 \end_layout
17309
17310 \begin_layout Itemize
17311 font-changing commands including 
17312 \family typewriter
17313
17314 \backslash
17315 em
17316 \family default
17317
17318 \family typewriter
17319
17320 \backslash
17321 emph
17322 \family default
17323
17324 \family typewriter
17325
17326 \backslash
17327 textit
17328 \family default
17329 , and corresponding commands to change family, size, series, and shape
17330 \end_layout
17331
17332 \begin_layout Itemize
17333
17334 \family typewriter
17335
17336 \backslash
17337 input{foo}
17338 \family default
17339  (or 
17340 \family typewriter
17341
17342 \backslash
17343 input{foo.blah}
17344 \family default
17345 ) and 
17346 \family typewriter
17347
17348 \backslash
17349 include{foo}
17350 \family default
17351 .
17352  Plain TeX 
17353 \family typewriter
17354
17355 \backslash
17356 input
17357 \family default
17358  command ``
17359 \family typewriter
17360
17361 \backslash
17362 input foo.tex
17363 \family default
17364
17365 \begin_inset Quotes erd
17366 \end_inset
17367
17368  is also supported.
17369 \end_layout
17370
17371 \begin_layout Itemize
17372
17373 \family typewriter
17374 tabular
17375 \family default
17376  environment, and commands that go inside it like 
17377 \family typewriter
17378
17379 \backslash
17380 hline
17381 \family default
17382
17383 \family typewriter
17384
17385 \backslash
17386 cline
17387 \family default
17388 , and 
17389 \family typewriter
17390
17391 \backslash
17392 multicolumn
17393 \family default
17394  (but see below)
17395 \end_layout
17396
17397 \begin_layout Itemize
17398 float environments 
17399 \family typewriter
17400 table
17401 \family default
17402  and 
17403 \family typewriter
17404 table*
17405 \family default
17406 , as well as 
17407 \family typewriter
17408
17409 \backslash
17410 caption
17411 \family default
17412  commands within them
17413 \end_layout
17414
17415 \begin_layout Itemize
17416
17417 \family typewriter
17418 thebibliography
17419 \family default
17420  environment and 
17421 \family typewriter
17422
17423 \backslash
17424 bibitem
17425 \family default
17426  command, as well as BibTeX's 
17427 \family typewriter
17428
17429 \backslash
17430 bibliography
17431 \family default
17432  and 
17433 \family typewriter
17434
17435 \backslash
17436 bibliographystyle
17437 \family default
17438  commands
17439 \end_layout
17440
17441 \begin_layout Itemize
17442 miscellaneous commands: 
17443 \family typewriter
17444
17445 \backslash
17446 hfill
17447 \family default
17448
17449 \family typewriter
17450
17451 \backslash
17452
17453 \backslash
17454
17455 \family default
17456
17457 \family typewriter
17458
17459 \backslash
17460 noindent
17461 \family default
17462
17463 \family typewriter
17464
17465 \backslash
17466 ldots
17467 \family default
17468 ...
17469 \end_layout
17470
17471 \begin_layout Itemize
17472 documentclass-specific environments (and some commands) which can be  translated
17473  to LyX layouts
17474 \end_layout
17475
17476 \begin_layout Itemize
17477 arguments to certain untranslatable commands (e.g.
17478  
17479 \family typewriter
17480
17481 \backslash
17482 mbox
17483 \family default
17484 )
17485 \end_layout
17486
17487 \begin_layout Standard
17488 Some of this support may not be 100% yet.
17489  See below for details
17490 \end_layout
17491
17492 \begin_layout Standard
17493 reLyX copies math (almost) verbatim from your LaTeX file.
17494  Luckily, LyX reads  in LaTeX math, so (almost) any math which is supported
17495  by LyX should work just fine.
17496  A few math commands which are not supported by LyX will be replaced with
17497  their equivalents, e.g., 
17498 \family typewriter
17499
17500 \backslash
17501 to
17502 \family default
17503  is converted to 
17504 \family typewriter
17505
17506 \backslash
17507 rightarrow
17508 \family default
17509 .
17510  See the section on 
17511 \shape italic
17512 Syntax Files
17513 \shape default
17514  for more details.
17515 \end_layout
17516
17517 \begin_layout Standard
17518 reLyX will also copy any preamble commands (i.e., anything before 
17519 \family typewriter
17520
17521 \backslash
17522 begin{document}
17523 \family default
17524 ) verbatim, so fancy stuff you've got in your preamble should be conserved
17525  in DVI and printed documents, although it will not of course show up in
17526  the LyX window.
17527  Check the preamble to make sure.
17528 \end_layout
17529
17530 \begin_layout Subsubsection
17531 What reLyX Can't Handle --- But it's OK
17532 \end_layout
17533
17534 \begin_layout Itemize
17535 figures and 
17536 \family typewriter
17537 tabular*
17538 \family default
17539  tables
17540 \end_layout
17541
17542 \begin_layout Itemize
17543 minipages
17544 \end_layout
17545
17546 \begin_layout Itemize
17547 spacing commands (
17548 \family typewriter
17549
17550 \backslash
17551 vspace
17552 \family default
17553
17554 \family typewriter
17555
17556 \backslash
17557 pagebreak
17558 \family default
17559
17560 \family typewriter
17561
17562 \backslash
17563 par
17564 \family default
17565 )
17566 \end_layout
17567
17568 \begin_layout Itemize
17569
17570 \family typewriter
17571
17572 \backslash
17573 centering
17574 \family default
17575
17576 \family typewriter
17577
17578 \backslash
17579 raggedleft
17580 \family default
17581
17582 \family typewriter
17583
17584 \backslash
17585 raggedright
17586 \end_layout
17587
17588 \begin_layout Itemize
17589
17590 \family typewriter
17591
17592 \backslash
17593 verb
17594 \family default
17595  and 
17596 \family typewriter
17597 verbatim
17598 \family default
17599  environment.
17600  reLyX is careful to copy 
17601 \shape italic
17602 exactly
17603 \shape default
17604  in this case, including comments and whitespace.
17605 \end_layout
17606
17607 \begin_layout Itemize
17608 some unknown (e.g., user-defined) environments and commands
17609 \end_layout
17610
17611 \begin_layout Standard
17612 reLyX copies unknown commands, along with their arguments, verbatim into
17613  the LyX file.
17614  Also, if it sees a 
17615 \family typewriter
17616
17617 \backslash
17618 begin{foo}
17619 \family default
17620  where it doesn't recognize the 
17621 \begin_inset Quotes eld
17622 \end_inset
17623
17624 foo
17625 \begin_inset Quotes erd
17626 \end_inset
17627
17628  environment, it will copy verbatim until it sees 
17629 \family typewriter
17630
17631 \backslash
17632 end{foo}
17633 \family default
17634  (unless you use the 
17635 \series bold
17636 -r
17637 \series default
17638  option).
17639  Hopefully, then, most of these unknown commands won't cause reLyX to break;
17640  they'll merely require you to do some editing once you've loaded the file
17641  up in LyX.
17642   That should be less painful than editing either the 
17643 \family typewriter
17644 .tex
17645 \family default
17646  or the 
17647 \family typewriter
17648 .lyx
17649 \family default
17650  file using a text editor.
17651 \end_layout
17652
17653 \begin_layout Subsubsection
17654 What reLyX Handles Badly --- a.\InsetSpace ~
17655 k.\InsetSpace ~
17656 a.
17657  BUGS
17658 \begin_inset LatexCommand \label{sub:relyx-bugs}
17659
17660 \end_inset
17661
17662
17663 \end_layout
17664
17665 \begin_layout Standard
17666 Since reLyX is relatively new, it's got a number of problems.
17667   As it matures, these bugs will be squished.
17668  A number of bugs and missing features can be found listed on the LyX bug
17669  tracker, 
17670 \begin_inset LatexCommand \url[LyX Bugzilla]{http://bugzilla.lyx.org/}
17671
17672 \end_inset
17673
17674 .
17675 \end_layout
17676
17677 \begin_layout Standard
17678 If reLyX is choking on something, or LyX can't read it after reLyX translates
17679  it, the best thing to do is to put 
17680 \family typewriter
17681
17682 \backslash
17683 begin{reLyXskip}
17684 \family default
17685  before the offending text, and 
17686 \family typewriter
17687
17688 \backslash
17689 end{reLyXskip}
17690 \family default
17691  after it.
17692  I call this a 
17693 \begin_inset Quotes eld
17694 \end_inset
17695
17696 skip
17697 \begin_inset Quotes erd
17698 \end_inset
17699
17700  block.
17701  reLyX will copy this block exactly, in TeX mode.
17702  Then edit the resulting LyX file, and translate the unknown stuff by hand.
17703  The 
17704 \family typewriter
17705 reLyXskip
17706 \family default
17707  environment is magical; the 
17708 \family typewriter
17709
17710 \backslash
17711 begin
17712 \family default
17713  and 
17714 \family typewriter
17715
17716 \backslash
17717 end
17718 \family default
17719  commands will not be put into the LyX file.
17720 \end_layout
17721
17722 \begin_layout Itemize
17723 \begin_inset Quotes eld
17724 \end_inset
17725
17726 Exact
17727 \begin_inset Quotes erd
17728 \end_inset
17729
17730  copying of unknown environments and commands isn't quite exact.
17731  Specifically, newlines and comments may be lost.
17732  This will yield ugly LyX, but in almost all cases the output will be the
17733  same.
17734  However, certain parts of the file will be copied perfectly, including
17735  whitespace and comments.
17736  This includes: the LaTeX preamble, 
17737 \family typewriter
17738 verbatim
17739 \family default
17740  environments and 
17741 \family typewriter
17742
17743 \backslash
17744 verb
17745 \family default
17746  commands, and skip blocks.
17747 \end_layout
17748
17749 \begin_layout Itemize
17750 reLyX translates only a few options to the 
17751 \family typewriter
17752
17753 \backslash
17754 documentclass
17755 \family default
17756  command.
17757  (Specifically 1[012]pt, [letter|legal|executive|a4|a5|b5]paper, [one|two]side,
17758  landscape, and [one|two]column.) Other options are placed in the extra class
17759  options field in the 
17760 \family sans
17761 \bar under
17762 D
17763 \bar default
17764 ocument\SpecialChar \menuseparator
17765
17766 \bar under
17767 S
17768 \bar default
17769 ettings
17770 \family default
17771  dialog.
17772 \end_layout
17773
17774 \begin_deeper
17775 \begin_layout Standard
17776 More importantly, reLyX doesn't translate 
17777 \family typewriter
17778
17779 \backslash
17780 usepackage
17781 \family default
17782  commands, margin  commands, 
17783 \family typewriter
17784
17785 \backslash
17786 newcommand
17787 \family default
17788 s, or, in fact, anything else from the preamble.
17789  It simply copies them into the LaTeX preamble.
17790  If you have margin commands in your preamble, then the LyX file will generate
17791  the right margins.
17792  However, these margins will override any margins you set in the LyX 
17793 \family sans
17794 \bar under
17795 D
17796 \bar default
17797 ocument
17798 \bar under
17799 \SpecialChar \menuseparator
17800 S
17801 \bar default
17802 ettings
17803 \family default
17804  dialog.
17805  So you should remove the options from the preamble to be safe.
17806  The same goes for setting your language with babel, 
17807 \family typewriter
17808
17809 \backslash
17810 inputencoding
17811 \family default
17812
17813 \family typewriter
17814
17815 \backslash
17816 pagestyle
17817 \family default
17818 , etc.
17819 \end_layout
17820
17821 \end_deeper
17822 \begin_layout Itemize
17823 The foil class has a couple bugs.
17824  reLyX may do weird things with optional arguments to 
17825 \family typewriter
17826
17827 \backslash
17828 foilhead
17829 \family default
17830  commands.
17831  Also, it may handle 
17832 \family typewriter
17833
17834 \backslash
17835 begin{dinglist}
17836 \family default
17837  incorrectly (although the stuff in the environment should translate normally).
17838 \end_layout
17839
17840 \begin_layout Standard
17841 reLyX is hopefully rather robust.
17842  As mentioned above, it may not translate your file perfectly, but it shouldn't
17843  crash.
17844  If it does crash---and the problem is not one of those mentioned above
17845  or in the 
17846 \emph on
17847 BUGS
17848 \emph default
17849  file---see Section\InsetSpace ~
17850
17851 \begin_inset LatexCommand \ref{sub:relyx-bug-reports}
17852
17853 \end_inset
17854
17855 .
17856 \end_layout
17857
17858 \begin_layout Subsubsection
17859 What LyX Can't Handle
17860 \end_layout
17861
17862 \begin_layout Standard
17863 LyX itself is missing a couple features, such that even if reLyX translates
17864  things perfectly, LyX may still have trouble reading it.
17865  If you really need these features, you can export your final document as
17866  LaTeX, and put them back in.
17867  See 
17868 \emph on
17869 BUGS
17870 \emph default
17871  for more details on these bugs.
17872 \end_layout
17873
17874 \begin_layout Itemize
17875 For a number of commands, LyX does not support the optional argument.
17876  Examples include 
17877 \family typewriter
17878
17879 \backslash
17880 sqrt
17881 \family default
17882
17883 \family typewriter
17884
17885 \backslash
17886 chapter
17887 \family default
17888  (and other sectioning commands), and 
17889 \family typewriter
17890
17891 \backslash
17892
17893 \backslash
17894
17895 \family default
17896 .
17897  reLyX will automatically discard the optional arguments with a warning
17898  to stdout.
17899  LyX also ignores the width argument for the 
17900 \family typewriter
17901 thebibliography
17902 \family default
17903  environment.
17904 \end_layout
17905
17906 \begin_layout Itemize
17907 Centering (or right or left justifying) works on full paragraphs.
17908 \end_layout
17909
17910 \begin_layout Itemize
17911 LyX support for tables isn't perfect.
17912  For complicated tables, use a 
17913 \begin_inset Quotes eld
17914 \end_inset
17915
17916 skip
17917 \begin_inset Quotes erd
17918 \end_inset
17919
17920  block, so that they will be copied in TeX mode.
17921 \end_layout
17922
17923 \begin_layout Itemize
17924 The LyX math editor can't handle the AMS-LaTeX math environments align,
17925  split, etc.
17926  So those environments will be copied in TeX mode.
17927  You can change 
17928 \family typewriter
17929 equation*
17930 \family default
17931  environments to the exactly equivalent displaymath, and then they will
17932  be translated correctly.
17933 \end_layout
17934
17935 \begin_layout Subsection
17936 Examples
17937 \end_layout
17938
17939 \begin_layout Standard
17940
17941 \family typewriter
17942 reLyX -df -o 
17943 \begin_inset Quotes eld
17944 \end_inset
17945
17946 my/dir
17947 \begin_inset Quotes erd
17948 \end_inset
17949
17950  -r 
17951 \begin_inset Quotes eld
17952 \end_inset
17953
17954 myenv
17955 \begin_inset Quotes erd
17956 \end_inset
17957
17958  foo.tex > foo.debug
17959 \end_layout
17960
17961 \begin_layout Standard
17962 The above will create a file my/dir/foo.lyx from foo.tex, overwriting if necessary.
17963   When it finds a 
17964 \family typewriter
17965
17966 \backslash
17967 begin{myenv} ...
17968  
17969 \backslash
17970 end{myenv}
17971 \family default
17972  block, it will translate the stuff within the block, but copy the 
17973 \family typewriter
17974
17975 \backslash
17976 begin
17977 \family default
17978  and 
17979 \family typewriter
17980
17981 \backslash
17982 end
17983 \family default
17984  commands in TeX mode.
17985   Finally, I'm going to keep the temporary files around (they will also
17986  be in my/dir/) and output lots of debugging information into the file foo.debug.
17987 \end_layout
17988
17989 \begin_layout Subsection
17990 Notes
17991 \end_layout
17992
17993 \begin_layout Subsubsection
17994 Bug Reports
17995 \begin_inset LatexCommand \label{sub:relyx-bug-reports}
17996
17997 \end_inset
17998
17999
18000 \end_layout
18001
18002 \begin_layout Standard
18003 If reLyX is crashing or otherwise acting strangely---in ways other than
18004  those described in Section\InsetSpace ~
18005
18006 \begin_inset LatexCommand \ref{sub:relyx-bugs}
18007
18008 \end_inset
18009
18010  or the bug tracker---then please run reLyX
18011 \series bold
18012  -d
18013 \series default
18014 .
18015   That will allow you to figure out where in the reLyXing process it crashed.
18016  That, in turn, will allow you to write a better bug report, which will
18017  allow the developers to fix it more quickly and easily.
18018 \end_layout
18019
18020 \begin_layout Standard
18021 Bug reports should be sent to the LyX developers' mailing list.
18022  Its address is currently 
18023 \family typewriter
18024 lyx-devel@lists.lyx.org
18025 \family default
18026 .
18027  If you are running reLyX on a huge file, please do not send all of the
18028  output in your bug report.
18029  Just include the last ten or twenty lines of output, along with the piece
18030  of the LaTeX file it crashed on.
18031   Or, even better, attach a small but complete file which causes the same
18032  problem as your original file.
18033 \end_layout
18034
18035 \begin_layout Subsubsection
18036 Implementation Details:
18037 \end_layout
18038
18039 \begin_layout Standard
18040 reLyX makes several 
18041 \begin_inset Quotes eld
18042 \end_inset
18043
18044 passes
18045 \begin_inset Quotes erd
18046 \end_inset
18047
18048  in order to translate a TeX file.
18049  On each pass, it creates one or two files.
18050 \end_layout
18051
18052 \begin_layout Description
18053 Pass\InsetSpace ~
18054 0 \InsetSpace ~
18055
18056 \newline
18057 Before doing anything, read the syntax file (or files).
18058 \end_layout
18059
18060 \begin_layout Description
18061 Pass\InsetSpace ~
18062 1a \InsetSpace ~
18063
18064 \newline
18065 Split preamble (anything before a 
18066 \family typewriter
18067
18068 \backslash
18069 begin{document}
18070 \family default
18071  command) off the rest of the file.
18072  It saves the two pieces in separate files.
18073  This is necessary because there may be very strange stuff in a preamble.
18074  It also ignores anything after the 
18075 \family typewriter
18076
18077 \backslash
18078 end{document}
18079 \family default
18080 , on the assumption that it isn't LaTeX.
18081 \end_layout
18082
18083 \begin_layout Description
18084 Pass\InsetSpace ~
18085 1b \InsetSpace ~
18086
18087 \newline
18088 Translate the preamble.
18089  Currently, that just means translating the 
18090 \family typewriter
18091
18092 \backslash
18093 documentclass
18094 \family default
18095  command and copying the rest exactly into the LyX preamble.
18096 \end_layout
18097
18098 \begin_deeper
18099 \begin_layout Standard
18100 Once you know what class the document is, read the LyX layout file for that
18101  class.
18102 \end_layout
18103
18104 \end_deeper
18105 \begin_layout Description
18106 Pass\InsetSpace ~
18107 2 \InsetSpace ~
18108
18109 \newline
18110
18111 \begin_inset Quotes eld
18112 \end_inset
18113
18114 Clean
18115 \begin_inset Quotes erd
18116 \end_inset
18117
18118  the TeX file, generating slightly stricter LaTeX.
18119  This includes:
18120 \end_layout
18121
18122 \begin_deeper
18123 \begin_layout Itemize
18124 Change, e.g., 
18125 \family typewriter
18126 x^2
18127 \family default
18128  to the equivalent but clearer 
18129 \family typewriter
18130 x^{2}
18131 \end_layout
18132
18133 \begin_layout Itemize
18134 Removing optional arguments that LyX can't handle (e.g., from 
18135 \family typewriter
18136
18137 \backslash
18138 sqrt
18139 \family default
18140 )
18141 \end_layout
18142
18143 \begin_layout Itemize
18144 Changing 
18145 \family typewriter
18146 {
18147 \backslash
18148 em foo}
18149 \family default
18150  to 
18151 \family typewriter
18152
18153 \backslash
18154 emph{foo}
18155 \family default
18156 , etc.
18157  This is necessary because LyX always writes out the non-local forms anyway.
18158  This should very rarely make a difference.
18159 \end_layout
18160
18161 \end_deeper
18162 \begin_layout Description
18163 Pass\InsetSpace ~
18164 3 \InsetSpace ~
18165
18166 \newline
18167 Translate LaTeX text, commands, and environments to LyX.
18168 \end_layout
18169
18170 \begin_layout Description
18171 Pass\InsetSpace ~
18172 4 \InsetSpace ~
18173
18174 \newline
18175 Put the two pieces back together, and do some final tweaking, to generate
18176  the LyX file
18177 \end_layout
18178
18179 \begin_layout Standard
18180 If there are any 
18181 \family typewriter
18182
18183 \backslash
18184 input
18185 \family default
18186  or 
18187 \family typewriter
18188
18189 \backslash
18190 include
18191 \family default
18192  commands, reLyX will loop back to the beginning and translate those.
18193  It assumes that the included files are the same class as the main file,
18194  and that they have no preamble matter.
18195  (If you have an 
18196 \family typewriter
18197
18198 \backslash
18199 input
18200 \family default
18201  command in the preamble of a file, the command will be copied exactly into
18202  the LaTeX preamble portion of the LyX file, so the included file won't
18203  be translated.) So when translating included files, it skips passes 0 and
18204  1.
18205 \end_layout
18206
18207 \begin_layout Standard
18208 If reLyX doesn't find a file you wanted to include, it will give a warning,
18209  but will continue to translate any files it does find.
18210 \end_layout
18211
18212 \begin_layout Subsubsection
18213 Layout Files
18214 \end_layout
18215
18216 \begin_layout Standard
18217 reLyX reads a LyX layout file to know how to handle LaTeX environments and
18218  commands which get translated to LyX layouts.
18219  This file will include all 
18220 \begin_inset Quotes eld
18221 \end_inset
18222
18223 normal
18224 \begin_inset Quotes erd
18225 \end_inset
18226
18227  non-math environments (i.e., including quote and itemize, but not tabular,
18228  minipage, and some other fancy environments), and commands like 
18229 \family typewriter
18230
18231 \backslash
18232 section
18233 \family default
18234  and 
18235 \family typewriter
18236
18237 \backslash
18238 title
18239 \family default
18240 .
18241  If you want to reLyX a class that doesn't have an existing layout file,
18242  then you'll have to create a layout file.
18243  But you have to do this anyway, in order to LyX the file, since LyX depends
18244  on layout files to know how to display and process its files.
18245  Check the LyX documentation for help with this task (which can be hard
18246  or easy, depending on the class you want to create a layout file for.) If
18247  your class is quite similar to a class that has a layout file, then consider
18248  using the 
18249 \series bold
18250 -c
18251 \series default
18252  option.
18253 \end_layout
18254
18255 \begin_layout Subsubsection
18256 Syntax Files
18257 \begin_inset LatexCommand \label{sub:relyx-syntax}
18258
18259 \end_inset
18260
18261
18262 \end_layout
18263
18264 \begin_layout Standard
18265 reLyX always reads at least one syntax file, called the default syntax file.
18266  reLyX will read your personal syntax file if it exists; otherwise it will
18267  read the system-wide file.
18268  reLyX will read additional syntax files if you specify them with the 
18269 \series bold
18270 -s
18271 \series default
18272  option.
18273  (These extra files should have the same format as the default file, but
18274  will tend to be shorter, since they only have to specify extra commands
18275  not found in the default file.) A syntax file tells reLyX a few things.
18276 \end_layout
18277
18278 \begin_layout Standard
18279 First, it describes the syntax of each command, that is, how many required
18280  arguments and how many optional arguments the command takes.
18281  Knowing this makes it easier for reLyX to copy (in TeX mode) commands that
18282  it doesn't know how to translate.
18283  The syntax file simply has a command, followed by braces or brackets describing
18284  its arguments in the correct order.
18285  For example, a syntax file entry 
18286 \family typewriter
18287
18288 \backslash
18289 bibitem[]{}
18290 \family default
18291  means that the 
18292 \family typewriter
18293
18294 \backslash
18295 bibitem
18296 \family default
18297  command takes an optional argument followed by a required one, while the
18298  entry 
18299 \family typewriter
18300
18301 \backslash
18302 bf
18303 \family default
18304  means that the 
18305 \family typewriter
18306
18307 \backslash
18308 bf
18309 \family default
18310  command takes no arguments at all.
18311   When reLyX encounters a token that it doesn't know how to translate into
18312  LyX, it will copy the token---along with the correct number of arguments---exac
18313 tly.
18314   If the token is not in the syntax file, then reLyX just copies as many
18315  arguments as it finds.
18316   This means that it may copy too much.
18317  But since the user can specify additional syntax files, that shouldn't
18318  happen often.
18319 \end_layout
18320
18321 \begin_layout Standard
18322 Some commands that cannot be translated to LyX, like 
18323 \family typewriter
18324
18325 \backslash
18326 mbox
18327 \family default
18328 , have as one of their arguments regular LaTeX text.
18329  If the string 
18330 \begin_inset Quotes eld
18331 \end_inset
18332
18333 translate
18334 \begin_inset Quotes erd
18335 \end_inset
18336
18337  is put into an argument of an (untranslatable) command in the syntax file,
18338  then reLyX will translate that argument instead of copying it verbatim.
18339  So, for example, the default syntax file has 
18340 \family typewriter
18341
18342 \backslash
18343 raisebox{}[][]{translate}
18344 \family default
18345 .
18346  This means that the 
18347 \family typewriter
18348
18349 \backslash
18350 raisebox
18351 \family default
18352  command and the first argument (and optional arguments if they exist) are
18353  copied in TeX mode, but the last argument (which may contain math, complicated
18354  LaTeX, other untranslatable commands, etc.) will be translated into LyX.
18355  You can't use 
18356 \begin_inset Quotes eld
18357 \end_inset
18358
18359 translate
18360 \begin_inset Quotes erd
18361 \end_inset
18362
18363  on optional arguments.
18364 \end_layout
18365
18366 \begin_layout Standard
18367 User-defined syntax files are allowed to define new commands and their syntax,
18368  or override the number of arguments for a command given in the default
18369  syntax file.
18370  (E.g., if you're using a style that gives an extra argument to some command...)
18371  However, this will only be useful for commands copied in TeX mode.
18372  Commands which are actually translated by reLyX (like 
18373 \family typewriter
18374
18375 \backslash
18376 item
18377 \family default
18378 ) have their argument syntax hard-coded.
18379  The hard-coded commands are identified in the default syntax file.
18380 \end_layout
18381
18382 \begin_layout Standard
18383 Second, the syntax file describes any 
18384 \begin_inset Quotes eld
18385 \end_inset
18386
18387 regular environments
18388 \begin_inset Quotes erd
18389 \end_inset
18390
18391 .
18392   Usually, an entire unknown environment will be copied in TeX mode.
18393  If you define a regular environment 
18394 \begin_inset Quotes eld
18395 \end_inset
18396
18397 foo
18398 \begin_inset Quotes erd
18399 \end_inset
18400
18401 , though, then only the 
18402 \family typewriter
18403
18404 \backslash
18405 begin{foo}
18406 \family default
18407  and 
18408 \family typewriter
18409
18410 \backslash
18411 end{foo}
18412 \family default
18413  commands will be copied in TeX mode; the text within the environment will
18414  be treated (i.e., translated) by reLyX as regular LaTeX, rather than being
18415  copied into TeX mode.
18416  Don't try to declare 
18417 \family typewriter
18418 tabbing
18419 \family default
18420  and 
18421 \family typewriter
18422 picture
18423 \family default
18424  as regular environments, as the text within those environments will confuse
18425  reLyX; use this capability for new environments you create that have plain
18426  text or math or simple commands in them.
18427  You also can't declare unknown math environments (like 
18428 \family typewriter
18429 equation*
18430 \family default
18431 ) as regular environments, either, since the LyX math editor won't understand
18432  them.
18433  The names of regular environments appear, whitespace-separated, between
18434  
18435 \family typewriter
18436
18437 \backslash
18438 begin{reLyXre}
18439 \family default
18440  and 
18441 \family typewriter
18442
18443 \backslash
18444 end{reLyXre}
18445 \family default
18446  statements in the syntax file.
18447  (If you have a regular environment which you won't use very often, you
18448  can use the 
18449 \series bold
18450 -r
18451 \series default
18452  option rather than writing a syntax file.)
18453 \end_layout
18454
18455 \begin_layout Standard
18456 Third, the syntax file describes a math translation table.
18457  The LyX math editor doesn't support a few commands.
18458  For example, 
18459 \family typewriter
18460 _
18461 \family default
18462  is supported, but the equivalent 
18463 \family typewriter
18464
18465 \backslash
18466 sb
18467 \family default
18468  is not.
18469  Put any commands you'd like translate between 
18470 \family typewriter
18471
18472 \backslash
18473 begin{reLyXmt}
18474 \family default
18475  and 
18476 \family typewriter
18477
18478 \backslash
18479 end{reLyXmt}
18480 \family default
18481  statements.
18482  The statement 
18483 \begin_inset Quotes eld
18484 \end_inset
18485
18486
18487 \family typewriter
18488
18489 \backslash
18490 | {
18491 \backslash
18492 Vert}
18493 \family default
18494
18495 \begin_inset Quotes erd
18496 \end_inset
18497
18498  means that any 
18499 \family typewriter
18500
18501 \backslash
18502 |
18503 \family default
18504  in math mode will be converted to 
18505 \begin_inset Quotes eld
18506 \end_inset
18507
18508
18509 \family typewriter
18510
18511 \backslash
18512 Vert
18513 \family default
18514  
18515 \begin_inset Quotes erd
18516 \end_inset
18517
18518
18519 \family typewriter
18520  
18521 \family default
18522 (in cases where a token made up of a backslash and a non-letter is translated
18523  to something with letters at the end, a space is added by reLyX.
18524  That way, 
18525 \begin_inset Quotes eld
18526 \end_inset
18527
18528
18529 \family typewriter
18530
18531 \backslash
18532 |a
18533 \family default
18534
18535 \begin_inset Quotes erd
18536 \end_inset
18537
18538  is correctly translated to 
18539 \begin_inset Quotes eld
18540 \end_inset
18541
18542
18543 \family typewriter
18544
18545 \backslash
18546 Vert a
18547 \family default
18548
18549 \begin_inset Quotes erd
18550 \end_inset
18551
18552 ).
18553 \end_layout
18554
18555 \begin_layout Subsubsection
18556 Miscellaneous
18557 \end_layout
18558
18559 \begin_layout Standard
18560 You need Perl version 5.002 or later to run reLyX.
18561  <plug> If you don't have Perl, you should get it anyway (at 
18562 \begin_inset LatexCommand \url[Perl]{http://www.perl.com/}
18563
18564 \end_inset
18565
18566 ), because it's a really useful tool for pretty much anything.
18567  </plug>
18568 \end_layout
18569
18570 \begin_layout Subsection
18571 Diagnostics
18572 \end_layout
18573
18574 \begin_layout Standard
18575 reLyX should always explain why it crashes, if it crashes.
18576  Some diagnostics may be very technical, though, if they come from the guts
18577  of the code.
18578  reLyX gives much more information while running if you use the 
18579 \series bold
18580 -d
18581 \series default
18582  option, but you shouldn't need that unless something goes wrong.
18583 \end_layout
18584
18585 \begin_layout Standard
18586 When it's finished, reLyX will tell you if it finished successfully or died
18587  due to some error.
18588 \end_layout
18589
18590 \begin_layout Subsection
18591 Warnings
18592 \end_layout
18593
18594 \begin_layout Standard
18595 Always keep a copy of your original LaTeX files either under a different
18596  name or in a different directory.
18597  There are a couple ways in which using LyX could lead to overwriting the
18598  original LaTeX file.
18599 \end_layout
18600
18601 \begin_layout Standard
18602 If you import 
18603 \family typewriter
18604 foo.tex
18605 \family default
18606  to create 
18607 \family typewriter
18608 foo.lyx
18609 \family default
18610 , then edit 
18611 \family typewriter
18612 foo.lyx
18613 \family default
18614  and want to re-export it, note that it will overwrite the original 
18615 \family typewriter
18616 foo.tex
18617 \family default
18618 .
18619  (LyX will 
18620 \emph on
18621 not
18622 \emph default
18623  ask you if you want to overwrite it.)
18624 \end_layout
18625
18626 \begin_layout Standard
18627 If you have chosen not to use a temporary directory in the preferences,
18628  then LyX will create its temporary files in your current directory, which
18629  means your LaTeX original may be overwritten (without a warning from LyX)
18630  when you 
18631 \begin_inset Quotes eld
18632 \end_inset
18633
18634 View DVI
18635 \begin_inset Quotes erd
18636 \end_inset
18637
18638  or print the LyX document.
18639 \end_layout
18640
18641 \begin_layout Subsection
18642 Files
18643 \end_layout
18644
18645 \begin_layout Description
18646
18647 \family typewriter
18648 \series medium
18649 MY_LYXDIR/layouts/*.layout
18650 \family default
18651 \series default
18652  \InsetSpace ~
18653
18654 \newline
18655 User's personal layout files for document classes
18656 \end_layout
18657
18658 \begin_layout Description
18659
18660 \family typewriter
18661 \series medium
18662 MY_LYXDIR/reLyX/syntax.default
18663 \family default
18664 \series default
18665  \InsetSpace ~
18666
18667 \newline
18668 User's personal syntax file
18669 \end_layout
18670
18671 \begin_layout Description
18672
18673 \family typewriter
18674 \series medium
18675 LIBDIR/layouts/*.layout
18676 \family default
18677 \series default
18678  \InsetSpace ~
18679
18680 \newline
18681 System-wide layout files for document classes
18682 \end_layout
18683
18684 \begin_layout Description
18685
18686 \family typewriter
18687 \series medium
18688 LIBDIR/reLyX/syntax.default
18689 \family default
18690 \series default
18691  \InsetSpace ~
18692
18693 \newline
18694 System-wide LaTeX syntax file
18695 \end_layout
18696
18697 \begin_layout Standard
18698
18699 \family typewriter
18700 LIBDIR
18701 \family default
18702  is the system-wide LyX directory, usually something like 
18703 \family typewriter
18704 /usr/local/share/lyx/
18705 \family default
18706 .
18707  
18708 \family typewriter
18709 MY_LYXDIR
18710 \family default
18711  is your personal LyX directory, something like 
18712 \family typewriter
18713 .lyx/
18714 \family default
18715  in your home directory.
18716  You can see their actual values in the 
18717 \family sans
18718 \bar under
18719 H
18720 \bar default
18721 elp\SpecialChar \menuseparator
18722 About\InsetSpace ~
18723 Ly
18724 \bar under
18725 X
18726 \family default
18727 \bar default
18728  dialog.
18729 \end_layout
18730
18731 \begin_layout Subsection
18732 See also
18733 \end_layout
18734
18735 \begin_layout Standard
18736
18737 \shape italic
18738 lyx
18739 \shape default
18740 (1), 
18741 \shape italic
18742 latex
18743 \shape default
18744 (1)
18745 \end_layout
18746
18747 \begin_layout Subsection
18748 Authors
18749 \end_layout
18750
18751 \begin_layout Standard
18752 Copyright (c) 1998--9 
18753 \noun on
18754 Amir Karger
18755 \noun default
18756  (
18757 \family typewriter
18758 karger@voth.chem.utah.edu
18759 \family default
18760 )
18761 \end_layout
18762
18763 \begin_layout Standard
18764 Code contributors:
18765 \end_layout
18766
18767 \begin_layout Itemize
18768
18769 \noun on
18770 John Weiss
18771 \noun default
18772  wrote the original CleanTeX pass.
18773 \end_layout
18774
18775 \begin_layout Itemize
18776
18777 \noun on
18778 Etienne Grossmann
18779 \end_layout
18780
18781 \begin_layout Itemize
18782
18783 \noun on
18784 Jos\i \'{e}
18785  Ab\i \'{\i}
18786 lio Oliveira Matos
18787 \end_layout
18788
18789 \begin_layout Itemize
18790
18791 \noun on
18792 David Suarez de Lis
18793 \end_layout
18794
18795 \begin_layout Standard
18796 Other contributors:
18797 \end_layout
18798
18799 \begin_layout Itemize
18800
18801 \noun on
18802 Jean-Marc Lasgouttes
18803 \noun default
18804  worked on the wrapper script and offered lots of bug reports, advice, and
18805  feature suggestions.
18806 \end_layout
18807
18808 \begin_layout Itemize
18809
18810 \noun on
18811 Asger K.
18812  Alstrup Nielsen
18813 \noun default
18814  and 
18815 \noun on
18816 Marc Pavese
18817 \noun default
18818  provided advice.
18819 \end_layout
18820
18821 \begin_layout Itemize
18822 Various members of the LyX developers' and users' lists provided bug reports
18823  and feature suggestions.
18824 \end_layout
18825
18826 \begin_layout Standard
18827 reLyX uses a modified version the Perl TeX parser 
18828 \family typewriter
18829 Text::TeX
18830 \family default
18831  package written by 
18832 \noun on
18833 Ilya Zakharevich
18834 \noun default
18835  (
18836 \family typewriter
18837 ilya@math.ohio-state.edu
18838 \family default
18839 ), available on CPAN.
18840 \end_layout
18841
18842 \begin_layout Chapter
18843 LyX Features needing Extra Software
18844 \end_layout
18845
18846 \begin_layout Section
18847 Using LyX with SGML-Tools (aka LinuxDoc)
18848 \end_layout
18849
18850 \begin_layout Standard
18851 by 
18852 \noun on
18853 Paul Evans
18854 \end_layout
18855
18856 \begin_layout Subsection
18857 Overview
18858 \end_layout
18859
18860 \begin_layout Standard
18861 LinuxDoc is a document class available in LyX if you have the 
18862 \family typewriter
18863 sgml-tools
18864 \family default
18865  package installed.
18866  You can use it to produce documents in the so-called Standardized General
18867  Mark-up Language (SGML) in the particular format used by the Linux Documentatio
18868 n Project.
18869  That is obviously helpful if you are contributing to that project.
18870  You can use the SGML format with the 
18871 \family typewriter
18872 sgml-tools
18873 \family default
18874  package of scripts and programs (to produce other formats, including LaTeX,
18875  HTML, plain text, man pages and\SpecialChar \ldots{}
18876 ).
18877  You may therefore prefer to use this document class if you want to write
18878  something that can be easily translated into other formats.
18879 \end_layout
18880
18881 \begin_layout Standard
18882 You will find that LinuxDoc has fewer layout options than the other text
18883  classes in LyX.
18884  This is mainly so that the translations into other formats have a chance
18885  of making some sense.
18886  In this section we describe:
18887 \end_layout
18888
18889 \begin_layout Itemize
18890 how to setup and use a document in LinuxDoc
18891 \end_layout
18892
18893 \begin_layout Itemize
18894 how to use the tags in LinuxDoc to layout your document
18895 \end_layout
18896
18897 \begin_layout Itemize
18898 how to use the SGML packages to produce the various formats
18899 \end_layout
18900
18901 \begin_layout Itemize
18902 how to sort out some problems.
18903 \end_layout
18904
18905 \begin_layout Subsection
18906 Preparing and using a LinuxDoc document
18907 \end_layout
18908
18909 \begin_layout Subsubsection
18910 Getting started
18911 \end_layout
18912
18913 \begin_layout Standard
18914 You start by selecting the LinuxDoc class using the 
18915 \family sans
18916 \bar under
18917 D
18918 \bar default
18919 ocument\SpecialChar \menuseparator
18920
18921 \bar under
18922 S
18923 \bar default
18924 ettings
18925 \family default
18926  dialog.
18927
18928 \family sans
18929  
18930 \family default
18931 Then you will find that there are fewer paragraph environments than for
18932  most other classes.
18933  You can see them on the pull down box on the left of the tool bar.
18934  How to use them is described in section\InsetSpace ~
18935
18936 \begin_inset LatexCommand \ref{sec:sgmlparas}
18937
18938 \end_inset
18939
18940 .
18941 \end_layout
18942
18943 \begin_layout Standard
18944 You 
18945 \emph on
18946 must
18947 \emph default
18948  enter a title for the document, followed by an author, marking each with
18949  the appropriate paragraph environment.
18950  If you don't do this, you will get errors when you try to print the file.
18951  You can then enter the date and an abstract.
18952  The document proper must start with a Section paragraph environment rather
18953  than any standard layout.
18954 \end_layout
18955
18956 \begin_layout Standard
18957 After that you can prepare a document as usual using the available range
18958  of paragraph environments.
18959  See section\InsetSpace ~
18960
18961 \begin_inset LatexCommand \ref{sec:sgmlparas}
18962
18963 \end_inset
18964
18965  for the full list and their uses.
18966 \end_layout
18967
18968 \begin_layout Subsubsection
18969 Output from LinuxDoc
18970 \end_layout
18971
18972 \begin_layout Standard
18973 You can print and save these documents in the normal way.
18974  To use the other features of the SGML package you need to save your document
18975  as LinuxDoc; this is a version in which the document is translated into
18976  the basic sgml tags.
18977  Use
18978 \family sans
18979  
18980 \bar under
18981 F
18982 \bar default
18983 ile\SpecialChar \menuseparator
18984
18985 \bar under
18986 E
18987 \bar default
18988 xport\SpecialChar \menuseparator
18989 Linu
18990 \bar under
18991 x
18992 \bar default
18993 Doc.
18994
18995 \family default
18996  You will get a file with the same name and a 
18997 \family typewriter
18998 .sgml
18999 \family default
19000  extension rather than a 
19001 \family typewriter
19002 .lyx
19003 \family default
19004  extension.
19005  See\InsetSpace ~
19006
19007 \begin_inset LatexCommand \ref{sec:sgmloperate}
19008
19009 \end_inset
19010
19011  on how you than make use of this file.
19012 \end_layout
19013
19014 \begin_layout Subsection
19015 Using the paragraph environments in LinuxDoc
19016 \end_layout
19017
19018 \begin_layout Subsubsection
19019 The Structure of a LinuxDoc Document
19020 \end_layout
19021
19022 \begin_layout Standard
19023 There is a formal structure for LinuxDoc which limits how you can place
19024  tags.
19025  There are two parts to all documents: 
19026 \end_layout
19027
19028 \begin_layout Description
19029 Header: this is everything up to the first time you insert a Section layout
19030  marker.
19031  It can include title, author, date, abstract and ToC.
19032  You must include the first two.
19033 \end_layout
19034
19035 \begin_layout Description
19036 Body: from the beginning of the first section onwards.
19037  All other tags are allowed.
19038  
19039 \end_layout
19040
19041 \begin_layout Subsubsection
19042 The LinuxDoc Paragraph Environments
19043 \end_layout
19044
19045 \begin_layout Standard
19046 \begin_inset LatexCommand \label{sec:sgmlparas}
19047
19048 \end_inset
19049
19050 Here is a list of all the tags you will find listed on the layout bar in
19051  the order they come there, with some comments where the purpose or use
19052  is not obvious:
19053 \end_layout
19054
19055 \begin_layout Itemize
19056
19057 \family sans
19058 Standard:
19059 \family roman
19060  works as described in [cross reference]
19061 \end_layout
19062
19063 \begin_layout Itemize
19064
19065 \family sans
19066 Title
19067 \family default
19068 : This will appear at the top left of the document when printed, above a
19069  heavy horizontal rule, although you will not see this on the LyX screen.
19070 \end_layout
19071
19072 \begin_layout Itemize
19073
19074 \family sans
19075 Section, Subsection, Subsubsection, Paragraph and Subparagraph:
19076 \family default
19077  all do what you would expect and in the usual order.
19078  Whether they are numbered or not is controlled by the 
19079 \family sans
19080 Section\InsetSpace ~
19081 number\InsetSpace ~
19082 depth
19083 \family default
19084  setting.
19085  You cannot get the equivalent number free versions in any other way; there
19086  is no 
19087 \family sans
19088 Section*
19089 \family default
19090  or similar
19091 \end_layout
19092
19093 \begin_layout Itemize
19094
19095 \family sans
19096 Enumerate:
19097 \family default
19098  As usual this produces a numbered and indented list as described in the
19099  
19100 \emph on
19101 User's Guide
19102 \emph default
19103 .
19104 \end_layout
19105
19106 \begin_layout Itemize
19107
19108 \family sans
19109 Itemize: 
19110 \family roman
19111 Again much the same as in the other classes: see the 
19112 \emph on
19113 User's Guide
19114 \emph default
19115 .
19116 \end_layout
19117
19118 \begin_layout Itemize
19119
19120 \family sans
19121 Description
19122 \family default
19123 : As explained in the 
19124 \emph on
19125 User's Guide
19126 \emph default
19127 .
19128  Remember that if you want the bold element at the start of a description
19129  to be more than one word then you need to put protected spaces between
19130  the words.
19131  
19132 \end_layout
19133
19134 \begin_layout Itemize
19135
19136 \family sans
19137 Verbatim: 
19138 \family default
19139 As usual.
19140 \end_layout
19141
19142 \begin_layout Itemize
19143
19144 \family sans
19145 Code: similar to the LyX-Code
19146 \family roman
19147  environment
19148 \end_layout
19149
19150 \begin_layout Itemize
19151
19152 \family sans
19153 Author
19154 \family default
19155 : Anything you mark with this will appear on the left of the heading of
19156  the document, under the heavy rule.
19157 \end_layout
19158
19159 \begin_layout Itemize
19160
19161 \family sans
19162 Date:
19163 \family default
19164  Anything you mark with this will appear on the right of the heading under
19165  the rule.
19166  You do not have to make this a date.
19167  Any text can be entered, e.\InsetSpace ~
19168 g.\InsetSpace \space{}
19169 a version number.
19170 \end_layout
19171
19172 \begin_layout Itemize
19173
19174 \family sans
19175 Abstract
19176 \family default
19177 : You can use this to produce a free standing paragraph after the author
19178  and date, and before the first section.
19179  You are only allowed one such paragraph.
19180 \begin_inset Foot
19181 status collapsed
19182
19183 \begin_layout Standard
19184
19185 \emph on
19186 Author's note.
19187  
19188 \emph default
19189 This needs checking ---
19190 \emph on
19191 pe.
19192 \end_layout
19193
19194 \end_inset
19195
19196
19197 \end_layout
19198
19199 \begin_layout Itemize
19200
19201 \family sans
19202 Displaymath
19203 \family default
19204 :
19205 \begin_inset Foot
19206 status collapsed
19207
19208 \begin_layout Standard
19209
19210 \emph on
19211 Author's note: 
19212 \emph default
19213 I have not yet checked this ---
19214 \emph on
19215 pe.
19216 \end_layout
19217
19218 \end_inset
19219
19220
19221 \end_layout
19222
19223 \begin_layout Subsubsection
19224 Other document features
19225 \end_layout
19226
19227 \begin_layout Standard
19228 You can also use the 
19229 \family sans
19230 Layout 
19231 \family default
19232 menu to set fonts or to emphasis words.
19233  You can also use the table of contents as usual; see the corresponding
19234  section of the 
19235 \emph on
19236 User's Guide
19237 \emph default
19238 .
19239  Although you will find some other features on the menus e.\InsetSpace ~
19240 g.\InsetSpace \space{}
19241 inserting footnotes.
19242  There is some doubt about whether these will work correctly.
19243 \begin_inset Foot
19244 status collapsed
19245
19246 \begin_layout Standard
19247
19248 \emph on
19249 Author's note: 
19250 \emph default
19251 Again still checking to see whether this is my system
19252 \emph on
19253  ---pe.
19254 \end_layout
19255
19256 \end_inset
19257
19258
19259 \end_layout
19260
19261 \begin_layout Subsubsection
19262 Cross references and HTML 
19263 \end_layout
19264
19265 \begin_layout Standard
19266 On the
19267 \family sans
19268  Insert
19269 \family default
19270  menu you will find two new options relating to the inclusion of URL addresses.
19271  If you use either option you will find some highlighted TeX code inserted
19272  into your document in three separate blocks with spaces available between.
19273  The blocks will be:
19274 \end_layout
19275
19276 \begin_layout Quote
19277
19278 \family typewriter
19279
19280 \backslash
19281 htmlurl{
19282 \family default
19283  or 
19284 \family typewriter
19285
19286 \backslash
19287 url{
19288 \family roman
19289
19290 \hfill
19291 space
19292 \family default
19293  
19294 \family typewriter
19295
19296 \hfill
19297 }{
19298 \family roman
19299
19300 \hfill
19301 space
19302 \hfill
19303
19304 \family typewriter
19305 }
19306 \end_layout
19307
19308 \begin_layout Standard
19309 You insert a full HTML tag between the first and second blocks.
19310  This can be 
19311 \begin_inset LatexCommand \url{http://any.address}
19312
19313 \end_inset
19314
19315  or other valid tags such as 
19316 \begin_inset LatexCommand \url{mailto:me@my.address}
19317
19318 \end_inset
19319
19320
19321 \family typewriter
19322 .
19323 \family default
19324 Then y
19325 \family roman
19326 ou 
19327 \family default
19328 insert some description between the second and third blocks.
19329  The differences are:
19330 \end_layout
19331
19332 \begin_layout Itemize
19333
19334 \family sans
19335 URL:
19336 \family roman
19337  both the HTML tag and the description will appear in the document
19338 \end_layout
19339
19340 \begin_layout Itemize
19341
19342 \family sans
19343 HTML\InsetSpace ~
19344 URL: 
19345 \family roman
19346 only the description appears in the printed version
19347 \end_layout
19348
19349 \begin_layout Subsection
19350 Using the LinuxDoc Sgml scripts
19351 \begin_inset Note Note
19352 status collapsed
19353
19354 \begin_layout Standard
19355 This section is completely outdated.
19356 \end_layout
19357
19358 \end_inset
19359
19360
19361 \end_layout
19362
19363 \begin_layout Standard
19364 \begin_inset LatexCommand \label{sec:sgmloperate}
19365
19366 \end_inset
19367
19368 You can use LinuxDoc as a text class without any additional scripts or programs,
19369  but there is not much point in doing this.
19370  All you will get is a document that looks like a 
19371 \emph on
19372 Linux Documentation Project Howto
19373 \family sans
19374 \emph default
19375 .
19376  
19377 \family default
19378 To do the document translation you need to get and install the 
19379 \family typewriter
19380 sgml-tools-1.0.x.tar.gz 
19381 \family default
19382 (with 
19383 \begin_inset Formula $x\geq3$
19384 \end_inset
19385
19386 ) package from 
19387 \family roman
19388 the SGML-Tools WWW Page
19389 \family default
19390  at
19391 \end_layout
19392
19393 \begin_layout LyX-Code
19394
19395 \family roman
19396 \begin_inset LatexCommand \url{http://pobox.com/~cg/sgmltools}
19397
19398 \end_inset
19399
19400
19401 \family default
19402  
19403 \end_layout
19404
19405 \begin_layout Standard
19406 Alternatively, you can go to the 
19407 \family typewriter
19408 sunsite
19409 \family default
19410  archive at
19411 \begin_inset Foot
19412 status collapsed
19413
19414 \begin_layout Standard
19415 Note that, at the time of this writing (01/1998), version 1.0.3 of sgml-tools
19416  has not yet been made available at 
19417 \family typewriter
19418 sunsite
19419 \family default
19420 .
19421 \end_layout
19422
19423 \end_inset
19424
19425
19426 \end_layout
19427
19428 \begin_layout LyX-Code
19429
19430 \family roman
19431 \begin_inset LatexCommand \url{ftp://sunsite.unc.edu/pub/Linux/utils/text/sgml-tools-1.0.x.tar.gz}
19432
19433 \end_inset
19434
19435
19436 \end_layout
19437
19438 \begin_layout Standard
19439
19440 \family roman
19441 The
19442 \family default
19443  file 
19444 \family typewriter
19445 sgml-tools-1.0.x.tar.gz
19446 \family default
19447  contains everything that you need to write SGML documents and convert them
19448  to groff, LaTeX, HTML, GNU info, LyX, and RTF\SpecialChar \@.
19449
19450 \end_layout
19451
19452 \begin_layout Standard
19453 This package was renamed from 
19454 \family typewriter
19455 linuxdoc-sgml-1.5.tar.gz
19456 \family default
19457  in January 1997.
19458 \end_layout
19459
19460 \begin_layout Standard
19461 Follow the instructions in that package on how to install it and how to
19462  use it.
19463  All this has to be done outside of LyX, before you can use the 
19464 \family sans
19465 \bar under
19466 F
19467 \bar default
19468 ile\SpecialChar \menuseparator
19469
19470 \bar under
19471 E
19472 \bar default
19473 xport\SpecialChar \menuseparator
19474 as\InsetSpace ~
19475 LinuxDoc 
19476 \family roman
19477 option.
19478 \end_layout
19479
19480 \begin_layout Subsection
19481 Troubleshooting LinuxDoc
19482 \end_layout
19483
19484 \begin_layout Standard
19485 When you print or preview a LinuxDoc document some checking is done of the
19486  tags before LaTeX is run.
19487  Some errors are trapped here, especially those concerning the structure
19488  of the document.
19489  LyX may produce an error message, but not leave an error box in the document
19490  for you to open.
19491  You may have to look at the files directly to discover what is wrong.
19492  Most problems seem to come from the use of options that are not fully available
19493  in the text class.
19494 \end_layout
19495
19496 \begin_layout Section
19497 Checking TeX
19498 \end_layout
19499
19500 \begin_layout Standard
19501 by 
19502 \noun on
19503 Asger Alstrup
19504 \end_layout
19505
19506 \begin_layout Subsection
19507 Introduction
19508 \end_layout
19509
19510 \begin_layout Standard
19511 Under the 
19512 \family sans
19513 \bar under
19514 T
19515 \bar default
19516 ools
19517 \family default
19518  menu, you'll find a 
19519 \family sans
19520 \bar under
19521 C
19522 \bar default
19523 heck\InsetSpace ~
19524 TeX
19525 \family default
19526  command.
19527  This feature requires you to have the 
19528 \family typewriter
19529 chktex
19530 \family default
19531  program installed, and is grayed out if you don't have it.
19532  You can get it from your nearest CTAN mirror, or over the Web from 
19533 \begin_inset LatexCommand \url{http://www.ifi.uio.no/~jensthi/chktex/}
19534
19535 \end_inset
19536
19537 .
19538 \end_layout
19539
19540 \begin_layout Standard
19541 The 
19542 \family sans
19543 ChkTeX
19544 \family default
19545  package is a program that was written by 
19546 \noun on
19547 Jens T.
19548  Berger Thielemann
19549 \noun default
19550  in frustration because some constructs in LaTeX are sometimes non-intuitive,
19551  and easy to forget.
19552  The program runs over your LaTeX file and checks the integrity of the file,
19553  and flags some common errors.
19554  In other technical words, it is 
19555 \family typewriter
19556 Lint
19557 \family default
19558  for LaTeX.
19559 \end_layout
19560
19561 \begin_layout Standard
19562 Well, what is a syntax checker doing in LyX which is supposed to produce
19563  correct LaTeX anyways? The answer is simple: Just as 
19564 \family typewriter
19565 Lint
19566 \family default
19567  not only checks the 
19568 \emph on
19569 syntax
19570 \emph default
19571  of C programs, but also does 
19572 \emph on
19573 semantic
19574 \emph default
19575  checks for type-errors, 
19576 \family sans
19577 ChkTeX
19578 \family default
19579  catches some common 
19580 \emph on
19581 typographic
19582 \emph default
19583  errors, in addition to the syntactical ones.
19584  Specifically, 
19585 \family sans
19586 ChkTeX
19587 \family default
19588  is capable of detecting several common errors, such as
19589 \end_layout
19590
19591 \begin_layout Itemize
19592 Ellipsis detection:
19593 \newline
19594 Use \SpecialChar \ldots{}
19595  instead of ...
19596 \end_layout
19597
19598 \begin_layout Itemize
19599 No space in front of/after parenthesis:
19600 \newline
19601 ( wrong spacing )
19602 \end_layout
19603
19604 \begin_layout Itemize
19605 Enforcement of normal space after common abbreviations:
19606 \newline
19607 e.
19608  g.\InsetSpace \space{}
19609 is too wide spacing.
19610 \end_layout
19611
19612 \begin_layout Itemize
19613 Enforcement of end-of-sentence space when the last sentence ends with a
19614  capital letter:
19615 \newline
19616 This is a TEST.
19617  And this is wrong spacing.
19618 \end_layout
19619
19620 \begin_layout Itemize
19621 Space in front of labels and similar commands:
19622 \newline
19623 The label should stick right
19624  up to the text to avoid falling to a wrong page.
19625  
19626 \begin_inset LatexCommand \label{sec:chktex}
19627
19628 \end_inset
19629
19630  
19631 \begin_inset Foot
19632 status collapsed
19633
19634 \begin_layout Standard
19635 This footnote is in danger of falling off to a wrong page
19636 \end_layout
19637
19638 \end_inset
19639
19640  The label is separated too much.
19641 \end_layout
19642
19643 \begin_layout Itemize
19644 Space in front of references, instead of hard spaces:
19645 \newline
19646 In you are in bad luck,
19647  the text will break right between the referenced text and reference number,
19648  and that's a pity.
19649  See section 
19650 \begin_inset LatexCommand \ref{sec:chktex}
19651
19652 \end_inset
19653
19654 .
19655 \end_layout
19656
19657 \begin_layout Itemize
19658 Use of 
19659 \begin_inset Quotes eld
19660 \end_inset
19661
19662 x
19663 \begin_inset Quotes erd
19664 \end_inset
19665
19666  instead of 
19667 \begin_inset Formula $\times$
19668 \end_inset
19669
19670  between numbers:
19671 \newline
19672 2x2 looks cheap compared to 
19673 \begin_inset Formula $2\times2$
19674 \end_inset
19675
19676 .
19677 \end_layout
19678
19679 \begin_layout Standard
19680 and more \SpecialChar \ldots{}
19681  It is an invaluable tool when you are 
19682 \begin_inset Quotes eld
19683 \end_inset
19684
19685 finishing up
19686 \begin_inset Quotes erd
19687 \end_inset
19688
19689  your document before printing, and you should run it right after the obligatory
19690  spelling check, and before you go fine tuning the typesetting.
19691 \end_layout
19692
19693 \begin_layout Subsection
19694 How to use it
19695 \end_layout
19696
19697 \begin_layout Standard
19698 If you have the program installed, usage is as simple as choosing 
19699 \family sans
19700 \bar under
19701 T
19702 \bar default
19703 ools\SpecialChar \menuseparator
19704
19705 \bar under
19706 C
19707 \bar default
19708 heck\InsetSpace ~
19709 TeX
19710 \family default
19711 .
19712  This will make LyX generate a LaTeX file of your document, start 
19713 \family sans
19714 ChkTeX
19715 \family default
19716  to check it, and then make LyX insert 
19717 \begin_inset Quotes eld
19718 \end_inset
19719
19720 error boxes
19721 \begin_inset Quotes erd
19722 \end_inset
19723
19724  with the warnings from 
19725 \family sans
19726 ChkTeX
19727 \family default
19728 , if there were any.
19729  The warnings will be placed close to the point of the mistake, and you
19730  can quickly find them by using the 
19731 \family sans
19732 \bar under
19733 N
19734 \bar default
19735 avigate\SpecialChar \menuseparator
19736
19737 \bar under
19738 E
19739 \bar default
19740 rror
19741 \family default
19742  menu item, or the shortcut key 
19743 \family sans
19744 C-g
19745 \family default
19746  from the default 
19747 \family typewriter
19748 cua
19749 \family default
19750  bind file.
19751  Open the error boxes by clicking on them with the mouse, or use the shortcut
19752  key 
19753 \family sans
19754 C-i
19755 \family default
19756  from 
19757 \family typewriter
19758 cua
19759 \family default
19760  bindings, or the corresponding 
19761 \family sans
19762 C-o
19763 \family default
19764  for the alternate 
19765 \family typewriter
19766 emacs
19767 \family default
19768  bind file.
19769  Read the warning and correct the mistake, if it is a mistake.
19770  If you have trouble understanding what the warning is about, you can safely
19771  ignore it.
19772  Remember that there is a hidden layer between the document on screen and
19773  the technical details in invoking 
19774 \family sans
19775 ChkTeX
19776 \family default
19777 , and this gap can make some warnings seem arcane or just right down plain
19778  silly.
19779 \end_layout
19780
19781 \begin_layout Standard
19782 This document is an excellent testing bed for the feature, and it should
19783  provide quite a few warnings for you to fiddle with.
19784  Since computers are only so smart, expect most of the warnings to be false
19785  alarms, though.
19786 \end_layout
19787
19788 \begin_layout Subsection
19789 How to fine tune it
19790 \end_layout
19791
19792 \begin_layout Standard
19793 Sometimes, you'll find that 
19794 \family sans
19795 ChkTeX
19796 \family default
19797  makes more noise than suits your mood.
19798  Then you can choose not to use it, wait until your mood changes, or try
19799  to customize 
19800 \family sans
19801 ChkTeX
19802 \family default
19803  to get better along with you.
19804  Another choice in the most desperate situations is to use 
19805 \family sans
19806 \bar under
19807 V
19808 \bar default
19809 iew\SpecialChar \menuseparator
19810
19811 \bar under
19812 R
19813 \bar default
19814 emove\InsetSpace ~
19815 All\InsetSpace ~
19816 Error\InsetSpace ~
19817 Boxes
19818 \family default
19819 , which will get rid of all warnings instantly.
19820 \end_layout
19821
19822 \begin_layout Standard
19823 Although 
19824 \family sans
19825 ChkTeX
19826 \family default
19827  
19828 \emph on
19829 is
19830 \emph default
19831  very configurable and extensible, you shouldn't expect to solve all problems
19832  with 
19833 \family sans
19834 ChkTeX
19835 \family default
19836  in LyX this way.
19837  Since LyX has to generate a somewhat special LaTeX file to be able to match
19838  the line numbers from the 
19839 \family sans
19840 ChkTeX
19841 \family default
19842  output
19843 \begin_inset Foot
19844 status collapsed
19845
19846 \begin_layout Standard
19847 You can inspect the specific output from 
19848 \family sans
19849 chktex
19850 \family default
19851  by using 
19852 \family sans
19853 Edit\SpecialChar \menuseparator
19854 View\InsetSpace ~
19855 LaTeX\InsetSpace ~
19856 Log
19857 \family default
19858  right after a 
19859 \family sans
19860 chktex
19861 \family default
19862  run.
19863 \end_layout
19864
19865 \end_inset
19866
19867  to the internal document structure, some of the warnings will not seen
19868  to appear correctly.
19869  There are two things you can do about this:
19870 \end_layout
19871
19872 \begin_layout Itemize
19873 Fine tune the 
19874 \family sans
19875 ChkTeX
19876 \family default
19877  invocation command line in 
19878 \family sans
19879 Preferences
19880 \family default
19881  (tabs 
19882 \family sans
19883 Outputs
19884 \family default
19885
19886 \family sans
19887 Misc
19888 \family default
19889 ), or the global 
19890 \family sans
19891 ChkTeX
19892 \family default
19893  installation configuration file (usually with the file 
19894 \family typewriter
19895 /usr/local/share/chktexrc
19896 \family default
19897 ).
19898  See below to learn what warnings can be enabled and disabled on the command
19899  line.
19900  
19901 \end_layout
19902
19903 \begin_layout Itemize
19904 Export your document as a raw LaTeX file using 
19905 \family sans
19906 \bar under
19907 F
19908 \bar default
19909 ile\SpecialChar \menuseparator
19910
19911 \bar under
19912 E
19913 \bar default
19914 xport\SpecialChar \menuseparator
19915
19916 \bar under
19917 L
19918 \bar default
19919 aTeX
19920 \family default
19921  and run 
19922 \family typewriter
19923 chktex
19924 \family default
19925  manually on that.
19926  Invoked in this way, it can be a hassle to find the corresponding place
19927  in the document inside LyX, but with a little patience, you should be able
19928  to do it.
19929 \end_layout
19930
19931 \begin_layout Standard
19932 Here follows the warning messages that can be enabled and disabled in 
19933 \family sans
19934 Preferences
19935 \family default
19936 .
19937  Use 
19938 \family typewriter
19939 -n#
19940 \family default
19941  to disable a warning, and 
19942 \family typewriter
19943 -w#
19944 \family default
19945  to enable a warning.
19946  The emphasized entries are disabled by default, because the default is
19947  "
19948 \family typewriter
19949 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19950 \family default
19951 ".
19952 \end_layout
19953
19954 \begin_layout Standard
19955 Notice that you should only use the options that enable and disable warnings,
19956  because LyX relies on some of the other command line parameters to be set
19957  in a specific way to have a chance to communicate with 
19958 \family typewriter
19959 chktex
19960 \family default
19961 .
19962 \end_layout
19963
19964 \begin_layout Enumerate
19965
19966 \size small
19967 \emph on
19968 Command terminated with space.
19969 \end_layout
19970
19971 \begin_layout Enumerate
19972
19973 \size small
19974 Non-breaking space (
19975 \begin_inset Quotes eld
19976 \end_inset
19977
19978
19979 \family typewriter
19980 ~
19981 \family default
19982
19983 \begin_inset Quotes erd
19984 \end_inset
19985
19986 ) should have been used.
19987 \end_layout
19988
19989 \begin_layout Enumerate
19990
19991 \size small
19992 \emph on
19993 You should enclose the previous parenthesis with 
19994 \begin_inset Quotes eld
19995 \end_inset
19996
19997
19998 \family typewriter
19999 {}
20000 \family default
20001
20002 \begin_inset Quotes erd
20003 \end_inset
20004
20005 .
20006 \end_layout
20007
20008 \begin_layout Enumerate
20009
20010 \size small
20011 Italic correction (
20012 \begin_inset Quotes eld
20013 \end_inset
20014
20015
20016 \family typewriter
20017
20018 \backslash
20019 /
20020 \family default
20021
20022 \begin_inset Quotes erd
20023 \end_inset
20024
20025 ) found in non-italic buffer.
20026 \end_layout
20027
20028 \begin_layout Enumerate
20029
20030 \size small
20031 Italic correction (
20032 \begin_inset Quotes eld
20033 \end_inset
20034
20035
20036 \family typewriter
20037
20038 \backslash
20039 /
20040 \family default
20041
20042 \begin_inset Quotes erd
20043 \end_inset
20044
20045 ) found more than once.
20046 \end_layout
20047
20048 \begin_layout Enumerate
20049
20050 \size small
20051 \emph on
20052 No italic correction (
20053 \begin_inset Quotes eld
20054 \end_inset
20055
20056
20057 \family typewriter
20058
20059 \backslash
20060 /
20061 \family default
20062
20063 \begin_inset Quotes erd
20064 \end_inset
20065
20066 ) found.
20067 \end_layout
20068
20069 \begin_layout Enumerate
20070
20071 \size small
20072 Accent command 
20073 \begin_inset Quotes eld
20074 \end_inset
20075
20076
20077 \family typewriter
20078 cmd
20079 \family default
20080
20081 \begin_inset Quotes erd
20082 \end_inset
20083
20084  needs use of 
20085 \begin_inset Quotes eld
20086 \end_inset
20087
20088
20089 \family typewriter
20090 cmd
20091 \family default
20092
20093 \begin_inset Quotes erd
20094 \end_inset
20095
20096 .
20097 \end_layout
20098
20099 \begin_layout Enumerate
20100
20101 \size small
20102 Wrong length of dash may have been used.
20103 \end_layout
20104
20105 \begin_layout Enumerate
20106
20107 \size small
20108 \emph on
20109 \begin_inset Quotes eld
20110 \end_inset
20111
20112
20113 \family typewriter
20114 %s
20115 \family default
20116
20117 \begin_inset Quotes erd
20118 \end_inset
20119
20120  expected, found 
20121 \begin_inset Quotes eld
20122 \end_inset
20123
20124
20125 \family typewriter
20126 %s
20127 \family default
20128
20129 \begin_inset Quotes erd
20130 \end_inset
20131
20132 .
20133 \end_layout
20134
20135 \begin_layout Enumerate
20136
20137 \size small
20138 Solo 
20139 \begin_inset Quotes eld
20140 \end_inset
20141
20142
20143 \family typewriter
20144 %s
20145 \family default
20146
20147 \begin_inset Quotes erd
20148 \end_inset
20149
20150  found.
20151 \end_layout
20152
20153 \begin_layout Enumerate
20154
20155 \size small
20156 You should use 
20157 \begin_inset Quotes eld
20158 \end_inset
20159
20160
20161 \family typewriter
20162 %s
20163 \family default
20164
20165 \begin_inset Quotes erd
20166 \end_inset
20167
20168  to achieve an ellipsis.
20169 \end_layout
20170
20171 \begin_layout Enumerate
20172
20173 \size small
20174 Inter-word spacing (
20175 \begin_inset Quotes eld
20176 \end_inset
20177
20178
20179 \family typewriter
20180
20181 \backslash
20182  
20183 \family default
20184
20185 \begin_inset Quotes eld
20186 \end_inset
20187
20188 ) should perhaps be used.
20189 \end_layout
20190
20191 \begin_layout Enumerate
20192
20193 \size small
20194 Inter-sentence spacing (
20195 \begin_inset Quotes eld
20196 \end_inset
20197
20198
20199 \family typewriter
20200
20201 \backslash
20202 @
20203 \family default
20204
20205 \begin_inset Quotes erd
20206 \end_inset
20207
20208 ) should perhaps be used.
20209 \end_layout
20210
20211 \begin_layout Enumerate
20212
20213 \size small
20214 Could not find argument for command.
20215 \end_layout
20216
20217 \begin_layout Enumerate
20218
20219 \size small
20220 No match found for 
20221 \begin_inset Quotes eld
20222 \end_inset
20223
20224
20225 \family typewriter
20226 %s
20227 \family default
20228
20229 \begin_inset Quotes erd
20230 \end_inset
20231
20232 .
20233 \end_layout
20234
20235 \begin_layout Enumerate
20236
20237 \size small
20238 Math mode still on at end of LaTeX file.
20239 \end_layout
20240
20241 \begin_layout Enumerate
20242
20243 \size small
20244 Number of 
20245 \begin_inset Quotes eld
20246 \end_inset
20247
20248
20249 \family typewriter
20250 char
20251 \family default
20252
20253 \begin_inset Quotes erd
20254 \end_inset
20255
20256  doesn't match the number of 
20257 \begin_inset Quotes eld
20258 \end_inset
20259
20260
20261 \family typewriter
20262 char
20263 \family default
20264
20265 \begin_inset Quotes erd
20266 \end_inset
20267
20268 .
20269 \end_layout
20270
20271 \begin_layout Enumerate
20272
20273 \size small
20274 You should use either 
20275 \family typewriter
20276
20277 \begin_inset Quotes eld
20278 \end_inset
20279
20280
20281 \family default
20282  or 
20283 \family typewriter
20284
20285 \begin_inset Quotes erd
20286 \end_inset
20287
20288
20289 \family default
20290  as an alternative to 
20291 \begin_inset Quotes eld
20292 \end_inset
20293
20294
20295 \family typewriter
20296 "
20297 \family default
20298
20299 \begin_inset Quotes erd
20300 \end_inset
20301
20302 .
20303 \end_layout
20304
20305 \begin_layout Enumerate
20306
20307 \size small
20308 You should use "
20309 \family typewriter
20310 '
20311 \family default
20312 " (ASCII 39) instead of "
20313 \family typewriter
20314 ´
20315 \family default
20316 " (ASCII 180).
20317 \end_layout
20318
20319 \begin_layout Enumerate
20320
20321 \size small
20322 User-specified pattern found.
20323 \end_layout
20324
20325 \begin_layout Enumerate
20326
20327 \size small
20328 This command might not be intended.
20329 \end_layout
20330
20331 \begin_layout Enumerate
20332
20333 \size small
20334 \emph on
20335 Comment displayed.
20336 \end_layout
20337
20338 \begin_layout Enumerate
20339
20340 \size small
20341 Either 
20342 \family typewriter
20343 ''
20344 \backslash
20345 ,'
20346 \family default
20347  or 
20348 \family typewriter
20349 '
20350 \backslash
20351 ,''
20352 \family default
20353  will look better.
20354 \end_layout
20355
20356 \begin_layout Enumerate
20357
20358 \size small
20359 Delete this space to maintain correct page references.
20360 \end_layout
20361
20362 \begin_layout Enumerate
20363
20364 \size small
20365 \emph on
20366 You might wish to put this between a pair of 
20367 \begin_inset Quotes eld
20368 \end_inset
20369
20370
20371 \family typewriter
20372 {}
20373 \family default
20374
20375 \begin_inset Quotes erd
20376 \end_inset
20377
20378 .
20379 \end_layout
20380
20381 \begin_layout Enumerate
20382
20383 \size small
20384 You ought to remove spaces in front of punctuation.
20385 \end_layout
20386
20387 \begin_layout Enumerate
20388
20389 \size small
20390 Could not execute LaTeX command.
20391 \end_layout
20392
20393 \begin_layout Enumerate
20394
20395 \size small
20396 Don't use 
20397 \family typewriter
20398
20399 \backslash
20400 /
20401 \family default
20402  in front of small punctuation.
20403 \end_layout
20404
20405 \begin_layout Enumerate
20406
20407 \family typewriter
20408 \size small
20409 $
20410 \backslash
20411 times$
20412 \family default
20413  may look prettier here.
20414 \end_layout
20415
20416 \begin_layout Enumerate
20417
20418 \size small
20419 \emph on
20420 Multiple spaces detected in output.
20421 \end_layout
20422
20423 \begin_layout Enumerate
20424
20425 \size small
20426 This text may be ignored.
20427 \end_layout
20428
20429 \begin_layout Enumerate
20430
20431 \size small
20432 Use 
20433 \family typewriter
20434
20435 \begin_inset Quotes eld
20436 \end_inset
20437
20438
20439 \family default
20440  to begin quotation, not 
20441 \family typewriter
20442 '
20443 \family default
20444 .
20445 \end_layout
20446
20447 \begin_layout Enumerate
20448
20449 \size small
20450 Use 
20451 \family typewriter
20452 '
20453 \family default
20454  to end quotation, not 
20455 \family typewriter
20456
20457 \begin_inset Quotes eld
20458 \end_inset
20459
20460
20461 \family default
20462 .
20463 \end_layout
20464
20465 \begin_layout Enumerate
20466
20467 \size small
20468 Don't mix quotes.
20469 \end_layout
20470
20471 \begin_layout Enumerate
20472
20473 \size small
20474 You should perhaps use 
20475 \begin_inset Quotes eld
20476 \end_inset
20477
20478
20479 \family typewriter
20480 cmd
20481 \family default
20482
20483 \begin_inset Quotes erd
20484 \end_inset
20485
20486  instead.
20487 \end_layout
20488
20489 \begin_layout Enumerate
20490
20491 \size small
20492 You should put a space in front of/after parenthesis.
20493 \end_layout
20494
20495 \begin_layout Enumerate
20496
20497 \size small
20498 You should avoid spaces in front of/after parenthesis.
20499 \end_layout
20500
20501 \begin_layout Enumerate
20502
20503 \size small
20504 \emph on
20505 You should not use punctuation in front of/after quotes.
20506 \end_layout
20507
20508 \begin_layout Enumerate
20509
20510 \size small
20511 Double space found.
20512 \end_layout
20513
20514 \begin_layout Enumerate
20515
20516 \size small
20517 You should put punctuation outside inner/inside display math mode.
20518 \end_layout
20519
20520 \begin_layout Enumerate
20521
20522 \size small
20523 You ought to not use primitive TeX in LaTeX code.
20524 \end_layout
20525
20526 \begin_layout Enumerate
20527
20528 \size small
20529 You should remove spaces in front of 
20530 \begin_inset Quotes eld
20531 \end_inset
20532
20533
20534 \family typewriter
20535 %s
20536 \family default
20537
20538 \begin_inset Quotes erd
20539 \end_inset
20540
20541
20542 \end_layout
20543
20544 \begin_layout Enumerate
20545
20546 \size small
20547 \begin_inset Quotes eld
20548 \end_inset
20549
20550
20551 \family typewriter
20552 %s
20553 \family default
20554
20555 \begin_inset Quotes erd
20556 \end_inset
20557
20558  is normally not followed by 
20559 \begin_inset Quotes eld
20560 \end_inset
20561
20562
20563 \family typewriter
20564 %c
20565 \family default
20566
20567 \begin_inset Quotes erd
20568 \end_inset
20569
20570 .
20571 \end_layout
20572
20573 \begin_layout Standard
20574 In later versions of LyX, we hope to provide a more complete interface to
20575  this tool (and it's smaller cousin 
20576 \family typewriter
20577 lacheck
20578 \family default
20579 ) to exploit the full power of it.
20580  But it's not exactly useless as it is now: go try it on one of your existing
20581  documents of a certain length and be surprised.
20582 \end_layout
20583
20584 \begin_layout Section
20585 Version Control in LyX
20586 \end_layout
20587
20588 \begin_layout Standard
20589 by
20590 \noun on
20591  Lars Gullik Bjønnes
20592 \end_layout
20593
20594 \begin_layout Subsection
20595 Introduction
20596 \end_layout
20597
20598 \begin_layout Standard
20599 A friend of mine wanted to try LyX for a group project.
20600  When he didn't find support for version control or file locking, he dropped
20601  it.
20602  This angered me a bit, so I thought that I should at least make support
20603  for RCS (with the possibility of CVS and/or SCCS as a future improvement.)
20604  This has now been done.
20605  LyX now supports some of the most basic RCS commands.
20606  If you need to something a bit more sophisticated you will have to do that
20607  manually in an xterm.
20608 \end_layout
20609
20610 \begin_layout Standard
20611 Before you begin to use the version control features in LyX, you should
20612  read 
20613 \begin_inset Quotes eld
20614 \end_inset
20615
20616 rcsintro
20617 \begin_inset Quotes erd
20618 \end_inset
20619
20620  (a man file, read it with 
20621 \family typewriter
20622 man rcsintro
20623 \family default
20624 ).
20625  This file describes all the basic features of RCS.
20626  You should especially notice the comment about a RCS directory, and the
20627  notion of a master RCS file (the file ending in 
20628 \family typewriter
20629 ,v
20630 \family default
20631 ).
20632 \end_layout
20633
20634 \begin_layout Standard
20635 The implementation in LyX assumes a recent version of the GNU RCS package---no
20636  guarantees are made for older versions.
20637 \end_layout
20638
20639 \begin_layout Subsection
20640 RCS commands in LyX
20641 \end_layout
20642
20643 \begin_layout Standard
20644 The following sections describe the RCS commands supported by LyX.
20645  You can find them in the 
20646 \family sans
20647 \bar under
20648 F
20649 \bar default
20650 ile\SpecialChar \menuseparator
20651
20652 \bar under
20653 V
20654 \bar default
20655 ersion\InsetSpace ~
20656 Control
20657 \family default
20658  submenu.
20659 \end_layout
20660
20661 \begin_layout Subsubsection
20662
20663 \family sans
20664 Register
20665 \end_layout
20666
20667 \begin_layout Standard
20668 If your document is not under revision control, this is the only item shown
20669  in the menu.
20670  And if it is under revision control, the 
20671 \family sans
20672 \bar under
20673 R
20674 \bar default
20675 egister
20676 \family default
20677  item is grayed out.
20678  
20679 \end_layout
20680
20681 \begin_layout Standard
20682 This command registers your document with RCS\SpecialChar \@.
20683  You are asked interactively
20684  to supply an initial description of the document.
20685  The document is now set in Read-Only mode and you have to 
20686 \family sans
20687 Check\InsetSpace ~
20688 Out\InsetSpace ~
20689 For\InsetSpace ~
20690 Edit
20691 \family default
20692 , before making any changes to it.
20693  A document under revision control has a 
20694 \begin_inset Quotes eld
20695 \end_inset
20696
20697 [RCS:<version> <locker>]
20698 \begin_inset Quotes erd
20699 \end_inset
20700
20701  item tagged to the filename in the minibuffer.
20702 \end_layout
20703
20704 \begin_layout Standard
20705 RCS command that is run: 
20706 \family typewriter
20707 ci -q -u -i -t-"<initial description>" <file-name>
20708 \end_layout
20709
20710 \begin_layout Standard
20711 Read 
20712 \family typewriter
20713 man ci
20714 \family default
20715  to understand the switches.
20716  
20717 \end_layout
20718
20719 \begin_layout Subsubsection
20720
20721 \family sans
20722 Check In Changes
20723 \end_layout
20724
20725 \begin_layout Standard
20726 When you are finished editing a file, you check in your changes.
20727  When you do this, you are asked for a description of the changes.
20728  This is stored in the history log.
20729  The version number is bumped, your changes are applied to the master RCS
20730  file, the document is unlocked and set to Read-Only mode.
20731  
20732 \end_layout
20733
20734 \begin_layout Standard
20735 RCS command: 
20736 \family typewriter
20737 ci -q -u -m"<description>" <file-name>
20738 \end_layout
20739
20740 \begin_layout Subsubsection
20741
20742 \family sans
20743 Check Out For Edit
20744 \end_layout
20745
20746 \begin_layout Standard
20747 By doing this you lock the document so that only you can edit it.
20748  This will also make the document Read-Write only for you.
20749  You will usually continue editing for a while and when you are finished
20750  you check in your changes.
20751  The status line is changed to reflect that you have locked the file.
20752  
20753 \end_layout
20754
20755 \begin_layout Standard
20756 RCS command: 
20757 \family typewriter
20758 co -q -l <file-name>
20759 \end_layout
20760
20761 \begin_layout Subsubsection
20762
20763 \family sans
20764 Revert To Last Version
20765 \end_layout
20766
20767 \begin_layout Standard
20768 This will discard all changes made to the document since the last check
20769  in.
20770  You get a warning before changes are discarded.
20771 \end_layout
20772
20773 \begin_layout Standard
20774 RCS command: 
20775 \family typewriter
20776 co -f -u<version> <file-name>
20777 \end_layout
20778
20779 \begin_layout Subsubsection
20780
20781 \family sans
20782 Undo Last Checkin
20783 \end_layout
20784
20785 \begin_layout Standard
20786 This makes as if the last check in never happened.
20787  No changes are made to the document loaded into LyX, but the last version
20788  is removed from the master RCS file.
20789  
20790 \end_layout
20791
20792 \begin_layout Standard
20793 RCS command: 
20794 \family typewriter
20795 rcs -o<version> <file-name>
20796 \end_layout
20797
20798 \begin_layout Subsubsection
20799
20800 \family sans
20801 Show History
20802 \end_layout
20803
20804 \begin_layout Standard
20805 This show the complete history of the RCS document.
20806  The output of 
20807 \family typewriter
20808 rlog <file-name>
20809 \family default
20810  is shown in a browser.
20811  See 
20812 \family typewriter
20813 man rlog
20814 \family default
20815  for more info.
20816 \end_layout
20817
20818 \begin_layout Section
20819 Literate Programming
20820 \end_layout
20821
20822 \begin_layout Standard
20823 Updated by 
20824 \noun on
20825 Kayvan Sylvan 
20826 \noun default
20827 (kayvan@sylvan.com)
20828 \noun on
20829
20830 \noun default
20831 original documentation written by 
20832 \noun on
20833 Edmar Wienskoski Jr.
20834
20835 \noun default
20836  (edmar-w-jr@technologist.com)
20837 \end_layout
20838
20839 \begin_layout Subsection
20840 Introduction
20841 \end_layout
20842
20843 \begin_layout Standard
20844 The main purpose of this documentation is to show you how to use LyX for
20845  literate programming.
20846  Where it is assumed that you are familiar with this programming technique,
20847  and know what 
20848 \begin_inset Quotes eld
20849 \end_inset
20850
20851 tangling
20852 \begin_inset Quotes erd
20853 \end_inset
20854
20855  and 
20856 \begin_inset Quotes eld
20857 \end_inset
20858
20859 weaving
20860 \begin_inset Quotes erd
20861 \end_inset
20862
20863  means.
20864  If that is not the case, please follow the web links provided in the following
20865  sections.
20866  There is a lot of good documentation out there covering old development
20867  history to the latest tools tips.
20868 \end_layout
20869
20870 \begin_layout Standard
20871 It is also assumed that you are familiar with LyX itself to a point that
20872  you are comfortable changing your LyX preferences, and X resources file.
20873  If that is not the case please refer to other LyX documentation to cover
20874  your specific needs.
20875 \end_layout
20876
20877 \begin_layout Subsection
20878 Literate Programming
20879 \end_layout
20880
20881 \begin_layout Standard
20882 From the Literate Programming FAQ: 
20883 \end_layout
20884
20885 \begin_layout Quotation
20886 Literate programming is the combination of documentation and source together
20887  in a fashion suited for reading by human beings.
20888  In fact, literate programs should be enjoyable reading, even inviting!
20889  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
20890  and documentation in a single file.
20891  Literate programming tools then parse the file to produce either readable
20892  documentation or compilable source.
20893  The WEB style of literate programming was created by D.E.
20894  Knuth during the development of his TeX typesetting software.
20895  
20896 \end_layout
20897
20898 \begin_layout Standard
20899 Another excerpt says:
20900 \end_layout
20901
20902 \begin_layout Quotation
20903
20904 \emph on
20905 How is literate programming different from verbose commenting?
20906 \end_layout
20907
20908 \begin_layout Quotation
20909 There are three distinguishing characteristics.
20910  In order of importance, they are: 
20911 \end_layout
20912
20913 \begin_deeper
20914 \begin_layout Itemize
20915 flexible order of elaboration 
20916 \end_layout
20917
20918 \begin_layout Itemize
20919 automatic support for browsing 
20920 \end_layout
20921
20922 \begin_layout Itemize
20923 typeset documentation, especially diagrams and mathematics 
20924 \end_layout
20925
20926 \end_deeper
20927 \begin_layout Standard
20928 Now that I sparked your curiosity, take a look in the references.
20929 \end_layout
20930
20931 \begin_layout Subsubsection
20932 References
20933 \end_layout
20934
20935 \begin_layout Standard
20936 The complete Literate Programming FAQ can be found at:
20937 \end_layout
20938
20939 \begin_layout Quote
20940 \begin_inset LatexCommand \url[Literate Programming FAQ]{http://shelob.ce.ttu.edu/daves/lpfaq/faq.html}
20941
20942 \end_inset
20943
20944
20945 \end_layout
20946
20947 \begin_layout Standard
20948 The FAQ lists 23 (twenty three!) different literate programming tools.
20949  Where some are specialized or 
20950 \begin_inset Quotes eld
20951 \end_inset
20952
20953 tailored
20954 \begin_inset Quotes erd
20955 \end_inset
20956
20957  for particular programming languages, while other have general scope.
20958  I selected 
20959 \noun on
20960 Noweb
20961 \noun default
20962  for my own use for several reasons:
20963 \end_layout
20964
20965 \begin_layout Itemize
20966 It can generate the documentation either in LaTeX or HTML.
20967 \end_layout
20968
20969 \begin_layout Itemize
20970 It has an open architecture, i.e., it is easy to plug in new filters and to
20971  perform special processing that you may need.
20972  
20973 \end_layout
20974
20975 \begin_layout Itemize
20976 There is a good selection of filters available already (the HTML is one
20977  of them).
20978 \end_layout
20979
20980 \begin_layout Itemize
20981 It is free.
20982 \end_layout
20983
20984 \begin_layout Standard
20985 The Noweb web page can be found at: 
20986 \end_layout
20987
20988 \begin_layout Quote
20989 \begin_inset LatexCommand \url[Noweb home page]{http://www.cs.virginia.edu/~nr/noweb/}
20990
20991 \end_inset
20992
20993
20994 \end_layout
20995
20996 \begin_layout Standard
20997 Starting from there you can reach many other interesting links and even
20998  some literate program examples.
20999 \end_layout
21000
21001 \begin_layout Subsection
21002 LyX and Literate Programming
21003 \end_layout
21004
21005 \begin_layout Standard
21006 The LyX support for Literate Programming is provided by using the generic
21007  LyX convertors mechanism.
21008  This support is provided in a 
21009 \begin_inset Quotes eld
21010 \end_inset
21011
21012 Noweb independent
21013 \begin_inset Quotes erd
21014 \end_inset
21015
21016  way, i.e., you will be able to use this new LyX feature with some other literate
21017  programming tool of your choice by just changing your LyX preferences.
21018 \end_layout
21019
21020 \begin_layout Subsubsection
21021 Generating documents and code (weaving and tangling)
21022 \end_layout
21023
21024 \begin_layout Paragraph
21025 Selecting the document class
21026 \end_layout
21027
21028 \begin_layout Standard
21029 If you have installed Noweb and LyX successfully, whenever you open a new
21030  document or try to change the document class of an existing one, you will
21031  find that there are three new document classes available:
21032 \end_layout
21033
21034 \begin_layout Itemize
21035 Article (Noweb)
21036 \end_layout
21037
21038 \begin_layout Itemize
21039 Book (Noweb)
21040 \end_layout
21041
21042 \begin_layout Itemize
21043 Report (Noweb)
21044 \end_layout
21045
21046 \begin_layout Standard
21047 You must select one of them to create your literate documents from.
21048  
21049 \end_layout
21050
21051 \begin_layout Standard
21052 Note that literate documents are not limited to these three classes.
21053  New classes can be generated from other styles like letter or in combination
21054  with other class variations like Article (AMS).
21055  If you have special needs that cannot be covered by one of the existing
21056  classes, let the LyX developers list (lyx-devel@lists.lyx.org) know and we
21057  will arrange to insert a new entry, or teach you how to do it.
21058 \begin_inset Foot
21059 status collapsed
21060
21061 \begin_layout Standard
21062 It is very simple, it involves the creation of a file with four lines, and
21063  re-running of the auto configuration.
21064 \end_layout
21065
21066 \end_inset
21067
21068  Moreover, if you use a literate tool other than Noweb you may need to create
21069  a new set of document classes for it.
21070 \end_layout
21071
21072 \begin_layout Paragraph
21073 Typing code in
21074 \end_layout
21075
21076 \begin_layout Standard
21077 LyX enables you to write code with a layout named 
21078 \noun on
21079 Scrap
21080 \noun default
21081 .
21082 \begin_inset Foot
21083 status collapsed
21084
21085 \begin_layout Standard
21086 The equivalent Noweb term is 
21087 \begin_inset Quotes eld
21088 \end_inset
21089
21090 Chunk
21091 \begin_inset Quotes erd
21092 \end_inset
21093
21094 .
21095  For historical reasons, I got used to the term 
21096 \begin_inset Quotes eld
21097 \end_inset
21098
21099 scrap
21100 \begin_inset Quotes erd
21101 \end_inset
21102
21103  introduced by other literate tool named Nuweb, which I used for many years
21104  before rendering myself to Noweb.
21105 \end_layout
21106
21107 \end_inset
21108
21109  Noweb delimits scraps like this:
21110 \end_layout
21111
21112 \begin_layout LyX-Code
21113 <<My scrap>>=
21114 \end_layout
21115
21116 \begin_layout LyX-Code
21117   code
21118 \end_layout
21119
21120 \begin_layout LyX-Code
21121   more code
21122 \end_layout
21123
21124 \begin_layout LyX-Code
21125   even more code
21126 \end_layout
21127
21128 \begin_layout LyX-Code
21129   @
21130 \end_layout
21131
21132 \begin_layout Standard
21133 The problem is that whatever is written in between the << and the 
21134 \family typewriter
21135 @
21136 \family default
21137  must be taken literally, i.e., LyX should be prevented from making any special
21138  interpretation of what has been written.
21139  This is handled by a special layout named Scrap, that works like a normal
21140  paragraph but has a free spacing capability.
21141 \end_layout
21142
21143 \begin_layout Standard
21144 The down side of the Scrap paragraph layout is that consecutive paragraphs
21145  of code will be spaced with one empty line in the source code and also
21146  in the printed documentation.
21147  The work around is to enter each line of code within a single Scrap, with
21148  a newline (ctrl-return).
21149  The example above will look like this:
21150 \begin_inset Foot
21151 status collapsed
21152
21153 \begin_layout Standard
21154 If you have a printed version of this document you will not see any difference
21155  between the previous example and this one.
21156 \end_layout
21157
21158 \end_inset
21159
21160
21161 \end_layout
21162
21163 \begin_layout LyX-Code
21164 <<My scrap>>=
21165 \newline
21166   code
21167 \newline
21168   more code
21169 \newline
21170   even more code
21171 \newline
21172   @
21173 \end_layout
21174
21175 \begin_layout Standard
21176 This layout works fine.
21177  The only real inconvenience is that you have to type ctrl-return instead
21178  of a plain return.
21179 \begin_inset Foot
21180 status collapsed
21181
21182 \begin_layout Standard
21183 It is in my list of 
21184 \begin_inset Quotes eld
21185 \end_inset
21186
21187 improvements
21188 \begin_inset Quotes erd
21189 \end_inset
21190
21191  to fix that.
21192 \end_layout
21193
21194 \end_inset
21195
21196
21197 \end_layout
21198
21199 \begin_layout Standard
21200 As a special note, you can also use the 
21201 \begin_inset Quotes eld
21202 \end_inset
21203
21204 %def
21205 \begin_inset Quotes erd
21206 \end_inset
21207
21208  construct of Noweb in your scraps to add items to Noweb's identifier cross-refe
21209 rence:
21210 \end_layout
21211
21212 \begin_layout LyX-Code
21213 <<My scrap>>=
21214 \newline
21215   def some_function(args):
21216 \newline
21217     "This is the doc string for this
21218  function."
21219 \newline
21220     print "My args: ", args
21221 \end_layout
21222
21223 \begin_layout LyX-Code
21224 @ %def some_function
21225 \end_layout
21226
21227 \begin_layout Standard
21228 For an example of this usage and the resulting cross-reference output, look
21229  at the Literate python program in 
21230 \emph on
21231 LIBDIR/examples/listerrors.lyx 
21232 \emph default
21233 which should make this all clear.
21234 \end_layout
21235
21236 \begin_layout Paragraph
21237 Generating the documentation
21238 \end_layout
21239
21240 \begin_layout Standard
21241 At this point you already have a new document file with a proper document
21242  class, and with some code and text on it.
21243  How do I print it? The answer is simple, you select 
21244 \family sans
21245 \bar under
21246 V
21247 \bar default
21248 iew\SpecialChar \menuseparator
21249
21250 \bar under
21251 D
21252 \bar default
21253 VI,
21254 \family default
21255  etc.
21256  Just like you would do for a plain document.
21257  No special procedure is required.
21258 \end_layout
21259
21260 \begin_layout Standard
21261 To help orientate you, I will now explain what happens inside LyX:
21262 \end_layout
21263
21264 \begin_layout Enumerate
21265 When the 
21266 \family sans
21267 \bar under
21268 U
21269 \bar default
21270 pdate\SpecialChar \menuseparator
21271
21272 \bar under
21273 D
21274 \bar default
21275 VI 
21276 \family default
21277 menu option is chosen, a LaTeX file is generated.
21278  
21279 \end_layout
21280
21281 \begin_deeper
21282 \begin_layout Standard
21283 If the document is of any literate class the generated file will be named
21284  with an extension name defined by the 
21285 \begin_inset Quotes eld
21286 \end_inset
21287
21288 literate
21289 \begin_inset Quotes erd
21290 \end_inset
21291
21292  format (defined in the Preferences panel), otherwise the file will have
21293  the usual 
21294 \family typewriter
21295 .tex 
21296 \family default
21297 extension.
21298 \end_layout
21299
21300 \end_deeper
21301 \begin_layout Enumerate
21302 Note that the only difference so far is in the name of the file, no special
21303  processing is required by LyX.
21304  Given that you formatted the code using the Scrap layout that, by itself,
21305  takes care of the business.
21306 \end_layout
21307
21308 \begin_layout Enumerate
21309 If the document is of any literate class LyX will then use the internal
21310  LyX to Noweb converter, followed by the Noweb to LaTeX converter
21311 \begin_inset Foot
21312 status open
21313
21314 \begin_layout Standard
21315 The converters are defined in the 
21316 \family sans
21317 \bar under
21318 T
21319 \bar default
21320 ools\SpecialChar \menuseparator
21321
21322 \bar under
21323 P
21324 \bar default
21325 references
21326 \family default
21327  panel, under the 
21328 \begin_inset Quotes eld
21329 \end_inset
21330
21331 Conversion
21332 \begin_inset Quotes erd
21333 \end_inset
21334
21335  tab.
21336 \end_layout
21337
21338 \end_inset
21339
21340  to generate the LaTeX file.
21341 \end_layout
21342
21343 \begin_deeper
21344 \begin_layout Standard
21345 Otherwise it will just skip this step.
21346 \end_layout
21347
21348 \end_deeper
21349 \begin_layout Enumerate
21350 Finally, LaTeX is invoked and the regular post processing continues as in
21351  a plain document.
21352 \end_layout
21353
21354 \begin_layout Standard
21355 Independence from a particular 
21356 \begin_inset Quotes eld
21357 \end_inset
21358
21359 literate tool
21360 \begin_inset Quotes erd
21361 \end_inset
21362
21363  is easily achieved by changing the commands that are run by the various
21364  converters.
21365 \end_layout
21366
21367 \begin_layout Paragraph
21368 Generating the code
21369 \end_layout
21370
21371 \begin_layout Standard
21372 When the build menu option is chosen or the corresponding button in the
21373  toolbar is pressed, a LaTeX file is generated just like step 1 above.
21374  Next, LyX invokes the
21375 \family typewriter
21376  Noweb->Program
21377 \family default
21378  converter.
21379  Typically, this converter (like any other converter), has two parts:
21380 \end_layout
21381
21382 \begin_layout Enumerate
21383 The converter program itself.
21384  This program performs the conversion from the one format to the other (in
21385  this case, from the Noweb format to the Program pseudo-format).
21386 \end_layout
21387
21388 \begin_layout Enumerate
21389 The error log parser.
21390  This is a program whose sole purpose is to rewrite error messages in a
21391  format that LyX understands.
21392  This makes it possible for LyX to place error boxes in the right places
21393  in the file buffer.
21394 \end_layout
21395
21396 \begin_layout Standard
21397 The first part, the 
21398 \begin_inset Quotes eld
21399 \end_inset
21400
21401 Converter
21402 \begin_inset Quotes erd
21403 \end_inset
21404
21405  setting, should be set to 
21406 \begin_inset Quotes eld
21407 \end_inset
21408
21409
21410 \family typewriter
21411 build-script $$i
21412 \family default
21413
21414 \begin_inset Quotes erd
21415 \end_inset
21416
21417 .
21418  This basically means that LyX will call 
21419 \begin_inset Quotes eld
21420 \end_inset
21421
21422 build-script
21423 \begin_inset Quotes erd
21424 \end_inset
21425
21426  (a program or script) with the name of the Noweb file (generally a file
21427  in the LyX temp directory).
21428  
21429 \end_layout
21430
21431 \begin_layout Standard
21432 This is an implementation of 
21433 \begin_inset Quotes eld
21434 \end_inset
21435
21436 build-script
21437 \begin_inset Quotes erd
21438 \end_inset
21439
21440  that you can place in a directory on your path:
21441 \end_layout
21442
21443 \begin_layout LyX-Code
21444 #!/bin/sh
21445 \end_layout
21446
21447 \begin_layout LyX-Code
21448 #
21449 \end_layout
21450
21451 \begin_layout LyX-Code
21452 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 sh
21453 \end_layout
21454
21455 \begin_layout Standard
21456 The next part of the converter setting is the 
21457 \begin_inset Quotes eld
21458 \end_inset
21459
21460 Flags
21461 \begin_inset Quotes erd
21462 \end_inset
21463
21464  which is to be set to 
21465 \begin_inset Quotes eld
21466 \end_inset
21467
21468
21469 \family typewriter
21470 originaldir,parselog=listerrors
21471 \family default
21472
21473 \begin_inset Quotes erd
21474 \end_inset
21475
21476 .
21477  This will run any errors that are generated by the 
21478 \begin_inset Quotes eld
21479 \end_inset
21480
21481 build-script
21482 \begin_inset Quotes erd
21483 \end_inset
21484
21485  process through the 
21486 \begin_inset Quotes eld
21487 \end_inset
21488
21489 listerrors
21490 \begin_inset Quotes erd
21491 \end_inset
21492
21493  program.
21494 \end_layout
21495
21496 \begin_layout Standard
21497 The converter code looks in 
21498 \emph on
21499 MYLYXDIR/scripts 
21500 \emph default
21501 first, then in
21502 \emph on
21503  LIBDIR/scripts 
21504 \emph default
21505 then on the path for the 
21506 \begin_inset Quotes eld
21507 \end_inset
21508
21509 listerrors
21510 \begin_inset Quotes erd
21511 \end_inset
21512
21513  program.
21514 \end_layout
21515
21516 \begin_layout Paragraph
21517 Build instructions in the document
21518 \end_layout
21519
21520 \begin_layout Standard
21521 The last piece of the integration between LyX and noweb is the 
21522 \begin_inset Quotes eld
21523 \end_inset
21524
21525 build-script
21526 \begin_inset Quotes erd
21527 \end_inset
21528
21529  scrap.
21530  Generally, the instructions for building your program should be embedded
21531  in a scrap of its own.
21532  The noweb-specific 
21533 \begin_inset Quotes eld
21534 \end_inset
21535
21536 build-script
21537 \begin_inset Quotes erd
21538 \end_inset
21539
21540  above uses the notangle command to look for this scrap (called 
21541 \begin_inset Quotes eld
21542 \end_inset
21543
21544 build-script
21545 \begin_inset Quotes erd
21546 \end_inset
21547
21548 ) and runs its contents through 
21549 \begin_inset Quotes eld
21550 \end_inset
21551
21552 sh
21553 \begin_inset Quotes erd
21554 \end_inset
21555
21556 .
21557 \end_layout
21558
21559 \begin_layout Standard
21560 Typically, such a scrap would look something like this:
21561 \end_layout
21562
21563 \begin_layout LyX-Code
21564 <<build-script>>=
21565 \newline
21566 #!/bin/sh
21567 \newline
21568
21569 \newline
21570 if [ -z "${NOWEB_SOURCE}" ]
21571 \newline
21572 then
21573 \newline
21574   NOWEB_SOURCE=myfile.nw
21575 \newline
21576
21577 fi
21578 \newline
21579 [...
21580  code to extract files ...]
21581 \newline
21582 [...
21583  code to compile files ...]
21584 \newline
21585 @
21586 \end_layout
21587
21588 \begin_layout Standard
21589 Look in 
21590 \emph on
21591 LIBDIR/examples/listerrors.lyx 
21592 \emph default
21593 or in 
21594 \emph on
21595 LIBDIR/examples/Literate.lyx
21596 \emph default
21597  which implement two versions of the 
21598 \begin_inset Quotes eld
21599 \end_inset
21600
21601 listerrors
21602 \begin_inset Quotes erd
21603 \end_inset
21604
21605  program for some illustrations of how all of these pieces go together or
21606  in 
21607 \emph on
21608 LIBDIR/examples/noweb2lyx.lyx.
21609  
21610 \emph default
21611 Interestingly, these three files show off the language-indepence of the
21612  LyX literate programming support since they are written in Python, C and
21613  Perl respectively.
21614 \end_layout
21615
21616 \begin_layout Subsubsection
21617 Configuring LyX
21618 \end_layout
21619
21620 \begin_layout Standard
21621 All the Literate Programming support is configured by the 
21622 \family sans
21623 \bar under
21624 T
21625 \bar default
21626 ools\SpecialChar \menuseparator
21627
21628 \bar under
21629 P
21630 \bar default
21631 references
21632 \family default
21633  panel in the 
21634 \begin_inset Quotes eld
21635 \end_inset
21636
21637 Conversion
21638 \begin_inset Quotes erd
21639 \end_inset
21640
21641  tab.
21642  The important parts are:
21643 \end_layout
21644
21645 \begin_layout Description
21646 the\InsetSpace ~
21647
21648 \begin_inset Quotes eld
21649 \end_inset
21650
21651 literate
21652 \begin_inset Quotes erd
21653 \end_inset
21654
21655 \InsetSpace ~
21656 format Set up via the Formats tab, this is where the Noweb-specific pieces
21657  are set up.
21658  The 
21659 \family sans
21660 GUI Name
21661 \family default
21662  is set to 
21663 \family typewriter
21664 NoWeb
21665 \family default
21666 , the file extension is set to 
21667 \family typewriter
21668 .nw
21669 \family default
21670 .
21671  This tells LyX to create a file with a 
21672 \family typewriter
21673 .nw
21674 \family default
21675  extension in the first step of the conversion process.
21676 \end_layout
21677
21678 \begin_layout Description
21679 the\InsetSpace ~
21680
21681 \family sans
21682 Program
21683 \family default
21684 \InsetSpace ~
21685 format This is an empty format whose sole purpose is to be the endpoint
21686  of a conversion (which then allows us to set up a converter for it).
21687 \end_layout
21688
21689 \begin_layout Description
21690
21691 \family sans
21692 NoWeb
21693 \family default
21694 ->
21695 \family sans
21696 LaTeX
21697 \family default
21698  This converter performs the 
21699 \begin_inset Quotes eld
21700 \end_inset
21701
21702 weaving
21703 \begin_inset Quotes erd
21704 \end_inset
21705
21706  of the literate document.
21707  For Noweb, it is set to 
21708 \begin_inset Quotes eld
21709 \end_inset
21710
21711
21712 \family typewriter
21713 noweave -delay -index $$i > $$o
21714 \family default
21715
21716 \begin_inset Quotes erd
21717 \end_inset
21718
21719
21720 \end_layout
21721
21722 \begin_layout Description
21723
21724 \family sans
21725 NoWeb
21726 \family default
21727 ->
21728 \family sans
21729 Program
21730 \family default
21731  This performs the 
21732 \begin_inset Quotes eld
21733 \end_inset
21734
21735 tangling step
21736 \begin_inset Quotes erd
21737 \end_inset
21738
21739 .
21740  As stated above, the Converter is set to 
21741 \begin_inset Quotes eld
21742 \end_inset
21743
21744
21745 \family typewriter
21746 build-script $$i
21747 \family default
21748
21749 \begin_inset Quotes erd
21750 \end_inset
21751
21752 , with Flags set to 
21753 \begin_inset Quotes eld
21754 \end_inset
21755
21756
21757 \family typewriter
21758 originaldir,parselog=listerrors
21759 \family default
21760
21761 \begin_inset Quotes erd
21762 \end_inset
21763
21764 .
21765 \end_layout
21766
21767 \begin_layout Subsubsection
21768 Debug extensions
21769 \end_layout
21770
21771 \begin_layout Standard
21772 There is also a new function implemented in the LyX server, the 
21773 \begin_inset Quotes eld
21774 \end_inset
21775
21776 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
21777  
21778 \end_layout
21779
21780 \begin_layout Standard
21781 When debugging code with ddd/gdb, it is possible to invoke a text editor
21782  at the current execution position with a single key stroke.
21783  The default ddd configuration for that is shift-ctrl-V.
21784  It happens that you can define the editor command line invocation in ddd
21785  by accessing the
21786 \family sans
21787  
21788 \bar under
21789 E
21790 \bar default
21791 dit\SpecialChar \menuseparator
21792
21793 \bar under
21794 P
21795 \bar default
21796 references\SpecialChar \menuseparator
21797
21798 \bar under
21799 H
21800 \bar default
21801 elpers 
21802 \family default
21803 dialog and changing the "Edit Sources" entry.
21804 \end_layout
21805
21806 \begin_layout Standard
21807 I take advantage of the new created LyX server function and this ddd feature,
21808  and set 
21809 \begin_inset Quotes eld
21810 \end_inset
21811
21812 Edit Sources
21813 \begin_inset Quotes erd
21814 \end_inset
21815
21816  to:
21817 \end_layout
21818
21819 \begin_layout LyX-Code
21820 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
21821 \end_layout
21822
21823 \begin_layout Standard
21824 With this, whenever you are using ddd and find a point in the program that
21825  you want to edit, you just press shift-ctrl-V (in the ddd window), and
21826  ddd you forward this information to LyX through the LyX server and then
21827  the LyX window will show the same file with the cursor at the same position
21828  ddd was pointing to.
21829  No more guessing or long scrolling to locate a point in the program back
21830  from debugging !
21831 \end_layout
21832
21833 \begin_layout Standard
21834 Note however that you must enable the LyX server to get this feature working
21835  (it is disabled by default).
21836  You can enable it in 
21837 \family sans
21838 Preferences
21839 \family default
21840  (tabs 
21841 \family sans
21842 Inputs
21843 \family default
21844
21845 \family sans
21846 Paths
21847 \family default
21848 ) by entering in the 
21849 \family sans
21850 LyXserver pipe
21851 \family default
21852  a path like 
21853 \begin_inset Quotes eld
21854 \end_inset
21855
21856
21857 \family typewriter
21858 /home/<your-home-directory>/.lyx/lyxpipe
21859 \family default
21860
21861 \begin_inset Quotes erd
21862 \end_inset
21863
21864
21865 \end_layout
21866
21867 \begin_layout Standard
21868 Read the LyX server documentation in the 
21869 \emph on
21870 Customization Manual
21871 \emph default
21872  for further information.
21873 \end_layout
21874
21875 \begin_layout Subsubsection
21876 Toolbar extensions
21877 \end_layout
21878
21879 \begin_layout Standard
21880 There are six new buttons that can be added to your LyX toolbar.
21881  Five of these buttons are short cuts to layout styles: 
21882 \family sans
21883 Standard
21884 \family default
21885
21886 \family sans
21887 Section
21888 \family default
21889
21890 \family sans
21891 LaTeX
21892 \family default
21893
21894 \family sans
21895 LyX-Code
21896 \family default
21897 , and 
21898 \family sans
21899 Scrap
21900 \family default
21901 .
21902  The last one is a short cut to the 
21903 \begin_inset Quotes eld
21904 \end_inset
21905
21906 Build Program
21907 \begin_inset Quotes erd
21908 \end_inset
21909
21910  File menu entry.
21911  
21912 \end_layout
21913
21914 \begin_layout Standard
21915 LyX has a range of buttons that are available for tool bar customization.
21916  In my toolbar I like to combine the six short cuts above with two more:
21917  One for 
21918 \family sans
21919 \bar under
21920 V
21921 \bar default
21922 iew
21923 \family default
21924 \SpecialChar \menuseparator
21925
21926 \family sans
21927 \bar under
21928 U
21929 \bar default
21930 pdate
21931 \family default
21932 \SpecialChar \menuseparator
21933
21934 \family sans
21935 \bar under
21936 D
21937 \bar default
21938 VI
21939 \family default
21940  and the other for 
21941 \family sans
21942 \bar under
21943 V
21944 \bar default
21945 iew\SpecialChar \menuseparator
21946
21947 \bar under
21948 D
21949 \bar default
21950 VI
21951 \family default
21952  File menu entries.
21953  Here is how it looks like:
21954 \end_layout
21955
21956 \begin_layout LyX-Code
21957 Toolbar
21958 \end_layout
21959
21960 \begin_layout LyX-Code
21961   Layouts
21962 \end_layout
21963
21964 \begin_layout LyX-Code
21965   Icon "layout Standard"
21966 \end_layout
21967
21968 \begin_layout LyX-Code
21969   Icon "layout Section"
21970 \end_layout
21971
21972 \begin_layout LyX-Code
21973   Icon "layout LaTeX"
21974 \end_layout
21975
21976 \begin_layout LyX-Code
21977   Icon "layout LyX-Code"
21978 \end_layout
21979
21980 \begin_layout LyX-Code
21981   Icon "layout Scrap"
21982 \end_layout
21983
21984 \begin_layout LyX-Code
21985   Separator
21986 \end_layout
21987
21988 \begin_layout LyX-Code
21989   Icon "buffer-view"
21990 \end_layout
21991
21992 \begin_layout LyX-Code
21993   Icon "buffer-typeset"
21994 \end_layout
21995
21996 \begin_layout LyX-Code
21997   Icon "build-program"
21998 \end_layout
21999
22000 \begin_layout LyX-Code
22001   Separator
22002 \end_layout
22003
22004 \begin_layout LyX-Code
22005 .
22006 \end_layout
22007
22008 \begin_layout LyX-Code
22009 .
22010 \end_layout
22011
22012 \begin_layout LyX-Code
22013 .
22014 \end_layout
22015
22016 \begin_layout LyX-Code
22017 End
22018 \end_layout
22019
22020 \begin_layout Subsubsection
22021 Colors customization
22022 \end_layout
22023
22024 \begin_layout Standard
22025 There are a number of colors in LyX that can be customized in 
22026 \family sans
22027 Preferences
22028 \family default
22029 .
22030  One of the things that bothers people is the LaTeX font color.
22031  The default color is red, since the scraps uses LaTeX font, and there is
22032  a lot of scraps in literate documents, you may get tired of seeing everything
22033  in red.
22034  You can change it by going to the tabs 
22035 \family sans
22036 Look&Feel
22037 \family default
22038
22039 \family sans
22040 Colors.
22041 \end_layout
22042
22043 \begin_layout Standard
22044 The next thing is the visible presence of the newline character in the screen.
22045  You can choose the color of this particular character and make it blend
22046  in the background.
22047  I recommend you choosing a color that is close to the background but not
22048  equal, that way you still can see it is there, but it is not bothering
22049  you anymore.
22050  
22051 \end_layout
22052
22053 \begin_layout Chapter
22054 Secrets of the LaTeX Masters
22055 \begin_inset LatexCommand \label{cha:secrets}
22056
22057 \end_inset
22058
22059
22060 \end_layout
22061
22062 \begin_layout Standard
22063 Though LyX is a powerful tool, it cannot hope to support everything that
22064  can be done with pure TeX/LaTeX.
22065  However, many familiar dirty TeX and LaTeX tricks can be done within LyX,
22066  as long as you are not afraid to use that 
22067 \begin_inset Quotes eld
22068 \end_inset
22069
22070 TeX
22071 \begin_inset Quotes erd
22072 \end_inset
22073
22074  button on the toolbar or add things to the LaTeX preamble.
22075  This section lists some tips, tricks, and otherwise cool ideas to give
22076  your document that extra little flair.
22077  
22078 \emph on
22079 Do try this at home
22080 \emph default
22081 , just start with something a little smaller and less important than your
22082  dissertation!
22083 \end_layout
22084
22085 \begin_layout Standard
22086 Most ideas in this section require less common files in your LaTeX installation.
22087  If you have a system like teTeX, most will already be available.
22088  A few, however, will need to be downloaded from one of the CTAN archives.
22089  Often, there are several ways to do something, or several LaTeX style files
22090  which do the same thing.
22091  We do not endorse one choice over another, we simply claim that we have
22092  done a particular task with a particular file.
22093  Put on your wizard hat, keep an eye out for dragons, and let us begin.
22094 \end_layout
22095
22096 \begin_layout Section
22097 Tricks for Footnotes and Margin Notes
22098 \end_layout
22099
22100 \begin_layout Standard
22101 suggested by 
22102 \noun on
22103 Robin Socha
22104 \end_layout
22105
22106 \begin_layout Subsection
22107 Footnotes 
22108 \end_layout
22109
22110 \begin_layout Standard
22111 LyX cannot yet take care of setting the footnote numbering back to 1 after
22112  each section in the 
22113 \begin_inset Quotes eld
22114 \end_inset
22115
22116
22117 \family sans
22118 article
22119 \family default
22120
22121 \begin_inset Quotes erd
22122 \end_inset
22123
22124
22125 \family roman
22126  document class or changing the counter style.
22127  You'll need to insert LaTeX commands like the following to achieve that:
22128 \end_layout
22129
22130 \begin_layout Standard
22131 \begin_inset ERT
22132 status inlined
22133
22134 \begin_layout Standard
22135
22136
22137 \backslash
22138 setcounter{footnote}{0}
22139 \end_layout
22140
22141 \end_inset
22142
22143  Using 
22144 \family typewriter
22145
22146 \backslash
22147 setcounter{footnote}{0}
22148 \family roman
22149  will set the counter back to 1
22150 \begin_inset Foot
22151 status collapsed
22152
22153 \begin_layout Standard
22154 The counter has been set back to 1.
22155 \end_layout
22156
22157 \end_inset
22158
22159 .
22160 \end_layout
22161
22162 \begin_layout Standard
22163 The following command will change the numbering to small letters.
22164  Take a look at the next footnote in your xdvi or ghostview 
22165 \begin_inset ERT
22166 status inlined
22167
22168 \begin_layout Standard
22169
22170
22171 \backslash
22172 renewcommand{
22173 \backslash
22174 thefootnote}{
22175 \backslash
22176 alph{footnote}}
22177 \end_layout
22178
22179 \end_inset
22180
22181 :
22182 \begin_inset Foot
22183 status collapsed
22184
22185 \begin_layout Standard
22186 This is an example for a footnote with alphabetic numbering.
22187 \newline
22188 Use
22189 \family typewriter
22190  
22191 \backslash
22192 renewcommand{
22193 \backslash
22194 thefootnote {
22195 \backslash
22196 alph{footnote}} 
22197 \family roman
22198 to get this.
22199 \end_layout
22200
22201 \end_inset
22202
22203
22204 \end_layout
22205
22206 \begin_layout Standard
22207 The next command sets the counter style back to default, i.e.
22208  
22209 \family typewriter
22210
22211 \backslash
22212 arabic
22213 \family default
22214
22215 \begin_inset Foot
22216 status collapsed
22217
22218 \begin_layout Standard
22219 Use
22220 \family typewriter
22221  
22222 \backslash
22223 renewcommand{
22224 \backslash
22225 thefootnote}{
22226 \backslash
22227 arabic{footnote}}
22228 \family roman
22229  to set the counter--style back to LyX's default, i.e.
22230  
22231 \backslash
22232 arabic.
22233 \family default
22234
22235 \begin_inset ERT
22236 status collapsed
22237
22238 \begin_layout Standard
22239
22240
22241 \backslash
22242 renewcommand {
22243 \backslash
22244 thefootnote} {
22245 \backslash
22246 arabic{footnote}}
22247 \end_layout
22248
22249 \end_inset
22250
22251
22252 \end_layout
22253
22254 \end_inset
22255
22256 .
22257 \end_layout
22258
22259 \begin_layout Standard
22260 You can use 
22261 \family typewriter
22262
22263 \backslash
22264 arabic
22265 \family default
22266
22267 \family typewriter
22268
22269 \backslash
22270 roman
22271 \family default
22272
22273 \family typewriter
22274
22275 \backslash
22276 Roman
22277 \family default
22278
22279 \family typewriter
22280
22281 \backslash
22282 alph
22283 \family default
22284  or 
22285 \family typewriter
22286
22287 \backslash
22288 Alph
22289 \family default
22290  and others as counter styles.
22291  Just replace the LaTeX command in the above example and rerun TeX to see
22292  what those styles can do.
22293  
22294 \end_layout
22295
22296 \begin_layout Subsection
22297 Margin Notes
22298 \end_layout
22299
22300 \begin_layout Standard
22301 Here are two examples of neat things you can do to margin notes using LaTeX
22302  commands.
22303 \end_layout
22304
22305 \begin_layout Standard
22306 The following command will make a vertical line appear alongside your text---gre
22307 at for 
22308 \begin_inset Quotes eld
22309 \end_inset
22310
22311 thumbing
22312 \begin_inset Quotes erd
22313 \end_inset
22314
22315
22316 \family typewriter
22317
22318 \backslash
22319 marginpar{
22320 \backslash
22321 rule[-10mm]{30mm}{5mm}}
22322 \family roman
22323 .
22324 \family default
22325
22326 \begin_inset ERT
22327 status inlined
22328
22329 \begin_layout Standard
22330
22331
22332 \backslash
22333 marginpar{
22334 \backslash
22335 rule[-10mm]{30mm}{5mm}}
22336 \end_layout
22337
22338 \end_inset
22339
22340
22341 \end_layout
22342
22343 \begin_layout Standard
22344 Check your dvi- or ghostview-output to see what the 
22345 \family typewriter
22346
22347 \backslash
22348 reversemarginpar 
22349 \family default
22350 command does to the following margin note.
22351 \end_layout
22352
22353 \begin_layout Standard
22354 \begin_inset ERT
22355 status inlined
22356
22357 \begin_layout Standard
22358
22359
22360 \backslash
22361 reversemarginpar
22362 \end_layout
22363
22364 \end_inset
22365
22366
22367 \begin_inset Marginal
22368 status collapsed
22369
22370 \begin_layout Standard
22371 This is a 
22372 \newline
22373 margin note.
22374 \end_layout
22375
22376 \end_inset
22377
22378
22379 \end_layout
22380
22381 \begin_layout Section
22382 Multiple Columns
22383 \end_layout
22384
22385 \begin_layout Standard
22386 by 
22387 \noun on
22388 Lars Gullik Bjønnes
22389 \end_layout
22390
22391 \begin_layout Subsection
22392 Purpose
22393 \end_layout
22394
22395 \begin_layout Standard
22396 The aim for this chapter
22397 \begin_inset Foot
22398 status collapsed
22399
22400 \begin_layout Standard
22401 Editor's note: Lars' original chapter was a masterful description of how
22402  to use the 
22403 \family typewriter
22404 multicol
22405 \family default
22406  package.
22407  However, it was too long to flow smoothly in this document.
22408  I have therefore chosen to excerpt the most important sections here (sorry,
22409  Lars); you can read the original chapter (and more of the story!) in the
22410  example file 
22411 \family typewriter
22412 examples/multicol.lyx
22413 \family default
22414 .
22415  --- mer
22416 \end_layout
22417
22418 \end_inset
22419
22420  is to show how the LaTeX package 
22421 \family typewriter
22422 multicol
22423 \family default
22424  can be used in a LyX document.
22425  As LyX doesn't support the 
22426 \family typewriter
22427 multicol
22428 \family default
22429  package natively yet, we have to use some small hacks.
22430  By reading this section it should be obvious how to do this.
22431 \end_layout
22432
22433 \begin_layout Subsection
22434 Limitations 
22435 \end_layout
22436
22437 \begin_layout Standard
22438 The 
22439 \family typewriter
22440 multicol
22441 \family default
22442  package allows switching between one and multicolumn format on the same
22443  page.
22444  Footnotes are handled correctly (for the most part), but will be placed
22445  at the bottom of the page and not under each column.
22446  LaTeX's float mechanism, however, is partly disabled in the current implementat
22447 ion.
22448  At the moment only page-wide floats can be used within the scope of the
22449  environment.
22450 \end_layout
22451
22452 \begin_layout Subsection
22453 Examples
22454 \end_layout
22455
22456 \begin_layout Subsubsection
22457 Two columns
22458 \end_layout
22459
22460 \begin_layout Standard
22461 If you want to have two columns in your text, you have use LaTeX mode to
22462  insert 
22463 \family typewriter
22464
22465 \backslash
22466 begin{multicols}{2}
22467 \family default
22468  at the point where you want the two column layout to start, and then 
22469 \family typewriter
22470
22471 \backslash
22472 end{multicols}
22473 \family default
22474  where you want it to end.
22475  Like this:
22476 \end_layout
22477
22478 \begin_layout Standard
22479 \begin_inset ERT
22480 status inlined
22481
22482 \begin_layout Standard
22483
22484
22485 \backslash
22486 begin{multicols}{2}
22487 \end_layout
22488
22489 \end_inset
22490
22491
22492 \end_layout
22493
22494 \begin_layout Standard
22495 \noindent
22496
22497 \series bold
22498 \size small
22499 The Adventure of the Empty House
22500 \series default
22501
22502 \newline
22503 by 
22504 \noun on
22505 Sir Arthur Conan Doyle
22506 \end_layout
22507
22508 \begin_layout Standard
22509
22510 \size small
22511 It was in the spring of the year 1894 that all London was interested, and
22512  the fashionable world dismayed, by the murder of the Honourable Ronald
22513  Adair under most unusual and inexplicable circumstances.
22514  The public has already learned those particulars of the crime which came
22515  out in the police investigation, but a good deal was suppressed upon that
22516  occasion, since the case for the prosecution was so overwhelmingly strong
22517  that it was not necessary to bring forward all the facts.
22518  Only now, at the end of nearly ten years, am I allowed to supply those
22519  missing links which make up the whole of that remarkable chain.
22520  The crime was of interest in itself, but that interest was as nothing to
22521  me compared to the inconceivable sequel, which afforded me the greatest
22522  shock and surprise of any event in my adventurous life.
22523  Even now, after this long interval, I find myself thrilling as I think
22524  of it, and feeling once more that sudden flood of joy, amazement, and increduli
22525 ty which utterly submerged my mind.
22526  Let me say to that public, which has shown some interest in those glimpses
22527  which I have occasionally given them of the thoughts and actions of a very
22528  remarkable man, that they are not to blame me if I have not shared my knowledge
22529  with them, for I should have considered it my first duty to do so, had
22530  I not been barred by a positive prohibition from his own lips, which was
22531  only withdrawn upon the third of last month.
22532 \end_layout
22533
22534 \begin_layout Standard
22535 \begin_inset ERT
22536 status inlined
22537
22538 \begin_layout Standard
22539
22540
22541 \backslash
22542 end{multicols}
22543 \end_layout
22544
22545 \end_inset
22546
22547
22548 \end_layout
22549
22550 \begin_layout Subsubsection
22551 Multiple columns
22552 \end_layout
22553
22554 \begin_layout Standard
22555 The same pattern is used when you want more than two columns:
22556 \end_layout
22557
22558 \begin_layout Standard
22559 \begin_inset ERT
22560 status inlined
22561
22562 \begin_layout Standard
22563
22564
22565 \backslash
22566 begin{multicols}{3}
22567 \end_layout
22568
22569 \end_inset
22570
22571
22572 \end_layout
22573
22574 \begin_layout Standard
22575
22576 \size footnotesize
22577 It can be imagined that my close intimacy with Sherlock Holmes had interested
22578  me deeply in crime, and that after his disappearance I never failed to
22579  read with care the various problems which came before the public.
22580  And I even attempted, more than once, for my own private satisfaction,
22581  to employ his methods in their solution, though with indifferent success.
22582  There was none, however, which appealed to me like this tragedy of Ronald
22583  Adair.
22584  As I read the evidence at the inquest, which led up to a verdict of willful
22585  murder against some person or persons unknown, I realized more clearly
22586  than I had ever done the loss which the community had sustained by the
22587  death of Sherlock Holmes.
22588  There were points about this strange business which would, I was sure,
22589  have specially appealed to him, and the efforts of the police would have
22590  been supplemented, or more probably anticipated, by the trained observation
22591  and the alert mind of the first criminal agent in Europe.
22592  All day, as I drove upon my round, I turned over the case in my mind and
22593  found no explanation which appeared to me to be adequate.
22594  At the risk of telling a twice-told tale, I will recapitulate the facts
22595  as they were known to the public at the conclusion of the inquest.
22596 \end_layout
22597
22598 \begin_layout Standard
22599 \begin_inset ERT
22600 status inlined
22601
22602 \begin_layout Standard
22603
22604
22605 \backslash
22606 end{multicols}
22607 \end_layout
22608
22609 \end_inset
22610
22611
22612 \end_layout
22613
22614 \begin_layout Standard
22615 You can have more than 3 columns if you want to, but that might not be very
22616  pleasant for the eye.
22617 \end_layout
22618
22619 \begin_layout Subsubsection
22620 Columns inside columns
22621 \end_layout
22622
22623 \begin_layout Standard
22624 You can even have columns inside columns:
22625 \end_layout
22626
22627 \begin_layout Standard
22628 \begin_inset ERT
22629 status inlined
22630
22631 \begin_layout Standard
22632
22633
22634 \backslash
22635 begin{multicols}{2}
22636 \end_layout
22637
22638 \end_inset
22639
22640
22641 \end_layout
22642
22643 \begin_layout Standard
22644
22645 \size footnotesize
22646 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
22647  at that time governor of one of the Australian colonies.
22648  Adair's mother had returned from Australia to undergo the operation for
22649  cataract, and she, her son Ronald, and her daughter Hilda were living together
22650  at 427 Park Lane.
22651 \end_layout
22652
22653 \begin_layout Standard
22654 \begin_inset ERT
22655 status inlined
22656
22657 \begin_layout Standard
22658
22659
22660 \backslash
22661 begin{multicols}{2}
22662 \end_layout
22663
22664 \end_inset
22665
22666
22667 \end_layout
22668
22669 \begin_layout Standard
22670
22671 \size footnotesize
22672 The youth moved in the best society--had, so far as was known, no enemies
22673  and no particular vices.
22674  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
22675  had been broken off by mutual consent some months before, and there was
22676  no sign that it had left any very profound feeling behind it.
22677  For the rest {sic} the man's life moved in a narrow and conventional circle,
22678  for his habits were quiet and his nature unemotional.
22679  Yet it was upon this easy-going young aristocrat that death came, in most
22680  strange and unexpected form, between the hours of ten and eleven-twenty
22681  on the night of March 30, 1894.
22682 \end_layout
22683
22684 \begin_layout Standard
22685 \begin_inset ERT
22686 status inlined
22687
22688 \begin_layout Standard
22689
22690
22691 \backslash
22692 end{multicols}
22693 \end_layout
22694
22695 \end_inset
22696
22697
22698 \end_layout
22699
22700 \begin_layout Standard
22701
22702 \size footnotesize
22703 Ronald Adair was fond of cards--playing continually, but never for such
22704  stakes as would hurt him.
22705  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
22706  It was shown that, after dinner on the day of his death, he had played
22707  a rubber of whist at the latter club.
22708  He had also played there in the afternoon.
22709
22710 \size default
22711  
22712 \size footnotesize
22713 The evidence of those who had played with him-- Mr.
22714  Murray, Sir John Hardy, and Colonel Moran--showed that the game was whist,
22715  and that there was a fairly equal fall of the cards.
22716  Adair might have lost five pounds, but not more.
22717  His fortune was a considerable one, and such a loss could not in any way
22718  affect him.
22719  He had played nearly every day at one club or other, but he was a cautious
22720  player, and usually rose a winner.
22721  It came out in evidence that, in partnership with Colonel Moran, he had
22722  actually won as much as four hundred and twenty pounds in a sitting, some
22723  weeks before, from Godfrey Milner and Lord Balmoral.
22724  So much for his recent history as it came out at the inquest.
22725 \end_layout
22726
22727 \begin_layout Standard
22728 \begin_inset ERT
22729 status inlined
22730
22731 \begin_layout Standard
22732
22733
22734 \backslash
22735 end{multicols}
22736 \end_layout
22737
22738 \end_inset
22739
22740
22741 \end_layout
22742
22743 \begin_layout Standard
22744 Please do read the file 
22745 \family typewriter
22746 examples/multicol.lyx
22747 \family default
22748  for more advanced examples including column and header spacing, vertical
22749  separator lines, and more.
22750 \end_layout
22751
22752 \begin_layout Section
22753 Numbering in the 
22754 \family sans
22755 Enumerate
22756 \family default
22757  Paragraph Environment
22758 \begin_inset OptArg
22759 status collapsed
22760
22761 \begin_layout Standard
22762 Numbering in Enumerate
22763 \end_layout
22764
22765 \end_inset
22766
22767
22768 \end_layout
22769
22770 \begin_layout Standard
22771 by 
22772 \noun on
22773 John Weiss
22774 \end_layout
22775
22776 \begin_layout Standard
22777 \begin_inset VSpace bigskip
22778 \end_inset
22779
22780
22781 \end_layout
22782
22783 \begin_layout Standard
22784 \noindent
22785 The default numbering for the 
22786 \family sans
22787 Enumerate
22788 \family default
22789  paragraph environment begins with Arabic numbers and ends with uppercase
22790  letters.
22791  Suppose, however, you wanted a different type of numbering scheme.
22792  Here's a quickie example of how to change the numbering scheme:
22793 \end_layout
22794
22795 \begin_layout LyX-Code
22796
22797 \backslash
22798 renewcommand{
22799 \backslash
22800 labelenumi}{
22801 \backslash
22802 Roman{enumi}.}
22803 \end_layout
22804
22805 \begin_layout LyX-Code
22806
22807 \backslash
22808 renewcommand{
22809 \backslash
22810 labelenumii}{
22811 \backslash
22812 Alph{enumii}.}
22813 \end_layout
22814
22815 \begin_layout LyX-Code
22816
22817 \backslash
22818 renewcommand{
22819 \backslash
22820 labelenumiii}{
22821 \backslash
22822 arabic{enumiii}.}
22823 \end_layout
22824
22825 \begin_layout LyX-Code
22826
22827 \backslash
22828 renewcommand{
22829 \backslash
22830 labelenumiv}{
22831 \backslash
22832 alph{enumiv}.)}
22833 \end_layout
22834
22835 \begin_layout Standard
22836 \SpecialChar \ldots{}
22837  which changes the numbering scheme to uppercase Roman numerals, uppercase
22838  letters, Arabic numbers, and lowercase letter.
22839 \end_layout
22840
22841 \begin_layout Standard
22842 Additionally, the previous example also adds a little bit extra to the numbering
22843  scheme.
22844  For example, the first level label actually looks like: 
22845 \begin_inset Quotes eld
22846 \end_inset
22847
22848 I.
22849 \begin_inset Quotes erd
22850 \end_inset
22851
22852 .
22853  For ease of reading, we'll describe what the numbering schemes look like
22854  using a notation something like this: <
22855 \begin_inset Quotes eld
22856 \end_inset
22857
22858 I.
22859 \begin_inset Quotes erd
22860 \end_inset
22861
22862 ,\InsetSpace ~
22863
22864 \begin_inset Quotes erd
22865 \end_inset
22866
22867 A.
22868 \begin_inset Quotes erd
22869 \end_inset
22870
22871 ,\InsetSpace ~
22872
22873 \begin_inset Quotes erd
22874 \end_inset
22875
22876 1.
22877 \begin_inset Quotes erd
22878 \end_inset
22879
22880 ,\InsetSpace ~
22881
22882 \begin_inset Quotes eld
22883 \end_inset
22884
22885 a.)
22886 \begin_inset Quotes erd
22887 \end_inset
22888
22889 >.
22890  
22891 \end_layout
22892
22893 \begin_layout Standard
22894 As you can see in the example, there is a label command for each nesting
22895  level, 
22896 \family typewriter
22897
22898 \backslash
22899 labelenumi
22900 \family default
22901  \SpecialChar \ldots{}
22902  
22903 \family typewriter
22904
22905 \backslash
22906 labelenumiv
22907 \family default
22908 , as well as a counter, 
22909 \family typewriter
22910 enumi
22911 \family default
22912  \SpecialChar \ldots{}
22913  
22914 \family typewriter
22915 enumiv
22916 \family default
22917 .
22918  There are also five 
22919 \begin_inset Quotes eld
22920 \end_inset
22921
22922 number printing
22923 \begin_inset Quotes erd
22924 \end_inset
22925
22926  commands, 
22927 \family typewriter
22928
22929 \backslash
22930 arabic{}
22931 \family default
22932
22933 \family typewriter
22934
22935 \backslash
22936 roman{}
22937 \family default
22938
22939 \family typewriter
22940
22941 \backslash
22942 Roman{}
22943 \family default
22944
22945 \family typewriter
22946
22947 \backslash
22948 alph{}
22949 \family default
22950 , and 
22951 \family typewriter
22952
22953 \backslash
22954 Alph{}
22955 \family default
22956 , each of which take one counter as an argument.
22957  You can add characters before or after these, but there's no need to add
22958  spaces.
22959 \end_layout
22960
22961 \begin_layout Standard
22962 You can get really fancy with these.
22963  For example:
22964 \end_layout
22965
22966 \begin_layout LyX-Code
22967
22968 \backslash
22969 renewcommand{
22970 \backslash
22971 labelenumi}{
22972 \backslash
22973 #
22974 \backslash
22975 Alph{enumi}
22976 \backslash
22977 #}
22978 \end_layout
22979
22980 \begin_layout LyX-Code
22981
22982 \backslash
22983 renewcommand{
22984 \backslash
22985 labelenumii}{
22986 \backslash
22987 Alph{enumi}.
22988 \backslash
22989 arabic{enumii}}
22990 \end_layout
22991
22992 \begin_layout LyX-Code
22993
22994 \backslash
22995 renewcommand{
22996 \backslash
22997 labelenumiii}{
22998 \backslash
22999 alph{enumiii}+}
23000 \end_layout
23001
23002 \begin_layout LyX-Code
23003
23004 \backslash
23005 renewcommand{
23006 \backslash
23007 labelenumiv}{(
23008 \backslash
23009 roman{enumiv})}
23010 \end_layout
23011
23012 \begin_layout Standard
23013 produces the somewhat out of hand numbering scheme: <
23014 \begin_inset Quotes eld
23015 \end_inset
23016
23017 #A#
23018 \begin_inset Quotes erd
23019 \end_inset
23020
23021 ,\InsetSpace ~
23022
23023 \begin_inset Quotes erd
23024 \end_inset
23025
23026 A.1
23027 \begin_inset Quotes erd
23028 \end_inset
23029
23030 ,\InsetSpace ~
23031
23032 \begin_inset Quotes erd
23033 \end_inset
23034
23035 a+
23036 \begin_inset Quotes erd
23037 \end_inset
23038
23039 ,\InsetSpace ~
23040
23041 \begin_inset Quotes eld
23042 \end_inset
23043
23044 (i)
23045 \begin_inset Quotes erd
23046 \end_inset
23047
23048 >.
23049  
23050 \end_layout
23051
23052 \begin_layout Section
23053 Extra Space Between Table Rows
23054 \end_layout
23055
23056 \begin_layout Standard
23057 by 
23058 \noun on
23059 Mike Ressler
23060 \end_layout
23061
23062 \begin_layout Standard
23063 \begin_inset VSpace bigskip
23064 \end_inset
23065
23066
23067 \end_layout
23068
23069 \begin_layout Standard
23070 \noindent
23071 LaTeX allows you to put a bit of extra space between rows in a table by
23072  giving an optional argument to the end-of-row specifier (
23073 \family typewriter
23074
23075 \backslash
23076
23077 \backslash
23078
23079 \family default
23080 ).
23081  LyX has not yet implemented this in a formal way, so here are two dirty
23082  little tricks to do the same job.
23083  
23084 \end_layout
23085
23086 \begin_layout Standard
23087 The first is the more formal, but longwinded way to do it.
23088  In the LaTeX preamble, add the following command definition: 
23089 \end_layout
23090
23091 \begin_layout Standard
23092
23093 \family typewriter
23094
23095 \backslash
23096 newcommand{
23097 \backslash
23098 extratablespace}[1]{
23099 \backslash
23100 noalign{vskip#1}}
23101 \family default
23102  This command takes a single argument---the amount of space you would like
23103  to insert.
23104  Insert the command in the first column of the row 
23105 \emph on
23106 after
23107 \emph default
23108  where you would like the space to appear.
23109  Here is an example (I've removed all the borders using 
23110 \family sans
23111 \bar under
23112 L
23113 \bar default
23114 ayout\SpecialChar \menuseparator
23115 Tabl
23116 \bar under
23117 e
23118 \family default
23119 \bar default
23120 ):
23121 \end_layout
23122
23123 \begin_layout Standard
23124 \align center
23125 \begin_inset Tabular
23126 <lyxtabular version="3" rows="4" columns="3">
23127 <features>
23128 <column alignment="center" valignment="top" width="0pt">
23129 <column alignment="center" valignment="top" width="0pt">
23130 <column alignment="center" valignment="top" width="0pt">
23131 <row>
23132 <cell alignment="center" valignment="top" topline="true" usebox="none">
23133 \begin_inset Text
23134
23135 \begin_layout Standard
23136
23137 \family roman
23138 \series medium
23139 \shape up
23140 \size normal
23141 \emph off
23142 \bar no
23143 \noun off
23144 \color none
23145 Minerals
23146 \end_layout
23147
23148 \end_inset
23149 </cell>
23150 <cell alignment="center" valignment="top" topline="true" usebox="none">
23151 \begin_inset Text
23152
23153 \begin_layout Standard
23154
23155 \family roman
23156 \series medium
23157 \shape up
23158 \size normal
23159 \emph off
23160 \bar no
23161 \noun off
23162 \color none
23163 Calcite
23164 \end_layout
23165
23166 \end_inset
23167 </cell>
23168 <cell alignment="center" valignment="top" topline="true" usebox="none">
23169 \begin_inset Text
23170
23171 \begin_layout Standard
23172
23173 \family roman
23174 \series medium
23175 \shape up
23176 \size normal
23177 \emph off
23178 \bar no
23179 \noun off
23180 \color none
23181 Dolomite
23182 \end_layout
23183
23184 \end_inset
23185 </cell>
23186 </row>
23187 <row>
23188 <cell alignment="center" valignment="top" topline="true" usebox="none">
23189 \begin_inset Text
23190
23191 \begin_layout Standard
23192
23193 \end_layout
23194
23195 \end_inset
23196 </cell>
23197 <cell alignment="center" valignment="top" topline="true" usebox="none">
23198 \begin_inset Text
23199
23200 \begin_layout Standard
23201
23202 \family roman
23203 \series medium
23204 \shape up
23205 \size normal
23206 \emph off
23207 \bar no
23208 \noun off
23209 \color none
23210 Quartz
23211 \end_layout
23212
23213 \end_inset
23214 </cell>
23215 <cell alignment="center" valignment="top" topline="true" usebox="none">
23216 \begin_inset Text
23217
23218 \begin_layout Standard
23219
23220 \family roman
23221 \series medium
23222 \shape up
23223 \size normal
23224 \emph off
23225 \bar no
23226 \noun off
23227 \color none
23228 Graphite
23229 \end_layout
23230
23231 \end_inset
23232 </cell>
23233 </row>
23234 <row>
23235 <cell alignment="center" valignment="top" topline="true" usebox="none">
23236 \begin_inset Text
23237
23238 \begin_layout Standard
23239
23240 \family roman
23241 \series medium
23242 \shape up
23243 \size normal
23244 \emph off
23245 \bar no
23246 \noun off
23247 \color none
23248 \begin_inset ERT
23249 status collapsed
23250
23251 \begin_layout Standard
23252
23253
23254 \backslash
23255 extratablespace{2ex}
23256 \end_layout
23257
23258 \end_inset
23259
23260 Rocks
23261 \end_layout
23262
23263 \end_inset
23264 </cell>
23265 <cell alignment="center" valignment="top" topline="true" usebox="none">
23266 \begin_inset Text
23267
23268 \begin_layout Standard
23269
23270 \family roman
23271 \series medium
23272 \shape up
23273 \size normal
23274 \emph off
23275 \bar no
23276 \noun off
23277 \color none
23278 Limestone
23279 \end_layout
23280
23281 \end_inset
23282 </cell>
23283 <cell alignment="center" valignment="top" topline="true" usebox="none">
23284 \begin_inset Text
23285
23286 \begin_layout Standard
23287
23288 \family roman
23289 \series medium
23290 \shape up
23291 \size normal
23292 \emph off
23293 \bar no
23294 \noun off
23295 \color none
23296 Sandstone
23297 \end_layout
23298
23299 \end_inset
23300 </cell>
23301 </row>
23302 <row>
23303 <cell alignment="center" valignment="top" topline="true" usebox="none">
23304 \begin_inset Text
23305
23306 \begin_layout Standard
23307
23308 \end_layout
23309
23310 \end_inset
23311 </cell>
23312 <cell alignment="center" valignment="top" topline="true" usebox="none">
23313 \begin_inset Text
23314
23315 \begin_layout Standard
23316
23317 \family roman
23318 \series medium
23319 \shape up
23320 \size normal
23321 \emph off
23322 \bar no
23323 \noun off
23324 \color none
23325 Granite
23326 \end_layout
23327
23328 \end_inset
23329 </cell>
23330 <cell alignment="center" valignment="top" topline="true" usebox="none">
23331 \begin_inset Text
23332
23333 \begin_layout Standard
23334
23335 \family roman
23336 \series medium
23337 \shape up
23338 \size normal
23339 \emph off
23340 \bar no
23341 \noun off
23342 \color none
23343 Andesite
23344 \end_layout
23345
23346 \end_inset
23347 </cell>
23348 </row>
23349 </lyxtabular>
23350
23351 \end_inset
23352
23353
23354 \end_layout
23355
23356 \begin_layout Standard
23357 The second method is faster, but will make typographers and TeXperts all
23358  over the world groan.
23359  Simply put an end of row specifier with optional argument at the same spot.
23360  No fancy definitions are needed as in the above example, but there will
23361  be more space inserted than you specified because you essentially added
23362  a blank row plus the extra space.
23363  If the space added is too much, simply use a negative number, like so:
23364 \end_layout
23365
23366 \begin_layout Standard
23367 \align center
23368 \begin_inset Tabular
23369 <lyxtabular version="3" rows="4" columns="3">
23370 <features>
23371 <column alignment="center" valignment="top" width="0pt">
23372 <column alignment="center" valignment="top" width="0pt">
23373 <column alignment="center" valignment="top" width="0pt">
23374 <row>
23375 <cell alignment="center" valignment="top" topline="true" usebox="none">
23376 \begin_inset Text
23377
23378 \begin_layout Standard
23379
23380 \family roman
23381 \series medium
23382 \shape up
23383 \size normal
23384 \emph off
23385 \bar no
23386 \noun off
23387 \color none
23388 Minerals
23389 \end_layout
23390
23391 \end_inset
23392 </cell>
23393 <cell alignment="center" valignment="top" topline="true" usebox="none">
23394 \begin_inset Text
23395
23396 \begin_layout Standard
23397
23398 \family roman
23399 \series medium
23400 \shape up
23401 \size normal
23402 \emph off
23403 \bar no
23404 \noun off
23405 \color none
23406 Calcite
23407 \end_layout
23408
23409 \end_inset
23410 </cell>
23411 <cell alignment="center" valignment="top" topline="true" usebox="none">
23412 \begin_inset Text
23413
23414 \begin_layout Standard
23415
23416 \family roman
23417 \series medium
23418 \shape up
23419 \size normal
23420 \emph off
23421 \bar no
23422 \noun off
23423 \color none
23424 Dolomite
23425 \end_layout
23426
23427 \end_inset
23428 </cell>
23429 </row>
23430 <row>
23431 <cell alignment="center" valignment="top" topline="true" usebox="none">
23432 \begin_inset Text
23433
23434 \begin_layout Standard
23435
23436 \end_layout
23437
23438 \end_inset
23439 </cell>
23440 <cell alignment="center" valignment="top" topline="true" usebox="none">
23441 \begin_inset Text
23442
23443 \begin_layout Standard
23444
23445 \family roman
23446 \series medium
23447 \shape up
23448 \size normal
23449 \emph off
23450 \bar no
23451 \noun off
23452 \color none
23453 Quartz
23454 \end_layout
23455
23456 \end_inset
23457 </cell>
23458 <cell alignment="center" valignment="top" topline="true" usebox="none">
23459 \begin_inset Text
23460
23461 \begin_layout Standard
23462
23463 \family roman
23464 \series medium
23465 \shape up
23466 \size normal
23467 \emph off
23468 \bar no
23469 \noun off
23470 \color none
23471 Graphite
23472 \end_layout
23473
23474 \end_inset
23475 </cell>
23476 </row>
23477 <row>
23478 <cell alignment="center" valignment="top" topline="true" usebox="none">
23479 \begin_inset Text
23480
23481 \begin_layout Standard
23482
23483 \family roman
23484 \series medium
23485 \shape up
23486 \size normal
23487 \emph off
23488 \bar no
23489 \noun off
23490 \color none
23491 \begin_inset ERT
23492 status collapsed
23493
23494 \begin_layout Standard
23495
23496
23497 \backslash
23498
23499 \backslash
23500 [-1ex]
23501 \end_layout
23502
23503 \end_inset
23504
23505  Rocks
23506 \end_layout
23507
23508 \end_inset
23509 </cell>
23510 <cell alignment="center" valignment="top" topline="true" usebox="none">
23511 \begin_inset Text
23512
23513 \begin_layout Standard
23514
23515 \family roman
23516 \series medium
23517 \shape up
23518 \size normal
23519 \emph off
23520 \bar no
23521 \noun off
23522 \color none
23523 Limestone
23524 \end_layout
23525
23526 \end_inset
23527 </cell>
23528 <cell alignment="center" valignment="top" topline="true" usebox="none">
23529 \begin_inset Text
23530
23531 \begin_layout Standard
23532
23533 \family roman
23534 \series medium
23535 \shape up
23536 \size normal
23537 \emph off
23538 \bar no
23539 \noun off
23540 \color none
23541 Sandstone
23542 \end_layout
23543
23544 \end_inset
23545 </cell>
23546 </row>
23547 <row>
23548 <cell alignment="center" valignment="top" topline="true" usebox="none">
23549 \begin_inset Text
23550
23551 \begin_layout Standard
23552
23553 \end_layout
23554
23555 \end_inset
23556 </cell>
23557 <cell alignment="center" valignment="top" topline="true" usebox="none">
23558 \begin_inset Text
23559
23560 \begin_layout Standard
23561
23562 \family roman
23563 \series medium
23564 \shape up
23565 \size normal
23566 \emph off
23567 \bar no
23568 \noun off
23569 \color none
23570 Granite
23571 \end_layout
23572
23573 \end_inset
23574 </cell>
23575 <cell alignment="center" valignment="top" topline="true" usebox="none">
23576 \begin_inset Text
23577
23578 \begin_layout Standard
23579
23580 \family roman
23581 \series medium
23582 \shape up
23583 \size normal
23584 \emph off
23585 \bar no
23586 \noun off
23587 \color none
23588 Andesite
23589 \end_layout
23590
23591 \end_inset
23592 </cell>
23593 </row>
23594 </lyxtabular>
23595
23596 \end_inset
23597
23598
23599 \end_layout
23600
23601 \begin_layout Standard
23602 It's short, sweet, and gets the job done quickly, even if it is really ugly.
23603  You may put away the rotten vegetables now! I promise I won't suggest anything
23604  else like that!
23605 \end_layout
23606
23607 \begin_layout Section
23608 Dropped Capitals
23609 \end_layout
23610
23611 \begin_layout Standard
23612 by 
23613 \noun on
23614 Mike Ressler
23615 \end_layout
23616
23617 \begin_layout Standard
23618 \begin_inset VSpace bigskip
23619 \end_inset
23620
23621
23622 \end_layout
23623
23624 \begin_layout Standard
23625 \noindent
23626 \begin_inset ERT
23627 status collapsed
23628
23629 \begin_layout Standard
23630
23631
23632 \backslash
23633 newfont{
23634 \backslash
23635 tmpfont}{cmr17 scaled 2500}{
23636 \backslash
23637 tmpfont T}
23638 \backslash
23639 vspace*{-8.4ex}
23640 \end_layout
23641
23642 \end_inset
23643
23644
23645 \end_layout
23646
23647 \begin_layout Standard
23648 \noindent
23649 \begin_inset ERT
23650 status inlined
23651
23652 \begin_layout Standard
23653
23654
23655 \backslash
23656 hangindent=3.3em 
23657 \backslash
23658 hangafter=-3
23659 \end_layout
23660
23661 \end_inset
23662
23663  hose of you who like the style of old books probably also like 
23664 \begin_inset Quotes eld
23665 \end_inset
23666
23667 dropped capitals
23668 \begin_inset Quotes erd
23669 \end_inset
23670
23671 ---those large capital letters which begin each new chapter or section.
23672  Implementing them with plain LyX/LaTeX is straightforward (assuming you
23673  know some plain TeX!) but does require a lot of work and many iterations,
23674  as you can see by all the ugly TeX-mode stuff at the beginning of this
23675  paragraph.
23676 \end_layout
23677
23678 \begin_layout Standard
23679 \begin_inset ERT
23680 status inlined
23681
23682 \begin_layout Standard
23683
23684
23685 \backslash
23686 verb+
23687 \backslash
23688 bigdrop{-1em}{3}{ptmri}{T}+
23689 \end_layout
23690
23691 \end_inset
23692
23693 here is a much easier way of doing this, of course.
23694  The 
23695 \family typewriter
23696 dropcaps
23697 \family default
23698  (or the newer 
23699 \family typewriter
23700 dropping
23701 \family default
23702 ) package from CTAN allows a simple way to add such letters to your documents.
23703  Since this package is not a standard part of teTeX, I can't demonstrate
23704  it within this document, but if you copy this paragraph to a new document,
23705  delete the 
23706 \begin_inset Quotes eld
23707 \end_inset
23708
23709
23710 \family typewriter
23711
23712 \backslash
23713 verb
23714 \family default
23715
23716 \begin_inset Quotes erd
23717 \end_inset
23718
23719  and the pluses from the TeX code at the beginning of the paragraph, and
23720  add 
23721 \family typewriter
23722
23723 \backslash
23724 usepackage{dropcaps}
23725 \family default
23726  to your LaTeX preamble, you will get a nice Times Roman Italic 
23727 \begin_inset Quotes eld
23728 \end_inset
23729
23730 T
23731 \begin_inset Quotes erd
23732 \end_inset
23733
23734 , whose height is three lines of text and which protrudes 1 em into the
23735  margin.
23736  (Make certain you have copied 
23737 \begin_inset Quotes eld
23738 \end_inset
23739
23740
23741 \family typewriter
23742 dropcaps.sty
23743 \family default
23744
23745 \begin_inset Quotes erd
23746 \end_inset
23747
23748  into a directory where TeX can see it.) The first argument is the amount
23749  of indentation; in this case the negative sign moves it into the margin.
23750  The second argument is the height of the letter in number of lines of text.
23751  The third argument is the font name: virtually anything which has a tfm
23752  file should work (wade through the 
23753 \family typewriter
23754 .../texmf/fonts/tfm
23755 \family default
23756  directory for possibilities).
23757  My personal favorite is 
23758 \begin_inset Quotes eld
23759 \end_inset
23760
23761
23762 \family typewriter
23763 yinit
23764 \family default
23765
23766 \begin_inset Quotes erd
23767 \end_inset
23768
23769 , a fancy German font specifically designed for dropped capitals.
23770  The fourth argument is the letter (or letters) to be dropped.
23771  The 
23772 \family typewriter
23773 dropping
23774 \family default
23775  package also offers the 
23776 \family typewriter
23777
23778 \backslash
23779 bigdrop
23780 \family default
23781  command, as well as a slightly simplified 
23782 \family typewriter
23783
23784 \backslash
23785 dropping
23786 \family default
23787  command.
23788 \end_layout
23789
23790 \begin_layout Section
23791 Non-standard Paragraph Shapes
23792 \end_layout
23793
23794 \begin_layout Standard
23795 by 
23796 \noun on
23797 Mike Ressler
23798 \end_layout
23799
23800 \begin_layout Standard
23801 \begin_inset VSpace bigskip
23802 \end_inset
23803
23804
23805 \end_layout
23806
23807 \begin_layout Standard
23808 \begin_inset ERT
23809 status inlined
23810
23811 \begin_layout Standard
23812
23813
23814 \backslash
23815 begin{sloppypar}
23816 \end_layout
23817
23818 \end_inset
23819
23820
23821 \end_layout
23822
23823 \begin_layout Standard
23824 \begin_inset ERT
23825 status collapsed
23826
23827 \begin_layout Standard
23828
23829
23830 \backslash
23831 newdimen
23832 \backslash
23833 varunit 
23834 \end_layout
23835
23836 \begin_layout Standard
23837
23838
23839 \backslash
23840 setlength{
23841 \backslash
23842 varunit}{4.5in}
23843 \end_layout
23844
23845 \end_inset
23846
23847
23848 \end_layout
23849
23850 \begin_layout Standard
23851 \noindent
23852 \begin_inset ERT
23853 status collapsed
23854
23855 \begin_layout Standard
23856
23857
23858 \backslash
23859 parshape 19 0.45
23860 \backslash
23861 varunit 0.332
23862 \backslash
23863 varunit
23864 \end_layout
23865
23866 \begin_layout Standard
23867
23868 0.40
23869 \backslash
23870 varunit 0.300
23871 \backslash
23872 varunit
23873 \end_layout
23874
23875 \begin_layout Standard
23876
23877 0.35
23878 \backslash
23879 varunit 0.293
23880 \backslash
23881 varunit
23882 \end_layout
23883
23884 \begin_layout Standard
23885
23886 0.30
23887 \backslash
23888 varunit 0.300
23889 \backslash
23890 varunit
23891 \end_layout
23892
23893 \begin_layout Standard
23894
23895 0.25
23896 \backslash
23897 varunit 0.317
23898 \backslash
23899 varunit
23900 \end_layout
23901
23902 \begin_layout Standard
23903
23904 0.20
23905 \backslash
23906 varunit 0.342
23907 \backslash
23908 varunit
23909 \end_layout
23910
23911 \begin_layout Standard
23912
23913 0.15
23914 \backslash
23915 varunit 0.373
23916 \backslash
23917 varunit
23918 \end_layout
23919
23920 \begin_layout Standard
23921
23922 0.10
23923 \backslash
23924 varunit 0.410
23925 \backslash
23926 varunit
23927 \end_layout
23928
23929 \begin_layout Standard
23930
23931 0.05
23932 \backslash
23933 varunit 0.453
23934 \backslash
23935 varunit
23936 \end_layout
23937
23938 \begin_layout Standard
23939
23940 0.00
23941 \backslash
23942 varunit 0.500
23943 \backslash
23944 varunit
23945 \end_layout
23946
23947 \begin_layout Standard
23948
23949 0.05
23950 \backslash
23951 varunit 0.453
23952 \backslash
23953 varunit
23954 \end_layout
23955
23956 \begin_layout Standard
23957
23958 0.10
23959 \backslash
23960 varunit 0.410
23961 \backslash
23962 varunit
23963 \end_layout
23964
23965 \begin_layout Standard
23966
23967 0.15
23968 \backslash
23969 varunit 0.373
23970 \backslash
23971 varunit
23972 \end_layout
23973
23974 \begin_layout Standard
23975
23976 0.20
23977 \backslash
23978 varunit 0.342
23979 \backslash
23980 varunit
23981 \end_layout
23982
23983 \begin_layout Standard
23984
23985 0.25
23986 \backslash
23987 varunit 0.317
23988 \backslash
23989 varunit
23990 \end_layout
23991
23992 \begin_layout Standard
23993
23994 0.30
23995 \backslash
23996 varunit 0.300
23997 \backslash
23998 varunit
23999 \end_layout
24000
24001 \begin_layout Standard
24002
24003 0.35
24004 \backslash
24005 varunit 0.293
24006 \backslash
24007 varunit
24008 \end_layout
24009
24010 \begin_layout Standard
24011
24012 0.40
24013 \backslash
24014 varunit 0.300
24015 \backslash
24016 varunit
24017 \end_layout
24018
24019 \begin_layout Standard
24020
24021 0.45
24022 \backslash
24023 varunit 0.332
24024 \backslash
24025 varunit
24026 \end_layout
24027
24028 \begin_layout Standard
24029
24030 \end_layout
24031
24032 \end_inset
24033
24034 There are times when the tyranny of rectangular paragraphs must be overthrown.
24035  In such situations, a call to the delightful plain TeX command 
24036 \family typewriter
24037
24038 \backslash
24039 parshape
24040 \family default
24041  is called for.
24042  As you can see, completely arbitrary shapes can be laid out with a suitable
24043  set of linelength definitions.
24044  While this parshape may look a bit silly and useless, one could conceive
24045  of situations such as finely tuned dropped capitals, word wrapping around
24046  non-rectangular graphics, etc.\InsetSpace \space{}
24047 which will benefit from such handcrafting.
24048 \end_layout
24049
24050 \begin_layout Standard
24051 \begin_inset VSpace bigskip
24052 \end_inset
24053
24054
24055 \end_layout
24056
24057 \begin_layout Standard
24058 The syntax is 
24059 \family typewriter
24060
24061 \backslash
24062 parshape numlines #1indent #1length #2indent #2length \SpecialChar \ldots{}
24063  #nindent #nlength
24064 \family default
24065 , where 
24066 \family typewriter
24067 numlines
24068 \family default
24069  is the number of lines of text which define the paragraph.
24070  If there turn out to be fewer lines, the shape is truncated; if there are
24071  more, the excess lines have the same dimensions as the last line of the
24072  definition.
24073  The 
24074 \family typewriter
24075 #nindent
24076 \family default
24077  and 
24078 \family typewriter
24079 #nlength
24080 \family default
24081  entries specify the indentation of the line from the left margin, and the
24082  length of the line as measured from that point.
24083  The shape applies only to the current paragraph; everything is reset to
24084  normal for the next paragraph.
24085 \end_layout
24086
24087 \begin_layout Standard
24088 \begin_inset ERT
24089 status inlined
24090
24091 \begin_layout Standard
24092
24093
24094 \backslash
24095 end{sloppypar}
24096 \end_layout
24097
24098 \end_inset
24099
24100
24101 \end_layout
24102
24103 \begin_layout Section
24104 Summary
24105 \end_layout
24106
24107 \begin_layout Standard
24108 As you can see, the examples in this section range from the useful to the
24109  whimsical.
24110  While I don't expect that anyone will ever need the paragraph shape demonstrate
24111 d in the last section, the important point is that you can do almost anything
24112  you want in LyX if you are willing to figure out how to do it in TeX and
24113  LaTeX.
24114  TeX is a fantastically powerful typesetting system and all that power is
24115  available to you since LyX uses it as its backend.
24116  Happy LyXing!
24117 \end_layout
24118
24119 \end_body
24120 \end_document