]> git.lyx.org Git - lyx.git/blob - lib/doc/Extended.lyx
* doc/cs_Tutorial.lyx: update by Pavel Sanda
[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 collapsable (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  Preferrably, 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 an 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 ), then make the following changes to the resulting 
8032 \family typewriter
8033 .tex
8034 \family default
8035  file.
8036 \end_layout
8037
8038 \begin_layout Enumerate
8039 Remove the comment lines before the 
8040 \family typewriter
8041
8042 \backslash
8043 documentclass
8044 \family default
8045  command.
8046 \end_layout
8047
8048 \begin_layout Enumerate
8049 Remove everything between (and including) the 
8050 \family typewriter
8051
8052 \backslash
8053 makeatletter
8054 \family default
8055  and 
8056 \family typewriter
8057
8058 \backslash
8059 makeatother
8060 \family default
8061  commands, except for any commands you specifically put into the LaTeX preamble.
8062 \end_layout
8063
8064 \begin_layout Standard
8065 The modified 
8066 \family typewriter
8067 .tex
8068 \family default
8069  file should be saved and processed through LaTeX as many times as necessary.
8070  You may also want to check the resulting 
8071 \family typewriter
8072 .dvi
8073 \family default
8074  document.
8075 \end_layout
8076
8077 \begin_layout Subsection
8078 Use of ERT
8079 \end_layout
8080
8081 \begin_layout Standard
8082 The use of ERT is reduced to two commands, which must be placed at the top
8083  of the document.
8084  If you started writing your paper by using the 
8085 \family typewriter
8086 ijmpc.lyx
8087 \family default
8088  or the 
8089 \family typewriter
8090 ijmpd.lyx
8091 \family default
8092  template, the ERT needed is already in its place; you usually don't need
8093  to delete it.
8094  You may only modify the first ERT to specify the information printed to
8095  the top of odd and even pages (authors' names and short paper's title,
8096  respectively).
8097  This ERT must have the form 
8098 \family typewriter
8099
8100 \backslash
8101 markboth{Authors' Names}{Short Paper's Title}
8102 \family default
8103 .
8104 \end_layout
8105
8106 \begin_layout Section
8107 Kluwer
8108 \end_layout
8109
8110 \begin_layout Standard
8111 by 
8112 \noun on
8113 Panayotis Papasotiriou
8114 \end_layout
8115
8116 \begin_layout Subsection
8117 Overview
8118 \end_layout
8119
8120 \begin_layout Standard
8121 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
8122  that facilitates electronic manuscript submission to the journals they
8123  publish.
8124  Most known of them (at least in my domain of interest) are 
8125 \emph on
8126 Astrophysics and Space Science
8127 \emph default
8128  and 
8129 \emph on
8130 Solar Physics
8131 \emph default
8132 , but there are many others (see a complete list at 
8133 \begin_inset LatexCommand \url{http://www.wkap.nl/jrnllist.htm/JRNLHOME}
8134
8135 \end_inset
8136
8137 ).
8138  The Kluwer package may be downloaded from the site 
8139 \begin_inset LatexCommand \url{http://www.wkap.nl/kaphtml.htm/STYLEFILES}
8140
8141 \end_inset
8142
8143 .
8144  A complete user guide is contained in that package (but it can also be
8145  downloaded separately).
8146 \end_layout
8147
8148 \begin_layout Standard
8149 LyX supports many features of the package but not everything.
8150  However, the ERT needed is reduced to some 
8151 \begin_inset Quotes eld
8152 \end_inset
8153
8154 peculiar
8155 \begin_inset Quotes erd
8156 \end_inset
8157
8158  commands of the package (see\InsetSpace ~
8159
8160 \begin_inset LatexCommand \ref{subsec:kluwer_peculiarities}
8161
8162 \end_inset
8163
8164 ).
8165  I have recently used LyX to write an article submitted to the 
8166 \emph on
8167 Astrophysics and Space Science
8168 \emph default
8169  without any problem.
8170 \end_layout
8171
8172 \begin_layout Subsection
8173 Writing a paper
8174 \end_layout
8175
8176 \begin_layout Standard
8177 The easiest way to write a paper is to start with the Kluwer template file.
8178  Click on 
8179 \family sans
8180 File\SpecialChar \menuseparator
8181 New from 
8182 \bar under
8183 T
8184 \bar default
8185 emplate
8186 \family default
8187 , then choose the 
8188 \family typewriter
8189 kluwer.lyx
8190 \family default
8191  template.
8192  This will give an (almost) empty document that includes the most common
8193  fields found in a manuscript and a short description of their use.
8194  As in most templates, simply overwrite the existing text (including the
8195  brackets, 
8196 \family typewriter
8197 <>
8198 \family default
8199 ) with the correct information.
8200 \end_layout
8201
8202 \begin_layout Subsection
8203 Preparing a paper for submission
8204 \end_layout
8205
8206 \begin_layout Standard
8207 As in the AASTeX package, before you submit your paper to a journal you
8208  must 
8209 \begin_inset Quotes eld
8210 \end_inset
8211
8212 postprocess
8213 \begin_inset Quotes erd
8214 \end_inset
8215
8216  it as follows.
8217 \end_layout
8218
8219 \begin_layout Enumerate
8220 Export your paper as a LaTeX file.
8221  To do this, click on 
8222 \family sans
8223 \bar under
8224 F
8225 \bar default
8226 ile\SpecialChar \menuseparator
8227
8228 \bar under
8229 E
8230 \bar default
8231 xport\SpecialChar \menuseparator
8232
8233 \bar under
8234 L
8235 \bar default
8236 ateX
8237 \family default
8238 .
8239  
8240 \end_layout
8241
8242 \begin_layout Enumerate
8243 Edit the resulting 
8244 \family typewriter
8245 .tex
8246 \family default
8247  file with a text editor and make the following changes
8248 \end_layout
8249
8250 \begin_deeper
8251 \begin_layout Enumerate
8252 remove the comment lines before the 
8253 \family typewriter
8254
8255 \backslash
8256 documentclass
8257 \family default
8258  command,
8259 \end_layout
8260
8261 \begin_layout Enumerate
8262 remove everything between (and including) the 
8263 \family typewriter
8264
8265 \backslash
8266 makeatletter
8267 \family default
8268  and 
8269 \family typewriter
8270
8271 \backslash
8272 makeatother
8273 \family default
8274  commands, except for any commands you specifically put into the LaTeX preamble.
8275 \end_layout
8276
8277 \begin_layout Standard
8278 Save the resulting 
8279 \family typewriter
8280 .tex
8281 \family default
8282  file.
8283 \end_layout
8284
8285 \end_deeper
8286 \begin_layout Enumerate
8287 Run the 
8288 \family typewriter
8289 .tex
8290 \family default
8291  file through LaTeX as many times as necessary (usually up to three).
8292 \end_layout
8293
8294 \begin_layout Enumerate
8295 View the resulting 
8296 \family typewriter
8297 .dvi
8298 \family default
8299  document using, e.g., 
8300 \family sans
8301 xdvi
8302 \family default
8303 , and check if everything is ok (it should, if you didn't make any mistake).
8304 \end_layout
8305
8306 \begin_layout Subsection
8307 \begin_inset Quotes eld
8308 \end_inset
8309
8310 Peculiarities
8311 \begin_inset Quotes erd
8312 \end_inset
8313
8314  of the Kluwer package
8315 \begin_inset LatexCommand \label{subsec:kluwer_peculiarities}
8316
8317 \end_inset
8318
8319
8320 \end_layout
8321
8322 \begin_layout Standard
8323 The Kluwer package has the following 
8324 \begin_inset Quotes eld
8325 \end_inset
8326
8327 peculiarities
8328 \begin_inset Quotes erd
8329 \end_inset
8330
8331 .
8332 \end_layout
8333
8334 \begin_layout Enumerate
8335 It is possible to write multiple articles in the same LaTeX file
8336 \begin_inset Foot
8337 status collapsed
8338
8339 \begin_layout Standard
8340 I can't imagine any good reason to do this.
8341 \end_layout
8342
8343 \end_inset
8344
8345 .
8346  Each article must be included in the environment 
8347 \begin_inset Quotes eld
8348 \end_inset
8349
8350 article
8351 \begin_inset Quotes erd
8352 \end_inset
8353
8354 .
8355  Unfortunately, this environment cannot be omitted, even if you write just
8356  one article.
8357  Therefore, each article starts with the command 
8358 \family typewriter
8359
8360 \backslash
8361 begin{article}
8362 \family default
8363  and, obviously, ends with the command 
8364 \family typewriter
8365
8366 \backslash
8367 end{article}
8368 \family default
8369 .
8370  Although this can be implemented in LyX, I didn't included it, since it
8371  looks ugly and can confuse the novice user.
8372  Therefore, you need to enter them directly and mark them as LaTeX code
8373  (the well-known 
8374 \begin_inset Quotes eld
8375 \end_inset
8376
8377 ERT
8378 \begin_inset Quotes erd
8379 \end_inset
8380
8381 ).
8382 \end_layout
8383
8384 \begin_layout Enumerate
8385 Information given at the beginning of the article (i.e., title, subtitle,
8386  author, institution, running title, running author, abstract and keywords)
8387  must be included in an environment called 
8388 \begin_inset Quotes eld
8389 \end_inset
8390
8391 opening
8392 \begin_inset Quotes erd
8393 \end_inset
8394
8395 .
8396  This is not implemented in LyX, so you must enter title, subtitle etc.
8397  between two ERT lines (
8398 \family typewriter
8399
8400 \backslash
8401 begin{opening}
8402 \family default
8403  and 
8404 \family typewriter
8405
8406 \backslash
8407 end{opening}
8408 \family default
8409 ).
8410 \end_layout
8411
8412 \begin_layout Enumerate
8413 According to the user manual, the label of each bibliography item must be
8414  written as 
8415 \family typewriter
8416
8417 \backslash
8418 protect
8419 \backslash
8420 citeauthoryear{
8421 \family default
8422 \emph on
8423 author(s)
8424 \family typewriter
8425 \emph default
8426 }{
8427 \family default
8428 \emph on
8429 year
8430 \family typewriter
8431 \emph default
8432 }
8433 \family default
8434 .
8435 \end_layout
8436
8437 \begin_layout Standard
8438 The 
8439 \family typewriter
8440 kluwer.lyx
8441 \family default
8442  template takes care of all these 
8443 \begin_inset Quotes eld
8444 \end_inset
8445
8446 peculiarities
8447 \begin_inset Quotes erd
8448 \end_inset
8449
8450 .
8451  If you start a new paper using this template you don't need to do anything
8452  special.
8453  Just 
8454 \end_layout
8455
8456 \begin_layout Enumerate
8457 don't delete the ERT included in the template, and
8458 \end_layout
8459
8460 \begin_layout Enumerate
8461 copy the example bibliography item included in the template and modify it
8462  as necessary to enter new bibliography items.
8463 \end_layout
8464
8465 \begin_layout Section
8466 Koma-Script
8467 \end_layout
8468
8469 \begin_layout Standard
8470 by 
8471 \noun on
8472 Bernd Rellermeyer
8473 \end_layout
8474
8475 \begin_layout Subsection
8476 Overview
8477 \end_layout
8478
8479 \begin_layout Standard
8480 The LyX document classes
8481 \emph on
8482  article (koma-script)
8483 \emph default
8484
8485 \emph on
8486 report (koma-script)
8487 \emph default
8488
8489 \emph on
8490 book
8491 \emph default
8492  
8493 \emph on
8494 (koma-script)
8495 \emph default
8496 , and 
8497 \emph on
8498 letter
8499 \emph default
8500  
8501 \emph on
8502 (koma-script)
8503 \emph default
8504  correspond to the LaTeX document classes 
8505 \family typewriter
8506 scrartcl.cls
8507 \family default
8508
8509 \family typewriter
8510 scrreprt.cls
8511 \family default
8512
8513 \family typewriter
8514 scrbook.cls
8515 \family default
8516 , and 
8517 \family typewriter
8518 scrlettr.cls
8519 \family default
8520 , resp.
8521  of the Koma-Script family.
8522  They are replacements for the standard document classes 
8523 \family typewriter
8524 article.cls
8525 \family default
8526
8527 \family typewriter
8528 report.cls
8529 \family default
8530
8531 \family typewriter
8532 book.cls
8533 \family default
8534  and 
8535 \family typewriter
8536 letter.cls
8537 \family default
8538 , resp., and fit better to European typography conventions in a number of
8539  points.
8540 \end_layout
8541
8542 \begin_layout Itemize
8543 Standard character size is 11pt in 
8544 \emph on
8545 article (koma-script)
8546 \emph default
8547
8548 \emph on
8549 report (koma-script)
8550 \emph default
8551 , and 
8552 \emph on
8553 book (koma-script)
8554 \emph default
8555 , and 12pt in 
8556 \emph on
8557 letter (koma-script)
8558 \emph default
8559 .
8560 \end_layout
8561
8562 \begin_layout Itemize
8563 Headings, labels of the description environment, and a number of elements
8564  of the 
8565 \emph on
8566 letter (koma-script) 
8567 \emph default
8568 document class are set in a bold sans serif font.
8569 \begin_inset Foot
8570 status collapsed
8571
8572 \begin_layout Standard
8573 There is a big difference between the bold sans serif old cm fonts and new
8574  ec fonts, especially in the appearance of headings.
8575  In comparison, the ec bold sans serif fonts look a bit thin.
8576  Here the LaTeX package 
8577 \family typewriter
8578 cmsd.sty by 
8579 \family default
8580 \shape smallcaps
8581 Walter Schmidt
8582 \shape default
8583  helps to produce the 
8584 \begin_inset Quotes eld
8585 \end_inset
8586
8587 usual
8588 \begin_inset Quotes erd
8589 \end_inset
8590
8591  appearance when using the ec fonts.
8592 \end_layout
8593
8594 \end_inset
8595
8596  The numbering of chapter headings is made in the same way as the numbering
8597  of section headings, that is without the extra line 
8598 \begin_inset Quotes eld
8599 \end_inset
8600
8601 Chapter\SpecialChar \ldots{}
8602
8603 \begin_inset Quotes erd
8604 \end_inset
8605
8606 .
8607  In addition, the appearance of the headings can be modified by using a
8608  number of options (in LyX to be entered in the field 
8609 \family sans
8610 E
8611 \bar under
8612 x
8613 \bar default
8614 tra\InsetSpace ~
8615 Options
8616 \family default
8617  of the dialog 
8618 \family sans
8619 \bar under
8620 L
8621 \bar default
8622 ayout\SpecialChar \menuseparator
8623
8624 \bar under
8625 D
8626 \bar default
8627 ocument
8628 \family default
8629 ).
8630  A detailed German description of these options can be found in the Koma-Script
8631  documentation 
8632 \emph on
8633 scrguide
8634 \emph default
8635 .
8636 \end_layout
8637
8638 \begin_layout Itemize
8639 The main means in the Koma-Script document classes to design the type area
8640  are the options 
8641 \family sans
8642 BCOR
8643 \family default
8644  and 
8645 \family sans
8646 DIV
8647 \family default
8648  (in LyX to be entered in the extra class options field in the dialog 
8649 \family sans
8650 \bar under
8651 D
8652 \bar default
8653 ocument\SpecialChar \menuseparator
8654
8655 \bar under
8656 S
8657 \bar default
8658 ettings
8659 \family default
8660 ).
8661  They make a clearer modification of page margins possible as do the options
8662  of 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  A detailed German description of these and other type area options can
8676  be found in the Koma-Script documentation 
8677 \emph on
8678 scrguide
8679 \emph default
8680 .
8681 \end_layout
8682
8683 \begin_layout Itemize
8684 The LaTeX document classes of the Koma-Script family define a number of
8685  additional commands.
8686  Those part of it which makes sense in LyX is implemented in corresponding
8687  paragraph types.
8688 \end_layout
8689
8690 \begin_layout Standard
8691 A detailed German description of the LaTeX document classes of the Koma-Script
8692  family can be found in the Koma-Script documentation 
8693 \emph on
8694 scrguide
8695 \emph default
8696 .
8697 \begin_inset Foot
8698 status collapsed
8699
8700 \begin_layout Standard
8701 There is an English translation 
8702 \emph on
8703 screnggu
8704 \emph default
8705 , but it is not a complete one.
8706 \end_layout
8707
8708 \end_inset
8709
8710  The following sections describe only those aspects, which are relevant
8711  in LyX.
8712 \end_layout
8713
8714 \begin_layout Subsection
8715 article (koma-script), report (koma-script), and book (koma-script)
8716 \end_layout
8717
8718 \begin_layout Standard
8719 The document classes 
8720 \emph on
8721 article (koma-script)
8722 \emph default
8723
8724 \emph on
8725 report (koma-script)
8726 \emph default
8727 , and 
8728 \emph on
8729 book
8730 \emph default
8731  
8732 \emph on
8733 (koma-script)
8734 \emph default
8735  are implemented in the layout files 
8736 \family typewriter
8737 scrartcl.layout
8738 \family default
8739
8740 \family typewriter
8741 scrreprt.layout
8742 \family default
8743 , and 
8744 \family typewriter
8745 scrbook.layout
8746 \family default
8747 , resp.
8748  They contain all the paragraph types of the corresponding standard document
8749  classes 
8750 \emph on
8751 article
8752 \emph default
8753
8754 \emph on
8755 report
8756 \emph default
8757 , and 
8758 \emph on
8759 book
8760 \emph default
8761 , resp., partly modified, with the exception of the LyX specific 
8762 \family sans
8763 List
8764 \family default
8765 -type, which is replaced by the new 
8766 \family sans
8767 Labeling
8768 \family default
8769 -type having the same functionality.
8770  Beside the 
8771 \family sans
8772 Labeling
8773 \family default
8774 -Type there is a number of new paragraph types added.
8775  They are 
8776 \emph on
8777 not
8778 \emph default
8779  part of 
8780 \emph on
8781 letter (koma-script)
8782 \emph default
8783 .
8784 \end_layout
8785
8786 \begin_layout Itemize
8787
8788 \family sans
8789 Addpart, Addchap
8790 \family default
8791
8792 \family sans
8793 Addsec
8794 \family default
8795 : are equivalents to 
8796 \family sans
8797 Part*, Chapter*
8798 \family default
8799  and 
8800 \family sans
8801 Section*
8802 \family default
8803 , resp., additionally inserting an entry in the table of contents.
8804  
8805 \family sans
8806 Addpart 
8807 \family default
8808 and
8809 \family sans
8810  Addchap
8811 \family default
8812  are not contained in 
8813 \emph on
8814 article (koma-script)
8815 \emph default
8816 .
8817 \end_layout
8818
8819 \begin_layout Itemize
8820
8821 \family sans
8822 Addchap*
8823 \family default
8824
8825 \family sans
8826 Addsec*
8827 \family default
8828 : behave exactly as 
8829 \family sans
8830 Addchap
8831 \family default
8832  and 
8833 \family sans
8834 Addsec
8835 \family default
8836 , resp., additionally clearing running heads.
8837
8838 \family sans
8839  Addchap*
8840 \family default
8841  is not contained in 
8842 \emph on
8843 article (koma-script)
8844 \emph default
8845 .
8846 \begin_inset Foot
8847 status collapsed
8848
8849 \begin_layout Standard
8850 There is also an 
8851 \family typewriter
8852
8853 \backslash
8854 addpart*
8855 \family default
8856  command in 
8857 \emph on
8858 book (koma-script)
8859 \emph default
8860  and in 
8861 \emph on
8862 report (koma-script)
8863 \emph default
8864 , but since this is identical to 
8865 \family sans
8866 Part*
8867 \family default
8868 , is has not been implemented in LyX.
8869 \end_layout
8870
8871 \end_inset
8872
8873
8874 \end_layout
8875
8876 \begin_layout Itemize
8877
8878 \family sans
8879 Minisec
8880 \family default
8881 : generates a heading directly above the following paragraph in the standard
8882  character size without affecting the structure of the document.
8883 \end_layout
8884
8885 \begin_layout Itemize
8886
8887 \family sans
8888 Captionabove
8889 \family default
8890  and 
8891 \family sans
8892 Captionbelow 
8893 \family default
8894 are special captions which respect the different space settings needed for
8895  captions placed above or below an element (if you follow strict typographic
8896  rules, you might want to place table captions always above the table).
8897  You can also use the class option 
8898 \family typewriter
8899 tablecaptionsabove
8900 \family default
8901 , which will switch 
8902 \family sans
8903 caption
8904 \family default
8905  to 
8906 \family sans
8907 captionabove
8908 \family default
8909  for tables and 
8910 \family sans
8911 captionbelow
8912 \family default
8913  for figures.
8914  You need at least Koma-Script version 2.8q to use this.
8915 \end_layout
8916
8917 \begin_layout Itemize
8918
8919 \family sans
8920 Dictum
8921 \family default
8922 : can be used to set a bonmot, e.
8923 \begin_inset ERT
8924 status collapsed
8925
8926 \begin_layout Standard
8927
8928
8929 \backslash
8930 ,
8931 \end_layout
8932
8933 \end_inset
8934
8935 g.
8936 \begin_inset ERT
8937 status collapsed
8938
8939 \begin_layout Standard
8940
8941
8942 \backslash
8943  
8944 \end_layout
8945
8946 \end_inset
8947
8948 at the beginning of a chapter.
8949  If you use the optional argument (
8950 \family sans
8951 \bar under
8952 I
8953 \bar default
8954 nsert\SpecialChar \menuseparator
8955 Short\InsetSpace ~
8956 Title
8957 \family default
8958 ), you can insert the dictum's author there.
8959  Dictum and author are separated by a line.
8960  You need at least Koma-Script version 2.8q to use this.
8961  
8962 \family sans
8963 Dictum
8964 \family default
8965  is not contained in 
8966 \emph on
8967 article (koma-script)
8968 \emph default
8969 .
8970 \end_layout
8971
8972 \begin_layout Standard
8973 The following types, together with the standard types 
8974 \family sans
8975 Title
8976 \family default
8977
8978 \family sans
8979 Author
8980 \family default
8981 , and 
8982 \family sans
8983 Date
8984 \family default
8985 , form the title area of the document.
8986  They must be entered ahead of the first 
8987 \begin_inset Quotes eld
8988 \end_inset
8989
8990 ordinary
8991 \begin_inset Quotes erd
8992 \end_inset
8993
8994  paragraph.
8995 \begin_inset Foot
8996 status collapsed
8997
8998 \begin_layout Standard
8999 The corresponding LaTeX commands must appear before the 
9000 \family typewriter
9001
9002 \backslash
9003 maketitle
9004 \family default
9005  command.
9006 \end_layout
9007
9008 \end_inset
9009
9010  When such a type is used more than once, the latter usage overwrites the
9011  former one, that means, for every type only the latest usage is valid.
9012  The order of the different types however has, like 
9013 \family sans
9014 Title
9015 \family default
9016
9017 \family sans
9018 Author
9019 \family default
9020 , and 
9021 \family sans
9022 Date
9023 \family default
9024 , no effect on the appearance of the produced document.
9025 \end_layout
9026
9027 \begin_layout Itemize
9028
9029 \family sans
9030 Subject
9031 \family default
9032 : produces a centered paragraph above the ordinary title (
9033 \family sans
9034 Title
9035 \family default
9036
9037 \family sans
9038 Author
9039 \family default
9040
9041 \family sans
9042 Date
9043 \family default
9044 ) for the subject of the document.
9045 \end_layout
9046
9047 \begin_layout Itemize
9048
9049 \family sans
9050 Publishers
9051 \family default
9052 : produces a centered paragraph below the ordinary title (
9053 \family sans
9054 Title
9055 \family default
9056
9057 \family sans
9058 Author
9059 \family default
9060
9061 \family sans
9062 Date
9063 \family default
9064 ) for the publishers' name.
9065 \end_layout
9066
9067 \begin_layout Itemize
9068
9069 \family sans
9070 Dedication
9071 \family default
9072 : in 
9073 \emph on
9074 report (koma-script)
9075 \emph default
9076  and 
9077 \emph on
9078 book (koma-script)
9079 \emph default
9080  produces a centered paragraph on its own page behind the title page, or
9081  in 
9082 \emph on
9083 article (koma-script)
9084 \emph default
9085  produces a centered paragraph below the ordinary title (
9086 \family sans
9087 Title
9088 \family default
9089
9090 \family sans
9091 Author
9092 \family default
9093
9094 \family sans
9095 Date
9096 \family default
9097
9098 \family sans
9099 Publishers
9100 \family default
9101 ) for a dedication.
9102 \end_layout
9103
9104 \begin_layout Itemize
9105
9106 \family sans
9107 Titlehead
9108 \family default
9109 : produces a left aligned paragraph above the ordinary title (
9110 \family sans
9111 Title
9112 \family default
9113
9114 \family sans
9115 Author
9116 \family default
9117
9118 \family sans
9119 Date
9120 \family default
9121
9122 \family sans
9123 Subject
9124 \family default
9125 ) for a document`s head.
9126 \end_layout
9127
9128 \begin_layout Itemize
9129
9130 \family sans
9131 Uppertitleback
9132 \family default
9133 : produces in a double-sided print in 
9134 \emph on
9135 report (koma-script)
9136 \emph default
9137  and 
9138 \emph on
9139 book (koma-script)
9140 \emph default
9141  a left-aligned paragraph at the top of the title page`s back or has no
9142  effect in a single-sided print or in 
9143 \emph on
9144 article (koma-script)
9145 \emph default
9146 .
9147 \end_layout
9148
9149 \begin_layout Itemize
9150
9151 \family sans
9152 Lowertitleback
9153 \family default
9154 : produces in a double-sided print in 
9155 \emph on
9156 report (koma-script)
9157 \emph default
9158  and 
9159 \emph on
9160 book (koma-script)
9161 \emph default
9162  a left-aligned paragraph at the bottom of the title page`s back or has
9163  no effect in a single-sided print or in 
9164 \emph on
9165 article (koma-script)
9166 \emph default
9167 .
9168 \end_layout
9169
9170 \begin_layout Itemize
9171
9172 \family sans
9173 Extratitle
9174 \family default
9175 : produces a special 
9176 \begin_inset Quotes eld
9177 \end_inset
9178
9179 dirty
9180 \begin_inset Quotes erd
9181 \end_inset
9182
9183  page ahead of the actual document containing a paragraph without special
9184  formatting.
9185 \end_layout
9186
9187 \begin_layout Standard
9188 The layout files for the document classes 
9189 \emph on
9190 article (koma-script)
9191 \emph default
9192
9193 \emph on
9194 report (koma-script)
9195 \emph default
9196 , and 
9197 \emph on
9198 book (koma-script)
9199 \emph default
9200  do include the file 
9201 \family typewriter
9202 scrmacros.inc
9203 \family default
9204 .
9205  This is thought of as a place to define your own types.
9206  Copy s
9207 \family typewriter
9208 crmacros.inc
9209 \family default
9210  in your personal layout directory and edit the file!
9211 \end_layout
9212
9213 \begin_layout Subsection
9214 letter (koma-script)
9215 \end_layout
9216
9217 \begin_layout Standard
9218 \begin_inset ERT
9219 status inlined
9220
9221 \begin_layout Standard
9222
9223
9224 \backslash
9225 begin{sloppypar}
9226 \end_layout
9227
9228 \end_inset
9229
9230
9231 \end_layout
9232
9233 \begin_layout Standard
9234 \noindent
9235 The document class 
9236 \emph on
9237 letter (koma-script)
9238 \emph default
9239  is implemented in the layout file 
9240 \family typewriter
9241 scrlettr.layout
9242 \family default
9243 .
9244  It contains all the paragraph types of the corresponding standard document
9245  class 
9246 \emph on
9247 letter
9248 \emph default
9249 , partly modified, with the exception of the LyX specific types 
9250 \family sans
9251 LyX-Code
9252 \family default
9253  and 
9254 \family sans
9255 Comment
9256 \family default
9257  and the 
9258 \family sans
9259 List
9260 \family default
9261  type, which is replaced by the new 
9262 \family sans
9263 Labeling
9264 \family default
9265  type.
9266  In addition, it contains, in contrast to the standard document class, the
9267  standard types 
9268 \family sans
9269 LaTeX
9270 \family default
9271
9272 \family sans
9273 Quotation
9274 \family default
9275
9276 \family sans
9277 Quote
9278 \family default
9279 , and 
9280 \family sans
9281 Verse
9282 \family default
9283 .
9284  Furthermore, there are a number of new letter specific types.
9285 \end_layout
9286
9287 \begin_layout Standard
9288 \begin_inset ERT
9289 status inlined
9290
9291 \begin_layout Standard
9292
9293
9294 \backslash
9295 end{sloppypar}
9296 \end_layout
9297
9298 \end_inset
9299
9300
9301 \end_layout
9302
9303 \begin_layout Standard
9304 The appearance of the letter produced by this document class can be controlled
9305  by a number of LaTeX commands, which you can put in the LaTeX preamble.
9306 \begin_inset Foot
9307 status collapsed
9308
9309 \begin_layout Standard
9310 For example, the standard appearance of the letter`s heading, consisting
9311  of name and address, is quite self-willed.
9312  An 
9313 \begin_inset Quotes eld
9314 \end_inset
9315
9316 ordinary
9317 \begin_inset Quotes erd
9318 \end_inset
9319
9320  heading is produced by the following LaTeX commands in the preamble:
9321 \end_layout
9322
9323 \begin_layout LyX-Code
9324
9325 \backslash
9326 firsthead{
9327 \backslash
9328 parbox[b]{
9329 \backslash
9330 textwidth}
9331 \end_layout
9332
9333 \begin_layout LyX-Code
9334   {
9335 \backslash
9336 ignorespaces 
9337 \backslash
9338 fromname
9339 \backslash
9340
9341 \backslash
9342  
9343 \backslash
9344 ignorespaces 
9345 \backslash
9346 fromaddress}} 
9347 \end_layout
9348
9349 \begin_layout LyX-Code
9350
9351 \backslash
9352 nexthead{
9353 \backslash
9354 parbox[b]{
9355 \backslash
9356 textwidth}
9357 \end_layout
9358
9359 \begin_layout LyX-Code
9360   {
9361 \backslash
9362 ignorespaces 
9363 \backslash
9364 fromname 
9365 \backslash
9366 hfill 
9367 \backslash
9368 ignorespaces 
9369 \backslash
9370 pagename
9371 \backslash
9372  
9373 \backslash
9374 thepage}}
9375 \end_layout
9376
9377 \end_inset
9378
9379  A detailed German description of such LaTeX commands can be found in the
9380  Koma-Script documentation 
9381 \emph on
9382 scrguide
9383 \emph default
9384 .
9385  With it, the letter's author can produce his personal letter layout.
9386 \end_layout
9387
9388 \begin_layout Standard
9389 The types 
9390 \family sans
9391 Letter 
9392 \family default
9393 and 
9394 \family sans
9395 Opening
9396 \family default
9397  define the beginning of the letter and must be used in every letter.
9398  To emphasize them in the LyX document class, they are marked with the letter
9399  
9400 \shape italic
9401 L
9402 \shape default
9403  or 
9404 \shape italic
9405 O
9406 \shape default
9407 , resp.
9408  in the left margin.
9409  It is possible to write any number of letters in one file.
9410  An 
9411 \family sans
9412 Opening
9413 \family default
9414  type produces a new letter using the same addressee and a 
9415 \family sans
9416 Letter
9417 \family default
9418  type produces a new addressee.
9419  The types 
9420 \family sans
9421 Closing
9422 \family default
9423
9424 \family sans
9425 PS
9426 \family default
9427
9428 \family sans
9429 CC
9430 \family default
9431 , and 
9432 \family sans
9433 Encl
9434 \family default
9435  are ordinary paragraph types and can also be used several times in one
9436  and the same letter.
9437 \end_layout
9438
9439 \begin_layout Itemize
9440
9441 \family sans
9442 Letter
9443 \family default
9444 : produces a paragraph for the addressee and implicitly defines the beginning
9445  of the letter.
9446 \end_layout
9447
9448 \begin_layout Itemize
9449
9450 \family sans
9451 Opening
9452 \family default
9453 : produces a paragraph for the form of address and implicitly produces a
9454  new letter.
9455 \end_layout
9456
9457 \begin_layout Itemize
9458
9459 \family sans
9460 Closing
9461 \family default
9462 : produces a paragraph for a close.
9463 \end_layout
9464
9465 \begin_layout Itemize
9466
9467 \family sans
9468 PS
9469 \family default
9470 : produces a paragraph for a postscript.
9471 \end_layout
9472
9473 \begin_layout Itemize
9474
9475 \family sans
9476 CC
9477 \family default
9478 : produces a paragraph for a distribution list.
9479 \end_layout
9480
9481 \begin_layout Itemize
9482
9483 \family sans
9484 Encl
9485 \family default
9486 : produces a paragraph for enclosures.
9487 \end_layout
9488
9489 \begin_layout Standard
9490 The types 
9491 \family sans
9492 Name
9493 \family default
9494
9495 \family sans
9496 Signature
9497 \family default
9498
9499 \family sans
9500 Address
9501 \family default
9502 ,
9503 \family sans
9504  Telephone
9505 \family default
9506
9507 \family sans
9508 Place
9509 \family default
9510
9511 \family sans
9512 Backaddress
9513 \family default
9514
9515 \family sans
9516 Specialmail
9517 \family default
9518
9519 \family sans
9520 Location
9521 \family default
9522
9523 \family sans
9524 Title
9525 \family default
9526 , and 
9527 \family sans
9528 Subject
9529 \family default
9530  are input types provided with a label to enter information, which will
9531  be processed by the document class.
9532 \begin_inset Foot
9533 status collapsed
9534
9535 \begin_layout Standard
9536 It could be seen as a matter of inconsequence, that the types 
9537 \family sans
9538 Letter
9539 \family default
9540  and 
9541 \family sans
9542 Opening
9543 \family default
9544  described above are not such input types as well.
9545  Because of the special meaning of those types, however, I have implemented
9546  them as ordinary paragraph types with a one letter mark in the left margin.
9547  Moreover, it would affect my feeling of symmetry, if the 
9548 \family sans
9549 Opening
9550 \family default
9551  type and the 
9552 \family sans
9553 Closing
9554 \family default
9555  type had such a serious different appearance.
9556 \end_layout
9557
9558 \end_inset
9559
9560  The types must be used ahead of the corresponding 
9561 \family sans
9562 Opening
9563 \family default
9564  type.
9565 \end_layout
9566
9567 \begin_layout Standard
9568 An implementation of these types in a WYSIWYG fashion does not seem to make
9569  sense, because the real appearance of the produced letter does not only
9570  depend on the usage of the particular type, but also on other factors.
9571  For example, a signature entered in the 
9572 \family sans
9573 Signature
9574 \family default
9575  type will in the standard behavior appear in the produced letter only,
9576  when in the same letter also a 
9577 \family sans
9578 Closing
9579 \family default
9580  type is used.
9581  The entered value of the 
9582 \family sans
9583 Telephone
9584 \family default
9585  type will in the standard behavior not appear in the produced letter at
9586  all.
9587  The possibility to design the letter`s heading freely is already indicated
9588  in a footnote above.
9589 \end_layout
9590
9591 \begin_layout Standard
9592 The input types can also be used as empty paragraphs.
9593  This makes sense e.\InsetSpace ~
9594 g.
9595  for the 
9596 \family sans
9597 Signature
9598 \family default
9599  type.
9600  If the 
9601 \family sans
9602 Signature
9603 \family default
9604  type is not used at all, in the standard behavior the value of the 
9605 \family sans
9606 Name
9607 \family default
9608  type is used as signature, whereas if an empty 
9609 \family sans
9610 Signature
9611 \family default
9612  type is used, no signature value is defined.
9613 \end_layout
9614
9615 \begin_layout Standard
9616 By using the input types it is possible to write a letter template, containing
9617  filled input types with your personal dates (name, address, etc.) and empty
9618  input types for other dates you want to enter.
9619 \end_layout
9620
9621 \begin_layout Itemize
9622
9623 \family sans
9624 Name
9625 \family default
9626 : sender's name, in the standard behavior appears as a centered paragraph
9627  in small caps in the letter`s heading.
9628 \end_layout
9629
9630 \begin_layout Itemize
9631
9632 \family sans
9633 Signature
9634 \family default
9635 : sender's signature, in the standard behavior appears below the 
9636 \family sans
9637 Closing
9638 \family default
9639  type.
9640  If no 
9641 \family sans
9642 Signature
9643 \family default
9644  type is used, the value of the 
9645 \family sans
9646 Name
9647 \family default
9648  type appears instead.
9649 \end_layout
9650
9651 \begin_layout Itemize
9652
9653 \family sans
9654 Address
9655 \family default
9656 : sender's address, in the standard behavior appears in a centered paragraph
9657  in the letter`s heading below the sender's name.
9658 \end_layout
9659
9660 \begin_layout Itemize
9661
9662 \family sans
9663 Telephone
9664 \family default
9665 : sender's telephone number, in the standard behavior only sets the LaTeX
9666  variable 
9667 \family typewriter
9668
9669 \backslash
9670 telephonenum
9671 \family default
9672 .
9673 \end_layout
9674
9675 \begin_layout Itemize
9676
9677 \family sans
9678 Place
9679 \family default
9680 : place of the letter`s making.
9681 \end_layout
9682
9683 \begin_layout Itemize
9684
9685 \family sans
9686 Date
9687 \family default
9688 : date of the letter`s making.
9689  
9690 \family sans
9691 Place
9692 \family default
9693  and 
9694 \family sans
9695 Date
9696 \family default
9697 , in the standard behavior, produce the place and the date in a right-aligned
9698  line below the addressee's field.
9699  If an empty 
9700 \family sans
9701 Date
9702 \family default
9703  type is used, neither place nor date appear, independent of the value of
9704  the 
9705 \family sans
9706 Place
9707 \family default
9708  type.
9709  If no 
9710 \family sans
9711 Date
9712 \family default
9713  type is used, the date of the letter `s production is used.
9714 \end_layout
9715
9716 \begin_layout Itemize
9717
9718 \family sans
9719 Backaddress
9720 \family default
9721 : sender`s back address, in the standard behavior appears above the addressee's
9722  field in a small sans serif font.
9723 \end_layout
9724
9725 \begin_layout Itemize
9726
9727 \family sans
9728 Specialmail
9729 \family default
9730 : special mail information, in the standard behavior appears underlined
9731  above the addressee's field below the back address.
9732 \end_layout
9733
9734 \begin_layout Itemize
9735
9736 \family sans
9737 Location
9738 \family default
9739 : additional information, in the standard behavior appears on right side
9740  below the addressee`s field.
9741 \end_layout
9742
9743 \begin_layout Itemize
9744
9745 \family sans
9746 Title
9747 \family default
9748 : the letter's title, in the standard behavior appears in a big, bold, sans
9749  serif font above the subject.
9750 \end_layout
9751
9752 \begin_layout Itemize
9753
9754 \family sans
9755 Subject
9756 \family default
9757 : the letter's subject, in the standard behavior appears in a bold font
9758  above the 
9759 \family sans
9760 Opening
9761 \family default
9762  paragraph.
9763 \end_layout
9764
9765 \begin_layout Standard
9766 The types 
9767 \family sans
9768 Yourref
9769 \family default
9770
9771 \family sans
9772 Yourmail
9773 \family default
9774
9775 \family sans
9776 Myref
9777 \family default
9778
9779 \family sans
9780 Customer
9781 \family default
9782 , and 
9783 \family sans
9784 Invoice
9785 \family default
9786  produce a business letter like line above the 
9787 \family sans
9788 Title
9789 \family default
9790  line containing the fields 
9791 \begin_inset Quotes eld
9792 \end_inset
9793
9794 Your ref.
9795 \begin_inset Quotes erd
9796 \end_inset
9797
9798
9799 \begin_inset Quotes eld
9800 \end_inset
9801
9802 Your letter of
9803 \begin_inset Quotes erd
9804 \end_inset
9805
9806
9807 \begin_inset Quotes eld
9808 \end_inset
9809
9810 Our ref.
9811 \begin_inset Quotes erd
9812 \end_inset
9813
9814
9815 \begin_inset Quotes eld
9816 \end_inset
9817
9818 Customer no.
9819 \begin_inset Quotes erd
9820 \end_inset
9821
9822
9823 \begin_inset Quotes eld
9824 \end_inset
9825
9826 Invoice no.
9827 \begin_inset Quotes erd
9828 \end_inset
9829
9830 , and 
9831 \begin_inset Quotes eld
9832 \end_inset
9833
9834 Date
9835 \begin_inset Quotes erd
9836 \end_inset
9837
9838 .
9839  For the date field, the value of the 
9840 \family sans
9841 Date
9842 \family default
9843  type is used.
9844  If one of these 
9845 \begin_inset Quotes eld
9846 \end_inset
9847
9848 business letter types
9849 \begin_inset Quotes erd
9850 \end_inset
9851
9852  is used, the value of the 
9853 \family sans
9854 Place
9855 \family default
9856  type however does not appear, but only the LaTeX variable 
9857 \family typewriter
9858
9859 \backslash
9860 fromplace
9861 \family default
9862  is set.
9863  The ordinary output of place and date in a right-aligned line below the
9864  addressee`s field is suppressed.
9865  The types are implemented as input types provided with a label and must
9866  be used ahead of the corresponding 
9867 \family sans
9868 Opening
9869 \family default
9870  type.
9871 \end_layout
9872
9873 \begin_layout Itemize
9874
9875 \family sans
9876 Yourref
9877 \family default
9878 : Your ref.
9879 \end_layout
9880
9881 \begin_layout Itemize
9882
9883 \family sans
9884 Yourmail
9885 \family default
9886 : Your letter of.
9887 \end_layout
9888
9889 \begin_layout Itemize
9890
9891 \family sans
9892 Myref
9893 \family default
9894 : Our ref.
9895 \end_layout
9896
9897 \begin_layout Itemize
9898
9899 \family sans
9900 Customer
9901 \family default
9902 : Customer no.
9903 \end_layout
9904
9905 \begin_layout Itemize
9906
9907 \family sans
9908 Invoice
9909 \family default
9910 : Invoice no.
9911 \end_layout
9912
9913 \begin_layout Subsection
9914 The new letter class: letter (koma-script v.2)
9915 \end_layout
9916
9917 \begin_layout Standard
9918 by 
9919 \noun on
9920 Jürgen Spitzmüller
9921 \end_layout
9922
9923 \begin_layout Standard
9924 \begin_inset VSpace medskip
9925 \end_inset
9926
9927
9928 \end_layout
9929
9930 \begin_layout Standard
9931 \noindent
9932 Koma-Script version 2.8 has introduced a new letter class 
9933 \family typewriter
9934 scrlttr2
9935 \family default
9936  which superceeds the now unsupported 
9937 \family typewriter
9938 scrlettr
9939 \family default
9940 .
9941  It has --- on the LaTeX side --- a completely new interface and is not
9942  compatible with the old class.
9943  Therefore, LyX supports both, though it is recommended to use the new class.
9944 \end_layout
9945
9946 \begin_layout Standard
9947 This class covers the same functionality as 
9948 \emph on
9949 letter (koma-script),
9950 \emph default
9951  and a few more.
9952  The basic items are 
9953 \family sans
9954 Address
9955 \family default
9956  (receiver's address, same as 
9957 \family sans
9958 Letter
9959 \family default
9960  in the old layout), 
9961 \family sans
9962 Opening
9963 \family default
9964 , and 
9965 \family sans
9966 Closing
9967 \family default
9968 .
9969  
9970 \family sans
9971 NextAddress
9972 \family default
9973  will start a new letter (i.
9974 \begin_inset ERT
9975 status collapsed
9976
9977 \begin_layout Standard
9978
9979
9980 \backslash
9981 ,
9982 \end_layout
9983
9984 \end_inset
9985
9986 e.
9987 \begin_inset ERT
9988 status collapsed
9989
9990 \begin_layout Standard
9991
9992
9993 \backslash
9994  
9995 \end_layout
9996
9997 \end_inset
9998
9999 you can write several letters per document).
10000  New elements are sender's 
10001 \family sans
10002 E-Mail
10003 \family default
10004
10005 \family sans
10006 URL
10007 \family default
10008
10009 \family sans
10010 Fax
10011 \family default
10012
10013 \family sans
10014 Bank
10015 \family default
10016  and the possibility to use a 
10017 \family sans
10018 Logo
10019 \family default
10020  (via 
10021 \family sans
10022 \bar under
10023 I
10024 \bar default
10025 nsert\SpecialChar \menuseparator
10026
10027 \bar under
10028 G
10029 \bar default
10030 raphics
10031 \family default
10032 ) in the header.
10033 \end_layout
10034
10035 \begin_layout Standard
10036 The biggest improvement is, though, that the letter's layout is configurable
10037  at almost any needs.
10038  This can be done via the preamble or with a special style file (Letter
10039  Class Option, extension 
10040 \family typewriter
10041 *.lco
10042 \family default
10043 ), that will be read in as a class option.
10044 \begin_inset Foot
10045 status collapsed
10046
10047 \begin_layout Standard
10048 The KOMA package comes with some default 
10049 \family typewriter
10050 *.lco
10051 \family default
10052  files.
10053  There is, for instance, a 
10054 \family typewriter
10055 DIN.lco
10056 \family default
10057  file that follows german typesetting rules, or a 
10058 \family typewriter
10059 KOMAold.lco
10060 \family default
10061  that provides the default layout of the old 
10062 \family typewriter
10063 scrlettr
10064 \family default
10065  class.
10066  The latter can be loaded with the class option 
10067 \family typewriter
10068 KOMAold
10069 \family default
10070 , inserted via the 
10071 \family sans
10072 \bar under
10073 L
10074 \bar default
10075 ayout\SpecialChar \menuseparator
10076
10077 \bar under
10078 D
10079 \bar default
10080 ocument\SpecialChar \menuseparator
10081 Extra Options 
10082 \family default
10083 field.
10084 \end_layout
10085
10086 \end_inset
10087
10088  Have a look at the 
10089 \emph on
10090 koma-letter2
10091 \emph default
10092  template that is included in LyX for examples.
10093  A detailed description is to be found in the Koma-Script documentation
10094  (
10095 \emph on
10096 scrguide
10097 \emph default
10098 ).
10099 \end_layout
10100
10101 \begin_layout Subsection
10102 Problems
10103 \end_layout
10104
10105 \begin_layout Standard
10106 Visualizing the Koma-Script document classes in LyX, the LyX internals cause
10107  some problems.
10108 \end_layout
10109
10110 \begin_layout Itemize
10111 The chapter number of a 
10112 \family sans
10113 Chapter
10114 \family default
10115  type appears on a line of its own above the chapter heading instead of
10116  appearing in the same line ahead of it.
10117  The cause for that is the LyX internal behavior for the labeltype 
10118 \family sans
10119 Counter_Chapter
10120 \family default
10121  in the layout file.
10122 \end_layout
10123
10124 \begin_layout Itemize
10125 The headings of the types 
10126 \family sans
10127 Addchap
10128 \family default
10129  and 
10130 \family sans
10131 Addsec
10132 \family default
10133  are only put in the 
10134 \begin_inset Quotes eld
10135 \end_inset
10136
10137 true
10138 \begin_inset Quotes erd
10139 \end_inset
10140
10141  LaTeX table of contents, but not in the LyX table of contents (
10142 \family sans
10143 \bar under
10144 D
10145 \bar default
10146 ocument\SpecialChar \menuseparator
10147
10148 \bar under
10149 T
10150 \bar default
10151 able\InsetSpace ~
10152 of\InsetSpace ~
10153 Contents
10154 \family default
10155 ).
10156 \end_layout
10157
10158 \begin_layout Itemize
10159 The paragraphs in a 
10160 \emph on
10161 letter
10162 \emph default
10163  document class appear in a skip separation mode, not indented.
10164  This is the standard behavior, no special LaTeX commands are needed for
10165  that.
10166  But in the 
10167 \family sans
10168 \bar under
10169 D
10170 \bar default
10171 ocument\SpecialChar \menuseparator
10172
10173 \bar under
10174 S
10175 \bar default
10176 ettings
10177 \family default
10178  dialog the corresponding radio button indicates 
10179 \family sans
10180 \bar under
10181 I
10182 \bar default
10183 ndent
10184 \family default
10185 .
10186  A 
10187 \family sans
10188 S
10189 \bar under
10190 k
10191 \bar default
10192 ip
10193 \family default
10194  value always has the effect that extra LaTeX commands are inserted in the
10195  document to produce the gap, which is not what is wanted in this case.
10196 \end_layout
10197
10198 \begin_layout Section
10199 Springer Journals (
10200 \family sans
10201 svjour
10202 \family default
10203 )
10204 \end_layout
10205
10206 \begin_layout Standard
10207 by 
10208 \noun on
10209 Martin Vermeer
10210 \end_layout
10211
10212 \begin_layout Subsection
10213 Description
10214 \end_layout
10215
10216 \begin_layout Standard
10217 These are the layout files for some of the journal formats used by Springer
10218  Verlag and listed on 
10219 \begin_inset LatexCommand \url{http://www.springer.de/author/tex/help-journals.html}
10220
10221 \end_inset
10222
10223 , where you should also go to fetch the class files (yes, these are LaTeX2e
10224  now!).
10225  It is a modular system: the things common to all journals are implemented
10226  in 
10227 \family typewriter
10228 svjour.inc
10229 \family default
10230 , which journal-specific layout files (such as, e.g., 
10231 \family typewriter
10232 svjog.layout
10233 \family default
10234  for Journal of Geodesy) can include.
10235 \end_layout
10236
10237 \begin_layout Standard
10238 This means that implementing support for any other Springer journal on this
10239  list is as simple as writing your own 
10240 \family typewriter
10241 sv
10242 \family default
10243 <myjournal>
10244 \family typewriter
10245 .layout
10246 \family default
10247  file following the outline given in 
10248 \family typewriter
10249 svjog.layout
10250 \family default
10251 .
10252  
10253 \end_layout
10254
10255 \begin_layout Standard
10256 It is reasonably well tested only for the Journal of Geodesy.
10257  
10258 \family typewriter
10259 svjour
10260 \family default
10261  and 
10262 \family typewriter
10263 svjog
10264 \family default
10265  come with the standard LyX distribution.
10266  Install the relevant class file (downloaded from Springer) in a proper
10267  directory, reconfigure LaTeX (in the teTeX case by running 
10268 \family typewriter
10269 texhash
10270 \family default
10271 , as root if necessary --- doesn't LyX take care of this?), reconfigure
10272  LyX and it should work.
10273 \end_layout
10274
10275 \begin_layout Subsection
10276 New styles
10277 \end_layout
10278
10279 \begin_layout Standard
10280 A large number of theorem-like styles --- 
10281 \family sans
10282 Claim, Conjecture,
10283 \family default
10284  
10285 \family sans
10286 \SpecialChar \ldots{}
10287 Theorem
10288 \family default
10289 .
10290 \end_layout
10291
10292 \begin_layout Standard
10293
10294 \family sans
10295 Headnote, Dedication, Subtitle, Running_LaTeX_Title, Author_Running, Institute,
10296  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
10297 \family default
10298 .
10299  See the Springer class file documentation for details.
10300 \end_layout
10301
10302 \begin_layout Subsection
10303 Supported journals
10304 \end_layout
10305
10306 \begin_layout Itemize
10307
10308 \emph on
10309 Journal of Geodesy
10310 \emph default
10311
10312 \family typewriter
10313 svjog.layout 
10314 \family default
10315 --- Martin Vermeer
10316 \end_layout
10317
10318 \begin_layout Itemize
10319
10320 \emph on
10321 Probability Theory and Related Fields
10322 \emph default
10323
10324 \family typewriter
10325 svprobth.layout
10326 \family default
10327  --- Jean-Marc Lasgouttes
10328 \end_layout
10329
10330 \begin_layout Standard
10331 Add your own, it isn't so hard!
10332 \end_layout
10333
10334 \begin_layout Subsection
10335 Credits
10336 \end_layout
10337
10338 \begin_layout Standard
10339 These files are partly based on the older 
10340 \family typewriter
10341 ejour2.layout
10342 \family default
10343 , which was again based on a tinkered-with version of an old LaTeX 2.09 style
10344  file from Springer.
10345  All this, and the 
10346 \family typewriter
10347 ejour2
10348 \family default
10349  layout, are now defunct.
10350  Jean-Marc Lasgouttes helped out big in making me find my way around the
10351  LyX layout file mechanism.
10352 \end_layout
10353
10354 \begin_layout Subsection
10355 Bugs
10356 \end_layout
10357
10358 \begin_layout Standard
10359 Probably.
10360  But probably less than in the old hacked-LaTeX 
10361 \family typewriter
10362 ejour2
10363 \family default
10364 .
10365 \end_layout
10366
10367 \begin_layout Standard
10368 Limitations e.g.: does not display the number for theorem-like layouts, just
10369  #.
10370 \end_layout
10371
10372 \begin_layout Section
10373 AGU journals (
10374 \family sans
10375 aguplus
10376 \family default
10377 )
10378 \end_layout
10379
10380 \begin_layout Standard
10381 by 
10382 \shape smallcaps
10383 Martin Vermeer
10384 \end_layout
10385
10386 \begin_layout Subsection
10387 Description
10388 \end_layout
10389
10390 \begin_layout Standard
10391 These are the layout files for some of the journals of the American Geophysical
10392  Society.
10393  It is assumed that you have both the AGU's own class files and AGUplus
10394  installed (everything to be found at
10395 \begin_inset LatexCommand \url{ftp://ftp.agu.org/journals/latex/journals}
10396
10397 \end_inset
10398
10399 ).
10400 \end_layout
10401
10402 \begin_layout Subsection
10403 New styles
10404 \end_layout
10405
10406 \begin_layout Standard
10407 Redefined are 
10408 \family sans
10409 Paragraph
10410 \family default
10411
10412 \family sans
10413 Paragraph*
10414 \family default
10415 .
10416  They are still called this in the LyX GUI, though their LaTeX equivalents
10417  in the AGU classes are 
10418 \family sans
10419 Subsubsubsection
10420 \family default
10421  and 
10422 \family sans
10423 Subsubsubsection*
10424 \family default
10425 .
10426 \end_layout
10427
10428 \begin_layout Standard
10429 Newly defined styles are 
10430 \family sans
10431 Left_Header
10432 \family default
10433
10434 \family sans
10435 Right_Header
10436 \family default
10437
10438 \family sans
10439 Received
10440 \family default
10441
10442 \family sans
10443 Revised
10444 \family default
10445
10446 \family sans
10447 Accepted
10448 \family default
10449
10450 \family sans
10451 CCC
10452 \family default
10453
10454 \family sans
10455 PaperId
10456 \family default
10457
10458 \family sans
10459 AuthorAddr
10460 \family default
10461
10462 \family sans
10463 SlugComment
10464 \family default
10465 .
10466  These are mostly manuscript attributes and defined in the AGU class documentati
10467 on.
10468 \end_layout
10469
10470 \begin_layout Standard
10471 I suspect this is still badly incomplete.
10472 \end_layout
10473
10474 \begin_layout Subsection
10475 New floats
10476 \end_layout
10477
10478 \begin_layout Standard
10479
10480 \family sans
10481 Planotable
10482 \family default
10483  and 
10484 \family sans
10485 Plate
10486 \family default
10487 .
10488  We also have a new 
10489 \family sans
10490 Table_Caption
10491 \family default
10492 .
10493 \end_layout
10494
10495 \begin_layout Subsection
10496 Supported journals
10497 \end_layout
10498
10499 \begin_layout Itemize
10500
10501 \emph on
10502 Journal of Geophysical Research
10503 \emph default
10504
10505 \family typewriter
10506 jgrga.layout 
10507 \family default
10508 --- Martin Vermeer
10509 \end_layout
10510
10511 \begin_layout Standard
10512 Add your own, it isn't so hard! Look at the 
10513 \family typewriter
10514 jgrga.layout
10515 \family default
10516  example and 
10517 \family typewriter
10518 aguplus.inc
10519 \family default
10520 .
10521 \end_layout
10522
10523 \begin_layout Subsection
10524 Bugs and things to remember
10525 \end_layout
10526
10527 \begin_layout Standard
10528 In order to use the new layouts, you must remember to do the following for
10529  a new document:
10530 \end_layout
10531
10532 \begin_layout Enumerate
10533
10534 \emph on
10535 Turn off babel
10536 \emph default
10537 .
10538  This can be done in the 
10539 \family sans
10540 layout\SpecialChar \menuseparator
10541 document
10542 \family default
10543  or 
10544 \family sans
10545 document\SpecialChar \menuseparator
10546 settings
10547 \family default
10548  menu item.
10549  (AGU articles are always in English, right? So 
10550 \emph on
10551 don't
10552 \emph default
10553  choose a language.)
10554 \end_layout
10555
10556 \begin_layout Enumerate
10557 Enter 
10558 \family typewriter
10559 jgrga
10560 \family default
10561  into the document's 
10562 \family sans
10563 Extra Options
10564 \family default
10565  field.
10566  (Yes, this is a bug.)
10567 \end_layout
10568
10569 \begin_layout Enumerate
10570 Make sure you use the 
10571 \family typewriter
10572 agu.bst
10573 \family default
10574  bibliography style, by entering 
10575 \family sans
10576 agu
10577 \family default
10578  into the second field of the BibTeX inset.
10579  None of the standard styles will do.
10580 \end_layout
10581
10582 \begin_layout Section
10583 EGS journals (
10584 \family sans
10585 egs
10586 \family default
10587 )
10588 \end_layout
10589
10590 \begin_layout Standard
10591 by 
10592 \shape smallcaps
10593 Martin Vermeer
10594 \end_layout
10595
10596 \begin_layout Subsection
10597 Description
10598 \end_layout
10599
10600 \begin_layout Standard
10601 This is the layout file for the European Geophysical Society journals.
10602  The needed 
10603 \family typewriter
10604 egs.cls
10605 \family default
10606  can be downloaded from the web site of the EGS under 
10607 \begin_inset LatexCommand \url{www.copernicus.org}
10608
10609 \end_inset
10610
10611 .
10612 \end_layout
10613
10614 \begin_layout Subsection
10615 New styles
10616 \end_layout
10617
10618 \begin_layout Standard
10619
10620 \family sans
10621 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
10622  Accepted
10623 \family default
10624
10625 \family sans
10626 Offsets
10627 \family default
10628 .
10629  The current layout file is unfortunately very unmodular and would benefit
10630  from using the various 
10631 \family typewriter
10632 std*.inc
10633 \family default
10634  file inclusions.
10635 \end_layout
10636
10637 \begin_layout Section
10638 Slides [aka 
10639 \noun on
10640 Sli
10641 \noun default
10642 TeX]
10643 \begin_inset LatexCommand \label{sec:slitex}
10644
10645 \end_inset
10646
10647
10648 \end_layout
10649
10650 \begin_layout Standard
10651 by 
10652 \noun on
10653 John Weiss
10654 \noun default
10655  
10656 \end_layout
10657
10658 \begin_layout Subsection
10659 Introduction
10660 \end_layout
10661
10662 \begin_layout Standard
10663 This section describes how to use LyX to make slides for overhead projectors.
10664  There are two document classes that can do this: the default slides class
10665  and the 
10666 \family sans
10667 Foil
10668 \family default
10669 TeX slides class.
10670  This section documents the former.
10671 \end_layout
10672
10673 \begin_layout Standard
10674 I'm going to say this again, nice and clear, so that there's no misunderstanding
10675 :
10676 \end_layout
10677
10678 \begin_layout Standard
10679 \begin_inset VSpace bigskip
10680 \end_inset
10681
10682
10683 \end_layout
10684
10685 \begin_layout Standard
10686 \align center
10687
10688 \size large
10689 This section documents the class 
10690 \begin_inset Quotes eld
10691 \end_inset
10692
10693
10694 \family sans
10695 slides (default)
10696 \family default
10697
10698 \begin_inset Quotes erd
10699 \end_inset
10700
10701  
10702 \emph on
10703 only.
10704 \end_layout
10705
10706 \begin_layout Standard
10707 \begin_inset VSpace bigskip
10708 \end_inset
10709
10710
10711 \end_layout
10712
10713 \begin_layout Standard
10714 If you're looking for the documentation for 
10715 \begin_inset Quotes eld
10716 \end_inset
10717
10718
10719 \family sans
10720 slides (FoilTeX)
10721 \family default
10722
10723 \begin_inset Quotes erd
10724 \end_inset
10725
10726 , check out section\InsetSpace ~
10727
10728 \begin_inset LatexCommand \ref{sec:foiltex}
10729
10730 \end_inset
10731
10732 .
10733  The 
10734 \family sans
10735 foils 
10736 \family default
10737 class [
10738 \begin_inset Quotes eld
10739 \end_inset
10740
10741
10742 \family sans
10743 slides (FoilTeX)
10744 \family default
10745
10746 \begin_inset Quotes erd
10747 \end_inset
10748
10749 ] is actually somewhat better than the default 
10750 \family sans
10751 slides
10752 \family default
10753  class,
10754 \begin_inset Foot
10755 status collapsed
10756
10757 \begin_layout Standard
10758 \SpecialChar \ldots{}
10759 or so I've been told repeatedly by its advocates.
10760  Having never used it, I have no idea if this claim is true or not.
10761 \end_layout
10762
10763 \end_inset
10764
10765  which this section documents.
10766 \end_layout
10767
10768 \begin_layout Standard
10769 This class is the LaTeX2e improvement of the old 
10770 \noun on
10771 Sli
10772 \noun default
10773 TeX package.
10774  Every LaTeX2e distribution includes this class [which I'll just refer to
10775  as 
10776 \begin_inset Quotes eld
10777 \end_inset
10778
10779
10780 \family sans
10781 slides
10782 \family default
10783
10784 \begin_inset Quotes erd
10785 \end_inset
10786
10787  from now on], so you're bound to have it.
10788  As I noted earlier, there are other classes, such as 
10789 \family sans
10790 foils
10791 \family default
10792 , which also produce slides for overhead projectors and do a better job
10793  at it.
10794  However, there are some things which 
10795 \family sans
10796 slides
10797 \family default
10798  can do which the others can't, such as generate overlays.
10799  Read on to learn more!
10800 \end_layout
10801
10802 \begin_layout Subsection
10803 Getting Started
10804 \begin_inset LatexCommand \label{sec:slidesetup}
10805
10806 \end_inset
10807
10808
10809 \end_layout
10810
10811 \begin_layout Standard
10812 Obviously, to use this document class, you need to select 
10813 \begin_inset Quotes eld
10814 \end_inset
10815
10816
10817 \family sans
10818 slides (default)
10819 \family default
10820
10821 \begin_inset Quotes erd
10822 \end_inset
10823
10824  from the class list in the 
10825 \family sans
10826 \bar under
10827 D
10828 \bar default
10829 ocument\SpecialChar \menuseparator
10830
10831 \bar under
10832 S
10833 \bar default
10834 ettings
10835 \family default
10836  dialog.
10837  There are some other special things you should know about this class:
10838 \end_layout
10839
10840 \begin_layout Itemize
10841 Don't bother changing the options 
10842 \family sans
10843 Sides and Columns
10844 \family default
10845 .
10846  They're not supported by the 
10847 \family sans
10848 slides
10849 \family default
10850  class, anyways.
10851 \end_layout
10852
10853 \begin_layout Itemize
10854 The option 
10855 \family sans
10856 \bar under
10857 P
10858 \bar default
10859 age\InsetSpace ~
10860 style
10861 \family default
10862  behaves a bit differently for this class.
10863  The possible choices and what they do are as follows:
10864 \end_layout
10865
10866 \begin_deeper
10867 \begin_layout Description
10868
10869 \family sans
10870 plain
10871 \family default
10872  The final output contains page numbers in the lower right corner.
10873 \end_layout
10874
10875 \begin_layout Description
10876
10877 \family sans
10878 headings
10879 \family default
10880  Like 
10881 \family sans
10882 plain
10883 \family default
10884 , but also prints out any time markers you've put in.
10885  This is the default.
10886 \end_layout
10887
10888 \begin_layout Description
10889
10890 \family sans
10891 empty
10892 \family default
10893  The final output contains no page numbers, time markers, or alignment markers.
10894 \end_layout
10895
10896 \end_deeper
10897 \begin_layout Itemize
10898 The 
10899 \family sans
10900 slides
10901 \family default
10902  class has an extra option: 
10903 \family typewriter
10904 clock
10905 \family default
10906 .
10907  To use it, put 
10908 \begin_inset Quotes eld
10909 \end_inset
10910
10911
10912 \family typewriter
10913 clock
10914 \family default
10915
10916 \begin_inset Quotes erd
10917 \end_inset
10918
10919  in the extra class options.
10920 \end_layout
10921
10922 \begin_deeper
10923 \begin_layout Standard
10924 Using this options allows you to add time markers to 
10925 \family sans
10926 Note
10927 \family default
10928 s.
10929  See section\InsetSpace ~
10930
10931 \begin_inset LatexCommand \ref{sec:slideNote}
10932
10933 \end_inset
10934
10935  for more details.
10936 \end_layout
10937
10938 \end_deeper
10939 \begin_layout Standard
10940 You can also use the template file 
10941 \begin_inset Quotes eld
10942 \end_inset
10943
10944
10945 \family typewriter
10946 slides.lyx
10947 \family default
10948
10949 \begin_inset Quotes erd
10950 \end_inset
10951
10952  to automatically set up a document to use the 
10953 \family sans
10954 slides 
10955 \family default
10956 class [using 
10957 \family sans
10958 \bar under
10959 F
10960 \bar default
10961 ile\SpecialChar \menuseparator
10962 New\InsetSpace ~
10963 from\InsetSpace ~
10964
10965 \bar under
10966 T
10967 \bar default
10968 emplate
10969 \family default
10970  to open your new document].
10971  The template file also contains some examples of the special paragraph
10972  environments used by this class.
10973  I'll describe those next.
10974 \end_layout
10975
10976 \begin_layout Subsection
10977 Paragraph Environments
10978 \end_layout
10979
10980 \begin_layout Subsubsection
10981 Supported Environments
10982 \end_layout
10983
10984 \begin_layout Standard
10985 The first thing you'll notice when you start up a new 
10986 \family sans
10987 slides 
10988 \family default
10989 document is the font size and type: it's the equivalent of the size 
10990 \begin_inset Quotes eld
10991 \end_inset
10992
10993
10994 \family sans
10995 Largest
10996 \family default
10997
10998 \begin_inset Quotes erd
10999 \end_inset
11000
11001  in the 
11002 \family sans
11003 Sans\InsetSpace ~
11004 Serif
11005 \family default
11006  font.
11007  This is also what's used in the output.
11008  Think of this as a 
11009 \begin_inset Quotes eld
11010 \end_inset
11011
11012 visual cue
11013 \begin_inset Quotes erd
11014 \end_inset
11015
11016  to remind you that this is a slide.
11017  Your final slides will use a larger font; ergo, you'll have less space.
11018  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
11019 \end_layout
11020
11021 \begin_layout Standard
11022 The next thing that becomes obvious is the changes to the paragraph environment
11023  pull-down box [at the far-left end of the toolbar].
11024  Most of the paragraph environments you're used to seeing are missing.
11025  There are also five new ones.
11026  That's because the 
11027 \family sans
11028 slides
11029 \family default
11030  class itself only supports certain paragraph environments:
11031 \end_layout
11032
11033 \begin_layout Itemize
11034
11035 \family sans
11036 Standard
11037 \end_layout
11038
11039 \begin_layout Itemize
11040
11041 \family sans
11042 Itemize
11043 \end_layout
11044
11045 \begin_layout Itemize
11046
11047 \family sans
11048 Enumerate
11049 \end_layout
11050
11051 \begin_layout Itemize
11052
11053 \family sans
11054 Description
11055 \end_layout
11056
11057 \begin_layout Itemize
11058
11059 \family sans
11060 List
11061 \end_layout
11062
11063 \begin_layout Itemize
11064
11065 \family sans
11066 Quotation
11067 \end_layout
11068
11069 \begin_layout Itemize
11070
11071 \family sans
11072 Quote
11073 \end_layout
11074
11075 \begin_layout Itemize
11076
11077 \family sans
11078 Verse
11079 \end_layout
11080
11081 \begin_layout Itemize
11082
11083 \family sans
11084 Caption
11085 \end_layout
11086
11087 \begin_layout Itemize
11088
11089 \family sans
11090 LyX-Code
11091 \end_layout
11092
11093 \begin_layout Itemize
11094
11095 \family sans
11096 Comment
11097 \end_layout
11098
11099 \begin_layout Standard
11100 All of the other standard environments, including the section-heading environmen
11101 ts, aren't used in the 
11102 \family sans
11103 slides
11104 \family default
11105  class.
11106 \end_layout
11107
11108 \begin_layout Standard
11109 On the other hand, you'll notice the following new environments:
11110 \end_layout
11111
11112 \begin_layout Itemize
11113
11114 \family sans
11115 Slide
11116 \end_layout
11117
11118 \begin_layout Itemize
11119
11120 \family sans
11121 Overlay
11122 \end_layout
11123
11124 \begin_layout Itemize
11125
11126 \family sans
11127 Note
11128 \end_layout
11129
11130 \begin_layout Itemize
11131
11132 \family sans
11133 InvisibleText
11134 \end_layout
11135
11136 \begin_layout Itemize
11137
11138 \family sans
11139 VisibleText
11140 \end_layout
11141
11142 \begin_layout Standard
11143 These five are kind of quirky, due to a 
11144 \begin_inset Quotes eld
11145 \end_inset
11146
11147 feature
11148 \begin_inset Quotes erd
11149 \end_inset
11150
11151  in LyX.
11152  You see, LyX doesn't permit you to nest any other paragraph environment
11153  into an empty environment.
11154  Now, that's fine and dandy, but it means that you wouldn't be able to start
11155  a slide with anything except plain text.
11156  To deal with this, I've performed a little 
11157 \begin_inset Quotes eld
11158 \end_inset
11159
11160 LaTeX magic.
11161 \begin_inset Quotes erd
11162 \end_inset
11163
11164  
11165 \end_layout
11166
11167 \begin_layout Subsubsection
11168 Quirks of the New Environments
11169 \begin_inset LatexCommand \label{sec:slideQuirk}
11170
11171 \end_inset
11172
11173
11174 \end_layout
11175
11176 \begin_layout Standard
11177 All five of the new paragraph environments are somewhat quirky due to inherent
11178  limitiations in the current version of LyX.
11179  As I just mentioned, LyX forbids environments that begin with another environme
11180 nt.
11181  To get around this, the 
11182 \family sans
11183 Slide
11184 \family default
11185  environment isn't a paragraph environment as described in the 
11186 \emph on
11187 User's Guide
11188 \emph default
11189 .
11190  
11191 \end_layout
11192
11193 \begin_layout Standard
11194 You should consider 
11195 \family sans
11196 Slide
11197 \family default
11198
11199 \family sans
11200 Overlay
11201 \family default
11202 , and 
11203 \family sans
11204 Note
11205 \family default
11206  to be 
11207 \begin_inset Quotes eld
11208 \end_inset
11209
11210 pseudo-environments.
11211 \begin_inset Quotes erd
11212 \end_inset
11213
11214  They look like a section heading or a 
11215 \begin_inset Quotes eld
11216 \end_inset
11217
11218
11219 \family sans
11220 Caption
11221 \family default
11222 ,
11223 \begin_inset Quotes erd
11224 \end_inset
11225
11226  but really begin a [and, if necessary, end the previous] paragraph environment.
11227  Likewise, treat 
11228 \family sans
11229 InvisibleText
11230 \family default
11231  and 
11232 \family sans
11233 VisibleText
11234 \family default
11235  as 
11236 \begin_inset Quotes eld
11237 \end_inset
11238
11239 pseudo-commands.
11240 \begin_inset Quotes erd
11241 \end_inset
11242
11243  These two perform some action.
11244 \end_layout
11245
11246 \begin_layout Standard
11247 A common feature of all five environments, 
11248 \family sans
11249 Slide
11250 \family default
11251
11252 \family sans
11253 Overlay
11254 \family default
11255
11256 \family sans
11257 Note
11258 \family default
11259
11260 \family sans
11261 InvisibleText
11262 \family default
11263  and 
11264 \family sans
11265 VisibleText
11266 \family default
11267 , is a rather long-ish label.
11268  The text following this label --- ordinarily the contents of the paragraph
11269  environment --- is utterly irrelevant for 
11270 \family sans
11271 Slide
11272 \family default
11273
11274 \family sans
11275 Overlay
11276 \family default
11277
11278 \family sans
11279 Note
11280 \family default
11281
11282 \family sans
11283 InvisibleText
11284 \family default
11285  and 
11286 \family sans
11287 VisibleText
11288 \family default
11289 .
11290  LyX completely ignores it.
11291  In fact, you can leave these five environments completely empty.
11292  
11293 \end_layout
11294
11295 \begin_layout Standard
11296 While you don't 
11297 \emph on
11298 have
11299 \emph default
11300  to put any text after the rather long-ish label, you might want to.
11301  This could be a short description of the contents of the 
11302 \family sans
11303 Slide
11304 \family default
11305 , for example.
11306  In that case, enter in your descriptive comment and hit 
11307 \family sans
11308 Return
11309 \family default
11310  as you normally would.
11311 \end_layout
11312
11313 \begin_layout Standard
11314 If, on the other hand, you don't want to enter in any descriptive text,
11315  you'll hit another LyX quirk.
11316  LyX, like nature, abhors a vacuum, and will not let you start a new paragraph
11317  environment until you put something in the old one.
11318  So, do this:
11319 \end_layout
11320
11321 \begin_layout Itemize
11322 Start entering the text that will 
11323 \emph on
11324 follow
11325 \emph default
11326  the new 
11327 \family sans
11328 Slide
11329 \family default
11330
11331 \family sans
11332 Overlay
11333 \family default
11334
11335 \family sans
11336 Note
11337 \family default
11338
11339 \family sans
11340 InvisibleText
11341 \family default
11342  or 
11343 \family sans
11344 VisibleText
11345 \family default
11346 .
11347  
11348 \end_layout
11349
11350 \begin_layout Itemize
11351 Now move to the beginning of that paragraph.
11352  
11353 \end_layout
11354
11355 \begin_layout Itemize
11356 Next, hit 
11357 \family sans
11358 Return
11359 \family default
11360 .
11361  
11362 \end_layout
11363
11364 \begin_layout Itemize
11365 Finally, change this new, empty paragraph to a 
11366 \family sans
11367 Slide
11368 \family default
11369
11370 \family sans
11371 Overlay
11372 \family default
11373
11374 \family sans
11375 Note
11376 \family default
11377
11378 \family sans
11379 InvisibleText
11380 \family default
11381  or 
11382 \family sans
11383 VisibleText
11384 \family default
11385 .
11386  
11387 \end_layout
11388
11389 \begin_layout Standard
11390 Some future version of LyX will, hopefully, resolve this quirkiness\SpecialChar \ldots{}
11391
11392 \end_layout
11393
11394 \begin_layout Subsection
11395 Making a Presentation with 
11396 \family sans
11397 Slide
11398 \family default
11399 ,
11400 \family sans
11401  Overlay
11402 \family default
11403  and 
11404 \family sans
11405 Note
11406 \end_layout
11407
11408 \begin_layout Subsubsection
11409 Using the 
11410 \family sans
11411 Slide
11412 \family default
11413  Environment
11414 \end_layout
11415
11416 \begin_layout Standard
11417 If you're expecting this section to teach you how to actually make a presentatio
11418 n, you'll be sorely disappointed.
11419  Naturally, I'll describe all of the ways the 
11420 \family sans
11421 slides
11422 \family default
11423  class can assist you in preparing the materials for a presentation.
11424  Filling in the contents, however, is up to you.
11425  [Then again, that 
11426 \emph on
11427 is
11428 \emph default
11429  the LyX philosophy.]
11430 \end_layout
11431
11432 \begin_layout Standard
11433 Choosing the 
11434 \family sans
11435 Slide
11436 \family default
11437  environment [in the manner described in section\InsetSpace ~
11438
11439 \begin_inset LatexCommand \ref{sec:slideQuirk}
11440
11441 \end_inset
11442
11443 ] tells LyX to begin a new slide [duh].
11444  The label for this environment/
11445 \begin_inset Quotes erd
11446 \end_inset
11447
11448 pseudo-command
11449 \begin_inset Quotes erd
11450 \end_inset
11451
11452  is an 
11453 \begin_inset Quotes eld
11454 \end_inset
11455
11456 ASCII line,
11457 \begin_inset Quotes erd
11458 \end_inset
11459
11460  in cool blue, followed by the label, 
11461 \begin_inset Quotes eld
11462 \end_inset
11463
11464 NewSlide:
11465 \begin_inset Quotes erd
11466 \end_inset
11467
11468 .
11469  Any text or paragraph environments that follow this one go on the new slide.
11470  It's that simple.
11471 \end_layout
11472
11473 \begin_layout Standard
11474 Slides are probably the only time you'll need to forcibly end pages in LyX
11475  (this can be specified in the 
11476 \family sans
11477 Paragraph Layout
11478 \family default
11479  dialog).
11480  In fact, you'll want to, once you finish entering the contents of one slide.
11481  If you've entered more text than can physically fit on a slide, the extra
11482  overflows onto a new slide.
11483  I don't recommend doing this, however, since the overflow slide won't have
11484  any page number on it.
11485  Furthermore, it may interfere with any 
11486 \family sans
11487 Overlay
11488 \family default
11489  you've made to accompany the oversized 
11490 \family sans
11491 Slide
11492 \family default
11493 .
11494 \end_layout
11495
11496 \begin_layout Standard
11497 The 
11498 \family sans
11499 Overlay
11500 \family default
11501  and 
11502 \family sans
11503 Note
11504 \family default
11505  environments work the same way as the 
11506 \family sans
11507 Slide 
11508 \family default
11509 environment.
11510  They both create an 
11511 \begin_inset Quotes eld
11512 \end_inset
11513
11514 ASCII line
11515 \begin_inset Quotes erd
11516 \end_inset
11517
11518  followed by a label [
11519 \begin_inset Quotes eld
11520 \end_inset
11521
11522 NewOverlay:
11523 \begin_inset Quotes erd
11524 \end_inset
11525
11526  and 
11527 \begin_inset Quotes eld
11528 \end_inset
11529
11530 NewNote:
11531 \begin_inset Quotes erd
11532 \end_inset
11533
11534 , respectively].
11535  The color is a stunning magenta instead of blue, and the 
11536 \begin_inset Quotes eld
11537 \end_inset
11538
11539 ASCII line
11540 \begin_inset Quotes erd
11541 \end_inset
11542
11543  will look different, in style and in length.
11544  The label fonts of all three also differ from one another.
11545 \end_layout
11546
11547 \begin_layout Standard
11548 As with a 
11549 \family sans
11550 Slide
11551 \family default
11552 , if the contents of a 
11553 \family sans
11554 Note
11555 \family default
11556  or 
11557 \family sans
11558 Overlay
11559 \family default
11560  exceed the physical size of a slide or sheet of paper, the extra will overflow
11561  onto a new sheet.
11562  Again, you should avoid this.
11563  It defeats the whole purpose of 
11564 \family sans
11565 Note
11566 \family default
11567 s and 
11568 \family sans
11569 Overlay
11570 \family default
11571 s.
11572 \end_layout
11573
11574 \begin_layout Subsubsection
11575 Using 
11576 \family sans
11577 Overlay
11578 \family default
11579  with 
11580 \family sans
11581 Slide
11582 \end_layout
11583
11584 \begin_layout Standard
11585 The idea behind an 
11586 \family sans
11587 Overlay
11588 \family default
11589  is a slide that sits atop another slide.
11590  Perhaps you wish to discuss a figure on the main 
11591 \family sans
11592 Slide
11593 \family default
11594  before displaying the text associated with it.
11595  One way to accomplish this is tape a flap of dark paper over the part of
11596  the 
11597 \family sans
11598 Slide
11599 \family default
11600  you want to display later.
11601  This method fails, however, if you wish to overlap one graph with another,
11602  for example.
11603  You would then have to fumble while speaking to align the two separate,
11604  overlapping 
11605 \family sans
11606 Slide
11607 \family default
11608 s to align the two graphs.
11609  The use of an 
11610 \family sans
11611 Overlay
11612 \family default
11613  environment in both cases makes life much easier.
11614 \end_layout
11615
11616 \begin_layout Standard
11617 Each 
11618 \family sans
11619 Overlay
11620 \family default
11621  receives the page number of its 
11622 \begin_inset Quotes eld
11623 \end_inset
11624
11625 parent
11626 \begin_inset Quotes erd
11627 \end_inset
11628
11629  
11630 \family sans
11631 Slide
11632 \family default
11633 , appended by 
11634 \begin_inset Quotes eld
11635 \end_inset
11636
11637
11638 \family typewriter
11639 -a
11640 \family default
11641
11642 \begin_inset Quotes erd
11643 \end_inset
11644
11645 .
11646 \begin_inset Foot
11647 status collapsed
11648
11649 \begin_layout Standard
11650 Presumably, mutliple 
11651 \family sans
11652 Overlay
11653 \family default
11654 s would have 
11655 \begin_inset Quotes eld
11656 \end_inset
11657
11658
11659 \family typewriter
11660 -a
11661 \family default
11662
11663 \begin_inset Quotes erd
11664 \end_inset
11665
11666
11667 \begin_inset Quotes eld
11668 \end_inset
11669
11670
11671 \family typewriter
11672 -b
11673 \family default
11674
11675 \begin_inset Quotes erd
11676 \end_inset
11677
11678
11679 \begin_inset Quotes eld
11680 \end_inset
11681
11682
11683 \family typewriter
11684 -c
11685 \family default
11686
11687 \begin_inset Quotes erd
11688 \end_inset
11689
11690 , etc.\InsetSpace ~
11691 appended to the page number of the parent 
11692 \family sans
11693 Slide
11694 \family default
11695 .
11696  
11697 \end_layout
11698
11699 \end_inset
11700
11701  Clearly, you want the contents of both the 
11702 \family sans
11703 Slide
11704 \family default
11705  and the 
11706 \family sans
11707 Overlay
11708 \family default
11709  to each fit on a single physical slide! You should probably consider an
11710  
11711 \family sans
11712 Overlay
11713 \family default
11714  as 
11715 \begin_inset Quotes eld
11716 \end_inset
11717
11718 part of
11719 \begin_inset Quotes erd
11720 \end_inset
11721
11722  a 
11723 \family sans
11724 Slide
11725 \family default
11726 .
11727  Indeed, the LyX 
11728 \family sans
11729 slides
11730 \family default
11731  class provides a visual cue for this: the label at the start of an 
11732 \family sans
11733 Overlay
11734 \family default
11735  is shorter than that at the start of a 
11736 \family sans
11737 Slide
11738 \family default
11739 .
11740  Lastly, when you generate printable output, you'll find alignment markers
11741  in all four corners of both the 
11742 \family sans
11743 Overlay
11744 \family default
11745  page and its parent 
11746 \family sans
11747 Slide
11748 \family default
11749 .
11750  These will assist you in lining up the two physical slides.
11751 \end_layout
11752
11753 \begin_layout Standard
11754 The major problem in overlaying two slides is aligning the contents of the
11755  two transparencies.
11756  How much space should you leave for that graph on the second slide? Worse
11757  still, what if you want a graph and a sentence on second slide, but there
11758  is text on the main transparency that goes in between them? You could try
11759  and insert vertical space of the right size.
11760  The better way is to use 
11761 \family sans
11762 InvisibleText
11763 \family default
11764  and 
11765 \family sans
11766 VisibleText
11767 \family default
11768 .
11769 \end_layout
11770
11771 \begin_layout Standard
11772 As their names imply, 
11773 \family sans
11774 InvisibleText
11775 \family default
11776  and 
11777 \family sans
11778 VisibleText
11779 \family default
11780  are two command-like paragraph environments that make all subsequent text
11781  invisible and visible, respectively.
11782  Note from section\InsetSpace ~
11783
11784 \begin_inset LatexCommand \ref{sec:slideQuirk}
11785
11786 \end_inset
11787
11788  that you don't place anything 
11789 \emph on
11790 into
11791 \emph default
11792  these two environments, however.
11793  When you create an 
11794 \family sans
11795 InvisibleText
11796 \family default
11797 , it inserts a centered, sky-blue label into the page reading 
11798 \begin_inset Quotes eld
11799 \end_inset
11800
11801 <Invisible Text Follows>
11802 \begin_inset Quotes erd
11803 \end_inset
11804
11805 .
11806  For paragraphs following this label, the parts of the 
11807 \family sans
11808 Slide
11809 \family default
11810  [or 
11811 \family sans
11812 Overlay
11813 \family default
11814 ; it doesn't matter which] where they would be contain instead blank space.
11815  
11816 \end_layout
11817
11818 \begin_layout Standard
11819 For 
11820 \family sans
11821 VisibleText
11822 \family default
11823 , the corresponding centered label is 
11824 \begin_inset Quotes eld
11825 \end_inset
11826
11827 <Visible Text Follows>
11828 \begin_inset Quotes erd
11829 \end_inset
11830
11831  in blazing green.
11832  Paragraphs following this label behave normally.
11833  Note that the beginning of a new 
11834 \family sans
11835 Slide
11836 \family default
11837
11838 \family sans
11839 Overlay
11840 \family default
11841 , or 
11842 \family sans
11843 Note
11844 \family default
11845  automatically shuts off an 
11846 \family sans
11847 InvisibleText
11848 \family default
11849 .
11850  It's therefore not necessary to use 
11851 \family sans
11852 VisibleText
11853 \family default
11854  at the end of a 
11855 \family sans
11856 Slide
11857 \family default
11858 .
11859 \end_layout
11860
11861 \begin_layout Standard
11862 By now, it should be obvious how to create overlay transparencies using
11863  the proper combination of 
11864 \family sans
11865 InvisibleText
11866 \family default
11867  and 
11868 \family sans
11869 VisibleText
11870 \family default
11871  on a 
11872 \family sans
11873 Slide
11874 \family default
11875  and 
11876 \family sans
11877 Overlay
11878 \family default
11879 :
11880 \end_layout
11881
11882 \begin_layout Enumerate
11883 Create a 
11884 \family sans
11885 Slide
11886 \family default
11887 , including everything that will appear on it, whether on the main slide
11888  or on the 
11889 \family sans
11890 Overlay
11891 \family default
11892 .
11893 \end_layout
11894
11895 \begin_layout Enumerate
11896 Before each figure or paragraph that will appear only on the 
11897 \family sans
11898 Overlay
11899 \family default
11900 , insert an 
11901 \family sans
11902 InvisibleText
11903 \family default
11904  environment.
11905  If necessary, insert a 
11906 \family sans
11907 VisibleText
11908 \family default
11909  environment after the 
11910 \family sans
11911 Overlay
11912 \family default
11913 -only text.
11914 \end_layout
11915
11916 \begin_layout Enumerate
11917 Start an 
11918 \family sans
11919 Overlay
11920 \family default
11921  immediately following the 
11922 \family sans
11923 Slide
11924 \family default
11925 .
11926 \end_layout
11927
11928 \begin_layout Enumerate
11929 Copy the contents of this 
11930 \family sans
11931 Slide
11932 \family default
11933  into the 
11934 \family sans
11935 Overlay
11936 \family default
11937 .
11938 \end_layout
11939
11940 \begin_layout Enumerate
11941 Within the 
11942 \family sans
11943 Overlay
11944 \family default
11945 , change all of the 
11946 \family sans
11947 InvisibleText
11948 \family default
11949  lines to 
11950 \family sans
11951 VisibleText
11952 \family default
11953  and vice-versa.
11954 \end_layout
11955
11956 \begin_layout Standard
11957 That's it.
11958  You've just made an 
11959 \family sans
11960 Overlay
11961 \family default
11962 .
11963 \end_layout
11964
11965 \begin_layout Standard
11966 There's one problem with the way I've designed the LyX 
11967 \family sans
11968 slides
11969 \family default
11970  class: you can't make text in the middle of a paragraph invisible, nor
11971  make text in the middle of an invisible paragraph visible again.
11972  To accomplish this feat, you'll need to use some inlined LaTeX codes.
11973 \begin_inset Foot
11974 status collapsed
11975
11976 \begin_layout Standard
11977 The commands of interest are: 
11978 \end_layout
11979
11980 \begin_layout Itemize
11981
11982 \family typewriter
11983 {
11984 \backslash
11985 invisible \SpecialChar \ldots{}
11986  }
11987 \end_layout
11988
11989 \begin_layout Itemize
11990
11991 \family typewriter
11992 {
11993 \backslash
11994 visible \SpecialChar \ldots{}
11995  }
11996 \end_layout
11997
11998 \begin_layout Standard
11999 \SpecialChar \ldots{}
12000 and need to be marked as TeX.
12001  The text whose 
12002 \begin_inset Quotes eld
12003 \end_inset
12004
12005 visibility
12006 \begin_inset Quotes erd
12007 \end_inset
12008
12009  you wish to change goes in between the brackets [and after the 
12010 \family typewriter
12011
12012 \backslash
12013 invisible
12014 \family default
12015  or 
12016 \family typewriter
12017
12018 \backslash
12019 visible
12020 \family default
12021  command].
12022  If you don't know how to mark text as TeX, see the apprpriate section of
12023  the 
12024 \emph on
12025 User's Guide
12026 \emph default
12027 .
12028 \end_layout
12029
12030 \end_inset
12031
12032
12033 \end_layout
12034
12035 \begin_layout Subsubsection
12036 Using 
12037 \family sans
12038 Note
12039 \family default
12040  with 
12041 \family sans
12042 Slide
12043 \family default
12044
12045 \begin_inset LatexCommand \label{sec:slideNote}
12046
12047 \end_inset
12048
12049
12050 \end_layout
12051
12052 \begin_layout Standard
12053 Like an 
12054 \family sans
12055 Overlay
12056 \family default
12057 , a 
12058 \family sans
12059 Note
12060 \family default
12061  is associated with a 
12062 \begin_inset Quotes eld
12063 \end_inset
12064
12065 parent
12066 \begin_inset Quotes erd
12067 \end_inset
12068
12069  
12070 \family sans
12071 Slide
12072 \family default
12073 .
12074  Here, too, the LyX 
12075 \family sans
12076 slides
12077 \family default
12078  class provides visual cues.
12079  The label for a 
12080 \family sans
12081 Note
12082 \family default
12083  is shorter than that of a 
12084 \family sans
12085 Slide
12086 \family default
12087  [yet longer than that of an 
12088 \family sans
12089 Overlay
12090 \family default
12091 ] and, like the label of an 
12092 \family sans
12093 Overlay
12094 \family default
12095  is shockingly magenta.
12096  Additionally, the printed 
12097 \family sans
12098 Note
12099 \family default
12100  has the page number of its 
12101 \begin_inset Quotes eld
12102 \end_inset
12103
12104 parent
12105 \begin_inset Quotes erd
12106 \end_inset
12107
12108  
12109 \family sans
12110 Slide
12111 \family default
12112 , appended by 
12113 \begin_inset Quotes eld
12114 \end_inset
12115
12116
12117 \family typewriter
12118 -
12119 \family default
12120 1
12121 \begin_inset Quotes erd
12122 \end_inset
12123
12124
12125 \begin_inset Quotes eld
12126 \end_inset
12127
12128
12129 \family typewriter
12130 -
12131 \family default
12132 2
12133 \begin_inset Quotes erd
12134 \end_inset
12135
12136
12137 \begin_inset Quotes eld
12138 \end_inset
12139
12140
12141 \family typewriter
12142 -
12143 \family default
12144 3
12145 \begin_inset Quotes erd
12146 \end_inset
12147
12148 , etc.
12149  You can have multiple 
12150 \family sans
12151 Note
12152 \family default
12153 s associated with a single 
12154 \family sans
12155 Slide
12156 \family default
12157 , and, as with 
12158 \family sans
12159 Slide
12160 \family default
12161  and 
12162 \family sans
12163 Overlay
12164 \family default
12165 , you'll probably want to break up long 
12166 \family sans
12167 Note
12168 \family default
12169 s so that they fit on a single sheet of paper.
12170 \end_layout
12171
12172 \begin_layout Standard
12173 The purpose of a 
12174 \family sans
12175 Note
12176 \family default
12177  is obvious: it contains anything additional you might want to say about
12178  a 
12179 \family sans
12180 Slide
12181 \family default
12182 .
12183  It could also be used as a sheet of reminders for a particular 
12184 \family sans
12185 Slide
12186 \family default
12187 .
12188  In the case of the latter, you might want to make use of time markers.
12189  Currently, the LyX 
12190 \family sans
12191 slides
12192 \family default
12193  class has no 
12194 \begin_inset Quotes eld
12195 \end_inset
12196
12197 native
12198 \begin_inset Quotes erd
12199 \end_inset
12200
12201  support for time markers, a 
12202 \noun on
12203 Sli
12204 \noun default
12205 TeX feature.
12206  So, you'll have to resort to using the LaTeX codes.
12207 \end_layout
12208
12209 \begin_layout Standard
12210 To use time markers, you'll need to specify the extra class option 
12211 \begin_inset Quotes eld
12212 \end_inset
12213
12214
12215 \family typewriter
12216 clock
12217 \family default
12218
12219 \begin_inset Quotes erd
12220 \end_inset
12221
12222  [see section\InsetSpace ~
12223
12224 \begin_inset LatexCommand \ref{sec:slidesetup}
12225
12226 \end_inset
12227
12228 ].
12229  This option turns on timing marks, which will appear in the lower-left-hand
12230  corner of every 
12231 \family sans
12232 Note
12233 \family default
12234  you generate.
12235  To set what appears in the time marker, you use the LaTeX commands 
12236 \begin_inset Quotes eld
12237 \end_inset
12238
12239
12240 \family typewriter
12241
12242 \backslash
12243 settime{}
12244 \family default
12245
12246 \begin_inset Quotes erd
12247 \end_inset
12248
12249  and 
12250 \begin_inset Quotes eld
12251 \end_inset
12252
12253
12254 \family typewriter
12255
12256 \backslash
12257 addtime{}
12258 \family default
12259
12260 \begin_inset Quotes erd
12261 \end_inset
12262
12263 .
12264  The arguments of both commands are time measured in seconds.
12265  
12266 \begin_inset Quotes eld
12267 \end_inset
12268
12269
12270 \family typewriter
12271
12272 \backslash
12273 settime{}
12274 \family default
12275
12276 \begin_inset Quotes erd
12277 \end_inset
12278
12279  sets the time marker to a given time.
12280  
12281 \begin_inset Quotes eld
12282 \end_inset
12283
12284
12285 \family typewriter
12286
12287 \backslash
12288 addtime{}
12289 \family default
12290
12291 \begin_inset Quotes erd
12292 \end_inset
12293
12294  increments the time marker by the specified amount.
12295  Using time markers and 
12296 \family sans
12297 Note
12298 \family default
12299 s in this fashion, you can remind yourself how much time to spend on a particula
12300
12301 \family sans
12302 Slide
12303 \family default
12304 .
12305 \end_layout
12306
12307 \begin_layout Standard
12308 There's one last feature to describe.
12309  Clearly, you'd like to print out all of your 
12310 \family sans
12311 Slide
12312 \family default
12313 s and 
12314 \family sans
12315 Overlay
12316 \family default
12317 s on transparencies while printing all of your 
12318 \family sans
12319 Note
12320 \family default
12321 s on plain paper.
12322  However, a 
12323 \family sans
12324 Note
12325 \family default
12326  
12327 \emph on
12328 must
12329 \emph default
12330  follow the 
12331 \family sans
12332 Slide
12333 \family default
12334  with which it is associated.
12335  What's a person to do?
12336 \end_layout
12337
12338 \begin_layout Standard
12339 Luckily, there are two LaTeX commands that allow you to select what to print
12340  out.
12341  Both must be placed into the preamble of your document.
12342  The command 
12343 \begin_inset Quotes eld
12344 \end_inset
12345
12346
12347 \family typewriter
12348
12349 \backslash
12350 onlyslides{
12351 \backslash
12352 slides}
12353 \family default
12354
12355 \begin_inset Quotes erd
12356 \end_inset
12357
12358  will cause the output to contain only the 
12359 \family sans
12360 Slide
12361 \family default
12362 s and 
12363 \family sans
12364 Overlay
12365 \family default
12366 s.
12367  Correspondingly, the command 
12368 \begin_inset Quotes eld
12369 \end_inset
12370
12371
12372 \family typewriter
12373
12374 \backslash
12375 onlynotes{
12376 \backslash
12377 notes}
12378 \family default
12379
12380 \begin_inset Quotes erd
12381 \end_inset
12382
12383  prevents the output of anything but 
12384 \family sans
12385 Note
12386 \family default
12387 s.
12388  I'd advise placing both commands in the preamble and initially comment
12389  both out.
12390  You can then preview your entire presentation as you write.
12391  When you're done writing, you can then uncomment one of the two to select
12392  what you want to print.
12393  I like to uncomment 
12394 \begin_inset Quotes eld
12395 \end_inset
12396
12397
12398 \family typewriter
12399
12400 \backslash
12401 onlyslides{
12402 \backslash
12403 slides}
12404 \family default
12405
12406 \begin_inset Quotes erd
12407 \end_inset
12408
12409  , print to a file with 
12410 \begin_inset Quotes eld
12411 \end_inset
12412
12413
12414 \family typewriter
12415 -slides
12416 \family default
12417
12418 \begin_inset Quotes erd
12419 \end_inset
12420
12421  in its name, comment it back out, then uncomment 
12422 \begin_inset Quotes eld
12423 \end_inset
12424
12425
12426 \family typewriter
12427
12428 \backslash
12429 onlynotes{
12430 \backslash
12431 notes}
12432 \family default
12433
12434 \begin_inset Quotes erd
12435 \end_inset
12436
12437  and print to a 
12438 \begin_inset Quotes eld
12439 \end_inset
12440
12441
12442 \family typewriter
12443 *-notes.ps
12444 \family default
12445
12446 \begin_inset Quotes erd
12447 \end_inset
12448
12449  file.
12450  I can then send either file to a printer, loading transparencies or plain
12451  paper as appropriate.
12452 \end_layout
12453
12454 \begin_layout Standard
12455 You can also provide other arguments to the 
12456 \begin_inset Quotes eld
12457 \end_inset
12458
12459
12460 \family typewriter
12461
12462 \backslash
12463 onlyslides{}
12464 \family default
12465
12466 \begin_inset Quotes erd
12467 \end_inset
12468
12469  and 
12470 \begin_inset Quotes eld
12471 \end_inset
12472
12473
12474 \family typewriter
12475
12476 \backslash
12477 onlynotes{}
12478 \family default
12479
12480 \begin_inset Quotes erd
12481 \end_inset
12482
12483  commands.
12484  See a good LaTeX book for details.
12485 \end_layout
12486
12487 \begin_layout Subsection
12488 The 
12489 \family sans
12490 slides
12491 \family default
12492  Class Template File
12493 \end_layout
12494
12495 \begin_layout Standard
12496 I have also provided a template file, 
12497 \begin_inset Quotes eld
12498 \end_inset
12499
12500
12501 \family typewriter
12502 slides.lyx
12503 \family default
12504
12505 \begin_inset Quotes erd
12506 \end_inset
12507
12508 , with the 
12509 \family sans
12510 slides
12511 \family default
12512  class.
12513  To use it, begin your new presentation with 
12514 \family sans
12515 \bar under
12516 F
12517 \bar default
12518 ile\SpecialChar \menuseparator
12519 New\InsetSpace ~
12520 from\InsetSpace ~
12521
12522 \bar under
12523 T
12524 \bar default
12525 emplate
12526 \family default
12527 .
12528  Your new LyX presentation file will contain an example 
12529 \family sans
12530 Slide
12531 \family default
12532  -- 
12533 \family sans
12534 Overlay
12535 \family default
12536  --
12537 \family sans
12538  Note
12539 \family default
12540  triplet.
12541  The 
12542 \family sans
12543 Slide
12544 \family default
12545  and 
12546 \family sans
12547 Overlay
12548 \family default
12549  additionally contain an example of the use of 
12550 \family sans
12551 InvisibleText
12552 \family default
12553  and 
12554 \family sans
12555 VisibleText
12556 \family default
12557 .
12558  Lastly, the preamble will contain:
12559 \end_layout
12560
12561 \begin_layout LyX-Code
12562 % Uncomment to print out only slides and overlays
12563 \end_layout
12564
12565 \begin_layout LyX-Code
12566 %
12567 \end_layout
12568
12569 \begin_layout LyX-Code
12570 %
12571 \backslash
12572 onlyslides{
12573 \backslash
12574 slides}
12575 \newline
12576  
12577 \end_layout
12578
12579 \begin_layout LyX-Code
12580 % Uncomment to print out only notes
12581 \end_layout
12582
12583 \begin_layout LyX-Code
12584 %
12585 \end_layout
12586
12587 \begin_layout LyX-Code
12588 %
12589 \backslash
12590 onlynotes{
12591 \backslash
12592 notes}
12593 \end_layout
12594
12595 \begin_layout Standard
12596 One final thing: I created this class to support the LaTeX2e 
12597 \begin_inset Quotes eld
12598 \end_inset
12599
12600
12601 \noun on
12602 Sli
12603 \noun default
12604 TeX emulation
12605 \begin_inset Quotes erd
12606 \end_inset
12607
12608  class, one of the built-in LaTeX2e classes.
12609  Neither I nor the rest of the LyX Team endorse or oppose the use of this
12610  built-in slide class.
12611  It's here if you want it or need it.
12612  There exist other LaTeX2e classes for creating presentations, such as the
12613  
12614 \family sans
12615 Foils
12616 \family default
12617  class [see section\InsetSpace ~
12618
12619 \begin_inset LatexCommand \ref{sec:foiltex}
12620
12621 \end_inset
12622
12623 ] or the 
12624 \begin_inset Quotes eld
12625 \end_inset
12626
12627
12628 \family typewriter
12629 seminar
12630 \family default
12631
12632 \begin_inset Quotes erd
12633 \end_inset
12634
12635  package [present on some TeX distributions].
12636  The latter is not yet supported under LyX.
12637 \begin_inset Foot
12638 status collapsed
12639
12640 \begin_layout Standard
12641 Perhaps you can take on the task\SpecialChar \ldots{}
12642
12643 \end_layout
12644
12645 \end_inset
12646
12647  I know nothing about these other classes.
12648  Try them out to see what sort of alternative they provide.
12649 \end_layout
12650
12651 \begin_layout Section
12652 Foils [aka 
12653 \family sans
12654 Foil
12655 \family default
12656 \noun on
12657 TeX
12658 \noun default
12659 ]
12660 \begin_inset LatexCommand \label{sec:foiltex}
12661
12662 \end_inset
12663
12664
12665 \end_layout
12666
12667 \begin_layout Standard
12668 by 
12669 \noun on
12670 Allan Rae
12671 \end_layout
12672
12673 \begin_layout Subsection
12674 Introduction
12675 \end_layout
12676
12677 \begin_layout Standard
12678 This section describes how to use LyX to make slides for overhead projectors.
12679  There are two document classes that can do this: the default slides class
12680  and the 
12681 \family sans
12682 Foil
12683 \family default
12684 TeX slides class.
12685  This section documents the latter.
12686 \end_layout
12687
12688 \begin_layout Standard
12689 I'm going to say this again, nice and clear, so that there's no misunderstanding
12690 :
12691 \end_layout
12692
12693 \begin_layout Standard
12694 \begin_inset VSpace bigskip
12695 \end_inset
12696
12697
12698 \end_layout
12699
12700 \begin_layout Standard
12701 \align center
12702
12703 \size large
12704 This section documents the class 
12705 \begin_inset Quotes eld
12706 \end_inset
12707
12708
12709 \family sans
12710 slides (FoilTeX)
12711 \family default
12712
12713 \begin_inset Quotes erd
12714 \end_inset
12715
12716  
12717 \emph on
12718 only.
12719 \end_layout
12720
12721 \begin_layout Standard
12722 \begin_inset VSpace bigskip
12723 \end_inset
12724
12725
12726 \end_layout
12727
12728 \begin_layout Standard
12729 If you're looking for the documentation for 
12730 \begin_inset Quotes eld
12731 \end_inset
12732
12733
12734 \family sans
12735 slides (default)
12736 \family default
12737
12738 \begin_inset Quotes erd
12739 \end_inset
12740
12741 , check out section\InsetSpace ~
12742
12743 \begin_inset LatexCommand \ref{sec:slitex}
12744
12745 \end_inset
12746
12747 .
12748  If your machine doesn't have the 
12749 \family sans
12750 foils 
12751 \family default
12752 class [
12753 \begin_inset Quotes eld
12754 \end_inset
12755
12756
12757 \family sans
12758 slides (FoilTeX)
12759 \family default
12760
12761 \begin_inset Quotes erd
12762 \end_inset
12763
12764 ] installed, you'll probably have to use the default 
12765 \family sans
12766 slides
12767 \family default
12768  class, which isn't quite as good as 
12769 \family sans
12770 foils.
12771 \end_layout
12772
12773 \begin_layout Standard
12774 The 
12775 \family sans
12776 foils
12777 \family default
12778  class is designed for use with version 2.1 of the 
12779 \family sans
12780 foils.cls
12781 \family default
12782  LaTeX class file which is now an integral part of LaTeX2e.
12783 \end_layout
12784
12785 \begin_layout Subsection
12786 Getting Started
12787 \end_layout
12788
12789 \begin_layout Standard
12790 Obviously, to use this document class, you need to select 
12791 \begin_inset Quotes eld
12792 \end_inset
12793
12794
12795 \family sans
12796 slides (FoilTeX)
12797 \family default
12798
12799 \begin_inset Quotes erd
12800 \end_inset
12801
12802  from the 
12803 \family sans
12804 \bar under
12805 C
12806 \bar default
12807 lass
12808 \family default
12809  entry in the 
12810 \family sans
12811 Document\InsetSpace ~
12812 Layout
12813 \family default
12814  dialog.
12815  There are some settings in the 
12816 \family sans
12817 Document\InsetSpace ~
12818 Layout
12819 \family default
12820  dialog that you should know about that are specific to this class:
12821 \end_layout
12822
12823 \begin_layout Itemize
12824 Don't change the options 
12825 \family sans
12826 Sides
12827 \family default
12828  and 
12829 \family sans
12830 Columns
12831 \family default
12832  on the 
12833 \family sans
12834 Document\InsetSpace ~
12835 Layout
12836 \family default
12837  dialog.
12838  They're ignored by the 
12839 \family sans
12840 foils
12841 \family default
12842  class.
12843 \end_layout
12844
12845 \begin_layout Itemize
12846 The default font size is 20pt with the other options being 17pt, 25pt and
12847  30pt.
12848 \end_layout
12849
12850 \begin_layout Itemize
12851 The default font is 
12852 \family sans
12853 sans
12854 \family default
12855  
12856 \family sans
12857 serif
12858 \family default
12859  but all math equations are still typeset in the usual roman font.
12860 \end_layout
12861
12862 \begin_layout Itemize
12863
12864 \family sans
12865 Foil
12866 \family default
12867 TeX supports A4 and Letter paper sizes as well as a special size for working
12868  with 35mm slides.
12869  It doesn't support A5, B5, legal or executive paper sizes.
12870 \end_layout
12871
12872 \begin_layout Itemize
12873 Don't bother changing the 
12874 \family sans
12875 Float Placement
12876 \family default
12877  settings because they are ignored anyway.
12878  All floats appear where they are defined in the text.
12879 \end_layout
12880
12881 \begin_layout Itemize
12882 The 
12883 \family sans
12884 \bar under
12885 P
12886 \bar default
12887 agestyle
12888 \family default
12889  setting behaves a bit differently for this class.
12890  
12891 \family sans
12892 Foil
12893 \family default
12894 TeX provides extensive footer and header capabilities including a user-defined
12895  logo.
12896  See section\InsetSpace ~
12897
12898 \begin_inset LatexCommand \ref{sec:foilfoot}
12899
12900 \end_inset
12901
12902  for more details.
12903  The title page is treated differently to all other pages in the document
12904  and is 
12905 \emph on
12906 always
12907 \emph default
12908  unnumbered and 
12909 \emph on
12910 always
12911 \emph default
12912  has the logo centered at the bottom of the page (if one is defined).
12913  The possible page style choices and what they do are as follows:
12914 \end_layout
12915
12916 \begin_deeper
12917 \begin_layout List
12918 \labelwidthstring MMMMMMM
12919
12920 \family sans
12921 \series bold
12922 empty
12923 \family default
12924 \series default
12925  The final output contains no page numbers, or other headers or footers
12926  (except footnotes of course).
12927  
12928 \end_layout
12929
12930 \begin_layout List
12931 \labelwidthstring MMMMMMM
12932
12933 \family sans
12934 \series bold
12935 plain
12936 \family default
12937 \series default
12938  The final output contains page numbers centered at the bottom of the page.
12939  No other headings or footers (other than footnotes).
12940 \end_layout
12941
12942 \begin_layout List
12943 \labelwidthstring MMMMMMM
12944
12945 \series bold
12946 foilheadings
12947 \series default
12948  Page numbers in lower right corner.
12949  Additional headers and footers are also shown.
12950  This is also the default.
12951 \end_layout
12952
12953 \begin_layout List
12954 \labelwidthstring MMMMMMM
12955
12956 \series bold
12957 fancy
12958 \series default
12959  Gives you access to the 
12960 \family sans
12961 fancyheadings
12962 \family default
12963  package although its use with 
12964 \family sans
12965 Foil
12966 \family default
12967 TeX is discouraged by the writer of the 
12968 \family sans
12969 Foil
12970 \family default
12971 TeX package because of some potential page layout clashes.
12972 \end_layout
12973
12974 \end_deeper
12975 \begin_layout Subsubsection
12976 Extra Options
12977 \end_layout
12978
12979 \begin_layout Standard
12980 The following options may be used in the extra class options in the 
12981 \family sans
12982 \bar under
12983 D
12984 \bar default
12985 ocument\SpecialChar \menuseparator
12986
12987 \bar under
12988 S
12989 \bar default
12990 ettings
12991 \family default
12992  dialog.
12993 \end_layout
12994
12995 \begin_layout List
12996 \labelwidthstring MMMMMMx
12997
12998 \series bold
12999 35mmSlide
13000 \series default
13001  This sets up the page layout for 7.33in by 11in paper, which is about the
13002  same aspect ratio as a 35mm slide, making it a bit easier to work with
13003  this medium.
13004 \end_layout
13005
13006 \begin_layout List
13007 \labelwidthstring MMMMMMx
13008
13009 \series bold
13010 headrule
13011 \series default
13012  Places a rule across the page below the header on every page except the
13013  title page.
13014 \end_layout
13015
13016 \begin_layout List
13017 \labelwidthstring MMMMMMx
13018
13019 \series bold
13020 footrule
13021 \series default
13022  Places a rule across the page above the footer on every page except the
13023  title page.
13024 \end_layout
13025
13026 \begin_layout List
13027 \labelwidthstring MMMMMMx
13028
13029 \series bold
13030 dvips
13031 \series default
13032  This is automatically set each time you create a new 
13033 \family sans
13034 foils
13035 \family default
13036  document.
13037  This option tells 
13038 \family sans
13039 Foil
13040 \family default
13041 TeX to use the dvips driver to rotate those pages that are set as landscape
13042  foils.
13043 \end_layout
13044
13045 \begin_layout List
13046 \labelwidthstring MMMMMMx
13047
13048 \series bold
13049 landscape
13050 \series default
13051  Simply changes the page dimensions to those of a landscape page but doesn't
13052  do any rotation.
13053  Thus if you use this option you need to use an external program to rotate
13054  each page or feed your paper through your printer as landscape.
13055  Note that this option effectively reverses the roles of the 
13056 \family sans
13057 Foilhead
13058 \family default
13059  and 
13060 \family sans
13061 Rotatefoilhead
13062 \family default
13063  environments (don't worry these are described in the next section).
13064 \end_layout
13065
13066 \begin_layout List
13067 \labelwidthstring MMMMMMx
13068
13069 \series bold
13070 leqno
13071 \series default
13072  Equation numbers on the left.
13073 \end_layout
13074
13075 \begin_layout List
13076 \labelwidthstring MMMMMMx
13077
13078 \series bold
13079 fleqn
13080 \series default
13081  Flush-left equations.
13082 \end_layout
13083
13084 \begin_layout Subsection
13085 Supported Environments
13086 \end_layout
13087
13088 \begin_layout Standard
13089 Most of the environments commonly supported in other classes are also supported
13090  by the 
13091 \family sans
13092 foils
13093 \family default
13094  class.
13095  There are several additional environments provided by 
13096 \family sans
13097 Foil
13098 \family default
13099 TeX as well as a couple added by LyX.
13100  The following environments are shared with other classes:
13101 \end_layout
13102
13103 \begin_layout Standard
13104 \begin_inset ERT
13105 status inlined
13106
13107 \begin_layout Standard
13108
13109
13110 \backslash
13111 begin{multicols}{2}
13112 \end_layout
13113
13114 \end_inset
13115
13116
13117 \end_layout
13118
13119 \begin_layout Itemize
13120
13121 \family sans
13122 Standard
13123 \end_layout
13124
13125 \begin_layout Itemize
13126
13127 \family sans
13128 Itemize
13129 \end_layout
13130
13131 \begin_layout Itemize
13132
13133 \family sans
13134 Enumerate
13135 \end_layout
13136
13137 \begin_layout Itemize
13138
13139 \family sans
13140 Description
13141 \end_layout
13142
13143 \begin_layout Itemize
13144
13145 \family sans
13146 List
13147 \end_layout
13148
13149 \begin_layout Itemize
13150
13151 \family sans
13152 LyX-Code
13153 \end_layout
13154
13155 \begin_layout Itemize
13156
13157 \family sans
13158 Verse
13159 \end_layout
13160
13161 \begin_layout Itemize
13162
13163 \family sans
13164 Quote
13165 \end_layout
13166
13167 \begin_layout Itemize
13168
13169 \family sans
13170 Quotation
13171 \end_layout
13172
13173 \begin_layout Itemize
13174
13175 \family sans
13176 Title
13177 \end_layout
13178
13179 \begin_layout Itemize
13180
13181 \family sans
13182 Author
13183 \end_layout
13184
13185 \begin_layout Itemize
13186
13187 \family sans
13188 Date
13189 \end_layout
13190
13191 \begin_layout Itemize
13192
13193 \family sans
13194 Abstract
13195 \end_layout
13196
13197 \begin_layout Itemize
13198
13199 \family sans
13200 Bibliography
13201 \end_layout
13202
13203 \begin_layout Itemize
13204
13205 \family sans
13206 Address
13207 \end_layout
13208
13209 \begin_layout Itemize
13210
13211 \family sans
13212 RightAddress
13213 \end_layout
13214
13215 \begin_layout Itemize
13216
13217 \family sans
13218 Caption
13219 \end_layout
13220
13221 \begin_layout Itemize
13222
13223 \family sans
13224 Comment
13225 \end_layout
13226
13227 \begin_layout Standard
13228 \begin_inset ERT
13229 status inlined
13230
13231 \begin_layout Standard
13232
13233
13234 \backslash
13235 end{multicols}
13236 \end_layout
13237
13238 \end_inset
13239
13240
13241 \end_layout
13242
13243 \begin_layout Standard
13244 That is, all the major environments apart from the sectioning environments.
13245  Since foils are essentially self-contained sections, with a title and body,
13246  
13247 \family sans
13248 Foil
13249 \family default
13250 TeX provides specific commands for starting new foils and these are:
13251 \end_layout
13252
13253 \begin_layout Itemize
13254
13255 \family sans
13256 Foilhead
13257 \end_layout
13258
13259 \begin_layout Itemize
13260
13261 \family sans
13262 Rotatefoilhead
13263 \end_layout
13264
13265 \begin_layout Standard
13266 LyX also provides slightly modified versions of these two environments called:
13267 \end_layout
13268
13269 \begin_layout Itemize
13270
13271 \family sans
13272 ShortFoilhead
13273 \end_layout
13274
13275 \begin_layout Itemize
13276
13277 \family sans
13278 ShortRotatefoilhead
13279 \end_layout
13280
13281 \begin_layout Standard
13282 and the differences will be explained in the next section.
13283 \end_layout
13284
13285 \begin_layout Standard
13286 Since foils are often used in presenting ideas or new theorems and such
13287  
13288 \family sans
13289 Foil
13290 \family default
13291 TeX also provides a comprehensive box of goodies for presenting them:
13292 \end_layout
13293
13294 \begin_layout Standard
13295 \begin_inset ERT
13296 status inlined
13297
13298 \begin_layout Standard
13299
13300
13301 \backslash
13302 begin{multicols}{2}
13303 \end_layout
13304
13305 \end_inset
13306
13307
13308 \end_layout
13309
13310 \begin_layout Itemize
13311
13312 \family sans
13313 Theorem
13314 \end_layout
13315
13316 \begin_layout Itemize
13317
13318 \family sans
13319 Lemma
13320 \end_layout
13321
13322 \begin_layout Itemize
13323
13324 \family sans
13325 Corollary
13326 \end_layout
13327
13328 \begin_layout Itemize
13329
13330 \family sans
13331 Proposition
13332 \end_layout
13333
13334 \begin_layout Itemize
13335
13336 \family sans
13337 Definition
13338 \end_layout
13339
13340 \begin_layout Itemize
13341
13342 \family sans
13343 Proof
13344 \end_layout
13345
13346 \begin_layout Itemize
13347
13348 \family sans
13349 Theorem*
13350 \end_layout
13351
13352 \begin_layout Itemize
13353
13354 \family sans
13355 Lemma*
13356 \end_layout
13357
13358 \begin_layout Itemize
13359
13360 \family sans
13361 Corollary*
13362 \end_layout
13363
13364 \begin_layout Itemize
13365
13366 \family sans
13367 Proposition*
13368 \end_layout
13369
13370 \begin_layout Itemize
13371
13372 \family sans
13373 Definition*
13374 \end_layout
13375
13376 \begin_layout Standard
13377 \begin_inset ERT
13378 status inlined
13379
13380 \begin_layout Standard
13381
13382
13383 \backslash
13384 end{multicols}
13385 \end_layout
13386
13387 \end_inset
13388
13389
13390 \end_layout
13391
13392 \begin_layout Standard
13393 The starred versions are unnumbered while the unstarred versions are numbered.
13394  There are also two list environments added by LyX and these are:
13395 \end_layout
13396
13397 \begin_layout Itemize
13398
13399 \family sans
13400 TickList
13401 \end_layout
13402
13403 \begin_layout Itemize
13404
13405 \family sans
13406 CrossList
13407 \end_layout
13408
13409 \begin_layout Standard
13410
13411 \family sans
13412 Foil
13413 \family default
13414 TeX provides some powerful header and footer capabilities that are best
13415  set in the preamble although they may be set at any point in a document.
13416  If you want to change these settings in your document the best place to
13417  do so is at the very top of a foil, 
13418 \emph on
13419 i.e.
13420
13421 \emph default
13422  straight after the foilhead.
13423 \end_layout
13424
13425 \begin_layout Standard
13426 For this purpose, the following command styles are provided [
13427 \shape smallcaps
13428 Martin Vermeer
13429 \shape default
13430 ]:
13431 \end_layout
13432
13433 \begin_layout Standard
13434 \begin_inset ERT
13435 status inlined
13436
13437 \begin_layout Standard
13438
13439
13440 \backslash
13441 begin{multicols}{2}
13442 \end_layout
13443
13444 \end_inset
13445
13446
13447 \end_layout
13448
13449 \begin_layout Itemize
13450
13451 \family sans
13452 My\InsetSpace ~
13453 Logo
13454 \end_layout
13455
13456 \begin_layout Itemize
13457
13458 \family sans
13459 Restriction
13460 \end_layout
13461
13462 \begin_layout Itemize
13463
13464 \family sans
13465 Right\InsetSpace ~
13466 Footer
13467 \end_layout
13468
13469 \begin_layout Itemize
13470
13471 \family sans
13472 Right\InsetSpace ~
13473 Header
13474 \end_layout
13475
13476 \begin_layout Itemize
13477
13478 \family sans
13479 Left\InsetSpace ~
13480 Header
13481 \end_layout
13482
13483 \begin_deeper
13484 \begin_layout Standard
13485 \InsetSpace ~
13486
13487 \end_layout
13488
13489 \end_deeper
13490 \begin_layout Standard
13491 \begin_inset ERT
13492 status inlined
13493
13494 \begin_layout Standard
13495
13496
13497 \backslash
13498 end{multicols}
13499 \end_layout
13500
13501 \end_inset
13502
13503
13504 \end_layout
13505
13506 \begin_layout Standard
13507 There are also a few commands provided by 
13508 \family sans
13509 Foil
13510 \family default
13511 TeX that aren't directly supported by LyX but I'll tell you what they do
13512  and how to use them in section\InsetSpace ~
13513
13514 \begin_inset LatexCommand \ref{sec:unsuppfoils}
13515
13516 \end_inset
13517
13518 .
13519 \end_layout
13520
13521 \begin_layout Subsection
13522 Building a Set of Foils
13523 \end_layout
13524
13525 \begin_layout Standard
13526 This section will give a simple introduction to using the different environments
13527  to build a set of foils.
13528  If you want to see an example set of foils take a look at the 
13529 \family typewriter
13530 Foils.lyx
13531 \family default
13532  file accessible from the 
13533 \family sans
13534 \bar under
13535 F
13536 \bar default
13537 ile\SpecialChar \menuseparator
13538
13539 \bar under
13540 O
13541 \bar default
13542 pen\SpecialChar \ldots{}
13543
13544 \family default
13545  dialog under the 
13546 \family sans
13547 Examples
13548 \family default
13549  button.
13550  
13551 \end_layout
13552
13553 \begin_layout Subsubsection
13554 Give It a Title Page
13555 \end_layout
13556
13557 \begin_layout Standard
13558 Unlike other classes that provide 
13559 \family sans
13560 Title
13561 \family default
13562
13563 \family sans
13564 Author
13565 \family default
13566
13567 \family sans
13568 Date
13569 \family default
13570  and 
13571 \family sans
13572 Abstract
13573 \family default
13574  environments, 
13575 \family sans
13576 foils
13577 \family default
13578  creates the title on a page of its own.
13579  If you leave out the 
13580 \family sans
13581 Date
13582 \family default
13583  environment LaTeX will substitute the current date (every time you regenerate
13584  the output).
13585 \end_layout
13586
13587 \begin_layout Subsubsection
13588 Start a New Foil
13589 \end_layout
13590
13591 \begin_layout Standard
13592 As I mentioned earlier, there are four ways of starting a new foil.
13593  For portrait foils you should use 
13594 \family sans
13595 Foilhead
13596 \family default
13597  or 
13598 \family sans
13599 ShortFoilhead.
13600
13601 \family default
13602  The difference between these two environments is the amount of space between
13603  the title of the foil (the foilhead) and the body of the foil.
13604 \end_layout
13605
13606 \begin_layout Standard
13607 Landscape foils are generated using the 
13608 \family sans
13609 Rotatefoilhead
13610 \family default
13611  and 
13612 \family sans
13613 ShortRotatefoilhead
13614 \family default
13615  environments.
13616  Again the only difference is the spacing between foilhead and body.
13617  Both of the short versions have 0.5 inches less separation between the foilhead
13618  and the body.
13619  
13620 \end_layout
13621
13622 \begin_layout Standard
13623 One problem with the support for landscape foils is the requirement that
13624  you have to use the 
13625 \family typewriter
13626 dvips
13627 \family default
13628  driver to generate the PostScript® output otherwise the foils won't be
13629  rotated.
13630  It is possible to get landscape foils even if you haven't got the 
13631 \family typewriter
13632 dvips
13633 \family default
13634  driver provided you can feed your foils sideways through your printer ;-)
13635 \end_layout
13636
13637 \begin_layout Subsubsection
13638 Theorems, Lemmas, Proofs and more
13639 \end_layout
13640
13641 \begin_layout Standard
13642 Due to a small bug in LyX you can't have two of the same type of these environme
13643 nts directly following each other.
13644  They must be separated by something.
13645  If you try, you will just be extending the previous environment as if you
13646  had merged the two environments together.
13647  So, how do you get around this problem? The simplest option is to insert
13648  some text between the two environments or add a 
13649 \family sans
13650 LaTeX
13651 \family default
13652  environment between the two with just a 
13653 \begin_inset Quotes eld
13654 \end_inset
13655
13656
13657 \family typewriter
13658 %
13659 \family default
13660
13661 \begin_inset Quotes erd
13662 \end_inset
13663
13664  in it.
13665  This will force LyX to produce two separate environments and hence the
13666  correct LaTeX output.
13667  An example is provided in the example file included with the LyX distribution.
13668  Remember, this problem only occurs if you are trying to place two of the
13669  same type of theorem-like environments one directly after the other.
13670 \end_layout
13671
13672 \begin_layout Subsubsection
13673 Lists
13674 \end_layout
13675
13676 \begin_layout Standard
13677 You get all the commonly supported list styles found in other classes as
13678  well as two new ones.
13679  I'll only describe the new ones here.
13680  If you want to find out more about the other list environments check out
13681  the 
13682 \emph on
13683 User's Guide.
13684
13685 \emph default
13686  If you intend to use itemized lists you might also want to read about the
13687  
13688 \family sans
13689 Itemize\InsetSpace ~
13690 Bullet\InsetSpace ~
13691 Selection
13692 \family default
13693  dialog described above in section\InsetSpace ~
13694
13695 \begin_inset LatexCommand \ref{sec:bullet}
13696
13697 \end_inset
13698
13699 .
13700 \end_layout
13701
13702 \begin_layout Standard
13703 The two new list styles, 
13704 \family sans
13705 TickList 
13706 \family default
13707 and 
13708 \family sans
13709 CrossList
13710 \family default
13711 , are designed to make it easier for you to create lists of do's and don'ts
13712  or right and wrong by providing dedicated environments that use a tick
13713  or a cross as the label of the list.
13714  These lists are in fact dedicated variants of the 
13715 \family sans
13716 Itemize
13717 \family default
13718  environment.
13719  They do however require that you have the 
13720 \family typewriter
13721 psnfss
13722 \family default
13723  packages installed.
13724 \end_layout
13725
13726 \begin_layout Subsubsection
13727 Figures and Tables
13728 \end_layout
13729
13730 \begin_layout Standard
13731
13732 \family sans
13733 Foil
13734 \family default
13735 TeX redefines the floating tables and figures so that they appear exactly
13736  where they are in the text rather than pushing them to the top of the page
13737  or to some user specified location.
13738  In fact if you change the float placement settings they are simply ignored.
13739 \end_layout
13740
13741 \begin_layout Subsubsection
13742 Page Headers and Footers
13743 \begin_inset LatexCommand \label{sec:foilfoot}
13744
13745 \end_inset
13746
13747
13748 \end_layout
13749
13750 \begin_layout Standard
13751
13752 \family sans
13753 My\InsetSpace ~
13754 Logo
13755 \family default
13756  and 
13757 \family sans
13758 Restriction
13759 \family default
13760  are two commands used to control the left-footer text string.
13761  The first is meant to allow you to include a graphic logo on your foils
13762  and defaults to 
13763 \begin_inset Quotes eld
13764 \end_inset
13765
13766 -Typeset by 
13767 \family sans
13768 Foil
13769 \family default
13770 TeX-
13771 \begin_inset Quotes erd
13772 \end_inset
13773
13774 .
13775  While the second is meant to provide a classification for the audience,
13776  
13777 \emph on
13778 e.g.
13779
13780 \emph default
13781  Confidential.
13782  It is empty by default.
13783 \end_layout
13784
13785 \begin_layout Standard
13786 The remaining page corners can be filled by
13787 \family sans
13788  Right\InsetSpace ~
13789 Footer
13790 \family default
13791  (which defaults to page numbers), 
13792 \family sans
13793 Right\InsetSpace ~
13794 Header
13795 \family default
13796  (top right) and 
13797 \family sans
13798 Left\InsetSpace ~
13799 Header
13800 \family default
13801  (top left).
13802 \end_layout
13803
13804 \begin_layout Subsection
13805 Unsupported 
13806 \family sans
13807 Foil
13808 \family default
13809 TeX Goodies
13810 \begin_inset LatexCommand \label{sec:unsuppfoils}
13811
13812 \end_inset
13813
13814
13815 \end_layout
13816
13817 \begin_layout Standard
13818 All the commands mentioned below need to be set in a 
13819 \family sans
13820 LaTeX
13821 \family default
13822  environment or as 
13823 \family sans
13824 TeX
13825 \family default
13826  within another environment.
13827 \end_layout
13828
13829 \begin_layout Subsubsection
13830 Lengths
13831 \end_layout
13832
13833 \begin_layout Standard
13834 All lengths are adjusted using the 
13835 \family typewriter
13836
13837 \backslash
13838 setlength{
13839 \family default
13840 \emph on
13841 lengthname
13842 \family typewriter
13843 \emph default
13844 }{
13845 \family default
13846 \emph on
13847 newlength
13848 \family typewriter
13849 \emph default
13850 }
13851 \family default
13852  command.
13853  Where 
13854 \emph on
13855 lengthname
13856 \emph default
13857  should be replaced by the name given to the length you want to change and
13858  
13859 \emph on
13860 newlength
13861 \emph default
13862  is the length value.
13863  All lengths should be specified in units of length such as inches (
13864 \family typewriter
13865 in
13866 \family default
13867 ), millimeters (
13868 \family typewriter
13869 mm
13870 \family default
13871 ) or points (
13872 \family typewriter
13873 pt
13874 \family default
13875 ) or relative to some document or font-based length such as 
13876 \family typewriter
13877
13878 \backslash
13879 textwidth
13880 \family default
13881 .
13882  
13883 \end_layout
13884
13885 \begin_layout Standard
13886 It's possible to change the spacing between a foilhead and the body of the
13887  foil by adjusting the length specified by 
13888 \family typewriter
13889
13890 \backslash
13891 foilheadskip
13892 \family default
13893 .
13894  For example, to make 
13895 \emph on
13896 all
13897 \emph default
13898  foilheads 0.5 inches closer to their bodies put the following in the preamble:
13899  
13900 \family typewriter
13901
13902 \backslash
13903 setlength{
13904 \backslash
13905 foilheadskip}{-0.5in}
13906 \end_layout
13907
13908 \begin_layout Standard
13909 The spacings around floats can be adjusted by setting these lengths:
13910 \end_layout
13911
13912 \begin_layout List
13913 \labelwidthstring MMMMMMMMMMM
13914
13915 \family typewriter
13916
13917 \backslash
13918 abovefloatskip 
13919 \family default
13920 Separation between the text and the top of the float
13921 \end_layout
13922
13923 \begin_layout List
13924 \labelwidthstring MMMMMMMMMMM
13925
13926 \family typewriter
13927
13928 \backslash
13929 abovecaptionskip 
13930 \family default
13931 Separation between the float and the caption
13932 \end_layout
13933
13934 \begin_layout List
13935 \labelwidthstring MMMMMMMMMMM
13936
13937 \family typewriter
13938
13939 \backslash
13940 belowcaptionskip 
13941 \family default
13942 Separation between the caption and the following text
13943 \end_layout
13944
13945 \begin_layout List
13946 \labelwidthstring MMMMMMMMMMM
13947
13948 \family typewriter
13949
13950 \backslash
13951 captionwidth
13952 \family default
13953  You can make the captions narrower than the surrounding text by adjusting
13954  this length.
13955  Best done relative to 
13956 \family typewriter
13957
13958 \backslash
13959 textwidth
13960 \family default
13961 .
13962 \end_layout
13963
13964 \begin_layout Standard
13965 There are also several title page related lengths that you may find useful
13966  if you have a long title or several authors:
13967 \end_layout
13968
13969 \begin_layout List
13970 \labelwidthstring MMMMMMMMMMM
13971
13972 \family typewriter
13973
13974 \backslash
13975 abovetitleskip
13976 \family default
13977  Separation from headers to 
13978 \family sans
13979 Title
13980 \end_layout
13981
13982 \begin_layout List
13983 \labelwidthstring MMMMMMMMMMM
13984
13985 \family typewriter
13986
13987 \backslash
13988 titleauthorskip
13989 \family default
13990  between 
13991 \family sans
13992 Title
13993 \family default
13994  and 
13995 \family sans
13996 Author
13997 \family default
13998  environments
13999 \end_layout
14000
14001 \begin_layout List
14002 \labelwidthstring MMMMMMMMMMM
14003
14004 \family typewriter
14005
14006 \backslash
14007 authorauthorskip
14008 \family default
14009  between multiple 
14010 \family sans
14011 Author
14012 \family default
14013  lines
14014 \end_layout
14015
14016 \begin_layout List
14017 \labelwidthstring MMMMMMMMMMM
14018
14019 \family typewriter
14020
14021 \backslash
14022 authordateskip
14023 \family default
14024  between the 
14025 \family sans
14026 Author
14027 \family default
14028  and the 
14029 \family sans
14030 Date
14031 \end_layout
14032
14033 \begin_layout List
14034 \labelwidthstring MMMMMMMMMMM
14035
14036 \family typewriter
14037
14038 \backslash
14039 dateabstractskip
14040 \family default
14041  between the 
14042 \family sans
14043 Date
14044 \family default
14045  and the 
14046 \family sans
14047 Abstract
14048 \end_layout
14049
14050 \begin_layout Standard
14051 The last length related command affects all the list environments.
14052  If you place
14053 \family typewriter
14054  
14055 \backslash
14056 zerolistvertdimens
14057 \family default
14058  
14059 \emph on
14060 inside
14061 \emph default
14062  a list environment then all the vertical spacing between the list items
14063  is removed.
14064  Note that this is a command not a length so it doesn't require 
14065 \family typewriter
14066
14067 \backslash
14068 setlength
14069 \family default
14070  like the stuff mentioned above.
14071 \end_layout
14072
14073 \begin_layout Subsubsection
14074 Headers and Footers
14075 \end_layout
14076
14077 \begin_layout Standard
14078 The 
14079 \family typewriter
14080
14081 \backslash
14082 LogoOn
14083 \family default
14084  and 
14085 \family typewriter
14086
14087 \backslash
14088 LogoOff
14089 \family default
14090  commands control whether the logo in the 
14091 \family sans
14092 MyLogo
14093 \family default
14094  definition appear on a given page.
14095  If you put 
14096 \family typewriter
14097
14098 \backslash
14099 LogoOff
14100 \family default
14101  in the preamble then none of the foils will have the logo on them.
14102  If you don't want the logo on a particular page place the 
14103 \family typewriter
14104
14105 \backslash
14106 LogoOff
14107 \family default
14108  directly after the foilhead of that page and the 
14109 \family typewriter
14110
14111 \backslash
14112 LogoOn
14113 \family default
14114  directly after the next foilhead.
14115 \end_layout
14116
14117 \begin_layout Standard
14118 If you decide to use the 
14119 \family sans
14120 fancy
14121 \family default
14122  page style setting in the 
14123 \family sans
14124 Document\InsetSpace ~
14125 Layout
14126 \family default
14127  dialog you should probably add 
14128 \family typewriter
14129
14130 \backslash
14131 let
14132 \backslash
14133 headwidth
14134 \backslash
14135 textwidth
14136 \family default
14137  to your preamble so headers and footers on landscape pages are correctly
14138  placed when rotated.
14139  This is due to some clashes between the page layouts provided by the 
14140 \family sans
14141 fancyheadings
14142 \family default
14143  package and the 
14144 \family sans
14145 foils
14146 \family default
14147  class.
14148 \end_layout
14149
14150 \begin_layout Section
14151 Latex8 (IEEE Conference Papers)
14152 \end_layout
14153
14154 \begin_layout Standard
14155 by 
14156 \noun on
14157 Allan Rae
14158 \end_layout
14159
14160 \begin_layout Subsection
14161 Introduction
14162 \end_layout
14163
14164 \begin_layout Standard
14165 Since this class is specifically for writing submissions to IEEE sponsored
14166  conferences I strongly recommend that you get a copy of their Authors Kit.
14167  The 
14168 \family sans
14169 latex.sty
14170 \family default
14171  package and associated bibliography style file is included in the kit.
14172  The Authors Kit is usually sent out by email once your initial submission
14173  has been accepted.
14174  There is a lot of useful information in the Authors Kit explaining formatting
14175  restrictions and so on and I will assume you have read this since that
14176  means I don't have to repeat it all here.
14177 \end_layout
14178
14179 \begin_layout Subsection
14180 Getting Started
14181 \end_layout
14182
14183 \begin_layout Standard
14184 [AR\SpecialChar \@.
14185  more to come]
14186 \end_layout
14187
14188 \begin_layout Subsection
14189 Supported Environments
14190 \end_layout
14191
14192 \begin_layout Itemize
14193
14194 \family sans
14195 Standard
14196 \end_layout
14197
14198 \begin_layout Itemize
14199
14200 \family sans
14201 Title
14202 \end_layout
14203
14204 \begin_layout Itemize
14205
14206 \family sans
14207 Author
14208 \end_layout
14209
14210 \begin_layout Itemize
14211
14212 \family sans
14213 E-mail
14214 \end_layout
14215
14216 \begin_layout Itemize
14217
14218 \family sans
14219 Affiliation
14220 \end_layout
14221
14222 \begin_layout Itemize
14223
14224 \family sans
14225 Abstract
14226 \end_layout
14227
14228 \begin_layout Itemize
14229
14230 \family sans
14231 Section
14232 \end_layout
14233
14234 \begin_layout Itemize
14235
14236 \family sans
14237 SubSection
14238 \end_layout
14239
14240 \begin_layout Itemize
14241
14242 \family sans
14243 Caption
14244 \end_layout
14245
14246 \begin_layout Subsection
14247 Differences Between Screen and Paper
14248 \end_layout
14249
14250 \begin_layout Standard
14251 There are slight differences in appearance mainly with the presentation
14252  of section counters.
14253  On screen the trailing period of the section counter is missing but it
14254  will appear in the output so don't let this worry you.
14255 \end_layout
14256
14257 \begin_layout Section
14258 Hollywood (Hollywood spec scripts)
14259 \end_layout
14260
14261 \begin_layout Standard
14262 by 
14263 \shape smallcaps
14264 Garst Reese
14265 \end_layout
14266
14267 \begin_layout Subsection
14268 Introduction
14269 \end_layout
14270
14271 \begin_layout Standard
14272 Getting the format of a Hollywood script right is a 
14273 \begin_inset Quotes eld
14274 \end_inset
14275
14276 rite of passage.
14277 \begin_inset Quotes erd
14278 \end_inset
14279
14280  It is designed to make the readers focus on content and to be easy and
14281  familiar for the actors to read.
14282  Each page of a script should be one minute of film.
14283  Nothing goes in a script that you cannot see or hear on screen.
14284  The courier 12 pt font should be used throughout.
14285  No italics.
14286 \end_layout
14287
14288 \begin_layout Subsection
14289 Special problems
14290 \end_layout
14291
14292 \begin_layout Standard
14293 Speakers' lines should NEVER break in mid-sentence.
14294  If a speaker's lines continue over a page break, repeat the 
14295 \family sans
14296 Speaker
14297 \family default
14298  title followed by (Cont'd).
14299 \end_layout
14300
14301 \begin_layout Subsection
14302 Special features
14303 \end_layout
14304
14305 \begin_layout Standard
14306 Insert the 
14307 \family sans
14308 Speaker
14309 \family default
14310  names as labels then cross-reference the label to insert the name.
14311  The cross-reference dialog will show the current cast of characters.
14312  You can use this to insert the speaker name in narratives also.
14313 \end_layout
14314
14315 \begin_layout Subsection
14316 Paper size and Margins
14317 \end_layout
14318
14319 \begin_layout Standard
14320 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
14321 \end_layout
14322
14323 \begin_layout Subsection
14324 Environments
14325 \end_layout
14326
14327 \begin_layout Standard
14328 The following environments are available.
14329  You can use hollywood.bind to get the bind keys shown at the right.
14330 \end_layout
14331
14332 \begin_layout Itemize
14333
14334 \family sans
14335 Standard
14336 \newline
14337
14338 \family default
14339 Used where nothing else works.
14340  Try to avoid it.
14341 \end_layout
14342
14343 \begin_layout Itemize
14344
14345 \family sans
14346 FADE_IN
14347 \family default
14348 :
14349 \hfill
14350
14351 \family sans
14352 M-z S-I
14353 \family default
14354
14355 \newline
14356 Usually followed by something like 
14357 \begin_inset Quotes eld
14358 \end_inset
14359
14360 on Sally waking up.
14361 \begin_inset Quotes erd
14362 \end_inset
14363
14364
14365 \end_layout
14366
14367 \begin_layout Itemize
14368
14369 \family sans
14370 INT:
14371 \hfill
14372 M-z i
14373 \newline
14374
14375 \family default
14376 Introduces a new INTERIOR camera set-up.
14377  Always followed by DAY or NIGHT, or something similar to define the lighting
14378  required.
14379  Everthing on this line in CAPS.
14380 \end_layout
14381
14382 \begin_layout Itemize
14383
14384 \family sans
14385 EXT:
14386 \hfill
14387 M-z e
14388 \newline
14389
14390 \family default
14391 Introduces a new EXTERIOR camera set-up.
14392  Everthing on this line in CAPS.
14393 \end_layout
14394
14395 \begin_layout Itemize
14396
14397 \family sans
14398 Speaker
14399 \hfill
14400 M-z s
14401 \newline
14402
14403 \family default
14404 The character speaking.
14405 \end_layout
14406
14407 \begin_layout Itemize
14408
14409 \family sans
14410 Parenthetical
14411 \hfill
14412 M-z p
14413 \newline
14414
14415 \family default
14416 Instructions to the speaker.
14417  The () are automatically inserted, but only the ( will show in LyX.
14418  Both will be printed.
14419 \end_layout
14420
14421 \begin_layout Itemize
14422
14423 \family sans
14424 Dialogue
14425 \hfill
14426 M-z d
14427 \newline
14428
14429 \family default
14430 What the 
14431 \family sans
14432 Speaker
14433 \family default
14434  says.
14435 \end_layout
14436
14437 \begin_layout Itemize
14438
14439 \family sans
14440 Transition
14441 \hfill
14442 M-z t
14443 \newline
14444
14445 \family default
14446 Camera movement instruction.
14447  e.g.
14448  CUT TO:
14449 \end_layout
14450
14451 \begin_layout Itemize
14452
14453 \family sans
14454 FADE OUT:
14455 \hfill
14456 M-z S-I
14457 \end_layout
14458
14459 \begin_layout Itemize
14460
14461 \family sans
14462 Author
14463 \hfill
14464 M-z S-A
14465 \end_layout
14466
14467 \begin_layout Itemize
14468
14469 \family sans
14470 Title
14471 \hfill
14472 M-z S-T
14473 \end_layout
14474
14475 \begin_layout Itemize
14476
14477 \family sans
14478 Right_Address
14479 \hfill
14480 M-z r
14481 \end_layout
14482
14483 \begin_layout Subsection
14484 Script jargon
14485 \end_layout
14486
14487 \begin_layout Itemize
14488 (O.S) --- off screen
14489 \end_layout
14490
14491 \begin_layout Itemize
14492 (V.0) --- voice over
14493 \end_layout
14494
14495 \begin_layout Itemize
14496 b.g.
14497  --- background
14498 \end_layout
14499
14500 \begin_layout Itemize
14501 C.U.
14502  --- close-up
14503 \end_layout
14504
14505 \begin_layout Itemize
14506 PAN --- camera movement
14507 \end_layout
14508
14509 \begin_layout Itemize
14510 INSERT --- cut to close-up of
14511 \end_layout
14512
14513 \begin_layout Section
14514 Broadway
14515 \end_layout
14516
14517 \begin_layout Standard
14518 by 
14519 \shape smallcaps
14520 Garst Reese
14521 \end_layout
14522
14523 \begin_layout Subsection
14524 Introduction
14525 \end_layout
14526
14527 \begin_layout Standard
14528 Broadway is for writing plays.
14529  The format is more decorative than Hollywood, and much less standardized.
14530  This format should be suitable for workshops.
14531 \end_layout
14532
14533 \begin_layout Subsection
14534 Special problems
14535 \end_layout
14536
14537 \begin_layout Standard
14538 The same as in Hollywood.
14539 \end_layout
14540
14541 \begin_layout Subsection
14542 Special features
14543 \end_layout
14544
14545 \begin_layout Standard
14546 Insert the 
14547 \family sans
14548 Speaker
14549 \family default
14550  names as labels then cross-reference the label to insert the name.
14551  The cross-reference dialog will show the current cast of characters.
14552 \end_layout
14553
14554 \begin_layout Subsection
14555 Paper size and Margins
14556 \end_layout
14557
14558 \begin_layout Standard
14559 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
14560 \end_layout
14561
14562 \begin_layout Subsection
14563 Environments
14564 \end_layout
14565
14566 \begin_layout Standard
14567 The following environments are available.
14568  You can use broadway.bind to get the bind keys shown at the right.
14569 \end_layout
14570
14571 \begin_layout Itemize
14572
14573 \family sans
14574 Standard
14575 \newline
14576
14577 \family default
14578 You should not have to use this, but it is here for anything that does not
14579  fit otherwise.
14580 \end_layout
14581
14582 \begin_layout Itemize
14583
14584 \family sans
14585 Narrative
14586 \hfill
14587 M-z n
14588 \newline
14589
14590 \family default
14591 Used to describe stage setting and the action.
14592  First use of speaker names in all CAPs.
14593 \end_layout
14594
14595 \begin_layout Itemize
14596
14597 \family sans
14598 ACT
14599 \hfill
14600 M-z a
14601 \newline
14602
14603 \family default
14604 Automatically numbered.
14605  On screen it will be arabic, but will print as Roman.
14606 \end_layout
14607
14608 \begin_layout Itemize
14609
14610 \family sans
14611 ACT*
14612 \hfill
14613 M-z S at
14614 \newline
14615
14616 \family default
14617 Subtitle for 
14618 \family sans
14619 ACT.
14620  
14621 \family default
14622 It is just centered text.
14623 \end_layout
14624
14625 \begin_layout Itemize
14626
14627 \family sans
14628 SCENE
14629 \hfill
14630 M-z S-S
14631 \newline
14632
14633 \family default
14634 Not automatically numbered.
14635  You supply the number.
14636  This is because I couldn't figure out how.
14637 \end_layout
14638
14639 \begin_layout Itemize
14640
14641 \family sans
14642 AT_RISE:
14643 \hfill
14644 M-z S-R
14645 \newline
14646
14647 \family default
14648 A special case of Narrative to describe the setting and action as the curtain
14649  rises.
14650 \end_layout
14651
14652 \begin_layout Itemize
14653
14654 \family sans
14655 Speaker
14656 \hfill
14657 M-z s
14658 \newline
14659
14660 \family default
14661 The speaker's (actor's) title, centered in all CAPS.
14662 \end_layout
14663
14664 \begin_layout Itemize
14665
14666 \family sans
14667 Parenthetical
14668 \hfill
14669 M-z p
14670 \newline
14671
14672 \family default
14673 Instructions to the speaker.
14674  The parentheses are automatically inserted.
14675  The ( will appear on screen, but both will be in the printed play.
14676  This environment is only used within 
14677 \family sans
14678 Dialogue
14679 \family default
14680 .
14681 \end_layout
14682
14683 \begin_layout Itemize
14684
14685 \family sans
14686 Dialogue
14687 \hfill
14688 M-z d
14689 \newline
14690
14691 \family default
14692 What the Speaker says.
14693 \end_layout
14694
14695 \begin_layout Itemize
14696
14697 \family sans
14698 CURTAIN
14699 \hfill
14700 M-z S-C
14701 \newline
14702
14703 \family default
14704 The curtain comes down.
14705 \end_layout
14706
14707 \begin_layout Itemize
14708
14709 \family sans
14710 Title
14711 \hfill
14712 M-z S-T
14713 \end_layout
14714
14715 \begin_layout Itemize
14716
14717 \family sans
14718 Author
14719 \hfill
14720 M-z S-A
14721 \end_layout
14722
14723 \begin_layout Itemize
14724
14725 \family sans
14726 Right_Address
14727 \hfill
14728 M-z r
14729 \end_layout
14730
14731 \begin_layout Standard
14732 Hello there.
14733 \end_layout
14734
14735 \begin_layout Section
14736 RevTeX4
14737 \end_layout
14738
14739 \begin_layout Standard
14740 by 
14741 \noun on
14742 Amir Karger
14743 \end_layout
14744
14745 \begin_layout Standard
14746 \begin_inset VSpace bigskip
14747 \end_inset
14748
14749
14750 \end_layout
14751
14752 \begin_layout Standard
14753 \noindent
14754 The 
14755 \family sans
14756 Revtex\InsetSpace ~
14757 4
14758 \family default
14759  textclass works with the American Physical Sociey's RevTeX 4.0 (the 
14760 \begin_inset Formula $\beta$
14761 \end_inset
14762
14763  release of May, 1999) class.
14764 \end_layout
14765
14766 \begin_layout Standard
14767 LyX has a 
14768 \family sans
14769 Revtex
14770 \family default
14771  textclass, which works with RevTeX 3.1.
14772  However, v3.1 is basically obsolete, as it works with LaTeX 2.09.
14773  That means that it doesn't interact very well with LyX, which requires
14774  LaTeX2e, although it has been kludged to work.
14775  Since RevTeX 4.0 has been designed to work much more cleanly with LaTeX2e,
14776  LyX with the 
14777 \family sans
14778 RevTeX\InsetSpace ~
14779 4
14780 \family default
14781  textclass should also be pretty easy to use.
14782 \end_layout
14783
14784 \begin_layout Standard
14785 These documents are supposed to be used in 
14786 \emph on
14787 addition
14788 \emph default
14789  to the RevTeX 4.0 documents, so we don't describe any of the special RevTeX
14790  macros, and assume you'll know what to put in the preamble if necessary.
14791 \end_layout
14792
14793 \begin_layout Subsection
14794 Installation
14795 \end_layout
14796
14797 \begin_layout Standard
14798 All you need to do is install RevTeX 4, as described in the package's README
14799  file.
14800  the package can be found at 
14801 \begin_inset LatexCommand \url[The RevTeX 4 Web Site]{http://publish.aps.org/revtex4/}
14802
14803 \end_inset
14804
14805 .
14806  Install it somewhere that LaTeX can see it.
14807  Test it by trying to LaTeX a short RevTeX 4 document in some random directory
14808  (i.e., not the directory where you installed the class file.) Then, if you
14809  reconfigure LyX, it will find the class file and let you use the RevTeX4
14810  textclass.
14811 \end_layout
14812
14813 \begin_layout Standard
14814 Probably the easiest way to get started is either to import a RevTeX 4 document
14815  using 
14816 \family typewriter
14817 reLyX
14818 \family default
14819 , or to use the 
14820 \family sans
14821 Revtex\InsetSpace ~
14822 4
14823 \family default
14824  template, found in the templates directory.
14825 \end_layout
14826
14827 \begin_layout Subsection
14828 Preamble Matter
14829 \end_layout
14830
14831 \begin_layout Standard
14832 Optional arguments to 
14833 \family typewriter
14834
14835 \backslash
14836 documentclass
14837 \family default
14838 , like 
14839 \begin_inset Quotes eld
14840 \end_inset
14841
14842 preprint
14843 \begin_inset Quotes erd
14844 \end_inset
14845
14846  and 
14847 \begin_inset Quotes eld
14848 \end_inset
14849
14850 aps
14851 \begin_inset Quotes erd
14852 \end_inset
14853
14854 , go in the 
14855 \family sans
14856 E
14857 \bar under
14858 x
14859 \bar default
14860 tra\InsetSpace ~
14861 Options
14862 \family default
14863  field in the 
14864 \family sans
14865 Document\InsetSpace ~
14866 Layout
14867 \family default
14868  dialog, as usual.
14869  Remember that in RevTeX, at least one optional argument is required! 
14870 \end_layout
14871
14872 \begin_layout Standard
14873 Other preamble matter, like 
14874 \family typewriter
14875
14876 \backslash
14877 draft
14878 \family default
14879  etc.
14880  goes in the 
14881 \family sans
14882 Latex\InsetSpace ~
14883 Preamble
14884 \family default
14885  dialog, also as usual.
14886 \end_layout
14887
14888 \begin_layout Subsection
14889 Layouts
14890 \end_layout
14891
14892 \begin_layout Standard
14893 The layouts basically correspond to the commands in RevTeX4.0.
14894  For example, the Email layout corresponds to 
14895 \family typewriter
14896
14897 \backslash
14898 email{}
14899 \family default
14900 .
14901  Note that (at least as of RevTeX 4.0 Beta), the 
14902 \family sans
14903 Address
14904 \family default
14905  and 
14906 \family sans
14907 Affiliation
14908 \family default
14909  layouts are exactly equivalent, so you shouldn't need to use both.
14910 \begin_inset Foot
14911 status collapsed
14912
14913 \begin_layout Standard
14914 In case you're curious, both were included so that 
14915 \family typewriter
14916 reLyX
14917 \family default
14918  would be able to translate both 
14919 \family typewriter
14920
14921 \backslash
14922 address
14923 \family default
14924  and 
14925 \family typewriter
14926
14927 \backslash
14928 affiliation
14929 \family default
14930 .
14931 \end_layout
14932
14933 \end_inset
14934
14935
14936 \end_layout
14937
14938 \begin_layout Subsection
14939 Important Notes
14940 \end_layout
14941
14942 \begin_layout Standard
14943 There are a couple of important unique aspects of RevTeX 4 which might cause
14944  bugs that will be even more confusing in LyX.
14945 \end_layout
14946
14947 \begin_layout Standard
14948 In RevTeX, the 
14949 \family typewriter
14950
14951 \backslash
14952 thanks
14953 \family default
14954  command goes 
14955 \emph on
14956 outside
14957 \emph default
14958  the 
14959 \family typewriter
14960
14961 \backslash
14962 author
14963 \family default
14964  command.
14965  The LyX equivalent is that there is a separate Thanks layout.
14966  Do 
14967 \emph on
14968 not
14969 \emph default
14970  write footnotes in the 
14971 \family sans
14972 Author
14973 \family default
14974  layout, or weird things may happen.
14975  See the RevTeX 4 documentation for more details.
14976 \end_layout
14977
14978 \begin_layout Standard
14979 Also, the 
14980 \family sans
14981 Author\InsetSpace ~
14982 Email
14983 \family default
14984
14985 \family sans
14986 Author\InsetSpace ~
14987 URL
14988 \family default
14989 , and 
14990 \family sans
14991 Thanks
14992 \family default
14993  layouts must be placed 
14994 \emph on
14995 in between
14996 \emph default
14997  the 
14998 \family sans
14999 Author
15000 \family default
15001  layout and the corresponding 
15002 \family sans
15003 Address
15004 \family default
15005  (or equivalent 
15006 \family sans
15007 Affiliation
15008 \family default
15009 ) layout.
15010  If you put the 
15011 \family sans
15012 Thanks
15013 \family default
15014  after the 
15015 \family sans
15016 Address
15017 \family default
15018 , the LaTeX won't compile.
15019 \end_layout
15020
15021 \begin_layout Subsection
15022 Drawbacks
15023 \end_layout
15024
15025 \begin_layout Standard
15026 The main problem with this layout is that you can't use the optional arguments
15027  to layouts like Email and Title.
15028  (The problem is not unique to this layout; you can't use optional arguments
15029  to the Section layouts either.) This means that after you export that file
15030  to LaTeX (which you'll need to do eventually to send it in to APS), you'll
15031  need to edit the LaTeX file with a text editor to add the optional arguments
15032  to set, e.g., the running title for the page headers.
15033  Lacking these layouts makes the 
15034 \family typewriter
15035
15036 \backslash
15037 altaffiliation
15038 \family default
15039  (and the equivalent 
15040 \family typewriter
15041
15042 \backslash
15043 altaddress
15044 \family default
15045 ) useless, so the corresponding layouts don't exist, and will have to be
15046  added by hand.
15047 \begin_inset Foot
15048 status collapsed
15049
15050 \begin_layout Standard
15051
15052 \emph on
15053 Note from JMarc:
15054 \emph default
15055  actually, LyX 1.3.0 supports some forms of optional arguments, but this layout
15056  has not been updated yet to take advantage of it.
15057 \end_layout
15058
15059 \end_inset
15060
15061  
15062 \end_layout
15063
15064 \begin_layout Section
15065 Article (mwart), book (mwbk) and report (mwrep)
15066 \begin_inset OptArg
15067 status collapsed
15068
15069 \begin_layout Standard
15070 The 
15071 \family typewriter
15072 mw
15073 \family default
15074  Classes
15075 \end_layout
15076
15077 \end_inset
15078
15079
15080 \end_layout
15081
15082 \begin_layout Standard
15083 by 
15084 \noun on
15085 Tomasz Luczak
15086 \end_layout
15087
15088 \begin_layout Standard
15089 The LyX document classes
15090 \emph on
15091  article (mwart)
15092 \emph default
15093
15094 \emph on
15095 report (mwrep)
15096 \emph default
15097  and 
15098 \emph on
15099 book
15100 \emph default
15101  
15102 \emph on
15103 (mwbk)
15104 \emph default
15105  correspond to the LaTeX document classes 
15106 \family typewriter
15107 mwart.cls
15108 \family default
15109
15110 \family typewriter
15111 mwrep.cls
15112 \family default
15113  and 
15114 \family typewriter
15115 mwbk.cls
15116 \family default
15117 , resp.
15118  They are replacements for the standard document classes 
15119 \family typewriter
15120 article.cls
15121 \family default
15122
15123 \family typewriter
15124 report.cls
15125 \family default
15126  and 
15127 \family typewriter
15128 book.cls
15129 \family default
15130 , resp., and fit better to Polish typography conventions in a number of points.
15131  
15132 \end_layout
15133
15134 \begin_layout Standard
15135 Basic differences:
15136 \end_layout
15137
15138 \begin_layout Itemize
15139 Unnumbered titles (with star, eg.
15140  
15141 \family sans
15142 Section*
15143 \family default
15144 ) are added into table of contents,
15145 \end_layout
15146
15147 \begin_layout Itemize
15148 Additional page styles:
15149 \end_layout
15150
15151 \begin_deeper
15152 \begin_layout Description
15153 uheadings header with separated lines,
15154 \end_layout
15155
15156 \begin_layout Description
15157 myheadings custom header, contents headers via commands: 
15158 \family typewriter
15159
15160 \backslash
15161 markright
15162 \family default
15163  and 
15164 \family typewriter
15165
15166 \backslash
15167 markboth
15168 \family default
15169 ,
15170 \end_layout
15171
15172 \begin_layout Description
15173 myuheadings custom header with separated lines,
15174 \end_layout
15175
15176 \begin_layout Description
15177 outer page number is placed on outer side of page
15178 \end_layout
15179
15180 \end_deeper
15181 \begin_layout Itemize
15182 Options 
15183 \end_layout
15184
15185 \begin_deeper
15186 \begin_layout Description
15187 rmheadings serif titles --- default,
15188 \end_layout
15189
15190 \begin_layout Description
15191 sfheadings sansserif titles,
15192 \end_layout
15193
15194 \begin_layout Description
15195 authortitle on title page first placed is author next title --- default,
15196 \end_layout
15197
15198 \begin_layout Description
15199 titleauthor on title page first placed is title next author,
15200 \end_layout
15201
15202 \begin_layout Description
15203 withmarginpar reserve place on page for margins.
15204 \end_layout
15205
15206 \end_deeper
15207 \begin_layout Section
15208 Elsevier Journals
15209 \end_layout
15210
15211 \begin_layout Standard
15212 By 
15213 \noun on
15214 Rod Pinna
15215 \end_layout
15216
15217 \begin_layout Standard
15218 Elsevier Science Publishers B.V.
15219  provides a standard LaTeX document class (
15220 \family typewriter
15221 elsart.cls
15222 \family default
15223 ) for submitting articles to their various journals.
15224  The style file can be downloaded directly from their web site: 
15225 \begin_inset LatexCommand \url{http://authors.elsevier.com/}
15226
15227 \end_inset
15228
15229 .
15230  Instructions are supplied along with the class file, which details the
15231  requirements of the publishers.
15232  LyX includes package that allows for the use of this class, by a layout
15233  and a template file.
15234  Installation of the class file is the same as for any other LaTeX package;
15235  instructions are provided in the Elsevier documentation.
15236 \end_layout
15237
15238 \begin_layout Standard
15239 To make use of 
15240 \family typewriter
15241 elsart.cls
15242 \family default
15243 , a file 
15244 \family typewriter
15245 elsart.layout
15246 \family default
15247  is supplied.
15248  As the Elsevier class file is based mainly on the standard article class,
15249  most of the normal functionality is provided.
15250  The Elsevier class defines a number of mathematical environments, which
15251  are similar to the AMS environments.
15252  These commands are all described in the Elsevier documentation, and are
15253  available in LyX.
15254 \end_layout
15255
15256 \begin_layout Standard
15257 The easiest way to use the Elsevier style is to base documents on the included
15258  template file.
15259  It is best not to use options such as fancy headings or the geometry package,
15260  as elements such as these are defined by Elsevier in their style file.
15261  Ideally, no extra packages except those mentioned in the Elsevier documentation
15262  should be used.
15263  Essentially, Elsevier require as 
15264 \begin_inset Quotes eld
15265 \end_inset
15266
15267 clean
15268 \begin_inset Quotes erd
15269 \end_inset
15270
15271  a 
15272 \begin_inset ERT
15273 status collapsed
15274
15275 \begin_layout Standard
15276
15277
15278 \backslash
15279 LaTeX
15280 \end_layout
15281
15282 \end_inset
15283
15284  file as possible, as their intention is to take the supplied file and replace
15285  the class file with one for the particular journal to which the paper has
15286  been submitted.
15287  This also means that not too much time should be spent on the formating
15288  of the document.
15289  When it comes to be published, this will change anyway.
15290  The rest of the usage for this layout is substantially the same as for
15291  the normal article class.
15292  For details of what Elsevier do and don't allow, refer to their documentation.
15293 \end_layout
15294
15295 \begin_layout Section
15296 Memoir
15297 \end_layout
15298
15299 \begin_layout Standard
15300 By 
15301 \noun on
15302 Jürgen Spitzmüller
15303 \end_layout
15304
15305 \begin_layout Subsection
15306 Overview
15307 \end_layout
15308
15309 \begin_layout Standard
15310 Memoir is a very powerful and constantly evolving class.
15311  It has been designed with regard to fictional and non-fictional literature.
15312  Its aim is to let the user have maximum control over the typesetting of
15313  his document.
15314  Memoir is based on the standard book class, but it can also emulate the
15315  article class (see below).
15316 \end_layout
15317
15318 \begin_layout Standard
15319 Peter Wilson, the developer of Memoir, is known as the author of lots of
15320  useful packages in the LaTeX world.
15321  Most of them have been merged with Memoir.
15322  Therefore, it is much easier to layout the table of contents, appendices,
15323  chapter designs and such.
15324  LyX, though, does not support all of these goodies natively.
15325  Some of them might be added to forthcoming releases
15326 \begin_inset Foot
15327 status collapsed
15328
15329 \begin_layout Standard
15330 You are invited to send suggestions to 
15331 \begin_inset LatexCommand \url{lyx-devel@lists.lyx.org}
15332
15333 \end_inset
15334
15335 .
15336 \end_layout
15337
15338 \end_inset
15339
15340 , lots will probably never, due to the limitations of LyX's framework.
15341  Of course you can still use all features with the help of some native LaTeX
15342  commands (ERT
15343 \begin_inset Foot
15344 status collapsed
15345
15346 \begin_layout Standard
15347 Cf.
15348 \begin_inset ERT
15349 status collapsed
15350
15351 \begin_layout Standard
15352
15353
15354 \backslash
15355  
15356 \end_layout
15357
15358 \end_inset
15359
15360 section\InsetSpace ~
15361
15362 \begin_inset LatexCommand \ref{sec:Inserting-LaTeX-Code}
15363
15364 \end_inset
15365
15366  for details.
15367 \end_layout
15368
15369 \end_inset
15370
15371 ).
15372  In this section, we can only list those features which are natively supported
15373  by LyX.
15374  For detailed descriptions (and for the rest of features) we are recommending
15375  to have a look at the detailed manual of the Memoir class
15376 \begin_inset Foot
15377 status collapsed
15378
15379 \begin_layout Standard
15380 Cf.
15381 \begin_inset ERT
15382 status collapsed
15383
15384 \begin_layout Standard
15385
15386
15387 \backslash
15388  
15389 \end_layout
15390
15391 \end_inset
15392
15393
15394 \begin_inset LatexCommand \url{CTAN:/macros/latex/memoir/memman.pdf}
15395
15396 \end_inset
15397
15398 .
15399 \end_layout
15400
15401 \end_inset
15402
15403 , which is not only a user guide for the class, but also both a comprehensive
15404  description on good typesetting and a superb example for good typesetting
15405  itself.
15406 \end_layout
15407
15408 \begin_layout Subsection
15409 Basic features and restrictions
15410 \end_layout
15411
15412 \begin_layout Standard
15413 Memoir supports basically all features of the standard book classes.
15414  There are, however, some differences, as follows:
15415 \end_layout
15416
15417 \begin_layout Description
15418 Font\InsetSpace ~
15419 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14,
15420  17
15421 \end_layout
15422
15423 \begin_layout Description
15424 Page\InsetSpace ~
15425 style: The fancy page style is not supported, due to a command clash
15426  between Memoir and the fancyhdr package (they are both defining a command
15427  with the same name, which confuses LaTeX).
15428  Instead, Memoir comes with a bunch of own page styles (see 
15429 \family sans
15430 Layout\SpecialChar \menuseparator
15431 Document\SpecialChar \menuseparator
15432 Page\InsetSpace ~
15433 Style
15434 \family default
15435 ).
15436  If you want to use these for the chapter pages, you have to use the command
15437  
15438 \family typewriter
15439
15440 \backslash
15441 chapterstyle
15442 \family default
15443  in the main text or in preamble (e.
15444 \begin_inset ERT
15445 status collapsed
15446
15447 \begin_layout Standard
15448
15449
15450 \backslash
15451 ,
15452 \end_layout
15453
15454 \end_inset
15455
15456 g.
15457 \begin_inset ERT
15458 status collapsed
15459
15460 \begin_layout Standard
15461
15462
15463 \backslash
15464  
15465 \end_layout
15466
15467 \end_inset
15468
15469
15470 \family typewriter
15471
15472 \backslash
15473 chapterstyle{companion}
15474 \family default
15475 ).
15476 \end_layout
15477
15478 \begin_layout Description
15479 Sectioning: Sectionings (chapter, section, subsection etc.) are coming with
15480  an optional argument in the standard classes.
15481  With this, you can specify an alternative version of the title for the
15482  table of contents and the headers (for instance, if the title is too long).
15483  In LyX, you can do this via 
15484 \family sans
15485 Insert\SpecialChar \menuseparator
15486 Short\InsetSpace ~
15487 Title
15488 \family default
15489  at the beginning of a chapter/section.
15490  Memoir features a second optional argument and thus separates the table
15491  of contents from the header.
15492  You can define three variants of a title with this: one for the main text,
15493  one for the table of contents, and one for the headers.
15494  Simply insert two optional arguments if you need this feature, the first
15495  one containing the short title for the Table of Contents, the second one
15496  containing an alternative short title for the headers.
15497 \end_layout
15498
15499 \begin_layout Description
15500 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15501  of contents, the list of figures and the list of table start a new page
15502  automatically.
15503  Memoir does not follow this route.
15504  You have to insert a page break yourself, if you want to have one.
15505 \end_layout
15506
15507 \begin_layout Description
15508 Titlepage: For some unknown reason, Memoir uses pagination on the title
15509  page (in the standard classes, title pages are 
15510 \begin_inset Quotes eld
15511 \end_inset
15512
15513 empty
15514 \begin_inset Quotes erd
15515 \end_inset
15516
15517 , i.
15518 \begin_inset ERT
15519 status collapsed
15520
15521 \begin_layout Standard
15522
15523
15524 \backslash
15525 ,
15526 \end_layout
15527
15528 \end_inset
15529
15530 e.
15531 \begin_inset ERT
15532 status collapsed
15533
15534 \begin_layout Standard
15535
15536
15537 \backslash
15538  
15539 \end_layout
15540
15541 \end_inset
15542
15543 without pagina).
15544  If you want an empty title page, type 
15545 \family typewriter
15546
15547 \backslash
15548 aliaspagestyle{title}{empty} 
15549 \family default
15550 in the preamble.
15551 \end_layout
15552
15553 \begin_layout Description
15554 Article: With the class option 
15555 \emph on
15556 article 
15557 \emph default
15558 (to be inserted in 
15559 \family sans
15560 Layout\SpecialChar \menuseparator
15561 Document\SpecialChar \menuseparator
15562 Extra\InsetSpace ~
15563 Options
15564 \family default
15565 ), you can emulate article style.
15566  That is, counters (footnotes, figures, tables etc.) will not be reset on
15567  new chapters, chapters don't start a new page (but are---in contrary to
15568  
15569 \begin_inset Quotes eld
15570 \end_inset
15571
15572 real
15573 \begin_inset Quotes erd
15574 \end_inset
15575
15576  article classes---still allowed), parts, though, use their own page, as
15577  in book.
15578 \end_layout
15579
15580 \begin_layout Description
15581 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15582  font commands, which have been used in the old LaTeX version 2.09 (e.
15583 \begin_inset ERT
15584 status collapsed
15585
15586 \begin_layout Standard
15587
15588
15589 \backslash
15590 ,
15591 \end_layout
15592
15593 \end_inset
15594
15595 g.
15596 \begin_inset ERT
15597 status collapsed
15598
15599 \begin_layout Standard
15600
15601
15602 \backslash
15603  
15604 \end_layout
15605
15606 \end_inset
15607
15608
15609 \family typewriter
15610
15611 \backslash
15612 rm
15613 \family default
15614
15615 \family typewriter
15616
15617 \backslash
15618 it
15619 \family default
15620 ).
15621  It produces an error and stops LaTeX whenever such a command appears.
15622  The class option 
15623 \emph on
15624 oldfontcommands
15625 \emph default
15626  reallows the commands and spits out warnings instead (which does at least
15627  not stop LaTeX).
15628  Since a lot of packages and particularly BibTeX style files are still using
15629  those commands, we have decided to use this option by default.
15630 \end_layout
15631
15632 \begin_layout Subsection
15633 Extra features
15634 \end_layout
15635
15636 \begin_layout Standard
15637 We will only describe the features supported by LyX (which is not much currently
15638 ).
15639  Please consult the Memoir manual
15640 \begin_inset Foot
15641 status collapsed
15642
15643 \begin_layout Standard
15644 Cf.
15645 \begin_inset ERT
15646 status collapsed
15647
15648 \begin_layout Standard
15649
15650
15651 \backslash
15652  
15653 \end_layout
15654
15655 \end_inset
15656
15657
15658 \begin_inset LatexCommand \url{CTAN:/macros/latex/memoir/memman.pdf}
15659
15660 \end_inset
15661
15662 .
15663 \end_layout
15664
15665 \end_inset
15666
15667  for details.
15668 \end_layout
15669
15670 \begin_layout Description
15671 Abstract: You may wonder why an abstract is an extra feature.
15672  Well, it is in book class.
15673  Usually books don't have abstracts.
15674  Memoir, however, has.
15675  You can use it whereever and how often you like.
15676 \end_layout
15677
15678 \begin_layout Description
15679 Chapterprecis: You may know this from belletristic: The contents of a chapter
15680  is shortly described below the title and also in the table of contents
15681  (e.
15682 \begin_inset ERT
15683 status collapsed
15684
15685 \begin_layout Standard
15686
15687
15688 \backslash
15689 ,
15690 \end_layout
15691
15692 \end_inset
15693
15694 g.
15695 \begin_inset ERT
15696 status collapsed
15697
15698 \begin_layout Standard
15699
15700
15701 \backslash
15702  
15703 \end_layout
15704
15705 \end_inset
15706
15707
15708 \emph on
15709 Our hero arrives in Troia; he loses some friends; he finds others
15710 \emph default
15711 ).
15712  Chapterprecis does exactly this.
15713  It is therefore only sensible below a chapter.
15714 \end_layout
15715
15716 \begin_layout Description
15717 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
15718  The epigraph environment provides an elegant way of typesetting such a
15719  motto.
15720  The motto itself (text) and its author (source) are divided by a short
15721  line.
15722  Unfortunately, we have to fool LyX a bit here again, since the environment
15723  needs two arguments (text and source).
15724  In this case, we have to use curly brackets (in TeX mode) between the two
15725  arguments: 
15726 \emph on
15727 <smart slogan>
15728 \emph default
15729  
15730 \family typewriter
15731 }{
15732 \family default
15733  
15734 \emph on
15735 <author of the slogan>.
15736 \end_layout
15737
15738 \begin_layout Description
15739 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
15740  complex figurative poems).
15741  Lyx can only support a few of them.
15742  One is poemtitle, which is a centered title for poems, which will also
15743  be added to the table of contents (verse is the standard environment for
15744  poems.
15745  Memoir has some enhanced versions of verse, but you need to use ERT, because
15746  they have to be nested inside regular verse environments, which is not
15747  possible with LyX).
15748 \end_layout
15749
15750 \begin_layout Description
15751 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
15752 \end_layout
15753
15754 \begin_layout Chapter
15755 Importing and Exporting Alternate File Formats
15756 \begin_inset OptArg
15757 status collapsed
15758
15759 \begin_layout Standard
15760 Importing and Exporting
15761 \end_layout
15762
15763 \end_inset
15764
15765
15766 \end_layout
15767
15768 \begin_layout Section
15769 Considerations
15770 \end_layout
15771
15772 \begin_layout Standard
15773 Importing and exporting LyX documents from/to other formats has been touched
15774  on briefly in the 
15775 \emph on
15776 User Guide
15777 \emph default
15778 .
15779  Here we describe more of the gory details needed to understand just what
15780  is going on when you click on the 
15781 \family sans
15782 \bar under
15783 F
15784 \bar default
15785 ile\SpecialChar \menuseparator
15786
15787 \bar under
15788 I
15789 \bar default
15790 mport
15791 \family default
15792  and 
15793 \family sans
15794 \bar under
15795 F
15796 \bar default
15797 ile\SpecialChar \menuseparator
15798 E
15799 \bar under
15800 x
15801 \bar default
15802 port
15803 \family default
15804  menu items.
15805  
15806 \end_layout
15807
15808 \begin_layout Section
15809 Importing Other Formats
15810 \end_layout
15811
15812 \begin_layout Subsection
15813 LaTeX
15814 \end_layout
15815
15816 \begin_layout Standard
15817 Translating from LaTeX into LyX is performed by a Perl script called reLyX.
15818  Although it is a standalone program which can be called from the command
15819  line, LyX will call it automatically when a LaTeX document is imported.
15820  See section\InsetSpace ~
15821
15822 \begin_inset LatexCommand \ref{sec:reLyX}
15823
15824 \end_inset
15825
15826  for a complete description.
15827  There are no user tunable parameters for reLyX within LyX.
15828 \end_layout
15829
15830 \begin_layout Subsection
15831 ASCII Text
15832 \end_layout
15833
15834 \begin_layout Standard
15835 When importing plain ASCII text, there are two methods of reading the file.
15836  Importing 
15837 \begin_inset Quotes eld
15838 \end_inset
15839
15840 as lines
15841 \begin_inset Quotes erd
15842 \end_inset
15843
15844  preserves all the linebreaks in the ASCII; to LyX, then, each line looks
15845  like a paragraph.
15846  Importing 
15847 \begin_inset Quotes eld
15848 \end_inset
15849
15850 as paragraphs
15851 \begin_inset Quotes erd
15852 \end_inset
15853
15854  assumes that consecutive lines separated by only a single linebreak form
15855  a single paragraph.
15856  Successive linebreaks with no intervening text are thus assumed to be paragraph
15857  delimiters.
15858 \end_layout
15859
15860 \begin_layout Subsection
15861 Noweb
15862 \end_layout
15863
15864 \begin_layout Standard
15865
15866 \emph on
15867 [Editor's note: Needs to be written, obviously - any volunteers? --- mer]
15868 \end_layout
15869
15870 \begin_layout Section
15871 Exporting Other Formats
15872 \end_layout
15873
15874 \begin_layout Subsection
15875 LaTeX
15876 \end_layout
15877
15878 \begin_layout Standard
15879 LyX generates two types of LaTeX files: stripped down versions for the normal
15880  processing (
15881 \family sans
15882 View DVI
15883 \family default
15884 , etc.) which one normally never sees
15885 \begin_inset Foot
15886 status collapsed
15887
15888 \begin_layout Standard
15889 The resulting file is a perfectly valid LaTeX file, though the preamble
15890  might look a bit strange since it includes some definitions used by LyX
15891  which wouldn't show up in most human-written files.
15892 \end_layout
15893
15894 \end_inset
15895
15896 , and human readable forms which are suitable for exchanging with your colleague
15897 s.
15898  The only settable option for the translation is the line length of the
15899  output file.
15900  The default is 65 characters, but it can be set in 
15901 \family sans
15902 \bar under
15903 T
15904 \bar default
15905 ools
15906 \family default
15907 \SpecialChar \menuseparator
15908
15909 \family sans
15910 \bar under
15911 P
15912 \bar default
15913 references
15914 \family default
15915  using the 
15916 \family sans
15917 \bar under
15918 A
15919 \bar default
15920 scii\InsetSpace ~
15921 line\InsetSpace ~
15922 length
15923 \family default
15924  field.
15925  
15926 \end_layout
15927
15928 \begin_layout Subsection
15929 Device Independent Files
15930 \end_layout
15931
15932 \begin_layout Standard
15933 Device Independent files (DVI files) are produced by running LaTeX on your
15934  document.
15935  There are no user settable options.
15936 \end_layout
15937
15938 \begin_layout Subsection
15939 PostScript
15940 \end_layout
15941
15942 \begin_layout Standard
15943 The next step in the conversion chain is converting a DVI file into Postscript®.
15944  You can either use 
15945 \family sans
15946 \bar under
15947 F
15948 \bar default
15949 ile
15950 \family default
15951 \SpecialChar \menuseparator
15952
15953 \family sans
15954 \bar under
15955 E
15956 \bar default
15957 xport
15958 \family default
15959 \SpecialChar \menuseparator
15960
15961 \family sans
15962 Pos
15963 \bar under
15964 t
15965 \bar default
15966 script
15967 \family default
15968  or, if you need more control on the result, 
15969 \family sans
15970 \bar under
15971 F
15972 \bar default
15973 ile
15974 \family default
15975 \SpecialChar \menuseparator
15976
15977 \family sans
15978 \bar under
15979 P
15980 \bar default
15981 rint
15982 \family default
15983 .
15984  If you use the later, note that it is possible to configure, in 
15985 \family sans
15986 \bar under
15987 T
15988 \bar default
15989 ools
15990 \family default
15991 \SpecialChar \menuseparator
15992
15993 \family sans
15994 \bar under
15995 P
15996 \bar default
15997 references
15998 \family default
15999 , the options passed to the dvips program to achieve different effects.
16000 \end_layout
16001
16002 \begin_layout Subsection
16003 ASCII text
16004 \end_layout
16005
16006 \begin_layout Standard
16007 Exporting as ASCII attempts to preserve the 
16008 \begin_inset Quotes eld
16009 \end_inset
16010
16011 shape
16012 \begin_inset Quotes erd
16013 \end_inset
16014
16015  of the document as well as possible, but things like centering and indentation
16016  are thrown out; paragraphs are separated by blank lines.
16017  Section numbering and cross-references are done correctly, so the resulting
16018  text files is remarkably readable.
16019  The only changeable option is the length of lines, as for LaTeX output.
16020 \end_layout
16021
16022 \begin_layout Subsection
16023 HTML
16024 \end_layout
16025
16026 \begin_layout Standard
16027 LyX documents can be converted to hypertext markup, usually by converting
16028  to LaTeX first, then converting that to HTML\SpecialChar \@.
16029  Four LaTeX
16030 \begin_inset Formula $\rightarrow$
16031 \end_inset
16032
16033 HTML converters are currently known to LyX: 
16034 \family typewriter
16035 tth
16036 \family default
16037
16038 \family typewriter
16039 latex2html
16040 \family default
16041
16042 \family typewriter
16043 hevea
16044 \family default
16045  and 
16046 \family typewriter
16047 htlatex
16048 \family default
16049 .
16050  Though they are autodetected, you can overide the selection in preferences.
16051  You can also include further command line options in this dialog.
16052  
16053 \end_layout
16054
16055 \begin_layout Subsection
16056 PDF
16057 \end_layout
16058
16059 \begin_layout Standard
16060 by 
16061 \noun on
16062 Dekel Tsur
16063 \noun default
16064  (mostly)
16065 \end_layout
16066
16067 \begin_layout Standard
16068 \begin_inset VSpace bigskip
16069 \end_inset
16070
16071
16072 \end_layout
16073
16074 \begin_layout Standard
16075 The fastest way to generate a basic PDF file (no tags, links, etc.) with
16076  any version of LyX is to save the document as a Postscript® file, then
16077  run the 
16078 \family typewriter
16079 ps2pdf
16080 \family default
16081  command on it.
16082  Starting with version 1.1.6, the menu item 
16083 \family sans
16084 File->Export->PDF
16085 \family default
16086  will do all this for you.
16087  There are some issues with fonts that you need to pay attention to: see
16088  Section\InsetSpace ~
16089
16090 \begin_inset LatexCommand \ref{sec:badfonts}
16091
16092 \end_inset
16093
16094 .
16095  Also, as of version 1.1.6, there is a better method that will generate much
16096  more sophisticated files.
16097 \end_layout
16098
16099 \begin_layout Subsubsection
16100 Use pdfLaTeX
16101 \end_layout
16102
16103 \begin_layout Standard
16104 With pdfLaTeX you need to convert your eps figures to PDF (see Section\InsetSpace ~
16105
16106 \begin_inset LatexCommand \ref{sec:pdfeps}
16107
16108 \end_inset
16109
16110 ), and you cannot use pstricks.
16111  On the other hand, with pdfLaTeX it is possible to insert directly images
16112  in JPEG or PNG format, use TrueType fonts, and more.
16113 \end_layout
16114
16115 \begin_layout Subsubsection
16116 Why does the text look so bad when viewed with Acrobat Reader?
16117 \begin_inset LatexCommand \label{sec:badfonts}
16118
16119 \end_inset
16120
16121
16122 \begin_inset OptArg
16123 status collapsed
16124
16125 \begin_layout Standard
16126 Bad Fonts in Acrobat Reader
16127 \end_layout
16128
16129 \end_inset
16130
16131
16132 \end_layout
16133
16134 \begin_layout Standard
16135 The problem is that bitmap fonts are displayed poorly by Acrobat Reader.
16136  When creating a PDF from the LyX file, you need to use outline font instead
16137  of the default bitmap fonts (in fact, you should also use outline fonts
16138  for Postscript files).
16139  Recent LaTeX distributions come with Postscript® Type 1 version of the
16140  standard (Computer Modern) fonts.
16141  pdfLaTeX uses these font by default.
16142  Dvips doesn't use these fonts by default, so to make it use them, add the
16143  following to lines to your 
16144 \family typewriter
16145 ~/.dvipsrc
16146 \family default
16147  file
16148 \end_layout
16149
16150 \begin_layout LyX-Code
16151 p+ psfonts.cmz
16152 \end_layout
16153
16154 \begin_layout LyX-Code
16155 p+ psfonts.amz
16156 \end_layout
16157
16158 \begin_layout Standard
16159 If the default LaTeX font encoding (OT1) is used, nothing else need to be
16160  done.
16161  However, if the T1 font encoding is used, then LaTeX uses the newer EC
16162  fonts, for which there are no Type1 version.
16163  There are two solutions in this case: Either use the 
16164 \begin_inset Quotes eld
16165 \end_inset
16166
16167 ae font
16168 \begin_inset Quotes erd
16169 \end_inset
16170
16171  (which is in fact a 
16172 \begin_inset Quotes eld
16173 \end_inset
16174
16175 virtual
16176 \begin_inset Quotes erd
16177 \end_inset
16178
16179  font that emulates T1 coded fonts using the standard CM fonts).
16180  This is done by selecting 
16181 \begin_inset Quotes eld
16182 \end_inset
16183
16184 AE (Almost European)
16185 \begin_inset Quotes erd
16186 \end_inset
16187
16188  from 
16189 \family sans
16190 Document\SpecialChar \menuseparator
16191 Settings\SpecialChar \menuseparator
16192  Fonts\SpecialChar \menuseparator
16193 Roman
16194 \family default
16195 .
16196  However, some glyphs are missing from the CM fonts (e.g.
16197  eth, thorn), and they are taken from the EC fonts.
16198  Therefore you get these glyphs as bitmaps.
16199  Or use the 
16200 \begin_inset Quotes eld
16201 \end_inset
16202
16203 Latin Modern
16204 \begin_inset Quotes erd
16205 \end_inset
16206
16207  font from 
16208 \family sans
16209 Document\SpecialChar \menuseparator
16210 Settings\SpecialChar \menuseparator
16211  Fonts\SpecialChar \menuseparator
16212 Roman
16213 \family default
16214 .
16215  It is a newer and probably the best Postscript® Type 1 version of cm.
16216  Basically, we recommend this over the 
16217 \begin_inset Quotes eld
16218 \end_inset
16219
16220 ae
16221 \begin_inset Quotes erd
16222 \end_inset
16223
16224  solution.
16225  However, the Latin Modern fonts differ from cm in some visual aspects,
16226  which does not please everybody.
16227 \end_layout
16228
16229 \begin_layout Standard
16230 Note: LyX uses by default the T1 font encoding.
16231  If you wish to use the default font encoding (this is not recommended,
16232  unless you only write English documents), clear the field 
16233 \family sans
16234 \bar under
16235 T
16236 \bar default
16237 eX\InsetSpace ~
16238 encoding
16239 \family default
16240  in preferences (tabs 
16241 \family sans
16242 Outputs
16243 \family default
16244
16245 \family sans
16246 Misc
16247 \family default
16248 ).
16249  
16250 \end_layout
16251
16252 \begin_layout Standard
16253 An alternate option is to use the standard Postscript® fonts instead of
16254  the Computer Modern fonts.
16255  To do that, you just need to select one of the fonts listed in the document
16256  layout dialog (except for 
16257 \begin_inset Quotes eld
16258 \end_inset
16259
16260 default
16261 \begin_inset Quotes erd
16262 \end_inset
16263
16264  and 
16265 \begin_inset Quotes eld
16266 \end_inset
16267
16268 computer modern
16269 \begin_inset Quotes erd
16270 \end_inset
16271
16272 , they're all Postscript® fonts).
16273  When using the Postscript® fonts, the result PDF file is smaller as the
16274  fonts are not saved into the file.
16275  Furthermore, the Postscript® fonts include all T1 glyphs.
16276  On the other hand, the Postscript® fonts have no bold symbol font, so poor
16277  man's bold must be used (see Section\InsetSpace ~
16278
16279 \begin_inset LatexCommand \ref{sec:pdfbold}
16280
16281 \end_inset
16282
16283 ).
16284  The Postscript® fonts also look different from the Computer Modern fonts.
16285 \end_layout
16286
16287 \begin_layout Standard
16288 To sum up, both the Computer Modern and the Postscript® fonts gives good
16289  results (with few exceptions).
16290  The decision of which one to use is a matter of taste.
16291 \end_layout
16292
16293 \begin_layout Subsubsection
16294 Why doesn't the 
16295 \backslash
16296 boldsymbol{} command work when I use pslatex?
16297 \begin_inset LatexCommand \label{sec:pdfbold}
16298
16299 \end_inset
16300
16301
16302 \begin_inset OptArg
16303 status collapsed
16304
16305 \begin_layout Standard
16306
16307 \family typewriter
16308
16309 \backslash
16310 boldsymbol{}
16311 \family default
16312  and 
16313 \family typewriter
16314 pslatex
16315 \end_layout
16316
16317 \end_inset
16318
16319
16320 \end_layout
16321
16322 \begin_layout Standard
16323 The Postscript® fonts do not have a bold symbol font.
16324  The solution is to use the 
16325 \family typewriter
16326
16327 \backslash
16328 pmb{}
16329 \family default
16330  (poor man's bold) command.
16331 \end_layout
16332
16333 \begin_layout Standard
16334 It is possible to redefine the 
16335 \family typewriter
16336
16337 \backslash
16338 boldsymbol
16339 \family default
16340  command to use 
16341 \family typewriter
16342
16343 \backslash
16344 pmb
16345 \family default
16346  by putting
16347 \end_layout
16348
16349 \begin_layout LyX-Code
16350
16351 \backslash
16352 renewcommand{
16353 \backslash
16354 boldsymbol}[1]{
16355 \backslash
16356 pmb{#1}}
16357 \end_layout
16358
16359 \begin_layout Standard
16360 in the preamble.
16361 \end_layout
16362
16363 \begin_layout Subsubsection
16364 Is it possible to do write latex code which is processed only when running
16365  pdfLaTeX?
16366 \begin_inset OptArg
16367 status collapsed
16368
16369 \begin_layout Standard
16370 Conditionals with pdfLaTeX
16371 \end_layout
16372
16373 \end_inset
16374
16375
16376 \end_layout
16377
16378 \begin_layout Standard
16379 Yes.
16380  Here is an example:
16381 \end_layout
16382
16383 \begin_layout LyX-Code
16384
16385 \backslash
16386 newif 
16387 \backslash
16388 ifpdf
16389 \end_layout
16390
16391 \begin_layout LyX-Code
16392    
16393 \backslash
16394 ifx 
16395 \backslash
16396 pdfoutput 
16397 \backslash
16398 undefined
16399 \end_layout
16400
16401 \begin_layout LyX-Code
16402       
16403 \backslash
16404 pdffalse
16405 \end_layout
16406
16407 \begin_layout LyX-Code
16408    
16409 \backslash
16410 else
16411 \end_layout
16412
16413 \begin_layout LyX-Code
16414       
16415 \backslash
16416 pdftrue
16417 \end_layout
16418
16419 \begin_layout LyX-Code
16420
16421 \backslash
16422 fi
16423 \end_layout
16424
16425 \begin_layout LyX-Code
16426
16427 \end_layout
16428
16429 \begin_layout LyX-Code
16430
16431 \backslash
16432 ifpdf
16433 \end_layout
16434
16435 \begin_layout LyX-Code
16436    
16437 \backslash
16438 pdfinfo { /Author (your name and e-mail address)
16439 \end_layout
16440
16441 \begin_layout LyX-Code
16442       /Title (official title -- i.e., title element)
16443 \end_layout
16444
16445 \begin_layout LyX-Code
16446       /Subject (one line description of the document)
16447 \end_layout
16448
16449 \begin_layout LyX-Code
16450    }
16451 \end_layout
16452
16453 \begin_layout LyX-Code
16454    
16455 \backslash
16456 pdfcatalog { /PageMode (/UseNone)
16457 \end_layout
16458
16459 \begin_layout LyX-Code
16460    % /OpenAction (fitbh)
16461 \end_layout
16462
16463 \begin_layout LyX-Code
16464    }
16465 \end_layout
16466
16467 \begin_layout LyX-Code
16468    
16469 \backslash
16470 usepackage[pdftex]{hyperref}
16471 \end_layout
16472
16473 \begin_layout LyX-Code
16474
16475 \backslash
16476 else
16477 \end_layout
16478
16479 \begin_layout LyX-Code
16480    
16481 \backslash
16482 usepackage[ps2pdf]{hyperref}
16483 \end_layout
16484
16485 \begin_layout LyX-Code
16486
16487 \backslash
16488 fi
16489 \end_layout
16490
16491 \begin_layout Subsubsection
16492 How can I make URLs clickable ?
16493 \end_layout
16494
16495 \begin_layout Standard
16496 See the references here :
16497 \end_layout
16498
16499 \begin_layout Standard
16500 \begin_inset LatexCommand \url{http://wiki.lyx.org/pmwiki.php/FAQ/PDF}
16501
16502 \end_inset
16503
16504
16505 \end_layout
16506
16507 \begin_layout Subsection
16508 Custom
16509 \end_layout
16510
16511 \begin_layout Standard
16512 Custom exports are possible if you have some particularly weird format you
16513  wish to convert to, assuming you have the relevant converter, of course.
16514  The format of the 
16515 \emph on
16516 input
16517 \emph default
16518  file can be chosen in the 
16519 \family sans
16520 \bar under
16521 F
16522 \bar default
16523 ile\SpecialChar \menuseparator
16524
16525 \bar under
16526 E
16527 \bar default
16528 xport\SpecialChar \menuseparator
16529
16530 \bar under
16531 C
16532 \bar default
16533 ustom 
16534 \family default
16535 dialog; LyX will automatically convert the file to this point, then feed
16536  it to your custom converter.
16537  The possible values are all formats that LyX can produce from its own documents.
16538  
16539 \end_layout
16540
16541 \begin_layout Standard
16542 The converter command is also specified in the dialog.It should be a completely
16543  qualified command line which uses the variable 
16544 \family typewriter
16545 $$FName
16546 \family default
16547  to specify the name of the file.
16548  If this variable is not given, then the file will be sent to the standard
16549  input of your command.
16550  You may have to apply a bit of ingenuity to escape this sequence correctly
16551  so that it is compatible with your shell.
16552  
16553 \end_layout
16554
16555 \begin_layout Standard
16556 While it is not possible to save this command using the 
16557 \family sans
16558 Preferences 
16559 \family default
16560 dialog, you can manually edit your 
16561 \family typewriter
16562 .lyx/preferences
16563 \family default
16564  to add a line like
16565 \end_layout
16566
16567 \begin_layout LyX-Code
16568
16569 \backslash
16570 custom_export_command "mycommand $$FName"
16571 \end_layout
16572
16573 \begin_layout Section
16574 The Complete reLyX Description
16575 \begin_inset LatexCommand \label{sec:reLyX}
16576
16577 \end_inset
16578
16579
16580 \end_layout
16581
16582 \begin_layout Subsection
16583 Synopsis
16584 \end_layout
16585
16586 \begin_layout Standard
16587 The simplest way to use reLyX is via the 
16588 \family sans
16589 \bar under
16590 F
16591 \bar default
16592 ile\SpecialChar \menuseparator
16593
16594 \bar under
16595 I
16596 \bar default
16597 mport
16598 \family default
16599  command in LyX.
16600  That runs reLyX on the given file and loads the resulting file into LyX.
16601  You should try that first, and call it from the command line only if you
16602  need to use more complicated options.
16603 \end_layout
16604
16605 \begin_layout Standard
16606
16607 \series bold
16608 reLyX
16609 \series default
16610  [ 
16611 \series bold
16612 -c
16613 \series default
16614  
16615 \shape italic
16616 textclass
16617 \shape default
16618  ] [ 
16619 \series bold
16620 -df
16621 \series default
16622  ] [ 
16623 \series bold
16624 -o
16625 \series default
16626  
16627 \shape italic
16628 outputdir
16629 \shape default
16630  ] [
16631 \series bold
16632  -r
16633 \series default
16634 \shape italic
16635  renv1
16636 \shape default
16637 [,
16638 \shape italic
16639 renv2
16640 \shape default
16641 ...]] [
16642 \series bold
16643  -s
16644 \series default
16645 \shape italic
16646  sfile1
16647 \shape default
16648 [,
16649 \shape italic
16650 sfile2
16651 \shape default
16652 ...]] 
16653 \emph on
16654 inputfile
16655 \end_layout
16656
16657 \begin_layout Standard
16658
16659 \series bold
16660 reLyX
16661 \series default
16662  
16663 \series bold
16664 -p
16665 \series default
16666  
16667 \series bold
16668 -c
16669 \series default
16670  
16671 \shape italic
16672 textclass
16673 \shape default
16674  [ 
16675 \series bold
16676 -df
16677 \series default
16678  ] [ 
16679 \series bold
16680 -o
16681 \series default
16682  
16683 \shape italic
16684 outputdir
16685 \shape default
16686  ] [
16687 \series bold
16688  -r
16689 \series default
16690 \shape italic
16691  renv1
16692 \shape default
16693 [,
16694 \shape italic
16695 renv2
16696 \shape default
16697 ...]] [
16698 \series bold
16699  -s
16700 \series default
16701 \shape italic
16702  sfile1
16703 \shape default
16704 [,
16705 \shape italic
16706 sfile2
16707 \shape default
16708 ...]] 
16709 \emph on
16710 inputfiles
16711 \end_layout
16712
16713 \begin_layout Standard
16714
16715 \series bold
16716 reLyX
16717 \series default
16718  
16719 \series bold
16720 -h
16721 \end_layout
16722
16723 \begin_layout Subsection
16724 Options
16725 \end_layout
16726
16727 \begin_layout Description
16728
16729 \series bold
16730 -c
16731 \series default
16732  Class.
16733  By default, when reLyX sees a 
16734 \family typewriter
16735
16736 \backslash
16737 documentclass{foo}
16738 \family default
16739  command, it creates a file of textclass 
16740 \begin_inset Quotes eld
16741 \end_inset
16742
16743 foo
16744 \begin_inset Quotes erd
16745 \end_inset
16746
16747  and reads the LyX layout file for that class.
16748   Use 
16749 \series bold
16750 -c
16751 \series default
16752  to declare a different textclass (and read a different layout file).
16753 \end_layout
16754
16755 \begin_layout Description
16756
16757 \series bold
16758 -d
16759 \series default
16760  Debug.
16761  By default, reLyX gives sparse output and deletes the temporary files which
16762  were created during translation.
16763  Using the 
16764 \series bold
16765 -d
16766 \series default
16767  flag will create much more output (both to stdout and stderr) and leave
16768  the temporary files around.
16769 \end_layout
16770
16771 \begin_layout Description
16772
16773 \series bold
16774 -f
16775 \series default
16776  Force.
16777  reLyX will not run if the 
16778 \family typewriter
16779 .lyx
16780 \family default
16781  file it would generate already exists Use the 
16782 \series bold
16783 -f
16784 \series default
16785  option (carefully) to clobber any existing files.
16786 \end_layout
16787
16788 \begin_layout Description
16789
16790 \series bold
16791 -h
16792 \series default
16793  Help.
16794  Print out usage information and quit
16795 \end_layout
16796
16797 \begin_layout Description
16798
16799 \series bold
16800 -o
16801 \series default
16802  Output directory.
16803  With this option, all temporary files and LyX output files (for the given
16804  input file, for any included files, or for any file fragments given with
16805  the 
16806 \series bold
16807 -p
16808 \series default
16809  option) will be put into 
16810 \shape italic
16811 outputdir
16812 \shape default
16813 .
16814  Otherwise, for each file 
16815 \emph on
16816 dir/foo.tex
16817 \emph default
16818 , the temporary files and the LyX output file will be created in 
16819 \emph on
16820 dir
16821 \emph default
16822 .
16823  This can be useful if a file includes files from other directories which
16824  you want to consolidate in one directory, or if you don't have write permission
16825  on the directory the LaTeX files are in.
16826 \end_layout
16827
16828 \begin_layout Description
16829
16830 \series bold
16831 -p
16832 \series default
16833  Partial file.
16834  The input files are LaTeX fragments, with no preamble matter or 
16835 \family typewriter
16836
16837 \backslash
16838 begin{document}
16839 \family default
16840  commands.
16841  This option requires the 
16842 \series bold
16843 -c
16844 \series default
16845  option, since there are no 
16846 \family typewriter
16847
16848 \backslash
16849 documentclass
16850 \family default
16851  commands in the files reLyX is translating.
16852  When using this option, you can translate more than one file, as long as
16853  all files are the same class.
16854  The LyX file created by reLyX can be included in an existing LyX file using
16855  
16856 \family sans
16857 \bar under
16858 I
16859 \bar default
16860 nsert\SpecialChar \menuseparator
16861 Fil
16862 \bar under
16863 e
16864 \bar default
16865 \SpecialChar \menuseparator
16866 Ly
16867 \bar under
16868 X
16869 \bar default
16870 \InsetSpace ~
16871 Document
16872 \family default
16873 .
16874 \end_layout
16875
16876 \begin_layout Description
16877
16878 \series bold
16879 -r
16880 \series default
16881  Regular environments (see the Section\InsetSpace ~
16882
16883 \begin_inset LatexCommand \ref{sub:relyx-syntax}
16884
16885 \end_inset
16886
16887 ).
16888   If you give more than one environment, separate them with commas (not
16889  spaces).
16890  You'll probably need to quote the environment list, especially if it has
16891  asterisk environments (foo*) in it.
16892  If you use this command often, considering creating a personal syntax file.
16893 \end_layout
16894
16895 \begin_layout Description
16896
16897 \series bold
16898 -s
16899 \series default
16900  Syntax files.
16901  Input (one or more quoted, comma-separated) syntax files to read in addition
16902  to the default.
16903  (see the section Section\InsetSpace ~
16904
16905 \begin_inset LatexCommand \ref{sub:relyx-syntax}
16906
16907 \end_inset
16908
16909  for details).
16910 \end_layout
16911
16912 \begin_layout Subsection
16913 Description
16914 \end_layout
16915
16916 \begin_layout Subsubsection
16917 Introduction
16918 \end_layout
16919
16920 \begin_layout Standard
16921 reLyX will create a LyX file 
16922 \emph on
16923 dir/foo.lyx
16924 \emph default
16925  from the LaTeX file 
16926 \emph on
16927 dir/foo.tex
16928 \emph default
16929  (unless the 
16930 \series bold
16931 -o
16932 \series default
16933  option is used).
16934 \end_layout
16935
16936 \begin_layout Standard
16937 Suffixes 
16938 \family typewriter
16939 .tex
16940 \family default
16941
16942 \family typewriter
16943 .ltx
16944 \family default
16945  and 
16946 \family typewriter
16947 .latex
16948 \family default
16949  are supported.
16950  If 
16951 \emph on
16952 inputfile
16953 \emph default
16954  does not exist and does not have one of these suffixes, reLyX will try
16955  to translate 
16956 \emph on
16957 inputfile.tex
16958 \emph default
16959 .
16960  (This is similar to the behavior of LaTeX.)
16961 \end_layout
16962
16963 \begin_layout Standard
16964 The purpose of reLyX is to translate 
16965 \shape italic
16966 well-behaved
16967 \shape default
16968  LaTeX2e into LyX.
16969  If your LaTeX file doesn't compile---or if you do weird things, like redefining
16970  standard LaTeX commands---it may choke.
16971  LaTeX209 will often be translated correctly, but it's not guaranteed.
16972 \end_layout
16973
16974 \begin_layout Standard
16975 reLyX has some bugs and lacks a few features.
16976  However, its main goals are:
16977 \end_layout
16978
16979 \begin_layout Itemize
16980 Get through a well-behaved LaTeX2e file without crashing
16981 \end_layout
16982
16983 \begin_layout Itemize
16984 Translate a lot of that file.
16985 \end_layout
16986
16987 \begin_layout Itemize
16988 Localize the parts that can't be translated and copy them in TeX mode
16989 \end_layout
16990
16991 \begin_layout Standard
16992 It achieves these main goals pretty well on most files.
16993 \end_layout
16994
16995 \begin_layout Standard
16996 There are many improvements that can and will be made to reLyX in the future.
16997  However, we wanted to get reLyX out there early on, to make it easier for
16998  new LyX users to read in their existing LaTeX files.
16999 \end_layout
17000
17001 \begin_layout Subsubsection
17002 Usage
17003 \end_layout
17004
17005 \begin_layout Standard
17006 Here's a more lengthy description of what you should do to translate a LaTeX
17007  document into LyX.
17008 \end_layout
17009
17010 \begin_layout Itemize
17011 Run reLyX.
17012 \end_layout
17013
17014 \begin_deeper
17015 \begin_layout Standard
17016 reLyX will inform you of its progress and give any warnings to stderr, so
17017  if you don't want any output at all, try (in csh) 
17018 \begin_inset Quotes eld
17019 \end_inset
17020
17021
17022 \family typewriter
17023 reLyX foo.tex >& /dev/null
17024 \family default
17025
17026 \begin_inset Quotes erd
17027 \end_inset
17028
17029  or (in bash) 
17030 \begin_inset Quotes eld
17031 \end_inset
17032
17033
17034 \family typewriter
17035 reLyX foo.tex
17036 \family default
17037  
17038 \family typewriter
17039 2>&1 >/dev/null
17040 \family default
17041
17042 \begin_inset Quotes erd
17043 \end_inset
17044
17045 .
17046  You should NOT redirect standard output to 
17047 \family typewriter
17048 foo.lyx
17049 \family default
17050 .
17051  
17052 \end_layout
17053
17054 \end_deeper
17055 \begin_layout Itemize
17056 Run LyX on the resulting .lyx file.
17057 \end_layout
17058
17059 \begin_deeper
17060 \begin_layout Standard
17061 In theory, most of the file will have been translated, and anything that's
17062  untranslatable will be highlighted in red (TeX mode).
17063  In theory, LyX will be able to read in the file, and to create printed
17064  documents from it, because all that untranslated red stuff will be passed
17065  directly back to LaTeX, which LyX  uses as a backend.
17066  Unfortunately, reality doesn't always reflect theory.
17067  If reLyX crashes, or LyX cannot read the generated LyX file, see Section\InsetSpace ~
17068
17069 \begin_inset LatexCommand \ref{sub:relyx-bugs}
17070
17071 \end_inset
17072
17073  or the 
17074 \family typewriter
17075 BUGS
17076 \family default
17077  file.
17078 \end_layout
17079
17080 \end_deeper
17081 \begin_layout Itemize
17082 Change things that are in ERT boxes (TeX code) by hand in LyX.
17083 \end_layout
17084
17085 \begin_deeper
17086 \begin_layout Standard
17087 As mentioned above, you should be able to print out the LyX file even without
17088  doing this.
17089  However, changing a command in TeX mode to the corresponding LyX object
17090  will allow you to take advantage of LyX's WYSIWYM editing.
17091 \end_layout
17092
17093 \begin_layout Standard
17094 reLyX is not guaranteed to create a LyX file which generates exactly the
17095  same output as the LaTeX file, but it should come close.
17096  reLyX will generally err on the side of translating less to ensure that
17097  dvi or ps files are accurate, even though this leads to more 
17098 \begin_inset Quotes eld
17099 \end_inset
17100
17101 evil red text
17102 \begin_inset Quotes erd
17103 \end_inset
17104
17105  and less WYSIWYM.
17106 \end_layout
17107
17108 \end_deeper
17109 \begin_layout Itemize
17110 PROOFREAD THE DOCUMENT!!
17111 \end_layout
17112
17113 \begin_deeper
17114 \begin_layout Standard
17115 I'm sure you were planning on doing this anyway, but it's particularly important
17116  after translating a LaTeX document.
17117  reLyX is, at least now, better at 
17118 \begin_inset Quotes eld
17119 \end_inset
17120
17121 macro-translating
17122 \begin_inset Quotes erd
17123 \end_inset
17124
17125  (translating the whole document) than 
17126 \begin_inset Quotes eld
17127 \end_inset
17128
17129 micro-translating
17130 \begin_inset Quotes erd
17131 \end_inset
17132
17133  (translating every little detail).
17134  For example, you may see extra spaces or deleted spaces.
17135  Space handling has improved, but it's not perfect.
17136 \end_layout
17137
17138 \end_deeper
17139 \begin_layout Subsubsection
17140 What reLyX Can Handle
17141 \end_layout
17142
17143 \begin_layout Standard
17144 reLyX understands many LaTeX commands.
17145  It will translate:
17146 \end_layout
17147
17148 \begin_layout Itemize
17149 regular text, including mini-commands like ~, '', 
17150 \family typewriter
17151
17152 \backslash
17153 @
17154 \family default
17155
17156 \family typewriter
17157
17158 \backslash
17159 TeX
17160 \family default
17161 , as well as accented characters like 
17162 \family typewriter
17163
17164 \backslash
17165 '{a}
17166 \family default
17167 , and the special cases ?` and !`
17168 \end_layout
17169
17170 \begin_layout Itemize
17171 title commands like 
17172 \family typewriter
17173
17174 \backslash
17175 author
17176 \family default
17177
17178 \family typewriter
17179
17180 \backslash
17181 date
17182 \family default
17183
17184 \family typewriter
17185
17186 \backslash
17187 title
17188 \family default
17189
17190 \family typewriter
17191
17192 \backslash
17193 thanks
17194 \family default
17195  and the abstract environment
17196 \end_layout
17197
17198 \begin_layout Itemize
17199 heading commands like 
17200 \family typewriter
17201
17202 \backslash
17203 section
17204 \family default
17205  including starred commands (
17206 \family typewriter
17207
17208 \backslash
17209 section*
17210 \family default
17211 )
17212 \end_layout
17213
17214 \begin_layout Itemize
17215 Environments: 
17216 \family typewriter
17217 quote
17218 \family default
17219
17220 \family typewriter
17221 quotation
17222 \family default
17223 , and 
17224 \family typewriter
17225 verse
17226 \family default
17227
17228 \family typewriter
17229 center
17230 \family default
17231
17232 \family typewriter
17233 flushright
17234 \family default
17235 , and 
17236 \family typewriter
17237 flushleft
17238 \end_layout
17239
17240 \begin_layout Itemize
17241
17242 \family typewriter
17243 itemize
17244 \family default
17245
17246 \family typewriter
17247 enumerate
17248 \family default
17249 , and 
17250 \family typewriter
17251 description
17252 \family default
17253  environments, and their 
17254 \family typewriter
17255
17256 \backslash
17257 item
17258 \family default
17259  commands.
17260  Also, well-behaved nested lists
17261 \end_layout
17262
17263 \begin_layout Itemize
17264 cross-referencing commands: 
17265 \family typewriter
17266
17267 \backslash
17268 ref
17269 \family default
17270
17271 \family typewriter
17272
17273 \backslash
17274 pageref
17275 \family default
17276
17277 \family typewriter
17278
17279 \backslash
17280 label
17281 \family default
17282 , and 
17283 \family typewriter
17284
17285 \backslash
17286 cite
17287 \end_layout
17288
17289 \begin_layout Itemize
17290
17291 \family typewriter
17292
17293 \backslash
17294 footnote
17295 \family default
17296  and 
17297 \family typewriter
17298
17299 \backslash
17300 margin
17301 \end_layout
17302
17303 \begin_layout Itemize
17304 font-changing commands including 
17305 \family typewriter
17306
17307 \backslash
17308 em
17309 \family default
17310
17311 \family typewriter
17312
17313 \backslash
17314 emph
17315 \family default
17316
17317 \family typewriter
17318
17319 \backslash
17320 textit
17321 \family default
17322 , and corresponding commands to change family, size, series, and shape
17323 \end_layout
17324
17325 \begin_layout Itemize
17326
17327 \family typewriter
17328
17329 \backslash
17330 input{foo}
17331 \family default
17332  (or 
17333 \family typewriter
17334
17335 \backslash
17336 input{foo.blah}
17337 \family default
17338 ) and 
17339 \family typewriter
17340
17341 \backslash
17342 include{foo}
17343 \family default
17344 .
17345  Plain TeX 
17346 \family typewriter
17347
17348 \backslash
17349 input
17350 \family default
17351  command 
17352 \begin_inset Quotes erd
17353 \end_inset
17354
17355
17356 \family typewriter
17357
17358 \backslash
17359 input foo.tex
17360 \family default
17361
17362 \begin_inset Quotes erd
17363 \end_inset
17364
17365  is also supported.
17366 \end_layout
17367
17368 \begin_layout Itemize
17369
17370 \family typewriter
17371 tabular
17372 \family default
17373  environment, and commands that go inside it like 
17374 \family typewriter
17375
17376 \backslash
17377 hline
17378 \family default
17379
17380 \family typewriter
17381
17382 \backslash
17383 cline
17384 \family default
17385 , and 
17386 \family typewriter
17387
17388 \backslash
17389 multicolumn
17390 \family default
17391  (but see below)
17392 \end_layout
17393
17394 \begin_layout Itemize
17395 float environments 
17396 \family typewriter
17397 table
17398 \family default
17399  and 
17400 \family typewriter
17401 table*
17402 \family default
17403 , as well as 
17404 \family typewriter
17405
17406 \backslash
17407 caption
17408 \family default
17409  commands within them
17410 \end_layout
17411
17412 \begin_layout Itemize
17413
17414 \family typewriter
17415 thebibliography
17416 \family default
17417  environment and 
17418 \family typewriter
17419
17420 \backslash
17421 bibitem
17422 \family default
17423  command, as well as BibTeX's 
17424 \family typewriter
17425
17426 \backslash
17427 bibliography
17428 \family default
17429  and 
17430 \family typewriter
17431
17432 \backslash
17433 bibliographystyle
17434 \family default
17435  commands
17436 \end_layout
17437
17438 \begin_layout Itemize
17439 miscellaneous commands: 
17440 \family typewriter
17441
17442 \backslash
17443 hfill
17444 \family default
17445
17446 \family typewriter
17447
17448 \backslash
17449
17450 \backslash
17451
17452 \family default
17453
17454 \family typewriter
17455
17456 \backslash
17457 noindent
17458 \family default
17459
17460 \family typewriter
17461
17462 \backslash
17463 ldots
17464 \family default
17465 ...
17466 \end_layout
17467
17468 \begin_layout Itemize
17469 documentclass-specific environments (and some commands) which can be  translated
17470  to LyX layouts
17471 \end_layout
17472
17473 \begin_layout Itemize
17474 arguments to certain untranslatable commands (e.g.
17475  
17476 \family typewriter
17477
17478 \backslash
17479 mbox
17480 \family default
17481 )
17482 \end_layout
17483
17484 \begin_layout Standard
17485 Some of this support may not be 100% yet.
17486  See below for details
17487 \end_layout
17488
17489 \begin_layout Standard
17490 reLyX copies math (almost) verbatim from your LaTeX file.
17491  Luckily, LyX reads  in LaTeX math, so (almost) any math which is supported
17492  by LyX should work just fine.
17493  A few math commands which are not supported by LyX will be replaced with
17494  their equivalents, e.g., 
17495 \family typewriter
17496
17497 \backslash
17498 to
17499 \family default
17500  is converted to 
17501 \family typewriter
17502
17503 \backslash
17504 rightarrow
17505 \family default
17506 .
17507  See the section on 
17508 \shape italic
17509 Syntax Files
17510 \shape default
17511  for more details.
17512 \end_layout
17513
17514 \begin_layout Standard
17515 reLyX will also copy any preamble commands (i.e., anything before 
17516 \family typewriter
17517
17518 \backslash
17519 begin{document}
17520 \family default
17521 ) verbatim, so fancy stuff you've got in your preamble should be conserved
17522  in dvi and printed documents, although it will not of course show up in
17523  the LyX window.
17524  Check the preamble to make sure.
17525 \end_layout
17526
17527 \begin_layout Subsubsection
17528 What reLyX Can't Handle --- But it's OK
17529 \end_layout
17530
17531 \begin_layout Itemize
17532 figures and 
17533 \family typewriter
17534 tabular*
17535 \family default
17536  tables
17537 \end_layout
17538
17539 \begin_layout Itemize
17540 minipages
17541 \end_layout
17542
17543 \begin_layout Itemize
17544 spacing commands (
17545 \family typewriter
17546
17547 \backslash
17548 vspace
17549 \family default
17550
17551 \family typewriter
17552
17553 \backslash
17554 pagebreak
17555 \family default
17556
17557 \family typewriter
17558
17559 \backslash
17560 par
17561 \family default
17562 )
17563 \end_layout
17564
17565 \begin_layout Itemize
17566
17567 \family typewriter
17568
17569 \backslash
17570 centering
17571 \family default
17572
17573 \family typewriter
17574
17575 \backslash
17576 raggedleft
17577 \family default
17578
17579 \family typewriter
17580
17581 \backslash
17582 raggedright
17583 \end_layout
17584
17585 \begin_layout Itemize
17586
17587 \family typewriter
17588
17589 \backslash
17590 verb
17591 \family default
17592  and 
17593 \family typewriter
17594 verbatim
17595 \family default
17596  environment.
17597  reLyX is careful to copy 
17598 \shape italic
17599 exactly
17600 \shape default
17601  in this case, including comments and whitespace.
17602 \end_layout
17603
17604 \begin_layout Itemize
17605 some unknown (e.g., user-defined) environments and commands
17606 \end_layout
17607
17608 \begin_layout Standard
17609 reLyX copies unknown commands, along with their arguments, verbatim into
17610  the LyX file.
17611  Also, if it sees a 
17612 \family typewriter
17613
17614 \backslash
17615 begin{foo}
17616 \family default
17617  where it doesn't recognize the 
17618 \begin_inset Quotes eld
17619 \end_inset
17620
17621 foo
17622 \begin_inset Quotes erd
17623 \end_inset
17624
17625  environment, it will copy verbatim until it sees 
17626 \family typewriter
17627
17628 \backslash
17629 end{foo}
17630 \family default
17631  (unless you use the 
17632 \series bold
17633 -r
17634 \series default
17635  option).
17636  Hopefully, then, most of these unknown commands won't cause reLyX to break;
17637  they'll merely require you to do some editing once you've loaded the file
17638  up in LyX.
17639   That should be less painful than editing either the 
17640 \family typewriter
17641 .tex
17642 \family default
17643  or the 
17644 \family typewriter
17645 .lyx
17646 \family default
17647  file using a text editor.
17648 \end_layout
17649
17650 \begin_layout Subsubsection
17651 What reLyX Handles Badly --- a.\InsetSpace ~
17652 k.\InsetSpace ~
17653 a.
17654  BUGS
17655 \begin_inset LatexCommand \label{sub:relyx-bugs}
17656
17657 \end_inset
17658
17659
17660 \end_layout
17661
17662 \begin_layout Standard
17663 Since reLyX is relatively new, it's got a number of problems.
17664   As it matures, these bugs will be squished.
17665  A number of bugs and missing features can be found listed on the LyX bug
17666  tracker, 
17667 \begin_inset LatexCommand \url[LyX Bugzilla]{http://bugzilla.lyx.org/}
17668
17669 \end_inset
17670
17671 .
17672 \end_layout
17673
17674 \begin_layout Standard
17675 If reLyX is choking on something, or LyX can't read it after reLyX translates
17676  it, the best thing to do is to put 
17677 \family typewriter
17678
17679 \backslash
17680 begin{reLyXskip}
17681 \family default
17682  before the offending text, and 
17683 \family typewriter
17684
17685 \backslash
17686 end{reLyXskip}
17687 \family default
17688  after it.
17689  I call this a 
17690 \begin_inset Quotes eld
17691 \end_inset
17692
17693 skip
17694 \begin_inset Quotes erd
17695 \end_inset
17696
17697  block.
17698  reLyX will copy this block exactly, in TeX mode.
17699  Then edit the resulting LyX file, and translate the unknown stuff by hand.
17700  The 
17701 \family typewriter
17702 reLyXskip
17703 \family default
17704  environment is magical; the 
17705 \family typewriter
17706
17707 \backslash
17708 begin
17709 \family default
17710  and 
17711 \family typewriter
17712
17713 \backslash
17714 end
17715 \family default
17716  commands will not be put into the LyX file.
17717 \end_layout
17718
17719 \begin_layout Itemize
17720 \begin_inset Quotes eld
17721 \end_inset
17722
17723 Exact
17724 \begin_inset Quotes erd
17725 \end_inset
17726
17727  copying of unknown environments and commands isn't quite exact.
17728  Specifically, newlines and comments may be lost.
17729  This will yield ugly LyX, but in almost all cases the output will be the
17730  same.
17731  However, certain parts of the file will be copied perfectly, including
17732  whitespace and comments.
17733  This includes: the LaTeX preamble, 
17734 \family typewriter
17735 verbatim
17736 \family default
17737  environments and 
17738 \family typewriter
17739
17740 \backslash
17741 verb
17742 \family default
17743  commands, and skip blocks.
17744 \end_layout
17745
17746 \begin_layout Itemize
17747 reLyX translates only a few options to the 
17748 \family typewriter
17749
17750 \backslash
17751 documentclass
17752 \family default
17753  command.
17754  (Specifically 1[012]pt, [letter|legal|executive|a4|a5|b5]paper, [one|two]side,
17755  landscape, and [one|two]column.) Other options are placed in the extra class
17756  options field in the 
17757 \family sans
17758 \bar under
17759 D
17760 \bar default
17761 ocument\SpecialChar \menuseparator
17762
17763 \bar under
17764 S
17765 \bar default
17766 ettings
17767 \family default
17768  dialog.
17769 \end_layout
17770
17771 \begin_deeper
17772 \begin_layout Standard
17773 More importantly, reLyX doesn't translate 
17774 \family typewriter
17775
17776 \backslash
17777 usepackage
17778 \family default
17779  commands, margin  commands, 
17780 \family typewriter
17781
17782 \backslash
17783 newcommand
17784 \family default
17785 s, or, in fact, anything else from the preamble.
17786  It simply copies them into the LaTeX preamble.
17787  If you have margin commands in your preamble, then the LyX file will generate
17788  the right margins.
17789  However, these margins will override any margins you set in the LyX 
17790 \family sans
17791 \bar under
17792 D
17793 \bar default
17794 ocument
17795 \bar under
17796 \SpecialChar \menuseparator
17797 S
17798 \bar default
17799 ettings
17800 \family default
17801  dialog.
17802  So you should remove the options from the preamble to be safe.
17803  The same goes for setting your language with babel, 
17804 \family typewriter
17805
17806 \backslash
17807 inputencoding
17808 \family default
17809
17810 \family typewriter
17811
17812 \backslash
17813 pagestyle
17814 \family default
17815 , etc.
17816 \end_layout
17817
17818 \end_deeper
17819 \begin_layout Itemize
17820 The foil class has a couple bugs.
17821  reLyX may do weird things with optional arguments to 
17822 \family typewriter
17823
17824 \backslash
17825 foilhead
17826 \family default
17827  commands.
17828  Also, it may handle 
17829 \family typewriter
17830
17831 \backslash
17832 begin{dinglist}
17833 \family default
17834  incorrectly (although the stuff in the environment should translate normally).
17835 \end_layout
17836
17837 \begin_layout Standard
17838 reLyX is hopefully rather robust.
17839  As mentioned above, it may not translate your file perfectly, but it shouldn't
17840  crash.
17841  If it does crash---and the problem is not one of those mentioned above
17842  or in the 
17843 \emph on
17844 BUGS
17845 \emph default
17846  file---see Section\InsetSpace ~
17847
17848 \begin_inset LatexCommand \ref{sub:relyx-bug-reports}
17849
17850 \end_inset
17851
17852 .
17853 \end_layout
17854
17855 \begin_layout Subsubsection
17856 What LyX Can't Handle
17857 \end_layout
17858
17859 \begin_layout Standard
17860 LyX itself is missing a couple features, such that even if reLyX translates
17861  things perfectly, LyX may still have trouble reading it.
17862  If you really need these features, you can export your final document as
17863  LaTeX, and put them back in.
17864  See 
17865 \emph on
17866 BUGS
17867 \emph default
17868  for more details on these bugs.
17869 \end_layout
17870
17871 \begin_layout Itemize
17872 For a number of commands, LyX does not support the optional argument.
17873  Examples include 
17874 \family typewriter
17875
17876 \backslash
17877 sqrt
17878 \family default
17879
17880 \family typewriter
17881
17882 \backslash
17883 chapter
17884 \family default
17885  (and other sectioning commands), and 
17886 \family typewriter
17887
17888 \backslash
17889
17890 \backslash
17891
17892 \family default
17893 .
17894  reLyX will automatically discard the optional arguments with a warning
17895  to stdout.
17896  LyX also ignores the width argument for the 
17897 \family typewriter
17898 thebibliography
17899 \family default
17900  environment.
17901 \end_layout
17902
17903 \begin_layout Itemize
17904 Centering (or right or left justifying) works on full paragraphs.
17905 \end_layout
17906
17907 \begin_layout Itemize
17908 LyX support for tables isn't perfect.
17909  For complicated tables, use a 
17910 \begin_inset Quotes eld
17911 \end_inset
17912
17913 skip
17914 \begin_inset Quotes erd
17915 \end_inset
17916
17917  block, so that they will be copied in TeX mode.
17918 \end_layout
17919
17920 \begin_layout Itemize
17921 The LyX math editor can't handle the AMS-LaTeX math environments align,
17922  split, etc.
17923  So those environments will be copied in TeX mode.
17924  You can change 
17925 \family typewriter
17926 equation*
17927 \family default
17928  environments to the exactly equivalent displaymath, and then they will
17929  be translated correctly.
17930 \end_layout
17931
17932 \begin_layout Subsection
17933 Examples
17934 \end_layout
17935
17936 \begin_layout Standard
17937
17938 \family typewriter
17939 reLyX -df -o 
17940 \begin_inset Quotes eld
17941 \end_inset
17942
17943 my/dir
17944 \begin_inset Quotes erd
17945 \end_inset
17946
17947  -r 
17948 \begin_inset Quotes eld
17949 \end_inset
17950
17951 myenv
17952 \begin_inset Quotes erd
17953 \end_inset
17954
17955  foo.tex > foo.debug
17956 \end_layout
17957
17958 \begin_layout Standard
17959 The above will create a file my/dir/foo.lyx from foo.tex, overwriting if necessary.
17960   When it finds a 
17961 \family typewriter
17962
17963 \backslash
17964 begin{myenv} ...
17965  
17966 \backslash
17967 end{myenv}
17968 \family default
17969  block, it will translate the stuff within the block, but copy the 
17970 \family typewriter
17971
17972 \backslash
17973 begin
17974 \family default
17975  and 
17976 \family typewriter
17977
17978 \backslash
17979 end
17980 \family default
17981  commands in TeX mode.
17982   Finally, I'm going to keep the temporary files around (they will also
17983  be in my/dir/) and output lots of debugging information into the file foo.debug.
17984 \end_layout
17985
17986 \begin_layout Subsection
17987 Notes
17988 \end_layout
17989
17990 \begin_layout Subsubsection
17991 Bug Reports
17992 \begin_inset LatexCommand \label{sub:relyx-bug-reports}
17993
17994 \end_inset
17995
17996
17997 \end_layout
17998
17999 \begin_layout Standard
18000 If reLyX is crashing or otherwise acting strangely---in ways other than
18001  those described in Section\InsetSpace ~
18002
18003 \begin_inset LatexCommand \ref{sub:relyx-bugs}
18004
18005 \end_inset
18006
18007  or the bug tracker---then please run reLyX
18008 \series bold
18009  -d
18010 \series default
18011 .
18012   That will allow you to figure out where in the reLyXing process it crashed.
18013  That, in turn, will allow you to write a better bug report, which will
18014  allow the developers to fix it more quickly and easily.
18015 \end_layout
18016
18017 \begin_layout Standard
18018 Bug reports should be sent to the LyX developers' mailing list.
18019  Its address is currently 
18020 \family typewriter
18021 lyx-devel@lists.lyx.org
18022 \family default
18023 .
18024  If you are running reLyX on a huge file, please do not send all of the
18025  output in your bug report.
18026  Just include the last ten or twenty lines of output, along with the piece
18027  of the LaTeX file it crashed on.
18028   Or, even better, attach a small but complete file which causes the same
18029  problem as your original file.
18030 \end_layout
18031
18032 \begin_layout Subsubsection
18033 Implementation Details:
18034 \end_layout
18035
18036 \begin_layout Standard
18037 reLyX makes several 
18038 \begin_inset Quotes eld
18039 \end_inset
18040
18041 passes
18042 \begin_inset Quotes erd
18043 \end_inset
18044
18045  in order to translate a TeX file.
18046  On each pass, it creates one or two files.
18047 \end_layout
18048
18049 \begin_layout Description
18050 Pass\InsetSpace ~
18051 0 \InsetSpace ~
18052
18053 \newline
18054 Before doing anything, read the syntax file (or files).
18055 \end_layout
18056
18057 \begin_layout Description
18058 Pass\InsetSpace ~
18059 1a \InsetSpace ~
18060
18061 \newline
18062 Split preamble (anything before a 
18063 \family typewriter
18064
18065 \backslash
18066 begin{document}
18067 \family default
18068  command) off the rest of the file.
18069  It saves the two pieces in separate files.
18070  This is necessary because there may be very strange stuff in a preamble.
18071  It also ignores anything after the 
18072 \family typewriter
18073
18074 \backslash
18075 end{document}
18076 \family default
18077 , on the assumption that it isn't LaTeX.
18078 \end_layout
18079
18080 \begin_layout Description
18081 Pass\InsetSpace ~
18082 1b \InsetSpace ~
18083
18084 \newline
18085 Translate the preamble.
18086  Currently, that just means translating the 
18087 \family typewriter
18088
18089 \backslash
18090 documentclass
18091 \family default
18092  command and copying the rest exactly into the LyX preamble.
18093 \end_layout
18094
18095 \begin_deeper
18096 \begin_layout Standard
18097 Once you know what class the document is, read the LyX layout file for that
18098  class.
18099 \end_layout
18100
18101 \end_deeper
18102 \begin_layout Description
18103 Pass\InsetSpace ~
18104 2 \InsetSpace ~
18105
18106 \newline
18107
18108 \begin_inset Quotes eld
18109 \end_inset
18110
18111 Clean
18112 \begin_inset Quotes erd
18113 \end_inset
18114
18115  the TeX file, generating slightly stricter LaTeX.
18116  This includes:
18117 \end_layout
18118
18119 \begin_deeper
18120 \begin_layout Itemize
18121 Change, e.g., 
18122 \family typewriter
18123 x^2
18124 \family default
18125  to the equivalent but clearer 
18126 \family typewriter
18127 x^{2}
18128 \end_layout
18129
18130 \begin_layout Itemize
18131 Removing optional arguments that LyX can't handle (e.g., from 
18132 \family typewriter
18133
18134 \backslash
18135 sqrt
18136 \family default
18137 )
18138 \end_layout
18139
18140 \begin_layout Itemize
18141 Changing 
18142 \family typewriter
18143 {
18144 \backslash
18145 em foo}
18146 \family default
18147  to 
18148 \family typewriter
18149
18150 \backslash
18151 emph{foo}
18152 \family default
18153 , etc.
18154  This is necessary because LyX always writes out the non-local forms anyway.
18155  This should very rarely make a difference.
18156 \end_layout
18157
18158 \end_deeper
18159 \begin_layout Description
18160 Pass\InsetSpace ~
18161 3 \InsetSpace ~
18162
18163 \newline
18164 Translate LaTeX text, commands, and environments to LyX.
18165 \end_layout
18166
18167 \begin_layout Description
18168 Pass\InsetSpace ~
18169 4 \InsetSpace ~
18170
18171 \newline
18172 Put the two pieces back together, and do some final tweaking, to generate
18173  the LyX file
18174 \end_layout
18175
18176 \begin_layout Standard
18177 If there are any 
18178 \family typewriter
18179
18180 \backslash
18181 input
18182 \family default
18183  or 
18184 \family typewriter
18185
18186 \backslash
18187 include
18188 \family default
18189  commands, reLyX will loop back to the beginning and translate those.
18190  It assumes that the included files are the same class as the main file,
18191  and that they have no preamble matter.
18192  (If you have an 
18193 \family typewriter
18194
18195 \backslash
18196 input
18197 \family default
18198  command in the preamble of a file, the command will be copied exactly into
18199  the LaTeX preamble portion of the LyX file, so the included file won't
18200  be translated.) So when translating included files, it skips passes 0 and
18201  1.
18202 \end_layout
18203
18204 \begin_layout Standard
18205 If reLyX doesn't find a file you wanted to include, it will give a warning,
18206  but will continue to translate any files it does find.
18207 \end_layout
18208
18209 \begin_layout Subsubsection
18210 Layout Files
18211 \end_layout
18212
18213 \begin_layout Standard
18214 reLyX reads a LyX layout file to know how to handle LaTeX environments and
18215  commands which get translated to LyX layouts.
18216  This file will include all 
18217 \begin_inset Quotes eld
18218 \end_inset
18219
18220 normal
18221 \begin_inset Quotes erd
18222 \end_inset
18223
18224  non-math environments (i.e., including quote and itemize, but not tabular,
18225  minipage, and some other fancy environments), and commands like 
18226 \family typewriter
18227
18228 \backslash
18229 section
18230 \family default
18231  and 
18232 \family typewriter
18233
18234 \backslash
18235 title
18236 \family default
18237 .
18238  If you want to reLyX a class that doesn't have an existing layout file,
18239  then you'll have to create a layout file.
18240  But you have to do this anyway, in order to LyX the file, since LyX depends
18241  on layout files to know how to display and process its files.
18242  Check the LyX documentation for help with this task (which can be hard
18243  or easy, depending on the class you want to create a layout file for.) If
18244  your class is quite similar to a class that has a layout file, then consider
18245  using the 
18246 \series bold
18247 -c
18248 \series default
18249  option.
18250 \end_layout
18251
18252 \begin_layout Subsubsection
18253 Syntax Files
18254 \begin_inset LatexCommand \label{sub:relyx-syntax}
18255
18256 \end_inset
18257
18258
18259 \end_layout
18260
18261 \begin_layout Standard
18262 reLyX always reads at least one syntax file, called the default syntax file.
18263  reLyX will read your personal syntax file if it exists; otherwise it will
18264  read the system-wide file.
18265  reLyX will read additional syntax files if you specify them with the 
18266 \series bold
18267 -s
18268 \series default
18269  option.
18270  (These extra files should have the same format as the default file, but
18271  will tend to be shorter, since they only have to specify extra commands
18272  not found in the default file.) A syntax file tells reLyX a few things.
18273 \end_layout
18274
18275 \begin_layout Standard
18276 First, it describes the syntax of each command, that is, how many required
18277  arguments and how many optional arguments the command takes.
18278  Knowing this makes it easier for reLyX to copy (in TeX mode) commands that
18279  it doesn't know how to translate.
18280  The syntax file simply has a command, followed by braces or brackets describing
18281  its arguments in the correct order.
18282  For example, a syntax file entry 
18283 \family typewriter
18284
18285 \backslash
18286 bibitem[]{}
18287 \family default
18288  means that the 
18289 \family typewriter
18290
18291 \backslash
18292 bibitem
18293 \family default
18294  command takes an optional argument followed by a required one, while the
18295  entry 
18296 \family typewriter
18297
18298 \backslash
18299 bf
18300 \family default
18301  means that the 
18302 \family typewriter
18303
18304 \backslash
18305 bf
18306 \family default
18307  command takes no arguments at all.
18308   When reLyX encounters a token that it doesn't know how to translate into
18309  LyX, it will copy the token---along with the correct number of arguments---exac
18310 tly.
18311   If the token is not in the syntax file, then reLyX just copies as many
18312  arguments as it finds.
18313   This means that it may copy too much.
18314  But since the user can specify additional syntax files, that shouldn't
18315  happen often.
18316 \end_layout
18317
18318 \begin_layout Standard
18319 Some commands that cannot be translated to LyX, like 
18320 \family typewriter
18321
18322 \backslash
18323 mbox
18324 \family default
18325 , have as one of their arguments regular LaTeX text.
18326  If the string 
18327 \begin_inset Quotes eld
18328 \end_inset
18329
18330 translate
18331 \begin_inset Quotes erd
18332 \end_inset
18333
18334  is put into an argument of an (untranslatable) command in the syntax file,
18335  then reLyX will translate that argument instead of copying it verbatim.
18336  So, for example, the default syntax file has 
18337 \family typewriter
18338
18339 \backslash
18340 raisebox{}[][]{translate}
18341 \family default
18342 .
18343  This means that the 
18344 \family typewriter
18345
18346 \backslash
18347 raisebox
18348 \family default
18349  command and the first argument (and optional arguments if they exist) are
18350  copied in TeX mode, but the last argument (which may contain math, complicated
18351  LaTeX, other untranslatable commands, etc.) will be translated into LyX.
18352  You can't use 
18353 \begin_inset Quotes eld
18354 \end_inset
18355
18356 translate
18357 \begin_inset Quotes erd
18358 \end_inset
18359
18360  on optional arguments.
18361 \end_layout
18362
18363 \begin_layout Standard
18364 User-defined syntax files are allowed to define new commands and their syntax,
18365  or override the number of arguments for a command given in the default
18366  syntax file.
18367  (E.g., if you're using a style that gives an extra argument to some command...)
18368  However, this will only be useful for commands copied in TeX mode.
18369  Commands which are actually translated by reLyX (like 
18370 \family typewriter
18371
18372 \backslash
18373 item
18374 \family default
18375 ) have their argument syntax hard-coded.
18376  The hard-coded commands are identified in the default syntax file.
18377 \end_layout
18378
18379 \begin_layout Standard
18380 Second, the syntax file describes any 
18381 \begin_inset Quotes eld
18382 \end_inset
18383
18384 regular environments
18385 \begin_inset Quotes erd
18386 \end_inset
18387
18388 .
18389   Usually, an entire unknown environment will be copied in TeX mode.
18390  If you define a regular environment 
18391 \begin_inset Quotes eld
18392 \end_inset
18393
18394 foo
18395 \begin_inset Quotes erd
18396 \end_inset
18397
18398 , though, then only the 
18399 \family typewriter
18400
18401 \backslash
18402 begin{foo}
18403 \family default
18404  and 
18405 \family typewriter
18406
18407 \backslash
18408 end{foo}
18409 \family default
18410  commands will be copied in TeX mode; the text within the environment will
18411  be treated (i.e., translated) by reLyX as regular LaTeX, rather than being
18412  copied into TeX mode.
18413  Don't try to declare 
18414 \family typewriter
18415 tabbing
18416 \family default
18417  and 
18418 \family typewriter
18419 picture
18420 \family default
18421  as regular environments, as the text within those environments will confuse
18422  reLyX; use this capability for new environments you create that have plain
18423  text or math or simple commands in them.
18424  You also can't declare unknown math environments (like 
18425 \family typewriter
18426 equation*
18427 \family default
18428 ) as regular environments, either, since the LyX math editor won't understand
18429  them.
18430  The names of regular environments appear, whitespace-separated, between
18431  
18432 \family typewriter
18433
18434 \backslash
18435 begin{reLyXre}
18436 \family default
18437  and 
18438 \family typewriter
18439
18440 \backslash
18441 end{reLyXre}
18442 \family default
18443  statements in the syntax file.
18444  (If you have a regular environment which you won't use very often, you
18445  can use the 
18446 \series bold
18447 -r
18448 \series default
18449  option rather than writing a syntax file.)
18450 \end_layout
18451
18452 \begin_layout Standard
18453 Third, the syntax file describes a math translation table.
18454  The LyX math editor doesn't support a few commands.
18455  For example, 
18456 \family typewriter
18457 _
18458 \family default
18459  is supported, but the equivalent 
18460 \family typewriter
18461
18462 \backslash
18463 sb
18464 \family default
18465  is not.
18466  Put any commands you'd like translate between 
18467 \family typewriter
18468
18469 \backslash
18470 begin{reLyXmt}
18471 \family default
18472  and 
18473 \family typewriter
18474
18475 \backslash
18476 end{reLyXmt}
18477 \family default
18478  statements.
18479  The statement 
18480 \begin_inset Quotes eld
18481 \end_inset
18482
18483
18484 \family typewriter
18485
18486 \backslash
18487 | {
18488 \backslash
18489 Vert}
18490 \family default
18491
18492 \begin_inset Quotes erd
18493 \end_inset
18494
18495  means that any 
18496 \family typewriter
18497
18498 \backslash
18499 |
18500 \family default
18501  in math mode will be converted to 
18502 \begin_inset Quotes eld
18503 \end_inset
18504
18505
18506 \family typewriter
18507
18508 \backslash
18509 Vert
18510 \family default
18511  
18512 \begin_inset Quotes erd
18513 \end_inset
18514
18515
18516 \family typewriter
18517  
18518 \family default
18519 (in cases where a token made up of a backslash and a non-letter is translated
18520  to something with letters at the end, a space is added by reLyX.
18521  That way, 
18522 \begin_inset Quotes eld
18523 \end_inset
18524
18525
18526 \family typewriter
18527
18528 \backslash
18529 |a
18530 \family default
18531
18532 \begin_inset Quotes erd
18533 \end_inset
18534
18535  is correctly translated to 
18536 \begin_inset Quotes eld
18537 \end_inset
18538
18539
18540 \family typewriter
18541
18542 \backslash
18543 Vert a
18544 \family default
18545
18546 \begin_inset Quotes erd
18547 \end_inset
18548
18549 ).
18550 \end_layout
18551
18552 \begin_layout Subsubsection
18553 Miscellaneous
18554 \end_layout
18555
18556 \begin_layout Standard
18557 You need Perl version 5.002 or later to run reLyX.
18558  <plug> If you don't have Perl, you should get it anyway (at 
18559 \begin_inset LatexCommand \url[Perl]{http://www.perl.com/}
18560
18561 \end_inset
18562
18563 ), because it's a really useful tool for pretty much anything.
18564  </plug>
18565 \end_layout
18566
18567 \begin_layout Subsection
18568 Diagnostics
18569 \end_layout
18570
18571 \begin_layout Standard
18572 reLyX should always explain why it crashes, if it crashes.
18573  Some diagnostics may be very technical, though, if they come from the guts
18574  of the code.
18575  reLyX gives much more information while running if you use the 
18576 \series bold
18577 -d
18578 \series default
18579  option, but you shouldn't need that unless something goes wrong.
18580 \end_layout
18581
18582 \begin_layout Standard
18583 When it's finished, reLyX will tell you if it finished successfully or died
18584  due to some error.
18585 \end_layout
18586
18587 \begin_layout Subsection
18588 Warnings
18589 \end_layout
18590
18591 \begin_layout Standard
18592 Always keep a copy of your original LaTeX files either under a different
18593  name or in a different directory.
18594  There are a couple ways in which using LyX could lead to overwriting the
18595  original LaTeX file.
18596 \end_layout
18597
18598 \begin_layout Standard
18599 If you import 
18600 \family typewriter
18601 foo.tex
18602 \family default
18603  to create 
18604 \family typewriter
18605 foo.lyx
18606 \family default
18607 , then edit 
18608 \family typewriter
18609 foo.lyx
18610 \family default
18611  and want to re-export it, note that it will overwrite the original 
18612 \family typewriter
18613 foo.tex
18614 \family default
18615 .
18616  (LyX will 
18617 \emph on
18618 not
18619 \emph default
18620  ask you if you want to overwrite it.)
18621 \end_layout
18622
18623 \begin_layout Standard
18624 If you have chosen not to use a temporary directory in the preferences,
18625  then LyX will create its temporary files in your current directory, which
18626  means your LaTeX original may be overwritten (without a warning from LyX)
18627  when you 
18628 \begin_inset Quotes eld
18629 \end_inset
18630
18631 view dvi
18632 \begin_inset Quotes erd
18633 \end_inset
18634
18635  or print the LyX document.
18636 \end_layout
18637
18638 \begin_layout Subsection
18639 Files
18640 \end_layout
18641
18642 \begin_layout Description
18643
18644 \family typewriter
18645 \series medium
18646 MY_LYXDIR/layouts/*.layout
18647 \family default
18648 \series default
18649  \InsetSpace ~
18650
18651 \newline
18652 User's personal layout files for document classes
18653 \end_layout
18654
18655 \begin_layout Description
18656
18657 \family typewriter
18658 \series medium
18659 MY_LYXDIR/reLyX/syntax.default
18660 \family default
18661 \series default
18662  \InsetSpace ~
18663
18664 \newline
18665 User's personal syntax file
18666 \end_layout
18667
18668 \begin_layout Description
18669
18670 \family typewriter
18671 \series medium
18672 LIBDIR/layouts/*.layout
18673 \family default
18674 \series default
18675  \InsetSpace ~
18676
18677 \newline
18678 System-wide layout files for document classes
18679 \end_layout
18680
18681 \begin_layout Description
18682
18683 \family typewriter
18684 \series medium
18685 LIBDIR/reLyX/syntax.default
18686 \family default
18687 \series default
18688  \InsetSpace ~
18689
18690 \newline
18691 System-wide LaTeX syntax file
18692 \end_layout
18693
18694 \begin_layout Standard
18695
18696 \family typewriter
18697 LIBDIR
18698 \family default
18699  is the system-wide LyX directory, usually something like 
18700 \family typewriter
18701 /usr/local/share/lyx/
18702 \family default
18703 .
18704  
18705 \family typewriter
18706 MY_LYXDIR
18707 \family default
18708  is your personal LyX directory, something like 
18709 \family typewriter
18710 .lyx/
18711 \family default
18712  in your home directory.
18713  You can see their actual values in the 
18714 \family sans
18715 \bar under
18716 H
18717 \bar default
18718 elp\SpecialChar \menuseparator
18719 About\InsetSpace ~
18720 Ly
18721 \bar under
18722 X
18723 \family default
18724 \bar default
18725  dialog.
18726 \end_layout
18727
18728 \begin_layout Subsection
18729 See also
18730 \end_layout
18731
18732 \begin_layout Standard
18733
18734 \shape italic
18735 lyx
18736 \shape default
18737 (1), 
18738 \shape italic
18739 latex
18740 \shape default
18741 (1)
18742 \end_layout
18743
18744 \begin_layout Subsection
18745 Authors
18746 \end_layout
18747
18748 \begin_layout Standard
18749 Copyright (c) 1998--9 
18750 \noun on
18751 Amir Karger
18752 \noun default
18753  (
18754 \family typewriter
18755 karger@voth.chem.utah.edu
18756 \family default
18757 )
18758 \end_layout
18759
18760 \begin_layout Standard
18761 Code contributors:
18762 \end_layout
18763
18764 \begin_layout Itemize
18765
18766 \noun on
18767 John Weiss
18768 \noun default
18769  wrote the original CleanTeX pass.
18770 \end_layout
18771
18772 \begin_layout Itemize
18773
18774 \noun on
18775 Etienne Grossmann
18776 \end_layout
18777
18778 \begin_layout Itemize
18779
18780 \noun on
18781 Jos\i \'{e}
18782  Ab\i \'{\i}
18783 lio Oliveira Matos
18784 \end_layout
18785
18786 \begin_layout Itemize
18787
18788 \noun on
18789 David Suarez de Lis
18790 \end_layout
18791
18792 \begin_layout Standard
18793 Other contributors:
18794 \end_layout
18795
18796 \begin_layout Itemize
18797
18798 \noun on
18799 Jean-Marc Lasgouttes
18800 \noun default
18801  worked on the wrapper script and offered lots of bug reports, advice, and
18802  feature suggestions.
18803 \end_layout
18804
18805 \begin_layout Itemize
18806
18807 \noun on
18808 Asger K.
18809  Alstrup Nielsen
18810 \noun default
18811  and 
18812 \noun on
18813 Marc Pavese
18814 \noun default
18815  provided advice.
18816 \end_layout
18817
18818 \begin_layout Itemize
18819 Various members of the LyX developers' and users' lists provided bug reports
18820  and feature suggestions.
18821 \end_layout
18822
18823 \begin_layout Standard
18824 reLyX uses a modified version the Perl TeX parser 
18825 \family typewriter
18826 Text::TeX
18827 \family default
18828  package written by 
18829 \noun on
18830 Ilya Zakharevich
18831 \noun default
18832  (
18833 \family typewriter
18834 ilya@math.ohio-state.edu
18835 \family default
18836 ), available on CPAN.
18837 \end_layout
18838
18839 \begin_layout Chapter
18840 LyX Features needing Extra Software
18841 \end_layout
18842
18843 \begin_layout Section
18844 Using LyX with SGML-Tools (aka LinuxDoc)
18845 \end_layout
18846
18847 \begin_layout Standard
18848 by 
18849 \noun on
18850 Paul Evans
18851 \end_layout
18852
18853 \begin_layout Subsection
18854 Overview
18855 \end_layout
18856
18857 \begin_layout Standard
18858 LinuxDoc is a document class available in LyX if you have the 
18859 \family typewriter
18860 sgml-tools
18861 \family default
18862  package installed.
18863  You can use it to produce documents in the so-called Standardized General
18864  Mark-up Language (SGML) in the particular format used by the Linux Documentatio
18865 n Project.
18866  That is obviously helpful if you are contributing to that project.
18867  You can use the SGML format with the 
18868 \family typewriter
18869 sgml-tools
18870 \family default
18871  package of scripts and programs (to produce other formats, including Latex,
18872  HTML, plain text, man pages and\SpecialChar \ldots{}
18873 ).
18874  You may therefore prefer to use this document class if you want to write
18875  something that can be easily translated into other formats.
18876 \end_layout
18877
18878 \begin_layout Standard
18879 You will find that LinuxDoc has fewer layout options than the other text
18880  classes in LyX.
18881  This is mainly so that the translations into other formats have a chance
18882  of making some sense.
18883  In this section we describe:
18884 \end_layout
18885
18886 \begin_layout Itemize
18887 how to setup and use a document in LinuxDoc
18888 \end_layout
18889
18890 \begin_layout Itemize
18891 how to use the tags in LinuxDoc to layout your document
18892 \end_layout
18893
18894 \begin_layout Itemize
18895 how to use the SGML packages to produce the various formats
18896 \end_layout
18897
18898 \begin_layout Itemize
18899 how to sort out some problems.
18900 \end_layout
18901
18902 \begin_layout Subsection
18903 Preparing and using a LinuxDoc document
18904 \end_layout
18905
18906 \begin_layout Subsubsection
18907 Getting started
18908 \end_layout
18909
18910 \begin_layout Standard
18911 You start by selecting the LinuxDoc class using the 
18912 \family sans
18913 \bar under
18914 D
18915 \bar default
18916 ocument\SpecialChar \menuseparator
18917
18918 \bar under
18919 S
18920 \bar default
18921 ettings
18922 \family default
18923  dialog.
18924
18925 \family sans
18926  
18927 \family default
18928 Then you will find that there are fewer paragraph environments than for
18929  most other classes.
18930  You can see them on the pull down box on the left of the tool bar.
18931  How to use them is described in section\InsetSpace ~
18932
18933 \begin_inset LatexCommand \ref{sec:sgmlparas}
18934
18935 \end_inset
18936
18937 .
18938 \end_layout
18939
18940 \begin_layout Standard
18941 You 
18942 \emph on
18943 must
18944 \emph default
18945  enter a title for the document, followed by an author, marking each with
18946  the appropriate paragraph environment.
18947  If you don't do this, you will get errors when you try to print the file.
18948  You can then enter the date and an abstract.
18949  The document proper must start with a Section paragraph environment rather
18950  than any standard layout.
18951 \end_layout
18952
18953 \begin_layout Standard
18954 After that you can prepare a document as usual using the available range
18955  of paragraph environments.
18956  See section\InsetSpace ~
18957
18958 \begin_inset LatexCommand \ref{sec:sgmlparas}
18959
18960 \end_inset
18961
18962  for the full list and their uses.
18963 \end_layout
18964
18965 \begin_layout Subsubsection
18966 Output from LinuxDoc
18967 \end_layout
18968
18969 \begin_layout Standard
18970 You can print and save these documents in the normal way.
18971  To use the other features of the SGML package you need to save your document
18972  as LinuxDoc; this is a version in which the document is translated into
18973  the basic sgml tags.
18974  Use
18975 \family sans
18976  
18977 \bar under
18978 F
18979 \bar default
18980 ile\SpecialChar \menuseparator
18981
18982 \bar under
18983 E
18984 \bar default
18985 xport\SpecialChar \menuseparator
18986 Linu
18987 \bar under
18988 x
18989 \bar default
18990 Doc.
18991
18992 \family default
18993  You will get a file with the same name and a 
18994 \family typewriter
18995 .sgml
18996 \family default
18997  extension rather than a 
18998 \family typewriter
18999 .lyx
19000 \family default
19001  extension.
19002  See\InsetSpace ~
19003
19004 \begin_inset LatexCommand \ref{sec:sgmloperate}
19005
19006 \end_inset
19007
19008  on how you than make use of this file.
19009 \end_layout
19010
19011 \begin_layout Subsection
19012 Using the paragraph environments in LinuxDoc
19013 \end_layout
19014
19015 \begin_layout Subsubsection
19016 The Structure of a LinuxDoc Document
19017 \end_layout
19018
19019 \begin_layout Standard
19020 There is a formal structure for LinuxDoc which limits how you can place
19021  tags.
19022  There are two parts to all documents: 
19023 \end_layout
19024
19025 \begin_layout Description
19026 Header: this is everything up to the first time you insert a Section layout
19027  marker.
19028  It can include title, author, date, abstract and ToC.
19029  You must include the first two.
19030 \end_layout
19031
19032 \begin_layout Description
19033 Body: from the beginning of the first section onwards.
19034  All other tags are allowed.
19035  
19036 \end_layout
19037
19038 \begin_layout Subsubsection
19039 The LinuxDoc Paragraph Environments
19040 \end_layout
19041
19042 \begin_layout Standard
19043 \begin_inset LatexCommand \label{sec:sgmlparas}
19044
19045 \end_inset
19046
19047 Here is a list of all the tags you will find listed on the layout bar in
19048  the order they come there, with some comments where the purpose or use
19049  is not obvious:
19050 \end_layout
19051
19052 \begin_layout Itemize
19053
19054 \family sans
19055 Standard:
19056 \family roman
19057  works as described in [cross reference]
19058 \end_layout
19059
19060 \begin_layout Itemize
19061
19062 \family sans
19063 Title
19064 \family default
19065 : This will appear at the top left of the document when printed, above a
19066  heavy horizontal rule, although you will not see this on the LyX screen.
19067 \end_layout
19068
19069 \begin_layout Itemize
19070
19071 \family sans
19072 Section, Subsection, Subsubsection, Paragraph and Subparagraph:
19073 \family default
19074  all do what you would expect and in the usual order.
19075  Whether they are numbered or not is controlled by the 
19076 \family sans
19077 Section\InsetSpace ~
19078 number\InsetSpace ~
19079 depth
19080 \family default
19081  setting.
19082  You cannot get the equivalent number free versions in any other way; there
19083  is no 
19084 \family sans
19085 Section*
19086 \family default
19087  or similar
19088 \end_layout
19089
19090 \begin_layout Itemize
19091
19092 \family sans
19093 Enumerate:
19094 \family default
19095  As usual this produces a numbered and indented list as described in the
19096  
19097 \emph on
19098 User's Guide
19099 \emph default
19100 .
19101 \end_layout
19102
19103 \begin_layout Itemize
19104
19105 \family sans
19106 Itemize: 
19107 \family roman
19108 Again much the same as in the other classes: see the 
19109 \emph on
19110 User's Guide
19111 \emph default
19112 .
19113 \end_layout
19114
19115 \begin_layout Itemize
19116
19117 \family sans
19118 Description
19119 \family default
19120 : As explained in the 
19121 \emph on
19122 User's Guide
19123 \emph default
19124 .
19125  Remember that if you want the bold element at the start of a description
19126  to be more than one word then you need to put protected spaces between
19127  the words.
19128  
19129 \end_layout
19130
19131 \begin_layout Itemize
19132
19133 \family sans
19134 Verbatim: 
19135 \family default
19136 As usual.
19137 \end_layout
19138
19139 \begin_layout Itemize
19140
19141 \family sans
19142 Code: similar to the Lyx-Code
19143 \family roman
19144  environment
19145 \end_layout
19146
19147 \begin_layout Itemize
19148
19149 \family sans
19150 Author
19151 \family default
19152 : Anything you mark with this will appear on the left of the heading of
19153  the document, under the heavy rule.
19154 \end_layout
19155
19156 \begin_layout Itemize
19157
19158 \family sans
19159 Date:
19160 \family default
19161  Anything you mark with this will appear on the right of the heading under
19162  the rule.
19163  You do not have to make this a date.
19164  Any text can be entered, e.\InsetSpace ~
19165 g.
19166  a version number.
19167 \end_layout
19168
19169 \begin_layout Itemize
19170
19171 \family sans
19172 Abstract
19173 \family default
19174 : You can use this to produce a free standing paragraph after the author
19175  and date, and before the first section.
19176  You are only allowed one such paragraph.
19177 \begin_inset Foot
19178 status collapsed
19179
19180 \begin_layout Standard
19181
19182 \emph on
19183 Author's note.
19184  
19185 \emph default
19186 This needs checking ---
19187 \emph on
19188 pe.
19189 \end_layout
19190
19191 \end_inset
19192
19193
19194 \end_layout
19195
19196 \begin_layout Itemize
19197
19198 \family sans
19199 Displaymath
19200 \family default
19201 :
19202 \begin_inset Foot
19203 status collapsed
19204
19205 \begin_layout Standard
19206
19207 \emph on
19208 Author's note: 
19209 \emph default
19210 I have not yet checked this ---
19211 \emph on
19212 pe.
19213 \end_layout
19214
19215 \end_inset
19216
19217
19218 \end_layout
19219
19220 \begin_layout Subsubsection
19221 Other document features
19222 \end_layout
19223
19224 \begin_layout Standard
19225 You can also use the 
19226 \family sans
19227 Layout 
19228 \family default
19229 menu to set fonts or to emphasis words.
19230  You can also use the table of contents as usual; see the corresponding
19231  section of the 
19232 \emph on
19233 User's Guide
19234 \emph default
19235 .
19236  Although you will find some some other features on the menus e.\InsetSpace ~
19237 g.
19238  inserting footnotes.
19239  There is some doubt about whether these will work correctly.
19240 \begin_inset Foot
19241 status collapsed
19242
19243 \begin_layout Standard
19244
19245 \emph on
19246 Author's note: 
19247 \emph default
19248 Again still checking to see whether this is my system
19249 \emph on
19250  ---pe.
19251 \end_layout
19252
19253 \end_inset
19254
19255
19256 \end_layout
19257
19258 \begin_layout Subsubsection
19259 Cross references and HTML 
19260 \end_layout
19261
19262 \begin_layout Standard
19263 On the
19264 \family sans
19265  Insert
19266 \family default
19267  menu you will find two new options relating to the inclusion of URL addresses.
19268  If you use either option you will find some highlighted TeX code inserted
19269  into your document in three separate blocks with spaces available between.
19270  The blocks will be:
19271 \end_layout
19272
19273 \begin_layout Quote
19274
19275 \family typewriter
19276
19277 \backslash
19278 htmlurl{
19279 \family default
19280  or 
19281 \family typewriter
19282
19283 \backslash
19284 url{
19285 \family roman
19286
19287 \hfill
19288 space
19289 \family default
19290  
19291 \family typewriter
19292
19293 \hfill
19294 }{
19295 \family roman
19296
19297 \hfill
19298 space
19299 \hfill
19300
19301 \family typewriter
19302 }
19303 \end_layout
19304
19305 \begin_layout Standard
19306 You insert a full HTML tag between the first and second blocks.
19307  This can be 
19308 \begin_inset LatexCommand \url{http://any.address}
19309
19310 \end_inset
19311
19312  or other valid tags such as 
19313 \begin_inset LatexCommand \url{mailto:me@my.address}
19314
19315 \end_inset
19316
19317
19318 \family typewriter
19319 .
19320 \family default
19321 Then y
19322 \family roman
19323 ou 
19324 \family default
19325 insert some description between the second and third blocks.
19326  The differences are:
19327 \end_layout
19328
19329 \begin_layout Itemize
19330
19331 \family sans
19332 URL:
19333 \family roman
19334  both the HTML tag and the description will appear in the document
19335 \end_layout
19336
19337 \begin_layout Itemize
19338
19339 \family sans
19340 HTML\InsetSpace ~
19341 URL: 
19342 \family roman
19343 only the description appears in the printed version
19344 \end_layout
19345
19346 \begin_layout Subsection
19347 Using the LinuxDoc Sgml scripts
19348 \begin_inset Note Note
19349 status collapsed
19350
19351 \begin_layout Standard
19352 This section is completely outdated.
19353 \end_layout
19354
19355 \end_inset
19356
19357
19358 \end_layout
19359
19360 \begin_layout Standard
19361 \begin_inset LatexCommand \label{sec:sgmloperate}
19362
19363 \end_inset
19364
19365 You can use LinuxDoc as a text class without any additional scripts or programs,
19366  but there is not much point in doing this.
19367  All you will get is a document that looks like a 
19368 \emph on
19369 Linux Documentation Project Howto
19370 \family sans
19371 \emph default
19372 .
19373  
19374 \family default
19375 To do the document translation you need to get and install the 
19376 \family typewriter
19377 sgml-tools-1.0.x.tar.gz 
19378 \family default
19379 (with 
19380 \begin_inset Formula $x\geq3$
19381 \end_inset
19382
19383 ) package from 
19384 \family roman
19385 the SGML-Tools WWW Page
19386 \family default
19387  at
19388 \end_layout
19389
19390 \begin_layout LyX-Code
19391
19392 \family roman
19393 \begin_inset LatexCommand \url{http://pobox.com/~cg/sgmltools}
19394
19395 \end_inset
19396
19397
19398 \family default
19399  
19400 \end_layout
19401
19402 \begin_layout Standard
19403 Alternatively, you can go to the 
19404 \family typewriter
19405 sunsite
19406 \family default
19407  archive at
19408 \begin_inset Foot
19409 status collapsed
19410
19411 \begin_layout Standard
19412 Note that, at the time of this writing (01/1998), version 1.0.3 of sgml-tools
19413  has not yet been made available at 
19414 \family typewriter
19415 sunsite
19416 \family default
19417 .
19418 \end_layout
19419
19420 \end_inset
19421
19422
19423 \end_layout
19424
19425 \begin_layout LyX-Code
19426
19427 \family roman
19428 \begin_inset LatexCommand \url{ftp://sunsite.unc.edu/pub/Linux/utils/text/sgml-tools-1.0.x.tar.gz}
19429
19430 \end_inset
19431
19432
19433 \end_layout
19434
19435 \begin_layout Standard
19436
19437 \family roman
19438 The
19439 \family default
19440  file 
19441 \family typewriter
19442 sgml-tools-1.0.x.tar.gz
19443 \family default
19444  contains everything that you need to write SGML documents and convert them
19445  to groff, LaTeX, HTML, GNU info, LyX, and RTF\SpecialChar \@.
19446
19447 \end_layout
19448
19449 \begin_layout Standard
19450 This package was renamed from 
19451 \family typewriter
19452 linuxdoc-sgml-1.5.tar.gz
19453 \family default
19454  in January 1997.
19455 \end_layout
19456
19457 \begin_layout Standard
19458 Follow the instructions in that package on how to install it and how to
19459  use it.
19460  All this has to be done outside of LyX, before you can use the 
19461 \family sans
19462 \bar under
19463 F
19464 \bar default
19465 ile\SpecialChar \menuseparator
19466
19467 \bar under
19468 E
19469 \bar default
19470 xport\SpecialChar \menuseparator
19471 as\InsetSpace ~
19472 LinuxDoc 
19473 \family roman
19474 option.
19475 \end_layout
19476
19477 \begin_layout Subsection
19478 Troubleshooting LinuxDoc
19479 \end_layout
19480
19481 \begin_layout Standard
19482 When you print or preview a LinuxDoc document some checking is done of the
19483  tags before LaTeX is run.
19484  Some errors are trapped here, especially those concerning the structure
19485  of the document.
19486  LyX may produce an error message, but not leave an error box in the document
19487  for you to open.
19488  You may have to look at the files directly to discover what is wrong.
19489  Most problems seem to come from the use of options that are not fully available
19490  in the text class.
19491 \end_layout
19492
19493 \begin_layout Section
19494 Checking TeX
19495 \end_layout
19496
19497 \begin_layout Standard
19498 by 
19499 \noun on
19500 Asger Alstrup
19501 \end_layout
19502
19503 \begin_layout Subsection
19504 Introduction
19505 \end_layout
19506
19507 \begin_layout Standard
19508 Under the 
19509 \family sans
19510 \bar under
19511 T
19512 \bar default
19513 ools
19514 \family default
19515  menu, you'll find a 
19516 \family sans
19517 \bar under
19518 C
19519 \bar default
19520 heck\InsetSpace ~
19521 TeX
19522 \family default
19523  command.
19524  This feature requires you to have the 
19525 \family typewriter
19526 chktex
19527 \family default
19528  program installed, and is grayed out if you don't have it.
19529  You can get it from your nearest CTAN mirror, or over the Web from 
19530 \begin_inset LatexCommand \url{http://www.ifi.uio.no/~jensthi/chktex/}
19531
19532 \end_inset
19533
19534 .
19535 \end_layout
19536
19537 \begin_layout Standard
19538 The 
19539 \family sans
19540 ChkTeX
19541 \family default
19542  package is a program that was written by 
19543 \noun on
19544 Jens T.
19545  Berger Thielemann
19546 \noun default
19547  in frustration because some constructs in LaTeX are sometimes non-intuitive,
19548  and easy to forget.
19549  The program runs over your LaTeX file and checks the integrity of the file,
19550  and flags some common errors.
19551  In other technical words, it is 
19552 \family typewriter
19553 Lint
19554 \family default
19555  for LaTeX.
19556 \end_layout
19557
19558 \begin_layout Standard
19559 Well, what is a syntax checker doing in LyX which is supposed to produce
19560  correct LaTeX anyways? The answer is simple: Just as 
19561 \family typewriter
19562 Lint
19563 \family default
19564  not only checks the 
19565 \emph on
19566 syntax
19567 \emph default
19568  of C programs, but also does 
19569 \emph on
19570 semantic
19571 \emph default
19572  checks for type-errors, 
19573 \family sans
19574 ChkTeX
19575 \family default
19576  catches some common 
19577 \emph on
19578 typographic
19579 \emph default
19580  errors, in addition to the syntactical ones.
19581  Specifically, 
19582 \family sans
19583 ChkTeX
19584 \family default
19585  is capable of detecting several common errors, such as
19586 \end_layout
19587
19588 \begin_layout Itemize
19589 Ellipsis detection:
19590 \newline
19591 Use \SpecialChar \ldots{}
19592  instead of ...
19593 \end_layout
19594
19595 \begin_layout Itemize
19596 No space in front of/after parenthesis:
19597 \newline
19598 ( wrong spacing )
19599 \end_layout
19600
19601 \begin_layout Itemize
19602 Enforcement of normal space after common abbreviations:
19603 \newline
19604 e.
19605  g.
19606  is too wide spacing.
19607 \end_layout
19608
19609 \begin_layout Itemize
19610 Enforcement of end-of-sentence space when the last sentence ends with a
19611  capital letter:
19612 \newline
19613 This is a TEST.
19614  And this is wrong spacing.
19615 \end_layout
19616
19617 \begin_layout Itemize
19618 Space in front of labels and similar commands:
19619 \newline
19620 The label should stick right
19621  up to the text to avoid falling to a wrong page.
19622  
19623 \begin_inset LatexCommand \label{sec:chktex}
19624
19625 \end_inset
19626
19627  
19628 \begin_inset Foot
19629 status collapsed
19630
19631 \begin_layout Standard
19632 This footnote is in danger of falling off to a wrong page
19633 \end_layout
19634
19635 \end_inset
19636
19637  The label is separated too much.
19638 \end_layout
19639
19640 \begin_layout Itemize
19641 Space in front of references, instead of hard spaces:
19642 \newline
19643 In you are in bad luck,
19644  the text will break right between the referenced text and reference number,
19645  and that's a pity.
19646  See section 
19647 \begin_inset LatexCommand \ref{sec:chktex}
19648
19649 \end_inset
19650
19651 .
19652 \end_layout
19653
19654 \begin_layout Itemize
19655 Use of 
19656 \begin_inset Quotes eld
19657 \end_inset
19658
19659 x
19660 \begin_inset Quotes erd
19661 \end_inset
19662
19663  instead of 
19664 \begin_inset Formula $\times$
19665 \end_inset
19666
19667  between numbers:
19668 \newline
19669 2x2 looks cheap compared to 
19670 \begin_inset Formula $2\times2$
19671 \end_inset
19672
19673 .
19674 \end_layout
19675
19676 \begin_layout Standard
19677 and more \SpecialChar \ldots{}
19678  It is an invaluable tool when you are 
19679 \begin_inset Quotes eld
19680 \end_inset
19681
19682 finishing up
19683 \begin_inset Quotes erd
19684 \end_inset
19685
19686  your document before printing, and you should run it right after the obligatory
19687  spelling check, and before you go fine tuning the typesetting.
19688 \end_layout
19689
19690 \begin_layout Subsection
19691 How to use it
19692 \end_layout
19693
19694 \begin_layout Standard
19695 If you have the program installed, usage is as simple as choosing 
19696 \family sans
19697 \bar under
19698 T
19699 \bar default
19700 ools\SpecialChar \menuseparator
19701
19702 \bar under
19703 C
19704 \bar default
19705 heck\InsetSpace ~
19706 TeX
19707 \family default
19708 .
19709  This will make LyX generate a LaTeX file of your document, start 
19710 \family sans
19711 ChkTeX
19712 \family default
19713  to check it, and then make LyX insert 
19714 \begin_inset Quotes eld
19715 \end_inset
19716
19717 error boxes
19718 \begin_inset Quotes erd
19719 \end_inset
19720
19721  with the warnings from 
19722 \family sans
19723 ChkTeX
19724 \family default
19725 , if there were any.
19726  The warnings will be placed close to the point of the mistake, and you
19727  can quickly find them by using the 
19728 \family sans
19729 \bar under
19730 N
19731 \bar default
19732 avigate\SpecialChar \menuseparator
19733
19734 \bar under
19735 E
19736 \bar default
19737 rror
19738 \family default
19739  menu item, or the shortcut key 
19740 \family sans
19741 C-g
19742 \family default
19743  from the default 
19744 \family typewriter
19745 cua
19746 \family default
19747  bind file.
19748  Open the error boxes by clicking on them with the mouse, or use the shortcut
19749  key 
19750 \family sans
19751 C-i
19752 \family default
19753  from 
19754 \family typewriter
19755 cua
19756 \family default
19757  bindings, or the corresponding 
19758 \family sans
19759 C-o
19760 \family default
19761  for the alternate 
19762 \family typewriter
19763 emacs
19764 \family default
19765  bind file.
19766  Read the warning and correct the mistake, if it is a mistake.
19767  If you have trouble understanding what the warning is about, you can safely
19768  ignore it.
19769  Remember that there is a hidden layer between the document on screen and
19770  the technical details in invoking 
19771 \family sans
19772 ChkTeX
19773 \family default
19774 , and this gap can make some warnings seem arcane or just right down plain
19775  silly.
19776 \end_layout
19777
19778 \begin_layout Standard
19779 This document is an excellent testing bed for the feature, and it should
19780  provide quite a few warnings for you to fiddle with.
19781  Since computers are only so smart, expect most of the warnings to be false
19782  alarms, though.
19783 \end_layout
19784
19785 \begin_layout Subsection
19786 How to fine tune it
19787 \end_layout
19788
19789 \begin_layout Standard
19790 Sometimes, you'll find that 
19791 \family sans
19792 ChkTeX
19793 \family default
19794  makes more noise than suits your mood.
19795  Then you can choose not to use it, wait until your mood changes, or try
19796  to customize 
19797 \family sans
19798 ChkTeX
19799 \family default
19800  to get better along with you.
19801  Another choice in the most desperate situations is to use 
19802 \family sans
19803 \bar under
19804 V
19805 \bar default
19806 iew\SpecialChar \menuseparator
19807
19808 \bar under
19809 R
19810 \bar default
19811 emove\InsetSpace ~
19812 All\InsetSpace ~
19813 Error\InsetSpace ~
19814 Boxes
19815 \family default
19816 , which will get rid of all warnings instantly.
19817 \end_layout
19818
19819 \begin_layout Standard
19820 Although 
19821 \family sans
19822 ChkTeX
19823 \family default
19824  
19825 \emph on
19826 is
19827 \emph default
19828  very configurable and extensible, you shouldn't expect to solve all problems
19829  with 
19830 \family sans
19831 ChkTeX
19832 \family default
19833  in LyX this way.
19834  Since LyX has to generate a somewhat special LaTeX file to be able to match
19835  the line numbers from the 
19836 \family sans
19837 ChkTeX
19838 \family default
19839  output
19840 \begin_inset Foot
19841 status collapsed
19842
19843 \begin_layout Standard
19844 You can inspect the specific output from 
19845 \family sans
19846 chktex
19847 \family default
19848  by using 
19849 \family sans
19850 Edit\SpecialChar \menuseparator
19851 View\InsetSpace ~
19852 LaTeX\InsetSpace ~
19853 Log
19854 \family default
19855  right after a 
19856 \family sans
19857 chktex
19858 \family default
19859  run.
19860 \end_layout
19861
19862 \end_inset
19863
19864  to the internal document structure, some of the warnings will not seen
19865  to appear correctly.
19866  There are two things you can do about this:
19867 \end_layout
19868
19869 \begin_layout Itemize
19870 Fine tune the 
19871 \family sans
19872 ChkTeX
19873 \family default
19874  invocation command line in 
19875 \family sans
19876 Preferences
19877 \family default
19878  (tabs 
19879 \family sans
19880 Outputs
19881 \family default
19882
19883 \family sans
19884 Misc
19885 \family default
19886 ), or the global 
19887 \family sans
19888 ChkTeX
19889 \family default
19890  installation configuration file (usually with the file 
19891 \family typewriter
19892 /usr/local/share/chktexrc
19893 \family default
19894 ).
19895  See below to learn what warnings can be enabled and disabled on the command
19896  line.
19897  
19898 \end_layout
19899
19900 \begin_layout Itemize
19901 Export your document as a raw LaTeX file using 
19902 \family sans
19903 \bar under
19904 F
19905 \bar default
19906 ile\SpecialChar \menuseparator
19907
19908 \bar under
19909 E
19910 \bar default
19911 xport\SpecialChar \menuseparator
19912
19913 \bar under
19914 L
19915 \bar default
19916 aTeX
19917 \family default
19918  and run 
19919 \family typewriter
19920 chktex
19921 \family default
19922  manually on that.
19923  Invoked in this way, it can be a hassle to find the corresponding place
19924  in the document inside LyX, but with a little patience, you should be able
19925  to do it.
19926 \end_layout
19927
19928 \begin_layout Standard
19929 Here follows the warning messages that can be enabled and disabled in 
19930 \family sans
19931 Preferences
19932 \family default
19933 .
19934  Use 
19935 \family typewriter
19936 -n#
19937 \family default
19938  to disable a warning, and 
19939 \family typewriter
19940 -w#
19941 \family default
19942  to enable a warning.
19943  The emphasized entries are disabled by default, because the default is
19944  "
19945 \family typewriter
19946 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19947 \family default
19948 ".
19949 \end_layout
19950
19951 \begin_layout Standard
19952 Notice that you should only use the options that enable and disable warnings,
19953  because LyX relies on some of the other command line parameters to be set
19954  in a specific way to have a chance to communicate with 
19955 \family typewriter
19956 chktex
19957 \family default
19958 .
19959 \end_layout
19960
19961 \begin_layout Enumerate
19962
19963 \size small
19964 \emph on
19965 Command terminated with space.
19966 \end_layout
19967
19968 \begin_layout Enumerate
19969
19970 \size small
19971 Non-breaking space (
19972 \begin_inset Quotes eld
19973 \end_inset
19974
19975
19976 \family typewriter
19977 ~
19978 \family default
19979
19980 \begin_inset Quotes erd
19981 \end_inset
19982
19983 ) should have been used.
19984 \end_layout
19985
19986 \begin_layout Enumerate
19987
19988 \size small
19989 \emph on
19990 You should enclose the previous parenthesis with 
19991 \begin_inset Quotes eld
19992 \end_inset
19993
19994
19995 \family typewriter
19996 {}
19997 \family default
19998
19999 \begin_inset Quotes erd
20000 \end_inset
20001
20002 .
20003 \end_layout
20004
20005 \begin_layout Enumerate
20006
20007 \size small
20008 Italic correction (
20009 \begin_inset Quotes eld
20010 \end_inset
20011
20012
20013 \family typewriter
20014
20015 \backslash
20016 /
20017 \family default
20018
20019 \begin_inset Quotes erd
20020 \end_inset
20021
20022 ) found in non-italic buffer.
20023 \end_layout
20024
20025 \begin_layout Enumerate
20026
20027 \size small
20028 Italic correction (
20029 \begin_inset Quotes eld
20030 \end_inset
20031
20032
20033 \family typewriter
20034
20035 \backslash
20036 /
20037 \family default
20038
20039 \begin_inset Quotes erd
20040 \end_inset
20041
20042 ) found more than once.
20043 \end_layout
20044
20045 \begin_layout Enumerate
20046
20047 \size small
20048 \emph on
20049 No italic correction (
20050 \begin_inset Quotes eld
20051 \end_inset
20052
20053
20054 \family typewriter
20055
20056 \backslash
20057 /
20058 \family default
20059
20060 \begin_inset Quotes erd
20061 \end_inset
20062
20063 ) found.
20064 \end_layout
20065
20066 \begin_layout Enumerate
20067
20068 \size small
20069 Accent command 
20070 \begin_inset Quotes eld
20071 \end_inset
20072
20073
20074 \family typewriter
20075 cmd
20076 \family default
20077
20078 \begin_inset Quotes erd
20079 \end_inset
20080
20081  needs use of 
20082 \begin_inset Quotes eld
20083 \end_inset
20084
20085
20086 \family typewriter
20087 cmd
20088 \family default
20089
20090 \begin_inset Quotes erd
20091 \end_inset
20092
20093 .
20094 \end_layout
20095
20096 \begin_layout Enumerate
20097
20098 \size small
20099 Wrong length of dash may have been used.
20100 \end_layout
20101
20102 \begin_layout Enumerate
20103
20104 \size small
20105 \emph on
20106 \begin_inset Quotes eld
20107 \end_inset
20108
20109
20110 \family typewriter
20111 %s
20112 \family default
20113
20114 \begin_inset Quotes erd
20115 \end_inset
20116
20117  expected, found 
20118 \begin_inset Quotes eld
20119 \end_inset
20120
20121
20122 \family typewriter
20123 %s
20124 \family default
20125
20126 \begin_inset Quotes erd
20127 \end_inset
20128
20129 .
20130 \end_layout
20131
20132 \begin_layout Enumerate
20133
20134 \size small
20135 Solo 
20136 \begin_inset Quotes eld
20137 \end_inset
20138
20139
20140 \family typewriter
20141 %s
20142 \family default
20143
20144 \begin_inset Quotes erd
20145 \end_inset
20146
20147  found.
20148 \end_layout
20149
20150 \begin_layout Enumerate
20151
20152 \size small
20153 You should use 
20154 \begin_inset Quotes eld
20155 \end_inset
20156
20157
20158 \family typewriter
20159 %s
20160 \family default
20161
20162 \begin_inset Quotes erd
20163 \end_inset
20164
20165  to achieve an ellipsis.
20166 \end_layout
20167
20168 \begin_layout Enumerate
20169
20170 \size small
20171 Inter-word spacing (
20172 \begin_inset Quotes eld
20173 \end_inset
20174
20175
20176 \family typewriter
20177
20178 \backslash
20179  
20180 \family default
20181
20182 \begin_inset Quotes eld
20183 \end_inset
20184
20185 ) should perhaps be used.
20186 \end_layout
20187
20188 \begin_layout Enumerate
20189
20190 \size small
20191 Inter-sentence spacing (
20192 \begin_inset Quotes eld
20193 \end_inset
20194
20195
20196 \family typewriter
20197
20198 \backslash
20199 @
20200 \family default
20201
20202 \begin_inset Quotes erd
20203 \end_inset
20204
20205 ) should perhaps be used.
20206 \end_layout
20207
20208 \begin_layout Enumerate
20209
20210 \size small
20211 Could not find argument for command.
20212 \end_layout
20213
20214 \begin_layout Enumerate
20215
20216 \size small
20217 No match found for 
20218 \begin_inset Quotes eld
20219 \end_inset
20220
20221
20222 \family typewriter
20223 %s
20224 \family default
20225
20226 \begin_inset Quotes erd
20227 \end_inset
20228
20229 .
20230 \end_layout
20231
20232 \begin_layout Enumerate
20233
20234 \size small
20235 Math mode still on at end of LaTeX file.
20236 \end_layout
20237
20238 \begin_layout Enumerate
20239
20240 \size small
20241 Number of 
20242 \begin_inset Quotes eld
20243 \end_inset
20244
20245
20246 \family typewriter
20247 char
20248 \family default
20249
20250 \begin_inset Quotes erd
20251 \end_inset
20252
20253  doesn't match the number of 
20254 \begin_inset Quotes eld
20255 \end_inset
20256
20257
20258 \family typewriter
20259 char
20260 \family default
20261
20262 \begin_inset Quotes erd
20263 \end_inset
20264
20265 .
20266 \end_layout
20267
20268 \begin_layout Enumerate
20269
20270 \size small
20271 You should use either 
20272 \family typewriter
20273
20274 \begin_inset Quotes eld
20275 \end_inset
20276
20277
20278 \family default
20279  or 
20280 \family typewriter
20281
20282 \begin_inset Quotes erd
20283 \end_inset
20284
20285
20286 \family default
20287  as an alternative to 
20288 \begin_inset Quotes eld
20289 \end_inset
20290
20291
20292 \family typewriter
20293 "
20294 \family default
20295
20296 \begin_inset Quotes erd
20297 \end_inset
20298
20299 .
20300 \end_layout
20301
20302 \begin_layout Enumerate
20303
20304 \size small
20305 You should use "
20306 \family typewriter
20307 '
20308 \family default
20309 " (ASCII 39) instead of "
20310 \family typewriter
20311 ´
20312 \family default
20313 " (ASCII 180).
20314 \end_layout
20315
20316 \begin_layout Enumerate
20317
20318 \size small
20319 User-specified pattern found.
20320 \end_layout
20321
20322 \begin_layout Enumerate
20323
20324 \size small
20325 This command might not be intended.
20326 \end_layout
20327
20328 \begin_layout Enumerate
20329
20330 \size small
20331 \emph on
20332 Comment displayed.
20333 \end_layout
20334
20335 \begin_layout Enumerate
20336
20337 \size small
20338 Either 
20339 \family typewriter
20340 ''
20341 \backslash
20342 ,'
20343 \family default
20344  or 
20345 \family typewriter
20346 '
20347 \backslash
20348 ,''
20349 \family default
20350  will look better.
20351 \end_layout
20352
20353 \begin_layout Enumerate
20354
20355 \size small
20356 Delete this space to maintain correct page references.
20357 \end_layout
20358
20359 \begin_layout Enumerate
20360
20361 \size small
20362 \emph on
20363 You might wish to put this between a pair of 
20364 \begin_inset Quotes eld
20365 \end_inset
20366
20367
20368 \family typewriter
20369 {}
20370 \family default
20371
20372 \begin_inset Quotes erd
20373 \end_inset
20374
20375 .
20376 \end_layout
20377
20378 \begin_layout Enumerate
20379
20380 \size small
20381 You ought to remove spaces in front of punctuation.
20382 \end_layout
20383
20384 \begin_layout Enumerate
20385
20386 \size small
20387 Could not execute LaTeX command.
20388 \end_layout
20389
20390 \begin_layout Enumerate
20391
20392 \size small
20393 Don't use 
20394 \family typewriter
20395
20396 \backslash
20397 /
20398 \family default
20399  in front of small punctuation.
20400 \end_layout
20401
20402 \begin_layout Enumerate
20403
20404 \family typewriter
20405 \size small
20406 $
20407 \backslash
20408 times$
20409 \family default
20410  may look prettier here.
20411 \end_layout
20412
20413 \begin_layout Enumerate
20414
20415 \size small
20416 \emph on
20417 Multiple spaces detected in output.
20418 \end_layout
20419
20420 \begin_layout Enumerate
20421
20422 \size small
20423 This text may be ignored.
20424 \end_layout
20425
20426 \begin_layout Enumerate
20427
20428 \size small
20429 Use 
20430 \family typewriter
20431
20432 \begin_inset Quotes eld
20433 \end_inset
20434
20435
20436 \family default
20437  to begin quotation, not 
20438 \family typewriter
20439 '
20440 \family default
20441 .
20442 \end_layout
20443
20444 \begin_layout Enumerate
20445
20446 \size small
20447 Use 
20448 \family typewriter
20449 '
20450 \family default
20451  to end quotation, not 
20452 \family typewriter
20453
20454 \begin_inset Quotes eld
20455 \end_inset
20456
20457
20458 \family default
20459 .
20460 \end_layout
20461
20462 \begin_layout Enumerate
20463
20464 \size small
20465 Don't mix quotes.
20466 \end_layout
20467
20468 \begin_layout Enumerate
20469
20470 \size small
20471 You should perhaps use 
20472 \begin_inset Quotes eld
20473 \end_inset
20474
20475
20476 \family typewriter
20477 cmd
20478 \family default
20479
20480 \begin_inset Quotes erd
20481 \end_inset
20482
20483  instead.
20484 \end_layout
20485
20486 \begin_layout Enumerate
20487
20488 \size small
20489 You should put a space in front of/after parenthesis.
20490 \end_layout
20491
20492 \begin_layout Enumerate
20493
20494 \size small
20495 You should avoid spaces in front of/after parenthesis.
20496 \end_layout
20497
20498 \begin_layout Enumerate
20499
20500 \size small
20501 \emph on
20502 You should not use punctuation in front of/after quotes.
20503 \end_layout
20504
20505 \begin_layout Enumerate
20506
20507 \size small
20508 Double space found.
20509 \end_layout
20510
20511 \begin_layout Enumerate
20512
20513 \size small
20514 You should put punctuation outside inner/inside display math mode.
20515 \end_layout
20516
20517 \begin_layout Enumerate
20518
20519 \size small
20520 You ought to not use primitive TeX in LaTeX code.
20521 \end_layout
20522
20523 \begin_layout Enumerate
20524
20525 \size small
20526 You should remove spaces in front of 
20527 \begin_inset Quotes eld
20528 \end_inset
20529
20530
20531 \family typewriter
20532 %s
20533 \family default
20534
20535 \begin_inset Quotes erd
20536 \end_inset
20537
20538
20539 \end_layout
20540
20541 \begin_layout Enumerate
20542
20543 \size small
20544 \begin_inset Quotes eld
20545 \end_inset
20546
20547
20548 \family typewriter
20549 %s
20550 \family default
20551
20552 \begin_inset Quotes erd
20553 \end_inset
20554
20555  is normally not followed by 
20556 \begin_inset Quotes eld
20557 \end_inset
20558
20559
20560 \family typewriter
20561 %c
20562 \family default
20563
20564 \begin_inset Quotes erd
20565 \end_inset
20566
20567 .
20568 \end_layout
20569
20570 \begin_layout Standard
20571 In later versions of LyX, we hope to provide a more complete interface to
20572  this tool (and it's smaller cousin 
20573 \family typewriter
20574 lacheck
20575 \family default
20576 ) to exploit the full power of it.
20577  But it's not exactly useless as it is now: go try it on one of your existing
20578  documents of a certain length and be surprised.
20579 \end_layout
20580
20581 \begin_layout Section
20582 Version Control in LyX
20583 \end_layout
20584
20585 \begin_layout Standard
20586 by
20587 \noun on
20588  Lars Gullik Bjønnes
20589 \end_layout
20590
20591 \begin_layout Subsection
20592 Introduction
20593 \end_layout
20594
20595 \begin_layout Standard
20596 A friend of mine wanted to try LyX for a group project.
20597  When he didn't find support for version control or file locking, he dropped
20598  it.
20599  This angered me a bit, so I thought that I should at least make support
20600  for RCS (with the possibility of CVS and/or SCCS as a future improvement.)
20601  This has now been done.
20602  LyX now supports some of the most basic RCS commands.
20603  If you need to something a bit more sophisticated you will have to do that
20604  manually in an xterm.
20605 \end_layout
20606
20607 \begin_layout Standard
20608 Before you begin to use the version control features in LyX, you should
20609  read 
20610 \begin_inset Quotes eld
20611 \end_inset
20612
20613 rcsintro
20614 \begin_inset Quotes erd
20615 \end_inset
20616
20617  (a man file, read it with 
20618 \family typewriter
20619 man rcsintro
20620 \family default
20621 ).
20622  This file describes all the basic features of RCS.
20623  You should especially notice the comment about a RCS directory, and the
20624  notion of a master RCS file (the file ending in 
20625 \family typewriter
20626 ,v
20627 \family default
20628 ).
20629 \end_layout
20630
20631 \begin_layout Standard
20632 The implementation in LyX assumes a recent version of the GNU RCS package---no
20633  guarantees are made for older versions.
20634 \end_layout
20635
20636 \begin_layout Subsection
20637 RCS commands in LyX
20638 \end_layout
20639
20640 \begin_layout Standard
20641 The following sections describe the RCS commands supported by LyX.
20642  You can find them in the 
20643 \family sans
20644 \bar under
20645 F
20646 \bar default
20647 ile\SpecialChar \menuseparator
20648
20649 \bar under
20650 V
20651 \bar default
20652 ersion\InsetSpace ~
20653 Control
20654 \family default
20655  submenu.
20656 \end_layout
20657
20658 \begin_layout Subsubsection
20659
20660 \family sans
20661 Register
20662 \end_layout
20663
20664 \begin_layout Standard
20665 If your document is not under revision control, this is the only item shown
20666  in the menu.
20667  And if it is under revision control, the 
20668 \family sans
20669 \bar under
20670 R
20671 \bar default
20672 egister
20673 \family default
20674  item is grayed out.
20675  
20676 \end_layout
20677
20678 \begin_layout Standard
20679 This command registers your document with RCS\SpecialChar \@.
20680  You are asked interactively
20681  to supply an initial description of the document.
20682  The document is now set in Read-Only mode and you have to 
20683 \family sans
20684 Check\InsetSpace ~
20685 Out\InsetSpace ~
20686 For\InsetSpace ~
20687 Edit
20688 \family default
20689 , before making any changes to it.
20690  A document under revision control has a 
20691 \begin_inset Quotes eld
20692 \end_inset
20693
20694 [RCS:<version> <locker>]
20695 \begin_inset Quotes erd
20696 \end_inset
20697
20698  item tagged to the filename in the minibuffer.
20699 \end_layout
20700
20701 \begin_layout Standard
20702 RCS command that is run: 
20703 \family typewriter
20704 ci -q -u -i -t-"<initial description>" <file-name>
20705 \end_layout
20706
20707 \begin_layout Standard
20708 Read 
20709 \family typewriter
20710 man ci
20711 \family default
20712  to understand the switches.
20713  
20714 \end_layout
20715
20716 \begin_layout Subsubsection
20717
20718 \family sans
20719 Check In Changes
20720 \end_layout
20721
20722 \begin_layout Standard
20723 When you are finished editing a file, you check in your changes.
20724  When you do this, you are asked for a description of the changes.
20725  This is stored in the history log.
20726  The version number is bumped, your changes are applied to the master RCS
20727  file, the document is unlocked and set to Read-Only mode.
20728  
20729 \end_layout
20730
20731 \begin_layout Standard
20732 RCS command: 
20733 \family typewriter
20734 ci -q -u -m"<description>" <file-name>
20735 \end_layout
20736
20737 \begin_layout Subsubsection
20738
20739 \family sans
20740 Check Out For Edit
20741 \end_layout
20742
20743 \begin_layout Standard
20744 By doing this you lock the document so that only you can edit it.
20745  This will also make the document Read-Write only for you.
20746  You will usually continue editing for a while and when you are finished
20747  you check in your changes.
20748  The status line is changed to reflect that you have locked the file.
20749  
20750 \end_layout
20751
20752 \begin_layout Standard
20753 RCS command: 
20754 \family typewriter
20755 co -q -l <file-name>
20756 \end_layout
20757
20758 \begin_layout Subsubsection
20759
20760 \family sans
20761 Revert To Last Version
20762 \end_layout
20763
20764 \begin_layout Standard
20765 This will discard all changes made to the document since the last check
20766  in.
20767  You get a warning before changes are discarded.
20768 \end_layout
20769
20770 \begin_layout Standard
20771 RCS command: 
20772 \family typewriter
20773 co -f -u<version> <file-name>
20774 \end_layout
20775
20776 \begin_layout Subsubsection
20777
20778 \family sans
20779 Undo Last Checkin
20780 \end_layout
20781
20782 \begin_layout Standard
20783 This makes as if the last check in never happened.
20784  No changes are made to the document loaded into LyX, but the last version
20785  is removed from the master RCS file.
20786  
20787 \end_layout
20788
20789 \begin_layout Standard
20790 RCS command: 
20791 \family typewriter
20792 rcs -o<version> <file-name>
20793 \end_layout
20794
20795 \begin_layout Subsubsection
20796
20797 \family sans
20798 Show History
20799 \end_layout
20800
20801 \begin_layout Standard
20802 This show the complete history of the RCS document.
20803  The output of 
20804 \family typewriter
20805 rlog <file-name>
20806 \family default
20807  is shown in a browser.
20808  See 
20809 \family typewriter
20810 man rlog
20811 \family default
20812  for more info.
20813 \end_layout
20814
20815 \begin_layout Section
20816 Literate Programming
20817 \end_layout
20818
20819 \begin_layout Standard
20820 Updated by 
20821 \noun on
20822 Kayvan Sylvan 
20823 \noun default
20824 (kayvan@sylvan.com)
20825 \noun on
20826
20827 \noun default
20828 original documentation written by 
20829 \noun on
20830 Edmar Wienskoski Jr.
20831
20832 \noun default
20833  (edmar-w-jr@technologist.com)
20834 \end_layout
20835
20836 \begin_layout Subsection
20837 Introduction
20838 \end_layout
20839
20840 \begin_layout Standard
20841 The main purpose of this documentation is to show you how to use LyX for
20842  literate programming.
20843  Where it is assumed that you are familiar with this programming technique,
20844  and know what 
20845 \begin_inset Quotes eld
20846 \end_inset
20847
20848 tangling
20849 \begin_inset Quotes erd
20850 \end_inset
20851
20852  and 
20853 \begin_inset Quotes eld
20854 \end_inset
20855
20856 weaving
20857 \begin_inset Quotes erd
20858 \end_inset
20859
20860  means.
20861  If that is not the case, please follow the web links provided in the following
20862  sections.
20863  There is a lot of good documentation out there covering old development
20864  history to the latest tools tips.
20865 \end_layout
20866
20867 \begin_layout Standard
20868 It is also assumed that you are familiar with LyX itself to a point that
20869  you are comfortable changing your LyX preferences, and X resources file.
20870  If that is not the case please refer to other LyX documentation to cover
20871  your specific needs.
20872 \end_layout
20873
20874 \begin_layout Subsection
20875 Literate Programming
20876 \end_layout
20877
20878 \begin_layout Standard
20879 From the Literate Programming FAQ: 
20880 \end_layout
20881
20882 \begin_layout Quotation
20883 Literate programming is the combination of documentation and source together
20884  in a fashion suited for reading by human beings.
20885  In fact, literate programs should be enjoyable reading, even inviting!
20886  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
20887  and documentation in a single file.
20888  Literate programming tools then parse the file to produce either readable
20889  documentation or compilable source.
20890  The WEB style of literate programming was created by D.E.
20891  Knuth during the development of his TeX typesetting software.
20892  
20893 \end_layout
20894
20895 \begin_layout Standard
20896 Another excerpt says:
20897 \end_layout
20898
20899 \begin_layout Quotation
20900
20901 \emph on
20902 How is literate programming different from verbose commenting?
20903 \end_layout
20904
20905 \begin_layout Quotation
20906 There are three distinguishing characteristics.
20907  In order of importance, they are: 
20908 \end_layout
20909
20910 \begin_deeper
20911 \begin_layout Itemize
20912 flexible order of elaboration 
20913 \end_layout
20914
20915 \begin_layout Itemize
20916 automatic support for browsing 
20917 \end_layout
20918
20919 \begin_layout Itemize
20920 typeset documentation, especially diagrams and mathematics 
20921 \end_layout
20922
20923 \end_deeper
20924 \begin_layout Standard
20925 Now that I sparked your curiosity, take a look in the references.
20926 \end_layout
20927
20928 \begin_layout Subsubsection
20929 References
20930 \end_layout
20931
20932 \begin_layout Standard
20933 The complete Literate Programming FAQ can be found at:
20934 \end_layout
20935
20936 \begin_layout Quote
20937 \begin_inset LatexCommand \url[Literate Programming FAQ]{http://shelob.ce.ttu.edu/daves/lpfaq/faq.html}
20938
20939 \end_inset
20940
20941
20942 \end_layout
20943
20944 \begin_layout Standard
20945 The FAQ lists 23 (twenty three!) different literate programming tools.
20946  Where some are specialized or 
20947 \begin_inset Quotes eld
20948 \end_inset
20949
20950 tailored
20951 \begin_inset Quotes erd
20952 \end_inset
20953
20954  for particular programming languages, while other have general scope.
20955  I selected 
20956 \noun on
20957 Noweb
20958 \noun default
20959  for my own use for several reasons:
20960 \end_layout
20961
20962 \begin_layout Itemize
20963 It can generate the documentation either in latex or html.
20964 \end_layout
20965
20966 \begin_layout Itemize
20967 It has a open architecture, i.e., it is easy to plug in new filters and to
20968  perform special processing that you may need.
20969  
20970 \end_layout
20971
20972 \begin_layout Itemize
20973 There is a good selection of filters available already (the html is one
20974  of them).
20975 \end_layout
20976
20977 \begin_layout Itemize
20978 It is free.
20979 \end_layout
20980
20981 \begin_layout Standard
20982 The Noweb web page can be found at: 
20983 \end_layout
20984
20985 \begin_layout Quote
20986 \begin_inset LatexCommand \url[Noweb home page]{http://www.cs.virginia.edu/~nr/noweb/}
20987
20988 \end_inset
20989
20990
20991 \end_layout
20992
20993 \begin_layout Standard
20994 Starting from there you can reach many other interesting links and even
20995  some literate program examples.
20996 \end_layout
20997
20998 \begin_layout Subsection
20999 LyX and Literate Programming
21000 \end_layout
21001
21002 \begin_layout Standard
21003 The LyX support for Literate Programming is provided by using the generic
21004  LyX convertors mechanism.
21005  This support is provided in a 
21006 \begin_inset Quotes eld
21007 \end_inset
21008
21009 Noweb independent
21010 \begin_inset Quotes erd
21011 \end_inset
21012
21013  way, i.e., you will be able to use this new LyX feature with some other literate
21014  programming tool of your choice by just changing your LyX preferences.
21015 \end_layout
21016
21017 \begin_layout Subsubsection
21018 Generating documents and code (weaving and tangling)
21019 \end_layout
21020
21021 \begin_layout Paragraph
21022 Selecting the document class
21023 \end_layout
21024
21025 \begin_layout Standard
21026 If you have installed Noweb and LyX successfully, whenever you open a new
21027  document or try to change the document class of an existing one, you will
21028  find that there are three new document classes available:
21029 \end_layout
21030
21031 \begin_layout Itemize
21032 Article (Noweb)
21033 \end_layout
21034
21035 \begin_layout Itemize
21036 Book (Noweb)
21037 \end_layout
21038
21039 \begin_layout Itemize
21040 Report (Noweb)
21041 \end_layout
21042
21043 \begin_layout Standard
21044 You must select one of them to create your literate documents from.
21045  
21046 \end_layout
21047
21048 \begin_layout Standard
21049 Note that literate documents are not limited to these three classes.
21050  New classes can be generated from other styles like letter or in combination
21051  with other class variations like Article (AMS).
21052  If you have special needs that cannot be covered by one of the existing
21053  classes, let the LyX developers list (lyx-devel@lists.lyx.org) know and we
21054  will arrange to insert a new entry, or teach you how to do it.
21055 \begin_inset Foot
21056 status collapsed
21057
21058 \begin_layout Standard
21059 It is very simple, it involves the creation of a file with four lines, and
21060  re-running of the auto configuration.
21061 \end_layout
21062
21063 \end_inset
21064
21065  Moreover, if you use a literate tool other than Noweb you may need to create
21066  a new set of document classes for it.
21067 \end_layout
21068
21069 \begin_layout Paragraph
21070 Typing code in
21071 \end_layout
21072
21073 \begin_layout Standard
21074 LyX enables you to write code with a layout named 
21075 \noun on
21076 Scrap
21077 \noun default
21078 .
21079 \begin_inset Foot
21080 status collapsed
21081
21082 \begin_layout Standard
21083 The equivalent Noweb term is 
21084 \begin_inset Quotes eld
21085 \end_inset
21086
21087 Chunk
21088 \begin_inset Quotes erd
21089 \end_inset
21090
21091 .
21092  For historical reasons, I got used to the term 
21093 \begin_inset Quotes eld
21094 \end_inset
21095
21096 scrap
21097 \begin_inset Quotes erd
21098 \end_inset
21099
21100  introduced by other literate tool named Nuweb, which I used for many years
21101  before rendering myself to Noweb.
21102 \end_layout
21103
21104 \end_inset
21105
21106  Noweb delimits scraps like this:
21107 \end_layout
21108
21109 \begin_layout LyX-Code
21110 <<My scrap>>=
21111 \end_layout
21112
21113 \begin_layout LyX-Code
21114   code
21115 \end_layout
21116
21117 \begin_layout LyX-Code
21118   more code
21119 \end_layout
21120
21121 \begin_layout LyX-Code
21122   even more code
21123 \end_layout
21124
21125 \begin_layout LyX-Code
21126   @
21127 \end_layout
21128
21129 \begin_layout Standard
21130 The problem is that whatever is written in between the << and the 
21131 \family typewriter
21132 @
21133 \family default
21134  must be taken literally, i.e., LyX should be prevented from making any special
21135  interpretation of what has been written.
21136  This is handled by a special layout named Scrap, that works like a normal
21137  paragraph but has a free spacing capability.
21138 \end_layout
21139
21140 \begin_layout Standard
21141 The down side of the Scrap paragraph layout is that consecutive paragraphs
21142  of code will be spaced with one empty line in the source code and also
21143  in the printed documentation.
21144  The work around is to enter each line of code within a single Scrap, with
21145  a newline (ctrl-return).
21146  The example above will look like this:
21147 \begin_inset Foot
21148 status collapsed
21149
21150 \begin_layout Standard
21151 If you have a printed version of this document you will not see any difference
21152  between the previous example and this one.
21153 \end_layout
21154
21155 \end_inset
21156
21157
21158 \end_layout
21159
21160 \begin_layout LyX-Code
21161 <<My scrap>>=
21162 \newline
21163   code
21164 \newline
21165   more code
21166 \newline
21167   even more code
21168 \newline
21169   @
21170 \end_layout
21171
21172 \begin_layout Standard
21173 This layout works fine.
21174  The only real inconvenience is that you have to type ctrl-return instead
21175  of a plain return.
21176 \begin_inset Foot
21177 status collapsed
21178
21179 \begin_layout Standard
21180 It is in my list of 
21181 \begin_inset Quotes eld
21182 \end_inset
21183
21184 improvements
21185 \begin_inset Quotes erd
21186 \end_inset
21187
21188  to fix that.
21189 \end_layout
21190
21191 \end_inset
21192
21193
21194 \end_layout
21195
21196 \begin_layout Standard
21197 As a special note, you can also use the 
21198 \begin_inset Quotes eld
21199 \end_inset
21200
21201 %def
21202 \begin_inset Quotes erd
21203 \end_inset
21204
21205  construct of Noweb in your scraps to add items to Noweb's identifier cross-refe
21206 rence:
21207 \end_layout
21208
21209 \begin_layout LyX-Code
21210 <<My scrap>>=
21211 \newline
21212   def some_function(args):
21213 \newline
21214     "This is the doc string for this
21215  function."
21216 \newline
21217     print "My args: ", args
21218 \end_layout
21219
21220 \begin_layout LyX-Code
21221 @ %def some_function
21222 \end_layout
21223
21224 \begin_layout Standard
21225 For an example of this usage and the resulting cross-reference output, look
21226  at the Literate python program in 
21227 \emph on
21228 LIBDIR/examples/listerrors.lyx 
21229 \emph default
21230 which should make this all clear.
21231 \end_layout
21232
21233 \begin_layout Paragraph
21234 Generating the documentation
21235 \end_layout
21236
21237 \begin_layout Standard
21238 At this point you already have a new document file with a proper document
21239  class, and with some code and text on it.
21240  How do I print it? The answer is simple, you select 
21241 \family sans
21242 \bar under
21243 V
21244 \bar default
21245 iew\SpecialChar \menuseparator
21246
21247 \bar under
21248 D
21249 \bar default
21250 VI,
21251 \family default
21252  etc.
21253  Just like you would do for a plain document.
21254  No special procedure is required.
21255 \end_layout
21256
21257 \begin_layout Standard
21258 To help orientate you, I will now explain what happens inside LyX:
21259 \end_layout
21260
21261 \begin_layout Enumerate
21262 When the 
21263 \family sans
21264 \bar under
21265 U
21266 \bar default
21267 pdate\SpecialChar \menuseparator
21268
21269 \bar under
21270 D
21271 \bar default
21272 VI 
21273 \family default
21274 menu option is chosen, a latex file is generated.
21275  
21276 \end_layout
21277
21278 \begin_deeper
21279 \begin_layout Standard
21280 If the document is of any literate class the generated file will be named
21281  with an extension name defined by the 
21282 \begin_inset Quotes eld
21283 \end_inset
21284
21285 literate
21286 \begin_inset Quotes erd
21287 \end_inset
21288
21289  format (defined in the Preferences panel), otherwise the file will have
21290  the usual 
21291 \family typewriter
21292 .tex 
21293 \family default
21294 extension.
21295 \end_layout
21296
21297 \end_deeper
21298 \begin_layout Enumerate
21299 Note that the only difference so far is in the name of the file, no special
21300  processing is required by LyX.
21301  Given that you formatted the code using the Scrap layout that, by itself,
21302  takes care of the business.
21303 \end_layout
21304
21305 \begin_layout Enumerate
21306 If the document is of any literate class LyX will then use the internal
21307  LyX to Noweb converter, followed by the Noweb to LaTeX converter
21308 \begin_inset Foot
21309 status open
21310
21311 \begin_layout Standard
21312 The converters are defined in the 
21313 \family sans
21314 \bar under
21315 T
21316 \bar default
21317 ools\SpecialChar \menuseparator
21318
21319 \bar under
21320 P
21321 \bar default
21322 references
21323 \family default
21324  panel, under the 
21325 \begin_inset Quotes eld
21326 \end_inset
21327
21328 Conversion
21329 \begin_inset Quotes erd
21330 \end_inset
21331
21332  tab.
21333 \end_layout
21334
21335 \end_inset
21336
21337  to generate the LaTeX file.
21338 \end_layout
21339
21340 \begin_deeper
21341 \begin_layout Standard
21342 Otherwise it will just skip this step.
21343 \end_layout
21344
21345 \end_deeper
21346 \begin_layout Enumerate
21347 Finally, LaTeX is invoked and the regular post processing continues as in
21348  a plain document.
21349 \end_layout
21350
21351 \begin_layout Standard
21352 Independence from a particular 
21353 \begin_inset Quotes eld
21354 \end_inset
21355
21356 literate tool
21357 \begin_inset Quotes erd
21358 \end_inset
21359
21360  is easily achieved by changing the commands that are run by the various
21361  converters.
21362 \end_layout
21363
21364 \begin_layout Paragraph
21365 Generating the code
21366 \end_layout
21367
21368 \begin_layout Standard
21369 When the build menu option is chosen or the corresponding button in the
21370  toolbar is pressed, a latex file is generated just like step 1 above.
21371  Next, LyX invokes the
21372 \family typewriter
21373  Noweb->Program
21374 \family default
21375  converter.
21376  Typically, this converter (like any other converter), has two parts:
21377 \end_layout
21378
21379 \begin_layout Enumerate
21380 The converter program itself.
21381  This program performs the conversion from the one format to the other (in
21382  this case, from the Noweb format to the Program pseudo-format).
21383 \end_layout
21384
21385 \begin_layout Enumerate
21386 The error log parser.
21387  This is a program whose sole purpose is to rewrite error messages in a
21388  format that LyX understands.
21389  This makes it possible for LyX to place error boxes in the right places
21390  in the file buffer.
21391 \end_layout
21392
21393 \begin_layout Standard
21394 The first part, the 
21395 \begin_inset Quotes eld
21396 \end_inset
21397
21398 Converter
21399 \begin_inset Quotes erd
21400 \end_inset
21401
21402  setting, should be set to 
21403 \begin_inset Quotes eld
21404 \end_inset
21405
21406
21407 \family typewriter
21408 build-script $$i
21409 \family default
21410
21411 \begin_inset Quotes erd
21412 \end_inset
21413
21414 .
21415  This basically means that LyX will call 
21416 \begin_inset Quotes eld
21417 \end_inset
21418
21419 build-script
21420 \begin_inset Quotes erd
21421 \end_inset
21422
21423  (a program or script) with the name of the Noweb file (generally a file
21424  in the LyX temp directory).
21425  
21426 \end_layout
21427
21428 \begin_layout Standard
21429 This is an implementation of 
21430 \begin_inset Quotes eld
21431 \end_inset
21432
21433 build-script
21434 \begin_inset Quotes erd
21435 \end_inset
21436
21437  that you can place in a directory on your path:
21438 \end_layout
21439
21440 \begin_layout LyX-Code
21441 #!/bin/sh
21442 \end_layout
21443
21444 \begin_layout LyX-Code
21445 #
21446 \end_layout
21447
21448 \begin_layout LyX-Code
21449 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 sh
21450 \end_layout
21451
21452 \begin_layout Standard
21453 The next part of the converter setting is the 
21454 \begin_inset Quotes eld
21455 \end_inset
21456
21457 Flags
21458 \begin_inset Quotes erd
21459 \end_inset
21460
21461  which is to be set to 
21462 \begin_inset Quotes eld
21463 \end_inset
21464
21465
21466 \family typewriter
21467 originaldir,parselog=listerrors
21468 \family default
21469
21470 \begin_inset Quotes erd
21471 \end_inset
21472
21473 .
21474  This will run any errors that are generated by the 
21475 \begin_inset Quotes eld
21476 \end_inset
21477
21478 build-script
21479 \begin_inset Quotes erd
21480 \end_inset
21481
21482  process through the 
21483 \begin_inset Quotes eld
21484 \end_inset
21485
21486 listerrors
21487 \begin_inset Quotes erd
21488 \end_inset
21489
21490  program.
21491 \end_layout
21492
21493 \begin_layout Standard
21494 The converter code looks in 
21495 \emph on
21496 MYLYXDIR/scripts 
21497 \emph default
21498 first, then in
21499 \emph on
21500  LIBDIR/scripts 
21501 \emph default
21502 then on the path for the 
21503 \begin_inset Quotes eld
21504 \end_inset
21505
21506 listerrors
21507 \begin_inset Quotes erd
21508 \end_inset
21509
21510  program.
21511 \end_layout
21512
21513 \begin_layout Paragraph
21514 Build instructions in the document
21515 \end_layout
21516
21517 \begin_layout Standard
21518 The last piece of the integration between LyX and noweb is the 
21519 \begin_inset Quotes eld
21520 \end_inset
21521
21522 build-script
21523 \begin_inset Quotes erd
21524 \end_inset
21525
21526  scrap.
21527  Generally, the instructions for building your program should be embedded
21528  in a scrap of its own.
21529  The noweb-specific 
21530 \begin_inset Quotes eld
21531 \end_inset
21532
21533 build-script
21534 \begin_inset Quotes erd
21535 \end_inset
21536
21537  above uses the notangle command to look for this scrap (called 
21538 \begin_inset Quotes eld
21539 \end_inset
21540
21541 build-script
21542 \begin_inset Quotes erd
21543 \end_inset
21544
21545 ) and runs its contents through 
21546 \begin_inset Quotes eld
21547 \end_inset
21548
21549 sh
21550 \begin_inset Quotes erd
21551 \end_inset
21552
21553 .
21554 \end_layout
21555
21556 \begin_layout Standard
21557 Typically, such a scrap would look something like this:
21558 \end_layout
21559
21560 \begin_layout LyX-Code
21561 <<build-script>>=
21562 \newline
21563 #!/bin/sh
21564 \newline
21565
21566 \newline
21567 if [ -z "${NOWEB_SOURCE}" ]
21568 \newline
21569 then
21570 \newline
21571   NOWEB_SOURCE=myfile.nw
21572 \newline
21573
21574 fi
21575 \newline
21576 [...
21577  code to extract files ...]
21578 \newline
21579 [...
21580  code to compile files ...]
21581 \newline
21582 @
21583 \end_layout
21584
21585 \begin_layout Standard
21586 Look in 
21587 \emph on
21588 LIBDIR/examples/listerrors.lyx 
21589 \emph default
21590 or in 
21591 \emph on
21592 LIBDIR/examples/Literate.lyx
21593 \emph default
21594  which implement two versions of the 
21595 \begin_inset Quotes eld
21596 \end_inset
21597
21598 listerrors
21599 \begin_inset Quotes erd
21600 \end_inset
21601
21602  program for some illustrations of how all of these pieces go together or
21603  in 
21604 \emph on
21605 LIBDIR/examples/noweb2lyx.lyx.
21606  
21607 \emph default
21608 Interestingly, these three files show off the language-indepence of the
21609  LyX literate programming support since they are written in Python, C and
21610  Perl respectively.
21611 \end_layout
21612
21613 \begin_layout Subsubsection
21614 Configuring LyX
21615 \end_layout
21616
21617 \begin_layout Standard
21618 All the Literate Programming support is configured by the 
21619 \family sans
21620 \bar under
21621 T
21622 \bar default
21623 ools\SpecialChar \menuseparator
21624
21625 \bar under
21626 P
21627 \bar default
21628 references
21629 \family default
21630  panel in the 
21631 \begin_inset Quotes eld
21632 \end_inset
21633
21634 Conversion
21635 \begin_inset Quotes erd
21636 \end_inset
21637
21638  tab.
21639  The important parts are:
21640 \end_layout
21641
21642 \begin_layout Description
21643 the\InsetSpace ~
21644
21645 \begin_inset Quotes eld
21646 \end_inset
21647
21648 literate
21649 \begin_inset Quotes erd
21650 \end_inset
21651
21652 \InsetSpace ~
21653 format Set up via the Formats tab, this is where the Noweb-specific pieces
21654  are set up.
21655  The 
21656 \family sans
21657 GUI Name
21658 \family default
21659  is set to 
21660 \family typewriter
21661 NoWeb
21662 \family default
21663 , the file extension is set to 
21664 \family typewriter
21665 .nw
21666 \family default
21667 .
21668  This tells LyX to create a file with a 
21669 \family typewriter
21670 .nw
21671 \family default
21672  extension in the first step of the conversion process.
21673 \end_layout
21674
21675 \begin_layout Description
21676 the\InsetSpace ~
21677
21678 \family sans
21679 Program
21680 \family default
21681 \InsetSpace ~
21682 format This is an empty format whose sole purpose is to be the endpoint
21683  of a conversion (which then allows us to set up a converter for it).
21684 \end_layout
21685
21686 \begin_layout Description
21687
21688 \family sans
21689 NoWeb
21690 \family default
21691 ->
21692 \family sans
21693 LaTeX
21694 \family default
21695  This converter performs the 
21696 \begin_inset Quotes eld
21697 \end_inset
21698
21699 weaving
21700 \begin_inset Quotes erd
21701 \end_inset
21702
21703  of the literate document.
21704  For Noweb, it is set to 
21705 \begin_inset Quotes eld
21706 \end_inset
21707
21708
21709 \family typewriter
21710 noweave -delay -index $$i > $$o
21711 \family default
21712
21713 \begin_inset Quotes erd
21714 \end_inset
21715
21716
21717 \end_layout
21718
21719 \begin_layout Description
21720
21721 \family sans
21722 NoWeb
21723 \family default
21724 ->
21725 \family sans
21726 Program
21727 \family default
21728  This performs the 
21729 \begin_inset Quotes eld
21730 \end_inset
21731
21732 tangling step
21733 \begin_inset Quotes erd
21734 \end_inset
21735
21736 .
21737  As stated above, the Converter is set to 
21738 \begin_inset Quotes eld
21739 \end_inset
21740
21741
21742 \family typewriter
21743 build-script $$i
21744 \family default
21745
21746 \begin_inset Quotes erd
21747 \end_inset
21748
21749 , with Flags set to 
21750 \begin_inset Quotes eld
21751 \end_inset
21752
21753
21754 \family typewriter
21755 originaldir,parselog=listerrors
21756 \family default
21757
21758 \begin_inset Quotes erd
21759 \end_inset
21760
21761 .
21762 \end_layout
21763
21764 \begin_layout Subsubsection
21765 Debug extensions
21766 \end_layout
21767
21768 \begin_layout Standard
21769 There is also a new function implemented in the LyX server, the 
21770 \begin_inset Quotes eld
21771 \end_inset
21772
21773 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
21774  
21775 \end_layout
21776
21777 \begin_layout Standard
21778 When debugging code with ddd/gdb, it is possible to invoke a text editor
21779  at the current execution position with a single key stroke.
21780  The default ddd configuration for that is shift-ctrl-V.
21781  It happens that you can define the editor command line invocation in ddd
21782  by accessing the
21783 \family sans
21784  
21785 \bar under
21786 E
21787 \bar default
21788 dit\SpecialChar \menuseparator
21789
21790 \bar under
21791 P
21792 \bar default
21793 references\SpecialChar \menuseparator
21794
21795 \bar under
21796 H
21797 \bar default
21798 elpers 
21799 \family default
21800 dialog and changing the "Edit Sources" entry.
21801 \end_layout
21802
21803 \begin_layout Standard
21804 I take advantage of the new created LyX server function and this ddd feature,
21805  and set 
21806 \begin_inset Quotes eld
21807 \end_inset
21808
21809 Edit Sources
21810 \begin_inset Quotes erd
21811 \end_inset
21812
21813  to:
21814 \end_layout
21815
21816 \begin_layout LyX-Code
21817 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
21818 \end_layout
21819
21820 \begin_layout Standard
21821 With this, whenever you are using ddd and find a point in the program that
21822  you want to edit, you just press shift-ctrl-V (in the ddd window), and
21823  ddd you forward this information to LyX through the LyX server and then
21824  the LyX window will show the same file with the cursor at the same position
21825  ddd was pointing to.
21826  No more guessing or long scrolling to locate a point in the program back
21827  from debugging !
21828 \end_layout
21829
21830 \begin_layout Standard
21831 Note however that you must enable the LyX server to get this feature working
21832  (it is disabled by default).
21833  You can enable it in 
21834 \family sans
21835 Preferences
21836 \family default
21837  (tabs 
21838 \family sans
21839 Inputs
21840 \family default
21841
21842 \family sans
21843 Paths
21844 \family default
21845 ) by entering in the 
21846 \family sans
21847 LyXserver pipe
21848 \family default
21849  a path like 
21850 \begin_inset Quotes eld
21851 \end_inset
21852
21853
21854 \family typewriter
21855 /home/<your-home-directory>/.lyx/lyxpipe
21856 \family default
21857
21858 \begin_inset Quotes erd
21859 \end_inset
21860
21861
21862 \end_layout
21863
21864 \begin_layout Standard
21865 Read the LyX server documentation in the 
21866 \emph on
21867 Customization Manual
21868 \emph default
21869  for further information.
21870 \end_layout
21871
21872 \begin_layout Subsubsection
21873 Toolbar extensions
21874 \end_layout
21875
21876 \begin_layout Standard
21877 There are six new buttons that can be added to your LyX toolbar.
21878  Five of these buttons are short cuts to layout styles: 
21879 \family sans
21880 Standard
21881 \family default
21882
21883 \family sans
21884 Section
21885 \family default
21886
21887 \family sans
21888 LaTeX
21889 \family default
21890
21891 \family sans
21892 LyX-Code
21893 \family default
21894 , and 
21895 \family sans
21896 Scrap
21897 \family default
21898 .
21899  The last one is a short cut to the 
21900 \begin_inset Quotes eld
21901 \end_inset
21902
21903 Build Program
21904 \begin_inset Quotes erd
21905 \end_inset
21906
21907  File menu entry.
21908  
21909 \end_layout
21910
21911 \begin_layout Standard
21912 LyX has a range of buttons that are available for tool bar customization.
21913  In my toolbar I like to combine the six short cuts above with two more:
21914  One for 
21915 \family sans
21916 \bar under
21917 V
21918 \bar default
21919 iew
21920 \family default
21921 \SpecialChar \menuseparator
21922
21923 \family sans
21924 \bar under
21925 U
21926 \bar default
21927 pdate
21928 \family default
21929 \SpecialChar \menuseparator
21930
21931 \family sans
21932 \bar under
21933 D
21934 \bar default
21935 VI
21936 \family default
21937  and the other for 
21938 \family sans
21939 \bar under
21940 V
21941 \bar default
21942 iew\SpecialChar \menuseparator
21943
21944 \bar under
21945 D
21946 \bar default
21947 VI
21948 \family default
21949  File menu entries.
21950  Here is how it looks like:
21951 \end_layout
21952
21953 \begin_layout LyX-Code
21954 Toolbar
21955 \end_layout
21956
21957 \begin_layout LyX-Code
21958   Layouts
21959 \end_layout
21960
21961 \begin_layout LyX-Code
21962   Icon "layout Standard"
21963 \end_layout
21964
21965 \begin_layout LyX-Code
21966   Icon "layout Section"
21967 \end_layout
21968
21969 \begin_layout LyX-Code
21970   Icon "layout LaTeX"
21971 \end_layout
21972
21973 \begin_layout LyX-Code
21974   Icon "layout LyX-Code"
21975 \end_layout
21976
21977 \begin_layout LyX-Code
21978   Icon "layout Scrap"
21979 \end_layout
21980
21981 \begin_layout LyX-Code
21982   Separator
21983 \end_layout
21984
21985 \begin_layout LyX-Code
21986   Icon "buffer-view"
21987 \end_layout
21988
21989 \begin_layout LyX-Code
21990   Icon "buffer-typeset"
21991 \end_layout
21992
21993 \begin_layout LyX-Code
21994   Icon "build-program"
21995 \end_layout
21996
21997 \begin_layout LyX-Code
21998   Separator
21999 \end_layout
22000
22001 \begin_layout LyX-Code
22002 .
22003 \end_layout
22004
22005 \begin_layout LyX-Code
22006 .
22007 \end_layout
22008
22009 \begin_layout LyX-Code
22010 .
22011 \end_layout
22012
22013 \begin_layout LyX-Code
22014 End
22015 \end_layout
22016
22017 \begin_layout Subsubsection
22018 Colors customization
22019 \end_layout
22020
22021 \begin_layout Standard
22022 There are a number of colors in LyX that can be customized in 
22023 \family sans
22024 Preferences
22025 \family default
22026 .
22027  One of the things that bothers people is the LaTeX font color.
22028  The default color is red, since the scraps uses LaTeX font, and there is
22029  a lot of scraps in literate documents, you may get tired of seeing everything
22030  in red.
22031  You can change it by going to the tabs 
22032 \family sans
22033 Look&Feel
22034 \family default
22035
22036 \family sans
22037 Colors.
22038 \end_layout
22039
22040 \begin_layout Standard
22041 The next thing is the visible presence of the newline character in the screen.
22042  You can choose the color of this particular character and make it blend
22043  in the background.
22044  I recommend you choosing a color that is close to the background but not
22045  equal, that way you still can see it is there, but it is not bothering
22046  you anymore.
22047  
22048 \end_layout
22049
22050 \begin_layout Chapter
22051 Secrets of the LaTeX Masters
22052 \begin_inset LatexCommand \label{cha:secrets}
22053
22054 \end_inset
22055
22056
22057 \end_layout
22058
22059 \begin_layout Standard
22060 Though LyX is a powerful tool, it cannot hope to support everything that
22061  can be done with pure TeX/LaTeX.
22062  However, many familiar dirty TeX and LaTeX tricks can be done within LyX,
22063  as long as you are not afraid to use that 
22064 \begin_inset Quotes eld
22065 \end_inset
22066
22067 TeX
22068 \begin_inset Quotes erd
22069 \end_inset
22070
22071  button on the toolbar or add things to the LaTeX preamble.
22072  This section lists some tips, tricks, and otherwise cool ideas to give
22073  your document that extra little flair.
22074  
22075 \emph on
22076 Do try this at home
22077 \emph default
22078 , just start with something a little smaller and less important than your
22079  dissertation!
22080 \end_layout
22081
22082 \begin_layout Standard
22083 Most ideas in this section require less common files in your LaTeX installation.
22084  If you have a system like teTeX, most will already be available.
22085  A few, however, will need to be downloaded from one of the CTAN archives.
22086  Often, there are several ways to do something, or several LaTeX style files
22087  which do the same thing.
22088  We do not endorse one choice over another, we simply claim that we have
22089  done a particular task with a particular file.
22090  Put on your wizard hat, keep an eye out for dragons, and let us begin.
22091 \end_layout
22092
22093 \begin_layout Section
22094 Tricks for Footnotes and Margin Notes
22095 \end_layout
22096
22097 \begin_layout Standard
22098 suggested by 
22099 \noun on
22100 Robin Socha
22101 \end_layout
22102
22103 \begin_layout Subsection
22104 Footnotes 
22105 \end_layout
22106
22107 \begin_layout Standard
22108 LyX cannot yet take care of setting the footnote numbering back to 1 after
22109  each section in the 
22110 \begin_inset Quotes eld
22111 \end_inset
22112
22113
22114 \family sans
22115 article
22116 \family default
22117
22118 \begin_inset Quotes erd
22119 \end_inset
22120
22121
22122 \family roman
22123  document class or changing the counter style.
22124  You'll need to insert LaTeX commands like the following to achieve that:
22125 \end_layout
22126
22127 \begin_layout Standard
22128 \begin_inset ERT
22129 status inlined
22130
22131 \begin_layout Standard
22132
22133
22134 \backslash
22135 setcounter{footnote}{0}
22136 \end_layout
22137
22138 \end_inset
22139
22140  Using 
22141 \family typewriter
22142
22143 \backslash
22144 setcounter{footnote}{0}
22145 \family roman
22146  will set the counter back to 1
22147 \begin_inset Foot
22148 status collapsed
22149
22150 \begin_layout Standard
22151 The counter has been set back to 1.
22152 \end_layout
22153
22154 \end_inset
22155
22156 .
22157 \end_layout
22158
22159 \begin_layout Standard
22160 The following command will change the numbering to small letters.
22161  Take a look at the next footnote in your xdvi or ghostview 
22162 \begin_inset ERT
22163 status inlined
22164
22165 \begin_layout Standard
22166
22167
22168 \backslash
22169 renewcommand{
22170 \backslash
22171 thefootnote}{
22172 \backslash
22173 alph{footnote}}
22174 \end_layout
22175
22176 \end_inset
22177
22178 :
22179 \begin_inset Foot
22180 status collapsed
22181
22182 \begin_layout Standard
22183 This is an example for a footnote with alphabetic numbering.
22184 \newline
22185 Use
22186 \family typewriter
22187  
22188 \backslash
22189 renewcommand{
22190 \backslash
22191 thefootnote {
22192 \backslash
22193 alph{footnote}} 
22194 \family roman
22195 to get this.
22196 \end_layout
22197
22198 \end_inset
22199
22200
22201 \end_layout
22202
22203 \begin_layout Standard
22204 The next command sets the counter style back to default, i.e.
22205  
22206 \family typewriter
22207
22208 \backslash
22209 arabic
22210 \family default
22211
22212 \begin_inset Foot
22213 status collapsed
22214
22215 \begin_layout Standard
22216 Use
22217 \family typewriter
22218  
22219 \backslash
22220 renewcommand{
22221 \backslash
22222 thefootnote}{
22223 \backslash
22224 arabic{footnote}}
22225 \family roman
22226  to set the counter--style back to LyX's default, i.e.
22227  
22228 \backslash
22229 arabic.
22230 \family default
22231
22232 \begin_inset ERT
22233 status collapsed
22234
22235 \begin_layout Standard
22236
22237
22238 \backslash
22239 renewcommand {
22240 \backslash
22241 thefootnote} {
22242 \backslash
22243 arabic{footnote}}
22244 \end_layout
22245
22246 \end_inset
22247
22248
22249 \end_layout
22250
22251 \end_inset
22252
22253 .
22254 \end_layout
22255
22256 \begin_layout Standard
22257 You can use 
22258 \family typewriter
22259
22260 \backslash
22261 arabic
22262 \family default
22263
22264 \family typewriter
22265
22266 \backslash
22267 roman
22268 \family default
22269
22270 \family typewriter
22271
22272 \backslash
22273 Roman
22274 \family default
22275
22276 \family typewriter
22277
22278 \backslash
22279 alph
22280 \family default
22281  or 
22282 \family typewriter
22283
22284 \backslash
22285 Alph
22286 \family default
22287  and others as counter styles.
22288  Just replace the LaTeX command in the above example and rerun TeX to see
22289  what those styles can do.
22290  
22291 \end_layout
22292
22293 \begin_layout Subsection
22294 Margin Notes
22295 \end_layout
22296
22297 \begin_layout Standard
22298 Here are two examples of neat things you can do to margin notes using LaTeX
22299  commands.
22300 \end_layout
22301
22302 \begin_layout Standard
22303 The following command will make a vertical line appear alongside your text---gre
22304 at for 
22305 \begin_inset Quotes eld
22306 \end_inset
22307
22308 thumbing
22309 \begin_inset Quotes erd
22310 \end_inset
22311
22312
22313 \family typewriter
22314
22315 \backslash
22316 marginpar{
22317 \backslash
22318 rule[-10mm]{30mm}{5mm}}
22319 \family roman
22320 .
22321 \family default
22322
22323 \begin_inset ERT
22324 status inlined
22325
22326 \begin_layout Standard
22327
22328
22329 \backslash
22330 marginpar{
22331 \backslash
22332 rule[-10mm]{30mm}{5mm}}
22333 \end_layout
22334
22335 \end_inset
22336
22337
22338 \end_layout
22339
22340 \begin_layout Standard
22341 Check your dvi- or ghostview-output to see what the 
22342 \family typewriter
22343
22344 \backslash
22345 reversemarginpar 
22346 \family default
22347 command does to the following margin note.
22348 \end_layout
22349
22350 \begin_layout Standard
22351 \begin_inset ERT
22352 status inlined
22353
22354 \begin_layout Standard
22355
22356
22357 \backslash
22358 reversemarginpar
22359 \end_layout
22360
22361 \end_inset
22362
22363
22364 \begin_inset Marginal
22365 status collapsed
22366
22367 \begin_layout Standard
22368 This is a 
22369 \newline
22370 margin note.
22371 \end_layout
22372
22373 \end_inset
22374
22375
22376 \end_layout
22377
22378 \begin_layout Section
22379 Multiple Columns
22380 \end_layout
22381
22382 \begin_layout Standard
22383 by 
22384 \noun on
22385 Lars Gullik Bjønnes
22386 \end_layout
22387
22388 \begin_layout Subsection
22389 Purpose
22390 \end_layout
22391
22392 \begin_layout Standard
22393 The aim for this chapter
22394 \begin_inset Foot
22395 status collapsed
22396
22397 \begin_layout Standard
22398 Editor's note: Lars' original chapter was a masterful description of how
22399  to use the 
22400 \family typewriter
22401 multicol
22402 \family default
22403  package.
22404  However, it was too long to flow smoothly in this document.
22405  I have therefore chosen to excerpt the most important sections here (sorry,
22406  Lars); you can read the original chapter (and more of the story!) in the
22407  example file 
22408 \family typewriter
22409 examples/multicol.lyx
22410 \family default
22411 .
22412  --- mer
22413 \end_layout
22414
22415 \end_inset
22416
22417  is to show how the LaTeX package 
22418 \family typewriter
22419 multicol
22420 \family default
22421  can be used in a LyX document.
22422  As LyX doesn't support the 
22423 \family typewriter
22424 multicol
22425 \family default
22426  package natively yet, we have to use some small hacks.
22427  By reading this section it should be obvious how to do this.
22428 \end_layout
22429
22430 \begin_layout Subsection
22431 Limitations 
22432 \end_layout
22433
22434 \begin_layout Standard
22435 The 
22436 \family typewriter
22437 multicol
22438 \family default
22439  package allows switching between one and multicolumn format on the same
22440  page.
22441  Footnotes are handled correctly (for the most part), but will be placed
22442  at the bottom of the page and not under each column.
22443  LaTeX's float mechanism, however, is partly disabled in the current implementat
22444 ion.
22445  At the moment only page-wide floats can be used within the scope of the
22446  environment.
22447 \end_layout
22448
22449 \begin_layout Subsection
22450 Examples
22451 \end_layout
22452
22453 \begin_layout Subsubsection
22454 Two columns
22455 \end_layout
22456
22457 \begin_layout Standard
22458 If you want to have two columns in your text, you have use LaTeX mode to
22459  insert 
22460 \family typewriter
22461
22462 \backslash
22463 begin{multicols}{2}
22464 \family default
22465  at the point where you want the two column layout to start, and then 
22466 \family typewriter
22467
22468 \backslash
22469 end{multicols}
22470 \family default
22471  where you want it to end.
22472  Like this:
22473 \end_layout
22474
22475 \begin_layout Standard
22476 \begin_inset ERT
22477 status inlined
22478
22479 \begin_layout Standard
22480
22481
22482 \backslash
22483 begin{multicols}{2}
22484 \end_layout
22485
22486 \end_inset
22487
22488
22489 \end_layout
22490
22491 \begin_layout Standard
22492 \noindent
22493
22494 \series bold
22495 \size small
22496 The Adventure of the Empty House
22497 \series default
22498
22499 \newline
22500 by 
22501 \noun on
22502 Sir Arthur Conan Doyle
22503 \end_layout
22504
22505 \begin_layout Standard
22506
22507 \size small
22508 It was in the spring of the year 1894 that all London was interested, and
22509  the fashionable world dismayed, by the murder of the Honourable Ronald
22510  Adair under most unusual and inexplicable circumstances.
22511  The public has already learned those particulars of the crime which came
22512  out in the police investigation, but a good deal was suppressed upon that
22513  occasion, since the case for the prosecution was so overwhelmingly strong
22514  that it was not necessary to bring forward all the facts.
22515  Only now, at the end of nearly ten years, am I allowed to supply those
22516  missing links which make up the whole of that remarkable chain.
22517  The crime was of interest in itself, but that interest was as nothing to
22518  me compared to the inconceivable sequel, which afforded me the greatest
22519  shock and surprise of any event in my adventurous life.
22520  Even now, after this long interval, I find myself thrilling as I think
22521  of it, and feeling once more that sudden flood of joy, amazement, and increduli
22522 ty which utterly submerged my mind.
22523  Let me say to that public, which has shown some interest in those glimpses
22524  which I have occasionally given them of the thoughts and actions of a very
22525  remarkable man, that they are not to blame me if I have not shared my knowledge
22526  with them, for I should have considered it my first duty to do so, had
22527  I not been barred by a positive prohibition from his own lips, which was
22528  only withdrawn upon the third of last month.
22529 \end_layout
22530
22531 \begin_layout Standard
22532 \begin_inset ERT
22533 status inlined
22534
22535 \begin_layout Standard
22536
22537
22538 \backslash
22539 end{multicols}
22540 \end_layout
22541
22542 \end_inset
22543
22544
22545 \end_layout
22546
22547 \begin_layout Subsubsection
22548 Multiple columns
22549 \end_layout
22550
22551 \begin_layout Standard
22552 The same pattern is used when you want more than two columns:
22553 \end_layout
22554
22555 \begin_layout Standard
22556 \begin_inset ERT
22557 status inlined
22558
22559 \begin_layout Standard
22560
22561
22562 \backslash
22563 begin{multicols}{3}
22564 \end_layout
22565
22566 \end_inset
22567
22568
22569 \end_layout
22570
22571 \begin_layout Standard
22572
22573 \size footnotesize
22574 It can be imagined that my close intimacy with Sherlock Holmes had interested
22575  me deeply in crime, and that after his disappearance I never failed to
22576  read with care the various problems which came before the public.
22577  And I even attempted, more than once, for my own private satisfaction,
22578  to employ his methods in their solution, though with indifferent success.
22579  There was none, however, which appealed to me like this tragedy of Ronald
22580  Adair.
22581  As I read the evidence at the inquest, which led up to a verdict of willful
22582  murder against some person or persons unknown, I realized more clearly
22583  than I had ever done the loss which the community had sustained by the
22584  death of Sherlock Holmes.
22585  There were points about this strange business which would, I was sure,
22586  have specially appealed to him, and the efforts of the police would have
22587  been supplemented, or more probably anticipated, by the trained observation
22588  and the alert mind of the first criminal agent in Europe.
22589  All day, as I drove upon my round, I turned over the case in my mind and
22590  found no explanation which appeared to me to be adequate.
22591  At the risk of telling a twice-told tale, I will recapitulate the facts
22592  as they were known to the public at the conclusion of the inquest.
22593 \end_layout
22594
22595 \begin_layout Standard
22596 \begin_inset ERT
22597 status inlined
22598
22599 \begin_layout Standard
22600
22601
22602 \backslash
22603 end{multicols}
22604 \end_layout
22605
22606 \end_inset
22607
22608
22609 \end_layout
22610
22611 \begin_layout Standard
22612 You can have have more than 3 columns if you want to, but that might not
22613  be very pleasant for the eye.
22614 \end_layout
22615
22616 \begin_layout Subsubsection
22617 Columns inside columns
22618 \end_layout
22619
22620 \begin_layout Standard
22621 You can even have columns inside columns:
22622 \end_layout
22623
22624 \begin_layout Standard
22625 \begin_inset ERT
22626 status inlined
22627
22628 \begin_layout Standard
22629
22630
22631 \backslash
22632 begin{multicols}{2}
22633 \end_layout
22634
22635 \end_inset
22636
22637
22638 \end_layout
22639
22640 \begin_layout Standard
22641
22642 \size footnotesize
22643 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
22644  at that time governor of one of the Australian colonies.
22645  Adair's mother had returned from Australia to undergo the operation for
22646  cataract, and she, her son Ronald, and her daughter Hilda were living together
22647  at 427 Park Lane.
22648 \end_layout
22649
22650 \begin_layout Standard
22651 \begin_inset ERT
22652 status inlined
22653
22654 \begin_layout Standard
22655
22656
22657 \backslash
22658 begin{multicols}{2}
22659 \end_layout
22660
22661 \end_inset
22662
22663
22664 \end_layout
22665
22666 \begin_layout Standard
22667
22668 \size footnotesize
22669 The youth moved in the best society--had, so far as was known, no enemies
22670  and no particular vices.
22671  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
22672  had been broken off by mutual consent some months before, and there was
22673  no sign that it had left any very profound feeling behind it.
22674  For the rest {sic} the man's life moved in a narrow and conventional circle,
22675  for his habits were quiet and his nature unemotional.
22676  Yet it was upon this easy-going young aristocrat that death came, in most
22677  strange and unexpected form, between the hours of ten and eleven-twenty
22678  on the night of March 30, 1894.
22679 \end_layout
22680
22681 \begin_layout Standard
22682 \begin_inset ERT
22683 status inlined
22684
22685 \begin_layout Standard
22686
22687
22688 \backslash
22689 end{multicols}
22690 \end_layout
22691
22692 \end_inset
22693
22694
22695 \end_layout
22696
22697 \begin_layout Standard
22698
22699 \size footnotesize
22700 Ronald Adair was fond of cards--playing continually, but never for such
22701  stakes as would hurt him.
22702  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
22703  It was shown that, after dinner on the day of his death, he had played
22704  a rubber of whist at the latter club.
22705  He had also played there in the afternoon.
22706
22707 \size default
22708  
22709 \size footnotesize
22710 The evidence of those who had played with him-- Mr.
22711  Murray, Sir John Hardy, and Colonel Moran--showed that the game was whist,
22712  and that there was a fairly equal fall of the cards.
22713  Adair might have lost five pounds, but not more.
22714  His fortune was a considerable one, and such a loss could not in any way
22715  affect him.
22716  He had played nearly every day at one club or other, but he was a cautious
22717  player, and usually rose a winner.
22718  It came out in evidence that, in partnership with Colonel Moran, he had
22719  actually won as much as four hundred and twenty pounds in a sitting, some
22720  weeks before, from Godfrey Milner and Lord Balmoral.
22721  So much for his recent history as it came out at the inquest.
22722 \end_layout
22723
22724 \begin_layout Standard
22725 \begin_inset ERT
22726 status inlined
22727
22728 \begin_layout Standard
22729
22730
22731 \backslash
22732 end{multicols}
22733 \end_layout
22734
22735 \end_inset
22736
22737
22738 \end_layout
22739
22740 \begin_layout Standard
22741 Please do read the file 
22742 \family typewriter
22743 examples/multicol.lyx
22744 \family default
22745  for more advanced examples including column and header spacing, vertical
22746  separator lines, and more.
22747 \end_layout
22748
22749 \begin_layout Section
22750 Numbering in the 
22751 \family sans
22752 Enumerate
22753 \family default
22754  Paragraph Environment
22755 \begin_inset OptArg
22756 status collapsed
22757
22758 \begin_layout Standard
22759 Numbering in Enumerate
22760 \end_layout
22761
22762 \end_inset
22763
22764
22765 \end_layout
22766
22767 \begin_layout Standard
22768 by 
22769 \noun on
22770 John Weiss
22771 \end_layout
22772
22773 \begin_layout Standard
22774 \begin_inset VSpace bigskip
22775 \end_inset
22776
22777
22778 \end_layout
22779
22780 \begin_layout Standard
22781 \noindent
22782 The default numbering for the 
22783 \family sans
22784 Enumerate
22785 \family default
22786  paragraph environment begins with Arabic numbers and ends with uppercase
22787  letters.
22788  Suppose, however, you wanted a different type of numbering scheme.
22789  Here's a quickie example of how to change the numbering scheme:
22790 \end_layout
22791
22792 \begin_layout LyX-Code
22793
22794 \backslash
22795 renewcommand{
22796 \backslash
22797 labelenumi}{
22798 \backslash
22799 Roman{enumi}.}
22800 \end_layout
22801
22802 \begin_layout LyX-Code
22803
22804 \backslash
22805 renewcommand{
22806 \backslash
22807 labelenumii}{
22808 \backslash
22809 Alph{enumii}.}
22810 \end_layout
22811
22812 \begin_layout LyX-Code
22813
22814 \backslash
22815 renewcommand{
22816 \backslash
22817 labelenumiii}{
22818 \backslash
22819 arabic{enumiii}.}
22820 \end_layout
22821
22822 \begin_layout LyX-Code
22823
22824 \backslash
22825 renewcommand{
22826 \backslash
22827 labelenumiv}{
22828 \backslash
22829 alph{enumiv}.)}
22830 \end_layout
22831
22832 \begin_layout Standard
22833 \SpecialChar \ldots{}
22834  which changes the numbering scheme to uppercase Roman numerals, uppercase
22835  letters, Arabic numbers, and lowercase letter.
22836 \end_layout
22837
22838 \begin_layout Standard
22839 Additionally, the previous example also adds a little bit extra to the numbering
22840  scheme.
22841  For example, the first level label actually looks like: 
22842 \begin_inset Quotes eld
22843 \end_inset
22844
22845 I.
22846 \begin_inset Quotes erd
22847 \end_inset
22848
22849 .
22850  For ease of reading, we'll describe what the numbering schemes look like
22851  using a notation something like this: <
22852 \begin_inset Quotes eld
22853 \end_inset
22854
22855 I.
22856 \begin_inset Quotes erd
22857 \end_inset
22858
22859 ,\InsetSpace ~
22860
22861 \begin_inset Quotes erd
22862 \end_inset
22863
22864 A.
22865 \begin_inset Quotes erd
22866 \end_inset
22867
22868 ,\InsetSpace ~
22869
22870 \begin_inset Quotes erd
22871 \end_inset
22872
22873 1.
22874 \begin_inset Quotes erd
22875 \end_inset
22876
22877 ,\InsetSpace ~
22878
22879 \begin_inset Quotes eld
22880 \end_inset
22881
22882 a.)
22883 \begin_inset Quotes erd
22884 \end_inset
22885
22886 >.
22887  
22888 \end_layout
22889
22890 \begin_layout Standard
22891 As you can see in the example, there is a label command for each nesting
22892  level, 
22893 \family typewriter
22894
22895 \backslash
22896 labelenumi
22897 \family default
22898  \SpecialChar \ldots{}
22899  
22900 \family typewriter
22901
22902 \backslash
22903 labelenumiv
22904 \family default
22905 , as well as a counter, 
22906 \family typewriter
22907 enumi
22908 \family default
22909  \SpecialChar \ldots{}
22910  
22911 \family typewriter
22912 enumiv
22913 \family default
22914 .
22915  There are also five 
22916 \begin_inset Quotes eld
22917 \end_inset
22918
22919 number printing
22920 \begin_inset Quotes erd
22921 \end_inset
22922
22923  commands, 
22924 \family typewriter
22925
22926 \backslash
22927 arabic{}
22928 \family default
22929
22930 \family typewriter
22931
22932 \backslash
22933 roman{}
22934 \family default
22935
22936 \family typewriter
22937
22938 \backslash
22939 Roman{}
22940 \family default
22941
22942 \family typewriter
22943
22944 \backslash
22945 alph{}
22946 \family default
22947 , and 
22948 \family typewriter
22949
22950 \backslash
22951 Alph{}
22952 \family default
22953 , each of which take one counter as an argument.
22954  You can add characters before or after these, but there's no need to add
22955  spaces.
22956 \end_layout
22957
22958 \begin_layout Standard
22959 You can get really fancy with these.
22960  For example:
22961 \end_layout
22962
22963 \begin_layout LyX-Code
22964
22965 \backslash
22966 renewcommand{
22967 \backslash
22968 labelenumi}{
22969 \backslash
22970 #
22971 \backslash
22972 Alph{enumi}
22973 \backslash
22974 #}
22975 \end_layout
22976
22977 \begin_layout LyX-Code
22978
22979 \backslash
22980 renewcommand{
22981 \backslash
22982 labelenumii}{
22983 \backslash
22984 Alph{enumi}.
22985 \backslash
22986 arabic{enumii}}
22987 \end_layout
22988
22989 \begin_layout LyX-Code
22990
22991 \backslash
22992 renewcommand{
22993 \backslash
22994 labelenumiii}{
22995 \backslash
22996 alph{enumiii}+}
22997 \end_layout
22998
22999 \begin_layout LyX-Code
23000
23001 \backslash
23002 renewcommand{
23003 \backslash
23004 labelenumiv}{(
23005 \backslash
23006 roman{enumiv})}
23007 \end_layout
23008
23009 \begin_layout Standard
23010 produces the somewhat out of hand numbering scheme: <
23011 \begin_inset Quotes eld
23012 \end_inset
23013
23014 #A#
23015 \begin_inset Quotes erd
23016 \end_inset
23017
23018 ,\InsetSpace ~
23019
23020 \begin_inset Quotes erd
23021 \end_inset
23022
23023 A.1
23024 \begin_inset Quotes erd
23025 \end_inset
23026
23027 ,\InsetSpace ~
23028
23029 \begin_inset Quotes erd
23030 \end_inset
23031
23032 a+
23033 \begin_inset Quotes erd
23034 \end_inset
23035
23036 ,\InsetSpace ~
23037
23038 \begin_inset Quotes eld
23039 \end_inset
23040
23041 (i)
23042 \begin_inset Quotes erd
23043 \end_inset
23044
23045 >.
23046  
23047 \end_layout
23048
23049 \begin_layout Section
23050 Extra Space Between Table Rows
23051 \end_layout
23052
23053 \begin_layout Standard
23054 by 
23055 \noun on
23056 Mike Ressler
23057 \end_layout
23058
23059 \begin_layout Standard
23060 \begin_inset VSpace bigskip
23061 \end_inset
23062
23063
23064 \end_layout
23065
23066 \begin_layout Standard
23067 \noindent
23068 LaTeX allows you to put a bit of extra space between rows in a table by
23069  giving an optional argument to the end-of-row specifier (
23070 \family typewriter
23071
23072 \backslash
23073
23074 \backslash
23075
23076 \family default
23077 ).
23078  LyX has not yet implemented this in a formal way, so here are two dirty
23079  little tricks to do the same job.
23080  
23081 \end_layout
23082
23083 \begin_layout Standard
23084 The first is the more formal, but longwinded way to do it.
23085  In the LaTeX preamble, add the following command definition: 
23086 \end_layout
23087
23088 \begin_layout Standard
23089
23090 \family typewriter
23091
23092 \backslash
23093 newcommand{
23094 \backslash
23095 extratablespace}[1]{
23096 \backslash
23097 noalign{vskip#1}}
23098 \family default
23099  This command takes a single argument---the amount of space you would like
23100  to insert.
23101  Insert the command in the first column of the row 
23102 \emph on
23103 after
23104 \emph default
23105  where you would like the space to appear.
23106  Here is an example (I've removed all the borders using 
23107 \family sans
23108 \bar under
23109 L
23110 \bar default
23111 ayout\SpecialChar \menuseparator
23112 Tabl
23113 \bar under
23114 e
23115 \family default
23116 \bar default
23117 ):
23118 \end_layout
23119
23120 \begin_layout Standard
23121 \align center
23122 \begin_inset Tabular
23123 <lyxtabular version="3" rows="4" columns="3">
23124 <features>
23125 <column alignment="center" valignment="top" width="0pt">
23126 <column alignment="center" valignment="top" width="0pt">
23127 <column alignment="center" valignment="top" width="0pt">
23128 <row>
23129 <cell alignment="center" valignment="top" topline="true" usebox="none">
23130 \begin_inset Text
23131
23132 \begin_layout Standard
23133
23134 \family roman
23135 \series medium
23136 \shape up
23137 \size normal
23138 \emph off
23139 \bar no
23140 \noun off
23141 \color none
23142 Minerals
23143 \end_layout
23144
23145 \end_inset
23146 </cell>
23147 <cell alignment="center" valignment="top" topline="true" usebox="none">
23148 \begin_inset Text
23149
23150 \begin_layout Standard
23151
23152 \family roman
23153 \series medium
23154 \shape up
23155 \size normal
23156 \emph off
23157 \bar no
23158 \noun off
23159 \color none
23160 Calcite
23161 \end_layout
23162
23163 \end_inset
23164 </cell>
23165 <cell alignment="center" valignment="top" topline="true" usebox="none">
23166 \begin_inset Text
23167
23168 \begin_layout Standard
23169
23170 \family roman
23171 \series medium
23172 \shape up
23173 \size normal
23174 \emph off
23175 \bar no
23176 \noun off
23177 \color none
23178 Dolomite
23179 \end_layout
23180
23181 \end_inset
23182 </cell>
23183 </row>
23184 <row>
23185 <cell alignment="center" valignment="top" topline="true" usebox="none">
23186 \begin_inset Text
23187
23188 \begin_layout Standard
23189
23190 \end_layout
23191
23192 \end_inset
23193 </cell>
23194 <cell alignment="center" valignment="top" topline="true" usebox="none">
23195 \begin_inset Text
23196
23197 \begin_layout Standard
23198
23199 \family roman
23200 \series medium
23201 \shape up
23202 \size normal
23203 \emph off
23204 \bar no
23205 \noun off
23206 \color none
23207 Quartz
23208 \end_layout
23209
23210 \end_inset
23211 </cell>
23212 <cell alignment="center" valignment="top" topline="true" usebox="none">
23213 \begin_inset Text
23214
23215 \begin_layout Standard
23216
23217 \family roman
23218 \series medium
23219 \shape up
23220 \size normal
23221 \emph off
23222 \bar no
23223 \noun off
23224 \color none
23225 Graphite
23226 \end_layout
23227
23228 \end_inset
23229 </cell>
23230 </row>
23231 <row>
23232 <cell alignment="center" valignment="top" topline="true" usebox="none">
23233 \begin_inset Text
23234
23235 \begin_layout Standard
23236
23237 \family roman
23238 \series medium
23239 \shape up
23240 \size normal
23241 \emph off
23242 \bar no
23243 \noun off
23244 \color none
23245 \begin_inset ERT
23246 status collapsed
23247
23248 \begin_layout Standard
23249
23250
23251 \backslash
23252 extratablespace{2ex}
23253 \end_layout
23254
23255 \end_inset
23256
23257 Rocks
23258 \end_layout
23259
23260 \end_inset
23261 </cell>
23262 <cell alignment="center" valignment="top" topline="true" usebox="none">
23263 \begin_inset Text
23264
23265 \begin_layout Standard
23266
23267 \family roman
23268 \series medium
23269 \shape up
23270 \size normal
23271 \emph off
23272 \bar no
23273 \noun off
23274 \color none
23275 Limestone
23276 \end_layout
23277
23278 \end_inset
23279 </cell>
23280 <cell alignment="center" valignment="top" topline="true" usebox="none">
23281 \begin_inset Text
23282
23283 \begin_layout Standard
23284
23285 \family roman
23286 \series medium
23287 \shape up
23288 \size normal
23289 \emph off
23290 \bar no
23291 \noun off
23292 \color none
23293 Sandstone
23294 \end_layout
23295
23296 \end_inset
23297 </cell>
23298 </row>
23299 <row>
23300 <cell alignment="center" valignment="top" topline="true" usebox="none">
23301 \begin_inset Text
23302
23303 \begin_layout Standard
23304
23305 \end_layout
23306
23307 \end_inset
23308 </cell>
23309 <cell alignment="center" valignment="top" topline="true" usebox="none">
23310 \begin_inset Text
23311
23312 \begin_layout Standard
23313
23314 \family roman
23315 \series medium
23316 \shape up
23317 \size normal
23318 \emph off
23319 \bar no
23320 \noun off
23321 \color none
23322 Granite
23323 \end_layout
23324
23325 \end_inset
23326 </cell>
23327 <cell alignment="center" valignment="top" topline="true" usebox="none">
23328 \begin_inset Text
23329
23330 \begin_layout Standard
23331
23332 \family roman
23333 \series medium
23334 \shape up
23335 \size normal
23336 \emph off
23337 \bar no
23338 \noun off
23339 \color none
23340 Andesite
23341 \end_layout
23342
23343 \end_inset
23344 </cell>
23345 </row>
23346 </lyxtabular>
23347
23348 \end_inset
23349
23350
23351 \end_layout
23352
23353 \begin_layout Standard
23354 The second method is faster, but will make typographers and TeXperts all
23355  over the world groan.
23356  Simply put an end of row specifier with optional argument at the same spot.
23357  No fancy definitions are needed as in the above example, but there will
23358  be more space inserted than you specified because you essentially added
23359  a blank row plus the extra space.
23360  If the space added is too much, simply use a negative number, like so:
23361 \end_layout
23362
23363 \begin_layout Standard
23364 \align center
23365 \begin_inset Tabular
23366 <lyxtabular version="3" rows="4" columns="3">
23367 <features>
23368 <column alignment="center" valignment="top" width="0pt">
23369 <column alignment="center" valignment="top" width="0pt">
23370 <column alignment="center" valignment="top" width="0pt">
23371 <row>
23372 <cell alignment="center" valignment="top" topline="true" usebox="none">
23373 \begin_inset Text
23374
23375 \begin_layout Standard
23376
23377 \family roman
23378 \series medium
23379 \shape up
23380 \size normal
23381 \emph off
23382 \bar no
23383 \noun off
23384 \color none
23385 Minerals
23386 \end_layout
23387
23388 \end_inset
23389 </cell>
23390 <cell alignment="center" valignment="top" topline="true" usebox="none">
23391 \begin_inset Text
23392
23393 \begin_layout Standard
23394
23395 \family roman
23396 \series medium
23397 \shape up
23398 \size normal
23399 \emph off
23400 \bar no
23401 \noun off
23402 \color none
23403 Calcite
23404 \end_layout
23405
23406 \end_inset
23407 </cell>
23408 <cell alignment="center" valignment="top" topline="true" usebox="none">
23409 \begin_inset Text
23410
23411 \begin_layout Standard
23412
23413 \family roman
23414 \series medium
23415 \shape up
23416 \size normal
23417 \emph off
23418 \bar no
23419 \noun off
23420 \color none
23421 Dolomite
23422 \end_layout
23423
23424 \end_inset
23425 </cell>
23426 </row>
23427 <row>
23428 <cell alignment="center" valignment="top" topline="true" usebox="none">
23429 \begin_inset Text
23430
23431 \begin_layout Standard
23432
23433 \end_layout
23434
23435 \end_inset
23436 </cell>
23437 <cell alignment="center" valignment="top" topline="true" usebox="none">
23438 \begin_inset Text
23439
23440 \begin_layout Standard
23441
23442 \family roman
23443 \series medium
23444 \shape up
23445 \size normal
23446 \emph off
23447 \bar no
23448 \noun off
23449 \color none
23450 Quartz
23451 \end_layout
23452
23453 \end_inset
23454 </cell>
23455 <cell alignment="center" valignment="top" topline="true" usebox="none">
23456 \begin_inset Text
23457
23458 \begin_layout Standard
23459
23460 \family roman
23461 \series medium
23462 \shape up
23463 \size normal
23464 \emph off
23465 \bar no
23466 \noun off
23467 \color none
23468 Graphite
23469 \end_layout
23470
23471 \end_inset
23472 </cell>
23473 </row>
23474 <row>
23475 <cell alignment="center" valignment="top" topline="true" usebox="none">
23476 \begin_inset Text
23477
23478 \begin_layout Standard
23479
23480 \family roman
23481 \series medium
23482 \shape up
23483 \size normal
23484 \emph off
23485 \bar no
23486 \noun off
23487 \color none
23488 \begin_inset ERT
23489 status collapsed
23490
23491 \begin_layout Standard
23492
23493
23494 \backslash
23495
23496 \backslash
23497 [-1ex]
23498 \end_layout
23499
23500 \end_inset
23501
23502  Rocks
23503 \end_layout
23504
23505 \end_inset
23506 </cell>
23507 <cell alignment="center" valignment="top" topline="true" usebox="none">
23508 \begin_inset Text
23509
23510 \begin_layout Standard
23511
23512 \family roman
23513 \series medium
23514 \shape up
23515 \size normal
23516 \emph off
23517 \bar no
23518 \noun off
23519 \color none
23520 Limestone
23521 \end_layout
23522
23523 \end_inset
23524 </cell>
23525 <cell alignment="center" valignment="top" topline="true" usebox="none">
23526 \begin_inset Text
23527
23528 \begin_layout Standard
23529
23530 \family roman
23531 \series medium
23532 \shape up
23533 \size normal
23534 \emph off
23535 \bar no
23536 \noun off
23537 \color none
23538 Sandstone
23539 \end_layout
23540
23541 \end_inset
23542 </cell>
23543 </row>
23544 <row>
23545 <cell alignment="center" valignment="top" topline="true" usebox="none">
23546 \begin_inset Text
23547
23548 \begin_layout Standard
23549
23550 \end_layout
23551
23552 \end_inset
23553 </cell>
23554 <cell alignment="center" valignment="top" topline="true" usebox="none">
23555 \begin_inset Text
23556
23557 \begin_layout Standard
23558
23559 \family roman
23560 \series medium
23561 \shape up
23562 \size normal
23563 \emph off
23564 \bar no
23565 \noun off
23566 \color none
23567 Granite
23568 \end_layout
23569
23570 \end_inset
23571 </cell>
23572 <cell alignment="center" valignment="top" topline="true" usebox="none">
23573 \begin_inset Text
23574
23575 \begin_layout Standard
23576
23577 \family roman
23578 \series medium
23579 \shape up
23580 \size normal
23581 \emph off
23582 \bar no
23583 \noun off
23584 \color none
23585 Andesite
23586 \end_layout
23587
23588 \end_inset
23589 </cell>
23590 </row>
23591 </lyxtabular>
23592
23593 \end_inset
23594
23595
23596 \end_layout
23597
23598 \begin_layout Standard
23599 It's short, sweet, and gets the job done quickly, even if it is really ugly.
23600  You may put away the rotten vegetables now! I promise I won't suggest anything
23601  else like that!
23602 \end_layout
23603
23604 \begin_layout Section
23605 Dropped Capitals
23606 \end_layout
23607
23608 \begin_layout Standard
23609 by 
23610 \noun on
23611 Mike Ressler
23612 \end_layout
23613
23614 \begin_layout Standard
23615 \begin_inset VSpace bigskip
23616 \end_inset
23617
23618
23619 \end_layout
23620
23621 \begin_layout Standard
23622 \noindent
23623 \begin_inset ERT
23624 status collapsed
23625
23626 \begin_layout Standard
23627
23628
23629 \backslash
23630 newfont{
23631 \backslash
23632 tmpfont}{cmr17 scaled 2500}{
23633 \backslash
23634 tmpfont T}
23635 \backslash
23636 vspace*{-8.4ex}
23637 \end_layout
23638
23639 \end_inset
23640
23641
23642 \end_layout
23643
23644 \begin_layout Standard
23645 \noindent
23646 \begin_inset ERT
23647 status inlined
23648
23649 \begin_layout Standard
23650
23651
23652 \backslash
23653 hangindent=3.3em 
23654 \backslash
23655 hangafter=-3
23656 \end_layout
23657
23658 \end_inset
23659
23660  hose of you who like the style of old books probably also like 
23661 \begin_inset Quotes eld
23662 \end_inset
23663
23664 dropped capitals
23665 \begin_inset Quotes erd
23666 \end_inset
23667
23668 ---those large capital letters which begin each new chapter or section.
23669  Implementing them with plain LyX/LaTeX is straightforward (assuming you
23670  know some plain TeX!) but does require a lot of work and many iterations,
23671  as you can see by all the ugly TeX-mode stuff at the beginning of this
23672  paragraph.
23673 \end_layout
23674
23675 \begin_layout Standard
23676 \begin_inset ERT
23677 status inlined
23678
23679 \begin_layout Standard
23680
23681
23682 \backslash
23683 verb+
23684 \backslash
23685 bigdrop{-1em}{3}{ptmri}{T}+
23686 \end_layout
23687
23688 \end_inset
23689
23690 here is a much easier way of doing this, of course.
23691  The 
23692 \family typewriter
23693 dropcaps
23694 \family default
23695  (or the newer 
23696 \family typewriter
23697 dropping
23698 \family default
23699 ) package from CTAN allows a simple way to add such letters to your documents.
23700  Since this package is not a standard part of teTeX, I can't demonstrate
23701  it within this document, but if you copy this paragraph to a new document,
23702  delete the 
23703 \begin_inset Quotes eld
23704 \end_inset
23705
23706
23707 \family typewriter
23708
23709 \backslash
23710 verb
23711 \family default
23712
23713 \begin_inset Quotes erd
23714 \end_inset
23715
23716  and the pluses from the TeX code at the beginning of the paragraph, and
23717  add 
23718 \family typewriter
23719
23720 \backslash
23721 usepackage{dropcaps}
23722 \family default
23723  to your LaTeX preamble, you will get a nice Times Roman Italic 
23724 \begin_inset Quotes eld
23725 \end_inset
23726
23727 T
23728 \begin_inset Quotes erd
23729 \end_inset
23730
23731 , whose height is three lines of text and which protrudes 1 em into the
23732  margin.
23733  (Make certain you have copied 
23734 \begin_inset Quotes eld
23735 \end_inset
23736
23737
23738 \family typewriter
23739 dropcaps.sty
23740 \family default
23741
23742 \begin_inset Quotes erd
23743 \end_inset
23744
23745  into a directory where TeX can see it.) The first argument is the amount
23746  of indentation; in this case the negative sign moves it into the margin.
23747  The second argument is the height of the letter in number of lines of text.
23748  The third argument is the font name: virtually anything which has a tfm
23749  file should work (wade through the 
23750 \family typewriter
23751 .../texmf/fonts/tfm
23752 \family default
23753  directory for possibilities).
23754  My personal favorite is 
23755 \begin_inset Quotes eld
23756 \end_inset
23757
23758
23759 \family typewriter
23760 yinit
23761 \family default
23762
23763 \begin_inset Quotes erd
23764 \end_inset
23765
23766 , a fancy German font specifically designed for dropped capitals.
23767  The fourth argument is the letter (or letters) to be dropped.
23768  The 
23769 \family typewriter
23770 dropping
23771 \family default
23772  package also offers the 
23773 \family typewriter
23774
23775 \backslash
23776 bigdrop
23777 \family default
23778  command, as well as a slightly simplified 
23779 \family typewriter
23780
23781 \backslash
23782 dropping
23783 \family default
23784  command.
23785 \end_layout
23786
23787 \begin_layout Section
23788 Non-standard Paragraph Shapes
23789 \end_layout
23790
23791 \begin_layout Standard
23792 by 
23793 \noun on
23794 Mike Ressler
23795 \end_layout
23796
23797 \begin_layout Standard
23798 \begin_inset VSpace bigskip
23799 \end_inset
23800
23801
23802 \end_layout
23803
23804 \begin_layout Standard
23805 \begin_inset ERT
23806 status inlined
23807
23808 \begin_layout Standard
23809
23810
23811 \backslash
23812 begin{sloppypar}
23813 \end_layout
23814
23815 \end_inset
23816
23817
23818 \end_layout
23819
23820 \begin_layout Standard
23821 \begin_inset ERT
23822 status collapsed
23823
23824 \begin_layout Standard
23825
23826
23827 \backslash
23828 newdimen
23829 \backslash
23830 varunit 
23831 \end_layout
23832
23833 \begin_layout Standard
23834
23835
23836 \backslash
23837 setlength{
23838 \backslash
23839 varunit}{4.5in}
23840 \end_layout
23841
23842 \end_inset
23843
23844
23845 \end_layout
23846
23847 \begin_layout Standard
23848 \noindent
23849 \begin_inset ERT
23850 status collapsed
23851
23852 \begin_layout Standard
23853
23854
23855 \backslash
23856 parshape 19 0.45
23857 \backslash
23858 varunit 0.332
23859 \backslash
23860 varunit
23861 \end_layout
23862
23863 \begin_layout Standard
23864
23865 0.40
23866 \backslash
23867 varunit 0.300
23868 \backslash
23869 varunit
23870 \end_layout
23871
23872 \begin_layout Standard
23873
23874 0.35
23875 \backslash
23876 varunit 0.293
23877 \backslash
23878 varunit
23879 \end_layout
23880
23881 \begin_layout Standard
23882
23883 0.30
23884 \backslash
23885 varunit 0.300
23886 \backslash
23887 varunit
23888 \end_layout
23889
23890 \begin_layout Standard
23891
23892 0.25
23893 \backslash
23894 varunit 0.317
23895 \backslash
23896 varunit
23897 \end_layout
23898
23899 \begin_layout Standard
23900
23901 0.20
23902 \backslash
23903 varunit 0.342
23904 \backslash
23905 varunit
23906 \end_layout
23907
23908 \begin_layout Standard
23909
23910 0.15
23911 \backslash
23912 varunit 0.373
23913 \backslash
23914 varunit
23915 \end_layout
23916
23917 \begin_layout Standard
23918
23919 0.10
23920 \backslash
23921 varunit 0.410
23922 \backslash
23923 varunit
23924 \end_layout
23925
23926 \begin_layout Standard
23927
23928 0.05
23929 \backslash
23930 varunit 0.453
23931 \backslash
23932 varunit
23933 \end_layout
23934
23935 \begin_layout Standard
23936
23937 0.00
23938 \backslash
23939 varunit 0.500
23940 \backslash
23941 varunit
23942 \end_layout
23943
23944 \begin_layout Standard
23945
23946 0.05
23947 \backslash
23948 varunit 0.453
23949 \backslash
23950 varunit
23951 \end_layout
23952
23953 \begin_layout Standard
23954
23955 0.10
23956 \backslash
23957 varunit 0.410
23958 \backslash
23959 varunit
23960 \end_layout
23961
23962 \begin_layout Standard
23963
23964 0.15
23965 \backslash
23966 varunit 0.373
23967 \backslash
23968 varunit
23969 \end_layout
23970
23971 \begin_layout Standard
23972
23973 0.20
23974 \backslash
23975 varunit 0.342
23976 \backslash
23977 varunit
23978 \end_layout
23979
23980 \begin_layout Standard
23981
23982 0.25
23983 \backslash
23984 varunit 0.317
23985 \backslash
23986 varunit
23987 \end_layout
23988
23989 \begin_layout Standard
23990
23991 0.30
23992 \backslash
23993 varunit 0.300
23994 \backslash
23995 varunit
23996 \end_layout
23997
23998 \begin_layout Standard
23999
24000 0.35
24001 \backslash
24002 varunit 0.293
24003 \backslash
24004 varunit
24005 \end_layout
24006
24007 \begin_layout Standard
24008
24009 0.40
24010 \backslash
24011 varunit 0.300
24012 \backslash
24013 varunit
24014 \end_layout
24015
24016 \begin_layout Standard
24017
24018 0.45
24019 \backslash
24020 varunit 0.332
24021 \backslash
24022 varunit
24023 \end_layout
24024
24025 \begin_layout Standard
24026
24027 \end_layout
24028
24029 \end_inset
24030
24031 There are times when the tyranny of rectangular paragraphs must be overthrown.
24032  In such situations, a call to the delightful plain TeX command 
24033 \family typewriter
24034
24035 \backslash
24036 parshape
24037 \family default
24038  is called for.
24039  As you can see, completely arbitrary shapes can be laid out with a suitable
24040  set of linelength definitions.
24041  While this parshape may look a bit silly and useless, one could conceive
24042  of situations such as finely tuned dropped capitals, word wrapping around
24043  non-rectangular graphics, etc.
24044  which will benefit from such handcrafting.
24045 \end_layout
24046
24047 \begin_layout Standard
24048 \begin_inset VSpace bigskip
24049 \end_inset
24050
24051
24052 \end_layout
24053
24054 \begin_layout Standard
24055 The syntax is 
24056 \family typewriter
24057
24058 \backslash
24059 parshape numlines #1indent #1length #2indent #2length \SpecialChar \ldots{}
24060  #nindent #nlength
24061 \family default
24062 , where 
24063 \family typewriter
24064 numlines
24065 \family default
24066  is the number of lines of text which define the paragraph.
24067  If there turn out to be fewer lines, the shape is truncated; if there are
24068  more, the excess lines have the same dimensions as the last line of the
24069  definition.
24070  The 
24071 \family typewriter
24072 #nindent
24073 \family default
24074  and 
24075 \family typewriter
24076 #nlength
24077 \family default
24078  entries specify the indentation of the line from the left margin, and the
24079  length of the line as measured from that point.
24080  The shape applies only to the current paragraph; everything is reset to
24081  normal for the next paragraph.
24082 \end_layout
24083
24084 \begin_layout Standard
24085 \begin_inset ERT
24086 status inlined
24087
24088 \begin_layout Standard
24089
24090
24091 \backslash
24092 end{sloppypar}
24093 \end_layout
24094
24095 \end_inset
24096
24097
24098 \end_layout
24099
24100 \begin_layout Section
24101 Summary
24102 \end_layout
24103
24104 \begin_layout Standard
24105 As you can see, the examples in this section range from the useful to the
24106  whimsical.
24107  While I don't expect that anyone will ever need the paragraph shape demonstrate
24108 d in the last section, the important point is that you can do almost anything
24109  you want in LyX if you are willing to figure out how to do it in TeX and
24110  LaTeX.
24111  TeX is a fantastically powerful typesetting system and all that power is
24112  available to you since LyX uses it as its backend.
24113  Happy LyXing!
24114 \end_layout
24115
24116 \end_body
24117 \end_document