]> git.lyx.org Git - lyx.git/blob - lib/doc/Additional.lyx
Check path of Qt tools if qtchooser is detected
[lyx.git] / lib / doc / Additional.lyx
1 #LyX 2.3 created this file. For more info see http://www.lyx.org/
2 \lyxformat 511
3 \begin_document
4 \begin_header
5 \save_transient_properties true
6 \origin /systemlyxdir/doc/
7 \textclass scrbook
8 \begin_preamble
9 % DO NOT ALTER THIS PREAMBLE!!!
10 %
11 % This preamble is designed to ensure that the manual prints
12 % out as advertised. If you mess with this preamble,
13 % parts of the manual may not print out as expected.  If you
14 % have problems LaTeXing this file, please contact 
15 % the documentation team
16 % email: lyx-docs@lists.lyx.org
17
18 % the pages of the TOC are numbered roman
19 % and a PDF-bookmark for the TOC is added
20 \pagenumbering{roman}
21 \let\myTOC\tableofcontents
22 \renewcommand{\tableofcontents}{%
23  \pdfbookmark[1]{\contentsname}{}
24  \myTOC
25  \cleardoublepage
26  \pagenumbering{arabic}}
27
28 % extra space for tables
29 \newcommand{\extratablespace}[1]{\noalign{\vskip#1}}
30 \end_preamble
31 \options fleqn,bibliography=totoc,index=totoc,BCOR7.5mm,titlepage,captions=tableheading
32 \use_default_options false
33 \begin_modules
34 logicalmkup
35 theorems-ams
36 theorems-ams-extended
37 multicol
38 shapepar
39 \end_modules
40 \maintain_unincluded_children false
41 \language english
42 \language_package default
43 \inputencoding auto
44 \fontencoding global
45 \font_roman "lmodern" "default"
46 \font_sans "lmss" "default"
47 \font_typewriter "lmtt" "default"
48 \font_math "auto" "auto"
49 \font_default_family default
50 \use_non_tex_fonts false
51 \font_sc false
52 \font_osf false
53 \font_sf_scale 100 100
54 \font_tt_scale 100 100
55 \use_microtype false
56 \graphics default
57 \default_output_format pdf2
58 \output_sync 0
59 \bibtex_command default
60 \index_command default
61 \paperfontsize 12
62 \spacing single
63 \use_hyperref true
64 \pdf_title "LyX's Additional Features manual"
65 \pdf_author "LyX Team"
66 \pdf_subject "LyX's additional features documentation"
67 \pdf_keywords "LyX, Documentation, Additional"
68 \pdf_bookmarks true
69 \pdf_bookmarksnumbered true
70 \pdf_bookmarksopen false
71 \pdf_bookmarksopenlevel 1
72 \pdf_breaklinks false
73 \pdf_pdfborder false
74 \pdf_colorlinks true
75 \pdf_backref false
76 \pdf_pdfusetitle false
77 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
78 \papersize a4paper
79 \use_geometry false
80 \use_package amsmath 1
81 \use_package amssymb 1
82 \use_package cancel 0
83 \use_package esint 0
84 \use_package mathdots 1
85 \use_package mathtools 0
86 \use_package mhchem 1
87 \use_package stackrel 0
88 \use_package stmaryrd 0
89 \use_package undertilde 0
90 \cite_engine basic
91 \cite_engine_type default
92 \biblio_style plain
93 \use_bibtopic false
94 \use_indices false
95 \paperorientation portrait
96 \suppress_date false
97 \justification true
98 \use_refstyle 0
99 \notefontcolor #0000ff
100 \index Index
101 \shortcut idx
102 \color #008000
103 \end_index
104 \secnumdepth 3
105 \tocdepth 3
106 \paragraph_separation indent
107 \paragraph_indentation default
108 \quotes_language english
109 \papercolumns 1
110 \papersides 2
111 \paperpagestyle headings
112 \tracking_changes true
113 \output_changes false
114 \html_math_output 0
115 \html_css_as_file 0
116 \html_be_strict true
117 \author 893223064 "John Robert Hudson" j.r.hudson@virginmedia.com
118 \end_header
119
120 \begin_body
121
122 \begin_layout Title
123 Additional \SpecialChar LyX
124  Features
125 \end_layout
126
127 \begin_layout Subtitle
128 Version 2.3.x
129 \end_layout
130
131 \begin_layout Author
132 by the \SpecialChar LyX
133  Team
134 \begin_inset Foot
135 status collapsed
136
137 \begin_layout Plain Layout
138 \noindent
139 Principal maintainer of this file is
140 \noun on
141  Richard Heck
142 \noun default
143 .
144  If you have comments or error corrections, please send them to the \SpecialChar LyX
145  Documentati
146 on mailing list, 
147 \begin_inset Flex Code
148 status collapsed
149
150 \begin_layout Plain Layout
151 \noindent
152 <lyx-docs@lists.lyx.org>
153 \end_layout
154
155 \end_inset
156
157 .
158 \end_layout
159
160 \end_inset
161
162
163 \end_layout
164
165 \begin_layout Standard
166 \begin_inset CommandInset toc
167 LatexCommand tableofcontents
168
169 \end_inset
170
171
172 \end_layout
173
174 \begin_layout Chapter
175 Introduction
176 \end_layout
177
178 \begin_layout Standard
179 This manual is essentially Part II of the 
180 \emph on
181 User's Guide\SpecialChar endofsentence
182
183 \emph default
184  The reason for separating the two documents is simple: the 
185 \emph on
186 User's Guide
187 \emph default
188  is already quite lengthy, and it contains information on all of the basic
189  features one needs to know in order to prepare most documents.
190  However, the \SpecialChar LyX
191  Team has worked to make \SpecialChar LyX
192  extensible through various configuration
193  files and external packages.
194  That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
195  package, you can
196  create a layout file (or module) for it without having to alter \SpecialChar LyX
197  itself.
198  We've already had contributions of several new features this way, and some
199  of them are documented here.
200  There are also some more `advanced' features, such as how to control the
201  presentation of bibliographies and how to work with multi-part documents,
202  that are not covered in the 
203 \emph on
204 User's Guide
205 \emph default
206  and are discussed here.
207 \end_layout
208
209 \begin_layout Standard
210 This manual also documents some special features, like fax support, version
211  control, and SGML support, which require additional software to work properly.
212  There is also a chapter on \SpecialChar LyX
213 's support for HTML.
214  And lastly, there's a chapter of \SpecialChar LaTeX
215  tools and tips, things you can use to
216  spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
217 .
218  After all, \SpecialChar LyX
219  
220 \emph on
221 is
222 \emph default
223  only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
224  features.
225 \end_layout
226
227 \begin_layout Standard
228 If you haven't read the 
229 \emph on
230 Introduction
231 \emph default
232  yet, you are definitely in the wrong manual.
233  The 
234 \emph on
235 Introduction
236 \emph default
237  is the first place to go, since it describes the notation and format of
238  all of the manuals.
239  You should also be thoroughly familiar with the 
240 \emph on
241 User's Guide
242 \emph default
243  and all of the basic features of \SpecialChar LyX
244  before attempting to read this one.
245 \end_layout
246
247 \begin_layout Standard
248 Since many of the topics in this manual depend heavily on \SpecialChar LyX
249 's interaction
250  with \SpecialChar LaTeX
251 , this first chapter covers the inner workings of \SpecialChar LyX
252  and how to direct
253  \SpecialChar LyX
254  to generate exactly the \SpecialChar LaTeX
255  code you want.
256  It is obviously for more seasoned \SpecialChar LyX
257  users.
258 \end_layout
259
260 \begin_layout Chapter
261 \SpecialChar LyX
262  and \SpecialChar LaTeX
263
264 \end_layout
265
266 \begin_layout Section
267 How \SpecialChar LyX
268  Uses \SpecialChar LaTeX
269
270 \end_layout
271
272 \begin_layout Standard
273 This chapter is for both \SpecialChar TeX
274 -nicians and the \SpecialChar LaTeX
275 -curious.
276  In it, we'll explain how \SpecialChar LyX
277  and \SpecialChar LaTeX
278  work together to produce printable output.
279  This is the only place in any of the manuals where we assume you know something
280  about \SpecialChar LaTeX
281 .
282 \end_layout
283
284 \begin_layout Standard
285 At one time, \SpecialChar LyX
286  was called a 
287 \begin_inset Quotes eld
288 \end_inset
289
290 WYSIWYM frontend to \SpecialChar LaTeX
291 ,
292 \begin_inset Quotes erd
293 \end_inset
294
295  but that's no longer true.
296  There are frontends to \SpecialChar LaTeX
297  out there.
298 \begin_inset Foot
299 status collapsed
300
301 \begin_layout Plain Layout
302 Some familar ones are \SpecialChar TeX
303 maker and kile, on Linux, and \SpecialChar TeX
304 shop, OSX.
305  There are also the \SpecialChar LaTeX
306  modes for vi and emacs, of course.
307 \end_layout
308
309 \end_inset
310
311  These are basically text editors with the ability to run \SpecialChar LaTeX
312  and mark any
313  errors in the file you're editing.
314  Although \SpecialChar LyX
315  
316 \emph on
317 is
318 \emph default
319  an editor, and it 
320 \emph on
321 does
322 \emph default
323  run \SpecialChar LaTeX
324 , and it also indicates errors in the file, it also does much, much
325  more.
326  For one thing, you don't need to know \SpecialChar LaTeX
327  to use \SpecialChar LyX
328  effectively.
329  And \SpecialChar LyX
330  has added its own extensions to \SpecialChar LaTeX
331 .
332  Try the following sometime: select 
333 \begin_inset Flex Noun
334 status collapsed
335
336 \begin_layout Plain Layout
337 Export\SpecialChar menuseparator
338 LaTeX
339 \end_layout
340
341 \end_inset
342
343  from the 
344 \begin_inset Flex Noun
345 status collapsed
346
347 \begin_layout Plain Layout
348 File
349 \end_layout
350
351 \end_inset
352
353  menu (or 
354 \begin_inset Flex Noun
355 status collapsed
356
357 \begin_layout Plain Layout
358 View\SpecialChar menuseparator
359 Source
360 \begin_inset space ~
361 \end_inset
362
363 Pane
364 \end_layout
365
366 \end_inset
367
368 ), then look at the preamble of the resulting 
369 \begin_inset Flex Code
370 status collapsed
371
372 \begin_layout Plain Layout
373 .tex
374 \end_layout
375
376 \end_inset
377
378  file.
379  You'll notice a variety of new macros defined specifically by \SpecialChar LyX
380 .
381  These macros are defined automatically, according to the features you use
382  in the document.
383 \end_layout
384
385 \begin_layout Standard
386 There are several commands that automatically invoke \SpecialChar LaTeX
387 .
388  They are:
389 \end_layout
390
391 \begin_layout Itemize
392 \begin_inset Flex Noun
393 status collapsed
394
395 \begin_layout Plain Layout
396 Document\SpecialChar menuseparator
397 View
398 \end_layout
399
400 \end_inset
401
402
403 \end_layout
404
405 \begin_layout Itemize
406 \begin_inset Flex Noun
407 status collapsed
408
409 \begin_layout Plain Layout
410 Document\SpecialChar menuseparator
411 Update
412 \end_layout
413
414 \end_inset
415
416
417 \end_layout
418
419 \begin_layout Standard
420 They will only invoke \SpecialChar LaTeX
421  if the file has changed since the last time \SpecialChar LaTeX
422  was
423  run.
424  
425 \end_layout
426
427 \begin_layout Standard
428 When \SpecialChar LyX
429  runs \SpecialChar LaTeX
430  on the file you're editing, it performs these steps:
431 \end_layout
432
433 \begin_layout Enumerate
434 Convert the document to \SpecialChar LaTeX
435  and save to a file with the extension 
436 \begin_inset Flex Code
437 status collapsed
438
439 \begin_layout Plain Layout
440 .tex
441 \end_layout
442
443 \end_inset
444
445  in place of 
446 \begin_inset Flex Code
447 status collapsed
448
449 \begin_layout Plain Layout
450 .lyx
451 \end_layout
452
453 \end_inset
454
455 .
456 \end_layout
457
458 \begin_layout Enumerate
459 Run \SpecialChar LaTeX
460  on the 
461 \begin_inset Flex Code
462 status collapsed
463
464 \begin_layout Plain Layout
465 .tex
466 \end_layout
467
468 \end_inset
469
470  file (maybe several times), and run any other commands (such as 
471 \begin_inset Flex Code
472 status collapsed
473
474 \begin_layout Plain Layout
475 bibtex
476 \end_layout
477
478 \end_inset
479
480  or 
481 \begin_inset Flex Code
482 status collapsed
483
484 \begin_layout Plain Layout
485 makeindex
486 \end_layout
487
488 \end_inset
489
490 ) needed to compile the \SpecialChar LaTeX
491  file.
492 \end_layout
493
494 \begin_layout Enumerate
495 If there are any errors, show the error log.
496 \end_layout
497
498 \begin_layout Standard
499 If you have run \SpecialChar LaTeX
500  using 
501 \begin_inset Flex Noun
502 status collapsed
503
504 \begin_layout Plain Layout
505 View\SpecialChar menuseparator
506 DVI
507 \end_layout
508
509 \end_inset
510
511 , \SpecialChar LyX
512  then runs a DVI viewer to display the DVI-file.
513  If you have used 
514 \begin_inset Flex Noun
515 status collapsed
516
517 \begin_layout Plain Layout
518 View\SpecialChar menuseparator
519 PostScript
520 \end_layout
521
522 \end_inset
523
524 , \SpecialChar LyX
525  performs further steps:
526 \end_layout
527
528 \begin_layout Itemize
529 Run 
530 \begin_inset Flex Code
531 status collapsed
532
533 \begin_layout Plain Layout
534 dvips
535 \end_layout
536
537 \end_inset
538
539  to convert the DVI file to PostScript.
540 \end_layout
541
542 \begin_layout Itemize
543 Run a PostScript viewer, such as 
544 \begin_inset Flex Code
545 status collapsed
546
547 \begin_layout Plain Layout
548 ghostview
549 \end_layout
550
551 \end_inset
552
553 , to display the PostScript file.
554 \end_layout
555
556 \begin_layout Standard
557 \SpecialChar LyX
558  does similar things when viewing, or exporting, other formats.
559 \end_layout
560
561 \begin_layout Section
562 Translating \SpecialChar LaTeX
563  files into \SpecialChar LyX
564
565 \end_layout
566
567 \begin_layout Standard
568 You can import a \SpecialChar LaTeX
569  file into \SpecialChar LyX
570  by using the 
571 \begin_inset Flex Noun
572 status collapsed
573
574 \begin_layout Plain Layout
575 File\SpecialChar menuseparator
576 Import\SpecialChar menuseparator
577 LaTeX
578 \end_layout
579
580 \end_inset
581
582  command in \SpecialChar LyX
583 .
584  This will call a program named 
585 \begin_inset Flex Code
586 status collapsed
587
588 \begin_layout Plain Layout
589 tex2lyx
590 \end_layout
591
592 \end_inset
593
594  which will create a file 
595 \begin_inset Flex Code
596 status collapsed
597
598 \begin_layout Plain Layout
599 foo.lyx
600 \end_layout
601
602 \end_inset
603
604  from the file 
605 \begin_inset Flex Code
606 status collapsed
607
608 \begin_layout Plain Layout
609 foo.tex
610 \end_layout
611
612 \end_inset
613
614 .
615  \SpecialChar LyX
616  will then open that file.
617 \begin_inset Foot
618 status collapsed
619
620 \begin_layout Plain Layout
621 \begin_inset Flex Code
622 status collapsed
623
624 \begin_layout Plain Layout
625 tex2lyx
626 \end_layout
627
628 \end_inset
629
630  can also be run from the command line, of course.
631 \end_layout
632
633 \end_inset
634
635
636 \end_layout
637
638 \begin_layout Standard
639 \begin_inset Flex Code
640 status collapsed
641
642 \begin_layout Plain Layout
643 tex2lyx
644 \end_layout
645
646 \end_inset
647
648  will translate most legal \SpecialChar LaTeX
649 , but not everything.
650  It will put things it doesn't understand into \SpecialChar TeX
651  code, so after translating
652  a file with 
653 \begin_inset Flex Code
654 status collapsed
655
656 \begin_layout Plain Layout
657 tex2lyx
658 \end_layout
659
660 \end_inset
661
662 , you can look for \SpecialChar TeX
663  code and hand-edit it until it looks right.
664 \end_layout
665
666 \begin_layout Standard
667 If you don't know what \SpecialChar TeX
668  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 \SpecialChar TeX
679  Code into \SpecialChar LyX
680  Documents 
681 \end_layout
682
683 \begin_layout Standard
684 Anything you can do in \SpecialChar LaTeX
685  you can do in \SpecialChar LyX
686 , for a very simple reason: You can
687  always insert \SpecialChar TeX
688  code into any \SpecialChar LyX
689  document.
690  \SpecialChar LyX
691  cannot, and will never be able to, display every possible \SpecialChar LaTeX
692  construct.
693  If ever you need to insert \SpecialChar LaTeX
694  commands into your \SpecialChar LyX
695  document, you can use the
696  
697 \begin_inset Flex Code
698 status collapsed
699
700 \begin_layout Plain Layout
701 \SpecialChar TeX
702  Code
703 \end_layout
704
705 \end_inset
706
707  box, which you can insert into your document with 
708 \begin_inset Flex Noun
709 status collapsed
710
711 \begin_layout Plain Layout
712 Insert\SpecialChar menuseparator
713
714 \family sans
715 TeX
716 \family default
717  Code
718 \end_layout
719
720 \end_inset
721
722  or the keyboard shortcut 
723 \begin_inset Info
724 type  "shortcut"
725 arg   "ert-insert"
726 \end_inset
727
728 .
729 \end_layout
730
731 \begin_layout Standard
732 Here's an example of inserting \SpecialChar LaTeX
733  commands in a \SpecialChar LyX
734  document.
735  The code looks like this:
736 \end_layout
737
738 \begin_layout LyX-Code
739
740 \backslash
741 begin{tabular}{ll}
742 \begin_inset Newline newline
743 \end_inset
744
745
746 \backslash
747 begin{minipage}{5cm}
748 \begin_inset Newline newline
749 \end_inset
750
751 This is an example of a minipage environment.
752  You 
753 \begin_inset Newline newline
754 \end_inset
755
756 can put nearly everything in it, even (non-floating) 
757 \begin_inset Newline newline
758 \end_inset
759
760 figures and tables.
761  
762 \begin_inset Newline newline
763 \end_inset
764
765
766 \backslash
767 end{minipage}
768 \begin_inset Newline newline
769 \end_inset
770
771 &
772 \begin_inset Newline newline
773 \end_inset
774
775
776 \backslash
777 begin{minipage}{5cm}
778 \begin_inset Newline newline
779 \end_inset
780
781
782 \backslash
783 begin{verbatim}
784 \begin_inset Newline newline
785 \end_inset
786
787
788 \backslash
789 begin{minipage}{5cm}
790 \begin_inset Newline newline
791 \end_inset
792
793 This ...
794  
795 \begin_inset Newline newline
796 \end_inset
797
798
799 \backslash
800 end{minipage}
801 \begin_inset Newline newline
802 \end_inset
803
804
805 \backslash
806 end{verbatim}
807 \begin_inset Newline newline
808 \end_inset
809
810
811 \backslash
812 end{minipage}
813 \begin_inset Newline newline
814 \end_inset
815
816
817 \backslash
818 end{tabular}
819 \end_layout
820
821 \begin_layout LyX-Code
822
823 \end_layout
824
825 \begin_layout Standard
826 The 
827 \begin_inset Flex Code
828 status collapsed
829
830 \begin_layout Plain Layout
831 \SpecialChar TeX
832  Code
833 \end_layout
834
835 \end_inset
836
837  box containing this text is directly after this paragraph.
838  Those of you reading the manual in \SpecialChar LyX
839  will only see the \SpecialChar TeX
840  code inset.
841  Those reading a printed version of the manuals will see the actual results:
842 \begin_inset VSpace bigskip
843 \end_inset
844
845
846 \end_layout
847
848 \begin_layout Standard
849 \begin_inset ERT
850 status open
851
852 \begin_layout Plain Layout
853
854
855 \backslash
856 begin{tabular}{ll}
857 \end_layout
858
859 \begin_layout Plain Layout
860
861
862 \backslash
863 begin{minipage}{5cm}
864 \end_layout
865
866 \begin_layout Plain Layout
867
868 This is an example of a minipage environment.
869  You can put nearly everything in it, even (non-floating) figures and tables.
870  
871 \end_layout
872
873 \begin_layout Plain Layout
874
875
876 \backslash
877 end{minipage}
878 \end_layout
879
880 \begin_layout Plain Layout
881
882 &
883 \end_layout
884
885 \begin_layout Plain Layout
886
887
888 \backslash
889 begin{minipage}{5cm}
890 \end_layout
891
892 \begin_layout Plain Layout
893
894
895 \backslash
896 begin{verbatim}
897 \end_layout
898
899 \begin_layout Plain Layout
900
901
902 \backslash
903 begin{minipage}{5cm}
904 \end_layout
905
906 \begin_layout Plain Layout
907
908 This ...
909  
910 \end_layout
911
912 \begin_layout Plain Layout
913
914
915 \backslash
916 end{minipage}
917 \end_layout
918
919 \begin_layout Plain Layout
920
921
922 \backslash
923 end{verbatim}
924 \end_layout
925
926 \begin_layout Plain Layout
927
928
929 \backslash
930 end{minipage}
931 \end_layout
932
933 \begin_layout Plain Layout
934
935
936 \backslash
937 end{tabular}
938 \end_layout
939
940 \end_inset
941
942
943 \begin_inset VSpace bigskip
944 \end_inset
945
946
947 \end_layout
948
949 \begin_layout Standard
950 In addition to using \SpecialChar TeX
951  code, you can also create a separate file containing
952  some complex \SpecialChar LaTeX
953  structure and then use 
954 \begin_inset Flex Noun
955 status collapsed
956
957 \begin_layout Plain Layout
958 Insert\SpecialChar menuseparator
959 Child
960 \begin_inset space ~
961 \end_inset
962
963 Document
964 \end_layout
965
966 \end_inset
967
968  to include your file (you should select the type 
969 \begin_inset Flex Code
970 status collapsed
971
972 \begin_layout Plain Layout
973 Input
974 \end_layout
975
976 \end_inset
977
978 ).
979  We recommend that you only do this if you have a 
980 \begin_inset Flex Code
981 status collapsed
982
983 \begin_layout Plain Layout
984 .tex
985 \end_layout
986
987 \end_inset
988
989  file which you 
990 \emph on
991 know
992 \emph default
993  works already.
994  Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
995  errors.
996 \end_layout
997
998 \begin_layout Standard
999 There are a few last points to emphasize:
1000 \end_layout
1001
1002 \begin_layout Itemize
1003 \SpecialChar LyX
1004  
1005 \emph on
1006 does not
1007 \emph default
1008  check if your \SpecialChar LaTeX
1009  code is correct.
1010 \end_layout
1011
1012 \begin_layout Itemize
1013 Beware of reinventing the wheel.
1014 \end_layout
1015
1016 \begin_layout Standard
1017 On that last point, \SpecialChar LyX
1018  does have quite a few features tucked into it, and
1019  more are coming.
1020  Be sure to check the manuals to make sure that \SpecialChar LyX
1021  doesn't have such-and-such
1022  feature before you decide you have to do it by hand.
1023  Moreover, there are numerous \SpecialChar LaTeX
1024  packages out there to do all sorts of things,
1025  from labels to envelopes to fancy multipage tables.
1026  Check out 
1027 \begin_inset CommandInset href
1028 LatexCommand href
1029 name "CTAN"
1030 target "http://www.ctan.org/"
1031
1032 \end_inset
1033
1034  for details.
1035 \end_layout
1036
1037 \begin_layout Standard
1038 If you do need to do some wild and fancy things within your document, be
1039  sure to check out a good \SpecialChar LaTeX
1040  book for assistance.
1041  There are a number of them listed in the bibliography of the 
1042 \emph on
1043 User's Guide
1044 \emph default
1045 .
1046 \end_layout
1047
1048 \begin_layout Section
1049 \SpecialChar LyX
1050  and the \SpecialChar LaTeX
1051  Preamble
1052 \end_layout
1053
1054 \begin_layout Subsection
1055 About the \SpecialChar LaTeX
1056  Preamble
1057 \end_layout
1058
1059 \begin_layout Standard
1060 If you already know \SpecialChar LaTeX
1061 , there is no need to explain here what the preamble
1062  is good for.
1063  If you don't, the following will give you some ideas—we recommend again
1064  that you consult a \SpecialChar LaTeX
1065  book for further information.
1066  In any case, you should read the points below, because they explain what
1067  you can do and what you don't need to do in the \SpecialChar LaTeX
1068  preamble of a \SpecialChar LyX
1069  document.
1070 \end_layout
1071
1072 \begin_layout Standard
1073 The \SpecialChar LaTeX
1074  preamble comes at the very beginning of a document, 
1075 \emph on
1076 before
1077 \emph default
1078  the text.
1079  It serves to:
1080 \end_layout
1081
1082 \begin_layout Itemize
1083 Declare the document class.
1084  
1085 \begin_inset Newline newline
1086 \end_inset
1087
1088 \SpecialChar LyX
1089  already does this for you.
1090  If you're a seasoned \SpecialChar LaTeX
1091 -nician, and you have a custom document class you
1092  want to use, check out the 
1093 \emph on
1094 Customization Manual
1095 \emph default
1096  for information on how to make \SpecialChar LyX
1097  interface to it.
1098 \end_layout
1099
1100 \begin_layout Itemize
1101 Declare the usage of packages.
1102  
1103 \begin_inset Newline newline
1104 \end_inset
1105
1106 \SpecialChar LaTeX
1107  packages provide special commands, which are only available within a document
1108  when the package has been declared in the preamble.
1109  In addition to providing special commands, the inclusion of a package can
1110  change the document.
1111  For example, the package 
1112 \begin_inset Flex Code
1113 status collapsed
1114
1115 \begin_layout Plain Layout
1116 indentfirst
1117 \end_layout
1118
1119 \end_inset
1120
1121  forces all paragraphs to be indented.
1122  There are other packages for labels, envelopes, margins, etc.
1123  
1124 \end_layout
1125
1126 \begin_layout Itemize
1127 Set counters, variables, lengths and widths.
1128  
1129 \begin_inset Newline newline
1130 \end_inset
1131
1132 There are several \SpecialChar LaTeX
1133  counters and variables that 
1134 \emph on
1135 must
1136 \emph default
1137  be set globally from within the preamble in order to have the desired effect.
1138  (There are variables that you can set and reset inside the document, too.)
1139  Margins are a good example of something that must be set in the preamble.
1140  Another example is the label format for lists.
1141  You can actually set these just about anywhere, but it's best to do it
1142  just once, inside the preamble.
1143 \end_layout
1144
1145 \begin_layout Itemize
1146 Declare user defined commands (with 
1147 \begin_inset Flex Code
1148 status collapsed
1149
1150 \begin_layout Plain Layout
1151
1152 \backslash
1153 newcommand
1154 \end_layout
1155
1156 \end_inset
1157
1158  or 
1159 \begin_inset Flex Code
1160 status collapsed
1161
1162 \begin_layout Plain Layout
1163
1164 \backslash
1165 renewcommand
1166 \end_layout
1167
1168 \end_inset
1169
1170 ).
1171 \begin_inset Newline newline
1172 \end_inset
1173
1174 These are abbreviations for \SpecialChar LaTeX
1175  commands which appear very often inside a document.
1176  Although the preamble is a good place to declare such commands, they 
1177 \emph on
1178 can
1179 \emph default
1180  be declared anywhere (before they are used for the first time, of course).
1181  This can be useful if there is a lot of raw \SpecialChar LaTeX
1182  code in your document, which
1183  normally should not be the case.
1184 \end_layout
1185
1186 \begin_layout Standard
1187 \SpecialChar LyX
1188  adds its own set of definitions to the preamble of the 
1189 \begin_inset Flex Code
1190 status collapsed
1191
1192 \begin_layout Plain Layout
1193 .tex
1194 \end_layout
1195
1196 \end_inset
1197
1198  file it produces.
1199  This makes \SpecialChar LaTeX
1200  files generated by \SpecialChar LyX
1201  portable.
1202 \end_layout
1203
1204 \begin_layout Subsection
1205 Changing the Preamble
1206 \end_layout
1207
1208 \begin_layout Standard
1209 The commands which \SpecialChar LyX
1210  adds to the preamble of a \SpecialChar LaTeX
1211  file are fixed; you can't
1212  change them without patching \SpecialChar LyX
1213  itself.
1214  You can, however, add your own stuff to the preamble by selecting 
1215 \begin_inset Flex Noun
1216 status collapsed
1217
1218 \begin_layout Plain Layout
1219 \SpecialChar LaTeX
1220
1221 \begin_inset space ~
1222 \end_inset
1223
1224 Preamble
1225 \end_layout
1226
1227 \end_inset
1228
1229  in the 
1230 \begin_inset Flex Noun
1231 status collapsed
1232
1233 \begin_layout Plain Layout
1234 Document\SpecialChar menuseparator
1235 Settings
1236 \end_layout
1237
1238 \end_inset
1239
1240  dialog.
1241  \SpecialChar LyX
1242  adds anything in the 
1243 \begin_inset Flex Noun
1244 status collapsed
1245
1246 \begin_layout Plain Layout
1247 Preamble
1248 \end_layout
1249
1250 \end_inset
1251
1252  dialog to its own built-in preamble.
1253  Before adding your own declarations in the preamble, you should make sure
1254  that \SpecialChar LyX
1255  doesn't already support what you want to do.
1256  (Remember what we said about reinventing the wheel?) Also, 
1257 \emph on
1258 make sure your preamble code is correct
1259 \emph default
1260 .
1261  \SpecialChar LyX
1262  doesn't check it for you.
1263  If there is an error, you're likely to get an error like 
1264 \begin_inset Quotes eld
1265 \end_inset
1266
1267
1268 \begin_inset Flex Code
1269 status collapsed
1270
1271 \begin_layout Plain Layout
1272 Missing 
1273 \backslash
1274 begin{document}
1275 \end_layout
1276
1277 \end_inset
1278
1279
1280 \begin_inset Quotes erd
1281 \end_inset
1282
1283 .
1284  If you see this error, check your preamble.
1285 \end_layout
1286
1287 \begin_layout Subsection
1288 Examples
1289 \end_layout
1290
1291 \begin_layout Standard
1292 Here are some examples of what you can add to a preamble, and what they
1293  do.
1294 \end_layout
1295
1296 \begin_layout Subsubsection
1297 Example #1: Offsets
1298 \end_layout
1299
1300 \begin_layout Standard
1301 There are two variables under \SpecialChar LaTeX
1302  that control page position: 
1303 \begin_inset Flex Code
1304 status collapsed
1305
1306 \begin_layout Plain Layout
1307
1308 \backslash
1309 hoffset
1310 \end_layout
1311
1312 \end_inset
1313
1314  and 
1315 \begin_inset Flex Code
1316 status collapsed
1317
1318 \begin_layout Plain Layout
1319
1320 \backslash
1321 voffset
1322 \end_layout
1323
1324 \end_inset
1325
1326 .
1327  Their names should be self-explanatory.
1328  These variables are useful if you think for a moment about computer labels.
1329  Sometimes, the size of a print medium and the area of the medium that you
1330  can actually print on aren't the same.
1331  This is where 
1332 \begin_inset Flex Code
1333 status collapsed
1334
1335 \begin_layout Plain Layout
1336
1337 \backslash
1338 hoffset
1339 \end_layout
1340
1341 \end_inset
1342
1343  and 
1344 \begin_inset Flex Code
1345 status collapsed
1346
1347 \begin_layout Plain Layout
1348
1349 \backslash
1350 voffset
1351 \end_layout
1352
1353 \end_inset
1354
1355  come in.
1356 \end_layout
1357
1358 \begin_layout Standard
1359 The default values for 
1360 \begin_inset Flex Code
1361 status collapsed
1362
1363 \begin_layout Plain Layout
1364
1365 \backslash
1366 hoffset
1367 \end_layout
1368
1369 \end_inset
1370
1371  and 
1372 \begin_inset Flex Code
1373 status collapsed
1374
1375 \begin_layout Plain Layout
1376
1377 \backslash
1378 voffset
1379 \end_layout
1380
1381 \end_inset
1382
1383  are both 0
1384 \begin_inset space \thinspace{}
1385 \end_inset
1386
1387 points, i.
1388 \begin_inset space \thinspace{}
1389 \end_inset
1390
1391 e.
1392 \begin_inset space \space{}
1393 \end_inset
1394
1395 the page isn't shifted.
1396  Unfortunately, some DVI drivers always seem to shift the page.
1397  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1398  If you're using \SpecialChar LyX
1399  on a system that you don't personally maintain, and your
1400  sysadmin is a doofus, 
1401 \begin_inset Flex Code
1402 status collapsed
1403
1404 \begin_layout Plain Layout
1405
1406 \backslash
1407 hoffset
1408 \end_layout
1409
1410 \end_inset
1411
1412  and 
1413 \begin_inset Flex Code
1414 status collapsed
1415
1416 \begin_layout Plain Layout
1417
1418 \backslash
1419 voffset
1420 \end_layout
1421
1422 \end_inset
1423
1424  can save the day.
1425  Suppose your left and top margins are always 0.5
1426 \begin_inset space \thinspace{}
1427 \end_inset
1428
1429 inches too big.
1430  You can add this to the preamble:
1431 \end_layout
1432
1433 \begin_layout LyX-Code
1434
1435 \backslash
1436 setlength{
1437 \backslash
1438 hoffset}{-0.5 in}
1439 \end_layout
1440
1441 \begin_layout LyX-Code
1442
1443 \backslash
1444 setlength{
1445 \backslash
1446 voffset}{-0.5 in}
1447 \end_layout
1448
1449 \begin_layout Standard
1450 and your margins should now be correct.
1451 \end_layout
1452
1453 \begin_layout Subsubsection
1454 Example #2: Labels
1455 \end_layout
1456
1457 \begin_layout Standard
1458 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1459  There's a rather nice package, available at your nearest CTAN archive,
1460  for printing sheets of labels: 
1461 \begin_inset Flex Code
1462 status collapsed
1463
1464 \begin_layout Plain Layout
1465 labels.sty
1466 \end_layout
1467
1468 \end_inset
1469
1470 .
1471  Now, your system may not have this package installed by default.
1472  We leave that up to you to check.
1473  You'll also want to read the documentation for it; we're not going to do
1474  that for you.
1475  Since this is an example, however, we'll give you an example of how you
1476  use this package.
1477 \end_layout
1478
1479 \begin_layout Standard
1480 First, make sure you're using the 
1481 \begin_inset Flex Code
1482 status collapsed
1483
1484 \begin_layout Plain Layout
1485 article
1486 \end_layout
1487
1488 \end_inset
1489
1490  document class.
1491  Next, you need to put the following in your preamble:
1492 \end_layout
1493
1494 \begin_layout LyX-Code
1495
1496 \backslash
1497 usepackage{labels}
1498 \end_layout
1499
1500 \begin_layout LyX-Code
1501
1502 \backslash
1503 LabelCols=3
1504 \end_layout
1505
1506 \begin_layout LyX-Code
1507
1508 \backslash
1509 LabelRows=7
1510 \end_layout
1511
1512 \begin_layout LyX-Code
1513
1514 \backslash
1515 LeftBorder=8mm
1516 \end_layout
1517
1518 \begin_layout LyX-Code
1519
1520 \backslash
1521 RightBorder=8mm
1522 \end_layout
1523
1524 \begin_layout LyX-Code
1525
1526 \backslash
1527 TopBorder=9mm
1528 \end_layout
1529
1530 \begin_layout LyX-Code
1531
1532 \backslash
1533 BottomBorder=2mm
1534 \end_layout
1535
1536 \begin_layout Standard
1537 This sets things up for Avery label sheets, stock #5360.
1538  You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1539  code, placing
1540  the commands 
1541 \begin_inset Flex Code
1542 status collapsed
1543
1544 \begin_layout Plain Layout
1545
1546 \backslash
1547 begin{labels}
1548 \end_layout
1549
1550 \end_inset
1551
1552  and 
1553 \begin_inset Flex Code
1554 status collapsed
1555
1556 \begin_layout Plain Layout
1557
1558 \backslash
1559 end{labels}
1560 \end_layout
1561
1562 \end_inset
1563
1564  around each label text.
1565  This and other special features of 
1566 \begin_inset Flex Code
1567 status collapsed
1568
1569 \begin_layout Plain Layout
1570 labels.sty
1571 \end_layout
1572
1573 \end_inset
1574
1575  are explained in its documentation.
1576 \end_layout
1577
1578 \begin_layout Standard
1579 Someday, someone may write a \SpecialChar LyX
1580  layout file to support this package directly.
1581  Maybe that someone is you.
1582 \end_layout
1583
1584 \begin_layout Subsubsection
1585 Example #3: Paragraph Indentation
1586 \end_layout
1587
1588 \begin_layout Standard
1589 Americans are trained to indent the first line of 
1590 \emph on
1591 every
1592 \emph default
1593  paragraph.
1594  As with all of their other weird quirks, most Americans will whine and
1595  moan until they can have their way and indent the first line of all paragraphs.
1596  (Yes, we're joking.
1597  (We are?) 
1598 \emph on
1599 Yeah
1600 \emph default
1601 , we are.)
1602 \end_layout
1603
1604 \begin_layout Standard
1605 Of course, this behavior isn't standard typography.
1606  In books, you typically only indent the first line of a paragraph 
1607 \emph on
1608 if
1609 \emph default
1610  it follows another one.
1611  The idea behind indenting the first line of a paragraph is to distinguish
1612  neighboring paragraphs from one another.
1613  If there is no previous paragraph—for example, if it follows a figure or
1614  is the first paragraph in a section—then there is no need for indentation.
1615  
1616 \end_layout
1617
1618 \begin_layout Standard
1619 If you're a typical American (we're still joking!), though, you don't care
1620  about such esoteric things; you want your indentation! Add this to the
1621  preamble:
1622 \end_layout
1623
1624 \begin_layout LyX-Code
1625
1626 \backslash
1627 usepackage{indentfirst}
1628 \end_layout
1629
1630 \begin_layout Standard
1631 If your \SpecialChar TeX
1632  distribution isn't braindead, you'll have this package, and all
1633  of your paragraphs will get the indentation the Founding Fathers intended
1634  they should have.
1635 \end_layout
1636
1637 \begin_layout Subsubsection
1638 Example #4: This Document
1639 \end_layout
1640
1641 \begin_layout Standard
1642 You can also check out the preamble of this document to get an idea of some
1643  of the advanced things you can do.
1644 \end_layout
1645
1646 \begin_layout Section
1647 \SpecialChar LyX
1648  and \SpecialChar LaTeX
1649  Errors
1650 \end_layout
1651
1652 \begin_layout Standard
1653 When \SpecialChar LyX
1654  calls \SpecialChar LaTeX
1655 , it tells \SpecialChar LaTeX
1656  to blithely ignore any errors and keep going.
1657  It then uses the logfile from the \SpecialChar LaTeX
1658  run to do a post-mortem.
1659  After analyzing the logfile, \SpecialChar LyX
1660  displays a dialog listing the errors.
1661  Clicking on any one of them will take you to the position in your \SpecialChar LyX
1662  file
1663  where the error occurred.
1664 \begin_inset Foot
1665 status collapsed
1666
1667 \begin_layout Plain Layout
1668 Well, usually.
1669  Analyzing the logfile is a tough job, and \SpecialChar LyX
1670  doesn't always go to the right
1671  line.
1672  There are also cases where \SpecialChar LaTeX
1673  reports the error on one line, but the actual
1674  error is earlier.
1675  This is not unlike forgetting a closing brace in a program: You'll get
1676  an error, but only later.
1677 \end_layout
1678
1679 \end_inset
1680
1681
1682 \end_layout
1683
1684 \begin_layout Standard
1685 Some folks also like to look at the log file directly: It is available from
1686  
1687 \begin_inset Flex Noun
1688 status collapsed
1689
1690 \begin_layout Plain Layout
1691 Document\SpecialChar menuseparator
1692 LaTeX
1693 \begin_inset space ~
1694 \end_inset
1695
1696 Log
1697 \end_layout
1698
1699 \end_inset
1700
1701 .
1702  There are some fairly common error messages and warnings.
1703  We'll cover those here.
1704  You should look at a good \SpecialChar LaTeX
1705  book for a complete listing.
1706 \end_layout
1707
1708 \begin_layout Itemize
1709 \begin_inset Flex Code
1710 status collapsed
1711
1712 \begin_layout Plain Layout
1713 LaTeX Warning
1714 \end_layout
1715
1716 \end_inset
1717
1718
1719 \begin_inset Newline newline
1720 \end_inset
1721
1722 Anything beginning with these words is a warning message for the purpose
1723  of 
1724 \begin_inset Quotes eld
1725 \end_inset
1726
1727 debugging
1728 \begin_inset Quotes erd
1729 \end_inset
1730
1731  the \SpecialChar LaTeX
1732  code itself.
1733  You'll get messages like this if you added or changed cross-references
1734  or bibliography entries, in which case, \SpecialChar LaTeX
1735  is trying to tell you that you
1736  need to make another run.
1737  You can by-and-large ignore these.
1738 \end_layout
1739
1740 \begin_layout Itemize
1741 \begin_inset Flex Code
1742 status collapsed
1743
1744 \begin_layout Plain Layout
1745 LaTeX Font Warning
1746 \end_layout
1747
1748 \end_inset
1749
1750
1751 \begin_inset Newline newline
1752 \end_inset
1753
1754 Another warning message, this time about fonts which \SpecialChar LaTeX
1755  couldn't find.
1756  The rest of the message will often say something about a replacement font
1757  that \SpecialChar LaTeX
1758  used.
1759  You can safely ignore these, too.
1760 \end_layout
1761
1762 \begin_layout Itemize
1763 \begin_inset Flex Code
1764 status collapsed
1765
1766 \begin_layout Plain Layout
1767 Overfull 
1768 \backslash
1769 hbox
1770 \end_layout
1771
1772 \end_inset
1773
1774
1775 \begin_inset Newline newline
1776 \end_inset
1777
1778 \SpecialChar LaTeX
1779  absolutely 
1780 \emph on
1781 loves
1782 \emph default
1783  to spew these out.
1784  They are warnings about lines that were too long and run past the right
1785  margin.
1786  Almost always, this is unnoticeable in the final output.
1787  (It can be just a point or two.) Or, only one or two characters extend past
1788  the margin.
1789  \SpecialChar LaTeX
1790  seems to generate at least one of these messages for just about any document
1791  you write.
1792 \begin_inset Newline newline
1793 \end_inset
1794
1795 You can ignore these messages.
1796  Your eyes will tell you if there's a problem with something that's too
1797  wide; just look at the output.
1798 \begin_inset Foot
1799 status collapsed
1800
1801 \begin_layout Plain Layout
1802 You can also enable the `draft' option in 
1803 \begin_inset Flex Noun
1804 status collapsed
1805
1806 \begin_layout Plain Layout
1807 Document\SpecialChar menuseparator
1808 Settings
1809 \end_layout
1810
1811 \end_inset
1812
1813 , and then \SpecialChar LaTeX
1814  will draw a black box in the margin of lines that are overfull.
1815 \end_layout
1816
1817 \end_inset
1818
1819
1820 \end_layout
1821
1822 \begin_layout Itemize
1823 \begin_inset Flex Code
1824 status collapsed
1825
1826 \begin_layout Plain Layout
1827 Underfull 
1828 \backslash
1829 hbox
1830 \end_layout
1831
1832 \end_inset
1833
1834
1835 \begin_inset Newline newline
1836 \end_inset
1837
1838 Not quite as common as its cousin.
1839  \SpecialChar LaTeX
1840  seems to like to print lines that are a bit too wide as opposed to ones
1841  that are a bit too narrow.
1842  We have no idea why.
1843 \end_layout
1844
1845 \begin_layout Itemize
1846 \begin_inset Flex Code
1847 status collapsed
1848
1849 \begin_layout Plain Layout
1850 Overfull 
1851 \backslash
1852 vbox
1853 \end_layout
1854
1855 \end_inset
1856
1857  and 
1858 \begin_inset Flex Code
1859 status collapsed
1860
1861 \begin_layout Plain Layout
1862 Underfull 
1863 \backslash
1864 vbox
1865 \end_layout
1866
1867 \end_inset
1868
1869
1870 \begin_inset Newline newline
1871 \end_inset
1872
1873 Warnings about troubles breaking the page.
1874  Once again, just look at the output.
1875  Your eyes will tell you where something has gone wrong.
1876 \end_layout
1877
1878 \begin_layout Itemize
1879 \begin_inset Flex Code
1880 status collapsed
1881
1882 \begin_layout Plain Layout
1883 LaTeX Error: File 
1884 \begin_inset Quotes els
1885 \end_inset
1886
1887 Xxxx
1888 \begin_inset Quotes ers
1889 \end_inset
1890
1891  not found
1892 \end_layout
1893
1894 \end_inset
1895
1896
1897 \begin_inset Newline newline
1898 \end_inset
1899
1900 The file 
1901 \begin_inset Quotes eld
1902 \end_inset
1903
1904 Xxxx
1905 \begin_inset Quotes erd
1906 \end_inset
1907
1908  isn't installed on this system.
1909  This usually appears because some package your document needs isn't installed.
1910  If you didn't touch the preamble or didn't use the 
1911 \begin_inset Flex Code
1912 status collapsed
1913
1914 \begin_layout Plain Layout
1915
1916 \backslash
1917 usepackage{}
1918 \end_layout
1919
1920 \end_inset
1921
1922  command, then one of the packages \SpecialChar LyX
1923  tried to load is missing.
1924  Use 
1925 \begin_inset Flex Noun
1926 status collapsed
1927
1928 \begin_layout Plain Layout
1929 Help\SpecialChar menuseparator
1930 \SpecialChar LaTeX
1931  Configuration
1932 \end_layout
1933
1934 \end_inset
1935
1936  to get a list of packages that \SpecialChar LyX
1937  knows about.
1938  This file is updated whenever you reconfigure \SpecialChar LyX
1939  (using 
1940 \begin_inset Flex Noun
1941 status collapsed
1942
1943 \begin_layout Plain Layout
1944 Tools\SpecialChar menuseparator
1945 Reconfigure
1946 \end_layout
1947
1948 \end_inset
1949
1950 ) and tells you which packages have been detected and what they do.
1951 \begin_inset Newline newline
1952 \end_inset
1953
1954 If you did use the 
1955 \begin_inset Flex Code
1956 status collapsed
1957
1958 \begin_layout Plain Layout
1959
1960 \backslash
1961 usepackage{}
1962 \end_layout
1963
1964 \end_inset
1965
1966  command and the package in question isn't installed, then you'll need to
1967  install it yourself.
1968 \end_layout
1969
1970 \begin_layout Itemize
1971 \begin_inset Flex Code
1972 status collapsed
1973
1974 \begin_layout Plain Layout
1975 LaTeX Error: Unknown option
1976 \end_layout
1977
1978 \end_inset
1979
1980
1981 \begin_inset Newline newline
1982 \end_inset
1983
1984 Error messages beginning with this are trying to tell you that you specified
1985  a bad or undefined option to a package.
1986  Check the package's documentation.
1987 \end_layout
1988
1989 \begin_layout Itemize
1990 \begin_inset Flex Code
1991 status collapsed
1992
1993 \begin_layout Plain Layout
1994 Undefined control sequence
1995 \end_layout
1996
1997 \end_inset
1998
1999
2000 \begin_inset Newline newline
2001 \end_inset
2002
2003 If you've inserted \SpecialChar LaTeX
2004  code into your document, but made a typo, you'll get
2005  one of these.
2006  You may have forgotten to load a package.
2007  In any case, this error message usually means that you used an undefined
2008  command.
2009  
2010 \end_layout
2011
2012 \begin_layout Standard
2013 There are other error and warning messages.
2014  Some are self-explanatory.
2015  These are usually \SpecialChar LaTeX
2016  messages.
2017  Others are downright cryptic.
2018  These are usually \SpecialChar TeX
2019  error messages, and we really have 
2020 \emph on
2021 no clue
2022 \emph default
2023  what they mean or how to decipher them.
2024  No-one does.
2025 \end_layout
2026
2027 \begin_layout Standard
2028 There's a general sequence you should follow if you get error messages:
2029 \end_layout
2030
2031 \begin_layout Enumerate
2032 Look at the \SpecialChar LaTeX
2033  code you inserted for typos.
2034 \end_layout
2035
2036 \begin_layout Enumerate
2037 If there are no typos, check that you used the command(s) correctly.
2038 \end_layout
2039
2040 \begin_layout Enumerate
2041 If you get a bunch of error boxes piled up at the very top of the document—and
2042  especially if you see a 
2043 \begin_inset Quotes eld
2044 \end_inset
2045
2046
2047 \begin_inset Flex Code
2048 status collapsed
2049
2050 \begin_layout Plain Layout
2051 Missing 
2052 \backslash
2053 begin{document}
2054 \end_layout
2055
2056 \end_inset
2057
2058
2059 \begin_inset Quotes erd
2060 \end_inset
2061
2062  error—it means that there are errors in the preamble.
2063  Start debugging your preamble.
2064 \end_layout
2065
2066 \begin_layout Enumerate
2067 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2068  code to the
2069  document, the first suspect is your \SpecialChar LaTeX
2070  distribution itself.
2071  Check for missing packages and install them.
2072 \end_layout
2073
2074 \begin_layout Enumerate
2075 Okay, so there are no missing packages.
2076  Did you use any of the fine-tuning options in \SpecialChar LyX
2077 ? Specifically, did you 
2078 \emph on
2079 misuse
2080 \emph default
2081  any of them, like trying to manually insert lots of 
2082 \begin_inset Flex Code
2083 status collapsed
2084
2085 \begin_layout Plain Layout
2086 Protected
2087 \begin_inset space ~
2088 \end_inset
2089
2090 Blanks
2091 \end_layout
2092
2093 \end_inset
2094
2095
2096 \begin_inset Flex Code
2097 status collapsed
2098
2099 \begin_layout Plain Layout
2100 Linebreaks
2101 \end_layout
2102
2103 \end_inset
2104
2105 , or 
2106 \begin_inset Flex Code
2107 status collapsed
2108
2109 \begin_layout Plain Layout
2110 Pagebreaks
2111 \end_layout
2112
2113 \end_inset
2114
2115 ? Did you try to kludge something together with these instead of using the
2116  appropriate paragraph environment?
2117 \end_layout
2118
2119 \begin_layout Enumerate
2120 All right, you didn't use any of the fine-tuning options, you played by
2121  the rules.
2122  Did you try to pull a fancy maneuver? Did you do something funky inside
2123  a table or an equation, like inserting a graphic into a table cell?
2124 \end_layout
2125
2126 \begin_layout Enumerate
2127 Do you have long sections of text where \SpecialChar LaTeX
2128  cannot find a place to break a
2129  line? By default, \SpecialChar LaTeX
2130  is rather strict about how much extra inter-word spacing
2131  it will add in order to break a line.
2132  Preferably, you should rework the paragraph to avoid the problem.
2133 \end_layout
2134
2135 \begin_layout Enumerate
2136 Did you go overboard with the nesting? \SpecialChar LyX
2137  (currently) doesn't check to make
2138  sure you're in the limits for nesting environments.
2139  If you nested a bunch of environments to the 
2140 \begin_inset Formula $17^{\mathrm{th}}$
2141 \end_inset
2142
2143  level, that's the problem.
2144  (The limit in \SpecialChar LaTeX
2145  is five.)
2146 \end_layout
2147
2148 \begin_layout Enumerate
2149 Okay, you didn't get any error messages, but your output looks awful.
2150  If you have a table or figure that's too wide or long for the page, you
2151  need to:
2152 \end_layout
2153
2154 \begin_deeper
2155 \begin_layout Enumerate
2156 rescale the figure so it fits.
2157 \end_layout
2158
2159 \begin_layout Enumerate
2160 trim down the table so it fits.
2161 \end_layout
2162
2163 \end_deeper
2164 \begin_layout Enumerate
2165 If something else is wrong with the output, and you didn't try to pull anything
2166  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2167 \end_layout
2168
2169 \begin_layout Standard
2170 If all this doesn't help—well, then 
2171 \emph on
2172 perhaps
2173 \emph default
2174  you might have found a bug in \SpecialChar LyX
2175 \SpecialChar ldots
2176 .
2177 \end_layout
2178
2179 \begin_layout Chapter
2180
2181 \change_inserted 893223064 1464851738
2182 Document classes
2183 \end_layout
2184
2185 \begin_layout Standard
2186
2187 \change_inserted 893223064 1464852146
2188 This section will be updated in due course.
2189 \end_layout
2190
2191 \begin_layout Standard
2192 Special Document Classes
2193 \end_layout
2194
2195 \begin_layout Section
2196 A&A Paper
2197 \end_layout
2198
2199 \begin_layout Standard
2200 by 
2201 \noun on
2202 Peter Sütterlin
2203 \end_layout
2204
2205 \begin_layout Subsection
2206 Introduction
2207 \end_layout
2208
2209 \begin_layout Standard
2210 This section describes how \SpecialChar LyX
2211  can be used to write articles for submission
2212  to the scientific journal 
2213 \emph on
2214 Astronomy and Astrophysics
2215 \emph default
2216  (
2217 \begin_inset Flex URL
2218 status collapsed
2219
2220 \begin_layout Plain Layout
2221
2222 http://www.edpsciences.fr/aa/
2223 \end_layout
2224
2225 \end_inset
2226
2227 ) using Version 5.01 of the document class 
2228 \family typewriter
2229 aa.cls
2230 \family default
2231 .
2232  This package can be downloaded from the ftp site
2233 \end_layout
2234
2235 \begin_layout Standard
2236 \begin_inset VSpace medskip
2237 \end_inset
2238
2239
2240 \end_layout
2241
2242 \begin_layout Standard
2243 \align center
2244 \begin_inset Flex URL
2245 status collapsed
2246
2247 \begin_layout Plain Layout
2248
2249 ftp://ftp.edpsciences.org/pub/aa/readme.html
2250 \end_layout
2251
2252 \end_inset
2253
2254
2255 \end_layout
2256
2257 \begin_layout Standard
2258 \begin_inset VSpace medskip
2259 \end_inset
2260
2261
2262 \end_layout
2263
2264 \begin_layout Standard
2265 A manual comes together with that package, and this text is not meant to
2266  replace the original manual but is merely a short guide in how to realize
2267  the correct form of your paper.
2268  
2269 \end_layout
2270
2271 \begin_layout Standard
2272 Please note that the publisher of the journal was changed from Springer
2273  to EDP Sciences starting January 1, 2001.
2274  That change involved also some slight changes to the style files, namely
2275  the removal of the thesaurus command.
2276  The \SpecialChar LyX
2277  class aa supports the newest version of these style files, V 5.01.
2278  If you have an older version installed, please upgrade.
2279  For compatibility, the old (version 4) layout has been kept as 
2280 \family sans
2281 article (A&A V4)
2282 \family default
2283 .
2284  Please refer to the comments in 
2285 \family typewriter
2286 \SpecialChar LyX
2287 Dir/layouts/aapaper.layout
2288 \family default
2289 .
2290 \end_layout
2291
2292 \begin_layout Subsection
2293 Getting started
2294 \end_layout
2295
2296 \begin_layout Standard
2297 It is recommended you start from the example template distributed with \SpecialChar LyX
2298 .
2299  If you are not using a template, note the following settings:
2300 \end_layout
2301
2302 \begin_layout Itemize
2303 Select 
2304 \family sans
2305 article (A&A)
2306 \family default
2307  in the 
2308 \family sans
2309 Document\SpecialChar menuseparator
2310 Settings
2311 \family default
2312  dialog (OK, that one was obvious).
2313 \end_layout
2314
2315 \begin_layout Itemize
2316 Don't change the option 
2317 \family sans
2318 Page
2319 \begin_inset space ~
2320 \end_inset
2321
2322 style
2323 \family default
2324 : Leave it set to 
2325 \family sans
2326 default
2327 \family default
2328 .
2329  The whole layout is done by the macros, you shouldn't change anything.
2330 \end_layout
2331
2332 \begin_layout Subsection
2333 The header block
2334 \end_layout
2335
2336 \begin_layout Standard
2337 First thing to enter is the header information.
2338  It consists of seven entries, of which some are optional.
2339  They are
2340 \end_layout
2341
2342 \begin_layout Itemize
2343
2344 \family sans
2345 Title
2346 \family default
2347 : [required] 
2348 \end_layout
2349
2350 \begin_layout Itemize
2351
2352 \family sans
2353 Subtitle
2354 \family default
2355 : [optional] 
2356 \end_layout
2357
2358 \begin_layout Itemize
2359
2360 \family sans
2361 Author
2362 \family default
2363 : [required]
2364 \end_layout
2365
2366 \begin_layout Itemize
2367
2368 \family sans
2369 Address
2370 \family default
2371 : [required]
2372 \end_layout
2373
2374 \begin_layout Itemize
2375
2376 \family sans
2377 Offprints
2378 \family default
2379 : [optional] if more than one author: whom to contact for offprint requests.
2380 \end_layout
2381
2382 \begin_layout Itemize
2383
2384 \family sans
2385 Mail
2386 \family default
2387 : [optional] mail address for contacts.
2388 \end_layout
2389
2390 \begin_layout Itemize
2391
2392 \family sans
2393 Date
2394 \family default
2395 : [required].
2396  Suggested format is 
2397 \family typewriter
2398 Received: <date>; Accepted <date> 
2399 \end_layout
2400
2401 \begin_layout Standard
2402 There is no need to issue the 
2403 \family typewriter
2404
2405 \backslash
2406 maketitle
2407 \family default
2408  command, this is done automatically by \SpecialChar LyX
2409  when the header is finished.
2410  Although the order of the single header entries doesn't matter it is advised
2411  to keep the above sequence, just to get the best optics and meets the layout
2412  of the real document.
2413 \end_layout
2414
2415 \begin_layout Standard
2416 If you want to place footnotes in the header block, e.
2417 \begin_inset space \thinspace{}
2418 \end_inset
2419
2420 g.
2421 \begin_inset space \space{}
2422 \end_inset
2423
2424 to state your present address, just use the standard footnote via the menu
2425  
2426 \family sans
2427 Insert\SpecialChar menuseparator
2428 Footnote.
2429
2430 \family default
2431  \SpecialChar LyX
2432  will automagically use the term 
2433 \family typewriter
2434
2435 \backslash
2436 thanks{}
2437 \family default
2438  in that case.
2439 \end_layout
2440
2441 \begin_layout Standard
2442 In addition to these topics, the macros use three additional \SpecialChar LaTeX
2443  commands that
2444  have no counterpart in \SpecialChar LyX
2445 :
2446 \end_layout
2447
2448 \begin_layout Itemize
2449
2450 \family typewriter
2451
2452 \backslash
2453 and
2454 \family default
2455  to separate different names for more than one author and institute, respectivel
2456 y.
2457 \end_layout
2458
2459 \begin_layout Itemize
2460
2461 \family typewriter
2462
2463 \backslash
2464 inst{<nr>}
2465 \family default
2466 to mark corresponding author/institute pairs.
2467  The institutes are numbered sequentially as they appear in the 
2468 \family sans
2469 Address
2470 \family default
2471  field, so you have to put a marker to each author.
2472 \end_layout
2473
2474 \begin_layout Itemize
2475
2476 \family typewriter
2477
2478 \backslash
2479 email{address}
2480 \family default
2481  to supply an email address for fast contact.
2482 \end_layout
2483
2484 \begin_layout Standard
2485 In all cases, the appropriate command has to be entered in \SpecialChar LyX
2486  and marked as
2487  \SpecialChar LaTeX
2488  code.
2489  See the examples.
2490  
2491 \end_layout
2492
2493 \begin_layout Subsection
2494 The abstract
2495 \end_layout
2496
2497 \begin_layout Standard
2498 The abstract should immediately follow the header block.
2499  With version 5 the abstract environment was changed to a command, and there
2500  is now a resctriction to only one paragraph.
2501  In addition, it should contain an entry with the keywords.
2502  This is not yet implemented for \SpecialChar LyX
2503 , therefore you have to enter the \SpecialChar LaTeX
2504  command
2505  
2506 \family typewriter
2507
2508 \backslash
2509 keywords{}
2510 \family default
2511  by hand and mark it as \SpecialChar LaTeX
2512  code.
2513  Refer to the example paper.
2514 \end_layout
2515
2516 \begin_layout Subsection
2517 Supported environments
2518 \end_layout
2519
2520 \begin_layout Standard
2521 The A&A paper layout supports the following environments for structuring
2522  your text:
2523 \end_layout
2524
2525 \begin_layout Itemize
2526
2527 \family sans
2528 Standard
2529 \end_layout
2530
2531 \begin_layout Itemize
2532
2533 \family sans
2534 Section
2535 \end_layout
2536
2537 \begin_layout Itemize
2538
2539 \family sans
2540 Subsection
2541 \end_layout
2542
2543 \begin_layout Itemize
2544
2545 \family sans
2546 Subsubsection
2547 \end_layout
2548
2549 \begin_layout Itemize
2550
2551 \family sans
2552 Itemize
2553 \end_layout
2554
2555 \begin_layout Itemize
2556
2557 \family sans
2558 Enumerate
2559 \end_layout
2560
2561 \begin_layout Itemize
2562
2563 \family sans
2564 Description
2565 \end_layout
2566
2567 \begin_layout Itemize
2568
2569 \family sans
2570 Caption
2571 \end_layout
2572
2573 \begin_layout Itemize
2574
2575 \family sans
2576 Abstract
2577 \end_layout
2578
2579 \begin_layout Itemize
2580
2581 \family sans
2582 Acknowledgment
2583 \end_layout
2584
2585 \begin_layout Itemize
2586
2587 \family sans
2588 Bibliography
2589 \end_layout
2590
2591 \begin_layout Itemize
2592
2593 \family sans
2594 \SpecialChar LaTeX
2595
2596 \end_layout
2597
2598 \begin_layout Subsection
2599 Commands not supported by \SpecialChar LyX
2600
2601 \end_layout
2602
2603 \begin_layout Standard
2604 Some commands are not yet supported by the 
2605 \family sans
2606 paper (A&A)
2607 \family default
2608  layout for \SpecialChar LyX
2609 .
2610  Some have already been mentioned.
2611  For the sake of completeness, they are listed all together here:
2612 \end_layout
2613
2614 \begin_layout Itemize
2615
2616 \family typewriter
2617
2618 \backslash
2619 and
2620 \end_layout
2621
2622 \begin_layout Itemize
2623
2624 \family typewriter
2625
2626 \backslash
2627 email
2628 \end_layout
2629
2630 \begin_layout Itemize
2631
2632 \family typewriter
2633
2634 \backslash
2635 appendix
2636 \end_layout
2637
2638 \begin_layout Itemize
2639
2640 \family typewriter
2641
2642 \backslash
2643 authorrunning
2644 \end_layout
2645
2646 \begin_layout Itemize
2647
2648 \family typewriter
2649
2650 \backslash
2651 inst{}
2652 \end_layout
2653
2654 \begin_layout Itemize
2655
2656 \family typewriter
2657
2658 \backslash
2659 keywords{}
2660 \end_layout
2661
2662 \begin_layout Itemize
2663
2664 \family typewriter
2665
2666 \backslash
2667 object{}
2668 \end_layout
2669
2670 \begin_layout Itemize
2671
2672 \family typewriter
2673
2674 \backslash
2675 titlerunning{}
2676 \end_layout
2677
2678 \begin_layout Standard
2679 If you want to use any of these commands, you have to enter them yourself.
2680  
2681 \series bold
2682 Do not forget to mark them as \SpecialChar LaTeX
2683  code!
2684 \end_layout
2685
2686 \begin_layout Subsection
2687 Figure and Table Floats
2688 \end_layout
2689
2690 \begin_layout Standard
2691 \SpecialChar LyX
2692  provides support for the necessary float environments 
2693 \family sans
2694 figure, figure*, table
2695 \family default
2696  and 
2697 \family sans
2698 table*
2699 \family default
2700 , therefore we won't tell much about it here.
2701  Refer to the 
2702 \emph on
2703 User's
2704 \begin_inset space ~
2705 \end_inset
2706
2707 Guide
2708 \emph default
2709 .
2710  Just remember that tables should be left-aligned.
2711  For that, select the table and change the alignment in 
2712 \family sans
2713 Edit\SpecialChar menuseparator
2714 Paragraph
2715 \begin_inset space ~
2716 \end_inset
2717
2718 Settings.
2719 \end_layout
2720
2721 \begin_layout Standard
2722 There is only one special thing: the figures with caption besides the figure.
2723  To create such a figure, you have to do the following:
2724 \end_layout
2725
2726 \begin_layout Enumerate
2727 Create a wide figure float: 
2728 \family sans
2729 Insert\SpecialChar menuseparator
2730 Float\SpecialChar menuseparator
2731 Figure
2732 \family default
2733 , then right click in the figure and select 
2734 \family sans
2735 Span
2736 \begin_inset space ~
2737 \end_inset
2738
2739 columns
2740 \family default
2741 .
2742 \end_layout
2743
2744 \begin_layout Enumerate
2745 Enter your caption text.
2746 \end_layout
2747
2748 \begin_layout Enumerate
2749 Press 
2750 \family sans
2751 Return
2752 \family default
2753  to move the cursor above the caption.
2754 \end_layout
2755
2756 \begin_layout Enumerate
2757 Insert your figure
2758 \end_layout
2759
2760 \begin_layout Enumerate
2761 Position the cursor behind the figure and insert a horizontal fill: 
2762 \family sans
2763 Insert\SpecialChar menuseparator
2764 Special
2765 \begin_inset space ~
2766 \end_inset
2767
2768 Character\SpecialChar menuseparator
2769 Horizontal
2770 \begin_inset space ~
2771 \end_inset
2772
2773 Fill
2774 \family default
2775 .
2776 \end_layout
2777
2778 \begin_layout Enumerate
2779 Switch to \SpecialChar LaTeX
2780  mode: 
2781 \family sans
2782 M-c
2783 \begin_inset space ~
2784 \end_inset
2785
2786 t
2787 \family default
2788 .
2789 \end_layout
2790
2791 \begin_layout Enumerate
2792 Enter 
2793 \family typewriter
2794
2795 \backslash
2796 parbox[b]{55mm}{
2797 \family default
2798 .
2799  
2800 \series bold
2801 Do not close the brace!
2802 \end_layout
2803
2804 \begin_layout Enumerate
2805 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
2806  mode and insert
2807  the closing brace: 
2808 \family sans
2809 M-c
2810 \begin_inset space ~
2811 \end_inset
2812
2813 t
2814 \family default
2815  
2816 \family typewriter
2817 }
2818 \family default
2819 .
2820 \end_layout
2821
2822 \begin_layout Standard
2823 Also, refer to the figures in the example paper.
2824 \end_layout
2825
2826 \begin_layout Subsection
2827 Referee layout
2828 \end_layout
2829
2830 \begin_layout Standard
2831 For submission, the paper has to be formated in a special double-spacing
2832  layout.
2833  For this purpose, you have to give the option 
2834 \family typewriter
2835 referee
2836 \family default
2837  to the documentclass.
2838  This must be done using the extra class options field in the 
2839 \family sans
2840 Document\SpecialChar menuseparator
2841 Settings
2842 \family default
2843  dialog.
2844  Just enter the string 
2845 \family typewriter
2846 referee
2847 \family default
2848  there.
2849 \end_layout
2850
2851 \begin_layout Subsection
2852 The example paper
2853 \end_layout
2854
2855 \begin_layout Standard
2856 The 
2857 \family sans
2858 Examples
2859 \family default
2860  directory contains an example paper written with \SpecialChar LyX
2861 .
2862  It is the example paper from the original macro package, translated to
2863  \SpecialChar LyX
2864 .
2865  Use it for inspiration, and compare the original \SpecialChar LaTeX
2866  code with \SpecialChar LyX
2867  way of writing.
2868 \end_layout
2869
2870 \begin_layout Section
2871 AAS\SpecialChar TeX
2872
2873 \end_layout
2874
2875 \begin_layout Standard
2876 by 
2877 \noun on
2878 Mike Ressler
2879 \end_layout
2880
2881 \begin_layout Subsection
2882 Introduction
2883 \end_layout
2884
2885 \begin_layout Standard
2886 AAS\SpecialChar TeX
2887  is a set of macros produced by the American Astronomical Society to
2888  facilitate electronic manuscript submission to the three journals they
2889  publish: the Astrophysical Journal (including the Letters and Supplement),
2890  the Astronomical Journal, and the Publications of the Astronomical Society
2891  of the Pacific.
2892  \SpecialChar LyX
2893  has proven to be an excellent tool for generating these documents, especially
2894  given its equation, citation, and figure handling capabilities.
2895  \SpecialChar LyX
2896  requires version 5.0 (or higher) of these macros; preferably 5.2, which
2897  is the version described here, or higher.
2898  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
2899 2.09 and are fundamentally
2900  incompatible with \SpecialChar LyX
2901 .
2902  The AAS\SpecialChar TeX
2903  package may be downloaded from the AAS\SpecialChar TeX
2904  Web site
2905 \end_layout
2906
2907 \begin_layout Standard
2908 \begin_inset VSpace medskip
2909 \end_inset
2910
2911
2912 \end_layout
2913
2914 \begin_layout Standard
2915 \align center
2916 \begin_inset Flex URL
2917 status collapsed
2918
2919 \begin_layout Plain Layout
2920
2921 https://aas.org/aastex/aastex-downloads
2922 \end_layout
2923
2924 \end_inset
2925
2926
2927 \end_layout
2928
2929 \begin_layout Standard
2930 \begin_inset VSpace medskip
2931 \end_inset
2932
2933
2934 \end_layout
2935
2936 \begin_layout Standard
2937 A complete user guide is contained in that package and you should familiarize
2938  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
2939 .
2940  \SpecialChar LyX
2941  will not reduce the need to figure out all the AAS\SpecialChar TeX
2942  commands, it will only
2943  reduce the drudgery of typing everything in.
2944  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
2945  document conforms
2946  completely to the requirements of the journal to which you are submitting
2947  your paper.
2948 \end_layout
2949
2950 \begin_layout Subsection
2951 Starting a New Paper
2952 \end_layout
2953
2954 \begin_layout Standard
2955 I strongly suggest that you start with the AAS\SpecialChar TeX
2956  template file.
2957  Click on 
2958 \family sans
2959 File\SpecialChar menuseparator
2960 New from
2961 \family default
2962  
2963 \family sans
2964 Template
2965 \family default
2966 , enter the new file name, then choose the 
2967 \family typewriter
2968 aastex.lyx
2969 \family default
2970  template.
2971  This will show the most common fields found in a manuscript.
2972  Simply overwrite the existing text (including the brackets, 
2973 \family typewriter
2974 <>
2975 \family default
2976 ) with the correct information.
2977  Many of the AAS\SpecialChar TeX
2978  commands and environments can be implemented directly in
2979  \SpecialChar LyX
2980 , but some cannot: most noticeably 
2981 \family typewriter
2982
2983 \backslash
2984 altaffilmark
2985 \family default
2986  and 
2987 \family typewriter
2988
2989 \backslash
2990 altaffiltext
2991 \family default
2992 , which should stick out like a sore thumb if you actually just opened the
2993  template file.
2994  For commands such as these, the \SpecialChar LaTeX
2995  code must be entered directly and marked
2996  as such.
2997  Such commands are referred to as \SpecialChar TeX
2998  code, or Evil Red Text.
2999  I tried to minimize the amount of \SpecialChar TeX
3000  code needed in an AAS\SpecialChar TeX
3001  document, but
3002  there is still a bit more required than any of us would like.
3003 \end_layout
3004
3005 \begin_layout Subsection
3006 Finishing Your Paper
3007 \end_layout
3008
3009 \begin_layout Standard
3010 When the paper is finished to your satisfaction and previews/prints correctly,
3011  there are a few 
3012 \begin_inset Quotes eld
3013 \end_inset
3014
3015 postprocessing
3016 \begin_inset Quotes erd
3017 \end_inset
3018
3019  actions which need to be done before you submit it to the journals.
3020  
3021 \end_layout
3022
3023 \begin_layout Enumerate
3024 Export your paper as a \SpecialChar LaTeX
3025  file (
3026 \family sans
3027 File\SpecialChar menuseparator
3028 Export\SpecialChar menuseparator
3029 \SpecialChar LaTeX
3030
3031 \family default
3032 ).
3033  
3034 \end_layout
3035
3036 \begin_layout Enumerate
3037 Edit the resulting 
3038 \family typewriter
3039 .tex
3040 \family default
3041  file with your favorite text editor
3042 \end_layout
3043
3044 \begin_deeper
3045 \begin_layout Enumerate
3046 remove the comment lines before the 
3047 \family typewriter
3048
3049 \backslash
3050 documentclass
3051 \family default
3052  command
3053 \end_layout
3054
3055 \begin_layout Enumerate
3056 remove the 
3057 \family typewriter
3058
3059 \backslash
3060 usepackage...{fontenc}
3061 \family default
3062  line if it appears (usually just after 
3063 \family typewriter
3064
3065 \backslash
3066 documentclass
3067 \family default
3068 }; also remove the 
3069 \family typewriter
3070
3071 \backslash
3072 secnumdepth
3073 \family default
3074  line if it appears.
3075 \end_layout
3076
3077 \begin_layout Enumerate
3078 remove everything between (and including) the 
3079 \family typewriter
3080
3081 \backslash
3082 makeatletter
3083 \family default
3084  and 
3085 \family typewriter
3086
3087 \backslash
3088 makeatother
3089 \family default
3090  commands, except for any commands you specifically put into the \SpecialChar LaTeX
3091  preamble
3092  (which should appear immediately after the 
3093 \begin_inset Quotes eld
3094 \end_inset
3095
3096 User specified \SpecialChar LaTeX
3097  commands
3098 \begin_inset Quotes erd
3099 \end_inset
3100
3101  comment in the 
3102 \family typewriter
3103 .tex
3104 \family default
3105  file).
3106 \end_layout
3107
3108 \end_deeper
3109 \begin_layout Enumerate
3110 Run the resulting file through \SpecialChar LaTeX
3111  to make sure it still processes correctly.
3112 \end_layout
3113
3114 \begin_layout Enumerate
3115 Reread the journal requirements to make sure your filenames and formats
3116  are correct.
3117 \end_layout
3118
3119 \begin_layout Enumerate
3120 Submit it.
3121 \end_layout
3122
3123 \begin_layout Subsection
3124 Comments On Specific Commands
3125 \end_layout
3126
3127 \begin_layout Standard
3128 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
3129  commands: the
3130  AAS\SpecialChar TeX
3131  User Guide (
3132 \family typewriter
3133 aasguide.tex
3134 \family default
3135 ) gives a good description of each.
3136  Thus it's probably easiest for me to go down the list as found in the guide
3137  and offer comments where necessary.
3138  So let's begin \SpecialChar ldots
3139
3140 \end_layout
3141
3142 \begin_layout Subsubsection
3143 Things that work as expected
3144 \end_layout
3145
3146 \begin_layout Standard
3147 Because they work as you might expect, I simply list them and the section
3148  they are found in: 
3149 \family typewriter
3150
3151 \backslash
3152 documentclass
3153 \family default
3154  (2.1.1), 
3155 \family typewriter
3156
3157 \backslash
3158 begin{document}
3159 \family default
3160  (2.2), 
3161 \family typewriter
3162
3163 \backslash
3164 title
3165 \family default
3166  (2.3), 
3167 \family typewriter
3168
3169 \backslash
3170 author
3171 \family default
3172  (2.3), 
3173 \family typewriter
3174
3175 \backslash
3176 affil
3177 \family default
3178  (2.3), 
3179 \family typewriter
3180
3181 \backslash
3182 abstract
3183 \family default
3184  (2.4), 
3185 \family typewriter
3186
3187 \backslash
3188 keywords
3189 \family default
3190  (2.5), 
3191 \family typewriter
3192
3193 \backslash
3194 section
3195 \family default
3196  (2.7), 
3197 \family typewriter
3198
3199 \backslash
3200 subsection
3201 \family default
3202  (2.7), 
3203 \family typewriter
3204
3205 \backslash
3206 subsubsection
3207 \family default
3208  (2.7), 
3209 \family typewriter
3210
3211 \backslash
3212 paragraph
3213 \family default
3214  (2.7), 
3215 \family typewriter
3216
3217 \backslash
3218 facility
3219 \family default
3220  (2.10), 
3221 \family typewriter
3222
3223 \backslash
3224 begin{displaymath}
3225 \family default
3226  (2.12), 
3227 \family typewriter
3228
3229 \backslash
3230 begin{equation}
3231 \family default
3232  (2.12), 
3233 \family typewriter
3234
3235 \backslash
3236 begin{eqnarray}
3237 \family default
3238  (2.12), 
3239 \family typewriter
3240
3241 \backslash
3242 begin{mathletters}
3243 \family default
3244  (2.12), 
3245 \family typewriter
3246
3247 \backslash
3248 begin{thebibliography}
3249 \family default
3250  (2.13.1), 
3251 \family typewriter
3252
3253 \backslash
3254 bibitem
3255 \family default
3256  (2.13.2), all the cite commands and their variations (2.13.2), the generic
3257  graphicx figure commands (2.14.1), 
3258 \family typewriter
3259
3260 \backslash
3261 begin{table}
3262 \family default
3263  (2.15.4), 
3264 \family typewriter
3265
3266 \backslash
3267 begin{tabular}
3268 \family default
3269  (2.15.4), 
3270 \family typewriter
3271
3272 \backslash
3273 caption
3274 \family default
3275  (2.15.4), 
3276 \family typewriter
3277
3278 \backslash
3279 label
3280 \family default
3281  (2.15.4, amongst other places), 
3282 \family typewriter
3283
3284 \backslash
3285 tablerefs
3286 \family default
3287  (2.15.5), 
3288 \family typewriter
3289
3290 \backslash
3291 tablecomments
3292 \family default
3293  (2.15.5), 
3294 \family typewriter
3295
3296 \backslash
3297 url
3298 \family default
3299  (2.17.4), 
3300 \family typewriter
3301
3302 \backslash
3303 end{document}
3304 \family default
3305  (2.18).
3306 \end_layout
3307
3308 \begin_layout Standard
3309 The following style options also work correctly: 
3310 \family typewriter
3311 longabstract
3312 \family default
3313  (2.4), 
3314 \family typewriter
3315 preprint
3316 \family default
3317  (3.2.1), 
3318 \family typewriter
3319 preprint2
3320 \family default
3321  (3.2.2), 
3322 \family typewriter
3323 eqsecnum
3324 \family default
3325  (3.3), 
3326 \family typewriter
3327 flushrt
3328 \family default
3329  (3.4).
3330  Simply put them in the 
3331 \family sans
3332 Options
3333 \family default
3334  box in 
3335 \family sans
3336 Layout\SpecialChar menuseparator
3337 Document
3338 \family default
3339 .
3340 \end_layout
3341
3342 \begin_layout Subsubsection
3343 Things that work, but require more comment
3344 \end_layout
3345
3346 \begin_layout Standard
3347 The following items work, but require a little more discussion:
3348 \end_layout
3349
3350 \begin_layout Itemize
3351 These items are reserved for use by the journal editors, but you can put
3352  them into the \SpecialChar LaTeX
3353  preamble if you feel compelled to do so: 
3354 \family typewriter
3355
3356 \backslash
3357 received
3358 \family default
3359
3360 \family typewriter
3361
3362 \backslash
3363 revised
3364 \family default
3365
3366 \family typewriter
3367
3368 \backslash
3369 accepted
3370 \family default
3371
3372 \family typewriter
3373
3374 \backslash
3375 ccc
3376 \family default
3377
3378 \family typewriter
3379
3380 \backslash
3381 cpright
3382 \family default
3383  (all from 2.1.3)
3384 \end_layout
3385
3386 \begin_layout Itemize
3387 These items may be placed in the \SpecialChar LaTeX
3388  preamble, and are included as blanks in
3389  the template file: 
3390 \family typewriter
3391
3392 \backslash
3393 slugcomment
3394 \family default
3395  (2.1.4), 
3396 \family typewriter
3397
3398 \backslash
3399 shorttitle
3400 \family default
3401  (2.1.5), 
3402 \family typewriter
3403
3404 \backslash
3405 shortauthors
3406 \family default
3407  (2.1.5)
3408 \end_layout
3409
3410 \begin_layout Itemize
3411
3412 \family typewriter
3413
3414 \backslash
3415 email
3416 \family default
3417  (2.3) – can only be used 
3418 \begin_inset Quotes eld
3419 \end_inset
3420
3421 standalone
3422 \begin_inset Quotes erd
3423 \end_inset
3424
3425 , not in the middle of a paragraph.
3426  Use \SpecialChar TeX
3427  code if you need to embed it.
3428 \end_layout
3429
3430 \begin_layout Itemize
3431
3432 \family typewriter
3433
3434 \backslash
3435 and
3436 \family default
3437  (2.3) – will have extra {} after it.
3438  This should not cause an error.
3439 \end_layout
3440
3441 \begin_layout Itemize
3442
3443 \family typewriter
3444
3445 \backslash
3446 notetoeditor
3447 \family default
3448  (2.6) – can only be used 
3449 \begin_inset Quotes eld
3450 \end_inset
3451
3452 standalone
3453 \begin_inset Quotes erd
3454 \end_inset
3455
3456 , not in the middle of a paragraph.
3457  Use \SpecialChar TeX
3458  code if you need to embed it.
3459 \end_layout
3460
3461 \begin_layout Itemize
3462
3463 \family typewriter
3464
3465 \backslash
3466 placetable
3467 \family default
3468  (2.8) – can't insert a cross-reference tag, you must type the tag name by
3469  hand
3470 \end_layout
3471
3472 \begin_layout Itemize
3473
3474 \family typewriter
3475
3476 \backslash
3477 placefigure
3478 \family default
3479  (2.8) – same as for 
3480 \family typewriter
3481
3482 \backslash
3483 placetable
3484 \end_layout
3485
3486 \begin_layout Itemize
3487
3488 \family typewriter
3489
3490 \backslash
3491 acknowledgements
3492 \family default
3493  (2.9) – will have extra {} after it.
3494  This should not cause an error.
3495 \end_layout
3496
3497 \begin_layout Itemize
3498
3499 \family typewriter
3500
3501 \backslash
3502 appendix
3503 \family default
3504  (2.11) – will have extra {} after it.
3505  This should not cause an error.
3506 \end_layout
3507
3508 \begin_layout Itemize
3509
3510 \family typewriter
3511
3512 \backslash
3513 figcaption
3514 \family default
3515  (2.14.2) – you can insert an optional filename argument by placing the cursor
3516  at the beginning of the text and selecting 
3517 \family sans
3518 Insert\SpecialChar menuseparator
3519 Short Title
3520 \family default
3521 .
3522  
3523 \begin_inset Quotes eld
3524 \end_inset
3525
3526 Short Title
3527 \begin_inset Quotes erd
3528 \end_inset
3529
3530  inserts an optional argument of the type needed by 
3531 \family typewriter
3532
3533 \backslash
3534 figcaption
3535 \family default
3536 .
3537  Hopefully it will be renamed someday.
3538 \end_layout
3539
3540 \begin_layout Itemize
3541
3542 \family typewriter
3543
3544 \backslash
3545 objectname
3546 \family default
3547  (2.17.1) – same as 
3548 \family typewriter
3549
3550 \backslash
3551 figcaption
3552 \family default
3553  for the catalog ID optional parameter
3554 \end_layout
3555
3556 \begin_layout Itemize
3557
3558 \family typewriter
3559
3560 \backslash
3561 dataset
3562 \family default
3563  (2.17.1) – same as 
3564 \family typewriter
3565
3566 \backslash
3567 figcaption
3568 \family default
3569  for the catalog ID optional parameter
3570 \end_layout
3571
3572 \begin_layout Subsubsection
3573 Things not implemented, use \SpecialChar TeX
3574  code
3575 \end_layout
3576
3577 \begin_layout Standard
3578
3579 \family typewriter
3580
3581 \backslash
3582 altaffilmark
3583 \family default
3584  (2.3), 
3585 \family typewriter
3586
3587 \backslash
3588 altaffiltext
3589 \family default
3590  (2.3), 
3591 \family typewriter
3592
3593 \backslash
3594 eqnum
3595 \family default
3596  (2.12), 
3597 \family typewriter
3598
3599 \backslash
3600 setcounter{equation}
3601 \family default
3602  (2.12), Journal name abbreviations (2.13.4), 
3603 \family typewriter
3604
3605 \backslash
3606 figurenum
3607 \family default
3608  (2.14.1), 
3609 \family typewriter
3610
3611 \backslash
3612 epsscale
3613 \family default
3614  (2.14.1), 
3615 \family typewriter
3616
3617 \backslash
3618 plotone
3619 \family default
3620  (2.14.1), 
3621 \family typewriter
3622
3623 \backslash
3624 plottwo
3625 \family default
3626  (2.14.1), 
3627 \family typewriter
3628
3629 \backslash
3630 tablenum
3631 \family default
3632  (2.15.4), 
3633 \family typewriter
3634
3635 \backslash
3636 tableline
3637 \family default
3638  (2.15.4, insert it as the first element in the lefthand cell after where
3639  you want it.
3640  Don't use any of \SpecialChar LyX
3641 's rules in the table), 
3642 \family typewriter
3643
3644 \backslash
3645 tablenotemark
3646 \family default
3647  (2.15.5), 
3648 \family typewriter
3649
3650 \backslash
3651 tablenotetext
3652 \family default
3653  (2.15.5), much of Misc (2.17, except 
3654 \family typewriter
3655
3656 \backslash
3657 objectname
3658 \family default
3659
3660 \family typewriter
3661
3662 \backslash
3663 dataset
3664 \family default
3665
3666 \family typewriter
3667
3668 \backslash
3669 url
3670 \family default
3671 , and 
3672 \family typewriter
3673
3674 \backslash
3675 email
3676 \family default
3677 ; see above), 
3678 \family typewriter
3679
3680 \backslash
3681 singlespace
3682 \family default
3683  (3.1), 
3684 \family typewriter
3685
3686 \backslash
3687 doublespace
3688 \family default
3689  (3.1), 
3690 \family typewriter
3691
3692 \backslash
3693 onecolumn
3694 \family default
3695  (3.2), 
3696 \family typewriter
3697
3698 \backslash
3699 twocolumn
3700 \family default
3701  (3.2)
3702 \end_layout
3703
3704 \begin_layout Subsubsection
3705 Things that cannot be implemented
3706 \end_layout
3707
3708 \begin_layout Standard
3709 \SpecialChar ldots
3710  at least in any meaningful sort of way, so I suggest ignoring them.
3711  They are the references environment (2.13.3), and the deluxetable environment
3712  (2.15).
3713  If you really, really need to use deluxetable, I suggest editing it in
3714  a separate file with a text editor, then using 
3715 \family sans
3716 Insert\SpecialChar menuseparator
3717 Child
3718 \begin_inset space ~
3719 \end_inset
3720
3721 Document
3722 \family default
3723  to include it in your \SpecialChar LyX
3724  document.
3725  See the 
3726 \family typewriter
3727 aas_sample.lyx
3728 \family default
3729  file to see an example of this.
3730 \end_layout
3731
3732 \begin_layout Subsection
3733 FAQs, Tips, Tricks, and Other Ruminations
3734 \end_layout
3735
3736 \begin_layout Subsubsection
3737 Getting \SpecialChar LyX
3738  and AAS\SpecialChar TeX
3739  to cooperate
3740 \end_layout
3741
3742 \begin_layout Standard
3743 It can be a bit tricky to get \SpecialChar LyX
3744  to recognize a new layout and document class.
3745  When all else fails, do this:
3746 \end_layout
3747
3748 \begin_layout Enumerate
3749 Make certain that \SpecialChar LaTeX
3750  can find AAS\SpecialChar TeX
3751 .
3752  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
3753  distribution into a
3754  directory completely unrelated to \SpecialChar LaTeX
3755  or AAS\SpecialChar TeX
3756  and run \SpecialChar LaTeX
3757  on 
3758 \family typewriter
3759 sample.tex
3760 \family default
3761 .
3762 \end_layout
3763
3764 \begin_layout Enumerate
3765 Make certain that 
3766 \family typewriter
3767 aastex.layout
3768 \family default
3769  appears in \SpecialChar LyX
3770 's 
3771 \family typewriter
3772 layouts
3773 \family default
3774  folder
3775 \end_layout
3776
3777 \begin_layout Enumerate
3778 Rerun 
3779 \family sans
3780 Tools\SpecialChar menuseparator
3781 Reconfigure
3782 \family default
3783  in \SpecialChar LyX
3784 , then restart \SpecialChar LyX
3785 .
3786 \end_layout
3787
3788 \begin_layout Enumerate
3789 Open a regular new file, not from a template.
3790  Does AAS\SpecialChar TeX
3791  appear in the class list in 
3792 \family sans
3793 Document\SpecialChar menuseparator
3794 Settings
3795 \family default
3796 ?
3797 \end_layout
3798
3799 \begin_layout Standard
3800 If you get a warning from an existing AAS\SpecialChar TeX
3801  document about not being able
3802  to find the AAS\SpecialChar TeX
3803  layout or a message about 
3804 \begin_inset Quotes eld
3805 \end_inset
3806
3807 You should not mix title layouts with normal ones
3808 \begin_inset Quotes erd
3809 \end_inset
3810
3811 , things haven't been installed correctly.
3812 \end_layout
3813
3814 \begin_layout Subsubsection
3815 \SpecialChar LaTeX
3816  error processing a table 
3817 \end_layout
3818
3819 \begin_layout Standard
3820 \SpecialChar LyX
3821 , by default, attempts to center the table caption/title.
3822  This seems to produce a bad interaction in AAS\SpecialChar TeX
3823  so you should click somewhere
3824  in the caption/title, then select 
3825 \family sans
3826 Edit\SpecialChar menuseparator
3827 Paragraph
3828 \begin_inset space ~
3829 \end_inset
3830
3831 Settings
3832 \family default
3833 , then set the 
3834 \family sans
3835 Alignment
3836 \family default
3837  to 
3838 \family sans
3839 Block
3840 \family default
3841 .
3842  This took care of it for me.
3843 \end_layout
3844
3845 \begin_layout Subsubsection
3846 References
3847 \end_layout
3848
3849 \begin_layout Standard
3850 A couple of things: 1) I have noticed some funny spacing in the reference
3851  entries in the text.
3852  When you enter the bibliography item data, make sure their is 
3853 \emph on
3854 no
3855 \emph default
3856  space between the last author and the parenthesis setting off the year;
3857  
3858 \emph on
3859 e.
3860 \begin_inset space \thinspace{}
3861 \end_inset
3862
3863 g.
3864 \begin_inset space \space{}
3865 \end_inset
3866
3867
3868 \emph default
3869 type 
3870 \family typewriter
3871 Ressler(1992)
3872 \family default
3873 , not 
3874 \family typewriter
3875 Ressler (1992)
3876 \family default
3877 .
3878  2) Entering the references at all is not obvious.
3879  The easiest thing is to start typing your first reference at the end of
3880  the document, then mark it as type 
3881 \family sans
3882 References
3883 \family default
3884 .
3885  That will put a small gray box in front of what you just typed.
3886  Click on the box to fill in the rest of the information.
3887  For new references, go to the end of an existing reference and press return.
3888  That will create a new line with its own box, etc.
3889 \end_layout
3890
3891 \begin_layout Subsubsection
3892 Including EPS files
3893 \end_layout
3894
3895 \begin_layout Standard
3896 Even though AAS\SpecialChar TeX
3897  provides its own figure commands (
3898 \family typewriter
3899
3900 \backslash
3901 plotone
3902 \family default
3903 , for example), I much prefer \SpecialChar LaTeX
3904 's standard figure commands (with the default
3905  graphicx).
3906  You can insert the 
3907 \family typewriter
3908
3909 \backslash
3910 plotone
3911 \family default
3912 , etc.
3913 \begin_inset space ~
3914 \end_inset
3915
3916 commands as \SpecialChar TeX
3917  code into a Figure Float box if you desire, but I never have
3918  much luck getting the layout right.
3919  With the standard graphics, \SpecialChar LyX
3920  will insert a 
3921 \family typewriter
3922
3923 \backslash
3924 usepackage{graphicx}
3925 \family default
3926  command into the \SpecialChar LaTeX
3927  preamble and handle the figures in the standard \SpecialChar LaTeX2e
3928  way,
3929  interspersing the figures in the text.
3930  I believe ApJ accepts figures exactly this way now; AJ might still use
3931  the 
3932 \begin_inset Quotes eld
3933 \end_inset
3934
3935 stack everything at the end
3936 \begin_inset Quotes erd
3937 \end_inset
3938
3939  technique.
3940 \end_layout
3941
3942 \begin_layout Subsubsection
3943 Things I could have done, but didn't
3944 \end_layout
3945
3946 \begin_layout Standard
3947 There are a few 
3948 \begin_inset Quotes eld
3949 \end_inset
3950
3951 pretty
3952 \begin_inset Quotes erd
3953 \end_inset
3954
3955  things I could have implemented, but chose not to.
3956  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
3957  window,
3958  even though it is double-spaced in the paper manuscript.
3959  Also, I chose not to make separate layouts for the preprint and preprint2
3960  styles.
3961  Since I assume you will spend most of your time in the plain manuscript
3962  mode anyway, I decided not to chew up more disk space with this.
3963  
3964 \end_layout
3965
3966 \begin_layout Subsection
3967 Final Caveat
3968 \end_layout
3969
3970 \begin_layout Standard
3971 Your mileage may vary.
3972  I've now had papers published by both ApJ and AJ that have had 98% of the
3973  effort done in \SpecialChar LyX
3974 ; the last 2% was the \SpecialChar LaTeX
3975  post-processing and a few cleanups.
3976  I have had no trouble with the submission process, and I'm sure the journals
3977  were never aware that there might be a difference.
3978  So, go forth and publish!
3979 \end_layout
3980
3981 \begin_layout Section
3982 AMS \SpecialChar LaTeX
3983
3984 \end_layout
3985
3986 \begin_layout Standard
3987 by 
3988 \noun on
3989 David Johnson
3990 \noun default
3991 ; updated by 
3992 \noun on
3993 Richard Heck
3994 \end_layout
3995
3996 \begin_layout Standard
3997 \begin_inset VSpace bigskip
3998 \end_inset
3999
4000
4001 \end_layout
4002
4003 \begin_layout Standard
4004 \noindent
4005 The AMS \SpecialChar LaTeX
4006  layouts are set up to conform to suggested styles for mathematical
4007  papers to be submitted to American Mathematical Society publications.
4008  The layouts are not tailored to a specific journal, but easily can be.
4009  You should refer to the AMS documentation for specific instructions for
4010  each journal (usually it will entail only changing a single line in the
4011  \SpecialChar TeX
4012  output).
4013  That documentation is available on the Web at 
4014 \begin_inset Flex URL
4015 status open
4016
4017 \begin_layout Plain Layout
4018
4019 http://www.ams.org
4020 \end_layout
4021
4022 \end_inset
4023
4024  or by ftp at 
4025 \begin_inset Flex URL
4026 status open
4027
4028 \begin_layout Plain Layout
4029
4030 ftp://ftp.ams.org/pub/tex/amslatex/
4031 \end_layout
4032
4033 \end_inset
4034
4035 .
4036  These layouts are appropriate, and useful, for any mathematical writing.
4037  
4038 \end_layout
4039
4040 \begin_layout Standard
4041 There are two basic AMS \SpecialChar LaTeX
4042  layouts: 
4043 \end_layout
4044
4045 \begin_layout Itemize
4046 amsart: The standard AMS article format.
4047 \end_layout
4048
4049 \begin_layout Itemize
4050 amsbook: the standard AMS book (really, monograph) format.
4051  
4052 \end_layout
4053
4054 \begin_layout Standard
4055 The layouts themselves contain only the minimum necessary to use the AMS
4056  classes.
4057  They do not, in particular, contain any of the `theorem' environments used
4058  for setting theorems, lemmas, and the like.
4059  These are contained, instead, in the 
4060 \begin_inset Flex Code
4061 status collapsed
4062
4063 \begin_layout Plain Layout
4064 Theorems (AMS)
4065 \end_layout
4066
4067 \end_inset
4068
4069  module, which is loaded by default when you select one of the AMS classes.
4070  (It can also be used with other classes and can be removed, if you would
4071  rather use something else.) Less commonly used environments are in the 
4072 \begin_inset Flex Code
4073 status collapsed
4074
4075 \begin_layout Plain Layout
4076 Theorems (AMS-Extended)
4077 \end_layout
4078
4079 \end_inset
4080
4081  module, which must be loaded manually.
4082 \end_layout
4083
4084 \begin_layout Standard
4085 By default, theorems and the like are numbered consecutively throughout
4086  the document, but this may be modified by loading the module 
4087 \begin_inset Flex Code
4088 status collapsed
4089
4090 \begin_layout Plain Layout
4091 Theorems (Order by Section)
4092 \end_layout
4093
4094 \end_inset
4095
4096  or, if you are using 
4097 \begin_inset Flex Code
4098 status collapsed
4099
4100 \begin_layout Plain Layout
4101 book (AMS)
4102 \end_layout
4103
4104 \end_inset
4105
4106 , the module 
4107 \begin_inset Flex Code
4108 status collapsed
4109
4110 \begin_layout Plain Layout
4111 Theorems (Order by Chapter)
4112 \end_layout
4113
4114 \end_inset
4115
4116 .
4117  These will number the results as 
4118 \begin_inset Formula $n.m$
4119 \end_inset
4120
4121 , where the first number refers to the section (or chapter) and the second
4122  refers to the total number of results so far in that section (or chapter).
4123  Many environments are also available unnumbered.
4124  These are indicated by an asterisk at the end.
4125  If you happen to want 
4126 \emph on
4127 only
4128 \emph default
4129  unnumbered results, the module 
4130 \begin_inset Flex Code
4131 status collapsed
4132
4133 \begin_layout Plain Layout
4134 Theorems (Starred)
4135 \end_layout
4136
4137 \end_inset
4138
4139  provides that option.
4140 \end_layout
4141
4142 \begin_layout Standard
4143 Note that these modules do not 
4144 \emph on
4145 have
4146 \emph default
4147  to be used with the AMS classes.
4148  It is perfectly possible to use the 
4149 \begin_inset Flex Code
4150 status collapsed
4151
4152 \begin_layout Plain Layout
4153 Theorems (AMS)
4154 \end_layout
4155
4156 \end_inset
4157
4158  module, and the others mentioned, with other classes, such as 
4159 \begin_inset Flex Code
4160 status collapsed
4161
4162 \begin_layout Plain Layout
4163 article
4164 \end_layout
4165
4166 \end_inset
4167
4168
4169 \begin_inset Flex Code
4170 status collapsed
4171
4172 \begin_layout Plain Layout
4173 report
4174 \end_layout
4175
4176 \end_inset
4177
4178
4179 \begin_inset Flex Code
4180 status collapsed
4181
4182 \begin_layout Plain Layout
4183 book (KOMA-script)
4184 \end_layout
4185
4186 \end_inset
4187
4188 , and so forth.
4189 \end_layout
4190
4191 \begin_layout Subsection
4192 What these layouts provide
4193 \end_layout
4194
4195 \begin_layout Standard
4196 There is a long list of included environments provided by these layouts.
4197  In AMS-\SpecialChar LaTeX
4198 , there is, in fact, an opportunity to define an unlimited variety
4199  of `theorem' environments.
4200  However, the AMS recommends the environments that are available in \SpecialChar LyX
4201 .
4202  
4203 \end_layout
4204
4205 \begin_layout Standard
4206 The following environments—as well as the standard environments, such as
4207  
4208 \begin_inset Flex Noun
4209 status collapsed
4210
4211 \begin_layout Plain Layout
4212 section
4213 \end_layout
4214
4215 \end_inset
4216
4217
4218 \begin_inset Flex Noun
4219 status collapsed
4220
4221 \begin_layout Plain Layout
4222 bibliography
4223 \end_layout
4224
4225 \end_inset
4226
4227
4228 \begin_inset Flex Noun
4229 status collapsed
4230
4231 \begin_layout Plain Layout
4232 title
4233 \end_layout
4234
4235 \end_inset
4236
4237
4238 \begin_inset Flex Noun
4239 status collapsed
4240
4241 \begin_layout Plain Layout
4242 author
4243 \end_layout
4244
4245 \end_inset
4246
4247 , and 
4248 \begin_inset Flex Noun
4249 status collapsed
4250
4251 \begin_layout Plain Layout
4252 date
4253 \end_layout
4254
4255 \end_inset
4256
4257 —are provided by 
4258 \begin_inset Flex Code
4259 status collapsed
4260
4261 \begin_layout Plain Layout
4262 article (AMS)
4263 \end_layout
4264
4265 \end_inset
4266
4267  and 
4268 \begin_inset Flex Code
4269 status collapsed
4270
4271 \begin_layout Plain Layout
4272 book (AMS)
4273 \end_layout
4274
4275 \end_inset
4276
4277 :
4278 \end_layout
4279
4280 \begin_layout Description
4281 Address This should be the author's permanent address.
4282 \end_layout
4283
4284 \begin_layout Description
4285 Current
4286 \begin_inset space ~
4287 \end_inset
4288
4289 Address This should be the author's temporary address at the time of submission,
4290  if different from the Address.
4291 \end_layout
4292
4293 \begin_layout Description
4294 Email Author's e-mail address
4295 \end_layout
4296
4297 \begin_layout Description
4298 URL Author's Web address, if desired.
4299 \end_layout
4300
4301 \begin_layout Description
4302 Keywords Key words or phrases used to identify specific topics discussed
4303  in the paper.
4304 \end_layout
4305
4306 \begin_layout Description
4307 Subjectclass These refer to the AMS Subject Classifications, published and
4308  described in 
4309 \emph on
4310 Mathematical Reviews
4311 \emph default
4312 .
4313  These are also available online at the AMS cites listed above.
4314 \end_layout
4315
4316 \begin_layout Description
4317 Thanks
4318 \end_layout
4319
4320 \begin_layout Description
4321 Dedicatory
4322 \end_layout
4323
4324 \begin_layout Description
4325 Translator
4326 \end_layout
4327
4328 \begin_layout Standard
4329 The following environments are provided by both the 
4330 \begin_inset Flex Code
4331 status collapsed
4332
4333 \begin_layout Plain Layout
4334 Theorems
4335 \end_layout
4336
4337 \end_inset
4338
4339  and 
4340 \begin_inset Flex Code
4341 status collapsed
4342
4343 \begin_layout Plain Layout
4344 Theorems (AMS)
4345 \end_layout
4346
4347 \end_inset
4348
4349  modules, in the latter case in both starred (unnumbered) and unstarred
4350  (numbered) versions.
4351  These same environments are provided only in the starred versions by the
4352  
4353 \begin_inset Flex Code
4354 status collapsed
4355
4356 \begin_layout Plain Layout
4357 Theorems (Starred)
4358 \end_layout
4359
4360 \end_inset
4361
4362  module:
4363 \end_layout
4364
4365 \begin_layout Theorem
4366 This is typically used for the statements of major results.
4367  
4368 \end_layout
4369
4370 \begin_layout Corollary*
4371 This is used for statements which follow fairly directly from previous statement
4372 s.
4373  Again, these can be major results.
4374  
4375 \end_layout
4376
4377 \begin_layout Lemma
4378 These are smaller results needed to prove other statements.
4379 \end_layout
4380
4381 \begin_layout Proposition
4382 These are less major results which (hopefully) add to the general theory
4383  being discussed.
4384 \end_layout
4385
4386 \begin_layout Conjecture
4387 These are statements provided without justification, which the author does
4388  not know how to prove, but which seem to be true (to the author, at least).
4389 \end_layout
4390
4391 \begin_layout Definition*
4392 Guess what this is for.
4393  The font is different for this environment than for the previous ones.
4394  
4395 \end_layout
4396
4397 \begin_layout Example*
4398 Used for examples illustrating proven results.
4399 \end_layout
4400
4401 \begin_layout Problem
4402 It's not really known what this is for.
4403  You should figure it out.
4404 \end_layout
4405
4406 \begin_layout Exercise*
4407 Write a description for this one.
4408 \end_layout
4409
4410 \begin_layout Remark
4411 This environment is also a type of theorem, usually a lesser sort of observation.
4412 \end_layout
4413
4414 \begin_layout Claim*
4415 Often used in the course of giving a proof of a larger result.
4416 \end_layout
4417
4418 \begin_layout Case
4419 Generally, these are used to break up long arguments, using specific instances
4420  of some condition.
4421  
4422 \end_layout
4423
4424 \begin_layout Case
4425 The numbering scheme for cases is on its own, not together with other numbered
4426  statements.
4427  
4428 \end_layout
4429
4430 \begin_layout Proof
4431 At the end of this environment, a QED symbol (usually a square, but it can
4432  vary with different styles) is placed.
4433  If you want to have other environments within this one—for example, Case
4434  environments—and have the QED symbol appear only after them, then the other
4435  environments need to be nested within the proof environment.
4436  See the section 
4437 \emph on
4438 Nesting Environments
4439 \emph default
4440  of the 
4441 \emph on
4442 User's Guide
4443 \emph default
4444  for information on nesting.
4445 \end_layout
4446
4447 \begin_layout Standard
4448 And these environments are provided by 
4449 \begin_inset Flex Code
4450 status collapsed
4451
4452 \begin_layout Plain Layout
4453 Theorems (AMS-Extended)
4454 \end_layout
4455
4456 \end_inset
4457
4458 :
4459 \end_layout
4460
4461 \begin_layout Criterion*
4462 A required condition.
4463 \end_layout
4464
4465 \begin_layout Algorithm*
4466 A general procedure to be used.
4467 \end_layout
4468
4469 \begin_layout Axiom*
4470 This is a property or statement taken as true within the system being discussed.
4471 \end_layout
4472
4473 \begin_layout Condition*
4474 Sometimes used to state a condition assumed within the present context of
4475  discussion.
4476 \end_layout
4477
4478 \begin_layout Note*
4479 Similar to a Remark.
4480 \end_layout
4481
4482 \begin_layout Notation*
4483 Used for the explanation of, yes, notation.
4484 \end_layout
4485
4486 \begin_layout Summary
4487 Do we really need to tell you? 
4488 \end_layout
4489
4490 \begin_layout Acknowledgement*
4491 Acknowledgement.
4492 \end_layout
4493
4494 \begin_layout Conclusion*
4495 Sometimes used at the end of a long train of argument.
4496 \end_layout
4497
4498 \begin_layout Fact
4499 Used in a way similar to Proposition, though perhaps lower on the scale.
4500 \end_layout
4501
4502 \begin_layout Standard
4503 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
4504  and AMS fonts
4505  packages.
4506  They need to be available on your system in order to use these environments.
4507 \end_layout
4508
4509 \begin_layout Section
4510 AGU journals (
4511 \family sans
4512 aguplus
4513 \family default
4514 )
4515 \end_layout
4516
4517 \begin_layout Standard
4518 by 
4519 \shape smallcaps
4520 Martin Vermeer
4521 \end_layout
4522
4523 \begin_layout Subsection
4524 Description
4525 \end_layout
4526
4527 \begin_layout Standard
4528 These are the layout files for some of the journals of the American Geophysical
4529  Society.
4530  It is assumed that you have both the AGU's own class files and AGUplus
4531  installed (everything to be found at
4532 \begin_inset Flex URL
4533 status collapsed
4534
4535 \begin_layout Plain Layout
4536
4537 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
4538 \end_layout
4539
4540 \end_inset
4541
4542 ).
4543 \end_layout
4544
4545 \begin_layout Subsection
4546 New styles
4547 \end_layout
4548
4549 \begin_layout Standard
4550 Redefined are 
4551 \family sans
4552 Paragraph
4553 \family default
4554
4555 \family sans
4556 Paragraph*
4557 \family default
4558 .
4559  They are still called this in the \SpecialChar LyX
4560  GUI, though their \SpecialChar LaTeX
4561  equivalents in the
4562  AGU classes are 
4563 \family sans
4564 Subsubsubsection
4565 \family default
4566  and 
4567 \family sans
4568 Subsubsubsection*
4569 \family default
4570 .
4571 \end_layout
4572
4573 \begin_layout Standard
4574 Newly defined styles are 
4575 \family sans
4576 Left_Header
4577 \family default
4578
4579 \family sans
4580 Right_Header
4581 \family default
4582
4583 \family sans
4584 Received
4585 \family default
4586
4587 \family sans
4588 Revised
4589 \family default
4590
4591 \family sans
4592 Accepted
4593 \family default
4594
4595 \family sans
4596 CCC
4597 \family default
4598
4599 \family sans
4600 PaperId
4601 \family default
4602
4603 \family sans
4604 AuthorAddr
4605 \family default
4606
4607 \family sans
4608 SlugComment
4609 \family default
4610 .
4611  These are mostly manuscript attributes and defined in the AGU class documentati
4612 on.
4613 \end_layout
4614
4615 \begin_layout Standard
4616 I suspect this is still badly incomplete.
4617 \end_layout
4618
4619 \begin_layout Subsection
4620 New floats
4621 \end_layout
4622
4623 \begin_layout Standard
4624
4625 \family sans
4626 Planotable
4627 \family default
4628  and 
4629 \family sans
4630 Plate
4631 \family default
4632 .
4633  We also have a new 
4634 \family sans
4635 Table_Caption
4636 \family default
4637 .
4638 \end_layout
4639
4640 \begin_layout Subsection
4641 Supported journals
4642 \end_layout
4643
4644 \begin_layout Itemize
4645
4646 \emph on
4647 Journal of Geophysical Research
4648 \emph default
4649
4650 \family typewriter
4651 jgrga.layout
4652 \family default
4653  — Martin Vermeer
4654 \end_layout
4655
4656 \begin_layout Standard
4657 Add your own, it isn't so hard! Look at the 
4658 \family typewriter
4659 jgrga.layout
4660 \family default
4661  example and 
4662 \family typewriter
4663 aguplus.inc
4664 \family default
4665 .
4666 \end_layout
4667
4668 \begin_layout Subsection
4669 Bugs and things to remember
4670 \end_layout
4671
4672 \begin_layout Standard
4673 In order to use the new layouts, you must remember to do the following for
4674  a new document:
4675 \end_layout
4676
4677 \begin_layout Enumerate
4678
4679 \emph on
4680 Turn off babel
4681 \emph default
4682 .
4683  This can be done in the 
4684 \family sans
4685 Layout\SpecialChar menuseparator
4686 Document
4687 \family default
4688  or 
4689 \family sans
4690 Document\SpecialChar menuseparator
4691 Settings
4692 \family default
4693  menu item.
4694  (AGU articles are always in English, right? So 
4695 \emph on
4696 don't
4697 \emph default
4698  choose a language.)
4699 \end_layout
4700
4701 \begin_layout Enumerate
4702 Enter 
4703 \family typewriter
4704 jgrga
4705 \family default
4706  into the document's 
4707 \family sans
4708 Extra Options
4709 \family default
4710  field.
4711  (Yes, this is a bug.)
4712 \end_layout
4713
4714 \begin_layout Enumerate
4715 Make sure you use the 
4716 \family typewriter
4717 agu.bst
4718 \family default
4719  bibliography style, by entering 
4720 \family sans
4721 agu
4722 \family default
4723  into the second field of the Bib\SpecialChar TeX
4724  inset.
4725  None of the standard styles will do.
4726 \end_layout
4727
4728 \begin_layout Section
4729 Broadway
4730 \end_layout
4731
4732 \begin_layout Standard
4733 by 
4734 \shape smallcaps
4735 Garst Reese
4736 \end_layout
4737
4738 \begin_layout Subsection
4739 Introduction
4740 \end_layout
4741
4742 \begin_layout Standard
4743 Broadway is for writing plays.
4744  The format is more decorative than Hollywood, and much less standardized.
4745  This format should be suitable for workshops.
4746 \end_layout
4747
4748 \begin_layout Subsection
4749 Special problems
4750 \end_layout
4751
4752 \begin_layout Standard
4753 The same as in Hollywood.
4754 \end_layout
4755
4756 \begin_layout Subsection
4757 Special features
4758 \end_layout
4759
4760 \begin_layout Standard
4761 Insert the 
4762 \family sans
4763 Speaker
4764 \family default
4765  names as labels then cross-reference the label to insert the name.
4766  The cross-reference dialog will show the current cast of characters.
4767 \end_layout
4768
4769 \begin_layout Subsection
4770 Paper size and Margins
4771 \end_layout
4772
4773 \begin_layout Standard
4774 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
4775 \end_layout
4776
4777 \begin_layout Subsection
4778 Environments
4779 \end_layout
4780
4781 \begin_layout Standard
4782 The following environments are available.
4783  You can use broadway.bind to get the bind keys shown at the right.
4784 \end_layout
4785
4786 \begin_layout Itemize
4787
4788 \family sans
4789 Standard
4790 \begin_inset Newline newline
4791 \end_inset
4792
4793
4794 \family default
4795 You should not have to use this, but it is here for anything that does not
4796  fit otherwise.
4797 \end_layout
4798
4799 \begin_layout Itemize
4800
4801 \family sans
4802 Narrative
4803 \begin_inset space \hfill{}
4804 \end_inset
4805
4806 M-z n
4807 \begin_inset Newline newline
4808 \end_inset
4809
4810
4811 \family default
4812 Used to describe stage setting and the action.
4813  First use of speaker names in all CAPs.
4814 \end_layout
4815
4816 \begin_layout Itemize
4817
4818 \family sans
4819 ACT
4820 \begin_inset space \hfill{}
4821 \end_inset
4822
4823 M-z a
4824 \begin_inset Newline newline
4825 \end_inset
4826
4827
4828 \family default
4829 Automatically numbered.
4830  On screen it will be arabic, but will print as Roman.
4831 \end_layout
4832
4833 \begin_layout Itemize
4834
4835 \family sans
4836 ACT*
4837 \begin_inset space \hfill{}
4838 \end_inset
4839
4840 M-z S at
4841 \begin_inset Newline newline
4842 \end_inset
4843
4844
4845 \family default
4846 Subtitle for 
4847 \family sans
4848 ACT.
4849
4850 \family default
4851  It is just centered text.
4852 \end_layout
4853
4854 \begin_layout Itemize
4855
4856 \family sans
4857 SCENE
4858 \begin_inset space \hfill{}
4859 \end_inset
4860
4861 M-z S-S
4862 \begin_inset Newline newline
4863 \end_inset
4864
4865
4866 \family default
4867 Not automatically numbered.
4868  You supply the number.
4869  This is because I couldn't figure out how.
4870 \end_layout
4871
4872 \begin_layout Itemize
4873
4874 \family sans
4875 AT_RISE:
4876 \begin_inset space \hfill{}
4877 \end_inset
4878
4879 M-z S-R
4880 \begin_inset Newline newline
4881 \end_inset
4882
4883
4884 \family default
4885 A special case of Narrative to describe the setting and action as the curtain
4886  rises.
4887 \end_layout
4888
4889 \begin_layout Itemize
4890
4891 \family sans
4892 Speaker
4893 \begin_inset space \hfill{}
4894 \end_inset
4895
4896 M-z s
4897 \begin_inset Newline newline
4898 \end_inset
4899
4900
4901 \family default
4902 The speaker's (actor's) title, centered in all CAPS.
4903 \end_layout
4904
4905 \begin_layout Itemize
4906
4907 \family sans
4908 Parenthetical
4909 \begin_inset space \hfill{}
4910 \end_inset
4911
4912 M-z p
4913 \begin_inset Newline newline
4914 \end_inset
4915
4916
4917 \family default
4918 Instructions to the speaker.
4919  The parentheses are automatically inserted.
4920  The ( will appear on screen, but both will be in the printed play.
4921  This environment is only used within 
4922 \family sans
4923 Dialogue
4924 \family default
4925 .
4926 \end_layout
4927
4928 \begin_layout Itemize
4929
4930 \family sans
4931 Dialogue
4932 \begin_inset space \hfill{}
4933 \end_inset
4934
4935 M-z d
4936 \begin_inset Newline newline
4937 \end_inset
4938
4939
4940 \family default
4941 What the Speaker says.
4942 \end_layout
4943
4944 \begin_layout Itemize
4945
4946 \family sans
4947 CURTAIN
4948 \begin_inset space \hfill{}
4949 \end_inset
4950
4951 M-z S-C
4952 \begin_inset Newline newline
4953 \end_inset
4954
4955
4956 \family default
4957 The curtain comes down.
4958 \end_layout
4959
4960 \begin_layout Itemize
4961
4962 \family sans
4963 Title
4964 \begin_inset space \hfill{}
4965 \end_inset
4966
4967 M-z S-T
4968 \end_layout
4969
4970 \begin_layout Itemize
4971
4972 \family sans
4973 Author
4974 \begin_inset space \hfill{}
4975 \end_inset
4976
4977 M-z S-A
4978 \end_layout
4979
4980 \begin_layout Itemize
4981
4982 \family sans
4983 Right_Address
4984 \begin_inset space \hfill{}
4985 \end_inset
4986
4987 M-z r
4988 \end_layout
4989
4990 \begin_layout Standard
4991 Hello there.
4992 \end_layout
4993
4994 \begin_layout Section
4995 Dinbrief
4996 \end_layout
4997
4998 \begin_layout Standard
4999 The document class 
5000 \family sans
5001 dinbrief
5002 \family default
5003  can be used to type letters according to German conventions.
5004  A template file is included in 
5005 \family typewriter
5006 .../lyx/share/templates
5007 \family default
5008  for you to use as a starting point.
5009 \end_layout
5010
5011 \begin_layout Section
5012 EGS journals (
5013 \family sans
5014 egs
5015 \family default
5016 )
5017 \end_layout
5018
5019 \begin_layout Standard
5020 by 
5021 \shape smallcaps
5022 Martin Vermeer
5023 \end_layout
5024
5025 \begin_layout Subsection
5026 Description
5027 \end_layout
5028
5029 \begin_layout Standard
5030 This is the layout file for the European Geophysical Society journals.
5031  The needed 
5032 \family typewriter
5033 egs.cls
5034 \family default
5035  can be downloaded from the web site of the EGS under 
5036 \begin_inset Flex URL
5037 status collapsed
5038
5039 \begin_layout Plain Layout
5040
5041 www.copernicus.org
5042 \end_layout
5043
5044 \end_inset
5045
5046 .
5047 \end_layout
5048
5049 \begin_layout Subsection
5050 New styles
5051 \end_layout
5052
5053 \begin_layout Standard
5054
5055 \family sans
5056 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
5057  Accepted
5058 \family default
5059
5060 \family sans
5061 Offsets
5062 \family default
5063 .
5064  The current layout file is unfortunately very unmodular and would benefit
5065  from using the various 
5066 \family typewriter
5067 std*.inc
5068 \family default
5069  file inclusions.
5070 \end_layout
5071
5072 \begin_layout Section
5073 Elsevier Journals
5074 \end_layout
5075
5076 \begin_layout Standard
5077 See the \SpecialChar LyX
5078  template file 
5079 \family typewriter
5080 elsarticle.lyx
5081 \family default
5082 .
5083  It contains all infos you need.
5084 \end_layout
5085
5086 \begin_layout Section
5087 Foils [aka 
5088 \family sans
5089 Foil\SpecialChar TeX
5090
5091 \family default
5092 ]
5093 \begin_inset CommandInset label
5094 LatexCommand label
5095 name "sec:foiltex"
5096
5097 \end_inset
5098
5099
5100 \end_layout
5101
5102 \begin_layout Standard
5103 by 
5104 \noun on
5105 Allan Rae
5106 \end_layout
5107
5108 \begin_layout Subsection
5109 Introduction
5110 \end_layout
5111
5112 \begin_layout Standard
5113 This section describes how to use \SpecialChar LyX
5114  to make slides for overhead projectors.
5115  There are two document classes that can do this: the default slides class
5116  and the 
5117 \family sans
5118 Foil\SpecialChar TeX
5119
5120 \family default
5121  slides class.
5122  This section documents the latter.
5123 \end_layout
5124
5125 \begin_layout Standard
5126 I'm going to say this again, nice and clear, so that there's no misunderstanding
5127 :
5128 \end_layout
5129
5130 \begin_layout Standard
5131 \begin_inset VSpace bigskip
5132 \end_inset
5133
5134
5135 \end_layout
5136
5137 \begin_layout Standard
5138 \align center
5139
5140 \size large
5141 This section documents the class 
5142 \begin_inset Quotes eld
5143 \end_inset
5144
5145
5146 \family sans
5147 FoilTeX
5148 \family default
5149
5150 \begin_inset Quotes erd
5151 \end_inset
5152
5153  
5154 \emph on
5155 only.
5156 \end_layout
5157
5158 \begin_layout Standard
5159 \begin_inset VSpace bigskip
5160 \end_inset
5161
5162
5163 \end_layout
5164
5165 \begin_layout Standard
5166 If you're looking for the documentation for 
5167 \begin_inset Quotes eld
5168 \end_inset
5169
5170
5171 \family sans
5172 slides (default)
5173 \family default
5174
5175 \begin_inset Quotes erd
5176 \end_inset
5177
5178 , check out section
5179 \begin_inset space ~
5180 \end_inset
5181
5182
5183 \begin_inset CommandInset ref
5184 LatexCommand ref
5185 reference "sec:slitex"
5186
5187 \end_inset
5188
5189 .
5190  If your machine doesn't have the 
5191 \family sans
5192 foils
5193 \family default
5194  class 
5195 \family sans
5196 FoilTeX
5197 \family default
5198  installed, you'll probably have to use the default 
5199 \family sans
5200 slides
5201 \family default
5202  class, which isn't quite as good as 
5203 \family sans
5204 foils.
5205 \end_layout
5206
5207 \begin_layout Standard
5208 The 
5209 \family sans
5210 foils
5211 \family default
5212  class is designed for use with version
5213 \begin_inset space ~
5214 \end_inset
5215
5216 2.1 of the 
5217 \family sans
5218 foils.cls
5219 \family default
5220  \SpecialChar LaTeX
5221  class file which is now an integral part of \SpecialChar LaTeX2e
5222 .
5223 \end_layout
5224
5225 \begin_layout Subsection
5226 Getting Started
5227 \end_layout
5228
5229 \begin_layout Standard
5230 Obviously, to use this document class, you need to select 
5231 \family sans
5232 FoilTeX
5233 \family default
5234  from the 
5235 \family sans
5236 Class
5237 \family default
5238  entry in the 
5239 \family sans
5240 Document
5241 \begin_inset space ~
5242 \end_inset
5243
5244 Layout
5245 \family default
5246  dialog.
5247  There are some settings in the 
5248 \family sans
5249 Document
5250 \begin_inset space ~
5251 \end_inset
5252
5253 Layout
5254 \family default
5255  dialog that you should know about that are specific to this class:
5256 \end_layout
5257
5258 \begin_layout Itemize
5259 Don't change the options 
5260 \family sans
5261 Sides
5262 \family default
5263  and 
5264 \family sans
5265 Columns
5266 \family default
5267  on the 
5268 \family sans
5269 Document
5270 \begin_inset space ~
5271 \end_inset
5272
5273 Layout
5274 \family default
5275  dialog.
5276  They're ignored by the 
5277 \family sans
5278 foils
5279 \family default
5280  class.
5281 \end_layout
5282
5283 \begin_layout Itemize
5284 The default font size is 20
5285 \begin_inset space \thinspace{}
5286 \end_inset
5287
5288 pt with the other options being 17
5289 \begin_inset space \thinspace{}
5290 \end_inset
5291
5292 pt, 25
5293 \begin_inset space \thinspace{}
5294 \end_inset
5295
5296 pt and 30
5297 \begin_inset space \thinspace{}
5298 \end_inset
5299
5300 pt.
5301 \end_layout
5302
5303 \begin_layout Itemize
5304 The default font is 
5305 \family sans
5306 sans
5307 \family default
5308  
5309 \family sans
5310 serif
5311 \family default
5312  but all math equations are still typeset in the usual roman font.
5313 \end_layout
5314
5315 \begin_layout Itemize
5316
5317 \family sans
5318 Foil\SpecialChar TeX
5319
5320 \family default
5321  supports A4 and Letter paper sizes as well as a special size for working
5322  with 35
5323 \begin_inset space \thinspace{}
5324 \end_inset
5325
5326 mm slides.
5327  It doesn't support A5, B5, legal or executive paper sizes.
5328 \end_layout
5329
5330 \begin_layout Itemize
5331 Don't bother changing the 
5332 \family sans
5333 Float Placement
5334 \family default
5335  settings because they are ignored anyway.
5336  All floats appear where they are defined in the text.
5337 \end_layout
5338
5339 \begin_layout Itemize
5340 The 
5341 \family sans
5342 Pagestyle
5343 \family default
5344  setting behaves a bit differently for this class.
5345  
5346 \family sans
5347 Foil\SpecialChar TeX
5348
5349 \family default
5350  provides extensive footer and header capabilities including a user-defined
5351  logo.
5352  See section
5353 \begin_inset space ~
5354 \end_inset
5355
5356
5357 \begin_inset CommandInset ref
5358 LatexCommand ref
5359 reference "sec:foilfoot"
5360
5361 \end_inset
5362
5363  for more details.
5364  The title page is treated differently to all other pages in the document
5365  and is 
5366 \emph on
5367 always
5368 \emph default
5369  unnumbered and 
5370 \emph on
5371 always
5372 \emph default
5373  has the logo centered at the bottom of the page (if one is defined).
5374  The possible page style choices and what they do are as follows:
5375 \end_layout
5376
5377 \begin_deeper
5378 \begin_layout Labeling
5379 \labelwidthstring MMMMMMM
5380
5381 \family sans
5382 \series bold
5383 empty
5384 \family default
5385 \series default
5386  The final output contains no page numbers, or other headers or footers
5387  (except footnotes of course).
5388  
5389 \end_layout
5390
5391 \begin_layout Labeling
5392 \labelwidthstring MMMMMMM
5393
5394 \family sans
5395 \series bold
5396 plain
5397 \family default
5398 \series default
5399  The final output contains page numbers centered at the bottom of the page.
5400  No other headings or footers (other than footnotes).
5401 \end_layout
5402
5403 \begin_layout Labeling
5404 \labelwidthstring MMMMMMM
5405
5406 \series bold
5407 foilheadings
5408 \series default
5409  Page numbers in lower right corner.
5410  Additional headers and footers are also shown.
5411  This is also the default.
5412 \end_layout
5413
5414 \begin_layout Labeling
5415 \labelwidthstring MMMMMMM
5416
5417 \series bold
5418 fancy
5419 \series default
5420  Gives you access to the 
5421 \family sans
5422 fancyheadings
5423 \family default
5424  package although its use with 
5425 \family sans
5426 Foil\SpecialChar TeX
5427
5428 \family default
5429  is discouraged by the writer of the 
5430 \family sans
5431 Foil\SpecialChar TeX
5432
5433 \family default
5434  package because of some potential page layout clashes.
5435 \end_layout
5436
5437 \end_deeper
5438 \begin_layout Subsubsection
5439 Extra Options
5440 \end_layout
5441
5442 \begin_layout Standard
5443 The following options may be used in the extra class options in the 
5444 \family sans
5445 Document\SpecialChar menuseparator
5446 Settings
5447 \family default
5448  dialog.
5449 \end_layout
5450
5451 \begin_layout Labeling
5452 \labelwidthstring MMMMMMx
5453
5454 \series bold
5455 35mmSlide
5456 \series default
5457  This sets up the page layout for 7.33
5458 \begin_inset space \thinspace{}
5459 \end_inset
5460
5461 in by 11
5462 \begin_inset space \thinspace{}
5463 \end_inset
5464
5465 in paper, which is about the same aspect ratio as a 35
5466 \begin_inset space \thinspace{}
5467 \end_inset
5468
5469 mm slide, making it a bit easier to work with this medium.
5470 \end_layout
5471
5472 \begin_layout Labeling
5473 \labelwidthstring MMMMMMx
5474
5475 \series bold
5476 headrule
5477 \series default
5478  Places a rule across the page below the header on every page except the
5479  title page.
5480 \end_layout
5481
5482 \begin_layout Labeling
5483 \labelwidthstring MMMMMMx
5484
5485 \series bold
5486 footrule
5487 \series default
5488  Places a rule across the page above the footer on every page except the
5489  title page.
5490 \end_layout
5491
5492 \begin_layout Labeling
5493 \labelwidthstring MMMMMMx
5494
5495 \series bold
5496 dvips
5497 \series default
5498  This is automatically set each time you create a new 
5499 \family sans
5500 foils
5501 \family default
5502  document.
5503  This option tells 
5504 \family sans
5505 Foil\SpecialChar TeX
5506
5507 \family default
5508  to use the dvips driver to rotate those pages that are set as landscape
5509  foils.
5510 \end_layout
5511
5512 \begin_layout Labeling
5513 \labelwidthstring MMMMMMx
5514
5515 \series bold
5516 landscape
5517 \series default
5518  Simply changes the page dimensions to those of a landscape page but doesn't
5519  do any rotation.
5520  Thus if you use this option you need to use an external program to rotate
5521  each page or feed your paper through your printer as landscape.
5522  Note that this option effectively reverses the roles of the 
5523 \family sans
5524 Foilhead
5525 \family default
5526  and 
5527 \family sans
5528 Rotatefoilhead
5529 \family default
5530  environments (don't worry these are described in the next section).
5531 \end_layout
5532
5533 \begin_layout Labeling
5534 \labelwidthstring MMMMMMx
5535
5536 \series bold
5537 leqno
5538 \series default
5539  Equation numbers on the left.
5540 \end_layout
5541
5542 \begin_layout Labeling
5543 \labelwidthstring MMMMMMx
5544
5545 \series bold
5546 fleqn
5547 \series default
5548  Flush-left equations.
5549 \end_layout
5550
5551 \begin_layout Subsection
5552 Supported Environments
5553 \end_layout
5554
5555 \begin_layout Standard
5556 Most of the environments commonly supported in other classes are also supported
5557  by the 
5558 \family sans
5559 foils
5560 \family default
5561  class.
5562  There are several additional environments provided by 
5563 \family sans
5564 Foil\SpecialChar TeX
5565
5566 \family default
5567  as well as a couple added by \SpecialChar LyX
5568 .
5569  The following environments are shared with other classes:
5570 \end_layout
5571
5572 \begin_layout Standard
5573 \begin_inset Flex Multiple Columns
5574 status open
5575
5576 \begin_layout Itemize
5577
5578 \family sans
5579 Standard
5580 \end_layout
5581
5582 \begin_layout Itemize
5583
5584 \family sans
5585 Itemize
5586 \end_layout
5587
5588 \begin_layout Itemize
5589
5590 \family sans
5591 Enumerate
5592 \end_layout
5593
5594 \begin_layout Itemize
5595
5596 \family sans
5597 Description
5598 \end_layout
5599
5600 \begin_layout Itemize
5601
5602 \family sans
5603 List
5604 \end_layout
5605
5606 \begin_layout Itemize
5607
5608 \family sans
5609 \SpecialChar LyX
5610 -Code
5611 \end_layout
5612
5613 \begin_layout Itemize
5614
5615 \family sans
5616 Verse
5617 \end_layout
5618
5619 \begin_layout Itemize
5620
5621 \family sans
5622 Quote
5623 \end_layout
5624
5625 \begin_layout Itemize
5626
5627 \family sans
5628 Quotation
5629 \end_layout
5630
5631 \begin_layout Itemize
5632
5633 \family sans
5634 Title
5635 \end_layout
5636
5637 \begin_layout Itemize
5638
5639 \family sans
5640 Author
5641 \end_layout
5642
5643 \begin_layout Itemize
5644
5645 \family sans
5646 Date
5647 \end_layout
5648
5649 \begin_layout Itemize
5650
5651 \family sans
5652 Abstract
5653 \end_layout
5654
5655 \begin_layout Itemize
5656
5657 \family sans
5658 Bibliography
5659 \end_layout
5660
5661 \begin_layout Itemize
5662
5663 \family sans
5664 Address
5665 \end_layout
5666
5667 \begin_layout Itemize
5668
5669 \family sans
5670 RightAddress
5671 \end_layout
5672
5673 \begin_layout Itemize
5674
5675 \family sans
5676 Caption
5677 \end_layout
5678
5679 \begin_layout Itemize
5680
5681 \family sans
5682 Comment
5683 \end_layout
5684
5685 \end_inset
5686
5687
5688 \end_layout
5689
5690 \begin_layout Standard
5691 That is, all the major environments apart from the sectioning environments.
5692  Since foils are essentially self-contained sections, with a title and body,
5693  
5694 \family sans
5695 Foil\SpecialChar TeX
5696
5697 \family default
5698  provides specific commands for starting new foils and these are:
5699 \end_layout
5700
5701 \begin_layout Itemize
5702
5703 \family sans
5704 Foilhead
5705 \end_layout
5706
5707 \begin_layout Itemize
5708
5709 \family sans
5710 Rotatefoilhead
5711 \end_layout
5712
5713 \begin_layout Standard
5714 \SpecialChar LyX
5715  also provides slightly modified versions of these two environments called:
5716 \end_layout
5717
5718 \begin_layout Itemize
5719
5720 \family sans
5721 ShortFoilhead
5722 \end_layout
5723
5724 \begin_layout Itemize
5725
5726 \family sans
5727 ShortRotatefoilhead
5728 \end_layout
5729
5730 \begin_layout Standard
5731 and the differences will be explained in the next section.
5732 \end_layout
5733
5734 \begin_layout Standard
5735 Since foils are often used in presenting ideas or new theorems and such
5736  
5737 \family sans
5738 Foil\SpecialChar TeX
5739
5740 \family default
5741  also provides a comprehensive box of goodies for presenting them:
5742 \end_layout
5743
5744 \begin_layout Standard
5745 \begin_inset Flex Multiple Columns
5746 status open
5747
5748 \begin_layout Itemize
5749
5750 \family sans
5751 Theorem
5752 \end_layout
5753
5754 \begin_layout Itemize
5755
5756 \family sans
5757 Lemma
5758 \end_layout
5759
5760 \begin_layout Itemize
5761
5762 \family sans
5763 Corollary
5764 \end_layout
5765
5766 \begin_layout Itemize
5767
5768 \family sans
5769 Proposition
5770 \end_layout
5771
5772 \begin_layout Itemize
5773
5774 \family sans
5775 Definition
5776 \end_layout
5777
5778 \begin_layout Itemize
5779
5780 \family sans
5781 Proof
5782 \end_layout
5783
5784 \begin_layout Itemize
5785
5786 \family sans
5787 Theorem*
5788 \end_layout
5789
5790 \begin_layout Itemize
5791
5792 \family sans
5793 Lemma*
5794 \end_layout
5795
5796 \begin_layout Itemize
5797
5798 \family sans
5799 Corollary*
5800 \end_layout
5801
5802 \begin_layout Itemize
5803
5804 \family sans
5805 Proposition*
5806 \end_layout
5807
5808 \begin_layout Itemize
5809
5810 \family sans
5811 Definition*
5812 \end_layout
5813
5814 \end_inset
5815
5816
5817 \end_layout
5818
5819 \begin_layout Standard
5820 The starred versions are unnumbered while the unstarred versions are numbered.
5821  There are also two list environments added by \SpecialChar LyX
5822  and these are:
5823 \end_layout
5824
5825 \begin_layout Itemize
5826
5827 \family sans
5828 TickList
5829 \end_layout
5830
5831 \begin_layout Itemize
5832
5833 \family sans
5834 CrossList
5835 \end_layout
5836
5837 \begin_layout Standard
5838
5839 \family sans
5840 Foil\SpecialChar TeX
5841
5842 \family default
5843  provides some powerful header and footer capabilities that are best set
5844  in the preamble although they may be set at any point in a document.
5845  If you want to change these settings in your document the best place to
5846  do so is at the very top of a foil, i.
5847 \begin_inset space \thinspace{}
5848 \end_inset
5849
5850 e.
5851 \emph on
5852
5853 \begin_inset space \space{}
5854 \end_inset
5855
5856
5857 \emph default
5858 straight after the foilhead.
5859 \end_layout
5860
5861 \begin_layout Standard
5862 For this purpose, the following command styles are provided [
5863 \shape smallcaps
5864 Martin Vermeer
5865 \shape default
5866 ]:
5867 \end_layout
5868
5869 \begin_layout Standard
5870 \begin_inset Flex Multiple Columns
5871 status open
5872
5873 \begin_layout Itemize
5874
5875 \family sans
5876 My
5877 \begin_inset space ~
5878 \end_inset
5879
5880 Logo
5881 \end_layout
5882
5883 \begin_layout Itemize
5884
5885 \family sans
5886 Restriction
5887 \end_layout
5888
5889 \begin_layout Itemize
5890
5891 \family sans
5892 Right
5893 \begin_inset space ~
5894 \end_inset
5895
5896 Footer
5897 \end_layout
5898
5899 \begin_layout Itemize
5900
5901 \family sans
5902 Right
5903 \begin_inset space ~
5904 \end_inset
5905
5906 Header
5907 \end_layout
5908
5909 \begin_layout Itemize
5910
5911 \family sans
5912 Left
5913 \begin_inset space ~
5914 \end_inset
5915
5916 Header
5917 \end_layout
5918
5919 \begin_deeper
5920 \begin_layout Plain Layout
5921 \begin_inset space ~
5922 \end_inset
5923
5924
5925 \end_layout
5926
5927 \end_deeper
5928 \end_inset
5929
5930
5931 \end_layout
5932
5933 \begin_layout Standard
5934 There are also a few commands provided by 
5935 \family sans
5936 Foil\SpecialChar TeX
5937
5938 \family default
5939  that aren't directly supported by \SpecialChar LyX
5940  but I'll tell you what they do and how
5941  to use them in section
5942 \begin_inset space ~
5943 \end_inset
5944
5945
5946 \begin_inset CommandInset ref
5947 LatexCommand ref
5948 reference "sec:unsuppfoils"
5949
5950 \end_inset
5951
5952 .
5953 \end_layout
5954
5955 \begin_layout Subsection
5956 Building a Set of Foils
5957 \end_layout
5958
5959 \begin_layout Standard
5960 This section will give a simple introduction to using the different environments
5961  to build a set of foils.
5962  If you want to see an example set of foils, take a look at the 
5963 \family typewriter
5964 Foils.lyx
5965 \family default
5966  file you find in \SpecialChar LyX
5967 's 
5968 \family typewriter
5969 examples
5970 \family default
5971  folder.
5972 \end_layout
5973
5974 \begin_layout Subsubsection
5975 Give It a Title Page
5976 \end_layout
5977
5978 \begin_layout Standard
5979 Unlike other classes that provide 
5980 \family sans
5981 Title
5982 \family default
5983
5984 \family sans
5985 Author
5986 \family default
5987
5988 \family sans
5989 Date
5990 \family default
5991  and 
5992 \family sans
5993 Abstract
5994 \family default
5995  environments, 
5996 \family sans
5997 foils
5998 \family default
5999  creates the title on a page of its own.
6000  If you leave out the 
6001 \family sans
6002 Date
6003 \family default
6004  environment \SpecialChar LaTeX
6005  will substitute the current date (every time you regenerate
6006  the output).
6007 \end_layout
6008
6009 \begin_layout Subsubsection
6010 Start a New Foil
6011 \end_layout
6012
6013 \begin_layout Standard
6014 As I mentioned earlier, there are four ways of starting a new foil.
6015  For portrait foils you should use 
6016 \family sans
6017 Foilhead
6018 \family default
6019  or 
6020 \family sans
6021 ShortFoilhead.
6022
6023 \family default
6024  The difference between these two environments is the amount of space between
6025  the title of the foil (the foilhead) and the body of the foil.
6026 \end_layout
6027
6028 \begin_layout Standard
6029 Landscape foils are generated using the 
6030 \family sans
6031 Rotatefoilhead
6032 \family default
6033  and 
6034 \family sans
6035 ShortRotatefoilhead
6036 \family default
6037  environments.
6038  Again the only difference is the spacing between foilhead and body.
6039  Both of the short versions have 0.5
6040 \begin_inset space ~
6041 \end_inset
6042
6043 inches less separation between the foilhead and the body.
6044  
6045 \end_layout
6046
6047 \begin_layout Standard
6048 One problem with the support for landscape foils is the requirement that
6049  you have to use the 
6050 \family typewriter
6051 dvips
6052 \family default
6053  driver to generate the PostScript output otherwise the foils won't be rotated.
6054  It is possible to get landscape foils even if you haven't got the 
6055 \family typewriter
6056 dvips
6057 \family default
6058  driver provided you can feed your foils sideways through your printer ;-)
6059 \end_layout
6060
6061 \begin_layout Subsubsection
6062 Theorems, Lemmas, Proofs and more
6063 \end_layout
6064
6065 \begin_layout Standard
6066 Due to a small bug in \SpecialChar LyX
6067  you can't have two of the same type of these environments
6068  directly following each other.
6069  They must be separated by something.
6070  If you try, you will just be extending the previous environment as if you
6071  had merged the two environments together.
6072  So, how do you get around this problem? The simplest option is to insert
6073  some text between the two environments or add a 
6074 \family sans
6075 \SpecialChar LaTeX
6076
6077 \family default
6078  environment between the two with just a 
6079 \begin_inset Quotes eld
6080 \end_inset
6081
6082
6083 \family typewriter
6084 %
6085 \family default
6086
6087 \begin_inset Quotes erd
6088 \end_inset
6089
6090  in it.
6091  This will force \SpecialChar LyX
6092  to produce two separate environments and hence the correct
6093  \SpecialChar LaTeX
6094  output.
6095  An example is provided in the example file included with the \SpecialChar LyX
6096  distribution.
6097  Remember, this problem only occurs if you are trying to place two of the
6098  same type of theorem-like environments one directly after the other.
6099 \end_layout
6100
6101 \begin_layout Subsubsection
6102 Lists
6103 \end_layout
6104
6105 \begin_layout Standard
6106 You get all the commonly supported list styles found in other classes as
6107  well as two new ones.
6108  I'll only describe the new ones here.
6109  If you want to find out more about the other list environments check out
6110  the 
6111 \emph on
6112 User's Guide.
6113
6114 \emph default
6115  If you intend to use itemized lists you might also want to read about the
6116  
6117 \family sans
6118 Itemize
6119 \begin_inset space ~
6120 \end_inset
6121
6122 Bullet
6123 \begin_inset space ~
6124 \end_inset
6125
6126 Selection
6127 \family default
6128  dialog described above in section
6129 \begin_inset space ~
6130 \end_inset
6131
6132
6133 \begin_inset CommandInset ref
6134 LatexCommand ref
6135 reference "sec:bullet"
6136
6137 \end_inset
6138
6139 .
6140 \end_layout
6141
6142 \begin_layout Standard
6143 The two new list styles, 
6144 \family sans
6145 TickList
6146 \family default
6147  and 
6148 \family sans
6149 CrossList
6150 \family default
6151 , are designed to make it easier for you to create lists of do's and don'ts
6152  or right and wrong by providing dedicated environments that use a tick
6153  or a cross as the label of the list.
6154  These lists are in fact dedicated variants of the 
6155 \family sans
6156 Itemize
6157 \family default
6158  environment.
6159  They do however require that you have the 
6160 \family typewriter
6161 psnfss
6162 \family default
6163  packages installed.
6164 \end_layout
6165
6166 \begin_layout Subsubsection
6167 Figures and Tables
6168 \end_layout
6169
6170 \begin_layout Standard
6171
6172 \family sans
6173 Foil\SpecialChar TeX
6174
6175 \family default
6176  redefines the floating tables and figures so that they appear exactly where
6177  they are in the text rather than pushing them to the top of the page or
6178  to some user specified location.
6179  In fact if you change the float placement settings they are simply ignored.
6180 \end_layout
6181
6182 \begin_layout Subsubsection
6183 Page Headers and Footers
6184 \begin_inset CommandInset label
6185 LatexCommand label
6186 name "sec:foilfoot"
6187
6188 \end_inset
6189
6190
6191 \end_layout
6192
6193 \begin_layout Standard
6194
6195 \family sans
6196 My
6197 \begin_inset space ~
6198 \end_inset
6199
6200 Logo
6201 \family default
6202  and 
6203 \family sans
6204 Restriction
6205 \family default
6206  are two commands used to control the left-footer text string.
6207  The first is meant to allow you to include a graphic logo on your foils
6208  and defaults to 
6209 \begin_inset Quotes eld
6210 \end_inset
6211
6212 -Typeset by 
6213 \family sans
6214 Foil\SpecialChar TeX
6215
6216 \family default
6217 -
6218 \begin_inset Quotes erd
6219 \end_inset
6220
6221 .
6222  While the second is meant to provide a classification for the audience,
6223  
6224 \emph on
6225 e.
6226 \begin_inset space \thinspace{}
6227 \end_inset
6228
6229 g.
6230 \emph default
6231
6232 \begin_inset space \space{}
6233 \end_inset
6234
6235 Confidential.
6236  It is empty by default.
6237 \end_layout
6238
6239 \begin_layout Standard
6240 The remaining page corners can be filled by 
6241 \family sans
6242 Right
6243 \begin_inset space ~
6244 \end_inset
6245
6246 Footer
6247 \family default
6248  (which defaults to page numbers), 
6249 \family sans
6250 Right
6251 \begin_inset space ~
6252 \end_inset
6253
6254 Header
6255 \family default
6256  (top right) and 
6257 \family sans
6258 Left
6259 \begin_inset space ~
6260 \end_inset
6261
6262 Header
6263 \family default
6264  (top left).
6265 \end_layout
6266
6267 \begin_layout Subsection
6268 Unsupported 
6269 \family sans
6270 Foil\SpecialChar TeX
6271
6272 \family default
6273  Goodies
6274 \begin_inset CommandInset label
6275 LatexCommand label
6276 name "sec:unsuppfoils"
6277
6278 \end_inset
6279
6280
6281 \end_layout
6282
6283 \begin_layout Standard
6284 All the commands mentioned below need to be set in a 
6285 \family sans
6286 \SpecialChar LaTeX
6287
6288 \family default
6289  environment or as 
6290 \family sans
6291 \SpecialChar TeX
6292
6293 \family default
6294  within another environment.
6295 \end_layout
6296
6297 \begin_layout Subsubsection
6298 Lengths
6299 \end_layout
6300
6301 \begin_layout Standard
6302 All lengths are adjusted using the 
6303 \family typewriter
6304
6305 \backslash
6306 setlength{
6307 \family default
6308 \emph on
6309 lengthname
6310 \family typewriter
6311 \emph default
6312 }{
6313 \family default
6314 \emph on
6315 newlength
6316 \family typewriter
6317 \emph default
6318 }
6319 \family default
6320  command.
6321  Where 
6322 \emph on
6323 lengthname
6324 \emph default
6325  should be replaced by the name given to the length you want to change and
6326  
6327 \emph on
6328 newlength
6329 \emph default
6330  is the length value.
6331  All lengths should be specified in units of length such as inches (
6332 \family typewriter
6333 in
6334 \family default
6335 ), millimeters (
6336 \family typewriter
6337 mm
6338 \family default
6339 ) or points (
6340 \family typewriter
6341 pt
6342 \family default
6343 ) or relative to some document or font-based length such as 
6344 \family typewriter
6345
6346 \backslash
6347 textwidth
6348 \family default
6349 .
6350  
6351 \end_layout
6352
6353 \begin_layout Standard
6354 It's possible to change the spacing between a foilhead and the body of the
6355  foil by adjusting the length specified by 
6356 \family typewriter
6357
6358 \backslash
6359 foilheadskip
6360 \family default
6361 .
6362  For example, to make 
6363 \emph on
6364 all
6365 \emph default
6366  foilheads 0.5
6367 \begin_inset space \space{}
6368 \end_inset
6369
6370 in closer to their bodies put the following in the preamble: 
6371 \family typewriter
6372
6373 \backslash
6374 setlength{
6375 \backslash
6376 foilheadskip}{-0.5in}
6377 \end_layout
6378
6379 \begin_layout Standard
6380 The spacings around floats can be adjusted by setting these lengths:
6381 \end_layout
6382
6383 \begin_layout Labeling
6384 \labelwidthstring MMMMMMMMMMM
6385
6386 \family typewriter
6387
6388 \backslash
6389 abovefloatskip
6390 \family default
6391  Separation between the text and the top of the float
6392 \end_layout
6393
6394 \begin_layout Labeling
6395 \labelwidthstring MMMMMMMMMMM
6396
6397 \family typewriter
6398
6399 \backslash
6400 abovecaptionskip
6401 \family default
6402  Separation between the float and the caption
6403 \end_layout
6404
6405 \begin_layout Labeling
6406 \labelwidthstring MMMMMMMMMMM
6407
6408 \family typewriter
6409
6410 \backslash
6411 belowcaptionskip
6412 \family default
6413  Separation between the caption and the following text
6414 \end_layout
6415
6416 \begin_layout Labeling
6417 \labelwidthstring MMMMMMMMMMM
6418
6419 \family typewriter
6420
6421 \backslash
6422 captionwidth
6423 \family default
6424  You can make the captions narrower than the surrounding text by adjusting
6425  this length.
6426  Best done relative to 
6427 \family typewriter
6428
6429 \backslash
6430 textwidth
6431 \family default
6432 .
6433 \end_layout
6434
6435 \begin_layout Standard
6436 There are also several title page related lengths that you may find useful
6437  if you have a long title or several authors:
6438 \end_layout
6439
6440 \begin_layout Labeling
6441 \labelwidthstring MMMMMMMMMMM
6442
6443 \family typewriter
6444
6445 \backslash
6446 abovetitleskip
6447 \family default
6448  Separation from headers to 
6449 \family sans
6450 Title
6451 \end_layout
6452
6453 \begin_layout Labeling
6454 \labelwidthstring MMMMMMMMMMM
6455
6456 \family typewriter
6457
6458 \backslash
6459 titleauthorskip
6460 \family default
6461  between 
6462 \family sans
6463 Title
6464 \family default
6465  and 
6466 \family sans
6467 Author
6468 \family default
6469  environments
6470 \end_layout
6471
6472 \begin_layout Labeling
6473 \labelwidthstring MMMMMMMMMMM
6474
6475 \family typewriter
6476
6477 \backslash
6478 authorauthorskip
6479 \family default
6480  between multiple 
6481 \family sans
6482 Author
6483 \family default
6484  lines
6485 \end_layout
6486
6487 \begin_layout Labeling
6488 \labelwidthstring MMMMMMMMMMM
6489
6490 \family typewriter
6491
6492 \backslash
6493 authordateskip
6494 \family default
6495  between the 
6496 \family sans
6497 Author
6498 \family default
6499  and the 
6500 \family sans
6501 Date
6502 \end_layout
6503
6504 \begin_layout Labeling
6505 \labelwidthstring MMMMMMMMMMM
6506
6507 \family typewriter
6508
6509 \backslash
6510 dateabstractskip
6511 \family default
6512  between the 
6513 \family sans
6514 Date
6515 \family default
6516  and the 
6517 \family sans
6518 Abstract
6519 \end_layout
6520
6521 \begin_layout Standard
6522 The last length related command affects all the list environments.
6523  If you place 
6524 \family typewriter
6525
6526 \backslash
6527 zerolistvertdimens
6528 \family default
6529  
6530 \emph on
6531 inside
6532 \emph default
6533  a list environment then all the vertical spacing between the list items
6534  is removed.
6535  Note that this is a command not a length so it doesn't require 
6536 \family typewriter
6537
6538 \backslash
6539 setlength
6540 \family default
6541  like the stuff mentioned above.
6542 \end_layout
6543
6544 \begin_layout Subsubsection
6545 Headers and Footers
6546 \end_layout
6547
6548 \begin_layout Standard
6549 The 
6550 \family typewriter
6551
6552 \backslash
6553 LogoOn
6554 \family default
6555  and 
6556 \family typewriter
6557
6558 \backslash
6559 LogoOff
6560 \family default
6561  commands control whether the logo in the 
6562 \family sans
6563 MyLogo
6564 \family default
6565  definition appear on a given page.
6566  If you put 
6567 \family typewriter
6568
6569 \backslash
6570 LogoOff
6571 \family default
6572  in the preamble then none of the foils will have the logo on them.
6573  If you don't want the logo on a particular page place the 
6574 \family typewriter
6575
6576 \backslash
6577 LogoOff
6578 \family default
6579  directly after the foilhead of that page and the 
6580 \family typewriter
6581
6582 \backslash
6583 LogoOn
6584 \family default
6585  directly after the next foilhead.
6586 \end_layout
6587
6588 \begin_layout Standard
6589 If you decide to use the 
6590 \family sans
6591 fancy
6592 \family default
6593  page style setting in the 
6594 \family sans
6595 Document
6596 \begin_inset space ~
6597 \end_inset
6598
6599 Layout
6600 \family default
6601  dialog you should probably add 
6602 \family typewriter
6603
6604 \backslash
6605 let
6606 \backslash
6607 headwidth
6608 \backslash
6609 textwidth
6610 \family default
6611  to your preamble so headers and footers on landscape pages are correctly
6612  placed when rotated.
6613  This is due to some clashes between the page layouts provided by the 
6614 \family sans
6615 fancyheadings
6616 \family default
6617  package and the 
6618 \family sans
6619 foils
6620 \family default
6621  class.
6622 \end_layout
6623
6624 \begin_layout Section
6625 Hollywood (Hollywood spec scripts)
6626 \end_layout
6627
6628 \begin_layout Standard
6629 by 
6630 \shape smallcaps
6631 Garst Reese
6632 \end_layout
6633
6634 \begin_layout Subsection
6635 Introduction
6636 \end_layout
6637
6638 \begin_layout Standard
6639 Getting the format of a Hollywood script right is a 
6640 \begin_inset Quotes eld
6641 \end_inset
6642
6643 rite of passage.
6644 \begin_inset Quotes erd
6645 \end_inset
6646
6647  It is designed to make the readers focus on content and to be easy and
6648  familiar for the actors to read.
6649  Each page of a script should be one minute of film.
6650  Nothing goes in a script that you cannot see or hear on screen.
6651  The courier 12 pt font should be used throughout.
6652  No italics.
6653 \end_layout
6654
6655 \begin_layout Subsection
6656 Special problems
6657 \end_layout
6658
6659 \begin_layout Standard
6660 Speakers' lines should NEVER break in mid-sentence.
6661  If a speaker's lines continue over a page break, repeat the 
6662 \family sans
6663 Speaker
6664 \family default
6665  title followed by (Cont'd).
6666 \end_layout
6667
6668 \begin_layout Subsection
6669 Special features
6670 \end_layout
6671
6672 \begin_layout Standard
6673 Insert the 
6674 \family sans
6675 Speaker
6676 \family default
6677  names as labels then cross-reference the label to insert the name.
6678  The cross-reference dialog will show the current cast of characters.
6679  You can use this to insert the speaker name in narratives also.
6680 \end_layout
6681
6682 \begin_layout Subsection
6683 Paper size and Margins
6684 \end_layout
6685
6686 \begin_layout Standard
6687 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
6688 \end_layout
6689
6690 \begin_layout Subsection
6691 Environments
6692 \end_layout
6693
6694 \begin_layout Standard
6695 The following environments are available.
6696  You can use hollywood.bind to get the bind keys shown at the right.
6697 \end_layout
6698
6699 \begin_layout Itemize
6700
6701 \family sans
6702 Standard
6703 \begin_inset Newline newline
6704 \end_inset
6705
6706
6707 \family default
6708 Used where nothing else works.
6709  Try to avoid it.
6710 \end_layout
6711
6712 \begin_layout Itemize
6713
6714 \family sans
6715 FADE_IN
6716 \family default
6717 :
6718 \begin_inset space \hfill{}
6719 \end_inset
6720
6721
6722 \family sans
6723 M-z S-I
6724 \family default
6725
6726 \begin_inset Newline newline
6727 \end_inset
6728
6729 Usually followed by something like 
6730 \begin_inset Quotes eld
6731 \end_inset
6732
6733 on Sally waking up.
6734 \begin_inset Quotes erd
6735 \end_inset
6736
6737
6738 \end_layout
6739
6740 \begin_layout Itemize
6741
6742 \family sans
6743 INT:
6744 \begin_inset space \hfill{}
6745 \end_inset
6746
6747 M-z i
6748 \begin_inset Newline newline
6749 \end_inset
6750
6751
6752 \family default
6753 Introduces a new INTERIOR camera set-up.
6754  Always followed by DAY or NIGHT, or something similar to define the lighting
6755  required.
6756  Everthing on this line in CAPS.
6757 \end_layout
6758
6759 \begin_layout Itemize
6760
6761 \family sans
6762 EXT:
6763 \begin_inset space \hfill{}
6764 \end_inset
6765
6766 M-z e
6767 \begin_inset Newline newline
6768 \end_inset
6769
6770
6771 \family default
6772 Introduces a new EXTERIOR camera set-up.
6773  Everthing on this line in CAPS.
6774 \end_layout
6775
6776 \begin_layout Itemize
6777
6778 \family sans
6779 Speaker
6780 \begin_inset space \hfill{}
6781 \end_inset
6782
6783 M-z s
6784 \begin_inset Newline newline
6785 \end_inset
6786
6787
6788 \family default
6789 The character speaking.
6790 \end_layout
6791
6792 \begin_layout Itemize
6793
6794 \family sans
6795 Parenthetical
6796 \begin_inset space \hfill{}
6797 \end_inset
6798
6799 M-z p
6800 \begin_inset Newline newline
6801 \end_inset
6802
6803
6804 \family default
6805 Instructions to the speaker.
6806  The () are automatically inserted, but only the ( will show in \SpecialChar LyX
6807 .
6808  Both will be printed.
6809 \end_layout
6810
6811 \begin_layout Itemize
6812
6813 \family sans
6814 Dialogue
6815 \begin_inset space \hfill{}
6816 \end_inset
6817
6818 M-z d
6819 \begin_inset Newline newline
6820 \end_inset
6821
6822
6823 \family default
6824 What the 
6825 \family sans
6826 Speaker
6827 \family default
6828  says.
6829 \end_layout
6830
6831 \begin_layout Itemize
6832
6833 \family sans
6834 Transition
6835 \begin_inset space \hfill{}
6836 \end_inset
6837
6838 M-z t
6839 \begin_inset Newline newline
6840 \end_inset
6841
6842
6843 \family default
6844 Camera movement instruction.
6845  e.
6846 \begin_inset space \thinspace{}
6847 \end_inset
6848
6849 g.
6850 \begin_inset space \space{}
6851 \end_inset
6852
6853 CUT TO:
6854 \end_layout
6855
6856 \begin_layout Itemize
6857
6858 \family sans
6859 FADE OUT:
6860 \begin_inset space \hfill{}
6861 \end_inset
6862
6863 M-z S-I
6864 \end_layout
6865
6866 \begin_layout Itemize
6867
6868 \family sans
6869 Author
6870 \begin_inset space \hfill{}
6871 \end_inset
6872
6873 M-z S-A
6874 \end_layout
6875
6876 \begin_layout Itemize
6877
6878 \family sans
6879 Title
6880 \begin_inset space \hfill{}
6881 \end_inset
6882
6883 M-z S-T
6884 \end_layout
6885
6886 \begin_layout Itemize
6887
6888 \family sans
6889 Right_Address
6890 \begin_inset space \hfill{}
6891 \end_inset
6892
6893 M-z r
6894 \end_layout
6895
6896 \begin_layout Subsection
6897 Script jargon
6898 \end_layout
6899
6900 \begin_layout Itemize
6901 (O.S) — off screen
6902 \end_layout
6903
6904 \begin_layout Itemize
6905 (V.0) — voice over
6906 \end_layout
6907
6908 \begin_layout Itemize
6909 b.
6910 \begin_inset space \thinspace{}
6911 \end_inset
6912
6913 g.
6914  — background
6915 \end_layout
6916
6917 \begin_layout Itemize
6918 C.U.
6919  — close-up
6920 \end_layout
6921
6922 \begin_layout Itemize
6923 PAN — camera movement
6924 \end_layout
6925
6926 \begin_layout Itemize
6927 INSERT — cut to close-up of
6928 \end_layout
6929
6930 \begin_layout Section
6931 ijmpc and ijmpd
6932 \end_layout
6933
6934 \begin_layout Standard
6935 by 
6936 \noun on
6937 Panayotis Papasotiriou
6938 \end_layout
6939
6940 \begin_layout Subsection
6941 Overview
6942 \end_layout
6943
6944 \begin_layout Standard
6945 The ijmpc package is a set of macros that facilitates electronic manuscript
6946  submission to the 
6947 \emph on
6948 International Journal of Modern Physics C
6949 \emph default
6950 .
6951  Similarly, the ijmpd package is for creating manuscripts to be submitted
6952  to the 
6953 \emph on
6954 International Journal of Modern Physics D
6955 \emph default
6956 .
6957  Both journals are published by World Scientific.
6958  The corresponding document classes are named 
6959 \family typewriter
6960 ws-ijmpc.cls
6961 \family default
6962  and 
6963 \family typewriter
6964 ws-ijmpd.cls
6965 \family default
6966 , respectively.
6967  These files, together with instructions for the authors, can be downloaded
6968  from the sites 
6969 \begin_inset Flex URL
6970 status collapsed
6971
6972 \begin_layout Plain Layout
6973
6974 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
6975 \end_layout
6976
6977 \end_inset
6978
6979  and 
6980 \begin_inset Flex URL
6981 status collapsed
6982
6983 \begin_layout Plain Layout
6984
6985 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
6986 \end_layout
6987
6988 \end_inset
6989
6990 .
6991  Both packages are modified versions of the standard 
6992 \begin_inset Quotes eld
6993 \end_inset
6994
6995 article
6996 \begin_inset Quotes erd
6997 \end_inset
6998
6999  package, and they are almost (but not exactly) identical.
7000  Most of their features are supported by \SpecialChar LyX
7001 .
7002  I have used \SpecialChar LyX
7003  successfully to write articles submitted to both journals
7004  without any problem.
7005 \end_layout
7006
7007 \begin_layout Subsection
7008 Writing a paper
7009 \end_layout
7010
7011 \begin_layout Standard
7012 As usual, the easiest way to write a paper is to start with a template.
7013  Click on 
7014 \family sans
7015 File\SpecialChar menuseparator
7016 New from
7017 \family default
7018  
7019 \family sans
7020 Template
7021 \family default
7022 , then choose the 
7023 \family typewriter
7024 ijmpc.lyx
7025 \family default
7026  or 
7027 \family typewriter
7028 ijmpd.lyx
7029 \family default
7030  template.
7031  This will give an (almost) empty document that includes the most common
7032  fields found in a manuscript.
7033  Simply overwrite the existing text (including the brackets, 
7034 \family typewriter
7035 <>
7036 \family default
7037 ) with your text.
7038  You should keep in mind the following remarks.
7039 \end_layout
7040
7041 \begin_layout Enumerate
7042 \SpecialChar LyX
7043  won't let you change the font size and the page style of the document,
7044  because such modifications are not allowed by both packages.
7045 \end_layout
7046
7047 \begin_layout Enumerate
7048 The language of the document should not be changed.
7049  Before previewing your paper, be sure that the babel package is not used.
7050  To do this, click on 
7051 \family sans
7052 Tools\SpecialChar menuseparator
7053 Preferences
7054 \family default
7055 , select the 
7056 \family sans
7057 Lang Opts
7058 \family default
7059  tab, deselect the 
7060 \family sans
7061 Use babel
7062 \family default
7063  checkbox in the language settings, and click on 
7064 \family sans
7065 Apply
7066 \family default
7067  (or 
7068 \family sans
7069 Save
7070 \family default
7071 , if you wish to make this change permanent).
7072 \end_layout
7073
7074 \begin_layout Enumerate
7075 The 
7076 \begin_inset Quotes eld
7077 \end_inset
7078
7079 Keywords
7080 \begin_inset Quotes erd
7081 \end_inset
7082
7083  style must be used to define keywords.
7084 \end_layout
7085
7086 \begin_layout Enumerate
7087 The ijmpc package provides a style named 
7088 \begin_inset Quotes eld
7089 \end_inset
7090
7091 Classification Codes
7092 \begin_inset Quotes erd
7093 \end_inset
7094
7095 , which can be used to define classification codes, such as PACS numbers.
7096  Note that this facility is not supported by the ijmpd package.
7097 \end_layout
7098
7099 \begin_layout Enumerate
7100 Several new environments are available: 
7101 \begin_inset Quotes eld
7102 \end_inset
7103
7104 Definition
7105 \begin_inset Quotes erd
7106 \end_inset
7107
7108
7109 \begin_inset Quotes eld
7110 \end_inset
7111
7112 Step
7113 \begin_inset Quotes erd
7114 \end_inset
7115
7116
7117 \begin_inset Quotes eld
7118 \end_inset
7119
7120 Example
7121 \begin_inset Quotes erd
7122 \end_inset
7123
7124
7125 \begin_inset Quotes eld
7126 \end_inset
7127
7128 Remark
7129 \begin_inset Quotes erd
7130 \end_inset
7131
7132
7133 \begin_inset Quotes eld
7134 \end_inset
7135
7136 Notation
7137 \begin_inset Quotes erd
7138 \end_inset
7139
7140
7141 \begin_inset Quotes eld
7142 \end_inset
7143
7144 Theorem
7145 \begin_inset Quotes erd
7146 \end_inset
7147
7148
7149 \begin_inset Quotes eld
7150 \end_inset
7151
7152 Proof
7153 \begin_inset Quotes erd
7154 \end_inset
7155
7156
7157 \begin_inset Quotes eld
7158 \end_inset
7159
7160 Corollary
7161 \begin_inset Quotes erd
7162 \end_inset
7163
7164
7165 \begin_inset Quotes eld
7166 \end_inset
7167
7168 Lemma
7169 \begin_inset Quotes erd
7170 \end_inset
7171
7172
7173 \begin_inset Quotes eld
7174 \end_inset
7175
7176 Proposition
7177 \begin_inset Quotes erd
7178 \end_inset
7179
7180
7181 \begin_inset Quotes eld
7182 \end_inset
7183
7184 Prop
7185 \begin_inset Quotes erd
7186 \end_inset
7187
7188
7189 \begin_inset Quotes eld
7190 \end_inset
7191
7192 Question
7193 \begin_inset Quotes erd
7194 \end_inset
7195
7196
7197 \begin_inset Quotes eld
7198 \end_inset
7199
7200 Claim
7201 \begin_inset Quotes erd
7202 \end_inset
7203
7204 , and 
7205 \begin_inset Quotes eld
7206 \end_inset
7207
7208 Conjecture
7209 \begin_inset Quotes erd
7210 \end_inset
7211
7212 .
7213  Their use is more or less obvious.
7214  \SpecialChar LyX
7215  supports all these environments; it will use the proper label, text style,
7216  and numbering scheme for each of them.
7217 \end_layout
7218
7219 \begin_layout Enumerate
7220 Both packages use basic citations; the natbib package should not be used.
7221  In \SpecialChar LyX
7222 , citation references are shown as usual; in the output, citations are
7223  shown as superscripts.
7224  If you want to use a citation as normal text, you should use the 
7225 \family typewriter
7226 refcite
7227 \family default
7228  command, e.
7229 \begin_inset space \thinspace{}
7230 \end_inset
7231
7232 g.
7233 \begin_inset space \space{}
7234 \end_inset
7235
7236
7237 \begin_inset Quotes eld
7238 \end_inset
7239
7240 See Ref.
7241 \begin_inset space \space{}
7242 \end_inset
7243
7244
7245 \family typewriter
7246
7247 \backslash
7248 refcite{key}
7249 \family default
7250
7251 \begin_inset Quotes erd
7252 \end_inset
7253
7254 .
7255 \end_layout
7256
7257 \begin_layout Enumerate
7258 There is no 
7259 \begin_inset Quotes eld
7260 \end_inset
7261
7262 Acknowledgments
7263 \begin_inset Quotes erd
7264 \end_inset
7265
7266  section in both packages.
7267  To put acknowledgments, just use the 
7268 \begin_inset Quotes eld
7269 \end_inset
7270
7271 Section*
7272 \begin_inset Quotes erd
7273 \end_inset
7274
7275  environment.
7276 \end_layout
7277
7278 \begin_layout Enumerate
7279 Appendices may be added to the paper, 
7280 \emph on
7281 after
7282 \emph default
7283  the Acknowledgments and 
7284 \shape italic
7285 before
7286 \shape default
7287  the References.
7288  \SpecialChar LyX
7289  provides a special environment, called 
7290 \begin_inset Quotes eld
7291 \end_inset
7292
7293 Appendices Section
7294 \begin_inset Quotes erd
7295 \end_inset
7296
7297  which marks the beginning of the appendices.
7298  This environment should be left blank; it just sends a \SpecialChar LaTeX
7299  command, but nothing
7300  is really printed.
7301  In \SpecialChar LyX
7302 , the word 
7303 \begin_inset Quotes eld
7304 \end_inset
7305
7306 Appendix
7307 \begin_inset Quotes erd
7308 \end_inset
7309
7310  is printed with blue letters, as a signal that all sections after that
7311  point are appendices.
7312  To write an appendix, use the 
7313 \begin_inset Quotes eld
7314 \end_inset
7315
7316 Appendix
7317 \begin_inset Quotes erd
7318 \end_inset
7319
7320  environment.
7321  \SpecialChar LyX
7322  will number each appendix with capital letters, as required by both journals.
7323  Note that 
7324 \begin_inset Quotes eld
7325 \end_inset
7326
7327 Appendices Section
7328 \begin_inset Quotes erd
7329 \end_inset
7330
7331  
7332 \emph on
7333 must
7334 \emph default
7335  be present before the first appendix; if not, all appendices will be numbered
7336  as normal sections in the output.
7337 \end_layout
7338
7339 \begin_layout Enumerate
7340 The ijmpc and the ijmpd packages use the 
7341 \family typewriter
7342 tbl
7343 \family default
7344  command to implement table captions.
7345  As a result, a table created by \SpecialChar LyX
7346  is printed correctly, but its caption
7347  is ignored.
7348  However, you can use some \SpecialChar TeX
7349  code to overcome this problem, so that captions
7350  are printed as expected.
7351  To do so, create a float table as usual, remove the caption, and replace
7352  it with the \SpecialChar TeX
7353  code 
7354 \family typewriter
7355
7356 \backslash
7357 tbl{
7358 \emph on
7359 your table caption
7360 \emph default
7361 }{
7362 \family default
7363  (sic); you must also the \SpecialChar TeX
7364  code 
7365 \family typewriter
7366 }
7367 \family default
7368  immediately after the tabular material.
7369  Study the example table included in the template files to see how this
7370  trick is implemented.
7371  Alternatively, If you need table captions, you should implement the whole
7372  table float in a 
7373 \family typewriter
7374 .tex
7375 \family default
7376  file, then include this file to the \SpecialChar LyX
7377  document (
7378 \family sans
7379 Insert\SpecialChar menuseparator
7380 File\SpecialChar menuseparator
7381 Child
7382 \begin_inset space ~
7383 \end_inset
7384
7385 Document
7386 \family default
7387 ).
7388  Details on how to create a table float can be found in the files 
7389 \family typewriter
7390 ws-ijmpc.tex
7391 \family default
7392  and 
7393 \family typewriter
7394 ws-ijmpd.tex
7395 \family default
7396 , included in the corresponding packages.
7397 \end_layout
7398
7399 \begin_layout Subsection
7400 Preparing a paper for submission
7401 \end_layout
7402
7403 \begin_layout Standard
7404 Before you submit your paper you must export the \SpecialChar LyX
7405  document as a \SpecialChar LaTeX
7406  file (
7407 \family sans
7408 File\SpecialChar menuseparator
7409 Export\SpecialChar menuseparator
7410 \SpecialChar LaTeX
7411
7412 \family default
7413 )
7414 \begin_inset Foot
7415 status open
7416
7417 \begin_layout Plain Layout
7418 Actually you have the choice between \SpecialChar LaTeX
7419  (plain) and pdflatex.
7420  If you intend to use pdflatex to prepare the paper, you should use the
7421  pdflatex option so that included graphics are converted to PDF format,
7422  ready for use by pdflatex.
7423 \end_layout
7424
7425 \end_inset
7426
7427 , then make the following changes to the resulting 
7428 \family typewriter
7429 .tex
7430 \family default
7431  file.
7432 \end_layout
7433
7434 \begin_layout Enumerate
7435 Remove the comment lines before the 
7436 \family typewriter
7437
7438 \backslash
7439 documentclass
7440 \family default
7441  command.
7442 \end_layout
7443
7444 \begin_layout Enumerate
7445 Remove everything between (and including) the 
7446 \family typewriter
7447
7448 \backslash
7449 makeatletter
7450 \family default
7451  and 
7452 \family typewriter
7453
7454 \backslash
7455 makeatother
7456 \family default
7457  commands, except for any commands you specifically put into the \SpecialChar LaTeX
7458  preamble.
7459 \end_layout
7460
7461 \begin_layout Standard
7462 The modified 
7463 \family typewriter
7464 .tex
7465 \family default
7466  file should be saved and processed through \SpecialChar LaTeX
7467  as many times as necessary.
7468  You may also want to check the resulting 
7469 \family typewriter
7470 .dvi
7471 \family default
7472  document.
7473 \end_layout
7474
7475 \begin_layout Subsection
7476 Use of \SpecialChar TeX
7477  code
7478 \end_layout
7479
7480 \begin_layout Standard
7481 The use of \SpecialChar TeX
7482  code is reduced to two commands, which must be placed at the
7483  top of the document.
7484  If you started writing your paper by using the 
7485 \family typewriter
7486 ijmpc.lyx
7487 \family default
7488  or the 
7489 \family typewriter
7490 ijmpd.lyx
7491 \family default
7492  template, the \SpecialChar TeX
7493  code needed is already in its place; you usually don't need
7494  to delete it.
7495  You may only modify the first \SpecialChar TeX
7496  code to specify the information printed
7497  to the top of odd and even pages (authors' names and short paper's title,
7498  respectively).
7499  This \SpecialChar TeX
7500  code must have the form 
7501 \family typewriter
7502
7503 \backslash
7504 markboth{Authors' Names}{Short Paper's Title}
7505 \family default
7506 .
7507 \end_layout
7508
7509 \begin_layout Section
7510 iopart
7511 \end_layout
7512
7513 \begin_layout Standard
7514 by 
7515 \noun on
7516 Uwe Stöhr
7517 \end_layout
7518
7519 \begin_layout Subsection
7520 Overview
7521 \end_layout
7522
7523 \begin_layout Standard
7524 The iopart package provides a document class to create electronic manuscript
7525  submission to the journals published by the Institute of Physics.
7526  Instructions for the authors how to create a paper using the iopart class
7527  can be downloaded together with the iopart package from the site 
7528 \begin_inset Flex URL
7529 status collapsed
7530
7531 \begin_layout Plain Layout
7532
7533 ftp://ftp.iop.org/pub/journals/latex2e
7534 \end_layout
7535
7536 \end_inset
7537
7538 .
7539 \end_layout
7540
7541 \begin_layout Subsection
7542 Writing a paper
7543 \end_layout
7544
7545 \begin_layout Standard
7546 The easiest way to write a paper is to start with the file 
7547 \emph on
7548 IOP-article.lyx
7549 \emph default
7550  that is available in \SpecialChar LyX
7551 's examples files folder.
7552  Open this file, save it under a new name, and start writing.
7553  The example file explains how to use the special text environments.
7554  Here are the most important advices:
7555 \end_layout
7556
7557 \begin_layout Itemize
7558 To be able to compile your document to a PDF, PS, or DVI, ensure that the
7559  two options 
7560 \family sans
7561 Use AMS math package
7562 \family default
7563  in the document settings under 
7564 \family sans
7565 Math Options
7566 \family default
7567  are not used!
7568 \end_layout
7569
7570 \begin_layout Itemize
7571
7572 \size normal
7573 The title environment defines the kind of your paper.
7574  So use one of the following environments for the title:
7575 \end_layout
7576
7577 \begin_deeper
7578 \begin_layout Itemize
7579
7580 \family sans
7581 \size normal
7582 Title
7583 \family default
7584  for a Paper
7585 \end_layout
7586
7587 \begin_layout Itemize
7588
7589 \family sans
7590 \size normal
7591 Review
7592 \family default
7593  for a Review
7594 \end_layout
7595
7596 \begin_layout Itemize
7597
7598 \family sans
7599 \size normal
7600 Topical
7601 \family default
7602  for a Topical review
7603 \end_layout
7604
7605 \begin_layout Itemize
7606
7607 \family sans
7608 \size normal
7609 Comment
7610 \family default
7611  for a Comment
7612 \end_layout
7613
7614 \begin_layout Itemize
7615
7616 \family sans
7617 \size normal
7618 Note
7619 \family default
7620  for a Note
7621 \end_layout
7622
7623 \begin_layout Itemize
7624
7625 \family sans
7626 \size normal
7627 Paper
7628 \family default
7629  for a Paper (same as Title)
7630 \end_layout
7631
7632 \begin_layout Itemize
7633
7634 \family sans
7635 \size normal
7636 Prelim
7637 \family default
7638  for a Preliminary communication
7639 \end_layout
7640
7641 \begin_layout Itemize
7642
7643 \family sans
7644 \size normal
7645 Rapid
7646 \family default
7647  for a Rapid communication
7648 \end_layout
7649
7650 \begin_layout Itemize
7651
7652 \family sans
7653 \size normal
7654 Letter
7655 \family default
7656  for a Letter to the editor
7657 \end_layout
7658
7659 \end_deeper
7660 \begin_layout Itemize
7661
7662 \size normal
7663 All title environments except of 
7664 \family sans
7665 Letter
7666 \family default
7667  can have an optional short title.
7668 \end_layout
7669
7670 \begin_layout Itemize
7671 There is a general title environment 
7672 \family sans
7673 Article
7674 \family default
7675  which is not directly supported by the \SpecialChar LyX
7676 .
7677  This can be used as \SpecialChar TeX
7678  code when your document doesn't fit into one of the
7679  other title types.
7680 \end_layout
7681
7682 \begin_layout Standard
7683 For more informations like hints for special table and formula formatting,
7684  look at the IOP author guidelines.
7685 \end_layout
7686
7687 \begin_layout Section
7688 Kluwer
7689 \end_layout
7690
7691 \begin_layout Standard
7692 by 
7693 \noun on
7694 Panayotis Papasotiriou
7695 \end_layout
7696
7697 \begin_layout Subsection
7698 Overview
7699 \end_layout
7700
7701 \begin_layout Standard
7702 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
7703  that facilitates electronic manuscript submission to the journals they
7704  publish.
7705  Most known of them (at least in my domain of interest) are 
7706 \emph on
7707 Astrophysics and Space Science
7708 \emph default
7709  and 
7710 \emph on
7711 Solar Physics
7712 \emph default
7713 , but there are many others (see a complete list at 
7714 \begin_inset Flex URL
7715 status open
7716
7717 \begin_layout Plain Layout
7718
7719 http://www.wkap.nl/jrnllist.htm/JRNLHOME
7720 \end_layout
7721
7722 \end_inset
7723
7724 ).
7725  The Kluwer package may be downloaded from the site 
7726 \begin_inset Flex URL
7727 status collapsed
7728
7729 \begin_layout Plain Layout
7730
7731 http://www.wkap.nl/kaphtml.htm/STYLEFILES
7732 \end_layout
7733
7734 \end_inset
7735
7736 .
7737  A complete user guide is contained in that package (but it can also be
7738  downloaded separately).
7739 \end_layout
7740
7741 \begin_layout Standard
7742 \SpecialChar LyX
7743  supports many features of the package but not everything.
7744  However, the \SpecialChar TeX
7745  code needed is reduced to some 
7746 \begin_inset Quotes eld
7747 \end_inset
7748
7749 peculiar
7750 \begin_inset Quotes erd
7751 \end_inset
7752
7753  commands of the package (see
7754 \begin_inset space ~
7755 \end_inset
7756
7757
7758 \begin_inset CommandInset ref
7759 LatexCommand ref
7760 reference "subsec:kluwer_peculiarities"
7761
7762 \end_inset
7763
7764 ).
7765  I have recently used \SpecialChar LyX
7766  to write an article submitted to the 
7767 \emph on
7768 Astrophysics and Space Science
7769 \emph default
7770  without any problem.
7771 \end_layout
7772
7773 \begin_layout Subsection
7774 Writing a paper
7775 \end_layout
7776
7777 \begin_layout Standard
7778 The easiest way to write a paper is to start with the Kluwer template file.
7779  Click on 
7780 \family sans
7781 File\SpecialChar menuseparator
7782 New from
7783 \family default
7784  
7785 \family sans
7786 Template
7787 \family default
7788 , then choose the 
7789 \family typewriter
7790 kluwer.lyx
7791 \family default
7792  template.
7793  This will give an (almost) empty document that includes the most common
7794  fields found in a manuscript and a short description of their use.
7795  As in most templates, simply overwrite the existing text (including the
7796  brackets, 
7797 \family typewriter
7798 <>
7799 \family default
7800 ) with the correct information.
7801 \end_layout
7802
7803 \begin_layout Subsection
7804 Preparing a paper for submission
7805 \end_layout
7806
7807 \begin_layout Standard
7808 As in the AAS\SpecialChar TeX
7809  package, before you submit your paper to a journal you must
7810  
7811 \begin_inset Quotes eld
7812 \end_inset
7813
7814 postprocess
7815 \begin_inset Quotes erd
7816 \end_inset
7817
7818  it as follows.
7819 \end_layout
7820
7821 \begin_layout Enumerate
7822 Export your paper as a \SpecialChar LaTeX
7823  file.
7824  To do this, click on 
7825 \family sans
7826 File\SpecialChar menuseparator
7827 Export\SpecialChar menuseparator
7828 \SpecialChar LaTeX
7829
7830 \family default
7831 .
7832  
7833 \end_layout
7834
7835 \begin_layout Enumerate
7836 Edit the resulting 
7837 \family typewriter
7838 .tex
7839 \family default
7840  file with a text editor and make the following changes
7841 \end_layout
7842
7843 \begin_deeper
7844 \begin_layout Enumerate
7845 remove the comment lines before the 
7846 \family typewriter
7847
7848 \backslash
7849 documentclass
7850 \family default
7851  command,
7852 \end_layout
7853
7854 \begin_layout Enumerate
7855 remove everything between (and including) the 
7856 \family typewriter
7857
7858 \backslash
7859 makeatletter
7860 \family default
7861  and 
7862 \family typewriter
7863
7864 \backslash
7865 makeatother
7866 \family default
7867  commands, except for any commands you specifically put into the \SpecialChar LaTeX
7868  preamble.
7869 \end_layout
7870
7871 \begin_layout Standard
7872 Save the resulting 
7873 \family typewriter
7874 .tex
7875 \family default
7876  file.
7877 \end_layout
7878
7879 \end_deeper
7880 \begin_layout Enumerate
7881 Run the 
7882 \family typewriter
7883 .tex
7884 \family default
7885  file through \SpecialChar LaTeX
7886  as many times as necessary (usually up to three).
7887 \end_layout
7888
7889 \begin_layout Enumerate
7890 View the resulting 
7891 \family typewriter
7892 .dvi
7893 \family default
7894  document using, e.
7895 \begin_inset space \thinspace{}
7896 \end_inset
7897
7898 g.
7899 \begin_inset space \space{}
7900 \end_inset
7901
7902
7903 \family sans
7904 xdvi
7905 \family default
7906 , and check if everything is OK (it should, if you didn't make any mistake).
7907 \end_layout
7908
7909 \begin_layout Subsection
7910 \begin_inset Quotes eld
7911 \end_inset
7912
7913 Peculiarities
7914 \begin_inset Quotes erd
7915 \end_inset
7916
7917  of the Kluwer package
7918 \begin_inset CommandInset label
7919 LatexCommand label
7920 name "subsec:kluwer_peculiarities"
7921
7922 \end_inset
7923
7924
7925 \end_layout
7926
7927 \begin_layout Standard
7928 The Kluwer package has the following 
7929 \begin_inset Quotes eld
7930 \end_inset
7931
7932 peculiarities
7933 \begin_inset Quotes erd
7934 \end_inset
7935
7936 .
7937 \end_layout
7938
7939 \begin_layout Enumerate
7940 It is possible to write multiple articles in the same \SpecialChar LaTeX
7941  file
7942 \begin_inset Foot
7943 status collapsed
7944
7945 \begin_layout Plain Layout
7946 I can't imagine any good reason to do this.
7947 \end_layout
7948
7949 \end_inset
7950
7951 .
7952  Each article must be included in the environment 
7953 \begin_inset Quotes eld
7954 \end_inset
7955
7956 article
7957 \begin_inset Quotes erd
7958 \end_inset
7959
7960 .
7961  Unfortunately, this environment cannot be omitted, even if you write just
7962  one article.
7963  Therefore, each article starts with the command 
7964 \family typewriter
7965
7966 \backslash
7967 begin{article}
7968 \family default
7969  and, obviously, ends with the command 
7970 \family typewriter
7971
7972 \backslash
7973 end{article}
7974 \family default
7975 .
7976  Although this can be implemented in \SpecialChar LyX
7977 , I didn't included it, since it looks
7978  ugly and can confuse the novice user.
7979  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
7980  code (the
7981  well-known 
7982 \begin_inset Quotes eld
7983 \end_inset
7984
7985 \SpecialChar TeX
7986  code
7987 \begin_inset Quotes erd
7988 \end_inset
7989
7990 ).
7991 \end_layout
7992
7993 \begin_layout Enumerate
7994 Information given at the beginning of the article (i.
7995 \begin_inset space \thinspace{}
7996 \end_inset
7997
7998 e.
7999 \begin_inset space \space{}
8000 \end_inset
8001
8002 title, subtitle, author, institution, running title, running author, abstract
8003  and keywords) must be included in an environment called 
8004 \begin_inset Quotes eld
8005 \end_inset
8006
8007 opening
8008 \begin_inset Quotes erd
8009 \end_inset
8010
8011 .
8012  This is not implemented in \SpecialChar LyX
8013 , so you must enter title, subtitle etc.
8014 \begin_inset space ~
8015 \end_inset
8016
8017 between two \SpecialChar TeX
8018  code lines (
8019 \family typewriter
8020
8021 \backslash
8022 begin{opening}
8023 \family default
8024  and 
8025 \family typewriter
8026
8027 \backslash
8028 end{opening}
8029 \family default
8030 ).
8031 \end_layout
8032
8033 \begin_layout Enumerate
8034 According to the user manual, the label of each bibliography item must be
8035  written as 
8036 \family typewriter
8037
8038 \backslash
8039 protect
8040 \backslash
8041 citeauthoryear{
8042 \family default
8043 \emph on
8044 author(s)
8045 \family typewriter
8046 \emph default
8047 }{
8048 \family default
8049 \emph on
8050 year
8051 \family typewriter
8052 \emph default
8053 }
8054 \family default
8055 .
8056 \end_layout
8057
8058 \begin_layout Standard
8059 The 
8060 \family typewriter
8061 kluwer.lyx
8062 \family default
8063  template takes care of all these 
8064 \begin_inset Quotes eld
8065 \end_inset
8066
8067 peculiarities
8068 \begin_inset Quotes erd
8069 \end_inset
8070
8071 .
8072  If you start a new paper using this template you don't need to do anything
8073  special.
8074  Just 
8075 \end_layout
8076
8077 \begin_layout Enumerate
8078 don't delete the \SpecialChar TeX
8079  code included in the template, and
8080 \end_layout
8081
8082 \begin_layout Enumerate
8083 copy the example bibliography item included in the template and modify it
8084  as necessary to enter new bibliography items.
8085 \end_layout
8086
8087 \begin_layout Section
8088 Koma-Script
8089 \end_layout
8090
8091 \begin_layout Standard
8092 by 
8093 \noun on
8094 Bernd Rellermeyer
8095 \end_layout
8096
8097 \begin_layout Subsection
8098 Overview
8099 \end_layout
8100
8101 \begin_layout Standard
8102 The \SpecialChar LyX
8103  document classes 
8104 \emph on
8105 article (koma-script)
8106 \emph default
8107
8108 \emph on
8109 report (koma-script)
8110 \emph default
8111
8112 \emph on
8113 book
8114 \emph default
8115  
8116 \emph on
8117 (koma-script)
8118 \emph default
8119 , and 
8120 \emph on
8121 letter
8122 \emph default
8123  
8124 \emph on
8125 (koma-script)
8126 \emph default
8127  correspond to the \SpecialChar LaTeX
8128  document classes 
8129 \family typewriter
8130 scrartcl.cls
8131 \family default
8132
8133 \family typewriter
8134 scrreprt.cls
8135 \family default
8136
8137 \family typewriter
8138 scrbook.cls
8139 \family default
8140 , and 
8141 \family typewriter
8142 scrlettr.cls
8143 \family default
8144 , resp.
8145 \begin_inset space ~
8146 \end_inset
8147
8148 of the Koma-Script family.
8149  They are replacements for the standard document classes 
8150 \family typewriter
8151 article.cls
8152 \family default
8153
8154 \family typewriter
8155 report.cls
8156 \family default
8157
8158 \family typewriter
8159 book.cls
8160 \family default
8161  and 
8162 \family typewriter
8163 letter.cls
8164 \family default
8165 , resp., and fit better to European typography conventions in a number of
8166  points.
8167 \end_layout
8168
8169 \begin_layout Itemize
8170 Standard character size is 11pt in 
8171 \emph on
8172 article (koma-script)
8173 \emph default
8174
8175 \emph on
8176 report (koma-script)
8177 \emph default
8178 , and 
8179 \emph on
8180 book (koma-script)
8181 \emph default
8182 , and 12pt in 
8183 \emph on
8184 letter (koma-script)
8185 \emph default
8186 .
8187 \end_layout
8188
8189 \begin_layout Itemize
8190 Headings, labels of the description environment, and a number of elements
8191  of the 
8192 \emph on
8193 letter (koma-script)
8194 \emph default
8195  document class are set in a bold sans serif font.
8196 \begin_inset Foot
8197 status collapsed
8198
8199 \begin_layout Plain Layout
8200 There is a big difference between the bold sans serif old cm fonts and new
8201  ec fonts, especially in the appearance of headings.
8202  In comparison, the ec bold sans serif fonts look a bit thin.
8203  Here the \SpecialChar LaTeX
8204  package 
8205 \family typewriter
8206 cmsd.sty by
8207 \family default
8208  
8209 \shape smallcaps
8210 Walter Schmidt
8211 \shape default
8212  helps to produce the 
8213 \begin_inset Quotes eld
8214 \end_inset
8215
8216 usual
8217 \begin_inset Quotes erd
8218 \end_inset
8219
8220  appearance when using the ec fonts.
8221 \end_layout
8222
8223 \end_inset
8224
8225  The numbering of chapter headings is made in the same way as the numbering
8226  of section headings, that is without the extra line 
8227 \begin_inset Quotes eld
8228 \end_inset
8229
8230 Chapter\SpecialChar ldots
8231
8232 \begin_inset Quotes erd
8233 \end_inset
8234
8235 .
8236  In addition, the appearance of the headings can be modified by using a
8237  number of options (in \SpecialChar LyX
8238  to be entered in the field 
8239 \family sans
8240 Extra
8241 \begin_inset space ~
8242 \end_inset
8243
8244 Options
8245 \family default
8246  of the dialog 
8247 \family sans
8248 Layout\SpecialChar menuseparator
8249 Document
8250 \family default
8251 ).
8252  
8253 \end_layout
8254
8255 \begin_layout Itemize
8256 The main means in the Koma-Script document classes to design the type area
8257  are the options 
8258 \family sans
8259 BCOR
8260 \family default
8261  and 
8262 \family sans
8263 DIV
8264 \family default
8265  (in \SpecialChar LyX
8266  to be entered in the extra class options field in the dialog 
8267 \family sans
8268 Document\SpecialChar menuseparator
8269 Settings
8270 \family default
8271 ).
8272  They make a clearer modification of page margins possible as do the options
8273  of the dialog 
8274 \family sans
8275 Document\SpecialChar menuseparator
8276 Settings
8277 \family default
8278 .
8279  
8280 \end_layout
8281
8282 \begin_layout Itemize
8283 The \SpecialChar LaTeX
8284  document classes of the Koma-Script family define a number of additional
8285  commands.
8286  Those part of it which makes sense in \SpecialChar LyX
8287  is implemented in corresponding
8288  paragraph types.
8289 \end_layout
8290
8291 \begin_layout Standard
8292 Detailed descriptions of the \SpecialChar LaTeX
8293  document classes of the Koma-Script family
8294  can be found in the Koma-Script documentation 
8295 \emph on
8296 scrguide
8297 \emph default
8298  (German) and 
8299 \emph on
8300 scrguien
8301 \emph default
8302  (English).
8303 \end_layout
8304
8305 \begin_layout Subsection
8306 article (koma-script), report (koma-script), and book (koma-script)
8307 \end_layout
8308
8309 \begin_layout Standard
8310 The document classes 
8311 \emph on
8312 article (koma-script)
8313 \emph default
8314
8315 \emph on
8316 report (koma-script)
8317 \emph default
8318 , and 
8319 \emph on
8320 book
8321 \emph default
8322  
8323 \emph on
8324 (koma-script)
8325 \emph default
8326  are implemented in the layout files 
8327 \family typewriter
8328 scrartcl.layout
8329 \family default
8330
8331 \family typewriter
8332 scrreprt.layout
8333 \family default
8334 , and 
8335 \family typewriter
8336 scrbook.layout
8337 \family default
8338 , resp.
8339  They contain all the paragraph types of the corresponding standard document
8340  classes 
8341 \emph on
8342 article
8343 \emph default
8344
8345 \emph on
8346 report
8347 \emph default
8348 , and 
8349 \emph on
8350 book
8351 \emph default
8352 , resp., partly modified, with the exception of the \SpecialChar LyX
8353  specific 
8354 \family sans
8355 List
8356 \family default
8357 -type, which is replaced by the new 
8358 \family sans
8359 Labeling
8360 \family default
8361 -type having the same functionality.
8362  Beside the 
8363 \family sans
8364 Labeling
8365 \family default
8366 -Type there is a number of new paragraph types added.
8367  They are 
8368 \emph on
8369 not
8370 \emph default
8371  part of 
8372 \emph on
8373 letter (koma-script)
8374 \emph default
8375 .
8376 \end_layout
8377
8378 \begin_layout Itemize
8379
8380 \family sans
8381 Addpart, Addchap
8382 \family default
8383
8384 \family sans
8385 Addsec
8386 \family default
8387 : are equivalents to 
8388 \family sans
8389 Part*, Chapter*
8390 \family default
8391  and 
8392 \family sans
8393 Section*
8394 \family default
8395 , resp., additionally inserting an entry in the table of contents.
8396  
8397 \family sans
8398 Addpart
8399 \family default
8400  and 
8401 \family sans
8402 Addchap
8403 \family default
8404  are not contained in 
8405 \emph on
8406 article (koma-script)
8407 \emph default
8408 .
8409 \end_layout
8410
8411 \begin_layout Itemize
8412
8413 \family sans
8414 Addchap*
8415 \family default
8416
8417 \family sans
8418 Addsec*
8419 \family default
8420 : behave exactly as 
8421 \family sans
8422 Addchap
8423 \family default
8424  and 
8425 \family sans
8426 Addsec
8427 \family default
8428 , resp., additionally clearing running heads.
8429  
8430 \family sans
8431 Addchap*
8432 \family default
8433  is not contained in 
8434 \emph on
8435 article (koma-script)
8436 \emph default
8437 .
8438 \begin_inset Foot
8439 status collapsed
8440
8441 \begin_layout Plain Layout
8442 There is also an 
8443 \family typewriter
8444
8445 \backslash
8446 addpart*
8447 \family default
8448  command in 
8449 \emph on
8450 book (koma-script)
8451 \emph default
8452  and in 
8453 \emph on
8454 report (koma-script)
8455 \emph default
8456 , but since this is identical to 
8457 \family sans
8458 Part*
8459 \family default
8460 , is has not been implemented in \SpecialChar LyX
8461 .
8462 \end_layout
8463
8464 \end_inset
8465
8466
8467 \end_layout
8468
8469 \begin_layout Itemize
8470
8471 \family sans
8472 Minisec
8473 \family default
8474 : generates a heading directly above the following paragraph in the standard
8475  character size without affecting the structure of the document.
8476 \end_layout
8477
8478 \begin_layout Itemize
8479
8480 \family sans
8481 Captionabove
8482 \family default
8483  and 
8484 \family sans
8485 Captionbelow
8486 \family default
8487  are special captions which respect the different space settings needed
8488  for captions placed above or below an element (if you follow strict typographic
8489  rules, you might want to place table captions always above the table).
8490  You can also use the class option 
8491 \family typewriter
8492 tablecaptionsabove
8493 \family default
8494 , which will switch 
8495 \family sans
8496 caption
8497 \family default
8498  to 
8499 \family sans
8500 captionabove
8501 \family default
8502  for tables and 
8503 \family sans
8504 captionbelow
8505 \family default
8506  for figures.
8507  You need at least Koma-Script version 2.8q to use this.
8508 \end_layout
8509
8510 \begin_layout Itemize
8511
8512 \family sans
8513 Dictum
8514 \family default
8515 : can be used to set a bonmot, e.
8516 \begin_inset space \thinspace{}
8517 \end_inset
8518
8519 g.
8520 \begin_inset space \space{}
8521 \end_inset
8522
8523 at the beginning of a chapter.
8524  If you use the optional argument (
8525 \family sans
8526 Insert\SpecialChar menuseparator
8527 Short
8528 \begin_inset space ~
8529 \end_inset
8530
8531 Title
8532 \family default
8533 ), you can insert the dictum's author there.
8534  Dictum and author are separated by a line.
8535  You need at least Koma-Script version 2.8q to use this.
8536  
8537 \family sans
8538 Dictum
8539 \family default
8540  is not contained in 
8541 \emph on
8542 article (koma-script)
8543 \emph default
8544 .
8545 \end_layout
8546
8547 \begin_layout Standard
8548 The following types, together with the standard types 
8549 \family sans
8550 Title
8551 \family default
8552
8553 \family sans
8554 Author
8555 \family default
8556 , and 
8557 \family sans
8558 Date
8559 \family default
8560 , form the title area of the document.
8561  They must be entered ahead of the first 
8562 \begin_inset Quotes eld
8563 \end_inset
8564
8565 ordinary
8566 \begin_inset Quotes erd
8567 \end_inset
8568
8569  paragraph.
8570 \begin_inset Foot
8571 status collapsed
8572
8573 \begin_layout Plain Layout
8574 The corresponding \SpecialChar LaTeX
8575  commands must appear before the 
8576 \family typewriter
8577
8578 \backslash
8579 maketitle
8580 \family default
8581  command.
8582 \end_layout
8583
8584 \end_inset
8585
8586  When such a type is used more than once, the latter usage overwrites the
8587  former one, that means, for every type only the latest usage is valid.
8588  The order of the different types however has, like 
8589 \family sans
8590 Title
8591 \family default
8592
8593 \family sans
8594 Author
8595 \family default
8596 , and 
8597 \family sans
8598 Date
8599 \family default
8600 , no effect on the appearance of the produced document.
8601 \end_layout
8602
8603 \begin_layout Itemize
8604
8605 \family sans
8606 Subject
8607 \family default
8608 : produces a centered paragraph above the ordinary title (
8609 \family sans
8610 Title
8611 \family default
8612
8613 \family sans
8614 Author
8615 \family default
8616
8617 \family sans
8618 Date
8619 \family default
8620 ) for the subject of the document.
8621 \end_layout
8622
8623 \begin_layout Itemize
8624
8625 \family sans
8626 Publishers
8627 \family default
8628 : produces a centered paragraph below the ordinary title (
8629 \family sans
8630 Title
8631 \family default
8632
8633 \family sans
8634 Author
8635 \family default
8636
8637 \family sans
8638 Date
8639 \family default
8640 ) for the publishers' name.
8641 \end_layout
8642
8643 \begin_layout Itemize
8644
8645 \family sans
8646 Dedication
8647 \family default
8648 : in 
8649 \emph on
8650 report (koma-script)
8651 \emph default
8652  and 
8653 \emph on
8654 book (koma-script)
8655 \emph default
8656  produces a centered paragraph on its own page behind the title page, or
8657  in 
8658 \emph on
8659 article (koma-script)
8660 \emph default
8661  produces a centered paragraph below the ordinary title (
8662 \family sans
8663 Title
8664 \family default
8665
8666 \family sans
8667 Author
8668 \family default
8669
8670 \family sans
8671 Date
8672 \family default
8673
8674 \family sans
8675 Publishers
8676 \family default
8677 ) for a dedication.
8678 \end_layout
8679
8680 \begin_layout Itemize
8681
8682 \family sans
8683 Titlehead
8684 \family default
8685 : produces a left aligned paragraph above the ordinary title (
8686 \family sans
8687 Title
8688 \family default
8689
8690 \family sans
8691 Author
8692 \family default
8693
8694 \family sans
8695 Date
8696 \family default
8697
8698 \family sans
8699 Subject
8700 \family default
8701 ) for a document`s head.
8702 \end_layout
8703
8704 \begin_layout Itemize
8705
8706 \family sans
8707 Uppertitleback
8708 \family default
8709 : produces in a double-sided print in 
8710 \emph on
8711 report (koma-script)
8712 \emph default
8713  and 
8714 \emph on
8715 book (koma-script)
8716 \emph default
8717  a left-aligned paragraph at the top of the title page`s back or has no
8718  effect in a single-sided print or in 
8719 \emph on
8720 article (koma-script)
8721 \emph default
8722 .
8723 \end_layout
8724
8725 \begin_layout Itemize
8726
8727 \family sans
8728 Lowertitleback
8729 \family default
8730 : produces in a double-sided print in 
8731 \emph on
8732 report (koma-script)
8733 \emph default
8734  and 
8735 \emph on
8736 book (koma-script)
8737 \emph default
8738  a left-aligned paragraph at the bottom of the title page`s back or has
8739  no effect in a single-sided print or in 
8740 \emph on
8741 article (koma-script)
8742 \emph default
8743 .
8744 \end_layout
8745
8746 \begin_layout Itemize
8747
8748 \family sans
8749 Extratitle
8750 \family default
8751 : produces a special 
8752 \begin_inset Quotes eld
8753 \end_inset
8754
8755 dirty
8756 \begin_inset Quotes erd
8757 \end_inset
8758
8759  page ahead of the actual document containing a paragraph without special
8760  formatting.
8761 \end_layout
8762
8763 \begin_layout Standard
8764 The layout files for the document classes 
8765 \emph on
8766 article (koma-script)
8767 \emph default
8768
8769 \emph on
8770 report (koma-script)
8771 \emph default
8772 , and 
8773 \emph on
8774 book (koma-script)
8775 \emph default
8776  do include the file 
8777 \family typewriter
8778 scrmacros.inc
8779 \family default
8780 .
8781  This is thought of as a place to define your own types.
8782  Copy scrmacros
8783 \family typewriter
8784 .inc
8785 \family default
8786  in your personal layout directory and edit the file!
8787 \end_layout
8788
8789 \begin_layout Subsection
8790 letter (koma-script)
8791 \end_layout
8792
8793 \begin_layout Standard
8794 \noindent
8795 The document class 
8796 \emph on
8797 letter (koma-script)
8798 \emph default
8799  is implemented in the layout file 
8800 \family typewriter
8801 scrlettr.layout
8802 \family default
8803 .
8804  It contains all the paragraph types of the corresponding standard document
8805  class 
8806 \emph on
8807 letter
8808 \emph default
8809 , partly modified, with the exception of the \SpecialChar LyX
8810  specific types 
8811 \family sans
8812 \SpecialChar LyX
8813 -Code
8814 \family default
8815  and 
8816 \family sans
8817 Comment
8818 \family default
8819  and the 
8820 \family sans
8821 List
8822 \family default
8823  type, which is replaced by the new 
8824 \family sans
8825 Labeling
8826 \family default
8827  type.
8828  In addition, it contains, in contrast to the standard document class, the
8829  standard types 
8830 \family sans
8831 \SpecialChar LaTeX
8832
8833 \family default
8834
8835 \family sans
8836 Quotation
8837 \family default
8838
8839 \family sans
8840 Quote
8841 \family default
8842 , and 
8843 \family sans
8844 Verse
8845 \family default
8846 .
8847  Furthermore, there are a number of new letter specific types.
8848 \end_layout
8849
8850 \begin_layout Standard
8851 The appearance of the letter produced by this document class can be controlled
8852  by a number of \SpecialChar LaTeX
8853  commands, which you can put in the \SpecialChar LaTeX
8854  preamble.
8855 \begin_inset Foot
8856 status collapsed
8857
8858 \begin_layout Plain Layout
8859 For example, the standard appearance of the letter`s heading, consisting
8860  of name and address, is quite self-willed.
8861  An 
8862 \begin_inset Quotes eld
8863 \end_inset
8864
8865 ordinary
8866 \begin_inset Quotes erd
8867 \end_inset
8868
8869  heading is produced by the following \SpecialChar LaTeX
8870  commands in the preamble:
8871 \end_layout
8872
8873 \begin_layout LyX-Code
8874
8875 \backslash
8876 firsthead{
8877 \backslash
8878 parbox[b]{
8879 \backslash
8880 textwidth}
8881 \end_layout
8882
8883 \begin_layout LyX-Code
8884   {
8885 \backslash
8886 ignorespaces 
8887 \backslash
8888 fromname
8889 \backslash
8890
8891 \backslash
8892  
8893 \backslash
8894 ignorespaces 
8895 \backslash
8896 fromaddress}} 
8897 \end_layout
8898
8899 \begin_layout LyX-Code
8900
8901 \backslash
8902 nexthead{
8903 \backslash
8904 parbox[b]{
8905 \backslash
8906 textwidth}
8907 \end_layout
8908
8909 \begin_layout LyX-Code
8910   {
8911 \backslash
8912 ignorespaces 
8913 \backslash
8914 fromname 
8915 \backslash
8916 hfill 
8917 \backslash
8918 ignorespaces 
8919 \backslash
8920 pagename
8921 \backslash
8922  
8923 \backslash
8924 thepage}}
8925 \end_layout
8926
8927 \end_inset
8928
8929  A detailed German description of such \SpecialChar LaTeX
8930  commands can be found in the Koma-Script
8931  documentation 
8932 \emph on
8933 scrguide
8934 \emph default
8935 .
8936  With it, the letter's author can produce his personal letter layout.
8937 \end_layout
8938
8939 \begin_layout Standard
8940 The types 
8941 \family sans
8942 Letter
8943 \family default
8944  and 
8945 \family sans
8946 Opening
8947 \family default
8948  define the beginning of the letter and must be used in every letter.
8949  To emphasize them in the \SpecialChar LyX
8950  document class, they are marked with the letter
8951  
8952 \shape italic
8953 L
8954 \shape default
8955  or 
8956 \shape italic
8957 O
8958 \shape default
8959 , resp.
8960 \begin_inset space ~
8961 \end_inset
8962
8963 in the left margin.
8964  It is possible to write any number of letters in one file.
8965  An 
8966 \family sans
8967 Opening
8968 \family default
8969  type produces a new letter using the same addressee and a 
8970 \family sans
8971 Letter
8972 \family default
8973  type produces a new addressee.
8974  The types 
8975 \family sans
8976 Closing
8977 \family default
8978
8979 \family sans
8980 PS
8981 \family default
8982
8983 \family sans
8984 CC
8985 \family default
8986 , and 
8987 \family sans
8988 Encl
8989 \family default
8990  are ordinary paragraph types and can also be used several times in one
8991  and the same letter.
8992 \end_layout
8993
8994 \begin_layout Itemize
8995
8996 \family sans
8997 Letter
8998 \family default
8999 : produces a paragraph for the addressee and implicitly defines the beginning
9000  of the letter.
9001 \end_layout
9002
9003 \begin_layout Itemize
9004
9005 \family sans
9006 Opening
9007 \family default
9008 : produces a paragraph for the form of address and implicitly produces a
9009  new letter.
9010 \end_layout
9011
9012 \begin_layout Itemize
9013
9014 \family sans
9015 Closing
9016 \family default
9017 : produces a paragraph for a close.
9018 \end_layout
9019
9020 \begin_layout Itemize
9021
9022 \family sans
9023 PS
9024 \family default
9025 : produces a paragraph for a postscript.
9026 \end_layout
9027
9028 \begin_layout Itemize
9029
9030 \family sans
9031 CC
9032 \family default
9033 : produces a paragraph for a distribution list.
9034 \end_layout
9035
9036 \begin_layout Itemize
9037
9038 \family sans
9039 Encl
9040 \family default
9041 : produces a paragraph for enclosures.
9042 \end_layout
9043
9044 \begin_layout Standard
9045 The types 
9046 \family sans
9047 Name
9048 \family default
9049
9050 \family sans
9051 Signature
9052 \family default
9053
9054 \family sans
9055 Address
9056 \family default
9057
9058 \family sans
9059 Telephone
9060 \family default
9061
9062 \family sans
9063 Place
9064 \family default
9065
9066 \family sans
9067 Backaddress
9068 \family default
9069
9070 \family sans
9071 Specialmail
9072 \family default
9073
9074 \family sans
9075 Location
9076 \family default
9077
9078 \family sans
9079 Title
9080 \family default
9081 , and 
9082 \family sans
9083 Subject
9084 \family default
9085  are input types provided with a label to enter information, which will
9086  be processed by the document class.
9087 \begin_inset Foot
9088 status open
9089
9090 \begin_layout Plain Layout
9091 It could be seen as a matter of inconsequence, that the types 
9092 \family sans
9093 Letter
9094 \family default
9095  and 
9096 \family sans
9097 Opening
9098 \family default
9099  described above are not such input types as well.
9100  Because of the special meaning of those types, however, I have implemented
9101  them as ordinary paragraph types with a one letter mark in the left margin.
9102  Moreover, it would affect my feeling of symmetry, if the 
9103 \family sans
9104 Opening
9105 \family default
9106  type and the 
9107 \family sans
9108 Closing
9109 \family default
9110  type had such a serious different appearance.
9111 \end_layout
9112
9113 \end_inset
9114
9115  The types must be used ahead of the corresponding 
9116 \family sans
9117 Opening
9118 \family default
9119  type.
9120 \end_layout
9121
9122 \begin_layout Standard
9123 An implementation of these types in a WYSIWYG fashion does not seem to make
9124  sense, because the real appearance of the produced letter does not only
9125  depend on the usage of the particular type, but also on other factors.
9126  For example, a signature entered in the 
9127 \family sans
9128 Signature
9129 \family default
9130  type will in the standard behavior appear in the produced letter only,
9131  when in the same letter also a 
9132 \family sans
9133 Closing
9134 \family default
9135  type is used.
9136  The entered value of the 
9137 \family sans
9138 Telephone
9139 \family default
9140  type will in the standard behavior not appear in the produced letter at
9141  all.
9142  The possibility to design the letter`s heading freely is already indicated
9143  in a footnote above.
9144 \end_layout
9145
9146 \begin_layout Standard
9147 The input types can also be used as empty paragraphs.
9148  This makes sense e.
9149 \begin_inset space \thinspace{}
9150 \end_inset
9151
9152 g.
9153 \begin_inset space \space{}
9154 \end_inset
9155
9156 for the 
9157 \family sans
9158 Signature
9159 \family default
9160  type.
9161  If the 
9162 \family sans
9163 Signature
9164 \family default
9165  type is not used at all, in the standard behavior the value of the 
9166 \family sans
9167 Name
9168 \family default
9169  type is used as signature, whereas if an empty 
9170 \family sans
9171 Signature
9172 \family default
9173  type is used, no signature value is defined.
9174 \end_layout
9175
9176 \begin_layout Standard
9177 By using the input types it is possible to write a letter template, containing
9178  filled input types with your personal dates (name, address, etc.) and empty
9179  input types for other dates you want to enter.
9180 \end_layout
9181
9182 \begin_layout Itemize
9183
9184 \family sans
9185 Name
9186 \family default
9187 : sender's name, in the standard behavior appears as a centered paragraph
9188  in small caps in the letter`s heading.
9189 \end_layout
9190
9191 \begin_layout Itemize
9192
9193 \family sans
9194 Signature
9195 \family default
9196 : sender's signature, in the standard behavior appears below the 
9197 \family sans
9198 Closing
9199 \family default
9200  type.
9201  If no 
9202 \family sans
9203 Signature
9204 \family default
9205  type is used, the value of the 
9206 \family sans
9207 Name
9208 \family default
9209  type appears instead.
9210 \end_layout
9211
9212 \begin_layout Itemize
9213
9214 \family sans
9215 Address
9216 \family default
9217 : sender's address, in the standard behavior appears in a centered paragraph
9218  in the letter`s heading below the sender's name.
9219 \end_layout
9220
9221 \begin_layout Itemize
9222
9223 \family sans
9224 Telephone
9225 \family default
9226 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
9227  variable
9228  
9229 \family typewriter
9230
9231 \backslash
9232 telephonenum
9233 \family default
9234 .
9235 \end_layout
9236
9237 \begin_layout Itemize
9238
9239 \family sans
9240 Place
9241 \family default
9242 : place of the letter`s making.
9243 \end_layout
9244
9245 \begin_layout Itemize
9246
9247 \family sans
9248 Date
9249 \family default
9250 : date of the letter`s making.
9251  
9252 \family sans
9253 Place
9254 \family default
9255  and 
9256 \family sans
9257 Date
9258 \family default
9259 , in the standard behavior, produce the place and the date in a right-aligned
9260  line below the addressee's field.
9261  If an empty 
9262 \family sans
9263 Date
9264 \family default
9265  type is used, neither place nor date appear, independent of the value of
9266  the 
9267 \family sans
9268 Place
9269 \family default
9270  type.
9271  If no 
9272 \family sans
9273 Date
9274 \family default
9275  type is used, the date of the letter `s production is used.
9276 \end_layout
9277
9278 \begin_layout Itemize
9279
9280 \family sans
9281 Backaddress
9282 \family default
9283 : sender`s back address, in the standard behavior appears above the addressee's
9284  field in a small sans serif font.
9285 \end_layout
9286
9287 \begin_layout Itemize
9288
9289 \family sans
9290 Specialmail
9291 \family default
9292 : special mail information, in the standard behavior appears underlined
9293  above the addressee's field below the back address.
9294 \end_layout
9295
9296 \begin_layout Itemize
9297
9298 \family sans
9299 Location
9300 \family default
9301 : additional information, in the standard behavior appears on right side
9302  below the addressee`s field.
9303 \end_layout
9304
9305 \begin_layout Itemize
9306
9307 \family sans
9308 Title
9309 \family default
9310 : the letter's title, in the standard behavior appears in a big, bold, sans
9311  serif font above the subject.
9312 \end_layout
9313
9314 \begin_layout Itemize
9315
9316 \family sans
9317 Subject
9318 \family default
9319 : the letter's subject, in the standard behavior appears in a bold font
9320  above the 
9321 \family sans
9322 Opening
9323 \family default
9324  paragraph.
9325 \end_layout
9326
9327 \begin_layout Standard
9328 The types 
9329 \family sans
9330 Yourref
9331 \family default
9332
9333 \family sans
9334 Yourmail
9335 \family default
9336
9337 \family sans
9338 Myref
9339 \family default
9340
9341 \family sans
9342 Customer
9343 \family default
9344 , and 
9345 \family sans
9346 Invoice
9347 \family default
9348  produce a business letter like line above the 
9349 \family sans
9350 Title
9351 \family default
9352  line containing the fields 
9353 \begin_inset Quotes eld
9354 \end_inset
9355
9356 Your ref.
9357 \begin_inset Quotes erd
9358 \end_inset
9359
9360
9361 \begin_inset Quotes eld
9362 \end_inset
9363
9364 Your letter of
9365 \begin_inset Quotes erd
9366 \end_inset
9367
9368
9369 \begin_inset Quotes eld
9370 \end_inset
9371
9372 Our ref.
9373 \begin_inset Quotes erd
9374 \end_inset
9375
9376
9377 \begin_inset Quotes eld
9378 \end_inset
9379
9380 Customer no.
9381 \begin_inset Quotes erd
9382 \end_inset
9383
9384
9385 \begin_inset Quotes eld
9386 \end_inset
9387
9388 Invoice no.
9389 \begin_inset Quotes erd
9390 \end_inset
9391
9392 , and 
9393 \begin_inset Quotes eld
9394 \end_inset
9395
9396 Date
9397 \begin_inset Quotes erd
9398 \end_inset
9399
9400 .
9401  For the date field, the value of the 
9402 \family sans
9403 Date
9404 \family default
9405  type is used.
9406  If one of these 
9407 \begin_inset Quotes eld
9408 \end_inset
9409
9410 business letter types
9411 \begin_inset Quotes erd
9412 \end_inset
9413
9414  is used, the value of the 
9415 \family sans
9416 Place
9417 \family default
9418  type however does not appear, but only the \SpecialChar LaTeX
9419  variable 
9420 \family typewriter
9421
9422 \backslash
9423 fromplace
9424 \family default
9425  is set.
9426  The ordinary output of place and date in a right-aligned line below the
9427  addressee`s field is suppressed.
9428  The types are implemented as input types provided with a label and must
9429  be used ahead of the corresponding 
9430 \family sans
9431 Opening
9432 \family default
9433  type.
9434 \end_layout
9435
9436 \begin_layout Itemize
9437
9438 \family sans
9439 Yourref
9440 \family default
9441 : Your ref.
9442 \end_layout
9443
9444 \begin_layout Itemize
9445
9446 \family sans
9447 Yourmail
9448 \family default
9449 : Your letter of.
9450 \end_layout
9451
9452 \begin_layout Itemize
9453
9454 \family sans
9455 Myref
9456 \family default
9457 : Our ref.
9458 \end_layout
9459
9460 \begin_layout Itemize
9461
9462 \family sans
9463 Customer
9464 \family default
9465 : Customer no.
9466 \end_layout
9467
9468 \begin_layout Itemize
9469
9470 \family sans
9471 Invoice
9472 \family default
9473 : Invoice no.
9474 \end_layout
9475
9476 \begin_layout Subsection
9477 The new letter class: letter (koma-script v.2)
9478 \end_layout
9479
9480 \begin_layout Standard
9481 by 
9482 \noun on
9483 Jürgen Spitzmüller
9484 \end_layout
9485
9486 \begin_layout Standard
9487 \begin_inset VSpace medskip
9488 \end_inset
9489
9490
9491 \end_layout
9492
9493 \begin_layout Standard
9494 \noindent
9495 Koma-Script version 2.8 has introduced a new letter class 
9496 \family typewriter
9497 scrlttr2
9498 \family default
9499  which supersedes the now unsupported 
9500 \family typewriter
9501 scrlettr
9502 \family default
9503 .
9504  It has — on the \SpecialChar LaTeX
9505  side — a completely new interface and is not compatible
9506  with the old class.
9507  Therefore, \SpecialChar LyX
9508  supports both, though it is recommended you use the new class.
9509 \end_layout
9510
9511 \begin_layout Standard
9512 This class covers the same functionality as 
9513 \emph on
9514 letter (koma-script),
9515 \emph default
9516  and a few more.
9517  The basic items are 
9518 \family sans
9519 Address
9520 \family default
9521  (receiver's address, same as 
9522 \family sans
9523 Letter
9524 \family default
9525  in the old layout), 
9526 \family sans
9527 Opening
9528 \family default
9529 , and 
9530 \family sans
9531 Closing
9532 \family default
9533 .
9534  
9535 \family sans
9536 NextAddress
9537 \family default
9538  will start a new letter (i.
9539 \begin_inset space \thinspace{}
9540 \end_inset
9541
9542 e.
9543 \begin_inset space \space{}
9544 \end_inset
9545
9546 you can write several letters per document).
9547  New elements are sender's 
9548 \family sans
9549 E-Mail
9550 \family default
9551
9552 \family sans
9553 URL
9554 \family default
9555
9556 \family sans
9557 Fax
9558 \family default
9559
9560 \family sans
9561 Bank
9562 \family default
9563  and the possibility to use a 
9564 \family sans
9565 Logo
9566 \family default
9567  (via 
9568 \family sans
9569 Insert\SpecialChar menuseparator
9570 Graphics
9571 \family default
9572 ) in the header.
9573 \end_layout
9574
9575 \begin_layout Standard
9576 The biggest improvement is, though, that the letter's layout is configurable
9577  to meet almost any needs.
9578  This can be done via the preamble or with a special style file (Letter
9579  Class Option, extension 
9580 \family typewriter
9581 *.lco
9582 \family default
9583 ), that will be read in as a class option.
9584 \begin_inset Foot
9585 status collapsed
9586
9587 \begin_layout Plain Layout
9588 The KOMA package comes with some default 
9589 \family typewriter
9590 *.lco
9591 \family default
9592  files.
9593  There is, for instance, a 
9594 \family typewriter
9595 DIN.lco
9596 \family default
9597  file that follows german typesetting rules, or a 
9598 \family typewriter
9599 KOMAold.lco
9600 \family default
9601  that provides the default layout of the old 
9602 \family typewriter
9603 scrlettr
9604 \family default
9605  class.
9606  The latter can be loaded with the class option 
9607 \family typewriter
9608 KOMAold
9609 \family default
9610 , inserted via the 
9611 \family sans
9612 Layout\SpecialChar menuseparator
9613 Document\SpecialChar menuseparator
9614 Extra Options
9615 \family default
9616  field.
9617 \end_layout
9618
9619 \end_inset
9620
9621  Have a look at the 
9622 \emph on
9623 koma-letter2
9624 \emph default
9625  template that is included in \SpecialChar LyX
9626  for examples.
9627  A detailed description is to be found in the Koma-Script documentation
9628  (
9629 \emph on
9630 scrguide
9631 \emph default
9632 ).
9633 \end_layout
9634
9635 \begin_layout Subsection
9636 Problems
9637 \end_layout
9638
9639 \begin_layout Standard
9640 Visualizing the Koma-Script document classes in \SpecialChar LyX
9641 , the \SpecialChar LyX
9642  internals cause some
9643  problems.
9644 \end_layout
9645
9646 \begin_layout Itemize
9647 The chapter number of a 
9648 \family sans
9649 Chapter
9650 \family default
9651  type appears on a line of its own above the chapter heading instead of
9652  appearing in the same line ahead of it.
9653  The cause for that is the \SpecialChar LyX
9654  internal behavior for the labeltype 
9655 \family sans
9656 Counter_Chapter
9657 \family default
9658  in the layout file.
9659 \end_layout
9660
9661 \begin_layout Itemize
9662 The headings of the types 
9663 \family sans
9664 Addchap
9665 \family default
9666  and 
9667 \family sans
9668 Addsec
9669 \family default
9670  are only put in the 
9671 \begin_inset Quotes eld
9672 \end_inset
9673
9674 true
9675 \begin_inset Quotes erd
9676 \end_inset
9677
9678  \SpecialChar LaTeX
9679  table of contents, but not in the \SpecialChar LyX
9680  table of contents (
9681 \family sans
9682 Document\SpecialChar menuseparator
9683 Table
9684 \begin_inset space ~
9685 \end_inset
9686
9687 of
9688 \begin_inset space ~
9689 \end_inset
9690
9691 Contents
9692 \family default
9693 ).
9694 \end_layout
9695
9696 \begin_layout Itemize
9697 The paragraphs in a 
9698 \emph on
9699 letter
9700 \emph default
9701  document class appear in a skip separation mode, not indented.
9702  This is the standard behavior, no special \SpecialChar LaTeX
9703  commands are needed for that.
9704  But in the 
9705 \family sans
9706 Document\SpecialChar menuseparator
9707 Settings
9708 \family default
9709  dialog the corresponding radio button indicates 
9710 \family sans
9711 Indent
9712 \family default
9713 .
9714  A 
9715 \family sans
9716 Skip
9717 \family default
9718  value always has the effect that extra \SpecialChar LaTeX
9719  commands are inserted in the document
9720  to produce the gap, which is not what is wanted in this case.
9721 \end_layout
9722
9723 \begin_layout Section
9724 Memoir
9725 \end_layout
9726
9727 \begin_layout Standard
9728 By 
9729 \noun on
9730 Jürgen Spitzmüller
9731 \end_layout
9732
9733 \begin_layout Subsection
9734 Overview
9735 \end_layout
9736
9737 \begin_layout Standard
9738 Memoir is a very powerful and constantly evolving class.
9739  It has been designed with regard to fictional and non-fictional literature.
9740  Its aim is to let the user have maximum control over the typesetting of
9741  his document.
9742  Memoir is based on the standard book class, but it can also emulate the
9743  article class (see below).
9744 \end_layout
9745
9746 \begin_layout Standard
9747 Peter Wilson, the developer of Memoir, is known as the author of lots of
9748  useful packages in the \SpecialChar LaTeX
9749  world.
9750  Most of them have been merged with Memoir.
9751  Therefore, it is much easier to layout the table of contents, appendices,
9752  chapter designs and such.
9753  \SpecialChar LyX
9754 , though, does not support all of these goodies natively.
9755  Some of them might be added to forthcoming releases
9756 \begin_inset Foot
9757 status collapsed
9758
9759 \begin_layout Plain Layout
9760 You are invited to send suggestions to 
9761 \begin_inset Flex URL
9762 status collapsed
9763
9764 \begin_layout Plain Layout
9765
9766 lyx-devel@lists.lyx.org
9767 \end_layout
9768
9769 \end_inset
9770
9771 .
9772 \end_layout
9773
9774 \end_inset
9775
9776 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
9777 's framework.
9778  Of course you can still use all features with the help of some native \SpecialChar LaTeX
9779
9780  commands (\SpecialChar TeX
9781  code
9782 \begin_inset Foot
9783 status collapsed
9784
9785 \begin_layout Plain Layout
9786 Cf.
9787 \begin_inset ERT
9788 status collapsed
9789
9790 \begin_layout Plain Layout
9791
9792
9793 \backslash
9794  
9795 \end_layout
9796
9797 \end_inset
9798
9799 section
9800 \begin_inset space ~
9801 \end_inset
9802
9803
9804 \begin_inset CommandInset ref
9805 LatexCommand ref
9806 reference "sec:Inserting-TeX-Code"
9807
9808 \end_inset
9809
9810  for details.
9811 \end_layout
9812
9813 \end_inset
9814
9815 ).
9816  In this section, we can only list those features that are natively supported
9817  by \SpecialChar LyX
9818 .
9819  For detailed descriptions (and for the rest of features) we recommend you
9820  have a look at the detailed manual of the Memoir class
9821 \begin_inset Foot
9822 status collapsed
9823
9824 \begin_layout Plain Layout
9825 Cf.
9826 \begin_inset ERT
9827 status collapsed
9828
9829 \begin_layout Plain Layout
9830
9831
9832 \backslash
9833  
9834 \end_layout
9835
9836 \end_inset
9837
9838
9839 \begin_inset Flex URL
9840 status collapsed
9841
9842 \begin_layout Plain Layout
9843
9844 CTAN:/macros/latex/memoir/memman.pdf
9845 \end_layout
9846
9847 \end_inset
9848
9849 .
9850 \end_layout
9851
9852 \end_inset
9853
9854 , which is not only a user guide for the class, but also both a comprehensive
9855  description on good typesetting and a superb example for good typesetting
9856  itself.
9857 \end_layout
9858
9859 \begin_layout Subsection
9860 Basic features and restrictions
9861 \end_layout
9862
9863 \begin_layout Standard
9864 Memoir supports basically all features of the standard book classes.
9865  There are, however, some differences, as follows:
9866 \end_layout
9867
9868 \begin_layout Description
9869 Font
9870 \begin_inset space ~
9871 \end_inset
9872
9873 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
9874 \end_layout
9875
9876 \begin_layout Description
9877 Page
9878 \begin_inset space ~
9879 \end_inset
9880
9881 style: The fancy page style is not supported, due to a command clash between
9882  Memoir and the fancyhdr package (they both define a command with the same
9883  name, which confuses \SpecialChar LaTeX
9884 ).
9885  Instead, Memoir comes with a number of its own page styles (see 
9886 \family sans
9887 Layout\SpecialChar menuseparator
9888 Document\SpecialChar menuseparator
9889 Page
9890 \begin_inset space ~
9891 \end_inset
9892
9893 Style
9894 \family default
9895 ).
9896  If you want to use these for the chapter pages, you have to use the command
9897  
9898 \family typewriter
9899
9900 \backslash
9901 chapterstyle
9902 \family default
9903  in the main text or in preamble (e.
9904 \begin_inset space \thinspace{}
9905 \end_inset
9906
9907 g.
9908 \begin_inset space \space{}
9909 \end_inset
9910
9911
9912 \family typewriter
9913
9914 \backslash
9915 chapterstyle{companion}
9916 \family default
9917 ).
9918 \end_layout
9919
9920 \begin_layout Description
9921 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
9922  optional argument in the standard classes.
9923  With this, you can specify an alternative version of the title for the
9924  table of contents and the headers (for instance, if the title is too long).
9925  In \SpecialChar LyX
9926 , you can do this via 
9927 \family sans
9928 Insert\SpecialChar menuseparator
9929 Short
9930 \begin_inset space ~
9931 \end_inset
9932
9933 Title
9934 \family default
9935  at the beginning of a chapter/section.
9936  Memoir features a second optional argument and thus separates the table
9937  of contents from the header.
9938  You can define three variants of a title with this: one for the main text,
9939  one for the table of contents, and one for the headers.
9940  Simply insert two optional arguments if you need this feature, the first
9941  one containing the short title for the Table of Contents, the second one
9942  containing an alternative short title for the headers.
9943 \end_layout
9944
9945 \begin_layout Description
9946 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
9947  of contents, the list of figures and the list of table start a new page
9948  automatically.
9949  Memoir does not follow this route.
9950  You have to insert a page break yourself, if you want to have one.
9951 \end_layout
9952
9953 \begin_layout Description
9954 Titlepage: For some unknown reason, Memoir uses pagination on the title
9955  page (in the standard classes, title pages are 
9956 \begin_inset Quotes eld
9957 \end_inset
9958
9959 empty
9960 \begin_inset Quotes erd
9961 \end_inset
9962
9963 ).
9964  If you want an empty title page, type 
9965 \family typewriter
9966
9967 \backslash
9968 aliaspagestyle{title}{empty}
9969 \family default
9970  in the preamble.
9971 \end_layout
9972
9973 \begin_layout Description
9974 Article: With the class option 
9975 \emph on
9976 article
9977 \emph default
9978  (to be inserted in 
9979 \family sans
9980 Layout\SpecialChar menuseparator
9981 Document\SpecialChar menuseparator
9982 Extra
9983 \begin_inset space ~
9984 \end_inset
9985
9986 Options
9987 \family default
9988 ), you can emulate article style.
9989  That is, counters (footnotes, figures, tables etc.) will not be reset on
9990  new chapters, chapters don't start a new page (but are—in contrary to 
9991 \begin_inset Quotes eld
9992 \end_inset
9993
9994 real
9995 \begin_inset Quotes erd
9996 \end_inset
9997
9998  article classes—still allowed), parts, though, use their own page, as in
9999  book.
10000 \end_layout
10001
10002 \begin_layout Description
10003 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
10004  font commands, which have been used in the old \SpecialChar LaTeX
10005  version 2.09 (e.
10006 \begin_inset space \thinspace{}
10007 \end_inset
10008
10009 g.
10010 \begin_inset space \space{}
10011 \end_inset
10012
10013
10014 \family typewriter
10015
10016 \backslash
10017 rm
10018 \family default
10019
10020 \family typewriter
10021
10022 \backslash
10023 it
10024 \family default
10025 ).
10026  It produces an error and stops \SpecialChar LaTeX
10027  whenever such a command appears.
10028  The class option 
10029 \emph on
10030 oldfontcommands
10031 \emph default
10032  reallows the commands and spits out warnings instead (which does at least
10033  not stop \SpecialChar LaTeX
10034 ).
10035  Since a lot of packages and particularly Bib\SpecialChar TeX
10036  style files are still using
10037  those commands, we have decided to use this option by default.
10038 \end_layout
10039
10040 \begin_layout Subsection
10041 Extra features
10042 \end_layout
10043
10044 \begin_layout Standard
10045 We will only describe the features supported by \SpecialChar LyX
10046  (which is not much currently).
10047  Please consult the Memoir manual
10048 \begin_inset Foot
10049 status collapsed
10050
10051 \begin_layout Plain Layout
10052 Cf.
10053 \begin_inset ERT
10054 status collapsed
10055
10056 \begin_layout Plain Layout
10057
10058
10059 \backslash
10060  
10061 \end_layout
10062
10063 \end_inset
10064
10065
10066 \begin_inset Flex URL
10067 status collapsed
10068
10069 \begin_layout Plain Layout
10070
10071 CTAN:/macros/latex/memoir/memman.pdf
10072 \end_layout
10073
10074 \end_inset
10075
10076 .
10077 \end_layout
10078
10079 \end_inset
10080
10081  for details.
10082 \end_layout
10083
10084 \begin_layout Description
10085 Abstract: You may wonder why an abstract is an extra feature.
10086  Well, it is in book class.
10087  Usually books don't have abstracts.
10088  Memoir, however, has.
10089  You can use it wherever and how often you like.
10090 \end_layout
10091
10092 \begin_layout Description
10093 Chapterprecis: You may know this older typesetting style: The contents of
10094  a chapter are summarized below the title and also in the table of contents
10095  (e.
10096 \begin_inset space \thinspace{}
10097 \end_inset
10098
10099 g.
10100 \begin_inset space \space{}
10101 \end_inset
10102
10103
10104 \emph on
10105 Our hero arrives in Troia; he loses some friends; he finds others
10106 \emph default
10107 ).
10108  Chapterprecis does exactly this.
10109  It is therefore only sensible below a chapter.
10110 \end_layout
10111
10112 \begin_layout Description
10113 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
10114  The epigraph environment provides an elegant way of typesetting such a
10115  motto.
10116  The motto itself (text) and its author (source) are divided by a short
10117  line.
10118  Unfortunately, we have to fool \SpecialChar LyX
10119  a bit here again, since the environment
10120  needs two arguments (text and source).
10121  In this case, we have to use curly brackets (in \SpecialChar TeX
10122  mode) between the two
10123  arguments: 
10124 \emph on
10125 <smart slogan>
10126 \emph default
10127  
10128 \family typewriter
10129 }{
10130 \family default
10131  
10132 \emph on
10133 <author of the slogan>.
10134 \end_layout
10135
10136 \begin_layout Description
10137 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
10138  complex figurative poems).
10139  \SpecialChar LyX
10140  can only support a few of them.
10141  One is poemtitle, which is a centered title for poems, which will also
10142  be added to the table of contents (verse is the standard environment for
10143  poems.
10144  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
10145  code,
10146  because they have to be nested inside regular verse environments, which
10147  is not possible with \SpecialChar LyX
10148 ).
10149 \end_layout
10150
10151 \begin_layout Description
10152 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
10153 \end_layout
10154
10155 \begin_layout Section
10156 Article (mwart), book (mwbk) and report (mwrep)
10157 \begin_inset Argument status
10158 status collapsed
10159
10160 \begin_layout Plain Layout
10161 The 
10162 \family typewriter
10163 mw
10164 \family default
10165  Classes
10166 \end_layout
10167
10168 \end_inset
10169
10170
10171 \end_layout
10172
10173 \begin_layout Standard
10174 by 
10175 \noun on
10176 Tomasz Luczak
10177 \end_layout
10178
10179 \begin_layout Standard
10180 The \SpecialChar LyX
10181  document classes 
10182 \emph on
10183 article (mwart)
10184 \emph default
10185
10186 \emph on
10187 report (mwrep)
10188 \emph default
10189  and 
10190 \emph on
10191 book
10192 \emph default
10193  
10194 \emph on
10195 (mwbk)
10196 \emph default
10197  correspond to the \SpecialChar LaTeX
10198  document classes 
10199 \family typewriter
10200 mwart.cls
10201 \family default
10202
10203 \family typewriter
10204 mwrep.cls
10205 \family default
10206  and 
10207 \family typewriter
10208 mwbk.cls
10209 \family default
10210 , resp.
10211  They are replacements for the standard document classes 
10212 \family typewriter
10213 article.cls
10214 \family default
10215
10216 \family typewriter
10217 report.cls
10218 \family default
10219  and 
10220 \family typewriter
10221 book.cls
10222 \family default
10223 , resp., and fit better to Polish typography conventions in a number of points.
10224  
10225 \end_layout
10226
10227 \begin_layout Standard
10228 Basic differences:
10229 \end_layout
10230
10231 \begin_layout Itemize
10232 Unnumbered titles (with star, e.
10233 \begin_inset space \thinspace{}
10234 \end_inset
10235
10236 g.
10237 \begin_inset space \space{}
10238 \end_inset
10239
10240
10241 \family sans
10242 Section*
10243 \family default
10244 ) are added into table of contents,
10245 \end_layout
10246
10247 \begin_layout Itemize
10248 Additional page styles:
10249 \end_layout
10250
10251 \begin_deeper
10252 \begin_layout Description
10253 uheadings header with separated lines,
10254 \end_layout
10255
10256 \begin_layout Description
10257 myheadings custom header, contents headers via commands: 
10258 \family typewriter
10259
10260 \backslash
10261 markright
10262 \family default
10263  and 
10264 \family typewriter
10265
10266 \backslash
10267 markboth
10268 \family default
10269 ,
10270 \end_layout
10271
10272 \begin_layout Description
10273 myuheadings custom header with separated lines,
10274 \end_layout
10275
10276 \begin_layout Description
10277 outer page number is placed on outer side of page
10278 \end_layout
10279
10280 \end_deeper
10281 \begin_layout Itemize
10282 Options 
10283 \end_layout
10284
10285 \begin_deeper
10286 \begin_layout Description
10287 rmheadings serif titles — default,
10288 \end_layout
10289
10290 \begin_layout Description
10291 sfheadings sansserif titles,
10292 \end_layout
10293
10294 \begin_layout Description
10295 authortitle on title page first placed is author next title — default,
10296 \end_layout
10297
10298 \begin_layout Description
10299 titleauthor on title page first placed is title next author,
10300 \end_layout
10301
10302 \begin_layout Description
10303 withmarginpar reserve place on page for margins.
10304 \end_layout
10305
10306 \end_deeper
10307 \begin_layout Section
10308 Paper
10309 \end_layout
10310
10311 \begin_layout Standard
10312 The document class 
10313 \family sans
10314 paper
10315 \family default
10316  provides an alternative to the standard 
10317 \family sans
10318 article
10319 \family default
10320  class.
10321  It provides similar functionality, but you might prefer this layout with
10322  sans serif sections, headings, and more.
10323 \end_layout
10324
10325 \begin_layout Section
10326 Rev\SpecialChar TeX
10327 4
10328 \end_layout
10329
10330 \begin_layout Standard
10331 by 
10332 \noun on
10333 Amir Karger
10334 \end_layout
10335
10336 \begin_layout Standard
10337 \begin_inset VSpace bigskip
10338 \end_inset
10339
10340
10341 \end_layout
10342
10343 \begin_layout Standard
10344 \noindent
10345 The 
10346 \family sans
10347 Revtex
10348 \begin_inset space ~
10349 \end_inset
10350
10351 4
10352 \family default
10353  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
10354  4.0 (the 
10355 \begin_inset Formula $\beta$
10356 \end_inset
10357
10358  release of May, 1999) class.
10359 \end_layout
10360
10361 \begin_layout Standard
10362 \SpecialChar LyX
10363  has a 
10364 \family sans
10365 Revtex
10366 \family default
10367  textclass, which works with Rev\SpecialChar TeX
10368  3.1.
10369  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
10370  2.09.
10371  That means that it doesn't interact very well with \SpecialChar LyX
10372 , which requires \SpecialChar LaTeX2e
10373 , although
10374  it has been kludged to work.
10375  Since Rev\SpecialChar TeX
10376  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
10377 , \SpecialChar LyX
10378  with the
10379  
10380 \family sans
10381 Rev\SpecialChar TeX
10382
10383 \begin_inset space ~
10384 \end_inset
10385
10386 4
10387 \family default
10388  textclass should also be pretty easy to use.
10389 \end_layout
10390
10391 \begin_layout Standard
10392 These documents are supposed to be used in 
10393 \emph on
10394 addition
10395 \emph default
10396  to the Rev\SpecialChar TeX
10397  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
10398  macros,
10399  and assume you'll know what to put in the preamble if necessary.
10400 \end_layout
10401
10402 \begin_layout Subsection
10403 Installation
10404 \end_layout
10405
10406 \begin_layout Standard
10407 All you need to do is install Rev\SpecialChar TeX
10408  4, as described in the package's README
10409  file.
10410  The package can be found at The Rev\SpecialChar TeX
10411  4 Web Site 
10412 \begin_inset Flex URL
10413 status collapsed
10414
10415 \begin_layout Plain Layout
10416
10417 http://publish.aps.org/revtex4/
10418 \end_layout
10419
10420 \end_inset
10421
10422 .
10423  Install it somewhere that \SpecialChar LaTeX
10424  can see it.
10425  Test it by trying to \SpecialChar LaTeX
10426  a short Rev\SpecialChar TeX
10427  4 document in some random directory (i.
10428 \begin_inset space \thinspace{}
10429 \end_inset
10430
10431 e.
10432 \begin_inset space \space{}
10433 \end_inset
10434
10435 not the directory where you installed the class file.) Then, if you reconfigure
10436  \SpecialChar LyX
10437 , it will find the class file and let you use the Rev\SpecialChar TeX
10438 4 textclass.
10439 \end_layout
10440
10441 \begin_layout Standard
10442 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
10443  4 document
10444  using 
10445 \family typewriter
10446 tex2lyx
10447 \family default
10448 , or to use the 
10449 \family sans
10450 Revtex
10451 \begin_inset space ~
10452 \end_inset
10453
10454 4
10455 \family default
10456  template, found in the templates directory.
10457 \end_layout
10458
10459 \begin_layout Subsection
10460 Preamble Matter
10461 \end_layout
10462
10463 \begin_layout Standard
10464 Optional arguments to 
10465 \family typewriter
10466
10467 \backslash
10468 documentclass
10469 \family default
10470 , like 
10471 \begin_inset Quotes eld
10472 \end_inset
10473
10474 preprint
10475 \begin_inset Quotes erd
10476 \end_inset
10477
10478  and 
10479 \begin_inset Quotes eld
10480 \end_inset
10481
10482 aps
10483 \begin_inset Quotes erd
10484 \end_inset
10485
10486 , go in the 
10487 \family sans
10488 Extra
10489 \begin_inset space ~
10490 \end_inset
10491
10492 Options
10493 \family default
10494  field in the 
10495 \family sans
10496 Document
10497 \begin_inset space ~
10498 \end_inset
10499
10500 Layout
10501 \family default
10502  dialog, as usual.
10503  Remember that in Rev\SpecialChar TeX
10504 , at least one optional argument is required! 
10505 \end_layout
10506
10507 \begin_layout Standard
10508 Other preamble matter, like 
10509 \family typewriter
10510
10511 \backslash
10512 draft
10513 \family default
10514  etc.
10515 \begin_inset space ~
10516 \end_inset
10517
10518 goes in the 
10519 \family sans
10520 \SpecialChar LaTeX
10521
10522 \begin_inset space ~
10523 \end_inset
10524
10525 Preamble
10526 \family default
10527  dialog, also as usual.
10528 \end_layout
10529
10530 \begin_layout Subsection
10531 Layouts
10532 \end_layout
10533
10534 \begin_layout Standard
10535 The layouts basically correspond to the commands in Rev\SpecialChar TeX
10536 4.0.
10537  For example, the Email layout corresponds to 
10538 \family typewriter
10539
10540 \backslash
10541 email{}
10542 \family default
10543 .
10544  Note that (at least as of Rev\SpecialChar TeX
10545  4.0 Beta), the 
10546 \family sans
10547 Address
10548 \family default
10549  and 
10550 \family sans
10551 Affiliation
10552 \family default
10553  layouts are exactly equivalent, so you shouldn't need to use both.
10554 \begin_inset Foot
10555 status collapsed
10556
10557 \begin_layout Plain Layout
10558 In case you're curious, both were included so that 
10559 \family typewriter
10560 tex2lyx
10561 \family default
10562  would be able to translate both 
10563 \family typewriter
10564
10565 \backslash
10566 address
10567 \family default
10568  and 
10569 \family typewriter
10570
10571 \backslash
10572 affiliation
10573 \family default
10574 .
10575 \end_layout
10576
10577 \end_inset
10578
10579
10580 \end_layout
10581
10582 \begin_layout Subsection
10583 Important Notes
10584 \end_layout
10585
10586 \begin_layout Standard
10587 There are a couple of important unique aspects of Rev\SpecialChar TeX
10588  4 which might cause
10589  bugs that will be even more confusing in \SpecialChar LyX
10590 .
10591 \end_layout
10592
10593 \begin_layout Standard
10594 In Rev\SpecialChar TeX
10595 , the 
10596 \family typewriter
10597
10598 \backslash
10599 thanks
10600 \family default
10601  command goes 
10602 \emph on
10603 outside
10604 \emph default
10605  the 
10606 \family typewriter
10607
10608 \backslash
10609 author
10610 \family default
10611  command.
10612  The \SpecialChar LyX
10613  equivalent is that there is a separate Thanks layout.
10614  Do 
10615 \emph on
10616 not
10617 \emph default
10618  write footnotes in the 
10619 \family sans
10620 Author
10621 \family default
10622  layout, or weird things may happen.
10623  See the Rev\SpecialChar TeX
10624  4 documentation for more details.
10625 \end_layout
10626
10627 \begin_layout Standard
10628 Also, the 
10629 \family sans
10630 Author
10631 \begin_inset space ~
10632 \end_inset
10633
10634 Email
10635 \family default
10636
10637 \family sans
10638 Author
10639 \begin_inset space ~
10640 \end_inset
10641
10642 URL
10643 \family default
10644 , and 
10645 \family sans
10646 Thanks
10647 \family default
10648  layouts must be placed 
10649 \emph on
10650 in between
10651 \emph default
10652  the 
10653 \family sans
10654 Author
10655 \family default
10656  layout and the corresponding 
10657 \family sans
10658 Address
10659 \family default
10660  (or equivalent 
10661 \family sans
10662 Affiliation
10663 \family default
10664 ) layout.
10665  If you put the 
10666 \family sans
10667 Thanks
10668 \family default
10669  after the 
10670 \family sans
10671 Address
10672 \family default
10673 , the \SpecialChar LaTeX
10674  won't compile.
10675 \end_layout
10676
10677 \begin_layout Subsection
10678 Drawbacks
10679 \end_layout
10680
10681 \begin_layout Standard
10682 The main problem with this layout is that you can't use the optional arguments
10683  to layouts like Email and Title.
10684  (The problem is not unique to this layout; you can't use optional arguments
10685  to the Section layouts either.) This means that after you export that file
10686  to \SpecialChar LaTeX
10687  (which you'll need to do eventually to send it in to APS), you'll need
10688  to edit the \SpecialChar LaTeX
10689  file with a text editor to add the optional arguments to set,
10690  e.
10691 \begin_inset space \thinspace{}
10692 \end_inset
10693
10694 g.
10695 \begin_inset space \space{}
10696 \end_inset
10697
10698 the running title for the page headers.
10699  Lacking these layouts makes the 
10700 \family typewriter
10701
10702 \backslash
10703 altaffiliation
10704 \family default
10705  (and the equivalent 
10706 \family typewriter
10707
10708 \backslash
10709 altaddress
10710 \family default
10711 ) useless, so the corresponding layouts don't exist, and will have to be
10712  added by hand.
10713 \begin_inset Foot
10714 status collapsed
10715
10716 \begin_layout Plain Layout
10717
10718 \emph on
10719 Note from JMarc:
10720 \emph default
10721  actually, \SpecialChar LyX
10722  1.3.0 supports some forms of optional arguments, but this layout
10723  has not been updated yet to take advantage of it.
10724 \end_layout
10725
10726 \end_inset
10727
10728  
10729 \end_layout
10730
10731 \begin_layout Section
10732 Springer Journals (
10733 \family sans
10734 svjour
10735 \family default
10736 )
10737 \end_layout
10738
10739 \begin_layout Standard
10740 by 
10741 \noun on
10742 Martin Vermeer
10743 \end_layout
10744
10745 \begin_layout Subsection
10746 Description
10747 \end_layout
10748
10749 \begin_layout Standard
10750 These are the layout files for some of the journal formats used by Springer
10751  Verlag and listed on 
10752 \begin_inset Flex URL
10753 status collapsed
10754
10755 \begin_layout Plain Layout
10756
10757 http://www.springer.de/author/tex/help-journals.html
10758 \end_layout
10759
10760 \end_inset
10761
10762 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
10763  now!).
10764  It is a modular system: the things common to all journals are implemented
10765  in 
10766 \family typewriter
10767 svjour.inc
10768 \family default
10769 , which journal-specific layout files (such as, e.
10770 \begin_inset space \thinspace{}
10771 \end_inset
10772
10773 g.
10774 \begin_inset space \space{}
10775 \end_inset
10776
10777
10778 \family typewriter
10779 svjog.layout
10780 \family default
10781  for Journal of Geodesy) can include.
10782 \end_layout
10783
10784 \begin_layout Standard
10785 This means that implementing support for any other Springer journal on this
10786  list is as simple as writing your own 
10787 \family typewriter
10788 sv
10789 \family default
10790 <myjournal>
10791 \family typewriter
10792 .layout
10793 \family default
10794  file following the outline given in 
10795 \family typewriter
10796 svjog.layout
10797 \family default
10798 .
10799  
10800 \end_layout
10801
10802 \begin_layout Standard
10803 It is reasonably well tested only for the Journal of Geodesy.
10804  
10805 \family typewriter
10806 svjour
10807 \family default
10808  and 
10809 \family typewriter
10810 svjog
10811 \family default
10812  come with the standard \SpecialChar LyX
10813  distribution.
10814  Install the relevant class file (downloaded from Springer) in a proper
10815  directory, reconfigure \SpecialChar LaTeX
10816  (in the te\SpecialChar TeX
10817  case by running 
10818 \family typewriter
10819 texhash
10820 \family default
10821 , as root if necessary — doesn't \SpecialChar LyX
10822  take care of this?), reconfigure \SpecialChar LyX
10823  and
10824  it should work.
10825 \end_layout
10826
10827 \begin_layout Subsection
10828 New styles
10829 \end_layout
10830
10831 \begin_layout Standard
10832 A large number of theorem-like styles — 
10833 \family sans
10834 Claim, Conjecture,
10835 \family default
10836  
10837 \family sans
10838 \SpecialChar ldots
10839 Theorem
10840 \family default
10841 .
10842 \end_layout
10843
10844 \begin_layout Standard
10845
10846 \family sans
10847 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
10848 _Title, Author_Running, Institute,
10849  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
10850 \family default
10851 .
10852  See the Springer class file documentation for details.
10853 \end_layout
10854
10855 \begin_layout Subsection
10856 Supported journals
10857 \end_layout
10858
10859 \begin_layout Itemize
10860
10861 \emph on
10862 Journal of Geodesy
10863 \emph default
10864
10865 \family typewriter
10866 svjog.layout
10867 \family default
10868  — Martin Vermeer
10869 \end_layout
10870
10871 \begin_layout Itemize
10872
10873 \emph on
10874 Probability Theory and Related Fields
10875 \emph default
10876
10877 \family typewriter
10878 svprobth.layout
10879 \family default
10880  — Jean-Marc Lasgouttes
10881 \end_layout
10882
10883 \begin_layout Standard
10884 Add your own, it isn't so hard!
10885 \end_layout
10886
10887 \begin_layout Subsection
10888 Credits
10889 \end_layout
10890
10891 \begin_layout Standard
10892 These files are partly based on the older 
10893 \family typewriter
10894 ejour2.layout
10895 \family default
10896 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
10897  2.09 style
10898  file from Springer.
10899  All this, and the 
10900 \family typewriter
10901 ejour2
10902 \family default
10903  layout, are now defunct.
10904  Jean-Marc Lasgouttes helped out big in making me find my way around the
10905  \SpecialChar LyX
10906  layout file mechanism.
10907 \end_layout
10908
10909 \begin_layout Subsection
10910 Bugs
10911 \end_layout
10912
10913 \begin_layout Standard
10914 Probably.
10915  But probably less than in the old hacked-\SpecialChar LaTeX
10916  
10917 \family typewriter
10918 ejour2
10919 \family default
10920 .
10921 \end_layout
10922
10923 \begin_layout Standard
10924 Limitations e.
10925 \begin_inset space \thinspace{}
10926 \end_inset
10927
10928 g.: does not display the number for theorem-like layouts, just #.
10929 \end_layout
10930
10931 \begin_layout Section
10932 Slides [aka 
10933 \noun on
10934 Sli\SpecialChar TeX
10935
10936 \noun default
10937 ]
10938 \begin_inset CommandInset label
10939 LatexCommand label
10940 name "sec:slitex"
10941
10942 \end_inset
10943
10944
10945 \end_layout
10946
10947 \begin_layout Standard
10948 by 
10949 \noun on
10950 John Weiss
10951 \noun default
10952  
10953 \end_layout
10954
10955 \begin_layout Subsection
10956 Introduction
10957 \end_layout
10958
10959 \begin_layout Standard
10960 This section describes how to use \SpecialChar LyX
10961  to make slides for overhead projectors.
10962  There are two document classes that can do this: the default slides class
10963  and the 
10964 \family sans
10965 Foil\SpecialChar TeX
10966
10967 \family default
10968  slides class.
10969  This section documents the former.
10970 \end_layout
10971
10972 \begin_layout Standard
10973 I'm going to say this again, nice and clear, so that there's no misunderstanding
10974 :
10975 \end_layout
10976
10977 \begin_layout Standard
10978 \begin_inset VSpace bigskip
10979 \end_inset
10980
10981
10982 \end_layout
10983
10984 \begin_layout Standard
10985 \align center
10986
10987 \size large
10988 This section documents the class 
10989 \begin_inset Quotes eld
10990 \end_inset
10991
10992
10993 \family sans
10994 slides (default)
10995 \family default
10996
10997 \begin_inset Quotes erd
10998 \end_inset
10999
11000  
11001 \emph on
11002 only.
11003 \end_layout
11004
11005 \begin_layout Standard
11006 \begin_inset VSpace bigskip
11007 \end_inset
11008
11009
11010 \end_layout
11011
11012 \begin_layout Standard
11013 If you're looking for the documentation for 
11014 \begin_inset Quotes eld
11015 \end_inset
11016
11017
11018 \family sans
11019 slides (Foil\SpecialChar TeX
11020 )
11021 \family default
11022
11023 \begin_inset Quotes erd
11024 \end_inset
11025
11026 , check out section
11027 \begin_inset space ~
11028 \end_inset
11029
11030
11031 \begin_inset CommandInset ref
11032 LatexCommand ref
11033 reference "sec:foiltex"
11034
11035 \end_inset
11036
11037 .
11038  The 
11039 \family sans
11040 foils
11041 \family default
11042  class [
11043 \begin_inset Quotes eld
11044 \end_inset
11045
11046
11047 \family sans
11048 slides (Foil\SpecialChar TeX
11049 )
11050 \family default
11051
11052 \begin_inset Quotes erd
11053 \end_inset
11054
11055 ] is actually somewhat better than the default 
11056 \family sans
11057 slides
11058 \family default
11059  class,
11060 \begin_inset Foot
11061 status collapsed
11062
11063 \begin_layout Plain Layout
11064 \SpecialChar ldots
11065 or so I've been told repeatedly by its advocates.
11066  Having never used it, I have no idea if this claim is true or not.
11067 \end_layout
11068
11069 \end_inset
11070
11071  which this section documents.
11072 \end_layout
11073
11074 \begin_layout Standard
11075 This class is the \SpecialChar LaTeX2e
11076  improvement of the old 
11077 \noun on
11078 Sli\SpecialChar TeX
11079
11080 \noun default
11081  package.
11082  Every \SpecialChar LaTeX2e
11083  distribution includes this class [which I'll just refer to as 
11084 \begin_inset Quotes eld
11085 \end_inset
11086
11087
11088 \family sans
11089 slides
11090 \family default
11091
11092 \begin_inset Quotes erd
11093 \end_inset
11094
11095  from now on], so you're bound to have it.
11096  As I noted earlier, there are other classes, such as 
11097 \family sans
11098 foils
11099 \family default
11100 , which also produce slides for overhead projectors and do a better job
11101  at it.
11102  However, there are some things which 
11103 \family sans
11104 slides
11105 \family default
11106  can do which the others can't, such as generate overlays.
11107  Read on to learn more!
11108 \end_layout
11109
11110 \begin_layout Subsection
11111 Getting Started
11112 \begin_inset CommandInset label
11113 LatexCommand label
11114 name "sec:slidesetup"
11115
11116 \end_inset
11117
11118
11119 \end_layout
11120
11121 \begin_layout Standard
11122 Obviously, to use this document class, you need to select 
11123 \begin_inset Quotes eld
11124 \end_inset
11125
11126
11127 \family sans
11128 slides (default)
11129 \family default
11130
11131 \begin_inset Quotes erd
11132 \end_inset
11133
11134  from the class list in the 
11135 \family sans
11136 Document\SpecialChar menuseparator
11137 Settings
11138 \family default
11139  dialog.
11140  There are some other special things you should know about this class:
11141 \end_layout
11142
11143 \begin_layout Itemize
11144 Don't bother changing the options 
11145 \family sans
11146 Sides and Columns
11147 \family default
11148 .
11149  They're not supported by the 
11150 \family sans
11151 slides
11152 \family default
11153  class, anyways.
11154 \end_layout
11155
11156 \begin_layout Itemize
11157 The option 
11158 \family sans
11159 Page
11160 \begin_inset space ~
11161 \end_inset
11162
11163 style
11164 \family default
11165  behaves a bit differently for this class.
11166  The possible choices and what they do are as follows:
11167 \end_layout
11168
11169 \begin_deeper
11170 \begin_layout Description
11171
11172 \family sans
11173 plain
11174 \family default
11175  The final output contains page numbers in the lower right corner.
11176 \end_layout
11177
11178 \begin_layout Description
11179
11180 \family sans
11181 headings
11182 \family default
11183  Like 
11184 \family sans
11185 plain
11186 \family default
11187 , but also prints out any time markers you've put in.
11188  This is the default.
11189 \end_layout
11190
11191 \begin_layout Description
11192
11193 \family sans
11194 empty
11195 \family default
11196  The final output contains no page numbers, time markers, or alignment markers.
11197 \end_layout
11198
11199 \end_deeper
11200 \begin_layout Itemize
11201 The 
11202 \family sans
11203 slides
11204 \family default
11205  class has an extra option: 
11206 \family typewriter
11207 clock
11208 \family default
11209 .
11210  To use it, put 
11211 \begin_inset Quotes eld
11212 \end_inset
11213
11214
11215 \family typewriter
11216 clock
11217 \family default
11218
11219 \begin_inset Quotes erd
11220 \end_inset
11221
11222  in the extra class options.
11223 \end_layout
11224
11225 \begin_deeper
11226 \begin_layout Standard
11227 Using this options allows you to add time markers to 
11228 \family sans
11229 Note
11230 \family default
11231 s.
11232  See section
11233 \begin_inset space ~
11234 \end_inset
11235
11236
11237 \begin_inset CommandInset ref
11238 LatexCommand ref
11239 reference "sec:slideNote"
11240
11241 \end_inset
11242
11243  for more details.
11244 \end_layout
11245
11246 \end_deeper
11247 \begin_layout Standard
11248 You can also use the template file 
11249 \begin_inset Quotes eld
11250 \end_inset
11251
11252
11253 \family typewriter
11254 slides.lyx
11255 \family default
11256
11257 \begin_inset Quotes erd
11258 \end_inset
11259
11260  to automatically set up a document to use the 
11261 \family sans
11262 slides
11263 \family default
11264  class [using 
11265 \family sans
11266 File\SpecialChar menuseparator
11267 New
11268 \begin_inset space ~
11269 \end_inset
11270
11271 from
11272 \begin_inset space ~
11273 \end_inset
11274
11275 Template
11276 \family default
11277  to open your new document].
11278  The template file also contains some examples of the special paragraph
11279  environments used by this class.
11280  I'll describe those next.
11281 \end_layout
11282
11283 \begin_layout Subsection
11284 Paragraph Environments
11285 \end_layout
11286
11287 \begin_layout Subsubsection
11288 Supported Environments
11289 \end_layout
11290
11291 \begin_layout Standard
11292 The first thing you'll notice when you start up a new 
11293 \family sans
11294 slides
11295 \family default
11296  document is the font size and type: it's the equivalent of the size 
11297 \begin_inset Quotes eld
11298 \end_inset
11299
11300
11301 \family sans
11302 Largest
11303 \family default
11304
11305 \begin_inset Quotes erd
11306 \end_inset
11307
11308  in the 
11309 \family sans
11310 Sans
11311 \begin_inset space ~
11312 \end_inset
11313
11314 Serif
11315 \family default
11316  font.
11317  This is also what's used in the output.
11318  Think of this as a 
11319 \begin_inset Quotes eld
11320 \end_inset
11321
11322 visual cue
11323 \begin_inset Quotes erd
11324 \end_inset
11325
11326  to remind you that this is a slide.
11327  Your final slides will use a larger font; ergo, you'll have less space.
11328  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
11329 \end_layout
11330
11331 \begin_layout Standard
11332 The next thing that becomes obvious is the changes to the paragraph environment
11333  pull-down box [at the far-left end of the toolbar].
11334  Most of the paragraph environments you're used to seeing are missing.
11335  There are also five new ones.
11336  That's because the 
11337 \family sans
11338 slides
11339 \family default
11340  class itself only supports certain paragraph environments:
11341 \end_layout
11342
11343 \begin_layout Itemize
11344
11345 \family sans
11346 Standard
11347 \end_layout
11348
11349 \begin_layout Itemize
11350
11351 \family sans
11352 Itemize
11353 \end_layout
11354
11355 \begin_layout Itemize
11356
11357 \family sans
11358 Enumerate
11359 \end_layout
11360
11361 \begin_layout Itemize
11362
11363 \family sans
11364 Description
11365 \end_layout
11366
11367 \begin_layout Itemize
11368
11369 \family sans
11370 List
11371 \end_layout
11372
11373 \begin_layout Itemize
11374
11375 \family sans
11376 Quotation
11377 \end_layout
11378
11379 \begin_layout Itemize
11380
11381 \family sans
11382 Quote
11383 \end_layout
11384
11385 \begin_layout Itemize
11386
11387 \family sans
11388 Verse
11389 \end_layout
11390
11391 \begin_layout Itemize
11392
11393 \family sans
11394 Caption
11395 \end_layout
11396
11397 \begin_layout Itemize
11398
11399 \family sans
11400 \SpecialChar LyX
11401 -Code
11402 \end_layout
11403
11404 \begin_layout Itemize
11405
11406 \family sans
11407 Comment
11408 \end_layout
11409
11410 \begin_layout Standard
11411 All of the other standard environments, including the section-heading environmen
11412 ts, aren't used in the 
11413 \family sans
11414 slides
11415 \family default
11416  class.
11417 \end_layout
11418
11419 \begin_layout Standard
11420 On the other hand, you'll notice the following new environments:
11421 \end_layout
11422
11423 \begin_layout Itemize
11424
11425 \family sans
11426 Slide
11427 \end_layout
11428
11429 \begin_layout Itemize
11430
11431 \family sans
11432 Overlay
11433 \end_layout
11434
11435 \begin_layout Itemize
11436
11437 \family sans
11438 Note
11439 \end_layout
11440
11441 \begin_layout Itemize
11442
11443 \family sans
11444 InvisibleText
11445 \end_layout
11446
11447 \begin_layout Itemize
11448
11449 \family sans
11450 VisibleText
11451 \end_layout
11452
11453 \begin_layout Standard
11454 These five are kind of quirky, due to a 
11455 \begin_inset Quotes eld
11456 \end_inset
11457
11458 feature
11459 \begin_inset Quotes erd
11460 \end_inset
11461
11462  in \SpecialChar LyX
11463 .
11464  You see, \SpecialChar LyX
11465  doesn't permit you to nest any other paragraph environment into
11466  an empty environment.
11467  Now, that's fine and dandy, but it means that you wouldn't be able to start
11468  a slide with anything except plain text.
11469  To deal with this, I've performed a little 
11470 \begin_inset Quotes eld
11471 \end_inset
11472
11473 \SpecialChar LaTeX
11474  magic.
11475 \begin_inset Quotes erd
11476 \end_inset
11477
11478  
11479 \end_layout
11480
11481 \begin_layout Subsubsection
11482 Quirks of the New Environments
11483 \begin_inset CommandInset label
11484 LatexCommand label
11485 name "sec:slideQuirk"
11486
11487 \end_inset
11488
11489
11490 \end_layout
11491
11492 \begin_layout Standard
11493 All five of the new paragraph environments are somewhat quirky due to inherent
11494  limitiations in the current version of \SpecialChar LyX
11495 .
11496  As I just mentioned, \SpecialChar LyX
11497  forbids environments that begin with another environment.
11498  To get around this, the 
11499 \family sans
11500 Slide
11501 \family default
11502  environment isn't a paragraph environment as described in the 
11503 \emph on
11504 User's Guide
11505 \emph default
11506 .
11507  
11508 \end_layout
11509
11510 \begin_layout Standard
11511 You should consider 
11512 \family sans
11513 Slide
11514 \family default
11515
11516 \family sans
11517 Overlay
11518 \family default
11519 , and 
11520 \family sans
11521 Note
11522 \family default
11523  to be 
11524 \begin_inset Quotes eld
11525 \end_inset
11526
11527 pseudo-environments.
11528 \begin_inset Quotes erd
11529 \end_inset
11530
11531  They look like a section heading or a 
11532 \begin_inset Quotes eld
11533 \end_inset
11534
11535
11536 \family sans
11537 Caption
11538 \family default
11539 ,
11540 \begin_inset Quotes erd
11541 \end_inset
11542
11543  but really begin a [and, if necessary, end the previous] paragraph environment.
11544  Likewise, treat 
11545 \family sans
11546 InvisibleText
11547 \family default
11548  and 
11549 \family sans
11550 VisibleText
11551 \family default
11552  as 
11553 \begin_inset Quotes eld
11554 \end_inset
11555
11556 pseudo-commands.
11557 \begin_inset Quotes erd
11558 \end_inset
11559
11560  These two perform some action.
11561 \end_layout
11562
11563 \begin_layout Standard
11564 A common feature of all five environments, 
11565 \family sans
11566 Slide
11567 \family default
11568
11569 \family sans
11570 Overlay
11571 \family default
11572
11573 \family sans
11574 Note
11575 \family default
11576
11577 \family sans
11578 InvisibleText
11579 \family default
11580  and 
11581 \family sans
11582 VisibleText
11583 \family default
11584 , is a rather long-ish label.
11585  The text following this label — ordinarily the contents of the paragraph
11586  environment — is utterly irrelevant for 
11587 \family sans
11588 Slide
11589 \family default
11590
11591 \family sans
11592 Overlay
11593 \family default
11594
11595 \family sans
11596 Note
11597 \family default
11598
11599 \family sans
11600 InvisibleText
11601 \family default
11602  and 
11603 \family sans
11604 VisibleText
11605 \family default
11606 .
11607  \SpecialChar LyX
11608  completely ignores it.
11609  In fact, you can leave these five environments completely empty.
11610  
11611 \end_layout
11612
11613 \begin_layout Standard
11614 While you don't 
11615 \emph on
11616 have
11617 \emph default
11618  to put any text after the rather long-ish label, you might want to.
11619  This could be a short description of the contents of the 
11620 \family sans
11621 Slide
11622 \family default
11623 , for example.
11624  In that case, enter your descriptive comment and hit 
11625 \family sans
11626 Return
11627 \family default
11628  as you normally would.
11629 \end_layout
11630
11631 \begin_layout Standard
11632 If, on the other hand, you don't want to enter any descriptive text, you'll
11633  hit another \SpecialChar LyX
11634  quirk.
11635  \SpecialChar LyX
11636 , like nature, abhors a vacuum, and will not let you start a new paragraph
11637  environment until you put something in the old one.
11638  So, do this:
11639 \end_layout
11640
11641 \begin_layout Itemize
11642 Start entering the text that will 
11643 \emph on
11644 follow
11645 \emph default
11646  the new 
11647 \family sans
11648 Slide
11649 \family default
11650
11651 \family sans
11652 Overlay
11653 \family default
11654
11655 \family sans
11656 Note
11657 \family default
11658
11659 \family sans
11660 InvisibleText
11661 \family default
11662  or 
11663 \family sans
11664 VisibleText
11665 \family default
11666 .
11667  
11668 \end_layout
11669
11670 \begin_layout Itemize
11671 Now move to the beginning of that paragraph.
11672  
11673 \end_layout
11674
11675 \begin_layout Itemize
11676 Next, hit 
11677 \family sans
11678 Return
11679 \family default
11680 .
11681  
11682 \end_layout
11683
11684 \begin_layout Itemize
11685 Finally, change this new, empty paragraph to a 
11686 \family sans
11687 Slide
11688 \family default
11689
11690 \family sans
11691 Overlay
11692 \family default
11693
11694 \family sans
11695 Note
11696 \family default
11697
11698 \family sans
11699 InvisibleText
11700 \family default
11701  or 
11702 \family sans
11703 VisibleText
11704 \family default
11705 .
11706  
11707 \end_layout
11708
11709 \begin_layout Standard
11710 Some future version of \SpecialChar LyX
11711  will, hopefully, resolve this quirkiness\SpecialChar ldots
11712
11713 \end_layout
11714
11715 \begin_layout Subsection
11716 Making a Presentation with 
11717 \family sans
11718 Slide
11719 \family default
11720
11721 \family sans
11722 Overlay
11723 \family default
11724  and 
11725 \family sans
11726 Note
11727 \end_layout
11728
11729 \begin_layout Subsubsection
11730 Using the 
11731 \family sans
11732 Slide
11733 \family default
11734  Environment
11735 \end_layout
11736
11737 \begin_layout Standard
11738 If you're expecting this section to teach you how to actually make a presentatio
11739 n, you'll be sorely disappointed.
11740  Naturally, I'll describe all of the ways the 
11741 \family sans
11742 slides
11743 \family default
11744  class can assist you in preparing the materials for a presentation.
11745  Filling in the contents, however, is up to you.
11746  [Then again, that 
11747 \emph on
11748 is
11749 \emph default
11750  the \SpecialChar LyX
11751  philosophy.]
11752 \end_layout
11753
11754 \begin_layout Standard
11755 Choosing the 
11756 \family sans
11757 Slide
11758 \family default
11759  environment [in the manner described in section
11760 \begin_inset space ~
11761 \end_inset
11762
11763
11764 \begin_inset CommandInset ref
11765 LatexCommand ref
11766 reference "sec:slideQuirk"
11767
11768 \end_inset
11769
11770 ] tells \SpecialChar LyX
11771  to begin a new slide [duh].
11772  The label for this environment/
11773 \begin_inset Quotes erd
11774 \end_inset
11775
11776 pseudo-command
11777 \begin_inset Quotes erd
11778 \end_inset
11779
11780  is an 
11781 \begin_inset Quotes eld
11782 \end_inset
11783
11784 ASCII line,
11785 \begin_inset Quotes erd
11786 \end_inset
11787
11788  in cool blue, followed by the label, 
11789 \begin_inset Quotes eld
11790 \end_inset
11791
11792 NewSlide:
11793 \begin_inset Quotes erd
11794 \end_inset
11795
11796 .
11797  Any text or paragraph environments that follow this one go on the new slide.
11798  It's that simple.
11799 \end_layout
11800
11801 \begin_layout Standard
11802 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
11803
11804  (this can be specified in the 
11805 \family sans
11806 Paragraph Layout
11807 \family default
11808  dialog).
11809  In fact, you'll want to, once you finish entering the contents of one slide.
11810  If you've entered more text than can physically fit on a slide, the extra
11811  overflows onto a new slide.
11812  I don't recommend doing this, however, since the overflow slide won't have
11813  any page number on it.
11814  Furthermore, it may interfere with any 
11815 \family sans
11816 Overlay
11817 \family default
11818  you've made to accompany the oversized 
11819 \family sans
11820 Slide
11821 \family default
11822 .
11823 \end_layout
11824
11825 \begin_layout Standard
11826 The 
11827 \family sans
11828 Overlay
11829 \family default
11830  and 
11831 \family sans
11832 Note
11833 \family default
11834  environments work the same way as the 
11835 \family sans
11836 Slide
11837 \family default
11838  environment.
11839  They both create an 
11840 \begin_inset Quotes eld
11841 \end_inset
11842
11843 ASCII line
11844 \begin_inset Quotes erd
11845 \end_inset
11846
11847  followed by a label [
11848 \begin_inset Quotes eld
11849 \end_inset
11850
11851 NewOverlay:
11852 \begin_inset Quotes erd
11853 \end_inset
11854
11855  and 
11856 \begin_inset Quotes eld
11857 \end_inset
11858
11859 NewNote:
11860 \begin_inset Quotes erd
11861 \end_inset
11862
11863 , respectively].
11864  The color is a stunning magenta instead of blue, and the 
11865 \begin_inset Quotes eld
11866 \end_inset
11867
11868 ASCII line
11869 \begin_inset Quotes erd
11870 \end_inset
11871
11872  will look different, in style and in length.
11873  The label fonts of all three also differ from one another.
11874 \end_layout
11875
11876 \begin_layout Standard
11877 As with a 
11878 \family sans
11879 Slide
11880 \family default
11881 , if the contents of a 
11882 \family sans
11883 Note
11884 \family default
11885  or 
11886 \family sans
11887 Overlay
11888 \family default
11889  exceed the physical size of a slide or sheet of paper, the extra will overflow
11890  onto a new sheet.
11891  Again, you should avoid this.
11892  It defeats the whole purpose of 
11893 \family sans
11894 Note
11895 \family default
11896 s and 
11897 \family sans
11898 Overlay
11899 \family default
11900 s.
11901 \end_layout
11902
11903 \begin_layout Subsubsection
11904 Using 
11905 \family sans
11906 Overlay
11907 \family default
11908  with 
11909 \family sans
11910 Slide
11911 \end_layout
11912
11913 \begin_layout Standard
11914 The idea behind an 
11915 \family sans
11916 Overlay
11917 \family default
11918  is a slide that sits atop another slide.
11919  Perhaps you wish to discuss a figure on the main 
11920 \family sans
11921 Slide
11922 \family default
11923  before displaying the text associated with it.
11924  One way to accomplish this is tape a flap of dark paper over the part of
11925  the 
11926 \family sans
11927 Slide
11928 \family default
11929  you want to display later.
11930  This method fails, however, if you wish to overlap one graph with another,
11931  for example.
11932  You would then have to fumble while speaking to align the two separate,
11933  overlapping 
11934 \family sans
11935 Slide
11936 \family default
11937 s to align the two graphs.
11938  The use of an 
11939 \family sans
11940 Overlay
11941 \family default
11942  environment in both cases makes life much easier.
11943 \end_layout
11944
11945 \begin_layout Standard
11946 Each 
11947 \family sans
11948 Overlay
11949 \family default
11950  receives the page number of its 
11951 \begin_inset Quotes eld
11952 \end_inset
11953
11954 parent
11955 \begin_inset Quotes erd
11956 \end_inset
11957
11958  
11959 \family sans
11960 Slide
11961 \family default
11962 , appended by 
11963 \begin_inset Quotes eld
11964 \end_inset
11965
11966
11967 \family typewriter
11968 -a
11969 \family default
11970
11971 \begin_inset Quotes erd
11972 \end_inset
11973
11974 .
11975 \begin_inset Foot
11976 status collapsed
11977
11978 \begin_layout Plain Layout
11979 Presumably, mutliple 
11980 \family sans
11981 Overlay
11982 \family default
11983 s would have 
11984 \begin_inset Quotes eld
11985 \end_inset
11986
11987
11988 \family typewriter
11989 -a
11990 \family default
11991
11992 \begin_inset Quotes erd
11993 \end_inset
11994
11995
11996 \begin_inset Quotes eld
11997 \end_inset
11998
11999
12000 \family typewriter
12001 -b
12002 \family default
12003
12004 \begin_inset Quotes erd
12005 \end_inset
12006
12007
12008 \begin_inset Quotes eld
12009 \end_inset
12010
12011
12012 \family typewriter
12013 -c
12014 \family default
12015
12016 \begin_inset Quotes erd
12017 \end_inset
12018
12019 , etc.
12020 \begin_inset space ~
12021 \end_inset
12022
12023 appended to the page number of the parent 
12024 \family sans
12025 Slide
12026 \family default
12027 .
12028  
12029 \end_layout
12030
12031 \end_inset
12032
12033  Clearly, you want the contents of both the 
12034 \family sans
12035 Slide
12036 \family default
12037  and the 
12038 \family sans
12039 Overlay
12040 \family default
12041  to each fit on a single physical slide! You should probably consider an
12042  
12043 \family sans
12044 Overlay
12045 \family default
12046  as 
12047 \begin_inset Quotes eld
12048 \end_inset
12049
12050 part of
12051 \begin_inset Quotes erd
12052 \end_inset
12053
12054  a 
12055 \family sans
12056 Slide
12057 \family default
12058 .
12059  Indeed, the \SpecialChar LyX
12060  
12061 \family sans
12062 slides
12063 \family default
12064  class provides a visual cue for this: the label at the start of an 
12065 \family sans
12066 Overlay
12067 \family default
12068  is shorter than that at the start of a 
12069 \family sans
12070 Slide
12071 \family default
12072 .
12073  Lastly, when you generate printable output, you'll find alignment markers
12074  in all four corners of both the 
12075 \family sans
12076 Overlay
12077 \family default
12078  page and its parent 
12079 \family sans
12080 Slide
12081 \family default
12082 .
12083  These will assist you in lining up the two physical slides.
12084 \end_layout
12085
12086 \begin_layout Standard
12087 The major problem in overlaying two slides is aligning the contents of the
12088  two transparencies.
12089  How much space should you leave for that graph on the second slide? Worse
12090  still, what if you want a graph and a sentence on second slide, but there
12091  is text on the main transparency that goes in between them? You could try
12092  and insert vertical space of the right size.
12093  The better way is to use 
12094 \family sans
12095 InvisibleText
12096 \family default
12097  and 
12098 \family sans
12099 VisibleText
12100 \family default
12101 .
12102 \end_layout
12103
12104 \begin_layout Standard
12105 As their names imply, 
12106 \family sans
12107 InvisibleText
12108 \family default
12109  and 
12110 \family sans
12111 VisibleText
12112 \family default
12113  are two command-like paragraph environments that make all subsequent text
12114  invisible and visible, respectively.
12115  Note from section
12116 \begin_inset space ~
12117 \end_inset
12118
12119
12120 \begin_inset CommandInset ref
12121 LatexCommand ref
12122 reference "sec:slideQuirk"
12123
12124 \end_inset
12125
12126  that you don't place anything 
12127 \emph on
12128 into
12129 \emph default
12130  these two environments, however.
12131  When you create an 
12132 \family sans
12133 InvisibleText
12134 \family default
12135 , it inserts a centered, sky-blue label into the page reading 
12136 \begin_inset Quotes eld
12137 \end_inset
12138
12139 <Invisible Text Follows>
12140 \begin_inset Quotes erd
12141 \end_inset
12142
12143 .
12144  For paragraphs following this label, the parts of the 
12145 \family sans
12146 Slide
12147 \family default
12148  [or 
12149 \family sans
12150 Overlay
12151 \family default
12152 ; it doesn't matter which] where they would be contain instead blank space.
12153  
12154 \end_layout
12155
12156 \begin_layout Standard
12157 For 
12158 \family sans
12159 VisibleText
12160 \family default
12161 , the corresponding centered label is 
12162 \begin_inset Quotes eld
12163 \end_inset
12164
12165 <Visible Text Follows>
12166 \begin_inset Quotes erd
12167 \end_inset
12168
12169  in blazing green.
12170  Paragraphs following this label behave normally.
12171  Note that the beginning of a new 
12172 \family sans
12173 Slide
12174 \family default
12175
12176 \family sans
12177 Overlay
12178 \family default
12179 , or 
12180 \family sans
12181 Note
12182 \family default
12183  automatically shuts off an 
12184 \family sans
12185 InvisibleText
12186 \family default
12187 .
12188  It's therefore not necessary to use 
12189 \family sans
12190 VisibleText
12191 \family default
12192  at the end of a 
12193 \family sans
12194 Slide
12195 \family default
12196 .
12197 \end_layout
12198
12199 \begin_layout Standard
12200 By now, it should be obvious how to create overlay transparencies using
12201  the proper combination of 
12202 \family sans
12203 InvisibleText
12204 \family default
12205  and 
12206 \family sans
12207 VisibleText
12208 \family default
12209  on a 
12210 \family sans
12211 Slide
12212 \family default
12213  and 
12214 \family sans
12215 Overlay
12216 \family default
12217 :
12218 \end_layout
12219
12220 \begin_layout Enumerate
12221 Create a 
12222 \family sans
12223 Slide
12224 \family default
12225 , including everything that will appear on it, whether on the main slide
12226  or on the 
12227 \family sans
12228 Overlay
12229 \family default
12230 .
12231 \end_layout
12232
12233 \begin_layout Enumerate
12234 Before each figure or paragraph that will appear only on the 
12235 \family sans
12236 Overlay
12237 \family default
12238 , insert an 
12239 \family sans
12240 InvisibleText
12241 \family default
12242  environment.
12243  If necessary, insert a 
12244 \family sans
12245 VisibleText
12246 \family default
12247  environment after the 
12248 \family sans
12249 Overlay
12250 \family default
12251 -only text.
12252 \end_layout
12253
12254 \begin_layout Enumerate
12255 Start an 
12256 \family sans
12257 Overlay
12258 \family default
12259  immediately following the 
12260 \family sans
12261 Slide
12262 \family default
12263 .
12264 \end_layout
12265
12266 \begin_layout Enumerate
12267 Copy the contents of this 
12268 \family sans
12269 Slide
12270 \family default
12271  into the 
12272 \family sans
12273 Overlay
12274 \family default
12275 .
12276 \end_layout
12277
12278 \begin_layout Enumerate
12279 Within the 
12280 \family sans
12281 Overlay
12282 \family default
12283 , change all of the 
12284 \family sans
12285 InvisibleText
12286 \family default
12287  lines to 
12288 \family sans
12289 VisibleText
12290 \family default
12291  and vice-versa.
12292 \end_layout
12293
12294 \begin_layout Standard
12295 That's it.
12296  You've just made an 
12297 \family sans
12298 Overlay
12299 \family default
12300 .
12301 \end_layout
12302
12303 \begin_layout Standard
12304 There's one problem with the way I've designed the \SpecialChar LyX
12305  
12306 \family sans
12307 slides
12308 \family default
12309  class: you can't make text in the middle of a paragraph invisible, nor
12310  make text in the middle of an invisible paragraph visible again.
12311  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
12312  codes.
12313 \begin_inset Foot
12314 status collapsed
12315
12316 \begin_layout Plain Layout
12317 The commands of interest are: 
12318 \end_layout
12319
12320 \begin_layout Itemize
12321
12322 \family typewriter
12323 {
12324 \backslash
12325 invisible \SpecialChar ldots
12326  }
12327 \end_layout
12328
12329 \begin_layout Itemize
12330
12331 \family typewriter
12332 {
12333 \backslash
12334 visible \SpecialChar ldots
12335  }
12336 \end_layout
12337
12338 \begin_layout Plain Layout
12339 \SpecialChar ldots
12340 and need to be marked as \SpecialChar TeX
12341 .
12342  The text whose 
12343 \begin_inset Quotes eld
12344 \end_inset
12345
12346 visibility
12347 \begin_inset Quotes erd
12348 \end_inset
12349
12350  you wish to change goes in between the brackets [and after the 
12351 \family typewriter
12352
12353 \backslash
12354 invisible
12355 \family default
12356  or 
12357 \family typewriter
12358
12359 \backslash
12360 visible
12361 \family default
12362  command].
12363  If you don't know how to mark text as \SpecialChar TeX
12364 , see the appropriate section of
12365  the 
12366 \emph on
12367 User's Guide
12368 \emph default
12369 .
12370 \end_layout
12371
12372 \end_inset
12373
12374
12375 \end_layout
12376
12377 \begin_layout Subsubsection
12378 Using 
12379 \family sans
12380 Note
12381 \family default
12382  with 
12383 \family sans
12384 Slide
12385 \family default
12386
12387 \begin_inset CommandInset label
12388 LatexCommand label
12389 name "sec:slideNote"
12390
12391 \end_inset
12392
12393
12394 \end_layout
12395
12396 \begin_layout Standard
12397 Like an 
12398 \family sans
12399 Overlay
12400 \family default
12401 , a 
12402 \family sans
12403 Note
12404 \family default
12405  is associated with a 
12406 \begin_inset Quotes eld
12407 \end_inset
12408
12409 parent
12410 \begin_inset Quotes erd
12411 \end_inset
12412
12413  
12414 \family sans
12415 Slide
12416 \family default
12417 .
12418  Here, too, the \SpecialChar LyX
12419  
12420 \family sans
12421 slides
12422 \family default
12423  class provides visual cues.
12424  The label for a 
12425 \family sans
12426 Note
12427 \family default
12428  is shorter than that of a 
12429 \family sans
12430 Slide
12431 \family default
12432  [yet longer than that of an 
12433 \family sans
12434 Overlay
12435 \family default
12436 ] and, like the label of an 
12437 \family sans
12438 Overlay
12439 \family default
12440  is shockingly magenta.
12441  Additionally, the printed 
12442 \family sans
12443 Note
12444 \family default
12445  has the page number of its 
12446 \begin_inset Quotes eld
12447 \end_inset
12448
12449 parent
12450 \begin_inset Quotes erd
12451 \end_inset
12452
12453  
12454 \family sans
12455 Slide
12456 \family default
12457 , appended by 
12458 \begin_inset Quotes eld
12459 \end_inset
12460
12461
12462 \family typewriter
12463 -
12464 \family default
12465 1
12466 \begin_inset Quotes erd
12467 \end_inset
12468
12469
12470 \begin_inset Quotes eld
12471 \end_inset
12472
12473
12474 \family typewriter
12475 -
12476 \family default
12477 2
12478 \begin_inset Quotes erd
12479 \end_inset
12480
12481
12482 \begin_inset Quotes eld
12483 \end_inset
12484
12485
12486 \family typewriter
12487 -
12488 \family default
12489 3
12490 \begin_inset Quotes erd
12491 \end_inset
12492
12493 , etc.
12494  You can have multiple 
12495 \family sans
12496 Note
12497 \family default
12498 s associated with a single 
12499 \family sans
12500 Slide
12501 \family default
12502 , and, as with 
12503 \family sans
12504 Slide
12505 \family default
12506  and 
12507 \family sans
12508 Overlay
12509 \family default
12510 , you'll probably want to break up long 
12511 \family sans
12512 Note
12513 \family default
12514 s so that they fit on a single sheet of paper.
12515 \end_layout
12516
12517 \begin_layout Standard
12518 The purpose of a 
12519 \family sans
12520 Note
12521 \family default
12522  is obvious: it contains anything additional you might want to say about
12523  a 
12524 \family sans
12525 Slide
12526 \family default
12527 .
12528  It could also be used as a sheet of reminders for a particular 
12529 \family sans
12530 Slide
12531 \family default
12532 .
12533  In the case of the latter, you might want to make use of time markers.
12534  Currently, the \SpecialChar LyX
12535  
12536 \family sans
12537 slides
12538 \family default
12539  class has no 
12540 \begin_inset Quotes eld
12541 \end_inset
12542
12543 native
12544 \begin_inset Quotes erd
12545 \end_inset
12546
12547  support for time markers, a 
12548 \noun on
12549 Sli\SpecialChar TeX
12550
12551 \noun default
12552  feature.
12553  So, you'll have to resort to using the \SpecialChar LaTeX
12554  codes.
12555 \end_layout
12556
12557 \begin_layout Standard
12558 To use time markers, you'll need to specify the extra class option 
12559 \begin_inset Quotes eld
12560 \end_inset
12561
12562
12563 \family typewriter
12564 clock
12565 \family default
12566
12567 \begin_inset Quotes erd
12568 \end_inset
12569
12570  [see section
12571 \begin_inset space ~
12572 \end_inset
12573
12574
12575 \begin_inset CommandInset ref
12576 LatexCommand ref
12577 reference "sec:slidesetup"
12578
12579 \end_inset
12580
12581 ].
12582  This option turns on timing marks, which will appear in the lower-left-hand
12583  corner of every 
12584 \family sans
12585 Note
12586 \family default
12587  you generate.
12588  To set what appears in the time marker, you use the \SpecialChar LaTeX
12589  commands 
12590 \begin_inset Quotes eld
12591 \end_inset
12592
12593
12594 \family typewriter
12595
12596 \backslash
12597 settime{}
12598 \family default
12599
12600 \begin_inset Quotes erd
12601 \end_inset
12602
12603  and 
12604 \begin_inset Quotes eld
12605 \end_inset
12606
12607
12608 \family typewriter
12609
12610 \backslash
12611 addtime{}
12612 \family default
12613
12614 \begin_inset Quotes erd
12615 \end_inset
12616
12617 .
12618  The arguments of both commands are time measured in seconds.
12619  
12620 \begin_inset Quotes eld
12621 \end_inset
12622
12623
12624 \family typewriter
12625
12626 \backslash
12627 settime{}
12628 \family default
12629
12630 \begin_inset Quotes erd
12631 \end_inset
12632
12633  sets the time marker to a given time.
12634  
12635 \begin_inset Quotes eld
12636 \end_inset
12637
12638
12639 \family typewriter
12640
12641 \backslash
12642 addtime{}
12643 \family default
12644
12645 \begin_inset Quotes erd
12646 \end_inset
12647
12648  increments the time marker by the specified amount.
12649  Using time markers and 
12650 \family sans
12651 Note
12652 \family default
12653 s in this fashion, you can remind yourself how much time to spend on a particula
12654
12655 \family sans
12656 Slide
12657 \family default
12658 .
12659 \end_layout
12660
12661 \begin_layout Standard
12662 There's one last feature to describe.
12663  Clearly, you'd like to print out all of your 
12664 \family sans
12665 Slide
12666 \family default
12667 s and 
12668 \family sans
12669 Overlay
12670 \family default
12671 s on transparencies while printing all of your 
12672 \family sans
12673 Note
12674 \family default
12675 s on plain paper.
12676  However, a 
12677 \family sans
12678 Note
12679 \family default
12680  
12681 \emph on
12682 must
12683 \emph default
12684  follow the 
12685 \family sans
12686 Slide
12687 \family default
12688  with which it is associated.
12689  What's a person to do?
12690 \end_layout
12691
12692 \begin_layout Standard
12693 Luckily, there are two \SpecialChar LaTeX
12694  commands that allow you to select what to print
12695  out.
12696  Both must be placed into the preamble of your document.
12697  The command 
12698 \begin_inset Quotes eld
12699 \end_inset
12700
12701
12702 \family typewriter
12703
12704 \backslash
12705 onlyslides{
12706 \backslash
12707 slides}
12708 \family default
12709
12710 \begin_inset Quotes erd
12711 \end_inset
12712
12713  will cause the output to contain only the 
12714 \family sans
12715 Slide
12716 \family default
12717 s and 
12718 \family sans
12719 Overlay
12720 \family default
12721 s.
12722  Correspondingly, the command 
12723 \begin_inset Quotes eld
12724 \end_inset
12725
12726
12727 \family typewriter
12728
12729 \backslash
12730 onlynotes{
12731 \backslash
12732 notes}
12733 \family default
12734
12735 \begin_inset Quotes erd
12736 \end_inset
12737
12738  prevents the output of anything but 
12739 \family sans
12740 Note
12741 \family default
12742 s.
12743  I'd advise placing both commands in the preamble and initially comment
12744  both out.
12745  You can then preview your entire presentation as you write.
12746  When you're done writing, you can then uncomment one of the two to select
12747  what you want to print.
12748  I like to uncomment 
12749 \begin_inset Quotes eld
12750 \end_inset
12751
12752
12753 \family typewriter
12754
12755 \backslash
12756 onlyslides{
12757 \backslash
12758 slides}
12759 \family default
12760
12761 \begin_inset Quotes erd
12762 \end_inset
12763
12764  , print to a file with 
12765 \begin_inset Quotes eld
12766 \end_inset
12767
12768
12769 \family typewriter
12770 -slides
12771 \family default
12772
12773 \begin_inset Quotes erd
12774 \end_inset
12775
12776  in its name, comment it back out, then uncomment 
12777 \begin_inset Quotes eld
12778 \end_inset
12779
12780
12781 \family typewriter
12782
12783 \backslash
12784 onlynotes{
12785 \backslash
12786 notes}
12787 \family default
12788
12789 \begin_inset Quotes erd
12790 \end_inset
12791
12792  and print to a 
12793 \begin_inset Quotes eld
12794 \end_inset
12795
12796
12797 \family typewriter
12798 *-notes.ps
12799 \family default
12800
12801 \begin_inset Quotes erd
12802 \end_inset
12803
12804  file.
12805  I can then send either file to a printer, loading transparencies or plain
12806  paper as appropriate.
12807 \end_layout
12808
12809 \begin_layout Standard
12810 You can also provide other arguments to the 
12811 \begin_inset Quotes eld
12812 \end_inset
12813
12814
12815 \family typewriter
12816
12817 \backslash
12818 onlyslides{}
12819 \family default
12820
12821 \begin_inset Quotes erd
12822 \end_inset
12823
12824  and 
12825 \begin_inset Quotes eld
12826 \end_inset
12827
12828
12829 \family typewriter
12830
12831 \backslash
12832 onlynotes{}
12833 \family default
12834
12835 \begin_inset Quotes erd
12836 \end_inset
12837
12838  commands.
12839  See a good \SpecialChar LaTeX
12840  book for details.
12841 \end_layout
12842
12843 \begin_layout Subsection
12844 The 
12845 \family sans
12846 slides
12847 \family default
12848  Class Template File
12849 \end_layout
12850
12851 \begin_layout Standard
12852 I have also provided a template file, 
12853 \begin_inset Quotes eld
12854 \end_inset
12855
12856
12857 \family typewriter
12858 slides.lyx
12859 \family default
12860
12861 \begin_inset Quotes erd
12862 \end_inset
12863
12864 , with the 
12865 \family sans
12866 slides
12867 \family default
12868  class.
12869  To use it, begin your new presentation with 
12870 \family sans
12871 File\SpecialChar menuseparator
12872 New
12873 \begin_inset space ~
12874 \end_inset
12875
12876 from
12877 \begin_inset space ~
12878 \end_inset
12879
12880 Template
12881 \family default
12882 .
12883  Your new \SpecialChar LyX
12884  presentation file will contain an example 
12885 \family sans
12886 Slide
12887 \family default
12888  – 
12889 \family sans
12890 Overlay
12891 \family default
12892  – 
12893 \family sans
12894 Note
12895 \family default
12896  triplet.
12897  The 
12898 \family sans
12899 Slide
12900 \family default
12901  and 
12902 \family sans
12903 Overlay
12904 \family default
12905  additionally contain an example of the use of 
12906 \family sans
12907 InvisibleText
12908 \family default
12909  and 
12910 \family sans
12911 VisibleText
12912 \family default
12913 .
12914  Lastly, the preamble will contain:
12915 \end_layout
12916
12917 \begin_layout LyX-Code
12918 % Uncomment to print out only slides and overlays
12919 \end_layout
12920
12921 \begin_layout LyX-Code
12922 %
12923 \end_layout
12924
12925 \begin_layout LyX-Code
12926 %
12927 \backslash
12928 onlyslides{
12929 \backslash
12930 slides}
12931 \begin_inset Newline newline
12932 \end_inset
12933
12934  
12935 \end_layout
12936
12937 \begin_layout LyX-Code
12938 % Uncomment to print out only notes
12939 \end_layout
12940
12941 \begin_layout LyX-Code
12942 %
12943 \end_layout
12944
12945 \begin_layout LyX-Code
12946 %
12947 \backslash
12948 onlynotes{
12949 \backslash
12950 notes}
12951 \end_layout
12952
12953 \begin_layout Standard
12954 One final thing: I created this class to support the \SpecialChar LaTeX2e
12955  
12956 \begin_inset Quotes eld
12957 \end_inset
12958
12959
12960 \noun on
12961 Sli\SpecialChar TeX
12962
12963 \noun default
12964  emulation
12965 \begin_inset Quotes erd
12966 \end_inset
12967
12968  class, one of the built-in \SpecialChar LaTeX2e
12969  classes.
12970  Neither I nor the rest of the \SpecialChar LyX
12971  Team endorse or oppose the use of this built-in
12972  slide class.
12973  It's here if you want it or need it.
12974  There exist other \SpecialChar LaTeX2e
12975  classes for creating presentations, such as the 
12976 \family sans
12977 Foils
12978 \family default
12979  class [see section
12980 \begin_inset space ~
12981 \end_inset
12982
12983
12984 \begin_inset CommandInset ref
12985 LatexCommand ref
12986 reference "sec:foiltex"
12987
12988 \end_inset
12989
12990 ] or the 
12991 \begin_inset Quotes eld
12992 \end_inset
12993
12994
12995 \family typewriter
12996 seminar
12997 \family default
12998
12999 \begin_inset Quotes erd
13000 \end_inset
13001
13002  package [present on some \SpecialChar TeX
13003  distributions].
13004  The latter is not yet supported under \SpecialChar LyX
13005 .
13006 \begin_inset Foot
13007 status collapsed
13008
13009 \begin_layout Plain Layout
13010 Perhaps you can take on the task\SpecialChar ldots
13011
13012 \end_layout
13013
13014 \end_inset
13015
13016  I know nothing about these other classes.
13017  Try them out to see what sort of alternative they provide.
13018 \end_layout
13019
13020 \begin_layout Chapter
13021
13022 \change_inserted 893223064 1464851900
13023 Modules
13024 \end_layout
13025
13026 \begin_layout Standard
13027
13028 \change_inserted 893223064 1464851910
13029 This is a holder for prepared text.
13030 \end_layout
13031
13032 \begin_layout Chapter
13033
13034 \change_inserted 893223064 1464851939
13035 Page layout
13036 \end_layout
13037
13038 \begin_layout Standard
13039
13040 \change_inserted 893223064 1464851945
13041 This is a holder for prepared text.
13042 \end_layout
13043
13044 \begin_layout Section
13045 Special features
13046 \end_layout
13047
13048 \begin_layout Standard
13049 You can do everything with \SpecialChar LyX
13050  that you can do with \SpecialChar LaTeX
13051 .
13052  However, \SpecialChar LyX
13053  cannot support every \SpecialChar LaTeX
13054  feature directly.
13055  But you can always use \SpecialChar TeX
13056  Code.
13057  This chapter shows you some more special things you might want to use.
13058  For other special things you can do with figures, tables, floats, boxes
13059  and notes, have a look at the 
13060 \emph on
13061 Embedded
13062 \begin_inset space ~
13063 \end_inset
13064
13065 Objects
13066 \emph default
13067  manual.
13068 \end_layout
13069
13070 \begin_layout Section
13071 Fancy Headers and Footers
13072 \end_layout
13073
13074 \begin_layout Standard
13075 The default page layout is rather plain; for an 
13076 \begin_inset Flex Code
13077 status collapsed
13078
13079 \begin_layout Plain Layout
13080 article
13081 \end_layout
13082
13083 \end_inset
13084
13085  document class, all you get is a centered page number at the bottom of
13086  the page.
13087  This document uses KOMA-script's book class, so it appears to be a bit
13088  fancier.
13089  But to really put on a show, you need to set the document page style to
13090  
13091 \begin_inset Quotes eld
13092 \end_inset
13093
13094 fancy
13095 \begin_inset Quotes erd
13096 \end_inset
13097
13098 , as mentioned in the 
13099 \emph on
13100 User Guide
13101 \emph default
13102 .
13103  This section describes the \SpecialChar LaTeX
13104  code you need to insert in your \SpecialChar LaTeX
13105  preamble in
13106  order to get the desired effects.
13107 \end_layout
13108
13109 \begin_layout Standard
13110 For more information on fancy headers, see the 
13111 \begin_inset Flex Code
13112 status collapsed
13113
13114 \begin_layout Plain Layout
13115 fancyhdr
13116 \end_layout
13117
13118 \end_inset
13119
13120  package documentation.
13121  (
13122 \begin_inset Flex URL
13123 status collapsed
13124
13125 \begin_layout Plain Layout
13126
13127 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
13128 \end_layout
13129
13130 \end_inset
13131
13132 )
13133 \end_layout
13134
13135 \begin_layout Standard
13136 The page header is divided into three fields, not surprisingly labeled 
13137 \begin_inset Quotes eld
13138 \end_inset
13139
13140 left
13141 \begin_inset Quotes erd
13142 \end_inset
13143
13144
13145 \begin_inset Quotes eld
13146 \end_inset
13147
13148 center
13149 \begin_inset Quotes erd
13150 \end_inset
13151
13152 , and 
13153 \begin_inset Quotes eld
13154 \end_inset
13155
13156 right
13157 \begin_inset Quotes erd
13158 \end_inset
13159
13160 .
13161  The footer is also divided into these three fields.
13162  The \SpecialChar LaTeX
13163  commands to set these fields in the simplest manner are 
13164 \begin_inset Flex Code
13165 status collapsed
13166
13167 \begin_layout Plain Layout
13168
13169 \backslash
13170 lhead
13171 \end_layout
13172
13173 \end_inset
13174
13175
13176 \begin_inset Flex Code
13177 status collapsed
13178
13179 \begin_layout Plain Layout
13180
13181 \backslash
13182 chead
13183 \end_layout
13184
13185 \end_inset
13186
13187
13188 \begin_inset Flex Code
13189 status collapsed
13190
13191 \begin_layout Plain Layout
13192
13193 \backslash
13194 rhead
13195 \end_layout
13196
13197 \end_inset
13198
13199
13200 \begin_inset Flex Code
13201 status collapsed
13202
13203 \begin_layout Plain Layout
13204
13205 \backslash
13206 lfoot
13207 \end_layout
13208
13209 \end_inset
13210
13211 , etc.
13212  Suppose you wish to put your name in the upper left hand corner of each
13213  page.
13214  Simply insert the following command in the preamble: 
13215 \end_layout
13216
13217 \begin_layout Standard
13218
13219 \family typewriter
13220
13221 \backslash
13222 lhead{John Q.
13223  DocWriter}
13224 \end_layout
13225
13226 \begin_layout Standard
13227 You will now see your name in the upper left.
13228  If a field has a default entry that you would like to get rid of (often
13229  the page number appears in the central footer) simply include a command
13230  with a blank argument, e.
13231 \begin_inset space \thinspace{}
13232 \end_inset
13233
13234 g.:
13235 \end_layout
13236
13237 \begin_layout Standard
13238
13239 \family typewriter
13240
13241 \backslash
13242 cfoot{}
13243 \end_layout
13244
13245 \begin_layout Standard
13246 Let's get really fancy: lets put the section number with the word 
13247 \begin_inset Quotes eld
13248 \end_inset
13249
13250 Section
13251 \begin_inset Quotes erd
13252 \end_inset
13253
13254  (e.
13255 \begin_inset space \thinspace{}
13256 \end_inset
13257
13258 g.
13259 \begin_inset space \space{}
13260 \end_inset
13261
13262 Section 3) in the upper left, the page number (e.
13263 \begin_inset space \thinspace{}
13264 \end_inset
13265
13266 g.
13267 \begin_inset space \space{}
13268 \end_inset
13269
13270 Page 4) in the upper right, your name in the lower left, and the date in
13271  the lower right.
13272  The following commands should now appear in the preamble:
13273 \end_layout
13274
13275 \begin_layout Standard
13276
13277 \family typewriter
13278
13279 \backslash
13280 lhead{Section 
13281 \backslash
13282 thesection}
13283 \end_layout
13284
13285 \begin_layout Standard
13286
13287 \family typewriter
13288
13289 \backslash
13290 chead{}
13291 \end_layout
13292
13293 \begin_layout Standard
13294
13295 \family typewriter
13296
13297 \backslash
13298 rhead{Page 
13299 \backslash
13300 thepage}
13301 \end_layout
13302
13303 \begin_layout Standard
13304
13305 \family typewriter
13306
13307 \backslash
13308 lfoot{John Q.
13309  DocWriter}
13310 \end_layout
13311
13312 \begin_layout Standard
13313
13314 \family typewriter
13315
13316 \backslash
13317 cfoot{}
13318 \end_layout
13319
13320 \begin_layout Standard
13321
13322 \family typewriter
13323
13324 \backslash
13325 rfoot{
13326 \backslash
13327 today}
13328 \end_layout
13329
13330 \begin_layout Standard
13331 The commands 
13332 \begin_inset Flex Code
13333 status collapsed
13334
13335 \begin_layout Plain Layout
13336
13337 \backslash
13338 thesection
13339 \end_layout
13340
13341 \end_inset
13342
13343  and 
13344 \begin_inset Flex Code
13345 status collapsed
13346
13347 \begin_layout Plain Layout
13348
13349 \backslash
13350 thepage
13351 \end_layout
13352
13353 \end_inset
13354
13355  access \SpecialChar LaTeX
13356 's section and page counters, and so print out the current section
13357  and page numbers.
13358  
13359 \begin_inset Flex Code
13360 status collapsed
13361
13362 \begin_layout Plain Layout
13363
13364 \backslash
13365 today
13366 \end_layout
13367
13368 \end_inset
13369
13370  simply prints out today's date.
13371 \end_layout
13372
13373 \begin_layout Standard
13374 The thicknesses of the horizontal rules drawn beneath the header and above
13375  the footer can also be modified.
13376  If you don't want one of the rules, set its thickness to 0.
13377  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
13378  Use commands
13379 \family typewriter
13380  
13381 \family default
13382 like 
13383 \begin_inset Flex Code
13384 status collapsed
13385
13386 \begin_layout Plain Layout
13387
13388 \backslash
13389 renewcommand{
13390 \backslash
13391 headrulewidth}{0.4pt}
13392 \end_layout
13393
13394 \end_inset
13395
13396  and 
13397 \begin_inset Flex Code
13398 status collapsed
13399
13400 \begin_layout Plain Layout
13401
13402 \backslash
13403 renewcommand{
13404 \backslash
13405 footrulewidth}{0.4pt}
13406 \end_layout
13407
13408 \end_inset
13409
13410  to set the thicknesses.
13411 \end_layout
13412
13413 \begin_layout Standard
13414 You can switch the header/footer settings on and off for individual pages
13415  using commands like 
13416 \begin_inset Flex Code
13417 status collapsed
13418
13419 \begin_layout Plain Layout
13420
13421 \backslash
13422 thispagestyle{empty}
13423 \end_layout
13424
13425 \end_inset
13426
13427
13428 \begin_inset Flex Code
13429 status collapsed
13430
13431 \begin_layout Plain Layout
13432
13433 \backslash
13434 thispagestyle{plain}
13435 \end_layout
13436
13437 \end_inset
13438
13439 , and 
13440 \begin_inset Flex Code
13441 status collapsed
13442
13443 \begin_layout Plain Layout
13444
13445 \backslash
13446 thispagestyle{fancy}
13447 \end_layout
13448
13449 \end_inset
13450
13451 .
13452  Simply insert them in the text on the page you want changed and mark them
13453  as \SpecialChar TeX
13454  code.
13455  In fact, title pages are marked as plain by default, while following pages
13456  are marked fancy when using the global fancy setting.
13457 \end_layout
13458
13459 \begin_layout Standard
13460 As a final example, it is possible to include an image in the header or
13461  footer.
13462  Suppose you want to put a company logo in the upper lefthand corner.
13463  You might try something like
13464 \end_layout
13465
13466 \begin_layout Standard
13467
13468 \family typewriter
13469
13470 \backslash
13471 lhead{
13472 \backslash
13473 resizebox{1in}{!}{
13474 \backslash
13475 includegraphics{logo.eps}}}
13476 \end_layout
13477
13478 \begin_layout Standard
13479 \noindent
13480 (you may need to preface this with 
13481 \begin_inset Flex Code
13482 status collapsed
13483
13484 \begin_layout Plain Layout
13485 \noindent
13486
13487 \backslash
13488 usepackage{graphics}
13489 \end_layout
13490
13491 \end_inset
13492
13493  if you don't include graphics elsewhere in your document).
13494 \end_layout
13495
13496 \begin_layout Section
13497 Multiple Text Columns
13498 \end_layout
13499
13500 \begin_layout Standard
13501 This feature is independent of the option 
13502 \family sans
13503 Two-column document
13504 \family default
13505  in the document settings under 
13506 \family sans
13507 Text Layout
13508 \family default
13509 .
13510  If you want to have 2
13511 \begin_inset space ~
13512 \end_inset
13513
13514 columns for the whole document, it is recommended to use the 
13515 \family sans
13516 Two-column document
13517 \family default
13518  option.
13519  For all other cases use this feature.
13520 \end_layout
13521
13522 \begin_layout Standard
13523 To use multiple text columns in your document, you have to load the module
13524  
13525 \family sans
13526 Multiple Columns
13527 \family default
13528  (menu 
13529 \family sans
13530 Document\SpecialChar menuseparator
13531 Settings\SpecialChar menuseparator
13532 Modules
13533 \family default
13534 ) and must have the \SpecialChar LaTeX
13535 -package 
13536 \series bold
13537 multicol
13538 \series default
13539  installed.
13540 \end_layout
13541
13542 \begin_layout Standard
13543 Footnotes within multiple columns will be placed at the bottom of the page
13544  and not under each column.
13545  Within the different columns you can use everything, with the limitation
13546  that for floats you need to use the float option 
13547 \family sans
13548 Span columns
13549 \family default
13550 .
13551 \end_layout
13552
13553 \begin_layout Subsection
13554 Basics
13555 \end_layout
13556
13557 \begin_layout Standard
13558 If you want to have 2
13559 \begin_inset space ~
13560 \end_inset
13561
13562 columns in your text, insert a multicolumn inset via the menu 
13563 \family sans
13564 Insert\SpecialChar menuseparator
13565 Custom
13566 \begin_inset space ~
13567 \end_inset
13568
13569 Insets\SpecialChar menuseparator
13570 Multiple
13571 \begin_inset space ~
13572 \end_inset
13573
13574 Columns
13575 \family default
13576  where the columns should start.
13577  Write all text that should be printed in 2
13578 \begin_inset space ~
13579 \end_inset
13580
13581 columns into this inset.
13582 \end_layout
13583
13584 \begin_layout Standard
13585 Here is an example:
13586 \end_layout
13587
13588 \begin_layout Standard
13589 \noindent
13590 \begin_inset Flex Multiple Columns
13591 status open
13592
13593 \begin_layout Plain Layout
13594 \noindent
13595
13596 \series bold
13597 \size small
13598 The Adventure of the Empty House
13599 \series default
13600
13601 \begin_inset Newline newline
13602 \end_inset
13603
13604 by Sir Arthur Conan Doyle
13605 \end_layout
13606
13607 \begin_layout Plain Layout
13608
13609 \size small
13610 It was in the spring of the year 1894 that all London was interested, and
13611  the fashionable world dismayed, by the murder of the Honourable Ronald
13612  Adair under most unusual and inexplicable circumstances.
13613  The public has already learned those particulars of the crime which came
13614  out in the police investigation, but a good deal was suppressed upon that
13615  occasion, since the case for the prosecution was so overwhelmingly strong
13616  that it was not necessary to bring forward all the facts.
13617  Only now, at the end of nearly ten years, am I allowed to supply those
13618  missing links which make up the whole of that remarkable chain.
13619  The crime was of interest in itself, but that interest was as nothing to
13620  me compared to the inconceivable sequel, which afforded me the greatest
13621  shock and surprise of any event in my adventurous life.
13622  Even now, after this long interval, I find myself thrilling as I think
13623  of it, and feeling once more that sudden flood of joy, amazement, and increduli
13624 ty which utterly submerged my mind.
13625  Let me say to that public, which has shown some interest in those glimpses
13626  which I have occasionally given them of the thoughts and actions of a very
13627  remarkable man, that they are not to blame me if I have not shared my knowledge
13628  with them, for I should have considered it my first duty to do so, had
13629  I not been barred by a positive prohibition from his own lips, which was
13630  only withdrawn upon the third of last month.
13631 \end_layout
13632
13633 \end_inset
13634
13635
13636 \end_layout
13637
13638 \begin_layout Standard
13639 To get 3 or more columns, set the cursor into the multicolumn inset and
13640  use the menu 
13641 \family sans
13642 Insert\SpecialChar menuseparator
13643 Number
13644 \begin_inset space ~
13645 \end_inset
13646
13647 of
13648 \begin_inset space ~
13649 \end_inset
13650
13651 Columns
13652 \family default
13653 .
13654  The number of the desired columns is written into that inset (for 3
13655 \begin_inset space ~
13656 \end_inset
13657
13658 columns write 
13659 \begin_inset Quotes eld
13660 \end_inset
13661
13662 3
13663 \begin_inset Quotes erd
13664 \end_inset
13665
13666 ).
13667 \begin_inset Newline newline
13668 \end_inset
13669
13670 Here is an example with 3
13671 \begin_inset space ~
13672 \end_inset
13673
13674 columns:
13675 \end_layout
13676
13677 \begin_layout Standard
13678 \begin_inset Flex Multiple Columns
13679 status open
13680
13681 \begin_layout Plain Layout
13682
13683 \size footnotesize
13684 \begin_inset Argument 1
13685 status open
13686
13687 \begin_layout Plain Layout
13688 3
13689 \end_layout
13690
13691 \end_inset
13692
13693 It can be imagined that my close intimacy with Sherlock Holmes had interested
13694  me deeply in crime, and that after his disappearance I never failed to
13695  read with care the various problems which came before the public.
13696  And I even attempted, more than once, for my own private satisfaction,
13697  to employ his methods in their solution, though with indifferent success.
13698  There was none, however, which appealed to me like this tragedy of Ronald
13699  Adair.
13700  As I read the evidence at the inquest, which led up to a verdict of willful
13701  murder against some person or persons unknown, I realized more clearly
13702  than I had ever done the loss which the community had sustained by the
13703  death of Sherlock Holmes.
13704  There were points about this strange business which would, I was sure,
13705  have specially appealed to him, and the efforts of the police would have
13706  been supplemented, or more probably anticipated, by the trained observation
13707  and the alert mind of the first criminal agent in Europe.
13708  All day, as I drove upon my round, I turned over the case in my mind and
13709  found no explanation which appeared to me to be adequate.
13710  At the risk of telling a twice-told tale, I will recapitulate the facts
13711  as they were known to the public at the conclusion of the inquest.
13712 \end_layout
13713
13714 \end_inset
13715
13716
13717 \end_layout
13718
13719 \begin_layout Standard
13720 You can have up to 10
13721 \begin_inset space ~
13722 \end_inset
13723
13724 columns if you want to, but that might not be very pleasant for the readers
13725  of your document.
13726 \end_layout
13727
13728 \begin_layout Standard
13729 \begin_inset Newpage newpage
13730 \end_inset
13731
13732
13733 \end_layout
13734
13735 \begin_layout Subsection
13736 Columns inside Columns
13737 \end_layout
13738
13739 \begin_layout Standard
13740 You can also have columns inside columns:
13741 \end_layout
13742
13743 \begin_layout Standard
13744 \begin_inset Flex Multiple Columns
13745 status open
13746
13747 \begin_layout Plain Layout
13748
13749 \size footnotesize
13750 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
13751  at that time governor of one of the Australian colonies.
13752  Adair's mother had returned from Australia to undergo the operation for
13753  cataract, and she, her son Ronald, and her daughter Hilda were living together
13754  at 427 Park Lane.
13755 \end_layout
13756
13757 \begin_layout Plain Layout
13758 \begin_inset Flex Multiple Columns
13759 status open
13760
13761 \begin_layout Plain Layout
13762
13763 \size footnotesize
13764 The youth moved in the best society–had, so far as was known, no enemies
13765  and no particular vices.
13766  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
13767  had been broken off by mutual consent some months before, and there was
13768  no sign that it had left any very profound feeling behind it.
13769  For the rest {sic} the man's life moved in a narrow and conventional circle,
13770  for his habits were quiet and his nature unemotional.
13771  Yet it was upon this easy-going young aristocrat that death came, in most
13772  strange and unexpected form, between the hours of ten and eleven-twenty
13773  on the night of March 30, 1894.
13774 \end_layout
13775
13776 \end_inset
13777
13778
13779 \end_layout
13780
13781 \begin_layout Plain Layout
13782
13783 \size footnotesize
13784 Ronald Adair was fond of cards–playing continually, but never for such stakes
13785  as would hurt him.
13786  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
13787  It was shown that, after dinner on the day of his death, he had played
13788  a rubber of whist at the latter club.
13789  He had also played there in the afternoon.
13790
13791 \size default
13792  
13793 \size footnotesize
13794 The evidence of those who had played with him– Mr.
13795  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
13796  and that there was a fairly equal fall of the cards.
13797  Adair might have lost five pounds, but not more.
13798  His fortune was a considerable one, and such a loss could not in any way
13799  affect him.
13800  He had played nearly every day at one club or other, but he was a cautious
13801  player, and usually rose a winner.
13802  It came out in evidence that, in partnership with Colonel Moran, he had
13803  actually won as much as four hundred and twenty pounds in a sitting, some
13804  weeks before, from Godfrey Milner and Lord Balmoral.
13805  So much for his recent history as it came out at the inquest.
13806 \end_layout
13807
13808 \end_inset
13809
13810
13811 \end_layout
13812
13813 \begin_layout Subsection
13814 Advanced Examples
13815 \end_layout
13816
13817 \begin_layout Standard
13818 The examples in this section show some more special features of multiple
13819  columns.
13820 \end_layout
13821
13822 \begin_layout Standard
13823 For more features of multiple columns, have a look at the documentation
13824  of the \SpecialChar LaTeX
13825 -package 
13826 \series bold
13827 multicol
13828 \series default
13829
13830 \begin_inset CommandInset citation
13831 LatexCommand cite
13832 key "multicol"
13833
13834 \end_inset
13835
13836 .
13837 \end_layout
13838
13839 \begin_layout Subsubsection
13840 Preface
13841 \end_layout
13842
13843 \begin_layout Standard
13844 To add a preface text for multiple columns, set the cursor into the multicolumn
13845  inset and use the menu 
13846 \family sans
13847 Insert\SpecialChar menuseparator
13848 Preface
13849 \family default
13850 .
13851  Write your preface text into that inset.
13852 \begin_inset Newline newline
13853 \end_inset
13854
13855 This is an example with some preface text:
13856 \end_layout
13857
13858 \begin_layout Standard
13859 \begin_inset VSpace bigskip
13860 \end_inset
13861
13862
13863 \end_layout
13864
13865 \begin_layout Standard
13866 \begin_inset Flex Multiple Columns
13867 status open
13868
13869 \begin_layout Plain Layout
13870 \begin_inset Argument 2
13871 status open
13872
13873 \begin_layout Plain Layout
13874 And the story continues and continues and continues and continues\SpecialChar ldots
13875
13876 \end_layout
13877
13878 \end_inset
13879
13880
13881 \size small
13882 On the evening of the crime, he returned from the club exactly at ten.
13883  His mother and sister were out spending the evening with a relation.
13884  The servant deposed that she heard him enter the front room on the second
13885  floor, generally used as his sitting-room.
13886  She had lit a fire there, and as it smoked she had opened the window.
13887  No sound was heard from the room until eleven-twenty, the hour of the return
13888  of Lady Maynooth and her daughter.
13889  Desiring to say good-night, she attempted to enter her son's room.
13890  The door was locked on the inside, and no answer could be got to their
13891  cries and knocking.
13892  Help was obtained, and the door forced.
13893  The unfortunate young man was found lying near the table.
13894  His head had been horribly mutilated by an expanding revolver bullet, but
13895  no weapon of any sort was to be found in the room.
13896 \end_layout
13897
13898 \end_inset
13899
13900
13901 \end_layout
13902
13903 \begin_layout Standard
13904 You can also use a section heading as the preface if you use a section command
13905  as \SpecialChar TeX
13906  Code.
13907  For example the command
13908 \end_layout
13909
13910 \begin_layout Standard
13911
13912 \series bold
13913
13914 \backslash
13915 subsection{subsection title}
13916 \end_layout
13917
13918 \begin_layout Standard
13919 creates a subsection.
13920  In this example the preface is a subsubsection:
13921 \end_layout
13922
13923 \begin_layout Standard
13924 \begin_inset Flex Multiple Columns
13925 status open
13926
13927 \begin_layout Plain Layout
13928 \begin_inset Argument 2
13929 status open
13930
13931 \begin_layout Plain Layout
13932 \begin_inset ERT
13933 status collapsed
13934
13935 \begin_layout Plain Layout
13936
13937
13938 \backslash
13939 subsubsection{
13940 \end_layout
13941
13942 \end_inset
13943
13944 This is a subsubsection heading as a preface
13945 \begin_inset ERT
13946 status collapsed
13947
13948 \begin_layout Plain Layout
13949
13950 }
13951 \end_layout
13952
13953 \end_inset
13954
13955
13956 \end_layout
13957
13958 \end_inset
13959
13960
13961 \size small
13962 A minute examination of the circumstances served only to make the case more
13963  complex.
13964  In the first place, no reason could be given why the young man should have
13965  fastened the door upon the inside.
13966  There was the possibility that the murderer had done this, and had afterwards
13967  escaped by the window.
13968  The drop was at least twenty feet, however, and a bed of crocuses in full
13969  bloom lay beneath.
13970  Neither the flowers nor the earth showed any sign of having been disturbed,
13971  nor were there any marks upon the narrow strip of grass which separated
13972  the house from the road.
13973  Apparently, therefore, it was the young man himself who had fastened the
13974  door.
13975  But how did he come by his death? No one could have climbed up to the window
13976  without leaving traces.
13977  Suppose a man had fired through the window, he would indeed be a remarkable
13978  shot who could with a revolver inflict so deadly a wound.
13979  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
13980  a hundred yards of the house.
13981  No one had heard a shot.
13982 \end_layout
13983
13984 \end_inset
13985
13986
13987 \end_layout
13988
13989 \begin_layout Standard
13990 If there is less vertical space than 6
13991 \begin_inset space ~
13992 \end_inset
13993
13994 text lines is left on the page at the beginning of the multiple columns,
13995  a page break will be inserted before the multiple columns.
13996  Depending on the number of lines of the preface text, you might want to
13997  change this space.
13998  This is done by setting the cursor into the mulitcolumn inset behind the
13999  preface (if there is any) and using the menu 
14000 \family sans
14001 Insert\SpecialChar menuseparator
14002 Space
14003 \begin_inset space ~
14004 \end_inset
14005
14006 Before
14007 \begin_inset space ~
14008 \end_inset
14009
14010 Page
14011 \begin_inset space ~
14012 \end_inset
14013
14014 Break
14015 \family default
14016 .
14017  Insert into that inset the amount of space like e.
14018 \begin_inset space \thinspace{}
14019 \end_inset
14020
14021 g.
14022 \begin_inset space \space{}
14023 \end_inset
14024
14025
14026 \begin_inset Quotes eld
14027 \end_inset
14028
14029 5cm
14030 \begin_inset Quotes erd
14031 \end_inset
14032
14033 .
14034 \begin_inset Newline newline
14035 \end_inset
14036
14037 In this example the space is set to 7
14038 \begin_inset space ~
14039 \end_inset
14040
14041 text lines by using 
14042 \begin_inset Quotes eld
14043 \end_inset
14044
14045 7
14046 \backslash
14047 baselineskip
14048 \begin_inset Quotes erd
14049 \end_inset
14050
14051  (where the command 
14052 \series bold
14053
14054 \backslash
14055 baselineskip
14056 \series default
14057  needs to be inserted as \SpecialChar TeX
14058  code):
14059 \end_layout
14060
14061 \begin_layout Standard
14062 \begin_inset Flex Multiple Columns
14063 status open
14064
14065 \begin_layout Plain Layout
14066 \begin_inset Argument 3
14067 status open
14068
14069 \begin_layout Plain Layout
14070 7
14071 \begin_inset ERT
14072 status collapsed
14073
14074 \begin_layout Plain Layout
14075
14076
14077 \backslash
14078 baselineskip
14079 \end_layout
14080
14081 \end_inset
14082
14083
14084 \end_layout
14085
14086 \end_inset
14087
14088
14089 \size small
14090 On the evening of the crime, he returned from the club exactly at ten.
14091  His mother and sister were out spending the evening with a relation.
14092  The servant deposed that she heard him enter the front room on the second
14093  floor, generally used as his sitting-room.
14094  She had lit a fire there, and as it smoked she had opened the window.
14095  No sound was heard from the room until eleven-twenty, the hour of the return
14096  of Lady Maynooth and her daughter.
14097  Desiring to say good-night, she attempted to enter her son's room.
14098  The door was locked on the inside, and no answer could be got to their
14099  cries and knocking.
14100  Help was obtained, and the door forced.
14101  The unfortunate young man was found lying near the table.
14102  His head had been horribly mutilated by an expanding revolver bullet, but
14103  no weapon of any sort was to be found in the room.
14104 \end_layout
14105
14106 \end_inset
14107
14108
14109 \end_layout
14110
14111 \begin_layout Subsubsection
14112 Surrounding Space
14113 \end_layout
14114
14115 \begin_layout Standard
14116 The amount of space before and after multiple columns can be changed by
14117  changing the length 
14118 \series bold
14119
14120 \backslash
14121 multicolsep
14122 \series default
14123 .
14124  For example the command
14125 \end_layout
14126
14127 \begin_layout Standard
14128
14129 \series bold
14130
14131 \backslash
14132 setlength{
14133 \backslash
14134 multicolsep}{3cm}
14135 \end_layout
14136
14137 \begin_layout Standard
14138 in \SpecialChar TeX
14139  Code changes its value to 3
14140 \begin_inset space \thinspace{}
14141 \end_inset
14142
14143 cm.
14144  The change must be made before the multiple columns' start.
14145  The predefined value is 13
14146 \begin_inset space \thinspace{}
14147 \end_inset
14148
14149 pt.
14150 \end_layout
14151
14152 \begin_layout Standard
14153 For this example 
14154 \series bold
14155
14156 \backslash
14157 multicolsep
14158 \series default
14159  was set to 2.5
14160 \begin_inset space \thinspace{}
14161 \end_inset
14162
14163 cm:
14164 \end_layout
14165
14166 \begin_layout Standard
14167 \begin_inset ERT
14168 status open
14169
14170 \begin_layout Plain Layout
14171
14172
14173 \backslash
14174 setlength{
14175 \backslash
14176 multicolsep}{2.5cm}
14177 \end_layout
14178
14179 \end_inset
14180
14181
14182 \end_layout
14183
14184 \begin_layout Standard
14185 \begin_inset Flex Multiple Columns
14186 status open
14187
14188 \begin_layout Plain Layout
14189
14190 \size small
14191 All day I turned these facts over in my mind, endeavouring to hit upon some
14192  theory which could reconcile them all, and to find that line of least resistanc
14193 e which my poor friend had declared to be the starting-point of every investigat
14194 ion.
14195  I confess that I made little progress.
14196  In the evening I strolled across the Park, and found myself about six o'clock
14197  at the Oxford Street end of Park Lane.
14198  A group of loafers upon the pavements, all staring up at a particular window,
14199  directed me to the house which I had come to see.
14200  A tall, thin man with coloured glasses, whom I strongly suspected of being
14201  a plain-clothes detective, was pointing out some theory of his own, while
14202  the others crowded round to listen to what he said.
14203  I got as near him as I could, but his observations seemed to me to be absurd,
14204  so I withdrew again in some disgust.
14205  As I did so I struck against an elderly, deformed man, who had been behind
14206  me, and I knocked down several books which he was carrying.
14207 \end_layout
14208
14209 \end_inset
14210
14211
14212 \end_layout
14213
14214 \begin_layout Standard
14215 \begin_inset Note Greyedout
14216 status open
14217
14218 \begin_layout Plain Layout
14219
14220 \series bold
14221 Note:
14222 \series default
14223  The values you set with 
14224 \series bold
14225
14226 \backslash
14227 setlength
14228 \series default
14229  will be used for all following multiple columns until you change them again.
14230 \end_layout
14231
14232 \end_inset
14233
14234
14235 \end_layout
14236
14237 \begin_layout Standard
14238 \begin_inset ERT
14239 status collapsed
14240
14241 \begin_layout Plain Layout
14242
14243
14244 \backslash
14245 setlength{
14246 \backslash
14247 multicolsep}{13pt}
14248 \end_layout
14249
14250 \end_inset
14251
14252
14253 \begin_inset Note Note
14254 status collapsed
14255
14256 \begin_layout Plain Layout
14257 go back to the default
14258 \end_layout
14259
14260 \end_inset
14261
14262
14263 \end_layout
14264
14265 \begin_layout Standard
14266 \begin_inset Newpage newpage
14267 \end_inset
14268
14269
14270 \end_layout
14271
14272 \begin_layout Subsubsection
14273 Column Breaks
14274 \end_layout
14275
14276 \begin_layout Standard
14277 A column break can be forced by inserting the command 
14278 \series bold
14279
14280 \backslash
14281 columnbreak{}
14282 \series default
14283  as \SpecialChar TeX
14284  Code to that position in the text where the column should be broken.
14285  Note that this leads in most cases to whitespace in the text.
14286 \begin_inset Newline newline
14287 \end_inset
14288
14289 Here is an example:
14290 \end_layout
14291
14292 \begin_layout Standard
14293 \begin_inset Flex Multiple Columns
14294 status open
14295
14296 \begin_layout Plain Layout
14297
14298 \size small
14299 \begin_inset Quotes eld
14300 \end_inset
14301
14302 You're surprised to see me, sir,
14303 \begin_inset Quotes erd
14304 \end_inset
14305
14306  said he, in a strange, croaking voice.
14307 \end_layout
14308
14309 \begin_layout Plain Layout
14310
14311 \size small
14312 I acknowledged that I was.
14313 \end_layout
14314
14315 \begin_layout Plain Layout
14316
14317 \size small
14318 \begin_inset Quotes eld
14319 \end_inset
14320
14321 Well, I've a conscience, sir, and when I chanced to see you go into this
14322  house, as I came hobbling after you, I thought to myself, I'll just step
14323  in and see that kind gentleman, and tell him that if I was a bit gruff
14324  in my manner there was not any harm meant, and that I am much obliged to
14325  him for picking up my books.
14326 \begin_inset Quotes erd
14327 \end_inset
14328
14329
14330 \end_layout
14331
14332 \begin_layout Plain Layout
14333
14334 \size small
14335 \begin_inset Quotes eld
14336 \end_inset
14337
14338 You make too much of a trifle,
14339 \begin_inset Quotes erd
14340 \end_inset
14341
14342  said I.
14343  
14344 \begin_inset Quotes eld
14345 \end_inset
14346
14347 May I ask how you knew who I was?
14348 \begin_inset Quotes erd
14349 \end_inset
14350
14351  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
14352 \begin_inset ERT
14353 status collapsed
14354
14355 \begin_layout Plain Layout
14356
14357
14358 \backslash
14359 columnbreak{}
14360 \end_layout
14361
14362 \end_inset
14363
14364
14365 \end_layout
14366
14367 \begin_layout Plain Layout
14368
14369 \size small
14370 \begin_inset Quotes eld
14371 \end_inset
14372
14373 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14374  you'll find my little bookshop at the corner of Church Street, and very
14375  happy to see you, I am sure.
14376  Maybe you collect yourself, sir.
14377  Here's 
14378 \noun on
14379 British
14380 \begin_inset space ~
14381 \end_inset
14382
14383 Birds
14384 \noun default
14385 , and 
14386 \noun on
14387 Catullus
14388 \noun default
14389 , and 
14390 \noun on
14391 The Holy War
14392 \noun default
14393 –a bargain, every one of them.
14394  With five volumes you could just fill that gap on that second shelf.
14395  It looks untidy, does it not, sir?
14396 \begin_inset Quotes erd
14397 \end_inset
14398
14399
14400 \end_layout
14401
14402 \end_inset
14403
14404
14405 \end_layout
14406
14407 \begin_layout Subsubsection
14408 Column Separation
14409 \end_layout
14410
14411 \begin_layout Standard
14412 The width of the columns is automatically calculated, but you can modify
14413  the space between the columns.
14414  This is done by changing the length 
14415 \series bold
14416
14417 \backslash
14418 columnsep
14419 \series default
14420 .
14421  Its predefined value is 10
14422 \begin_inset space \thinspace{}
14423 \end_inset
14424
14425 pt.
14426  Here is an example where 
14427 \series bold
14428
14429 \backslash
14430 columnsep
14431 \series default
14432  is set to 3
14433 \begin_inset space \thinspace{}
14434 \end_inset
14435
14436 cm:
14437 \end_layout
14438
14439 \begin_layout Standard
14440 \begin_inset ERT
14441 status open
14442
14443 \begin_layout Plain Layout
14444
14445
14446 \backslash
14447 setlength{
14448 \backslash
14449 columnsep}{3cm}
14450 \end_layout
14451
14452 \end_inset
14453
14454
14455 \end_layout
14456
14457 \begin_layout Standard
14458 \begin_inset Flex Multiple Columns
14459 status open
14460
14461 \begin_layout Plain Layout
14462
14463 \size small
14464 My observations of No.
14465 \begin_inset space \space{}
14466 \end_inset
14467
14468 427 Park Lane did little to clear up the problem in which I was interested.
14469  The house was separated from the street by a low wall and railing, the
14470  whole not more than five feet high.
14471  It was perfectly easy, therefore, for anyone to get into the garden, but
14472  the window was entirely inaccessible, since there was no water pipe or
14473  anything which could help the most active man to climb it.
14474  More puzzled than ever, I retraced my steps to Kensington.
14475  I had not been in my study five minutes when the maid entered to say that
14476  a person desired to see me.
14477  To my astonishment it was none other than my strange old book collector,
14478  his sharp, wizened face peering out from a frame of white hair, and his
14479  precious volumes, a dozen of them at least, wedged under his right arm.
14480 \end_layout
14481
14482 \end_inset
14483
14484
14485 \end_layout
14486
14487 \begin_layout Standard
14488 \begin_inset ERT
14489 status collapsed
14490
14491 \begin_layout Plain Layout
14492
14493
14494 \backslash
14495 setlength{
14496 \backslash
14497 columnsep}{10pt}
14498 \end_layout
14499
14500 \end_inset
14501
14502
14503 \begin_inset Note Note
14504 status collapsed
14505
14506 \begin_layout Plain Layout
14507 go back to the default
14508 \end_layout
14509
14510 \end_inset
14511
14512
14513 \end_layout
14514
14515 \begin_layout Subsubsection
14516 Vertical Lines
14517 \end_layout
14518
14519 \begin_layout Standard
14520 Between the columns a rule with a width of the length 
14521 \series bold
14522
14523 \backslash
14524 columnseprule
14525 \series default
14526  is placed.
14527  If this rule width is set to 0
14528 \begin_inset space \thinspace{}
14529 \end_inset
14530
14531 pt (this is the default), the rule is suppressed.
14532  In the following example the rule is 2
14533 \begin_inset space \thinspace{}
14534 \end_inset
14535
14536 pt wide:
14537 \end_layout
14538
14539 \begin_layout Standard
14540 \begin_inset ERT
14541 status open
14542
14543 \begin_layout Plain Layout
14544
14545
14546 \backslash
14547 setlength{
14548 \backslash
14549 columnseprule}{2pt}
14550 \end_layout
14551
14552 \end_inset
14553
14554
14555 \end_layout
14556
14557 \begin_layout Standard
14558 \begin_inset Flex Multiple Columns
14559 status open
14560
14561 \begin_layout Plain Layout
14562
14563 \size small
14564 \begin_inset Quotes eld
14565 \end_inset
14566
14567 You're surprised to see me, sir,
14568 \begin_inset Quotes erd
14569 \end_inset
14570
14571  said he, in a strange, croaking voice.
14572 \end_layout
14573
14574 \begin_layout Plain Layout
14575
14576 \size small
14577 I acknowledged that I was.
14578 \end_layout
14579
14580 \begin_layout Plain Layout
14581
14582 \size small
14583 \begin_inset Quotes eld
14584 \end_inset
14585
14586 Well, I've a conscience, sir, and when I chanced to see you go into this
14587  house, as I came hobbling after you, I thought to myself, I'll just step
14588  in and see that kind gentleman, and tell him that if I was a bit gruff
14589  in my manner there was not any harm meant, and that I am much obliged to
14590  him for picking up my books.
14591 \begin_inset Quotes erd
14592 \end_inset
14593
14594
14595 \end_layout
14596
14597 \begin_layout Plain Layout
14598
14599 \size small
14600 \begin_inset Quotes eld
14601 \end_inset
14602
14603 You make too much of a trifle,
14604 \begin_inset Quotes erd
14605 \end_inset
14606
14607  said I.
14608  
14609 \begin_inset Quotes eld
14610 \end_inset
14611
14612 May I ask how you knew who I was?
14613 \begin_inset Quotes erd
14614 \end_inset
14615
14616
14617 \end_layout
14618
14619 \begin_layout Plain Layout
14620
14621 \size small
14622 \begin_inset Quotes eld
14623 \end_inset
14624
14625 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14626  you'll find my little bookshop at the corner of Church Street, and very
14627  happy to see you, I am sure.
14628  Maybe you collect yourself, sir.
14629  Here's 
14630 \noun on
14631 British
14632 \begin_inset space ~
14633 \end_inset
14634
14635 Birds
14636 \noun default
14637 , and 
14638 \noun on
14639 Catullus
14640 \noun default
14641 , and 
14642 \noun on
14643 The Holy War
14644 \noun default
14645 –a bargain, every one of them.
14646  With five volumes you could just fill that gap on that second shelf.
14647  It looks untidy, does it not, sir?
14648 \begin_inset Quotes erd
14649 \end_inset
14650
14651
14652 \end_layout
14653
14654 \end_inset
14655
14656
14657 \end_layout
14658
14659 \begin_layout Standard
14660 \begin_inset VSpace defskip
14661 \end_inset
14662
14663
14664 \end_layout
14665
14666 \begin_layout Standard
14667 The rule can be colored by redefining the command 
14668 \series bold
14669
14670 \backslash
14671 columnseprulecolor
14672 \series default
14673 .
14674  This is done by inserting the command
14675 \begin_inset Newline newline
14676 \end_inset
14677
14678
14679 \series bold
14680
14681 \backslash
14682 renewcommand{
14683 \backslash
14684 columnseprulecolor}{
14685 \backslash
14686 color{red}}
14687 \series default
14688
14689 \begin_inset Newline newline
14690 \end_inset
14691
14692 as \SpecialChar TeX
14693  Code before the multicolumn inset.
14694  Replace 
14695 \series bold
14696 red
14697 \series default
14698  in this command by a color of your choice.
14699  You can use all pre- and self-defined colors.
14700  See the 
14701 \emph on
14702 EmbeddedObjects
14703 \emph default
14704  manual, section 
14705 \emph on
14706 Colored
14707 \begin_inset space ~
14708 \end_inset
14709
14710 Tables
14711 \emph default
14712  for more information about pre- and self-defined colors.
14713  To go back to the default color insert the command
14714 \begin_inset Newline newline
14715 \end_inset
14716
14717
14718 \series bold
14719
14720 \backslash
14721 renewcommand{
14722 \backslash
14723 columnseprulecolor}{
14724 \backslash
14725 normalcolor}
14726 \series default
14727
14728 \begin_inset Newline newline
14729 \end_inset
14730
14731 Here is the example with a cyan rule and 1
14732 \begin_inset space \thinspace{}
14733 \end_inset
14734
14735 cm column separation:
14736 \end_layout
14737
14738 \begin_layout Standard
14739 \begin_inset ERT
14740 status open
14741
14742 \begin_layout Plain Layout
14743
14744
14745 \backslash
14746 setlength{
14747 \backslash
14748 columnsep}{1cm}
14749 \end_layout
14750
14751 \begin_layout Plain Layout
14752
14753
14754 \backslash
14755 renewcommand{
14756 \backslash
14757 columnseprulecolor}{
14758 \backslash
14759 color{cyan}}
14760 \end_layout
14761
14762 \end_inset
14763
14764
14765 \end_layout
14766
14767 \begin_layout Standard
14768 \begin_inset Flex Multiple Columns
14769 status open
14770
14771 \begin_layout Plain Layout
14772
14773 \size small
14774 \begin_inset Quotes eld
14775 \end_inset
14776
14777 You're surprised to see me, sir,
14778 \begin_inset Quotes erd
14779 \end_inset
14780
14781  said he, in a strange, croaking voice.
14782 \end_layout
14783
14784 \begin_layout Plain Layout
14785
14786 \size small
14787 I acknowledged that I was.
14788 \end_layout
14789
14790 \begin_layout Plain Layout
14791
14792 \size small
14793 \begin_inset Quotes eld
14794 \end_inset
14795
14796 Well, I've a conscience, sir, and when I chanced to see you go into this
14797  house, as I came hobbling after you, I thought to myself, I'll just step
14798  in and see that kind gentleman, and tell him that if I was a bit gruff
14799  in my manner there was not any harm meant, and that I am much obliged to
14800  him for picking up my books.
14801 \begin_inset Quotes erd
14802 \end_inset
14803
14804
14805 \end_layout
14806
14807 \begin_layout Plain Layout
14808
14809 \size small
14810 \begin_inset Quotes eld
14811 \end_inset
14812
14813 You make too much of a trifle,
14814 \begin_inset Quotes erd
14815 \end_inset
14816
14817  said I.
14818  
14819 \begin_inset Quotes eld
14820 \end_inset
14821
14822 May I ask how you knew who I was?
14823 \begin_inset Quotes erd
14824 \end_inset
14825
14826
14827 \end_layout
14828
14829 \begin_layout Plain Layout
14830
14831 \size small
14832 \begin_inset Quotes eld
14833 \end_inset
14834
14835 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14836  you'll find my little bookshop at the corner of Church Street, and very
14837  happy to see you, I am sure.
14838  Maybe you collect yourself, sir.
14839  Here's 
14840 \noun on
14841 British
14842 \begin_inset space ~
14843 \end_inset
14844
14845 Birds
14846 \noun default
14847 , and 
14848 \noun on
14849 Catullus
14850 \noun default
14851 , and 
14852 \noun on
14853 The Holy War
14854 \noun default
14855 –a bargain, every one of them.
14856  With five volumes you could just fill that gap on that second shelf.
14857  It looks untidy, does it not, sir?
14858 \begin_inset Quotes erd
14859 \end_inset
14860
14861
14862 \end_layout
14863
14864 \end_inset
14865
14866
14867 \end_layout
14868
14869 \begin_layout Standard
14870 \begin_inset ERT
14871 status collapsed
14872
14873 \begin_layout Plain Layout
14874
14875
14876 \backslash
14877 setlength{
14878 \backslash
14879 columnseprule}{0pt}
14880 \end_layout
14881
14882 \begin_layout Plain Layout
14883
14884
14885 \backslash
14886 renewcommand{
14887 \backslash
14888 columnseprulecolor}{
14889 \backslash
14890 normalcolor}
14891 \end_layout
14892
14893 \end_inset
14894
14895
14896 \begin_inset Note Note
14897 status collapsed
14898
14899 \begin_layout Plain Layout
14900 go back to the default
14901 \end_layout
14902
14903 \end_inset
14904
14905
14906 \end_layout
14907
14908 \begin_layout Chapter
14909
14910 \change_inserted 893223064 1464852301
14911 Text formatting
14912 \end_layout
14913
14914 \begin_layout Section
14915 Non-standard Paragraph Shapes
14916 \end_layout
14917
14918 \begin_layout Standard
14919 \noindent
14920 \SpecialChar LaTeX
14921  as well as any other text processor uses by default rectangular paragraphs.
14922  For special cases like for example posters, invitation cards or poems you
14923  can modify the paragraph shape to one of your choice.
14924  This can be done by using the \SpecialChar LaTeX
14925 -package 
14926 \series bold
14927 shapepar
14928 \series default
14929  which is loaded by using in the document settings the module 
14930 \family sans
14931 Custom paragraph shapes
14932 \family default
14933 .
14934 \end_layout
14935
14936 \begin_layout Subsection
14937 Predefined shapes
14938 \end_layout
14939
14940 \begin_layout Standard
14941
14942 \series bold
14943 shapepar
14944 \series default
14945  provides the following shapes:
14946 \end_layout
14947
14948 \begin_layout Standard
14949 \begin_inset Tabular
14950 <lyxtabular version="3" rows="13" columns="3">
14951 <features booktabs="true" islongtable="true" longtabularalignment="center">
14952 <column alignment="center" valignment="middle" width="16col%">
14953 <column alignment="center" valignment="middle" width="40col%">
14954 <column alignment="center" valignment="middle" width="35col%">
14955 <row endhead="true">
14956 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
14957 \begin_inset Text
14958
14959 \begin_layout Plain Layout
14960 Name
14961 \end_layout
14962
14963 \end_inset
14964 </cell>
14965 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
14966 \begin_inset Text
14967
14968 \begin_layout Plain Layout
14969 Description
14970 \end_layout
14971
14972 \end_inset
14973 </cell>
14974 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
14975 \begin_inset Text
14976
14977 \begin_layout Plain Layout
14978 Annotation
14979 \end_layout
14980
14981 \end_inset
14982 </cell>
14983 </row>
14984 <row>
14985 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
14986 \begin_inset Text
14987
14988 \begin_layout Plain Layout
14989 CDlabel
14990 \end_layout
14991
14992 \end_inset
14993 </cell>
14994 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
14995 \begin_inset Text
14996
14997 \begin_layout Plain Layout
14998 Circle with circular hole (in the size of a CD/DVD)
14999 \end_layout
15000
15001 \end_inset
15002 </cell>
15003 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15004 \begin_inset Text
15005
15006 \begin_layout Plain Layout
15007 Cannot be scaled, take care there is not too much text
15008 \end_layout
15009
15010 \end_inset
15011 </cell>
15012 </row>
15013 <row>
15014 <cell alignment="center" valignment="top" topline="true" usebox="none">
15015 \begin_inset Text
15016
15017 \begin_layout Plain Layout
15018 Circle
15019 \end_layout
15020
15021 \end_inset
15022 </cell>
15023 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15024 \begin_inset Text
15025
15026 \begin_layout Plain Layout
15027 Circle
15028 \end_layout
15029
15030 \end_inset
15031 </cell>
15032 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15033 \begin_inset Text
15034
15035 \begin_layout Plain Layout
15036 Fragile, calculation might fail
15037 \end_layout
15038
15039 \end_inset
15040 </cell>
15041 </row>
15042 <row>
15043 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15044 \begin_inset Text
15045
15046 \begin_layout Plain Layout
15047 Diamond
15048 \end_layout
15049
15050 \end_inset
15051 </cell>
15052 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15053 \begin_inset Text
15054
15055 \begin_layout Plain Layout
15056 Rhomboid (symbolizing a 
15057 \begin_inset Quotes eld
15058 \end_inset
15059
15060 diamond
15061 \begin_inset Quotes erd
15062 \end_inset
15063
15064 )
15065 \end_layout
15066
15067 \end_inset
15068 </cell>
15069 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15070 \begin_inset Text
15071
15072 \begin_layout Plain Layout
15073 -
15074 \end_layout
15075
15076 \end_inset
15077 </cell>
15078 </row>
15079 <row>
15080 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15081 \begin_inset Text
15082
15083 \begin_layout Plain Layout
15084 Heart
15085 \end_layout
15086
15087 \end_inset
15088 </cell>
15089 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15090 \begin_inset Text
15091
15092 \begin_layout Plain Layout
15093 Heart-like shape
15094 \end_layout
15095
15096 \end_inset
15097 </cell>
15098 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15099 \begin_inset Text
15100
15101 \begin_layout Plain Layout
15102 -
15103 \end_layout
15104
15105 \end_inset
15106 </cell>
15107 </row>
15108 <row>
15109 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15110 \begin_inset Text
15111
15112 \begin_layout Plain Layout
15113 Hexagon
15114 \end_layout
15115
15116 \end_inset
15117 </cell>
15118 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15119 \begin_inset Text
15120
15121 \begin_layout Plain Layout
15122 Hexagon
15123 \end_layout
15124
15125 \end_inset
15126 </cell>
15127 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15128 \begin_inset Text
15129
15130 \begin_layout Plain Layout
15131 -
15132 \end_layout
15133
15134 \end_inset
15135 </cell>
15136 </row>
15137 <row>
15138 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15139 \begin_inset Text
15140
15141 \begin_layout Plain Layout
15142 Nut
15143 \end_layout
15144
15145 \end_inset
15146 </cell>
15147 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15148 \begin_inset Text
15149
15150 \begin_layout Plain Layout
15151 Nut for bolt (hexagon with circular hole)
15152 \end_layout
15153
15154 \end_inset
15155 </cell>
15156 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15157 \begin_inset Text
15158
15159 \begin_layout Plain Layout
15160 -
15161 \end_layout
15162
15163 \end_inset
15164 </cell>
15165 </row>
15166 <row>
15167 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15168 \begin_inset Text
15169
15170 \begin_layout Plain Layout
15171 Square
15172 \end_layout
15173
15174 \end_inset
15175 </cell>
15176 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15177 \begin_inset Text
15178
15179 \begin_layout Plain Layout
15180 Square
15181 \end_layout
15182
15183 \end_inset
15184 </cell>
15185 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15186 \begin_inset Text
15187
15188 \begin_layout Plain Layout
15189 -
15190 \end_layout
15191
15192 \end_inset
15193 </cell>
15194 </row>
15195 <row>
15196 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15197 \begin_inset Text
15198
15199 \begin_layout Plain Layout
15200 Star
15201 \end_layout
15202
15203 \end_inset
15204 </cell>
15205 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15206 \begin_inset Text
15207
15208 \begin_layout Plain Layout
15209 Five-point star
15210 \end_layout
15211
15212 \end_inset
15213 </cell>
15214 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
15215 \begin_inset Text
15216
15217 \begin_layout Plain Layout
15218 -
15219 \end_layout
15220
15221 \end_inset
15222 </cell>
15223 </row>
15224 <row>
15225 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15226 \begin_inset Text
15227
15228 \begin_layout Plain Layout
15229 Candle
15230 \end_layout
15231
15232 \end_inset
15233 </cell>
15234 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15235 \begin_inset Text
15236
15237 \begin_layout Plain Layout
15238 Burning candle
15239 \end_layout
15240
15241 \end_inset
15242 </cell>
15243 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15244 \begin_inset Text
15245
15246 \begin_layout Plain Layout
15247 -
15248 \end_layout
15249
15250 \end_inset
15251 </cell>
15252 </row>
15253 <row>
15254 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15255 \begin_inset Text
15256
15257 \begin_layout Plain Layout
15258 Drop down/up
15259 \end_layout
15260
15261 \end_inset
15262 </cell>
15263 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15264 \begin_inset Text
15265
15266 \begin_layout Plain Layout
15267 Normal/reversed rain drop
15268 \end_layout
15269
15270 \end_inset
15271 </cell>
15272 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15273 \begin_inset Text
15274
15275 \begin_layout Plain Layout
15276 Fragile, calculation might fail
15277 \end_layout
15278
15279 \end_inset
15280 </cell>
15281 </row>
15282 <row>
15283 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15284 \begin_inset Text
15285
15286 \begin_layout Plain Layout
15287 \SpecialChar TeX
15288
15289 \end_layout
15290
15291 \end_inset
15292 </cell>
15293 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15294 \begin_inset Text
15295
15296 \begin_layout Plain Layout
15297 The \SpecialChar TeX
15298  logo
15299 \end_layout
15300
15301 \end_inset
15302 </cell>
15303 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15304 \begin_inset Text
15305
15306 \begin_layout Plain Layout
15307 -
15308 \end_layout
15309
15310 \end_inset
15311 </cell>
15312 </row>
15313 <row>
15314 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15315 \begin_inset Text
15316
15317 \begin_layout Plain Layout
15318 Triangle up/down/
15319 \begin_inset Newline newline
15320 \end_inset
15321
15322 left/right
15323 \end_layout
15324
15325 \end_inset
15326 </cell>
15327 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15328 \begin_inset Text
15329
15330 \begin_layout Plain Layout
15331 Triangles in different orientations
15332 \end_layout
15333
15334 \end_inset
15335 </cell>
15336 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
15337 \begin_inset Text
15338
15339 \begin_layout Plain Layout
15340 -
15341 \end_layout
15342
15343 \end_inset
15344 </cell>
15345 </row>
15346 </lyxtabular>
15347
15348 \end_inset
15349
15350
15351 \end_layout
15352
15353 \begin_layout Standard
15354 To use a shape for your paragraph, simply select it in \SpecialChar LyX
15355 's pull-down box
15356  for environments in the toolbar.
15357 \end_layout
15358
15359 \begin_layout Standard
15360 \begin_inset Newpage newpage
15361 \end_inset
15362
15363
15364 \end_layout
15365
15366 \begin_layout Standard
15367 Here is an example paragraph in the shape of a nut:
15368 \end_layout
15369
15370 \begin_layout Standard
15371 \begin_inset VSpace bigskip
15372 \end_inset
15373
15374
15375 \end_layout
15376
15377 \begin_layout Nut
15378
15379 \lang latin
15380 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15381  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15382  voluptua.
15383  At vero eos et accusam et justo duo dolores et ea rebum.
15384  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15385  sit amet.
15386  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15387  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15388  voluptua.
15389 \end_layout
15390
15391 \begin_layout Standard
15392 \begin_inset VSpace bigskip
15393 \end_inset
15394
15395
15396 \end_layout
15397
15398 \begin_layout Standard
15399 \begin_inset Note Greyedout
15400 status open
15401
15402 \begin_layout Plain Layout
15403
15404 \series bold
15405 Note
15406 \series default
15407 : shapepar paragraphs cannot run over a page break.
15408 \end_layout
15409
15410 \end_inset
15411
15412
15413 \end_layout
15414
15415 \begin_layout Standard
15416 \begin_inset VSpace bigskip
15417 \end_inset
15418
15419
15420 \end_layout
15421
15422 \begin_layout Standard
15423
15424 \series bold
15425 shapepar
15426 \series default
15427  takes care that the shape will always be preserved, no matter how much
15428  text is in the paragraph.
15429  Therefore the paragraph size changes with the amount of contained text.
15430  This can lead to paragraph sizes exceeding the page margins.
15431  To demonstrate the size scaling, here is the same example paragraph but
15432  with twice as much text:
15433 \end_layout
15434
15435 \begin_layout Standard
15436 \begin_inset Newpage newpage
15437 \end_inset
15438
15439
15440 \end_layout
15441
15442 \begin_layout Nut
15443
15444 \lang latin
15445 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15446  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15447  voluptua.
15448  At vero eos et accusam et justo duo dolores et ea rebum.
15449  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15450  sit amet.
15451  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15452  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15453  voluptua.
15454  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15455  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15456  voluptua.
15457  At vero eos et accusam et justo duo dolores et ea rebum.
15458  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15459  sit amet.
15460  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15461  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15462  voluptua.
15463 \end_layout
15464
15465 \begin_layout Standard
15466 \begin_inset VSpace bigskip
15467 \end_inset
15468
15469
15470 \end_layout
15471
15472 \begin_layout Standard
15473 An exception is the shape 
15474 \family sans
15475 CDlabel
15476 \family default
15477 .
15478  It cannot be scaled because it must fit the size of a CD/DVD.
15479  Therefore the amount of text that fits into the shape is limited.
15480 \begin_inset Newline newline
15481 \end_inset
15482
15483 The 
15484 \family sans
15485 drop
15486 \family default
15487  shapes and the 
15488 \family sans
15489 circle
15490 \family default
15491  shape are fragile, meaning that the calculation of their size can fail,
15492  depending on the amount of text.
15493  You will then get the \SpecialChar LaTeX
15494  error 
15495 \begin_inset Quotes eld
15496 \end_inset
15497
15498 Arithmetic overflow
15499 \begin_inset Quotes erd
15500 \end_inset
15501
15502 .
15503  In this case one can try to remove or add some text; if nothing works one
15504  has to use another shape.
15505 \end_layout
15506
15507 \begin_layout Standard
15508 \begin_inset VSpace bigskip
15509 \end_inset
15510
15511
15512 \end_layout
15513
15514 \begin_layout Standard
15515 For shapes with tips you will maybe see that \SpecialChar LaTeX
15516 's hyphenation routine fails
15517  for text in the tips.
15518  Therefore it is often necessary to add hyphenation points 
15519 \family sans
15520 (
15521 \begin_inset Info
15522 type  "shortcut"
15523 arg   "specialchar-insert hyphenation"
15524 \end_inset
15525
15526
15527 \family default
15528 ) to the corresponding text parts.
15529 \end_layout
15530
15531 \begin_layout Standard
15532 \begin_inset VSpace bigskip
15533 \end_inset
15534
15535
15536 \end_layout
15537
15538 \begin_layout Standard
15539 Shapepar paragraphs are either always centered or placed on the page so
15540  that their left border touches the left page margin.
15541  You can therefore not use the paragraph dialog to align such paragraphs.
15542  A solution is to put the paragraph into a minipage or parbox and align
15543  the box.
15544  The problem is hereby to find the right width for the box.
15545  Because if it is too wide and you center the box, the paragraph is not
15546  centered too because it sticks at the left side of the box.
15547  So you might have to play a bit with the width until it fits.
15548  Here are two heart-shaped paragraphs, the first one is not aligned, the
15549  second one is right-aligned:
15550 \end_layout
15551
15552 \begin_layout Standard
15553 \begin_inset Newpage newpage
15554 \end_inset
15555
15556
15557 \end_layout
15558
15559 \begin_layout Heart
15560 \noindent
15561
15562 \lang latin
15563 Lo\SpecialChar softhyphen
15564 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15565  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15566  voluptua.
15567  At vero eos et accusam et justo duo dolores et ea rebum.
15568  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15569  sit amet.
15570 \end_layout
15571
15572 \begin_layout Standard
15573 \begin_inset VSpace bigskip
15574 \end_inset
15575
15576
15577 \end_layout
15578
15579 \begin_layout Standard
15580 \noindent
15581 \align right
15582 \begin_inset Box Frameless
15583 position "t"
15584 hor_pos "c"
15585 has_inner_box 1
15586 inner_pos "t"
15587 use_parbox 1
15588 use_makebox 0
15589 width "42col%"
15590 special "none"
15591 height "1in"
15592 height_special "totalheight"
15593 thickness "0.4pt"
15594 separation "3pt"
15595 shadowsize "4pt"
15596 framecolor "black"
15597 backgroundcolor "none"
15598 status open
15599
15600 \begin_layout Heart
15601 \noindent
15602
15603 \lang latin
15604 Lo\SpecialChar softhyphen
15605 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15606  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15607  voluptua.
15608  At vero eos et accusam et justo duo dolores et ea rebum.
15609  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15610  sit amet.
15611 \end_layout
15612
15613 \end_inset
15614
15615
15616 \end_layout
15617
15618 \begin_layout Subsection
15619 Custom shapes
15620 \end_layout
15621
15622 \begin_layout Standard
15623 You can define any shape you want.
15624  Doing this manually is a lot of work because every coordinate must be specified.
15625  But there is a way to let the computer calculate the coordinates:
15626 \end_layout
15627
15628 \begin_layout Enumerate
15629 Install the program 
15630 \begin_inset CommandInset href
15631 LatexCommand href
15632 name "Jpgfdraw"
15633 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
15634
15635 \end_inset
15636
15637 .
15638 \end_layout
15639
15640 \begin_layout Enumerate
15641 In 
15642 \family sans
15643 Jpgfdraw
15644 \family default
15645  go to the menu 
15646 \family sans
15647 TeX/LaTeX\SpecialChar menuseparator
15648 Settings\SpecialChar menuseparator
15649 Set Normal Size
15650 \family default
15651  and select the font size you are using in your document.
15652  For example this document uses the size 12
15653 \begin_inset space \thinspace{}
15654 \end_inset
15655
15656 pt.
15657 \end_layout
15658
15659 \begin_layout Enumerate
15660 Draw a shape.
15661 \end_layout
15662
15663 \begin_layout Enumerate
15664 Use the menu 
15665 \family sans
15666 TeX/LaTeX\SpecialChar menuseparator
15667 Shapepar
15668 \family default
15669  to export the shape to coordinates.
15670  In the appearing dialog use either the outline of your shape for the coordinate
15671 s or the path itself.
15672 \begin_inset Foot
15673 status collapsed
15674
15675 \begin_layout Plain Layout
15676 For more information see 
15677 \begin_inset CommandInset href
15678 LatexCommand href
15679 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
15680
15681 \end_inset
15682
15683
15684 \end_layout
15685
15686 \end_inset
15687
15688
15689 \end_layout
15690
15691 \begin_layout Standard
15692 The coordinates are written into a \SpecialChar TeX
15693  file.
15694  To use it for your \SpecialChar LyX
15695  document
15696 \end_layout
15697
15698 \begin_layout Enumerate
15699 Place the cursor before the first character of your paragraph (or into a
15700  new empty one).
15701 \end_layout
15702
15703 \begin_layout Enumerate
15704 Open in \SpecialChar LyX
15705  the menu 
15706 \family sans
15707 Insert\SpecialChar menuseparator
15708 File\SpecialChar menuseparator
15709 Child
15710 \begin_inset space ~
15711 \end_inset
15712
15713 Document
15714 \family default
15715 , select the file and use 
15716 \family sans
15717 Input
15718 \family default
15719  as 
15720 \family sans
15721 Include Type.
15722 \end_layout
15723
15724 \begin_layout Standard
15725 \begin_inset VSpace defskip
15726 \end_inset
15727
15728
15729 \end_layout
15730
15731 \begin_layout Standard
15732 \begin_inset Note Greyedout
15733 status open
15734
15735 \begin_layout Plain Layout
15736
15737 \series bold
15738 Note
15739 \series default
15740 : The changed shape only applies to the current paragraph; everything is
15741  reset to normal for the next paragraph.
15742  Therefore the shape definition file must be input into every paragraph
15743  with the desired shape.
15744 \end_layout
15745
15746 \end_inset
15747
15748
15749 \end_layout
15750
15751 \begin_layout Standard
15752 \begin_inset VSpace bigskip
15753 \end_inset
15754
15755
15756 \end_layout
15757
15758 \begin_layout Standard
15759 Here is an example:
15760 \end_layout
15761
15762 \begin_layout Standard
15763 \begin_inset VSpace bigskip
15764 \end_inset
15765
15766
15767 \end_layout
15768
15769 \begin_layout Standard
15770 \begin_inset CommandInset include
15771 LatexCommand input
15772 filename "SpecialParagraphShape.tex"
15773
15774 \end_inset
15775
15776
15777 \lang latin
15778 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15779  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15780  voluptua.
15781  At vero eos et accusam et justo duo dolores et ea rebum.
15782  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15783  sit amet.
15784  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15785  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15786  voluptua.
15787 \end_layout
15788
15789 \begin_layout Standard
15790 \begin_inset VSpace bigskip
15791 \end_inset
15792
15793
15794 \end_layout
15795
15796 \begin_layout Standard
15797
15798 \series bold
15799 A tip:
15800 \series default
15801  to draw complexer shapes in 
15802 \family sans
15803 Jpgfdraw
15804 \family default
15805  you can draw the shape in a program of your choice and import the resulting
15806  image to 
15807 \family sans
15808 Jpgfdraw
15809 \family default
15810 .
15811  Then you only need to draw a line or spline along the outline of the image.
15812 \end_layout
15813
15814 \begin_layout Standard
15815 \begin_inset VSpace bigskip
15816 \end_inset
15817
15818
15819 \end_layout
15820
15821 \begin_layout Standard
15822 The module 
15823 \family sans
15824 Custom paragraph shapes
15825 \family default
15826  also provides the two commands 
15827 \family sans
15828 shapepar
15829 \family default
15830  and 
15831 \family sans
15832 Shapepar
15833 \family default
15834  which can be used to define custom shapes coordinate by coordinate.
15835 \begin_inset Foot
15836 status collapsed
15837
15838 \begin_layout Plain Layout
15839 These commands are internally used for all shapes described here.
15840 \end_layout
15841
15842 \end_inset
15843
15844  For information how these styles are used and about further customization
15845  possibilities, have a look at the documentation of the package 
15846 \series bold
15847 shapepar
15848 \series default
15849
15850 \begin_inset CommandInset citation
15851 LatexCommand cite
15852 key "shapepar"
15853
15854 \end_inset
15855
15856 .
15857 \end_layout
15858
15859 \begin_layout Bibliography
15860 \begin_inset CommandInset bibitem
15861 LatexCommand bibitem
15862 key "multicol"
15863
15864 \end_inset
15865
15866 Documentation of the \SpecialChar LaTeX
15867 -package 
15868 \begin_inset CommandInset href
15869 LatexCommand href
15870 name "multicol"
15871 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
15872
15873 \end_inset
15874
15875
15876 \end_layout
15877
15878 \begin_layout Bibliography
15879 \begin_inset CommandInset bibitem
15880 LatexCommand bibitem
15881 key "shapepar"
15882
15883 \end_inset
15884
15885 Documentation of the \SpecialChar LaTeX
15886 -package 
15887 \begin_inset CommandInset href
15888 LatexCommand href
15889 name "shapepar"
15890 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"
15891
15892 \end_inset
15893
15894
15895 \end_layout
15896
15897 \begin_layout Chapter
15898
15899 \change_inserted 893223064 1464852414
15900 Bibliographic databases
15901 \change_deleted 893223064 1464852406
15902 Supplemental Tools
15903 \change_unchanged
15904
15905 \end_layout
15906
15907 \begin_layout Section
15908 Customizing Bibliographies with Bib\SpecialChar TeX
15909
15910 \end_layout
15911
15912 \begin_layout Standard
15913 The most basic information about how to use Bib\SpecialChar TeX
15914  with \SpecialChar LyX
15915  is contained in the
15916  section 
15917 \emph on
15918 Bibliography databases (Bib\SpecialChar TeX
15919 )
15920 \emph default
15921  of the 
15922 \emph on
15923 User's Guide
15924 \emph default
15925 .
15926  The following subsections explain special bibliography features supported
15927  by \SpecialChar LyX
15928 .
15929 \end_layout
15930
15931 \begin_layout Subsection
15932 Alternative Citation Styles
15933 \end_layout
15934
15935 \begin_layout Standard
15936 Standard Bib\SpecialChar TeX
15937  uses numbers (e.
15938 \begin_inset space \thinspace{}
15939 \end_inset
15940
15941 g.
15942 \begin_inset space \space{}
15943 \end_inset
15944
15945
15946 \begin_inset Quotes eld
15947 \end_inset
15948
15949 [12]
15950 \begin_inset Quotes erd
15951 \end_inset
15952
15953 ) to refer to a cited work.
15954  However, in many scientific disciplines, other citation styles are in use.
15955  The most common one is the author-year style (e.
15956 \begin_inset space \thinspace{}
15957 \end_inset
15958
15959 g.
15960 \begin_inset space \space{}
15961 \end_inset
15962
15963
15964 \begin_inset Quotes eld
15965 \end_inset
15966
15967 Knuth 1984a
15968 \begin_inset Quotes erd
15969 \end_inset
15970
15971 ).
15972  \SpecialChar LyX
15973  supports two packages that provide this style, 
15974 \begin_inset Flex Code
15975 status collapsed
15976
15977 \begin_layout Plain Layout
15978 natbib
15979 \end_layout
15980
15981 \end_inset
15982
15983  and 
15984 \begin_inset Flex Code
15985 status collapsed
15986
15987 \begin_layout Plain Layout
15988 jurabib
15989 \end_layout
15990
15991 \end_inset
15992
15993 .
15994  Both packages have their pros and cons, which cannot be listed in detail.
15995  If you only want to have simple author-year (or author-numerical) style,
15996  or if you want to use one of the countless style files for 
15997 \begin_inset Flex Code
15998 status collapsed
15999
16000 \begin_layout Plain Layout
16001 natbib
16002 \end_layout
16003
16004 \end_inset
16005
16006 , then the established 
16007 \begin_inset Flex Code
16008 status collapsed
16009
16010 \begin_layout Plain Layout
16011 natbib
16012 \end_layout
16013
16014 \end_inset
16015
16016  package is probably your choice.
16017  If you need special features like short title references, ibidem etc., you
16018  might consider the 
16019 \begin_inset Flex Code
16020 status collapsed
16021
16022 \begin_layout Plain Layout
16023 jurabib
16024 \end_layout
16025
16026 \end_inset
16027
16028  package.
16029 \end_layout
16030
16031 \begin_layout Standard
16032 The handling of both packages in \SpecialChar LyX
16033  is basically the same.
16034  Go to 
16035 \begin_inset Flex Noun
16036 status collapsed
16037
16038 \begin_layout Plain Layout
16039 Document\SpecialChar menuseparator
16040 Settings
16041 \end_layout
16042
16043 \end_inset
16044
16045  and select under 
16046 \begin_inset Flex Noun
16047 status collapsed
16048
16049 \begin_layout Plain Layout
16050 Bibliography
16051 \end_layout
16052
16053 \end_inset
16054
16055  the option 
16056 \begin_inset Flex Noun
16057 status collapsed
16058
16059 \begin_layout Plain Layout
16060 Natbib
16061 \end_layout
16062
16063 \end_inset
16064
16065  or 
16066 \begin_inset Flex Noun
16067 status collapsed
16068
16069 \begin_layout Plain Layout
16070 Jurabib
16071 \end_layout
16072
16073 \end_inset
16074
16075 .
16076  With both packages, you will get some extra features in the citation dialog
16077  and you can select the style of the reference (
16078 \begin_inset Quotes eld
16079 \end_inset
16080
16081 Knuth 1984
16082 \begin_inset Quotes erd
16083 \end_inset
16084
16085
16086 \begin_inset Quotes eld
16087 \end_inset
16088
16089 Knuth (1984)
16090 \begin_inset Quotes erd
16091 \end_inset
16092
16093
16094 \begin_inset Quotes eld
16095 \end_inset
16096
16097 Knuth, 1984
16098 \begin_inset Quotes erd
16099 \end_inset
16100
16101
16102 \begin_inset Quotes eld
16103 \end_inset
16104
16105 1984
16106 \begin_inset Quotes erd
16107 \end_inset
16108
16109  etc.).
16110  Note that both packages need specifically designed style files.
16111  They both ship their own, but there are lots of additional style files,
16112  and there is even an interactive style file builder
16113 \begin_inset Foot
16114 status collapsed
16115
16116 \begin_layout Plain Layout
16117 See 
16118 \begin_inset Flex URL
16119 status open
16120
16121 \begin_layout Plain Layout
16122
16123 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
16124 \end_layout
16125
16126 \end_inset
16127
16128
16129 \end_layout
16130
16131 \end_inset
16132
16133  for 
16134 \begin_inset Flex Code
16135 status collapsed
16136
16137 \begin_layout Plain Layout
16138 natbib
16139 \end_layout
16140
16141 \end_inset
16142
16143 .
16144 \end_layout
16145
16146 \begin_layout Subsection
16147 Sectioned Bibliographies
16148 \end_layout
16149
16150 \begin_layout Standard
16151 Sometimes you might need to divide your bibliography into several sections.
16152  If you are for instance a historian, the possibility to separate sources
16153  and scientific works is most likely a 
16154 \begin_inset Quotes eld
16155 \end_inset
16156
16157 must have
16158 \begin_inset Quotes erd
16159 \end_inset
16160
16161 .
16162  Unfortunately, Bib\SpecialChar TeX
16163  itself does not allow you to do this.
16164  But with the help of some \SpecialChar LaTeX
16165  packages, Bib\SpecialChar TeX
16166  can be extended to fit your needs.
16167 \end_layout
16168
16169 \begin_layout Standard
16170 \SpecialChar LyX
16171  provides native support for one of these packages, 
16172 \family typewriter
16173 bibtopic
16174 \family default
16175 .
16176 \begin_inset Foot
16177 status collapsed
16178
16179 \begin_layout Plain Layout
16180 Available from 
16181 \begin_inset Flex URL
16182 status open
16183
16184 \begin_layout Plain Layout
16185
16186 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
16187 \end_layout
16188
16189 \end_inset
16190
16191
16192 \end_layout
16193
16194 \end_inset
16195
16196  The advantage of this package (compared to other packages like 
16197 \family typewriter
16198 multibib
16199 \family default
16200 ) is that you don't need to define new citation commands.
16201  Instead, you need to prepare different bibliographic databases which include
16202  the entries for the different sections of the bibliography.
16203  For example: If you want to divide your bibliography into the sections
16204  
16205 \begin_inset Quotes eld
16206 \end_inset
16207
16208 Sources
16209 \begin_inset Quotes erd
16210 \end_inset
16211
16212  and 
16213 \begin_inset Quotes eld
16214 \end_inset
16215
16216 Scientific works
16217 \begin_inset Quotes erd
16218 \end_inset
16219
16220 , you first need to create two bibliographic databases, e.
16221 \begin_inset space \thinspace{}
16222 \end_inset
16223
16224 g.
16225 \begin_inset space \space{}
16226 \end_inset
16227
16228
16229 \begin_inset Flex Code
16230 status collapsed
16231
16232 \begin_layout Plain Layout
16233 sources.bib
16234 \end_layout
16235
16236 \end_inset
16237
16238  and 
16239 \begin_inset Flex Code
16240 status collapsed
16241
16242 \begin_layout Plain Layout
16243 scientific.bib
16244 \end_layout
16245
16246 \end_inset
16247
16248 .
16249  
16250 \end_layout
16251
16252 \begin_layout Standard
16253 Go to 
16254 \begin_inset Flex Noun
16255 status collapsed
16256
16257 \begin_layout Plain Layout
16258 Document\SpecialChar menuseparator
16259 Settings
16260 \end_layout
16261
16262 \end_inset
16263
16264  and check under 
16265 \begin_inset Flex Noun
16266 status collapsed
16267
16268 \begin_layout Plain Layout
16269 Bibliography
16270 \end_layout
16271
16272 \end_inset
16273
16274  the option 
16275 \begin_inset Flex Noun
16276 status collapsed
16277
16278 \begin_layout Plain Layout
16279 Sectioned bibliography
16280 \end_layout
16281
16282 \end_inset
16283
16284 .
16285  Now you can insert multiple Bib\SpecialChar TeX
16286  bibliographies, one for each section of
16287  your bibliography.
16288  Returning to our example: Insert the Bib\SpecialChar TeX
16289  bibliography 
16290 \begin_inset Flex Code
16291 status collapsed
16292
16293 \begin_layout Plain Layout
16294 sources.bib
16295 \end_layout
16296
16297 \end_inset
16298
16299  and a second one for the database 
16300 \begin_inset Flex Code
16301 status collapsed
16302
16303 \begin_layout Plain Layout
16304 scientific.bib
16305 \end_layout
16306
16307 \end_inset
16308
16309 .
16310  You are free to use the same or different styles for each section.
16311  Additionally, you can choose if the bibliography section should contain
16312  
16313 \begin_inset Quotes eld
16314 \end_inset
16315
16316 all cited references
16317 \begin_inset Quotes erd
16318 \end_inset
16319
16320  of the specified database(s) (which is the default), 
16321 \begin_inset Quotes eld
16322 \end_inset
16323
16324 all uncited references
16325 \begin_inset Quotes erd
16326 \end_inset
16327
16328  or even 
16329 \begin_inset Quotes eld
16330 \end_inset
16331
16332 all references
16333 \begin_inset Quotes erd
16334 \end_inset
16335
16336 .
16337  This might be useful if you would like to separate your bibliography into
16338  three sections: 
16339 \begin_inset Quotes eld
16340 \end_inset
16341
16342 Cited sources
16343 \begin_inset Quotes erd
16344 \end_inset
16345
16346
16347 \begin_inset Quotes eld
16348 \end_inset
16349
16350 Uncited sources
16351 \begin_inset Quotes erd
16352 \end_inset
16353
16354 , and 
16355 \begin_inset Quotes eld
16356 \end_inset
16357
16358 Scientific works
16359 \begin_inset Quotes erd
16360 \end_inset
16361
16362 .
16363  The titles for the sections can be added as ordinary sections or subsections.
16364  Since 
16365 \begin_inset Flex Code
16366 status collapsed
16367
16368 \begin_layout Plain Layout
16369 bibtopic
16370 \end_layout
16371
16372 \end_inset
16373
16374  removes the bibliography title, you have to manually re-add that, too (as
16375  a chapter* or section*, for instance).
16376 \end_layout
16377
16378 \begin_layout Subsection
16379 Multiple Bibliographies
16380 \end_layout
16381
16382 \begin_layout Standard
16383 Multiple bibliographies, e.
16384 \begin_inset space \thinspace{}
16385 \end_inset
16386
16387 g.
16388 \begin_inset space \space{}
16389 \end_inset
16390
16391 a bibliography for each section or chapter of the document, are not supported
16392  by Bib\SpecialChar TeX
16393  itself.
16394  But the 
16395 \begin_inset Flex Code
16396 status collapsed
16397
16398 \begin_layout Plain Layout
16399 bibtopic
16400 \end_layout
16401
16402 \end_inset
16403
16404  package, which is used for the creation of sectioned bibliographies in
16405  \SpecialChar LyX
16406  (see the previous section), provides an easy way to solve this task, if
16407  you are willing to use some 
16408 \begin_inset Flex Noun
16409 status collapsed
16410
16411 \begin_layout Plain Layout
16412 \SpecialChar TeX
16413  Code
16414 \end_layout
16415
16416 \end_inset
16417
16418  (see section
16419 \begin_inset space ~
16420 \end_inset
16421
16422
16423 \begin_inset CommandInset ref
16424 LatexCommand ref
16425 reference "sec:Inserting-TeX-Code"
16426
16427 \end_inset
16428
16429 ).
16430 \begin_inset Foot
16431 status collapsed
16432
16433 \begin_layout Plain Layout
16434 An alternative approach is to use the 
16435 \begin_inset Flex Code
16436 status collapsed
16437
16438 \begin_layout Plain Layout
16439 chapterbib
16440 \end_layout
16441
16442 \end_inset
16443
16444  or 
16445 \begin_inset Flex Code
16446 status collapsed
16447
16448 \begin_layout Plain Layout
16449 bibunits
16450 \end_layout
16451
16452 \end_inset
16453
16454  package, respectively.
16455 \end_layout
16456
16457 \end_inset
16458
16459
16460 \end_layout
16461
16462 \begin_layout Standard
16463 First go to 
16464 \begin_inset Flex Noun
16465 status collapsed
16466
16467 \begin_layout Plain Layout
16468 Document\SpecialChar menuseparator
16469 Settings
16470 \end_layout
16471
16472 \end_inset
16473
16474  and under 
16475 \begin_inset Flex Noun
16476 status collapsed
16477
16478 \begin_layout Plain Layout
16479 Bibliography
16480 \end_layout
16481
16482 \end_inset
16483
16484  check 
16485 \begin_inset Flex Noun
16486 status collapsed
16487
16488 \begin_layout Plain Layout
16489 Sectioned bibliography
16490 \end_layout
16491
16492 \end_inset
16493
16494 .
16495  In the document, you have to enclose the sections, which shall contain
16496  their own bibliography (including the Bib\SpecialChar TeX
16497  bibliography itself), between
16498  
16499 \begin_inset Flex Code
16500 status collapsed
16501
16502 \begin_layout Plain Layout
16503
16504 \backslash
16505 begin{btUnit}
16506 \end_layout
16507
16508 \end_inset
16509
16510  and 
16511 \begin_inset Flex Code
16512 status collapsed
16513
16514 \begin_layout Plain Layout
16515
16516 \backslash
16517 end{btUnit}
16518 \end_layout
16519
16520 \end_inset
16521
16522  (those commands have to be inserted as \SpecialChar TeX
16523  code).
16524  The bibliography will contain all references that have been cited in the
16525  current 
16526 \begin_inset Flex Code
16527 status collapsed
16528
16529 \begin_layout Plain Layout
16530 btUnit
16531 \end_layout
16532
16533 \end_inset
16534
16535 .
16536  
16537 \series bold
16538 Note:
16539 \series default
16540  If you are using this approach, then every citation reference has to be
16541  inside some 
16542 \begin_inset Flex Code
16543 status collapsed
16544
16545 \begin_layout Plain Layout
16546 btUnit
16547 \end_layout
16548
16549 \end_inset
16550
16551 .
16552  Also, the 
16553 \begin_inset Flex Code
16554 status collapsed
16555
16556 \begin_layout Plain Layout
16557 btUnit
16558 \end_layout
16559
16560 \end_inset
16561
16562 s cannot be nested.
16563 \end_layout
16564
16565 \begin_layout Chapter
16566 Multipart Documents
16567 \end_layout
16568
16569 \begin_layout Section
16570 General Operation
16571 \end_layout
16572
16573 \begin_layout Standard
16574 When you are working on a large file with many sections, it is often convenient
16575  to break up the document into several files, or perhaps you have something
16576  where a table may change from time to time, but the preceding text does
16577  not.
16578  In these cases, you should seriously consider using multipart documents.
16579  For example, scientific papers often have five major sections: the introduction
16580 , observations, results, discussion, and conclusion.
16581  Each of these could be its own separate \SpecialChar LyX
16582  file, with one 
16583 \begin_inset Quotes eld
16584 \end_inset
16585
16586 master
16587 \begin_inset Quotes erd
16588 \end_inset
16589
16590  file which contains the title, authors, abstract, references, etc., plus
16591  the five included files.
16592  It is important to note that each of these files is a full \SpecialChar LyX
16593  file which
16594  can be formatted and printed on its own, as well as included in a master
16595  file.
16596  Each of these files must have the same document class, however—don't attempt
16597  to mix book classes with article classes.
16598  You may also include \SpecialChar LaTeX
16599  files; however, these files must not have their own
16600  preamble (i.
16601 \begin_inset space \thinspace{}
16602 \end_inset
16603
16604 e.
16605 \begin_inset space \space{}
16606 \end_inset
16607
16608 everything up to and including the 
16609 \begin_inset Flex Code
16610 status collapsed
16611
16612 \begin_layout Plain Layout
16613
16614 \backslash
16615 begin{document}
16616 \end_layout
16617
16618 \end_inset
16619
16620  line as well as the 
16621 \begin_inset Flex Code
16622 status collapsed
16623
16624 \begin_layout Plain Layout
16625
16626 \backslash
16627 end{document}
16628 \end_layout
16629
16630 \end_inset
16631
16632  line must be deleted) or else errors will be generated when you try to
16633  make a DVI file.
16634 \end_layout
16635
16636 \begin_layout Standard
16637 \SpecialChar LyX
16638  allows you to include files quite easily with 
16639 \begin_inset Flex Noun
16640 status collapsed
16641
16642 \begin_layout Plain Layout
16643 Insert\SpecialChar menuseparator
16644 ChiId
16645 \begin_inset space ~
16646 \end_inset
16647
16648 Document
16649 \end_layout
16650
16651 \end_inset
16652
16653 .
16654  When you click on this selection a small box is inserted into the file
16655  at the current cursor location.
16656  Clicking on the box raises a dialog which allows you to select the file
16657  to be included, and the method of its inclusion.
16658  
16659 \end_layout
16660
16661 \begin_layout Standard
16662 The file selection box should by now be obvious.
16663  The three inclusion methods are 
16664 \begin_inset Quotes eld
16665 \end_inset
16666
16667 include
16668 \begin_inset Quotes erd
16669 \end_inset
16670
16671
16672 \begin_inset Quotes eld
16673 \end_inset
16674
16675 input
16676 \begin_inset Quotes erd
16677 \end_inset
16678
16679 , and 
16680 \begin_inset Quotes eld
16681 \end_inset
16682
16683 verbatim
16684 \begin_inset Quotes erd
16685 \end_inset
16686
16687 .
16688  The difference between 
16689 \begin_inset Quotes eld
16690 \end_inset
16691
16692 include
16693 \begin_inset Quotes erd
16694 \end_inset
16695
16696  and 
16697 \begin_inset Quotes eld
16698 \end_inset
16699
16700 input
16701 \begin_inset Quotes erd
16702 \end_inset
16703
16704  is really only meaningful to \SpecialChar LaTeX
16705 perts, but the practical difference is that
16706  files that are 
16707 \begin_inset Quotes eld
16708 \end_inset
16709
16710 included
16711 \begin_inset Quotes erd
16712 \end_inset
16713
16714  are typeset beginning on a new page, while files that are 
16715 \begin_inset Quotes eld
16716 \end_inset
16717
16718 inputted
16719 \begin_inset Quotes erd
16720 \end_inset
16721
16722  are typeset starting on the current page.
16723 \end_layout
16724
16725 \begin_layout Standard
16726 Generally, the master file is converted into a full \SpecialChar LaTeX
16727  file before typesetting,
16728  while the included files are converted to \SpecialChar LaTeX
16729  files that do not have all the
16730  preamble information.
16731 \end_layout
16732
16733 \begin_layout Standard
16734
16735 \begin_inset Quotes eld
16736 \end_inset
16737
16738 verbatim
16739 \begin_inset Quotes erd
16740 \end_inset
16741
16742  included file allows you to include a file typeset exactly as it appears
16743  in the file, i.
16744 \begin_inset space \thinspace{}
16745 \end_inset
16746
16747 e.
16748 \begin_inset space \space{}
16749 \end_inset
16750
16751 in 
16752 \begin_inset Flex Code
16753 status collapsed
16754
16755 \begin_layout Plain Layout
16756 verbatim
16757 \end_layout
16758
16759 \end_inset
16760
16761  mode, with the characters set in a fixed-width typewriter font.
16762  Normally, spaces in this file are invisible, though two consecutive spaces
16763  are conserved, unlike \SpecialChar LyX
16764 's normal treatment of spaces.
16765  However, setting the 
16766 \begin_inset Flex Noun
16767 status collapsed
16768
16769 \begin_layout Plain Layout
16770 Mark
16771 \begin_inset space ~
16772 \end_inset
16773
16774 spaces
16775 \begin_inset space ~
16776 \end_inset
16777
16778 in
16779 \begin_inset space ~
16780 \end_inset
16781
16782 output
16783 \end_layout
16784
16785 \end_inset
16786
16787  checkbox typesets a mark to unambiguously define the presence of a space.
16788  
16789 \end_layout
16790
16791 \begin_layout Section
16792 Cross-References Between Files
16793 \end_layout
16794
16795 \begin_layout Standard
16796 \begin_inset Box Shadowbox
16797 position "t"
16798 hor_pos "c"
16799 has_inner_box 1
16800 inner_pos "t"
16801 use_parbox 0
16802 use_makebox 0
16803 width "100col%"
16804 special "none"
16805 height "1in"
16806 height_special "totalheight"
16807 thickness "0.4pt"
16808 separation "3pt"
16809 shadowsize "4pt"
16810 framecolor "black"
16811 backgroundcolor "none"
16812 status open
16813
16814 \begin_layout Plain Layout
16815 This section is somewhat out of date.
16816  Need to describe default master documents and how children are opened when
16817  the master is.
16818  [[FIXME]]
16819 \end_layout
16820
16821 \end_inset
16822
16823
16824 \end_layout
16825
16826 \begin_layout Standard
16827 It is possible to set up cross-references between the different files.
16828  First, open all the files in question: let's call them A and B in a two
16829  file example, where B is included in A.
16830  Let's say you insert a label in A, then want to reference it in B.
16831  Open the cross-reference dialog whilst in document B, and you can select
16832  the 
16833 \begin_inset Quotes eld
16834 \end_inset
16835
16836 buffer
16837 \begin_inset Quotes erd
16838 \end_inset
16839
16840  to use.
16841 \end_layout
16842
16843 \begin_layout Section
16844 Bibliography Lists in all Subdocuments
16845 \end_layout
16846
16847 \begin_layout Standard
16848 \begin_inset Box Frameless
16849 position "t"
16850 hor_pos "c"
16851 has_inner_box 1
16852 inner_pos "t"
16853 use_parbox 0
16854 use_makebox 0
16855 width "100col%"
16856 special "none"
16857 height "1in"
16858 height_special "totalheight"
16859 thickness "0.4pt"
16860 separation "3pt"
16861 shadowsize "4pt"
16862 framecolor "black"
16863 backgroundcolor "none"
16864 status open
16865
16866 \begin_layout Plain Layout
16867 This section also needs updating.
16868  There is now material about this on the wiki, and it could be copied here.
16869 \end_layout
16870
16871 \end_inset
16872
16873
16874 \end_layout
16875
16876 \begin_layout Standard
16877 Copy the bibliography list with all entries to all subdocuments and transform
16878  them to a comment.
16879  This way \SpecialChar LyX
16880  will find the 
16881 \begin_inset Flex Code
16882 status collapsed
16883
16884 \begin_layout Plain Layout
16885 .bib
16886 \end_layout
16887
16888 \end_inset
16889
16890 -files and you can easily insert references without making the bibliography
16891  list visible.
16892 \end_layout
16893
16894 \begin_layout Standard
16895 As the bibliography list is in a comment, \SpecialChar LaTeX
16896  won't use it and the references
16897  will look like this: [?], instead of like this: [1].
16898  One solution is to use the \SpecialChar LaTeX
16899 -package 
16900 \begin_inset Flex Code
16901 status collapsed
16902
16903 \begin_layout Plain Layout
16904 comment
16905 \end_layout
16906
16907 \end_inset
16908
16909  that will only include comments by processing the files separately.
16910  To do this, add in the \SpecialChar LaTeX
16911  preamble of every subdocument the following:
16912 \end_layout
16913
16914 \begin_layout LyX-Code
16915
16916 \backslash
16917 usepackage{comment}
16918 \end_layout
16919
16920 \begin_layout LyX-Code
16921
16922 \backslash
16923 includecomment{comment}
16924 \end_layout
16925
16926 \begin_layout Standard
16927 See also 
16928 \begin_inset Flex URL
16929 status collapsed
16930
16931 \begin_layout Plain Layout
16932
16933 http://wiki.lyx.org/FAQ/Unsorted#toc31
16934 \end_layout
16935
16936 \end_inset
16937
16938 .
16939 \end_layout
16940
16941 \begin_layout Section
16942 Itemize Bullet Selection
16943 \begin_inset CommandInset label
16944 LatexCommand label
16945 name "sec:bullet"
16946
16947 \end_inset
16948
16949
16950 \end_layout
16951
16952 \begin_layout Standard
16953 by
16954 \noun on
16955  Allan Rae
16956 \end_layout
16957
16958 \begin_layout Subsection
16959 Introduction
16960 \end_layout
16961
16962 \begin_layout Standard
16963 \SpecialChar LyX
16964  provides 216 bullet shapes that can be accessed from a simple dialog.
16965  Using this dialog you can easily specify what bullet shape to use at each
16966  level of an itemized list.
16967  These settings are document-wide so you won't be able to specify different
16968  sets of bullets for different paragraphs.
16969 \begin_inset Foot
16970 status collapsed
16971
16972 \begin_layout Plain Layout
16973 Well, actually you can but you'll have to do it by hand.
16974 \end_layout
16975
16976 \end_inset
16977
16978
16979 \end_layout
16980
16981 \begin_layout Subsection
16982 How it looks
16983 \end_layout
16984
16985 \begin_layout Standard
16986 Open the dialog by selecting the 
16987 \begin_inset Flex Noun
16988 status collapsed
16989
16990 \begin_layout Plain Layout
16991 Document\SpecialChar menuseparator
16992 Settings
16993 \end_layout
16994
16995 \end_inset
16996
16997  menu item and then select the 
16998 \begin_inset Flex Noun
16999 status collapsed
17000
17001 \begin_layout Plain Layout
17002 Bullets
17003 \end_layout
17004
17005 \end_inset
17006
17007  tab.
17008 \end_layout
17009
17010 \begin_layout Standard
17011 The dialog provides you with a table of bullet shapes.
17012  A column of buttons on the left of the table provides access to the six
17013  different panels of bullet shapes.
17014  The row of buttons across the top is used to select which bullet depth
17015  you are changing.
17016  A text entry under the table shows the currently selected bullet shape's
17017  \SpecialChar LaTeX
17018  equivalent and this can be edited if desired.
17019  If you do modify the text you will also need to specify any needed packages
17020  in the \SpecialChar LaTeX
17021  preamble.
17022 \end_layout
17023
17024 \begin_layout Standard
17025 The six panels are divided up by the packages they require.
17026  The following table shows the mappings from button name to \SpecialChar LaTeX
17027  package.
17028 \begin_inset Separator latexpar
17029 \end_inset
17030
17031
17032 \end_layout
17033
17034 \begin_layout Standard
17035 \align center
17036 \begin_inset Tabular
17037 <lyxtabular version="3" rows="7" columns="2">
17038 <features tabularvalignment="middle">
17039 <column alignment="center" valignment="top" width="0pt">
17040 <column alignment="center" valignment="top" width="0pt">
17041 <row>
17042 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
17043 \begin_inset Text
17044
17045 \begin_layout Plain Layout
17046
17047 \family roman
17048 \series medium
17049 \shape up
17050 \size normal
17051 \emph off
17052 \bar no
17053 \noun off
17054 \color none
17055 Button
17056 \end_layout
17057
17058 \end_inset
17059 </cell>
17060 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
17061 \begin_inset Text
17062
17063 \begin_layout Plain Layout
17064
17065 \family roman
17066 \series medium
17067 \shape up
17068 \size normal
17069 \emph off
17070 \bar no
17071 \noun off
17072 \color none
17073 Packages Required
17074 \end_layout
17075
17076 \end_inset
17077 </cell>
17078 </row>
17079 <row>
17080 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17081 \begin_inset Text
17082
17083 \begin_layout Plain Layout
17084
17085 \family sans
17086 \series medium
17087 \shape up
17088 \size normal
17089 \emph off
17090 \bar no
17091 \noun off
17092 \color none
17093 Standard
17094 \end_layout
17095
17096 \end_inset
17097 </cell>
17098 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17099 \begin_inset Text
17100
17101 \begin_layout Plain Layout
17102
17103 \series medium
17104 \shape up
17105 \size normal
17106 \emph off
17107 \bar no
17108 \noun off
17109 \color none
17110 base \SpecialChar LaTeX
17111
17112 \end_layout
17113
17114 \end_inset
17115 </cell>
17116 </row>
17117 <row>
17118 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17119 \begin_inset Text
17120
17121 \begin_layout Plain Layout
17122
17123 \family sans
17124 \series medium
17125 \shape up
17126 \size normal
17127 \emph off
17128 \bar no
17129 \noun off
17130 \color none
17131 Maths
17132 \end_layout
17133
17134 \end_inset
17135 </cell>
17136 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17137 \begin_inset Text
17138
17139 \begin_layout Plain Layout
17140
17141 \family typewriter
17142 \series medium
17143 \shape up
17144 \size normal
17145 \emph off
17146 \bar no
17147 \noun off
17148 \color none
17149 amssymb.sty
17150 \end_layout
17151
17152 \end_inset
17153 </cell>
17154 </row>
17155 <row>
17156 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17157 \begin_inset Text
17158
17159 \begin_layout Plain Layout
17160
17161 \family sans
17162 \series medium
17163 \shape up
17164 \size normal
17165 \emph off
17166 \bar no
17167 \noun off
17168 \color none
17169 Ding1
17170 \end_layout
17171
17172 \end_inset
17173 </cell>
17174 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17175 \begin_inset Text
17176
17177 \begin_layout Plain Layout
17178
17179 \family typewriter
17180 \series medium
17181 \shape up
17182 \size normal
17183 \emph off
17184 \bar no
17185 \noun off
17186 \color none
17187 pifont.sty
17188 \end_layout
17189
17190 \end_inset
17191 </cell>
17192 </row>
17193 <row>
17194 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17195 \begin_inset Text
17196
17197 \begin_layout Plain Layout
17198
17199 \family sans
17200 \series medium
17201 \shape up
17202 \size normal
17203 \emph off
17204 \bar no
17205 \noun off
17206 \color none
17207 Ding2
17208 \end_layout
17209
17210 \end_inset
17211 </cell>
17212 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17213 \begin_inset Text
17214
17215 \begin_layout Plain Layout
17216
17217 \family typewriter
17218 \series medium
17219 \shape up
17220 \size normal
17221 \emph off
17222 \bar no
17223 \noun off
17224 \color none
17225 pifont.sty
17226 \end_layout
17227
17228 \end_inset
17229 </cell>
17230 </row>
17231 <row>
17232 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17233 \begin_inset Text
17234
17235 \begin_layout Plain Layout
17236
17237 \family sans
17238 \series medium
17239 \shape up
17240 \size normal
17241 \emph off
17242 \bar no
17243 \noun off
17244 \color none
17245 Ding3
17246 \end_layout
17247
17248 \end_inset
17249 </cell>
17250 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17251 \begin_inset Text
17252
17253 \begin_layout Plain Layout
17254
17255 \family typewriter
17256 \series medium
17257 \shape up
17258 \size normal
17259 \emph off
17260 \bar no
17261 \noun off
17262 \color none
17263 pifont.sty
17264 \end_layout
17265
17266 \end_inset
17267 </cell>
17268 </row>
17269 <row>
17270 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
17271 \begin_inset Text
17272
17273 \begin_layout Plain Layout
17274
17275 \family sans
17276 \series medium
17277 \shape up
17278 \size normal
17279 \emph off
17280 \bar no
17281 \noun off
17282 \color none
17283 Ding4
17284 \end_layout
17285
17286 \end_inset
17287 </cell>
17288 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
17289 \begin_inset Text
17290
17291 \begin_layout Plain Layout
17292
17293 \family typewriter
17294 \series medium
17295 \shape up
17296 \size normal
17297 \emph off
17298 \bar no
17299 \noun off
17300 \color none
17301 pifont.sty
17302 \end_layout
17303
17304 \end_inset
17305 </cell>
17306 </row>
17307 </lyxtabular>
17308
17309 \end_inset
17310
17311
17312 \end_layout
17313
17314 \begin_layout Standard
17315 \SpecialChar LyX
17316  doesn't stop you using bullets from packages you don't have.
17317  If you get errors from \SpecialChar LaTeX
17318  when you try to view or print the file, then it
17319  is likely you are missing a package.
17320 \begin_inset Foot
17321 status collapsed
17322
17323 \begin_layout Plain Layout
17324 \SpecialChar LyX
17325  doesn't restrict your use since you may be editing locally and exporting
17326  elsewhere.
17327 \end_layout
17328
17329 \end_inset
17330
17331
17332 \end_layout
17333
17334 \begin_layout Subsection
17335 How to use it
17336 \end_layout
17337
17338 \begin_layout Standard
17339 Select which bullet depth you want to change then select the bullet shape
17340  and size.
17341  Any changes will not be visible in \SpecialChar LyX
17342 , but are visible when viewing the document.
17343 \end_layout
17344
17345 \begin_layout Standard
17346 You can reset a bullet shape to the default simply by clicking your right
17347  mouse button on the appropriate bullet depth button.
17348 \begin_inset Foot
17349 status collapsed
17350
17351 \begin_layout Plain Layout
17352 If you 
17353 \emph on
17354 really
17355 \emph default
17356  want to have multiple sets of paragraphs with different sets of bullets
17357  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
17358  code.
17359  The bullet selection dialog can help though because it provides you with
17360  the \SpecialChar LaTeX
17361  code for a wide range of bullet shapes.
17362  To make your own custom paragraphs you have the following options:
17363 \end_layout
17364
17365 \begin_layout Plain Layout
17366 \begin_inset ERT
17367 status open
17368
17369 \begin_layout Plain Layout
17370
17371
17372 \backslash
17373 let
17374 \backslash
17375 savelabelitemi=
17376 \backslash
17377 labelitemi
17378 \end_layout
17379
17380 \end_inset
17381
17382
17383 \end_layout
17384
17385 \begin_layout Plain Layout
17386 \begin_inset ERT
17387 status open
17388
17389 \begin_layout Plain Layout
17390
17391
17392 \backslash
17393 renewcommand
17394 \backslash
17395 labelitemi[0]{
17396 \backslash
17397 small
17398 \backslash
17399 (
17400 \backslash
17401 sharp
17402 \backslash
17403 )}
17404 \end_layout
17405
17406 \end_inset
17407
17408
17409 \end_layout
17410
17411 \begin_layout Itemize
17412 Use the \SpecialChar LaTeX
17413  command 
17414 \begin_inset Flex Code
17415 status collapsed
17416
17417 \begin_layout Plain Layout
17418
17419 \backslash
17420 renewcommand{}{}
17421 \end_layout
17422
17423 \end_inset
17424
17425  to specify a new bullet shape for a given depth.
17426  You'll also need to save the current bullet shape so you can restore it
17427  again afterwards.
17428  In this itemized list the following \SpecialChar LaTeX
17429  code was used to change the bullet
17430  used for the first depth.
17431 \begin_inset Separator latexpar
17432 \end_inset
17433
17434
17435 \end_layout
17436
17437 \begin_deeper
17438 \begin_layout LyX-Code
17439
17440 \backslash
17441 let
17442 \backslash
17443 savelabelitemi=
17444 \backslash
17445 labelitemi 
17446 \end_layout
17447
17448 \begin_layout LyX-Code
17449
17450 \backslash
17451 renewcommand
17452 \backslash
17453 labelitemi[0]{
17454 \backslash
17455 small
17456 \backslash
17457 (
17458 \backslash
17459 sharp
17460 \backslash
17461 )}
17462 \end_layout
17463
17464 \end_deeper
17465 \begin_layout Itemize
17466 Note that the itemize depth is specified in Roman numerals as part of the
17467  
17468 \family typewriter
17469
17470 \backslash
17471 labelitem
17472 \family default
17473  command.
17474 \end_layout
17475
17476 \begin_layout Itemize
17477 \begin_inset ERT
17478 status open
17479
17480 \begin_layout Plain Layout
17481
17482 [
17483 \backslash
17484 (
17485 \backslash
17486 star
17487 \backslash
17488 )]
17489 \end_layout
17490
17491 \end_inset
17492
17493  Specify each individual entry by starting each item with the bullet shape
17494  enclosed in square brackets and set as 
17495 \begin_inset Flex Noun
17496 status collapsed
17497
17498 \begin_layout Plain Layout
17499 \SpecialChar TeX
17500  Code
17501 \end_layout
17502
17503 \end_inset
17504
17505 .
17506  For example, this item was started with 
17507 \begin_inset Flex Code
17508 status collapsed
17509
17510 \begin_layout Plain Layout
17511 [
17512 \backslash
17513 (
17514 \backslash
17515 star
17516 \backslash
17517 )]
17518 \end_layout
17519
17520 \end_inset
17521
17522 .
17523 \end_layout
17524
17525 \begin_layout Plain Layout
17526 \begin_inset ERT
17527 status open
17528
17529 \begin_layout Plain Layout
17530
17531
17532 \backslash
17533 renewcommand
17534 \backslash
17535 labelitemi[0]{
17536 \backslash
17537 savelabelitemi}
17538 \end_layout
17539
17540 \end_inset
17541
17542
17543 \end_layout
17544
17545 \begin_layout Plain Layout
17546 You'll also need to revert the labelitem back to its previous setting for
17547  the global bullet shape settings to remain in effect.
17548  The way used here was:
17549 \end_layout
17550
17551 \begin_layout LyX-Code
17552
17553 \backslash
17554 renewcommand
17555 \backslash
17556 labelitemi[0]{
17557 \backslash
17558 savelabelitemi}
17559 \end_layout
17560
17561 \end_inset
17562
17563
17564 \end_layout
17565
17566 \begin_layout Chapter
17567 \SpecialChar LyX
17568  Features needing Extra Software
17569 \end_layout
17570
17571 \begin_layout Section
17572 Checking \SpecialChar TeX
17573
17574 \end_layout
17575
17576 \begin_layout Standard
17577 by 
17578 \noun on
17579 Asger Alstrup
17580 \end_layout
17581
17582 \begin_layout Subsection
17583 Introduction
17584 \end_layout
17585
17586 \begin_layout Standard
17587 If you have the 
17588 \family typewriter
17589 chktex
17590 \family default
17591  program installed
17592 \begin_inset Foot
17593 status collapsed
17594
17595 \begin_layout Plain Layout
17596
17597 \family typewriter
17598 chktex
17599 \family default
17600  is not yet available when you are using the \SpecialChar LaTeX
17601  distribution MiK\SpecialChar TeX
17602 .
17603 \end_layout
17604
17605 \end_inset
17606
17607 , you'll find in the 
17608 \family sans
17609 Tools
17610 \family default
17611  menu the entry: 
17612 \family sans
17613 Check
17614 \begin_inset space ~
17615 \end_inset
17616
17617 TeX
17618 \family default
17619 .
17620  You can get 
17621 \family typewriter
17622 chktex
17623 \family default
17624  from CTAN,
17625 \begin_inset Newline newline
17626 \end_inset
17627
17628
17629 \begin_inset CommandInset href
17630 LatexCommand href
17631 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
17632
17633 \end_inset
17634
17635 .
17636 \end_layout
17637
17638 \begin_layout Standard
17639 The 
17640 \family sans
17641 Chk\SpecialChar TeX
17642
17643 \family default
17644  package is a program that was written by 
17645 \begin_inset Flex Noun
17646 status collapsed
17647
17648 \begin_layout Plain Layout
17649 Jens T.
17650 \begin_inset space ~
17651 \end_inset
17652
17653 Berger Thielemann
17654 \end_layout
17655
17656 \end_inset
17657
17658  in frustration because some constructs in \SpecialChar LaTeX
17659  are sometimes non-intuitive,
17660  and easy to forget.
17661  The program runs over your \SpecialChar LaTeX
17662  file, checks the integrity of the file, and
17663  flags some common errors.
17664  In other technical words, it is 
17665 \family typewriter
17666 lint
17667 \family default
17668  for \SpecialChar LaTeX
17669 .
17670 \end_layout
17671
17672 \begin_layout Standard
17673 Well, what is a syntax checker doing in \SpecialChar LyX
17674  which is supposed to produce correct
17675  \SpecialChar LaTeX
17676  anyways? The answer is simple: Just as 
17677 \family typewriter
17678 Lint
17679 \family default
17680  not only checks the 
17681 \emph on
17682 syntax
17683 \emph default
17684  of C programs, but also does 
17685 \emph on
17686 semantic
17687 \emph default
17688  checks for type-errors, 
17689 \family sans
17690 Chk\SpecialChar TeX
17691
17692 \family default
17693  catches some common 
17694 \emph on
17695 typographic
17696 \emph default
17697  errors, in addition to the syntactical ones.
17698  Specifically, 
17699 \family sans
17700 Chk\SpecialChar TeX
17701
17702 \family default
17703  is capable of detecting several common errors, such as
17704 \end_layout
17705
17706 \begin_layout Itemize
17707 Ellipsis detection:
17708 \begin_inset Newline newline
17709 \end_inset
17710
17711 Use \SpecialChar ldots
17712  instead of ...
17713 \end_layout
17714
17715 \begin_layout Itemize
17716 No space in front of/after parenthesis:
17717 \begin_inset Newline newline
17718 \end_inset
17719
17720 ( wrong spacing )
17721 \end_layout
17722
17723 \begin_layout Itemize
17724 Enforcement of normal space after common abbreviations:
17725 \begin_inset Newline newline
17726 \end_inset
17727
17728 e.
17729 \begin_inset space \thinspace{}
17730 \end_inset
17731
17732 g.
17733 \begin_inset space \space{}
17734 \end_inset
17735
17736 is too wide spacing.
17737 \end_layout
17738
17739 \begin_layout Itemize
17740 Enforcement of end-of-sentence space when the last sentence ends with a
17741  capital letter:
17742 \begin_inset Newline newline
17743 \end_inset
17744
17745 This is a TEST.
17746  And this is wrong spacing.
17747 \end_layout
17748
17749 \begin_layout Itemize
17750 Space in front of labels and similar commands:
17751 \begin_inset Newline newline
17752 \end_inset
17753
17754 The label should stick right up to the text to avoid falling to a wrong
17755  page.
17756  
17757 \begin_inset CommandInset label
17758 LatexCommand label
17759 name "sec:chktex"
17760
17761 \end_inset
17762
17763  
17764 \begin_inset Foot
17765 status collapsed
17766
17767 \begin_layout Plain Layout
17768 This footnote is in danger of falling off to a wrong page
17769 \end_layout
17770
17771 \end_inset
17772
17773  The label is separated too much.
17774 \end_layout
17775
17776 \begin_layout Itemize
17777 Space in front of references, instead of hard spaces:
17778 \begin_inset Newline newline
17779 \end_inset
17780
17781 If you have bad luck, the text will break right between the referenced text
17782  and reference number, and that's a pity.
17783  See section 
17784 \begin_inset CommandInset ref
17785 LatexCommand ref
17786 reference "sec:chktex"
17787
17788 \end_inset
17789
17790 .
17791 \end_layout
17792
17793 \begin_layout Itemize
17794 Use of 
17795 \begin_inset Quotes eld
17796 \end_inset
17797
17798 x
17799 \begin_inset Quotes erd
17800 \end_inset
17801
17802  instead of 
17803 \begin_inset Formula $\times$
17804 \end_inset
17805
17806  between numbers:
17807 \begin_inset Newline newline
17808 \end_inset
17809
17810 2x2 looks cheap compared to 
17811 \begin_inset Formula $2\times2$
17812 \end_inset
17813
17814 .
17815 \end_layout
17816
17817 \begin_layout Standard
17818 and more \SpecialChar ldots
17819  It is an invaluable tool when you are 
17820 \begin_inset Quotes eld
17821 \end_inset
17822
17823 finishing up
17824 \begin_inset Quotes erd
17825 \end_inset
17826
17827  your document before printing, and you should run it right after the obligatory
17828  spelling check, and before you go fine tuning the typesetting.
17829 \end_layout
17830
17831 \begin_layout Subsection
17832 How to use it
17833 \end_layout
17834
17835 \begin_layout Standard
17836 If you have the program installed, usage is as simple as choosing 
17837 \family sans
17838 Tools\SpecialChar menuseparator
17839 Check
17840 \begin_inset space ~
17841 \end_inset
17842
17843 TeX
17844 \family default
17845 .
17846  This will make \SpecialChar LyX
17847  generate a \SpecialChar LaTeX
17848  file of your document, start 
17849 \family sans
17850 Chk\SpecialChar TeX
17851
17852 \family default
17853  to check it, and then make \SpecialChar LyX
17854  insert 
17855 \begin_inset Quotes eld
17856 \end_inset
17857
17858 error boxes
17859 \begin_inset Quotes erd
17860 \end_inset
17861
17862  with the warnings from 
17863 \family sans
17864 Chk\SpecialChar TeX
17865
17866 \family default
17867 , if there were any.
17868  The warnings will be placed close to the point of the mistake, and you
17869  can quickly find them by using the 
17870 \family sans
17871 Navigate\SpecialChar menuseparator
17872 Error
17873 \family default
17874  menu item, or the shortcut key 
17875 \family sans
17876 C-g
17877 \family default
17878  from the default 
17879 \family typewriter
17880 cua
17881 \family default
17882  bind file.
17883  Open the error boxes by clicking on them with the mouse, or use the shortcut
17884  key 
17885 \family sans
17886 C-i
17887 \family default
17888  from 
17889 \family typewriter
17890 cua
17891 \family default
17892  bindings, or the corresponding 
17893 \family sans
17894 C-o
17895 \family default
17896  for the alternate 
17897 \family typewriter
17898 emacs
17899 \family default
17900  bind file.
17901  Read the warning and correct the mistake, if it is a mistake.
17902  If you have trouble understanding what the warning is about, you can safely
17903  ignore it.
17904  Remember that there is a hidden layer between the document on screen and
17905  the technical details in invoking 
17906 \family sans
17907 Chk\SpecialChar TeX
17908
17909 \family default
17910 , and this gap can make some warnings seem arcane or just plain silly.
17911 \end_layout
17912
17913 \begin_layout Standard
17914 This document is an excellent testing bed for the feature, and it should
17915  provide quite a few warnings for you to fiddle with.
17916  Since computers are only so smart, expect most of the warnings to be false
17917  alarms, though.
17918 \end_layout
17919
17920 \begin_layout Subsection
17921 How to fine tune it
17922 \end_layout
17923
17924 \begin_layout Standard
17925 Sometimes, you'll find that 
17926 \family sans
17927 Chk\SpecialChar TeX
17928
17929 \family default
17930  makes more noise than suits your mood.
17931  Then you can choose not to use it, wait until your mood changes, or try
17932  to customize 
17933 \family sans
17934 Chk\SpecialChar TeX
17935
17936 \family default
17937  to get better along with you.
17938 \end_layout
17939
17940 \begin_layout Standard
17941 Although 
17942 \family sans
17943 Chk\SpecialChar TeX
17944
17945 \family default
17946  
17947 \emph on
17948 is
17949 \emph default
17950  very configurable and extensible, you should not expect to solve all problems
17951  with 
17952 \family sans
17953 Chk\SpecialChar TeX
17954
17955 \family default
17956  in \SpecialChar LyX
17957  this way.
17958  Since \SpecialChar LyX
17959  has to generate a somewhat special \SpecialChar LaTeX
17960  file to be able to match the
17961  line numbers from the 
17962 \family sans
17963 Chk\SpecialChar TeX
17964
17965 \family default
17966  output
17967 \begin_inset Foot
17968 status collapsed
17969
17970 \begin_layout Plain Layout
17971 You can inspect the specific output from 
17972 \family sans
17973 chktex
17974 \family default
17975  by using 
17976 \family sans
17977 Document\SpecialChar menuseparator
17978 \SpecialChar LaTeX
17979
17980 \begin_inset space ~
17981 \end_inset
17982
17983 Log
17984 \family default
17985  right after a 
17986 \family sans
17987 chktex
17988 \family default
17989  run.
17990 \end_layout
17991
17992 \end_inset
17993
17994  to the internal document structure, some of the warnings will not appear
17995  correctly.
17996  There are two things you can do about this:
17997 \end_layout
17998
17999 \begin_layout Itemize
18000 Fine tune the 
18001 \family sans
18002 Chk\SpecialChar TeX
18003
18004 \family default
18005  invocation command line in 
18006 \begin_inset Flex Noun
18007 status collapsed
18008
18009 \begin_layout Plain Layout
18010 Tools\SpecialChar menuseparator
18011 Preferences\SpecialChar menuseparator
18012 Output\SpecialChar menuseparator
18013 LaTeX\SpecialChar menuseparator
18014 CheckTeX command
18015 \end_layout
18016
18017 \end_inset
18018
18019 , or the global 
18020 \family sans
18021 Chk\SpecialChar TeX
18022
18023 \family default
18024  installation configuration file (usually with the file 
18025 \family typewriter
18026 chktexrc
18027 \family default
18028 ).
18029  See below to learn what warnings can be enabled and disabled on the command
18030  line.
18031 \end_layout
18032
18033 \begin_layout Itemize
18034 Export your document as a raw \SpecialChar LaTeX
18035  file using 
18036 \family sans
18037 File\SpecialChar menuseparator
18038 Export\SpecialChar menuseparator
18039 \SpecialChar LaTeX
18040
18041 \family default
18042  and run 
18043 \family typewriter
18044 chktex
18045 \family default
18046  manually on that.
18047  Invoked in this way, it can be a hassle to find the corresponding place
18048  in the document inside \SpecialChar LyX
18049 , but with a little patience, you should be able
18050  to do it.
18051 \end_layout
18052
18053 \begin_layout Standard
18054 Here follows the warning messages that can be enabled and disabled in 
18055 \family sans
18056 Preferences
18057 \family default
18058 .
18059  Use 
18060 \family typewriter
18061 -n#
18062 \family default
18063  to disable a warning, and 
18064 \family typewriter
18065 -w#
18066 \family default
18067  to enable a warning.
18068  The emphasized entries are disabled by default, because the default is
18069  "
18070 \family typewriter
18071 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
18072 \family default
18073 ".
18074 \end_layout
18075
18076 \begin_layout Standard
18077 Notice that you should only use the options that enable and disable warnings,
18078  because \SpecialChar LyX
18079  relies on some of the other command line parameters to be set
18080  in a specific way to have a chance to communicate with 
18081 \family typewriter
18082 chktex
18083 \family default
18084 .
18085 \end_layout
18086
18087 \begin_layout Enumerate
18088
18089 \size small
18090 \emph on
18091 Command terminated with space.
18092 \end_layout
18093
18094 \begin_layout Enumerate
18095
18096 \size small
18097 Non-breaking space (
18098 \begin_inset Quotes eld
18099 \end_inset
18100
18101
18102 \family typewriter
18103 ~
18104 \family default
18105
18106 \begin_inset Quotes erd
18107 \end_inset
18108
18109 ) should have been used.
18110 \end_layout
18111
18112 \begin_layout Enumerate
18113
18114 \size small
18115 \emph on
18116 You should enclose the previous parenthesis with 
18117 \begin_inset Quotes eld
18118 \end_inset
18119
18120
18121 \family typewriter
18122 {}
18123 \family default
18124
18125 \begin_inset Quotes erd
18126 \end_inset
18127
18128 .
18129 \end_layout
18130
18131 \begin_layout Enumerate
18132
18133 \size small
18134 Italic correction (
18135 \begin_inset Quotes eld
18136 \end_inset
18137
18138
18139 \family typewriter
18140
18141 \backslash
18142 /
18143 \family default
18144
18145 \begin_inset Quotes erd
18146 \end_inset
18147
18148 ) found in non-italic buffer.
18149 \end_layout
18150
18151 \begin_layout Enumerate
18152
18153 \size small
18154 Italic correction (
18155 \begin_inset Quotes eld
18156 \end_inset
18157
18158
18159 \family typewriter
18160
18161 \backslash
18162 /
18163 \family default
18164
18165 \begin_inset Quotes erd
18166 \end_inset
18167
18168 ) found more than once.
18169 \end_layout
18170
18171 \begin_layout Enumerate
18172
18173 \size small
18174 \emph on
18175 No italic correction (
18176 \begin_inset Quotes eld
18177 \end_inset
18178
18179
18180 \family typewriter
18181
18182 \backslash
18183 /
18184 \family default
18185
18186 \begin_inset Quotes erd
18187 \end_inset
18188
18189 ) found.
18190 \end_layout
18191
18192 \begin_layout Enumerate
18193
18194 \size small
18195 Accent command 
18196 \begin_inset Quotes eld
18197 \end_inset
18198
18199
18200 \family typewriter
18201 cmd
18202 \family default
18203
18204 \begin_inset Quotes erd
18205 \end_inset
18206
18207  needs use of 
18208 \begin_inset Quotes eld
18209 \end_inset
18210
18211
18212 \family typewriter
18213 cmd
18214 \family default
18215
18216 \begin_inset Quotes erd
18217 \end_inset
18218
18219 .
18220 \end_layout
18221
18222 \begin_layout Enumerate
18223
18224 \size small
18225 Wrong length of dash may have been used.
18226 \end_layout
18227
18228 \begin_layout Enumerate
18229
18230 \size small
18231 \emph on
18232 \begin_inset Quotes eld
18233 \end_inset
18234
18235
18236 \family typewriter
18237 %s
18238 \family default
18239
18240 \begin_inset Quotes erd
18241 \end_inset
18242
18243  expected, found 
18244 \begin_inset Quotes eld
18245 \end_inset
18246
18247
18248 \family typewriter
18249 %s
18250 \family default
18251
18252 \begin_inset Quotes erd
18253 \end_inset
18254
18255 .
18256 \end_layout
18257
18258 \begin_layout Enumerate
18259
18260 \size small
18261 Solo 
18262 \begin_inset Quotes eld
18263 \end_inset
18264
18265
18266 \family typewriter
18267 %s
18268 \family default
18269
18270 \begin_inset Quotes erd
18271 \end_inset
18272
18273  found.
18274 \end_layout
18275
18276 \begin_layout Enumerate
18277
18278 \size small
18279 You should use 
18280 \begin_inset Quotes eld
18281 \end_inset
18282
18283
18284 \family typewriter
18285 %s
18286 \family default
18287
18288 \begin_inset Quotes erd
18289 \end_inset
18290
18291  to achieve an ellipsis.
18292 \end_layout
18293
18294 \begin_layout Enumerate
18295
18296 \size small
18297 Inter-word spacing (
18298 \begin_inset Quotes eld
18299 \end_inset
18300
18301
18302 \family typewriter
18303
18304 \backslash
18305
18306 \family default
18307  
18308 \begin_inset Quotes eld
18309 \end_inset
18310
18311 ) should perhaps be used.
18312 \end_layout
18313
18314 \begin_layout Enumerate
18315
18316 \size small
18317 Inter-sentence spacing (
18318 \begin_inset Quotes eld
18319 \end_inset
18320
18321
18322 \family typewriter
18323
18324 \backslash
18325 @
18326 \family default
18327
18328 \begin_inset Quotes erd
18329 \end_inset
18330
18331 ) should perhaps be used.
18332 \end_layout
18333
18334 \begin_layout Enumerate
18335
18336 \size small
18337 Could not find argument for command.
18338 \end_layout
18339
18340 \begin_layout Enumerate
18341
18342 \size small
18343 No match found for 
18344 \begin_inset Quotes eld
18345 \end_inset
18346
18347
18348 \family typewriter
18349 %s
18350 \family default
18351
18352 \begin_inset Quotes erd
18353 \end_inset
18354
18355 .
18356 \end_layout
18357
18358 \begin_layout Enumerate
18359
18360 \size small
18361 Math mode still on at end of \SpecialChar LaTeX
18362  file.
18363 \end_layout
18364
18365 \begin_layout Enumerate
18366
18367 \size small
18368 Number of 
18369 \begin_inset Quotes eld
18370 \end_inset
18371
18372
18373 \family typewriter
18374 char
18375 \family default
18376
18377 \begin_inset Quotes erd
18378 \end_inset
18379
18380  doesn't match the number of 
18381 \begin_inset Quotes eld
18382 \end_inset
18383
18384
18385 \family typewriter
18386 char
18387 \family default
18388
18389 \begin_inset Quotes erd
18390 \end_inset
18391
18392 .
18393 \end_layout
18394
18395 \begin_layout Enumerate
18396
18397 \size small
18398 You should use either 
18399 \family typewriter
18400
18401 \begin_inset Quotes eld
18402 \end_inset
18403
18404
18405 \family default
18406  or 
18407 \family typewriter
18408
18409 \begin_inset Quotes erd
18410 \end_inset
18411
18412
18413 \family default
18414  as an alternative to 
18415 \begin_inset Quotes eld
18416 \end_inset
18417
18418
18419 \family typewriter
18420 "
18421 \family default
18422
18423 \begin_inset Quotes erd
18424 \end_inset
18425
18426 .
18427 \end_layout
18428
18429 \begin_layout Enumerate
18430
18431 \size small
18432 You should use "
18433 \family typewriter
18434 '
18435 \family default
18436 " (ASCII 39) instead of "
18437 \family typewriter
18438 ´
18439 \family default
18440 " (ASCII 180).
18441 \end_layout
18442
18443 \begin_layout Enumerate
18444
18445 \size small
18446 User-specified pattern found.
18447 \end_layout
18448
18449 \begin_layout Enumerate
18450
18451 \size small
18452 This command might not be intended.
18453 \end_layout
18454
18455 \begin_layout Enumerate
18456
18457 \size small
18458 \emph on
18459 Comment displayed.
18460 \end_layout
18461
18462 \begin_layout Enumerate
18463
18464 \size small
18465 Either 
18466 \family typewriter
18467 ''
18468 \backslash
18469 ,'
18470 \family default
18471  or 
18472 \family typewriter
18473 '
18474 \backslash
18475 ,''
18476 \family default
18477  will look better.
18478 \end_layout
18479
18480 \begin_layout Enumerate
18481
18482 \size small
18483 Delete this space to maintain correct page references.
18484 \end_layout
18485
18486 \begin_layout Enumerate
18487
18488 \size small
18489 \emph on
18490 You might wish to put this between a pair of 
18491 \begin_inset Quotes eld
18492 \end_inset
18493
18494
18495 \family typewriter
18496 {}
18497 \family default
18498
18499 \begin_inset Quotes erd
18500 \end_inset
18501
18502 .
18503 \end_layout
18504
18505 \begin_layout Enumerate
18506
18507 \size small
18508 You ought to remove spaces in front of punctuation.
18509 \end_layout
18510
18511 \begin_layout Enumerate
18512
18513 \size small
18514 Could not execute \SpecialChar LaTeX
18515  command.
18516 \end_layout
18517
18518 \begin_layout Enumerate
18519
18520 \size small
18521 Don't use 
18522 \family typewriter
18523
18524 \backslash
18525 /
18526 \family default
18527  in front of small punctuation.
18528 \end_layout
18529
18530 \begin_layout Enumerate
18531
18532 \family typewriter
18533 \size small
18534 $
18535 \backslash
18536 times$
18537 \family default
18538  may look prettier here.
18539 \end_layout
18540
18541 \begin_layout Enumerate
18542
18543 \size small
18544 \emph on
18545 Multiple spaces detected in output.
18546 \end_layout
18547
18548 \begin_layout Enumerate
18549
18550 \size small
18551 This text may be ignored.
18552 \end_layout
18553
18554 \begin_layout Enumerate
18555
18556 \size small
18557 Use 
18558 \family typewriter
18559
18560 \begin_inset Quotes eld
18561 \end_inset
18562
18563
18564 \family default
18565  to begin quotation, not 
18566 \family typewriter
18567 '
18568 \family default
18569 .
18570 \end_layout
18571
18572 \begin_layout Enumerate
18573
18574 \size small
18575 Use 
18576 \family typewriter
18577 '
18578 \family default
18579  to end quotation, not 
18580 \family typewriter
18581
18582 \begin_inset Quotes eld
18583 \end_inset
18584
18585
18586 \family default
18587 .
18588 \end_layout
18589
18590 \begin_layout Enumerate
18591
18592 \size small
18593 Don't mix quotes.
18594 \end_layout
18595
18596 \begin_layout Enumerate
18597
18598 \size small
18599 You should perhaps use 
18600 \begin_inset Quotes eld
18601 \end_inset
18602
18603
18604 \family typewriter
18605 cmd
18606 \family default
18607
18608 \begin_inset Quotes erd
18609 \end_inset
18610
18611  instead.
18612 \end_layout
18613
18614 \begin_layout Enumerate
18615
18616 \size small
18617 You should put a space in front of/after parenthesis.
18618 \end_layout
18619
18620 \begin_layout Enumerate
18621
18622 \size small
18623 You should avoid spaces in front of/after parenthesis.
18624 \end_layout
18625
18626 \begin_layout Enumerate
18627
18628 \size small
18629 \emph on
18630 You should not use punctuation in front of/after quotes.
18631 \end_layout
18632
18633 \begin_layout Enumerate
18634
18635 \size small
18636 Double space found.
18637 \end_layout
18638
18639 \begin_layout Enumerate
18640
18641 \size small
18642 You should put punctuation outside inner/inside display math mode.
18643 \end_layout
18644
18645 \begin_layout Enumerate
18646
18647 \size small
18648 You ought to not use primitive \SpecialChar TeX
18649  in \SpecialChar LaTeX
18650  code.
18651 \end_layout
18652
18653 \begin_layout Enumerate
18654
18655 \size small
18656 You should remove spaces in front of 
18657 \begin_inset Quotes eld
18658 \end_inset
18659
18660
18661 \family typewriter
18662 %s
18663 \family default
18664
18665 \begin_inset Quotes erd
18666 \end_inset
18667
18668
18669 \end_layout
18670
18671 \begin_layout Enumerate
18672
18673 \size small
18674 \begin_inset Quotes eld
18675 \end_inset
18676
18677
18678 \family typewriter
18679 %s
18680 \family default
18681
18682 \begin_inset Quotes erd
18683 \end_inset
18684
18685  is normally not followed by 
18686 \begin_inset Quotes eld
18687 \end_inset
18688
18689
18690 \family typewriter
18691 %c
18692 \family default
18693
18694 \begin_inset Quotes erd
18695 \end_inset
18696
18697 .
18698 \end_layout
18699
18700 \begin_layout Standard
18701 In later versions of \SpecialChar LyX
18702 , we hope to provide a more complete interface to this
18703  tool (and it's smaller cousin 
18704 \family typewriter
18705 lacheck
18706 \family default
18707 ) to exploit the full power of it.
18708  But it's not exactly useless as it is now: go try it on one of your existing
18709  documents of a certain length and be surprised.
18710 \end_layout
18711
18712 \begin_layout Section
18713 Version Control in \SpecialChar LyX
18714
18715 \end_layout
18716
18717 \begin_layout Standard
18718 by
18719 \noun on
18720  Lars Gullik Bjønnes 
18721 \noun default
18722 and 
18723 \noun on
18724 Pavel Sanda
18725 \end_layout
18726
18727 \begin_layout Subsection
18728 Introduction
18729 \end_layout
18730
18731 \begin_layout Standard
18732 \SpecialChar LyX
18733  supports some of the most basic RCS/CVS/SVN/GIT commands.
18734  If you need something a bit more sophisticated you will have to do that
18735  manually in a terminal.
18736 \end_layout
18737
18738 \begin_layout Standard
18739 Also note that CVS support is not as good as subversion support so we advise
18740  using SVN instead.
18741  A good place to start learning Subversion is SVN Book
18742 \begin_inset Foot
18743 status collapsed
18744
18745 \begin_layout Plain Layout
18746 \begin_inset CommandInset href
18747 LatexCommand href
18748 target "http://svnbook.red-bean.com/"
18749
18750 \end_inset
18751
18752
18753 \end_layout
18754
18755 \end_inset
18756
18757 .
18758  In the case of RCS you should read 
18759 \begin_inset Quotes eld
18760 \end_inset
18761
18762 rcsintro
18763 \begin_inset Quotes erd
18764 \end_inset
18765
18766  (a man file, read it with 
18767 \family typewriter
18768 man rcsintro
18769 \family default
18770 ).
18771  This file describes all the basic features of RCS.
18772  You should especially notice the comment about a RCS directory, and the
18773  notion of a master RCS file (the file ending in 
18774 \family typewriter
18775 ,v
18776 \family default
18777 ).
18778 \end_layout
18779
18780 \begin_layout Standard
18781 Before you begin to use the version control features in \SpecialChar LyX
18782 , you should be
18783  familiar with RCS/CVS/SVN/GIT usage.
18784  The implementation in \SpecialChar LyX
18785  assumes a recent version of the GNU RCS or CVS/SVN
18786  package — no guarantees are made for older versions.
18787  Most of the log messages are not currently displayed after operations —
18788  you can check them in the Messages pane if unsure.
18789  Regular users of version control will appreciate VC toolbar, which can
18790  be enabled via 
18791 \family sans
18792 View\SpecialChar menuseparator
18793 Toolbars\SpecialChar menuseparator
18794 Version
18795 \begin_inset space ~
18796 \end_inset
18797
18798 Control
18799 \family default
18800 .
18801 \end_layout
18802
18803 \begin_layout Standard
18804 For introducing your own external commands consult vc-command in the manual
18805  of \SpecialChar LyX
18806  functions.
18807 \end_layout
18808
18809 \begin_layout Standard
18810 It is strongly recommended to store documents in uncompressed format if
18811  using version control (uncheck 
18812 \family sans
18813 Document\SpecialChar menuseparator
18814 Compressed
18815 \family default
18816  if it is checked): Uncompressed LyX documents are text files and therefore
18817  for merging two different versions by version control systems.
18818  Compressed LyX documents are binary files, which cannot be merged by version
18819  control systems.
18820 \end_layout
18821
18822 \begin_layout Subsection
18823 RCS commands in \SpecialChar LyX
18824
18825 \end_layout
18826
18827 \begin_layout Standard
18828 The following sections describe the RCS commands supported by \SpecialChar LyX
18829 .
18830  You can find them in the 
18831 \family sans
18832 File\SpecialChar menuseparator
18833 Version
18834 \begin_inset space ~
18835 \end_inset
18836
18837 Control
18838 \family default
18839  submenu.
18840  \SpecialChar LyX
18841  was tested against RCS 5.7/5.8.
18842 \end_layout
18843
18844 \begin_layout Subsubsection
18845
18846 \family sans
18847 Register
18848 \end_layout
18849
18850 \begin_layout Standard
18851 If your document is not under revision control, this is the only item shown
18852  in the menu.
18853  And if it is under revision control, the 
18854 \family sans
18855 Register
18856 \family default
18857  item is not visible.
18858  
18859 \end_layout
18860
18861 \begin_layout Standard
18862 This command registers your document with RCS (unless you are under the
18863  directory managed by CVS)\SpecialChar endofsentence
18864  You are asked interactively to supply an initial
18865  description of the document.
18866  The document is now set in Read-Only mode and you have to 
18867 \family sans
18868 Check
18869 \begin_inset space ~
18870 \end_inset
18871
18872 Out
18873 \begin_inset space ~
18874 \end_inset
18875
18876 For
18877 \begin_inset space ~
18878 \end_inset
18879
18880 Edit
18881 \family default
18882 , before making any changes to it.
18883  A document under revision control has a 
18884 \begin_inset Quotes eld
18885 \end_inset
18886
18887 [RCS:<version> <locker>]
18888 \begin_inset Quotes erd
18889 \end_inset
18890
18891  item tagged to the filename in the minibuffer.
18892 \end_layout
18893
18894 \begin_layout Standard
18895 RCS command that is run: 
18896 \family typewriter
18897 ci -q -u -i -t-"<initial description>" <file-name>
18898 \end_layout
18899
18900 \begin_layout Standard
18901 Read 
18902 \family typewriter
18903 man ci
18904 \family default
18905  to understand the switches.
18906  
18907 \end_layout
18908
18909 \begin_layout Subsubsection
18910
18911 \family sans
18912 Check In Changes
18913 \end_layout
18914
18915 \begin_layout Standard
18916 When you are finished editing a file, you check in your changes.
18917  When you do this, you are asked for a description of the changes.
18918  This is stored in the history log.
18919  The version number is bumped, your changes are applied to the master RCS
18920  file, the document is unlocked and set to Read-Only mode.
18921 \end_layout
18922
18923 \begin_layout Standard
18924 RCS command: 
18925 \family typewriter
18926 ci -q -u -m"<description>" <file-name>
18927 \end_layout
18928
18929 \begin_layout Subsubsection
18930
18931 \family sans
18932 Check Out For Edit
18933 \end_layout
18934
18935 \begin_layout Standard
18936 By doing this you lock the document so that only you can edit it.
18937  This will also make the document Read-Write only for you.
18938  You will usually continue editing for a while and when you are finished
18939  you check in your changes.
18940  The status line is changed to reflect that you have locked the file.
18941 \end_layout
18942
18943 \begin_layout Standard
18944 RCS command: 
18945 \family typewriter
18946 co -q -l <file-name>
18947 \end_layout
18948
18949 \begin_layout Subsubsection
18950
18951 \family sans
18952 Revert To Repository Version
18953 \end_layout
18954
18955 \begin_layout Standard
18956 This will discard all changes made to the document since the last check
18957  in.
18958  You get a warning before changes are discarded.
18959 \end_layout
18960
18961 \begin_layout Standard
18962 RCS command: 
18963 \family typewriter
18964 co -f -u<version> <file-name>
18965 \end_layout
18966
18967 \begin_layout Subsubsection
18968
18969 \family sans
18970 Copy
18971 \end_layout
18972
18973 \begin_layout Standard
18974 This will create a copy of the current document.
18975  Since RCS does not support copy operations natively, the version history
18976  is not preserved, and the copy is added as a new file.
18977  It requires a clean document without any changes since the last checkin.
18978  You are asked for a file name and a description of the copy operation.
18979  After that the copy is created, both locally and in the repository.
18980  If the parent directories of the copied and original document differ, all
18981  relative paths of included files of the copy are adjusted (like in 
18982 \family sans
18983 File\SpecialChar menuseparator
18984 Save As
18985 \family default
18986 \SpecialChar ldots
18987 ).
18988  Finally, the copy is loaded instead of the original document.
18989 \end_layout
18990
18991 \begin_layout Labeling
18992 \labelwidthstring 00.00.0000
18993 RCS
18994 \begin_inset space ~
18995 \end_inset
18996
18997 commands: 
18998 \begin_inset space ~
18999 \end_inset
19000
19001
19002 \begin_inset Newline newline
19003 \end_inset
19004
19005 Copy 
19006 \begin_inset Flex Code
19007 status collapsed
19008
19009 \begin_layout Plain Layout
19010
19011 \family typewriter
19012 \begin_inset Quotes eld
19013 \end_inset
19014
19015 <file-name>
19016 \begin_inset Quotes erd
19017 \end_inset
19018
19019
19020 \end_layout
19021
19022 \end_inset
19023
19024  to 
19025 \begin_inset Flex Code
19026 status collapsed
19027
19028 \begin_layout Plain Layout
19029
19030 \family typewriter
19031 \begin_inset Quotes eld
19032 \end_inset
19033
19034 <new-file-name>
19035 \begin_inset Quotes erd
19036 \end_inset
19037
19038
19039 \end_layout
19040
19041 \end_inset
19042
19043
19044 \begin_inset Newline newline
19045 \end_inset
19046
19047
19048 \begin_inset Flex Code
19049 status collapsed
19050
19051 \begin_layout Plain Layout
19052 ci -q -u 
19053 \family typewriter
19054 -i 
19055 \begin_inset Quotes eld
19056 \end_inset
19057
19058 <new-file-name>
19059 \begin_inset Quotes erd
19060 \end_inset
19061
19062
19063 \end_layout
19064
19065 \end_inset
19066
19067
19068 \end_layout
19069
19070 \begin_layout Subsubsection
19071
19072 \family sans
19073 Undo Last Checkin
19074 \end_layout
19075
19076 \begin_layout Standard
19077 This makes as if the last check in never happened.
19078  No changes are made to the document loaded into \SpecialChar LyX
19079 , but the last version
19080  is removed from the master RCS file.
19081 \end_layout
19082
19083 \begin_layout Standard
19084 RCS command: 
19085 \family typewriter
19086 rcs -o<version> <file-name>
19087 \end_layout
19088
19089 \begin_layout Subsubsection
19090
19091 \family sans
19092 Show History
19093 \end_layout
19094
19095 \begin_layout Standard
19096 This shows the complete history of the RCS document.
19097  The output of 
19098 \family typewriter
19099 rlog <file-name>
19100 \family default
19101  is shown in a browser.
19102  See 
19103 \family typewriter
19104 man rlog
19105 \family default
19106  for more info.
19107 \end_layout
19108
19109 \begin_layout Subsubsection
19110 Revision info
19111 \end_layout
19112
19113 \begin_layout Standard
19114 \SpecialChar LyX
19115  supports RCS version number, author name, date and time of last commit.
19116  All those are extracted from 
19117 \family typewriter
19118 rlog -r <file-name>
19119 \family default
19120 .
19121  See 
19122 \begin_inset CommandInset ref
19123 LatexCommand ref
19124 reference "subsec:VCS-Revision-Information"
19125
19126 \end_inset
19127
19128  for details.
19129 \end_layout
19130
19131 \begin_layout Subsection
19132 CVS commands in \SpecialChar LyX
19133
19134 \end_layout
19135
19136 \begin_layout Standard
19137 A subset of CVS operations is supported by \SpecialChar LyX
19138 .
19139  You can find the commands in the 
19140 \family sans
19141 File\SpecialChar menuseparator
19142 Version
19143 \begin_inset space ~
19144 \end_inset
19145
19146 Control
19147 \family default
19148  submenu.
19149  The version control system SVN is more powerful, so please use it instead
19150  of CVS if possible.
19151 \end_layout
19152
19153 \begin_layout Subsubsection
19154
19155 \family sans
19156 General CVS usage
19157 \end_layout
19158
19159 \begin_layout Standard
19160 If you start from scratch with CVS you have to create your repository and
19161  checkout the working copy with external tools.
19162  If you're using a client-server setup you may need to login before doing
19163  the first repository checkout.
19164 \end_layout
19165
19166 \begin_layout Standard
19167 If your documents are under revision control and others are using the same
19168  repository problems arise when different changes to the same document at
19169  the same location happen.
19170  Standard CVS repositories don't operate with a file locking mechanism.
19171  This may be surprising, but conflicts only occur if people disagree on
19172  the proper content of the same part of a document.
19173  So, if co-workers are used to communicate regularly, these conflicts occur
19174  rarely.
19175  If they don't communicate they have a fundamental problem anyway.
19176  Nevertheless some people like to work with so called 
19177 \begin_inset Quotes eld
19178 \end_inset
19179
19180 reserved checkouts
19181 \begin_inset Quotes erd
19182 \end_inset
19183
19184 .
19185  If they do so the working copy of all files is readonly when checked out
19186  first and the user starts editing after using a special command to make
19187  the working copy writable.
19188  When the changes are checked in the working copy returns to readonly state.
19189  With \SpecialChar LyX
19190  one has to edit the 
19191 \begin_inset Flex Code
19192 status collapsed
19193
19194 \begin_layout Plain Layout
19195 .cvsrc
19196 \end_layout
19197
19198 \end_inset
19199
19200  file and add the line 
19201 \begin_inset Flex Code
19202 status collapsed
19203
19204 \begin_layout Plain Layout
19205 cvs -r
19206 \end_layout
19207
19208 \end_inset
19209
19210  to work with reserved checkouts.
19211  The benefit is the possibility to see who is using a writable copy of some
19212  document.
19213  It's not guaranteed only one user makes a copy writable.
19214 \end_layout
19215
19216 \begin_layout Standard
19217 \SpecialChar LyX
19218  tries to guess if you're using reserved or non-reserved checkouts.
19219  If your working copy is readonly or it is writable and an additional copy
19220  of your document exists in the CVS/Base sub-directory a reserved otherwise
19221  a non-reserved checkout is assumed.
19222  When a reserved checkout is detected you have to use 
19223 \begin_inset Flex Noun
19224 status collapsed
19225
19226 \begin_layout Plain Layout
19227 Check Out
19228 \end_layout
19229
19230 \end_inset
19231
19232  to make your working copy writable if it's readonly.
19233  After doing so the 
19234 \begin_inset Flex Noun
19235 status collapsed
19236
19237 \begin_layout Plain Layout
19238 Check In
19239 \end_layout
19240
19241 \end_inset
19242
19243  operation is possible and that makes your working copy readonly again after
19244  transferring your changes to the repository.
19245 \end_layout
19246
19247 \begin_layout Standard
19248 More information about CVS can be found here 
19249 \begin_inset Flex URL
19250 status collapsed
19251
19252 \begin_layout Plain Layout
19253
19254 http://www.nongnu.org/cvs
19255 \end_layout
19256
19257 \end_inset
19258
19259  and here 
19260 \begin_inset Flex URL
19261 status collapsed
19262
19263 \begin_layout Plain Layout
19264
19265 http://ximbiot.com/cvs
19266 \end_layout
19267
19268 \end_inset
19269
19270 .
19271 \end_layout
19272
19273 \begin_layout Standard
19274 Read 
19275 \family typewriter
19276 man cvs
19277 \family default
19278  to understand the sub-commands and the switches mentioned below.
19279 \end_layout
19280
19281 \begin_layout Subsubsection
19282
19283 \family sans
19284 Register
19285 \end_layout
19286
19287 \begin_layout Standard
19288 If your document is not under revision control, this is the only item shown
19289  in the menu.
19290  And if it is under revision control, the 
19291 \family sans
19292 Register
19293 \family default
19294  item is not visible.
19295  
19296 \end_layout
19297
19298 \begin_layout Standard
19299 This command registers in CVS your document 
19300 \begin_inset Flex Strong
19301 status collapsed
19302
19303 \begin_layout Plain Layout
19304
19305 \emph on
19306 only
19307 \end_layout
19308
19309 \end_inset
19310
19311  in the case you have already the documents directory under CVS control
19312  (in particular 
19313 \family typewriter
19314 CVS/Entries
19315 \family default
19316  file exists).
19317  This means you have to create or checkout the archive by yourself using
19318  external tools.
19319  (In case you forget that step \SpecialChar LyX
19320  registers the document with RCS.)
19321 \end_layout
19322
19323 \begin_layout Standard
19324 Then you are asked interactively to supply an initial description of the
19325  document.
19326  Don't forget that registered file is not yet checked in.
19327 \end_layout
19328
19329 \begin_layout Standard
19330 CVS command that is run: 
19331 \family typewriter
19332 cvs -q add -m"<entered message>" "<file-name>"
19333 \end_layout
19334
19335 \begin_layout Standard
19336 The term 
19337 \family typewriter
19338 "<file-name>"
19339 \family default
19340  above and for all other CVS commands is an abbreviation for 
19341 \begin_inset Quotes eld
19342 \end_inset
19343
19344 change the current working directory to file location and use the file name
19345  without path component as argument
19346 \begin_inset Quotes erd
19347 \end_inset
19348
19349 .
19350 \end_layout
19351
19352 \begin_layout Subsubsection
19353
19354 \family sans
19355 Check In Changes
19356 \end_layout
19357
19358 \begin_layout Standard
19359 When you are finished editing a file, you commit your changes.
19360  When you do this and you had changed the document, you are asked for a
19361  description of the changes.
19362  After that changes are written to the repository.
19363  In case you didn't change the document and a reserved checkout is detected
19364  the reservation made on 
19365 \begin_inset Flex Noun
19366 status collapsed
19367
19368 \begin_layout Plain Layout
19369 Check Out
19370 \end_layout
19371
19372 \end_inset
19373
19374  is undone.
19375 \end_layout
19376
19377 \begin_layout Labeling
19378 \labelwidthstring 00.00.0000
19379 CVS
19380 \begin_inset space ~
19381 \end_inset
19382
19383 command: 
19384 \begin_inset space ~
19385 \end_inset
19386
19387
19388 \begin_inset Newline newline
19389 \end_inset
19390
19391
19392 \begin_inset Flex Code
19393 status collapsed
19394
19395 \begin_layout Plain Layout
19396 cvs 
19397 \family typewriter
19398 -q commit -m"<description>" "<file-name>"
19399 \end_layout
19400
19401 \end_inset
19402
19403  or
19404 \begin_inset Newline newline
19405 \end_inset
19406
19407
19408 \begin_inset Flex Code
19409 status collapsed
19410
19411 \begin_layout Plain Layout
19412 cvs -q unedit 
19413 \family typewriter
19414 "<file-name>"
19415 \end_layout
19416
19417 \end_inset
19418
19419
19420 \end_layout
19421
19422 \begin_layout Subsubsection
19423
19424 \family sans
19425 Check Out Changes
19426 \end_layout
19427
19428 \begin_layout Standard
19429 When you are sharing a repository with others, you may have to incorporate
19430  their changes into your working copy.
19431 \end_layout
19432
19433 \begin_layout Standard
19434 CVS command: 
19435 \family typewriter
19436 cvs -q update "<file-name>"
19437 \end_layout
19438
19439 \begin_layout Standard
19440 If a readonly checkout is detected the working copy is made writable and
19441  reserved.
19442 \end_layout
19443
19444 \begin_layout Standard
19445 CVS command: 
19446 \family typewriter
19447 cvs -q edit "<file-name>"
19448 \end_layout
19449
19450 \begin_layout Subsubsection
19451
19452 \family sans
19453 Revert To Repository Version
19454 \end_layout
19455
19456 \begin_layout Standard
19457 This will discard all changes made to the document since the last check
19458  in.
19459  You get a warning before changes are discarded.
19460  Firstly the file is deleted, secondly CVS update command is run.
19461 \end_layout
19462
19463 \begin_layout Standard
19464 CVS command: 
19465 \family typewriter
19466 cvs -q update "<file-name>"
19467 \end_layout
19468
19469 \begin_layout Standard
19470 If a reserved checkout is detected and the working copy has no changes only
19471  the reservation is undone.
19472 \end_layout
19473
19474 \begin_layout Standard
19475 CVS command: 
19476 \family typewriter
19477 cvs -q unedit "<file-name>"
19478 \end_layout
19479
19480 \begin_layout Subsubsection
19481
19482 \family sans
19483 Copy
19484 \end_layout
19485
19486 \begin_layout Standard
19487 This will create a copy of the current document.
19488  Since CVS does not support copy operations natively, the version history
19489  is not preserved, and the copy is added as a new file.
19490  It requires a clean document without any changes since the last checkin.
19491  You are asked for a file name and a description of the copy operation.
19492  After that the copy is created, both locally and in the repository.
19493  If the parent directories of the copied and original document differ, all
19494  relative paths of included files of the copy are adjusted (like in 
19495 \family sans
19496 File\SpecialChar menuseparator
19497 Save As
19498 \family default
19499 \SpecialChar ldots
19500 ).
19501  Finally, the copy is loaded instead of the original document.
19502 \end_layout
19503
19504 \begin_layout Labeling
19505 \labelwidthstring 00.00.0000
19506 CVS
19507 \begin_inset space ~
19508 \end_inset
19509
19510 commands: 
19511 \begin_inset space ~
19512 \end_inset
19513
19514
19515 \begin_inset Newline newline
19516 \end_inset
19517
19518 Copy 
19519 \begin_inset Flex Code
19520 status collapsed
19521
19522 \begin_layout Plain Layout
19523
19524 \family typewriter
19525 \begin_inset Quotes eld
19526 \end_inset
19527
19528 <file-name>
19529 \begin_inset Quotes erd
19530 \end_inset
19531
19532
19533 \end_layout
19534
19535 \end_inset
19536
19537  to 
19538 \begin_inset Flex Code
19539 status collapsed
19540
19541 \begin_layout Plain Layout
19542
19543 \family typewriter
19544 \begin_inset Quotes eld
19545 \end_inset
19546
19547 <new-file-name>
19548 \begin_inset Quotes erd
19549 \end_inset
19550
19551
19552 \end_layout
19553
19554 \end_inset
19555
19556
19557 \begin_inset Newline newline
19558 \end_inset
19559
19560
19561 \begin_inset Flex Code
19562 status collapsed
19563
19564 \begin_layout Plain Layout
19565 cvs -q add 
19566 \family typewriter
19567
19568 \begin_inset Quotes eld
19569 \end_inset
19570
19571 <new-file-name>
19572 \begin_inset Quotes erd
19573 \end_inset
19574
19575
19576 \end_layout
19577
19578 \end_inset
19579
19580
19581 \end_layout
19582
19583 \begin_layout Subsubsection
19584
19585 \family sans
19586 Rename
19587 \end_layout
19588
19589 \begin_layout Standard
19590 This will rename the current document.
19591  Since CVS does not support rename operations natively, the version history
19592  is not preserved, the renamed document is added as a new file, and the
19593  original document is deleted.
19594  It requires a clean document without any changes since the last checkin.
19595  You are asked for a file name and a description of the rename operation.
19596  After that the document is renamed, both locally and in the repository.
19597  If the parent directories of the new and old file names differ, all relative
19598  paths of included files are adjusted (like in 
19599 \family sans
19600 File\SpecialChar menuseparator
19601 Save As
19602 \family default
19603 \SpecialChar ldots
19604 ).
19605  Finally, the document is reloaded using the new name.
19606 \end_layout
19607
19608 \begin_layout Labeling
19609 \labelwidthstring 00.00.0000
19610 CVS
19611 \begin_inset space ~
19612 \end_inset
19613
19614 commands: 
19615 \begin_inset space ~
19616 \end_inset
19617
19618
19619 \begin_inset Newline newline
19620 \end_inset
19621
19622 Rename 
19623 \begin_inset Flex Code
19624 status collapsed
19625
19626 \begin_layout Plain Layout
19627
19628 \family typewriter
19629 \begin_inset Quotes eld
19630 \end_inset
19631
19632 <file-name>
19633 \begin_inset Quotes erd
19634 \end_inset
19635
19636
19637 \end_layout
19638
19639 \end_inset
19640
19641  to 
19642 \begin_inset Flex Code
19643 status collapsed
19644
19645 \begin_layout Plain Layout
19646
19647 \family typewriter
19648 \begin_inset Quotes eld
19649 \end_inset
19650
19651 <new-file-name>
19652 \begin_inset Quotes erd
19653 \end_inset
19654
19655
19656 \end_layout
19657
19658 \end_inset
19659
19660
19661 \begin_inset Newline newline
19662 \end_inset
19663
19664
19665 \begin_inset Flex Code
19666 status collapsed
19667
19668 \begin_layout Plain Layout
19669 cvs -q add 
19670 \family typewriter
19671
19672 \begin_inset Quotes eld
19673 \end_inset
19674
19675 <new-file-name>
19676 \begin_inset Quotes erd
19677 \end_inset
19678
19679
19680 \end_layout
19681
19682 \end_inset
19683
19684
19685 \begin_inset Newline newline
19686 \end_inset
19687
19688
19689 \begin_inset Flex Code
19690 status collapsed
19691
19692 \begin_layout Plain Layout
19693 cvs -q remove 
19694 \family typewriter
19695
19696 \begin_inset Quotes eld
19697 \end_inset
19698
19699 <file-name>
19700 \begin_inset Quotes erd
19701 \end_inset
19702
19703
19704 \end_layout
19705
19706 \end_inset
19707
19708
19709 \end_layout
19710
19711 \begin_layout Subsubsection
19712 Update of the local directory checkout from repository
19713 \end_layout
19714
19715 \begin_layout Standard
19716 Once your documents gets more complex, containing sub-documents and pictures,
19717  including external 
19718 \begin_inset Flex Code
19719 status collapsed
19720
19721 \begin_layout Plain Layout
19722 .tex
19723 \end_layout
19724
19725 \end_inset
19726
19727  files and so on using version control becomes more complicated.
19728  \SpecialChar LyX
19729  supports updating the whole tree in which resides the document.
19730  This become especially useful once you cooperate with people which neither
19731  have detailed knowledge about CVS usage nor they have ambition to commit
19732  additional material to the repository.
19733  You have to organize the files structure so that all external files are
19734  in the same directory or subdirectories of the document.
19735  It's good practice anyway to store multipart documents in an extra directory.
19736 \end_layout
19737
19738 \begin_layout Standard
19739 The 
19740 \begin_inset Flex Code
19741 status collapsed
19742
19743 \begin_layout Plain Layout
19744 Update local directory from repository
19745 \end_layout
19746
19747 \end_inset
19748
19749  command updates the whole directory.
19750  If local changes are detected user is warned before update starts.
19751  In case of merge conflicts both versions of the conflicting document parts
19752  are placed in the final document.
19753  You have to review and correct the result of the merge.
19754  You'll find the conflicts enclosed in pairs of 
19755 \begin_inset Flex Code
19756 status collapsed
19757
19758 \begin_layout Plain Layout
19759 <<<<<<<
19760 \end_layout
19761
19762 \end_inset
19763
19764  and 
19765 \begin_inset Flex Code
19766 status collapsed
19767
19768 \begin_layout Plain Layout
19769 >>>>>>>
19770 \end_layout
19771
19772 \end_inset
19773
19774  separated by 
19775 \begin_inset Flex Code
19776 status collapsed
19777
19778 \begin_layout Plain Layout
19779 =======
19780 \end_layout
19781
19782 \end_inset
19783
19784 .
19785  The first part is your version as before the update operation with the
19786  document name prepended.
19787  The second one is the repository version with the version number after
19788  the sequence of 
19789 \begin_inset Flex Code
19790 status collapsed
19791
19792 \begin_layout Plain Layout
19793 >
19794 \end_layout
19795
19796 \end_inset
19797
19798  signs.
19799 \end_layout
19800
19801 \begin_layout Labeling
19802 \labelwidthstring 00.00.0000
19803 CVS
19804 \begin_inset space ~
19805 \end_inset
19806
19807 commands: 
19808 \begin_inset space ~
19809 \end_inset
19810
19811
19812 \begin_inset Newline newline
19813 \end_inset
19814
19815
19816 \begin_inset Flex Code
19817 status collapsed
19818
19819 \begin_layout Plain Layout
19820 cd $path; cvs diff 
19821 \family typewriter
19822 "."
19823 \end_layout
19824
19825 \end_inset
19826
19827  (Ask if changes are detected.)
19828 \begin_inset Newline newline
19829 \end_inset
19830
19831
19832 \begin_inset Flex Code
19833 status collapsed
19834
19835 \begin_layout Plain Layout
19836 cd $path; cvs -q update 
19837 \family typewriter
19838 "."
19839 \end_layout
19840
19841 \end_inset
19842
19843
19844 \end_layout
19845
19846 \begin_layout Standard
19847 where 
19848 \begin_inset Flex Code
19849 status collapsed
19850
19851 \begin_layout Plain Layout
19852 $path
19853 \end_layout
19854
19855 \end_inset
19856
19857  stands for the path to the document.
19858 \end_layout
19859
19860 \begin_layout Subsubsection
19861
19862 \family sans
19863 Show History
19864 \end_layout
19865
19866 \begin_layout Standard
19867 This shows the complete history of the CVS document.
19868  The output of 
19869 \family typewriter
19870 cvs log "<file-name>"
19871 \family default
19872  is shown in a browser.
19873 \end_layout
19874
19875 \begin_layout Subsubsection
19876 Revision info
19877 \end_layout
19878
19879 \begin_layout Standard
19880 \SpecialChar LyX
19881  supports CVS version number, author name, date and time of last commit.
19882  All those are extracted from 
19883 \family typewriter
19884 cvs log -r <file-name>
19885 \family default
19886 .
19887  See 
19888 \begin_inset CommandInset ref
19889 LatexCommand ref
19890 reference "subsec:VCS-Revision-Information"
19891
19892 \end_inset
19893
19894  for details.
19895 \end_layout
19896
19897 \begin_layout Subsection
19898 SVN commands in \SpecialChar LyX
19899
19900 \end_layout
19901
19902 \begin_layout Standard
19903 SVN is now partially supported by \SpecialChar LyX
19904 .
19905  You can find the commands in the 
19906 \family sans
19907 File\SpecialChar menuseparator
19908 Version
19909 \begin_inset space ~
19910 \end_inset
19911
19912 Control
19913 \family default
19914  submenu.
19915  Please note that if you use password protected access to repository via
19916  ssh, you will be asked in terminal window.
19917  \SpecialChar LyX
19918  was tested against SVN 1.5, 1.6, 1.7 and 1.8
19919 \begin_inset Foot
19920 status open
19921
19922 \begin_layout Plain Layout
19923 Most of the commands will work with 1.4 too, see 
19924 \begin_inset CommandInset ref
19925 LatexCommand ref
19926 reference "subsec:SVN-Repo-Update"
19927
19928 \end_inset
19929
19930 .
19931  There seems to be currently unresolved permissions problem under SVN 1.8
19932  with reverting changes when file is locked.
19933 \end_layout
19934
19935 \end_inset
19936
19937
19938 \end_layout
19939
19940 \begin_layout Subsubsection
19941
19942 \family sans
19943 Register
19944 \end_layout
19945
19946 \begin_layout Standard
19947 If your document is not under revision control, this is the only item shown
19948  in the menu.
19949  And if it is under revision control, the 
19950 \family sans
19951 Register
19952 \family default
19953  item is not visible.
19954 \end_layout
19955
19956 \begin_layout Standard
19957 This command registers in SVN your document ONLY in case you have already
19958  the documents directory under SVN control (in particular 
19959 \family typewriter
19960 .svn/entries
19961 \family default
19962  file exists).
19963  This means you have to checkout the archive by yourself.
19964 \end_layout
19965
19966 \begin_layout Standard
19967 Then you are asked interactively to supply an initial description of the
19968  document.
19969  Don't forget that registered file is not yet commited.
19970 \end_layout
19971
19972 \begin_layout Standard
19973 SVN command that is run: 
19974 \family typewriter
19975 svn add -q 
19976 \begin_inset Quotes eld
19977 \end_inset
19978
19979 <file-name>
19980 \begin_inset Quotes erd
19981 \end_inset
19982
19983
19984 \end_layout
19985
19986 \begin_layout Standard
19987 Read 
19988 \family typewriter
19989 man svn
19990 \family default
19991  to understand the switches.
19992 \end_layout
19993
19994 \begin_layout Subsubsection
19995
19996 \family sans
19997 Check In Changes
19998 \end_layout
19999
20000 \begin_layout Standard
20001 When you are finished editing a file, you commit your changes.
20002  When you do this, you are asked for a description of the changes.
20003  After that changes are commited.
20004 \end_layout
20005
20006 \begin_layout Standard
20007 SVN command:
20008 \begin_inset Foot
20009 status collapsed
20010
20011 \begin_layout Plain Layout
20012 In case locking is not enabled.
20013  See Section 
20014 \begin_inset CommandInset ref
20015 LatexCommand ref
20016 reference "subsec:SVN-File-Locking"
20017
20018 \end_inset
20019
20020 .
20021 \end_layout
20022
20023 \end_inset
20024
20025  
20026 \family typewriter
20027 svn commit -q -m"<description>" <file-name>
20028 \end_layout
20029
20030 \begin_layout Subsubsection
20031
20032 \family sans
20033 Check Out For Edit
20034 \end_layout
20035
20036 \begin_layout Standard
20037 Updates the changes of this file from the repository.
20038  Be sure you understand SVN merging and conflicts resolving before using
20039  this function, because all conflicts has to be resolved manually by you!
20040 \end_layout
20041
20042 \begin_layout Standard
20043 SVN command:
20044 \begin_inset Foot
20045 status collapsed
20046
20047 \begin_layout Plain Layout
20048 Ditto.
20049 \end_layout
20050
20051 \end_inset
20052
20053  
20054 \family typewriter
20055 svn update --non-interactive 
20056 \begin_inset Quotes eld
20057 \end_inset
20058
20059 <file-name>
20060 \begin_inset Quotes erd
20061 \end_inset
20062
20063
20064 \end_layout
20065
20066 \begin_layout Subsubsection
20067
20068 \family sans
20069 Revert To Repository Version
20070 \end_layout
20071
20072 \begin_layout Standard
20073 This will discard all changes made to the document since the last check
20074  in.
20075  You get a warning before changes are discarded.
20076 \end_layout
20077
20078 \begin_layout Standard
20079 SVN command: 
20080 \family typewriter
20081 svn revert -q 
20082 \begin_inset Quotes eld
20083 \end_inset
20084
20085 <file-name>
20086 \begin_inset Quotes erd
20087 \end_inset
20088
20089
20090 \end_layout
20091
20092 \begin_layout Subsubsection
20093
20094 \family sans
20095 Copy
20096 \end_layout
20097
20098 \begin_layout Standard
20099 This will create a copy of the current document including the version history.
20100  It requires a clean document without any changes since the last checkin.
20101  You are asked for a file name and a description of the copy operation.
20102  After that the copy is created, both locally and in the repository.
20103  If the parent directories of the copied and original document differ, all
20104  relative paths of included files of the copy are adjusted (like in 
20105 \family sans
20106 File\SpecialChar menuseparator
20107 Save As
20108 \family default
20109 \SpecialChar ldots
20110 ).
20111  Finally, the copy is loaded instead of the original document.
20112 \end_layout
20113
20114 \begin_layout Labeling
20115 \labelwidthstring 00.00.0000
20116 SVN
20117 \begin_inset space ~
20118 \end_inset
20119
20120 commands: 
20121 \begin_inset space ~
20122 \end_inset
20123
20124
20125 \begin_inset Newline newline
20126 \end_inset
20127
20128
20129 \begin_inset Flex Code
20130 status collapsed
20131
20132 \begin_layout Plain Layout
20133 svn copy -q 
20134 \family typewriter
20135
20136 \begin_inset Quotes eld
20137 \end_inset
20138
20139 <file-name>
20140 \begin_inset Quotes erd
20141 \end_inset
20142
20143  
20144 \begin_inset Quotes eld
20145 \end_inset
20146
20147 <new-file-name>
20148 \begin_inset Quotes erd
20149 \end_inset
20150
20151
20152 \end_layout
20153
20154 \end_inset
20155
20156
20157 \begin_inset Newline newline
20158 \end_inset
20159
20160
20161 \begin_inset Flex Code
20162 status collapsed
20163
20164 \begin_layout Plain Layout
20165 svn commit
20166 \end_layout
20167
20168 \end_inset
20169
20170
20171 \end_layout
20172
20173 \begin_layout Subsubsection
20174
20175 \family sans
20176 Rename
20177 \end_layout
20178
20179 \begin_layout Standard
20180 This will rename the current document including the version history.
20181  It requires a clean document without any changes since the last checkin.
20182  You are asked for a file name and a description of the rename operation.
20183  After that the document is renamed, both locally and in the repository.
20184  If the parent directories of the new and old file names differ, all relative
20185  paths of included files are adjusted (like in 
20186 \family sans
20187 File\SpecialChar menuseparator
20188 Save As
20189 \family default
20190 \SpecialChar ldots
20191 ).
20192  Finally, the document is reloaded using the new name.
20193 \end_layout
20194
20195 \begin_layout Labeling
20196 \labelwidthstring 00.00.0000
20197 SVN
20198 \begin_inset space ~
20199 \end_inset
20200
20201 commands: 
20202 \begin_inset space ~
20203 \end_inset
20204
20205
20206 \begin_inset Newline newline
20207 \end_inset
20208
20209
20210 \begin_inset Flex Code
20211 status collapsed
20212
20213 \begin_layout Plain Layout
20214 svn move -q 
20215 \family typewriter
20216
20217 \begin_inset Quotes eld
20218 \end_inset
20219
20220 <file-name>
20221 \begin_inset Quotes erd
20222 \end_inset
20223
20224  
20225 \begin_inset Quotes eld
20226 \end_inset
20227
20228 <new-file-name>
20229 \begin_inset Quotes erd
20230 \end_inset
20231
20232
20233 \end_layout
20234
20235 \end_inset
20236
20237
20238 \begin_inset Newline newline
20239 \end_inset
20240
20241
20242 \begin_inset Flex Code
20243 status collapsed
20244
20245 \begin_layout Plain Layout
20246 svn commit
20247 \end_layout
20248
20249 \end_inset
20250
20251
20252 \end_layout
20253
20254 \begin_layout Subsubsection
20255 \begin_inset CommandInset label
20256 LatexCommand label
20257 name "subsec:SVN-Repo-Update"
20258
20259 \end_inset
20260
20261 Update of the local directory checkout from repository
20262 \begin_inset Foot
20263 status collapsed
20264
20265 \begin_layout Plain Layout
20266 Note that this command will work only with subversion 
20267 \begin_inset Formula $\geqq1.5$
20268 \end_inset
20269
20270
20271 \end_layout
20272
20273 \end_inset
20274
20275
20276 \end_layout
20277
20278 \begin_layout Standard
20279 All the commands above have one shortcomming - they deal with the current
20280  document only.
20281  Once your document contains pictures, includes external 
20282 \begin_inset Flex Code
20283 status collapsed
20284
20285 \begin_layout Plain Layout
20286 .tex
20287 \end_layout
20288
20289 \end_inset
20290
20291  files and so on administration becomes more complicated.
20292  \SpecialChar LyX
20293  now supports updating the whole tree in which resides the document
20294 \begin_inset Foot
20295 status collapsed
20296
20297 \begin_layout Plain Layout
20298 One need to organize the files structure so that all external files are
20299  in the same directory or subdirectories of the document.
20300  
20301 \end_layout
20302
20303 \end_inset
20304
20305 .
20306  This become especially useful once you cooperate with people which neither
20307  know about subversion management nor they have ambition to commit additional
20308  material to the repository.
20309  
20310 \end_layout
20311
20312 \begin_layout Standard
20313 \begin_inset Flex Code
20314 status collapsed
20315
20316 \begin_layout Plain Layout
20317 Update local directory from repository
20318 \end_layout
20319
20320 \end_inset
20321
20322  command updates the whole directory and in case of merge conflicts local
20323  version of the files are left, so no unintended data loss occurs.
20324  If local changes are detected user is warned before update starts.
20325 \end_layout
20326
20327 \begin_layout Labeling
20328 \labelwidthstring 00.00.0000
20329 SVN
20330 \begin_inset space ~
20331 \end_inset
20332
20333 commands: 
20334 \begin_inset space ~
20335 \end_inset
20336
20337
20338 \begin_inset Newline newline
20339 \end_inset
20340
20341
20342 \begin_inset Flex Code
20343 status collapsed
20344
20345 \begin_layout Plain Layout
20346 svn diff $path
20347 \end_layout
20348
20349 \end_inset
20350
20351  (Ask if changes are detected.)
20352 \begin_inset Newline newline
20353 \end_inset
20354
20355
20356 \begin_inset Flex Code
20357 status collapsed
20358
20359 \begin_layout Plain Layout
20360 svn update –accept mine-full $path
20361 \end_layout
20362
20363 \end_inset
20364
20365
20366 \end_layout
20367
20368 \begin_layout Standard
20369 where 
20370 \begin_inset Flex Code
20371 status collapsed
20372
20373 \begin_layout Plain Layout
20374 $path
20375 \end_layout
20376
20377 \end_inset
20378
20379  stands for the path to the document.
20380 \end_layout
20381
20382 \begin_layout Subsubsection
20383
20384 \family sans
20385 Show History
20386 \end_layout
20387
20388 \begin_layout Standard
20389 This shows the complete history of the SVN document.
20390  The output of 
20391 \family typewriter
20392 svn log 
20393 \begin_inset Quotes eld
20394 \end_inset
20395
20396 <file-name>
20397 \begin_inset Quotes erd
20398 \end_inset
20399
20400
20401 \family default
20402  is shown in a browser.
20403 \end_layout
20404
20405 \begin_layout Subsubsection
20406 File Locking
20407 \begin_inset CommandInset label
20408 LatexCommand label
20409 name "subsec:SVN-File-Locking"
20410
20411 \end_inset
20412
20413
20414 \end_layout
20415
20416 \begin_layout Standard
20417 The file exchange through various revision control systems brings the problem
20418  of merge conflicts in case two different users try to edit the same (parts
20419  of) document.
20420  When such a conflict happens it needs manual resolving and one reasonable
20421  alternative is to provide some kind of locking mechanism, which guarantees
20422  that only one user is allowed to edit file at the given time.
20423 \end_layout
20424
20425 \begin_layout Standard
20426 SVN has two such mechanisms to provide mutual exclusivity for file access
20427  - locks and automatic setting of write permissions (see sec.
20428  
20429 \begin_inset CommandInset ref
20430 LatexCommand ref
20431 reference "subsec:Automatical-Locking-Property"
20432
20433 \end_inset
20434
20435 ) based on 
20436 \begin_inset Flex Code
20437 status collapsed
20438
20439 \begin_layout Plain Layout
20440 svn:needs-lock
20441 \end_layout
20442
20443 \end_inset
20444
20445  file svn property
20446 \begin_inset Foot
20447 status open
20448
20449 \begin_layout Plain Layout
20450 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
20451 \end_layout
20452
20453 \end_inset
20454
20455 .
20456  If this property is detected for a given document \SpecialChar LyX
20457  starts to use SVN locks
20458  for document editing automatically and the whole check-in/out mechanism
20459  switches to the same regimen as for RCS.
20460  This in particular means there are two different modes of file use in \SpecialChar LyX
20461 :
20462 \end_layout
20463
20464 \begin_layout Itemize
20465 Unlocked state.
20466  The loaded file is in the read-only mode.
20467  For editing on needs to check-out.
20468  
20469 \emph on
20470 Check-out
20471 \emph default
20472  consists of updating from the repository and gaining write lock.
20473  If the lock is not possible to obtain, we remain in unlocked state.
20474 \end_layout
20475
20476 \begin_layout Itemize
20477 Locked state.
20478  The loaded file is in the 'normal' edit mode.
20479  No other user is allowed to edit the file.
20480  
20481 \emph on
20482 Check-in
20483 \emph default
20484  consists of commiting changes and releasing write-lock.
20485  If no changes have been made to the document, no commit will be produced
20486 \begin_inset Foot
20487 status collapsed
20488
20489 \begin_layout Plain Layout
20490 Don't be puzzled by the fact that you will be asked for commit message anyway.
20491 \end_layout
20492
20493 \end_inset
20494
20495  and only the write-lock will be released.
20496 \end_layout
20497
20498 \begin_layout Standard
20499 SVN commands:
20500 \end_layout
20501
20502 \begin_layout Labeling
20503 \labelwidthstring 00.00.0000
20504 Check-in:
20505 \family typewriter
20506  svn commit -q -m"<description>" "<file-name>"
20507 \begin_inset Newline newline
20508 \end_inset
20509
20510 svn unlock "<file-name>"
20511 \end_layout
20512
20513 \begin_layout Labeling
20514 \labelwidthstring 00.00.0000
20515 Check-out: 
20516 \family typewriter
20517 svn update "<file-name>"
20518 \begin_inset Newline newline
20519 \end_inset
20520
20521 svn lock "<file-name>"
20522 \end_layout
20523
20524 \begin_layout Subsubsection
20525
20526 \family typewriter
20527 \begin_inset CommandInset label
20528 LatexCommand label
20529 name "subsec:Automatical-Locking-Property"
20530
20531 \end_inset
20532
20533
20534 \family default
20535 Automatic Locking Property
20536 \end_layout
20537
20538 \begin_layout Standard
20539 The above mentioned automatic setting of write permissions of the .lyx file
20540  can be set through
20541 \family sans
20542  File\SpecialChar menuseparator
20543 Version
20544 \begin_inset space ~
20545 \end_inset
20546
20547 Control\SpecialChar menuseparator
20548 Toggle locking property
20549 \family default
20550 .
20551  This command is active only when the file is not locked on the svn server
20552  (i.e.
20553  you need to check-out before proceeding).
20554 \end_layout
20555
20556 \begin_layout Labeling
20557 \labelwidthstring 00.00.0000
20558 SVN
20559 \begin_inset space ~
20560 \end_inset
20561
20562 commands:
20563 \end_layout
20564
20565 \begin_layout Labeling
20566 \labelwidthstring 00.00.0000
20567 Set:
20568 \family typewriter
20569  svn propset svn:needs-lock ON "<file-name>"
20570 \end_layout
20571
20572 \begin_layout Labeling
20573 \labelwidthstring 00.00.0000
20574 Unset: 
20575 \family typewriter
20576 svn propdel svn:needs-lock "<file-name>"
20577 \end_layout
20578
20579 \begin_layout Subsubsection
20580 \begin_inset CommandInset label
20581 LatexCommand label
20582 name "subsec:VCS-Revision-Information"
20583
20584 \end_inset
20585
20586 Revision Information in Documents
20587 \end_layout
20588
20589 \begin_layout Standard
20590 There are more possibilities how to activate revision information in our
20591  document.
20592 \end_layout
20593
20594 \begin_layout Itemize
20595 \SpecialChar LyX
20596  supports directly:
20597 \end_layout
20598
20599 \begin_deeper
20600 \begin_layout Itemize
20601 tree revision information (
20602 \begin_inset Flex Code
20603 status collapsed
20604
20605 \begin_layout Plain Layout
20606 vcs-tree-revision
20607 \end_layout
20608
20609 \end_inset
20610
20611 ).
20612  The result is the output of the 
20613 \begin_inset Flex Code
20614 status collapsed
20615
20616 \begin_layout Plain Layout
20617 svnversion
20618 \end_layout
20619
20620 \end_inset
20621
20622  command, the following table gives you an idea, how to read the results.
20623 \end_layout
20624
20625 \begin_layout Standard
20626 \align center
20627 \begin_inset Tabular
20628 <lyxtabular version="3" rows="6" columns="2">
20629 <features tabularvalignment="middle">
20630 <column alignment="center" valignment="top">
20631 <column alignment="center" valignment="top">
20632 <row>
20633 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20634 \begin_inset Text
20635
20636 \begin_layout Plain Layout
20637 Output
20638 \end_layout
20639
20640 \end_inset
20641 </cell>
20642 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20643 \begin_inset Text
20644
20645 \begin_layout Plain Layout
20646 Meaning
20647 \end_layout
20648
20649 \end_inset
20650 </cell>
20651 </row>
20652 <row>
20653 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20654 \begin_inset Text
20655
20656 \begin_layout Plain Layout
20657 4123:4168
20658 \end_layout
20659
20660 \end_inset
20661 </cell>
20662 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20663 \begin_inset Text
20664
20665 \begin_layout Plain Layout
20666 mixed revision working copy
20667 \end_layout
20668
20669 \end_inset
20670 </cell>
20671 </row>
20672 <row>
20673 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20674 \begin_inset Text
20675
20676 \begin_layout Plain Layout
20677 4168M
20678 \end_layout
20679
20680 \end_inset
20681 </cell>
20682 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20683 \begin_inset Text
20684
20685 \begin_layout Plain Layout
20686 modified working copy
20687 \end_layout
20688
20689 \end_inset
20690 </cell>
20691 </row>
20692 <row>
20693 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20694 \begin_inset Text
20695
20696 \begin_layout Plain Layout
20697 4123S
20698 \end_layout
20699
20700 \end_inset
20701 </cell>
20702 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20703 \begin_inset Text
20704
20705 \begin_layout Plain Layout
20706 switched working copy
20707 \end_layout
20708
20709 \end_inset
20710 </cell>
20711 </row>
20712 <row>
20713 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20714 \begin_inset Text
20715
20716 \begin_layout Plain Layout
20717 4123P
20718 \end_layout
20719
20720 \end_inset
20721 </cell>
20722 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20723 \begin_inset Text
20724
20725 \begin_layout Plain Layout
20726 partial working copy, from a sparse checkout
20727 \end_layout
20728
20729 \end_inset
20730 </cell>
20731 </row>
20732 <row>
20733 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20734 \begin_inset Text
20735
20736 \begin_layout Plain Layout
20737 4123:4168MS
20738 \end_layout
20739
20740 \end_inset
20741 </cell>
20742 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20743 \begin_inset Text
20744
20745 \begin_layout Plain Layout
20746 mixed revision, modified, switched working copy
20747 \end_layout
20748
20749 \end_inset
20750 </cell>
20751 </row>
20752 </lyxtabular>
20753
20754 \end_inset
20755
20756
20757 \end_layout
20758
20759 \begin_layout Itemize
20760 file revision information.
20761  The result comes from parsing the output of 
20762 \begin_inset Flex Code
20763 status collapsed
20764
20765 \begin_layout Plain Layout
20766 svn
20767 \begin_inset space ~
20768 \end_inset
20769
20770 info
20771 \begin_inset space ~
20772 \end_inset
20773
20774 –xml
20775 \begin_inset space ~
20776 \end_inset
20777
20778 file.lyx
20779 \end_layout
20780
20781 \end_inset
20782
20783 .
20784  Supported flags are:
20785 \end_layout
20786
20787 \begin_deeper
20788 \begin_layout Itemize
20789 version number of the last commit (
20790 \begin_inset Flex Code
20791 status collapsed
20792
20793 \begin_layout Plain Layout
20794 vcs-revision
20795 \end_layout
20796
20797 \end_inset
20798
20799 )
20800 \end_layout
20801
20802 \begin_layout Itemize
20803 author of the last commit (
20804 \begin_inset Flex Code
20805 status collapsed
20806
20807 \begin_layout Plain Layout
20808 vcs-author
20809 \end_layout
20810
20811 \end_inset
20812
20813 )
20814 \end_layout
20815
20816 \begin_layout Itemize
20817 date of the last commit (
20818 \begin_inset Flex Code
20819 status collapsed
20820
20821 \begin_layout Plain Layout
20822 vcs-date
20823 \end_layout
20824
20825 \end_inset
20826
20827 )
20828 \end_layout
20829
20830 \begin_layout Itemize
20831 time of the last commit (
20832 \begin_inset Flex Code
20833 status collapsed
20834
20835 \begin_layout Plain Layout
20836 vcs-time
20837 \end_layout
20838
20839 \end_inset
20840
20841 )
20842 \end_layout
20843
20844 \end_deeper
20845 \begin_layout Standard
20846 You can obtain this info via InsetInfo (e.g.
20847  
20848 \begin_inset Flex Code
20849 status collapsed
20850
20851 \begin_layout Plain Layout
20852 info-insert buffer vcs-date
20853 \end_layout
20854
20855 \end_inset
20856
20857 ).
20858  The information will be available only when you have the file stored under
20859  svn managment (i.e.
20860  the 
20861 \begin_inset Flex Code
20862 status collapsed
20863
20864 \begin_layout Plain Layout
20865 .svn
20866 \end_layout
20867
20868 \end_inset
20869
20870  directory is available with your document).
20871 \end_layout
20872
20873 \end_deeper
20874 \begin_layout Itemize
20875 Another—a hacking one—possibility is to use svn keywords
20876 \begin_inset Foot
20877 status collapsed
20878
20879 \begin_layout Plain Layout
20880 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
20881 \end_layout
20882
20883 \end_inset
20884
20885 .
20886  In short – you set file keywords property (e.g.
20887  
20888 \family sans
20889 svn propset svn:keywords 'Rev' file.lyx
20890 \family default
20891 ) and then paste keyword \SpecialChar TeX
20892  code
20893 \begin_inset Foot
20894 status collapsed
20895
20896 \begin_layout Plain Layout
20897 This is an easy way how to ensure that \SpecialChar LyX
20898  won't break the line in the middle
20899  of keyword tag.
20900 \end_layout
20901
20902 \end_inset
20903
20904  tag in your document (e.g.
20905  
20906 \begin_inset ERT
20907 status open
20908
20909 \begin_layout Plain Layout
20910
20911 $Rev$
20912 \end_layout
20913
20914 \end_inset
20915
20916 ).
20917  This way svn client will automatically substitute revision number (e.g.
20918  
20919 \begin_inset ERT
20920 status open
20921
20922 \begin_layout Plain Layout
20923
20924 $Rev: 59 $
20925 \end_layout
20926
20927 \end_inset
20928
20929 ) after each update and commit.
20930  There are more problems with this approach.
20931  Firstly, the '$' character is used in \SpecialChar TeX
20932  world for math equations, so any
20933  occurence of math formula 
20934 \begin_inset Formula $Rev$
20935 \end_inset
20936
20937  become 
20938 \begin_inset Formula $Rev:59$
20939 \end_inset
20940
20941  in your \SpecialChar LyX
20942  document.
20943  Similarly for other keywords like Id, Date, Author, etc.
20944  Secondly svn output is dependent on your locales, so its very easy that
20945  svn would produce some problematic strings once Date is used.
20946  Thirdly you get the whole 'Rev: 59' string in your document instead of
20947  the plain number.
20948  Until subversion implements user's custom keywords it will be hard to use
20949  this approach reliably or let \SpecialChar LyX
20950  to support it directly.
20951 \end_layout
20952
20953 \begin_layout Subsection
20954 SVN and Windows Environment
20955 \end_layout
20956
20957 \begin_layout Quote
20958 My inclination is to say that if the user cannot figure out the command
20959  line operations on their own fairly quickly, they would be well advised
20960  to use TortoiseSVN.
20961  —P.
20962  A.
20963  Rubin
20964 \end_layout
20965
20966 \begin_layout Subsubsection
20967 Preparation
20968 \end_layout
20969
20970 \begin_layout Standard
20971 In addition to installing \SpecialChar LyX
20972 , and having access to a Subversion repository,
20973  the user will need to install the Subversion client program.
20974  A Windows installer for the client program is available from 
20975 \begin_inset CommandInset href
20976 LatexCommand href
20977 name "CollabNet"
20978 target "http://www.collab.net/nonav/downloads/subversion/"
20979
20980 \end_inset
20981
20982 .
20983  The user may also want to install 
20984 \begin_inset CommandInset href
20985 LatexCommand href
20986 name "TortoiseSVN"
20987 target "http://tortoisesvn.tigris.org/"
20988
20989 \end_inset
20990
20991 , which integrates Subversion operations into the context (rightclick) menu
20992  of Windows Explorer.
20993  Operations done outside \SpecialChar LyX
20994  will typically be more convenient using the Explorer
20995  context menu.
20996  Note that TortoiseSVN is not a replacement for the client program, which
20997  is what \SpecialChar LyX
20998  itself will use.
20999 \end_layout
21000
21001 \begin_layout Subsubsection
21002 Bringing a document under Subversion control
21003 \end_layout
21004
21005 \begin_layout Standard
21006 Before a \SpecialChar LyX
21007  document can be brought under version control in Subversion, its
21008  parent directory needs to be under version control.
21009  If the document is being added to a project already in the repository,
21010  this is accomplished by checking the project out to the directory where
21011  the new document will be placed.
21012  If the project itself is not yet under version control (for instance, if
21013  this document starts a new project), the directory must be imported into
21014  the repository.
21015  This is done outside \SpecialChar LyX
21016 .
21017  Both import and checkout are easily accomplished from the Explorer context
21018  menu using TortoiseSVN, or alternatively can be done using the command
21019  line client at a DOS prompt.
21020  The procedure for importing the project using TortoiseSVN is described
21021  below, assuming an existing repository and a new project being started
21022  in 
21023 \family typewriter
21024 C:
21025 \backslash
21026 new project
21027 \family default
21028 .
21029  For information on using the Subversion client program, run 
21030 \family typewriter
21031 svn --help 
21032 \family default
21033 in a DOS shell.
21034 \end_layout
21035
21036 \begin_layout Enumerate
21037 Locate 
21038 \family typewriter
21039 C:
21040 \backslash
21041 new project 
21042 \family default
21043 in Windows Explorer, right click it, and select 
21044 \family sans
21045 TortoiseSVN\SpecialChar menuseparator
21046 Repo-browser
21047 \family default
21048 .
21049  If necessary, adjust the URL for the repository, then click OK.
21050 \end_layout
21051
21052 \begin_layout Enumerate
21053 Right click the level of the repository under which you want to place the
21054  new project folder (typically the top level) and click 
21055 \family sans
21056 Create folder
21057 \family default
21058  Supply a name for the project folder and click OK.
21059  Add a message for the log file if desired, then click OK again.
21060  The new project folder should appear in the repository.
21061  Finally, click OK again to exit the repository browser.
21062 \end_layout
21063
21064 \begin_layout Enumerate
21065 Once again right click 
21066 \family typewriter
21067 C:
21068 \backslash
21069 new project
21070 \family default
21071 , this time selecting SVN Checkout\SpecialChar ldots
21072  Select the URL of the project folder
21073  you just created in the repository, and set the checkout directory to 
21074 \family typewriter
21075 C:
21076 \backslash
21077 new project.
21078
21079 \family default
21080  Click OK.
21081  You will be warned about a non-empty folder; click OK to proceed.
21082  You should now have a 
21083 \family typewriter
21084 .svn
21085 \family default
21086  directory under 
21087 \family typewriter
21088 C:
21089 \backslash
21090 new project.
21091 \end_layout
21092
21093 \begin_layout Enumerate
21094 Create or open your document in \SpecialChar LyX
21095  and click 
21096 \family sans
21097 File\SpecialChar menuseparator
21098 Version
21099 \begin_inset space ~
21100 \end_inset
21101
21102 Control\SpecialChar menuseparator
21103 Register.
21104  
21105 \family default
21106 Add a log message and click OK to commit the document to version control.
21107 \end_layout
21108
21109 \begin_layout Standard
21110 From this point onward, you should have full functionality in the 
21111 \family sans
21112 File\SpecialChar menuseparator
21113 Version
21114 \begin_inset space ~
21115 \end_inset
21116
21117 Control
21118 \family default
21119  menu.
21120  You also have the option of checking the document in and out, viewing its
21121  history, etc.
21122  using the TortoiseSVN context menu in Windows Explorer or the Subversion
21123  client program from a command prompt.
21124 \end_layout
21125
21126 \begin_layout Subsubsection
21127 SSH tunnel used with SVN under Windows
21128 \end_layout
21129
21130 \begin_layout Standard
21131 Compared with Linux setting up an svn client to communicate over ssh under
21132  Windows is a rather troublesome task.
21133  We will at least offer some hints how to setup the client side but prior
21134  knowledge about ssh and the Windows command line is needed, also be prepared
21135  for a great deal of frustration\SpecialChar ldots
21136
21137 \end_layout
21138
21139 \begin_layout Enumerate
21140 Get an svn client for windows, as described in the previous sections.
21141  When it is a fresh install run some svn command (e.g.
21142  
21143 \begin_inset Flex Code
21144 status collapsed
21145
21146 \begin_layout Plain Layout
21147 svn –version
21148 \end_layout
21149
21150 \end_inset
21151
21152 ) to create config files, which you will need to change later on.
21153 \end_layout
21154
21155 \begin_layout Enumerate
21156 Choose an ssh client for Windows.
21157  There are several possibilities, we will use the one from Putty tools
21158 \begin_inset Foot
21159 status collapsed
21160
21161 \begin_layout Plain Layout
21162 \begin_inset Flex URL
21163 status collapsed
21164
21165 \begin_layout Plain Layout
21166
21167 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
21168 \end_layout
21169
21170 \end_inset
21171
21172
21173 \end_layout
21174
21175 \end_inset
21176
21177 .
21178  You will need to set the connection up so that the client doesn't ask for
21179  any password from you.
21180  To keep things easy we will use only keys without any additional password
21181  protection etc.
21182 \end_layout
21183
21184 \begin_deeper
21185 \begin_layout Enumerate
21186 Generate keys by 
21187 \begin_inset Flex Code
21188 status collapsed
21189
21190 \begin_layout Plain Layout
21191 puttygen
21192 \end_layout
21193
21194 \end_inset
21195
21196 .
21197  Save your private .ppk key file and put the public one on the server side.
21198  If the SVN server runs on Linux, note that the format of the public key
21199  is not compatible with Linux openssh and you will need to direcly copy-paste
21200  the key from the “
21201 \emph on
21202 Public key for pasting into OpenSSH authorized_keys file
21203 \emph default
21204 :” edit field into the server's 
21205 \begin_inset Flex Code
21206 status collapsed
21207
21208 \begin_layout Plain Layout
21209 ~/.ssh/authorized_keys
21210 \end_layout
21211
21212 \end_inset
21213
21214  / 
21215 \begin_inset Flex Code
21216 status collapsed
21217
21218 \begin_layout Plain Layout
21219 authorized_keys2
21220 \end_layout
21221
21222 \end_inset
21223
21224  file.
21225 \end_layout
21226
21227 \begin_layout Enumerate
21228 Get the Putty's 
21229 \begin_inset Flex Code
21230 status collapsed
21231
21232 \begin_layout Plain Layout
21233 plink
21234 \end_layout
21235
21236 \end_inset
21237
21238 .
21239  In the SVN config file
21240 \begin_inset Foot
21241 status collapsed
21242
21243 \begin_layout Plain Layout
21244 Exact path depends on Windows version, usually somewhere around 
21245 \begin_inset Flex Code
21246 status collapsed
21247
21248 \begin_layout Plain Layout
21249 c:
21250 \backslash
21251 Documents and Settings
21252 \backslash
21253 user
21254 \backslash
21255 Application Data
21256 \backslash
21257 Subversion
21258 \backslash
21259 config
21260 \end_layout
21261
21262 \end_inset
21263
21264  / 
21265 \begin_inset Flex Code
21266 status collapsed
21267
21268 \begin_layout Plain Layout
21269 AppData
21270 \backslash
21271 Roaming
21272 \backslash
21273 Subversion
21274 \end_layout
21275
21276 \end_inset
21277
21278 .
21279 \end_layout
21280
21281 \end_inset
21282
21283 , section [tunnels], setup ssh command, e.g.
21284  
21285 \begin_inset Flex Code
21286 status collapsed
21287
21288 \begin_layout Plain Layout
21289 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
21290 \end_layout
21291
21292 \end_inset
21293
21294 .
21295 \begin_inset Foot
21296 status collapsed
21297
21298 \begin_layout Plain Layout
21299 It will usually take a lot of time to get exact command right and it depends
21300  on many things.
21301  For example do not have some remote server saved as a default session in
21302  Putty etc.
21303  If things fail, try to connect via plink without SVN first.
21304 \end_layout
21305
21306 \end_inset
21307
21308
21309 \end_layout
21310
21311 \end_deeper
21312 \begin_layout Enumerate
21313 Checkout the SVN archive, e.
21314 \begin_inset space \thinspace{}
21315 \end_inset
21316
21317 g.
21318 \begin_inset Newline newline
21319 \end_inset
21320
21321
21322 \begin_inset Flex Code
21323 status collapsed
21324
21325 \begin_layout Plain Layout
21326 svn co svn+ssh://user@server/repository_path
21327 \end_layout
21328
21329 \end_inset
21330
21331 .
21332 \end_layout
21333
21334 \begin_layout Subsubsection
21335 End-of-Line Conversions
21336 \end_layout
21337
21338 \begin_layout Standard
21339 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
21340  will
21341  use different line endings inside the .lyx files.
21342  This is not a problem as far as \SpecialChar LyX
21343  functionality is concerned, but the commit
21344  diffs will be huge and merge-conflicts prone.
21345  Fortunately SVN itself knows
21346 \begin_inset Foot
21347 status collapsed
21348
21349 \begin_layout Plain Layout
21350 \begin_inset Flex URL
21351 status collapsed
21352
21353 \begin_layout Plain Layout
21354
21355 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
21356 \end_layout
21357
21358 \end_inset
21359
21360
21361 \end_layout
21362
21363 \end_inset
21364
21365  how to deal with CR/LF problems when switching .lyx files to the 
21366 \begin_inset Flex Code
21367 status collapsed
21368
21369 \begin_layout Plain Layout
21370 native
21371 \end_layout
21372
21373 \end_inset
21374
21375  mode.
21376 \begin_inset Foot
21377 status collapsed
21378
21379 \begin_layout Plain Layout
21380 For the lazy guys: 
21381 \begin_inset Flex Code
21382 status collapsed
21383
21384 \begin_layout Plain Layout
21385 svn propset svn:eol-style native FILE_NAME
21386 \end_layout
21387
21388 \end_inset
21389
21390
21391 \end_layout
21392
21393 \end_inset
21394
21395
21396 \end_layout
21397
21398 \begin_layout Subsection
21399 GIT commands in \SpecialChar LyX
21400
21401 \end_layout
21402
21403 \begin_layout Standard
21404 A minimal subset of GIT commands is now supported by \SpecialChar LyX
21405 .
21406  You can find the commands in the 
21407 \family sans
21408 File\SpecialChar menuseparator
21409 Version
21410 \begin_inset space ~
21411 \end_inset
21412
21413 Control
21414 \family default
21415  submenu.
21416  Please note that if you use password protected access to repository via
21417  ssh, you will be asked in terminal window.
21418  \SpecialChar LyX
21419  was tested against GIT 1.7.
21420 \begin_inset Foot
21421 status open
21422
21423 \begin_layout Plain Layout
21424 Windows users please note that you need to ensure that git is on the path.
21425  This can be set from within \SpecialChar LyX
21426  at 
21427 \family sans
21428 Tools\SpecialChar menuseparator
21429 Preferences\SpecialChar menuseparator
21430 Paths\SpecialChar menuseparator
21431 PATH prefix
21432 \family default
21433 .
21434 \end_layout
21435
21436 \end_inset
21437
21438
21439 \end_layout
21440
21441 \begin_layout Standard
21442 One big difference of GIT and the other supported version control systems
21443  is the distributed nature of GIT: With traditional version control systems
21444  there is one central server which hosts the repository.
21445  Users commit their changes to the server, and get updates made by other
21446  users from it.
21447  With GIT, users commit to a local repository.
21448  The local repository can be synchronized with one or more remote repositories
21449  using the 
21450 \begin_inset Flex Code
21451 status collapsed
21452
21453 \begin_layout Plain Layout
21454 pull
21455 \end_layout
21456
21457 \end_inset
21458
21459  and 
21460 \begin_inset Flex Code
21461 status collapsed
21462
21463 \begin_layout Plain Layout
21464 push
21465 \end_layout
21466
21467 \end_inset
21468
21469  GIT commands.
21470  \SpecialChar LyX
21471  does not interact in any way with remote GIT repositories.
21472  It works exclusively with the local repository in a very similar way as
21473  with a central CVS or SVN repository.
21474  If you use remote GIT repositories you need to do the 
21475 \begin_inset Flex Code
21476 status collapsed
21477
21478 \begin_layout Plain Layout
21479 pull
21480 \end_layout
21481
21482 \end_inset
21483
21484  and 
21485 \begin_inset Flex Code
21486 status collapsed
21487
21488 \begin_layout Plain Layout
21489 push
21490 \end_layout
21491
21492 \end_inset
21493
21494  operations with your favourite GIT client.
21495 \end_layout
21496
21497 \begin_layout Subsubsection
21498
21499 \family sans
21500 Register
21501 \end_layout
21502
21503 \begin_layout Standard
21504 If your document is not under revision control, this is the only item shown
21505  in the menu.
21506  And if it is under revision control, the 
21507 \family sans
21508 Register
21509 \family default
21510  item is not visible.
21511 \end_layout
21512
21513 \begin_layout Standard
21514 This command registers in GIT your document ONLY in case you have already
21515  the documents directory under GIT control (in particular 
21516 \family typewriter
21517 .git/index
21518 \family default
21519  file exists).
21520  This means you have to checkout the archive by yourself.
21521 \end_layout
21522
21523 \begin_layout Standard
21524 Then you are asked interactively to supply an initial description of the
21525  document.
21526  Don't forget that registered file is not yet commited.
21527 \end_layout
21528
21529 \begin_layout Standard
21530 GIT command that is run: 
21531 \family typewriter
21532 git add 
21533 \begin_inset Quotes eld
21534 \end_inset
21535
21536 <file-name>
21537 \begin_inset Quotes erd
21538 \end_inset
21539
21540
21541 \end_layout
21542
21543 \begin_layout Standard
21544 Read 
21545 \family typewriter
21546 man git
21547 \family default
21548  to understand the switches.
21549 \end_layout
21550
21551 \begin_layout Subsubsection
21552
21553 \family sans
21554 Check In Changes
21555 \end_layout
21556
21557 \begin_layout Standard
21558 When you are finished editing a file, you commit your changes.
21559  When you do this, you are asked for a description of the changes.
21560  After that changes are commited.
21561 \end_layout
21562
21563 \begin_layout Standard
21564 GIT command: 
21565 \family typewriter
21566 git commit -q -m"<description>" <file-name>
21567 \end_layout
21568
21569 \begin_layout Subsubsection
21570
21571 \family sans
21572 Revert To Repository Version
21573 \end_layout
21574
21575 \begin_layout Standard
21576 This will discard all changes made to the document since the last check
21577  in.
21578  You get a warning before changes are discarded.
21579 \end_layout
21580
21581 \begin_layout Standard
21582 GIT command: 
21583 \family typewriter
21584 git checkout -q 
21585 \begin_inset Quotes eld
21586 \end_inset
21587
21588 <file-name>
21589 \begin_inset Quotes erd
21590 \end_inset
21591
21592
21593 \end_layout
21594
21595 \begin_layout Subsubsection
21596
21597 \family sans
21598 Rename
21599 \end_layout
21600
21601 \begin_layout Standard
21602 This will rename the current document including the version history.
21603  It requires a clean document without any changes since the last checkin.
21604  You are asked for a file name and a description of the rename operation.
21605  After that the document is renamed, both locally and in the repository.
21606  If the parent directories of the new and old file names differ, all relative
21607  paths of included files are adjusted (like in 
21608 \family sans
21609 File\SpecialChar menuseparator
21610 Save As
21611 \family default
21612 \SpecialChar ldots
21613 ).
21614  Finally, the document is reloaded using the new name.
21615 \end_layout
21616
21617 \begin_layout Labeling
21618 \labelwidthstring 00.00.0000
21619 GIT
21620 \begin_inset space ~
21621 \end_inset
21622
21623 commands: 
21624 \begin_inset space ~
21625 \end_inset
21626
21627
21628 \begin_inset Newline newline
21629 \end_inset
21630
21631
21632 \begin_inset Flex Code
21633 status collapsed
21634
21635 \begin_layout Plain Layout
21636 git mv 
21637 \family typewriter
21638
21639 \begin_inset Quotes eld
21640 \end_inset
21641
21642 <file-name>
21643 \begin_inset Quotes erd
21644 \end_inset
21645
21646  
21647 \begin_inset Quotes eld
21648 \end_inset
21649
21650 <new-file-name>
21651 \begin_inset Quotes erd
21652 \end_inset
21653
21654
21655 \end_layout
21656
21657 \end_inset
21658
21659
21660 \begin_inset Newline newline
21661 \end_inset
21662
21663
21664 \begin_inset Flex Code
21665 status collapsed
21666
21667 \begin_layout Plain Layout
21668 git commit
21669 \end_layout
21670
21671 \end_inset
21672
21673
21674 \end_layout
21675
21676 \begin_layout Subsubsection
21677
21678 \family sans
21679 Show History
21680 \end_layout
21681
21682 \begin_layout Standard
21683 This shows the complete history of the GIT document.
21684  The output of 
21685 \family typewriter
21686 git log 
21687 \begin_inset Quotes eld
21688 \end_inset
21689
21690 <file-name>
21691 \begin_inset Quotes erd
21692 \end_inset
21693
21694
21695 \family default
21696  is shown in a browser.
21697 \end_layout
21698
21699 \begin_layout Subsubsection
21700 Version Info
21701 \end_layout
21702
21703 \begin_layout Standard
21704 \SpecialChar LyX
21705  supports GIT hash number of the last commit to the file, author name, date
21706  and time of last commit.
21707  All those are extracted from 
21708 \family typewriter
21709 git log -n 1 --pretty=format:%H%n%an%n%ai
21710 \family default
21711 .
21712  Tree version information is obtained via 
21713 \family typewriter
21714 git describe --abbrev --dirty --long
21715 \family default
21716 .
21717  See 
21718 \begin_inset CommandInset ref
21719 LatexCommand ref
21720 reference "subsec:VCS-Revision-Information"
21721
21722 \end_inset
21723
21724  for other details.
21725 \end_layout
21726
21727 \begin_layout Subsection
21728 Further tuning
21729 \end_layout
21730
21731 \begin_layout Standard
21732 With the recent addition of the vc-command function \SpecialChar LyX
21733  power users are allowed
21734  to create their own commands for revision control.
21735 \end_layout
21736
21737 \begin_layout Standard
21738 As an example you can see how two TortoiseSVN commands could be integrated
21739  directly:
21740 \end_layout
21741
21742 \begin_layout Description
21743 Commit: 
21744 \begin_inset Flex Code
21745 status collapsed
21746
21747 \begin_layout Plain Layout
21748 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
21749 \end_layout
21750
21751 \end_inset
21752
21753
21754 \end_layout
21755
21756 \begin_layout Description
21757 Revert: 
21758 \begin_inset Flex Code
21759 status collapsed
21760
21761 \begin_layout Plain Layout
21762 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
21763 \end_layout
21764
21765 \end_inset
21766
21767
21768 \end_layout
21769
21770 \begin_layout Subsection
21771 Version control and Document comparison
21772 \end_layout
21773
21774 \begin_layout Standard
21775 One of the typical uses of version control is to inspect the changes between
21776  revisions, usually by creating 
21777 \begin_inset Flex Code
21778 status collapsed
21779
21780 \begin_layout Plain Layout
21781 diff
21782 \end_layout
21783
21784 \end_inset
21785
21786  dumps.
21787  While this is useful for plain text files, it is much less useful in the
21788  case of \SpecialChar LyX
21789  files, which have more a complicated structure.
21790  Hence we provide binding to the Document comparison feature.
21791  There are two ways of calling this feature - either by direct call of 
21792 \begin_inset Flex Code
21793 status collapsed
21794
21795 \begin_layout Plain Layout
21796 VC_COMPARE
21797 \end_layout
21798
21799 \end_inset
21800
21801  \SpecialChar LyX
21802  function (for details see \SpecialChar LyX
21803  functions manual) or by icon/menu item 
21804 \begin_inset Flex Noun
21805 status collapsed
21806
21807 \begin_layout Plain Layout
21808 Compare with older revision...
21809 \end_layout
21810
21811 \end_inset
21812
21813 .
21814  One can either compare two chosen revisions of the document or he can simply
21815  compare the current version of edited text with older revisions (where
21816  '
21817 \begin_inset Flex Noun
21818 status collapsed
21819
21820 \begin_layout Plain Layout
21821 0
21822 \end_layout
21823
21824 \end_inset
21825
21826 ' revisions back means comparison of the edited file with last commited
21827  revision).
21828  
21829 \end_layout
21830
21831 \begin_layout Standard
21832 This feature is supported for SVN and RCS though due to the more complicated
21833  versioning scheme of RCS there is a constraint – when addressing the revisions
21834  in dialog, numbers always point to the last number in RCS revision number,
21835  i.e.
21836  '35' in '1.2.35'.
21837  We don't currently support GIT addressing of revisions, one can just compare
21838  edited document with its revision X steps backs, where X is addressed as
21839  HEAD~X.
21840 \end_layout
21841
21842 \begin_layout Section
21843 Literate Programming
21844 \end_layout
21845
21846 \begin_layout Standard
21847 Updated by 
21848 \noun on
21849 Kayvan Sylvan 
21850 \noun default
21851 (kayvan@sylvan.com)
21852 \noun on
21853
21854 \noun default
21855 original documentation written by 
21856 \noun on
21857 Edmar Wienskoski Jr.
21858
21859 \noun default
21860  (edmar-w-jr@technologist.com)
21861 \end_layout
21862
21863 \begin_layout Subsection
21864 Introduction
21865 \end_layout
21866
21867 \begin_layout Standard
21868 The main purpose of this documentation is to show you how to use \SpecialChar LyX
21869  for literate
21870  programming, where it is assumed that you are familiar with this programming
21871  technique, and know what 
21872 \begin_inset Quotes eld
21873 \end_inset
21874
21875 tangling
21876 \begin_inset Quotes erd
21877 \end_inset
21878
21879  and 
21880 \begin_inset Quotes eld
21881 \end_inset
21882
21883 weaving
21884 \begin_inset Quotes erd
21885 \end_inset
21886
21887  means.
21888  If that is not the case, please follow the web links provided in the following
21889  sections.
21890  There is a lot of good documentation out there covering old development
21891  history to the latest tools tips.
21892 \end_layout
21893
21894 \begin_layout Standard
21895 It is also assumed that you are familiar with \SpecialChar LyX
21896  itself to a point that you
21897  are comfortable changing your \SpecialChar LyX
21898  preferences, and X resources file.
21899  If that is not the case please refer to other \SpecialChar LyX
21900  documentation to cover your
21901  specific needs.
21902 \end_layout
21903
21904 \begin_layout Subsection
21905 Literate Programming
21906 \end_layout
21907
21908 \begin_layout Standard
21909 From the Literate Programming FAQ: 
21910 \end_layout
21911
21912 \begin_layout Quotation
21913 Literate programming is the combination of documentation and source together
21914  in a fashion suited for reading by human beings.
21915  In fact, literate programs should be enjoyable reading, even inviting!
21916  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
21917  and documentation in a single file.
21918  Literate programming tools then parse the file to produce either readable
21919  documentation or compilable source.
21920  The WEB style of literate programming was created by D.
21921 \begin_inset space \thinspace{}
21922 \end_inset
21923
21924 E.
21925  Knuth during the development of his \SpecialChar TeX
21926  typesetting software.
21927  
21928 \end_layout
21929
21930 \begin_layout Standard
21931 Another excerpt says:
21932 \end_layout
21933
21934 \begin_layout Quotation
21935
21936 \emph on
21937 How is literate programming different from verbose commenting?
21938 \end_layout
21939
21940 \begin_layout Quotation
21941 There are three distinguishing characteristics.
21942  In order of importance, they are: 
21943 \end_layout
21944
21945 \begin_deeper
21946 \begin_layout Itemize
21947 flexible order of elaboration 
21948 \end_layout
21949
21950 \begin_layout Itemize
21951 automatic support for browsing 
21952 \end_layout
21953
21954 \begin_layout Itemize
21955 typeset documentation, especially diagrams and mathematics 
21956 \end_layout
21957
21958 \end_deeper
21959 \begin_layout Standard
21960 Now that I sparked your curiosity, take a look in the references.
21961 \end_layout
21962
21963 \begin_layout Subsubsection
21964 References
21965 \end_layout
21966
21967 \begin_layout Standard
21968 The complete Literate Programming FAQ can be found at:
21969 \end_layout
21970
21971 \begin_layout Quote
21972 Literate Programming FAQ 
21973 \begin_inset Flex URL
21974 status collapsed
21975
21976 \begin_layout Plain Layout
21977
21978 http://www.literateprogramming.com/lpfaq.pdf
21979 \end_layout
21980
21981 \end_inset
21982
21983
21984 \end_layout
21985
21986 \begin_layout Standard
21987 The FAQ lists 23 (twenty three!) different literate programming tools.
21988  Where some are specialized or 
21989 \begin_inset Quotes eld
21990 \end_inset
21991
21992 tailored
21993 \begin_inset Quotes erd
21994 \end_inset
21995
21996  for particular programming languages, while other have general scope.
21997  I selected 
21998 \noun on
21999 Noweb
22000 \noun default
22001  for my own use for several reasons:
22002 \end_layout
22003
22004 \begin_layout Itemize
22005 It can generate the documentation either in \SpecialChar LaTeX
22006  or HTML.
22007 \end_layout
22008
22009 \begin_layout Itemize
22010 It has a open architecture, i.
22011 \begin_inset space \thinspace{}
22012 \end_inset
22013
22014 e.
22015 \begin_inset space \space{}
22016 \end_inset
22017
22018 it is easy to plug in new filters and to perform special processing that
22019  you may need.
22020  
22021 \end_layout
22022
22023 \begin_layout Itemize
22024 There is a good selection of filters available already (the HTML is one
22025  of them).
22026 \end_layout
22027
22028 \begin_layout Itemize
22029 It is free.
22030 \end_layout
22031
22032 \begin_layout Standard
22033 The Noweb web page can be found at: 
22034 \end_layout
22035
22036 \begin_layout Quote
22037 Noweb home page 
22038 \begin_inset Flex URL
22039 status collapsed
22040
22041 \begin_layout Plain Layout
22042
22043 http://www.cs.virginia.edu/~nr/noweb/
22044 \end_layout
22045
22046 \end_inset
22047
22048
22049 \end_layout
22050
22051 \begin_layout Standard
22052 Starting from there you can reach many other interesting links and even
22053  some literate program examples.
22054 \end_layout
22055
22056 \begin_layout Subsection
22057 \SpecialChar LyX
22058  and Literate Programming with Noweb
22059 \end_layout
22060
22061 \begin_layout Standard
22062 The \SpecialChar LyX
22063  support for Literate Programming is provided by using the generic \SpecialChar LyX
22064
22065  converters mechanism.
22066  This support is provided in a 
22067 \begin_inset Quotes eld
22068 \end_inset
22069
22070 Noweb independent
22071 \begin_inset Quotes erd
22072 \end_inset
22073
22074  way, i.
22075 \begin_inset space \thinspace{}
22076 \end_inset
22077
22078 e.
22079 \begin_inset space \space{}
22080 \end_inset
22081
22082 you will be able to use this new \SpecialChar LyX
22083  feature with some other literate programming
22084  tool of your choice by just changing your \SpecialChar LyX
22085  preferences.
22086 \end_layout
22087
22088 \begin_layout Subsubsection
22089 Generating documents and code (weaving and tangling)
22090 \end_layout
22091
22092 \begin_layout Paragraph
22093 Using the noweb module
22094 \end_layout
22095
22096 \begin_layout Standard
22097 If you have installed Noweb and \SpecialChar LyX
22098  successfully, whenever you open a new document,
22099  after you have chosen its document class, use the Document->Settings menu
22100  to add the 
22101 \begin_inset Quotes eld
22102 \end_inset
22103
22104 noweb
22105 \begin_inset Quotes erd
22106 \end_inset
22107
22108  module.
22109  If Noweb is correctly installed, when you click on the 
22110 \begin_inset Quotes eld
22111 \end_inset
22112
22113 Modules
22114 \begin_inset Quotes erd
22115 \end_inset
22116
22117  link, you will see the 
22118 \begin_inset Quotes eld
22119 \end_inset
22120
22121 noweb
22122 \begin_inset Quotes erd
22123 \end_inset
22124
22125  module in the available list and you can add it to your document.
22126 \end_layout
22127
22128 \begin_layout Paragraph
22129 Typing code in
22130 \end_layout
22131
22132 \begin_layout Standard
22133 \SpecialChar LyX
22134  enables you to write code with a layout named 
22135 \begin_inset Flex Noun
22136 status collapsed
22137
22138 \begin_layout Plain Layout
22139 Chunk
22140 \end_layout
22141
22142 \end_inset
22143
22144 .
22145  Noweb delimits chunks like this:
22146 \end_layout
22147
22148 \begin_layout LyX-Code
22149 <<My code>>=
22150 \end_layout
22151
22152 \begin_layout LyX-Code
22153   code
22154 \end_layout
22155
22156 \begin_layout LyX-Code
22157   more code
22158 \end_layout
22159
22160 \begin_layout LyX-Code
22161   even more code
22162 \end_layout
22163
22164 \begin_layout LyX-Code
22165   @
22166 \end_layout
22167
22168 \begin_layout Standard
22169 The problem is that whatever is written in between the << and the 
22170 \family typewriter
22171 @
22172 \family default
22173  must be taken literally, i.
22174 \begin_inset space \thinspace{}
22175 \end_inset
22176
22177 e.
22178 \begin_inset space \space{}
22179 \end_inset
22180
22181 \SpecialChar LyX
22182  should be prevented from making any special interpretation of what has
22183  been written.
22184  This is also handled by 
22185 \begin_inset Flex Noun
22186 status collapsed
22187
22188 \begin_layout Plain Layout
22189 Chunk
22190 \end_layout
22191
22192 \end_inset
22193
22194 , that works like a normal paragraph but has a free spacing capability.
22195 \end_layout
22196
22197 \begin_layout Standard
22198 As a special note, you can also use the 
22199 \begin_inset Quotes eld
22200 \end_inset
22201
22202 %def
22203 \begin_inset Quotes erd
22204 \end_inset
22205
22206  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
22207 rence:
22208 \end_layout
22209
22210 \begin_layout LyX-Code
22211 <<My chunk>>=
22212 \end_layout
22213
22214 \begin_layout LyX-Code
22215 def some_function(args):
22216 \end_layout
22217
22218 \begin_layout LyX-Code
22219    "This is the doc string for this function."
22220 \end_layout
22221
22222 \begin_layout LyX-Code
22223    print "My args: ", args
22224 \end_layout
22225
22226 \begin_layout LyX-Code
22227 @ %def some_function
22228 \end_layout
22229
22230 \begin_layout Standard
22231 For an example of this usage and the resulting cross-reference output, look
22232  at the Literate python program in 
22233 \emph on
22234 LIBDIR/examples/listerrors.lyx
22235 \emph default
22236  which should make this all clear.
22237 \end_layout
22238
22239 \begin_layout Paragraph
22240 Generating the documentation
22241 \end_layout
22242
22243 \begin_layout Standard
22244 At this point you already have a new document file with a proper document
22245  class, and with some code and text on it.
22246  How do I print it? The answer is simple, you select 
22247 \family sans
22248 View\SpecialChar menuseparator
22249 DVI,
22250 \family default
22251  etc.
22252  Just like you would do for a plain document.
22253  No special procedure is required.
22254 \end_layout
22255
22256 \begin_layout Standard
22257 To help orientate you, I will now explain what happens inside \SpecialChar LyX
22258 :
22259 \end_layout
22260
22261 \begin_layout Enumerate
22262 When the 
22263 \family sans
22264 Update\SpecialChar menuseparator
22265 DVI
22266 \family default
22267  menu option is chosen, a \SpecialChar LaTeX
22268  file is generated.
22269  
22270 \end_layout
22271
22272 \begin_deeper
22273 \begin_layout Standard
22274 If the document is of any literate class the generated file will be named
22275  with an extension name defined by the 
22276 \begin_inset Quotes eld
22277 \end_inset
22278
22279 literate
22280 \begin_inset Quotes erd
22281 \end_inset
22282
22283  format (defined in the Preferences panel), otherwise the file will have
22284  the usual 
22285 \family typewriter
22286 .tex
22287 \family default
22288  extension.
22289 \end_layout
22290
22291 \end_deeper
22292 \begin_layout Enumerate
22293 Note that the only difference so far is in the name of the file, no special
22294  processing is required by \SpecialChar LyX
22295 .
22296  Given that you formatted the code using the 
22297 \begin_inset Flex Noun
22298 status collapsed
22299
22300 \begin_layout Plain Layout
22301 Chunk
22302 \end_layout
22303
22304 \end_inset
22305
22306  layout that, by itself, takes care of the business.
22307 \end_layout
22308
22309 \begin_layout Enumerate
22310 If the document is of any literate class \SpecialChar LyX
22311  will then use the internal \SpecialChar LyX
22312  to
22313  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
22314  converter
22315 \begin_inset Foot
22316 status collapsed
22317
22318 \begin_layout Plain Layout
22319 The converters are defined in the 
22320 \family sans
22321 Tools\SpecialChar menuseparator
22322 Preferences
22323 \family default
22324  panel, under the 
22325 \begin_inset Quotes eld
22326 \end_inset
22327
22328 Conversion
22329 \begin_inset Quotes erd
22330 \end_inset
22331
22332  tab.
22333  See section 
22334 \emph on
22335 Converters
22336 \emph default
22337  of the 
22338 \emph on
22339 Customization
22340 \emph default
22341  manual for general information about converters.
22342 \end_layout
22343
22344 \end_inset
22345
22346  to generate the \SpecialChar LaTeX
22347  file.
22348 \end_layout
22349
22350 \begin_deeper
22351 \begin_layout Standard
22352 Otherwise it will just skip this step.
22353 \end_layout
22354
22355 \end_deeper
22356 \begin_layout Enumerate
22357 Finally, \SpecialChar LaTeX
22358  is invoked and the regular post processing continues as in a plain
22359  document.
22360 \end_layout
22361
22362 \begin_layout Standard
22363 Independence from a particular 
22364 \begin_inset Quotes eld
22365 \end_inset
22366
22367 literate tool
22368 \begin_inset Quotes erd
22369 \end_inset
22370
22371  is easily achieved by changing the commands that are run by the various
22372  converters.
22373 \end_layout
22374
22375 \begin_layout Paragraph
22376 Generating the code
22377 \end_layout
22378
22379 \begin_layout Standard
22380 When the build menu option is chosen or the corresponding button in the
22381  toolbar is pressed, a \SpecialChar LaTeX
22382  file is generated just like step 1 above.
22383  Next, \SpecialChar LyX
22384  invokes the 
22385 \family typewriter
22386 Noweb->Program
22387 \family default
22388  converter.
22389  This converter needs to be defined by the user and is not installed by
22390  default, though the Program format is.
22391  This converter (like any other converter) will have two parts:
22392 \end_layout
22393
22394 \begin_layout Enumerate
22395 The converter program itself.
22396  This program performs the conversion from the one format to the other (in
22397  this case, from the Noweb format to the Program pseudo-format).
22398 \end_layout
22399
22400 \begin_layout Enumerate
22401 The error log parser.
22402  This is a program whose sole purpose is to rewrite error messages in a
22403  format that \SpecialChar LyX
22404  understands.
22405  This makes it possible for \SpecialChar LyX
22406  to place error boxes in the right places in
22407  the file buffer.
22408 \end_layout
22409
22410 \begin_layout Standard
22411 The first part, the 
22412 \begin_inset Quotes eld
22413 \end_inset
22414
22415 Converter
22416 \begin_inset Quotes erd
22417 \end_inset
22418
22419  setting, should be set to
22420 \begin_inset Newline newline
22421 \end_inset
22422
22423
22424 \begin_inset Quotes eld
22425 \end_inset
22426
22427
22428 \family typewriter
22429 build-script $$i
22430 \family default
22431  $$r
22432 \begin_inset Quotes erd
22433 \end_inset
22434
22435 .
22436 \begin_inset Newline newline
22437 \end_inset
22438
22439 This basically means that \SpecialChar LyX
22440  will call 
22441 \begin_inset Quotes eld
22442 \end_inset
22443
22444 build-script
22445 \begin_inset Quotes erd
22446 \end_inset
22447
22448  (a program or script) with the name of the Noweb file (normally a file
22449  in the \SpecialChar LyX
22450  temp directory) and the directory path of the original \SpecialChar LyX
22451  file.
22452  
22453 \end_layout
22454
22455 \begin_layout Standard
22456 This is an implementation of 
22457 \begin_inset Quotes eld
22458 \end_inset
22459
22460 build-script
22461 \begin_inset Quotes erd
22462 \end_inset
22463
22464  that you can place in a directory on your path:
22465 \end_layout
22466
22467 \begin_layout Standard
22468 \begin_inset VSpace defskip
22469 \end_inset
22470
22471
22472 \end_layout
22473
22474 \begin_layout Standard
22475 \begin_inset Newpage pagebreak
22476 \end_inset
22477
22478
22479 \end_layout
22480
22481 \begin_layout Standard
22482
22483 \family sans
22484 #!/bin/sh
22485 \end_layout
22486
22487 \begin_layout Standard
22488
22489 \family sans
22490 #
22491 \end_layout
22492
22493 \begin_layout Standard
22494
22495 \family sans
22496 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
22497 \end_layout
22498
22499 \begin_layout Standard
22500 \begin_inset VSpace defskip
22501 \end_inset
22502
22503
22504 \end_layout
22505
22506 \begin_layout Standard
22507 The next part of the converter setting is the 
22508 \begin_inset Quotes eld
22509 \end_inset
22510
22511 Flags
22512 \begin_inset Quotes erd
22513 \end_inset
22514
22515  which is to be set to
22516 \begin_inset Newline newline
22517 \end_inset
22518
22519
22520 \begin_inset Quotes eld
22521 \end_inset
22522
22523
22524 \family typewriter
22525 parselog=$$s/scripts/listerrors
22526 \family default
22527
22528 \begin_inset Quotes erd
22529 \end_inset
22530
22531 .
22532 \begin_inset Newline newline
22533 \end_inset
22534
22535 This will run any errors that are generated by the 
22536 \begin_inset Quotes eld
22537 \end_inset
22538
22539 build-script
22540 \begin_inset Quotes erd
22541 \end_inset
22542
22543  process through the 
22544 \begin_inset Quotes eld
22545 \end_inset
22546
22547 listerrors
22548 \begin_inset Quotes erd
22549 \end_inset
22550
22551  program.
22552 \end_layout
22553
22554 \begin_layout Standard
22555 The build will normally take place in \SpecialChar LyX
22556 's temporary directory, so the files
22557  produced by the conversion will be in that directory.
22558  \SpecialChar LyX
22559  will copy out what it regards as the `main' file, but the 
22560 \family typewriter
22561 Noweb->Program
22562 \family default
22563  conversion may produce several files, and so most of these would then be
22564  deleted when \SpecialChar LyX
22565  was closed.
22566  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
22567  the build-script chunk can place the generated files in that location.
22568 \end_layout
22569
22570 \begin_layout Paragraph
22571 Build instructions in the document
22572 \end_layout
22573
22574 \begin_layout Standard
22575 The last piece of the integration between \SpecialChar LyX
22576  and noweb is the 
22577 \begin_inset Quotes eld
22578 \end_inset
22579
22580 build-script
22581 \begin_inset Quotes erd
22582 \end_inset
22583
22584  chunk.
22585  Generally, the instructions for building your program should be embedded
22586  in a chunk of its own.
22587  The noweb-specific 
22588 \begin_inset Quotes eld
22589 \end_inset
22590
22591 build-script
22592 \begin_inset Quotes erd
22593 \end_inset
22594
22595  above uses the notangle command to look for this chunk (called 
22596 \begin_inset Quotes eld
22597 \end_inset
22598
22599 build-script
22600 \begin_inset Quotes erd
22601 \end_inset
22602
22603 ) and runs its contents through 
22604 \begin_inset Quotes eld
22605 \end_inset
22606
22607 sh
22608 \begin_inset Quotes erd
22609 \end_inset
22610
22611 .
22612 \end_layout
22613
22614 \begin_layout Standard
22615 Typically, such a chunk would look something like this:
22616 \end_layout
22617
22618 \begin_layout LyX-Code
22619 <<build-script>>=
22620 \end_layout
22621
22622 \begin_layout LyX-Code
22623 #!/bin/sh
22624 \begin_inset Newline newline
22625 \end_inset
22626
22627 if [ -z "${NOWEB_SOURCE}" ]
22628 \begin_inset Newline newline
22629 \end_inset
22630
22631 then
22632 \end_layout
22633
22634 \begin_layout LyX-Code
22635 NOWEB_SOURCE=myfile.nw
22636 \begin_inset Newline newline
22637 \end_inset
22638
22639 fi
22640 \begin_inset Newline newline
22641 \end_inset
22642
22643 [...
22644  code to extract files ...
22645  use NOWEB_OUTPUT_DIR here ...]
22646 \begin_inset Newline newline
22647 \end_inset
22648
22649 [...
22650  code to compile files ...]
22651 \begin_inset Newline newline
22652 \end_inset
22653
22654 @
22655 \end_layout
22656
22657 \begin_layout Standard
22658 Look in 
22659 \emph on
22660 LIBDIR/examples/listerrors.lyx
22661 \emph default
22662  or in 
22663 \emph on
22664 LIBDIR/examples/Literate.lyx
22665 \emph default
22666  which implement two versions of the 
22667 \begin_inset Quotes eld
22668 \end_inset
22669
22670 listerrors
22671 \begin_inset Quotes erd
22672 \end_inset
22673
22674  program for some illustrations of how all of these pieces go together or
22675  in 
22676 \emph on
22677 LIBDIR/examples/noweb2lyx.lyx.
22678
22679 \emph default
22680  Interestingly, these three files show off the language-indepence of the
22681  \SpecialChar LyX
22682  literate programming support since they are written in Python, C and Perl
22683  respectively.
22684 \end_layout
22685
22686 \begin_layout Subsubsection
22687 Configuring \SpecialChar LyX
22688
22689 \end_layout
22690
22691 \begin_layout Standard
22692 All the Literate Programming support is configured by the 
22693 \family sans
22694 Tools\SpecialChar menuseparator
22695 Preferences
22696 \family default
22697  panel in the 
22698 \begin_inset Quotes eld
22699 \end_inset
22700
22701 File Handling
22702 \begin_inset Quotes erd
22703 \end_inset
22704
22705  tab.
22706  The important parts are:
22707 \end_layout
22708
22709 \begin_layout Description
22710 the
22711 \begin_inset space ~
22712 \end_inset
22713
22714
22715 \begin_inset Quotes eld
22716 \end_inset
22717
22718 NoWeb
22719 \begin_inset Quotes erd
22720 \end_inset
22721
22722
22723 \begin_inset space ~
22724 \end_inset
22725
22726 format Set up via the File Formats tab, this is where the Noweb-specific
22727  pieces are set up.
22728  The 
22729 \family sans
22730 GUI Name
22731 \family default
22732  is set to 
22733 \family typewriter
22734 NoWeb
22735 \family default
22736 , the file extension is set to 
22737 \family typewriter
22738 .nw
22739 \family default
22740 .
22741  This tells \SpecialChar LyX
22742  to create a file with a 
22743 \family typewriter
22744 .nw
22745 \family default
22746  extension in the first step of the conversion process.
22747 \end_layout
22748
22749 \begin_layout Description
22750 the
22751 \begin_inset space ~
22752 \end_inset
22753
22754
22755 \family sans
22756 Program
22757 \family default
22758
22759 \begin_inset space ~
22760 \end_inset
22761
22762 format This is an empty format whose sole purpose is to be the endpoint
22763  of a conversion (which then allows us to set up a converter for it).
22764 \end_layout
22765
22766 \begin_layout Description
22767
22768 \family sans
22769 NoWeb
22770 \family default
22771 ->
22772 \family sans
22773 \SpecialChar LaTeX
22774
22775 \family default
22776  This converter performs the 
22777 \begin_inset Quotes eld
22778 \end_inset
22779
22780 weaving
22781 \begin_inset Quotes erd
22782 \end_inset
22783
22784  of the literate document.
22785  For Noweb, it is set to 
22786 \begin_inset Quotes eld
22787 \end_inset
22788
22789
22790 \family typewriter
22791 noweave -delay -index $$i > $$o
22792 \family default
22793
22794 \begin_inset Quotes erd
22795 \end_inset
22796
22797
22798 \end_layout
22799
22800 \begin_layout Description
22801
22802 \family sans
22803 NoWeb
22804 \family default
22805 ->
22806 \family sans
22807 Program
22808 \family default
22809  This performs the 
22810 \begin_inset Quotes eld
22811 \end_inset
22812
22813 tangling step
22814 \begin_inset Quotes erd
22815 \end_inset
22816
22817 .
22818  As stated above, the Converter is set to 
22819 \begin_inset Quotes eld
22820 \end_inset
22821
22822
22823 \family typewriter
22824 build-script $$i
22825 \family default
22826  $$r
22827 \begin_inset Quotes erd
22828 \end_inset
22829
22830 , with Flags set to
22831 \begin_inset Newline newline
22832 \end_inset
22833
22834
22835 \begin_inset Quotes eld
22836 \end_inset
22837
22838
22839 \family typewriter
22840 parselog=$$s/scripts/listerrors
22841 \family default
22842
22843 \begin_inset Quotes erd
22844 \end_inset
22845
22846 .
22847 \end_layout
22848
22849 \begin_layout Subsubsection
22850 Debug extensions
22851 \end_layout
22852
22853 \begin_layout Standard
22854 There is also a new function implemented in the \SpecialChar LyX
22855  server, the 
22856 \begin_inset Quotes eld
22857 \end_inset
22858
22859 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
22860  
22861 \end_layout
22862
22863 \begin_layout Standard
22864 When debugging code with ddd/gdb, it is possible to invoke a text editor
22865  at the current execution position with a single key stroke.
22866  The default ddd configuration for that is shift-ctrl-V.
22867  It happens that you can define the editor command line invocation in ddd
22868  by accessing the 
22869 \family sans
22870 Edit\SpecialChar menuseparator
22871 Preferences\SpecialChar menuseparator
22872 Helpers
22873 \family default
22874  dialog and changing the "Edit Sources" entry.
22875 \end_layout
22876
22877 \begin_layout Standard
22878 I take advantage of the newly created \SpecialChar LyX
22879  server function and this ddd feature,
22880  and set 
22881 \begin_inset Quotes eld
22882 \end_inset
22883
22884 Edit Sources
22885 \begin_inset Quotes erd
22886 \end_inset
22887
22888  to:
22889 \end_layout
22890
22891 \begin_layout Standard
22892 \begin_inset VSpace defskip
22893 \end_inset
22894
22895
22896 \end_layout
22897
22898 \begin_layout Standard
22899
22900 \family sans
22901 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
22902 \end_layout
22903
22904 \begin_layout Standard
22905 \begin_inset VSpace defskip
22906 \end_inset
22907
22908
22909 \end_layout
22910
22911 \begin_layout Standard
22912 With this, whenever you are using ddd and find a point in the program that
22913  you want to edit, you just press shift-ctrl-V (in the ddd window), and
22914  ddd will forward this information to \SpecialChar LyX
22915  through the \SpecialChar LyX
22916  server and then the
22917  \SpecialChar LyX
22918  window will show the same file with the cursor at the same position ddd
22919  was pointing to.
22920  No more guessing or long scrolling to locate a point in the program back
22921  from debugging !
22922 \end_layout
22923
22924 \begin_layout Standard
22925 Note however that you must enable the \SpecialChar LyX
22926  server to get this feature working
22927  (it is disabled by default).
22928  You can enable it in 
22929 \family sans
22930 Preferences
22931 \family default
22932  (tabs 
22933 \family sans
22934 Inputs
22935 \family default
22936
22937 \family sans
22938 Paths
22939 \family default
22940 ) by entering in the 
22941 \family sans
22942 \SpecialChar LyX
22943 server pipe
22944 \family default
22945  a path like 
22946 \begin_inset Quotes eld
22947 \end_inset
22948
22949
22950 \family typewriter
22951 /home/<your-home-directory>/.lyx/lyxpipe
22952 \family default
22953
22954 \begin_inset Quotes erd
22955 \end_inset
22956
22957
22958 \end_layout
22959
22960 \begin_layout Standard
22961 Read the \SpecialChar LyX
22962  server documentation in the 
22963 \emph on
22964 Customization Manual
22965 \emph default
22966  for further information.
22967 \end_layout
22968
22969 \begin_layout Subsubsection
22970 Toolbar extensions
22971 \end_layout
22972
22973 \begin_layout Standard
22974 There are six new buttons that can be added to your \SpecialChar LyX
22975  toolbar.
22976  Five of these buttons are short cuts to layout styles: 
22977 \family sans
22978 Standard
22979 \family default
22980
22981 \family sans
22982 Section
22983 \family default
22984
22985 \family sans
22986 \SpecialChar LaTeX
22987
22988 \family default
22989
22990 \family sans
22991 \SpecialChar LyX
22992 -Code
22993 \family default
22994 , and 
22995 \family sans
22996 Chunk
22997 \family default
22998 .
22999  The last one is a short cut to the 
23000 \begin_inset Quotes eld
23001 \end_inset
23002
23003 Build Program
23004 \begin_inset Quotes erd
23005 \end_inset
23006
23007  File menu entry.
23008  
23009 \end_layout
23010
23011 \begin_layout Standard
23012 \SpecialChar LyX
23013  has a range of buttons that are available for tool bar customization.
23014  In my toolbar I like to combine the six short cuts above with two more:
23015  One for 
23016 \family sans
23017 Document
23018 \family default
23019 \SpecialChar menuseparator
23020
23021 \family sans
23022 Update
23023 \family default
23024 \SpecialChar menuseparator
23025
23026 \family sans
23027 DVI
23028 \family default
23029  and the other for 
23030 \family sans
23031 Document\SpecialChar menuseparator
23032 View\SpecialChar menuseparator
23033 DVI
23034 \family default
23035  File menu entries.
23036  Here is how it looks like:
23037 \end_layout
23038
23039 \begin_layout LyX-Code
23040 Toolbar
23041 \end_layout
23042
23043 \begin_layout LyX-Code
23044   Layouts
23045 \end_layout
23046
23047 \begin_layout LyX-Code
23048   Icon "layout Standard"
23049 \end_layout
23050
23051 \begin_layout LyX-Code
23052   Icon "layout Section"
23053 \end_layout
23054
23055 \begin_layout LyX-Code
23056   Icon "layout \SpecialChar LaTeX
23057 "
23058 \end_layout
23059
23060 \begin_layout LyX-Code
23061   Icon "layout \SpecialChar LyX
23062 -Code"
23063 \end_layout
23064
23065 \begin_layout LyX-Code
23066   Icon "layout Chunk"
23067 \end_layout
23068
23069 \begin_layout LyX-Code
23070   Separator
23071 \end_layout
23072
23073 \begin_layout LyX-Code
23074   Icon "buffer-view"
23075 \end_layout
23076
23077 \begin_layout LyX-Code
23078   Icon "buffer-typeset"
23079 \end_layout
23080
23081 \begin_layout LyX-Code
23082   Icon "build-program"
23083 \end_layout
23084
23085 \begin_layout LyX-Code
23086   Separator
23087 \end_layout
23088
23089 \begin_layout LyX-Code
23090 .
23091 \end_layout
23092
23093 \begin_layout LyX-Code
23094 .
23095 \end_layout
23096
23097 \begin_layout LyX-Code
23098 .
23099 \end_layout
23100
23101 \begin_layout LyX-Code
23102 End
23103 \end_layout
23104
23105 \begin_layout Subsubsection
23106 Colors customization
23107 \end_layout
23108
23109 \begin_layout Standard
23110 There are a number of colors in \SpecialChar LyX
23111  that can be customized in 
23112 \family sans
23113 Preferences
23114 \family default
23115 .
23116  One of the things that bothers people is the \SpecialChar LaTeX
23117  font color.
23118  The default color is red, since the chunks uses \SpecialChar LaTeX
23119  font, and there is a lot
23120  of chunks in literate documents, you may get tired of seeing everything
23121  in red.
23122  You can change it by going to the tabs 
23123 \family sans
23124 Look&Feel
23125 \family default
23126
23127 \family sans
23128 Colors.
23129 \end_layout
23130
23131 \begin_layout Standard
23132 The next thing is the visible presence of the newline character in the screen.
23133  You can choose the color of this particular character and make it blend
23134  in the background.
23135  I recommend you choosing a color that is close to the background but not
23136  equal, that way you still can see it is there, but it is not bothering
23137  you anymore.
23138 \end_layout
23139
23140 \begin_layout Subsection
23141 \SpecialChar LyX
23142  and knitr/Sweave
23143 \end_layout
23144
23145 \begin_layout Standard
23146 Support for 
23147 \family sans
23148 knitr
23149 \family default
23150  and 
23151 \family sans
23152 Sweave
23153 \family default
23154  is documented in the 
23155 \emph on
23156 knitr.lyx
23157 \emph default
23158  example file and in the Sweave manual (menu 
23159 \family sans
23160 Help\SpecialChar menuseparator
23161 Specific Manuals
23162 \family default
23163 ).
23164 \end_layout
23165
23166 \begin_layout Chapter
23167 \SpecialChar LyX
23168  Archives
23169 \end_layout
23170
23171 \begin_layout Standard
23172 Users sometimes need to be able to 
23173 \begin_inset Quotes eld
23174 \end_inset
23175
23176 bundle
23177 \begin_inset Quotes erd
23178 \end_inset
23179
23180  a \SpecialChar LyX
23181  file together with all the images (and other files) on which it depends,
23182  either for sending to a publisher or for sharing with a co-author.
23183  \SpecialChar LyX
23184  2.0 includes a Python script (
23185 \begin_inset Flex Code
23186 status collapsed
23187
23188 \begin_layout Plain Layout
23189 lyxpak.py
23190 \end_layout
23191
23192 \end_inset
23193
23194 ) that automates this process.
23195  To use it, you must have either the 
23196 \begin_inset Flex Code
23197 status collapsed
23198
23199 \begin_layout Plain Layout
23200 zipfile
23201 \end_layout
23202
23203 \end_inset
23204
23205  or 
23206 \begin_inset Flex Code
23207 status collapsed
23208
23209 \begin_layout Plain Layout
23210 tarfile
23211 \end_layout
23212
23213 \end_inset
23214
23215  python modules installed on your system.
23216  By default, the script prefers the 
23217 \begin_inset Flex Code
23218 status collapsed
23219
23220 \begin_layout Plain Layout
23221 gzip
23222 \end_layout
23223
23224 \end_inset
23225
23226 -compressed 
23227 \begin_inset Flex Code
23228 status collapsed
23229
23230 \begin_layout Plain Layout
23231 tar
23232 \end_layout
23233
23234 \end_inset
23235
23236  format on Unix-like systems and the 
23237 \begin_inset Flex Code
23238 status collapsed
23239
23240 \begin_layout Plain Layout
23241 zip
23242 \end_layout
23243
23244 \end_inset
23245
23246  format on Windows.
23247 \end_layout
23248
23249 \begin_layout Standard
23250 \SpecialChar LyX
23251 's configuration process will set the script up to export a `\SpecialChar LyX
23252  Archive',
23253  and this format will then be available under 
23254 \begin_inset Flex Code
23255 status collapsed
23256
23257 \begin_layout Plain Layout
23258 File\SpecialChar menuseparator
23259 Export
23260 \end_layout
23261
23262 \end_inset
23263
23264 .
23265 \end_layout
23266
23267 \begin_layout Standard
23268 Independently of the platform, the generation of a particular archive format
23269  can be forced by adding either the 
23270 \begin_inset Flex Code
23271 status collapsed
23272
23273 \begin_layout Plain Layout
23274 -t
23275 \end_layout
23276
23277 \end_inset
23278
23279  (for the 
23280 \begin_inset Flex Code
23281 status collapsed
23282
23283 \begin_layout Plain Layout
23284 tar
23285 \end_layout
23286
23287 \end_inset
23288
23289  format) or 
23290 \begin_inset Flex Code
23291 status collapsed
23292
23293 \begin_layout Plain Layout
23294 -z
23295 \end_layout
23296
23297 \end_inset
23298
23299  (for the 
23300 \begin_inset Flex Code
23301 status collapsed
23302
23303 \begin_layout Plain Layout
23304 zip
23305 \end_layout
23306
23307 \end_inset
23308
23309  format) switch to the 
23310 \begin_inset Flex Code
23311 status collapsed
23312
23313 \begin_layout Plain Layout
23314 \SpecialChar LyX
23315 \SpecialChar menuseparator
23316 \SpecialChar LyX
23317  Archive
23318 \end_layout
23319
23320 \end_inset
23321
23322  converter in 
23323 \begin_inset Flex Code
23324 status collapsed
23325
23326 \begin_layout Plain Layout
23327 Tools\SpecialChar menuseparator
23328 Preferences\SpecialChar menuseparator
23329 File Handling\SpecialChar menuseparator
23330 Converters
23331 \end_layout
23332
23333 \end_inset
23334
23335 .
23336  (Make sure you add the switch after the script name, not before it.)
23337 \end_layout
23338
23339 \begin_layout Chapter
23340 \SpecialChar LyX
23341  and the World Wide Web
23342 \end_layout
23343
23344 \begin_layout Standard
23345 \SpecialChar LyX
23346  has long supported the export of documents to various web-friendly formats,
23347  such as HTML.
23348  Before verson 2.0, however, HTML export was always accomplished by the use
23349  of external converters.
23350 \begin_inset Foot
23351 status collapsed
23352
23353 \begin_layout Plain Layout
23354 For details on the use of external converters with \SpecialChar LyX
23355 , see the 
23356 \emph on
23357 Converters
23358 \emph default
23359  section of the Customization manual.
23360 \end_layout
23361
23362 \end_inset
23363
23364  These fall into two large groups: there are converters that use \SpecialChar LaTeX
23365  as an
23366  intermediate format, such as 
23367 \begin_inset Flex Code
23368 status collapsed
23369
23370 \begin_layout Plain Layout
23371 htlatex
23372 \end_layout
23373
23374 \end_inset
23375
23376
23377 \begin_inset Flex Code
23378 status collapsed
23379
23380 \begin_layout Plain Layout
23381 html2latex
23382 \end_layout
23383
23384 \end_inset
23385
23386 , and 
23387 \begin_inset Flex Code
23388 status collapsed
23389
23390 \begin_layout Plain Layout
23391 plastex
23392 \end_layout
23393
23394 \end_inset
23395
23396 , relying upon \SpecialChar LyX
23397  to produce the \SpecialChar LaTeX
23398 ; and there is a converter that works directly
23399  on \SpecialChar LyX
23400  files, 
23401 \begin_inset Flex Code
23402 status collapsed
23403
23404 \begin_layout Plain Layout
23405 e\SpecialChar LyX
23406 er
23407 \end_layout
23408
23409 \end_inset
23410
23411 .
23412  All of these have different advantages and disadvantages.
23413  
23414 \end_layout
23415
23416 \begin_layout Standard
23417 The \SpecialChar LaTeX
23418 -based converters have the advantage that, in principle, they know everythin
23419 g about the exported document that \SpecialChar LaTeX
23420  does.
23421  Such converters do not care, for example, if a certain block of code was
23422  produced by \SpecialChar LyX
23423  or was Evil Red Text.
23424  These converters know about 
23425 \begin_inset Flex Code
23426 status collapsed
23427
23428 \begin_layout Plain Layout
23429 aux
23430 \end_layout
23431
23432 \end_inset
23433
23434  files, counters, and references, and can often make use of the 
23435 \begin_inset Flex Code
23436 status collapsed
23437
23438 \begin_layout Plain Layout
23439 bbl
23440 \end_layout
23441
23442 \end_inset
23443
23444  files generated by Bib\SpecialChar TeX
23445 .
23446  On the other hand, \SpecialChar LaTeX
23447  is a very hard language to parse—it is sometimes said
23448  that only \SpecialChar TeX
23449  itself understands \SpecialChar TeX
23450 —and \SpecialChar LaTeX
23451 -based converters will often choke on
23452  what seem to be quite simple constructs; complex ones can throw them completely
23453 , and as of this writing, for example, the 
23454 \emph on
23455 Embedded Objects
23456 \emph default
23457  manual will not export with 
23458 \begin_inset Flex Code
23459 status collapsed
23460
23461 \begin_layout Plain Layout
23462 htlatex
23463 \end_layout
23464
23465 \end_inset
23466
23467 , though the others will.
23468  The other issue concerns how math is handled.
23469  These converters typically convert the formulae into little pictures that
23470  are then linked from the HTML document.
23471  Since these are actually generated by \SpecialChar LaTeX
23472 , they are accurate.
23473  But they do not scale well, and just getting them to look as if they are
23474  actually meant to be in your document—so that the font sizes seem to be
23475  roughly the same—can be a challenge.
23476 \end_layout
23477
23478 \begin_layout Standard
23479 Alex Fernandez's 
23480 \begin_inset Flex Code
23481 status collapsed
23482
23483 \begin_layout Plain Layout
23484 e\SpecialChar LyX
23485 er
23486 \end_layout
23487
23488 \end_inset
23489
23490  (
23491 \begin_inset CommandInset href
23492 LatexCommand href
23493 name "http://elyxer.nongnu.org/"
23494 target "http://elyxer.nongnu.org/"
23495
23496 \end_inset
23497
23498 ) solves some of these problems.
23499  In particular, the formulae it produces scale perfectly, since it renders
23500  math using a combination of HTML and CSS rather than converting the formulae
23501  to images.
23502  But even moderately complex formula are rendered less well than with 
23503 \begin_inset Flex Code
23504 status collapsed
23505
23506 \begin_layout Plain Layout
23507 htlatex
23508 \end_layout
23509
23510 \end_inset
23511
23512 ; this reflects the limitations of HTML.
23513 \begin_inset Foot
23514 status collapsed
23515
23516 \begin_layout Plain Layout
23517 That said, 
23518 \begin_inset Flex Code
23519 status collapsed
23520
23521 \begin_layout Plain Layout
23522 e\SpecialChar LyX
23523 er
23524 \end_layout
23525
23526 \end_inset
23527
23528  can also use jsMath and MathJax for equations, but this setting is only
23529  available globally and requires one to have access to a server that runs
23530  the backend.
23531 \end_layout
23532
23533 \end_inset
23534
23535  More importantly (as of version 1.1.1, at least), 
23536 \begin_inset Flex Code
23537 status collapsed
23538
23539 \begin_layout Plain Layout
23540 e\SpecialChar LyX
23541 er
23542 \end_layout
23543
23544 \end_inset
23545
23546  has limited support for math macros and no support for user-defined paragraph
23547  or character styles.
23548  These limitations make 
23549 \begin_inset Flex Code
23550 status collapsed
23551
23552 \begin_layout Plain Layout
23553 e\SpecialChar LyX
23554 er
23555 \end_layout
23556
23557 \end_inset
23558
23559  unsuitable for many of the documents \SpecialChar LyX
23560  users produce.
23561  In principle, of course, these problems could be solved, but the \SpecialChar LyX
23562  developers
23563  have decided to follow a different path and have made \SpecialChar LyX
23564  itself capable of
23565  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
23566 , DocBook, and plaintext.
23567 \end_layout
23568
23569 \begin_layout Standard
23570 As of this writing, XHTML output remains under development and should probably
23571  be regarded as 
23572 \begin_inset Quotes eld
23573 \end_inset
23574
23575 experimental
23576 \begin_inset Quotes erd
23577 \end_inset
23578
23579 .
23580 \begin_inset Foot
23581 status collapsed
23582
23583 \begin_layout Plain Layout
23584 The file 
23585 \begin_inset Flex Code
23586 status collapsed
23587
23588 \begin_layout Plain Layout
23589 development/HTML.notes
23590 \end_layout
23591
23592 \end_inset
23593
23594 , which can be found in the \SpecialChar LyX
23595  source tree or 
23596 \begin_inset CommandInset href
23597 LatexCommand href
23598 name "accessed online"
23599 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
23600
23601 \end_inset
23602
23603 , usually contains up-to-date information about the state of XHTML output.
23604  See also the list of XHTML bugs on 
23605 \begin_inset CommandInset href
23606 LatexCommand href
23607 name "the bug tracker"
23608 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"
23609
23610 \end_inset
23611
23612 .
23613 \end_layout
23614
23615 \end_inset
23616
23617  Still, the developers have chosen this approach because it has several
23618  potential advantages over the other two.
23619 \end_layout
23620
23621 \begin_layout Standard
23622 These advantages are primarily due to the fact that the XHTML output routines,
23623  since they are part of \SpecialChar LyX
23624 , know everything \SpecialChar LyX
23625  knows about the document being
23626  exported.
23627 \begin_inset Foot
23628 status collapsed
23629
23630 \begin_layout Plain Layout
23631 Another advantage is that, since these routines are internal to \SpecialChar LyX
23632 , they are
23633  immune to changes in \SpecialChar LyX
23634 's file format, or to changes in the semantics of
23635  existing insets.
23636 \end_layout
23637
23638 \end_inset
23639
23640  So they know about the table of contents (as displayed in the outline),
23641  about the counters associated with different paragraph styles, and about
23642  user-defined styles.
23643  The XHTML output routines know what \SpecialChar LyX
23644  knows about internationalization,
23645  too, so they will output 
23646 \begin_inset Quotes eld
23647 \end_inset
23648
23649 Chapter 1
23650 \begin_inset Quotes erd
23651 \end_inset
23652
23653  or 
23654 \begin_inset Quotes eld
23655 \end_inset
23656
23657
23658 \lang ngerman
23659 Kapitel
23660 \lang english
23661  1
23662 \begin_inset Quotes erd
23663 \end_inset
23664
23665 , depending upon the language in effect at the time.
23666  
23667 \end_layout
23668
23669 \begin_layout Standard
23670 Quite generally, the output routines know what \SpecialChar LyX
23671  knows about document layout,
23672  that is, about how the document is to be rendered on screen.
23673  We use this information when we output the document as XHTML.
23674  In particular, \SpecialChar LyX
23675  
23676 \emph on
23677 automatically
23678 \emph default
23679  generates CSS style information corresponding to the layout information
23680  it uses to render the document on screen: if section headings are supposed
23681  to be sans-serif and bold as seen in \SpecialChar LyX
23682 , then (by default) they will be sans-seri
23683 f and bold when viewed in a web browser, too.
23684  And this is true not just for pre-defined styles, like Section, but for
23685  any style, including user-defined styles.
23686  Indeed, the XHTML output routines make no distinction between user-defined
23687  paragraph and character styles and \SpecialChar LyX
23688 's own pre-defined styles: in each case,
23689  everything \SpecialChar LyX
23690  knows about the styles is contained in the layout files.
23691  And much the same is true as regards pre-defined textual insets, such as
23692  footnotes, and various custom insets.
23693  
23694 \end_layout
23695
23696 \begin_layout Standard
23697 The result is that XHTML output can be customized and extended in exactly
23698  the same way \SpecialChar LaTeX
23699  output can be customized and extended: through layout files
23700  and modules.
23701  See chapter five of the 
23702 \emph on
23703 Customization 
23704 \emph default
23705 manual for the details.
23706 \end_layout
23707
23708 \begin_layout Standard
23709 The remainder of this chapter contains more detailed information on XHTML
23710  output, its limitations, and ways to work around those limitations.
23711 \end_layout
23712
23713 \begin_layout Section
23714 Math Output in XHTML
23715 \end_layout
23716
23717 \begin_layout Standard
23718 \SpecialChar LyX
23719  offers four choices for how math is rendered.
23720  These have various advantages and disadvantages:
23721 \end_layout
23722
23723 \begin_layout Itemize
23724 MathML
23725 \begin_inset Newline newline
23726 \end_inset
23727
23728 MathML is a dialect of XML designed specifically for mathematics on the
23729  web, and it typically renders very well in browsers that support it.
23730  The disadvantage is that not all browsers support MathML, and support is
23731  not complete even in the Gecko-based browsers, such as Firefox.
23732 \begin_inset Newline newline
23733 \end_inset
23734
23735 If \SpecialChar LyX
23736  is unable to render a formula as MathML—for example, if the formula
23737  uses the 
23738 \begin_inset Flex Code
23739 status collapsed
23740
23741 \begin_layout Plain Layout
23742 xymatrix
23743 \end_layout
23744
23745 \end_inset
23746
23747  package or ERT—then it will instead output the formula as an image.
23748  
23749 \end_layout
23750
23751 \begin_layout Itemize
23752 HTML
23753 \begin_inset Newline newline
23754 \end_inset
23755
23756 As mentioned above, 
23757 \begin_inset Flex Code
23758 status collapsed
23759
23760 \begin_layout Plain Layout
23761 elyxer
23762 \end_layout
23763
23764 \end_inset
23765
23766  outputs math as HTML, styled by CSS.
23767 \begin_inset Foot
23768 status collapsed
23769
23770 \begin_layout Plain Layout
23771 \SpecialChar LyX
23772  has borrowed some of the CSS for its HTML output from 
23773 \begin_inset Flex Code
23774 status collapsed
23775
23776 \begin_layout Plain Layout
23777 elyxer
23778 \end_layout
23779
23780 \end_inset
23781
23782 .
23783 \end_layout
23784
23785 \end_inset
23786
23787  For simple formulae, this can work quite well, though with more complicated
23788  formulae it tends to break down.
23789  Still, this method has the advantage that it is very widely supported and
23790  so it may be appropriate for documents that contain only a little, fairly
23791  simple math.
23792 \begin_inset Newline newline
23793 \end_inset
23794
23795 If Lyx is unable to render a formula as HTML—for example, if the formula
23796  uses the 
23797 \begin_inset Flex Code
23798 status collapsed
23799
23800 \begin_layout Plain Layout
23801 xymatrix
23802 \end_layout
23803
23804 \end_inset
23805
23806  package or ERT—then it will instead output the formula as an image.
23807  
23808 \end_layout
23809
23810 \begin_layout Itemize
23811 Images
23812 \begin_inset Newline newline
23813 \end_inset
23814
23815 Like 
23816 \begin_inset Flex Code
23817 status collapsed
23818
23819 \begin_layout Plain Layout
23820 htlatex
23821 \end_layout
23822
23823 \end_inset
23824
23825 , \SpecialChar LyX
23826  will output formulae as images, the very same images, in fact, that are
23827  used for instant preview.
23828 \begin_inset Foot
23829 status collapsed
23830
23831 \begin_layout Plain Layout
23832 Instant preview does 
23833 \emph on
23834 not 
23835 \emph default
23836 have to be on for images to be output, however.
23837 \end_layout
23838
23839 \end_inset
23840
23841  The advantage to this method is that the images are simply generated by
23842  \SpecialChar LaTeX
23843 , so they are very accurate.
23844  The disadvantage, as mentioned earlier, is that these are bitmapped images,
23845  so they do not scale terribly well, and one cannot copy them, etc.
23846  (As of this writing, there are also problems about equation numbering.
23847  See 
23848 \begin_inset CommandInset href
23849 LatexCommand href
23850 name "bug 6894"
23851 target "http://www.lyx.org/trac/ticket/6894"
23852
23853 \end_inset
23854
23855 .)
23856 \begin_inset Newline newline
23857 \end_inset
23858
23859 The size of the images can be controlled by setting the 
23860 \begin_inset Quotes eld
23861 \end_inset
23862
23863 Math Images Scaling
23864 \begin_inset Quotes erd
23865 \end_inset
23866
23867  parameter under 
23868 \begin_inset Flex Noun
23869 status collapsed
23870
23871 \begin_layout Plain Layout
23872 Document\SpecialChar menuseparator
23873 Settings\SpecialChar menuseparator
23874 Output
23875 \end_layout
23876
23877 \end_inset
23878
23879 .
23880 \begin_inset Foot
23881 status collapsed
23882
23883 \begin_layout Plain Layout
23884 For those who want to know, this controls the resolution of the image in
23885  dots per inch and is based upon a default of 75 dpi.
23886 \end_layout
23887
23888 \end_inset
23889
23890
23891 \begin_inset Newline newline
23892 \end_inset
23893
23894 If \SpecialChar LyX
23895  for some reason fails to create an image for a formula (e.g., if a required
23896  \SpecialChar LaTeX
23897  package is not installed), then it will fall back to outputing the raw
23898  \SpecialChar LaTeX
23899 .
23900 \end_layout
23901
23902 \begin_layout Itemize
23903 \SpecialChar LaTeX
23904
23905 \begin_inset Newline newline
23906 \end_inset
23907
23908 Finally, \SpecialChar LyX
23909  will happily output math as \SpecialChar LaTeX
23910 .
23911  As well as being the output of last resort, this method can be used with
23912  such tools as 
23913 \begin_inset CommandInset href
23914 LatexCommand href
23915 name "jsMath"
23916 target "http://www.math.union.edu/~dpvc/jsMath/"
23917
23918 \end_inset
23919
23920 , which uses JavaScript to render \SpecialChar LaTeX
23921  embedded in HTML documents.
23922  \SpecialChar LyX
23923  wraps the \SpecialChar LaTeX
23924  in either a 
23925 \begin_inset Flex Code
23926 status collapsed
23927
23928 \begin_layout Plain Layout
23929 span
23930 \end_layout
23931
23932 \end_inset
23933
23934  (for inline formulas) or 
23935 \begin_inset Flex Code
23936 status collapsed
23937
23938 \begin_layout Plain Layout
23939 div
23940 \end_layout
23941
23942 \end_inset
23943
23944  (for displayed formulas) with 
23945 \begin_inset Flex Code
23946 status collapsed
23947
23948 \begin_layout Plain Layout
23949 class='math'
23950 \end_layout
23951
23952 \end_inset
23953
23954 , as is required for jsMath.
23955 \end_layout
23956
23957 \begin_layout Standard
23958 One of these output methods must be selected under 
23959 \begin_inset Flex Noun
23960 status collapsed
23961
23962 \begin_layout Plain Layout
23963 Document\SpecialChar menuseparator
23964 Settings\SpecialChar menuseparator
23965 Output
23966 \end_layout
23967
23968 \end_inset
23969
23970 .
23971  By default, \SpecialChar LyX
23972  outputs MathML.
23973  This is a document-wide setting, therefore.
23974 \end_layout
23975
23976 \begin_layout Standard
23977 Eventually, \SpecialChar LyX
23978  will offer the user the option to select an alternate output
23979  method for a particular inset, say, one that isn't being rendered very
23980  well by MathML.
23981 \begin_inset Foot
23982 status collapsed
23983
23984 \begin_layout Plain Layout
23985 That said, since \SpecialChar LyX
23986  falls back to images if the inset contains ERT, then one
23987  can force output as an image by putting some harmless ERT into the math,
23988  for example: 
23989 \begin_inset Formula $a=b\relax$
23990 \end_inset
23991
23992 .
23993 \end_layout
23994
23995 \end_inset
23996
23997
23998 \end_layout
23999
24000 \begin_layout Section
24001 Bibliography and Citations
24002 \end_layout
24003
24004 \begin_layout Standard
24005 XHTML output fully supports bibliographies and citations.
24006  
24007 \end_layout
24008
24009 \begin_layout Standard
24010 Citation labels are generated by the same machinery that generates \SpecialChar LyX
24011 's on-screen
24012  labels, so the labels will look in the output much as they do in \SpecialChar LyX
24013 , though
24014  better.
24015  If you are using numerical citations, then \SpecialChar LyX
24016  will output numerical labels,
24017  such as [1] or [17], rather than simply showing the citation key in square
24018  brackets, as it does on-screen.
24019  If you are using author-year citations, then \SpecialChar LyX
24020  will add lowercase letters
24021  to the years, just as Bib\SpecialChar TeX
24022  does, if it finds more than one citation for
24023  a given author-year combination.
24024  The labels will be printed with the bibliography entries.
24025  Note that there is, at present, no way to customize the appearance of the
24026  labels, for example, to choose between square brackets and parentheses.
24027 \end_layout
24028
24029 \begin_layout Standard
24030 Bibliography output is handled by the same machinery that handles the presentati
24031 on of reference information in the citation dialog, so you will see in the
24032  XHTML output pretty much what you would see if you were to look at a given
24033  entry in the citation dialog.
24034  The formatting can be customized in your layout file or, preferably, in
24035  a module.
24036  See the 
24037 \emph on
24038 Customization
24039 \emph default
24040  manual for the details.
24041 \end_layout
24042
24043 \begin_layout Standard
24044 The main defect at present is that cross-referenced information is printed
24045  with every entry with which it is associated.
24046  So you can see things like this:
24047 \end_layout
24048
24049 \begin_layout Quote
24050 Jason Stanley, 
24051 \begin_inset Quotes eld
24052 \end_inset
24053
24054 Context and Logical Form
24055 \begin_inset Quotes erd
24056 \end_inset
24057
24058 , in 
24059 \emph on
24060 Language in Context: Selected Essays
24061 \emph default
24062  (Oxford: Oxford University Press, 2007), pp.
24063  30–68.
24064 \end_layout
24065
24066 \begin_layout Quote
24067 Jason Stanley, 
24068 \begin_inset Quotes eld
24069 \end_inset
24070
24071 Semantics in Context
24072 \begin_inset Quotes erd
24073 \end_inset
24074
24075 , in 
24076 \emph on
24077 Language in Context: Selected Essays
24078 \emph default
24079  (Oxford: Oxford University Press, 2007), pp.
24080  201–30.
24081 \end_layout
24082
24083 \begin_layout Standard
24084 This should be fixed before long.
24085 \end_layout
24086
24087 \begin_layout Standard
24088 There is no support at present for sectioned bibliographies.
24089  If you have multiple bibliographies, then \SpecialChar LyX
24090  will print the same bibliography
24091  over and over.
24092 \end_layout
24093
24094 \begin_layout Section
24095 Indexes
24096 \end_layout
24097
24098 \begin_layout Standard
24099 \SpecialChar LyX
24100  will happily export indexes as XHTML, but with certain limitations at the
24101  moment.
24102 \end_layout
24103
24104 \begin_layout Standard
24105 Index export will be most reliable when you do not attempt to use the fancy
24106  constructs that are described in the section on indexes in the 
24107 \emph on
24108 User's Guide
24109 \emph default
24110 .
24111 \begin_inset Foot
24112 status collapsed
24113
24114 \begin_layout Plain Layout
24115 The main issue here is that \SpecialChar LyX
24116  itself does not really handle these.
24117  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
24118 .
24119 \end_layout
24120
24121 \end_inset
24122
24123  We'll describe how they are handled using the subsection headings from
24124  that section.
24125 \end_layout
24126
24127 \begin_layout Itemize
24128 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
24129  makes an effort to support these,
24130  but the entries must be separated by 
24131 \begin_inset Quotes eld
24132 \end_inset
24133
24134  ! 
24135 \begin_inset Quotes erd
24136 \end_inset
24137
24138 , that is, there must be spaces around the exclamation point.
24139  This is because it is otherwise too difficult to check for escaped exclamation
24140  points, ones in math, and so forth.
24141 \end_layout
24142
24143 \begin_layout Itemize
24144 Page Ranges: There is no support at all for page ranges, since these make
24145  no sense with XHMTL.
24146  Instead, you will just get two index entries, one at either end.
24147 \end_layout
24148
24149 \begin_layout Itemize
24150 Cross-referencing: There is no support for cross-referencing.
24151  If \SpecialChar LyX
24152  finds an entry containing the 
24153 \begin_inset Quotes eld
24154 \end_inset
24155
24156 |see\SpecialChar ldots
24157
24158 \begin_inset Quotes erd
24159 \end_inset
24160
24161  construct, it is just dropped, and the rest is treated as an ordinary index
24162  entry.
24163 \end_layout
24164
24165 \begin_layout Itemize
24166 Index Entry Order: \SpecialChar LyX
24167  does support attempts to fix the sorting order.
24168  It will take what is before the first `@' it finds and use that for sorting,
24169  taking what follows the first `@' to be the actual entry.
24170  At present, \SpecialChar LyX
24171  does not check for escaped `@', so do not try to index email
24172  addresses.
24173 \end_layout
24174
24175 \begin_layout Itemize
24176 Index Entry Layout: You can format entries by using the text style dialog,
24177  or by using any other method available within \SpecialChar LyX
24178  itself.
24179  There is no support for constructs like: 
24180 \begin_inset Quotes eld
24181 \end_inset
24182
24183 entry|textbf
24184 \begin_inset Quotes erd
24185 \end_inset
24186
24187 .
24188  Indeed, if \SpecialChar LyX
24189  finds a pipe symbol, `|', in an entry, it will delete it and
24190  everything that follows it.
24191 \end_layout
24192
24193 \begin_layout Itemize
24194 Multiple Indexes: There is no support for multiple indexes.
24195  Rather, all index entries will be printed as one large index.
24196  To avoid our printing several versions of the index, we print only the
24197  main index, so make sure you have one.
24198 \end_layout
24199
24200 \begin_layout Section
24201 Nomenclature and Glossary
24202 \end_layout
24203
24204 \begin_layout Standard
24205 There is at present no support for glossaries.
24206  Adding it would be fairly trivial, and welcome.
24207 \end_layout
24208
24209 \begin_layout Chapter
24210 The \SpecialChar LyX
24211  Server
24212 \end_layout
24213
24214 \begin_layout Section
24215 Introduction
24216 \end_layout
24217
24218 \begin_layout Standard
24219 The `\SpecialChar LyX
24220  server' allows other programs to talk to \SpecialChar LyX
24221 , invoke \SpecialChar LyX
24222  commands, and retrieve
24223  information about the \SpecialChar LyX
24224  internal state.
24225  This is only intended for advanced users, but they should find it useful.
24226  It is by writing to the \SpecialChar LyX
24227  server, for example, that bibliography managers,
24228  such as JabRef, are able to 
24229 \begin_inset Quotes eld
24230 \end_inset
24231
24232 push
24233 \begin_inset Quotes erd
24234 \end_inset
24235
24236  citations to \SpecialChar LyX
24237 .
24238 \end_layout
24239
24240 \begin_layout Section
24241 Starting the \SpecialChar LyX
24242  Server
24243 \end_layout
24244
24245 \begin_layout Standard
24246 The \SpecialChar LyX
24247  server works through the use of a pair of named pipes.
24248  These are usually located in 
24249 \begin_inset Flex Code
24250 status collapsed
24251
24252 \begin_layout Plain Layout
24253 UserDir
24254 \end_layout
24255
24256 \end_inset
24257
24258 , (except on Windows, where 
24259 \emph on
24260 local
24261 \emph default
24262  named pipes are special objects located in 
24263 \begin_inset Flex Code
24264 status collapsed
24265
24266 \begin_layout Plain Layout
24267
24268 \backslash
24269
24270 \backslash
24271 .
24272 \backslash
24273 pipe
24274 \end_layout
24275
24276 \end_inset
24277
24278 ) and have the names 
24279 \begin_inset Quotes eld
24280 \end_inset
24281
24282
24283 \begin_inset Flex Code
24284 status collapsed
24285
24286 \begin_layout Plain Layout
24287 lyxpipe.in
24288 \end_layout
24289
24290 \end_inset
24291
24292
24293 \begin_inset Quotes erd
24294 \end_inset
24295
24296  and 
24297 \begin_inset Quotes eld
24298 \end_inset
24299
24300
24301 \begin_inset Flex Code
24302 status collapsed
24303
24304 \begin_layout Plain Layout
24305 lyxpipe.out
24306 \end_layout
24307
24308 \end_inset
24309
24310
24311 \begin_inset Quotes erd
24312 \end_inset
24313
24314 .
24315  External programs write into 
24316 \begin_inset Flex Code
24317 status collapsed
24318
24319 \begin_layout Plain Layout
24320 lyxpipe.in
24321 \end_layout
24322
24323 \end_inset
24324
24325  and read back data from 
24326 \begin_inset Flex Code
24327 status collapsed
24328
24329 \begin_layout Plain Layout
24330 lyxpipe.out
24331 \end_layout
24332
24333 \end_inset
24334
24335 .
24336  The stem of the pipe names can be defined in the 
24337 \begin_inset Flex Noun
24338 status collapsed
24339
24340 \begin_layout Plain Layout
24341 Tools\SpecialChar menuseparator
24342 Preferences
24343 \end_layout
24344
24345 \end_inset
24346
24347  dialog, for example 
24348 \begin_inset Flex Code
24349 status collapsed
24350
24351 \begin_layout Plain Layout
24352 "/home/myhome/lyxpipe"
24353 \end_layout
24354
24355 \end_inset
24356
24357 , or 
24358 \begin_inset Flex Code
24359 status collapsed
24360
24361 \begin_layout Plain Layout
24362 "
24363 \backslash
24364
24365 \backslash
24366 .
24367 \backslash
24368 pipe
24369 \backslash
24370 lyxpipe"
24371 \end_layout
24372
24373 \end_inset
24374
24375  on Windows (where any working path instead of lyxpipe can be used, for
24376  example 
24377 \begin_inset Flex Code
24378 status collapsed
24379
24380 \begin_layout Plain Layout
24381 "
24382 \backslash
24383
24384 \backslash
24385 .
24386 \backslash
24387 pipe
24388 \backslash
24389 my
24390 \backslash
24391 lyx
24392 \backslash
24393 pipe"
24394 \end_layout
24395
24396 \end_inset
24397
24398  would also work).
24399  You 
24400 \emph on
24401 must
24402 \emph default
24403  configure this manually in order for the server to start.
24404 \end_layout
24405
24406 \begin_layout Standard
24407 \SpecialChar LyX
24408  will add the '
24409 \begin_inset Flex Code
24410 status collapsed
24411
24412 \begin_layout Plain Layout
24413 .in
24414 \end_layout
24415
24416 \end_inset
24417
24418 ' and '
24419 \begin_inset Flex Code
24420 status collapsed
24421
24422 \begin_layout Plain Layout
24423 .out
24424 \end_layout
24425
24426 \end_inset
24427
24428 ' to create the pipes.
24429  If one of the pipes already exists, \SpecialChar LyX
24430  will assume that another \SpecialChar LyX
24431  process
24432  is already running and will not start the server.
24433  On POSIX (Unix like) systems, if for some other reason, an unused 
24434 \begin_inset Quotes eld
24435 \end_inset
24436
24437 stale
24438 \begin_inset Quotes erd
24439 \end_inset
24440
24441  pipe is left in existence when \SpecialChar LyX
24442  closes, then \SpecialChar LyX
24443  will try to delete it.
24444  If this fails for some reason, you will need to delete the pipes manually
24445  and then restart \SpecialChar LyX
24446 .
24447  On Windows, pipes are deleted by the OS on program termination or crash,
24448  so 
24449 \begin_inset Quotes eld
24450 \end_inset
24451
24452 stale
24453 \begin_inset Quotes erd
24454 \end_inset
24455
24456  pipes should not be possible.
24457 \end_layout
24458
24459 \begin_layout Standard
24460 To have several \SpecialChar LyX
24461  processes with servers at the same time, you have to use
24462  different configurations, perhaps by using separate user directories, each
24463  with its own 
24464 \begin_inset Flex Code
24465 status collapsed
24466
24467 \begin_layout Plain Layout
24468 preferences
24469 \end_layout
24470
24471 \end_inset
24472
24473  file, for each process.
24474 \end_layout
24475
24476 \begin_layout Standard
24477 If you are developing a client program, you might find it useful to enable
24478  debugging information from the \SpecialChar LyX
24479  server.
24480  Do this by starting \SpecialChar LyX
24481  as 
24482 \begin_inset Flex Code
24483 status collapsed
24484
24485 \begin_layout Plain Layout
24486 lyx -dbg lyxserver
24487 \end_layout
24488
24489 \end_inset
24490
24491 .
24492 \end_layout
24493
24494 \begin_layout Standard
24495 You can find a complete example client written in C++ in the source distribution
24496  as 
24497 \begin_inset Flex Code
24498 status collapsed
24499
24500 \begin_layout Plain Layout
24501 development/lyxserver/server_monitor.cpp
24502 \end_layout
24503
24504 \end_inset
24505
24506 .
24507 \end_layout
24508
24509 \begin_layout Standard
24510 Another useful tool is the command-line based client found in 
24511 \begin_inset Flex Code
24512 status collapsed
24513
24514 \begin_layout Plain Layout
24515 src/client/lyxclient
24516 \end_layout
24517
24518 \end_inset
24519
24520 .
24521 \end_layout
24522
24523 \begin_layout Section
24524 Normal communication
24525 \end_layout
24526
24527 \begin_layout Standard
24528 To issue a \SpecialChar LyX
24529  call, the client writes a line of ASCII text into the input
24530  pipe.
24531  This line has the following format:
24532 \end_layout
24533
24534 \begin_layout Quote
24535 LYXCMD:
24536 \emph on
24537 clientname
24538 \emph default
24539 :
24540 \emph on
24541 function
24542 \emph default
24543 :
24544 \emph on
24545 argument
24546 \end_layout
24547
24548 \begin_layout Description
24549 clientname is a name that the client can choose arbitrarily.
24550  Its only use is that \SpecialChar LyX
24551  will echo it if it sends an answer—so a client can
24552  dispatch results from different requesters.
24553 \end_layout
24554
24555 \begin_layout Description
24556 function is the function you want \SpecialChar LyX
24557  to perform.
24558  It is the same as the commands you'd use in the minibuffer.
24559 \end_layout
24560
24561 \begin_layout Description
24562 argument is an optional argument which is meaningful only to some functions
24563  (for instance, the 
24564 \begin_inset Quotes eld
24565 \end_inset
24566
24567 self-insert
24568 \begin_inset Quotes erd
24569 \end_inset
24570
24571  LFUN will insert the argument as text at the cursor position).
24572 \end_layout
24573
24574 \begin_layout Standard
24575 The answer from \SpecialChar LyX
24576  will arrive in the output pipe and be of the form
24577 \end_layout
24578
24579 \begin_layout Quote
24580 INFO:
24581 \emph on
24582 clientname
24583 \emph default
24584 :
24585 \emph on
24586 function
24587 \emph default
24588 :
24589 \emph on
24590 data
24591 \end_layout
24592
24593 \begin_layout Standard
24594 where 
24595 \emph on
24596 clientname
24597 \emph default
24598  and 
24599 \emph on
24600 function
24601 \emph default
24602  are just echoed from the command request, while 
24603 \emph on
24604 data
24605 \emph default
24606  is more or less useful information filled according to how the command
24607  execution worked out.
24608  Some commands, such as 
24609 \begin_inset Quotes eld
24610 \end_inset
24611
24612 font-state
24613 \begin_inset Quotes erd
24614 \end_inset
24615
24616 , will return information about the internal state of \SpecialChar LyX
24617 , while other will
24618  return an empty data-response.
24619  This means that the command execution went fine.
24620 \end_layout
24621
24622 \begin_layout Standard
24623 In case of errors, the response from \SpecialChar LyX
24624  will have this form
24625 \end_layout
24626
24627 \begin_layout Quote
24628 ERROR:
24629 \emph on
24630 clientname
24631 \emph default
24632 :
24633 \emph on
24634 function
24635 \emph default
24636 :
24637 \emph on
24638 error message
24639 \end_layout
24640
24641 \begin_layout Standard
24642 where the 
24643 \emph on
24644 error message
24645 \emph default
24646  should contain an explanation of why the command failed.
24647 \end_layout
24648
24649 \begin_layout Standard
24650 Examples:
24651 \end_layout
24652
24653 \begin_layout LyX-Code
24654 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
24655 \begin_inset Newline newline
24656 \end_inset
24657
24658 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
24659 \begin_inset Newline newline
24660 \end_inset
24661
24662 read a <~/.lyxpipe.out
24663 \begin_inset Newline newline
24664 \end_inset
24665
24666 echo $a
24667 \end_layout
24668
24669 \begin_layout Subsection
24670 AppleScript (Mac OS X)
24671 \end_layout
24672
24673 \begin_layout Standard
24674 Since \SpecialChar LyX
24675  2.1, \SpecialChar LyX
24676  supports basic interactions with AppleScript for normal communicatio
24677 n through the command run.
24678  This command takes a direct argument (the 
24679 \series bold
24680 function
24681 \series default
24682  to perform) and an optional argument.
24683  It either returns the output of the function or triggers an error with
24684  the error message and code.
24685 \end_layout
24686
24687 \begin_layout Standard
24688 Example:
24689 \end_layout
24690
24691 \begin_layout LyX-Code
24692 tell application "\SpecialChar LyX
24693 "
24694 \end_layout
24695
24696 \begin_layout LyX-Code
24697   try
24698 \end_layout
24699
24700 \begin_layout LyX-Code
24701     -- Stores the current file name into f
24702 \end_layout
24703
24704 \begin_layout LyX-Code
24705     set f to (run "server-get-filename" with argument "")
24706 \end_layout
24707
24708 \begin_layout LyX-Code
24709     on error the error_message number the error_number
24710 \end_layout
24711
24712 \begin_layout LyX-Code
24713       display dialog "Error: " & the error_number & ".
24714  " ¬
24715 \end_layout
24716
24717 \begin_layout LyX-Code
24718               & the error_message buttons {"OK"} default button 1
24719 \end_layout
24720
24721 \begin_layout LyX-Code
24722   end try
24723 \end_layout
24724
24725 \begin_layout LyX-Code
24726 end tell
24727 \end_layout
24728
24729 \begin_layout Section
24730 Notification
24731 \end_layout
24732
24733 \begin_layout Standard
24734 \SpecialChar LyX
24735  can notify clients of events going on asynchronously.
24736  Currently it will only do this if the user binds a key sequence with the
24737  function 
24738 \begin_inset Quotes eld
24739 \end_inset
24740
24741 notify
24742 \begin_inset Quotes erd
24743 \end_inset
24744
24745 .
24746  The format of the string \SpecialChar LyX
24747  sends is as follows:
24748 \end_layout
24749
24750 \begin_layout Quote
24751 \begin_inset Flex Code
24752 status collapsed
24753
24754 \begin_layout Plain Layout
24755 NOTIFY:
24756 \end_layout
24757
24758 \end_inset
24759
24760
24761 \emph on
24762 key-sequence
24763 \end_layout
24764
24765 \begin_layout Standard
24766 where 
24767 \emph on
24768 key-sequence
24769 \emph default
24770  is the printed representation of the key sequence that was actually typed
24771  by the user.
24772 \end_layout
24773
24774 \begin_layout Standard
24775 This mechanism can be used to extend \SpecialChar LyX
24776 's command set and implement macros.
24777  Bind some key sequence to 
24778 \begin_inset Quotes eld
24779 \end_inset
24780
24781 notify
24782 \begin_inset Quotes erd
24783 \end_inset
24784
24785 .
24786  Then start a client that listens on the output pipe, dispatches the command
24787  according to the sequence, and starts a function that may use \SpecialChar LyX
24788  calls and
24789  \SpecialChar LyX
24790  requests to issue a command or a series of commands to \SpecialChar LyX
24791 .
24792 \end_layout
24793
24794 \begin_layout Section
24795 The simple \SpecialChar LyX
24796  Server Protocol
24797 \end_layout
24798
24799 \begin_layout Standard
24800 \SpecialChar LyX
24801  implements a simple protocol that can be used for session management.
24802  All messages are of the form
24803 \end_layout
24804
24805 \begin_layout Quote
24806 LYXSRV:
24807 \emph on
24808 clientname
24809 \emph default
24810 :
24811 \emph on
24812 protocol message
24813 \end_layout
24814
24815 \begin_layout Standard
24816 where 
24817 \emph on
24818 protocol message
24819 \emph default
24820  can be 
24821 \begin_inset Quotes eld
24822 \end_inset
24823
24824 hello
24825 \begin_inset Quotes erd
24826 \end_inset
24827
24828  or 
24829 \begin_inset Quotes eld
24830 \end_inset
24831
24832 bye
24833 \begin_inset Quotes erd
24834 \end_inset
24835
24836 .
24837  If 
24838 \begin_inset Quotes eld
24839 \end_inset
24840
24841 hello
24842 \begin_inset Quotes erd
24843 \end_inset
24844
24845  is received from a client, \SpecialChar LyX
24846  will report back to inform the client that
24847  it's listening to it's messages, while 
24848 \begin_inset Quotes eld
24849 \end_inset
24850
24851 bye
24852 \begin_inset Quotes erd
24853 \end_inset
24854
24855  sent from \SpecialChar LyX
24856  will inform clients that \SpecialChar LyX
24857  is closing.
24858 \end_layout
24859
24860 \begin_layout Section
24861 Reverse DVI/PDF search
24862 \end_layout
24863
24864 \begin_layout Standard
24865 Some DVI/PDF viewers
24866 \begin_inset Foot
24867 status collapsed
24868
24869 \begin_layout Plain Layout
24870 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
24871  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
24872 \end_layout
24873
24874 \end_inset
24875
24876  provide 
24877 \emph on
24878 reverse search
24879 \emph default
24880  facility (also called 
24881 \emph on
24882 inverse search
24883 \emph default
24884 ).
24885  This means that you can tell \SpecialChar LyX
24886  to put the cursor to a specific line in the
24887  document by clicking at the respective position in the DVI/PDF output.
24888  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
24889 .
24890  This is done via the \SpecialChar LyX
24891  server either by using the named pipe (
24892 \emph on
24893 lyxpipe
24894 \emph default
24895 ), or the UNIX domain socket (
24896 \emph on
24897 lyxsocket
24898 \emph default
24899 ) that \SpecialChar LyX
24900  creates in its temporary directory (this is the way the 
24901 \begin_inset Flex Code
24902 status collapsed
24903
24904 \begin_layout Plain Layout
24905 lyxclient
24906 \end_layout
24907
24908 \end_inset
24909
24910  program communicates with \SpecialChar LyX
24911 ).
24912  In some cases, you need a helper script that mediates between the viewer
24913  and \SpecialChar LyX
24914 , in others, the viewer can communicate with \SpecialChar LyX
24915  directly.
24916  This depends on the selected viewer and on your operating system.
24917  The same applies to the way viewers need to be configured and the way the
24918  reverse search is actually performed.
24919  In what follows, we will thus describe how to setup reverse search for
24920  specific viewers.
24921  Before we turn to this, though, we will explain what needs to be done generally
24922  to enable reverse search in the DVI/PDF output.
24923 \end_layout
24924
24925 \begin_layout Subsection
24926 Automatic setup
24927 \begin_inset CommandInset label
24928 LatexCommand label
24929 name "subsec:rev-search"
24930
24931 \end_inset
24932
24933
24934 \end_layout
24935
24936 \begin_layout Standard
24937 In most cases \SpecialChar LyX
24938  will do the work for you by enabling the option 
24939 \begin_inset Flex Noun
24940 status collapsed
24941
24942 \begin_layout Plain Layout
24943 Synchronize with Output
24944 \end_layout
24945
24946 \end_inset
24947
24948  in the menu 
24949 \begin_inset Flex Noun
24950 status collapsed
24951
24952 \begin_layout Plain Layout
24953 Document\SpecialChar menuseparator
24954 Settings\SpecialChar menuseparator
24955 Output
24956 \end_layout
24957
24958 \end_inset
24959
24960 .
24961  In such a case \SpecialChar LyX
24962  will automatically insert the necessary Sync\SpecialChar TeX
24963  macro (for
24964  PDF) or load the srcltx package (for DVI) respectively.
24965  This option can be easily reached also on 
24966 \begin_inset Flex Code
24967 status collapsed
24968
24969 \begin_layout Plain Layout
24970 View/Update
24971 \end_layout
24972
24973 \end_inset
24974
24975  Toolbar.
24976 \end_layout
24977
24978 \begin_layout Standard
24979 If you need a different setting, you can select or input a custom macro
24980  from the drop down box just below 
24981 \begin_inset Flex Noun
24982 status collapsed
24983
24984 \begin_layout Plain Layout
24985 Document\SpecialChar menuseparator
24986 Settings\SpecialChar menuseparator
24987 Output\SpecialChar menuseparator
24988 Synchronize with Output
24989 \end_layout
24990
24991 \end_inset
24992
24993 .
24994 \end_layout
24995
24996 \begin_layout Standard
24997 Note that the method 
24998 \begin_inset Flex Code
24999 status collapsed
25000
25001 \begin_layout Plain Layout
25002
25003 \backslash
25004 synctex=1
25005 \end_layout
25006
25007 \end_inset
25008
25009  enables gzip compression.
25010  If your viewer does not support it, you should instead use 
25011 \begin_inset Flex Code
25012 status collapsed
25013
25014 \begin_layout Plain Layout
25015
25016 \backslash
25017 synctex=-1
25018 \end_layout
25019
25020 \end_inset
25021
25022 .
25023 \end_layout
25024
25025 \begin_layout Standard
25026 Please also note that including the 
25027 \begin_inset Flex Code
25028 status collapsed
25029
25030 \begin_layout Plain Layout
25031 srcltx
25032 \end_layout
25033
25034 \end_inset
25035
25036  package or 
25037 \begin_inset Flex Code
25038 status collapsed
25039
25040 \begin_layout Plain Layout
25041 src-specials
25042 \end_layout
25043
25044 \end_inset
25045
25046  sometimes has an undesired impact on the typesetting.
25047  Thus, you should switch output synchronization off for the final typesetting
25048  if you use the 
25049 \begin_inset Flex Code
25050 status collapsed
25051
25052 \begin_layout Plain Layout
25053 srcltx
25054 \end_layout
25055
25056 \end_inset
25057
25058  package or 
25059 \begin_inset Flex Code
25060 status collapsed
25061
25062 \begin_layout Plain Layout
25063 src-specials
25064 \end_layout
25065
25066 \end_inset
25067
25068 .
25069  
25070 \end_layout
25071
25072 \begin_layout Standard
25073 In case you need some more special settings that are not covered by the
25074  automatic settings, read the next section about how to set up output synchroniz
25075 ation manually.
25076  If the automatic setup suits your needs, you can readily jump to section
25077 \begin_inset space ~
25078 \end_inset
25079
25080
25081 \begin_inset CommandInset ref
25082 LatexCommand ref
25083 reference "subsec:configuring-viewers"
25084
25085 \end_inset
25086
25087 , where the necessary configuration steps in your viewer – needed both with
25088  the automatic and the manual setup – are described.
25089 \end_layout
25090
25091 \begin_layout Subsection
25092 Manual setup
25093 \end_layout
25094
25095 \begin_layout Standard
25096 \SpecialChar LaTeX
25097  provides several different methods for reverse search.
25098  Some are built-in in the 
25099 \begin_inset Flex Code
25100 status collapsed
25101
25102 \begin_layout Plain Layout
25103 latex/pdflatex
25104 \end_layout
25105
25106 \end_inset
25107
25108  program, some are provided by external packages.
25109  Your choice depends on whether your \SpecialChar LaTeX
25110  distribution already provides a given
25111  method (the built-in methods are rather new) and whether your viewer can
25112  cope with it.
25113  The available methods are described in the following.
25114 \end_layout
25115
25116 \begin_layout Subsubsection*
25117 Built-in DVI-search via src-specials (DVI only) 
25118 \end_layout
25119
25120 \begin_layout Standard
25121 This method provides the DVI file with the necessary information for reverse
25122  search.
25123  It is available in \SpecialChar LaTeX
25124  since quite some time (any somewhat recent \SpecialChar LaTeX
25125  distribution
25126  should include it), and it works reliably.
25127  To enable it, change the 
25128 \begin_inset Flex Noun
25129 status collapsed
25130
25131 \begin_layout Plain Layout
25132 La
25133 \family sans
25134 TeX
25135 \family default
25136  (plain)->DVI
25137 \end_layout
25138
25139 \end_inset
25140
25141  or 
25142 \begin_inset Flex Noun
25143 status collapsed
25144
25145 \begin_layout Plain Layout
25146 La
25147 \family sans
25148 TeX
25149 \family default
25150  (plain)->DraftDVI
25151 \end_layout
25152
25153 \end_inset
25154
25155  converter in 
25156 \begin_inset Flex Noun
25157 status collapsed
25158
25159 \begin_layout Plain Layout
25160 Preferences\SpecialChar menuseparator
25161 File Handling\SpecialChar menuseparator
25162 Converters
25163 \end_layout
25164
25165 \end_inset
25166
25167  to 
25168 \begin_inset Flex Code
25169 status collapsed
25170
25171 \begin_layout Plain Layout
25172 latex -src-specials $$i
25173 \end_layout
25174
25175 \end_inset
25176
25177 .
25178  If this doesn't work, check if your \SpecialChar TeX
25179  engine needs different options (the
25180  syntax might differ in some distributions).
25181 \end_layout
25182
25183 \begin_layout Subsubsection*
25184 External Packages (PDFSync and scrltx) 
25185 \end_layout
25186
25187 \begin_layout Standard
25188 The packages 
25189 \emph on
25190 pdfsync
25191 \emph default
25192  and 
25193 \emph on
25194 scrltx
25195 \emph default
25196  provide reverse search facility for PDF output (via pdflatex) and DVI output,
25197  respectively.
25198  In order to enable it, load the packages in the \SpecialChar LyX
25199  preamble: 
25200 \end_layout
25201
25202 \begin_layout Itemize
25203 \begin_inset Flex Code
25204 status collapsed
25205
25206 \begin_layout Plain Layout
25207
25208 \backslash
25209 usepackage{pdfsync}
25210 \end_layout
25211
25212 \end_inset
25213
25214  for reverse PDF search,
25215 \end_layout
25216
25217 \begin_layout Itemize
25218 \begin_inset Flex Code
25219 status collapsed
25220
25221 \begin_layout Plain Layout
25222
25223 \backslash
25224 usepackage[active]{srcltx}
25225 \end_layout
25226
25227 \end_inset
25228
25229  for reverse DVI search.
25230 \end_layout
25231
25232 \begin_layout Standard
25233 If you want to be able to perform both DVI and PDF reverse searches, you
25234  can also insert in the preamble the following lines
25235 \end_layout
25236
25237 \begin_layout LyX-Code
25238
25239 \backslash
25240 usepackage{ifpdf}
25241 \begin_inset Newline newline
25242 \end_inset
25243
25244
25245 \backslash
25246 ifpdf
25247 \begin_inset Newline newline
25248 \end_inset
25249
25250   
25251 \backslash
25252 usepackage{pdfsync}
25253 \begin_inset Newline newline
25254 \end_inset
25255
25256
25257 \backslash
25258 else
25259 \begin_inset Newline newline
25260 \end_inset
25261
25262   
25263 \backslash
25264 usepackage[active]{srcltx}
25265 \begin_inset Newline newline
25266 \end_inset
25267
25268
25269 \backslash
25270 fi
25271 \end_layout
25272
25273 \begin_layout Standard
25274 This way, you can preview the file as either DVI or PDF (pdflatex) and the
25275  right package will be used.
25276 \end_layout
25277
25278 \begin_layout Standard
25279 Note that PDFSync might affect the output layout of your document.
25280  It is therefore advised to disable PDFsync for final documents.
25281 \end_layout
25282
25283 \begin_layout Subsubsection*
25284 Built-in reverse search via Sync\SpecialChar TeX
25285  (DVI and PDF) 
25286 \end_layout
25287
25288 \begin_layout Standard
25289 Recent versions of 
25290 \begin_inset Flex Code
25291 status collapsed
25292
25293 \begin_layout Plain Layout
25294 (pdf)latex
25295 \end_layout
25296
25297 \end_inset
25298
25299  have built-in support for both PDF and DVI reverse search.
25300  This so-called 
25301 \emph on
25302 Sync\SpecialChar TeX
25303
25304 \emph default
25305  facility is basically the result of the integration of the PDFSync package
25306  to the pdftex program and its merge with the 
25307 \emph on
25308 scr-specials
25309 \emph default
25310  approach.
25311  You need at least \SpecialChar TeX
25312 Live 2008 or a recent Mik\SpecialChar TeX
25313  distribution in order to use
25314  it.
25315 \begin_inset Foot
25316 status collapsed
25317
25318 \begin_layout Plain Layout
25319 For some reason, Mik\SpecialChar TeX
25320  does not understand/obey the command \SpecialChar LyX
25321  inserts into
25322  the preamble when you check the "Enable Forward/Reverse Search" button
25323  in the toolbar and does not generate the necessary info.
25324 \end_layout
25325
25326 \begin_layout Plain Layout
25327 The generation of the required info can be forced by changing the converter
25328  "\SpecialChar LaTeX
25329  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
25330  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
25331  the -synctex=1 switch).
25332 \end_layout
25333
25334 \end_inset
25335
25336  Also note that only a few PDF viewers (Okular and Qpdfview on Unix, Skim
25337  on the Mac, SumatraPDF on Windows) already provide Sync\SpecialChar TeX
25338  support.
25339 \end_layout
25340
25341 \begin_layout Standard
25342 To enable Sync\SpecialChar TeX
25343  for DVI output, change the 
25344 \begin_inset Flex Noun
25345 status collapsed
25346
25347 \begin_layout Plain Layout
25348 La
25349 \family sans
25350 TeX
25351 \family default
25352  (plain) -> DVI
25353 \end_layout
25354
25355 \end_inset
25356
25357  or 
25358 \begin_inset Flex Noun
25359 status collapsed
25360
25361 \begin_layout Plain Layout
25362 La
25363 \family sans
25364 TeX
25365 \family default
25366  (plain) -> DraftDVI
25367 \end_layout
25368
25369 \end_inset
25370
25371  converter in 
25372 \begin_inset Flex Noun
25373 status collapsed
25374
25375 \begin_layout Plain Layout
25376 Preferences\SpecialChar menuseparator
25377 File Handling\SpecialChar menuseparator
25378 Converters
25379 \end_layout
25380
25381 \end_inset
25382
25383  to 
25384 \begin_inset Flex Code
25385 status collapsed
25386
25387 \begin_layout Plain Layout
25388 latex -synctex=1 $$i
25389 \end_layout
25390
25391 \end_inset
25392
25393 , and for PDF output, change the 
25394 \begin_inset Flex Noun
25395 status collapsed
25396
25397 \begin_layout Plain Layout
25398 La
25399 \family sans
25400 TeX
25401 \family default
25402  (pdflatex) -> PDF (pdflatex)
25403 \end_layout
25404
25405 \end_inset
25406
25407  or converter to 
25408 \begin_inset Flex Code
25409 status collapsed
25410
25411 \begin_layout Plain Layout
25412 pdflatex -synctex=1 $$i
25413 \end_layout
25414
25415 \end_inset
25416
25417 .
25418  Check the documentation of your viewer whether the viewer needs to be configure
25419 d for the use with Sync\SpecialChar TeX
25420 .
25421 \begin_inset Foot
25422 status collapsed
25423
25424 \begin_layout Plain Layout
25425 Note that the option 
25426 \begin_inset Flex Code
25427 status collapsed
25428
25429 \begin_layout Plain Layout
25430 -synctex=1
25431 \end_layout
25432
25433 \end_inset
25434
25435  option enables gzip compression.
25436  If your viewer does not support it, you should instead use 
25437 \begin_inset Flex Code
25438 status collapsed
25439
25440 \begin_layout Plain Layout
25441 -synctex=-1
25442 \end_layout
25443
25444 \end_inset
25445
25446 .
25447 \end_layout
25448
25449 \end_inset
25450
25451
25452 \end_layout
25453
25454 \begin_layout Subsection
25455 Configuring and using specific viewers
25456 \begin_inset CommandInset label
25457 LatexCommand label
25458 name "subsec:configuring-viewers"
25459
25460 \end_inset
25461
25462
25463 \end_layout
25464
25465 \begin_layout Subsubsection*
25466 Xdvi (all platforms)
25467 \end_layout
25468
25469 \begin_layout Standard
25470 If you use 
25471 \begin_inset Flex Code
25472 status collapsed
25473
25474 \begin_layout Plain Layout
25475 xdvi
25476 \end_layout
25477
25478 \end_inset
25479
25480 , you don't need to do anything else for performing a reverse DVI search,
25481  as \SpecialChar LyX
25482  already provides the necessary hooks for automatically using the 
25483 \begin_inset Flex Code
25484 status collapsed
25485
25486 \begin_layout Plain Layout
25487 lyxclient
25488 \end_layout
25489
25490 \end_inset
25491
25492  program.
25493  Just setup your document as described above (reverse search is triggered
25494  by Ctrl-click or Alt-click on Mac OSX, respectively).
25495 \end_layout
25496
25497 \begin_layout Standard
25498 However, if for whatever reason you want to use the named pipe instead of
25499  the socket for communicating with \SpecialChar LyX
25500 , simply change the DVI viewer in 
25501 \begin_inset Flex Noun
25502 status collapsed
25503
25504 \begin_layout Plain Layout
25505 Preferences\SpecialChar menuseparator
25506 File Handling\SpecialChar menuseparator
25507 File formats
25508 \end_layout
25509
25510 \end_inset
25511
25512  to
25513 \begin_inset Foot
25514 status collapsed
25515
25516 \begin_layout Plain Layout
25517 On Mac OSX you have to use 
25518 \begin_inset Flex Code
25519 status collapsed
25520
25521 \begin_layout Plain Layout
25522 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
25523 \end_layout
25524
25525 \end_inset
25526
25527
25528 \end_layout
25529
25530 \end_inset
25531
25532  
25533 \begin_inset Flex Code
25534 status collapsed
25535
25536 \begin_layout Plain Layout
25537 xdvi -editor "lyxeditor.sh %f %l"
25538 \end_layout
25539
25540 \end_inset
25541
25542 , where 
25543 \begin_inset Flex Code
25544 status collapsed
25545
25546 \begin_layout Plain Layout
25547 lyxeditor.sh
25548 \end_layout
25549
25550 \end_inset
25551
25552  is a suitable script.
25553  For example, a minimal shell script is the following one:
25554 \end_layout
25555
25556 \begin_layout LyX-Code
25557 #!/bin/sh
25558 \begin_inset Newline newline
25559 \end_inset
25560
25561 LYXPIPE="/path/to/lyxpipe"
25562 \begin_inset Newline newline
25563 \end_inset
25564
25565 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
25566 \begin_inset Newline newline
25567 \end_inset
25568
25569 echo "$COMMAND" > "${LYXPIPE}".in || exit
25570 \begin_inset Newline newline
25571 \end_inset
25572
25573 read TMP < "${LYXPIPE}".out || exit
25574 \end_layout
25575
25576 \begin_layout Standard
25577 where 
25578 \begin_inset Flex Code
25579 status collapsed
25580
25581 \begin_layout Plain Layout
25582 /path/to/lyxpipe
25583 \end_layout
25584
25585 \end_inset
25586
25587  is the LyXServer pipe path specified in 
25588 \begin_inset Flex Noun
25589 status collapsed
25590
25591 \begin_layout Plain Layout
25592 Preferences\SpecialChar menuseparator
25593 Paths
25594 \end_layout
25595
25596 \end_inset
25597
25598 .
25599 \begin_inset Foot
25600 status collapsed
25601
25602 \begin_layout Plain Layout
25603 In the 
25604 \begin_inset Flex Code
25605 status collapsed
25606
25607 \begin_layout Plain Layout
25608 development/tools
25609 \end_layout
25610
25611 \end_inset
25612
25613  folder of a source distribution you can find a 
25614 \begin_inset Flex Code
25615 status collapsed
25616
25617 \begin_layout Plain Layout
25618 lyxeditor
25619 \end_layout
25620
25621 \end_inset
25622
25623  script which is able to locate the 
25624 \emph on
25625 lyxpipe
25626 \emph default
25627  based on your preferences.
25628 \end_layout
25629
25630 \end_inset
25631
25632
25633 \end_layout
25634
25635 \begin_layout Subsubsection*
25636 MacDviX (Mac OSX)
25637 \end_layout
25638
25639 \begin_layout Standard
25640 At the end of 
25641 \begin_inset Flex Code
25642 status collapsed
25643
25644 \begin_layout Plain Layout
25645 /Applications/MacDviX_Folder/calleditor.script
25646 \end_layout
25647
25648 \end_inset
25649
25650 , add the following lines:
25651 \end_layout
25652
25653 \begin_layout LyX-Code
25654 /Applications/LyX.app/Contents/MacOS/lyxeditor "$2" $1
25655 \begin_inset Newline newline
25656 \end_inset
25657
25658 exit 1
25659 \end_layout
25660
25661 \begin_layout Standard
25662 Modify the lines accordingly if you install \SpecialChar LyX
25663  somewhere else than in the
25664  Applications folder.
25665 \end_layout
25666
25667 \begin_layout Standard
25668 Reverse search is triggered by Alt-click (OPTION-click).
25669 \end_layout
25670
25671 \begin_layout Subsubsection*
25672 Skim (Mac OSX)
25673 \end_layout
25674
25675 \begin_layout Standard
25676 Enter 
25677 \begin_inset Flex Code
25678 status collapsed
25679
25680 \begin_layout Plain Layout
25681 open -a Skim.app $$i
25682 \end_layout
25683
25684 \end_inset
25685
25686  to the viewer setting in 
25687 \begin_inset Flex Noun
25688 status collapsed
25689
25690 \begin_layout Plain Layout
25691 Preferences\SpecialChar menuseparator
25692 File Handling\SpecialChar menuseparator
25693 File formats\SpecialChar menuseparator
25694 PDF (pdflatex)
25695 \end_layout
25696
25697 \end_inset
25698
25699 , and then in 
25700 \begin_inset Flex Noun
25701 status collapsed
25702
25703 \begin_layout Plain Layout
25704 Skim\SpecialChar menuseparator
25705 Preferences\SpecialChar menuseparator
25706 Sync
25707 \end_layout
25708
25709 \end_inset
25710
25711  choose 
25712 \begin_inset Flex Noun
25713 status collapsed
25714
25715 \begin_layout Plain Layout
25716 custom
25717 \end_layout
25718
25719 \end_inset
25720
25721  preset and enter command 
25722 \begin_inset Flex Noun
25723 status collapsed
25724
25725 \begin_layout Plain Layout
25726 /Applications/\SpecialChar LyX
25727 .app/Contents/MacOS/lyxeditor
25728 \end_layout
25729
25730 \end_inset
25731
25732 .
25733 \end_layout
25734
25735 \begin_layout Standard
25736 Reverse search is triggered by COMMAND-SHIFT-click
25737 \end_layout
25738
25739 \begin_layout Subsubsection*
25740 Okular (KDE)
25741 \end_layout
25742
25743 \begin_layout Standard
25744 Go to 
25745 \begin_inset Flex Noun
25746 status collapsed
25747
25748 \begin_layout Plain Layout
25749 Settings\SpecialChar menuseparator
25750 Configure Okular\SpecialChar menuseparator
25751 Editor
25752 \end_layout
25753
25754 \end_inset
25755
25756 , select 
25757 \begin_inset Quotes eld
25758 \end_inset
25759
25760 Custom Text Editor
25761 \begin_inset Quotes erd
25762 \end_inset
25763
25764  and add the command 
25765 \begin_inset Flex Code
25766 status collapsed
25767
25768 \begin_layout Plain Layout
25769 lyxclient -g %f %l
25770 \end_layout
25771
25772 \end_inset
25773
25774 .
25775 \end_layout
25776
25777 \begin_layout Standard
25778 Reverse search is triggered by SHIFT-click.
25779 \end_layout
25780
25781 \begin_layout Subsubsection*
25782 Qpdfview (Unix)
25783 \end_layout
25784
25785 \begin_layout Standard
25786 Qpdfview supports Sync\SpecialChar TeX
25787  since version 0.3.5.
25788  Go to 
25789 \begin_inset Flex Noun
25790 status collapsed
25791
25792 \begin_layout Plain Layout
25793 Edit\SpecialChar menuseparator
25794 Settings\SpecialChar menuseparator
25795 Behavior
25796 \end_layout
25797
25798 \end_inset
25799
25800 , click on the input field of the 
25801 \begin_inset Quotes eld
25802 \end_inset
25803
25804 Source editor
25805 \begin_inset Quotes erd
25806 \end_inset
25807
25808  item and add the command 
25809 \begin_inset Flex Code
25810 status collapsed
25811
25812 \begin_layout Plain Layout
25813 lyxclient -g %1 %2
25814 \end_layout
25815
25816 \end_inset
25817
25818 .
25819 \end_layout
25820
25821 \begin_layout Standard
25822 Reverse search is triggered by double-click.
25823 \end_layout
25824
25825 \begin_layout Subsubsection*
25826 YAP (Windows)
25827 \end_layout
25828
25829 \begin_layout Standard
25830 Launch yap, choose its 
25831 \begin_inset Flex Noun
25832 status collapsed
25833
25834 \begin_layout Plain Layout
25835 View\SpecialChar menuseparator
25836 Options
25837 \end_layout
25838
25839 \end_inset
25840
25841  menu and select the 
25842 \begin_inset Quotes eld
25843 \end_inset
25844
25845 Inverse DVI Search
25846 \begin_inset Quotes erd
25847 \end_inset
25848
25849  tab.
25850  Click on the 
25851 \begin_inset Quotes eld
25852 \end_inset
25853
25854 New\SpecialChar ldots
25855
25856 \begin_inset Quotes erd
25857 \end_inset
25858
25859  button and, in the window that opens, enter 
25860 \begin_inset Quotes eld
25861 \end_inset
25862
25863 \SpecialChar LyX
25864  Editor
25865 \begin_inset Quotes erd
25866 \end_inset
25867
25868  (or any other name you like) in the 
25869 \begin_inset Quotes eld
25870 \end_inset
25871
25872 Name:
25873 \begin_inset Quotes erd
25874 \end_inset
25875
25876  field.
25877  Now click on the button labeled 
25878 \begin_inset Quotes eld
25879 \end_inset
25880
25881 \SpecialChar ldots
25882
25883 \begin_inset Quotes erd
25884 \end_inset
25885
25886  to open a file dialog and navigate to the directory containing the batch
25887  file 
25888 \begin_inset Flex Code
25889 status collapsed
25890
25891 \begin_layout Plain Layout
25892 lyxeditor.bat
25893 \end_layout
25894
25895 \end_inset
25896
25897  (see below).
25898  Select 
25899 \begin_inset Flex Code
25900 status collapsed
25901
25902 \begin_layout Plain Layout
25903 lyxeditor.bat
25904 \end_layout
25905
25906 \end_inset
25907
25908  and then specify the program arguments as 
25909 \begin_inset Flex Code
25910 status collapsed
25911
25912 \begin_layout Plain Layout
25913 %f %l
25914 \end_layout
25915
25916 \end_inset
25917
25918 .
25919  The 
25920 \begin_inset Flex Code
25921 status collapsed
25922
25923 \begin_layout Plain Layout
25924 lyxeditor.bat
25925 \end_layout
25926
25927 \end_inset
25928
25929  wrapper is used for communicating with \SpecialChar LyX
25930  through the 
25931 \emph on
25932 lyxpipe
25933 \emph default
25934  and is as follows:
25935 \end_layout
25936
25937 \begin_layout LyX-Code
25938 @echo off
25939 \begin_inset Newline newline
25940 \end_inset
25941
25942 echo LYXCMD:revdvi:server-goto-file-row:%1 %2> 
25943 \backslash
25944
25945 \backslash
25946 .
25947 \backslash
25948 pipe
25949 \backslash
25950 lyxpipe.in
25951 \begin_inset Newline newline
25952 \end_inset
25953
25954 type 
25955 \backslash
25956
25957 \backslash
25958 .
25959 \backslash
25960 pipe
25961 \backslash
25962 lyxpipe.out
25963 \end_layout
25964
25965 \begin_layout Standard
25966 Make sure that the \SpecialChar LyX
25967 Server pipe path you specified in \SpecialChar LyX
25968  is 
25969 \begin_inset Flex Code
25970 status collapsed
25971
25972 \begin_layout Plain Layout
25973
25974 \backslash
25975
25976 \backslash
25977 .
25978 \backslash
25979 pipe
25980 \backslash
25981 lyxpipe
25982 \end_layout
25983
25984 \end_inset
25985
25986 , otherwise change the 
25987 \begin_inset Flex Code
25988 status collapsed
25989
25990 \begin_layout Plain Layout
25991 lyxeditor.bat
25992 \end_layout
25993
25994 \end_inset
25995
25996  wrapper accordingly.
25997 \end_layout
25998
25999 \begin_layout Standard
26000 In yap, reverse search is triggered by double-click.
26001 \end_layout
26002
26003 \begin_layout Subsubsection*
26004 SumatraPDF (Windows)
26005 \end_layout
26006
26007 \begin_layout Standard
26008 In order to use SumatraPDF for inverse search, enter 
26009 \begin_inset Flex Code
26010 status collapsed
26011
26012 \begin_layout Plain Layout
26013 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
26014 \end_layout
26015
26016 \end_inset
26017
26018  in the viewer setting in 
26019 \begin_inset Flex Noun
26020 status collapsed
26021
26022 \begin_layout Plain Layout
26023 Preferences\SpecialChar menuseparator
26024 File Handling\SpecialChar menuseparator
26025 File formats\SpecialChar menuseparator
26026 PDF (pdflatex)
26027 \end_layout
26028
26029 \end_inset
26030
26031 , where 
26032 \begin_inset Flex Code
26033 status collapsed
26034
26035 \begin_layout Plain Layout
26036 lyxeditor.bat
26037 \end_layout
26038
26039 \end_inset
26040
26041  is the previous wrapper.
26042  If SumatraPDF.exe is not in your command PATH, use its full file name.
26043 \end_layout
26044
26045 \begin_layout Standard
26046 Reverse search is triggered by double-click.
26047 \end_layout
26048
26049 \begin_layout Subsubsection*
26050 YAP (Cygwin)
26051 \end_layout
26052
26053 \begin_layout Standard
26054 First of all, make sure that yap is your default DVI viewer in the Windows
26055  environment, then launch it, choose its 
26056 \begin_inset Flex Noun
26057 status collapsed
26058
26059 \begin_layout Plain Layout
26060 View\SpecialChar menuseparator
26061 Options
26062 \end_layout
26063
26064 \end_inset
26065
26066  menu and select the 
26067 \begin_inset Quotes eld
26068 \end_inset
26069
26070 Inverse DVI Search
26071 \begin_inset Quotes erd
26072 \end_inset
26073
26074  tab.
26075  Click on the 
26076 \begin_inset Quotes eld
26077 \end_inset
26078
26079 New\SpecialChar ldots
26080
26081 \begin_inset Quotes erd
26082 \end_inset
26083
26084  button and, in the window that opens, enter 
26085 \begin_inset Quotes eld
26086 \end_inset
26087
26088 \SpecialChar LyX
26089  Editor
26090 \begin_inset Quotes erd
26091 \end_inset
26092
26093  (or any other name you like) in the 
26094 \begin_inset Quotes eld
26095 \end_inset
26096
26097 Name:
26098 \begin_inset Quotes erd
26099 \end_inset
26100
26101  field.
26102  Now click on the button labeled 
26103 \begin_inset Quotes eld
26104 \end_inset
26105
26106 \SpecialChar ldots
26107
26108 \begin_inset Quotes erd
26109 \end_inset
26110
26111  to open a file dialog and navigate to the directory containing the 
26112 \begin_inset Flex Code
26113 status collapsed
26114
26115 \begin_layout Plain Layout
26116 lyxeditor.exe
26117 \end_layout
26118
26119 \end_inset
26120
26121  program (which is installed by default on Cygwin along with the \SpecialChar LyX
26122  executable).
26123  Select 
26124 \begin_inset Flex Code
26125 status collapsed
26126
26127 \begin_layout Plain Layout
26128 lyxeditor.exe
26129 \end_layout
26130
26131 \end_inset
26132
26133  and then specify the program arguments as 
26134 \begin_inset Flex Code
26135 status collapsed
26136
26137 \begin_layout Plain Layout
26138 -g %f %l
26139 \end_layout
26140
26141 \end_inset
26142
26143 .
26144  In this way, you will be using the 
26145 \emph on
26146 lyxsocket
26147 \emph default
26148  for communicating with \SpecialChar LyX
26149 .
26150  If, for whatever reason, you want to use the 
26151 \emph on
26152 lyxpipe
26153 \emph default
26154 , omit the 
26155 \begin_inset Flex Code
26156 status collapsed
26157
26158 \begin_layout Plain Layout
26159 -g
26160 \end_layout
26161
26162 \end_inset
26163
26164  option and be sure to specify the \SpecialChar LyX
26165 Server pipe path in the \SpecialChar LyX
26166  preferences.
26167 \end_layout
26168
26169 \begin_layout Standard
26170 In yap, reverse search is triggered by double-click.
26171 \end_layout
26172
26173 \begin_layout Subsubsection*
26174 SumatraPDF (Cygwin)
26175 \end_layout
26176
26177 \begin_layout Standard
26178 In order to use SumatraPDF for inverse search, enter 
26179 \begin_inset Flex Code
26180 status collapsed
26181
26182 \begin_layout Plain Layout
26183 SumatraPDF -inverse-search "lyxeditor -g %f %l"
26184 \end_layout
26185
26186 \end_inset
26187
26188  in the viewer setting in 
26189 \begin_inset Flex Noun
26190 status collapsed
26191
26192 \begin_layout Plain Layout
26193 Preferences\SpecialChar menuseparator
26194 File Handling\SpecialChar menuseparator
26195 File formats\SpecialChar menuseparator
26196 PDF (pdflatex)
26197 \end_layout
26198
26199 \end_inset
26200
26201 .
26202  If SumatraPDF.exe is not in your command PATH, use its full posix path.
26203  The 
26204 \begin_inset Flex Code
26205 status collapsed
26206
26207 \begin_layout Plain Layout
26208 -g
26209 \end_layout
26210
26211 \end_inset
26212
26213  enables communication via the 
26214 \emph on
26215 lyxsocket
26216 \emph default
26217 .
26218  Again, omit the 
26219 \begin_inset Flex Code
26220 status collapsed
26221
26222 \begin_layout Plain Layout
26223 -g
26224 \end_layout
26225
26226 \end_inset
26227
26228  option if you want to use the 
26229 \emph on
26230 lyxpipe
26231 \emph default
26232 , and be sure to specify the \SpecialChar LyX
26233 Server pipe path in the \SpecialChar LyX
26234  preferences.
26235 \end_layout
26236
26237 \begin_layout Standard
26238 Reverse search is triggered by double-click.
26239 \end_layout
26240
26241 \begin_layout Section
26242 Forward search
26243 \end_layout
26244
26245 \begin_layout Standard
26246 Forward search is, as the name implies, in a sense the 
26247 \begin_inset Quotes eld
26248 \end_inset
26249
26250 opposite
26251 \begin_inset Quotes erd
26252 \end_inset
26253
26254  of reverse search.
26255  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
26256 .
26257  If forward search is set up (as described in what follows), you can put
26258  the cursor anywhere in your \SpecialChar LyX
26259  document, and hit 
26260 \begin_inset Flex Noun
26261 status collapsed
26262
26263 \begin_layout Plain Layout
26264 Navigate\SpecialChar menuseparator
26265 Forward search
26266 \end_layout
26267
26268 \end_inset
26269
26270  (or select 
26271 \begin_inset Flex Noun
26272 status collapsed
26273
26274 \begin_layout Plain Layout
26275 Forward search
26276 \end_layout
26277
26278 \end_inset
26279
26280  in the context menu via right mouse click), and then the viewer will jump
26281  to that position as well.
26282  This implies, of course, that your viewer supports this function.
26283 \end_layout
26284
26285 \begin_layout Standard
26286 To make forward search possible, you first need to provide the generated
26287  output PDF/DVI file with additional information about the \SpecialChar TeX
26288  sources.
26289  This can be done via the methods described in the section 
26290 \begin_inset CommandInset ref
26291 LatexCommand ref
26292 reference "subsec:rev-search"
26293
26294 \end_inset
26295
26296 .
26297 \end_layout
26298
26299 \begin_layout Standard
26300 Additionally, you need to configure \SpecialChar LyX
26301  for using your viewers in 
26302 \begin_inset Flex Noun
26303 status collapsed
26304
26305 \begin_layout Plain Layout
26306 Tools\SpecialChar menuseparator
26307 Preferences\SpecialChar menuseparator
26308 Output\SpecialChar menuseparator
26309 General
26310 \end_layout
26311
26312 \end_inset
26313
26314 .
26315  We provide a range of tested configurations for some viewers, which you
26316  can select from the drop down list.
26317  If none of these configurations suits you, you have to find out and enter
26318  a suitable configuration yourself.
26319  The definition syntax uses the following placeholders:
26320 \end_layout
26321
26322 \begin_layout Itemize
26323 \noindent
26324 \begin_inset Flex Code
26325 status collapsed
26326
26327 \begin_layout Plain Layout
26328 $$n
26329 \end_layout
26330
26331 \end_inset
26332
26333 : row number
26334 \end_layout
26335
26336 \begin_layout Itemize
26337 \noindent
26338 \begin_inset Flex Code
26339 status collapsed
26340
26341 \begin_layout Plain Layout
26342 $$t
26343 \end_layout
26344
26345 \end_inset
26346
26347 : name of the (temporary) exported .tex file (without path)
26348 \end_layout
26349
26350 \begin_layout Itemize
26351 \noindent
26352 \begin_inset Flex Code
26353 status collapsed
26354
26355 \begin_layout Plain Layout
26356 $$f
26357 \end_layout
26358
26359 \end_inset
26360
26361 : name of the (temporary) exported .tex file (including path)
26362 \end_layout
26363
26364 \begin_layout Itemize
26365 \noindent
26366 \begin_inset Flex Code
26367 status collapsed
26368
26369 \begin_layout Plain Layout
26370 $$o
26371 \end_layout
26372
26373 \end_inset
26374
26375 : name of the exported output file (either dvi or pdf, depending on which
26376  one exists in the temporary directory)
26377 \end_layout
26378
26379 \begin_layout Standard
26380 Note that only some of the viewers provide full forward search functionality,
26381  among them yap, xdvi, okular
26382 \begin_inset Foot
26383 status collapsed
26384
26385 \begin_layout Plain Layout
26386 You might want to set 
26387 \begin_inset Flex Code
26388 status collapsed
26389
26390 \begin_layout Plain Layout
26391 okular –unique
26392 \end_layout
26393
26394 \end_inset
26395
26396  in 
26397 \begin_inset Flex Noun
26398 status collapsed
26399
26400 \begin_layout Plain Layout
26401 Tools\SpecialChar menuseparator
26402 Preferences\SpecialChar menuseparator
26403 File Handling\SpecialChar menuseparator
26404 File
26405 \begin_inset space ~
26406 \end_inset
26407
26408 Formats
26409 \end_layout
26410
26411 \end_inset
26412
26413
26414 \end_layout
26415
26416 \end_inset
26417
26418 , qpdfview and SumatraPDF
26419 \begin_inset Foot
26420 status collapsed
26421
26422 \begin_layout Plain Layout
26423 SumatraPDF can also use DDE commands through the external program CMCDDE
26424  — downloadable from 
26425 \begin_inset CommandInset href
26426 LatexCommand href
26427 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
26428
26429 \end_inset
26430
26431
26432 \end_layout
26433
26434 \end_inset
26435
26436 .
26437  While many of the widespread PDF viewers (most notably Adobe Reader) do
26438  not support forward search at all, some other viewers – e.
26439 \begin_inset space \thinspace{}
26440 \end_inset
26441
26442 g.
26443  evince and xpdf – allow at least to reload the document and jump to a specific
26444  page of the file, so you can at least navigate 
26445 \begin_inset Quotes eld
26446 \end_inset
26447
26448 near
26449 \begin_inset Quotes erd
26450 \end_inset
26451
26452 .
26453  This latter functionality is provided by an external call of synctex (see
26454  the predefined example configurations).
26455  
26456 \end_layout
26457
26458 \begin_layout Standard
26459 Forward search works both with DVI and PDF output.
26460  \SpecialChar LyX
26461  simply checks which preview format you have used before (i.
26462 \begin_inset space \thinspace{}
26463 \end_inset
26464
26465 e., which format is already there in the temporary directory) and chooses
26466  the appropriate configuration for the respective format.
26467 \end_layout
26468
26469 \end_body
26470 \end_document