]> git.lyx.org Git - features.git/blob - lib/doc/Additional.lyx
ffd383a839cfc58c1974fb5f3928e21bdc3ff1a2
[features.git] / lib / doc / Additional.lyx
1 #LyX 2.0 created this file. For more info see http://www.lyx.org/
2 \lyxformat 413
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
47 % test for installed LaTeX packages
48 \usepackage{ifthen}
49
50 % for wrapped figures/tables
51 % test for picinpar
52 \newboolean{picinpar}
53 \IfFileExists{picinpar.sty}
54  {\usepackage{picinpar}
55   \setboolean{picinpar}{true}}
56  {\setboolean{picinpar}{false}}
57 \end_preamble
58 \options fleqn,bibliography=totoc,index=totoc,BCOR7.5mm,titlepage,captions=tableheading
59 \use_default_options false
60 \begin_modules
61 logicalmkup
62 theorems-ams
63 theorems-ams-extended
64 \end_modules
65 \maintain_unincluded_children false
66 \begin_local_layout
67 Format 7
68 InsetLayout CharStyle:MenuItem
69 LyxType               charstyle
70 LabelString           menu
71 LatexType             command
72 LatexName             menuitem
73 Font
74 Family              Sans
75 EndFont
76 Preamble
77 \newcommand*{\menuitem}[1]{{\sffamily #1}}
78 EndPreamble
79 End
80 \end_local_layout
81 \language english
82 \language_package default
83 \inputencoding auto
84 \fontencoding global
85 \font_roman default
86 \font_sans default
87 \font_typewriter default
88 \font_default_family default
89 \use_non_tex_fonts false
90 \font_sc false
91 \font_osf false
92 \font_sf_scale 100
93 \font_tt_scale 100
94
95 \graphics default
96 \default_output_format default
97 \output_sync 0
98 \bibtex_command default
99 \index_command default
100 \paperfontsize 12
101 \spacing single
102 \use_hyperref true
103 \pdf_title "LyX's Additional Features manual"
104 \pdf_author "LyX Team"
105 \pdf_subject "LyX's additional features documentation"
106 \pdf_keywords "LyX, Documentation, Additional"
107 \pdf_bookmarks true
108 \pdf_bookmarksnumbered true
109 \pdf_bookmarksopen false
110 \pdf_bookmarksopenlevel 1
111 \pdf_breaklinks false
112 \pdf_pdfborder false
113 \pdf_colorlinks true
114 \pdf_backref false
115 \pdf_pdfusetitle false
116 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
117 \papersize default
118 \use_geometry false
119 \use_amsmath 1
120 \use_esint 0
121 \use_mhchem 1
122 \use_mathdots 1
123 \cite_engine basic
124 \use_bibtopic false
125 \use_indices false
126 \paperorientation portrait
127 \suppress_date false
128 \use_refstyle 0
129 \index Index
130 \shortcut idx
131 \color #008000
132 \end_index
133 \secnumdepth 3
134 \tocdepth 3
135 \paragraph_separation indent
136 \paragraph_indentation default
137 \quotes_language english
138 \papercolumns 1
139 \papersides 2
140 \paperpagestyle headings
141 \tracking_changes false
142 \output_changes false
143 \html_math_output 0
144 \html_css_as_file 0
145 \html_be_strict true
146 \end_header
147
148 \begin_body
149
150 \begin_layout Title
151 Additional LyX Features
152 \end_layout
153
154 \begin_layout Subtitle
155 Version 2.0.x
156 \end_layout
157
158 \begin_layout Author
159 by the LyX Team
160 \begin_inset Foot
161 status collapsed
162
163 \begin_layout Plain Layout
164 \noindent
165 Principal maintainer of this file is
166 \noun on
167  Richard Heck
168 \noun default
169 .
170  If you have comments or error corrections, please send them to the LyX
171  Documentation mailing list, 
172 \begin_inset Flex Code
173 status collapsed
174
175 \begin_layout Plain Layout
176 \noindent
177 <lyx-docs@lists.lyx.org>
178 \end_layout
179
180 \end_inset
181
182 .
183 \end_layout
184
185 \end_inset
186
187
188 \end_layout
189
190 \begin_layout Standard
191 \begin_inset CommandInset toc
192 LatexCommand tableofcontents
193
194 \end_inset
195
196
197 \end_layout
198
199 \begin_layout Chapter
200 Introduction
201 \end_layout
202
203 \begin_layout Standard
204 This manual is essentially Part II of the 
205 \emph on
206 User's Guide\SpecialChar \@.
207
208 \emph default
209  The reason for separating this document out is simple: the 
210 \emph on
211 User's Guide
212 \emph default
213  is already quite lengthy, and it contains information on all of the basic
214  features one needs to know in order to prepare most documents.
215  However, the LyX Team has worked to make LyX extensible through various
216  configuration files and external packages.
217  That means that if you want to support the Fizzwizzle LaTeX package, you
218  can create a layout file (or module) for it without having to alter LyX
219  itself.
220  We've already had contributions of several new features this way, and some
221  of them are documented here.
222  There are also some more `advanced' features, such as how to control the
223  presentation of bibliographies and how to work with multi-part documents,
224  that are not covered in the 
225 \emph on
226 User's Guide
227 \emph default
228  and are discussed here.
229 \end_layout
230
231 \begin_layout Standard
232 This manual also documents some special features, like fax support, version
233  control, and SGML support, which require additional software to work properly.
234  There is also a chapter on LyX's support for HTML.
235  And lastly, there's a chapter of LaTeX tools and tips, things you can use
236  to spruce up your documents by directly using the powerful features of
237  LaTeX.
238  After all, LyX 
239 \emph on
240 is
241 \emph default
242  only WYSIWYM and will only ever interface to some, not all, LaTeX features.
243 \end_layout
244
245 \begin_layout Standard
246 If you haven't read the 
247 \emph on
248 Introduction
249 \emph default
250  yet, you are definitely in the wrong manual.
251  The 
252 \emph on
253 Introduction
254 \emph default
255  is the first place to go, since it describes the notation and format of
256  all of the manuals.
257  You should also be thoroughly familiar with the 
258 \emph on
259 User's Guide
260 \emph default
261  and all of the basic features of LyX before attempting to read this one.
262 \end_layout
263
264 \begin_layout Standard
265 Since many of the topics in this manual depend heavily on LyX's interaction
266  with LaTeX, this first chapter covers the inner workings of LyX and how
267  to direct LyX to generate exactly the LaTeX code you want.
268  It is obviously for more seasoned LyX users.
269 \end_layout
270
271 \begin_layout Chapter
272 LyX and LaTeX
273 \end_layout
274
275 \begin_layout Section
276 How LyX Uses LaTeX
277 \end_layout
278
279 \begin_layout Standard
280 This chapter is for both TeX-nicians and the LaTeX-curious.
281  In it, we'll explain how LyX and LaTeX work together to produce printable
282  output.
283  This is the only place in any of the manuals where we assume you know something
284  about LaTeX.
285 \end_layout
286
287 \begin_layout Standard
288 At one time, LyX was called a 
289 \begin_inset Quotes eld
290 \end_inset
291
292 WYSIWYM frontend to LaTeX,
293 \begin_inset Quotes erd
294 \end_inset
295
296  but that's no longer true.
297  There are frontends to LaTeX out there.
298 \begin_inset Foot
299 status collapsed
300
301 \begin_layout Plain Layout
302 Some familar ones are TeXmaker and kile, on Linux, and TeXshop, OSX.
303  There are also the LaTeX modes for vi and emacs, of course.
304 \end_layout
305
306 \end_inset
307
308  These are basically text editors with the ability to run LaTeX and mark
309  any errors in the file you're editing.
310  Although LyX 
311 \emph on
312 is
313 \emph default
314  an editor, and it 
315 \emph on
316 does
317 \emph default
318  run LaTeX, and it also indicates errors in the file, it also does much,
319  much more.
320  For one thing, you don't need to know LaTeX to use LyX effectively.
321  And LyX has added its own extensions to LaTeX.
322  Try the following sometime: select 
323 \begin_inset Flex MenuItem
324 status collapsed
325
326 \begin_layout Plain Layout
327 Export\SpecialChar \menuseparator
328 LaTeX
329 \end_layout
330
331 \end_inset
332
333  from the 
334 \begin_inset Flex MenuItem
335 status collapsed
336
337 \begin_layout Plain Layout
338 File
339 \end_layout
340
341 \end_inset
342
343  menu (or 
344 \begin_inset Flex MenuItem
345 status collapsed
346
347 \begin_layout Plain Layout
348 View\SpecialChar \menuseparator
349 Source
350 \end_layout
351
352 \end_inset
353
354 ), then look at the preamble of the resulting 
355 \begin_inset Flex Code
356 status collapsed
357
358 \begin_layout Plain Layout
359 .tex
360 \end_layout
361
362 \end_inset
363
364  file.
365  You'll notice a variety of new macros defined specifically by LyX.
366  These macros are defined automatically, according to the features you use
367  in the document.
368 \end_layout
369
370 \begin_layout Standard
371 There are several commands that automatically invoke LaTeX.
372  They are:
373 \end_layout
374
375 \begin_layout Itemize
376 \begin_inset Flex MenuItem
377 status collapsed
378
379 \begin_layout Plain Layout
380 View\SpecialChar \menuseparator
381 Format
382 \end_layout
383
384 \end_inset
385
386
387 \end_layout
388
389 \begin_layout Itemize
390 \begin_inset Flex MenuItem
391 status collapsed
392
393 \begin_layout Plain Layout
394 View\SpecialChar \menuseparator
395 Update\SpecialChar \menuseparator
396 Format
397 \end_layout
398
399 \end_inset
400
401
402 \end_layout
403
404 \begin_layout Itemize
405 \begin_inset Flex MenuItem
406 status collapsed
407
408 \begin_layout Plain Layout
409 File\SpecialChar \menuseparator
410 Print
411 \end_layout
412
413 \end_inset
414
415
416 \end_layout
417
418 \begin_layout Itemize
419 \begin_inset Flex MenuItem
420 status collapsed
421
422 \begin_layout Plain Layout
423 File\SpecialChar \menuseparator
424 Fax
425 \end_layout
426
427 \end_inset
428
429
430 \end_layout
431
432 \begin_layout Standard
433 They will only invoke LaTeX if the file has changed since the last time
434  LaTeX was run.
435  
436 \end_layout
437
438 \begin_layout Standard
439 When LyX runs LaTeX on the file you're editing, it performs these steps:
440 \end_layout
441
442 \begin_layout Enumerate
443 Convert the document to LaTeX and save to a file with the extension 
444 \begin_inset Flex Code
445 status collapsed
446
447 \begin_layout Plain Layout
448 .tex
449 \end_layout
450
451 \end_inset
452
453  in place of 
454 \begin_inset Flex Code
455 status collapsed
456
457 \begin_layout Plain Layout
458 .lyx
459 \end_layout
460
461 \end_inset
462
463 .
464 \end_layout
465
466 \begin_layout Enumerate
467 Run LaTeX on the 
468 \begin_inset Flex Code
469 status collapsed
470
471 \begin_layout Plain Layout
472 .tex
473 \end_layout
474
475 \end_inset
476
477  file (maybe several times), and run any other commands (such as 
478 \begin_inset Flex Code
479 status collapsed
480
481 \begin_layout Plain Layout
482 bibtex
483 \end_layout
484
485 \end_inset
486
487  or 
488 \begin_inset Flex Code
489 status collapsed
490
491 \begin_layout Plain Layout
492 makeindex
493 \end_layout
494
495 \end_inset
496
497 ) needed to compile the LaTeX file.
498 \end_layout
499
500 \begin_layout Enumerate
501 If there are any errors, show the error log.
502 \end_layout
503
504 \begin_layout Standard
505 If you've run LaTeX using 
506 \begin_inset Flex MenuItem
507 status collapsed
508
509 \begin_layout Plain Layout
510 View
511 \bar under
512 \SpecialChar \menuseparator
513
514 \bar default
515 DVI
516 \end_layout
517
518 \end_inset
519
520 , LyX then runs a DVI viewer to display the DVI-file.
521  If you've used 
522 \begin_inset Flex MenuItem
523 status collapsed
524
525 \begin_layout Plain Layout
526 View
527 \bar under
528 \SpecialChar \menuseparator
529
530 \bar default
531 PostScript
532 \end_layout
533
534 \end_inset
535
536 , LyX performs further steps:
537 \end_layout
538
539 \begin_layout Itemize
540 Run 
541 \begin_inset Flex Code
542 status collapsed
543
544 \begin_layout Plain Layout
545 dvips
546 \end_layout
547
548 \end_inset
549
550  to convert the DVI file to PostScript.
551 \end_layout
552
553 \begin_layout Itemize
554 Run a PostScript viewer, such as 
555 \begin_inset Flex Code
556 status collapsed
557
558 \begin_layout Plain Layout
559 ghostview
560 \end_layout
561
562 \end_inset
563
564 , to display the PostScript file.
565 \end_layout
566
567 \begin_layout Standard
568 LyX does similar things when viewing, or exporting, other formats.
569 \end_layout
570
571 \begin_layout Section
572 Translating LaTeX files into LyX
573 \end_layout
574
575 \begin_layout Standard
576 You can import a LaTeX file into LyX by using the 
577 \begin_inset Flex MenuItem
578 status collapsed
579
580 \begin_layout Plain Layout
581 File\SpecialChar \menuseparator
582 Import\SpecialChar \menuseparator
583 LaTeX
584 \end_layout
585
586 \end_inset
587
588  command in LyX.
589  This will call a program named 
590 \begin_inset Flex Code
591 status collapsed
592
593 \begin_layout Plain Layout
594 tex2lyx
595 \end_layout
596
597 \end_inset
598
599  which will create a file 
600 \begin_inset Flex Code
601 status collapsed
602
603 \begin_layout Plain Layout
604 foo.lyx
605 \end_layout
606
607 \end_inset
608
609  from the file 
610 \begin_inset Flex Code
611 status collapsed
612
613 \begin_layout Plain Layout
614 foo.tex
615 \end_layout
616
617 \end_inset
618
619 .
620  LyX will then open that file.
621 \begin_inset Foot
622 status collapsed
623
624 \begin_layout Plain Layout
625 \begin_inset Flex Code
626 status collapsed
627
628 \begin_layout Plain Layout
629 tex2lyx
630 \end_layout
631
632 \end_inset
633
634  can also be run from the command line, of course.
635 \end_layout
636
637 \end_inset
638
639
640 \end_layout
641
642 \begin_layout Standard
643 \begin_inset Flex Code
644 status collapsed
645
646 \begin_layout Plain Layout
647 tex2lyx
648 \end_layout
649
650 \end_inset
651
652  will translate most legal LaTeX, but not everything.
653  It will put things it doesn't understand into TeX code, so after translating
654  a file with 
655 \begin_inset Flex Code
656 status collapsed
657
658 \begin_layout Plain Layout
659 tex2lyx
660 \end_layout
661
662 \end_inset
663
664 , you can look for TeX code and hand-edit it until it looks right.
665 \end_layout
666
667 \begin_layout Standard
668 If you don't know what TeX code is, read the next section.
669 \end_layout
670
671 \begin_layout Section
672 \begin_inset CommandInset label
673 LatexCommand label
674 name "sec:Inserting-TeX-Code"
675
676 \end_inset
677
678 Inserting TeX Code into LyX Documents 
679 \end_layout
680
681 \begin_layout Standard
682 Anything you can do in LaTeX you can do in LyX, for a very simple reason:
683  You can always insert TeX code into any LyX document.
684  LyX cannot, and will never be able to, display every possible LaTeX construct.
685  If ever you need to insert LaTeX commands into your LyX document, you can
686  use the 
687 \begin_inset Flex Code
688 status collapsed
689
690 \begin_layout Plain Layout
691 TeX Code
692 \end_layout
693
694 \end_inset
695
696  box, which you can insert into your document with 
697 \begin_inset Flex MenuItem
698 status collapsed
699
700 \begin_layout Plain Layout
701 Insert\SpecialChar \menuseparator
702 TeX Code
703 \end_layout
704
705 \end_inset
706
707 .
708 \end_layout
709
710 \begin_layout Standard
711 Here's an example of inserting LaTeX commands in a LyX document.
712  The code looks like this:
713 \end_layout
714
715 \begin_layout LyX-Code
716
717 \backslash
718 begin{tabular}{ll}
719 \begin_inset Newline newline
720 \end_inset
721
722
723 \backslash
724 begin{minipage}{5cm}
725 \begin_inset Newline newline
726 \end_inset
727
728 This is an example for a minipage environment.
729  You 
730 \begin_inset Newline newline
731 \end_inset
732
733 can put nearly everything in it, even (non-floating) 
734 \begin_inset Newline newline
735 \end_inset
736
737 figures and tables.
738  
739 \begin_inset Newline newline
740 \end_inset
741
742
743 \backslash
744 end{minipage}
745 \begin_inset Newline newline
746 \end_inset
747
748 &
749 \begin_inset Newline newline
750 \end_inset
751
752
753 \backslash
754 begin{minipage}{5cm}
755 \begin_inset Newline newline
756 \end_inset
757
758
759 \backslash
760 begin{verbatim}
761 \begin_inset Newline newline
762 \end_inset
763
764
765 \backslash
766 begin{minipage}{5cm}
767 \begin_inset Newline newline
768 \end_inset
769
770 This ...
771  
772 \begin_inset Newline newline
773 \end_inset
774
775
776 \backslash
777 end{minipage}
778 \begin_inset Newline newline
779 \end_inset
780
781
782 \backslash
783 end{verbatim}
784 \begin_inset Newline newline
785 \end_inset
786
787
788 \backslash
789 end{minipage}
790 \begin_inset Newline newline
791 \end_inset
792
793
794 \backslash
795 end{tabular}
796 \end_layout
797
798 \begin_layout LyX-Code
799
800 \end_layout
801
802 \begin_layout Standard
803 The 
804 \begin_inset Flex Code
805 status collapsed
806
807 \begin_layout Plain Layout
808 TeX Code
809 \end_layout
810
811 \end_inset
812
813  box containing this text is directly after this paragraph.
814  Those of you reading the manual in LyX will only see the TeX code inset.
815  Those reading a printed version of the manuals will see the actual results:
816 \end_layout
817
818 \begin_layout Standard
819 \begin_inset ERT
820 status collapsed
821
822 \begin_layout Plain Layout
823
824
825 \backslash
826 begin{tabular}{ll}
827 \end_layout
828
829 \begin_layout Plain Layout
830
831
832 \backslash
833 begin{minipage}{5cm}
834 \end_layout
835
836 \begin_layout Plain Layout
837
838 This is an example for a minipage environment.
839  You can put nearly everything in it, even (non-floating) figures and tables.
840  
841 \end_layout
842
843 \begin_layout Plain Layout
844
845
846 \backslash
847 end{minipage}
848 \end_layout
849
850 \begin_layout Plain Layout
851
852 &
853 \end_layout
854
855 \begin_layout Plain Layout
856
857
858 \backslash
859 begin{minipage}{5cm}
860 \end_layout
861
862 \begin_layout Plain Layout
863
864
865 \backslash
866 begin{verbatim}
867 \end_layout
868
869 \begin_layout Plain Layout
870
871
872 \backslash
873 begin{minipage}{5cm}
874 \end_layout
875
876 \begin_layout Plain Layout
877
878 This ...
879  
880 \end_layout
881
882 \begin_layout Plain Layout
883
884
885 \backslash
886 end{minipage}
887 \end_layout
888
889 \begin_layout Plain Layout
890
891
892 \backslash
893 end{verbatim}
894 \end_layout
895
896 \begin_layout Plain Layout
897
898
899 \backslash
900 end{minipage}
901 \end_layout
902
903 \begin_layout Plain Layout
904
905
906 \backslash
907 end{tabular}
908 \end_layout
909
910 \end_inset
911
912
913 \end_layout
914
915 \begin_layout Standard
916 In addition to using TeX code, you can also create a separate file containing
917  some complex LaTeX structure and then use 
918 \begin_inset Flex MenuItem
919 status collapsed
920
921 \begin_layout Plain Layout
922 Insert\SpecialChar \menuseparator
923 Child
924 \begin_inset space ~
925 \end_inset
926
927 Document
928 \end_layout
929
930 \end_inset
931
932  to include your file (you should select the type 
933 \begin_inset Flex Code
934 status collapsed
935
936 \begin_layout Plain Layout
937 Input
938 \end_layout
939
940 \end_inset
941
942 ).
943  We recommend that you only do this if you have a 
944 \begin_inset Flex Code
945 status collapsed
946
947 \begin_layout Plain Layout
948 .tex
949 \end_layout
950
951 \end_inset
952
953  file which you 
954 \emph on
955 know
956 \emph default
957  works already.
958  Otherwise, you'll have a big job tracking down LaTeX errors.
959 \end_layout
960
961 \begin_layout Standard
962 There are a few last points to emphasize:
963 \end_layout
964
965 \begin_layout Itemize
966 LyX 
967 \emph on
968 does not
969 \emph default
970  check if your LaTeX code is correct.
971 \end_layout
972
973 \begin_layout Itemize
974 Beware reinventing the wheel.
975 \end_layout
976
977 \begin_layout Standard
978 On that last point, LyX does have quite a few features tucked into it, and
979  more are coming.
980  Be sure to check the manuals to make sure that LyX doesn't have such-and-such
981  feature before you decide you have to do it by hand.
982  Moreover, there are numerous LaTeX packages out there to do all sorts of
983  things, from labels to envelopes to fancy multipage tables.
984  Check out 
985 \begin_inset CommandInset href
986 LatexCommand href
987 name "CTAN"
988 target "http://www.ctan.org/"
989
990 \end_inset
991
992  for details, and see chapter 
993 \begin_inset CommandInset ref
994 LatexCommand ref
995 reference "cha:secrets"
996
997 \end_inset
998
999 .
1000 \end_layout
1001
1002 \begin_layout Standard
1003 If you do need to do some wild and fancy things within your document, be
1004  sure to check out a good LaTeX book for assistance.
1005  There are a number of them listed in the bibliography of the 
1006 \emph on
1007 User's Guide
1008 \emph default
1009 .
1010 \end_layout
1011
1012 \begin_layout Section
1013 LyX and the LaTeX Preamble
1014 \end_layout
1015
1016 \begin_layout Subsection
1017 About the LaTeX Preamble
1018 \end_layout
1019
1020 \begin_layout Standard
1021 If you already know LaTeX, there is no need to explain here what the preamble
1022  is good for.
1023  If you don't, the following will give you some ideas—we recommend again
1024  that you consult a LaTeX book for further information.
1025  In any case, you should read the points below, because they explain what
1026  you can do and what you don't need to do in the LaTeX preamble of a LyX
1027  document.
1028 \end_layout
1029
1030 \begin_layout Standard
1031 The LaTeX preamble comes at the very beginning of a document, 
1032 \emph on
1033 before
1034 \emph default
1035  the text.
1036  It serves to:
1037 \end_layout
1038
1039 \begin_layout Itemize
1040 Declare the document class.
1041  
1042 \begin_inset Newline newline
1043 \end_inset
1044
1045 LyX already does this for you.
1046  If you're a seasoned LaTeX-nician, and you have a custom document class
1047  you want to use, check out the 
1048 \emph on
1049 Customization Manual
1050 \emph default
1051  for information on how to make LyX interface to it.
1052 \end_layout
1053
1054 \begin_layout Itemize
1055 Declare the usage of packages.
1056  
1057 \begin_inset Newline newline
1058 \end_inset
1059
1060 LaTeX packages provide special commands, which are only available within
1061  a document when the package has been declared in the preamble.
1062  For example, the package 
1063 \begin_inset Flex Code
1064 status collapsed
1065
1066 \begin_layout Plain Layout
1067 indentfirst
1068 \end_layout
1069
1070 \end_inset
1071
1072  forces all paragraphs to be indented.
1073  There are other packages for labels, envelopes, margins, etc.
1074  
1075 \end_layout
1076
1077 \begin_layout Itemize
1078 Set counters, variables, lengths and widths.
1079  
1080 \begin_inset Newline newline
1081 \end_inset
1082
1083 There are several LaTeX counters and variables which 
1084 \emph on
1085 must
1086 \emph default
1087  be set globally from within the preamble in order to have the desired effect.
1088  (There are variables which you can set and reset inside the document, too.)
1089  Margins are a good example of something which must be set in the preamble.
1090  Another example is the label format for lists.
1091  You can actually set these just about anywhere, but it's best to do it
1092  just once, inside the preamble.
1093 \end_layout
1094
1095 \begin_layout Itemize
1096 Declare user defined commands (with 
1097 \begin_inset Flex Code
1098 status collapsed
1099
1100 \begin_layout Plain Layout
1101
1102 \backslash
1103 newcommand
1104 \end_layout
1105
1106 \end_inset
1107
1108  or 
1109 \begin_inset Flex Code
1110 status collapsed
1111
1112 \begin_layout Plain Layout
1113
1114 \backslash
1115 renewcommand
1116 \end_layout
1117
1118 \end_inset
1119
1120 ).
1121 \begin_inset Newline newline
1122 \end_inset
1123
1124 These are abbreviations for LaTeX commands which appear very often inside
1125  a document.
1126  Although the preamble is a good place to declare such commands, they 
1127 \emph on
1128 can
1129 \emph default
1130  be declared anywhere (before they are used for the first time, of course).
1131  This can be useful if there is a lot of raw LaTeX code in your document,
1132  which normally should not be the case.
1133 \end_layout
1134
1135 \begin_layout Standard
1136 LyX adds its own set of definitions to the preamble of the 
1137 \begin_inset Flex Code
1138 status collapsed
1139
1140 \begin_layout Plain Layout
1141 .tex
1142 \end_layout
1143
1144 \end_inset
1145
1146  file it produces.
1147  This makes LaTeX files generated by LyX portable.
1148 \end_layout
1149
1150 \begin_layout Subsection
1151 Changing the Preamble
1152 \end_layout
1153
1154 \begin_layout Standard
1155 The commands which LyX adds to the preamble of a LaTeX file are fixed; you
1156  can't change them without patching LyX itself.
1157  You can, however, add your own stuff to the preamble by selecting 
1158 \begin_inset Flex MenuItem
1159 status collapsed
1160
1161 \begin_layout Plain Layout
1162 LaTeX
1163 \begin_inset space ~
1164 \end_inset
1165
1166 Preamble
1167 \end_layout
1168
1169 \end_inset
1170
1171  in the 
1172 \begin_inset Flex MenuItem
1173 status collapsed
1174
1175 \begin_layout Plain Layout
1176 Document\SpecialChar \menuseparator
1177 Settings
1178 \end_layout
1179
1180 \end_inset
1181
1182  dialog.
1183  LyX adds anything in the 
1184 \begin_inset Flex MenuItem
1185 status collapsed
1186
1187 \begin_layout Plain Layout
1188 Preamble
1189 \end_layout
1190
1191 \end_inset
1192
1193  dialog to its own built-in preamble.
1194  Before adding your own declarations in the preamble, you should make sure
1195  that LyX doesn't already support what you want to do.
1196  (Remember what we said about reinventing the wheel?) Also, 
1197 \emph on
1198 make sure your preamble code is correct
1199 \emph default
1200 .
1201  LyX doesn't check it for you.
1202  If there is an error, you're likely to get an error like 
1203 \begin_inset Quotes eld
1204 \end_inset
1205
1206
1207 \begin_inset Flex Code
1208 status collapsed
1209
1210 \begin_layout Plain Layout
1211 Missing 
1212 \backslash
1213 begin{document}
1214 \end_layout
1215
1216 \end_inset
1217
1218
1219 \begin_inset Quotes erd
1220 \end_inset
1221
1222 .
1223  If you see this error, check your preamble.
1224 \end_layout
1225
1226 \begin_layout Subsection
1227 Examples
1228 \end_layout
1229
1230 \begin_layout Standard
1231 Here are some examples of what you can add to a preamble, and what they
1232  do.
1233 \end_layout
1234
1235 \begin_layout Subsubsection
1236 Example #1: Offsets
1237 \end_layout
1238
1239 \begin_layout Standard
1240 There are two variables under LaTeX that control page position: 
1241 \begin_inset Flex Code
1242 status collapsed
1243
1244 \begin_layout Plain Layout
1245
1246 \backslash
1247 hoffset
1248 \end_layout
1249
1250 \end_inset
1251
1252  and 
1253 \begin_inset Flex Code
1254 status collapsed
1255
1256 \begin_layout Plain Layout
1257
1258 \backslash
1259 voffset
1260 \end_layout
1261
1262 \end_inset
1263
1264 .
1265  Their names should be self-explanatory.
1266  These variables are useful if you think for a moment about computer labels.
1267  Sometimes, the size of a print medium and the area of the medium that you
1268  can actually print on aren't the same.
1269  This is where 
1270 \begin_inset Flex Code
1271 status collapsed
1272
1273 \begin_layout Plain Layout
1274
1275 \backslash
1276 hoffset
1277 \end_layout
1278
1279 \end_inset
1280
1281  and 
1282 \begin_inset Flex Code
1283 status collapsed
1284
1285 \begin_layout Plain Layout
1286
1287 \backslash
1288 voffset
1289 \end_layout
1290
1291 \end_inset
1292
1293  come in.
1294 \end_layout
1295
1296 \begin_layout Standard
1297 The default values for 
1298 \begin_inset Flex Code
1299 status collapsed
1300
1301 \begin_layout Plain Layout
1302
1303 \backslash
1304 hoffset
1305 \end_layout
1306
1307 \end_inset
1308
1309  and 
1310 \begin_inset Flex Code
1311 status collapsed
1312
1313 \begin_layout Plain Layout
1314
1315 \backslash
1316 voffset
1317 \end_layout
1318
1319 \end_inset
1320
1321  are both 0
1322 \begin_inset space \thinspace{}
1323 \end_inset
1324
1325 points, i.
1326 \begin_inset space \thinspace{}
1327 \end_inset
1328
1329 e.
1330 \begin_inset space \space{}
1331 \end_inset
1332
1333 the page isn't shifted.
1334  Unfortunately, some DVI drivers always seem to shift the page.
1335  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1336  If you're using LyX on a system that you don't personally maintain, and
1337  your sysadmin is a doofus, 
1338 \begin_inset Flex Code
1339 status collapsed
1340
1341 \begin_layout Plain Layout
1342
1343 \backslash
1344 hoffset
1345 \end_layout
1346
1347 \end_inset
1348
1349  and 
1350 \begin_inset Flex Code
1351 status collapsed
1352
1353 \begin_layout Plain Layout
1354
1355 \backslash
1356 voffset
1357 \end_layout
1358
1359 \end_inset
1360
1361  can save the day.
1362  Suppose your left and top margins are always 0.5
1363 \begin_inset space \thinspace{}
1364 \end_inset
1365
1366 inches too big.
1367  You can add this to the preamble:
1368 \end_layout
1369
1370 \begin_layout LyX-Code
1371
1372 \backslash
1373 setlength{
1374 \backslash
1375 hoffset}{-0.5 in}
1376 \end_layout
1377
1378 \begin_layout LyX-Code
1379
1380 \backslash
1381 setlength{
1382 \backslash
1383 voffset}{-0.5 in}
1384 \end_layout
1385
1386 \begin_layout Standard
1387 and your margins should now be correct.
1388 \end_layout
1389
1390 \begin_layout Subsubsection
1391 Example #2: Labels
1392 \end_layout
1393
1394 \begin_layout Standard
1395 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1396  There's a rather nice package, available at your nearest CTAN archive,
1397  for printing sheets of labels: 
1398 \begin_inset Flex Code
1399 status collapsed
1400
1401 \begin_layout Plain Layout
1402 labels.sty
1403 \end_layout
1404
1405 \end_inset
1406
1407 .
1408  Now, your system may not have this package installed by default.
1409  We leave that up to you to check.
1410  You'll also want to read the documentation for it; we're not going to do
1411  that for you.
1412  Since this is an example, however, we'll give you an example of how you
1413  use this package.
1414 \end_layout
1415
1416 \begin_layout Standard
1417 First, make sure you're using the 
1418 \begin_inset Flex Code
1419 status collapsed
1420
1421 \begin_layout Plain Layout
1422 article
1423 \end_layout
1424
1425 \end_inset
1426
1427  document class.
1428  Next, you need to put the following in your preamble:
1429 \end_layout
1430
1431 \begin_layout LyX-Code
1432
1433 \backslash
1434 usepackage{labels}
1435 \end_layout
1436
1437 \begin_layout LyX-Code
1438
1439 \backslash
1440 LabelCols=3
1441 \end_layout
1442
1443 \begin_layout LyX-Code
1444
1445 \backslash
1446 LabelRows=7
1447 \end_layout
1448
1449 \begin_layout LyX-Code
1450
1451 \backslash
1452 LeftBorder=8mm
1453 \end_layout
1454
1455 \begin_layout LyX-Code
1456
1457 \backslash
1458 RightBorder=8mm
1459 \end_layout
1460
1461 \begin_layout LyX-Code
1462
1463 \backslash
1464 TopBorder=9mm
1465 \end_layout
1466
1467 \begin_layout LyX-Code
1468
1469 \backslash
1470 BottomBorder=2mm
1471 \end_layout
1472
1473 \begin_layout Standard
1474 This sets things up for Avery label sheets, stock #5360.
1475  You're now ready to print labels, but you'll need to insert LaTeX code,
1476  placing the commands 
1477 \begin_inset Flex Code
1478 status collapsed
1479
1480 \begin_layout Plain Layout
1481
1482 \backslash
1483 begin{labels}
1484 \end_layout
1485
1486 \end_inset
1487
1488  and 
1489 \begin_inset Flex Code
1490 status collapsed
1491
1492 \begin_layout Plain Layout
1493
1494 \backslash
1495 end{labels}
1496 \end_layout
1497
1498 \end_inset
1499
1500  around each label text.
1501  This and other special features of 
1502 \begin_inset Flex Code
1503 status collapsed
1504
1505 \begin_layout Plain Layout
1506 labels.sty
1507 \end_layout
1508
1509 \end_inset
1510
1511  are explained in its documentation.
1512 \end_layout
1513
1514 \begin_layout Standard
1515 Someday, someone may write a LyX layout file to support this package directly.
1516  Maybe that someone is you.
1517 \end_layout
1518
1519 \begin_layout Subsubsection
1520 Example #3: Paragraph Indentation
1521 \end_layout
1522
1523 \begin_layout Standard
1524 Americans are trained to indent the first line of 
1525 \emph on
1526 every
1527 \emph default
1528  paragraph.
1529  As with all of their other weird quirks, most Americans will whine and
1530  moan until they can have their way and indent the first line of all paragraphs.
1531  (Yes, we're joking.
1532  (We are?) 
1533 \emph on
1534 Yeah
1535 \emph default
1536 , we are.)
1537 \end_layout
1538
1539 \begin_layout Standard
1540 Of course, this behavior isn't standard typography.
1541  In books, you typically only indent the first line of a paragraph 
1542 \emph on
1543 if
1544 \emph default
1545  it follows another one.
1546  The idea behind indenting the first line of a paragraph is to distinguish
1547  neighboring paragraphs from one another.
1548  If there is no previous paragraph—for example, if it follows a figure or
1549  is the first paragraph in a section—then there is no need for indentation.
1550  
1551 \end_layout
1552
1553 \begin_layout Standard
1554 If you're a typical American (we're still joking!), though, you don't care
1555  about such esoteric things; you want your indentation! Add this to the
1556  preamble:
1557 \end_layout
1558
1559 \begin_layout LyX-Code
1560
1561 \backslash
1562 usepackage{indentfirst}
1563 \end_layout
1564
1565 \begin_layout Standard
1566 If your TeX distribution isn't braindead, you'll have this package, and
1567  all of your paragraphs will get the indentation the Founding Fathers intended
1568  they should have.
1569 \end_layout
1570
1571 \begin_layout Subsubsection
1572 Example #4: This Document
1573 \end_layout
1574
1575 \begin_layout Standard
1576 You can also check out the preamble of this document to get an idea of some
1577  of the advanced things you can do.
1578  Also, there are more examples and an assortment of LaTeX 
1579 \begin_inset Quotes eld
1580 \end_inset
1581
1582 dirty tricks
1583 \begin_inset Quotes erd
1584 \end_inset
1585
1586  given in Chapter
1587 \begin_inset space ~
1588 \end_inset
1589
1590
1591 \begin_inset CommandInset ref
1592 LatexCommand ref
1593 reference "cha:secrets"
1594
1595 \end_inset
1596
1597 .
1598  
1599 \end_layout
1600
1601 \begin_layout Section
1602 LyX and LaTeX Errors
1603 \end_layout
1604
1605 \begin_layout Standard
1606 When LyX calls LaTeX, it tells LaTeX to blithely ignore any errors and keep
1607  going.
1608  It then uses the logfile from the LaTeX run to do a post-mortem.
1609  After analyzing the logfile,LyX displays a dialog listing the errors.
1610  Clicking on any one of them will take you to the position in your LyX file
1611  where the error occurred.
1612 \begin_inset Foot
1613 status collapsed
1614
1615 \begin_layout Plain Layout
1616 Well, usually.
1617  Analyzing the logfile is a tough job, and LyX doesn't always go to the
1618  right line.
1619  There are also cases where LaTeX reports the error on one line, but the
1620  actual error is earlier.
1621  This is not unlike forgetting a closing brace in a program: You'll get
1622  an error, but only later.
1623 \end_layout
1624
1625 \end_inset
1626
1627
1628 \end_layout
1629
1630 \begin_layout Standard
1631 Some folks also like to look at the log file directly: It is available from
1632  
1633 \begin_inset Flex MenuItem
1634 status collapsed
1635
1636 \begin_layout Plain Layout
1637 Document
1638 \bar under
1639 \SpecialChar \menuseparator
1640
1641 \bar default
1642 Latex
1643 \begin_inset space ~
1644 \end_inset
1645
1646 Log
1647 \end_layout
1648
1649 \end_inset
1650
1651 .
1652  There are some fairly common error messages and warnings.
1653  We'll cover those here.
1654  You should look at a good LaTeX book for a complete listing.
1655 \end_layout
1656
1657 \begin_layout Itemize
1658 \begin_inset Flex Code
1659 status collapsed
1660
1661 \begin_layout Plain Layout
1662 LaTeX Warning
1663 \end_layout
1664
1665 \end_inset
1666
1667
1668 \begin_inset Newline newline
1669 \end_inset
1670
1671 Anything beginning with these words is a warning message for the purpose
1672  of 
1673 \begin_inset Quotes eld
1674 \end_inset
1675
1676 debugging
1677 \begin_inset Quotes erd
1678 \end_inset
1679
1680  the LaTeX code itself.
1681  You'll get messages like this if you added or changed cross-references
1682  or bibliography entries, in which case, LaTeX is trying to tell you that
1683  you need to make another run.
1684  You can by-and-large ignore these.
1685 \end_layout
1686
1687 \begin_layout Itemize
1688 \begin_inset Flex Code
1689 status collapsed
1690
1691 \begin_layout Plain Layout
1692 LaTeX Font Warning
1693 \end_layout
1694
1695 \end_inset
1696
1697
1698 \begin_inset Newline newline
1699 \end_inset
1700
1701 Another warning message, this time about fonts which LaTeX couldn't find.
1702  The rest of the message will often say something about a replacement font
1703  that LaTeX used.
1704  You can safely ignore these, too.
1705 \end_layout
1706
1707 \begin_layout Itemize
1708 \begin_inset Flex Code
1709 status collapsed
1710
1711 \begin_layout Plain Layout
1712 Overfull 
1713 \backslash
1714 hbox
1715 \end_layout
1716
1717 \end_inset
1718
1719
1720 \begin_inset Newline newline
1721 \end_inset
1722
1723 LaTeX absolutely 
1724 \emph on
1725 loves
1726 \emph default
1727  to spew these out.
1728  They are warnings about lines that were too long and run past the right
1729  margin.
1730  Almost always, this is unnoticeable in the final output.
1731  (It can be just a point or two.) Or, only one or two characters extend past
1732  the margin.
1733  LaTeX seems to generate at least one of these messages for just about any
1734  document you write.
1735 \begin_inset Newline newline
1736 \end_inset
1737
1738 You can ignore these messages.
1739  Your eyes will tell you if there's a problem with something that's too
1740  wide; just look at the output.
1741 \begin_inset Foot
1742 status collapsed
1743
1744 \begin_layout Plain Layout
1745 You can also enable the `draft' option in 
1746 \begin_inset Flex MenuItem
1747 status collapsed
1748
1749 \begin_layout Plain Layout
1750 Document
1751 \bar under
1752 \SpecialChar \menuseparator
1753
1754 \bar default
1755 Settings
1756 \end_layout
1757
1758 \end_inset
1759
1760 , and then LaTeX will draw a black box in the margin of lines that are overfull.
1761 \end_layout
1762
1763 \end_inset
1764
1765
1766 \end_layout
1767
1768 \begin_layout Itemize
1769 \begin_inset Flex Code
1770 status collapsed
1771
1772 \begin_layout Plain Layout
1773 Underfull 
1774 \backslash
1775 hbox
1776 \end_layout
1777
1778 \end_inset
1779
1780
1781 \begin_inset Newline newline
1782 \end_inset
1783
1784 Not quite as common as its cousin.
1785  LaTeX seems to like to print lines that are a bit too wide as opposed to
1786  ones that are a bit too narrow.
1787  We have no idea why.
1788 \end_layout
1789
1790 \begin_layout Itemize
1791 \begin_inset Flex Code
1792 status collapsed
1793
1794 \begin_layout Plain Layout
1795 Overfull 
1796 \backslash
1797 vbox
1798 \end_layout
1799
1800 \end_inset
1801
1802  and 
1803 \begin_inset Flex Code
1804 status collapsed
1805
1806 \begin_layout Plain Layout
1807 Underfull 
1808 \backslash
1809 vbox
1810 \end_layout
1811
1812 \end_inset
1813
1814
1815 \begin_inset Newline newline
1816 \end_inset
1817
1818 Warnings about troubles breaking the page.
1819  Once again, just look at the output.
1820  Your eyes will tell you where something has gone wrong.
1821 \end_layout
1822
1823 \begin_layout Itemize
1824 \begin_inset Flex Code
1825 status collapsed
1826
1827 \begin_layout Plain Layout
1828  LaTeX Error: File 
1829 \begin_inset Quotes els
1830 \end_inset
1831
1832 Xxxx
1833 \begin_inset Quotes ers
1834 \end_inset
1835
1836  not found
1837 \end_layout
1838
1839 \end_inset
1840
1841
1842 \begin_inset Newline newline
1843 \end_inset
1844
1845 The file 
1846 \begin_inset Quotes eld
1847 \end_inset
1848
1849 Xxxx
1850 \begin_inset Quotes erd
1851 \end_inset
1852
1853  isn't installed on this system.
1854  This usually appears because some package your document needs isn't installed.
1855  If you didn't touch the preamble or didn't use the 
1856 \begin_inset Flex Code
1857 status collapsed
1858
1859 \begin_layout Plain Layout
1860
1861 \backslash
1862 usepackage{}
1863 \end_layout
1864
1865 \end_inset
1866
1867  command, then one of the packages LyX tried to load is missing.
1868  Use 
1869 \begin_inset Flex MenuItem
1870 status collapsed
1871
1872 \begin_layout Plain Layout
1873 Help\SpecialChar \menuseparator
1874 LaTeX Configuration
1875 \end_layout
1876
1877 \end_inset
1878
1879  to get a list of packages that LyX knows about.
1880  This file is updated whenever you reconfigure LyX (using 
1881 \begin_inset Flex MenuItem
1882 status collapsed
1883
1884 \begin_layout Plain Layout
1885 Tools\SpecialChar \menuseparator
1886 Reconfigure
1887 \end_layout
1888
1889 \end_inset
1890
1891 ) and tells you which packages have been detected and what they do.
1892 \begin_inset Newline newline
1893 \end_inset
1894
1895 If you did use the 
1896 \begin_inset Flex Code
1897 status collapsed
1898
1899 \begin_layout Plain Layout
1900
1901 \backslash
1902 usepackage{}
1903 \end_layout
1904
1905 \end_inset
1906
1907  command and the package in question isn't installed, then you'll need to
1908  install it yourself.
1909 \end_layout
1910
1911 \begin_layout Itemize
1912 \begin_inset Flex Code
1913 status collapsed
1914
1915 \begin_layout Plain Layout
1916 LaTeX Error: Unknown option
1917 \end_layout
1918
1919 \end_inset
1920
1921
1922 \begin_inset Newline newline
1923 \end_inset
1924
1925 Error messages beginning with this are trying to tell you that you specified
1926  a bad or undefined option to a package.
1927  Check the package's documentation.
1928 \end_layout
1929
1930 \begin_layout Itemize
1931 \begin_inset Flex Code
1932 status collapsed
1933
1934 \begin_layout Plain Layout
1935 Undefined control sequence
1936 \end_layout
1937
1938 \end_inset
1939
1940
1941 \begin_inset Newline newline
1942 \end_inset
1943
1944 If you've inserted LaTeX code into your document, but made a typo, you'll
1945  get one of these.
1946  You may have forgotten to load a package.
1947  In any case, this error message usually means that you used an undefined
1948  command.
1949  
1950 \end_layout
1951
1952 \begin_layout Standard
1953 There are other error and warning messages.
1954  Some are self-explanatory.
1955  These are usually LaTeX messages.
1956  Others are downright cryptic.
1957  These are usually TeX error messages, and we really have 
1958 \emph on
1959 no clue
1960 \emph default
1961  what they mean or how to decipher them.
1962  No-one does.
1963 \end_layout
1964
1965 \begin_layout Standard
1966 There's a general sequence you should follow if you get error messages:
1967 \end_layout
1968
1969 \begin_layout Enumerate
1970 Look at the LaTeX code you inserted for typos.
1971 \end_layout
1972
1973 \begin_layout Enumerate
1974 If there are no typos, check that you used the command(s) correctly.
1975 \end_layout
1976
1977 \begin_layout Enumerate
1978 If you get a bunch of error boxes piled up at the very top of the document—and
1979  especially if you see a 
1980 \begin_inset Quotes eld
1981 \end_inset
1982
1983
1984 \begin_inset Flex Code
1985 status collapsed
1986
1987 \begin_layout Plain Layout
1988 Missing 
1989 \backslash
1990 begin{document}
1991 \end_layout
1992
1993 \end_inset
1994
1995
1996 \begin_inset Quotes erd
1997 \end_inset
1998
1999  error—it means that there are errors in the preamble.
2000  Start debugging your preamble.
2001 \end_layout
2002
2003 \begin_layout Enumerate
2004 If you didn't add anything to the preamble and didn't add any LaTeX code
2005  to the document, the first suspect is your LaTeX distribution itself.
2006  Check for missing packages and install them.
2007 \end_layout
2008
2009 \begin_layout Enumerate
2010 Okay, so there are no missing packages.
2011  Did you use any of the fine-tuning options in LyX? Specifically, did you
2012  
2013 \emph on
2014 misuse
2015 \emph default
2016  any of them, like trying to manually insert lots of 
2017 \begin_inset Flex Code
2018 status collapsed
2019
2020 \begin_layout Plain Layout
2021 Protected
2022 \begin_inset space ~
2023 \end_inset
2024
2025 Blanks
2026 \end_layout
2027
2028 \end_inset
2029
2030
2031 \begin_inset Flex Code
2032 status collapsed
2033
2034 \begin_layout Plain Layout
2035 Linebreaks
2036 \end_layout
2037
2038 \end_inset
2039
2040 , or 
2041 \begin_inset Flex Code
2042 status collapsed
2043
2044 \begin_layout Plain Layout
2045 Pagebreaks
2046 \end_layout
2047
2048 \end_inset
2049
2050 ? Did you try to kludge something together with these instead of using the
2051  appropriate paragraph environment?
2052 \end_layout
2053
2054 \begin_layout Enumerate
2055 All right, you didn't use any of the fine-tuning options, you played by
2056  the rules.
2057  Did you try to pull a fancy maneuver? Did you do something funky inside
2058  a table or an equation, like inserting a graphic into a table cell?
2059 \end_layout
2060
2061 \begin_layout Enumerate
2062 Do you have long sections of text where LaTeX cannot find a place to break
2063  a line? By default, LaTeX is rather strict about how much extra inter-word
2064  spacing it will add in order to break a line.
2065  Preferably, you should rework the paragraph to avoid the problem.
2066  If this isn't an option, you can wrap your text in 
2067 \begin_inset Flex Code
2068 status collapsed
2069
2070 \begin_layout Plain Layout
2071
2072 \backslash
2073 sloppypar
2074 \end_layout
2075
2076 \end_inset
2077
2078  to make LaTeX's line breaking more, well, sloppy.
2079 \end_layout
2080
2081 \begin_layout Enumerate
2082 Did you go overboard with the nesting? LyX (currently) doesn't check to
2083  make sure you're in the limits for nesting environments.
2084  If you nested a bunch of environments to the 
2085 \begin_inset Formula $17^{\mathrm{th}}$
2086 \end_inset
2087
2088  level, that's the problem.
2089  (The limit in LaTeX is five.)
2090 \end_layout
2091
2092 \begin_layout Enumerate
2093 Okay, you didn't get any error messages, but your output looks awful.
2094  If you have a table or figure that's too wide or long for the page, you
2095  need to:
2096 \end_layout
2097
2098 \begin_deeper
2099 \begin_layout Enumerate
2100 rescale the figure so it fits.
2101 \end_layout
2102
2103 \begin_layout Enumerate
2104 trim down the table so it fits.
2105 \end_layout
2106
2107 \end_deeper
2108 \begin_layout Enumerate
2109 If something else is wrong with the output, and you didn't try to pull anything
2110  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2111 \end_layout
2112
2113 \begin_layout Standard
2114 If all this doesn't help—well, then 
2115 \emph on
2116 perhaps
2117 \emph default
2118  you might have found a bug in LyX\SpecialChar \ldots{}
2119 .
2120 \end_layout
2121
2122 \begin_layout Chapter
2123 Supplemental Tools
2124 \end_layout
2125
2126 \begin_layout Section
2127 Customizing Bibliographies with BibTeX
2128 \end_layout
2129
2130 \begin_layout Standard
2131 The most basic information about how to use BibTeX with LyX is contained
2132  in the section 
2133 \emph on
2134 Bibliography databases (BibTeX)
2135 \emph default
2136  of the 
2137 \emph on
2138 User's Guide
2139 \emph default
2140 .
2141  The following subsections explain special bibliography features supported
2142  by LyX.
2143 \end_layout
2144
2145 \begin_layout Subsection
2146 Alternative Citation Styles
2147 \end_layout
2148
2149 \begin_layout Standard
2150 Standard BibTeX uses numbers (e.
2151 \begin_inset space \thinspace{}
2152 \end_inset
2153
2154 g.
2155 \begin_inset space \space{}
2156 \end_inset
2157
2158
2159 \begin_inset Quotes eld
2160 \end_inset
2161
2162 [12]
2163 \begin_inset Quotes erd
2164 \end_inset
2165
2166 ) to refer to a cited work.
2167  However, in many scientific disciplines, other citation styles are in use.
2168  The most common one is the author-year style (e.
2169 \begin_inset space \thinspace{}
2170 \end_inset
2171
2172 g.
2173 \begin_inset space \space{}
2174 \end_inset
2175
2176
2177 \begin_inset Quotes eld
2178 \end_inset
2179
2180 Knuth 1984a
2181 \begin_inset Quotes erd
2182 \end_inset
2183
2184 ).
2185  LyX supports two packages that provide this style, 
2186 \begin_inset Flex Code
2187 status collapsed
2188
2189 \begin_layout Plain Layout
2190 natbib
2191 \end_layout
2192
2193 \end_inset
2194
2195  and 
2196 \begin_inset Flex Code
2197 status collapsed
2198
2199 \begin_layout Plain Layout
2200 jurabib
2201 \end_layout
2202
2203 \end_inset
2204
2205 .
2206  Both packages have their pros and cons, which cannot be listed in detail.
2207  If you only want to have simple author-year (or author-numerical) style,
2208  or if you want to use one of the countless style files for 
2209 \begin_inset Flex Code
2210 status collapsed
2211
2212 \begin_layout Plain Layout
2213 natbib
2214 \end_layout
2215
2216 \end_inset
2217
2218 , than the established 
2219 \begin_inset Flex Code
2220 status collapsed
2221
2222 \begin_layout Plain Layout
2223 natbib
2224 \end_layout
2225
2226 \end_inset
2227
2228  package is probably your choice.
2229  If you need special features like short title references, ibidem etc., you
2230  might consider the 
2231 \begin_inset Flex Code
2232 status collapsed
2233
2234 \begin_layout Plain Layout
2235 jurabib
2236 \end_layout
2237
2238 \end_inset
2239
2240  package.
2241 \end_layout
2242
2243 \begin_layout Standard
2244 The handling of both packages in LyX is basically the same.
2245  Go to 
2246 \begin_inset Flex MenuItem
2247 status collapsed
2248
2249 \begin_layout Plain Layout
2250 Document\SpecialChar \menuseparator
2251 Settings
2252 \end_layout
2253
2254 \end_inset
2255
2256  and select under 
2257 \begin_inset Flex MenuItem
2258 status collapsed
2259
2260 \begin_layout Plain Layout
2261 Bibliography
2262 \end_layout
2263
2264 \end_inset
2265
2266  the option 
2267 \begin_inset Flex MenuItem
2268 status collapsed
2269
2270 \begin_layout Plain Layout
2271 Natbib
2272 \end_layout
2273
2274 \end_inset
2275
2276  or 
2277 \begin_inset Flex MenuItem
2278 status collapsed
2279
2280 \begin_layout Plain Layout
2281 Jurabib
2282 \end_layout
2283
2284 \end_inset
2285
2286 .
2287  With both packages, you will get some extra features in the citation dialog
2288  and you can select the style of the reference (
2289 \begin_inset Quotes eld
2290 \end_inset
2291
2292 Knuth 1984
2293 \begin_inset Quotes erd
2294 \end_inset
2295
2296
2297 \begin_inset Quotes eld
2298 \end_inset
2299
2300 Knuth (1984)
2301 \begin_inset Quotes erd
2302 \end_inset
2303
2304
2305 \begin_inset Quotes eld
2306 \end_inset
2307
2308 Knuth, 1984
2309 \begin_inset Quotes erd
2310 \end_inset
2311
2312
2313 \begin_inset Quotes eld
2314 \end_inset
2315
2316 1984
2317 \begin_inset Quotes erd
2318 \end_inset
2319
2320  etc.).
2321  Note that both packages need specifically designed style files.
2322  They both ship their own, but there are lots of additional style files,
2323  and there is even an interactive style file builder
2324 \begin_inset Foot
2325 status collapsed
2326
2327 \begin_layout Plain Layout
2328 See 
2329 \begin_inset Flex URL
2330 status open
2331
2332 \begin_layout Plain Layout
2333
2334 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2335 \end_layout
2336
2337 \end_inset
2338
2339
2340 \end_layout
2341
2342 \end_inset
2343
2344  for 
2345 \begin_inset Flex Code
2346 status collapsed
2347
2348 \begin_layout Plain Layout
2349 natbib
2350 \end_layout
2351
2352 \end_inset
2353
2354 .
2355 \end_layout
2356
2357 \begin_layout Subsection
2358 Sectioned Bibliographies
2359 \end_layout
2360
2361 \begin_layout Standard
2362 Sometimes you might need to divide your bibliography into several sections.
2363  If you are for instance a historian, the possibility to separate sources
2364  and scientific works is most likely a 
2365 \begin_inset Quotes eld
2366 \end_inset
2367
2368 must have
2369 \begin_inset Quotes erd
2370 \end_inset
2371
2372 .
2373  Unfortunately, BibTeX itself does not allow you to do this.
2374  But with the help of some LaTeX packages, BibTeX can be extended to fit
2375  your needs.
2376 \end_layout
2377
2378 \begin_layout Standard
2379 LyX provides native support for one of these packages, 
2380 \family typewriter
2381 bibtopic
2382 \family default
2383 .
2384 \begin_inset Foot
2385 status collapsed
2386
2387 \begin_layout Plain Layout
2388 Available from 
2389 \begin_inset Flex URL
2390 status open
2391
2392 \begin_layout Plain Layout
2393
2394 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2395 \end_layout
2396
2397 \end_inset
2398
2399
2400 \end_layout
2401
2402 \end_inset
2403
2404  The advantage of this package (compared to other packages like 
2405 \family typewriter
2406 multibib
2407 \family default
2408 ) is that you don't need to define new citation commands.
2409  Instead, you need to prepare different bibliographic databases which include
2410  the entries for the different sections of the bibliography.
2411  For example: If you want to divide your bibliography into the sections
2412  
2413 \begin_inset Quotes eld
2414 \end_inset
2415
2416 Sources
2417 \begin_inset Quotes erd
2418 \end_inset
2419
2420  and 
2421 \begin_inset Quotes eld
2422 \end_inset
2423
2424 Scientific works
2425 \begin_inset Quotes erd
2426 \end_inset
2427
2428 , you first need to create two bibliographic databases, e.
2429 \begin_inset space \thinspace{}
2430 \end_inset
2431
2432 g.
2433 \begin_inset space \space{}
2434 \end_inset
2435
2436
2437 \begin_inset Flex Code
2438 status collapsed
2439
2440 \begin_layout Plain Layout
2441 sources.bib
2442 \end_layout
2443
2444 \end_inset
2445
2446  and 
2447 \begin_inset Flex Code
2448 status collapsed
2449
2450 \begin_layout Plain Layout
2451 scientific.bib
2452 \end_layout
2453
2454 \end_inset
2455
2456 .
2457  
2458 \end_layout
2459
2460 \begin_layout Standard
2461 Go to 
2462 \begin_inset Flex MenuItem
2463 status collapsed
2464
2465 \begin_layout Plain Layout
2466 Document\SpecialChar \menuseparator
2467 Settings
2468 \end_layout
2469
2470 \end_inset
2471
2472  and check under 
2473 \begin_inset Flex MenuItem
2474 status collapsed
2475
2476 \begin_layout Plain Layout
2477 Bibliography
2478 \end_layout
2479
2480 \end_inset
2481
2482  the option 
2483 \begin_inset Flex MenuItem
2484 status collapsed
2485
2486 \begin_layout Plain Layout
2487 Sectioned bibliography
2488 \end_layout
2489
2490 \end_inset
2491
2492 .
2493  Now you can insert multiple BibTeX bibliographies, one for each section
2494  of your bibliography.
2495  Returning to our example: Insert the BibTeX bibliography 
2496 \begin_inset Flex Code
2497 status collapsed
2498
2499 \begin_layout Plain Layout
2500 sources.bib
2501 \end_layout
2502
2503 \end_inset
2504
2505  and a second one for the database 
2506 \begin_inset Flex Code
2507 status collapsed
2508
2509 \begin_layout Plain Layout
2510 scientific.bib
2511 \end_layout
2512
2513 \end_inset
2514
2515 .
2516  You are free to use the same or different styles for each section.
2517  Additionally, you can chose if the bibliography section should contain
2518  
2519 \begin_inset Quotes eld
2520 \end_inset
2521
2522 all cited references
2523 \begin_inset Quotes erd
2524 \end_inset
2525
2526  of the specified database(s) (which is the default), 
2527 \begin_inset Quotes eld
2528 \end_inset
2529
2530 all uncited references
2531 \begin_inset Quotes erd
2532 \end_inset
2533
2534  or even 
2535 \begin_inset Quotes eld
2536 \end_inset
2537
2538 all references
2539 \begin_inset Quotes erd
2540 \end_inset
2541
2542 .
2543  This might be useful if you would like to separate your bibliography into
2544  three sections: 
2545 \begin_inset Quotes eld
2546 \end_inset
2547
2548 Cited sources
2549 \begin_inset Quotes erd
2550 \end_inset
2551
2552
2553 \begin_inset Quotes eld
2554 \end_inset
2555
2556 Uncited sources
2557 \begin_inset Quotes erd
2558 \end_inset
2559
2560 , and 
2561 \begin_inset Quotes eld
2562 \end_inset
2563
2564 Scientific works
2565 \begin_inset Quotes erd
2566 \end_inset
2567
2568 .
2569  The titles for the sections can be added as ordinary sections or subsections.
2570  Since 
2571 \begin_inset Flex Code
2572 status collapsed
2573
2574 \begin_layout Plain Layout
2575 bibtopic
2576 \end_layout
2577
2578 \end_inset
2579
2580  removes the bibliography title, you have manually re-add that, too (as
2581  a chapter* or section*, for instance).
2582 \end_layout
2583
2584 \begin_layout Subsection
2585 Multiple Bibliographies
2586 \end_layout
2587
2588 \begin_layout Standard
2589 Multiple bibliographies, e.
2590 \begin_inset space \thinspace{}
2591 \end_inset
2592
2593 g.
2594 \begin_inset space \space{}
2595 \end_inset
2596
2597 a bibliography for each section or chapter of the document, are not supported
2598  by BibTeX itself.
2599  But the 
2600 \begin_inset Flex Code
2601 status collapsed
2602
2603 \begin_layout Plain Layout
2604 bibtopic
2605 \end_layout
2606
2607 \end_inset
2608
2609  package, which is used for the creation of sectioned bibliographies in
2610  LyX (see the previous section), provides an easy way to solve this task,
2611  if you are willing to use some 
2612 \begin_inset Flex MenuItem
2613 status collapsed
2614
2615 \begin_layout Plain Layout
2616 TeX Code
2617 \end_layout
2618
2619 \end_inset
2620
2621  (see section
2622 \begin_inset space ~
2623 \end_inset
2624
2625
2626 \begin_inset CommandInset ref
2627 LatexCommand ref
2628 reference "sec:Inserting-TeX-Code"
2629
2630 \end_inset
2631
2632 ).
2633 \begin_inset Foot
2634 status collapsed
2635
2636 \begin_layout Plain Layout
2637 An alternative approach is to use the 
2638 \begin_inset Flex Code
2639 status collapsed
2640
2641 \begin_layout Plain Layout
2642 chapterbib
2643 \end_layout
2644
2645 \end_inset
2646
2647  or 
2648 \begin_inset Flex Code
2649 status collapsed
2650
2651 \begin_layout Plain Layout
2652 bibunits
2653 \end_layout
2654
2655 \end_inset
2656
2657  package, respectively.
2658 \end_layout
2659
2660 \end_inset
2661
2662
2663 \end_layout
2664
2665 \begin_layout Standard
2666 First go to 
2667 \begin_inset Flex MenuItem
2668 status collapsed
2669
2670 \begin_layout Plain Layout
2671 Document\SpecialChar \menuseparator
2672 Settings
2673 \end_layout
2674
2675 \end_inset
2676
2677  and under 
2678 \begin_inset Flex MenuItem
2679 status collapsed
2680
2681 \begin_layout Plain Layout
2682 Bibliography
2683 \end_layout
2684
2685 \end_inset
2686
2687  check 
2688 \begin_inset Flex MenuItem
2689 status collapsed
2690
2691 \begin_layout Plain Layout
2692 Sectioned bibliography
2693 \end_layout
2694
2695 \end_inset
2696
2697 .
2698  In the document, you have to enclose the sections, which shall contain
2699  their own bibliography (including the BibTeX bibliography itself), between
2700  
2701 \begin_inset Flex Code
2702 status collapsed
2703
2704 \begin_layout Plain Layout
2705
2706 \backslash
2707 begin{btUnit}
2708 \end_layout
2709
2710 \end_inset
2711
2712  and 
2713 \begin_inset Flex Code
2714 status collapsed
2715
2716 \begin_layout Plain Layout
2717
2718 \backslash
2719 end{btUnit}
2720 \end_layout
2721
2722 \end_inset
2723
2724  (those commands have to be inserted as TeX code).
2725  The bibliography will contain all references which have been cited in the
2726  current 
2727 \begin_inset Flex Code
2728 status collapsed
2729
2730 \begin_layout Plain Layout
2731 btUnit
2732 \end_layout
2733
2734 \end_inset
2735
2736 .
2737  
2738 \series bold
2739 Note:
2740 \series default
2741  If you are using this approach, then every citation reference has to be
2742  inside some 
2743 \begin_inset Flex Code
2744 status collapsed
2745
2746 \begin_layout Plain Layout
2747 btUnit
2748 \end_layout
2749
2750 \end_inset
2751
2752 .
2753  Also, the 
2754 \begin_inset Flex Code
2755 status collapsed
2756
2757 \begin_layout Plain Layout
2758 btUnit
2759 \end_layout
2760
2761 \end_inset
2762
2763 s cannot be nested.
2764 \end_layout
2765
2766 \begin_layout Section
2767 Multipart Documents
2768 \end_layout
2769
2770 \begin_layout Subsection
2771 General Operation
2772 \end_layout
2773
2774 \begin_layout Standard
2775 When you are working on a large file with many sections, it is often convenient
2776  to break up the document into several files, or perhaps you have something
2777  where a table may change from time to time, but the preceding text does
2778  not.
2779  In these cases, you should seriously consider using multipart documents.
2780  For example, scientific papers often have five major sections: the introduction
2781 , observations, results, discussion, and conclusion.
2782  Each of these could be its own separate LyX file, with one 
2783 \begin_inset Quotes eld
2784 \end_inset
2785
2786 master
2787 \begin_inset Quotes erd
2788 \end_inset
2789
2790  file which contains the title, authors, abstract, references, etc., plus
2791  the five included files.
2792  It is important to note that each of these files is a full LyX file which
2793  can be formatted and printed on its own, as well as included in a master
2794  file.
2795  Each of these files must have the same document class, however—don't attempt
2796  to mix book classes with article classes.
2797  You may also include LaTeX files; however, these files must not have their
2798  own preamble (i.
2799 \begin_inset space \thinspace{}
2800 \end_inset
2801
2802 g.
2803 \begin_inset space \space{}
2804 \end_inset
2805
2806 everything up to and including the 
2807 \begin_inset Flex Code
2808 status collapsed
2809
2810 \begin_layout Plain Layout
2811
2812 \backslash
2813 begin{document}
2814 \end_layout
2815
2816 \end_inset
2817
2818  line as well as the 
2819 \begin_inset Flex Code
2820 status collapsed
2821
2822 \begin_layout Plain Layout
2823
2824 \backslash
2825 end{document}
2826 \end_layout
2827
2828 \end_inset
2829
2830  line must be deleted) or else errors will be generated when you try to
2831  make a DVI file.
2832 \end_layout
2833
2834 \begin_layout Standard
2835 LyX allows you to include files quite easily with 
2836 \begin_inset Flex MenuItem
2837 status collapsed
2838
2839 \begin_layout Plain Layout
2840 Insert\SpecialChar \menuseparator
2841 ChiId
2842 \begin_inset space ~
2843 \end_inset
2844
2845 Document
2846 \end_layout
2847
2848 \end_inset
2849
2850 .
2851  When you click on this selection a small box is inserted into the file
2852  at the current cursor location.
2853  Clicking on the box raises a dialog which allows you to select the file
2854  to be included, and the method of its inclusion.
2855  
2856 \end_layout
2857
2858 \begin_layout Standard
2859 The file selection box should by now be obvious.
2860  The three inclusion methods are 
2861 \begin_inset Quotes eld
2862 \end_inset
2863
2864 include
2865 \begin_inset Quotes erd
2866 \end_inset
2867
2868
2869 \begin_inset Quotes eld
2870 \end_inset
2871
2872 input
2873 \begin_inset Quotes erd
2874 \end_inset
2875
2876 , and 
2877 \begin_inset Quotes eld
2878 \end_inset
2879
2880 verbatim
2881 \begin_inset Quotes erd
2882 \end_inset
2883
2884 .
2885  The difference between 
2886 \begin_inset Quotes eld
2887 \end_inset
2888
2889 include
2890 \begin_inset Quotes erd
2891 \end_inset
2892
2893  and 
2894 \begin_inset Quotes eld
2895 \end_inset
2896
2897 input
2898 \begin_inset Quotes erd
2899 \end_inset
2900
2901  is really only meaningful to LaTeXperts, but the practical difference is
2902  that files which are 
2903 \begin_inset Quotes eld
2904 \end_inset
2905
2906 included
2907 \begin_inset Quotes erd
2908 \end_inset
2909
2910  are typeset beginning on a new page, while files which are 
2911 \begin_inset Quotes eld
2912 \end_inset
2913
2914 inputted
2915 \begin_inset Quotes erd
2916 \end_inset
2917
2918  are typeset starting on the current page.
2919 \end_layout
2920
2921 \begin_layout Standard
2922 Generally, the master file is converted into a full LaTeX file before typesettin
2923 g, while the included files are converted to LaTeX files which do not have
2924  all the preamble information.
2925 \end_layout
2926
2927 \begin_layout Standard
2928
2929 \begin_inset Quotes eld
2930 \end_inset
2931
2932 verbatim
2933 \begin_inset Quotes erd
2934 \end_inset
2935
2936  included file allows you to include a file typeset exactly as it appears
2937  in the file, i.
2938 \begin_inset space \thinspace{}
2939 \end_inset
2940
2941 g.
2942 \begin_inset space \space{}
2943 \end_inset
2944
2945 in 
2946 \begin_inset Flex Code
2947 status collapsed
2948
2949 \begin_layout Plain Layout
2950 verbatim
2951 \end_layout
2952
2953 \end_inset
2954
2955  mode, with the characters set in a fixed-width typewriter font.
2956  Normally, spaces in this file are invisible, though two consecutive spaces
2957  are conserved, unlike LyX's normal treatment of spaces.
2958  However, setting the 
2959 \begin_inset Flex MenuItem
2960 status collapsed
2961
2962 \begin_layout Plain Layout
2963 Mark
2964 \begin_inset space ~
2965 \end_inset
2966
2967 spaces
2968 \begin_inset space ~
2969 \end_inset
2970
2971 in
2972 \begin_inset space ~
2973 \end_inset
2974
2975 output
2976 \end_layout
2977
2978 \end_inset
2979
2980  checkbox typesets a mark to unambiguously define the presence of a space.
2981  
2982 \end_layout
2983
2984 \begin_layout Subsection
2985 Cross-References Between Files
2986 \end_layout
2987
2988 \begin_layout Standard
2989 \begin_inset Box Shadowbox
2990 position "t"
2991 hor_pos "c"
2992 has_inner_box 1
2993 inner_pos "t"
2994 use_parbox 0
2995 use_makebox 0
2996 width "100col%"
2997 special "none"
2998 height "1in"
2999 height_special "totalheight"
3000 status open
3001
3002 \begin_layout Plain Layout
3003 This section is somewhat out of date.
3004  Need to describe default master documents and how children are opened when
3005  the master is.
3006  [[FIXME]]
3007 \end_layout
3008
3009 \end_inset
3010
3011
3012 \end_layout
3013
3014 \begin_layout Standard
3015 It is possible to set up cross-references between the different files.
3016  First, open all the files in question: let's call them A and B in a two
3017  file example, where B is included in A.
3018  Let's say you insert a label in A, then want to reference it in B.
3019  Open the cross-reference dialog in whilst in document B, and you can select
3020  the 
3021 \begin_inset Quotes eld
3022 \end_inset
3023
3024 buffer
3025 \begin_inset Quotes erd
3026 \end_inset
3027
3028  to use.
3029 \end_layout
3030
3031 \begin_layout Subsection
3032 Bibliography Lists in all Subdocuments
3033 \end_layout
3034
3035 \begin_layout Standard
3036 \begin_inset Box Frameless
3037 position "t"
3038 hor_pos "c"
3039 has_inner_box 1
3040 inner_pos "t"
3041 use_parbox 0
3042 use_makebox 0
3043 width "100col%"
3044 special "none"
3045 height "1in"
3046 height_special "totalheight"
3047 status open
3048
3049 \begin_layout Plain Layout
3050 This section also needs updating.
3051  There is now material about this on the wiki, and it could be copied here.
3052 \end_layout
3053
3054 \end_inset
3055
3056
3057 \end_layout
3058
3059 \begin_layout Standard
3060 Copy the bibliography list with all entries to all subdocuments and transform
3061  them to a comment.
3062  This way LyX will find the 
3063 \begin_inset Flex Code
3064 status collapsed
3065
3066 \begin_layout Plain Layout
3067 .bib
3068 \end_layout
3069
3070 \end_inset
3071
3072 -files and you can easily insert references without making the bibliography
3073  list visible.
3074 \end_layout
3075
3076 \begin_layout Standard
3077 As the bibliography list is in a comment, LaTeX won't use use it and the
3078  references will look like this: [?], instead of like this: [1].
3079  One solution is to use the LaTeX-package 
3080 \begin_inset Flex Code
3081 status collapsed
3082
3083 \begin_layout Plain Layout
3084 comment
3085 \end_layout
3086
3087 \end_inset
3088
3089  that will only include comments by processing the files separately.
3090  To do this, add in the LaTeX preamble of every subdocument the following:
3091 \end_layout
3092
3093 \begin_layout LyX-Code
3094
3095 \backslash
3096 usepackage{comment}
3097 \end_layout
3098
3099 \begin_layout LyX-Code
3100
3101 \backslash
3102 includecomment{comment}
3103 \end_layout
3104
3105 \begin_layout Standard
3106 See also 
3107 \begin_inset Flex URL
3108 status collapsed
3109
3110 \begin_layout Plain Layout
3111
3112 http://wiki.lyx.org/FAQ/Unsorted#toc31
3113 \end_layout
3114
3115 \end_inset
3116
3117 .
3118 \end_layout
3119
3120 \begin_layout Section
3121 LyX Archives
3122 \end_layout
3123
3124 \begin_layout Standard
3125 Users sometimes need to be able to 
3126 \begin_inset Quotes eld
3127 \end_inset
3128
3129 bundle
3130 \begin_inset Quotes erd
3131 \end_inset
3132
3133  a LyX file together with all the images (and other files) on which it depends,
3134  either for sending to a publisher or for sharing with a co-author.
3135  LyX 2.0 includes a Python script (
3136 \begin_inset Flex Code
3137 status collapsed
3138
3139 \begin_layout Plain Layout
3140 lyxpak.py
3141 \end_layout
3142
3143 \end_inset
3144
3145 ) that automates this process.
3146  To use it, you must have either the 
3147 \begin_inset Flex Code
3148 status collapsed
3149
3150 \begin_layout Plain Layout
3151 zipfile
3152 \end_layout
3153
3154 \end_inset
3155
3156  or 
3157 \begin_inset Flex Code
3158 status collapsed
3159
3160 \begin_layout Plain Layout
3161 tarfile
3162 \end_layout
3163
3164 \end_inset
3165
3166  python modules installed on your system.
3167  By default, the script prefers the 
3168 \begin_inset Flex Code
3169 status collapsed
3170
3171 \begin_layout Plain Layout
3172 gzip
3173 \end_layout
3174
3175 \end_inset
3176
3177 -compressed 
3178 \begin_inset Flex Code
3179 status collapsed
3180
3181 \begin_layout Plain Layout
3182 tar
3183 \end_layout
3184
3185 \end_inset
3186
3187  format on Unix-like systems and the 
3188 \begin_inset Flex Code
3189 status collapsed
3190
3191 \begin_layout Plain Layout
3192 zip
3193 \end_layout
3194
3195 \end_inset
3196
3197  format on Windows.
3198 \end_layout
3199
3200 \begin_layout Standard
3201 LyX's configuration process will set the script up to export a `LyX Archive',
3202  and this format will then be available under 
3203 \begin_inset Flex Code
3204 status collapsed
3205
3206 \begin_layout Plain Layout
3207 File\SpecialChar \menuseparator
3208 Export
3209 \end_layout
3210
3211 \end_inset
3212
3213 .
3214 \end_layout
3215
3216 \begin_layout Standard
3217 Independently of the platform, the generation of a particular archive format
3218  can be forced by adding either the 
3219 \begin_inset Flex Code
3220 status collapsed
3221
3222 \begin_layout Plain Layout
3223 -t
3224 \end_layout
3225
3226 \end_inset
3227
3228  (for the 
3229 \begin_inset Flex Code
3230 status collapsed
3231
3232 \begin_layout Plain Layout
3233 tar
3234 \end_layout
3235
3236 \end_inset
3237
3238  format) or 
3239 \begin_inset Flex Code
3240 status collapsed
3241
3242 \begin_layout Plain Layout
3243 -z
3244 \end_layout
3245
3246 \end_inset
3247
3248  (for the 
3249 \begin_inset Flex Code
3250 status collapsed
3251
3252 \begin_layout Plain Layout
3253 zip
3254 \end_layout
3255
3256 \end_inset
3257
3258  format) switch to the 
3259 \begin_inset Flex Code
3260 status collapsed
3261
3262 \begin_layout Plain Layout
3263 LyX\SpecialChar \menuseparator
3264 LyX Archive
3265 \end_layout
3266
3267 \end_inset
3268
3269  converter in 
3270 \begin_inset Flex Code
3271 status collapsed
3272
3273 \begin_layout Plain Layout
3274 Tools\SpecialChar \menuseparator
3275 Preferences\SpecialChar \menuseparator
3276 File Handling\SpecialChar \menuseparator
3277 Converters
3278 \end_layout
3279
3280 \end_inset
3281
3282 .
3283  (Make sure you add the switch after the script name, not before it.)
3284 \end_layout
3285
3286 \begin_layout Section
3287 Fancy Headers and Footers
3288 \end_layout
3289
3290 \begin_layout Standard
3291 The default page layout is rather plain; for an 
3292 \begin_inset Flex Code
3293 status collapsed
3294
3295 \begin_layout Plain Layout
3296 article
3297 \end_layout
3298
3299 \end_inset
3300
3301  document class, all you get is a centered page number at the bottom of
3302  the page.
3303  This document uses KOMA-script's book class, so it appears to be a bit
3304  fancier.
3305  But to really put on a show, you need to set the document page style to
3306  
3307 \begin_inset Quotes eld
3308 \end_inset
3309
3310 fancy
3311 \begin_inset Quotes erd
3312 \end_inset
3313
3314 , as mentioned in the 
3315 \emph on
3316 User Guide
3317 \emph default
3318 .
3319  This section describes the LaTeX code you need to insert in your LaTeX
3320  preamble in order to get the desired effects.
3321 \end_layout
3322
3323 \begin_layout Standard
3324 For more information on fancy headers, see the 
3325 \begin_inset Flex Code
3326 status collapsed
3327
3328 \begin_layout Plain Layout
3329 fancyhdr
3330 \end_layout
3331
3332 \end_inset
3333
3334  package documentation.
3335  (
3336 \begin_inset Flex URL
3337 status collapsed
3338
3339 \begin_layout Plain Layout
3340
3341 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
3342 \end_layout
3343
3344 \end_inset
3345
3346 )
3347 \end_layout
3348
3349 \begin_layout Standard
3350 The page header is divided into three fields, not surprisingly labeled 
3351 \begin_inset Quotes eld
3352 \end_inset
3353
3354 left
3355 \begin_inset Quotes erd
3356 \end_inset
3357
3358
3359 \begin_inset Quotes eld
3360 \end_inset
3361
3362 center
3363 \begin_inset Quotes erd
3364 \end_inset
3365
3366 , and 
3367 \begin_inset Quotes eld
3368 \end_inset
3369
3370 right
3371 \begin_inset Quotes erd
3372 \end_inset
3373
3374 .
3375  The footer is also divided into these three fields.
3376  The LaTeX commands to set these fields in the simplest manner are 
3377 \begin_inset Flex Code
3378 status collapsed
3379
3380 \begin_layout Plain Layout
3381
3382 \backslash
3383 lhead
3384 \end_layout
3385
3386 \end_inset
3387
3388
3389 \begin_inset Flex Code
3390 status collapsed
3391
3392 \begin_layout Plain Layout
3393
3394 \backslash
3395 chead
3396 \end_layout
3397
3398 \end_inset
3399
3400
3401 \begin_inset Flex Code
3402 status collapsed
3403
3404 \begin_layout Plain Layout
3405
3406 \backslash
3407 rhead
3408 \end_layout
3409
3410 \end_inset
3411
3412
3413 \begin_inset Flex Code
3414 status collapsed
3415
3416 \begin_layout Plain Layout
3417
3418 \backslash
3419 lfoot
3420 \end_layout
3421
3422 \end_inset
3423
3424 , etc.
3425  Suppose you wish to put your name in the upper left hand corner of each
3426  page.
3427  Simply insert the following command in the preamble: 
3428 \end_layout
3429
3430 \begin_layout Standard
3431
3432 \family typewriter
3433
3434 \backslash
3435 lhead{John Q.
3436  DocWriter}
3437 \end_layout
3438
3439 \begin_layout Standard
3440 You will now see your name in the upper left.
3441  If a field has a default entry that you would like to get rid of (often
3442  the page number appears in the central footer, simply include a command
3443  with a blank argument, e.
3444 \begin_inset space \thinspace{}
3445 \end_inset
3446
3447 g.:
3448 \end_layout
3449
3450 \begin_layout Standard
3451
3452 \family typewriter
3453
3454 \backslash
3455 cfoot{}
3456 \end_layout
3457
3458 \begin_layout Standard
3459 Let's get really fancy: lets put the section number with the word 
3460 \begin_inset Quotes eld
3461 \end_inset
3462
3463 Section
3464 \begin_inset Quotes erd
3465 \end_inset
3466
3467  (e.
3468 \begin_inset space \thinspace{}
3469 \end_inset
3470
3471 g.
3472 \begin_inset space \space{}
3473 \end_inset
3474
3475 Section 3) in the upper left, the page number (e.
3476 \begin_inset space \thinspace{}
3477 \end_inset
3478
3479 g.
3480 \begin_inset space \space{}
3481 \end_inset
3482
3483 Page 4) in the upper right, your name in the lower left, and the date in
3484  the lower right.
3485  The following commands should now appear in the preamble:
3486 \end_layout
3487
3488 \begin_layout Standard
3489
3490 \family typewriter
3491
3492 \backslash
3493 lhead{Section 
3494 \backslash
3495 thesection}
3496 \end_layout
3497
3498 \begin_layout Standard
3499
3500 \family typewriter
3501
3502 \backslash
3503 chead{}
3504 \end_layout
3505
3506 \begin_layout Standard
3507
3508 \family typewriter
3509
3510 \backslash
3511 rhead{Page 
3512 \backslash
3513 thepage}
3514 \end_layout
3515
3516 \begin_layout Standard
3517
3518 \family typewriter
3519
3520 \backslash
3521 lfoot{John Q.
3522  DocWriter}
3523 \end_layout
3524
3525 \begin_layout Standard
3526
3527 \family typewriter
3528
3529 \backslash
3530 cfoot{}
3531 \end_layout
3532
3533 \begin_layout Standard
3534
3535 \family typewriter
3536
3537 \backslash
3538 rfoot{
3539 \backslash
3540 today}
3541 \end_layout
3542
3543 \begin_layout Standard
3544 The commands 
3545 \begin_inset Flex Code
3546 status collapsed
3547
3548 \begin_layout Plain Layout
3549
3550 \backslash
3551 thesection
3552 \end_layout
3553
3554 \end_inset
3555
3556  and 
3557 \begin_inset Flex Code
3558 status collapsed
3559
3560 \begin_layout Plain Layout
3561
3562 \backslash
3563 thepage
3564 \end_layout
3565
3566 \end_inset
3567
3568  access LaTeX's section and page counters, and so print out the current
3569  section and page numbers.
3570  
3571 \begin_inset Flex Code
3572 status collapsed
3573
3574 \begin_layout Plain Layout
3575
3576 \backslash
3577 today
3578 \end_layout
3579
3580 \end_inset
3581
3582  simply prints out today's date.
3583 \end_layout
3584
3585 \begin_layout Standard
3586 The thicknesses of the horizontal rules drawn beneath the header and above
3587  the footer can also be modified.
3588  If you don't want one of the rules, set its thickness to 0.
3589  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
3590  Use commands
3591 \family typewriter
3592  
3593 \family default
3594 like 
3595 \begin_inset Flex Code
3596 status collapsed
3597
3598 \begin_layout Plain Layout
3599
3600 \backslash
3601 renewcommand{
3602 \backslash
3603 headrulewidth}{0.4pt}
3604 \end_layout
3605
3606 \end_inset
3607
3608  and 
3609 \begin_inset Flex Code
3610 status collapsed
3611
3612 \begin_layout Plain Layout
3613
3614 \backslash
3615 renewcommand{
3616 \backslash
3617 footrulewidth}{0.4pt}
3618 \end_layout
3619
3620 \end_inset
3621
3622  to set the thicknesses.
3623 \end_layout
3624
3625 \begin_layout Standard
3626 You can switch the header/footer settings on and off for individual pages
3627  using commands like 
3628 \begin_inset Flex Code
3629 status collapsed
3630
3631 \begin_layout Plain Layout
3632
3633 \backslash
3634 thispagestyle{empty}
3635 \end_layout
3636
3637 \end_inset
3638
3639
3640 \begin_inset Flex Code
3641 status collapsed
3642
3643 \begin_layout Plain Layout
3644
3645 \backslash
3646 thispagestyle{plain}
3647 \end_layout
3648
3649 \end_inset
3650
3651 , and 
3652 \begin_inset Flex Code
3653 status collapsed
3654
3655 \begin_layout Plain Layout
3656
3657 \backslash
3658 thispagestyle{fancy}
3659 \end_layout
3660
3661 \end_inset
3662
3663 .
3664  Simply insert them in the text on the page you want changed and mark them
3665  as TeX code.
3666  In fact, title pages are marked as plain by default, while following pages
3667  are marked fancy when using the global fancy setting.
3668 \end_layout
3669
3670 \begin_layout Standard
3671 As a final example, it is possible to include an image in the header or
3672  footer.
3673  Suppose you want to put a company logo in the upper lefthand corner.
3674  You might try something like
3675 \end_layout
3676
3677 \begin_layout Standard
3678
3679 \family typewriter
3680
3681 \backslash
3682 lhead{
3683 \backslash
3684 resizebox{1in}{!}{
3685 \backslash
3686 includegraphics{logo.eps}}}
3687 \end_layout
3688
3689 \begin_layout Standard
3690 \noindent
3691 (you may need to preface this with 
3692 \begin_inset Flex Code
3693 status collapsed
3694
3695 \begin_layout Plain Layout
3696 \noindent
3697
3698 \backslash
3699 usepackage{graphics}
3700 \end_layout
3701
3702 \end_inset
3703
3704  if you don't include graphics elsewhere in your document).
3705 \end_layout
3706
3707 \begin_layout Section
3708 Itemize Bullet Selection
3709 \begin_inset CommandInset label
3710 LatexCommand label
3711 name "sec:bullet"
3712
3713 \end_inset
3714
3715
3716 \end_layout
3717
3718 \begin_layout Standard
3719 by
3720 \noun on
3721  Allan Rae
3722 \end_layout
3723
3724 \begin_layout Subsection
3725 Introduction
3726 \end_layout
3727
3728 \begin_layout Standard
3729 LyX provides 216 bullet shapes that can be accessed from a simple dialog.
3730  Using this dialog you can easily specify what bullet shape to use at each
3731  level of an itemized list.
3732  These settings are document-wide so you won't be able to specify different
3733  sets of bullets for different paragraphs.
3734 \begin_inset Foot
3735 status collapsed
3736
3737 \begin_layout Plain Layout
3738 Well, actually you can but you'll have to do it by hand.
3739 \end_layout
3740
3741 \end_inset
3742
3743
3744 \end_layout
3745
3746 \begin_layout Subsection
3747 How it looks
3748 \end_layout
3749
3750 \begin_layout Standard
3751 Open the dialog by selecting the 
3752 \begin_inset Flex MenuItem
3753 status collapsed
3754
3755 \begin_layout Plain Layout
3756 Document\SpecialChar \menuseparator
3757 Settings
3758 \end_layout
3759
3760 \end_inset
3761
3762  menu item and then select the 
3763 \begin_inset Flex MenuItem
3764 status collapsed
3765
3766 \begin_layout Plain Layout
3767 Bullets
3768 \end_layout
3769
3770 \end_inset
3771
3772  tab.
3773 \end_layout
3774
3775 \begin_layout Standard
3776 The dialog provides you with a table of bullet shapes.
3777  A column of buttons on the left of the table provides access to the six
3778  different panels of bullet shapes.
3779  The row of buttons across the top is used to select which bullet depth
3780  you are changing.
3781  A text entry under the table shows the currently selected bullet shape's
3782  LaTeX equivalent and this can be edited if desired.
3783  If you do modify the text you will also need to specify any needed packages
3784  in the LaTeX preamble.
3785 \end_layout
3786
3787 \begin_layout Standard
3788 The six panels are divided up by the packages they require.
3789  The following table shows the mappings from button name to LaTeX packages.
3790 \end_layout
3791
3792 \begin_layout Standard
3793 \align center
3794 \begin_inset Tabular
3795 <lyxtabular version="3" rows="7" columns="2">
3796 <features tabularvalignment="middle">
3797 <column alignment="center" valignment="top" width="0pt">
3798 <column alignment="center" valignment="top" width="0pt">
3799 <row>
3800 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3801 \begin_inset Text
3802
3803 \begin_layout Plain Layout
3804
3805 \family roman
3806 \series medium
3807 \shape up
3808 \size normal
3809 \emph off
3810 \bar no
3811 \noun off
3812 \color none
3813 Button
3814 \end_layout
3815
3816 \end_inset
3817 </cell>
3818 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3819 \begin_inset Text
3820
3821 \begin_layout Plain Layout
3822
3823 \family roman
3824 \series medium
3825 \shape up
3826 \size normal
3827 \emph off
3828 \bar no
3829 \noun off
3830 \color none
3831 Packages Required
3832 \end_layout
3833
3834 \end_inset
3835 </cell>
3836 </row>
3837 <row>
3838 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3839 \begin_inset Text
3840
3841 \begin_layout Plain Layout
3842
3843 \family sans
3844 \series medium
3845 \shape up
3846 \size normal
3847 \emph off
3848 \bar no
3849 \noun off
3850 \color none
3851 Standard
3852 \end_layout
3853
3854 \end_inset
3855 </cell>
3856 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3857 \begin_inset Text
3858
3859 \begin_layout Plain Layout
3860
3861 \series medium
3862 \shape up
3863 \size normal
3864 \emph off
3865 \bar no
3866 \noun off
3867 \color none
3868 base LaTeX
3869 \end_layout
3870
3871 \end_inset
3872 </cell>
3873 </row>
3874 <row>
3875 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3876 \begin_inset Text
3877
3878 \begin_layout Plain Layout
3879
3880 \family sans
3881 \series medium
3882 \shape up
3883 \size normal
3884 \emph off
3885 \bar no
3886 \noun off
3887 \color none
3888 Maths
3889 \end_layout
3890
3891 \end_inset
3892 </cell>
3893 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3894 \begin_inset Text
3895
3896 \begin_layout Plain Layout
3897
3898 \family typewriter
3899 \series medium
3900 \shape up
3901 \size normal
3902 \emph off
3903 \bar no
3904 \noun off
3905 \color none
3906 amssymb.sty
3907 \end_layout
3908
3909 \end_inset
3910 </cell>
3911 </row>
3912 <row>
3913 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3914 \begin_inset Text
3915
3916 \begin_layout Plain Layout
3917
3918 \family sans
3919 \series medium
3920 \shape up
3921 \size normal
3922 \emph off
3923 \bar no
3924 \noun off
3925 \color none
3926 Ding1
3927 \end_layout
3928
3929 \end_inset
3930 </cell>
3931 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3932 \begin_inset Text
3933
3934 \begin_layout Plain Layout
3935
3936 \family typewriter
3937 \series medium
3938 \shape up
3939 \size normal
3940 \emph off
3941 \bar no
3942 \noun off
3943 \color none
3944 pifont.sty
3945 \end_layout
3946
3947 \end_inset
3948 </cell>
3949 </row>
3950 <row>
3951 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3952 \begin_inset Text
3953
3954 \begin_layout Plain Layout
3955
3956 \family sans
3957 \series medium
3958 \shape up
3959 \size normal
3960 \emph off
3961 \bar no
3962 \noun off
3963 \color none
3964 Ding2
3965 \end_layout
3966
3967 \end_inset
3968 </cell>
3969 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3970 \begin_inset Text
3971
3972 \begin_layout Plain Layout
3973
3974 \family typewriter
3975 \series medium
3976 \shape up
3977 \size normal
3978 \emph off
3979 \bar no
3980 \noun off
3981 \color none
3982 pifont.sty
3983 \end_layout
3984
3985 \end_inset
3986 </cell>
3987 </row>
3988 <row>
3989 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3990 \begin_inset Text
3991
3992 \begin_layout Plain Layout
3993
3994 \family sans
3995 \series medium
3996 \shape up
3997 \size normal
3998 \emph off
3999 \bar no
4000 \noun off
4001 \color none
4002 Ding3
4003 \end_layout
4004
4005 \end_inset
4006 </cell>
4007 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4008 \begin_inset Text
4009
4010 \begin_layout Plain Layout
4011
4012 \family typewriter
4013 \series medium
4014 \shape up
4015 \size normal
4016 \emph off
4017 \bar no
4018 \noun off
4019 \color none
4020 pifont.sty
4021 \end_layout
4022
4023 \end_inset
4024 </cell>
4025 </row>
4026 <row>
4027 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4028 \begin_inset Text
4029
4030 \begin_layout Plain Layout
4031
4032 \family sans
4033 \series medium
4034 \shape up
4035 \size normal
4036 \emph off
4037 \bar no
4038 \noun off
4039 \color none
4040 Ding4
4041 \end_layout
4042
4043 \end_inset
4044 </cell>
4045 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4046 \begin_inset Text
4047
4048 \begin_layout Plain Layout
4049
4050 \family typewriter
4051 \series medium
4052 \shape up
4053 \size normal
4054 \emph off
4055 \bar no
4056 \noun off
4057 \color none
4058 pifont.sty
4059 \end_layout
4060
4061 \end_inset
4062 </cell>
4063 </row>
4064 </lyxtabular>
4065
4066 \end_inset
4067
4068
4069 \end_layout
4070
4071 \begin_layout Standard
4072 LyX doesn't stop you using bullets from packages you don't have.
4073  If you get errors from LaTeX when you try to view or print the file, then
4074  it is likely you are missing a package.
4075 \begin_inset Foot
4076 status collapsed
4077
4078 \begin_layout Plain Layout
4079 LyX doesn't restrict your use since you may be editing locally and exporting
4080  elsewhere.
4081 \end_layout
4082
4083 \end_inset
4084
4085
4086 \end_layout
4087
4088 \begin_layout Subsection
4089 How to use it
4090 \end_layout
4091
4092 \begin_layout Standard
4093 Select which bullet depth you want to change then select the bullet shape
4094  and size.
4095  Any changes will not be visible in LyX, but are visible when viewing the
4096  document.
4097 \end_layout
4098
4099 \begin_layout Standard
4100 You can reset a bullet shape to the default simply by clicking your right
4101  mouse button on the appropriate bullet depth button.
4102 \begin_inset Foot
4103 status collapsed
4104
4105 \begin_layout Plain Layout
4106 If you 
4107 \emph on
4108 really
4109 \emph default
4110  want to have multiple sets of paragraphs with different sets of bullets
4111  in each, then you're going to have to get your hands dirty with TeX code.
4112  The bullet selection dialog can help though because it provides you with
4113  the LaTeX code for a wide range of bullet shapes.
4114  To make your own custom paragraphs you have the following options:
4115 \end_layout
4116
4117 \begin_layout Plain Layout
4118 \begin_inset ERT
4119 status open
4120
4121 \begin_layout Plain Layout
4122
4123
4124 \backslash
4125 let
4126 \backslash
4127 savelabelitemi=
4128 \backslash
4129 labelitemi
4130 \end_layout
4131
4132 \end_inset
4133
4134
4135 \end_layout
4136
4137 \begin_layout Plain Layout
4138 \begin_inset ERT
4139 status open
4140
4141 \begin_layout Plain Layout
4142
4143
4144 \backslash
4145 renewcommand
4146 \backslash
4147 labelitemi[0]{
4148 \backslash
4149 small
4150 \backslash
4151 (
4152 \backslash
4153 sharp
4154 \backslash
4155 )}
4156 \end_layout
4157
4158 \end_inset
4159
4160
4161 \end_layout
4162
4163 \begin_layout Itemize
4164 Use the LaTeX command 
4165 \begin_inset Flex Code
4166 status collapsed
4167
4168 \begin_layout Plain Layout
4169
4170 \backslash
4171 renewcommand{}{}
4172 \end_layout
4173
4174 \end_inset
4175
4176  to specify a new bullet shape for a given depth.
4177  You'll also need to save the current bullet shape so you can restore it
4178  again afterwards.
4179  In this itemized list the following LaTeX code was used to change the bullet
4180  used for the first depth.
4181 \end_layout
4182
4183 \begin_deeper
4184 \begin_layout LyX-Code
4185
4186 \backslash
4187 let
4188 \backslash
4189 savelabelitemi=
4190 \backslash
4191 labelitemi 
4192 \end_layout
4193
4194 \begin_layout LyX-Code
4195
4196 \backslash
4197 renewcommand
4198 \backslash
4199 labelitemi[0]{
4200 \backslash
4201 small
4202 \backslash
4203 (
4204 \backslash
4205 sharp
4206 \backslash
4207 )}
4208 \end_layout
4209
4210 \end_deeper
4211 \begin_layout Itemize
4212 Note that the itemize depth is specified in Roman numerals as part of the
4213  
4214 \family typewriter
4215
4216 \backslash
4217 labelitem
4218 \family default
4219  command.
4220 \end_layout
4221
4222 \begin_layout Itemize
4223 \begin_inset ERT
4224 status open
4225
4226 \begin_layout Plain Layout
4227
4228 [
4229 \backslash
4230 (
4231 \backslash
4232 star
4233 \backslash
4234 )]
4235 \end_layout
4236
4237 \end_inset
4238
4239  Specify each individual entry by starting each item with the bullet shape
4240  enclosed in square brackets and set as 
4241 \begin_inset Flex MenuItem
4242 status collapsed
4243
4244 \begin_layout Plain Layout
4245 TeX Code
4246 \end_layout
4247
4248 \end_inset
4249
4250 .
4251  For example, this item was started with 
4252 \begin_inset Flex Code
4253 status collapsed
4254
4255 \begin_layout Plain Layout
4256 [
4257 \backslash
4258 (
4259 \backslash
4260 star
4261 \backslash
4262 )]
4263 \end_layout
4264
4265 \end_inset
4266
4267 .
4268 \end_layout
4269
4270 \begin_layout Plain Layout
4271 \begin_inset ERT
4272 status open
4273
4274 \begin_layout Plain Layout
4275
4276
4277 \backslash
4278 renewcommand
4279 \backslash
4280 labelitemi[0]{
4281 \backslash
4282 savelabelitemi}
4283 \end_layout
4284
4285 \end_inset
4286
4287
4288 \end_layout
4289
4290 \begin_layout Plain Layout
4291 You'll also need to revert the labelitem back to its previous setting for
4292  the global bullet shape settings to remain in effect.
4293  The way used here was:
4294 \end_layout
4295
4296 \begin_layout LyX-Code
4297
4298 \backslash
4299 renewcommand
4300 \backslash
4301 labelitemi[0]{
4302 \backslash
4303 savelabelitemi}
4304 \end_layout
4305
4306 \end_inset
4307
4308
4309 \end_layout
4310
4311 \begin_layout Chapter
4312 LyX and the World Wide Web
4313 \end_layout
4314
4315 \begin_layout Standard
4316 LyX has long supported the export of documents to various web-friendly formats,
4317  such as HTML.
4318  Before verson 2.0, however, HTML export was always accomplished by the use
4319  of external converters.
4320 \begin_inset Foot
4321 status collapsed
4322
4323 \begin_layout Plain Layout
4324 For details on the use of external converters with LyX, see the 
4325 \emph on
4326 Converters
4327 \emph default
4328  section of the Customization manual.
4329 \end_layout
4330
4331 \end_inset
4332
4333  These fall into two large groups: there are converters that use LaTeX as
4334  an intermediate format, such as 
4335 \begin_inset Flex Code
4336 status collapsed
4337
4338 \begin_layout Plain Layout
4339 htlatex
4340 \end_layout
4341
4342 \end_inset
4343
4344
4345 \begin_inset Flex Code
4346 status collapsed
4347
4348 \begin_layout Plain Layout
4349 html2latex
4350 \end_layout
4351
4352 \end_inset
4353
4354 , and 
4355 \begin_inset Flex Code
4356 status collapsed
4357
4358 \begin_layout Plain Layout
4359 plastex
4360 \end_layout
4361
4362 \end_inset
4363
4364 , relying upon LyX to produce the LaTeX; and there is a converter that works
4365  directly on LyX files, 
4366 \begin_inset Flex Code
4367 status collapsed
4368
4369 \begin_layout Plain Layout
4370 eLyXer
4371 \end_layout
4372
4373 \end_inset
4374
4375 .
4376  All of these have different advantages and disadvantages.
4377  
4378 \end_layout
4379
4380 \begin_layout Standard
4381 The LaTeX-based converters have the advantage that, in principle, they know
4382  everything about the exported document that LaTeX does.
4383  Such converters do not care, for example, if a certain block of code was
4384  produced by LyX or was Evil Red Text.
4385  These converters know about 
4386 \begin_inset Flex Code
4387 status collapsed
4388
4389 \begin_layout Plain Layout
4390 aux
4391 \end_layout
4392
4393 \end_inset
4394
4395  files, counters, and references, and can often make use of the 
4396 \begin_inset Flex Code
4397 status collapsed
4398
4399 \begin_layout Plain Layout
4400 bbl
4401 \end_layout
4402
4403 \end_inset
4404
4405  files generated by BibTeX.
4406  On the other hand, LaTeX is a very hard language to parse---it is sometimes
4407  said that only TeX itself understands TeX---and LaTeX-based converters
4408  will often choke on what seem to be quite simple constructs; complex ones
4409  can throw them completely, and as of this writing, for example, the 
4410 \emph on
4411 Embedded Objects
4412 \emph default
4413  manual will not export with 
4414 \begin_inset Flex Code
4415 status collapsed
4416
4417 \begin_layout Plain Layout
4418 htlatex
4419 \end_layout
4420
4421 \end_inset
4422
4423 , though the others will.
4424  The other issue concerns how math is handled.
4425  These converters typically convert the formulae into little pictures that
4426  are then linked from the HTML document.
4427  Since these are actually generated by LaTeX, they are accurate.
4428  But they do not scale well, and just getting them to look as if they are
4429  actually meant to be in your document---so that the font sizes seem to
4430  be roughly the same---can be a challenge.
4431 \end_layout
4432
4433 \begin_layout Standard
4434 Alex Fernandez's 
4435 \begin_inset Flex Code
4436 status collapsed
4437
4438 \begin_layout Plain Layout
4439 eLyXer
4440 \end_layout
4441
4442 \end_inset
4443
4444  (
4445 \begin_inset CommandInset href
4446 LatexCommand href
4447 name "http://elyxer.nongnu.org/"
4448 target "http://elyxer.nongnu.org/"
4449
4450 \end_inset
4451
4452 ) solves some of these problems.
4453  In particular, the formulae it produces scale perfectly, since it renders
4454  math using a combination of HTML and CSS rather than converting the formulae
4455  to images.
4456  But even moderately complex formula are rendered less well than with 
4457 \begin_inset Flex Code
4458 status collapsed
4459
4460 \begin_layout Plain Layout
4461 htlatex
4462 \end_layout
4463
4464 \end_inset
4465
4466 ; this reflects the limitations of HTML.
4467 \begin_inset Foot
4468 status collapsed
4469
4470 \begin_layout Plain Layout
4471 That said, 
4472 \begin_inset Flex Code
4473 status collapsed
4474
4475 \begin_layout Plain Layout
4476 eLyXer
4477 \end_layout
4478
4479 \end_inset
4480
4481  can also use jsMath and MathJax for equations, but this setting is only
4482  available globally and requires one to have access to a server that runs
4483  the backend.
4484 \end_layout
4485
4486 \end_inset
4487
4488  More importantly (as of version 1.1.1, at least), 
4489 \begin_inset Flex Code
4490 status collapsed
4491
4492 \begin_layout Plain Layout
4493 eLyXer
4494 \end_layout
4495
4496 \end_inset
4497
4498  has limited support for math macros and no support for user-defined paragraph
4499  or character styles.
4500  These limitations make 
4501 \begin_inset Flex Code
4502 status collapsed
4503
4504 \begin_layout Plain Layout
4505 eLyXer
4506 \end_layout
4507
4508 \end_inset
4509
4510  unsuitable for many of the documents LyX users produce.
4511  In principle, of course, these problems could be solved, but the LyX developers
4512  have decided to follow a different path and have made LyX itself capable
4513  of writing XHTML, just as it is capable of writing LaTeX, DocBook, and
4514  plaintext.
4515 \end_layout
4516
4517 \begin_layout Standard
4518 As of this writing, XHTML output remains under development and should probably
4519  be regarded as 
4520 \begin_inset Quotes eld
4521 \end_inset
4522
4523 experimental
4524 \begin_inset Quotes erd
4525 \end_inset
4526
4527 .
4528 \begin_inset Foot
4529 status collapsed
4530
4531 \begin_layout Plain Layout
4532 The file 
4533 \begin_inset Flex Code
4534 status collapsed
4535
4536 \begin_layout Plain Layout
4537 development/HTML.notes
4538 \end_layout
4539
4540 \end_inset
4541
4542 , which can be found in the LyX source tree or 
4543 \begin_inset CommandInset href
4544 LatexCommand href
4545 name "accessed online"
4546 target "http://www.lyx.org/trac/browser/lyx-devel/trunk/development/HTML/HTML.notes"
4547
4548 \end_inset
4549
4550 , usually contains up-to-date information about the state of XHTML output.
4551  See also the list of XHTML bugs on 
4552 \begin_inset CommandInset href
4553 LatexCommand href
4554 name "the bug tracker"
4555 target "http://www.lyx.org/trac/query?status=reopened&status=assigned&status=new&max=0&component=xhtml+export&order=id&col=id&col=summary&col=reporter&col=keywords&keywords=%21%7Efixedintrunk&desc=1"
4556
4557 \end_inset
4558
4559 .
4560 \end_layout
4561
4562 \end_inset
4563
4564  Still, the developers have chosen this approach because it has several
4565  potential advantages over the other two.
4566 \end_layout
4567
4568 \begin_layout Standard
4569 These advantages are primarily due to the fact that the XHTML output routines,
4570  since they are part of LyX, know everything LyX knows about the document
4571  being exported.
4572 \begin_inset Foot
4573 status collapsed
4574
4575 \begin_layout Plain Layout
4576 Another advantage is that, since these routines are internal to LyX, they
4577  are immune to changes in LyX's file format, or to changes in the semantics
4578  of existing insets.
4579 \end_layout
4580
4581 \end_inset
4582
4583  So they know about the table of contents (as displayed in the outline),
4584  about the counters associated with different paragraph styles, and about
4585  user-defined styles.
4586  The XHTML output routines know what LyX knows about internationalization,
4587  too, so they will output 
4588 \begin_inset Quotes eld
4589 \end_inset
4590
4591 Chapter 1
4592 \begin_inset Quotes erd
4593 \end_inset
4594
4595  or 
4596 \begin_inset Quotes eld
4597 \end_inset
4598
4599
4600 \lang ngerman
4601 Kapitel
4602 \lang english
4603  1
4604 \begin_inset Quotes erd
4605 \end_inset
4606
4607 , depending upon the language in effect at the time.
4608  
4609 \end_layout
4610
4611 \begin_layout Standard
4612 Quite generally, the output routines know what LyX knows about document
4613  layout, that is, about how the document is to be rendered on screen.
4614  We use this information when we output the document as XHTML.
4615  In particular, LyX 
4616 \emph on
4617 automatically
4618 \emph default
4619  generates CSS style information corresponding to the layout information
4620  it uses to render the document on screen: if section headings are supposed
4621  to be sans-serif and bold as seen in LyX, then (by default) they will be
4622  sans-serif and bold when viewed in a web browser, too.
4623  And this is true not just for pre-defined styles, like Section, but for
4624  any style, including user-defined styles.
4625  Indeed, the XHTML output routines make no distinction between user-defined
4626  paragraph and character styles and LyX's own pre-defined styles: in each
4627  case, everything LyX knows about the styles is contained in the layout
4628  files.
4629  And much the same is true as regards pre-defined textual insets, such as
4630  footnotes, and various custom insets.
4631  
4632 \end_layout
4633
4634 \begin_layout Standard
4635 The result is that XHTML output can be customized and extended in exactly
4636  the same way LaTeX output can be customized and extended: through layout
4637  files and modules.
4638  See chapter five of the 
4639 \emph on
4640 Customization 
4641 \emph default
4642 manual for the details.
4643 \end_layout
4644
4645 \begin_layout Standard
4646 The remainder of this chapter contains more detailed information on XHTML
4647  output, its limitations, and ways to work around those limitations.
4648 \end_layout
4649
4650 \begin_layout Section
4651 Math Output in XHTML
4652 \end_layout
4653
4654 \begin_layout Standard
4655 LyX offers four choices for how math is rendered.
4656  These have various advantages and disadvantages:
4657 \end_layout
4658
4659 \begin_layout Itemize
4660 MathML
4661 \begin_inset Newline newline
4662 \end_inset
4663
4664 MathML is a dialect of XML designed specifically for mathematics on the
4665  web, and it typically renders very well in browsers that support it.
4666  The disadvantage is that not all browsers support MathML, and support is
4667  not complete even in the Gecko-based browsers, such as Firefox.
4668 \begin_inset Newline newline
4669 \end_inset
4670
4671 If LyX is unable to render a formula as MathML---for example, if the formula
4672  uses the 
4673 \begin_inset Flex Code
4674 status collapsed
4675
4676 \begin_layout Plain Layout
4677 xymatrix
4678 \end_layout
4679
4680 \end_inset
4681
4682  package or ERT---then it will instead output the formula as an image.
4683  
4684 \end_layout
4685
4686 \begin_layout Itemize
4687 HTML
4688 \begin_inset Newline newline
4689 \end_inset
4690
4691 As mentioned above, 
4692 \begin_inset Flex Code
4693 status collapsed
4694
4695 \begin_layout Plain Layout
4696 elyxer
4697 \end_layout
4698
4699 \end_inset
4700
4701  outputs math as HTML, styled by CSS.
4702 \begin_inset Foot
4703 status collapsed
4704
4705 \begin_layout Plain Layout
4706 LyX has borrowed some of the CSS for its HTML output from 
4707 \begin_inset Flex Code
4708 status collapsed
4709
4710 \begin_layout Plain Layout
4711 elyxer
4712 \end_layout
4713
4714 \end_inset
4715
4716 .
4717 \end_layout
4718
4719 \end_inset
4720
4721  For simple formulae, this can work quite well, though with more complicated
4722  formulae it tends to break down.
4723  Still, this method has the advantage that it is very widely supported and
4724  so it may be appropriate for documents that contain only a little, fairly
4725  simple math.
4726 \begin_inset Newline newline
4727 \end_inset
4728
4729 If Lyx is unable to render a formula as HTML---for example, if the formula
4730  uses the 
4731 \begin_inset Flex Code
4732 status collapsed
4733
4734 \begin_layout Plain Layout
4735 xymatrix
4736 \end_layout
4737
4738 \end_inset
4739
4740  package or ERT---then it will instead output the formula as an image.
4741  
4742 \end_layout
4743
4744 \begin_layout Itemize
4745 Images
4746 \begin_inset Newline newline
4747 \end_inset
4748
4749 Like 
4750 \begin_inset Flex Code
4751 status collapsed
4752
4753 \begin_layout Plain Layout
4754 htlatex
4755 \end_layout
4756
4757 \end_inset
4758
4759 , LyX will output formulae as images, the very same images, in fact, that
4760  are used for instant preview.
4761 \begin_inset Foot
4762 status collapsed
4763
4764 \begin_layout Plain Layout
4765 Instant preview does 
4766 \emph on
4767 not 
4768 \emph default
4769 have to be on for images to be output, however.
4770 \end_layout
4771
4772 \end_inset
4773
4774  The advantage to this method is that the images are simply generated by
4775  LaTeX, so they are very accurate.
4776  The disadvantage, as mentioned earlier, is that these are bitmapped images,
4777  so they do not scale terribly well, and one cannot copy them, etc.
4778  (As of this writing, there are also problems about equation numbering.
4779  See 
4780 \begin_inset CommandInset href
4781 LatexCommand href
4782 name "bug 6894"
4783 target "http://www.lyx.org/trac/ticket/6894"
4784
4785 \end_inset
4786
4787 .)
4788 \begin_inset Newline newline
4789 \end_inset
4790
4791 The size of the images can be controlled by setting the 
4792 \begin_inset Quotes eld
4793 \end_inset
4794
4795 Math Images Scaling
4796 \begin_inset Quotes erd
4797 \end_inset
4798
4799  parameter under 
4800 \begin_inset Flex MenuItem
4801 status collapsed
4802
4803 \begin_layout Plain Layout
4804 Document\SpecialChar \menuseparator
4805 Settings\SpecialChar \menuseparator
4806 Output
4807 \end_layout
4808
4809 \end_inset
4810
4811 .
4812 \begin_inset Foot
4813 status collapsed
4814
4815 \begin_layout Plain Layout
4816 For those who want to know, this controls the resolution of the image in
4817  dots per inch and is based upon a default of 75 dpi.
4818 \end_layout
4819
4820 \end_inset
4821
4822
4823 \begin_inset Newline newline
4824 \end_inset
4825
4826 If LyX for some reason fails to create an image for a formula (e.g., if a
4827  required LaTeX package is not installed), then it will fall back to outputing
4828  the raw LaTeX.
4829 \end_layout
4830
4831 \begin_layout Itemize
4832 LaTeX
4833 \begin_inset Newline newline
4834 \end_inset
4835
4836 Finally, LyX will happily output math as LaTeX.
4837  As well as being the output of last resort, this method can be used with
4838  such tools as 
4839 \begin_inset CommandInset href
4840 LatexCommand href
4841 name "jsMath"
4842 target "http://www.math.union.edu/~dpvc/jsMath/"
4843
4844 \end_inset
4845
4846 , which uses JavaScript to render LaTeX embedded in HTML documents.
4847  LyX wraps the LaTeX in either a 
4848 \begin_inset Flex Code
4849 status collapsed
4850
4851 \begin_layout Plain Layout
4852 span
4853 \end_layout
4854
4855 \end_inset
4856
4857  (for inline formulas) or 
4858 \begin_inset Flex Code
4859 status collapsed
4860
4861 \begin_layout Plain Layout
4862 div
4863 \end_layout
4864
4865 \end_inset
4866
4867  (for displayed formulas) with 
4868 \begin_inset Flex Code
4869 status collapsed
4870
4871 \begin_layout Plain Layout
4872 class='math'
4873 \end_layout
4874
4875 \end_inset
4876
4877 , as is required for jsMath.
4878 \end_layout
4879
4880 \begin_layout Standard
4881 One of these output methods must be selected under 
4882 \begin_inset Flex MenuItem
4883 status collapsed
4884
4885 \begin_layout Plain Layout
4886 Document\SpecialChar \menuseparator
4887 Settings\SpecialChar \menuseparator
4888 Output
4889 \end_layout
4890
4891 \end_inset
4892
4893 .
4894  By default, LyX outputs MathML.
4895  This is a document-wide setting, therefore.
4896 \end_layout
4897
4898 \begin_layout Standard
4899 Eventually, LyX will offer the user the option to select an alternate output
4900  method for a particular inset, say, one that isn't being rendered very
4901  well by MathML.
4902 \begin_inset Foot
4903 status collapsed
4904
4905 \begin_layout Plain Layout
4906 That said, since LyX falls back to images if the inset contains ERT, then
4907  one can force output as an image by putting some harmless ERT into the
4908  math, for example: 
4909 \begin_inset Formula $a=b\relax$
4910 \end_inset
4911
4912 .
4913 \end_layout
4914
4915 \end_inset
4916
4917
4918 \end_layout
4919
4920 \begin_layout Section
4921 Bibliography and Citations
4922 \end_layout
4923
4924 \begin_layout Standard
4925 XHTML output fully supports bibliographies and citations.
4926  
4927 \end_layout
4928
4929 \begin_layout Standard
4930 Citation labels are generated by the same machinery that generates LyX's
4931  on-screen labels, so the labels will look in the output much as they do
4932  in LyX, though better.
4933  If you are using numerical citations, then LyX will output numerical labels,
4934  such as [1] or [17], rather than simply showing the citation key in square
4935  brackets, as it does on-screen.
4936  If you are using author-year citations, then LyX will add lowercase letters
4937  to the years, just as BibTeX does, if it finds more than one citation for
4938  a given author-year combination.
4939  The labels will be printed with the bibliography entries.
4940  Note that there is, at present, no way to customize the appearance of the
4941  labels, for example, to choose between square brackets and parentheses.
4942 \end_layout
4943
4944 \begin_layout Standard
4945 Bibliography output is handled by the same machinery that handles the presentati
4946 on of reference information in the citation dialog, so you will see in the
4947  XHTML output pretty much what you would see if you were to look at a given
4948  entry in the citation dialog.
4949  The formatting can be customized in your layout file or, preferably, in
4950  a module.
4951  See the 
4952 \emph on
4953 Customization
4954 \emph default
4955  manual for the details.
4956 \end_layout
4957
4958 \begin_layout Standard
4959 The main defect at present is that cross-referenced information is printed
4960  with every entry with which it is associated.
4961  So you can see things like this:
4962 \end_layout
4963
4964 \begin_layout Quote
4965 Jason Stanley, 
4966 \begin_inset Quotes eld
4967 \end_inset
4968
4969 Context and Logical Form
4970 \begin_inset Quotes erd
4971 \end_inset
4972
4973 , in 
4974 \emph on
4975 Language in Context: Selected Essays
4976 \emph default
4977  (Oxford: Oxford University Press, 2007), pp.
4978  30--68.
4979 \end_layout
4980
4981 \begin_layout Quote
4982 Jason Stanley, 
4983 \begin_inset Quotes eld
4984 \end_inset
4985
4986 Semantics in Context
4987 \begin_inset Quotes erd
4988 \end_inset
4989
4990 , in 
4991 \emph on
4992 Language in Context: Selected Essays
4993 \emph default
4994  (Oxford: Oxford University Press, 2007), pp.
4995  201--30.
4996 \end_layout
4997
4998 \begin_layout Standard
4999 This should be fixed before long.
5000 \end_layout
5001
5002 \begin_layout Standard
5003 There is no support at present for sectioned bibliographies.
5004  If you have multiple bibliographies, then LyX will print the same bibliography
5005  over and over.
5006 \end_layout
5007
5008 \begin_layout Section
5009 Indexes
5010 \end_layout
5011
5012 \begin_layout Standard
5013 LyX will happily export indexes as XHTML, but with certain limitations at
5014  the moment.
5015 \end_layout
5016
5017 \begin_layout Standard
5018 Index export will be most reliable when you do not attempt to use the fancy
5019  constructs that are described in the section on indexes in the 
5020 \emph on
5021 User's Guide
5022 \emph default
5023 .
5024 \begin_inset Foot
5025 status collapsed
5026
5027 \begin_layout Plain Layout
5028 The main issue here is that LyX itself does not really handle these.
5029  It just lets you enter what you would have to enter in raw LaTeX.
5030 \end_layout
5031
5032 \end_inset
5033
5034  We'll describe how they are handled using the subsection headings from
5035  that section.
5036 \end_layout
5037
5038 \begin_layout Itemize
5039 Grouping Index Entries (aka, sub-entries): LyX makes an effort to support
5040  these, but the entries must be separated by 
5041 \begin_inset Quotes eld
5042 \end_inset
5043
5044  ! 
5045 \begin_inset Quotes erd
5046 \end_inset
5047
5048 , that is, there must be spaces around the exclamation point.
5049  This is because it is otherwise too difficult to check for escaped exclamation
5050  points, ones in math, and so forth.
5051 \end_layout
5052
5053 \begin_layout Itemize
5054 Page Ranges: There is no support at all for page ranges, since these make
5055  no sense with XHMTL.
5056  Instead, you will just get two index entries, one at either end.
5057 \end_layout
5058
5059 \begin_layout Itemize
5060 Cross-referencing: There is no support for cross-referencing.
5061  If LyX finds an entry containing the 
5062 \begin_inset Quotes eld
5063 \end_inset
5064
5065 |see\SpecialChar \ldots{}
5066
5067 \begin_inset Quotes erd
5068 \end_inset
5069
5070  construct, it is just dropped, and the rest is treated as an ordinary index
5071  entry.
5072 \end_layout
5073
5074 \begin_layout Itemize
5075 Index Entry Order: LyX does support attempts to fix the sorting order.
5076  It will take what is before the first `@' it finds and use that for sorting,
5077  taking what follows the first `@' to be the actual entry.
5078  At present, LyX does not check for escaped `@', so do not try to index
5079  email addresses.
5080 \end_layout
5081
5082 \begin_layout Itemize
5083 Index Entry Layout: You can format entries by using the text style dialog,
5084  or by using any other method available within LyX itself.
5085  There is no support for constructs like: 
5086 \begin_inset Quotes eld
5087 \end_inset
5088
5089 entry|textbf
5090 \begin_inset Quotes erd
5091 \end_inset
5092
5093 .
5094  Indeed, if LyX finds a pipe symbol, `|', in an entry, it will delete it
5095  and everything that follows it.
5096 \end_layout
5097
5098 \begin_layout Itemize
5099 Multiple Indexes: There is no support for multiple indexes.
5100  Rather, all index entries will be printed as one large index.
5101  To avoid our printing several versions of the index, we print only the
5102  main index, so make sure you have one.
5103 \end_layout
5104
5105 \begin_layout Section
5106 Nomenclature and Glossary
5107 \end_layout
5108
5109 \begin_layout Standard
5110 There is at present no support for glossaries.
5111  Adding it would be fairly trivial, and welcome.
5112 \end_layout
5113
5114 \begin_layout Chapter
5115 The LyX Server
5116 \end_layout
5117
5118 \begin_layout Section
5119 Introduction
5120 \end_layout
5121
5122 \begin_layout Standard
5123 The `LyX server' allows other programs to talk to LyX, invoke LyX commands,
5124  and retrieve information about the LyX internal state.
5125  This is only intended for advanced users, but they should find it useful.
5126  It is by writing to the LyX server, for example, that bibliography managers,
5127  such as JabRef, are able to 
5128 \begin_inset Quotes eld
5129 \end_inset
5130
5131 push
5132 \begin_inset Quotes erd
5133 \end_inset
5134
5135  citations to LyX.
5136 \end_layout
5137
5138 \begin_layout Section
5139 Starting the LyX Server
5140 \end_layout
5141
5142 \begin_layout Standard
5143 The LyX server works through the use of a pair of named pipes.
5144  These are usually located in 
5145 \begin_inset Flex Code
5146 status collapsed
5147
5148 \begin_layout Plain Layout
5149 UserDir
5150 \end_layout
5151
5152 \end_inset
5153
5154 , (except on Windows, where 
5155 \emph on
5156 local
5157 \emph default
5158  named pipes are special objects located in 
5159 \begin_inset Flex Code
5160 status collapsed
5161
5162 \begin_layout Plain Layout
5163
5164 \backslash
5165
5166 \backslash
5167 .
5168 \backslash
5169 pipe
5170 \end_layout
5171
5172 \end_inset
5173
5174 ) and have the names 
5175 \begin_inset Quotes eld
5176 \end_inset
5177
5178
5179 \begin_inset Flex Code
5180 status collapsed
5181
5182 \begin_layout Plain Layout
5183 lyxpipe.in
5184 \end_layout
5185
5186 \end_inset
5187
5188
5189 \begin_inset Quotes erd
5190 \end_inset
5191
5192  and 
5193 \begin_inset Quotes eld
5194 \end_inset
5195
5196
5197 \begin_inset Flex Code
5198 status collapsed
5199
5200 \begin_layout Plain Layout
5201 lyxpipe.out
5202 \end_layout
5203
5204 \end_inset
5205
5206
5207 \begin_inset Quotes erd
5208 \end_inset
5209
5210 .
5211  External programs write into 
5212 \begin_inset Flex Code
5213 status collapsed
5214
5215 \begin_layout Plain Layout
5216 lyxpipe.in
5217 \end_layout
5218
5219 \end_inset
5220
5221  and read back data from 
5222 \begin_inset Flex Code
5223 status collapsed
5224
5225 \begin_layout Plain Layout
5226 lyxpipe.out
5227 \end_layout
5228
5229 \end_inset
5230
5231 .
5232  The stem of the pipe names can be defined in the 
5233 \begin_inset Flex MenuItem
5234 status collapsed
5235
5236 \begin_layout Plain Layout
5237 Tools\SpecialChar \menuseparator
5238 Preferences
5239 \end_layout
5240
5241 \end_inset
5242
5243  dialog, for example 
5244 \begin_inset Flex Code
5245 status collapsed
5246
5247 \begin_layout Plain Layout
5248 "/home/myhome/lyxpipe"
5249 \end_layout
5250
5251 \end_inset
5252
5253 , or 
5254 \begin_inset Flex Code
5255 status collapsed
5256
5257 \begin_layout Plain Layout
5258 "
5259 \backslash
5260
5261 \backslash
5262 .
5263 \backslash
5264 pipe
5265 \backslash
5266 lyxpipe"
5267 \end_layout
5268
5269 \end_inset
5270
5271  on Windows (but any working path can be used).
5272  You 
5273 \emph on
5274 must
5275 \emph default
5276  configure this manually in order for the server to start.
5277 \end_layout
5278
5279 \begin_layout Standard
5280 LyX will add the '
5281 \begin_inset Flex Code
5282 status collapsed
5283
5284 \begin_layout Plain Layout
5285 .in
5286 \end_layout
5287
5288 \end_inset
5289
5290 ' and '
5291 \begin_inset Flex Code
5292 status collapsed
5293
5294 \begin_layout Plain Layout
5295 .out
5296 \end_layout
5297
5298 \end_inset
5299
5300 ' to create the pipes.
5301  If one of the pipes already exists, LyX will assume that another LyX process
5302  is already running and will not start the server.
5303  On POSIX (Unix like) systems, if for some other reason, an unused 
5304 \begin_inset Quotes eld
5305 \end_inset
5306
5307 stale
5308 \begin_inset Quotes erd
5309 \end_inset
5310
5311  pipe is left in existence when LyX closes, then LyX will try to delete
5312  it.
5313  If this fails for some reason, you will need to delete the pipes manually
5314  and then restart LyX.
5315  On Windows, pipes are deleted by the OS on program termination or crash,
5316  so 
5317 \begin_inset Quotes eld
5318 \end_inset
5319
5320 stale
5321 \begin_inset Quotes erd
5322 \end_inset
5323
5324  pipes should not be possible.
5325 \end_layout
5326
5327 \begin_layout Standard
5328 To have several LyX processes with servers at the same time, you have to
5329  use different configurations, perhaps by using separate user directories,
5330  each with its own 
5331 \begin_inset Flex Code
5332 status collapsed
5333
5334 \begin_layout Plain Layout
5335 preferences
5336 \end_layout
5337
5338 \end_inset
5339
5340  file, for each process.
5341 \end_layout
5342
5343 \begin_layout Standard
5344 If you are developing a client program, you might find it useful to enable
5345  debugging information from the LyX server.
5346  Do this by starting LyX as 
5347 \begin_inset Flex Code
5348 status collapsed
5349
5350 \begin_layout Plain Layout
5351 lyx -dbg lyxserver
5352 \end_layout
5353
5354 \end_inset
5355
5356 .
5357 \end_layout
5358
5359 \begin_layout Standard
5360 You can find a complete example client written in C in the source distribution
5361  as 
5362 \begin_inset Flex Code
5363 status collapsed
5364
5365 \begin_layout Plain Layout
5366 development/lyxserver/server_monitor.c
5367 \end_layout
5368
5369 \end_inset
5370
5371 .
5372 \end_layout
5373
5374 \begin_layout Standard
5375 Another useful tool is command-line based client you will find in 
5376 \begin_inset Flex Code
5377 status collapsed
5378
5379 \begin_layout Plain Layout
5380 src/client/lyxclient
5381 \end_layout
5382
5383 \end_inset
5384
5385 .
5386 \end_layout
5387
5388 \begin_layout Section
5389 Normal communication
5390 \end_layout
5391
5392 \begin_layout Standard
5393 To issue a LyX call, the client writes a line of ASCII text into the input
5394  pipe.
5395  This line has the following format:
5396 \end_layout
5397
5398 \begin_layout Quote
5399 LYXCMD:
5400 \emph on
5401 clientname
5402 \emph default
5403 :
5404 \emph on
5405 function
5406 \emph default
5407 :
5408 \emph on
5409 argument
5410 \end_layout
5411
5412 \begin_layout Description
5413 clientname is a name that the client can choose arbitrarily.
5414  Its only use is that LyX will echo it if it sends an answer—so a client
5415  can dispatch results from different requesters.
5416 \end_layout
5417
5418 \begin_layout Description
5419 function is the function you want LyX to perform.
5420  It is the same as the commands you'd use in the minibuffer.
5421 \end_layout
5422
5423 \begin_layout Description
5424 argument is an optional argument which is meaningful only to some functions
5425  (for instance, the 
5426 \begin_inset Quotes eld
5427 \end_inset
5428
5429 self-insert
5430 \begin_inset Quotes erd
5431 \end_inset
5432
5433  LFUN will insert the argument as text at the cursor position).
5434 \end_layout
5435
5436 \begin_layout Standard
5437 The answer from LyX will arrive in the output pipe and be of the form
5438 \end_layout
5439
5440 \begin_layout Quote
5441 INFO:
5442 \emph on
5443 clientname
5444 \emph default
5445 :
5446 \emph on
5447 function
5448 \emph default
5449 :
5450 \emph on
5451 data
5452 \end_layout
5453
5454 \begin_layout Standard
5455 where 
5456 \emph on
5457 clientname
5458 \emph default
5459  and 
5460 \emph on
5461 function
5462 \emph default
5463  are just echoed from the command request, while 
5464 \emph on
5465 data
5466 \emph default
5467  is more or less useful information filled according to how the command
5468  execution worked out.
5469  Some commands, such as 
5470 \begin_inset Quotes eld
5471 \end_inset
5472
5473 font-state
5474 \begin_inset Quotes erd
5475 \end_inset
5476
5477 , will return information about the internal state of LyX, while other will
5478  return an empty data-response.
5479  This means that the command execution went fine.
5480 \end_layout
5481
5482 \begin_layout Standard
5483 In case of errors, the response from LyX will have this form
5484 \end_layout
5485
5486 \begin_layout Quote
5487 ERROR:
5488 \emph on
5489 clientname
5490 \emph default
5491 :
5492 \emph on
5493 function
5494 \emph default
5495 :
5496 \emph on
5497 error message
5498 \end_layout
5499
5500 \begin_layout Standard
5501 where the 
5502 \emph on
5503 error message
5504 \emph default
5505  should contain an explanation of why the command failed.
5506 \end_layout
5507
5508 \begin_layout Standard
5509 Examples:
5510 \end_layout
5511
5512 \begin_layout LyX-Code
5513 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
5514 \begin_inset Newline newline
5515 \end_inset
5516
5517 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
5518 \begin_inset Newline newline
5519 \end_inset
5520
5521 read a <~/.lyxpipe.out
5522 \begin_inset Newline newline
5523 \end_inset
5524
5525 echo $a
5526 \end_layout
5527
5528 \begin_layout Section
5529 Notification
5530 \end_layout
5531
5532 \begin_layout Standard
5533 LyX can notify clients of events going on asynchronously.
5534  Currently it will only do this if the user binds a key sequence with the
5535  function 
5536 \begin_inset Quotes eld
5537 \end_inset
5538
5539 notify
5540 \begin_inset Quotes erd
5541 \end_inset
5542
5543 .
5544  The format of the string LyX sends is as follows:
5545 \end_layout
5546
5547 \begin_layout Quote
5548 \begin_inset Flex Code
5549 status collapsed
5550
5551 \begin_layout Plain Layout
5552 NOTIFY:
5553 \end_layout
5554
5555 \end_inset
5556
5557
5558 \emph on
5559 key-sequence
5560 \end_layout
5561
5562 \begin_layout Standard
5563 where 
5564 \emph on
5565 key-sequence
5566 \emph default
5567  is the printed representation of the key sequence that was actually typed
5568  by the user.
5569 \end_layout
5570
5571 \begin_layout Standard
5572 This mechanism can be used to extend LyX's command set and implement macros.
5573  Bind some key sequence to 
5574 \begin_inset Quotes eld
5575 \end_inset
5576
5577 notify
5578 \begin_inset Quotes erd
5579 \end_inset
5580
5581 .
5582  Then start a client that listens on the output pipe, dispatches the command
5583  according to the sequence, and starts a function that may use LyX calls
5584  and LyX requests to issue a command or a series of commands to LyX.
5585 \end_layout
5586
5587 \begin_layout Section
5588 The simple LyX Server Protocol
5589 \end_layout
5590
5591 \begin_layout Standard
5592 LyX implements a simple protocol that can be used for session management.
5593  All messages are of the form
5594 \end_layout
5595
5596 \begin_layout Quote
5597 LYXSRV:
5598 \emph on
5599 clientname
5600 \emph default
5601 :
5602 \emph on
5603 protocol message
5604 \end_layout
5605
5606 \begin_layout Standard
5607 where 
5608 \emph on
5609 protocol message
5610 \emph default
5611  can be 
5612 \begin_inset Quotes eld
5613 \end_inset
5614
5615 hello
5616 \begin_inset Quotes erd
5617 \end_inset
5618
5619  or 
5620 \begin_inset Quotes eld
5621 \end_inset
5622
5623 bye
5624 \begin_inset Quotes erd
5625 \end_inset
5626
5627 .
5628  If 
5629 \begin_inset Quotes eld
5630 \end_inset
5631
5632 hello
5633 \begin_inset Quotes erd
5634 \end_inset
5635
5636  is received from a client, LyX will report back to inform the client that
5637  it's listening to it's messages, while 
5638 \begin_inset Quotes eld
5639 \end_inset
5640
5641 bye
5642 \begin_inset Quotes erd
5643 \end_inset
5644
5645  sent from LyX will inform clients that LyX is closing.
5646 \end_layout
5647
5648 \begin_layout Section
5649 Reverse DVI/PDF search
5650 \end_layout
5651
5652 \begin_layout Standard
5653 Some DVI/PDF viewers
5654 \begin_inset Foot
5655 status collapsed
5656
5657 \begin_layout Plain Layout
5658 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
5659  Skim on Mac OSX and SumatraPDF on Windows.
5660 \end_layout
5661
5662 \end_inset
5663
5664  provide 
5665 \emph on
5666 reverse search
5667 \emph default
5668  facility (also called 
5669 \emph on
5670 inverse search
5671 \emph default
5672 ).
5673  This means that you can tell LyX to put the cursor to a specific line in
5674  the document by clicking at the respective position in the DVI/PDF output.
5675  To achieve this, the viewer must be able to communicate with LyX.
5676  This is done via the LyX server either by using the named pipe (
5677 \emph on
5678 lyxpipe
5679 \emph default
5680 ), or the UNIX domain socket (
5681 \emph on
5682 lyxsocket
5683 \emph default
5684 ) that LyX creates in its temporary directory (this is the way the 
5685 \begin_inset Flex Code
5686 status collapsed
5687
5688 \begin_layout Plain Layout
5689 lyxclient
5690 \end_layout
5691
5692 \end_inset
5693
5694  program communicates with LyX).
5695  In some cases, you need a helper script that mediates between the viewer
5696  and LyX, in others, the viewer can communicate with LyX directly.
5697  This depends on the selected viewer and on your operating system.
5698  The same applies to the way viewers need to be configured and the way the
5699  reverse search is actually performed.
5700  In what follows, we will thus describe how to setup reverse search for
5701  specific viewers.
5702  Before we turn to this, though, we will explain what needs to be done generally
5703  to enable reverse search in the DVI/PDF output.
5704 \end_layout
5705
5706 \begin_layout Subsection
5707 Automatic setup
5708 \begin_inset CommandInset label
5709 LatexCommand label
5710 name "sub:rev-search"
5711
5712 \end_inset
5713
5714
5715 \end_layout
5716
5717 \begin_layout Standard
5718 In most cases LyX will do the work for you by enabling 
5719 \begin_inset Flex MenuItem
5720 status collapsed
5721
5722 \begin_layout Plain Layout
5723 Document\SpecialChar \menuseparator
5724 Output\SpecialChar \menuseparator
5725 Synchronize with Output
5726 \end_layout
5727
5728 \end_inset
5729
5730 .
5731  In such a case LyX will automatically insert the necessary SyncTeX macro
5732  (for PDF) or load the srcltx package (for DVI) respectively.
5733  This option can be easily reached also on 
5734 \begin_inset Flex Code
5735 status collapsed
5736
5737 \begin_layout Plain Layout
5738 View/Update
5739 \end_layout
5740
5741 \end_inset
5742
5743  Toolbar.
5744 \end_layout
5745
5746 \begin_layout Standard
5747 If you need a different setting, you can select or input a custom macro
5748  from the drop down box just below 
5749 \begin_inset Flex MenuItem
5750 status collapsed
5751
5752 \begin_layout Plain Layout
5753 Document\SpecialChar \menuseparator
5754 Settings\SpecialChar \menuseparator
5755 Output\SpecialChar \menuseparator
5756 Synchronize with Output
5757 \end_layout
5758
5759 \end_inset
5760
5761 .
5762 \end_layout
5763
5764 \begin_layout Standard
5765 Please note that including the 
5766 \begin_inset Flex Code
5767 status collapsed
5768
5769 \begin_layout Plain Layout
5770 srcltx
5771 \end_layout
5772
5773 \end_inset
5774
5775  package or 
5776 \begin_inset Flex Code
5777 status collapsed
5778
5779 \begin_layout Plain Layout
5780 src-specials
5781 \end_layout
5782
5783 \end_inset
5784
5785  sometimes has an undesired impact on the typesetting.
5786  Thus, you should switch output synchronization off for the final typesetting
5787  if you use the 
5788 \begin_inset Flex Code
5789 status collapsed
5790
5791 \begin_layout Plain Layout
5792 srcltx
5793 \end_layout
5794
5795 \end_inset
5796
5797  package or 
5798 \begin_inset Flex Code
5799 status collapsed
5800
5801 \begin_layout Plain Layout
5802 src-specials
5803 \end_layout
5804
5805 \end_inset
5806
5807 .
5808 \end_layout
5809
5810 \begin_layout Standard
5811 In case you need some more special settings that are not covered by the
5812  automatic settings, read the next section about how to set up output synchroniz
5813 ation manually.
5814  If the automatic setup suits your needs, you can readily jump to section
5815 \begin_inset space ~
5816 \end_inset
5817
5818
5819 \begin_inset CommandInset ref
5820 LatexCommand ref
5821 reference "sub:configuring-viewers"
5822
5823 \end_inset
5824
5825 , where the necessary configuration steps in your viewer -- needed both
5826  with the automatic and the manual setup -- are described.
5827 \end_layout
5828
5829 \begin_layout Subsection
5830 Manual setup
5831 \end_layout
5832
5833 \begin_layout Standard
5834 LaTeX provides several different methods for reverse search.
5835  Some are built-in in the 
5836 \begin_inset Flex Code
5837 status collapsed
5838
5839 \begin_layout Plain Layout
5840 latex/pdflatex
5841 \end_layout
5842
5843 \end_inset
5844
5845  program, some are provided by external packages.
5846  Your choice depends on whether your LaTeX distribution already provides
5847  a given method (the built-in methods are rather new) and whether your viewer
5848  can cope with it.
5849  The available methods are described in the following.
5850 \end_layout
5851
5852 \begin_layout Subsubsection*
5853 Built-in DVI-search via src-specials (DVI only) 
5854 \end_layout
5855
5856 \begin_layout Standard
5857 This method provides the DVI file with the necessary information for reverse
5858  search.
5859  It is available in LaTeX since quite some time (any somewhat recent LaTeX
5860  distribution should include it), and it works reliably.
5861  To enable it, change the 
5862 \begin_inset Flex MenuItem
5863 status collapsed
5864
5865 \begin_layout Plain Layout
5866 LaT
5867 \begin_inset ERT
5868 status collapsed
5869
5870 \begin_layout Plain Layout
5871
5872 {}
5873 \end_layout
5874
5875 \end_inset
5876
5877 eX (plain)->DVI
5878 \end_layout
5879
5880 \end_inset
5881
5882  or 
5883 \begin_inset Flex MenuItem
5884 status collapsed
5885
5886 \begin_layout Plain Layout
5887 LaT
5888 \begin_inset ERT
5889 status collapsed
5890
5891 \begin_layout Plain Layout
5892
5893 {}
5894 \end_layout
5895
5896 \end_inset
5897
5898 eX (plain)->DraftDVI
5899 \end_layout
5900
5901 \end_inset
5902
5903  converter in 
5904 \begin_inset Flex MenuItem
5905 status collapsed
5906
5907 \begin_layout Plain Layout
5908 Preferences\SpecialChar \menuseparator
5909 File Handling\SpecialChar \menuseparator
5910 Converters
5911 \end_layout
5912
5913 \end_inset
5914
5915  to 
5916 \begin_inset Flex Code
5917 status collapsed
5918
5919 \begin_layout Plain Layout
5920 latex -src-specials $$i
5921 \end_layout
5922
5923 \end_inset
5924
5925 .
5926  If this doesn't work, check if your TeX engine needs different options
5927  (the syntax might differ in some distributions).
5928 \end_layout
5929
5930 \begin_layout Subsubsection*
5931 External Packages (PDFSync and scrltx) 
5932 \end_layout
5933
5934 \begin_layout Standard
5935 The packages 
5936 \emph on
5937 pdfsync
5938 \emph default
5939  and 
5940 \emph on
5941 scrltx
5942 \emph default
5943  provide reverse search facility for PDF output (via pdflatex) and DVI output,
5944  respectively.
5945  In order to enable it, load the packages in the LyX preamble: 
5946 \end_layout
5947
5948 \begin_layout Itemize
5949 \begin_inset Flex Code
5950 status collapsed
5951
5952 \begin_layout Plain Layout
5953
5954 \backslash
5955 usepackage{pdfsync}
5956 \end_layout
5957
5958 \end_inset
5959
5960  for reverse PDF search,
5961 \end_layout
5962
5963 \begin_layout Itemize
5964 \begin_inset Flex Code
5965 status collapsed
5966
5967 \begin_layout Plain Layout
5968
5969 \backslash
5970 usepackage[active]{srcltx}
5971 \end_layout
5972
5973 \end_inset
5974
5975  for reverse DVI search.
5976 \end_layout
5977
5978 \begin_layout Standard
5979 If you want to be able to perform both DVI and PDF reverse searches, you
5980  can also insert in the preamble the following lines
5981 \end_layout
5982
5983 \begin_layout LyX-Code
5984
5985 \backslash
5986 usepackage{ifpdf}
5987 \begin_inset Newline newline
5988 \end_inset
5989
5990
5991 \backslash
5992 ifpdf
5993 \begin_inset Newline newline
5994 \end_inset
5995
5996   
5997 \backslash
5998 usepackage{pdfsync}
5999 \begin_inset Newline newline
6000 \end_inset
6001
6002
6003 \backslash
6004 else
6005 \begin_inset Newline newline
6006 \end_inset
6007
6008   
6009 \backslash
6010 usepackage[active]{srcltx}
6011 \begin_inset Newline newline
6012 \end_inset
6013
6014
6015 \backslash
6016 fi
6017 \end_layout
6018
6019 \begin_layout Standard
6020 This way, you can preview the file as either DVI or PDF (pdflatex) and the
6021  right package will be used.
6022 \end_layout
6023
6024 \begin_layout Standard
6025 Note that PDFSync might affect the output layout of your document.
6026  It is therefore advised to disable PDFsync for final documents.
6027 \end_layout
6028
6029 \begin_layout Subsubsection*
6030 Built-in reverse search via SyncTeX (DVI and PDF) 
6031 \end_layout
6032
6033 \begin_layout Standard
6034 Recent versions of 
6035 \begin_inset Flex Code
6036 status collapsed
6037
6038 \begin_layout Plain Layout
6039 (pdf)latex
6040 \end_layout
6041
6042 \end_inset
6043
6044  have built-in support for both PDF and DVI reverse search.
6045  This so-called 
6046 \emph on
6047 SyncTeX
6048 \emph default
6049  facility is basically the result of the integration of the PDFSync package
6050  to the pdftex program and its merge with the 
6051 \emph on
6052 scr-specials
6053 \emph default
6054  approach.
6055  You need at least TeXLive 2008 or a recent MikTeX distribution in order
6056  to use it.
6057  Also note that only a few PDF viewers (Skim on the Mac, SumatraPDF on Windows)
6058  already provide SyncTeX support.
6059 \end_layout
6060
6061 \begin_layout Standard
6062 To enable SyncTeX for DVI output, change the 
6063 \begin_inset Flex MenuItem
6064 status collapsed
6065
6066 \begin_layout Plain Layout
6067 LaT
6068 \begin_inset ERT
6069 status collapsed
6070
6071 \begin_layout Plain Layout
6072
6073 {}
6074 \end_layout
6075
6076 \end_inset
6077
6078 eX (plain) -> DVI
6079 \end_layout
6080
6081 \end_inset
6082
6083  or 
6084 \begin_inset Flex MenuItem
6085 status collapsed
6086
6087 \begin_layout Plain Layout
6088 LaT
6089 \begin_inset ERT
6090 status collapsed
6091
6092 \begin_layout Plain Layout
6093
6094 {}
6095 \end_layout
6096
6097 \end_inset
6098
6099 eX (plain) -> DraftDVI
6100 \end_layout
6101
6102 \end_inset
6103
6104  converter in 
6105 \begin_inset Flex MenuItem
6106 status collapsed
6107
6108 \begin_layout Plain Layout
6109 Preferences\SpecialChar \menuseparator
6110 File Handling\SpecialChar \menuseparator
6111 Converters
6112 \end_layout
6113
6114 \end_inset
6115
6116  to 
6117 \begin_inset Flex Code
6118 status collapsed
6119
6120 \begin_layout Plain Layout
6121 latex -synctex=1 $$i
6122 \end_layout
6123
6124 \end_inset
6125
6126 , and for PDF output, change the 
6127 \begin_inset Flex MenuItem
6128 status collapsed
6129
6130 \begin_layout Plain Layout
6131 LaT
6132 \begin_inset ERT
6133 status collapsed
6134
6135 \begin_layout Plain Layout
6136
6137 {}
6138 \end_layout
6139
6140 \end_inset
6141
6142 eX (pdflatex) -> PDF (pdflatex)
6143 \end_layout
6144
6145 \end_inset
6146
6147  or converter to 
6148 \begin_inset Flex Code
6149 status collapsed
6150
6151 \begin_layout Plain Layout
6152 pdflatex -synctex=1 $$i
6153 \end_layout
6154
6155 \end_inset
6156
6157 .
6158  Check the documentation of your viewer whether the viewer needs to be configure
6159 d for the use with SyncTeX.
6160 \begin_inset Foot
6161 status collapsed
6162
6163 \begin_layout Plain Layout
6164 The 
6165 \begin_inset Flex Code
6166 status collapsed
6167
6168 \begin_layout Plain Layout
6169 -synctex=1
6170 \end_layout
6171
6172 \end_inset
6173
6174  option enables gzip compression.
6175  If your viewer does not support it, you should instead use 
6176 \begin_inset Flex Code
6177 status collapsed
6178
6179 \begin_layout Plain Layout
6180 -synctex=-1
6181 \end_layout
6182
6183 \end_inset
6184
6185 .
6186 \end_layout
6187
6188 \end_inset
6189
6190
6191 \end_layout
6192
6193 \begin_layout Subsection
6194 Configuring and using specific viewers
6195 \begin_inset CommandInset label
6196 LatexCommand label
6197 name "sub:configuring-viewers"
6198
6199 \end_inset
6200
6201
6202 \end_layout
6203
6204 \begin_layout Subsubsection*
6205 Xdvi (all platforms)
6206 \end_layout
6207
6208 \begin_layout Standard
6209 If you use 
6210 \begin_inset Flex Code
6211 status collapsed
6212
6213 \begin_layout Plain Layout
6214 xdvi
6215 \end_layout
6216
6217 \end_inset
6218
6219 , you don't need to do anything else for performing a reverse DVI search,
6220  as LyX already provides the necessary hooks for automatically using the
6221  
6222 \begin_inset Flex Code
6223 status collapsed
6224
6225 \begin_layout Plain Layout
6226 lyxclient
6227 \end_layout
6228
6229 \end_inset
6230
6231  program.
6232  Just setup your document as described above (reverse search is triggered
6233  by Ctrl-click or Alt-click on Mac OSX, respectively).
6234 \end_layout
6235
6236 \begin_layout Standard
6237 However, if for whatever reason you want to use the named pipe instead of
6238  the socket for communicating with LyX, simply change the DVI viewer in
6239  
6240 \begin_inset Flex MenuItem
6241 status collapsed
6242
6243 \begin_layout Plain Layout
6244 Preferences\SpecialChar \menuseparator
6245 File Handling\SpecialChar \menuseparator
6246 File formats
6247 \end_layout
6248
6249 \end_inset
6250
6251  to
6252 \begin_inset Foot
6253 status collapsed
6254
6255 \begin_layout Plain Layout
6256 On Mac OSX you have to use 
6257 \begin_inset Flex Code
6258 status collapsed
6259
6260 \begin_layout Plain Layout
6261 DISPLAY=:0.0 xdvi -editor 'lyxeditor.sh %f %l'
6262 \end_layout
6263
6264 \end_inset
6265
6266
6267 \end_layout
6268
6269 \end_inset
6270
6271  
6272 \begin_inset Flex Code
6273 status collapsed
6274
6275 \begin_layout Plain Layout
6276 xdvi -editor 'lyxeditor.sh %f %l'
6277 \end_layout
6278
6279 \end_inset
6280
6281 , where 
6282 \begin_inset Flex Code
6283 status collapsed
6284
6285 \begin_layout Plain Layout
6286 lyxeditor.sh
6287 \end_layout
6288
6289 \end_inset
6290
6291  is a suitable script.
6292  For example, a minimal shell script is the following one:
6293 \end_layout
6294
6295 \begin_layout LyX-Code
6296 #!/bin/sh
6297 \begin_inset Newline newline
6298 \end_inset
6299
6300 LYXPIPE="/path/to/lyxpipe"
6301 \begin_inset Newline newline
6302 \end_inset
6303
6304 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
6305 \begin_inset Newline newline
6306 \end_inset
6307
6308 echo "$COMMAND" > "${LYXPIPE}".in || exit
6309 \begin_inset Newline newline
6310 \end_inset
6311
6312 read < "${LYXPIPE}".out || exit
6313 \end_layout
6314
6315 \begin_layout Standard
6316 where 
6317 \begin_inset Flex Code
6318 status collapsed
6319
6320 \begin_layout Plain Layout
6321 /path/to/lyxpipe
6322 \end_layout
6323
6324 \end_inset
6325
6326  is the Ly
6327 \begin_inset ERT
6328 status collapsed
6329
6330 \begin_layout Plain Layout
6331
6332 {}
6333 \end_layout
6334
6335 \end_inset
6336
6337 XServer pipe path specified in 
6338 \begin_inset Flex MenuItem
6339 status collapsed
6340
6341 \begin_layout Plain Layout
6342 Preferences\SpecialChar \menuseparator
6343 Paths
6344 \end_layout
6345
6346 \end_inset
6347
6348 .
6349 \begin_inset Foot
6350 status collapsed
6351
6352 \begin_layout Plain Layout
6353 In the 
6354 \begin_inset Flex Code
6355 status collapsed
6356
6357 \begin_layout Plain Layout
6358 development/tools
6359 \end_layout
6360
6361 \end_inset
6362
6363  folder of a source distribution you can find a 
6364 \begin_inset Flex Code
6365 status collapsed
6366
6367 \begin_layout Plain Layout
6368 lyxeditor
6369 \end_layout
6370
6371 \end_inset
6372
6373  script which is able to locate the 
6374 \emph on
6375 lyxpipe
6376 \emph default
6377  based on your preferences.
6378 \end_layout
6379
6380 \end_inset
6381
6382
6383 \end_layout
6384
6385 \begin_layout Subsubsection*
6386 MacDviX (Mac OSX)
6387 \end_layout
6388
6389 \begin_layout Standard
6390 At the end of 
6391 \begin_inset Flex Code
6392 status collapsed
6393
6394 \begin_layout Plain Layout
6395 /Applications/MacDviX_Folder/calleditor.script
6396 \end_layout
6397
6398 \end_inset
6399
6400 , add the following lines:
6401 \end_layout
6402
6403 \begin_layout LyX-Code
6404 /Applications/Ly
6405 \begin_inset ERT
6406 status collapsed
6407
6408 \begin_layout Plain Layout
6409
6410 {}
6411 \end_layout
6412
6413 \end_inset
6414
6415 X.app/Contents/MacOS/lyxeditor "$2" $1
6416 \begin_inset Newline newline
6417 \end_inset
6418
6419 exit 1
6420 \end_layout
6421
6422 \begin_layout Standard
6423 Modify the lines accordingly if you install LyX somewhere else than in the
6424  Applications folder.
6425 \end_layout
6426
6427 \begin_layout Standard
6428 Reverse search is triggered by Alt-click (OPTION-click).
6429 \end_layout
6430
6431 \begin_layout Subsubsection*
6432 Skim (Mac OSX)
6433 \end_layout
6434
6435 \begin_layout Standard
6436 Enter 
6437 \begin_inset Flex Code
6438 status collapsed
6439
6440 \begin_layout Plain Layout
6441 open -a Skim.app $$i
6442 \end_layout
6443
6444 \end_inset
6445
6446  to the viewer setting in 
6447 \begin_inset Flex MenuItem
6448 status collapsed
6449
6450 \begin_layout Plain Layout
6451 Preferences\SpecialChar \menuseparator
6452 File Handling\SpecialChar \menuseparator
6453 File formats\SpecialChar \menuseparator
6454 PDF (pdflatex)
6455 \end_layout
6456
6457 \end_inset
6458
6459 , and then in 
6460 \begin_inset Flex MenuItem
6461 status collapsed
6462
6463 \begin_layout Plain Layout
6464 Skim\SpecialChar \menuseparator
6465 Preferences\SpecialChar \menuseparator
6466 Sync
6467 \end_layout
6468
6469 \end_inset
6470
6471  select Ly
6472 \begin_inset ERT
6473 status collapsed
6474
6475 \begin_layout Plain Layout
6476
6477 {}
6478 \end_layout
6479
6480 \end_inset
6481
6482 X.
6483 \end_layout
6484
6485 \begin_layout Standard
6486 Reverse search is triggered by COMMAND-SHIFT-click
6487 \end_layout
6488
6489 \begin_layout Subsubsection*
6490 Okular (KDE)
6491 \end_layout
6492
6493 \begin_layout Standard
6494 Go to 
6495 \begin_inset Flex MenuItem
6496 status collapsed
6497
6498 \begin_layout Plain Layout
6499 Settings\SpecialChar \menuseparator
6500 Configure Okular\SpecialChar \ldots{}
6501 \SpecialChar \menuseparator
6502 Editor
6503 \end_layout
6504
6505 \end_inset
6506
6507 , select 
6508 \begin_inset Quotes eld
6509 \end_inset
6510
6511 Custom Text Editor
6512 \begin_inset Quotes erd
6513 \end_inset
6514
6515  and add the command 
6516 \begin_inset Flex Code
6517 status collapsed
6518
6519 \begin_layout Plain Layout
6520 lyxclient -g %f %l
6521 \end_layout
6522
6523 \end_inset
6524
6525 .
6526 \end_layout
6527
6528 \begin_layout Standard
6529 Reverse search is triggered by SHIFT-click.
6530 \end_layout
6531
6532 \begin_layout Subsubsection*
6533 YAP (Windows)
6534 \end_layout
6535
6536 \begin_layout Standard
6537 Launch yap, choose its 
6538 \begin_inset Flex MenuItem
6539 status collapsed
6540
6541 \begin_layout Plain Layout
6542 View\SpecialChar \menuseparator
6543 Options
6544 \end_layout
6545
6546 \end_inset
6547
6548  menu and select the 
6549 \begin_inset Quotes eld
6550 \end_inset
6551
6552 Inverse DVI Search
6553 \begin_inset Quotes erd
6554 \end_inset
6555
6556  tab.
6557  Click on the 
6558 \begin_inset Quotes eld
6559 \end_inset
6560
6561 New\SpecialChar \ldots{}
6562
6563 \begin_inset Quotes erd
6564 \end_inset
6565
6566  button and, in the window that opens, enter 
6567 \begin_inset Quotes eld
6568 \end_inset
6569
6570 LyX Editor
6571 \begin_inset Quotes erd
6572 \end_inset
6573
6574  (or any other name you like) in the 
6575 \begin_inset Quotes eld
6576 \end_inset
6577
6578 Name:
6579 \begin_inset Quotes erd
6580 \end_inset
6581
6582  field.
6583  Now click on the button labeled 
6584 \begin_inset Quotes eld
6585 \end_inset
6586
6587 \SpecialChar \ldots{}
6588
6589 \begin_inset Quotes erd
6590 \end_inset
6591
6592  to open a file dialog and navigate to the directory containing the batch
6593  file 
6594 \begin_inset Flex Code
6595 status collapsed
6596
6597 \begin_layout Plain Layout
6598 lyxeditor.bat
6599 \end_layout
6600
6601 \end_inset
6602
6603  (see below).
6604  Select 
6605 \begin_inset Flex Code
6606 status collapsed
6607
6608 \begin_layout Plain Layout
6609 lyxeditor.bat
6610 \end_layout
6611
6612 \end_inset
6613
6614  and then specify the program arguments as 
6615 \begin_inset Flex Code
6616 status collapsed
6617
6618 \begin_layout Plain Layout
6619 %f %l
6620 \end_layout
6621
6622 \end_inset
6623
6624 .
6625  The 
6626 \begin_inset Flex Code
6627 status collapsed
6628
6629 \begin_layout Plain Layout
6630 lyxeditor.bat
6631 \end_layout
6632
6633 \end_inset
6634
6635  wrapper is used for communicating with LyX through the 
6636 \emph on
6637 lyxpipe
6638 \emph default
6639  and is as follows:
6640 \end_layout
6641
6642 \begin_layout LyX-Code
6643 @echo off
6644 \begin_inset Newline newline
6645 \end_inset
6646
6647 echo LYXCMD:revdvi:server-goto-file-row:%1 %2> 
6648 \backslash
6649
6650 \backslash
6651 .
6652 \backslash
6653 pipe
6654 \backslash
6655 lyxpipe.in
6656 \begin_inset Newline newline
6657 \end_inset
6658
6659 type 
6660 \backslash
6661
6662 \backslash
6663 .
6664 \backslash
6665 pipe
6666 \backslash
6667 lyxpipe.out
6668 \end_layout
6669
6670 \begin_layout Standard
6671 Make sure that the LyXServer pipe path you specified in LyX is 
6672 \begin_inset Flex Code
6673 status collapsed
6674
6675 \begin_layout Plain Layout
6676
6677 \backslash
6678
6679 \backslash
6680 .
6681 \backslash
6682 pipe
6683 \backslash
6684 lyxpipe
6685 \end_layout
6686
6687 \end_inset
6688
6689 , otherwise change the 
6690 \begin_inset Flex Code
6691 status collapsed
6692
6693 \begin_layout Plain Layout
6694 lyxeditor.bat
6695 \end_layout
6696
6697 \end_inset
6698
6699  wrapper accordingly.
6700 \end_layout
6701
6702 \begin_layout Standard
6703 In yap, reverse search is triggered by double-click.
6704 \end_layout
6705
6706 \begin_layout Subsubsection*
6707 SumatraPDF (Windows)
6708 \end_layout
6709
6710 \begin_layout Standard
6711 In order to use SumatraPDF for inverse search, enter 
6712 \begin_inset Flex Code
6713 status collapsed
6714
6715 \begin_layout Plain Layout
6716 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
6717 \end_layout
6718
6719 \end_inset
6720
6721  in the viewer setting in 
6722 \begin_inset Flex MenuItem
6723 status collapsed
6724
6725 \begin_layout Plain Layout
6726 Preferences\SpecialChar \menuseparator
6727 File Handling\SpecialChar \menuseparator
6728 File formats\SpecialChar \menuseparator
6729 PDF (pdflatex)
6730 \end_layout
6731
6732 \end_inset
6733
6734 , where 
6735 \begin_inset Flex Code
6736 status collapsed
6737
6738 \begin_layout Plain Layout
6739 lyxeditor.bat
6740 \end_layout
6741
6742 \end_inset
6743
6744  is the previous wrapper.
6745  If SumatraPDF.exe is not in your command PATH, use its full file name.
6746 \end_layout
6747
6748 \begin_layout Standard
6749 Reverse search is triggered by double-click.
6750 \end_layout
6751
6752 \begin_layout Subsubsection*
6753 YAP (Cygwin)
6754 \end_layout
6755
6756 \begin_layout Standard
6757 First of all, make sure that yap is your default DVI viewer in the Windows
6758  environment, then launch it, choose its 
6759 \begin_inset Flex MenuItem
6760 status collapsed
6761
6762 \begin_layout Plain Layout
6763 View\SpecialChar \menuseparator
6764 Options
6765 \end_layout
6766
6767 \end_inset
6768
6769  menu and select the 
6770 \begin_inset Quotes eld
6771 \end_inset
6772
6773 Inverse DVI Search
6774 \begin_inset Quotes erd
6775 \end_inset
6776
6777  tab.
6778  Click on the 
6779 \begin_inset Quotes eld
6780 \end_inset
6781
6782 New\SpecialChar \ldots{}
6783
6784 \begin_inset Quotes erd
6785 \end_inset
6786
6787  button and, in the window that opens, enter 
6788 \begin_inset Quotes eld
6789 \end_inset
6790
6791 LyX Editor
6792 \begin_inset Quotes erd
6793 \end_inset
6794
6795  (or any other name you like) in the 
6796 \begin_inset Quotes eld
6797 \end_inset
6798
6799 Name:
6800 \begin_inset Quotes erd
6801 \end_inset
6802
6803  field.
6804  Now click on the button labeled 
6805 \begin_inset Quotes eld
6806 \end_inset
6807
6808 \SpecialChar \ldots{}
6809
6810 \begin_inset Quotes erd
6811 \end_inset
6812
6813  to open a file dialog and navigate to the directory containing the 
6814 \begin_inset Flex Code
6815 status collapsed
6816
6817 \begin_layout Plain Layout
6818 lyxeditor.exe
6819 \end_layout
6820
6821 \end_inset
6822
6823  program (which is installed by default on Cygwin along with the LyX executable).
6824  Select 
6825 \begin_inset Flex Code
6826 status collapsed
6827
6828 \begin_layout Plain Layout
6829 lyxeditor.exe
6830 \end_layout
6831
6832 \end_inset
6833
6834  and then specify the program arguments as 
6835 \begin_inset Flex Code
6836 status collapsed
6837
6838 \begin_layout Plain Layout
6839 -g %f %l
6840 \end_layout
6841
6842 \end_inset
6843
6844 .
6845  In this way, you will be using the 
6846 \emph on
6847 lyxsocket
6848 \emph default
6849  for communicating with LyX.
6850  If, for whatever reason, you want to use the 
6851 \emph on
6852 lyxpipe
6853 \emph default
6854 , omit the 
6855 \begin_inset Flex Code
6856 status collapsed
6857
6858 \begin_layout Plain Layout
6859 -g
6860 \end_layout
6861
6862 \end_inset
6863
6864  option and be sure to specify the LyXServer pipe path in the LyX preferences.
6865 \end_layout
6866
6867 \begin_layout Standard
6868 In yap, reverse search is triggered by double-click.
6869 \end_layout
6870
6871 \begin_layout Subsubsection*
6872 SumatraPDF (Cygwin)
6873 \end_layout
6874
6875 \begin_layout Standard
6876 In order to use SumatraPDF for inverse search, enter 
6877 \begin_inset Flex Code
6878 status collapsed
6879
6880 \begin_layout Plain Layout
6881 SumatraPDF.sh
6882 \end_layout
6883
6884 \end_inset
6885
6886  in the viewer setting in 
6887 \begin_inset Flex MenuItem
6888 status collapsed
6889
6890 \begin_layout Plain Layout
6891 Preferences\SpecialChar \menuseparator
6892 File Handling\SpecialChar \menuseparator
6893 File formats\SpecialChar \menuseparator
6894 PDF (pdflatex)
6895 \end_layout
6896
6897 \end_inset
6898
6899 , where 
6900 \begin_inset Flex Code
6901 status collapsed
6902
6903 \begin_layout Plain Layout
6904 SumatraPDF.sh
6905 \end_layout
6906
6907 \end_inset
6908
6909  is the following script (to be placed in your command PATH, 
6910 \begin_inset Flex Code
6911 status collapsed
6912
6913 \begin_layout Plain Layout
6914 /usr/local/bin
6915 \end_layout
6916
6917 \end_inset
6918
6919  being the best choice):
6920 \end_layout
6921
6922 \begin_layout LyX-Code
6923 #!/bin/bash
6924 \begin_inset Newline newline
6925 \end_inset
6926
6927 cd $(dirname $1)
6928 \begin_inset Newline newline
6929 \end_inset
6930
6931 SumatraPDF -inverse-search "lyxeditor -g %f %l" $(basename $1)
6932 \end_layout
6933
6934 \begin_layout Standard
6935 This wrapper script is needed because SumatraPDF is a native Windows application
6936  and does not understand the posix paths used by the Cygwin version of LyX.
6937  If SumatraPDF.exe is not in your command PATH, use its full posix path in
6938  the script above.
6939  The 
6940 \begin_inset Flex Code
6941 status collapsed
6942
6943 \begin_layout Plain Layout
6944 -g
6945 \end_layout
6946
6947 \end_inset
6948
6949  enables communication via the 
6950 \emph on
6951 lyxsocket
6952 \emph default
6953 .
6954  Again, omit the 
6955 \begin_inset Flex Code
6956 status collapsed
6957
6958 \begin_layout Plain Layout
6959 -g
6960 \end_layout
6961
6962 \end_inset
6963
6964  option if you want to use the 
6965 \emph on
6966 lyxpipe
6967 \emph default
6968 , and be sure to specify the LyXServer pipe path in the LyX preferences.
6969 \end_layout
6970
6971 \begin_layout Standard
6972 Reverse search is triggered by double-click.
6973 \end_layout
6974
6975 \begin_layout Section
6976 Forward search
6977 \end_layout
6978
6979 \begin_layout Standard
6980 Forward search is, as the name implies, in a sense the 
6981 \begin_inset Quotes eld
6982 \end_inset
6983
6984 opposite
6985 \begin_inset Quotes erd
6986 \end_inset
6987
6988  to reverse search.
6989  It allows you to let the viewer jump to a given position from within LyX.
6990  If forward search is set up (as described in what follows), you can put
6991  the cursor anywhere in your LyX document, and hit 
6992 \begin_inset Flex MenuItem
6993 status collapsed
6994
6995 \begin_layout Plain Layout
6996 Navigate\SpecialChar \menuseparator
6997 Forward search
6998 \end_layout
6999
7000 \end_inset
7001
7002  (or select 
7003 \begin_inset Flex MenuItem
7004 status collapsed
7005
7006 \begin_layout Plain Layout
7007 Forward search
7008 \end_layout
7009
7010 \end_inset
7011
7012  in the context menu via right mouse click), and then the viewer will jump
7013  to that position as well.
7014  This implies, of course, that your viewer supports this function.
7015 \end_layout
7016
7017 \begin_layout Standard
7018 To make forward search possible, you first need to provide the generated
7019  output PDF/DVI file with additional information about the TeX sources.
7020  This can be done via the methods described in the section 
7021 \begin_inset CommandInset ref
7022 LatexCommand ref
7023 reference "sub:rev-search"
7024
7025 \end_inset
7026
7027 .
7028 \end_layout
7029
7030 \begin_layout Standard
7031 Additionally, you need to configure LyX for using your viewers in 
7032 \begin_inset Flex MenuItem
7033 status collapsed
7034
7035 \begin_layout Plain Layout
7036 Tools\SpecialChar \menuseparator
7037 Preferences\SpecialChar \menuseparator
7038 Output\SpecialChar \menuseparator
7039 General
7040 \end_layout
7041
7042 \end_inset
7043
7044 .
7045  We provide a range of tested configurations for some viewers, which you
7046  can select from the drop down list.
7047  If none of these configurations suits you, you have to find out and enter
7048  a suitable configuration yourself.
7049  The definition syntax uses the following placeholders: 
7050 \end_layout
7051
7052 \begin_layout Itemize
7053 \noindent
7054 \begin_inset Flex Code
7055 status collapsed
7056
7057 \begin_layout Plain Layout
7058 $$n
7059 \end_layout
7060
7061 \end_inset
7062
7063 : row number
7064 \end_layout
7065
7066 \begin_layout Itemize
7067 \noindent
7068 \begin_inset Flex Code
7069 status collapsed
7070
7071 \begin_layout Plain Layout
7072 $$t
7073 \end_layout
7074
7075 \end_inset
7076
7077 : name of the (temporary) exported .tex file
7078 \end_layout
7079
7080 \begin_layout Itemize
7081 \noindent
7082 \begin_inset Flex Code
7083 status collapsed
7084
7085 \begin_layout Plain Layout
7086 $$o
7087 \end_layout
7088
7089 \end_inset
7090
7091 : name of the exported output file (either dvi or pdf, depending on which
7092  one exists in the temporary directory)
7093 \end_layout
7094
7095 \begin_layout Standard
7096 Note that only some of the viewers provide full forward search functionality,
7097  among them yap, xdvi, okular and Sumatra PDF
7098 \begin_inset Foot
7099 status collapsed
7100
7101 \begin_layout Plain Layout
7102 For Sumatra CMCDDE is needed --- downloadable from http://www.istri.fr/zip/CMCDDE.z
7103 ip
7104 \end_layout
7105
7106 \end_inset
7107
7108 .
7109  While many of the widespread PDF viewers (most notably Adobe Reader) do
7110  not support forward search at all, some other viewers -- e.
7111 \begin_inset space \thinspace{}
7112 \end_inset
7113
7114 g.
7115  evince and xpdf -- allow at least to reload the document and jump to a
7116  specific page of the file, so you can at least navigate 
7117 \begin_inset Quotes eld
7118 \end_inset
7119
7120 near
7121 \begin_inset Quotes erd
7122 \end_inset
7123
7124 .
7125  These latter functionality is provided by an external call of synctex (see
7126  the predefined example configurations).
7127  
7128 \end_layout
7129
7130 \begin_layout Standard
7131 Forward search works both with DVI and PDF output.
7132  LyX simply checks which preview format you have used before (i.
7133 \begin_inset space \thinspace{}
7134 \end_inset
7135
7136 e., which format is already there in the temporary directory) and chooses
7137  the appropriate configuration for the respective format.
7138 \end_layout
7139
7140 \begin_layout Chapter
7141 Special Document Classes
7142 \end_layout
7143
7144 \begin_layout Section
7145 A&A Paper
7146 \end_layout
7147
7148 \begin_layout Standard
7149 by 
7150 \noun on
7151 Peter Sütterlin
7152 \end_layout
7153
7154 \begin_layout Subsection
7155 Introduction
7156 \end_layout
7157
7158 \begin_layout Standard
7159 This section describes how LyX can be used to write articles for submission
7160  to the scientific journal 
7161 \emph on
7162 Astronomy and Astrophysics
7163 \emph default
7164  (www.edpsciences.fr/aa/ 
7165 \begin_inset Flex URL
7166 status collapsed
7167
7168 \begin_layout Plain Layout
7169
7170 http://www.edpsciences.fr/aa/
7171 \end_layout
7172
7173 \end_inset
7174
7175 ) using Version 5.01 of the document class 
7176 \family typewriter
7177 aa.cls
7178 \family default
7179 .
7180  This package can be downloaded from the ftp site
7181 \end_layout
7182
7183 \begin_layout Standard
7184 \begin_inset VSpace medskip
7185 \end_inset
7186
7187
7188 \end_layout
7189
7190 \begin_layout Standard
7191 \align center
7192 \begin_inset Flex URL
7193 status collapsed
7194
7195 \begin_layout Plain Layout
7196
7197 ftp://ftp.edpsciences.org/pub/aa/readme.html
7198 \end_layout
7199
7200 \end_inset
7201
7202
7203 \end_layout
7204
7205 \begin_layout Standard
7206 \begin_inset VSpace medskip
7207 \end_inset
7208
7209
7210 \end_layout
7211
7212 \begin_layout Standard
7213 A manual comes together with that package, and this text is not meant to
7214  replace the original manual but is merely a short guide in how to realize
7215  the correct form of your paper.
7216  
7217 \end_layout
7218
7219 \begin_layout Standard
7220 Please note that the publisher of the journal was changed from Springer
7221  to EDP Sciences starting January 1, 2001.
7222  That change involved also some slight changes to the style files, namely
7223  the removal of the thesaurus command.
7224  The LyX class aa supports the newest version of these style files, V 5.01.
7225  If you have an older version installed, please upgrade.
7226  For compatibility, the old (version 4) layout has been kept as 
7227 \family sans
7228 article (A&A V4)
7229 \family default
7230 .
7231  Please refer to the comments in 
7232 \family typewriter
7233 LyXDir/layouts/aapaper.layout
7234 \family default
7235 .
7236 \end_layout
7237
7238 \begin_layout Subsection
7239 Getting started
7240 \end_layout
7241
7242 \begin_layout Standard
7243 It is recommended you start from the example template distributed with LyX.
7244  If you are not using a template, note the following settings:
7245 \end_layout
7246
7247 \begin_layout Itemize
7248 Select 
7249 \family sans
7250 article (A&A)
7251 \family default
7252  in the 
7253 \family sans
7254 Document\SpecialChar \menuseparator
7255 Settings
7256 \family default
7257  dialog (OK, that one was obvious).
7258 \end_layout
7259
7260 \begin_layout Itemize
7261 Don't change the option 
7262 \family sans
7263 Page
7264 \begin_inset space ~
7265 \end_inset
7266
7267 style
7268 \family default
7269 : Leave it set to 
7270 \family sans
7271 default
7272 \family default
7273 .
7274  The whole layout is done by the macros, you shouldn't change anything.
7275 \end_layout
7276
7277 \begin_layout Subsection
7278 The header block
7279 \end_layout
7280
7281 \begin_layout Standard
7282 First thing to enter is the header information.
7283  It consists of seven entries, of which some are optional.
7284  They are
7285 \end_layout
7286
7287 \begin_layout Itemize
7288
7289 \family sans
7290 Title
7291 \family default
7292 : [required] 
7293 \end_layout
7294
7295 \begin_layout Itemize
7296
7297 \family sans
7298 Subtitle
7299 \family default
7300 : [optional] 
7301 \end_layout
7302
7303 \begin_layout Itemize
7304
7305 \family sans
7306 Author
7307 \family default
7308 : [required]
7309 \end_layout
7310
7311 \begin_layout Itemize
7312
7313 \family sans
7314 Address
7315 \family default
7316 : [required]
7317 \end_layout
7318
7319 \begin_layout Itemize
7320
7321 \family sans
7322 Offprints
7323 \family default
7324 : [optional] if more than one author: whom to contact for offprint requests.
7325 \end_layout
7326
7327 \begin_layout Itemize
7328
7329 \family sans
7330 Mail
7331 \family default
7332 : [optional] mail address for contacts.
7333 \end_layout
7334
7335 \begin_layout Itemize
7336
7337 \family sans
7338 Date
7339 \family default
7340 : [required].
7341  Suggested format is 
7342 \family typewriter
7343 Received: <date>; Accepted <date> 
7344 \end_layout
7345
7346 \begin_layout Standard
7347 There is no need to issue the 
7348 \family typewriter
7349
7350 \backslash
7351 maketitle
7352 \family default
7353  command, this is done automatically by LyX when the header is finished.
7354  Although the order of the single header entries doesn't matter it is advised
7355  to keep the above sequence, just to get the best optics and meets the layout
7356  of the real document.
7357 \end_layout
7358
7359 \begin_layout Standard
7360 If you want to place footnotes in the header block, e.
7361 \begin_inset space \thinspace{}
7362 \end_inset
7363
7364 g.
7365 \begin_inset space \space{}
7366 \end_inset
7367
7368 to state your present address, just use the standard footnote via the menu
7369  
7370 \family sans
7371 Insert\SpecialChar \menuseparator
7372 Footnote.
7373
7374 \family default
7375  LyX will automagically use the term 
7376 \family typewriter
7377
7378 \backslash
7379 thanks{}
7380 \family default
7381  in that case.
7382 \end_layout
7383
7384 \begin_layout Standard
7385 In addition to these topics, the macros use three additional LaTeX commands
7386  that have no counterpart in LyX:
7387 \end_layout
7388
7389 \begin_layout Itemize
7390
7391 \family typewriter
7392
7393 \backslash
7394 and
7395 \family default
7396  to separate different names for more than one author and institute, respectivel
7397 y.
7398 \end_layout
7399
7400 \begin_layout Itemize
7401
7402 \family typewriter
7403
7404 \backslash
7405 inst{<nr>}
7406 \family default
7407 to mark corresponding author/institute pairs.
7408  The institutes are numbered sequentially as they appear in the 
7409 \family sans
7410 Address
7411 \family default
7412  field, so you have to put a marker to each author.
7413 \end_layout
7414
7415 \begin_layout Itemize
7416
7417 \family typewriter
7418
7419 \backslash
7420 email{address}
7421 \family default
7422  to supply an email address for fast contact.
7423 \end_layout
7424
7425 \begin_layout Standard
7426 In all cases, the appropriate command has to be entered in LyX and marked
7427  as LaTeX code.
7428  See the examples.
7429  
7430 \end_layout
7431
7432 \begin_layout Subsection
7433 The abstract
7434 \end_layout
7435
7436 \begin_layout Standard
7437 The abstract should immediately follow the header block.
7438  With version 5 the abstract environment was changed to a command, and there
7439  is now a resctriction to only one paragraph.
7440  In addition, it should contain an entry with the keywords.
7441  This is not yet implemented for LyX, therefore you have to enter the LaTeX
7442  command 
7443 \family typewriter
7444
7445 \backslash
7446 keywords{}
7447 \family default
7448  by hand and mark it as LaTeX code.
7449  Refer to the example paper.
7450 \end_layout
7451
7452 \begin_layout Subsection
7453 Supported environments
7454 \end_layout
7455
7456 \begin_layout Standard
7457 The A&A paper layout supports the following environments for structuring
7458  your text:
7459 \end_layout
7460
7461 \begin_layout Itemize
7462
7463 \family sans
7464 Standard
7465 \end_layout
7466
7467 \begin_layout Itemize
7468
7469 \family sans
7470 Section
7471 \end_layout
7472
7473 \begin_layout Itemize
7474
7475 \family sans
7476 Subsection
7477 \end_layout
7478
7479 \begin_layout Itemize
7480
7481 \family sans
7482 Subsubsection
7483 \end_layout
7484
7485 \begin_layout Itemize
7486
7487 \family sans
7488 Itemize
7489 \end_layout
7490
7491 \begin_layout Itemize
7492
7493 \family sans
7494 Enumerate
7495 \end_layout
7496
7497 \begin_layout Itemize
7498
7499 \family sans
7500 Description
7501 \end_layout
7502
7503 \begin_layout Itemize
7504
7505 \family sans
7506 Caption
7507 \end_layout
7508
7509 \begin_layout Itemize
7510
7511 \family sans
7512 Abstract
7513 \end_layout
7514
7515 \begin_layout Itemize
7516
7517 \family sans
7518 Acknowledgment
7519 \end_layout
7520
7521 \begin_layout Itemize
7522
7523 \family sans
7524 Bibliography
7525 \end_layout
7526
7527 \begin_layout Itemize
7528
7529 \family sans
7530 LaTeX
7531 \end_layout
7532
7533 \begin_layout Subsection
7534 Commands not supported by LyX
7535 \end_layout
7536
7537 \begin_layout Standard
7538 Some commands are not yet supported by the 
7539 \family sans
7540 paper (A&A)
7541 \family default
7542  layout for LyX.
7543  Some have already been mentioned.
7544  For the sake of completeness, they are listed all together here:
7545 \end_layout
7546
7547 \begin_layout Itemize
7548
7549 \family typewriter
7550
7551 \backslash
7552 and
7553 \end_layout
7554
7555 \begin_layout Itemize
7556
7557 \family typewriter
7558
7559 \backslash
7560 email
7561 \end_layout
7562
7563 \begin_layout Itemize
7564
7565 \family typewriter
7566
7567 \backslash
7568 appendix
7569 \end_layout
7570
7571 \begin_layout Itemize
7572
7573 \family typewriter
7574
7575 \backslash
7576 authorrunning
7577 \end_layout
7578
7579 \begin_layout Itemize
7580
7581 \family typewriter
7582
7583 \backslash
7584 inst{}
7585 \end_layout
7586
7587 \begin_layout Itemize
7588
7589 \family typewriter
7590
7591 \backslash
7592 keywords{}
7593 \end_layout
7594
7595 \begin_layout Itemize
7596
7597 \family typewriter
7598
7599 \backslash
7600 object{}
7601 \end_layout
7602
7603 \begin_layout Itemize
7604
7605 \family typewriter
7606
7607 \backslash
7608 titlerunning{}
7609 \end_layout
7610
7611 \begin_layout Standard
7612 If you want to use any of these commands, you have to enter them yourself.
7613  
7614 \series bold
7615 Do not forget to mark them as LaTeX code!
7616 \end_layout
7617
7618 \begin_layout Subsection
7619 Figure and Table Floats
7620 \end_layout
7621
7622 \begin_layout Standard
7623 LyX provides support for the necessary float environments 
7624 \family sans
7625 figure, figure*, table
7626 \family default
7627  and 
7628 \family sans
7629 table*
7630 \family default
7631 , therefore we won't tell much about it here.
7632  Refer to the 
7633 \emph on
7634 User's
7635 \begin_inset space ~
7636 \end_inset
7637
7638 Guide
7639 \emph default
7640 .
7641  Just remember that tables should be left-aligned.
7642  For that, select the table and change the alignment in 
7643 \family sans
7644 Edit\SpecialChar \menuseparator
7645 Paragraph
7646 \begin_inset space ~
7647 \end_inset
7648
7649 Settings.
7650 \end_layout
7651
7652 \begin_layout Standard
7653 There is only one special thing: the figures with caption besides the figure.
7654  To create such a figure, you have to do the following:
7655 \end_layout
7656
7657 \begin_layout Enumerate
7658 Create a wide figure float: 
7659 \family sans
7660 Insert\SpecialChar \menuseparator
7661 Float\SpecialChar \menuseparator
7662 Figure
7663 \family default
7664 , then right click in the figure and select 
7665 \family sans
7666 \bar under
7667 S
7668 \bar default
7669 pan
7670 \begin_inset space ~
7671 \end_inset
7672
7673 columns
7674 \family default
7675 .
7676 \end_layout
7677
7678 \begin_layout Enumerate
7679 Enter your caption text.
7680 \end_layout
7681
7682 \begin_layout Enumerate
7683 Press 
7684 \family sans
7685 Return
7686 \family default
7687  to move the cursor above the caption.
7688 \end_layout
7689
7690 \begin_layout Enumerate
7691 Insert your figure
7692 \end_layout
7693
7694 \begin_layout Enumerate
7695 Position the cursor behind the figure and insert a horizontal fill: 
7696 \family sans
7697 Insert\SpecialChar \menuseparator
7698 Special
7699 \begin_inset space ~
7700 \end_inset
7701
7702 Character\SpecialChar \menuseparator
7703 Horizontal
7704 \begin_inset space ~
7705 \end_inset
7706
7707 Fill
7708 \family default
7709 .
7710 \end_layout
7711
7712 \begin_layout Enumerate
7713 Switch to LaTeX mode: 
7714 \family sans
7715 M-c
7716 \begin_inset space ~
7717 \end_inset
7718
7719 t
7720 \family default
7721 .
7722 \end_layout
7723
7724 \begin_layout Enumerate
7725 Enter 
7726 \family typewriter
7727
7728 \backslash
7729 parbox[b]{55mm}{
7730 \family default
7731 .
7732  
7733 \series bold
7734 Do not close the brace!
7735 \end_layout
7736
7737 \begin_layout Enumerate
7738 Position the cursor behind the caption text, switch to LaTeX mode and insert
7739  the closing brace: 
7740 \family sans
7741 M-c
7742 \begin_inset space ~
7743 \end_inset
7744
7745 t
7746 \family default
7747  
7748 \family typewriter
7749 }
7750 \family default
7751 .
7752 \end_layout
7753
7754 \begin_layout Standard
7755 Also, refer to the figures in the example paper.
7756 \end_layout
7757
7758 \begin_layout Subsection
7759 Referee layout
7760 \end_layout
7761
7762 \begin_layout Standard
7763 For submission, the paper has to be formated in a special double-spacing
7764  layout.
7765  For this purpose, you have to give the option 
7766 \family typewriter
7767 referee
7768 \family default
7769  to the documentclass.
7770  This must be done using the extra class options field in the 
7771 \family sans
7772 Document\SpecialChar \menuseparator
7773 Settings
7774 \family default
7775  dialog.
7776  Just enter the string 
7777 \family typewriter
7778 referee
7779 \family default
7780  there.
7781 \end_layout
7782
7783 \begin_layout Subsection
7784 The example paper
7785 \end_layout
7786
7787 \begin_layout Standard
7788 The 
7789 \family sans
7790 Examples
7791 \family default
7792  directory contains an example paper written with LyX.
7793  It is the example paper from the original macro package, translated to
7794  LyX.
7795  Use it for inspiration, and compare the original LaTeX code with LyX way
7796  of writing.
7797 \end_layout
7798
7799 \begin_layout Section
7800 AASTeX
7801 \end_layout
7802
7803 \begin_layout Standard
7804 by 
7805 \noun on
7806 Mike Ressler
7807 \end_layout
7808
7809 \begin_layout Subsection
7810 Introduction
7811 \end_layout
7812
7813 \begin_layout Standard
7814 AASTeX is a set of macros produced by the American Astronomical Society
7815  to facilitate electronic manuscript submission to the three journals they
7816  publish: the Astrophysical Journal (including the Letters and Supplement),
7817  the Astronomical Journal, and the Publications of the Astronomical Society
7818  of the Pacific.
7819  LyX has proven to be an excellent tool for generating these documents,
7820  especially given its equation, citation, and figure handling capabilities.
7821  LyX requires version 5.0 (or higher) of these macros; preferably 5.2, which
7822  is the version described here, or higher.
7823  Versions prior to 5.0 are intended for use with LaTeX2.09 and are fundamentally
7824  incompatible with LyX.
7825  The AASTeX package may be downloaded from the AASTeX Web site
7826 \end_layout
7827
7828 \begin_layout Standard
7829 \begin_inset VSpace medskip
7830 \end_inset
7831
7832
7833 \end_layout
7834
7835 \begin_layout Standard
7836 \align center
7837 \begin_inset Flex URL
7838 status collapsed
7839
7840 \begin_layout Plain Layout
7841
7842 http://www.journals.uchicago.edu/AAS/AASTeX
7843 \end_layout
7844
7845 \end_inset
7846
7847
7848 \end_layout
7849
7850 \begin_layout Standard
7851 \begin_inset VSpace medskip
7852 \end_inset
7853
7854
7855 \end_layout
7856
7857 \begin_layout Standard
7858 A complete user guide is contained in that package and you should familiarize
7859  yourself with it thoroughly before embarking on writing a paper in LyX.
7860  LyX will not reduce the need to figure out all the AASTeX commands, it
7861  will only reduce the drudgery of typing everything in.
7862  It is your responsibility to ensure that the final exported LaTeX document
7863  conforms completely to the requirements of the journal to which you are
7864  submitting your paper.
7865 \end_layout
7866
7867 \begin_layout Subsection
7868 Starting a New Paper
7869 \end_layout
7870
7871 \begin_layout Standard
7872 I strongly suggest that you start with the AASTeX template file.
7873  Click on 
7874 \family sans
7875 File\SpecialChar \menuseparator
7876 New from
7877 \family default
7878  
7879 \family sans
7880 Template
7881 \family default
7882 , enter the new file name, then choose the 
7883 \family typewriter
7884 aastex.lyx
7885 \family default
7886  template.
7887  This will show the most common fields found in a manuscript.
7888  Simply overwrite the existing text (including the brackets, 
7889 \family typewriter
7890 <>
7891 \family default
7892 ) with the correct information.
7893  Many of the AASTeX commands and environments can be implemented directly
7894  in LyX, but some cannot: most noticeably 
7895 \family typewriter
7896
7897 \backslash
7898 altaffilmark
7899 \family default
7900  and 
7901 \family typewriter
7902
7903 \backslash
7904 altaffiltext
7905 \family default
7906 , which should stick out like a sore thumb if you actually just opened the
7907  template file.
7908  For commands such as these, the LaTeX code must be entered directly and
7909  marked as such.
7910  Such commands are referred to as TeX code, or Evil Red Text.
7911  I tried to minimize the amount of TeX code needed in an AASTeX document,
7912  but there is still a bit more required than any of us would like.
7913 \end_layout
7914
7915 \begin_layout Subsection
7916 Finishing Your Paper
7917 \end_layout
7918
7919 \begin_layout Standard
7920 When the paper is finished to your satisfaction and previews/prints correctly,
7921  there are a few 
7922 \begin_inset Quotes eld
7923 \end_inset
7924
7925 postprocessing
7926 \begin_inset Quotes erd
7927 \end_inset
7928
7929  actions which need to be done before you submit it to the journals.
7930  
7931 \end_layout
7932
7933 \begin_layout Enumerate
7934 Export your paper as a LaTeX file (
7935 \family sans
7936 File\SpecialChar \menuseparator
7937 Export\SpecialChar \menuseparator
7938 LaTeX
7939 \family default
7940 ).
7941  
7942 \end_layout
7943
7944 \begin_layout Enumerate
7945 Edit the resulting 
7946 \family typewriter
7947 .tex
7948 \family default
7949  file with your favorite text editor
7950 \end_layout
7951
7952 \begin_deeper
7953 \begin_layout Enumerate
7954 remove the comment lines before the 
7955 \family typewriter
7956
7957 \backslash
7958 documentclass
7959 \family default
7960  command
7961 \end_layout
7962
7963 \begin_layout Enumerate
7964 remove the 
7965 \family typewriter
7966
7967 \backslash
7968 usepackage...{fontenc}
7969 \family default
7970  line if it appears (usually just after 
7971 \family typewriter
7972
7973 \backslash
7974 documentclass
7975 \family default
7976 }; also remove the 
7977 \family typewriter
7978
7979 \backslash
7980 secnumdepth
7981 \family default
7982  line if it appears.
7983 \end_layout
7984
7985 \begin_layout Enumerate
7986 remove everything between (and including) the 
7987 \family typewriter
7988
7989 \backslash
7990 makeatletter
7991 \family default
7992  and 
7993 \family typewriter
7994
7995 \backslash
7996 makeatother
7997 \family default
7998  commands, except for any commands you specifically put into the LaTeX preamble
7999  (which should appear immediately after the 
8000 \begin_inset Quotes eld
8001 \end_inset
8002
8003 User specified LaTeX commands
8004 \begin_inset Quotes erd
8005 \end_inset
8006
8007  comment in the 
8008 \family typewriter
8009 .tex
8010 \family default
8011  file).
8012 \end_layout
8013
8014 \end_deeper
8015 \begin_layout Enumerate
8016 Run the resulting file through LaTeX to make sure it still processes correctly.
8017 \end_layout
8018
8019 \begin_layout Enumerate
8020 Reread the journal requirements to make sure your filenames and formats
8021  are correct.
8022 \end_layout
8023
8024 \begin_layout Enumerate
8025 Submit it.
8026 \end_layout
8027
8028 \begin_layout Subsection
8029 Comments On Specific Commands
8030 \end_layout
8031
8032 \begin_layout Standard
8033 I will not describe the detailed usage of the individual AASTeX commands:
8034  the AASTeX User Guide (
8035 \family typewriter
8036 aasguide.tex
8037 \family default
8038 ) gives a good description of each.
8039  Thus it's probably easiest for me to go down the list as found in the guide
8040  and offer comments where necessary.
8041  So let's begin \SpecialChar \ldots{}
8042
8043 \end_layout
8044
8045 \begin_layout Subsubsection
8046 Things that work as expected
8047 \end_layout
8048
8049 \begin_layout Standard
8050 Because they work as you might expect, I simply list them and the section
8051  they are found in: 
8052 \family typewriter
8053
8054 \backslash
8055 documentclass
8056 \family default
8057  (2.1.1), 
8058 \family typewriter
8059
8060 \backslash
8061 begin{document}
8062 \family default
8063  (2.2), 
8064 \family typewriter
8065
8066 \backslash
8067 title
8068 \family default
8069  (2.3), 
8070 \family typewriter
8071
8072 \backslash
8073 author
8074 \family default
8075  (2.3), 
8076 \family typewriter
8077
8078 \backslash
8079 affil
8080 \family default
8081  (2.3), 
8082 \family typewriter
8083
8084 \backslash
8085 abstract
8086 \family default
8087  (2.4), 
8088 \family typewriter
8089
8090 \backslash
8091 keywords
8092 \family default
8093  (2.5), 
8094 \family typewriter
8095
8096 \backslash
8097 section
8098 \family default
8099  (2.7), 
8100 \family typewriter
8101
8102 \backslash
8103 subsection
8104 \family default
8105  (2.7), 
8106 \family typewriter
8107
8108 \backslash
8109 subsubsection
8110 \family default
8111  (2.7), 
8112 \family typewriter
8113
8114 \backslash
8115 paragraph
8116 \family default
8117  (2.7), 
8118 \family typewriter
8119
8120 \backslash
8121 facility
8122 \family default
8123  (2.10), 
8124 \family typewriter
8125
8126 \backslash
8127 begin{displaymath}
8128 \family default
8129  (2.12), 
8130 \family typewriter
8131
8132 \backslash
8133 begin{equation}
8134 \family default
8135  (2.12), 
8136 \family typewriter
8137
8138 \backslash
8139 begin{eqnarray}
8140 \family default
8141  (2.12), 
8142 \family typewriter
8143
8144 \backslash
8145 begin{mathletters}
8146 \family default
8147  (2.12), 
8148 \family typewriter
8149
8150 \backslash
8151 begin{thebibliography}
8152 \family default
8153  (2.13.1), 
8154 \family typewriter
8155
8156 \backslash
8157 bibitem
8158 \family default
8159  (2.13.2), all the cite commands and their variations (2.13.2), the generic
8160  graphicx figure commands (2.14.1), 
8161 \family typewriter
8162
8163 \backslash
8164 begin{table}
8165 \family default
8166  (2.15.4), 
8167 \family typewriter
8168
8169 \backslash
8170 begin{tabular}
8171 \family default
8172  (2.15.4), 
8173 \family typewriter
8174
8175 \backslash
8176 caption
8177 \family default
8178  (2.15.4), 
8179 \family typewriter
8180
8181 \backslash
8182 label
8183 \family default
8184  (2.15.4, amongst other places), 
8185 \family typewriter
8186
8187 \backslash
8188 tablerefs
8189 \family default
8190  (2.15.5), 
8191 \family typewriter
8192
8193 \backslash
8194 tablecomments
8195 \family default
8196  (2.15.5), 
8197 \family typewriter
8198
8199 \backslash
8200 url
8201 \family default
8202  (2.17.4), 
8203 \family typewriter
8204
8205 \backslash
8206 end{document}
8207 \family default
8208  (2.18).
8209 \end_layout
8210
8211 \begin_layout Standard
8212 The following style options also work correctly: 
8213 \family typewriter
8214 longabstract
8215 \family default
8216  (2.4), 
8217 \family typewriter
8218 preprint
8219 \family default
8220  (3.2.1), 
8221 \family typewriter
8222 preprint2
8223 \family default
8224  (3.2.2), 
8225 \family typewriter
8226 eqsecnum
8227 \family default
8228  (3.3), 
8229 \family typewriter
8230 flushrt
8231 \family default
8232  (3.4).
8233  Simply put them in the 
8234 \family sans
8235 Options
8236 \family default
8237  box in 
8238 \family sans
8239 Layout\SpecialChar \menuseparator
8240 Document
8241 \family default
8242 .
8243 \end_layout
8244
8245 \begin_layout Subsubsection
8246 Things that work, but require more comment
8247 \end_layout
8248
8249 \begin_layout Standard
8250 The following items work, but require a little more discussion:
8251 \end_layout
8252
8253 \begin_layout Itemize
8254 These items are reserved for use by the journal editors, but you can put
8255  them into the LaTeX preamble if you feel compelled to do so: 
8256 \family typewriter
8257
8258 \backslash
8259 received
8260 \family default
8261
8262 \family typewriter
8263
8264 \backslash
8265 revised
8266 \family default
8267
8268 \family typewriter
8269
8270 \backslash
8271 accepted
8272 \family default
8273
8274 \family typewriter
8275
8276 \backslash
8277 ccc
8278 \family default
8279
8280 \family typewriter
8281
8282 \backslash
8283 cpright
8284 \family default
8285  (all from 2.1.3)
8286 \end_layout
8287
8288 \begin_layout Itemize
8289 These items may be placed in the LaTeX preamble, and are included as blanks
8290  in the template file: 
8291 \family typewriter
8292
8293 \backslash
8294 slugcomment
8295 \family default
8296  (2.1.4), 
8297 \family typewriter
8298
8299 \backslash
8300 shorttitle
8301 \family default
8302  (2.1.5), 
8303 \family typewriter
8304
8305 \backslash
8306 shortauthors
8307 \family default
8308  (2.1.5)
8309 \end_layout
8310
8311 \begin_layout Itemize
8312
8313 \family typewriter
8314
8315 \backslash
8316 email
8317 \family default
8318  (2.3) – can only be used 
8319 \begin_inset Quotes eld
8320 \end_inset
8321
8322 standalone
8323 \begin_inset Quotes erd
8324 \end_inset
8325
8326 , not in the middle of a paragraph.
8327  Use TeX code if you need to embed it.
8328 \end_layout
8329
8330 \begin_layout Itemize
8331
8332 \family typewriter
8333
8334 \backslash
8335 and
8336 \family default
8337  (2.3) – will have extra {} after it.
8338  This should not cause an error.
8339 \end_layout
8340
8341 \begin_layout Itemize
8342
8343 \family typewriter
8344
8345 \backslash
8346 notetoeditor
8347 \family default
8348  (2.6) – can only be used 
8349 \begin_inset Quotes eld
8350 \end_inset
8351
8352 standalone
8353 \begin_inset Quotes erd
8354 \end_inset
8355
8356 , not in the middle of a paragraph.
8357  Use TeX code if you need to embed it.
8358 \end_layout
8359
8360 \begin_layout Itemize
8361
8362 \family typewriter
8363
8364 \backslash
8365 placetable
8366 \family default
8367  (2.8) – can't insert a cross-reference tag, you must type the tag name by
8368  hand
8369 \end_layout
8370
8371 \begin_layout Itemize
8372
8373 \family typewriter
8374
8375 \backslash
8376 placefigure
8377 \family default
8378  (2.8) – same as for 
8379 \family typewriter
8380
8381 \backslash
8382 placetable
8383 \end_layout
8384
8385 \begin_layout Itemize
8386
8387 \family typewriter
8388
8389 \backslash
8390 acknowledgements
8391 \family default
8392  (2.9) – will have extra {} after it.
8393  This should not cause an error.
8394 \end_layout
8395
8396 \begin_layout Itemize
8397
8398 \family typewriter
8399
8400 \backslash
8401 appendix
8402 \family default
8403  (2.11) – will have extra {} after it.
8404  This should not cause an error.
8405 \end_layout
8406
8407 \begin_layout Itemize
8408
8409 \family typewriter
8410
8411 \backslash
8412 figcaption
8413 \family default
8414  (2.14.2) – you can insert an optional filename argument by placing the cursor
8415  at the beginning of the text and selecting 
8416 \family sans
8417 Insert\SpecialChar \menuseparator
8418 Short Title
8419 \family default
8420 .
8421  
8422 \begin_inset Quotes eld
8423 \end_inset
8424
8425 Short Title
8426 \begin_inset Quotes erd
8427 \end_inset
8428
8429  inserts an optional argument of the type needed by 
8430 \family typewriter
8431
8432 \backslash
8433 figcaption
8434 \family default
8435 .
8436  Hopefully it will be renamed someday.
8437 \end_layout
8438
8439 \begin_layout Itemize
8440
8441 \family typewriter
8442
8443 \backslash
8444 objectname
8445 \family default
8446  (2.17.1) – same as 
8447 \family typewriter
8448
8449 \backslash
8450 figcaption
8451 \family default
8452  for the catalog ID optional parameter
8453 \end_layout
8454
8455 \begin_layout Itemize
8456
8457 \family typewriter
8458
8459 \backslash
8460 dataset
8461 \family default
8462  (2.17.1) – same as 
8463 \family typewriter
8464
8465 \backslash
8466 figcaption
8467 \family default
8468  for the catalog ID optional parameter
8469 \end_layout
8470
8471 \begin_layout Subsubsection
8472 Things not implemented, use TeX code
8473 \end_layout
8474
8475 \begin_layout Standard
8476
8477 \family typewriter
8478
8479 \backslash
8480 altaffilmark
8481 \family default
8482  (2.3), 
8483 \family typewriter
8484
8485 \backslash
8486 altaffiltext
8487 \family default
8488  (2.3), 
8489 \family typewriter
8490
8491 \backslash
8492 eqnum
8493 \family default
8494  (2.12), 
8495 \family typewriter
8496
8497 \backslash
8498 setcounter{equation}
8499 \family default
8500  (2.12), Journal name abbreviations (2.13.4), 
8501 \family typewriter
8502
8503 \backslash
8504 figurenum
8505 \family default
8506  (2.14.1), 
8507 \family typewriter
8508
8509 \backslash
8510 epsscale
8511 \family default
8512  (2.14.1), 
8513 \family typewriter
8514
8515 \backslash
8516 plotone
8517 \family default
8518  (2.14.1), 
8519 \family typewriter
8520
8521 \backslash
8522 plottwo
8523 \family default
8524  (2.14.1), 
8525 \family typewriter
8526
8527 \backslash
8528 tablenum
8529 \family default
8530  (2.15.4), 
8531 \family typewriter
8532
8533 \backslash
8534 tableline
8535 \family default
8536  (2.15.4, insert it as the first element in the lefthand cell after where
8537  you want it.
8538  Don't use any of LyX's rules in the table), 
8539 \family typewriter
8540
8541 \backslash
8542 tablenotemark
8543 \family default
8544  (2.15.5), 
8545 \family typewriter
8546
8547 \backslash
8548 tablenotetext
8549 \family default
8550  (2.15.5), much of Misc (2.17, except 
8551 \family typewriter
8552
8553 \backslash
8554 objectname
8555 \family default
8556
8557 \family typewriter
8558
8559 \backslash
8560 dataset
8561 \family default
8562
8563 \family typewriter
8564
8565 \backslash
8566 url
8567 \family default
8568 , and 
8569 \family typewriter
8570
8571 \backslash
8572 email
8573 \family default
8574 ; see above), 
8575 \family typewriter
8576
8577 \backslash
8578 singlespace
8579 \family default
8580  (3.1), 
8581 \family typewriter
8582
8583 \backslash
8584 doublespace
8585 \family default
8586  (3.1), 
8587 \family typewriter
8588
8589 \backslash
8590 onecolumn
8591 \family default
8592  (3.2), 
8593 \family typewriter
8594
8595 \backslash
8596 twocolumn
8597 \family default
8598  (3.2)
8599 \end_layout
8600
8601 \begin_layout Subsubsection
8602 Things that cannot be implemented
8603 \end_layout
8604
8605 \begin_layout Standard
8606 \SpecialChar \ldots{}
8607  at least in any meaningful sort of way, so I suggest ignoring them.
8608  They are the references environment (2.13.3), and the deluxetable environment
8609  (2.15).
8610  If you really, really need to use deluxetable, I suggest editing it in
8611  a separate file with a text editor, then using 
8612 \family sans
8613 Insert\SpecialChar \menuseparator
8614 Child
8615 \begin_inset space ~
8616 \end_inset
8617
8618 Document
8619 \family default
8620  to include it in your LyX document.
8621  See the 
8622 \family typewriter
8623 aas_sample.lyx
8624 \family default
8625  file to see an example of this.
8626 \end_layout
8627
8628 \begin_layout Subsection
8629 FAQs, Tips, Tricks, and Other Ruminations
8630 \end_layout
8631
8632 \begin_layout Subsubsection
8633 Getting LyX and AASTeX to cooperate
8634 \end_layout
8635
8636 \begin_layout Standard
8637 It can be a bit tricky to get LyX to recognize a new layout and document
8638  class.
8639  When all else fails, do this:
8640 \end_layout
8641
8642 \begin_layout Enumerate
8643 Make certain that LaTeX can find AASTeX.
8644  Copy sample.tex (and perhaps table.tex) from the AASTeX distribution into
8645  a directory completely unrelated to LaTeX or AASTeX and run LaTeX on 
8646 \family typewriter
8647 sample.tex
8648 \family default
8649 .
8650 \end_layout
8651
8652 \begin_layout Enumerate
8653 Make certain that 
8654 \family typewriter
8655 aastex.layout
8656 \family default
8657  appears in LyX's 
8658 \family typewriter
8659 layouts
8660 \family default
8661  folder
8662 \end_layout
8663
8664 \begin_layout Enumerate
8665 Rerun 
8666 \family sans
8667 Tools\SpecialChar \menuseparator
8668 Reconfigure
8669 \family default
8670  in LyX, then restart LyX.
8671 \end_layout
8672
8673 \begin_layout Enumerate
8674 Open a regular new file, not from a template.
8675  Does AASTeX appear in the class list in 
8676 \family sans
8677 Document\SpecialChar \menuseparator
8678 Settings
8679 \family default
8680 ?
8681 \end_layout
8682
8683 \begin_layout Standard
8684 If you get a warning from an existing AASTeX document about not being able
8685  to find the AASTeX layout or a message about 
8686 \begin_inset Quotes eld
8687 \end_inset
8688
8689 You should not mix title layouts with normal ones
8690 \begin_inset Quotes erd
8691 \end_inset
8692
8693 , things haven't been installed correctly.
8694 \end_layout
8695
8696 \begin_layout Subsubsection
8697 LaTeX error processing a table 
8698 \end_layout
8699
8700 \begin_layout Standard
8701 LyX, by default, attempts to center the table caption/title.
8702  This seems to produce a bad interaction in AASTeX so you should click somewhere
8703  in the caption/title, then select 
8704 \family sans
8705 Edit\SpecialChar \menuseparator
8706 Paragraph
8707 \begin_inset space ~
8708 \end_inset
8709
8710 Settings
8711 \family default
8712 , then set the 
8713 \family sans
8714 Alignment
8715 \family default
8716  to 
8717 \family sans
8718 Block
8719 \family default
8720 .
8721  This took care of it for me.
8722 \end_layout
8723
8724 \begin_layout Subsubsection
8725 References
8726 \end_layout
8727
8728 \begin_layout Standard
8729 A couple of things: 1) I have noticed some funny spacing in the reference
8730  entries in the text.
8731  When you enter the bibliography item data, make sure their is 
8732 \emph on
8733 no
8734 \emph default
8735  space between the last author and the parenthesis setting off the year;
8736  
8737 \emph on
8738 e.
8739 \begin_inset space \thinspace{}
8740 \end_inset
8741
8742 g.
8743 \begin_inset space \space{}
8744 \end_inset
8745
8746
8747 \emph default
8748 type 
8749 \family typewriter
8750 Ressler(1992)
8751 \family default
8752 , not 
8753 \family typewriter
8754 Ressler (1992)
8755 \family default
8756 .
8757  2) Entering the references at all is not obvious.
8758  The easiest thing is to start typing your first reference at the end of
8759  the document, then mark it as type 
8760 \family sans
8761 References
8762 \family default
8763 .
8764  That will put a small gray box in front of what you just typed.
8765  Click on the box to fill in the rest of the information.
8766  For new references, go to the end of an existing reference and press return.
8767  That will create a new line with its own box, etc.
8768 \end_layout
8769
8770 \begin_layout Subsubsection
8771 Including EPS files
8772 \end_layout
8773
8774 \begin_layout Standard
8775 Even though AASTeX provides its own figure commands (
8776 \family typewriter
8777
8778 \backslash
8779 plotone
8780 \family default
8781 , for example), I much prefer LaTeX's standard figure commands (with the
8782  default graphicx).
8783  You can insert the 
8784 \family typewriter
8785
8786 \backslash
8787 plotone
8788 \family default
8789 , etc.
8790 \begin_inset space ~
8791 \end_inset
8792
8793 commands as TeX code into a Figure Float box if you desire, but I never
8794  have much luck getting the layout right.
8795  With the standard graphics, LyX will insert a 
8796 \family typewriter
8797
8798 \backslash
8799 usepackage{graphicx}
8800 \family default
8801  command into the LaTeX preamble and handle the figures in the standard
8802  LaTeX2e way, interspersing the figures in the text.
8803  I believe ApJ accepts figures exactly this way now; AJ might still use
8804  the 
8805 \begin_inset Quotes eld
8806 \end_inset
8807
8808 stack everything at the end
8809 \begin_inset Quotes erd
8810 \end_inset
8811
8812  technique.
8813 \end_layout
8814
8815 \begin_layout Subsubsection
8816 Things I could have done, but didn't
8817 \end_layout
8818
8819 \begin_layout Standard
8820 There are a few 
8821 \begin_inset Quotes eld
8822 \end_inset
8823
8824 pretty
8825 \begin_inset Quotes erd
8826 \end_inset
8827
8828  things I could have implemented, but chose not to.
8829  For instance, I saw no point in double-spacing the text in the LyX window,
8830  even though it is double-spaced in the paper manuscript.
8831  Also, I chose not to make separate layouts for the preprint and preprint2
8832  styles.
8833  Since I assume you will spend most of your time in the plain manuscript
8834  mode anyway, I decided not to chew up more disk space with this.
8835  
8836 \end_layout
8837
8838 \begin_layout Subsection
8839 Final Caveat
8840 \end_layout
8841
8842 \begin_layout Standard
8843 Your mileage may vary.
8844  I've now had papers published by both ApJ and AJ that have had 98% of the
8845  effort done in LyX; the last 2% was the LaTeX post-processing and a few
8846  cleanups.
8847  I have had no trouble with the submission process, and I'm sure the journals
8848  were never aware that there might be a difference.
8849  So, go forth and publish!
8850 \end_layout
8851
8852 \begin_layout Section
8853 AMS LaTeX
8854 \end_layout
8855
8856 \begin_layout Standard
8857 by 
8858 \noun on
8859 David Johnson
8860 \noun default
8861 ; updated by 
8862 \noun on
8863 Richard Heck
8864 \end_layout
8865
8866 \begin_layout Standard
8867 \begin_inset VSpace bigskip
8868 \end_inset
8869
8870
8871 \end_layout
8872
8873 \begin_layout Standard
8874 \noindent
8875 The AMS LaTeX layouts are set up to conform to suggested styles for mathematical
8876  papers to be submitted to American Mathematical Society publications.
8877  The layouts are not tailored to a specific journal, but easily can be.
8878  You should refer to the AMS documentation for specific instructions for
8879  each journal (usually it will entail only changing a single line in the
8880  TeX output).
8881  That documentation is available on the Web at 
8882 \begin_inset Flex URL
8883 status open
8884
8885 \begin_layout Plain Layout
8886
8887 http://www.ams.org
8888 \end_layout
8889
8890 \end_inset
8891
8892  or by ftp at 
8893 \begin_inset Flex URL
8894 status open
8895
8896 \begin_layout Plain Layout
8897
8898 ftp://ftp.ams.org/pub/tex/amslatex/
8899 \end_layout
8900
8901 \end_inset
8902
8903 .
8904  These layouts are appropriate, and useful, for any mathematical writing.
8905  
8906 \end_layout
8907
8908 \begin_layout Standard
8909 There are two basic AMS LaTeX layouts: 
8910 \end_layout
8911
8912 \begin_layout Itemize
8913 amsart: The standard AMS article format.
8914 \end_layout
8915
8916 \begin_layout Itemize
8917 amsbook: the standard AMS book (really, monograph) format.
8918  
8919 \end_layout
8920
8921 \begin_layout Standard
8922 The layouts themselves contain only the minimum necessary to use the AMS
8923  classes.
8924  They do not, in particular, contain any of the `theorem' environments used
8925  for setting theorems, lemmas, and the like.
8926  These are contained, instead, in the 
8927 \begin_inset Flex Code
8928 status collapsed
8929
8930 \begin_layout Plain Layout
8931 Theorems (AMS)
8932 \end_layout
8933
8934 \end_inset
8935
8936  module, which is loaded by default when when you select one of the AMS
8937  classes.
8938  (It can also be used with other classes and can be removed, if you would
8939  rather use something else.) Less commonly used environments are in the 
8940 \begin_inset Flex Code
8941 status collapsed
8942
8943 \begin_layout Plain Layout
8944 Theorems (AMS-Extended)
8945 \end_layout
8946
8947 \end_inset
8948
8949  module, which must be loaded manually.
8950 \end_layout
8951
8952 \begin_layout Standard
8953 By default, theorems and the like are numbered consecutively throughout
8954  the document, but this may be modified by loading the module 
8955 \begin_inset Flex Code
8956 status collapsed
8957
8958 \begin_layout Plain Layout
8959 Theorems (Order by Section)
8960 \end_layout
8961
8962 \end_inset
8963
8964  or, if you are using 
8965 \begin_inset Flex Code
8966 status collapsed
8967
8968 \begin_layout Plain Layout
8969 book (AMS)
8970 \end_layout
8971
8972 \end_inset
8973
8974 , the module 
8975 \begin_inset Flex Code
8976 status collapsed
8977
8978 \begin_layout Plain Layout
8979 Theorems (Order by Chapter)
8980 \end_layout
8981
8982 \end_inset
8983
8984 .
8985  These will number the results as 
8986 \begin_inset Formula $n.m$
8987 \end_inset
8988
8989 , where the first number refers to the section (or chapter) and the second
8990  refers to the total number of results so far in that section (or chapter).
8991  Many environments are also available unnumbered.
8992  These are indicated by an asterisk at the end.
8993  If you happen to want 
8994 \emph on
8995 only
8996 \emph default
8997  unnumbered results, the module 
8998 \begin_inset Flex Code
8999 status collapsed
9000
9001 \begin_layout Plain Layout
9002 Theorems (Starred)
9003 \end_layout
9004
9005 \end_inset
9006
9007  provides that option.
9008 \end_layout
9009
9010 \begin_layout Standard
9011 Note that these modules do not 
9012 \emph on
9013 have
9014 \emph default
9015  to be used with the AMS classes.
9016  It is perfectly possible to use the 
9017 \begin_inset Flex Code
9018 status collapsed
9019
9020 \begin_layout Plain Layout
9021 Theorems (AMS)
9022 \end_layout
9023
9024 \end_inset
9025
9026  module, and the others mentioned, with other classes, such as 
9027 \begin_inset Flex Code
9028 status collapsed
9029
9030 \begin_layout Plain Layout
9031 article
9032 \end_layout
9033
9034 \end_inset
9035
9036
9037 \begin_inset Flex Code
9038 status collapsed
9039
9040 \begin_layout Plain Layout
9041 report
9042 \end_layout
9043
9044 \end_inset
9045
9046
9047 \begin_inset Flex Code
9048 status collapsed
9049
9050 \begin_layout Plain Layout
9051 book (KOMA-script)
9052 \end_layout
9053
9054 \end_inset
9055
9056 , and so forth.
9057 \end_layout
9058
9059 \begin_layout Subsection
9060 What these layouts provide
9061 \end_layout
9062
9063 \begin_layout Standard
9064 There is a long list of included environments provided by these layouts.
9065  In AMS-LaTeX, there is, in fact, an opportunity to define an unlimited
9066  variety of `theorem' environments.
9067  However, the AMS recommends the environments that are available in LyX.
9068  
9069 \end_layout
9070
9071 \begin_layout Standard
9072 The following environments—as well as the standard environments, such as
9073  
9074 \begin_inset Flex Noun
9075 status collapsed
9076
9077 \begin_layout Plain Layout
9078 section
9079 \end_layout
9080
9081 \end_inset
9082
9083
9084 \begin_inset Flex Noun
9085 status collapsed
9086
9087 \begin_layout Plain Layout
9088 bibliography
9089 \end_layout
9090
9091 \end_inset
9092
9093
9094 \begin_inset Flex Noun
9095 status collapsed
9096
9097 \begin_layout Plain Layout
9098 title
9099 \end_layout
9100
9101 \end_inset
9102
9103
9104 \begin_inset Flex Noun
9105 status collapsed
9106
9107 \begin_layout Plain Layout
9108 author
9109 \end_layout
9110
9111 \end_inset
9112
9113 , and 
9114 \begin_inset Flex Noun
9115 status collapsed
9116
9117 \begin_layout Plain Layout
9118 date
9119 \end_layout
9120
9121 \end_inset
9122
9123 —are provided by 
9124 \begin_inset Flex Code
9125 status collapsed
9126
9127 \begin_layout Plain Layout
9128 article (AMS)
9129 \end_layout
9130
9131 \end_inset
9132
9133  and 
9134 \begin_inset Flex Code
9135 status collapsed
9136
9137 \begin_layout Plain Layout
9138 book (AMS)
9139 \end_layout
9140
9141 \end_inset
9142
9143 :
9144 \end_layout
9145
9146 \begin_layout Description
9147 Address This should be the author's permanent address.
9148 \end_layout
9149
9150 \begin_layout Description
9151 Current
9152 \begin_inset space ~
9153 \end_inset
9154
9155 Address This should be the author's temporary address at the time of submission,
9156  if different from the Address.
9157 \end_layout
9158
9159 \begin_layout Description
9160 Email Author's e-mail address
9161 \end_layout
9162
9163 \begin_layout Description
9164 URL Author's Web address, if desired.
9165 \end_layout
9166
9167 \begin_layout Description
9168 Keywords Key words or phrases used to identify specific topics discussed
9169  in the paper.
9170 \end_layout
9171
9172 \begin_layout Description
9173 Subjectclass These refer to the AMS Subject Classifications, published and
9174  described in 
9175 \emph on
9176 Mathematical Reviews
9177 \emph default
9178 .
9179  These are also available online at the AMS cites listed above.
9180 \end_layout
9181
9182 \begin_layout Description
9183 Thanks
9184 \end_layout
9185
9186 \begin_layout Description
9187 Dedicatory
9188 \end_layout
9189
9190 \begin_layout Description
9191 Translator
9192 \end_layout
9193
9194 \begin_layout Standard
9195 The following environments are provided by both the 
9196 \begin_inset Flex Code
9197 status collapsed
9198
9199 \begin_layout Plain Layout
9200 Theorems
9201 \end_layout
9202
9203 \end_inset
9204
9205  and 
9206 \begin_inset Flex Code
9207 status collapsed
9208
9209 \begin_layout Plain Layout
9210 Theorems (AMS)
9211 \end_layout
9212
9213 \end_inset
9214
9215  modules, in the latter case in both starred (unnumbered) and unstarred
9216  (numbered) versions.
9217  These same environments are provided only in the starred versions by the
9218  
9219 \begin_inset Flex Code
9220 status collapsed
9221
9222 \begin_layout Plain Layout
9223 Theorems (Starred)
9224 \end_layout
9225
9226 \end_inset
9227
9228  module:
9229 \end_layout
9230
9231 \begin_layout Theorem
9232 This is typically used for the statements of major results.
9233  
9234 \end_layout
9235
9236 \begin_layout Corollary*
9237 This is used for statements which follow fairly directly from previous statement
9238 s.
9239  Again, these can be major results.
9240  
9241 \end_layout
9242
9243 \begin_layout Lemma
9244 These are smaller results needed to prove other statements.
9245 \end_layout
9246
9247 \begin_layout Proposition
9248 These are less major results which (hopefully) add to the general theory
9249  being discussed.
9250 \end_layout
9251
9252 \begin_layout Conjecture
9253 These are statements provided without justification, which the author does
9254  not know how to prove, but which seem to be true (to the author, at least).
9255 \end_layout
9256
9257 \begin_layout Definition*
9258 Guess what this is for.
9259  The font is different for this environment than for the previous ones.
9260  
9261 \end_layout
9262
9263 \begin_layout Example*
9264 Used for examples illustrating proven results.
9265 \end_layout
9266
9267 \begin_layout Problem
9268 It's not really known what this is for.
9269  You should figure it out.
9270 \end_layout
9271
9272 \begin_layout Exercise*
9273 Write a description for this one.
9274 \end_layout
9275
9276 \begin_layout Remark
9277 This environment is also a type of theorem, usually a lesser sort of observation.
9278 \end_layout
9279
9280 \begin_layout Claim*
9281 Often used in the course of giving a proof of a larger result.
9282 \end_layout
9283
9284 \begin_layout Case
9285 Generally, these are used to break up long arguments, using specific instances
9286  of some condition.
9287  
9288 \end_layout
9289
9290 \begin_layout Case
9291 The numbering scheme for cases is on its own, not together with other numbered
9292  statements.
9293  
9294 \end_layout
9295
9296 \begin_layout Proof
9297 At the end of this environment, a QED symbol (usually a square, but it can
9298  vary with different styles) is placed.
9299  If you want to have other environments within this one—for example, Case
9300  environments—and have the QED symbol appear only after them, then the other
9301  environments need to be nested within the proof environment.
9302  See the section 
9303 \emph on
9304 Nesting Environments
9305 \emph default
9306  of the 
9307 \emph on
9308 User's Guide
9309 \emph default
9310  for information on nesting.
9311 \end_layout
9312
9313 \begin_layout Standard
9314 And these environments are provided by 
9315 \begin_inset Flex Code
9316 status collapsed
9317
9318 \begin_layout Plain Layout
9319 Theorems (AMS-Extended)
9320 \end_layout
9321
9322 \end_inset
9323
9324 :
9325 \end_layout
9326
9327 \begin_layout Criterion*
9328 A required condition.
9329 \end_layout
9330
9331 \begin_layout Algorithm*
9332 A general procedure to be used.
9333 \end_layout
9334
9335 \begin_layout Axiom*
9336 This is a property or statement taken as true within the system being discussed.
9337 \end_layout
9338
9339 \begin_layout Condition*
9340 Sometimes used to state a condition assumed within the present context of
9341  discussion.
9342 \end_layout
9343
9344 \begin_layout Note*
9345 Similar to a Remark.
9346 \end_layout
9347
9348 \begin_layout Notation*
9349 Used for the explanation of, yes, notation.
9350 \end_layout
9351
9352 \begin_layout Summary
9353 Do we really need to tell you? 
9354 \end_layout
9355
9356 \begin_layout Acknowledgement*
9357 Acknowledgement.
9358 \end_layout
9359
9360 \begin_layout Conclusion*
9361 Sometimes used at the end of a long train of argument.
9362 \end_layout
9363
9364 \begin_layout Fact
9365 Used in a way similar to Proposition, though perhaps lower on the scale.
9366 \end_layout
9367
9368 \begin_layout Standard
9369 In addition, the AMS classes automatically provide the AMS LaTeX and AMS
9370  fonts packages.
9371  They need to be available on your system in order to use these environments.
9372 \end_layout
9373
9374 \begin_layout Section
9375 AGU journals (
9376 \family sans
9377 aguplus
9378 \family default
9379 )
9380 \end_layout
9381
9382 \begin_layout Standard
9383 by 
9384 \shape smallcaps
9385 Martin Vermeer
9386 \end_layout
9387
9388 \begin_layout Subsection
9389 Description
9390 \end_layout
9391
9392 \begin_layout Standard
9393 These are the layout files for some of the journals of the American Geophysical
9394  Society.
9395  It is assumed that you have both the AGU's own class files and AGUplus
9396  installed (everything to be found at
9397 \begin_inset Flex URL
9398 status collapsed
9399
9400 \begin_layout Plain Layout
9401
9402 ftp://ftp.agu.org/journals/latex/journals
9403 \end_layout
9404
9405 \end_inset
9406
9407 ).
9408 \end_layout
9409
9410 \begin_layout Subsection
9411 New styles
9412 \end_layout
9413
9414 \begin_layout Standard
9415 Redefined are 
9416 \family sans
9417 Paragraph
9418 \family default
9419
9420 \family sans
9421 Paragraph*
9422 \family default
9423 .
9424  They are still called this in the LyX GUI, though their LaTeX equivalents
9425  in the AGU classes are 
9426 \family sans
9427 Subsubsubsection
9428 \family default
9429  and 
9430 \family sans
9431 Subsubsubsection*
9432 \family default
9433 .
9434 \end_layout
9435
9436 \begin_layout Standard
9437 Newly defined styles are 
9438 \family sans
9439 Left_Header
9440 \family default
9441
9442 \family sans
9443 Right_Header
9444 \family default
9445
9446 \family sans
9447 Received
9448 \family default
9449
9450 \family sans
9451 Revised
9452 \family default
9453
9454 \family sans
9455 Accepted
9456 \family default
9457
9458 \family sans
9459 CCC
9460 \family default
9461
9462 \family sans
9463 PaperId
9464 \family default
9465
9466 \family sans
9467 AuthorAddr
9468 \family default
9469
9470 \family sans
9471 SlugComment
9472 \family default
9473 .
9474  These are mostly manuscript attributes and defined in the AGU class documentati
9475 on.
9476 \end_layout
9477
9478 \begin_layout Standard
9479 I suspect this is still badly incomplete.
9480 \end_layout
9481
9482 \begin_layout Subsection
9483 New floats
9484 \end_layout
9485
9486 \begin_layout Standard
9487
9488 \family sans
9489 Planotable
9490 \family default
9491  and 
9492 \family sans
9493 Plate
9494 \family default
9495 .
9496  We also have a new 
9497 \family sans
9498 Table_Caption
9499 \family default
9500 .
9501 \end_layout
9502
9503 \begin_layout Subsection
9504 Supported journals
9505 \end_layout
9506
9507 \begin_layout Itemize
9508
9509 \emph on
9510 Journal of Geophysical Research
9511 \emph default
9512
9513 \family typewriter
9514 jgrga.layout
9515 \family default
9516  — Martin Vermeer
9517 \end_layout
9518
9519 \begin_layout Standard
9520 Add your own, it isn't so hard! Look at the 
9521 \family typewriter
9522 jgrga.layout
9523 \family default
9524  example and 
9525 \family typewriter
9526 aguplus.inc
9527 \family default
9528 .
9529 \end_layout
9530
9531 \begin_layout Subsection
9532 Bugs and things to remember
9533 \end_layout
9534
9535 \begin_layout Standard
9536 In order to use the new layouts, you must remember to do the following for
9537  a new document:
9538 \end_layout
9539
9540 \begin_layout Enumerate
9541
9542 \emph on
9543 Turn off babel
9544 \emph default
9545 .
9546  This can be done in the 
9547 \family sans
9548 Layout\SpecialChar \menuseparator
9549 Document
9550 \family default
9551  or 
9552 \family sans
9553 Document\SpecialChar \menuseparator
9554 Settings
9555 \family default
9556  menu item.
9557  (AGU articles are always in English, right? So 
9558 \emph on
9559 don't
9560 \emph default
9561  choose a language.)
9562 \end_layout
9563
9564 \begin_layout Enumerate
9565 Enter 
9566 \family typewriter
9567 jgrga
9568 \family default
9569  into the document's 
9570 \family sans
9571 Extra Options
9572 \family default
9573  field.
9574  (Yes, this is a bug.)
9575 \end_layout
9576
9577 \begin_layout Enumerate
9578 Make sure you use the 
9579 \family typewriter
9580 agu.bst
9581 \family default
9582  bibliography style, by entering 
9583 \family sans
9584 agu
9585 \family default
9586  into the second field of the BibTeX inset.
9587  None of the standard styles will do.
9588 \end_layout
9589
9590 \begin_layout Section
9591 Broadway
9592 \end_layout
9593
9594 \begin_layout Standard
9595 by 
9596 \shape smallcaps
9597 Garst Reese
9598 \end_layout
9599
9600 \begin_layout Subsection
9601 Introduction
9602 \end_layout
9603
9604 \begin_layout Standard
9605 Broadway is for writing plays.
9606  The format is more decorative than Hollywood, and much less standardized.
9607  This format should be suitable for workshops.
9608 \end_layout
9609
9610 \begin_layout Subsection
9611 Special problems
9612 \end_layout
9613
9614 \begin_layout Standard
9615 The same as in Hollywood.
9616 \end_layout
9617
9618 \begin_layout Subsection
9619 Special features
9620 \end_layout
9621
9622 \begin_layout Standard
9623 Insert the 
9624 \family sans
9625 Speaker
9626 \family default
9627  names as labels then cross-reference the label to insert the name.
9628  The cross-reference dialog will show the current cast of characters.
9629 \end_layout
9630
9631 \begin_layout Subsection
9632 Paper size and Margins
9633 \end_layout
9634
9635 \begin_layout Standard
9636 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
9637 \end_layout
9638
9639 \begin_layout Subsection
9640 Environments
9641 \end_layout
9642
9643 \begin_layout Standard
9644 The following environments are available.
9645  You can use broadway.bind to get the bind keys shown at the right.
9646 \end_layout
9647
9648 \begin_layout Itemize
9649
9650 \family sans
9651 Standard
9652 \begin_inset Newline newline
9653 \end_inset
9654
9655
9656 \family default
9657 You should not have to use this, but it is here for anything that does not
9658  fit otherwise.
9659 \end_layout
9660
9661 \begin_layout Itemize
9662
9663 \family sans
9664 Narrative
9665 \begin_inset space \hfill{}
9666 \end_inset
9667
9668 M-z n
9669 \begin_inset Newline newline
9670 \end_inset
9671
9672
9673 \family default
9674 Used to describe stage setting and the action.
9675  First use of speaker names in all CAPs.
9676 \end_layout
9677
9678 \begin_layout Itemize
9679
9680 \family sans
9681 ACT
9682 \begin_inset space \hfill{}
9683 \end_inset
9684
9685 M-z a
9686 \begin_inset Newline newline
9687 \end_inset
9688
9689
9690 \family default
9691 Automatically numbered.
9692  On screen it will be arabic, but will print as Roman.
9693 \end_layout
9694
9695 \begin_layout Itemize
9696
9697 \family sans
9698 ACT*
9699 \begin_inset space \hfill{}
9700 \end_inset
9701
9702 M-z S at
9703 \begin_inset Newline newline
9704 \end_inset
9705
9706
9707 \family default
9708 Subtitle for 
9709 \family sans
9710 ACT.
9711
9712 \family default
9713  It is just centered text.
9714 \end_layout
9715
9716 \begin_layout Itemize
9717
9718 \family sans
9719 SCENE
9720 \begin_inset space \hfill{}
9721 \end_inset
9722
9723 M-z S-S
9724 \begin_inset Newline newline
9725 \end_inset
9726
9727
9728 \family default
9729 Not automatically numbered.
9730  You supply the number.
9731  This is because I couldn't figure out how.
9732 \end_layout
9733
9734 \begin_layout Itemize
9735
9736 \family sans
9737 AT_RISE:
9738 \begin_inset space \hfill{}
9739 \end_inset
9740
9741 M-z S-R
9742 \begin_inset Newline newline
9743 \end_inset
9744
9745
9746 \family default
9747 A special case of Narrative to describe the setting and action as the curtain
9748  rises.
9749 \end_layout
9750
9751 \begin_layout Itemize
9752
9753 \family sans
9754 Speaker
9755 \begin_inset space \hfill{}
9756 \end_inset
9757
9758 M-z s
9759 \begin_inset Newline newline
9760 \end_inset
9761
9762
9763 \family default
9764 The speaker's (actor's) title, centered in all CAPS.
9765 \end_layout
9766
9767 \begin_layout Itemize
9768
9769 \family sans
9770 Parenthetical
9771 \begin_inset space \hfill{}
9772 \end_inset
9773
9774 M-z p
9775 \begin_inset Newline newline
9776 \end_inset
9777
9778
9779 \family default
9780 Instructions to the speaker.
9781  The parentheses are automatically inserted.
9782  The ( will appear on screen, but both will be in the printed play.
9783  This environment is only used within 
9784 \family sans
9785 Dialogue
9786 \family default
9787 .
9788 \end_layout
9789
9790 \begin_layout Itemize
9791
9792 \family sans
9793 Dialogue
9794 \begin_inset space \hfill{}
9795 \end_inset
9796
9797 M-z d
9798 \begin_inset Newline newline
9799 \end_inset
9800
9801
9802 \family default
9803 What the Speaker says.
9804 \end_layout
9805
9806 \begin_layout Itemize
9807
9808 \family sans
9809 CURTAIN
9810 \begin_inset space \hfill{}
9811 \end_inset
9812
9813 M-z S-C
9814 \begin_inset Newline newline
9815 \end_inset
9816
9817
9818 \family default
9819 The curtain comes down.
9820 \end_layout
9821
9822 \begin_layout Itemize
9823
9824 \family sans
9825 Title
9826 \begin_inset space \hfill{}
9827 \end_inset
9828
9829 M-z S-T
9830 \end_layout
9831
9832 \begin_layout Itemize
9833
9834 \family sans
9835 Author
9836 \begin_inset space \hfill{}
9837 \end_inset
9838
9839 M-z S-A
9840 \end_layout
9841
9842 \begin_layout Itemize
9843
9844 \family sans
9845 Right_Address
9846 \begin_inset space \hfill{}
9847 \end_inset
9848
9849 M-z r
9850 \end_layout
9851
9852 \begin_layout Standard
9853 Hello there.
9854 \end_layout
9855
9856 \begin_layout Section
9857 Dinbrief
9858 \end_layout
9859
9860 \begin_layout Standard
9861 The document class 
9862 \family sans
9863 dinbrief
9864 \family default
9865  can be used to type letters according to German conventions.
9866  A template file is included in 
9867 \family typewriter
9868 .../lyx/share/templates
9869 \family default
9870  for you to use as a starting point.
9871 \end_layout
9872
9873 \begin_layout Section
9874 EGS journals (
9875 \family sans
9876 egs
9877 \family default
9878 )
9879 \end_layout
9880
9881 \begin_layout Standard
9882 by 
9883 \shape smallcaps
9884 Martin Vermeer
9885 \end_layout
9886
9887 \begin_layout Subsection
9888 Description
9889 \end_layout
9890
9891 \begin_layout Standard
9892 This is the layout file for the European Geophysical Society journals.
9893  The needed 
9894 \family typewriter
9895 egs.cls
9896 \family default
9897  can be downloaded from the web site of the EGS under 
9898 \begin_inset Flex URL
9899 status collapsed
9900
9901 \begin_layout Plain Layout
9902
9903 www.copernicus.org
9904 \end_layout
9905
9906 \end_inset
9907
9908 .
9909 \end_layout
9910
9911 \begin_layout Subsection
9912 New styles
9913 \end_layout
9914
9915 \begin_layout Standard
9916
9917 \family sans
9918 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
9919  Accepted
9920 \family default
9921
9922 \family sans
9923 Offsets
9924 \family default
9925 .
9926  The current layout file is unfortunately very unmodular and would benefit
9927  from using the various 
9928 \family typewriter
9929 std*.inc
9930 \family default
9931  file inclusions.
9932 \end_layout
9933
9934 \begin_layout Section
9935 Elsevier Journals
9936 \end_layout
9937
9938 \begin_layout Standard
9939 See the LyX template file 
9940 \family typewriter
9941 elsarticle.lyx
9942 \family default
9943 .
9944  It contains all infos you need.
9945 \end_layout
9946
9947 \begin_layout Section
9948 Foils [aka 
9949 \family sans
9950 FoilTeX
9951 \family default
9952 ]
9953 \begin_inset CommandInset label
9954 LatexCommand label
9955 name "sec:foiltex"
9956
9957 \end_inset
9958
9959
9960 \end_layout
9961
9962 \begin_layout Standard
9963 by 
9964 \noun on
9965 Allan Rae
9966 \end_layout
9967
9968 \begin_layout Subsection
9969 Introduction
9970 \end_layout
9971
9972 \begin_layout Standard
9973 This section describes how to use LyX to make slides for overhead projectors.
9974  There are two document classes that can do this: the default slides class
9975  and the 
9976 \family sans
9977 FoilTeX
9978 \family default
9979  slides class.
9980  This section documents the latter.
9981 \end_layout
9982
9983 \begin_layout Standard
9984 I'm going to say this again, nice and clear, so that there's no misunderstanding
9985 :
9986 \end_layout
9987
9988 \begin_layout Standard
9989 \begin_inset VSpace bigskip
9990 \end_inset
9991
9992
9993 \end_layout
9994
9995 \begin_layout Standard
9996 \align center
9997
9998 \size large
9999 This section documents the class 
10000 \begin_inset Quotes eld
10001 \end_inset
10002
10003
10004 \family sans
10005 slides (FoilTeX)
10006 \family default
10007
10008 \begin_inset Quotes erd
10009 \end_inset
10010
10011  
10012 \emph on
10013 only.
10014 \end_layout
10015
10016 \begin_layout Standard
10017 \begin_inset VSpace bigskip
10018 \end_inset
10019
10020
10021 \end_layout
10022
10023 \begin_layout Standard
10024 If you're looking for the documentation for 
10025 \begin_inset Quotes eld
10026 \end_inset
10027
10028
10029 \family sans
10030 slides (default)
10031 \family default
10032
10033 \begin_inset Quotes erd
10034 \end_inset
10035
10036 , check out section
10037 \begin_inset space ~
10038 \end_inset
10039
10040
10041 \begin_inset CommandInset ref
10042 LatexCommand ref
10043 reference "sec:slitex"
10044
10045 \end_inset
10046
10047 .
10048  If your machine doesn't have the 
10049 \family sans
10050 foils
10051 \family default
10052  class [
10053 \begin_inset Quotes eld
10054 \end_inset
10055
10056
10057 \family sans
10058 slides (FoilTeX)
10059 \family default
10060
10061 \begin_inset Quotes erd
10062 \end_inset
10063
10064 ] installed, you'll probably have to use the default 
10065 \family sans
10066 slides
10067 \family default
10068  class, which isn't quite as good as 
10069 \family sans
10070 foils.
10071 \end_layout
10072
10073 \begin_layout Standard
10074 The 
10075 \family sans
10076 foils
10077 \family default
10078  class is designed for use with version 2.1 of the 
10079 \family sans
10080 foils.cls
10081 \family default
10082  LaTeX class file which is now an integral part of LaTeX2e.
10083 \end_layout
10084
10085 \begin_layout Subsection
10086 Getting Started
10087 \end_layout
10088
10089 \begin_layout Standard
10090 Obviously, to use this document class, you need to select 
10091 \begin_inset Quotes eld
10092 \end_inset
10093
10094
10095 \family sans
10096 slides (FoilTeX)
10097 \family default
10098
10099 \begin_inset Quotes erd
10100 \end_inset
10101
10102  from the 
10103 \family sans
10104 Class
10105 \family default
10106  entry in the 
10107 \family sans
10108 Document
10109 \begin_inset space ~
10110 \end_inset
10111
10112 Layout
10113 \family default
10114  dialog.
10115  There are some settings in the 
10116 \family sans
10117 Document
10118 \begin_inset space ~
10119 \end_inset
10120
10121 Layout
10122 \family default
10123  dialog that you should know about that are specific to this class:
10124 \end_layout
10125
10126 \begin_layout Itemize
10127 Don't change the options 
10128 \family sans
10129 Sides
10130 \family default
10131  and 
10132 \family sans
10133 Columns
10134 \family default
10135  on the 
10136 \family sans
10137 Document
10138 \begin_inset space ~
10139 \end_inset
10140
10141 Layout
10142 \family default
10143  dialog.
10144  They're ignored by the 
10145 \family sans
10146 foils
10147 \family default
10148  class.
10149 \end_layout
10150
10151 \begin_layout Itemize
10152 The default font size is 20
10153 \begin_inset space \thinspace{}
10154 \end_inset
10155
10156 pt with the other options being 17
10157 \begin_inset space \thinspace{}
10158 \end_inset
10159
10160 pt, 25
10161 \begin_inset space \thinspace{}
10162 \end_inset
10163
10164 pt and 30
10165 \begin_inset space \thinspace{}
10166 \end_inset
10167
10168 pt.
10169 \end_layout
10170
10171 \begin_layout Itemize
10172 The default font is 
10173 \family sans
10174 sans
10175 \family default
10176  
10177 \family sans
10178 serif
10179 \family default
10180  but all math equations are still typeset in the usual roman font.
10181 \end_layout
10182
10183 \begin_layout Itemize
10184
10185 \family sans
10186 FoilTeX
10187 \family default
10188  supports A4 and Letter paper sizes as well as a special size for working
10189  with 35
10190 \begin_inset space \thinspace{}
10191 \end_inset
10192
10193 mm slides.
10194  It doesn't support A5, B5, legal or executive paper sizes.
10195 \end_layout
10196
10197 \begin_layout Itemize
10198 Don't bother changing the 
10199 \family sans
10200 Float Placement
10201 \family default
10202  settings because they are ignored anyway.
10203  All floats appear where they are defined in the text.
10204 \end_layout
10205
10206 \begin_layout Itemize
10207 The 
10208 \family sans
10209 Pagestyle
10210 \family default
10211  setting behaves a bit differently for this class.
10212  
10213 \family sans
10214 FoilTeX
10215 \family default
10216  provides extensive footer and header capabilities including a user-defined
10217  logo.
10218  See section
10219 \begin_inset space ~
10220 \end_inset
10221
10222
10223 \begin_inset CommandInset ref
10224 LatexCommand ref
10225 reference "sec:foilfoot"
10226
10227 \end_inset
10228
10229  for more details.
10230  The title page is treated differently to all other pages in the document
10231  and is 
10232 \emph on
10233 always
10234 \emph default
10235  unnumbered and 
10236 \emph on
10237 always
10238 \emph default
10239  has the logo centered at the bottom of the page (if one is defined).
10240  The possible page style choices and what they do are as follows:
10241 \end_layout
10242
10243 \begin_deeper
10244 \begin_layout Labeling
10245 \labelwidthstring MMMMMMM
10246
10247 \family sans
10248 \series bold
10249 empty
10250 \family default
10251 \series default
10252  The final output contains no page numbers, or other headers or footers
10253  (except footnotes of course).
10254  
10255 \end_layout
10256
10257 \begin_layout Labeling
10258 \labelwidthstring MMMMMMM
10259
10260 \family sans
10261 \series bold
10262 plain
10263 \family default
10264 \series default
10265  The final output contains page numbers centered at the bottom of the page.
10266  No other headings or footers (other than footnotes).
10267 \end_layout
10268
10269 \begin_layout Labeling
10270 \labelwidthstring MMMMMMM
10271
10272 \series bold
10273 foilheadings
10274 \series default
10275  Page numbers in lower right corner.
10276  Additional headers and footers are also shown.
10277  This is also the default.
10278 \end_layout
10279
10280 \begin_layout Labeling
10281 \labelwidthstring MMMMMMM
10282
10283 \series bold
10284 fancy
10285 \series default
10286  Gives you access to the 
10287 \family sans
10288 fancyheadings
10289 \family default
10290  package although its use with 
10291 \family sans
10292 FoilTeX
10293 \family default
10294  is discouraged by the writer of the 
10295 \family sans
10296 FoilTeX
10297 \family default
10298  package because of some potential page layout clashes.
10299 \end_layout
10300
10301 \end_deeper
10302 \begin_layout Subsubsection
10303 Extra Options
10304 \end_layout
10305
10306 \begin_layout Standard
10307 The following options may be used in the extra class options in the 
10308 \family sans
10309 Document\SpecialChar \menuseparator
10310 Settings
10311 \family default
10312  dialog.
10313 \end_layout
10314
10315 \begin_layout Labeling
10316 \labelwidthstring MMMMMMx
10317
10318 \series bold
10319 35mmSlide
10320 \series default
10321  This sets up the page layout for 7.33
10322 \begin_inset space \thinspace{}
10323 \end_inset
10324
10325 in by 11
10326 \begin_inset space \thinspace{}
10327 \end_inset
10328
10329 in paper, which is about the same aspect ratio as a 35
10330 \begin_inset space \thinspace{}
10331 \end_inset
10332
10333 mm slide, making it a bit easier to work with this medium.
10334 \end_layout
10335
10336 \begin_layout Labeling
10337 \labelwidthstring MMMMMMx
10338
10339 \series bold
10340 headrule
10341 \series default
10342  Places a rule across the page below the header on every page except the
10343  title page.
10344 \end_layout
10345
10346 \begin_layout Labeling
10347 \labelwidthstring MMMMMMx
10348
10349 \series bold
10350 footrule
10351 \series default
10352  Places a rule across the page above the footer on every page except the
10353  title page.
10354 \end_layout
10355
10356 \begin_layout Labeling
10357 \labelwidthstring MMMMMMx
10358
10359 \series bold
10360 dvips
10361 \series default
10362  This is automatically set each time you create a new 
10363 \family sans
10364 foils
10365 \family default
10366  document.
10367  This option tells 
10368 \family sans
10369 FoilTeX
10370 \family default
10371  to use the dvips driver to rotate those pages that are set as landscape
10372  foils.
10373 \end_layout
10374
10375 \begin_layout Labeling
10376 \labelwidthstring MMMMMMx
10377
10378 \series bold
10379 landscape
10380 \series default
10381  Simply changes the page dimensions to those of a landscape page but doesn't
10382  do any rotation.
10383  Thus if you use this option you need to use an external program to rotate
10384  each page or feed your paper through your printer as landscape.
10385  Note that this option effectively reverses the roles of the 
10386 \family sans
10387 Foilhead
10388 \family default
10389  and 
10390 \family sans
10391 Rotatefoilhead
10392 \family default
10393  environments (don't worry these are described in the next section).
10394 \end_layout
10395
10396 \begin_layout Labeling
10397 \labelwidthstring MMMMMMx
10398
10399 \series bold
10400 leqno
10401 \series default
10402  Equation numbers on the left.
10403 \end_layout
10404
10405 \begin_layout Labeling
10406 \labelwidthstring MMMMMMx
10407
10408 \series bold
10409 fleqn
10410 \series default
10411  Flush-left equations.
10412 \end_layout
10413
10414 \begin_layout Subsection
10415 Supported Environments
10416 \end_layout
10417
10418 \begin_layout Standard
10419 Most of the environments commonly supported in other classes are also supported
10420  by the 
10421 \family sans
10422 foils
10423 \family default
10424  class.
10425  There are several additional environments provided by 
10426 \family sans
10427 FoilTeX
10428 \family default
10429  as well as a couple added by LyX.
10430  The following environments are shared with other classes:
10431 \end_layout
10432
10433 \begin_layout Standard
10434 \begin_inset ERT
10435 status open
10436
10437 \begin_layout Plain Layout
10438
10439
10440 \backslash
10441 begin{multicols}{2}
10442 \end_layout
10443
10444 \end_inset
10445
10446
10447 \end_layout
10448
10449 \begin_layout Itemize
10450
10451 \family sans
10452 Standard
10453 \end_layout
10454
10455 \begin_layout Itemize
10456
10457 \family sans
10458 Itemize
10459 \end_layout
10460
10461 \begin_layout Itemize
10462
10463 \family sans
10464 Enumerate
10465 \end_layout
10466
10467 \begin_layout Itemize
10468
10469 \family sans
10470 Description
10471 \end_layout
10472
10473 \begin_layout Itemize
10474
10475 \family sans
10476 List
10477 \end_layout
10478
10479 \begin_layout Itemize
10480
10481 \family sans
10482 LyX-Code
10483 \end_layout
10484
10485 \begin_layout Itemize
10486
10487 \family sans
10488 Verse
10489 \end_layout
10490
10491 \begin_layout Itemize
10492
10493 \family sans
10494 Quote
10495 \end_layout
10496
10497 \begin_layout Itemize
10498
10499 \family sans
10500 Quotation
10501 \end_layout
10502
10503 \begin_layout Itemize
10504
10505 \family sans
10506 Title
10507 \end_layout
10508
10509 \begin_layout Itemize
10510
10511 \family sans
10512 Author
10513 \end_layout
10514
10515 \begin_layout Itemize
10516
10517 \family sans
10518 Date
10519 \end_layout
10520
10521 \begin_layout Itemize
10522
10523 \family sans
10524 Abstract
10525 \end_layout
10526
10527 \begin_layout Itemize
10528
10529 \family sans
10530 Bibliography
10531 \end_layout
10532
10533 \begin_layout Itemize
10534
10535 \family sans
10536 Address
10537 \end_layout
10538
10539 \begin_layout Itemize
10540
10541 \family sans
10542 RightAddress
10543 \end_layout
10544
10545 \begin_layout Itemize
10546
10547 \family sans
10548 Caption
10549 \end_layout
10550
10551 \begin_layout Itemize
10552
10553 \family sans
10554 Comment
10555 \end_layout
10556
10557 \begin_layout Standard
10558 \begin_inset ERT
10559 status open
10560
10561 \begin_layout Plain Layout
10562
10563
10564 \backslash
10565 end{multicols}
10566 \end_layout
10567
10568 \end_inset
10569
10570
10571 \end_layout
10572
10573 \begin_layout Standard
10574 That is, all the major environments apart from the sectioning environments.
10575  Since foils are essentially self-contained sections, with a title and body,
10576  
10577 \family sans
10578 FoilTeX
10579 \family default
10580  provides specific commands for starting new foils and these are:
10581 \end_layout
10582
10583 \begin_layout Itemize
10584
10585 \family sans
10586 Foilhead
10587 \end_layout
10588
10589 \begin_layout Itemize
10590
10591 \family sans
10592 Rotatefoilhead
10593 \end_layout
10594
10595 \begin_layout Standard
10596 LyX also provides slightly modified versions of these two environments called:
10597 \end_layout
10598
10599 \begin_layout Itemize
10600
10601 \family sans
10602 ShortFoilhead
10603 \end_layout
10604
10605 \begin_layout Itemize
10606
10607 \family sans
10608 ShortRotatefoilhead
10609 \end_layout
10610
10611 \begin_layout Standard
10612 and the differences will be explained in the next section.
10613 \end_layout
10614
10615 \begin_layout Standard
10616 Since foils are often used in presenting ideas or new theorems and such
10617  
10618 \family sans
10619 FoilTeX
10620 \family default
10621  also provides a comprehensive box of goodies for presenting them:
10622 \end_layout
10623
10624 \begin_layout Standard
10625 \begin_inset ERT
10626 status open
10627
10628 \begin_layout Plain Layout
10629
10630
10631 \backslash
10632 begin{multicols}{2}
10633 \end_layout
10634
10635 \end_inset
10636
10637
10638 \end_layout
10639
10640 \begin_layout Itemize
10641
10642 \family sans
10643 Theorem
10644 \end_layout
10645
10646 \begin_layout Itemize
10647
10648 \family sans
10649 Lemma
10650 \end_layout
10651
10652 \begin_layout Itemize
10653
10654 \family sans
10655 Corollary
10656 \end_layout
10657
10658 \begin_layout Itemize
10659
10660 \family sans
10661 Proposition
10662 \end_layout
10663
10664 \begin_layout Itemize
10665
10666 \family sans
10667 Definition
10668 \end_layout
10669
10670 \begin_layout Itemize
10671
10672 \family sans
10673 Proof
10674 \end_layout
10675
10676 \begin_layout Itemize
10677
10678 \family sans
10679 Theorem*
10680 \end_layout
10681
10682 \begin_layout Itemize
10683
10684 \family sans
10685 Lemma*
10686 \end_layout
10687
10688 \begin_layout Itemize
10689
10690 \family sans
10691 Corollary*
10692 \end_layout
10693
10694 \begin_layout Itemize
10695
10696 \family sans
10697 Proposition*
10698 \end_layout
10699
10700 \begin_layout Itemize
10701
10702 \family sans
10703 Definition*
10704 \end_layout
10705
10706 \begin_layout Standard
10707 \begin_inset ERT
10708 status open
10709
10710 \begin_layout Plain Layout
10711
10712
10713 \backslash
10714 end{multicols}
10715 \end_layout
10716
10717 \end_inset
10718
10719
10720 \end_layout
10721
10722 \begin_layout Standard
10723 The starred versions are unnumbered while the unstarred versions are numbered.
10724  There are also two list environments added by LyX and these are:
10725 \end_layout
10726
10727 \begin_layout Itemize
10728
10729 \family sans
10730 TickList
10731 \end_layout
10732
10733 \begin_layout Itemize
10734
10735 \family sans
10736 CrossList
10737 \end_layout
10738
10739 \begin_layout Standard
10740
10741 \family sans
10742 FoilTeX
10743 \family default
10744  provides some powerful header and footer capabilities that are best set
10745  in the preamble although they may be set at any point in a document.
10746  If you want to change these settings in your document the best place to
10747  do so is at the very top of a foil, i.
10748 \begin_inset space \thinspace{}
10749 \end_inset
10750
10751 g.
10752 \emph on
10753
10754 \begin_inset space \space{}
10755 \end_inset
10756
10757
10758 \emph default
10759 straight after the foilhead.
10760 \end_layout
10761
10762 \begin_layout Standard
10763 For this purpose, the following command styles are provided [
10764 \shape smallcaps
10765 Martin Vermeer
10766 \shape default
10767 ]:
10768 \end_layout
10769
10770 \begin_layout Standard
10771 \begin_inset ERT
10772 status open
10773
10774 \begin_layout Plain Layout
10775
10776
10777 \backslash
10778 begin{multicols}{2}
10779 \end_layout
10780
10781 \end_inset
10782
10783
10784 \end_layout
10785
10786 \begin_layout Itemize
10787
10788 \family sans
10789 My
10790 \begin_inset space ~
10791 \end_inset
10792
10793 Logo
10794 \end_layout
10795
10796 \begin_layout Itemize
10797
10798 \family sans
10799 Restriction
10800 \end_layout
10801
10802 \begin_layout Itemize
10803
10804 \family sans
10805 Right
10806 \begin_inset space ~
10807 \end_inset
10808
10809 Footer
10810 \end_layout
10811
10812 \begin_layout Itemize
10813
10814 \family sans
10815 Right
10816 \begin_inset space ~
10817 \end_inset
10818
10819 Header
10820 \end_layout
10821
10822 \begin_layout Itemize
10823
10824 \family sans
10825 Left
10826 \begin_inset space ~
10827 \end_inset
10828
10829 Header
10830 \end_layout
10831
10832 \begin_deeper
10833 \begin_layout Standard
10834 \begin_inset space ~
10835 \end_inset
10836
10837
10838 \end_layout
10839
10840 \end_deeper
10841 \begin_layout Standard
10842 \begin_inset ERT
10843 status open
10844
10845 \begin_layout Plain Layout
10846
10847
10848 \backslash
10849 end{multicols}
10850 \end_layout
10851
10852 \end_inset
10853
10854
10855 \end_layout
10856
10857 \begin_layout Standard
10858 There are also a few commands provided by 
10859 \family sans
10860 FoilTeX
10861 \family default
10862  that aren't directly supported by LyX but I'll tell you what they do and
10863  how to use them in section
10864 \begin_inset space ~
10865 \end_inset
10866
10867
10868 \begin_inset CommandInset ref
10869 LatexCommand ref
10870 reference "sec:unsuppfoils"
10871
10872 \end_inset
10873
10874 .
10875 \end_layout
10876
10877 \begin_layout Subsection
10878 Building a Set of Foils
10879 \end_layout
10880
10881 \begin_layout Standard
10882 This section will give a simple introduction to using the different environments
10883  to build a set of foils.
10884  If you want to see an example set of foils, take a look at the 
10885 \family typewriter
10886 Foils.lyx
10887 \family default
10888  file you find in LyX's 
10889 \family typewriter
10890 examples
10891 \family default
10892  folder.
10893 \end_layout
10894
10895 \begin_layout Subsubsection
10896 Give It a Title Page
10897 \end_layout
10898
10899 \begin_layout Standard
10900 Unlike other classes that provide 
10901 \family sans
10902 Title
10903 \family default
10904
10905 \family sans
10906 Author
10907 \family default
10908
10909 \family sans
10910 Date
10911 \family default
10912  and 
10913 \family sans
10914 Abstract
10915 \family default
10916  environments, 
10917 \family sans
10918 foils
10919 \family default
10920  creates the title on a page of its own.
10921  If you leave out the 
10922 \family sans
10923 Date
10924 \family default
10925  environment LaTeX will substitute the current date (every time you regenerate
10926  the output).
10927 \end_layout
10928
10929 \begin_layout Subsubsection
10930 Start a New Foil
10931 \end_layout
10932
10933 \begin_layout Standard
10934 As I mentioned earlier, there are four ways of starting a new foil.
10935  For portrait foils you should use 
10936 \family sans
10937 Foilhead
10938 \family default
10939  or 
10940 \family sans
10941 ShortFoilhead.
10942
10943 \family default
10944  The difference between these two environments is the amount of space between
10945  the title of the foil (the foilhead) and the body of the foil.
10946 \end_layout
10947
10948 \begin_layout Standard
10949 Landscape foils are generated using the 
10950 \family sans
10951 Rotatefoilhead
10952 \family default
10953  and 
10954 \family sans
10955 ShortRotatefoilhead
10956 \family default
10957  environments.
10958  Again the only difference is the spacing between foilhead and body.
10959  Both of the short versions have 0.5 inches less separation between the foilhead
10960  and the body.
10961  
10962 \end_layout
10963
10964 \begin_layout Standard
10965 One problem with the support for landscape foils is the requirement that
10966  you have to use the 
10967 \family typewriter
10968 dvips
10969 \family default
10970  driver to generate the PostScript output otherwise the foils won't be rotated.
10971  It is possible to get landscape foils even if you haven't got the 
10972 \family typewriter
10973 dvips
10974 \family default
10975  driver provided you can feed your foils sideways through your printer ;-)
10976 \end_layout
10977
10978 \begin_layout Subsubsection
10979 Theorems, Lemmas, Proofs and more
10980 \end_layout
10981
10982 \begin_layout Standard
10983 Due to a small bug in LyX you can't have two of the same type of these environme
10984 nts directly following each other.
10985  They must be separated by something.
10986  If you try, you will just be extending the previous environment as if you
10987  had merged the two environments together.
10988  So, how do you get around this problem? The simplest option is to insert
10989  some text between the two environments or add a 
10990 \family sans
10991 LaTeX
10992 \family default
10993  environment between the two with just a 
10994 \begin_inset Quotes eld
10995 \end_inset
10996
10997
10998 \family typewriter
10999 %
11000 \family default
11001
11002 \begin_inset Quotes erd
11003 \end_inset
11004
11005  in it.
11006  This will force LyX to produce two separate environments and hence the
11007  correct LaTeX output.
11008  An example is provided in the example file included with the LyX distribution.
11009  Remember, this problem only occurs if you are trying to place two of the
11010  same type of theorem-like environments one directly after the other.
11011 \end_layout
11012
11013 \begin_layout Subsubsection
11014 Lists
11015 \end_layout
11016
11017 \begin_layout Standard
11018 You get all the commonly supported list styles found in other classes as
11019  well as two new ones.
11020  I'll only describe the new ones here.
11021  If you want to find out more about the other list environments check out
11022  the 
11023 \emph on
11024 User's Guide.
11025
11026 \emph default
11027  If you intend to use itemized lists you might also want to read about the
11028  
11029 \family sans
11030 Itemize
11031 \begin_inset space ~
11032 \end_inset
11033
11034 Bullet
11035 \begin_inset space ~
11036 \end_inset
11037
11038 Selection
11039 \family default
11040  dialog described above in section
11041 \begin_inset space ~
11042 \end_inset
11043
11044
11045 \begin_inset CommandInset ref
11046 LatexCommand ref
11047 reference "sec:bullet"
11048
11049 \end_inset
11050
11051 .
11052 \end_layout
11053
11054 \begin_layout Standard
11055 The two new list styles, 
11056 \family sans
11057 TickList
11058 \family default
11059  and 
11060 \family sans
11061 CrossList
11062 \family default
11063 , are designed to make it easier for you to create lists of do's and don'ts
11064  or right and wrong by providing dedicated environments that use a tick
11065  or a cross as the label of the list.
11066  These lists are in fact dedicated variants of the 
11067 \family sans
11068 Itemize
11069 \family default
11070  environment.
11071  They do however require that you have the 
11072 \family typewriter
11073 psnfss
11074 \family default
11075  packages installed.
11076 \end_layout
11077
11078 \begin_layout Subsubsection
11079 Figures and Tables
11080 \end_layout
11081
11082 \begin_layout Standard
11083
11084 \family sans
11085 FoilTeX
11086 \family default
11087  redefines the floating tables and figures so that they appear exactly where
11088  they are in the text rather than pushing them to the top of the page or
11089  to some user specified location.
11090  In fact if you change the float placement settings they are simply ignored.
11091 \end_layout
11092
11093 \begin_layout Subsubsection
11094 Page Headers and Footers
11095 \begin_inset CommandInset label
11096 LatexCommand label
11097 name "sec:foilfoot"
11098
11099 \end_inset
11100
11101
11102 \end_layout
11103
11104 \begin_layout Standard
11105
11106 \family sans
11107 My
11108 \begin_inset space ~
11109 \end_inset
11110
11111 Logo
11112 \family default
11113  and 
11114 \family sans
11115 Restriction
11116 \family default
11117  are two commands used to control the left-footer text string.
11118  The first is meant to allow you to include a graphic logo on your foils
11119  and defaults to 
11120 \begin_inset Quotes eld
11121 \end_inset
11122
11123 -Typeset by 
11124 \family sans
11125 FoilTeX
11126 \family default
11127 -
11128 \begin_inset Quotes erd
11129 \end_inset
11130
11131 .
11132  While the second is meant to provide a classification for the audience,
11133  
11134 \emph on
11135 e.
11136 \begin_inset space \thinspace{}
11137 \end_inset
11138
11139 g.
11140 \emph default
11141
11142 \begin_inset space \space{}
11143 \end_inset
11144
11145 Confidential.
11146  It is empty by default.
11147 \end_layout
11148
11149 \begin_layout Standard
11150 The remaining page corners can be filled by 
11151 \family sans
11152 Right
11153 \begin_inset space ~
11154 \end_inset
11155
11156 Footer
11157 \family default
11158  (which defaults to page numbers), 
11159 \family sans
11160 Right
11161 \begin_inset space ~
11162 \end_inset
11163
11164 Header
11165 \family default
11166  (top right) and 
11167 \family sans
11168 Left
11169 \begin_inset space ~
11170 \end_inset
11171
11172 Header
11173 \family default
11174  (top left).
11175 \end_layout
11176
11177 \begin_layout Subsection
11178 Unsupported 
11179 \family sans
11180 FoilTeX
11181 \family default
11182  Goodies
11183 \begin_inset CommandInset label
11184 LatexCommand label
11185 name "sec:unsuppfoils"
11186
11187 \end_inset
11188
11189
11190 \end_layout
11191
11192 \begin_layout Standard
11193 All the commands mentioned below need to be set in a 
11194 \family sans
11195 LaTeX
11196 \family default
11197  environment or as 
11198 \family sans
11199 TeX
11200 \family default
11201  within another environment.
11202 \end_layout
11203
11204 \begin_layout Subsubsection
11205 Lengths
11206 \end_layout
11207
11208 \begin_layout Standard
11209 All lengths are adjusted using the 
11210 \family typewriter
11211
11212 \backslash
11213 setlength{
11214 \family default
11215 \emph on
11216 lengthname
11217 \family typewriter
11218 \emph default
11219 }{
11220 \family default
11221 \emph on
11222 newlength
11223 \family typewriter
11224 \emph default
11225 }
11226 \family default
11227  command.
11228  Where 
11229 \emph on
11230 lengthname
11231 \emph default
11232  should be replaced by the name given to the length you want to change and
11233  
11234 \emph on
11235 newlength
11236 \emph default
11237  is the length value.
11238  All lengths should be specified in units of length such as inches (
11239 \family typewriter
11240 in
11241 \family default
11242 ), millimeters (
11243 \family typewriter
11244 mm
11245 \family default
11246 ) or points (
11247 \family typewriter
11248 pt
11249 \family default
11250 ) or relative to some document or font-based length such as 
11251 \family typewriter
11252
11253 \backslash
11254 textwidth
11255 \family default
11256 .
11257  
11258 \end_layout
11259
11260 \begin_layout Standard
11261 It's possible to change the spacing between a foilhead and the body of the
11262  foil by adjusting the length specified by 
11263 \family typewriter
11264
11265 \backslash
11266 foilheadskip
11267 \family default
11268 .
11269  For example, to make 
11270 \emph on
11271 all
11272 \emph default
11273  foilheads 0.5
11274 \begin_inset space \space{}
11275 \end_inset
11276
11277 in closer to their bodies put the following in the preamble: 
11278 \family typewriter
11279
11280 \backslash
11281 setlength{
11282 \backslash
11283 foilheadskip}{-0.5in}
11284 \end_layout
11285
11286 \begin_layout Standard
11287 The spacings around floats can be adjusted by setting these lengths:
11288 \end_layout
11289
11290 \begin_layout Labeling
11291 \labelwidthstring MMMMMMMMMMM
11292
11293 \family typewriter
11294
11295 \backslash
11296 abovefloatskip
11297 \family default
11298  Separation between the text and the top of the float
11299 \end_layout
11300
11301 \begin_layout Labeling
11302 \labelwidthstring MMMMMMMMMMM
11303
11304 \family typewriter
11305
11306 \backslash
11307 abovecaptionskip
11308 \family default
11309  Separation between the float and the caption
11310 \end_layout
11311
11312 \begin_layout Labeling
11313 \labelwidthstring MMMMMMMMMMM
11314
11315 \family typewriter
11316
11317 \backslash
11318 belowcaptionskip
11319 \family default
11320  Separation between the caption and the following text
11321 \end_layout
11322
11323 \begin_layout Labeling
11324 \labelwidthstring MMMMMMMMMMM
11325
11326 \family typewriter
11327
11328 \backslash
11329 captionwidth
11330 \family default
11331  You can make the captions narrower than the surrounding text by adjusting
11332  this length.
11333  Best done relative to 
11334 \family typewriter
11335
11336 \backslash
11337 textwidth
11338 \family default
11339 .
11340 \end_layout
11341
11342 \begin_layout Standard
11343 There are also several title page related lengths that you may find useful
11344  if you have a long title or several authors:
11345 \end_layout
11346
11347 \begin_layout Labeling
11348 \labelwidthstring MMMMMMMMMMM
11349
11350 \family typewriter
11351
11352 \backslash
11353 abovetitleskip
11354 \family default
11355  Separation from headers to 
11356 \family sans
11357 Title
11358 \end_layout
11359
11360 \begin_layout Labeling
11361 \labelwidthstring MMMMMMMMMMM
11362
11363 \family typewriter
11364
11365 \backslash
11366 titleauthorskip
11367 \family default
11368  between 
11369 \family sans
11370 Title
11371 \family default
11372  and 
11373 \family sans
11374 Author
11375 \family default
11376  environments
11377 \end_layout
11378
11379 \begin_layout Labeling
11380 \labelwidthstring MMMMMMMMMMM
11381
11382 \family typewriter
11383
11384 \backslash
11385 authorauthorskip
11386 \family default
11387  between multiple 
11388 \family sans
11389 Author
11390 \family default
11391  lines
11392 \end_layout
11393
11394 \begin_layout Labeling
11395 \labelwidthstring MMMMMMMMMMM
11396
11397 \family typewriter
11398
11399 \backslash
11400 authordateskip
11401 \family default
11402  between the 
11403 \family sans
11404 Author
11405 \family default
11406  and the 
11407 \family sans
11408 Date
11409 \end_layout
11410
11411 \begin_layout Labeling
11412 \labelwidthstring MMMMMMMMMMM
11413
11414 \family typewriter
11415
11416 \backslash
11417 dateabstractskip
11418 \family default
11419  between the 
11420 \family sans
11421 Date
11422 \family default
11423  and the 
11424 \family sans
11425 Abstract
11426 \end_layout
11427
11428 \begin_layout Standard
11429 The last length related command affects all the list environments.
11430  If you place 
11431 \family typewriter
11432
11433 \backslash
11434 zerolistvertdimens
11435 \family default
11436  
11437 \emph on
11438 inside
11439 \emph default
11440  a list environment then all the vertical spacing between the list items
11441  is removed.
11442  Note that this is a command not a length so it doesn't require 
11443 \family typewriter
11444
11445 \backslash
11446 setlength
11447 \family default
11448  like the stuff mentioned above.
11449 \end_layout
11450
11451 \begin_layout Subsubsection
11452 Headers and Footers
11453 \end_layout
11454
11455 \begin_layout Standard
11456 The 
11457 \family typewriter
11458
11459 \backslash
11460 LogoOn
11461 \family default
11462  and 
11463 \family typewriter
11464
11465 \backslash
11466 LogoOff
11467 \family default
11468  commands control whether the logo in the 
11469 \family sans
11470 MyLogo
11471 \family default
11472  definition appear on a given page.
11473  If you put 
11474 \family typewriter
11475
11476 \backslash
11477 LogoOff
11478 \family default
11479  in the preamble then none of the foils will have the logo on them.
11480  If you don't want the logo on a particular page place the 
11481 \family typewriter
11482
11483 \backslash
11484 LogoOff
11485 \family default
11486  directly after the foilhead of that page and the 
11487 \family typewriter
11488
11489 \backslash
11490 LogoOn
11491 \family default
11492  directly after the next foilhead.
11493 \end_layout
11494
11495 \begin_layout Standard
11496 If you decide to use the 
11497 \family sans
11498 fancy
11499 \family default
11500  page style setting in the 
11501 \family sans
11502 Document
11503 \begin_inset space ~
11504 \end_inset
11505
11506 Layout
11507 \family default
11508  dialog you should probably add 
11509 \family typewriter
11510
11511 \backslash
11512 let
11513 \backslash
11514 headwidth
11515 \backslash
11516 textwidth
11517 \family default
11518  to your preamble so headers and footers on landscape pages are correctly
11519  placed when rotated.
11520  This is due to some clashes between the page layouts provided by the 
11521 \family sans
11522 fancyheadings
11523 \family default
11524  package and the 
11525 \family sans
11526 foils
11527 \family default
11528  class.
11529 \end_layout
11530
11531 \begin_layout Section
11532 Hollywood (Hollywood spec scripts)
11533 \end_layout
11534
11535 \begin_layout Standard
11536 by 
11537 \shape smallcaps
11538 Garst Reese
11539 \end_layout
11540
11541 \begin_layout Subsection
11542 Introduction
11543 \end_layout
11544
11545 \begin_layout Standard
11546 Getting the format of a Hollywood script right is a 
11547 \begin_inset Quotes eld
11548 \end_inset
11549
11550 rite of passage.
11551 \begin_inset Quotes erd
11552 \end_inset
11553
11554  It is designed to make the readers focus on content and to be easy and
11555  familiar for the actors to read.
11556  Each page of a script should be one minute of film.
11557  Nothing goes in a script that you cannot see or hear on screen.
11558  The courier 12 pt font should be used throughout.
11559  No italics.
11560 \end_layout
11561
11562 \begin_layout Subsection
11563 Special problems
11564 \end_layout
11565
11566 \begin_layout Standard
11567 Speakers' lines should NEVER break in mid-sentence.
11568  If a speaker's lines continue over a page break, repeat the 
11569 \family sans
11570 Speaker
11571 \family default
11572  title followed by (Cont'd).
11573 \end_layout
11574
11575 \begin_layout Subsection
11576 Special features
11577 \end_layout
11578
11579 \begin_layout Standard
11580 Insert the 
11581 \family sans
11582 Speaker
11583 \family default
11584  names as labels then cross-reference the label to insert the name.
11585  The cross-reference dialog will show the current cast of characters.
11586  You can use this to insert the speaker name in narratives also.
11587 \end_layout
11588
11589 \begin_layout Subsection
11590 Paper size and Margins
11591 \end_layout
11592
11593 \begin_layout Standard
11594 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
11595 \end_layout
11596
11597 \begin_layout Subsection
11598 Environments
11599 \end_layout
11600
11601 \begin_layout Standard
11602 The following environments are available.
11603  You can use hollywood.bind to get the bind keys shown at the right.
11604 \end_layout
11605
11606 \begin_layout Itemize
11607
11608 \family sans
11609 Standard
11610 \begin_inset Newline newline
11611 \end_inset
11612
11613
11614 \family default
11615 Used where nothing else works.
11616  Try to avoid it.
11617 \end_layout
11618
11619 \begin_layout Itemize
11620
11621 \family sans
11622 FADE_IN
11623 \family default
11624 :
11625 \begin_inset space \hfill{}
11626 \end_inset
11627
11628
11629 \family sans
11630 M-z S-I
11631 \family default
11632
11633 \begin_inset Newline newline
11634 \end_inset
11635
11636 Usually followed by something like 
11637 \begin_inset Quotes eld
11638 \end_inset
11639
11640 on Sally waking up.
11641 \begin_inset Quotes erd
11642 \end_inset
11643
11644
11645 \end_layout
11646
11647 \begin_layout Itemize
11648
11649 \family sans
11650 INT:
11651 \begin_inset space \hfill{}
11652 \end_inset
11653
11654 M-z i
11655 \begin_inset Newline newline
11656 \end_inset
11657
11658
11659 \family default
11660 Introduces a new INTERIOR camera set-up.
11661  Always followed by DAY or NIGHT, or something similar to define the lighting
11662  required.
11663  Everthing on this line in CAPS.
11664 \end_layout
11665
11666 \begin_layout Itemize
11667
11668 \family sans
11669 EXT:
11670 \begin_inset space \hfill{}
11671 \end_inset
11672
11673 M-z e
11674 \begin_inset Newline newline
11675 \end_inset
11676
11677
11678 \family default
11679 Introduces a new EXTERIOR camera set-up.
11680  Everthing on this line in CAPS.
11681 \end_layout
11682
11683 \begin_layout Itemize
11684
11685 \family sans
11686 Speaker
11687 \begin_inset space \hfill{}
11688 \end_inset
11689
11690 M-z s
11691 \begin_inset Newline newline
11692 \end_inset
11693
11694
11695 \family default
11696 The character speaking.
11697 \end_layout
11698
11699 \begin_layout Itemize
11700
11701 \family sans
11702 Parenthetical
11703 \begin_inset space \hfill{}
11704 \end_inset
11705
11706 M-z p
11707 \begin_inset Newline newline
11708 \end_inset
11709
11710
11711 \family default
11712 Instructions to the speaker.
11713  The () are automatically inserted, but only the ( will show in LyX.
11714  Both will be printed.
11715 \end_layout
11716
11717 \begin_layout Itemize
11718
11719 \family sans
11720 Dialogue
11721 \begin_inset space \hfill{}
11722 \end_inset
11723
11724 M-z d
11725 \begin_inset Newline newline
11726 \end_inset
11727
11728
11729 \family default
11730 What the 
11731 \family sans
11732 Speaker
11733 \family default
11734  says.
11735 \end_layout
11736
11737 \begin_layout Itemize
11738
11739 \family sans
11740 Transition
11741 \begin_inset space \hfill{}
11742 \end_inset
11743
11744 M-z t
11745 \begin_inset Newline newline
11746 \end_inset
11747
11748
11749 \family default
11750 Camera movement instruction.
11751  e.
11752 \begin_inset space \thinspace{}
11753 \end_inset
11754
11755 g.
11756 \begin_inset space \space{}
11757 \end_inset
11758
11759 CUT TO:
11760 \end_layout
11761
11762 \begin_layout Itemize
11763
11764 \family sans
11765 FADE OUT:
11766 \begin_inset space \hfill{}
11767 \end_inset
11768
11769 M-z S-I
11770 \end_layout
11771
11772 \begin_layout Itemize
11773
11774 \family sans
11775 Author
11776 \begin_inset space \hfill{}
11777 \end_inset
11778
11779 M-z S-A
11780 \end_layout
11781
11782 \begin_layout Itemize
11783
11784 \family sans
11785 Title
11786 \begin_inset space \hfill{}
11787 \end_inset
11788
11789 M-z S-T
11790 \end_layout
11791
11792 \begin_layout Itemize
11793
11794 \family sans
11795 Right_Address
11796 \begin_inset space \hfill{}
11797 \end_inset
11798
11799 M-z r
11800 \end_layout
11801
11802 \begin_layout Subsection
11803 Script jargon
11804 \end_layout
11805
11806 \begin_layout Itemize
11807 (O.S) — off screen
11808 \end_layout
11809
11810 \begin_layout Itemize
11811 (V.0) — voice over
11812 \end_layout
11813
11814 \begin_layout Itemize
11815 b.
11816 \begin_inset space \thinspace{}
11817 \end_inset
11818
11819 g.
11820  — background
11821 \end_layout
11822
11823 \begin_layout Itemize
11824 C.U.
11825  — close-up
11826 \end_layout
11827
11828 \begin_layout Itemize
11829 PAN — camera movement
11830 \end_layout
11831
11832 \begin_layout Itemize
11833 INSERT — cut to close-up of
11834 \end_layout
11835
11836 \begin_layout Section
11837 ijmpc and ijmpd
11838 \end_layout
11839
11840 \begin_layout Standard
11841 by 
11842 \noun on
11843 Panayotis Papasotiriou
11844 \end_layout
11845
11846 \begin_layout Subsection
11847 Overview
11848 \end_layout
11849
11850 \begin_layout Standard
11851 The ijmpc package is a set of macros that facilitates electronic manuscript
11852  submission to the 
11853 \emph on
11854 International Journal of Modern Physics C
11855 \emph default
11856 .
11857  Similarly, the ijmpd package is for creating manuscripts to be submitted
11858  to the 
11859 \emph on
11860 International Journal of Modern Physics D
11861 \emph default
11862 .
11863  Both journals are published by World Scientific.
11864  The corresponding document classes are named 
11865 \family typewriter
11866 ws-ijmpc.cls
11867 \family default
11868  and 
11869 \family typewriter
11870 ws-ijmpd.cls
11871 \family default
11872 , respectively.
11873  These files, together with instructions for the authors, can be downloaded
11874  from the sites 
11875 \begin_inset Flex URL
11876 status collapsed
11877
11878 \begin_layout Plain Layout
11879
11880 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
11881 \end_layout
11882
11883 \end_inset
11884
11885  and 
11886 \begin_inset Flex URL
11887 status collapsed
11888
11889 \begin_layout Plain Layout
11890
11891 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
11892 \end_layout
11893
11894 \end_inset
11895
11896 .
11897  Both packages are modified versions of the standard 
11898 \begin_inset Quotes eld
11899 \end_inset
11900
11901 article
11902 \begin_inset Quotes erd
11903 \end_inset
11904
11905  package, and they are almost (but not exactly) identical.
11906  Most of their features are supported by LyX.
11907  I have used LyX successfully to write articles submitted to both journals
11908  without any problem.
11909 \end_layout
11910
11911 \begin_layout Subsection
11912 Writing a paper
11913 \end_layout
11914
11915 \begin_layout Standard
11916 As usual, the easiest way to write a paper is to start with a template.
11917  Click on 
11918 \family sans
11919 File\SpecialChar \menuseparator
11920 New from
11921 \family default
11922  
11923 \family sans
11924 \bar under
11925 T
11926 \bar default
11927 emplate
11928 \family default
11929 , then choose the 
11930 \family typewriter
11931 ijmpc.lyx
11932 \family default
11933  or 
11934 \family typewriter
11935 ijmpd.lyx
11936 \family default
11937  template.
11938  This will give an (almost) empty document that includes the most common
11939  fields found in a manuscript.
11940  Simply overwrite the existing text (including the brackets, 
11941 \family typewriter
11942 <>
11943 \family default
11944 ) with your text.
11945  You should keep in mind the following remarks.
11946 \end_layout
11947
11948 \begin_layout Enumerate
11949 LyX won't let you change the font size and the page style of the document,
11950  because such modifications are not allowed by both packages.
11951 \end_layout
11952
11953 \begin_layout Enumerate
11954 The language of the document should not be changed.
11955  Before previewing your paper, be sure that the babel package is not used.
11956  To do this, click on 
11957 \family sans
11958 Tools\SpecialChar \menuseparator
11959 Preferences
11960 \family default
11961 , select the 
11962 \family sans
11963 Lang Opts
11964 \family default
11965  tab, deselect the 
11966 \family sans
11967 Use babel
11968 \family default
11969  checkbox in the language settings, and click on 
11970 \family sans
11971 Apply
11972 \family default
11973  (or 
11974 \family sans
11975 Save
11976 \family default
11977 , if you wish to make this change permanent).
11978 \end_layout
11979
11980 \begin_layout Enumerate
11981 The 
11982 \begin_inset Quotes eld
11983 \end_inset
11984
11985 Keywords
11986 \begin_inset Quotes erd
11987 \end_inset
11988
11989  style must be used to define keywords.
11990 \end_layout
11991
11992 \begin_layout Enumerate
11993 The ijmpc package provides a style named 
11994 \begin_inset Quotes eld
11995 \end_inset
11996
11997 Classification Codes
11998 \begin_inset Quotes erd
11999 \end_inset
12000
12001 , which can be used to define classification codes, such as PACS numbers.
12002  Note that this facility is not supported by the ijmpd package.
12003 \end_layout
12004
12005 \begin_layout Enumerate
12006 Several new environments are available: 
12007 \begin_inset Quotes eld
12008 \end_inset
12009
12010 Definition
12011 \begin_inset Quotes erd
12012 \end_inset
12013
12014
12015 \begin_inset Quotes eld
12016 \end_inset
12017
12018 Step
12019 \begin_inset Quotes erd
12020 \end_inset
12021
12022
12023 \begin_inset Quotes eld
12024 \end_inset
12025
12026 Example
12027 \begin_inset Quotes erd
12028 \end_inset
12029
12030
12031 \begin_inset Quotes eld
12032 \end_inset
12033
12034 Remark
12035 \begin_inset Quotes erd
12036 \end_inset
12037
12038
12039 \begin_inset Quotes eld
12040 \end_inset
12041
12042 Notation
12043 \begin_inset Quotes erd
12044 \end_inset
12045
12046
12047 \begin_inset Quotes eld
12048 \end_inset
12049
12050 Theorem
12051 \begin_inset Quotes erd
12052 \end_inset
12053
12054
12055 \begin_inset Quotes eld
12056 \end_inset
12057
12058 Proof
12059 \begin_inset Quotes erd
12060 \end_inset
12061
12062
12063 \begin_inset Quotes eld
12064 \end_inset
12065
12066 Corollary
12067 \begin_inset Quotes erd
12068 \end_inset
12069
12070
12071 \begin_inset Quotes eld
12072 \end_inset
12073
12074 Lemma
12075 \begin_inset Quotes erd
12076 \end_inset
12077
12078
12079 \begin_inset Quotes eld
12080 \end_inset
12081
12082 Proposition
12083 \begin_inset Quotes erd
12084 \end_inset
12085
12086
12087 \begin_inset Quotes eld
12088 \end_inset
12089
12090 Prop
12091 \begin_inset Quotes erd
12092 \end_inset
12093
12094
12095 \begin_inset Quotes eld
12096 \end_inset
12097
12098 Question
12099 \begin_inset Quotes erd
12100 \end_inset
12101
12102
12103 \begin_inset Quotes eld
12104 \end_inset
12105
12106 Claim
12107 \begin_inset Quotes erd
12108 \end_inset
12109
12110 , and 
12111 \begin_inset Quotes eld
12112 \end_inset
12113
12114 Conjecture
12115 \begin_inset Quotes erd
12116 \end_inset
12117
12118 .
12119  Their use is more or less obvious.
12120  LyX supports all these environments; it will use the proper label, text
12121  style, and numbering scheme for each of them.
12122 \end_layout
12123
12124 \begin_layout Enumerate
12125 Both packages use basic citations; the natbib package should not be used.
12126  In LyX, citation references are shown as usual; in the output, citations
12127  are shown as superscripts.
12128  If you want to use a citation as normal text, you should use the 
12129 \family typewriter
12130 refcite
12131 \family default
12132  command, e.
12133 \begin_inset space \thinspace{}
12134 \end_inset
12135
12136 g.
12137 \begin_inset space \space{}
12138 \end_inset
12139
12140
12141 \begin_inset Quotes eld
12142 \end_inset
12143
12144 See Ref.
12145 \begin_inset space \space{}
12146 \end_inset
12147
12148
12149 \family typewriter
12150
12151 \backslash
12152 refcite{key}
12153 \family default
12154
12155 \begin_inset Quotes erd
12156 \end_inset
12157
12158 .
12159 \end_layout
12160
12161 \begin_layout Enumerate
12162 There is no 
12163 \begin_inset Quotes eld
12164 \end_inset
12165
12166 Acknowledgments
12167 \begin_inset Quotes erd
12168 \end_inset
12169
12170  section in both packages.
12171  To put acknowledgments, just use the 
12172 \begin_inset Quotes eld
12173 \end_inset
12174
12175 Section*
12176 \begin_inset Quotes erd
12177 \end_inset
12178
12179  environment.
12180 \end_layout
12181
12182 \begin_layout Enumerate
12183 Appendices may be added to the paper, 
12184 \emph on
12185 after
12186 \emph default
12187  the Acknowledgments and 
12188 \shape italic
12189 before
12190 \shape default
12191  the References.
12192  LyX provides a special environment, called 
12193 \begin_inset Quotes eld
12194 \end_inset
12195
12196 Appendices Section
12197 \begin_inset Quotes erd
12198 \end_inset
12199
12200  which marks the beginning of the appendices.
12201  This environment should be left blank; it just sends a LaTeX command, but
12202  nothing is really printed.
12203  In LyX, the word 
12204 \begin_inset Quotes eld
12205 \end_inset
12206
12207 Appendix
12208 \begin_inset Quotes erd
12209 \end_inset
12210
12211  is printed with blue letters, as a signal that all sections after that
12212  point are appendices.
12213  To write an appendix, use the 
12214 \begin_inset Quotes eld
12215 \end_inset
12216
12217 Appendix
12218 \begin_inset Quotes erd
12219 \end_inset
12220
12221  environment.
12222  LyX will number each appendix with capital letters, as required by both
12223  journals.
12224  Note that 
12225 \begin_inset Quotes eld
12226 \end_inset
12227
12228 Appendices Section
12229 \begin_inset Quotes erd
12230 \end_inset
12231
12232  
12233 \emph on
12234 must
12235 \emph default
12236  be present before the first appendix; if not, all appendices will be numbered
12237  as normal sections in the output.
12238 \end_layout
12239
12240 \begin_layout Enumerate
12241 The ijmpc and the ijmpd packages use the 
12242 \family typewriter
12243 tbl
12244 \family default
12245  command to implement table captions.
12246  As a result, a table created by LyX is printed correctly, but its caption
12247  is ignored.
12248  However, you can use some TeX code to overcome this problem, so that captions
12249  are printed as expected.
12250  To do so, create a float table as usual, remove the caption, and replace
12251  it with the TeX code 
12252 \family typewriter
12253
12254 \backslash
12255 tbl{
12256 \emph on
12257 your table caption
12258 \emph default
12259 }{
12260 \family default
12261  (sic); you must also the TeX code 
12262 \family typewriter
12263 }
12264 \family default
12265  immediately after the tabular material.
12266  Study the example table included in the template files to see how this
12267  trick is implemented.
12268  Alternatively, If you need table captions, you should implement the whole
12269  table float in a 
12270 \family typewriter
12271 .tex
12272 \family default
12273  file, then include this file to the LyX document (
12274 \family sans
12275 Insert\SpecialChar \menuseparator
12276 File\SpecialChar \menuseparator
12277 Child
12278 \begin_inset space ~
12279 \end_inset
12280
12281 Document
12282 \family default
12283 ).
12284  Details on how to create a table float can be found in the files 
12285 \family typewriter
12286 ws-ijmpc.tex
12287 \family default
12288  and 
12289 \family typewriter
12290 ws-ijmpd.tex
12291 \family default
12292 , included in the corresponding packages.
12293 \end_layout
12294
12295 \begin_layout Subsection
12296 Preparing a paper for submission
12297 \end_layout
12298
12299 \begin_layout Standard
12300 Before you submit your paper you must export the LyX document as a LaTeX
12301  file (
12302 \family sans
12303 File\SpecialChar \menuseparator
12304 Export\SpecialChar \menuseparator
12305 LaTeX
12306 \family default
12307 )
12308 \begin_inset Foot
12309 status open
12310
12311 \begin_layout Plain Layout
12312 Actually you have the choice between LaTeX (plain) and pdflatex.
12313  If you intend to use pdflatex to prepare the paper, you should use the
12314  pdflatex option so that included graphics are converted to PDF format,
12315  ready for use by pdflatex.
12316 \end_layout
12317
12318 \end_inset
12319
12320 , then make the following changes to the resulting 
12321 \family typewriter
12322 .tex
12323 \family default
12324  file.
12325 \end_layout
12326
12327 \begin_layout Enumerate
12328 Remove the comment lines before the 
12329 \family typewriter
12330
12331 \backslash
12332 documentclass
12333 \family default
12334  command.
12335 \end_layout
12336
12337 \begin_layout Enumerate
12338 Remove everything between (and including) the 
12339 \family typewriter
12340
12341 \backslash
12342 makeatletter
12343 \family default
12344  and 
12345 \family typewriter
12346
12347 \backslash
12348 makeatother
12349 \family default
12350  commands, except for any commands you specifically put into the LaTeX preamble.
12351 \end_layout
12352
12353 \begin_layout Standard
12354 The modified 
12355 \family typewriter
12356 .tex
12357 \family default
12358  file should be saved and processed through LaTeX as many times as necessary.
12359  You may also want to check the resulting 
12360 \family typewriter
12361 .dvi
12362 \family default
12363  document.
12364 \end_layout
12365
12366 \begin_layout Subsection
12367 Use of TeX code
12368 \end_layout
12369
12370 \begin_layout Standard
12371 The use of TeX code is reduced to two commands, which must be placed at
12372  the top of the document.
12373  If you started writing your paper by using the 
12374 \family typewriter
12375 ijmpc.lyx
12376 \family default
12377  or the 
12378 \family typewriter
12379 ijmpd.lyx
12380 \family default
12381  template, the TeX code needed is already in its place; you usually don't
12382  need to delete it.
12383  You may only modify the first TeX code to specify the information printed
12384  to the top of odd and even pages (authors' names and short paper's title,
12385  respectively).
12386  This TeX code must have the form 
12387 \family typewriter
12388
12389 \backslash
12390 markboth{Authors' Names}{Short Paper's Title}
12391 \family default
12392 .
12393 \end_layout
12394
12395 \begin_layout Section
12396 iopart
12397 \end_layout
12398
12399 \begin_layout Standard
12400 by 
12401 \noun on
12402 Uwe Stöhr
12403 \end_layout
12404
12405 \begin_layout Subsection
12406 Overview
12407 \end_layout
12408
12409 \begin_layout Standard
12410 The iopart package provides a document class to create electronic manuscript
12411  submission to the journals published by the Institute of Physics.
12412  Instructions for the authors how to create a paper using the iopart class
12413  can be downloaded together with the iopart package from the site 
12414 \begin_inset Flex URL
12415 status collapsed
12416
12417 \begin_layout Plain Layout
12418
12419 ftp://ftp.iop.org/pub/journals/latex2e
12420 \end_layout
12421
12422 \end_inset
12423
12424 .
12425 \end_layout
12426
12427 \begin_layout Subsection
12428 Writing a paper
12429 \end_layout
12430
12431 \begin_layout Standard
12432 The easiest way to write a paper is to start with the file 
12433 \emph on
12434 IOP-article.lyx
12435 \emph default
12436  that is available in LyX's examples files folder.
12437  Open this file, save it under a new name, and start writing.
12438  The example file explains how to use the special text environments.
12439  Here are the most important advices:
12440 \end_layout
12441
12442 \begin_layout Itemize
12443 To be able to compile your document to a PDF, PS, or DVI, ensure that the
12444  two options 
12445 \family sans
12446 Use AMS math package
12447 \family default
12448  in the document settings under 
12449 \family sans
12450 Math Options
12451 \family default
12452  are not used!
12453 \end_layout
12454
12455 \begin_layout Itemize
12456
12457 \size normal
12458 The title environment defines the kind of your paper.
12459  So use one of the following environments for the title:
12460 \end_layout
12461
12462 \begin_deeper
12463 \begin_layout Itemize
12464
12465 \family sans
12466 \size normal
12467 Title
12468 \family default
12469  for a Paper
12470 \end_layout
12471
12472 \begin_layout Itemize
12473
12474 \family sans
12475 \size normal
12476 Review
12477 \family default
12478  for a Review
12479 \end_layout
12480
12481 \begin_layout Itemize
12482
12483 \family sans
12484 \size normal
12485 Topical
12486 \family default
12487  for a Topical review
12488 \end_layout
12489
12490 \begin_layout Itemize
12491
12492 \family sans
12493 \size normal
12494 Comment
12495 \family default
12496  for a Comment
12497 \end_layout
12498
12499 \begin_layout Itemize
12500
12501 \family sans
12502 \size normal
12503 Note
12504 \family default
12505  for a Note
12506 \end_layout
12507
12508 \begin_layout Itemize
12509
12510 \family sans
12511 \size normal
12512 Paper
12513 \family default
12514  for a Paper (same as Title)
12515 \end_layout
12516
12517 \begin_layout Itemize
12518
12519 \family sans
12520 \size normal
12521 Prelim
12522 \family default
12523  for a Preliminary communication
12524 \end_layout
12525
12526 \begin_layout Itemize
12527
12528 \family sans
12529 \size normal
12530 Rapid
12531 \family default
12532  for a Rapid communication
12533 \end_layout
12534
12535 \begin_layout Itemize
12536
12537 \family sans
12538 \size normal
12539 Letter
12540 \family default
12541  for a Letter to the editor
12542 \end_layout
12543
12544 \end_deeper
12545 \begin_layout Itemize
12546
12547 \size normal
12548 All title environments except of 
12549 \family sans
12550 Letter
12551 \family default
12552  can have an optional short title.
12553 \end_layout
12554
12555 \begin_layout Itemize
12556 There is a general title environment 
12557 \family sans
12558 Article
12559 \family default
12560  which is not directly supported by the LyX.
12561  This can be used as TeX code when your document doesn't fit into one of
12562  the other title types.
12563 \end_layout
12564
12565 \begin_layout Standard
12566 For more informations like hints for special table and formula formatting,
12567  look at the IOP author guidelines.
12568 \end_layout
12569
12570 \begin_layout Section
12571 Kluwer
12572 \end_layout
12573
12574 \begin_layout Standard
12575 by 
12576 \noun on
12577 Panayotis Papasotiriou
12578 \end_layout
12579
12580 \begin_layout Subsection
12581 Overview
12582 \end_layout
12583
12584 \begin_layout Standard
12585 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
12586  that facilitates electronic manuscript submission to the journals they
12587  publish.
12588  Most known of them (at least in my domain of interest) are 
12589 \emph on
12590 Astrophysics and Space Science
12591 \emph default
12592  and 
12593 \emph on
12594 Solar Physics
12595 \emph default
12596 , but there are many others (see a complete list at 
12597 \begin_inset Flex URL
12598 status open
12599
12600 \begin_layout Plain Layout
12601
12602 http://www.wkap.nl/jrnllist.htm/JRNLHOME
12603 \end_layout
12604
12605 \end_inset
12606
12607 ).
12608  The Kluwer package may be downloaded from the site 
12609 \begin_inset Flex URL
12610 status collapsed
12611
12612 \begin_layout Plain Layout
12613
12614 http://www.wkap.nl/kaphtml.htm/STYLEFILES
12615 \end_layout
12616
12617 \end_inset
12618
12619 .
12620  A complete user guide is contained in that package (but it can also be
12621  downloaded separately).
12622 \end_layout
12623
12624 \begin_layout Standard
12625 LyX supports many features of the package but not everything.
12626  However, the TeX code needed is reduced to some 
12627 \begin_inset Quotes eld
12628 \end_inset
12629
12630 peculiar
12631 \begin_inset Quotes erd
12632 \end_inset
12633
12634  commands of the package (see
12635 \begin_inset space ~
12636 \end_inset
12637
12638
12639 \begin_inset CommandInset ref
12640 LatexCommand ref
12641 reference "subsec:kluwer_peculiarities"
12642
12643 \end_inset
12644
12645 ).
12646  I have recently used LyX to write an article submitted to the 
12647 \emph on
12648 Astrophysics and Space Science
12649 \emph default
12650  without any problem.
12651 \end_layout
12652
12653 \begin_layout Subsection
12654 Writing a paper
12655 \end_layout
12656
12657 \begin_layout Standard
12658 The easiest way to write a paper is to start with the Kluwer template file.
12659  Click on 
12660 \family sans
12661 File\SpecialChar \menuseparator
12662 New from
12663 \family default
12664  
12665 \family sans
12666 Template
12667 \family default
12668 , then choose the 
12669 \family typewriter
12670 kluwer.lyx
12671 \family default
12672  template.
12673  This will give an (almost) empty document that includes the most common
12674  fields found in a manuscript and a short description of their use.
12675  As in most templates, simply overwrite the existing text (including the
12676  brackets, 
12677 \family typewriter
12678 <>
12679 \family default
12680 ) with the correct information.
12681 \end_layout
12682
12683 \begin_layout Subsection
12684 Preparing a paper for submission
12685 \end_layout
12686
12687 \begin_layout Standard
12688 As in the AASTeX package, before you submit your paper to a journal you
12689  must 
12690 \begin_inset Quotes eld
12691 \end_inset
12692
12693 postprocess
12694 \begin_inset Quotes erd
12695 \end_inset
12696
12697  it as follows.
12698 \end_layout
12699
12700 \begin_layout Enumerate
12701 Export your paper as a LaTeX file.
12702  To do this, click on 
12703 \family sans
12704 File\SpecialChar \menuseparator
12705 Export\SpecialChar \menuseparator
12706 LaTeX
12707 \family default
12708 .
12709  
12710 \end_layout
12711
12712 \begin_layout Enumerate
12713 Edit the resulting 
12714 \family typewriter
12715 .tex
12716 \family default
12717  file with a text editor and make the following changes
12718 \end_layout
12719
12720 \begin_deeper
12721 \begin_layout Enumerate
12722 remove the comment lines before the 
12723 \family typewriter
12724
12725 \backslash
12726 documentclass
12727 \family default
12728  command,
12729 \end_layout
12730
12731 \begin_layout Enumerate
12732 remove everything between (and including) the 
12733 \family typewriter
12734
12735 \backslash
12736 makeatletter
12737 \family default
12738  and 
12739 \family typewriter
12740
12741 \backslash
12742 makeatother
12743 \family default
12744  commands, except for any commands you specifically put into the LaTeX preamble.
12745 \end_layout
12746
12747 \begin_layout Standard
12748 Save the resulting 
12749 \family typewriter
12750 .tex
12751 \family default
12752  file.
12753 \end_layout
12754
12755 \end_deeper
12756 \begin_layout Enumerate
12757 Run the 
12758 \family typewriter
12759 .tex
12760 \family default
12761  file through LaTeX as many times as necessary (usually up to three).
12762 \end_layout
12763
12764 \begin_layout Enumerate
12765 View the resulting 
12766 \family typewriter
12767 .dvi
12768 \family default
12769  document using, e.
12770 \begin_inset space \thinspace{}
12771 \end_inset
12772
12773 g.
12774 \begin_inset space \space{}
12775 \end_inset
12776
12777
12778 \family sans
12779 xdvi
12780 \family default
12781 , and check if everything is OK (it should, if you didn't make any mistake).
12782 \end_layout
12783
12784 \begin_layout Subsection
12785 \begin_inset Quotes eld
12786 \end_inset
12787
12788 Peculiarities
12789 \begin_inset Quotes erd
12790 \end_inset
12791
12792  of the Kluwer package
12793 \begin_inset CommandInset label
12794 LatexCommand label
12795 name "subsec:kluwer_peculiarities"
12796
12797 \end_inset
12798
12799
12800 \end_layout
12801
12802 \begin_layout Standard
12803 The Kluwer package has the following 
12804 \begin_inset Quotes eld
12805 \end_inset
12806
12807 peculiarities
12808 \begin_inset Quotes erd
12809 \end_inset
12810
12811 .
12812 \end_layout
12813
12814 \begin_layout Enumerate
12815 It is possible to write multiple articles in the same LaTeX file
12816 \begin_inset Foot
12817 status collapsed
12818
12819 \begin_layout Plain Layout
12820 I can't imagine any good reason to do this.
12821 \end_layout
12822
12823 \end_inset
12824
12825 .
12826  Each article must be included in the environment 
12827 \begin_inset Quotes eld
12828 \end_inset
12829
12830 article
12831 \begin_inset Quotes erd
12832 \end_inset
12833
12834 .
12835  Unfortunately, this environment cannot be omitted, even if you write just
12836  one article.
12837  Therefore, each article starts with the command 
12838 \family typewriter
12839
12840 \backslash
12841 begin{article}
12842 \family default
12843  and, obviously, ends with the command 
12844 \family typewriter
12845
12846 \backslash
12847 end{article}
12848 \family default
12849 .
12850  Although this can be implemented in LyX, I didn't included it, since it
12851  looks ugly and can confuse the novice user.
12852  Therefore, you need to enter them directly and mark them as LaTeX code
12853  (the well-known 
12854 \begin_inset Quotes eld
12855 \end_inset
12856
12857 TeX code
12858 \begin_inset Quotes erd
12859 \end_inset
12860
12861 ).
12862 \end_layout
12863
12864 \begin_layout Enumerate
12865 Information given at the beginning of the article (i.
12866 \begin_inset space \thinspace{}
12867 \end_inset
12868
12869 g.
12870 \begin_inset space \space{}
12871 \end_inset
12872
12873 title, subtitle, author, institution, running title, running author, abstract
12874  and keywords) must be included in an environment called 
12875 \begin_inset Quotes eld
12876 \end_inset
12877
12878 opening
12879 \begin_inset Quotes erd
12880 \end_inset
12881
12882 .
12883  This is not implemented in LyX, so you must enter title, subtitle etc.
12884 \begin_inset space ~
12885 \end_inset
12886
12887 between two TeX code lines (
12888 \family typewriter
12889
12890 \backslash
12891 begin{opening}
12892 \family default
12893  and 
12894 \family typewriter
12895
12896 \backslash
12897 end{opening}
12898 \family default
12899 ).
12900 \end_layout
12901
12902 \begin_layout Enumerate
12903 According to the user manual, the label of each bibliography item must be
12904  written as 
12905 \family typewriter
12906
12907 \backslash
12908 protect
12909 \backslash
12910 citeauthoryear{
12911 \family default
12912 \emph on
12913 author(s)
12914 \family typewriter
12915 \emph default
12916 }{
12917 \family default
12918 \emph on
12919 year
12920 \family typewriter
12921 \emph default
12922 }
12923 \family default
12924 .
12925 \end_layout
12926
12927 \begin_layout Standard
12928 The 
12929 \family typewriter
12930 kluwer.lyx
12931 \family default
12932  template takes care of all these 
12933 \begin_inset Quotes eld
12934 \end_inset
12935
12936 peculiarities
12937 \begin_inset Quotes erd
12938 \end_inset
12939
12940 .
12941  If you start a new paper using this template you don't need to do anything
12942  special.
12943  Just 
12944 \end_layout
12945
12946 \begin_layout Enumerate
12947 don't delete the TeX code included in the template, and
12948 \end_layout
12949
12950 \begin_layout Enumerate
12951 copy the example bibliography item included in the template and modify it
12952  as necessary to enter new bibliography items.
12953 \end_layout
12954
12955 \begin_layout Section
12956 Koma-Script
12957 \end_layout
12958
12959 \begin_layout Standard
12960 by 
12961 \noun on
12962 Bernd Rellermeyer
12963 \end_layout
12964
12965 \begin_layout Subsection
12966 Overview
12967 \end_layout
12968
12969 \begin_layout Standard
12970 The LyX document classes 
12971 \emph on
12972 article (koma-script)
12973 \emph default
12974
12975 \emph on
12976 report (koma-script)
12977 \emph default
12978
12979 \emph on
12980 book
12981 \emph default
12982  
12983 \emph on
12984 (koma-script)
12985 \emph default
12986 , and 
12987 \emph on
12988 letter
12989 \emph default
12990  
12991 \emph on
12992 (koma-script)
12993 \emph default
12994  correspond to the LaTeX document classes 
12995 \family typewriter
12996 scrartcl.cls
12997 \family default
12998
12999 \family typewriter
13000 scrreprt.cls
13001 \family default
13002
13003 \family typewriter
13004 scrbook.cls
13005 \family default
13006 , and 
13007 \family typewriter
13008 scrlettr.cls
13009 \family default
13010 , resp.
13011 \begin_inset space ~
13012 \end_inset
13013
13014 of the Koma-Script family.
13015  They are replacements for the standard document classes 
13016 \family typewriter
13017 article.cls
13018 \family default
13019
13020 \family typewriter
13021 report.cls
13022 \family default
13023
13024 \family typewriter
13025 book.cls
13026 \family default
13027  and 
13028 \family typewriter
13029 letter.cls
13030 \family default
13031 , resp., and fit better to European typography conventions in a number of
13032  points.
13033 \end_layout
13034
13035 \begin_layout Itemize
13036 Standard character size is 11pt in 
13037 \emph on
13038 article (koma-script)
13039 \emph default
13040
13041 \emph on
13042 report (koma-script)
13043 \emph default
13044 , and 
13045 \emph on
13046 book (koma-script)
13047 \emph default
13048 , and 12pt in 
13049 \emph on
13050 letter (koma-script)
13051 \emph default
13052 .
13053 \end_layout
13054
13055 \begin_layout Itemize
13056 Headings, labels of the description environment, and a number of elements
13057  of the 
13058 \emph on
13059 letter (koma-script)
13060 \emph default
13061  document class are set in a bold sans serif font.
13062 \begin_inset Foot
13063 status collapsed
13064
13065 \begin_layout Plain Layout
13066 There is a big difference between the bold sans serif old cm fonts and new
13067  ec fonts, especially in the appearance of headings.
13068  In comparison, the ec bold sans serif fonts look a bit thin.
13069  Here the LaTeX package 
13070 \family typewriter
13071 cmsd.sty by
13072 \family default
13073  
13074 \shape smallcaps
13075 Walter Schmidt
13076 \shape default
13077  helps to produce the 
13078 \begin_inset Quotes eld
13079 \end_inset
13080
13081 usual
13082 \begin_inset Quotes erd
13083 \end_inset
13084
13085  appearance when using the ec fonts.
13086 \end_layout
13087
13088 \end_inset
13089
13090  The numbering of chapter headings is made in the same way as the numbering
13091  of section headings, that is without the extra line 
13092 \begin_inset Quotes eld
13093 \end_inset
13094
13095 Chapter\SpecialChar \ldots{}
13096
13097 \begin_inset Quotes erd
13098 \end_inset
13099
13100 .
13101  In addition, the appearance of the headings can be modified by using a
13102  number of options (in LyX to be entered in the field 
13103 \family sans
13104 Extra
13105 \begin_inset space ~
13106 \end_inset
13107
13108 Options
13109 \family default
13110  of the dialog 
13111 \family sans
13112 Layout\SpecialChar \menuseparator
13113 Document
13114 \family default
13115 ).
13116  
13117 \end_layout
13118
13119 \begin_layout Itemize
13120 The main means in the Koma-Script document classes to design the type area
13121  are the options 
13122 \family sans
13123 BCOR
13124 \family default
13125  and 
13126 \family sans
13127 DIV
13128 \family default
13129  (in LyX to be entered in the extra class options field in the dialog 
13130 \family sans
13131 Document\SpecialChar \menuseparator
13132 Settings
13133 \family default
13134 ).
13135  They make a clearer modification of page margins possible as do the options
13136  of the dialog 
13137 \family sans
13138 Document\SpecialChar \menuseparator
13139 Settings
13140 \family default
13141 .
13142  
13143 \end_layout
13144
13145 \begin_layout Itemize
13146 The LaTeX document classes of the Koma-Script family define a number of
13147  additional commands.
13148  Those part of it which makes sense in LyX is implemented in corresponding
13149  paragraph types.
13150 \end_layout
13151
13152 \begin_layout Standard
13153 Detailed descriptions of the LaTeX document classes of the Koma-Script family
13154  can be found in the Koma-Script documentation 
13155 \emph on
13156 scrguide
13157 \emph default
13158  (German) and 
13159 \emph on
13160 scrguien
13161 \emph default
13162  (English).
13163 \end_layout
13164
13165 \begin_layout Subsection
13166 article (koma-script), report (koma-script), and book (koma-script)
13167 \end_layout
13168
13169 \begin_layout Standard
13170 The document classes 
13171 \emph on
13172 article (koma-script)
13173 \emph default
13174
13175 \emph on
13176 report (koma-script)
13177 \emph default
13178 , and 
13179 \emph on
13180 book
13181 \emph default
13182  
13183 \emph on
13184 (koma-script)
13185 \emph default
13186  are implemented in the layout files 
13187 \family typewriter
13188 scrartcl.layout
13189 \family default
13190
13191 \family typewriter
13192 scrreprt.layout
13193 \family default
13194 , and 
13195 \family typewriter
13196 scrbook.layout
13197 \family default
13198 , resp.
13199  They contain all the paragraph types of the corresponding standard document
13200  classes 
13201 \emph on
13202 article
13203 \emph default
13204
13205 \emph on
13206 report
13207 \emph default
13208 , and 
13209 \emph on
13210 book
13211 \emph default
13212 , resp., partly modified, with the exception of the LyX specific 
13213 \family sans
13214 List
13215 \family default
13216 -type, which is replaced by the new 
13217 \family sans
13218 Labeling
13219 \family default
13220 -type having the same functionality.
13221  Beside the 
13222 \family sans
13223 Labeling
13224 \family default
13225 -Type there is a number of new paragraph types added.
13226  They are 
13227 \emph on
13228 not
13229 \emph default
13230  part of 
13231 \emph on
13232 letter (koma-script)
13233 \emph default
13234 .
13235 \end_layout
13236
13237 \begin_layout Itemize
13238
13239 \family sans
13240 Addpart, Addchap
13241 \family default
13242
13243 \family sans
13244 Addsec
13245 \family default
13246 : are equivalents to 
13247 \family sans
13248 Part*, Chapter*
13249 \family default
13250  and 
13251 \family sans
13252 Section*
13253 \family default
13254 , resp., additionally inserting an entry in the table of contents.
13255  
13256 \family sans
13257 Addpart
13258 \family default
13259  and 
13260 \family sans
13261 Addchap
13262 \family default
13263  are not contained in 
13264 \emph on
13265 article (koma-script)
13266 \emph default
13267 .
13268 \end_layout
13269
13270 \begin_layout Itemize
13271
13272 \family sans
13273 Addchap*
13274 \family default
13275
13276 \family sans
13277 Addsec*
13278 \family default
13279 : behave exactly as 
13280 \family sans
13281 Addchap
13282 \family default
13283  and 
13284 \family sans
13285 Addsec
13286 \family default
13287 , resp., additionally clearing running heads.
13288  
13289 \family sans
13290 Addchap*
13291 \family default
13292  is not contained in 
13293 \emph on
13294 article (koma-script)
13295 \emph default
13296 .
13297 \begin_inset Foot
13298 status collapsed
13299
13300 \begin_layout Plain Layout
13301 There is also an 
13302 \family typewriter
13303
13304 \backslash
13305 addpart*
13306 \family default
13307  command in 
13308 \emph on
13309 book (koma-script)
13310 \emph default
13311  and in 
13312 \emph on
13313 report (koma-script)
13314 \emph default
13315 , but since this is identical to 
13316 \family sans
13317 Part*
13318 \family default
13319 , is has not been implemented in LyX.
13320 \end_layout
13321
13322 \end_inset
13323
13324
13325 \end_layout
13326
13327 \begin_layout Itemize
13328
13329 \family sans
13330 Minisec
13331 \family default
13332 : generates a heading directly above the following paragraph in the standard
13333  character size without affecting the structure of the document.
13334 \end_layout
13335
13336 \begin_layout Itemize
13337
13338 \family sans
13339 Captionabove
13340 \family default
13341  and 
13342 \family sans
13343 Captionbelow
13344 \family default
13345  are special captions which respect the different space settings needed
13346  for captions placed above or below an element (if you follow strict typographic
13347  rules, you might want to place table captions always above the table).
13348  You can also use the class option 
13349 \family typewriter
13350 tablecaptionsabove
13351 \family default
13352 , which will switch 
13353 \family sans
13354 caption
13355 \family default
13356  to 
13357 \family sans
13358 captionabove
13359 \family default
13360  for tables and 
13361 \family sans
13362 captionbelow
13363 \family default
13364  for figures.
13365  You need at least Koma-Script version 2.8q to use this.
13366 \end_layout
13367
13368 \begin_layout Itemize
13369
13370 \family sans
13371 Dictum
13372 \family default
13373 : can be used to set a bonmot, e.
13374 \begin_inset space \thinspace{}
13375 \end_inset
13376
13377 g.
13378 \begin_inset space \space{}
13379 \end_inset
13380
13381 at the beginning of a chapter.
13382  If you use the optional argument (
13383 \family sans
13384 Insert\SpecialChar \menuseparator
13385 Short
13386 \begin_inset space ~
13387 \end_inset
13388
13389 Title
13390 \family default
13391 ), you can insert the dictum's author there.
13392  Dictum and author are separated by a line.
13393  You need at least Koma-Script version 2.8q to use this.
13394  
13395 \family sans
13396 Dictum
13397 \family default
13398  is not contained in 
13399 \emph on
13400 article (koma-script)
13401 \emph default
13402 .
13403 \end_layout
13404
13405 \begin_layout Standard
13406 The following types, together with the standard types 
13407 \family sans
13408 Title
13409 \family default
13410
13411 \family sans
13412 Author
13413 \family default
13414 , and 
13415 \family sans
13416 Date
13417 \family default
13418 , form the title area of the document.
13419  They must be entered ahead of the first 
13420 \begin_inset Quotes eld
13421 \end_inset
13422
13423 ordinary
13424 \begin_inset Quotes erd
13425 \end_inset
13426
13427  paragraph.
13428 \begin_inset Foot
13429 status collapsed
13430
13431 \begin_layout Plain Layout
13432 The corresponding LaTeX commands must appear before the 
13433 \family typewriter
13434
13435 \backslash
13436 maketitle
13437 \family default
13438  command.
13439 \end_layout
13440
13441 \end_inset
13442
13443  When such a type is used more than once, the latter usage overwrites the
13444  former one, that means, for every type only the latest usage is valid.
13445  The order of the different types however has, like 
13446 \family sans
13447 Title
13448 \family default
13449
13450 \family sans
13451 Author
13452 \family default
13453 , and 
13454 \family sans
13455 Date
13456 \family default
13457 , no effect on the appearance of the produced document.
13458 \end_layout
13459
13460 \begin_layout Itemize
13461
13462 \family sans
13463 Subject
13464 \family default
13465 : produces a centered paragraph above the ordinary title (
13466 \family sans
13467 Title
13468 \family default
13469
13470 \family sans
13471 Author
13472 \family default
13473
13474 \family sans
13475 Date
13476 \family default
13477 ) for the subject of the document.
13478 \end_layout
13479
13480 \begin_layout Itemize
13481
13482 \family sans
13483 Publishers
13484 \family default
13485 : produces a centered paragraph below the ordinary title (
13486 \family sans
13487 Title
13488 \family default
13489
13490 \family sans
13491 Author
13492 \family default
13493
13494 \family sans
13495 Date
13496 \family default
13497 ) for the publishers' name.
13498 \end_layout
13499
13500 \begin_layout Itemize
13501
13502 \family sans
13503 Dedication
13504 \family default
13505 : in 
13506 \emph on
13507 report (koma-script)
13508 \emph default
13509  and 
13510 \emph on
13511 book (koma-script)
13512 \emph default
13513  produces a centered paragraph on its own page behind the title page, or
13514  in 
13515 \emph on
13516 article (koma-script)
13517 \emph default
13518  produces a centered paragraph below the ordinary title (
13519 \family sans
13520 Title
13521 \family default
13522
13523 \family sans
13524 Author
13525 \family default
13526
13527 \family sans
13528 Date
13529 \family default
13530
13531 \family sans
13532 Publishers
13533 \family default
13534 ) for a dedication.
13535 \end_layout
13536
13537 \begin_layout Itemize
13538
13539 \family sans
13540 Titlehead
13541 \family default
13542 : produces a left aligned paragraph above the ordinary title (
13543 \family sans
13544 Title
13545 \family default
13546
13547 \family sans
13548 Author
13549 \family default
13550
13551 \family sans
13552 Date
13553 \family default
13554
13555 \family sans
13556 Subject
13557 \family default
13558 ) for a document`s head.
13559 \end_layout
13560
13561 \begin_layout Itemize
13562
13563 \family sans
13564 Uppertitleback
13565 \family default
13566 : produces in a double-sided print in 
13567 \emph on
13568 report (koma-script)
13569 \emph default
13570  and 
13571 \emph on
13572 book (koma-script)
13573 \emph default
13574  a left-aligned paragraph at the top of the title page`s back or has no
13575  effect in a single-sided print or in 
13576 \emph on
13577 article (koma-script)
13578 \emph default
13579 .
13580 \end_layout
13581
13582 \begin_layout Itemize
13583
13584 \family sans
13585 Lowertitleback
13586 \family default
13587 : produces in a double-sided print in 
13588 \emph on
13589 report (koma-script)
13590 \emph default
13591  and 
13592 \emph on
13593 book (koma-script)
13594 \emph default
13595  a left-aligned paragraph at the bottom of the title page`s back or has
13596  no effect in a single-sided print or in 
13597 \emph on
13598 article (koma-script)
13599 \emph default
13600 .
13601 \end_layout
13602
13603 \begin_layout Itemize
13604
13605 \family sans
13606 Extratitle
13607 \family default
13608 : produces a special 
13609 \begin_inset Quotes eld
13610 \end_inset
13611
13612 dirty
13613 \begin_inset Quotes erd
13614 \end_inset
13615
13616  page ahead of the actual document containing a paragraph without special
13617  formatting.
13618 \end_layout
13619
13620 \begin_layout Standard
13621 The layout files for the document classes 
13622 \emph on
13623 article (koma-script)
13624 \emph default
13625
13626 \emph on
13627 report (koma-script)
13628 \emph default
13629 , and 
13630 \emph on
13631 book (koma-script)
13632 \emph default
13633  do include the file 
13634 \family typewriter
13635 scrmacros.inc
13636 \family default
13637 .
13638  This is thought of as a place to define your own types.
13639  Copy scrmacros
13640 \family typewriter
13641 .inc
13642 \family default
13643  in your personal layout directory and edit the file!
13644 \end_layout
13645
13646 \begin_layout Subsection
13647 letter (koma-script)
13648 \end_layout
13649
13650 \begin_layout Standard
13651 \noindent
13652 The document class 
13653 \emph on
13654 letter (koma-script)
13655 \emph default
13656  is implemented in the layout file 
13657 \family typewriter
13658 scrlettr.layout
13659 \family default
13660 .
13661  It contains all the paragraph types of the corresponding standard document
13662  class 
13663 \emph on
13664 letter
13665 \emph default
13666 , partly modified, with the exception of the LyX specific types 
13667 \family sans
13668 LyX-Code
13669 \family default
13670  and 
13671 \family sans
13672 Comment
13673 \family default
13674  and the 
13675 \family sans
13676 List
13677 \family default
13678  type, which is replaced by the new 
13679 \family sans
13680 Labeling
13681 \family default
13682  type.
13683  In addition, it contains, in contrast to the standard document class, the
13684  standard types 
13685 \family sans
13686 LaTeX
13687 \family default
13688
13689 \family sans
13690 Quotation
13691 \family default
13692
13693 \family sans
13694 Quote
13695 \family default
13696 , and 
13697 \family sans
13698 Verse
13699 \family default
13700 .
13701  Furthermore, there are a number of new letter specific types.
13702 \end_layout
13703
13704 \begin_layout Standard
13705 The appearance of the letter produced by this document class can be controlled
13706  by a number of LaTeX commands, which you can put in the LaTeX preamble.
13707 \begin_inset Foot
13708 status collapsed
13709
13710 \begin_layout Plain Layout
13711 For example, the standard appearance of the letter`s heading, consisting
13712  of name and address, is quite self-willed.
13713  An 
13714 \begin_inset Quotes eld
13715 \end_inset
13716
13717 ordinary
13718 \begin_inset Quotes erd
13719 \end_inset
13720
13721  heading is produced by the following LaTeX commands in the preamble:
13722 \end_layout
13723
13724 \begin_layout LyX-Code
13725
13726 \backslash
13727 firsthead{
13728 \backslash
13729 parbox[b]{
13730 \backslash
13731 textwidth}
13732 \end_layout
13733
13734 \begin_layout LyX-Code
13735   {
13736 \backslash
13737 ignorespaces 
13738 \backslash
13739 fromname
13740 \backslash
13741
13742 \backslash
13743  
13744 \backslash
13745 ignorespaces 
13746 \backslash
13747 fromaddress}} 
13748 \end_layout
13749
13750 \begin_layout LyX-Code
13751
13752 \backslash
13753 nexthead{
13754 \backslash
13755 parbox[b]{
13756 \backslash
13757 textwidth}
13758 \end_layout
13759
13760 \begin_layout LyX-Code
13761   {
13762 \backslash
13763 ignorespaces 
13764 \backslash
13765 fromname 
13766 \backslash
13767 hfill 
13768 \backslash
13769 ignorespaces 
13770 \backslash
13771 pagename
13772 \backslash
13773  
13774 \backslash
13775 thepage}}
13776 \end_layout
13777
13778 \end_inset
13779
13780  A detailed German description of such LaTeX commands can be found in the
13781  Koma-Script documentation 
13782 \emph on
13783 scrguide
13784 \emph default
13785 .
13786  With it, the letter's author can produce his personal letter layout.
13787 \end_layout
13788
13789 \begin_layout Standard
13790 The types 
13791 \family sans
13792 Letter
13793 \family default
13794  and 
13795 \family sans
13796 Opening
13797 \family default
13798  define the beginning of the letter and must be used in every letter.
13799  To emphasize them in the LyX document class, they are marked with the letter
13800  
13801 \shape italic
13802 L
13803 \shape default
13804  or 
13805 \shape italic
13806 O
13807 \shape default
13808 , resp.
13809 \begin_inset space ~
13810 \end_inset
13811
13812 in the left margin.
13813  It is possible to write any number of letters in one file.
13814  An 
13815 \family sans
13816 Opening
13817 \family default
13818  type produces a new letter using the same addressee and a 
13819 \family sans
13820 Letter
13821 \family default
13822  type produces a new addressee.
13823  The types 
13824 \family sans
13825 Closing
13826 \family default
13827
13828 \family sans
13829 PS
13830 \family default
13831
13832 \family sans
13833 CC
13834 \family default
13835 , and 
13836 \family sans
13837 Encl
13838 \family default
13839  are ordinary paragraph types and can also be used several times in one
13840  and the same letter.
13841 \end_layout
13842
13843 \begin_layout Itemize
13844
13845 \family sans
13846 Letter
13847 \family default
13848 : produces a paragraph for the addressee and implicitly defines the beginning
13849  of the letter.
13850 \end_layout
13851
13852 \begin_layout Itemize
13853
13854 \family sans
13855 Opening
13856 \family default
13857 : produces a paragraph for the form of address and implicitly produces a
13858  new letter.
13859 \end_layout
13860
13861 \begin_layout Itemize
13862
13863 \family sans
13864 Closing
13865 \family default
13866 : produces a paragraph for a close.
13867 \end_layout
13868
13869 \begin_layout Itemize
13870
13871 \family sans
13872 PS
13873 \family default
13874 : produces a paragraph for a postscript.
13875 \end_layout
13876
13877 \begin_layout Itemize
13878
13879 \family sans
13880 CC
13881 \family default
13882 : produces a paragraph for a distribution list.
13883 \end_layout
13884
13885 \begin_layout Itemize
13886
13887 \family sans
13888 Encl
13889 \family default
13890 : produces a paragraph for enclosures.
13891 \end_layout
13892
13893 \begin_layout Standard
13894 The types 
13895 \family sans
13896 Name
13897 \family default
13898
13899 \family sans
13900 Signature
13901 \family default
13902
13903 \family sans
13904 Address
13905 \family default
13906
13907 \family sans
13908 Telephone
13909 \family default
13910
13911 \family sans
13912 Place
13913 \family default
13914
13915 \family sans
13916 Backaddress
13917 \family default
13918
13919 \family sans
13920 Specialmail
13921 \family default
13922
13923 \family sans
13924 Location
13925 \family default
13926
13927 \family sans
13928 Title
13929 \family default
13930 , and 
13931 \family sans
13932 Subject
13933 \family default
13934  are input types provided with a label to enter information, which will
13935  be processed by the document class.
13936 \begin_inset Foot
13937 status open
13938
13939 \begin_layout Plain Layout
13940 It could be seen as a matter of inconsequence, that the types 
13941 \family sans
13942 Letter
13943 \family default
13944  and 
13945 \family sans
13946 Opening
13947 \family default
13948  described above are not such input types as well.
13949  Because of the special meaning of those types, however, I have implemented
13950  them as ordinary paragraph types with a one letter mark in the left margin.
13951  Moreover, it would affect my feeling of symmetry, if the 
13952 \family sans
13953 Opening
13954 \family default
13955  type and the 
13956 \family sans
13957 Closing
13958 \family default
13959  type had such a serious different appearance.
13960 \end_layout
13961
13962 \end_inset
13963
13964  The types must be used ahead of the corresponding 
13965 \family sans
13966 Opening
13967 \family default
13968  type.
13969 \end_layout
13970
13971 \begin_layout Standard
13972 An implementation of these types in a WYSIWYG fashion does not seem to make
13973  sense, because the real appearance of the produced letter does not only
13974  depend on the usage of the particular type, but also on other factors.
13975  For example, a signature entered in the 
13976 \family sans
13977 Signature
13978 \family default
13979  type will in the standard behavior appear in the produced letter only,
13980  when in the same letter also a 
13981 \family sans
13982 Closing
13983 \family default
13984  type is used.
13985  The entered value of the 
13986 \family sans
13987 Telephone
13988 \family default
13989  type will in the standard behavior not appear in the produced letter at
13990  all.
13991  The possibility to design the letter`s heading freely is already indicated
13992  in a footnote above.
13993 \end_layout
13994
13995 \begin_layout Standard
13996 The input types can also be used as empty paragraphs.
13997  This makes sense e.
13998 \begin_inset space \thinspace{}
13999 \end_inset
14000
14001 g.
14002 \begin_inset space \space{}
14003 \end_inset
14004
14005 for the 
14006 \family sans
14007 Signature
14008 \family default
14009  type.
14010  If the 
14011 \family sans
14012 Signature
14013 \family default
14014  type is not used at all, in the standard behavior the value of the 
14015 \family sans
14016 Name
14017 \family default
14018  type is used as signature, whereas if an empty 
14019 \family sans
14020 Signature
14021 \family default
14022  type is used, no signature value is defined.
14023 \end_layout
14024
14025 \begin_layout Standard
14026 By using the input types it is possible to write a letter template, containing
14027  filled input types with your personal dates (name, address, etc.) and empty
14028  input types for other dates you want to enter.
14029 \end_layout
14030
14031 \begin_layout Itemize
14032
14033 \family sans
14034 Name
14035 \family default
14036 : sender's name, in the standard behavior appears as a centered paragraph
14037  in small caps in the letter`s heading.
14038 \end_layout
14039
14040 \begin_layout Itemize
14041
14042 \family sans
14043 Signature
14044 \family default
14045 : sender's signature, in the standard behavior appears below the 
14046 \family sans
14047 Closing
14048 \family default
14049  type.
14050  If no 
14051 \family sans
14052 Signature
14053 \family default
14054  type is used, the value of the 
14055 \family sans
14056 Name
14057 \family default
14058  type appears instead.
14059 \end_layout
14060
14061 \begin_layout Itemize
14062
14063 \family sans
14064 Address
14065 \family default
14066 : sender's address, in the standard behavior appears in a centered paragraph
14067  in the letter`s heading below the sender's name.
14068 \end_layout
14069
14070 \begin_layout Itemize
14071
14072 \family sans
14073 Telephone
14074 \family default
14075 : sender's telephone number, in the standard behavior only sets the LaTeX
14076  variable 
14077 \family typewriter
14078
14079 \backslash
14080 telephonenum
14081 \family default
14082 .
14083 \end_layout
14084
14085 \begin_layout Itemize
14086
14087 \family sans
14088 Place
14089 \family default
14090 : place of the letter`s making.
14091 \end_layout
14092
14093 \begin_layout Itemize
14094
14095 \family sans
14096 Date
14097 \family default
14098 : date of the letter`s making.
14099  
14100 \family sans
14101 Place
14102 \family default
14103  and 
14104 \family sans
14105 Date
14106 \family default
14107 , in the standard behavior, produce the place and the date in a right-aligned
14108  line below the addressee's field.
14109  If an empty 
14110 \family sans
14111 Date
14112 \family default
14113  type is used, neither place nor date appear, independent of the value of
14114  the 
14115 \family sans
14116 Place
14117 \family default
14118  type.
14119  If no 
14120 \family sans
14121 Date
14122 \family default
14123  type is used, the date of the letter `s production is used.
14124 \end_layout
14125
14126 \begin_layout Itemize
14127
14128 \family sans
14129 Backaddress
14130 \family default
14131 : sender`s back address, in the standard behavior appears above the addressee's
14132  field in a small sans serif font.
14133 \end_layout
14134
14135 \begin_layout Itemize
14136
14137 \family sans
14138 Specialmail
14139 \family default
14140 : special mail information, in the standard behavior appears underlined
14141  above the addressee's field below the back address.
14142 \end_layout
14143
14144 \begin_layout Itemize
14145
14146 \family sans
14147 Location
14148 \family default
14149 : additional information, in the standard behavior appears on right side
14150  below the addressee`s field.
14151 \end_layout
14152
14153 \begin_layout Itemize
14154
14155 \family sans
14156 Title
14157 \family default
14158 : the letter's title, in the standard behavior appears in a big, bold, sans
14159  serif font above the subject.
14160 \end_layout
14161
14162 \begin_layout Itemize
14163
14164 \family sans
14165 Subject
14166 \family default
14167 : the letter's subject, in the standard behavior appears in a bold font
14168  above the 
14169 \family sans
14170 Opening
14171 \family default
14172  paragraph.
14173 \end_layout
14174
14175 \begin_layout Standard
14176 The types 
14177 \family sans
14178 Yourref
14179 \family default
14180
14181 \family sans
14182 Yourmail
14183 \family default
14184
14185 \family sans
14186 Myref
14187 \family default
14188
14189 \family sans
14190 Customer
14191 \family default
14192 , and 
14193 \family sans
14194 Invoice
14195 \family default
14196  produce a business letter like line above the 
14197 \family sans
14198 Title
14199 \family default
14200  line containing the fields 
14201 \begin_inset Quotes eld
14202 \end_inset
14203
14204 Your ref.
14205 \begin_inset Quotes erd
14206 \end_inset
14207
14208
14209 \begin_inset Quotes eld
14210 \end_inset
14211
14212 Your letter of
14213 \begin_inset Quotes erd
14214 \end_inset
14215
14216
14217 \begin_inset Quotes eld
14218 \end_inset
14219
14220 Our ref.
14221 \begin_inset Quotes erd
14222 \end_inset
14223
14224
14225 \begin_inset Quotes eld
14226 \end_inset
14227
14228 Customer no.
14229 \begin_inset Quotes erd
14230 \end_inset
14231
14232
14233 \begin_inset Quotes eld
14234 \end_inset
14235
14236 Invoice no.
14237 \begin_inset Quotes erd
14238 \end_inset
14239
14240 , and 
14241 \begin_inset Quotes eld
14242 \end_inset
14243
14244 Date
14245 \begin_inset Quotes erd
14246 \end_inset
14247
14248 .
14249  For the date field, the value of the 
14250 \family sans
14251 Date
14252 \family default
14253  type is used.
14254  If one of these 
14255 \begin_inset Quotes eld
14256 \end_inset
14257
14258 business letter types
14259 \begin_inset Quotes erd
14260 \end_inset
14261
14262  is used, the value of the 
14263 \family sans
14264 Place
14265 \family default
14266  type however does not appear, but only the LaTeX variable 
14267 \family typewriter
14268
14269 \backslash
14270 fromplace
14271 \family default
14272  is set.
14273  The ordinary output of place and date in a right-aligned line below the
14274  addressee`s field is suppressed.
14275  The types are implemented as input types provided with a label and must
14276  be used ahead of the corresponding 
14277 \family sans
14278 Opening
14279 \family default
14280  type.
14281 \end_layout
14282
14283 \begin_layout Itemize
14284
14285 \family sans
14286 Yourref
14287 \family default
14288 : Your ref.
14289 \end_layout
14290
14291 \begin_layout Itemize
14292
14293 \family sans
14294 Yourmail
14295 \family default
14296 : Your letter of.
14297 \end_layout
14298
14299 \begin_layout Itemize
14300
14301 \family sans
14302 Myref
14303 \family default
14304 : Our ref.
14305 \end_layout
14306
14307 \begin_layout Itemize
14308
14309 \family sans
14310 Customer
14311 \family default
14312 : Customer no.
14313 \end_layout
14314
14315 \begin_layout Itemize
14316
14317 \family sans
14318 Invoice
14319 \family default
14320 : Invoice no.
14321 \end_layout
14322
14323 \begin_layout Subsection
14324 The new letter class: letter (koma-script v.2)
14325 \end_layout
14326
14327 \begin_layout Standard
14328 by 
14329 \noun on
14330 Jürgen Spitzmüller
14331 \end_layout
14332
14333 \begin_layout Standard
14334 \begin_inset VSpace medskip
14335 \end_inset
14336
14337
14338 \end_layout
14339
14340 \begin_layout Standard
14341 \noindent
14342 Koma-Script version 2.8 has introduced a new letter class 
14343 \family typewriter
14344 scrlttr2
14345 \family default
14346  which supersedes the now unsupported 
14347 \family typewriter
14348 scrlettr
14349 \family default
14350 .
14351  It has — on the LaTeX side — a completely new interface and is not compatible
14352  with the old class.
14353  Therefore, LyX supports both, though it is recommended you use the new
14354  class.
14355 \end_layout
14356
14357 \begin_layout Standard
14358 This class covers the same functionality as 
14359 \emph on
14360 letter (koma-script),
14361 \emph default
14362  and a few more.
14363  The basic items are 
14364 \family sans
14365 Address
14366 \family default
14367  (receiver's address, same as 
14368 \family sans
14369 Letter
14370 \family default
14371  in the old layout), 
14372 \family sans
14373 Opening
14374 \family default
14375 , and 
14376 \family sans
14377 Closing
14378 \family default
14379 .
14380  
14381 \family sans
14382 NextAddress
14383 \family default
14384  will start a new letter (i.
14385 \begin_inset space \thinspace{}
14386 \end_inset
14387
14388 g.
14389 \begin_inset space \space{}
14390 \end_inset
14391
14392 you can write several letters per document).
14393  New elements are sender's 
14394 \family sans
14395 E-Mail
14396 \family default
14397
14398 \family sans
14399 URL
14400 \family default
14401
14402 \family sans
14403 Fax
14404 \family default
14405
14406 \family sans
14407 Bank
14408 \family default
14409  and the possibility to use a 
14410 \family sans
14411 Logo
14412 \family default
14413  (via 
14414 \family sans
14415 Insert\SpecialChar \menuseparator
14416 Graphics
14417 \family default
14418 ) in the header.
14419 \end_layout
14420
14421 \begin_layout Standard
14422 The biggest improvement is, though, that the letter's layout is configurable
14423  to meet almost any needs.
14424  This can be done via the preamble or with a special style file (Letter
14425  Class Option, extension 
14426 \family typewriter
14427 *.lco
14428 \family default
14429 ), that will be read in as a class option.
14430 \begin_inset Foot
14431 status collapsed
14432
14433 \begin_layout Plain Layout
14434 The KOMA package comes with some default 
14435 \family typewriter
14436 *.lco
14437 \family default
14438  files.
14439  There is, for instance, a 
14440 \family typewriter
14441 DIN.lco
14442 \family default
14443  file that follows german typesetting rules, or a 
14444 \family typewriter
14445 KOMAold.lco
14446 \family default
14447  that provides the default layout of the old 
14448 \family typewriter
14449 scrlettr
14450 \family default
14451  class.
14452  The latter can be loaded with the class option 
14453 \family typewriter
14454 KOMAold
14455 \family default
14456 , inserted via the 
14457 \family sans
14458 \bar under
14459 L
14460 \bar default
14461 ayout\SpecialChar \menuseparator
14462
14463 \bar under
14464 D
14465 \bar default
14466 ocument\SpecialChar \menuseparator
14467 Extra Options
14468 \family default
14469  field.
14470 \end_layout
14471
14472 \end_inset
14473
14474  Have a look at the 
14475 \emph on
14476 koma-letter2
14477 \emph default
14478  template that is included in LyX for examples.
14479  A detailed description is to be found in the Koma-Script documentation
14480  (
14481 \emph on
14482 scrguide
14483 \emph default
14484 ).
14485 \end_layout
14486
14487 \begin_layout Subsection
14488 Problems
14489 \end_layout
14490
14491 \begin_layout Standard
14492 Visualizing the Koma-Script document classes in LyX, the LyX internals cause
14493  some problems.
14494 \end_layout
14495
14496 \begin_layout Itemize
14497 The chapter number of a 
14498 \family sans
14499 Chapter
14500 \family default
14501  type appears on a line of its own above the chapter heading instead of
14502  appearing in the same line ahead of it.
14503  The cause for that is the LyX internal behavior for the labeltype 
14504 \family sans
14505 Counter_Chapter
14506 \family default
14507  in the layout file.
14508 \end_layout
14509
14510 \begin_layout Itemize
14511 The headings of the types 
14512 \family sans
14513 Addchap
14514 \family default
14515  and 
14516 \family sans
14517 Addsec
14518 \family default
14519  are only put in the 
14520 \begin_inset Quotes eld
14521 \end_inset
14522
14523 true
14524 \begin_inset Quotes erd
14525 \end_inset
14526
14527  LaTeX table of contents, but not in the LyX table of contents (
14528 \family sans
14529 Document\SpecialChar \menuseparator
14530 Table
14531 \begin_inset space ~
14532 \end_inset
14533
14534 of
14535 \begin_inset space ~
14536 \end_inset
14537
14538 Contents
14539 \family default
14540 ).
14541 \end_layout
14542
14543 \begin_layout Itemize
14544 The paragraphs in a 
14545 \emph on
14546 letter
14547 \emph default
14548  document class appear in a skip separation mode, not indented.
14549  This is the standard behavior, no special LaTeX commands are needed for
14550  that.
14551  But in the 
14552 \family sans
14553 Document\SpecialChar \menuseparator
14554 Settings
14555 \family default
14556  dialog the corresponding radio button indicates 
14557 \family sans
14558 Indent
14559 \family default
14560 .
14561  A 
14562 \family sans
14563 Skip
14564 \family default
14565  value always has the effect that extra LaTeX commands are inserted in the
14566  document to produce the gap, which is not what is wanted in this case.
14567 \end_layout
14568
14569 \begin_layout Section
14570 Memoir
14571 \end_layout
14572
14573 \begin_layout Standard
14574 By 
14575 \noun on
14576 Jürgen Spitzmüller
14577 \end_layout
14578
14579 \begin_layout Subsection
14580 Overview
14581 \end_layout
14582
14583 \begin_layout Standard
14584 Memoir is a very powerful and constantly evolving class.
14585  It has been designed with regard to fictional and non-fictional literature.
14586  Its aim is to let the user have maximum control over the typesetting of
14587  his document.
14588  Memoir is based on the standard book class, but it can also emulate the
14589  article class (see below).
14590 \end_layout
14591
14592 \begin_layout Standard
14593 Peter Wilson, the developer of Memoir, is known as the author of lots of
14594  useful packages in the LaTeX world.
14595  Most of them have been merged with Memoir.
14596  Therefore, it is much easier to layout the table of contents, appendices,
14597  chapter designs and such.
14598  LyX, though, does not support all of these goodies natively.
14599  Some of them might be added to forthcoming releases
14600 \begin_inset Foot
14601 status collapsed
14602
14603 \begin_layout Plain Layout
14604 You are invited to send suggestions to 
14605 \begin_inset Flex URL
14606 status collapsed
14607
14608 \begin_layout Plain Layout
14609
14610 lyx-devel@lists.lyx.org
14611 \end_layout
14612
14613 \end_inset
14614
14615 .
14616 \end_layout
14617
14618 \end_inset
14619
14620 , lots will probably never, due to the limitations of LyX's framework.
14621  Of course you can still use all features with the help of some native LaTeX
14622  commands (TeX code
14623 \begin_inset Foot
14624 status collapsed
14625
14626 \begin_layout Plain Layout
14627 Cf.
14628 \begin_inset ERT
14629 status collapsed
14630
14631 \begin_layout Plain Layout
14632
14633
14634 \backslash
14635  
14636 \end_layout
14637
14638 \end_inset
14639
14640 section
14641 \begin_inset space ~
14642 \end_inset
14643
14644
14645 \begin_inset CommandInset ref
14646 LatexCommand ref
14647 reference "sec:Inserting-TeX-Code"
14648
14649 \end_inset
14650
14651  for details.
14652 \end_layout
14653
14654 \end_inset
14655
14656 ).
14657  In this section, we can only list those features which are natively supported
14658  by LyX.
14659  For detailed descriptions (and for the rest of features) we recommend you
14660  have a look at the detailed manual of the Memoir class
14661 \begin_inset Foot
14662 status collapsed
14663
14664 \begin_layout Plain Layout
14665 Cf.
14666 \begin_inset ERT
14667 status collapsed
14668
14669 \begin_layout Plain Layout
14670
14671
14672 \backslash
14673  
14674 \end_layout
14675
14676 \end_inset
14677
14678
14679 \begin_inset Flex URL
14680 status collapsed
14681
14682 \begin_layout Plain Layout
14683
14684 CTAN:/macros/latex/memoir/memman.pdf
14685 \end_layout
14686
14687 \end_inset
14688
14689 .
14690 \end_layout
14691
14692 \end_inset
14693
14694 , which is not only a user guide for the class, but also both a comprehensive
14695  description on good typesetting and a superb example for good typesetting
14696  itself.
14697 \end_layout
14698
14699 \begin_layout Subsection
14700 Basic features and restrictions
14701 \end_layout
14702
14703 \begin_layout Standard
14704 Memoir supports basically all features of the standard book classes.
14705  There are, however, some differences, as follows:
14706 \end_layout
14707
14708 \begin_layout Description
14709 Font
14710 \begin_inset space ~
14711 \end_inset
14712
14713 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
14714 \end_layout
14715
14716 \begin_layout Description
14717 Page
14718 \begin_inset space ~
14719 \end_inset
14720
14721 style: The fancy page style is not supported, due to a command clash between
14722  Memoir and the fancyhdr package (they both define a command with the same
14723  name, which confuses LaTeX).
14724  Instead, Memoir comes with a number of its own page styles (see 
14725 \family sans
14726 Layout\SpecialChar \menuseparator
14727 Document\SpecialChar \menuseparator
14728 Page
14729 \begin_inset space ~
14730 \end_inset
14731
14732 Style
14733 \family default
14734 ).
14735  If you want to use these for the chapter pages, you have to use the command
14736  
14737 \family typewriter
14738
14739 \backslash
14740 chapterstyle
14741 \family default
14742  in the main text or in preamble (e.
14743 \begin_inset space \thinspace{}
14744 \end_inset
14745
14746 g.
14747 \begin_inset space \space{}
14748 \end_inset
14749
14750
14751 \family typewriter
14752
14753 \backslash
14754 chapterstyle{companion}
14755 \family default
14756 ).
14757 \end_layout
14758
14759 \begin_layout Description
14760 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
14761  optional argument in the standard classes.
14762  With this, you can specify an alternative version of the title for the
14763  table of contents and the headers (for instance, if the title is too long).
14764  In LyX, you can do this via 
14765 \family sans
14766 Insert\SpecialChar \menuseparator
14767 Short
14768 \begin_inset space ~
14769 \end_inset
14770
14771 Title
14772 \family default
14773  at the beginning of a chapter/section.
14774  Memoir features a second optional argument and thus separates the table
14775  of contents from the header.
14776  You can define three variants of a title with this: one for the main text,
14777  one for the table of contents, and one for the headers.
14778  Simply insert two optional arguments if you need this feature, the first
14779  one containing the short title for the Table of Contents, the second one
14780  containing an alternative short title for the headers.
14781 \end_layout
14782
14783 \begin_layout Description
14784 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
14785  of contents, the list of figures and the list of table start a new page
14786  automatically.
14787  Memoir does not follow this route.
14788  You have to insert a page break yourself, if you want to have one.
14789 \end_layout
14790
14791 \begin_layout Description
14792 Titlepage: For some unknown reason, Memoir uses pagination on the title
14793  page (in the standard classes, title pages are 
14794 \begin_inset Quotes eld
14795 \end_inset
14796
14797 empty
14798 \begin_inset Quotes erd
14799 \end_inset
14800
14801 , i.
14802 \begin_inset space \thinspace{}
14803 \end_inset
14804
14805 g.
14806 \begin_inset space \space{}
14807 \end_inset
14808
14809 without pagina).
14810  If you want an empty title page, type 
14811 \family typewriter
14812
14813 \backslash
14814 aliaspagestyle{title}{empty}
14815 \family default
14816  in the preamble.
14817 \end_layout
14818
14819 \begin_layout Description
14820 Article: With the class option 
14821 \emph on
14822 article
14823 \emph default
14824  (to be inserted in 
14825 \family sans
14826 Layout\SpecialChar \menuseparator
14827 Document\SpecialChar \menuseparator
14828 Extra
14829 \begin_inset space ~
14830 \end_inset
14831
14832 Options
14833 \family default
14834 ), you can emulate article style.
14835  That is, counters (footnotes, figures, tables etc.) will not be reset on
14836  new chapters, chapters don't start a new page (but are—in contrary to 
14837 \begin_inset Quotes eld
14838 \end_inset
14839
14840 real
14841 \begin_inset Quotes erd
14842 \end_inset
14843
14844  article classes—still allowed), parts, though, use their own page, as in
14845  book.
14846 \end_layout
14847
14848 \begin_layout Description
14849 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
14850  font commands, which have been used in the old LaTeX version 2.09 (e.
14851 \begin_inset space \thinspace{}
14852 \end_inset
14853
14854 g.
14855 \begin_inset space \space{}
14856 \end_inset
14857
14858
14859 \family typewriter
14860
14861 \backslash
14862 rm
14863 \family default
14864
14865 \family typewriter
14866
14867 \backslash
14868 it
14869 \family default
14870 ).
14871  It produces an error and stops LaTeX whenever such a command appears.
14872  The class option 
14873 \emph on
14874 oldfontcommands
14875 \emph default
14876  reallows the commands and spits out warnings instead (which does at least
14877  not stop LaTeX).
14878  Since a lot of packages and particularly BibTeX style files are still using
14879  those commands, we have decided to use this option by default.
14880 \end_layout
14881
14882 \begin_layout Subsection
14883 Extra features
14884 \end_layout
14885
14886 \begin_layout Standard
14887 We will only describe the features supported by LyX (which is not much currently
14888 ).
14889  Please consult the Memoir manual
14890 \begin_inset Foot
14891 status collapsed
14892
14893 \begin_layout Plain Layout
14894 Cf.
14895 \begin_inset ERT
14896 status collapsed
14897
14898 \begin_layout Plain Layout
14899
14900
14901 \backslash
14902  
14903 \end_layout
14904
14905 \end_inset
14906
14907
14908 \begin_inset Flex URL
14909 status collapsed
14910
14911 \begin_layout Plain Layout
14912
14913 CTAN:/macros/latex/memoir/memman.pdf
14914 \end_layout
14915
14916 \end_inset
14917
14918 .
14919 \end_layout
14920
14921 \end_inset
14922
14923  for details.
14924 \end_layout
14925
14926 \begin_layout Description
14927 Abstract: You may wonder why an abstract is an extra feature.
14928  Well, it is in book class.
14929  Usually books don't have abstracts.
14930  Memoir, however, has.
14931  You can use it wherever and how often you like.
14932 \end_layout
14933
14934 \begin_layout Description
14935 Chapterprecis: You may know this older typesetting style: The contents of
14936  a chapter are summarized below the title and also in the table of contents
14937  (e.
14938 \begin_inset space \thinspace{}
14939 \end_inset
14940
14941 g.
14942 \begin_inset space \space{}
14943 \end_inset
14944
14945
14946 \emph on
14947 Our hero arrives in Troia; he loses some friends; he finds others
14948 \emph default
14949 ).
14950  Chapterprecis does exactly this.
14951  It is therefore only sensible below a chapter.
14952 \end_layout
14953
14954 \begin_layout Description
14955 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
14956  The epigraph environment provides an elegant way of typesetting such a
14957  motto.
14958  The motto itself (text) and its author (source) are divided by a short
14959  line.
14960  Unfortunately, we have to fool LyX a bit here again, since the environment
14961  needs two arguments (text and source).
14962  In this case, we have to use curly brackets (in TeX mode) between the two
14963  arguments: 
14964 \emph on
14965 <smart slogan>
14966 \emph default
14967  
14968 \family typewriter
14969 }{
14970 \family default
14971  
14972 \emph on
14973 <author of the slogan>.
14974 \end_layout
14975
14976 \begin_layout Description
14977 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
14978  complex figurative poems).
14979  LyX can only support a few of them.
14980  One is poemtitle, which is a centered title for poems, which will also
14981  be added to the table of contents (verse is the standard environment for
14982  poems.
14983  Memoir has some enhanced versions of verse, but you need to use TeX code,
14984  because they have to be nested inside regular verse environments, which
14985  is not possible with LyX).
14986 \end_layout
14987
14988 \begin_layout Description
14989 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
14990 \end_layout
14991
14992 \begin_layout Section
14993 Article (mwart), book (mwbk) and report (mwrep)
14994 \begin_inset Argument
14995 status collapsed
14996
14997 \begin_layout Plain Layout
14998 The 
14999 \family typewriter
15000 mw
15001 \family default
15002  Classes
15003 \end_layout
15004
15005 \end_inset
15006
15007
15008 \end_layout
15009
15010 \begin_layout Standard
15011 by 
15012 \noun on
15013 Tomasz Luczak
15014 \end_layout
15015
15016 \begin_layout Standard
15017 The LyX document classes 
15018 \emph on
15019 article (mwart)
15020 \emph default
15021
15022 \emph on
15023 report (mwrep)
15024 \emph default
15025  and 
15026 \emph on
15027 book
15028 \emph default
15029  
15030 \emph on
15031 (mwbk)
15032 \emph default
15033  correspond to the LaTeX document classes 
15034 \family typewriter
15035 mwart.cls
15036 \family default
15037
15038 \family typewriter
15039 mwrep.cls
15040 \family default
15041  and 
15042 \family typewriter
15043 mwbk.cls
15044 \family default
15045 , resp.
15046  They are replacements for the standard document classes 
15047 \family typewriter
15048 article.cls
15049 \family default
15050
15051 \family typewriter
15052 report.cls
15053 \family default
15054  and 
15055 \family typewriter
15056 book.cls
15057 \family default
15058 , resp., and fit better to Polish typography conventions in a number of points.
15059  
15060 \end_layout
15061
15062 \begin_layout Standard
15063 Basic differences:
15064 \end_layout
15065
15066 \begin_layout Itemize
15067 Unnumbered titles (with star, e.
15068 \begin_inset space \thinspace{}
15069 \end_inset
15070
15071 g.
15072 \begin_inset space \space{}
15073 \end_inset
15074
15075
15076 \family sans
15077 Section*
15078 \family default
15079 ) are added into table of contents,
15080 \end_layout
15081
15082 \begin_layout Itemize
15083 Additional page styles:
15084 \end_layout
15085
15086 \begin_deeper
15087 \begin_layout Description
15088 uheadings header with separated lines,
15089 \end_layout
15090
15091 \begin_layout Description
15092 myheadings custom header, contents headers via commands: 
15093 \family typewriter
15094
15095 \backslash
15096 markright
15097 \family default
15098  and 
15099 \family typewriter
15100
15101 \backslash
15102 markboth
15103 \family default
15104 ,
15105 \end_layout
15106
15107 \begin_layout Description
15108 myuheadings custom header with separated lines,
15109 \end_layout
15110
15111 \begin_layout Description
15112 outer page number is placed on outer side of page
15113 \end_layout
15114
15115 \end_deeper
15116 \begin_layout Itemize
15117 Options 
15118 \end_layout
15119
15120 \begin_deeper
15121 \begin_layout Description
15122 rmheadings serif titles — default,
15123 \end_layout
15124
15125 \begin_layout Description
15126 sfheadings sansserif titles,
15127 \end_layout
15128
15129 \begin_layout Description
15130 authortitle on title page first placed is author next title — default,
15131 \end_layout
15132
15133 \begin_layout Description
15134 titleauthor on title page first placed is title next author,
15135 \end_layout
15136
15137 \begin_layout Description
15138 withmarginpar reserve place on page for margins.
15139 \end_layout
15140
15141 \end_deeper
15142 \begin_layout Section
15143 Paper
15144 \end_layout
15145
15146 \begin_layout Standard
15147 The document class 
15148 \family sans
15149 paper
15150 \family default
15151  provides an alternative to the standard 
15152 \family sans
15153 article
15154 \family default
15155  class.
15156  It provides similar functionality, but you might prefer this layout with
15157  sans serif sections, headings, and more.
15158 \end_layout
15159
15160 \begin_layout Section
15161 RevTeX4
15162 \end_layout
15163
15164 \begin_layout Standard
15165 by 
15166 \noun on
15167 Amir Karger
15168 \end_layout
15169
15170 \begin_layout Standard
15171 \begin_inset VSpace bigskip
15172 \end_inset
15173
15174
15175 \end_layout
15176
15177 \begin_layout Standard
15178 \noindent
15179 The 
15180 \family sans
15181 Revtex
15182 \begin_inset space ~
15183 \end_inset
15184
15185 4
15186 \family default
15187  textclass works with the American Physical Sociey's RevTeX 4.0 (the 
15188 \begin_inset Formula $\beta$
15189 \end_inset
15190
15191  release of May, 1999) class.
15192 \end_layout
15193
15194 \begin_layout Standard
15195 LyX has a 
15196 \family sans
15197 Revtex
15198 \family default
15199  textclass, which works with RevTeX 3.1.
15200  However, v3.1 is basically obsolete, as it works with LaTeX 2.09.
15201  That means that it doesn't interact very well with LyX, which requires
15202  LaTeX2e, although it has been kludged to work.
15203  Since RevTeX 4.0 has been designed to work much more cleanly with LaTeX2e,
15204  LyX with the 
15205 \family sans
15206 RevTeX
15207 \begin_inset space ~
15208 \end_inset
15209
15210 4
15211 \family default
15212  textclass should also be pretty easy to use.
15213 \end_layout
15214
15215 \begin_layout Standard
15216 These documents are supposed to be used in 
15217 \emph on
15218 addition
15219 \emph default
15220  to the RevTeX 4.0 documents, so we don't describe any of the special RevTeX
15221  macros, and assume you'll know what to put in the preamble if necessary.
15222 \end_layout
15223
15224 \begin_layout Subsection
15225 Installation
15226 \end_layout
15227
15228 \begin_layout Standard
15229 All you need to do is install RevTeX 4, as described in the package's README
15230  file.
15231  The package can be found at The RevTeX 4 Web Site 
15232 \begin_inset Flex URL
15233 status collapsed
15234
15235 \begin_layout Plain Layout
15236
15237 http://publish.aps.org/revtex4/
15238 \end_layout
15239
15240 \end_inset
15241
15242 .
15243  Install it somewhere that LaTeX can see it.
15244  Test it by trying to LaTeX a short RevTeX 4 document in some random directory
15245  (i.
15246 \begin_inset space \thinspace{}
15247 \end_inset
15248
15249 g.
15250 \begin_inset space \space{}
15251 \end_inset
15252
15253 not the directory where you installed the class file.) Then, if you reconfigure
15254  LyX, it will find the class file and let you use the RevTeX4 textclass.
15255 \end_layout
15256
15257 \begin_layout Standard
15258 Probably the easiest way to get started is either to import a RevTeX 4 document
15259  using 
15260 \family typewriter
15261 tex2lyx
15262 \family default
15263 , or to use the 
15264 \family sans
15265 Revtex
15266 \begin_inset space ~
15267 \end_inset
15268
15269 4
15270 \family default
15271  template, found in the templates directory.
15272 \end_layout
15273
15274 \begin_layout Subsection
15275 Preamble Matter
15276 \end_layout
15277
15278 \begin_layout Standard
15279 Optional arguments to 
15280 \family typewriter
15281
15282 \backslash
15283 documentclass
15284 \family default
15285 , like 
15286 \begin_inset Quotes eld
15287 \end_inset
15288
15289 preprint
15290 \begin_inset Quotes erd
15291 \end_inset
15292
15293  and 
15294 \begin_inset Quotes eld
15295 \end_inset
15296
15297 aps
15298 \begin_inset Quotes erd
15299 \end_inset
15300
15301 , go in the 
15302 \family sans
15303 E
15304 \bar under
15305 x
15306 \bar default
15307 tra
15308 \begin_inset space ~
15309 \end_inset
15310
15311 Options
15312 \family default
15313  field in the 
15314 \family sans
15315 Document
15316 \begin_inset space ~
15317 \end_inset
15318
15319 Layout
15320 \family default
15321  dialog, as usual.
15322  Remember that in RevTeX, at least one optional argument is required! 
15323 \end_layout
15324
15325 \begin_layout Standard
15326 Other preamble matter, like 
15327 \family typewriter
15328
15329 \backslash
15330 draft
15331 \family default
15332  etc.
15333 \begin_inset space ~
15334 \end_inset
15335
15336 goes in the 
15337 \family sans
15338 LaTeX
15339 \begin_inset space ~
15340 \end_inset
15341
15342 Preamble
15343 \family default
15344  dialog, also as usual.
15345 \end_layout
15346
15347 \begin_layout Subsection
15348 Layouts
15349 \end_layout
15350
15351 \begin_layout Standard
15352 The layouts basically correspond to the commands in RevTeX4.0.
15353  For example, the Email layout corresponds to 
15354 \family typewriter
15355
15356 \backslash
15357 email{}
15358 \family default
15359 .
15360  Note that (at least as of RevTeX 4.0 Beta), the 
15361 \family sans
15362 Address
15363 \family default
15364  and 
15365 \family sans
15366 Affiliation
15367 \family default
15368  layouts are exactly equivalent, so you shouldn't need to use both.
15369 \begin_inset Foot
15370 status collapsed
15371
15372 \begin_layout Plain Layout
15373 In case you're curious, both were included so that 
15374 \family typewriter
15375 tex2lyx
15376 \family default
15377  would be able to translate both 
15378 \family typewriter
15379
15380 \backslash
15381 address
15382 \family default
15383  and 
15384 \family typewriter
15385
15386 \backslash
15387 affiliation
15388 \family default
15389 .
15390 \end_layout
15391
15392 \end_inset
15393
15394
15395 \end_layout
15396
15397 \begin_layout Subsection
15398 Important Notes
15399 \end_layout
15400
15401 \begin_layout Standard
15402 There are a couple of important unique aspects of RevTeX 4 which might cause
15403  bugs that will be even more confusing in LyX.
15404 \end_layout
15405
15406 \begin_layout Standard
15407 In RevTeX, the 
15408 \family typewriter
15409
15410 \backslash
15411 thanks
15412 \family default
15413  command goes 
15414 \emph on
15415 outside
15416 \emph default
15417  the 
15418 \family typewriter
15419
15420 \backslash
15421 author
15422 \family default
15423  command.
15424  The LyX equivalent is that there is a separate Thanks layout.
15425  Do 
15426 \emph on
15427 not
15428 \emph default
15429  write footnotes in the 
15430 \family sans
15431 Author
15432 \family default
15433  layout, or weird things may happen.
15434  See the RevTeX 4 documentation for more details.
15435 \end_layout
15436
15437 \begin_layout Standard
15438 Also, the 
15439 \family sans
15440 Author
15441 \begin_inset space ~
15442 \end_inset
15443
15444 Email
15445 \family default
15446
15447 \family sans
15448 Author
15449 \begin_inset space ~
15450 \end_inset
15451
15452 URL
15453 \family default
15454 , and 
15455 \family sans
15456 Thanks
15457 \family default
15458  layouts must be placed 
15459 \emph on
15460 in between
15461 \emph default
15462  the 
15463 \family sans
15464 Author
15465 \family default
15466  layout and the corresponding 
15467 \family sans
15468 Address
15469 \family default
15470  (or equivalent 
15471 \family sans
15472 Affiliation
15473 \family default
15474 ) layout.
15475  If you put the 
15476 \family sans
15477 Thanks
15478 \family default
15479  after the 
15480 \family sans
15481 Address
15482 \family default
15483 , the LaTeX won't compile.
15484 \end_layout
15485
15486 \begin_layout Subsection
15487 Drawbacks
15488 \end_layout
15489
15490 \begin_layout Standard
15491 The main problem with this layout is that you can't use the optional arguments
15492  to layouts like Email and Title.
15493  (The problem is not unique to this layout; you can't use optional arguments
15494  to the Section layouts either.) This means that after you export that file
15495  to LaTeX (which you'll need to do eventually to send it in to APS), you'll
15496  need to edit the LaTeX file with a text editor to add the optional arguments
15497  to set, e.
15498 \begin_inset space \thinspace{}
15499 \end_inset
15500
15501 g.
15502 \begin_inset space \space{}
15503 \end_inset
15504
15505 the running title for the page headers.
15506  Lacking these layouts makes the 
15507 \family typewriter
15508
15509 \backslash
15510 altaffiliation
15511 \family default
15512  (and the equivalent 
15513 \family typewriter
15514
15515 \backslash
15516 altaddress
15517 \family default
15518 ) useless, so the corresponding layouts don't exist, and will have to be
15519  added by hand.
15520 \begin_inset Foot
15521 status collapsed
15522
15523 \begin_layout Plain Layout
15524
15525 \emph on
15526 Note from JMarc:
15527 \emph default
15528  actually, LyX 1.3.0 supports some forms of optional arguments, but this layout
15529  has not been updated yet to take advantage of it.
15530 \end_layout
15531
15532 \end_inset
15533
15534  
15535 \end_layout
15536
15537 \begin_layout Section
15538 Springer Journals (
15539 \family sans
15540 svjour
15541 \family default
15542 )
15543 \end_layout
15544
15545 \begin_layout Standard
15546 by 
15547 \noun on
15548 Martin Vermeer
15549 \end_layout
15550
15551 \begin_layout Subsection
15552 Description
15553 \end_layout
15554
15555 \begin_layout Standard
15556 These are the layout files for some of the journal formats used by Springer
15557  Verlag and listed on 
15558 \begin_inset Flex URL
15559 status collapsed
15560
15561 \begin_layout Plain Layout
15562
15563 http://www.springer.de/author/tex/help-journals.html
15564 \end_layout
15565
15566 \end_inset
15567
15568 , where you should also go to fetch the class files (yes, these are LaTeX2e
15569  now!).
15570  It is a modular system: the things common to all journals are implemented
15571  in 
15572 \family typewriter
15573 svjour.inc
15574 \family default
15575 , which journal-specific layout files (such as, e.
15576 \begin_inset space \thinspace{}
15577 \end_inset
15578
15579 g.
15580 \begin_inset space \space{}
15581 \end_inset
15582
15583
15584 \family typewriter
15585 svjog.layout
15586 \family default
15587  for Journal of Geodesy) can include.
15588 \end_layout
15589
15590 \begin_layout Standard
15591 This means that implementing support for any other Springer journal on this
15592  list is as simple as writing your own 
15593 \family typewriter
15594 sv
15595 \family default
15596 <myjournal>
15597 \family typewriter
15598 .layout
15599 \family default
15600  file following the outline given in 
15601 \family typewriter
15602 svjog.layout
15603 \family default
15604 .
15605  
15606 \end_layout
15607
15608 \begin_layout Standard
15609 It is reasonably well tested only for the Journal of Geodesy.
15610  
15611 \family typewriter
15612 svjour
15613 \family default
15614  and 
15615 \family typewriter
15616 svjog
15617 \family default
15618  come with the standard LyX distribution.
15619  Install the relevant class file (downloaded from Springer) in a proper
15620  directory, reconfigure LaTeX (in the teTeX case by running 
15621 \family typewriter
15622 texhash
15623 \family default
15624 , as root if necessary — doesn't LyX take care of this?), reconfigure LyX
15625  and it should work.
15626 \end_layout
15627
15628 \begin_layout Subsection
15629 New styles
15630 \end_layout
15631
15632 \begin_layout Standard
15633 A large number of theorem-like styles — 
15634 \family sans
15635 Claim, Conjecture,
15636 \family default
15637  
15638 \family sans
15639 \SpecialChar \ldots{}
15640 Theorem
15641 \family default
15642 .
15643 \end_layout
15644
15645 \begin_layout Standard
15646
15647 \family sans
15648 Headnote, Dedication, Subtitle, Running_LaTeX_Title, Author_Running, Institute,
15649  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
15650 \family default
15651 .
15652  See the Springer class file documentation for details.
15653 \end_layout
15654
15655 \begin_layout Subsection
15656 Supported journals
15657 \end_layout
15658
15659 \begin_layout Itemize
15660
15661 \emph on
15662 Journal of Geodesy
15663 \emph default
15664
15665 \family typewriter
15666 svjog.layout
15667 \family default
15668  — Martin Vermeer
15669 \end_layout
15670
15671 \begin_layout Itemize
15672
15673 \emph on
15674 Probability Theory and Related Fields
15675 \emph default
15676
15677 \family typewriter
15678 svprobth.layout
15679 \family default
15680  — Jean-Marc Lasgouttes
15681 \end_layout
15682
15683 \begin_layout Standard
15684 Add your own, it isn't so hard!
15685 \end_layout
15686
15687 \begin_layout Subsection
15688 Credits
15689 \end_layout
15690
15691 \begin_layout Standard
15692 These files are partly based on the older 
15693 \family typewriter
15694 ejour2.layout
15695 \family default
15696 , which was again based on a tinkered-with version of an old LaTeX 2.09 style
15697  file from Springer.
15698  All this, and the 
15699 \family typewriter
15700 ejour2
15701 \family default
15702  layout, are now defunct.
15703  Jean-Marc Lasgouttes helped out big in making me find my way around the
15704  LyX layout file mechanism.
15705 \end_layout
15706
15707 \begin_layout Subsection
15708 Bugs
15709 \end_layout
15710
15711 \begin_layout Standard
15712 Probably.
15713  But probably less than in the old hacked-LaTeX 
15714 \family typewriter
15715 ejour2
15716 \family default
15717 .
15718 \end_layout
15719
15720 \begin_layout Standard
15721 Limitations e.
15722 \begin_inset space \thinspace{}
15723 \end_inset
15724
15725 g.: does not display the number for theorem-like layouts, just #.
15726 \end_layout
15727
15728 \begin_layout Section
15729 Slides [aka 
15730 \noun on
15731 SliTeX
15732 \noun default
15733 ]
15734 \begin_inset CommandInset label
15735 LatexCommand label
15736 name "sec:slitex"
15737
15738 \end_inset
15739
15740
15741 \end_layout
15742
15743 \begin_layout Standard
15744 by 
15745 \noun on
15746 John Weiss
15747 \noun default
15748  
15749 \end_layout
15750
15751 \begin_layout Subsection
15752 Introduction
15753 \end_layout
15754
15755 \begin_layout Standard
15756 This section describes how to use LyX to make slides for overhead projectors.
15757  There are two document classes that can do this: the default slides class
15758  and the 
15759 \family sans
15760 FoilTeX
15761 \family default
15762  slides class.
15763  This section documents the former.
15764 \end_layout
15765
15766 \begin_layout Standard
15767 I'm going to say this again, nice and clear, so that there's no misunderstanding
15768 :
15769 \end_layout
15770
15771 \begin_layout Standard
15772 \begin_inset VSpace bigskip
15773 \end_inset
15774
15775
15776 \end_layout
15777
15778 \begin_layout Standard
15779 \align center
15780
15781 \size large
15782 This section documents the class 
15783 \begin_inset Quotes eld
15784 \end_inset
15785
15786
15787 \family sans
15788 slides (default)
15789 \family default
15790
15791 \begin_inset Quotes erd
15792 \end_inset
15793
15794  
15795 \emph on
15796 only.
15797 \end_layout
15798
15799 \begin_layout Standard
15800 \begin_inset VSpace bigskip
15801 \end_inset
15802
15803
15804 \end_layout
15805
15806 \begin_layout Standard
15807 If you're looking for the documentation for 
15808 \begin_inset Quotes eld
15809 \end_inset
15810
15811
15812 \family sans
15813 slides (FoilTeX)
15814 \family default
15815
15816 \begin_inset Quotes erd
15817 \end_inset
15818
15819 , check out section
15820 \begin_inset space ~
15821 \end_inset
15822
15823
15824 \begin_inset CommandInset ref
15825 LatexCommand ref
15826 reference "sec:foiltex"
15827
15828 \end_inset
15829
15830 .
15831  The 
15832 \family sans
15833 foils
15834 \family default
15835  class [
15836 \begin_inset Quotes eld
15837 \end_inset
15838
15839
15840 \family sans
15841 slides (FoilTeX)
15842 \family default
15843
15844 \begin_inset Quotes erd
15845 \end_inset
15846
15847 ] is actually somewhat better than the default 
15848 \family sans
15849 slides
15850 \family default
15851  class,
15852 \begin_inset Foot
15853 status collapsed
15854
15855 \begin_layout Plain Layout
15856 \SpecialChar \ldots{}
15857 or so I've been told repeatedly by its advocates.
15858  Having never used it, I have no idea if this claim is true or not.
15859 \end_layout
15860
15861 \end_inset
15862
15863  which this section documents.
15864 \end_layout
15865
15866 \begin_layout Standard
15867 This class is the LaTeX2e improvement of the old 
15868 \noun on
15869 SliTeX
15870 \noun default
15871  package.
15872  Every LaTeX2e distribution includes this class [which I'll just refer to
15873  as 
15874 \begin_inset Quotes eld
15875 \end_inset
15876
15877
15878 \family sans
15879 slides
15880 \family default
15881
15882 \begin_inset Quotes erd
15883 \end_inset
15884
15885  from now on], so you're bound to have it.
15886  As I noted earlier, there are other classes, such as 
15887 \family sans
15888 foils
15889 \family default
15890 , which also produce slides for overhead projectors and do a better job
15891  at it.
15892  However, there are some things which 
15893 \family sans
15894 slides
15895 \family default
15896  can do which the others can't, such as generate overlays.
15897  Read on to learn more!
15898 \end_layout
15899
15900 \begin_layout Subsection
15901 Getting Started
15902 \begin_inset CommandInset label
15903 LatexCommand label
15904 name "sec:slidesetup"
15905
15906 \end_inset
15907
15908
15909 \end_layout
15910
15911 \begin_layout Standard
15912 Obviously, to use this document class, you need to select 
15913 \begin_inset Quotes eld
15914 \end_inset
15915
15916
15917 \family sans
15918 slides (default)
15919 \family default
15920
15921 \begin_inset Quotes erd
15922 \end_inset
15923
15924  from the class list in the 
15925 \family sans
15926 Document\SpecialChar \menuseparator
15927 Settings
15928 \family default
15929  dialog.
15930  There are some other special things you should know about this class:
15931 \end_layout
15932
15933 \begin_layout Itemize
15934 Don't bother changing the options 
15935 \family sans
15936 Sides and Columns
15937 \family default
15938 .
15939  They're not supported by the 
15940 \family sans
15941 slides
15942 \family default
15943  class, anyways.
15944 \end_layout
15945
15946 \begin_layout Itemize
15947 The option 
15948 \family sans
15949 Page
15950 \begin_inset space ~
15951 \end_inset
15952
15953 style
15954 \family default
15955  behaves a bit differently for this class.
15956  The possible choices and what they do are as follows:
15957 \end_layout
15958
15959 \begin_deeper
15960 \begin_layout Description
15961
15962 \family sans
15963 plain
15964 \family default
15965  The final output contains page numbers in the lower right corner.
15966 \end_layout
15967
15968 \begin_layout Description
15969
15970 \family sans
15971 headings
15972 \family default
15973  Like 
15974 \family sans
15975 plain
15976 \family default
15977 , but also prints out any time markers you've put in.
15978  This is the default.
15979 \end_layout
15980
15981 \begin_layout Description
15982
15983 \family sans
15984 empty
15985 \family default
15986  The final output contains no page numbers, time markers, or alignment markers.
15987 \end_layout
15988
15989 \end_deeper
15990 \begin_layout Itemize
15991 The 
15992 \family sans
15993 slides
15994 \family default
15995  class has an extra option: 
15996 \family typewriter
15997 clock
15998 \family default
15999 .
16000  To use it, put 
16001 \begin_inset Quotes eld
16002 \end_inset
16003
16004
16005 \family typewriter
16006 clock
16007 \family default
16008
16009 \begin_inset Quotes erd
16010 \end_inset
16011
16012  in the extra class options.
16013 \end_layout
16014
16015 \begin_deeper
16016 \begin_layout Standard
16017 Using this options allows you to add time markers to 
16018 \family sans
16019 Note
16020 \family default
16021 s.
16022  See section
16023 \begin_inset space ~
16024 \end_inset
16025
16026
16027 \begin_inset CommandInset ref
16028 LatexCommand ref
16029 reference "sec:slideNote"
16030
16031 \end_inset
16032
16033  for more details.
16034 \end_layout
16035
16036 \end_deeper
16037 \begin_layout Standard
16038 You can also use the template file 
16039 \begin_inset Quotes eld
16040 \end_inset
16041
16042
16043 \family typewriter
16044 slides.lyx
16045 \family default
16046
16047 \begin_inset Quotes erd
16048 \end_inset
16049
16050  to automatically set up a document to use the 
16051 \family sans
16052 slides
16053 \family default
16054  class [using 
16055 \family sans
16056 File\SpecialChar \menuseparator
16057 New
16058 \begin_inset space ~
16059 \end_inset
16060
16061 from
16062 \begin_inset space ~
16063 \end_inset
16064
16065 Template
16066 \family default
16067  to open your new document].
16068  The template file also contains some examples of the special paragraph
16069  environments used by this class.
16070  I'll describe those next.
16071 \end_layout
16072
16073 \begin_layout Subsection
16074 Paragraph Environments
16075 \end_layout
16076
16077 \begin_layout Subsubsection
16078 Supported Environments
16079 \end_layout
16080
16081 \begin_layout Standard
16082 The first thing you'll notice when you start up a new 
16083 \family sans
16084 slides
16085 \family default
16086  document is the font size and type: it's the equivalent of the size 
16087 \begin_inset Quotes eld
16088 \end_inset
16089
16090
16091 \family sans
16092 Largest
16093 \family default
16094
16095 \begin_inset Quotes erd
16096 \end_inset
16097
16098  in the 
16099 \family sans
16100 Sans
16101 \begin_inset space ~
16102 \end_inset
16103
16104 Serif
16105 \family default
16106  font.
16107  This is also what's used in the output.
16108  Think of this as a 
16109 \begin_inset Quotes eld
16110 \end_inset
16111
16112 visual cue
16113 \begin_inset Quotes erd
16114 \end_inset
16115
16116  to remind you that this is a slide.
16117  Your final slides will use a larger font; ergo, you'll have less space.
16118  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
16119 \end_layout
16120
16121 \begin_layout Standard
16122 The next thing that becomes obvious is the changes to the paragraph environment
16123  pull-down box [at the far-left end of the toolbar].
16124  Most of the paragraph environments you're used to seeing are missing.
16125  There are also five new ones.
16126  That's because the 
16127 \family sans
16128 slides
16129 \family default
16130  class itself only supports certain paragraph environments:
16131 \end_layout
16132
16133 \begin_layout Itemize
16134
16135 \family sans
16136 Standard
16137 \end_layout
16138
16139 \begin_layout Itemize
16140
16141 \family sans
16142 Itemize
16143 \end_layout
16144
16145 \begin_layout Itemize
16146
16147 \family sans
16148 Enumerate
16149 \end_layout
16150
16151 \begin_layout Itemize
16152
16153 \family sans
16154 Description
16155 \end_layout
16156
16157 \begin_layout Itemize
16158
16159 \family sans
16160 List
16161 \end_layout
16162
16163 \begin_layout Itemize
16164
16165 \family sans
16166 Quotation
16167 \end_layout
16168
16169 \begin_layout Itemize
16170
16171 \family sans
16172 Quote
16173 \end_layout
16174
16175 \begin_layout Itemize
16176
16177 \family sans
16178 Verse
16179 \end_layout
16180
16181 \begin_layout Itemize
16182
16183 \family sans
16184 Caption
16185 \end_layout
16186
16187 \begin_layout Itemize
16188
16189 \family sans
16190 LyX-Code
16191 \end_layout
16192
16193 \begin_layout Itemize
16194
16195 \family sans
16196 Comment
16197 \end_layout
16198
16199 \begin_layout Standard
16200 All of the other standard environments, including the section-heading environmen
16201 ts, aren't used in the 
16202 \family sans
16203 slides
16204 \family default
16205  class.
16206 \end_layout
16207
16208 \begin_layout Standard
16209 On the other hand, you'll notice the following new environments:
16210 \end_layout
16211
16212 \begin_layout Itemize
16213
16214 \family sans
16215 Slide
16216 \end_layout
16217
16218 \begin_layout Itemize
16219
16220 \family sans
16221 Overlay
16222 \end_layout
16223
16224 \begin_layout Itemize
16225
16226 \family sans
16227 Note
16228 \end_layout
16229
16230 \begin_layout Itemize
16231
16232 \family sans
16233 InvisibleText
16234 \end_layout
16235
16236 \begin_layout Itemize
16237
16238 \family sans
16239 VisibleText
16240 \end_layout
16241
16242 \begin_layout Standard
16243 These five are kind of quirky, due to a 
16244 \begin_inset Quotes eld
16245 \end_inset
16246
16247 feature
16248 \begin_inset Quotes erd
16249 \end_inset
16250
16251  in LyX.
16252  You see, LyX doesn't permit you to nest any other paragraph environment
16253  into an empty environment.
16254  Now, that's fine and dandy, but it means that you wouldn't be able to start
16255  a slide with anything except plain text.
16256  To deal with this, I've performed a little 
16257 \begin_inset Quotes eld
16258 \end_inset
16259
16260 LaTeX magic.
16261 \begin_inset Quotes erd
16262 \end_inset
16263
16264  
16265 \end_layout
16266
16267 \begin_layout Subsubsection
16268 Quirks of the New Environments
16269 \begin_inset CommandInset label
16270 LatexCommand label
16271 name "sec:slideQuirk"
16272
16273 \end_inset
16274
16275
16276 \end_layout
16277
16278 \begin_layout Standard
16279 All five of the new paragraph environments are somewhat quirky due to inherent
16280  limitiations in the current version of LyX.
16281  As I just mentioned, LyX forbids environments that begin with another environme
16282 nt.
16283  To get around this, the 
16284 \family sans
16285 Slide
16286 \family default
16287  environment isn't a paragraph environment as described in the 
16288 \emph on
16289 User's Guide
16290 \emph default
16291 .
16292  
16293 \end_layout
16294
16295 \begin_layout Standard
16296 You should consider 
16297 \family sans
16298 Slide
16299 \family default
16300
16301 \family sans
16302 Overlay
16303 \family default
16304 , and 
16305 \family sans
16306 Note
16307 \family default
16308  to be 
16309 \begin_inset Quotes eld
16310 \end_inset
16311
16312 pseudo-environments.
16313 \begin_inset Quotes erd
16314 \end_inset
16315
16316  They look like a section heading or a 
16317 \begin_inset Quotes eld
16318 \end_inset
16319
16320
16321 \family sans
16322 Caption
16323 \family default
16324 ,
16325 \begin_inset Quotes erd
16326 \end_inset
16327
16328  but really begin a [and, if necessary, end the previous] paragraph environment.
16329  Likewise, treat 
16330 \family sans
16331 InvisibleText
16332 \family default
16333  and 
16334 \family sans
16335 VisibleText
16336 \family default
16337  as 
16338 \begin_inset Quotes eld
16339 \end_inset
16340
16341 pseudo-commands.
16342 \begin_inset Quotes erd
16343 \end_inset
16344
16345  These two perform some action.
16346 \end_layout
16347
16348 \begin_layout Standard
16349 A common feature of all five environments, 
16350 \family sans
16351 Slide
16352 \family default
16353
16354 \family sans
16355 Overlay
16356 \family default
16357
16358 \family sans
16359 Note
16360 \family default
16361
16362 \family sans
16363 InvisibleText
16364 \family default
16365  and 
16366 \family sans
16367 VisibleText
16368 \family default
16369 , is a rather long-ish label.
16370  The text following this label — ordinarily the contents of the paragraph
16371  environment — is utterly irrelevant for 
16372 \family sans
16373 Slide
16374 \family default
16375
16376 \family sans
16377 Overlay
16378 \family default
16379
16380 \family sans
16381 Note
16382 \family default
16383
16384 \family sans
16385 InvisibleText
16386 \family default
16387  and 
16388 \family sans
16389 VisibleText
16390 \family default
16391 .
16392  LyX completely ignores it.
16393  In fact, you can leave these five environments completely empty.
16394  
16395 \end_layout
16396
16397 \begin_layout Standard
16398 While you don't 
16399 \emph on
16400 have
16401 \emph default
16402  to put any text after the rather long-ish label, you might want to.
16403  This could be a short description of the contents of the 
16404 \family sans
16405 Slide
16406 \family default
16407 , for example.
16408  In that case, enter your descriptive comment and hit 
16409 \family sans
16410 Return
16411 \family default
16412  as you normally would.
16413 \end_layout
16414
16415 \begin_layout Standard
16416 If, on the other hand, you don't want to enter any descriptive text, you'll
16417  hit another LyX quirk.
16418  LyX, like nature, abhors a vacuum, and will not let you start a new paragraph
16419  environment until you put something in the old one.
16420  So, do this:
16421 \end_layout
16422
16423 \begin_layout Itemize
16424 Start entering the text that will 
16425 \emph on
16426 follow
16427 \emph default
16428  the new 
16429 \family sans
16430 Slide
16431 \family default
16432
16433 \family sans
16434 Overlay
16435 \family default
16436
16437 \family sans
16438 Note
16439 \family default
16440
16441 \family sans
16442 InvisibleText
16443 \family default
16444  or 
16445 \family sans
16446 VisibleText
16447 \family default
16448 .
16449  
16450 \end_layout
16451
16452 \begin_layout Itemize
16453 Now move to the beginning of that paragraph.
16454  
16455 \end_layout
16456
16457 \begin_layout Itemize
16458 Next, hit 
16459 \family sans
16460 Return
16461 \family default
16462 .
16463  
16464 \end_layout
16465
16466 \begin_layout Itemize
16467 Finally, change this new, empty paragraph to a 
16468 \family sans
16469 Slide
16470 \family default
16471
16472 \family sans
16473 Overlay
16474 \family default
16475
16476 \family sans
16477 Note
16478 \family default
16479
16480 \family sans
16481 InvisibleText
16482 \family default
16483  or 
16484 \family sans
16485 VisibleText
16486 \family default
16487 .
16488  
16489 \end_layout
16490
16491 \begin_layout Standard
16492 Some future version of LyX will, hopefully, resolve this quirkiness\SpecialChar \ldots{}
16493
16494 \end_layout
16495
16496 \begin_layout Subsection
16497 Making a Presentation with 
16498 \family sans
16499 Slide
16500 \family default
16501
16502 \family sans
16503 Overlay
16504 \family default
16505  and 
16506 \family sans
16507 Note
16508 \end_layout
16509
16510 \begin_layout Subsubsection
16511 Using the 
16512 \family sans
16513 Slide
16514 \family default
16515  Environment
16516 \end_layout
16517
16518 \begin_layout Standard
16519 If you're expecting this section to teach you how to actually make a presentatio
16520 n, you'll be sorely disappointed.
16521  Naturally, I'll describe all of the ways the 
16522 \family sans
16523 slides
16524 \family default
16525  class can assist you in preparing the materials for a presentation.
16526  Filling in the contents, however, is up to you.
16527  [Then again, that 
16528 \emph on
16529 is
16530 \emph default
16531  the LyX philosophy.]
16532 \end_layout
16533
16534 \begin_layout Standard
16535 Choosing the 
16536 \family sans
16537 Slide
16538 \family default
16539  environment [in the manner described in section
16540 \begin_inset space ~
16541 \end_inset
16542
16543
16544 \begin_inset CommandInset ref
16545 LatexCommand ref
16546 reference "sec:slideQuirk"
16547
16548 \end_inset
16549
16550 ] tells LyX to begin a new slide [duh].
16551  The label for this environment/
16552 \begin_inset Quotes erd
16553 \end_inset
16554
16555 pseudo-command
16556 \begin_inset Quotes erd
16557 \end_inset
16558
16559  is an 
16560 \begin_inset Quotes eld
16561 \end_inset
16562
16563 ASCII line,
16564 \begin_inset Quotes erd
16565 \end_inset
16566
16567  in cool blue, followed by the label, 
16568 \begin_inset Quotes eld
16569 \end_inset
16570
16571 NewSlide:
16572 \begin_inset Quotes erd
16573 \end_inset
16574
16575 .
16576  Any text or paragraph environments that follow this one go on the new slide.
16577  It's that simple.
16578 \end_layout
16579
16580 \begin_layout Standard
16581 Slides are probably the only time you'll need to forcibly end pages in LyX
16582  (this can be specified in the 
16583 \family sans
16584 Paragraph Layout
16585 \family default
16586  dialog).
16587  In fact, you'll want to, once you finish entering the contents of one slide.
16588  If you've entered more text than can physically fit on a slide, the extra
16589  overflows onto a new slide.
16590  I don't recommend doing this, however, since the overflow slide won't have
16591  any page number on it.
16592  Furthermore, it may interfere with any 
16593 \family sans
16594 Overlay
16595 \family default
16596  you've made to accompany the oversized 
16597 \family sans
16598 Slide
16599 \family default
16600 .
16601 \end_layout
16602
16603 \begin_layout Standard
16604 The 
16605 \family sans
16606 Overlay
16607 \family default
16608  and 
16609 \family sans
16610 Note
16611 \family default
16612  environments work the same way as the 
16613 \family sans
16614 Slide
16615 \family default
16616  environment.
16617  They both create an 
16618 \begin_inset Quotes eld
16619 \end_inset
16620
16621 ASCII line
16622 \begin_inset Quotes erd
16623 \end_inset
16624
16625  followed by a label [
16626 \begin_inset Quotes eld
16627 \end_inset
16628
16629 NewOverlay:
16630 \begin_inset Quotes erd
16631 \end_inset
16632
16633  and 
16634 \begin_inset Quotes eld
16635 \end_inset
16636
16637 NewNote:
16638 \begin_inset Quotes erd
16639 \end_inset
16640
16641 , respectively].
16642  The color is a stunning magenta instead of blue, and the 
16643 \begin_inset Quotes eld
16644 \end_inset
16645
16646 ASCII line
16647 \begin_inset Quotes erd
16648 \end_inset
16649
16650  will look different, in style and in length.
16651  The label fonts of all three also differ from one another.
16652 \end_layout
16653
16654 \begin_layout Standard
16655 As with a 
16656 \family sans
16657 Slide
16658 \family default
16659 , if the contents of a 
16660 \family sans
16661 Note
16662 \family default
16663  or 
16664 \family sans
16665 Overlay
16666 \family default
16667  exceed the physical size of a slide or sheet of paper, the extra will overflow
16668  onto a new sheet.
16669  Again, you should avoid this.
16670  It defeats the whole purpose of 
16671 \family sans
16672 Note
16673 \family default
16674 s and 
16675 \family sans
16676 Overlay
16677 \family default
16678 s.
16679 \end_layout
16680
16681 \begin_layout Subsubsection
16682 Using 
16683 \family sans
16684 Overlay
16685 \family default
16686  with 
16687 \family sans
16688 Slide
16689 \end_layout
16690
16691 \begin_layout Standard
16692 The idea behind an 
16693 \family sans
16694 Overlay
16695 \family default
16696  is a slide that sits atop another slide.
16697  Perhaps you wish to discuss a figure on the main 
16698 \family sans
16699 Slide
16700 \family default
16701  before displaying the text associated with it.
16702  One way to accomplish this is tape a flap of dark paper over the part of
16703  the 
16704 \family sans
16705 Slide
16706 \family default
16707  you want to display later.
16708  This method fails, however, if you wish to overlap one graph with another,
16709  for example.
16710  You would then have to fumble while speaking to align the two separate,
16711  overlapping 
16712 \family sans
16713 Slide
16714 \family default
16715 s to align the two graphs.
16716  The use of an 
16717 \family sans
16718 Overlay
16719 \family default
16720  environment in both cases makes life much easier.
16721 \end_layout
16722
16723 \begin_layout Standard
16724 Each 
16725 \family sans
16726 Overlay
16727 \family default
16728  receives the page number of its 
16729 \begin_inset Quotes eld
16730 \end_inset
16731
16732 parent
16733 \begin_inset Quotes erd
16734 \end_inset
16735
16736  
16737 \family sans
16738 Slide
16739 \family default
16740 , appended by 
16741 \begin_inset Quotes eld
16742 \end_inset
16743
16744
16745 \family typewriter
16746 -a
16747 \family default
16748
16749 \begin_inset Quotes erd
16750 \end_inset
16751
16752 .
16753 \begin_inset Foot
16754 status collapsed
16755
16756 \begin_layout Plain Layout
16757 Presumably, mutliple 
16758 \family sans
16759 Overlay
16760 \family default
16761 s would have 
16762 \begin_inset Quotes eld
16763 \end_inset
16764
16765
16766 \family typewriter
16767 -a
16768 \family default
16769
16770 \begin_inset Quotes erd
16771 \end_inset
16772
16773
16774 \begin_inset Quotes eld
16775 \end_inset
16776
16777
16778 \family typewriter
16779 -b
16780 \family default
16781
16782 \begin_inset Quotes erd
16783 \end_inset
16784
16785
16786 \begin_inset Quotes eld
16787 \end_inset
16788
16789
16790 \family typewriter
16791 -c
16792 \family default
16793
16794 \begin_inset Quotes erd
16795 \end_inset
16796
16797 , etc.
16798 \begin_inset space ~
16799 \end_inset
16800
16801 appended to the page number of the parent 
16802 \family sans
16803 Slide
16804 \family default
16805 .
16806  
16807 \end_layout
16808
16809 \end_inset
16810
16811  Clearly, you want the contents of both the 
16812 \family sans
16813 Slide
16814 \family default
16815  and the 
16816 \family sans
16817 Overlay
16818 \family default
16819  to each fit on a single physical slide! You should probably consider an
16820  
16821 \family sans
16822 Overlay
16823 \family default
16824  as 
16825 \begin_inset Quotes eld
16826 \end_inset
16827
16828 part of
16829 \begin_inset Quotes erd
16830 \end_inset
16831
16832  a 
16833 \family sans
16834 Slide
16835 \family default
16836 .
16837  Indeed, the LyX 
16838 \family sans
16839 slides
16840 \family default
16841  class provides a visual cue for this: the label at the start of an 
16842 \family sans
16843 Overlay
16844 \family default
16845  is shorter than that at the start of a 
16846 \family sans
16847 Slide
16848 \family default
16849 .
16850  Lastly, when you generate printable output, you'll find alignment markers
16851  in all four corners of both the 
16852 \family sans
16853 Overlay
16854 \family default
16855  page and its parent 
16856 \family sans
16857 Slide
16858 \family default
16859 .
16860  These will assist you in lining up the two physical slides.
16861 \end_layout
16862
16863 \begin_layout Standard
16864 The major problem in overlaying two slides is aligning the contents of the
16865  two transparencies.
16866  How much space should you leave for that graph on the second slide? Worse
16867  still, what if you want a graph and a sentence on second slide, but there
16868  is text on the main transparency that goes in between them? You could try
16869  and insert vertical space of the right size.
16870  The better way is to use 
16871 \family sans
16872 InvisibleText
16873 \family default
16874  and 
16875 \family sans
16876 VisibleText
16877 \family default
16878 .
16879 \end_layout
16880
16881 \begin_layout Standard
16882 As their names imply, 
16883 \family sans
16884 InvisibleText
16885 \family default
16886  and 
16887 \family sans
16888 VisibleText
16889 \family default
16890  are two command-like paragraph environments that make all subsequent text
16891  invisible and visible, respectively.
16892  Note from section
16893 \begin_inset space ~
16894 \end_inset
16895
16896
16897 \begin_inset CommandInset ref
16898 LatexCommand ref
16899 reference "sec:slideQuirk"
16900
16901 \end_inset
16902
16903  that you don't place anything 
16904 \emph on
16905 into
16906 \emph default
16907  these two environments, however.
16908  When you create an 
16909 \family sans
16910 InvisibleText
16911 \family default
16912 , it inserts a centered, sky-blue label into the page reading 
16913 \begin_inset Quotes eld
16914 \end_inset
16915
16916 <Invisible Text Follows>
16917 \begin_inset Quotes erd
16918 \end_inset
16919
16920 .
16921  For paragraphs following this label, the parts of the 
16922 \family sans
16923 Slide
16924 \family default
16925  [or 
16926 \family sans
16927 Overlay
16928 \family default
16929 ; it doesn't matter which] where they would be contain instead blank space.
16930  
16931 \end_layout
16932
16933 \begin_layout Standard
16934 For 
16935 \family sans
16936 VisibleText
16937 \family default
16938 , the corresponding centered label is 
16939 \begin_inset Quotes eld
16940 \end_inset
16941
16942 <Visible Text Follows>
16943 \begin_inset Quotes erd
16944 \end_inset
16945
16946  in blazing green.
16947  Paragraphs following this label behave normally.
16948  Note that the beginning of a new 
16949 \family sans
16950 Slide
16951 \family default
16952
16953 \family sans
16954 Overlay
16955 \family default
16956 , or 
16957 \family sans
16958 Note
16959 \family default
16960  automatically shuts off an 
16961 \family sans
16962 InvisibleText
16963 \family default
16964 .
16965  It's therefore not necessary to use 
16966 \family sans
16967 VisibleText
16968 \family default
16969  at the end of a 
16970 \family sans
16971 Slide
16972 \family default
16973 .
16974 \end_layout
16975
16976 \begin_layout Standard
16977 By now, it should be obvious how to create overlay transparencies using
16978  the proper combination of 
16979 \family sans
16980 InvisibleText
16981 \family default
16982  and 
16983 \family sans
16984 VisibleText
16985 \family default
16986  on a 
16987 \family sans
16988 Slide
16989 \family default
16990  and 
16991 \family sans
16992 Overlay
16993 \family default
16994 :
16995 \end_layout
16996
16997 \begin_layout Enumerate
16998 Create a 
16999 \family sans
17000 Slide
17001 \family default
17002 , including everything that will appear on it, whether on the main slide
17003  or on the 
17004 \family sans
17005 Overlay
17006 \family default
17007 .
17008 \end_layout
17009
17010 \begin_layout Enumerate
17011 Before each figure or paragraph that will appear only on the 
17012 \family sans
17013 Overlay
17014 \family default
17015 , insert an 
17016 \family sans
17017 InvisibleText
17018 \family default
17019  environment.
17020  If necessary, insert a 
17021 \family sans
17022 VisibleText
17023 \family default
17024  environment after the 
17025 \family sans
17026 Overlay
17027 \family default
17028 -only text.
17029 \end_layout
17030
17031 \begin_layout Enumerate
17032 Start an 
17033 \family sans
17034 Overlay
17035 \family default
17036  immediately following the 
17037 \family sans
17038 Slide
17039 \family default
17040 .
17041 \end_layout
17042
17043 \begin_layout Enumerate
17044 Copy the contents of this 
17045 \family sans
17046 Slide
17047 \family default
17048  into the 
17049 \family sans
17050 Overlay
17051 \family default
17052 .
17053 \end_layout
17054
17055 \begin_layout Enumerate
17056 Within the 
17057 \family sans
17058 Overlay
17059 \family default
17060 , change all of the 
17061 \family sans
17062 InvisibleText
17063 \family default
17064  lines to 
17065 \family sans
17066 VisibleText
17067 \family default
17068  and vice-versa.
17069 \end_layout
17070
17071 \begin_layout Standard
17072 That's it.
17073  You've just made an 
17074 \family sans
17075 Overlay
17076 \family default
17077 .
17078 \end_layout
17079
17080 \begin_layout Standard
17081 There's one problem with the way I've designed the LyX 
17082 \family sans
17083 slides
17084 \family default
17085  class: you can't make text in the middle of a paragraph invisible, nor
17086  make text in the middle of an invisible paragraph visible again.
17087  To accomplish this feat, you'll need to use some inlined LaTeX codes.
17088 \begin_inset Foot
17089 status collapsed
17090
17091 \begin_layout Plain Layout
17092 The commands of interest are: 
17093 \end_layout
17094
17095 \begin_layout Itemize
17096
17097 \family typewriter
17098 {
17099 \backslash
17100 invisible \SpecialChar \ldots{}
17101  }
17102 \end_layout
17103
17104 \begin_layout Itemize
17105
17106 \family typewriter
17107 {
17108 \backslash
17109 visible \SpecialChar \ldots{}
17110  }
17111 \end_layout
17112
17113 \begin_layout Plain Layout
17114 \SpecialChar \ldots{}
17115 and need to be marked as TeX.
17116  The text whose 
17117 \begin_inset Quotes eld
17118 \end_inset
17119
17120 visibility
17121 \begin_inset Quotes erd
17122 \end_inset
17123
17124  you wish to change goes in between the brackets [and after the 
17125 \family typewriter
17126
17127 \backslash
17128 invisible
17129 \family default
17130  or 
17131 \family typewriter
17132
17133 \backslash
17134 visible
17135 \family default
17136  command].
17137  If you don't know how to mark text as TeX, see the appropriate section
17138  of the 
17139 \emph on
17140 User's Guide
17141 \emph default
17142 .
17143 \end_layout
17144
17145 \end_inset
17146
17147
17148 \end_layout
17149
17150 \begin_layout Subsubsection
17151 Using 
17152 \family sans
17153 Note
17154 \family default
17155  with 
17156 \family sans
17157 Slide
17158 \family default
17159
17160 \begin_inset CommandInset label
17161 LatexCommand label
17162 name "sec:slideNote"
17163
17164 \end_inset
17165
17166
17167 \end_layout
17168
17169 \begin_layout Standard
17170 Like an 
17171 \family sans
17172 Overlay
17173 \family default
17174 , a 
17175 \family sans
17176 Note
17177 \family default
17178  is associated with a 
17179 \begin_inset Quotes eld
17180 \end_inset
17181
17182 parent
17183 \begin_inset Quotes erd
17184 \end_inset
17185
17186  
17187 \family sans
17188 Slide
17189 \family default
17190 .
17191  Here, too, the LyX 
17192 \family sans
17193 slides
17194 \family default
17195  class provides visual cues.
17196  The label for a 
17197 \family sans
17198 Note
17199 \family default
17200  is shorter than that of a 
17201 \family sans
17202 Slide
17203 \family default
17204  [yet longer than that of an 
17205 \family sans
17206 Overlay
17207 \family default
17208 ] and, like the label of an 
17209 \family sans
17210 Overlay
17211 \family default
17212  is shockingly magenta.
17213  Additionally, the printed 
17214 \family sans
17215 Note
17216 \family default
17217  has the page number of its 
17218 \begin_inset Quotes eld
17219 \end_inset
17220
17221 parent
17222 \begin_inset Quotes erd
17223 \end_inset
17224
17225  
17226 \family sans
17227 Slide
17228 \family default
17229 , appended by 
17230 \begin_inset Quotes eld
17231 \end_inset
17232
17233
17234 \family typewriter
17235 -
17236 \family default
17237 1
17238 \begin_inset Quotes erd
17239 \end_inset
17240
17241
17242 \begin_inset Quotes eld
17243 \end_inset
17244
17245
17246 \family typewriter
17247 -
17248 \family default
17249 2
17250 \begin_inset Quotes erd
17251 \end_inset
17252
17253
17254 \begin_inset Quotes eld
17255 \end_inset
17256
17257
17258 \family typewriter
17259 -
17260 \family default
17261 3
17262 \begin_inset Quotes erd
17263 \end_inset
17264
17265 , etc.
17266  You can have multiple 
17267 \family sans
17268 Note
17269 \family default
17270 s associated with a single 
17271 \family sans
17272 Slide
17273 \family default
17274 , and, as with 
17275 \family sans
17276 Slide
17277 \family default
17278  and 
17279 \family sans
17280 Overlay
17281 \family default
17282 , you'll probably want to break up long 
17283 \family sans
17284 Note
17285 \family default
17286 s so that they fit on a single sheet of paper.
17287 \end_layout
17288
17289 \begin_layout Standard
17290 The purpose of a 
17291 \family sans
17292 Note
17293 \family default
17294  is obvious: it contains anything additional you might want to say about
17295  a 
17296 \family sans
17297 Slide
17298 \family default
17299 .
17300  It could also be used as a sheet of reminders for a particular 
17301 \family sans
17302 Slide
17303 \family default
17304 .
17305  In the case of the latter, you might want to make use of time markers.
17306  Currently, the LyX 
17307 \family sans
17308 slides
17309 \family default
17310  class has no 
17311 \begin_inset Quotes eld
17312 \end_inset
17313
17314 native
17315 \begin_inset Quotes erd
17316 \end_inset
17317
17318  support for time markers, a 
17319 \noun on
17320 SliTeX
17321 \noun default
17322  feature.
17323  So, you'll have to resort to using the LaTeX codes.
17324 \end_layout
17325
17326 \begin_layout Standard
17327 To use time markers, you'll need to specify the extra class option 
17328 \begin_inset Quotes eld
17329 \end_inset
17330
17331
17332 \family typewriter
17333 clock
17334 \family default
17335
17336 \begin_inset Quotes erd
17337 \end_inset
17338
17339  [see section
17340 \begin_inset space ~
17341 \end_inset
17342
17343
17344 \begin_inset CommandInset ref
17345 LatexCommand ref
17346 reference "sec:slidesetup"
17347
17348 \end_inset
17349
17350 ].
17351  This option turns on timing marks, which will appear in the lower-left-hand
17352  corner of every 
17353 \family sans
17354 Note
17355 \family default
17356  you generate.
17357  To set what appears in the time marker, you use the LaTeX commands 
17358 \begin_inset Quotes eld
17359 \end_inset
17360
17361
17362 \family typewriter
17363
17364 \backslash
17365 settime{}
17366 \family default
17367
17368 \begin_inset Quotes erd
17369 \end_inset
17370
17371  and 
17372 \begin_inset Quotes eld
17373 \end_inset
17374
17375
17376 \family typewriter
17377
17378 \backslash
17379 addtime{}
17380 \family default
17381
17382 \begin_inset Quotes erd
17383 \end_inset
17384
17385 .
17386  The arguments of both commands are time measured in seconds.
17387  
17388 \begin_inset Quotes eld
17389 \end_inset
17390
17391
17392 \family typewriter
17393
17394 \backslash
17395 settime{}
17396 \family default
17397
17398 \begin_inset Quotes erd
17399 \end_inset
17400
17401  sets the time marker to a given time.
17402  
17403 \begin_inset Quotes eld
17404 \end_inset
17405
17406
17407 \family typewriter
17408
17409 \backslash
17410 addtime{}
17411 \family default
17412
17413 \begin_inset Quotes erd
17414 \end_inset
17415
17416  increments the time marker by the specified amount.
17417  Using time markers and 
17418 \family sans
17419 Note
17420 \family default
17421 s in this fashion, you can remind yourself how much time to spend on a particula
17422
17423 \family sans
17424 Slide
17425 \family default
17426 .
17427 \end_layout
17428
17429 \begin_layout Standard
17430 There's one last feature to describe.
17431  Clearly, you'd like to print out all of your 
17432 \family sans
17433 Slide
17434 \family default
17435 s and 
17436 \family sans
17437 Overlay
17438 \family default
17439 s on transparencies while printing all of your 
17440 \family sans
17441 Note
17442 \family default
17443 s on plain paper.
17444  However, a 
17445 \family sans
17446 Note
17447 \family default
17448  
17449 \emph on
17450 must
17451 \emph default
17452  follow the 
17453 \family sans
17454 Slide
17455 \family default
17456  with which it is associated.
17457  What's a person to do?
17458 \end_layout
17459
17460 \begin_layout Standard
17461 Luckily, there are two LaTeX commands that allow you to select what to print
17462  out.
17463  Both must be placed into the preamble of your document.
17464  The command 
17465 \begin_inset Quotes eld
17466 \end_inset
17467
17468
17469 \family typewriter
17470
17471 \backslash
17472 onlyslides{
17473 \backslash
17474 slides}
17475 \family default
17476
17477 \begin_inset Quotes erd
17478 \end_inset
17479
17480  will cause the output to contain only the 
17481 \family sans
17482 Slide
17483 \family default
17484 s and 
17485 \family sans
17486 Overlay
17487 \family default
17488 s.
17489  Correspondingly, the command 
17490 \begin_inset Quotes eld
17491 \end_inset
17492
17493
17494 \family typewriter
17495
17496 \backslash
17497 onlynotes{
17498 \backslash
17499 notes}
17500 \family default
17501
17502 \begin_inset Quotes erd
17503 \end_inset
17504
17505  prevents the output of anything but 
17506 \family sans
17507 Note
17508 \family default
17509 s.
17510  I'd advise placing both commands in the preamble and initially comment
17511  both out.
17512  You can then preview your entire presentation as you write.
17513  When you're done writing, you can then uncomment one of the two to select
17514  what you want to print.
17515  I like to uncomment 
17516 \begin_inset Quotes eld
17517 \end_inset
17518
17519
17520 \family typewriter
17521
17522 \backslash
17523 onlyslides{
17524 \backslash
17525 slides}
17526 \family default
17527
17528 \begin_inset Quotes erd
17529 \end_inset
17530
17531  , print to a file with 
17532 \begin_inset Quotes eld
17533 \end_inset
17534
17535
17536 \family typewriter
17537 -slides
17538 \family default
17539
17540 \begin_inset Quotes erd
17541 \end_inset
17542
17543  in its name, comment it back out, then uncomment 
17544 \begin_inset Quotes eld
17545 \end_inset
17546
17547
17548 \family typewriter
17549
17550 \backslash
17551 onlynotes{
17552 \backslash
17553 notes}
17554 \family default
17555
17556 \begin_inset Quotes erd
17557 \end_inset
17558
17559  and print to a 
17560 \begin_inset Quotes eld
17561 \end_inset
17562
17563
17564 \family typewriter
17565 *-notes.ps
17566 \family default
17567
17568 \begin_inset Quotes erd
17569 \end_inset
17570
17571  file.
17572  I can then send either file to a printer, loading transparencies or plain
17573  paper as appropriate.
17574 \end_layout
17575
17576 \begin_layout Standard
17577 You can also provide other arguments to the 
17578 \begin_inset Quotes eld
17579 \end_inset
17580
17581
17582 \family typewriter
17583
17584 \backslash
17585 onlyslides{}
17586 \family default
17587
17588 \begin_inset Quotes erd
17589 \end_inset
17590
17591  and 
17592 \begin_inset Quotes eld
17593 \end_inset
17594
17595
17596 \family typewriter
17597
17598 \backslash
17599 onlynotes{}
17600 \family default
17601
17602 \begin_inset Quotes erd
17603 \end_inset
17604
17605  commands.
17606  See a good LaTeX book for details.
17607 \end_layout
17608
17609 \begin_layout Subsection
17610 The 
17611 \family sans
17612 slides
17613 \family default
17614  Class Template File
17615 \end_layout
17616
17617 \begin_layout Standard
17618 I have also provided a template file, 
17619 \begin_inset Quotes eld
17620 \end_inset
17621
17622
17623 \family typewriter
17624 slides.lyx
17625 \family default
17626
17627 \begin_inset Quotes erd
17628 \end_inset
17629
17630 , with the 
17631 \family sans
17632 slides
17633 \family default
17634  class.
17635  To use it, begin your new presentation with 
17636 \family sans
17637 \bar under
17638 F
17639 \bar default
17640 ile\SpecialChar \menuseparator
17641 New
17642 \begin_inset space ~
17643 \end_inset
17644
17645 from
17646 \begin_inset space ~
17647 \end_inset
17648
17649
17650 \bar under
17651 T
17652 \bar default
17653 emplate
17654 \family default
17655 .
17656  Your new LyX presentation file will contain an example 
17657 \family sans
17658 Slide
17659 \family default
17660  – 
17661 \family sans
17662 Overlay
17663 \family default
17664  – 
17665 \family sans
17666 Note
17667 \family default
17668  triplet.
17669  The 
17670 \family sans
17671 Slide
17672 \family default
17673  and 
17674 \family sans
17675 Overlay
17676 \family default
17677  additionally contain an example of the use of 
17678 \family sans
17679 InvisibleText
17680 \family default
17681  and 
17682 \family sans
17683 VisibleText
17684 \family default
17685 .
17686  Lastly, the preamble will contain:
17687 \end_layout
17688
17689 \begin_layout LyX-Code
17690 % Uncomment to print out only slides and overlays
17691 \end_layout
17692
17693 \begin_layout LyX-Code
17694 %
17695 \end_layout
17696
17697 \begin_layout LyX-Code
17698 %
17699 \backslash
17700 onlyslides{
17701 \backslash
17702 slides}
17703 \begin_inset Newline newline
17704 \end_inset
17705
17706  
17707 \end_layout
17708
17709 \begin_layout LyX-Code
17710 % Uncomment to print out only notes
17711 \end_layout
17712
17713 \begin_layout LyX-Code
17714 %
17715 \end_layout
17716
17717 \begin_layout LyX-Code
17718 %
17719 \backslash
17720 onlynotes{
17721 \backslash
17722 notes}
17723 \end_layout
17724
17725 \begin_layout Standard
17726 One final thing: I created this class to support the LaTeX2e 
17727 \begin_inset Quotes eld
17728 \end_inset
17729
17730
17731 \noun on
17732 SliTeX
17733 \noun default
17734  emulation
17735 \begin_inset Quotes erd
17736 \end_inset
17737
17738  class, one of the built-in LaTeX2e classes.
17739  Neither I nor the rest of the LyX Team endorse or oppose the use of this
17740  built-in slide class.
17741  It's here if you want it or need it.
17742  There exist other LaTeX2e classes for creating presentations, such as the
17743  
17744 \family sans
17745 Foils
17746 \family default
17747  class [see section
17748 \begin_inset space ~
17749 \end_inset
17750
17751
17752 \begin_inset CommandInset ref
17753 LatexCommand ref
17754 reference "sec:foiltex"
17755
17756 \end_inset
17757
17758 ] or the 
17759 \begin_inset Quotes eld
17760 \end_inset
17761
17762
17763 \family typewriter
17764 seminar
17765 \family default
17766
17767 \begin_inset Quotes erd
17768 \end_inset
17769
17770  package [present on some TeX distributions].
17771  The latter is not yet supported under LyX.
17772 \begin_inset Foot
17773 status collapsed
17774
17775 \begin_layout Plain Layout
17776 Perhaps you can take on the task\SpecialChar \ldots{}
17777
17778 \end_layout
17779
17780 \end_inset
17781
17782  I know nothing about these other classes.
17783  Try them out to see what sort of alternative they provide.
17784 \end_layout
17785
17786 \begin_layout Chapter
17787 LyX Features needing Extra Software
17788 \end_layout
17789
17790 \begin_layout Section
17791 Checking TeX
17792 \end_layout
17793
17794 \begin_layout Standard
17795 by 
17796 \noun on
17797 Asger Alstrup
17798 \end_layout
17799
17800 \begin_layout Subsection
17801 Introduction
17802 \end_layout
17803
17804 \begin_layout Standard
17805 If you have the 
17806 \family typewriter
17807 chktex
17808 \family default
17809  program installed
17810 \begin_inset Foot
17811 status collapsed
17812
17813 \begin_layout Plain Layout
17814
17815 \family typewriter
17816 chktex
17817 \family default
17818  is not yet available when you are using the LaTeX distribution MiKTeX.
17819 \end_layout
17820
17821 \end_inset
17822
17823 , you'll find in the 
17824 \family sans
17825 Tools
17826 \family default
17827  menu the entry: 
17828 \family sans
17829 Check
17830 \begin_inset space ~
17831 \end_inset
17832
17833 TeX
17834 \family default
17835 .
17836  You can get 
17837 \family typewriter
17838 chktex
17839 \family default
17840  it from CTAN, 
17841 \begin_inset CommandInset href
17842 LatexCommand href
17843 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
17844
17845 \end_inset
17846
17847 .
17848 \end_layout
17849
17850 \begin_layout Standard
17851 The 
17852 \family sans
17853 ChkTeX
17854 \family default
17855  package is a program that was written by 
17856 \begin_inset Flex Noun
17857 status collapsed
17858
17859 \begin_layout Plain Layout
17860 Jens T.
17861 \begin_inset space ~
17862 \end_inset
17863
17864 Berger Thielemann
17865 \end_layout
17866
17867 \end_inset
17868
17869  in frustration because some constructs in LaTeX are sometimes non-intuitive,
17870  and easy to forget.
17871  The program runs over your LaTeX file, checks the integrity of the file,
17872  and flags some common errors.
17873  In other technical words, it is 
17874 \family typewriter
17875 lint
17876 \family default
17877  for LaTeX.
17878 \end_layout
17879
17880 \begin_layout Standard
17881 Well, what is a syntax checker doing in LyX which is supposed to produce
17882  correct LaTeX anyways? The answer is simple: Just as 
17883 \family typewriter
17884 Lint
17885 \family default
17886  not only checks the 
17887 \emph on
17888 syntax
17889 \emph default
17890  of C programs, but also does 
17891 \emph on
17892 semantic
17893 \emph default
17894  checks for type-errors, 
17895 \family sans
17896 ChkTeX
17897 \family default
17898  catches some common 
17899 \emph on
17900 typographic
17901 \emph default
17902  errors, in addition to the syntactical ones.
17903  Specifically, 
17904 \family sans
17905 ChkTeX
17906 \family default
17907  is capable of detecting several common errors, such as
17908 \end_layout
17909
17910 \begin_layout Itemize
17911 Ellipsis detection:
17912 \begin_inset Newline newline
17913 \end_inset
17914
17915 Use \SpecialChar \ldots{}
17916  instead of ...
17917 \end_layout
17918
17919 \begin_layout Itemize
17920 No space in front of/after parenthesis:
17921 \begin_inset Newline newline
17922 \end_inset
17923
17924 ( wrong spacing )
17925 \end_layout
17926
17927 \begin_layout Itemize
17928 Enforcement of normal space after common abbreviations:
17929 \begin_inset Newline newline
17930 \end_inset
17931
17932 e.
17933 \begin_inset space \thinspace{}
17934 \end_inset
17935
17936 g.
17937 \begin_inset space \space{}
17938 \end_inset
17939
17940 is too wide spacing.
17941 \end_layout
17942
17943 \begin_layout Itemize
17944 Enforcement of end-of-sentence space when the last sentence ends with a
17945  capital letter:
17946 \begin_inset Newline newline
17947 \end_inset
17948
17949 This is a TEST.
17950  And this is wrong spacing.
17951 \end_layout
17952
17953 \begin_layout Itemize
17954 Space in front of labels and similar commands:
17955 \begin_inset Newline newline
17956 \end_inset
17957
17958 The label should stick right up to the text to avoid falling to a wrong
17959  page.
17960  
17961 \begin_inset CommandInset label
17962 LatexCommand label
17963 name "sec:chktex"
17964
17965 \end_inset
17966
17967  
17968 \begin_inset Foot
17969 status collapsed
17970
17971 \begin_layout Plain Layout
17972 This footnote is in danger of falling off to a wrong page
17973 \end_layout
17974
17975 \end_inset
17976
17977  The label is separated too much.
17978 \end_layout
17979
17980 \begin_layout Itemize
17981 Space in front of references, instead of hard spaces:
17982 \begin_inset Newline newline
17983 \end_inset
17984
17985 In you are in bad luck, the text will break right between the referenced
17986  text and reference number, and that's a pity.
17987  See section 
17988 \begin_inset CommandInset ref
17989 LatexCommand ref
17990 reference "sec:chktex"
17991
17992 \end_inset
17993
17994 .
17995 \end_layout
17996
17997 \begin_layout Itemize
17998 Use of 
17999 \begin_inset Quotes eld
18000 \end_inset
18001
18002 x
18003 \begin_inset Quotes erd
18004 \end_inset
18005
18006  instead of 
18007 \begin_inset Formula $\times$
18008 \end_inset
18009
18010  between numbers:
18011 \begin_inset Newline newline
18012 \end_inset
18013
18014 2x2 looks cheap compared to 
18015 \begin_inset Formula $2\times2$
18016 \end_inset
18017
18018 .
18019 \end_layout
18020
18021 \begin_layout Standard
18022 and more \SpecialChar \ldots{}
18023  It is an invaluable tool when you are 
18024 \begin_inset Quotes eld
18025 \end_inset
18026
18027 finishing up
18028 \begin_inset Quotes erd
18029 \end_inset
18030
18031  your document before printing, and you should run it right after the obligatory
18032  spelling check, and before you go fine tuning the typesetting.
18033 \end_layout
18034
18035 \begin_layout Subsection
18036 How to use it
18037 \end_layout
18038
18039 \begin_layout Standard
18040 If you have the program installed, usage is as simple as choosing 
18041 \family sans
18042 Tools\SpecialChar \menuseparator
18043 Check
18044 \begin_inset space ~
18045 \end_inset
18046
18047 TeX
18048 \family default
18049 .
18050  This will make LyX generate a LaTeX file of your document, start 
18051 \family sans
18052 ChkTeX
18053 \family default
18054  to check it, and then make LyX insert 
18055 \begin_inset Quotes eld
18056 \end_inset
18057
18058 error boxes
18059 \begin_inset Quotes erd
18060 \end_inset
18061
18062  with the warnings from 
18063 \family sans
18064 ChkTeX
18065 \family default
18066 , if there were any.
18067  The warnings will be placed close to the point of the mistake, and you
18068  can quickly find them by using the 
18069 \family sans
18070 Navigate\SpecialChar \menuseparator
18071 Error
18072 \family default
18073  menu item, or the shortcut key 
18074 \family sans
18075 C-g
18076 \family default
18077  from the default 
18078 \family typewriter
18079 cua
18080 \family default
18081  bind file.
18082  Open the error boxes by clicking on them with the mouse, or use the shortcut
18083  key 
18084 \family sans
18085 C-i
18086 \family default
18087  from 
18088 \family typewriter
18089 cua
18090 \family default
18091  bindings, or the corresponding 
18092 \family sans
18093 C-o
18094 \family default
18095  for the alternate 
18096 \family typewriter
18097 emacs
18098 \family default
18099  bind file.
18100  Read the warning and correct the mistake, if it is a mistake.
18101  If you have trouble understanding what the warning is about, you can safely
18102  ignore it.
18103  Remember that there is a hidden layer between the document on screen and
18104  the technical details in invoking 
18105 \family sans
18106 ChkTeX
18107 \family default
18108 , and this gap can make some warnings seem arcane or just right down plain
18109  silly.
18110 \end_layout
18111
18112 \begin_layout Standard
18113 This document is an excellent testing bed for the feature, and it should
18114  provide quite a few warnings for you to fiddle with.
18115  Since computers are only so smart, expect most of the warnings to be false
18116  alarms, though.
18117 \end_layout
18118
18119 \begin_layout Subsection
18120 How to fine tune it
18121 \end_layout
18122
18123 \begin_layout Standard
18124 Sometimes, you'll find that 
18125 \family sans
18126 ChkTeX
18127 \family default
18128  makes more noise than suits your mood.
18129  Then you can choose not to use it, wait until your mood changes, or try
18130  to customize 
18131 \family sans
18132 ChkTeX
18133 \family default
18134  to get better along with you.
18135 \end_layout
18136
18137 \begin_layout Standard
18138 Although 
18139 \family sans
18140 ChkTeX
18141 \family default
18142  
18143 \emph on
18144 is
18145 \emph default
18146  very configurable and extensible, you shouldn't expect to solve all problems
18147  with 
18148 \family sans
18149 ChkTeX
18150 \family default
18151  in LyX this way.
18152  Since LyX has to generate a somewhat special LaTeX file to be able to match
18153  the line numbers from the 
18154 \family sans
18155 ChkTeX
18156 \family default
18157  output
18158 \begin_inset Foot
18159 status collapsed
18160
18161 \begin_layout Plain Layout
18162 You can inspect the specific output from 
18163 \family sans
18164 chktex
18165 \family default
18166  by using 
18167 \family sans
18168 Edit\SpecialChar \menuseparator
18169 View
18170 \begin_inset space ~
18171 \end_inset
18172
18173 LaTeX
18174 \begin_inset space ~
18175 \end_inset
18176
18177 Log
18178 \family default
18179  right after a 
18180 \family sans
18181 chktex
18182 \family default
18183  run.
18184 \end_layout
18185
18186 \end_inset
18187
18188  to the internal document structure, some of the warnings will not seen
18189  to appear correctly.
18190  There are two things you can do about this:
18191 \end_layout
18192
18193 \begin_layout Itemize
18194 Fine tune the 
18195 \family sans
18196 ChkTeX
18197 \family default
18198  invocation command line in 
18199 \family sans
18200 Preferences
18201 \family default
18202  (tabs 
18203 \family sans
18204 Outputs
18205 \family default
18206
18207 \family sans
18208 Misc
18209 \family default
18210 ), or the global 
18211 \family sans
18212 ChkTeX
18213 \family default
18214  installation configuration file (usually with the file 
18215 \family typewriter
18216 chktexrc
18217 \family default
18218 ).
18219  See below to learn what warnings can be enabled and disabled on the command
18220  line.
18221  
18222 \end_layout
18223
18224 \begin_layout Itemize
18225 Export your document as a raw LaTeX file using 
18226 \family sans
18227 File\SpecialChar \menuseparator
18228 Export\SpecialChar \menuseparator
18229 LaTeX
18230 \family default
18231  and run 
18232 \family typewriter
18233 chktex
18234 \family default
18235  manually on that.
18236  Invoked in this way, it can be a hassle to find the corresponding place
18237  in the document inside LyX, but with a little patience, you should be able
18238  to do it.
18239 \end_layout
18240
18241 \begin_layout Standard
18242 Here follows the warning messages that can be enabled and disabled in 
18243 \family sans
18244 Preferences
18245 \family default
18246 .
18247  Use 
18248 \family typewriter
18249 -n#
18250 \family default
18251  to disable a warning, and 
18252 \family typewriter
18253 -w#
18254 \family default
18255  to enable a warning.
18256  The emphasized entries are disabled by default, because the default is
18257  "
18258 \family typewriter
18259 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
18260 \family default
18261 ".
18262 \end_layout
18263
18264 \begin_layout Standard
18265 Notice that you should only use the options that enable and disable warnings,
18266  because LyX relies on some of the other command line parameters to be set
18267  in a specific way to have a chance to communicate with 
18268 \family typewriter
18269 chktex
18270 \family default
18271 .
18272 \end_layout
18273
18274 \begin_layout Enumerate
18275
18276 \size small
18277 \emph on
18278 Command terminated with space.
18279 \end_layout
18280
18281 \begin_layout Enumerate
18282
18283 \size small
18284 Non-breaking space (
18285 \begin_inset Quotes eld
18286 \end_inset
18287
18288
18289 \family typewriter
18290 ~
18291 \family default
18292
18293 \begin_inset Quotes erd
18294 \end_inset
18295
18296 ) should have been used.
18297 \end_layout
18298
18299 \begin_layout Enumerate
18300
18301 \size small
18302 \emph on
18303 You should enclose the previous parenthesis with 
18304 \begin_inset Quotes eld
18305 \end_inset
18306
18307
18308 \family typewriter
18309 {}
18310 \family default
18311
18312 \begin_inset Quotes erd
18313 \end_inset
18314
18315 .
18316 \end_layout
18317
18318 \begin_layout Enumerate
18319
18320 \size small
18321 Italic correction (
18322 \begin_inset Quotes eld
18323 \end_inset
18324
18325
18326 \family typewriter
18327
18328 \backslash
18329 /
18330 \family default
18331
18332 \begin_inset Quotes erd
18333 \end_inset
18334
18335 ) found in non-italic buffer.
18336 \end_layout
18337
18338 \begin_layout Enumerate
18339
18340 \size small
18341 Italic correction (
18342 \begin_inset Quotes eld
18343 \end_inset
18344
18345
18346 \family typewriter
18347
18348 \backslash
18349 /
18350 \family default
18351
18352 \begin_inset Quotes erd
18353 \end_inset
18354
18355 ) found more than once.
18356 \end_layout
18357
18358 \begin_layout Enumerate
18359
18360 \size small
18361 \emph on
18362 No italic correction (
18363 \begin_inset Quotes eld
18364 \end_inset
18365
18366
18367 \family typewriter
18368
18369 \backslash
18370 /
18371 \family default
18372
18373 \begin_inset Quotes erd
18374 \end_inset
18375
18376 ) found.
18377 \end_layout
18378
18379 \begin_layout Enumerate
18380
18381 \size small
18382 Accent command 
18383 \begin_inset Quotes eld
18384 \end_inset
18385
18386
18387 \family typewriter
18388 cmd
18389 \family default
18390
18391 \begin_inset Quotes erd
18392 \end_inset
18393
18394  needs use of 
18395 \begin_inset Quotes eld
18396 \end_inset
18397
18398
18399 \family typewriter
18400 cmd
18401 \family default
18402
18403 \begin_inset Quotes erd
18404 \end_inset
18405
18406 .
18407 \end_layout
18408
18409 \begin_layout Enumerate
18410
18411 \size small
18412 Wrong length of dash may have been used.
18413 \end_layout
18414
18415 \begin_layout Enumerate
18416
18417 \size small
18418 \emph on
18419 \begin_inset Quotes eld
18420 \end_inset
18421
18422
18423 \family typewriter
18424 %s
18425 \family default
18426
18427 \begin_inset Quotes erd
18428 \end_inset
18429
18430  expected, found 
18431 \begin_inset Quotes eld
18432 \end_inset
18433
18434
18435 \family typewriter
18436 %s
18437 \family default
18438
18439 \begin_inset Quotes erd
18440 \end_inset
18441
18442 .
18443 \end_layout
18444
18445 \begin_layout Enumerate
18446
18447 \size small
18448 Solo 
18449 \begin_inset Quotes eld
18450 \end_inset
18451
18452
18453 \family typewriter
18454 %s
18455 \family default
18456
18457 \begin_inset Quotes erd
18458 \end_inset
18459
18460  found.
18461 \end_layout
18462
18463 \begin_layout Enumerate
18464
18465 \size small
18466 You should use 
18467 \begin_inset Quotes eld
18468 \end_inset
18469
18470
18471 \family typewriter
18472 %s
18473 \family default
18474
18475 \begin_inset Quotes erd
18476 \end_inset
18477
18478  to achieve an ellipsis.
18479 \end_layout
18480
18481 \begin_layout Enumerate
18482
18483 \size small
18484 Inter-word spacing (
18485 \begin_inset Quotes eld
18486 \end_inset
18487
18488
18489 \family typewriter
18490
18491 \backslash
18492
18493 \family default
18494  
18495 \begin_inset Quotes eld
18496 \end_inset
18497
18498 ) should perhaps be used.
18499 \end_layout
18500
18501 \begin_layout Enumerate
18502
18503 \size small
18504 Inter-sentence spacing (
18505 \begin_inset Quotes eld
18506 \end_inset
18507
18508
18509 \family typewriter
18510
18511 \backslash
18512 @
18513 \family default
18514
18515 \begin_inset Quotes erd
18516 \end_inset
18517
18518 ) should perhaps be used.
18519 \end_layout
18520
18521 \begin_layout Enumerate
18522
18523 \size small
18524 Could not find argument for command.
18525 \end_layout
18526
18527 \begin_layout Enumerate
18528
18529 \size small
18530 No match found for 
18531 \begin_inset Quotes eld
18532 \end_inset
18533
18534
18535 \family typewriter
18536 %s
18537 \family default
18538
18539 \begin_inset Quotes erd
18540 \end_inset
18541
18542 .
18543 \end_layout
18544
18545 \begin_layout Enumerate
18546
18547 \size small
18548 Math mode still on at end of LaTeX file.
18549 \end_layout
18550
18551 \begin_layout Enumerate
18552
18553 \size small
18554 Number of 
18555 \begin_inset Quotes eld
18556 \end_inset
18557
18558
18559 \family typewriter
18560 char
18561 \family default
18562
18563 \begin_inset Quotes erd
18564 \end_inset
18565
18566  doesn't match the number of 
18567 \begin_inset Quotes eld
18568 \end_inset
18569
18570
18571 \family typewriter
18572 char
18573 \family default
18574
18575 \begin_inset Quotes erd
18576 \end_inset
18577
18578 .
18579 \end_layout
18580
18581 \begin_layout Enumerate
18582
18583 \size small
18584 You should use either 
18585 \family typewriter
18586
18587 \begin_inset Quotes eld
18588 \end_inset
18589
18590
18591 \family default
18592  or 
18593 \family typewriter
18594
18595 \begin_inset Quotes erd
18596 \end_inset
18597
18598
18599 \family default
18600  as an alternative to 
18601 \begin_inset Quotes eld
18602 \end_inset
18603
18604
18605 \family typewriter
18606 "
18607 \family default
18608
18609 \begin_inset Quotes erd
18610 \end_inset
18611
18612 .
18613 \end_layout
18614
18615 \begin_layout Enumerate
18616
18617 \size small
18618 You should use "
18619 \family typewriter
18620 '
18621 \family default
18622 " (ASCII 39) instead of "
18623 \family typewriter
18624 ´
18625 \family default
18626 " (ASCII 180).
18627 \end_layout
18628
18629 \begin_layout Enumerate
18630
18631 \size small
18632 User-specified pattern found.
18633 \end_layout
18634
18635 \begin_layout Enumerate
18636
18637 \size small
18638 This command might not be intended.
18639 \end_layout
18640
18641 \begin_layout Enumerate
18642
18643 \size small
18644 \emph on
18645 Comment displayed.
18646 \end_layout
18647
18648 \begin_layout Enumerate
18649
18650 \size small
18651 Either 
18652 \family typewriter
18653 ''
18654 \backslash
18655 ,'
18656 \family default
18657  or 
18658 \family typewriter
18659 '
18660 \backslash
18661 ,''
18662 \family default
18663  will look better.
18664 \end_layout
18665
18666 \begin_layout Enumerate
18667
18668 \size small
18669 Delete this space to maintain correct page references.
18670 \end_layout
18671
18672 \begin_layout Enumerate
18673
18674 \size small
18675 \emph on
18676 You might wish to put this between a pair of 
18677 \begin_inset Quotes eld
18678 \end_inset
18679
18680
18681 \family typewriter
18682 {}
18683 \family default
18684
18685 \begin_inset Quotes erd
18686 \end_inset
18687
18688 .
18689 \end_layout
18690
18691 \begin_layout Enumerate
18692
18693 \size small
18694 You ought to remove spaces in front of punctuation.
18695 \end_layout
18696
18697 \begin_layout Enumerate
18698
18699 \size small
18700 Could not execute LaTeX command.
18701 \end_layout
18702
18703 \begin_layout Enumerate
18704
18705 \size small
18706 Don't use 
18707 \family typewriter
18708
18709 \backslash
18710 /
18711 \family default
18712  in front of small punctuation.
18713 \end_layout
18714
18715 \begin_layout Enumerate
18716
18717 \family typewriter
18718 \size small
18719 $
18720 \backslash
18721 times$
18722 \family default
18723  may look prettier here.
18724 \end_layout
18725
18726 \begin_layout Enumerate
18727
18728 \size small
18729 \emph on
18730 Multiple spaces detected in output.
18731 \end_layout
18732
18733 \begin_layout Enumerate
18734
18735 \size small
18736 This text may be ignored.
18737 \end_layout
18738
18739 \begin_layout Enumerate
18740
18741 \size small
18742 Use 
18743 \family typewriter
18744
18745 \begin_inset Quotes eld
18746 \end_inset
18747
18748
18749 \family default
18750  to begin quotation, not 
18751 \family typewriter
18752 '
18753 \family default
18754 .
18755 \end_layout
18756
18757 \begin_layout Enumerate
18758
18759 \size small
18760 Use 
18761 \family typewriter
18762 '
18763 \family default
18764  to end quotation, not 
18765 \family typewriter
18766
18767 \begin_inset Quotes eld
18768 \end_inset
18769
18770
18771 \family default
18772 .
18773 \end_layout
18774
18775 \begin_layout Enumerate
18776
18777 \size small
18778 Don't mix quotes.
18779 \end_layout
18780
18781 \begin_layout Enumerate
18782
18783 \size small
18784 You should perhaps use 
18785 \begin_inset Quotes eld
18786 \end_inset
18787
18788
18789 \family typewriter
18790 cmd
18791 \family default
18792
18793 \begin_inset Quotes erd
18794 \end_inset
18795
18796  instead.
18797 \end_layout
18798
18799 \begin_layout Enumerate
18800
18801 \size small
18802 You should put a space in front of/after parenthesis.
18803 \end_layout
18804
18805 \begin_layout Enumerate
18806
18807 \size small
18808 You should avoid spaces in front of/after parenthesis.
18809 \end_layout
18810
18811 \begin_layout Enumerate
18812
18813 \size small
18814 \emph on
18815 You should not use punctuation in front of/after quotes.
18816 \end_layout
18817
18818 \begin_layout Enumerate
18819
18820 \size small
18821 Double space found.
18822 \end_layout
18823
18824 \begin_layout Enumerate
18825
18826 \size small
18827 You should put punctuation outside inner/inside display math mode.
18828 \end_layout
18829
18830 \begin_layout Enumerate
18831
18832 \size small
18833 You ought to not use primitive TeX in LaTeX code.
18834 \end_layout
18835
18836 \begin_layout Enumerate
18837
18838 \size small
18839 You should remove spaces in front of 
18840 \begin_inset Quotes eld
18841 \end_inset
18842
18843
18844 \family typewriter
18845 %s
18846 \family default
18847
18848 \begin_inset Quotes erd
18849 \end_inset
18850
18851
18852 \end_layout
18853
18854 \begin_layout Enumerate
18855
18856 \size small
18857 \begin_inset Quotes eld
18858 \end_inset
18859
18860
18861 \family typewriter
18862 %s
18863 \family default
18864
18865 \begin_inset Quotes erd
18866 \end_inset
18867
18868  is normally not followed by 
18869 \begin_inset Quotes eld
18870 \end_inset
18871
18872
18873 \family typewriter
18874 %c
18875 \family default
18876
18877 \begin_inset Quotes erd
18878 \end_inset
18879
18880 .
18881 \end_layout
18882
18883 \begin_layout Standard
18884 In later versions of LyX, we hope to provide a more complete interface to
18885  this tool (and it's smaller cousin 
18886 \family typewriter
18887 lacheck
18888 \family default
18889 ) to exploit the full power of it.
18890  But it's not exactly useless as it is now: go try it on one of your existing
18891  documents of a certain length and be surprised.
18892 \end_layout
18893
18894 \begin_layout Section
18895 Version Control in LyX
18896 \end_layout
18897
18898 \begin_layout Standard
18899 by
18900 \noun on
18901  Lars Gullik Bjønnes 
18902 \noun default
18903 and 
18904 \noun on
18905 Pavel Sanda
18906 \end_layout
18907
18908 \begin_layout Subsection
18909 Introduction
18910 \end_layout
18911
18912 \begin_layout Standard
18913 A friend of mine wanted to try LyX for a group project.
18914  When he didn't find support for version control or file locking, he dropped
18915  it.
18916  This angered me a bit, so I thought that I should at least make support
18917  for RCS (with the possibility of CVS and/or SCCS as a future improvement.)
18918  This has been done.
18919  LyX now supports some of the most basic RCS/CVS/SVN commands.
18920  If you need something a bit more sophisticated you will have to do that
18921  manually in a terminal.
18922 \end_layout
18923
18924 \begin_layout Standard
18925 Also note that CVS support is not as good as subversion support so we advice
18926  using SVN instead.
18927  Good place to start with Subversion is SVN Book
18928 \begin_inset Foot
18929 status open
18930
18931 \begin_layout Plain Layout
18932 \begin_inset CommandInset href
18933 LatexCommand href
18934 target "http://svnbook.red-bean.com/"
18935
18936 \end_inset
18937
18938
18939 \end_layout
18940
18941 \end_inset
18942
18943 .
18944  In case of RCS you should read 
18945 \begin_inset Quotes eld
18946 \end_inset
18947
18948 rcsintro
18949 \begin_inset Quotes erd
18950 \end_inset
18951
18952  (a man file, read it with 
18953 \family typewriter
18954 man rcsintro
18955 \family default
18956 ).
18957  This file describes all the basic features of RCS.
18958  You should especially notice the comment about a RCS directory, and the
18959  notion of a master RCS file (the file ending in 
18960 \family typewriter
18961 ,v
18962 \family default
18963 ).
18964 \end_layout
18965
18966 \begin_layout Standard
18967 The implementation in LyX assumes a recent version of the GNU RCS or CVS/SVN
18968  package—no guarantees are made for older versions.
18969  Most of the log messages are not currently displayed after operations —
18970  you can check them in Messages pane if unsure.
18971 \end_layout
18972
18973 \begin_layout Standard
18974 For introducing your own external commands consult vc-command in the manual
18975  of LyX functions.
18976 \end_layout
18977
18978 \begin_layout Subsection
18979 RCS commands in LyX
18980 \end_layout
18981
18982 \begin_layout Standard
18983 The following sections describe the RCS commands supported by LyX.
18984  You can find them in the 
18985 \family sans
18986 File\SpecialChar \menuseparator
18987 Version
18988 \begin_inset space ~
18989 \end_inset
18990
18991 Control
18992 \family default
18993  submenu.
18994  LyX was tested against RCS 5.7.
18995 \end_layout
18996
18997 \begin_layout Subsubsection
18998
18999 \family sans
19000 Register
19001 \end_layout
19002
19003 \begin_layout Standard
19004 If your document is not under revision control, this is the only item shown
19005  in the menu.
19006  And if it is under revision control, the 
19007 \family sans
19008 Register
19009 \family default
19010  item is not visible.
19011  
19012 \end_layout
19013
19014 \begin_layout Standard
19015 This command registers your document with RCS (unless you are under the
19016  directory managed by CVS)\SpecialChar \@.
19017  You are asked interactively to supply an initial
19018  description of the document.
19019  The document is now set in Read-Only mode and you have to 
19020 \family sans
19021 Check
19022 \begin_inset space ~
19023 \end_inset
19024
19025 Out
19026 \begin_inset space ~
19027 \end_inset
19028
19029 For
19030 \begin_inset space ~
19031 \end_inset
19032
19033 Edit
19034 \family default
19035 , before making any changes to it.
19036  A document under revision control has a 
19037 \begin_inset Quotes eld
19038 \end_inset
19039
19040 [RCS:<version> <locker>]
19041 \begin_inset Quotes erd
19042 \end_inset
19043
19044  item tagged to the filename in the minibuffer.
19045 \end_layout
19046
19047 \begin_layout Standard
19048 RCS command that is run: 
19049 \family typewriter
19050 ci -q -u -i -t-"<initial description>" <file-name>
19051 \end_layout
19052
19053 \begin_layout Standard
19054 Read 
19055 \family typewriter
19056 man ci
19057 \family default
19058  to understand the switches.
19059  
19060 \end_layout
19061
19062 \begin_layout Subsubsection
19063
19064 \family sans
19065 Check In Changes
19066 \end_layout
19067
19068 \begin_layout Standard
19069 When you are finished editing a file, you check in your changes.
19070  When you do this, you are asked for a description of the changes.
19071  This is stored in the history log.
19072  The version number is bumped, your changes are applied to the master RCS
19073  file, the document is unlocked and set to Read-Only mode.
19074  
19075 \end_layout
19076
19077 \begin_layout Standard
19078 RCS command: 
19079 \family typewriter
19080 ci -q -u -m"<description>" <file-name>
19081 \end_layout
19082
19083 \begin_layout Subsubsection
19084
19085 \family sans
19086 Check Out For Edit
19087 \end_layout
19088
19089 \begin_layout Standard
19090 By doing this you lock the document so that only you can edit it.
19091  This will also make the document Read-Write only for you.
19092  You will usually continue editing for a while and when you are finished
19093  you check in your changes.
19094  The status line is changed to reflect that you have locked the file.
19095  
19096 \end_layout
19097
19098 \begin_layout Standard
19099 RCS command: 
19100 \family typewriter
19101 co -q -l <file-name>
19102 \end_layout
19103
19104 \begin_layout Subsubsection
19105
19106 \family sans
19107 Revert To Repository Version
19108 \end_layout
19109
19110 \begin_layout Standard
19111 This will discard all changes made to the document since the last check
19112  in.
19113  You get a warning before changes are discarded.
19114 \end_layout
19115
19116 \begin_layout Standard
19117 RCS command: 
19118 \family typewriter
19119 co -f -u<version> <file-name>
19120 \end_layout
19121
19122 \begin_layout Subsubsection
19123
19124 \family sans
19125 Undo Last Checkin
19126 \end_layout
19127
19128 \begin_layout Standard
19129 This makes as if the last check in never happened.
19130  No changes are made to the document loaded into LyX, but the last version
19131  is removed from the master RCS file.
19132  
19133 \end_layout
19134
19135 \begin_layout Standard
19136 RCS command: 
19137 \family typewriter
19138 rcs -o<version> <file-name>
19139 \end_layout
19140
19141 \begin_layout Subsubsection
19142
19143 \family sans
19144 Show History
19145 \end_layout
19146
19147 \begin_layout Standard
19148 This shows the complete history of the RCS document.
19149  The output of 
19150 \family typewriter
19151 rlog <file-name>
19152 \family default
19153  is shown in a browser.
19154  See 
19155 \family typewriter
19156 man rlog
19157 \family default
19158  for more info.
19159 \end_layout
19160
19161 \begin_layout Subsubsection
19162 Revision info
19163 \end_layout
19164
19165 \begin_layout Standard
19166 LyX supports RCS version number, author name, date and time of last commit.
19167  All those are extracted from 
19168 \family typewriter
19169 rlog -r <file-name>
19170 \family default
19171 .
19172  For other details see 
19173 \begin_inset CommandInset ref
19174 LatexCommand ref
19175 reference "sub:VCS-Revision-Information"
19176
19177 \end_inset
19178
19179  for details.
19180 \end_layout
19181
19182 \begin_layout Subsection
19183 CVS commands in LyX
19184 \end_layout
19185
19186 \begin_layout Standard
19187 A subset of CVS operations is supported by LyX.
19188  You can find the commands in the 
19189 \family sans
19190 File\SpecialChar \menuseparator
19191 Version
19192 \begin_inset space ~
19193 \end_inset
19194
19195 Control
19196 \family default
19197  submenu.
19198  The version control system SVN is more powerful, so please use it instead
19199  of CVS if possible.
19200 \end_layout
19201
19202 \begin_layout Subsubsection
19203
19204 \family sans
19205 General CVS usage
19206 \end_layout
19207
19208 \begin_layout Standard
19209 If you start from scratch with CVS you have to create your repository and
19210  checkout the working copy with external tools.
19211  If you're using a client-server setup you may need to login before doing
19212  the first repository checkout.
19213 \end_layout
19214
19215 \begin_layout Standard
19216 If your documents are under revision control and others are using the same
19217  repository problems arise when different changes to the same document at
19218  the same location happen.
19219  Standard CVS repositories doesn't operate with a file locking mechanism.
19220  This may be surprising, but conflicts only occur if people disagree on
19221  the proper content of the same part of a document.
19222  So, if co-workers are used to communicate regularly, these conflicts occur
19223  rarely.
19224  If they don't communicate they have a fundamental problem anyway.
19225  Nevertheless some people like to work with so called 
19226 \begin_inset Quotes eld
19227 \end_inset
19228
19229 reserved checkouts
19230 \begin_inset Quotes erd
19231 \end_inset
19232
19233 .
19234  If they do so the working copy of all files is readonly when checked out
19235  first and the user starts editing after using a special command to make
19236  the working copy writable.
19237  When the changes are checked in the working copy returns to readonly state.
19238  With LyX one has to edit the 
19239 \begin_inset Flex Code
19240 status collapsed
19241
19242 \begin_layout Plain Layout
19243 .cvsrc
19244 \end_layout
19245
19246 \end_inset
19247
19248  file and add the line 
19249 \begin_inset Flex Code
19250 status collapsed
19251
19252 \begin_layout Plain Layout
19253 cvs -r
19254 \end_layout
19255
19256 \end_inset
19257
19258  to work with reserved checkouts.
19259  The benefit is the possibility to see who is using a writable copy of some
19260  document.
19261  It's not guaranteed only one user makes a copy writable.
19262 \end_layout
19263
19264 \begin_layout Standard
19265 LyX tries to guess if you're using reserved or non-reserved checkouts.
19266  If your working copy is readonly or it is writable and an additional copy
19267  of your document exists in the CVS/Base sub-directory a reserved otherwise
19268  a non-reserved checkout is assumed.
19269  When a reserved checkout is detected you have to use 
19270 \begin_inset Flex MenuItem
19271 status collapsed
19272
19273 \begin_layout Plain Layout
19274 Check Out
19275 \end_layout
19276
19277 \end_inset
19278
19279  to make your working copy writable if it's readonly.
19280  After doing so the 
19281 \begin_inset Flex MenuItem
19282 status collapsed
19283
19284 \begin_layout Plain Layout
19285 Check In
19286 \end_layout
19287
19288 \end_inset
19289
19290  operation is possible and that makes your working copy readonly again after
19291  transferring your changes to the repository.
19292 \end_layout
19293
19294 \begin_layout Standard
19295 More information about CVS can be found here 
19296 \begin_inset Flex URL
19297 status collapsed
19298
19299 \begin_layout Plain Layout
19300
19301 http://www.nongnu.org/cvs
19302 \end_layout
19303
19304 \end_inset
19305
19306  and here 
19307 \begin_inset Flex URL
19308 status collapsed
19309
19310 \begin_layout Plain Layout
19311
19312 http://ximbiot.com/cvs
19313 \end_layout
19314
19315 \end_inset
19316
19317 .
19318 \end_layout
19319
19320 \begin_layout Standard
19321 Read 
19322 \family typewriter
19323 man cvs
19324 \family default
19325  to understand the sub-commands and the switches mentioned below.
19326 \end_layout
19327
19328 \begin_layout Subsubsection
19329
19330 \family sans
19331 Register
19332 \end_layout
19333
19334 \begin_layout Standard
19335 If your document is not under revision control, this is the only item shown
19336  in the menu.
19337  And if it is under revision control, the 
19338 \family sans
19339 \bar under
19340 R
19341 \bar default
19342 egister
19343 \family default
19344  item is not visible.
19345  
19346 \end_layout
19347
19348 \begin_layout Standard
19349 This command registers in CVS your document 
19350 \begin_inset Flex Strong
19351 status collapsed
19352
19353 \begin_layout Plain Layout
19354
19355 \emph on
19356 only
19357 \end_layout
19358
19359 \end_inset
19360
19361  in case you have already the documents directory under CVS control (in
19362  particular 
19363 \family typewriter
19364 CVS/Entries
19365 \family default
19366  file exists).
19367  This means you have to create or checkout the archive by yourself using
19368  external tools.
19369  (In case you forget that step LyX registers the document with RCS.)
19370 \end_layout
19371
19372 \begin_layout Standard
19373 Then you are asked interactively to supply an initial description of the
19374  document.
19375  Don't forget that registered file is not yet checked in.
19376 \end_layout
19377
19378 \begin_layout Standard
19379 CVS command that is run: 
19380 \family typewriter
19381 cvs -q add -m"<entered message>" "<file-name>"
19382 \end_layout
19383
19384 \begin_layout Standard
19385 The term 
19386 \family typewriter
19387 "<file-name>"
19388 \family default
19389  above and for all other CVS commands is an abbreviation for 
19390 \begin_inset Quotes eld
19391 \end_inset
19392
19393 change the current working directory to file location and use the file name
19394  without path component as argument
19395 \begin_inset Quotes erd
19396 \end_inset
19397
19398 .
19399 \end_layout
19400
19401 \begin_layout Subsubsection
19402
19403 \family sans
19404 Check In Changes
19405 \end_layout
19406
19407 \begin_layout Standard
19408 When you are finished editing a file, you commit your changes.
19409  When you do this and you had changed the document, you are asked for a
19410  description of the changes.
19411  After that changes are written to the repository.
19412  In case you didn't change the document and a reserved checkout is detected
19413  the reservation made on 
19414 \begin_inset Flex MenuItem
19415 status collapsed
19416
19417 \begin_layout Plain Layout
19418 Check Out
19419 \end_layout
19420
19421 \end_inset
19422
19423  is undone.
19424 \end_layout
19425
19426 \begin_layout Labeling
19427 \labelwidthstring 00.00.0000
19428 CVS
19429 \begin_inset space ~
19430 \end_inset
19431
19432 command: 
19433 \begin_inset space ~
19434 \end_inset
19435
19436
19437 \begin_inset Newline newline
19438 \end_inset
19439
19440
19441 \begin_inset Flex Code
19442 status collapsed
19443
19444 \begin_layout Plain Layout
19445 cvs 
19446 \family typewriter
19447 -q commit -m"<description>" "<file-name>"
19448 \end_layout
19449
19450 \end_inset
19451
19452  or
19453 \begin_inset Newline newline
19454 \end_inset
19455
19456
19457 \begin_inset Flex Code
19458 status collapsed
19459
19460 \begin_layout Plain Layout
19461 cvs -q unedit 
19462 \family typewriter
19463 "<file-name>"
19464 \end_layout
19465
19466 \end_inset
19467
19468
19469 \end_layout
19470
19471 \begin_layout Subsubsection
19472
19473 \family sans
19474 Check Out Changes
19475 \end_layout
19476
19477 \begin_layout Standard
19478 When you are sharing a repository with others, you may have to incorporate
19479  their changes into your working copy.
19480 \end_layout
19481
19482 \begin_layout Standard
19483 CVS command: 
19484 \family typewriter
19485 cvs -q update "<file-name>"
19486 \end_layout
19487
19488 \begin_layout Standard
19489 If a readonly checkout is detected the working copy is made writable and
19490  reserved.
19491 \end_layout
19492
19493 \begin_layout Standard
19494 CVS command: 
19495 \family typewriter
19496 cvs -q edit "<file-name>"
19497 \end_layout
19498
19499 \begin_layout Subsubsection
19500
19501 \family sans
19502 Revert To Repository Version
19503 \end_layout
19504
19505 \begin_layout Standard
19506 This will discard all changes made to the document since the last check
19507  in.
19508  You get a warning before changes are discarded.
19509  Firstly the file is deleted, secondly CVS update command is run.
19510 \end_layout
19511
19512 \begin_layout Standard
19513 CVS command: 
19514 \family typewriter
19515 cvs -q update "<file-name>"
19516 \end_layout
19517
19518 \begin_layout Standard
19519 If a reserved checkout is detected and the working copy has no changes only
19520  the reservation is undone.
19521 \end_layout
19522
19523 \begin_layout Standard
19524 CVS command: 
19525 \family typewriter
19526 cvs -q unedit "<file-name>"
19527 \end_layout
19528
19529 \begin_layout Subsubsection
19530 Update of the local directory checkout from repository
19531 \end_layout
19532
19533 \begin_layout Standard
19534 Once your documents gets more complex, containing sub-documents and pictures,
19535  including external 
19536 \begin_inset Flex Code
19537 status collapsed
19538
19539 \begin_layout Plain Layout
19540 .tex
19541 \end_layout
19542
19543 \end_inset
19544
19545  files and so on using version control becomes more complicated.
19546  LyX supports updating the whole tree in which resides the document.
19547  This become especially useful once you cooperate with people which neither
19548  have detailed knowledge about CVS usage nor they have ambition to commit
19549  additional material to the repository.
19550  You have to organize the files structure so that all external files are
19551  in the same directory or subdirectories of the document.
19552  It's good practice anyway to store multipart documents in an extra directory.
19553 \end_layout
19554
19555 \begin_layout Standard
19556 The 
19557 \begin_inset Flex Code
19558 status collapsed
19559
19560 \begin_layout Plain Layout
19561 Update local directory from repository
19562 \end_layout
19563
19564 \end_inset
19565
19566  command updates the whole directory.
19567  If local changes are detected user is warned before update starts.
19568  In case of merge conflicts both versions of the conflicting document parts
19569  are placed in the final document.
19570  You have to review and correct the result of the merge.
19571  You'll find the conflicts enclosed in pairs of 
19572 \begin_inset Flex Code
19573 status collapsed
19574
19575 \begin_layout Plain Layout
19576 <<<<<<<
19577 \end_layout
19578
19579 \end_inset
19580
19581  and 
19582 \begin_inset Flex Code
19583 status collapsed
19584
19585 \begin_layout Plain Layout
19586 >>>>>>>
19587 \end_layout
19588
19589 \end_inset
19590
19591  separated by 
19592 \begin_inset Flex Code
19593 status collapsed
19594
19595 \begin_layout Plain Layout
19596 =======
19597 \end_layout
19598
19599 \end_inset
19600
19601 .
19602  The first part is your version as before the update operation with the
19603  document name prepended.
19604  The second one is the repository version with the version number after
19605  the sequence of 
19606 \begin_inset Flex Code
19607 status collapsed
19608
19609 \begin_layout Plain Layout
19610 >
19611 \end_layout
19612
19613 \end_inset
19614
19615  signs.
19616 \end_layout
19617
19618 \begin_layout Labeling
19619 \labelwidthstring 00.00.0000
19620 CVS
19621 \begin_inset space ~
19622 \end_inset
19623
19624 commands: 
19625 \begin_inset space ~
19626 \end_inset
19627
19628
19629 \begin_inset Newline newline
19630 \end_inset
19631
19632
19633 \begin_inset Flex Code
19634 status collapsed
19635
19636 \begin_layout Plain Layout
19637 cd $path; cvs diff 
19638 \family typewriter
19639 "."
19640 \end_layout
19641
19642 \end_inset
19643
19644  (Ask if changes are detected.)
19645 \begin_inset Newline newline
19646 \end_inset
19647
19648
19649 \begin_inset Flex Code
19650 status collapsed
19651
19652 \begin_layout Plain Layout
19653 cd $path; cvs -q update 
19654 \family typewriter
19655 "."
19656 \end_layout
19657
19658 \end_inset
19659
19660
19661 \end_layout
19662
19663 \begin_layout Standard
19664 where 
19665 \begin_inset Flex Code
19666 status collapsed
19667
19668 \begin_layout Plain Layout
19669 $path
19670 \end_layout
19671
19672 \end_inset
19673
19674  stands for the path to the document.
19675 \end_layout
19676
19677 \begin_layout Subsubsection
19678
19679 \family sans
19680 Show History
19681 \end_layout
19682
19683 \begin_layout Standard
19684 This shows the complete history of the CVS document.
19685  The output of 
19686 \family typewriter
19687 cvs log "<file-name>"
19688 \family default
19689  is shown in a browser.
19690 \end_layout
19691
19692 \begin_layout Subsection
19693 SVN commands in LyX
19694 \end_layout
19695
19696 \begin_layout Standard
19697 SVN is now partially supported by LyX.
19698  You can find the commands in the 
19699 \family sans
19700 File\SpecialChar \menuseparator
19701 Version
19702 \begin_inset space ~
19703 \end_inset
19704
19705 Control
19706 \family default
19707  submenu.
19708  Please note that if you use password protected access to repository via
19709  ssh, you will be asked in terminal window.
19710  LyX was tested against SVN 1.5 and 1.6
19711 \begin_inset Foot
19712 status open
19713
19714 \begin_layout Plain Layout
19715 Most of the commands will work with 1.4 too, see 
19716 \begin_inset CommandInset ref
19717 LatexCommand ref
19718 reference "sub:SVN-Repo-Update"
19719
19720 \end_inset
19721
19722 .
19723 \end_layout
19724
19725 \end_inset
19726
19727
19728 \end_layout
19729
19730 \begin_layout Subsubsection
19731
19732 \family sans
19733 Register
19734 \end_layout
19735
19736 \begin_layout Standard
19737 If your document is not under revision control, this is the only item shown
19738  in the menu.
19739  And if it is under revision control, the 
19740 \family sans
19741 \bar under
19742 R
19743 \bar default
19744 egister
19745 \family default
19746  item is not visible.
19747  
19748 \end_layout
19749
19750 \begin_layout Standard
19751 This command registers in SVN your document ONLY in case you have already
19752  the documents directory under SVN control (in particular 
19753 \family typewriter
19754 .svn/entries
19755 \family default
19756  file exists).
19757  This means you have to checkout the archive by yourself.
19758  
19759 \end_layout
19760
19761 \begin_layout Standard
19762 Then you are asked interactively to supply an initial description of the
19763  document.
19764  Don't forget that registered file is not yet commited.
19765 \end_layout
19766
19767 \begin_layout Standard
19768 SVN command that is run: 
19769 \family typewriter
19770 svn add -q 
19771 \begin_inset Quotes eld
19772 \end_inset
19773
19774 <file-name>
19775 \begin_inset Quotes erd
19776 \end_inset
19777
19778
19779 \end_layout
19780
19781 \begin_layout Standard
19782 Read 
19783 \family typewriter
19784 man svn
19785 \family default
19786  to understand the switches.
19787  
19788 \end_layout
19789
19790 \begin_layout Subsubsection
19791
19792 \family sans
19793 Check In Changes
19794 \end_layout
19795
19796 \begin_layout Standard
19797 When you are finished editing a file, you commit your changes.
19798  When you do this, you are asked for a description of the changes.
19799  After that changes are commited.
19800 \end_layout
19801
19802 \begin_layout Standard
19803 SVN command:
19804 \begin_inset Foot
19805 status collapsed
19806
19807 \begin_layout Plain Layout
19808 In case locking is not enabled.
19809  See Section 
19810 \begin_inset CommandInset ref
19811 LatexCommand ref
19812 reference "subsec:SVN-File-Locking"
19813
19814 \end_inset
19815
19816 .
19817 \end_layout
19818
19819 \end_inset
19820
19821  
19822 \family typewriter
19823 svn commit -q -m"<description>" <file-name>
19824 \end_layout
19825
19826 \begin_layout Subsubsection
19827
19828 \family sans
19829 Check Out For Edit
19830 \end_layout
19831
19832 \begin_layout Standard
19833 Updates the changes of this file from the repository.
19834  Be sure you understand SVN merging and conflicts resolving before using
19835  this function, because all conflicts has to be resolved manually by you!
19836 \end_layout
19837
19838 \begin_layout Standard
19839 SVN command:
19840 \begin_inset Foot
19841 status collapsed
19842
19843 \begin_layout Plain Layout
19844 Ditto.
19845 \end_layout
19846
19847 \end_inset
19848
19849  
19850 \family typewriter
19851 svn update --non-interactive 
19852 \begin_inset Quotes eld
19853 \end_inset
19854
19855 <file-name>
19856 \begin_inset Quotes erd
19857 \end_inset
19858
19859
19860 \end_layout
19861
19862 \begin_layout Subsubsection
19863
19864 \family sans
19865 Revert To Repository Version
19866 \end_layout
19867
19868 \begin_layout Standard
19869 This will discard all changes made to the document since the last check
19870  in.
19871  You get a warning before changes are discarded.
19872  
19873 \end_layout
19874
19875 \begin_layout Standard
19876 SVN command: 
19877 \family typewriter
19878 svn revert -q 
19879 \begin_inset Quotes eld
19880 \end_inset
19881
19882 <file-name>
19883 \begin_inset Quotes erd
19884 \end_inset
19885
19886
19887 \end_layout
19888
19889 \begin_layout Subsubsection
19890 \begin_inset CommandInset label
19891 LatexCommand label
19892 name "sub:SVN-Repo-Update"
19893
19894 \end_inset
19895
19896 Update of the local directory checkout from repository
19897 \begin_inset Foot
19898 status collapsed
19899
19900 \begin_layout Plain Layout
19901 Note that this command will work only with subversion 
19902 \begin_inset Formula $\geqq1.5$
19903 \end_inset
19904
19905
19906 \end_layout
19907
19908 \end_inset
19909
19910
19911 \end_layout
19912
19913 \begin_layout Standard
19914 All the commands above have one shortcomming - they deal with the current
19915  document only.
19916  Once your document contains pictures, includes external 
19917 \begin_inset Flex Code
19918 status collapsed
19919
19920 \begin_layout Plain Layout
19921 .tex
19922 \end_layout
19923
19924 \end_inset
19925
19926  files and so on administration becomes more complicated.
19927  LyX now supports updating the whole tree in which resides the document
19928 \begin_inset Foot
19929 status collapsed
19930
19931 \begin_layout Plain Layout
19932 One need to organize the files structure so that all external files are
19933  in the same directory or subdirectories of the document.
19934  
19935 \end_layout
19936
19937 \end_inset
19938
19939 .
19940  This become especially useful once you cooperate with people which neither
19941  know about subversion management nor they have ambition to commit additional
19942  material to the repository.
19943  
19944 \end_layout
19945
19946 \begin_layout Standard
19947 \begin_inset Flex Code
19948 status collapsed
19949
19950 \begin_layout Plain Layout
19951 Update local directory from repository
19952 \end_layout
19953
19954 \end_inset
19955
19956  command updates the whole directory and in case of merge conflicts local
19957  version of the files are left, so no unintended data loss occurs.
19958  If local changes are detected user is warned before update starts.
19959 \end_layout
19960
19961 \begin_layout Labeling
19962 \labelwidthstring 00.00.0000
19963 SVN
19964 \begin_inset space ~
19965 \end_inset
19966
19967 commands: 
19968 \begin_inset space ~
19969 \end_inset
19970
19971
19972 \begin_inset Newline newline
19973 \end_inset
19974
19975
19976 \begin_inset Flex Code
19977 status collapsed
19978
19979 \begin_layout Plain Layout
19980 svn diff $path
19981 \end_layout
19982
19983 \end_inset
19984
19985  (Ask if changes are detected.)
19986 \begin_inset Newline newline
19987 \end_inset
19988
19989
19990 \begin_inset Flex Code
19991 status collapsed
19992
19993 \begin_layout Plain Layout
19994 svn update --accept mine-full $path
19995 \end_layout
19996
19997 \end_inset
19998
19999
20000 \end_layout
20001
20002 \begin_layout Standard
20003 where 
20004 \begin_inset Flex Code
20005 status collapsed
20006
20007 \begin_layout Plain Layout
20008 $path
20009 \end_layout
20010
20011 \end_inset
20012
20013  stands for the path to the document.
20014 \end_layout
20015
20016 \begin_layout Subsubsection
20017
20018 \family sans
20019 Show History
20020 \end_layout
20021
20022 \begin_layout Standard
20023 This shows the complete history of the SVN document.
20024  The output of 
20025 \family typewriter
20026 svn log 
20027 \begin_inset Quotes eld
20028 \end_inset
20029
20030 <file-name>
20031 \begin_inset Quotes erd
20032 \end_inset
20033
20034
20035 \family default
20036  is shown in a browser.
20037 \end_layout
20038
20039 \begin_layout Subsubsection
20040 File Locking
20041 \begin_inset CommandInset label
20042 LatexCommand label
20043 name "subsec:SVN-File-Locking"
20044
20045 \end_inset
20046
20047
20048 \end_layout
20049
20050 \begin_layout Standard
20051 The file exchange through various revision control systems brings the problem
20052  of merge conflicts in case two different users try to edit the same (parts
20053  of) document.
20054  When such a conflict happens it needs manual resolving and one reasonable
20055  alternative is to provide some kind of locking mechanism, which guarantees
20056  that only one user is allowed to edit file at the given time.
20057 \end_layout
20058
20059 \begin_layout Standard
20060 SVN has two such mechanisms to provide mutual exclusivity for file access
20061  - locks and automatic setting of write permissions (see sec.
20062  
20063 \begin_inset CommandInset ref
20064 LatexCommand ref
20065 reference "subsec:Automatical-Locking-Property"
20066
20067 \end_inset
20068
20069 ) based on 
20070 \begin_inset Flex Code
20071 status collapsed
20072
20073 \begin_layout Plain Layout
20074 svn:needs-lock
20075 \end_layout
20076
20077 \end_inset
20078
20079  file svn property
20080 \begin_inset Foot
20081 status open
20082
20083 \begin_layout Plain Layout
20084 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
20085 \end_layout
20086
20087 \end_inset
20088
20089 .
20090  If this property is detected for a given document LyX starts to use SVN
20091  locks for document editing automatically and the whole check-in/out mechanism
20092  switches to the same regimen as for RCS.
20093  This in particular means there are two different modes of file use in LyX:
20094 \end_layout
20095
20096 \begin_layout Itemize
20097 Unlocked state.
20098  The loaded file is in the read-only mode.
20099  For editing on needs to check-out.
20100  
20101 \emph on
20102 Check-out
20103 \emph default
20104  consists of updating from the repository and gaining write lock.
20105  If the lock is not possible to obtain, we remain in unlocked state.
20106 \end_layout
20107
20108 \begin_layout Itemize
20109 Locked state.
20110  The loaded file is in the 'normal' edit mode.
20111  No other user is allowed to edit the file.
20112  
20113 \emph on
20114 Check-in
20115 \emph default
20116  consists of commiting changes and releasing write-lock.
20117  If no changes have been made to the document, no commit will be produced
20118 \begin_inset Foot
20119 status collapsed
20120
20121 \begin_layout Plain Layout
20122 Don't be puzzled by the fact that you will be asked for commit message anyway.
20123 \end_layout
20124
20125 \end_inset
20126
20127  and only the write-lock will be released.
20128 \end_layout
20129
20130 \begin_layout Standard
20131 SVN commands:
20132 \end_layout
20133
20134 \begin_layout Labeling
20135 \labelwidthstring 00.00.0000
20136 Check-in:
20137 \family typewriter
20138  svn commit -q -m"<description>" "<file-name>"
20139 \begin_inset Newline newline
20140 \end_inset
20141
20142 svn unlock "<file-name>"
20143 \end_layout
20144
20145 \begin_layout Labeling
20146 \labelwidthstring 00.00.0000
20147 Check-out: 
20148 \family typewriter
20149 svn update "<file-name>"
20150 \begin_inset Newline newline
20151 \end_inset
20152
20153 svn lock "<file-name>"
20154 \end_layout
20155
20156 \begin_layout Subsubsection
20157
20158 \family typewriter
20159 \begin_inset CommandInset label
20160 LatexCommand label
20161 name "subsec:Automatical-Locking-Property"
20162
20163 \end_inset
20164
20165
20166 \family default
20167 Automatic Locking Property
20168 \end_layout
20169
20170 \begin_layout Standard
20171 The above mentioned automatic setting of write permissions of the .lyx file
20172  can be set through
20173 \family sans
20174 \bar under
20175  F
20176 \bar default
20177 ile\SpecialChar \menuseparator
20178
20179 \bar under
20180 V
20181 \bar default
20182 ersion
20183 \begin_inset space ~
20184 \end_inset
20185
20186 Control\SpecialChar \menuseparator
20187
20188 \bar under
20189 T
20190 \bar default
20191 oggle locking property
20192 \family default
20193 .
20194  This command is active only when the file is not locked on the svn server
20195  (i.e.
20196  you need to check-out before proceeding).
20197 \end_layout
20198
20199 \begin_layout Labeling
20200 \labelwidthstring 00.00.0000
20201 SVN
20202 \begin_inset space ~
20203 \end_inset
20204
20205 commands:
20206 \end_layout
20207
20208 \begin_layout Labeling
20209 \labelwidthstring 00.00.0000
20210 Set:
20211 \family typewriter
20212  svn propset svn:needs-lock ON "<file-name>"
20213 \end_layout
20214
20215 \begin_layout Labeling
20216 \labelwidthstring 00.00.0000
20217 Unset: 
20218 \family typewriter
20219 svn propdel svn:needs-lock "<file-name>"
20220 \end_layout
20221
20222 \begin_layout Subsubsection
20223 \begin_inset CommandInset label
20224 LatexCommand label
20225 name "sub:VCS-Revision-Information"
20226
20227 \end_inset
20228
20229 Revision Information in Documents
20230 \end_layout
20231
20232 \begin_layout Standard
20233 There are more possibilities how to activate revision information in our
20234  document.
20235 \end_layout
20236
20237 \begin_layout Itemize
20238 LyX supports directly:
20239 \end_layout
20240
20241 \begin_deeper
20242 \begin_layout Itemize
20243 tree revision information (
20244 \begin_inset Flex Code
20245 status collapsed
20246
20247 \begin_layout Plain Layout
20248 vcs-tree-revision
20249 \end_layout
20250
20251 \end_inset
20252
20253 ).
20254  The result is the output of the 
20255 \begin_inset Flex Code
20256 status collapsed
20257
20258 \begin_layout Plain Layout
20259 svnversion
20260 \end_layout
20261
20262 \end_inset
20263
20264  command, the following table gives you an idea, how to read the results.
20265 \end_layout
20266
20267 \begin_layout Standard
20268 \align center
20269 \begin_inset Tabular
20270 <lyxtabular version="3" rows="6" columns="2">
20271 <features tabularvalignment="middle">
20272 <column alignment="center" valignment="top" width="0">
20273 <column alignment="center" valignment="top" width="0">
20274 <row>
20275 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20276 \begin_inset Text
20277
20278 \begin_layout Plain Layout
20279 Output
20280 \end_layout
20281
20282 \end_inset
20283 </cell>
20284 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20285 \begin_inset Text
20286
20287 \begin_layout Plain Layout
20288 Meaning
20289 \end_layout
20290
20291 \end_inset
20292 </cell>
20293 </row>
20294 <row>
20295 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20296 \begin_inset Text
20297
20298 \begin_layout Plain Layout
20299 4123:4168
20300 \end_layout
20301
20302 \end_inset
20303 </cell>
20304 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20305 \begin_inset Text
20306
20307 \begin_layout Plain Layout
20308 mixed revision working copy
20309 \end_layout
20310
20311 \end_inset
20312 </cell>
20313 </row>
20314 <row>
20315 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20316 \begin_inset Text
20317
20318 \begin_layout Plain Layout
20319 4168M
20320 \end_layout
20321
20322 \end_inset
20323 </cell>
20324 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20325 \begin_inset Text
20326
20327 \begin_layout Plain Layout
20328 modified working copy
20329 \end_layout
20330
20331 \end_inset
20332 </cell>
20333 </row>
20334 <row>
20335 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20336 \begin_inset Text
20337
20338 \begin_layout Plain Layout
20339 4123S
20340 \end_layout
20341
20342 \end_inset
20343 </cell>
20344 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20345 \begin_inset Text
20346
20347 \begin_layout Plain Layout
20348 switched working copy
20349 \end_layout
20350
20351 \end_inset
20352 </cell>
20353 </row>
20354 <row>
20355 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20356 \begin_inset Text
20357
20358 \begin_layout Plain Layout
20359 4123P
20360 \end_layout
20361
20362 \end_inset
20363 </cell>
20364 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20365 \begin_inset Text
20366
20367 \begin_layout Plain Layout
20368 partial working copy, from a sparse checkout
20369 \end_layout
20370
20371 \end_inset
20372 </cell>
20373 </row>
20374 <row>
20375 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20376 \begin_inset Text
20377
20378 \begin_layout Plain Layout
20379 4123:4168MS
20380 \end_layout
20381
20382 \end_inset
20383 </cell>
20384 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20385 \begin_inset Text
20386
20387 \begin_layout Plain Layout
20388 mixed revision, modified, switched working copy
20389 \end_layout
20390
20391 \end_inset
20392 </cell>
20393 </row>
20394 </lyxtabular>
20395
20396 \end_inset
20397
20398
20399 \end_layout
20400
20401 \begin_layout Itemize
20402 file revision information.
20403  The result comes from parsing the output of 
20404 \begin_inset Flex Code
20405 status collapsed
20406
20407 \begin_layout Plain Layout
20408 svn
20409 \begin_inset space ~
20410 \end_inset
20411
20412 info
20413 \begin_inset space ~
20414 \end_inset
20415
20416 --xml
20417 \begin_inset space ~
20418 \end_inset
20419
20420 file.lyx
20421 \end_layout
20422
20423 \end_inset
20424
20425 .
20426  Supported flags are:
20427 \end_layout
20428
20429 \begin_deeper
20430 \begin_layout Itemize
20431 version number of the last commit (
20432 \begin_inset Flex Code
20433 status collapsed
20434
20435 \begin_layout Plain Layout
20436 vcs-revision
20437 \end_layout
20438
20439 \end_inset
20440
20441 )
20442 \end_layout
20443
20444 \begin_layout Itemize
20445 author of the last commit (
20446 \begin_inset Flex Code
20447 status collapsed
20448
20449 \begin_layout Plain Layout
20450 vcs-author
20451 \end_layout
20452
20453 \end_inset
20454
20455 )
20456 \end_layout
20457
20458 \begin_layout Itemize
20459 date of the last commit (
20460 \begin_inset Flex Code
20461 status collapsed
20462
20463 \begin_layout Plain Layout
20464 vcs-date
20465 \end_layout
20466
20467 \end_inset
20468
20469 )
20470 \end_layout
20471
20472 \begin_layout Itemize
20473 time of the last commit (
20474 \begin_inset Flex Code
20475 status collapsed
20476
20477 \begin_layout Plain Layout
20478 vcs-time
20479 \end_layout
20480
20481 \end_inset
20482
20483 )
20484 \end_layout
20485
20486 \end_deeper
20487 \begin_layout Standard
20488 You can obtain this info via InsetInfo (e.g.
20489  
20490 \begin_inset Flex Code
20491 status collapsed
20492
20493 \begin_layout Plain Layout
20494 info-insert buffer vcs-date
20495 \end_layout
20496
20497 \end_inset
20498
20499 ).
20500  The information will be available only when you have the file stored under
20501  svn managment (i.e.
20502  the 
20503 \begin_inset Flex Code
20504 status collapsed
20505
20506 \begin_layout Plain Layout
20507 .svn
20508 \end_layout
20509
20510 \end_inset
20511
20512  directory is available with your document).
20513 \end_layout
20514
20515 \end_deeper
20516 \begin_layout Itemize
20517 Another---a hacking one---possibility is to use svn keywords
20518 \begin_inset Foot
20519 status collapsed
20520
20521 \begin_layout Plain Layout
20522 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
20523 \end_layout
20524
20525 \end_inset
20526
20527 .
20528  In short -- you set file keywords property (e.g.
20529  
20530 \family sans
20531 svn propset svn:keywords 'Rev' file.lyx
20532 \family default
20533 ) and then paste keyword TeX code
20534 \begin_inset Foot
20535 status collapsed
20536
20537 \begin_layout Plain Layout
20538 This is an easy way how to ensure that LyX won't break the line in the middle
20539  of keyword tag.
20540 \end_layout
20541
20542 \end_inset
20543
20544  tag in your document (e.g.
20545  
20546 \begin_inset ERT
20547 status open
20548
20549 \begin_layout Plain Layout
20550
20551 $Rev$
20552 \end_layout
20553
20554 \end_inset
20555
20556 ).
20557  This way svn client will automatically substitute revision number (e.g.
20558  
20559 \begin_inset ERT
20560 status open
20561
20562 \begin_layout Plain Layout
20563
20564 $Rev: 59 $
20565 \end_layout
20566
20567 \end_inset
20568
20569 ) after each update and commit.
20570  There are more problems with this approach.
20571  Firstly, the '$' character is used in TeX world for math equations, so
20572  any occurence of math formula 
20573 \begin_inset Formula $Rev$
20574 \end_inset
20575
20576  become 
20577 \begin_inset Formula $Rev:59$
20578 \end_inset
20579
20580  in your LyX document.
20581  Similarly for other keywords like Id, Date, Author, etc.
20582  Secondly svn output is dependent on your locales, so its very easy that
20583  svn would produce some problematic strings once Date is used.
20584  Thirdly you get the whole 'Rev: 59' string in your document instead of
20585  the plain number.
20586  Until subversion implements user's custom keywords it will be hard to use
20587  this approach reliably or let LyX to support it directly.
20588 \end_layout
20589
20590 \begin_layout Subsection
20591 SVN and Windows Environment
20592 \end_layout
20593
20594 \begin_layout Quote
20595 My inclination is to say that if the user cannot figure out the command
20596  line operations on their own fairly quickly, they would be well advised
20597  to use TortoiseSVN.
20598  ---P.
20599  A.
20600  Rubin
20601 \end_layout
20602
20603 \begin_layout Subsubsection
20604 Preparation
20605 \end_layout
20606
20607 \begin_layout Standard
20608 In addition to installing LyX, and having access to a Subversion repository,
20609  the user will need to install the Subversion client program.
20610  A Windows installer for the client program is available from 
20611 \begin_inset CommandInset href
20612 LatexCommand href
20613 name "CollabNet"
20614 target "http://www.collab.net/nonav/downloads/subversion/"
20615
20616 \end_inset
20617
20618 .
20619  The user may also want to install 
20620 \begin_inset CommandInset href
20621 LatexCommand href
20622 name "TortoiseSVN"
20623 target "http://tortoisesvn.tigris.org/"
20624
20625 \end_inset
20626
20627 , which integrates Subversion operations into the context (rightclick) menu
20628  of Windows Explorer.
20629  Operations done outside LyX will typically be more convenient using the
20630  Explorer context menu.
20631  Note that TortoiseSVN is not a replacement for the client program, which
20632  is what LyX itself will use.
20633 \end_layout
20634
20635 \begin_layout Subsubsection
20636 Bringing a document under Subversion control
20637 \end_layout
20638
20639 \begin_layout Standard
20640 Before a LyX document can be brought under version control in Subversion,
20641  its parent directory needs to be under version control.
20642  If the document is being added to a project already in the repository,
20643  this is accomplished by checking the project out to the directory where
20644  the new document will be placed.
20645  If the project itself is not yet under version control (for instance, if
20646  this document starts a new project), the directory must be imported into
20647  the repository.
20648  This is done outside LyX.
20649  Both import and checkout are easily accomplished from the Explorer context
20650  menu using TortoiseSVN, or alternatively can be done using the command
20651  line client at a DOS prompt.
20652  The procedure for importing the project using TortoiseSVN is described
20653  below, assuming an existing repository and a new project being started
20654  in 
20655 \family typewriter
20656 C:
20657 \backslash
20658 new project
20659 \family default
20660 .
20661  For information on using the Subversion client program, run 
20662 \family typewriter
20663 svn --help 
20664 \family default
20665 in a DOS shell.
20666 \end_layout
20667
20668 \begin_layout Enumerate
20669 Locate 
20670 \family typewriter
20671 C:
20672 \backslash
20673 new project 
20674 \family default
20675 in Windows Explorer, right click it, and select 
20676 \family typewriter
20677 TortoiseSVN > Repo-browser
20678 \family default
20679 .
20680  If necessary, adjust the URL for the repository, then click OK.
20681 \end_layout
20682
20683 \begin_layout Enumerate
20684 Right click the level of the repository under which you want to place the
20685  new project folder (typically the top level) and click 
20686 \family typewriter
20687 Create folder\SpecialChar \ldots{}
20688
20689 \family default
20690  Supply a name for the project folder and click OK.
20691  Add a message for the log file if desired, then click OK again.
20692  The new project folder should appear in the repository.
20693  Finally, click OK again to exit the repository browser.
20694 \end_layout
20695
20696 \begin_layout Enumerate
20697 Once again right click 
20698 \family typewriter
20699 C:
20700 \backslash
20701 new project
20702 \family default
20703 , this time selecting SVN Checkout\SpecialChar \ldots{}
20704  Select the URL of the project folder
20705  you just created in the repository, and set the checkout directory to 
20706 \family typewriter
20707 C:
20708 \backslash
20709 new project.
20710
20711 \family default
20712  Click OK.
20713  You will be warned about a non-empty folder; click OK to proceed.
20714  You should now have a 
20715 \family typewriter
20716 .svn
20717 \family default
20718  directory under 
20719 \family typewriter
20720 C:
20721 \backslash
20722 new project.
20723 \end_layout
20724
20725 \begin_layout Enumerate
20726 Create or open your document in LyX and click 
20727 \family sans
20728 \bar under
20729 F
20730 \bar default
20731 ile\SpecialChar \menuseparator
20732
20733 \bar under
20734 V
20735 \bar default
20736 ersion
20737 \begin_inset space ~
20738 \end_inset
20739
20740 Control\SpecialChar \menuseparator
20741
20742 \bar under
20743 R
20744 \bar default
20745 egister.
20746  
20747 \family default
20748 Add a log message and click OK to commit the document to version control.
20749 \end_layout
20750
20751 \begin_layout Standard
20752 From this point onward, you should have full functionality in the 
20753 \family sans
20754 \bar under
20755 F
20756 \bar default
20757 ile\SpecialChar \menuseparator
20758
20759 \bar under
20760 V
20761 \bar default
20762 ersion
20763 \begin_inset space ~
20764 \end_inset
20765
20766 Control
20767 \family default
20768  menu.
20769  You also have the option of checking the document in and out, viewing its
20770  history, etc.
20771  using the TortoiseSVN context menu in Windows Explorer or the Subversion
20772  client program from a command prompt.
20773 \end_layout
20774
20775 \begin_layout Subsubsection
20776 SSH tunnel used with SVN under Windows
20777 \end_layout
20778
20779 \begin_layout Standard
20780 Compared with Linux setting up svn client to communicate over ssh under
20781  Windows is a rather troublesome task.
20782  We will at least offer some hints how to setup the client side but prior
20783  knowledge about ssh and the Windows command line is needed, also be prepared
20784  for a great deal of frustration\SpecialChar \ldots{}
20785
20786 \end_layout
20787
20788 \begin_layout Enumerate
20789 Get a svn client for windows, as described in the previous sections.
20790  When it is a fresh install run some svn command (e.g.
20791  
20792 \begin_inset Flex Code
20793 status collapsed
20794
20795 \begin_layout Plain Layout
20796 svn --version
20797 \end_layout
20798
20799 \end_inset
20800
20801 ) to create config files, which you will need to change later on.
20802 \end_layout
20803
20804 \begin_layout Enumerate
20805 Choose a ssh client for Windows.
20806  There are several possibilities, we will use the one from Putty tools
20807 \begin_inset Foot
20808 status open
20809
20810 \begin_layout Plain Layout
20811 \begin_inset Flex URL
20812 status collapsed
20813
20814 \begin_layout Plain Layout
20815
20816 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
20817 \end_layout
20818
20819 \end_inset
20820
20821
20822 \end_layout
20823
20824 \end_inset
20825
20826 .
20827  You will need to set the connection up so that the client doesn't ask for
20828  any password from you.
20829  To keep things easy we will use only keys without any additional password
20830  protection etc.
20831 \end_layout
20832
20833 \begin_deeper
20834 \begin_layout Enumerate
20835 Generate keys by 
20836 \begin_inset Flex Code
20837 status collapsed
20838
20839 \begin_layout Plain Layout
20840 puttygen
20841 \end_layout
20842
20843 \end_inset
20844
20845 .
20846  Save your private .ppk key file and put the public one on the server side.
20847  If the SVN server runs on Linux, note that the format of the public key
20848  is not compatible with Linux openssh and you will need to direcly copy-paste
20849  the key from the “
20850 \emph on
20851 Public key for pasting into OpenSSH authorized_keys file
20852 \emph default
20853 :” edit field into the server's 
20854 \begin_inset Flex Code
20855 status collapsed
20856
20857 \begin_layout Plain Layout
20858 ~/.ssh/authorized_keys
20859 \end_layout
20860
20861 \end_inset
20862
20863
20864 \begin_inset Flex Code
20865 status collapsed
20866
20867 \begin_layout Plain Layout
20868 authorized_keys2
20869 \end_layout
20870
20871 \end_inset
20872
20873  file.
20874 \end_layout
20875
20876 \begin_layout Enumerate
20877 Get the Putty's 
20878 \begin_inset Flex Code
20879 status collapsed
20880
20881 \begin_layout Plain Layout
20882 plink
20883 \end_layout
20884
20885 \end_inset
20886
20887 .
20888  In the SVN config file
20889 \begin_inset Foot
20890 status collapsed
20891
20892 \begin_layout Plain Layout
20893 Exact path depends on Windows version, usually somewhere around 
20894 \begin_inset Flex Code
20895 status collapsed
20896
20897 \begin_layout Plain Layout
20898 c:
20899 \backslash
20900 Documents and Settings
20901 \backslash
20902 user
20903 \backslash
20904 Application Data
20905 \backslash
20906 Subversion
20907 \backslash
20908 config
20909 \end_layout
20910
20911 \end_inset
20912
20913  / 
20914 \begin_inset Flex Code
20915 status collapsed
20916
20917 \begin_layout Plain Layout
20918 AppData
20919 \backslash
20920 Roaming
20921 \backslash
20922 Subversion
20923 \end_layout
20924
20925 \end_inset
20926
20927 .
20928 \end_layout
20929
20930 \end_inset
20931
20932 , section [tunnels], setup ssh command, e.g.
20933  
20934 \begin_inset Flex Code
20935 status collapsed
20936
20937 \begin_layout Plain Layout
20938 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
20939 \end_layout
20940
20941 \end_inset
20942
20943 .
20944 \begin_inset Foot
20945 status collapsed
20946
20947 \begin_layout Plain Layout
20948 It will usually take a lot of time to get exact command right and it depends
20949  on many things.
20950  For example do not have some remote server saved as a default session in
20951  Putty etc.
20952  If things fail, try to connect via plink without SVN first.
20953 \end_layout
20954
20955 \end_inset
20956
20957
20958 \end_layout
20959
20960 \end_deeper
20961 \begin_layout Enumerate
20962 Checkout the SVN archive, e.g.
20963  
20964 \begin_inset Flex Code
20965 status collapsed
20966
20967 \begin_layout Plain Layout
20968 svn co svn+ssh://user@server/repository_path
20969 \end_layout
20970
20971 \end_inset
20972
20973 .
20974 \end_layout
20975
20976 \begin_layout Subsubsection
20977 End-of-Line Conversions
20978 \end_layout
20979
20980 \begin_layout Standard
20981 When the collsraborators are mixing Linux and Windows environments, LyX
20982  will use different line endings inside the .lyx files.
20983  This is not a problem as far as LyX functionality is concerned, but the
20984  commit diffs will be huge and merge-conflicts prone.
20985  Fortunately SVN itself knows
20986 \begin_inset Foot
20987 status collapsed
20988
20989 \begin_layout Plain Layout
20990 \begin_inset Flex URL
20991 status collapsed
20992
20993 \begin_layout Plain Layout
20994
20995 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
20996 \end_layout
20997
20998 \end_inset
20999
21000
21001 \end_layout
21002
21003 \end_inset
21004
21005  how to deal with CR/LF problems when switching .lyx files to the 
21006 \begin_inset Flex Code
21007 status collapsed
21008
21009 \begin_layout Plain Layout
21010 native
21011 \end_layout
21012
21013 \end_inset
21014
21015  mode.
21016 \begin_inset Foot
21017 status collapsed
21018
21019 \begin_layout Plain Layout
21020 For the lazy guys: 
21021 \begin_inset Flex Code
21022 status collapsed
21023
21024 \begin_layout Plain Layout
21025 svn propset svn:eol-style native FILE_NAME
21026 \end_layout
21027
21028 \end_inset
21029
21030
21031 \end_layout
21032
21033 \end_inset
21034
21035
21036 \end_layout
21037
21038 \begin_layout Subsection
21039 Further tuning
21040 \end_layout
21041
21042 \begin_layout Standard
21043 With the recent addition of the vc-command function LyX power users are
21044  allowed to create their own commands for revision control.
21045 \end_layout
21046
21047 \begin_layout Standard
21048 As an example you can see how two TortoiseSVN commands could be integrated
21049  directly:
21050 \end_layout
21051
21052 \begin_layout Description
21053 Commit: 
21054 \begin_inset Flex Code
21055 status collapsed
21056
21057 \begin_layout Plain Layout
21058 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
21059 \end_layout
21060
21061 \end_inset
21062
21063
21064 \end_layout
21065
21066 \begin_layout Description
21067 Revert: 
21068 \begin_inset Flex Code
21069 status collapsed
21070
21071 \begin_layout Plain Layout
21072 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
21073 \end_layout
21074
21075 \end_inset
21076
21077
21078 \end_layout
21079
21080 \begin_layout Subsection
21081 Version control and Document comparison
21082 \end_layout
21083
21084 \begin_layout Standard
21085 One of the typical uses of version control is to inspect the changes between
21086  revisions, usually by creating 
21087 \begin_inset Flex Code
21088 status collapsed
21089
21090 \begin_layout Plain Layout
21091 diff
21092 \end_layout
21093
21094 \end_inset
21095
21096  dumps.
21097  While this is useful for plain text files, it is much less useful in the
21098  case of LyX files, which have more complicated structure.
21099  Hence we provide binding to the Document comparison feature.
21100  They are two ways of calling this feature - either by direct call of 
21101 \begin_inset Flex Code
21102 status collapsed
21103
21104 \begin_layout Plain Layout
21105 VC_COMPARE
21106 \end_layout
21107
21108 \end_inset
21109
21110  LyX function (for details see LyX functions manual) or by icon/menu item
21111  
21112 \begin_inset Flex MenuItem
21113 status collapsed
21114
21115 \begin_layout Plain Layout
21116 Compare with older revision...
21117 \end_layout
21118
21119 \end_inset
21120
21121 .
21122  One can either compare two chosen revisions of the document or he can simply
21123  compare the current version of edited text with older revisions (where
21124  '
21125 \begin_inset Flex MenuItem
21126 status collapsed
21127
21128 \begin_layout Plain Layout
21129 0
21130 \end_layout
21131
21132 \end_inset
21133
21134 ' revisions back means comparison of the edited file with last commited
21135  revision).
21136  
21137 \end_layout
21138
21139 \begin_layout Standard
21140 This feature is supported for SVN and RCS though due to the more complicated
21141  versioning scheme of RCS there is a constraint -- when addressing the revisions
21142  in dialog, numbers always point to the last number in RCS revision number,
21143  i.e.
21144  '35' in '1.2.35'.
21145 \end_layout
21146
21147 \begin_layout Section
21148 Literate Programming
21149 \end_layout
21150
21151 \begin_layout Standard
21152 Updated by 
21153 \noun on
21154 Kayvan Sylvan 
21155 \noun default
21156 (kayvan@sylvan.com)
21157 \noun on
21158
21159 \noun default
21160 original documentation written by 
21161 \noun on
21162 Edmar Wienskoski Jr.
21163
21164 \noun default
21165  (edmar-w-jr@technologist.com)
21166 \end_layout
21167
21168 \begin_layout Subsection
21169 Introduction
21170 \end_layout
21171
21172 \begin_layout Standard
21173 The main purpose of this documentation is to show you how to use LyX for
21174  literate programming, where it is assumed that you are familiar with this
21175  programming technique, and know what 
21176 \begin_inset Quotes eld
21177 \end_inset
21178
21179 tangling
21180 \begin_inset Quotes erd
21181 \end_inset
21182
21183  and 
21184 \begin_inset Quotes eld
21185 \end_inset
21186
21187 weaving
21188 \begin_inset Quotes erd
21189 \end_inset
21190
21191  means.
21192  If that is not the case, please follow the web links provided in the following
21193  sections.
21194  There is a lot of good documentation out there covering old development
21195  history to the latest tools tips.
21196 \end_layout
21197
21198 \begin_layout Standard
21199 It is also assumed that you are familiar with LyX itself to a point that
21200  you are comfortable changing your LyX preferences, and X resources file.
21201  If that is not the case please refer to other LyX documentation to cover
21202  your specific needs.
21203 \end_layout
21204
21205 \begin_layout Subsection
21206 Literate Programming
21207 \end_layout
21208
21209 \begin_layout Standard
21210 From the Literate Programming FAQ: 
21211 \end_layout
21212
21213 \begin_layout Quotation
21214 Literate programming is the combination of documentation and source together
21215  in a fashion suited for reading by human beings.
21216  In fact, literate programs should be enjoyable reading, even inviting!
21217  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
21218  and documentation in a single file.
21219  Literate programming tools then parse the file to produce either readable
21220  documentation or compilable source.
21221  The WEB style of literate programming was created by D.
21222 \begin_inset space \thinspace{}
21223 \end_inset
21224
21225 E.
21226  Knuth during the development of his TeX typesetting software.
21227  
21228 \end_layout
21229
21230 \begin_layout Standard
21231 Another excerpt says:
21232 \end_layout
21233
21234 \begin_layout Quotation
21235
21236 \emph on
21237 How is literate programming different from verbose commenting?
21238 \end_layout
21239
21240 \begin_layout Quotation
21241 There are three distinguishing characteristics.
21242  In order of importance, they are: 
21243 \end_layout
21244
21245 \begin_deeper
21246 \begin_layout Itemize
21247 flexible order of elaboration 
21248 \end_layout
21249
21250 \begin_layout Itemize
21251 automatic support for browsing 
21252 \end_layout
21253
21254 \begin_layout Itemize
21255 typeset documentation, especially diagrams and mathematics 
21256 \end_layout
21257
21258 \end_deeper
21259 \begin_layout Standard
21260 Now that I sparked your curiosity, take a look in the references.
21261 \end_layout
21262
21263 \begin_layout Subsubsection
21264 References
21265 \end_layout
21266
21267 \begin_layout Standard
21268 The complete Literate Programming FAQ can be found at:
21269 \end_layout
21270
21271 \begin_layout Quote
21272 Literate Programming FAQ 
21273 \begin_inset Flex URL
21274 status collapsed
21275
21276 \begin_layout Plain Layout
21277
21278 http://www.literateprogramming.com/lpfaq.pdf
21279 \end_layout
21280
21281 \end_inset
21282
21283
21284 \end_layout
21285
21286 \begin_layout Standard
21287 The FAQ lists 23 (twenty three!) different literate programming tools.
21288  Where some are specialized or 
21289 \begin_inset Quotes eld
21290 \end_inset
21291
21292 tailored
21293 \begin_inset Quotes erd
21294 \end_inset
21295
21296  for particular programming languages, while other have general scope.
21297  I selected 
21298 \noun on
21299 Noweb
21300 \noun default
21301  for my own use for several reasons:
21302 \end_layout
21303
21304 \begin_layout Itemize
21305 It can generate the documentation either in LaTeX or HTML.
21306 \end_layout
21307
21308 \begin_layout Itemize
21309 It has a open architecture, i.
21310 \begin_inset space \thinspace{}
21311 \end_inset
21312
21313 g.
21314 \begin_inset space \space{}
21315 \end_inset
21316
21317 it is easy to plug in new filters and to perform special processing that
21318  you may need.
21319  
21320 \end_layout
21321
21322 \begin_layout Itemize
21323 There is a good selection of filters available already (the HTML is one
21324  of them).
21325 \end_layout
21326
21327 \begin_layout Itemize
21328 It is free.
21329 \end_layout
21330
21331 \begin_layout Standard
21332 The Noweb web page can be found at: 
21333 \end_layout
21334
21335 \begin_layout Quote
21336 Noweb home page 
21337 \begin_inset Flex URL
21338 status collapsed
21339
21340 \begin_layout Plain Layout
21341
21342 http://www.cs.virginia.edu/~nr/noweb/
21343 \end_layout
21344
21345 \end_inset
21346
21347
21348 \end_layout
21349
21350 \begin_layout Standard
21351 Starting from there you can reach many other interesting links and even
21352  some literate program examples.
21353 \end_layout
21354
21355 \begin_layout Subsection
21356 LyX and Literate Programming
21357 \end_layout
21358
21359 \begin_layout Standard
21360 The LyX support for Literate Programming is provided by using the generic
21361  LyX converters mechanism.
21362  This support is provided in a 
21363 \begin_inset Quotes eld
21364 \end_inset
21365
21366 Noweb independent
21367 \begin_inset Quotes erd
21368 \end_inset
21369
21370  way, i.
21371 \begin_inset space \thinspace{}
21372 \end_inset
21373
21374 g.
21375 \begin_inset space \space{}
21376 \end_inset
21377
21378 you will be able to use this new LyX feature with some other literate programmin
21379 g tool of your choice by just changing your LyX preferences.
21380 \end_layout
21381
21382 \begin_layout Subsubsection
21383 Generating documents and code (weaving and tangling)
21384 \end_layout
21385
21386 \begin_layout Paragraph
21387 Selecting the document class
21388 \end_layout
21389
21390 \begin_layout Standard
21391 If you have installed Noweb and LyX successfully, whenever you open a new
21392  document or try to change the document class of an existing one, you will
21393  find that there are three new document classes available:
21394 \end_layout
21395
21396 \begin_layout Itemize
21397 Article (Noweb)
21398 \end_layout
21399
21400 \begin_layout Itemize
21401 Book (Noweb)
21402 \end_layout
21403
21404 \begin_layout Itemize
21405 Report (Noweb)
21406 \end_layout
21407
21408 \begin_layout Standard
21409 You must select one of them to create your literate documents from.
21410  
21411 \end_layout
21412
21413 \begin_layout Standard
21414 Note that literate documents are not limited to these three classes.
21415  New classes can be generated from other styles like letter or in combination
21416  with other class variations like Article (AMS).
21417  If you have special needs that cannot be covered by one of the existing
21418  classes, let the LyX developers list (lyx-devel@lists.lyx.org) know and we
21419  will arrange to insert a new entry, or teach you how to do it.
21420 \begin_inset Foot
21421 status collapsed
21422
21423 \begin_layout Plain Layout
21424 It is very simple, it involves the creation of a file with four lines, and
21425  re-running of the auto configuration.
21426 \end_layout
21427
21428 \end_inset
21429
21430  Moreover, if you use a literate tool other than Noweb you may need to create
21431  a new set of document classes for it.
21432 \end_layout
21433
21434 \begin_layout Paragraph
21435 Typing code in
21436 \end_layout
21437
21438 \begin_layout Standard
21439 LyX enables you to write code with a layout named 
21440 \noun on
21441 Scrap
21442 \noun default
21443 .
21444 \begin_inset Foot
21445 status collapsed
21446
21447 \begin_layout Plain Layout
21448 The equivalent Noweb term is 
21449 \begin_inset Quotes eld
21450 \end_inset
21451
21452 Chunk
21453 \begin_inset Quotes erd
21454 \end_inset
21455
21456 .
21457  For historical reasons, I got used to the term 
21458 \begin_inset Quotes eld
21459 \end_inset
21460
21461 scrap
21462 \begin_inset Quotes erd
21463 \end_inset
21464
21465  introduced by other literate tool named Nuweb, which I used for many years
21466  before rendering myself to Noweb.
21467 \end_layout
21468
21469 \end_inset
21470
21471  Noweb delimits scraps like this:
21472 \end_layout
21473
21474 \begin_layout LyX-Code
21475 <<My scrap>>=
21476 \end_layout
21477
21478 \begin_layout LyX-Code
21479   code
21480 \end_layout
21481
21482 \begin_layout LyX-Code
21483   more code
21484 \end_layout
21485
21486 \begin_layout LyX-Code
21487   even more code
21488 \end_layout
21489
21490 \begin_layout LyX-Code
21491   @
21492 \end_layout
21493
21494 \begin_layout Standard
21495 The problem is that whatever is written in between the << and the 
21496 \family typewriter
21497 @
21498 \family default
21499  must be taken literally, i.
21500 \begin_inset space \thinspace{}
21501 \end_inset
21502
21503 g.
21504 \begin_inset space \space{}
21505 \end_inset
21506
21507 LyX should be prevented from making any special interpretation of what has
21508  been written.
21509  This is handled by a special layout named Scrap, that works like a normal
21510  paragraph but has a free spacing capability.
21511 \end_layout
21512
21513 \begin_layout Standard
21514 The down side of the Scrap paragraph layout is that consecutive paragraphs
21515  of code will be spaced with one empty line in the source code and also
21516  in the printed documentation.
21517  The work around is to enter each line of code within a single Scrap, with
21518  a newline (ctrl-return).
21519  The example above will look like this:
21520 \begin_inset Foot
21521 status collapsed
21522
21523 \begin_layout Plain Layout
21524 If you have a printed version of this document you will not see any difference
21525  between the previous example and this one.
21526 \end_layout
21527
21528 \end_inset
21529
21530
21531 \end_layout
21532
21533 \begin_layout LyX-Code
21534 <<My scrap>>=
21535 \begin_inset Newline newline
21536 \end_inset
21537
21538   code
21539 \begin_inset Newline newline
21540 \end_inset
21541
21542   more code
21543 \begin_inset Newline newline
21544 \end_inset
21545
21546   even more code
21547 \begin_inset Newline newline
21548 \end_inset
21549
21550   @
21551 \end_layout
21552
21553 \begin_layout Standard
21554 This layout works fine.
21555  The only real inconvenience is that you have to type ctrl-return instead
21556  of a plain return.
21557 \begin_inset Foot
21558 status collapsed
21559
21560 \begin_layout Plain Layout
21561 It is in my list of 
21562 \begin_inset Quotes eld
21563 \end_inset
21564
21565 improvements
21566 \begin_inset Quotes erd
21567 \end_inset
21568
21569  to fix that.
21570 \end_layout
21571
21572 \end_inset
21573
21574
21575 \end_layout
21576
21577 \begin_layout Standard
21578 As a special note, you can also use the 
21579 \begin_inset Quotes eld
21580 \end_inset
21581
21582 %def
21583 \begin_inset Quotes erd
21584 \end_inset
21585
21586  construct of Noweb in your scraps to add items to Noweb's identifier cross-refe
21587 rence:
21588 \end_layout
21589
21590 \begin_layout LyX-Code
21591 <<My scrap>>=
21592 \begin_inset Newline newline
21593 \end_inset
21594
21595   def some_function(args):
21596 \begin_inset Newline newline
21597 \end_inset
21598
21599     "This is the doc string for this function."
21600 \begin_inset Newline newline
21601 \end_inset
21602
21603     print "My args: ", args
21604 \end_layout
21605
21606 \begin_layout LyX-Code
21607 @ %def some_function
21608 \end_layout
21609
21610 \begin_layout Standard
21611 For an example of this usage and the resulting cross-reference output, look
21612  at the Literate python program in 
21613 \emph on
21614 LIBDIR/examples/listerrors.lyx
21615 \emph default
21616  which should make this all clear.
21617 \end_layout
21618
21619 \begin_layout Paragraph
21620 Generating the documentation
21621 \end_layout
21622
21623 \begin_layout Standard
21624 At this point you already have a new document file with a proper document
21625  class, and with some code and text on it.
21626  How do I print it? The answer is simple, you select 
21627 \family sans
21628 View\SpecialChar \menuseparator
21629 DVI,
21630 \family default
21631  etc.
21632  Just like you would do for a plain document.
21633  No special procedure is required.
21634 \end_layout
21635
21636 \begin_layout Standard
21637 To help orientate you, I will now explain what happens inside LyX:
21638 \end_layout
21639
21640 \begin_layout Enumerate
21641 When the 
21642 \family sans
21643 Update\SpecialChar \menuseparator
21644 DVI
21645 \family default
21646  menu option is chosen, a LaTeX file is generated.
21647  
21648 \end_layout
21649
21650 \begin_deeper
21651 \begin_layout Standard
21652 If the document is of any literate class the generated file will be named
21653  with an extension name defined by the 
21654 \begin_inset Quotes eld
21655 \end_inset
21656
21657 literate
21658 \begin_inset Quotes erd
21659 \end_inset
21660
21661  format (defined in the Preferences panel), otherwise the file will have
21662  the usual 
21663 \family typewriter
21664 .tex
21665 \family default
21666  extension.
21667 \end_layout
21668
21669 \end_deeper
21670 \begin_layout Enumerate
21671 Note that the only difference so far is in the name of the file, no special
21672  processing is required by LyX.
21673  Given that you formatted the code using the Scrap layout that, by itself,
21674  takes care of the business.
21675 \end_layout
21676
21677 \begin_layout Enumerate
21678 If the document is of any literate class LyX will then use the internal
21679  LyX to Noweb converter, followed by the Noweb to LaTeX converter
21680 \begin_inset Foot
21681 status collapsed
21682
21683 \begin_layout Plain Layout
21684 The converters are defined in the 
21685 \family sans
21686 Tools\SpecialChar \menuseparator
21687 Preferences
21688 \family default
21689  panel, under the 
21690 \begin_inset Quotes eld
21691 \end_inset
21692
21693 Conversion
21694 \begin_inset Quotes erd
21695 \end_inset
21696
21697  tab.
21698  See section 
21699 \emph on
21700 Converters
21701 \emph default
21702  of the 
21703 \emph on
21704 Customization
21705 \emph default
21706  manual for general information about converters.
21707 \end_layout
21708
21709 \end_inset
21710
21711  to generate the LaTeX file.
21712 \end_layout
21713
21714 \begin_deeper
21715 \begin_layout Standard
21716 Otherwise it will just skip this step.
21717 \end_layout
21718
21719 \end_deeper
21720 \begin_layout Enumerate
21721 Finally, LaTeX is invoked and the regular post processing continues as in
21722  a plain document.
21723 \end_layout
21724
21725 \begin_layout Standard
21726 Independence from a particular 
21727 \begin_inset Quotes eld
21728 \end_inset
21729
21730 literate tool
21731 \begin_inset Quotes erd
21732 \end_inset
21733
21734  is easily achieved by changing the commands that are run by the various
21735  converters.
21736 \end_layout
21737
21738 \begin_layout Paragraph
21739 Generating the code
21740 \end_layout
21741
21742 \begin_layout Standard
21743 When the build menu option is chosen or the corresponding button in the
21744  toolbar is pressed, a LaTeX file is generated just like step 1 above.
21745  Next, LyX invokes the 
21746 \family typewriter
21747 Noweb->Program
21748 \family default
21749  converter.
21750  This converter needs to be defined by the user and is not installed by
21751  default, though the Program format is.
21752  This converter (like any other converter) will have two parts:
21753 \end_layout
21754
21755 \begin_layout Enumerate
21756 The converter program itself.
21757  This program performs the conversion from the one format to the other (in
21758  this case, from the Noweb format to the Program pseudo-format).
21759 \end_layout
21760
21761 \begin_layout Enumerate
21762 The error log parser.
21763  This is a program whose sole purpose is to rewrite error messages in a
21764  format that LyX understands.
21765  This makes it possible for LyX to place error boxes in the right places
21766  in the file buffer.
21767 \end_layout
21768
21769 \begin_layout Standard
21770 The first part, the 
21771 \begin_inset Quotes eld
21772 \end_inset
21773
21774 Converter
21775 \begin_inset Quotes erd
21776 \end_inset
21777
21778  setting, should be set to 
21779 \begin_inset Quotes eld
21780 \end_inset
21781
21782
21783 \family typewriter
21784 build-script $$i
21785 \family default
21786
21787 \begin_inset Quotes erd
21788 \end_inset
21789
21790 .
21791  This basically means that LyX will call 
21792 \begin_inset Quotes eld
21793 \end_inset
21794
21795 build-script
21796 \begin_inset Quotes erd
21797 \end_inset
21798
21799  (a program or script) with the name of the Noweb file (normally a file
21800  in the LyX temp directory).
21801  
21802 \end_layout
21803
21804 \begin_layout Standard
21805 This is an implementation of 
21806 \begin_inset Quotes eld
21807 \end_inset
21808
21809 build-script
21810 \begin_inset Quotes erd
21811 \end_inset
21812
21813  that you can place in a directory on your path:
21814 \end_layout
21815
21816 \begin_layout LyX-Code
21817 #!/bin/sh
21818 \end_layout
21819
21820 \begin_layout LyX-Code
21821 #
21822 \end_layout
21823
21824 \begin_layout LyX-Code
21825 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 sh
21826 \end_layout
21827
21828 \begin_layout Standard
21829 The next part of the converter setting is the 
21830 \begin_inset Quotes eld
21831 \end_inset
21832
21833 Flags
21834 \begin_inset Quotes erd
21835 \end_inset
21836
21837  which is to be set to 
21838 \begin_inset Quotes eld
21839 \end_inset
21840
21841
21842 \family typewriter
21843 parselog=listerrors
21844 \family default
21845
21846 \begin_inset Quotes erd
21847 \end_inset
21848
21849 .
21850  This will run any errors that are generated by the 
21851 \begin_inset Quotes eld
21852 \end_inset
21853
21854 build-script
21855 \begin_inset Quotes erd
21856 \end_inset
21857
21858  process through the 
21859 \begin_inset Quotes eld
21860 \end_inset
21861
21862 listerrors
21863 \begin_inset Quotes erd
21864 \end_inset
21865
21866  program.
21867 \end_layout
21868
21869 \begin_layout Standard
21870 The converter code looks in 
21871 \emph on
21872 MYLYXDIR/scripts
21873 \emph default
21874  first, then in 
21875 \emph on
21876 LIBDIR/scripts
21877 \emph default
21878  then on the path for the 
21879 \begin_inset Quotes eld
21880 \end_inset
21881
21882 listerrors
21883 \begin_inset Quotes erd
21884 \end_inset
21885
21886  program.
21887 \end_layout
21888
21889 \begin_layout Standard
21890 The build will normally take place in LyX's temporary directory, so the
21891  files produced by the conversion will be in that directory.
21892  LyX will copy out what it regards as the `main' file, but the 
21893 \family typewriter
21894 Noweb->Program
21895 \family default
21896  conversion may produce several files, and so most of these would then be
21897  deleted when LyX was closed.
21898  The present solution is to use a `copier',
21899 \begin_inset Foot
21900 status collapsed
21901
21902 \begin_layout Plain Layout
21903 See section 
21904 \emph on
21905 Copiers
21906 \emph default
21907  of the 
21908 \emph on
21909 Customization
21910 \emph default
21911  manual for information on these.
21912 \end_layout
21913
21914 \end_inset
21915
21916  in this case, the 
21917 \family typewriter
21918 ext_copy.py
21919 \family default
21920  script in its default mode, so that the entire contents of the temporary
21921  directory is copied.
21922  More will get copied than is needed, to be sure, but nothing will be lost.
21923  If, however, you know what extensions the generated files will have, this
21924  can be improved by using the 
21925 \family typewriter
21926 -e
21927 \family default
21928  option to 
21929 \family typewriter
21930 ext_copy
21931 \family default
21932 .
21933  This option takes a comma-separated list of extensions to copy.
21934  So, for example, if the conversion will generate only files with the extensions
21935  
21936 \family typewriter
21937 .c
21938 \family default
21939  and 
21940 \family typewriter
21941 .h
21942 \family default
21943 , then the correct definition would be:
21944 \end_layout
21945
21946 \begin_layout LyX-Code
21947 python -tt $$s/scripts/ext_copy.py -e c,h $$i $$o
21948 \end_layout
21949
21950 \begin_layout Standard
21951 The result will be that only files with these two extensions will be copied
21952  out.
21953 \end_layout
21954
21955 \begin_layout Paragraph
21956 Build instructions in the document
21957 \end_layout
21958
21959 \begin_layout Standard
21960 The last piece of the integration between LyX and noweb is the 
21961 \begin_inset Quotes eld
21962 \end_inset
21963
21964 build-script
21965 \begin_inset Quotes erd
21966 \end_inset
21967
21968  scrap.
21969  Generally, the instructions for building your program should be embedded
21970  in a scrap of its own.
21971  The noweb-specific 
21972 \begin_inset Quotes eld
21973 \end_inset
21974
21975 build-script
21976 \begin_inset Quotes erd
21977 \end_inset
21978
21979  above uses the notangle command to look for this scrap (called 
21980 \begin_inset Quotes eld
21981 \end_inset
21982
21983 build-script
21984 \begin_inset Quotes erd
21985 \end_inset
21986
21987 ) and runs its contents through 
21988 \begin_inset Quotes eld
21989 \end_inset
21990
21991 sh
21992 \begin_inset Quotes erd
21993 \end_inset
21994
21995 .
21996 \end_layout
21997
21998 \begin_layout Standard
21999 Typically, such a scrap would look something like this:
22000 \end_layout
22001
22002 \begin_layout LyX-Code
22003 <<build-script>>=
22004 \begin_inset Newline newline
22005 \end_inset
22006
22007 #!/bin/sh
22008 \begin_inset Newline newline
22009 \end_inset
22010
22011
22012 \begin_inset Newline newline
22013 \end_inset
22014
22015 if [ -z "${NOWEB_SOURCE}" ]
22016 \begin_inset Newline newline
22017 \end_inset
22018
22019 then
22020 \begin_inset Newline newline
22021 \end_inset
22022
22023   NOWEB_SOURCE=myfile.nw
22024 \begin_inset Newline newline
22025 \end_inset
22026
22027 fi
22028 \begin_inset Newline newline
22029 \end_inset
22030
22031 [...
22032  code to extract files ...]
22033 \begin_inset Newline newline
22034 \end_inset
22035
22036 [...
22037  code to compile files ...]
22038 \begin_inset Newline newline
22039 \end_inset
22040
22041 @
22042 \end_layout
22043
22044 \begin_layout Standard
22045 Look in 
22046 \emph on
22047 LIBDIR/examples/listerrors.lyx
22048 \emph default
22049  or in 
22050 \emph on
22051 LIBDIR/examples/Literate.lyx
22052 \emph default
22053  which implement two versions of the 
22054 \begin_inset Quotes eld
22055 \end_inset
22056
22057 listerrors
22058 \begin_inset Quotes erd
22059 \end_inset
22060
22061  program for some illustrations of how all of these pieces go together or
22062  in 
22063 \emph on
22064 LIBDIR/examples/noweb2lyx.lyx.
22065
22066 \emph default
22067  Interestingly, these three files show off the language-indepence of the
22068  LyX literate programming support since they are written in Python, C and
22069  Perl respectively.
22070 \end_layout
22071
22072 \begin_layout Subsubsection
22073 Configuring LyX
22074 \end_layout
22075
22076 \begin_layout Standard
22077 All the Literate Programming support is configured by the 
22078 \family sans
22079 Tools\SpecialChar \menuseparator
22080 Preferences
22081 \family default
22082  panel in the 
22083 \begin_inset Quotes eld
22084 \end_inset
22085
22086 Conversion
22087 \begin_inset Quotes erd
22088 \end_inset
22089
22090  tab.
22091  The important parts are:
22092 \end_layout
22093
22094 \begin_layout Description
22095 the
22096 \begin_inset space ~
22097 \end_inset
22098
22099
22100 \begin_inset Quotes eld
22101 \end_inset
22102
22103 literate
22104 \begin_inset Quotes erd
22105 \end_inset
22106
22107
22108 \begin_inset space ~
22109 \end_inset
22110
22111 format Set up via the Formats tab, this is where the Noweb-specific pieces
22112  are set up.
22113  The 
22114 \family sans
22115 GUI Name
22116 \family default
22117  is set to 
22118 \family typewriter
22119 NoWeb
22120 \family default
22121 , the file extension is set to 
22122 \family typewriter
22123 .nw
22124 \family default
22125 .
22126  This tells LyX to create a file with a 
22127 \family typewriter
22128 .nw
22129 \family default
22130  extension in the first step of the conversion process.
22131 \end_layout
22132
22133 \begin_layout Description
22134 the
22135 \begin_inset space ~
22136 \end_inset
22137
22138
22139 \family sans
22140 Program
22141 \family default
22142
22143 \begin_inset space ~
22144 \end_inset
22145
22146 format This is an empty format whose sole purpose is to be the endpoint
22147  of a conversion (which then allows us to set up a converter for it).
22148 \end_layout
22149
22150 \begin_layout Description
22151
22152 \family sans
22153 NoWeb
22154 \family default
22155 ->
22156 \family sans
22157 LaTeX
22158 \family default
22159  This converter performs the 
22160 \begin_inset Quotes eld
22161 \end_inset
22162
22163 weaving
22164 \begin_inset Quotes erd
22165 \end_inset
22166
22167  of the literate document.
22168  For Noweb, it is set to 
22169 \begin_inset Quotes eld
22170 \end_inset
22171
22172
22173 \family typewriter
22174 noweave -delay -index $$i > $$o
22175 \family default
22176
22177 \begin_inset Quotes erd
22178 \end_inset
22179
22180
22181 \end_layout
22182
22183 \begin_layout Description
22184
22185 \family sans
22186 NoWeb
22187 \family default
22188 ->
22189 \family sans
22190 Program
22191 \family default
22192  This performs the 
22193 \begin_inset Quotes eld
22194 \end_inset
22195
22196 tangling step
22197 \begin_inset Quotes erd
22198 \end_inset
22199
22200 .
22201  As stated above, the Converter is set to 
22202 \begin_inset Quotes eld
22203 \end_inset
22204
22205
22206 \family typewriter
22207 build-script $$i
22208 \family default
22209
22210 \begin_inset Quotes erd
22211 \end_inset
22212
22213 , with Flags set to 
22214 \begin_inset Quotes eld
22215 \end_inset
22216
22217
22218 \family typewriter
22219 originaldir,parselog=listerrors
22220 \family default
22221
22222 \begin_inset Quotes erd
22223 \end_inset
22224
22225 .
22226 \end_layout
22227
22228 \begin_layout Subsubsection
22229 Debug extensions
22230 \end_layout
22231
22232 \begin_layout Standard
22233 There is also a new function implemented in the LyX server, the 
22234 \begin_inset Quotes eld
22235 \end_inset
22236
22237 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
22238  
22239 \end_layout
22240
22241 \begin_layout Standard
22242 When debugging code with ddd/gdb, it is possible to invoke a text editor
22243  at the current execution position with a single key stroke.
22244  The default ddd configuration for that is shift-ctrl-V.
22245  It happens that you can define the editor command line invocation in ddd
22246  by accessing the 
22247 \family sans
22248 Edit\SpecialChar \menuseparator
22249 Preferences\SpecialChar \menuseparator
22250 Helpers
22251 \family default
22252  dialog and changing the "Edit Sources" entry.
22253 \end_layout
22254
22255 \begin_layout Standard
22256 I take advantage of the new created LyX server function and this ddd feature,
22257  and set 
22258 \begin_inset Quotes eld
22259 \end_inset
22260
22261 Edit Sources
22262 \begin_inset Quotes erd
22263 \end_inset
22264
22265  to:
22266 \end_layout
22267
22268 \begin_layout LyX-Code
22269 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
22270 \end_layout
22271
22272 \begin_layout Standard
22273 With this, whenever you are using ddd and find a point in the program that
22274  you want to edit, you just press shift-ctrl-V (in the ddd window), and
22275  ddd you forward this information to LyX through the LyX server and then
22276  the LyX window will show the same file with the cursor at the same position
22277  ddd was pointing to.
22278  No more guessing or long scrolling to locate a point in the program back
22279  from debugging !
22280 \end_layout
22281
22282 \begin_layout Standard
22283 Note however that you must enable the LyX server to get this feature working
22284  (it is disabled by default).
22285  You can enable it in 
22286 \family sans
22287 Preferences
22288 \family default
22289  (tabs 
22290 \family sans
22291 Inputs
22292 \family default
22293
22294 \family sans
22295 Paths
22296 \family default
22297 ) by entering in the 
22298 \family sans
22299 LyXserver pipe
22300 \family default
22301  a path like 
22302 \begin_inset Quotes eld
22303 \end_inset
22304
22305
22306 \family typewriter
22307 /home/<your-home-directory>/.lyx/lyxpipe
22308 \family default
22309
22310 \begin_inset Quotes erd
22311 \end_inset
22312
22313
22314 \end_layout
22315
22316 \begin_layout Standard
22317 Read the LyX server documentation in the 
22318 \emph on
22319 Customization Manual
22320 \emph default
22321  for further information.
22322 \end_layout
22323
22324 \begin_layout Subsubsection
22325 Toolbar extensions
22326 \end_layout
22327
22328 \begin_layout Standard
22329 There are six new buttons that can be added to your LyX toolbar.
22330  Five of these buttons are short cuts to layout styles: 
22331 \family sans
22332 Standard
22333 \family default
22334
22335 \family sans
22336 Section
22337 \family default
22338
22339 \family sans
22340 LaTeX
22341 \family default
22342
22343 \family sans
22344 LyX-Code
22345 \family default
22346 , and 
22347 \family sans
22348 Scrap
22349 \family default
22350 .
22351  The last one is a short cut to the 
22352 \begin_inset Quotes eld
22353 \end_inset
22354
22355 Build Program
22356 \begin_inset Quotes erd
22357 \end_inset
22358
22359  File menu entry.
22360  
22361 \end_layout
22362
22363 \begin_layout Standard
22364 LyX has a range of buttons that are available for tool bar customization.
22365  In my toolbar I like to combine the six short cuts above with two more:
22366  One for 
22367 \family sans
22368 View
22369 \family default
22370 \SpecialChar \menuseparator
22371
22372 \family sans
22373 Update
22374 \family default
22375 \SpecialChar \menuseparator
22376
22377 \family sans
22378 DVI
22379 \family default
22380  and the other for 
22381 \family sans
22382 View\SpecialChar \menuseparator
22383 DVI
22384 \family default
22385  File menu entries.
22386  Here is how it looks like:
22387 \end_layout
22388
22389 \begin_layout LyX-Code
22390 Toolbar
22391 \end_layout
22392
22393 \begin_layout LyX-Code
22394   Layouts
22395 \end_layout
22396
22397 \begin_layout LyX-Code
22398   Icon "layout Standard"
22399 \end_layout
22400
22401 \begin_layout LyX-Code
22402   Icon "layout Section"
22403 \end_layout
22404
22405 \begin_layout LyX-Code
22406   Icon "layout LaTeX"
22407 \end_layout
22408
22409 \begin_layout LyX-Code
22410   Icon "layout LyX-Code"
22411 \end_layout
22412
22413 \begin_layout LyX-Code
22414   Icon "layout Scrap"
22415 \end_layout
22416
22417 \begin_layout LyX-Code
22418   Separator
22419 \end_layout
22420
22421 \begin_layout LyX-Code
22422   Icon "buffer-view"
22423 \end_layout
22424
22425 \begin_layout LyX-Code
22426   Icon "buffer-typeset"
22427 \end_layout
22428
22429 \begin_layout LyX-Code
22430   Icon "build-program"
22431 \end_layout
22432
22433 \begin_layout LyX-Code
22434   Separator
22435 \end_layout
22436
22437 \begin_layout LyX-Code
22438 .
22439 \end_layout
22440
22441 \begin_layout LyX-Code
22442 .
22443 \end_layout
22444
22445 \begin_layout LyX-Code
22446 .
22447 \end_layout
22448
22449 \begin_layout LyX-Code
22450 End
22451 \end_layout
22452
22453 \begin_layout Subsubsection
22454 Colors customization
22455 \end_layout
22456
22457 \begin_layout Standard
22458 There are a number of colors in LyX that can be customized in 
22459 \family sans
22460 Preferences
22461 \family default
22462 .
22463  One of the things that bothers people is the LaTeX font color.
22464  The default color is red, since the scraps uses LaTeX font, and there is
22465  a lot of scraps in literate documents, you may get tired of seeing everything
22466  in red.
22467  You can change it by going to the tabs 
22468 \family sans
22469 Look&Feel
22470 \family default
22471
22472 \family sans
22473 Colors.
22474 \end_layout
22475
22476 \begin_layout Standard
22477 The next thing is the visible presence of the newline character in the screen.
22478  You can choose the color of this particular character and make it blend
22479  in the background.
22480  I recommend you choosing a color that is close to the background but not
22481  equal, that way you still can see it is there, but it is not bothering
22482  you anymore.
22483  
22484 \end_layout
22485
22486 \begin_layout Chapter
22487 Special features
22488 \end_layout
22489
22490 \begin_layout Standard
22491 You can do everything with LyX that you can do with LaTeX.
22492  However, LyX cannot support every LaTeX feature directly.
22493  But you can always use TeX Code.
22494  This chapter shows you some more special things that are possible with
22495  LyX that you might want to use.
22496  For spcial things you can do with the features that are directly supported
22497  by LyX, have a look at the 
22498 \emph on
22499 EmbeddedObjects
22500 \emph default
22501  manual.
22502 \end_layout
22503
22504 \begin_layout Section
22505 Multiple Columns
22506 \end_layout
22507
22508 \begin_layout Subsection
22509 Purpose
22510 \end_layout
22511
22512 \begin_layout Standard
22513 The aim for this chapter
22514 \begin_inset Foot
22515 status collapsed
22516
22517 \begin_layout Plain Layout
22518 Editor's note: Lars' original chapter was a masterful description of how
22519  to use the 
22520 \family typewriter
22521 multicol
22522 \family default
22523  package.
22524  However, it was too long to flow smoothly in this document.
22525  I have therefore chosen to excerpt the most important sections here (sorry,
22526  Lars); you can read the original chapter (and more of the story!) in the
22527  example file 
22528 \family typewriter
22529 examples/multicol.lyx
22530 \family default
22531 .
22532  — mer
22533 \end_layout
22534
22535 \end_inset
22536
22537  is to show how the LaTeX package 
22538 \family typewriter
22539 multicol
22540 \family default
22541  can be used in a LyX document.
22542  As LyX doesn't support the 
22543 \family typewriter
22544 multicol
22545 \family default
22546  package natively yet, we have to use some small hacks.
22547  By reading this section it should be obvious how to do this.
22548 \end_layout
22549
22550 \begin_layout Subsection
22551 Limitations 
22552 \end_layout
22553
22554 \begin_layout Standard
22555 The 
22556 \family typewriter
22557 multicol
22558 \family default
22559  package allows switching between one and multicolumn format on the same
22560  page.
22561  Footnotes are handled correctly (for the most part), but will be placed
22562  at the bottom of the page and not under each column.
22563  LaTeX's float mechanism, however, is partly disabled in the current implementat
22564 ion.
22565  At the moment only page-wide floats can be used within the scope of the
22566  environment.
22567 \end_layout
22568
22569 \begin_layout Subsection
22570 Examples
22571 \end_layout
22572
22573 \begin_layout Subsubsection
22574 Two columns
22575 \end_layout
22576
22577 \begin_layout Standard
22578 If you want to have two columns in your text, you have use LaTeX mode to
22579  insert 
22580 \family typewriter
22581
22582 \backslash
22583 begin{multicols}{2}
22584 \family default
22585  at the point where you want the two column layout to start, and then 
22586 \family typewriter
22587
22588 \backslash
22589 end{multicols}
22590 \family default
22591  where you want it to end.
22592  Like this:
22593 \end_layout
22594
22595 \begin_layout Standard
22596 \begin_inset ERT
22597 status open
22598
22599 \begin_layout Plain Layout
22600
22601
22602 \backslash
22603 begin{multicols}{2}
22604 \end_layout
22605
22606 \end_inset
22607
22608
22609 \end_layout
22610
22611 \begin_layout Standard
22612 \noindent
22613
22614 \series bold
22615 \size small
22616 The Adventure of the Empty House
22617 \series default
22618
22619 \begin_inset Newline newline
22620 \end_inset
22621
22622 by 
22623 \noun on
22624 Sir Arthur Conan Doyle
22625 \end_layout
22626
22627 \begin_layout Standard
22628
22629 \size small
22630 It was in the spring of the year 1894 that all London was interested, and
22631  the fashionable world dismayed, by the murder of the Honourable Ronald
22632  Adair under most unusual and inexplicable circumstances.
22633  The public has already learned those particulars of the crime which came
22634  out in the police investigation, but a good deal was suppressed upon that
22635  occasion, since the case for the prosecution was so overwhelmingly strong
22636  that it was not necessary to bring forward all the facts.
22637  Only now, at the end of nearly ten years, am I allowed to supply those
22638  missing links which make up the whole of that remarkable chain.
22639  The crime was of interest in itself, but that interest was as nothing to
22640  me compared to the inconceivable sequel, which afforded me the greatest
22641  shock and surprise of any event in my adventurous life.
22642  Even now, after this long interval, I find myself thrilling as I think
22643  of it, and feeling once more that sudden flood of joy, amazement, and increduli
22644 ty which utterly submerged my mind.
22645  Let me say to that public, which has shown some interest in those glimpses
22646  which I have occasionally given them of the thoughts and actions of a very
22647  remarkable man, that they are not to blame me if I have not shared my knowledge
22648  with them, for I should have considered it my first duty to do so, had
22649  I not been barred by a positive prohibition from his own lips, which was
22650  only withdrawn upon the third of last month.
22651 \end_layout
22652
22653 \begin_layout Standard
22654 \begin_inset ERT
22655 status open
22656
22657 \begin_layout Plain Layout
22658
22659
22660 \backslash
22661 end{multicols}
22662 \end_layout
22663
22664 \end_inset
22665
22666
22667 \end_layout
22668
22669 \begin_layout Subsubsection
22670 Multiple columns
22671 \end_layout
22672
22673 \begin_layout Standard
22674 The same pattern is used when you want more than two columns:
22675 \end_layout
22676
22677 \begin_layout Standard
22678 \begin_inset ERT
22679 status open
22680
22681 \begin_layout Plain Layout
22682
22683
22684 \backslash
22685 begin{multicols}{3}
22686 \end_layout
22687
22688 \end_inset
22689
22690
22691 \end_layout
22692
22693 \begin_layout Standard
22694
22695 \size footnotesize
22696 It can be imagined that my close intimacy with Sherlock Holmes had interested
22697  me deeply in crime, and that after his disappearance I never failed to
22698  read with care the various problems which came before the public.
22699  And I even attempted, more than once, for my own private satisfaction,
22700  to employ his methods in their solution, though with indifferent success.
22701  There was none, however, which appealed to me like this tragedy of Ronald
22702  Adair.
22703  As I read the evidence at the inquest, which led up to a verdict of willful
22704  murder against some person or persons unknown, I realized more clearly
22705  than I had ever done the loss which the community had sustained by the
22706  death of Sherlock Holmes.
22707  There were points about this strange business which would, I was sure,
22708  have specially appealed to him, and the efforts of the police would have
22709  been supplemented, or more probably anticipated, by the trained observation
22710  and the alert mind of the first criminal agent in Europe.
22711  All day, as I drove upon my round, I turned over the case in my mind and
22712  found no explanation which appeared to me to be adequate.
22713  At the risk of telling a twice-told tale, I will recapitulate the facts
22714  as they were known to the public at the conclusion of the inquest.
22715 \end_layout
22716
22717 \begin_layout Standard
22718 \begin_inset ERT
22719 status open
22720
22721 \begin_layout Plain Layout
22722
22723
22724 \backslash
22725 end{multicols}
22726 \end_layout
22727
22728 \end_inset
22729
22730
22731 \end_layout
22732
22733 \begin_layout Standard
22734 You can have more than 3 columns if you want to, but that might not be very
22735  pleasant for the eye.
22736 \end_layout
22737
22738 \begin_layout Subsubsection
22739 Columns inside columns
22740 \end_layout
22741
22742 \begin_layout Standard
22743 You can even have columns inside columns:
22744 \end_layout
22745
22746 \begin_layout Standard
22747 \begin_inset ERT
22748 status open
22749
22750 \begin_layout Plain Layout
22751
22752
22753 \backslash
22754 begin{multicols}{2}
22755 \end_layout
22756
22757 \end_inset
22758
22759
22760 \end_layout
22761
22762 \begin_layout Standard
22763
22764 \size footnotesize
22765 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
22766  at that time governor of one of the Australian colonies.
22767  Adair's mother had returned from Australia to undergo the operation for
22768  cataract, and she, her son Ronald, and her daughter Hilda were living together
22769  at 427 Park Lane.
22770 \end_layout
22771
22772 \begin_layout Standard
22773 \begin_inset ERT
22774 status open
22775
22776 \begin_layout Plain Layout
22777
22778
22779 \backslash
22780 begin{multicols}{2}
22781 \end_layout
22782
22783 \end_inset
22784
22785
22786 \end_layout
22787
22788 \begin_layout Standard
22789
22790 \size footnotesize
22791 The youth moved in the best society–had, so far as was known, no enemies
22792  and no particular vices.
22793  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
22794  had been broken off by mutual consent some months before, and there was
22795  no sign that it had left any very profound feeling behind it.
22796  For the rest {sic} the man's life moved in a narrow and conventional circle,
22797  for his habits were quiet and his nature unemotional.
22798  Yet it was upon this easy-going young aristocrat that death came, in most
22799  strange and unexpected form, between the hours of ten and eleven-twenty
22800  on the night of March 30, 1894.
22801 \end_layout
22802
22803 \begin_layout Standard
22804 \begin_inset ERT
22805 status open
22806
22807 \begin_layout Plain Layout
22808
22809
22810 \backslash
22811 end{multicols}
22812 \end_layout
22813
22814 \end_inset
22815
22816
22817 \end_layout
22818
22819 \begin_layout Standard
22820
22821 \size footnotesize
22822 Ronald Adair was fond of cards–playing continually, but never for such stakes
22823  as would hurt him.
22824  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
22825  It was shown that, after dinner on the day of his death, he had played
22826  a rubber of whist at the latter club.
22827  He had also played there in the afternoon.
22828
22829 \size default
22830  
22831 \size footnotesize
22832 The evidence of those who had played with him– Mr.
22833  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
22834  and that there was a fairly equal fall of the cards.
22835  Adair might have lost five pounds, but not more.
22836  His fortune was a considerable one, and such a loss could not in any way
22837  affect him.
22838  He had played nearly every day at one club or other, but he was a cautious
22839  player, and usually rose a winner.
22840  It came out in evidence that, in partnership with Colonel Moran, he had
22841  actually won as much as four hundred and twenty pounds in a sitting, some
22842  weeks before, from Godfrey Milner and Lord Balmoral.
22843  So much for his recent history as it came out at the inquest.
22844 \end_layout
22845
22846 \begin_layout Standard
22847 \begin_inset ERT
22848 status open
22849
22850 \begin_layout Plain Layout
22851
22852
22853 \backslash
22854 end{multicols}
22855 \end_layout
22856
22857 \end_inset
22858
22859
22860 \end_layout
22861
22862 \begin_layout Standard
22863 Please do read the file 
22864 \family typewriter
22865 examples/multicol.lyx
22866 \family default
22867  for more advanced examples including column and header spacing, vertical
22868  separator lines, and more.
22869 \end_layout
22870
22871 \begin_layout Section
22872 Numbering in the 
22873 \family sans
22874 Enumerate
22875 \family default
22876  Paragraph Environment
22877 \begin_inset Argument
22878 status collapsed
22879
22880 \begin_layout Plain Layout
22881 Numbering in Enumerate
22882 \end_layout
22883
22884 \end_inset
22885
22886
22887 \end_layout
22888
22889 \begin_layout Standard
22890 \begin_inset VSpace bigskip
22891 \end_inset
22892
22893
22894 \end_layout
22895
22896 \begin_layout Standard
22897 \noindent
22898 The default numbering for the 
22899 \family sans
22900 Enumerate
22901 \family default
22902  paragraph environment begins with Arabic numbers and ends with uppercase
22903  letters.
22904  Suppose, however, you wanted a different type of numbering scheme.
22905  Here's a quickie example of how to change the numbering scheme:
22906 \end_layout
22907
22908 \begin_layout LyX-Code
22909
22910 \backslash
22911 renewcommand{
22912 \backslash
22913 labelenumi}{
22914 \backslash
22915 Roman{enumi}.}
22916 \end_layout
22917
22918 \begin_layout LyX-Code
22919
22920 \backslash
22921 renewcommand{
22922 \backslash
22923 labelenumii}{
22924 \backslash
22925 Alph{enumii}.}
22926 \end_layout
22927
22928 \begin_layout LyX-Code
22929
22930 \backslash
22931 renewcommand{
22932 \backslash
22933 labelenumiii}{
22934 \backslash
22935 arabic{enumiii}.}
22936 \end_layout
22937
22938 \begin_layout LyX-Code
22939
22940 \backslash
22941 renewcommand{
22942 \backslash
22943 labelenumiv}{
22944 \backslash
22945 alph{enumiv}.)}
22946 \end_layout
22947
22948 \begin_layout Standard
22949 \SpecialChar \ldots{}
22950  which changes the numbering scheme to uppercase Roman numerals, uppercase
22951  letters, Arabic numbers, and lowercase letter.
22952 \end_layout
22953
22954 \begin_layout Standard
22955 Additionally, the previous example also adds a little bit extra to the numbering
22956  scheme.
22957  For example, the first level label actually looks like: 
22958 \begin_inset Quotes eld
22959 \end_inset
22960
22961 I.
22962 \begin_inset Quotes erd
22963 \end_inset
22964
22965 .
22966  For ease of reading, we'll describe what the numbering schemes look like
22967  using a notation something like this: <
22968 \begin_inset Quotes eld
22969 \end_inset
22970
22971 I.
22972 \begin_inset Quotes erd
22973 \end_inset
22974
22975 ,
22976 \begin_inset space ~
22977 \end_inset
22978
22979
22980 \begin_inset Quotes erd
22981 \end_inset
22982
22983 A.
22984 \begin_inset Quotes erd
22985 \end_inset
22986
22987 ,
22988 \begin_inset space ~
22989 \end_inset
22990
22991
22992 \begin_inset Quotes erd
22993 \end_inset
22994
22995 1.
22996 \begin_inset Quotes erd
22997 \end_inset
22998
22999 ,
23000 \begin_inset space ~
23001 \end_inset
23002
23003
23004 \begin_inset Quotes eld
23005 \end_inset
23006
23007 a.)
23008 \begin_inset Quotes erd
23009 \end_inset
23010
23011 >.
23012  
23013 \end_layout
23014
23015 \begin_layout Standard
23016 As you can see in the example, there is a label command for each nesting
23017  level, 
23018 \family typewriter
23019
23020 \backslash
23021 labelenumi
23022 \family default
23023  \SpecialChar \ldots{}
23024  
23025 \family typewriter
23026
23027 \backslash
23028 labelenumiv
23029 \family default
23030 , as well as a counter, 
23031 \family typewriter
23032 enumi
23033 \family default
23034  \SpecialChar \ldots{}
23035  
23036 \family typewriter
23037 enumiv
23038 \family default
23039 .
23040  There are also five 
23041 \begin_inset Quotes eld
23042 \end_inset
23043
23044 number printing
23045 \begin_inset Quotes erd
23046 \end_inset
23047
23048  commands, 
23049 \family typewriter
23050
23051 \backslash
23052 arabic{}
23053 \family default
23054
23055 \family typewriter
23056
23057 \backslash
23058 roman{}
23059 \family default
23060
23061 \family typewriter
23062
23063 \backslash
23064 Roman{}
23065 \family default
23066
23067 \family typewriter
23068
23069 \backslash
23070 alph{}
23071 \family default
23072 , and 
23073 \family typewriter
23074
23075 \backslash
23076 Alph{}
23077 \family default
23078 , each of which take one counter as an argument.
23079  You can add characters before or after these, but there's no need to add
23080  spaces.
23081 \end_layout
23082
23083 \begin_layout Standard
23084 You can get really fancy with these.
23085  For example:
23086 \end_layout
23087
23088 \begin_layout LyX-Code
23089
23090 \backslash
23091 renewcommand{
23092 \backslash
23093 labelenumi}{
23094 \backslash
23095 #
23096 \backslash
23097 Alph{enumi}
23098 \backslash
23099 #}
23100 \end_layout
23101
23102 \begin_layout LyX-Code
23103
23104 \backslash
23105 renewcommand{
23106 \backslash
23107 labelenumii}{
23108 \backslash
23109 Alph{enumi}.
23110 \backslash
23111 arabic{enumii}}
23112 \end_layout
23113
23114 \begin_layout LyX-Code
23115
23116 \backslash
23117 renewcommand{
23118 \backslash
23119 labelenumiii}{
23120 \backslash
23121 alph{enumiii}+}
23122 \end_layout
23123
23124 \begin_layout LyX-Code
23125
23126 \backslash
23127 renewcommand{
23128 \backslash
23129 labelenumiv}{(
23130 \backslash
23131 roman{enumiv})}
23132 \end_layout
23133
23134 \begin_layout Standard
23135 produces the somewhat out of hand numbering scheme: <
23136 \begin_inset Quotes eld
23137 \end_inset
23138
23139 #A#
23140 \begin_inset Quotes erd
23141 \end_inset
23142
23143 ,
23144 \begin_inset space ~
23145 \end_inset
23146
23147
23148 \begin_inset Quotes erd
23149 \end_inset
23150
23151 A.1
23152 \begin_inset Quotes erd
23153 \end_inset
23154
23155 ,
23156 \begin_inset space ~
23157 \end_inset
23158
23159
23160 \begin_inset Quotes erd
23161 \end_inset
23162
23163 a+
23164 \begin_inset Quotes erd
23165 \end_inset
23166
23167 ,
23168 \begin_inset space ~
23169 \end_inset
23170
23171
23172 \begin_inset Quotes eld
23173 \end_inset
23174
23175 (i)
23176 \begin_inset Quotes erd
23177 \end_inset
23178
23179 >.
23180  
23181 \end_layout
23182
23183 \begin_layout Section
23184 Dropped Capitals
23185 \end_layout
23186
23187 \begin_layout Standard
23188 \begin_inset VSpace bigskip
23189 \end_inset
23190
23191
23192 \end_layout
23193
23194 \begin_layout Standard
23195 \noindent
23196 \begin_inset ERT
23197 status collapsed
23198
23199 \begin_layout Plain Layout
23200
23201
23202 \backslash
23203 newfont{
23204 \backslash
23205 tmpfont}{cmr17 scaled 2500}{
23206 \backslash
23207 tmpfont T}
23208 \backslash
23209 vspace*{-8.4ex}
23210 \end_layout
23211
23212 \end_inset
23213
23214
23215 \end_layout
23216
23217 \begin_layout Standard
23218 \noindent
23219 \begin_inset ERT
23220 status open
23221
23222 \begin_layout Plain Layout
23223
23224
23225 \backslash
23226 hangindent=3.3em 
23227 \backslash
23228 hangafter=-3
23229 \end_layout
23230
23231 \end_inset
23232
23233  hose of you who like the style of old books probably also like 
23234 \begin_inset Quotes eld
23235 \end_inset
23236
23237 dropped capitals
23238 \begin_inset Quotes erd
23239 \end_inset
23240
23241 —those large capital letters which begin each new chapter or section.
23242  Implementing them with plain LyX/LaTeX is straightforward (assuming you
23243  know some plain TeX!) but does require a lot of work and many iterations,
23244  as you can see by all the ugly TeX-mode stuff at the beginning of this
23245  paragraph.
23246 \end_layout
23247
23248 \begin_layout Standard
23249 \begin_inset ERT
23250 status open
23251
23252 \begin_layout Plain Layout
23253
23254
23255 \backslash
23256 verb+
23257 \backslash
23258 bigdrop{-1em}{3}{ptmri}{T}+
23259 \end_layout
23260
23261 \end_inset
23262
23263 here is a much easier way of doing this, of course.
23264  The 
23265 \family typewriter
23266 dropcaps
23267 \family default
23268  (or the newer 
23269 \family typewriter
23270 dropping
23271 \family default
23272 ) package from CTAN allows a simple way to add such letters to your documents.
23273  Since this package is not a standard part of TeXLive, I can't demonstrate
23274  it within this document, but if you copy this paragraph to a new document,
23275  delete the 
23276 \begin_inset Quotes eld
23277 \end_inset
23278
23279
23280 \family typewriter
23281
23282 \backslash
23283 verb
23284 \family default
23285
23286 \begin_inset Quotes erd
23287 \end_inset
23288
23289  and the pluses from the TeX code at the beginning of the paragraph, and
23290  add 
23291 \family typewriter
23292
23293 \backslash
23294 usepackage{dropcaps}
23295 \family default
23296  to your LaTeX preamble, you will get a nice Times Roman Italic 
23297 \begin_inset Quotes eld
23298 \end_inset
23299
23300 T
23301 \begin_inset Quotes erd
23302 \end_inset
23303
23304 , whose height is three lines of text and which protrudes 1 em into the
23305  margin.
23306  (Make certain you have copied 
23307 \begin_inset Quotes eld
23308 \end_inset
23309
23310
23311 \family typewriter
23312 dropcaps.sty
23313 \family default
23314
23315 \begin_inset Quotes erd
23316 \end_inset
23317
23318  into a directory where TeX can see it.) The first argument is the amount
23319  of indentation; in this case the negative sign moves it into the margin.
23320  The second argument is the height of the letter in number of lines of text.
23321  The third argument is the font name: virtually anything which has a tfm
23322  file should work (wade through the 
23323 \family typewriter
23324 .../texmf/fonts/tfm
23325 \family default
23326  directory for possibilities).
23327  My personal favorite is 
23328 \begin_inset Quotes eld
23329 \end_inset
23330
23331
23332 \family typewriter
23333 yinit
23334 \family default
23335
23336 \begin_inset Quotes erd
23337 \end_inset
23338
23339 , a fancy German font specifically designed for dropped capitals.
23340  The fourth argument is the letter (or letters) to be dropped.
23341  The 
23342 \family typewriter
23343 dropping
23344 \family default
23345  package also offers the 
23346 \family typewriter
23347
23348 \backslash
23349 bigdrop
23350 \family default
23351  command, as well as a slightly simplified 
23352 \family typewriter
23353
23354 \backslash
23355 dropping
23356 \family default
23357  command.
23358 \end_layout
23359
23360 \begin_layout Section
23361
23362 \lang ngerman
23363 Textumflossene Bilder und Tabellen
23364 \end_layout
23365
23366 \begin_layout Standard
23367
23368 \lang ngerman
23369 Im 
23370 \emph on
23371 Eingebettete Objekte
23372 \emph default
23373  Handbuch werden Umflossene Gleitobjekte beschrieben.
23374  Sie liefern Folgendes:
23375 \end_layout
23376
23377 \begin_layout Standard
23378 \noindent
23379 \align center
23380 \begin_inset Tabular
23381 <lyxtabular version="3" rows="2" columns="2">
23382 <features tabularvalignment="middle">
23383 <column alignment="center" valignment="top" width="0">
23384 <column alignment="center" valignment="top" width="0">
23385 <row>
23386 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23387 \begin_inset Text
23388
23389 \begin_layout Plain Layout
23390 \begin_inset Graphics
23391         filename ../images/dialog-show-new-inset_graphics.png
23392         scale 70
23393         scaleBeforeRotation
23394         BoundingBox 0bp 6bp 22bp 22bp
23395
23396 \end_inset
23397
23398
23399 \end_layout
23400
23401 \end_inset
23402 </cell>
23403 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23404 \begin_inset Text
23405
23406 \begin_layout Plain Layout
23407 text
23408 \end_layout
23409
23410 \end_inset
23411 </cell>
23412 </row>
23413 <row>
23414 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23415 \begin_inset Text
23416
23417 \begin_layout Plain Layout
23418 text
23419 \end_layout
23420
23421 \end_inset
23422 </cell>
23423 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23424 \begin_inset Text
23425
23426 \begin_layout Plain Layout
23427 text
23428 \end_layout
23429
23430 \end_inset
23431 </cell>
23432 </row>
23433 </lyxtabular>
23434
23435 \end_inset
23436
23437  or 
23438 \begin_inset Tabular
23439 <lyxtabular version="3" rows="2" columns="2">
23440 <features tabularvalignment="middle">
23441 <column alignment="center" valignment="top" width="0">
23442 <column alignment="center" valignment="top" width="0">
23443 <row>
23444 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23445 \begin_inset Text
23446
23447 \begin_layout Plain Layout
23448 text
23449 \end_layout
23450
23451 \end_inset
23452 </cell>
23453 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23454 \begin_inset Text
23455
23456 \begin_layout Plain Layout
23457 \begin_inset Graphics
23458         filename ../images/dialog-show-new-inset_graphics.png
23459         scale 70
23460         scaleBeforeRotation
23461         BoundingBox 0bp 6bp 22bp 22bp
23462
23463 \end_inset
23464
23465
23466 \end_layout
23467
23468 \end_inset
23469 </cell>
23470 </row>
23471 <row>
23472 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23473 \begin_inset Text
23474
23475 \begin_layout Plain Layout
23476 text
23477 \end_layout
23478
23479 \end_inset
23480 </cell>
23481 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23482 \begin_inset Text
23483
23484 \begin_layout Plain Layout
23485 text
23486 \end_layout
23487
23488 \end_inset
23489 </cell>
23490 </row>
23491 </lyxtabular>
23492
23493 \end_inset
23494
23495
23496 \end_layout
23497
23498 \begin_layout Standard
23499
23500 \lang ngerman
23501 Wenn Sie aber text richtig um Bilder oder Tabellen fließen lassen wollen,
23502  also auch so etwas:
23503 \lang english
23504
23505 \begin_inset VSpace defskip
23506 \end_inset
23507
23508
23509 \end_layout
23510
23511 \begin_layout Standard
23512 \noindent
23513 \align center
23514 \begin_inset Tabular
23515 <lyxtabular version="3" rows="2" columns="2">
23516 <features tabularvalignment="middle">
23517 <column alignment="center" valignment="top" width="0">
23518 <column alignment="center" valignment="top" width="0">
23519 <row>
23520 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23521 \begin_inset Text
23522
23523 \begin_layout Plain Layout
23524 text
23525 \end_layout
23526
23527 \end_inset
23528 </cell>
23529 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23530 \begin_inset Text
23531
23532 \begin_layout Plain Layout
23533 text
23534 \end_layout
23535
23536 \end_inset
23537 </cell>
23538 </row>
23539 <row>
23540 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23541 \begin_inset Text
23542
23543 \begin_layout Plain Layout
23544 \begin_inset Graphics
23545         filename ../images/dialog-show-new-inset_graphics.png
23546         scale 70
23547         scaleBeforeRotation
23548         BoundingBox 0bp 6bp 22bp 22bp
23549
23550 \end_inset
23551
23552
23553 \end_layout
23554
23555 \end_inset
23556 </cell>
23557 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23558 \begin_inset Text
23559
23560 \begin_layout Plain Layout
23561 text
23562 \end_layout
23563
23564 \end_inset
23565 </cell>
23566 </row>
23567 </lyxtabular>
23568
23569 \end_inset
23570
23571  
23572 \begin_inset Tabular
23573 <lyxtabular version="3" rows="2" columns="2">
23574 <features tabularvalignment="middle">
23575 <column alignment="center" valignment="top" width="0">
23576 <column alignment="center" valignment="top" width="0">
23577 <row>
23578 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23579 \begin_inset Text
23580
23581 \begin_layout Plain Layout
23582 text
23583 \end_layout
23584
23585 \end_inset
23586 </cell>
23587 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23588 \begin_inset Text
23589
23590 \begin_layout Plain Layout
23591 text
23592 \end_layout
23593
23594 \end_inset
23595 </cell>
23596 </row>
23597 <row>
23598 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23599 \begin_inset Text
23600
23601 \begin_layout Plain Layout
23602 text
23603 \end_layout
23604
23605 \end_inset
23606 </cell>
23607 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23608 \begin_inset Text
23609
23610 \begin_layout Plain Layout
23611 \begin_inset Graphics
23612         filename ../images/dialog-show-new-inset_graphics.png
23613         scale 70
23614         scaleBeforeRotation
23615         BoundingBox 0bp 6bp 22bp 22bp
23616
23617 \end_inset
23618
23619
23620 \end_layout
23621
23622 \end_inset
23623 </cell>
23624 </row>
23625 </lyxtabular>
23626
23627 \end_inset
23628
23629  
23630 \begin_inset Tabular
23631 <lyxtabular version="3" rows="2" columns="3">
23632 <features tabularvalignment="middle">
23633 <column alignment="center" valignment="top" width="0">
23634 <column alignment="center" valignment="top" width="0">
23635 <column alignment="center" valignment="top" width="0">
23636 <row>
23637 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23638 \begin_inset Text
23639
23640 \begin_layout Plain Layout
23641 text
23642 \end_layout
23643
23644 \end_inset
23645 </cell>
23646 <cell alignment="center" valignment="top" topline="true" usebox="none">
23647 \begin_inset Text
23648
23649 \begin_layout Plain Layout
23650 \begin_inset Graphics
23651         filename ../images/dialog-show-new-inset_graphics.png
23652         scale 70
23653         scaleBeforeRotation
23654         BoundingBox 0bp 6bp 22bp 22bp
23655
23656 \end_inset
23657
23658
23659 \end_layout
23660
23661 \end_inset
23662 </cell>
23663 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23664 \begin_inset Text
23665
23666 \begin_layout Plain Layout
23667 text
23668 \end_layout
23669
23670 \end_inset
23671 </cell>
23672 </row>
23673 <row>
23674 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23675 \begin_inset Text
23676
23677 \begin_layout Plain Layout
23678 text
23679 \end_layout
23680
23681 \end_inset
23682 </cell>
23683 <cell alignment="center" valignment="top" bottomline="true" usebox="none">
23684 \begin_inset Text
23685
23686 \begin_layout Plain Layout
23687 text
23688 \end_layout
23689
23690 \end_inset
23691 </cell>
23692 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23693 \begin_inset Text
23694
23695 \begin_layout Plain Layout
23696 text
23697 \end_layout
23698
23699 \end_inset
23700 </cell>
23701 </row>
23702 </lyxtabular>
23703
23704 \end_inset
23705
23706  
23707 \begin_inset Tabular
23708 <lyxtabular version="3" rows="2" columns="3">
23709 <features tabularvalignment="middle">
23710 <column alignment="center" valignment="top" width="0">
23711 <column alignment="center" valignment="top" width="0">
23712 <column alignment="center" valignment="top" width="0">
23713 <row>
23714 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23715 \begin_inset Text
23716
23717 \begin_layout Plain Layout
23718 text
23719 \end_layout
23720
23721 \end_inset
23722 </cell>
23723 <cell alignment="center" valignment="top" topline="true" usebox="none">
23724 \begin_inset Text
23725
23726 \begin_layout Plain Layout
23727 text
23728 \end_layout
23729
23730 \end_inset
23731 </cell>
23732 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23733 \begin_inset Text
23734
23735 \begin_layout Plain Layout
23736 text
23737 \end_layout
23738
23739 \end_inset
23740 </cell>
23741 </row>
23742 <row>
23743 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23744 \begin_inset Text
23745
23746 \begin_layout Plain Layout
23747 text
23748 \end_layout
23749
23750 \end_inset
23751 </cell>
23752 <cell alignment="center" valignment="top" bottomline="true" usebox="none">
23753 \begin_inset Text
23754
23755 \begin_layout Plain Layout
23756 \begin_inset Graphics
23757         filename ../images/dialog-show-new-inset_graphics.png
23758         scale 70
23759         scaleBeforeRotation
23760         BoundingBox 0bp 6bp 22bp 22bp
23761
23762 \end_inset
23763
23764
23765 \end_layout
23766
23767 \end_inset
23768 </cell>
23769 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23770 \begin_inset Text
23771
23772 \begin_layout Plain Layout
23773 text
23774 \end_layout
23775
23776 \end_inset
23777 </cell>
23778 </row>
23779 </lyxtabular>
23780
23781 \end_inset
23782
23783
23784 \end_layout
23785
23786 \begin_layout Standard
23787 \noindent
23788 \align center
23789 \begin_inset Tabular
23790 <lyxtabular version="3" rows="3" columns="2">
23791 <features tabularvalignment="middle">
23792 <column alignment="center" valignment="top" width="0">
23793 <column alignment="center" valignment="top" width="0">
23794 <row>
23795 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23796 \begin_inset Text
23797
23798 \begin_layout Plain Layout
23799 text
23800 \end_layout
23801
23802 \end_inset
23803 </cell>
23804 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23805 \begin_inset Text
23806
23807 \begin_layout Plain Layout
23808 text
23809 \end_layout
23810
23811 \end_inset
23812 </cell>
23813 </row>
23814 <row>
23815 <cell alignment="center" valignment="top" leftline="true" usebox="none">
23816 \begin_inset Text
23817
23818 \begin_layout Plain Layout
23819 \begin_inset Graphics
23820         filename ../images/dialog-show-new-inset_graphics.png
23821         scale 70
23822         scaleBeforeRotation
23823         BoundingBox 0bp 6bp 22bp 22bp
23824
23825 \end_inset
23826
23827
23828 \end_layout
23829
23830 \end_inset
23831 </cell>
23832 <cell alignment="center" valignment="top" rightline="true" usebox="none">
23833 \begin_inset Text
23834
23835 \begin_layout Plain Layout
23836 text
23837 \end_layout
23838
23839 \end_inset
23840 </cell>
23841 </row>
23842 <row>
23843 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23844 \begin_inset Text
23845
23846 \begin_layout Plain Layout
23847 text
23848 \end_layout
23849
23850 \end_inset
23851 </cell>
23852 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23853 \begin_inset Text
23854
23855 \begin_layout Plain Layout
23856 text
23857 \end_layout
23858
23859 \end_inset
23860 </cell>
23861 </row>
23862 </lyxtabular>
23863
23864 \end_inset
23865
23866  
23867 \begin_inset Tabular
23868 <lyxtabular version="3" rows="3" columns="3">
23869 <features tabularvalignment="middle">
23870 <column alignment="center" valignment="top" width="0">
23871 <column alignment="center" valignment="top" width="0">
23872 <column alignment="center" valignment="top" width="0">
23873 <row>
23874 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23875 \begin_inset Text
23876
23877 \begin_layout Plain Layout
23878 text
23879 \end_layout
23880
23881 \end_inset
23882 </cell>
23883 <cell alignment="center" valignment="top" topline="true" usebox="none">
23884 \begin_inset Text
23885
23886 \begin_layout Plain Layout
23887 text
23888 \end_layout
23889
23890 \end_inset
23891 </cell>
23892 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23893 \begin_inset Text
23894
23895 \begin_layout Plain Layout
23896 text
23897 \end_layout
23898
23899 \end_inset
23900 </cell>
23901 </row>
23902 <row>
23903 <cell alignment="center" valignment="top" leftline="true" usebox="none">
23904 \begin_inset Text
23905
23906 \begin_layout Plain Layout
23907 text
23908 \end_layout
23909
23910 \end_inset
23911 </cell>
23912 <cell alignment="center" valignment="top" usebox="none">
23913 \begin_inset Text
23914
23915 \begin_layout Plain Layout
23916 \begin_inset Graphics
23917         filename ../images/dialog-show-new-inset_graphics.png
23918         scale 70
23919         scaleBeforeRotation
23920         BoundingBox 0bp 6bp 22bp 22bp
23921
23922 \end_inset
23923
23924
23925 \end_layout
23926
23927 \end_inset
23928 </cell>
23929 <cell alignment="center" valignment="top" rightline="true" usebox="none">
23930 \begin_inset Text
23931
23932 \begin_layout Plain Layout
23933 text
23934 \end_layout
23935
23936 \end_inset
23937 </cell>
23938 </row>
23939 <row>
23940 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
23941 \begin_inset Text
23942
23943 \begin_layout Plain Layout
23944 text
23945 \end_layout
23946
23947 \end_inset
23948 </cell>
23949 <cell alignment="center" valignment="top" bottomline="true" usebox="none">
23950 \begin_inset Text
23951
23952 \begin_layout Plain Layout
23953 text
23954 \end_layout
23955
23956 \end_inset
23957 </cell>
23958 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
23959 \begin_inset Text
23960
23961 \begin_layout Plain Layout
23962 text
23963 \end_layout
23964
23965 \end_inset
23966 </cell>
23967 </row>
23968 </lyxtabular>
23969
23970 \end_inset
23971
23972  
23973 \begin_inset Tabular
23974 <lyxtabular version="3" rows="3" columns="2">
23975 <features tabularvalignment="middle">
23976 <column alignment="center" valignment="top" width="0">
23977 <column alignment="center" valignment="top" width="0">
23978 <row>
23979 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
23980 \begin_inset Text
23981
23982 \begin_layout Plain Layout
23983 text
23984 \end_layout
23985
23986 \end_inset
23987 </cell>
23988 <cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
23989 \begin_inset Text
23990
23991 \begin_layout Plain Layout
23992 text
23993 \end_layout
23994
23995 \end_inset
23996 </cell>
23997 </row>
23998 <row>
23999 <cell alignment="center" valignment="top" leftline="true" usebox="none">
24000 \begin_inset Text
24001
24002 \begin_layout Plain Layout
24003 text
24004 \end_layout
24005
24006 \end_inset
24007 </cell>
24008 <cell alignment="center" valignment="top" rightline="true" usebox="none">
24009 \begin_inset Text
24010
24011 \begin_layout Plain Layout
24012 \begin_inset Graphics
24013         filename ../images/dialog-show-new-inset_graphics.png
24014         scale 70
24015         scaleBeforeRotation
24016         BoundingBox 0bp 6bp 22bp 22bp
24017
24018 \end_inset
24019
24020
24021 \end_layout
24022
24023 \end_inset
24024 </cell>
24025 </row>
24026 <row>
24027 <cell alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
24028 \begin_inset Text
24029
24030 \begin_layout Plain Layout
24031 text
24032 \end_layout
24033
24034 \end_inset
24035 </cell>
24036 <cell alignment="center" valignment="top" bottomline="true" rightline="true" usebox="none">
24037 \begin_inset Text
24038
24039 \begin_layout Plain Layout
24040 text
24041 \end_layout
24042
24043 \end_inset
24044 </cell>
24045 </row>
24046 </lyxtabular>
24047
24048 \end_inset
24049
24050
24051 \end_layout
24052
24053 \begin_layout Standard
24054 \noindent
24055
24056 \lang ngerman
24057 sollten Sie das LaTeX-Paket 
24058 \family sans
24059 picinpar
24060 \family default
24061  benutzen.
24062  Hier ist ein Beispiel:
24063 \end_layout
24064
24065 \begin_layout Standard
24066 \begin_inset ERT
24067 status collapsed
24068
24069 \begin_layout Plain Layout
24070
24071
24072 \backslash
24073 ifpicinpar
24074 \end_layout
24075
24076 \end_inset
24077
24078
24079 \lang ngerman
24080
24081 \begin_inset Note Note
24082 status open
24083
24084 \begin_layout Plain Layout
24085
24086 \lang ngerman
24087 Das folgende Beispiel wird nur gedruckt, wenn das LaTeX-Paket 
24088 \family typewriter
24089 picinpar
24090 \family default
24091  installiert ist.
24092 \end_layout
24093
24094 \end_inset
24095
24096
24097 \end_layout
24098
24099 \begin_layout Standard
24100 \begin_inset ERT
24101 status collapsed
24102
24103 \begin_layout Plain Layout
24104
24105
24106 \backslash
24107 begin{window}[2,c,{
24108 \end_layout
24109
24110 \end_inset
24111
24112
24113 \begin_inset Graphics
24114         filename clipart/mobius.eps
24115         width 40col%
24116         scaleBeforeRotation
24117         rotateOrigin center
24118
24119 \end_inset
24120
24121
24122 \begin_inset ERT
24123 status collapsed
24124
24125 \begin_layout Plain Layout
24126
24127 },{}]
24128 \end_layout
24129
24130 \begin_layout Plain Layout
24131
24132
24133 \backslash
24134 hspace{-1em}
24135 \end_layout
24136
24137 \end_inset
24138
24139
24140 \begin_inset ERT
24141 status collapsed
24142
24143 \begin_layout Plain Layout
24144
24145
24146 \backslash
24147 hspace*{1em}
24148 \end_layout
24149
24150 \end_inset
24151
24152
24153 \lang ngerman
24154 Textumflossene Bilder oder Tabellen sind keine Gleitobjekte, weil sie dort
24155  gedruckt werden, wo sie definiert wurden.
24156  Dieser Typ wird benutzt, um text um eine Abbildung herum 
24157 \emph on
24158 fließen
24159 \emph default
24160  zu lassen, wobei der text nur den Teil der Zeile benutzt, den die Abbildung
24161  übrig lässt.
24162  Er wird so eingefügt, wie Sie hier sehen, wenn das La\SpecialChar \-
24163 TeX-Paket 
24164 \family typewriter
24165 picinpar
24166 \family default
24167  installiert ist.
24168  Der erste Parameter in der eckigen
24169 \begin_inset Newline linebreak
24170 \end_inset
24171
24172 Klammer, hier 2, definiert die Anzahl der Zeilen über dem Bild, der zweite,
24173  hier c, die Position des Bildes.
24174  Die Abbildung nimmt 40
24175 \begin_inset space \thinspace{}
24176 \end_inset
24177
24178 % der Spaltenbreite ein.
24179  Weitere Einzelheiten finden Sie in der Dokumentation von 
24180 \family typewriter
24181 picinpar
24182 \family default
24183 .
24184  Die Bildparameter können Sie mit einem Klick auf das Bild wie gewohnt ändern.
24185 \lang english
24186
24187 \begin_inset ERT
24188 status collapsed
24189
24190 \begin_layout Plain Layout
24191
24192
24193 \backslash
24194 end{window}
24195 \end_layout
24196
24197 \end_inset
24198
24199
24200 \end_layout
24201
24202 \begin_layout Standard
24203 \begin_inset ERT
24204 status collapsed
24205
24206 \begin_layout Plain Layout
24207
24208
24209 \backslash
24210 else
24211 \end_layout
24212
24213 \end_inset
24214
24215
24216 \lang ngerman
24217
24218 \begin_inset Note Note
24219 status open
24220
24221 \begin_layout Plain Layout
24222
24223 \lang ngerman
24224 Der folgende Teil wird gedruckt, wenn das LaTeX-Paket 
24225 \family typewriter
24226 picinpar
24227 \family default
24228  nicht installiert ist:
24229 \end_layout
24230
24231 \end_inset
24232
24233
24234 \end_layout
24235
24236 \begin_layout Standard
24237
24238 \lang ngerman
24239 Sie müssen das LaTeX-Paket 
24240 \family typewriter
24241 picinpar
24242 \family default
24243  installiert haben, um das Beispiel in der Ausgabe zu sehen.
24244 \end_layout
24245
24246 \begin_layout Standard
24247 \begin_inset ERT
24248 status collapsed
24249
24250 \begin_layout Plain Layout
24251
24252
24253 \backslash
24254 fi
24255 \end_layout
24256
24257 \end_inset
24258
24259
24260 \end_layout
24261
24262 \begin_layout Section
24263 Non-standard Paragraph Shapes
24264 \end_layout
24265
24266 \begin_layout Standard
24267 \begin_inset VSpace bigskip
24268 \end_inset
24269
24270
24271 \end_layout
24272
24273 \begin_layout Standard
24274 \begin_inset ERT
24275 status collapsed
24276
24277 \begin_layout Plain Layout
24278
24279
24280 \backslash
24281 begin{sloppypar}
24282 \end_layout
24283
24284 \end_inset
24285
24286
24287 \end_layout
24288
24289 \begin_layout Standard
24290 \begin_inset ERT
24291 status collapsed
24292
24293 \begin_layout Plain Layout
24294
24295
24296 \backslash
24297 newdimen
24298 \backslash
24299 varunit 
24300 \end_layout
24301
24302 \begin_layout Plain Layout
24303
24304
24305 \backslash
24306 setlength{
24307 \backslash
24308 varunit}{4.5in}
24309 \end_layout
24310
24311 \end_inset
24312
24313
24314 \end_layout
24315
24316 \begin_layout Standard
24317 \noindent
24318 \begin_inset ERT
24319 status collapsed
24320
24321 \begin_layout Plain Layout
24322
24323
24324 \backslash
24325 parshape 19 0.45
24326 \backslash
24327 varunit 0.332
24328 \backslash
24329 varunit
24330 \end_layout
24331
24332 \begin_layout Plain Layout
24333
24334 0.40
24335 \backslash
24336 varunit 0.300
24337 \backslash
24338 varunit
24339 \end_layout
24340
24341 \begin_layout Plain Layout
24342
24343 0.35
24344 \backslash
24345 varunit 0.293
24346 \backslash
24347 varunit
24348 \end_layout
24349
24350 \begin_layout Plain Layout
24351
24352 0.30
24353 \backslash
24354 varunit 0.300
24355 \backslash
24356 varunit
24357 \end_layout
24358
24359 \begin_layout Plain Layout
24360
24361 0.25
24362 \backslash
24363 varunit 0.317
24364 \backslash
24365 varunit
24366 \end_layout
24367
24368 \begin_layout Plain Layout
24369
24370 0.20
24371 \backslash
24372 varunit 0.342
24373 \backslash
24374 varunit
24375 \end_layout
24376
24377 \begin_layout Plain Layout
24378
24379 0.15
24380 \backslash
24381 varunit 0.373
24382 \backslash
24383 varunit
24384 \end_layout
24385
24386 \begin_layout Plain Layout
24387
24388 0.10
24389 \backslash
24390 varunit 0.410
24391 \backslash
24392 varunit
24393 \end_layout
24394
24395 \begin_layout Plain Layout
24396
24397 0.05
24398 \backslash
24399 varunit 0.453
24400 \backslash
24401 varunit
24402 \end_layout
24403
24404 \begin_layout Plain Layout
24405
24406 0.00
24407 \backslash
24408 varunit 0.500
24409 \backslash
24410 varunit
24411 \end_layout
24412
24413 \begin_layout Plain Layout
24414
24415 0.05
24416 \backslash
24417 varunit 0.453
24418 \backslash
24419 varunit
24420 \end_layout
24421
24422 \begin_layout Plain Layout
24423
24424 0.10
24425 \backslash
24426 varunit 0.410
24427 \backslash
24428 varunit
24429 \end_layout
24430
24431 \begin_layout Plain Layout
24432
24433 0.15
24434 \backslash
24435 varunit 0.373
24436 \backslash
24437 varunit
24438 \end_layout
24439
24440 \begin_layout Plain Layout
24441
24442 0.20
24443 \backslash
24444 varunit 0.342
24445 \backslash
24446 varunit
24447 \end_layout
24448
24449 \begin_layout Plain Layout
24450
24451 0.25
24452 \backslash
24453 varunit 0.317
24454 \backslash
24455 varunit
24456 \end_layout
24457
24458 \begin_layout Plain Layout
24459
24460 0.30
24461 \backslash
24462 varunit 0.300
24463 \backslash
24464 varunit
24465 \end_layout
24466
24467 \begin_layout Plain Layout
24468
24469 0.35
24470 \backslash
24471 varunit 0.293
24472 \backslash
24473 varunit
24474 \end_layout
24475
24476 \begin_layout Plain Layout
24477
24478 0.40
24479 \backslash
24480 varunit 0.300
24481 \backslash
24482 varunit
24483 \end_layout
24484
24485 \begin_layout Plain Layout
24486
24487 0.45
24488 \backslash
24489 varunit 0.332
24490 \backslash
24491 varunit
24492 \end_layout
24493
24494 \begin_layout Plain Layout
24495
24496 \end_layout
24497
24498 \end_inset
24499
24500 There are times when the tyranny of rectangular paragraphs must be overthrown.
24501  In such situations, a call to the delightful plain TeX command 
24502 \family typewriter
24503
24504 \backslash
24505 parshape
24506 \family default
24507  is called for.
24508  As you can see, completely arbitrary shapes can be laid out with a suitable
24509  set of linelength definitions.
24510  While this parshape may look a bit silly and useless, one could conceive
24511  of situations such as finely tuned dropped capitals, word wrapping around
24512  non-rectangular graphics, etc.
24513  which will benefit from such handcrafting.
24514 \end_layout
24515
24516 \begin_layout Standard
24517 \begin_inset VSpace bigskip
24518 \end_inset
24519
24520
24521 \end_layout
24522
24523 \begin_layout Standard
24524 The syntax is 
24525 \family typewriter
24526
24527 \backslash
24528 parshape numlines #1indent #1length #2indent #2length \SpecialChar \ldots{}
24529  #nindent #nlength
24530 \family default
24531 , where 
24532 \family typewriter
24533 numlines
24534 \family default
24535  is the number of lines of text which define the paragraph.
24536  If there turn out to be fewer lines, the shape is truncated; if there are
24537  more, the excess lines have the same dimensions as the last line of the
24538  definition.
24539  The 
24540 \family typewriter
24541 #nindent
24542 \family default
24543  and 
24544 \family typewriter
24545 #nlength
24546 \family default
24547  entries specify the indentation of the line from the left margin, and the
24548  length of the line as measured from that point.
24549  The shape applies only to the current paragraph; everything is reset to
24550  normal for the next paragraph.
24551 \end_layout
24552
24553 \begin_layout Standard
24554 \begin_inset ERT
24555 status collapsed
24556
24557 \begin_layout Plain Layout
24558
24559
24560 \backslash
24561 end{sloppypar}
24562 \end_layout
24563
24564 \end_inset
24565
24566
24567 \end_layout
24568
24569 \end_body
24570 \end_document