]> git.lyx.org Git - lyx.git/blob - lib/doc/Extended.lyx
fixing wrong case of \lang -> \language
[lyx.git] / lib / doc / Extended.lyx
1 #LyX 1.4.0cvs created this file. For more info see http://www.lyx.org/
2 \lyxformat 243
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 \quotes_times 2
28 \papercolumns 1
29 \papersides 2
30 \paperpagestyle headings
31 \tracking_changes false
32 \output_changes true
33 \end_header
34
35 \begin_body
36
37 \begin_layout Title
38
39 Extended LyX Features
40 \end_layout
41
42 \begin_layout Author
43
44 by the LyX Team
45 \begin_inset Foot
46 status collapsed
47
48 \begin_layout Standard
49 \noindent
50 Principal maintainer of this file is
51 \noun on
52  Mike Ressler
53 \noun default
54 .
55  If you have comments or error corrections, please send them to the LyX
56  Documentation mailing list, <lyx-docs@lists.lyx.org>.
57 \end_layout
58
59 \end_inset
60
61  
62 \end_layout
63
64 \begin_layout Standard
65
66
67 \begin_inset LatexCommand \tableofcontents{}
68
69 \end_inset
70
71
72 \end_layout
73
74 \begin_layout Chapter
75
76 Introduction
77 \end_layout
78
79 \begin_layout Standard
80
81 The 
82 \emph on
83 Extended LyX Features
84 \emph default
85  manual, which you are now reading, is essentially Part II of the 
86 \emph on
87 User's Guide\SpecialChar \@.
88
89 \emph default
90  The reason for splitting this document is simple: the 
91 \emph on
92 User's Guide
93 \emph default
94  is already huge, and it contains all of the basic features one needs to
95  know in order to prepare most documents.
96  However, the LyX Team has a long-term goal of making LyX extensible through
97  various configuration files and external packages.
98  That means that if you want to support the Fizzwizzle LaTeX package, you
99  can create a layout file for it without having to alter LyX itself.
100  We've already had contributions of several new features this way.
101  This is the place where all of that gets documented.
102 \end_layout
103
104 \begin_layout Standard
105
106 This manual also documents some special features, like fax support, version
107  control, and SGML support, which require additional software to work properly.
108  Lastly, there's a chapter of LaTeX tools and tips, things you can use to
109  spruce up your documents by directly using the powerful features of LaTeX.
110  After all, LyX 
111 \emph on
112 is
113 \emph default
114  only WYSIWYM, and will only ever interface to certain LaTeX features.
115 \end_layout
116
117 \begin_layout Standard
118
119 Of course, with all of this extra documentation, 
120 \emph on
121 Extended LyX Features
122 \emph default
123  may itself grow too big for its britches.
124  In that case, you can just call it the 
125 \begin_inset Quotes eld
126 \end_inset
127
128 Overextended Manual
129 \begin_inset Quotes erd
130 \end_inset
131
132  for fun!
133 \end_layout
134
135 \begin_layout Standard
136
137 If you haven't read the 
138 \emph on
139 Introduction 
140 \emph default
141 yet, you are definitely in the wrong manual.
142  The 
143 \emph on
144 Introduction
145 \emph default
146  is the first place to go, since it will direct you to the correct manual,
147  and it also describes the notation and format of all of the manuals.
148  You should also be thoroughly familiar with the 
149 \emph on
150 User's Guide
151 \emph default
152  and all of the basic features of LyX.
153  
154 \end_layout
155
156 \begin_layout Standard
157
158 In this document, many sections are independent articles contributed by
159  an individual and are noted as such.
160  This person is generally whoever wrote the layout file for the new document
161  class or LaTeX package, or implemented the feature.
162  If there is no mention of an author to a chapter [or chapter sections],
163  that means it was written by the LyX Documentation Team.
164 \end_layout
165
166 \begin_layout Standard
167
168 Since all the topics in this manual depend heavily on LyX's interaction
169  with LaTeX, this first chapter covers
170 \emph on
171  
172 \emph default
173 the inner workings of LyX and how to direct LyX to generate exactly the
174  LaTeX code you want.
175  It is obviously for more seasoned LyX users.
176 \end_layout
177
178 \begin_layout Chapter
179
180 LyX and LaTeX
181 \end_layout
182
183 \begin_layout Section
184
185 How LyX Uses LaTeX
186 \end_layout
187
188 \begin_layout Standard
189
190
191 \begin_inset LatexCommand \label{sec:lyxandlatex}
192
193 \end_inset
194
195 This chapter is for both TeX-nicians and the LaTeX-curious.
196  In it, we'll explain how LyX and LaTeX work together to produce printable
197  output.
198  This is the only place in any of the manuals where we assume you know something
199  about LaTeX.
200 \end_layout
201
202 \begin_layout Standard
203
204 At one time, we called LyX a 
205 \begin_inset Quotes eld
206 \end_inset
207
208 WYSIWYM frontend to LaTeX,
209 \begin_inset Quotes erd
210 \end_inset
211
212  but that's no longer true.
213  There are frontends to LaTeX out there.
214  They are basically editors with the ability to run LaTeX and mark any errors
215  in the file you're editing.
216  Although LyX 
217 \emph on
218 is
219 \emph default
220  an editor, and it 
221 \emph on
222 does
223 \emph default
224  run LaTeX, and it also marks errors in the file, it also does much, much
225  more.
226  Thanks to the WYSIWYM concept, you don't need LaTeX to use LyX effectively.
227  LyX has also added a few extensions to LaTeX.
228  Try the following sometime: select 
229 \family sans
230 Export\SpecialChar \menuseparator
231 LaTeX
232 \family default
233  from the 
234 \family sans
235 \bar under
236 F
237 \bar default
238 ile
239 \family default
240  menu, then look at the preamble of the resulting 
241 \family typewriter
242 .tex
243 \family default
244  file.
245  You'll notice a variety of new macros defined specifically by LyX.
246  These macros are defined automatically, according to the features you use
247  in the document.
248 \end_layout
249
250 \begin_layout Standard
251
252 There are several commands that automatically invoke LaTeX.
253  They are:
254 \end_layout
255
256 \begin_layout Itemize
257
258
259 \family sans
260 \bar under
261 V
262 \bar default
263 iew\SpecialChar \menuseparator
264 View\InsetSpace ~
265
266 \emph on
267 Format
268 \end_layout
269
270 \begin_layout Itemize
271
272
273 \family sans
274 \bar under
275 V
276 \bar default
277 iew\SpecialChar \menuseparator
278
279 \bar under
280 U
281 \bar default
282 pdate\SpecialChar \menuseparator
283
284 \emph on
285 Format
286 \end_layout
287
288 \begin_layout Itemize
289
290
291 \family sans
292 \bar under
293 F
294 \bar default
295 ile
296 \bar under
297 \SpecialChar \menuseparator
298 P
299 \bar default
300 rint
301 \end_layout
302
303 \begin_layout Itemize
304
305
306 \family sans
307 \bar under
308 F
309 \bar default
310 ile
311 \bar under
312 \SpecialChar \menuseparator
313 F
314 \bar default
315 ax
316 \end_layout
317
318 \begin_layout Standard
319
320 They will only invoke LaTeX if the file has changed since the last time
321  LaTeX was run.
322  
323 \end_layout
324
325 \begin_layout Standard
326
327 When you run LaTeX on the file you're editing, LyX performs these steps:
328 \end_layout
329
330 \begin_layout Enumerate
331
332 Convert the document to LaTeX and save to a file with the extension 
333 \family typewriter
334 .tex
335 \family default
336  in place of 
337 \family typewriter
338 .lyx
339 \family default
340 .
341 \end_layout
342
343 \begin_layout Enumerate
344
345 Run LaTeX on the 
346 \family typewriter
347 .tex
348 \family default
349  file (maybe several times).
350 \end_layout
351
352 \begin_layout Enumerate
353
354 If there are any errors, insert error boxes in the document to mark where
355  they are.
356  These boxes are transient and are not saved along with the document.
357 \end_layout
358
359 \begin_layout Standard
360
361 If you've run LaTeX using 
362 \family sans
363 View\InsetSpace ~
364 DVI
365 \family default
366 , LyX then executes 
367 \family typewriter
368 xdvi
369 \family default
370  on the Dvi file.
371  If you've used 
372 \family sans
373 View\InsetSpace ~
374 PostScript
375 \family default
376  or 
377 \family sans
378 \bar under
379 P
380 \bar default
381 rint
382 \family default
383 , LyX performs two more steps:
384 \end_layout
385
386 \begin_layout Itemize
387
388 Run 
389 \family typewriter
390 dvips
391 \family default
392  to convert the Dvi file to PostScript®:
393 \end_layout
394
395 \begin_deeper
396 \begin_layout Itemize
397
398 For 
399 \family sans
400 View\InsetSpace ~
401 PostScript
402 \family default
403 , the output file has the extension 
404 \family typewriter
405 .ps_tmp
406 \end_layout
407
408 \begin_layout Itemize
409
410 For 
411 \family sans
412 \bar under
413 P
414 \bar default
415 rint
416 \family default
417 \InsetSpace ~
418 , the output file has the extension 
419 \family typewriter
420 .ps
421 \family default
422 , as expected.
423 \end_layout
424 \end_deeper
425 \begin_layout Itemize
426
427 Execute 
428 \family typewriter
429 ghostview
430 \family default
431  or send the PostScript® file to the printer.
432 \end_layout
433
434 \begin_layout Section
435
436
437 \begin_inset Quotes eld
438 \end_inset
439
440 Help! LyX generated an unreadable 
441 \family typewriter
442 .tex
443 \family default
444  file!
445 \begin_inset Quotes erd
446 \end_inset
447
448
449 \end_layout
450
451 \begin_layout Standard
452
453 Die-hard LaTeX users will scream and howl this into the night, then declare
454  LyX useless, simply because they didn't RTFM.
455 \end_layout
456
457 \begin_layout Standard
458
459 We're going to set the record straight.
460  LyX produces two kinds of LaTeX files.
461  One is human readable.
462  The other is LyX readable.
463  Every time LyX executes LaTeX, it produces a LaTeX file that it can easily
464  scan for errors.
465  The resulting 
466 \family typewriter
467 .tex
468 \family default
469  file is not human readable.
470  Don't even try to read it.
471  If you want a 
472 \family typewriter
473 .tex
474 \family default
475  file that you can send to a colleague, select 
476 \family sans
477 \bar under
478 E
479 \bar default
480 xport\SpecialChar \menuseparator
481
482 \bar under
483 L
484 \bar default
485 aTeX
486 \family default
487  from the 
488 \family sans
489 \bar under
490 F
491 \bar default
492 ile
493 \family default
494  menu.
495 \end_layout
496
497 \begin_layout Section
498
499 Translating LaTeX files into LyX
500 \end_layout
501
502 \begin_layout Standard
503
504 You can import a LaTeX file into LyX by using the 
505 \family sans
506 \bar under
507 F
508 \bar default
509 ile\SpecialChar \menuseparator
510
511 \bar under
512 I
513 \bar default
514 mport\SpecialChar \menuseparator
515
516 \bar under
517 L
518 \bar default
519 aTeX
520 \family default
521  command in LyX.
522  This will call a Perl script named 
523 \family typewriter
524 reLyX
525 \family default
526 ---which will create a file 
527 \family typewriter
528 foo.lyx
529 \family default
530  from the file 
531 \family typewriter
532 foo.tex
533 \family default
534 ---and then open that file.
535  If the translation doesn't work, you can try calling 
536 \family typewriter
537 reLyX
538 \family default
539  from the command line, possibly using fancier options.
540 \end_layout
541
542 \begin_layout Standard
543
544
545 \family typewriter
546 reLyX
547 \family default
548  will translate most legal LaTeX, but not everything.
549  It will leave things it doesn't understand in TeX mode, so after translating
550  a file with 
551 \family typewriter
552 reLyX
553 \family default
554 , you can look for red text and hand-edit it to look right.
555 \end_layout
556
557 \begin_layout Standard
558
559
560 \family typewriter
561 reLyX
562 \family default
563  has its own section in the 
564 \emph on
565 Extended Features
566 \emph default
567  manual (as well as a Unix manpage equivalent), which you should read to
568  find out about what LaTeX isn't supported, bugs (and how to get around
569  them), and how to use the various options.
570 \end_layout
571
572 \begin_layout Standard
573
574 If you can't get 
575 \family typewriter
576 reLyX
577 \family default
578  to work, or you just want to put a piece of LaTeX code into a LyX file,
579  see Section
580 \begin_inset LatexCommand \ref{sec:latexcodes}
581
582 \end_inset
583
584 .
585 \end_layout
586
587 \begin_layout Section
588
589 Inserting LaTeX Code into LyX Documents 
590 \begin_inset LatexCommand \label{sec:Inserting-LaTeX-Code}
591
592 \end_inset
593
594
595 \end_layout
596
597 \begin_layout Standard
598
599
600 \begin_inset LatexCommand \label{sec:latexcodes}
601
602 \end_inset
603
604  This is a rather important point: You can always insert LaTeX code into
605  any LyX document.
606  LyX simply cannot, and will probably never be able to, display every possible
607  LaTeX construct.
608  If ever you need to insert LaTeX commands into your LyX document, you can
609  use the ERT box, which you can insert into your document with 
610 \family sans
611 \bar under
612 I
613 \bar default
614 nsert\SpecialChar \menuseparator
615
616 \bar under
617 T
618 \bar default
619 eX
620 \family default
621 .
622  The ERT box comes in three forms: collapsed, open, and inlined.
623  The first two are used just like any other collapsable (foldable) box (such
624  as footnotes), and are useful for significant amounts of LaTeX commands.
625  An 
626 \begin_inset Quotes eld
627 \end_inset
628
629 inlined
630 \begin_inset Quotes erd
631 \end_inset
632
633  ERT box displays its content as part of the button, and is useful for very
634  short sections of LaTeX commands.
635  
636 \begin_inset ERT
637 status inlined
638
639 \begin_layout Standard
640 % like this
641 \end_layout
642
643 \end_inset
644
645
646 \end_layout
647
648 \begin_layout Standard
649
650 You can switch between all three by right-clicking on the ERT.
651  Note that if you want more than one line of LaTeX commands, you cannot
652  use the inlined mode.
653 \end_layout
654
655 \begin_layout Standard
656
657 Here's an example of inserting LaTeX commands in a LyX document.
658  The code looks like this:
659 \end_layout
660
661 \begin_layout LyX-Code
662
663
664 \backslash
665 begin{tabular}{ll}
666 \newline
667
668 \backslash
669 begin{minipage}{5cm}
670 \newline
671 This is an example for a minipage environment.
672  You 
673 \newline
674 can put nearly everything in it, even (non-floating) 
675 \newline
676 figures and tables.
677  
678 \newline
679
680 \backslash
681 end{minipage}
682 \newline
683 &
684 \newline
685
686 \backslash
687 begin{minipage}{5cm}
688 \newline
689
690 \backslash
691 begin{verbatim}
692 \newline
693
694 \backslash
695 begin{minipage}{5cm}
696 \newline
697 This ...
698  
699 \newline
700
701 \backslash
702 end{minipage}
703 \newline
704
705 \backslash
706 end{verbatim}
707 \newline
708
709 \backslash
710 end{minipage}
711 \newline
712
713 \backslash
714 end{tabular}
715 \end_layout
716
717 \begin_layout LyX-Code
718
719 \end_layout
720
721 \begin_layout Standard
722
723 The ERT box containing this text is directly after this paragraph.
724  Those of you reading the manual online will only see a bunch of funky text
725  in red.
726  Those reading a printed version of the manuals will see the actual results:
727 \end_layout
728
729 \begin_layout Standard
730
731
732 \begin_inset ERT
733 status collapsed
734
735 \begin_layout Standard
736
737 \backslash
738 begin{tabular}{ll}
739 \end_layout
740
741 \begin_layout Standard
742
743 \backslash
744 begin{minipage}{5cm}
745 \end_layout
746
747 \begin_layout Standard
748 This is an example for a minipage environment. You can put nearly everything in it, even (non-floating) figures and tables. 
749 \end_layout
750
751 \begin_layout Standard
752
753 \backslash
754 end{minipage}
755 \end_layout
756
757 \begin_layout Standard
758 &
759 \end_layout
760
761 \begin_layout Standard
762
763 \backslash
764 begin{minipage}{5cm}
765 \end_layout
766
767 \begin_layout Standard
768
769 \backslash
770 begin{verbatim}
771 \end_layout
772
773 \begin_layout Standard
774
775 \backslash
776 begin{minipage}{5cm}
777 \end_layout
778
779 \begin_layout Standard
780 This ... 
781 \end_layout
782
783 \begin_layout Standard
784
785 \backslash
786 end{minipage}
787 \end_layout
788
789 \begin_layout Standard
790
791 \backslash
792 end{verbatim}
793 \end_layout
794
795 \begin_layout Standard
796
797 \backslash
798 end{minipage}
799 \end_layout
800
801 \begin_layout Standard
802
803 \backslash
804 end{tabular}
805 \end_layout
806
807 \end_inset
808
809
810 \end_layout
811
812 \begin_layout Standard
813
814 In addition to these two methods, you can also create a separate file containing
815  some complex LaTeX structure.
816  You can then use 
817 \family sans
818 \bar under
819 I
820 \bar default
821 nsert\SpecialChar \menuseparator
822 Chil
823 \bar under
824 d
825 \bar default
826 \InsetSpace ~
827 Document
828 \family default
829  to include your file (you should select the type 
830 \family sans
831 Input
832 \family default
833 ).
834  We recommend that you only do this if you have a 
835 \family typewriter
836 .tex
837 \family default
838  file which you 
839 \emph on
840 know
841 \emph default
842  works already.
843  Otherwise, you'll have a big job tracking down LaTeX errors\SpecialChar \ldots{}
844
845 \end_layout
846
847 \begin_layout Standard
848
849 There are a few last notes to emphasize:
850 \end_layout
851
852 \begin_layout Itemize
853
854 Inside of LyX, LaTeX code appears 
855 \emph on
856 in red
857 \end_layout
858
859 \begin_layout Itemize
860
861 LyX 
862 \emph on
863 does not
864 \emph default
865  check if your LaTeX code is correct.
866 \end_layout
867
868 \begin_layout Itemize
869
870 Beware reinventing the wheel.
871 \end_layout
872
873 \begin_layout Standard
874
875 That last note refers to two things.
876  First, LyX does have quite a few features tucked into it, and more are
877  coming.
878  Be sure to check the manuals to make sure that LyX doesn't have such-and-such
879  feature before you go off merrily coding LaTeX.
880  Second, there are numerous LaTeX packages out there to do all sorts of
881  things, from labels to envelopes to fancy multipage tables.
882  Check out a CTAN site for details (see Section 
883 \begin_inset Quotes eld
884 \end_inset
885
886 Requirements
887 \begin_inset Quotes erd
888 \end_inset
889
890  of the 
891 \emph on
892 User's Guide
893 \emph default
894 ).
895 \begin_inset Foot
896 status open
897
898 \begin_layout Standard
899
900 Note from 
901 \noun on
902 John Weiss
903 \noun default
904 : I seem to do this an awful lot.
905  Sat down and merrily began coding something to print out labels, only to
906  learn that there were already 2 different LaTeX packages to do this.
907  Worse yet --- I had them already!
908 \end_layout
909
910 \end_inset
911
912
913 \end_layout
914
915 \begin_layout Standard
916
917 If you do need to do some wild and fancy things within your document, be
918  sure to check out a good LaTeX book for assistance.
919  There are a number of them listed in the bibliography of the 
920 \emph on
921 User's Guide
922 \emph default
923 .
924 \end_layout
925
926 \begin_layout Standard
927
928 There are a number of LaTeX commands which have to be placed before the
929  beginning of the actual text.
930  They go into the preamble, and this is explained in the next section.
931 \end_layout
932
933 \begin_layout Section
934
935 LyX and the LaTeX Preamble
936 \end_layout
937
938 \begin_layout Subsection
939
940 About the LaTeX Preamble
941 \end_layout
942
943 \begin_layout Standard
944
945
946 \begin_inset LatexCommand \label{sec:preamble}
947
948 \end_inset
949
950 If you already know LaTeX, there is no need to explain here what the preamble
951  is good for.
952  If you don't, the following will give you some ideas --- we recommend again
953  that you consult a LaTeX book for further information.
954  In any case, you should read the points below, because they explain what
955  you can do and what you don't need to do in the LaTeX preamble of a LyX
956  document.
957 \end_layout
958
959 \begin_layout Standard
960
961 The LaTeX preamble comes at the very beginning of a document, 
962 \emph on
963 before 
964 \emph default
965 the text.
966  It serves to:
967 \end_layout
968
969 \begin_layout Itemize
970
971 declare the document class.
972  LyX already does this for you.
973 \end_layout
974
975 \begin_deeper
976 \begin_layout Standard
977
978 If you're a seasoned LaTeX-nician, and you have some custom document class
979  you want to use, check out the 
980 \emph on
981 Customization Manual
982 \emph default
983  for information on how to make LyX interface to it.
984  Be sure to submit your efforts to the LyX Team for inclusion in future
985  versions!
986 \end_layout
987 \end_deeper
988 \begin_layout Itemize
989
990 declare the usage of packages.
991  LaTeX packages provide special commands, which are only available within
992  a document when the package has been declared in the preamble.
993  For example, the
994 \family typewriter
995  
996 \family default
997 package 
998 \family typewriter
999 indentfirst
1000 \family default
1001  forces all paragraphs to be indented.
1002  There are other packages for labels, envelopes, margins, etc.
1003  
1004 \end_layout
1005
1006 \begin_layout Itemize
1007
1008 set counters, variables, lengths and widths.
1009  There are several LaTeX counters and variables which 
1010 \emph on
1011 must
1012 \emph default
1013  be set globally from within the preamble in order to have the desired effect.
1014  [There are other variables which you can set and reset inside the document,
1015  too.] Margins are a good example of something which must be set in the preamble.
1016  Another example is the label format for lists.
1017  You can actually set these just about anywhere, but it's best to do it
1018  just once, inside the preamble.
1019 \end_layout
1020
1021 \begin_layout Itemize
1022
1023 declare user defined commands [with 
1024 \family typewriter
1025
1026 \backslash
1027 newcommand 
1028 \family default
1029 or 
1030 \family typewriter
1031
1032 \backslash
1033 renewcommand
1034 \family default
1035 ], mostly abbreviations for LaTeX commands which appear very often inside
1036  a document.
1037  Although the preamble is a good place to declare such commands, they 
1038 \emph on
1039 can
1040 \emph default
1041  be declared anywhere else [but 
1042 \emph on
1043 before
1044 \emph default
1045  they are used for the first time, of course\SpecialChar \ldots{}
1046 ].
1047  This can be useful if there is a lot of raw LaTeX code in your document,
1048  which normally should not be the case.
1049 \end_layout
1050
1051 \begin_layout Standard
1052
1053 LyX adds its own set of definitions to the preamble of the 
1054 \family typewriter
1055 .tex
1056 \family default
1057  file it produces.
1058  This makes LaTeX files generated by LyX portable.
1059 \end_layout
1060
1061 \begin_layout Subsection
1062
1063 Changing the Preamble
1064 \end_layout
1065
1066 \begin_layout Standard
1067
1068 The commands which LyX adds to the preamble of a LaTeX file are fixed; you
1069  can't change them without patching LyX itself.
1070  You can, however, add your own stuff to the preamble.
1071  There are two ways to do this:
1072 \end_layout
1073
1074 \begin_layout Enumerate
1075
1076 Select 
1077 \family sans
1078 \bar under
1079 L
1080 \bar default
1081 aTeX\InsetSpace ~
1082
1083 \bar under
1084 P
1085 \bar default
1086 reamble
1087 \family default
1088  from the 
1089 \family sans
1090 \bar under
1091 D
1092 \bar default
1093 ocument
1094 \family default
1095  menu, or via the 
1096 \family sans
1097 \bar under
1098 D
1099 \bar default
1100 ocument
1101 \family default
1102 \SpecialChar \menuseparator
1103
1104 \family sans
1105 \bar under
1106 S
1107 \bar default
1108 ettings
1109 \family default
1110  dialog, depending on your frontend.
1111  Note that the LyX keybindings will not work in this dialog, alas.
1112 \end_layout
1113
1114 \begin_layout Enumerate
1115
1116 Use the preamble contents you've added as your default template (see 
1117 \begin_inset Quotes eld
1118 \end_inset
1119
1120 Basic LyX Setup
1121 \begin_inset Quotes erd
1122 \end_inset
1123
1124  in the 
1125 \emph on
1126 User's Guide
1127 \emph default
1128 ), so that it will be the default preamble for any file you create.
1129 \end_layout
1130
1131 \begin_layout Standard
1132
1133 LyX adds anything in the 
1134 \family sans
1135 \bar under
1136 P
1137 \bar default
1138 reamble
1139 \family default
1140  dialog to its own built-in preamble.
1141  Before adding your own declarations in the preamble, you should make sure
1142  that LyX doesn't already support what you want to do (remember what we
1143  said about reinventing the wheel?).
1144  Also, 
1145 \emph on
1146 make sure your preamble code is correct
1147 \emph default
1148 .
1149  LyX doesn't check it.
1150 \end_layout
1151
1152 \begin_layout Subsection
1153
1154 Examples
1155 \end_layout
1156
1157 \begin_layout Standard
1158
1159 Here are some examples of what you can add to a preamble, and what they
1160  do:
1161 \end_layout
1162
1163 \begin_layout Subsubsection
1164
1165 Example #1: Offsets
1166 \end_layout
1167
1168 \begin_layout Standard
1169
1170 There are two variables under LaTeX that control page position: 
1171 \family typewriter
1172
1173 \backslash
1174 hoffset
1175 \family default
1176  and 
1177 \family typewriter
1178
1179 \backslash
1180 voffset
1181 \family default
1182 .
1183  Their names should be self-explanatory.
1184  These variables are useful if you think for a moment about computer labels.
1185  Sometimes, the size of a print medium and the area of the medium that you
1186  can actually print on aren't the same.
1187  This is where 
1188 \family typewriter
1189
1190 \backslash
1191 hoffset
1192 \family default
1193  and 
1194 \family typewriter
1195
1196 \backslash
1197 voffset
1198 \family default
1199  come in.
1200 \end_layout
1201
1202 \begin_layout Standard
1203
1204 The default values for 
1205 \family typewriter
1206
1207 \backslash
1208 hoffset
1209 \family default
1210  and 
1211 \family typewriter
1212
1213 \backslash
1214 voffset
1215 \family default
1216  are both 0 pt.,\InsetSpace ~
1217 i.\InsetSpace ~
1218 e.\InsetSpace ~
1219 the page isn't shifted.
1220 \end_layout
1221
1222 \begin_layout Standard
1223
1224 Unfortunately, some DVI drivers always seem to shift the page.
1225  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1226  If you're using LyX on a system that you don't personally maintain, and
1227  your sysadmin is a doofus, 
1228 \family typewriter
1229
1230 \backslash
1231 hoffset
1232 \family default
1233  and 
1234 \family typewriter
1235
1236 \backslash
1237 voffset
1238 \family default
1239  can save the day.
1240  Suppose you're left and top margins are always 0.5 inches too big.
1241  You can add this to the preamble:
1242 \end_layout
1243
1244 \begin_layout LyX-Code
1245
1246
1247 \backslash
1248 setlength{
1249 \backslash
1250 hoffset}{-0.5 in}
1251 \end_layout
1252
1253 \begin_layout LyX-Code
1254
1255
1256 \backslash
1257 setlength{
1258 \backslash
1259 voffset}{-0.5 in}
1260 \end_layout
1261
1262 \begin_layout Standard
1263
1264 \SpecialChar \ldots{}
1265 and your margins should now be correct.
1266 \end_layout
1267
1268 \begin_layout Subsubsection
1269
1270 Example #2: Labels
1271 \end_layout
1272
1273 \begin_layout Standard
1274
1275 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1276  There's a rather nice package, available at your nearest CTAN archive,
1277  for printing sheets of labels, called 
1278 \family typewriter
1279 labels.sty
1280 \family default
1281 .
1282  Now, your system may not have this package installed by default.
1283  We leave that up to you to check.
1284  You'll also want to read the documentation for it; we're not going to do
1285  that for you.
1286  Since this is an example, however, we'll give you an example of how you
1287  use this package.
1288 \end_layout
1289
1290 \begin_layout Standard
1291
1292 First, make sure you're using the 
1293 \family sans
1294 article 
1295 \family default
1296 document class.
1297  Next, you need to put the following in your preamble:
1298 \end_layout
1299
1300 \begin_layout LyX-Code
1301
1302
1303 \backslash
1304 usepackage{labels}
1305 \end_layout
1306
1307 \begin_layout LyX-Code
1308
1309
1310 \backslash
1311 LabelCols=3
1312 \end_layout
1313
1314 \begin_layout LyX-Code
1315
1316
1317 \backslash
1318 LabelRows=7
1319 \end_layout
1320
1321 \begin_layout LyX-Code
1322
1323
1324 \backslash
1325 LeftBorder=8mm
1326 \end_layout
1327
1328 \begin_layout LyX-Code
1329
1330
1331 \backslash
1332 RightBorder=8mm
1333 \end_layout
1334
1335 \begin_layout LyX-Code
1336
1337
1338 \backslash
1339 TopBorder=9mm
1340 \end_layout
1341
1342 \begin_layout LyX-Code
1343
1344
1345 \backslash
1346 BottomBorder=2mm
1347 \end_layout
1348
1349 \begin_layout Standard
1350
1351 This sets things up for Avery® label sheets, stock #5360.
1352  You're now ready to print labels, but you'll need to insert LaTeX code,
1353  placing the commands 
1354 \family typewriter
1355
1356 \backslash
1357 begin{labels}
1358 \family default
1359  and 
1360 \family typewriter
1361
1362 \backslash
1363 end{labels}
1364 \family default
1365  around each label text.
1366  This and other special features of 
1367 \family typewriter
1368 labels.sty
1369 \family default
1370  are explained in its documentation.
1371 \end_layout
1372
1373 \begin_layout Standard
1374
1375 Someday, someone may write a LyX layout file to support this package directly.
1376  Maybe that someone is you.
1377 \end_layout
1378
1379 \begin_layout Subsubsection
1380
1381 Example #3: Paragraph Indentation
1382 \end_layout
1383
1384 \begin_layout Standard
1385
1386 Americans are trained to indent the first line of 
1387 \emph on
1388 every
1389 \emph default
1390  paragraph.
1391  As with all of their other weird quirks, most Americans will whine and
1392  moan until they can have their way and indent the first line of all paragraphs.
1393 \begin_inset Foot
1394 status collapsed
1395
1396 \begin_layout Standard
1397
1398 Note from 
1399 \noun on
1400 John Weiss
1401 \noun default
1402 : This was written by an American --- 
1403 \emph on
1404 me
1405 \emph default
1406 ! It's my perception of my fellow countrymen.
1407  Tough if you don't like it.
1408  Thpbpbpbpbpbpbpbp!
1409 \end_layout
1410
1411 \end_inset
1412
1413
1414 \end_layout
1415
1416 \begin_layout Standard
1417
1418 Of course, this behavior isn't standard typography.
1419  In books, you typically only indent the first line of a paragraph 
1420 \emph on
1421 if
1422 \emph default
1423  it follows another one.
1424  The idea behind indenting the first line of a paragraph is to distinguish
1425  neighboring paragraphs from one another.
1426  If there is no previous paragraph, for example, it follows a figure, or
1427  is the first paragraph in a section, then there is no special indentation.
1428  
1429 \end_layout
1430
1431 \begin_layout Standard
1432
1433 If you're a typical American, though, you don't care about such esoteric
1434  things; you want your indentation! Add this to the preamble:
1435 \end_layout
1436
1437 \begin_layout LyX-Code
1438
1439
1440 \backslash
1441 usepackage{indentfirst}
1442 \end_layout
1443
1444 \begin_layout Standard
1445
1446 If your TeX distribution isn't a braindead one, you'll have this package,
1447  and all of your paragraphs will get the indentation you think they deserve.
1448 \end_layout
1449
1450 \begin_layout Subsubsection
1451
1452 Example #4: This Document
1453 \end_layout
1454
1455 \begin_layout Standard
1456
1457 You can also check out the preamble of this document to get an idea of some
1458  of the advanced things you can do.
1459  You'll probably need to make the 
1460 \family sans
1461 \bar under
1462 P
1463 \bar default
1464 reamble\SpecialChar \ldots{}
1465
1466 \family default
1467  dialog full-screen to see most of it.
1468  Also, there are more examples and an assortment of LaTeX 
1469 \begin_inset Quotes eld
1470 \end_inset
1471
1472 dirty tricks
1473 \begin_inset Quotes erd
1474 \end_inset
1475
1476  given in Chapter\InsetSpace ~
1477
1478 \begin_inset LatexCommand \ref{cha:secrets}
1479
1480 \end_inset
1481
1482 .
1483  
1484 \end_layout
1485
1486 \begin_layout Section
1487
1488 LyX and LaTeX Errors
1489 \end_layout
1490
1491 \begin_layout Standard
1492
1493 When LyX calls LaTeX, it tells LaTeX to blithely ignore any errors and keep
1494  going.
1495  It then uses the log-file from the LaTeX run to do a post-mortem.
1496  As we stated earlier in the chapter, LyX generates two kinds of 
1497 \family typewriter
1498 .tex
1499 \family default
1500  files, one of which it uses to locate errors in the document.
1501  If there was an error someplace, LyX will put a box with the word 
1502 \begin_inset Quotes eld
1503 \end_inset
1504
1505 Error
1506 \begin_inset Quotes erd
1507 \end_inset
1508
1509  at the appropriate place in the document.
1510 \begin_inset Foot
1511 status collapsed
1512
1513 \begin_layout Standard
1514
1515 LyX will occasionally misguess where the error was.
1516  This will typically happen with tables, figures, math, and the preamble.
1517 \end_layout
1518
1519 \end_inset
1520
1521  It will also display a message alerting you to the fact that there were
1522  errors.
1523 \end_layout
1524
1525 \begin_layout Standard
1526
1527 You can navigate through the errors by using 
1528 \family sans
1529 \bar under
1530 E
1531 \bar default
1532 rror
1533 \family default
1534  in the 
1535 \family sans
1536 \bar under
1537 N
1538 \bar default
1539 avigate
1540 \family default
1541  menu.
1542  You can 
1543 \begin_inset Quotes eld
1544 \end_inset
1545
1546 open
1547 \begin_inset Quotes erd
1548 \end_inset
1549
1550  the error-boxes and view the error message LaTeX produced by clicking on
1551  it.
1552 \end_layout
1553
1554 \begin_layout Standard
1555
1556 Some folks also like to look at the log file directly, accessible from
1557 \family sans
1558  
1559 \bar under
1560 D
1561 \bar default
1562 ocument\SpecialChar \menuseparator
1563
1564 \bar under
1565 L
1566 \bar default
1567 aTeX\InsetSpace ~
1568 Log\InsetSpace ~
1569 File
1570 \family default
1571 .
1572  There are some fairly common error messages and warnings.
1573  We'll cover those here.
1574  You should look at a good LaTeX book for a complete listing.
1575 \end_layout
1576
1577 \begin_layout Itemize
1578
1579
1580 \begin_inset Quotes eld
1581 \end_inset
1582
1583
1584 \family typewriter
1585 LaTeX Warning:
1586 \family default
1587
1588 \begin_inset Quotes eld
1589 \end_inset
1590
1591
1592 \end_layout
1593
1594 \begin_deeper
1595 \begin_layout Standard
1596
1597 Anything beginning with these word is a warning message for the purpose
1598  of 
1599 \begin_inset Quotes eld
1600 \end_inset
1601
1602 debugging
1603 \begin_inset Quotes erd
1604 \end_inset
1605
1606  the LaTeX code itself.
1607  You'll get messages like this if you added or changed cross-references
1608  or bibliography entries, in which case, LaTeX is trying to tell you that
1609  you need to make another run.
1610 \end_layout
1611
1612 \begin_layout Standard
1613
1614 You can by-and-large ignore these.
1615 \end_layout
1616 \end_deeper
1617 \begin_layout Itemize
1618
1619
1620 \begin_inset Quotes eld
1621 \end_inset
1622
1623
1624 \family typewriter
1625 LaTeX Font Warning:
1626 \family default
1627
1628 \begin_inset Quotes erd
1629 \end_inset
1630
1631
1632 \end_layout
1633
1634 \begin_deeper
1635 \begin_layout Standard
1636
1637 Another warning message, this time about fonts which LaTeX couldn't find.
1638  The rest of the message will often say something about a replacement font
1639  that LaTeX used.
1640 \end_layout
1641
1642 \begin_layout Standard
1643
1644 You can safely ignore these.
1645 \end_layout
1646 \end_deeper
1647 \begin_layout Itemize
1648
1649
1650 \begin_inset Quotes eld
1651 \end_inset
1652
1653
1654 \family typewriter
1655 Overfull 
1656 \backslash
1657 hbox
1658 \family default
1659
1660 \begin_inset Quotes erd
1661 \end_inset
1662
1663
1664 \end_layout
1665
1666 \begin_deeper
1667 \begin_layout Standard
1668
1669 LaTeX absolutely 
1670 \emph on
1671 loves
1672 \emph default
1673  to spew these out.
1674  They are warning you about lines that were too long and run past the right
1675  margin.
1676  Almost always, this is unnoticeable in the final output.
1677  Or, only one or two characters extend past the margin.
1678  LaTeX seems to generate at least one of these messages for just about any
1679  document you write.
1680 \end_layout
1681
1682 \begin_layout Standard
1683
1684 You can ignore these stupid messages.
1685  Your eyes will tell you if there's a problem with something that's too
1686  wide; just look at the output.
1687 \end_layout
1688 \end_deeper
1689 \begin_layout Itemize
1690
1691
1692 \begin_inset Quotes eld
1693 \end_inset
1694
1695
1696 \family typewriter
1697 Underfull 
1698 \backslash
1699 hbox
1700 \family default
1701
1702 \begin_inset Quotes erd
1703 \end_inset
1704
1705
1706 \end_layout
1707
1708 \begin_deeper
1709 \begin_layout Standard
1710
1711 Not quite as common as its cousin.
1712  LaTeX seems to like to print lines that are a bit too wide as opposed to
1713  ones that are a bit too narrow.
1714  We have no idea why.
1715 \end_layout
1716
1717 \begin_layout Standard
1718
1719 You can ignore these, too.
1720 \end_layout
1721 \end_deeper
1722 \begin_layout Itemize
1723
1724
1725 \begin_inset Quotes eld
1726 \end_inset
1727
1728
1729 \family typewriter
1730 Overfull 
1731 \backslash
1732 vbox
1733 \family default
1734
1735 \begin_inset Quotes erd
1736 \end_inset
1737
1738  and 
1739 \begin_inset Quotes eld
1740 \end_inset
1741
1742
1743 \family typewriter
1744 Underfull 
1745 \backslash
1746 vbox
1747 \family default
1748
1749 \begin_inset Quotes erd
1750 \end_inset
1751
1752
1753 \end_layout
1754
1755 \begin_deeper
1756 \begin_layout Standard
1757
1758 Warnings about troubles breaking the page.
1759  Once again, just look at the output.
1760  Your eyes will tell you where something has gone wrong.
1761 \end_layout
1762 \end_deeper
1763 \begin_layout Itemize
1764
1765
1766 \begin_inset Quotes eld
1767 \end_inset
1768
1769  
1770 \family typewriter
1771 LaTeX Error: File 
1772 \begin_inset Quotes els
1773 \end_inset
1774
1775 Xxxx
1776 \begin_inset Quotes ers
1777 \end_inset
1778
1779  not found
1780 \family default
1781
1782 \begin_inset Quotes erd
1783 \end_inset
1784
1785  
1786 \end_layout
1787
1788 \begin_deeper
1789 \begin_layout Standard
1790
1791 The file 
1792 \begin_inset Quotes eld
1793 \end_inset
1794
1795 Xxxx
1796 \begin_inset Quotes erd
1797 \end_inset
1798
1799  isn't installed on this system.
1800  This usually appears because some package your document needs isn't installed.
1801  If you didn't touch the preamble or didn't use the 
1802 \family typewriter
1803
1804 \backslash
1805 usepackage{}
1806 \family default
1807  command, then one of the packages LyX tried to load is missing.
1808  Use 
1809 \family sans
1810 \bar under
1811 H
1812 \bar default
1813 elp\SpecialChar \menuseparator
1814 L
1815 \bar under
1816 a
1817 \bar default
1818 TeX Configuration
1819 \family default
1820 , to get a list of packages that LyX knows about.
1821  This file is updated whenever you reconfigure LyX (using 
1822 \family sans
1823 \bar under
1824 T
1825 \bar default
1826 ools
1827 \bar under
1828 \SpecialChar \menuseparator
1829 R
1830 \bar default
1831 econfigure
1832 \family default
1833 ) and tells you which packages have been detected and what they do.
1834 \end_layout
1835
1836 \begin_layout Standard
1837
1838 If you 
1839 \emph on
1840 did
1841 \emph default
1842  use the 
1843 \family typewriter
1844
1845 \backslash
1846 usepackage{}
1847 \family default
1848  command, and the package in question isn't installed, you'll need to install
1849  it yourself.
1850 \end_layout
1851 \end_deeper
1852 \begin_layout Itemize
1853
1854
1855 \begin_inset Quotes eld
1856 \end_inset
1857
1858
1859 \family typewriter
1860 LaTeX Error: Unknown option
1861 \family default
1862
1863 \begin_inset Quotes erd
1864 \end_inset
1865
1866
1867 \end_layout
1868
1869 \begin_deeper
1870 \begin_layout Standard
1871
1872 Error messages beginning with this are trying to tell you that you specified
1873  a bad or undefined option to a package.
1874  Check the package's documentation.
1875 \end_layout
1876 \end_deeper
1877 \begin_layout Itemize
1878
1879
1880 \begin_inset Quotes eld
1881 \end_inset
1882
1883
1884 \family typewriter
1885 Undefined control sequence
1886 \family default
1887
1888 \begin_inset Quotes erd
1889 \end_inset
1890
1891
1892 \end_layout
1893
1894 \begin_deeper
1895 \begin_layout Standard
1896
1897 If you've inserted LaTeX code into your document, but made a typo, you'll
1898  get one of these.
1899  You may have forgotten to load a package.
1900  In any case, this error message usually means that you used an undefined
1901  command.
1902 \end_layout
1903 \end_deeper
1904 \begin_layout Standard
1905
1906 There are other error and warning messages.
1907  Some are self-explanatory.
1908  These are usually LaTeX messages.
1909  Others are downright cryptic.
1910  These are actually TeX error messages, and we really have 
1911 \emph on
1912 no clue
1913 \emph default
1914  what they mean or how to decipher them.
1915 \end_layout
1916
1917 \begin_layout Standard
1918
1919 There's a general sequence you should follow if you get error messages:
1920 \end_layout
1921
1922 \begin_layout Enumerate
1923
1924 Look at the LaTeX code you inserted for typos.
1925 \end_layout
1926
1927 \begin_layout Enumerate
1928
1929 If there are no typos, check and see that you used the command(s) correctly.
1930 \end_layout
1931
1932 \begin_layout Enumerate
1933
1934 If you get a bunch of error boxes piled up at the very top of the document,
1935  it means that there are errors in the preamble.
1936  Start debugging your preamble.
1937 \end_layout
1938
1939 \begin_layout Enumerate
1940
1941 If you didn't add anything to the preamble and didn't add any LaTeX code
1942  to the document, the first suspect is your LaTeX distribution itself.
1943  Check for missing packages and install them.
1944 \end_layout
1945
1946 \begin_layout Enumerate
1947
1948 Okay, so there are no missing packages.
1949  Did you use any of the fine-tuning options in LyX? Specifically, did you
1950  
1951 \emph on
1952 misuse
1953 \emph default
1954  any of them, like trying to manually insert lots of 
1955 \family sans
1956 Protected\InsetSpace ~
1957 Blank
1958 \family default
1959 s, 
1960 \family sans
1961 Linebreak
1962 \family default
1963 s, or 
1964 \family sans
1965 Pagebreak
1966 \family default
1967 s? Did you try to kludge something together with these instead of using
1968  the appropriate paragraph environment?
1969 \end_layout
1970
1971 \begin_layout Enumerate
1972
1973 All right, you didn't use any of the fine-tuning options, you played by
1974  the rules.
1975  Did you try to pull a fancy maneuver? Did you do something funky inside
1976  a table or an equation, like inserting a graphic into a table cell?
1977 \end_layout
1978
1979 \begin_layout Enumerate
1980
1981 Do you have long sections of text where LaTeX cannot find a place to break
1982  a line? By default, LaTeX is rather strict about how much extra inter-word
1983  spacing it will add in order to break a line.
1984  Preferrably, you should rework the paragraph to avoid the problem.
1985  If this isn't an option, you can wrap your text in 
1986 \family typewriter
1987
1988 \backslash
1989 sloppypar
1990 \family default
1991  to make LaTeX's line breaking more, well, sloppy.
1992 \end_layout
1993
1994 \begin_layout Enumerate
1995
1996 Did you go overboard with the nesting? LyX (currently) doesn't check to
1997  make sure you're in the limits for nesting environments.
1998  If you nested a bunch of environments to the 
1999 \begin_inset Formula $17^{\mathrm{th}}$
2000 \end_inset
2001
2002  level, that's the problem.
2003 \end_layout
2004
2005 \begin_layout Enumerate
2006
2007 Okay, you didn't get any error messages, but your output looks whacked.
2008  If you have a table or figure that's too wide or long for the page, you
2009  need to:
2010 \end_layout
2011
2012 \begin_deeper
2013 \begin_layout Enumerate
2014
2015 rescale the figure so it fits.
2016 \end_layout
2017
2018 \begin_layout Enumerate
2019
2020 trim down the table so it fits.
2021 \end_layout
2022
2023 \begin_layout Standard
2024
2025 If something else is wrong with the output, and you didn't try to pull anything
2026  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2027 \end_layout
2028 \end_deeper
2029 \begin_layout Standard
2030
2031 If all this doesn't help --- well, then 
2032 \emph on
2033 perhaps
2034 \emph default
2035  you might have found a bug in LyX\SpecialChar \ldots{}
2036
2037 \end_layout
2038
2039 \begin_layout Chapter
2040
2041 Supplemental Tools
2042 \end_layout
2043
2044 \begin_layout Section
2045
2046 Preparing a Bibliography with BibTeX
2047 \end_layout
2048
2049 \begin_layout Standard
2050
2051 by 
2052 \noun on
2053 Mike Ressler
2054 \end_layout
2055
2056 \begin_layout Standard
2057
2058
2059 \begin_inset VSpace bigskip
2060 \end_inset
2061
2062
2063 \end_layout
2064
2065
2066 \begin_layout Standard
2067 \noindent
2068 STOP! If you don't know what BibTeX is, or have a reasonably good idea of
2069  how to use it (
2070 \emph on
2071 e.g.
2072
2073 \emph default
2074  setting up your own bibliographic databases), 
2075 \emph on
2076 run
2077 \emph default
2078 , do not walk, to your nearest copy of the 2nd edition of Lamport's 
2079 \emph on
2080 LaTeX: A Document Preparation System
2081 \emph default
2082 , particularly Appendix B.
2083  The rest of this discussion assumes you have created a correct bibliography
2084  file, that you have all relevant environment variables set correctly (esp.
2085  
2086 \family typewriter
2087 BIBINPUTS
2088 \family default
2089
2090 \family typewriter
2091 BSTINPUTS
2092 \family default
2093 , and 
2094 \family typewriter
2095 TEXINPUTS
2096 \family default
2097 ), and that if sufficiently desperate, you could create and 
2098 \begin_inset Quotes eld
2099 \end_inset
2100
2101 TeX
2102 \begin_inset Quotes erd
2103 \end_inset
2104
2105  a LaTeX file with a BibTeX database.
2106  
2107 \end_layout
2108
2109 \begin_layout Standard
2110
2111 For those who don't know what BibTeX is, it is a system for creating a large
2112  database of your most used journal references.
2113  For all future articles you write, you only need to include this standard
2114  database and reference the appropriate key to each reference.
2115  Even if you write only a few papers with handful of references each, it
2116  is well worth your time to examine BibTeX and decide whether it will be
2117  useful to you.
2118 \end_layout
2119
2120 \begin_layout Standard
2121
2122 To use BibTeX with LyX, first read the 
2123 \emph on
2124 User Guide
2125 \emph default
2126  where it describes how to insert citations.
2127  The basic mechanism for inserting BibTeX references is the same.
2128  Then, at the very end of your document, select 
2129 \family sans
2130 Insert\SpecialChar \menuseparator
2131 List
2132 \family default
2133  / 
2134 \family sans
2135 TOC\SpecialChar \menuseparator
2136 BibTeX Reference
2137 \family default
2138 .
2139  In the resulting dialog, fill out the dialog boxes as follows: 
2140 \end_layout
2141
2142 \begin_layout Description
2143
2144 Database: enter the name of your 
2145 \family typewriter
2146 .bib
2147 \family default
2148  file 
2149 \emph on
2150 without
2151 \emph default
2152  the 
2153 \family typewriter
2154 .bib
2155 \family default
2156  extension.
2157  For searching multiple 
2158 \family typewriter
2159 .bib
2160 \family default
2161  files, just enter them in the desired order, separated by commas.
2162  
2163 \end_layout
2164
2165 \begin_layout Description
2166
2167 Style: enter the name of your BibTeX style file *without* the 
2168 \family typewriter
2169 .bst
2170 \family default
2171  extension.
2172  The default style is 
2173 \family typewriter
2174 plain
2175 \family default
2176  (which should be included in your LaTeX distribution, so you don't have
2177  to worry about creating it).
2178 \end_layout
2179
2180 \begin_layout Standard
2181
2182 For each citation, assuming that the source is in the 
2183 \family typewriter
2184 .bib
2185 \family default
2186  file, just call 
2187 \family sans
2188 \bar under
2189 I
2190 \bar default
2191 nsert\SpecialChar \menuseparator
2192
2193 \bar under
2194 C
2195 \bar default
2196 itation Reference
2197 \family default
2198  at the correct location in the text, and enter the appropriate reference
2199  key.
2200  Nothing else is required; when invoking 
2201 \family sans
2202 \bar under
2203 V
2204 \bar default
2205 iew\SpecialChar \menuseparator
2206
2207 \bar under
2208 D
2209 \bar default
2210 VI
2211 \family default
2212 , for example, you should see that BibTex and LaTeX are invoked as needed,
2213  including multiple invocations of LaTeX.
2214  
2215 \end_layout
2216
2217 \begin_layout Section
2218
2219 Making an Index
2220 \end_layout
2221
2222 \begin_layout Standard
2223
2224 A good index is one of the hardest things to make in a lengthy document,
2225  but LyX helps make things a bit simpler by interfacing to the 
2226 \family typewriter
2227 makeindex
2228 \family default
2229  program which is found in most recent LaTeX distributions.
2230  Inserting an index and marking words to include in it works much the same
2231  way as preparing a bibliography as mentioned in the last section.
2232 \end_layout
2233
2234 \begin_layout Standard
2235
2236 First, go to the end of your file and select 
2237 \family sans
2238 \bar under
2239 I
2240 \bar default
2241 nsert\SpecialChar \menuseparator
2242 List
2243 \family default
2244 \InsetSpace ~
2245 /\InsetSpace ~
2246
2247 \family sans
2248 T
2249 \bar under
2250 O
2251 \bar default
2252 C\SpecialChar \menuseparator
2253
2254 \bar under
2255 I
2256 \bar default
2257 ndex
2258 \family default
2259 \InsetSpace ~
2260
2261 \family sans
2262 List
2263 \family default
2264 .
2265  Then, for each word you would like to include in the index, go to the end
2266  of that word and click on 
2267 \family sans
2268 \bar under
2269 I
2270 \bar default
2271 nsert\SpecialChar \menuseparator
2272
2273 \bar under
2274 I
2275 \bar default
2276 ndex
2277 \family default
2278 \InsetSpace ~
2279
2280 \family sans
2281 Entry
2282 \family default
2283 .
2284  This will insert a tag showing the word as it will appear in the index.
2285  That's all there is to it; LyX will automatically call 
2286 \family typewriter
2287 makeindex
2288 \family default
2289  for you and create the index itself.
2290  The text in the dialog available from right-clicking on the index button
2291  accepts LaTeX, so you'll need to be careful to avoid using any special
2292  characters.
2293  On the positive side, you can use the advanced options - have a look at
2294  the documentation which comes with your LaTeX distribution to find out
2295  how to do things like 
2296 \begin_inset Quotes eld
2297 \end_inset
2298
2299 nested entries
2300 \begin_inset Quotes erd
2301 \end_inset
2302
2303 , etc.
2304 \end_layout
2305
2306 \begin_layout Standard
2307
2308 Be careful not to put spaces between the word in the text and the index
2309  marker; apparently the wrong page number can be produced if this happens.
2310 \end_layout
2311
2312 \begin_layout Section
2313
2314 Multipart Documents
2315 \end_layout
2316
2317 \begin_layout Subsection
2318
2319 General Operation
2320 \end_layout
2321
2322 \begin_layout Standard
2323
2324 When you are working on a large file with many sections, it is often convenient
2325  to break up the document into several files, or perhaps you have something
2326  where a table may change from time to time, but the preceding text does
2327  not.
2328  In these cases, you should seriously consider using multipart documents.
2329  For example, scientific papers often have five major sections: the introduction
2330 , observations, results, discussion, and conclusion.
2331  Each of these could be its own separate LyX file, with one 
2332 \begin_inset Quotes eld
2333 \end_inset
2334
2335 master
2336 \begin_inset Quotes erd
2337 \end_inset
2338
2339  file which contains the title, authors, abstract, references, etc., plus
2340  the five included files.
2341  It is important to note that each of these files is a full LyX file which
2342  can be formatted and printed on its own, as well as included in a master
2343  file.
2344  Each of these files must have the same document class, however--- don't
2345  attempt to mix book classes with article classes.
2346  You may also include LaTeX files; however, these files must not have their
2347  own preamble 
2348 \emph on
2349 (i.e.
2350
2351 \emph default
2352  everything up to and including the 
2353 \family typewriter
2354
2355 \backslash
2356 begin{document}
2357 \family default
2358  line as well as the 
2359 \family typewriter
2360
2361 \backslash
2362 end{document}
2363 \family default
2364  line must be deleted) or else errors will be generated when you try to
2365  make a DVI file.
2366 \end_layout
2367
2368 \begin_layout Standard
2369
2370 LyX allows you to include files quite easily with 
2371 \family sans
2372 \bar under
2373 I
2374 \bar default
2375 nsert\SpecialChar \menuseparator
2376 ChiI
2377 \bar under
2378 d
2379 \bar default
2380 \InsetSpace ~
2381 Document
2382 \family default
2383 .
2384  When you click on this selection a small box is inserted into the file
2385  at the current cursor location.
2386  Clicking on the box raises a dialog which allows you to select the file
2387  to be included, and the method of its inclusion.
2388  
2389 \end_layout
2390
2391 \begin_layout Standard
2392
2393 The file selection box should by now be obvious.
2394  The three inclusion methods are 
2395 \begin_inset Quotes eld
2396 \end_inset
2397
2398 include
2399 \begin_inset Quotes erd
2400 \end_inset
2401
2402
2403 \begin_inset Quotes eld
2404 \end_inset
2405
2406 input
2407 \begin_inset Quotes erd
2408 \end_inset
2409
2410 , and 
2411 \begin_inset Quotes eld
2412 \end_inset
2413
2414 verbatim
2415 \begin_inset Quotes erd
2416 \end_inset
2417
2418 .
2419  The difference between 
2420 \begin_inset Quotes eld
2421 \end_inset
2422
2423 include
2424 \begin_inset Quotes erd
2425 \end_inset
2426
2427  and 
2428 \begin_inset Quotes eld
2429 \end_inset
2430
2431 input
2432 \begin_inset Quotes erd
2433 \end_inset
2434
2435  is really only meaningful to LaTeXperts, but the practical difference is
2436  that files which are 
2437 \begin_inset Quotes eld
2438 \end_inset
2439
2440 included
2441 \begin_inset Quotes erd
2442 \end_inset
2443
2444  are typeset beginning on a new page, while files which are 
2445 \begin_inset Quotes eld
2446 \end_inset
2447
2448 inputted
2449 \begin_inset Quotes erd
2450 \end_inset
2451
2452  are typeset starting on the current page.
2453  Perhaps the labeling in LyX will be changed someday to reflect this.
2454 \end_layout
2455
2456 \begin_layout Standard
2457
2458 Generally, the master file is converted into a full LaTeX file before typesettin
2459 g, while the included files are converted to LaTeX files which do not have
2460  all the preamble information.
2461  Checking the 
2462 \family sans
2463 Don't
2464 \family default
2465 \InsetSpace ~
2466
2467 \family sans
2468 typeset
2469 \family default
2470  button prevents this conversion.
2471 \end_layout
2472
2473 \begin_layout Standard
2474
2475
2476 \begin_inset Quotes eld
2477 \end_inset
2478
2479 verbatim
2480 \begin_inset Quotes erd
2481 \end_inset
2482
2483  included file allows you to include a file typeset exactly as it appears
2484  in the file, i.e.\InsetSpace ~
2485 verbatim mode, with the characters set in a fixed-width
2486  typewriter font.
2487  Normally, spaces in this file are invisible, though two consecutive spaces
2488  are conserved, unlike LyX's normal treatment of spaces.
2489  However, setting the 
2490 \family sans
2491 \bar under
2492 M
2493 \bar default
2494 ark\InsetSpace ~
2495 spaces\InsetSpace ~
2496 in\InsetSpace ~
2497 output
2498 \family default
2499  checkbox typesets a mark to unambiguously define the presence of a space.
2500
2501 \emph on
2502  
2503 \end_layout
2504
2505 \begin_layout Subsection
2506
2507 Cross-References Between Files
2508 \end_layout
2509
2510 \begin_layout Standard
2511
2512 It is possible to set up cross-references between the different files.
2513  First, open all the files in question: let's call them A and B in a two
2514  file example, where B is included in A.
2515  Let's say you insert a label in A, then want to reference it in B.
2516  Open the cross-reference dialog in whilst in document B, and you can select
2517  the 
2518 \begin_inset Quotes eld
2519 \end_inset
2520
2521 buffer
2522 \begin_inset Quotes erd
2523 \end_inset
2524
2525  to use.
2526 \end_layout
2527
2528 \begin_layout Section
2529
2530 Algorithms
2531 \end_layout
2532
2533 \begin_layout Standard
2534
2535 The package 
2536 \family sans
2537 algorithm
2538 \family default
2539  is needed by LyX to be able to output algorithm floats.
2540  These are useful in placing short algorithms across page breaks and support
2541  an index of algorithms too.
2542 \end_layout
2543
2544 \begin_layout Section
2545
2546 Subfigures
2547 \end_layout
2548
2549 \begin_layout Standard
2550
2551 The package
2552 \family sans
2553  subfigure 
2554 \family default
2555 is used by LyX when you select ``subfigure'' in the graphics dialog and
2556  enter the subfigure caption.
2557  Several figures marked in this way can be packed into a single float with
2558  individual sub-captions.
2559 \end_layout
2560
2561 \begin_layout Section
2562
2563 Fancy Headers and Footers
2564 \end_layout
2565
2566 \begin_layout Standard
2567
2568 The default page layout is rather plain; for an article document class,
2569  all you get is a centered page number at the bottom of the page.
2570  This document is the book class, so it appears to be a bit fancier, but
2571  to really put on a show, you need to set the document page style to 
2572 \begin_inset Quotes eld
2573 \end_inset
2574
2575 fancy
2576 \begin_inset Quotes erd
2577 \end_inset
2578
2579 , as mentioned in the 
2580 \family sans
2581 User\InsetSpace ~
2582 Guide
2583 \family default
2584 .
2585  This section describes the LaTeX codes you need to insert in your LaTeX
2586  preamble or the text in order to get the desired effects.
2587 \end_layout
2588
2589 \begin_layout Standard
2590
2591 The page header is divided into three fields, not surprisingly labeled 
2592 \begin_inset Quotes eld
2593 \end_inset
2594
2595 left
2596 \begin_inset Quotes erd
2597 \end_inset
2598
2599
2600 \begin_inset Quotes eld
2601 \end_inset
2602
2603 center
2604 \begin_inset Quotes erd
2605 \end_inset
2606
2607 , and 
2608 \begin_inset Quotes eld
2609 \end_inset
2610
2611 right
2612 \begin_inset Quotes erd
2613 \end_inset
2614
2615 .
2616  The footer is also divided into these three fields.
2617  The LaTeX commands to set these fields in the simplest manner are 
2618 \family typewriter
2619
2620 \backslash
2621 lhead
2622 \family default
2623
2624 \family typewriter
2625
2626 \backslash
2627 chead
2628 \family default
2629
2630 \family typewriter
2631
2632 \backslash
2633 rhead
2634 \family default
2635
2636 \family typewriter
2637
2638 \backslash
2639 lfoot
2640 \family default
2641 , etc.
2642  Suppose you wish to put your name in the upper left hand corner of each
2643  page.
2644  Simply insert the following command in the preamble: 
2645 \end_layout
2646
2647 \begin_layout Standard
2648
2649
2650 \family typewriter
2651
2652 \backslash
2653 lhead{John Q.
2654  DocWriter}
2655 \end_layout
2656
2657 \begin_layout Standard
2658
2659 You will now see your name in the upper left.
2660  If a field has a default entry that you would like to get rid of (often
2661  the page number appears in the central footer, simply include a command
2662  with a blank argument, e.g.
2663 \end_layout
2664
2665 \begin_layout Standard
2666
2667
2668 \family typewriter
2669
2670 \backslash
2671 cfoot{}
2672 \end_layout
2673
2674 \begin_layout Standard
2675
2676 Let's get really fancy: lets put the section number with the word 
2677 \begin_inset Quotes eld
2678 \end_inset
2679
2680 Section
2681 \begin_inset Quotes erd
2682 \end_inset
2683
2684  (e.g.
2685  Section 3) in the upper left, the page number (e.g.
2686  Page 4) in the upper right, your name in the lower left, and the date in
2687  the lower right.
2688  The following commands should now appear in the preamble:
2689 \end_layout
2690
2691 \begin_layout Standard
2692
2693
2694 \family typewriter
2695
2696 \backslash
2697 lhead{Section 
2698 \backslash
2699 thesection}
2700 \end_layout
2701
2702 \begin_layout Standard
2703
2704
2705 \family typewriter
2706
2707 \backslash
2708 chead{}
2709 \end_layout
2710
2711 \begin_layout Standard
2712
2713
2714 \family typewriter
2715
2716 \backslash
2717 rhead{Page 
2718 \backslash
2719 thepage}
2720 \end_layout
2721
2722 \begin_layout Standard
2723
2724
2725 \family typewriter
2726
2727 \backslash
2728 lfoot{John Q.
2729  DocWriter}
2730 \end_layout
2731
2732 \begin_layout Standard
2733
2734
2735 \family typewriter
2736
2737 \backslash
2738 cfoot{}
2739 \end_layout
2740
2741 \begin_layout Standard
2742
2743
2744 \family typewriter
2745
2746 \backslash
2747 rfoot{
2748 \backslash
2749 today}
2750 \end_layout
2751
2752 \begin_layout Standard
2753
2754 The codes 
2755 \family typewriter
2756
2757 \backslash
2758 thesection
2759 \family default
2760  and 
2761 \family typewriter
2762
2763 \backslash
2764 thepage
2765 \family default
2766  access LaTeX's section and page counters, and so print out the current
2767  section and page numbers.
2768  
2769 \family typewriter
2770
2771 \backslash
2772 today
2773 \family default
2774  simply prints out today's date.
2775 \end_layout
2776
2777 \begin_layout Standard
2778
2779 The thicknesses of the horizontal rules drawn beneath the header and above
2780  the footer can also be modified.
2781  If you don't want one of the headers, set its thickness to 0.
2782  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
2783  Use the commands, e.g.
2784  
2785 \family typewriter
2786
2787 \backslash
2788 renewcommand{
2789 \backslash
2790 headrulewidth}{0.4pt}
2791 \family default
2792  and 
2793 \family typewriter
2794
2795 \backslash
2796 renewcommand{
2797 \backslash
2798 footrulewidth}{0.4pt}
2799 \family default
2800  to set the thicknesses.
2801 \end_layout
2802
2803 \begin_layout Standard
2804
2805 You can switch the header/footer settings on and off for individual pages
2806  using commands like 
2807 \family typewriter
2808
2809 \backslash
2810 thispagestyle{empty}
2811 \family default
2812
2813 \family typewriter
2814
2815 \backslash
2816 thispagestyle{plain}
2817 \family default
2818 , and 
2819 \family typewriter
2820
2821 \backslash
2822 thispagestyle{fancy}
2823 \family default
2824 .
2825  Simply insert them in the text on the page you want changed and mark them
2826  as TeX code.
2827  In fact, title pages are marked as plain by default, while following pages
2828  are marked fancy when using the global fancy setting.
2829 \end_layout
2830
2831 \begin_layout Standard
2832
2833 There are more complex commands which will let you insert things in the
2834  upper left on odd numbered pages, etc., but I will refer you to the 
2835 \family typewriter
2836 fancyhdr
2837 \family default
2838  package documentation for more descriptions.
2839  For example, if you have a teTeX installation, look for 
2840 \family typewriter
2841 /usr/share/texmf/doc/latex/fancyhdr/\SpecialChar \-
2842 fancyhdr.dvi
2843 \family default
2844 .
2845 \end_layout
2846
2847 \begin_layout Standard
2848
2849 As a final example, it is possible to include an Encapsulated PostScript®
2850  file in the header or footer.
2851  Suppose you want to put a company logo in the upper lefthand corner.
2852  You might try something like
2853 \end_layout
2854
2855 \begin_layout Standard
2856
2857
2858 \family typewriter
2859
2860 \backslash
2861 lhead{
2862 \backslash
2863 resizebox{1in}{!}{
2864 \backslash
2865 includegraphics{logo.eps}}}
2866 \end_layout
2867
2868 \begin_layout Standard
2869 \noindent
2870 (you may need to preface this with 
2871 \family typewriter
2872
2873 \backslash
2874 usepackage{graphics}
2875 \family default
2876  if you don't include EPS files elsewhere in your document).
2877 \end_layout
2878
2879 \begin_layout Section
2880
2881 Minipages
2882 \end_layout
2883
2884 \begin_layout Standard
2885
2886 LaTeX provides a mechanism to produce essentially a page within a page,
2887  called minipages.
2888  Within a minipage, all the usual rules of indentation, line wrapping, etc.\InsetSpace ~
2889 apply.
2890  LyX also provides some of the minipage capability.
2891 \end_layout
2892
2893 \begin_layout Standard
2894
2895 Minipages in LyX have their own collapsable box; insert one via 
2896 \family sans
2897 \bar under
2898 I
2899 \bar default
2900 nsert\SpecialChar \menuseparator
2901 Mini
2902 \bar under
2903 p
2904 \bar default
2905 age
2906 \family default
2907 .
2908  Right-clicking on the box allows you to alter the minipage's width and
2909  alignment within the page.
2910  Warning: if the minipage is too long to fit on a page, it is truncated,
2911  not wrapped onto the next page.
2912 \end_layout
2913
2914 \begin_layout Standard
2915
2916 If you place two minipages side-by-side, you can use 
2917 \family sans
2918 \bar under
2919 I
2920 \bar default
2921 nsert\SpecialChar \menuseparator
2922
2923 \bar under
2924 S
2925 \bar default
2926 pecial\InsetSpace ~
2927 Character
2928 \family default
2929  to insert a special instruction known in the LaTeX world as an 
2930 \family typewriter
2931 hfill
2932 \family default
2933  to put a maximum amount of space between them; it forces one minipage to
2934  the left edge, the other to the right edge.
2935  The examples below show the difference.
2936 \end_layout
2937
2938 \begin_layout Standard
2939
2940
2941 \begin_inset Box Frameless
2942 position "t"
2943 hor_pos "c"
2944 has_inner_box 1
2945 inner_pos "c"
2946 use_parbox 0
2947 width "1.5in"
2948 special "none"
2949 height "1pt"
2950 height_special "totalheight"
2951 status open
2952
2953 \begin_layout Standard
2954
2955 This is a minipage which does not use hfill.
2956  This is the second sentence of a minipage which does not use hfill.
2957 \end_layout
2958
2959 \end_inset
2960
2961
2962 \end_layout
2963
2964 \begin_layout Standard
2965
2966
2967 \begin_inset Box Frameless
2968 position "t"
2969 hor_pos "c"
2970 has_inner_box 1
2971 inner_pos "c"
2972 use_parbox 0
2973 width "1.5in"
2974 special "none"
2975 height "1pt"
2976 height_special "totalheight"
2977 status open
2978
2979 \begin_layout Standard
2980
2981 This is a second minipage which does not use hfill.
2982  This is the second sentence of a second minipage which does not use hfill.
2983 \end_layout
2984
2985 \end_inset
2986
2987
2988 \end_layout
2989
2990
2991 \begin_layout Standard
2992
2993
2994 \begin_inset VSpace medskip
2995 \end_inset
2996
2997
2998 \end_layout
2999
3000 \begin_layout Standard
3001
3002 Here is some normal text to separate the two examples.
3003 \end_layout
3004
3005 \begin_layout Standard
3006
3007
3008 \begin_inset VSpace medskip
3009 \end_inset
3010
3011
3012 \end_layout
3013
3014
3015 \begin_layout Standard
3016
3017
3018 \begin_inset Box Frameless
3019 position "t"
3020 hor_pos "c"
3021 has_inner_box 1
3022 inner_pos "c"
3023 use_parbox 0
3024 width "1.5in"
3025 special "none"
3026 height "1pt"
3027 height_special "totalheight"
3028 status open
3029
3030 \begin_layout Standard
3031
3032 This is a minipage which does use hfill.
3033  This is the second sentence of a minipage which does use hfill.
3034 \end_layout
3035
3036 \end_inset
3037
3038
3039 \hfill
3040
3041 \begin_inset Box Frameless
3042 position "t"
3043 hor_pos "c"
3044 has_inner_box 1
3045 inner_pos "c"
3046 use_parbox 0
3047 width "1.5in"
3048 special "none"
3049 height "1pt"
3050 height_special "totalheight"
3051 status open
3052
3053 \begin_layout Standard
3054
3055 This is a second minipage which does use hfill.
3056  This is the second sentence of a second minipage which does use hfill.
3057 \end_layout
3058
3059 \end_inset
3060
3061
3062 \end_layout
3063
3064 \begin_layout Section
3065
3066 Wrapping Text Around Figures
3067 \begin_inset LatexCommand \label{sec:floatflt}
3068
3069 \end_inset
3070
3071
3072 \end_layout
3073
3074 \begin_layout Standard
3075
3076
3077 \begin_inset Wrap figure
3078 placement r
3079 width "6cm"
3080 status open
3081
3082 \begin_layout Standard
3083
3084
3085 \begin_inset Graphics
3086         filename mobius.eps
3087         display color
3088         width 40col%
3089         rotateOrigin center
3090
3091 \end_inset
3092
3093
3094 \end_layout
3095
3096 \begin_layout Caption
3097
3098 This is a wrapped figure, and this is the brilliant caption that describes
3099  it
3100 \end_layout
3101
3102 \end_inset
3103
3104
3105 \end_layout
3106
3107 \begin_layout Standard
3108
3109 A very frequently asked question is whether text can be made to 
3110 \begin_inset Quotes eld
3111 \end_inset
3112
3113 wrap
3114 \begin_inset Quotes erd
3115 \end_inset
3116
3117  around figures so that a figure occupies some fraction of the column width
3118  and text fills the rest.
3119  If you have the LaTeX package 
3120 \family typewriter
3121 floatflt
3122 \family default
3123  installed (you can find out about it in the 
3124 \emph on
3125 LaTeX Configuration
3126 \emph default
3127  manual) you can do this.
3128 \end_layout
3129
3130 \begin_layout Standard
3131
3132 At the right is a figure of a mobius strip---you should have already seen
3133  this in the 
3134 \emph on
3135 User's Guide
3136 \emph default
3137 .
3138  To wrap the text like this insert a wrap box via 
3139 \family sans
3140 \bar under
3141 I
3142 \bar default
3143 nsert\SpecialChar \menuseparator
3144 Flo
3145 \bar under
3146 a
3147 \bar default
3148 ts\SpecialChar \menuseparator
3149 Floatflt Figure
3150 \family default
3151 .
3152 \end_layout
3153
3154 \begin_layout Standard
3155
3156 Note: this package is very fragile! For example, having a figure too close
3157  to the bottom of the page will mess things up, as will having two figures
3158  close together.
3159  Use this package sparingly and do read the documentation that came with
3160  it (which will also tell you how to wrap text around tables).
3161 \end_layout
3162
3163 \begin_layout Section
3164
3165 Extra Table Options
3166 \end_layout
3167
3168 \begin_layout Standard
3169
3170 While the standard table layout will suffice in 99% of all tables you generate,
3171  occasionally you will run into one which requires a bit of extra tweaking.
3172  The table dialog which appears on a right-click of a table allows these
3173  tweaks to be made.
3174  It will give you access to some extra column alignment parameters.
3175  A little bit of LaTeX background is useful here: when you set up a table
3176  in LaTeX, each column is given an alignment type.
3177  For example, you would give it 
3178 \begin_inset Quotes eld
3179 \end_inset
3180
3181
3182 \family typewriter
3183 l
3184 \family default
3185
3186 \begin_inset Quotes erd
3187 \end_inset
3188
3189
3190 \begin_inset Quotes eld
3191 \end_inset
3192
3193
3194 \family typewriter
3195 c
3196 \family default
3197
3198 \begin_inset Quotes erd
3199 \end_inset
3200
3201 , or 
3202 \begin_inset Quotes eld
3203 \end_inset
3204
3205
3206 \family typewriter
3207 r
3208 \family default
3209
3210 \begin_inset Quotes erd
3211 \end_inset
3212
3213  for left-aligned, centered, and right-aligned columns respectively (which
3214  appear as the left/center/right radio buttons in LyX).
3215  A fourth type is 
3216 \begin_inset Quotes eld
3217 \end_inset
3218
3219
3220 \family typewriter
3221 p
3222 \family default
3223
3224 \begin_inset Quotes erd
3225 \end_inset
3226
3227 , which will make a column of a specified width (the width box in LyX),
3228  and will wrap text within that box.
3229  A fifth type is 
3230 \begin_inset Quotes eld
3231 \end_inset
3232
3233
3234 \family typewriter
3235 |
3236 \family default
3237
3238 \begin_inset Quotes erd
3239 \end_inset
3240
3241  (vertical bar) which rather than making a column will make a vertical rule
3242  at that point; this manifests itself in LyX as the 
3243 \begin_inset Quotes eld
3244 \end_inset
3245
3246 borders
3247 \begin_inset Quotes erd
3248 \end_inset
3249
3250  buttons.
3251  Finally, there is a type 
3252 \begin_inset Quotes eld
3253 \end_inset
3254
3255
3256 \family typewriter
3257 @
3258 \family default
3259
3260 \begin_inset Quotes erd
3261 \end_inset
3262
3263 , which allows you to use whatever is enclosed in the accompanying braces
3264  as the column separator, including a null argument.
3265  The reasons for doing this may not be obvious, but they can be very powerful.
3266  They are best demonstrated by example.
3267 \end_layout
3268
3269 \begin_layout Subsection
3270
3271 Removing Extra Column Space
3272 \end_layout
3273
3274 \begin_layout Standard
3275
3276 Here is a standard table:
3277 \end_layout
3278
3279 \begin_layout Standard
3280 \align center
3281
3282 \begin_inset  Tabular
3283 <lyxtabular version="3" rows="3" columns="2">
3284 <features>
3285 <column alignment="left" valignment="top" width="0pt">
3286 <column alignment="left" valignment="top" leftline="true" width="0pt">
3287 <row bottomline="true">
3288 <cell alignment="left" valignment="top" topline="true" usebox="none">
3289 \begin_inset Text
3290
3291 \begin_layout Standard
3292
3293
3294 \family roman
3295 \series medium
3296 \shape up
3297 \size normal
3298 \emph off
3299 \bar no
3300 \noun off
3301 \color none
3302 Type
3303 \end_layout
3304
3305 \end_inset
3306 </cell>
3307 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
3308 \begin_inset Text
3309
3310 \begin_layout Standard
3311
3312
3313 \family roman
3314 \series medium
3315 \shape up
3316 \size normal
3317 \emph off
3318 \bar no
3319 \noun off
3320 \color none
3321 Example
3322 \end_layout
3323
3324 \end_inset
3325 </cell>
3326 </row>
3327 <row>
3328 <cell alignment="left" valignment="top" topline="true" usebox="none">
3329 \begin_inset Text
3330
3331 \begin_layout Standard
3332
3333
3334 \family roman
3335 \series medium
3336 \shape up
3337 \size normal
3338 \emph off
3339 \bar no
3340 \noun off
3341 \color none
3342 Rock
3343 \end_layout
3344
3345 \end_inset
3346 </cell>
3347 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3348 \begin_inset Text
3349
3350 \begin_layout Standard
3351
3352
3353 \family roman
3354 \series medium
3355 \shape up
3356 \size normal
3357 \emph off
3358 \bar no
3359 \noun off
3360 \color none
3361 Granite
3362 \end_layout
3363
3364 \end_inset
3365 </cell>
3366 </row>
3367 <row>
3368 <cell alignment="center" valignment="top" topline="true" usebox="none">
3369 \begin_inset Text
3370
3371 \begin_layout Standard
3372
3373
3374 \family roman
3375 \series medium
3376 \shape up
3377 \size normal
3378 \emph off
3379 \bar no
3380 \noun off
3381 \color none
3382 Mineral
3383 \end_layout
3384
3385 \end_inset
3386 </cell>
3387 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3388 \begin_inset Text
3389
3390 \begin_layout Standard
3391
3392
3393 \family roman
3394 \series medium
3395 \shape up
3396 \size normal
3397 \emph off
3398 \bar no
3399 \noun off
3400 \color none
3401 Quartz
3402 \end_layout
3403
3404 \end_inset
3405 </cell>
3406 </row>
3407 </lyxtabular>
3408
3409 \end_inset
3410
3411
3412 \end_layout
3413
3414 \begin_layout Standard
3415
3416 Notice that the horizontal rule extends a bit past the text on both sides.
3417  If you wanted the line to end even with the text, we can put a null separator
3418  on the ends to get rid of the bit of extra space LaTeX adds by default.
3419  Here is the example:
3420 \end_layout
3421
3422 \begin_layout Standard
3423 \align center
3424
3425 \begin_inset  Tabular
3426 <lyxtabular version="3" rows="3" columns="2">
3427 <features>
3428 <column alignment="left" valignment="top" width="0pt" special="@{} l">
3429 <column alignment="left" valignment="top" leftline="true" width="0pt" special="l @{}">
3430 <row bottomline="true">
3431 <cell alignment="left" valignment="top" topline="true" usebox="none">
3432 \begin_inset Text
3433
3434 \begin_layout Standard
3435
3436
3437 \family roman
3438 \series medium
3439 \shape up
3440 \size normal
3441 \emph off
3442 \bar no
3443 \noun off
3444 \color none
3445 Type
3446 \end_layout
3447
3448 \end_inset
3449 </cell>
3450 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
3451 \begin_inset Text
3452
3453 \begin_layout Standard
3454
3455
3456 \family roman
3457 \series medium
3458 \shape up
3459 \size normal
3460 \emph off
3461 \bar no
3462 \noun off
3463 \color none
3464 Example
3465 \end_layout
3466
3467 \end_inset
3468 </cell>
3469 </row>
3470 <row>
3471 <cell alignment="left" valignment="top" topline="true" usebox="none">
3472 \begin_inset Text
3473
3474 \begin_layout Standard
3475
3476
3477 \family roman
3478 \series medium
3479 \shape up
3480 \size normal
3481 \emph off
3482 \bar no
3483 \noun off
3484 \color none
3485 Rock
3486 \end_layout
3487
3488 \end_inset
3489 </cell>
3490 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3491 \begin_inset Text
3492
3493 \begin_layout Standard
3494
3495
3496 \family roman
3497 \series medium
3498 \shape up
3499 \size normal
3500 \emph off
3501 \bar no
3502 \noun off
3503 \color none
3504 Granite
3505 \end_layout
3506
3507 \end_inset
3508 </cell>
3509 </row>
3510 <row>
3511 <cell alignment="center" valignment="top" topline="true" usebox="none">
3512 \begin_inset Text
3513
3514 \begin_layout Standard
3515
3516
3517 \family roman
3518 \series medium
3519 \shape up
3520 \size normal
3521 \emph off
3522 \bar no
3523 \noun off
3524 \color none
3525 Mineral
3526 \end_layout
3527
3528 \end_inset
3529 </cell>
3530 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3531 \begin_inset Text
3532
3533 \begin_layout Standard
3534
3535
3536 \family roman
3537 \series medium
3538 \shape up
3539 \size normal
3540 \emph off
3541 \bar no
3542 \noun off
3543 \color none
3544 Quartz
3545 \end_layout
3546
3547 \end_inset
3548 </cell>
3549 </row>
3550 </lyxtabular>
3551
3552 \end_inset
3553
3554
3555 \end_layout
3556
3557 \begin_layout Standard
3558
3559 In this case, the column specifier for the left column was set to 
3560 \begin_inset Quotes eld
3561 \end_inset
3562
3563
3564 \family typewriter
3565 @{} l
3566 \family default
3567
3568 \begin_inset Quotes erd
3569 \end_inset
3570
3571 , while the right column was set to 
3572 \begin_inset Quotes eld
3573 \end_inset
3574
3575
3576 \family typewriter
3577 l @{}
3578 \family default
3579
3580 \begin_inset Quotes erd
3581 \end_inset
3582
3583 , in order to put the null characters on the edges.
3584  
3585 \end_layout
3586
3587 \begin_layout Subsection
3588
3589 Changing the Column Separator Character
3590 \end_layout
3591
3592 \begin_layout Standard
3593
3594 Now suppose you really wanted, for reasons that are completely opaque, to
3595  use 
3596 \begin_inset Formula $\sqrt{\pi}$
3597 \end_inset
3598
3599  with some space around it for the column separator.
3600  Simply turn off the vertical border, then set the right column specifier
3601  to 
3602 \begin_inset Quotes eld
3603 \end_inset
3604
3605
3606 \family typewriter
3607 @{~$
3608 \backslash
3609 sqrt{
3610 \backslash
3611 pi}$~} l
3612 \family default
3613
3614 \begin_inset Quotes erd
3615 \end_inset
3616
3617 .
3618  You could now make a table like this:
3619 \end_layout
3620
3621 \begin_layout Standard
3622 \align center
3623
3624 \begin_inset  Tabular
3625 <lyxtabular version="3" rows="3" columns="2">
3626 <features>
3627 <column alignment="left" valignment="top" width="0pt">
3628 <column alignment="left" valignment="top" width="0in" special="@{~$\sqrt{\pi}$~}l">
3629 <row bottomline="true">
3630 <cell alignment="left" valignment="top" topline="true" usebox="none">
3631 \begin_inset Text
3632
3633 \begin_layout Standard
3634
3635
3636 \family roman
3637 \series medium
3638 \shape up
3639 \size normal
3640 \emph off
3641 \bar no
3642 \noun off
3643 \color none
3644 Type
3645 \end_layout
3646
3647 \end_inset
3648 </cell>
3649 <cell alignment="left" valignment="top" topline="true" usebox="none">
3650 \begin_inset Text
3651
3652 \begin_layout Standard
3653
3654
3655 \family roman
3656 \series medium
3657 \shape up
3658 \size normal
3659 \emph off
3660 \bar no
3661 \noun off
3662 \color none
3663 Example
3664 \end_layout
3665
3666 \end_inset
3667 </cell>
3668 </row>
3669 <row>
3670 <cell alignment="left" valignment="top" topline="true" usebox="none">
3671 \begin_inset Text
3672
3673 \begin_layout Standard
3674
3675
3676 \family roman
3677 \series medium
3678 \shape up
3679 \size normal
3680 \emph off
3681 \bar no
3682 \noun off
3683 \color none
3684 Rock
3685 \end_layout
3686
3687 \end_inset
3688 </cell>
3689 <cell alignment="center" valignment="top" topline="true" usebox="none">
3690 \begin_inset Text
3691
3692 \begin_layout Standard
3693
3694
3695 \family roman
3696 \series medium
3697 \shape up
3698 \size normal
3699 \emph off
3700 \bar no
3701 \noun off
3702 \color none
3703 Granite
3704 \end_layout
3705
3706 \end_inset
3707 </cell>
3708 </row>
3709 <row>
3710 <cell alignment="center" valignment="top" topline="true" usebox="none">
3711 \begin_inset Text
3712
3713 \begin_layout Standard
3714
3715
3716 \family roman
3717 \series medium
3718 \shape up
3719 \size normal
3720 \emph off
3721 \bar no
3722 \noun off
3723 \color none
3724 Mineral
3725 \end_layout
3726
3727 \end_inset
3728 </cell>
3729 <cell alignment="center" valignment="top" topline="true" usebox="none">
3730 \begin_inset Text
3731
3732 \begin_layout Standard
3733
3734
3735 \family roman
3736 \series medium
3737 \shape up
3738 \size normal
3739 \emph off
3740 \bar no
3741 \noun off
3742 \color none
3743 Quartz
3744 \end_layout
3745
3746 \end_inset
3747 </cell>
3748 </row>
3749 </lyxtabular>
3750
3751 \end_inset
3752
3753
3754 \end_layout
3755
3756 \begin_layout Subsection
3757
3758 Making a Decimal Point Aligned Column
3759 \end_layout
3760
3761 \begin_layout Standard
3762
3763 Okay, that last example was very silly, but here is one that is not.
3764  Suppose you want to make a table that has a column which is aligned on
3765  a decimal point.
3766  A standard LaTeX trick to do this is to set the whole number part in a
3767  right-aligned column, use a decimal point for the column separator, then
3768  set the fractional part as a left-aligned column.
3769  A variation on this is to include the decimal point explicitly with the
3770  whole part, then use just a null separator in between.
3771  The latter variation is demonstrated here:
3772 \end_layout
3773
3774 \begin_layout Standard
3775 \align center
3776
3777 \begin_inset  Tabular
3778 <lyxtabular version="3" rows="5" columns="3">
3779 <features>
3780 <column alignment="center" valignment="top" width="0pt">
3781 <column alignment="right" valignment="top" leftline="true" width="0pt">
3782 <column alignment="center" valignment="top" width="0pt" special="@{} l">
3783 <row bottomline="true">
3784 <cell alignment="center" valignment="top" topline="true" usebox="none">
3785 \begin_inset Text
3786
3787 \begin_layout Standard
3788
3789
3790 \family roman
3791 \series medium
3792 \shape up
3793 \size normal
3794 \emph off
3795 \bar no
3796 \noun off
3797 \color none
3798 Expression
3799 \end_layout
3800
3801 \end_inset
3802 </cell>
3803 <cell multicolumn="1" alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
3804 \begin_inset Text
3805
3806 \begin_layout Standard
3807
3808
3809 \family roman
3810 \series medium
3811 \shape up
3812 \size normal
3813 \emph off
3814 \bar no
3815 \noun off
3816 \color none
3817 Value 
3818 \end_layout
3819
3820 \end_inset
3821 </cell>
3822 <cell multicolumn="2" alignment="center" valignment="top" topline="true" usebox="none">
3823 \begin_inset Text
3824
3825 \begin_layout Standard
3826
3827 \end_layout
3828
3829 \end_inset
3830 </cell>
3831 </row>
3832 <row>
3833 <cell alignment="center" valignment="top" topline="true" usebox="none">
3834 \begin_inset Text
3835
3836 \begin_layout Standard
3837
3838
3839 \family roman
3840 \series medium
3841 \shape up
3842 \size normal
3843 \emph off
3844 \bar no
3845 \noun off
3846 \color none
3847
3848 \begin_inset Formula $\pi$
3849 \end_inset
3850
3851
3852 \end_layout
3853
3854 \end_inset
3855 </cell>
3856 <cell alignment="right" valignment="top" topline="true" leftline="true" usebox="none">
3857 \begin_inset Text
3858
3859 \begin_layout Standard
3860
3861
3862 \family roman
3863 \series medium
3864 \shape up
3865 \size normal
3866 \emph off
3867 \bar no
3868 \noun off
3869 \color none
3870 3.
3871 \end_layout
3872
3873 \end_inset
3874 </cell>
3875 <cell alignment="center" valignment="top" topline="true" usebox="none">
3876 \begin_inset Text
3877
3878 \begin_layout Standard
3879
3880
3881 \family roman
3882 \series medium
3883 \shape up
3884 \size normal
3885 \emph off
3886 \bar no
3887 \noun off
3888 \color none
3889 1416
3890 \end_layout
3891
3892 \end_inset
3893 </cell>
3894 </row>
3895 <row>
3896 <cell alignment="center" valignment="top" topline="true" usebox="none">
3897 \begin_inset Text
3898
3899 \begin_layout Standard
3900
3901
3902 \family roman
3903 \series medium
3904 \shape up
3905 \size normal
3906 \emph off
3907 \bar no
3908 \noun off
3909 \color none
3910
3911 \begin_inset Formula $\pi^{\pi}$
3912 \end_inset
3913
3914
3915 \end_layout
3916
3917 \end_inset
3918 </cell>
3919 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3920 \begin_inset Text
3921
3922 \begin_layout Standard
3923
3924
3925 \family roman
3926 \series medium
3927 \shape up
3928 \size normal
3929 \emph off
3930 \bar no
3931 \noun off
3932 \color none
3933 36.
3934 \end_layout
3935
3936 \end_inset
3937 </cell>
3938 <cell alignment="center" valignment="top" topline="true" usebox="none">
3939 \begin_inset Text
3940
3941 \begin_layout Standard
3942
3943
3944 \family roman
3945 \series medium
3946 \shape up
3947 \size normal
3948 \emph off
3949 \bar no
3950 \noun off
3951 \color none
3952 462
3953 \end_layout
3954
3955 \end_inset
3956 </cell>
3957 </row>
3958 <row>
3959 <cell alignment="center" valignment="top" topline="true" usebox="none">
3960 \begin_inset Text
3961
3962 \begin_layout Standard
3963
3964
3965 \family roman
3966 \series medium
3967 \shape up
3968 \size normal
3969 \emph off
3970 \bar no
3971 \noun off
3972 \color none
3973
3974 \begin_inset Formula $(\pi^{\pi})^{\pi}$
3975 \end_inset
3976
3977
3978 \end_layout
3979
3980 \end_inset
3981 </cell>
3982 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3983 \begin_inset Text
3984
3985 \begin_layout Standard
3986
3987
3988 \family roman
3989 \series medium
3990 \shape up
3991 \size normal
3992 \emph off
3993 \bar no
3994 \noun off
3995 \color none
3996 80663.
3997 \end_layout
3998
3999 \end_inset
4000 </cell>
4001 <cell alignment="center" valignment="top" topline="true" usebox="none">
4002 \begin_inset Text
4003
4004 \begin_layout Standard
4005
4006 \end_layout
4007
4008 \end_inset
4009 </cell>
4010 </row>
4011 <row>
4012 <cell alignment="center" valignment="top" topline="true" usebox="none">
4013 \begin_inset Text
4014
4015 \begin_layout Standard
4016
4017
4018 \family roman
4019 \series medium
4020 \shape up
4021 \size normal
4022 \emph off
4023 \bar no
4024 \noun off
4025 \color none
4026
4027 \begin_inset Formula $\pi^{\pi^{\pi}}$
4028 \end_inset
4029
4030
4031 \end_layout
4032
4033 \end_inset
4034 </cell>
4035 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4036 \begin_inset Text
4037
4038 \begin_layout Standard
4039
4040
4041 \family roman
4042 \series medium
4043 \shape up
4044 \size normal
4045 \emph off
4046 \bar no
4047 \noun off
4048 \color none
4049 1.
4050 \end_layout
4051
4052 \end_inset
4053 </cell>
4054 <cell alignment="center" valignment="top" topline="true" usebox="none">
4055 \begin_inset Text
4056
4057 \begin_layout Standard
4058
4059
4060 \family roman
4061 \series medium
4062 \shape up
4063 \size normal
4064 \emph off
4065 \bar no
4066 \noun off
4067 \color none
4068 3402
4069 \begin_inset Formula $\times10^{18}$
4070 \end_inset
4071
4072
4073 \end_layout
4074
4075 \end_inset
4076 </cell>
4077 </row>
4078 </lyxtabular>
4079
4080 \end_inset
4081
4082
4083 \end_layout
4084
4085 \begin_layout Standard
4086
4087 Though it appears a bit funny in LyX, on paper it will produce what appears
4088  to be a 2-column table in which the right column is aligned on the decimal
4089  point and the header appears to be centered over it.
4090 \end_layout
4091
4092 \begin_layout Standard
4093
4094 Perhaps it is best if I described just what I did: first, create a 3
4095 \begin_inset Formula $\times$
4096 \end_inset
4097
4098 3 table and remove all the borders.
4099  Then re-add a bottom border to the top row, and a right border to the first
4100  column.
4101  Type in the values for the first column and set its alignment to 
4102 \family sans
4103 center
4104 \family default
4105 .
4106  Type in the 
4107 \family typewriter
4108 3.
4109 \family default
4110
4111 \family typewriter
4112 36.
4113 \family default
4114
4115 \family typewriter
4116 80663.
4117 \family default
4118 , and 
4119 \family typewriter
4120 1.
4121
4122 \family default
4123  and set that column's alignment to 
4124 \family sans
4125 right
4126 \family default
4127 .
4128  Type in the 
4129 \family typewriter
4130 1416
4131 \family default
4132
4133 \family typewriter
4134 462
4135 \family default
4136 , and 
4137 \family typewriter
4138 3402
4139 \begin_inset Formula $\times10^{18}$
4140 \end_inset
4141
4142
4143 \family default
4144  and set the extra column alignment to 
4145 \family typewriter
4146 @{} l
4147 \family default
4148 .
4149  Finally type in the word 
4150 \family typewriter
4151 Value
4152 \family default
4153  in the middle column, highlight it and the blank entry to its right, and
4154  check the 
4155 \family sans
4156 Special Cell
4157 \family default
4158  entry 
4159 \family sans
4160 multicolumn
4161 \family default
4162 .
4163  Easy, right? 
4164 \end_layout
4165
4166 \begin_layout Subsection
4167
4168 A Better Decimal-Alignment Solution
4169 \end_layout
4170
4171 \begin_layout Standard
4172
4173 An alternative way to have decimal alignment in tables is through the 
4174 \family typewriter
4175 dcolumn
4176 \family default
4177  package.
4178  Add the following to the LateX preamble:
4179 \end_layout
4180
4181 \begin_layout LyX-Code
4182
4183
4184 \backslash
4185 usepackage{dcolumn}
4186 \end_layout
4187
4188 \begin_layout LyX-Code
4189
4190
4191 \backslash
4192 newcolumntype{d}[1]{D{.}{.}{#1}}
4193 \end_layout
4194
4195 \begin_layout Standard
4196
4197 To have a column decimally aligned, enter in the 
4198 \family sans
4199 Special Column Alignment
4200 \family default
4201  box of the 
4202 \family sans
4203 Table
4204 \family default
4205  dialog the following:
4206 \end_layout
4207
4208 \begin_layout LyX-Code
4209
4210 d{number of decimals of the data}
4211 \end_layout
4212
4213 \begin_layout Standard
4214
4215 To create extra column space just increase the number of decimals in 
4216 \family typewriter
4217 d{}
4218 \family default
4219 .
4220  Setting the multicolumn attribute for a single cell makes it insensitive
4221  to the decimal alignment which comes in handy as well.
4222  A drawback of this method is that math mode is not allowed in a column
4223  with decimal alignment except if the multicolumn attribute is set.
4224 \end_layout
4225
4226 \begin_layout Standard
4227
4228 This method offers the same flexibility as the 
4229 \family typewriter
4230 dcolumn
4231 \family default
4232  package.
4233  One could, for example, change the alignment separator, and have different
4234  alignment separators for different columns by defining multiple column
4235  types in the preamble.
4236  The syntax is as follows: 
4237 \end_layout
4238
4239 \begin_layout LyX-Code
4240
4241 D{inputsep}{outputsep}{decimal places}
4242 \end_layout
4243
4244 \begin_layout Standard
4245
4246 The interested reader is directed towards the 
4247 \family typewriter
4248 dcolumn
4249 \family default
4250  package documentation for more details.
4251 \end_layout
4252
4253 \begin_layout Section
4254
4255 Itemize Bullet Selection
4256 \begin_inset LatexCommand \label{sec:bullet}
4257
4258 \end_inset
4259
4260
4261 \end_layout
4262
4263 \begin_layout Standard
4264
4265 by
4266 \noun on
4267  Allan Rae
4268 \end_layout
4269
4270 \begin_layout Subsection
4271
4272 Introduction
4273 \end_layout
4274
4275 \begin_layout Standard
4276
4277 LyX provides 216 bullet shapes that can be accessed from a simple dialog.
4278  Using this dialog you can easily specify what bullet shape to use at each
4279  level of an itemized list.
4280  These settings are document-wide so you won't be able to specify different
4281  sets of bullets for different paragraphs
4282 \begin_inset Foot
4283 status collapsed
4284
4285 \begin_layout Standard
4286
4287 Well, actually you can but you'll have to do it by hand.
4288 \end_layout
4289
4290 \end_inset
4291
4292 .
4293 \end_layout
4294
4295 \begin_layout Subsection
4296
4297 How it looks
4298 \end_layout
4299
4300 \begin_layout Standard
4301
4302 Open the dialog by selecting the 
4303 \family sans
4304 \bar under
4305 D
4306 \bar default
4307 ocument\SpecialChar \menuseparator
4308
4309 \bar under
4310 S
4311 \bar default
4312 ettings
4313 \family default
4314  menu item and then select the 
4315 \family sans
4316 \bar under
4317 B
4318 \bar default
4319 ullets
4320 \family default
4321  tab.
4322 \end_layout
4323
4324 \begin_layout Standard
4325
4326 The dialog provides you with a table of bullet shapes.
4327  A column of buttons on the left of the table provides access to the six
4328  different panels of bullet shapes.
4329  The row of buttons across the top is used to select which bullet depth
4330  you are changing.
4331  A text entry under the table shows the currently selected bullet shape's
4332  LaTeX equivalent and this can be edited if desired.
4333  If you do modify the text you will also need to specify any needed packages
4334  in the LaTeX preamble.
4335 \end_layout
4336
4337 \begin_layout Standard
4338
4339 The six panels are divided up by the packages they require.
4340  The following table shows the mappings from button name to LaTeX packages.
4341 \end_layout
4342
4343 \begin_layout Standard
4344 \align center
4345
4346 \begin_inset  Tabular
4347 <lyxtabular version="3" rows="7" columns="2">
4348 <features>
4349 <column alignment="center" valignment="top" leftline="true" width="0pt">
4350 <column alignment="center" valignment="top" leftline="true" rightline="true" width="0pt">
4351 <row topline="true" bottomline="true">
4352 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4353 \begin_inset Text
4354
4355 \begin_layout Standard
4356
4357
4358 \family roman
4359 \series medium
4360 \shape up
4361 \size normal
4362 \emph off
4363 \bar no
4364 \noun off
4365 \color none
4366 Button
4367 \end_layout
4368
4369 \end_inset
4370 </cell>
4371 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4372 \begin_inset Text
4373
4374 \begin_layout Standard
4375
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 Packages Required
4386 \end_layout
4387
4388 \end_inset
4389 </cell>
4390 </row>
4391 <row topline="true">
4392 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4393 \begin_inset Text
4394
4395 \begin_layout Standard
4396
4397
4398 \family sans
4399 \series medium
4400 \shape up
4401 \size normal
4402 \emph off
4403 \bar no
4404 \noun off
4405 \color none
4406 Standard
4407 \end_layout
4408
4409 \end_inset
4410 </cell>
4411 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4412 \begin_inset Text
4413
4414 \begin_layout Standard
4415
4416
4417 \series medium
4418 \shape up
4419 \size normal
4420 \emph off
4421 \bar no
4422 \noun off
4423 \color none
4424 base LaTeX
4425 \end_layout
4426
4427 \end_inset
4428 </cell>
4429 </row>
4430 <row topline="true">
4431 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4432 \begin_inset Text
4433
4434 \begin_layout Standard
4435
4436
4437 \family sans
4438 \series medium
4439 \shape up
4440 \size normal
4441 \emph off
4442 \bar no
4443 \noun off
4444 \color none
4445 Maths
4446 \end_layout
4447
4448 \end_inset
4449 </cell>
4450 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4451 \begin_inset Text
4452
4453 \begin_layout Standard
4454
4455
4456 \family typewriter
4457 \series medium
4458 \shape up
4459 \size normal
4460 \emph off
4461 \bar no
4462 \noun off
4463 \color none
4464 amssymb.sty
4465 \end_layout
4466
4467 \end_inset
4468 </cell>
4469 </row>
4470 <row topline="true">
4471 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4472 \begin_inset Text
4473
4474 \begin_layout Standard
4475
4476
4477 \family sans
4478 \series medium
4479 \shape up
4480 \size normal
4481 \emph off
4482 \bar no
4483 \noun off
4484 \color none
4485 Ding1
4486 \end_layout
4487
4488 \end_inset
4489 </cell>
4490 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4491 \begin_inset Text
4492
4493 \begin_layout Standard
4494
4495
4496 \family typewriter
4497 \series medium
4498 \shape up
4499 \size normal
4500 \emph off
4501 \bar no
4502 \noun off
4503 \color none
4504 pifont.sty
4505 \end_layout
4506
4507 \end_inset
4508 </cell>
4509 </row>
4510 <row topline="true">
4511 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4512 \begin_inset Text
4513
4514 \begin_layout Standard
4515
4516
4517 \family sans
4518 \series medium
4519 \shape up
4520 \size normal
4521 \emph off
4522 \bar no
4523 \noun off
4524 \color none
4525 Ding2
4526 \end_layout
4527
4528 \end_inset
4529 </cell>
4530 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4531 \begin_inset Text
4532
4533 \begin_layout Standard
4534
4535
4536 \family typewriter
4537 \series medium
4538 \shape up
4539 \size normal
4540 \emph off
4541 \bar no
4542 \noun off
4543 \color none
4544 pifont.sty
4545 \end_layout
4546
4547 \end_inset
4548 </cell>
4549 </row>
4550 <row topline="true">
4551 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4552 \begin_inset Text
4553
4554 \begin_layout Standard
4555
4556
4557 \family sans
4558 \series medium
4559 \shape up
4560 \size normal
4561 \emph off
4562 \bar no
4563 \noun off
4564 \color none
4565 Ding3
4566 \end_layout
4567
4568 \end_inset
4569 </cell>
4570 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4571 \begin_inset Text
4572
4573 \begin_layout Standard
4574
4575
4576 \family typewriter
4577 \series medium
4578 \shape up
4579 \size normal
4580 \emph off
4581 \bar no
4582 \noun off
4583 \color none
4584 pifont.sty
4585 \end_layout
4586
4587 \end_inset
4588 </cell>
4589 </row>
4590 <row topline="true" bottomline="true">
4591 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4592 \begin_inset Text
4593
4594 \begin_layout Standard
4595
4596
4597 \family sans
4598 \series medium
4599 \shape up
4600 \size normal
4601 \emph off
4602 \bar no
4603 \noun off
4604 \color none
4605 Ding4
4606 \end_layout
4607
4608 \end_inset
4609 </cell>
4610 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4611 \begin_inset Text
4612
4613 \begin_layout Standard
4614
4615
4616 \family typewriter
4617 \series medium
4618 \shape up
4619 \size normal
4620 \emph off
4621 \bar no
4622 \noun off
4623 \color none
4624 pifont.sty
4625 \end_layout
4626
4627 \end_inset
4628 </cell>
4629 </row>
4630 </lyxtabular>
4631
4632 \end_inset
4633
4634
4635 \end_layout
4636
4637 \begin_layout Standard
4638
4639 LyX doesn't stop you using bullets from packages you don't have.
4640  If you get errors from LaTeX when you try to view or print the file then
4641  its likely you are missing a package.
4642  LyX doesn't restrict your use since you may be editing locally and exporting
4643  elsewhere.
4644 \end_layout
4645
4646 \begin_layout Subsection
4647
4648 How to use it
4649 \end_layout
4650
4651 \begin_layout Standard
4652
4653 Select which bullet depth you want to change then select the bullet shape
4654  and size.
4655
4656 \family sans
4657  
4658 \family default
4659 Any changes will not be visible in LyX, but are visible when viewing the
4660  document using xdvi or ghostview.
4661 \end_layout
4662
4663 \begin_layout Standard
4664
4665 You can reset a bullet shape to the default simply by clicking your right
4666  mouse button on the appropriate bullet depth button.
4667 \end_layout
4668
4669 \begin_layout Standard
4670
4671 If you 
4672 \emph on
4673 really
4674 \emph default
4675  want to have multiple sets of paragraphs with different sets of bullets
4676  in each then you're going to have to get your hands dirty.
4677  The itemize bullet selection dialog can help though because it provides
4678  you with the LaTeX code for a wide range of bullet shapes.
4679  To make your own custom paragraphs you have the following options:
4680 \end_layout
4681
4682 \begin_layout Standard
4683
4684
4685 \begin_inset ERT
4686 status inlined
4687
4688 \begin_layout Standard
4689
4690 \backslash
4691 let
4692 \backslash
4693 savelabelitemi=
4694 \backslash
4695 labelitemi
4696 \end_layout
4697
4698 \end_inset
4699
4700
4701 \end_layout
4702
4703 \begin_layout Standard
4704
4705
4706 \begin_inset ERT
4707 status inlined
4708
4709 \begin_layout Standard
4710
4711 \backslash
4712 renewcommand
4713 \backslash
4714 labelitemi[0]{
4715 \backslash
4716 small
4717 \backslash
4718 (
4719 \backslash
4720 sharp
4721 \backslash
4722 )}
4723 \end_layout
4724
4725 \end_inset
4726
4727
4728 \end_layout
4729
4730 \begin_layout Itemize
4731
4732 Use the LaTeX command 
4733 \family typewriter
4734
4735 \backslash
4736 renewcommand{}{}
4737 \family default
4738  to specify a new bullet shape for a given depth.
4739  You'll also need to save the current bullet shape so you can restore it
4740  again afterwards.
4741  In this itemized list the following LaTeX code was used to change the bullet
4742  used for the first depth.
4743 \newline
4744
4745 \family typewriter
4746
4747 \backslash
4748 let
4749 \backslash
4750 savelabelitemi=
4751 \backslash
4752 labelitemi
4753 \family default
4754  
4755 \family typewriter
4756
4757 \newline
4758
4759 \backslash
4760 renewcommand
4761 \backslash
4762 labelitemi[0]{
4763 \backslash
4764 small
4765 \backslash
4766 (
4767 \backslash
4768 sharp
4769 \backslash
4770 )}
4771 \newline
4772
4773 \family default
4774 Note that the itemize depth is specified in Roman numerals as part of the
4775  
4776 \family typewriter
4777
4778 \backslash
4779 labelitem
4780 \family default
4781  command.
4782 \end_layout
4783
4784 \begin_layout Itemize
4785
4786
4787 \begin_inset ERT
4788 status inlined
4789
4790 \begin_layout Standard
4791 [
4792 \backslash
4793 (
4794 \backslash
4795 star
4796 \backslash
4797 )]
4798 \end_layout
4799
4800 \end_inset
4801
4802  Specify each individual entry by starting each item with the bullet shape
4803  enclosed in square brackets and set as TeX.
4804  For example, this item was started with 
4805 \family typewriter
4806 [
4807 \backslash
4808 (
4809 \backslash
4810 star
4811 \backslash
4812 )]
4813 \family default
4814 .
4815 \end_layout
4816
4817 \begin_layout Standard
4818
4819
4820 \begin_inset ERT
4821 status inlined
4822
4823 \begin_layout Standard
4824
4825 \backslash
4826 renewcommand
4827 \backslash
4828 labelitemi[0]{
4829 \backslash
4830 savelabelitemi}
4831 \end_layout
4832
4833 \end_inset
4834
4835
4836 \end_layout
4837
4838 \begin_layout Standard
4839
4840 You'll also need to revert the labelitem back to its previous setting for
4841  the global bullet shape settings to remain in effect.
4842  The way used here was:
4843 \newline
4844
4845 \family typewriter
4846
4847 \backslash
4848 renewcommand
4849 \backslash
4850 labelitemi[0]{
4851 \backslash
4852 savelabelitemi}
4853 \end_layout
4854
4855 \begin_layout Chapter
4856
4857 Special Document Classes
4858 \end_layout
4859
4860 \begin_layout Section
4861
4862 AMS LaTeX
4863 \end_layout
4864
4865 \begin_layout Standard
4866
4867 by 
4868 \noun on
4869 David Johnson
4870 \end_layout
4871
4872
4873 \begin_layout Standard
4874
4875
4876 \begin_inset VSpace bigskip
4877 \end_inset
4878
4879
4880 \end_layout
4881
4882 \begin_layout Standard
4883 \noindent
4884 The AMS LaTeX layouts are set up to conform to suggested styles for mathematical
4885  papers to be submitted to American Mathematical Society publications.
4886  The layouts are not tailored to a specific journal, but easily can be.
4887  You should refer to the AMS documentation for specific instructions for
4888  each journal (usually it will entail only changing a single line in the
4889  TeX output).
4890  That documentation is available on the Web at 
4891 \begin_inset LatexCommand \url{http://www.ams.org}
4892
4893 \end_inset
4894
4895  or by ftp at 
4896 \begin_inset LatexCommand \url{ftp://ftp.ams.org/pub/tex/amslatex/}
4897
4898 \end_inset
4899
4900 .These layouts are appropriate, and useful, for any mathematical writing.
4901  There are currently 4 distinct AMS LaTeX layouts: 
4902 \end_layout
4903
4904 \begin_layout Enumerate
4905
4906 amsart: The standard AMS-article format.
4907  All results and similar statements are numbered as 
4908 \begin_inset Formula $(n.m)$
4909 \end_inset
4910
4911 , where the first number refers to the section, and the second refers to
4912  the total number of results (Theorems, Corollaries, Propositions, Definitions
4913  and Remarks, etc.) in that section.
4914  There are also many (but not all) environments available unnumbered, which
4915  is occasionally needed.
4916  Unnumbered environments indicated by an asterisk at the end.
4917 \end_layout
4918
4919 \begin_layout Enumerate
4920
4921 amsart-seq: Here, numbering for each type of statement is in its own sequence,
4922  with no reference to the section number.
4923  There are also many (but not all) environments available unnumbered, which
4924  is occasionally needed.
4925  Unnumbered environments indicated by an asterisk at the end.
4926 \end_layout
4927
4928 \begin_layout Enumerate
4929
4930 amsart-plain: This one is even more terse, since all the environments are
4931  unnumbered.
4932 \end_layout
4933
4934 \begin_layout Enumerate
4935
4936 amsbook: the standard AMS book (really, monograph) format.
4937  Numbering is similar to the amsart layout, except that all numbering is
4938  by 
4939 \begin_inset Formula $(n.m.p)$
4940 \end_inset
4941
4942 , where the first number refers to the chapter, the second to the section,
4943  and the third is the number of the results (Theorems, Corollaries, Propositions
4944 , Definitions and Remarks, etc.) in that section.
4945  There are also many (but not all) environments available unnumbered, which
4946  is occasionally needed.
4947  Unnumbered environments indicated by an asterisk at the end.
4948 \end_layout
4949
4950 \begin_layout Standard
4951
4952 Any AMS LyX file can be converted to either of the numbering schemes by
4953  simply changing the document class in the 
4954 \family sans
4955 \bar under
4956 D
4957 \bar default
4958 ocument\SpecialChar \menuseparator
4959
4960 \bar under
4961 S
4962 \bar default
4963 ettings
4964 \family default
4965  dialog.
4966  
4967 \end_layout
4968
4969 \begin_layout Subsection
4970
4971 What these layouts provide
4972 \end_layout
4973
4974 \begin_layout Standard
4975
4976 There is a long list of included environments provided by these layouts.
4977  Most mathematical papers or books will set as special statements most of
4978  these environments, in AMS-LaTeX there is an opportunity to define an unlimited
4979  variety of such declarations.
4980  However, the AMS recommends the environments that are available in LyX.
4981  The list of environments (not counting the standard environments such as
4982  
4983 \family sans
4984 sections, bibliography, title, author, date
4985 \family default
4986 ), is:
4987 \end_layout
4988
4989 \begin_layout Description
4990
4991 Theorem This is typically used for the statements of major results.
4992  The word 
4993 \begin_inset Quotes eld
4994 \end_inset
4995
4996
4997 \family sans
4998 Theorem
4999 \family default
5000
5001 \begin_inset Quotes erd
5002 \end_inset
5003
5004  appears in bold type, along with an automatically-determined number (an
5005  unnumbered version, 
5006 \family sans
5007 Theorem*
5008 \family default
5009 , is also available).
5010  The text is italicized.
5011 \end_layout
5012
5013 \begin_layout Description
5014
5015 Corollary This is used for statements which follow fairly directly from
5016  previous statements.
5017  Again, these can be major results.
5018  Unnumbered version 
5019 \family sans
5020 Corollary*
5021 \family default
5022  is available.
5023 \end_layout
5024
5025 \begin_layout Description
5026
5027 Lemma These are smaller results needed to prove other statements.
5028 \end_layout
5029
5030 \begin_layout Description
5031
5032 Proposition These are less major results which (hopefully) add to the general
5033  theory being discussed.
5034 \end_layout
5035
5036 \begin_layout Description
5037
5038 Conjecture These are statements provided without justification, which the
5039  author does not know how to prove, but which seem to be true (to the author,
5040  at least).
5041 \end_layout
5042
5043 \begin_layout Description
5044
5045 Criterion A required condition.
5046 \end_layout
5047
5048 \begin_layout Description
5049
5050 Algorithm A general procedure to be used.
5051 \end_layout
5052
5053 \begin_layout Description
5054
5055 Axiom This is a property or statement taken as true within the system being
5056  discussed.
5057 \end_layout
5058
5059 \begin_layout Description
5060
5061 Definition Guess what this is for.
5062  The font, both on-screen and in the output, is different for this environment
5063  than for the previous ones.
5064  The heading (
5065 \begin_inset Quotes eld
5066 \end_inset
5067
5068 definition
5069 \begin_inset Quotes erd
5070 \end_inset
5071
5072 ) is still set in boldface, along with the number, if any, but the rest
5073  is set upright.
5074 \end_layout
5075
5076 \begin_layout Description
5077
5078 Example Typeset similarly to Definition.
5079 \end_layout
5080
5081 \begin_layout Description
5082
5083 Condition
5084 \end_layout
5085
5086 \begin_layout Description
5087
5088 Problem
5089 \end_layout
5090
5091 \begin_layout Description
5092
5093 Exercise
5094 \end_layout
5095
5096 \begin_layout Description
5097
5098 Remark This environment is also a new type of theorem.
5099  This is set with the word Remark in italics, and the rest upright.
5100 \end_layout
5101
5102 \begin_layout Description
5103
5104 Note Set similarly to the Remark environment.
5105 \end_layout
5106
5107 \begin_layout Description
5108
5109 Notation
5110 \end_layout
5111
5112 \begin_layout Description
5113
5114 Claim
5115 \end_layout
5116
5117 \begin_layout Description
5118
5119 Summary
5120 \end_layout
5121
5122 \begin_layout Description
5123
5124 Acknowledgement
5125 \end_layout
5126
5127 \begin_layout Description
5128
5129 Case Generally, these are used to break up long arguments, using specific
5130  instances of some condition.
5131  The numbering scheme for cases is on its own, not together with other numbered
5132  statements.
5133  
5134 \end_layout
5135
5136 \begin_layout Description
5137
5138 Conclusion
5139 \end_layout
5140
5141 \begin_layout Description
5142
5143 Fact 
5144 \end_layout
5145
5146 \begin_layout Description
5147
5148 Proof The word 
5149 \begin_inset Quotes eld
5150 \end_inset
5151
5152
5153 \shape italic
5154 Proof
5155 \shape default
5156
5157 \begin_inset Quotes erd
5158 \end_inset
5159
5160  is set in italics, but the rest is set upright.
5161  At the end of this environment (other environments can be nested within
5162  this one, of course) a QED symbol (usually a square, but it can vary with
5163  different styles) is placed.
5164 \end_layout
5165
5166 \begin_layout Description
5167
5168 Address This should be the author's permanent address.
5169 \end_layout
5170
5171 \begin_layout Description
5172
5173 Current\InsetSpace ~
5174 Address This should be the author's temporary address at the time
5175  of submission, if different from the Address.
5176 \end_layout
5177
5178 \begin_layout Description
5179
5180 Email Author's e-mail address
5181 \end_layout
5182
5183 \begin_layout Description
5184
5185 URL Author's Web address, if desired.
5186 \end_layout
5187
5188 \begin_layout Description
5189
5190 Keywords Key words or phrases used to identify specific topics discussed
5191  in the paper.
5192 \end_layout
5193
5194 \begin_layout Description
5195
5196 Subjectclass These refer to the AMS Subject Classifications, published and
5197  described in 
5198 \emph on
5199 Mathematical Reviews
5200 \emph default
5201 .
5202  These are also available online at the AMS cites listed above.
5203 \end_layout
5204
5205 \begin_layout Description
5206
5207 Thanks
5208 \end_layout
5209
5210 \begin_layout Description
5211
5212 Dedicatory
5213 \end_layout
5214
5215 \begin_layout Description
5216
5217 Translator
5218 \end_layout
5219
5220 \begin_layout Standard
5221
5222 In addition, these environments automatically provide the AMS LaTeX and
5223  AMS fonts packages.
5224  They need to be available on your system in order to use these environments.
5225 \end_layout
5226
5227 \begin_layout Section
5228
5229 Dinbrief
5230 \end_layout
5231
5232 \begin_layout Standard
5233
5234 The document class 
5235 \family sans
5236 dinbrief
5237 \family default
5238  can be used to type letters according to German conventions.
5239  A template file is included in 
5240 \family typewriter
5241 .../lyx/share/templates
5242 \family default
5243  for you to use as a starting point.
5244 \end_layout
5245
5246 \begin_layout Section
5247
5248 Paper
5249 \end_layout
5250
5251 \begin_layout Standard
5252
5253 The document class 
5254 \family sans
5255 paper
5256 \family default
5257  provides an alternative to the standard 
5258 \family sans
5259 article
5260 \family default
5261  class.
5262  It provides similar functionality, but you might prefer this layout with
5263  sans serif sections, headings, and more.
5264 \end_layout
5265
5266 \begin_layout Section
5267
5268 A&A Paper
5269 \end_layout
5270
5271 \begin_layout Standard
5272
5273 by 
5274 \noun on
5275 Peter Sütterlin
5276 \end_layout
5277
5278 \begin_layout Subsection
5279
5280 Introduction
5281 \end_layout
5282
5283 \begin_layout Standard
5284
5285 This section describes how LyX can be used to write articles for submission
5286  to the scientific journal 
5287 \emph on
5288 Astronomy and Astrophysics
5289 \emph default
5290  (
5291 \begin_inset LatexCommand \url[www.edpsciences.fr/aa/]{http://www.edpsciences.fr/aa/}
5292
5293 \end_inset
5294
5295 )
5296 \emph on
5297  
5298 \emph default
5299 using
5300 \emph on
5301  
5302 \emph default
5303 Version 5.01 of the document class 
5304 \family typewriter
5305 aa.cls
5306 \family default
5307 .
5308  This package can be downloaded from the ftp site
5309 \end_layout
5310
5311
5312 \begin_layout Standard
5313
5314
5315 \begin_inset VSpace medskip
5316 \end_inset
5317
5318
5319 \end_layout
5320
5321 \begin_layout Standard
5322 \align center
5323
5324 \begin_inset LatexCommand \url{ftp://ftp.edpsciences.org/pub/aa/readme.html}
5325
5326 \end_inset
5327
5328
5329 \end_layout
5330
5331 \begin_layout Standard
5332
5333
5334 \begin_inset VSpace medskip
5335 \end_inset
5336
5337
5338 \end_layout
5339
5340
5341 \begin_layout Standard
5342
5343 A manual comes together with that package, and this text is not meant to
5344  replace the original manual but merely a short guide how to realize the
5345  correct form of your paper.
5346  
5347 \end_layout
5348
5349 \begin_layout Standard
5350
5351 Please note that the publisher of the journal was changed from Springer
5352  to EDP Sciences starting January 1, 2001.
5353  That change implicated also some slight changes of the style files, namely
5354  the removal of the thesaurus command.
5355  The LyX class aa supports the newest version of these style files, V 5.01.
5356  If you have an older version installed, please upgrade.
5357  For compatibility, the old (version 4) layout has been kept as 
5358 \family sans
5359 article (A&A V4)
5360 \family default
5361 .
5362  Please refer to the comments in 
5363 \family typewriter
5364 LyXDir/layouts/aapaper.layout
5365 \family default
5366 .
5367 \end_layout
5368
5369 \begin_layout Subsection
5370
5371 Getting started
5372 \end_layout
5373
5374 \begin_layout Standard
5375
5376 It is recommended you start from the example template distributed with LyX.
5377  If you are not using a template, note the following settings:
5378 \end_layout
5379
5380 \begin_layout Itemize
5381
5382 Select 
5383 \family sans
5384 article (A&A)
5385 \family default
5386  in the 
5387 \family sans
5388 \bar under
5389 D
5390 \bar default
5391 ocument\SpecialChar \menuseparator
5392
5393 \bar under
5394 S
5395 \bar default
5396 ettings
5397 \family default
5398  dialog (OK, that one was obvious).
5399 \end_layout
5400
5401 \begin_layout Itemize
5402
5403 Don't change the option 
5404 \family sans
5405 Page\InsetSpace ~
5406 style
5407 \family default
5408 : Leave it set to 
5409 \family sans
5410 default
5411 \family default
5412 .
5413  The whole layout is done by the macros, you shouldn't change anything.
5414 \end_layout
5415
5416 \begin_layout Subsection
5417
5418 The header block
5419 \end_layout
5420
5421 \begin_layout Standard
5422
5423 First thing to enter is the header information.
5424  It consists of seven entries, of which some are optional.
5425  They are
5426 \end_layout
5427
5428 \begin_layout Itemize
5429
5430
5431 \family sans
5432 Title
5433 \family default
5434 : [required] 
5435 \end_layout
5436
5437 \begin_layout Itemize
5438
5439
5440 \family sans
5441 Subtitle
5442 \family default
5443 : [optional] 
5444 \end_layout
5445
5446 \begin_layout Itemize
5447
5448
5449 \family sans
5450 Author
5451 \family default
5452 : [required]
5453 \end_layout
5454
5455 \begin_layout Itemize
5456
5457
5458 \family sans
5459 Address
5460 \family default
5461 : [required]
5462 \end_layout
5463
5464 \begin_layout Itemize
5465
5466
5467 \family sans
5468 Offprints
5469 \family default
5470 : [optional] if more than one author: whom to contact for offprint requests.
5471 \end_layout
5472
5473 \begin_layout Itemize
5474
5475
5476 \family sans
5477 Mail
5478 \family default
5479 : [optional] mail address for contacts.
5480 \end_layout
5481
5482 \begin_layout Itemize
5483
5484
5485 \family sans
5486 Date
5487 \family default
5488 : [required].
5489  Suggested format is 
5490 \family typewriter
5491 Received: <date>; Accepted <date> 
5492 \end_layout
5493
5494 \begin_layout Standard
5495
5496 There is no need to issue the 
5497 \family typewriter
5498
5499 \backslash
5500 maketitle
5501 \family default
5502  command, this is done automatically by LyX when the header is finished.
5503  Although the order of the single header entries doesn't matter it is advised
5504  to keep the above sequence, just to get the best optics and meets the layout
5505  of the real document.
5506 \end_layout
5507
5508 \begin_layout Standard
5509
5510 If you want to place footnotes in the header block, e.g.
5511 \begin_inset ERT
5512 status collapsed
5513
5514 \begin_layout Standard
5515
5516 \backslash
5517  
5518 \end_layout
5519
5520 \end_inset
5521
5522 to state your present address, just use the standard footnote via 
5523 \family sans
5524 \bar under
5525 I
5526 \bar default
5527 nsert\SpecialChar \menuseparator
5528
5529 \bar under
5530 F
5531 \bar default
5532 ootnote.
5533  
5534 \family default
5535 LyX will automagically use the term 
5536 \family typewriter
5537
5538 \backslash
5539 thanks{}
5540 \family default
5541  in that case.
5542 \end_layout
5543
5544 \begin_layout Standard
5545
5546 In addition to these topics, the macros use three additional LaTeX commands
5547  that have no counterpart in LyX:
5548 \end_layout
5549
5550 \begin_layout Itemize
5551
5552
5553 \family typewriter
5554
5555 \backslash
5556 and
5557 \family default
5558  to separate different names for more than one author and institute, respectivel
5559 y.
5560 \end_layout
5561
5562 \begin_layout Itemize
5563
5564
5565 \family typewriter
5566
5567 \backslash
5568 inst{<nr>}
5569 \family default
5570 to mark corresponding author/institute pairs.
5571  The institutes are numbered sequentially as they appear in the 
5572 \family sans
5573 Address
5574 \family default
5575  field, so you have to put a marker to each author.
5576 \end_layout
5577
5578 \begin_layout Itemize
5579
5580
5581 \family typewriter
5582
5583 \backslash
5584 email{address}
5585 \family default
5586  to supply an email address for fast contact.
5587 \end_layout
5588
5589 \begin_layout Standard
5590
5591 In all cases, the appropriate command has to be entered in LyX an marked
5592  as LaTeX code.
5593  See the examples.
5594  
5595 \end_layout
5596
5597 \begin_layout Subsection
5598
5599 The abstract
5600 \end_layout
5601
5602 \begin_layout Standard
5603
5604 The abstract should immediately follow the header block.
5605  With version 5 the abstract environment was changed to a command, and there
5606  is now a resctriction to only one paragraph.
5607  In addition, it should contain an entry with the keywords.
5608  This is not yet implemented for LyX, therefore you have to enter the LaTeX
5609  command 
5610 \family typewriter
5611
5612 \backslash
5613 keywords{}
5614 \family default
5615  by hand and mark it as LaTeX code.
5616  Refer to the example paper.
5617 \end_layout
5618
5619 \begin_layout Subsection
5620
5621 Supported environments
5622 \end_layout
5623
5624 \begin_layout Standard
5625
5626 The A&A paper layout supports the following environments for structuring
5627  your text:
5628 \end_layout
5629
5630 \begin_layout Itemize
5631
5632
5633 \family sans
5634 Standard
5635 \end_layout
5636
5637 \begin_layout Itemize
5638
5639
5640 \family sans
5641 Section
5642 \end_layout
5643
5644 \begin_layout Itemize
5645
5646
5647 \family sans
5648 Subsection
5649 \end_layout
5650
5651 \begin_layout Itemize
5652
5653
5654 \family sans
5655 Subsubsection
5656 \end_layout
5657
5658 \begin_layout Itemize
5659
5660
5661 \family sans
5662 Itemize
5663 \end_layout
5664
5665 \begin_layout Itemize
5666
5667
5668 \family sans
5669 Enumerate
5670 \end_layout
5671
5672 \begin_layout Itemize
5673
5674
5675 \family sans
5676 Description
5677 \end_layout
5678
5679 \begin_layout Itemize
5680
5681
5682 \family sans
5683 Caption
5684 \end_layout
5685
5686 \begin_layout Itemize
5687
5688
5689 \family sans
5690 Abstract
5691 \end_layout
5692
5693 \begin_layout Itemize
5694
5695
5696 \family sans
5697 Acknowledgment
5698 \end_layout
5699
5700 \begin_layout Itemize
5701
5702
5703 \family sans
5704 Bibliography
5705 \end_layout
5706
5707 \begin_layout Itemize
5708
5709
5710 \family sans
5711 LaTeX
5712 \end_layout
5713
5714 \begin_layout Subsection
5715
5716 Commands not supported by LyX
5717 \end_layout
5718
5719 \begin_layout Standard
5720
5721 Some commands are not yet supported by the 
5722 \family sans
5723 paper (A&A)
5724 \family default
5725  layout for LyX.
5726  Some have already been mentioned.
5727  For the sake of completeness, they are listed all together here:
5728 \end_layout
5729
5730 \begin_layout Itemize
5731
5732
5733 \family typewriter
5734
5735 \backslash
5736 and
5737 \end_layout
5738
5739 \begin_layout Itemize
5740
5741
5742 \family typewriter
5743
5744 \backslash
5745 email
5746 \end_layout
5747
5748 \begin_layout Itemize
5749
5750
5751 \family typewriter
5752
5753 \backslash
5754 appendix
5755 \end_layout
5756
5757 \begin_layout Itemize
5758
5759
5760 \family typewriter
5761
5762 \backslash
5763 authorrunning
5764 \end_layout
5765
5766 \begin_layout Itemize
5767
5768
5769 \family typewriter
5770
5771 \backslash
5772 inst{}
5773 \end_layout
5774
5775 \begin_layout Itemize
5776
5777
5778 \family typewriter
5779
5780 \backslash
5781 keywords{}
5782 \end_layout
5783
5784 \begin_layout Itemize
5785
5786
5787 \family typewriter
5788
5789 \backslash
5790 object{}
5791 \end_layout
5792
5793 \begin_layout Itemize
5794
5795
5796 \family typewriter
5797
5798 \backslash
5799 titlerunning{}
5800 \end_layout
5801
5802 \begin_layout Standard
5803
5804 If you want to use any of these commands, you have to enter them yourself.
5805  
5806 \series bold
5807 Do not forget to mark them as LaTeX code!
5808 \end_layout
5809
5810 \begin_layout Subsection
5811
5812 Figure and Table Floats
5813 \end_layout
5814
5815 \begin_layout Standard
5816
5817 LyX provides support for the necessary float environments 
5818 \family sans
5819 figure, figure*, table 
5820 \family default
5821 and 
5822 \family sans
5823 table*
5824 \family default
5825 , therefore we won't tell much about it here.
5826  Refer to the 
5827 \emph on
5828 User's\InsetSpace ~
5829 Guide
5830 \emph default
5831 .
5832  Just remember that tables should be left-aligned.
5833  For that, select the table and change the alignment in 
5834 \family sans
5835 \bar under
5836 E
5837 \bar default
5838 dit\SpecialChar \menuseparator
5839
5840 \bar under
5841 P
5842 \bar default
5843 aragraph\InsetSpace ~
5844 Settings.
5845 \end_layout
5846
5847 \begin_layout Standard
5848
5849 There is
5850 \family sans
5851  
5852 \family default
5853 only one special thing: the figures with caption besides the figure.
5854  To create such a figure, you have to do the following:
5855 \end_layout
5856
5857 \begin_layout Enumerate
5858
5859 Create a wide figure float: 
5860 \family sans
5861 \bar under
5862 I
5863 \bar default
5864 nsert\SpecialChar \menuseparator
5865 Flo
5866 \bar under
5867 a
5868 \bar default
5869 t\SpecialChar \menuseparator
5870 Figure
5871 \family default
5872 , then right click in the figure and select
5873 \family sans
5874  
5875 \bar under
5876 S
5877 \bar default
5878 pan\InsetSpace ~
5879 columns
5880 \family default
5881 .
5882 \end_layout
5883
5884 \begin_layout Enumerate
5885
5886 Enter your caption text.
5887 \end_layout
5888
5889 \begin_layout Enumerate
5890
5891 Press 
5892 \family sans
5893 Return
5894 \family default
5895  to move the cursor above the caption.
5896 \end_layout
5897
5898 \begin_layout Enumerate
5899
5900 Insert your figure
5901 \end_layout
5902
5903 \begin_layout Enumerate
5904
5905 Position the cursor behind the figure and insert a horizontal fill: 
5906 \family sans
5907 \bar under
5908 I
5909 \bar default
5910 nsert\SpecialChar \menuseparator
5911
5912 \bar under
5913 S
5914 \bar default
5915 pecial\InsetSpace ~
5916 Character
5917 \bar under
5918 \SpecialChar \menuseparator
5919 H
5920 \bar default
5921 orizontal\InsetSpace ~
5922 Fill
5923 \family default
5924 .
5925 \end_layout
5926
5927 \begin_layout Enumerate
5928
5929 Switch to LaTeX mode: 
5930 \family sans
5931 M-c\InsetSpace ~
5932 t
5933 \family default
5934 .
5935 \end_layout
5936
5937 \begin_layout Enumerate
5938
5939 Enter 
5940 \family typewriter
5941
5942 \backslash
5943 parbox[b]{55mm}{
5944 \family default
5945 .
5946  
5947 \series bold
5948 Do not close the brace!
5949 \end_layout
5950
5951 \begin_layout Enumerate
5952
5953 Position the cursor behind the caption text, switch to LaTeX mode and insert
5954  the closing brace: 
5955 \family sans
5956 M-c\InsetSpace ~
5957
5958 \family typewriter
5959 }
5960 \family default
5961 .
5962 \end_layout
5963
5964 \begin_layout Standard
5965
5966 Also, refer to the figures in the example paper.
5967 \end_layout
5968
5969 \begin_layout Subsection
5970
5971 Referee layout
5972 \end_layout
5973
5974 \begin_layout Standard
5975
5976 For submission, the paper has to be formated in a special double-spacing
5977  layout.
5978  For this purpose, you have to give the option 
5979 \family typewriter
5980 referee
5981 \family default
5982  to the documentclass.
5983  This must be done using the extra class options field in the 
5984 \family sans
5985 \bar under
5986 D
5987 \bar default
5988 ocument\SpecialChar \menuseparator
5989
5990 \bar under
5991 S
5992 \bar default
5993 ettings
5994 \family default
5995  dialog.
5996  Just enter the string 
5997 \family typewriter
5998 referee
5999 \family default
6000  there.
6001 \end_layout
6002
6003 \begin_layout Subsection
6004
6005 The example paper
6006 \end_layout
6007
6008 \begin_layout Standard
6009
6010 The 
6011 \family sans
6012 Examples
6013 \family default
6014  directory contains an example paper written with LyX.
6015  It is the example paper from the original macro package, translated to
6016  LyX.
6017  Use it for inspiration, and compare the original LaTeX code with LyX way
6018  of writing.
6019 \end_layout
6020
6021 \begin_layout Section
6022
6023 AASTeX
6024 \end_layout
6025
6026 \begin_layout Standard
6027
6028 by 
6029 \noun on
6030 Mike Ressler
6031 \end_layout
6032
6033 \begin_layout Subsection
6034
6035 Introduction
6036 \end_layout
6037
6038 \begin_layout Standard
6039
6040 AASTeX is a set of macros produced by the American Astronomical Society
6041  to facilitate electronic manuscript submission to the three journals they
6042  publish: the Astrophysical Journal (including the Letters and Supplement),
6043  the Astronomical Journal, and the Publications of the Astronomical Society
6044  of the Pacific.
6045  LyX has proven to be an excellent tool for generating these documents,
6046  especially given its equation, citation, and figure handling capabilities.
6047  LyX requires version 5.0 (or higher) of these macros; preferably 5.2, which
6048  is the version described here, or higher.
6049  Versions prior to 5.0 are intended for use with LaTeX2.09 and are fundamentally
6050  incompatible with LyX.
6051  The AASTeX package may be downloaded from the AASTeX Web site
6052 \end_layout
6053
6054
6055 \begin_layout Standard
6056
6057
6058 \begin_inset VSpace medskip
6059 \end_inset
6060
6061
6062 \end_layout
6063
6064 \begin_layout Standard
6065 \align center
6066
6067 \begin_inset LatexCommand \url{http://www.journals.uchicago.edu/AAS/AASTeX}
6068
6069 \end_inset
6070
6071
6072 \end_layout
6073
6074 \begin_layout Standard
6075
6076
6077 \begin_inset VSpace medskip
6078 \end_inset
6079
6080
6081 \end_layout
6082
6083
6084 \begin_layout Standard
6085
6086 A complete user guide is contained in that package and you should familiarize
6087  yourself with it thoroughly before embarking on writing a paper in LyX.
6088  LyX will not reduce the need to figure out all the AASTeX commands, it
6089  will only reduce the drudgery of typing everything in.
6090  It is your responsibility to ensure that the final exported LaTeX document
6091  conforms completely to the requirements of the journal to which you are
6092  submitting your paper.
6093 \end_layout
6094
6095 \begin_layout Subsection
6096
6097 Starting a New Paper
6098 \end_layout
6099
6100 \begin_layout Standard
6101
6102 I strongly suggest that you start with the AASTeX template file.
6103  Click on 
6104 \family sans
6105 \bar under
6106 F
6107 \bar default
6108 ile\SpecialChar \menuseparator
6109 New from 
6110 \bar under
6111 T
6112 \bar default
6113 emplate
6114 \family default
6115 , enter the new file name, then choose the 
6116 \family typewriter
6117 aastex.lyx
6118 \family default
6119  template.
6120  This will show the most common fields found in a manuscript.
6121  Simply overwrite the existing text (including the brackets, 
6122 \family typewriter
6123 <>
6124 \family default
6125 ) with the correct information.
6126  Many of the AASTeX commands and environments can be implemented directly
6127  in LyX, but some cannot: most noticeably 
6128 \family typewriter
6129
6130 \backslash
6131 altaffilmark
6132 \family default
6133  and 
6134 \family typewriter
6135
6136 \backslash
6137 altaffiltext
6138 \family default
6139 , which should stick out like a sore thumb if you actually just opened the
6140  template file.
6141  For commands such as these, the LaTeX code must be entered directly and
6142  marked as such.
6143  Such commands are referred to as ERT, or Evil Red Text.
6144  I tried to minimize the amount of ERT needed in an AASTeX document, but
6145  there is still a bit more required than any of us would like.
6146 \end_layout
6147
6148 \begin_layout Subsection
6149
6150 Finishing Your Paper
6151 \end_layout
6152
6153 \begin_layout Standard
6154
6155 When the paper is finished to your satisfaction and previews/prints correctly,
6156  there are a few 
6157 \begin_inset Quotes eld
6158 \end_inset
6159
6160 postprocessing
6161 \begin_inset Quotes erd
6162 \end_inset
6163
6164  actions which need to be done before you submit it to the journals.
6165  
6166 \end_layout
6167
6168 \begin_layout Enumerate
6169
6170 Export your paper as a LaTeX file (
6171 \family sans
6172 \bar under
6173 F
6174 \bar default
6175 ile\SpecialChar \menuseparator
6176
6177 \bar under
6178 E
6179 \bar default
6180 xport\SpecialChar \menuseparator
6181
6182 \bar under
6183 L
6184 \bar default
6185 aTeX
6186 \family default
6187 ).
6188  
6189 \end_layout
6190
6191 \begin_layout Enumerate
6192
6193 Edit the resulting 
6194 \family typewriter
6195 .tex
6196 \family default
6197  file with your favorite text editor
6198 \end_layout
6199
6200 \begin_deeper
6201 \begin_layout Enumerate
6202
6203 remove the comment lines before the 
6204 \family typewriter
6205
6206 \backslash
6207 documentclass
6208 \family default
6209  command
6210 \end_layout
6211
6212 \begin_layout Enumerate
6213
6214 remove the 
6215 \family typewriter
6216
6217 \backslash
6218 usepackage...{fontenc}
6219 \family default
6220  line if it appears (usually just after 
6221 \family typewriter
6222
6223 \backslash
6224 documentclass
6225 \family default
6226 }; also remove the 
6227 \family typewriter
6228
6229 \backslash
6230 secnumdepth
6231 \family default
6232  line if it appears.
6233 \end_layout
6234
6235 \begin_layout Enumerate
6236
6237 remove everything between (and including) the 
6238 \family typewriter
6239
6240 \backslash
6241 makeatletter
6242 \family default
6243  and 
6244 \family typewriter
6245
6246 \backslash
6247 makeatother
6248 \family default
6249  commands, except for any commands you specifically put into the LaTeX preamble
6250  (which should appear immediately after the 
6251 \begin_inset Quotes eld
6252 \end_inset
6253
6254 User specified LaTeX commands
6255 \begin_inset Quotes erd
6256 \end_inset
6257
6258  comment in the 
6259 \family typewriter
6260 .tex
6261 \family default
6262  file).
6263 \end_layout
6264 \end_deeper
6265 \begin_layout Enumerate
6266
6267 Run the resulting file through LaTeX to make sure it still processes correctly.
6268 \end_layout
6269
6270 \begin_layout Enumerate
6271
6272 Reread the journal requirements to make sure your filenames and formats
6273  are correct.
6274 \end_layout
6275
6276 \begin_layout Enumerate
6277
6278 Submit it.
6279 \end_layout
6280
6281 \begin_layout Subsection
6282
6283 Comments On Specific Commands
6284 \end_layout
6285
6286 \begin_layout Standard
6287
6288 I will not describe the detailed usage of the individual AASTeX commands:
6289  the AASTeX User Guide (
6290 \family typewriter
6291 aasguide.tex
6292 \family default
6293 ) gives a good description of each.
6294  Thus it's probably easiest for me to go down the list as found in the guide
6295  and offer comments where necessary.
6296  So let's begin \SpecialChar \ldots{}
6297
6298 \end_layout
6299
6300 \begin_layout Subsubsection
6301
6302 Things that work as expected
6303 \end_layout
6304
6305 \begin_layout Standard
6306
6307
6308 \begin_inset ERT
6309 status inlined
6310
6311 \begin_layout Standard
6312
6313 \backslash
6314 begin{sloppypar}
6315 \end_layout
6316
6317 \end_inset
6318
6319
6320 \end_layout
6321
6322 \begin_layout Standard
6323
6324 Because they work as you might expect, I simply list them and the section
6325  they are found in: 
6326 \family typewriter
6327
6328 \backslash
6329 documentclass
6330 \family default
6331  (2.1.1), 
6332 \family typewriter
6333
6334 \backslash
6335 begin{document}
6336 \family default
6337  (2.2), 
6338 \family typewriter
6339
6340 \backslash
6341 title
6342 \family default
6343  (2.3), 
6344 \family typewriter
6345
6346 \backslash
6347 author
6348 \family default
6349  (2.3), 
6350 \family typewriter
6351
6352 \backslash
6353 affil
6354 \family default
6355  (2.3), 
6356 \family typewriter
6357
6358 \backslash
6359 abstract
6360 \family default
6361  (2.4), 
6362 \family typewriter
6363
6364 \backslash
6365 keywords
6366 \family default
6367  (2.5), 
6368 \family typewriter
6369
6370 \backslash
6371 section
6372 \family default
6373  (2.7), 
6374 \family typewriter
6375
6376 \backslash
6377 subsection
6378 \family default
6379  (2.7), 
6380 \family typewriter
6381
6382 \backslash
6383 subsubsection
6384 \family default
6385  (2.7), 
6386 \family typewriter
6387
6388 \backslash
6389 paragraph
6390 \family default
6391  (2.7),
6392 \family typewriter
6393  
6394 \backslash
6395 facility
6396 \family default
6397  (2.10), 
6398 \family typewriter
6399
6400 \backslash
6401 begin{displaymath}
6402 \family default
6403  (2.12), 
6404 \family typewriter
6405
6406 \backslash
6407 begin{equation}
6408 \family default
6409  (2.12), 
6410 \family typewriter
6411
6412 \backslash
6413 begin{eqnarray}
6414 \family default
6415  (2.12), 
6416 \family typewriter
6417
6418 \backslash
6419 begin{mathletters}
6420 \family default
6421  (2.12), 
6422 \family typewriter
6423
6424 \backslash
6425 begin{thebibliography}
6426 \family default
6427  (2.13.1), 
6428 \family typewriter
6429
6430 \backslash
6431 bibitem
6432 \family default
6433  (2.13.2), all the cite commands and their variations (2.13.2), the generic
6434  graphicx figure commands (2.14.1),
6435 \family typewriter
6436  
6437 \backslash
6438 begin{table}
6439 \family default
6440  (2.15.4), 
6441 \family typewriter
6442
6443 \backslash
6444 begin{tabular}
6445 \family default
6446  (2.15.4), 
6447 \family typewriter
6448
6449 \backslash
6450 caption
6451 \family default
6452  (2.15.4), 
6453 \family typewriter
6454
6455 \backslash
6456 label
6457 \family default
6458  (2.15.4, amongst other places), 
6459 \family typewriter
6460
6461 \backslash
6462 tablerefs
6463 \family default
6464  (2.15.5), 
6465 \family typewriter
6466
6467 \backslash
6468 tablecomments
6469 \family default
6470  (2.15.5), 
6471 \family typewriter
6472
6473 \backslash
6474 url
6475 \family default
6476  (2.17.4), 
6477 \family typewriter
6478
6479 \backslash
6480 end{document}
6481 \family default
6482  (2.18).
6483 \end_layout
6484
6485 \begin_layout Standard
6486
6487 The following style options also work correctly: 
6488 \family typewriter
6489 longabstract
6490 \family default
6491  (2.4), 
6492 \family typewriter
6493 preprint
6494 \family default
6495  (3.2.1), 
6496 \family typewriter
6497 preprint2
6498 \family default
6499  (3.2.2), 
6500 \family typewriter
6501 eqsecnum
6502 \family default
6503  (3.3), 
6504 \family typewriter
6505 flushrt
6506 \family default
6507  (3.4).
6508  Simply put them in the 
6509 \family sans
6510 Options
6511 \family default
6512  box in 
6513 \family sans
6514 Layout\SpecialChar \menuseparator
6515 Document
6516 \family default
6517 .
6518 \end_layout
6519
6520 \begin_layout Standard
6521
6522
6523 \begin_inset ERT
6524 status inlined
6525
6526 \begin_layout Standard
6527
6528 \backslash
6529 end{sloppypar}
6530 \end_layout
6531
6532 \end_inset
6533
6534
6535 \end_layout
6536
6537 \begin_layout Subsubsection
6538
6539 Things that work, but require more comment
6540 \end_layout
6541
6542 \begin_layout Standard
6543
6544 The following items work, but require a little more discussion:
6545 \end_layout
6546
6547 \begin_layout Itemize
6548
6549 These items are reserved for use by the journal editors, but you can put
6550  them into the LaTeX preamble if you feel compelled to do so: 
6551 \family typewriter
6552
6553 \backslash
6554 received
6555 \family default
6556
6557 \family typewriter
6558
6559 \backslash
6560 revised
6561 \family default
6562
6563 \family typewriter
6564
6565 \backslash
6566 accepted
6567 \family default
6568
6569 \family typewriter
6570
6571 \backslash
6572 ccc
6573 \family default
6574
6575 \family typewriter
6576
6577 \backslash
6578 cpright
6579 \family default
6580  (all from 2.1.3)
6581 \end_layout
6582
6583 \begin_layout Itemize
6584
6585 These items may be placed in the LaTeX preamble, and are included as blanks
6586  in the template file: 
6587 \family typewriter
6588
6589 \backslash
6590 slugcomment
6591 \family default
6592  (2.1.4), 
6593 \family typewriter
6594
6595 \backslash
6596 shorttitle
6597 \family default
6598  (2.1.5), 
6599 \family typewriter
6600
6601 \backslash
6602 shortauthors
6603 \family default
6604  (2.1.5)
6605 \end_layout
6606
6607 \begin_layout Itemize
6608
6609
6610 \family typewriter
6611
6612 \backslash
6613 email
6614 \family default
6615  (2.3) -- can only be used 
6616 \begin_inset Quotes eld
6617 \end_inset
6618
6619 standalone
6620 \begin_inset Quotes erd
6621 \end_inset
6622
6623 , not in the middle of a paragraph.
6624  Use ERT if you need to embed it.
6625 \end_layout
6626
6627 \begin_layout Itemize
6628
6629
6630 \family typewriter
6631
6632 \backslash
6633 and
6634 \family default
6635  (2.3) -- will have extra {} after it.
6636  This should not cause an error.
6637 \end_layout
6638
6639 \begin_layout Itemize
6640
6641
6642 \family typewriter
6643
6644 \backslash
6645 notetoeditor
6646 \family default
6647  (2.6) -- can only be used 
6648 \begin_inset Quotes eld
6649 \end_inset
6650
6651 standalone
6652 \begin_inset Quotes erd
6653 \end_inset
6654
6655 , not in the middle of a paragraph.
6656  Use ERT if you need to embed it.
6657 \end_layout
6658
6659 \begin_layout Itemize
6660
6661
6662 \family typewriter
6663
6664 \backslash
6665 placetable
6666 \family default
6667  (2.8) -- can't insert a cross-reference tag, you must type the tag name
6668  by hand
6669 \end_layout
6670
6671 \begin_layout Itemize
6672
6673
6674 \family typewriter
6675
6676 \backslash
6677 placefigure
6678 \family default
6679  (2.8) -- same as for 
6680 \family typewriter
6681
6682 \backslash
6683 placetable
6684 \end_layout
6685
6686 \begin_layout Itemize
6687
6688
6689 \family typewriter
6690
6691 \backslash
6692 acknowledgements
6693 \family default
6694  (2.9) -- will have extra {} after it.
6695  This should not cause an error.
6696 \end_layout
6697
6698 \begin_layout Itemize
6699
6700
6701 \family typewriter
6702
6703 \backslash
6704 appendix
6705 \family default
6706  (2.11) -- will have extra {} after it.
6707  This should not cause an error.
6708 \end_layout
6709
6710 \begin_layout Itemize
6711
6712
6713 \family typewriter
6714
6715 \backslash
6716 figcaption
6717 \family default
6718  (2.14.2) -- you can insert an optional filename argument by placing the cursor
6719  at the beginning of the text and selecting 
6720 \family sans
6721 Insert\SpecialChar \menuseparator
6722 Short Title
6723 \family default
6724 .
6725  
6726 \begin_inset Quotes eld
6727 \end_inset
6728
6729 Short Title
6730 \begin_inset Quotes erd
6731 \end_inset
6732
6733  inserts an optional argument of the type needed by 
6734 \family typewriter
6735
6736 \backslash
6737 figcaption
6738 \family default
6739 .
6740  Hopefully it will be renamed someday.
6741 \end_layout
6742
6743 \begin_layout Itemize
6744
6745
6746 \family typewriter
6747
6748 \backslash
6749 objectname
6750 \family default
6751  (2.17.1) -- same as 
6752 \family typewriter
6753
6754 \backslash
6755 figcaption
6756 \family default
6757  for the catalog ID optional parameter
6758 \end_layout
6759
6760 \begin_layout Itemize
6761
6762
6763 \family typewriter
6764
6765 \backslash
6766 dataset
6767 \family default
6768  (2.17.1) -- same as 
6769 \family typewriter
6770
6771 \backslash
6772 figcaption
6773 \family default
6774  for the catalog ID optional parameter
6775 \end_layout
6776
6777 \begin_layout Subsubsection
6778
6779 Things not implemented, use ERT
6780 \end_layout
6781
6782 \begin_layout Standard
6783
6784
6785 \begin_inset ERT
6786 status inlined
6787
6788 \begin_layout Standard
6789
6790 \backslash
6791 begin{sloppypar}
6792 \end_layout
6793
6794 \end_inset
6795
6796
6797 \end_layout
6798
6799 \begin_layout Standard
6800
6801
6802 \family typewriter
6803
6804 \backslash
6805 altaffilmark
6806 \family default
6807  (2.3), 
6808 \family typewriter
6809
6810 \backslash
6811 altaffiltext
6812 \family default
6813  (2.3), 
6814 \family typewriter
6815
6816 \backslash
6817 eqnum
6818 \family default
6819  (2.12), 
6820 \family typewriter
6821
6822 \backslash
6823 setcounter{equation}
6824 \family default
6825  (2.12), Journal name abbreviations (2.13.4), 
6826 \family typewriter
6827
6828 \backslash
6829 figurenum
6830 \family default
6831  (2.14.1), 
6832 \family typewriter
6833
6834 \backslash
6835 epsscale
6836 \family default
6837  (2.14.1), 
6838 \family typewriter
6839
6840 \backslash
6841 plotone
6842 \family default
6843  (2.14.1), 
6844 \family typewriter
6845
6846 \backslash
6847 plottwo
6848 \family default
6849  (2.14.1), 
6850 \family typewriter
6851
6852 \backslash
6853 tablenum
6854 \family default
6855  (2.15.4), 
6856 \family typewriter
6857
6858 \backslash
6859 tableline
6860 \family default
6861  (2.15.4, insert it as the first element in the lefthand cell after where
6862  you want it.
6863  Don't use any of LyX's rules in the table), 
6864 \family typewriter
6865
6866 \backslash
6867 tablenotemark
6868 \family default
6869  (2.15.5), 
6870 \family typewriter
6871
6872 \backslash
6873 tablenotetext
6874 \family default
6875  (2.15.5), much of Misc (2.17, except 
6876 \family typewriter
6877
6878 \backslash
6879 objectname
6880 \family default
6881 ,
6882 \family typewriter
6883  
6884 \backslash
6885 dataset
6886 \family default
6887 ,
6888 \family typewriter
6889  
6890 \backslash
6891 url
6892 \family default
6893 , and 
6894 \family typewriter
6895
6896 \backslash
6897 email
6898 \family default
6899 ; see above), 
6900 \family typewriter
6901
6902 \backslash
6903 singlespace
6904 \family default
6905  (3.1), 
6906 \family typewriter
6907
6908 \backslash
6909 doublespace
6910 \family default
6911  (3.1), 
6912 \family typewriter
6913
6914 \backslash
6915 onecolumn
6916 \family default
6917  (3.2), 
6918 \family typewriter
6919
6920 \backslash
6921 twocolumn
6922 \family default
6923  (3.2)
6924 \end_layout
6925
6926 \begin_layout Standard
6927
6928
6929 \begin_inset ERT
6930 status inlined
6931
6932 \begin_layout Standard
6933
6934 \backslash
6935 end{sloppypar}
6936 \end_layout
6937
6938 \end_inset
6939
6940
6941 \end_layout
6942
6943 \begin_layout Subsubsection
6944
6945 Things that cannot be implemented
6946 \end_layout
6947
6948 \begin_layout Standard
6949
6950 \SpecialChar \ldots{}
6951  at least in any meaningful sort of way, so I suggest ignoring them.
6952  They are the references environment (2.13.3), and the deluxetable environment
6953  (2.15).
6954  If you really, really need to use deluxetable, I suggest editing it in
6955  a separate file with a text editor, then using 
6956 \family sans
6957 \bar under
6958 I
6959 \bar default
6960 nsert\SpecialChar \menuseparator
6961 Chil
6962 \bar under
6963 d
6964 \bar default
6965 \InsetSpace ~
6966 Document
6967 \family default
6968  to include it in your LyX document.
6969  See the 
6970 \family typewriter
6971 aas_sample.lyx
6972 \family default
6973  file to see an example of this.
6974 \end_layout
6975
6976 \begin_layout Subsection
6977
6978 FAQs, Tips, Tricks, and Other Ruminations
6979 \end_layout
6980
6981 \begin_layout Subsubsection
6982
6983 Getting LyX and AASTeX to cooperate
6984 \end_layout
6985
6986 \begin_layout Standard
6987
6988 It can be a bit tricky to get LyX to recognize a new layout and document
6989  class.
6990  When all else fails, do this:
6991 \end_layout
6992
6993 \begin_layout Enumerate
6994
6995 Make certain that LaTeX can find AASTeX.
6996  Copy sample.tex (and perhaps table.tex) from the AASTeX distribution into
6997  a directory completely unrelated to LaTeX or AASTeX and run LaTeX on 
6998 \family typewriter
6999 sample.tex
7000 \family default
7001 .
7002 \end_layout
7003
7004 \begin_layout Enumerate
7005
7006 Make certain that 
7007 \family typewriter
7008 aastex.layout
7009 \family default
7010  appears in 
7011 \family typewriter
7012 /usr/.../share/lyx/layouts
7013 \family default
7014  or 
7015 \family typewriter
7016 ~/.lyx/layouts
7017 \family default
7018 .
7019 \end_layout
7020
7021 \begin_layout Enumerate
7022
7023 Rerun 
7024 \family sans
7025 \bar under
7026 T
7027 \bar default
7028 ools\SpecialChar \menuseparator
7029
7030 \bar under
7031 R
7032 \bar default
7033 econfigure
7034 \family default
7035  in LyX, then restart LyX.
7036 \end_layout
7037
7038 \begin_layout Enumerate
7039
7040 Open a regular new file, not from a template.
7041  Does AASTeX appear in the class list in 
7042 \family sans
7043 \bar under
7044 D
7045 \bar default
7046 ocument\SpecialChar \menuseparator
7047
7048 \bar under
7049 S
7050 \bar default
7051 ettings
7052 \family default
7053 ?
7054 \end_layout
7055
7056 \begin_layout Standard
7057
7058 If you get a warning from an existing AASTeX document about not being able
7059  to find the AASTeX layout or a message about 
7060 \begin_inset Quotes eld
7061 \end_inset
7062
7063 You should not mix title layouts with normal ones
7064 \begin_inset Quotes erd
7065 \end_inset
7066
7067 , things haven't been installed correctly.
7068 \end_layout
7069
7070 \begin_layout Subsubsection
7071
7072 LaTeX error processing a table 
7073 \end_layout
7074
7075 \begin_layout Standard
7076
7077 LyX, by default, attempts to center the table caption/title.
7078  This seems to produce a bad interaction in AASTeX so you should click somewhere
7079  in the caption/title, then select 
7080 \family sans
7081 \bar under
7082 E
7083 \bar default
7084 dit\SpecialChar \menuseparator
7085
7086 \bar under
7087 P
7088 \bar default
7089 aragraph\InsetSpace ~
7090 Settings
7091 \family default
7092 , then set the 
7093 \family sans
7094 Alignment
7095 \family default
7096  to 
7097 \family sans
7098 \bar under
7099 B
7100 \bar default
7101 lock
7102 \family default
7103 .
7104  This took care of it for me.
7105 \end_layout
7106
7107 \begin_layout Subsubsection
7108
7109 References
7110 \begin_inset LatexCommand \label{cite}
7111
7112 \end_inset
7113
7114
7115 \end_layout
7116
7117 \begin_layout Standard
7118
7119 A couple of things: 1) I have noticed some funny spacing in the reference
7120  entries in the text.
7121  When you enter the bibliography item data, make sure their is 
7122 \emph on
7123 no
7124 \emph default
7125  space between the last author and the parenthesis setting off the year;
7126  
7127 \emph on
7128 e.g.
7129  
7130 \emph default
7131 type
7132 \family typewriter
7133  Ressler(1992)
7134 \family default
7135 , not 
7136 \family typewriter
7137 Ressler (1992)
7138 \family default
7139 .
7140  2) Entering the references at all is not obvious.
7141  The easiest thing is to start typing your first reference at the end of
7142  the document, then mark it as type 
7143 \family sans
7144 References
7145 \family default
7146 .
7147  That will put a small gray box in front of what you just typed.
7148  Click on the box to fill in the rest of the information.
7149  For new references, go to the end of an existing reference and press return.
7150  That will create a new line with its own box, etc.
7151 \end_layout
7152
7153 \begin_layout Subsubsection
7154
7155 Including EPS files
7156 \end_layout
7157
7158 \begin_layout Standard
7159
7160 Even though AASTeX provides its own figure commands (
7161 \family typewriter
7162
7163 \backslash
7164 plotone
7165 \family default
7166 , for example), I much prefer LaTeX's standard figure commands (with the
7167  default graphicx).
7168  You can insert the 
7169 \family typewriter
7170
7171 \backslash
7172 plotone
7173 \family default
7174 , etc.\InsetSpace ~
7175 commands as ERT into a Figure Float box if you desire, but I never
7176  have much luck getting the layout right.
7177  With the standard graphics, LyX will insert a 
7178 \family typewriter
7179
7180 \backslash
7181 usepackage{graphicx}
7182 \family default
7183  command into the LaTeX preamble and handle the figures in the standard
7184  LaTeX2e way, interspersing the figures in the text.
7185  I believe ApJ accepts figures exactly this way now; AJ might still use
7186  the 
7187 \begin_inset Quotes eld
7188 \end_inset
7189
7190 stack everything at the end
7191 \begin_inset Quotes erd
7192 \end_inset
7193
7194  technique.
7195 \end_layout
7196
7197 \begin_layout Subsubsection
7198
7199 Things I could have done, but didn't
7200 \end_layout
7201
7202 \begin_layout Standard
7203
7204 There are a few 
7205 \begin_inset Quotes eld
7206 \end_inset
7207
7208 pretty
7209 \begin_inset Quotes erd
7210 \end_inset
7211
7212  things I could have implemented, but chose not to.
7213  For instance, I saw no point in double-spacing the text in the LyX window,
7214  even though it is double-spaced in the paper manuscript.
7215  Also, I chose not to make separate layouts for the preprint and preprint2
7216  styles.
7217  Since I assume you will spend most of your time in the plain manuscript
7218  mode anyway, I decided not to chew up more disk space with this.
7219  
7220 \end_layout
7221
7222 \begin_layout Subsection
7223
7224 Final Caveat
7225 \end_layout
7226
7227 \begin_layout Standard
7228
7229 Your mileage may vary.
7230  I've now had papers published by both ApJ and AJ that have had 98% of the
7231  effort done in LyX; the last 2% was the LaTeX post-processing and a few
7232  cleanups.
7233  I have had no trouble with the submission process, and I'm sure the journals
7234  were never aware that there might be a difference.
7235  So, go forth and publish!
7236 \end_layout
7237
7238 \begin_layout Section
7239
7240 ijmpd
7241 \end_layout
7242
7243 \begin_layout Standard
7244
7245 by 
7246 \noun on
7247 Panayotis Papasotiriou
7248 \end_layout
7249
7250 \begin_layout Subsection
7251
7252 Overview
7253 \end_layout
7254
7255 \begin_layout Standard
7256
7257 The ijmpd package is a set of macros that facilitates electronic manuscript
7258  submission to the 
7259 \emph on
7260 International Journal of Modern Physics D
7261 \emph default
7262  published by World Scientific.
7263  The name of the document class is 
7264 \family typewriter
7265 ws-ijmpd.cls
7266 \family default
7267 .
7268  This file, together with instructions for the authors, can be downloaded
7269  from the site 
7270 \begin_inset LatexCommand \url{http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml}
7271
7272 \end_inset
7273
7274 .
7275  The ijmpd package is a modified version of the standard 
7276 \begin_inset Quotes eld
7277 \end_inset
7278
7279 article
7280 \begin_inset Quotes erd
7281 \end_inset
7282
7283  package.
7284  Most of its features are supported by LyX.
7285  I have recently used LyX successfully to write an article submitted to
7286  the 
7287 \emph on
7288 International Journal of Modern Physics D
7289 \emph default
7290 .
7291 \end_layout
7292
7293 \begin_layout Subsection
7294
7295 Writing a paper
7296 \end_layout
7297
7298 \begin_layout Standard
7299
7300 As usual, the easiest way to write a paper is to start with a template.
7301  Click on 
7302 \family sans
7303 \bar under
7304 F
7305 \bar default
7306 ile\SpecialChar \menuseparator
7307 New from 
7308 \bar under
7309 T
7310 \bar default
7311 emplate
7312 \family default
7313 , then choose the 
7314 \family typewriter
7315 ijmpd.lyx
7316 \family default
7317  template.
7318  This will give an (almost) empty document that includes the most common
7319  fields found in a manuscript.
7320  Simply overwrite the existing text (including the brackets, 
7321 \family typewriter
7322 <>
7323 \family default
7324 ) with the correct information.
7325  You should keep in mind the following remarks.
7326 \end_layout
7327
7328 \begin_layout Enumerate
7329
7330 LyX won't let you change the font size and the page style of the document,
7331  because the ijmpd package does not allow such modifications.
7332 \end_layout
7333
7334 \begin_layout Enumerate
7335
7336 The ijmpd package requires that the language of the document should not
7337  be changed.
7338  Before previewing your paper, be sure that the babel package is not used.
7339  To do this, click on 
7340 \family sans
7341 \bar under
7342 T
7343 \bar default
7344 ools\SpecialChar \menuseparator
7345
7346 \bar under
7347 P
7348 \bar default
7349 references
7350 \family default
7351 , deselect the 
7352 \family sans
7353 \bar under
7354 U
7355 \bar default
7356 se babel
7357 \family default
7358  checkbox in the language settings, and click on 
7359 \family sans
7360 \bar under
7361 A
7362 \bar default
7363 pply
7364 \family default
7365  (or 
7366 \family sans
7367 Save
7368 \family default
7369 , if you wish to make this change permanent).
7370 \end_layout
7371
7372 \begin_layout Enumerate
7373
7374 Two new environments, named 
7375 \begin_inset Quotes eld
7376 \end_inset
7377
7378 Theorem
7379 \begin_inset Quotes erd
7380 \end_inset
7381
7382  and 
7383 \begin_inset Quotes eld
7384 \end_inset
7385
7386 Proof
7387 \begin_inset Quotes erd
7388 \end_inset
7389
7390  are available (their use is obvious).
7391 \end_layout
7392
7393 \begin_layout Enumerate
7394
7395 Appendices may be added to the paper.
7396  LyX offers a special environment, called 
7397 \begin_inset Quotes eld
7398 \end_inset
7399
7400 Appendix
7401 \begin_inset Quotes erd
7402 \end_inset
7403
7404  which marks the beginning of the appendix.
7405  An appendix can contain normal sections, subsections, or subsubsections.
7406 \end_layout
7407
7408 \begin_layout Enumerate
7409
7410 The ijmpd package implements table captions quite differently than LyX does.
7411  As a result, a table created by LyX is printed correctly, but its caption
7412  is ignored.
7413  If you need table captions, you should implement the whole table float
7414  in a 
7415 \family typewriter
7416 .tex
7417 \family default
7418  file, then include this file to the LyX document (
7419 \family sans
7420 \bar under
7421 I
7422 \bar default
7423 nsert\SpecialChar \menuseparator
7424 Chil
7425 \bar under
7426 d
7427 \bar default
7428 \InsetSpace ~
7429 Document
7430 \family default
7431 ).
7432  Details on how to create an ijmpd table float can be found in the file
7433  
7434 \family typewriter
7435 ws-ijmpd.tex
7436 \family default
7437 , which is included in the ijmpd package.
7438 \end_layout
7439
7440 \begin_layout Subsection
7441
7442 Preparing a paper for submission
7443 \end_layout
7444
7445 \begin_layout Standard
7446
7447 Before you submit your paper you must export the LyX document as a LaTeX
7448  file (
7449 \family sans
7450 \bar under
7451 F
7452 \bar default
7453 ile\SpecialChar \menuseparator
7454
7455 \bar under
7456 E
7457 \bar default
7458 xport\SpecialChar \menuseparator
7459
7460 \bar under
7461 L
7462 \bar default
7463 ateX
7464 \family default
7465 ), then make the following changes to the resulting 
7466 \family typewriter
7467 .tex
7468 \family default
7469  file.
7470 \end_layout
7471
7472 \begin_layout Enumerate
7473
7474 Remove the comment lines before the 
7475 \family typewriter
7476
7477 \backslash
7478 documentclass
7479 \family default
7480  command.
7481 \end_layout
7482
7483 \begin_layout Enumerate
7484
7485 Remove everything between (and including) the 
7486 \family typewriter
7487
7488 \backslash
7489 makeatletter
7490 \family default
7491  and 
7492 \family typewriter
7493
7494 \backslash
7495 makeatother
7496 \family default
7497  commands, except for any commands you specifically put into the LaTeX preamble.
7498 \end_layout
7499
7500 \begin_layout Standard
7501
7502 The modified 
7503 \family typewriter
7504 .tex
7505 \family default
7506  file should be saved and processed through LaTeX as many times as necessary.
7507  You may also want to check the resulting 
7508 \family typewriter
7509 .dvi
7510 \family default
7511  document.
7512 \end_layout
7513
7514 \begin_layout Subsection
7515
7516 Use of ERT
7517 \end_layout
7518
7519 \begin_layout Standard
7520
7521 The use of ERT is optional, and is reduced to three commands, which affect
7522  the look of the page.
7523  If you started writing your paper by using the 
7524 \family typewriter
7525 ijmpd.lyx
7526 \family default
7527  template, the ERT needed is already in its place; you usually don't need
7528  to delete it.
7529  You may only change the first ERT to specify the information printed to
7530  the top of odd and even pages (authors' names and short paper's title,
7531  respectively).
7532  This ERT must have the form 
7533 \family typewriter
7534
7535 \backslash
7536 markboth{Authors' Names}{Short Paper's Title}
7537 \family default
7538 .
7539 \end_layout
7540
7541 \begin_layout Section
7542
7543 Kluwer
7544 \end_layout
7545
7546 \begin_layout Standard
7547
7548 by 
7549 \noun on
7550 Panayotis Papasotiriou
7551 \end_layout
7552
7553 \begin_layout Subsection
7554
7555 Overview
7556 \end_layout
7557
7558 \begin_layout Standard
7559
7560 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
7561  that facilitates electronic manuscript submission to the journals they
7562  publish.
7563  Most known of them (at least in my domain of interest) are 
7564 \emph on
7565 Astrophysics and Space Science
7566 \emph default
7567  and 
7568 \emph on
7569 Solar Physics
7570 \emph default
7571 , but there are many others (see a complete list at 
7572 \begin_inset LatexCommand \url{http://www.wkap.nl/jrnllist.htm/JRNLHOME}
7573
7574 \end_inset
7575
7576 ).
7577  The Kluwer package may be downloaded from the site 
7578 \begin_inset LatexCommand \url{http://www.wkap.nl/kaphtml.htm/STYLEFILES}
7579
7580 \end_inset
7581
7582 .
7583  A complete user guide is contained in that package (but it can also be
7584  downloaded separately).
7585 \end_layout
7586
7587 \begin_layout Standard
7588
7589 LyX supports many features of the package but not everything.
7590  However, the ERT needed is reduced to some 
7591 \begin_inset Quotes eld
7592 \end_inset
7593
7594 peculiar
7595 \begin_inset Quotes erd
7596 \end_inset
7597
7598  commands of the package (see\InsetSpace ~
7599
7600 \begin_inset LatexCommand \ref{subsec:kluwer_peculiarities}
7601
7602 \end_inset
7603
7604 ).
7605  I have recently used LyX to write an article submitted to the 
7606 \emph on
7607 Astrophysics and Space Science
7608 \emph default
7609  without any problem.
7610 \end_layout
7611
7612 \begin_layout Subsection
7613
7614 Writing a paper
7615 \end_layout
7616
7617 \begin_layout Standard
7618
7619 The easiest way to write a paper is to start with the Kluwer template file.
7620  Click on 
7621 \family sans
7622 File\SpecialChar \menuseparator
7623 New from 
7624 \bar under
7625 T
7626 \bar default
7627 emplate
7628 \family default
7629 , then choose the 
7630 \family typewriter
7631 kluwer.lyx
7632 \family default
7633  template.
7634  This will give an (almost) empty document that includes the most common
7635  fields found in a manuscript and a short description of their use.
7636  As in most templates, simply overwrite the existing text (including the
7637  brackets, 
7638 \family typewriter
7639 <>
7640 \family default
7641 ) with the correct information.
7642 \end_layout
7643
7644 \begin_layout Subsection
7645
7646 Preparing a paper for submission
7647 \end_layout
7648
7649 \begin_layout Standard
7650
7651 As in the AASTeX package, before you submit your paper to a journal you
7652  must 
7653 \begin_inset Quotes eld
7654 \end_inset
7655
7656 postprocess
7657 \begin_inset Quotes erd
7658 \end_inset
7659
7660  it as follows.
7661 \end_layout
7662
7663 \begin_layout Enumerate
7664
7665 Export your paper as a LaTeX file.
7666  To do this, click on 
7667 \family sans
7668 \bar under
7669 F
7670 \bar default
7671 ile\SpecialChar \menuseparator
7672
7673 \bar under
7674 E
7675 \bar default
7676 xport\SpecialChar \menuseparator
7677
7678 \bar under
7679 L
7680 \bar default
7681 ateX
7682 \family default
7683 .
7684  
7685 \end_layout
7686
7687 \begin_layout Enumerate
7688
7689 Edit the resulting 
7690 \family typewriter
7691 .tex
7692 \family default
7693  file with a text editor and make the following changes
7694 \end_layout
7695
7696 \begin_deeper
7697 \begin_layout Enumerate
7698
7699 remove the comment lines before the 
7700 \family typewriter
7701
7702 \backslash
7703 documentclass
7704 \family default
7705  command,
7706 \end_layout
7707
7708 \begin_layout Enumerate
7709
7710 remove everything between (and including) the 
7711 \family typewriter
7712
7713 \backslash
7714 makeatletter
7715 \family default
7716  and 
7717 \family typewriter
7718
7719 \backslash
7720 makeatother
7721 \family default
7722  commands, except for any commands you specifically put into the LaTeX preamble.
7723 \end_layout
7724
7725 \begin_layout Standard
7726
7727 Save the resulting 
7728 \family typewriter
7729 .tex
7730 \family default
7731  file.
7732 \end_layout
7733 \end_deeper
7734 \begin_layout Enumerate
7735
7736 Run the 
7737 \family typewriter
7738 .tex
7739 \family default
7740  file through LaTeX as many times as necessary (usually up to three).
7741 \end_layout
7742
7743 \begin_layout Enumerate
7744
7745 View the resulting 
7746 \family typewriter
7747 .dvi
7748 \family default
7749  document using, e.g., 
7750 \family sans
7751 xdvi
7752 \family default
7753 , and check if everything is ok (it should, if you didn't make any mistake).
7754 \end_layout
7755
7756 \begin_layout Subsection
7757
7758
7759 \begin_inset Quotes eld
7760 \end_inset
7761
7762 Peculiarities
7763 \begin_inset Quotes erd
7764 \end_inset
7765
7766  of the Kluwer package
7767 \begin_inset LatexCommand \label{subsec:kluwer_peculiarities}
7768
7769 \end_inset
7770
7771
7772 \end_layout
7773
7774 \begin_layout Standard
7775
7776 The Kluwer package has the following 
7777 \begin_inset Quotes eld
7778 \end_inset
7779
7780 peculiarities
7781 \begin_inset Quotes erd
7782 \end_inset
7783
7784 .
7785 \end_layout
7786
7787 \begin_layout Enumerate
7788
7789 It is possible to write multiple articles in the same LaTeX file
7790 \begin_inset Foot
7791 status collapsed
7792
7793 \begin_layout Standard
7794
7795 I can't imagine any good reason to do this.
7796 \end_layout
7797
7798 \end_inset
7799
7800 .
7801  Each article must be included in the environment 
7802 \begin_inset Quotes eld
7803 \end_inset
7804
7805 article
7806 \begin_inset Quotes erd
7807 \end_inset
7808
7809 .
7810  Unfortunately, this environment cannot be omitted, even if you write just
7811  one article.
7812  Therefore, each article starts with the command 
7813 \family typewriter
7814
7815 \backslash
7816 begin{article}
7817 \family default
7818  and, obviously, ends with the command 
7819 \family typewriter
7820
7821 \backslash
7822 end{article}
7823 \family default
7824 .
7825  Although this can be implemented in LyX, I didn't included it, since it
7826  looks ugly and can confuse the novice user.
7827  Therefore, you need to enter them directly and mark them as LaTeX code
7828  (the well-known 
7829 \begin_inset Quotes eld
7830 \end_inset
7831
7832 ERT
7833 \begin_inset Quotes erd
7834 \end_inset
7835
7836 ).
7837 \end_layout
7838
7839 \begin_layout Enumerate
7840
7841 Information given at the beginning of the article (i.e., title, subtitle,
7842  author, institution, running title, running author, abstract and keywords)
7843  must be included in an environment called 
7844 \begin_inset Quotes eld
7845 \end_inset
7846
7847 opening
7848 \begin_inset Quotes erd
7849 \end_inset
7850
7851 .
7852  This is not implemented in LyX, so you must enter title, subtitle etc.
7853  between two ERT lines (
7854 \family typewriter
7855
7856 \backslash
7857 begin{opening}
7858 \family default
7859  and 
7860 \family typewriter
7861
7862 \backslash
7863 end{opening}
7864 \family default
7865 ).
7866 \end_layout
7867
7868 \begin_layout Enumerate
7869
7870 According to the user manual, the label of each bibliography item must be
7871  written as 
7872 \family typewriter
7873
7874 \backslash
7875 protect
7876 \backslash
7877 citeauthoryear{
7878 \family default
7879 \emph on
7880 author(s)
7881 \family typewriter
7882 \emph default
7883 }{
7884 \family default
7885 \emph on
7886 year
7887 \family typewriter
7888 \emph default
7889 }
7890 \family default
7891 .
7892 \end_layout
7893
7894 \begin_layout Standard
7895
7896 The 
7897 \family typewriter
7898 kluwer.lyx
7899 \family default
7900  template takes care of all these 
7901 \begin_inset Quotes eld
7902 \end_inset
7903
7904 peculiarities
7905 \begin_inset Quotes erd
7906 \end_inset
7907
7908 .
7909  If you start a new paper using this template you don't need to do anything
7910  special.
7911  Just 
7912 \end_layout
7913
7914 \begin_layout Enumerate
7915
7916 don't delete the ERT included in the template, and
7917 \end_layout
7918
7919 \begin_layout Enumerate
7920
7921 copy the example bibliography item included in the template and modify it
7922  as necessary to enter new bibliography items.
7923 \end_layout
7924
7925 \begin_layout Section
7926
7927 Koma-Script
7928 \end_layout
7929
7930 \begin_layout Standard
7931
7932 by 
7933 \noun on
7934 Bernd Rellermeyer
7935 \end_layout
7936
7937 \begin_layout Subsection
7938
7939 Overview
7940 \end_layout
7941
7942 \begin_layout Standard
7943
7944 The LyX document classes
7945 \emph on
7946  article (koma-script)
7947 \emph default
7948
7949 \emph on
7950 report (koma-script)
7951 \emph default
7952
7953 \emph on
7954 book
7955 \emph default
7956  
7957 \emph on
7958 (koma-script)
7959 \emph default
7960 , and 
7961 \emph on
7962 letter
7963 \emph default
7964  
7965 \emph on
7966 (koma-script)
7967 \emph default
7968  correspond to the LaTeX document classes 
7969 \family typewriter
7970 scrartcl.cls
7971 \family default
7972
7973 \family typewriter
7974 scrreprt.cls
7975 \family default
7976
7977 \family typewriter
7978 scrbook.cls
7979 \family default
7980 , and 
7981 \family typewriter
7982 scrlettr.cls
7983 \family default
7984 , resp.
7985  of the Koma-Script family.
7986  They are replacements for the standard document classes 
7987 \family typewriter
7988 article.cls
7989 \family default
7990
7991 \family typewriter
7992 report.cls
7993 \family default
7994
7995 \family typewriter
7996 book.cls
7997 \family default
7998  and 
7999 \family typewriter
8000 letter.cls
8001 \family default
8002 , resp., and fit better to European typography conventions in a number of
8003  points.
8004 \end_layout
8005
8006 \begin_layout Itemize
8007
8008 Standard character size is 11pt in 
8009 \emph on
8010 article (koma-script)
8011 \emph default
8012
8013 \emph on
8014 report (koma-script)
8015 \emph default
8016 , and 
8017 \emph on
8018 book (koma-script)
8019 \emph default
8020 , and 12pt in 
8021 \emph on
8022 letter (koma-script)
8023 \emph default
8024 .
8025 \end_layout
8026
8027 \begin_layout Itemize
8028
8029 Headings, labels of the description environment, and a number of elements
8030  of the 
8031 \emph on
8032 letter (koma-script) 
8033 \emph default
8034 document class are set in a bold sans serif font.
8035 \begin_inset Foot
8036 status collapsed
8037
8038 \begin_layout Standard
8039
8040 There is a big difference between the bold sans serif old cm fonts and new
8041  ec fonts, especially in the appearance of headings.
8042  In comparison, the ec bold sans serif fonts look a bit thin.
8043  Here the LaTeX package 
8044 \family typewriter
8045 cmsd.sty by 
8046 \family default
8047 \shape smallcaps
8048 Walter Schmidt
8049 \shape default
8050  helps to produce the 
8051 \begin_inset Quotes eld
8052 \end_inset
8053
8054 usual
8055 \begin_inset Quotes erd
8056 \end_inset
8057
8058  appearance when using the ec fonts.
8059 \end_layout
8060
8061 \end_inset
8062
8063  The numbering of chapter headings is made in the same way as the numbering
8064  of section headings, that is without the extra line 
8065 \begin_inset Quotes eld
8066 \end_inset
8067
8068 Chapter\SpecialChar \ldots{}
8069
8070 \begin_inset Quotes erd
8071 \end_inset
8072
8073 .
8074  In addition, the appearance of the headings can be modified by using a
8075  number of options (in LyX to be entered in the field 
8076 \family sans
8077 E
8078 \bar under
8079 x
8080 \bar default
8081 tra\InsetSpace ~
8082 Options
8083 \family default
8084  of the dialog 
8085 \family sans
8086 \bar under
8087 L
8088 \bar default
8089 ayout\SpecialChar \menuseparator
8090
8091 \bar under
8092 D
8093 \bar default
8094 ocument
8095 \family default
8096 ).
8097  A detailed German description of these options can be found in the Koma-Script
8098  documentation 
8099 \emph on
8100 scrguide
8101 \emph default
8102 .
8103 \end_layout
8104
8105 \begin_layout Itemize
8106
8107 The main means in the Koma-Script document classes to design the type area
8108  are the options 
8109 \family sans
8110 BCOR
8111 \family default
8112  and 
8113 \family sans
8114 DIV
8115 \family default
8116  (in LyX to be entered in the extra class options field in the dialog 
8117 \family sans
8118 \bar under
8119 D
8120 \bar default
8121 ocument\SpecialChar \menuseparator
8122
8123 \bar under
8124 S
8125 \bar default
8126 ettings
8127 \family default
8128 ).
8129  They make a clearer modification of page margins possible as do the options
8130  of the dialog 
8131 \family sans
8132 \bar under
8133 D
8134 \bar default
8135 ocument\SpecialChar \menuseparator
8136
8137 \bar under
8138 S
8139 \bar default
8140 ettings
8141 \family default
8142 .
8143  A detailed German description of these and other type area options can
8144  be found in the Koma-Script documentation 
8145 \emph on
8146 scrguide
8147 \emph default
8148 .
8149 \end_layout
8150
8151 \begin_layout Itemize
8152
8153 The LaTeX document classes of the Koma-Script family define a number of
8154  additional commands.
8155  Those part of it which makes sense in LyX is implemented in corresponding
8156  paragraph types.
8157 \end_layout
8158
8159 \begin_layout Standard
8160
8161 A detailed German description of the LaTeX document classes of the Koma-Script
8162  family can be found in the Koma-Script documentation 
8163 \emph on
8164 scrguide
8165 \emph default
8166 .
8167 \begin_inset Foot
8168 status collapsed
8169
8170 \begin_layout Standard
8171
8172 There is an English translation 
8173 \emph on
8174 screnggu
8175 \emph default
8176 , but it is not a complete one.
8177 \end_layout
8178
8179 \end_inset
8180
8181  The following sections describe only those aspects, which are relevant
8182  in LyX.
8183 \end_layout
8184
8185 \begin_layout Subsection
8186
8187 article (koma-script), report (koma-script), and book (koma-script)
8188 \end_layout
8189
8190 \begin_layout Standard
8191
8192 The document classes 
8193 \emph on
8194 article (koma-script)
8195 \emph default
8196
8197 \emph on
8198 report (koma-script)
8199 \emph default
8200 , and 
8201 \emph on
8202 book
8203 \emph default
8204  
8205 \emph on
8206 (koma-script)
8207 \emph default
8208  are implemented in the layout files 
8209 \family typewriter
8210 scrartcl.layout
8211 \family default
8212
8213 \family typewriter
8214 scrreprt.layout
8215 \family default
8216 , and 
8217 \family typewriter
8218 scrbook.layout
8219 \family default
8220 , resp.
8221  They contain all the paragraph types of the corresponding standard document
8222  classes 
8223 \emph on
8224 article
8225 \emph default
8226
8227 \emph on
8228 report
8229 \emph default
8230 , and 
8231 \emph on
8232 book
8233 \emph default
8234 , resp., partly modified, with the exception of the LyX specific 
8235 \family sans
8236 List
8237 \family default
8238 -type, which is replaced by the new 
8239 \family sans
8240 Labeling
8241 \family default
8242 -type having the same functionality.
8243  Beside the 
8244 \family sans
8245 Labeling
8246 \family default
8247 -Type there is a number of new paragraph types added.
8248  They are 
8249 \emph on
8250 not
8251 \emph default
8252  part of 
8253 \emph on
8254 letter (koma-script)
8255 \emph default
8256 .
8257 \end_layout
8258
8259 \begin_layout Itemize
8260
8261
8262 \family sans
8263 Addpart, Addchap
8264 \family default
8265
8266 \family sans
8267 Addsec
8268 \family default
8269 : are equivalents to 
8270 \family sans
8271 Part*, Chapter*
8272 \family default
8273  and 
8274 \family sans
8275 Section*
8276 \family default
8277 , resp., additionally inserting an entry in the table of contents.
8278  
8279 \family sans
8280 Addpart 
8281 \family default
8282 and
8283 \family sans
8284  Addchap
8285 \family default
8286  are not contained in 
8287 \emph on
8288 article (koma-script)
8289 \emph default
8290 .
8291 \end_layout
8292
8293 \begin_layout Itemize
8294
8295
8296 \family sans
8297 Addchap*
8298 \family default
8299
8300 \family sans
8301 Addsec*
8302 \family default
8303 : behave exactly as 
8304 \family sans
8305 Addchap
8306 \family default
8307  and 
8308 \family sans
8309 Addsec
8310 \family default
8311 , resp., additionally clearing running heads.
8312
8313 \family sans
8314  Addchap*
8315 \family default
8316  is not contained in 
8317 \emph on
8318 article (koma-script)
8319 \emph default
8320 .
8321 \begin_inset Foot
8322 status collapsed
8323
8324 \begin_layout Standard
8325
8326 There is also an 
8327 \family typewriter
8328
8329 \backslash
8330 addpart*
8331 \family default
8332  command in 
8333 \emph on
8334 book (koma-script)
8335 \emph default
8336  and in 
8337 \emph on
8338 report (koma-script)
8339 \emph default
8340 , but since this is identical to 
8341 \family sans
8342 Part*
8343 \family default
8344 , is has not been implemented in LyX.
8345 \end_layout
8346
8347 \end_inset
8348
8349
8350 \end_layout
8351
8352 \begin_layout Itemize
8353
8354
8355 \family sans
8356 Minisec
8357 \family default
8358 : generates a heading directly above the following paragraph in the standard
8359  character size without affecting the structure of the document.
8360 \end_layout
8361
8362 \begin_layout Itemize
8363
8364
8365 \family sans
8366 Captionabove
8367 \family default
8368  and 
8369 \family sans
8370 Captionbelow 
8371 \family default
8372 are special captions which respect the different space settings needed for
8373  captions placed above or below an element (if you follow strict typographic
8374  rules, you might want to place table captions always above the table).
8375  You can also use the class option 
8376 \family typewriter
8377 tablecaptionsabove
8378 \family default
8379 , which will switch 
8380 \family sans
8381 caption
8382 \family default
8383  to 
8384 \family sans
8385 captionabove
8386 \family default
8387  for tables and 
8388 \family sans
8389 captionbelow
8390 \family default
8391  for figures.
8392  You need at least Koma-Script version 2.8q to use this.
8393 \end_layout
8394
8395 \begin_layout Itemize
8396
8397
8398 \family sans
8399 Dictum
8400 \family default
8401 : can be used to set a bonmot, e.
8402 \begin_inset ERT
8403 status collapsed
8404
8405 \begin_layout Standard
8406
8407 \backslash
8408 ,
8409 \end_layout
8410
8411 \end_inset
8412
8413 g.
8414 \begin_inset ERT
8415 status collapsed
8416
8417 \begin_layout Standard
8418
8419 \backslash
8420  
8421 \end_layout
8422
8423 \end_inset
8424
8425 at the beginning of a chapter.
8426  If you use the optional argument (
8427 \family sans
8428 \bar under
8429 I
8430 \bar default
8431 nsert\SpecialChar \menuseparator
8432 Short\InsetSpace ~
8433 Title
8434 \family default
8435 ), you can insert the dictum's author there.
8436  Dictum and author are separated by a line.
8437  You need at least Koma-Script version 2.8q to use this.
8438  
8439 \family sans
8440 Dictum
8441 \family default
8442  is not contained in 
8443 \emph on
8444 article (koma-script)
8445 \emph default
8446 .
8447 \end_layout
8448
8449 \begin_layout Standard
8450
8451 The following types, together with the standard types 
8452 \family sans
8453 Title
8454 \family default
8455
8456 \family sans
8457 Author
8458 \family default
8459 , and 
8460 \family sans
8461 Date
8462 \family default
8463 , form the title area of the document.
8464  They must be entered ahead of the first 
8465 \begin_inset Quotes eld
8466 \end_inset
8467
8468 ordinary
8469 \begin_inset Quotes erd
8470 \end_inset
8471
8472  paragraph.
8473 \begin_inset Foot
8474 status collapsed
8475
8476 \begin_layout Standard
8477
8478 The corresponding LaTeX commands must appear before the 
8479 \family typewriter
8480
8481 \backslash
8482 maketitle
8483 \family default
8484  command.
8485 \end_layout
8486
8487 \end_inset
8488
8489  When such a type is used more than once, the latter usage overwrites the
8490  former one, that means, for every type only the latest usage is valid.
8491  The order of the different types however has, like 
8492 \family sans
8493 Title
8494 \family default
8495
8496 \family sans
8497 Author
8498 \family default
8499 , and 
8500 \family sans
8501 Date
8502 \family default
8503 , no effect on the appearance of the produced document.
8504 \end_layout
8505
8506 \begin_layout Itemize
8507
8508
8509 \family sans
8510 Subject
8511 \family default
8512 : produces a centered paragraph above the ordinary title (
8513 \family sans
8514 Title
8515 \family default
8516
8517 \family sans
8518 Author
8519 \family default
8520
8521 \family sans
8522 Date
8523 \family default
8524 ) for the subject of the document.
8525 \end_layout
8526
8527 \begin_layout Itemize
8528
8529
8530 \family sans
8531 Publishers
8532 \family default
8533 : produces a centered paragraph below the ordinary title (
8534 \family sans
8535 Title
8536 \family default
8537
8538 \family sans
8539 Author
8540 \family default
8541
8542 \family sans
8543 Date
8544 \family default
8545 ) for the publishers' name.
8546 \end_layout
8547
8548 \begin_layout Itemize
8549
8550
8551 \family sans
8552 Dedication
8553 \family default
8554 : in 
8555 \emph on
8556 report (koma-script)
8557 \emph default
8558  and 
8559 \emph on
8560 book (koma-script)
8561 \emph default
8562  produces a centered paragraph on its own page behind the title page, or
8563  in 
8564 \emph on
8565 article (koma-script)
8566 \emph default
8567  produces a centered paragraph below the ordinary title (
8568 \family sans
8569 Title
8570 \family default
8571
8572 \family sans
8573 Author
8574 \family default
8575
8576 \family sans
8577 Date
8578 \family default
8579
8580 \family sans
8581 Publishers
8582 \family default
8583 ) for a dedication.
8584 \end_layout
8585
8586 \begin_layout Itemize
8587
8588
8589 \family sans
8590 Titlehead
8591 \family default
8592 : produces a left aligned paragraph above the ordinary title (
8593 \family sans
8594 Title
8595 \family default
8596
8597 \family sans
8598 Author
8599 \family default
8600
8601 \family sans
8602 Date
8603 \family default
8604
8605 \family sans
8606 Subject
8607 \family default
8608 ) for a document`s head.
8609 \end_layout
8610
8611 \begin_layout Itemize
8612
8613
8614 \family sans
8615 Uppertitleback
8616 \family default
8617 : produces in a double-sided print in 
8618 \emph on
8619 report (koma-script)
8620 \emph default
8621  and 
8622 \emph on
8623 book (koma-script)
8624 \emph default
8625  a left-aligned paragraph at the top of the title page`s back or has no
8626  effect in a single-sided print or in 
8627 \emph on
8628 article (koma-script)
8629 \emph default
8630 .
8631 \end_layout
8632
8633 \begin_layout Itemize
8634
8635
8636 \family sans
8637 Lowertitleback
8638 \family default
8639 : produces in a double-sided print in 
8640 \emph on
8641 report (koma-script)
8642 \emph default
8643  and 
8644 \emph on
8645 book (koma-script)
8646 \emph default
8647  a left-aligned paragraph at the bottom of the title page`s back or has
8648  no effect in a single-sided print or in 
8649 \emph on
8650 article (koma-script)
8651 \emph default
8652 .
8653 \end_layout
8654
8655 \begin_layout Itemize
8656
8657
8658 \family sans
8659 Extratitle
8660 \family default
8661 : produces a special 
8662 \begin_inset Quotes eld
8663 \end_inset
8664
8665 dirty
8666 \begin_inset Quotes erd
8667 \end_inset
8668
8669  page ahead of the actual document containing a paragraph without special
8670  formatting.
8671 \end_layout
8672
8673 \begin_layout Standard
8674
8675 The layout files for the document classes 
8676 \emph on
8677 article (koma-script)
8678 \emph default
8679
8680 \emph on
8681 report (koma-script)
8682 \emph default
8683 , and 
8684 \emph on
8685 book (koma-script)
8686 \emph default
8687  do include the file 
8688 \family typewriter
8689 scrmacros.inc
8690 \family default
8691 .
8692  This is thought of as a place to define your own types.
8693  Copy s
8694 \family typewriter
8695 crmacros.inc
8696 \family default
8697  in your personal layout directory and edit the file!
8698 \end_layout
8699
8700 \begin_layout Subsection
8701
8702 letter (koma-script)
8703 \end_layout
8704
8705 \begin_layout Standard
8706
8707
8708 \begin_inset ERT
8709 status inlined
8710
8711 \begin_layout Standard
8712
8713 \backslash
8714 begin{sloppypar}
8715 \end_layout
8716
8717 \end_inset
8718
8719
8720 \end_layout
8721
8722 \begin_layout Standard
8723 \noindent
8724 The document class 
8725 \emph on
8726 letter (koma-script)
8727 \emph default
8728  is implemented in the layout file 
8729 \family typewriter
8730 scrlettr.layout
8731 \family default
8732 .
8733  It contains all the paragraph types of the corresponding standard document
8734  class 
8735 \emph on
8736 letter
8737 \emph default
8738 , partly modified, with the exception of the LyX specific types 
8739 \family sans
8740 LyX-Code
8741 \family default
8742  and 
8743 \family sans
8744 Comment
8745 \family default
8746  and the 
8747 \family sans
8748 List
8749 \family default
8750  type, which is replaced by the new 
8751 \family sans
8752 Labeling
8753 \family default
8754  type.
8755  In addition, it contains, in contrast to the standard document class, the
8756  standard types 
8757 \family sans
8758 LaTeX
8759 \family default
8760
8761 \family sans
8762 Quotation
8763 \family default
8764
8765 \family sans
8766 Quote
8767 \family default
8768 , and 
8769 \family sans
8770 Verse
8771 \family default
8772 .
8773  Furthermore, there are a number of new letter specific types.
8774 \end_layout
8775
8776 \begin_layout Standard
8777
8778
8779 \begin_inset ERT
8780 status inlined
8781
8782 \begin_layout Standard
8783
8784 \backslash
8785 end{sloppypar}
8786 \end_layout
8787
8788 \end_inset
8789
8790
8791 \end_layout
8792
8793 \begin_layout Standard
8794
8795 The appearance of the letter produced by this document class can be controlled
8796  by a number of LaTeX commands, which you can put in the LaTeX preamble.
8797 \begin_inset Foot
8798 status collapsed
8799
8800 \begin_layout Standard
8801
8802 For example, the standard appearance of the letter`s heading, consisting
8803  of name and address, is quite self-willed.
8804  An 
8805 \begin_inset Quotes eld
8806 \end_inset
8807
8808 ordinary
8809 \begin_inset Quotes erd
8810 \end_inset
8811
8812  heading is produced by the following LaTeX commands in the preamble:
8813 \end_layout
8814
8815 \begin_layout LyX-Code
8816
8817
8818 \backslash
8819 firsthead{
8820 \backslash
8821 parbox[b]{
8822 \backslash
8823 textwidth}
8824 \end_layout
8825
8826 \begin_layout LyX-Code
8827
8828   {
8829 \backslash
8830 ignorespaces 
8831 \backslash
8832 fromname
8833 \backslash
8834
8835 \backslash
8836  
8837 \backslash
8838 ignorespaces 
8839 \backslash
8840 fromaddress}} 
8841 \end_layout
8842
8843 \begin_layout LyX-Code
8844
8845
8846 \backslash
8847 nexthead{
8848 \backslash
8849 parbox[b]{
8850 \backslash
8851 textwidth}
8852 \end_layout
8853
8854 \begin_layout LyX-Code
8855
8856   {
8857 \backslash
8858 ignorespaces 
8859 \backslash
8860 fromname 
8861 \backslash
8862 hfill 
8863 \backslash
8864 ignorespaces 
8865 \backslash
8866 pagename
8867 \backslash
8868  
8869 \backslash
8870 thepage}}
8871 \end_layout
8872
8873 \end_inset
8874
8875  A detailed German description of such LaTeX commands can be found in the
8876  Koma-Script documentation 
8877 \emph on
8878 scrguide
8879 \emph default
8880 .
8881  With it, the letter's author can produce his personal letter layout.
8882 \end_layout
8883
8884 \begin_layout Standard
8885
8886 The types 
8887 \family sans
8888 Letter 
8889 \family default
8890 and 
8891 \family sans
8892 Opening
8893 \family default
8894  define the beginning of the letter and must be used in every letter.
8895  To emphasize them in the LyX document class, they are marked with the letter
8896  
8897 \shape italic
8898 L
8899 \shape default
8900  or 
8901 \shape italic
8902 O
8903 \shape default
8904 , resp.
8905  in the left margin.
8906  It is possible to write any number of letters in one file.
8907  An 
8908 \family sans
8909 Opening
8910 \family default
8911  type produces a new letter using the same addressee and a 
8912 \family sans
8913 Letter
8914 \family default
8915  type produces a new addressee.
8916  The types 
8917 \family sans
8918 Closing
8919 \family default
8920
8921 \family sans
8922 PS
8923 \family default
8924
8925 \family sans
8926 CC
8927 \family default
8928 , and 
8929 \family sans
8930 Encl
8931 \family default
8932  are ordinary paragraph types and can also be used several times in one
8933  and the same letter.
8934 \end_layout
8935
8936 \begin_layout Itemize
8937
8938
8939 \family sans
8940 Letter
8941 \family default
8942 : produces a paragraph for the addressee and implicitly defines the beginning
8943  of the letter.
8944 \end_layout
8945
8946 \begin_layout Itemize
8947
8948
8949 \family sans
8950 Opening
8951 \family default
8952 : produces a paragraph for the form of address and implicitly produces a
8953  new letter.
8954 \end_layout
8955
8956 \begin_layout Itemize
8957
8958
8959 \family sans
8960 Closing
8961 \family default
8962 : produces a paragraph for a close.
8963 \end_layout
8964
8965 \begin_layout Itemize
8966
8967
8968 \family sans
8969 PS
8970 \family default
8971 : produces a paragraph for a postscript.
8972 \end_layout
8973
8974 \begin_layout Itemize
8975
8976
8977 \family sans
8978 CC
8979 \family default
8980 : produces a paragraph for a distribution list.
8981 \end_layout
8982
8983 \begin_layout Itemize
8984
8985
8986 \family sans
8987 Encl
8988 \family default
8989 : produces a paragraph for enclosures.
8990 \end_layout
8991
8992 \begin_layout Standard
8993
8994 The types 
8995 \family sans
8996 Name
8997 \family default
8998
8999 \family sans
9000 Signature
9001 \family default
9002
9003 \family sans
9004 Address
9005 \family default
9006 ,
9007 \family sans
9008  Telephone
9009 \family default
9010
9011 \family sans
9012 Place
9013 \family default
9014
9015 \family sans
9016 Backaddress
9017 \family default
9018
9019 \family sans
9020 Specialmail
9021 \family default
9022
9023 \family sans
9024 Location
9025 \family default
9026
9027 \family sans
9028 Title
9029 \family default
9030 , and 
9031 \family sans
9032 Subject
9033 \family default
9034  are input types provided with a label to enter information, which will
9035  be processed by the document class.
9036 \begin_inset Foot
9037 status collapsed
9038
9039 \begin_layout Standard
9040
9041 It could be seen as a matter of inconsequence, that the types 
9042 \family sans
9043 Letter
9044 \family default
9045  and 
9046 \family sans
9047 Opening
9048 \family default
9049  described above are not such input types as well.
9050  Because of the special meaning of those types, however, I have implemented
9051  them as ordinary paragraph types with a one letter mark in the left margin.
9052  Moreover, it would affect my feeling of symmetry, if the 
9053 \family sans
9054 Opening
9055 \family default
9056  type and the 
9057 \family sans
9058 Closing
9059 \family default
9060  type had such a serious different appearance.
9061 \end_layout
9062
9063 \end_inset
9064
9065  The types must be used ahead of the corresponding 
9066 \family sans
9067 Opening
9068 \family default
9069  type.
9070 \end_layout
9071
9072 \begin_layout Standard
9073
9074 An implementation of these types in a WYSIWYG fashion does not seem to make
9075  sense, because the real appearance of the produced letter does not only
9076  depend on the usage of the particular type, but also on other factors.
9077  For example, a signature entered in the 
9078 \family sans
9079 Signature
9080 \family default
9081  type will in the standard behavior appear in the produced letter only,
9082  when in the same letter also a 
9083 \family sans
9084 Closing
9085 \family default
9086  type is used.
9087  The entered value of the 
9088 \family sans
9089 Telephone
9090 \family default
9091  type will in the standard behavior not appear in the produced letter at
9092  all.
9093  The possibility to design the letter`s heading freely is already indicated
9094  in a footnote above.
9095 \end_layout
9096
9097 \begin_layout Standard
9098
9099 The input types can also be used as empty paragraphs.
9100  This makes sense e.\InsetSpace ~
9101 g.
9102  for the 
9103 \family sans
9104 Signature
9105 \family default
9106  type.
9107  If the 
9108 \family sans
9109 Signature
9110 \family default
9111  type is not used at all, in the standard behavior the value of the 
9112 \family sans
9113 Name
9114 \family default
9115  type is used as signature, whereas if an empty 
9116 \family sans
9117 Signature
9118 \family default
9119  type is used, no signature value is defined.
9120 \end_layout
9121
9122 \begin_layout Standard
9123
9124 By using the input types it is possible to write a letter template, containing
9125  filled input types with your personal dates (name, address, etc.) and empty
9126  input types for other dates you want to enter.
9127 \end_layout
9128
9129 \begin_layout Itemize
9130
9131
9132 \family sans
9133 Name
9134 \family default
9135 : sender's name, in the standard behavior appears as a centered paragraph
9136  in small caps in the letter`s heading.
9137 \end_layout
9138
9139 \begin_layout Itemize
9140
9141
9142 \family sans
9143 Signature
9144 \family default
9145 : sender's signature, in the standard behavior appears below the 
9146 \family sans
9147 Closing
9148 \family default
9149  type.
9150  If no 
9151 \family sans
9152 Signature
9153 \family default
9154  type is used, the value of the 
9155 \family sans
9156 Name
9157 \family default
9158  type appears instead.
9159 \end_layout
9160
9161 \begin_layout Itemize
9162
9163
9164 \family sans
9165 Address
9166 \family default
9167 : sender's address, in the standard behavior appears in a centered paragraph
9168  in the letter`s heading below the sender's name.
9169 \end_layout
9170
9171 \begin_layout Itemize
9172
9173
9174 \family sans
9175 Telephone
9176 \family default
9177 : sender's telephone number, in the standard behavior only sets the LaTeX
9178  variable 
9179 \family typewriter
9180
9181 \backslash
9182 telephonenum
9183 \family default
9184 .
9185 \end_layout
9186
9187 \begin_layout Itemize
9188
9189
9190 \family sans
9191 Place
9192 \family default
9193 : place of the letter`s making.
9194 \end_layout
9195
9196 \begin_layout Itemize
9197
9198
9199 \family sans
9200 Date
9201 \family default
9202 : date of the letter`s making.
9203  
9204 \family sans
9205 Place
9206 \family default
9207  and 
9208 \family sans
9209 Date
9210 \family default
9211 , in the standard behavior, produce the place and the date in a right-aligned
9212  line below the addressee's field.
9213  If an empty 
9214 \family sans
9215 Date
9216 \family default
9217  type is used, neither place nor date appear, independent of the value of
9218  the 
9219 \family sans
9220 Place
9221 \family default
9222  type.
9223  If no 
9224 \family sans
9225 Date
9226 \family default
9227  type is used, the date of the letter `s production is used.
9228 \end_layout
9229
9230 \begin_layout Itemize
9231
9232
9233 \family sans
9234 Backaddress
9235 \family default
9236 : sender`s back address, in the standard behavior appears above the addressee's
9237  field in a small sans serif font.
9238 \end_layout
9239
9240 \begin_layout Itemize
9241
9242
9243 \family sans
9244 Specialmail
9245 \family default
9246 : special mail information, in the standard behavior appears underlined
9247  above the addressee's field below the back address.
9248 \end_layout
9249
9250 \begin_layout Itemize
9251
9252
9253 \family sans
9254 Location
9255 \family default
9256 : additional information, in the standard behavior appears on right side
9257  below the addressee`s field.
9258 \end_layout
9259
9260 \begin_layout Itemize
9261
9262
9263 \family sans
9264 Title
9265 \family default
9266 : the letter's title, in the standard behavior appears in a big, bold, sans
9267  serif font above the subject.
9268 \end_layout
9269
9270 \begin_layout Itemize
9271
9272
9273 \family sans
9274 Subject
9275 \family default
9276 : the letter's subject, in the standard behavior appears in a bold font
9277  above the 
9278 \family sans
9279 Opening
9280 \family default
9281  paragraph.
9282 \end_layout
9283
9284 \begin_layout Standard
9285
9286 The types 
9287 \family sans
9288 Yourref
9289 \family default
9290
9291 \family sans
9292 Yourmail
9293 \family default
9294
9295 \family sans
9296 Myref
9297 \family default
9298
9299 \family sans
9300 Customer
9301 \family default
9302 , and 
9303 \family sans
9304 Invoice
9305 \family default
9306  produce a business letter like line above the 
9307 \family sans
9308 Title
9309 \family default
9310  line containing the fields 
9311 \begin_inset Quotes eld
9312 \end_inset
9313
9314 Your ref.
9315 \begin_inset Quotes erd
9316 \end_inset
9317
9318
9319 \begin_inset Quotes eld
9320 \end_inset
9321
9322 Your letter of
9323 \begin_inset Quotes erd
9324 \end_inset
9325
9326
9327 \begin_inset Quotes eld
9328 \end_inset
9329
9330 Our ref.
9331 \begin_inset Quotes erd
9332 \end_inset
9333
9334
9335 \begin_inset Quotes eld
9336 \end_inset
9337
9338 Customer no.
9339 \begin_inset Quotes erd
9340 \end_inset
9341
9342
9343 \begin_inset Quotes eld
9344 \end_inset
9345
9346 Invoice no.
9347 \begin_inset Quotes erd
9348 \end_inset
9349
9350 , and 
9351 \begin_inset Quotes eld
9352 \end_inset
9353
9354 Date
9355 \begin_inset Quotes erd
9356 \end_inset
9357
9358 .
9359  For the date field, the value of the 
9360 \family sans
9361 Date
9362 \family default
9363  type is used.
9364  If one of these 
9365 \begin_inset Quotes eld
9366 \end_inset
9367
9368 business letter types
9369 \begin_inset Quotes erd
9370 \end_inset
9371
9372  is used, the value of the 
9373 \family sans
9374 Place
9375 \family default
9376  type however does not appear, but only the LaTeX variable 
9377 \family typewriter
9378
9379 \backslash
9380 fromplace
9381 \family default
9382  is set.
9383  The ordinary output of place and date in a right-aligned line below the
9384  addressee`s field is suppressed.
9385  The types are implemented as input types provided with a label and must
9386  be used ahead of the corresponding 
9387 \family sans
9388 Opening
9389 \family default
9390  type.
9391 \end_layout
9392
9393 \begin_layout Itemize
9394
9395
9396 \family sans
9397 Yourref
9398 \family default
9399 : Your ref.
9400 \end_layout
9401
9402 \begin_layout Itemize
9403
9404
9405 \family sans
9406 Yourmail
9407 \family default
9408 : Your letter of.
9409 \end_layout
9410
9411 \begin_layout Itemize
9412
9413
9414 \family sans
9415 Myref
9416 \family default
9417 : Our ref.
9418 \end_layout
9419
9420 \begin_layout Itemize
9421
9422
9423 \family sans
9424 Customer
9425 \family default
9426 : Customer no.
9427 \end_layout
9428
9429 \begin_layout Itemize
9430
9431
9432 \family sans
9433 Invoice
9434 \family default
9435 : Invoice no.
9436 \end_layout
9437
9438 \begin_layout Subsection
9439
9440 The new letter class: letter (koma-script v.2)
9441 \end_layout
9442
9443 \begin_layout Standard
9444
9445 by 
9446 \noun on
9447 Jürgen Spitzmüller
9448 \end_layout
9449
9450
9451 \begin_layout Standard
9452
9453
9454 \begin_inset VSpace medskip
9455 \end_inset
9456
9457
9458 \end_layout
9459
9460 \begin_layout Standard
9461 \noindent
9462 Koma-Script version 2.8 has introduced a new letter class 
9463 \family typewriter
9464 scrlttr2
9465 \family default
9466  which superceeds the now unsupported 
9467 \family typewriter
9468 scrlettr
9469 \family default
9470 .
9471  It has --- on the LaTeX side --- a completely new interface and is not
9472  compatible with the old class.
9473  Therefore, LyX supports both, though it is recommended to use the new class.
9474 \end_layout
9475
9476 \begin_layout Standard
9477
9478 This class covers the same functionality as 
9479 \emph on
9480 letter (koma-script),
9481 \emph default
9482  and a few more.
9483  The basic items are 
9484 \family sans
9485 Address
9486 \family default
9487  (receiver's address, same as 
9488 \family sans
9489 Letter
9490 \family default
9491  in the old layout), 
9492 \family sans
9493 Opening
9494 \family default
9495 , and 
9496 \family sans
9497 Closing
9498 \family default
9499 .
9500  
9501 \family sans
9502 NextAddress
9503 \family default
9504  will start a new letter (i.
9505 \begin_inset ERT
9506 status collapsed
9507
9508 \begin_layout Standard
9509
9510 \backslash
9511 ,
9512 \end_layout
9513
9514 \end_inset
9515
9516 e.
9517 \begin_inset ERT
9518 status collapsed
9519
9520 \begin_layout Standard
9521
9522 \backslash
9523  
9524 \end_layout
9525
9526 \end_inset
9527
9528 you can write several letters per document).
9529  New elements are sender's 
9530 \family sans
9531 E-Mail
9532 \family default
9533
9534 \family sans
9535 URL
9536 \family default
9537
9538 \family sans
9539 Fax
9540 \family default
9541
9542 \family sans
9543 Bank
9544 \family default
9545  and the possibility to use a 
9546 \family sans
9547 Logo
9548 \family default
9549  (via 
9550 \family sans
9551 \bar under
9552 I
9553 \bar default
9554 nsert\SpecialChar \menuseparator
9555
9556 \bar under
9557 G
9558 \bar default
9559 raphics
9560 \family default
9561 ) in the header.
9562 \end_layout
9563
9564 \begin_layout Standard
9565
9566 The biggest improvement is, though, that the letter's layout is configurable
9567  at almost any needs.
9568  This can be done via the preamble or with a special style file (Letter
9569  Class Option, extension 
9570 \family typewriter
9571 *.lco
9572 \family default
9573 ), that will be read in as a class option.
9574 \begin_inset Foot
9575 status collapsed
9576
9577 \begin_layout Standard
9578
9579 The KOMA package comes with some default 
9580 \family typewriter
9581 *.lco
9582 \family default
9583  files.
9584  There is, for instance, a 
9585 \family typewriter
9586 DIN.lco
9587 \family default
9588  file that follows german typesetting rules, or a 
9589 \family typewriter
9590 KOMAold.lco
9591 \family default
9592  that provides the default layout of the old 
9593 \family typewriter
9594 scrlettr
9595 \family default
9596  class.
9597  The latter can be loaded with the class option 
9598 \family typewriter
9599 KOMAold
9600 \family default
9601 , inserted via the 
9602 \family sans
9603 \bar under
9604 L
9605 \bar default
9606 ayout\SpecialChar \menuseparator
9607
9608 \bar under
9609 D
9610 \bar default
9611 ocument\SpecialChar \menuseparator
9612 Extra Options 
9613 \family default
9614 field.
9615 \end_layout
9616
9617 \end_inset
9618
9619  Have a look at the 
9620 \emph on
9621 koma-letter2
9622 \emph default
9623  template that is included in LyX for examples.
9624  A detailed description is to be found in the Koma-Script documentation
9625  (
9626 \emph on
9627 scrguide
9628 \emph default
9629 ).
9630 \end_layout
9631
9632 \begin_layout Subsection
9633
9634 Problems
9635 \end_layout
9636
9637 \begin_layout Standard
9638
9639 Visualizing the Koma-Script document classes in LyX, the LyX internals cause
9640  some problems.
9641 \end_layout
9642
9643 \begin_layout Itemize
9644
9645 The chapter number of a 
9646 \family sans
9647 Chapter
9648 \family default
9649  type appears on a line of its own above the chapter heading instead of
9650  appearing in the same line ahead of it.
9651  The cause for that is the LyX internal behavior for the labeltype 
9652 \family sans
9653 Counter_Chapter
9654 \family default
9655  in the layout file.
9656 \end_layout
9657
9658 \begin_layout Itemize
9659
9660 The headings of the types 
9661 \family sans
9662 Addchap
9663 \family default
9664  and 
9665 \family sans
9666 Addsec
9667 \family default
9668  are only put in the 
9669 \begin_inset Quotes eld
9670 \end_inset
9671
9672 true
9673 \begin_inset Quotes erd
9674 \end_inset
9675
9676  LaTeX table of contents, but not in the LyX table of contents (
9677 \family sans
9678 \bar under
9679 D
9680 \bar default
9681 ocument\SpecialChar \menuseparator
9682
9683 \bar under
9684 T
9685 \bar default
9686 able\InsetSpace ~
9687 of\InsetSpace ~
9688 Contents
9689 \family default
9690 ).
9691 \end_layout
9692
9693 \begin_layout Itemize
9694
9695 The paragraphs in a 
9696 \emph on
9697 letter
9698 \emph default
9699  document class appear in a skip separation mode, not indented.
9700  This is the standard behavior, no special LaTeX commands are needed for
9701  that.
9702  But in the 
9703 \family sans
9704 \bar under
9705 D
9706 \bar default
9707 ocument\SpecialChar \menuseparator
9708
9709 \bar under
9710 S
9711 \bar default
9712 ettings
9713 \family default
9714  dialog the corresponding radio button indicates 
9715 \family sans
9716 \bar under
9717 I
9718 \bar default
9719 ndent
9720 \family default
9721 .
9722  A 
9723 \family sans
9724 S
9725 \bar under
9726 k
9727 \bar default
9728 ip
9729 \family default
9730  value always has the effect that extra LaTeX commands are inserted in the
9731  document to produce the gap, which is not what is wanted in this case.
9732 \end_layout
9733
9734 \begin_layout Section
9735
9736 Springer Journals (
9737 \family sans
9738 svjour
9739 \family default
9740 )
9741 \end_layout
9742
9743 \begin_layout Standard
9744
9745 by 
9746 \noun on
9747 Martin Vermeer
9748 \end_layout
9749
9750 \begin_layout Subsection
9751
9752 Description
9753 \end_layout
9754
9755 \begin_layout Standard
9756
9757 These are the layout files for some of the journal formats used by Springer
9758  Verlag and listed on 
9759 \begin_inset LatexCommand \url{http://www.springer.de/author/tex/help-journals.html}
9760
9761 \end_inset
9762
9763 , where you should also go to fetch the class files (yes, these are LaTeX2e
9764  now!).
9765  It is a modular system: the things common to all journals are implemented
9766  in 
9767 \family typewriter
9768 svjour.inc
9769 \family default
9770 , which journal-specific layout files (such as, e.g., 
9771 \family typewriter
9772 svjog.layout
9773 \family default
9774  for Journal of Geodesy) can include.
9775 \end_layout
9776
9777 \begin_layout Standard
9778
9779 This means that implementing support for any other Springer journal on this
9780  list is as simple as writing your own 
9781 \family typewriter
9782 sv
9783 \family default
9784 <myjournal>
9785 \family typewriter
9786 .layout
9787 \family default
9788  file following the outline given in 
9789 \family typewriter
9790 svjog.layout
9791 \family default
9792 .
9793  
9794 \end_layout
9795
9796 \begin_layout Standard
9797
9798 It is reasonably well tested only for the Journal of Geodesy.
9799  
9800 \family typewriter
9801 svjour
9802 \family default
9803  and 
9804 \family typewriter
9805 svjog
9806 \family default
9807  come with the standard LyX distribution.
9808  Install the relevant class file (downloaded from Springer) in a proper
9809  directory, reconfigure LaTeX (in the teTeX case by running 
9810 \family typewriter
9811 texhash
9812 \family default
9813 , as root if necessary --- doesn't LyX take care of this?), reconfigure
9814  LyX and it should work.
9815 \end_layout
9816
9817 \begin_layout Subsection
9818
9819 New styles
9820 \end_layout
9821
9822 \begin_layout Standard
9823
9824 A large number of theorem-like styles --- 
9825 \family sans
9826 Claim, Conjecture,
9827 \family default
9828  
9829 \family sans
9830 \SpecialChar \ldots{}
9831 Theorem
9832 \family default
9833 .
9834 \end_layout
9835
9836 \begin_layout Standard
9837
9838
9839 \family sans
9840 Headnote, Dedication, Subtitle, Running_LaTeX_Title, Author_Running, Institute,
9841  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
9842 \family default
9843 .
9844  See the Springer class file documentation for details.
9845 \end_layout
9846
9847 \begin_layout Subsection
9848
9849 Supported journals
9850 \end_layout
9851
9852 \begin_layout Itemize
9853
9854
9855 \emph on
9856 Journal of Geodesy
9857 \emph default
9858
9859 \family typewriter
9860 svjog.layout 
9861 \family default
9862 --- Martin Vermeer
9863 \end_layout
9864
9865 \begin_layout Itemize
9866
9867
9868 \emph on
9869 Probability Theory and Related Fields
9870 \emph default
9871
9872 \family typewriter
9873 svprobth.layout
9874 \family default
9875  --- Jean-Marc Lasgouttes
9876 \end_layout
9877
9878 \begin_layout Standard
9879
9880 Add your own, it isn't so hard!
9881 \end_layout
9882
9883 \begin_layout Subsection
9884
9885 Credits
9886 \end_layout
9887
9888 \begin_layout Standard
9889
9890 These files are partly based on the older 
9891 \family typewriter
9892 ejour2.layout
9893 \family default
9894 , which was again based on a tinkered-with version of an old LaTeX 2.09 style
9895  file from Springer.
9896  All this, and the 
9897 \family typewriter
9898 ejour2
9899 \family default
9900  layout, are now defunct.
9901  Jean-Marc Lasgouttes helped out big in making me find my way around the
9902  LyX layout file mechanism.
9903 \end_layout
9904
9905 \begin_layout Subsection
9906
9907 Bugs
9908 \end_layout
9909
9910 \begin_layout Standard
9911
9912 Probably.
9913  But probably less than in the old hacked-LaTeX 
9914 \family typewriter
9915 ejour2
9916 \family default
9917 .
9918 \end_layout
9919
9920 \begin_layout Standard
9921
9922 Limitations e.g.: does not display the number for theorem-like layouts, just
9923  #.
9924 \end_layout
9925
9926 \begin_layout Section
9927
9928 AGU journals (
9929 \family sans
9930 aguplus
9931 \family default
9932 )
9933 \end_layout
9934
9935 \begin_layout Standard
9936
9937 by 
9938 \shape smallcaps
9939 Martin Vermeer
9940 \end_layout
9941
9942 \begin_layout Subsection
9943
9944 Description
9945 \end_layout
9946
9947 \begin_layout Standard
9948
9949 These are the layout files for some of the journals of the American Geophysical
9950  Society.
9951  It is assumed that you have both the AGU's own class files and AGUplus
9952  installed (everything to be found at
9953 \begin_inset LatexCommand \url{ftp://ftp.agu.org/journals/latex/journals}
9954
9955 \end_inset
9956
9957 ).
9958 \end_layout
9959
9960 \begin_layout Subsection
9961
9962 New styles
9963 \end_layout
9964
9965 \begin_layout Standard
9966
9967 Redefined are 
9968 \family sans
9969 Paragraph
9970 \family default
9971
9972 \family sans
9973 Paragraph*
9974 \family default
9975 .
9976  They are still called this in the LyX GUI, though their LaTeX equivalents
9977  in the AGU classes are 
9978 \family sans
9979 Subsubsubsection
9980 \family default
9981  and 
9982 \family sans
9983 Subsubsubsection*
9984 \family default
9985 .
9986 \end_layout
9987
9988 \begin_layout Standard
9989
9990 Newly defined styles are 
9991 \family sans
9992 Left_Header
9993 \family default
9994
9995 \family sans
9996 Right_Header
9997 \family default
9998
9999 \family sans
10000 Received
10001 \family default
10002
10003 \family sans
10004 Revised
10005 \family default
10006
10007 \family sans
10008 Accepted
10009 \family default
10010
10011 \family sans
10012 CCC
10013 \family default
10014
10015 \family sans
10016 PaperId
10017 \family default
10018
10019 \family sans
10020 AuthorAddr
10021 \family default
10022
10023 \family sans
10024 SlugComment
10025 \family default
10026 .
10027  These are mostly manuscript attributes and defined in the AGU class documentati
10028 on.
10029 \end_layout
10030
10031 \begin_layout Standard
10032
10033 I suspect this is still badly incomplete.
10034 \end_layout
10035
10036 \begin_layout Subsection
10037
10038 New floats
10039 \end_layout
10040
10041 \begin_layout Standard
10042
10043
10044 \family sans
10045 Planotable
10046 \family default
10047  and 
10048 \family sans
10049 Plate
10050 \family default
10051 .
10052  We also have a new 
10053 \family sans
10054 Table_Caption
10055 \family default
10056 .
10057 \end_layout
10058
10059 \begin_layout Subsection
10060
10061 Supported journals
10062 \end_layout
10063
10064 \begin_layout Itemize
10065
10066
10067 \emph on
10068 Journal of Geophysical Research
10069 \emph default
10070
10071 \family typewriter
10072 jgrga.layout 
10073 \family default
10074 --- Martin Vermeer
10075 \end_layout
10076
10077 \begin_layout Standard
10078
10079 Add your own, it isn't so hard! Look at the 
10080 \family typewriter
10081 jgrga.layout
10082 \family default
10083  example and 
10084 \family typewriter
10085 aguplus.inc
10086 \family default
10087 .
10088 \end_layout
10089
10090 \begin_layout Subsection
10091
10092 Bugs and things to remember
10093 \end_layout
10094
10095 \begin_layout Standard
10096
10097 In order to use the new layouts, you must remember to do the following for
10098  a new document:
10099 \end_layout
10100
10101 \begin_layout Enumerate
10102
10103
10104 \emph on
10105 Turn off babel
10106 \emph default
10107 .
10108  This can be done in the 
10109 \family sans
10110 layout\SpecialChar \menuseparator
10111 document
10112 \family default
10113  or 
10114 \family sans
10115 document\SpecialChar \menuseparator
10116 settings
10117 \family default
10118  menu item.
10119  (AGU articles are always in English, right? So 
10120 \emph on
10121 don't
10122 \emph default
10123  choose a language.)
10124 \end_layout
10125
10126 \begin_layout Enumerate
10127
10128 Enter 
10129 \family typewriter
10130 jgrga
10131 \family default
10132  into the document's 
10133 \family sans
10134 Extra Options
10135 \family default
10136  field.
10137  (Yes, this is a bug.)
10138 \end_layout
10139
10140 \begin_layout Enumerate
10141
10142 Make sure you use the 
10143 \family typewriter
10144 agu.bst
10145 \family default
10146  bibliography style, by entering 
10147 \family sans
10148 agu
10149 \family default
10150  into the second field of the BibTeX inset.
10151  None of the standard styles will do.
10152 \end_layout
10153
10154 \begin_layout Section
10155
10156 EGS journals (
10157 \family sans
10158 egs
10159 \family default
10160 )
10161 \end_layout
10162
10163 \begin_layout Standard
10164
10165 by 
10166 \shape smallcaps
10167 Martin Vermeer
10168 \end_layout
10169
10170 \begin_layout Subsection
10171
10172 Description
10173 \end_layout
10174
10175 \begin_layout Standard
10176
10177 This is the layout file for the European Geophysical Society journals.
10178  The needed 
10179 \family typewriter
10180 egs.cls
10181 \family default
10182  can be downloaded from the web site of the EGS under 
10183 \begin_inset LatexCommand \url{www.copernicus.org}
10184
10185 \end_inset
10186
10187 .
10188 \end_layout
10189
10190 \begin_layout Subsection
10191
10192 New styles
10193 \end_layout
10194
10195 \begin_layout Standard
10196
10197
10198 \family sans
10199 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
10200  Accepted
10201 \family default
10202
10203 \family sans
10204 Offsets
10205 \family default
10206 .
10207  The current layout file is unfortunately very unmodular and would benefit
10208  from using the various 
10209 \family typewriter
10210 std*.inc
10211 \family default
10212  file inclusions.
10213 \end_layout
10214
10215 \begin_layout Section
10216
10217 Slides [aka 
10218 \noun on
10219 Sli
10220 \noun default
10221 TeX]
10222 \begin_inset LatexCommand \label{sec:slitex}
10223
10224 \end_inset
10225
10226
10227 \end_layout
10228
10229 \begin_layout Standard
10230
10231 by 
10232 \noun on
10233 John Weiss
10234 \noun default
10235  
10236 \end_layout
10237
10238 \begin_layout Subsection
10239
10240 Introduction
10241 \end_layout
10242
10243 \begin_layout Standard
10244
10245 This section describes how to use LyX to make slides for overhead projectors.
10246  There are two document classes that can do this: the default slides class
10247  and the 
10248 \family sans
10249 Foil
10250 \family default
10251 TeX slides class.
10252  This section documents the former.
10253 \end_layout
10254
10255 \begin_layout Standard
10256
10257 I'm going to say this again, nice and clear, so that there's no misunderstanding
10258 :
10259 \end_layout
10260
10261
10262 \begin_layout Standard
10263
10264
10265 \begin_inset VSpace bigskip
10266 \end_inset
10267
10268
10269 \end_layout
10270
10271 \begin_layout Standard
10272 \align center
10273
10274 \size large
10275 This section documents the class 
10276 \begin_inset Quotes eld
10277 \end_inset
10278
10279
10280 \family sans
10281 slides (default)
10282 \family default
10283
10284 \begin_inset Quotes erd
10285 \end_inset
10286
10287  
10288 \emph on
10289 only.
10290 \end_layout
10291
10292 \begin_layout Standard
10293
10294
10295 \begin_inset VSpace bigskip
10296 \end_inset
10297
10298
10299 \end_layout
10300
10301
10302 \begin_layout Standard
10303
10304 If you're looking for the documentation for 
10305 \begin_inset Quotes eld
10306 \end_inset
10307
10308
10309 \family sans
10310 slides (FoilTeX)
10311 \family default
10312
10313 \begin_inset Quotes erd
10314 \end_inset
10315
10316 , check out section\InsetSpace ~
10317
10318 \begin_inset LatexCommand \ref{sec:foiltex}
10319
10320 \end_inset
10321
10322 .
10323  The 
10324 \family sans
10325 foils 
10326 \family default
10327 class [
10328 \begin_inset Quotes eld
10329 \end_inset
10330
10331
10332 \family sans
10333 slides (FoilTeX)
10334 \family default
10335
10336 \begin_inset Quotes erd
10337 \end_inset
10338
10339 ] is actually somewhat better than the default 
10340 \family sans
10341 slides
10342 \family default
10343  class,
10344 \begin_inset Foot
10345 status collapsed
10346
10347 \begin_layout Standard
10348
10349 \SpecialChar \ldots{}
10350 or so I've been told repeatedly by its advocates.
10351  Having never used it, I have no idea if this claim is true or not.
10352 \end_layout
10353
10354 \end_inset
10355
10356  which this section documents.
10357 \end_layout
10358
10359 \begin_layout Standard
10360
10361 This class is the LaTeX2e improvement of the old 
10362 \noun on
10363 Sli
10364 \noun default
10365 TeX package.
10366  Every LaTeX2e distribution includes this class [which I'll just refer to
10367  as 
10368 \begin_inset Quotes eld
10369 \end_inset
10370
10371
10372 \family sans
10373 slides
10374 \family default
10375
10376 \begin_inset Quotes erd
10377 \end_inset
10378
10379  from now on], so you're bound to have it.
10380  As I noted earlier, there are other classes, such as 
10381 \family sans
10382 foils
10383 \family default
10384 , which also produce slides for overhead projectors and do a better job
10385  at it.
10386  However, there are some things which 
10387 \family sans
10388 slides
10389 \family default
10390  can do which the others can't, such as generate overlays.
10391  Read on to learn more!
10392 \end_layout
10393
10394 \begin_layout Subsection
10395
10396 Getting Started
10397 \begin_inset LatexCommand \label{sec:slidesetup}
10398
10399 \end_inset
10400
10401
10402 \end_layout
10403
10404 \begin_layout Standard
10405
10406 Obviously, to use this document class, you need to select 
10407 \begin_inset Quotes eld
10408 \end_inset
10409
10410
10411 \family sans
10412 slides (default)
10413 \family default
10414
10415 \begin_inset Quotes erd
10416 \end_inset
10417
10418  from the class list in the 
10419 \family sans
10420 \bar under
10421 D
10422 \bar default
10423 ocument\SpecialChar \menuseparator
10424
10425 \bar under
10426 S
10427 \bar default
10428 ettings
10429 \family default
10430  dialog.
10431  There are some other special things you should know about this class:
10432 \end_layout
10433
10434 \begin_layout Itemize
10435
10436 Don't bother changing the options 
10437 \family sans
10438 Sides and Columns
10439 \family default
10440 .
10441  They're not supported by the 
10442 \family sans
10443 slides
10444 \family default
10445  class, anyways.
10446 \end_layout
10447
10448 \begin_layout Itemize
10449
10450 The option 
10451 \family sans
10452 \bar under
10453 P
10454 \bar default
10455 age\InsetSpace ~
10456 style
10457 \family default
10458  behaves a bit differently for this class.
10459  The possible choices and what they do are as follows:
10460 \end_layout
10461
10462 \begin_deeper
10463 \begin_layout Description
10464
10465
10466 \family sans
10467 plain
10468 \family default
10469  The final output contains page numbers in the lower right corner.
10470 \end_layout
10471
10472 \begin_layout Description
10473
10474
10475 \family sans
10476 headings
10477 \family default
10478  Like 
10479 \family sans
10480 plain
10481 \family default
10482 , but also prints out any time markers you've put in.
10483  This is the default.
10484 \end_layout
10485
10486 \begin_layout Description
10487
10488
10489 \family sans
10490 empty
10491 \family default
10492  The final output contains no page numbers, time markers, or alignment markers.
10493 \end_layout
10494 \end_deeper
10495 \begin_layout Itemize
10496
10497 The 
10498 \family sans
10499 slides
10500 \family default
10501  class has an extra option: 
10502 \family typewriter
10503 clock
10504 \family default
10505 .
10506  To use it, put 
10507 \begin_inset Quotes eld
10508 \end_inset
10509
10510
10511 \family typewriter
10512 clock
10513 \family default
10514
10515 \begin_inset Quotes erd
10516 \end_inset
10517
10518  in the extra class options.
10519 \end_layout
10520
10521 \begin_deeper
10522 \begin_layout Standard
10523
10524 Using this options allows you to add time markers to 
10525 \family sans
10526 Note
10527 \family default
10528 s.
10529  See section\InsetSpace ~
10530
10531 \begin_inset LatexCommand \ref{sec:slideNote}
10532
10533 \end_inset
10534
10535  for more details.
10536 \end_layout
10537 \end_deeper
10538 \begin_layout Standard
10539
10540 You can also use the template file 
10541 \begin_inset Quotes eld
10542 \end_inset
10543
10544
10545 \family typewriter
10546 slides.lyx
10547 \family default
10548
10549 \begin_inset Quotes erd
10550 \end_inset
10551
10552  to automatically set up a document to use the 
10553 \family sans
10554 slides 
10555 \family default
10556 class [using 
10557 \family sans
10558 \bar under
10559 F
10560 \bar default
10561 ile\SpecialChar \menuseparator
10562 New\InsetSpace ~
10563 from\InsetSpace ~
10564
10565 \bar under
10566 T
10567 \bar default
10568 emplate
10569 \family default
10570  to open your new document].
10571  The template file also contains some examples of the special paragraph
10572  environments used by this class.
10573  I'll describe those next.
10574 \end_layout
10575
10576 \begin_layout Subsection
10577
10578 Paragraph Environments
10579 \end_layout
10580
10581 \begin_layout Subsubsection
10582
10583 Supported Environments
10584 \end_layout
10585
10586 \begin_layout Standard
10587
10588 The first thing you'll notice when you start up a new 
10589 \family sans
10590 slides 
10591 \family default
10592 document is the font size and type: it's the equivalent of the size 
10593 \begin_inset Quotes eld
10594 \end_inset
10595
10596
10597 \family sans
10598 Largest
10599 \family default
10600
10601 \begin_inset Quotes erd
10602 \end_inset
10603
10604  in the 
10605 \family sans
10606 Sans\InsetSpace ~
10607 Serif
10608 \family default
10609  font.
10610  This is also what's used in the output.
10611  Think of this as a 
10612 \begin_inset Quotes eld
10613 \end_inset
10614
10615 visual cue
10616 \begin_inset Quotes erd
10617 \end_inset
10618
10619  to remind you that this is a slide.
10620  Your final slides will use a larger font; ergo, you'll have less space.
10621  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
10622 \end_layout
10623
10624 \begin_layout Standard
10625
10626 The next thing that becomes obvious is the changes to the paragraph environment
10627  pull-down box [at the far-left end of the toolbar].
10628  Most of the paragraph environments you're used to seeing are missing.
10629  There are also five new ones.
10630  That's because the 
10631 \family sans
10632 slides
10633 \family default
10634  class itself only supports certain paragraph environments:
10635 \end_layout
10636
10637 \begin_layout Itemize
10638
10639
10640 \family sans
10641 Standard
10642 \end_layout
10643
10644 \begin_layout Itemize
10645
10646
10647 \family sans
10648 Itemize
10649 \end_layout
10650
10651 \begin_layout Itemize
10652
10653
10654 \family sans
10655 Enumerate
10656 \end_layout
10657
10658 \begin_layout Itemize
10659
10660
10661 \family sans
10662 Description
10663 \end_layout
10664
10665 \begin_layout Itemize
10666
10667
10668 \family sans
10669 List
10670 \end_layout
10671
10672 \begin_layout Itemize
10673
10674
10675 \family sans
10676 Quotation
10677 \end_layout
10678
10679 \begin_layout Itemize
10680
10681
10682 \family sans
10683 Quote
10684 \end_layout
10685
10686 \begin_layout Itemize
10687
10688
10689 \family sans
10690 Verse
10691 \end_layout
10692
10693 \begin_layout Itemize
10694
10695
10696 \family sans
10697 Caption
10698 \end_layout
10699
10700 \begin_layout Itemize
10701
10702
10703 \family sans
10704 LyX-Code
10705 \end_layout
10706
10707 \begin_layout Itemize
10708
10709
10710 \family sans
10711 Comment
10712 \end_layout
10713
10714 \begin_layout Standard
10715
10716 All of the other standard environments, including the section-heading environmen
10717 ts, aren't used in the 
10718 \family sans
10719 slides
10720 \family default
10721  class.
10722 \end_layout
10723
10724 \begin_layout Standard
10725
10726 On the other hand, you'll notice the following new environments:
10727 \end_layout
10728
10729 \begin_layout Itemize
10730
10731
10732 \family sans
10733 Slide
10734 \end_layout
10735
10736 \begin_layout Itemize
10737
10738
10739 \family sans
10740 Overlay
10741 \end_layout
10742
10743 \begin_layout Itemize
10744
10745
10746 \family sans
10747 Note
10748 \end_layout
10749
10750 \begin_layout Itemize
10751
10752
10753 \family sans
10754 InvisibleText
10755 \end_layout
10756
10757 \begin_layout Itemize
10758
10759
10760 \family sans
10761 VisibleText
10762 \end_layout
10763
10764 \begin_layout Standard
10765
10766 These five are kind of quirky, due to a 
10767 \begin_inset Quotes eld
10768 \end_inset
10769
10770 feature
10771 \begin_inset Quotes erd
10772 \end_inset
10773
10774  in LyX.
10775  You see, LyX doesn't permit you to nest any other paragraph environment
10776  into an empty environment.
10777  Now, that's fine and dandy, but it means that you wouldn't be able to start
10778  a slide with anything except plain text.
10779  To deal with this, I've performed a little 
10780 \begin_inset Quotes eld
10781 \end_inset
10782
10783 LaTeX magic.
10784 \begin_inset Quotes erd
10785 \end_inset
10786
10787  
10788 \end_layout
10789
10790 \begin_layout Subsubsection
10791
10792 Quirks of the New Environments
10793 \begin_inset LatexCommand \label{sec:slideQuirk}
10794
10795 \end_inset
10796
10797
10798 \end_layout
10799
10800 \begin_layout Standard
10801
10802 All five of the new paragraph environments are somewhat quirky due to inherent
10803  limitiations in the current version of LyX.
10804  As I just mentioned, LyX forbids environments that begin with another environme
10805 nt.
10806  To get around this, the 
10807 \family sans
10808 Slide
10809 \family default
10810  environment isn't a paragraph environment as described in the 
10811 \emph on
10812 User's Guide
10813 \emph default
10814 .
10815  
10816 \end_layout
10817
10818 \begin_layout Standard
10819
10820 You should consider 
10821 \family sans
10822 Slide
10823 \family default
10824
10825 \family sans
10826 Overlay
10827 \family default
10828 , and 
10829 \family sans
10830 Note
10831 \family default
10832  to be 
10833 \begin_inset Quotes eld
10834 \end_inset
10835
10836 pseudo-environments.
10837 \begin_inset Quotes erd
10838 \end_inset
10839
10840  They look like a section heading or a 
10841 \begin_inset Quotes eld
10842 \end_inset
10843
10844
10845 \family sans
10846 Caption
10847 \family default
10848 ,
10849 \begin_inset Quotes erd
10850 \end_inset
10851
10852  but really begin a [and, if necessary, end the previous] paragraph environment.
10853  Likewise, treat 
10854 \family sans
10855 InvisibleText
10856 \family default
10857  and 
10858 \family sans
10859 VisibleText
10860 \family default
10861  as 
10862 \begin_inset Quotes eld
10863 \end_inset
10864
10865 pseudo-commands.
10866 \begin_inset Quotes erd
10867 \end_inset
10868
10869  These two perform some action.
10870 \end_layout
10871
10872 \begin_layout Standard
10873
10874 A common feature of all five environments, 
10875 \family sans
10876 Slide
10877 \family default
10878
10879 \family sans
10880 Overlay
10881 \family default
10882
10883 \family sans
10884 Note
10885 \family default
10886
10887 \family sans
10888 InvisibleText
10889 \family default
10890  and 
10891 \family sans
10892 VisibleText
10893 \family default
10894 , is a rather long-ish label.
10895  The text following this label --- ordinarily the contents of the paragraph
10896  environment --- is utterly irrelevant for 
10897 \family sans
10898 Slide
10899 \family default
10900
10901 \family sans
10902 Overlay
10903 \family default
10904
10905 \family sans
10906 Note
10907 \family default
10908
10909 \family sans
10910 InvisibleText
10911 \family default
10912  and 
10913 \family sans
10914 VisibleText
10915 \family default
10916 .
10917  LyX completely ignores it.
10918  In fact, you can leave these five environments completely empty.
10919  
10920 \end_layout
10921
10922 \begin_layout Standard
10923
10924 While you don't 
10925 \emph on
10926 have
10927 \emph default
10928  to put any text after the rather long-ish label, you might want to.
10929  This could be a short description of the contents of the 
10930 \family sans
10931 Slide
10932 \family default
10933 , for example.
10934  In that case, enter in your descriptive comment and hit 
10935 \family sans
10936 Return
10937 \family default
10938  as you normally would.
10939 \end_layout
10940
10941 \begin_layout Standard
10942
10943 If, on the other hand, you don't want to enter in any descriptive text,
10944  you'll hit another LyX quirk.
10945  LyX, like nature, abhors a vacuum, and will not let you start a new paragraph
10946  environment until you put something in the old one.
10947  So, do this:
10948 \end_layout
10949
10950 \begin_layout Itemize
10951
10952 Start entering the text that will 
10953 \emph on
10954 follow
10955 \emph default
10956  the new 
10957 \family sans
10958 Slide
10959 \family default
10960
10961 \family sans
10962 Overlay
10963 \family default
10964
10965 \family sans
10966 Note
10967 \family default
10968
10969 \family sans
10970 InvisibleText
10971 \family default
10972  or 
10973 \family sans
10974 VisibleText
10975 \family default
10976 .
10977  
10978 \end_layout
10979
10980 \begin_layout Itemize
10981
10982 Now move to the beginning of that paragraph.
10983  
10984 \end_layout
10985
10986 \begin_layout Itemize
10987
10988 Next, hit 
10989 \family sans
10990 Return
10991 \family default
10992 .
10993  
10994 \end_layout
10995
10996 \begin_layout Itemize
10997
10998 Finally, change this new, empty paragraph to a 
10999 \family sans
11000 Slide
11001 \family default
11002
11003 \family sans
11004 Overlay
11005 \family default
11006
11007 \family sans
11008 Note
11009 \family default
11010
11011 \family sans
11012 InvisibleText
11013 \family default
11014  or 
11015 \family sans
11016 VisibleText
11017 \family default
11018 .
11019  
11020 \end_layout
11021
11022 \begin_layout Standard
11023
11024 Some future version of LyX will, hopefully, resolve this quirkiness\SpecialChar \ldots{}
11025
11026 \end_layout
11027
11028 \begin_layout Subsection
11029
11030 Making a Presentation with 
11031 \family sans
11032 Slide
11033 \family default
11034 ,
11035 \family sans
11036  Overlay
11037 \family default
11038  and 
11039 \family sans
11040 Note
11041 \end_layout
11042
11043 \begin_layout Subsubsection
11044
11045 Using the 
11046 \family sans
11047 Slide
11048 \family default
11049  Environment
11050 \end_layout
11051
11052 \begin_layout Standard
11053
11054 If you're expecting this section to teach you how to actually make a presentatio
11055 n, you'll be sorely disappointed.
11056  Naturally, I'll describe all of the ways the 
11057 \family sans
11058 slides
11059 \family default
11060  class can assist you in preparing the materials for a presentation.
11061  Filling in the contents, however, is up to you.
11062  [Then again, that 
11063 \emph on
11064 is
11065 \emph default
11066  the LyX philosophy.]
11067 \end_layout
11068
11069 \begin_layout Standard
11070
11071 Choosing the 
11072 \family sans
11073 Slide
11074 \family default
11075  environment [in the manner described in section\InsetSpace ~
11076
11077 \begin_inset LatexCommand \ref{sec:slideQuirk}
11078
11079 \end_inset
11080
11081 ] tells LyX to begin a new slide [duh].
11082  The label for this environment/
11083 \begin_inset Quotes erd
11084 \end_inset
11085
11086 pseudo-command
11087 \begin_inset Quotes erd
11088 \end_inset
11089
11090  is an 
11091 \begin_inset Quotes eld
11092 \end_inset
11093
11094 ASCII line,
11095 \begin_inset Quotes erd
11096 \end_inset
11097
11098  in cool blue, followed by the label, 
11099 \begin_inset Quotes eld
11100 \end_inset
11101
11102 NewSlide:
11103 \begin_inset Quotes erd
11104 \end_inset
11105
11106 .
11107  Any text or paragraph environments that follow this one go on the new slide.
11108  It's that simple.
11109 \end_layout
11110
11111 \begin_layout Standard
11112
11113 Slides are probably the only time you'll need to forcibly end pages in LyX
11114  (this can be specified in the 
11115 \family sans
11116 Paragraph Layout
11117 \family default
11118  dialog).
11119  In fact, you'll want to, once you finish entering the contents of one slide.
11120  If you've entered more text than can physically fit on a slide, the extra
11121  overflows onto a new slide.
11122  I don't recommend doing this, however, since the overflow slide won't have
11123  any page number on it.
11124  Furthermore, it may interfere with any 
11125 \family sans
11126 Overlay
11127 \family default
11128  you've made to accompany the oversized 
11129 \family sans
11130 Slide
11131 \family default
11132 .
11133 \end_layout
11134
11135 \begin_layout Standard
11136
11137 The 
11138 \family sans
11139 Overlay
11140 \family default
11141  and 
11142 \family sans
11143 Note
11144 \family default
11145  environments work the same way as the 
11146 \family sans
11147 Slide 
11148 \family default
11149 environment.
11150  They both create an 
11151 \begin_inset Quotes eld
11152 \end_inset
11153
11154 ASCII line
11155 \begin_inset Quotes erd
11156 \end_inset
11157
11158  followed by a label [
11159 \begin_inset Quotes eld
11160 \end_inset
11161
11162 NewOverlay:
11163 \begin_inset Quotes erd
11164 \end_inset
11165
11166  and 
11167 \begin_inset Quotes eld
11168 \end_inset
11169
11170 NewNote:
11171 \begin_inset Quotes erd
11172 \end_inset
11173
11174 , respectively].
11175  The color is a stunning magenta instead of blue, and the 
11176 \begin_inset Quotes eld
11177 \end_inset
11178
11179 ASCII line
11180 \begin_inset Quotes erd
11181 \end_inset
11182
11183  will look different, in style and in length.
11184  The label fonts of all three also differ from one another.
11185 \end_layout
11186
11187 \begin_layout Standard
11188
11189 As with a 
11190 \family sans
11191 Slide
11192 \family default
11193 , if the contents of a 
11194 \family sans
11195 Note
11196 \family default
11197  or 
11198 \family sans
11199 Overlay
11200 \family default
11201  exceed the physical size of a slide or sheet of paper, the extra will overflow
11202  onto a new sheet.
11203  Again, you should avoid this.
11204  It defeats the whole purpose of 
11205 \family sans
11206 Note
11207 \family default
11208 s and 
11209 \family sans
11210 Overlay
11211 \family default
11212 s.
11213 \end_layout
11214
11215 \begin_layout Subsubsection
11216
11217 Using 
11218 \family sans
11219 Overlay
11220 \family default
11221  with 
11222 \family sans
11223 Slide
11224 \end_layout
11225
11226 \begin_layout Standard
11227
11228 The idea behind an 
11229 \family sans
11230 Overlay
11231 \family default
11232  is a slide that sits atop another slide.
11233  Perhaps you wish to discuss a figure on the main 
11234 \family sans
11235 Slide
11236 \family default
11237  before displaying the text associated with it.
11238  One way to accomplish this is tape a flap of dark paper over the part of
11239  the 
11240 \family sans
11241 Slide
11242 \family default
11243  you want to display later.
11244  This method fails, however, if you wish to overlap one graph with another,
11245  for example.
11246  You would then have to fumble while speaking to align the two separate,
11247  overlapping 
11248 \family sans
11249 Slide
11250 \family default
11251 s to align the two graphs.
11252  The use of an 
11253 \family sans
11254 Overlay
11255 \family default
11256  environment in both cases makes life much easier.
11257 \end_layout
11258
11259 \begin_layout Standard
11260
11261 Each 
11262 \family sans
11263 Overlay
11264 \family default
11265  receives the page number of its 
11266 \begin_inset Quotes eld
11267 \end_inset
11268
11269 parent
11270 \begin_inset Quotes erd
11271 \end_inset
11272
11273  
11274 \family sans
11275 Slide
11276 \family default
11277 , appended by 
11278 \begin_inset Quotes eld
11279 \end_inset
11280
11281
11282 \family typewriter
11283 -a
11284 \family default
11285
11286 \begin_inset Quotes erd
11287 \end_inset
11288
11289 .
11290 \begin_inset Foot
11291 status collapsed
11292
11293 \begin_layout Standard
11294
11295 Presumably, mutliple 
11296 \family sans
11297 Overlay
11298 \family default
11299 s would have 
11300 \begin_inset Quotes eld
11301 \end_inset
11302
11303
11304 \family typewriter
11305 -a
11306 \family default
11307
11308 \begin_inset Quotes erd
11309 \end_inset
11310
11311
11312 \begin_inset Quotes eld
11313 \end_inset
11314
11315
11316 \family typewriter
11317 -b
11318 \family default
11319
11320 \begin_inset Quotes erd
11321 \end_inset
11322
11323
11324 \begin_inset Quotes eld
11325 \end_inset
11326
11327
11328 \family typewriter
11329 -c
11330 \family default
11331
11332 \begin_inset Quotes erd
11333 \end_inset
11334
11335 , etc.\InsetSpace ~
11336 appended to the page number of the parent 
11337 \family sans
11338 Slide
11339 \family default
11340 .
11341  
11342 \end_layout
11343
11344 \end_inset
11345
11346  Clearly, you want the contents of both the 
11347 \family sans
11348 Slide
11349 \family default
11350  and the 
11351 \family sans
11352 Overlay
11353 \family default
11354  to each fit on a single physical slide! You should probably consider an
11355  
11356 \family sans
11357 Overlay
11358 \family default
11359  as 
11360 \begin_inset Quotes eld
11361 \end_inset
11362
11363 part of
11364 \begin_inset Quotes erd
11365 \end_inset
11366
11367  a 
11368 \family sans
11369 Slide
11370 \family default
11371 .
11372  Indeed, the LyX 
11373 \family sans
11374 slides
11375 \family default
11376  class provides a visual cue for this: the label at the start of an 
11377 \family sans
11378 Overlay
11379 \family default
11380  is shorter than that at the start of a 
11381 \family sans
11382 Slide
11383 \family default
11384 .
11385  Lastly, when you generate printable output, you'll find alignment markers
11386  in all four corners of both the 
11387 \family sans
11388 Overlay
11389 \family default
11390  page and its parent 
11391 \family sans
11392 Slide
11393 \family default
11394 .
11395  These will assist you in lining up the two physical slides.
11396 \end_layout
11397
11398 \begin_layout Standard
11399
11400 The major problem in overlaying two slides is aligning the contents of the
11401  two transparencies.
11402  How much space should you leave for that graph on the second slide? Worse
11403  still, what if you want a graph and a sentence on second slide, but there
11404  is text on the main transparency that goes in between them? You could try
11405  and insert vertical space of the right size.
11406  The better way is to use 
11407 \family sans
11408 InvisibleText
11409 \family default
11410  and 
11411 \family sans
11412 VisibleText
11413 \family default
11414 .
11415 \end_layout
11416
11417 \begin_layout Standard
11418
11419 As their names imply, 
11420 \family sans
11421 InvisibleText
11422 \family default
11423  and 
11424 \family sans
11425 VisibleText
11426 \family default
11427  are two command-like paragraph environments that make all subsequent text
11428  invisible and visible, respectively.
11429  Note from section\InsetSpace ~
11430
11431 \begin_inset LatexCommand \ref{sec:slideQuirk}
11432
11433 \end_inset
11434
11435  that you don't place anything 
11436 \emph on
11437 into
11438 \emph default
11439  these two environments, however.
11440  When you create an 
11441 \family sans
11442 InvisibleText
11443 \family default
11444 , it inserts a centered, sky-blue label into the page reading 
11445 \begin_inset Quotes eld
11446 \end_inset
11447
11448 <Invisible Text Follows>
11449 \begin_inset Quotes erd
11450 \end_inset
11451
11452 .
11453  For paragraphs following this label, the parts of the 
11454 \family sans
11455 Slide
11456 \family default
11457  [or 
11458 \family sans
11459 Overlay
11460 \family default
11461 ; it doesn't matter which] where they would be contain instead blank space.
11462  
11463 \end_layout
11464
11465 \begin_layout Standard
11466
11467 For 
11468 \family sans
11469 VisibleText
11470 \family default
11471 , the corresponding centered label is 
11472 \begin_inset Quotes eld
11473 \end_inset
11474
11475 <Visible Text Follows>
11476 \begin_inset Quotes erd
11477 \end_inset
11478
11479  in blazing green.
11480  Paragraphs following this label behave normally.
11481  Note that the beginning of a new 
11482 \family sans
11483 Slide
11484 \family default
11485
11486 \family sans
11487 Overlay
11488 \family default
11489 , or 
11490 \family sans
11491 Note
11492 \family default
11493  automatically shuts off an 
11494 \family sans
11495 InvisibleText
11496 \family default
11497 .
11498  It's therefore not necessary to use 
11499 \family sans
11500 VisibleText
11501 \family default
11502  at the end of a 
11503 \family sans
11504 Slide
11505 \family default
11506 .
11507 \end_layout
11508
11509 \begin_layout Standard
11510
11511 By now, it should be obvious how to create overlay transparencies using
11512  the proper combination of 
11513 \family sans
11514 InvisibleText
11515 \family default
11516  and 
11517 \family sans
11518 VisibleText
11519 \family default
11520  on a 
11521 \family sans
11522 Slide
11523 \family default
11524  and 
11525 \family sans
11526 Overlay
11527 \family default
11528 :
11529 \end_layout
11530
11531 \begin_layout Enumerate
11532
11533 Create a 
11534 \family sans
11535 Slide
11536 \family default
11537 , including everything that will appear on it, whether on the main slide
11538  or on the 
11539 \family sans
11540 Overlay
11541 \family default
11542 .
11543 \end_layout
11544
11545 \begin_layout Enumerate
11546
11547 Before each figure or paragraph that will appear only on the 
11548 \family sans
11549 Overlay
11550 \family default
11551 , insert an 
11552 \family sans
11553 InvisibleText
11554 \family default
11555  environment.
11556  If necessary, insert a 
11557 \family sans
11558 VisibleText
11559 \family default
11560  environment after the 
11561 \family sans
11562 Overlay
11563 \family default
11564 -only text.
11565 \end_layout
11566
11567 \begin_layout Enumerate
11568
11569 Start an 
11570 \family sans
11571 Overlay
11572 \family default
11573  immediately following the 
11574 \family sans
11575 Slide
11576 \family default
11577 .
11578 \end_layout
11579
11580 \begin_layout Enumerate
11581
11582 Copy the contents of this 
11583 \family sans
11584 Slide
11585 \family default
11586  into the 
11587 \family sans
11588 Overlay
11589 \family default
11590 .
11591 \end_layout
11592
11593 \begin_layout Enumerate
11594
11595 Within the 
11596 \family sans
11597 Overlay
11598 \family default
11599 , change all of the 
11600 \family sans
11601 InvisibleText
11602 \family default
11603  lines to 
11604 \family sans
11605 VisibleText
11606 \family default
11607  and vice-versa.
11608 \end_layout
11609
11610 \begin_layout Standard
11611
11612 That's it.
11613  You've just made an 
11614 \family sans
11615 Overlay
11616 \family default
11617 .
11618 \end_layout
11619
11620 \begin_layout Standard
11621
11622 There's one problem with the way I've designed the LyX 
11623 \family sans
11624 slides
11625 \family default
11626  class: you can't make text in the middle of a paragraph invisible, nor
11627  make text in the middle of an invisible paragraph visible again.
11628  To accomplish this feat, you'll need to use some inlined LaTeX codes.
11629 \begin_inset Foot
11630 status collapsed
11631
11632 \begin_layout Standard
11633
11634 The commands of interest are: 
11635 \end_layout
11636
11637 \begin_layout Itemize
11638
11639
11640 \family typewriter
11641 {
11642 \backslash
11643 invisible \SpecialChar \ldots{}
11644  }
11645 \end_layout
11646
11647 \begin_layout Itemize
11648
11649
11650 \family typewriter
11651 {
11652 \backslash
11653 visible \SpecialChar \ldots{}
11654  }
11655 \end_layout
11656
11657 \begin_layout Standard
11658
11659 \SpecialChar \ldots{}
11660 and need to be marked as TeX.
11661  The text whose 
11662 \begin_inset Quotes eld
11663 \end_inset
11664
11665 visibility
11666 \begin_inset Quotes erd
11667 \end_inset
11668
11669  you wish to change goes in between the brackets [and after the 
11670 \family typewriter
11671
11672 \backslash
11673 invisible
11674 \family default
11675  or 
11676 \family typewriter
11677
11678 \backslash
11679 visible
11680 \family default
11681  command].
11682  If you don't know how to mark text as TeX, see the apprpriate section of
11683  the 
11684 \emph on
11685 User's Guide
11686 \emph default
11687 .
11688 \end_layout
11689
11690 \end_inset
11691
11692
11693 \end_layout
11694
11695 \begin_layout Subsubsection
11696
11697 Using 
11698 \family sans
11699 Note
11700 \family default
11701  with 
11702 \family sans
11703 Slide
11704 \family default
11705
11706 \begin_inset LatexCommand \label{sec:slideNote}
11707
11708 \end_inset
11709
11710
11711 \end_layout
11712
11713 \begin_layout Standard
11714
11715 Like an 
11716 \family sans
11717 Overlay
11718 \family default
11719 , a 
11720 \family sans
11721 Note
11722 \family default
11723  is associated with a 
11724 \begin_inset Quotes eld
11725 \end_inset
11726
11727 parent
11728 \begin_inset Quotes erd
11729 \end_inset
11730
11731  
11732 \family sans
11733 Slide
11734 \family default
11735 .
11736  Here, too, the LyX 
11737 \family sans
11738 slides
11739 \family default
11740  class provides visual cues.
11741  The label for a 
11742 \family sans
11743 Note
11744 \family default
11745  is shorter than that of a 
11746 \family sans
11747 Slide
11748 \family default
11749  [yet longer than that of an 
11750 \family sans
11751 Overlay
11752 \family default
11753 ] and, like the label of an 
11754 \family sans
11755 Overlay
11756 \family default
11757  is shockingly magenta.
11758  Additionally, the printed 
11759 \family sans
11760 Note
11761 \family default
11762  has the page number of its 
11763 \begin_inset Quotes eld
11764 \end_inset
11765
11766 parent
11767 \begin_inset Quotes erd
11768 \end_inset
11769
11770  
11771 \family sans
11772 Slide
11773 \family default
11774 , appended by 
11775 \begin_inset Quotes eld
11776 \end_inset
11777
11778
11779 \family typewriter
11780 -
11781 \family default
11782 1
11783 \begin_inset Quotes erd
11784 \end_inset
11785
11786
11787 \begin_inset Quotes eld
11788 \end_inset
11789
11790
11791 \family typewriter
11792 -
11793 \family default
11794 2
11795 \begin_inset Quotes erd
11796 \end_inset
11797
11798
11799 \begin_inset Quotes eld
11800 \end_inset
11801
11802
11803 \family typewriter
11804 -
11805 \family default
11806 3
11807 \begin_inset Quotes erd
11808 \end_inset
11809
11810 , etc.
11811  You can have multiple 
11812 \family sans
11813 Note
11814 \family default
11815 s associated with a single 
11816 \family sans
11817 Slide
11818 \family default
11819 , and, as with 
11820 \family sans
11821 Slide
11822 \family default
11823  and 
11824 \family sans
11825 Overlay
11826 \family default
11827 , you'll probably want to break up long 
11828 \family sans
11829 Note
11830 \family default
11831 s so that they fit on a single sheet of paper.
11832 \end_layout
11833
11834 \begin_layout Standard
11835
11836 The purpose of a 
11837 \family sans
11838 Note
11839 \family default
11840  is obvious: it contains anything additional you might want to say about
11841  a 
11842 \family sans
11843 Slide
11844 \family default
11845 .
11846  It could also be used as a sheet of reminders for a particular 
11847 \family sans
11848 Slide
11849 \family default
11850 .
11851  In the case of the latter, you might want to make use of time markers.
11852  Currently, the LyX 
11853 \family sans
11854 slides
11855 \family default
11856  class has no 
11857 \begin_inset Quotes eld
11858 \end_inset
11859
11860 native
11861 \begin_inset Quotes erd
11862 \end_inset
11863
11864  support for time markers, a 
11865 \noun on
11866 Sli
11867 \noun default
11868 TeX feature.
11869  So, you'll have to resort to using the LaTeX codes.
11870 \end_layout
11871
11872 \begin_layout Standard
11873
11874 To use time markers, you'll need to specify the extra class option 
11875 \begin_inset Quotes eld
11876 \end_inset
11877
11878
11879 \family typewriter
11880 clock
11881 \family default
11882
11883 \begin_inset Quotes erd
11884 \end_inset
11885
11886  [see section\InsetSpace ~
11887
11888 \begin_inset LatexCommand \ref{sec:slidesetup}
11889
11890 \end_inset
11891
11892 ].
11893  This option turns on timing marks, which will appear in the lower-left-hand
11894  corner of every 
11895 \family sans
11896 Note
11897 \family default
11898  you generate.
11899  To set what appears in the time marker, you use the LaTeX commands 
11900 \begin_inset Quotes eld
11901 \end_inset
11902
11903
11904 \family typewriter
11905
11906 \backslash
11907 settime{}
11908 \family default
11909
11910 \begin_inset Quotes erd
11911 \end_inset
11912
11913  and 
11914 \begin_inset Quotes eld
11915 \end_inset
11916
11917
11918 \family typewriter
11919
11920 \backslash
11921 addtime{}
11922 \family default
11923
11924 \begin_inset Quotes erd
11925 \end_inset
11926
11927 .
11928  The arguments of both commands are time measured in seconds.
11929  
11930 \begin_inset Quotes eld
11931 \end_inset
11932
11933
11934 \family typewriter
11935
11936 \backslash
11937 settime{}
11938 \family default
11939
11940 \begin_inset Quotes erd
11941 \end_inset
11942
11943  sets the time marker to a given time.
11944  
11945 \begin_inset Quotes eld
11946 \end_inset
11947
11948
11949 \family typewriter
11950
11951 \backslash
11952 addtime{}
11953 \family default
11954
11955 \begin_inset Quotes erd
11956 \end_inset
11957
11958  increments the time marker by the specified amount.
11959  Using time markers and 
11960 \family sans
11961 Note
11962 \family default
11963 s in this fashion, you can remind yourself how much time to spend on a particula
11964
11965 \family sans
11966 Slide
11967 \family default
11968 .
11969 \end_layout
11970
11971 \begin_layout Standard
11972
11973 There's one last feature to describe.
11974  Clearly, you'd like to print out all of your 
11975 \family sans
11976 Slide
11977 \family default
11978 s and 
11979 \family sans
11980 Overlay
11981 \family default
11982 s on transparencies while printing all of your 
11983 \family sans
11984 Note
11985 \family default
11986 s on plain paper.
11987  However, a 
11988 \family sans
11989 Note
11990 \family default
11991  
11992 \emph on
11993 must
11994 \emph default
11995  follow the 
11996 \family sans
11997 Slide
11998 \family default
11999  with which it is associated.
12000  What's a person to do?
12001 \end_layout
12002
12003 \begin_layout Standard
12004
12005 Luckily, there are two LaTeX commands that allow you to select what to print
12006  out.
12007  Both must be placed into the preamble of your document.
12008  The command 
12009 \begin_inset Quotes eld
12010 \end_inset
12011
12012
12013 \family typewriter
12014
12015 \backslash
12016 onlyslides{
12017 \backslash
12018 slides}
12019 \family default
12020
12021 \begin_inset Quotes erd
12022 \end_inset
12023
12024  will cause the output to contain only the 
12025 \family sans
12026 Slide
12027 \family default
12028 s and 
12029 \family sans
12030 Overlay
12031 \family default
12032 s.
12033  Correspondingly, the command 
12034 \begin_inset Quotes eld
12035 \end_inset
12036
12037
12038 \family typewriter
12039
12040 \backslash
12041 onlynotes{
12042 \backslash
12043 notes}
12044 \family default
12045
12046 \begin_inset Quotes erd
12047 \end_inset
12048
12049  prevents the output of anything but 
12050 \family sans
12051 Note
12052 \family default
12053 s.
12054  I'd advise placing both commands in the preamble and initially comment
12055  both out.
12056  You can then preview your entire presentation as you write.
12057  When you're done writing, you can then uncomment one of the two to select
12058  what you want to print.
12059  I like to uncomment 
12060 \begin_inset Quotes eld
12061 \end_inset
12062
12063
12064 \family typewriter
12065
12066 \backslash
12067 onlyslides{
12068 \backslash
12069 slides}
12070 \family default
12071
12072 \begin_inset Quotes erd
12073 \end_inset
12074
12075  , print to a file with 
12076 \begin_inset Quotes eld
12077 \end_inset
12078
12079
12080 \family typewriter
12081 -slides
12082 \family default
12083
12084 \begin_inset Quotes erd
12085 \end_inset
12086
12087  in its name, comment it back out, then uncomment 
12088 \begin_inset Quotes eld
12089 \end_inset
12090
12091
12092 \family typewriter
12093
12094 \backslash
12095 onlynotes{
12096 \backslash
12097 notes}
12098 \family default
12099
12100 \begin_inset Quotes erd
12101 \end_inset
12102
12103  and print to a 
12104 \begin_inset Quotes eld
12105 \end_inset
12106
12107
12108 \family typewriter
12109 *-notes.ps
12110 \family default
12111
12112 \begin_inset Quotes erd
12113 \end_inset
12114
12115  file.
12116  I can then send either file to a printer, loading transparencies or plain
12117  paper as appropriate.
12118 \end_layout
12119
12120 \begin_layout Standard
12121
12122 You can also provide other arguments to the 
12123 \begin_inset Quotes eld
12124 \end_inset
12125
12126
12127 \family typewriter
12128
12129 \backslash
12130 onlyslides{}
12131 \family default
12132
12133 \begin_inset Quotes erd
12134 \end_inset
12135
12136  and 
12137 \begin_inset Quotes eld
12138 \end_inset
12139
12140
12141 \family typewriter
12142
12143 \backslash
12144 onlynotes{}
12145 \family default
12146
12147 \begin_inset Quotes erd
12148 \end_inset
12149
12150  commands.
12151  See a good LaTeX book for details.
12152 \end_layout
12153
12154 \begin_layout Subsection
12155
12156 The 
12157 \family sans
12158 slides
12159 \family default
12160  Class Template File
12161 \end_layout
12162
12163 \begin_layout Standard
12164
12165 I have also provided a template file, 
12166 \begin_inset Quotes eld
12167 \end_inset
12168
12169
12170 \family typewriter
12171 slides.lyx
12172 \family default
12173
12174 \begin_inset Quotes erd
12175 \end_inset
12176
12177 , with the 
12178 \family sans
12179 slides
12180 \family default
12181  class.
12182  To use it, begin your new presentation with 
12183 \family sans
12184 \bar under
12185 F
12186 \bar default
12187 ile\SpecialChar \menuseparator
12188 New\InsetSpace ~
12189 from\InsetSpace ~
12190
12191 \bar under
12192 T
12193 \bar default
12194 emplate
12195 \family default
12196 .
12197  Your new LyX presentation file will contain an example 
12198 \family sans
12199 Slide
12200 \family default
12201  -- 
12202 \family sans
12203 Overlay
12204 \family default
12205  --
12206 \family sans
12207  Note
12208 \family default
12209  triplet.
12210  The 
12211 \family sans
12212 Slide
12213 \family default
12214  and 
12215 \family sans
12216 Overlay
12217 \family default
12218  additionally contain an example of the use of 
12219 \family sans
12220 InvisibleText
12221 \family default
12222  and 
12223 \family sans
12224 VisibleText
12225 \family default
12226 .
12227  Lastly, the preamble will contain:
12228 \end_layout
12229
12230 \begin_layout LyX-Code
12231
12232 % Uncomment to print out only slides and overlays
12233 \end_layout
12234
12235 \begin_layout LyX-Code
12236
12237 %
12238 \end_layout
12239
12240 \begin_layout LyX-Code
12241
12242 %
12243 \backslash
12244 onlyslides{
12245 \backslash
12246 slides}
12247 \newline
12248  
12249 \end_layout
12250
12251 \begin_layout LyX-Code
12252
12253 % Uncomment to print out only notes
12254 \end_layout
12255
12256 \begin_layout LyX-Code
12257
12258 %
12259 \end_layout
12260
12261 \begin_layout LyX-Code
12262
12263 %
12264 \backslash
12265 onlynotes{
12266 \backslash
12267 notes}
12268 \end_layout
12269
12270 \begin_layout Standard
12271
12272 One final thing: I created this class to support the LaTeX2e 
12273 \begin_inset Quotes eld
12274 \end_inset
12275
12276
12277 \noun on
12278 Sli
12279 \noun default
12280 TeX emulation
12281 \begin_inset Quotes erd
12282 \end_inset
12283
12284  class, one of the built-in LaTeX2e classes.
12285  Neither I nor the rest of the LyX Team endorse or oppose the use of this
12286  built-in slide class.
12287  It's here if you want it or need it.
12288  There exist other LaTeX2e classes for creating presentations, such as the
12289  
12290 \family sans
12291 Foils
12292 \family default
12293  class [see section\InsetSpace ~
12294
12295 \begin_inset LatexCommand \ref{sec:foiltex}
12296
12297 \end_inset
12298
12299 ] or the 
12300 \begin_inset Quotes eld
12301 \end_inset
12302
12303
12304 \family typewriter
12305 seminar
12306 \family default
12307
12308 \begin_inset Quotes erd
12309 \end_inset
12310
12311  package [present on some TeX distributions].
12312  The latter is not yet supported under LyX.
12313 \begin_inset Foot
12314 status collapsed
12315
12316 \begin_layout Standard
12317
12318 Perhaps you can take on the task\SpecialChar \ldots{}
12319
12320 \end_layout
12321
12322 \end_inset
12323
12324  I know nothing about these other classes.
12325  Try them out to see what sort of alternative they provide.
12326 \end_layout
12327
12328 \begin_layout Section
12329
12330 Foils [aka 
12331 \family sans
12332 Foil
12333 \family default
12334 \noun on
12335 TeX
12336 \noun default
12337 ]
12338 \begin_inset LatexCommand \label{sec:foiltex}
12339
12340 \end_inset
12341
12342
12343 \end_layout
12344
12345 \begin_layout Standard
12346
12347 by 
12348 \noun on
12349 Allan Rae
12350 \end_layout
12351
12352 \begin_layout Subsection
12353
12354 Introduction
12355 \end_layout
12356
12357 \begin_layout Standard
12358
12359 This section describes how to use LyX to make slides for overhead projectors.
12360  There are two document classes that can do this: the default slides class
12361  and the 
12362 \family sans
12363 Foil
12364 \family default
12365 TeX slides class.
12366  This section documents the latter.
12367 \end_layout
12368
12369 \begin_layout Standard
12370
12371 I'm going to say this again, nice and clear, so that there's no misunderstanding
12372 :
12373 \end_layout
12374
12375
12376 \begin_layout Standard
12377
12378
12379 \begin_inset VSpace bigskip
12380 \end_inset
12381
12382
12383 \end_layout
12384
12385 \begin_layout Standard
12386 \align center
12387
12388 \size large
12389 This section documents the class 
12390 \begin_inset Quotes eld
12391 \end_inset
12392
12393
12394 \family sans
12395 slides (FoilTeX)
12396 \family default
12397
12398 \begin_inset Quotes erd
12399 \end_inset
12400
12401  
12402 \emph on
12403 only.
12404 \end_layout
12405
12406 \begin_layout Standard
12407
12408
12409 \begin_inset VSpace bigskip
12410 \end_inset
12411
12412
12413 \end_layout
12414
12415
12416 \begin_layout Standard
12417
12418 If you're looking for the documentation for 
12419 \begin_inset Quotes eld
12420 \end_inset
12421
12422
12423 \family sans
12424 slides (default)
12425 \family default
12426
12427 \begin_inset Quotes erd
12428 \end_inset
12429
12430 , check out section\InsetSpace ~
12431
12432 \begin_inset LatexCommand \ref{sec:slitex}
12433
12434 \end_inset
12435
12436 .
12437  If your machine doesn't have the 
12438 \family sans
12439 foils 
12440 \family default
12441 class [
12442 \begin_inset Quotes eld
12443 \end_inset
12444
12445
12446 \family sans
12447 slides (FoilTeX)
12448 \family default
12449
12450 \begin_inset Quotes erd
12451 \end_inset
12452
12453 ] installed, you'll probably have to use the default 
12454 \family sans
12455 slides
12456 \family default
12457  class, which isn't quite as good as 
12458 \family sans
12459 foils.
12460 \end_layout
12461
12462 \begin_layout Standard
12463
12464 The 
12465 \family sans
12466 foils
12467 \family default
12468  class is designed for use with version 2.1 of the 
12469 \family sans
12470 foils.cls
12471 \family default
12472  LaTeX class file which is now an integral part of LaTeX2e.
12473 \end_layout
12474
12475 \begin_layout Subsection
12476
12477 Getting Started
12478 \end_layout
12479
12480 \begin_layout Standard
12481
12482 Obviously, to use this document class, you need to select 
12483 \begin_inset Quotes eld
12484 \end_inset
12485
12486
12487 \family sans
12488 slides (FoilTeX)
12489 \family default
12490
12491 \begin_inset Quotes erd
12492 \end_inset
12493
12494  from the 
12495 \family sans
12496 \bar under
12497 C
12498 \bar default
12499 lass
12500 \family default
12501  entry in the 
12502 \family sans
12503 Document\InsetSpace ~
12504 Layout
12505 \family default
12506  dialog.
12507  There are some settings in the 
12508 \family sans
12509 Document\InsetSpace ~
12510 Layout
12511 \family default
12512  dialog that you should know about that are specific to this class:
12513 \end_layout
12514
12515 \begin_layout Itemize
12516
12517 Don't change the options 
12518 \family sans
12519 Sides
12520 \family default
12521  and 
12522 \family sans
12523 Columns
12524 \family default
12525  on the 
12526 \family sans
12527 Document\InsetSpace ~
12528 Layout
12529 \family default
12530  dialog.
12531  They're ignored by the 
12532 \family sans
12533 foils
12534 \family default
12535  class.
12536 \end_layout
12537
12538 \begin_layout Itemize
12539
12540 The default font size is 20pt with the other options being 17pt, 25pt and
12541  30pt.
12542 \end_layout
12543
12544 \begin_layout Itemize
12545
12546 The default font is 
12547 \family sans
12548 sans
12549 \family default
12550  
12551 \family sans
12552 serif
12553 \family default
12554  but all math equations are still typeset in the usual roman font.
12555 \end_layout
12556
12557 \begin_layout Itemize
12558
12559
12560 \family sans
12561 Foil
12562 \family default
12563 TeX supports A4 and Letter paper sizes as well as a special size for working
12564  with 35mm slides.
12565  It doesn't support A5, B5, legal or executive paper sizes.
12566 \end_layout
12567
12568 \begin_layout Itemize
12569
12570 Don't bother changing the 
12571 \family sans
12572 Float Placement
12573 \family default
12574  settings because they are ignored anyway.
12575  All floats appear where they are defined in the text.
12576 \end_layout
12577
12578 \begin_layout Itemize
12579
12580 The 
12581 \family sans
12582 \bar under
12583 P
12584 \bar default
12585 agestyle
12586 \family default
12587  setting behaves a bit differently for this class.
12588  
12589 \family sans
12590 Foil
12591 \family default
12592 TeX provides extensive footer and header capabilities including a user-defined
12593  logo.
12594  See section\InsetSpace ~
12595
12596 \begin_inset LatexCommand \ref{sec:foilfoot}
12597
12598 \end_inset
12599
12600  for more details.
12601  The title page is treated differently to all other pages in the document
12602  and is 
12603 \emph on
12604 always
12605 \emph default
12606  unnumbered and 
12607 \emph on
12608 always
12609 \emph default
12610  has the logo centered at the bottom of the page (if one is defined).
12611  The possible page style choices and what they do are as follows:
12612 \end_layout
12613
12614 \begin_deeper
12615 \begin_layout List
12616 \labelwidthstring MMMMMMM
12617
12618
12619 \family sans
12620 \series bold
12621 empty
12622 \family default
12623 \series default
12624  The final output contains no page numbers, or other headers or footers
12625  (except footnotes of course).
12626  
12627 \end_layout
12628
12629 \begin_layout List
12630 \labelwidthstring MMMMMMM
12631
12632
12633 \family sans
12634 \series bold
12635 plain
12636 \family default
12637 \series default
12638  The final output contains page numbers centered at the bottom of the page.
12639  No other headings or footers (other than footnotes).
12640 \end_layout
12641
12642 \begin_layout List
12643 \labelwidthstring MMMMMMM
12644
12645
12646 \series bold
12647 foilheadings
12648 \series default
12649  Page numbers in lower right corner.
12650  Additional headers and footers are also shown.
12651  This is also the default.
12652 \end_layout
12653
12654 \begin_layout List
12655 \labelwidthstring MMMMMMM
12656
12657
12658 \series bold
12659 fancy
12660 \series default
12661  Gives you access to the 
12662 \family sans
12663 fancyheadings
12664 \family default
12665  package although its use with 
12666 \family sans
12667 Foil
12668 \family default
12669 TeX is discouraged by the writer of the 
12670 \family sans
12671 Foil
12672 \family default
12673 TeX package because of some potential page layout clashes.
12674 \end_layout
12675 \end_deeper
12676 \begin_layout Subsubsection
12677
12678 Extra Options
12679 \end_layout
12680
12681 \begin_layout Standard
12682
12683 The following options may be used in the extra class options in the 
12684 \family sans
12685 \bar under
12686 D
12687 \bar default
12688 ocument\SpecialChar \menuseparator
12689
12690 \bar under
12691 S
12692 \bar default
12693 ettings
12694 \family default
12695  dialog.
12696 \end_layout
12697
12698 \begin_layout List
12699 \labelwidthstring MMMMMMx
12700
12701
12702 \series bold
12703 35mmSlide
12704 \series default
12705  This sets up the page layout for 7.33in by 11in paper, which is about the
12706  same aspect ratio as a 35mm slide, making it a bit easier to work with
12707  this medium.
12708 \end_layout
12709
12710 \begin_layout List
12711 \labelwidthstring MMMMMMx
12712
12713
12714 \series bold
12715 headrule
12716 \series default
12717  Places a rule across the page below the header on every page except the
12718  title page.
12719 \end_layout
12720
12721 \begin_layout List
12722 \labelwidthstring MMMMMMx
12723
12724
12725 \series bold
12726 footrule
12727 \series default
12728  Places a rule across the page above the footer on every page except the
12729  title page.
12730 \end_layout
12731
12732 \begin_layout List
12733 \labelwidthstring MMMMMMx
12734
12735
12736 \series bold
12737 dvips
12738 \series default
12739  This is automatically set each time you create a new 
12740 \family sans
12741 foils
12742 \family default
12743  document.
12744  This option tells 
12745 \family sans
12746 Foil
12747 \family default
12748 TeX to use the dvips driver to rotate those pages that are set as landscape
12749  foils.
12750 \end_layout
12751
12752 \begin_layout List
12753 \labelwidthstring MMMMMMx
12754
12755
12756 \series bold
12757 landscape
12758 \series default
12759  Simply changes the page dimensions to those of a landscape page but doesn't
12760  do any rotation.
12761  Thus if you use this option you need to use an external program to rotate
12762  each page or feed your paper through your printer as landscape.
12763  Note that this option effectively reverses the roles of the 
12764 \family sans
12765 Foilhead
12766 \family default
12767  and 
12768 \family sans
12769 Rotatefoilhead
12770 \family default
12771  environments (don't worry these are described in the next section).
12772 \end_layout
12773
12774 \begin_layout List
12775 \labelwidthstring MMMMMMx
12776
12777
12778 \series bold
12779 leqno
12780 \series default
12781  Equation numbers on the left.
12782 \end_layout
12783
12784 \begin_layout List
12785 \labelwidthstring MMMMMMx
12786
12787
12788 \series bold
12789 fleqn
12790 \series default
12791  Flush-left equations.
12792 \end_layout
12793
12794 \begin_layout Subsection
12795
12796 Supported Environments
12797 \end_layout
12798
12799 \begin_layout Standard
12800
12801 Most of the environments commonly supported in other classes are also supported
12802  by the 
12803 \family sans
12804 foils
12805 \family default
12806  class.
12807  There are several additional environments provided by 
12808 \family sans
12809 Foil
12810 \family default
12811 TeX as well as a couple added by LyX.
12812  The following environments are shared with other classes:
12813 \end_layout
12814
12815 \begin_layout Standard
12816
12817
12818 \begin_inset ERT
12819 status inlined
12820
12821 \begin_layout Standard
12822
12823 \backslash
12824 begin{multicols}{2}
12825 \end_layout
12826
12827 \end_inset
12828
12829
12830 \end_layout
12831
12832 \begin_layout Itemize
12833
12834
12835 \family sans
12836 Standard
12837 \end_layout
12838
12839 \begin_layout Itemize
12840
12841
12842 \family sans
12843 Itemize
12844 \end_layout
12845
12846 \begin_layout Itemize
12847
12848
12849 \family sans
12850 Enumerate
12851 \end_layout
12852
12853 \begin_layout Itemize
12854
12855
12856 \family sans
12857 Description
12858 \end_layout
12859
12860 \begin_layout Itemize
12861
12862
12863 \family sans
12864 List
12865 \end_layout
12866
12867 \begin_layout Itemize
12868
12869
12870 \family sans
12871 LyX-Code
12872 \end_layout
12873
12874 \begin_layout Itemize
12875
12876
12877 \family sans
12878 Verse
12879 \end_layout
12880
12881 \begin_layout Itemize
12882
12883
12884 \family sans
12885 Quote
12886 \end_layout
12887
12888 \begin_layout Itemize
12889
12890
12891 \family sans
12892 Quotation
12893 \end_layout
12894
12895 \begin_layout Itemize
12896
12897
12898 \family sans
12899 Title
12900 \end_layout
12901
12902 \begin_layout Itemize
12903
12904
12905 \family sans
12906 Author
12907 \end_layout
12908
12909 \begin_layout Itemize
12910
12911
12912 \family sans
12913 Date
12914 \end_layout
12915
12916 \begin_layout Itemize
12917
12918
12919 \family sans
12920 Abstract
12921 \end_layout
12922
12923 \begin_layout Itemize
12924
12925
12926 \family sans
12927 Bibliography
12928 \end_layout
12929
12930 \begin_layout Itemize
12931
12932
12933 \family sans
12934 Address
12935 \end_layout
12936
12937 \begin_layout Itemize
12938
12939
12940 \family sans
12941 RightAddress
12942 \end_layout
12943
12944 \begin_layout Itemize
12945
12946
12947 \family sans
12948 Caption
12949 \end_layout
12950
12951 \begin_layout Itemize
12952
12953
12954 \family sans
12955 Comment
12956 \end_layout
12957
12958 \begin_layout Standard
12959
12960
12961 \begin_inset ERT
12962 status inlined
12963
12964 \begin_layout Standard
12965
12966 \backslash
12967 end{multicols}
12968 \end_layout
12969
12970 \end_inset
12971
12972
12973 \end_layout
12974
12975 \begin_layout Standard
12976
12977 That is, all the major environments apart from the sectioning environments.
12978  Since foils are essentially self-contained sections, with a title and body,
12979  
12980 \family sans
12981 Foil
12982 \family default
12983 TeX provides specific commands for starting new foils and these are:
12984 \end_layout
12985
12986 \begin_layout Itemize
12987
12988
12989 \family sans
12990 Foilhead
12991 \end_layout
12992
12993 \begin_layout Itemize
12994
12995
12996 \family sans
12997 Rotatefoilhead
12998 \end_layout
12999
13000 \begin_layout Standard
13001
13002 LyX also provides slightly modified versions of these two environments called:
13003 \end_layout
13004
13005 \begin_layout Itemize
13006
13007
13008 \family sans
13009 ShortFoilhead
13010 \end_layout
13011
13012 \begin_layout Itemize
13013
13014
13015 \family sans
13016 ShortRotatefoilhead
13017 \end_layout
13018
13019 \begin_layout Standard
13020
13021 and the differences will be explained in the next section.
13022 \end_layout
13023
13024 \begin_layout Standard
13025
13026 Since foils are often used in presenting ideas or new theorems and such
13027  
13028 \family sans
13029 Foil
13030 \family default
13031 TeX also provides a comprehensive box of goodies for presenting them:
13032 \end_layout
13033
13034 \begin_layout Standard
13035
13036
13037 \begin_inset ERT
13038 status inlined
13039
13040 \begin_layout Standard
13041
13042 \backslash
13043 begin{multicols}{2}
13044 \end_layout
13045
13046 \end_inset
13047
13048
13049 \end_layout
13050
13051 \begin_layout Itemize
13052
13053
13054 \family sans
13055 Theorem
13056 \end_layout
13057
13058 \begin_layout Itemize
13059
13060
13061 \family sans
13062 Lemma
13063 \end_layout
13064
13065 \begin_layout Itemize
13066
13067
13068 \family sans
13069 Corollary
13070 \end_layout
13071
13072 \begin_layout Itemize
13073
13074
13075 \family sans
13076 Proposition
13077 \end_layout
13078
13079 \begin_layout Itemize
13080
13081
13082 \family sans
13083 Definition
13084 \end_layout
13085
13086 \begin_layout Itemize
13087
13088
13089 \family sans
13090 Proof
13091 \end_layout
13092
13093 \begin_layout Itemize
13094
13095
13096 \family sans
13097 Theorem*
13098 \end_layout
13099
13100 \begin_layout Itemize
13101
13102
13103 \family sans
13104 Lemma*
13105 \end_layout
13106
13107 \begin_layout Itemize
13108
13109
13110 \family sans
13111 Corollary*
13112 \end_layout
13113
13114 \begin_layout Itemize
13115
13116
13117 \family sans
13118 Proposition*
13119 \end_layout
13120
13121 \begin_layout Itemize
13122
13123
13124 \family sans
13125 Definition*
13126 \end_layout
13127
13128 \begin_layout Standard
13129
13130
13131 \begin_inset ERT
13132 status inlined
13133
13134 \begin_layout Standard
13135
13136 \backslash
13137 end{multicols}
13138 \end_layout
13139
13140 \end_inset
13141
13142
13143 \end_layout
13144
13145 \begin_layout Standard
13146
13147 The starred versions are unnumbered while the unstarred versions are numbered.
13148  There are also two list environments added by LyX and these are:
13149 \end_layout
13150
13151 \begin_layout Itemize
13152
13153
13154 \family sans
13155 TickList
13156 \end_layout
13157
13158 \begin_layout Itemize
13159
13160
13161 \family sans
13162 CrossList
13163 \end_layout
13164
13165 \begin_layout Standard
13166
13167
13168 \family sans
13169 Foil
13170 \family default
13171 TeX provides some powerful header and footer capabilities that are best
13172  set in the preamble although they may be set at any point in a document.
13173  If you want to change these settings in your document the best place to
13174  do so is at the very top of a foil, 
13175 \emph on
13176 i.e.
13177
13178 \emph default
13179  straight after the foilhead.
13180 \end_layout
13181
13182 \begin_layout Standard
13183
13184 For this purpose, the following command styles are provided [
13185 \shape smallcaps
13186 Martin Vermeer
13187 \shape default
13188 ]:
13189 \end_layout
13190
13191 \begin_layout Standard
13192
13193
13194 \begin_inset ERT
13195 status inlined
13196
13197 \begin_layout Standard
13198
13199 \backslash
13200 begin{multicols}{2}
13201 \end_layout
13202
13203 \end_inset
13204
13205
13206 \end_layout
13207
13208 \begin_layout Itemize
13209
13210
13211 \family sans
13212 My\InsetSpace ~
13213 Logo
13214 \end_layout
13215
13216 \begin_layout Itemize
13217
13218
13219 \family sans
13220 Restriction
13221 \end_layout
13222
13223 \begin_layout Itemize
13224
13225
13226 \family sans
13227 Right\InsetSpace ~
13228 Footer
13229 \end_layout
13230
13231 \begin_layout Itemize
13232
13233
13234 \family sans
13235 Right\InsetSpace ~
13236 Header
13237 \end_layout
13238
13239 \begin_layout Itemize
13240
13241
13242 \family sans
13243 Left\InsetSpace ~
13244 Header
13245 \end_layout
13246
13247 \begin_deeper
13248 \begin_layout Standard
13249
13250 \InsetSpace ~
13251
13252 \end_layout
13253 \end_deeper
13254 \begin_layout Standard
13255
13256
13257 \begin_inset ERT
13258 status inlined
13259
13260 \begin_layout Standard
13261
13262 \backslash
13263 end{multicols}
13264 \end_layout
13265
13266 \end_inset
13267
13268
13269 \end_layout
13270
13271 \begin_layout Standard
13272
13273 There are also a few commands provided by 
13274 \family sans
13275 Foil
13276 \family default
13277 TeX that aren't directly supported by LyX but I'll tell you what they do
13278  and how to use them in section\InsetSpace ~
13279
13280 \begin_inset LatexCommand \ref{sec:unsuppfoils}
13281
13282 \end_inset
13283
13284 .
13285 \end_layout
13286
13287 \begin_layout Subsection
13288
13289 Building a Set of Foils
13290 \end_layout
13291
13292 \begin_layout Standard
13293
13294 This section will give a simple introduction to using the different environments
13295  to build a set of foils.
13296  If you want to see an example set of foils take a look at the 
13297 \family typewriter
13298 Foils.lyx
13299 \family default
13300  file accessible from the 
13301 \family sans
13302 \bar under
13303 F
13304 \bar default
13305 ile\SpecialChar \menuseparator
13306
13307 \bar under
13308 O
13309 \bar default
13310 pen\SpecialChar \ldots{}
13311
13312 \family default
13313  dialog under the 
13314 \family sans
13315 Examples
13316 \family default
13317  button.
13318  
13319 \end_layout
13320
13321 \begin_layout Subsubsection
13322
13323 Give It a Title Page
13324 \end_layout
13325
13326 \begin_layout Standard
13327
13328 Unlike other classes that provide 
13329 \family sans
13330 Title
13331 \family default
13332
13333 \family sans
13334 Author
13335 \family default
13336
13337 \family sans
13338 Date
13339 \family default
13340  and 
13341 \family sans
13342 Abstract
13343 \family default
13344  environments, 
13345 \family sans
13346 foils
13347 \family default
13348  creates the title on a page of its own.
13349  If you leave out the 
13350 \family sans
13351 Date
13352 \family default
13353  environment LaTeX will substitute the current date (every time you regenerate
13354  the output).
13355 \end_layout
13356
13357 \begin_layout Subsubsection
13358
13359 Start a New Foil
13360 \end_layout
13361
13362 \begin_layout Standard
13363
13364 As I mentioned earlier, there are four ways of starting a new foil.
13365  For portrait foils you should use 
13366 \family sans
13367 Foilhead
13368 \family default
13369  or 
13370 \family sans
13371 ShortFoilhead.
13372
13373 \family default
13374  The difference between these two environments is the amount of space between
13375  the title of the foil (the foilhead) and the body of the foil.
13376 \end_layout
13377
13378 \begin_layout Standard
13379
13380 Landscape foils are generated using the 
13381 \family sans
13382 Rotatefoilhead
13383 \family default
13384  and 
13385 \family sans
13386 ShortRotatefoilhead
13387 \family default
13388  environments.
13389  Again the only difference is the spacing between foilhead and body.
13390  Both of the short versions have 0.5 inches less separation between the foilhead
13391  and the body.
13392  
13393 \end_layout
13394
13395 \begin_layout Standard
13396
13397 One problem with the support for landscape foils is the requirement that
13398  you have to use the 
13399 \family typewriter
13400 dvips
13401 \family default
13402  driver to generate the PostScript® output otherwise the foils won't be
13403  rotated.
13404  It is possible to get landscape foils even if you haven't got the 
13405 \family typewriter
13406 dvips
13407 \family default
13408  driver provided you can feed your foils sideways through your printer ;-)
13409 \end_layout
13410
13411 \begin_layout Subsubsection
13412
13413 Theorems, Lemmas, Proofs and more
13414 \end_layout
13415
13416 \begin_layout Standard
13417
13418 Due to a small bug in LyX you can't have two of the same type of these environme
13419 nts directly following each other.
13420  They must be separated by something.
13421  If you try, you will just be extending the previous environment as if you
13422  had merged the two environments together.
13423  So, how do you get around this problem? The simplest option is to insert
13424  some text between the two environments or add a 
13425 \family sans
13426 LaTeX
13427 \family default
13428  environment between the two with just a 
13429 \begin_inset Quotes eld
13430 \end_inset
13431
13432
13433 \family typewriter
13434 %
13435 \family default
13436
13437 \begin_inset Quotes erd
13438 \end_inset
13439
13440  in it.
13441  This will force LyX to produce two separate environments and hence the
13442  correct LaTeX output.
13443  An example is provided in the example file included with the LyX distribution.
13444  Remember, this problem only occurs if you are trying to place two of the
13445  same type of theorem-like environments one directly after the other.
13446 \end_layout
13447
13448 \begin_layout Subsubsection
13449
13450 Lists
13451 \end_layout
13452
13453 \begin_layout Standard
13454
13455 You get all the commonly supported list styles found in other classes as
13456  well as two new ones.
13457  I'll only describe the new ones here.
13458  If you want to find out more about the other list environments check out
13459  the 
13460 \emph on
13461 User's Guide.
13462
13463 \emph default
13464  If you intend to use itemized lists you might also want to read about the
13465  
13466 \family sans
13467 Itemize\InsetSpace ~
13468 Bullet\InsetSpace ~
13469 Selection
13470 \family default
13471  dialog described above in section\InsetSpace ~
13472
13473 \begin_inset LatexCommand \ref{sec:bullet}
13474
13475 \end_inset
13476
13477 .
13478 \end_layout
13479
13480 \begin_layout Standard
13481
13482 The two new list styles, 
13483 \family sans
13484 TickList 
13485 \family default
13486 and 
13487 \family sans
13488 CrossList
13489 \family default
13490 , are designed to make it easier for you to create lists of do's and don'ts
13491  or right and wrong by providing dedicated environments that use a tick
13492  or a cross as the label of the list.
13493  These lists are in fact dedicated variants of the 
13494 \family sans
13495 Itemize
13496 \family default
13497  environment.
13498  They do however require that you have the 
13499 \family typewriter
13500 psnfss
13501 \family default
13502  packages installed.
13503 \end_layout
13504
13505 \begin_layout Subsubsection
13506
13507 Figures and Tables
13508 \end_layout
13509
13510 \begin_layout Standard
13511
13512
13513 \family sans
13514 Foil
13515 \family default
13516 TeX redefines the floating tables and figures so that they appear exactly
13517  where they are in the text rather than pushing them to the top of the page
13518  or to some user specified location.
13519  In fact if you change the float placement settings they are simply ignored.
13520 \end_layout
13521
13522 \begin_layout Subsubsection
13523
13524 Page Headers and Footers
13525 \begin_inset LatexCommand \label{sec:foilfoot}
13526
13527 \end_inset
13528
13529
13530 \end_layout
13531
13532 \begin_layout Standard
13533
13534
13535 \family sans
13536 My\InsetSpace ~
13537 Logo
13538 \family default
13539  and 
13540 \family sans
13541 Restriction
13542 \family default
13543  are two commands used to control the left-footer text string.
13544  The first is meant to allow you to include a graphic logo on your foils
13545  and defaults to 
13546 \begin_inset Quotes eld
13547 \end_inset
13548
13549 -Typeset by 
13550 \family sans
13551 Foil
13552 \family default
13553 TeX-
13554 \begin_inset Quotes erd
13555 \end_inset
13556
13557 .
13558  While the second is meant to provide a classification for the audience,
13559  
13560 \emph on
13561 e.g.
13562
13563 \emph default
13564  Confidential.
13565  It is empty by default.
13566 \end_layout
13567
13568 \begin_layout Standard
13569
13570 The remaining page corners can be filled by
13571 \family sans
13572  Right\InsetSpace ~
13573 Footer
13574 \family default
13575  (which defaults to page numbers), 
13576 \family sans
13577 Right\InsetSpace ~
13578 Header
13579 \family default
13580  (top right) and 
13581 \family sans
13582 Left\InsetSpace ~
13583 Header
13584 \family default
13585  (top left).
13586 \end_layout
13587
13588 \begin_layout Subsection
13589
13590 Unsupported 
13591 \family sans
13592 Foil
13593 \family default
13594 TeX Goodies
13595 \begin_inset LatexCommand \label{sec:unsuppfoils}
13596
13597 \end_inset
13598
13599
13600 \end_layout
13601
13602 \begin_layout Standard
13603
13604 All the commands mentioned below need to be set in a 
13605 \family sans
13606 LaTeX
13607 \family default
13608  environment or as 
13609 \family sans
13610 TeX
13611 \family default
13612  within another environment.
13613 \end_layout
13614
13615 \begin_layout Subsubsection
13616
13617 Lengths
13618 \end_layout
13619
13620 \begin_layout Standard
13621
13622 All lengths are adjusted using the 
13623 \family typewriter
13624
13625 \backslash
13626 setlength{
13627 \family default
13628 \emph on
13629 lengthname
13630 \family typewriter
13631 \emph default
13632 }{
13633 \family default
13634 \emph on
13635 newlength
13636 \family typewriter
13637 \emph default
13638 }
13639 \family default
13640  command.
13641  Where 
13642 \emph on
13643 lengthname
13644 \emph default
13645  should be replaced by the name given to the length you want to change and
13646  
13647 \emph on
13648 newlength
13649 \emph default
13650  is the length value.
13651  All lengths should be specified in units of length such as inches (
13652 \family typewriter
13653 in
13654 \family default
13655 ), millimeters (
13656 \family typewriter
13657 mm
13658 \family default
13659 ) or points (
13660 \family typewriter
13661 pt
13662 \family default
13663 ) or relative to some document or font-based length such as 
13664 \family typewriter
13665
13666 \backslash
13667 textwidth
13668 \family default
13669 .
13670  
13671 \end_layout
13672
13673 \begin_layout Standard
13674
13675 It's possible to change the spacing between a foilhead and the body of the
13676  foil by adjusting the length specified by 
13677 \family typewriter
13678
13679 \backslash
13680 foilheadskip
13681 \family default
13682 .
13683  For example, to make 
13684 \emph on
13685 all
13686 \emph default
13687  foilheads 0.5 inches closer to their bodies put the following in the preamble:
13688  
13689 \family typewriter
13690
13691 \backslash
13692 setlength{
13693 \backslash
13694 foilheadskip}{-0.5in}
13695 \end_layout
13696
13697 \begin_layout Standard
13698
13699 The spacings around floats can be adjusted by setting these lengths:
13700 \end_layout
13701
13702 \begin_layout List
13703 \labelwidthstring MMMMMMMMMMM
13704
13705
13706 \family typewriter
13707
13708 \backslash
13709 abovefloatskip 
13710 \family default
13711 Separation between the text and the top of the float
13712 \end_layout
13713
13714 \begin_layout List
13715 \labelwidthstring MMMMMMMMMMM
13716
13717
13718 \family typewriter
13719
13720 \backslash
13721 abovecaptionskip 
13722 \family default
13723 Separation between the float and the caption
13724 \end_layout
13725
13726 \begin_layout List
13727 \labelwidthstring MMMMMMMMMMM
13728
13729
13730 \family typewriter
13731
13732 \backslash
13733 belowcaptionskip 
13734 \family default
13735 Separation between the caption and the following text
13736 \end_layout
13737
13738 \begin_layout List
13739 \labelwidthstring MMMMMMMMMMM
13740
13741
13742 \family typewriter
13743
13744 \backslash
13745 captionwidth
13746 \family default
13747  You can make the captions narrower than the surrounding text by adjusting
13748  this length.
13749  Best done relative to 
13750 \family typewriter
13751
13752 \backslash
13753 textwidth
13754 \family default
13755 .
13756 \end_layout
13757
13758 \begin_layout Standard
13759
13760 There are also several title page related lengths that you may find useful
13761  if you have a long title or several authors:
13762 \end_layout
13763
13764 \begin_layout List
13765 \labelwidthstring MMMMMMMMMMM
13766
13767
13768 \family typewriter
13769
13770 \backslash
13771 abovetitleskip
13772 \family default
13773  Separation from headers to 
13774 \family sans
13775 Title
13776 \end_layout
13777
13778 \begin_layout List
13779 \labelwidthstring MMMMMMMMMMM
13780
13781
13782 \family typewriter
13783
13784 \backslash
13785 titleauthorskip
13786 \family default
13787  between 
13788 \family sans
13789 Title
13790 \family default
13791  and 
13792 \family sans
13793 Author
13794 \family default
13795  environments
13796 \end_layout
13797
13798 \begin_layout List
13799 \labelwidthstring MMMMMMMMMMM
13800
13801
13802 \family typewriter
13803
13804 \backslash
13805 authorauthorskip
13806 \family default
13807  between multiple 
13808 \family sans
13809 Author
13810 \family default
13811  lines
13812 \end_layout
13813
13814 \begin_layout List
13815 \labelwidthstring MMMMMMMMMMM
13816
13817
13818 \family typewriter
13819
13820 \backslash
13821 authordateskip
13822 \family default
13823  between the 
13824 \family sans
13825 Author
13826 \family default
13827  and the 
13828 \family sans
13829 Date
13830 \end_layout
13831
13832 \begin_layout List
13833 \labelwidthstring MMMMMMMMMMM
13834
13835
13836 \family typewriter
13837
13838 \backslash
13839 dateabstractskip
13840 \family default
13841  between the 
13842 \family sans
13843 Date
13844 \family default
13845  and the 
13846 \family sans
13847 Abstract
13848 \end_layout
13849
13850 \begin_layout Standard
13851
13852 The last length related command affects all the list environments.
13853  If you place
13854 \family typewriter
13855  
13856 \backslash
13857 zerolistvertdimens
13858 \family default
13859  
13860 \emph on
13861 inside
13862 \emph default
13863  a list environment then all the vertical spacing between the list items
13864  is removed.
13865  Note that this is a command not a length so it doesn't require 
13866 \family typewriter
13867
13868 \backslash
13869 setlength
13870 \family default
13871  like the stuff mentioned above.
13872 \end_layout
13873
13874 \begin_layout Subsubsection
13875
13876 Headers and Footers
13877 \end_layout
13878
13879 \begin_layout Standard
13880
13881 The 
13882 \family typewriter
13883
13884 \backslash
13885 LogoOn
13886 \family default
13887  and 
13888 \family typewriter
13889
13890 \backslash
13891 LogoOff
13892 \family default
13893  commands control whether the logo in the 
13894 \family sans
13895 MyLogo
13896 \family default
13897  definition appear on a given page.
13898  If you put 
13899 \family typewriter
13900
13901 \backslash
13902 LogoOff
13903 \family default
13904  in the preamble then none of the foils will have the logo on them.
13905  If you don't want the logo on a particular page place the 
13906 \family typewriter
13907
13908 \backslash
13909 LogoOff
13910 \family default
13911  directly after the foilhead of that page and the 
13912 \family typewriter
13913
13914 \backslash
13915 LogoOn
13916 \family default
13917  directly after the next foilhead.
13918 \end_layout
13919
13920 \begin_layout Standard
13921
13922 If you decide to use the 
13923 \family sans
13924 fancy
13925 \family default
13926  page style setting in the 
13927 \family sans
13928 Document\InsetSpace ~
13929 Layout
13930 \family default
13931  dialog you should probably add 
13932 \family typewriter
13933
13934 \backslash
13935 let
13936 \backslash
13937 headwidth
13938 \backslash
13939 textwidth
13940 \family default
13941  to your preamble so headers and footers on landscape pages are correctly
13942  placed when rotated.
13943  This is due to some clashes between the page layouts provided by the 
13944 \family sans
13945 fancyheadings
13946 \family default
13947  package and the 
13948 \family sans
13949 foils
13950 \family default
13951  class.
13952 \end_layout
13953
13954 \begin_layout Section
13955
13956 Latex8 (IEEE Conference Papers)
13957 \end_layout
13958
13959 \begin_layout Standard
13960
13961 by 
13962 \noun on
13963 Allan Rae
13964 \end_layout
13965
13966 \begin_layout Subsection
13967
13968 Introduction
13969 \end_layout
13970
13971 \begin_layout Standard
13972
13973 Since this class is specifically for writing submissions to IEEE sponsored
13974  conferences I strongly recommend that you get a copy of their Authors Kit.
13975  The 
13976 \family sans
13977 latex.sty
13978 \family default
13979  package and associated bibliography style file is included in the kit.
13980  The Authors Kit is usually sent out by email once your initial submission
13981  has been accepted.
13982  There is a lot of useful information in the Authors Kit explaining formatting
13983  restrictions and so on and I will assume you have read this since that
13984  means I don't have to repeat it all here.
13985 \end_layout
13986
13987 \begin_layout Subsection
13988
13989 Getting Started
13990 \end_layout
13991
13992 \begin_layout Standard
13993
13994 [AR\SpecialChar \@.
13995  more to come]
13996 \end_layout
13997
13998 \begin_layout Subsection
13999
14000 Supported Environments
14001 \end_layout
14002
14003 \begin_layout Itemize
14004
14005
14006 \family sans
14007 Standard
14008 \end_layout
14009
14010 \begin_layout Itemize
14011
14012
14013 \family sans
14014 Title
14015 \end_layout
14016
14017 \begin_layout Itemize
14018
14019
14020 \family sans
14021 Author
14022 \end_layout
14023
14024 \begin_layout Itemize
14025
14026
14027 \family sans
14028 E-mail
14029 \end_layout
14030
14031 \begin_layout Itemize
14032
14033
14034 \family sans
14035 Affiliation
14036 \end_layout
14037
14038 \begin_layout Itemize
14039
14040
14041 \family sans
14042 Abstract
14043 \end_layout
14044
14045 \begin_layout Itemize
14046
14047
14048 \family sans
14049 Section
14050 \end_layout
14051
14052 \begin_layout Itemize
14053
14054
14055 \family sans
14056 SubSection
14057 \end_layout
14058
14059 \begin_layout Itemize
14060
14061
14062 \family sans
14063 Caption
14064 \end_layout
14065
14066 \begin_layout Subsection
14067
14068 Differences Between Screen and Paper
14069 \end_layout
14070
14071 \begin_layout Standard
14072
14073 There are slight differences in appearance mainly with the presentation
14074  of section counters.
14075  On screen the trailing period of the section counter is missing but it
14076  will appear in the output so don't let this worry you.
14077 \end_layout
14078
14079 \begin_layout Section
14080
14081 Hollywood (Hollywood spec scripts)
14082 \end_layout
14083
14084 \begin_layout Standard
14085
14086 by 
14087 \shape smallcaps
14088 Garst Reese
14089 \end_layout
14090
14091 \begin_layout Subsection
14092
14093 Introduction
14094 \end_layout
14095
14096 \begin_layout Standard
14097
14098 Getting the format of a Hollywood script right is a 
14099 \begin_inset Quotes eld
14100 \end_inset
14101
14102 rite of passage.
14103 \begin_inset Quotes erd
14104 \end_inset
14105
14106  It is designed to make the readers focus on content and to be easy and
14107  familiar for the actors to read.
14108  Each page of a script should be one minute of film.
14109  Nothing goes in a script that you cannot see or hear on screen.
14110  The courier 12 pt font should be used throughout.
14111  No italics.
14112 \end_layout
14113
14114 \begin_layout Subsection
14115
14116 Special problems
14117 \end_layout
14118
14119 \begin_layout Standard
14120
14121 Speakers' lines should NEVER break in mid-sentence.
14122  If a speaker's lines continue over a page break, repeat the 
14123 \family sans
14124 Speaker
14125 \family default
14126  title followed by (Cont'd).
14127 \end_layout
14128
14129 \begin_layout Subsection
14130
14131 Special features
14132 \end_layout
14133
14134 \begin_layout Standard
14135
14136 Insert the 
14137 \family sans
14138 Speaker
14139 \family default
14140  names as labels then cross-reference the label to insert the name.
14141  The cross-reference dialog will show the current cast of characters.
14142  You can use this to insert the speaker name in narratives also.
14143 \end_layout
14144
14145 \begin_layout Subsection
14146
14147 Paper size and Margins
14148 \end_layout
14149
14150 \begin_layout Standard
14151
14152 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
14153 \end_layout
14154
14155 \begin_layout Subsection
14156
14157 Environments
14158 \end_layout
14159
14160 \begin_layout Standard
14161
14162 The following environments are available.
14163  You can use hollywood.bind to get the bind keys shown at the right.
14164 \end_layout
14165
14166 \begin_layout Itemize
14167
14168
14169 \family sans
14170 Standard
14171 \newline
14172
14173 \family default
14174 Used where nothing else works.
14175  Try to avoid it.
14176 \end_layout
14177
14178 \begin_layout Itemize
14179
14180
14181 \family sans
14182 FADE_IN
14183 \family default
14184 :
14185 \hfill
14186
14187 \family sans
14188 M-z S-I
14189 \family default
14190
14191 \newline
14192 Usually followed by something like 
14193 \begin_inset Quotes eld
14194 \end_inset
14195
14196 on Sally waking up.
14197 \begin_inset Quotes erd
14198 \end_inset
14199
14200
14201 \end_layout
14202
14203 \begin_layout Itemize
14204
14205
14206 \family sans
14207 INT:
14208 \hfill
14209 M-z i
14210 \newline
14211
14212 \family default
14213 Introduces a new INTERIOR camera set-up.
14214  Always followed by DAY or NIGHT, or something similar to define the lighting
14215  required.
14216  Everthing on this line in CAPS.
14217 \end_layout
14218
14219 \begin_layout Itemize
14220
14221
14222 \family sans
14223 EXT:
14224 \hfill
14225 M-z e
14226 \newline
14227
14228 \family default
14229 Introduces a new EXTERIOR camera set-up.
14230  Everthing on this line in CAPS.
14231 \end_layout
14232
14233 \begin_layout Itemize
14234
14235
14236 \family sans
14237 Speaker
14238 \hfill
14239 M-z s
14240 \newline
14241
14242 \family default
14243 The character speaking.
14244 \end_layout
14245
14246 \begin_layout Itemize
14247
14248
14249 \family sans
14250 Parenthetical
14251 \hfill
14252 M-z p
14253 \newline
14254
14255 \family default
14256 Instructions to the speaker.
14257  The () are automatically inserted, but only the ( will show in LyX.
14258  Both will be printed.
14259 \end_layout
14260
14261 \begin_layout Itemize
14262
14263
14264 \family sans
14265 Dialogue
14266 \hfill
14267 M-z d
14268 \newline
14269
14270 \family default
14271 What the 
14272 \family sans
14273 Speaker
14274 \family default
14275  says.
14276 \end_layout
14277
14278 \begin_layout Itemize
14279
14280
14281 \family sans
14282 Transition
14283 \hfill
14284 M-z t
14285 \newline
14286
14287 \family default
14288 Camera movement instruction.
14289  e.g.
14290  CUT TO:
14291 \end_layout
14292
14293 \begin_layout Itemize
14294
14295
14296 \family sans
14297 FADE OUT:
14298 \hfill
14299 M-z S-I
14300 \end_layout
14301
14302 \begin_layout Itemize
14303
14304
14305 \family sans
14306 Author
14307 \hfill
14308 M-z S-A
14309 \end_layout
14310
14311 \begin_layout Itemize
14312
14313
14314 \family sans
14315 Title
14316 \hfill
14317 M-z S-T
14318 \end_layout
14319
14320 \begin_layout Itemize
14321
14322
14323 \family sans
14324 Right_Address
14325 \hfill
14326 M-z r
14327 \end_layout
14328
14329 \begin_layout Subsection
14330
14331 Script jargon
14332 \end_layout
14333
14334 \begin_layout Itemize
14335
14336 (O.S) --- off screen
14337 \end_layout
14338
14339 \begin_layout Itemize
14340
14341 (V.0) --- voice over
14342 \end_layout
14343
14344 \begin_layout Itemize
14345
14346 b.g.
14347  --- background
14348 \end_layout
14349
14350 \begin_layout Itemize
14351
14352 C.U.
14353  --- close-up
14354 \end_layout
14355
14356 \begin_layout Itemize
14357
14358 PAN --- camera movement
14359 \end_layout
14360
14361 \begin_layout Itemize
14362
14363 INSERT --- cut to close-up of
14364 \end_layout
14365
14366 \begin_layout Section
14367
14368 Broadway
14369 \end_layout
14370
14371 \begin_layout Standard
14372
14373 by 
14374 \shape smallcaps
14375 Garst Reese
14376 \end_layout
14377
14378 \begin_layout Subsection
14379
14380 Introduction
14381 \end_layout
14382
14383 \begin_layout Standard
14384
14385 Broadway is for writing plays.
14386  The format is more decorative than Hollywood, and much less standardized.
14387  This format should be suitable for workshops.
14388 \end_layout
14389
14390 \begin_layout Subsection
14391
14392 Special problems
14393 \end_layout
14394
14395 \begin_layout Standard
14396
14397 The same as in Hollywood.
14398 \end_layout
14399
14400 \begin_layout Subsection
14401
14402 Special features
14403 \end_layout
14404
14405 \begin_layout Standard
14406
14407 Insert the 
14408 \family sans
14409 Speaker
14410 \family default
14411  names as labels then cross-reference the label to insert the name.
14412  The cross-reference dialog will show the current cast of characters.
14413 \end_layout
14414
14415 \begin_layout Subsection
14416
14417 Paper size and Margins
14418 \end_layout
14419
14420 \begin_layout Standard
14421
14422 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
14423 \end_layout
14424
14425 \begin_layout Subsection
14426
14427 Environments
14428 \end_layout
14429
14430 \begin_layout Standard
14431
14432 The following environments are available.
14433  You can use broadway.bind to get the bind keys shown at the right.
14434 \end_layout
14435
14436 \begin_layout Itemize
14437
14438
14439 \family sans
14440 Standard
14441 \newline
14442
14443 \family default
14444 You should not have to use this, but it is here for anything that does not
14445  fit otherwise.
14446 \end_layout
14447
14448 \begin_layout Itemize
14449
14450
14451 \family sans
14452 Narrative
14453 \hfill
14454 M-z n
14455 \newline
14456
14457 \family default
14458 Used to describe stage setting and the action.
14459  First use of speaker names in all CAPs.
14460 \end_layout
14461
14462 \begin_layout Itemize
14463
14464
14465 \family sans
14466 ACT
14467 \hfill
14468 M-z a
14469 \newline
14470
14471 \family default
14472 Automatically numbered.
14473  On screen it will be arabic, but will print as Roman.
14474 \end_layout
14475
14476 \begin_layout Itemize
14477
14478
14479 \family sans
14480 ACT*
14481 \hfill
14482 M-z S at
14483 \newline
14484
14485 \family default
14486 Subtitle for 
14487 \family sans
14488 ACT.
14489  
14490 \family default
14491 It is just centered text.
14492 \end_layout
14493
14494 \begin_layout Itemize
14495
14496
14497 \family sans
14498 SCENE
14499 \hfill
14500 M-z S-S
14501 \newline
14502
14503 \family default
14504 Not automatically numbered.
14505  You supply the number.
14506  This is because I couldn't figure out how.
14507 \end_layout
14508
14509 \begin_layout Itemize
14510
14511
14512 \family sans
14513 AT_RISE:
14514 \hfill
14515 M-z S-R
14516 \newline
14517
14518 \family default
14519 A special case of Narrative to describe the setting and action as the curtain
14520  rises.
14521 \end_layout
14522
14523 \begin_layout Itemize
14524
14525
14526 \family sans
14527 Speaker
14528 \hfill
14529 M-z s
14530 \newline
14531
14532 \family default
14533 The speaker's (actor's) title, centered in all CAPS.
14534 \end_layout
14535
14536 \begin_layout Itemize
14537
14538
14539 \family sans
14540 Parenthetical
14541 \hfill
14542 M-z p
14543 \newline
14544
14545 \family default
14546 Instructions to the speaker.
14547  The parentheses are automatically inserted.
14548  The ( will appear on screen, but both will be in the printed play.
14549  This environment is only used within 
14550 \family sans
14551 Dialogue
14552 \family default
14553 .
14554 \end_layout
14555
14556 \begin_layout Itemize
14557
14558
14559 \family sans
14560 Dialogue
14561 \hfill
14562 M-z d
14563 \newline
14564
14565 \family default
14566 What the Speaker says.
14567 \end_layout
14568
14569 \begin_layout Itemize
14570
14571
14572 \family sans
14573 CURTAIN
14574 \hfill
14575 M-z S-C
14576 \newline
14577
14578 \family default
14579 The curtain comes down.
14580 \end_layout
14581
14582 \begin_layout Itemize
14583
14584
14585 \family sans
14586 Title
14587 \hfill
14588 M-z S-T
14589 \end_layout
14590
14591 \begin_layout Itemize
14592
14593
14594 \family sans
14595 Author
14596 \hfill
14597 M-z S-A
14598 \end_layout
14599
14600 \begin_layout Itemize
14601
14602
14603 \family sans
14604 Right_Address
14605 \hfill
14606 M-z r
14607 \end_layout
14608
14609 \begin_layout Standard
14610
14611 Hello there.
14612 \end_layout
14613
14614 \begin_layout Section
14615
14616 RevTeX4
14617 \end_layout
14618
14619 \begin_layout Standard
14620
14621 by 
14622 \noun on
14623 Amir Karger
14624 \end_layout
14625
14626
14627 \begin_layout Standard
14628
14629
14630 \begin_inset VSpace bigskip
14631 \end_inset
14632
14633
14634 \end_layout
14635
14636 \begin_layout Standard
14637 \noindent
14638 The 
14639 \family sans
14640 Revtex\InsetSpace ~
14641 4
14642 \family default
14643  textclass works with the American Physical Sociey's RevTeX 4.0 (the 
14644 \begin_inset Formula $\beta$
14645 \end_inset
14646
14647  release of May, 1999) class.
14648 \end_layout
14649
14650 \begin_layout Standard
14651
14652 LyX has a 
14653 \family sans
14654 Revtex
14655 \family default
14656  textclass, which works with RevTeX 3.1.
14657  However, v3.1 is basically obsolete, as it works with LaTeX 2.09.
14658  That means that it doesn't interact very well with LyX, which requires
14659  LaTeX2e, although it has been kludged to work.
14660  Since RevTeX 4.0 has been designed to work much more cleanly with LaTeX2e,
14661  LyX with the 
14662 \family sans
14663 RevTeX\InsetSpace ~
14664 4
14665 \family default
14666  textclass should also be pretty easy to use.
14667 \end_layout
14668
14669 \begin_layout Standard
14670
14671 These documents are supposed to be used in 
14672 \emph on
14673 addition
14674 \emph default
14675  to the RevTeX 4.0 documents, so we don't describe any of the special RevTeX
14676  macros, and assume you'll know what to put in the preamble if necessary.
14677 \end_layout
14678
14679 \begin_layout Subsection
14680
14681 Installation
14682 \end_layout
14683
14684 \begin_layout Standard
14685
14686 All you need to do is install RevTeX 4, as described in the package's README
14687  file.
14688  the package can be found at 
14689 \begin_inset LatexCommand \url[The RevTeX 4 Web Site]{http://publish.aps.org/revtex4/}
14690
14691 \end_inset
14692
14693 .
14694  Install it somewhere that LaTeX can see it.
14695  Test it by trying to LaTeX a short RevTeX 4 document in some random directory
14696  (i.e., not the directory where you installed the class file.) Then, if you
14697  reconfigure LyX, it will find the class file and let you use the RevTeX4
14698  textclass.
14699 \end_layout
14700
14701 \begin_layout Standard
14702
14703 Probably the easiest way to get started is either to import a RevTeX 4 document
14704  using 
14705 \family typewriter
14706 reLyX
14707 \family default
14708 , or to use the 
14709 \family sans
14710 Revtex\InsetSpace ~
14711 4
14712 \family default
14713  template, found in the templates directory.
14714 \end_layout
14715
14716 \begin_layout Subsection
14717
14718 Preamble Matter
14719 \end_layout
14720
14721 \begin_layout Standard
14722
14723 Optional arguments to 
14724 \family typewriter
14725
14726 \backslash
14727 documentclass
14728 \family default
14729 , like 
14730 \begin_inset Quotes eld
14731 \end_inset
14732
14733 preprint
14734 \begin_inset Quotes erd
14735 \end_inset
14736
14737  and 
14738 \begin_inset Quotes eld
14739 \end_inset
14740
14741 aps
14742 \begin_inset Quotes erd
14743 \end_inset
14744
14745 , go in the 
14746 \family sans
14747 E
14748 \bar under
14749 x
14750 \bar default
14751 tra\InsetSpace ~
14752 Options
14753 \family default
14754  field in the 
14755 \family sans
14756 Document\InsetSpace ~
14757 Layout
14758 \family default
14759  dialog, as usual.
14760  Remember that in RevTeX, at least one optional argument is required! 
14761 \end_layout
14762
14763 \begin_layout Standard
14764
14765 Other preamble matter, like 
14766 \family typewriter
14767
14768 \backslash
14769 draft
14770 \family default
14771  etc.
14772  goes in the 
14773 \family sans
14774 Latex\InsetSpace ~
14775 Preamble
14776 \family default
14777  dialog, also as usual.
14778 \end_layout
14779
14780 \begin_layout Subsection
14781
14782 Layouts
14783 \end_layout
14784
14785 \begin_layout Standard
14786
14787 The layouts basically correspond to the commands in RevTeX4.0.
14788  For example, the Email layout corresponds to 
14789 \family typewriter
14790
14791 \backslash
14792 email{}
14793 \family default
14794 .
14795  Note that (at least as of RevTeX 4.0 Beta), the 
14796 \family sans
14797 Address
14798 \family default
14799  and 
14800 \family sans
14801 Affiliation
14802 \family default
14803  layouts are exactly equivalent, so you shouldn't need to use both.
14804 \begin_inset Foot
14805 status collapsed
14806
14807 \begin_layout Standard
14808
14809 In case you're curious, both were included so that 
14810 \family typewriter
14811 reLyX
14812 \family default
14813  would be able to translate both 
14814 \family typewriter
14815
14816 \backslash
14817 address
14818 \family default
14819  and 
14820 \family typewriter
14821
14822 \backslash
14823 affiliation
14824 \family default
14825 .
14826 \end_layout
14827
14828 \end_inset
14829
14830
14831 \end_layout
14832
14833 \begin_layout Subsection
14834
14835 Important Notes
14836 \end_layout
14837
14838 \begin_layout Standard
14839
14840 There are a couple of important unique aspects of RevTeX 4 which might cause
14841  bugs that will be even more confusing in LyX.
14842 \end_layout
14843
14844 \begin_layout Standard
14845
14846 In RevTeX, the 
14847 \family typewriter
14848
14849 \backslash
14850 thanks
14851 \family default
14852  command goes 
14853 \emph on
14854 outside
14855 \emph default
14856  the 
14857 \family typewriter
14858
14859 \backslash
14860 author
14861 \family default
14862  command.
14863  The LyX equivalent is that there is a separate Thanks layout.
14864  Do 
14865 \emph on
14866 not
14867 \emph default
14868  write footnotes in the 
14869 \family sans
14870 Author
14871 \family default
14872  layout, or weird things may happen.
14873  See the RevTeX 4 documentation for more details.
14874 \end_layout
14875
14876 \begin_layout Standard
14877
14878 Also, the 
14879 \family sans
14880 Author\InsetSpace ~
14881 Email
14882 \family default
14883
14884 \family sans
14885 Author\InsetSpace ~
14886 URL
14887 \family default
14888 , and 
14889 \family sans
14890 Thanks
14891 \family default
14892  layouts must be placed 
14893 \emph on
14894 in between
14895 \emph default
14896  the 
14897 \family sans
14898 Author
14899 \family default
14900  layout and the corresponding 
14901 \family sans
14902 Address
14903 \family default
14904  (or equivalent 
14905 \family sans
14906 Affiliation
14907 \family default
14908 ) layout.
14909  If you put the 
14910 \family sans
14911 Thanks
14912 \family default
14913  after the 
14914 \family sans
14915 Address
14916 \family default
14917 , the LaTeX won't compile.
14918 \end_layout
14919
14920 \begin_layout Subsection
14921
14922 Drawbacks
14923 \end_layout
14924
14925 \begin_layout Standard
14926
14927 The main problem with this layout is that you can't use the optional arguments
14928  to layouts like Email and Title.
14929  (The problem is not unique to this layout; you can't use optional arguments
14930  to the Section layouts either.) This means that after you export that file
14931  to LaTeX (which you'll need to do eventually to send it in to APS), you'll
14932  need to edit the LaTeX file with a text editor to add the optional arguments
14933  to set, e.g., the running title for the page headers.
14934  Lacking these layouts makes the 
14935 \family typewriter
14936
14937 \backslash
14938 altaffiliation
14939 \family default
14940  (and the equivalent 
14941 \family typewriter
14942
14943 \backslash
14944 altaddress
14945 \family default
14946 ) useless, so the corresponding layouts don't exist, and will have to be
14947  added by hand.
14948 \begin_inset Foot
14949 status collapsed
14950
14951 \begin_layout Standard
14952
14953
14954 \emph on
14955 Note from JMarc:
14956 \emph default
14957  actually, LyX 1.3.0 supports some forms of optional arguments, but this layout
14958  has not been updated yet to take advantage of it.
14959 \end_layout
14960
14961 \end_inset
14962
14963  
14964 \end_layout
14965
14966 \begin_layout Section
14967
14968 Article (mwart), book (mwbk) and report (mwrep)
14969 \begin_inset OptArg
14970 status collapsed
14971
14972 \begin_layout Standard
14973
14974 The 
14975 \family typewriter
14976 mw
14977 \family default
14978  Classes
14979 \end_layout
14980
14981 \end_inset
14982
14983
14984 \end_layout
14985
14986 \begin_layout Standard
14987
14988 by 
14989 \noun on
14990 Tomasz Luczak
14991 \end_layout
14992
14993 \begin_layout Standard
14994
14995 The LyX document classes
14996 \emph on
14997  article (mwart)
14998 \emph default
14999
15000 \emph on
15001 report (mwrep)
15002 \emph default
15003  and 
15004 \emph on
15005 book
15006 \emph default
15007  
15008 \emph on
15009 (mwbk)
15010 \emph default
15011  correspond to the LaTeX document classes 
15012 \family typewriter
15013 mwart.cls
15014 \family default
15015
15016 \family typewriter
15017 mwrep.cls
15018 \family default
15019  and 
15020 \family typewriter
15021 mwbk.cls
15022 \family default
15023 , resp.
15024  They are replacements for the standard document classes 
15025 \family typewriter
15026 article.cls
15027 \family default
15028
15029 \family typewriter
15030 report.cls
15031 \family default
15032  and 
15033 \family typewriter
15034 book.cls
15035 \family default
15036 , resp., and fit better to Polish typography conventions in a number of points.
15037  
15038 \end_layout
15039
15040 \begin_layout Standard
15041
15042 Basic differences:
15043 \end_layout
15044
15045 \begin_layout Itemize
15046
15047 Unnumbered titles (with star, eg.
15048  
15049 \family sans
15050 Section*
15051 \family default
15052 ) are added into table of contents,
15053 \end_layout
15054
15055 \begin_layout Itemize
15056
15057 Additional page styles:
15058 \end_layout
15059
15060 \begin_deeper
15061 \begin_layout Description
15062
15063 uheadings header with separated lines,
15064 \end_layout
15065
15066 \begin_layout Description
15067
15068 myheadings custom header, contents headers via commands: 
15069 \family typewriter
15070
15071 \backslash
15072 markright
15073 \family default
15074  and 
15075 \family typewriter
15076
15077 \backslash
15078 markboth
15079 \family default
15080 ,
15081 \end_layout
15082
15083 \begin_layout Description
15084
15085 myuheadings custom header with separated lines,
15086 \end_layout
15087
15088 \begin_layout Description
15089
15090 outer page number is placed on outer side of page
15091 \end_layout
15092 \end_deeper
15093 \begin_layout Itemize
15094
15095 Options 
15096 \end_layout
15097
15098 \begin_deeper
15099 \begin_layout Description
15100
15101 rmheadings serif titles --- default,
15102 \end_layout
15103
15104 \begin_layout Description
15105
15106 sfheadings sansserif titles,
15107 \end_layout
15108
15109 \begin_layout Description
15110
15111 authortitle on title page first placed is author next title --- default,
15112 \end_layout
15113
15114 \begin_layout Description
15115
15116 titleauthor on title page first placed is title next author,
15117 \end_layout
15118
15119 \begin_layout Description
15120
15121 withmarginpar reserve place on page for margins.
15122 \end_layout
15123 \end_deeper
15124 \begin_layout Section
15125
15126 Elsevier Journals
15127 \end_layout
15128
15129 \begin_layout Standard
15130
15131 By 
15132 \noun on
15133 Rod Pinna
15134 \end_layout
15135
15136 \begin_layout Standard
15137
15138 Elsevier Science Publishers B.V.
15139  provides a standard LaTeX document class (
15140 \family typewriter
15141 elsart.cls
15142 \family default
15143 ) for submitting articles to their various journals.
15144  The style file can be downloaded directly from their web site: 
15145 \begin_inset LatexCommand \url{http://authors.elsevier.com/}
15146
15147 \end_inset
15148
15149 .
15150  Instructions are supplied along with the class file, which details the
15151  requirements of the publishers.
15152  LyX includes package that allows for the use of this class, by a layout
15153  and a template file.
15154  Installation of the class file is the same as for any other LaTeX package;
15155  instructions are provided in the Elsevier documentation.
15156 \end_layout
15157
15158 \begin_layout Standard
15159
15160 To make use of 
15161 \family typewriter
15162 elsart.cls
15163 \family default
15164 , a file 
15165 \family typewriter
15166 elsart.layout
15167 \family default
15168  is supplied.
15169  As the Elsevier class file is based mainly on the standard article class,
15170  most of the normal functionality is provided.
15171  The Elsevier class defines a number of mathematical environments, which
15172  are similar to the AMS environments.
15173  These commands are all described in the Elsevier documentation, and are
15174  available in LyX.
15175 \end_layout
15176
15177 \begin_layout Standard
15178
15179 The easiest way to use the Elsevier style is to base documents on the included
15180  template file.
15181  It is best not to use options such as fancy headings or the geometry package,
15182  as elements such as these are defined by Elsevier in their style file.
15183  Ideally, no extra packages except those mentioned in the Elsevier documentation
15184  should be used.
15185  Essentially, Elsevier require as 
15186 \begin_inset Quotes eld
15187 \end_inset
15188
15189 clean
15190 \begin_inset Quotes erd
15191 \end_inset
15192
15193  a 
15194 \begin_inset ERT
15195 status collapsed
15196
15197 \begin_layout Standard
15198
15199 \backslash
15200 LaTeX
15201 \end_layout
15202
15203 \end_inset
15204
15205  file as possible, as their intention is to take the supplied file and replace
15206  the class file with one for the particular journal to which the paper has
15207  been submitted.
15208  This also means that not too much time should be spent on the formating
15209  of the document.
15210  When it comes to be published, this will change anyway.
15211  The rest of the usage for this layout is substantially the same as for
15212  the normal article class.
15213  For details of what Elsevier do and don't allow, refer to their documentation.
15214 \end_layout
15215
15216 \begin_layout Section
15217
15218 Memoir
15219 \end_layout
15220
15221 \begin_layout Standard
15222
15223 By 
15224 \noun on
15225 Jürgen Spitzmüller
15226 \end_layout
15227
15228 \begin_layout Subsection
15229
15230 Overview
15231 \end_layout
15232
15233 \begin_layout Standard
15234
15235 Memoir is a very powerful and constantly evolving class.
15236  It has been designed with regard to fictional and non-fictional literature.
15237  Its aim is to let the user have maximum control over the typesetting of
15238  his document.
15239  Memoir is based on the standard book class, but it can also emulate the
15240  article class (see below).
15241 \end_layout
15242
15243 \begin_layout Standard
15244
15245 Peter Wilson, the developer of Memoir, is known as the author of lots of
15246  useful packages in the LaTeX world.
15247  Most of them have been merged with Memoir.
15248  Therefore, it is much easier to layout the table of contents, appendices,
15249  chapter designs and such.
15250  LyX, though, does not support all of these goodies natively.
15251  Some of them might be added to forthcoming releases
15252 \begin_inset Foot
15253 status collapsed
15254
15255 \begin_layout Standard
15256
15257 You are invited to send suggestions to 
15258 \begin_inset LatexCommand \url{lyx-devel@lists.lyx.org}
15259
15260 \end_inset
15261
15262 .
15263 \end_layout
15264
15265 \end_inset
15266
15267 , lots will probably never, due to the limitations of LyX's framework.
15268  Of course you can still use all features with the help of some native LaTeX
15269  commands (ERT
15270 \begin_inset Foot
15271 status collapsed
15272
15273 \begin_layout Standard
15274
15275 Cf.
15276 \begin_inset ERT
15277 status collapsed
15278
15279 \begin_layout Standard
15280
15281 \backslash
15282  
15283 \end_layout
15284
15285 \end_inset
15286
15287 section\InsetSpace ~
15288
15289 \begin_inset LatexCommand \ref{sec:Inserting-LaTeX-Code}
15290
15291 \end_inset
15292
15293  for details.
15294 \end_layout
15295
15296 \end_inset
15297
15298 ).
15299  In this section, we can only list those features which are natively supported
15300  by LyX.
15301  For detailed descriptions (and for the rest of features) we are recommending
15302  to have a look at the detailed manual of the Memoir class
15303 \begin_inset Foot
15304 status collapsed
15305
15306 \begin_layout Standard
15307
15308 Cf.
15309 \begin_inset ERT
15310 status collapsed
15311
15312 \begin_layout Standard
15313
15314 \backslash
15315  
15316 \end_layout
15317
15318 \end_inset
15319
15320
15321 \begin_inset LatexCommand \url{CTAN:/macros/latex/memoir/memman.pdf}
15322
15323 \end_inset
15324
15325 .
15326 \end_layout
15327
15328 \end_inset
15329
15330 , which is not only a user guide for the class, but also both a comprehensive
15331  description on good typesetting and a superb example for good typesetting
15332  itself.
15333 \end_layout
15334
15335 \begin_layout Subsection
15336
15337 Basic features and restrictions
15338 \end_layout
15339
15340 \begin_layout Standard
15341
15342 Memoir supports basically all features of the standard book classes.
15343  There are, however, some differences, as follows:
15344 \end_layout
15345
15346 \begin_layout Description
15347
15348 Font\InsetSpace ~
15349 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14,
15350  17
15351 \end_layout
15352
15353 \begin_layout Description
15354
15355 Page\InsetSpace ~
15356 style: The fancy page style is not supported, due to a command clash
15357  between Memoir and the fancyhdr package (they are both defining a command
15358  with the same name, which confuses LaTeX).
15359  Instead, Memoir comes with a bunch of own page styles (see 
15360 \family sans
15361 Layout\SpecialChar \menuseparator
15362 Document\SpecialChar \menuseparator
15363 Page\InsetSpace ~
15364 Style
15365 \family default
15366 ).
15367  If you want to use these for the chapter pages, you have to use the command
15368  
15369 \family typewriter
15370
15371 \backslash
15372 chapterstyle
15373 \family default
15374  in the main text or in preamble (e.
15375 \begin_inset ERT
15376 status collapsed
15377
15378 \begin_layout Standard
15379
15380 \backslash
15381 ,
15382 \end_layout
15383
15384 \end_inset
15385
15386 g.
15387 \begin_inset ERT
15388 status collapsed
15389
15390 \begin_layout Standard
15391
15392 \backslash
15393  
15394 \end_layout
15395
15396 \end_inset
15397
15398
15399 \family typewriter
15400
15401 \backslash
15402 chapterstyle{companion}
15403 \family default
15404 ).
15405 \end_layout
15406
15407 \begin_layout Description
15408
15409 Sectioning: Sectionings (chapter, section, subsection etc.) are coming with
15410  an optional argument in the standard classes.
15411  With this, you can specify an alternative version of the title for the
15412  table of contents and the headers (for instance, if the title is too long).
15413  In LyX, you can do this via 
15414 \family sans
15415 Insert\SpecialChar \menuseparator
15416 Short\InsetSpace ~
15417 Title
15418 \family default
15419  at the beginning of a chapter/section.
15420  Memoir features a second optional argument and thus separates the table
15421  of contents from the header.
15422  You can define three variants of a title with this: one for the main text,
15423  one for the table of contents, and one for the headers.
15424  Simply insert two optional arguments if you need this feature, the first
15425  one containing the short title for the Table of Contents, the second one
15426  containing an alternative short title for the headers.
15427 \end_layout
15428
15429 \begin_layout Description
15430
15431 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15432  of contents, the list of figures and the list of table start a new page
15433  automatically.
15434  Memoir does not follow this route.
15435  You have to insert a page break yourself, if you want to have one.
15436 \end_layout
15437
15438 \begin_layout Description
15439
15440 Titlepage: For some unknown reason, Memoir uses pagination on the title
15441  page (in the standard classes, title pages are 
15442 \begin_inset Quotes eld
15443 \end_inset
15444
15445 empty
15446 \begin_inset Quotes erd
15447 \end_inset
15448
15449 , i.
15450 \begin_inset ERT
15451 status collapsed
15452
15453 \begin_layout Standard
15454
15455 \backslash
15456 ,
15457 \end_layout
15458
15459 \end_inset
15460
15461 e.
15462 \begin_inset ERT
15463 status collapsed
15464
15465 \begin_layout Standard
15466
15467 \backslash
15468  
15469 \end_layout
15470
15471 \end_inset
15472
15473 without pagina).
15474  If you want an empty title page, type 
15475 \family typewriter
15476
15477 \backslash
15478 aliaspagestyle{title}{empty} 
15479 \family default
15480 in the preamble.
15481 \end_layout
15482
15483 \begin_layout Description
15484
15485 Article: With the class option 
15486 \emph on
15487 article 
15488 \emph default
15489 (to be inserted in 
15490 \family sans
15491 Layout\SpecialChar \menuseparator
15492 Document\SpecialChar \menuseparator
15493 Extra\InsetSpace ~
15494 Options
15495 \family default
15496 ), you can emulate article style.
15497  That is, counters (footnotes, figures, tables etc.) will not be reset on
15498  new chapters, chapters don't start a new page (but are---in contrary to
15499  
15500 \begin_inset Quotes eld
15501 \end_inset
15502
15503 real
15504 \begin_inset Quotes erd
15505 \end_inset
15506
15507  article classes---still allowed), parts, though, use their own page, as
15508  in book.
15509 \end_layout
15510
15511 \begin_layout Description
15512
15513 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15514  font commands, which have been used in the old LaTeX version 2.09 (e.
15515 \begin_inset ERT
15516 status collapsed
15517
15518 \begin_layout Standard
15519
15520 \backslash
15521 ,
15522 \end_layout
15523
15524 \end_inset
15525
15526 g.
15527 \begin_inset ERT
15528 status collapsed
15529
15530 \begin_layout Standard
15531
15532 \backslash
15533  
15534 \end_layout
15535
15536 \end_inset
15537
15538
15539 \family typewriter
15540
15541 \backslash
15542 rm
15543 \family default
15544
15545 \family typewriter
15546
15547 \backslash
15548 it
15549 \family default
15550 ).
15551  It produces an error and stops LaTeX whenever such a command appears.
15552  The class option 
15553 \emph on
15554 oldfontcommands
15555 \emph default
15556  reallows the commands and spits out warnings instead (which does at least
15557  not stop LaTeX).
15558  Since a lot of packages and particularly BibTeX style files are still using
15559  those commands, we have decided to use this option by default.
15560 \end_layout
15561
15562 \begin_layout Subsection
15563
15564 Extra features
15565 \end_layout
15566
15567 \begin_layout Standard
15568
15569 We will only describe the features supported by LyX (which is not much currently
15570 ).
15571  Please consult the Memoir manual
15572 \begin_inset Foot
15573 status collapsed
15574
15575 \begin_layout Standard
15576
15577 Cf.
15578 \begin_inset ERT
15579 status collapsed
15580
15581 \begin_layout Standard
15582
15583 \backslash
15584  
15585 \end_layout
15586
15587 \end_inset
15588
15589
15590 \begin_inset LatexCommand \url{CTAN:/macros/latex/memoir/memman.pdf}
15591
15592 \end_inset
15593
15594 .
15595 \end_layout
15596
15597 \end_inset
15598
15599  for details.
15600 \end_layout
15601
15602 \begin_layout Description
15603
15604 Abstract: You may wonder why an abstract is an extra feature.
15605  Well, it is in book class.
15606  Usually books don't have abstracts.
15607  Memoir, however, has.
15608  You can use it whereever and how often you like.
15609 \end_layout
15610
15611 \begin_layout Description
15612
15613 Chapterprecis: You may know this from belletristic: The contents of a chapter
15614  is shortly described below the title and also in the table of contents
15615  (e.
15616 \begin_inset ERT
15617 status collapsed
15618
15619 \begin_layout Standard
15620
15621 \backslash
15622 ,
15623 \end_layout
15624
15625 \end_inset
15626
15627 g.
15628 \begin_inset ERT
15629 status collapsed
15630
15631 \begin_layout Standard
15632
15633 \backslash
15634  
15635 \end_layout
15636
15637 \end_inset
15638
15639
15640 \emph on
15641 Our hero arrives in Troia; he loses some friends; he finds others
15642 \emph default
15643 ).
15644  Chapterprecis does exactly this.
15645  It is therefore only sensible below a chapter.
15646 \end_layout
15647
15648 \begin_layout Description
15649
15650 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
15651  The epigraph environment provides an elegant way of typesetting such a
15652  motto.
15653  The motto itself (text) and its author (source) are divided by a short
15654  line.
15655  Unfortunately, we have to fool LyX a bit here again, since the environment
15656  needs two arguments (text and source).
15657  In this case, we have to use curly brackets (in TeX mode) between the two
15658  arguments: 
15659 \emph on
15660 <smart slogan>
15661 \emph default
15662  
15663 \family typewriter
15664 }{
15665 \family default
15666  
15667 \emph on
15668 <author of the slogan>.
15669 \end_layout
15670
15671 \begin_layout Description
15672
15673 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
15674  complex figurative poems).
15675  Lyx can only support a few of them.
15676  One is poemtitle, which is a centered title for poems, which will also
15677  be added to the table of contents (verse is the standard environment for
15678  poems.
15679  Memoir has some enhanced versions of verse, but you need to use ERT, because
15680  they have to be nested inside regular verse environments, which is not
15681  possible with LyX).
15682 \end_layout
15683
15684 \begin_layout Description
15685
15686 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
15687 \end_layout
15688
15689 \begin_layout Chapter
15690
15691 Importing and Exporting Alternate File Formats
15692 \begin_inset OptArg
15693 status collapsed
15694
15695 \begin_layout Standard
15696
15697 Importing and Exporting
15698 \end_layout
15699
15700 \end_inset
15701
15702
15703 \end_layout
15704
15705 \begin_layout Section
15706
15707 Considerations
15708 \end_layout
15709
15710 \begin_layout Standard
15711
15712 Importing and exporting LyX documents from/to other formats has been touched
15713  on briefly in the 
15714 \emph on
15715 User Guide
15716 \emph default
15717 .
15718  Here we describe more of the gory details needed to understand just what
15719  is going on when you click on the 
15720 \family sans
15721 \bar under
15722 F
15723 \bar default
15724 ile\SpecialChar \menuseparator
15725
15726 \bar under
15727 I
15728 \bar default
15729 mport
15730 \family default
15731  and 
15732 \family sans
15733 \bar under
15734 F
15735 \bar default
15736 ile\SpecialChar \menuseparator
15737 E
15738 \bar under
15739 x
15740 \bar default
15741 port
15742 \family default
15743  menu items.
15744  
15745 \end_layout
15746
15747 \begin_layout Section
15748
15749 Importing Other Formats
15750 \end_layout
15751
15752 \begin_layout Subsection
15753
15754 LaTeX
15755 \end_layout
15756
15757 \begin_layout Standard
15758
15759 Translating from LaTeX into LyX is performed by a Perl script called reLyX.
15760  Although it is a standalone program which can be called from the command
15761  line, LyX will call it automatically when a LaTeX document is imported.
15762  See section\InsetSpace ~
15763
15764 \begin_inset LatexCommand \ref{sec:reLyX}
15765
15766 \end_inset
15767
15768  for a complete description.
15769  There are no user tunable parameters for reLyX within LyX.
15770 \end_layout
15771
15772 \begin_layout Subsection
15773
15774 ASCII Text
15775 \end_layout
15776
15777 \begin_layout Standard
15778
15779 When importing plain ASCII text, there are two methods of reading the file.
15780  Importing 
15781 \begin_inset Quotes eld
15782 \end_inset
15783
15784 as lines
15785 \begin_inset Quotes erd
15786 \end_inset
15787
15788  preserves all the linebreaks in the ASCII; to LyX, then, each line looks
15789  like a paragraph.
15790  Importing 
15791 \begin_inset Quotes eld
15792 \end_inset
15793
15794 as paragraphs
15795 \begin_inset Quotes erd
15796 \end_inset
15797
15798  assumes that consecutive lines separated by only a single linebreak form
15799  a single paragraph.
15800  Successive linebreaks with no intervening text are thus assumed to be paragraph
15801  delimiters.
15802 \end_layout
15803
15804 \begin_layout Subsection
15805
15806 Noweb
15807 \end_layout
15808
15809 \begin_layout Standard
15810
15811
15812 \emph on
15813 [Editor's note: Needs to be written, obviously - any volunteers? --- mer]
15814 \end_layout
15815
15816 \begin_layout Section
15817
15818 Exporting Other Formats
15819 \end_layout
15820
15821 \begin_layout Subsection
15822
15823 LaTeX
15824 \end_layout
15825
15826 \begin_layout Standard
15827
15828 LyX generates two types of LaTeX files: stripped down versions for the normal
15829  processing (
15830 \family sans
15831 View DVI
15832 \family default
15833 , etc.) which one normally never sees
15834 \begin_inset Foot
15835 status collapsed
15836
15837 \begin_layout Standard
15838
15839 The resulting file is a perfectly valid LaTeX file, though the preamble
15840  might look a bit strange since it includes some definitions used by LyX
15841  which wouldn't show up in most human-written files.
15842 \end_layout
15843
15844 \end_inset
15845
15846 , and human readable forms which are suitable for exchanging with your colleague
15847 s.
15848  The only settable option for the translation is the line length of the
15849  output file.
15850  The default is 65 characters, but it can be set in 
15851 \family sans
15852 \bar under
15853 T
15854 \bar default
15855 ools
15856 \family default
15857 \SpecialChar \menuseparator
15858
15859 \family sans
15860 \bar under
15861 P
15862 \bar default
15863 references
15864 \family default
15865  using the 
15866 \family sans
15867 \bar under
15868 A
15869 \bar default
15870 scii\InsetSpace ~
15871 line\InsetSpace ~
15872 length
15873 \family default
15874  field.
15875  
15876 \end_layout
15877
15878 \begin_layout Subsection
15879
15880 Device Independent Files
15881 \end_layout
15882
15883 \begin_layout Standard
15884
15885 Device Independent files (DVI files) are produced by running LaTeX on your
15886  document.
15887  There are no user settable options.
15888 \end_layout
15889
15890 \begin_layout Subsection
15891
15892 PostScript®
15893 \end_layout
15894
15895 \begin_layout Standard
15896
15897 The next step in the conversion chain is converting a DVI file into Postscript®.
15898  You can either use 
15899 \family sans
15900 \bar under
15901 F
15902 \bar default
15903 ile
15904 \family default
15905 \SpecialChar \menuseparator
15906
15907 \family sans
15908 \bar under
15909 E
15910 \bar default
15911 xport
15912 \family default
15913 \SpecialChar \menuseparator
15914
15915 \family sans
15916 Pos
15917 \bar under
15918 t
15919 \bar default
15920 script
15921 \family default
15922  or, if you need more control on the result, 
15923 \family sans
15924 \bar under
15925 F
15926 \bar default
15927 ile
15928 \family default
15929 \SpecialChar \menuseparator
15930
15931 \family sans
15932 \bar under
15933 P
15934 \bar default
15935 rint
15936 \family default
15937 .
15938  If you use the later, note that it is possible to configure, in 
15939 \family sans
15940 \bar under
15941 T
15942 \bar default
15943 ools
15944 \family default
15945 \SpecialChar \menuseparator
15946
15947 \family sans
15948 \bar under
15949 P
15950 \bar default
15951 references
15952 \family default
15953 , the options passed to the dvips program to achieve different effects.
15954 \end_layout
15955
15956 \begin_layout Subsection
15957
15958 ASCII text
15959 \end_layout
15960
15961 \begin_layout Standard
15962
15963 Exporting as ASCII attempts to preserve the 
15964 \begin_inset Quotes eld
15965 \end_inset
15966
15967 shape
15968 \begin_inset Quotes erd
15969 \end_inset
15970
15971  of the document as well as possible, but things like centering and indentation
15972  are thrown out; paragraphs are separated by blank lines.
15973  Section numbering and cross-references are done correctly, so the resulting
15974  text files is remarkably readable.
15975  The only changeable option is the length of lines, as for LaTeX output.
15976 \end_layout
15977
15978 \begin_layout Subsection
15979
15980 HTML
15981 \end_layout
15982
15983 \begin_layout Standard
15984
15985 LyX documents can be converted to hypertext markup, usually by converting
15986  to LaTeX first, then converting that to HTML\SpecialChar \@.
15987  Three LaTeX
15988 \begin_inset Formula $\rightarrow$
15989 \end_inset
15990
15991 HTML converters are currently known to LyX: 
15992 \family typewriter
15993 tth
15994 \family default
15995
15996 \family typewriter
15997 latex2html
15998 \family default
15999 , and 
16000 \family typewriter
16001 hevea
16002 \family default
16003 .
16004  Though they are autodetected, you can overide the selection in preferences.
16005  You can also include further command line options in this dialog.
16006  
16007 \end_layout
16008
16009 \begin_layout Subsection
16010
16011 PDF
16012 \end_layout
16013
16014 \begin_layout Standard
16015
16016 by 
16017 \noun on
16018 Dekel Tsur
16019 \noun default
16020  (mostly)
16021 \end_layout
16022
16023 \begin_layout Standard
16024
16025
16026 \begin_inset VSpace bigskip
16027 \end_inset
16028
16029
16030 \end_layout
16031
16032
16033 \begin_layout Standard
16034
16035 The fastest way to generate a basic PDF file (no tags, links, etc.) with
16036  any version of LyX is to save the document as a Postscript® file, then
16037  run the 
16038 \family typewriter
16039 ps2pdf
16040 \family default
16041  command on it.
16042  Starting with version 1.1.6, the menu item 
16043 \family sans
16044 File->Export->PDF
16045 \family default
16046  will do all this for you.
16047  There are some issues with fonts that you need to pay attention to: see
16048  Section\InsetSpace ~
16049
16050 \begin_inset LatexCommand \ref{sec:badfonts}
16051
16052 \end_inset
16053
16054 .
16055  Also, as of version 1.1.6, there is a better method that will generate much
16056  more sophisticated files.
16057 \end_layout
16058
16059 \begin_layout Subsubsection
16060
16061 Use pdfLaTeX
16062 \end_layout
16063
16064 \begin_layout Standard
16065
16066 With pdfLaTeX you need to convert your eps figures to PDF (see Section\InsetSpace ~
16067
16068 \begin_inset LatexCommand \ref{sec:pdfeps}
16069
16070 \end_inset
16071
16072 ), and you cannot use pstricks.
16073  On the other hand, with pdfLaTeX it is possible to insert directly images
16074  in JPEG or PNG format, use TrueType fonts, and more.
16075 \end_layout
16076
16077 \begin_layout Subsubsection
16078
16079 Why does the text look so bad when viewed with Acrobat Reader?
16080 \begin_inset LatexCommand \label{sec:badfonts}
16081
16082 \end_inset
16083
16084
16085 \begin_inset OptArg
16086 status collapsed
16087
16088 \begin_layout Standard
16089
16090 Bad Fonts in Acrobat Reader
16091 \end_layout
16092
16093 \end_inset
16094
16095
16096 \end_layout
16097
16098 \begin_layout Standard
16099
16100 The problem is that bitmap fonts are displayed poorly by Acrobat Reader.
16101  When creating a PDF from the LyX file, you need to use outline font instead
16102  of the default bitmap fonts (in fact, you should also use outline fonts
16103  for Postscript files).
16104  Recent LaTeX distributions come with Postscript® Type 1 version of the
16105  standard (Computer Modern) fonts.
16106  pdfLaTeX uses these font by default.
16107  Dvips doesn't use these fonts by default, so to make it use them, add the
16108  following to lines to your 
16109 \family typewriter
16110 ~/.dvipsrc
16111 \family default
16112  file
16113 \end_layout
16114
16115 \begin_layout LyX-Code
16116
16117 p+ psfonts.cmz
16118 \end_layout
16119
16120 \begin_layout LyX-Code
16121
16122 p+ psfonts.amz
16123 \end_layout
16124
16125 \begin_layout Standard
16126
16127 If the default LaTeX font encoding (OT1) is used, nothing else need to be
16128  done.
16129  However, if the T1 font encoding is used, then LaTeX uses the newer EC
16130  fonts, for which there are no Type1 version.
16131  The solution is to use the ae package which emulates T1 coded fonts using
16132  the standard CM fonts.
16133  This is done by adding 
16134 \family typewriter
16135
16136 \backslash
16137 usepackage{ae,aecompl}
16138 \family default
16139  to the preamble of the LyX file.
16140  However, some glyphs are missing from the CM fonts (e.g.
16141  eth, thorn), and they are taken from the EC fonts.
16142  Therefore you get these glyphs as bitmaps.
16143 \end_layout
16144
16145 \begin_layout Standard
16146
16147 Note: LyX uses by default the T1 font encoding.
16148  If you wish to use the default font encoding (this is not recommended,
16149  unless you only write English documents), clear the field 
16150 \family sans
16151 \bar under
16152 T
16153 \bar default
16154 eX\InsetSpace ~
16155 encoding
16156 \family default
16157  in preferences (tabs 
16158 \family sans
16159 Outputs
16160 \family default
16161
16162 \family sans
16163 Misc
16164 \family default
16165 ).
16166  
16167 \end_layout
16168
16169 \begin_layout Standard
16170
16171 An alternate option is to use the standard Postscript® fonts instead of
16172  the Computer Modern fonts.
16173  To do that, you need to select 
16174 \family sans
16175 pslatex
16176 \family default
16177  as the global font in the document layout dialog.
16178  When using the Postscript® fonts, the result PDF file is smaller as the
16179  fonts are not saved into the file.
16180  Furthermore, the Postscript® fonts include all T1 glyphs.
16181  On the other hand, the Postscript® fonts have no bold symbol font, so poor
16182  man's bold must be used (see Section\InsetSpace ~
16183
16184 \begin_inset LatexCommand \ref{sec:pdfbold}
16185
16186 \end_inset
16187
16188 ).
16189  The Postscript® fonts also look different from the Computer Modern fonts.
16190 \end_layout
16191
16192 \begin_layout Standard
16193
16194 To sum up, both the Computer Modern and the Postscript® fonts gives good
16195  results (with few exceptions).
16196  The decision of which one to use is a matter of taste.
16197 \end_layout
16198
16199 \begin_layout Subsubsection
16200
16201 Why doesn't the 
16202 \backslash
16203 boldsymbol{} command work when I use pslatex?
16204 \begin_inset LatexCommand \label{sec:pdfbold}
16205
16206 \end_inset
16207
16208
16209 \begin_inset OptArg
16210 status collapsed
16211
16212 \begin_layout Standard
16213
16214
16215 \family typewriter
16216
16217 \backslash
16218 boldsymbol{}
16219 \family default
16220  and 
16221 \family typewriter
16222 pslatex
16223 \end_layout
16224
16225 \end_inset
16226
16227
16228 \end_layout
16229
16230 \begin_layout Standard
16231
16232 The Postscript® fonts do not have a bold symbol font.
16233  The solution is to use the 
16234 \family typewriter
16235
16236 \backslash
16237 pmb{}
16238 \family default
16239  (poor man's bold) command.
16240 \end_layout
16241
16242 \begin_layout Standard
16243
16244 It is possible to redefine the 
16245 \family typewriter
16246
16247 \backslash
16248 boldsymbol
16249 \family default
16250  command to use 
16251 \family typewriter
16252
16253 \backslash
16254 pmb
16255 \family default
16256  by putting
16257 \end_layout
16258
16259 \begin_layout LyX-Code
16260
16261
16262 \backslash
16263 renewcommand{
16264 \backslash
16265 boldsymbol}[1]{
16266 \backslash
16267 pmb{#1}}
16268 \end_layout
16269
16270 \begin_layout Standard
16271
16272 in the preamble.
16273 \end_layout
16274
16275 \begin_layout Subsubsection
16276
16277 Is it possible to do write latex code which is processed only when running
16278  pdfLaTeX?
16279 \begin_inset OptArg
16280 status collapsed
16281
16282 \begin_layout Standard
16283
16284 Conditionals with pdfLaTeX
16285 \end_layout
16286
16287 \end_inset
16288
16289
16290 \end_layout
16291
16292 \begin_layout Standard
16293
16294 Yes.
16295  Here is an example:
16296 \end_layout
16297
16298 \begin_layout LyX-Code
16299
16300
16301 \backslash
16302 newif 
16303 \backslash
16304 ifpdf
16305 \end_layout
16306
16307 \begin_layout LyX-Code
16308
16309    
16310 \backslash
16311 ifx 
16312 \backslash
16313 pdfoutput 
16314 \backslash
16315 undefined
16316 \end_layout
16317
16318 \begin_layout LyX-Code
16319
16320       
16321 \backslash
16322 pdffalse
16323 \end_layout
16324
16325 \begin_layout LyX-Code
16326
16327    
16328 \backslash
16329 else
16330 \end_layout
16331
16332 \begin_layout LyX-Code
16333
16334       
16335 \backslash
16336 pdftrue
16337 \end_layout
16338
16339 \begin_layout LyX-Code
16340
16341
16342 \backslash
16343 fi
16344 \end_layout
16345
16346 \begin_layout LyX-Code
16347
16348 \end_layout
16349
16350 \begin_layout LyX-Code
16351
16352
16353 \backslash
16354 ifpdf
16355 \end_layout
16356
16357 \begin_layout LyX-Code
16358
16359    
16360 \backslash
16361 pdfinfo { /Author (your name and e-mail address)
16362 \end_layout
16363
16364 \begin_layout LyX-Code
16365
16366       /Title (official title -- i.e., title element)
16367 \end_layout
16368
16369 \begin_layout LyX-Code
16370
16371       /Subject (one line description of the document)
16372 \end_layout
16373
16374 \begin_layout LyX-Code
16375
16376    }
16377 \end_layout
16378
16379 \begin_layout LyX-Code
16380
16381    
16382 \backslash
16383 pdfcatalog { /PageMode (/UseNone)
16384 \end_layout
16385
16386 \begin_layout LyX-Code
16387
16388    % /OpenAction (fitbh)
16389 \end_layout
16390
16391 \begin_layout LyX-Code
16392
16393    }
16394 \end_layout
16395
16396 \begin_layout LyX-Code
16397
16398    
16399 \backslash
16400 usepackage[pdftex]{hyperref}
16401 \end_layout
16402
16403 \begin_layout LyX-Code
16404
16405
16406 \backslash
16407 else
16408 \end_layout
16409
16410 \begin_layout LyX-Code
16411
16412    
16413 \backslash
16414 usepackage[ps2pdf]{hyperref}
16415 \end_layout
16416
16417 \begin_layout LyX-Code
16418
16419
16420 \backslash
16421 fi
16422 \end_layout
16423
16424 \begin_layout Subsubsection
16425
16426 How can I make URLs clickable ?
16427 \end_layout
16428
16429 \begin_layout Standard
16430
16431 See the references here :
16432 \end_layout
16433
16434 \begin_layout Standard
16435
16436
16437 \begin_inset LatexCommand \url{http://wiki.lyx.org/pmwiki.php/FAQ/PDF}
16438
16439 \end_inset
16440
16441
16442 \end_layout
16443
16444 \begin_layout Subsection
16445
16446 Custom
16447 \end_layout
16448
16449 \begin_layout Standard
16450
16451 Custom exports are possible if you have some particularly weird format you
16452  wish to convert to, assuming you have the relevant converter, of course.
16453  The format of the 
16454 \emph on
16455 input
16456 \emph default
16457  file can be chosen in the 
16458 \family sans
16459 \bar under
16460 F
16461 \bar default
16462 ile\SpecialChar \menuseparator
16463
16464 \bar under
16465 E
16466 \bar default
16467 xport\SpecialChar \menuseparator
16468
16469 \bar under
16470 C
16471 \bar default
16472 ustom 
16473 \family default
16474 dialog; LyX will automatically convert the file to this point, then feed
16475  it to your custom converter.
16476  The possible values are all formats that LyX can produce from its own documents.
16477  
16478 \end_layout
16479
16480 \begin_layout Standard
16481
16482 The converter command is also specified in the dialog.It should be a completely
16483  qualified command line which uses the variable 
16484 \family typewriter
16485 $$FName
16486 \family default
16487  to specify the name of the file.
16488  If this variable is not given, then the file will be sent to the standard
16489  input of your command.
16490  You may have to apply a bit of ingenuity to escape this sequence correctly
16491  so that it is compatible with your shell.
16492  
16493 \end_layout
16494
16495 \begin_layout Standard
16496
16497 While it is not possible to save this command using the 
16498 \family sans
16499 Preferences 
16500 \family default
16501 dialog, you can manually edit your 
16502 \family typewriter
16503 .lyx/preferences
16504 \family default
16505  to add a line like
16506 \end_layout
16507
16508 \begin_layout LyX-Code
16509
16510
16511 \backslash
16512 custom_export_command "mycommand $$FName"
16513 \end_layout
16514
16515 \begin_layout Section
16516
16517 The Complete reLyX Description
16518 \begin_inset LatexCommand \label{sec:reLyX}
16519
16520 \end_inset
16521
16522
16523 \end_layout
16524
16525 \begin_layout Subsection
16526
16527 Synopsis
16528 \end_layout
16529
16530 \begin_layout Standard
16531
16532 The simplest way to use reLyX is via the 
16533 \family sans
16534 \bar under
16535 F
16536 \bar default
16537 ile\SpecialChar \menuseparator
16538
16539 \bar under
16540 I
16541 \bar default
16542 mport
16543 \family default
16544  command in LyX.
16545  That runs reLyX on the given file and loads the resulting file into LyX.
16546  You should try that first, and call it from the command line only if you
16547  need to use more complicated options.
16548 \end_layout
16549
16550 \begin_layout Standard
16551
16552
16553 \series bold
16554 reLyX
16555 \series default
16556  [ 
16557 \series bold
16558 -c
16559 \series default
16560  
16561 \shape italic
16562 textclass
16563 \shape default
16564  ] [ 
16565 \series bold
16566 -df
16567 \series default
16568  ] [ 
16569 \series bold
16570 -o
16571 \series default
16572  
16573 \shape italic
16574 outputdir
16575 \shape default
16576  ] [
16577 \series bold
16578  -r
16579 \series default
16580 \shape italic
16581  renv1
16582 \shape default
16583 [,
16584 \shape italic
16585 renv2
16586 \shape default
16587 ...]] [
16588 \series bold
16589  -s
16590 \series default
16591 \shape italic
16592  sfile1
16593 \shape default
16594 [,
16595 \shape italic
16596 sfile2
16597 \shape default
16598 ...]] 
16599 \emph on
16600 inputfile
16601 \end_layout
16602
16603 \begin_layout Standard
16604
16605
16606 \series bold
16607 reLyX
16608 \series default
16609  
16610 \series bold
16611 -p
16612 \series default
16613  
16614 \series bold
16615 -c
16616 \series default
16617  
16618 \shape italic
16619 textclass
16620 \shape default
16621  [ 
16622 \series bold
16623 -df
16624 \series default
16625  ] [ 
16626 \series bold
16627 -o
16628 \series default
16629  
16630 \shape italic
16631 outputdir
16632 \shape default
16633  ] [
16634 \series bold
16635  -r
16636 \series default
16637 \shape italic
16638  renv1
16639 \shape default
16640 [,
16641 \shape italic
16642 renv2
16643 \shape default
16644 ...]] [
16645 \series bold
16646  -s
16647 \series default
16648 \shape italic
16649  sfile1
16650 \shape default
16651 [,
16652 \shape italic
16653 sfile2
16654 \shape default
16655 ...]] 
16656 \emph on
16657 inputfiles
16658 \end_layout
16659
16660 \begin_layout Standard
16661
16662
16663 \series bold
16664 reLyX
16665 \series default
16666  
16667 \series bold
16668 -h
16669 \end_layout
16670
16671 \begin_layout Subsection
16672
16673 Options
16674 \end_layout
16675
16676 \begin_layout Description
16677
16678
16679 \series bold
16680 -c
16681 \series default
16682  Class.
16683  By default, when reLyX sees a 
16684 \family typewriter
16685
16686 \backslash
16687 documentclass{foo}
16688 \family default
16689  command, it creates a file of textclass 
16690 \begin_inset Quotes eld
16691 \end_inset
16692
16693 foo
16694 \begin_inset Quotes erd
16695 \end_inset
16696
16697  and reads the LyX layout file for that class.
16698   Use 
16699 \series bold
16700 -c
16701 \series default
16702  to declare a different textclass (and read a different layout file).
16703 \end_layout
16704
16705 \begin_layout Description
16706
16707
16708 \series bold
16709 -d
16710 \series default
16711  Debug.
16712  By default, reLyX gives sparse output and deletes the temporary files which
16713  were created during translation.
16714  Using the 
16715 \series bold
16716 -d
16717 \series default
16718  flag will create much more output (both to stdout and stderr) and leave
16719  the temporary files around.
16720 \end_layout
16721
16722 \begin_layout Description
16723
16724
16725 \series bold
16726 -f
16727 \series default
16728  Force.
16729  reLyX will not run if the 
16730 \family typewriter
16731 .lyx
16732 \family default
16733  file it would generate already exists Use the 
16734 \series bold
16735 -f
16736 \series default
16737  option (carefully) to clobber any existing files.
16738 \end_layout
16739
16740 \begin_layout Description
16741
16742
16743 \series bold
16744 -h
16745 \series default
16746  Help.
16747  Print out usage information and quit
16748 \end_layout
16749
16750 \begin_layout Description
16751
16752
16753 \series bold
16754 -o
16755 \series default
16756  Output directory.
16757  With this option, all temporary files and LyX output files (for the given
16758  input file, for any included files, or for any file fragments given with
16759  the 
16760 \series bold
16761 -p
16762 \series default
16763  option) will be put into 
16764 \shape italic
16765 outputdir
16766 \shape default
16767 .
16768  Otherwise, for each file 
16769 \emph on
16770 dir/foo.tex
16771 \emph default
16772 , the temporary files and the LyX output file will be created in 
16773 \emph on
16774 dir
16775 \emph default
16776 .
16777  This can be useful if a file includes files from other directories which
16778  you want to consolidate in one directory, or if you don't have write permission
16779  on the directory the LaTeX files are in.
16780 \end_layout
16781
16782 \begin_layout Description
16783
16784
16785 \series bold
16786 -p
16787 \series default
16788  Partial file.
16789  The input files are LaTeX fragments, with no preamble matter or 
16790 \family typewriter
16791
16792 \backslash
16793 begin{document}
16794 \family default
16795  commands.
16796  This option requires the 
16797 \series bold
16798 -c
16799 \series default
16800  option, since there are no 
16801 \family typewriter
16802
16803 \backslash
16804 documentclass
16805 \family default
16806  commands in the files reLyX is translating.
16807  When using this option, you can translate more than one file, as long as
16808  all files are the same class.
16809  The LyX file created by reLyX can be included in an existing LyX file using
16810  
16811 \family sans
16812 \bar under
16813 I
16814 \bar default
16815 nsert\SpecialChar \menuseparator
16816 Fil
16817 \bar under
16818 e
16819 \bar default
16820 \SpecialChar \menuseparator
16821 Ly
16822 \bar under
16823 X
16824 \bar default
16825 \InsetSpace ~
16826 Document
16827 \family default
16828 .
16829 \end_layout
16830
16831 \begin_layout Description
16832
16833
16834 \series bold
16835 -r
16836 \series default
16837  Regular environments (see the Section\InsetSpace ~
16838
16839 \begin_inset LatexCommand \ref{sub:relyx-syntax}
16840
16841 \end_inset
16842
16843 ).
16844   If you give more than one environment, separate them with commas (not
16845  spaces).
16846  You'll probably need to quote the environment list, especially if it has
16847  asterisk environments (foo*) in it.
16848  If you use this command often, considering creating a personal syntax file.
16849 \end_layout
16850
16851 \begin_layout Description
16852
16853
16854 \series bold
16855 -s
16856 \series default
16857  Syntax files.
16858  Input (one or more quoted, comma-separated) syntax files to read in addition
16859  to the default.
16860  (see the section Section\InsetSpace ~
16861
16862 \begin_inset LatexCommand \ref{sub:relyx-syntax}
16863
16864 \end_inset
16865
16866  for details).
16867 \end_layout
16868
16869 \begin_layout Subsection
16870
16871 Description
16872 \end_layout
16873
16874 \begin_layout Subsubsection
16875
16876 Introduction
16877 \end_layout
16878
16879 \begin_layout Standard
16880
16881 reLyX will create a LyX file 
16882 \emph on
16883 dir/foo.lyx
16884 \emph default
16885  from the LaTeX file 
16886 \emph on
16887 dir/foo.tex
16888 \emph default
16889  (unless the 
16890 \series bold
16891 -o
16892 \series default
16893  option is used).
16894 \end_layout
16895
16896 \begin_layout Standard
16897
16898 Suffixes 
16899 \family typewriter
16900 .tex
16901 \family default
16902
16903 \family typewriter
16904 .ltx
16905 \family default
16906  and 
16907 \family typewriter
16908 .latex
16909 \family default
16910  are supported.
16911  If 
16912 \emph on
16913 inputfile
16914 \emph default
16915  does not exist and does not have one of these suffixes, reLyX will try
16916  to translate 
16917 \emph on
16918 inputfile.tex
16919 \emph default
16920 .
16921  (This is similar to the behavior of LaTeX.)
16922 \end_layout
16923
16924 \begin_layout Standard
16925
16926 The purpose of reLyX is to translate 
16927 \shape italic
16928 well-behaved
16929 \shape default
16930  LaTeX2e into LyX.
16931  If your LaTeX file doesn't compile---or if you do weird things, like redefining
16932  standard LaTeX commands---it may choke.
16933  LaTeX209 will often be translated correctly, but it's not guaranteed.
16934 \end_layout
16935
16936 \begin_layout Standard
16937
16938 reLyX has some bugs and lacks a few features.
16939  However, its main goals are:
16940 \end_layout
16941
16942 \begin_layout Itemize
16943
16944 Get through a well-behaved LaTeX2e file without crashing
16945 \end_layout
16946
16947 \begin_layout Itemize
16948
16949 Translate a lot of that file.
16950 \end_layout
16951
16952 \begin_layout Itemize
16953
16954 Localize the parts that can't be translated and copy them in TeX mode
16955 \end_layout
16956
16957 \begin_layout Standard
16958
16959 It achieves these main goals pretty well on most files.
16960 \end_layout
16961
16962 \begin_layout Standard
16963
16964 There are many improvements that can and will be made to reLyX in the future.
16965  However, we wanted to get reLyX out there early on, to make it easier for
16966  new LyX users to read in their existing LaTeX files.
16967 \end_layout
16968
16969 \begin_layout Subsubsection
16970
16971 Usage
16972 \end_layout
16973
16974 \begin_layout Standard
16975
16976 Here's a more lengthy description of what you should do to translate a LaTeX
16977  document into LyX.
16978 \end_layout
16979
16980 \begin_layout Itemize
16981
16982 Run reLyX.
16983 \end_layout
16984
16985 \begin_deeper
16986 \begin_layout Standard
16987
16988 reLyX will inform you of its progress and give any warnings to stderr, so
16989  if you don't want any output at all, try (in csh) 
16990 \begin_inset Quotes eld
16991 \end_inset
16992
16993
16994 \family typewriter
16995 reLyX foo.tex >& /dev/null
16996 \family default
16997
16998 \begin_inset Quotes erd
16999 \end_inset
17000
17001  or (in bash) 
17002 \begin_inset Quotes eld
17003 \end_inset
17004
17005
17006 \family typewriter
17007 reLyX foo.tex
17008 \family default
17009  
17010 \family typewriter
17011 2>&1 >/dev/null
17012 \family default
17013
17014 \begin_inset Quotes erd
17015 \end_inset
17016
17017 .
17018  You should NOT redirect standard output to 
17019 \family typewriter
17020 foo.lyx
17021 \family default
17022 .
17023  
17024 \end_layout
17025 \end_deeper
17026 \begin_layout Itemize
17027
17028 Run LyX on the resulting .lyx file.
17029 \end_layout
17030
17031 \begin_deeper
17032 \begin_layout Standard
17033
17034 In theory, most of the file will have been translated, and anything that's
17035  untranslatable will be highlighted in red (TeX mode).
17036  In theory, LyX will be able to read in the file, and to create printed
17037  documents from it, because all that untranslated red stuff will be passed
17038  directly back to LaTeX, which LyX  uses as a backend.
17039  Unfortunately, reality doesn't always reflect theory.
17040  If reLyX crashes, or LyX cannot read the generated LyX file, see Section\InsetSpace ~
17041
17042 \begin_inset LatexCommand \ref{sub:relyx-bugs}
17043
17044 \end_inset
17045
17046  or the 
17047 \family typewriter
17048 BUGS
17049 \family default
17050  file.
17051 \end_layout
17052 \end_deeper
17053 \begin_layout Itemize
17054
17055 Change things that are in ERT boxes (TeX code) by hand in LyX.
17056 \end_layout
17057
17058 \begin_deeper
17059 \begin_layout Standard
17060
17061 As mentioned above, you should be able to print out the LyX file even without
17062  doing this.
17063  However, changing a command in TeX mode to the corresponding LyX object
17064  will allow you to take advantage of LyX's WYSIWYM editing.
17065 \end_layout
17066
17067 \begin_layout Standard
17068
17069 reLyX is not guaranteed to create a LyX file which generates exactly the
17070  same output as the LaTeX file, but it should come close.
17071  reLyX will generally err on the side of translating less to ensure that
17072  dvi or ps files are accurate, even though this leads to more 
17073 \begin_inset Quotes eld
17074 \end_inset
17075
17076 evil red text
17077 \begin_inset Quotes erd
17078 \end_inset
17079
17080  and less WYSIWYM.
17081 \end_layout
17082 \end_deeper
17083 \begin_layout Itemize
17084
17085 PROOFREAD THE DOCUMENT!!
17086 \end_layout
17087
17088 \begin_deeper
17089 \begin_layout Standard
17090
17091 I'm sure you were planning on doing this anyway, but it's particularly important
17092  after translating a LaTeX document.
17093  reLyX is, at least now, better at 
17094 \begin_inset Quotes eld
17095 \end_inset
17096
17097 macro-translating
17098 \begin_inset Quotes erd
17099 \end_inset
17100
17101  (translating the whole document) than 
17102 \begin_inset Quotes eld
17103 \end_inset
17104
17105 micro-translating
17106 \begin_inset Quotes erd
17107 \end_inset
17108
17109  (translating every little detail).
17110  For example, you may see extra spaces or deleted spaces.
17111  Space handling has improved, but it's not perfect.
17112 \end_layout
17113 \end_deeper
17114 \begin_layout Subsubsection
17115
17116 What reLyX Can Handle
17117 \end_layout
17118
17119 \begin_layout Standard
17120
17121 reLyX understands many LaTeX commands.
17122  It will translate:
17123 \end_layout
17124
17125 \begin_layout Itemize
17126
17127 regular text, including mini-commands like ~, '', 
17128 \family typewriter
17129
17130 \backslash
17131 @
17132 \family default
17133
17134 \family typewriter
17135
17136 \backslash
17137 TeX
17138 \family default
17139 , as well as accented characters like 
17140 \family typewriter
17141
17142 \backslash
17143 '{a}
17144 \family default
17145 , and the special cases ?` and !`
17146 \end_layout
17147
17148 \begin_layout Itemize
17149
17150 title commands like 
17151 \family typewriter
17152
17153 \backslash
17154 author
17155 \family default
17156
17157 \family typewriter
17158
17159 \backslash
17160 date
17161 \family default
17162
17163 \family typewriter
17164
17165 \backslash
17166 title
17167 \family default
17168
17169 \family typewriter
17170
17171 \backslash
17172 thanks
17173 \family default
17174  and the abstract environment
17175 \end_layout
17176
17177 \begin_layout Itemize
17178
17179 heading commands like 
17180 \family typewriter
17181
17182 \backslash
17183 section
17184 \family default
17185  including starred commands (
17186 \family typewriter
17187
17188 \backslash
17189 section*
17190 \family default
17191 )
17192 \end_layout
17193
17194 \begin_layout Itemize
17195
17196 Environments: 
17197 \family typewriter
17198 quote
17199 \family default
17200
17201 \family typewriter
17202 quotation
17203 \family default
17204 , and 
17205 \family typewriter
17206 verse
17207 \family default
17208
17209 \family typewriter
17210 center
17211 \family default
17212
17213 \family typewriter
17214 flushright
17215 \family default
17216 , and 
17217 \family typewriter
17218 flushleft
17219 \end_layout
17220
17221 \begin_layout Itemize
17222
17223
17224 \family typewriter
17225 itemize
17226 \family default
17227
17228 \family typewriter
17229 enumerate
17230 \family default
17231 , and 
17232 \family typewriter
17233 description
17234 \family default
17235  environments, and their 
17236 \family typewriter
17237
17238 \backslash
17239 item
17240 \family default
17241  commands.
17242  Also, well-behaved nested lists
17243 \end_layout
17244
17245 \begin_layout Itemize
17246
17247 cross-referencing commands: 
17248 \family typewriter
17249
17250 \backslash
17251 ref
17252 \family default
17253
17254 \family typewriter
17255
17256 \backslash
17257 pageref
17258 \family default
17259
17260 \family typewriter
17261
17262 \backslash
17263 label
17264 \family default
17265 , and 
17266 \family typewriter
17267
17268 \backslash
17269 cite
17270 \end_layout
17271
17272 \begin_layout Itemize
17273
17274
17275 \family typewriter
17276
17277 \backslash
17278 footnote
17279 \family default
17280  and 
17281 \family typewriter
17282
17283 \backslash
17284 margin
17285 \end_layout
17286
17287 \begin_layout Itemize
17288
17289 font-changing commands including 
17290 \family typewriter
17291
17292 \backslash
17293 em
17294 \family default
17295
17296 \family typewriter
17297
17298 \backslash
17299 emph
17300 \family default
17301
17302 \family typewriter
17303
17304 \backslash
17305 textit
17306 \family default
17307 , and corresponding commands to change family, size, series, and shape
17308 \end_layout
17309
17310 \begin_layout Itemize
17311
17312
17313 \family typewriter
17314
17315 \backslash
17316 input{foo}
17317 \family default
17318  (or 
17319 \family typewriter
17320
17321 \backslash
17322 input{foo.blah}
17323 \family default
17324 ) and 
17325 \family typewriter
17326
17327 \backslash
17328 include{foo}
17329 \family default
17330 .
17331  Plain TeX 
17332 \family typewriter
17333
17334 \backslash
17335 input
17336 \family default
17337  command 
17338 \begin_inset Quotes erd
17339 \end_inset
17340
17341
17342 \family typewriter
17343
17344 \backslash
17345 input foo.tex
17346 \family default
17347
17348 \begin_inset Quotes erd
17349 \end_inset
17350
17351  is also supported.
17352 \end_layout
17353
17354 \begin_layout Itemize
17355
17356
17357 \family typewriter
17358 tabular
17359 \family default
17360  environment, and commands that go inside it like 
17361 \family typewriter
17362
17363 \backslash
17364 hline
17365 \family default
17366
17367 \family typewriter
17368
17369 \backslash
17370 cline
17371 \family default
17372 , and 
17373 \family typewriter
17374
17375 \backslash
17376 multicolumn
17377 \family default
17378  (but see below)
17379 \end_layout
17380
17381 \begin_layout Itemize
17382
17383 float environments 
17384 \family typewriter
17385 table
17386 \family default
17387  and 
17388 \family typewriter
17389 table*
17390 \family default
17391 , as well as 
17392 \family typewriter
17393
17394 \backslash
17395 caption
17396 \family default
17397  commands within them
17398 \end_layout
17399
17400 \begin_layout Itemize
17401
17402
17403 \family typewriter
17404 thebibliography
17405 \family default
17406  environment and 
17407 \family typewriter
17408
17409 \backslash
17410 bibitem
17411 \family default
17412  command, as well as BibTeX's 
17413 \family typewriter
17414
17415 \backslash
17416 bibliography
17417 \family default
17418  and 
17419 \family typewriter
17420
17421 \backslash
17422 bibliographystyle
17423 \family default
17424  commands
17425 \end_layout
17426
17427 \begin_layout Itemize
17428
17429 miscellaneous commands: 
17430 \family typewriter
17431
17432 \backslash
17433 hfill
17434 \family default
17435
17436 \family typewriter
17437
17438 \backslash
17439
17440 \backslash
17441
17442 \family default
17443
17444 \family typewriter
17445
17446 \backslash
17447 noindent
17448 \family default
17449
17450 \family typewriter
17451
17452 \backslash
17453 ldots
17454 \family default
17455 ...
17456 \end_layout
17457
17458 \begin_layout Itemize
17459
17460 documentclass-specific environments (and some commands) which can be  translated
17461  to LyX layouts
17462 \end_layout
17463
17464 \begin_layout Itemize
17465
17466 arguments to certain untranslatable commands (e.g.
17467  
17468 \family typewriter
17469
17470 \backslash
17471 mbox
17472 \family default
17473 )
17474 \end_layout
17475
17476 \begin_layout Standard
17477
17478 Some of this support may not be 100% yet.
17479  See below for details
17480 \end_layout
17481
17482 \begin_layout Standard
17483
17484 reLyX copies math (almost) verbatim from your LaTeX file.
17485  Luckily, LyX reads  in LaTeX math, so (almost) any math which is supported
17486  by LyX should work just fine.
17487  A few math commands which are not supported by LyX will be replaced with
17488  their equivalents, e.g., 
17489 \family typewriter
17490
17491 \backslash
17492 to
17493 \family default
17494  is converted to 
17495 \family typewriter
17496
17497 \backslash
17498 rightarrow
17499 \family default
17500 .
17501  See the section on 
17502 \shape italic
17503 Syntax Files
17504 \shape default
17505  for more details.
17506 \end_layout
17507
17508 \begin_layout Standard
17509
17510 reLyX will also copy any preamble commands (i.e., anything before 
17511 \family typewriter
17512
17513 \backslash
17514 begin{document}
17515 \family default
17516 ) verbatim, so fancy stuff you've got in your preamble should be conserved
17517  in dvi and printed documents, although it will not of course show up in
17518  the LyX window.
17519  Check the preamble to make sure.
17520 \end_layout
17521
17522 \begin_layout Subsubsection
17523
17524 What reLyX Can't Handle --- But it's OK
17525 \end_layout
17526
17527 \begin_layout Itemize
17528
17529 figures and 
17530 \family typewriter
17531 tabular*
17532 \family default
17533  tables
17534 \end_layout
17535
17536 \begin_layout Itemize
17537
17538 minipages
17539 \end_layout
17540
17541 \begin_layout Itemize
17542
17543 spacing commands (
17544 \family typewriter
17545
17546 \backslash
17547 vspace
17548 \family default
17549
17550 \family typewriter
17551
17552 \backslash
17553 pagebreak
17554 \family default
17555
17556 \family typewriter
17557
17558 \backslash
17559 par
17560 \family default
17561 )
17562 \end_layout
17563
17564 \begin_layout Itemize
17565
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
17588 \family typewriter
17589
17590 \backslash
17591 verb
17592 \family default
17593  and 
17594 \family typewriter
17595 verbatim
17596 \family default
17597  environment.
17598  reLyX is careful to copy 
17599 \shape italic
17600 exactly
17601 \shape default
17602  in this case, including comments and whitespace.
17603 \end_layout
17604
17605 \begin_layout Itemize
17606
17607 some unknown (e.g., user-defined) environments and commands
17608 \end_layout
17609
17610 \begin_layout Standard
17611
17612 reLyX copies unknown commands, along with their arguments, verbatim into
17613  the LyX file.
17614  Also, if it sees a 
17615 \family typewriter
17616
17617 \backslash
17618 begin{foo}
17619 \family default
17620  where it doesn't recognize the 
17621 \begin_inset Quotes eld
17622 \end_inset
17623
17624 foo
17625 \begin_inset Quotes erd
17626 \end_inset
17627
17628  environment, it will copy verbatim until it sees 
17629 \family typewriter
17630
17631 \backslash
17632 end{foo}
17633 \family default
17634  (unless you use the 
17635 \series bold
17636 -r
17637 \series default
17638  option).
17639  Hopefully, then, most of these unknown commands won't cause reLyX to break;
17640  they'll merely require you to do some editing once you've loaded the file
17641  up in LyX.
17642   That should be less painful than editing either the 
17643 \family typewriter
17644 .tex
17645 \family default
17646  or the 
17647 \family typewriter
17648 .lyx
17649 \family default
17650  file using a text editor.
17651 \end_layout
17652
17653 \begin_layout Subsubsection
17654
17655 What reLyX Handles Badly --- a.\InsetSpace ~
17656 k.\InsetSpace ~
17657 a.
17658  BUGS
17659 \begin_inset LatexCommand \label{sub:relyx-bugs}
17660
17661 \end_inset
17662
17663
17664 \end_layout
17665
17666 \begin_layout Standard
17667
17668 Since reLyX is relatively new, it's got a number of problems.
17669   As it matures, these bugs will be squished.
17670  A number of bugs and missing features can be found listed on the LyX bug
17671  tracker, 
17672 \begin_inset LatexCommand \url[LyX Bugzilla]{http://bugzilla.lyx.org/}
17673
17674 \end_inset
17675
17676 .
17677 \end_layout
17678
17679 \begin_layout Standard
17680
17681 If reLyX is choking on something, or LyX can't read it after reLyX translates
17682  it, the best thing to do is to put 
17683 \family typewriter
17684
17685 \backslash
17686 begin{reLyXskip}
17687 \family default
17688  before the offending text, and 
17689 \family typewriter
17690
17691 \backslash
17692 end{reLyXskip}
17693 \family default
17694  after it.
17695  I call this a 
17696 \begin_inset Quotes eld
17697 \end_inset
17698
17699 skip
17700 \begin_inset Quotes erd
17701 \end_inset
17702
17703  block.
17704  reLyX will copy this block exactly, in TeX mode.
17705  Then edit the resulting LyX file, and translate the unknown stuff by hand.
17706  The 
17707 \family typewriter
17708 reLyXskip
17709 \family default
17710  environment is magical; the 
17711 \family typewriter
17712
17713 \backslash
17714 begin
17715 \family default
17716  and 
17717 \family typewriter
17718
17719 \backslash
17720 end
17721 \family default
17722  commands will not be put into the LyX file.
17723 \end_layout
17724
17725 \begin_layout Itemize
17726
17727
17728 \begin_inset Quotes eld
17729 \end_inset
17730
17731 Exact
17732 \begin_inset Quotes erd
17733 \end_inset
17734
17735  copying of unknown environments and commands isn't quite exact.
17736  Specifically, newlines and comments may be lost.
17737  This will yield ugly LyX, but in almost all cases the output will be the
17738  same.
17739  However, certain parts of the file will be copied perfectly, including
17740  whitespace and comments.
17741  This includes: the LaTeX preamble, 
17742 \family typewriter
17743 verbatim
17744 \family default
17745  environments and 
17746 \family typewriter
17747
17748 \backslash
17749 verb
17750 \family default
17751  commands, and skip blocks.
17752 \end_layout
17753
17754 \begin_layout Itemize
17755
17756 reLyX translates only a few options to the 
17757 \family typewriter
17758
17759 \backslash
17760 documentclass
17761 \family default
17762  command.
17763  (Specifically 1[012]pt, [letter|legal|executive|a4|a5|b5]paper, [one|two]side,
17764  landscape, and [one|two]column.) Other options are placed in the extra class
17765  options field in the 
17766 \family sans
17767 \bar under
17768 D
17769 \bar default
17770 ocument\SpecialChar \menuseparator
17771
17772 \bar under
17773 S
17774 \bar default
17775 ettings
17776 \family default
17777  dialog.
17778 \end_layout
17779
17780 \begin_deeper
17781 \begin_layout Standard
17782
17783 More importantly, reLyX doesn't translate 
17784 \family typewriter
17785
17786 \backslash
17787 usepackage
17788 \family default
17789  commands, margin  commands, 
17790 \family typewriter
17791
17792 \backslash
17793 newcommand
17794 \family default
17795 s, or, in fact, anything else from the preamble.
17796  It simply copies them into the LaTeX preamble.
17797  If you have margin commands in your preamble, then the LyX file will generate
17798  the right margins.
17799  However, these margins will override any margins you set in the LyX 
17800 \family sans
17801 \bar under
17802 D
17803 \bar default
17804 ocument
17805 \bar under
17806 \SpecialChar \menuseparator
17807 S
17808 \bar default
17809 ettings
17810 \family default
17811  dialog.
17812  So you should remove the options from the preamble to be safe.
17813  The same goes for setting your language with babel, 
17814 \family typewriter
17815
17816 \backslash
17817 inputencoding
17818 \family default
17819
17820 \family typewriter
17821
17822 \backslash
17823 pagestyle
17824 \family default
17825 , etc.
17826 \end_layout
17827 \end_deeper
17828 \begin_layout Itemize
17829
17830 The foil class has a couple bugs.
17831  reLyX may do weird things with optional arguments to 
17832 \family typewriter
17833
17834 \backslash
17835 foilhead
17836 \family default
17837  commands.
17838  Also, it may handle 
17839 \family typewriter
17840
17841 \backslash
17842 begin{dinglist}
17843 \family default
17844  incorrectly (although the stuff in the environment should translate normally).
17845 \end_layout
17846
17847 \begin_layout Standard
17848
17849 reLyX is hopefully rather robust.
17850  As mentioned above, it may not translate your file perfectly, but it shouldn't
17851  crash.
17852  If it does crash---and the problem is not one of those mentioned above
17853  or in the 
17854 \emph on
17855 BUGS
17856 \emph default
17857  file---see Section\InsetSpace ~
17858
17859 \begin_inset LatexCommand \ref{sub:relyx-bug-reports}
17860
17861 \end_inset
17862
17863 .
17864 \end_layout
17865
17866 \begin_layout Subsubsection
17867
17868 What LyX Can't Handle
17869 \end_layout
17870
17871 \begin_layout Standard
17872
17873 LyX itself is missing a couple features, such that even if reLyX translates
17874  things perfectly, LyX may still have trouble reading it.
17875  If you really need these features, you can export your final document as
17876  LaTeX, and put them back in.
17877  See 
17878 \emph on
17879 BUGS
17880 \emph default
17881  for more details on these bugs.
17882 \end_layout
17883
17884 \begin_layout Itemize
17885
17886 For a number of commands, LyX does not support the optional argument.
17887  Examples include 
17888 \family typewriter
17889
17890 \backslash
17891 sqrt
17892 \family default
17893
17894 \family typewriter
17895
17896 \backslash
17897 chapter
17898 \family default
17899  (and other sectioning commands), and 
17900 \family typewriter
17901
17902 \backslash
17903
17904 \backslash
17905
17906 \family default
17907 .
17908  reLyX will automatically discard the optional arguments with a warning
17909  to stdout.
17910  LyX also ignores the width argument for the 
17911 \family typewriter
17912 thebibliography
17913 \family default
17914  environment.
17915 \end_layout
17916
17917 \begin_layout Itemize
17918
17919 Centering (or right or left justifying) works on full paragraphs.
17920 \end_layout
17921
17922 \begin_layout Itemize
17923
17924 LyX support for tables isn't perfect.
17925  For complicated tables, use a 
17926 \begin_inset Quotes eld
17927 \end_inset
17928
17929 skip
17930 \begin_inset Quotes erd
17931 \end_inset
17932
17933  block, so that they will be copied in TeX mode.
17934 \end_layout
17935
17936 \begin_layout Itemize
17937
17938 The LyX math editor can't handle the AMS-LaTeX math environments align,
17939  split, etc.
17940  So those environments will be copied in TeX mode.
17941  You can change 
17942 \family typewriter
17943 equation*
17944 \family default
17945  environments to the exactly equivalent displaymath, and then they will
17946  be translated correctly.
17947 \end_layout
17948
17949 \begin_layout Subsection
17950
17951 Examples
17952 \end_layout
17953
17954 \begin_layout Standard
17955
17956
17957 \family typewriter
17958 reLyX -df -o 
17959 \begin_inset Quotes eld
17960 \end_inset
17961
17962 my/dir
17963 \begin_inset Quotes erd
17964 \end_inset
17965
17966  -r 
17967 \begin_inset Quotes eld
17968 \end_inset
17969
17970 myenv
17971 \begin_inset Quotes erd
17972 \end_inset
17973
17974  foo.tex > foo.debug
17975 \end_layout
17976
17977 \begin_layout Standard
17978
17979 The above will create a file my/dir/foo.lyx from foo.tex, overwriting if necessary.
17980   When it finds a 
17981 \family typewriter
17982
17983 \backslash
17984 begin{myenv} ...
17985  
17986 \backslash
17987 end{myenv}
17988 \family default
17989  block, it will translate the stuff within the block, but copy the 
17990 \family typewriter
17991
17992 \backslash
17993 begin
17994 \family default
17995  and 
17996 \family typewriter
17997
17998 \backslash
17999 end
18000 \family default
18001  commands in TeX mode.
18002   Finally, I'm going to keep the temporary files around (they will also
18003  be in my/dir/) and output lots of debugging information into the file foo.debug.
18004 \end_layout
18005
18006 \begin_layout Subsection
18007
18008 Notes
18009 \end_layout
18010
18011 \begin_layout Subsubsection
18012
18013 Bug Reports
18014 \begin_inset LatexCommand \label{sub:relyx-bug-reports}
18015
18016 \end_inset
18017
18018
18019 \end_layout
18020
18021 \begin_layout Standard
18022
18023 If reLyX is crashing or otherwise acting strangely---in ways other than
18024  those described in Section\InsetSpace ~
18025
18026 \begin_inset LatexCommand \ref{sub:relyx-bugs}
18027
18028 \end_inset
18029
18030  or the bug tracker---then please run reLyX
18031 \series bold
18032  -d
18033 \series default
18034 .
18035   That will allow you to figure out where in the reLyXing process it crashed.
18036  That, in turn, will allow you to write a better bug report, which will
18037  allow the developers to fix it more quickly and easily.
18038 \end_layout
18039
18040 \begin_layout Standard
18041
18042 Bug reports should be sent to the LyX developers' mailing list.
18043  Its address is currently 
18044 \family typewriter
18045 lyx-devel@lists.lyx.org
18046 \family default
18047 .
18048  If you are running reLyX on a huge file, please do not send all of the
18049  output in your bug report.
18050  Just include the last ten or twenty lines of output, along with the piece
18051  of the LaTeX file it crashed on.
18052   Or, even better, attach a small but complete file which causes the same
18053  problem as your original file.
18054 \end_layout
18055
18056 \begin_layout Subsubsection
18057
18058 Implementation Details:
18059 \end_layout
18060
18061 \begin_layout Standard
18062
18063 reLyX makes several 
18064 \begin_inset Quotes eld
18065 \end_inset
18066
18067 passes
18068 \begin_inset Quotes erd
18069 \end_inset
18070
18071  in order to translate a TeX file.
18072  On each pass, it creates one or two files.
18073 \end_layout
18074
18075 \begin_layout Description
18076
18077 Pass\InsetSpace ~
18078 0 \InsetSpace ~
18079
18080 \newline
18081 Before doing anything, read the syntax file (or files).
18082 \end_layout
18083
18084 \begin_layout Description
18085
18086 Pass\InsetSpace ~
18087 1a \InsetSpace ~
18088
18089 \newline
18090 Split preamble (anything before a 
18091 \family typewriter
18092
18093 \backslash
18094 begin{document}
18095 \family default
18096  command) off the rest of the file.
18097  It saves the two pieces in separate files.
18098  This is necessary because there may be very strange stuff in a preamble.
18099  It also ignores anything after the 
18100 \family typewriter
18101
18102 \backslash
18103 end{document}
18104 \family default
18105 , on the assumption that it isn't LaTeX.
18106 \end_layout
18107
18108 \begin_layout Description
18109
18110 Pass\InsetSpace ~
18111 1b \InsetSpace ~
18112
18113 \newline
18114 Translate the preamble.
18115  Currently, that just means translating the 
18116 \family typewriter
18117
18118 \backslash
18119 documentclass
18120 \family default
18121  command and copying the rest exactly into the LyX preamble.
18122 \end_layout
18123
18124 \begin_deeper
18125 \begin_layout Standard
18126
18127 Once you know what class the document is, read the LyX layout file for that
18128  class.
18129 \end_layout
18130 \end_deeper
18131 \begin_layout Description
18132
18133 Pass\InsetSpace ~
18134 2 \InsetSpace ~
18135
18136 \newline
18137
18138 \begin_inset Quotes eld
18139 \end_inset
18140
18141 Clean
18142 \begin_inset Quotes erd
18143 \end_inset
18144
18145  the TeX file, generating slightly stricter LaTeX.
18146  This includes:
18147 \end_layout
18148
18149 \begin_deeper
18150 \begin_layout Itemize
18151
18152 Change, e.g., 
18153 \family typewriter
18154 x^2
18155 \family default
18156  to the equivalent but clearer 
18157 \family typewriter
18158 x^{2}
18159 \end_layout
18160
18161 \begin_layout Itemize
18162
18163 Removing optional arguments that LyX can't handle (e.g., from 
18164 \family typewriter
18165
18166 \backslash
18167 sqrt
18168 \family default
18169 )
18170 \end_layout
18171
18172 \begin_layout Itemize
18173
18174 Changing 
18175 \family typewriter
18176 {
18177 \backslash
18178 em foo}
18179 \family default
18180  to 
18181 \family typewriter
18182
18183 \backslash
18184 emph{foo}
18185 \family default
18186 , etc.
18187  This is necessary because LyX always writes out the non-local forms anyway.
18188  This should very rarely make a difference.
18189 \end_layout
18190 \end_deeper
18191 \begin_layout Description
18192
18193 Pass\InsetSpace ~
18194 3 \InsetSpace ~
18195
18196 \newline
18197 Translate LaTeX text, commands, and environments to LyX.
18198 \end_layout
18199
18200 \begin_layout Description
18201
18202 Pass\InsetSpace ~
18203 4 \InsetSpace ~
18204
18205 \newline
18206 Put the two pieces back together, and do some final tweaking, to generate
18207  the LyX file
18208 \end_layout
18209
18210 \begin_layout Standard
18211
18212 If there are any 
18213 \family typewriter
18214
18215 \backslash
18216 input
18217 \family default
18218  or 
18219 \family typewriter
18220
18221 \backslash
18222 include
18223 \family default
18224  commands, reLyX will loop back to the beginning and translate those.
18225  It assumes that the included files are the same class as the main file,
18226  and that they have no preamble matter.
18227  (If you have an 
18228 \family typewriter
18229
18230 \backslash
18231 input
18232 \family default
18233  command in the preamble of a file, the command will be copied exactly into
18234  the LaTeX preamble portion of the LyX file, so the included file won't
18235  be translated.) So when translating included files, it skips passes 0 and
18236  1.
18237 \end_layout
18238
18239 \begin_layout Standard
18240
18241 If reLyX doesn't find a file you wanted to include, it will give a warning,
18242  but will continue to translate any files it does find.
18243 \end_layout
18244
18245 \begin_layout Subsubsection
18246
18247 Layout Files
18248 \end_layout
18249
18250 \begin_layout Standard
18251
18252 reLyX reads a LyX layout file to know how to handle LaTeX environments and
18253  commands which get translated to LyX layouts.
18254  This file will include all 
18255 \begin_inset Quotes eld
18256 \end_inset
18257
18258 normal
18259 \begin_inset Quotes erd
18260 \end_inset
18261
18262  non-math environments (i.e., including quote and itemize, but not tabular,
18263  minipage, and some other fancy environments), and commands like 
18264 \family typewriter
18265
18266 \backslash
18267 section
18268 \family default
18269  and 
18270 \family typewriter
18271
18272 \backslash
18273 title
18274 \family default
18275 .
18276  If you want to reLyX a class that doesn't have an existing layout file,
18277  then you'll have to create a layout file.
18278  But you have to do this anyway, in order to LyX the file, since LyX depends
18279  on layout files to know how to display and process its files.
18280  Check the LyX documentation for help with this task (which can be hard
18281  or easy, depending on the class you want to create a layout file for.) If
18282  your class is quite similar to a class that has a layout file, then consider
18283  using the 
18284 \series bold
18285 -c
18286 \series default
18287  option.
18288 \end_layout
18289
18290 \begin_layout Subsubsection
18291
18292 Syntax Files
18293 \begin_inset LatexCommand \label{sub:relyx-syntax}
18294
18295 \end_inset
18296
18297
18298 \end_layout
18299
18300 \begin_layout Standard
18301
18302 reLyX always reads at least one syntax file, called the default syntax file.
18303  reLyX will read your personal syntax file if it exists; otherwise it will
18304  read the system-wide file.
18305  reLyX will read additional syntax files if you specify them with the 
18306 \series bold
18307 -s
18308 \series default
18309  option.
18310  (These extra files should have the same format as the default file, but
18311  will tend to be shorter, since they only have to specify extra commands
18312  not found in the default file.) A syntax file tells reLyX a few things.
18313 \end_layout
18314
18315 \begin_layout Standard
18316
18317 First, it describes the syntax of each command, that is, how many required
18318  arguments and how many optional arguments the command takes.
18319  Knowing this makes it easier for reLyX to copy (in TeX mode) commands that
18320  it doesn't know how to translate.
18321  The syntax file simply has a command, followed by braces or brackets describing
18322  its arguments in the correct order.
18323  For example, a syntax file entry 
18324 \family typewriter
18325
18326 \backslash
18327 bibitem[]{}
18328 \family default
18329  means that the 
18330 \family typewriter
18331
18332 \backslash
18333 bibitem
18334 \family default
18335  command takes an optional argument followed by a required one, while the
18336  entry 
18337 \family typewriter
18338
18339 \backslash
18340 bf
18341 \family default
18342  means that the 
18343 \family typewriter
18344
18345 \backslash
18346 bf
18347 \family default
18348  command takes no arguments at all.
18349   When reLyX encounters a token that it doesn't know how to translate into
18350  LyX, it will copy the token---along with the correct number of arguments---exac
18351 tly.
18352   If the token is not in the syntax file, then reLyX just copies as many
18353  arguments as it finds.
18354   This means that it may copy too much.
18355  But since the user can specify additional syntax files, that shouldn't
18356  happen often.
18357 \end_layout
18358
18359 \begin_layout Standard
18360
18361 Some commands that cannot be translated to LyX, like 
18362 \family typewriter
18363
18364 \backslash
18365 mbox
18366 \family default
18367 , have as one of their arguments regular LaTeX text.
18368  If the string 
18369 \begin_inset Quotes eld
18370 \end_inset
18371
18372 translate
18373 \begin_inset Quotes erd
18374 \end_inset
18375
18376  is put into an argument of an (untranslatable) command in the syntax file,
18377  then reLyX will translate that argument instead of copying it verbatim.
18378  So, for example, the default syntax file has 
18379 \family typewriter
18380
18381 \backslash
18382 raisebox{}[][]{translate}
18383 \family default
18384 .
18385  This means that the 
18386 \family typewriter
18387
18388 \backslash
18389 raisebox
18390 \family default
18391  command and the first argument (and optional arguments if they exist) are
18392  copied in TeX mode, but the last argument (which may contain math, complicated
18393  LaTeX, other untranslatable commands, etc.) will be translated into LyX.
18394  You can't use 
18395 \begin_inset Quotes eld
18396 \end_inset
18397
18398 translate
18399 \begin_inset Quotes erd
18400 \end_inset
18401
18402  on optional arguments.
18403 \end_layout
18404
18405 \begin_layout Standard
18406
18407 User-defined syntax files are allowed to define new commands and their syntax,
18408  or override the number of arguments for a command given in the default
18409  syntax file.
18410  (E.g., if you're using a style that gives an extra argument to some command...)
18411  However, this will only be useful for commands copied in TeX mode.
18412  Commands which are actually translated by reLyX (like 
18413 \family typewriter
18414
18415 \backslash
18416 item
18417 \family default
18418 ) have their argument syntax hard-coded.
18419  The hard-coded commands are identified in the default syntax file.
18420 \end_layout
18421
18422 \begin_layout Standard
18423
18424 Second, the syntax file describes any 
18425 \begin_inset Quotes eld
18426 \end_inset
18427
18428 regular environments
18429 \begin_inset Quotes erd
18430 \end_inset
18431
18432 .
18433   Usually, an entire unknown environment will be copied in TeX mode.
18434  If you define a regular environment 
18435 \begin_inset Quotes eld
18436 \end_inset
18437
18438 foo
18439 \begin_inset Quotes erd
18440 \end_inset
18441
18442 , though, then only the 
18443 \family typewriter
18444
18445 \backslash
18446 begin{foo}
18447 \family default
18448  and 
18449 \family typewriter
18450
18451 \backslash
18452 end{foo}
18453 \family default
18454  commands will be copied in TeX mode; the text within the environment will
18455  be treated (i.e., translated) by reLyX as regular LaTeX, rather than being
18456  copied into TeX mode.
18457  Don't try to declare 
18458 \family typewriter
18459 tabbing
18460 \family default
18461  and 
18462 \family typewriter
18463 picture
18464 \family default
18465  as regular environments, as the text within those environments will confuse
18466  reLyX; use this capability for new environments you create that have plain
18467  text or math or simple commands in them.
18468  You also can't declare unknown math environments (like 
18469 \family typewriter
18470 equation*
18471 \family default
18472 ) as regular environments, either, since the LyX math editor won't understand
18473  them.
18474  The names of regular environments appear, whitespace-separated, between
18475  
18476 \family typewriter
18477
18478 \backslash
18479 begin{reLyXre}
18480 \family default
18481  and 
18482 \family typewriter
18483
18484 \backslash
18485 end{reLyXre}
18486 \family default
18487  statements in the syntax file.
18488  (If you have a regular environment which you won't use very often, you
18489  can use the 
18490 \series bold
18491 -r
18492 \series default
18493  option rather than writing a syntax file.)
18494 \end_layout
18495
18496 \begin_layout Standard
18497
18498 Third, the syntax file describes a math translation table.
18499  The LyX math editor doesn't support a few commands.
18500  For example, 
18501 \family typewriter
18502 _
18503 \family default
18504  is supported, but the equivalent 
18505 \family typewriter
18506
18507 \backslash
18508 sb
18509 \family default
18510  is not.
18511  Put any commands you'd like translate between 
18512 \family typewriter
18513
18514 \backslash
18515 begin{reLyXmt}
18516 \family default
18517  and 
18518 \family typewriter
18519
18520 \backslash
18521 end{reLyXmt}
18522 \family default
18523  statements.
18524  The statement 
18525 \begin_inset Quotes eld
18526 \end_inset
18527
18528
18529 \family typewriter
18530
18531 \backslash
18532 | {
18533 \backslash
18534 Vert}
18535 \family default
18536
18537 \begin_inset Quotes erd
18538 \end_inset
18539
18540  means that any 
18541 \family typewriter
18542
18543 \backslash
18544 |
18545 \family default
18546  in math mode will be converted to 
18547 \begin_inset Quotes eld
18548 \end_inset
18549
18550
18551 \family typewriter
18552
18553 \backslash
18554 Vert
18555 \family default
18556  
18557 \begin_inset Quotes erd
18558 \end_inset
18559
18560
18561 \family typewriter
18562  
18563 \family default
18564 (in cases where a token made up of a backslash and a non-letter is translated
18565  to something with letters at the end, a space is added by reLyX.
18566  That way, 
18567 \begin_inset Quotes eld
18568 \end_inset
18569
18570
18571 \family typewriter
18572
18573 \backslash
18574 |a
18575 \family default
18576
18577 \begin_inset Quotes erd
18578 \end_inset
18579
18580  is correctly translated to 
18581 \begin_inset Quotes eld
18582 \end_inset
18583
18584
18585 \family typewriter
18586
18587 \backslash
18588 Vert a
18589 \family default
18590
18591 \begin_inset Quotes erd
18592 \end_inset
18593
18594 ).
18595 \end_layout
18596
18597 \begin_layout Subsubsection
18598
18599 Miscellaneous
18600 \end_layout
18601
18602 \begin_layout Standard
18603
18604 You need Perl version 5.002 or later to run reLyX.
18605  <plug> If you don't have Perl, you should get it anyway (at 
18606 \begin_inset LatexCommand \url[Perl]{http://www.perl.com/}
18607
18608 \end_inset
18609
18610 ), because it's a really useful tool for pretty much anything.
18611  </plug>
18612 \end_layout
18613
18614 \begin_layout Subsection
18615
18616 Diagnostics
18617 \end_layout
18618
18619 \begin_layout Standard
18620
18621 reLyX should always explain why it crashes, if it crashes.
18622  Some diagnostics may be very technical, though, if they come from the guts
18623  of the code.
18624  reLyX gives much more information while running if you use the 
18625 \series bold
18626 -d
18627 \series default
18628  option, but you shouldn't need that unless something goes wrong.
18629 \end_layout
18630
18631 \begin_layout Standard
18632
18633 When it's finished, reLyX will tell you if it finished successfully or died
18634  due to some error.
18635 \end_layout
18636
18637 \begin_layout Subsection
18638
18639 Warnings
18640 \end_layout
18641
18642 \begin_layout Standard
18643
18644 Always keep a copy of your original LaTeX files either under a different
18645  name or in a different directory.
18646  There are a couple ways in which using LyX could lead to overwriting the
18647  original LaTeX file.
18648 \end_layout
18649
18650 \begin_layout Standard
18651
18652 If you import 
18653 \family typewriter
18654 foo.tex
18655 \family default
18656  to create 
18657 \family typewriter
18658 foo.lyx
18659 \family default
18660 , then edit 
18661 \family typewriter
18662 foo.lyx
18663 \family default
18664  and want to re-export it, note that it will overwrite the original 
18665 \family typewriter
18666 foo.tex
18667 \family default
18668 .
18669  (LyX will 
18670 \emph on
18671 not
18672 \emph default
18673  ask you if you want to overwrite it.)
18674 \end_layout
18675
18676 \begin_layout Standard
18677
18678 If you have chosen not to use a temporary directory in the preferences,
18679  then LyX will create its temporary files in your current directory, which
18680  means your LaTeX original may be overwritten (without a warning from LyX)
18681  when you 
18682 \begin_inset Quotes eld
18683 \end_inset
18684
18685 view dvi
18686 \begin_inset Quotes erd
18687 \end_inset
18688
18689  or print the LyX document.
18690 \end_layout
18691
18692 \begin_layout Subsection
18693
18694 Files
18695 \end_layout
18696
18697 \begin_layout Description
18698
18699
18700 \family typewriter
18701 \series medium
18702 MY_LYXDIR/layouts/*.layout
18703 \family default
18704 \series default
18705  \InsetSpace ~
18706
18707 \newline
18708 User's personal layout files for document classes
18709 \end_layout
18710
18711 \begin_layout Description
18712
18713
18714 \family typewriter
18715 \series medium
18716 MY_LYXDIR/reLyX/syntax.default
18717 \family default
18718 \series default
18719  \InsetSpace ~
18720
18721 \newline
18722 User's personal syntax file
18723 \end_layout
18724
18725 \begin_layout Description
18726
18727
18728 \family typewriter
18729 \series medium
18730 LIBDIR/layouts/*.layout
18731 \family default
18732 \series default
18733  \InsetSpace ~
18734
18735 \newline
18736 System-wide layout files for document classes
18737 \end_layout
18738
18739 \begin_layout Description
18740
18741
18742 \family typewriter
18743 \series medium
18744 LIBDIR/reLyX/syntax.default
18745 \family default
18746 \series default
18747  \InsetSpace ~
18748
18749 \newline
18750 System-wide LaTeX syntax file
18751 \end_layout
18752
18753 \begin_layout Standard
18754
18755
18756 \family typewriter
18757 LIBDIR
18758 \family default
18759  is the system-wide LyX directory, usually something like 
18760 \family typewriter
18761 /usr/local/share/lyx/
18762 \family default
18763 .
18764  
18765 \family typewriter
18766 MY_LYXDIR
18767 \family default
18768  is your personal LyX directory, something like 
18769 \family typewriter
18770 .lyx/
18771 \family default
18772  in your home directory.
18773  You can see their actual values in the 
18774 \family sans
18775 \bar under
18776 H
18777 \bar default
18778 elp\SpecialChar \menuseparator
18779 About\InsetSpace ~
18780 Ly
18781 \bar under
18782 X
18783 \family default
18784 \bar default
18785  dialog.
18786 \end_layout
18787
18788 \begin_layout Subsection
18789
18790 See also
18791 \end_layout
18792
18793 \begin_layout Standard
18794
18795
18796 \shape italic
18797 lyx
18798 \shape default
18799 (1), 
18800 \shape italic
18801 latex
18802 \shape default
18803 (1)
18804 \end_layout
18805
18806 \begin_layout Subsection
18807
18808 Authors
18809 \end_layout
18810
18811 \begin_layout Standard
18812
18813 Copyright (c) 1998--9 
18814 \noun on
18815 Amir Karger
18816 \noun default
18817  (
18818 \family typewriter
18819 karger@voth.chem.utah.edu
18820 \family default
18821 )
18822 \end_layout
18823
18824 \begin_layout Standard
18825
18826 Code contributors:
18827 \end_layout
18828
18829 \begin_layout Itemize
18830
18831
18832 \noun on
18833 John Weiss
18834 \noun default
18835  wrote the original CleanTeX pass.
18836 \end_layout
18837
18838 \begin_layout Itemize
18839
18840
18841 \noun on
18842 Etienne Grossmann
18843 \end_layout
18844
18845 \begin_layout Itemize
18846
18847
18848 \noun on
18849 Jos\i \'{e}
18850  Ab\i \'{\i}
18851 lio Oliveira Matos
18852 \end_layout
18853
18854 \begin_layout Itemize
18855
18856
18857 \noun on
18858 David Suarez de Lis
18859 \end_layout
18860
18861 \begin_layout Standard
18862
18863 Other contributors:
18864 \end_layout
18865
18866 \begin_layout Itemize
18867
18868
18869 \noun on
18870 Jean-Marc Lasgouttes
18871 \noun default
18872  worked on the wrapper script and offered lots of bug reports, advice, and
18873  feature suggestions.
18874 \end_layout
18875
18876 \begin_layout Itemize
18877
18878
18879 \noun on
18880 Asger K.
18881  Alstrup Nielsen
18882 \noun default
18883  and 
18884 \noun on
18885 Marc Pavese
18886 \noun default
18887  provided advice.
18888 \end_layout
18889
18890 \begin_layout Itemize
18891
18892 Various members of the LyX developers' and users' lists provided bug reports
18893  and feature suggestions.
18894 \end_layout
18895
18896 \begin_layout Standard
18897
18898 reLyX uses a modified version the Perl TeX parser 
18899 \family typewriter
18900 Text::TeX
18901 \family default
18902  package written by 
18903 \noun on
18904 Ilya Zakharevich
18905 \noun default
18906  (
18907 \family typewriter
18908 ilya@math.ohio-state.edu
18909 \family default
18910 ), available on CPAN.
18911 \end_layout
18912
18913 \begin_layout Chapter
18914
18915 LyX Features needing Extra Software
18916 \end_layout
18917
18918 \begin_layout Section
18919
18920 Using LyX with SGML-Tools (aka LinuxDoc)
18921 \end_layout
18922
18923 \begin_layout Standard
18924
18925 by 
18926 \noun on
18927 Paul Evans
18928 \end_layout
18929
18930 \begin_layout Subsection
18931
18932 Overview
18933 \end_layout
18934
18935 \begin_layout Standard
18936
18937 LinuxDoc is a document class available in LyX if you have the 
18938 \family typewriter
18939 sgml-tools
18940 \family default
18941  package installed.
18942  You can use it to produce documents in the so-called Standardized General
18943  Mark-up Language (SGML) in the particular format used by the Linux Documentatio
18944 n Project.
18945  That is obviously helpful if you are contributing to that project.
18946  You can use the SGML format with the 
18947 \family typewriter
18948 sgml-tools
18949 \family default
18950  package of scripts and programs (to produce other formats, including Latex,
18951  HTML, plain text, man pages and\SpecialChar \ldots{}
18952 ).
18953  You may therefore prefer to use this document class if you want to write
18954  something that can be easily translated into other formats.
18955 \end_layout
18956
18957 \begin_layout Standard
18958
18959 You will find that LinuxDoc has fewer layout options than the other text
18960  classes in LyX.
18961  This is mainly so that the translations into other formats have a chance
18962  of making some sense.
18963  In this section we describe:
18964 \end_layout
18965
18966 \begin_layout Itemize
18967
18968 how to setup and use a document in LinuxDoc
18969 \end_layout
18970
18971 \begin_layout Itemize
18972
18973 how to use the tags in LinuxDoc to layout your document
18974 \end_layout
18975
18976 \begin_layout Itemize
18977
18978 how to use the SGML packages to produce the various formats
18979 \end_layout
18980
18981 \begin_layout Itemize
18982
18983 how to sort out some problems.
18984 \end_layout
18985
18986 \begin_layout Subsection
18987
18988 Preparing and using a LinuxDoc document
18989 \end_layout
18990
18991 \begin_layout Subsubsection
18992
18993 Getting started
18994 \end_layout
18995
18996 \begin_layout Standard
18997
18998 You start by selecting the LinuxDoc class using the 
18999 \family sans
19000 \bar under
19001 D
19002 \bar default
19003 ocument\SpecialChar \menuseparator
19004
19005 \bar under
19006 S
19007 \bar default
19008 ettings
19009 \family default
19010  dialog.
19011
19012 \family sans
19013  
19014 \family default
19015 Then you will find that there are fewer paragraph environments than for
19016  most other classes.
19017  You can see them on the pull down box on the left of the tool bar.
19018  How to use them is described in section\InsetSpace ~
19019
19020 \begin_inset LatexCommand \ref{sec:sgmlparas}
19021
19022 \end_inset
19023
19024 .
19025 \end_layout
19026
19027 \begin_layout Standard
19028
19029 You 
19030 \emph on
19031 must
19032 \emph default
19033  enter a title for the document, followed by an author, marking each with
19034  the appropriate paragraph environment.
19035  If you don't do this, you will get errors when you try to print the file.
19036  You can then enter the date and an abstract.
19037  The document proper must start with a Section paragraph environment rather
19038  than any standard layout.
19039 \end_layout
19040
19041 \begin_layout Standard
19042
19043 After that you can prepare a document as usual using the available range
19044  of paragraph environments.
19045  See section\InsetSpace ~
19046
19047 \begin_inset LatexCommand \ref{sec:sgmlparas}
19048
19049 \end_inset
19050
19051  for the full list and their uses.
19052 \end_layout
19053
19054 \begin_layout Subsubsection
19055
19056 Output from LinuxDoc
19057 \end_layout
19058
19059 \begin_layout Standard
19060
19061 You can print and save these documents in the normal way.
19062  To use the other features of the SGML package you need to save your document
19063  as LinuxDoc; this is a version in which the document is translated into
19064  the basic sgml tags.
19065  Use
19066 \family sans
19067  
19068 \bar under
19069 F
19070 \bar default
19071 ile\SpecialChar \menuseparator
19072
19073 \bar under
19074 E
19075 \bar default
19076 xport\SpecialChar \menuseparator
19077 Linu
19078 \bar under
19079 x
19080 \bar default
19081 Doc.
19082
19083 \family default
19084  You will get a file with the same name and a 
19085 \family typewriter
19086 .sgml
19087 \family default
19088  extension rather than a 
19089 \family typewriter
19090 .lyx
19091 \family default
19092  extension.
19093  See\InsetSpace ~
19094
19095 \begin_inset LatexCommand \ref{sec:sgmloperate}
19096
19097 \end_inset
19098
19099  on how you than make use of this file.
19100 \end_layout
19101
19102 \begin_layout Subsection
19103
19104 Using the paragraph environments in LinuxDoc
19105 \end_layout
19106
19107 \begin_layout Subsubsection
19108
19109 The Structure of a LinuxDoc Document
19110 \end_layout
19111
19112 \begin_layout Standard
19113
19114 There is a formal structure for LinuxDoc which limits how you can place
19115  tags.
19116  There are two parts to all documents: 
19117 \end_layout
19118
19119 \begin_layout Description
19120
19121 Header: this is everything up to the first time you insert a Section layout
19122  marker.
19123  It can include title, author, date, abstract and ToC.
19124  You must include the first two.
19125 \end_layout
19126
19127 \begin_layout Description
19128
19129 Body: from the beginning of the first section onwards.
19130  All other tags are allowed.
19131  
19132 \end_layout
19133
19134 \begin_layout Subsubsection
19135
19136 The LinuxDoc Paragraph Environments
19137 \end_layout
19138
19139 \begin_layout Standard
19140
19141
19142 \begin_inset LatexCommand \label{sec:sgmlparas}
19143
19144 \end_inset
19145
19146 Here is a list of all the tags you will find listed on the layout bar in
19147  the order they come there, with some comments where the purpose or use
19148  is not obvious:
19149 \end_layout
19150
19151 \begin_layout Itemize
19152
19153
19154 \family sans
19155 Standard:
19156 \family roman
19157  works as described in [cross reference]
19158 \end_layout
19159
19160 \begin_layout Itemize
19161
19162
19163 \family sans
19164 Title
19165 \family default
19166 : This will appear at the top left of the document when printed, above a
19167  heavy horizontal rule, although you will not see this on the LyX screen.
19168 \end_layout
19169
19170 \begin_layout Itemize
19171
19172
19173 \family sans
19174 Section, Subsection, Subsubsection, Paragraph and Subparagraph:
19175 \family default
19176  all do what you would expect and in the usual order.
19177  Whether they are numbered or not is controlled by the 
19178 \family sans
19179 Section\InsetSpace ~
19180 number\InsetSpace ~
19181 depth
19182 \family default
19183  setting.
19184  You cannot get the equivalent number free versions in any other way; there
19185  is no 
19186 \family sans
19187 Section*
19188 \family default
19189  or similar
19190 \end_layout
19191
19192 \begin_layout Itemize
19193
19194
19195 \family sans
19196 Enumerate:
19197 \family default
19198  As usual this produces a numbered and indented list as described in the
19199  
19200 \emph on
19201 User's Guide
19202 \emph default
19203 .
19204 \end_layout
19205
19206 \begin_layout Itemize
19207
19208
19209 \family sans
19210 Itemize: 
19211 \family roman
19212 Again much the same as in the other classes: see the 
19213 \emph on
19214 User's Guide
19215 \emph default
19216 .
19217 \end_layout
19218
19219 \begin_layout Itemize
19220
19221
19222 \family sans
19223 Description
19224 \family default
19225 : As explained in the 
19226 \emph on
19227 User's Guide
19228 \emph default
19229 .
19230  Remember that if you want the bold element at the start of a description
19231  to be more than one word then you need to put protected spaces between
19232  the words.
19233  
19234 \end_layout
19235
19236 \begin_layout Itemize
19237
19238
19239 \family sans
19240 Verbatim: 
19241 \family default
19242 As usual.
19243 \end_layout
19244
19245 \begin_layout Itemize
19246
19247
19248 \family sans
19249 Code: similar to the Lyx-Code
19250 \family roman
19251  environment
19252 \end_layout
19253
19254 \begin_layout Itemize
19255
19256
19257 \family sans
19258 Author
19259 \family default
19260 : Anything you mark with this will appear on the left of the heading of
19261  the document, under the heavy rule.
19262 \end_layout
19263
19264 \begin_layout Itemize
19265
19266
19267 \family sans
19268 Date:
19269 \family default
19270  Anything you mark with this will appear on the right of the heading under
19271  the rule.
19272  You do not have to make this a date.
19273  Any text can be entered, e.\InsetSpace ~
19274 g.
19275  a version number.
19276 \end_layout
19277
19278 \begin_layout Itemize
19279
19280
19281 \family sans
19282 Abstract
19283 \family default
19284 : You can use this to produce a free standing paragraph after the author
19285  and date, and before the first section.
19286  You are only allowed one such paragraph.
19287 \begin_inset Foot
19288 status collapsed
19289
19290 \begin_layout Standard
19291
19292
19293 \emph on
19294 Author's note.
19295  
19296 \emph default
19297 This needs checking ---
19298 \emph on
19299 pe.
19300 \end_layout
19301
19302 \end_inset
19303
19304
19305 \end_layout
19306
19307 \begin_layout Itemize
19308
19309
19310 \family sans
19311 Displaymath
19312 \family default
19313 :
19314 \begin_inset Foot
19315 status collapsed
19316
19317 \begin_layout Standard
19318
19319
19320 \emph on
19321 Author's note: 
19322 \emph default
19323 I have not yet checked this ---
19324 \emph on
19325 pe.
19326 \end_layout
19327
19328 \end_inset
19329
19330
19331 \end_layout
19332
19333 \begin_layout Subsubsection
19334
19335 Other document features
19336 \end_layout
19337
19338 \begin_layout Standard
19339
19340 You can also use the 
19341 \family sans
19342 Layout 
19343 \family default
19344 menu to set fonts or to emphasis words.
19345  You can also use the table of contents as usual; see the corresponding
19346  section of the 
19347 \emph on
19348 User's Guide
19349 \emph default
19350 .
19351  Although you will find some some other features on the menus e.\InsetSpace ~
19352 g.
19353  inserting footnotes.
19354  There is some doubt about whether these will work correctly.
19355 \begin_inset Foot
19356 status collapsed
19357
19358 \begin_layout Standard
19359
19360
19361 \emph on
19362 Author's note: 
19363 \emph default
19364 Again still checking to see whether this is my system
19365 \emph on
19366  ---pe.
19367 \end_layout
19368
19369 \end_inset
19370
19371
19372 \end_layout
19373
19374 \begin_layout Subsubsection
19375
19376 Cross references and HTML 
19377 \end_layout
19378
19379 \begin_layout Standard
19380
19381 On the
19382 \family sans
19383  Insert
19384 \family default
19385  menu you will find two new options relating to the inclusion of URL addresses.
19386  If you use either option you will find some highlighted TeX code inserted
19387  into your document in three separate blocks with spaces available between.
19388  The blocks will be:
19389 \end_layout
19390
19391 \begin_layout Quote
19392
19393
19394 \family typewriter
19395
19396 \backslash
19397 htmlurl{
19398 \family default
19399  or 
19400 \family typewriter
19401
19402 \backslash
19403 url{
19404 \family roman
19405
19406 \hfill
19407 space
19408 \family default
19409  
19410 \family typewriter
19411
19412 \hfill
19413 }{
19414 \family roman
19415
19416 \hfill
19417 space
19418 \hfill
19419
19420 \family typewriter
19421 }
19422 \end_layout
19423
19424 \begin_layout Standard
19425
19426 You insert a full HTML tag between the first and second blocks.
19427  This can be 
19428 \begin_inset LatexCommand \url{http://any.address}
19429
19430 \end_inset
19431
19432  or other valid tags such as 
19433 \begin_inset LatexCommand \url{mailto:me@my.address}
19434
19435 \end_inset
19436
19437
19438 \family typewriter
19439 .
19440 \family default
19441 Then y
19442 \family roman
19443 ou 
19444 \family default
19445 insert some description between the second and third blocks.
19446  The differences are:
19447 \end_layout
19448
19449 \begin_layout Itemize
19450
19451
19452 \family sans
19453 URL:
19454 \family roman
19455  both the HTML tag and the description will appear in the document
19456 \end_layout
19457
19458 \begin_layout Itemize
19459
19460
19461 \family sans
19462 HTML\InsetSpace ~
19463 URL: 
19464 \family roman
19465 only the description appears in the printed version
19466 \end_layout
19467
19468 \begin_layout Subsection
19469
19470 Using the LinuxDoc Sgml scripts
19471 \begin_inset Note Note
19472 status collapsed
19473
19474 \begin_layout Standard
19475
19476 This section is completely outdated.
19477 \end_layout
19478
19479 \end_inset
19480
19481
19482 \end_layout
19483
19484 \begin_layout Standard
19485
19486
19487 \begin_inset LatexCommand \label{sec:sgmloperate}
19488
19489 \end_inset
19490
19491 You can use LinuxDoc as a text class without any additional scripts or programs,
19492  but there is not much point in doing this.
19493  All you will get is a document that looks like a 
19494 \emph on
19495 Linux Documentation Project Howto
19496 \family sans
19497 \emph default
19498 .
19499  
19500 \family default
19501 To do the document translation you need to get and install the 
19502 \family typewriter
19503 sgml-tools-1.0.x.tar.gz 
19504 \family default
19505 (with 
19506 \begin_inset Formula $x\geq3$
19507 \end_inset
19508
19509 ) package from 
19510 \family roman
19511 the SGML-Tools WWW Page
19512 \family default
19513  at
19514 \end_layout
19515
19516 \begin_layout LyX-Code
19517
19518
19519 \family roman
19520
19521 \begin_inset LatexCommand \url{http://pobox.com/~cg/sgmltools}
19522
19523 \end_inset
19524
19525
19526 \family default
19527  
19528 \end_layout
19529
19530 \begin_layout Standard
19531
19532 Alternatively, you can go to the 
19533 \family typewriter
19534 sunsite
19535 \family default
19536  archive at
19537 \begin_inset Foot
19538 status collapsed
19539
19540 \begin_layout Standard
19541
19542 Note that, at the time of this writing (01/1998), version 1.0.3 of sgml-tools
19543  has not yet been made available at 
19544 \family typewriter
19545 sunsite
19546 \family default
19547 .
19548 \end_layout
19549
19550 \end_inset
19551
19552
19553 \end_layout
19554
19555 \begin_layout LyX-Code
19556
19557
19558 \family roman
19559
19560 \begin_inset LatexCommand \url{ftp://sunsite.unc.edu/pub/Linux/utils/text/sgml-tools-1.0.x.tar.gz}
19561
19562 \end_inset
19563
19564
19565 \end_layout
19566
19567 \begin_layout Standard
19568
19569
19570 \family roman
19571 The
19572 \family default
19573  file 
19574 \family typewriter
19575 sgml-tools-1.0.x.tar.gz
19576 \family default
19577  contains everything that you need to write SGML documents and convert them
19578  to groff, LaTeX, HTML, GNU info, LyX, and RTF\SpecialChar \@.
19579
19580 \end_layout
19581
19582 \begin_layout Standard
19583
19584 This package was renamed from 
19585 \family typewriter
19586 linuxdoc-sgml-1.5.tar.gz
19587 \family default
19588  in January 1997.
19589 \end_layout
19590
19591 \begin_layout Standard
19592
19593 Follow the instructions in that package on how to install it and how to
19594  use it.
19595  All this has to be done outside of LyX, before you can use the 
19596 \family sans
19597 \bar under
19598 F
19599 \bar default
19600 ile\SpecialChar \menuseparator
19601
19602 \bar under
19603 E
19604 \bar default
19605 xport\SpecialChar \menuseparator
19606 as\InsetSpace ~
19607 LinuxDoc 
19608 \family roman
19609 option.
19610 \end_layout
19611
19612 \begin_layout Subsection
19613
19614 Troubleshooting LinuxDoc
19615 \end_layout
19616
19617 \begin_layout Standard
19618
19619 When you print or preview a LinuxDoc document some checking is done of the
19620  tags before LaTeX is run.
19621  Some errors are trapped here, especially those concerning the structure
19622  of the document.
19623  LyX may produce an error message, but not leave an error box in the document
19624  for you to open.
19625  You may have to look at the files directly to discover what is wrong.
19626  Most problems seem to come from the use of options that are not fully available
19627  in the text class.
19628 \end_layout
19629
19630 \begin_layout Section
19631
19632 Checking TeX
19633 \end_layout
19634
19635 \begin_layout Standard
19636
19637 by 
19638 \noun on
19639 Asger Alstrup
19640 \end_layout
19641
19642 \begin_layout Subsection
19643
19644 Introduction
19645 \end_layout
19646
19647 \begin_layout Standard
19648
19649 Under the 
19650 \family sans
19651 \bar under
19652 T
19653 \bar default
19654 ools
19655 \family default
19656  menu, you'll find a 
19657 \family sans
19658 \bar under
19659 C
19660 \bar default
19661 heck\InsetSpace ~
19662 TeX
19663 \family default
19664  command.
19665  This feature requires you to have the 
19666 \family typewriter
19667 chktex
19668 \family default
19669  program installed, and is grayed out if you don't have it.
19670  You can get it from your nearest CTAN mirror, or over the Web from 
19671 \begin_inset LatexCommand \url{http://www.ifi.uio.no/~jensthi/chktex/}
19672
19673 \end_inset
19674
19675 .
19676 \end_layout
19677
19678 \begin_layout Standard
19679
19680 The 
19681 \family sans
19682 ChkTeX
19683 \family default
19684  package is a program that was written by 
19685 \noun on
19686 Jens T.
19687  Berger Thielemann
19688 \noun default
19689  in frustration because some constructs in LaTeX are sometimes non-intuitive,
19690  and easy to forget.
19691  The program runs over your LaTeX file and checks the integrity of the file,
19692  and flags some common errors.
19693  In other technical words, it is 
19694 \family typewriter
19695 Lint
19696 \family default
19697  for LaTeX.
19698 \end_layout
19699
19700 \begin_layout Standard
19701
19702 Well, what is a syntax checker doing in LyX which is supposed to produce
19703  correct LaTeX anyways? The answer is simple: Just as 
19704 \family typewriter
19705 Lint
19706 \family default
19707  not only checks the 
19708 \emph on
19709 syntax
19710 \emph default
19711  of C programs, but also does 
19712 \emph on
19713 semantic
19714 \emph default
19715  checks for type-errors, 
19716 \family sans
19717 ChkTeX
19718 \family default
19719  catches some common 
19720 \emph on
19721 typographic
19722 \emph default
19723  errors, in addition to the syntactical ones.
19724  Specifically, 
19725 \family sans
19726 ChkTeX
19727 \family default
19728  is capable of detecting several common errors, such as
19729 \end_layout
19730
19731 \begin_layout Itemize
19732
19733 Ellipsis detection:
19734 \newline
19735 Use \SpecialChar \ldots{}
19736  instead of ...
19737 \end_layout
19738
19739 \begin_layout Itemize
19740
19741 No space in front of/after parenthesis:
19742 \newline
19743 ( wrong spacing )
19744 \end_layout
19745
19746 \begin_layout Itemize
19747
19748 Enforcement of normal space after common abbreviations:
19749 \newline
19750 e.
19751  g.
19752  is too wide spacing.
19753 \end_layout
19754
19755 \begin_layout Itemize
19756
19757 Enforcement of end-of-sentence space when the last sentence ends with a
19758  capital letter:
19759 \newline
19760 This is a TEST.
19761  And this is wrong spacing.
19762 \end_layout
19763
19764 \begin_layout Itemize
19765
19766 Space in front of labels and similar commands:
19767 \newline
19768 The label should stick right up to the text to avoid falling to a wrong
19769  page.
19770  
19771 \begin_inset LatexCommand \label{sec:chktex}
19772
19773 \end_inset
19774
19775  
19776 \begin_inset Foot
19777 status collapsed
19778
19779 \begin_layout Standard
19780
19781 This footnote is in danger of falling off to a wrong page
19782 \end_layout
19783
19784 \end_inset
19785
19786  The label is separated too much.
19787 \end_layout
19788
19789 \begin_layout Itemize
19790
19791 Space in front of references, instead of hard spaces:
19792 \newline
19793 In you are in bad luck, the text will break right between the referenced
19794  text and reference number, and that's a pity.
19795  See section 
19796 \begin_inset LatexCommand \ref{sec:chktex}
19797
19798 \end_inset
19799
19800 .
19801 \end_layout
19802
19803 \begin_layout Itemize
19804
19805 Use of 
19806 \begin_inset Quotes eld
19807 \end_inset
19808
19809 x
19810 \begin_inset Quotes erd
19811 \end_inset
19812
19813  instead of 
19814 \begin_inset Formula $\times$
19815 \end_inset
19816
19817  between numbers:
19818 \newline
19819 2x2 looks cheap compared to 
19820 \begin_inset Formula $2\times2$
19821 \end_inset
19822
19823 .
19824 \end_layout
19825
19826 \begin_layout Standard
19827
19828 and more \SpecialChar \ldots{}
19829  It is an invaluable tool when you are 
19830 \begin_inset Quotes eld
19831 \end_inset
19832
19833 finishing up
19834 \begin_inset Quotes erd
19835 \end_inset
19836
19837  your document before printing, and you should run it right after the obligatory
19838  spelling check, and before you go fine tuning the typesetting.
19839 \end_layout
19840
19841 \begin_layout Subsection
19842
19843 How to use it
19844 \end_layout
19845
19846 \begin_layout Standard
19847
19848 If you have the program installed, usage is as simple as choosing 
19849 \family sans
19850 \bar under
19851 T
19852 \bar default
19853 ools\SpecialChar \menuseparator
19854
19855 \bar under
19856 C
19857 \bar default
19858 heck\InsetSpace ~
19859 TeX
19860 \family default
19861 .
19862  This will make LyX generate a LaTeX file of your document, start 
19863 \family sans
19864 ChkTeX
19865 \family default
19866  to check it, and then make LyX insert 
19867 \begin_inset Quotes eld
19868 \end_inset
19869
19870 error boxes
19871 \begin_inset Quotes erd
19872 \end_inset
19873
19874  with the warnings from 
19875 \family sans
19876 ChkTeX
19877 \family default
19878 , if there were any.
19879  The warnings will be placed close to the point of the mistake, and you
19880  can quickly find them by using the 
19881 \family sans
19882 \bar under
19883 N
19884 \bar default
19885 avigate\SpecialChar \menuseparator
19886
19887 \bar under
19888 E
19889 \bar default
19890 rror
19891 \family default
19892  menu item, or the shortcut key 
19893 \family sans
19894 C-g
19895 \family default
19896  from the default 
19897 \family typewriter
19898 cua
19899 \family default
19900  bind file.
19901  Open the error boxes by clicking on them with the mouse, or use the shortcut
19902  key 
19903 \family sans
19904 C-i
19905 \family default
19906  from 
19907 \family typewriter
19908 cua
19909 \family default
19910  bindings, or the corresponding 
19911 \family sans
19912 C-o
19913 \family default
19914  for the alternate 
19915 \family typewriter
19916 emacs
19917 \family default
19918  bind file.
19919  Read the warning and correct the mistake, if it is a mistake.
19920  If you have trouble understanding what the warning is about, you can safely
19921  ignore it.
19922  Remember that there is a hidden layer between the document on screen and
19923  the technical details in invoking 
19924 \family sans
19925 ChkTeX
19926 \family default
19927 , and this gap can make some warnings seem arcane or just right down plain
19928  silly.
19929 \end_layout
19930
19931 \begin_layout Standard
19932
19933 This document is an excellent testing bed for the feature, and it should
19934  provide quite a few warnings for you to fiddle with.
19935  Since computers are only so smart, expect most of the warnings to be false
19936  alarms, though.
19937 \end_layout
19938
19939 \begin_layout Subsection
19940
19941 How to fine tune it
19942 \end_layout
19943
19944 \begin_layout Standard
19945
19946 Sometimes, you'll find that 
19947 \family sans
19948 ChkTeX
19949 \family default
19950  makes more noise than suits your mood.
19951  Then you can choose not to use it, wait until your mood changes, or try
19952  to customize 
19953 \family sans
19954 ChkTeX
19955 \family default
19956  to get better along with you.
19957  Another choice in the most desperate situations is to use 
19958 \family sans
19959 \bar under
19960 V
19961 \bar default
19962 iew\SpecialChar \menuseparator
19963
19964 \bar under
19965 R
19966 \bar default
19967 emove\InsetSpace ~
19968 All\InsetSpace ~
19969 Error\InsetSpace ~
19970 Boxes
19971 \family default
19972 , which will get rid of all warnings instantly.
19973 \end_layout
19974
19975 \begin_layout Standard
19976
19977 Although 
19978 \family sans
19979 ChkTeX
19980 \family default
19981  
19982 \emph on
19983 is
19984 \emph default
19985  very configurable and extensible, you shouldn't expect to solve all problems
19986  with 
19987 \family sans
19988 ChkTeX
19989 \family default
19990  in LyX this way.
19991  Since LyX has to generate a somewhat special LaTeX file to be able to match
19992  the line numbers from the 
19993 \family sans
19994 ChkTeX
19995 \family default
19996  output
19997 \begin_inset Foot
19998 status collapsed
19999
20000 \begin_layout Standard
20001
20002 You can inspect the specific output from 
20003 \family sans
20004 chktex
20005 \family default
20006  by using 
20007 \family sans
20008 Edit\SpecialChar \menuseparator
20009 View\InsetSpace ~
20010 LaTeX\InsetSpace ~
20011 Log
20012 \family default
20013  right after a 
20014 \family sans
20015 chktex
20016 \family default
20017  run.
20018 \end_layout
20019
20020 \end_inset
20021
20022  to the internal document structure, some of the warnings will not seen
20023  to appear correctly.
20024  There are two things you can do about this:
20025 \end_layout
20026
20027 \begin_layout Itemize
20028
20029 Fine tune the 
20030 \family sans
20031 ChkTeX
20032 \family default
20033  invocation command line in 
20034 \family sans
20035 Preferences
20036 \family default
20037  (tabs 
20038 \family sans
20039 Outputs
20040 \family default
20041
20042 \family sans
20043 Misc
20044 \family default
20045 ), or the global 
20046 \family sans
20047 ChkTeX
20048 \family default
20049  installation configuration file (usually with the file 
20050 \family typewriter
20051 /usr/local/share/chktexrc
20052 \family default
20053 ).
20054  See below to learn what warnings can be enabled and disabled on the command
20055  line.
20056  
20057 \end_layout
20058
20059 \begin_layout Itemize
20060
20061 Export your document as a raw LaTeX file using 
20062 \family sans
20063 \bar under
20064 F
20065 \bar default
20066 ile\SpecialChar \menuseparator
20067
20068 \bar under
20069 E
20070 \bar default
20071 xport\SpecialChar \menuseparator
20072
20073 \bar under
20074 L
20075 \bar default
20076 aTeX
20077 \family default
20078  and run 
20079 \family typewriter
20080 chktex
20081 \family default
20082  manually on that.
20083  Invoked in this way, it can be a hassle to find the corresponding place
20084  in the document inside LyX, but with a little patience, you should be able
20085  to do it.
20086 \end_layout
20087
20088 \begin_layout Standard
20089
20090 Here follows the warning messages that can be enabled and disabled in 
20091 \family sans
20092 Preferences
20093 \family default
20094 .
20095  Use 
20096 \family typewriter
20097 -n#
20098 \family default
20099  to disable a warning, and 
20100 \family typewriter
20101 -w#
20102 \family default
20103  to enable a warning.
20104  The emphasized entries are disabled by default, because the default is
20105  "
20106 \family typewriter
20107 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
20108 \family default
20109 ".
20110 \end_layout
20111
20112 \begin_layout Standard
20113
20114 Notice that you should only use the options that enable and disable warnings,
20115  because LyX relies on some of the other command line parameters to be set
20116  in a specific way to have a chance to communicate with 
20117 \family typewriter
20118 chktex
20119 \family default
20120 .
20121 \end_layout
20122
20123 \begin_layout Enumerate
20124
20125
20126 \size small
20127 \emph on
20128 Command terminated with space.
20129 \end_layout
20130
20131 \begin_layout Enumerate
20132
20133
20134 \size small
20135 Non-breaking space (
20136 \begin_inset Quotes eld
20137 \end_inset
20138
20139
20140 \family typewriter
20141 ~
20142 \family default
20143
20144 \begin_inset Quotes erd
20145 \end_inset
20146
20147 ) should have been used.
20148 \end_layout
20149
20150 \begin_layout Enumerate
20151
20152
20153 \size small
20154 \emph on
20155 You should enclose the previous parenthesis with 
20156 \begin_inset Quotes eld
20157 \end_inset
20158
20159
20160 \family typewriter
20161 {}
20162 \family default
20163
20164 \begin_inset Quotes erd
20165 \end_inset
20166
20167 .
20168 \end_layout
20169
20170 \begin_layout Enumerate
20171
20172
20173 \size small
20174 Italic correction (
20175 \begin_inset Quotes eld
20176 \end_inset
20177
20178
20179 \family typewriter
20180
20181 \backslash
20182 /
20183 \family default
20184
20185 \begin_inset Quotes erd
20186 \end_inset
20187
20188 ) found in non-italic buffer.
20189 \end_layout
20190
20191 \begin_layout Enumerate
20192
20193
20194 \size small
20195 Italic correction (
20196 \begin_inset Quotes eld
20197 \end_inset
20198
20199
20200 \family typewriter
20201
20202 \backslash
20203 /
20204 \family default
20205
20206 \begin_inset Quotes erd
20207 \end_inset
20208
20209 ) found more than once.
20210 \end_layout
20211
20212 \begin_layout Enumerate
20213
20214
20215 \size small
20216 \emph on
20217 No italic correction (
20218 \begin_inset Quotes eld
20219 \end_inset
20220
20221
20222 \family typewriter
20223
20224 \backslash
20225 /
20226 \family default
20227
20228 \begin_inset Quotes erd
20229 \end_inset
20230
20231 ) found.
20232 \end_layout
20233
20234 \begin_layout Enumerate
20235
20236
20237 \size small
20238 Accent command 
20239 \begin_inset Quotes eld
20240 \end_inset
20241
20242
20243 \family typewriter
20244 cmd
20245 \family default
20246
20247 \begin_inset Quotes erd
20248 \end_inset
20249
20250  needs use of 
20251 \begin_inset Quotes eld
20252 \end_inset
20253
20254
20255 \family typewriter
20256 cmd
20257 \family default
20258
20259 \begin_inset Quotes erd
20260 \end_inset
20261
20262 .
20263 \end_layout
20264
20265 \begin_layout Enumerate
20266
20267
20268 \size small
20269 Wrong length of dash may have been used.
20270 \end_layout
20271
20272 \begin_layout Enumerate
20273
20274
20275 \size small
20276 \emph on
20277
20278 \begin_inset Quotes eld
20279 \end_inset
20280
20281
20282 \family typewriter
20283 %s
20284 \family default
20285
20286 \begin_inset Quotes erd
20287 \end_inset
20288
20289  expected, found 
20290 \begin_inset Quotes eld
20291 \end_inset
20292
20293
20294 \family typewriter
20295 %s
20296 \family default
20297
20298 \begin_inset Quotes erd
20299 \end_inset
20300
20301 .
20302 \end_layout
20303
20304 \begin_layout Enumerate
20305
20306
20307 \size small
20308 Solo 
20309 \begin_inset Quotes eld
20310 \end_inset
20311
20312
20313 \family typewriter
20314 %s
20315 \family default
20316
20317 \begin_inset Quotes erd
20318 \end_inset
20319
20320  found.
20321 \end_layout
20322
20323 \begin_layout Enumerate
20324
20325
20326 \size small
20327 You should use 
20328 \begin_inset Quotes eld
20329 \end_inset
20330
20331
20332 \family typewriter
20333 %s
20334 \family default
20335
20336 \begin_inset Quotes erd
20337 \end_inset
20338
20339  to achieve an ellipsis.
20340 \end_layout
20341
20342 \begin_layout Enumerate
20343
20344
20345 \size small
20346 Inter-word spacing (
20347 \begin_inset Quotes eld
20348 \end_inset
20349
20350
20351 \family typewriter
20352
20353 \backslash
20354  
20355 \family default
20356
20357 \begin_inset Quotes eld
20358 \end_inset
20359
20360 ) should perhaps be used.
20361 \end_layout
20362
20363 \begin_layout Enumerate
20364
20365
20366 \size small
20367 Inter-sentence spacing (
20368 \begin_inset Quotes eld
20369 \end_inset
20370
20371
20372 \family typewriter
20373
20374 \backslash
20375 @
20376 \family default
20377
20378 \begin_inset Quotes erd
20379 \end_inset
20380
20381 ) should perhaps be used.
20382 \end_layout
20383
20384 \begin_layout Enumerate
20385
20386
20387 \size small
20388 Could not find argument for command.
20389 \end_layout
20390
20391 \begin_layout Enumerate
20392
20393
20394 \size small
20395 No match found for 
20396 \begin_inset Quotes eld
20397 \end_inset
20398
20399
20400 \family typewriter
20401 %s
20402 \family default
20403
20404 \begin_inset Quotes erd
20405 \end_inset
20406
20407 .
20408 \end_layout
20409
20410 \begin_layout Enumerate
20411
20412
20413 \size small
20414 Math mode still on at end of LaTeX file.
20415 \end_layout
20416
20417 \begin_layout Enumerate
20418
20419
20420 \size small
20421 Number of 
20422 \begin_inset Quotes eld
20423 \end_inset
20424
20425
20426 \family typewriter
20427 char
20428 \family default
20429
20430 \begin_inset Quotes erd
20431 \end_inset
20432
20433  doesn't match the number of 
20434 \begin_inset Quotes eld
20435 \end_inset
20436
20437
20438 \family typewriter
20439 char
20440 \family default
20441
20442 \begin_inset Quotes erd
20443 \end_inset
20444
20445 .
20446 \end_layout
20447
20448 \begin_layout Enumerate
20449
20450
20451 \size small
20452 You should use either 
20453 \family typewriter
20454
20455 \begin_inset Quotes eld
20456 \end_inset
20457
20458
20459 \family default
20460  or 
20461 \family typewriter
20462
20463 \begin_inset Quotes erd
20464 \end_inset
20465
20466
20467 \family default
20468  as an alternative to 
20469 \begin_inset Quotes eld
20470 \end_inset
20471
20472
20473 \family typewriter
20474 "
20475 \family default
20476
20477 \begin_inset Quotes erd
20478 \end_inset
20479
20480 .
20481 \end_layout
20482
20483 \begin_layout Enumerate
20484
20485
20486 \size small
20487 You should use "
20488 \family typewriter
20489 '
20490 \family default
20491 " (ASCII 39) instead of "
20492 \family typewriter
20493 ´
20494 \family default
20495 " (ASCII 180).
20496 \end_layout
20497
20498 \begin_layout Enumerate
20499
20500
20501 \size small
20502 User-specified pattern found.
20503 \end_layout
20504
20505 \begin_layout Enumerate
20506
20507
20508 \size small
20509 This command might not be intended.
20510 \end_layout
20511
20512 \begin_layout Enumerate
20513
20514
20515 \size small
20516 \emph on
20517 Comment displayed.
20518 \end_layout
20519
20520 \begin_layout Enumerate
20521
20522
20523 \size small
20524 Either 
20525 \family typewriter
20526 ''
20527 \backslash
20528 ,'
20529 \family default
20530  or 
20531 \family typewriter
20532 '
20533 \backslash
20534 ,''
20535 \family default
20536  will look better.
20537 \end_layout
20538
20539 \begin_layout Enumerate
20540
20541
20542 \size small
20543 Delete this space to maintain correct page references.
20544 \end_layout
20545
20546 \begin_layout Enumerate
20547
20548
20549 \size small
20550 \emph on
20551 You might wish to put this between a pair of 
20552 \begin_inset Quotes eld
20553 \end_inset
20554
20555
20556 \family typewriter
20557 {}
20558 \family default
20559
20560 \begin_inset Quotes erd
20561 \end_inset
20562
20563 .
20564 \end_layout
20565
20566 \begin_layout Enumerate
20567
20568
20569 \size small
20570 You ought to remove spaces in front of punctuation.
20571 \end_layout
20572
20573 \begin_layout Enumerate
20574
20575
20576 \size small
20577 Could not execute LaTeX command.
20578 \end_layout
20579
20580 \begin_layout Enumerate
20581
20582
20583 \size small
20584 Don't use 
20585 \family typewriter
20586
20587 \backslash
20588 /
20589 \family default
20590  in front of small punctuation.
20591 \end_layout
20592
20593 \begin_layout Enumerate
20594
20595
20596 \family typewriter
20597 \size small
20598 $
20599 \backslash
20600 times$
20601 \family default
20602  may look prettier here.
20603 \end_layout
20604
20605 \begin_layout Enumerate
20606
20607
20608 \size small
20609 \emph on
20610 Multiple spaces detected in output.
20611 \end_layout
20612
20613 \begin_layout Enumerate
20614
20615
20616 \size small
20617 This text may be ignored.
20618 \end_layout
20619
20620 \begin_layout Enumerate
20621
20622
20623 \size small
20624 Use 
20625 \family typewriter
20626
20627 \begin_inset Quotes eld
20628 \end_inset
20629
20630
20631 \family default
20632  to begin quotation, not 
20633 \family typewriter
20634 '
20635 \family default
20636 .
20637 \end_layout
20638
20639 \begin_layout Enumerate
20640
20641
20642 \size small
20643 Use 
20644 \family typewriter
20645 '
20646 \family default
20647  to end quotation, not 
20648 \family typewriter
20649
20650 \begin_inset Quotes eld
20651 \end_inset
20652
20653
20654 \family default
20655 .
20656 \end_layout
20657
20658 \begin_layout Enumerate
20659
20660
20661 \size small
20662 Don't mix quotes.
20663 \end_layout
20664
20665 \begin_layout Enumerate
20666
20667
20668 \size small
20669 You should perhaps use 
20670 \begin_inset Quotes eld
20671 \end_inset
20672
20673
20674 \family typewriter
20675 cmd
20676 \family default
20677
20678 \begin_inset Quotes erd
20679 \end_inset
20680
20681  instead.
20682 \end_layout
20683
20684 \begin_layout Enumerate
20685
20686
20687 \size small
20688 You should put a space in front of/after parenthesis.
20689 \end_layout
20690
20691 \begin_layout Enumerate
20692
20693
20694 \size small
20695 You should avoid spaces in front of/after parenthesis.
20696 \end_layout
20697
20698 \begin_layout Enumerate
20699
20700
20701 \size small
20702 \emph on
20703 You should not use punctuation in front of/after quotes.
20704 \end_layout
20705
20706 \begin_layout Enumerate
20707
20708
20709 \size small
20710 Double space found.
20711 \end_layout
20712
20713 \begin_layout Enumerate
20714
20715
20716 \size small
20717 You should put punctuation outside inner/inside display math mode.
20718 \end_layout
20719
20720 \begin_layout Enumerate
20721
20722
20723 \size small
20724 You ought to not use primitive TeX in LaTeX code.
20725 \end_layout
20726
20727 \begin_layout Enumerate
20728
20729
20730 \size small
20731 You should remove spaces in front of 
20732 \begin_inset Quotes eld
20733 \end_inset
20734
20735
20736 \family typewriter
20737 %s
20738 \family default
20739
20740 \begin_inset Quotes erd
20741 \end_inset
20742
20743
20744 \end_layout
20745
20746 \begin_layout Enumerate
20747
20748
20749 \size small
20750
20751 \begin_inset Quotes eld
20752 \end_inset
20753
20754
20755 \family typewriter
20756 %s
20757 \family default
20758
20759 \begin_inset Quotes erd
20760 \end_inset
20761
20762  is normally not followed by 
20763 \begin_inset Quotes eld
20764 \end_inset
20765
20766
20767 \family typewriter
20768 %c
20769 \family default
20770
20771 \begin_inset Quotes erd
20772 \end_inset
20773
20774 .
20775 \end_layout
20776
20777 \begin_layout Standard
20778
20779 In later versions of LyX, we hope to provide a more complete interface to
20780  this tool (and it's smaller cousin 
20781 \family typewriter
20782 lacheck
20783 \family default
20784 ) to exploit the full power of it.
20785  But it's not exactly useless as it is now: go try it on one of your existing
20786  documents of a certain length and be surprised.
20787 \end_layout
20788
20789 \begin_layout Section
20790
20791 Version Control in LyX
20792 \end_layout
20793
20794 \begin_layout Standard
20795
20796 by
20797 \noun on
20798  Lars Gullik Bjønnes
20799 \end_layout
20800
20801 \begin_layout Subsection
20802
20803 Introduction
20804 \end_layout
20805
20806 \begin_layout Standard
20807
20808 A friend of mine wanted to try LyX for a group project.
20809  When he didn't find support for version control or file locking, he dropped
20810  it.
20811  This angered me a bit, so I thought that I should at least make support
20812  for RCS (with the possibility of CVS and/or SCCS as a future improvement.)
20813  This has now been done.
20814  LyX now supports some of the most basic RCS commands.
20815  If you need to something a bit more sophisticated you will have to do that
20816  manually in an xterm.
20817 \end_layout
20818
20819 \begin_layout Standard
20820
20821 Before you begin to use the version control features in LyX, you should
20822  read 
20823 \begin_inset Quotes eld
20824 \end_inset
20825
20826 rcsintro
20827 \begin_inset Quotes erd
20828 \end_inset
20829
20830  (a man file, read it with 
20831 \family typewriter
20832 man rcsintro
20833 \family default
20834 ).
20835  This file describes all the basic features of RCS.
20836  You should especially notice the comment about a RCS directory, and the
20837  notion of a master RCS file (the file ending in 
20838 \family typewriter
20839 ,v
20840 \family default
20841 ).
20842 \end_layout
20843
20844 \begin_layout Standard
20845
20846 The implementation in LyX assumes a recent version of the GNU RCS package---no
20847  guarantees are made for older versions.
20848 \end_layout
20849
20850 \begin_layout Subsection
20851
20852 RCS commands in LyX
20853 \end_layout
20854
20855 \begin_layout Standard
20856
20857 The following sections describe the RCS commands supported by LyX.
20858  You can find them in the 
20859 \family sans
20860 \bar under
20861 F
20862 \bar default
20863 ile\SpecialChar \menuseparator
20864
20865 \bar under
20866 V
20867 \bar default
20868 ersion\InsetSpace ~
20869 Control
20870 \family default
20871  submenu.
20872 \end_layout
20873
20874 \begin_layout Subsubsection
20875
20876
20877 \family sans
20878 Register
20879 \end_layout
20880
20881 \begin_layout Standard
20882
20883 If your document is not under revision control, this is the only item shown
20884  in the menu.
20885  And if it is under revision control, the 
20886 \family sans
20887 \bar under
20888 R
20889 \bar default
20890 egister
20891 \family default
20892  item is grayed out.
20893  
20894 \end_layout
20895
20896 \begin_layout Standard
20897
20898 This command registers your document with RCS\SpecialChar \@.
20899  You are asked interactively
20900  to supply an initial description of the document.
20901  The document is now set in Read-Only mode and you have to 
20902 \family sans
20903 Check\InsetSpace ~
20904 Out\InsetSpace ~
20905 For\InsetSpace ~
20906 Edit
20907 \family default
20908 , before making any changes to it.
20909  A document under revision control has a 
20910 \begin_inset Quotes eld
20911 \end_inset
20912
20913 [RCS:<version> <locker>]
20914 \begin_inset Quotes erd
20915 \end_inset
20916
20917  item tagged to the filename in the minibuffer.
20918 \end_layout
20919
20920 \begin_layout Standard
20921
20922 RCS command that is run: 
20923 \family typewriter
20924 ci -q -u -i -t-"<initial description>" <file-name>
20925 \end_layout
20926
20927 \begin_layout Standard
20928
20929 Read 
20930 \family typewriter
20931 man ci
20932 \family default
20933  to understand the switches.
20934  
20935 \end_layout
20936
20937 \begin_layout Subsubsection
20938
20939
20940 \family sans
20941 Check In Changes
20942 \end_layout
20943
20944 \begin_layout Standard
20945
20946 When you are finished editing a file, you check in your changes.
20947  When you do this, you are asked for a description of the changes.
20948  This is stored in the history log.
20949  The version number is bumped, your changes are applied to the master RCS
20950  file, the document is unlocked and set to Read-Only mode.
20951  
20952 \end_layout
20953
20954 \begin_layout Standard
20955
20956 RCS command: 
20957 \family typewriter
20958 ci -q -u -m"<description>" <file-name>
20959 \end_layout
20960
20961 \begin_layout Subsubsection
20962
20963
20964 \family sans
20965 Check Out For Edit
20966 \end_layout
20967
20968 \begin_layout Standard
20969
20970 By doing this you lock the document so that only you can edit it.
20971  This will also make the document Read-Write only for you.
20972  You will usually continue editing for a while and when you are finished
20973  you check in your changes.
20974  The status line is changed to reflect that you have locked the file.
20975  
20976 \end_layout
20977
20978 \begin_layout Standard
20979
20980 RCS command: 
20981 \family typewriter
20982 co -q -l <file-name>
20983 \end_layout
20984
20985 \begin_layout Subsubsection
20986
20987
20988 \family sans
20989 Revert To Last Version
20990 \end_layout
20991
20992 \begin_layout Standard
20993
20994 This will discard all changes made to the document since the last check
20995  in.
20996  You get a warning before changes are discarded.
20997 \end_layout
20998
20999 \begin_layout Standard
21000
21001 RCS command: 
21002 \family typewriter
21003 co -f -u<version> <file-name>
21004 \end_layout
21005
21006 \begin_layout Subsubsection
21007
21008
21009 \family sans
21010 Undo Last Checkin
21011 \end_layout
21012
21013 \begin_layout Standard
21014
21015 This makes as if the last check in never happened.
21016  No changes are made to the document loaded into LyX, but the last version
21017  is removed from the master RCS file.
21018  
21019 \end_layout
21020
21021 \begin_layout Standard
21022
21023 RCS command: 
21024 \family typewriter
21025 rcs -o<version> <file-name>
21026 \end_layout
21027
21028 \begin_layout Subsubsection
21029
21030
21031 \family sans
21032 Show History
21033 \end_layout
21034
21035 \begin_layout Standard
21036
21037 This show the complete history of the RCS document.
21038  The output of 
21039 \family typewriter
21040 rlog <file-name>
21041 \family default
21042  is shown in a browser.
21043  See 
21044 \family typewriter
21045 man rlog
21046 \family default
21047  for more info.
21048 \end_layout
21049
21050 \begin_layout Section
21051
21052 Literate Programming
21053 \end_layout
21054
21055 \begin_layout Standard
21056
21057 Updated by 
21058 \noun on
21059 Kayvan Sylvan 
21060 \noun default
21061 (kayvan@sylvan.com)
21062 \noun on
21063
21064 \noun default
21065 original documentation written by 
21066 \noun on
21067 Edmar Wienskoski Jr.
21068
21069 \noun default
21070  (edmar-w-jr@technologist.com)
21071 \end_layout
21072
21073 \begin_layout Subsection
21074
21075 Introduction
21076 \end_layout
21077
21078 \begin_layout Standard
21079
21080 The main purpose of this documentation is to show you how to use LyX for
21081  literate programming.
21082  Where it is assumed that you are familiar with this programming technique,
21083  and know what 
21084 \begin_inset Quotes eld
21085 \end_inset
21086
21087 tangling
21088 \begin_inset Quotes erd
21089 \end_inset
21090
21091  and 
21092 \begin_inset Quotes eld
21093 \end_inset
21094
21095 weaving
21096 \begin_inset Quotes erd
21097 \end_inset
21098
21099  means.
21100  If that is not the case, please follow the web links provided in the following
21101  sections.
21102  There is a lot of good documentation out there covering old development
21103  history to the latest tools tips.
21104 \end_layout
21105
21106 \begin_layout Standard
21107
21108 It is also assumed that you are familiar with LyX itself to a point that
21109  you are comfortable changing your LyX preferences, and X resources file.
21110  If that is not the case please refer to other LyX documentation to cover
21111  your specific needs.
21112 \end_layout
21113
21114 \begin_layout Subsection
21115
21116 Literate Programming
21117 \end_layout
21118
21119 \begin_layout Standard
21120
21121 From the Literate Programming FAQ: 
21122 \end_layout
21123
21124 \begin_layout Quotation
21125
21126 Literate programming is the combination of documentation and source together
21127  in a fashion suited for reading by human beings.
21128  In fact, literate programs should be enjoyable reading, even inviting!
21129  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
21130  and documentation in a single file.
21131  Literate programming tools then parse the file to produce either readable
21132  documentation or compilable source.
21133  The WEB style of literate programming was created by D.E.
21134  Knuth during the development of his TeX typesetting software.
21135  
21136 \end_layout
21137
21138 \begin_layout Standard
21139
21140 Another excerpt says:
21141 \end_layout
21142
21143 \begin_layout Quotation
21144
21145
21146 \emph on
21147 How is literate programming different from verbose commenting?
21148 \end_layout
21149
21150 \begin_layout Quotation
21151
21152 There are three distinguishing characteristics.
21153  In order of importance, they are: 
21154 \end_layout
21155
21156 \begin_deeper
21157 \begin_layout Itemize
21158
21159 flexible order of elaboration 
21160 \end_layout
21161
21162 \begin_layout Itemize
21163
21164 automatic support for browsing 
21165 \end_layout
21166
21167 \begin_layout Itemize
21168
21169 typeset documentation, especially diagrams and mathematics 
21170 \end_layout
21171 \end_deeper
21172 \begin_layout Standard
21173
21174 Now that I sparked your curiosity, take a look in the references.
21175 \end_layout
21176
21177 \begin_layout Subsubsection
21178
21179 References
21180 \end_layout
21181
21182 \begin_layout Standard
21183
21184 The complete Literate Programming FAQ can be found at:
21185 \end_layout
21186
21187 \begin_layout Quote
21188
21189
21190 \begin_inset LatexCommand \url[Literate Programming FAQ]{http://shelob.ce.ttu.edu/daves/lpfaq/faq.html}
21191
21192 \end_inset
21193
21194
21195 \end_layout
21196
21197 \begin_layout Standard
21198
21199 The FAQ lists 23 (twenty three!) different literate programming tools.
21200  Where some are specialized or 
21201 \begin_inset Quotes eld
21202 \end_inset
21203
21204 tailored
21205 \begin_inset Quotes erd
21206 \end_inset
21207
21208  for particular programming languages, while other have general scope.
21209  I selected 
21210 \noun on
21211 Noweb
21212 \noun default
21213  for my own use for several reasons:
21214 \end_layout
21215
21216 \begin_layout Itemize
21217
21218 It can generate the documentation either in latex or html.
21219 \end_layout
21220
21221 \begin_layout Itemize
21222
21223 It has a open architecture, i.e., it is easy to plug in new filters and to
21224  perform special processing that you may need.
21225  
21226 \end_layout
21227
21228 \begin_layout Itemize
21229
21230 There is a good selection of filters available already (the html is one
21231  of them).
21232 \end_layout
21233
21234 \begin_layout Itemize
21235
21236 It is free.
21237 \end_layout
21238
21239 \begin_layout Standard
21240
21241 The Noweb web page can be found at: 
21242 \end_layout
21243
21244 \begin_layout Quote
21245
21246
21247 \begin_inset LatexCommand \url[Noweb home page]{http://www.cs.virginia.edu/~nr/noweb/}
21248
21249 \end_inset
21250
21251
21252 \end_layout
21253
21254 \begin_layout Standard
21255
21256 Starting from there you can reach many other interesting links and even
21257  some literate program examples.
21258 \end_layout
21259
21260 \begin_layout Subsection
21261
21262 LyX and Literate Programming
21263 \end_layout
21264
21265 \begin_layout Standard
21266
21267 The LyX support for Literate Programming is provided by using the generic
21268  LyX convertors mechanism.
21269  This support is provided in a 
21270 \begin_inset Quotes eld
21271 \end_inset
21272
21273 Noweb independent
21274 \begin_inset Quotes erd
21275 \end_inset
21276
21277  way, i.e., you will be able to use this new LyX feature with some other literate
21278  programming tool of your choice by just changing your LyX preferences.
21279 \end_layout
21280
21281 \begin_layout Subsubsection
21282
21283 Generating documents and code (weaving and tangling)
21284 \end_layout
21285
21286 \begin_layout Paragraph
21287
21288 Selecting the document class
21289 \end_layout
21290
21291 \begin_layout Standard
21292
21293 If you have installed Noweb and LyX successfully, whenever you open a new
21294  document or try to change the document class of an existing one, you will
21295  find that there are three new document classes available:
21296 \end_layout
21297
21298 \begin_layout Itemize
21299
21300 Article (Noweb)
21301 \end_layout
21302
21303 \begin_layout Itemize
21304
21305 Book (Noweb)
21306 \end_layout
21307
21308 \begin_layout Itemize
21309
21310 Report (Noweb)
21311 \end_layout
21312
21313 \begin_layout Standard
21314
21315 You must select one of them to create your literate documents from.
21316  
21317 \end_layout
21318
21319 \begin_layout Standard
21320
21321 Note that literate documents are not limited to these three classes.
21322  New classes can be generated from other styles like letter or in combination
21323  with other class variations like Article (AMS).
21324  If you have special needs that cannot be covered by one of the existing
21325  classes, let the LyX developers list (lyx-devel@lists.lyx.org) know and we
21326  will arrange to insert a new entry, or teach you how to do it.
21327 \begin_inset Foot
21328 status collapsed
21329
21330 \begin_layout Standard
21331
21332 It is very simple, it involves the creation of a file with four lines, and
21333  re-running of the auto configuration.
21334 \end_layout
21335
21336 \end_inset
21337
21338  Moreover, if you use a literate tool other than Noweb you may need to create
21339  a new set of document classes for it.
21340 \end_layout
21341
21342 \begin_layout Paragraph
21343
21344 Typing code in
21345 \end_layout
21346
21347 \begin_layout Standard
21348
21349 LyX enables you to write code with a layout named 
21350 \noun on
21351 Scrap
21352 \noun default
21353 .
21354 \begin_inset Foot
21355 status collapsed
21356
21357 \begin_layout Standard
21358
21359 The equivalent Noweb term is 
21360 \begin_inset Quotes eld
21361 \end_inset
21362
21363 Chunk
21364 \begin_inset Quotes erd
21365 \end_inset
21366
21367 .
21368  For historical reasons, I got used to the term 
21369 \begin_inset Quotes eld
21370 \end_inset
21371
21372 scrap
21373 \begin_inset Quotes erd
21374 \end_inset
21375
21376  introduced by other literate tool named Nuweb, which I used for many years
21377  before rendering myself to Noweb.
21378 \end_layout
21379
21380 \end_inset
21381
21382  Noweb delimits scraps like this:
21383 \end_layout
21384
21385 \begin_layout LyX-Code
21386
21387 <<My scrap>>=
21388 \end_layout
21389
21390 \begin_layout LyX-Code
21391
21392   code
21393 \end_layout
21394
21395 \begin_layout LyX-Code
21396
21397   more code
21398 \end_layout
21399
21400 \begin_layout LyX-Code
21401
21402   even more code
21403 \end_layout
21404
21405 \begin_layout LyX-Code
21406
21407   @
21408 \end_layout
21409
21410 \begin_layout Standard
21411
21412 The problem is that whatever is written in between the << and the 
21413 \family typewriter
21414 @
21415 \family default
21416  must be taken literally, i.e., LyX should be prevented from making any special
21417  interpretation of what has been written.
21418  This is handled by a special layout named Scrap, that works like a normal
21419  paragraph but has a free spacing capability.
21420 \end_layout
21421
21422 \begin_layout Standard
21423
21424 The down side of the Scrap paragraph layout is that consecutive paragraphs
21425  of code will be spaced with one empty line in the source code and also
21426  in the printed documentation.
21427  The work around is to enter each line of code within a single Scrap, with
21428  a newline (ctrl-return).
21429  The example above will look like this:
21430 \begin_inset Foot
21431 status collapsed
21432
21433 \begin_layout Standard
21434
21435 If you have a printed version of this document you will not see any difference
21436  between the previous example and this one.
21437 \end_layout
21438
21439 \end_inset
21440
21441
21442 \end_layout
21443
21444 \begin_layout LyX-Code
21445
21446 <<My scrap>>=
21447 \newline
21448   code
21449 \newline
21450   more code
21451 \newline
21452   even more code
21453 \newline
21454   @
21455 \end_layout
21456
21457 \begin_layout Standard
21458
21459 This layout works fine.
21460  The only real inconvenience is that you have to type ctrl-return instead
21461  of a plain return.
21462 \begin_inset Foot
21463 status collapsed
21464
21465 \begin_layout Standard
21466
21467 It is in my list of 
21468 \begin_inset Quotes eld
21469 \end_inset
21470
21471 improvements
21472 \begin_inset Quotes erd
21473 \end_inset
21474
21475  to fix that.
21476 \end_layout
21477
21478 \end_inset
21479
21480
21481 \end_layout
21482
21483 \begin_layout Standard
21484
21485 As a special note, you can also use the 
21486 \begin_inset Quotes eld
21487 \end_inset
21488
21489 %def
21490 \begin_inset Quotes erd
21491 \end_inset
21492
21493  construct of Noweb in your scraps to add items to Noweb's identifier cross-refe
21494 rence:
21495 \end_layout
21496
21497 \begin_layout LyX-Code
21498
21499 <<My scrap>>=
21500 \newline
21501   def some_function(args):
21502 \newline
21503     "This is the doc string for this function."
21504 \newline
21505     print "My args: ", args
21506 \end_layout
21507
21508 \begin_layout LyX-Code
21509
21510 @ %def some_function
21511 \end_layout
21512
21513 \begin_layout Standard
21514
21515 For an example of this usage and the resulting cross-reference output, look
21516  at the Literate python program in 
21517 \emph on
21518 LIBDIR/examples/listerrors.lyx 
21519 \emph default
21520 which should make this all clear.
21521 \end_layout
21522
21523 \begin_layout Paragraph
21524
21525 Generating the documentation
21526 \end_layout
21527
21528 \begin_layout Standard
21529
21530 At this point you already have a new document file with a proper document
21531  class, and with some code and text on it.
21532  How do I print it? The answer is simple, you select 
21533 \family sans
21534 \bar under
21535 V
21536 \bar default
21537 iew\SpecialChar \menuseparator
21538
21539 \bar under
21540 D
21541 \bar default
21542 VI,
21543 \family default
21544  etc.
21545  Just like you would do for a plain document.
21546  No special procedure is required.
21547 \end_layout
21548
21549 \begin_layout Standard
21550
21551 To help orientate you, I will now explain what happens inside LyX:
21552 \end_layout
21553
21554 \begin_layout Enumerate
21555
21556 When the 
21557 \family sans
21558 \bar under
21559 U
21560 \bar default
21561 pdate\SpecialChar \menuseparator
21562
21563 \bar under
21564 D
21565 \bar default
21566 VI 
21567 \family default
21568 menu option is chosen, a latex file is generated.
21569  
21570 \end_layout
21571
21572 \begin_deeper
21573 \begin_layout Standard
21574
21575 If the document is of any literate class the generated file will be named
21576  with an extension name defined by the 
21577 \begin_inset Quotes eld
21578 \end_inset
21579
21580 literate
21581 \begin_inset Quotes erd
21582 \end_inset
21583
21584  format (defined in the Preferences panel), otherwise the file will have
21585  the usual 
21586 \family typewriter
21587 .tex 
21588 \family default
21589 extension.
21590 \end_layout
21591 \end_deeper
21592 \begin_layout Enumerate
21593
21594 Note that the only difference so far is in the name of the file, no special
21595  processing is required by LyX.
21596  Given that you formatted the code using the Scrap layout that, by itself,
21597  takes care of the business.
21598 \end_layout
21599
21600 \begin_layout Enumerate
21601
21602 If the document is of any literate class LyX will then use the internal
21603  LyX to Noweb converter, followed by the Noweb to LaTeX converter
21604 \begin_inset Foot
21605 status open
21606
21607 \begin_layout Standard
21608
21609 The converters are defined in the 
21610 \family sans
21611 \bar under
21612 T
21613 \bar default
21614 ools\SpecialChar \menuseparator
21615
21616 \bar under
21617 P
21618 \bar default
21619 references
21620 \family default
21621  panel, under the 
21622 \begin_inset Quotes eld
21623 \end_inset
21624
21625 Conversion
21626 \begin_inset Quotes erd
21627 \end_inset
21628
21629  tab.
21630 \end_layout
21631
21632 \end_inset
21633
21634  to generate the LaTeX file.
21635 \end_layout
21636
21637 \begin_deeper
21638 \begin_layout Standard
21639
21640 Otherwise it will just skip this step.
21641 \end_layout
21642 \end_deeper
21643 \begin_layout Enumerate
21644
21645 Finally, LaTeX is invoked and the regular post processing continues as in
21646  a plain document.
21647 \end_layout
21648
21649 \begin_layout Standard
21650
21651 Independence from a particular 
21652 \begin_inset Quotes eld
21653 \end_inset
21654
21655 literate tool
21656 \begin_inset Quotes erd
21657 \end_inset
21658
21659  is easily achieved by changing the commands that are run by the various
21660  converters.
21661 \end_layout
21662
21663 \begin_layout Paragraph
21664
21665 Generating the code
21666 \end_layout
21667
21668 \begin_layout Standard
21669
21670 When the build menu option is chosen or the corresponding button in the
21671  toolbar is pressed, a latex file is generated just like step 1 above.
21672  Next, LyX invokes the
21673 \family typewriter
21674  Noweb->Program
21675 \family default
21676  converter.
21677  Typically, this converter (like any other converter), has two parts:
21678 \end_layout
21679
21680 \begin_layout Enumerate
21681
21682 The converter program itself.
21683  This program performs the conversion from the one format to the other (in
21684  this case, from the Noweb format to the Program pseudo-format).
21685 \end_layout
21686
21687 \begin_layout Enumerate
21688
21689 The error log parser.
21690  This is a program whose sole purpose is to rewrite error messages in a
21691  format that LyX understands.
21692  This makes it possible for LyX to place error boxes in the right places
21693  in the file buffer.
21694 \end_layout
21695
21696 \begin_layout Standard
21697
21698 The first part, the 
21699 \begin_inset Quotes eld
21700 \end_inset
21701
21702 Converter
21703 \begin_inset Quotes erd
21704 \end_inset
21705
21706  setting, should be set to 
21707 \begin_inset Quotes eld
21708 \end_inset
21709
21710
21711 \family typewriter
21712 build-script $$i
21713 \family default
21714
21715 \begin_inset Quotes erd
21716 \end_inset
21717
21718 .
21719  This basically means that LyX will call 
21720 \begin_inset Quotes eld
21721 \end_inset
21722
21723 build-script
21724 \begin_inset Quotes erd
21725 \end_inset
21726
21727  (a program or script) with the name of the Noweb file (generally a file
21728  in the LyX temp directory).
21729  
21730 \end_layout
21731
21732 \begin_layout Standard
21733
21734 This is an implementation of 
21735 \begin_inset Quotes eld
21736 \end_inset
21737
21738 build-script
21739 \begin_inset Quotes erd
21740 \end_inset
21741
21742  that you can place in a directory on your path:
21743 \end_layout
21744
21745 \begin_layout LyX-Code
21746
21747 #!/bin/sh
21748 \end_layout
21749
21750 \begin_layout LyX-Code
21751
21752 #
21753 \end_layout
21754
21755 \begin_layout LyX-Code
21756
21757 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 sh
21758 \end_layout
21759
21760 \begin_layout Standard
21761
21762 The next part of the converter setting is the 
21763 \begin_inset Quotes eld
21764 \end_inset
21765
21766 Flags
21767 \begin_inset Quotes erd
21768 \end_inset
21769
21770  which is to be set to 
21771 \begin_inset Quotes eld
21772 \end_inset
21773
21774
21775 \family typewriter
21776 originaldir,parselog=listerrors
21777 \family default
21778
21779 \begin_inset Quotes erd
21780 \end_inset
21781
21782 .
21783  This will run any errors that are generated by the 
21784 \begin_inset Quotes eld
21785 \end_inset
21786
21787 build-script
21788 \begin_inset Quotes erd
21789 \end_inset
21790
21791  process through the 
21792 \begin_inset Quotes eld
21793 \end_inset
21794
21795 listerrors
21796 \begin_inset Quotes erd
21797 \end_inset
21798
21799  program.
21800 \end_layout
21801
21802 \begin_layout Standard
21803
21804 The converter code looks in 
21805 \emph on
21806 MYLYXDIR/scripts 
21807 \emph default
21808 first, then in
21809 \emph on
21810  LIBDIR/scripts 
21811 \emph default
21812 then on the path for the 
21813 \begin_inset Quotes eld
21814 \end_inset
21815
21816 listerrors
21817 \begin_inset Quotes erd
21818 \end_inset
21819
21820  program.
21821 \end_layout
21822
21823 \begin_layout Paragraph
21824
21825 Build instructions in the document
21826 \end_layout
21827
21828 \begin_layout Standard
21829
21830 The last piece of the integration between LyX and noweb is the 
21831 \begin_inset Quotes eld
21832 \end_inset
21833
21834 build-script
21835 \begin_inset Quotes erd
21836 \end_inset
21837
21838  scrap.
21839  Generally, the instructions for building your program should be embedded
21840  in a scrap of its own.
21841  The noweb-specific 
21842 \begin_inset Quotes eld
21843 \end_inset
21844
21845 build-script
21846 \begin_inset Quotes erd
21847 \end_inset
21848
21849  above uses the notangle command to look for this scrap (called 
21850 \begin_inset Quotes eld
21851 \end_inset
21852
21853 build-script
21854 \begin_inset Quotes erd
21855 \end_inset
21856
21857 ) and runs its contents through 
21858 \begin_inset Quotes eld
21859 \end_inset
21860
21861 sh
21862 \begin_inset Quotes erd
21863 \end_inset
21864
21865 .
21866 \end_layout
21867
21868 \begin_layout Standard
21869
21870 Typically, such a scrap would look something like this:
21871 \end_layout
21872
21873 \begin_layout LyX-Code
21874
21875 <<build-script>>=
21876 \newline
21877 #!/bin/sh
21878 \newline
21879
21880 \newline
21881 if [ -z "${NOWEB_SOURCE}" ]
21882 \newline
21883 then
21884 \newline
21885   NOWEB_SOURCE=myfile.nw
21886 \newline
21887 fi
21888 \newline
21889 [...
21890  code to extract files ...]
21891 \newline
21892 [...
21893  code to compile files ...]
21894 \newline
21895 @
21896 \end_layout
21897
21898 \begin_layout Standard
21899
21900 Look in 
21901 \emph on
21902 LIBDIR/examples/listerrors.lyx 
21903 \emph default
21904 or in 
21905 \emph on
21906 LIBDIR/examples/Literate.lyx
21907 \emph default
21908  which implement two versions of the 
21909 \begin_inset Quotes eld
21910 \end_inset
21911
21912 listerrors
21913 \begin_inset Quotes erd
21914 \end_inset
21915
21916  program for some illustrations of how all of these pieces go together or
21917  in 
21918 \emph on
21919 LIBDIR/examples/noweb2lyx.lyx.
21920  
21921 \emph default
21922 Interestingly, these three files show off the language-indepence of the
21923  LyX literate programming support since they are written in Python, C and
21924  Perl respectively.
21925 \end_layout
21926
21927 \begin_layout Subsubsection
21928
21929 Configuring LyX
21930 \end_layout
21931
21932 \begin_layout Standard
21933
21934 All the Literate Programming support is configured by the 
21935 \family sans
21936 \bar under
21937 T
21938 \bar default
21939 ools\SpecialChar \menuseparator
21940
21941 \bar under
21942 P
21943 \bar default
21944 references
21945 \family default
21946  panel in the 
21947 \begin_inset Quotes eld
21948 \end_inset
21949
21950 Conversion
21951 \begin_inset Quotes erd
21952 \end_inset
21953
21954  tab.
21955  The important parts are:
21956 \end_layout
21957
21958 \begin_layout Description
21959
21960 the\InsetSpace ~
21961
21962 \begin_inset Quotes eld
21963 \end_inset
21964
21965 literate
21966 \begin_inset Quotes erd
21967 \end_inset
21968
21969 \InsetSpace ~
21970 format Set up via the Formats tab, this is where the Noweb-specific pieces
21971  are set up.
21972  The 
21973 \family sans
21974 GUI Name
21975 \family default
21976  is set to 
21977 \family typewriter
21978 NoWeb
21979 \family default
21980 , the file extension is set to 
21981 \family typewriter
21982 .nw
21983 \family default
21984 .
21985  This tells LyX to create a file with a 
21986 \family typewriter
21987 .nw
21988 \family default
21989  extension in the first step of the conversion process.
21990 \end_layout
21991
21992 \begin_layout Description
21993
21994 the\InsetSpace ~
21995
21996 \family sans
21997 Program
21998 \family default
21999 \InsetSpace ~
22000 format This is an empty format whose sole purpose is to be the endpoint
22001  of a conversion (which then allows us to set up a converter for it).
22002 \end_layout
22003
22004 \begin_layout Description
22005
22006
22007 \family sans
22008 NoWeb
22009 \family default
22010 ->
22011 \family sans
22012 LaTeX
22013 \family default
22014  This converter performs the 
22015 \begin_inset Quotes eld
22016 \end_inset
22017
22018 weaving
22019 \begin_inset Quotes erd
22020 \end_inset
22021
22022  of the literate document.
22023  For Noweb, it is set to 
22024 \begin_inset Quotes eld
22025 \end_inset
22026
22027
22028 \family typewriter
22029 noweave -delay -index $$i > $$o
22030 \family default
22031
22032 \begin_inset Quotes erd
22033 \end_inset
22034
22035
22036 \end_layout
22037
22038 \begin_layout Description
22039
22040
22041 \family sans
22042 NoWeb
22043 \family default
22044 ->
22045 \family sans
22046 Program
22047 \family default
22048  This performs the 
22049 \begin_inset Quotes eld
22050 \end_inset
22051
22052 tangling step
22053 \begin_inset Quotes erd
22054 \end_inset
22055
22056 .
22057  As stated above, the Converter is set to 
22058 \begin_inset Quotes eld
22059 \end_inset
22060
22061
22062 \family typewriter
22063 build-script $$i
22064 \family default
22065
22066 \begin_inset Quotes erd
22067 \end_inset
22068
22069 , with Flags set to 
22070 \begin_inset Quotes eld
22071 \end_inset
22072
22073
22074 \family typewriter
22075 originaldir,parselog=listerrors
22076 \family default
22077
22078 \begin_inset Quotes erd
22079 \end_inset
22080
22081 .
22082 \end_layout
22083
22084 \begin_layout Subsubsection
22085
22086 Debug extensions
22087 \end_layout
22088
22089 \begin_layout Standard
22090
22091 There is also a new function implemented in the LyX server, the 
22092 \begin_inset Quotes eld
22093 \end_inset
22094
22095 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
22096  
22097 \end_layout
22098
22099 \begin_layout Standard
22100
22101 When debugging code with ddd/gdb, it is possible to invoke a text editor
22102  at the current execution position with a single key stroke.
22103  The default ddd configuration for that is shift-ctrl-V.
22104  It happens that you can define the editor command line invocation in ddd
22105  by accessing the
22106 \family sans
22107  
22108 \bar under
22109 E
22110 \bar default
22111 dit\SpecialChar \menuseparator
22112
22113 \bar under
22114 P
22115 \bar default
22116 references\SpecialChar \menuseparator
22117
22118 \bar under
22119 H
22120 \bar default
22121 elpers 
22122 \family default
22123 dialog and changing the "Edit Sources" entry.
22124 \end_layout
22125
22126 \begin_layout Standard
22127
22128 I take advantage of the new created LyX server function and this ddd feature,
22129  and set 
22130 \begin_inset Quotes eld
22131 \end_inset
22132
22133 Edit Sources
22134 \begin_inset Quotes erd
22135 \end_inset
22136
22137  to:
22138 \end_layout
22139
22140 \begin_layout LyX-Code
22141
22142 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
22143 \end_layout
22144
22145 \begin_layout Standard
22146
22147 With this, whenever you are using ddd and find a point in the program that
22148  you want to edit, you just press shift-ctrl-V (in the ddd window), and
22149  ddd you forward this information to LyX through the LyX server and then
22150  the LyX window will show the same file with the cursor at the same position
22151  ddd was pointing to.
22152  No more guessing or long scrolling to locate a point in the program back
22153  from debugging !
22154 \end_layout
22155
22156 \begin_layout Standard
22157
22158 Note however that you must enable the LyX server to get this feature working
22159  (it is disabled by default).
22160  You can enable it in 
22161 \family sans
22162 Preferences
22163 \family default
22164  (tabs 
22165 \family sans
22166 Inputs
22167 \family default
22168
22169 \family sans
22170 Paths
22171 \family default
22172 ) by entering in the 
22173 \family sans
22174 LyXserver pipe
22175 \family default
22176  a path like 
22177 \begin_inset Quotes eld
22178 \end_inset
22179
22180
22181 \family typewriter
22182 /home/<your-home-directory>/.lyx/lyxpipe
22183 \family default
22184
22185 \begin_inset Quotes erd
22186 \end_inset
22187
22188
22189 \end_layout
22190
22191 \begin_layout Standard
22192
22193 Read the LyX server documentation in the 
22194 \emph on
22195 Customization Manual
22196 \emph default
22197  for further information.
22198 \end_layout
22199
22200 \begin_layout Subsubsection
22201
22202 Toolbar extensions
22203 \end_layout
22204
22205 \begin_layout Standard
22206
22207 There are six new buttons that can be added to your LyX toolbar.
22208  Five of these buttons are short cuts to layout styles: 
22209 \family sans
22210 Standard
22211 \family default
22212
22213 \family sans
22214 Section
22215 \family default
22216
22217 \family sans
22218 LaTeX
22219 \family default
22220
22221 \family sans
22222 LyX-Code
22223 \family default
22224 , and 
22225 \family sans
22226 Scrap
22227 \family default
22228 .
22229  The last one is a short cut to the 
22230 \begin_inset Quotes eld
22231 \end_inset
22232
22233 Build Program
22234 \begin_inset Quotes erd
22235 \end_inset
22236
22237  File menu entry.
22238  
22239 \end_layout
22240
22241 \begin_layout Standard
22242
22243 LyX has a range of buttons that are available for tool bar customization.
22244  In my toolbar I like to combine the six short cuts above with two more:
22245  One for 
22246 \family sans
22247 \bar under
22248 V
22249 \bar default
22250 iew
22251 \family default
22252 \SpecialChar \menuseparator
22253
22254 \family sans
22255 \bar under
22256 U
22257 \bar default
22258 pdate
22259 \family default
22260 \SpecialChar \menuseparator
22261
22262 \family sans
22263 \bar under
22264 D
22265 \bar default
22266 VI
22267 \family default
22268  and the other for 
22269 \family sans
22270 \bar under
22271 V
22272 \bar default
22273 iew\SpecialChar \menuseparator
22274
22275 \bar under
22276 D
22277 \bar default
22278 VI
22279 \family default
22280  File menu entries.
22281  Here is how it looks like:
22282 \end_layout
22283
22284 \begin_layout LyX-Code
22285
22286 Toolbar
22287 \end_layout
22288
22289 \begin_layout LyX-Code
22290
22291   Layouts
22292 \end_layout
22293
22294 \begin_layout LyX-Code
22295
22296   Icon "layout Standard"
22297 \end_layout
22298
22299 \begin_layout LyX-Code
22300
22301   Icon "layout Section"
22302 \end_layout
22303
22304 \begin_layout LyX-Code
22305
22306   Icon "layout LaTeX"
22307 \end_layout
22308
22309 \begin_layout LyX-Code
22310
22311   Icon "layout LyX-Code"
22312 \end_layout
22313
22314 \begin_layout LyX-Code
22315
22316   Icon "layout Scrap"
22317 \end_layout
22318
22319 \begin_layout LyX-Code
22320
22321   Separator
22322 \end_layout
22323
22324 \begin_layout LyX-Code
22325
22326   Icon "buffer-view"
22327 \end_layout
22328
22329 \begin_layout LyX-Code
22330
22331   Icon "buffer-typeset"
22332 \end_layout
22333
22334 \begin_layout LyX-Code
22335
22336   Icon "build-program"
22337 \end_layout
22338
22339 \begin_layout LyX-Code
22340
22341   Separator
22342 \end_layout
22343
22344 \begin_layout LyX-Code
22345
22346 .
22347 \end_layout
22348
22349 \begin_layout LyX-Code
22350
22351 .
22352 \end_layout
22353
22354 \begin_layout LyX-Code
22355
22356 .
22357 \end_layout
22358
22359 \begin_layout LyX-Code
22360
22361 End
22362 \end_layout
22363
22364 \begin_layout Subsubsection
22365
22366 Colors customization
22367 \end_layout
22368
22369 \begin_layout Standard
22370
22371 There are a number of colors in LyX that can be customized in 
22372 \family sans
22373 Preferences
22374 \family default
22375 .
22376  One of the things that bothers people is the LaTeX font color.
22377  The default color is red, since the scraps uses LaTeX font, and there is
22378  a lot of scraps in literate documents, you may get tired of seeing everything
22379  in red.
22380  You can change it by going to the tabs 
22381 \family sans
22382 Look&Feel
22383 \family default
22384
22385 \family sans
22386 Colors.
22387 \end_layout
22388
22389 \begin_layout Standard
22390
22391 The next thing is the visible presence of the newline character in the screen.
22392  You can choose the color of this particular character and make it blend
22393  in the background.
22394  I recommend you choosing a color that is close to the background but not
22395  equal, that way you still can see it is there, but it is not bothering
22396  you anymore.
22397  
22398 \end_layout
22399
22400 \begin_layout Chapter
22401
22402 Secrets of the LaTeX Masters
22403 \begin_inset LatexCommand \label{cha:secrets}
22404
22405 \end_inset
22406
22407
22408 \end_layout
22409
22410 \begin_layout Standard
22411
22412 Though LyX is a powerful tool, it cannot hope to support everything that
22413  can be done with pure TeX/LaTeX.
22414  However, many familiar dirty TeX and LaTeX tricks can be done within LyX,
22415  as long as you are not afraid to use that 
22416 \begin_inset Quotes eld
22417 \end_inset
22418
22419 TeX
22420 \begin_inset Quotes erd
22421 \end_inset
22422
22423  button on the toolbar or add things to the LaTeX preamble.
22424  This section lists some tips, tricks, and otherwise cool ideas to give
22425  your document that extra little flair.
22426  
22427 \emph on
22428 Do try this at home
22429 \emph default
22430 , just start with something a little smaller and less important than your
22431  dissertation!
22432 \end_layout
22433
22434 \begin_layout Standard
22435
22436 Most ideas in this section require less common files in your LaTeX installation.
22437  If you have a system like teTeX, most will already be available.
22438  A few, however, will need to be downloaded from one of the CTAN archives.
22439  Often, there are several ways to do something, or several LaTeX style files
22440  which do the same thing.
22441  We do not endorse one choice over another, we simply claim that we have
22442  done a particular task with a particular file.
22443  Put on your wizard hat, keep an eye out for dragons, and let us begin.
22444 \end_layout
22445
22446 \begin_layout Section
22447
22448 Tricks for Footnotes and Margin Notes
22449 \end_layout
22450
22451 \begin_layout Standard
22452
22453 suggested by 
22454 \noun on
22455 Robin Socha
22456 \end_layout
22457
22458 \begin_layout Subsection
22459
22460 Footnotes 
22461 \end_layout
22462
22463 \begin_layout Standard
22464
22465 LyX cannot yet take care of setting the footnote numbering back to 1 after
22466  each section in the 
22467 \begin_inset Quotes eld
22468 \end_inset
22469
22470
22471 \family sans
22472 article
22473 \family default
22474
22475 \begin_inset Quotes erd
22476 \end_inset
22477
22478
22479 \family roman
22480  document class or changing the counter style.
22481  You'll need to insert LaTeX commands like the following to achieve that:
22482 \end_layout
22483
22484 \begin_layout Standard
22485
22486
22487 \begin_inset ERT
22488 status inlined
22489
22490 \begin_layout Standard
22491
22492 \backslash
22493 setcounter{footnote}{0}
22494 \end_layout
22495
22496 \end_inset
22497
22498  Using 
22499 \family typewriter
22500
22501 \backslash
22502 setcounter{footnote}{0}
22503 \family roman
22504  will set the counter back to 1
22505 \begin_inset Foot
22506 status collapsed
22507
22508 \begin_layout Standard
22509
22510 The counter has been set back to 1.
22511 \end_layout
22512
22513 \end_inset
22514
22515 .
22516 \end_layout
22517
22518 \begin_layout Standard
22519
22520 The following command will change the numbering to small letters.
22521  Take a look at the next footnote in your xdvi or ghostview 
22522 \begin_inset ERT
22523 status inlined
22524
22525 \begin_layout Standard
22526
22527 \backslash
22528 renewcommand{
22529 \backslash
22530 thefootnote}{
22531 \backslash
22532 alph{footnote}}
22533 \end_layout
22534
22535 \end_inset
22536
22537 :
22538 \begin_inset Foot
22539 status collapsed
22540
22541 \begin_layout Standard
22542
22543 This is an example for a footnote with alphabetic numbering.
22544 \newline
22545 Use
22546 \family typewriter
22547  
22548 \backslash
22549 renewcommand{
22550 \backslash
22551 thefootnote {
22552 \backslash
22553 alph{footnote}} 
22554 \family roman
22555 to get this.
22556 \end_layout
22557
22558 \end_inset
22559
22560
22561 \end_layout
22562
22563 \begin_layout Standard
22564
22565 The next command sets the counter style back to default, i.e.
22566  
22567 \family typewriter
22568
22569 \backslash
22570 arabic
22571 \family default
22572
22573 \begin_inset Foot
22574 status collapsed
22575
22576 \begin_layout Standard
22577
22578 Use
22579 \family typewriter
22580  
22581 \backslash
22582 renewcommand{
22583 \backslash
22584 thefootnote}{
22585 \backslash
22586 arabic{footnote}}
22587 \family roman
22588  to set the counter--style back to LyX's default, i.e.
22589  
22590 \backslash
22591 arabic.
22592 \family default
22593
22594 \begin_inset ERT
22595 status collapsed
22596
22597 \begin_layout Standard
22598
22599 \backslash
22600 renewcommand {
22601 \backslash
22602 thefootnote} {
22603 \backslash
22604 arabic{footnote}}
22605 \end_layout
22606
22607 \end_inset
22608
22609
22610 \end_layout
22611
22612 \end_inset
22613
22614 .
22615 \end_layout
22616
22617 \begin_layout Standard
22618
22619 You can use 
22620 \family typewriter
22621
22622 \backslash
22623 arabic
22624 \family default
22625
22626 \family typewriter
22627
22628 \backslash
22629 roman
22630 \family default
22631
22632 \family typewriter
22633
22634 \backslash
22635 Roman
22636 \family default
22637
22638 \family typewriter
22639
22640 \backslash
22641 alph
22642 \family default
22643  or 
22644 \family typewriter
22645
22646 \backslash
22647 Alph
22648 \family default
22649  and others as counter styles.
22650  Just replace the LaTeX command in the above example and rerun TeX to see
22651  what those styles can do.
22652  
22653 \end_layout
22654
22655 \begin_layout Subsection
22656
22657 Margin Notes
22658 \end_layout
22659
22660 \begin_layout Standard
22661
22662 Here are two examples of neat things you can do to margin notes using LaTeX
22663  commands.
22664 \end_layout
22665
22666 \begin_layout Standard
22667
22668 The following command will make a vertical line appear alongside your text---gre
22669 at for 
22670 \begin_inset Quotes eld
22671 \end_inset
22672
22673 thumbing
22674 \begin_inset Quotes erd
22675 \end_inset
22676
22677
22678 \family typewriter
22679
22680 \backslash
22681 marginpar{
22682 \backslash
22683 rule[-10mm]{30mm}{5mm}}
22684 \family roman
22685 .
22686 \family default
22687
22688 \begin_inset ERT
22689 status inlined
22690
22691 \begin_layout Standard
22692
22693 \backslash
22694 marginpar{
22695 \backslash
22696 rule[-10mm]{30mm}{5mm}}
22697 \end_layout
22698
22699 \end_inset
22700
22701
22702 \end_layout
22703
22704 \begin_layout Standard
22705
22706 Check your dvi- or ghostview-output to see what the 
22707 \family typewriter
22708
22709 \backslash
22710 reversemarginpar 
22711 \family default
22712 command does to the following margin note.
22713 \end_layout
22714
22715 \begin_layout Standard
22716
22717
22718 \begin_inset ERT
22719 status inlined
22720
22721 \begin_layout Standard
22722
22723 \backslash
22724 reversemarginpar
22725 \end_layout
22726
22727 \end_inset
22728
22729
22730 \begin_inset Marginal
22731 status collapsed
22732
22733 \begin_layout Standard
22734
22735 This is a 
22736 \newline
22737 margin note.
22738 \end_layout
22739
22740 \end_inset
22741
22742
22743 \end_layout
22744
22745 \begin_layout Section
22746
22747 Multiple Columns
22748 \end_layout
22749
22750 \begin_layout Standard
22751
22752 by 
22753 \noun on
22754 Lars Gullik Bjønnes
22755 \end_layout
22756
22757 \begin_layout Subsection
22758
22759 Purpose
22760 \end_layout
22761
22762 \begin_layout Standard
22763
22764 The aim for this chapter
22765 \begin_inset Foot
22766 status collapsed
22767
22768 \begin_layout Standard
22769
22770 Editor's note: Lars' original chapter was a masterful description of how
22771  to use the 
22772 \family typewriter
22773 multicol
22774 \family default
22775  package.
22776  However, it was too long to flow smoothly in this document.
22777  I have therefore chosen to excerpt the most important sections here (sorry,
22778  Lars); you can read the original chapter (and more of the story!) in the
22779  example file 
22780 \family typewriter
22781 examples/multicol.lyx
22782 \family default
22783 .
22784  --- mer
22785 \end_layout
22786
22787 \end_inset
22788
22789  is to show how the LaTeX package 
22790 \family typewriter
22791 multicol
22792 \family default
22793  can be used in a LyX document.
22794  As LyX doesn't support the 
22795 \family typewriter
22796 multicol
22797 \family default
22798  package natively yet, we have to use some small hacks.
22799  By reading this section it should be obvious how to do this.
22800 \end_layout
22801
22802 \begin_layout Subsection
22803
22804 Limitations 
22805 \end_layout
22806
22807 \begin_layout Standard
22808
22809 The 
22810 \family typewriter
22811 multicol
22812 \family default
22813  package allows switching between one and multicolumn format on the same
22814  page.
22815  Footnotes are handled correctly (for the most part), but will be placed
22816  at the bottom of the page and not under each column.
22817  LaTeX's float mechanism, however, is partly disabled in the current implementat
22818 ion.
22819  At the moment only page-wide floats can be used within the scope of the
22820  environment.
22821 \end_layout
22822
22823 \begin_layout Subsection
22824
22825 Examples
22826 \end_layout
22827
22828 \begin_layout Subsubsection
22829
22830 Two columns
22831 \end_layout
22832
22833 \begin_layout Standard
22834
22835 If you want to have two columns in your text, you have use LaTeX mode to
22836  insert 
22837 \family typewriter
22838
22839 \backslash
22840 begin{multicols}{2}
22841 \family default
22842  at the point where you want the two column layout to start, and then 
22843 \family typewriter
22844
22845 \backslash
22846 end{multicols}
22847 \family default
22848  where you want it to end.
22849  Like this:
22850 \end_layout
22851
22852 \begin_layout Standard
22853
22854
22855 \begin_inset ERT
22856 status inlined
22857
22858 \begin_layout Standard
22859
22860 \backslash
22861 begin{multicols}{2}
22862 \end_layout
22863
22864 \end_inset
22865
22866
22867 \end_layout
22868
22869 \begin_layout Standard
22870 \noindent
22871
22872 \series bold
22873 \size small
22874 The Adventure of the Empty House
22875 \series default
22876
22877 \newline
22878 by 
22879 \noun on
22880 Sir Arthur Conan Doyle
22881 \end_layout
22882
22883 \begin_layout Standard
22884
22885
22886 \size small
22887 It was in the spring of the year 1894 that all London was interested, and
22888  the fashionable world dismayed, by the murder of the Honourable Ronald
22889  Adair under most unusual and inexplicable circumstances.
22890  The public has already learned those particulars of the crime which came
22891  out in the police investigation, but a good deal was suppressed upon that
22892  occasion, since the case for the prosecution was so overwhelmingly strong
22893  that it was not necessary to bring forward all the facts.
22894  Only now, at the end of nearly ten years, am I allowed to supply those
22895  missing links which make up the whole of that remarkable chain.
22896  The crime was of interest in itself, but that interest was as nothing to
22897  me compared to the inconceivable sequel, which afforded me the greatest
22898  shock and surprise of any event in my adventurous life.
22899  Even now, after this long interval, I find myself thrilling as I think
22900  of it, and feeling once more that sudden flood of joy, amazement, and increduli
22901 ty which utterly submerged my mind.
22902  Let me say to that public, which has shown some interest in those glimpses
22903  which I have occasionally given them of the thoughts and actions of a very
22904  remarkable man, that they are not to blame me if I have not shared my knowledge
22905  with them, for I should have considered it my first duty to do so, had
22906  I not been barred by a positive prohibition from his own lips, which was
22907  only withdrawn upon the third of last month.
22908 \end_layout
22909
22910 \begin_layout Standard
22911
22912
22913 \begin_inset ERT
22914 status inlined
22915
22916 \begin_layout Standard
22917
22918 \backslash
22919 end{multicols}
22920 \end_layout
22921
22922 \end_inset
22923
22924
22925 \end_layout
22926
22927 \begin_layout Subsubsection
22928
22929 Multiple columns
22930 \end_layout
22931
22932 \begin_layout Standard
22933
22934 The same pattern is used when you want more than two columns:
22935 \end_layout
22936
22937 \begin_layout Standard
22938
22939
22940 \begin_inset ERT
22941 status inlined
22942
22943 \begin_layout Standard
22944
22945 \backslash
22946 begin{multicols}{3}
22947 \end_layout
22948
22949 \end_inset
22950
22951
22952 \end_layout
22953
22954 \begin_layout Standard
22955
22956
22957 \size footnotesize
22958 It can be imagined that my close intimacy with Sherlock Holmes had interested
22959  me deeply in crime, and that after his disappearance I never failed to
22960  read with care the various problems which came before the public.
22961  And I even attempted, more than once, for my own private satisfaction,
22962  to employ his methods in their solution, though with indifferent success.
22963  There was none, however, which appealed to me like this tragedy of Ronald
22964  Adair.
22965  As I read the evidence at the inquest, which led up to a verdict of willful
22966  murder against some person or persons unknown, I realized more clearly
22967  than I had ever done the loss which the community had sustained by the
22968  death of Sherlock Holmes.
22969  There were points about this strange business which would, I was sure,
22970  have specially appealed to him, and the efforts of the police would have
22971  been supplemented, or more probably anticipated, by the trained observation
22972  and the alert mind of the first criminal agent in Europe.
22973  All day, as I drove upon my round, I turned over the case in my mind and
22974  found no explanation which appeared to me to be adequate.
22975  At the risk of telling a twice-told tale, I will recapitulate the facts
22976  as they were known to the public at the conclusion of the inquest.
22977 \end_layout
22978
22979 \begin_layout Standard
22980
22981
22982 \begin_inset ERT
22983 status inlined
22984
22985 \begin_layout Standard
22986
22987 \backslash
22988 end{multicols}
22989 \end_layout
22990
22991 \end_inset
22992
22993
22994 \end_layout
22995
22996 \begin_layout Standard
22997
22998 You can have have more than 3 columns if you want to, but that might not
22999  be very pleasant for the eye.
23000 \end_layout
23001
23002 \begin_layout Subsubsection
23003
23004 Columns inside columns
23005 \end_layout
23006
23007 \begin_layout Standard
23008
23009 You can even have columns inside columns:
23010 \end_layout
23011
23012 \begin_layout Standard
23013
23014
23015 \begin_inset ERT
23016 status inlined
23017
23018 \begin_layout Standard
23019
23020 \backslash
23021 begin{multicols}{2}
23022 \end_layout
23023
23024 \end_inset
23025
23026
23027 \end_layout
23028
23029 \begin_layout Standard
23030
23031
23032 \size footnotesize
23033 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
23034  at that time governor of one of the Australian colonies.
23035  Adair's mother had returned from Australia to undergo the operation for
23036  cataract, and she, her son Ronald, and her daughter Hilda were living together
23037  at 427 Park Lane.
23038 \end_layout
23039
23040 \begin_layout Standard
23041
23042
23043 \begin_inset ERT
23044 status inlined
23045
23046 \begin_layout Standard
23047
23048 \backslash
23049 begin{multicols}{2}
23050 \end_layout
23051
23052 \end_inset
23053
23054
23055 \end_layout
23056
23057 \begin_layout Standard
23058
23059
23060 \size footnotesize
23061 The youth moved in the best society--had, so far as was known, no enemies
23062  and no particular vices.
23063  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
23064  had been broken off by mutual consent some months before, and there was
23065  no sign that it had left any very profound feeling behind it.
23066  For the rest {sic} the man's life moved in a narrow and conventional circle,
23067  for his habits were quiet and his nature unemotional.
23068  Yet it was upon this easy-going young aristocrat that death came, in most
23069  strange and unexpected form, between the hours of ten and eleven-twenty
23070  on the night of March 30, 1894.
23071 \end_layout
23072
23073 \begin_layout Standard
23074
23075
23076 \begin_inset ERT
23077 status inlined
23078
23079 \begin_layout Standard
23080
23081 \backslash
23082 end{multicols}
23083 \end_layout
23084
23085 \end_inset
23086
23087
23088 \end_layout
23089
23090 \begin_layout Standard
23091
23092
23093 \size footnotesize
23094 Ronald Adair was fond of cards--playing continually, but never for such
23095  stakes as would hurt him.
23096  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
23097  It was shown that, after dinner on the day of his death, he had played
23098  a rubber of whist at the latter club.
23099  He had also played there in the afternoon.
23100
23101 \size default
23102  
23103 \size footnotesize
23104 The evidence of those who had played with him-- Mr.
23105  Murray, Sir John Hardy, and Colonel Moran--showed that the game was whist,
23106  and that there was a fairly equal fall of the cards.
23107  Adair might have lost five pounds, but not more.
23108  His fortune was a considerable one, and such a loss could not in any way
23109  affect him.
23110  He had played nearly every day at one club or other, but he was a cautious
23111  player, and usually rose a winner.
23112  It came out in evidence that, in partnership with Colonel Moran, he had
23113  actually won as much as four hundred and twenty pounds in a sitting, some
23114  weeks before, from Godfrey Milner and Lord Balmoral.
23115  So much for his recent history as it came out at the inquest.
23116 \end_layout
23117
23118 \begin_layout Standard
23119
23120
23121 \begin_inset ERT
23122 status inlined
23123
23124 \begin_layout Standard
23125
23126 \backslash
23127 end{multicols}
23128 \end_layout
23129
23130 \end_inset
23131
23132
23133 \end_layout
23134
23135 \begin_layout Standard
23136
23137 Please do read the file 
23138 \family typewriter
23139 examples/multicol.lyx
23140 \family default
23141  for more advanced examples including column and header spacing, vertical
23142  separator lines, and more.
23143 \end_layout
23144
23145 \begin_layout Section
23146
23147 Numbering in the 
23148 \family sans
23149 Enumerate
23150 \family default
23151  Paragraph Environment
23152 \begin_inset OptArg
23153 status collapsed
23154
23155 \begin_layout Standard
23156
23157 Numbering in Enumerate
23158 \end_layout
23159
23160 \end_inset
23161
23162
23163 \end_layout
23164
23165 \begin_layout Standard
23166
23167 by 
23168 \noun on
23169 John Weiss
23170 \end_layout
23171
23172 \begin_layout Standard
23173
23174
23175 \begin_inset VSpace bigskip
23176 \end_inset
23177
23178
23179 \end_layout
23180
23181
23182 \begin_layout Standard
23183 \noindent
23184 The default numbering for the 
23185 \family sans
23186 Enumerate
23187 \family default
23188  paragraph environment begins with Arabic numbers and ends with uppercase
23189  letters.
23190  Suppose, however, you wanted a different type of numbering scheme.
23191  Here's a quickie example of how to change the numbering scheme:
23192 \end_layout
23193
23194 \begin_layout LyX-Code
23195
23196
23197 \backslash
23198 renewcommand{
23199 \backslash
23200 labelenumi}{
23201 \backslash
23202 Roman{enumi}.}
23203 \end_layout
23204
23205 \begin_layout LyX-Code
23206
23207
23208 \backslash
23209 renewcommand{
23210 \backslash
23211 labelenumii}{
23212 \backslash
23213 Alph{enumii}.}
23214 \end_layout
23215
23216 \begin_layout LyX-Code
23217
23218
23219 \backslash
23220 renewcommand{
23221 \backslash
23222 labelenumiii}{
23223 \backslash
23224 arabic{enumiii}.}
23225 \end_layout
23226
23227 \begin_layout LyX-Code
23228
23229
23230 \backslash
23231 renewcommand{
23232 \backslash
23233 labelenumiv}{
23234 \backslash
23235 alph{enumiv}.)}
23236 \end_layout
23237
23238 \begin_layout Standard
23239
23240 \SpecialChar \ldots{}
23241  which changes the numbering scheme to uppercase Roman numerals, uppercase
23242  letters, Arabic numbers, and lowercase letter.
23243 \end_layout
23244
23245 \begin_layout Standard
23246
23247 Additionally, the previous example also adds a little bit extra to the numbering
23248  scheme.
23249  For example, the first level label actually looks like: 
23250 \begin_inset Quotes eld
23251 \end_inset
23252
23253 I.
23254 \begin_inset Quotes erd
23255 \end_inset
23256
23257 .
23258  For ease of reading, we'll describe what the numbering schemes look like
23259  using a notation something like this: <
23260 \begin_inset Quotes eld
23261 \end_inset
23262
23263 I.
23264 \begin_inset Quotes erd
23265 \end_inset
23266
23267 ,\InsetSpace ~
23268
23269 \begin_inset Quotes erd
23270 \end_inset
23271
23272 A.
23273 \begin_inset Quotes erd
23274 \end_inset
23275
23276 ,\InsetSpace ~
23277
23278 \begin_inset Quotes erd
23279 \end_inset
23280
23281 1.
23282 \begin_inset Quotes erd
23283 \end_inset
23284
23285 ,\InsetSpace ~
23286
23287 \begin_inset Quotes eld
23288 \end_inset
23289
23290 a.)
23291 \begin_inset Quotes erd
23292 \end_inset
23293
23294 >.
23295  
23296 \end_layout
23297
23298 \begin_layout Standard
23299
23300 As you can see in the example, there is a label command for each nesting
23301  level, 
23302 \family typewriter
23303
23304 \backslash
23305 labelenumi
23306 \family default
23307  \SpecialChar \ldots{}
23308  
23309 \family typewriter
23310
23311 \backslash
23312 labelenumiv
23313 \family default
23314 , as well as a counter, 
23315 \family typewriter
23316 enumi
23317 \family default
23318  \SpecialChar \ldots{}
23319  
23320 \family typewriter
23321 enumiv
23322 \family default
23323 .
23324  There are also five 
23325 \begin_inset Quotes eld
23326 \end_inset
23327
23328 number printing
23329 \begin_inset Quotes erd
23330 \end_inset
23331
23332  commands, 
23333 \family typewriter
23334
23335 \backslash
23336 arabic{}
23337 \family default
23338
23339 \family typewriter
23340
23341 \backslash
23342 roman{}
23343 \family default
23344
23345 \family typewriter
23346
23347 \backslash
23348 Roman{}
23349 \family default
23350
23351 \family typewriter
23352
23353 \backslash
23354 alph{}
23355 \family default
23356 , and 
23357 \family typewriter
23358
23359 \backslash
23360 Alph{}
23361 \family default
23362 , each of which take one counter as an argument.
23363  You can add characters before or after these, but there's no need to add
23364  spaces.
23365 \end_layout
23366
23367 \begin_layout Standard
23368
23369 You can get really fancy with these.
23370  For example:
23371 \end_layout
23372
23373 \begin_layout LyX-Code
23374
23375
23376 \backslash
23377 renewcommand{
23378 \backslash
23379 labelenumi}{
23380 \backslash
23381 #
23382 \backslash
23383 Alph{enumi}
23384 \backslash
23385 #}
23386 \end_layout
23387
23388 \begin_layout LyX-Code
23389
23390
23391 \backslash
23392 renewcommand{
23393 \backslash
23394 labelenumii}{
23395 \backslash
23396 Alph{enumi}.
23397 \backslash
23398 arabic{enumii}}
23399 \end_layout
23400
23401 \begin_layout LyX-Code
23402
23403
23404 \backslash
23405 renewcommand{
23406 \backslash
23407 labelenumiii}{
23408 \backslash
23409 alph{enumiii}+}
23410 \end_layout
23411
23412 \begin_layout LyX-Code
23413
23414
23415 \backslash
23416 renewcommand{
23417 \backslash
23418 labelenumiv}{(
23419 \backslash
23420 roman{enumiv})}
23421 \end_layout
23422
23423 \begin_layout Standard
23424
23425 produces the somewhat out of hand numbering scheme: <
23426 \begin_inset Quotes eld
23427 \end_inset
23428
23429 #A#
23430 \begin_inset Quotes erd
23431 \end_inset
23432
23433 ,\InsetSpace ~
23434
23435 \begin_inset Quotes erd
23436 \end_inset
23437
23438 A.1
23439 \begin_inset Quotes erd
23440 \end_inset
23441
23442 ,\InsetSpace ~
23443
23444 \begin_inset Quotes erd
23445 \end_inset
23446
23447 a+
23448 \begin_inset Quotes erd
23449 \end_inset
23450
23451 ,\InsetSpace ~
23452
23453 \begin_inset Quotes eld
23454 \end_inset
23455
23456 (i)
23457 \begin_inset Quotes erd
23458 \end_inset
23459
23460 >.
23461  
23462 \end_layout
23463
23464 \begin_layout Section
23465
23466 Extra Space Between Table Rows
23467 \end_layout
23468
23469 \begin_layout Standard
23470
23471 by 
23472 \noun on
23473 Mike Ressler
23474 \end_layout
23475
23476 \begin_layout Standard
23477
23478
23479 \begin_inset VSpace bigskip
23480 \end_inset
23481
23482
23483 \end_layout
23484
23485
23486 \begin_layout Standard
23487 \noindent
23488 LaTeX allows you to put a bit of extra space between rows in a table by
23489  giving an optional argument to the end-of-row specifier (
23490 \family typewriter
23491
23492 \backslash
23493
23494 \backslash
23495
23496 \family default
23497 ).
23498  LyX has not yet implemented this in a formal way, so here are two dirty
23499  little tricks to do the same job.
23500  
23501 \end_layout
23502
23503 \begin_layout Standard
23504
23505 The first is the more formal, but longwinded way to do it.
23506  In the LaTeX preamble, add the following command definition: 
23507 \end_layout
23508
23509 \begin_layout Standard
23510
23511
23512 \family typewriter
23513
23514 \backslash
23515 newcommand{
23516 \backslash
23517 extratablespace}[1]{
23518 \backslash
23519 noalign{vskip#1}}
23520 \family default
23521  This command takes a single argument---the amount of space you would like
23522  to insert.
23523  Insert the command in the first column of the row 
23524 \emph on
23525 after
23526 \emph default
23527  where you would like the space to appear.
23528  Here is an example (I've removed all the borders using 
23529 \family sans
23530 \bar under
23531 L
23532 \bar default
23533 ayout\SpecialChar \menuseparator
23534 Tabl
23535 \bar under
23536 e
23537 \family default
23538 \bar default
23539 ):
23540 \end_layout
23541
23542 \begin_layout Standard
23543 \align center
23544
23545 \begin_inset  Tabular
23546 <lyxtabular version="3" rows="4" columns="3">
23547 <features>
23548 <column alignment="center" valignment="top" width="0pt">
23549 <column alignment="center" valignment="top" width="0pt">
23550 <column alignment="center" valignment="top" width="0pt">
23551 <row>
23552 <cell alignment="center" valignment="top" topline="true" usebox="none">
23553 \begin_inset Text
23554
23555 \begin_layout Standard
23556
23557
23558 \family roman
23559 \series medium
23560 \shape up
23561 \size normal
23562 \emph off
23563 \bar no
23564 \noun off
23565 \color none
23566 Minerals
23567 \end_layout
23568
23569 \end_inset
23570 </cell>
23571 <cell alignment="center" valignment="top" topline="true" usebox="none">
23572 \begin_inset Text
23573
23574 \begin_layout Standard
23575
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 Calcite
23586 \end_layout
23587
23588 \end_inset
23589 </cell>
23590 <cell alignment="center" valignment="top" topline="true" usebox="none">
23591 \begin_inset Text
23592
23593 \begin_layout Standard
23594
23595
23596 \family roman
23597 \series medium
23598 \shape up
23599 \size normal
23600 \emph off
23601 \bar no
23602 \noun off
23603 \color none
23604 Dolomite
23605 \end_layout
23606
23607 \end_inset
23608 </cell>
23609 </row>
23610 <row>
23611 <cell alignment="center" valignment="top" topline="true" usebox="none">
23612 \begin_inset Text
23613
23614 \begin_layout Standard
23615
23616 \end_layout
23617
23618 \end_inset
23619 </cell>
23620 <cell alignment="center" valignment="top" topline="true" usebox="none">
23621 \begin_inset Text
23622
23623 \begin_layout Standard
23624
23625
23626 \family roman
23627 \series medium
23628 \shape up
23629 \size normal
23630 \emph off
23631 \bar no
23632 \noun off
23633 \color none
23634 Quartz
23635 \end_layout
23636
23637 \end_inset
23638 </cell>
23639 <cell alignment="center" valignment="top" topline="true" usebox="none">
23640 \begin_inset Text
23641
23642 \begin_layout Standard
23643
23644
23645 \family roman
23646 \series medium
23647 \shape up
23648 \size normal
23649 \emph off
23650 \bar no
23651 \noun off
23652 \color none
23653 Graphite
23654 \end_layout
23655
23656 \end_inset
23657 </cell>
23658 </row>
23659 <row>
23660 <cell alignment="center" valignment="top" topline="true" usebox="none">
23661 \begin_inset Text
23662
23663 \begin_layout Standard
23664
23665
23666 \family roman
23667 \series medium
23668 \shape up
23669 \size normal
23670 \emph off
23671 \bar no
23672 \noun off
23673 \color none
23674
23675 \begin_inset ERT
23676 status collapsed
23677
23678 \begin_layout Standard
23679
23680 \backslash
23681 extratablespace{2ex}
23682 \end_layout
23683
23684 \end_inset
23685
23686 Rocks
23687 \end_layout
23688
23689 \end_inset
23690 </cell>
23691 <cell alignment="center" valignment="top" topline="true" usebox="none">
23692 \begin_inset Text
23693
23694 \begin_layout Standard
23695
23696
23697 \family roman
23698 \series medium
23699 \shape up
23700 \size normal
23701 \emph off
23702 \bar no
23703 \noun off
23704 \color none
23705 Limestone
23706 \end_layout
23707
23708 \end_inset
23709 </cell>
23710 <cell alignment="center" valignment="top" topline="true" usebox="none">
23711 \begin_inset Text
23712
23713 \begin_layout Standard
23714
23715
23716 \family roman
23717 \series medium
23718 \shape up
23719 \size normal
23720 \emph off
23721 \bar no
23722 \noun off
23723 \color none
23724 Sandstone
23725 \end_layout
23726
23727 \end_inset
23728 </cell>
23729 </row>
23730 <row>
23731 <cell alignment="center" valignment="top" topline="true" usebox="none">
23732 \begin_inset Text
23733
23734 \begin_layout Standard
23735
23736 \end_layout
23737
23738 \end_inset
23739 </cell>
23740 <cell alignment="center" valignment="top" topline="true" usebox="none">
23741 \begin_inset Text
23742
23743 \begin_layout Standard
23744
23745
23746 \family roman
23747 \series medium
23748 \shape up
23749 \size normal
23750 \emph off
23751 \bar no
23752 \noun off
23753 \color none
23754 Granite
23755 \end_layout
23756
23757 \end_inset
23758 </cell>
23759 <cell alignment="center" valignment="top" topline="true" usebox="none">
23760 \begin_inset Text
23761
23762 \begin_layout Standard
23763
23764
23765 \family roman
23766 \series medium
23767 \shape up
23768 \size normal
23769 \emph off
23770 \bar no
23771 \noun off
23772 \color none
23773 Andesite
23774 \end_layout
23775
23776 \end_inset
23777 </cell>
23778 </row>
23779 </lyxtabular>
23780
23781 \end_inset
23782
23783
23784 \end_layout
23785
23786 \begin_layout Standard
23787
23788 The second method is faster, but will make typographers and TeXperts all
23789  over the world groan.
23790  Simply put an end of row specifier with optional argument at the same spot.
23791  No fancy definitions are needed as in the above example, but there will
23792  be more space inserted than you specified because you essentially added
23793  a blank row plus the extra space.
23794  If the space added is too much, simply use a negative number, like so:
23795 \end_layout
23796
23797 \begin_layout Standard
23798 \align center
23799
23800 \begin_inset  Tabular
23801 <lyxtabular version="3" rows="4" columns="3">
23802 <features>
23803 <column alignment="center" valignment="top" width="0pt">
23804 <column alignment="center" valignment="top" width="0pt">
23805 <column alignment="center" valignment="top" width="0pt">
23806 <row>
23807 <cell alignment="center" valignment="top" topline="true" usebox="none">
23808 \begin_inset Text
23809
23810 \begin_layout Standard
23811
23812
23813 \family roman
23814 \series medium
23815 \shape up
23816 \size normal
23817 \emph off
23818 \bar no
23819 \noun off
23820 \color none
23821 Minerals
23822 \end_layout
23823
23824 \end_inset
23825 </cell>
23826 <cell alignment="center" valignment="top" topline="true" usebox="none">
23827 \begin_inset Text
23828
23829 \begin_layout Standard
23830
23831
23832 \family roman
23833 \series medium
23834 \shape up
23835 \size normal
23836 \emph off
23837 \bar no
23838 \noun off
23839 \color none
23840 Calcite
23841 \end_layout
23842
23843 \end_inset
23844 </cell>
23845 <cell alignment="center" valignment="top" topline="true" usebox="none">
23846 \begin_inset Text
23847
23848 \begin_layout Standard
23849
23850
23851 \family roman
23852 \series medium
23853 \shape up
23854 \size normal
23855 \emph off
23856 \bar no
23857 \noun off
23858 \color none
23859 Dolomite
23860 \end_layout
23861
23862 \end_inset
23863 </cell>
23864 </row>
23865 <row>
23866 <cell alignment="center" valignment="top" topline="true" usebox="none">
23867 \begin_inset Text
23868
23869 \begin_layout Standard
23870
23871 \end_layout
23872
23873 \end_inset
23874 </cell>
23875 <cell alignment="center" valignment="top" topline="true" usebox="none">
23876 \begin_inset Text
23877
23878 \begin_layout Standard
23879
23880
23881 \family roman
23882 \series medium
23883 \shape up
23884 \size normal
23885 \emph off
23886 \bar no
23887 \noun off
23888 \color none
23889 Quartz
23890 \end_layout
23891
23892 \end_inset
23893 </cell>
23894 <cell alignment="center" valignment="top" topline="true" usebox="none">
23895 \begin_inset Text
23896
23897 \begin_layout Standard
23898
23899
23900 \family roman
23901 \series medium
23902 \shape up
23903 \size normal
23904 \emph off
23905 \bar no
23906 \noun off
23907 \color none
23908 Graphite
23909 \end_layout
23910
23911 \end_inset
23912 </cell>
23913 </row>
23914 <row>
23915 <cell alignment="center" valignment="top" topline="true" usebox="none">
23916 \begin_inset Text
23917
23918 \begin_layout Standard
23919
23920
23921 \family roman
23922 \series medium
23923 \shape up
23924 \size normal
23925 \emph off
23926 \bar no
23927 \noun off
23928 \color none
23929
23930 \begin_inset ERT
23931 status collapsed
23932
23933 \begin_layout Standard
23934
23935 \backslash
23936
23937 \backslash
23938 [-1ex]
23939 \end_layout
23940
23941 \end_inset
23942
23943  Rocks
23944 \end_layout
23945
23946 \end_inset
23947 </cell>
23948 <cell alignment="center" valignment="top" topline="true" usebox="none">
23949 \begin_inset Text
23950
23951 \begin_layout Standard
23952
23953
23954 \family roman
23955 \series medium
23956 \shape up
23957 \size normal
23958 \emph off
23959 \bar no
23960 \noun off
23961 \color none
23962 Limestone
23963 \end_layout
23964
23965 \end_inset
23966 </cell>
23967 <cell alignment="center" valignment="top" topline="true" usebox="none">
23968 \begin_inset Text
23969
23970 \begin_layout Standard
23971
23972
23973 \family roman
23974 \series medium
23975 \shape up
23976 \size normal
23977 \emph off
23978 \bar no
23979 \noun off
23980 \color none
23981 Sandstone
23982 \end_layout
23983
23984 \end_inset
23985 </cell>
23986 </row>
23987 <row>
23988 <cell alignment="center" valignment="top" topline="true" usebox="none">
23989 \begin_inset Text
23990
23991 \begin_layout Standard
23992
23993 \end_layout
23994
23995 \end_inset
23996 </cell>
23997 <cell alignment="center" valignment="top" topline="true" usebox="none">
23998 \begin_inset Text
23999
24000 \begin_layout Standard
24001
24002
24003 \family roman
24004 \series medium
24005 \shape up
24006 \size normal
24007 \emph off
24008 \bar no
24009 \noun off
24010 \color none
24011 Granite
24012 \end_layout
24013
24014 \end_inset
24015 </cell>
24016 <cell alignment="center" valignment="top" topline="true" usebox="none">
24017 \begin_inset Text
24018
24019 \begin_layout Standard
24020
24021
24022 \family roman
24023 \series medium
24024 \shape up
24025 \size normal
24026 \emph off
24027 \bar no
24028 \noun off
24029 \color none
24030 Andesite
24031 \end_layout
24032
24033 \end_inset
24034 </cell>
24035 </row>
24036 </lyxtabular>
24037
24038 \end_inset
24039
24040
24041 \end_layout
24042
24043 \begin_layout Standard
24044
24045 It's short, sweet, and gets the job done quickly, even if it is really ugly.
24046  You may put away the rotten vegetables now! I promise I won't suggest anything
24047  else like that!
24048 \end_layout
24049
24050 \begin_layout Section
24051
24052 Dropped Capitals
24053 \end_layout
24054
24055 \begin_layout Standard
24056
24057 by 
24058 \noun on
24059 Mike Ressler
24060 \end_layout
24061
24062 \begin_layout Standard
24063
24064
24065 \begin_inset VSpace bigskip
24066 \end_inset
24067
24068
24069 \end_layout
24070
24071
24072 \begin_layout Standard
24073 \noindent
24074
24075 \begin_inset ERT
24076 status collapsed
24077
24078 \begin_layout Standard
24079
24080 \backslash
24081 newfont{
24082 \backslash
24083 tmpfont}{cmr17 scaled 2500}{
24084 \backslash
24085 tmpfont T}
24086 \backslash
24087 vspace*{-8.4ex}
24088 \end_layout
24089
24090 \end_inset
24091
24092
24093 \end_layout
24094
24095 \begin_layout Standard
24096 \noindent
24097
24098 \begin_inset ERT
24099 status inlined
24100
24101 \begin_layout Standard
24102
24103 \backslash
24104 hangindent=3.3em 
24105 \backslash
24106 hangafter=-3
24107 \end_layout
24108
24109 \end_inset
24110
24111  hose of you who like the style of old books probably also like 
24112 \begin_inset Quotes eld
24113 \end_inset
24114
24115 dropped capitals
24116 \begin_inset Quotes erd
24117 \end_inset
24118
24119 ---those large capital letters which begin each new chapter or section.
24120  Implementing them with plain LyX/LaTeX is straightforward (assuming you
24121  know some plain TeX!) but does require a lot of work and many iterations,
24122  as you can see by all the ugly TeX-mode stuff at the beginning of this
24123  paragraph.
24124 \end_layout
24125
24126 \begin_layout Standard
24127
24128
24129 \begin_inset ERT
24130 status inlined
24131
24132 \begin_layout Standard
24133
24134 \backslash
24135 verb+
24136 \backslash
24137 bigdrop{-1em}{3}{ptmri}{T}+
24138 \end_layout
24139
24140 \end_inset
24141
24142 here is a much easier way of doing this, of course.
24143  The 
24144 \family typewriter
24145 dropcaps
24146 \family default
24147  (or the newer 
24148 \family typewriter
24149 dropping
24150 \family default
24151 ) package from CTAN allows a simple way to add such letters to your documents.
24152  Since this package is not a standard part of teTeX, I can't demonstrate
24153  it within this document, but if you copy this paragraph to a new document,
24154  delete the 
24155 \begin_inset Quotes eld
24156 \end_inset
24157
24158
24159 \family typewriter
24160
24161 \backslash
24162 verb
24163 \family default
24164
24165 \begin_inset Quotes erd
24166 \end_inset
24167
24168  and the pluses from the TeX code at the beginning of the paragraph, and
24169  add 
24170 \family typewriter
24171
24172 \backslash
24173 usepackage{dropcaps}
24174 \family default
24175  to your LaTeX preamble, you will get a nice Times Roman Italic 
24176 \begin_inset Quotes eld
24177 \end_inset
24178
24179 T
24180 \begin_inset Quotes erd
24181 \end_inset
24182
24183 , whose height is three lines of text and which protrudes 1 em into the
24184  margin.
24185  (Make certain you have copied 
24186 \begin_inset Quotes eld
24187 \end_inset
24188
24189
24190 \family typewriter
24191 dropcaps.sty
24192 \family default
24193
24194 \begin_inset Quotes erd
24195 \end_inset
24196
24197  into a directory where TeX can see it.) The first argument is the amount
24198  of indentation; in this case the negative sign moves it into the margin.
24199  The second argument is the height of the letter in number of lines of text.
24200  The third argument is the font name: virtually anything which has a tfm
24201  file should work (wade through the 
24202 \family typewriter
24203 .../texmf/fonts/tfm
24204 \family default
24205  directory for possibilities).
24206  My personal favorite is 
24207 \begin_inset Quotes eld
24208 \end_inset
24209
24210
24211 \family typewriter
24212 yinit
24213 \family default
24214
24215 \begin_inset Quotes erd
24216 \end_inset
24217
24218 , a fancy German font specifically designed for dropped capitals.
24219  The fourth argument is the letter (or letters) to be dropped.
24220  The 
24221 \family typewriter
24222 dropping
24223 \family default
24224  package also offers the 
24225 \family typewriter
24226
24227 \backslash
24228 bigdrop
24229 \family default
24230  command, as well as a slightly simplified 
24231 \family typewriter
24232
24233 \backslash
24234 dropping
24235 \family default
24236  command.
24237 \end_layout
24238
24239 \begin_layout Section
24240
24241 Non-standard Paragraph Shapes
24242 \end_layout
24243
24244 \begin_layout Standard
24245
24246 by 
24247 \noun on
24248 Mike Ressler
24249 \end_layout
24250
24251 \begin_layout Standard
24252
24253
24254 \begin_inset VSpace bigskip
24255 \end_inset
24256
24257
24258 \end_layout
24259
24260
24261 \begin_layout Standard
24262
24263
24264 \begin_inset ERT
24265 status inlined
24266
24267 \begin_layout Standard
24268
24269 \backslash
24270 begin{sloppypar}
24271 \end_layout
24272
24273 \end_inset
24274
24275
24276 \end_layout
24277
24278 \begin_layout Standard
24279
24280
24281 \begin_inset ERT
24282 status collapsed
24283
24284 \begin_layout Standard
24285
24286 \backslash
24287 newdimen
24288 \backslash
24289 varunit 
24290 \end_layout
24291
24292 \begin_layout Standard
24293
24294 \backslash
24295 setlength{
24296 \backslash
24297 varunit}{4.5in}
24298 \end_layout
24299
24300 \end_inset
24301
24302
24303 \end_layout
24304
24305 \begin_layout Standard
24306 \noindent
24307
24308 \begin_inset ERT
24309 status collapsed
24310
24311 \begin_layout Standard
24312
24313 \backslash
24314 parshape 19 0.45
24315 \backslash
24316 varunit 0.332
24317 \backslash
24318 varunit
24319 \end_layout
24320
24321 \begin_layout Standard
24322 0.40
24323 \backslash
24324 varunit 0.300
24325 \backslash
24326 varunit
24327 \end_layout
24328
24329 \begin_layout Standard
24330 0.35
24331 \backslash
24332 varunit 0.293
24333 \backslash
24334 varunit
24335 \end_layout
24336
24337 \begin_layout Standard
24338 0.30
24339 \backslash
24340 varunit 0.300
24341 \backslash
24342 varunit
24343 \end_layout
24344
24345 \begin_layout Standard
24346 0.25
24347 \backslash
24348 varunit 0.317
24349 \backslash
24350 varunit
24351 \end_layout
24352
24353 \begin_layout Standard
24354 0.20
24355 \backslash
24356 varunit 0.342
24357 \backslash
24358 varunit
24359 \end_layout
24360
24361 \begin_layout Standard
24362 0.15
24363 \backslash
24364 varunit 0.373
24365 \backslash
24366 varunit
24367 \end_layout
24368
24369 \begin_layout Standard
24370 0.10
24371 \backslash
24372 varunit 0.410
24373 \backslash
24374 varunit
24375 \end_layout
24376
24377 \begin_layout Standard
24378 0.05
24379 \backslash
24380 varunit 0.453
24381 \backslash
24382 varunit
24383 \end_layout
24384
24385 \begin_layout Standard
24386 0.00
24387 \backslash
24388 varunit 0.500
24389 \backslash
24390 varunit
24391 \end_layout
24392
24393 \begin_layout Standard
24394 0.05
24395 \backslash
24396 varunit 0.453
24397 \backslash
24398 varunit
24399 \end_layout
24400
24401 \begin_layout Standard
24402 0.10
24403 \backslash
24404 varunit 0.410
24405 \backslash
24406 varunit
24407 \end_layout
24408
24409 \begin_layout Standard
24410 0.15
24411 \backslash
24412 varunit 0.373
24413 \backslash
24414 varunit
24415 \end_layout
24416
24417 \begin_layout Standard
24418 0.20
24419 \backslash
24420 varunit 0.342
24421 \backslash
24422 varunit
24423 \end_layout
24424
24425 \begin_layout Standard
24426 0.25
24427 \backslash
24428 varunit 0.317
24429 \backslash
24430 varunit
24431 \end_layout
24432
24433 \begin_layout Standard
24434 0.30
24435 \backslash
24436 varunit 0.300
24437 \backslash
24438 varunit
24439 \end_layout
24440
24441 \begin_layout Standard
24442 0.35
24443 \backslash
24444 varunit 0.293
24445 \backslash
24446 varunit
24447 \end_layout
24448
24449 \begin_layout Standard
24450 0.40
24451 \backslash
24452 varunit 0.300
24453 \backslash
24454 varunit
24455 \end_layout
24456
24457 \begin_layout Standard
24458 0.45
24459 \backslash
24460 varunit 0.332
24461 \backslash
24462 varunit
24463 \end_layout
24464
24465 \begin_layout Standard
24466
24467 \end_layout
24468
24469 \end_inset
24470
24471 There are times when the tyranny of rectangular paragraphs must be overthrown.
24472  In such situations, a call to the delightful plain TeX command 
24473 \family typewriter
24474
24475 \backslash
24476 parshape
24477 \family default
24478  is called for.
24479  As you can see, completely arbitrary shapes can be laid out with a suitable
24480  set of linelength definitions.
24481  While this parshape may look a bit silly and useless, one could conceive
24482  of situations such as finely tuned dropped capitals, word wrapping around
24483  non-rectangular graphics, etc.
24484  which will benefit from such handcrafting.
24485 \end_layout
24486
24487
24488 \begin_layout Standard
24489
24490
24491 \begin_inset VSpace bigskip
24492 \end_inset
24493
24494
24495 \end_layout
24496
24497 \begin_layout Standard
24498
24499 The syntax is 
24500 \family typewriter
24501
24502 \backslash
24503 parshape numlines #1indent #1length #2indent #2length \SpecialChar \ldots{}
24504  #nindent #nlength
24505 \family default
24506 , where 
24507 \family typewriter
24508 numlines
24509 \family default
24510  is the number of lines of text which define the paragraph.
24511  If there turn out to be fewer lines, the shape is truncated; if there are
24512  more, the excess lines have the same dimensions as the last line of the
24513  definition.
24514  The 
24515 \family typewriter
24516 #nindent
24517 \family default
24518  and 
24519 \family typewriter
24520 #nlength
24521 \family default
24522  entries specify the indentation of the line from the left margin, and the
24523  length of the line as measured from that point.
24524  The shape applies only to the current paragraph; everything is reset to
24525  normal for the next paragraph.
24526 \end_layout
24527
24528 \begin_layout Standard
24529
24530
24531 \begin_inset ERT
24532 status inlined
24533
24534 \begin_layout Standard
24535
24536 \backslash
24537 end{sloppypar}
24538 \end_layout
24539
24540 \end_inset
24541
24542
24543 \end_layout
24544
24545 \begin_layout Section
24546
24547 Summary
24548 \end_layout
24549
24550 \begin_layout Standard
24551
24552 As you can see, the examples in this section range from the useful to the
24553  whimsical.
24554  While I don't expect that anyone will ever need the paragraph shape demonstrate
24555 d in the last section, the important point is that you can do almost anything
24556  you want in LyX if you are willing to figure out how to do it in TeX and
24557  LaTeX.
24558  TeX is a fantastically powerful typesetting system and all that power is
24559  available to you since LyX uses it as its backend.
24560  Happy LyXing!
24561 \end_layout
24562
24563 \end_body
24564 \end_document