]> git.lyx.org Git - lyx.git/blob - lib/doc/Additional.lyx
Additional.lyx: accept some changes
[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 -851615295 "ef"
118 \author 893223064 "John Robert Hudson" j.r.hudson@virginmedia.com
119 \end_header
120
121 \begin_body
122
123 \begin_layout Title
124 Additional \SpecialChar LyX
125  Features
126 \end_layout
127
128 \begin_layout Subtitle
129 Version 2.3.x
130 \end_layout
131
132 \begin_layout Author
133 by the \SpecialChar LyX
134  Team
135 \begin_inset Foot
136 status collapsed
137
138 \begin_layout Plain Layout
139 \noindent
140 Principal maintainer of this file is
141 \noun on
142  Richard Heck
143 \noun default
144 .
145  If you have comments or error corrections, please send them to the \SpecialChar LyX
146  Documentati
147 on mailing list, 
148 \begin_inset Flex Code
149 status collapsed
150
151 \begin_layout Plain Layout
152 \noindent
153 <lyx-docs@lists.lyx.org>
154 \end_layout
155
156 \end_inset
157
158 .
159 \end_layout
160
161 \end_inset
162
163
164 \end_layout
165
166 \begin_layout Standard
167 \begin_inset CommandInset toc
168 LatexCommand tableofcontents
169
170 \end_inset
171
172
173 \end_layout
174
175 \begin_layout Chapter
176 Introduction
177 \end_layout
178
179 \begin_layout Standard
180 This manual is essentially Part II of the 
181 \emph on
182 User's Guide\SpecialChar endofsentence
183
184 \emph default
185  The reason for separating the two documents is simple: the 
186 \emph on
187 User's Guide
188 \emph default
189  is already quite lengthy, and it contains information on all of the basic
190  features one needs to know in order to prepare most documents.
191  However, the \SpecialChar LyX
192  Team has worked to make \SpecialChar LyX
193  extensible through various configuration
194  files and external packages.
195  That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
196  package, you can
197  create a layout file (or module) for it without having to alter \SpecialChar LyX
198  itself.
199  We've already had contributions of several new features this way, and some
200  of them are documented here.
201  There are also some more `advanced' features, such as how to control the
202  presentation of bibliographies and how to work with multi-part documents,
203  that are not covered in the 
204 \emph on
205 User's Guide
206 \emph default
207  and are discussed here.
208 \end_layout
209
210 \begin_layout Standard
211 This manual also documents some special features, like fax support, version
212  control, and SGML support, which require additional software to work properly.
213  There is also a chapter on \SpecialChar LyX
214 's support for HTML.
215  And lastly, there's a chapter of \SpecialChar LaTeX
216  tools and tips, things you can use to
217  spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
218 .
219  After all, \SpecialChar LyX
220  
221 \emph on
222 is
223 \emph default
224  only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
225  features.
226 \end_layout
227
228 \begin_layout Standard
229 If you haven't read the 
230 \emph on
231 Introduction
232 \emph default
233  yet, you are definitely in the wrong manual.
234  The 
235 \emph on
236 Introduction
237 \emph default
238  is the first place to go, since it describes the notation and format of
239  all of the manuals.
240  You should also be thoroughly familiar with the 
241 \emph on
242 User's Guide
243 \emph default
244  and all of the basic features of \SpecialChar LyX
245  before attempting to read this one.
246 \end_layout
247
248 \begin_layout Standard
249 Since many of the topics in this manual depend heavily on \SpecialChar LyX
250 's interaction
251  with \SpecialChar LaTeX
252 , this first chapter covers the inner workings of \SpecialChar LyX
253  and how to direct
254  \SpecialChar LyX
255  to generate exactly the \SpecialChar LaTeX
256  code you want.
257  It is obviously for more seasoned \SpecialChar LyX
258  users.
259 \end_layout
260
261 \begin_layout Chapter
262 \SpecialChar LyX
263  and \SpecialChar LaTeX
264
265 \end_layout
266
267 \begin_layout Section
268 How \SpecialChar LyX
269  Uses \SpecialChar LaTeX
270
271 \end_layout
272
273 \begin_layout Standard
274 This chapter is for both \SpecialChar TeX
275 -nicians and the \SpecialChar LaTeX
276 -curious.
277  In it, we'll explain how \SpecialChar LyX
278  and \SpecialChar LaTeX
279  work together to produce printable output.
280  This is the only place in any of the manuals where we assume you know something
281  about \SpecialChar LaTeX
282 .
283 \end_layout
284
285 \begin_layout Standard
286 At one time, \SpecialChar LyX
287  was called a 
288 \begin_inset Quotes eld
289 \end_inset
290
291 WYSIWYM frontend to \SpecialChar LaTeX
292 ,
293 \begin_inset Quotes erd
294 \end_inset
295
296  but that's no longer true.
297  There are frontends to \SpecialChar LaTeX
298  out there.
299 \begin_inset Foot
300 status collapsed
301
302 \begin_layout Plain Layout
303 Some familar ones are \SpecialChar TeX
304 maker and kile, on Linux, and \SpecialChar TeX
305 shop, OSX.
306  There are also the \SpecialChar LaTeX
307  modes for vi and emacs, of course.
308 \end_layout
309
310 \end_inset
311
312  These are basically text editors with the ability to run \SpecialChar LaTeX
313  and mark any
314  errors in the file you're editing.
315  Although \SpecialChar LyX
316  
317 \emph on
318 is
319 \emph default
320  an editor, and it 
321 \emph on
322 does
323 \emph default
324  run \SpecialChar LaTeX
325 , and it also indicates errors in the file, it also does much, much
326  more.
327  For one thing, you don't need to know \SpecialChar LaTeX
328  to use \SpecialChar LyX
329  effectively.
330  And \SpecialChar LyX
331  has added its own extensions to \SpecialChar LaTeX
332 .
333  Try the following sometime: select 
334 \begin_inset Flex Noun
335 status collapsed
336
337 \begin_layout Plain Layout
338 Export\SpecialChar menuseparator
339 LaTeX
340 \end_layout
341
342 \end_inset
343
344  from the 
345 \begin_inset Flex Noun
346 status collapsed
347
348 \begin_layout Plain Layout
349 File
350 \end_layout
351
352 \end_inset
353
354  menu (or 
355 \begin_inset Flex Noun
356 status collapsed
357
358 \begin_layout Plain Layout
359 View\SpecialChar menuseparator
360 Source
361 \begin_inset space ~
362 \end_inset
363
364 Pane
365 \end_layout
366
367 \end_inset
368
369 ), then look at the preamble of the resulting 
370 \begin_inset Flex Code
371 status collapsed
372
373 \begin_layout Plain Layout
374 .tex
375 \end_layout
376
377 \end_inset
378
379  file.
380  You'll notice a variety of new macros defined specifically by \SpecialChar LyX
381 .
382  These macros are defined automatically, according to the features you use
383  in the document.
384 \end_layout
385
386 \begin_layout Standard
387 There are several commands that automatically invoke \SpecialChar LaTeX
388 .
389  They are:
390 \end_layout
391
392 \begin_layout Itemize
393 \begin_inset Flex Noun
394 status collapsed
395
396 \begin_layout Plain Layout
397 Document\SpecialChar menuseparator
398 View
399 \end_layout
400
401 \end_inset
402
403
404 \end_layout
405
406 \begin_layout Itemize
407 \begin_inset Flex Noun
408 status collapsed
409
410 \begin_layout Plain Layout
411 Document\SpecialChar menuseparator
412 Update
413 \end_layout
414
415 \end_inset
416
417
418 \end_layout
419
420 \begin_layout Standard
421 They will only invoke \SpecialChar LaTeX
422  if the file has changed since the last time \SpecialChar LaTeX
423  was
424  run.
425  
426 \end_layout
427
428 \begin_layout Standard
429 When \SpecialChar LyX
430  runs \SpecialChar LaTeX
431  on the file you're editing, it performs these steps:
432 \end_layout
433
434 \begin_layout Enumerate
435 Convert the document to \SpecialChar LaTeX
436  and save to a file with the extension 
437 \begin_inset Flex Code
438 status collapsed
439
440 \begin_layout Plain Layout
441 .tex
442 \end_layout
443
444 \end_inset
445
446  in place of 
447 \begin_inset Flex Code
448 status collapsed
449
450 \begin_layout Plain Layout
451 .lyx
452 \end_layout
453
454 \end_inset
455
456 .
457 \end_layout
458
459 \begin_layout Enumerate
460 Run \SpecialChar LaTeX
461  on the 
462 \begin_inset Flex Code
463 status collapsed
464
465 \begin_layout Plain Layout
466 .tex
467 \end_layout
468
469 \end_inset
470
471  file (maybe several times), and run any other commands (such as 
472 \begin_inset Flex Code
473 status collapsed
474
475 \begin_layout Plain Layout
476 bibtex
477 \end_layout
478
479 \end_inset
480
481  or 
482 \begin_inset Flex Code
483 status collapsed
484
485 \begin_layout Plain Layout
486 makeindex
487 \end_layout
488
489 \end_inset
490
491 ) needed to compile the \SpecialChar LaTeX
492  file.
493 \end_layout
494
495 \begin_layout Enumerate
496 If there are any errors, show the error log.
497 \end_layout
498
499 \begin_layout Standard
500 If you have run \SpecialChar LaTeX
501  using 
502 \begin_inset Flex Noun
503 status collapsed
504
505 \begin_layout Plain Layout
506 View\SpecialChar menuseparator
507 DVI
508 \end_layout
509
510 \end_inset
511
512 , \SpecialChar LyX
513  then runs a DVI viewer to display the DVI-file.
514  If you have used 
515 \begin_inset Flex Noun
516 status collapsed
517
518 \begin_layout Plain Layout
519 View\SpecialChar menuseparator
520 PostScript
521 \end_layout
522
523 \end_inset
524
525 , \SpecialChar LyX
526  performs further steps:
527 \end_layout
528
529 \begin_layout Itemize
530 Run 
531 \begin_inset Flex Code
532 status collapsed
533
534 \begin_layout Plain Layout
535 dvips
536 \end_layout
537
538 \end_inset
539
540  to convert the DVI file to PostScript.
541 \end_layout
542
543 \begin_layout Itemize
544 Run a PostScript viewer, such as 
545 \begin_inset Flex Code
546 status collapsed
547
548 \begin_layout Plain Layout
549 ghostview
550 \end_layout
551
552 \end_inset
553
554 , to display the PostScript file.
555 \end_layout
556
557 \begin_layout Standard
558 \SpecialChar LyX
559  does similar things when viewing, or exporting, other formats.
560 \end_layout
561
562 \begin_layout Section
563 Translating \SpecialChar LaTeX
564  files into \SpecialChar LyX
565
566 \end_layout
567
568 \begin_layout Standard
569 You can import a \SpecialChar LaTeX
570  file into \SpecialChar LyX
571  by using the 
572 \begin_inset Flex Noun
573 status collapsed
574
575 \begin_layout Plain Layout
576 File\SpecialChar menuseparator
577 Import\SpecialChar menuseparator
578 LaTeX
579 \end_layout
580
581 \end_inset
582
583  command in \SpecialChar LyX
584 .
585  This will call a program named 
586 \begin_inset Flex Code
587 status collapsed
588
589 \begin_layout Plain Layout
590 tex2lyx
591 \end_layout
592
593 \end_inset
594
595  which will create a file 
596 \begin_inset Flex Code
597 status collapsed
598
599 \begin_layout Plain Layout
600 foo.lyx
601 \end_layout
602
603 \end_inset
604
605  from the file 
606 \begin_inset Flex Code
607 status collapsed
608
609 \begin_layout Plain Layout
610 foo.tex
611 \end_layout
612
613 \end_inset
614
615 .
616  \SpecialChar LyX
617  will then open that file.
618 \begin_inset Foot
619 status collapsed
620
621 \begin_layout Plain Layout
622 \begin_inset Flex Code
623 status collapsed
624
625 \begin_layout Plain Layout
626 tex2lyx
627 \end_layout
628
629 \end_inset
630
631  can also be run from the command line, of course.
632 \end_layout
633
634 \end_inset
635
636
637 \end_layout
638
639 \begin_layout Standard
640 \begin_inset Flex Code
641 status collapsed
642
643 \begin_layout Plain Layout
644 tex2lyx
645 \end_layout
646
647 \end_inset
648
649  will translate most legal \SpecialChar LaTeX
650 , but not everything.
651  It will put things it doesn't understand into \SpecialChar TeX
652  code, so after translating
653  a file with 
654 \begin_inset Flex Code
655 status collapsed
656
657 \begin_layout Plain Layout
658 tex2lyx
659 \end_layout
660
661 \end_inset
662
663 , you can look for \SpecialChar TeX
664  code and hand-edit it until it looks right.
665 \end_layout
666
667 \begin_layout Standard
668 If you don't know what \SpecialChar TeX
669  code is, read the next section.
670 \end_layout
671
672 \begin_layout Section
673 \begin_inset CommandInset label
674 LatexCommand label
675 name "sec:Inserting-TeX-Code"
676
677 \end_inset
678
679 Inserting \SpecialChar TeX
680  Code into \SpecialChar LyX
681  Documents 
682 \end_layout
683
684 \begin_layout Standard
685 Anything you can do in \SpecialChar LaTeX
686  you can do in \SpecialChar LyX
687 , for a very simple reason: You can
688  always insert \SpecialChar TeX
689  code into any \SpecialChar LyX
690  document.
691  \SpecialChar LyX
692  cannot, and will never be able to, display every possible \SpecialChar LaTeX
693  construct.
694  If ever you need to insert \SpecialChar LaTeX
695  commands into your \SpecialChar LyX
696  document, you can use the
697  
698 \begin_inset Flex Code
699 status collapsed
700
701 \begin_layout Plain Layout
702 \SpecialChar TeX
703  Code
704 \end_layout
705
706 \end_inset
707
708  box, which you can insert into your document with 
709 \begin_inset Flex Noun
710 status collapsed
711
712 \begin_layout Plain Layout
713 Insert\SpecialChar menuseparator
714
715 \family sans
716 TeX
717 \family default
718  Code
719 \end_layout
720
721 \end_inset
722
723  or the keyboard shortcut 
724 \begin_inset Info
725 type  "shortcut"
726 arg   "ert-insert"
727 \end_inset
728
729 .
730 \end_layout
731
732 \begin_layout Standard
733 Here's an example of inserting \SpecialChar LaTeX
734  commands in a \SpecialChar LyX
735  document.
736  The code looks like this:
737 \end_layout
738
739 \begin_layout LyX-Code
740
741 \backslash
742 begin{tabular}{ll}
743 \begin_inset Newline newline
744 \end_inset
745
746
747 \backslash
748 begin{minipage}{5cm}
749 \begin_inset Newline newline
750 \end_inset
751
752 This is an example of a minipage environment.
753  You 
754 \begin_inset Newline newline
755 \end_inset
756
757 can put nearly everything in it, even (non-floating) 
758 \begin_inset Newline newline
759 \end_inset
760
761 figures and tables.
762  
763 \begin_inset Newline newline
764 \end_inset
765
766
767 \backslash
768 end{minipage}
769 \begin_inset Newline newline
770 \end_inset
771
772 &
773 \begin_inset Newline newline
774 \end_inset
775
776
777 \backslash
778 begin{minipage}{5cm}
779 \begin_inset Newline newline
780 \end_inset
781
782
783 \backslash
784 begin{verbatim}
785 \begin_inset Newline newline
786 \end_inset
787
788
789 \backslash
790 begin{minipage}{5cm}
791 \begin_inset Newline newline
792 \end_inset
793
794 This ...
795  
796 \begin_inset Newline newline
797 \end_inset
798
799
800 \backslash
801 end{minipage}
802 \begin_inset Newline newline
803 \end_inset
804
805
806 \backslash
807 end{verbatim}
808 \begin_inset Newline newline
809 \end_inset
810
811
812 \backslash
813 end{minipage}
814 \begin_inset Newline newline
815 \end_inset
816
817
818 \backslash
819 end{tabular}
820 \end_layout
821
822 \begin_layout LyX-Code
823
824 \end_layout
825
826 \begin_layout Standard
827 The 
828 \begin_inset Flex Code
829 status collapsed
830
831 \begin_layout Plain Layout
832 \SpecialChar TeX
833  Code
834 \end_layout
835
836 \end_inset
837
838  box containing this text is directly after this paragraph.
839  Those of you reading the manual in \SpecialChar LyX
840  will only see the \SpecialChar TeX
841  code inset.
842  Those reading a printed version of the manuals will see the actual results:
843 \begin_inset VSpace bigskip
844 \end_inset
845
846
847 \end_layout
848
849 \begin_layout Standard
850 \begin_inset ERT
851 status open
852
853 \begin_layout Plain Layout
854
855
856 \backslash
857 begin{tabular}{ll}
858 \end_layout
859
860 \begin_layout Plain Layout
861
862
863 \backslash
864 begin{minipage}{5cm}
865 \end_layout
866
867 \begin_layout Plain Layout
868
869 This is an example of a minipage environment.
870  You can put nearly everything in it, even (non-floating) figures and tables.
871  
872 \end_layout
873
874 \begin_layout Plain Layout
875
876
877 \backslash
878 end{minipage}
879 \end_layout
880
881 \begin_layout Plain Layout
882
883 &
884 \end_layout
885
886 \begin_layout Plain Layout
887
888
889 \backslash
890 begin{minipage}{5cm}
891 \end_layout
892
893 \begin_layout Plain Layout
894
895
896 \backslash
897 begin{verbatim}
898 \end_layout
899
900 \begin_layout Plain Layout
901
902
903 \backslash
904 begin{minipage}{5cm}
905 \end_layout
906
907 \begin_layout Plain Layout
908
909 This ...
910  
911 \end_layout
912
913 \begin_layout Plain Layout
914
915
916 \backslash
917 end{minipage}
918 \end_layout
919
920 \begin_layout Plain Layout
921
922
923 \backslash
924 end{verbatim}
925 \end_layout
926
927 \begin_layout Plain Layout
928
929
930 \backslash
931 end{minipage}
932 \end_layout
933
934 \begin_layout Plain Layout
935
936
937 \backslash
938 end{tabular}
939 \end_layout
940
941 \end_inset
942
943
944 \begin_inset VSpace bigskip
945 \end_inset
946
947
948 \end_layout
949
950 \begin_layout Standard
951 In addition to using \SpecialChar TeX
952  code, you can also create a separate file containing
953  some complex \SpecialChar LaTeX
954  structure and then use 
955 \begin_inset Flex Noun
956 status collapsed
957
958 \begin_layout Plain Layout
959 Insert\SpecialChar menuseparator
960 Child
961 \begin_inset space ~
962 \end_inset
963
964 Document
965 \end_layout
966
967 \end_inset
968
969  to include your file (you should select the type 
970 \begin_inset Flex Code
971 status collapsed
972
973 \begin_layout Plain Layout
974 Input
975 \end_layout
976
977 \end_inset
978
979 ).
980  We recommend that you only do this if you have a 
981 \begin_inset Flex Code
982 status collapsed
983
984 \begin_layout Plain Layout
985 .tex
986 \end_layout
987
988 \end_inset
989
990  file which you 
991 \emph on
992 know
993 \emph default
994  works already.
995  Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
996  errors.
997 \end_layout
998
999 \begin_layout Standard
1000 There are a few last points to emphasize:
1001 \end_layout
1002
1003 \begin_layout Itemize
1004 \SpecialChar LyX
1005  
1006 \emph on
1007 does not
1008 \emph default
1009  check if your \SpecialChar LaTeX
1010  code is correct.
1011 \end_layout
1012
1013 \begin_layout Itemize
1014 Beware of reinventing the wheel.
1015 \end_layout
1016
1017 \begin_layout Standard
1018 On that last point, \SpecialChar LyX
1019  does have quite a few features tucked into it, and
1020  more are coming.
1021  Be sure to check the manuals to make sure that \SpecialChar LyX
1022  doesn't have such-and-such
1023  feature before you decide you have to do it by hand.
1024  Moreover, there are numerous \SpecialChar LaTeX
1025  packages out there to do all sorts of things,
1026  from labels to envelopes to fancy multipage tables.
1027  Check out 
1028 \begin_inset CommandInset href
1029 LatexCommand href
1030 name "CTAN"
1031 target "http://www.ctan.org/"
1032
1033 \end_inset
1034
1035  for details.
1036 \end_layout
1037
1038 \begin_layout Standard
1039 If you do need to do some wild and fancy things within your document, be
1040  sure to check out a good \SpecialChar LaTeX
1041  book for assistance.
1042  There are a number of them listed in the bibliography of the 
1043 \emph on
1044 User's Guide
1045 \emph default
1046 .
1047 \end_layout
1048
1049 \begin_layout Section
1050 \SpecialChar LyX
1051  and the \SpecialChar LaTeX
1052  Preamble
1053 \end_layout
1054
1055 \begin_layout Subsection
1056 About the \SpecialChar LaTeX
1057  Preamble
1058 \end_layout
1059
1060 \begin_layout Standard
1061 If you already know \SpecialChar LaTeX
1062 , there is no need to explain here what the preamble
1063  is good for.
1064  If you don't, the following will give you some ideas—we recommend again
1065  that you consult a \SpecialChar LaTeX
1066  book for further information.
1067  In any case, you should read the points below, because they explain what
1068  you can do and what you don't need to do in the \SpecialChar LaTeX
1069  preamble of a \SpecialChar LyX
1070  document.
1071 \end_layout
1072
1073 \begin_layout Standard
1074 The \SpecialChar LaTeX
1075  preamble comes at the very beginning of a document, 
1076 \emph on
1077 before
1078 \emph default
1079  the text.
1080  It serves to:
1081 \end_layout
1082
1083 \begin_layout Itemize
1084 Declare the document class.
1085  
1086 \begin_inset Newline newline
1087 \end_inset
1088
1089 \SpecialChar LyX
1090  already does this for you.
1091  If you're a seasoned \SpecialChar LaTeX
1092 -nician, and you have a custom document class you
1093  want to use, check out the 
1094 \emph on
1095 Customization Manual
1096 \emph default
1097  for information on how to make \SpecialChar LyX
1098  interface to it.
1099 \end_layout
1100
1101 \begin_layout Itemize
1102 Declare the usage of packages.
1103  
1104 \begin_inset Newline newline
1105 \end_inset
1106
1107 \SpecialChar LaTeX
1108  packages provide special commands, which are only available within a document
1109  when the package has been declared in the preamble.
1110  In addition to providing special commands, the inclusion of a package can
1111  change the document.
1112  For example, the package 
1113 \begin_inset Flex Code
1114 status collapsed
1115
1116 \begin_layout Plain Layout
1117 indentfirst
1118 \end_layout
1119
1120 \end_inset
1121
1122  forces all paragraphs to be indented.
1123  There are other packages for labels, envelopes, margins, etc.
1124  
1125 \end_layout
1126
1127 \begin_layout Itemize
1128 Set counters, variables, lengths and widths.
1129  
1130 \begin_inset Newline newline
1131 \end_inset
1132
1133 There are several \SpecialChar LaTeX
1134  counters and variables that 
1135 \emph on
1136 must
1137 \emph default
1138  be set globally from within the preamble in order to have the desired effect.
1139  (There are variables that you can set and reset inside the document, too.)
1140  Margins are a good example of something that must be set in the preamble.
1141  Another example is the label format for lists.
1142  You can actually set these just about anywhere, but it's best to do it
1143  just once, inside the preamble.
1144 \end_layout
1145
1146 \begin_layout Itemize
1147 Declare user defined commands (with 
1148 \begin_inset Flex Code
1149 status collapsed
1150
1151 \begin_layout Plain Layout
1152
1153 \backslash
1154 newcommand
1155 \end_layout
1156
1157 \end_inset
1158
1159  or 
1160 \begin_inset Flex Code
1161 status collapsed
1162
1163 \begin_layout Plain Layout
1164
1165 \backslash
1166 renewcommand
1167 \end_layout
1168
1169 \end_inset
1170
1171 ).
1172 \begin_inset Newline newline
1173 \end_inset
1174
1175 These are abbreviations for \SpecialChar LaTeX
1176  commands which appear very often inside a document.
1177  Although the preamble is a good place to declare such commands, they 
1178 \emph on
1179 can
1180 \emph default
1181  be declared anywhere (before they are used for the first time, of course).
1182  This can be useful if there is a lot of raw \SpecialChar LaTeX
1183  code in your document, which
1184  normally should not be the case.
1185 \end_layout
1186
1187 \begin_layout Standard
1188 \SpecialChar LyX
1189  adds its own set of definitions to the preamble of the 
1190 \begin_inset Flex Code
1191 status collapsed
1192
1193 \begin_layout Plain Layout
1194 .tex
1195 \end_layout
1196
1197 \end_inset
1198
1199  file it produces.
1200  This makes \SpecialChar LaTeX
1201  files generated by \SpecialChar LyX
1202  portable.
1203 \end_layout
1204
1205 \begin_layout Subsection
1206 Changing the Preamble
1207 \end_layout
1208
1209 \begin_layout Standard
1210 The commands which \SpecialChar LyX
1211  adds to the preamble of a \SpecialChar LaTeX
1212  file are fixed; you can't
1213  change them without patching \SpecialChar LyX
1214  itself.
1215  You can, however, add your own stuff to the preamble by selecting 
1216 \begin_inset Flex Noun
1217 status collapsed
1218
1219 \begin_layout Plain Layout
1220 \SpecialChar LaTeX
1221
1222 \begin_inset space ~
1223 \end_inset
1224
1225 Preamble
1226 \end_layout
1227
1228 \end_inset
1229
1230  in the 
1231 \begin_inset Flex Noun
1232 status collapsed
1233
1234 \begin_layout Plain Layout
1235 Document\SpecialChar menuseparator
1236 Settings
1237 \end_layout
1238
1239 \end_inset
1240
1241  dialog.
1242  \SpecialChar LyX
1243  adds anything in the 
1244 \begin_inset Flex Noun
1245 status collapsed
1246
1247 \begin_layout Plain Layout
1248 Preamble
1249 \end_layout
1250
1251 \end_inset
1252
1253  dialog to its own built-in preamble.
1254  Before adding your own declarations in the preamble, you should make sure
1255  that \SpecialChar LyX
1256  doesn't already support what you want to do.
1257  (Remember what we said about reinventing the wheel?) Also, 
1258 \emph on
1259 make sure your preamble code is correct
1260 \emph default
1261 .
1262  \SpecialChar LyX
1263  doesn't check it for you.
1264  If there is an error, you're likely to get an error like 
1265 \begin_inset Quotes eld
1266 \end_inset
1267
1268
1269 \begin_inset Flex Code
1270 status collapsed
1271
1272 \begin_layout Plain Layout
1273 Missing 
1274 \backslash
1275 begin{document}
1276 \end_layout
1277
1278 \end_inset
1279
1280
1281 \begin_inset Quotes erd
1282 \end_inset
1283
1284 .
1285  If you see this error, check your preamble.
1286 \end_layout
1287
1288 \begin_layout Subsection
1289 Examples
1290 \end_layout
1291
1292 \begin_layout Standard
1293 Here are some examples of what you can add to a preamble, and what they
1294  do.
1295 \end_layout
1296
1297 \begin_layout Subsubsection
1298 Example #1: Offsets
1299 \end_layout
1300
1301 \begin_layout Standard
1302 There are two variables under \SpecialChar LaTeX
1303  that control page position: 
1304 \begin_inset Flex Code
1305 status collapsed
1306
1307 \begin_layout Plain Layout
1308
1309 \backslash
1310 hoffset
1311 \end_layout
1312
1313 \end_inset
1314
1315  and 
1316 \begin_inset Flex Code
1317 status collapsed
1318
1319 \begin_layout Plain Layout
1320
1321 \backslash
1322 voffset
1323 \end_layout
1324
1325 \end_inset
1326
1327 .
1328  Their names should be self-explanatory.
1329  These variables are useful if you think for a moment about computer labels.
1330  Sometimes, the size of a print medium and the area of the medium that you
1331  can actually print on aren't the same.
1332  This is where 
1333 \begin_inset Flex Code
1334 status collapsed
1335
1336 \begin_layout Plain Layout
1337
1338 \backslash
1339 hoffset
1340 \end_layout
1341
1342 \end_inset
1343
1344  and 
1345 \begin_inset Flex Code
1346 status collapsed
1347
1348 \begin_layout Plain Layout
1349
1350 \backslash
1351 voffset
1352 \end_layout
1353
1354 \end_inset
1355
1356  come in.
1357 \end_layout
1358
1359 \begin_layout Standard
1360 The default values for 
1361 \begin_inset Flex Code
1362 status collapsed
1363
1364 \begin_layout Plain Layout
1365
1366 \backslash
1367 hoffset
1368 \end_layout
1369
1370 \end_inset
1371
1372  and 
1373 \begin_inset Flex Code
1374 status collapsed
1375
1376 \begin_layout Plain Layout
1377
1378 \backslash
1379 voffset
1380 \end_layout
1381
1382 \end_inset
1383
1384  are both 0
1385 \begin_inset space \thinspace{}
1386 \end_inset
1387
1388 points, i.
1389 \begin_inset space \thinspace{}
1390 \end_inset
1391
1392 e.
1393 \begin_inset space \space{}
1394 \end_inset
1395
1396 the page isn't shifted.
1397  Unfortunately, some DVI drivers always seem to shift the page.
1398  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1399  If you're using \SpecialChar LyX
1400  on a system that you don't personally maintain, and your
1401  sysadmin is a doofus, 
1402 \begin_inset Flex Code
1403 status collapsed
1404
1405 \begin_layout Plain Layout
1406
1407 \backslash
1408 hoffset
1409 \end_layout
1410
1411 \end_inset
1412
1413  and 
1414 \begin_inset Flex Code
1415 status collapsed
1416
1417 \begin_layout Plain Layout
1418
1419 \backslash
1420 voffset
1421 \end_layout
1422
1423 \end_inset
1424
1425  can save the day.
1426  Suppose your left and top margins are always 0.5
1427 \begin_inset space \thinspace{}
1428 \end_inset
1429
1430 inches too big.
1431  You can add this to the preamble:
1432 \end_layout
1433
1434 \begin_layout LyX-Code
1435
1436 \backslash
1437 setlength{
1438 \backslash
1439 hoffset}{-0.5 in}
1440 \end_layout
1441
1442 \begin_layout LyX-Code
1443
1444 \backslash
1445 setlength{
1446 \backslash
1447 voffset}{-0.5 in}
1448 \end_layout
1449
1450 \begin_layout Standard
1451 and your margins should now be correct.
1452 \end_layout
1453
1454 \begin_layout Subsubsection
1455 Example #2: Labels
1456 \end_layout
1457
1458 \begin_layout Standard
1459 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1460  There's a rather nice package, available at your nearest CTAN archive,
1461  for printing sheets of labels: 
1462 \begin_inset Flex Code
1463 status collapsed
1464
1465 \begin_layout Plain Layout
1466 labels.sty
1467 \end_layout
1468
1469 \end_inset
1470
1471 .
1472  Now, your system may not have this package installed by default.
1473  We leave that up to you to check.
1474  You'll also want to read the documentation for it; we're not going to do
1475  that for you.
1476  Since this is an example, however, we'll give you an example of how you
1477  use this package.
1478 \end_layout
1479
1480 \begin_layout Standard
1481 First, make sure you're using the 
1482 \begin_inset Flex Code
1483 status collapsed
1484
1485 \begin_layout Plain Layout
1486 article
1487 \end_layout
1488
1489 \end_inset
1490
1491  document class.
1492  Next, you need to put the following in your preamble:
1493 \end_layout
1494
1495 \begin_layout LyX-Code
1496
1497 \backslash
1498 usepackage{labels}
1499 \end_layout
1500
1501 \begin_layout LyX-Code
1502
1503 \backslash
1504 LabelCols=3
1505 \end_layout
1506
1507 \begin_layout LyX-Code
1508
1509 \backslash
1510 LabelRows=7
1511 \end_layout
1512
1513 \begin_layout LyX-Code
1514
1515 \backslash
1516 LeftBorder=8mm
1517 \end_layout
1518
1519 \begin_layout LyX-Code
1520
1521 \backslash
1522 RightBorder=8mm
1523 \end_layout
1524
1525 \begin_layout LyX-Code
1526
1527 \backslash
1528 TopBorder=9mm
1529 \end_layout
1530
1531 \begin_layout LyX-Code
1532
1533 \backslash
1534 BottomBorder=2mm
1535 \end_layout
1536
1537 \begin_layout Standard
1538 This sets things up for Avery label sheets, stock #5360.
1539  You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1540  code, placing
1541  the commands 
1542 \begin_inset Flex Code
1543 status collapsed
1544
1545 \begin_layout Plain Layout
1546
1547 \backslash
1548 begin{labels}
1549 \end_layout
1550
1551 \end_inset
1552
1553  and 
1554 \begin_inset Flex Code
1555 status collapsed
1556
1557 \begin_layout Plain Layout
1558
1559 \backslash
1560 end{labels}
1561 \end_layout
1562
1563 \end_inset
1564
1565  around each label text.
1566  This and other special features of 
1567 \begin_inset Flex Code
1568 status collapsed
1569
1570 \begin_layout Plain Layout
1571 labels.sty
1572 \end_layout
1573
1574 \end_inset
1575
1576  are explained in its documentation.
1577 \end_layout
1578
1579 \begin_layout Standard
1580 Someday, someone may write a \SpecialChar LyX
1581  layout file to support this package directly.
1582  Maybe that someone is you.
1583 \end_layout
1584
1585 \begin_layout Subsubsection
1586 Example #3: Paragraph Indentation
1587 \end_layout
1588
1589 \begin_layout Standard
1590 Americans are trained to indent the first line of 
1591 \emph on
1592 every
1593 \emph default
1594  paragraph.
1595  As with all of their other weird quirks, most Americans will whine and
1596  moan until they can have their way and indent the first line of all paragraphs.
1597  (Yes, we're joking.
1598  (We are?) 
1599 \emph on
1600 Yeah
1601 \emph default
1602 , we are.)
1603 \end_layout
1604
1605 \begin_layout Standard
1606 Of course, this behavior isn't standard typography.
1607  In books, you typically only indent the first line of a paragraph 
1608 \emph on
1609 if
1610 \emph default
1611  it follows another one.
1612  The idea behind indenting the first line of a paragraph is to distinguish
1613  neighboring paragraphs from one another.
1614  If there is no previous paragraph—for example, if it follows a figure or
1615  is the first paragraph in a section—then there is no need for indentation.
1616  
1617 \end_layout
1618
1619 \begin_layout Standard
1620 If you're a typical American (we're still joking!), though, you don't care
1621  about such esoteric things; you want your indentation! Add this to the
1622  preamble:
1623 \end_layout
1624
1625 \begin_layout LyX-Code
1626
1627 \backslash
1628 usepackage{indentfirst}
1629 \end_layout
1630
1631 \begin_layout Standard
1632 If your \SpecialChar TeX
1633  distribution isn't braindead, you'll have this package, and all
1634  of your paragraphs will get the indentation the Founding Fathers intended
1635  they should have.
1636 \end_layout
1637
1638 \begin_layout Subsubsection
1639 Example #4: This Document
1640 \end_layout
1641
1642 \begin_layout Standard
1643 You can also check out the preamble of this document to get an idea of some
1644  of the advanced things you can do.
1645 \end_layout
1646
1647 \begin_layout Section
1648 \SpecialChar LyX
1649  and \SpecialChar LaTeX
1650  Errors
1651 \end_layout
1652
1653 \begin_layout Standard
1654 When \SpecialChar LyX
1655  calls \SpecialChar LaTeX
1656 , it tells \SpecialChar LaTeX
1657  to blithely ignore any errors and keep going.
1658  It then uses the logfile from the \SpecialChar LaTeX
1659  run to do a post-mortem.
1660  After analyzing the logfile, \SpecialChar LyX
1661  displays a dialog listing the errors.
1662  Clicking on any one of them will take you to the position in your \SpecialChar LyX
1663  file
1664  where the error occurred.
1665 \begin_inset Foot
1666 status collapsed
1667
1668 \begin_layout Plain Layout
1669 Well, usually.
1670  Analyzing the logfile is a tough job, and \SpecialChar LyX
1671  doesn't always go to the right
1672  line.
1673  There are also cases where \SpecialChar LaTeX
1674  reports the error on one line, but the actual
1675  error is earlier.
1676  This is not unlike forgetting a closing brace in a program: You'll get
1677  an error, but only later.
1678 \end_layout
1679
1680 \end_inset
1681
1682
1683 \end_layout
1684
1685 \begin_layout Standard
1686 Some folks also like to look at the log file directly: It is available from
1687  
1688 \begin_inset Flex Noun
1689 status collapsed
1690
1691 \begin_layout Plain Layout
1692 Document\SpecialChar menuseparator
1693 LaTeX
1694 \begin_inset space ~
1695 \end_inset
1696
1697 Log
1698 \end_layout
1699
1700 \end_inset
1701
1702 .
1703  There are some fairly common error messages and warnings.
1704  We'll cover those here.
1705  You should look at a good \SpecialChar LaTeX
1706  book for a complete listing.
1707 \end_layout
1708
1709 \begin_layout Itemize
1710 \begin_inset Flex Code
1711 status collapsed
1712
1713 \begin_layout Plain Layout
1714 LaTeX Warning
1715 \end_layout
1716
1717 \end_inset
1718
1719
1720 \begin_inset Newline newline
1721 \end_inset
1722
1723 Anything beginning with these words is a warning message for the purpose
1724  of 
1725 \begin_inset Quotes eld
1726 \end_inset
1727
1728 debugging
1729 \begin_inset Quotes erd
1730 \end_inset
1731
1732  the \SpecialChar LaTeX
1733  code itself.
1734  You'll get messages like this if you added or changed cross-references
1735  or bibliography entries, in which case, \SpecialChar LaTeX
1736  is trying to tell you that you
1737  need to make another run.
1738  You can by-and-large ignore these.
1739 \end_layout
1740
1741 \begin_layout Itemize
1742 \begin_inset Flex Code
1743 status collapsed
1744
1745 \begin_layout Plain Layout
1746 LaTeX Font Warning
1747 \end_layout
1748
1749 \end_inset
1750
1751
1752 \begin_inset Newline newline
1753 \end_inset
1754
1755 Another warning message, this time about fonts which \SpecialChar LaTeX
1756  couldn't find.
1757  The rest of the message will often say something about a replacement font
1758  that \SpecialChar LaTeX
1759  used.
1760  You can safely ignore these, too.
1761 \end_layout
1762
1763 \begin_layout Itemize
1764 \begin_inset Flex Code
1765 status collapsed
1766
1767 \begin_layout Plain Layout
1768 Overfull 
1769 \backslash
1770 hbox
1771 \end_layout
1772
1773 \end_inset
1774
1775
1776 \begin_inset Newline newline
1777 \end_inset
1778
1779 \SpecialChar LaTeX
1780  absolutely 
1781 \emph on
1782 loves
1783 \emph default
1784  to spew these out.
1785  They are warnings about lines that were too long and run past the right
1786  margin.
1787  Almost always, this is unnoticeable in the final output.
1788  (It can be just a point or two.) Or, only one or two characters extend past
1789  the margin.
1790  \SpecialChar LaTeX
1791  seems to generate at least one of these messages for just about any document
1792  you write.
1793 \begin_inset Newline newline
1794 \end_inset
1795
1796 You can ignore these messages.
1797  Your eyes will tell you if there's a problem with something that's too
1798  wide; just look at the output.
1799 \begin_inset Foot
1800 status collapsed
1801
1802 \begin_layout Plain Layout
1803 You can also enable the `draft' option in 
1804 \begin_inset Flex Noun
1805 status collapsed
1806
1807 \begin_layout Plain Layout
1808 Document\SpecialChar menuseparator
1809 Settings
1810 \end_layout
1811
1812 \end_inset
1813
1814 , and then \SpecialChar LaTeX
1815  will draw a black box in the margin of lines that are overfull.
1816 \end_layout
1817
1818 \end_inset
1819
1820
1821 \end_layout
1822
1823 \begin_layout Itemize
1824 \begin_inset Flex Code
1825 status collapsed
1826
1827 \begin_layout Plain Layout
1828 Underfull 
1829 \backslash
1830 hbox
1831 \end_layout
1832
1833 \end_inset
1834
1835
1836 \begin_inset Newline newline
1837 \end_inset
1838
1839 Not quite as common as its cousin.
1840  \SpecialChar LaTeX
1841  seems to like to print lines that are a bit too wide as opposed to ones
1842  that are a bit too narrow.
1843  We have no idea why.
1844 \end_layout
1845
1846 \begin_layout Itemize
1847 \begin_inset Flex Code
1848 status collapsed
1849
1850 \begin_layout Plain Layout
1851 Overfull 
1852 \backslash
1853 vbox
1854 \end_layout
1855
1856 \end_inset
1857
1858  and 
1859 \begin_inset Flex Code
1860 status collapsed
1861
1862 \begin_layout Plain Layout
1863 Underfull 
1864 \backslash
1865 vbox
1866 \end_layout
1867
1868 \end_inset
1869
1870
1871 \begin_inset Newline newline
1872 \end_inset
1873
1874 Warnings about troubles breaking the page.
1875  Once again, just look at the output.
1876  Your eyes will tell you where something has gone wrong.
1877 \end_layout
1878
1879 \begin_layout Itemize
1880 \begin_inset Flex Code
1881 status collapsed
1882
1883 \begin_layout Plain Layout
1884 LaTeX Error: File 
1885 \begin_inset Quotes els
1886 \end_inset
1887
1888 Xxxx
1889 \begin_inset Quotes ers
1890 \end_inset
1891
1892  not found
1893 \end_layout
1894
1895 \end_inset
1896
1897
1898 \begin_inset Newline newline
1899 \end_inset
1900
1901 The file 
1902 \begin_inset Quotes eld
1903 \end_inset
1904
1905 Xxxx
1906 \begin_inset Quotes erd
1907 \end_inset
1908
1909  isn't installed on this system.
1910  This usually appears because some package your document needs isn't installed.
1911  If you didn't touch the preamble or didn't use the 
1912 \begin_inset Flex Code
1913 status collapsed
1914
1915 \begin_layout Plain Layout
1916
1917 \backslash
1918 usepackage{}
1919 \end_layout
1920
1921 \end_inset
1922
1923  command, then one of the packages \SpecialChar LyX
1924  tried to load is missing.
1925  Use 
1926 \begin_inset Flex Noun
1927 status collapsed
1928
1929 \begin_layout Plain Layout
1930 Help\SpecialChar menuseparator
1931 \SpecialChar LaTeX
1932  Configuration
1933 \end_layout
1934
1935 \end_inset
1936
1937  to get a list of packages that \SpecialChar LyX
1938  knows about.
1939  This file is updated whenever you reconfigure \SpecialChar LyX
1940  (using 
1941 \begin_inset Flex Noun
1942 status collapsed
1943
1944 \begin_layout Plain Layout
1945 Tools\SpecialChar menuseparator
1946 Reconfigure
1947 \end_layout
1948
1949 \end_inset
1950
1951 ) and tells you which packages have been detected and what they do.
1952 \begin_inset Newline newline
1953 \end_inset
1954
1955 If you did use the 
1956 \begin_inset Flex Code
1957 status collapsed
1958
1959 \begin_layout Plain Layout
1960
1961 \backslash
1962 usepackage{}
1963 \end_layout
1964
1965 \end_inset
1966
1967  command and the package in question isn't installed, then you'll need to
1968  install it yourself.
1969 \end_layout
1970
1971 \begin_layout Itemize
1972 \begin_inset Flex Code
1973 status collapsed
1974
1975 \begin_layout Plain Layout
1976 LaTeX Error: Unknown option
1977 \end_layout
1978
1979 \end_inset
1980
1981
1982 \begin_inset Newline newline
1983 \end_inset
1984
1985 Error messages beginning with this are trying to tell you that you specified
1986  a bad or undefined option to a package.
1987  Check the package's documentation.
1988 \end_layout
1989
1990 \begin_layout Itemize
1991 \begin_inset Flex Code
1992 status collapsed
1993
1994 \begin_layout Plain Layout
1995 Undefined control sequence
1996 \end_layout
1997
1998 \end_inset
1999
2000
2001 \begin_inset Newline newline
2002 \end_inset
2003
2004 If you've inserted \SpecialChar LaTeX
2005  code into your document, but made a typo, you'll get
2006  one of these.
2007  You may have forgotten to load a package.
2008  In any case, this error message usually means that you used an undefined
2009  command.
2010  
2011 \end_layout
2012
2013 \begin_layout Standard
2014 There are other error and warning messages.
2015  Some are self-explanatory.
2016  These are usually \SpecialChar LaTeX
2017  messages.
2018  Others are downright cryptic.
2019  These are usually \SpecialChar TeX
2020  error messages, and we really have 
2021 \emph on
2022 no clue
2023 \emph default
2024  what they mean or how to decipher them.
2025  No-one does.
2026 \end_layout
2027
2028 \begin_layout Standard
2029 There's a general sequence you should follow if you get error messages:
2030 \end_layout
2031
2032 \begin_layout Enumerate
2033 Look at the \SpecialChar LaTeX
2034  code you inserted for typos.
2035 \end_layout
2036
2037 \begin_layout Enumerate
2038 If there are no typos, check that you used the command(s) correctly.
2039 \end_layout
2040
2041 \begin_layout Enumerate
2042 If you get a bunch of error boxes piled up at the very top of the document—and
2043  especially if you see a 
2044 \begin_inset Quotes eld
2045 \end_inset
2046
2047
2048 \begin_inset Flex Code
2049 status collapsed
2050
2051 \begin_layout Plain Layout
2052 Missing 
2053 \backslash
2054 begin{document}
2055 \end_layout
2056
2057 \end_inset
2058
2059
2060 \begin_inset Quotes erd
2061 \end_inset
2062
2063  error—it means that there are errors in the preamble.
2064  Start debugging your preamble.
2065 \end_layout
2066
2067 \begin_layout Enumerate
2068 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2069  code to the
2070  document, the first suspect is your \SpecialChar LaTeX
2071  distribution itself.
2072  Check for missing packages and install them.
2073 \end_layout
2074
2075 \begin_layout Enumerate
2076 Okay, so there are no missing packages.
2077  Did you use any of the fine-tuning options in \SpecialChar LyX
2078 ? Specifically, did you 
2079 \emph on
2080 misuse
2081 \emph default
2082  any of them, like trying to manually insert lots of 
2083 \begin_inset Flex Code
2084 status collapsed
2085
2086 \begin_layout Plain Layout
2087 Protected
2088 \begin_inset space ~
2089 \end_inset
2090
2091 Blanks
2092 \end_layout
2093
2094 \end_inset
2095
2096
2097 \begin_inset Flex Code
2098 status collapsed
2099
2100 \begin_layout Plain Layout
2101 Linebreaks
2102 \end_layout
2103
2104 \end_inset
2105
2106 , or 
2107 \begin_inset Flex Code
2108 status collapsed
2109
2110 \begin_layout Plain Layout
2111 Pagebreaks
2112 \end_layout
2113
2114 \end_inset
2115
2116 ? Did you try to kludge something together with these instead of using the
2117  appropriate paragraph environment?
2118 \end_layout
2119
2120 \begin_layout Enumerate
2121 All right, you didn't use any of the fine-tuning options, you played by
2122  the rules.
2123  Did you try to pull a fancy maneuver? Did you do something funky inside
2124  a table or an equation, like inserting a graphic into a table cell?
2125 \end_layout
2126
2127 \begin_layout Enumerate
2128 Do you have long sections of text where \SpecialChar LaTeX
2129  cannot find a place to break a
2130  line? By default, \SpecialChar LaTeX
2131  is rather strict about how much extra inter-word spacing
2132  it will add in order to break a line.
2133  Preferably, you should rework the paragraph to avoid the problem.
2134 \end_layout
2135
2136 \begin_layout Enumerate
2137 Did you go overboard with the nesting? \SpecialChar LyX
2138  (currently) doesn't check to make
2139  sure you're in the limits for nesting environments.
2140  If you nested a bunch of environments to the 
2141 \begin_inset Formula $17^{\mathrm{th}}$
2142 \end_inset
2143
2144  level, that's the problem.
2145  (The limit in \SpecialChar LaTeX
2146  is five.)
2147 \end_layout
2148
2149 \begin_layout Enumerate
2150 Okay, you didn't get any error messages, but your output looks awful.
2151  If you have a table or figure that's too wide or long for the page, you
2152  need to:
2153 \end_layout
2154
2155 \begin_deeper
2156 \begin_layout Enumerate
2157 rescale the figure so it fits.
2158 \end_layout
2159
2160 \begin_layout Enumerate
2161 trim down the table so it fits.
2162 \end_layout
2163
2164 \end_deeper
2165 \begin_layout Enumerate
2166 If something else is wrong with the output, and you didn't try to pull anything
2167  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2168 \end_layout
2169
2170 \begin_layout Standard
2171 If all this doesn't help—well, then 
2172 \emph on
2173 perhaps
2174 \emph default
2175  you might have found a bug in \SpecialChar LyX
2176 \SpecialChar ldots
2177 .
2178 \end_layout
2179
2180 \begin_layout Chapter
2181 Document classes
2182 \end_layout
2183
2184 \begin_layout Standard
2185
2186 \change_inserted 893223064 1464852146
2187 This section will be updated in due course.
2188 \end_layout
2189
2190 \begin_layout Standard
2191 Special Document Classes
2192 \end_layout
2193
2194 \begin_layout Section
2195 A&A Paper
2196 \end_layout
2197
2198 \begin_layout Standard
2199 by 
2200 \noun on
2201 Peter Sütterlin
2202 \end_layout
2203
2204 \begin_layout Subsection
2205 Introduction
2206 \end_layout
2207
2208 \begin_layout Standard
2209 This section describes how \SpecialChar LyX
2210  can be used to write articles for submission
2211  to the scientific journal 
2212 \emph on
2213 Astronomy and Astrophysics
2214 \emph default
2215  (
2216 \begin_inset Flex URL
2217 status collapsed
2218
2219 \begin_layout Plain Layout
2220
2221 http://www.edpsciences.fr/aa/
2222 \end_layout
2223
2224 \end_inset
2225
2226 ) using Version 5.01 of the document class 
2227 \family typewriter
2228 aa.cls
2229 \family default
2230 .
2231  This package can be downloaded from the ftp site
2232 \end_layout
2233
2234 \begin_layout Standard
2235 \begin_inset VSpace medskip
2236 \end_inset
2237
2238
2239 \end_layout
2240
2241 \begin_layout Standard
2242 \align center
2243 \begin_inset Flex URL
2244 status collapsed
2245
2246 \begin_layout Plain Layout
2247
2248 ftp://ftp.edpsciences.org/pub/aa/readme.html
2249 \end_layout
2250
2251 \end_inset
2252
2253
2254 \end_layout
2255
2256 \begin_layout Standard
2257 \begin_inset VSpace medskip
2258 \end_inset
2259
2260
2261 \end_layout
2262
2263 \begin_layout Standard
2264 A manual comes together with that package, and this text is not meant to
2265  replace the original manual but is merely a short guide in how to realize
2266  the correct form of your paper.
2267  
2268 \end_layout
2269
2270 \begin_layout Standard
2271 Please note that the publisher of the journal was changed from Springer
2272  to EDP Sciences starting January 1, 2001.
2273  That change involved also some slight changes to the style files, namely
2274  the removal of the thesaurus command.
2275  The \SpecialChar LyX
2276  class aa supports the newest version of these style files, V 5.01.
2277  If you have an older version installed, please upgrade.
2278  For compatibility, the old (version 4) layout has been kept as 
2279 \family sans
2280 article (A&A V4)
2281 \family default
2282 .
2283  Please refer to the comments in 
2284 \family typewriter
2285 \SpecialChar LyX
2286 Dir/layouts/aapaper.layout
2287 \family default
2288 .
2289 \end_layout
2290
2291 \begin_layout Subsection
2292 Getting started
2293 \end_layout
2294
2295 \begin_layout Standard
2296 It is recommended you start from the example template distributed with \SpecialChar LyX
2297 .
2298  If you are not using a template, note the following settings:
2299 \end_layout
2300
2301 \begin_layout Itemize
2302 Select 
2303 \family sans
2304 article (A&A)
2305 \family default
2306  in the 
2307 \family sans
2308 Document\SpecialChar menuseparator
2309 Settings
2310 \family default
2311  dialog (OK, that one was obvious).
2312 \end_layout
2313
2314 \begin_layout Itemize
2315 Don't change the option 
2316 \family sans
2317 Page
2318 \begin_inset space ~
2319 \end_inset
2320
2321 style
2322 \family default
2323 : Leave it set to 
2324 \family sans
2325 default
2326 \family default
2327 .
2328  The whole layout is done by the macros, you shouldn't change anything.
2329 \end_layout
2330
2331 \begin_layout Subsection
2332 The header block
2333 \end_layout
2334
2335 \begin_layout Standard
2336 First thing to enter is the header information.
2337  It consists of seven entries, of which some are optional.
2338  They are
2339 \end_layout
2340
2341 \begin_layout Itemize
2342
2343 \family sans
2344 Title
2345 \family default
2346 : [required] 
2347 \end_layout
2348
2349 \begin_layout Itemize
2350
2351 \family sans
2352 Subtitle
2353 \family default
2354 : [optional] 
2355 \end_layout
2356
2357 \begin_layout Itemize
2358
2359 \family sans
2360 Author
2361 \family default
2362 : [required]
2363 \end_layout
2364
2365 \begin_layout Itemize
2366
2367 \family sans
2368 Address
2369 \family default
2370 : [required]
2371 \end_layout
2372
2373 \begin_layout Itemize
2374
2375 \family sans
2376 Offprints
2377 \family default
2378 : [optional] if more than one author: whom to contact for offprint requests.
2379 \end_layout
2380
2381 \begin_layout Itemize
2382
2383 \family sans
2384 Mail
2385 \family default
2386 : [optional] mail address for contacts.
2387 \end_layout
2388
2389 \begin_layout Itemize
2390
2391 \family sans
2392 Date
2393 \family default
2394 : [required].
2395  Suggested format is 
2396 \family typewriter
2397 Received: <date>; Accepted <date> 
2398 \end_layout
2399
2400 \begin_layout Standard
2401 There is no need to issue the 
2402 \family typewriter
2403
2404 \backslash
2405 maketitle
2406 \family default
2407  command, this is done automatically by \SpecialChar LyX
2408  when the header is finished.
2409  Although the order of the single header entries doesn't matter it is advised
2410  to keep the above sequence, just to get the best optics and meets the layout
2411  of the real document.
2412 \end_layout
2413
2414 \begin_layout Standard
2415 If you want to place footnotes in the header block, e.
2416 \begin_inset space \thinspace{}
2417 \end_inset
2418
2419 g.
2420 \begin_inset space \space{}
2421 \end_inset
2422
2423 to state your present address, just use the standard footnote via the menu
2424  
2425 \family sans
2426 Insert\SpecialChar menuseparator
2427 Footnote.
2428
2429 \family default
2430  \SpecialChar LyX
2431  will automagically use the term 
2432 \family typewriter
2433
2434 \backslash
2435 thanks{}
2436 \family default
2437  in that case.
2438 \end_layout
2439
2440 \begin_layout Standard
2441 In addition to these topics, the macros use three additional \SpecialChar LaTeX
2442  commands that
2443  have no counterpart in \SpecialChar LyX
2444 :
2445 \end_layout
2446
2447 \begin_layout Itemize
2448
2449 \family typewriter
2450
2451 \backslash
2452 and
2453 \family default
2454  to separate different names for more than one author and institute, respectivel
2455 y.
2456 \end_layout
2457
2458 \begin_layout Itemize
2459
2460 \family typewriter
2461
2462 \backslash
2463 inst{<nr>}
2464 \family default
2465 to mark corresponding author/institute pairs.
2466  The institutes are numbered sequentially as they appear in the 
2467 \family sans
2468 Address
2469 \family default
2470  field, so you have to put a marker to each author.
2471 \end_layout
2472
2473 \begin_layout Itemize
2474
2475 \family typewriter
2476
2477 \backslash
2478 email{address}
2479 \family default
2480  to supply an email address for fast contact.
2481 \end_layout
2482
2483 \begin_layout Standard
2484 In all cases, the appropriate command has to be entered in \SpecialChar LyX
2485  and marked as
2486  \SpecialChar LaTeX
2487  code.
2488  See the examples.
2489  
2490 \end_layout
2491
2492 \begin_layout Subsection
2493 The abstract
2494 \end_layout
2495
2496 \begin_layout Standard
2497 The abstract should immediately follow the header block.
2498  With version 5 the abstract environment was changed to a command, and there
2499  is now a resctriction to only one paragraph.
2500  In addition, it should contain an entry with the keywords.
2501  This is not yet implemented for \SpecialChar LyX
2502 , therefore you have to enter the \SpecialChar LaTeX
2503  command
2504  
2505 \family typewriter
2506
2507 \backslash
2508 keywords{}
2509 \family default
2510  by hand and mark it as \SpecialChar LaTeX
2511  code.
2512  Refer to the example paper.
2513 \end_layout
2514
2515 \begin_layout Subsection
2516 Supported environments
2517 \end_layout
2518
2519 \begin_layout Standard
2520 The A&A paper layout supports the following environments for structuring
2521  your text:
2522 \end_layout
2523
2524 \begin_layout Itemize
2525
2526 \family sans
2527 Standard
2528 \end_layout
2529
2530 \begin_layout Itemize
2531
2532 \family sans
2533 Section
2534 \end_layout
2535
2536 \begin_layout Itemize
2537
2538 \family sans
2539 Subsection
2540 \end_layout
2541
2542 \begin_layout Itemize
2543
2544 \family sans
2545 Subsubsection
2546 \end_layout
2547
2548 \begin_layout Itemize
2549
2550 \family sans
2551 Itemize
2552 \end_layout
2553
2554 \begin_layout Itemize
2555
2556 \family sans
2557 Enumerate
2558 \end_layout
2559
2560 \begin_layout Itemize
2561
2562 \family sans
2563 Description
2564 \end_layout
2565
2566 \begin_layout Itemize
2567
2568 \family sans
2569 Caption
2570 \end_layout
2571
2572 \begin_layout Itemize
2573
2574 \family sans
2575 Abstract
2576 \end_layout
2577
2578 \begin_layout Itemize
2579
2580 \family sans
2581 Acknowledgment
2582 \end_layout
2583
2584 \begin_layout Itemize
2585
2586 \family sans
2587 Bibliography
2588 \end_layout
2589
2590 \begin_layout Itemize
2591
2592 \family sans
2593 \SpecialChar LaTeX
2594
2595 \end_layout
2596
2597 \begin_layout Subsection
2598 Commands not supported by \SpecialChar LyX
2599
2600 \end_layout
2601
2602 \begin_layout Standard
2603 Some commands are not yet supported by the 
2604 \family sans
2605 paper (A&A)
2606 \family default
2607  layout for \SpecialChar LyX
2608 .
2609  Some have already been mentioned.
2610  For the sake of completeness, they are listed all together here:
2611 \end_layout
2612
2613 \begin_layout Itemize
2614
2615 \family typewriter
2616
2617 \backslash
2618 and
2619 \end_layout
2620
2621 \begin_layout Itemize
2622
2623 \family typewriter
2624
2625 \backslash
2626 email
2627 \end_layout
2628
2629 \begin_layout Itemize
2630
2631 \family typewriter
2632
2633 \backslash
2634 appendix
2635 \end_layout
2636
2637 \begin_layout Itemize
2638
2639 \family typewriter
2640
2641 \backslash
2642 authorrunning
2643 \end_layout
2644
2645 \begin_layout Itemize
2646
2647 \family typewriter
2648
2649 \backslash
2650 inst{}
2651 \end_layout
2652
2653 \begin_layout Itemize
2654
2655 \family typewriter
2656
2657 \backslash
2658 keywords{}
2659 \end_layout
2660
2661 \begin_layout Itemize
2662
2663 \family typewriter
2664
2665 \backslash
2666 object{}
2667 \end_layout
2668
2669 \begin_layout Itemize
2670
2671 \family typewriter
2672
2673 \backslash
2674 titlerunning{}
2675 \end_layout
2676
2677 \begin_layout Standard
2678 If you want to use any of these commands, you have to enter them yourself.
2679  
2680 \series bold
2681 Do not forget to mark them as \SpecialChar LaTeX
2682  code!
2683 \end_layout
2684
2685 \begin_layout Subsection
2686 Figure and Table Floats
2687 \end_layout
2688
2689 \begin_layout Standard
2690 \SpecialChar LyX
2691  provides support for the necessary float environments 
2692 \family sans
2693 figure, figure*, table
2694 \family default
2695  and 
2696 \family sans
2697 table*
2698 \family default
2699 , therefore we won't tell much about it here.
2700  Refer to the 
2701 \emph on
2702 User's
2703 \begin_inset space ~
2704 \end_inset
2705
2706 Guide
2707 \emph default
2708 .
2709  Just remember that tables should be left-aligned.
2710  For that, select the table and change the alignment in 
2711 \family sans
2712 Edit\SpecialChar menuseparator
2713 Paragraph
2714 \begin_inset space ~
2715 \end_inset
2716
2717 Settings.
2718 \end_layout
2719
2720 \begin_layout Standard
2721 There is only one special thing: the figures with caption besides the figure.
2722  To create such a figure, you have to do the following:
2723 \end_layout
2724
2725 \begin_layout Enumerate
2726 Create a wide figure float: 
2727 \family sans
2728 Insert\SpecialChar menuseparator
2729 Float\SpecialChar menuseparator
2730 Figure
2731 \family default
2732 , then right click in the figure and select 
2733 \family sans
2734 Span
2735 \begin_inset space ~
2736 \end_inset
2737
2738 columns
2739 \family default
2740 .
2741 \end_layout
2742
2743 \begin_layout Enumerate
2744 Enter your caption text.
2745 \end_layout
2746
2747 \begin_layout Enumerate
2748 Press 
2749 \family sans
2750 Return
2751 \family default
2752  to move the cursor above the caption.
2753 \end_layout
2754
2755 \begin_layout Enumerate
2756 Insert your figure
2757 \end_layout
2758
2759 \begin_layout Enumerate
2760 Position the cursor behind the figure and insert a horizontal fill: 
2761 \family sans
2762 Insert\SpecialChar menuseparator
2763 Special
2764 \begin_inset space ~
2765 \end_inset
2766
2767 Character\SpecialChar menuseparator
2768 Horizontal
2769 \begin_inset space ~
2770 \end_inset
2771
2772 Fill
2773 \family default
2774 .
2775 \end_layout
2776
2777 \begin_layout Enumerate
2778 Switch to \SpecialChar LaTeX
2779  mode: 
2780 \family sans
2781 M-c
2782 \begin_inset space ~
2783 \end_inset
2784
2785 t
2786 \family default
2787 .
2788 \end_layout
2789
2790 \begin_layout Enumerate
2791 Enter 
2792 \family typewriter
2793
2794 \backslash
2795 parbox[b]{55mm}{
2796 \family default
2797 .
2798  
2799 \series bold
2800 Do not close the brace!
2801 \end_layout
2802
2803 \begin_layout Enumerate
2804 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
2805  mode and insert
2806  the closing brace: 
2807 \family sans
2808 M-c
2809 \begin_inset space ~
2810 \end_inset
2811
2812 t
2813 \family default
2814  
2815 \family typewriter
2816 }
2817 \family default
2818 .
2819 \end_layout
2820
2821 \begin_layout Standard
2822 Also, refer to the figures in the example paper.
2823 \end_layout
2824
2825 \begin_layout Subsection
2826 Referee layout
2827 \end_layout
2828
2829 \begin_layout Standard
2830 For submission, the paper has to be formated in a special double-spacing
2831  layout.
2832  For this purpose, you have to give the option 
2833 \family typewriter
2834 referee
2835 \family default
2836  to the documentclass.
2837  This must be done using the extra class options field in the 
2838 \family sans
2839 Document\SpecialChar menuseparator
2840 Settings
2841 \family default
2842  dialog.
2843  Just enter the string 
2844 \family typewriter
2845 referee
2846 \family default
2847  there.
2848 \end_layout
2849
2850 \begin_layout Subsection
2851 The example paper
2852 \end_layout
2853
2854 \begin_layout Standard
2855 The 
2856 \family sans
2857 Examples
2858 \family default
2859  directory contains an example paper written with \SpecialChar LyX
2860 .
2861  It is the example paper from the original macro package, translated to
2862  \SpecialChar LyX
2863 .
2864  Use it for inspiration, and compare the original \SpecialChar LaTeX
2865  code with \SpecialChar LyX
2866  way of writing.
2867 \end_layout
2868
2869 \begin_layout Section
2870 AAS\SpecialChar TeX
2871
2872 \end_layout
2873
2874 \begin_layout Standard
2875 by 
2876 \noun on
2877 Mike Ressler
2878 \end_layout
2879
2880 \begin_layout Subsection
2881 Introduction
2882 \end_layout
2883
2884 \begin_layout Standard
2885 AAS\SpecialChar TeX
2886  is a set of macros produced by the American Astronomical Society to
2887  facilitate electronic manuscript submission to the three journals they
2888  publish: the Astrophysical Journal (including the Letters and Supplement),
2889  the Astronomical Journal, and the Publications of the Astronomical Society
2890  of the Pacific.
2891  \SpecialChar LyX
2892  has proven to be an excellent tool for generating these documents, especially
2893  given its equation, citation, and figure handling capabilities.
2894  \SpecialChar LyX
2895  requires version 5.0 (or higher) of these macros; preferably 5.2, which
2896  is the version described here, or higher.
2897  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
2898 2.09 and are fundamentally
2899  incompatible with \SpecialChar LyX
2900 .
2901  The AAS\SpecialChar TeX
2902  package may be downloaded from the AAS\SpecialChar TeX
2903  Web site
2904 \end_layout
2905
2906 \begin_layout Standard
2907 \begin_inset VSpace medskip
2908 \end_inset
2909
2910
2911 \end_layout
2912
2913 \begin_layout Standard
2914 \align center
2915 \begin_inset Flex URL
2916 status collapsed
2917
2918 \begin_layout Plain Layout
2919
2920 https://aas.org/aastex/aastex-downloads
2921 \end_layout
2922
2923 \end_inset
2924
2925
2926 \end_layout
2927
2928 \begin_layout Standard
2929 \begin_inset VSpace medskip
2930 \end_inset
2931
2932
2933 \end_layout
2934
2935 \begin_layout Standard
2936 A complete user guide is contained in that package and you should familiarize
2937  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
2938 .
2939  \SpecialChar LyX
2940  will not reduce the need to figure out all the AAS\SpecialChar TeX
2941  commands, it will only
2942  reduce the drudgery of typing everything in.
2943  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
2944  document conforms
2945  completely to the requirements of the journal to which you are submitting
2946  your paper.
2947 \end_layout
2948
2949 \begin_layout Subsection
2950 Starting a New Paper
2951 \end_layout
2952
2953 \begin_layout Standard
2954 I strongly suggest that you start with the AAS\SpecialChar TeX
2955  template file.
2956  Click on 
2957 \family sans
2958 File\SpecialChar menuseparator
2959 New from
2960 \family default
2961  
2962 \family sans
2963 Template
2964 \family default
2965 , enter the new file name, then choose the 
2966 \family typewriter
2967 aastex.lyx
2968 \family default
2969  template.
2970  This will show the most common fields found in a manuscript.
2971  Simply overwrite the existing text (including the brackets, 
2972 \family typewriter
2973 <>
2974 \family default
2975 ) with the correct information.
2976  Many of the AAS\SpecialChar TeX
2977  commands and environments can be implemented directly in
2978  \SpecialChar LyX
2979 , but some cannot: most noticeably 
2980 \family typewriter
2981
2982 \backslash
2983 altaffilmark
2984 \family default
2985  and 
2986 \family typewriter
2987
2988 \backslash
2989 altaffiltext
2990 \family default
2991 , which should stick out like a sore thumb if you actually just opened the
2992  template file.
2993  For commands such as these, the \SpecialChar LaTeX
2994  code must be entered directly and marked
2995  as such.
2996  Such commands are referred to as \SpecialChar TeX
2997  code, or Evil Red Text.
2998  I tried to minimize the amount of \SpecialChar TeX
2999  code needed in an AAS\SpecialChar TeX
3000  document, but
3001  there is still a bit more required than any of us would like.
3002 \end_layout
3003
3004 \begin_layout Subsection
3005 Finishing Your Paper
3006 \end_layout
3007
3008 \begin_layout Standard
3009 When the paper is finished to your satisfaction and previews/prints correctly,
3010  there are a few 
3011 \begin_inset Quotes eld
3012 \end_inset
3013
3014 postprocessing
3015 \begin_inset Quotes erd
3016 \end_inset
3017
3018  actions which need to be done before you submit it to the journals.
3019  
3020 \end_layout
3021
3022 \begin_layout Enumerate
3023 Export your paper as a \SpecialChar LaTeX
3024  file (
3025 \family sans
3026 File\SpecialChar menuseparator
3027 Export\SpecialChar menuseparator
3028 \SpecialChar LaTeX
3029
3030 \family default
3031 ).
3032  
3033 \end_layout
3034
3035 \begin_layout Enumerate
3036 Edit the resulting 
3037 \family typewriter
3038 .tex
3039 \family default
3040  file with your favorite text editor
3041 \end_layout
3042
3043 \begin_deeper
3044 \begin_layout Enumerate
3045 remove the comment lines before the 
3046 \family typewriter
3047
3048 \backslash
3049 documentclass
3050 \family default
3051  command
3052 \end_layout
3053
3054 \begin_layout Enumerate
3055 remove the 
3056 \family typewriter
3057
3058 \backslash
3059 usepackage...{fontenc}
3060 \family default
3061  line if it appears (usually just after 
3062 \family typewriter
3063
3064 \backslash
3065 documentclass
3066 \family default
3067 }; also remove the 
3068 \family typewriter
3069
3070 \backslash
3071 secnumdepth
3072 \family default
3073  line if it appears.
3074 \end_layout
3075
3076 \begin_layout Enumerate
3077 remove everything between (and including) the 
3078 \family typewriter
3079
3080 \backslash
3081 makeatletter
3082 \family default
3083  and 
3084 \family typewriter
3085
3086 \backslash
3087 makeatother
3088 \family default
3089  commands, except for any commands you specifically put into the \SpecialChar LaTeX
3090  preamble
3091  (which should appear immediately after the 
3092 \begin_inset Quotes eld
3093 \end_inset
3094
3095 User specified \SpecialChar LaTeX
3096  commands
3097 \begin_inset Quotes erd
3098 \end_inset
3099
3100  comment in the 
3101 \family typewriter
3102 .tex
3103 \family default
3104  file).
3105 \end_layout
3106
3107 \end_deeper
3108 \begin_layout Enumerate
3109 Run the resulting file through \SpecialChar LaTeX
3110  to make sure it still processes correctly.
3111 \end_layout
3112
3113 \begin_layout Enumerate
3114 Reread the journal requirements to make sure your filenames and formats
3115  are correct.
3116 \end_layout
3117
3118 \begin_layout Enumerate
3119 Submit it.
3120 \end_layout
3121
3122 \begin_layout Subsection
3123 Comments On Specific Commands
3124 \end_layout
3125
3126 \begin_layout Standard
3127 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
3128  commands: the
3129  AAS\SpecialChar TeX
3130  User Guide (
3131 \family typewriter
3132 aasguide.tex
3133 \family default
3134 ) gives a good description of each.
3135  Thus it's probably easiest for me to go down the list as found in the guide
3136  and offer comments where necessary.
3137  So let's begin \SpecialChar ldots
3138
3139 \end_layout
3140
3141 \begin_layout Subsubsection
3142 Things that work as expected
3143 \end_layout
3144
3145 \begin_layout Standard
3146 Because they work as you might expect, I simply list them and the section
3147  they are found in: 
3148 \family typewriter
3149
3150 \backslash
3151 documentclass
3152 \family default
3153  (2.1.1), 
3154 \family typewriter
3155
3156 \backslash
3157 begin{document}
3158 \family default
3159  (2.2), 
3160 \family typewriter
3161
3162 \backslash
3163 title
3164 \family default
3165  (2.3), 
3166 \family typewriter
3167
3168 \backslash
3169 author
3170 \family default
3171  (2.3), 
3172 \family typewriter
3173
3174 \backslash
3175 affil
3176 \family default
3177  (2.3), 
3178 \family typewriter
3179
3180 \backslash
3181 abstract
3182 \family default
3183  (2.4), 
3184 \family typewriter
3185
3186 \backslash
3187 keywords
3188 \family default
3189  (2.5), 
3190 \family typewriter
3191
3192 \backslash
3193 section
3194 \family default
3195  (2.7), 
3196 \family typewriter
3197
3198 \backslash
3199 subsection
3200 \family default
3201  (2.7), 
3202 \family typewriter
3203
3204 \backslash
3205 subsubsection
3206 \family default
3207  (2.7), 
3208 \family typewriter
3209
3210 \backslash
3211 paragraph
3212 \family default
3213  (2.7), 
3214 \family typewriter
3215
3216 \backslash
3217 facility
3218 \family default
3219  (2.10), 
3220 \family typewriter
3221
3222 \backslash
3223 begin{displaymath}
3224 \family default
3225  (2.12), 
3226 \family typewriter
3227
3228 \backslash
3229 begin{equation}
3230 \family default
3231  (2.12), 
3232 \family typewriter
3233
3234 \backslash
3235 begin{eqnarray}
3236 \family default
3237  (2.12), 
3238 \family typewriter
3239
3240 \backslash
3241 begin{mathletters}
3242 \family default
3243  (2.12), 
3244 \family typewriter
3245
3246 \backslash
3247 begin{thebibliography}
3248 \family default
3249  (2.13.1), 
3250 \family typewriter
3251
3252 \backslash
3253 bibitem
3254 \family default
3255  (2.13.2), all the cite commands and their variations (2.13.2), the generic
3256  graphicx figure commands (2.14.1), 
3257 \family typewriter
3258
3259 \backslash
3260 begin{table}
3261 \family default
3262  (2.15.4), 
3263 \family typewriter
3264
3265 \backslash
3266 begin{tabular}
3267 \family default
3268  (2.15.4), 
3269 \family typewriter
3270
3271 \backslash
3272 caption
3273 \family default
3274  (2.15.4), 
3275 \family typewriter
3276
3277 \backslash
3278 label
3279 \family default
3280  (2.15.4, amongst other places), 
3281 \family typewriter
3282
3283 \backslash
3284 tablerefs
3285 \family default
3286  (2.15.5), 
3287 \family typewriter
3288
3289 \backslash
3290 tablecomments
3291 \family default
3292  (2.15.5), 
3293 \family typewriter
3294
3295 \backslash
3296 url
3297 \family default
3298  (2.17.4), 
3299 \family typewriter
3300
3301 \backslash
3302 end{document}
3303 \family default
3304  (2.18).
3305 \end_layout
3306
3307 \begin_layout Standard
3308 The following style options also work correctly: 
3309 \family typewriter
3310 longabstract
3311 \family default
3312  (2.4), 
3313 \family typewriter
3314 preprint
3315 \family default
3316  (3.2.1), 
3317 \family typewriter
3318 preprint2
3319 \family default
3320  (3.2.2), 
3321 \family typewriter
3322 eqsecnum
3323 \family default
3324  (3.3), 
3325 \family typewriter
3326 flushrt
3327 \family default
3328  (3.4).
3329  Simply put them in the 
3330 \family sans
3331 Options
3332 \family default
3333  box in 
3334 \family sans
3335 Layout\SpecialChar menuseparator
3336 Document
3337 \family default
3338 .
3339 \end_layout
3340
3341 \begin_layout Subsubsection
3342 Things that work, but require more comment
3343 \end_layout
3344
3345 \begin_layout Standard
3346 The following items work, but require a little more discussion:
3347 \end_layout
3348
3349 \begin_layout Itemize
3350 These items are reserved for use by the journal editors, but you can put
3351  them into the \SpecialChar LaTeX
3352  preamble if you feel compelled to do so: 
3353 \family typewriter
3354
3355 \backslash
3356 received
3357 \family default
3358
3359 \family typewriter
3360
3361 \backslash
3362 revised
3363 \family default
3364
3365 \family typewriter
3366
3367 \backslash
3368 accepted
3369 \family default
3370
3371 \family typewriter
3372
3373 \backslash
3374 ccc
3375 \family default
3376
3377 \family typewriter
3378
3379 \backslash
3380 cpright
3381 \family default
3382  (all from 2.1.3)
3383 \end_layout
3384
3385 \begin_layout Itemize
3386 These items may be placed in the \SpecialChar LaTeX
3387  preamble, and are included as blanks in
3388  the template file: 
3389 \family typewriter
3390
3391 \backslash
3392 slugcomment
3393 \family default
3394  (2.1.4), 
3395 \family typewriter
3396
3397 \backslash
3398 shorttitle
3399 \family default
3400  (2.1.5), 
3401 \family typewriter
3402
3403 \backslash
3404 shortauthors
3405 \family default
3406  (2.1.5)
3407 \end_layout
3408
3409 \begin_layout Itemize
3410
3411 \family typewriter
3412
3413 \backslash
3414 email
3415 \family default
3416  (2.3) – can only be used 
3417 \begin_inset Quotes eld
3418 \end_inset
3419
3420 standalone
3421 \begin_inset Quotes erd
3422 \end_inset
3423
3424 , not in the middle of a paragraph.
3425  Use \SpecialChar TeX
3426  code if you need to embed it.
3427 \end_layout
3428
3429 \begin_layout Itemize
3430
3431 \family typewriter
3432
3433 \backslash
3434 and
3435 \family default
3436  (2.3) – will have extra {} after it.
3437  This should not cause an error.
3438 \end_layout
3439
3440 \begin_layout Itemize
3441
3442 \family typewriter
3443
3444 \backslash
3445 notetoeditor
3446 \family default
3447  (2.6) – can only be used 
3448 \begin_inset Quotes eld
3449 \end_inset
3450
3451 standalone
3452 \begin_inset Quotes erd
3453 \end_inset
3454
3455 , not in the middle of a paragraph.
3456  Use \SpecialChar TeX
3457  code if you need to embed it.
3458 \end_layout
3459
3460 \begin_layout Itemize
3461
3462 \family typewriter
3463
3464 \backslash
3465 placetable
3466 \family default
3467  (2.8) – can't insert a cross-reference tag, you must type the tag name by
3468  hand
3469 \end_layout
3470
3471 \begin_layout Itemize
3472
3473 \family typewriter
3474
3475 \backslash
3476 placefigure
3477 \family default
3478  (2.8) – same as for 
3479 \family typewriter
3480
3481 \backslash
3482 placetable
3483 \end_layout
3484
3485 \begin_layout Itemize
3486
3487 \family typewriter
3488
3489 \backslash
3490 acknowledgements
3491 \family default
3492  (2.9) – will have extra {} after it.
3493  This should not cause an error.
3494 \end_layout
3495
3496 \begin_layout Itemize
3497
3498 \family typewriter
3499
3500 \backslash
3501 appendix
3502 \family default
3503  (2.11) – will have extra {} after it.
3504  This should not cause an error.
3505 \end_layout
3506
3507 \begin_layout Itemize
3508
3509 \family typewriter
3510
3511 \backslash
3512 figcaption
3513 \family default
3514  (2.14.2) – you can insert an optional filename argument by placing the cursor
3515  at the beginning of the text and selecting 
3516 \family sans
3517 Insert\SpecialChar menuseparator
3518 Short Title
3519 \family default
3520 .
3521  
3522 \begin_inset Quotes eld
3523 \end_inset
3524
3525 Short Title
3526 \begin_inset Quotes erd
3527 \end_inset
3528
3529  inserts an optional argument of the type needed by 
3530 \family typewriter
3531
3532 \backslash
3533 figcaption
3534 \family default
3535 .
3536  Hopefully it will be renamed someday.
3537 \end_layout
3538
3539 \begin_layout Itemize
3540
3541 \family typewriter
3542
3543 \backslash
3544 objectname
3545 \family default
3546  (2.17.1) – same as 
3547 \family typewriter
3548
3549 \backslash
3550 figcaption
3551 \family default
3552  for the catalog ID optional parameter
3553 \end_layout
3554
3555 \begin_layout Itemize
3556
3557 \family typewriter
3558
3559 \backslash
3560 dataset
3561 \family default
3562  (2.17.1) – same as 
3563 \family typewriter
3564
3565 \backslash
3566 figcaption
3567 \family default
3568  for the catalog ID optional parameter
3569 \end_layout
3570
3571 \begin_layout Subsubsection
3572 Things not implemented, use \SpecialChar TeX
3573  code
3574 \end_layout
3575
3576 \begin_layout Standard
3577
3578 \family typewriter
3579
3580 \backslash
3581 altaffilmark
3582 \family default
3583  (2.3), 
3584 \family typewriter
3585
3586 \backslash
3587 altaffiltext
3588 \family default
3589  (2.3), 
3590 \family typewriter
3591
3592 \backslash
3593 eqnum
3594 \family default
3595  (2.12), 
3596 \family typewriter
3597
3598 \backslash
3599 setcounter{equation}
3600 \family default
3601  (2.12), Journal name abbreviations (2.13.4), 
3602 \family typewriter
3603
3604 \backslash
3605 figurenum
3606 \family default
3607  (2.14.1), 
3608 \family typewriter
3609
3610 \backslash
3611 epsscale
3612 \family default
3613  (2.14.1), 
3614 \family typewriter
3615
3616 \backslash
3617 plotone
3618 \family default
3619  (2.14.1), 
3620 \family typewriter
3621
3622 \backslash
3623 plottwo
3624 \family default
3625  (2.14.1), 
3626 \family typewriter
3627
3628 \backslash
3629 tablenum
3630 \family default
3631  (2.15.4), 
3632 \family typewriter
3633
3634 \backslash
3635 tableline
3636 \family default
3637  (2.15.4, insert it as the first element in the lefthand cell after where
3638  you want it.
3639  Don't use any of \SpecialChar LyX
3640 's rules in the table), 
3641 \family typewriter
3642
3643 \backslash
3644 tablenotemark
3645 \family default
3646  (2.15.5), 
3647 \family typewriter
3648
3649 \backslash
3650 tablenotetext
3651 \family default
3652  (2.15.5), much of Misc (2.17, except 
3653 \family typewriter
3654
3655 \backslash
3656 objectname
3657 \family default
3658
3659 \family typewriter
3660
3661 \backslash
3662 dataset
3663 \family default
3664
3665 \family typewriter
3666
3667 \backslash
3668 url
3669 \family default
3670 , and 
3671 \family typewriter
3672
3673 \backslash
3674 email
3675 \family default
3676 ; see above), 
3677 \family typewriter
3678
3679 \backslash
3680 singlespace
3681 \family default
3682  (3.1), 
3683 \family typewriter
3684
3685 \backslash
3686 doublespace
3687 \family default
3688  (3.1), 
3689 \family typewriter
3690
3691 \backslash
3692 onecolumn
3693 \family default
3694  (3.2), 
3695 \family typewriter
3696
3697 \backslash
3698 twocolumn
3699 \family default
3700  (3.2)
3701 \end_layout
3702
3703 \begin_layout Subsubsection
3704 Things that cannot be implemented
3705 \end_layout
3706
3707 \begin_layout Standard
3708 \SpecialChar ldots
3709  at least in any meaningful sort of way, so I suggest ignoring them.
3710  They are the references environment (2.13.3), and the deluxetable environment
3711  (2.15).
3712  If you really, really need to use deluxetable, I suggest editing it in
3713  a separate file with a text editor, then using 
3714 \family sans
3715 Insert\SpecialChar menuseparator
3716 Child
3717 \begin_inset space ~
3718 \end_inset
3719
3720 Document
3721 \family default
3722  to include it in your \SpecialChar LyX
3723  document.
3724  See the 
3725 \family typewriter
3726 aas_sample.lyx
3727 \family default
3728  file to see an example of this.
3729 \end_layout
3730
3731 \begin_layout Subsection
3732 FAQs, Tips, Tricks, and Other Ruminations
3733 \end_layout
3734
3735 \begin_layout Subsubsection
3736 Getting \SpecialChar LyX
3737  and AAS\SpecialChar TeX
3738  to cooperate
3739 \end_layout
3740
3741 \begin_layout Standard
3742 It can be a bit tricky to get \SpecialChar LyX
3743  to recognize a new layout and document class.
3744  When all else fails, do this:
3745 \end_layout
3746
3747 \begin_layout Enumerate
3748 Make certain that \SpecialChar LaTeX
3749  can find AAS\SpecialChar TeX
3750 .
3751  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
3752  distribution into a
3753  directory completely unrelated to \SpecialChar LaTeX
3754  or AAS\SpecialChar TeX
3755  and run \SpecialChar LaTeX
3756  on 
3757 \family typewriter
3758 sample.tex
3759 \family default
3760 .
3761 \end_layout
3762
3763 \begin_layout Enumerate
3764 Make certain that 
3765 \family typewriter
3766 aastex.layout
3767 \family default
3768  appears in \SpecialChar LyX
3769 's 
3770 \family typewriter
3771 layouts
3772 \family default
3773  folder
3774 \end_layout
3775
3776 \begin_layout Enumerate
3777 Rerun 
3778 \family sans
3779 Tools\SpecialChar menuseparator
3780 Reconfigure
3781 \family default
3782  in \SpecialChar LyX
3783 , then restart \SpecialChar LyX
3784 .
3785 \end_layout
3786
3787 \begin_layout Enumerate
3788 Open a regular new file, not from a template.
3789  Does AAS\SpecialChar TeX
3790  appear in the class list in 
3791 \family sans
3792 Document\SpecialChar menuseparator
3793 Settings
3794 \family default
3795 ?
3796 \end_layout
3797
3798 \begin_layout Standard
3799 If you get a warning from an existing AAS\SpecialChar TeX
3800  document about not being able
3801  to find the AAS\SpecialChar TeX
3802  layout or a message about 
3803 \begin_inset Quotes eld
3804 \end_inset
3805
3806 You should not mix title layouts with normal ones
3807 \begin_inset Quotes erd
3808 \end_inset
3809
3810 , things haven't been installed correctly.
3811 \end_layout
3812
3813 \begin_layout Subsubsection
3814 \SpecialChar LaTeX
3815  error processing a table 
3816 \end_layout
3817
3818 \begin_layout Standard
3819 \SpecialChar LyX
3820 , by default, attempts to center the table caption/title.
3821  This seems to produce a bad interaction in AAS\SpecialChar TeX
3822  so you should click somewhere
3823  in the caption/title, then select 
3824 \family sans
3825 Edit\SpecialChar menuseparator
3826 Paragraph
3827 \begin_inset space ~
3828 \end_inset
3829
3830 Settings
3831 \family default
3832 , then set the 
3833 \family sans
3834 Alignment
3835 \family default
3836  to 
3837 \family sans
3838 Block
3839 \family default
3840 .
3841  This took care of it for me.
3842 \end_layout
3843
3844 \begin_layout Subsubsection
3845 References
3846 \end_layout
3847
3848 \begin_layout Standard
3849 A couple of things: 1) I have noticed some funny spacing in the reference
3850  entries in the text.
3851  When you enter the bibliography item data, make sure their is 
3852 \emph on
3853 no
3854 \emph default
3855  space between the last author and the parenthesis setting off the year;
3856  
3857 \emph on
3858 e.
3859 \begin_inset space \thinspace{}
3860 \end_inset
3861
3862 g.
3863 \begin_inset space \space{}
3864 \end_inset
3865
3866
3867 \emph default
3868 type 
3869 \family typewriter
3870 Ressler(1992)
3871 \family default
3872 , not 
3873 \family typewriter
3874 Ressler (1992)
3875 \family default
3876 .
3877  2) Entering the references at all is not obvious.
3878  The easiest thing is to start typing your first reference at the end of
3879  the document, then mark it as type 
3880 \family sans
3881 References
3882 \family default
3883 .
3884  That will put a small gray box in front of what you just typed.
3885  Click on the box to fill in the rest of the information.
3886  For new references, go to the end of an existing reference and press return.
3887  That will create a new line with its own box, etc.
3888 \end_layout
3889
3890 \begin_layout Subsubsection
3891 Including EPS files
3892 \end_layout
3893
3894 \begin_layout Standard
3895 Even though AAS\SpecialChar TeX
3896  provides its own figure commands (
3897 \family typewriter
3898
3899 \backslash
3900 plotone
3901 \family default
3902 , for example), I much prefer \SpecialChar LaTeX
3903 's standard figure commands (with the default
3904  graphicx).
3905  You can insert the 
3906 \family typewriter
3907
3908 \backslash
3909 plotone
3910 \family default
3911 , etc.
3912 \begin_inset space ~
3913 \end_inset
3914
3915 commands as \SpecialChar TeX
3916  code into a Figure Float box if you desire, but I never have
3917  much luck getting the layout right.
3918  With the standard graphics, \SpecialChar LyX
3919  will insert a 
3920 \family typewriter
3921
3922 \backslash
3923 usepackage{graphicx}
3924 \family default
3925  command into the \SpecialChar LaTeX
3926  preamble and handle the figures in the standard \SpecialChar LaTeX2e
3927  way,
3928  interspersing the figures in the text.
3929  I believe ApJ accepts figures exactly this way now; AJ might still use
3930  the 
3931 \begin_inset Quotes eld
3932 \end_inset
3933
3934 stack everything at the end
3935 \begin_inset Quotes erd
3936 \end_inset
3937
3938  technique.
3939 \end_layout
3940
3941 \begin_layout Subsubsection
3942 Things I could have done, but didn't
3943 \end_layout
3944
3945 \begin_layout Standard
3946 There are a few 
3947 \begin_inset Quotes eld
3948 \end_inset
3949
3950 pretty
3951 \begin_inset Quotes erd
3952 \end_inset
3953
3954  things I could have implemented, but chose not to.
3955  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
3956  window,
3957  even though it is double-spaced in the paper manuscript.
3958  Also, I chose not to make separate layouts for the preprint and preprint2
3959  styles.
3960  Since I assume you will spend most of your time in the plain manuscript
3961  mode anyway, I decided not to chew up more disk space with this.
3962  
3963 \end_layout
3964
3965 \begin_layout Subsection
3966 Final Caveat
3967 \end_layout
3968
3969 \begin_layout Standard
3970 Your mileage may vary.
3971  I've now had papers published by both ApJ and AJ that have had 98% of the
3972  effort done in \SpecialChar LyX
3973 ; the last 2% was the \SpecialChar LaTeX
3974  post-processing and a few cleanups.
3975  I have had no trouble with the submission process, and I'm sure the journals
3976  were never aware that there might be a difference.
3977  So, go forth and publish!
3978 \end_layout
3979
3980 \begin_layout Section
3981 AMS \SpecialChar LaTeX
3982
3983 \end_layout
3984
3985 \begin_layout Standard
3986 by 
3987 \noun on
3988 David Johnson
3989 \noun default
3990 ; updated by 
3991 \noun on
3992 Richard Heck
3993 \end_layout
3994
3995 \begin_layout Standard
3996 \begin_inset VSpace bigskip
3997 \end_inset
3998
3999
4000 \end_layout
4001
4002 \begin_layout Standard
4003 \noindent
4004 The AMS \SpecialChar LaTeX
4005  layouts are set up to conform to suggested styles for mathematical
4006  papers to be submitted to American Mathematical Society publications.
4007  The layouts are not tailored to a specific journal, but easily can be.
4008  You should refer to the AMS documentation for specific instructions for
4009  each journal (usually it will entail only changing a single line in the
4010  \SpecialChar TeX
4011  output).
4012  That documentation is available on the Web at 
4013 \begin_inset Flex URL
4014 status open
4015
4016 \begin_layout Plain Layout
4017
4018 http://www.ams.org
4019 \end_layout
4020
4021 \end_inset
4022
4023  or by ftp at 
4024 \begin_inset Flex URL
4025 status open
4026
4027 \begin_layout Plain Layout
4028
4029 ftp://ftp.ams.org/pub/tex/amslatex/
4030 \end_layout
4031
4032 \end_inset
4033
4034 .
4035  These layouts are appropriate, and useful, for any mathematical writing.
4036  
4037 \end_layout
4038
4039 \begin_layout Standard
4040 There are two basic AMS \SpecialChar LaTeX
4041  layouts: 
4042 \end_layout
4043
4044 \begin_layout Itemize
4045 amsart: The standard AMS article format.
4046 \end_layout
4047
4048 \begin_layout Itemize
4049 amsbook: the standard AMS book (really, monograph) format.
4050  
4051 \end_layout
4052
4053 \begin_layout Standard
4054 The layouts themselves contain only the minimum necessary to use the AMS
4055  classes.
4056  They do not, in particular, contain any of the `theorem' environments used
4057  for setting theorems, lemmas, and the like.
4058  These are contained, instead, in the 
4059 \begin_inset Flex Code
4060 status collapsed
4061
4062 \begin_layout Plain Layout
4063 Theorems (AMS)
4064 \end_layout
4065
4066 \end_inset
4067
4068  module, which is loaded by default when you select one of the AMS classes.
4069  (It can also be used with other classes and can be removed, if you would
4070  rather use something else.) Less commonly used environments are in the 
4071 \begin_inset Flex Code
4072 status collapsed
4073
4074 \begin_layout Plain Layout
4075 Theorems (AMS-Extended)
4076 \end_layout
4077
4078 \end_inset
4079
4080  module, which must be loaded manually.
4081 \end_layout
4082
4083 \begin_layout Standard
4084 By default, theorems and the like are numbered consecutively throughout
4085  the document, but this may be modified by loading the module 
4086 \begin_inset Flex Code
4087 status collapsed
4088
4089 \begin_layout Plain Layout
4090 Theorems (Order by Section)
4091 \end_layout
4092
4093 \end_inset
4094
4095  or, if you are using 
4096 \begin_inset Flex Code
4097 status collapsed
4098
4099 \begin_layout Plain Layout
4100 book (AMS)
4101 \end_layout
4102
4103 \end_inset
4104
4105 , the module 
4106 \begin_inset Flex Code
4107 status collapsed
4108
4109 \begin_layout Plain Layout
4110 Theorems (Order by Chapter)
4111 \end_layout
4112
4113 \end_inset
4114
4115 .
4116  These will number the results as 
4117 \begin_inset Formula $n.m$
4118 \end_inset
4119
4120 , where the first number refers to the section (or chapter) and the second
4121  refers to the total number of results so far in that section (or chapter).
4122  Many environments are also available unnumbered.
4123  These are indicated by an asterisk at the end.
4124  If you happen to want 
4125 \emph on
4126 only
4127 \emph default
4128  unnumbered results, the module 
4129 \begin_inset Flex Code
4130 status collapsed
4131
4132 \begin_layout Plain Layout
4133 Theorems (Starred)
4134 \end_layout
4135
4136 \end_inset
4137
4138  provides that option.
4139 \end_layout
4140
4141 \begin_layout Standard
4142 Note that these modules do not 
4143 \emph on
4144 have
4145 \emph default
4146  to be used with the AMS classes.
4147  It is perfectly possible to use the 
4148 \begin_inset Flex Code
4149 status collapsed
4150
4151 \begin_layout Plain Layout
4152 Theorems (AMS)
4153 \end_layout
4154
4155 \end_inset
4156
4157  module, and the others mentioned, with other classes, such as 
4158 \begin_inset Flex Code
4159 status collapsed
4160
4161 \begin_layout Plain Layout
4162 article
4163 \end_layout
4164
4165 \end_inset
4166
4167
4168 \begin_inset Flex Code
4169 status collapsed
4170
4171 \begin_layout Plain Layout
4172 report
4173 \end_layout
4174
4175 \end_inset
4176
4177
4178 \begin_inset Flex Code
4179 status collapsed
4180
4181 \begin_layout Plain Layout
4182 book (KOMA-script)
4183 \end_layout
4184
4185 \end_inset
4186
4187 , and so forth.
4188 \end_layout
4189
4190 \begin_layout Subsection
4191 What these layouts provide
4192 \end_layout
4193
4194 \begin_layout Standard
4195 There is a long list of included environments provided by these layouts.
4196  In AMS-\SpecialChar LaTeX
4197 , there is, in fact, an opportunity to define an unlimited variety
4198  of `theorem' environments.
4199  However, the AMS recommends the environments that are available in \SpecialChar LyX
4200 .
4201  
4202 \end_layout
4203
4204 \begin_layout Standard
4205 The following environments—as well as the standard environments, such as
4206  
4207 \begin_inset Flex Noun
4208 status collapsed
4209
4210 \begin_layout Plain Layout
4211 section
4212 \end_layout
4213
4214 \end_inset
4215
4216
4217 \begin_inset Flex Noun
4218 status collapsed
4219
4220 \begin_layout Plain Layout
4221 bibliography
4222 \end_layout
4223
4224 \end_inset
4225
4226
4227 \begin_inset Flex Noun
4228 status collapsed
4229
4230 \begin_layout Plain Layout
4231 title
4232 \end_layout
4233
4234 \end_inset
4235
4236
4237 \begin_inset Flex Noun
4238 status collapsed
4239
4240 \begin_layout Plain Layout
4241 author
4242 \end_layout
4243
4244 \end_inset
4245
4246 , and 
4247 \begin_inset Flex Noun
4248 status collapsed
4249
4250 \begin_layout Plain Layout
4251 date
4252 \end_layout
4253
4254 \end_inset
4255
4256 —are provided by 
4257 \begin_inset Flex Code
4258 status collapsed
4259
4260 \begin_layout Plain Layout
4261 article (AMS)
4262 \end_layout
4263
4264 \end_inset
4265
4266  and 
4267 \begin_inset Flex Code
4268 status collapsed
4269
4270 \begin_layout Plain Layout
4271 book (AMS)
4272 \end_layout
4273
4274 \end_inset
4275
4276 :
4277 \end_layout
4278
4279 \begin_layout Description
4280 Address This should be the author's permanent address.
4281 \end_layout
4282
4283 \begin_layout Description
4284 Current
4285 \begin_inset space ~
4286 \end_inset
4287
4288 Address This should be the author's temporary address at the time of submission,
4289  if different from the Address.
4290 \end_layout
4291
4292 \begin_layout Description
4293 Email Author's e-mail address
4294 \end_layout
4295
4296 \begin_layout Description
4297 URL Author's Web address, if desired.
4298 \end_layout
4299
4300 \begin_layout Description
4301 Keywords Key words or phrases used to identify specific topics discussed
4302  in the paper.
4303 \end_layout
4304
4305 \begin_layout Description
4306 Subjectclass These refer to the AMS Subject Classifications, published and
4307  described in 
4308 \emph on
4309 Mathematical Reviews
4310 \emph default
4311 .
4312  These are also available online at the AMS cites listed above.
4313 \end_layout
4314
4315 \begin_layout Description
4316 Thanks
4317 \end_layout
4318
4319 \begin_layout Description
4320 Dedicatory
4321 \end_layout
4322
4323 \begin_layout Description
4324 Translator
4325 \end_layout
4326
4327 \begin_layout Standard
4328 The following environments are provided by both the 
4329 \begin_inset Flex Code
4330 status collapsed
4331
4332 \begin_layout Plain Layout
4333 Theorems
4334 \end_layout
4335
4336 \end_inset
4337
4338  and 
4339 \begin_inset Flex Code
4340 status collapsed
4341
4342 \begin_layout Plain Layout
4343 Theorems (AMS)
4344 \end_layout
4345
4346 \end_inset
4347
4348  modules, in the latter case in both starred (unnumbered) and unstarred
4349  (numbered) versions.
4350  These same environments are provided only in the starred versions by the
4351  
4352 \begin_inset Flex Code
4353 status collapsed
4354
4355 \begin_layout Plain Layout
4356 Theorems (Starred)
4357 \end_layout
4358
4359 \end_inset
4360
4361  module:
4362 \end_layout
4363
4364 \begin_layout Theorem
4365 This is typically used for the statements of major results.
4366  
4367 \end_layout
4368
4369 \begin_layout Corollary*
4370 This is used for statements which follow fairly directly from previous statement
4371 s.
4372  Again, these can be major results.
4373  
4374 \end_layout
4375
4376 \begin_layout Lemma
4377 These are smaller results needed to prove other statements.
4378 \end_layout
4379
4380 \begin_layout Proposition
4381 These are less major results which (hopefully) add to the general theory
4382  being discussed.
4383 \end_layout
4384
4385 \begin_layout Conjecture
4386 These are statements provided without justification, which the author does
4387  not know how to prove, but which seem to be true (to the author, at least).
4388 \end_layout
4389
4390 \begin_layout Definition*
4391 Guess what this is for.
4392  The font is different for this environment than for the previous ones.
4393  
4394 \end_layout
4395
4396 \begin_layout Example*
4397 Used for examples illustrating proven results.
4398 \end_layout
4399
4400 \begin_layout Problem
4401 It's not really known what this is for.
4402  You should figure it out.
4403 \end_layout
4404
4405 \begin_layout Exercise*
4406 Write a description for this one.
4407 \end_layout
4408
4409 \begin_layout Remark
4410 This environment is also a type of theorem, usually a lesser sort of observation.
4411 \end_layout
4412
4413 \begin_layout Claim*
4414 Often used in the course of giving a proof of a larger result.
4415 \end_layout
4416
4417 \begin_layout Case
4418 Generally, these are used to break up long arguments, using specific instances
4419  of some condition.
4420  
4421 \end_layout
4422
4423 \begin_layout Case
4424 The numbering scheme for cases is on its own, not together with other numbered
4425  statements.
4426  
4427 \end_layout
4428
4429 \begin_layout Proof
4430 At the end of this environment, a QED symbol (usually a square, but it can
4431  vary with different styles) is placed.
4432  If you want to have other environments within this one—for example, Case
4433  environments—and have the QED symbol appear only after them, then the other
4434  environments need to be nested within the proof environment.
4435  See the section 
4436 \emph on
4437 Nesting Environments
4438 \emph default
4439  of the 
4440 \emph on
4441 User's Guide
4442 \emph default
4443  for information on nesting.
4444 \end_layout
4445
4446 \begin_layout Standard
4447 And these environments are provided by 
4448 \begin_inset Flex Code
4449 status collapsed
4450
4451 \begin_layout Plain Layout
4452 Theorems (AMS-Extended)
4453 \end_layout
4454
4455 \end_inset
4456
4457 :
4458 \end_layout
4459
4460 \begin_layout Criterion*
4461 A required condition.
4462 \end_layout
4463
4464 \begin_layout Algorithm*
4465 A general procedure to be used.
4466 \end_layout
4467
4468 \begin_layout Axiom*
4469 This is a property or statement taken as true within the system being discussed.
4470 \end_layout
4471
4472 \begin_layout Condition*
4473 Sometimes used to state a condition assumed within the present context of
4474  discussion.
4475 \end_layout
4476
4477 \begin_layout Note*
4478 Similar to a Remark.
4479 \end_layout
4480
4481 \begin_layout Notation*
4482 Used for the explanation of, yes, notation.
4483 \end_layout
4484
4485 \begin_layout Summary
4486 Do we really need to tell you? 
4487 \end_layout
4488
4489 \begin_layout Acknowledgement*
4490 Acknowledgement.
4491 \end_layout
4492
4493 \begin_layout Conclusion*
4494 Sometimes used at the end of a long train of argument.
4495 \end_layout
4496
4497 \begin_layout Fact
4498 Used in a way similar to Proposition, though perhaps lower on the scale.
4499 \end_layout
4500
4501 \begin_layout Standard
4502 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
4503  and AMS fonts
4504  packages.
4505  They need to be available on your system in order to use these environments.
4506 \end_layout
4507
4508 \begin_layout Section
4509 AGU journals (
4510 \family sans
4511 aguplus
4512 \family default
4513 )
4514 \end_layout
4515
4516 \begin_layout Standard
4517 by 
4518 \shape smallcaps
4519 Martin Vermeer
4520 \end_layout
4521
4522 \begin_layout Subsection
4523 Description
4524 \end_layout
4525
4526 \begin_layout Standard
4527 These are the layout files for some of the journals of the American Geophysical
4528  Society.
4529  It is assumed that you have both the AGU's own class files and AGUplus
4530  installed (everything to be found at
4531 \begin_inset Flex URL
4532 status collapsed
4533
4534 \begin_layout Plain Layout
4535
4536 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
4537 \end_layout
4538
4539 \end_inset
4540
4541 ).
4542 \end_layout
4543
4544 \begin_layout Subsection
4545 New styles
4546 \end_layout
4547
4548 \begin_layout Standard
4549 Redefined are 
4550 \family sans
4551 Paragraph
4552 \family default
4553
4554 \family sans
4555 Paragraph*
4556 \family default
4557 .
4558  They are still called this in the \SpecialChar LyX
4559  GUI, though their \SpecialChar LaTeX
4560  equivalents in the
4561  AGU classes are 
4562 \family sans
4563 Subsubsubsection
4564 \family default
4565  and 
4566 \family sans
4567 Subsubsubsection*
4568 \family default
4569 .
4570 \end_layout
4571
4572 \begin_layout Standard
4573 Newly defined styles are 
4574 \family sans
4575 Left_Header
4576 \family default
4577
4578 \family sans
4579 Right_Header
4580 \family default
4581
4582 \family sans
4583 Received
4584 \family default
4585
4586 \family sans
4587 Revised
4588 \family default
4589
4590 \family sans
4591 Accepted
4592 \family default
4593
4594 \family sans
4595 CCC
4596 \family default
4597
4598 \family sans
4599 PaperId
4600 \family default
4601
4602 \family sans
4603 AuthorAddr
4604 \family default
4605
4606 \family sans
4607 SlugComment
4608 \family default
4609 .
4610  These are mostly manuscript attributes and defined in the AGU class documentati
4611 on.
4612 \end_layout
4613
4614 \begin_layout Standard
4615 I suspect this is still badly incomplete.
4616 \end_layout
4617
4618 \begin_layout Subsection
4619 New floats
4620 \end_layout
4621
4622 \begin_layout Standard
4623
4624 \family sans
4625 Planotable
4626 \family default
4627  and 
4628 \family sans
4629 Plate
4630 \family default
4631 .
4632  We also have a new 
4633 \family sans
4634 Table_Caption
4635 \family default
4636 .
4637 \end_layout
4638
4639 \begin_layout Subsection
4640 Supported journals
4641 \end_layout
4642
4643 \begin_layout Itemize
4644
4645 \emph on
4646 Journal of Geophysical Research
4647 \emph default
4648
4649 \family typewriter
4650 jgrga.layout
4651 \family default
4652  — Martin Vermeer
4653 \end_layout
4654
4655 \begin_layout Standard
4656 Add your own, it isn't so hard! Look at the 
4657 \family typewriter
4658 jgrga.layout
4659 \family default
4660  example and 
4661 \family typewriter
4662 aguplus.inc
4663 \family default
4664 .
4665 \end_layout
4666
4667 \begin_layout Subsection
4668 Bugs and things to remember
4669 \end_layout
4670
4671 \begin_layout Standard
4672 In order to use the new layouts, you must remember to do the following for
4673  a new document:
4674 \end_layout
4675
4676 \begin_layout Enumerate
4677
4678 \emph on
4679 Turn off babel
4680 \emph default
4681 .
4682  This can be done in the 
4683 \family sans
4684 Layout\SpecialChar menuseparator
4685 Document
4686 \family default
4687  or 
4688 \family sans
4689 Document\SpecialChar menuseparator
4690 Settings
4691 \family default
4692  menu item.
4693  (AGU articles are always in English, right? So 
4694 \emph on
4695 don't
4696 \emph default
4697  choose a language.)
4698 \end_layout
4699
4700 \begin_layout Enumerate
4701 Enter 
4702 \family typewriter
4703 jgrga
4704 \family default
4705  into the document's 
4706 \family sans
4707 Extra Options
4708 \family default
4709  field.
4710  (Yes, this is a bug.)
4711 \end_layout
4712
4713 \begin_layout Enumerate
4714 Make sure you use the 
4715 \family typewriter
4716 agu.bst
4717 \family default
4718  bibliography style, by entering 
4719 \family sans
4720 agu
4721 \family default
4722  into the second field of the Bib\SpecialChar TeX
4723  inset.
4724  None of the standard styles will do.
4725 \end_layout
4726
4727 \begin_layout Section
4728 Broadway
4729 \end_layout
4730
4731 \begin_layout Standard
4732 by 
4733 \shape smallcaps
4734 Garst Reese
4735 \end_layout
4736
4737 \begin_layout Subsection
4738 Introduction
4739 \end_layout
4740
4741 \begin_layout Standard
4742 Broadway is for writing plays.
4743  The format is more decorative than Hollywood, and much less standardized.
4744  This format should be suitable for workshops.
4745 \end_layout
4746
4747 \begin_layout Subsection
4748 Special problems
4749 \end_layout
4750
4751 \begin_layout Standard
4752 The same as in Hollywood.
4753 \end_layout
4754
4755 \begin_layout Subsection
4756 Special features
4757 \end_layout
4758
4759 \begin_layout Standard
4760 Insert the 
4761 \family sans
4762 Speaker
4763 \family default
4764  names as labels then cross-reference the label to insert the name.
4765  The cross-reference dialog will show the current cast of characters.
4766 \end_layout
4767
4768 \begin_layout Subsection
4769 Paper size and Margins
4770 \end_layout
4771
4772 \begin_layout Standard
4773 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
4774 \end_layout
4775
4776 \begin_layout Subsection
4777 Environments
4778 \end_layout
4779
4780 \begin_layout Standard
4781 The following environments are available.
4782  You can use broadway.bind to get the bind keys shown at the right.
4783 \end_layout
4784
4785 \begin_layout Itemize
4786
4787 \family sans
4788 Standard
4789 \begin_inset Newline newline
4790 \end_inset
4791
4792
4793 \family default
4794 You should not have to use this, but it is here for anything that does not
4795  fit otherwise.
4796 \end_layout
4797
4798 \begin_layout Itemize
4799
4800 \family sans
4801 Narrative
4802 \begin_inset space \hfill{}
4803 \end_inset
4804
4805 M-z n
4806 \begin_inset Newline newline
4807 \end_inset
4808
4809
4810 \family default
4811 Used to describe stage setting and the action.
4812  First use of speaker names in all CAPs.
4813 \end_layout
4814
4815 \begin_layout Itemize
4816
4817 \family sans
4818 ACT
4819 \begin_inset space \hfill{}
4820 \end_inset
4821
4822 M-z a
4823 \begin_inset Newline newline
4824 \end_inset
4825
4826
4827 \family default
4828 Automatically numbered.
4829  On screen it will be arabic, but will print as Roman.
4830 \end_layout
4831
4832 \begin_layout Itemize
4833
4834 \family sans
4835 ACT*
4836 \begin_inset space \hfill{}
4837 \end_inset
4838
4839 M-z S at
4840 \begin_inset Newline newline
4841 \end_inset
4842
4843
4844 \family default
4845 Subtitle for 
4846 \family sans
4847 ACT.
4848
4849 \family default
4850  It is just centered text.
4851 \end_layout
4852
4853 \begin_layout Itemize
4854
4855 \family sans
4856 SCENE
4857 \begin_inset space \hfill{}
4858 \end_inset
4859
4860 M-z S-S
4861 \begin_inset Newline newline
4862 \end_inset
4863
4864
4865 \family default
4866 Not automatically numbered.
4867  You supply the number.
4868  This is because I couldn't figure out how.
4869 \end_layout
4870
4871 \begin_layout Itemize
4872
4873 \family sans
4874 AT_RISE:
4875 \begin_inset space \hfill{}
4876 \end_inset
4877
4878 M-z S-R
4879 \begin_inset Newline newline
4880 \end_inset
4881
4882
4883 \family default
4884 A special case of Narrative to describe the setting and action as the curtain
4885  rises.
4886 \end_layout
4887
4888 \begin_layout Itemize
4889
4890 \family sans
4891 Speaker
4892 \begin_inset space \hfill{}
4893 \end_inset
4894
4895 M-z s
4896 \begin_inset Newline newline
4897 \end_inset
4898
4899
4900 \family default
4901 The speaker's (actor's) title, centered in all CAPS.
4902 \end_layout
4903
4904 \begin_layout Itemize
4905
4906 \family sans
4907 Parenthetical
4908 \begin_inset space \hfill{}
4909 \end_inset
4910
4911 M-z p
4912 \begin_inset Newline newline
4913 \end_inset
4914
4915
4916 \family default
4917 Instructions to the speaker.
4918  The parentheses are automatically inserted.
4919  The ( will appear on screen, but both will be in the printed play.
4920  This environment is only used within 
4921 \family sans
4922 Dialogue
4923 \family default
4924 .
4925 \end_layout
4926
4927 \begin_layout Itemize
4928
4929 \family sans
4930 Dialogue
4931 \begin_inset space \hfill{}
4932 \end_inset
4933
4934 M-z d
4935 \begin_inset Newline newline
4936 \end_inset
4937
4938
4939 \family default
4940 What the Speaker says.
4941 \end_layout
4942
4943 \begin_layout Itemize
4944
4945 \family sans
4946 CURTAIN
4947 \begin_inset space \hfill{}
4948 \end_inset
4949
4950 M-z S-C
4951 \begin_inset Newline newline
4952 \end_inset
4953
4954
4955 \family default
4956 The curtain comes down.
4957 \end_layout
4958
4959 \begin_layout Itemize
4960
4961 \family sans
4962 Title
4963 \begin_inset space \hfill{}
4964 \end_inset
4965
4966 M-z S-T
4967 \end_layout
4968
4969 \begin_layout Itemize
4970
4971 \family sans
4972 Author
4973 \begin_inset space \hfill{}
4974 \end_inset
4975
4976 M-z S-A
4977 \end_layout
4978
4979 \begin_layout Itemize
4980
4981 \family sans
4982 Right_Address
4983 \begin_inset space \hfill{}
4984 \end_inset
4985
4986 M-z r
4987 \end_layout
4988
4989 \begin_layout Standard
4990 Hello there.
4991 \end_layout
4992
4993 \begin_layout Section
4994 Dinbrief
4995 \end_layout
4996
4997 \begin_layout Standard
4998 The document class 
4999 \family sans
5000 dinbrief
5001 \family default
5002  can be used to type letters according to German conventions.
5003  A template file is included in 
5004 \family typewriter
5005 .../lyx/share/templates
5006 \family default
5007  for you to use as a starting point.
5008 \end_layout
5009
5010 \begin_layout Section
5011 EGS journals (
5012 \family sans
5013 egs
5014 \family default
5015 )
5016 \end_layout
5017
5018 \begin_layout Standard
5019 by 
5020 \shape smallcaps
5021 Martin Vermeer
5022 \end_layout
5023
5024 \begin_layout Subsection
5025 Description
5026 \end_layout
5027
5028 \begin_layout Standard
5029 This is the layout file for the European Geophysical Society journals.
5030  The needed 
5031 \family typewriter
5032 egs.cls
5033 \family default
5034  can be downloaded from the web site of the EGS under 
5035 \begin_inset Flex URL
5036 status collapsed
5037
5038 \begin_layout Plain Layout
5039
5040 www.copernicus.org
5041 \end_layout
5042
5043 \end_inset
5044
5045 .
5046 \end_layout
5047
5048 \begin_layout Subsection
5049 New styles
5050 \end_layout
5051
5052 \begin_layout Standard
5053
5054 \family sans
5055 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
5056  Accepted
5057 \family default
5058
5059 \family sans
5060 Offsets
5061 \family default
5062 .
5063  The current layout file is unfortunately very unmodular and would benefit
5064  from using the various 
5065 \family typewriter
5066 std*.inc
5067 \family default
5068  file inclusions.
5069 \end_layout
5070
5071 \begin_layout Section
5072 Elsevier Journals
5073 \end_layout
5074
5075 \begin_layout Standard
5076 See the \SpecialChar LyX
5077  template file 
5078 \family typewriter
5079 elsarticle.lyx
5080 \family default
5081 .
5082  It contains all infos you need.
5083 \end_layout
5084
5085 \begin_layout Section
5086 Foils [aka 
5087 \family sans
5088 Foil\SpecialChar TeX
5089
5090 \family default
5091 ]
5092 \begin_inset CommandInset label
5093 LatexCommand label
5094 name "sec:foiltex"
5095
5096 \end_inset
5097
5098
5099 \end_layout
5100
5101 \begin_layout Standard
5102 by 
5103 \noun on
5104 Allan Rae
5105 \end_layout
5106
5107 \begin_layout Subsection
5108 Introduction
5109 \end_layout
5110
5111 \begin_layout Standard
5112 This section describes how to use \SpecialChar LyX
5113  to make slides for overhead projectors.
5114  There are two document classes that can do this: the default slides class
5115  and the 
5116 \family sans
5117 Foil\SpecialChar TeX
5118
5119 \family default
5120  slides class.
5121  This section documents the latter.
5122 \end_layout
5123
5124 \begin_layout Standard
5125 I'm going to say this again, nice and clear, so that there's no misunderstanding
5126 :
5127 \end_layout
5128
5129 \begin_layout Standard
5130 \begin_inset VSpace bigskip
5131 \end_inset
5132
5133
5134 \end_layout
5135
5136 \begin_layout Standard
5137 \align center
5138
5139 \size large
5140 This section documents the class 
5141 \begin_inset Quotes eld
5142 \end_inset
5143
5144
5145 \family sans
5146 FoilTeX
5147 \family default
5148
5149 \begin_inset Quotes erd
5150 \end_inset
5151
5152  
5153 \emph on
5154 only.
5155 \end_layout
5156
5157 \begin_layout Standard
5158 \begin_inset VSpace bigskip
5159 \end_inset
5160
5161
5162 \end_layout
5163
5164 \begin_layout Standard
5165 If you're looking for the documentation for 
5166 \begin_inset Quotes eld
5167 \end_inset
5168
5169
5170 \family sans
5171 slides (default)
5172 \family default
5173
5174 \begin_inset Quotes erd
5175 \end_inset
5176
5177 , check out section
5178 \begin_inset space ~
5179 \end_inset
5180
5181
5182 \begin_inset CommandInset ref
5183 LatexCommand ref
5184 reference "sec:slitex"
5185
5186 \end_inset
5187
5188 .
5189  If your machine doesn't have the 
5190 \family sans
5191 foils
5192 \family default
5193  class 
5194 \family sans
5195 FoilTeX
5196 \family default
5197  installed, you'll probably have to use the default 
5198 \family sans
5199 slides
5200 \family default
5201  class, which isn't quite as good as 
5202 \family sans
5203 foils.
5204 \end_layout
5205
5206 \begin_layout Standard
5207 The 
5208 \family sans
5209 foils
5210 \family default
5211  class is designed for use with version
5212 \begin_inset space ~
5213 \end_inset
5214
5215 2.1 of the 
5216 \family sans
5217 foils.cls
5218 \family default
5219  \SpecialChar LaTeX
5220  class file which is now an integral part of \SpecialChar LaTeX2e
5221 .
5222 \end_layout
5223
5224 \begin_layout Subsection
5225 Getting Started
5226 \end_layout
5227
5228 \begin_layout Standard
5229 Obviously, to use this document class, you need to select 
5230 \family sans
5231 FoilTeX
5232 \family default
5233  from the 
5234 \family sans
5235 Class
5236 \family default
5237  entry in the 
5238 \family sans
5239 Document
5240 \begin_inset space ~
5241 \end_inset
5242
5243 Layout
5244 \family default
5245  dialog.
5246  There are some settings in the 
5247 \family sans
5248 Document
5249 \begin_inset space ~
5250 \end_inset
5251
5252 Layout
5253 \family default
5254  dialog that you should know about that are specific to this class:
5255 \end_layout
5256
5257 \begin_layout Itemize
5258 Don't change the options 
5259 \family sans
5260 Sides
5261 \family default
5262  and 
5263 \family sans
5264 Columns
5265 \family default
5266  on the 
5267 \family sans
5268 Document
5269 \begin_inset space ~
5270 \end_inset
5271
5272 Layout
5273 \family default
5274  dialog.
5275  They're ignored by the 
5276 \family sans
5277 foils
5278 \family default
5279  class.
5280 \end_layout
5281
5282 \begin_layout Itemize
5283 The default font size is 20
5284 \begin_inset space \thinspace{}
5285 \end_inset
5286
5287 pt with the other options being 17
5288 \begin_inset space \thinspace{}
5289 \end_inset
5290
5291 pt, 25
5292 \begin_inset space \thinspace{}
5293 \end_inset
5294
5295 pt and 30
5296 \begin_inset space \thinspace{}
5297 \end_inset
5298
5299 pt.
5300 \end_layout
5301
5302 \begin_layout Itemize
5303 The default font is 
5304 \family sans
5305 sans
5306 \family default
5307  
5308 \family sans
5309 serif
5310 \family default
5311  but all math equations are still typeset in the usual roman font.
5312 \end_layout
5313
5314 \begin_layout Itemize
5315
5316 \family sans
5317 Foil\SpecialChar TeX
5318
5319 \family default
5320  supports A4 and Letter paper sizes as well as a special size for working
5321  with 35
5322 \begin_inset space \thinspace{}
5323 \end_inset
5324
5325 mm slides.
5326  It doesn't support A5, B5, legal or executive paper sizes.
5327 \end_layout
5328
5329 \begin_layout Itemize
5330 Don't bother changing the 
5331 \family sans
5332 Float Placement
5333 \family default
5334  settings because they are ignored anyway.
5335  All floats appear where they are defined in the text.
5336 \end_layout
5337
5338 \begin_layout Itemize
5339 The 
5340 \family sans
5341 Pagestyle
5342 \family default
5343  setting behaves a bit differently for this class.
5344  
5345 \family sans
5346 Foil\SpecialChar TeX
5347
5348 \family default
5349  provides extensive footer and header capabilities including a user-defined
5350  logo.
5351  See section
5352 \begin_inset space ~
5353 \end_inset
5354
5355
5356 \begin_inset CommandInset ref
5357 LatexCommand ref
5358 reference "sec:foilfoot"
5359
5360 \end_inset
5361
5362  for more details.
5363  The title page is treated differently to all other pages in the document
5364  and is 
5365 \emph on
5366 always
5367 \emph default
5368  unnumbered and 
5369 \emph on
5370 always
5371 \emph default
5372  has the logo centered at the bottom of the page (if one is defined).
5373  The possible page style choices and what they do are as follows:
5374 \end_layout
5375
5376 \begin_deeper
5377 \begin_layout Labeling
5378 \labelwidthstring MMMMMMM
5379
5380 \family sans
5381 \series bold
5382 empty
5383 \family default
5384 \series default
5385  The final output contains no page numbers, or other headers or footers
5386  (except footnotes of course).
5387  
5388 \end_layout
5389
5390 \begin_layout Labeling
5391 \labelwidthstring MMMMMMM
5392
5393 \family sans
5394 \series bold
5395 plain
5396 \family default
5397 \series default
5398  The final output contains page numbers centered at the bottom of the page.
5399  No other headings or footers (other than footnotes).
5400 \end_layout
5401
5402 \begin_layout Labeling
5403 \labelwidthstring MMMMMMM
5404
5405 \series bold
5406 foilheadings
5407 \series default
5408  Page numbers in lower right corner.
5409  Additional headers and footers are also shown.
5410  This is also the default.
5411 \end_layout
5412
5413 \begin_layout Labeling
5414 \labelwidthstring MMMMMMM
5415
5416 \series bold
5417 fancy
5418 \series default
5419  Gives you access to the 
5420 \family sans
5421 fancyheadings
5422 \family default
5423  package although its use with 
5424 \family sans
5425 Foil\SpecialChar TeX
5426
5427 \family default
5428  is discouraged by the writer of the 
5429 \family sans
5430 Foil\SpecialChar TeX
5431
5432 \family default
5433  package because of some potential page layout clashes.
5434 \end_layout
5435
5436 \end_deeper
5437 \begin_layout Subsubsection
5438 Extra Options
5439 \end_layout
5440
5441 \begin_layout Standard
5442 The following options may be used in the extra class options in the 
5443 \family sans
5444 Document\SpecialChar menuseparator
5445 Settings
5446 \family default
5447  dialog.
5448 \end_layout
5449
5450 \begin_layout Labeling
5451 \labelwidthstring MMMMMMx
5452
5453 \series bold
5454 35mmSlide
5455 \series default
5456  This sets up the page layout for 7.33
5457 \begin_inset space \thinspace{}
5458 \end_inset
5459
5460 in by 11
5461 \begin_inset space \thinspace{}
5462 \end_inset
5463
5464 in paper, which is about the same aspect ratio as a 35
5465 \begin_inset space \thinspace{}
5466 \end_inset
5467
5468 mm slide, making it a bit easier to work with this medium.
5469 \end_layout
5470
5471 \begin_layout Labeling
5472 \labelwidthstring MMMMMMx
5473
5474 \series bold
5475 headrule
5476 \series default
5477  Places a rule across the page below the header on every page except the
5478  title page.
5479 \end_layout
5480
5481 \begin_layout Labeling
5482 \labelwidthstring MMMMMMx
5483
5484 \series bold
5485 footrule
5486 \series default
5487  Places a rule across the page above the footer on every page except the
5488  title page.
5489 \end_layout
5490
5491 \begin_layout Labeling
5492 \labelwidthstring MMMMMMx
5493
5494 \series bold
5495 dvips
5496 \series default
5497  This is automatically set each time you create a new 
5498 \family sans
5499 foils
5500 \family default
5501  document.
5502  This option tells 
5503 \family sans
5504 Foil\SpecialChar TeX
5505
5506 \family default
5507  to use the dvips driver to rotate those pages that are set as landscape
5508  foils.
5509 \end_layout
5510
5511 \begin_layout Labeling
5512 \labelwidthstring MMMMMMx
5513
5514 \series bold
5515 landscape
5516 \series default
5517  Simply changes the page dimensions to those of a landscape page but doesn't
5518  do any rotation.
5519  Thus if you use this option you need to use an external program to rotate
5520  each page or feed your paper through your printer as landscape.
5521  Note that this option effectively reverses the roles of the 
5522 \family sans
5523 Foilhead
5524 \family default
5525  and 
5526 \family sans
5527 Rotatefoilhead
5528 \family default
5529  environments (don't worry these are described in the next section).
5530 \end_layout
5531
5532 \begin_layout Labeling
5533 \labelwidthstring MMMMMMx
5534
5535 \series bold
5536 leqno
5537 \series default
5538  Equation numbers on the left.
5539 \end_layout
5540
5541 \begin_layout Labeling
5542 \labelwidthstring MMMMMMx
5543
5544 \series bold
5545 fleqn
5546 \series default
5547  Flush-left equations.
5548 \end_layout
5549
5550 \begin_layout Subsection
5551 Supported Environments
5552 \end_layout
5553
5554 \begin_layout Standard
5555 Most of the environments commonly supported in other classes are also supported
5556  by the 
5557 \family sans
5558 foils
5559 \family default
5560  class.
5561  There are several additional environments provided by 
5562 \family sans
5563 Foil\SpecialChar TeX
5564
5565 \family default
5566  as well as a couple added by \SpecialChar LyX
5567 .
5568  The following environments are shared with other classes:
5569 \end_layout
5570
5571 \begin_layout Standard
5572 \begin_inset Flex Multiple Columns
5573 status open
5574
5575 \begin_layout Itemize
5576
5577 \family sans
5578 Standard
5579 \end_layout
5580
5581 \begin_layout Itemize
5582
5583 \family sans
5584 Itemize
5585 \end_layout
5586
5587 \begin_layout Itemize
5588
5589 \family sans
5590 Enumerate
5591 \end_layout
5592
5593 \begin_layout Itemize
5594
5595 \family sans
5596 Description
5597 \end_layout
5598
5599 \begin_layout Itemize
5600
5601 \family sans
5602 List
5603 \end_layout
5604
5605 \begin_layout Itemize
5606
5607 \family sans
5608 \SpecialChar LyX
5609 -Code
5610 \end_layout
5611
5612 \begin_layout Itemize
5613
5614 \family sans
5615 Verse
5616 \end_layout
5617
5618 \begin_layout Itemize
5619
5620 \family sans
5621 Quote
5622 \end_layout
5623
5624 \begin_layout Itemize
5625
5626 \family sans
5627 Quotation
5628 \end_layout
5629
5630 \begin_layout Itemize
5631
5632 \family sans
5633 Title
5634 \end_layout
5635
5636 \begin_layout Itemize
5637
5638 \family sans
5639 Author
5640 \end_layout
5641
5642 \begin_layout Itemize
5643
5644 \family sans
5645 Date
5646 \end_layout
5647
5648 \begin_layout Itemize
5649
5650 \family sans
5651 Abstract
5652 \end_layout
5653
5654 \begin_layout Itemize
5655
5656 \family sans
5657 Bibliography
5658 \end_layout
5659
5660 \begin_layout Itemize
5661
5662 \family sans
5663 Address
5664 \end_layout
5665
5666 \begin_layout Itemize
5667
5668 \family sans
5669 RightAddress
5670 \end_layout
5671
5672 \begin_layout Itemize
5673
5674 \family sans
5675 Caption
5676 \end_layout
5677
5678 \begin_layout Itemize
5679
5680 \family sans
5681 Comment
5682 \end_layout
5683
5684 \end_inset
5685
5686
5687 \end_layout
5688
5689 \begin_layout Standard
5690 That is, all the major environments apart from the sectioning environments.
5691  Since foils are essentially self-contained sections, with a title and body,
5692  
5693 \family sans
5694 Foil\SpecialChar TeX
5695
5696 \family default
5697  provides specific commands for starting new foils and these are:
5698 \end_layout
5699
5700 \begin_layout Itemize
5701
5702 \family sans
5703 Foilhead
5704 \end_layout
5705
5706 \begin_layout Itemize
5707
5708 \family sans
5709 Rotatefoilhead
5710 \end_layout
5711
5712 \begin_layout Standard
5713 \SpecialChar LyX
5714  also provides slightly modified versions of these two environments called:
5715 \end_layout
5716
5717 \begin_layout Itemize
5718
5719 \family sans
5720 ShortFoilhead
5721 \end_layout
5722
5723 \begin_layout Itemize
5724
5725 \family sans
5726 ShortRotatefoilhead
5727 \end_layout
5728
5729 \begin_layout Standard
5730 and the differences will be explained in the next section.
5731 \end_layout
5732
5733 \begin_layout Standard
5734 Since foils are often used in presenting ideas or new theorems and such
5735  
5736 \family sans
5737 Foil\SpecialChar TeX
5738
5739 \family default
5740  also provides a comprehensive box of goodies for presenting them:
5741 \end_layout
5742
5743 \begin_layout Standard
5744 \begin_inset Flex Multiple Columns
5745 status open
5746
5747 \begin_layout Itemize
5748
5749 \family sans
5750 Theorem
5751 \end_layout
5752
5753 \begin_layout Itemize
5754
5755 \family sans
5756 Lemma
5757 \end_layout
5758
5759 \begin_layout Itemize
5760
5761 \family sans
5762 Corollary
5763 \end_layout
5764
5765 \begin_layout Itemize
5766
5767 \family sans
5768 Proposition
5769 \end_layout
5770
5771 \begin_layout Itemize
5772
5773 \family sans
5774 Definition
5775 \end_layout
5776
5777 \begin_layout Itemize
5778
5779 \family sans
5780 Proof
5781 \end_layout
5782
5783 \begin_layout Itemize
5784
5785 \family sans
5786 Theorem*
5787 \end_layout
5788
5789 \begin_layout Itemize
5790
5791 \family sans
5792 Lemma*
5793 \end_layout
5794
5795 \begin_layout Itemize
5796
5797 \family sans
5798 Corollary*
5799 \end_layout
5800
5801 \begin_layout Itemize
5802
5803 \family sans
5804 Proposition*
5805 \end_layout
5806
5807 \begin_layout Itemize
5808
5809 \family sans
5810 Definition*
5811 \end_layout
5812
5813 \end_inset
5814
5815
5816 \end_layout
5817
5818 \begin_layout Standard
5819 The starred versions are unnumbered while the unstarred versions are numbered.
5820  There are also two list environments added by \SpecialChar LyX
5821  and these are:
5822 \end_layout
5823
5824 \begin_layout Itemize
5825
5826 \family sans
5827 TickList
5828 \end_layout
5829
5830 \begin_layout Itemize
5831
5832 \family sans
5833 CrossList
5834 \end_layout
5835
5836 \begin_layout Standard
5837
5838 \family sans
5839 Foil\SpecialChar TeX
5840
5841 \family default
5842  provides some powerful header and footer capabilities that are best set
5843  in the preamble although they may be set at any point in a document.
5844  If you want to change these settings in your document the best place to
5845  do so is at the very top of a foil, i.
5846 \begin_inset space \thinspace{}
5847 \end_inset
5848
5849 e.
5850 \emph on
5851
5852 \begin_inset space \space{}
5853 \end_inset
5854
5855
5856 \emph default
5857 straight after the foilhead.
5858 \end_layout
5859
5860 \begin_layout Standard
5861 For this purpose, the following command styles are provided [
5862 \shape smallcaps
5863 Martin Vermeer
5864 \shape default
5865 ]:
5866 \end_layout
5867
5868 \begin_layout Standard
5869 \begin_inset Flex Multiple Columns
5870 status open
5871
5872 \begin_layout Itemize
5873
5874 \family sans
5875 My
5876 \begin_inset space ~
5877 \end_inset
5878
5879 Logo
5880 \end_layout
5881
5882 \begin_layout Itemize
5883
5884 \family sans
5885 Restriction
5886 \end_layout
5887
5888 \begin_layout Itemize
5889
5890 \family sans
5891 Right
5892 \begin_inset space ~
5893 \end_inset
5894
5895 Footer
5896 \end_layout
5897
5898 \begin_layout Itemize
5899
5900 \family sans
5901 Right
5902 \begin_inset space ~
5903 \end_inset
5904
5905 Header
5906 \end_layout
5907
5908 \begin_layout Itemize
5909
5910 \family sans
5911 Left
5912 \begin_inset space ~
5913 \end_inset
5914
5915 Header
5916 \end_layout
5917
5918 \begin_deeper
5919 \begin_layout Plain Layout
5920 \begin_inset space ~
5921 \end_inset
5922
5923
5924 \end_layout
5925
5926 \end_deeper
5927 \end_inset
5928
5929
5930 \end_layout
5931
5932 \begin_layout Standard
5933 There are also a few commands provided by 
5934 \family sans
5935 Foil\SpecialChar TeX
5936
5937 \family default
5938  that aren't directly supported by \SpecialChar LyX
5939  but I'll tell you what they do and how
5940  to use them in section
5941 \begin_inset space ~
5942 \end_inset
5943
5944
5945 \begin_inset CommandInset ref
5946 LatexCommand ref
5947 reference "sec:unsuppfoils"
5948
5949 \end_inset
5950
5951 .
5952 \end_layout
5953
5954 \begin_layout Subsection
5955 Building a Set of Foils
5956 \end_layout
5957
5958 \begin_layout Standard
5959 This section will give a simple introduction to using the different environments
5960  to build a set of foils.
5961  If you want to see an example set of foils, take a look at the 
5962 \family typewriter
5963 Foils.lyx
5964 \family default
5965  file you find in \SpecialChar LyX
5966 's 
5967 \family typewriter
5968 examples
5969 \family default
5970  folder.
5971 \end_layout
5972
5973 \begin_layout Subsubsection
5974 Give It a Title Page
5975 \end_layout
5976
5977 \begin_layout Standard
5978 Unlike other classes that provide 
5979 \family sans
5980 Title
5981 \family default
5982
5983 \family sans
5984 Author
5985 \family default
5986
5987 \family sans
5988 Date
5989 \family default
5990  and 
5991 \family sans
5992 Abstract
5993 \family default
5994  environments, 
5995 \family sans
5996 foils
5997 \family default
5998  creates the title on a page of its own.
5999  If you leave out the 
6000 \family sans
6001 Date
6002 \family default
6003  environment \SpecialChar LaTeX
6004  will substitute the current date (every time you regenerate
6005  the output).
6006 \end_layout
6007
6008 \begin_layout Subsubsection
6009 Start a New Foil
6010 \end_layout
6011
6012 \begin_layout Standard
6013 As I mentioned earlier, there are four ways of starting a new foil.
6014  For portrait foils you should use 
6015 \family sans
6016 Foilhead
6017 \family default
6018  or 
6019 \family sans
6020 ShortFoilhead.
6021
6022 \family default
6023  The difference between these two environments is the amount of space between
6024  the title of the foil (the foilhead) and the body of the foil.
6025 \end_layout
6026
6027 \begin_layout Standard
6028 Landscape foils are generated using the 
6029 \family sans
6030 Rotatefoilhead
6031 \family default
6032  and 
6033 \family sans
6034 ShortRotatefoilhead
6035 \family default
6036  environments.
6037  Again the only difference is the spacing between foilhead and body.
6038  Both of the short versions have 0.5
6039 \begin_inset space ~
6040 \end_inset
6041
6042 inches less separation between the foilhead and the body.
6043  
6044 \end_layout
6045
6046 \begin_layout Standard
6047 One problem with the support for landscape foils is the requirement that
6048  you have to use the 
6049 \family typewriter
6050 dvips
6051 \family default
6052  driver to generate the PostScript output otherwise the foils won't be rotated.
6053  It is possible to get landscape foils even if you haven't got the 
6054 \family typewriter
6055 dvips
6056 \family default
6057  driver provided you can feed your foils sideways through your printer ;-)
6058 \end_layout
6059
6060 \begin_layout Subsubsection
6061 Theorems, Lemmas, Proofs and more
6062 \end_layout
6063
6064 \begin_layout Standard
6065 Due to a small bug in \SpecialChar LyX
6066  you can't have two of the same type of these environments
6067  directly following each other.
6068  They must be separated by something.
6069  If you try, you will just be extending the previous environment as if you
6070  had merged the two environments together.
6071  So, how do you get around this problem? The simplest option is to insert
6072  some text between the two environments or add a 
6073 \family sans
6074 \SpecialChar LaTeX
6075
6076 \family default
6077  environment between the two with just a 
6078 \begin_inset Quotes eld
6079 \end_inset
6080
6081
6082 \family typewriter
6083 %
6084 \family default
6085
6086 \begin_inset Quotes erd
6087 \end_inset
6088
6089  in it.
6090  This will force \SpecialChar LyX
6091  to produce two separate environments and hence the correct
6092  \SpecialChar LaTeX
6093  output.
6094  An example is provided in the example file included with the \SpecialChar LyX
6095  distribution.
6096  Remember, this problem only occurs if you are trying to place two of the
6097  same type of theorem-like environments one directly after the other.
6098 \end_layout
6099
6100 \begin_layout Subsubsection
6101 Lists
6102 \end_layout
6103
6104 \begin_layout Standard
6105 You get all the commonly supported list styles found in other classes as
6106  well as two new ones.
6107  I'll only describe the new ones here.
6108  If you want to find out more about the other list environments check out
6109  the 
6110 \emph on
6111 User's Guide.
6112
6113 \emph default
6114  If you intend to use itemized lists you might also want to read about the
6115  
6116 \family sans
6117 Itemize
6118 \begin_inset space ~
6119 \end_inset
6120
6121 Bullet
6122 \begin_inset space ~
6123 \end_inset
6124
6125 Selection
6126 \family default
6127  dialog described above in section
6128 \begin_inset space ~
6129 \end_inset
6130
6131
6132 \begin_inset CommandInset ref
6133 LatexCommand ref
6134 reference "sec:bullet"
6135
6136 \end_inset
6137
6138 .
6139 \end_layout
6140
6141 \begin_layout Standard
6142 The two new list styles, 
6143 \family sans
6144 TickList
6145 \family default
6146  and 
6147 \family sans
6148 CrossList
6149 \family default
6150 , are designed to make it easier for you to create lists of do's and don'ts
6151  or right and wrong by providing dedicated environments that use a tick
6152  or a cross as the label of the list.
6153  These lists are in fact dedicated variants of the 
6154 \family sans
6155 Itemize
6156 \family default
6157  environment.
6158  They do however require that you have the 
6159 \family typewriter
6160 psnfss
6161 \family default
6162  packages installed.
6163 \end_layout
6164
6165 \begin_layout Subsubsection
6166 Figures and Tables
6167 \end_layout
6168
6169 \begin_layout Standard
6170
6171 \family sans
6172 Foil\SpecialChar TeX
6173
6174 \family default
6175  redefines the floating tables and figures so that they appear exactly where
6176  they are in the text rather than pushing them to the top of the page or
6177  to some user specified location.
6178  In fact if you change the float placement settings they are simply ignored.
6179 \end_layout
6180
6181 \begin_layout Subsubsection
6182 Page Headers and Footers
6183 \begin_inset CommandInset label
6184 LatexCommand label
6185 name "sec:foilfoot"
6186
6187 \end_inset
6188
6189
6190 \end_layout
6191
6192 \begin_layout Standard
6193
6194 \family sans
6195 My
6196 \begin_inset space ~
6197 \end_inset
6198
6199 Logo
6200 \family default
6201  and 
6202 \family sans
6203 Restriction
6204 \family default
6205  are two commands used to control the left-footer text string.
6206  The first is meant to allow you to include a graphic logo on your foils
6207  and defaults to 
6208 \begin_inset Quotes eld
6209 \end_inset
6210
6211 -Typeset by 
6212 \family sans
6213 Foil\SpecialChar TeX
6214
6215 \family default
6216 -
6217 \begin_inset Quotes erd
6218 \end_inset
6219
6220 .
6221  While the second is meant to provide a classification for the audience,
6222  
6223 \emph on
6224 e.
6225 \begin_inset space \thinspace{}
6226 \end_inset
6227
6228 g.
6229 \emph default
6230
6231 \begin_inset space \space{}
6232 \end_inset
6233
6234 Confidential.
6235  It is empty by default.
6236 \end_layout
6237
6238 \begin_layout Standard
6239 The remaining page corners can be filled by 
6240 \family sans
6241 Right
6242 \begin_inset space ~
6243 \end_inset
6244
6245 Footer
6246 \family default
6247  (which defaults to page numbers), 
6248 \family sans
6249 Right
6250 \begin_inset space ~
6251 \end_inset
6252
6253 Header
6254 \family default
6255  (top right) and 
6256 \family sans
6257 Left
6258 \begin_inset space ~
6259 \end_inset
6260
6261 Header
6262 \family default
6263  (top left).
6264 \end_layout
6265
6266 \begin_layout Subsection
6267 Unsupported 
6268 \family sans
6269 Foil\SpecialChar TeX
6270
6271 \family default
6272  Goodies
6273 \begin_inset CommandInset label
6274 LatexCommand label
6275 name "sec:unsuppfoils"
6276
6277 \end_inset
6278
6279
6280 \end_layout
6281
6282 \begin_layout Standard
6283 All the commands mentioned below need to be set in a 
6284 \family sans
6285 \SpecialChar LaTeX
6286
6287 \family default
6288  environment or as 
6289 \family sans
6290 \SpecialChar TeX
6291
6292 \family default
6293  within another environment.
6294 \end_layout
6295
6296 \begin_layout Subsubsection
6297 Lengths
6298 \end_layout
6299
6300 \begin_layout Standard
6301 All lengths are adjusted using the 
6302 \family typewriter
6303
6304 \backslash
6305 setlength{
6306 \family default
6307 \emph on
6308 lengthname
6309 \family typewriter
6310 \emph default
6311 }{
6312 \family default
6313 \emph on
6314 newlength
6315 \family typewriter
6316 \emph default
6317 }
6318 \family default
6319  command.
6320  Where 
6321 \emph on
6322 lengthname
6323 \emph default
6324  should be replaced by the name given to the length you want to change and
6325  
6326 \emph on
6327 newlength
6328 \emph default
6329  is the length value.
6330  All lengths should be specified in units of length such as inches (
6331 \family typewriter
6332 in
6333 \family default
6334 ), millimeters (
6335 \family typewriter
6336 mm
6337 \family default
6338 ) or points (
6339 \family typewriter
6340 pt
6341 \family default
6342 ) or relative to some document or font-based length such as 
6343 \family typewriter
6344
6345 \backslash
6346 textwidth
6347 \family default
6348 .
6349  
6350 \end_layout
6351
6352 \begin_layout Standard
6353 It's possible to change the spacing between a foilhead and the body of the
6354  foil by adjusting the length specified by 
6355 \family typewriter
6356
6357 \backslash
6358 foilheadskip
6359 \family default
6360 .
6361  For example, to make 
6362 \emph on
6363 all
6364 \emph default
6365  foilheads 0.5
6366 \begin_inset space \space{}
6367 \end_inset
6368
6369 in closer to their bodies put the following in the preamble: 
6370 \family typewriter
6371
6372 \backslash
6373 setlength{
6374 \backslash
6375 foilheadskip}{-0.5in}
6376 \end_layout
6377
6378 \begin_layout Standard
6379 The spacings around floats can be adjusted by setting these lengths:
6380 \end_layout
6381
6382 \begin_layout Labeling
6383 \labelwidthstring MMMMMMMMMMM
6384
6385 \family typewriter
6386
6387 \backslash
6388 abovefloatskip
6389 \family default
6390  Separation between the text and the top of the float
6391 \end_layout
6392
6393 \begin_layout Labeling
6394 \labelwidthstring MMMMMMMMMMM
6395
6396 \family typewriter
6397
6398 \backslash
6399 abovecaptionskip
6400 \family default
6401  Separation between the float and the caption
6402 \end_layout
6403
6404 \begin_layout Labeling
6405 \labelwidthstring MMMMMMMMMMM
6406
6407 \family typewriter
6408
6409 \backslash
6410 belowcaptionskip
6411 \family default
6412  Separation between the caption and the following text
6413 \end_layout
6414
6415 \begin_layout Labeling
6416 \labelwidthstring MMMMMMMMMMM
6417
6418 \family typewriter
6419
6420 \backslash
6421 captionwidth
6422 \family default
6423  You can make the captions narrower than the surrounding text by adjusting
6424  this length.
6425  Best done relative to 
6426 \family typewriter
6427
6428 \backslash
6429 textwidth
6430 \family default
6431 .
6432 \end_layout
6433
6434 \begin_layout Standard
6435 There are also several title page related lengths that you may find useful
6436  if you have a long title or several authors:
6437 \end_layout
6438
6439 \begin_layout Labeling
6440 \labelwidthstring MMMMMMMMMMM
6441
6442 \family typewriter
6443
6444 \backslash
6445 abovetitleskip
6446 \family default
6447  Separation from headers to 
6448 \family sans
6449 Title
6450 \end_layout
6451
6452 \begin_layout Labeling
6453 \labelwidthstring MMMMMMMMMMM
6454
6455 \family typewriter
6456
6457 \backslash
6458 titleauthorskip
6459 \family default
6460  between 
6461 \family sans
6462 Title
6463 \family default
6464  and 
6465 \family sans
6466 Author
6467 \family default
6468  environments
6469 \end_layout
6470
6471 \begin_layout Labeling
6472 \labelwidthstring MMMMMMMMMMM
6473
6474 \family typewriter
6475
6476 \backslash
6477 authorauthorskip
6478 \family default
6479  between multiple 
6480 \family sans
6481 Author
6482 \family default
6483  lines
6484 \end_layout
6485
6486 \begin_layout Labeling
6487 \labelwidthstring MMMMMMMMMMM
6488
6489 \family typewriter
6490
6491 \backslash
6492 authordateskip
6493 \family default
6494  between the 
6495 \family sans
6496 Author
6497 \family default
6498  and the 
6499 \family sans
6500 Date
6501 \end_layout
6502
6503 \begin_layout Labeling
6504 \labelwidthstring MMMMMMMMMMM
6505
6506 \family typewriter
6507
6508 \backslash
6509 dateabstractskip
6510 \family default
6511  between the 
6512 \family sans
6513 Date
6514 \family default
6515  and the 
6516 \family sans
6517 Abstract
6518 \end_layout
6519
6520 \begin_layout Standard
6521 The last length related command affects all the list environments.
6522  If you place 
6523 \family typewriter
6524
6525 \backslash
6526 zerolistvertdimens
6527 \family default
6528  
6529 \emph on
6530 inside
6531 \emph default
6532  a list environment then all the vertical spacing between the list items
6533  is removed.
6534  Note that this is a command not a length so it doesn't require 
6535 \family typewriter
6536
6537 \backslash
6538 setlength
6539 \family default
6540  like the stuff mentioned above.
6541 \end_layout
6542
6543 \begin_layout Subsubsection
6544 Headers and Footers
6545 \end_layout
6546
6547 \begin_layout Standard
6548 The 
6549 \family typewriter
6550
6551 \backslash
6552 LogoOn
6553 \family default
6554  and 
6555 \family typewriter
6556
6557 \backslash
6558 LogoOff
6559 \family default
6560  commands control whether the logo in the 
6561 \family sans
6562 MyLogo
6563 \family default
6564  definition appear on a given page.
6565  If you put 
6566 \family typewriter
6567
6568 \backslash
6569 LogoOff
6570 \family default
6571  in the preamble then none of the foils will have the logo on them.
6572  If you don't want the logo on a particular page place the 
6573 \family typewriter
6574
6575 \backslash
6576 LogoOff
6577 \family default
6578  directly after the foilhead of that page and the 
6579 \family typewriter
6580
6581 \backslash
6582 LogoOn
6583 \family default
6584  directly after the next foilhead.
6585 \end_layout
6586
6587 \begin_layout Standard
6588 If you decide to use the 
6589 \family sans
6590 fancy
6591 \family default
6592  page style setting in the 
6593 \family sans
6594 Document
6595 \begin_inset space ~
6596 \end_inset
6597
6598 Layout
6599 \family default
6600  dialog you should probably add 
6601 \family typewriter
6602
6603 \backslash
6604 let
6605 \backslash
6606 headwidth
6607 \backslash
6608 textwidth
6609 \family default
6610  to your preamble so headers and footers on landscape pages are correctly
6611  placed when rotated.
6612  This is due to some clashes between the page layouts provided by the 
6613 \family sans
6614 fancyheadings
6615 \family default
6616  package and the 
6617 \family sans
6618 foils
6619 \family default
6620  class.
6621 \end_layout
6622
6623 \begin_layout Section
6624 Hollywood (Hollywood spec scripts)
6625 \end_layout
6626
6627 \begin_layout Standard
6628 by 
6629 \shape smallcaps
6630 Garst Reese
6631 \end_layout
6632
6633 \begin_layout Subsection
6634 Introduction
6635 \end_layout
6636
6637 \begin_layout Standard
6638 Getting the format of a Hollywood script right is a 
6639 \begin_inset Quotes eld
6640 \end_inset
6641
6642 rite of passage.
6643 \begin_inset Quotes erd
6644 \end_inset
6645
6646  It is designed to make the readers focus on content and to be easy and
6647  familiar for the actors to read.
6648  Each page of a script should be one minute of film.
6649  Nothing goes in a script that you cannot see or hear on screen.
6650  The courier 12 pt font should be used throughout.
6651  No italics.
6652 \end_layout
6653
6654 \begin_layout Subsection
6655 Special problems
6656 \end_layout
6657
6658 \begin_layout Standard
6659 Speakers' lines should NEVER break in mid-sentence.
6660  If a speaker's lines continue over a page break, repeat the 
6661 \family sans
6662 Speaker
6663 \family default
6664  title followed by (Cont'd).
6665 \end_layout
6666
6667 \begin_layout Subsection
6668 Special features
6669 \end_layout
6670
6671 \begin_layout Standard
6672 Insert the 
6673 \family sans
6674 Speaker
6675 \family default
6676  names as labels then cross-reference the label to insert the name.
6677  The cross-reference dialog will show the current cast of characters.
6678  You can use this to insert the speaker name in narratives also.
6679 \end_layout
6680
6681 \begin_layout Subsection
6682 Paper size and Margins
6683 \end_layout
6684
6685 \begin_layout Standard
6686 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
6687 \end_layout
6688
6689 \begin_layout Subsection
6690 Environments
6691 \end_layout
6692
6693 \begin_layout Standard
6694 The following environments are available.
6695  You can use hollywood.bind to get the bind keys shown at the right.
6696 \end_layout
6697
6698 \begin_layout Itemize
6699
6700 \family sans
6701 Standard
6702 \begin_inset Newline newline
6703 \end_inset
6704
6705
6706 \family default
6707 Used where nothing else works.
6708  Try to avoid it.
6709 \end_layout
6710
6711 \begin_layout Itemize
6712
6713 \family sans
6714 FADE_IN
6715 \family default
6716 :
6717 \begin_inset space \hfill{}
6718 \end_inset
6719
6720
6721 \family sans
6722 M-z S-I
6723 \family default
6724
6725 \begin_inset Newline newline
6726 \end_inset
6727
6728 Usually followed by something like 
6729 \begin_inset Quotes eld
6730 \end_inset
6731
6732 on Sally waking up.
6733 \begin_inset Quotes erd
6734 \end_inset
6735
6736
6737 \end_layout
6738
6739 \begin_layout Itemize
6740
6741 \family sans
6742 INT:
6743 \begin_inset space \hfill{}
6744 \end_inset
6745
6746 M-z i
6747 \begin_inset Newline newline
6748 \end_inset
6749
6750
6751 \family default
6752 Introduces a new INTERIOR camera set-up.
6753  Always followed by DAY or NIGHT, or something similar to define the lighting
6754  required.
6755  Everthing on this line in CAPS.
6756 \end_layout
6757
6758 \begin_layout Itemize
6759
6760 \family sans
6761 EXT:
6762 \begin_inset space \hfill{}
6763 \end_inset
6764
6765 M-z e
6766 \begin_inset Newline newline
6767 \end_inset
6768
6769
6770 \family default
6771 Introduces a new EXTERIOR camera set-up.
6772  Everthing on this line in CAPS.
6773 \end_layout
6774
6775 \begin_layout Itemize
6776
6777 \family sans
6778 Speaker
6779 \begin_inset space \hfill{}
6780 \end_inset
6781
6782 M-z s
6783 \begin_inset Newline newline
6784 \end_inset
6785
6786
6787 \family default
6788 The character speaking.
6789 \end_layout
6790
6791 \begin_layout Itemize
6792
6793 \family sans
6794 Parenthetical
6795 \begin_inset space \hfill{}
6796 \end_inset
6797
6798 M-z p
6799 \begin_inset Newline newline
6800 \end_inset
6801
6802
6803 \family default
6804 Instructions to the speaker.
6805  The () are automatically inserted, but only the ( will show in \SpecialChar LyX
6806 .
6807  Both will be printed.
6808 \end_layout
6809
6810 \begin_layout Itemize
6811
6812 \family sans
6813 Dialogue
6814 \begin_inset space \hfill{}
6815 \end_inset
6816
6817 M-z d
6818 \begin_inset Newline newline
6819 \end_inset
6820
6821
6822 \family default
6823 What the 
6824 \family sans
6825 Speaker
6826 \family default
6827  says.
6828 \end_layout
6829
6830 \begin_layout Itemize
6831
6832 \family sans
6833 Transition
6834 \begin_inset space \hfill{}
6835 \end_inset
6836
6837 M-z t
6838 \begin_inset Newline newline
6839 \end_inset
6840
6841
6842 \family default
6843 Camera movement instruction.
6844  e.
6845 \begin_inset space \thinspace{}
6846 \end_inset
6847
6848 g.
6849 \begin_inset space \space{}
6850 \end_inset
6851
6852 CUT TO:
6853 \end_layout
6854
6855 \begin_layout Itemize
6856
6857 \family sans
6858 FADE OUT:
6859 \begin_inset space \hfill{}
6860 \end_inset
6861
6862 M-z S-I
6863 \end_layout
6864
6865 \begin_layout Itemize
6866
6867 \family sans
6868 Author
6869 \begin_inset space \hfill{}
6870 \end_inset
6871
6872 M-z S-A
6873 \end_layout
6874
6875 \begin_layout Itemize
6876
6877 \family sans
6878 Title
6879 \begin_inset space \hfill{}
6880 \end_inset
6881
6882 M-z S-T
6883 \end_layout
6884
6885 \begin_layout Itemize
6886
6887 \family sans
6888 Right_Address
6889 \begin_inset space \hfill{}
6890 \end_inset
6891
6892 M-z r
6893 \end_layout
6894
6895 \begin_layout Subsection
6896 Script jargon
6897 \end_layout
6898
6899 \begin_layout Itemize
6900 (O.S) — off screen
6901 \end_layout
6902
6903 \begin_layout Itemize
6904 (V.0) — voice over
6905 \end_layout
6906
6907 \begin_layout Itemize
6908 b.
6909 \begin_inset space \thinspace{}
6910 \end_inset
6911
6912 g.
6913  — background
6914 \end_layout
6915
6916 \begin_layout Itemize
6917 C.U.
6918  — close-up
6919 \end_layout
6920
6921 \begin_layout Itemize
6922 PAN — camera movement
6923 \end_layout
6924
6925 \begin_layout Itemize
6926 INSERT — cut to close-up of
6927 \end_layout
6928
6929 \begin_layout Section
6930 ijmpc and ijmpd
6931 \end_layout
6932
6933 \begin_layout Standard
6934 by 
6935 \noun on
6936 Panayotis Papasotiriou
6937 \end_layout
6938
6939 \begin_layout Subsection
6940 Overview
6941 \end_layout
6942
6943 \begin_layout Standard
6944 The ijmpc package is a set of macros that facilitates electronic manuscript
6945  submission to the 
6946 \emph on
6947 International Journal of Modern Physics C
6948 \emph default
6949 .
6950  Similarly, the ijmpd package is for creating manuscripts to be submitted
6951  to the 
6952 \emph on
6953 International Journal of Modern Physics D
6954 \emph default
6955 .
6956  Both journals are published by World Scientific.
6957  The corresponding document classes are named 
6958 \family typewriter
6959 ws-ijmpc.cls
6960 \family default
6961  and 
6962 \family typewriter
6963 ws-ijmpd.cls
6964 \family default
6965 , respectively.
6966  These files, together with instructions for the authors, can be downloaded
6967  from the sites 
6968 \begin_inset Flex URL
6969 status collapsed
6970
6971 \begin_layout Plain Layout
6972
6973 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
6974 \end_layout
6975
6976 \end_inset
6977
6978  and 
6979 \begin_inset Flex URL
6980 status collapsed
6981
6982 \begin_layout Plain Layout
6983
6984 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
6985 \end_layout
6986
6987 \end_inset
6988
6989 .
6990  Both packages are modified versions of the standard 
6991 \begin_inset Quotes eld
6992 \end_inset
6993
6994 article
6995 \begin_inset Quotes erd
6996 \end_inset
6997
6998  package, and they are almost (but not exactly) identical.
6999  Most of their features are supported by \SpecialChar LyX
7000 .
7001  I have used \SpecialChar LyX
7002  successfully to write articles submitted to both journals
7003  without any problem.
7004 \end_layout
7005
7006 \begin_layout Subsection
7007 Writing a paper
7008 \end_layout
7009
7010 \begin_layout Standard
7011 As usual, the easiest way to write a paper is to start with a template.
7012  Click on 
7013 \family sans
7014 File\SpecialChar menuseparator
7015 New from
7016 \family default
7017  
7018 \family sans
7019 Template
7020 \family default
7021 , then choose the 
7022 \family typewriter
7023 ijmpc.lyx
7024 \family default
7025  or 
7026 \family typewriter
7027 ijmpd.lyx
7028 \family default
7029  template.
7030  This will give an (almost) empty document that includes the most common
7031  fields found in a manuscript.
7032  Simply overwrite the existing text (including the brackets, 
7033 \family typewriter
7034 <>
7035 \family default
7036 ) with your text.
7037  You should keep in mind the following remarks.
7038 \end_layout
7039
7040 \begin_layout Enumerate
7041 \SpecialChar LyX
7042  won't let you change the font size and the page style of the document,
7043  because such modifications are not allowed by both packages.
7044 \end_layout
7045
7046 \begin_layout Enumerate
7047 The language of the document should not be changed.
7048  Before previewing your paper, be sure that the babel package is not used.
7049  To do this, click on 
7050 \family sans
7051 Tools\SpecialChar menuseparator
7052 Preferences
7053 \family default
7054 , select the 
7055 \family sans
7056 Lang Opts
7057 \family default
7058  tab, deselect the 
7059 \family sans
7060 Use babel
7061 \family default
7062  checkbox in the language settings, and click on 
7063 \family sans
7064 Apply
7065 \family default
7066  (or 
7067 \family sans
7068 Save
7069 \family default
7070 , if you wish to make this change permanent).
7071 \end_layout
7072
7073 \begin_layout Enumerate
7074 The 
7075 \begin_inset Quotes eld
7076 \end_inset
7077
7078 Keywords
7079 \begin_inset Quotes erd
7080 \end_inset
7081
7082  style must be used to define keywords.
7083 \end_layout
7084
7085 \begin_layout Enumerate
7086 The ijmpc package provides a style named 
7087 \begin_inset Quotes eld
7088 \end_inset
7089
7090 Classification Codes
7091 \begin_inset Quotes erd
7092 \end_inset
7093
7094 , which can be used to define classification codes, such as PACS numbers.
7095  Note that this facility is not supported by the ijmpd package.
7096 \end_layout
7097
7098 \begin_layout Enumerate
7099 Several new environments are available: 
7100 \begin_inset Quotes eld
7101 \end_inset
7102
7103 Definition
7104 \begin_inset Quotes erd
7105 \end_inset
7106
7107
7108 \begin_inset Quotes eld
7109 \end_inset
7110
7111 Step
7112 \begin_inset Quotes erd
7113 \end_inset
7114
7115
7116 \begin_inset Quotes eld
7117 \end_inset
7118
7119 Example
7120 \begin_inset Quotes erd
7121 \end_inset
7122
7123
7124 \begin_inset Quotes eld
7125 \end_inset
7126
7127 Remark
7128 \begin_inset Quotes erd
7129 \end_inset
7130
7131
7132 \begin_inset Quotes eld
7133 \end_inset
7134
7135 Notation
7136 \begin_inset Quotes erd
7137 \end_inset
7138
7139
7140 \begin_inset Quotes eld
7141 \end_inset
7142
7143 Theorem
7144 \begin_inset Quotes erd
7145 \end_inset
7146
7147
7148 \begin_inset Quotes eld
7149 \end_inset
7150
7151 Proof
7152 \begin_inset Quotes erd
7153 \end_inset
7154
7155
7156 \begin_inset Quotes eld
7157 \end_inset
7158
7159 Corollary
7160 \begin_inset Quotes erd
7161 \end_inset
7162
7163
7164 \begin_inset Quotes eld
7165 \end_inset
7166
7167 Lemma
7168 \begin_inset Quotes erd
7169 \end_inset
7170
7171
7172 \begin_inset Quotes eld
7173 \end_inset
7174
7175 Proposition
7176 \begin_inset Quotes erd
7177 \end_inset
7178
7179
7180 \begin_inset Quotes eld
7181 \end_inset
7182
7183 Prop
7184 \begin_inset Quotes erd
7185 \end_inset
7186
7187
7188 \begin_inset Quotes eld
7189 \end_inset
7190
7191 Question
7192 \begin_inset Quotes erd
7193 \end_inset
7194
7195
7196 \begin_inset Quotes eld
7197 \end_inset
7198
7199 Claim
7200 \begin_inset Quotes erd
7201 \end_inset
7202
7203 , and 
7204 \begin_inset Quotes eld
7205 \end_inset
7206
7207 Conjecture
7208 \begin_inset Quotes erd
7209 \end_inset
7210
7211 .
7212  Their use is more or less obvious.
7213  \SpecialChar LyX
7214  supports all these environments; it will use the proper label, text style,
7215  and numbering scheme for each of them.
7216 \end_layout
7217
7218 \begin_layout Enumerate
7219 Both packages use basic citations; the natbib package should not be used.
7220  In \SpecialChar LyX
7221 , citation references are shown as usual; in the output, citations are
7222  shown as superscripts.
7223  If you want to use a citation as normal text, you should use the 
7224 \family typewriter
7225 refcite
7226 \family default
7227  command, e.
7228 \begin_inset space \thinspace{}
7229 \end_inset
7230
7231 g.
7232 \begin_inset space \space{}
7233 \end_inset
7234
7235
7236 \begin_inset Quotes eld
7237 \end_inset
7238
7239 See Ref.
7240 \begin_inset space \space{}
7241 \end_inset
7242
7243
7244 \family typewriter
7245
7246 \backslash
7247 refcite{key}
7248 \family default
7249
7250 \begin_inset Quotes erd
7251 \end_inset
7252
7253 .
7254 \end_layout
7255
7256 \begin_layout Enumerate
7257 There is no 
7258 \begin_inset Quotes eld
7259 \end_inset
7260
7261 Acknowledgments
7262 \begin_inset Quotes erd
7263 \end_inset
7264
7265  section in both packages.
7266  To put acknowledgments, just use the 
7267 \begin_inset Quotes eld
7268 \end_inset
7269
7270 Section*
7271 \begin_inset Quotes erd
7272 \end_inset
7273
7274  environment.
7275 \end_layout
7276
7277 \begin_layout Enumerate
7278 Appendices may be added to the paper, 
7279 \emph on
7280 after
7281 \emph default
7282  the Acknowledgments and 
7283 \shape italic
7284 before
7285 \shape default
7286  the References.
7287  \SpecialChar LyX
7288  provides a special environment, called 
7289 \begin_inset Quotes eld
7290 \end_inset
7291
7292 Appendices Section
7293 \begin_inset Quotes erd
7294 \end_inset
7295
7296  which marks the beginning of the appendices.
7297  This environment should be left blank; it just sends a \SpecialChar LaTeX
7298  command, but nothing
7299  is really printed.
7300  In \SpecialChar LyX
7301 , the word 
7302 \begin_inset Quotes eld
7303 \end_inset
7304
7305 Appendix
7306 \begin_inset Quotes erd
7307 \end_inset
7308
7309  is printed with blue letters, as a signal that all sections after that
7310  point are appendices.
7311  To write an appendix, use the 
7312 \begin_inset Quotes eld
7313 \end_inset
7314
7315 Appendix
7316 \begin_inset Quotes erd
7317 \end_inset
7318
7319  environment.
7320  \SpecialChar LyX
7321  will number each appendix with capital letters, as required by both journals.
7322  Note that 
7323 \begin_inset Quotes eld
7324 \end_inset
7325
7326 Appendices Section
7327 \begin_inset Quotes erd
7328 \end_inset
7329
7330  
7331 \emph on
7332 must
7333 \emph default
7334  be present before the first appendix; if not, all appendices will be numbered
7335  as normal sections in the output.
7336 \end_layout
7337
7338 \begin_layout Enumerate
7339 The ijmpc and the ijmpd packages use the 
7340 \family typewriter
7341 tbl
7342 \family default
7343  command to implement table captions.
7344  As a result, a table created by \SpecialChar LyX
7345  is printed correctly, but its caption
7346  is ignored.
7347  However, you can use some \SpecialChar TeX
7348  code to overcome this problem, so that captions
7349  are printed as expected.
7350  To do so, create a float table as usual, remove the caption, and replace
7351  it with the \SpecialChar TeX
7352  code 
7353 \family typewriter
7354
7355 \backslash
7356 tbl{
7357 \emph on
7358 your table caption
7359 \emph default
7360 }{
7361 \family default
7362  (sic); you must also the \SpecialChar TeX
7363  code 
7364 \family typewriter
7365 }
7366 \family default
7367  immediately after the tabular material.
7368  Study the example table included in the template files to see how this
7369  trick is implemented.
7370  Alternatively, If you need table captions, you should implement the whole
7371  table float in a 
7372 \family typewriter
7373 .tex
7374 \family default
7375  file, then include this file to the \SpecialChar LyX
7376  document (
7377 \family sans
7378 Insert\SpecialChar menuseparator
7379 File\SpecialChar menuseparator
7380 Child
7381 \begin_inset space ~
7382 \end_inset
7383
7384 Document
7385 \family default
7386 ).
7387  Details on how to create a table float can be found in the files 
7388 \family typewriter
7389 ws-ijmpc.tex
7390 \family default
7391  and 
7392 \family typewriter
7393 ws-ijmpd.tex
7394 \family default
7395 , included in the corresponding packages.
7396 \end_layout
7397
7398 \begin_layout Subsection
7399 Preparing a paper for submission
7400 \end_layout
7401
7402 \begin_layout Standard
7403 Before you submit your paper you must export the \SpecialChar LyX
7404  document as a \SpecialChar LaTeX
7405  file (
7406 \family sans
7407 File\SpecialChar menuseparator
7408 Export\SpecialChar menuseparator
7409 \SpecialChar LaTeX
7410
7411 \family default
7412 )
7413 \begin_inset Foot
7414 status open
7415
7416 \begin_layout Plain Layout
7417 Actually you have the choice between \SpecialChar LaTeX
7418  (plain) and pdflatex.
7419  If you intend to use pdflatex to prepare the paper, you should use the
7420  pdflatex option so that included graphics are converted to PDF format,
7421  ready for use by pdflatex.
7422 \end_layout
7423
7424 \end_inset
7425
7426 , then make the following changes to the resulting 
7427 \family typewriter
7428 .tex
7429 \family default
7430  file.
7431 \end_layout
7432
7433 \begin_layout Enumerate
7434 Remove the comment lines before the 
7435 \family typewriter
7436
7437 \backslash
7438 documentclass
7439 \family default
7440  command.
7441 \end_layout
7442
7443 \begin_layout Enumerate
7444 Remove everything between (and including) the 
7445 \family typewriter
7446
7447 \backslash
7448 makeatletter
7449 \family default
7450  and 
7451 \family typewriter
7452
7453 \backslash
7454 makeatother
7455 \family default
7456  commands, except for any commands you specifically put into the \SpecialChar LaTeX
7457  preamble.
7458 \end_layout
7459
7460 \begin_layout Standard
7461 The modified 
7462 \family typewriter
7463 .tex
7464 \family default
7465  file should be saved and processed through \SpecialChar LaTeX
7466  as many times as necessary.
7467  You may also want to check the resulting 
7468 \family typewriter
7469 .dvi
7470 \family default
7471  document.
7472 \end_layout
7473
7474 \begin_layout Subsection
7475 Use of \SpecialChar TeX
7476  code
7477 \end_layout
7478
7479 \begin_layout Standard
7480 The use of \SpecialChar TeX
7481  code is reduced to two commands, which must be placed at the
7482  top of the document.
7483  If you started writing your paper by using the 
7484 \family typewriter
7485 ijmpc.lyx
7486 \family default
7487  or the 
7488 \family typewriter
7489 ijmpd.lyx
7490 \family default
7491  template, the \SpecialChar TeX
7492  code needed is already in its place; you usually don't need
7493  to delete it.
7494  You may only modify the first \SpecialChar TeX
7495  code to specify the information printed
7496  to the top of odd and even pages (authors' names and short paper's title,
7497  respectively).
7498  This \SpecialChar TeX
7499  code must have the form 
7500 \family typewriter
7501
7502 \backslash
7503 markboth{Authors' Names}{Short Paper's Title}
7504 \family default
7505 .
7506 \end_layout
7507
7508 \begin_layout Section
7509 iopart
7510 \end_layout
7511
7512 \begin_layout Standard
7513 by 
7514 \noun on
7515 Uwe Stöhr
7516 \end_layout
7517
7518 \begin_layout Subsection
7519 Overview
7520 \end_layout
7521
7522 \begin_layout Standard
7523 The iopart package provides a document class to create electronic manuscript
7524  submission to the journals published by the Institute of Physics.
7525  Instructions for the authors how to create a paper using the iopart class
7526  can be downloaded together with the iopart package from the site 
7527 \begin_inset Flex URL
7528 status collapsed
7529
7530 \begin_layout Plain Layout
7531
7532 ftp://ftp.iop.org/pub/journals/latex2e
7533 \end_layout
7534
7535 \end_inset
7536
7537 .
7538 \end_layout
7539
7540 \begin_layout Subsection
7541 Writing a paper
7542 \end_layout
7543
7544 \begin_layout Standard
7545 The easiest way to write a paper is to start with the file 
7546 \emph on
7547 IOP-article.lyx
7548 \emph default
7549  that is available in \SpecialChar LyX
7550 's examples files folder.
7551  Open this file, save it under a new name, and start writing.
7552  The example file explains how to use the special text environments.
7553  Here are the most important advices:
7554 \end_layout
7555
7556 \begin_layout Itemize
7557 To be able to compile your document to a PDF, PS, or DVI, ensure that the
7558  two options 
7559 \family sans
7560 Use AMS math package
7561 \family default
7562  in the document settings under 
7563 \family sans
7564 Math Options
7565 \family default
7566  are not used!
7567 \end_layout
7568
7569 \begin_layout Itemize
7570
7571 \size normal
7572 The title environment defines the kind of your paper.
7573  So use one of the following environments for the title:
7574 \end_layout
7575
7576 \begin_deeper
7577 \begin_layout Itemize
7578
7579 \family sans
7580 \size normal
7581 Title
7582 \family default
7583  for a Paper
7584 \end_layout
7585
7586 \begin_layout Itemize
7587
7588 \family sans
7589 \size normal
7590 Review
7591 \family default
7592  for a Review
7593 \end_layout
7594
7595 \begin_layout Itemize
7596
7597 \family sans
7598 \size normal
7599 Topical
7600 \family default
7601  for a Topical review
7602 \end_layout
7603
7604 \begin_layout Itemize
7605
7606 \family sans
7607 \size normal
7608 Comment
7609 \family default
7610  for a Comment
7611 \end_layout
7612
7613 \begin_layout Itemize
7614
7615 \family sans
7616 \size normal
7617 Note
7618 \family default
7619  for a Note
7620 \end_layout
7621
7622 \begin_layout Itemize
7623
7624 \family sans
7625 \size normal
7626 Paper
7627 \family default
7628  for a Paper (same as Title)
7629 \end_layout
7630
7631 \begin_layout Itemize
7632
7633 \family sans
7634 \size normal
7635 Prelim
7636 \family default
7637  for a Preliminary communication
7638 \end_layout
7639
7640 \begin_layout Itemize
7641
7642 \family sans
7643 \size normal
7644 Rapid
7645 \family default
7646  for a Rapid communication
7647 \end_layout
7648
7649 \begin_layout Itemize
7650
7651 \family sans
7652 \size normal
7653 Letter
7654 \family default
7655  for a Letter to the editor
7656 \end_layout
7657
7658 \end_deeper
7659 \begin_layout Itemize
7660
7661 \size normal
7662 All title environments except of 
7663 \family sans
7664 Letter
7665 \family default
7666  can have an optional short title.
7667 \end_layout
7668
7669 \begin_layout Itemize
7670 There is a general title environment 
7671 \family sans
7672 Article
7673 \family default
7674  which is not directly supported by the \SpecialChar LyX
7675 .
7676  This can be used as \SpecialChar TeX
7677  code when your document doesn't fit into one of the
7678  other title types.
7679 \end_layout
7680
7681 \begin_layout Standard
7682 For more informations like hints for special table and formula formatting,
7683  look at the IOP author guidelines.
7684 \end_layout
7685
7686 \begin_layout Section
7687 Kluwer
7688 \end_layout
7689
7690 \begin_layout Standard
7691 by 
7692 \noun on
7693 Panayotis Papasotiriou
7694 \end_layout
7695
7696 \begin_layout Subsection
7697 Overview
7698 \end_layout
7699
7700 \begin_layout Standard
7701 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
7702  that facilitates electronic manuscript submission to the journals they
7703  publish.
7704  Most known of them (at least in my domain of interest) are 
7705 \emph on
7706 Astrophysics and Space Science
7707 \emph default
7708  and 
7709 \emph on
7710 Solar Physics
7711 \emph default
7712 , but there are many others (see a complete list at 
7713 \begin_inset Flex URL
7714 status open
7715
7716 \begin_layout Plain Layout
7717
7718 http://www.wkap.nl/jrnllist.htm/JRNLHOME
7719 \end_layout
7720
7721 \end_inset
7722
7723 ).
7724  The Kluwer package may be downloaded from the site 
7725 \begin_inset Flex URL
7726 status collapsed
7727
7728 \begin_layout Plain Layout
7729
7730 http://www.wkap.nl/kaphtml.htm/STYLEFILES
7731 \end_layout
7732
7733 \end_inset
7734
7735 .
7736  A complete user guide is contained in that package (but it can also be
7737  downloaded separately).
7738 \end_layout
7739
7740 \begin_layout Standard
7741 \SpecialChar LyX
7742  supports many features of the package but not everything.
7743  However, the \SpecialChar TeX
7744  code needed is reduced to some 
7745 \begin_inset Quotes eld
7746 \end_inset
7747
7748 peculiar
7749 \begin_inset Quotes erd
7750 \end_inset
7751
7752  commands of the package (see
7753 \begin_inset space ~
7754 \end_inset
7755
7756
7757 \begin_inset CommandInset ref
7758 LatexCommand ref
7759 reference "subsec:kluwer_peculiarities"
7760
7761 \end_inset
7762
7763 ).
7764  I have recently used \SpecialChar LyX
7765  to write an article submitted to the 
7766 \emph on
7767 Astrophysics and Space Science
7768 \emph default
7769  without any problem.
7770 \end_layout
7771
7772 \begin_layout Subsection
7773 Writing a paper
7774 \end_layout
7775
7776 \begin_layout Standard
7777 The easiest way to write a paper is to start with the Kluwer template file.
7778  Click on 
7779 \family sans
7780 File\SpecialChar menuseparator
7781 New from
7782 \family default
7783  
7784 \family sans
7785 Template
7786 \family default
7787 , then choose the 
7788 \family typewriter
7789 kluwer.lyx
7790 \family default
7791  template.
7792  This will give an (almost) empty document that includes the most common
7793  fields found in a manuscript and a short description of their use.
7794  As in most templates, simply overwrite the existing text (including the
7795  brackets, 
7796 \family typewriter
7797 <>
7798 \family default
7799 ) with the correct information.
7800 \end_layout
7801
7802 \begin_layout Subsection
7803 Preparing a paper for submission
7804 \end_layout
7805
7806 \begin_layout Standard
7807 As in the AAS\SpecialChar TeX
7808  package, before you submit your paper to a journal you must
7809  
7810 \begin_inset Quotes eld
7811 \end_inset
7812
7813 postprocess
7814 \begin_inset Quotes erd
7815 \end_inset
7816
7817  it as follows.
7818 \end_layout
7819
7820 \begin_layout Enumerate
7821 Export your paper as a \SpecialChar LaTeX
7822  file.
7823  To do this, click on 
7824 \family sans
7825 File\SpecialChar menuseparator
7826 Export\SpecialChar menuseparator
7827 \SpecialChar LaTeX
7828
7829 \family default
7830 .
7831  
7832 \end_layout
7833
7834 \begin_layout Enumerate
7835 Edit the resulting 
7836 \family typewriter
7837 .tex
7838 \family default
7839  file with a text editor and make the following changes
7840 \end_layout
7841
7842 \begin_deeper
7843 \begin_layout Enumerate
7844 remove the comment lines before the 
7845 \family typewriter
7846
7847 \backslash
7848 documentclass
7849 \family default
7850  command,
7851 \end_layout
7852
7853 \begin_layout Enumerate
7854 remove everything between (and including) the 
7855 \family typewriter
7856
7857 \backslash
7858 makeatletter
7859 \family default
7860  and 
7861 \family typewriter
7862
7863 \backslash
7864 makeatother
7865 \family default
7866  commands, except for any commands you specifically put into the \SpecialChar LaTeX
7867  preamble.
7868 \end_layout
7869
7870 \begin_layout Standard
7871 Save the resulting 
7872 \family typewriter
7873 .tex
7874 \family default
7875  file.
7876 \end_layout
7877
7878 \end_deeper
7879 \begin_layout Enumerate
7880 Run the 
7881 \family typewriter
7882 .tex
7883 \family default
7884  file through \SpecialChar LaTeX
7885  as many times as necessary (usually up to three).
7886 \end_layout
7887
7888 \begin_layout Enumerate
7889 View the resulting 
7890 \family typewriter
7891 .dvi
7892 \family default
7893  document using, e.
7894 \begin_inset space \thinspace{}
7895 \end_inset
7896
7897 g.
7898 \begin_inset space \space{}
7899 \end_inset
7900
7901
7902 \family sans
7903 xdvi
7904 \family default
7905 , and check if everything is OK (it should, if you didn't make any mistake).
7906 \end_layout
7907
7908 \begin_layout Subsection
7909 \begin_inset Quotes eld
7910 \end_inset
7911
7912 Peculiarities
7913 \begin_inset Quotes erd
7914 \end_inset
7915
7916  of the Kluwer package
7917 \begin_inset CommandInset label
7918 LatexCommand label
7919 name "subsec:kluwer_peculiarities"
7920
7921 \end_inset
7922
7923
7924 \end_layout
7925
7926 \begin_layout Standard
7927 The Kluwer package has the following 
7928 \begin_inset Quotes eld
7929 \end_inset
7930
7931 peculiarities
7932 \begin_inset Quotes erd
7933 \end_inset
7934
7935 .
7936 \end_layout
7937
7938 \begin_layout Enumerate
7939 It is possible to write multiple articles in the same \SpecialChar LaTeX
7940  file
7941 \begin_inset Foot
7942 status collapsed
7943
7944 \begin_layout Plain Layout
7945 I can't imagine any good reason to do this.
7946 \end_layout
7947
7948 \end_inset
7949
7950 .
7951  Each article must be included in the environment 
7952 \begin_inset Quotes eld
7953 \end_inset
7954
7955 article
7956 \begin_inset Quotes erd
7957 \end_inset
7958
7959 .
7960  Unfortunately, this environment cannot be omitted, even if you write just
7961  one article.
7962  Therefore, each article starts with the command 
7963 \family typewriter
7964
7965 \backslash
7966 begin{article}
7967 \family default
7968  and, obviously, ends with the command 
7969 \family typewriter
7970
7971 \backslash
7972 end{article}
7973 \family default
7974 .
7975  Although this can be implemented in \SpecialChar LyX
7976 , I didn't included it, since it looks
7977  ugly and can confuse the novice user.
7978  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
7979  code (the
7980  well-known 
7981 \begin_inset Quotes eld
7982 \end_inset
7983
7984 \SpecialChar TeX
7985  code
7986 \begin_inset Quotes erd
7987 \end_inset
7988
7989 ).
7990 \end_layout
7991
7992 \begin_layout Enumerate
7993 Information given at the beginning of the article (i.
7994 \begin_inset space \thinspace{}
7995 \end_inset
7996
7997 e.
7998 \begin_inset space \space{}
7999 \end_inset
8000
8001 title, subtitle, author, institution, running title, running author, abstract
8002  and keywords) must be included in an environment called 
8003 \begin_inset Quotes eld
8004 \end_inset
8005
8006 opening
8007 \begin_inset Quotes erd
8008 \end_inset
8009
8010 .
8011  This is not implemented in \SpecialChar LyX
8012 , so you must enter title, subtitle etc.
8013 \begin_inset space ~
8014 \end_inset
8015
8016 between two \SpecialChar TeX
8017  code lines (
8018 \family typewriter
8019
8020 \backslash
8021 begin{opening}
8022 \family default
8023  and 
8024 \family typewriter
8025
8026 \backslash
8027 end{opening}
8028 \family default
8029 ).
8030 \end_layout
8031
8032 \begin_layout Enumerate
8033 According to the user manual, the label of each bibliography item must be
8034  written as 
8035 \family typewriter
8036
8037 \backslash
8038 protect
8039 \backslash
8040 citeauthoryear{
8041 \family default
8042 \emph on
8043 author(s)
8044 \family typewriter
8045 \emph default
8046 }{
8047 \family default
8048 \emph on
8049 year
8050 \family typewriter
8051 \emph default
8052 }
8053 \family default
8054 .
8055 \end_layout
8056
8057 \begin_layout Standard
8058 The 
8059 \family typewriter
8060 kluwer.lyx
8061 \family default
8062  template takes care of all these 
8063 \begin_inset Quotes eld
8064 \end_inset
8065
8066 peculiarities
8067 \begin_inset Quotes erd
8068 \end_inset
8069
8070 .
8071  If you start a new paper using this template you don't need to do anything
8072  special.
8073  Just 
8074 \end_layout
8075
8076 \begin_layout Enumerate
8077 don't delete the \SpecialChar TeX
8078  code included in the template, and
8079 \end_layout
8080
8081 \begin_layout Enumerate
8082 copy the example bibliography item included in the template and modify it
8083  as necessary to enter new bibliography items.
8084 \end_layout
8085
8086 \begin_layout Section
8087 Koma-Script
8088 \end_layout
8089
8090 \begin_layout Standard
8091 by 
8092 \noun on
8093 Bernd Rellermeyer
8094 \end_layout
8095
8096 \begin_layout Subsection
8097 Overview
8098 \end_layout
8099
8100 \begin_layout Standard
8101 The \SpecialChar LyX
8102  document classes 
8103 \emph on
8104 article (koma-script)
8105 \emph default
8106
8107 \emph on
8108 report (koma-script)
8109 \emph default
8110
8111 \emph on
8112 book
8113 \emph default
8114  
8115 \emph on
8116 (koma-script)
8117 \emph default
8118 , and 
8119 \emph on
8120 letter
8121 \emph default
8122  
8123 \emph on
8124 (koma-script)
8125 \emph default
8126  correspond to the \SpecialChar LaTeX
8127  document classes 
8128 \family typewriter
8129 scrartcl.cls
8130 \family default
8131
8132 \family typewriter
8133 scrreprt.cls
8134 \family default
8135
8136 \family typewriter
8137 scrbook.cls
8138 \family default
8139 , and 
8140 \family typewriter
8141 scrlettr.cls
8142 \family default
8143 , resp.
8144 \begin_inset space ~
8145 \end_inset
8146
8147 of the Koma-Script family.
8148  They are replacements for the standard document classes 
8149 \family typewriter
8150 article.cls
8151 \family default
8152
8153 \family typewriter
8154 report.cls
8155 \family default
8156
8157 \family typewriter
8158 book.cls
8159 \family default
8160  and 
8161 \family typewriter
8162 letter.cls
8163 \family default
8164 , resp., and fit better to European typography conventions in a number of
8165  points.
8166 \end_layout
8167
8168 \begin_layout Itemize
8169 Standard character size is 11pt in 
8170 \emph on
8171 article (koma-script)
8172 \emph default
8173
8174 \emph on
8175 report (koma-script)
8176 \emph default
8177 , and 
8178 \emph on
8179 book (koma-script)
8180 \emph default
8181 , and 12pt in 
8182 \emph on
8183 letter (koma-script)
8184 \emph default
8185 .
8186 \end_layout
8187
8188 \begin_layout Itemize
8189 Headings, labels of the description environment, and a number of elements
8190  of the 
8191 \emph on
8192 letter (koma-script)
8193 \emph default
8194  document class are set in a bold sans serif font.
8195 \begin_inset Foot
8196 status collapsed
8197
8198 \begin_layout Plain Layout
8199 There is a big difference between the bold sans serif old cm fonts and new
8200  ec fonts, especially in the appearance of headings.
8201  In comparison, the ec bold sans serif fonts look a bit thin.
8202  Here the \SpecialChar LaTeX
8203  package 
8204 \family typewriter
8205 cmsd.sty by
8206 \family default
8207  
8208 \shape smallcaps
8209 Walter Schmidt
8210 \shape default
8211  helps to produce the 
8212 \begin_inset Quotes eld
8213 \end_inset
8214
8215 usual
8216 \begin_inset Quotes erd
8217 \end_inset
8218
8219  appearance when using the ec fonts.
8220 \end_layout
8221
8222 \end_inset
8223
8224  The numbering of chapter headings is made in the same way as the numbering
8225  of section headings, that is without the extra line 
8226 \begin_inset Quotes eld
8227 \end_inset
8228
8229 Chapter\SpecialChar ldots
8230
8231 \begin_inset Quotes erd
8232 \end_inset
8233
8234 .
8235  In addition, the appearance of the headings can be modified by using a
8236  number of options (in \SpecialChar LyX
8237  to be entered in the field 
8238 \family sans
8239 Extra
8240 \begin_inset space ~
8241 \end_inset
8242
8243 Options
8244 \family default
8245  of the dialog 
8246 \family sans
8247 Layout\SpecialChar menuseparator
8248 Document
8249 \family default
8250 ).
8251  
8252 \end_layout
8253
8254 \begin_layout Itemize
8255 The main means in the Koma-Script document classes to design the type area
8256  are the options 
8257 \family sans
8258 BCOR
8259 \family default
8260  and 
8261 \family sans
8262 DIV
8263 \family default
8264  (in \SpecialChar LyX
8265  to be entered in the extra class options field in the dialog 
8266 \family sans
8267 Document\SpecialChar menuseparator
8268 Settings
8269 \family default
8270 ).
8271  They make a clearer modification of page margins possible as do the options
8272  of the dialog 
8273 \family sans
8274 Document\SpecialChar menuseparator
8275 Settings
8276 \family default
8277 .
8278  
8279 \end_layout
8280
8281 \begin_layout Itemize
8282 The \SpecialChar LaTeX
8283  document classes of the Koma-Script family define a number of additional
8284  commands.
8285  Those part of it which makes sense in \SpecialChar LyX
8286  is implemented in corresponding
8287  paragraph types.
8288 \end_layout
8289
8290 \begin_layout Standard
8291 Detailed descriptions of the \SpecialChar LaTeX
8292  document classes of the Koma-Script family
8293  can be found in the Koma-Script documentation 
8294 \emph on
8295 scrguide
8296 \emph default
8297  (German) and 
8298 \emph on
8299 scrguien
8300 \emph default
8301  (English).
8302 \end_layout
8303
8304 \begin_layout Subsection
8305 article (koma-script), report (koma-script), and book (koma-script)
8306 \end_layout
8307
8308 \begin_layout Standard
8309 The document classes 
8310 \emph on
8311 article (koma-script)
8312 \emph default
8313
8314 \emph on
8315 report (koma-script)
8316 \emph default
8317 , and 
8318 \emph on
8319 book
8320 \emph default
8321  
8322 \emph on
8323 (koma-script)
8324 \emph default
8325  are implemented in the layout files 
8326 \family typewriter
8327 scrartcl.layout
8328 \family default
8329
8330 \family typewriter
8331 scrreprt.layout
8332 \family default
8333 , and 
8334 \family typewriter
8335 scrbook.layout
8336 \family default
8337 , resp.
8338  They contain all the paragraph types of the corresponding standard document
8339  classes 
8340 \emph on
8341 article
8342 \emph default
8343
8344 \emph on
8345 report
8346 \emph default
8347 , and 
8348 \emph on
8349 book
8350 \emph default
8351 , resp., partly modified, with the exception of the \SpecialChar LyX
8352  specific 
8353 \family sans
8354 List
8355 \family default
8356 -type, which is replaced by the new 
8357 \family sans
8358 Labeling
8359 \family default
8360 -type having the same functionality.
8361  Beside the 
8362 \family sans
8363 Labeling
8364 \family default
8365 -Type there is a number of new paragraph types added.
8366  They are 
8367 \emph on
8368 not
8369 \emph default
8370  part of 
8371 \emph on
8372 letter (koma-script)
8373 \emph default
8374 .
8375 \end_layout
8376
8377 \begin_layout Itemize
8378
8379 \family sans
8380 Addpart, Addchap
8381 \family default
8382
8383 \family sans
8384 Addsec
8385 \family default
8386 : are equivalents to 
8387 \family sans
8388 Part*, Chapter*
8389 \family default
8390  and 
8391 \family sans
8392 Section*
8393 \family default
8394 , resp., additionally inserting an entry in the table of contents.
8395  
8396 \family sans
8397 Addpart
8398 \family default
8399  and 
8400 \family sans
8401 Addchap
8402 \family default
8403  are not contained in 
8404 \emph on
8405 article (koma-script)
8406 \emph default
8407 .
8408 \end_layout
8409
8410 \begin_layout Itemize
8411
8412 \family sans
8413 Addchap*
8414 \family default
8415
8416 \family sans
8417 Addsec*
8418 \family default
8419 : behave exactly as 
8420 \family sans
8421 Addchap
8422 \family default
8423  and 
8424 \family sans
8425 Addsec
8426 \family default
8427 , resp., additionally clearing running heads.
8428  
8429 \family sans
8430 Addchap*
8431 \family default
8432  is not contained in 
8433 \emph on
8434 article (koma-script)
8435 \emph default
8436 .
8437 \begin_inset Foot
8438 status collapsed
8439
8440 \begin_layout Plain Layout
8441 There is also an 
8442 \family typewriter
8443
8444 \backslash
8445 addpart*
8446 \family default
8447  command in 
8448 \emph on
8449 book (koma-script)
8450 \emph default
8451  and in 
8452 \emph on
8453 report (koma-script)
8454 \emph default
8455 , but since this is identical to 
8456 \family sans
8457 Part*
8458 \family default
8459 , is has not been implemented in \SpecialChar LyX
8460 .
8461 \end_layout
8462
8463 \end_inset
8464
8465
8466 \end_layout
8467
8468 \begin_layout Itemize
8469
8470 \family sans
8471 Minisec
8472 \family default
8473 : generates a heading directly above the following paragraph in the standard
8474  character size without affecting the structure of the document.
8475 \end_layout
8476
8477 \begin_layout Itemize
8478
8479 \family sans
8480 Captionabove
8481 \family default
8482  and 
8483 \family sans
8484 Captionbelow
8485 \family default
8486  are special captions which respect the different space settings needed
8487  for captions placed above or below an element (if you follow strict typographic
8488  rules, you might want to place table captions always above the table).
8489  You can also use the class option 
8490 \family typewriter
8491 tablecaptionsabove
8492 \family default
8493 , which will switch 
8494 \family sans
8495 caption
8496 \family default
8497  to 
8498 \family sans
8499 captionabove
8500 \family default
8501  for tables and 
8502 \family sans
8503 captionbelow
8504 \family default
8505  for figures.
8506  You need at least Koma-Script version 2.8q to use this.
8507 \end_layout
8508
8509 \begin_layout Itemize
8510
8511 \family sans
8512 Dictum
8513 \family default
8514 : can be used to set a bonmot, e.
8515 \begin_inset space \thinspace{}
8516 \end_inset
8517
8518 g.
8519 \begin_inset space \space{}
8520 \end_inset
8521
8522 at the beginning of a chapter.
8523  If you use the optional argument (
8524 \family sans
8525 Insert\SpecialChar menuseparator
8526 Short
8527 \begin_inset space ~
8528 \end_inset
8529
8530 Title
8531 \family default
8532 ), you can insert the dictum's author there.
8533  Dictum and author are separated by a line.
8534  You need at least Koma-Script version 2.8q to use this.
8535  
8536 \family sans
8537 Dictum
8538 \family default
8539  is not contained in 
8540 \emph on
8541 article (koma-script)
8542 \emph default
8543 .
8544 \end_layout
8545
8546 \begin_layout Standard
8547 The following types, together with the standard types 
8548 \family sans
8549 Title
8550 \family default
8551
8552 \family sans
8553 Author
8554 \family default
8555 , and 
8556 \family sans
8557 Date
8558 \family default
8559 , form the title area of the document.
8560  They must be entered ahead of the first 
8561 \begin_inset Quotes eld
8562 \end_inset
8563
8564 ordinary
8565 \begin_inset Quotes erd
8566 \end_inset
8567
8568  paragraph.
8569 \begin_inset Foot
8570 status collapsed
8571
8572 \begin_layout Plain Layout
8573 The corresponding \SpecialChar LaTeX
8574  commands must appear before the 
8575 \family typewriter
8576
8577 \backslash
8578 maketitle
8579 \family default
8580  command.
8581 \end_layout
8582
8583 \end_inset
8584
8585  When such a type is used more than once, the latter usage overwrites the
8586  former one, that means, for every type only the latest usage is valid.
8587  The order of the different types however has, like 
8588 \family sans
8589 Title
8590 \family default
8591
8592 \family sans
8593 Author
8594 \family default
8595 , and 
8596 \family sans
8597 Date
8598 \family default
8599 , no effect on the appearance of the produced document.
8600 \end_layout
8601
8602 \begin_layout Itemize
8603
8604 \family sans
8605 Subject
8606 \family default
8607 : produces a centered paragraph above the ordinary title (
8608 \family sans
8609 Title
8610 \family default
8611
8612 \family sans
8613 Author
8614 \family default
8615
8616 \family sans
8617 Date
8618 \family default
8619 ) for the subject of the document.
8620 \end_layout
8621
8622 \begin_layout Itemize
8623
8624 \family sans
8625 Publishers
8626 \family default
8627 : produces a centered paragraph below the ordinary title (
8628 \family sans
8629 Title
8630 \family default
8631
8632 \family sans
8633 Author
8634 \family default
8635
8636 \family sans
8637 Date
8638 \family default
8639 ) for the publishers' name.
8640 \end_layout
8641
8642 \begin_layout Itemize
8643
8644 \family sans
8645 Dedication
8646 \family default
8647 : in 
8648 \emph on
8649 report (koma-script)
8650 \emph default
8651  and 
8652 \emph on
8653 book (koma-script)
8654 \emph default
8655  produces a centered paragraph on its own page behind the title page, or
8656  in 
8657 \emph on
8658 article (koma-script)
8659 \emph default
8660  produces a centered paragraph below the ordinary title (
8661 \family sans
8662 Title
8663 \family default
8664
8665 \family sans
8666 Author
8667 \family default
8668
8669 \family sans
8670 Date
8671 \family default
8672
8673 \family sans
8674 Publishers
8675 \family default
8676 ) for a dedication.
8677 \end_layout
8678
8679 \begin_layout Itemize
8680
8681 \family sans
8682 Titlehead
8683 \family default
8684 : produces a left aligned paragraph above the ordinary title (
8685 \family sans
8686 Title
8687 \family default
8688
8689 \family sans
8690 Author
8691 \family default
8692
8693 \family sans
8694 Date
8695 \family default
8696
8697 \family sans
8698 Subject
8699 \family default
8700 ) for a document`s head.
8701 \end_layout
8702
8703 \begin_layout Itemize
8704
8705 \family sans
8706 Uppertitleback
8707 \family default
8708 : produces in a double-sided print in 
8709 \emph on
8710 report (koma-script)
8711 \emph default
8712  and 
8713 \emph on
8714 book (koma-script)
8715 \emph default
8716  a left-aligned paragraph at the top of the title page`s back or has no
8717  effect in a single-sided print or in 
8718 \emph on
8719 article (koma-script)
8720 \emph default
8721 .
8722 \end_layout
8723
8724 \begin_layout Itemize
8725
8726 \family sans
8727 Lowertitleback
8728 \family default
8729 : produces in a double-sided print in 
8730 \emph on
8731 report (koma-script)
8732 \emph default
8733  and 
8734 \emph on
8735 book (koma-script)
8736 \emph default
8737  a left-aligned paragraph at the bottom of the title page`s back or has
8738  no effect in a single-sided print or in 
8739 \emph on
8740 article (koma-script)
8741 \emph default
8742 .
8743 \end_layout
8744
8745 \begin_layout Itemize
8746
8747 \family sans
8748 Extratitle
8749 \family default
8750 : produces a special 
8751 \begin_inset Quotes eld
8752 \end_inset
8753
8754 dirty
8755 \begin_inset Quotes erd
8756 \end_inset
8757
8758  page ahead of the actual document containing a paragraph without special
8759  formatting.
8760 \end_layout
8761
8762 \begin_layout Standard
8763 The layout files for the document classes 
8764 \emph on
8765 article (koma-script)
8766 \emph default
8767
8768 \emph on
8769 report (koma-script)
8770 \emph default
8771 , and 
8772 \emph on
8773 book (koma-script)
8774 \emph default
8775  do include the file 
8776 \family typewriter
8777 scrmacros.inc
8778 \family default
8779 .
8780  This is thought of as a place to define your own types.
8781  Copy scrmacros
8782 \family typewriter
8783 .inc
8784 \family default
8785  in your personal layout directory and edit the file!
8786 \end_layout
8787
8788 \begin_layout Subsection
8789 letter (koma-script)
8790 \end_layout
8791
8792 \begin_layout Standard
8793 \noindent
8794 The document class 
8795 \emph on
8796 letter (koma-script)
8797 \emph default
8798  is implemented in the layout file 
8799 \family typewriter
8800 scrlettr.layout
8801 \family default
8802 .
8803  It contains all the paragraph types of the corresponding standard document
8804  class 
8805 \emph on
8806 letter
8807 \emph default
8808 , partly modified, with the exception of the \SpecialChar LyX
8809  specific types 
8810 \family sans
8811 \SpecialChar LyX
8812 -Code
8813 \family default
8814  and 
8815 \family sans
8816 Comment
8817 \family default
8818  and the 
8819 \family sans
8820 List
8821 \family default
8822  type, which is replaced by the new 
8823 \family sans
8824 Labeling
8825 \family default
8826  type.
8827  In addition, it contains, in contrast to the standard document class, the
8828  standard types 
8829 \family sans
8830 \SpecialChar LaTeX
8831
8832 \family default
8833
8834 \family sans
8835 Quotation
8836 \family default
8837
8838 \family sans
8839 Quote
8840 \family default
8841 , and 
8842 \family sans
8843 Verse
8844 \family default
8845 .
8846  Furthermore, there are a number of new letter specific types.
8847 \end_layout
8848
8849 \begin_layout Standard
8850 The appearance of the letter produced by this document class can be controlled
8851  by a number of \SpecialChar LaTeX
8852  commands, which you can put in the \SpecialChar LaTeX
8853  preamble.
8854 \begin_inset Foot
8855 status collapsed
8856
8857 \begin_layout Plain Layout
8858 For example, the standard appearance of the letter`s heading, consisting
8859  of name and address, is quite self-willed.
8860  An 
8861 \begin_inset Quotes eld
8862 \end_inset
8863
8864 ordinary
8865 \begin_inset Quotes erd
8866 \end_inset
8867
8868  heading is produced by the following \SpecialChar LaTeX
8869  commands in the preamble:
8870 \end_layout
8871
8872 \begin_layout LyX-Code
8873
8874 \backslash
8875 firsthead{
8876 \backslash
8877 parbox[b]{
8878 \backslash
8879 textwidth}
8880 \end_layout
8881
8882 \begin_layout LyX-Code
8883   {
8884 \backslash
8885 ignorespaces 
8886 \backslash
8887 fromname
8888 \backslash
8889
8890 \backslash
8891  
8892 \backslash
8893 ignorespaces 
8894 \backslash
8895 fromaddress}} 
8896 \end_layout
8897
8898 \begin_layout LyX-Code
8899
8900 \backslash
8901 nexthead{
8902 \backslash
8903 parbox[b]{
8904 \backslash
8905 textwidth}
8906 \end_layout
8907
8908 \begin_layout LyX-Code
8909   {
8910 \backslash
8911 ignorespaces 
8912 \backslash
8913 fromname 
8914 \backslash
8915 hfill 
8916 \backslash
8917 ignorespaces 
8918 \backslash
8919 pagename
8920 \backslash
8921  
8922 \backslash
8923 thepage}}
8924 \end_layout
8925
8926 \end_inset
8927
8928  A detailed German description of such \SpecialChar LaTeX
8929  commands can be found in the Koma-Script
8930  documentation 
8931 \emph on
8932 scrguide
8933 \emph default
8934 .
8935  With it, the letter's author can produce his personal letter layout.
8936 \end_layout
8937
8938 \begin_layout Standard
8939 The types 
8940 \family sans
8941 Letter
8942 \family default
8943  and 
8944 \family sans
8945 Opening
8946 \family default
8947  define the beginning of the letter and must be used in every letter.
8948  To emphasize them in the \SpecialChar LyX
8949  document class, they are marked with the letter
8950  
8951 \shape italic
8952 L
8953 \shape default
8954  or 
8955 \shape italic
8956 O
8957 \shape default
8958 , resp.
8959 \begin_inset space ~
8960 \end_inset
8961
8962 in the left margin.
8963  It is possible to write any number of letters in one file.
8964  An 
8965 \family sans
8966 Opening
8967 \family default
8968  type produces a new letter using the same addressee and a 
8969 \family sans
8970 Letter
8971 \family default
8972  type produces a new addressee.
8973  The types 
8974 \family sans
8975 Closing
8976 \family default
8977
8978 \family sans
8979 PS
8980 \family default
8981
8982 \family sans
8983 CC
8984 \family default
8985 , and 
8986 \family sans
8987 Encl
8988 \family default
8989  are ordinary paragraph types and can also be used several times in one
8990  and the same letter.
8991 \end_layout
8992
8993 \begin_layout Itemize
8994
8995 \family sans
8996 Letter
8997 \family default
8998 : produces a paragraph for the addressee and implicitly defines the beginning
8999  of the letter.
9000 \end_layout
9001
9002 \begin_layout Itemize
9003
9004 \family sans
9005 Opening
9006 \family default
9007 : produces a paragraph for the form of address and implicitly produces a
9008  new letter.
9009 \end_layout
9010
9011 \begin_layout Itemize
9012
9013 \family sans
9014 Closing
9015 \family default
9016 : produces a paragraph for a close.
9017 \end_layout
9018
9019 \begin_layout Itemize
9020
9021 \family sans
9022 PS
9023 \family default
9024 : produces a paragraph for a postscript.
9025 \end_layout
9026
9027 \begin_layout Itemize
9028
9029 \family sans
9030 CC
9031 \family default
9032 : produces a paragraph for a distribution list.
9033 \end_layout
9034
9035 \begin_layout Itemize
9036
9037 \family sans
9038 Encl
9039 \family default
9040 : produces a paragraph for enclosures.
9041 \end_layout
9042
9043 \begin_layout Standard
9044 The types 
9045 \family sans
9046 Name
9047 \family default
9048
9049 \family sans
9050 Signature
9051 \family default
9052
9053 \family sans
9054 Address
9055 \family default
9056
9057 \family sans
9058 Telephone
9059 \family default
9060
9061 \family sans
9062 Place
9063 \family default
9064
9065 \family sans
9066 Backaddress
9067 \family default
9068
9069 \family sans
9070 Specialmail
9071 \family default
9072
9073 \family sans
9074 Location
9075 \family default
9076
9077 \family sans
9078 Title
9079 \family default
9080 , and 
9081 \family sans
9082 Subject
9083 \family default
9084  are input types provided with a label to enter information, which will
9085  be processed by the document class.
9086 \begin_inset Foot
9087 status open
9088
9089 \begin_layout Plain Layout
9090 It could be seen as a matter of inconsequence, that the types 
9091 \family sans
9092 Letter
9093 \family default
9094  and 
9095 \family sans
9096 Opening
9097 \family default
9098  described above are not such input types as well.
9099  Because of the special meaning of those types, however, I have implemented
9100  them as ordinary paragraph types with a one letter mark in the left margin.
9101  Moreover, it would affect my feeling of symmetry, if the 
9102 \family sans
9103 Opening
9104 \family default
9105  type and the 
9106 \family sans
9107 Closing
9108 \family default
9109  type had such a serious different appearance.
9110 \end_layout
9111
9112 \end_inset
9113
9114  The types must be used ahead of the corresponding 
9115 \family sans
9116 Opening
9117 \family default
9118  type.
9119 \end_layout
9120
9121 \begin_layout Standard
9122 An implementation of these types in a WYSIWYG fashion does not seem to make
9123  sense, because the real appearance of the produced letter does not only
9124  depend on the usage of the particular type, but also on other factors.
9125  For example, a signature entered in the 
9126 \family sans
9127 Signature
9128 \family default
9129  type will in the standard behavior appear in the produced letter only,
9130  when in the same letter also a 
9131 \family sans
9132 Closing
9133 \family default
9134  type is used.
9135  The entered value of the 
9136 \family sans
9137 Telephone
9138 \family default
9139  type will in the standard behavior not appear in the produced letter at
9140  all.
9141  The possibility to design the letter`s heading freely is already indicated
9142  in a footnote above.
9143 \end_layout
9144
9145 \begin_layout Standard
9146 The input types can also be used as empty paragraphs.
9147  This makes sense e.
9148 \begin_inset space \thinspace{}
9149 \end_inset
9150
9151 g.
9152 \begin_inset space \space{}
9153 \end_inset
9154
9155 for the 
9156 \family sans
9157 Signature
9158 \family default
9159  type.
9160  If the 
9161 \family sans
9162 Signature
9163 \family default
9164  type is not used at all, in the standard behavior the value of the 
9165 \family sans
9166 Name
9167 \family default
9168  type is used as signature, whereas if an empty 
9169 \family sans
9170 Signature
9171 \family default
9172  type is used, no signature value is defined.
9173 \end_layout
9174
9175 \begin_layout Standard
9176 By using the input types it is possible to write a letter template, containing
9177  filled input types with your personal dates (name, address, etc.) and empty
9178  input types for other dates you want to enter.
9179 \end_layout
9180
9181 \begin_layout Itemize
9182
9183 \family sans
9184 Name
9185 \family default
9186 : sender's name, in the standard behavior appears as a centered paragraph
9187  in small caps in the letter`s heading.
9188 \end_layout
9189
9190 \begin_layout Itemize
9191
9192 \family sans
9193 Signature
9194 \family default
9195 : sender's signature, in the standard behavior appears below the 
9196 \family sans
9197 Closing
9198 \family default
9199  type.
9200  If no 
9201 \family sans
9202 Signature
9203 \family default
9204  type is used, the value of the 
9205 \family sans
9206 Name
9207 \family default
9208  type appears instead.
9209 \end_layout
9210
9211 \begin_layout Itemize
9212
9213 \family sans
9214 Address
9215 \family default
9216 : sender's address, in the standard behavior appears in a centered paragraph
9217  in the letter`s heading below the sender's name.
9218 \end_layout
9219
9220 \begin_layout Itemize
9221
9222 \family sans
9223 Telephone
9224 \family default
9225 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
9226  variable
9227  
9228 \family typewriter
9229
9230 \backslash
9231 telephonenum
9232 \family default
9233 .
9234 \end_layout
9235
9236 \begin_layout Itemize
9237
9238 \family sans
9239 Place
9240 \family default
9241 : place of the letter`s making.
9242 \end_layout
9243
9244 \begin_layout Itemize
9245
9246 \family sans
9247 Date
9248 \family default
9249 : date of the letter`s making.
9250  
9251 \family sans
9252 Place
9253 \family default
9254  and 
9255 \family sans
9256 Date
9257 \family default
9258 , in the standard behavior, produce the place and the date in a right-aligned
9259  line below the addressee's field.
9260  If an empty 
9261 \family sans
9262 Date
9263 \family default
9264  type is used, neither place nor date appear, independent of the value of
9265  the 
9266 \family sans
9267 Place
9268 \family default
9269  type.
9270  If no 
9271 \family sans
9272 Date
9273 \family default
9274  type is used, the date of the letter `s production is used.
9275 \end_layout
9276
9277 \begin_layout Itemize
9278
9279 \family sans
9280 Backaddress
9281 \family default
9282 : sender`s back address, in the standard behavior appears above the addressee's
9283  field in a small sans serif font.
9284 \end_layout
9285
9286 \begin_layout Itemize
9287
9288 \family sans
9289 Specialmail
9290 \family default
9291 : special mail information, in the standard behavior appears underlined
9292  above the addressee's field below the back address.
9293 \end_layout
9294
9295 \begin_layout Itemize
9296
9297 \family sans
9298 Location
9299 \family default
9300 : additional information, in the standard behavior appears on right side
9301  below the addressee`s field.
9302 \end_layout
9303
9304 \begin_layout Itemize
9305
9306 \family sans
9307 Title
9308 \family default
9309 : the letter's title, in the standard behavior appears in a big, bold, sans
9310  serif font above the subject.
9311 \end_layout
9312
9313 \begin_layout Itemize
9314
9315 \family sans
9316 Subject
9317 \family default
9318 : the letter's subject, in the standard behavior appears in a bold font
9319  above the 
9320 \family sans
9321 Opening
9322 \family default
9323  paragraph.
9324 \end_layout
9325
9326 \begin_layout Standard
9327 The types 
9328 \family sans
9329 Yourref
9330 \family default
9331
9332 \family sans
9333 Yourmail
9334 \family default
9335
9336 \family sans
9337 Myref
9338 \family default
9339
9340 \family sans
9341 Customer
9342 \family default
9343 , and 
9344 \family sans
9345 Invoice
9346 \family default
9347  produce a business letter like line above the 
9348 \family sans
9349 Title
9350 \family default
9351  line containing the fields 
9352 \begin_inset Quotes eld
9353 \end_inset
9354
9355 Your ref.
9356 \begin_inset Quotes erd
9357 \end_inset
9358
9359
9360 \begin_inset Quotes eld
9361 \end_inset
9362
9363 Your letter of
9364 \begin_inset Quotes erd
9365 \end_inset
9366
9367
9368 \begin_inset Quotes eld
9369 \end_inset
9370
9371 Our ref.
9372 \begin_inset Quotes erd
9373 \end_inset
9374
9375
9376 \begin_inset Quotes eld
9377 \end_inset
9378
9379 Customer no.
9380 \begin_inset Quotes erd
9381 \end_inset
9382
9383
9384 \begin_inset Quotes eld
9385 \end_inset
9386
9387 Invoice no.
9388 \begin_inset Quotes erd
9389 \end_inset
9390
9391 , and 
9392 \begin_inset Quotes eld
9393 \end_inset
9394
9395 Date
9396 \begin_inset Quotes erd
9397 \end_inset
9398
9399 .
9400  For the date field, the value of the 
9401 \family sans
9402 Date
9403 \family default
9404  type is used.
9405  If one of these 
9406 \begin_inset Quotes eld
9407 \end_inset
9408
9409 business letter types
9410 \begin_inset Quotes erd
9411 \end_inset
9412
9413  is used, the value of the 
9414 \family sans
9415 Place
9416 \family default
9417  type however does not appear, but only the \SpecialChar LaTeX
9418  variable 
9419 \family typewriter
9420
9421 \backslash
9422 fromplace
9423 \family default
9424  is set.
9425  The ordinary output of place and date in a right-aligned line below the
9426  addressee`s field is suppressed.
9427  The types are implemented as input types provided with a label and must
9428  be used ahead of the corresponding 
9429 \family sans
9430 Opening
9431 \family default
9432  type.
9433 \end_layout
9434
9435 \begin_layout Itemize
9436
9437 \family sans
9438 Yourref
9439 \family default
9440 : Your ref.
9441 \end_layout
9442
9443 \begin_layout Itemize
9444
9445 \family sans
9446 Yourmail
9447 \family default
9448 : Your letter of.
9449 \end_layout
9450
9451 \begin_layout Itemize
9452
9453 \family sans
9454 Myref
9455 \family default
9456 : Our ref.
9457 \end_layout
9458
9459 \begin_layout Itemize
9460
9461 \family sans
9462 Customer
9463 \family default
9464 : Customer no.
9465 \end_layout
9466
9467 \begin_layout Itemize
9468
9469 \family sans
9470 Invoice
9471 \family default
9472 : Invoice no.
9473 \end_layout
9474
9475 \begin_layout Subsection
9476 The new letter class: letter (koma-script v.2)
9477 \end_layout
9478
9479 \begin_layout Standard
9480 by 
9481 \noun on
9482 Jürgen Spitzmüller
9483 \end_layout
9484
9485 \begin_layout Standard
9486 \begin_inset VSpace medskip
9487 \end_inset
9488
9489
9490 \end_layout
9491
9492 \begin_layout Standard
9493 \noindent
9494 Koma-Script version 2.8 has introduced a new letter class 
9495 \family typewriter
9496 scrlttr2
9497 \family default
9498  which supersedes the now unsupported 
9499 \family typewriter
9500 scrlettr
9501 \family default
9502 .
9503  It has — on the \SpecialChar LaTeX
9504  side — a completely new interface and is not compatible
9505  with the old class.
9506  Therefore, \SpecialChar LyX
9507  supports both, though it is recommended you use the new class.
9508 \end_layout
9509
9510 \begin_layout Standard
9511 This class covers the same functionality as 
9512 \emph on
9513 letter (koma-script),
9514 \emph default
9515  and a few more.
9516  The basic items are 
9517 \family sans
9518 Address
9519 \family default
9520  (receiver's address, same as 
9521 \family sans
9522 Letter
9523 \family default
9524  in the old layout), 
9525 \family sans
9526 Opening
9527 \family default
9528 , and 
9529 \family sans
9530 Closing
9531 \family default
9532 .
9533  
9534 \family sans
9535 NextAddress
9536 \family default
9537  will start a new letter (i.
9538 \begin_inset space \thinspace{}
9539 \end_inset
9540
9541 e.
9542 \begin_inset space \space{}
9543 \end_inset
9544
9545 you can write several letters per document).
9546  New elements are sender's 
9547 \family sans
9548 E-Mail
9549 \family default
9550
9551 \family sans
9552 URL
9553 \family default
9554
9555 \family sans
9556 Fax
9557 \family default
9558
9559 \family sans
9560 Bank
9561 \family default
9562  and the possibility to use a 
9563 \family sans
9564 Logo
9565 \family default
9566  (via 
9567 \family sans
9568 Insert\SpecialChar menuseparator
9569 Graphics
9570 \family default
9571 ) in the header.
9572 \end_layout
9573
9574 \begin_layout Standard
9575 The biggest improvement is, though, that the letter's layout is configurable
9576  to meet almost any needs.
9577  This can be done via the preamble or with a special style file (Letter
9578  Class Option, extension 
9579 \family typewriter
9580 *.lco
9581 \family default
9582 ), that will be read in as a class option.
9583 \begin_inset Foot
9584 status collapsed
9585
9586 \begin_layout Plain Layout
9587 The KOMA package comes with some default 
9588 \family typewriter
9589 *.lco
9590 \family default
9591  files.
9592  There is, for instance, a 
9593 \family typewriter
9594 DIN.lco
9595 \family default
9596  file that follows german typesetting rules, or a 
9597 \family typewriter
9598 KOMAold.lco
9599 \family default
9600  that provides the default layout of the old 
9601 \family typewriter
9602 scrlettr
9603 \family default
9604  class.
9605  The latter can be loaded with the class option 
9606 \family typewriter
9607 KOMAold
9608 \family default
9609 , inserted via the 
9610 \family sans
9611 Layout\SpecialChar menuseparator
9612 Document\SpecialChar menuseparator
9613 Extra Options
9614 \family default
9615  field.
9616 \end_layout
9617
9618 \end_inset
9619
9620  Have a look at the 
9621 \emph on
9622 koma-letter2
9623 \emph default
9624  template that is included in \SpecialChar LyX
9625  for examples.
9626  A detailed description is to be found in the Koma-Script documentation
9627  (
9628 \emph on
9629 scrguide
9630 \emph default
9631 ).
9632 \end_layout
9633
9634 \begin_layout Subsection
9635 Problems
9636 \end_layout
9637
9638 \begin_layout Standard
9639 Visualizing the Koma-Script document classes in \SpecialChar LyX
9640 , the \SpecialChar LyX
9641  internals cause some
9642  problems.
9643 \end_layout
9644
9645 \begin_layout Itemize
9646 The chapter number of a 
9647 \family sans
9648 Chapter
9649 \family default
9650  type appears on a line of its own above the chapter heading instead of
9651  appearing in the same line ahead of it.
9652  The cause for that is the \SpecialChar LyX
9653  internal behavior for the labeltype 
9654 \family sans
9655 Counter_Chapter
9656 \family default
9657  in the layout file.
9658 \end_layout
9659
9660 \begin_layout Itemize
9661 The headings of the types 
9662 \family sans
9663 Addchap
9664 \family default
9665  and 
9666 \family sans
9667 Addsec
9668 \family default
9669  are only put in the 
9670 \begin_inset Quotes eld
9671 \end_inset
9672
9673 true
9674 \begin_inset Quotes erd
9675 \end_inset
9676
9677  \SpecialChar LaTeX
9678  table of contents, but not in the \SpecialChar LyX
9679  table of contents (
9680 \family sans
9681 Document\SpecialChar menuseparator
9682 Table
9683 \begin_inset space ~
9684 \end_inset
9685
9686 of
9687 \begin_inset space ~
9688 \end_inset
9689
9690 Contents
9691 \family default
9692 ).
9693 \end_layout
9694
9695 \begin_layout Itemize
9696 The paragraphs in a 
9697 \emph on
9698 letter
9699 \emph default
9700  document class appear in a skip separation mode, not indented.
9701  This is the standard behavior, no special \SpecialChar LaTeX
9702  commands are needed for that.
9703  But in the 
9704 \family sans
9705 Document\SpecialChar menuseparator
9706 Settings
9707 \family default
9708  dialog the corresponding radio button indicates 
9709 \family sans
9710 Indent
9711 \family default
9712 .
9713  A 
9714 \family sans
9715 Skip
9716 \family default
9717  value always has the effect that extra \SpecialChar LaTeX
9718  commands are inserted in the document
9719  to produce the gap, which is not what is wanted in this case.
9720 \end_layout
9721
9722 \begin_layout Section
9723 Memoir
9724 \end_layout
9725
9726 \begin_layout Standard
9727 By 
9728 \noun on
9729 Jürgen Spitzmüller
9730 \end_layout
9731
9732 \begin_layout Subsection
9733 Overview
9734 \end_layout
9735
9736 \begin_layout Standard
9737 Memoir is a very powerful and constantly evolving class.
9738  It has been designed with regard to fictional and non-fictional literature.
9739  Its aim is to let the user have maximum control over the typesetting of
9740  his document.
9741  Memoir is based on the standard book class, but it can also emulate the
9742  article class (see below).
9743 \end_layout
9744
9745 \begin_layout Standard
9746 Peter Wilson, the developer of Memoir, is known as the author of lots of
9747  useful packages in the \SpecialChar LaTeX
9748  world.
9749  Most of them have been merged with Memoir.
9750  Therefore, it is much easier to layout the table of contents, appendices,
9751  chapter designs and such.
9752  \SpecialChar LyX
9753 , though, does not support all of these goodies natively.
9754  Some of them might be added to forthcoming releases
9755 \begin_inset Foot
9756 status collapsed
9757
9758 \begin_layout Plain Layout
9759 You are invited to send suggestions to 
9760 \begin_inset Flex URL
9761 status collapsed
9762
9763 \begin_layout Plain Layout
9764
9765 lyx-devel@lists.lyx.org
9766 \end_layout
9767
9768 \end_inset
9769
9770 .
9771 \end_layout
9772
9773 \end_inset
9774
9775 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
9776 's framework.
9777  Of course you can still use all features with the help of some native \SpecialChar LaTeX
9778
9779  commands (\SpecialChar TeX
9780  code
9781 \begin_inset Foot
9782 status collapsed
9783
9784 \begin_layout Plain Layout
9785 Cf.
9786 \begin_inset ERT
9787 status collapsed
9788
9789 \begin_layout Plain Layout
9790
9791
9792 \backslash
9793  
9794 \end_layout
9795
9796 \end_inset
9797
9798 section
9799 \begin_inset space ~
9800 \end_inset
9801
9802
9803 \begin_inset CommandInset ref
9804 LatexCommand ref
9805 reference "sec:Inserting-TeX-Code"
9806
9807 \end_inset
9808
9809  for details.
9810 \end_layout
9811
9812 \end_inset
9813
9814 ).
9815  In this section, we can only list those features that are natively supported
9816  by \SpecialChar LyX
9817 .
9818  For detailed descriptions (and for the rest of features) we recommend you
9819  have a look at the detailed manual of the Memoir class
9820 \begin_inset Foot
9821 status collapsed
9822
9823 \begin_layout Plain Layout
9824 Cf.
9825 \begin_inset ERT
9826 status collapsed
9827
9828 \begin_layout Plain Layout
9829
9830
9831 \backslash
9832  
9833 \end_layout
9834
9835 \end_inset
9836
9837
9838 \begin_inset Flex URL
9839 status collapsed
9840
9841 \begin_layout Plain Layout
9842
9843 CTAN:/macros/latex/memoir/memman.pdf
9844 \end_layout
9845
9846 \end_inset
9847
9848 .
9849 \end_layout
9850
9851 \end_inset
9852
9853 , which is not only a user guide for the class, but also both a comprehensive
9854  description on good typesetting and a superb example for good typesetting
9855  itself.
9856 \end_layout
9857
9858 \begin_layout Subsection
9859 Basic features and restrictions
9860 \end_layout
9861
9862 \begin_layout Standard
9863 Memoir supports basically all features of the standard book classes.
9864  There are, however, some differences, as follows:
9865 \end_layout
9866
9867 \begin_layout Description
9868 Font
9869 \begin_inset space ~
9870 \end_inset
9871
9872 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
9873 \end_layout
9874
9875 \begin_layout Description
9876 Page
9877 \begin_inset space ~
9878 \end_inset
9879
9880 style: The fancy page style is not supported, due to a command clash between
9881  Memoir and the fancyhdr package (they both define a command with the same
9882  name, which confuses \SpecialChar LaTeX
9883 ).
9884  Instead, Memoir comes with a number of its own page styles (see 
9885 \family sans
9886 Layout\SpecialChar menuseparator
9887 Document\SpecialChar menuseparator
9888 Page
9889 \begin_inset space ~
9890 \end_inset
9891
9892 Style
9893 \family default
9894 ).
9895  If you want to use these for the chapter pages, you have to use the command
9896  
9897 \family typewriter
9898
9899 \backslash
9900 chapterstyle
9901 \family default
9902  in the main text or in preamble (e.
9903 \begin_inset space \thinspace{}
9904 \end_inset
9905
9906 g.
9907 \begin_inset space \space{}
9908 \end_inset
9909
9910
9911 \family typewriter
9912
9913 \backslash
9914 chapterstyle{companion}
9915 \family default
9916 ).
9917 \end_layout
9918
9919 \begin_layout Description
9920 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
9921  optional argument in the standard classes.
9922  With this, you can specify an alternative version of the title for the
9923  table of contents and the headers (for instance, if the title is too long).
9924  In \SpecialChar LyX
9925 , you can do this via 
9926 \family sans
9927 Insert\SpecialChar menuseparator
9928 Short
9929 \begin_inset space ~
9930 \end_inset
9931
9932 Title
9933 \family default
9934  at the beginning of a chapter/section.
9935  Memoir features a second optional argument and thus separates the table
9936  of contents from the header.
9937  You can define three variants of a title with this: one for the main text,
9938  one for the table of contents, and one for the headers.
9939  Simply insert two optional arguments if you need this feature, the first
9940  one containing the short title for the Table of Contents, the second one
9941  containing an alternative short title for the headers.
9942 \end_layout
9943
9944 \begin_layout Description
9945 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
9946  of contents, the list of figures and the list of table start a new page
9947  automatically.
9948  Memoir does not follow this route.
9949  You have to insert a page break yourself, if you want to have one.
9950 \end_layout
9951
9952 \begin_layout Description
9953 Titlepage: For some unknown reason, Memoir uses pagination on the title
9954  page (in the standard classes, title pages are 
9955 \begin_inset Quotes eld
9956 \end_inset
9957
9958 empty
9959 \begin_inset Quotes erd
9960 \end_inset
9961
9962 ).
9963  If you want an empty title page, type 
9964 \family typewriter
9965
9966 \backslash
9967 aliaspagestyle{title}{empty}
9968 \family default
9969  in the preamble.
9970 \end_layout
9971
9972 \begin_layout Description
9973 Article: With the class option 
9974 \emph on
9975 article
9976 \emph default
9977  (to be inserted in 
9978 \family sans
9979 Layout\SpecialChar menuseparator
9980 Document\SpecialChar menuseparator
9981 Extra
9982 \begin_inset space ~
9983 \end_inset
9984
9985 Options
9986 \family default
9987 ), you can emulate article style.
9988  That is, counters (footnotes, figures, tables etc.) will not be reset on
9989  new chapters, chapters don't start a new page (but are—in contrary to 
9990 \begin_inset Quotes eld
9991 \end_inset
9992
9993 real
9994 \begin_inset Quotes erd
9995 \end_inset
9996
9997  article classes—still allowed), parts, though, use their own page, as in
9998  book.
9999 \end_layout
10000
10001 \begin_layout Description
10002 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
10003  font commands, which have been used in the old \SpecialChar LaTeX
10004  version 2.09 (e.
10005 \begin_inset space \thinspace{}
10006 \end_inset
10007
10008 g.
10009 \begin_inset space \space{}
10010 \end_inset
10011
10012
10013 \family typewriter
10014
10015 \backslash
10016 rm
10017 \family default
10018
10019 \family typewriter
10020
10021 \backslash
10022 it
10023 \family default
10024 ).
10025  It produces an error and stops \SpecialChar LaTeX
10026  whenever such a command appears.
10027  The class option 
10028 \emph on
10029 oldfontcommands
10030 \emph default
10031  reallows the commands and spits out warnings instead (which does at least
10032  not stop \SpecialChar LaTeX
10033 ).
10034  Since a lot of packages and particularly Bib\SpecialChar TeX
10035  style files are still using
10036  those commands, we have decided to use this option by default.
10037 \end_layout
10038
10039 \begin_layout Subsection
10040 Extra features
10041 \end_layout
10042
10043 \begin_layout Standard
10044 We will only describe the features supported by \SpecialChar LyX
10045  (which is not much currently).
10046  Please consult the Memoir manual
10047 \begin_inset Foot
10048 status collapsed
10049
10050 \begin_layout Plain Layout
10051 Cf.
10052 \begin_inset ERT
10053 status collapsed
10054
10055 \begin_layout Plain Layout
10056
10057
10058 \backslash
10059  
10060 \end_layout
10061
10062 \end_inset
10063
10064
10065 \begin_inset Flex URL
10066 status collapsed
10067
10068 \begin_layout Plain Layout
10069
10070 CTAN:/macros/latex/memoir/memman.pdf
10071 \end_layout
10072
10073 \end_inset
10074
10075 .
10076 \end_layout
10077
10078 \end_inset
10079
10080  for details.
10081 \end_layout
10082
10083 \begin_layout Description
10084 Abstract: You may wonder why an abstract is an extra feature.
10085  Well, it is in book class.
10086  Usually books don't have abstracts.
10087  Memoir, however, has.
10088  You can use it wherever and how often you like.
10089 \end_layout
10090
10091 \begin_layout Description
10092 Chapterprecis: You may know this older typesetting style: The contents of
10093  a chapter are summarized below the title and also in the table of contents
10094  (e.
10095 \begin_inset space \thinspace{}
10096 \end_inset
10097
10098 g.
10099 \begin_inset space \space{}
10100 \end_inset
10101
10102
10103 \emph on
10104 Our hero arrives in Troia; he loses some friends; he finds others
10105 \emph default
10106 ).
10107  Chapterprecis does exactly this.
10108  It is therefore only sensible below a chapter.
10109 \end_layout
10110
10111 \begin_layout Description
10112 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
10113  The epigraph environment provides an elegant way of typesetting such a
10114  motto.
10115  The motto itself (text) and its author (source) are divided by a short
10116  line.
10117  Unfortunately, we have to fool \SpecialChar LyX
10118  a bit here again, since the environment
10119  needs two arguments (text and source).
10120  In this case, we have to use curly brackets (in \SpecialChar TeX
10121  mode) between the two
10122  arguments: 
10123 \emph on
10124 <smart slogan>
10125 \emph default
10126  
10127 \family typewriter
10128 }{
10129 \family default
10130  
10131 \emph on
10132 <author of the slogan>.
10133 \end_layout
10134
10135 \begin_layout Description
10136 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
10137  complex figurative poems).
10138  \SpecialChar LyX
10139  can only support a few of them.
10140  One is poemtitle, which is a centered title for poems, which will also
10141  be added to the table of contents (verse is the standard environment for
10142  poems.
10143  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
10144  code,
10145  because they have to be nested inside regular verse environments, which
10146  is not possible with \SpecialChar LyX
10147 ).
10148 \end_layout
10149
10150 \begin_layout Description
10151 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
10152 \end_layout
10153
10154 \begin_layout Section
10155 Article (mwart), book (mwbk) and report (mwrep)
10156 \begin_inset Argument status
10157 status collapsed
10158
10159 \begin_layout Plain Layout
10160 The 
10161 \family typewriter
10162 mw
10163 \family default
10164  Classes
10165 \end_layout
10166
10167 \end_inset
10168
10169
10170 \end_layout
10171
10172 \begin_layout Standard
10173 by 
10174 \noun on
10175 Tomasz Luczak
10176 \end_layout
10177
10178 \begin_layout Standard
10179 The \SpecialChar LyX
10180  document classes 
10181 \emph on
10182 article (mwart)
10183 \emph default
10184
10185 \emph on
10186 report (mwrep)
10187 \emph default
10188  and 
10189 \emph on
10190 book
10191 \emph default
10192  
10193 \emph on
10194 (mwbk)
10195 \emph default
10196  correspond to the \SpecialChar LaTeX
10197  document classes 
10198 \family typewriter
10199 mwart.cls
10200 \family default
10201
10202 \family typewriter
10203 mwrep.cls
10204 \family default
10205  and 
10206 \family typewriter
10207 mwbk.cls
10208 \family default
10209 , resp.
10210  They are replacements for the standard document classes 
10211 \family typewriter
10212 article.cls
10213 \family default
10214
10215 \family typewriter
10216 report.cls
10217 \family default
10218  and 
10219 \family typewriter
10220 book.cls
10221 \family default
10222 , resp., and fit better to Polish typography conventions in a number of points.
10223  
10224 \end_layout
10225
10226 \begin_layout Standard
10227 Basic differences:
10228 \end_layout
10229
10230 \begin_layout Itemize
10231 Unnumbered titles (with star, e.
10232 \begin_inset space \thinspace{}
10233 \end_inset
10234
10235 g.
10236 \begin_inset space \space{}
10237 \end_inset
10238
10239
10240 \family sans
10241 Section*
10242 \family default
10243 ) are added into table of contents,
10244 \end_layout
10245
10246 \begin_layout Itemize
10247 Additional page styles:
10248 \end_layout
10249
10250 \begin_deeper
10251 \begin_layout Description
10252 uheadings header with separated lines,
10253 \end_layout
10254
10255 \begin_layout Description
10256 myheadings custom header, contents headers via commands: 
10257 \family typewriter
10258
10259 \backslash
10260 markright
10261 \family default
10262  and 
10263 \family typewriter
10264
10265 \backslash
10266 markboth
10267 \family default
10268 ,
10269 \end_layout
10270
10271 \begin_layout Description
10272 myuheadings custom header with separated lines,
10273 \end_layout
10274
10275 \begin_layout Description
10276 outer page number is placed on outer side of page
10277 \end_layout
10278
10279 \end_deeper
10280 \begin_layout Itemize
10281 Options 
10282 \end_layout
10283
10284 \begin_deeper
10285 \begin_layout Description
10286 rmheadings serif titles — default,
10287 \end_layout
10288
10289 \begin_layout Description
10290 sfheadings sansserif titles,
10291 \end_layout
10292
10293 \begin_layout Description
10294 authortitle on title page first placed is author next title — default,
10295 \end_layout
10296
10297 \begin_layout Description
10298 titleauthor on title page first placed is title next author,
10299 \end_layout
10300
10301 \begin_layout Description
10302 withmarginpar reserve place on page for margins.
10303 \end_layout
10304
10305 \end_deeper
10306 \begin_layout Section
10307 Paper
10308 \end_layout
10309
10310 \begin_layout Standard
10311 The document class 
10312 \family sans
10313 paper
10314 \family default
10315  provides an alternative to the standard 
10316 \family sans
10317 article
10318 \family default
10319  class.
10320  It provides similar functionality, but you might prefer this layout with
10321  sans serif sections, headings, and more.
10322 \end_layout
10323
10324 \begin_layout Section
10325 Rev\SpecialChar TeX
10326 4
10327 \end_layout
10328
10329 \begin_layout Standard
10330 by 
10331 \noun on
10332 Amir Karger
10333 \end_layout
10334
10335 \begin_layout Standard
10336 \begin_inset VSpace bigskip
10337 \end_inset
10338
10339
10340 \end_layout
10341
10342 \begin_layout Standard
10343 \noindent
10344 The 
10345 \family sans
10346 Revtex
10347 \begin_inset space ~
10348 \end_inset
10349
10350 4
10351 \family default
10352  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
10353  4.0 (the 
10354 \begin_inset Formula $\beta$
10355 \end_inset
10356
10357  release of May, 1999) class.
10358 \end_layout
10359
10360 \begin_layout Standard
10361 \SpecialChar LyX
10362  has a 
10363 \family sans
10364 Revtex
10365 \family default
10366  textclass, which works with Rev\SpecialChar TeX
10367  3.1.
10368  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
10369  2.09.
10370  That means that it doesn't interact very well with \SpecialChar LyX
10371 , which requires \SpecialChar LaTeX2e
10372 , although
10373  it has been kludged to work.
10374  Since Rev\SpecialChar TeX
10375  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
10376 , \SpecialChar LyX
10377  with the
10378  
10379 \family sans
10380 Rev\SpecialChar TeX
10381
10382 \begin_inset space ~
10383 \end_inset
10384
10385 4
10386 \family default
10387  textclass should also be pretty easy to use.
10388 \end_layout
10389
10390 \begin_layout Standard
10391 These documents are supposed to be used in 
10392 \emph on
10393 addition
10394 \emph default
10395  to the Rev\SpecialChar TeX
10396  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
10397  macros,
10398  and assume you'll know what to put in the preamble if necessary.
10399 \end_layout
10400
10401 \begin_layout Subsection
10402 Installation
10403 \end_layout
10404
10405 \begin_layout Standard
10406 All you need to do is install Rev\SpecialChar TeX
10407  4, as described in the package's README
10408  file.
10409  The package can be found at The Rev\SpecialChar TeX
10410  4 Web Site 
10411 \begin_inset Flex URL
10412 status collapsed
10413
10414 \begin_layout Plain Layout
10415
10416 http://publish.aps.org/revtex4/
10417 \end_layout
10418
10419 \end_inset
10420
10421 .
10422  Install it somewhere that \SpecialChar LaTeX
10423  can see it.
10424  Test it by trying to \SpecialChar LaTeX
10425  a short Rev\SpecialChar TeX
10426  4 document in some random directory (i.
10427 \begin_inset space \thinspace{}
10428 \end_inset
10429
10430 e.
10431 \begin_inset space \space{}
10432 \end_inset
10433
10434 not the directory where you installed the class file.) Then, if you reconfigure
10435  \SpecialChar LyX
10436 , it will find the class file and let you use the Rev\SpecialChar TeX
10437 4 textclass.
10438 \end_layout
10439
10440 \begin_layout Standard
10441 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
10442  4 document
10443  using 
10444 \family typewriter
10445 tex2lyx
10446 \family default
10447 , or to use the 
10448 \family sans
10449 Revtex
10450 \begin_inset space ~
10451 \end_inset
10452
10453 4
10454 \family default
10455  template, found in the templates directory.
10456 \end_layout
10457
10458 \begin_layout Subsection
10459 Preamble Matter
10460 \end_layout
10461
10462 \begin_layout Standard
10463 Optional arguments to 
10464 \family typewriter
10465
10466 \backslash
10467 documentclass
10468 \family default
10469 , like 
10470 \begin_inset Quotes eld
10471 \end_inset
10472
10473 preprint
10474 \begin_inset Quotes erd
10475 \end_inset
10476
10477  and 
10478 \begin_inset Quotes eld
10479 \end_inset
10480
10481 aps
10482 \begin_inset Quotes erd
10483 \end_inset
10484
10485 , go in the 
10486 \family sans
10487 Extra
10488 \begin_inset space ~
10489 \end_inset
10490
10491 Options
10492 \family default
10493  field in the 
10494 \family sans
10495 Document
10496 \begin_inset space ~
10497 \end_inset
10498
10499 Layout
10500 \family default
10501  dialog, as usual.
10502  Remember that in Rev\SpecialChar TeX
10503 , at least one optional argument is required! 
10504 \end_layout
10505
10506 \begin_layout Standard
10507 Other preamble matter, like 
10508 \family typewriter
10509
10510 \backslash
10511 draft
10512 \family default
10513  etc.
10514 \begin_inset space ~
10515 \end_inset
10516
10517 goes in the 
10518 \family sans
10519 \SpecialChar LaTeX
10520
10521 \begin_inset space ~
10522 \end_inset
10523
10524 Preamble
10525 \family default
10526  dialog, also as usual.
10527 \end_layout
10528
10529 \begin_layout Subsection
10530 Layouts
10531 \end_layout
10532
10533 \begin_layout Standard
10534 The layouts basically correspond to the commands in Rev\SpecialChar TeX
10535 4.0.
10536  For example, the Email layout corresponds to 
10537 \family typewriter
10538
10539 \backslash
10540 email{}
10541 \family default
10542 .
10543  Note that (at least as of Rev\SpecialChar TeX
10544  4.0 Beta), the 
10545 \family sans
10546 Address
10547 \family default
10548  and 
10549 \family sans
10550 Affiliation
10551 \family default
10552  layouts are exactly equivalent, so you shouldn't need to use both.
10553 \begin_inset Foot
10554 status collapsed
10555
10556 \begin_layout Plain Layout
10557 In case you're curious, both were included so that 
10558 \family typewriter
10559 tex2lyx
10560 \family default
10561  would be able to translate both 
10562 \family typewriter
10563
10564 \backslash
10565 address
10566 \family default
10567  and 
10568 \family typewriter
10569
10570 \backslash
10571 affiliation
10572 \family default
10573 .
10574 \end_layout
10575
10576 \end_inset
10577
10578
10579 \end_layout
10580
10581 \begin_layout Subsection
10582 Important Notes
10583 \end_layout
10584
10585 \begin_layout Standard
10586 There are a couple of important unique aspects of Rev\SpecialChar TeX
10587  4 which might cause
10588  bugs that will be even more confusing in \SpecialChar LyX
10589 .
10590 \end_layout
10591
10592 \begin_layout Standard
10593 In Rev\SpecialChar TeX
10594 , the 
10595 \family typewriter
10596
10597 \backslash
10598 thanks
10599 \family default
10600  command goes 
10601 \emph on
10602 outside
10603 \emph default
10604  the 
10605 \family typewriter
10606
10607 \backslash
10608 author
10609 \family default
10610  command.
10611  The \SpecialChar LyX
10612  equivalent is that there is a separate Thanks layout.
10613  Do 
10614 \emph on
10615 not
10616 \emph default
10617  write footnotes in the 
10618 \family sans
10619 Author
10620 \family default
10621  layout, or weird things may happen.
10622  See the Rev\SpecialChar TeX
10623  4 documentation for more details.
10624 \end_layout
10625
10626 \begin_layout Standard
10627 Also, the 
10628 \family sans
10629 Author
10630 \begin_inset space ~
10631 \end_inset
10632
10633 Email
10634 \family default
10635
10636 \family sans
10637 Author
10638 \begin_inset space ~
10639 \end_inset
10640
10641 URL
10642 \family default
10643 , and 
10644 \family sans
10645 Thanks
10646 \family default
10647  layouts must be placed 
10648 \emph on
10649 in between
10650 \emph default
10651  the 
10652 \family sans
10653 Author
10654 \family default
10655  layout and the corresponding 
10656 \family sans
10657 Address
10658 \family default
10659  (or equivalent 
10660 \family sans
10661 Affiliation
10662 \family default
10663 ) layout.
10664  If you put the 
10665 \family sans
10666 Thanks
10667 \family default
10668  after the 
10669 \family sans
10670 Address
10671 \family default
10672 , the \SpecialChar LaTeX
10673  won't compile.
10674 \end_layout
10675
10676 \begin_layout Subsection
10677 Drawbacks
10678 \end_layout
10679
10680 \begin_layout Standard
10681 The main problem with this layout is that you can't use the optional arguments
10682  to layouts like Email and Title.
10683  (The problem is not unique to this layout; you can't use optional arguments
10684  to the Section layouts either.) This means that after you export that file
10685  to \SpecialChar LaTeX
10686  (which you'll need to do eventually to send it in to APS), you'll need
10687  to edit the \SpecialChar LaTeX
10688  file with a text editor to add the optional arguments to set,
10689  e.
10690 \begin_inset space \thinspace{}
10691 \end_inset
10692
10693 g.
10694 \begin_inset space \space{}
10695 \end_inset
10696
10697 the running title for the page headers.
10698  Lacking these layouts makes the 
10699 \family typewriter
10700
10701 \backslash
10702 altaffiliation
10703 \family default
10704  (and the equivalent 
10705 \family typewriter
10706
10707 \backslash
10708 altaddress
10709 \family default
10710 ) useless, so the corresponding layouts don't exist, and will have to be
10711  added by hand.
10712 \begin_inset Foot
10713 status collapsed
10714
10715 \begin_layout Plain Layout
10716
10717 \emph on
10718 Note from JMarc:
10719 \emph default
10720  actually, \SpecialChar LyX
10721  1.3.0 supports some forms of optional arguments, but this layout
10722  has not been updated yet to take advantage of it.
10723 \end_layout
10724
10725 \end_inset
10726
10727  
10728 \end_layout
10729
10730 \begin_layout Section
10731 Springer Journals (
10732 \family sans
10733 svjour
10734 \family default
10735 )
10736 \end_layout
10737
10738 \begin_layout Standard
10739 by 
10740 \noun on
10741 Martin Vermeer
10742 \end_layout
10743
10744 \begin_layout Subsection
10745 Description
10746 \end_layout
10747
10748 \begin_layout Standard
10749 These are the layout files for some of the journal formats used by Springer
10750  Verlag and listed on 
10751 \begin_inset Flex URL
10752 status collapsed
10753
10754 \begin_layout Plain Layout
10755
10756 http://www.springer.de/author/tex/help-journals.html
10757 \end_layout
10758
10759 \end_inset
10760
10761 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
10762  now!).
10763  It is a modular system: the things common to all journals are implemented
10764  in 
10765 \family typewriter
10766 svjour.inc
10767 \family default
10768 , which journal-specific layout files (such as, e.
10769 \begin_inset space \thinspace{}
10770 \end_inset
10771
10772 g.
10773 \begin_inset space \space{}
10774 \end_inset
10775
10776
10777 \family typewriter
10778 svjog.layout
10779 \family default
10780  for Journal of Geodesy) can include.
10781 \end_layout
10782
10783 \begin_layout Standard
10784 This means that implementing support for any other Springer journal on this
10785  list is as simple as writing your own 
10786 \family typewriter
10787 sv
10788 \family default
10789 <myjournal>
10790 \family typewriter
10791 .layout
10792 \family default
10793  file following the outline given in 
10794 \family typewriter
10795 svjog.layout
10796 \family default
10797 .
10798  
10799 \end_layout
10800
10801 \begin_layout Standard
10802 It is reasonably well tested only for the Journal of Geodesy.
10803  
10804 \family typewriter
10805 svjour
10806 \family default
10807  and 
10808 \family typewriter
10809 svjog
10810 \family default
10811  come with the standard \SpecialChar LyX
10812  distribution.
10813  Install the relevant class file (downloaded from Springer) in a proper
10814  directory, reconfigure \SpecialChar LaTeX
10815  (in the te\SpecialChar TeX
10816  case by running 
10817 \family typewriter
10818 texhash
10819 \family default
10820 , as root if necessary — doesn't \SpecialChar LyX
10821  take care of this?), reconfigure \SpecialChar LyX
10822  and
10823  it should work.
10824 \end_layout
10825
10826 \begin_layout Subsection
10827 New styles
10828 \end_layout
10829
10830 \begin_layout Standard
10831 A large number of theorem-like styles — 
10832 \family sans
10833 Claim, Conjecture,
10834 \family default
10835  
10836 \family sans
10837 \SpecialChar ldots
10838 Theorem
10839 \family default
10840 .
10841 \end_layout
10842
10843 \begin_layout Standard
10844
10845 \family sans
10846 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
10847 _Title, Author_Running, Institute,
10848  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
10849 \family default
10850 .
10851  See the Springer class file documentation for details.
10852 \end_layout
10853
10854 \begin_layout Subsection
10855 Supported journals
10856 \end_layout
10857
10858 \begin_layout Itemize
10859
10860 \emph on
10861 Journal of Geodesy
10862 \emph default
10863
10864 \family typewriter
10865 svjog.layout
10866 \family default
10867  — Martin Vermeer
10868 \end_layout
10869
10870 \begin_layout Itemize
10871
10872 \emph on
10873 Probability Theory and Related Fields
10874 \emph default
10875
10876 \family typewriter
10877 svprobth.layout
10878 \family default
10879  — Jean-Marc Lasgouttes
10880 \end_layout
10881
10882 \begin_layout Standard
10883 Add your own, it isn't so hard!
10884 \end_layout
10885
10886 \begin_layout Subsection
10887 Credits
10888 \end_layout
10889
10890 \begin_layout Standard
10891 These files are partly based on the older 
10892 \family typewriter
10893 ejour2.layout
10894 \family default
10895 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
10896  2.09 style
10897  file from Springer.
10898  All this, and the 
10899 \family typewriter
10900 ejour2
10901 \family default
10902  layout, are now defunct.
10903  Jean-Marc Lasgouttes helped out big in making me find my way around the
10904  \SpecialChar LyX
10905  layout file mechanism.
10906 \end_layout
10907
10908 \begin_layout Subsection
10909 Bugs
10910 \end_layout
10911
10912 \begin_layout Standard
10913 Probably.
10914  But probably less than in the old hacked-\SpecialChar LaTeX
10915  
10916 \family typewriter
10917 ejour2
10918 \family default
10919 .
10920 \end_layout
10921
10922 \begin_layout Standard
10923 Limitations e.
10924 \begin_inset space \thinspace{}
10925 \end_inset
10926
10927 g.: does not display the number for theorem-like layouts, just #.
10928 \end_layout
10929
10930 \begin_layout Section
10931 Slides [aka 
10932 \noun on
10933 Sli\SpecialChar TeX
10934
10935 \noun default
10936 ]
10937 \begin_inset CommandInset label
10938 LatexCommand label
10939 name "sec:slitex"
10940
10941 \end_inset
10942
10943
10944 \end_layout
10945
10946 \begin_layout Standard
10947 by 
10948 \noun on
10949 John Weiss
10950 \noun default
10951  
10952 \end_layout
10953
10954 \begin_layout Subsection
10955 Introduction
10956 \end_layout
10957
10958 \begin_layout Standard
10959 This section describes how to use \SpecialChar LyX
10960  to make slides for overhead projectors.
10961  There are two document classes that can do this: the default slides class
10962  and the 
10963 \family sans
10964 Foil\SpecialChar TeX
10965
10966 \family default
10967  slides class.
10968  This section documents the former.
10969 \end_layout
10970
10971 \begin_layout Standard
10972 I'm going to say this again, nice and clear, so that there's no misunderstanding
10973 :
10974 \end_layout
10975
10976 \begin_layout Standard
10977 \begin_inset VSpace bigskip
10978 \end_inset
10979
10980
10981 \end_layout
10982
10983 \begin_layout Standard
10984 \align center
10985
10986 \size large
10987 This section documents the class 
10988 \begin_inset Quotes eld
10989 \end_inset
10990
10991
10992 \family sans
10993 slides (default)
10994 \family default
10995
10996 \begin_inset Quotes erd
10997 \end_inset
10998
10999  
11000 \emph on
11001 only.
11002 \end_layout
11003
11004 \begin_layout Standard
11005 \begin_inset VSpace bigskip
11006 \end_inset
11007
11008
11009 \end_layout
11010
11011 \begin_layout Standard
11012 If you're looking for the documentation for 
11013 \begin_inset Quotes eld
11014 \end_inset
11015
11016
11017 \family sans
11018 slides (Foil\SpecialChar TeX
11019 )
11020 \family default
11021
11022 \begin_inset Quotes erd
11023 \end_inset
11024
11025 , check out section
11026 \begin_inset space ~
11027 \end_inset
11028
11029
11030 \begin_inset CommandInset ref
11031 LatexCommand ref
11032 reference "sec:foiltex"
11033
11034 \end_inset
11035
11036 .
11037  The 
11038 \family sans
11039 foils
11040 \family default
11041  class [
11042 \begin_inset Quotes eld
11043 \end_inset
11044
11045
11046 \family sans
11047 slides (Foil\SpecialChar TeX
11048 )
11049 \family default
11050
11051 \begin_inset Quotes erd
11052 \end_inset
11053
11054 ] is actually somewhat better than the default 
11055 \family sans
11056 slides
11057 \family default
11058  class,
11059 \begin_inset Foot
11060 status collapsed
11061
11062 \begin_layout Plain Layout
11063 \SpecialChar ldots
11064 or so I've been told repeatedly by its advocates.
11065  Having never used it, I have no idea if this claim is true or not.
11066 \end_layout
11067
11068 \end_inset
11069
11070  which this section documents.
11071 \end_layout
11072
11073 \begin_layout Standard
11074 This class is the \SpecialChar LaTeX2e
11075  improvement of the old 
11076 \noun on
11077 Sli\SpecialChar TeX
11078
11079 \noun default
11080  package.
11081  Every \SpecialChar LaTeX2e
11082  distribution includes this class [which I'll just refer to as 
11083 \begin_inset Quotes eld
11084 \end_inset
11085
11086
11087 \family sans
11088 slides
11089 \family default
11090
11091 \begin_inset Quotes erd
11092 \end_inset
11093
11094  from now on], so you're bound to have it.
11095  As I noted earlier, there are other classes, such as 
11096 \family sans
11097 foils
11098 \family default
11099 , which also produce slides for overhead projectors and do a better job
11100  at it.
11101  However, there are some things which 
11102 \family sans
11103 slides
11104 \family default
11105  can do which the others can't, such as generate overlays.
11106  Read on to learn more!
11107 \end_layout
11108
11109 \begin_layout Subsection
11110 Getting Started
11111 \begin_inset CommandInset label
11112 LatexCommand label
11113 name "sec:slidesetup"
11114
11115 \end_inset
11116
11117
11118 \end_layout
11119
11120 \begin_layout Standard
11121 Obviously, to use this document class, you need to select 
11122 \begin_inset Quotes eld
11123 \end_inset
11124
11125
11126 \family sans
11127 slides (default)
11128 \family default
11129
11130 \begin_inset Quotes erd
11131 \end_inset
11132
11133  from the class list in the 
11134 \family sans
11135 Document\SpecialChar menuseparator
11136 Settings
11137 \family default
11138  dialog.
11139  There are some other special things you should know about this class:
11140 \end_layout
11141
11142 \begin_layout Itemize
11143 Don't bother changing the options 
11144 \family sans
11145 Sides and Columns
11146 \family default
11147 .
11148  They're not supported by the 
11149 \family sans
11150 slides
11151 \family default
11152  class, anyways.
11153 \end_layout
11154
11155 \begin_layout Itemize
11156 The option 
11157 \family sans
11158 Page
11159 \begin_inset space ~
11160 \end_inset
11161
11162 style
11163 \family default
11164  behaves a bit differently for this class.
11165  The possible choices and what they do are as follows:
11166 \end_layout
11167
11168 \begin_deeper
11169 \begin_layout Description
11170
11171 \family sans
11172 plain
11173 \family default
11174  The final output contains page numbers in the lower right corner.
11175 \end_layout
11176
11177 \begin_layout Description
11178
11179 \family sans
11180 headings
11181 \family default
11182  Like 
11183 \family sans
11184 plain
11185 \family default
11186 , but also prints out any time markers you've put in.
11187  This is the default.
11188 \end_layout
11189
11190 \begin_layout Description
11191
11192 \family sans
11193 empty
11194 \family default
11195  The final output contains no page numbers, time markers, or alignment markers.
11196 \end_layout
11197
11198 \end_deeper
11199 \begin_layout Itemize
11200 The 
11201 \family sans
11202 slides
11203 \family default
11204  class has an extra option: 
11205 \family typewriter
11206 clock
11207 \family default
11208 .
11209  To use it, put 
11210 \begin_inset Quotes eld
11211 \end_inset
11212
11213
11214 \family typewriter
11215 clock
11216 \family default
11217
11218 \begin_inset Quotes erd
11219 \end_inset
11220
11221  in the extra class options.
11222 \end_layout
11223
11224 \begin_deeper
11225 \begin_layout Standard
11226 Using this options allows you to add time markers to 
11227 \family sans
11228 Note
11229 \family default
11230 s.
11231  See section
11232 \begin_inset space ~
11233 \end_inset
11234
11235
11236 \begin_inset CommandInset ref
11237 LatexCommand ref
11238 reference "sec:slideNote"
11239
11240 \end_inset
11241
11242  for more details.
11243 \end_layout
11244
11245 \end_deeper
11246 \begin_layout Standard
11247 You can also use the template file 
11248 \begin_inset Quotes eld
11249 \end_inset
11250
11251
11252 \family typewriter
11253 slides.lyx
11254 \family default
11255
11256 \begin_inset Quotes erd
11257 \end_inset
11258
11259  to automatically set up a document to use the 
11260 \family sans
11261 slides
11262 \family default
11263  class [using 
11264 \family sans
11265 File\SpecialChar menuseparator
11266 New
11267 \begin_inset space ~
11268 \end_inset
11269
11270 from
11271 \begin_inset space ~
11272 \end_inset
11273
11274 Template
11275 \family default
11276  to open your new document].
11277  The template file also contains some examples of the special paragraph
11278  environments used by this class.
11279  I'll describe those next.
11280 \end_layout
11281
11282 \begin_layout Subsection
11283 Paragraph Environments
11284 \end_layout
11285
11286 \begin_layout Subsubsection
11287 Supported Environments
11288 \end_layout
11289
11290 \begin_layout Standard
11291 The first thing you'll notice when you start up a new 
11292 \family sans
11293 slides
11294 \family default
11295  document is the font size and type: it's the equivalent of the size 
11296 \begin_inset Quotes eld
11297 \end_inset
11298
11299
11300 \family sans
11301 Largest
11302 \family default
11303
11304 \begin_inset Quotes erd
11305 \end_inset
11306
11307  in the 
11308 \family sans
11309 Sans
11310 \begin_inset space ~
11311 \end_inset
11312
11313 Serif
11314 \family default
11315  font.
11316  This is also what's used in the output.
11317  Think of this as a 
11318 \begin_inset Quotes eld
11319 \end_inset
11320
11321 visual cue
11322 \begin_inset Quotes erd
11323 \end_inset
11324
11325  to remind you that this is a slide.
11326  Your final slides will use a larger font; ergo, you'll have less space.
11327  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
11328 \end_layout
11329
11330 \begin_layout Standard
11331 The next thing that becomes obvious is the changes to the paragraph environment
11332  pull-down box [at the far-left end of the toolbar].
11333  Most of the paragraph environments you're used to seeing are missing.
11334  There are also five new ones.
11335  That's because the 
11336 \family sans
11337 slides
11338 \family default
11339  class itself only supports certain paragraph environments:
11340 \end_layout
11341
11342 \begin_layout Itemize
11343
11344 \family sans
11345 Standard
11346 \end_layout
11347
11348 \begin_layout Itemize
11349
11350 \family sans
11351 Itemize
11352 \end_layout
11353
11354 \begin_layout Itemize
11355
11356 \family sans
11357 Enumerate
11358 \end_layout
11359
11360 \begin_layout Itemize
11361
11362 \family sans
11363 Description
11364 \end_layout
11365
11366 \begin_layout Itemize
11367
11368 \family sans
11369 List
11370 \end_layout
11371
11372 \begin_layout Itemize
11373
11374 \family sans
11375 Quotation
11376 \end_layout
11377
11378 \begin_layout Itemize
11379
11380 \family sans
11381 Quote
11382 \end_layout
11383
11384 \begin_layout Itemize
11385
11386 \family sans
11387 Verse
11388 \end_layout
11389
11390 \begin_layout Itemize
11391
11392 \family sans
11393 Caption
11394 \end_layout
11395
11396 \begin_layout Itemize
11397
11398 \family sans
11399 \SpecialChar LyX
11400 -Code
11401 \end_layout
11402
11403 \begin_layout Itemize
11404
11405 \family sans
11406 Comment
11407 \end_layout
11408
11409 \begin_layout Standard
11410 All of the other standard environments, including the section-heading environmen
11411 ts, aren't used in the 
11412 \family sans
11413 slides
11414 \family default
11415  class.
11416 \end_layout
11417
11418 \begin_layout Standard
11419 On the other hand, you'll notice the following new environments:
11420 \end_layout
11421
11422 \begin_layout Itemize
11423
11424 \family sans
11425 Slide
11426 \end_layout
11427
11428 \begin_layout Itemize
11429
11430 \family sans
11431 Overlay
11432 \end_layout
11433
11434 \begin_layout Itemize
11435
11436 \family sans
11437 Note
11438 \end_layout
11439
11440 \begin_layout Itemize
11441
11442 \family sans
11443 InvisibleText
11444 \end_layout
11445
11446 \begin_layout Itemize
11447
11448 \family sans
11449 VisibleText
11450 \end_layout
11451
11452 \begin_layout Standard
11453 These five are kind of quirky, due to a 
11454 \begin_inset Quotes eld
11455 \end_inset
11456
11457 feature
11458 \begin_inset Quotes erd
11459 \end_inset
11460
11461  in \SpecialChar LyX
11462 .
11463  You see, \SpecialChar LyX
11464  doesn't permit you to nest any other paragraph environment into
11465  an empty environment.
11466  Now, that's fine and dandy, but it means that you wouldn't be able to start
11467  a slide with anything except plain text.
11468  To deal with this, I've performed a little 
11469 \begin_inset Quotes eld
11470 \end_inset
11471
11472 \SpecialChar LaTeX
11473  magic.
11474 \begin_inset Quotes erd
11475 \end_inset
11476
11477  
11478 \end_layout
11479
11480 \begin_layout Subsubsection
11481 Quirks of the New Environments
11482 \begin_inset CommandInset label
11483 LatexCommand label
11484 name "sec:slideQuirk"
11485
11486 \end_inset
11487
11488
11489 \end_layout
11490
11491 \begin_layout Standard
11492 All five of the new paragraph environments are somewhat quirky due to inherent
11493  limitiations in the current version of \SpecialChar LyX
11494 .
11495  As I just mentioned, \SpecialChar LyX
11496  forbids environments that begin with another environment.
11497  To get around this, the 
11498 \family sans
11499 Slide
11500 \family default
11501  environment isn't a paragraph environment as described in the 
11502 \emph on
11503 User's Guide
11504 \emph default
11505 .
11506  
11507 \end_layout
11508
11509 \begin_layout Standard
11510 You should consider 
11511 \family sans
11512 Slide
11513 \family default
11514
11515 \family sans
11516 Overlay
11517 \family default
11518 , and 
11519 \family sans
11520 Note
11521 \family default
11522  to be 
11523 \begin_inset Quotes eld
11524 \end_inset
11525
11526 pseudo-environments.
11527 \begin_inset Quotes erd
11528 \end_inset
11529
11530  They look like a section heading or a 
11531 \begin_inset Quotes eld
11532 \end_inset
11533
11534
11535 \family sans
11536 Caption
11537 \family default
11538 ,
11539 \begin_inset Quotes erd
11540 \end_inset
11541
11542  but really begin a [and, if necessary, end the previous] paragraph environment.
11543  Likewise, treat 
11544 \family sans
11545 InvisibleText
11546 \family default
11547  and 
11548 \family sans
11549 VisibleText
11550 \family default
11551  as 
11552 \begin_inset Quotes eld
11553 \end_inset
11554
11555 pseudo-commands.
11556 \begin_inset Quotes erd
11557 \end_inset
11558
11559  These two perform some action.
11560 \end_layout
11561
11562 \begin_layout Standard
11563 A common feature of all five environments, 
11564 \family sans
11565 Slide
11566 \family default
11567
11568 \family sans
11569 Overlay
11570 \family default
11571
11572 \family sans
11573 Note
11574 \family default
11575
11576 \family sans
11577 InvisibleText
11578 \family default
11579  and 
11580 \family sans
11581 VisibleText
11582 \family default
11583 , is a rather long-ish label.
11584  The text following this label — ordinarily the contents of the paragraph
11585  environment — is utterly irrelevant for 
11586 \family sans
11587 Slide
11588 \family default
11589
11590 \family sans
11591 Overlay
11592 \family default
11593
11594 \family sans
11595 Note
11596 \family default
11597
11598 \family sans
11599 InvisibleText
11600 \family default
11601  and 
11602 \family sans
11603 VisibleText
11604 \family default
11605 .
11606  \SpecialChar LyX
11607  completely ignores it.
11608  In fact, you can leave these five environments completely empty.
11609  
11610 \end_layout
11611
11612 \begin_layout Standard
11613 While you don't 
11614 \emph on
11615 have
11616 \emph default
11617  to put any text after the rather long-ish label, you might want to.
11618  This could be a short description of the contents of the 
11619 \family sans
11620 Slide
11621 \family default
11622 , for example.
11623  In that case, enter your descriptive comment and hit 
11624 \family sans
11625 Return
11626 \family default
11627  as you normally would.
11628 \end_layout
11629
11630 \begin_layout Standard
11631 If, on the other hand, you don't want to enter any descriptive text, you'll
11632  hit another \SpecialChar LyX
11633  quirk.
11634  \SpecialChar LyX
11635 , like nature, abhors a vacuum, and will not let you start a new paragraph
11636  environment until you put something in the old one.
11637  So, do this:
11638 \end_layout
11639
11640 \begin_layout Itemize
11641 Start entering the text that will 
11642 \emph on
11643 follow
11644 \emph default
11645  the new 
11646 \family sans
11647 Slide
11648 \family default
11649
11650 \family sans
11651 Overlay
11652 \family default
11653
11654 \family sans
11655 Note
11656 \family default
11657
11658 \family sans
11659 InvisibleText
11660 \family default
11661  or 
11662 \family sans
11663 VisibleText
11664 \family default
11665 .
11666  
11667 \end_layout
11668
11669 \begin_layout Itemize
11670 Now move to the beginning of that paragraph.
11671  
11672 \end_layout
11673
11674 \begin_layout Itemize
11675 Next, hit 
11676 \family sans
11677 Return
11678 \family default
11679 .
11680  
11681 \end_layout
11682
11683 \begin_layout Itemize
11684 Finally, change this new, empty paragraph to a 
11685 \family sans
11686 Slide
11687 \family default
11688
11689 \family sans
11690 Overlay
11691 \family default
11692
11693 \family sans
11694 Note
11695 \family default
11696
11697 \family sans
11698 InvisibleText
11699 \family default
11700  or 
11701 \family sans
11702 VisibleText
11703 \family default
11704 .
11705  
11706 \end_layout
11707
11708 \begin_layout Standard
11709 Some future version of \SpecialChar LyX
11710  will, hopefully, resolve this quirkiness\SpecialChar ldots
11711
11712 \end_layout
11713
11714 \begin_layout Subsection
11715 Making a Presentation with 
11716 \family sans
11717 Slide
11718 \family default
11719
11720 \family sans
11721 Overlay
11722 \family default
11723  and 
11724 \family sans
11725 Note
11726 \end_layout
11727
11728 \begin_layout Subsubsection
11729 Using the 
11730 \family sans
11731 Slide
11732 \family default
11733  Environment
11734 \end_layout
11735
11736 \begin_layout Standard
11737 If you're expecting this section to teach you how to actually make a presentatio
11738 n, you'll be sorely disappointed.
11739  Naturally, I'll describe all of the ways the 
11740 \family sans
11741 slides
11742 \family default
11743  class can assist you in preparing the materials for a presentation.
11744  Filling in the contents, however, is up to you.
11745  [Then again, that 
11746 \emph on
11747 is
11748 \emph default
11749  the \SpecialChar LyX
11750  philosophy.]
11751 \end_layout
11752
11753 \begin_layout Standard
11754 Choosing the 
11755 \family sans
11756 Slide
11757 \family default
11758  environment [in the manner described in section
11759 \begin_inset space ~
11760 \end_inset
11761
11762
11763 \begin_inset CommandInset ref
11764 LatexCommand ref
11765 reference "sec:slideQuirk"
11766
11767 \end_inset
11768
11769 ] tells \SpecialChar LyX
11770  to begin a new slide [duh].
11771  The label for this environment/
11772 \begin_inset Quotes erd
11773 \end_inset
11774
11775 pseudo-command
11776 \begin_inset Quotes erd
11777 \end_inset
11778
11779  is an 
11780 \begin_inset Quotes eld
11781 \end_inset
11782
11783 ASCII line,
11784 \begin_inset Quotes erd
11785 \end_inset
11786
11787  in cool blue, followed by the label, 
11788 \begin_inset Quotes eld
11789 \end_inset
11790
11791 NewSlide:
11792 \begin_inset Quotes erd
11793 \end_inset
11794
11795 .
11796  Any text or paragraph environments that follow this one go on the new slide.
11797  It's that simple.
11798 \end_layout
11799
11800 \begin_layout Standard
11801 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
11802
11803  (this can be specified in the 
11804 \family sans
11805 Paragraph Layout
11806 \family default
11807  dialog).
11808  In fact, you'll want to, once you finish entering the contents of one slide.
11809  If you've entered more text than can physically fit on a slide, the extra
11810  overflows onto a new slide.
11811  I don't recommend doing this, however, since the overflow slide won't have
11812  any page number on it.
11813  Furthermore, it may interfere with any 
11814 \family sans
11815 Overlay
11816 \family default
11817  you've made to accompany the oversized 
11818 \family sans
11819 Slide
11820 \family default
11821 .
11822 \end_layout
11823
11824 \begin_layout Standard
11825 The 
11826 \family sans
11827 Overlay
11828 \family default
11829  and 
11830 \family sans
11831 Note
11832 \family default
11833  environments work the same way as the 
11834 \family sans
11835 Slide
11836 \family default
11837  environment.
11838  They both create an 
11839 \begin_inset Quotes eld
11840 \end_inset
11841
11842 ASCII line
11843 \begin_inset Quotes erd
11844 \end_inset
11845
11846  followed by a label [
11847 \begin_inset Quotes eld
11848 \end_inset
11849
11850 NewOverlay:
11851 \begin_inset Quotes erd
11852 \end_inset
11853
11854  and 
11855 \begin_inset Quotes eld
11856 \end_inset
11857
11858 NewNote:
11859 \begin_inset Quotes erd
11860 \end_inset
11861
11862 , respectively].
11863  The color is a stunning magenta instead of blue, and the 
11864 \begin_inset Quotes eld
11865 \end_inset
11866
11867 ASCII line
11868 \begin_inset Quotes erd
11869 \end_inset
11870
11871  will look different, in style and in length.
11872  The label fonts of all three also differ from one another.
11873 \end_layout
11874
11875 \begin_layout Standard
11876 As with a 
11877 \family sans
11878 Slide
11879 \family default
11880 , if the contents of a 
11881 \family sans
11882 Note
11883 \family default
11884  or 
11885 \family sans
11886 Overlay
11887 \family default
11888  exceed the physical size of a slide or sheet of paper, the extra will overflow
11889  onto a new sheet.
11890  Again, you should avoid this.
11891  It defeats the whole purpose of 
11892 \family sans
11893 Note
11894 \family default
11895 s and 
11896 \family sans
11897 Overlay
11898 \family default
11899 s.
11900 \end_layout
11901
11902 \begin_layout Subsubsection
11903 Using 
11904 \family sans
11905 Overlay
11906 \family default
11907  with 
11908 \family sans
11909 Slide
11910 \end_layout
11911
11912 \begin_layout Standard
11913 The idea behind an 
11914 \family sans
11915 Overlay
11916 \family default
11917  is a slide that sits atop another slide.
11918  Perhaps you wish to discuss a figure on the main 
11919 \family sans
11920 Slide
11921 \family default
11922  before displaying the text associated with it.
11923  One way to accomplish this is tape a flap of dark paper over the part of
11924  the 
11925 \family sans
11926 Slide
11927 \family default
11928  you want to display later.
11929  This method fails, however, if you wish to overlap one graph with another,
11930  for example.
11931  You would then have to fumble while speaking to align the two separate,
11932  overlapping 
11933 \family sans
11934 Slide
11935 \family default
11936 s to align the two graphs.
11937  The use of an 
11938 \family sans
11939 Overlay
11940 \family default
11941  environment in both cases makes life much easier.
11942 \end_layout
11943
11944 \begin_layout Standard
11945 Each 
11946 \family sans
11947 Overlay
11948 \family default
11949  receives the page number of its 
11950 \begin_inset Quotes eld
11951 \end_inset
11952
11953 parent
11954 \begin_inset Quotes erd
11955 \end_inset
11956
11957  
11958 \family sans
11959 Slide
11960 \family default
11961 , appended by 
11962 \begin_inset Quotes eld
11963 \end_inset
11964
11965
11966 \family typewriter
11967 -a
11968 \family default
11969
11970 \begin_inset Quotes erd
11971 \end_inset
11972
11973 .
11974 \begin_inset Foot
11975 status collapsed
11976
11977 \begin_layout Plain Layout
11978 Presumably, mutliple 
11979 \family sans
11980 Overlay
11981 \family default
11982 s would have 
11983 \begin_inset Quotes eld
11984 \end_inset
11985
11986
11987 \family typewriter
11988 -a
11989 \family default
11990
11991 \begin_inset Quotes erd
11992 \end_inset
11993
11994
11995 \begin_inset Quotes eld
11996 \end_inset
11997
11998
11999 \family typewriter
12000 -b
12001 \family default
12002
12003 \begin_inset Quotes erd
12004 \end_inset
12005
12006
12007 \begin_inset Quotes eld
12008 \end_inset
12009
12010
12011 \family typewriter
12012 -c
12013 \family default
12014
12015 \begin_inset Quotes erd
12016 \end_inset
12017
12018 , etc.
12019 \begin_inset space ~
12020 \end_inset
12021
12022 appended to the page number of the parent 
12023 \family sans
12024 Slide
12025 \family default
12026 .
12027  
12028 \end_layout
12029
12030 \end_inset
12031
12032  Clearly, you want the contents of both the 
12033 \family sans
12034 Slide
12035 \family default
12036  and the 
12037 \family sans
12038 Overlay
12039 \family default
12040  to each fit on a single physical slide! You should probably consider an
12041  
12042 \family sans
12043 Overlay
12044 \family default
12045  as 
12046 \begin_inset Quotes eld
12047 \end_inset
12048
12049 part of
12050 \begin_inset Quotes erd
12051 \end_inset
12052
12053  a 
12054 \family sans
12055 Slide
12056 \family default
12057 .
12058  Indeed, the \SpecialChar LyX
12059  
12060 \family sans
12061 slides
12062 \family default
12063  class provides a visual cue for this: the label at the start of an 
12064 \family sans
12065 Overlay
12066 \family default
12067  is shorter than that at the start of a 
12068 \family sans
12069 Slide
12070 \family default
12071 .
12072  Lastly, when you generate printable output, you'll find alignment markers
12073  in all four corners of both the 
12074 \family sans
12075 Overlay
12076 \family default
12077  page and its parent 
12078 \family sans
12079 Slide
12080 \family default
12081 .
12082  These will assist you in lining up the two physical slides.
12083 \end_layout
12084
12085 \begin_layout Standard
12086 The major problem in overlaying two slides is aligning the contents of the
12087  two transparencies.
12088  How much space should you leave for that graph on the second slide? Worse
12089  still, what if you want a graph and a sentence on second slide, but there
12090  is text on the main transparency that goes in between them? You could try
12091  and insert vertical space of the right size.
12092  The better way is to use 
12093 \family sans
12094 InvisibleText
12095 \family default
12096  and 
12097 \family sans
12098 VisibleText
12099 \family default
12100 .
12101 \end_layout
12102
12103 \begin_layout Standard
12104 As their names imply, 
12105 \family sans
12106 InvisibleText
12107 \family default
12108  and 
12109 \family sans
12110 VisibleText
12111 \family default
12112  are two command-like paragraph environments that make all subsequent text
12113  invisible and visible, respectively.
12114  Note from section
12115 \begin_inset space ~
12116 \end_inset
12117
12118
12119 \begin_inset CommandInset ref
12120 LatexCommand ref
12121 reference "sec:slideQuirk"
12122
12123 \end_inset
12124
12125  that you don't place anything 
12126 \emph on
12127 into
12128 \emph default
12129  these two environments, however.
12130  When you create an 
12131 \family sans
12132 InvisibleText
12133 \family default
12134 , it inserts a centered, sky-blue label into the page reading 
12135 \begin_inset Quotes eld
12136 \end_inset
12137
12138 <Invisible Text Follows>
12139 \begin_inset Quotes erd
12140 \end_inset
12141
12142 .
12143  For paragraphs following this label, the parts of the 
12144 \family sans
12145 Slide
12146 \family default
12147  [or 
12148 \family sans
12149 Overlay
12150 \family default
12151 ; it doesn't matter which] where they would be contain instead blank space.
12152  
12153 \end_layout
12154
12155 \begin_layout Standard
12156 For 
12157 \family sans
12158 VisibleText
12159 \family default
12160 , the corresponding centered label is 
12161 \begin_inset Quotes eld
12162 \end_inset
12163
12164 <Visible Text Follows>
12165 \begin_inset Quotes erd
12166 \end_inset
12167
12168  in blazing green.
12169  Paragraphs following this label behave normally.
12170  Note that the beginning of a new 
12171 \family sans
12172 Slide
12173 \family default
12174
12175 \family sans
12176 Overlay
12177 \family default
12178 , or 
12179 \family sans
12180 Note
12181 \family default
12182  automatically shuts off an 
12183 \family sans
12184 InvisibleText
12185 \family default
12186 .
12187  It's therefore not necessary to use 
12188 \family sans
12189 VisibleText
12190 \family default
12191  at the end of a 
12192 \family sans
12193 Slide
12194 \family default
12195 .
12196 \end_layout
12197
12198 \begin_layout Standard
12199 By now, it should be obvious how to create overlay transparencies using
12200  the proper combination of 
12201 \family sans
12202 InvisibleText
12203 \family default
12204  and 
12205 \family sans
12206 VisibleText
12207 \family default
12208  on a 
12209 \family sans
12210 Slide
12211 \family default
12212  and 
12213 \family sans
12214 Overlay
12215 \family default
12216 :
12217 \end_layout
12218
12219 \begin_layout Enumerate
12220 Create a 
12221 \family sans
12222 Slide
12223 \family default
12224 , including everything that will appear on it, whether on the main slide
12225  or on the 
12226 \family sans
12227 Overlay
12228 \family default
12229 .
12230 \end_layout
12231
12232 \begin_layout Enumerate
12233 Before each figure or paragraph that will appear only on the 
12234 \family sans
12235 Overlay
12236 \family default
12237 , insert an 
12238 \family sans
12239 InvisibleText
12240 \family default
12241  environment.
12242  If necessary, insert a 
12243 \family sans
12244 VisibleText
12245 \family default
12246  environment after the 
12247 \family sans
12248 Overlay
12249 \family default
12250 -only text.
12251 \end_layout
12252
12253 \begin_layout Enumerate
12254 Start an 
12255 \family sans
12256 Overlay
12257 \family default
12258  immediately following the 
12259 \family sans
12260 Slide
12261 \family default
12262 .
12263 \end_layout
12264
12265 \begin_layout Enumerate
12266 Copy the contents of this 
12267 \family sans
12268 Slide
12269 \family default
12270  into the 
12271 \family sans
12272 Overlay
12273 \family default
12274 .
12275 \end_layout
12276
12277 \begin_layout Enumerate
12278 Within the 
12279 \family sans
12280 Overlay
12281 \family default
12282 , change all of the 
12283 \family sans
12284 InvisibleText
12285 \family default
12286  lines to 
12287 \family sans
12288 VisibleText
12289 \family default
12290  and vice-versa.
12291 \end_layout
12292
12293 \begin_layout Standard
12294 That's it.
12295  You've just made an 
12296 \family sans
12297 Overlay
12298 \family default
12299 .
12300 \end_layout
12301
12302 \begin_layout Standard
12303 There's one problem with the way I've designed the \SpecialChar LyX
12304  
12305 \family sans
12306 slides
12307 \family default
12308  class: you can't make text in the middle of a paragraph invisible, nor
12309  make text in the middle of an invisible paragraph visible again.
12310  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
12311  codes.
12312 \begin_inset Foot
12313 status collapsed
12314
12315 \begin_layout Plain Layout
12316 The commands of interest are: 
12317 \end_layout
12318
12319 \begin_layout Itemize
12320
12321 \family typewriter
12322 {
12323 \backslash
12324 invisible \SpecialChar ldots
12325  }
12326 \end_layout
12327
12328 \begin_layout Itemize
12329
12330 \family typewriter
12331 {
12332 \backslash
12333 visible \SpecialChar ldots
12334  }
12335 \end_layout
12336
12337 \begin_layout Plain Layout
12338 \SpecialChar ldots
12339 and need to be marked as \SpecialChar TeX
12340 .
12341  The text whose 
12342 \begin_inset Quotes eld
12343 \end_inset
12344
12345 visibility
12346 \begin_inset Quotes erd
12347 \end_inset
12348
12349  you wish to change goes in between the brackets [and after the 
12350 \family typewriter
12351
12352 \backslash
12353 invisible
12354 \family default
12355  or 
12356 \family typewriter
12357
12358 \backslash
12359 visible
12360 \family default
12361  command].
12362  If you don't know how to mark text as \SpecialChar TeX
12363 , see the appropriate section of
12364  the 
12365 \emph on
12366 User's Guide
12367 \emph default
12368 .
12369 \end_layout
12370
12371 \end_inset
12372
12373
12374 \end_layout
12375
12376 \begin_layout Subsubsection
12377 Using 
12378 \family sans
12379 Note
12380 \family default
12381  with 
12382 \family sans
12383 Slide
12384 \family default
12385
12386 \begin_inset CommandInset label
12387 LatexCommand label
12388 name "sec:slideNote"
12389
12390 \end_inset
12391
12392
12393 \end_layout
12394
12395 \begin_layout Standard
12396 Like an 
12397 \family sans
12398 Overlay
12399 \family default
12400 , a 
12401 \family sans
12402 Note
12403 \family default
12404  is associated with a 
12405 \begin_inset Quotes eld
12406 \end_inset
12407
12408 parent
12409 \begin_inset Quotes erd
12410 \end_inset
12411
12412  
12413 \family sans
12414 Slide
12415 \family default
12416 .
12417  Here, too, the \SpecialChar LyX
12418  
12419 \family sans
12420 slides
12421 \family default
12422  class provides visual cues.
12423  The label for a 
12424 \family sans
12425 Note
12426 \family default
12427  is shorter than that of a 
12428 \family sans
12429 Slide
12430 \family default
12431  [yet longer than that of an 
12432 \family sans
12433 Overlay
12434 \family default
12435 ] and, like the label of an 
12436 \family sans
12437 Overlay
12438 \family default
12439  is shockingly magenta.
12440  Additionally, the printed 
12441 \family sans
12442 Note
12443 \family default
12444  has the page number of its 
12445 \begin_inset Quotes eld
12446 \end_inset
12447
12448 parent
12449 \begin_inset Quotes erd
12450 \end_inset
12451
12452  
12453 \family sans
12454 Slide
12455 \family default
12456 , appended by 
12457 \begin_inset Quotes eld
12458 \end_inset
12459
12460
12461 \family typewriter
12462 -
12463 \family default
12464 1
12465 \begin_inset Quotes erd
12466 \end_inset
12467
12468
12469 \begin_inset Quotes eld
12470 \end_inset
12471
12472
12473 \family typewriter
12474 -
12475 \family default
12476 2
12477 \begin_inset Quotes erd
12478 \end_inset
12479
12480
12481 \begin_inset Quotes eld
12482 \end_inset
12483
12484
12485 \family typewriter
12486 -
12487 \family default
12488 3
12489 \begin_inset Quotes erd
12490 \end_inset
12491
12492 , etc.
12493  You can have multiple 
12494 \family sans
12495 Note
12496 \family default
12497 s associated with a single 
12498 \family sans
12499 Slide
12500 \family default
12501 , and, as with 
12502 \family sans
12503 Slide
12504 \family default
12505  and 
12506 \family sans
12507 Overlay
12508 \family default
12509 , you'll probably want to break up long 
12510 \family sans
12511 Note
12512 \family default
12513 s so that they fit on a single sheet of paper.
12514 \end_layout
12515
12516 \begin_layout Standard
12517 The purpose of a 
12518 \family sans
12519 Note
12520 \family default
12521  is obvious: it contains anything additional you might want to say about
12522  a 
12523 \family sans
12524 Slide
12525 \family default
12526 .
12527  It could also be used as a sheet of reminders for a particular 
12528 \family sans
12529 Slide
12530 \family default
12531 .
12532  In the case of the latter, you might want to make use of time markers.
12533  Currently, the \SpecialChar LyX
12534  
12535 \family sans
12536 slides
12537 \family default
12538  class has no 
12539 \begin_inset Quotes eld
12540 \end_inset
12541
12542 native
12543 \begin_inset Quotes erd
12544 \end_inset
12545
12546  support for time markers, a 
12547 \noun on
12548 Sli\SpecialChar TeX
12549
12550 \noun default
12551  feature.
12552  So, you'll have to resort to using the \SpecialChar LaTeX
12553  codes.
12554 \end_layout
12555
12556 \begin_layout Standard
12557 To use time markers, you'll need to specify the extra class option 
12558 \begin_inset Quotes eld
12559 \end_inset
12560
12561
12562 \family typewriter
12563 clock
12564 \family default
12565
12566 \begin_inset Quotes erd
12567 \end_inset
12568
12569  [see section
12570 \begin_inset space ~
12571 \end_inset
12572
12573
12574 \begin_inset CommandInset ref
12575 LatexCommand ref
12576 reference "sec:slidesetup"
12577
12578 \end_inset
12579
12580 ].
12581  This option turns on timing marks, which will appear in the lower-left-hand
12582  corner of every 
12583 \family sans
12584 Note
12585 \family default
12586  you generate.
12587  To set what appears in the time marker, you use the \SpecialChar LaTeX
12588  commands 
12589 \begin_inset Quotes eld
12590 \end_inset
12591
12592
12593 \family typewriter
12594
12595 \backslash
12596 settime{}
12597 \family default
12598
12599 \begin_inset Quotes erd
12600 \end_inset
12601
12602  and 
12603 \begin_inset Quotes eld
12604 \end_inset
12605
12606
12607 \family typewriter
12608
12609 \backslash
12610 addtime{}
12611 \family default
12612
12613 \begin_inset Quotes erd
12614 \end_inset
12615
12616 .
12617  The arguments of both commands are time measured in seconds.
12618  
12619 \begin_inset Quotes eld
12620 \end_inset
12621
12622
12623 \family typewriter
12624
12625 \backslash
12626 settime{}
12627 \family default
12628
12629 \begin_inset Quotes erd
12630 \end_inset
12631
12632  sets the time marker to a given time.
12633  
12634 \begin_inset Quotes eld
12635 \end_inset
12636
12637
12638 \family typewriter
12639
12640 \backslash
12641 addtime{}
12642 \family default
12643
12644 \begin_inset Quotes erd
12645 \end_inset
12646
12647  increments the time marker by the specified amount.
12648  Using time markers and 
12649 \family sans
12650 Note
12651 \family default
12652 s in this fashion, you can remind yourself how much time to spend on a particula
12653
12654 \family sans
12655 Slide
12656 \family default
12657 .
12658 \end_layout
12659
12660 \begin_layout Standard
12661 There's one last feature to describe.
12662  Clearly, you'd like to print out all of your 
12663 \family sans
12664 Slide
12665 \family default
12666 s and 
12667 \family sans
12668 Overlay
12669 \family default
12670 s on transparencies while printing all of your 
12671 \family sans
12672 Note
12673 \family default
12674 s on plain paper.
12675  However, a 
12676 \family sans
12677 Note
12678 \family default
12679  
12680 \emph on
12681 must
12682 \emph default
12683  follow the 
12684 \family sans
12685 Slide
12686 \family default
12687  with which it is associated.
12688  What's a person to do?
12689 \end_layout
12690
12691 \begin_layout Standard
12692 Luckily, there are two \SpecialChar LaTeX
12693  commands that allow you to select what to print
12694  out.
12695  Both must be placed into the preamble of your document.
12696  The command 
12697 \begin_inset Quotes eld
12698 \end_inset
12699
12700
12701 \family typewriter
12702
12703 \backslash
12704 onlyslides{
12705 \backslash
12706 slides}
12707 \family default
12708
12709 \begin_inset Quotes erd
12710 \end_inset
12711
12712  will cause the output to contain only the 
12713 \family sans
12714 Slide
12715 \family default
12716 s and 
12717 \family sans
12718 Overlay
12719 \family default
12720 s.
12721  Correspondingly, the command 
12722 \begin_inset Quotes eld
12723 \end_inset
12724
12725
12726 \family typewriter
12727
12728 \backslash
12729 onlynotes{
12730 \backslash
12731 notes}
12732 \family default
12733
12734 \begin_inset Quotes erd
12735 \end_inset
12736
12737  prevents the output of anything but 
12738 \family sans
12739 Note
12740 \family default
12741 s.
12742  I'd advise placing both commands in the preamble and initially comment
12743  both out.
12744  You can then preview your entire presentation as you write.
12745  When you're done writing, you can then uncomment one of the two to select
12746  what you want to print.
12747  I like to uncomment 
12748 \begin_inset Quotes eld
12749 \end_inset
12750
12751
12752 \family typewriter
12753
12754 \backslash
12755 onlyslides{
12756 \backslash
12757 slides}
12758 \family default
12759
12760 \begin_inset Quotes erd
12761 \end_inset
12762
12763  , print to a file with 
12764 \begin_inset Quotes eld
12765 \end_inset
12766
12767
12768 \family typewriter
12769 -slides
12770 \family default
12771
12772 \begin_inset Quotes erd
12773 \end_inset
12774
12775  in its name, comment it back out, then uncomment 
12776 \begin_inset Quotes eld
12777 \end_inset
12778
12779
12780 \family typewriter
12781
12782 \backslash
12783 onlynotes{
12784 \backslash
12785 notes}
12786 \family default
12787
12788 \begin_inset Quotes erd
12789 \end_inset
12790
12791  and print to a 
12792 \begin_inset Quotes eld
12793 \end_inset
12794
12795
12796 \family typewriter
12797 *-notes.ps
12798 \family default
12799
12800 \begin_inset Quotes erd
12801 \end_inset
12802
12803  file.
12804  I can then send either file to a printer, loading transparencies or plain
12805  paper as appropriate.
12806 \end_layout
12807
12808 \begin_layout Standard
12809 You can also provide other arguments to the 
12810 \begin_inset Quotes eld
12811 \end_inset
12812
12813
12814 \family typewriter
12815
12816 \backslash
12817 onlyslides{}
12818 \family default
12819
12820 \begin_inset Quotes erd
12821 \end_inset
12822
12823  and 
12824 \begin_inset Quotes eld
12825 \end_inset
12826
12827
12828 \family typewriter
12829
12830 \backslash
12831 onlynotes{}
12832 \family default
12833
12834 \begin_inset Quotes erd
12835 \end_inset
12836
12837  commands.
12838  See a good \SpecialChar LaTeX
12839  book for details.
12840 \end_layout
12841
12842 \begin_layout Subsection
12843 The 
12844 \family sans
12845 slides
12846 \family default
12847  Class Template File
12848 \end_layout
12849
12850 \begin_layout Standard
12851 I have also provided a template file, 
12852 \begin_inset Quotes eld
12853 \end_inset
12854
12855
12856 \family typewriter
12857 slides.lyx
12858 \family default
12859
12860 \begin_inset Quotes erd
12861 \end_inset
12862
12863 , with the 
12864 \family sans
12865 slides
12866 \family default
12867  class.
12868  To use it, begin your new presentation with 
12869 \family sans
12870 File\SpecialChar menuseparator
12871 New
12872 \begin_inset space ~
12873 \end_inset
12874
12875 from
12876 \begin_inset space ~
12877 \end_inset
12878
12879 Template
12880 \family default
12881 .
12882  Your new \SpecialChar LyX
12883  presentation file will contain an example 
12884 \family sans
12885 Slide
12886 \family default
12887  – 
12888 \family sans
12889 Overlay
12890 \family default
12891  – 
12892 \family sans
12893 Note
12894 \family default
12895  triplet.
12896  The 
12897 \family sans
12898 Slide
12899 \family default
12900  and 
12901 \family sans
12902 Overlay
12903 \family default
12904  additionally contain an example of the use of 
12905 \family sans
12906 InvisibleText
12907 \family default
12908  and 
12909 \family sans
12910 VisibleText
12911 \family default
12912 .
12913  Lastly, the preamble will contain:
12914 \end_layout
12915
12916 \begin_layout LyX-Code
12917 % Uncomment to print out only slides and overlays
12918 \end_layout
12919
12920 \begin_layout LyX-Code
12921 %
12922 \end_layout
12923
12924 \begin_layout LyX-Code
12925 %
12926 \backslash
12927 onlyslides{
12928 \backslash
12929 slides}
12930 \begin_inset Newline newline
12931 \end_inset
12932
12933  
12934 \end_layout
12935
12936 \begin_layout LyX-Code
12937 % Uncomment to print out only notes
12938 \end_layout
12939
12940 \begin_layout LyX-Code
12941 %
12942 \end_layout
12943
12944 \begin_layout LyX-Code
12945 %
12946 \backslash
12947 onlynotes{
12948 \backslash
12949 notes}
12950 \end_layout
12951
12952 \begin_layout Standard
12953 One final thing: I created this class to support the \SpecialChar LaTeX2e
12954  
12955 \begin_inset Quotes eld
12956 \end_inset
12957
12958
12959 \noun on
12960 Sli\SpecialChar TeX
12961
12962 \noun default
12963  emulation
12964 \begin_inset Quotes erd
12965 \end_inset
12966
12967  class, one of the built-in \SpecialChar LaTeX2e
12968  classes.
12969  Neither I nor the rest of the \SpecialChar LyX
12970  Team endorse or oppose the use of this built-in
12971  slide class.
12972  It's here if you want it or need it.
12973  There exist other \SpecialChar LaTeX2e
12974  classes for creating presentations, such as the 
12975 \family sans
12976 Foils
12977 \family default
12978  class [see section
12979 \begin_inset space ~
12980 \end_inset
12981
12982
12983 \begin_inset CommandInset ref
12984 LatexCommand ref
12985 reference "sec:foiltex"
12986
12987 \end_inset
12988
12989 ] or the 
12990 \begin_inset Quotes eld
12991 \end_inset
12992
12993
12994 \family typewriter
12995 seminar
12996 \family default
12997
12998 \begin_inset Quotes erd
12999 \end_inset
13000
13001  package [present on some \SpecialChar TeX
13002  distributions].
13003  The latter is not yet supported under \SpecialChar LyX
13004 .
13005 \begin_inset Foot
13006 status collapsed
13007
13008 \begin_layout Plain Layout
13009 Perhaps you can take on the task\SpecialChar ldots
13010
13011 \end_layout
13012
13013 \end_inset
13014
13015  I know nothing about these other classes.
13016  Try them out to see what sort of alternative they provide.
13017 \end_layout
13018
13019 \begin_layout Chapter
13020
13021 \change_inserted 893223064 1464851900
13022 Modules
13023 \end_layout
13024
13025 \begin_layout Standard
13026
13027 \change_inserted 893223064 1464851910
13028 This is a holder for prepared text.
13029 \end_layout
13030
13031 \begin_layout Chapter
13032 Page layout
13033 \end_layout
13034
13035 \begin_layout Standard
13036
13037 \change_inserted 893223064 1464851945
13038 This is a holder for prepared text.
13039 \end_layout
13040
13041 \begin_layout Section
13042 Special features
13043 \end_layout
13044
13045 \begin_layout Standard
13046 You can do everything with \SpecialChar LyX
13047  that you can do with \SpecialChar LaTeX
13048 .
13049  However, \SpecialChar LyX
13050  cannot support every \SpecialChar LaTeX
13051  feature directly.
13052  But you can always use \SpecialChar TeX
13053  Code.
13054  This chapter shows you some more special things you might want to use.
13055  For other special things you can do with figures, tables, floats, boxes
13056  and notes, have a look at the 
13057 \emph on
13058 Embedded
13059 \begin_inset space ~
13060 \end_inset
13061
13062 Objects
13063 \emph default
13064  manual.
13065 \end_layout
13066
13067 \begin_layout Section
13068 Fancy Headers and Footers
13069 \end_layout
13070
13071 \begin_layout Standard
13072 The default page layout is rather plain; for an 
13073 \begin_inset Flex Code
13074 status collapsed
13075
13076 \begin_layout Plain Layout
13077 article
13078 \end_layout
13079
13080 \end_inset
13081
13082  document class, all you get is a centered page number at the bottom of
13083  the page.
13084  This document uses KOMA-script's book class, so it appears to be a bit
13085  fancier.
13086  But to really put on a show, you need to set the document page style to
13087  
13088 \begin_inset Quotes eld
13089 \end_inset
13090
13091 fancy
13092 \begin_inset Quotes erd
13093 \end_inset
13094
13095 , as mentioned in the 
13096 \emph on
13097 User Guide
13098 \emph default
13099 .
13100  This section describes the \SpecialChar LaTeX
13101  code you need to insert in your \SpecialChar LaTeX
13102  preamble in
13103  order to get the desired effects.
13104 \end_layout
13105
13106 \begin_layout Standard
13107 For more information on fancy headers, see the 
13108 \begin_inset Flex Code
13109 status collapsed
13110
13111 \begin_layout Plain Layout
13112 fancyhdr
13113 \end_layout
13114
13115 \end_inset
13116
13117  package documentation.
13118  (
13119 \begin_inset Flex URL
13120 status collapsed
13121
13122 \begin_layout Plain Layout
13123
13124 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
13125 \end_layout
13126
13127 \end_inset
13128
13129 )
13130 \end_layout
13131
13132 \begin_layout Standard
13133 The page header is divided into three fields, not surprisingly labeled 
13134 \begin_inset Quotes eld
13135 \end_inset
13136
13137 left
13138 \begin_inset Quotes erd
13139 \end_inset
13140
13141
13142 \begin_inset Quotes eld
13143 \end_inset
13144
13145 center
13146 \begin_inset Quotes erd
13147 \end_inset
13148
13149 , and 
13150 \begin_inset Quotes eld
13151 \end_inset
13152
13153 right
13154 \begin_inset Quotes erd
13155 \end_inset
13156
13157 .
13158  The footer is also divided into these three fields.
13159  The \SpecialChar LaTeX
13160  commands to set these fields in the simplest manner are 
13161 \begin_inset Flex Code
13162 status collapsed
13163
13164 \begin_layout Plain Layout
13165
13166 \backslash
13167 lhead
13168 \end_layout
13169
13170 \end_inset
13171
13172
13173 \begin_inset Flex Code
13174 status collapsed
13175
13176 \begin_layout Plain Layout
13177
13178 \backslash
13179 chead
13180 \end_layout
13181
13182 \end_inset
13183
13184
13185 \begin_inset Flex Code
13186 status collapsed
13187
13188 \begin_layout Plain Layout
13189
13190 \backslash
13191 rhead
13192 \end_layout
13193
13194 \end_inset
13195
13196
13197 \begin_inset Flex Code
13198 status collapsed
13199
13200 \begin_layout Plain Layout
13201
13202 \backslash
13203 lfoot
13204 \end_layout
13205
13206 \end_inset
13207
13208 , etc.
13209  Suppose you wish to put your name in the upper left hand corner of each
13210  page.
13211  Simply insert the following command in the preamble: 
13212 \end_layout
13213
13214 \begin_layout Standard
13215
13216 \family typewriter
13217
13218 \backslash
13219 lhead{John Q.
13220  DocWriter}
13221 \end_layout
13222
13223 \begin_layout Standard
13224 You will now see your name in the upper left.
13225  If a field has a default entry that you would like to get rid of (often
13226  the page number appears in the central footer) simply include a command
13227  with a blank argument, e.
13228 \begin_inset space \thinspace{}
13229 \end_inset
13230
13231 g.:
13232 \end_layout
13233
13234 \begin_layout Standard
13235
13236 \family typewriter
13237
13238 \backslash
13239 cfoot{}
13240 \end_layout
13241
13242 \begin_layout Standard
13243 Let's get really fancy: lets put the section number with the word 
13244 \begin_inset Quotes eld
13245 \end_inset
13246
13247 Section
13248 \begin_inset Quotes erd
13249 \end_inset
13250
13251  (e.
13252 \begin_inset space \thinspace{}
13253 \end_inset
13254
13255 g.
13256 \begin_inset space \space{}
13257 \end_inset
13258
13259 Section 3) in the upper left, the page number (e.
13260 \begin_inset space \thinspace{}
13261 \end_inset
13262
13263 g.
13264 \begin_inset space \space{}
13265 \end_inset
13266
13267 Page 4) in the upper right, your name in the lower left, and the date in
13268  the lower right.
13269  The following commands should now appear in the preamble:
13270 \end_layout
13271
13272 \begin_layout Standard
13273
13274 \family typewriter
13275
13276 \backslash
13277 lhead{Section 
13278 \backslash
13279 thesection}
13280 \end_layout
13281
13282 \begin_layout Standard
13283
13284 \family typewriter
13285
13286 \backslash
13287 chead{}
13288 \end_layout
13289
13290 \begin_layout Standard
13291
13292 \family typewriter
13293
13294 \backslash
13295 rhead{Page 
13296 \backslash
13297 thepage}
13298 \end_layout
13299
13300 \begin_layout Standard
13301
13302 \family typewriter
13303
13304 \backslash
13305 lfoot{John Q.
13306  DocWriter}
13307 \end_layout
13308
13309 \begin_layout Standard
13310
13311 \family typewriter
13312
13313 \backslash
13314 cfoot{}
13315 \end_layout
13316
13317 \begin_layout Standard
13318
13319 \family typewriter
13320
13321 \backslash
13322 rfoot{
13323 \backslash
13324 today}
13325 \end_layout
13326
13327 \begin_layout Standard
13328 The commands 
13329 \begin_inset Flex Code
13330 status collapsed
13331
13332 \begin_layout Plain Layout
13333
13334 \backslash
13335 thesection
13336 \end_layout
13337
13338 \end_inset
13339
13340  and 
13341 \begin_inset Flex Code
13342 status collapsed
13343
13344 \begin_layout Plain Layout
13345
13346 \backslash
13347 thepage
13348 \end_layout
13349
13350 \end_inset
13351
13352  access \SpecialChar LaTeX
13353 's section and page counters, and so print out the current section
13354  and page numbers.
13355  
13356 \begin_inset Flex Code
13357 status collapsed
13358
13359 \begin_layout Plain Layout
13360
13361 \backslash
13362 today
13363 \end_layout
13364
13365 \end_inset
13366
13367  simply prints out today's date.
13368 \end_layout
13369
13370 \begin_layout Standard
13371 The thicknesses of the horizontal rules drawn beneath the header and above
13372  the footer can also be modified.
13373  If you don't want one of the rules, set its thickness to 0.
13374  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
13375  Use commands
13376 \family typewriter
13377  
13378 \family default
13379 like 
13380 \begin_inset Flex Code
13381 status collapsed
13382
13383 \begin_layout Plain Layout
13384
13385 \backslash
13386 renewcommand{
13387 \backslash
13388 headrulewidth}{0.4pt}
13389 \end_layout
13390
13391 \end_inset
13392
13393  and 
13394 \begin_inset Flex Code
13395 status collapsed
13396
13397 \begin_layout Plain Layout
13398
13399 \backslash
13400 renewcommand{
13401 \backslash
13402 footrulewidth}{0.4pt}
13403 \end_layout
13404
13405 \end_inset
13406
13407  to set the thicknesses.
13408 \end_layout
13409
13410 \begin_layout Standard
13411 You can switch the header/footer settings on and off for individual pages
13412  using commands like 
13413 \begin_inset Flex Code
13414 status collapsed
13415
13416 \begin_layout Plain Layout
13417
13418 \backslash
13419 thispagestyle{empty}
13420 \end_layout
13421
13422 \end_inset
13423
13424
13425 \begin_inset Flex Code
13426 status collapsed
13427
13428 \begin_layout Plain Layout
13429
13430 \backslash
13431 thispagestyle{plain}
13432 \end_layout
13433
13434 \end_inset
13435
13436 , and 
13437 \begin_inset Flex Code
13438 status collapsed
13439
13440 \begin_layout Plain Layout
13441
13442 \backslash
13443 thispagestyle{fancy}
13444 \end_layout
13445
13446 \end_inset
13447
13448 .
13449  Simply insert them in the text on the page you want changed and mark them
13450  as \SpecialChar TeX
13451  code.
13452  In fact, title pages are marked as plain by default, while following pages
13453  are marked fancy when using the global fancy setting.
13454 \end_layout
13455
13456 \begin_layout Standard
13457 As a final example, it is possible to include an image in the header or
13458  footer.
13459  Suppose you want to put a company logo in the upper lefthand corner.
13460  You might try something like
13461 \end_layout
13462
13463 \begin_layout Standard
13464
13465 \family typewriter
13466
13467 \backslash
13468 lhead{
13469 \backslash
13470 resizebox{1in}{!}{
13471 \backslash
13472 includegraphics{logo.eps}}}
13473 \end_layout
13474
13475 \begin_layout Standard
13476 \noindent
13477 (you may need to preface this with 
13478 \begin_inset Flex Code
13479 status collapsed
13480
13481 \begin_layout Plain Layout
13482 \noindent
13483
13484 \backslash
13485 usepackage{graphics}
13486 \end_layout
13487
13488 \end_inset
13489
13490  if you don't include graphics elsewhere in your document).
13491 \end_layout
13492
13493 \begin_layout Section
13494 Multiple Text Columns
13495 \end_layout
13496
13497 \begin_layout Standard
13498 This feature is independent of the option 
13499 \family sans
13500 Two-column document
13501 \family default
13502  in the document settings under 
13503 \family sans
13504 Text Layout
13505 \family default
13506 .
13507  If you want to have 2
13508 \begin_inset space ~
13509 \end_inset
13510
13511 columns for the whole document, it is recommended to use the 
13512 \family sans
13513 Two-column document
13514 \family default
13515  option.
13516  For all other cases use this feature.
13517 \end_layout
13518
13519 \begin_layout Standard
13520 To use multiple text columns in your document, you have to load the module
13521  
13522 \family sans
13523 Multiple Columns
13524 \family default
13525  (menu 
13526 \family sans
13527 Document\SpecialChar menuseparator
13528 Settings\SpecialChar menuseparator
13529 Modules
13530 \family default
13531 ) and must have the \SpecialChar LaTeX
13532 -package 
13533 \series bold
13534 multicol
13535 \series default
13536  installed.
13537 \end_layout
13538
13539 \begin_layout Standard
13540 Footnotes within multiple columns will be placed at the bottom of the page
13541  and not under each column.
13542  Within the different columns you can use everything, with the limitation
13543  that for floats you need to use the float option 
13544 \family sans
13545 Span columns
13546 \family default
13547 .
13548 \end_layout
13549
13550 \begin_layout Subsection
13551 Basics
13552 \end_layout
13553
13554 \begin_layout Standard
13555 If you want to have 2
13556 \begin_inset space ~
13557 \end_inset
13558
13559 columns in your text, insert a multicolumn inset via the menu 
13560 \family sans
13561 Insert\SpecialChar menuseparator
13562 Custom
13563 \begin_inset space ~
13564 \end_inset
13565
13566 Insets\SpecialChar menuseparator
13567 Multiple
13568 \begin_inset space ~
13569 \end_inset
13570
13571 Columns
13572 \family default
13573  where the columns should start.
13574  Write all text that should be printed in 2
13575 \begin_inset space ~
13576 \end_inset
13577
13578 columns into this inset.
13579 \end_layout
13580
13581 \begin_layout Standard
13582 Here is an example:
13583 \end_layout
13584
13585 \begin_layout Standard
13586 \noindent
13587 \begin_inset Flex Multiple Columns
13588 status open
13589
13590 \begin_layout Plain Layout
13591 \noindent
13592
13593 \series bold
13594 \size small
13595 The Adventure of the Empty House
13596 \series default
13597
13598 \begin_inset Newline newline
13599 \end_inset
13600
13601 by Sir Arthur Conan Doyle
13602 \end_layout
13603
13604 \begin_layout Plain Layout
13605
13606 \size small
13607 It was in the spring of the year 1894 that all London was interested, and
13608  the fashionable world dismayed, by the murder of the Honourable Ronald
13609  Adair under most unusual and inexplicable circumstances.
13610  The public has already learned those particulars of the crime which came
13611  out in the police investigation, but a good deal was suppressed upon that
13612  occasion, since the case for the prosecution was so overwhelmingly strong
13613  that it was not necessary to bring forward all the facts.
13614  Only now, at the end of nearly ten years, am I allowed to supply those
13615  missing links which make up the whole of that remarkable chain.
13616  The crime was of interest in itself, but that interest was as nothing to
13617  me compared to the inconceivable sequel, which afforded me the greatest
13618  shock and surprise of any event in my adventurous life.
13619  Even now, after this long interval, I find myself thrilling as I think
13620  of it, and feeling once more that sudden flood of joy, amazement, and increduli
13621 ty which utterly submerged my mind.
13622  Let me say to that public, which has shown some interest in those glimpses
13623  which I have occasionally given them of the thoughts and actions of a very
13624  remarkable man, that they are not to blame me if I have not shared my knowledge
13625  with them, for I should have considered it my first duty to do so, had
13626  I not been barred by a positive prohibition from his own lips, which was
13627  only withdrawn upon the third of last month.
13628 \end_layout
13629
13630 \end_inset
13631
13632
13633 \end_layout
13634
13635 \begin_layout Standard
13636 To get 3 or more columns, set the cursor into the multicolumn inset and
13637  use the menu 
13638 \family sans
13639 Insert\SpecialChar menuseparator
13640 Number
13641 \begin_inset space ~
13642 \end_inset
13643
13644 of
13645 \begin_inset space ~
13646 \end_inset
13647
13648 Columns
13649 \family default
13650 .
13651  The number of the desired columns is written into that inset (for 3
13652 \begin_inset space ~
13653 \end_inset
13654
13655 columns write 
13656 \begin_inset Quotes eld
13657 \end_inset
13658
13659 3
13660 \begin_inset Quotes erd
13661 \end_inset
13662
13663 ).
13664 \begin_inset Newline newline
13665 \end_inset
13666
13667 Here is an example with 3
13668 \begin_inset space ~
13669 \end_inset
13670
13671 columns:
13672 \end_layout
13673
13674 \begin_layout Standard
13675 \begin_inset Flex Multiple Columns
13676 status open
13677
13678 \begin_layout Plain Layout
13679
13680 \size footnotesize
13681 \begin_inset Argument 1
13682 status open
13683
13684 \begin_layout Plain Layout
13685 3
13686 \end_layout
13687
13688 \end_inset
13689
13690 It can be imagined that my close intimacy with Sherlock Holmes had interested
13691  me deeply in crime, and that after his disappearance I never failed to
13692  read with care the various problems which came before the public.
13693  And I even attempted, more than once, for my own private satisfaction,
13694  to employ his methods in their solution, though with indifferent success.
13695  There was none, however, which appealed to me like this tragedy of Ronald
13696  Adair.
13697  As I read the evidence at the inquest, which led up to a verdict of willful
13698  murder against some person or persons unknown, I realized more clearly
13699  than I had ever done the loss which the community had sustained by the
13700  death of Sherlock Holmes.
13701  There were points about this strange business which would, I was sure,
13702  have specially appealed to him, and the efforts of the police would have
13703  been supplemented, or more probably anticipated, by the trained observation
13704  and the alert mind of the first criminal agent in Europe.
13705  All day, as I drove upon my round, I turned over the case in my mind and
13706  found no explanation which appeared to me to be adequate.
13707  At the risk of telling a twice-told tale, I will recapitulate the facts
13708  as they were known to the public at the conclusion of the inquest.
13709 \end_layout
13710
13711 \end_inset
13712
13713
13714 \end_layout
13715
13716 \begin_layout Standard
13717 You can have up to 10
13718 \begin_inset space ~
13719 \end_inset
13720
13721 columns if you want to, but that might not be very pleasant for the readers
13722  of your document.
13723 \end_layout
13724
13725 \begin_layout Standard
13726 \begin_inset Newpage newpage
13727 \end_inset
13728
13729
13730 \end_layout
13731
13732 \begin_layout Subsection
13733 Columns inside Columns
13734 \end_layout
13735
13736 \begin_layout Standard
13737 You can also have columns inside columns:
13738 \end_layout
13739
13740 \begin_layout Standard
13741 \begin_inset Flex Multiple Columns
13742 status open
13743
13744 \begin_layout Plain Layout
13745
13746 \size footnotesize
13747 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
13748  at that time governor of one of the Australian colonies.
13749  Adair's mother had returned from Australia to undergo the operation for
13750  cataract, and she, her son Ronald, and her daughter Hilda were living together
13751  at 427 Park Lane.
13752 \end_layout
13753
13754 \begin_layout Plain Layout
13755 \begin_inset Flex Multiple Columns
13756 status open
13757
13758 \begin_layout Plain Layout
13759
13760 \size footnotesize
13761 The youth moved in the best society–had, so far as was known, no enemies
13762  and no particular vices.
13763  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
13764  had been broken off by mutual consent some months before, and there was
13765  no sign that it had left any very profound feeling behind it.
13766  For the rest {sic} the man's life moved in a narrow and conventional circle,
13767  for his habits were quiet and his nature unemotional.
13768  Yet it was upon this easy-going young aristocrat that death came, in most
13769  strange and unexpected form, between the hours of ten and eleven-twenty
13770  on the night of March 30, 1894.
13771 \end_layout
13772
13773 \end_inset
13774
13775
13776 \end_layout
13777
13778 \begin_layout Plain Layout
13779
13780 \size footnotesize
13781 Ronald Adair was fond of cards–playing continually, but never for such stakes
13782  as would hurt him.
13783  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
13784  It was shown that, after dinner on the day of his death, he had played
13785  a rubber of whist at the latter club.
13786  He had also played there in the afternoon.
13787
13788 \size default
13789  
13790 \size footnotesize
13791 The evidence of those who had played with him– Mr.
13792  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
13793  and that there was a fairly equal fall of the cards.
13794  Adair might have lost five pounds, but not more.
13795  His fortune was a considerable one, and such a loss could not in any way
13796  affect him.
13797  He had played nearly every day at one club or other, but he was a cautious
13798  player, and usually rose a winner.
13799  It came out in evidence that, in partnership with Colonel Moran, he had
13800  actually won as much as four hundred and twenty pounds in a sitting, some
13801  weeks before, from Godfrey Milner and Lord Balmoral.
13802  So much for his recent history as it came out at the inquest.
13803 \end_layout
13804
13805 \end_inset
13806
13807
13808 \end_layout
13809
13810 \begin_layout Subsection
13811 Advanced Examples
13812 \end_layout
13813
13814 \begin_layout Standard
13815 The examples in this section show some more special features of multiple
13816  columns.
13817 \end_layout
13818
13819 \begin_layout Standard
13820 For more features of multiple columns, have a look at the documentation
13821  of the \SpecialChar LaTeX
13822 -package 
13823 \series bold
13824 multicol
13825 \series default
13826
13827 \begin_inset CommandInset citation
13828 LatexCommand cite
13829 key "multicol"
13830
13831 \end_inset
13832
13833 .
13834 \end_layout
13835
13836 \begin_layout Subsubsection
13837 Preface
13838 \end_layout
13839
13840 \begin_layout Standard
13841 To add a preface text for multiple columns, set the cursor into the multicolumn
13842  inset and use the menu 
13843 \family sans
13844 Insert\SpecialChar menuseparator
13845 Preface
13846 \family default
13847 .
13848  Write your preface text into that inset.
13849 \begin_inset Newline newline
13850 \end_inset
13851
13852 This is an example with some preface text:
13853 \end_layout
13854
13855 \begin_layout Standard
13856 \begin_inset VSpace bigskip
13857 \end_inset
13858
13859
13860 \end_layout
13861
13862 \begin_layout Standard
13863 \begin_inset Flex Multiple Columns
13864 status open
13865
13866 \begin_layout Plain Layout
13867 \begin_inset Argument 2
13868 status open
13869
13870 \begin_layout Plain Layout
13871 And the story continues and continues and continues and continues\SpecialChar ldots
13872
13873 \end_layout
13874
13875 \end_inset
13876
13877
13878 \size small
13879 On the evening of the crime, he returned from the club exactly at ten.
13880  His mother and sister were out spending the evening with a relation.
13881  The servant deposed that she heard him enter the front room on the second
13882  floor, generally used as his sitting-room.
13883  She had lit a fire there, and as it smoked she had opened the window.
13884  No sound was heard from the room until eleven-twenty, the hour of the return
13885  of Lady Maynooth and her daughter.
13886  Desiring to say good-night, she attempted to enter her son's room.
13887  The door was locked on the inside, and no answer could be got to their
13888  cries and knocking.
13889  Help was obtained, and the door forced.
13890  The unfortunate young man was found lying near the table.
13891  His head had been horribly mutilated by an expanding revolver bullet, but
13892  no weapon of any sort was to be found in the room.
13893 \end_layout
13894
13895 \end_inset
13896
13897
13898 \end_layout
13899
13900 \begin_layout Standard
13901 You can also use a section heading as the preface if you use a section command
13902  as \SpecialChar TeX
13903  Code.
13904  For example the command
13905 \end_layout
13906
13907 \begin_layout Standard
13908
13909 \series bold
13910
13911 \backslash
13912 subsection{subsection title}
13913 \end_layout
13914
13915 \begin_layout Standard
13916 creates a subsection.
13917  In this example the preface is a subsubsection:
13918 \end_layout
13919
13920 \begin_layout Standard
13921 \begin_inset Flex Multiple Columns
13922 status open
13923
13924 \begin_layout Plain Layout
13925 \begin_inset Argument 2
13926 status open
13927
13928 \begin_layout Plain Layout
13929 \begin_inset ERT
13930 status collapsed
13931
13932 \begin_layout Plain Layout
13933
13934
13935 \backslash
13936 subsubsection{
13937 \end_layout
13938
13939 \end_inset
13940
13941 This is a subsubsection heading as a preface
13942 \begin_inset ERT
13943 status collapsed
13944
13945 \begin_layout Plain Layout
13946
13947 }
13948 \end_layout
13949
13950 \end_inset
13951
13952
13953 \end_layout
13954
13955 \end_inset
13956
13957
13958 \size small
13959 A minute examination of the circumstances served only to make the case more
13960  complex.
13961  In the first place, no reason could be given why the young man should have
13962  fastened the door upon the inside.
13963  There was the possibility that the murderer had done this, and had afterwards
13964  escaped by the window.
13965  The drop was at least twenty feet, however, and a bed of crocuses in full
13966  bloom lay beneath.
13967  Neither the flowers nor the earth showed any sign of having been disturbed,
13968  nor were there any marks upon the narrow strip of grass which separated
13969  the house from the road.
13970  Apparently, therefore, it was the young man himself who had fastened the
13971  door.
13972  But how did he come by his death? No one could have climbed up to the window
13973  without leaving traces.
13974  Suppose a man had fired through the window, he would indeed be a remarkable
13975  shot who could with a revolver inflict so deadly a wound.
13976  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
13977  a hundred yards of the house.
13978  No one had heard a shot.
13979 \end_layout
13980
13981 \end_inset
13982
13983
13984 \end_layout
13985
13986 \begin_layout Standard
13987 If there is less vertical space than 6
13988 \begin_inset space ~
13989 \end_inset
13990
13991 text lines is left on the page at the beginning of the multiple columns,
13992  a page break will be inserted before the multiple columns.
13993  Depending on the number of lines of the preface text, you might want to
13994  change this space.
13995  This is done by setting the cursor into the mulitcolumn inset behind the
13996  preface (if there is any) and using the menu 
13997 \family sans
13998 Insert\SpecialChar menuseparator
13999 Space
14000 \begin_inset space ~
14001 \end_inset
14002
14003 Before
14004 \begin_inset space ~
14005 \end_inset
14006
14007 Page
14008 \begin_inset space ~
14009 \end_inset
14010
14011 Break
14012 \family default
14013 .
14014  Insert into that inset the amount of space like e.
14015 \begin_inset space \thinspace{}
14016 \end_inset
14017
14018 g.
14019 \begin_inset space \space{}
14020 \end_inset
14021
14022
14023 \begin_inset Quotes eld
14024 \end_inset
14025
14026 5cm
14027 \begin_inset Quotes erd
14028 \end_inset
14029
14030 .
14031 \begin_inset Newline newline
14032 \end_inset
14033
14034 In this example the space is set to 7
14035 \begin_inset space ~
14036 \end_inset
14037
14038 text lines by using 
14039 \begin_inset Quotes eld
14040 \end_inset
14041
14042 7
14043 \backslash
14044 baselineskip
14045 \begin_inset Quotes erd
14046 \end_inset
14047
14048  (where the command 
14049 \series bold
14050
14051 \backslash
14052 baselineskip
14053 \series default
14054  needs to be inserted as \SpecialChar TeX
14055  code):
14056 \end_layout
14057
14058 \begin_layout Standard
14059 \begin_inset Flex Multiple Columns
14060 status open
14061
14062 \begin_layout Plain Layout
14063 \begin_inset Argument 3
14064 status open
14065
14066 \begin_layout Plain Layout
14067 7
14068 \begin_inset ERT
14069 status collapsed
14070
14071 \begin_layout Plain Layout
14072
14073
14074 \backslash
14075 baselineskip
14076 \end_layout
14077
14078 \end_inset
14079
14080
14081 \end_layout
14082
14083 \end_inset
14084
14085
14086 \size small
14087 On the evening of the crime, he returned from the club exactly at ten.
14088  His mother and sister were out spending the evening with a relation.
14089  The servant deposed that she heard him enter the front room on the second
14090  floor, generally used as his sitting-room.
14091  She had lit a fire there, and as it smoked she had opened the window.
14092  No sound was heard from the room until eleven-twenty, the hour of the return
14093  of Lady Maynooth and her daughter.
14094  Desiring to say good-night, she attempted to enter her son's room.
14095  The door was locked on the inside, and no answer could be got to their
14096  cries and knocking.
14097  Help was obtained, and the door forced.
14098  The unfortunate young man was found lying near the table.
14099  His head had been horribly mutilated by an expanding revolver bullet, but
14100  no weapon of any sort was to be found in the room.
14101 \end_layout
14102
14103 \end_inset
14104
14105
14106 \end_layout
14107
14108 \begin_layout Subsubsection
14109 Surrounding Space
14110 \end_layout
14111
14112 \begin_layout Standard
14113 The amount of space before and after multiple columns can be changed by
14114  changing the length 
14115 \series bold
14116
14117 \backslash
14118 multicolsep
14119 \series default
14120 .
14121  For example the command
14122 \end_layout
14123
14124 \begin_layout Standard
14125
14126 \series bold
14127
14128 \backslash
14129 setlength{
14130 \backslash
14131 multicolsep}{3cm}
14132 \end_layout
14133
14134 \begin_layout Standard
14135 in \SpecialChar TeX
14136  Code changes its value to 3
14137 \begin_inset space \thinspace{}
14138 \end_inset
14139
14140 cm.
14141  The change must be made before the multiple columns' start.
14142  The predefined value is 13
14143 \begin_inset space \thinspace{}
14144 \end_inset
14145
14146 pt.
14147 \end_layout
14148
14149 \begin_layout Standard
14150 For this example 
14151 \series bold
14152
14153 \backslash
14154 multicolsep
14155 \series default
14156  was set to 2.5
14157 \begin_inset space \thinspace{}
14158 \end_inset
14159
14160 cm:
14161 \end_layout
14162
14163 \begin_layout Standard
14164 \begin_inset ERT
14165 status open
14166
14167 \begin_layout Plain Layout
14168
14169
14170 \backslash
14171 setlength{
14172 \backslash
14173 multicolsep}{2.5cm}
14174 \end_layout
14175
14176 \end_inset
14177
14178
14179 \end_layout
14180
14181 \begin_layout Standard
14182 \begin_inset Flex Multiple Columns
14183 status open
14184
14185 \begin_layout Plain Layout
14186
14187 \size small
14188 All day I turned these facts over in my mind, endeavouring to hit upon some
14189  theory which could reconcile them all, and to find that line of least resistanc
14190 e which my poor friend had declared to be the starting-point of every investigat
14191 ion.
14192  I confess that I made little progress.
14193  In the evening I strolled across the Park, and found myself about six o'clock
14194  at the Oxford Street end of Park Lane.
14195  A group of loafers upon the pavements, all staring up at a particular window,
14196  directed me to the house which I had come to see.
14197  A tall, thin man with coloured glasses, whom I strongly suspected of being
14198  a plain-clothes detective, was pointing out some theory of his own, while
14199  the others crowded round to listen to what he said.
14200  I got as near him as I could, but his observations seemed to me to be absurd,
14201  so I withdrew again in some disgust.
14202  As I did so I struck against an elderly, deformed man, who had been behind
14203  me, and I knocked down several books which he was carrying.
14204 \end_layout
14205
14206 \end_inset
14207
14208
14209 \end_layout
14210
14211 \begin_layout Standard
14212 \begin_inset Note Greyedout
14213 status open
14214
14215 \begin_layout Plain Layout
14216
14217 \series bold
14218 Note:
14219 \series default
14220  The values you set with 
14221 \series bold
14222
14223 \backslash
14224 setlength
14225 \series default
14226  will be used for all following multiple columns until you change them again.
14227 \end_layout
14228
14229 \end_inset
14230
14231
14232 \end_layout
14233
14234 \begin_layout Standard
14235 \begin_inset ERT
14236 status collapsed
14237
14238 \begin_layout Plain Layout
14239
14240
14241 \backslash
14242 setlength{
14243 \backslash
14244 multicolsep}{13pt}
14245 \end_layout
14246
14247 \end_inset
14248
14249
14250 \begin_inset Note Note
14251 status collapsed
14252
14253 \begin_layout Plain Layout
14254 go back to the default
14255 \end_layout
14256
14257 \end_inset
14258
14259
14260 \end_layout
14261
14262 \begin_layout Standard
14263 \begin_inset Newpage newpage
14264 \end_inset
14265
14266
14267 \end_layout
14268
14269 \begin_layout Subsubsection
14270 Column Breaks
14271 \end_layout
14272
14273 \begin_layout Standard
14274 A column break can be forced by inserting the command 
14275 \series bold
14276
14277 \backslash
14278 columnbreak{}
14279 \series default
14280  as \SpecialChar TeX
14281  Code to that position in the text where the column should be broken.
14282  Note that this leads in most cases to whitespace in the text.
14283 \begin_inset Newline newline
14284 \end_inset
14285
14286 Here is an example:
14287 \end_layout
14288
14289 \begin_layout Standard
14290 \begin_inset Flex Multiple Columns
14291 status open
14292
14293 \begin_layout Plain Layout
14294
14295 \size small
14296 \begin_inset Quotes eld
14297 \end_inset
14298
14299 You're surprised to see me, sir,
14300 \begin_inset Quotes erd
14301 \end_inset
14302
14303  said he, in a strange, croaking voice.
14304 \end_layout
14305
14306 \begin_layout Plain Layout
14307
14308 \size small
14309 I acknowledged that I was.
14310 \end_layout
14311
14312 \begin_layout Plain Layout
14313
14314 \size small
14315 \begin_inset Quotes eld
14316 \end_inset
14317
14318 Well, I've a conscience, sir, and when I chanced to see you go into this
14319  house, as I came hobbling after you, I thought to myself, I'll just step
14320  in and see that kind gentleman, and tell him that if I was a bit gruff
14321  in my manner there was not any harm meant, and that I am much obliged to
14322  him for picking up my books.
14323 \begin_inset Quotes erd
14324 \end_inset
14325
14326
14327 \end_layout
14328
14329 \begin_layout Plain Layout
14330
14331 \size small
14332 \begin_inset Quotes eld
14333 \end_inset
14334
14335 You make too much of a trifle,
14336 \begin_inset Quotes erd
14337 \end_inset
14338
14339  said I.
14340  
14341 \begin_inset Quotes eld
14342 \end_inset
14343
14344 May I ask how you knew who I was?
14345 \begin_inset Quotes erd
14346 \end_inset
14347
14348  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
14349 \begin_inset ERT
14350 status collapsed
14351
14352 \begin_layout Plain Layout
14353
14354
14355 \backslash
14356 columnbreak{}
14357 \end_layout
14358
14359 \end_inset
14360
14361
14362 \end_layout
14363
14364 \begin_layout Plain Layout
14365
14366 \size small
14367 \begin_inset Quotes eld
14368 \end_inset
14369
14370 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14371  you'll find my little bookshop at the corner of Church Street, and very
14372  happy to see you, I am sure.
14373  Maybe you collect yourself, sir.
14374  Here's 
14375 \noun on
14376 British
14377 \begin_inset space ~
14378 \end_inset
14379
14380 Birds
14381 \noun default
14382 , and 
14383 \noun on
14384 Catullus
14385 \noun default
14386 , and 
14387 \noun on
14388 The Holy War
14389 \noun default
14390 –a bargain, every one of them.
14391  With five volumes you could just fill that gap on that second shelf.
14392  It looks untidy, does it not, sir?
14393 \begin_inset Quotes erd
14394 \end_inset
14395
14396
14397 \end_layout
14398
14399 \end_inset
14400
14401
14402 \end_layout
14403
14404 \begin_layout Subsubsection
14405 Column Separation
14406 \end_layout
14407
14408 \begin_layout Standard
14409 The width of the columns is automatically calculated, but you can modify
14410  the space between the columns.
14411  This is done by changing the length 
14412 \series bold
14413
14414 \backslash
14415 columnsep
14416 \series default
14417 .
14418  Its predefined value is 10
14419 \begin_inset space \thinspace{}
14420 \end_inset
14421
14422 pt.
14423  Here is an example where 
14424 \series bold
14425
14426 \backslash
14427 columnsep
14428 \series default
14429  is set to 3
14430 \begin_inset space \thinspace{}
14431 \end_inset
14432
14433 cm:
14434 \end_layout
14435
14436 \begin_layout Standard
14437 \begin_inset ERT
14438 status open
14439
14440 \begin_layout Plain Layout
14441
14442
14443 \backslash
14444 setlength{
14445 \backslash
14446 columnsep}{3cm}
14447 \end_layout
14448
14449 \end_inset
14450
14451
14452 \end_layout
14453
14454 \begin_layout Standard
14455 \begin_inset Flex Multiple Columns
14456 status open
14457
14458 \begin_layout Plain Layout
14459
14460 \size small
14461 My observations of No.
14462 \begin_inset space \space{}
14463 \end_inset
14464
14465 427 Park Lane did little to clear up the problem in which I was interested.
14466  The house was separated from the street by a low wall and railing, the
14467  whole not more than five feet high.
14468  It was perfectly easy, therefore, for anyone to get into the garden, but
14469  the window was entirely inaccessible, since there was no water pipe or
14470  anything which could help the most active man to climb it.
14471  More puzzled than ever, I retraced my steps to Kensington.
14472  I had not been in my study five minutes when the maid entered to say that
14473  a person desired to see me.
14474  To my astonishment it was none other than my strange old book collector,
14475  his sharp, wizened face peering out from a frame of white hair, and his
14476  precious volumes, a dozen of them at least, wedged under his right arm.
14477 \end_layout
14478
14479 \end_inset
14480
14481
14482 \end_layout
14483
14484 \begin_layout Standard
14485 \begin_inset ERT
14486 status collapsed
14487
14488 \begin_layout Plain Layout
14489
14490
14491 \backslash
14492 setlength{
14493 \backslash
14494 columnsep}{10pt}
14495 \end_layout
14496
14497 \end_inset
14498
14499
14500 \begin_inset Note Note
14501 status collapsed
14502
14503 \begin_layout Plain Layout
14504 go back to the default
14505 \end_layout
14506
14507 \end_inset
14508
14509
14510 \end_layout
14511
14512 \begin_layout Subsubsection
14513 Vertical Lines
14514 \end_layout
14515
14516 \begin_layout Standard
14517 Between the columns a rule with a width of the length 
14518 \series bold
14519
14520 \backslash
14521 columnseprule
14522 \series default
14523  is placed.
14524  If this rule width is set to 0
14525 \begin_inset space \thinspace{}
14526 \end_inset
14527
14528 pt (this is the default), the rule is suppressed.
14529  In the following example the rule is 2
14530 \begin_inset space \thinspace{}
14531 \end_inset
14532
14533 pt wide:
14534 \end_layout
14535
14536 \begin_layout Standard
14537 \begin_inset ERT
14538 status open
14539
14540 \begin_layout Plain Layout
14541
14542
14543 \backslash
14544 setlength{
14545 \backslash
14546 columnseprule}{2pt}
14547 \end_layout
14548
14549 \end_inset
14550
14551
14552 \end_layout
14553
14554 \begin_layout Standard
14555 \begin_inset Flex Multiple Columns
14556 status open
14557
14558 \begin_layout Plain Layout
14559
14560 \size small
14561 \begin_inset Quotes eld
14562 \end_inset
14563
14564 You're surprised to see me, sir,
14565 \begin_inset Quotes erd
14566 \end_inset
14567
14568  said he, in a strange, croaking voice.
14569 \end_layout
14570
14571 \begin_layout Plain Layout
14572
14573 \size small
14574 I acknowledged that I was.
14575 \end_layout
14576
14577 \begin_layout Plain Layout
14578
14579 \size small
14580 \begin_inset Quotes eld
14581 \end_inset
14582
14583 Well, I've a conscience, sir, and when I chanced to see you go into this
14584  house, as I came hobbling after you, I thought to myself, I'll just step
14585  in and see that kind gentleman, and tell him that if I was a bit gruff
14586  in my manner there was not any harm meant, and that I am much obliged to
14587  him for picking up my books.
14588 \begin_inset Quotes erd
14589 \end_inset
14590
14591
14592 \end_layout
14593
14594 \begin_layout Plain Layout
14595
14596 \size small
14597 \begin_inset Quotes eld
14598 \end_inset
14599
14600 You make too much of a trifle,
14601 \begin_inset Quotes erd
14602 \end_inset
14603
14604  said I.
14605  
14606 \begin_inset Quotes eld
14607 \end_inset
14608
14609 May I ask how you knew who I was?
14610 \begin_inset Quotes erd
14611 \end_inset
14612
14613
14614 \end_layout
14615
14616 \begin_layout Plain Layout
14617
14618 \size small
14619 \begin_inset Quotes eld
14620 \end_inset
14621
14622 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14623  you'll find my little bookshop at the corner of Church Street, and very
14624  happy to see you, I am sure.
14625  Maybe you collect yourself, sir.
14626  Here's 
14627 \noun on
14628 British
14629 \begin_inset space ~
14630 \end_inset
14631
14632 Birds
14633 \noun default
14634 , and 
14635 \noun on
14636 Catullus
14637 \noun default
14638 , and 
14639 \noun on
14640 The Holy War
14641 \noun default
14642 –a bargain, every one of them.
14643  With five volumes you could just fill that gap on that second shelf.
14644  It looks untidy, does it not, sir?
14645 \begin_inset Quotes erd
14646 \end_inset
14647
14648
14649 \end_layout
14650
14651 \end_inset
14652
14653
14654 \end_layout
14655
14656 \begin_layout Standard
14657 \begin_inset VSpace defskip
14658 \end_inset
14659
14660
14661 \end_layout
14662
14663 \begin_layout Standard
14664 The rule can be colored by redefining the command 
14665 \series bold
14666
14667 \backslash
14668 columnseprulecolor
14669 \series default
14670 .
14671  This is done by inserting the command
14672 \begin_inset Newline newline
14673 \end_inset
14674
14675
14676 \series bold
14677
14678 \backslash
14679 renewcommand{
14680 \backslash
14681 columnseprulecolor}{
14682 \backslash
14683 color{red}}
14684 \series default
14685
14686 \begin_inset Newline newline
14687 \end_inset
14688
14689 as \SpecialChar TeX
14690  Code before the multicolumn inset.
14691  Replace 
14692 \series bold
14693 red
14694 \series default
14695  in this command by a color of your choice.
14696  You can use all pre- and self-defined colors.
14697  See the 
14698 \emph on
14699 EmbeddedObjects
14700 \emph default
14701  manual, section 
14702 \emph on
14703 Colored
14704 \begin_inset space ~
14705 \end_inset
14706
14707 Tables
14708 \emph default
14709  for more information about pre- and self-defined colors.
14710  To go back to the default color insert the command
14711 \begin_inset Newline newline
14712 \end_inset
14713
14714
14715 \series bold
14716
14717 \backslash
14718 renewcommand{
14719 \backslash
14720 columnseprulecolor}{
14721 \backslash
14722 normalcolor}
14723 \series default
14724
14725 \begin_inset Newline newline
14726 \end_inset
14727
14728 Here is the example with a cyan rule and 1
14729 \begin_inset space \thinspace{}
14730 \end_inset
14731
14732 cm column separation:
14733 \end_layout
14734
14735 \begin_layout Standard
14736 \begin_inset ERT
14737 status open
14738
14739 \begin_layout Plain Layout
14740
14741
14742 \backslash
14743 setlength{
14744 \backslash
14745 columnsep}{1cm}
14746 \end_layout
14747
14748 \begin_layout Plain Layout
14749
14750
14751 \backslash
14752 renewcommand{
14753 \backslash
14754 columnseprulecolor}{
14755 \backslash
14756 color{cyan}}
14757 \end_layout
14758
14759 \end_inset
14760
14761
14762 \end_layout
14763
14764 \begin_layout Standard
14765 \begin_inset Flex Multiple Columns
14766 status open
14767
14768 \begin_layout Plain Layout
14769
14770 \size small
14771 \begin_inset Quotes eld
14772 \end_inset
14773
14774 You're surprised to see me, sir,
14775 \begin_inset Quotes erd
14776 \end_inset
14777
14778  said he, in a strange, croaking voice.
14779 \end_layout
14780
14781 \begin_layout Plain Layout
14782
14783 \size small
14784 I acknowledged that I was.
14785 \end_layout
14786
14787 \begin_layout Plain Layout
14788
14789 \size small
14790 \begin_inset Quotes eld
14791 \end_inset
14792
14793 Well, I've a conscience, sir, and when I chanced to see you go into this
14794  house, as I came hobbling after you, I thought to myself, I'll just step
14795  in and see that kind gentleman, and tell him that if I was a bit gruff
14796  in my manner there was not any harm meant, and that I am much obliged to
14797  him for picking up my books.
14798 \begin_inset Quotes erd
14799 \end_inset
14800
14801
14802 \end_layout
14803
14804 \begin_layout Plain Layout
14805
14806 \size small
14807 \begin_inset Quotes eld
14808 \end_inset
14809
14810 You make too much of a trifle,
14811 \begin_inset Quotes erd
14812 \end_inset
14813
14814  said I.
14815  
14816 \begin_inset Quotes eld
14817 \end_inset
14818
14819 May I ask how you knew who I was?
14820 \begin_inset Quotes erd
14821 \end_inset
14822
14823
14824 \end_layout
14825
14826 \begin_layout Plain Layout
14827
14828 \size small
14829 \begin_inset Quotes eld
14830 \end_inset
14831
14832 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
14833  you'll find my little bookshop at the corner of Church Street, and very
14834  happy to see you, I am sure.
14835  Maybe you collect yourself, sir.
14836  Here's 
14837 \noun on
14838 British
14839 \begin_inset space ~
14840 \end_inset
14841
14842 Birds
14843 \noun default
14844 , and 
14845 \noun on
14846 Catullus
14847 \noun default
14848 , and 
14849 \noun on
14850 The Holy War
14851 \noun default
14852 –a bargain, every one of them.
14853  With five volumes you could just fill that gap on that second shelf.
14854  It looks untidy, does it not, sir?
14855 \begin_inset Quotes erd
14856 \end_inset
14857
14858
14859 \end_layout
14860
14861 \end_inset
14862
14863
14864 \end_layout
14865
14866 \begin_layout Standard
14867 \begin_inset ERT
14868 status collapsed
14869
14870 \begin_layout Plain Layout
14871
14872
14873 \backslash
14874 setlength{
14875 \backslash
14876 columnseprule}{0pt}
14877 \end_layout
14878
14879 \begin_layout Plain Layout
14880
14881
14882 \backslash
14883 renewcommand{
14884 \backslash
14885 columnseprulecolor}{
14886 \backslash
14887 normalcolor}
14888 \end_layout
14889
14890 \end_inset
14891
14892
14893 \begin_inset Note Note
14894 status collapsed
14895
14896 \begin_layout Plain Layout
14897 go back to the default
14898 \end_layout
14899
14900 \end_inset
14901
14902
14903 \end_layout
14904
14905 \begin_layout Chapter
14906 Text formatting
14907 \end_layout
14908
14909 \begin_layout Section
14910 Non-standard Paragraph Shapes
14911 \end_layout
14912
14913 \begin_layout Standard
14914 \noindent
14915 \SpecialChar LaTeX
14916  as well as any other text processor uses by default rectangular paragraphs.
14917  For special cases like for example posters, invitation cards or poems you
14918  can modify the paragraph shape to one of your choice.
14919  This can be done by using the \SpecialChar LaTeX
14920 -package 
14921 \series bold
14922 shapepar
14923 \series default
14924  which is loaded by using in the document settings the module 
14925 \family sans
14926 Custom paragraph shapes
14927 \family default
14928 .
14929 \end_layout
14930
14931 \begin_layout Subsection
14932 Predefined shapes
14933 \end_layout
14934
14935 \begin_layout Standard
14936
14937 \series bold
14938 shapepar
14939 \series default
14940  provides the following shapes:
14941 \end_layout
14942
14943 \begin_layout Standard
14944 \begin_inset Tabular
14945 <lyxtabular version="3" rows="13" columns="3">
14946 <features booktabs="true" islongtable="true" longtabularalignment="center">
14947 <column alignment="center" valignment="middle" width="16col%">
14948 <column alignment="center" valignment="middle" width="40col%">
14949 <column alignment="center" valignment="middle" width="35col%">
14950 <row endhead="true">
14951 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
14952 \begin_inset Text
14953
14954 \begin_layout Plain Layout
14955 Name
14956 \end_layout
14957
14958 \end_inset
14959 </cell>
14960 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
14961 \begin_inset Text
14962
14963 \begin_layout Plain Layout
14964 Description
14965 \end_layout
14966
14967 \end_inset
14968 </cell>
14969 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
14970 \begin_inset Text
14971
14972 \begin_layout Plain Layout
14973 Annotation
14974 \end_layout
14975
14976 \end_inset
14977 </cell>
14978 </row>
14979 <row>
14980 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
14981 \begin_inset Text
14982
14983 \begin_layout Plain Layout
14984 CDlabel
14985 \end_layout
14986
14987 \end_inset
14988 </cell>
14989 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
14990 \begin_inset Text
14991
14992 \begin_layout Plain Layout
14993 Circle with circular hole (in the size of a CD/DVD)
14994 \end_layout
14995
14996 \end_inset
14997 </cell>
14998 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
14999 \begin_inset Text
15000
15001 \begin_layout Plain Layout
15002 Cannot be scaled, take care there is not too much text
15003 \end_layout
15004
15005 \end_inset
15006 </cell>
15007 </row>
15008 <row>
15009 <cell alignment="center" valignment="top" topline="true" usebox="none">
15010 \begin_inset Text
15011
15012 \begin_layout Plain Layout
15013 Circle
15014 \end_layout
15015
15016 \end_inset
15017 </cell>
15018 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15019 \begin_inset Text
15020
15021 \begin_layout Plain Layout
15022 Circle
15023 \end_layout
15024
15025 \end_inset
15026 </cell>
15027 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15028 \begin_inset Text
15029
15030 \begin_layout Plain Layout
15031 Fragile, calculation might fail
15032 \end_layout
15033
15034 \end_inset
15035 </cell>
15036 </row>
15037 <row>
15038 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15039 \begin_inset Text
15040
15041 \begin_layout Plain Layout
15042 Diamond
15043 \end_layout
15044
15045 \end_inset
15046 </cell>
15047 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15048 \begin_inset Text
15049
15050 \begin_layout Plain Layout
15051 Rhomboid (symbolizing a 
15052 \begin_inset Quotes eld
15053 \end_inset
15054
15055 diamond
15056 \begin_inset Quotes erd
15057 \end_inset
15058
15059 )
15060 \end_layout
15061
15062 \end_inset
15063 </cell>
15064 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15065 \begin_inset Text
15066
15067 \begin_layout Plain Layout
15068 -
15069 \end_layout
15070
15071 \end_inset
15072 </cell>
15073 </row>
15074 <row>
15075 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15076 \begin_inset Text
15077
15078 \begin_layout Plain Layout
15079 Heart
15080 \end_layout
15081
15082 \end_inset
15083 </cell>
15084 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15085 \begin_inset Text
15086
15087 \begin_layout Plain Layout
15088 Heart-like shape
15089 \end_layout
15090
15091 \end_inset
15092 </cell>
15093 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15094 \begin_inset Text
15095
15096 \begin_layout Plain Layout
15097 -
15098 \end_layout
15099
15100 \end_inset
15101 </cell>
15102 </row>
15103 <row>
15104 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15105 \begin_inset Text
15106
15107 \begin_layout Plain Layout
15108 Hexagon
15109 \end_layout
15110
15111 \end_inset
15112 </cell>
15113 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15114 \begin_inset Text
15115
15116 \begin_layout Plain Layout
15117 Hexagon
15118 \end_layout
15119
15120 \end_inset
15121 </cell>
15122 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15123 \begin_inset Text
15124
15125 \begin_layout Plain Layout
15126 -
15127 \end_layout
15128
15129 \end_inset
15130 </cell>
15131 </row>
15132 <row>
15133 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15134 \begin_inset Text
15135
15136 \begin_layout Plain Layout
15137 Nut
15138 \end_layout
15139
15140 \end_inset
15141 </cell>
15142 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15143 \begin_inset Text
15144
15145 \begin_layout Plain Layout
15146 Nut for bolt (hexagon with circular hole)
15147 \end_layout
15148
15149 \end_inset
15150 </cell>
15151 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15152 \begin_inset Text
15153
15154 \begin_layout Plain Layout
15155 -
15156 \end_layout
15157
15158 \end_inset
15159 </cell>
15160 </row>
15161 <row>
15162 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15163 \begin_inset Text
15164
15165 \begin_layout Plain Layout
15166 Square
15167 \end_layout
15168
15169 \end_inset
15170 </cell>
15171 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15172 \begin_inset Text
15173
15174 \begin_layout Plain Layout
15175 Square
15176 \end_layout
15177
15178 \end_inset
15179 </cell>
15180 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15181 \begin_inset Text
15182
15183 \begin_layout Plain Layout
15184 -
15185 \end_layout
15186
15187 \end_inset
15188 </cell>
15189 </row>
15190 <row>
15191 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15192 \begin_inset Text
15193
15194 \begin_layout Plain Layout
15195 Star
15196 \end_layout
15197
15198 \end_inset
15199 </cell>
15200 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15201 \begin_inset Text
15202
15203 \begin_layout Plain Layout
15204 Five-point star
15205 \end_layout
15206
15207 \end_inset
15208 </cell>
15209 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
15210 \begin_inset Text
15211
15212 \begin_layout Plain Layout
15213 -
15214 \end_layout
15215
15216 \end_inset
15217 </cell>
15218 </row>
15219 <row>
15220 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15221 \begin_inset Text
15222
15223 \begin_layout Plain Layout
15224 Candle
15225 \end_layout
15226
15227 \end_inset
15228 </cell>
15229 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15230 \begin_inset Text
15231
15232 \begin_layout Plain Layout
15233 Burning candle
15234 \end_layout
15235
15236 \end_inset
15237 </cell>
15238 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15239 \begin_inset Text
15240
15241 \begin_layout Plain Layout
15242 -
15243 \end_layout
15244
15245 \end_inset
15246 </cell>
15247 </row>
15248 <row>
15249 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15250 \begin_inset Text
15251
15252 \begin_layout Plain Layout
15253 Drop down/up
15254 \end_layout
15255
15256 \end_inset
15257 </cell>
15258 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15259 \begin_inset Text
15260
15261 \begin_layout Plain Layout
15262 Normal/reversed rain drop
15263 \end_layout
15264
15265 \end_inset
15266 </cell>
15267 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15268 \begin_inset Text
15269
15270 \begin_layout Plain Layout
15271 Fragile, calculation might fail
15272 \end_layout
15273
15274 \end_inset
15275 </cell>
15276 </row>
15277 <row>
15278 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15279 \begin_inset Text
15280
15281 \begin_layout Plain Layout
15282 \SpecialChar TeX
15283
15284 \end_layout
15285
15286 \end_inset
15287 </cell>
15288 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
15289 \begin_inset Text
15290
15291 \begin_layout Plain Layout
15292 The \SpecialChar TeX
15293  logo
15294 \end_layout
15295
15296 \end_inset
15297 </cell>
15298 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
15299 \begin_inset Text
15300
15301 \begin_layout Plain Layout
15302 -
15303 \end_layout
15304
15305 \end_inset
15306 </cell>
15307 </row>
15308 <row>
15309 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15310 \begin_inset Text
15311
15312 \begin_layout Plain Layout
15313 Triangle up/down/
15314 \begin_inset Newline newline
15315 \end_inset
15316
15317 left/right
15318 \end_layout
15319
15320 \end_inset
15321 </cell>
15322 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
15323 \begin_inset Text
15324
15325 \begin_layout Plain Layout
15326 Triangles in different orientations
15327 \end_layout
15328
15329 \end_inset
15330 </cell>
15331 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
15332 \begin_inset Text
15333
15334 \begin_layout Plain Layout
15335 -
15336 \end_layout
15337
15338 \end_inset
15339 </cell>
15340 </row>
15341 </lyxtabular>
15342
15343 \end_inset
15344
15345
15346 \end_layout
15347
15348 \begin_layout Standard
15349 To use a shape for your paragraph, simply select it in \SpecialChar LyX
15350 's pull-down box
15351  for environments in the toolbar.
15352 \end_layout
15353
15354 \begin_layout Standard
15355 \begin_inset Newpage newpage
15356 \end_inset
15357
15358
15359 \end_layout
15360
15361 \begin_layout Standard
15362 Here is an example paragraph in the shape of a nut:
15363 \end_layout
15364
15365 \begin_layout Standard
15366 \begin_inset VSpace bigskip
15367 \end_inset
15368
15369
15370 \end_layout
15371
15372 \begin_layout Nut
15373
15374 \lang latin
15375 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15376  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15377  voluptua.
15378  At vero eos et accusam et justo duo dolores et ea rebum.
15379  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15380  sit amet.
15381  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15382  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15383  voluptua.
15384 \end_layout
15385
15386 \begin_layout Standard
15387 \begin_inset VSpace bigskip
15388 \end_inset
15389
15390
15391 \end_layout
15392
15393 \begin_layout Standard
15394 \begin_inset Note Greyedout
15395 status open
15396
15397 \begin_layout Plain Layout
15398
15399 \series bold
15400 Note
15401 \series default
15402 : shapepar paragraphs cannot run over a page break.
15403 \end_layout
15404
15405 \end_inset
15406
15407
15408 \end_layout
15409
15410 \begin_layout Standard
15411 \begin_inset VSpace bigskip
15412 \end_inset
15413
15414
15415 \end_layout
15416
15417 \begin_layout Standard
15418
15419 \series bold
15420 shapepar
15421 \series default
15422  takes care that the shape will always be preserved, no matter how much
15423  text is in the paragraph.
15424  Therefore the paragraph size changes with the amount of contained text.
15425  This can lead to paragraph sizes exceeding the page margins.
15426  To demonstrate the size scaling, here is the same example paragraph but
15427  with twice as much text:
15428 \end_layout
15429
15430 \begin_layout Standard
15431 \begin_inset Newpage newpage
15432 \end_inset
15433
15434
15435 \end_layout
15436
15437 \begin_layout Nut
15438
15439 \lang latin
15440 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15441  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15442  voluptua.
15443  At vero eos et accusam et justo duo dolores et ea rebum.
15444  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15445  sit amet.
15446  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15447  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15448  voluptua.
15449  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15450  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15451  voluptua.
15452  At vero eos et accusam et justo duo dolores et ea rebum.
15453  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15454  sit amet.
15455  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15456  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15457  voluptua.
15458 \end_layout
15459
15460 \begin_layout Standard
15461 \begin_inset VSpace bigskip
15462 \end_inset
15463
15464
15465 \end_layout
15466
15467 \begin_layout Standard
15468 An exception is the shape 
15469 \family sans
15470 CDlabel
15471 \family default
15472 .
15473  It cannot be scaled because it must fit the size of a CD/DVD.
15474  Therefore the amount of text that fits into the shape is limited.
15475 \begin_inset Newline newline
15476 \end_inset
15477
15478 The 
15479 \family sans
15480 drop
15481 \family default
15482  shapes and the 
15483 \family sans
15484 circle
15485 \family default
15486  shape are fragile, meaning that the calculation of their size can fail,
15487  depending on the amount of text.
15488  You will then get the \SpecialChar LaTeX
15489  error 
15490 \begin_inset Quotes eld
15491 \end_inset
15492
15493 Arithmetic overflow
15494 \begin_inset Quotes erd
15495 \end_inset
15496
15497 .
15498  In this case one can try to remove or add some text; if nothing works one
15499  has to use another shape.
15500 \end_layout
15501
15502 \begin_layout Standard
15503 \begin_inset VSpace bigskip
15504 \end_inset
15505
15506
15507 \end_layout
15508
15509 \begin_layout Standard
15510 For shapes with tips you will maybe see that \SpecialChar LaTeX
15511 's hyphenation routine fails
15512  for text in the tips.
15513  Therefore it is often necessary to add hyphenation points 
15514 \family sans
15515 (
15516 \begin_inset Info
15517 type  "shortcut"
15518 arg   "specialchar-insert hyphenation"
15519 \end_inset
15520
15521
15522 \family default
15523 ) to the corresponding text parts.
15524 \end_layout
15525
15526 \begin_layout Standard
15527 \begin_inset VSpace bigskip
15528 \end_inset
15529
15530
15531 \end_layout
15532
15533 \begin_layout Standard
15534 Shapepar paragraphs are either always centered or placed on the page so
15535  that their left border touches the left page margin.
15536  You can therefore not use the paragraph dialog to align such paragraphs.
15537  A solution is to put the paragraph into a minipage or parbox and align
15538  the box.
15539  The problem is hereby to find the right width for the box.
15540  Because if it is too wide and you center the box, the paragraph is not
15541  centered too because it sticks at the left side of the box.
15542  So you might have to play a bit with the width until it fits.
15543  Here are two heart-shaped paragraphs, the first one is not aligned, the
15544  second one is right-aligned:
15545 \end_layout
15546
15547 \begin_layout Standard
15548 \begin_inset Newpage newpage
15549 \end_inset
15550
15551
15552 \end_layout
15553
15554 \begin_layout Heart
15555 \noindent
15556
15557 \lang latin
15558 Lo\SpecialChar softhyphen
15559 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15560  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15561  voluptua.
15562  At vero eos et accusam et justo duo dolores et ea rebum.
15563  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15564  sit amet.
15565 \end_layout
15566
15567 \begin_layout Standard
15568 \begin_inset VSpace bigskip
15569 \end_inset
15570
15571
15572 \end_layout
15573
15574 \begin_layout Standard
15575 \noindent
15576 \align right
15577 \begin_inset Box Frameless
15578 position "t"
15579 hor_pos "c"
15580 has_inner_box 1
15581 inner_pos "t"
15582 use_parbox 1
15583 use_makebox 0
15584 width "42col%"
15585 special "none"
15586 height "1in"
15587 height_special "totalheight"
15588 thickness "0.4pt"
15589 separation "3pt"
15590 shadowsize "4pt"
15591 framecolor "black"
15592 backgroundcolor "none"
15593 status open
15594
15595 \begin_layout Heart
15596 \noindent
15597
15598 \lang latin
15599 Lo\SpecialChar softhyphen
15600 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15601  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15602  voluptua.
15603  At vero eos et accusam et justo duo dolores et ea rebum.
15604  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15605  sit amet.
15606 \end_layout
15607
15608 \end_inset
15609
15610
15611 \end_layout
15612
15613 \begin_layout Subsection
15614 Custom shapes
15615 \end_layout
15616
15617 \begin_layout Standard
15618 You can define any shape you want.
15619  Doing this manually is a lot of work because every coordinate must be specified.
15620  But there is a way to let the computer calculate the coordinates:
15621 \end_layout
15622
15623 \begin_layout Enumerate
15624 Install the program 
15625 \begin_inset CommandInset href
15626 LatexCommand href
15627 name "Jpgfdraw"
15628 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
15629
15630 \end_inset
15631
15632 .
15633 \end_layout
15634
15635 \begin_layout Enumerate
15636 In 
15637 \family sans
15638 Jpgfdraw
15639 \family default
15640  go to the menu 
15641 \family sans
15642 TeX/LaTeX\SpecialChar menuseparator
15643 Settings\SpecialChar menuseparator
15644 Set Normal Size
15645 \family default
15646  and select the font size you are using in your document.
15647  For example this document uses the size 12
15648 \begin_inset space \thinspace{}
15649 \end_inset
15650
15651 pt.
15652 \end_layout
15653
15654 \begin_layout Enumerate
15655 Draw a shape.
15656 \end_layout
15657
15658 \begin_layout Enumerate
15659 Use the menu 
15660 \family sans
15661 TeX/LaTeX\SpecialChar menuseparator
15662 Shapepar
15663 \family default
15664  to export the shape to coordinates.
15665  In the appearing dialog use either the outline of your shape for the coordinate
15666 s or the path itself.
15667 \begin_inset Foot
15668 status collapsed
15669
15670 \begin_layout Plain Layout
15671 For more information see 
15672 \begin_inset CommandInset href
15673 LatexCommand href
15674 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
15675
15676 \end_inset
15677
15678
15679 \end_layout
15680
15681 \end_inset
15682
15683
15684 \end_layout
15685
15686 \begin_layout Standard
15687 The coordinates are written into a \SpecialChar TeX
15688  file.
15689  To use it for your \SpecialChar LyX
15690  document
15691 \end_layout
15692
15693 \begin_layout Enumerate
15694 Place the cursor before the first character of your paragraph (or into a
15695  new empty one).
15696 \end_layout
15697
15698 \begin_layout Enumerate
15699 Open in \SpecialChar LyX
15700  the menu 
15701 \family sans
15702 Insert\SpecialChar menuseparator
15703 File\SpecialChar menuseparator
15704 Child
15705 \begin_inset space ~
15706 \end_inset
15707
15708 Document
15709 \family default
15710 , select the file and use 
15711 \family sans
15712 Input
15713 \family default
15714  as 
15715 \family sans
15716 Include Type.
15717 \end_layout
15718
15719 \begin_layout Standard
15720 \begin_inset VSpace defskip
15721 \end_inset
15722
15723
15724 \end_layout
15725
15726 \begin_layout Standard
15727 \begin_inset Note Greyedout
15728 status open
15729
15730 \begin_layout Plain Layout
15731
15732 \series bold
15733 Note
15734 \series default
15735 : The changed shape only applies to the current paragraph; everything is
15736  reset to normal for the next paragraph.
15737  Therefore the shape definition file must be input into every paragraph
15738  with the desired shape.
15739 \end_layout
15740
15741 \end_inset
15742
15743
15744 \end_layout
15745
15746 \begin_layout Standard
15747 \begin_inset VSpace bigskip
15748 \end_inset
15749
15750
15751 \end_layout
15752
15753 \begin_layout Standard
15754 Here is an example:
15755 \end_layout
15756
15757 \begin_layout Standard
15758 \begin_inset VSpace bigskip
15759 \end_inset
15760
15761
15762 \end_layout
15763
15764 \begin_layout Standard
15765 \begin_inset CommandInset include
15766 LatexCommand input
15767 filename "SpecialParagraphShape.tex"
15768
15769 \end_inset
15770
15771
15772 \lang latin
15773 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15774  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15775  voluptua.
15776  At vero eos et accusam et justo duo dolores et ea rebum.
15777  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
15778  sit amet.
15779  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
15780  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
15781  voluptua.
15782 \end_layout
15783
15784 \begin_layout Standard
15785 \begin_inset VSpace bigskip
15786 \end_inset
15787
15788
15789 \end_layout
15790
15791 \begin_layout Standard
15792
15793 \series bold
15794 A tip:
15795 \series default
15796  to draw complexer shapes in 
15797 \family sans
15798 Jpgfdraw
15799 \family default
15800  you can draw the shape in a program of your choice and import the resulting
15801  image to 
15802 \family sans
15803 Jpgfdraw
15804 \family default
15805 .
15806  Then you only need to draw a line or spline along the outline of the image.
15807 \end_layout
15808
15809 \begin_layout Standard
15810 \begin_inset VSpace bigskip
15811 \end_inset
15812
15813
15814 \end_layout
15815
15816 \begin_layout Standard
15817 The module 
15818 \family sans
15819 Custom paragraph shapes
15820 \family default
15821  also provides the two commands 
15822 \family sans
15823 shapepar
15824 \family default
15825  and 
15826 \family sans
15827 Shapepar
15828 \family default
15829  which can be used to define custom shapes coordinate by coordinate.
15830 \begin_inset Foot
15831 status collapsed
15832
15833 \begin_layout Plain Layout
15834 These commands are internally used for all shapes described here.
15835 \end_layout
15836
15837 \end_inset
15838
15839  For information how these styles are used and about further customization
15840  possibilities, have a look at the documentation of the package 
15841 \series bold
15842 shapepar
15843 \series default
15844
15845 \begin_inset CommandInset citation
15846 LatexCommand cite
15847 key "shapepar"
15848
15849 \end_inset
15850
15851 .
15852 \end_layout
15853
15854 \begin_layout Bibliography
15855 \begin_inset CommandInset bibitem
15856 LatexCommand bibitem
15857 key "multicol"
15858
15859 \end_inset
15860
15861 Documentation of the \SpecialChar LaTeX
15862 -package 
15863 \begin_inset CommandInset href
15864 LatexCommand href
15865 name "multicol"
15866 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
15867
15868 \end_inset
15869
15870
15871 \end_layout
15872
15873 \begin_layout Bibliography
15874 \begin_inset CommandInset bibitem
15875 LatexCommand bibitem
15876 key "shapepar"
15877
15878 \end_inset
15879
15880 Documentation of the \SpecialChar LaTeX
15881 -package 
15882 \begin_inset CommandInset href
15883 LatexCommand href
15884 name "shapepar"
15885 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"
15886
15887 \end_inset
15888
15889
15890 \end_layout
15891
15892 \begin_layout Chapter
15893 Bibliographic databases
15894 \end_layout
15895
15896 \begin_layout Section
15897 Customizing Bibliographies with Bib\SpecialChar TeX
15898
15899 \end_layout
15900
15901 \begin_layout Standard
15902 The most basic information about how to use Bib\SpecialChar TeX
15903  with \SpecialChar LyX
15904  is contained in the
15905  section 
15906 \emph on
15907 Bibliography databases (Bib\SpecialChar TeX
15908 )
15909 \emph default
15910  of the 
15911 \emph on
15912 User's Guide
15913 \emph default
15914 .
15915  The following subsections explain special bibliography features supported
15916  by \SpecialChar LyX
15917 .
15918 \end_layout
15919
15920 \begin_layout Subsection
15921 Alternative Citation Styles
15922 \end_layout
15923
15924 \begin_layout Standard
15925 Standard Bib\SpecialChar TeX
15926  uses numbers (e.
15927 \begin_inset space \thinspace{}
15928 \end_inset
15929
15930 g.
15931 \begin_inset space \space{}
15932 \end_inset
15933
15934
15935 \begin_inset Quotes eld
15936 \end_inset
15937
15938 [12]
15939 \begin_inset Quotes erd
15940 \end_inset
15941
15942 ) to refer to a cited work.
15943  However, in many scientific disciplines, other citation styles are in use.
15944  The most common one is the author-year style (e.
15945 \begin_inset space \thinspace{}
15946 \end_inset
15947
15948 g.
15949 \begin_inset space \space{}
15950 \end_inset
15951
15952
15953 \begin_inset Quotes eld
15954 \end_inset
15955
15956 Knuth 1984a
15957 \begin_inset Quotes erd
15958 \end_inset
15959
15960 ).
15961  \SpecialChar LyX
15962  supports two packages that provide this style, 
15963 \begin_inset Flex Code
15964 status collapsed
15965
15966 \begin_layout Plain Layout
15967 natbib
15968 \end_layout
15969
15970 \end_inset
15971
15972  and 
15973 \begin_inset Flex Code
15974 status collapsed
15975
15976 \begin_layout Plain Layout
15977 jurabib
15978 \end_layout
15979
15980 \end_inset
15981
15982 .
15983  Both packages have their pros and cons, which cannot be listed in detail.
15984  If you only want to have simple author-year (or author-numerical) style,
15985  or if you want to use one of the countless style files for 
15986 \begin_inset Flex Code
15987 status collapsed
15988
15989 \begin_layout Plain Layout
15990 natbib
15991 \end_layout
15992
15993 \end_inset
15994
15995 , then the established 
15996 \begin_inset Flex Code
15997 status collapsed
15998
15999 \begin_layout Plain Layout
16000 natbib
16001 \end_layout
16002
16003 \end_inset
16004
16005  package is probably your choice.
16006  If you need special features like short title references, ibidem etc., you
16007  might consider the 
16008 \begin_inset Flex Code
16009 status collapsed
16010
16011 \begin_layout Plain Layout
16012 jurabib
16013 \end_layout
16014
16015 \end_inset
16016
16017  package.
16018 \end_layout
16019
16020 \begin_layout Standard
16021 The handling of both packages in \SpecialChar LyX
16022  is basically the same.
16023  Go to 
16024 \begin_inset Flex Noun
16025 status collapsed
16026
16027 \begin_layout Plain Layout
16028 Document\SpecialChar menuseparator
16029 Settings
16030 \end_layout
16031
16032 \end_inset
16033
16034  and select under 
16035 \begin_inset Flex Noun
16036 status collapsed
16037
16038 \begin_layout Plain Layout
16039 Bibliography
16040 \end_layout
16041
16042 \end_inset
16043
16044  the option 
16045 \begin_inset Flex Noun
16046 status collapsed
16047
16048 \begin_layout Plain Layout
16049 Natbib
16050 \end_layout
16051
16052 \end_inset
16053
16054  or 
16055 \begin_inset Flex Noun
16056 status collapsed
16057
16058 \begin_layout Plain Layout
16059 Jurabib
16060 \end_layout
16061
16062 \end_inset
16063
16064 .
16065  With both packages, you will get some extra features in the citation dialog
16066  and you can select the style of the reference (
16067 \begin_inset Quotes eld
16068 \end_inset
16069
16070 Knuth 1984
16071 \begin_inset Quotes erd
16072 \end_inset
16073
16074
16075 \begin_inset Quotes eld
16076 \end_inset
16077
16078 Knuth (1984)
16079 \begin_inset Quotes erd
16080 \end_inset
16081
16082
16083 \begin_inset Quotes eld
16084 \end_inset
16085
16086 Knuth, 1984
16087 \begin_inset Quotes erd
16088 \end_inset
16089
16090
16091 \begin_inset Quotes eld
16092 \end_inset
16093
16094 1984
16095 \begin_inset Quotes erd
16096 \end_inset
16097
16098  etc.).
16099  Note that both packages need specifically designed style files.
16100  They both ship their own, but there are lots of additional style files,
16101  and there is even an interactive style file builder
16102 \begin_inset Foot
16103 status collapsed
16104
16105 \begin_layout Plain Layout
16106 See 
16107 \begin_inset Flex URL
16108 status open
16109
16110 \begin_layout Plain Layout
16111
16112 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
16113 \end_layout
16114
16115 \end_inset
16116
16117
16118 \end_layout
16119
16120 \end_inset
16121
16122  for 
16123 \begin_inset Flex Code
16124 status collapsed
16125
16126 \begin_layout Plain Layout
16127 natbib
16128 \end_layout
16129
16130 \end_inset
16131
16132 .
16133 \end_layout
16134
16135 \begin_layout Subsection
16136 Sectioned Bibliographies
16137 \end_layout
16138
16139 \begin_layout Standard
16140 Sometimes you might need to divide your bibliography into several sections.
16141  If you are for instance a historian, the possibility to separate sources
16142  and scientific works is most likely a 
16143 \begin_inset Quotes eld
16144 \end_inset
16145
16146 must have
16147 \begin_inset Quotes erd
16148 \end_inset
16149
16150 .
16151  Unfortunately, Bib\SpecialChar TeX
16152  itself does not allow you to do this.
16153  But with the help of some \SpecialChar LaTeX
16154  packages, Bib\SpecialChar TeX
16155  can be extended to fit your needs.
16156 \end_layout
16157
16158 \begin_layout Standard
16159 \SpecialChar LyX
16160  provides native support for one of these packages, 
16161 \family typewriter
16162 bibtopic
16163 \family default
16164 .
16165 \begin_inset Foot
16166 status collapsed
16167
16168 \begin_layout Plain Layout
16169 Available from 
16170 \begin_inset Flex URL
16171 status open
16172
16173 \begin_layout Plain Layout
16174
16175 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
16176 \end_layout
16177
16178 \end_inset
16179
16180
16181 \end_layout
16182
16183 \end_inset
16184
16185  The advantage of this package (compared to other packages like 
16186 \family typewriter
16187 multibib
16188 \family default
16189 ) is that you don't need to define new citation commands.
16190  Instead, you need to prepare different bibliographic databases which include
16191  the entries for the different sections of the bibliography.
16192  For example: If you want to divide your bibliography into the sections
16193  
16194 \begin_inset Quotes eld
16195 \end_inset
16196
16197 Sources
16198 \begin_inset Quotes erd
16199 \end_inset
16200
16201  and 
16202 \begin_inset Quotes eld
16203 \end_inset
16204
16205 Scientific works
16206 \begin_inset Quotes erd
16207 \end_inset
16208
16209 , you first need to create two bibliographic databases, e.
16210 \begin_inset space \thinspace{}
16211 \end_inset
16212
16213 g.
16214 \begin_inset space \space{}
16215 \end_inset
16216
16217
16218 \begin_inset Flex Code
16219 status collapsed
16220
16221 \begin_layout Plain Layout
16222 sources.bib
16223 \end_layout
16224
16225 \end_inset
16226
16227  and 
16228 \begin_inset Flex Code
16229 status collapsed
16230
16231 \begin_layout Plain Layout
16232 scientific.bib
16233 \end_layout
16234
16235 \end_inset
16236
16237 .
16238  
16239 \end_layout
16240
16241 \begin_layout Standard
16242 Go to 
16243 \begin_inset Flex Noun
16244 status collapsed
16245
16246 \begin_layout Plain Layout
16247 Document\SpecialChar menuseparator
16248 Settings
16249 \end_layout
16250
16251 \end_inset
16252
16253  and check under 
16254 \begin_inset Flex Noun
16255 status collapsed
16256
16257 \begin_layout Plain Layout
16258 Bibliography
16259 \end_layout
16260
16261 \end_inset
16262
16263  the option 
16264 \begin_inset Flex Noun
16265 status collapsed
16266
16267 \begin_layout Plain Layout
16268 Sectioned bibliography
16269 \end_layout
16270
16271 \end_inset
16272
16273 .
16274  Now you can insert multiple Bib\SpecialChar TeX
16275  bibliographies, one for each section of
16276  your bibliography.
16277  Returning to our example: Insert the Bib\SpecialChar TeX
16278  bibliography 
16279 \begin_inset Flex Code
16280 status collapsed
16281
16282 \begin_layout Plain Layout
16283 sources.bib
16284 \end_layout
16285
16286 \end_inset
16287
16288  and a second one for the database 
16289 \begin_inset Flex Code
16290 status collapsed
16291
16292 \begin_layout Plain Layout
16293 scientific.bib
16294 \end_layout
16295
16296 \end_inset
16297
16298 .
16299  You are free to use the same or different styles for each section.
16300  Additionally, you can choose if the bibliography section should contain
16301  
16302 \begin_inset Quotes eld
16303 \end_inset
16304
16305 all cited references
16306 \begin_inset Quotes erd
16307 \end_inset
16308
16309  of the specified database(s) (which is the default), 
16310 \begin_inset Quotes eld
16311 \end_inset
16312
16313 all uncited references
16314 \begin_inset Quotes erd
16315 \end_inset
16316
16317  or even 
16318 \begin_inset Quotes eld
16319 \end_inset
16320
16321 all references
16322 \begin_inset Quotes erd
16323 \end_inset
16324
16325 .
16326  This might be useful if you would like to separate your bibliography into
16327  three sections: 
16328 \begin_inset Quotes eld
16329 \end_inset
16330
16331 Cited sources
16332 \begin_inset Quotes erd
16333 \end_inset
16334
16335
16336 \begin_inset Quotes eld
16337 \end_inset
16338
16339 Uncited sources
16340 \begin_inset Quotes erd
16341 \end_inset
16342
16343 , and 
16344 \begin_inset Quotes eld
16345 \end_inset
16346
16347 Scientific works
16348 \begin_inset Quotes erd
16349 \end_inset
16350
16351 .
16352  The titles for the sections can be added as ordinary sections or subsections.
16353  Since 
16354 \begin_inset Flex Code
16355 status collapsed
16356
16357 \begin_layout Plain Layout
16358 bibtopic
16359 \end_layout
16360
16361 \end_inset
16362
16363  removes the bibliography title, you have to manually re-add that, too (as
16364  a chapter* or section*, for instance).
16365 \end_layout
16366
16367 \begin_layout Subsection
16368 Multiple Bibliographies
16369 \end_layout
16370
16371 \begin_layout Standard
16372 Multiple bibliographies, e.
16373 \begin_inset space \thinspace{}
16374 \end_inset
16375
16376 g.
16377 \begin_inset space \space{}
16378 \end_inset
16379
16380 a bibliography for each section or chapter of the document, are not supported
16381  by Bib\SpecialChar TeX
16382  itself.
16383  But the 
16384 \begin_inset Flex Code
16385 status collapsed
16386
16387 \begin_layout Plain Layout
16388 bibtopic
16389 \end_layout
16390
16391 \end_inset
16392
16393  package, which is used for the creation of sectioned bibliographies in
16394  \SpecialChar LyX
16395  (see the previous section), provides an easy way to solve this task, if
16396  you are willing to use some 
16397 \begin_inset Flex Noun
16398 status collapsed
16399
16400 \begin_layout Plain Layout
16401 \SpecialChar TeX
16402  Code
16403 \end_layout
16404
16405 \end_inset
16406
16407  (see section
16408 \begin_inset space ~
16409 \end_inset
16410
16411
16412 \begin_inset CommandInset ref
16413 LatexCommand ref
16414 reference "sec:Inserting-TeX-Code"
16415
16416 \end_inset
16417
16418 ).
16419 \begin_inset Foot
16420 status collapsed
16421
16422 \begin_layout Plain Layout
16423 An alternative approach is to use the 
16424 \begin_inset Flex Code
16425 status collapsed
16426
16427 \begin_layout Plain Layout
16428 chapterbib
16429 \end_layout
16430
16431 \end_inset
16432
16433  or 
16434 \begin_inset Flex Code
16435 status collapsed
16436
16437 \begin_layout Plain Layout
16438 bibunits
16439 \end_layout
16440
16441 \end_inset
16442
16443  package, respectively.
16444 \end_layout
16445
16446 \end_inset
16447
16448
16449 \end_layout
16450
16451 \begin_layout Standard
16452 First go to 
16453 \begin_inset Flex Noun
16454 status collapsed
16455
16456 \begin_layout Plain Layout
16457 Document\SpecialChar menuseparator
16458 Settings
16459 \end_layout
16460
16461 \end_inset
16462
16463  and under 
16464 \begin_inset Flex Noun
16465 status collapsed
16466
16467 \begin_layout Plain Layout
16468 Bibliography
16469 \end_layout
16470
16471 \end_inset
16472
16473  check 
16474 \begin_inset Flex Noun
16475 status collapsed
16476
16477 \begin_layout Plain Layout
16478 Sectioned bibliography
16479 \end_layout
16480
16481 \end_inset
16482
16483 .
16484  In the document, you have to enclose the sections, which shall contain
16485  their own bibliography (including the Bib\SpecialChar TeX
16486  bibliography itself), between
16487  
16488 \begin_inset Flex Code
16489 status collapsed
16490
16491 \begin_layout Plain Layout
16492
16493 \backslash
16494 begin{btUnit}
16495 \end_layout
16496
16497 \end_inset
16498
16499  and 
16500 \begin_inset Flex Code
16501 status collapsed
16502
16503 \begin_layout Plain Layout
16504
16505 \backslash
16506 end{btUnit}
16507 \end_layout
16508
16509 \end_inset
16510
16511  (those commands have to be inserted as \SpecialChar TeX
16512  code).
16513  The bibliography will contain all references that have been cited in the
16514  current 
16515 \begin_inset Flex Code
16516 status collapsed
16517
16518 \begin_layout Plain Layout
16519 btUnit
16520 \end_layout
16521
16522 \end_inset
16523
16524 .
16525  
16526 \series bold
16527 Note:
16528 \series default
16529  If you are using this approach, then every citation reference has to be
16530  inside some 
16531 \begin_inset Flex Code
16532 status collapsed
16533
16534 \begin_layout Plain Layout
16535 btUnit
16536 \end_layout
16537
16538 \end_inset
16539
16540 .
16541  Also, the 
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 s cannot be nested.
16552 \end_layout
16553
16554 \begin_layout Chapter
16555 Multipart Documents
16556 \end_layout
16557
16558 \begin_layout Section
16559 General Operation
16560 \end_layout
16561
16562 \begin_layout Standard
16563 When you are working on a large file with many sections, it is often convenient
16564  to break up the document into several files, or perhaps you have something
16565  where a table may change from time to time, but the preceding text does
16566  not.
16567  In these cases, you should seriously consider using multipart documents.
16568  For example, scientific papers often have five major sections: the introduction
16569 , observations, results, discussion, and conclusion.
16570  Each of these could be its own separate \SpecialChar LyX
16571  file, with one 
16572 \begin_inset Quotes eld
16573 \end_inset
16574
16575 master
16576 \begin_inset Quotes erd
16577 \end_inset
16578
16579  file which contains the title, authors, abstract, references, etc., plus
16580  the five included files.
16581  It is important to note that each of these files is a full \SpecialChar LyX
16582  file which
16583  can be formatted and printed on its own, as well as included in a master
16584  file.
16585  Each of these files must have the same document class, however—don't attempt
16586  to mix book classes with article classes.
16587  You may also include \SpecialChar LaTeX
16588  files; however, these files must not have their own
16589  preamble (i.
16590 \begin_inset space \thinspace{}
16591 \end_inset
16592
16593 e.
16594 \begin_inset space \space{}
16595 \end_inset
16596
16597 everything up to and including the 
16598 \begin_inset Flex Code
16599 status collapsed
16600
16601 \begin_layout Plain Layout
16602
16603 \backslash
16604 begin{document}
16605 \end_layout
16606
16607 \end_inset
16608
16609  line as well as the 
16610 \begin_inset Flex Code
16611 status collapsed
16612
16613 \begin_layout Plain Layout
16614
16615 \backslash
16616 end{document}
16617 \end_layout
16618
16619 \end_inset
16620
16621  line must be deleted) or else errors will be generated when you try to
16622  make a DVI file.
16623 \end_layout
16624
16625 \begin_layout Standard
16626 \SpecialChar LyX
16627  allows you to include files quite easily with 
16628 \begin_inset Flex Noun
16629 status collapsed
16630
16631 \begin_layout Plain Layout
16632 Insert\SpecialChar menuseparator
16633 ChiId
16634 \begin_inset space ~
16635 \end_inset
16636
16637 Document
16638 \end_layout
16639
16640 \end_inset
16641
16642 .
16643  When you click on this selection a small box is inserted into the file
16644  at the current cursor location.
16645  Clicking on the box raises a dialog which allows you to select the file
16646  to be included, and the method of its inclusion.
16647  
16648 \end_layout
16649
16650 \begin_layout Standard
16651 The file selection box should by now be obvious.
16652  The three inclusion methods are 
16653 \begin_inset Quotes eld
16654 \end_inset
16655
16656 include
16657 \begin_inset Quotes erd
16658 \end_inset
16659
16660
16661 \begin_inset Quotes eld
16662 \end_inset
16663
16664 input
16665 \begin_inset Quotes erd
16666 \end_inset
16667
16668 , and 
16669 \begin_inset Quotes eld
16670 \end_inset
16671
16672 verbatim
16673 \begin_inset Quotes erd
16674 \end_inset
16675
16676 .
16677  The difference between 
16678 \begin_inset Quotes eld
16679 \end_inset
16680
16681 include
16682 \begin_inset Quotes erd
16683 \end_inset
16684
16685  and 
16686 \begin_inset Quotes eld
16687 \end_inset
16688
16689 input
16690 \begin_inset Quotes erd
16691 \end_inset
16692
16693  is really only meaningful to \SpecialChar LaTeX
16694 perts, but the practical difference is that
16695  files that are 
16696 \begin_inset Quotes eld
16697 \end_inset
16698
16699 included
16700 \begin_inset Quotes erd
16701 \end_inset
16702
16703  are typeset beginning on a new page, while files that are 
16704 \begin_inset Quotes eld
16705 \end_inset
16706
16707 inputted
16708 \begin_inset Quotes erd
16709 \end_inset
16710
16711  are typeset starting on the current page.
16712 \end_layout
16713
16714 \begin_layout Standard
16715 Generally, the master file is converted into a full \SpecialChar LaTeX
16716  file before typesetting,
16717  while the included files are converted to \SpecialChar LaTeX
16718  files that do not have all the
16719  preamble information.
16720 \end_layout
16721
16722 \begin_layout Standard
16723
16724 \begin_inset Quotes eld
16725 \end_inset
16726
16727 verbatim
16728 \begin_inset Quotes erd
16729 \end_inset
16730
16731  included file allows you to include a file typeset exactly as it appears
16732  in the file, i.
16733 \begin_inset space \thinspace{}
16734 \end_inset
16735
16736 e.
16737 \begin_inset space \space{}
16738 \end_inset
16739
16740 in 
16741 \begin_inset Flex Code
16742 status collapsed
16743
16744 \begin_layout Plain Layout
16745 verbatim
16746 \end_layout
16747
16748 \end_inset
16749
16750  mode, with the characters set in a fixed-width typewriter font.
16751  Normally, spaces in this file are invisible, though two consecutive spaces
16752  are conserved, unlike \SpecialChar LyX
16753 's normal treatment of spaces.
16754  However, setting the 
16755 \begin_inset Flex Noun
16756 status collapsed
16757
16758 \begin_layout Plain Layout
16759 Mark
16760 \begin_inset space ~
16761 \end_inset
16762
16763 spaces
16764 \begin_inset space ~
16765 \end_inset
16766
16767 in
16768 \begin_inset space ~
16769 \end_inset
16770
16771 output
16772 \end_layout
16773
16774 \end_inset
16775
16776  checkbox typesets a mark to unambiguously define the presence of a space.
16777  
16778 \end_layout
16779
16780 \begin_layout Section
16781 Cross-References Between Files
16782 \end_layout
16783
16784 \begin_layout Standard
16785 \begin_inset Box Shadowbox
16786 position "t"
16787 hor_pos "c"
16788 has_inner_box 1
16789 inner_pos "t"
16790 use_parbox 0
16791 use_makebox 0
16792 width "100col%"
16793 special "none"
16794 height "1in"
16795 height_special "totalheight"
16796 thickness "0.4pt"
16797 separation "3pt"
16798 shadowsize "4pt"
16799 framecolor "black"
16800 backgroundcolor "none"
16801 status open
16802
16803 \begin_layout Plain Layout
16804 This section is somewhat out of date.
16805  Need to describe default master documents and how children are opened when
16806  the master is.
16807  [[FIXME]]
16808 \end_layout
16809
16810 \end_inset
16811
16812
16813 \end_layout
16814
16815 \begin_layout Standard
16816 It is possible to set up cross-references between the different files.
16817  First, open all the files in question: let's call them A and B in a two
16818  file example, where B is included in A.
16819  Let's say you insert a label in A, then want to reference it in B.
16820  Open the cross-reference dialog whilst in document B, and you can select
16821  the 
16822 \begin_inset Quotes eld
16823 \end_inset
16824
16825 buffer
16826 \begin_inset Quotes erd
16827 \end_inset
16828
16829  to use.
16830 \end_layout
16831
16832 \begin_layout Section
16833 Bibliography Lists in all Subdocuments
16834 \end_layout
16835
16836 \begin_layout Standard
16837 \begin_inset Box Frameless
16838 position "t"
16839 hor_pos "c"
16840 has_inner_box 1
16841 inner_pos "t"
16842 use_parbox 0
16843 use_makebox 0
16844 width "100col%"
16845 special "none"
16846 height "1in"
16847 height_special "totalheight"
16848 thickness "0.4pt"
16849 separation "3pt"
16850 shadowsize "4pt"
16851 framecolor "black"
16852 backgroundcolor "none"
16853 status open
16854
16855 \begin_layout Plain Layout
16856 This section also needs updating.
16857  There is now material about this on the wiki, and it could be copied here.
16858 \end_layout
16859
16860 \end_inset
16861
16862
16863 \end_layout
16864
16865 \begin_layout Standard
16866 Copy the bibliography list with all entries to all subdocuments and transform
16867  them to a comment.
16868  This way \SpecialChar LyX
16869  will find the 
16870 \begin_inset Flex Code
16871 status collapsed
16872
16873 \begin_layout Plain Layout
16874 .bib
16875 \end_layout
16876
16877 \end_inset
16878
16879 -files and you can easily insert references without making the bibliography
16880  list visible.
16881 \end_layout
16882
16883 \begin_layout Standard
16884 As the bibliography list is in a comment, \SpecialChar LaTeX
16885  won't use it and the references
16886  will look like this: [?], instead of like this: [1].
16887  One solution is to use the \SpecialChar LaTeX
16888 -package 
16889 \begin_inset Flex Code
16890 status collapsed
16891
16892 \begin_layout Plain Layout
16893 comment
16894 \end_layout
16895
16896 \end_inset
16897
16898  that will only include comments by processing the files separately.
16899  To do this, add in the \SpecialChar LaTeX
16900  preamble of every subdocument the following:
16901 \end_layout
16902
16903 \begin_layout LyX-Code
16904
16905 \backslash
16906 usepackage{comment}
16907 \end_layout
16908
16909 \begin_layout LyX-Code
16910
16911 \backslash
16912 includecomment{comment}
16913 \end_layout
16914
16915 \begin_layout Standard
16916 See also 
16917 \begin_inset Flex URL
16918 status collapsed
16919
16920 \begin_layout Plain Layout
16921
16922 http://wiki.lyx.org/FAQ/Unsorted#toc31
16923 \end_layout
16924
16925 \end_inset
16926
16927 .
16928 \end_layout
16929
16930 \begin_layout Section
16931 Itemize Bullet Selection
16932 \begin_inset CommandInset label
16933 LatexCommand label
16934 name "sec:bullet"
16935
16936 \end_inset
16937
16938
16939 \end_layout
16940
16941 \begin_layout Standard
16942 by
16943 \noun on
16944  Allan Rae
16945 \end_layout
16946
16947 \begin_layout Subsection
16948 Introduction
16949 \end_layout
16950
16951 \begin_layout Standard
16952 \SpecialChar LyX
16953  provides 216 bullet shapes that can be accessed from a simple dialog.
16954  Using this dialog you can easily specify what bullet shape to use at each
16955  level of an itemized list.
16956  These settings are document-wide so you won't be able to specify different
16957  sets of bullets for different paragraphs.
16958 \begin_inset Foot
16959 status collapsed
16960
16961 \begin_layout Plain Layout
16962 Well, actually you can but you'll have to do it by hand.
16963 \end_layout
16964
16965 \end_inset
16966
16967
16968 \end_layout
16969
16970 \begin_layout Subsection
16971 How it looks
16972 \end_layout
16973
16974 \begin_layout Standard
16975 Open the dialog by selecting the 
16976 \begin_inset Flex Noun
16977 status collapsed
16978
16979 \begin_layout Plain Layout
16980 Document\SpecialChar menuseparator
16981 Settings
16982 \end_layout
16983
16984 \end_inset
16985
16986  menu item and then select the 
16987 \begin_inset Flex Noun
16988 status collapsed
16989
16990 \begin_layout Plain Layout
16991 Bullets
16992 \end_layout
16993
16994 \end_inset
16995
16996  tab.
16997 \end_layout
16998
16999 \begin_layout Standard
17000 The dialog provides you with a table of bullet shapes.
17001  A column of buttons on the left of the table provides access to the six
17002  different panels of bullet shapes.
17003  The row of buttons across the top is used to select which bullet depth
17004  you are changing.
17005  A text entry under the table shows the currently selected bullet shape's
17006  \SpecialChar LaTeX
17007  equivalent and this can be edited if desired.
17008  If you do modify the text you will also need to specify any needed packages
17009  in the \SpecialChar LaTeX
17010  preamble.
17011 \end_layout
17012
17013 \begin_layout Standard
17014 The six panels are divided up by the packages they require.
17015  The following table shows the mappings from button name to \SpecialChar LaTeX
17016  package.
17017 \begin_inset Separator latexpar
17018 \end_inset
17019
17020
17021 \end_layout
17022
17023 \begin_layout Standard
17024 \align center
17025 \begin_inset Tabular
17026 <lyxtabular version="3" rows="7" columns="2">
17027 <features tabularvalignment="middle">
17028 <column alignment="center" valignment="top" width="0pt">
17029 <column alignment="center" valignment="top" width="0pt">
17030 <row>
17031 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
17032 \begin_inset Text
17033
17034 \begin_layout Plain Layout
17035
17036 \family roman
17037 \series medium
17038 \shape up
17039 \size normal
17040 \emph off
17041 \bar no
17042 \noun off
17043 \color none
17044 Button
17045 \end_layout
17046
17047 \end_inset
17048 </cell>
17049 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
17050 \begin_inset Text
17051
17052 \begin_layout Plain Layout
17053
17054 \family roman
17055 \series medium
17056 \shape up
17057 \size normal
17058 \emph off
17059 \bar no
17060 \noun off
17061 \color none
17062 Packages Required
17063 \end_layout
17064
17065 \end_inset
17066 </cell>
17067 </row>
17068 <row>
17069 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17070 \begin_inset Text
17071
17072 \begin_layout Plain Layout
17073
17074 \family sans
17075 \series medium
17076 \shape up
17077 \size normal
17078 \emph off
17079 \bar no
17080 \noun off
17081 \color none
17082 Standard
17083 \end_layout
17084
17085 \end_inset
17086 </cell>
17087 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17088 \begin_inset Text
17089
17090 \begin_layout Plain Layout
17091
17092 \series medium
17093 \shape up
17094 \size normal
17095 \emph off
17096 \bar no
17097 \noun off
17098 \color none
17099 base \SpecialChar LaTeX
17100
17101 \end_layout
17102
17103 \end_inset
17104 </cell>
17105 </row>
17106 <row>
17107 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17108 \begin_inset Text
17109
17110 \begin_layout Plain Layout
17111
17112 \family sans
17113 \series medium
17114 \shape up
17115 \size normal
17116 \emph off
17117 \bar no
17118 \noun off
17119 \color none
17120 Maths
17121 \end_layout
17122
17123 \end_inset
17124 </cell>
17125 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17126 \begin_inset Text
17127
17128 \begin_layout Plain Layout
17129
17130 \family typewriter
17131 \series medium
17132 \shape up
17133 \size normal
17134 \emph off
17135 \bar no
17136 \noun off
17137 \color none
17138 amssymb.sty
17139 \end_layout
17140
17141 \end_inset
17142 </cell>
17143 </row>
17144 <row>
17145 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17146 \begin_inset Text
17147
17148 \begin_layout Plain Layout
17149
17150 \family sans
17151 \series medium
17152 \shape up
17153 \size normal
17154 \emph off
17155 \bar no
17156 \noun off
17157 \color none
17158 Ding1
17159 \end_layout
17160
17161 \end_inset
17162 </cell>
17163 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17164 \begin_inset Text
17165
17166 \begin_layout Plain Layout
17167
17168 \family typewriter
17169 \series medium
17170 \shape up
17171 \size normal
17172 \emph off
17173 \bar no
17174 \noun off
17175 \color none
17176 pifont.sty
17177 \end_layout
17178
17179 \end_inset
17180 </cell>
17181 </row>
17182 <row>
17183 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17184 \begin_inset Text
17185
17186 \begin_layout Plain Layout
17187
17188 \family sans
17189 \series medium
17190 \shape up
17191 \size normal
17192 \emph off
17193 \bar no
17194 \noun off
17195 \color none
17196 Ding2
17197 \end_layout
17198
17199 \end_inset
17200 </cell>
17201 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17202 \begin_inset Text
17203
17204 \begin_layout Plain Layout
17205
17206 \family typewriter
17207 \series medium
17208 \shape up
17209 \size normal
17210 \emph off
17211 \bar no
17212 \noun off
17213 \color none
17214 pifont.sty
17215 \end_layout
17216
17217 \end_inset
17218 </cell>
17219 </row>
17220 <row>
17221 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
17222 \begin_inset Text
17223
17224 \begin_layout Plain Layout
17225
17226 \family sans
17227 \series medium
17228 \shape up
17229 \size normal
17230 \emph off
17231 \bar no
17232 \noun off
17233 \color none
17234 Ding3
17235 \end_layout
17236
17237 \end_inset
17238 </cell>
17239 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
17240 \begin_inset Text
17241
17242 \begin_layout Plain Layout
17243
17244 \family typewriter
17245 \series medium
17246 \shape up
17247 \size normal
17248 \emph off
17249 \bar no
17250 \noun off
17251 \color none
17252 pifont.sty
17253 \end_layout
17254
17255 \end_inset
17256 </cell>
17257 </row>
17258 <row>
17259 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
17260 \begin_inset Text
17261
17262 \begin_layout Plain Layout
17263
17264 \family sans
17265 \series medium
17266 \shape up
17267 \size normal
17268 \emph off
17269 \bar no
17270 \noun off
17271 \color none
17272 Ding4
17273 \end_layout
17274
17275 \end_inset
17276 </cell>
17277 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
17278 \begin_inset Text
17279
17280 \begin_layout Plain Layout
17281
17282 \family typewriter
17283 \series medium
17284 \shape up
17285 \size normal
17286 \emph off
17287 \bar no
17288 \noun off
17289 \color none
17290 pifont.sty
17291 \end_layout
17292
17293 \end_inset
17294 </cell>
17295 </row>
17296 </lyxtabular>
17297
17298 \end_inset
17299
17300
17301 \end_layout
17302
17303 \begin_layout Standard
17304 \SpecialChar LyX
17305  doesn't stop you using bullets from packages you don't have.
17306  If you get errors from \SpecialChar LaTeX
17307  when you try to view or print the file, then it
17308  is likely you are missing a package.
17309 \begin_inset Foot
17310 status collapsed
17311
17312 \begin_layout Plain Layout
17313 \SpecialChar LyX
17314  doesn't restrict your use since you may be editing locally and exporting
17315  elsewhere.
17316 \end_layout
17317
17318 \end_inset
17319
17320
17321 \end_layout
17322
17323 \begin_layout Subsection
17324 How to use it
17325 \end_layout
17326
17327 \begin_layout Standard
17328 Select which bullet depth you want to change then select the bullet shape
17329  and size.
17330  Any changes will not be visible in \SpecialChar LyX
17331 , but are visible when viewing the document.
17332 \end_layout
17333
17334 \begin_layout Standard
17335 You can reset a bullet shape to the default simply by clicking your right
17336  mouse button on the appropriate bullet depth button.
17337 \begin_inset Foot
17338 status collapsed
17339
17340 \begin_layout Plain Layout
17341 If you 
17342 \emph on
17343 really
17344 \emph default
17345  want to have multiple sets of paragraphs with different sets of bullets
17346  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
17347  code.
17348  The bullet selection dialog can help though because it provides you with
17349  the \SpecialChar LaTeX
17350  code for a wide range of bullet shapes.
17351  To make your own custom paragraphs you have the following options:
17352 \end_layout
17353
17354 \begin_layout Plain Layout
17355 \begin_inset ERT
17356 status open
17357
17358 \begin_layout Plain Layout
17359
17360
17361 \backslash
17362 let
17363 \backslash
17364 savelabelitemi=
17365 \backslash
17366 labelitemi
17367 \end_layout
17368
17369 \end_inset
17370
17371
17372 \end_layout
17373
17374 \begin_layout Plain Layout
17375 \begin_inset ERT
17376 status open
17377
17378 \begin_layout Plain Layout
17379
17380
17381 \backslash
17382 renewcommand
17383 \backslash
17384 labelitemi[0]{
17385 \backslash
17386 small
17387 \backslash
17388 (
17389 \backslash
17390 sharp
17391 \backslash
17392 )}
17393 \end_layout
17394
17395 \end_inset
17396
17397
17398 \end_layout
17399
17400 \begin_layout Itemize
17401 Use the \SpecialChar LaTeX
17402  command 
17403 \begin_inset Flex Code
17404 status collapsed
17405
17406 \begin_layout Plain Layout
17407
17408 \backslash
17409 renewcommand{}{}
17410 \end_layout
17411
17412 \end_inset
17413
17414  to specify a new bullet shape for a given depth.
17415  You'll also need to save the current bullet shape so you can restore it
17416  again afterwards.
17417  In this itemized list the following \SpecialChar LaTeX
17418  code was used to change the bullet
17419  used for the first depth.
17420 \begin_inset Separator latexpar
17421 \end_inset
17422
17423
17424 \end_layout
17425
17426 \begin_deeper
17427 \begin_layout LyX-Code
17428
17429 \backslash
17430 let
17431 \backslash
17432 savelabelitemi=
17433 \backslash
17434 labelitemi 
17435 \end_layout
17436
17437 \begin_layout LyX-Code
17438
17439 \backslash
17440 renewcommand
17441 \backslash
17442 labelitemi[0]{
17443 \backslash
17444 small
17445 \backslash
17446 (
17447 \backslash
17448 sharp
17449 \backslash
17450 )}
17451 \end_layout
17452
17453 \end_deeper
17454 \begin_layout Itemize
17455 Note that the itemize depth is specified in Roman numerals as part of the
17456  
17457 \family typewriter
17458
17459 \backslash
17460 labelitem
17461 \family default
17462  command.
17463 \end_layout
17464
17465 \begin_layout Itemize
17466 \begin_inset ERT
17467 status open
17468
17469 \begin_layout Plain Layout
17470
17471 [
17472 \backslash
17473 (
17474 \backslash
17475 star
17476 \backslash
17477 )]
17478 \end_layout
17479
17480 \end_inset
17481
17482  Specify each individual entry by starting each item with the bullet shape
17483  enclosed in square brackets and set as 
17484 \begin_inset Flex Noun
17485 status collapsed
17486
17487 \begin_layout Plain Layout
17488 \SpecialChar TeX
17489  Code
17490 \end_layout
17491
17492 \end_inset
17493
17494 .
17495  For example, this item was started with 
17496 \begin_inset Flex Code
17497 status collapsed
17498
17499 \begin_layout Plain Layout
17500 [
17501 \backslash
17502 (
17503 \backslash
17504 star
17505 \backslash
17506 )]
17507 \end_layout
17508
17509 \end_inset
17510
17511 .
17512 \end_layout
17513
17514 \begin_layout Plain Layout
17515 \begin_inset ERT
17516 status open
17517
17518 \begin_layout Plain Layout
17519
17520
17521 \backslash
17522 renewcommand
17523 \backslash
17524 labelitemi[0]{
17525 \backslash
17526 savelabelitemi}
17527 \end_layout
17528
17529 \end_inset
17530
17531
17532 \end_layout
17533
17534 \begin_layout Plain Layout
17535 You'll also need to revert the labelitem back to its previous setting for
17536  the global bullet shape settings to remain in effect.
17537  The way used here was:
17538 \end_layout
17539
17540 \begin_layout LyX-Code
17541
17542 \backslash
17543 renewcommand
17544 \backslash
17545 labelitemi[0]{
17546 \backslash
17547 savelabelitemi}
17548 \end_layout
17549
17550 \end_inset
17551
17552
17553 \end_layout
17554
17555 \begin_layout Chapter
17556 \SpecialChar LyX
17557  Features needing Extra Software
17558 \end_layout
17559
17560 \begin_layout Section
17561 Checking \SpecialChar TeX
17562
17563 \end_layout
17564
17565 \begin_layout Standard
17566 by 
17567 \noun on
17568 Asger Alstrup
17569 \end_layout
17570
17571 \begin_layout Subsection
17572 Introduction
17573 \end_layout
17574
17575 \begin_layout Standard
17576 If you have the 
17577 \family typewriter
17578 chktex
17579 \family default
17580  program installed
17581 \begin_inset Foot
17582 status collapsed
17583
17584 \begin_layout Plain Layout
17585
17586 \family typewriter
17587 chktex
17588 \family default
17589  is not yet available when you are using the \SpecialChar LaTeX
17590  distribution MiK\SpecialChar TeX
17591 .
17592 \end_layout
17593
17594 \end_inset
17595
17596 , you'll find in the 
17597 \family sans
17598 Tools
17599 \family default
17600  menu the entry: 
17601 \family sans
17602 Check
17603 \begin_inset space ~
17604 \end_inset
17605
17606 TeX
17607 \family default
17608 .
17609  You can get 
17610 \family typewriter
17611 chktex
17612 \family default
17613  from CTAN,
17614 \begin_inset Newline newline
17615 \end_inset
17616
17617
17618 \begin_inset CommandInset href
17619 LatexCommand href
17620 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
17621
17622 \end_inset
17623
17624 .
17625 \end_layout
17626
17627 \begin_layout Standard
17628 The 
17629 \family sans
17630 Chk\SpecialChar TeX
17631
17632 \family default
17633  package is a program that was written by 
17634 \begin_inset Flex Noun
17635 status collapsed
17636
17637 \begin_layout Plain Layout
17638 Jens T.
17639 \begin_inset space ~
17640 \end_inset
17641
17642 Berger Thielemann
17643 \end_layout
17644
17645 \end_inset
17646
17647  in frustration because some constructs in \SpecialChar LaTeX
17648  are sometimes non-intuitive,
17649  and easy to forget.
17650  The program runs over your \SpecialChar LaTeX
17651  file, checks the integrity of the file, and
17652  flags some common errors.
17653  In other technical words, it is 
17654 \family typewriter
17655 lint
17656 \family default
17657  for \SpecialChar LaTeX
17658 .
17659 \end_layout
17660
17661 \begin_layout Standard
17662 Well, what is a syntax checker doing in \SpecialChar LyX
17663  which is supposed to produce correct
17664  \SpecialChar LaTeX
17665  anyways? The answer is simple: Just as 
17666 \family typewriter
17667 Lint
17668 \family default
17669  not only checks the 
17670 \emph on
17671 syntax
17672 \emph default
17673  of C programs, but also does 
17674 \emph on
17675 semantic
17676 \emph default
17677  checks for type-errors, 
17678 \family sans
17679 Chk\SpecialChar TeX
17680
17681 \family default
17682  catches some common 
17683 \emph on
17684 typographic
17685 \emph default
17686  errors, in addition to the syntactical ones.
17687  Specifically, 
17688 \family sans
17689 Chk\SpecialChar TeX
17690
17691 \family default
17692  is capable of detecting several common errors, such as
17693 \end_layout
17694
17695 \begin_layout Itemize
17696 Ellipsis detection:
17697 \begin_inset Newline newline
17698 \end_inset
17699
17700 Use \SpecialChar ldots
17701  instead of ...
17702 \end_layout
17703
17704 \begin_layout Itemize
17705 No space in front of/after parenthesis:
17706 \begin_inset Newline newline
17707 \end_inset
17708
17709 ( wrong spacing )
17710 \end_layout
17711
17712 \begin_layout Itemize
17713 Enforcement of normal space after common abbreviations:
17714 \begin_inset Newline newline
17715 \end_inset
17716
17717 e.
17718 \begin_inset space \thinspace{}
17719 \end_inset
17720
17721 g.
17722 \begin_inset space \space{}
17723 \end_inset
17724
17725 is too wide spacing.
17726 \end_layout
17727
17728 \begin_layout Itemize
17729 Enforcement of end-of-sentence space when the last sentence ends with a
17730  capital letter:
17731 \begin_inset Newline newline
17732 \end_inset
17733
17734 This is a TEST.
17735  And this is wrong spacing.
17736 \end_layout
17737
17738 \begin_layout Itemize
17739 Space in front of labels and similar commands:
17740 \begin_inset Newline newline
17741 \end_inset
17742
17743 The label should stick right up to the text to avoid falling to a wrong
17744  page.
17745  
17746 \begin_inset CommandInset label
17747 LatexCommand label
17748 name "sec:chktex"
17749
17750 \end_inset
17751
17752  
17753 \begin_inset Foot
17754 status collapsed
17755
17756 \begin_layout Plain Layout
17757 This footnote is in danger of falling off to a wrong page
17758 \end_layout
17759
17760 \end_inset
17761
17762  The label is separated too much.
17763 \end_layout
17764
17765 \begin_layout Itemize
17766 Space in front of references, instead of hard spaces:
17767 \begin_inset Newline newline
17768 \end_inset
17769
17770 If you have bad luck, the text will break right between the referenced text
17771  and reference number, and that's a pity.
17772  See section 
17773 \begin_inset CommandInset ref
17774 LatexCommand ref
17775 reference "sec:chktex"
17776
17777 \end_inset
17778
17779 .
17780 \end_layout
17781
17782 \begin_layout Itemize
17783 Use of 
17784 \begin_inset Quotes eld
17785 \end_inset
17786
17787 x
17788 \begin_inset Quotes erd
17789 \end_inset
17790
17791  instead of 
17792 \begin_inset Formula $\times$
17793 \end_inset
17794
17795  between numbers:
17796 \begin_inset Newline newline
17797 \end_inset
17798
17799 2x2 looks cheap compared to 
17800 \begin_inset Formula $2\times2$
17801 \end_inset
17802
17803 .
17804 \end_layout
17805
17806 \begin_layout Standard
17807 and more \SpecialChar ldots
17808  It is an invaluable tool when you are 
17809 \begin_inset Quotes eld
17810 \end_inset
17811
17812 finishing up
17813 \begin_inset Quotes erd
17814 \end_inset
17815
17816  your document before printing, and you should run it right after the obligatory
17817  spelling check, and before you go fine tuning the typesetting.
17818 \end_layout
17819
17820 \begin_layout Subsection
17821 How to use it
17822 \end_layout
17823
17824 \begin_layout Standard
17825 If you have the program installed, usage is as simple as choosing 
17826 \family sans
17827 Tools\SpecialChar menuseparator
17828 Check
17829 \begin_inset space ~
17830 \end_inset
17831
17832 TeX
17833 \family default
17834 .
17835  This will make \SpecialChar LyX
17836  generate a \SpecialChar LaTeX
17837  file of your document, start 
17838 \family sans
17839 Chk\SpecialChar TeX
17840
17841 \family default
17842  to check it, and then make \SpecialChar LyX
17843  insert 
17844 \begin_inset Quotes eld
17845 \end_inset
17846
17847 error boxes
17848 \begin_inset Quotes erd
17849 \end_inset
17850
17851  with the warnings from 
17852 \family sans
17853 Chk\SpecialChar TeX
17854
17855 \family default
17856 , if there were any.
17857  The warnings will be placed close to the point of the mistake, and you
17858  can quickly find them by using the 
17859 \family sans
17860 Navigate\SpecialChar menuseparator
17861 Error
17862 \family default
17863  menu item, or the shortcut key 
17864 \family sans
17865 C-g
17866 \family default
17867  from the default 
17868 \family typewriter
17869 cua
17870 \family default
17871  bind file.
17872  Open the error boxes by clicking on them with the mouse, or use the shortcut
17873  key 
17874 \family sans
17875 C-i
17876 \family default
17877  from 
17878 \family typewriter
17879 cua
17880 \family default
17881  bindings, or the corresponding 
17882 \family sans
17883 C-o
17884 \family default
17885  for the alternate 
17886 \family typewriter
17887 emacs
17888 \family default
17889  bind file.
17890  Read the warning and correct the mistake, if it is a mistake.
17891  If you have trouble understanding what the warning is about, you can safely
17892  ignore it.
17893  Remember that there is a hidden layer between the document on screen and
17894  the technical details in invoking 
17895 \family sans
17896 Chk\SpecialChar TeX
17897
17898 \family default
17899 , and this gap can make some warnings seem arcane or just plain silly.
17900 \end_layout
17901
17902 \begin_layout Standard
17903 This document is an excellent testing bed for the feature, and it should
17904  provide quite a few warnings for you to fiddle with.
17905  Since computers are only so smart, expect most of the warnings to be false
17906  alarms, though.
17907 \end_layout
17908
17909 \begin_layout Subsection
17910 How to fine tune it
17911 \end_layout
17912
17913 \begin_layout Standard
17914 Sometimes, you'll find that 
17915 \family sans
17916 Chk\SpecialChar TeX
17917
17918 \family default
17919  makes more noise than suits your mood.
17920  Then you can choose not to use it, wait until your mood changes, or try
17921  to customize 
17922 \family sans
17923 Chk\SpecialChar TeX
17924
17925 \family default
17926  to get better along with you.
17927 \end_layout
17928
17929 \begin_layout Standard
17930 Although 
17931 \family sans
17932 Chk\SpecialChar TeX
17933
17934 \family default
17935  
17936 \emph on
17937 is
17938 \emph default
17939  very configurable and extensible, you should not expect to solve all problems
17940  with 
17941 \family sans
17942 Chk\SpecialChar TeX
17943
17944 \family default
17945  in \SpecialChar LyX
17946  this way.
17947  Since \SpecialChar LyX
17948  has to generate a somewhat special \SpecialChar LaTeX
17949  file to be able to match the
17950  line numbers from the 
17951 \family sans
17952 Chk\SpecialChar TeX
17953
17954 \family default
17955  output
17956 \begin_inset Foot
17957 status collapsed
17958
17959 \begin_layout Plain Layout
17960 You can inspect the specific output from 
17961 \family sans
17962 chktex
17963 \family default
17964  by using 
17965 \family sans
17966 Document\SpecialChar menuseparator
17967 \SpecialChar LaTeX
17968
17969 \begin_inset space ~
17970 \end_inset
17971
17972 Log
17973 \family default
17974  right after a 
17975 \family sans
17976 chktex
17977 \family default
17978  run.
17979 \end_layout
17980
17981 \end_inset
17982
17983  to the internal document structure, some of the warnings will not appear
17984  correctly.
17985  There are two things you can do about this:
17986 \end_layout
17987
17988 \begin_layout Itemize
17989 Fine tune the 
17990 \family sans
17991 Chk\SpecialChar TeX
17992
17993 \family default
17994  invocation command line in 
17995 \begin_inset Flex Noun
17996 status collapsed
17997
17998 \begin_layout Plain Layout
17999 Tools\SpecialChar menuseparator
18000 Preferences\SpecialChar menuseparator
18001 Output\SpecialChar menuseparator
18002 LaTeX\SpecialChar menuseparator
18003 CheckTeX command
18004 \end_layout
18005
18006 \end_inset
18007
18008 , or the global 
18009 \family sans
18010 Chk\SpecialChar TeX
18011
18012 \family default
18013  installation configuration file (usually with the file 
18014 \family typewriter
18015 chktexrc
18016 \family default
18017 ).
18018  See below to learn what warnings can be enabled and disabled on the command
18019  line.
18020 \end_layout
18021
18022 \begin_layout Itemize
18023 Export your document as a raw \SpecialChar LaTeX
18024  file using 
18025 \family sans
18026 File\SpecialChar menuseparator
18027 Export\SpecialChar menuseparator
18028 \SpecialChar LaTeX
18029
18030 \family default
18031  and run 
18032 \family typewriter
18033 chktex
18034 \family default
18035  manually on that.
18036  Invoked in this way, it can be a hassle to find the corresponding place
18037  in the document inside \SpecialChar LyX
18038 , but with a little patience, you should be able
18039  to do it.
18040 \end_layout
18041
18042 \begin_layout Standard
18043 Here follows the warning messages that can be enabled and disabled in 
18044 \family sans
18045 Preferences
18046 \family default
18047 .
18048  Use 
18049 \family typewriter
18050 -n#
18051 \family default
18052  to disable a warning, and 
18053 \family typewriter
18054 -w#
18055 \family default
18056  to enable a warning.
18057  The emphasized entries are disabled by default, because the default is
18058  "
18059 \family typewriter
18060 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
18061 \family default
18062 ".
18063 \end_layout
18064
18065 \begin_layout Standard
18066 Notice that you should only use the options that enable and disable warnings,
18067  because \SpecialChar LyX
18068  relies on some of the other command line parameters to be set
18069  in a specific way to have a chance to communicate with 
18070 \family typewriter
18071 chktex
18072 \family default
18073 .
18074 \end_layout
18075
18076 \begin_layout Enumerate
18077
18078 \size small
18079 \emph on
18080 Command terminated with space.
18081 \end_layout
18082
18083 \begin_layout Enumerate
18084
18085 \size small
18086 Non-breaking space (
18087 \begin_inset Quotes eld
18088 \end_inset
18089
18090
18091 \family typewriter
18092 ~
18093 \family default
18094
18095 \begin_inset Quotes erd
18096 \end_inset
18097
18098 ) should have been used.
18099 \end_layout
18100
18101 \begin_layout Enumerate
18102
18103 \size small
18104 \emph on
18105 You should enclose the previous parenthesis with 
18106 \begin_inset Quotes eld
18107 \end_inset
18108
18109
18110 \family typewriter
18111 {}
18112 \family default
18113
18114 \begin_inset Quotes erd
18115 \end_inset
18116
18117 .
18118 \end_layout
18119
18120 \begin_layout Enumerate
18121
18122 \size small
18123 Italic correction (
18124 \begin_inset Quotes eld
18125 \end_inset
18126
18127
18128 \family typewriter
18129
18130 \backslash
18131 /
18132 \family default
18133
18134 \begin_inset Quotes erd
18135 \end_inset
18136
18137 ) found in non-italic buffer.
18138 \end_layout
18139
18140 \begin_layout Enumerate
18141
18142 \size small
18143 Italic correction (
18144 \begin_inset Quotes eld
18145 \end_inset
18146
18147
18148 \family typewriter
18149
18150 \backslash
18151 /
18152 \family default
18153
18154 \begin_inset Quotes erd
18155 \end_inset
18156
18157 ) found more than once.
18158 \end_layout
18159
18160 \begin_layout Enumerate
18161
18162 \size small
18163 \emph on
18164 No italic correction (
18165 \begin_inset Quotes eld
18166 \end_inset
18167
18168
18169 \family typewriter
18170
18171 \backslash
18172 /
18173 \family default
18174
18175 \begin_inset Quotes erd
18176 \end_inset
18177
18178 ) found.
18179 \end_layout
18180
18181 \begin_layout Enumerate
18182
18183 \size small
18184 Accent command 
18185 \begin_inset Quotes eld
18186 \end_inset
18187
18188
18189 \family typewriter
18190 cmd
18191 \family default
18192
18193 \begin_inset Quotes erd
18194 \end_inset
18195
18196  needs use of 
18197 \begin_inset Quotes eld
18198 \end_inset
18199
18200
18201 \family typewriter
18202 cmd
18203 \family default
18204
18205 \begin_inset Quotes erd
18206 \end_inset
18207
18208 .
18209 \end_layout
18210
18211 \begin_layout Enumerate
18212
18213 \size small
18214 Wrong length of dash may have been used.
18215 \end_layout
18216
18217 \begin_layout Enumerate
18218
18219 \size small
18220 \emph on
18221 \begin_inset Quotes eld
18222 \end_inset
18223
18224
18225 \family typewriter
18226 %s
18227 \family default
18228
18229 \begin_inset Quotes erd
18230 \end_inset
18231
18232  expected, found 
18233 \begin_inset Quotes eld
18234 \end_inset
18235
18236
18237 \family typewriter
18238 %s
18239 \family default
18240
18241 \begin_inset Quotes erd
18242 \end_inset
18243
18244 .
18245 \end_layout
18246
18247 \begin_layout Enumerate
18248
18249 \size small
18250 Solo 
18251 \begin_inset Quotes eld
18252 \end_inset
18253
18254
18255 \family typewriter
18256 %s
18257 \family default
18258
18259 \begin_inset Quotes erd
18260 \end_inset
18261
18262  found.
18263 \end_layout
18264
18265 \begin_layout Enumerate
18266
18267 \size small
18268 You should use 
18269 \begin_inset Quotes eld
18270 \end_inset
18271
18272
18273 \family typewriter
18274 %s
18275 \family default
18276
18277 \begin_inset Quotes erd
18278 \end_inset
18279
18280  to achieve an ellipsis.
18281 \end_layout
18282
18283 \begin_layout Enumerate
18284
18285 \size small
18286 Inter-word spacing (
18287 \begin_inset Quotes eld
18288 \end_inset
18289
18290
18291 \family typewriter
18292
18293 \backslash
18294
18295 \family default
18296  
18297 \begin_inset Quotes eld
18298 \end_inset
18299
18300 ) should perhaps be used.
18301 \end_layout
18302
18303 \begin_layout Enumerate
18304
18305 \size small
18306 Inter-sentence spacing (
18307 \begin_inset Quotes eld
18308 \end_inset
18309
18310
18311 \family typewriter
18312
18313 \backslash
18314 @
18315 \family default
18316
18317 \begin_inset Quotes erd
18318 \end_inset
18319
18320 ) should perhaps be used.
18321 \end_layout
18322
18323 \begin_layout Enumerate
18324
18325 \size small
18326 Could not find argument for command.
18327 \end_layout
18328
18329 \begin_layout Enumerate
18330
18331 \size small
18332 No match found for 
18333 \begin_inset Quotes eld
18334 \end_inset
18335
18336
18337 \family typewriter
18338 %s
18339 \family default
18340
18341 \begin_inset Quotes erd
18342 \end_inset
18343
18344 .
18345 \end_layout
18346
18347 \begin_layout Enumerate
18348
18349 \size small
18350 Math mode still on at end of \SpecialChar LaTeX
18351  file.
18352 \end_layout
18353
18354 \begin_layout Enumerate
18355
18356 \size small
18357 Number of 
18358 \begin_inset Quotes eld
18359 \end_inset
18360
18361
18362 \family typewriter
18363 char
18364 \family default
18365
18366 \begin_inset Quotes erd
18367 \end_inset
18368
18369  doesn't match the number of 
18370 \begin_inset Quotes eld
18371 \end_inset
18372
18373
18374 \family typewriter
18375 char
18376 \family default
18377
18378 \begin_inset Quotes erd
18379 \end_inset
18380
18381 .
18382 \end_layout
18383
18384 \begin_layout Enumerate
18385
18386 \size small
18387 You should use either 
18388 \family typewriter
18389
18390 \begin_inset Quotes eld
18391 \end_inset
18392
18393
18394 \family default
18395  or 
18396 \family typewriter
18397
18398 \begin_inset Quotes erd
18399 \end_inset
18400
18401
18402 \family default
18403  as an alternative to 
18404 \begin_inset Quotes eld
18405 \end_inset
18406
18407
18408 \family typewriter
18409 "
18410 \family default
18411
18412 \begin_inset Quotes erd
18413 \end_inset
18414
18415 .
18416 \end_layout
18417
18418 \begin_layout Enumerate
18419
18420 \size small
18421 You should use "
18422 \family typewriter
18423 '
18424 \family default
18425 " (ASCII 39) instead of "
18426 \family typewriter
18427 ´
18428 \family default
18429 " (ASCII 180).
18430 \end_layout
18431
18432 \begin_layout Enumerate
18433
18434 \size small
18435 User-specified pattern found.
18436 \end_layout
18437
18438 \begin_layout Enumerate
18439
18440 \size small
18441 This command might not be intended.
18442 \end_layout
18443
18444 \begin_layout Enumerate
18445
18446 \size small
18447 \emph on
18448 Comment displayed.
18449 \end_layout
18450
18451 \begin_layout Enumerate
18452
18453 \size small
18454 Either 
18455 \family typewriter
18456 ''
18457 \backslash
18458 ,'
18459 \family default
18460  or 
18461 \family typewriter
18462 '
18463 \backslash
18464 ,''
18465 \family default
18466  will look better.
18467 \end_layout
18468
18469 \begin_layout Enumerate
18470
18471 \size small
18472 Delete this space to maintain correct page references.
18473 \end_layout
18474
18475 \begin_layout Enumerate
18476
18477 \size small
18478 \emph on
18479 You might wish to put this between a pair of 
18480 \begin_inset Quotes eld
18481 \end_inset
18482
18483
18484 \family typewriter
18485 {}
18486 \family default
18487
18488 \begin_inset Quotes erd
18489 \end_inset
18490
18491 .
18492 \end_layout
18493
18494 \begin_layout Enumerate
18495
18496 \size small
18497 You ought to remove spaces in front of punctuation.
18498 \end_layout
18499
18500 \begin_layout Enumerate
18501
18502 \size small
18503 Could not execute \SpecialChar LaTeX
18504  command.
18505 \end_layout
18506
18507 \begin_layout Enumerate
18508
18509 \size small
18510 Don't use 
18511 \family typewriter
18512
18513 \backslash
18514 /
18515 \family default
18516  in front of small punctuation.
18517 \end_layout
18518
18519 \begin_layout Enumerate
18520
18521 \family typewriter
18522 \size small
18523 $
18524 \backslash
18525 times$
18526 \family default
18527  may look prettier here.
18528 \end_layout
18529
18530 \begin_layout Enumerate
18531
18532 \size small
18533 \emph on
18534 Multiple spaces detected in output.
18535 \end_layout
18536
18537 \begin_layout Enumerate
18538
18539 \size small
18540 This text may be ignored.
18541 \end_layout
18542
18543 \begin_layout Enumerate
18544
18545 \size small
18546 Use 
18547 \family typewriter
18548
18549 \begin_inset Quotes eld
18550 \end_inset
18551
18552
18553 \family default
18554  to begin quotation, not 
18555 \family typewriter
18556 '
18557 \family default
18558 .
18559 \end_layout
18560
18561 \begin_layout Enumerate
18562
18563 \size small
18564 Use 
18565 \family typewriter
18566 '
18567 \family default
18568  to end quotation, not 
18569 \family typewriter
18570
18571 \begin_inset Quotes eld
18572 \end_inset
18573
18574
18575 \family default
18576 .
18577 \end_layout
18578
18579 \begin_layout Enumerate
18580
18581 \size small
18582 Don't mix quotes.
18583 \end_layout
18584
18585 \begin_layout Enumerate
18586
18587 \size small
18588 You should perhaps use 
18589 \begin_inset Quotes eld
18590 \end_inset
18591
18592
18593 \family typewriter
18594 cmd
18595 \family default
18596
18597 \begin_inset Quotes erd
18598 \end_inset
18599
18600  instead.
18601 \end_layout
18602
18603 \begin_layout Enumerate
18604
18605 \size small
18606 You should put a space in front of/after parenthesis.
18607 \end_layout
18608
18609 \begin_layout Enumerate
18610
18611 \size small
18612 You should avoid spaces in front of/after parenthesis.
18613 \end_layout
18614
18615 \begin_layout Enumerate
18616
18617 \size small
18618 \emph on
18619 You should not use punctuation in front of/after quotes.
18620 \end_layout
18621
18622 \begin_layout Enumerate
18623
18624 \size small
18625 Double space found.
18626 \end_layout
18627
18628 \begin_layout Enumerate
18629
18630 \size small
18631 You should put punctuation outside inner/inside display math mode.
18632 \end_layout
18633
18634 \begin_layout Enumerate
18635
18636 \size small
18637 You ought to not use primitive \SpecialChar TeX
18638  in \SpecialChar LaTeX
18639  code.
18640 \end_layout
18641
18642 \begin_layout Enumerate
18643
18644 \size small
18645 You should remove spaces in front of 
18646 \begin_inset Quotes eld
18647 \end_inset
18648
18649
18650 \family typewriter
18651 %s
18652 \family default
18653
18654 \begin_inset Quotes erd
18655 \end_inset
18656
18657
18658 \end_layout
18659
18660 \begin_layout Enumerate
18661
18662 \size small
18663 \begin_inset Quotes eld
18664 \end_inset
18665
18666
18667 \family typewriter
18668 %s
18669 \family default
18670
18671 \begin_inset Quotes erd
18672 \end_inset
18673
18674  is normally not followed by 
18675 \begin_inset Quotes eld
18676 \end_inset
18677
18678
18679 \family typewriter
18680 %c
18681 \family default
18682
18683 \begin_inset Quotes erd
18684 \end_inset
18685
18686 .
18687 \end_layout
18688
18689 \begin_layout Standard
18690 In later versions of \SpecialChar LyX
18691 , we hope to provide a more complete interface to this
18692  tool (and it's smaller cousin 
18693 \family typewriter
18694 lacheck
18695 \family default
18696 ) to exploit the full power of it.
18697  But it's not exactly useless as it is now: go try it on one of your existing
18698  documents of a certain length and be surprised.
18699 \end_layout
18700
18701 \begin_layout Section
18702 Version Control in \SpecialChar LyX
18703
18704 \end_layout
18705
18706 \begin_layout Standard
18707 by
18708 \noun on
18709  Lars Gullik Bjønnes 
18710 \noun default
18711 and 
18712 \noun on
18713 Pavel Sanda
18714 \end_layout
18715
18716 \begin_layout Subsection
18717 Introduction
18718 \end_layout
18719
18720 \begin_layout Standard
18721 \SpecialChar LyX
18722  supports some of the most basic RCS/CVS/SVN/GIT commands.
18723  If you need something a bit more sophisticated you will have to do that
18724  manually in a terminal.
18725 \end_layout
18726
18727 \begin_layout Standard
18728 Also note that CVS support is not as good as subversion support so we advise
18729  using SVN instead.
18730  A good place to start learning Subversion is SVN Book
18731 \begin_inset Foot
18732 status collapsed
18733
18734 \begin_layout Plain Layout
18735 \begin_inset CommandInset href
18736 LatexCommand href
18737 target "http://svnbook.red-bean.com/"
18738
18739 \end_inset
18740
18741
18742 \end_layout
18743
18744 \end_inset
18745
18746 .
18747  In the case of RCS you should read 
18748 \begin_inset Quotes eld
18749 \end_inset
18750
18751 rcsintro
18752 \begin_inset Quotes erd
18753 \end_inset
18754
18755  (a man file, read it with 
18756 \family typewriter
18757 man rcsintro
18758 \family default
18759 ).
18760  This file describes all the basic features of RCS.
18761  You should especially notice the comment about a RCS directory, and the
18762  notion of a master RCS file (the file ending in 
18763 \family typewriter
18764 ,v
18765 \family default
18766 ).
18767 \end_layout
18768
18769 \begin_layout Standard
18770 Before you begin to use the version control features in \SpecialChar LyX
18771 , you should be
18772  familiar with RCS/CVS/SVN/GIT usage.
18773  The implementation in \SpecialChar LyX
18774  assumes a recent version of the GNU RCS or CVS/SVN
18775  package — no guarantees are made for older versions.
18776  Most of the log messages are not currently displayed after operations —
18777  you can check them in the Messages pane if unsure.
18778  Regular users of version control will appreciate VC toolbar, which can
18779  be enabled via 
18780 \family sans
18781 View\SpecialChar menuseparator
18782 Toolbars\SpecialChar menuseparator
18783 Version
18784 \begin_inset space ~
18785 \end_inset
18786
18787 Control
18788 \family default
18789 .
18790 \end_layout
18791
18792 \begin_layout Standard
18793 For introducing your own external commands consult vc-command in the manual
18794  of \SpecialChar LyX
18795  functions.
18796 \end_layout
18797
18798 \begin_layout Standard
18799 It is strongly recommended to store documents in uncompressed format if
18800  using version control (uncheck 
18801 \family sans
18802 Document\SpecialChar menuseparator
18803 Compressed
18804 \family default
18805  if it is checked): Uncompressed LyX documents are text files and therefore
18806  for merging two different versions by version control systems.
18807  Compressed LyX documents are binary files, which cannot be merged by version
18808  control systems.
18809 \end_layout
18810
18811 \begin_layout Subsection
18812 RCS commands in \SpecialChar LyX
18813
18814 \end_layout
18815
18816 \begin_layout Standard
18817 The following sections describe the RCS commands supported by \SpecialChar LyX
18818 .
18819  You can find them in the 
18820 \family sans
18821 File\SpecialChar menuseparator
18822 Version
18823 \begin_inset space ~
18824 \end_inset
18825
18826 Control
18827 \family default
18828  submenu.
18829  \SpecialChar LyX
18830  was tested against RCS 5.7/5.8.
18831 \end_layout
18832
18833 \begin_layout Subsubsection
18834
18835 \family sans
18836 Register
18837 \end_layout
18838
18839 \begin_layout Standard
18840 If your document is not under revision control, this is the only item shown
18841  in the menu.
18842  And if it is under revision control, the 
18843 \family sans
18844 Register
18845 \family default
18846  item is not visible.
18847  
18848 \end_layout
18849
18850 \begin_layout Standard
18851 This command registers your document with RCS (unless you are under the
18852  directory managed by CVS)\SpecialChar endofsentence
18853  You are asked interactively to supply an initial
18854  description of the document.
18855  The document is now set in Read-Only mode and you have to 
18856 \family sans
18857 Check
18858 \begin_inset space ~
18859 \end_inset
18860
18861 Out
18862 \begin_inset space ~
18863 \end_inset
18864
18865 For
18866 \begin_inset space ~
18867 \end_inset
18868
18869 Edit
18870 \family default
18871 , before making any changes to it.
18872  A document under revision control has a 
18873 \begin_inset Quotes eld
18874 \end_inset
18875
18876 [RCS:<version> <locker>]
18877 \begin_inset Quotes erd
18878 \end_inset
18879
18880  item tagged to the filename in the minibuffer.
18881 \end_layout
18882
18883 \begin_layout Standard
18884 RCS command that is run: 
18885 \family typewriter
18886 ci -q -u -i -t-"<initial description>" <file-name>
18887 \end_layout
18888
18889 \begin_layout Standard
18890 Read 
18891 \family typewriter
18892 man ci
18893 \family default
18894  to understand the switches.
18895  
18896 \end_layout
18897
18898 \begin_layout Subsubsection
18899
18900 \family sans
18901 Check In Changes
18902 \end_layout
18903
18904 \begin_layout Standard
18905 When you are finished editing a file, you check in your changes.
18906  When you do this, you are asked for a description of the changes.
18907  This is stored in the history log.
18908  The version number is bumped, your changes are applied to the master RCS
18909  file, the document is unlocked and set to Read-Only mode.
18910 \end_layout
18911
18912 \begin_layout Standard
18913 RCS command: 
18914 \family typewriter
18915 ci -q -u -m"<description>" <file-name>
18916 \end_layout
18917
18918 \begin_layout Subsubsection
18919
18920 \family sans
18921 Check Out For Edit
18922 \end_layout
18923
18924 \begin_layout Standard
18925 By doing this you lock the document so that only you can edit it.
18926  This will also make the document Read-Write only for you.
18927  You will usually continue editing for a while and when you are finished
18928  you check in your changes.
18929  The status line is changed to reflect that you have locked the file.
18930 \end_layout
18931
18932 \begin_layout Standard
18933 RCS command: 
18934 \family typewriter
18935 co -q -l <file-name>
18936 \end_layout
18937
18938 \begin_layout Subsubsection
18939
18940 \family sans
18941 Revert To Repository Version
18942 \end_layout
18943
18944 \begin_layout Standard
18945 This will discard all changes made to the document since the last check
18946  in.
18947  You get a warning before changes are discarded.
18948 \end_layout
18949
18950 \begin_layout Standard
18951 RCS command: 
18952 \family typewriter
18953 co -f -u<version> <file-name>
18954 \end_layout
18955
18956 \begin_layout Subsubsection
18957
18958 \family sans
18959 Copy
18960 \end_layout
18961
18962 \begin_layout Standard
18963 This will create a copy of the current document.
18964  Since RCS does not support copy operations natively, the version history
18965  is not preserved, and the copy is added as a new file.
18966  It requires a clean document without any changes since the last checkin.
18967  You are asked for a file name and a description of the copy operation.
18968  After that the copy is created, both locally and in the repository.
18969  If the parent directories of the copied and original document differ, all
18970  relative paths of included files of the copy are adjusted (like in 
18971 \family sans
18972 File\SpecialChar menuseparator
18973 Save As
18974 \family default
18975 \SpecialChar ldots
18976 ).
18977  Finally, the copy is loaded instead of the original document.
18978 \end_layout
18979
18980 \begin_layout Labeling
18981 \labelwidthstring 00.00.0000
18982 RCS
18983 \begin_inset space ~
18984 \end_inset
18985
18986 commands: 
18987 \begin_inset space ~
18988 \end_inset
18989
18990
18991 \begin_inset Newline newline
18992 \end_inset
18993
18994 Copy 
18995 \begin_inset Flex Code
18996 status collapsed
18997
18998 \begin_layout Plain Layout
18999
19000 \family typewriter
19001 \begin_inset Quotes eld
19002 \end_inset
19003
19004 <file-name>
19005 \begin_inset Quotes erd
19006 \end_inset
19007
19008
19009 \end_layout
19010
19011 \end_inset
19012
19013  to 
19014 \begin_inset Flex Code
19015 status collapsed
19016
19017 \begin_layout Plain Layout
19018
19019 \family typewriter
19020 \begin_inset Quotes eld
19021 \end_inset
19022
19023 <new-file-name>
19024 \begin_inset Quotes erd
19025 \end_inset
19026
19027
19028 \end_layout
19029
19030 \end_inset
19031
19032
19033 \begin_inset Newline newline
19034 \end_inset
19035
19036
19037 \begin_inset Flex Code
19038 status collapsed
19039
19040 \begin_layout Plain Layout
19041 ci -q -u 
19042 \family typewriter
19043 -i 
19044 \begin_inset Quotes eld
19045 \end_inset
19046
19047 <new-file-name>
19048 \begin_inset Quotes erd
19049 \end_inset
19050
19051
19052 \end_layout
19053
19054 \end_inset
19055
19056
19057 \end_layout
19058
19059 \begin_layout Subsubsection
19060
19061 \family sans
19062 Undo Last Checkin
19063 \end_layout
19064
19065 \begin_layout Standard
19066 This makes as if the last check in never happened.
19067  No changes are made to the document loaded into \SpecialChar LyX
19068 , but the last version
19069  is removed from the master RCS file.
19070 \end_layout
19071
19072 \begin_layout Standard
19073 RCS command: 
19074 \family typewriter
19075 rcs -o<version> <file-name>
19076 \end_layout
19077
19078 \begin_layout Subsubsection
19079
19080 \family sans
19081 Show History
19082 \end_layout
19083
19084 \begin_layout Standard
19085 This shows the complete history of the RCS document.
19086  The output of 
19087 \family typewriter
19088 rlog <file-name>
19089 \family default
19090  is shown in a browser.
19091  See 
19092 \family typewriter
19093 man rlog
19094 \family default
19095  for more info.
19096 \end_layout
19097
19098 \begin_layout Subsubsection
19099 Revision info
19100 \end_layout
19101
19102 \begin_layout Standard
19103 \SpecialChar LyX
19104  supports RCS version number, author name, date and time of last commit.
19105  All those are extracted from 
19106 \family typewriter
19107 rlog -r <file-name>
19108 \family default
19109 .
19110  See 
19111 \begin_inset CommandInset ref
19112 LatexCommand ref
19113 reference "subsec:VCS-Revision-Information"
19114
19115 \end_inset
19116
19117  for details.
19118 \end_layout
19119
19120 \begin_layout Subsection
19121 CVS commands in \SpecialChar LyX
19122
19123 \end_layout
19124
19125 \begin_layout Standard
19126 A subset of CVS operations is supported by \SpecialChar LyX
19127 .
19128  You can find the commands in the 
19129 \family sans
19130 File\SpecialChar menuseparator
19131 Version
19132 \begin_inset space ~
19133 \end_inset
19134
19135 Control
19136 \family default
19137  submenu.
19138  The version control system SVN is more powerful, so please use it instead
19139  of CVS if possible.
19140 \end_layout
19141
19142 \begin_layout Subsubsection
19143
19144 \family sans
19145 General CVS usage
19146 \end_layout
19147
19148 \begin_layout Standard
19149 If you start from scratch with CVS you have to create your repository and
19150  checkout the working copy with external tools.
19151  If you're using a client-server setup you may need to login before doing
19152  the first repository checkout.
19153 \end_layout
19154
19155 \begin_layout Standard
19156 If your documents are under revision control and others are using the same
19157  repository problems arise when different changes to the same document at
19158  the same location happen.
19159  Standard CVS repositories don't operate with a file locking mechanism.
19160  This may be surprising, but conflicts only occur if people disagree on
19161  the proper content of the same part of a document.
19162  So, if co-workers are used to communicate regularly, these conflicts occur
19163  rarely.
19164  If they don't communicate they have a fundamental problem anyway.
19165  Nevertheless some people like to work with so called 
19166 \begin_inset Quotes eld
19167 \end_inset
19168
19169 reserved checkouts
19170 \begin_inset Quotes erd
19171 \end_inset
19172
19173 .
19174  If they do so the working copy of all files is readonly when checked out
19175  first and the user starts editing after using a special command to make
19176  the working copy writable.
19177  When the changes are checked in the working copy returns to readonly state.
19178  With \SpecialChar LyX
19179  one has to edit the 
19180 \begin_inset Flex Code
19181 status collapsed
19182
19183 \begin_layout Plain Layout
19184 .cvsrc
19185 \end_layout
19186
19187 \end_inset
19188
19189  file and add the line 
19190 \begin_inset Flex Code
19191 status collapsed
19192
19193 \begin_layout Plain Layout
19194 cvs -r
19195 \end_layout
19196
19197 \end_inset
19198
19199  to work with reserved checkouts.
19200  The benefit is the possibility to see who is using a writable copy of some
19201  document.
19202  It's not guaranteed only one user makes a copy writable.
19203 \end_layout
19204
19205 \begin_layout Standard
19206 \SpecialChar LyX
19207  tries to guess if you're using reserved or non-reserved checkouts.
19208  If your working copy is readonly or it is writable and an additional copy
19209  of your document exists in the CVS/Base sub-directory a reserved otherwise
19210  a non-reserved checkout is assumed.
19211  When a reserved checkout is detected you have to use 
19212 \begin_inset Flex Noun
19213 status collapsed
19214
19215 \begin_layout Plain Layout
19216 Check Out
19217 \end_layout
19218
19219 \end_inset
19220
19221  to make your working copy writable if it's readonly.
19222  After doing so the 
19223 \begin_inset Flex Noun
19224 status collapsed
19225
19226 \begin_layout Plain Layout
19227 Check In
19228 \end_layout
19229
19230 \end_inset
19231
19232  operation is possible and that makes your working copy readonly again after
19233  transferring your changes to the repository.
19234 \end_layout
19235
19236 \begin_layout Standard
19237 More information about CVS can be found here 
19238 \begin_inset Flex URL
19239 status collapsed
19240
19241 \begin_layout Plain Layout
19242
19243 http://www.nongnu.org/cvs
19244 \end_layout
19245
19246 \end_inset
19247
19248  and here 
19249 \begin_inset Flex URL
19250 status collapsed
19251
19252 \begin_layout Plain Layout
19253
19254 http://ximbiot.com/cvs
19255 \end_layout
19256
19257 \end_inset
19258
19259 .
19260 \end_layout
19261
19262 \begin_layout Standard
19263 Read 
19264 \family typewriter
19265 man cvs
19266 \family default
19267  to understand the sub-commands and the switches mentioned below.
19268 \end_layout
19269
19270 \begin_layout Subsubsection
19271
19272 \family sans
19273 Register
19274 \end_layout
19275
19276 \begin_layout Standard
19277 If your document is not under revision control, this is the only item shown
19278  in the menu.
19279  And if it is under revision control, the 
19280 \family sans
19281 Register
19282 \family default
19283  item is not visible.
19284  
19285 \end_layout
19286
19287 \begin_layout Standard
19288 This command registers in CVS your document 
19289 \begin_inset Flex Strong
19290 status collapsed
19291
19292 \begin_layout Plain Layout
19293
19294 \emph on
19295 only
19296 \end_layout
19297
19298 \end_inset
19299
19300  in the case you have already the documents directory under CVS control
19301  (in particular 
19302 \family typewriter
19303 CVS/Entries
19304 \family default
19305  file exists).
19306  This means you have to create or checkout the archive by yourself using
19307  external tools.
19308  (In case you forget that step \SpecialChar LyX
19309  registers the document with RCS.)
19310 \end_layout
19311
19312 \begin_layout Standard
19313 Then you are asked interactively to supply an initial description of the
19314  document.
19315  Don't forget that registered file is not yet checked in.
19316 \end_layout
19317
19318 \begin_layout Standard
19319 CVS command that is run: 
19320 \family typewriter
19321 cvs -q add -m"<entered message>" "<file-name>"
19322 \end_layout
19323
19324 \begin_layout Standard
19325 The term 
19326 \family typewriter
19327 "<file-name>"
19328 \family default
19329  above and for all other CVS commands is an abbreviation for 
19330 \begin_inset Quotes eld
19331 \end_inset
19332
19333 change the current working directory to file location and use the file name
19334  without path component as argument
19335 \begin_inset Quotes erd
19336 \end_inset
19337
19338 .
19339 \end_layout
19340
19341 \begin_layout Subsubsection
19342
19343 \family sans
19344 Check In Changes
19345 \end_layout
19346
19347 \begin_layout Standard
19348 When you are finished editing a file, you commit your changes.
19349  When you do this and you had changed the document, you are asked for a
19350  description of the changes.
19351  After that changes are written to the repository.
19352  In case you didn't change the document and a reserved checkout is detected
19353  the reservation made on 
19354 \begin_inset Flex Noun
19355 status collapsed
19356
19357 \begin_layout Plain Layout
19358 Check Out
19359 \end_layout
19360
19361 \end_inset
19362
19363  is undone.
19364 \end_layout
19365
19366 \begin_layout Labeling
19367 \labelwidthstring 00.00.0000
19368 CVS
19369 \begin_inset space ~
19370 \end_inset
19371
19372 command: 
19373 \begin_inset space ~
19374 \end_inset
19375
19376
19377 \begin_inset Newline newline
19378 \end_inset
19379
19380
19381 \begin_inset Flex Code
19382 status collapsed
19383
19384 \begin_layout Plain Layout
19385 cvs 
19386 \family typewriter
19387 -q commit -m"<description>" "<file-name>"
19388 \end_layout
19389
19390 \end_inset
19391
19392  or
19393 \begin_inset Newline newline
19394 \end_inset
19395
19396
19397 \begin_inset Flex Code
19398 status collapsed
19399
19400 \begin_layout Plain Layout
19401 cvs -q unedit 
19402 \family typewriter
19403 "<file-name>"
19404 \end_layout
19405
19406 \end_inset
19407
19408
19409 \end_layout
19410
19411 \begin_layout Subsubsection
19412
19413 \family sans
19414 Check Out Changes
19415 \end_layout
19416
19417 \begin_layout Standard
19418 When you are sharing a repository with others, you may have to incorporate
19419  their changes into your working copy.
19420 \end_layout
19421
19422 \begin_layout Standard
19423 CVS command: 
19424 \family typewriter
19425 cvs -q update "<file-name>"
19426 \end_layout
19427
19428 \begin_layout Standard
19429 If a readonly checkout is detected the working copy is made writable and
19430  reserved.
19431 \end_layout
19432
19433 \begin_layout Standard
19434 CVS command: 
19435 \family typewriter
19436 cvs -q edit "<file-name>"
19437 \end_layout
19438
19439 \begin_layout Subsubsection
19440
19441 \family sans
19442 Revert To Repository Version
19443 \end_layout
19444
19445 \begin_layout Standard
19446 This will discard all changes made to the document since the last check
19447  in.
19448  You get a warning before changes are discarded.
19449  Firstly the file is deleted, secondly CVS update command is run.
19450 \end_layout
19451
19452 \begin_layout Standard
19453 CVS command: 
19454 \family typewriter
19455 cvs -q update "<file-name>"
19456 \end_layout
19457
19458 \begin_layout Standard
19459 If a reserved checkout is detected and the working copy has no changes only
19460  the reservation is undone.
19461 \end_layout
19462
19463 \begin_layout Standard
19464 CVS command: 
19465 \family typewriter
19466 cvs -q unedit "<file-name>"
19467 \end_layout
19468
19469 \begin_layout Subsubsection
19470
19471 \family sans
19472 Copy
19473 \end_layout
19474
19475 \begin_layout Standard
19476 This will create a copy of the current document.
19477  Since CVS does not support copy operations natively, the version history
19478  is not preserved, and the copy is added as a new file.
19479  It requires a clean document without any changes since the last checkin.
19480  You are asked for a file name and a description of the copy operation.
19481  After that the copy is created, both locally and in the repository.
19482  If the parent directories of the copied and original document differ, all
19483  relative paths of included files of the copy are adjusted (like in 
19484 \family sans
19485 File\SpecialChar menuseparator
19486 Save As
19487 \family default
19488 \SpecialChar ldots
19489 ).
19490  Finally, the copy is loaded instead of the original document.
19491 \end_layout
19492
19493 \begin_layout Labeling
19494 \labelwidthstring 00.00.0000
19495 CVS
19496 \begin_inset space ~
19497 \end_inset
19498
19499 commands: 
19500 \begin_inset space ~
19501 \end_inset
19502
19503
19504 \begin_inset Newline newline
19505 \end_inset
19506
19507 Copy 
19508 \begin_inset Flex Code
19509 status collapsed
19510
19511 \begin_layout Plain Layout
19512
19513 \family typewriter
19514 \begin_inset Quotes eld
19515 \end_inset
19516
19517 <file-name>
19518 \begin_inset Quotes erd
19519 \end_inset
19520
19521
19522 \end_layout
19523
19524 \end_inset
19525
19526  to 
19527 \begin_inset Flex Code
19528 status collapsed
19529
19530 \begin_layout Plain Layout
19531
19532 \family typewriter
19533 \begin_inset Quotes eld
19534 \end_inset
19535
19536 <new-file-name>
19537 \begin_inset Quotes erd
19538 \end_inset
19539
19540
19541 \end_layout
19542
19543 \end_inset
19544
19545
19546 \begin_inset Newline newline
19547 \end_inset
19548
19549
19550 \begin_inset Flex Code
19551 status collapsed
19552
19553 \begin_layout Plain Layout
19554 cvs -q add 
19555 \family typewriter
19556
19557 \begin_inset Quotes eld
19558 \end_inset
19559
19560 <new-file-name>
19561 \begin_inset Quotes erd
19562 \end_inset
19563
19564
19565 \end_layout
19566
19567 \end_inset
19568
19569
19570 \end_layout
19571
19572 \begin_layout Subsubsection
19573
19574 \family sans
19575 Rename
19576 \end_layout
19577
19578 \begin_layout Standard
19579 This will rename the current document.
19580  Since CVS does not support rename operations natively, the version history
19581  is not preserved, the renamed document is added as a new file, and the
19582  original document is deleted.
19583  It requires a clean document without any changes since the last checkin.
19584  You are asked for a file name and a description of the rename operation.
19585  After that the document is renamed, both locally and in the repository.
19586  If the parent directories of the new and old file names differ, all relative
19587  paths of included files are adjusted (like in 
19588 \family sans
19589 File\SpecialChar menuseparator
19590 Save As
19591 \family default
19592 \SpecialChar ldots
19593 ).
19594  Finally, the document is reloaded using the new name.
19595 \end_layout
19596
19597 \begin_layout Labeling
19598 \labelwidthstring 00.00.0000
19599 CVS
19600 \begin_inset space ~
19601 \end_inset
19602
19603 commands: 
19604 \begin_inset space ~
19605 \end_inset
19606
19607
19608 \begin_inset Newline newline
19609 \end_inset
19610
19611 Rename 
19612 \begin_inset Flex Code
19613 status collapsed
19614
19615 \begin_layout Plain Layout
19616
19617 \family typewriter
19618 \begin_inset Quotes eld
19619 \end_inset
19620
19621 <file-name>
19622 \begin_inset Quotes erd
19623 \end_inset
19624
19625
19626 \end_layout
19627
19628 \end_inset
19629
19630  to 
19631 \begin_inset Flex Code
19632 status collapsed
19633
19634 \begin_layout Plain Layout
19635
19636 \family typewriter
19637 \begin_inset Quotes eld
19638 \end_inset
19639
19640 <new-file-name>
19641 \begin_inset Quotes erd
19642 \end_inset
19643
19644
19645 \end_layout
19646
19647 \end_inset
19648
19649
19650 \begin_inset Newline newline
19651 \end_inset
19652
19653
19654 \begin_inset Flex Code
19655 status collapsed
19656
19657 \begin_layout Plain Layout
19658 cvs -q add 
19659 \family typewriter
19660
19661 \begin_inset Quotes eld
19662 \end_inset
19663
19664 <new-file-name>
19665 \begin_inset Quotes erd
19666 \end_inset
19667
19668
19669 \end_layout
19670
19671 \end_inset
19672
19673
19674 \begin_inset Newline newline
19675 \end_inset
19676
19677
19678 \begin_inset Flex Code
19679 status collapsed
19680
19681 \begin_layout Plain Layout
19682 cvs -q remove 
19683 \family typewriter
19684
19685 \begin_inset Quotes eld
19686 \end_inset
19687
19688 <file-name>
19689 \begin_inset Quotes erd
19690 \end_inset
19691
19692
19693 \end_layout
19694
19695 \end_inset
19696
19697
19698 \end_layout
19699
19700 \begin_layout Subsubsection
19701 Update of the local directory checkout from repository
19702 \end_layout
19703
19704 \begin_layout Standard
19705 Once your documents gets more complex, containing sub-documents and pictures,
19706  including external 
19707 \begin_inset Flex Code
19708 status collapsed
19709
19710 \begin_layout Plain Layout
19711 .tex
19712 \end_layout
19713
19714 \end_inset
19715
19716  files and so on using version control becomes more complicated.
19717  \SpecialChar LyX
19718  supports updating the whole tree in which resides the document.
19719  This become especially useful once you cooperate with people which neither
19720  have detailed knowledge about CVS usage nor they have ambition to commit
19721  additional material to the repository.
19722  You have to organize the files structure so that all external files are
19723  in the same directory or subdirectories of the document.
19724  It's good practice anyway to store multipart documents in an extra directory.
19725 \end_layout
19726
19727 \begin_layout Standard
19728 The 
19729 \begin_inset Flex Code
19730 status collapsed
19731
19732 \begin_layout Plain Layout
19733 Update local directory from repository
19734 \end_layout
19735
19736 \end_inset
19737
19738  command updates the whole directory.
19739  If local changes are detected user is warned before update starts.
19740  In case of merge conflicts both versions of the conflicting document parts
19741  are placed in the final document.
19742  You have to review and correct the result of the merge.
19743  You'll find the conflicts enclosed in pairs of 
19744 \begin_inset Flex Code
19745 status collapsed
19746
19747 \begin_layout Plain Layout
19748 <<<<<<<
19749 \end_layout
19750
19751 \end_inset
19752
19753  and 
19754 \begin_inset Flex Code
19755 status collapsed
19756
19757 \begin_layout Plain Layout
19758 >>>>>>>
19759 \end_layout
19760
19761 \end_inset
19762
19763  separated by 
19764 \begin_inset Flex Code
19765 status collapsed
19766
19767 \begin_layout Plain Layout
19768 =======
19769 \end_layout
19770
19771 \end_inset
19772
19773 .
19774  The first part is your version as before the update operation with the
19775  document name prepended.
19776  The second one is the repository version with the version number after
19777  the sequence of 
19778 \begin_inset Flex Code
19779 status collapsed
19780
19781 \begin_layout Plain Layout
19782 >
19783 \end_layout
19784
19785 \end_inset
19786
19787  signs.
19788 \end_layout
19789
19790 \begin_layout Labeling
19791 \labelwidthstring 00.00.0000
19792 CVS
19793 \begin_inset space ~
19794 \end_inset
19795
19796 commands: 
19797 \begin_inset space ~
19798 \end_inset
19799
19800
19801 \begin_inset Newline newline
19802 \end_inset
19803
19804
19805 \begin_inset Flex Code
19806 status collapsed
19807
19808 \begin_layout Plain Layout
19809 cd $path; cvs diff 
19810 \family typewriter
19811 "."
19812 \end_layout
19813
19814 \end_inset
19815
19816  (Ask if changes are detected.)
19817 \begin_inset Newline newline
19818 \end_inset
19819
19820
19821 \begin_inset Flex Code
19822 status collapsed
19823
19824 \begin_layout Plain Layout
19825 cd $path; cvs -q update 
19826 \family typewriter
19827 "."
19828 \end_layout
19829
19830 \end_inset
19831
19832
19833 \end_layout
19834
19835 \begin_layout Standard
19836 where 
19837 \begin_inset Flex Code
19838 status collapsed
19839
19840 \begin_layout Plain Layout
19841 $path
19842 \end_layout
19843
19844 \end_inset
19845
19846  stands for the path to the document.
19847 \end_layout
19848
19849 \begin_layout Subsubsection
19850
19851 \family sans
19852 Show History
19853 \end_layout
19854
19855 \begin_layout Standard
19856 This shows the complete history of the CVS document.
19857  The output of 
19858 \family typewriter
19859 cvs log "<file-name>"
19860 \family default
19861  is shown in a browser.
19862 \end_layout
19863
19864 \begin_layout Subsubsection
19865 Revision info
19866 \end_layout
19867
19868 \begin_layout Standard
19869 \SpecialChar LyX
19870  supports CVS version number, author name, date and time of last commit.
19871  All those are extracted from 
19872 \family typewriter
19873 cvs log -r <file-name>
19874 \family default
19875 .
19876  See 
19877 \begin_inset CommandInset ref
19878 LatexCommand ref
19879 reference "subsec:VCS-Revision-Information"
19880
19881 \end_inset
19882
19883  for details.
19884 \end_layout
19885
19886 \begin_layout Subsection
19887 SVN commands in \SpecialChar LyX
19888
19889 \end_layout
19890
19891 \begin_layout Standard
19892 SVN is now partially supported by \SpecialChar LyX
19893 .
19894  You can find the commands in the 
19895 \family sans
19896 File\SpecialChar menuseparator
19897 Version
19898 \begin_inset space ~
19899 \end_inset
19900
19901 Control
19902 \family default
19903  submenu.
19904  Please note that if you use password protected access to repository via
19905  ssh, you will be asked in terminal window.
19906  \SpecialChar LyX
19907  was tested against SVN 1.5, 1.6, 1.7 and 1.8
19908 \begin_inset Foot
19909 status open
19910
19911 \begin_layout Plain Layout
19912 Most of the commands will work with 1.4 too, see 
19913 \begin_inset CommandInset ref
19914 LatexCommand ref
19915 reference "subsec:SVN-Repo-Update"
19916
19917 \end_inset
19918
19919 .
19920  There seems to be currently unresolved permissions problem under SVN 1.8
19921  with reverting changes when file is locked.
19922 \end_layout
19923
19924 \end_inset
19925
19926
19927 \end_layout
19928
19929 \begin_layout Subsubsection
19930
19931 \family sans
19932 Register
19933 \end_layout
19934
19935 \begin_layout Standard
19936 If your document is not under revision control, this is the only item shown
19937  in the menu.
19938  And if it is under revision control, the 
19939 \family sans
19940 Register
19941 \family default
19942  item is not visible.
19943 \end_layout
19944
19945 \begin_layout Standard
19946 This command registers in SVN your document ONLY in case you have already
19947  the documents directory under SVN control (in particular 
19948 \family typewriter
19949 .svn/entries
19950 \family default
19951  file exists).
19952  This means you have to checkout the archive by yourself.
19953 \end_layout
19954
19955 \begin_layout Standard
19956 Then you are asked interactively to supply an initial description of the
19957  document.
19958  Don't forget that registered file is not yet commited.
19959 \end_layout
19960
19961 \begin_layout Standard
19962 SVN command that is run: 
19963 \family typewriter
19964 svn add -q 
19965 \begin_inset Quotes eld
19966 \end_inset
19967
19968 <file-name>
19969 \begin_inset Quotes erd
19970 \end_inset
19971
19972
19973 \end_layout
19974
19975 \begin_layout Standard
19976 Read 
19977 \family typewriter
19978 man svn
19979 \family default
19980  to understand the switches.
19981 \end_layout
19982
19983 \begin_layout Subsubsection
19984
19985 \family sans
19986 Check In Changes
19987 \end_layout
19988
19989 \begin_layout Standard
19990 When you are finished editing a file, you commit your changes.
19991  When you do this, you are asked for a description of the changes.
19992  After that changes are commited.
19993 \end_layout
19994
19995 \begin_layout Standard
19996 SVN command:
19997 \begin_inset Foot
19998 status collapsed
19999
20000 \begin_layout Plain Layout
20001 In case locking is not enabled.
20002  See Section 
20003 \begin_inset CommandInset ref
20004 LatexCommand ref
20005 reference "subsec:SVN-File-Locking"
20006
20007 \end_inset
20008
20009 .
20010 \end_layout
20011
20012 \end_inset
20013
20014  
20015 \family typewriter
20016 svn commit -q -m"<description>" <file-name>
20017 \end_layout
20018
20019 \begin_layout Subsubsection
20020
20021 \family sans
20022 Check Out For Edit
20023 \end_layout
20024
20025 \begin_layout Standard
20026 Updates the changes of this file from the repository.
20027  Be sure you understand SVN merging and conflicts resolving before using
20028  this function, because all conflicts has to be resolved manually by you!
20029 \end_layout
20030
20031 \begin_layout Standard
20032 SVN command:
20033 \begin_inset Foot
20034 status collapsed
20035
20036 \begin_layout Plain Layout
20037 Ditto.
20038 \end_layout
20039
20040 \end_inset
20041
20042  
20043 \family typewriter
20044 svn update --non-interactive 
20045 \begin_inset Quotes eld
20046 \end_inset
20047
20048 <file-name>
20049 \begin_inset Quotes erd
20050 \end_inset
20051
20052
20053 \end_layout
20054
20055 \begin_layout Subsubsection
20056
20057 \family sans
20058 Revert To Repository Version
20059 \end_layout
20060
20061 \begin_layout Standard
20062 This will discard all changes made to the document since the last check
20063  in.
20064  You get a warning before changes are discarded.
20065 \end_layout
20066
20067 \begin_layout Standard
20068 SVN command: 
20069 \family typewriter
20070 svn revert -q 
20071 \begin_inset Quotes eld
20072 \end_inset
20073
20074 <file-name>
20075 \begin_inset Quotes erd
20076 \end_inset
20077
20078
20079 \end_layout
20080
20081 \begin_layout Subsubsection
20082
20083 \family sans
20084 Copy
20085 \end_layout
20086
20087 \begin_layout Standard
20088 This will create a copy of the current document including the version history.
20089  It requires a clean document without any changes since the last checkin.
20090  You are asked for a file name and a description of the copy operation.
20091  After that the copy is created, both locally and in the repository.
20092  If the parent directories of the copied and original document differ, all
20093  relative paths of included files of the copy are adjusted (like in 
20094 \family sans
20095 File\SpecialChar menuseparator
20096 Save As
20097 \family default
20098 \SpecialChar ldots
20099 ).
20100  Finally, the copy is loaded instead of the original document.
20101 \end_layout
20102
20103 \begin_layout Labeling
20104 \labelwidthstring 00.00.0000
20105 SVN
20106 \begin_inset space ~
20107 \end_inset
20108
20109 commands: 
20110 \begin_inset space ~
20111 \end_inset
20112
20113
20114 \begin_inset Newline newline
20115 \end_inset
20116
20117
20118 \begin_inset Flex Code
20119 status collapsed
20120
20121 \begin_layout Plain Layout
20122 svn copy -q 
20123 \family typewriter
20124
20125 \begin_inset Quotes eld
20126 \end_inset
20127
20128 <file-name>
20129 \begin_inset Quotes erd
20130 \end_inset
20131
20132  
20133 \begin_inset Quotes eld
20134 \end_inset
20135
20136 <new-file-name>
20137 \begin_inset Quotes erd
20138 \end_inset
20139
20140
20141 \end_layout
20142
20143 \end_inset
20144
20145
20146 \begin_inset Newline newline
20147 \end_inset
20148
20149
20150 \begin_inset Flex Code
20151 status collapsed
20152
20153 \begin_layout Plain Layout
20154 svn commit
20155 \end_layout
20156
20157 \end_inset
20158
20159
20160 \end_layout
20161
20162 \begin_layout Subsubsection
20163
20164 \family sans
20165 Rename
20166 \end_layout
20167
20168 \begin_layout Standard
20169 This will rename the current document including the version history.
20170  It requires a clean document without any changes since the last checkin.
20171  You are asked for a file name and a description of the rename operation.
20172  After that the document is renamed, both locally and in the repository.
20173  If the parent directories of the new and old file names differ, all relative
20174  paths of included files are adjusted (like in 
20175 \family sans
20176 File\SpecialChar menuseparator
20177 Save As
20178 \family default
20179 \SpecialChar ldots
20180 ).
20181  Finally, the document is reloaded using the new name.
20182 \end_layout
20183
20184 \begin_layout Labeling
20185 \labelwidthstring 00.00.0000
20186 SVN
20187 \begin_inset space ~
20188 \end_inset
20189
20190 commands: 
20191 \begin_inset space ~
20192 \end_inset
20193
20194
20195 \begin_inset Newline newline
20196 \end_inset
20197
20198
20199 \begin_inset Flex Code
20200 status collapsed
20201
20202 \begin_layout Plain Layout
20203 svn move -q 
20204 \family typewriter
20205
20206 \begin_inset Quotes eld
20207 \end_inset
20208
20209 <file-name>
20210 \begin_inset Quotes erd
20211 \end_inset
20212
20213  
20214 \begin_inset Quotes eld
20215 \end_inset
20216
20217 <new-file-name>
20218 \begin_inset Quotes erd
20219 \end_inset
20220
20221
20222 \end_layout
20223
20224 \end_inset
20225
20226
20227 \begin_inset Newline newline
20228 \end_inset
20229
20230
20231 \begin_inset Flex Code
20232 status collapsed
20233
20234 \begin_layout Plain Layout
20235 svn commit
20236 \end_layout
20237
20238 \end_inset
20239
20240
20241 \end_layout
20242
20243 \begin_layout Subsubsection
20244 \begin_inset CommandInset label
20245 LatexCommand label
20246 name "subsec:SVN-Repo-Update"
20247
20248 \end_inset
20249
20250 Update of the local directory checkout from repository
20251 \begin_inset Foot
20252 status collapsed
20253
20254 \begin_layout Plain Layout
20255 Note that this command will work only with subversion 
20256 \begin_inset Formula $\geqq1.5$
20257 \end_inset
20258
20259
20260 \end_layout
20261
20262 \end_inset
20263
20264
20265 \end_layout
20266
20267 \begin_layout Standard
20268 All the commands above have one shortcomming - they deal with the current
20269  document only.
20270  Once your document contains pictures, includes external 
20271 \begin_inset Flex Code
20272 status collapsed
20273
20274 \begin_layout Plain Layout
20275 .tex
20276 \end_layout
20277
20278 \end_inset
20279
20280  files and so on administration becomes more complicated.
20281  \SpecialChar LyX
20282  now supports updating the whole tree in which resides the document
20283 \begin_inset Foot
20284 status collapsed
20285
20286 \begin_layout Plain Layout
20287 One need to organize the files structure so that all external files are
20288  in the same directory or subdirectories of the document.
20289  
20290 \end_layout
20291
20292 \end_inset
20293
20294 .
20295  This become especially useful once you cooperate with people which neither
20296  know about subversion management nor they have ambition to commit additional
20297  material to the repository.
20298  
20299 \end_layout
20300
20301 \begin_layout Standard
20302 \begin_inset Flex Code
20303 status collapsed
20304
20305 \begin_layout Plain Layout
20306 Update local directory from repository
20307 \end_layout
20308
20309 \end_inset
20310
20311  command updates the whole directory and in case of merge conflicts local
20312  version of the files are left, so no unintended data loss occurs.
20313  If local changes are detected user is warned before update starts.
20314 \end_layout
20315
20316 \begin_layout Labeling
20317 \labelwidthstring 00.00.0000
20318 SVN
20319 \begin_inset space ~
20320 \end_inset
20321
20322 commands: 
20323 \begin_inset space ~
20324 \end_inset
20325
20326
20327 \begin_inset Newline newline
20328 \end_inset
20329
20330
20331 \begin_inset Flex Code
20332 status collapsed
20333
20334 \begin_layout Plain Layout
20335 svn diff $path
20336 \end_layout
20337
20338 \end_inset
20339
20340  (Ask if changes are detected.)
20341 \begin_inset Newline newline
20342 \end_inset
20343
20344
20345 \begin_inset Flex Code
20346 status collapsed
20347
20348 \begin_layout Plain Layout
20349 svn update –accept mine-full $path
20350 \end_layout
20351
20352 \end_inset
20353
20354
20355 \end_layout
20356
20357 \begin_layout Standard
20358 where 
20359 \begin_inset Flex Code
20360 status collapsed
20361
20362 \begin_layout Plain Layout
20363 $path
20364 \end_layout
20365
20366 \end_inset
20367
20368  stands for the path to the document.
20369 \end_layout
20370
20371 \begin_layout Subsubsection
20372
20373 \family sans
20374 Show History
20375 \end_layout
20376
20377 \begin_layout Standard
20378 This shows the complete history of the SVN document.
20379  The output of 
20380 \family typewriter
20381 svn log 
20382 \begin_inset Quotes eld
20383 \end_inset
20384
20385 <file-name>
20386 \begin_inset Quotes erd
20387 \end_inset
20388
20389
20390 \family default
20391  is shown in a browser.
20392 \end_layout
20393
20394 \begin_layout Subsubsection
20395 File Locking
20396 \begin_inset CommandInset label
20397 LatexCommand label
20398 name "subsec:SVN-File-Locking"
20399
20400 \end_inset
20401
20402
20403 \end_layout
20404
20405 \begin_layout Standard
20406 The file exchange through various revision control systems brings the problem
20407  of merge conflicts in case two different users try to edit the same (parts
20408  of) document.
20409  When such a conflict happens it needs manual resolving and one reasonable
20410  alternative is to provide some kind of locking mechanism, which guarantees
20411  that only one user is allowed to edit file at the given time.
20412 \end_layout
20413
20414 \begin_layout Standard
20415 SVN has two such mechanisms to provide mutual exclusivity for file access
20416  - locks and automatic setting of write permissions (see sec.
20417  
20418 \begin_inset CommandInset ref
20419 LatexCommand ref
20420 reference "subsec:Automatical-Locking-Property"
20421
20422 \end_inset
20423
20424 ) based on 
20425 \begin_inset Flex Code
20426 status collapsed
20427
20428 \begin_layout Plain Layout
20429 svn:needs-lock
20430 \end_layout
20431
20432 \end_inset
20433
20434  file svn property
20435 \begin_inset Foot
20436 status open
20437
20438 \begin_layout Plain Layout
20439 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
20440 \end_layout
20441
20442 \end_inset
20443
20444 .
20445  If this property is detected for a given document \SpecialChar LyX
20446  starts to use SVN locks
20447  for document editing automatically and the whole check-in/out mechanism
20448  switches to the same regimen as for RCS.
20449  This in particular means there are two different modes of file use in \SpecialChar LyX
20450 :
20451 \end_layout
20452
20453 \begin_layout Itemize
20454 Unlocked state.
20455  The loaded file is in the read-only mode.
20456  For editing on needs to check-out.
20457  
20458 \emph on
20459 Check-out
20460 \emph default
20461  consists of updating from the repository and gaining write lock.
20462  If the lock is not possible to obtain, we remain in unlocked state.
20463 \end_layout
20464
20465 \begin_layout Itemize
20466 Locked state.
20467  The loaded file is in the 'normal' edit mode.
20468  No other user is allowed to edit the file.
20469  
20470 \emph on
20471 Check-in
20472 \emph default
20473  consists of commiting changes and releasing write-lock.
20474  If no changes have been made to the document, no commit will be produced
20475 \begin_inset Foot
20476 status collapsed
20477
20478 \begin_layout Plain Layout
20479 Don't be puzzled by the fact that you will be asked for commit message anyway.
20480 \end_layout
20481
20482 \end_inset
20483
20484  and only the write-lock will be released.
20485 \end_layout
20486
20487 \begin_layout Standard
20488 SVN commands:
20489 \end_layout
20490
20491 \begin_layout Labeling
20492 \labelwidthstring 00.00.0000
20493 Check-in:
20494 \family typewriter
20495  svn commit -q -m"<description>" "<file-name>"
20496 \begin_inset Newline newline
20497 \end_inset
20498
20499 svn unlock "<file-name>"
20500 \end_layout
20501
20502 \begin_layout Labeling
20503 \labelwidthstring 00.00.0000
20504 Check-out: 
20505 \family typewriter
20506 svn update "<file-name>"
20507 \begin_inset Newline newline
20508 \end_inset
20509
20510 svn lock "<file-name>"
20511 \end_layout
20512
20513 \begin_layout Subsubsection
20514
20515 \family typewriter
20516 \begin_inset CommandInset label
20517 LatexCommand label
20518 name "subsec:Automatical-Locking-Property"
20519
20520 \end_inset
20521
20522
20523 \family default
20524 Automatic Locking Property
20525 \end_layout
20526
20527 \begin_layout Standard
20528 The above mentioned automatic setting of write permissions of the .lyx file
20529  can be set through
20530 \family sans
20531  File\SpecialChar menuseparator
20532 Version
20533 \begin_inset space ~
20534 \end_inset
20535
20536 Control\SpecialChar menuseparator
20537 Toggle locking property
20538 \family default
20539 .
20540  This command is active only when the file is not locked on the svn server
20541  (i.e.
20542  you need to check-out before proceeding).
20543 \end_layout
20544
20545 \begin_layout Labeling
20546 \labelwidthstring 00.00.0000
20547 SVN
20548 \begin_inset space ~
20549 \end_inset
20550
20551 commands:
20552 \end_layout
20553
20554 \begin_layout Labeling
20555 \labelwidthstring 00.00.0000
20556 Set:
20557 \family typewriter
20558  svn propset svn:needs-lock ON "<file-name>"
20559 \end_layout
20560
20561 \begin_layout Labeling
20562 \labelwidthstring 00.00.0000
20563 Unset: 
20564 \family typewriter
20565 svn propdel svn:needs-lock "<file-name>"
20566 \end_layout
20567
20568 \begin_layout Subsubsection
20569 \begin_inset CommandInset label
20570 LatexCommand label
20571 name "subsec:VCS-Revision-Information"
20572
20573 \end_inset
20574
20575 Revision Information in Documents
20576 \end_layout
20577
20578 \begin_layout Standard
20579 There are more possibilities how to activate revision information in our
20580  document.
20581 \end_layout
20582
20583 \begin_layout Itemize
20584 \SpecialChar LyX
20585  supports directly:
20586 \end_layout
20587
20588 \begin_deeper
20589 \begin_layout Itemize
20590 tree revision information (
20591 \begin_inset Flex Code
20592 status collapsed
20593
20594 \begin_layout Plain Layout
20595 vcs-tree-revision
20596 \end_layout
20597
20598 \end_inset
20599
20600 ).
20601  The result is the output of the 
20602 \begin_inset Flex Code
20603 status collapsed
20604
20605 \begin_layout Plain Layout
20606 svnversion
20607 \end_layout
20608
20609 \end_inset
20610
20611  command, the following table gives you an idea, how to read the results.
20612 \end_layout
20613
20614 \begin_layout Standard
20615 \align center
20616 \begin_inset Tabular
20617 <lyxtabular version="3" rows="6" columns="2">
20618 <features tabularvalignment="middle">
20619 <column alignment="center" valignment="top">
20620 <column alignment="center" valignment="top">
20621 <row>
20622 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20623 \begin_inset Text
20624
20625 \begin_layout Plain Layout
20626 Output
20627 \end_layout
20628
20629 \end_inset
20630 </cell>
20631 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20632 \begin_inset Text
20633
20634 \begin_layout Plain Layout
20635 Meaning
20636 \end_layout
20637
20638 \end_inset
20639 </cell>
20640 </row>
20641 <row>
20642 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20643 \begin_inset Text
20644
20645 \begin_layout Plain Layout
20646 4123:4168
20647 \end_layout
20648
20649 \end_inset
20650 </cell>
20651 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20652 \begin_inset Text
20653
20654 \begin_layout Plain Layout
20655 mixed revision working copy
20656 \end_layout
20657
20658 \end_inset
20659 </cell>
20660 </row>
20661 <row>
20662 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20663 \begin_inset Text
20664
20665 \begin_layout Plain Layout
20666 4168M
20667 \end_layout
20668
20669 \end_inset
20670 </cell>
20671 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20672 \begin_inset Text
20673
20674 \begin_layout Plain Layout
20675 modified working copy
20676 \end_layout
20677
20678 \end_inset
20679 </cell>
20680 </row>
20681 <row>
20682 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20683 \begin_inset Text
20684
20685 \begin_layout Plain Layout
20686 4123S
20687 \end_layout
20688
20689 \end_inset
20690 </cell>
20691 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20692 \begin_inset Text
20693
20694 \begin_layout Plain Layout
20695 switched working copy
20696 \end_layout
20697
20698 \end_inset
20699 </cell>
20700 </row>
20701 <row>
20702 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
20703 \begin_inset Text
20704
20705 \begin_layout Plain Layout
20706 4123P
20707 \end_layout
20708
20709 \end_inset
20710 </cell>
20711 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
20712 \begin_inset Text
20713
20714 \begin_layout Plain Layout
20715 partial working copy, from a sparse checkout
20716 \end_layout
20717
20718 \end_inset
20719 </cell>
20720 </row>
20721 <row>
20722 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
20723 \begin_inset Text
20724
20725 \begin_layout Plain Layout
20726 4123:4168MS
20727 \end_layout
20728
20729 \end_inset
20730 </cell>
20731 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
20732 \begin_inset Text
20733
20734 \begin_layout Plain Layout
20735 mixed revision, modified, switched working copy
20736 \end_layout
20737
20738 \end_inset
20739 </cell>
20740 </row>
20741 </lyxtabular>
20742
20743 \end_inset
20744
20745
20746 \end_layout
20747
20748 \begin_layout Itemize
20749 file revision information.
20750  The result comes from parsing the output of 
20751 \begin_inset Flex Code
20752 status collapsed
20753
20754 \begin_layout Plain Layout
20755 svn
20756 \begin_inset space ~
20757 \end_inset
20758
20759 info
20760 \begin_inset space ~
20761 \end_inset
20762
20763 –xml
20764 \begin_inset space ~
20765 \end_inset
20766
20767 file.lyx
20768 \end_layout
20769
20770 \end_inset
20771
20772 .
20773  Supported flags are:
20774 \end_layout
20775
20776 \begin_deeper
20777 \begin_layout Itemize
20778 version number of the last commit (
20779 \begin_inset Flex Code
20780 status collapsed
20781
20782 \begin_layout Plain Layout
20783 vcs-revision
20784 \end_layout
20785
20786 \end_inset
20787
20788 )
20789 \end_layout
20790
20791 \begin_layout Itemize
20792 author of the last commit (
20793 \begin_inset Flex Code
20794 status collapsed
20795
20796 \begin_layout Plain Layout
20797 vcs-author
20798 \end_layout
20799
20800 \end_inset
20801
20802 )
20803 \end_layout
20804
20805 \begin_layout Itemize
20806 date of the last commit (
20807 \begin_inset Flex Code
20808 status collapsed
20809
20810 \begin_layout Plain Layout
20811 vcs-date
20812 \end_layout
20813
20814 \end_inset
20815
20816 )
20817 \end_layout
20818
20819 \begin_layout Itemize
20820 time of the last commit (
20821 \begin_inset Flex Code
20822 status collapsed
20823
20824 \begin_layout Plain Layout
20825 vcs-time
20826 \end_layout
20827
20828 \end_inset
20829
20830 )
20831 \end_layout
20832
20833 \end_deeper
20834 \begin_layout Standard
20835 You can obtain this info via InsetInfo (e.g.
20836  
20837 \begin_inset Flex Code
20838 status collapsed
20839
20840 \begin_layout Plain Layout
20841 info-insert buffer vcs-date
20842 \end_layout
20843
20844 \end_inset
20845
20846 ).
20847  The information will be available only when you have the file stored under
20848  svn managment (i.e.
20849  the 
20850 \begin_inset Flex Code
20851 status collapsed
20852
20853 \begin_layout Plain Layout
20854 .svn
20855 \end_layout
20856
20857 \end_inset
20858
20859  directory is available with your document).
20860 \end_layout
20861
20862 \end_deeper
20863 \begin_layout Itemize
20864 Another—a hacking one—possibility is to use svn keywords
20865 \begin_inset Foot
20866 status collapsed
20867
20868 \begin_layout Plain Layout
20869 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
20870 \end_layout
20871
20872 \end_inset
20873
20874 .
20875  In short – you set file keywords property (e.g.
20876  
20877 \family sans
20878 svn propset svn:keywords 'Rev' file.lyx
20879 \family default
20880 ) and then paste keyword \SpecialChar TeX
20881  code
20882 \begin_inset Foot
20883 status collapsed
20884
20885 \begin_layout Plain Layout
20886 This is an easy way how to ensure that \SpecialChar LyX
20887  won't break the line in the middle
20888  of keyword tag.
20889 \end_layout
20890
20891 \end_inset
20892
20893  tag in your document (e.g.
20894  
20895 \begin_inset ERT
20896 status open
20897
20898 \begin_layout Plain Layout
20899
20900 $Rev$
20901 \end_layout
20902
20903 \end_inset
20904
20905 ).
20906  This way svn client will automatically substitute revision number (e.g.
20907  
20908 \begin_inset ERT
20909 status open
20910
20911 \begin_layout Plain Layout
20912
20913 $Rev: 59 $
20914 \end_layout
20915
20916 \end_inset
20917
20918 ) after each update and commit.
20919  There are more problems with this approach.
20920  Firstly, the '$' character is used in \SpecialChar TeX
20921  world for math equations, so any
20922  occurence of math formula 
20923 \begin_inset Formula $Rev$
20924 \end_inset
20925
20926  become 
20927 \begin_inset Formula $Rev:59$
20928 \end_inset
20929
20930  in your \SpecialChar LyX
20931  document.
20932  Similarly for other keywords like Id, Date, Author, etc.
20933  Secondly svn output is dependent on your locales, so its very easy that
20934  svn would produce some problematic strings once Date is used.
20935  Thirdly you get the whole 'Rev: 59' string in your document instead of
20936  the plain number.
20937  Until subversion implements user's custom keywords it will be hard to use
20938  this approach reliably or let \SpecialChar LyX
20939  to support it directly.
20940 \end_layout
20941
20942 \begin_layout Subsection
20943 SVN and Windows Environment
20944 \end_layout
20945
20946 \begin_layout Quote
20947 My inclination is to say that if the user cannot figure out the command
20948  line operations on their own fairly quickly, they would be well advised
20949  to use TortoiseSVN.
20950  —P.
20951  A.
20952  Rubin
20953 \end_layout
20954
20955 \begin_layout Subsubsection
20956 Preparation
20957 \end_layout
20958
20959 \begin_layout Standard
20960 In addition to installing \SpecialChar LyX
20961 , and having access to a Subversion repository,
20962  the user will need to install the Subversion client program.
20963  A Windows installer for the client program is available from 
20964 \begin_inset CommandInset href
20965 LatexCommand href
20966 name "CollabNet"
20967 target "http://www.collab.net/nonav/downloads/subversion/"
20968
20969 \end_inset
20970
20971 .
20972  The user may also want to install 
20973 \begin_inset CommandInset href
20974 LatexCommand href
20975 name "TortoiseSVN"
20976 target "http://tortoisesvn.tigris.org/"
20977
20978 \end_inset
20979
20980 , which integrates Subversion operations into the context (rightclick) menu
20981  of Windows Explorer.
20982  Operations done outside \SpecialChar LyX
20983  will typically be more convenient using the Explorer
20984  context menu.
20985  Note that TortoiseSVN is not a replacement for the client program, which
20986  is what \SpecialChar LyX
20987  itself will use.
20988 \end_layout
20989
20990 \begin_layout Subsubsection
20991 Bringing a document under Subversion control
20992 \end_layout
20993
20994 \begin_layout Standard
20995 Before a \SpecialChar LyX
20996  document can be brought under version control in Subversion, its
20997  parent directory needs to be under version control.
20998  If the document is being added to a project already in the repository,
20999  this is accomplished by checking the project out to the directory where
21000  the new document will be placed.
21001  If the project itself is not yet under version control (for instance, if
21002  this document starts a new project), the directory must be imported into
21003  the repository.
21004  This is done outside \SpecialChar LyX
21005 .
21006  Both import and checkout are easily accomplished from the Explorer context
21007  menu using TortoiseSVN, or alternatively can be done using the command
21008  line client at a DOS prompt.
21009  The procedure for importing the project using TortoiseSVN is described
21010  below, assuming an existing repository and a new project being started
21011  in 
21012 \family typewriter
21013 C:
21014 \backslash
21015 new project
21016 \family default
21017 .
21018  For information on using the Subversion client program, run 
21019 \family typewriter
21020 svn --help 
21021 \family default
21022 in a DOS shell.
21023 \end_layout
21024
21025 \begin_layout Enumerate
21026 Locate 
21027 \family typewriter
21028 C:
21029 \backslash
21030 new project 
21031 \family default
21032 in Windows Explorer, right click it, and select 
21033 \family sans
21034 TortoiseSVN\SpecialChar menuseparator
21035 Repo-browser
21036 \family default
21037 .
21038  If necessary, adjust the URL for the repository, then click OK.
21039 \end_layout
21040
21041 \begin_layout Enumerate
21042 Right click the level of the repository under which you want to place the
21043  new project folder (typically the top level) and click 
21044 \family sans
21045 Create folder
21046 \family default
21047  Supply a name for the project folder and click OK.
21048  Add a message for the log file if desired, then click OK again.
21049  The new project folder should appear in the repository.
21050  Finally, click OK again to exit the repository browser.
21051 \end_layout
21052
21053 \begin_layout Enumerate
21054 Once again right click 
21055 \family typewriter
21056 C:
21057 \backslash
21058 new project
21059 \family default
21060 , this time selecting SVN Checkout\SpecialChar ldots
21061  Select the URL of the project folder
21062  you just created in the repository, and set the checkout directory to 
21063 \family typewriter
21064 C:
21065 \backslash
21066 new project.
21067
21068 \family default
21069  Click OK.
21070  You will be warned about a non-empty folder; click OK to proceed.
21071  You should now have a 
21072 \family typewriter
21073 .svn
21074 \family default
21075  directory under 
21076 \family typewriter
21077 C:
21078 \backslash
21079 new project.
21080 \end_layout
21081
21082 \begin_layout Enumerate
21083 Create or open your document in \SpecialChar LyX
21084  and click 
21085 \family sans
21086 File\SpecialChar menuseparator
21087 Version
21088 \begin_inset space ~
21089 \end_inset
21090
21091 Control\SpecialChar menuseparator
21092 Register.
21093  
21094 \family default
21095 Add a log message and click OK to commit the document to version control.
21096 \end_layout
21097
21098 \begin_layout Standard
21099 From this point onward, you should have full functionality in the 
21100 \family sans
21101 File\SpecialChar menuseparator
21102 Version
21103 \begin_inset space ~
21104 \end_inset
21105
21106 Control
21107 \family default
21108  menu.
21109  You also have the option of checking the document in and out, viewing its
21110  history, etc.
21111  using the TortoiseSVN context menu in Windows Explorer or the Subversion
21112  client program from a command prompt.
21113 \end_layout
21114
21115 \begin_layout Subsubsection
21116 SSH tunnel used with SVN under Windows
21117 \end_layout
21118
21119 \begin_layout Standard
21120 Compared with Linux setting up an svn client to communicate over ssh under
21121  Windows is a rather troublesome task.
21122  We will at least offer some hints how to setup the client side but prior
21123  knowledge about ssh and the Windows command line is needed, also be prepared
21124  for a great deal of frustration\SpecialChar ldots
21125
21126 \end_layout
21127
21128 \begin_layout Enumerate
21129 Get an svn client for windows, as described in the previous sections.
21130  When it is a fresh install run some svn command (e.g.
21131  
21132 \begin_inset Flex Code
21133 status collapsed
21134
21135 \begin_layout Plain Layout
21136 svn –version
21137 \end_layout
21138
21139 \end_inset
21140
21141 ) to create config files, which you will need to change later on.
21142 \end_layout
21143
21144 \begin_layout Enumerate
21145 Choose an ssh client for Windows.
21146  There are several possibilities, we will use the one from Putty tools
21147 \begin_inset Foot
21148 status collapsed
21149
21150 \begin_layout Plain Layout
21151 \begin_inset Flex URL
21152 status collapsed
21153
21154 \begin_layout Plain Layout
21155
21156 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
21157 \end_layout
21158
21159 \end_inset
21160
21161
21162 \end_layout
21163
21164 \end_inset
21165
21166 .
21167  You will need to set the connection up so that the client doesn't ask for
21168  any password from you.
21169  To keep things easy we will use only keys without any additional password
21170  protection etc.
21171 \end_layout
21172
21173 \begin_deeper
21174 \begin_layout Enumerate
21175 Generate keys by 
21176 \begin_inset Flex Code
21177 status collapsed
21178
21179 \begin_layout Plain Layout
21180 puttygen
21181 \end_layout
21182
21183 \end_inset
21184
21185 .
21186  Save your private .ppk key file and put the public one on the server side.
21187  If the SVN server runs on Linux, note that the format of the public key
21188  is not compatible with Linux openssh and you will need to direcly copy-paste
21189  the key from the “
21190 \emph on
21191 Public key for pasting into OpenSSH authorized_keys file
21192 \emph default
21193 :” edit field into the server's 
21194 \begin_inset Flex Code
21195 status collapsed
21196
21197 \begin_layout Plain Layout
21198 ~/.ssh/authorized_keys
21199 \end_layout
21200
21201 \end_inset
21202
21203  / 
21204 \begin_inset Flex Code
21205 status collapsed
21206
21207 \begin_layout Plain Layout
21208 authorized_keys2
21209 \end_layout
21210
21211 \end_inset
21212
21213  file.
21214 \end_layout
21215
21216 \begin_layout Enumerate
21217 Get the Putty's 
21218 \begin_inset Flex Code
21219 status collapsed
21220
21221 \begin_layout Plain Layout
21222 plink
21223 \end_layout
21224
21225 \end_inset
21226
21227 .
21228  In the SVN config file
21229 \begin_inset Foot
21230 status collapsed
21231
21232 \begin_layout Plain Layout
21233 Exact path depends on Windows version, usually somewhere around 
21234 \begin_inset Flex Code
21235 status collapsed
21236
21237 \begin_layout Plain Layout
21238 c:
21239 \backslash
21240 Documents and Settings
21241 \backslash
21242 user
21243 \backslash
21244 Application Data
21245 \backslash
21246 Subversion
21247 \backslash
21248 config
21249 \end_layout
21250
21251 \end_inset
21252
21253  / 
21254 \begin_inset Flex Code
21255 status collapsed
21256
21257 \begin_layout Plain Layout
21258 AppData
21259 \backslash
21260 Roaming
21261 \backslash
21262 Subversion
21263 \end_layout
21264
21265 \end_inset
21266
21267 .
21268 \end_layout
21269
21270 \end_inset
21271
21272 , section [tunnels], setup ssh command, e.g.
21273  
21274 \begin_inset Flex Code
21275 status collapsed
21276
21277 \begin_layout Plain Layout
21278 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
21279 \end_layout
21280
21281 \end_inset
21282
21283 .
21284 \begin_inset Foot
21285 status collapsed
21286
21287 \begin_layout Plain Layout
21288 It will usually take a lot of time to get exact command right and it depends
21289  on many things.
21290  For example do not have some remote server saved as a default session in
21291  Putty etc.
21292  If things fail, try to connect via plink without SVN first.
21293 \end_layout
21294
21295 \end_inset
21296
21297
21298 \end_layout
21299
21300 \end_deeper
21301 \begin_layout Enumerate
21302 Checkout the SVN archive, e.
21303 \begin_inset space \thinspace{}
21304 \end_inset
21305
21306 g.
21307 \begin_inset Newline newline
21308 \end_inset
21309
21310
21311 \begin_inset Flex Code
21312 status collapsed
21313
21314 \begin_layout Plain Layout
21315 svn co svn+ssh://user@server/repository_path
21316 \end_layout
21317
21318 \end_inset
21319
21320 .
21321 \end_layout
21322
21323 \begin_layout Subsubsection
21324 End-of-Line Conversions
21325 \end_layout
21326
21327 \begin_layout Standard
21328 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
21329  will
21330  use different line endings inside the .lyx files.
21331  This is not a problem as far as \SpecialChar LyX
21332  functionality is concerned, but the commit
21333  diffs will be huge and merge-conflicts prone.
21334  Fortunately SVN itself knows
21335 \begin_inset Foot
21336 status collapsed
21337
21338 \begin_layout Plain Layout
21339 \begin_inset Flex URL
21340 status collapsed
21341
21342 \begin_layout Plain Layout
21343
21344 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
21345 \end_layout
21346
21347 \end_inset
21348
21349
21350 \end_layout
21351
21352 \end_inset
21353
21354  how to deal with CR/LF problems when switching .lyx files to the 
21355 \begin_inset Flex Code
21356 status collapsed
21357
21358 \begin_layout Plain Layout
21359 native
21360 \end_layout
21361
21362 \end_inset
21363
21364  mode.
21365 \begin_inset Foot
21366 status collapsed
21367
21368 \begin_layout Plain Layout
21369 For the lazy guys: 
21370 \begin_inset Flex Code
21371 status collapsed
21372
21373 \begin_layout Plain Layout
21374 svn propset svn:eol-style native FILE_NAME
21375 \end_layout
21376
21377 \end_inset
21378
21379
21380 \end_layout
21381
21382 \end_inset
21383
21384
21385 \end_layout
21386
21387 \begin_layout Subsection
21388 GIT commands in \SpecialChar LyX
21389
21390 \end_layout
21391
21392 \begin_layout Standard
21393 A minimal subset of GIT commands is now supported by \SpecialChar LyX
21394 .
21395  You can find the commands in the 
21396 \family sans
21397 File\SpecialChar menuseparator
21398 Version
21399 \begin_inset space ~
21400 \end_inset
21401
21402 Control
21403 \family default
21404  submenu.
21405  Please note that if you use password protected access to repository via
21406  ssh, you will be asked in terminal window.
21407  \SpecialChar LyX
21408  was tested against GIT 1.7.
21409 \begin_inset Foot
21410 status open
21411
21412 \begin_layout Plain Layout
21413 Windows users please note that you need to ensure that git is on the path.
21414  This can be set from within \SpecialChar LyX
21415  at 
21416 \family sans
21417 Tools\SpecialChar menuseparator
21418 Preferences\SpecialChar menuseparator
21419 Paths\SpecialChar menuseparator
21420 PATH prefix
21421 \family default
21422 .
21423 \end_layout
21424
21425 \end_inset
21426
21427
21428 \end_layout
21429
21430 \begin_layout Standard
21431 One big difference of GIT and the other supported version control systems
21432  is the distributed nature of GIT: With traditional version control systems
21433  there is one central server which hosts the repository.
21434  Users commit their changes to the server, and get updates made by other
21435  users from it.
21436  With GIT, users commit to a local repository.
21437  The local repository can be synchronized with one or more remote repositories
21438  using the 
21439 \begin_inset Flex Code
21440 status collapsed
21441
21442 \begin_layout Plain Layout
21443 pull
21444 \end_layout
21445
21446 \end_inset
21447
21448  and 
21449 \begin_inset Flex Code
21450 status collapsed
21451
21452 \begin_layout Plain Layout
21453 push
21454 \end_layout
21455
21456 \end_inset
21457
21458  GIT commands.
21459  \SpecialChar LyX
21460  does not interact in any way with remote GIT repositories.
21461  It works exclusively with the local repository in a very similar way as
21462  with a central CVS or SVN repository.
21463  If you use remote GIT repositories you need to do the 
21464 \begin_inset Flex Code
21465 status collapsed
21466
21467 \begin_layout Plain Layout
21468 pull
21469 \end_layout
21470
21471 \end_inset
21472
21473  and 
21474 \begin_inset Flex Code
21475 status collapsed
21476
21477 \begin_layout Plain Layout
21478 push
21479 \end_layout
21480
21481 \end_inset
21482
21483  operations with your favourite GIT client.
21484 \end_layout
21485
21486 \begin_layout Subsubsection
21487
21488 \family sans
21489 Register
21490 \end_layout
21491
21492 \begin_layout Standard
21493 If your document is not under revision control, this is the only item shown
21494  in the menu.
21495  And if it is under revision control, the 
21496 \family sans
21497 Register
21498 \family default
21499  item is not visible.
21500 \end_layout
21501
21502 \begin_layout Standard
21503 This command registers in GIT your document ONLY in case you have already
21504  the documents directory under GIT control (in particular 
21505 \family typewriter
21506 .git/index
21507 \family default
21508  file exists).
21509  This means you have to checkout the archive by yourself.
21510 \end_layout
21511
21512 \begin_layout Standard
21513 Then you are asked interactively to supply an initial description of the
21514  document.
21515  Don't forget that registered file is not yet commited.
21516 \end_layout
21517
21518 \begin_layout Standard
21519 GIT command that is run: 
21520 \family typewriter
21521 git add 
21522 \begin_inset Quotes eld
21523 \end_inset
21524
21525 <file-name>
21526 \begin_inset Quotes erd
21527 \end_inset
21528
21529
21530 \end_layout
21531
21532 \begin_layout Standard
21533 Read 
21534 \family typewriter
21535 man git
21536 \family default
21537  to understand the switches.
21538 \end_layout
21539
21540 \begin_layout Subsubsection
21541
21542 \family sans
21543 Check In Changes
21544 \end_layout
21545
21546 \begin_layout Standard
21547 When you are finished editing a file, you commit your changes.
21548  When you do this, you are asked for a description of the changes.
21549  After that changes are commited.
21550 \end_layout
21551
21552 \begin_layout Standard
21553 GIT command: 
21554 \family typewriter
21555 git commit -q -m"<description>" <file-name>
21556 \end_layout
21557
21558 \begin_layout Subsubsection
21559
21560 \family sans
21561 Revert To Repository Version
21562 \end_layout
21563
21564 \begin_layout Standard
21565 This will discard all changes made to the document since the last check
21566  in.
21567  You get a warning before changes are discarded.
21568 \end_layout
21569
21570 \begin_layout Standard
21571 GIT command: 
21572 \family typewriter
21573 git checkout -q 
21574 \begin_inset Quotes eld
21575 \end_inset
21576
21577 <file-name>
21578 \begin_inset Quotes erd
21579 \end_inset
21580
21581
21582 \end_layout
21583
21584 \begin_layout Subsubsection
21585
21586 \family sans
21587 Rename
21588 \end_layout
21589
21590 \begin_layout Standard
21591 This will rename the current document including the version history.
21592  It requires a clean document without any changes since the last checkin.
21593  You are asked for a file name and a description of the rename operation.
21594  After that the document is renamed, both locally and in the repository.
21595  If the parent directories of the new and old file names differ, all relative
21596  paths of included files are adjusted (like in 
21597 \family sans
21598 File\SpecialChar menuseparator
21599 Save As
21600 \family default
21601 \SpecialChar ldots
21602 ).
21603  Finally, the document is reloaded using the new name.
21604 \end_layout
21605
21606 \begin_layout Labeling
21607 \labelwidthstring 00.00.0000
21608 GIT
21609 \begin_inset space ~
21610 \end_inset
21611
21612 commands: 
21613 \begin_inset space ~
21614 \end_inset
21615
21616
21617 \begin_inset Newline newline
21618 \end_inset
21619
21620
21621 \begin_inset Flex Code
21622 status collapsed
21623
21624 \begin_layout Plain Layout
21625 git mv 
21626 \family typewriter
21627
21628 \begin_inset Quotes eld
21629 \end_inset
21630
21631 <file-name>
21632 \begin_inset Quotes erd
21633 \end_inset
21634
21635  
21636 \begin_inset Quotes eld
21637 \end_inset
21638
21639 <new-file-name>
21640 \begin_inset Quotes erd
21641 \end_inset
21642
21643
21644 \end_layout
21645
21646 \end_inset
21647
21648
21649 \begin_inset Newline newline
21650 \end_inset
21651
21652
21653 \begin_inset Flex Code
21654 status collapsed
21655
21656 \begin_layout Plain Layout
21657 git commit
21658 \end_layout
21659
21660 \end_inset
21661
21662
21663 \end_layout
21664
21665 \begin_layout Subsubsection
21666
21667 \family sans
21668 Show History
21669 \end_layout
21670
21671 \begin_layout Standard
21672 This shows the complete history of the GIT document.
21673  The output of 
21674 \family typewriter
21675 git log 
21676 \begin_inset Quotes eld
21677 \end_inset
21678
21679 <file-name>
21680 \begin_inset Quotes erd
21681 \end_inset
21682
21683
21684 \family default
21685  is shown in a browser.
21686 \end_layout
21687
21688 \begin_layout Subsubsection
21689 Version Info
21690 \end_layout
21691
21692 \begin_layout Standard
21693 \SpecialChar LyX
21694  supports GIT hash number of the last commit to the file, author name, date
21695  and time of last commit.
21696  All those are extracted from 
21697 \family typewriter
21698 git log -n 1 --pretty=format:%H%n%an%n%ai
21699 \family default
21700 .
21701  Tree version information is obtained via 
21702 \family typewriter
21703 git describe --abbrev --dirty --long
21704 \family default
21705 .
21706  See 
21707 \begin_inset CommandInset ref
21708 LatexCommand ref
21709 reference "subsec:VCS-Revision-Information"
21710
21711 \end_inset
21712
21713  for other details.
21714 \end_layout
21715
21716 \begin_layout Subsection
21717 Further tuning
21718 \end_layout
21719
21720 \begin_layout Standard
21721 With the recent addition of the vc-command function \SpecialChar LyX
21722  power users are allowed
21723  to create their own commands for revision control.
21724 \end_layout
21725
21726 \begin_layout Standard
21727 As an example you can see how two TortoiseSVN commands could be integrated
21728  directly:
21729 \end_layout
21730
21731 \begin_layout Description
21732 Commit: 
21733 \begin_inset Flex Code
21734 status collapsed
21735
21736 \begin_layout Plain Layout
21737 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
21738 \end_layout
21739
21740 \end_inset
21741
21742
21743 \end_layout
21744
21745 \begin_layout Description
21746 Revert: 
21747 \begin_inset Flex Code
21748 status collapsed
21749
21750 \begin_layout Plain Layout
21751 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
21752 \end_layout
21753
21754 \end_inset
21755
21756
21757 \end_layout
21758
21759 \begin_layout Subsection
21760 Version control and Document comparison
21761 \end_layout
21762
21763 \begin_layout Standard
21764 One of the typical uses of version control is to inspect the changes between
21765  revisions, usually by creating 
21766 \begin_inset Flex Code
21767 status collapsed
21768
21769 \begin_layout Plain Layout
21770 diff
21771 \end_layout
21772
21773 \end_inset
21774
21775  dumps.
21776  While this is useful for plain text files, it is much less useful in the
21777  case of \SpecialChar LyX
21778  files, which have more a complicated structure.
21779  Hence we provide binding to the Document comparison feature.
21780  There are two ways of calling this feature - either by direct call of 
21781 \begin_inset Flex Code
21782 status collapsed
21783
21784 \begin_layout Plain Layout
21785 VC_COMPARE
21786 \end_layout
21787
21788 \end_inset
21789
21790  \SpecialChar LyX
21791  function (for details see \SpecialChar LyX
21792  functions manual) or by icon/menu item 
21793 \begin_inset Flex Noun
21794 status collapsed
21795
21796 \begin_layout Plain Layout
21797 Compare with older revision...
21798 \end_layout
21799
21800 \end_inset
21801
21802 .
21803  One can either compare two chosen revisions of the document or he can simply
21804  compare the current version of edited text with older revisions (where
21805  '
21806 \begin_inset Flex Noun
21807 status collapsed
21808
21809 \begin_layout Plain Layout
21810 0
21811 \end_layout
21812
21813 \end_inset
21814
21815 ' revisions back means comparison of the edited file with last commited
21816  revision).
21817  
21818 \end_layout
21819
21820 \begin_layout Standard
21821 This feature is supported for SVN and RCS though due to the more complicated
21822  versioning scheme of RCS there is a constraint – when addressing the revisions
21823  in dialog, numbers always point to the last number in RCS revision number,
21824  i.e.
21825  '35' in '1.2.35'.
21826  We don't currently support GIT addressing of revisions, one can just compare
21827  edited document with its revision X steps backs, where X is addressed as
21828  HEAD~X.
21829 \end_layout
21830
21831 \begin_layout Section
21832 Literate Programming
21833 \end_layout
21834
21835 \begin_layout Standard
21836 Updated by 
21837 \noun on
21838 Kayvan Sylvan 
21839 \noun default
21840 (kayvan@sylvan.com)
21841 \noun on
21842
21843 \noun default
21844 original documentation written by 
21845 \noun on
21846 Edmar Wienskoski Jr.
21847
21848 \noun default
21849  (edmar-w-jr@technologist.com)
21850 \end_layout
21851
21852 \begin_layout Subsection
21853 Introduction
21854 \end_layout
21855
21856 \begin_layout Standard
21857 The main purpose of this documentation is to show you how to use \SpecialChar LyX
21858  for literate
21859  programming, where it is assumed that you are familiar with this programming
21860  technique, and know what 
21861 \begin_inset Quotes eld
21862 \end_inset
21863
21864 tangling
21865 \begin_inset Quotes erd
21866 \end_inset
21867
21868  and 
21869 \begin_inset Quotes eld
21870 \end_inset
21871
21872 weaving
21873 \begin_inset Quotes erd
21874 \end_inset
21875
21876  means.
21877  If that is not the case, please follow the web links provided in the following
21878  sections.
21879  There is a lot of good documentation out there covering old development
21880  history to the latest tools tips.
21881 \end_layout
21882
21883 \begin_layout Standard
21884 It is also assumed that you are familiar with \SpecialChar LyX
21885  itself to a point that you
21886  are comfortable changing your \SpecialChar LyX
21887  preferences, and X resources file.
21888  If that is not the case please refer to other \SpecialChar LyX
21889  documentation to cover your
21890  specific needs.
21891 \end_layout
21892
21893 \begin_layout Subsection
21894 Literate Programming
21895 \end_layout
21896
21897 \begin_layout Standard
21898 From the Literate Programming FAQ: 
21899 \end_layout
21900
21901 \begin_layout Quotation
21902 Literate programming is the combination of documentation and source together
21903  in a fashion suited for reading by human beings.
21904  In fact, literate programs should be enjoyable reading, even inviting!
21905  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
21906  and documentation in a single file.
21907  Literate programming tools then parse the file to produce either readable
21908  documentation or compilable source.
21909  The WEB style of literate programming was created by D.
21910 \begin_inset space \thinspace{}
21911 \end_inset
21912
21913 E.
21914  Knuth during the development of his \SpecialChar TeX
21915  typesetting software.
21916  
21917 \end_layout
21918
21919 \begin_layout Standard
21920 Another excerpt says:
21921 \end_layout
21922
21923 \begin_layout Quotation
21924
21925 \emph on
21926 How is literate programming different from verbose commenting?
21927 \end_layout
21928
21929 \begin_layout Quotation
21930 There are three distinguishing characteristics.
21931  In order of importance, they are: 
21932 \end_layout
21933
21934 \begin_deeper
21935 \begin_layout Itemize
21936 flexible order of elaboration 
21937 \end_layout
21938
21939 \begin_layout Itemize
21940 automatic support for browsing 
21941 \end_layout
21942
21943 \begin_layout Itemize
21944 typeset documentation, especially diagrams and mathematics 
21945 \end_layout
21946
21947 \end_deeper
21948 \begin_layout Standard
21949 Now that I sparked your curiosity, take a look in the references.
21950 \end_layout
21951
21952 \begin_layout Subsubsection
21953 References
21954 \end_layout
21955
21956 \begin_layout Standard
21957 The complete Literate Programming FAQ can be found at:
21958 \end_layout
21959
21960 \begin_layout Quote
21961 Literate Programming FAQ 
21962 \begin_inset Flex URL
21963 status collapsed
21964
21965 \begin_layout Plain Layout
21966
21967 http://www.literateprogramming.com/lpfaq.pdf
21968 \end_layout
21969
21970 \end_inset
21971
21972
21973 \end_layout
21974
21975 \begin_layout Standard
21976 The FAQ lists 23 (twenty three!) different literate programming tools.
21977  Where some are specialized or 
21978 \begin_inset Quotes eld
21979 \end_inset
21980
21981 tailored
21982 \begin_inset Quotes erd
21983 \end_inset
21984
21985  for particular programming languages, while other have general scope.
21986  I selected 
21987 \noun on
21988 Noweb
21989 \noun default
21990  for my own use for several reasons:
21991 \end_layout
21992
21993 \begin_layout Itemize
21994 It can generate the documentation either in \SpecialChar LaTeX
21995  or HTML.
21996 \end_layout
21997
21998 \begin_layout Itemize
21999 It has a open architecture, i.
22000 \begin_inset space \thinspace{}
22001 \end_inset
22002
22003 e.
22004 \begin_inset space \space{}
22005 \end_inset
22006
22007 it is easy to plug in new filters and to perform special processing that
22008  you may need.
22009  
22010 \end_layout
22011
22012 \begin_layout Itemize
22013 There is a good selection of filters available already (the HTML is one
22014  of them).
22015 \end_layout
22016
22017 \begin_layout Itemize
22018 It is free.
22019 \end_layout
22020
22021 \begin_layout Standard
22022 The Noweb web page can be found at: 
22023 \end_layout
22024
22025 \begin_layout Quote
22026 Noweb home page 
22027 \begin_inset Flex URL
22028 status collapsed
22029
22030 \begin_layout Plain Layout
22031
22032 http://www.cs.virginia.edu/~nr/noweb/
22033 \end_layout
22034
22035 \end_inset
22036
22037
22038 \end_layout
22039
22040 \begin_layout Standard
22041 Starting from there you can reach many other interesting links and even
22042  some literate program examples.
22043 \end_layout
22044
22045 \begin_layout Subsection
22046 \SpecialChar LyX
22047  and Literate Programming with Noweb
22048 \end_layout
22049
22050 \begin_layout Standard
22051 The \SpecialChar LyX
22052  support for Literate Programming is provided by using the generic \SpecialChar LyX
22053
22054  converters mechanism.
22055  This support is provided in a 
22056 \begin_inset Quotes eld
22057 \end_inset
22058
22059 Noweb independent
22060 \begin_inset Quotes erd
22061 \end_inset
22062
22063  way, i.
22064 \begin_inset space \thinspace{}
22065 \end_inset
22066
22067 e.
22068 \begin_inset space \space{}
22069 \end_inset
22070
22071 you will be able to use this new \SpecialChar LyX
22072  feature with some other literate programming
22073  tool of your choice by just changing your \SpecialChar LyX
22074  preferences.
22075 \end_layout
22076
22077 \begin_layout Subsubsection
22078 Generating documents and code (weaving and tangling)
22079 \end_layout
22080
22081 \begin_layout Paragraph
22082 Using the noweb module
22083 \end_layout
22084
22085 \begin_layout Standard
22086 If you have installed Noweb and \SpecialChar LyX
22087  successfully, whenever you open a new document,
22088  after you have chosen its document class, use the Document->Settings menu
22089  to add the 
22090 \begin_inset Quotes eld
22091 \end_inset
22092
22093 noweb
22094 \begin_inset Quotes erd
22095 \end_inset
22096
22097  module.
22098  If Noweb is correctly installed, when you click on the 
22099 \begin_inset Quotes eld
22100 \end_inset
22101
22102 Modules
22103 \begin_inset Quotes erd
22104 \end_inset
22105
22106  link, you will see the 
22107 \begin_inset Quotes eld
22108 \end_inset
22109
22110 noweb
22111 \begin_inset Quotes erd
22112 \end_inset
22113
22114  module in the available list and you can add it to your document.
22115 \end_layout
22116
22117 \begin_layout Paragraph
22118 Typing code in
22119 \end_layout
22120
22121 \begin_layout Standard
22122 \SpecialChar LyX
22123  enables you to write code with a layout named 
22124 \begin_inset Flex Noun
22125 status collapsed
22126
22127 \begin_layout Plain Layout
22128 Chunk
22129 \end_layout
22130
22131 \end_inset
22132
22133 .
22134  Noweb delimits chunks like this:
22135 \end_layout
22136
22137 \begin_layout LyX-Code
22138 <<My code>>=
22139 \end_layout
22140
22141 \begin_layout LyX-Code
22142   code
22143 \end_layout
22144
22145 \begin_layout LyX-Code
22146   more code
22147 \end_layout
22148
22149 \begin_layout LyX-Code
22150   even more code
22151 \end_layout
22152
22153 \begin_layout LyX-Code
22154   @
22155 \end_layout
22156
22157 \begin_layout Standard
22158 The problem is that whatever is written in between the << and the 
22159 \family typewriter
22160 @
22161 \family default
22162  must be taken literally, i.
22163 \begin_inset space \thinspace{}
22164 \end_inset
22165
22166 e.
22167 \begin_inset space \space{}
22168 \end_inset
22169
22170 \SpecialChar LyX
22171  should be prevented from making any special interpretation of what has
22172  been written.
22173  This is also handled by 
22174 \begin_inset Flex Noun
22175 status collapsed
22176
22177 \begin_layout Plain Layout
22178 Chunk
22179 \end_layout
22180
22181 \end_inset
22182
22183 , that works like a normal paragraph but has a free spacing capability.
22184 \end_layout
22185
22186 \begin_layout Standard
22187 As a special note, you can also use the 
22188 \begin_inset Quotes eld
22189 \end_inset
22190
22191 %def
22192 \begin_inset Quotes erd
22193 \end_inset
22194
22195  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
22196 rence:
22197 \end_layout
22198
22199 \begin_layout LyX-Code
22200 <<My chunk>>=
22201 \end_layout
22202
22203 \begin_layout LyX-Code
22204 def some_function(args):
22205 \end_layout
22206
22207 \begin_layout LyX-Code
22208    "This is the doc string for this function."
22209 \end_layout
22210
22211 \begin_layout LyX-Code
22212    print "My args: ", args
22213 \end_layout
22214
22215 \begin_layout LyX-Code
22216 @ %def some_function
22217 \end_layout
22218
22219 \begin_layout Standard
22220 For an example of this usage and the resulting cross-reference output, look
22221  at the Literate python program in 
22222 \emph on
22223 LIBDIR/examples/listerrors.lyx
22224 \emph default
22225  which should make this all clear.
22226 \end_layout
22227
22228 \begin_layout Paragraph
22229 Generating the documentation
22230 \end_layout
22231
22232 \begin_layout Standard
22233 At this point you already have a new document file with a proper document
22234  class, and with some code and text on it.
22235  How do I print it? The answer is simple, you select 
22236 \family sans
22237 View\SpecialChar menuseparator
22238 DVI,
22239 \family default
22240  etc.
22241  Just like you would do for a plain document.
22242  No special procedure is required.
22243 \end_layout
22244
22245 \begin_layout Standard
22246 To help orientate you, I will now explain what happens inside \SpecialChar LyX
22247 :
22248 \end_layout
22249
22250 \begin_layout Enumerate
22251 When the 
22252 \family sans
22253 Update\SpecialChar menuseparator
22254 DVI
22255 \family default
22256  menu option is chosen, a \SpecialChar LaTeX
22257  file is generated.
22258  
22259 \end_layout
22260
22261 \begin_deeper
22262 \begin_layout Standard
22263 If the document is of any literate class the generated file will be named
22264  with an extension name defined by the 
22265 \begin_inset Quotes eld
22266 \end_inset
22267
22268 literate
22269 \begin_inset Quotes erd
22270 \end_inset
22271
22272  format (defined in the Preferences panel), otherwise the file will have
22273  the usual 
22274 \family typewriter
22275 .tex
22276 \family default
22277  extension.
22278 \end_layout
22279
22280 \end_deeper
22281 \begin_layout Enumerate
22282 Note that the only difference so far is in the name of the file, no special
22283  processing is required by \SpecialChar LyX
22284 .
22285  Given that you formatted the code using the 
22286 \begin_inset Flex Noun
22287 status collapsed
22288
22289 \begin_layout Plain Layout
22290 Chunk
22291 \end_layout
22292
22293 \end_inset
22294
22295  layout that, by itself, takes care of the business.
22296 \end_layout
22297
22298 \begin_layout Enumerate
22299 If the document is of any literate class \SpecialChar LyX
22300  will then use the internal \SpecialChar LyX
22301  to
22302  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
22303  converter
22304 \begin_inset Foot
22305 status collapsed
22306
22307 \begin_layout Plain Layout
22308 The converters are defined in the 
22309 \family sans
22310 Tools\SpecialChar menuseparator
22311 Preferences
22312 \family default
22313  panel, under the 
22314 \begin_inset Quotes eld
22315 \end_inset
22316
22317 Conversion
22318 \begin_inset Quotes erd
22319 \end_inset
22320
22321  tab.
22322  See section 
22323 \emph on
22324 Converters
22325 \emph default
22326  of the 
22327 \emph on
22328 Customization
22329 \emph default
22330  manual for general information about converters.
22331 \end_layout
22332
22333 \end_inset
22334
22335  to generate the \SpecialChar LaTeX
22336  file.
22337 \end_layout
22338
22339 \begin_deeper
22340 \begin_layout Standard
22341 Otherwise it will just skip this step.
22342 \end_layout
22343
22344 \end_deeper
22345 \begin_layout Enumerate
22346 Finally, \SpecialChar LaTeX
22347  is invoked and the regular post processing continues as in a plain
22348  document.
22349 \end_layout
22350
22351 \begin_layout Standard
22352 Independence from a particular 
22353 \begin_inset Quotes eld
22354 \end_inset
22355
22356 literate tool
22357 \begin_inset Quotes erd
22358 \end_inset
22359
22360  is easily achieved by changing the commands that are run by the various
22361  converters.
22362 \end_layout
22363
22364 \begin_layout Paragraph
22365 Generating the code
22366 \end_layout
22367
22368 \begin_layout Standard
22369 When the build menu option is chosen or the corresponding button in the
22370  toolbar is pressed, a \SpecialChar LaTeX
22371  file is generated just like step 1 above.
22372  Next, \SpecialChar LyX
22373  invokes the 
22374 \family typewriter
22375 Noweb->Program
22376 \family default
22377  converter.
22378  This converter needs to be defined by the user and is not installed by
22379  default, though the Program format is.
22380  This converter (like any other converter) will have two parts:
22381 \end_layout
22382
22383 \begin_layout Enumerate
22384 The converter program itself.
22385  This program performs the conversion from the one format to the other (in
22386  this case, from the Noweb format to the Program pseudo-format).
22387 \end_layout
22388
22389 \begin_layout Enumerate
22390 The error log parser.
22391  This is a program whose sole purpose is to rewrite error messages in a
22392  format that \SpecialChar LyX
22393  understands.
22394  This makes it possible for \SpecialChar LyX
22395  to place error boxes in the right places in
22396  the file buffer.
22397 \end_layout
22398
22399 \begin_layout Standard
22400 The first part, the 
22401 \begin_inset Quotes eld
22402 \end_inset
22403
22404 Converter
22405 \begin_inset Quotes erd
22406 \end_inset
22407
22408  setting, should be set to
22409 \begin_inset Newline newline
22410 \end_inset
22411
22412
22413 \begin_inset Quotes eld
22414 \end_inset
22415
22416
22417 \family typewriter
22418 build-script $$i
22419 \family default
22420  $$r
22421 \begin_inset Quotes erd
22422 \end_inset
22423
22424 .
22425 \begin_inset Newline newline
22426 \end_inset
22427
22428 This basically means that \SpecialChar LyX
22429  will call 
22430 \begin_inset Quotes eld
22431 \end_inset
22432
22433 build-script
22434 \begin_inset Quotes erd
22435 \end_inset
22436
22437  (a program or script) with the name of the Noweb file (normally a file
22438  in the \SpecialChar LyX
22439  temp directory) and the directory path of the original \SpecialChar LyX
22440  file.
22441  
22442 \end_layout
22443
22444 \begin_layout Standard
22445 This is an implementation of 
22446 \begin_inset Quotes eld
22447 \end_inset
22448
22449 build-script
22450 \begin_inset Quotes erd
22451 \end_inset
22452
22453  that you can place in a directory on your path:
22454 \end_layout
22455
22456 \begin_layout Standard
22457 \begin_inset VSpace defskip
22458 \end_inset
22459
22460
22461 \end_layout
22462
22463 \begin_layout Standard
22464 \begin_inset Newpage pagebreak
22465 \end_inset
22466
22467
22468 \end_layout
22469
22470 \begin_layout Standard
22471
22472 \family sans
22473 #!/bin/sh
22474 \end_layout
22475
22476 \begin_layout Standard
22477
22478 \family sans
22479 #
22480 \end_layout
22481
22482 \begin_layout Standard
22483
22484 \family sans
22485 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
22486 \end_layout
22487
22488 \begin_layout Standard
22489 \begin_inset VSpace defskip
22490 \end_inset
22491
22492
22493 \end_layout
22494
22495 \begin_layout Standard
22496 The next part of the converter setting is the 
22497 \begin_inset Quotes eld
22498 \end_inset
22499
22500 Flags
22501 \begin_inset Quotes erd
22502 \end_inset
22503
22504  which is to be set to
22505 \begin_inset Newline newline
22506 \end_inset
22507
22508
22509 \begin_inset Quotes eld
22510 \end_inset
22511
22512
22513 \family typewriter
22514 parselog=$$s/scripts/listerrors
22515 \family default
22516
22517 \begin_inset Quotes erd
22518 \end_inset
22519
22520 .
22521 \begin_inset Newline newline
22522 \end_inset
22523
22524 This will run any errors that are generated by the 
22525 \begin_inset Quotes eld
22526 \end_inset
22527
22528 build-script
22529 \begin_inset Quotes erd
22530 \end_inset
22531
22532  process through the 
22533 \begin_inset Quotes eld
22534 \end_inset
22535
22536 listerrors
22537 \begin_inset Quotes erd
22538 \end_inset
22539
22540  program.
22541 \end_layout
22542
22543 \begin_layout Standard
22544 The build will normally take place in \SpecialChar LyX
22545 's temporary directory, so the files
22546  produced by the conversion will be in that directory.
22547  \SpecialChar LyX
22548  will copy out what it regards as the `main' file, but the 
22549 \family typewriter
22550 Noweb->Program
22551 \family default
22552  conversion may produce several files, and so most of these would then be
22553  deleted when \SpecialChar LyX
22554  was closed.
22555  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
22556  the build-script chunk can place the generated files in that location.
22557 \end_layout
22558
22559 \begin_layout Paragraph
22560 Build instructions in the document
22561 \end_layout
22562
22563 \begin_layout Standard
22564 The last piece of the integration between \SpecialChar LyX
22565  and noweb is the 
22566 \begin_inset Quotes eld
22567 \end_inset
22568
22569 build-script
22570 \begin_inset Quotes erd
22571 \end_inset
22572
22573  chunk.
22574  Generally, the instructions for building your program should be embedded
22575  in a chunk of its own.
22576  The noweb-specific 
22577 \begin_inset Quotes eld
22578 \end_inset
22579
22580 build-script
22581 \begin_inset Quotes erd
22582 \end_inset
22583
22584  above uses the notangle command to look for this chunk (called 
22585 \begin_inset Quotes eld
22586 \end_inset
22587
22588 build-script
22589 \begin_inset Quotes erd
22590 \end_inset
22591
22592 ) and runs its contents through 
22593 \begin_inset Quotes eld
22594 \end_inset
22595
22596 sh
22597 \begin_inset Quotes erd
22598 \end_inset
22599
22600 .
22601 \end_layout
22602
22603 \begin_layout Standard
22604 Typically, such a chunk would look something like this:
22605 \end_layout
22606
22607 \begin_layout LyX-Code
22608 <<build-script>>=
22609 \end_layout
22610
22611 \begin_layout LyX-Code
22612 #!/bin/sh
22613 \begin_inset Newline newline
22614 \end_inset
22615
22616 if [ -z "${NOWEB_SOURCE}" ]
22617 \begin_inset Newline newline
22618 \end_inset
22619
22620 then
22621 \end_layout
22622
22623 \begin_layout LyX-Code
22624 NOWEB_SOURCE=myfile.nw
22625 \begin_inset Newline newline
22626 \end_inset
22627
22628 fi
22629 \begin_inset Newline newline
22630 \end_inset
22631
22632 [...
22633  code to extract files ...
22634  use NOWEB_OUTPUT_DIR here ...]
22635 \begin_inset Newline newline
22636 \end_inset
22637
22638 [...
22639  code to compile files ...]
22640 \begin_inset Newline newline
22641 \end_inset
22642
22643 @
22644 \end_layout
22645
22646 \begin_layout Standard
22647 Look in 
22648 \emph on
22649 LIBDIR/examples/listerrors.lyx
22650 \emph default
22651  or in 
22652 \emph on
22653 LIBDIR/examples/Literate.lyx
22654 \emph default
22655  which implement two versions of the 
22656 \begin_inset Quotes eld
22657 \end_inset
22658
22659 listerrors
22660 \begin_inset Quotes erd
22661 \end_inset
22662
22663  program for some illustrations of how all of these pieces go together or
22664  in 
22665 \emph on
22666 LIBDIR/examples/noweb2lyx.lyx.
22667
22668 \emph default
22669  Interestingly, these three files show off the language-indepence of the
22670  \SpecialChar LyX
22671  literate programming support since they are written in Python, C and Perl
22672  respectively.
22673 \end_layout
22674
22675 \begin_layout Subsubsection
22676 Configuring \SpecialChar LyX
22677
22678 \end_layout
22679
22680 \begin_layout Standard
22681 All the Literate Programming support is configured by the 
22682 \family sans
22683 Tools\SpecialChar menuseparator
22684 Preferences
22685 \family default
22686  panel in the 
22687 \begin_inset Quotes eld
22688 \end_inset
22689
22690 File Handling
22691 \begin_inset Quotes erd
22692 \end_inset
22693
22694  tab.
22695  The important parts are:
22696 \end_layout
22697
22698 \begin_layout Description
22699 the
22700 \begin_inset space ~
22701 \end_inset
22702
22703
22704 \begin_inset Quotes eld
22705 \end_inset
22706
22707 NoWeb
22708 \begin_inset Quotes erd
22709 \end_inset
22710
22711
22712 \begin_inset space ~
22713 \end_inset
22714
22715 format Set up via the File Formats tab, this is where the Noweb-specific
22716  pieces are set up.
22717  The 
22718 \family sans
22719 GUI Name
22720 \family default
22721  is set to 
22722 \family typewriter
22723 NoWeb
22724 \family default
22725 , the file extension is set to 
22726 \family typewriter
22727 .nw
22728 \family default
22729 .
22730  This tells \SpecialChar LyX
22731  to create a file with a 
22732 \family typewriter
22733 .nw
22734 \family default
22735  extension in the first step of the conversion process.
22736 \end_layout
22737
22738 \begin_layout Description
22739 the
22740 \begin_inset space ~
22741 \end_inset
22742
22743
22744 \family sans
22745 Program
22746 \family default
22747
22748 \begin_inset space ~
22749 \end_inset
22750
22751 format This is an empty format whose sole purpose is to be the endpoint
22752  of a conversion (which then allows us to set up a converter for it).
22753 \end_layout
22754
22755 \begin_layout Description
22756
22757 \family sans
22758 NoWeb
22759 \family default
22760 ->
22761 \family sans
22762 \SpecialChar LaTeX
22763
22764 \family default
22765  This converter performs the 
22766 \begin_inset Quotes eld
22767 \end_inset
22768
22769 weaving
22770 \begin_inset Quotes erd
22771 \end_inset
22772
22773  of the literate document.
22774  For Noweb, it is set to 
22775 \begin_inset Quotes eld
22776 \end_inset
22777
22778
22779 \family typewriter
22780 noweave -delay -index $$i > $$o
22781 \family default
22782
22783 \begin_inset Quotes erd
22784 \end_inset
22785
22786
22787 \end_layout
22788
22789 \begin_layout Description
22790
22791 \family sans
22792 NoWeb
22793 \family default
22794 ->
22795 \family sans
22796 Program
22797 \family default
22798  This performs the 
22799 \begin_inset Quotes eld
22800 \end_inset
22801
22802 tangling step
22803 \begin_inset Quotes erd
22804 \end_inset
22805
22806 .
22807  As stated above, the Converter is set to 
22808 \begin_inset Quotes eld
22809 \end_inset
22810
22811
22812 \family typewriter
22813 build-script $$i
22814 \family default
22815  $$r
22816 \begin_inset Quotes erd
22817 \end_inset
22818
22819 , with Flags set to
22820 \begin_inset Newline newline
22821 \end_inset
22822
22823
22824 \begin_inset Quotes eld
22825 \end_inset
22826
22827
22828 \family typewriter
22829 parselog=$$s/scripts/listerrors
22830 \family default
22831
22832 \begin_inset Quotes erd
22833 \end_inset
22834
22835 .
22836 \end_layout
22837
22838 \begin_layout Subsubsection
22839 Debug extensions
22840 \end_layout
22841
22842 \begin_layout Standard
22843 There is also a new function implemented in the \SpecialChar LyX
22844  server, the 
22845 \begin_inset Quotes eld
22846 \end_inset
22847
22848 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
22849  
22850 \end_layout
22851
22852 \begin_layout Standard
22853 When debugging code with ddd/gdb, it is possible to invoke a text editor
22854  at the current execution position with a single key stroke.
22855  The default ddd configuration for that is shift-ctrl-V.
22856  It happens that you can define the editor command line invocation in ddd
22857  by accessing the 
22858 \family sans
22859 Edit\SpecialChar menuseparator
22860 Preferences\SpecialChar menuseparator
22861 Helpers
22862 \family default
22863  dialog and changing the "Edit Sources" entry.
22864 \end_layout
22865
22866 \begin_layout Standard
22867 I take advantage of the newly created \SpecialChar LyX
22868  server function and this ddd feature,
22869  and set 
22870 \begin_inset Quotes eld
22871 \end_inset
22872
22873 Edit Sources
22874 \begin_inset Quotes erd
22875 \end_inset
22876
22877  to:
22878 \end_layout
22879
22880 \begin_layout Standard
22881 \begin_inset VSpace defskip
22882 \end_inset
22883
22884
22885 \end_layout
22886
22887 \begin_layout Standard
22888
22889 \family sans
22890 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
22891 \end_layout
22892
22893 \begin_layout Standard
22894 \begin_inset VSpace defskip
22895 \end_inset
22896
22897
22898 \end_layout
22899
22900 \begin_layout Standard
22901 With this, whenever you are using ddd and find a point in the program that
22902  you want to edit, you just press shift-ctrl-V (in the ddd window), and
22903  ddd will forward this information to \SpecialChar LyX
22904  through the \SpecialChar LyX
22905  server and then the
22906  \SpecialChar LyX
22907  window will show the same file with the cursor at the same position ddd
22908  was pointing to.
22909  No more guessing or long scrolling to locate a point in the program back
22910  from debugging !
22911 \end_layout
22912
22913 \begin_layout Standard
22914 Note however that you must enable the \SpecialChar LyX
22915  server to get this feature working
22916  (it is disabled by default).
22917  You can enable it in 
22918 \family sans
22919 Preferences
22920 \family default
22921  (tabs 
22922 \family sans
22923 Inputs
22924 \family default
22925
22926 \family sans
22927 Paths
22928 \family default
22929 ) by entering in the 
22930 \family sans
22931 \SpecialChar LyX
22932 server pipe
22933 \family default
22934  a path like 
22935 \begin_inset Quotes eld
22936 \end_inset
22937
22938
22939 \family typewriter
22940 /home/<your-home-directory>/.lyx/lyxpipe
22941 \family default
22942
22943 \begin_inset Quotes erd
22944 \end_inset
22945
22946
22947 \end_layout
22948
22949 \begin_layout Standard
22950 Read the \SpecialChar LyX
22951  server documentation in the 
22952 \emph on
22953 Customization Manual
22954 \emph default
22955  for further information.
22956 \end_layout
22957
22958 \begin_layout Subsubsection
22959 Toolbar extensions
22960 \end_layout
22961
22962 \begin_layout Standard
22963 There are six new buttons that can be added to your \SpecialChar LyX
22964  toolbar.
22965  Five of these buttons are short cuts to layout styles: 
22966 \family sans
22967 Standard
22968 \family default
22969
22970 \family sans
22971 Section
22972 \family default
22973
22974 \family sans
22975 \SpecialChar LaTeX
22976
22977 \family default
22978
22979 \family sans
22980 \SpecialChar LyX
22981 -Code
22982 \family default
22983 , and 
22984 \family sans
22985 Chunk
22986 \family default
22987 .
22988  The last one is a short cut to the 
22989 \begin_inset Quotes eld
22990 \end_inset
22991
22992 Build Program
22993 \begin_inset Quotes erd
22994 \end_inset
22995
22996  File menu entry.
22997  
22998 \end_layout
22999
23000 \begin_layout Standard
23001 \SpecialChar LyX
23002  has a range of buttons that are available for tool bar customization.
23003  In my toolbar I like to combine the six short cuts above with two more:
23004  One for 
23005 \family sans
23006 Document
23007 \family default
23008 \SpecialChar menuseparator
23009
23010 \family sans
23011 Update
23012 \family default
23013 \SpecialChar menuseparator
23014
23015 \family sans
23016 DVI
23017 \family default
23018  and the other for 
23019 \family sans
23020 Document\SpecialChar menuseparator
23021 View\SpecialChar menuseparator
23022 DVI
23023 \family default
23024  File menu entries.
23025  Here is how it looks like:
23026 \end_layout
23027
23028 \begin_layout LyX-Code
23029 Toolbar
23030 \end_layout
23031
23032 \begin_layout LyX-Code
23033   Layouts
23034 \end_layout
23035
23036 \begin_layout LyX-Code
23037   Icon "layout Standard"
23038 \end_layout
23039
23040 \begin_layout LyX-Code
23041   Icon "layout Section"
23042 \end_layout
23043
23044 \begin_layout LyX-Code
23045   Icon "layout \SpecialChar LaTeX
23046 "
23047 \end_layout
23048
23049 \begin_layout LyX-Code
23050   Icon "layout \SpecialChar LyX
23051 -Code"
23052 \end_layout
23053
23054 \begin_layout LyX-Code
23055   Icon "layout Chunk"
23056 \end_layout
23057
23058 \begin_layout LyX-Code
23059   Separator
23060 \end_layout
23061
23062 \begin_layout LyX-Code
23063   Icon "buffer-view"
23064 \end_layout
23065
23066 \begin_layout LyX-Code
23067   Icon "buffer-typeset"
23068 \end_layout
23069
23070 \begin_layout LyX-Code
23071   Icon "build-program"
23072 \end_layout
23073
23074 \begin_layout LyX-Code
23075   Separator
23076 \end_layout
23077
23078 \begin_layout LyX-Code
23079 .
23080 \end_layout
23081
23082 \begin_layout LyX-Code
23083 .
23084 \end_layout
23085
23086 \begin_layout LyX-Code
23087 .
23088 \end_layout
23089
23090 \begin_layout LyX-Code
23091 End
23092 \end_layout
23093
23094 \begin_layout Subsubsection
23095 Colors customization
23096 \end_layout
23097
23098 \begin_layout Standard
23099 There are a number of colors in \SpecialChar LyX
23100  that can be customized in 
23101 \family sans
23102 Preferences
23103 \family default
23104 .
23105  One of the things that bothers people is the \SpecialChar LaTeX
23106  font color.
23107  The default color is red, since the chunks uses \SpecialChar LaTeX
23108  font, and there is a lot
23109  of chunks in literate documents, you may get tired of seeing everything
23110  in red.
23111  You can change it by going to the tabs 
23112 \family sans
23113 Look&Feel
23114 \family default
23115
23116 \family sans
23117 Colors.
23118 \end_layout
23119
23120 \begin_layout Standard
23121 The next thing is the visible presence of the newline character in the screen.
23122  You can choose the color of this particular character and make it blend
23123  in the background.
23124  I recommend you choosing a color that is close to the background but not
23125  equal, that way you still can see it is there, but it is not bothering
23126  you anymore.
23127 \end_layout
23128
23129 \begin_layout Subsection
23130 \SpecialChar LyX
23131  and knitr/Sweave
23132 \end_layout
23133
23134 \begin_layout Standard
23135 Support for 
23136 \family sans
23137 knitr
23138 \family default
23139  and 
23140 \family sans
23141 Sweave
23142 \family default
23143  is documented in the 
23144 \emph on
23145 knitr.lyx
23146 \emph default
23147  example file and in the Sweave manual (menu 
23148 \family sans
23149 Help\SpecialChar menuseparator
23150 Specific Manuals
23151 \family default
23152 ).
23153 \end_layout
23154
23155 \begin_layout Chapter
23156 \SpecialChar LyX
23157  Archives
23158 \end_layout
23159
23160 \begin_layout Standard
23161 Users sometimes need to be able to 
23162 \begin_inset Quotes eld
23163 \end_inset
23164
23165 bundle
23166 \begin_inset Quotes erd
23167 \end_inset
23168
23169  a \SpecialChar LyX
23170  file together with all the images (and other files) on which it depends,
23171  either for sending to a publisher or for sharing with a co-author.
23172  \SpecialChar LyX
23173  2.0 includes a Python script (
23174 \begin_inset Flex Code
23175 status collapsed
23176
23177 \begin_layout Plain Layout
23178 lyxpak.py
23179 \end_layout
23180
23181 \end_inset
23182
23183 ) that automates this process.
23184  To use it, you must have either the 
23185 \begin_inset Flex Code
23186 status collapsed
23187
23188 \begin_layout Plain Layout
23189 zipfile
23190 \end_layout
23191
23192 \end_inset
23193
23194  or 
23195 \begin_inset Flex Code
23196 status collapsed
23197
23198 \begin_layout Plain Layout
23199 tarfile
23200 \end_layout
23201
23202 \end_inset
23203
23204  python modules installed on your system.
23205  By default, the script prefers the 
23206 \begin_inset Flex Code
23207 status collapsed
23208
23209 \begin_layout Plain Layout
23210 gzip
23211 \end_layout
23212
23213 \end_inset
23214
23215 -compressed 
23216 \begin_inset Flex Code
23217 status collapsed
23218
23219 \begin_layout Plain Layout
23220 tar
23221 \end_layout
23222
23223 \end_inset
23224
23225  format on Unix-like systems and the 
23226 \begin_inset Flex Code
23227 status collapsed
23228
23229 \begin_layout Plain Layout
23230 zip
23231 \end_layout
23232
23233 \end_inset
23234
23235  format on Windows.
23236 \end_layout
23237
23238 \begin_layout Standard
23239 \SpecialChar LyX
23240 's configuration process will set the script up to export a `\SpecialChar LyX
23241  Archive',
23242  and this format will then be available under 
23243 \begin_inset Flex Code
23244 status collapsed
23245
23246 \begin_layout Plain Layout
23247 File\SpecialChar menuseparator
23248 Export
23249 \end_layout
23250
23251 \end_inset
23252
23253 .
23254 \end_layout
23255
23256 \begin_layout Standard
23257 Independently of the platform, the generation of a particular archive format
23258  can be forced by adding either the 
23259 \begin_inset Flex Code
23260 status collapsed
23261
23262 \begin_layout Plain Layout
23263 -t
23264 \end_layout
23265
23266 \end_inset
23267
23268  (for the 
23269 \begin_inset Flex Code
23270 status collapsed
23271
23272 \begin_layout Plain Layout
23273 tar
23274 \end_layout
23275
23276 \end_inset
23277
23278  format) or 
23279 \begin_inset Flex Code
23280 status collapsed
23281
23282 \begin_layout Plain Layout
23283 -z
23284 \end_layout
23285
23286 \end_inset
23287
23288  (for the 
23289 \begin_inset Flex Code
23290 status collapsed
23291
23292 \begin_layout Plain Layout
23293 zip
23294 \end_layout
23295
23296 \end_inset
23297
23298  format) switch to the 
23299 \begin_inset Flex Code
23300 status collapsed
23301
23302 \begin_layout Plain Layout
23303 \SpecialChar LyX
23304 \SpecialChar menuseparator
23305 \SpecialChar LyX
23306  Archive
23307 \end_layout
23308
23309 \end_inset
23310
23311  converter in 
23312 \begin_inset Flex Code
23313 status collapsed
23314
23315 \begin_layout Plain Layout
23316 Tools\SpecialChar menuseparator
23317 Preferences\SpecialChar menuseparator
23318 File Handling\SpecialChar menuseparator
23319 Converters
23320 \end_layout
23321
23322 \end_inset
23323
23324 .
23325  (Make sure you add the switch after the script name, not before it.)
23326 \end_layout
23327
23328 \begin_layout Chapter
23329 \SpecialChar LyX
23330  and the World Wide Web
23331 \end_layout
23332
23333 \begin_layout Standard
23334 \SpecialChar LyX
23335  has long supported the export of documents to various web-friendly formats,
23336  such as HTML.
23337  Before verson 2.0, however, HTML export was always accomplished by the use
23338  of external converters.
23339 \begin_inset Foot
23340 status collapsed
23341
23342 \begin_layout Plain Layout
23343 For details on the use of external converters with \SpecialChar LyX
23344 , see the 
23345 \emph on
23346 Converters
23347 \emph default
23348  section of the Customization manual.
23349 \end_layout
23350
23351 \end_inset
23352
23353  These fall into two large groups: there are converters that use \SpecialChar LaTeX
23354  as an
23355  intermediate format, such as 
23356 \begin_inset Flex Code
23357 status collapsed
23358
23359 \begin_layout Plain Layout
23360 htlatex
23361 \end_layout
23362
23363 \end_inset
23364
23365
23366 \begin_inset Flex Code
23367 status collapsed
23368
23369 \begin_layout Plain Layout
23370 html2latex
23371 \end_layout
23372
23373 \end_inset
23374
23375 , and 
23376 \begin_inset Flex Code
23377 status collapsed
23378
23379 \begin_layout Plain Layout
23380 plastex
23381 \end_layout
23382
23383 \end_inset
23384
23385 , relying upon \SpecialChar LyX
23386  to produce the \SpecialChar LaTeX
23387 ; and there is a converter that works directly
23388  on \SpecialChar LyX
23389  files, 
23390 \begin_inset Flex Code
23391 status collapsed
23392
23393 \begin_layout Plain Layout
23394 e\SpecialChar LyX
23395 er
23396 \end_layout
23397
23398 \end_inset
23399
23400 .
23401  All of these have different advantages and disadvantages.
23402  
23403 \end_layout
23404
23405 \begin_layout Standard
23406 The \SpecialChar LaTeX
23407 -based converters have the advantage that, in principle, they know everythin
23408 g about the exported document that \SpecialChar LaTeX
23409  does.
23410  Such converters do not care, for example, if a certain block of code was
23411  produced by \SpecialChar LyX
23412  or was Evil Red Text.
23413  These converters know about 
23414 \begin_inset Flex Code
23415 status collapsed
23416
23417 \begin_layout Plain Layout
23418 aux
23419 \end_layout
23420
23421 \end_inset
23422
23423  files, counters, and references, and can often make use of the 
23424 \begin_inset Flex Code
23425 status collapsed
23426
23427 \begin_layout Plain Layout
23428 bbl
23429 \end_layout
23430
23431 \end_inset
23432
23433  files generated by Bib\SpecialChar TeX
23434 .
23435  On the other hand, \SpecialChar LaTeX
23436  is a very hard language to parse—it is sometimes said
23437  that only \SpecialChar TeX
23438  itself understands \SpecialChar TeX
23439 —and \SpecialChar LaTeX
23440 -based converters will often choke on
23441  what seem to be quite simple constructs; complex ones can throw them completely
23442 , and as of this writing, for example, the 
23443 \emph on
23444 Embedded Objects
23445 \emph default
23446  manual will not export with 
23447 \begin_inset Flex Code
23448 status collapsed
23449
23450 \begin_layout Plain Layout
23451 htlatex
23452 \end_layout
23453
23454 \end_inset
23455
23456 , though the others will.
23457  The other issue concerns how math is handled.
23458  These converters typically convert the formulae into little pictures that
23459  are then linked from the HTML document.
23460  Since these are actually generated by \SpecialChar LaTeX
23461 , they are accurate.
23462  But they do not scale well, and just getting them to look as if they are
23463  actually meant to be in your document—so that the font sizes seem to be
23464  roughly the same—can be a challenge.
23465 \end_layout
23466
23467 \begin_layout Standard
23468 Alex Fernandez's 
23469 \begin_inset Flex Code
23470 status collapsed
23471
23472 \begin_layout Plain Layout
23473 e\SpecialChar LyX
23474 er
23475 \end_layout
23476
23477 \end_inset
23478
23479  (
23480 \begin_inset CommandInset href
23481 LatexCommand href
23482 name "http://elyxer.nongnu.org/"
23483 target "http://elyxer.nongnu.org/"
23484
23485 \end_inset
23486
23487 ) solves some of these problems.
23488  In particular, the formulae it produces scale perfectly, since it renders
23489  math using a combination of HTML and CSS rather than converting the formulae
23490  to images.
23491  But even moderately complex formula are rendered less well than with 
23492 \begin_inset Flex Code
23493 status collapsed
23494
23495 \begin_layout Plain Layout
23496 htlatex
23497 \end_layout
23498
23499 \end_inset
23500
23501 ; this reflects the limitations of HTML.
23502 \begin_inset Foot
23503 status collapsed
23504
23505 \begin_layout Plain Layout
23506 That said, 
23507 \begin_inset Flex Code
23508 status collapsed
23509
23510 \begin_layout Plain Layout
23511 e\SpecialChar LyX
23512 er
23513 \end_layout
23514
23515 \end_inset
23516
23517  can also use jsMath and MathJax for equations, but this setting is only
23518  available globally and requires one to have access to a server that runs
23519  the backend.
23520 \end_layout
23521
23522 \end_inset
23523
23524  More importantly (as of version 1.1.1, at least), 
23525 \begin_inset Flex Code
23526 status collapsed
23527
23528 \begin_layout Plain Layout
23529 e\SpecialChar LyX
23530 er
23531 \end_layout
23532
23533 \end_inset
23534
23535  has limited support for math macros and no support for user-defined paragraph
23536  or character styles.
23537  These limitations make 
23538 \begin_inset Flex Code
23539 status collapsed
23540
23541 \begin_layout Plain Layout
23542 e\SpecialChar LyX
23543 er
23544 \end_layout
23545
23546 \end_inset
23547
23548  unsuitable for many of the documents \SpecialChar LyX
23549  users produce.
23550  In principle, of course, these problems could be solved, but the \SpecialChar LyX
23551  developers
23552  have decided to follow a different path and have made \SpecialChar LyX
23553  itself capable of
23554  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
23555 , DocBook, and plaintext.
23556 \end_layout
23557
23558 \begin_layout Standard
23559 As of this writing, XHTML output remains under development and should probably
23560  be regarded as 
23561 \begin_inset Quotes eld
23562 \end_inset
23563
23564 experimental
23565 \begin_inset Quotes erd
23566 \end_inset
23567
23568 .
23569 \begin_inset Foot
23570 status collapsed
23571
23572 \begin_layout Plain Layout
23573 The file 
23574 \begin_inset Flex Code
23575 status collapsed
23576
23577 \begin_layout Plain Layout
23578 development/HTML.notes
23579 \end_layout
23580
23581 \end_inset
23582
23583 , which can be found in the \SpecialChar LyX
23584  source tree or 
23585 \begin_inset CommandInset href
23586 LatexCommand href
23587 name "accessed online"
23588 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
23589
23590 \end_inset
23591
23592 , usually contains up-to-date information about the state of XHTML output.
23593  See also the list of XHTML bugs on 
23594 \begin_inset CommandInset href
23595 LatexCommand href
23596 name "the bug tracker"
23597 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"
23598
23599 \end_inset
23600
23601 .
23602 \end_layout
23603
23604 \end_inset
23605
23606  Still, the developers have chosen this approach because it has several
23607  potential advantages over the other two.
23608 \end_layout
23609
23610 \begin_layout Standard
23611 These advantages are primarily due to the fact that the XHTML output routines,
23612  since they are part of \SpecialChar LyX
23613 , know everything \SpecialChar LyX
23614  knows about the document being
23615  exported.
23616 \begin_inset Foot
23617 status collapsed
23618
23619 \begin_layout Plain Layout
23620 Another advantage is that, since these routines are internal to \SpecialChar LyX
23621 , they are
23622  immune to changes in \SpecialChar LyX
23623 's file format, or to changes in the semantics of
23624  existing insets.
23625 \end_layout
23626
23627 \end_inset
23628
23629  So they know about the table of contents (as displayed in the outline),
23630  about the counters associated with different paragraph styles, and about
23631  user-defined styles.
23632  The XHTML output routines know what \SpecialChar LyX
23633  knows about internationalization,
23634  too, so they will output 
23635 \begin_inset Quotes eld
23636 \end_inset
23637
23638 Chapter 1
23639 \begin_inset Quotes erd
23640 \end_inset
23641
23642  or 
23643 \begin_inset Quotes eld
23644 \end_inset
23645
23646
23647 \lang ngerman
23648 Kapitel
23649 \lang english
23650  1
23651 \begin_inset Quotes erd
23652 \end_inset
23653
23654 , depending upon the language in effect at the time.
23655  
23656 \end_layout
23657
23658 \begin_layout Standard
23659 Quite generally, the output routines know what \SpecialChar LyX
23660  knows about document layout,
23661  that is, about how the document is to be rendered on screen.
23662  We use this information when we output the document as XHTML.
23663  In particular, \SpecialChar LyX
23664  
23665 \emph on
23666 automatically
23667 \emph default
23668  generates CSS style information corresponding to the layout information
23669  it uses to render the document on screen: if section headings are supposed
23670  to be sans-serif and bold as seen in \SpecialChar LyX
23671 , then (by default) they will be sans-seri
23672 f and bold when viewed in a web browser, too.
23673  And this is true not just for pre-defined styles, like Section, but for
23674  any style, including user-defined styles.
23675  Indeed, the XHTML output routines make no distinction between user-defined
23676  paragraph and character styles and \SpecialChar LyX
23677 's own pre-defined styles: in each case,
23678  everything \SpecialChar LyX
23679  knows about the styles is contained in the layout files.
23680  And much the same is true as regards pre-defined textual insets, such as
23681  footnotes, and various custom insets.
23682  
23683 \end_layout
23684
23685 \begin_layout Standard
23686 The result is that XHTML output can be customized and extended in exactly
23687  the same way \SpecialChar LaTeX
23688  output can be customized and extended: through layout files
23689  and modules.
23690  See chapter five of the 
23691 \emph on
23692 Customization 
23693 \emph default
23694 manual for the details.
23695 \end_layout
23696
23697 \begin_layout Standard
23698 The remainder of this chapter contains more detailed information on XHTML
23699  output, its limitations, and ways to work around those limitations.
23700 \end_layout
23701
23702 \begin_layout Section
23703 Math Output in XHTML
23704 \end_layout
23705
23706 \begin_layout Standard
23707 \SpecialChar LyX
23708  offers four choices for how math is rendered.
23709  These have various advantages and disadvantages:
23710 \end_layout
23711
23712 \begin_layout Itemize
23713 MathML
23714 \begin_inset Newline newline
23715 \end_inset
23716
23717 MathML is a dialect of XML designed specifically for mathematics on the
23718  web, and it typically renders very well in browsers that support it.
23719  The disadvantage is that not all browsers support MathML, and support is
23720  not complete even in the Gecko-based browsers, such as Firefox.
23721 \begin_inset Newline newline
23722 \end_inset
23723
23724 If \SpecialChar LyX
23725  is unable to render a formula as MathML—for example, if the formula
23726  uses the 
23727 \begin_inset Flex Code
23728 status collapsed
23729
23730 \begin_layout Plain Layout
23731 xymatrix
23732 \end_layout
23733
23734 \end_inset
23735
23736  package or ERT—then it will instead output the formula as an image.
23737  
23738 \end_layout
23739
23740 \begin_layout Itemize
23741 HTML
23742 \begin_inset Newline newline
23743 \end_inset
23744
23745 As mentioned above, 
23746 \begin_inset Flex Code
23747 status collapsed
23748
23749 \begin_layout Plain Layout
23750 elyxer
23751 \end_layout
23752
23753 \end_inset
23754
23755  outputs math as HTML, styled by CSS.
23756 \begin_inset Foot
23757 status collapsed
23758
23759 \begin_layout Plain Layout
23760 \SpecialChar LyX
23761  has borrowed some of the CSS for its HTML output from 
23762 \begin_inset Flex Code
23763 status collapsed
23764
23765 \begin_layout Plain Layout
23766 elyxer
23767 \end_layout
23768
23769 \end_inset
23770
23771 .
23772 \end_layout
23773
23774 \end_inset
23775
23776  For simple formulae, this can work quite well, though with more complicated
23777  formulae it tends to break down.
23778  Still, this method has the advantage that it is very widely supported and
23779  so it may be appropriate for documents that contain only a little, fairly
23780  simple math.
23781 \begin_inset Newline newline
23782 \end_inset
23783
23784 If Lyx is unable to render a formula as HTML—for example, if the formula
23785  uses the 
23786 \begin_inset Flex Code
23787 status collapsed
23788
23789 \begin_layout Plain Layout
23790 xymatrix
23791 \end_layout
23792
23793 \end_inset
23794
23795  package or ERT—then it will instead output the formula as an image.
23796  
23797 \end_layout
23798
23799 \begin_layout Itemize
23800 Images
23801 \begin_inset Newline newline
23802 \end_inset
23803
23804 Like 
23805 \begin_inset Flex Code
23806 status collapsed
23807
23808 \begin_layout Plain Layout
23809 htlatex
23810 \end_layout
23811
23812 \end_inset
23813
23814 , \SpecialChar LyX
23815  will output formulae as images, the very same images, in fact, that are
23816  used for instant preview.
23817 \begin_inset Foot
23818 status collapsed
23819
23820 \begin_layout Plain Layout
23821 Instant preview does 
23822 \emph on
23823 not 
23824 \emph default
23825 have to be on for images to be output, however.
23826 \end_layout
23827
23828 \end_inset
23829
23830  The advantage to this method is that the images are simply generated by
23831  \SpecialChar LaTeX
23832 , so they are very accurate.
23833  The disadvantage, as mentioned earlier, is that these are bitmapped images,
23834  so they do not scale terribly well, and one cannot copy them, etc.
23835  (As of this writing, there are also problems about equation numbering.
23836  See 
23837 \begin_inset CommandInset href
23838 LatexCommand href
23839 name "bug 6894"
23840 target "http://www.lyx.org/trac/ticket/6894"
23841
23842 \end_inset
23843
23844 .)
23845 \begin_inset Newline newline
23846 \end_inset
23847
23848 The size of the images can be controlled by setting the 
23849 \begin_inset Quotes eld
23850 \end_inset
23851
23852 Math Images Scaling
23853 \begin_inset Quotes erd
23854 \end_inset
23855
23856  parameter under 
23857 \begin_inset Flex Noun
23858 status collapsed
23859
23860 \begin_layout Plain Layout
23861 Document\SpecialChar menuseparator
23862 Settings\SpecialChar menuseparator
23863 Output
23864 \end_layout
23865
23866 \end_inset
23867
23868 .
23869 \begin_inset Foot
23870 status collapsed
23871
23872 \begin_layout Plain Layout
23873 For those who want to know, this controls the resolution of the image in
23874  dots per inch and is based upon a default of 75 dpi.
23875 \end_layout
23876
23877 \end_inset
23878
23879
23880 \begin_inset Newline newline
23881 \end_inset
23882
23883 If \SpecialChar LyX
23884  for some reason fails to create an image for a formula (e.g., if a required
23885  \SpecialChar LaTeX
23886  package is not installed), then it will fall back to outputing the raw
23887  \SpecialChar LaTeX
23888 .
23889 \end_layout
23890
23891 \begin_layout Itemize
23892 \SpecialChar LaTeX
23893
23894 \begin_inset Newline newline
23895 \end_inset
23896
23897 Finally, \SpecialChar LyX
23898  will happily output math as \SpecialChar LaTeX
23899 .
23900  As well as being the output of last resort, this method can be used with
23901  such tools as 
23902 \begin_inset CommandInset href
23903 LatexCommand href
23904 name "jsMath"
23905 target "http://www.math.union.edu/~dpvc/jsMath/"
23906
23907 \end_inset
23908
23909 , which uses JavaScript to render \SpecialChar LaTeX
23910  embedded in HTML documents.
23911  \SpecialChar LyX
23912  wraps the \SpecialChar LaTeX
23913  in either a 
23914 \begin_inset Flex Code
23915 status collapsed
23916
23917 \begin_layout Plain Layout
23918 span
23919 \end_layout
23920
23921 \end_inset
23922
23923  (for inline formulas) or 
23924 \begin_inset Flex Code
23925 status collapsed
23926
23927 \begin_layout Plain Layout
23928 div
23929 \end_layout
23930
23931 \end_inset
23932
23933  (for displayed formulas) with 
23934 \begin_inset Flex Code
23935 status collapsed
23936
23937 \begin_layout Plain Layout
23938 class='math'
23939 \end_layout
23940
23941 \end_inset
23942
23943 , as is required for jsMath.
23944 \end_layout
23945
23946 \begin_layout Standard
23947 One of these output methods must be selected under 
23948 \begin_inset Flex Noun
23949 status collapsed
23950
23951 \begin_layout Plain Layout
23952 Document\SpecialChar menuseparator
23953 Settings\SpecialChar menuseparator
23954 Output
23955 \end_layout
23956
23957 \end_inset
23958
23959 .
23960  By default, \SpecialChar LyX
23961  outputs MathML.
23962  This is a document-wide setting, therefore.
23963 \end_layout
23964
23965 \begin_layout Standard
23966 Eventually, \SpecialChar LyX
23967  will offer the user the option to select an alternate output
23968  method for a particular inset, say, one that isn't being rendered very
23969  well by MathML.
23970 \begin_inset Foot
23971 status collapsed
23972
23973 \begin_layout Plain Layout
23974 That said, since \SpecialChar LyX
23975  falls back to images if the inset contains ERT, then one
23976  can force output as an image by putting some harmless ERT into the math,
23977  for example: 
23978 \begin_inset Formula $a=b\relax$
23979 \end_inset
23980
23981 .
23982 \end_layout
23983
23984 \end_inset
23985
23986
23987 \end_layout
23988
23989 \begin_layout Section
23990 Bibliography and Citations
23991 \end_layout
23992
23993 \begin_layout Standard
23994 XHTML output fully supports bibliographies and citations.
23995  
23996 \end_layout
23997
23998 \begin_layout Standard
23999 Citation labels are generated by the same machinery that generates \SpecialChar LyX
24000 's on-screen
24001  labels, so the labels will look in the output much as they do in \SpecialChar LyX
24002 , though
24003  better.
24004  If you are using numerical citations, then \SpecialChar LyX
24005  will output numerical labels,
24006  such as [1] or [17], rather than simply showing the citation key in square
24007  brackets, as it does on-screen.
24008  If you are using author-year citations, then \SpecialChar LyX
24009  will add lowercase letters
24010  to the years, just as Bib\SpecialChar TeX
24011  does, if it finds more than one citation for
24012  a given author-year combination.
24013  The labels will be printed with the bibliography entries.
24014  Note that there is, at present, no way to customize the appearance of the
24015  labels, for example, to choose between square brackets and parentheses.
24016 \end_layout
24017
24018 \begin_layout Standard
24019 Bibliography output is handled by the same machinery that handles the presentati
24020 on of reference information in the citation dialog, so you will see in the
24021  XHTML output pretty much what you would see if you were to look at a given
24022  entry in the citation dialog.
24023  The formatting can be customized in your layout file or, preferably, in
24024  a module.
24025  See the 
24026 \emph on
24027 Customization
24028 \emph default
24029  manual for the details.
24030 \end_layout
24031
24032 \begin_layout Standard
24033 The main defect at present is that cross-referenced information is printed
24034  with every entry with which it is associated.
24035  So you can see things like this:
24036 \end_layout
24037
24038 \begin_layout Quote
24039 Jason Stanley, 
24040 \begin_inset Quotes eld
24041 \end_inset
24042
24043 Context and Logical Form
24044 \begin_inset Quotes erd
24045 \end_inset
24046
24047 , in 
24048 \emph on
24049 Language in Context: Selected Essays
24050 \emph default
24051  (Oxford: Oxford University Press, 2007), pp.
24052  30–68.
24053 \end_layout
24054
24055 \begin_layout Quote
24056 Jason Stanley, 
24057 \begin_inset Quotes eld
24058 \end_inset
24059
24060 Semantics in Context
24061 \begin_inset Quotes erd
24062 \end_inset
24063
24064 , in 
24065 \emph on
24066 Language in Context: Selected Essays
24067 \emph default
24068  (Oxford: Oxford University Press, 2007), pp.
24069  201–30.
24070 \end_layout
24071
24072 \begin_layout Standard
24073 This should be fixed before long.
24074 \end_layout
24075
24076 \begin_layout Standard
24077 There is no support at present for sectioned bibliographies.
24078  If you have multiple bibliographies, then \SpecialChar LyX
24079  will print the same bibliography
24080  over and over.
24081 \end_layout
24082
24083 \begin_layout Section
24084 Indexes
24085 \end_layout
24086
24087 \begin_layout Standard
24088 \SpecialChar LyX
24089  will happily export indexes as XHTML, but with certain limitations at the
24090  moment.
24091 \end_layout
24092
24093 \begin_layout Standard
24094 Index export will be most reliable when you do not attempt to use the fancy
24095  constructs that are described in the section on indexes in the 
24096 \emph on
24097 User's Guide
24098 \emph default
24099 .
24100 \begin_inset Foot
24101 status collapsed
24102
24103 \begin_layout Plain Layout
24104 The main issue here is that \SpecialChar LyX
24105  itself does not really handle these.
24106  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
24107 .
24108 \end_layout
24109
24110 \end_inset
24111
24112  We'll describe how they are handled using the subsection headings from
24113  that section.
24114 \end_layout
24115
24116 \begin_layout Itemize
24117 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
24118  makes an effort to support these,
24119  but the entries must be separated by 
24120 \begin_inset Quotes eld
24121 \end_inset
24122
24123  ! 
24124 \begin_inset Quotes erd
24125 \end_inset
24126
24127 , that is, there must be spaces around the exclamation point.
24128  This is because it is otherwise too difficult to check for escaped exclamation
24129  points, ones in math, and so forth.
24130 \end_layout
24131
24132 \begin_layout Itemize
24133 Page Ranges: There is no support at all for page ranges, since these make
24134  no sense with XHMTL.
24135  Instead, you will just get two index entries, one at either end.
24136 \end_layout
24137
24138 \begin_layout Itemize
24139 Cross-referencing: There is no support for cross-referencing.
24140  If \SpecialChar LyX
24141  finds an entry containing the 
24142 \begin_inset Quotes eld
24143 \end_inset
24144
24145 |see\SpecialChar ldots
24146
24147 \begin_inset Quotes erd
24148 \end_inset
24149
24150  construct, it is just dropped, and the rest is treated as an ordinary index
24151  entry.
24152 \end_layout
24153
24154 \begin_layout Itemize
24155 Index Entry Order: \SpecialChar LyX
24156  does support attempts to fix the sorting order.
24157  It will take what is before the first `@' it finds and use that for sorting,
24158  taking what follows the first `@' to be the actual entry.
24159  At present, \SpecialChar LyX
24160  does not check for escaped `@', so do not try to index email
24161  addresses.
24162 \end_layout
24163
24164 \begin_layout Itemize
24165 Index Entry Layout: You can format entries by using the text style dialog,
24166  or by using any other method available within \SpecialChar LyX
24167  itself.
24168  There is no support for constructs like: 
24169 \begin_inset Quotes eld
24170 \end_inset
24171
24172 entry|textbf
24173 \begin_inset Quotes erd
24174 \end_inset
24175
24176 .
24177  Indeed, if \SpecialChar LyX
24178  finds a pipe symbol, `|', in an entry, it will delete it and
24179  everything that follows it.
24180 \end_layout
24181
24182 \begin_layout Itemize
24183 Multiple Indexes: There is no support for multiple indexes.
24184  Rather, all index entries will be printed as one large index.
24185  To avoid our printing several versions of the index, we print only the
24186  main index, so make sure you have one.
24187 \end_layout
24188
24189 \begin_layout Section
24190 Nomenclature and Glossary
24191 \end_layout
24192
24193 \begin_layout Standard
24194 There is at present no support for glossaries.
24195  Adding it would be fairly trivial, and welcome.
24196 \end_layout
24197
24198 \begin_layout Chapter
24199 The \SpecialChar LyX
24200  Server
24201 \end_layout
24202
24203 \begin_layout Section
24204 Introduction
24205 \end_layout
24206
24207 \begin_layout Standard
24208 The `\SpecialChar LyX
24209  server' allows other programs to talk to \SpecialChar LyX
24210 , invoke \SpecialChar LyX
24211  commands, and retrieve
24212  information about the \SpecialChar LyX
24213  internal state.
24214  This is only intended for advanced users, but they should find it useful.
24215  It is by writing to the \SpecialChar LyX
24216  server, for example, that bibliography managers,
24217  such as JabRef, are able to 
24218 \begin_inset Quotes eld
24219 \end_inset
24220
24221 push
24222 \begin_inset Quotes erd
24223 \end_inset
24224
24225  citations to \SpecialChar LyX
24226 .
24227 \end_layout
24228
24229 \begin_layout Section
24230 Starting the \SpecialChar LyX
24231  Server
24232 \end_layout
24233
24234 \begin_layout Standard
24235 The \SpecialChar LyX
24236  server works through the use of a pair of named pipes.
24237  These are usually located in 
24238 \begin_inset Flex Code
24239 status collapsed
24240
24241 \begin_layout Plain Layout
24242 UserDir
24243 \end_layout
24244
24245 \end_inset
24246
24247 , (except on Windows, where 
24248 \emph on
24249 local
24250 \emph default
24251  named pipes are special objects located in 
24252 \begin_inset Flex Code
24253 status collapsed
24254
24255 \begin_layout Plain Layout
24256
24257 \backslash
24258
24259 \backslash
24260 .
24261 \backslash
24262 pipe
24263 \end_layout
24264
24265 \end_inset
24266
24267 ) and have the names 
24268 \begin_inset Quotes eld
24269 \end_inset
24270
24271
24272 \begin_inset Flex Code
24273 status collapsed
24274
24275 \begin_layout Plain Layout
24276 lyxpipe.in
24277 \end_layout
24278
24279 \end_inset
24280
24281
24282 \begin_inset Quotes erd
24283 \end_inset
24284
24285  and 
24286 \begin_inset Quotes eld
24287 \end_inset
24288
24289
24290 \begin_inset Flex Code
24291 status collapsed
24292
24293 \begin_layout Plain Layout
24294 lyxpipe.out
24295 \end_layout
24296
24297 \end_inset
24298
24299
24300 \begin_inset Quotes erd
24301 \end_inset
24302
24303 .
24304  External programs write into 
24305 \begin_inset Flex Code
24306 status collapsed
24307
24308 \begin_layout Plain Layout
24309 lyxpipe.in
24310 \end_layout
24311
24312 \end_inset
24313
24314  and read back data from 
24315 \begin_inset Flex Code
24316 status collapsed
24317
24318 \begin_layout Plain Layout
24319 lyxpipe.out
24320 \end_layout
24321
24322 \end_inset
24323
24324 .
24325  The stem of the pipe names can be defined in the 
24326 \begin_inset Flex Noun
24327 status collapsed
24328
24329 \begin_layout Plain Layout
24330 Tools\SpecialChar menuseparator
24331 Preferences
24332 \end_layout
24333
24334 \end_inset
24335
24336  dialog, for example 
24337 \begin_inset Flex Code
24338 status collapsed
24339
24340 \begin_layout Plain Layout
24341 "/home/myhome/lyxpipe"
24342 \end_layout
24343
24344 \end_inset
24345
24346 , or 
24347 \begin_inset Flex Code
24348 status collapsed
24349
24350 \begin_layout Plain Layout
24351 "
24352 \backslash
24353
24354 \backslash
24355 .
24356 \backslash
24357 pipe
24358 \backslash
24359 lyxpipe"
24360 \end_layout
24361
24362 \end_inset
24363
24364  on Windows (where any working path instead of lyxpipe can be used, for
24365  example 
24366 \begin_inset Flex Code
24367 status collapsed
24368
24369 \begin_layout Plain Layout
24370 "
24371 \backslash
24372
24373 \backslash
24374 .
24375 \backslash
24376 pipe
24377 \backslash
24378 my
24379 \backslash
24380 lyx
24381 \backslash
24382 pipe"
24383 \end_layout
24384
24385 \end_inset
24386
24387  would also work).
24388  You 
24389 \emph on
24390 must
24391 \emph default
24392  configure this manually in order for the server to start.
24393 \end_layout
24394
24395 \begin_layout Standard
24396 \SpecialChar LyX
24397  will add the '
24398 \begin_inset Flex Code
24399 status collapsed
24400
24401 \begin_layout Plain Layout
24402 .in
24403 \end_layout
24404
24405 \end_inset
24406
24407 ' and '
24408 \begin_inset Flex Code
24409 status collapsed
24410
24411 \begin_layout Plain Layout
24412 .out
24413 \end_layout
24414
24415 \end_inset
24416
24417 ' to create the pipes.
24418  If one of the pipes already exists, \SpecialChar LyX
24419  will assume that another \SpecialChar LyX
24420  process
24421  is already running and will not start the server.
24422  On POSIX (Unix like) systems, if for some other reason, an unused 
24423 \begin_inset Quotes eld
24424 \end_inset
24425
24426 stale
24427 \begin_inset Quotes erd
24428 \end_inset
24429
24430  pipe is left in existence when \SpecialChar LyX
24431  closes, then \SpecialChar LyX
24432  will try to delete it.
24433  If this fails for some reason, you will need to delete the pipes manually
24434  and then restart \SpecialChar LyX
24435 .
24436  On Windows, pipes are deleted by the OS on program termination or crash,
24437  so 
24438 \begin_inset Quotes eld
24439 \end_inset
24440
24441 stale
24442 \begin_inset Quotes erd
24443 \end_inset
24444
24445  pipes should not be possible.
24446 \end_layout
24447
24448 \begin_layout Standard
24449 To have several \SpecialChar LyX
24450  processes with servers at the same time, you have to use
24451  different configurations, perhaps by using separate user directories, each
24452  with its own 
24453 \begin_inset Flex Code
24454 status collapsed
24455
24456 \begin_layout Plain Layout
24457 preferences
24458 \end_layout
24459
24460 \end_inset
24461
24462  file, for each process.
24463 \end_layout
24464
24465 \begin_layout Standard
24466 If you are developing a client program, you might find it useful to enable
24467  debugging information from the \SpecialChar LyX
24468  server.
24469  Do this by starting \SpecialChar LyX
24470  as 
24471 \begin_inset Flex Code
24472 status collapsed
24473
24474 \begin_layout Plain Layout
24475 lyx -dbg lyxserver
24476 \end_layout
24477
24478 \end_inset
24479
24480 .
24481 \end_layout
24482
24483 \begin_layout Standard
24484 You can find a complete example client written in C++ in the source distribution
24485  as 
24486 \begin_inset Flex Code
24487 status collapsed
24488
24489 \begin_layout Plain Layout
24490 development/lyxserver/server_monitor.cpp
24491 \end_layout
24492
24493 \end_inset
24494
24495 .
24496 \end_layout
24497
24498 \begin_layout Standard
24499 Another useful tool is the command-line based client found in 
24500 \begin_inset Flex Code
24501 status collapsed
24502
24503 \begin_layout Plain Layout
24504 src/client/lyxclient
24505 \end_layout
24506
24507 \end_inset
24508
24509 .
24510 \end_layout
24511
24512 \begin_layout Section
24513 Normal communication
24514 \end_layout
24515
24516 \begin_layout Standard
24517 To issue a \SpecialChar LyX
24518  call, the client writes a line of ASCII text into the input
24519  pipe.
24520  This line has the following format:
24521 \end_layout
24522
24523 \begin_layout Quote
24524 LYXCMD:
24525 \emph on
24526 clientname
24527 \emph default
24528 :
24529 \emph on
24530 function
24531 \emph default
24532 :
24533 \emph on
24534 argument
24535 \end_layout
24536
24537 \begin_layout Description
24538 clientname is a name that the client can choose arbitrarily.
24539  Its only use is that \SpecialChar LyX
24540  will echo it if it sends an answer—so a client can
24541  dispatch results from different requesters.
24542 \end_layout
24543
24544 \begin_layout Description
24545 function is the function you want \SpecialChar LyX
24546  to perform.
24547  It is the same as the commands you'd use in the minibuffer.
24548 \end_layout
24549
24550 \begin_layout Description
24551 argument is an optional argument which is meaningful only to some functions
24552  (for instance, the 
24553 \begin_inset Quotes eld
24554 \end_inset
24555
24556 self-insert
24557 \begin_inset Quotes erd
24558 \end_inset
24559
24560  LFUN will insert the argument as text at the cursor position).
24561 \end_layout
24562
24563 \begin_layout Standard
24564 The answer from \SpecialChar LyX
24565  will arrive in the output pipe and be of the form
24566 \end_layout
24567
24568 \begin_layout Quote
24569 INFO:
24570 \emph on
24571 clientname
24572 \emph default
24573 :
24574 \emph on
24575 function
24576 \emph default
24577 :
24578 \emph on
24579 data
24580 \end_layout
24581
24582 \begin_layout Standard
24583 where 
24584 \emph on
24585 clientname
24586 \emph default
24587  and 
24588 \emph on
24589 function
24590 \emph default
24591  are just echoed from the command request, while 
24592 \emph on
24593 data
24594 \emph default
24595  is more or less useful information filled according to how the command
24596  execution worked out.
24597  Some commands, such as 
24598 \begin_inset Quotes eld
24599 \end_inset
24600
24601 font-state
24602 \begin_inset Quotes erd
24603 \end_inset
24604
24605 , will return information about the internal state of \SpecialChar LyX
24606 , while other will
24607  return an empty data-response.
24608  This means that the command execution went fine.
24609 \end_layout
24610
24611 \begin_layout Standard
24612 In case of errors, the response from \SpecialChar LyX
24613  will have this form
24614 \end_layout
24615
24616 \begin_layout Quote
24617 ERROR:
24618 \emph on
24619 clientname
24620 \emph default
24621 :
24622 \emph on
24623 function
24624 \emph default
24625 :
24626 \emph on
24627 error message
24628 \end_layout
24629
24630 \begin_layout Standard
24631 where the 
24632 \emph on
24633 error message
24634 \emph default
24635  should contain an explanation of why the command failed.
24636 \end_layout
24637
24638 \begin_layout Standard
24639 Examples:
24640 \end_layout
24641
24642 \begin_layout LyX-Code
24643 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
24644 \begin_inset Newline newline
24645 \end_inset
24646
24647 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
24648 \begin_inset Newline newline
24649 \end_inset
24650
24651 read a <~/.lyxpipe.out
24652 \begin_inset Newline newline
24653 \end_inset
24654
24655 echo $a
24656 \end_layout
24657
24658 \begin_layout Subsection
24659 AppleScript (Mac OS X)
24660 \end_layout
24661
24662 \begin_layout Standard
24663 Since \SpecialChar LyX
24664  2.1, \SpecialChar LyX
24665  supports basic interactions with AppleScript for normal communicatio
24666 n through the command run.
24667  This command takes a direct argument (the 
24668 \series bold
24669 function
24670 \series default
24671  to perform) and an optional argument.
24672  It either returns the output of the function or triggers an error with
24673  the error message and code.
24674 \end_layout
24675
24676 \begin_layout Standard
24677 Example:
24678 \end_layout
24679
24680 \begin_layout LyX-Code
24681 tell application "\SpecialChar LyX
24682 "
24683 \end_layout
24684
24685 \begin_layout LyX-Code
24686   try
24687 \end_layout
24688
24689 \begin_layout LyX-Code
24690     -- Stores the current file name into f
24691 \end_layout
24692
24693 \begin_layout LyX-Code
24694     set f to (run "server-get-filename" with argument "")
24695 \end_layout
24696
24697 \begin_layout LyX-Code
24698     on error the error_message number the error_number
24699 \end_layout
24700
24701 \begin_layout LyX-Code
24702       display dialog "Error: " & the error_number & ".
24703  " ¬
24704 \end_layout
24705
24706 \begin_layout LyX-Code
24707               & the error_message buttons {"OK"} default button 1
24708 \end_layout
24709
24710 \begin_layout LyX-Code
24711   end try
24712 \end_layout
24713
24714 \begin_layout LyX-Code
24715 end tell
24716 \end_layout
24717
24718 \begin_layout Section
24719 Notification
24720 \end_layout
24721
24722 \begin_layout Standard
24723 \SpecialChar LyX
24724  can notify clients of events going on asynchronously.
24725  Currently it will only do this if the user binds a key sequence with the
24726  function 
24727 \begin_inset Quotes eld
24728 \end_inset
24729
24730 notify
24731 \begin_inset Quotes erd
24732 \end_inset
24733
24734 .
24735  The format of the string \SpecialChar LyX
24736  sends is as follows:
24737 \end_layout
24738
24739 \begin_layout Quote
24740 \begin_inset Flex Code
24741 status collapsed
24742
24743 \begin_layout Plain Layout
24744 NOTIFY:
24745 \end_layout
24746
24747 \end_inset
24748
24749
24750 \emph on
24751 key-sequence
24752 \end_layout
24753
24754 \begin_layout Standard
24755 where 
24756 \emph on
24757 key-sequence
24758 \emph default
24759  is the printed representation of the key sequence that was actually typed
24760  by the user.
24761 \end_layout
24762
24763 \begin_layout Standard
24764 This mechanism can be used to extend \SpecialChar LyX
24765 's command set and implement macros.
24766  Bind some key sequence to 
24767 \begin_inset Quotes eld
24768 \end_inset
24769
24770 notify
24771 \begin_inset Quotes erd
24772 \end_inset
24773
24774 .
24775  Then start a client that listens on the output pipe, dispatches the command
24776  according to the sequence, and starts a function that may use \SpecialChar LyX
24777  calls and
24778  \SpecialChar LyX
24779  requests to issue a command or a series of commands to \SpecialChar LyX
24780 .
24781 \end_layout
24782
24783 \begin_layout Section
24784 The simple \SpecialChar LyX
24785  Server Protocol
24786 \end_layout
24787
24788 \begin_layout Standard
24789 \SpecialChar LyX
24790  implements a simple protocol that can be used for session management.
24791  All messages are of the form
24792 \end_layout
24793
24794 \begin_layout Quote
24795 LYXSRV:
24796 \emph on
24797 clientname
24798 \emph default
24799 :
24800 \emph on
24801 protocol message
24802 \end_layout
24803
24804 \begin_layout Standard
24805 where 
24806 \emph on
24807 protocol message
24808 \emph default
24809  can be 
24810 \begin_inset Quotes eld
24811 \end_inset
24812
24813 hello
24814 \begin_inset Quotes erd
24815 \end_inset
24816
24817  or 
24818 \begin_inset Quotes eld
24819 \end_inset
24820
24821 bye
24822 \begin_inset Quotes erd
24823 \end_inset
24824
24825 .
24826  If 
24827 \begin_inset Quotes eld
24828 \end_inset
24829
24830 hello
24831 \begin_inset Quotes erd
24832 \end_inset
24833
24834  is received from a client, \SpecialChar LyX
24835  will report back to inform the client that
24836  it's listening to it's messages, while 
24837 \begin_inset Quotes eld
24838 \end_inset
24839
24840 bye
24841 \begin_inset Quotes erd
24842 \end_inset
24843
24844  sent from \SpecialChar LyX
24845  will inform clients that \SpecialChar LyX
24846  is closing.
24847 \end_layout
24848
24849 \begin_layout Section
24850 Reverse DVI/PDF search
24851 \end_layout
24852
24853 \begin_layout Standard
24854 Some DVI/PDF viewers
24855 \begin_inset Foot
24856 status collapsed
24857
24858 \begin_layout Plain Layout
24859 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
24860  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
24861 \end_layout
24862
24863 \end_inset
24864
24865  provide 
24866 \emph on
24867 reverse search
24868 \emph default
24869  facility (also called 
24870 \emph on
24871 inverse search
24872 \emph default
24873 ).
24874  This means that you can tell \SpecialChar LyX
24875  to put the cursor to a specific line in the
24876  document by clicking at the respective position in the DVI/PDF output.
24877  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
24878 .
24879  This is done via the \SpecialChar LyX
24880  server either by using the named pipe (
24881 \emph on
24882 lyxpipe
24883 \emph default
24884 ), or the UNIX domain socket (
24885 \emph on
24886 lyxsocket
24887 \emph default
24888 ) that \SpecialChar LyX
24889  creates in its temporary directory (this is the way the 
24890 \begin_inset Flex Code
24891 status collapsed
24892
24893 \begin_layout Plain Layout
24894 lyxclient
24895 \end_layout
24896
24897 \end_inset
24898
24899  program communicates with \SpecialChar LyX
24900 ).
24901  In some cases, you need a helper script that mediates between the viewer
24902  and \SpecialChar LyX
24903 , in others, the viewer can communicate with \SpecialChar LyX
24904  directly.
24905  This depends on the selected viewer and on your operating system.
24906  The same applies to the way viewers need to be configured and the way the
24907  reverse search is actually performed.
24908  In what follows, we will thus describe how to setup reverse search for
24909  specific viewers.
24910  Before we turn to this, though, we will explain what needs to be done generally
24911  to enable reverse search in the DVI/PDF output.
24912 \end_layout
24913
24914 \begin_layout Subsection
24915 Automatic setup
24916 \begin_inset CommandInset label
24917 LatexCommand label
24918 name "subsec:rev-search"
24919
24920 \end_inset
24921
24922
24923 \end_layout
24924
24925 \begin_layout Standard
24926 In most cases \SpecialChar LyX
24927  will do the work for you by enabling the option 
24928 \begin_inset Flex Noun
24929 status collapsed
24930
24931 \begin_layout Plain Layout
24932 Synchronize with Output
24933 \end_layout
24934
24935 \end_inset
24936
24937  in the menu 
24938 \begin_inset Flex Noun
24939 status collapsed
24940
24941 \begin_layout Plain Layout
24942 Document\SpecialChar menuseparator
24943 Settings\SpecialChar menuseparator
24944 Output
24945 \end_layout
24946
24947 \end_inset
24948
24949 .
24950  In such a case \SpecialChar LyX
24951  will automatically insert the necessary Sync\SpecialChar TeX
24952  macro (for
24953  PDF) or load the srcltx package (for DVI) respectively.
24954  This option can be easily reached also on 
24955 \begin_inset Flex Code
24956 status collapsed
24957
24958 \begin_layout Plain Layout
24959 View/Update
24960 \end_layout
24961
24962 \end_inset
24963
24964  Toolbar.
24965 \end_layout
24966
24967 \begin_layout Standard
24968 If you need a different setting, you can select or input a custom macro
24969  from the drop down box just below 
24970 \begin_inset Flex Noun
24971 status collapsed
24972
24973 \begin_layout Plain Layout
24974 Document\SpecialChar menuseparator
24975 Settings\SpecialChar menuseparator
24976 Output\SpecialChar menuseparator
24977 Synchronize with Output
24978 \end_layout
24979
24980 \end_inset
24981
24982 .
24983 \end_layout
24984
24985 \begin_layout Standard
24986 Note that the method 
24987 \begin_inset Flex Code
24988 status collapsed
24989
24990 \begin_layout Plain Layout
24991
24992 \backslash
24993 synctex=1
24994 \end_layout
24995
24996 \end_inset
24997
24998  enables gzip compression.
24999  If your viewer does not support it, you should instead use 
25000 \begin_inset Flex Code
25001 status collapsed
25002
25003 \begin_layout Plain Layout
25004
25005 \backslash
25006 synctex=-1
25007 \end_layout
25008
25009 \end_inset
25010
25011 .
25012 \end_layout
25013
25014 \begin_layout Standard
25015 Please also note that including the 
25016 \begin_inset Flex Code
25017 status collapsed
25018
25019 \begin_layout Plain Layout
25020 srcltx
25021 \end_layout
25022
25023 \end_inset
25024
25025  package or 
25026 \begin_inset Flex Code
25027 status collapsed
25028
25029 \begin_layout Plain Layout
25030 src-specials
25031 \end_layout
25032
25033 \end_inset
25034
25035  sometimes has an undesired impact on the typesetting.
25036  Thus, you should switch output synchronization off for the final typesetting
25037  if you use the 
25038 \begin_inset Flex Code
25039 status collapsed
25040
25041 \begin_layout Plain Layout
25042 srcltx
25043 \end_layout
25044
25045 \end_inset
25046
25047  package or 
25048 \begin_inset Flex Code
25049 status collapsed
25050
25051 \begin_layout Plain Layout
25052 src-specials
25053 \end_layout
25054
25055 \end_inset
25056
25057 .
25058  
25059 \end_layout
25060
25061 \begin_layout Standard
25062 In case you need some more special settings that are not covered by the
25063  automatic settings, read the next section about how to set up output synchroniz
25064 ation manually.
25065  If the automatic setup suits your needs, you can readily jump to section
25066 \begin_inset space ~
25067 \end_inset
25068
25069
25070 \begin_inset CommandInset ref
25071 LatexCommand ref
25072 reference "subsec:configuring-viewers"
25073
25074 \end_inset
25075
25076 , where the necessary configuration steps in your viewer – needed both with
25077  the automatic and the manual setup – are described.
25078 \end_layout
25079
25080 \begin_layout Subsection
25081 Manual setup
25082 \end_layout
25083
25084 \begin_layout Standard
25085 \SpecialChar LaTeX
25086  provides several different methods for reverse search.
25087  Some are built-in in the 
25088 \begin_inset Flex Code
25089 status collapsed
25090
25091 \begin_layout Plain Layout
25092 latex/pdflatex
25093 \end_layout
25094
25095 \end_inset
25096
25097  program, some are provided by external packages.
25098  Your choice depends on whether your \SpecialChar LaTeX
25099  distribution already provides a given
25100  method (the built-in methods are rather new) and whether your viewer can
25101  cope with it.
25102  The available methods are described in the following.
25103 \end_layout
25104
25105 \begin_layout Subsubsection*
25106 Built-in DVI-search via src-specials (DVI only) 
25107 \end_layout
25108
25109 \begin_layout Standard
25110 This method provides the DVI file with the necessary information for reverse
25111  search.
25112  It is available in \SpecialChar LaTeX
25113  since quite some time (any somewhat recent \SpecialChar LaTeX
25114  distribution
25115  should include it), and it works reliably.
25116  To enable it, change the 
25117 \begin_inset Flex Noun
25118 status collapsed
25119
25120 \begin_layout Plain Layout
25121 La
25122 \family sans
25123 TeX
25124 \family default
25125  (plain)->DVI
25126 \end_layout
25127
25128 \end_inset
25129
25130  or 
25131 \begin_inset Flex Noun
25132 status collapsed
25133
25134 \begin_layout Plain Layout
25135 La
25136 \family sans
25137 TeX
25138 \family default
25139  (plain)->DraftDVI
25140 \end_layout
25141
25142 \end_inset
25143
25144  converter in 
25145 \begin_inset Flex Noun
25146 status collapsed
25147
25148 \begin_layout Plain Layout
25149 Preferences\SpecialChar menuseparator
25150 File Handling\SpecialChar menuseparator
25151 Converters
25152 \end_layout
25153
25154 \end_inset
25155
25156  to 
25157 \begin_inset Flex Code
25158 status collapsed
25159
25160 \begin_layout Plain Layout
25161 latex -src-specials $$i
25162 \end_layout
25163
25164 \end_inset
25165
25166 .
25167  If this doesn't work, check if your \SpecialChar TeX
25168  engine needs different options (the
25169  syntax might differ in some distributions).
25170 \end_layout
25171
25172 \begin_layout Subsubsection*
25173 External Packages (PDFSync and scrltx) 
25174 \end_layout
25175
25176 \begin_layout Standard
25177 The packages 
25178 \emph on
25179 pdfsync
25180 \emph default
25181  and 
25182 \emph on
25183 scrltx
25184 \emph default
25185  provide reverse search facility for PDF output (via pdflatex) and DVI output,
25186  respectively.
25187  In order to enable it, load the packages in the \SpecialChar LyX
25188  preamble: 
25189 \end_layout
25190
25191 \begin_layout Itemize
25192 \begin_inset Flex Code
25193 status collapsed
25194
25195 \begin_layout Plain Layout
25196
25197 \backslash
25198 usepackage{pdfsync}
25199 \end_layout
25200
25201 \end_inset
25202
25203  for reverse PDF search,
25204 \end_layout
25205
25206 \begin_layout Itemize
25207 \begin_inset Flex Code
25208 status collapsed
25209
25210 \begin_layout Plain Layout
25211
25212 \backslash
25213 usepackage[active]{srcltx}
25214 \end_layout
25215
25216 \end_inset
25217
25218  for reverse DVI search.
25219 \end_layout
25220
25221 \begin_layout Standard
25222 If you want to be able to perform both DVI and PDF reverse searches, you
25223  can also insert in the preamble the following lines
25224 \end_layout
25225
25226 \begin_layout LyX-Code
25227
25228 \backslash
25229 usepackage{ifpdf}
25230 \begin_inset Newline newline
25231 \end_inset
25232
25233
25234 \backslash
25235 ifpdf
25236 \begin_inset Newline newline
25237 \end_inset
25238
25239   
25240 \backslash
25241 usepackage{pdfsync}
25242 \begin_inset Newline newline
25243 \end_inset
25244
25245
25246 \backslash
25247 else
25248 \begin_inset Newline newline
25249 \end_inset
25250
25251   
25252 \backslash
25253 usepackage[active]{srcltx}
25254 \begin_inset Newline newline
25255 \end_inset
25256
25257
25258 \backslash
25259 fi
25260 \end_layout
25261
25262 \begin_layout Standard
25263 This way, you can preview the file as either DVI or PDF (pdflatex) and the
25264  right package will be used.
25265 \end_layout
25266
25267 \begin_layout Standard
25268 Note that PDFSync might affect the output layout of your document.
25269  It is therefore advised to disable PDFsync for final documents.
25270 \end_layout
25271
25272 \begin_layout Subsubsection*
25273 Built-in reverse search via Sync\SpecialChar TeX
25274  (DVI and PDF) 
25275 \end_layout
25276
25277 \begin_layout Standard
25278 Recent versions of 
25279 \begin_inset Flex Code
25280 status collapsed
25281
25282 \begin_layout Plain Layout
25283 (pdf)latex
25284 \end_layout
25285
25286 \end_inset
25287
25288  have built-in support for both PDF and DVI reverse search.
25289  This so-called 
25290 \emph on
25291 Sync\SpecialChar TeX
25292
25293 \emph default
25294  facility is basically the result of the integration of the PDFSync package
25295  to the pdftex program and its merge with the 
25296 \emph on
25297 scr-specials
25298 \emph default
25299  approach.
25300  You need at least \SpecialChar TeX
25301 Live 2008 or a recent Mik\SpecialChar TeX
25302  distribution in order to use
25303  it.
25304 \begin_inset Foot
25305 status collapsed
25306
25307 \begin_layout Plain Layout
25308 For some reason, Mik\SpecialChar TeX
25309  does not understand/obey the command \SpecialChar LyX
25310  inserts into
25311  the preamble when you check the "Enable Forward/Reverse Search" button
25312  in the toolbar and does not generate the necessary info.
25313 \end_layout
25314
25315 \begin_layout Plain Layout
25316 The generation of the required info can be forced by changing the converter
25317  "\SpecialChar LaTeX
25318  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
25319  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
25320  the -synctex=1 switch).
25321 \end_layout
25322
25323 \end_inset
25324
25325  Also note that only a few PDF viewers (Okular and Qpdfview on Unix, Skim
25326  on the Mac, SumatraPDF on Windows) already provide Sync\SpecialChar TeX
25327  support.
25328 \end_layout
25329
25330 \begin_layout Standard
25331 To enable Sync\SpecialChar TeX
25332  for DVI output, change the 
25333 \begin_inset Flex Noun
25334 status collapsed
25335
25336 \begin_layout Plain Layout
25337 La
25338 \family sans
25339 TeX
25340 \family default
25341  (plain) -> DVI
25342 \end_layout
25343
25344 \end_inset
25345
25346  or 
25347 \begin_inset Flex Noun
25348 status collapsed
25349
25350 \begin_layout Plain Layout
25351 La
25352 \family sans
25353 TeX
25354 \family default
25355  (plain) -> DraftDVI
25356 \end_layout
25357
25358 \end_inset
25359
25360  converter in 
25361 \begin_inset Flex Noun
25362 status collapsed
25363
25364 \begin_layout Plain Layout
25365 Preferences\SpecialChar menuseparator
25366 File Handling\SpecialChar menuseparator
25367 Converters
25368 \end_layout
25369
25370 \end_inset
25371
25372  to 
25373 \begin_inset Flex Code
25374 status collapsed
25375
25376 \begin_layout Plain Layout
25377 latex -synctex=1 $$i
25378 \end_layout
25379
25380 \end_inset
25381
25382 , and for PDF output, change the 
25383 \begin_inset Flex Noun
25384 status collapsed
25385
25386 \begin_layout Plain Layout
25387 La
25388 \family sans
25389 TeX
25390 \family default
25391  (pdflatex) -> PDF (pdflatex)
25392 \end_layout
25393
25394 \end_inset
25395
25396  or converter to 
25397 \begin_inset Flex Code
25398 status collapsed
25399
25400 \begin_layout Plain Layout
25401 pdflatex -synctex=1 $$i
25402 \end_layout
25403
25404 \end_inset
25405
25406 .
25407  Check the documentation of your viewer whether the viewer needs to be configure
25408 d for the use with Sync\SpecialChar TeX
25409 .
25410 \begin_inset Foot
25411 status collapsed
25412
25413 \begin_layout Plain Layout
25414 Note that the option 
25415 \begin_inset Flex Code
25416 status collapsed
25417
25418 \begin_layout Plain Layout
25419 -synctex=1
25420 \end_layout
25421
25422 \end_inset
25423
25424  option enables gzip compression.
25425  If your viewer does not support it, you should instead use 
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 .
25436 \end_layout
25437
25438 \end_inset
25439
25440
25441 \end_layout
25442
25443 \begin_layout Subsection
25444 Configuring and using specific viewers
25445 \begin_inset CommandInset label
25446 LatexCommand label
25447 name "subsec:configuring-viewers"
25448
25449 \end_inset
25450
25451
25452 \end_layout
25453
25454 \begin_layout Subsubsection*
25455 Xdvi (all platforms)
25456 \end_layout
25457
25458 \begin_layout Standard
25459 If you use 
25460 \begin_inset Flex Code
25461 status collapsed
25462
25463 \begin_layout Plain Layout
25464 xdvi
25465 \end_layout
25466
25467 \end_inset
25468
25469 , you don't need to do anything else for performing a reverse DVI search,
25470  as \SpecialChar LyX
25471  already provides the necessary hooks for automatically using the 
25472 \begin_inset Flex Code
25473 status collapsed
25474
25475 \begin_layout Plain Layout
25476 lyxclient
25477 \end_layout
25478
25479 \end_inset
25480
25481  program.
25482  Just setup your document as described above (reverse search is triggered
25483  by Ctrl-click or Alt-click on Mac OSX, respectively).
25484 \end_layout
25485
25486 \begin_layout Standard
25487 However, if for whatever reason you want to use the named pipe instead of
25488  the socket for communicating with \SpecialChar LyX
25489 , simply change the DVI viewer in 
25490 \begin_inset Flex Noun
25491 status collapsed
25492
25493 \begin_layout Plain Layout
25494 Preferences\SpecialChar menuseparator
25495 File Handling\SpecialChar menuseparator
25496 File formats
25497 \end_layout
25498
25499 \end_inset
25500
25501  to
25502 \begin_inset Foot
25503 status collapsed
25504
25505 \begin_layout Plain Layout
25506 On Mac OSX you have to use 
25507 \begin_inset Flex Code
25508 status collapsed
25509
25510 \begin_layout Plain Layout
25511 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
25512 \end_layout
25513
25514 \end_inset
25515
25516
25517 \end_layout
25518
25519 \end_inset
25520
25521  
25522 \begin_inset Flex Code
25523 status collapsed
25524
25525 \begin_layout Plain Layout
25526 xdvi -editor "lyxeditor.sh %f %l"
25527 \end_layout
25528
25529 \end_inset
25530
25531 , where 
25532 \begin_inset Flex Code
25533 status collapsed
25534
25535 \begin_layout Plain Layout
25536 lyxeditor.sh
25537 \end_layout
25538
25539 \end_inset
25540
25541  is a suitable script.
25542  For example, a minimal shell script is the following one:
25543 \end_layout
25544
25545 \begin_layout LyX-Code
25546 #!/bin/sh
25547 \begin_inset Newline newline
25548 \end_inset
25549
25550 LYXPIPE="/path/to/lyxpipe"
25551 \begin_inset Newline newline
25552 \end_inset
25553
25554 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
25555 \begin_inset Newline newline
25556 \end_inset
25557
25558 echo "$COMMAND" > "${LYXPIPE}".in || exit
25559 \begin_inset Newline newline
25560 \end_inset
25561
25562 read TMP < "${LYXPIPE}".out || exit
25563 \end_layout
25564
25565 \begin_layout Standard
25566 where 
25567 \begin_inset Flex Code
25568 status collapsed
25569
25570 \begin_layout Plain Layout
25571 /path/to/lyxpipe
25572 \end_layout
25573
25574 \end_inset
25575
25576  is the LyXServer pipe path specified in 
25577 \begin_inset Flex Noun
25578 status collapsed
25579
25580 \begin_layout Plain Layout
25581 Preferences\SpecialChar menuseparator
25582 Paths
25583 \end_layout
25584
25585 \end_inset
25586
25587 .
25588 \begin_inset Foot
25589 status collapsed
25590
25591 \begin_layout Plain Layout
25592 In the 
25593 \begin_inset Flex Code
25594 status collapsed
25595
25596 \begin_layout Plain Layout
25597 development/tools
25598 \end_layout
25599
25600 \end_inset
25601
25602  folder of a source distribution you can find a 
25603 \begin_inset Flex Code
25604 status collapsed
25605
25606 \begin_layout Plain Layout
25607 lyxeditor
25608 \end_layout
25609
25610 \end_inset
25611
25612  script which is able to locate the 
25613 \emph on
25614 lyxpipe
25615 \emph default
25616  based on your preferences.
25617 \end_layout
25618
25619 \end_inset
25620
25621
25622 \end_layout
25623
25624 \begin_layout Subsubsection*
25625 MacDviX (Mac OSX)
25626 \end_layout
25627
25628 \begin_layout Standard
25629 At the end of 
25630 \begin_inset Flex Code
25631 status collapsed
25632
25633 \begin_layout Plain Layout
25634 /Applications/MacDviX_Folder/calleditor.script
25635 \end_layout
25636
25637 \end_inset
25638
25639 , add the following lines:
25640 \end_layout
25641
25642 \begin_layout LyX-Code
25643 /Applications/LyX.app/Contents/MacOS/lyxeditor "$2" $1
25644 \begin_inset Newline newline
25645 \end_inset
25646
25647 exit 1
25648 \end_layout
25649
25650 \begin_layout Standard
25651 Modify the lines accordingly if you install \SpecialChar LyX
25652  somewhere else than in the
25653  Applications folder.
25654 \end_layout
25655
25656 \begin_layout Standard
25657 Reverse search is triggered by Alt-click (OPTION-click).
25658 \end_layout
25659
25660 \begin_layout Subsubsection*
25661 Skim (Mac OSX)
25662 \end_layout
25663
25664 \begin_layout Standard
25665 Enter 
25666 \begin_inset Flex Code
25667 status collapsed
25668
25669 \begin_layout Plain Layout
25670 open -a Skim.app $$i
25671 \end_layout
25672
25673 \end_inset
25674
25675  to the viewer setting in 
25676 \begin_inset Flex Noun
25677 status collapsed
25678
25679 \begin_layout Plain Layout
25680 Preferences\SpecialChar menuseparator
25681 File Handling\SpecialChar menuseparator
25682 File formats\SpecialChar menuseparator
25683 PDF (pdflatex)
25684 \end_layout
25685
25686 \end_inset
25687
25688 , and then in 
25689 \begin_inset Flex Noun
25690 status collapsed
25691
25692 \begin_layout Plain Layout
25693 Skim\SpecialChar menuseparator
25694 Preferences\SpecialChar menuseparator
25695 Sync
25696 \end_layout
25697
25698 \end_inset
25699
25700  choose 
25701 \begin_inset Flex Noun
25702 status collapsed
25703
25704 \begin_layout Plain Layout
25705 custom
25706 \end_layout
25707
25708 \end_inset
25709
25710  preset and enter command 
25711 \begin_inset Flex Noun
25712 status collapsed
25713
25714 \begin_layout Plain Layout
25715 /Applications/\SpecialChar LyX
25716 .app/Contents/MacOS/lyxeditor
25717 \end_layout
25718
25719 \end_inset
25720
25721 .
25722 \end_layout
25723
25724 \begin_layout Standard
25725 Reverse search is triggered by COMMAND-SHIFT-click
25726 \end_layout
25727
25728 \begin_layout Subsubsection*
25729 Okular (KDE)
25730 \end_layout
25731
25732 \begin_layout Standard
25733 Go to 
25734 \begin_inset Flex Noun
25735 status collapsed
25736
25737 \begin_layout Plain Layout
25738 Settings\SpecialChar menuseparator
25739 Configure Okular\SpecialChar menuseparator
25740 Editor
25741 \end_layout
25742
25743 \end_inset
25744
25745 , select 
25746 \begin_inset Quotes eld
25747 \end_inset
25748
25749 Custom Text Editor
25750 \begin_inset Quotes erd
25751 \end_inset
25752
25753  and add the command 
25754 \begin_inset Flex Code
25755 status collapsed
25756
25757 \begin_layout Plain Layout
25758 lyxclient -g %f %l
25759 \end_layout
25760
25761 \end_inset
25762
25763 .
25764 \end_layout
25765
25766 \begin_layout Standard
25767 Reverse search is triggered by SHIFT-click.
25768 \end_layout
25769
25770 \begin_layout Subsubsection*
25771 Qpdfview (Unix)
25772 \end_layout
25773
25774 \begin_layout Standard
25775 Qpdfview supports Sync\SpecialChar TeX
25776  since version 0.3.5.
25777  Go to 
25778 \begin_inset Flex Noun
25779 status collapsed
25780
25781 \begin_layout Plain Layout
25782 Edit\SpecialChar menuseparator
25783 Settings\SpecialChar menuseparator
25784 Behavior
25785 \end_layout
25786
25787 \end_inset
25788
25789 , click on the input field of the 
25790 \begin_inset Quotes eld
25791 \end_inset
25792
25793 Source editor
25794 \begin_inset Quotes erd
25795 \end_inset
25796
25797  item and add the command 
25798 \begin_inset Flex Code
25799 status collapsed
25800
25801 \begin_layout Plain Layout
25802 lyxclient -g %1 %2
25803 \end_layout
25804
25805 \end_inset
25806
25807 .
25808 \end_layout
25809
25810 \begin_layout Standard
25811 Reverse search is triggered by double-click
25812 \change_inserted -851615295 1468920502
25813  or, in more recent versions, by context menu
25814 \change_unchanged
25815 .
25816 \end_layout
25817
25818 \begin_layout Subsubsection*
25819 YAP (Windows)
25820 \end_layout
25821
25822 \begin_layout Standard
25823 Launch yap, choose its 
25824 \begin_inset Flex Noun
25825 status collapsed
25826
25827 \begin_layout Plain Layout
25828 View\SpecialChar menuseparator
25829 Options
25830 \end_layout
25831
25832 \end_inset
25833
25834  menu and select the 
25835 \begin_inset Quotes eld
25836 \end_inset
25837
25838 Inverse DVI Search
25839 \begin_inset Quotes erd
25840 \end_inset
25841
25842  tab.
25843  Click on the 
25844 \begin_inset Quotes eld
25845 \end_inset
25846
25847 New\SpecialChar ldots
25848
25849 \begin_inset Quotes erd
25850 \end_inset
25851
25852  button and, in the window that opens, enter 
25853 \begin_inset Quotes eld
25854 \end_inset
25855
25856 \SpecialChar LyX
25857  Editor
25858 \begin_inset Quotes erd
25859 \end_inset
25860
25861  (or any other name you like) in the 
25862 \begin_inset Quotes eld
25863 \end_inset
25864
25865 Name:
25866 \begin_inset Quotes erd
25867 \end_inset
25868
25869  field.
25870  Now click on the button labeled 
25871 \begin_inset Quotes eld
25872 \end_inset
25873
25874 \SpecialChar ldots
25875
25876 \begin_inset Quotes erd
25877 \end_inset
25878
25879  to open a file dialog and navigate to the directory containing the batch
25880  file 
25881 \begin_inset Flex Code
25882 status collapsed
25883
25884 \begin_layout Plain Layout
25885 lyxeditor.bat
25886 \end_layout
25887
25888 \end_inset
25889
25890  (see below).
25891  Select 
25892 \begin_inset Flex Code
25893 status collapsed
25894
25895 \begin_layout Plain Layout
25896 lyxeditor.bat
25897 \end_layout
25898
25899 \end_inset
25900
25901  and then specify the program arguments as 
25902 \begin_inset Flex Code
25903 status collapsed
25904
25905 \begin_layout Plain Layout
25906 %f %l
25907 \end_layout
25908
25909 \end_inset
25910
25911 .
25912  The 
25913 \begin_inset Flex Code
25914 status collapsed
25915
25916 \begin_layout Plain Layout
25917 lyxeditor.bat
25918 \end_layout
25919
25920 \end_inset
25921
25922  wrapper is used for communicating with \SpecialChar LyX
25923  through the 
25924 \emph on
25925 lyxpipe
25926 \emph default
25927  and is as follows:
25928 \end_layout
25929
25930 \begin_layout LyX-Code
25931 @echo off
25932 \begin_inset Newline newline
25933 \end_inset
25934
25935 echo LYXCMD:revdvi:server-goto-file-row:%1 %2> 
25936 \backslash
25937
25938 \backslash
25939 .
25940 \backslash
25941 pipe
25942 \backslash
25943 lyxpipe.in
25944 \begin_inset Newline newline
25945 \end_inset
25946
25947 type 
25948 \backslash
25949
25950 \backslash
25951 .
25952 \backslash
25953 pipe
25954 \backslash
25955 lyxpipe.out
25956 \end_layout
25957
25958 \begin_layout Standard
25959 Make sure that the \SpecialChar LyX
25960 Server pipe path you specified in \SpecialChar LyX
25961  is 
25962 \begin_inset Flex Code
25963 status collapsed
25964
25965 \begin_layout Plain Layout
25966
25967 \backslash
25968
25969 \backslash
25970 .
25971 \backslash
25972 pipe
25973 \backslash
25974 lyxpipe
25975 \end_layout
25976
25977 \end_inset
25978
25979 , otherwise change the 
25980 \begin_inset Flex Code
25981 status collapsed
25982
25983 \begin_layout Plain Layout
25984 lyxeditor.bat
25985 \end_layout
25986
25987 \end_inset
25988
25989  wrapper accordingly.
25990 \end_layout
25991
25992 \begin_layout Standard
25993 In yap, reverse search is triggered by double-click.
25994 \end_layout
25995
25996 \begin_layout Subsubsection*
25997 SumatraPDF (Windows)
25998 \end_layout
25999
26000 \begin_layout Standard
26001 In order to use SumatraPDF for inverse search, enter 
26002 \begin_inset Flex Code
26003 status collapsed
26004
26005 \begin_layout Plain Layout
26006 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
26007 \end_layout
26008
26009 \end_inset
26010
26011  in the viewer setting in 
26012 \begin_inset Flex Noun
26013 status collapsed
26014
26015 \begin_layout Plain Layout
26016 Preferences\SpecialChar menuseparator
26017 File Handling\SpecialChar menuseparator
26018 File formats\SpecialChar menuseparator
26019 PDF (pdflatex)
26020 \end_layout
26021
26022 \end_inset
26023
26024 , where 
26025 \begin_inset Flex Code
26026 status collapsed
26027
26028 \begin_layout Plain Layout
26029 lyxeditor.bat
26030 \end_layout
26031
26032 \end_inset
26033
26034  is the previous wrapper.
26035  If SumatraPDF.exe is not in your command PATH, use its full file name.
26036 \end_layout
26037
26038 \begin_layout Standard
26039 Reverse search is triggered by double-click.
26040 \end_layout
26041
26042 \begin_layout Subsubsection*
26043 YAP (Cygwin)
26044 \end_layout
26045
26046 \begin_layout Standard
26047 First of all, make sure that yap is your default DVI viewer in the Windows
26048  environment, then launch it, choose its 
26049 \begin_inset Flex Noun
26050 status collapsed
26051
26052 \begin_layout Plain Layout
26053 View\SpecialChar menuseparator
26054 Options
26055 \end_layout
26056
26057 \end_inset
26058
26059  menu and select the 
26060 \begin_inset Quotes eld
26061 \end_inset
26062
26063 Inverse DVI Search
26064 \begin_inset Quotes erd
26065 \end_inset
26066
26067  tab.
26068  Click on the 
26069 \begin_inset Quotes eld
26070 \end_inset
26071
26072 New\SpecialChar ldots
26073
26074 \begin_inset Quotes erd
26075 \end_inset
26076
26077  button and, in the window that opens, enter 
26078 \begin_inset Quotes eld
26079 \end_inset
26080
26081 \SpecialChar LyX
26082  Editor
26083 \begin_inset Quotes erd
26084 \end_inset
26085
26086  (or any other name you like) in the 
26087 \begin_inset Quotes eld
26088 \end_inset
26089
26090 Name:
26091 \begin_inset Quotes erd
26092 \end_inset
26093
26094  field.
26095  Now click on the button labeled 
26096 \begin_inset Quotes eld
26097 \end_inset
26098
26099 \SpecialChar ldots
26100
26101 \begin_inset Quotes erd
26102 \end_inset
26103
26104  to open a file dialog and navigate to the directory containing the 
26105 \begin_inset Flex Code
26106 status collapsed
26107
26108 \begin_layout Plain Layout
26109 lyxeditor.exe
26110 \end_layout
26111
26112 \end_inset
26113
26114  program (which is installed by default on Cygwin along with the \SpecialChar LyX
26115  executable).
26116  Select 
26117 \begin_inset Flex Code
26118 status collapsed
26119
26120 \begin_layout Plain Layout
26121 lyxeditor.exe
26122 \end_layout
26123
26124 \end_inset
26125
26126  and then specify the program arguments as 
26127 \begin_inset Flex Code
26128 status collapsed
26129
26130 \begin_layout Plain Layout
26131 -g %f %l
26132 \end_layout
26133
26134 \end_inset
26135
26136 .
26137  In this way, you will be using the 
26138 \emph on
26139 lyxsocket
26140 \emph default
26141  for communicating with \SpecialChar LyX
26142 .
26143  If, for whatever reason, you want to use the 
26144 \emph on
26145 lyxpipe
26146 \emph default
26147 , omit the 
26148 \begin_inset Flex Code
26149 status collapsed
26150
26151 \begin_layout Plain Layout
26152 -g
26153 \end_layout
26154
26155 \end_inset
26156
26157  option and be sure to specify the \SpecialChar LyX
26158 Server pipe path in the \SpecialChar LyX
26159  preferences.
26160 \end_layout
26161
26162 \begin_layout Standard
26163 In yap, reverse search is triggered by double-click.
26164 \end_layout
26165
26166 \begin_layout Subsubsection*
26167 SumatraPDF (Cygwin)
26168 \end_layout
26169
26170 \begin_layout Standard
26171 In order to use SumatraPDF for inverse search, enter 
26172 \begin_inset Flex Code
26173 status collapsed
26174
26175 \begin_layout Plain Layout
26176 SumatraPDF -inverse-search "lyxeditor -g %f %l"
26177 \end_layout
26178
26179 \end_inset
26180
26181  in the viewer setting in 
26182 \begin_inset Flex Noun
26183 status collapsed
26184
26185 \begin_layout Plain Layout
26186 Preferences\SpecialChar menuseparator
26187 File Handling\SpecialChar menuseparator
26188 File formats\SpecialChar menuseparator
26189 PDF (pdflatex)
26190 \end_layout
26191
26192 \end_inset
26193
26194 .
26195  If SumatraPDF.exe is not in your command PATH, use its full posix path.
26196  The 
26197 \begin_inset Flex Code
26198 status collapsed
26199
26200 \begin_layout Plain Layout
26201 -g
26202 \end_layout
26203
26204 \end_inset
26205
26206  enables communication via the 
26207 \emph on
26208 lyxsocket
26209 \emph default
26210 .
26211  Again, omit the 
26212 \begin_inset Flex Code
26213 status collapsed
26214
26215 \begin_layout Plain Layout
26216 -g
26217 \end_layout
26218
26219 \end_inset
26220
26221  option if you want to use the 
26222 \emph on
26223 lyxpipe
26224 \emph default
26225 , and be sure to specify the \SpecialChar LyX
26226 Server pipe path in the \SpecialChar LyX
26227  preferences.
26228 \end_layout
26229
26230 \begin_layout Standard
26231 Reverse search is triggered by double-click.
26232 \end_layout
26233
26234 \begin_layout Section
26235 Forward search
26236 \end_layout
26237
26238 \begin_layout Standard
26239 Forward search is, as the name implies, in a sense the 
26240 \begin_inset Quotes eld
26241 \end_inset
26242
26243 opposite
26244 \begin_inset Quotes erd
26245 \end_inset
26246
26247  of reverse search.
26248  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
26249 .
26250  If forward search is set up (as described in what follows), you can put
26251  the cursor anywhere in your \SpecialChar LyX
26252  document, and hit 
26253 \begin_inset Flex Noun
26254 status collapsed
26255
26256 \begin_layout Plain Layout
26257 Navigate\SpecialChar menuseparator
26258 Forward search
26259 \end_layout
26260
26261 \end_inset
26262
26263  (or select 
26264 \begin_inset Flex Noun
26265 status collapsed
26266
26267 \begin_layout Plain Layout
26268 Forward search
26269 \end_layout
26270
26271 \end_inset
26272
26273  in the context menu via right mouse click), and then the viewer will jump
26274  to that position as well.
26275  This implies, of course, that your viewer supports this function.
26276 \end_layout
26277
26278 \begin_layout Standard
26279 To make forward search possible, you first need to provide the generated
26280  output PDF/DVI file with additional information about the \SpecialChar TeX
26281  sources.
26282  This can be done via the methods described in the section 
26283 \begin_inset CommandInset ref
26284 LatexCommand ref
26285 reference "subsec:rev-search"
26286
26287 \end_inset
26288
26289 .
26290 \end_layout
26291
26292 \begin_layout Standard
26293 Additionally, you need to configure \SpecialChar LyX
26294  for using your viewers in 
26295 \begin_inset Flex Noun
26296 status collapsed
26297
26298 \begin_layout Plain Layout
26299 Tools\SpecialChar menuseparator
26300 Preferences\SpecialChar menuseparator
26301 Output\SpecialChar menuseparator
26302 General
26303 \end_layout
26304
26305 \end_inset
26306
26307 .
26308  We provide a range of tested configurations for some viewers, which you
26309  can select from the drop down list.
26310  If none of these configurations suits you, you have to find out and enter
26311  a suitable configuration yourself.
26312  The definition syntax uses the following placeholders:
26313 \end_layout
26314
26315 \begin_layout Itemize
26316 \noindent
26317 \begin_inset Flex Code
26318 status collapsed
26319
26320 \begin_layout Plain Layout
26321 $$n
26322 \end_layout
26323
26324 \end_inset
26325
26326 : row number
26327 \end_layout
26328
26329 \begin_layout Itemize
26330 \noindent
26331 \begin_inset Flex Code
26332 status collapsed
26333
26334 \begin_layout Plain Layout
26335 $$t
26336 \end_layout
26337
26338 \end_inset
26339
26340 : name of the (temporary) exported .tex file (without path)
26341 \end_layout
26342
26343 \begin_layout Itemize
26344 \noindent
26345 \begin_inset Flex Code
26346 status collapsed
26347
26348 \begin_layout Plain Layout
26349 $$f
26350 \end_layout
26351
26352 \end_inset
26353
26354 : name of the (temporary) exported .tex file (including path)
26355 \end_layout
26356
26357 \begin_layout Itemize
26358 \noindent
26359 \begin_inset Flex Code
26360 status collapsed
26361
26362 \begin_layout Plain Layout
26363 $$o
26364 \end_layout
26365
26366 \end_inset
26367
26368 : name of the exported output file (either dvi or pdf, depending on which
26369  one exists in the temporary directory)
26370 \end_layout
26371
26372 \begin_layout Standard
26373 Note that only some of the viewers provide full forward search functionality,
26374  among them yap, xdvi, okular
26375 \begin_inset Foot
26376 status collapsed
26377
26378 \begin_layout Plain Layout
26379 You might want to set 
26380 \begin_inset Flex Code
26381 status collapsed
26382
26383 \begin_layout Plain Layout
26384 okular –unique
26385 \end_layout
26386
26387 \end_inset
26388
26389  in 
26390 \begin_inset Flex Noun
26391 status collapsed
26392
26393 \begin_layout Plain Layout
26394 Tools\SpecialChar menuseparator
26395 Preferences\SpecialChar menuseparator
26396 File Handling\SpecialChar menuseparator
26397 File
26398 \begin_inset space ~
26399 \end_inset
26400
26401 Formats
26402 \end_layout
26403
26404 \end_inset
26405
26406
26407 \end_layout
26408
26409 \end_inset
26410
26411 , qpdfview and SumatraPDF
26412 \begin_inset Foot
26413 status collapsed
26414
26415 \begin_layout Plain Layout
26416 SumatraPDF can also use DDE commands through the external program CMCDDE
26417  — downloadable from 
26418 \begin_inset CommandInset href
26419 LatexCommand href
26420 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
26421
26422 \end_inset
26423
26424
26425 \end_layout
26426
26427 \end_inset
26428
26429 .
26430  While many of the widespread PDF viewers (most notably Adobe Reader) do
26431  not support forward search at all, some other viewers – e.
26432 \begin_inset space \thinspace{}
26433 \end_inset
26434
26435 g.
26436  evince and xpdf – allow at least to reload the document and jump to a specific
26437  page of the file, so you can at least navigate 
26438 \begin_inset Quotes eld
26439 \end_inset
26440
26441 near
26442 \begin_inset Quotes erd
26443 \end_inset
26444
26445 .
26446  This latter functionality is provided by an external call of synctex (see
26447  the predefined example configurations).
26448  
26449 \end_layout
26450
26451 \begin_layout Standard
26452 Forward search works both with DVI and PDF output.
26453  \SpecialChar LyX
26454  simply checks which preview format you have used before (i.
26455 \begin_inset space \thinspace{}
26456 \end_inset
26457
26458 e., which format is already there in the temporary directory) and chooses
26459  the appropriate configuration for the respective format.
26460 \end_layout
26461
26462 \end_body
26463 \end_document