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