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