]> git.lyx.org Git - lyx.git/blob - lib/doc/Additional.lyx
Customization.lyx: fixes and updates from Jean-Pierre
[lyx.git] / lib / doc / Additional.lyx
1 #LyX 2.2 created this file. For more info see http://www.lyx.org/
2 \lyxformat 504
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 \graphics default
56 \default_output_format pdf2
57 \output_sync 0
58 \bibtex_command default
59 \index_command default
60 \paperfontsize 12
61 \spacing single
62 \use_hyperref true
63 \pdf_title "LyX's Additional Features manual"
64 \pdf_author "LyX Team"
65 \pdf_subject "LyX's additional features documentation"
66 \pdf_keywords "LyX, Documentation, Additional"
67 \pdf_bookmarks true
68 \pdf_bookmarksnumbered true
69 \pdf_bookmarksopen false
70 \pdf_bookmarksopenlevel 1
71 \pdf_breaklinks false
72 \pdf_pdfborder false
73 \pdf_colorlinks true
74 \pdf_backref false
75 \pdf_pdfusetitle false
76 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
77 \papersize a4paper
78 \use_geometry false
79 \use_package amsmath 1
80 \use_package amssymb 1
81 \use_package cancel 0
82 \use_package esint 0
83 \use_package mathdots 1
84 \use_package mathtools 0
85 \use_package mhchem 1
86 \use_package stackrel 0
87 \use_package stmaryrd 0
88 \use_package undertilde 0
89 \cite_engine basic
90 \cite_engine_type default
91 \biblio_style plain
92 \use_bibtopic false
93 \use_indices false
94 \paperorientation portrait
95 \suppress_date false
96 \justification true
97 \use_refstyle 0
98 \notefontcolor #0000ff
99 \index Index
100 \shortcut idx
101 \color #008000
102 \end_index
103 \secnumdepth 3
104 \tocdepth 3
105 \paragraph_separation indent
106 \paragraph_indentation default
107 \quotes_language english
108 \papercolumns 1
109 \papersides 2
110 \paperpagestyle headings
111 \tracking_changes false
112 \output_changes false
113 \html_math_output 0
114 \html_css_as_file 0
115 \html_be_strict true
116 \end_header
117
118 \begin_body
119
120 \begin_layout Title
121 Additional \SpecialChar LyX
122  Features
123 \end_layout
124
125 \begin_layout Subtitle
126 Version 2.2.x
127 \end_layout
128
129 \begin_layout Author
130 by the \SpecialChar LyX
131  Team
132 \begin_inset Foot
133 status collapsed
134
135 \begin_layout Plain Layout
136 \noindent
137 Principal maintainer of this file is
138 \noun on
139  Richard Heck
140 \noun default
141 .
142  If you have comments or error corrections, please send them to the \SpecialChar LyX
143  Documentati
144 on mailing list, 
145 \begin_inset Flex Code
146 status collapsed
147
148 \begin_layout Plain Layout
149 \noindent
150 <lyx-docs@lists.lyx.org>
151 \end_layout
152
153 \end_inset
154
155 .
156 \end_layout
157
158 \end_inset
159
160
161 \end_layout
162
163 \begin_layout Standard
164 \begin_inset CommandInset toc
165 LatexCommand tableofcontents
166
167 \end_inset
168
169
170 \end_layout
171
172 \begin_layout Chapter
173 Introduction
174 \end_layout
175
176 \begin_layout Standard
177 This manual is essentially Part II of the 
178 \emph on
179 User's Guide\SpecialChar endofsentence
180
181 \emph default
182  The reason for separating the two documents is simple: the 
183 \emph on
184 User's Guide
185 \emph default
186  is already quite lengthy, and it contains information on all of the basic
187  features one needs to know in order to prepare most documents.
188  However, the \SpecialChar LyX
189  Team has worked to make \SpecialChar LyX
190  extensible through various configuration
191  files and external packages.
192  That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
193  package, you can
194  create a layout file (or module) for it without having to alter \SpecialChar LyX
195  itself.
196  We've already had contributions of several new features this way, and some
197  of them are documented here.
198  There are also some more `advanced' features, such as how to control the
199  presentation of bibliographies and how to work with multi-part documents,
200  that are not covered in the 
201 \emph on
202 User's Guide
203 \emph default
204  and are discussed here.
205 \end_layout
206
207 \begin_layout Standard
208 This manual also documents some special features, like fax support, version
209  control, and SGML support, which require additional software to work properly.
210  There is also a chapter on \SpecialChar LyX
211 's support for HTML.
212  And lastly, there's a chapter of \SpecialChar LaTeX
213  tools and tips, things you can use to
214  spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
215 .
216  After all, \SpecialChar LyX
217  
218 \emph on
219 is
220 \emph default
221  only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
222  features.
223 \end_layout
224
225 \begin_layout Standard
226 If you haven't read the 
227 \emph on
228 Introduction
229 \emph default
230  yet, you are definitely in the wrong manual.
231  The 
232 \emph on
233 Introduction
234 \emph default
235  is the first place to go, since it describes the notation and format of
236  all of the manuals.
237  You should also be thoroughly familiar with the 
238 \emph on
239 User's Guide
240 \emph default
241  and all of the basic features of \SpecialChar LyX
242  before attempting to read this one.
243 \end_layout
244
245 \begin_layout Standard
246 Since many of the topics in this manual depend heavily on \SpecialChar LyX
247 's interaction
248  with \SpecialChar LaTeX
249 , this first chapter covers the inner workings of \SpecialChar LyX
250  and how to direct
251  \SpecialChar LyX
252  to generate exactly the \SpecialChar LaTeX
253  code you want.
254  It is obviously for more seasoned \SpecialChar LyX
255  users.
256 \end_layout
257
258 \begin_layout Chapter
259 \SpecialChar LyX
260  and \SpecialChar LaTeX
261
262 \end_layout
263
264 \begin_layout Section
265 How \SpecialChar LyX
266  Uses \SpecialChar LaTeX
267
268 \end_layout
269
270 \begin_layout Standard
271 This chapter is for both \SpecialChar TeX
272 -nicians and the \SpecialChar LaTeX
273 -curious.
274  In it, we'll explain how \SpecialChar LyX
275  and \SpecialChar LaTeX
276  work together to produce printable output.
277  This is the only place in any of the manuals where we assume you know something
278  about \SpecialChar LaTeX
279 .
280 \end_layout
281
282 \begin_layout Standard
283 At one time, \SpecialChar LyX
284  was called a 
285 \begin_inset Quotes eld
286 \end_inset
287
288 WYSIWYM frontend to \SpecialChar LaTeX
289 ,
290 \begin_inset Quotes erd
291 \end_inset
292
293  but that's no longer true.
294  There are frontends to \SpecialChar LaTeX
295  out there.
296 \begin_inset Foot
297 status collapsed
298
299 \begin_layout Plain Layout
300 Some familar ones are \SpecialChar TeX
301 maker and kile, on Linux, and \SpecialChar TeX
302 shop, OSX.
303  There are also the \SpecialChar LaTeX
304  modes for vi and emacs, of course.
305 \end_layout
306
307 \end_inset
308
309  These are basically text editors with the ability to run \SpecialChar LaTeX
310  and mark any
311  errors in the file you're editing.
312  Although \SpecialChar LyX
313  
314 \emph on
315 is
316 \emph default
317  an editor, and it 
318 \emph on
319 does
320 \emph default
321  run \SpecialChar LaTeX
322 , and it also indicates errors in the file, it also does much, much
323  more.
324  For one thing, you don't need to know \SpecialChar LaTeX
325  to use \SpecialChar LyX
326  effectively.
327  And \SpecialChar LyX
328  has added its own extensions to \SpecialChar LaTeX
329 .
330  Try the following sometime: select 
331 \begin_inset Flex Noun
332 status collapsed
333
334 \begin_layout Plain Layout
335 Export\SpecialChar menuseparator
336 \SpecialChar LaTeX
337
338 \end_layout
339
340 \end_inset
341
342  from the 
343 \begin_inset Flex Noun
344 status collapsed
345
346 \begin_layout Plain Layout
347 File
348 \end_layout
349
350 \end_inset
351
352  menu (or 
353 \begin_inset Flex Noun
354 status collapsed
355
356 \begin_layout Plain Layout
357 View\SpecialChar menuseparator
358 Source
359 \begin_inset space ~
360 \end_inset
361
362 Pane
363 \end_layout
364
365 \end_inset
366
367 ), then look at the preamble of the resulting 
368 \begin_inset Flex Code
369 status collapsed
370
371 \begin_layout Plain Layout
372 .tex
373 \end_layout
374
375 \end_inset
376
377  file.
378  You'll notice a variety of new macros defined specifically by \SpecialChar LyX
379 .
380  These macros are defined automatically, according to the features you use
381  in the document.
382 \end_layout
383
384 \begin_layout Standard
385 There are several commands that automatically invoke \SpecialChar LaTeX
386 .
387  They are:
388 \end_layout
389
390 \begin_layout Itemize
391 \begin_inset Flex Noun
392 status collapsed
393
394 \begin_layout Plain Layout
395 Document\SpecialChar menuseparator
396 View
397 \end_layout
398
399 \end_inset
400
401
402 \end_layout
403
404 \begin_layout Itemize
405 \begin_inset Flex Noun
406 status collapsed
407
408 \begin_layout Plain Layout
409 Document\SpecialChar menuseparator
410 Update
411 \end_layout
412
413 \end_inset
414
415
416 \end_layout
417
418 \begin_layout Itemize
419 \begin_inset Flex Noun
420 status collapsed
421
422 \begin_layout Plain Layout
423 File\SpecialChar menuseparator
424 Print
425 \end_layout
426
427 \end_inset
428
429
430 \end_layout
431
432 \begin_layout Itemize
433 \begin_inset Flex Noun
434 status collapsed
435
436 \begin_layout Plain Layout
437 File\SpecialChar menuseparator
438 Fax
439 \end_layout
440
441 \end_inset
442
443
444 \end_layout
445
446 \begin_layout Standard
447 They will only invoke \SpecialChar LaTeX
448  if the file has changed since the last time \SpecialChar LaTeX
449  was
450  run.
451  
452 \end_layout
453
454 \begin_layout Standard
455 When \SpecialChar LyX
456  runs \SpecialChar LaTeX
457  on the file you're editing, it performs these steps:
458 \end_layout
459
460 \begin_layout Enumerate
461 Convert the document to \SpecialChar LaTeX
462  and save to a file with the extension 
463 \begin_inset Flex Code
464 status collapsed
465
466 \begin_layout Plain Layout
467 .tex
468 \end_layout
469
470 \end_inset
471
472  in place of 
473 \begin_inset Flex Code
474 status collapsed
475
476 \begin_layout Plain Layout
477 .lyx
478 \end_layout
479
480 \end_inset
481
482 .
483 \end_layout
484
485 \begin_layout Enumerate
486 Run \SpecialChar LaTeX
487  on the 
488 \begin_inset Flex Code
489 status collapsed
490
491 \begin_layout Plain Layout
492 .tex
493 \end_layout
494
495 \end_inset
496
497  file (maybe several times), and run any other commands (such as 
498 \begin_inset Flex Code
499 status collapsed
500
501 \begin_layout Plain Layout
502 bibtex
503 \end_layout
504
505 \end_inset
506
507  or 
508 \begin_inset Flex Code
509 status collapsed
510
511 \begin_layout Plain Layout
512 makeindex
513 \end_layout
514
515 \end_inset
516
517 ) needed to compile the \SpecialChar LaTeX
518  file.
519 \end_layout
520
521 \begin_layout Enumerate
522 If there are any errors, show the error log.
523 \end_layout
524
525 \begin_layout Standard
526 If you have run \SpecialChar LaTeX
527  using 
528 \begin_inset Flex Noun
529 status collapsed
530
531 \begin_layout Plain Layout
532 View
533 \bar under
534 \SpecialChar menuseparator
535
536 \bar default
537 DVI
538 \end_layout
539
540 \end_inset
541
542 , \SpecialChar LyX
543  then runs a DVI viewer to display the DVI-file.
544  If you have used 
545 \begin_inset Flex Noun
546 status collapsed
547
548 \begin_layout Plain Layout
549 View
550 \bar under
551 \SpecialChar menuseparator
552
553 \bar default
554 PostScript
555 \end_layout
556
557 \end_inset
558
559 , \SpecialChar LyX
560  performs further steps:
561 \end_layout
562
563 \begin_layout Itemize
564 Run 
565 \begin_inset Flex Code
566 status collapsed
567
568 \begin_layout Plain Layout
569 dvips
570 \end_layout
571
572 \end_inset
573
574  to convert the DVI file to PostScript.
575 \end_layout
576
577 \begin_layout Itemize
578 Run a PostScript viewer, such as 
579 \begin_inset Flex Code
580 status collapsed
581
582 \begin_layout Plain Layout
583 ghostview
584 \end_layout
585
586 \end_inset
587
588 , to display the PostScript file.
589 \end_layout
590
591 \begin_layout Standard
592 \SpecialChar LyX
593  does similar things when viewing, or exporting, other formats.
594 \end_layout
595
596 \begin_layout Section
597 Translating \SpecialChar LaTeX
598  files into \SpecialChar LyX
599
600 \end_layout
601
602 \begin_layout Standard
603 You can import a \SpecialChar LaTeX
604  file into \SpecialChar LyX
605  by using the 
606 \begin_inset Flex Noun
607 status collapsed
608
609 \begin_layout Plain Layout
610 File\SpecialChar menuseparator
611 Import\SpecialChar menuseparator
612 \SpecialChar LaTeX
613
614 \end_layout
615
616 \end_inset
617
618  command in \SpecialChar LyX
619 .
620  This will call a program named 
621 \begin_inset Flex Code
622 status collapsed
623
624 \begin_layout Plain Layout
625 tex2lyx
626 \end_layout
627
628 \end_inset
629
630  which will create a file 
631 \begin_inset Flex Code
632 status collapsed
633
634 \begin_layout Plain Layout
635 foo.lyx
636 \end_layout
637
638 \end_inset
639
640  from the file 
641 \begin_inset Flex Code
642 status collapsed
643
644 \begin_layout Plain Layout
645 foo.tex
646 \end_layout
647
648 \end_inset
649
650 .
651  \SpecialChar LyX
652  will then open that file.
653 \begin_inset Foot
654 status collapsed
655
656 \begin_layout Plain Layout
657 \begin_inset Flex Code
658 status collapsed
659
660 \begin_layout Plain Layout
661 tex2lyx
662 \end_layout
663
664 \end_inset
665
666  can also be run from the command line, of course.
667 \end_layout
668
669 \end_inset
670
671
672 \end_layout
673
674 \begin_layout Standard
675 \begin_inset Flex Code
676 status collapsed
677
678 \begin_layout Plain Layout
679 tex2lyx
680 \end_layout
681
682 \end_inset
683
684  will translate most legal \SpecialChar LaTeX
685 , but not everything.
686  It will put things it doesn't understand into \SpecialChar TeX
687  code, so after translating
688  a file with 
689 \begin_inset Flex Code
690 status collapsed
691
692 \begin_layout Plain Layout
693 tex2lyx
694 \end_layout
695
696 \end_inset
697
698 , you can look for \SpecialChar TeX
699  code and hand-edit it until it looks right.
700 \end_layout
701
702 \begin_layout Standard
703 If you don't know what \SpecialChar TeX
704  code is, read the next section.
705 \end_layout
706
707 \begin_layout Section
708 \begin_inset CommandInset label
709 LatexCommand label
710 name "sec:Inserting-TeX-Code"
711
712 \end_inset
713
714 Inserting \SpecialChar TeX
715  Code into \SpecialChar LyX
716  Documents 
717 \end_layout
718
719 \begin_layout Standard
720 Anything you can do in \SpecialChar LaTeX
721  you can do in \SpecialChar LyX
722 , for a very simple reason: You can
723  always insert \SpecialChar TeX
724  code into any \SpecialChar LyX
725  document.
726  \SpecialChar LyX
727  cannot, and will never be able to, display every possible \SpecialChar LaTeX
728  construct.
729  If ever you need to insert \SpecialChar LaTeX
730  commands into your \SpecialChar LyX
731  document, you can use the
732  
733 \begin_inset Flex Code
734 status collapsed
735
736 \begin_layout Plain Layout
737 \SpecialChar TeX
738  Code
739 \end_layout
740
741 \end_inset
742
743  box, which you can insert into your document with 
744 \begin_inset Flex Noun
745 status collapsed
746
747 \begin_layout Plain Layout
748 Insert\SpecialChar menuseparator
749
750 \family sans
751 TeX
752 \family default
753  Code
754 \end_layout
755
756 \end_inset
757
758  or the keyboard shortcut 
759 \begin_inset Info
760 type  "shortcut"
761 arg   "ert-insert"
762 \end_inset
763
764 .
765 \end_layout
766
767 \begin_layout Standard
768 Here's an example of inserting \SpecialChar LaTeX
769  commands in a \SpecialChar LyX
770  document.
771  The code looks like this:
772 \end_layout
773
774 \begin_layout LyX-Code
775
776 \backslash
777 begin{tabular}{ll}
778 \begin_inset Newline newline
779 \end_inset
780
781
782 \backslash
783 begin{minipage}{5cm}
784 \begin_inset Newline newline
785 \end_inset
786
787 This is an example of a minipage environment.
788  You 
789 \begin_inset Newline newline
790 \end_inset
791
792 can put nearly everything in it, even (non-floating) 
793 \begin_inset Newline newline
794 \end_inset
795
796 figures and tables.
797  
798 \begin_inset Newline newline
799 \end_inset
800
801
802 \backslash
803 end{minipage}
804 \begin_inset Newline newline
805 \end_inset
806
807 &
808 \begin_inset Newline newline
809 \end_inset
810
811
812 \backslash
813 begin{minipage}{5cm}
814 \begin_inset Newline newline
815 \end_inset
816
817
818 \backslash
819 begin{verbatim}
820 \begin_inset Newline newline
821 \end_inset
822
823
824 \backslash
825 begin{minipage}{5cm}
826 \begin_inset Newline newline
827 \end_inset
828
829 This ...
830  
831 \begin_inset Newline newline
832 \end_inset
833
834
835 \backslash
836 end{minipage}
837 \begin_inset Newline newline
838 \end_inset
839
840
841 \backslash
842 end{verbatim}
843 \begin_inset Newline newline
844 \end_inset
845
846
847 \backslash
848 end{minipage}
849 \begin_inset Newline newline
850 \end_inset
851
852
853 \backslash
854 end{tabular}
855 \end_layout
856
857 \begin_layout LyX-Code
858
859 \end_layout
860
861 \begin_layout Standard
862 The 
863 \begin_inset Flex Code
864 status collapsed
865
866 \begin_layout Plain Layout
867 \SpecialChar TeX
868  Code
869 \end_layout
870
871 \end_inset
872
873  box containing this text is directly after this paragraph.
874  Those of you reading the manual in \SpecialChar LyX
875  will only see the \SpecialChar TeX
876  code inset.
877  Those reading a printed version of the manuals will see the actual results:
878 \begin_inset VSpace bigskip
879 \end_inset
880
881
882 \end_layout
883
884 \begin_layout Standard
885 \begin_inset ERT
886 status open
887
888 \begin_layout Plain Layout
889
890
891 \backslash
892 begin{tabular}{ll}
893 \end_layout
894
895 \begin_layout Plain Layout
896
897
898 \backslash
899 begin{minipage}{5cm}
900 \end_layout
901
902 \begin_layout Plain Layout
903
904 This is an example of a minipage environment.
905  You can put nearly everything in it, even (non-floating) figures and tables.
906  
907 \end_layout
908
909 \begin_layout Plain Layout
910
911
912 \backslash
913 end{minipage}
914 \end_layout
915
916 \begin_layout Plain Layout
917
918 &
919 \end_layout
920
921 \begin_layout Plain Layout
922
923
924 \backslash
925 begin{minipage}{5cm}
926 \end_layout
927
928 \begin_layout Plain Layout
929
930
931 \backslash
932 begin{verbatim}
933 \end_layout
934
935 \begin_layout Plain Layout
936
937
938 \backslash
939 begin{minipage}{5cm}
940 \end_layout
941
942 \begin_layout Plain Layout
943
944 This ...
945  
946 \end_layout
947
948 \begin_layout Plain Layout
949
950
951 \backslash
952 end{minipage}
953 \end_layout
954
955 \begin_layout Plain Layout
956
957
958 \backslash
959 end{verbatim}
960 \end_layout
961
962 \begin_layout Plain Layout
963
964
965 \backslash
966 end{minipage}
967 \end_layout
968
969 \begin_layout Plain Layout
970
971
972 \backslash
973 end{tabular}
974 \end_layout
975
976 \end_inset
977
978
979 \begin_inset VSpace bigskip
980 \end_inset
981
982
983 \end_layout
984
985 \begin_layout Standard
986 In addition to using \SpecialChar TeX
987  code, you can also create a separate file containing
988  some complex \SpecialChar LaTeX
989  structure and then use 
990 \begin_inset Flex Noun
991 status collapsed
992
993 \begin_layout Plain Layout
994 Insert\SpecialChar menuseparator
995 Child
996 \begin_inset space ~
997 \end_inset
998
999 Document
1000 \end_layout
1001
1002 \end_inset
1003
1004  to include your file (you should select the type 
1005 \begin_inset Flex Code
1006 status collapsed
1007
1008 \begin_layout Plain Layout
1009 Input
1010 \end_layout
1011
1012 \end_inset
1013
1014 ).
1015  We recommend that you only do this if you have a 
1016 \begin_inset Flex Code
1017 status collapsed
1018
1019 \begin_layout Plain Layout
1020 .tex
1021 \end_layout
1022
1023 \end_inset
1024
1025  file which you 
1026 \emph on
1027 know
1028 \emph default
1029  works already.
1030  Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
1031  errors.
1032 \end_layout
1033
1034 \begin_layout Standard
1035 There are a few last points to emphasize:
1036 \end_layout
1037
1038 \begin_layout Itemize
1039 \SpecialChar LyX
1040  
1041 \emph on
1042 does not
1043 \emph default
1044  check if your \SpecialChar LaTeX
1045  code is correct.
1046 \end_layout
1047
1048 \begin_layout Itemize
1049 Beware of reinventing the wheel.
1050 \end_layout
1051
1052 \begin_layout Standard
1053 On that last point, \SpecialChar LyX
1054  does have quite a few features tucked into it, and
1055  more are coming.
1056  Be sure to check the manuals to make sure that \SpecialChar LyX
1057  doesn't have such-and-such
1058  feature before you decide you have to do it by hand.
1059  Moreover, there are numerous \SpecialChar LaTeX
1060  packages out there to do all sorts of things,
1061  from labels to envelopes to fancy multipage tables.
1062  Check out 
1063 \begin_inset CommandInset href
1064 LatexCommand href
1065 name "CTAN"
1066 target "http://www.ctan.org/"
1067
1068 \end_inset
1069
1070  for details.
1071 \end_layout
1072
1073 \begin_layout Standard
1074 If you do need to do some wild and fancy things within your document, be
1075  sure to check out a good \SpecialChar LaTeX
1076  book for assistance.
1077  There are a number of them listed in the bibliography of the 
1078 \emph on
1079 User's Guide
1080 \emph default
1081 .
1082 \end_layout
1083
1084 \begin_layout Section
1085 \SpecialChar LyX
1086  and the \SpecialChar LaTeX
1087  Preamble
1088 \end_layout
1089
1090 \begin_layout Subsection
1091 About the \SpecialChar LaTeX
1092  Preamble
1093 \end_layout
1094
1095 \begin_layout Standard
1096 If you already know \SpecialChar LaTeX
1097 , there is no need to explain here what the preamble
1098  is good for.
1099  If you don't, the following will give you some ideas—we recommend again
1100  that you consult a \SpecialChar LaTeX
1101  book for further information.
1102  In any case, you should read the points below, because they explain what
1103  you can do and what you don't need to do in the \SpecialChar LaTeX
1104  preamble of a \SpecialChar LyX
1105  document.
1106 \end_layout
1107
1108 \begin_layout Standard
1109 The \SpecialChar LaTeX
1110  preamble comes at the very beginning of a document, 
1111 \emph on
1112 before
1113 \emph default
1114  the text.
1115  It serves to:
1116 \end_layout
1117
1118 \begin_layout Itemize
1119 Declare the document class.
1120  
1121 \begin_inset Newline newline
1122 \end_inset
1123
1124 \SpecialChar LyX
1125  already does this for you.
1126  If you're a seasoned \SpecialChar LaTeX
1127 -nician, and you have a custom document class you
1128  want to use, check out the 
1129 \emph on
1130 Customization Manual
1131 \emph default
1132  for information on how to make \SpecialChar LyX
1133  interface to it.
1134 \end_layout
1135
1136 \begin_layout Itemize
1137 Declare the usage of packages.
1138  
1139 \begin_inset Newline newline
1140 \end_inset
1141
1142 \SpecialChar LaTeX
1143  packages provide special commands, which are only available within a document
1144  when the package has been declared in the preamble.
1145  In addition to providing special commands, the inclusion of a package can
1146  change the document.
1147  For example, the package 
1148 \begin_inset Flex Code
1149 status collapsed
1150
1151 \begin_layout Plain Layout
1152 indentfirst
1153 \end_layout
1154
1155 \end_inset
1156
1157  forces all paragraphs to be indented.
1158  There are other packages for labels, envelopes, margins, etc.
1159  
1160 \end_layout
1161
1162 \begin_layout Itemize
1163 Set counters, variables, lengths and widths.
1164  
1165 \begin_inset Newline newline
1166 \end_inset
1167
1168 There are several \SpecialChar LaTeX
1169  counters and variables that 
1170 \emph on
1171 must
1172 \emph default
1173  be set globally from within the preamble in order to have the desired effect.
1174  (There are variables that you can set and reset inside the document, too.)
1175  Margins are a good example of something that must be set in the preamble.
1176  Another example is the label format for lists.
1177  You can actually set these just about anywhere, but it's best to do it
1178  just once, inside the preamble.
1179 \end_layout
1180
1181 \begin_layout Itemize
1182 Declare user defined commands (with 
1183 \begin_inset Flex Code
1184 status collapsed
1185
1186 \begin_layout Plain Layout
1187
1188 \backslash
1189 newcommand
1190 \end_layout
1191
1192 \end_inset
1193
1194  or 
1195 \begin_inset Flex Code
1196 status collapsed
1197
1198 \begin_layout Plain Layout
1199
1200 \backslash
1201 renewcommand
1202 \end_layout
1203
1204 \end_inset
1205
1206 ).
1207 \begin_inset Newline newline
1208 \end_inset
1209
1210 These are abbreviations for \SpecialChar LaTeX
1211  commands which appear very often inside a document.
1212  Although the preamble is a good place to declare such commands, they 
1213 \emph on
1214 can
1215 \emph default
1216  be declared anywhere (before they are used for the first time, of course).
1217  This can be useful if there is a lot of raw \SpecialChar LaTeX
1218  code in your document, which
1219  normally should not be the case.
1220 \end_layout
1221
1222 \begin_layout Standard
1223 \SpecialChar LyX
1224  adds its own set of definitions to the preamble of the 
1225 \begin_inset Flex Code
1226 status collapsed
1227
1228 \begin_layout Plain Layout
1229 .tex
1230 \end_layout
1231
1232 \end_inset
1233
1234  file it produces.
1235  This makes \SpecialChar LaTeX
1236  files generated by \SpecialChar LyX
1237  portable.
1238 \end_layout
1239
1240 \begin_layout Subsection
1241 Changing the Preamble
1242 \end_layout
1243
1244 \begin_layout Standard
1245 The commands which \SpecialChar LyX
1246  adds to the preamble of a \SpecialChar LaTeX
1247  file are fixed; you can't
1248  change them without patching \SpecialChar LyX
1249  itself.
1250  You can, however, add your own stuff to the preamble by selecting 
1251 \begin_inset Flex Noun
1252 status collapsed
1253
1254 \begin_layout Plain Layout
1255 \SpecialChar LaTeX
1256
1257 \begin_inset space ~
1258 \end_inset
1259
1260 Preamble
1261 \end_layout
1262
1263 \end_inset
1264
1265  in the 
1266 \begin_inset Flex Noun
1267 status collapsed
1268
1269 \begin_layout Plain Layout
1270 Document\SpecialChar menuseparator
1271 Settings
1272 \end_layout
1273
1274 \end_inset
1275
1276  dialog.
1277  \SpecialChar LyX
1278  adds anything in the 
1279 \begin_inset Flex Noun
1280 status collapsed
1281
1282 \begin_layout Plain Layout
1283 Preamble
1284 \end_layout
1285
1286 \end_inset
1287
1288  dialog to its own built-in preamble.
1289  Before adding your own declarations in the preamble, you should make sure
1290  that \SpecialChar LyX
1291  doesn't already support what you want to do.
1292  (Remember what we said about reinventing the wheel?) Also, 
1293 \emph on
1294 make sure your preamble code is correct
1295 \emph default
1296 .
1297  \SpecialChar LyX
1298  doesn't check it for you.
1299  If there is an error, you're likely to get an error like 
1300 \begin_inset Quotes eld
1301 \end_inset
1302
1303
1304 \begin_inset Flex Code
1305 status collapsed
1306
1307 \begin_layout Plain Layout
1308 Missing 
1309 \backslash
1310 begin{document}
1311 \end_layout
1312
1313 \end_inset
1314
1315
1316 \begin_inset Quotes erd
1317 \end_inset
1318
1319 .
1320  If you see this error, check your preamble.
1321 \end_layout
1322
1323 \begin_layout Subsection
1324 Examples
1325 \end_layout
1326
1327 \begin_layout Standard
1328 Here are some examples of what you can add to a preamble, and what they
1329  do.
1330 \end_layout
1331
1332 \begin_layout Subsubsection
1333 Example #1: Offsets
1334 \end_layout
1335
1336 \begin_layout Standard
1337 There are two variables under \SpecialChar LaTeX
1338  that control page position: 
1339 \begin_inset Flex Code
1340 status collapsed
1341
1342 \begin_layout Plain Layout
1343
1344 \backslash
1345 hoffset
1346 \end_layout
1347
1348 \end_inset
1349
1350  and 
1351 \begin_inset Flex Code
1352 status collapsed
1353
1354 \begin_layout Plain Layout
1355
1356 \backslash
1357 voffset
1358 \end_layout
1359
1360 \end_inset
1361
1362 .
1363  Their names should be self-explanatory.
1364  These variables are useful if you think for a moment about computer labels.
1365  Sometimes, the size of a print medium and the area of the medium that you
1366  can actually print on aren't the same.
1367  This is where 
1368 \begin_inset Flex Code
1369 status collapsed
1370
1371 \begin_layout Plain Layout
1372
1373 \backslash
1374 hoffset
1375 \end_layout
1376
1377 \end_inset
1378
1379  and 
1380 \begin_inset Flex Code
1381 status collapsed
1382
1383 \begin_layout Plain Layout
1384
1385 \backslash
1386 voffset
1387 \end_layout
1388
1389 \end_inset
1390
1391  come in.
1392 \end_layout
1393
1394 \begin_layout Standard
1395 The default values for 
1396 \begin_inset Flex Code
1397 status collapsed
1398
1399 \begin_layout Plain Layout
1400
1401 \backslash
1402 hoffset
1403 \end_layout
1404
1405 \end_inset
1406
1407  and 
1408 \begin_inset Flex Code
1409 status collapsed
1410
1411 \begin_layout Plain Layout
1412
1413 \backslash
1414 voffset
1415 \end_layout
1416
1417 \end_inset
1418
1419  are both 0
1420 \begin_inset space \thinspace{}
1421 \end_inset
1422
1423 points, i.
1424 \begin_inset space \thinspace{}
1425 \end_inset
1426
1427 e.
1428 \begin_inset space \space{}
1429 \end_inset
1430
1431 the page isn't shifted.
1432  Unfortunately, some DVI drivers always seem to shift the page.
1433  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1434  If you're using \SpecialChar LyX
1435  on a system that you don't personally maintain, and your
1436  sysadmin is a doofus, 
1437 \begin_inset Flex Code
1438 status collapsed
1439
1440 \begin_layout Plain Layout
1441
1442 \backslash
1443 hoffset
1444 \end_layout
1445
1446 \end_inset
1447
1448  and 
1449 \begin_inset Flex Code
1450 status collapsed
1451
1452 \begin_layout Plain Layout
1453
1454 \backslash
1455 voffset
1456 \end_layout
1457
1458 \end_inset
1459
1460  can save the day.
1461  Suppose your left and top margins are always 0.5
1462 \begin_inset space \thinspace{}
1463 \end_inset
1464
1465 inches too big.
1466  You can add this to the preamble:
1467 \end_layout
1468
1469 \begin_layout LyX-Code
1470
1471 \backslash
1472 setlength{
1473 \backslash
1474 hoffset}{-0.5 in}
1475 \end_layout
1476
1477 \begin_layout LyX-Code
1478
1479 \backslash
1480 setlength{
1481 \backslash
1482 voffset}{-0.5 in}
1483 \end_layout
1484
1485 \begin_layout Standard
1486 and your margins should now be correct.
1487 \end_layout
1488
1489 \begin_layout Subsubsection
1490 Example #2: Labels
1491 \end_layout
1492
1493 \begin_layout Standard
1494 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1495  There's a rather nice package, available at your nearest CTAN archive,
1496  for printing sheets of labels: 
1497 \begin_inset Flex Code
1498 status collapsed
1499
1500 \begin_layout Plain Layout
1501 labels.sty
1502 \end_layout
1503
1504 \end_inset
1505
1506 .
1507  Now, your system may not have this package installed by default.
1508  We leave that up to you to check.
1509  You'll also want to read the documentation for it; we're not going to do
1510  that for you.
1511  Since this is an example, however, we'll give you an example of how you
1512  use this package.
1513 \end_layout
1514
1515 \begin_layout Standard
1516 First, make sure you're using the 
1517 \begin_inset Flex Code
1518 status collapsed
1519
1520 \begin_layout Plain Layout
1521 article
1522 \end_layout
1523
1524 \end_inset
1525
1526  document class.
1527  Next, you need to put the following in your preamble:
1528 \end_layout
1529
1530 \begin_layout LyX-Code
1531
1532 \backslash
1533 usepackage{labels}
1534 \end_layout
1535
1536 \begin_layout LyX-Code
1537
1538 \backslash
1539 LabelCols=3
1540 \end_layout
1541
1542 \begin_layout LyX-Code
1543
1544 \backslash
1545 LabelRows=7
1546 \end_layout
1547
1548 \begin_layout LyX-Code
1549
1550 \backslash
1551 LeftBorder=8mm
1552 \end_layout
1553
1554 \begin_layout LyX-Code
1555
1556 \backslash
1557 RightBorder=8mm
1558 \end_layout
1559
1560 \begin_layout LyX-Code
1561
1562 \backslash
1563 TopBorder=9mm
1564 \end_layout
1565
1566 \begin_layout LyX-Code
1567
1568 \backslash
1569 BottomBorder=2mm
1570 \end_layout
1571
1572 \begin_layout Standard
1573 This sets things up for Avery label sheets, stock #5360.
1574  You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1575  code, placing
1576  the commands 
1577 \begin_inset Flex Code
1578 status collapsed
1579
1580 \begin_layout Plain Layout
1581
1582 \backslash
1583 begin{labels}
1584 \end_layout
1585
1586 \end_inset
1587
1588  and 
1589 \begin_inset Flex Code
1590 status collapsed
1591
1592 \begin_layout Plain Layout
1593
1594 \backslash
1595 end{labels}
1596 \end_layout
1597
1598 \end_inset
1599
1600  around each label text.
1601  This and other special features of 
1602 \begin_inset Flex Code
1603 status collapsed
1604
1605 \begin_layout Plain Layout
1606 labels.sty
1607 \end_layout
1608
1609 \end_inset
1610
1611  are explained in its documentation.
1612 \end_layout
1613
1614 \begin_layout Standard
1615 Someday, someone may write a \SpecialChar LyX
1616  layout file to support this package directly.
1617  Maybe that someone is you.
1618 \end_layout
1619
1620 \begin_layout Subsubsection
1621 Example #3: Paragraph Indentation
1622 \end_layout
1623
1624 \begin_layout Standard
1625 Americans are trained to indent the first line of 
1626 \emph on
1627 every
1628 \emph default
1629  paragraph.
1630  As with all of their other weird quirks, most Americans will whine and
1631  moan until they can have their way and indent the first line of all paragraphs.
1632  (Yes, we're joking.
1633  (We are?) 
1634 \emph on
1635 Yeah
1636 \emph default
1637 , we are.)
1638 \end_layout
1639
1640 \begin_layout Standard
1641 Of course, this behavior isn't standard typography.
1642  In books, you typically only indent the first line of a paragraph 
1643 \emph on
1644 if
1645 \emph default
1646  it follows another one.
1647  The idea behind indenting the first line of a paragraph is to distinguish
1648  neighboring paragraphs from one another.
1649  If there is no previous paragraph—for example, if it follows a figure or
1650  is the first paragraph in a section—then there is no need for indentation.
1651  
1652 \end_layout
1653
1654 \begin_layout Standard
1655 If you're a typical American (we're still joking!), though, you don't care
1656  about such esoteric things; you want your indentation! Add this to the
1657  preamble:
1658 \end_layout
1659
1660 \begin_layout LyX-Code
1661
1662 \backslash
1663 usepackage{indentfirst}
1664 \end_layout
1665
1666 \begin_layout Standard
1667 If your \SpecialChar TeX
1668  distribution isn't braindead, you'll have this package, and all
1669  of your paragraphs will get the indentation the Founding Fathers intended
1670  they should have.
1671 \end_layout
1672
1673 \begin_layout Subsubsection
1674 Example #4: This Document
1675 \end_layout
1676
1677 \begin_layout Standard
1678 You can also check out the preamble of this document to get an idea of some
1679  of the advanced things you can do.
1680 \end_layout
1681
1682 \begin_layout Section
1683 \SpecialChar LyX
1684  and \SpecialChar LaTeX
1685  Errors
1686 \end_layout
1687
1688 \begin_layout Standard
1689 When \SpecialChar LyX
1690  calls \SpecialChar LaTeX
1691 , it tells \SpecialChar LaTeX
1692  to blithely ignore any errors and keep going.
1693  It then uses the logfile from the \SpecialChar LaTeX
1694  run to do a post-mortem.
1695  After analyzing the logfile, \SpecialChar LyX
1696  displays a dialog listing the errors.
1697  Clicking on any one of them will take you to the position in your \SpecialChar LyX
1698  file
1699  where the error occurred.
1700 \begin_inset Foot
1701 status collapsed
1702
1703 \begin_layout Plain Layout
1704 Well, usually.
1705  Analyzing the logfile is a tough job, and \SpecialChar LyX
1706  doesn't always go to the right
1707  line.
1708  There are also cases where \SpecialChar LaTeX
1709  reports the error on one line, but the actual
1710  error is earlier.
1711  This is not unlike forgetting a closing brace in a program: You'll get
1712  an error, but only later.
1713 \end_layout
1714
1715 \end_inset
1716
1717
1718 \end_layout
1719
1720 \begin_layout Standard
1721 Some folks also like to look at the log file directly: It is available from
1722  
1723 \begin_inset Flex Noun
1724 status collapsed
1725
1726 \begin_layout Plain Layout
1727 Document
1728 \bar under
1729 \SpecialChar menuseparator
1730
1731 \bar default
1732 Latex
1733 \begin_inset space ~
1734 \end_inset
1735
1736 Log
1737 \end_layout
1738
1739 \end_inset
1740
1741 .
1742  There are some fairly common error messages and warnings.
1743  We'll cover those here.
1744  You should look at a good \SpecialChar LaTeX
1745  book for a complete listing.
1746 \end_layout
1747
1748 \begin_layout Itemize
1749 \begin_inset Flex Code
1750 status collapsed
1751
1752 \begin_layout Plain Layout
1753 \SpecialChar LaTeX
1754  Warning
1755 \end_layout
1756
1757 \end_inset
1758
1759
1760 \begin_inset Newline newline
1761 \end_inset
1762
1763 Anything beginning with these words is a warning message for the purpose
1764  of 
1765 \begin_inset Quotes eld
1766 \end_inset
1767
1768 debugging
1769 \begin_inset Quotes erd
1770 \end_inset
1771
1772  the \SpecialChar LaTeX
1773  code itself.
1774  You'll get messages like this if you added or changed cross-references
1775  or bibliography entries, in which case, \SpecialChar LaTeX
1776  is trying to tell you that you
1777  need to make another run.
1778  You can by-and-large ignore these.
1779 \end_layout
1780
1781 \begin_layout Itemize
1782 \begin_inset Flex Code
1783 status collapsed
1784
1785 \begin_layout Plain Layout
1786 \SpecialChar LaTeX
1787  Font Warning
1788 \end_layout
1789
1790 \end_inset
1791
1792
1793 \begin_inset Newline newline
1794 \end_inset
1795
1796 Another warning message, this time about fonts which \SpecialChar LaTeX
1797  couldn't find.
1798  The rest of the message will often say something about a replacement font
1799  that \SpecialChar LaTeX
1800  used.
1801  You can safely ignore these, too.
1802 \end_layout
1803
1804 \begin_layout Itemize
1805 \begin_inset Flex Code
1806 status collapsed
1807
1808 \begin_layout Plain Layout
1809 Overfull 
1810 \backslash
1811 hbox
1812 \end_layout
1813
1814 \end_inset
1815
1816
1817 \begin_inset Newline newline
1818 \end_inset
1819
1820 \SpecialChar LaTeX
1821  absolutely 
1822 \emph on
1823 loves
1824 \emph default
1825  to spew these out.
1826  They are warnings about lines that were too long and run past the right
1827  margin.
1828  Almost always, this is unnoticeable in the final output.
1829  (It can be just a point or two.) Or, only one or two characters extend past
1830  the margin.
1831  \SpecialChar LaTeX
1832  seems to generate at least one of these messages for just about any document
1833  you write.
1834 \begin_inset Newline newline
1835 \end_inset
1836
1837 You can ignore these messages.
1838  Your eyes will tell you if there's a problem with something that's too
1839  wide; just look at the output.
1840 \begin_inset Foot
1841 status collapsed
1842
1843 \begin_layout Plain Layout
1844 You can also enable the `draft' option in 
1845 \begin_inset Flex Noun
1846 status collapsed
1847
1848 \begin_layout Plain Layout
1849 Document
1850 \bar under
1851 \SpecialChar menuseparator
1852
1853 \bar default
1854 Settings
1855 \end_layout
1856
1857 \end_inset
1858
1859 , and then \SpecialChar LaTeX
1860  will draw a black box in the margin of lines that are overfull.
1861 \end_layout
1862
1863 \end_inset
1864
1865
1866 \end_layout
1867
1868 \begin_layout Itemize
1869 \begin_inset Flex Code
1870 status collapsed
1871
1872 \begin_layout Plain Layout
1873 Underfull 
1874 \backslash
1875 hbox
1876 \end_layout
1877
1878 \end_inset
1879
1880
1881 \begin_inset Newline newline
1882 \end_inset
1883
1884 Not quite as common as its cousin.
1885  \SpecialChar LaTeX
1886  seems to like to print lines that are a bit too wide as opposed to ones
1887  that are a bit too narrow.
1888  We have no idea why.
1889 \end_layout
1890
1891 \begin_layout Itemize
1892 \begin_inset Flex Code
1893 status collapsed
1894
1895 \begin_layout Plain Layout
1896 Overfull 
1897 \backslash
1898 vbox
1899 \end_layout
1900
1901 \end_inset
1902
1903  and 
1904 \begin_inset Flex Code
1905 status collapsed
1906
1907 \begin_layout Plain Layout
1908 Underfull 
1909 \backslash
1910 vbox
1911 \end_layout
1912
1913 \end_inset
1914
1915
1916 \begin_inset Newline newline
1917 \end_inset
1918
1919 Warnings about troubles breaking the page.
1920  Once again, just look at the output.
1921  Your eyes will tell you where something has gone wrong.
1922 \end_layout
1923
1924 \begin_layout Itemize
1925 \begin_inset Flex Code
1926 status collapsed
1927
1928 \begin_layout Plain Layout
1929 \SpecialChar LaTeX
1930  Error: File 
1931 \begin_inset Quotes els
1932 \end_inset
1933
1934 Xxxx
1935 \begin_inset Quotes ers
1936 \end_inset
1937
1938  not found
1939 \end_layout
1940
1941 \end_inset
1942
1943
1944 \begin_inset Newline newline
1945 \end_inset
1946
1947 The file 
1948 \begin_inset Quotes eld
1949 \end_inset
1950
1951 Xxxx
1952 \begin_inset Quotes erd
1953 \end_inset
1954
1955  isn't installed on this system.
1956  This usually appears because some package your document needs isn't installed.
1957  If you didn't touch the preamble or didn't use the 
1958 \begin_inset Flex Code
1959 status collapsed
1960
1961 \begin_layout Plain Layout
1962
1963 \backslash
1964 usepackage{}
1965 \end_layout
1966
1967 \end_inset
1968
1969  command, then one of the packages \SpecialChar LyX
1970  tried to load is missing.
1971  Use 
1972 \begin_inset Flex Noun
1973 status collapsed
1974
1975 \begin_layout Plain Layout
1976 Help\SpecialChar menuseparator
1977 \SpecialChar LaTeX
1978  Configuration
1979 \end_layout
1980
1981 \end_inset
1982
1983  to get a list of packages that \SpecialChar LyX
1984  knows about.
1985  This file is updated whenever you reconfigure \SpecialChar LyX
1986  (using 
1987 \begin_inset Flex Noun
1988 status collapsed
1989
1990 \begin_layout Plain Layout
1991 Tools\SpecialChar menuseparator
1992 Reconfigure
1993 \end_layout
1994
1995 \end_inset
1996
1997 ) and tells you which packages have been detected and what they do.
1998 \begin_inset Newline newline
1999 \end_inset
2000
2001 If you did use the 
2002 \begin_inset Flex Code
2003 status collapsed
2004
2005 \begin_layout Plain Layout
2006
2007 \backslash
2008 usepackage{}
2009 \end_layout
2010
2011 \end_inset
2012
2013  command and the package in question isn't installed, then you'll need to
2014  install it yourself.
2015 \end_layout
2016
2017 \begin_layout Itemize
2018 \begin_inset Flex Code
2019 status collapsed
2020
2021 \begin_layout Plain Layout
2022 \SpecialChar LaTeX
2023  Error: Unknown option
2024 \end_layout
2025
2026 \end_inset
2027
2028
2029 \begin_inset Newline newline
2030 \end_inset
2031
2032 Error messages beginning with this are trying to tell you that you specified
2033  a bad or undefined option to a package.
2034  Check the package's documentation.
2035 \end_layout
2036
2037 \begin_layout Itemize
2038 \begin_inset Flex Code
2039 status collapsed
2040
2041 \begin_layout Plain Layout
2042 Undefined control sequence
2043 \end_layout
2044
2045 \end_inset
2046
2047
2048 \begin_inset Newline newline
2049 \end_inset
2050
2051 If you've inserted \SpecialChar LaTeX
2052  code into your document, but made a typo, you'll get
2053  one of these.
2054  You may have forgotten to load a package.
2055  In any case, this error message usually means that you used an undefined
2056  command.
2057  
2058 \end_layout
2059
2060 \begin_layout Standard
2061 There are other error and warning messages.
2062  Some are self-explanatory.
2063  These are usually \SpecialChar LaTeX
2064  messages.
2065  Others are downright cryptic.
2066  These are usually \SpecialChar TeX
2067  error messages, and we really have 
2068 \emph on
2069 no clue
2070 \emph default
2071  what they mean or how to decipher them.
2072  No-one does.
2073 \end_layout
2074
2075 \begin_layout Standard
2076 There's a general sequence you should follow if you get error messages:
2077 \end_layout
2078
2079 \begin_layout Enumerate
2080 Look at the \SpecialChar LaTeX
2081  code you inserted for typos.
2082 \end_layout
2083
2084 \begin_layout Enumerate
2085 If there are no typos, check that you used the command(s) correctly.
2086 \end_layout
2087
2088 \begin_layout Enumerate
2089 If you get a bunch of error boxes piled up at the very top of the document—and
2090  especially if you see a 
2091 \begin_inset Quotes eld
2092 \end_inset
2093
2094
2095 \begin_inset Flex Code
2096 status collapsed
2097
2098 \begin_layout Plain Layout
2099 Missing 
2100 \backslash
2101 begin{document}
2102 \end_layout
2103
2104 \end_inset
2105
2106
2107 \begin_inset Quotes erd
2108 \end_inset
2109
2110  error—it means that there are errors in the preamble.
2111  Start debugging your preamble.
2112 \end_layout
2113
2114 \begin_layout Enumerate
2115 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2116  code to the
2117  document, the first suspect is your \SpecialChar LaTeX
2118  distribution itself.
2119  Check for missing packages and install them.
2120 \end_layout
2121
2122 \begin_layout Enumerate
2123 Okay, so there are no missing packages.
2124  Did you use any of the fine-tuning options in \SpecialChar LyX
2125 ? Specifically, did you 
2126 \emph on
2127 misuse
2128 \emph default
2129  any of them, like trying to manually insert lots of 
2130 \begin_inset Flex Code
2131 status collapsed
2132
2133 \begin_layout Plain Layout
2134 Protected
2135 \begin_inset space ~
2136 \end_inset
2137
2138 Blanks
2139 \end_layout
2140
2141 \end_inset
2142
2143
2144 \begin_inset Flex Code
2145 status collapsed
2146
2147 \begin_layout Plain Layout
2148 Linebreaks
2149 \end_layout
2150
2151 \end_inset
2152
2153 , or 
2154 \begin_inset Flex Code
2155 status collapsed
2156
2157 \begin_layout Plain Layout
2158 Pagebreaks
2159 \end_layout
2160
2161 \end_inset
2162
2163 ? Did you try to kludge something together with these instead of using the
2164  appropriate paragraph environment?
2165 \end_layout
2166
2167 \begin_layout Enumerate
2168 All right, you didn't use any of the fine-tuning options, you played by
2169  the rules.
2170  Did you try to pull a fancy maneuver? Did you do something funky inside
2171  a table or an equation, like inserting a graphic into a table cell?
2172 \end_layout
2173
2174 \begin_layout Enumerate
2175 Do you have long sections of text where \SpecialChar LaTeX
2176  cannot find a place to break a
2177  line? By default, \SpecialChar LaTeX
2178  is rather strict about how much extra inter-word spacing
2179  it will add in order to break a line.
2180  Preferably, you should rework the paragraph to avoid the problem.
2181 \end_layout
2182
2183 \begin_layout Enumerate
2184 Did you go overboard with the nesting? \SpecialChar LyX
2185  (currently) doesn't check to make
2186  sure you're in the limits for nesting environments.
2187  If you nested a bunch of environments to the 
2188 \begin_inset Formula $17^{\mathrm{th}}$
2189 \end_inset
2190
2191  level, that's the problem.
2192  (The limit in \SpecialChar LaTeX
2193  is five.)
2194 \end_layout
2195
2196 \begin_layout Enumerate
2197 Okay, you didn't get any error messages, but your output looks awful.
2198  If you have a table or figure that's too wide or long for the page, you
2199  need to:
2200 \begin_inset Separator parbreak
2201 \end_inset
2202
2203
2204 \end_layout
2205
2206 \begin_deeper
2207 \begin_layout Enumerate
2208 rescale the figure so it fits.
2209 \end_layout
2210
2211 \begin_layout Enumerate
2212 trim down the table so it fits.
2213 \end_layout
2214
2215 \end_deeper
2216 \begin_layout Enumerate
2217 If something else is wrong with the output, and you didn't try to pull anything
2218  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2219 \end_layout
2220
2221 \begin_layout Standard
2222 If all this doesn't help—well, then 
2223 \emph on
2224 perhaps
2225 \emph default
2226  you might have found a bug in \SpecialChar LyX
2227 \SpecialChar ldots
2228 .
2229 \end_layout
2230
2231 \begin_layout Chapter
2232 Supplemental Tools
2233 \end_layout
2234
2235 \begin_layout Section
2236 Customizing Bibliographies with Bib\SpecialChar TeX
2237
2238 \end_layout
2239
2240 \begin_layout Standard
2241 The most basic information about how to use Bib\SpecialChar TeX
2242  with \SpecialChar LyX
2243  is contained in the
2244  section 
2245 \emph on
2246 Bibliography databases (Bib\SpecialChar TeX
2247 )
2248 \emph default
2249  of the 
2250 \emph on
2251 User's Guide
2252 \emph default
2253 .
2254  The following subsections explain special bibliography features supported
2255  by \SpecialChar LyX
2256 .
2257 \end_layout
2258
2259 \begin_layout Subsection
2260 Alternative Citation Styles
2261 \end_layout
2262
2263 \begin_layout Standard
2264 Standard Bib\SpecialChar TeX
2265  uses numbers (e.
2266 \begin_inset space \thinspace{}
2267 \end_inset
2268
2269 g.
2270 \begin_inset space \space{}
2271 \end_inset
2272
2273
2274 \begin_inset Quotes eld
2275 \end_inset
2276
2277 [12]
2278 \begin_inset Quotes erd
2279 \end_inset
2280
2281 ) to refer to a cited work.
2282  However, in many scientific disciplines, other citation styles are in use.
2283  The most common one is the author-year style (e.
2284 \begin_inset space \thinspace{}
2285 \end_inset
2286
2287 g.
2288 \begin_inset space \space{}
2289 \end_inset
2290
2291
2292 \begin_inset Quotes eld
2293 \end_inset
2294
2295 Knuth 1984a
2296 \begin_inset Quotes erd
2297 \end_inset
2298
2299 ).
2300  \SpecialChar LyX
2301  supports two packages that provide this style, 
2302 \begin_inset Flex Code
2303 status collapsed
2304
2305 \begin_layout Plain Layout
2306 natbib
2307 \end_layout
2308
2309 \end_inset
2310
2311  and 
2312 \begin_inset Flex Code
2313 status collapsed
2314
2315 \begin_layout Plain Layout
2316 jurabib
2317 \end_layout
2318
2319 \end_inset
2320
2321 .
2322  Both packages have their pros and cons, which cannot be listed in detail.
2323  If you only want to have simple author-year (or author-numerical) style,
2324  or if you want to use one of the countless style files for 
2325 \begin_inset Flex Code
2326 status collapsed
2327
2328 \begin_layout Plain Layout
2329 natbib
2330 \end_layout
2331
2332 \end_inset
2333
2334 , then the established 
2335 \begin_inset Flex Code
2336 status collapsed
2337
2338 \begin_layout Plain Layout
2339 natbib
2340 \end_layout
2341
2342 \end_inset
2343
2344  package is probably your choice.
2345  If you need special features like short title references, ibidem etc., you
2346  might consider the 
2347 \begin_inset Flex Code
2348 status collapsed
2349
2350 \begin_layout Plain Layout
2351 jurabib
2352 \end_layout
2353
2354 \end_inset
2355
2356  package.
2357 \end_layout
2358
2359 \begin_layout Standard
2360 The handling of both packages in \SpecialChar LyX
2361  is basically the same.
2362  Go to 
2363 \begin_inset Flex Noun
2364 status collapsed
2365
2366 \begin_layout Plain Layout
2367 Document\SpecialChar menuseparator
2368 Settings
2369 \end_layout
2370
2371 \end_inset
2372
2373  and select under 
2374 \begin_inset Flex Noun
2375 status collapsed
2376
2377 \begin_layout Plain Layout
2378 Bibliography
2379 \end_layout
2380
2381 \end_inset
2382
2383  the option 
2384 \begin_inset Flex Noun
2385 status collapsed
2386
2387 \begin_layout Plain Layout
2388 Natbib
2389 \end_layout
2390
2391 \end_inset
2392
2393  or 
2394 \begin_inset Flex Noun
2395 status collapsed
2396
2397 \begin_layout Plain Layout
2398 Jurabib
2399 \end_layout
2400
2401 \end_inset
2402
2403 .
2404  With both packages, you will get some extra features in the citation dialog
2405  and you can select the style of the reference (
2406 \begin_inset Quotes eld
2407 \end_inset
2408
2409 Knuth 1984
2410 \begin_inset Quotes erd
2411 \end_inset
2412
2413
2414 \begin_inset Quotes eld
2415 \end_inset
2416
2417 Knuth (1984)
2418 \begin_inset Quotes erd
2419 \end_inset
2420
2421
2422 \begin_inset Quotes eld
2423 \end_inset
2424
2425 Knuth, 1984
2426 \begin_inset Quotes erd
2427 \end_inset
2428
2429
2430 \begin_inset Quotes eld
2431 \end_inset
2432
2433 1984
2434 \begin_inset Quotes erd
2435 \end_inset
2436
2437  etc.).
2438  Note that both packages need specifically designed style files.
2439  They both ship their own, but there are lots of additional style files,
2440  and there is even an interactive style file builder
2441 \begin_inset Foot
2442 status collapsed
2443
2444 \begin_layout Plain Layout
2445 See 
2446 \begin_inset Flex URL
2447 status open
2448
2449 \begin_layout Plain Layout
2450
2451 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2452 \end_layout
2453
2454 \end_inset
2455
2456
2457 \end_layout
2458
2459 \end_inset
2460
2461  for 
2462 \begin_inset Flex Code
2463 status collapsed
2464
2465 \begin_layout Plain Layout
2466 natbib
2467 \end_layout
2468
2469 \end_inset
2470
2471 .
2472 \end_layout
2473
2474 \begin_layout Subsection
2475 Sectioned Bibliographies
2476 \end_layout
2477
2478 \begin_layout Standard
2479 Sometimes you might need to divide your bibliography into several sections.
2480  If you are for instance a historian, the possibility to separate sources
2481  and scientific works is most likely a 
2482 \begin_inset Quotes eld
2483 \end_inset
2484
2485 must have
2486 \begin_inset Quotes erd
2487 \end_inset
2488
2489 .
2490  Unfortunately, Bib\SpecialChar TeX
2491  itself does not allow you to do this.
2492  But with the help of some \SpecialChar LaTeX
2493  packages, Bib\SpecialChar TeX
2494  can be extended to fit your needs.
2495 \end_layout
2496
2497 \begin_layout Standard
2498 \SpecialChar LyX
2499  provides native support for one of these packages, 
2500 \family typewriter
2501 bibtopic
2502 \family default
2503 .
2504 \begin_inset Foot
2505 status collapsed
2506
2507 \begin_layout Plain Layout
2508 Available from 
2509 \begin_inset Flex URL
2510 status open
2511
2512 \begin_layout Plain Layout
2513
2514 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2515 \end_layout
2516
2517 \end_inset
2518
2519
2520 \end_layout
2521
2522 \end_inset
2523
2524  The advantage of this package (compared to other packages like 
2525 \family typewriter
2526 multibib
2527 \family default
2528 ) is that you don't need to define new citation commands.
2529  Instead, you need to prepare different bibliographic databases which include
2530  the entries for the different sections of the bibliography.
2531  For example: If you want to divide your bibliography into the sections
2532  
2533 \begin_inset Quotes eld
2534 \end_inset
2535
2536 Sources
2537 \begin_inset Quotes erd
2538 \end_inset
2539
2540  and 
2541 \begin_inset Quotes eld
2542 \end_inset
2543
2544 Scientific works
2545 \begin_inset Quotes erd
2546 \end_inset
2547
2548 , you first need to create two bibliographic databases, e.
2549 \begin_inset space \thinspace{}
2550 \end_inset
2551
2552 g.
2553 \begin_inset space \space{}
2554 \end_inset
2555
2556
2557 \begin_inset Flex Code
2558 status collapsed
2559
2560 \begin_layout Plain Layout
2561 sources.bib
2562 \end_layout
2563
2564 \end_inset
2565
2566  and 
2567 \begin_inset Flex Code
2568 status collapsed
2569
2570 \begin_layout Plain Layout
2571 scientific.bib
2572 \end_layout
2573
2574 \end_inset
2575
2576 .
2577  
2578 \end_layout
2579
2580 \begin_layout Standard
2581 Go to 
2582 \begin_inset Flex Noun
2583 status collapsed
2584
2585 \begin_layout Plain Layout
2586 Document\SpecialChar menuseparator
2587 Settings
2588 \end_layout
2589
2590 \end_inset
2591
2592  and check under 
2593 \begin_inset Flex Noun
2594 status collapsed
2595
2596 \begin_layout Plain Layout
2597 Bibliography
2598 \end_layout
2599
2600 \end_inset
2601
2602  the option 
2603 \begin_inset Flex Noun
2604 status collapsed
2605
2606 \begin_layout Plain Layout
2607 Sectioned bibliography
2608 \end_layout
2609
2610 \end_inset
2611
2612 .
2613  Now you can insert multiple Bib\SpecialChar TeX
2614  bibliographies, one for each section of
2615  your bibliography.
2616  Returning to our example: Insert the Bib\SpecialChar TeX
2617  bibliography 
2618 \begin_inset Flex Code
2619 status collapsed
2620
2621 \begin_layout Plain Layout
2622 sources.bib
2623 \end_layout
2624
2625 \end_inset
2626
2627  and a second one for the database 
2628 \begin_inset Flex Code
2629 status collapsed
2630
2631 \begin_layout Plain Layout
2632 scientific.bib
2633 \end_layout
2634
2635 \end_inset
2636
2637 .
2638  You are free to use the same or different styles for each section.
2639  Additionally, you can choose if the bibliography section should contain
2640  
2641 \begin_inset Quotes eld
2642 \end_inset
2643
2644 all cited references
2645 \begin_inset Quotes erd
2646 \end_inset
2647
2648  of the specified database(s) (which is the default), 
2649 \begin_inset Quotes eld
2650 \end_inset
2651
2652 all uncited references
2653 \begin_inset Quotes erd
2654 \end_inset
2655
2656  or even 
2657 \begin_inset Quotes eld
2658 \end_inset
2659
2660 all references
2661 \begin_inset Quotes erd
2662 \end_inset
2663
2664 .
2665  This might be useful if you would like to separate your bibliography into
2666  three sections: 
2667 \begin_inset Quotes eld
2668 \end_inset
2669
2670 Cited sources
2671 \begin_inset Quotes erd
2672 \end_inset
2673
2674
2675 \begin_inset Quotes eld
2676 \end_inset
2677
2678 Uncited sources
2679 \begin_inset Quotes erd
2680 \end_inset
2681
2682 , and 
2683 \begin_inset Quotes eld
2684 \end_inset
2685
2686 Scientific works
2687 \begin_inset Quotes erd
2688 \end_inset
2689
2690 .
2691  The titles for the sections can be added as ordinary sections or subsections.
2692  Since 
2693 \begin_inset Flex Code
2694 status collapsed
2695
2696 \begin_layout Plain Layout
2697 bibtopic
2698 \end_layout
2699
2700 \end_inset
2701
2702  removes the bibliography title, you have to manually re-add that, too (as
2703  a chapter* or section*, for instance).
2704 \end_layout
2705
2706 \begin_layout Subsection
2707 Multiple Bibliographies
2708 \end_layout
2709
2710 \begin_layout Standard
2711 Multiple bibliographies, e.
2712 \begin_inset space \thinspace{}
2713 \end_inset
2714
2715 g.
2716 \begin_inset space \space{}
2717 \end_inset
2718
2719 a bibliography for each section or chapter of the document, are not supported
2720  by Bib\SpecialChar TeX
2721  itself.
2722  But the 
2723 \begin_inset Flex Code
2724 status collapsed
2725
2726 \begin_layout Plain Layout
2727 bibtopic
2728 \end_layout
2729
2730 \end_inset
2731
2732  package, which is used for the creation of sectioned bibliographies in
2733  \SpecialChar LyX
2734  (see the previous section), provides an easy way to solve this task, if
2735  you are willing to use some 
2736 \begin_inset Flex Noun
2737 status collapsed
2738
2739 \begin_layout Plain Layout
2740 \SpecialChar TeX
2741  Code
2742 \end_layout
2743
2744 \end_inset
2745
2746  (see section
2747 \begin_inset space ~
2748 \end_inset
2749
2750
2751 \begin_inset CommandInset ref
2752 LatexCommand ref
2753 reference "sec:Inserting-TeX-Code"
2754
2755 \end_inset
2756
2757 ).
2758 \begin_inset Foot
2759 status collapsed
2760
2761 \begin_layout Plain Layout
2762 An alternative approach is to use the 
2763 \begin_inset Flex Code
2764 status collapsed
2765
2766 \begin_layout Plain Layout
2767 chapterbib
2768 \end_layout
2769
2770 \end_inset
2771
2772  or 
2773 \begin_inset Flex Code
2774 status collapsed
2775
2776 \begin_layout Plain Layout
2777 bibunits
2778 \end_layout
2779
2780 \end_inset
2781
2782  package, respectively.
2783 \end_layout
2784
2785 \end_inset
2786
2787
2788 \end_layout
2789
2790 \begin_layout Standard
2791 First go to 
2792 \begin_inset Flex Noun
2793 status collapsed
2794
2795 \begin_layout Plain Layout
2796 Document\SpecialChar menuseparator
2797 Settings
2798 \end_layout
2799
2800 \end_inset
2801
2802  and under 
2803 \begin_inset Flex Noun
2804 status collapsed
2805
2806 \begin_layout Plain Layout
2807 Bibliography
2808 \end_layout
2809
2810 \end_inset
2811
2812  check 
2813 \begin_inset Flex Noun
2814 status collapsed
2815
2816 \begin_layout Plain Layout
2817 Sectioned bibliography
2818 \end_layout
2819
2820 \end_inset
2821
2822 .
2823  In the document, you have to enclose the sections, which shall contain
2824  their own bibliography (including the Bib\SpecialChar TeX
2825  bibliography itself), between
2826  
2827 \begin_inset Flex Code
2828 status collapsed
2829
2830 \begin_layout Plain Layout
2831
2832 \backslash
2833 begin{btUnit}
2834 \end_layout
2835
2836 \end_inset
2837
2838  and 
2839 \begin_inset Flex Code
2840 status collapsed
2841
2842 \begin_layout Plain Layout
2843
2844 \backslash
2845 end{btUnit}
2846 \end_layout
2847
2848 \end_inset
2849
2850  (those commands have to be inserted as \SpecialChar TeX
2851  code).
2852  The bibliography will contain all references that have been cited in the
2853  current 
2854 \begin_inset Flex Code
2855 status collapsed
2856
2857 \begin_layout Plain Layout
2858 btUnit
2859 \end_layout
2860
2861 \end_inset
2862
2863 .
2864  
2865 \series bold
2866 Note:
2867 \series default
2868  If you are using this approach, then every citation reference has to be
2869  inside some 
2870 \begin_inset Flex Code
2871 status collapsed
2872
2873 \begin_layout Plain Layout
2874 btUnit
2875 \end_layout
2876
2877 \end_inset
2878
2879 .
2880  Also, the 
2881 \begin_inset Flex Code
2882 status collapsed
2883
2884 \begin_layout Plain Layout
2885 btUnit
2886 \end_layout
2887
2888 \end_inset
2889
2890 s cannot be nested.
2891 \end_layout
2892
2893 \begin_layout Section
2894 Multipart Documents
2895 \end_layout
2896
2897 \begin_layout Subsection
2898 General Operation
2899 \end_layout
2900
2901 \begin_layout Standard
2902 When you are working on a large file with many sections, it is often convenient
2903  to break up the document into several files, or perhaps you have something
2904  where a table may change from time to time, but the preceding text does
2905  not.
2906  In these cases, you should seriously consider using multipart documents.
2907  For example, scientific papers often have five major sections: the introduction
2908 , observations, results, discussion, and conclusion.
2909  Each of these could be its own separate \SpecialChar LyX
2910  file, with one 
2911 \begin_inset Quotes eld
2912 \end_inset
2913
2914 master
2915 \begin_inset Quotes erd
2916 \end_inset
2917
2918  file which contains the title, authors, abstract, references, etc., plus
2919  the five included files.
2920  It is important to note that each of these files is a full \SpecialChar LyX
2921  file which
2922  can be formatted and printed on its own, as well as included in a master
2923  file.
2924  Each of these files must have the same document class, however—don't attempt
2925  to mix book classes with article classes.
2926  You may also include \SpecialChar LaTeX
2927  files; however, these files must not have their own
2928  preamble (i.
2929 \begin_inset space \thinspace{}
2930 \end_inset
2931
2932 e.
2933 \begin_inset space \space{}
2934 \end_inset
2935
2936 everything up to and including the 
2937 \begin_inset Flex Code
2938 status collapsed
2939
2940 \begin_layout Plain Layout
2941
2942 \backslash
2943 begin{document}
2944 \end_layout
2945
2946 \end_inset
2947
2948  line as well as the 
2949 \begin_inset Flex Code
2950 status collapsed
2951
2952 \begin_layout Plain Layout
2953
2954 \backslash
2955 end{document}
2956 \end_layout
2957
2958 \end_inset
2959
2960  line must be deleted) or else errors will be generated when you try to
2961  make a DVI file.
2962 \end_layout
2963
2964 \begin_layout Standard
2965 \SpecialChar LyX
2966  allows you to include files quite easily with 
2967 \begin_inset Flex Noun
2968 status collapsed
2969
2970 \begin_layout Plain Layout
2971 Insert\SpecialChar menuseparator
2972 ChiId
2973 \begin_inset space ~
2974 \end_inset
2975
2976 Document
2977 \end_layout
2978
2979 \end_inset
2980
2981 .
2982  When you click on this selection a small box is inserted into the file
2983  at the current cursor location.
2984  Clicking on the box raises a dialog which allows you to select the file
2985  to be included, and the method of its inclusion.
2986  
2987 \end_layout
2988
2989 \begin_layout Standard
2990 The file selection box should by now be obvious.
2991  The three inclusion methods are 
2992 \begin_inset Quotes eld
2993 \end_inset
2994
2995 include
2996 \begin_inset Quotes erd
2997 \end_inset
2998
2999
3000 \begin_inset Quotes eld
3001 \end_inset
3002
3003 input
3004 \begin_inset Quotes erd
3005 \end_inset
3006
3007 , and 
3008 \begin_inset Quotes eld
3009 \end_inset
3010
3011 verbatim
3012 \begin_inset Quotes erd
3013 \end_inset
3014
3015 .
3016  The difference between 
3017 \begin_inset Quotes eld
3018 \end_inset
3019
3020 include
3021 \begin_inset Quotes erd
3022 \end_inset
3023
3024  and 
3025 \begin_inset Quotes eld
3026 \end_inset
3027
3028 input
3029 \begin_inset Quotes erd
3030 \end_inset
3031
3032  is really only meaningful to \SpecialChar LaTeX
3033 perts, but the practical difference is that
3034  files that are 
3035 \begin_inset Quotes eld
3036 \end_inset
3037
3038 included
3039 \begin_inset Quotes erd
3040 \end_inset
3041
3042  are typeset beginning on a new page, while files that are 
3043 \begin_inset Quotes eld
3044 \end_inset
3045
3046 inputted
3047 \begin_inset Quotes erd
3048 \end_inset
3049
3050  are typeset starting on the current page.
3051 \end_layout
3052
3053 \begin_layout Standard
3054 Generally, the master file is converted into a full \SpecialChar LaTeX
3055  file before typesetting,
3056  while the included files are converted to \SpecialChar LaTeX
3057  files that do not have all the
3058  preamble information.
3059 \end_layout
3060
3061 \begin_layout Standard
3062
3063 \begin_inset Quotes eld
3064 \end_inset
3065
3066 verbatim
3067 \begin_inset Quotes erd
3068 \end_inset
3069
3070  included file allows you to include a file typeset exactly as it appears
3071  in the file, i.
3072 \begin_inset space \thinspace{}
3073 \end_inset
3074
3075 e.
3076 \begin_inset space \space{}
3077 \end_inset
3078
3079 in 
3080 \begin_inset Flex Code
3081 status collapsed
3082
3083 \begin_layout Plain Layout
3084 verbatim
3085 \end_layout
3086
3087 \end_inset
3088
3089  mode, with the characters set in a fixed-width typewriter font.
3090  Normally, spaces in this file are invisible, though two consecutive spaces
3091  are conserved, unlike \SpecialChar LyX
3092 's normal treatment of spaces.
3093  However, setting the 
3094 \begin_inset Flex Noun
3095 status collapsed
3096
3097 \begin_layout Plain Layout
3098 Mark
3099 \begin_inset space ~
3100 \end_inset
3101
3102 spaces
3103 \begin_inset space ~
3104 \end_inset
3105
3106 in
3107 \begin_inset space ~
3108 \end_inset
3109
3110 output
3111 \end_layout
3112
3113 \end_inset
3114
3115  checkbox typesets a mark to unambiguously define the presence of a space.
3116  
3117 \end_layout
3118
3119 \begin_layout Subsection
3120 Cross-References Between Files
3121 \end_layout
3122
3123 \begin_layout Standard
3124 \begin_inset Box Shadowbox
3125 position "t"
3126 hor_pos "c"
3127 has_inner_box 1
3128 inner_pos "t"
3129 use_parbox 0
3130 use_makebox 0
3131 width "100col%"
3132 special "none"
3133 height "1in"
3134 height_special "totalheight"
3135 thickness "0.4pt"
3136 separation "3pt"
3137 shadowsize "4pt"
3138 framecolor "black"
3139 backgroundcolor "none"
3140 status open
3141
3142 \begin_layout Plain Layout
3143 This section is somewhat out of date.
3144  Need to describe default master documents and how children are opened when
3145  the master is.
3146  [[FIXME]]
3147 \end_layout
3148
3149 \end_inset
3150
3151
3152 \end_layout
3153
3154 \begin_layout Standard
3155 It is possible to set up cross-references between the different files.
3156  First, open all the files in question: let's call them A and B in a two
3157  file example, where B is included in A.
3158  Let's say you insert a label in A, then want to reference it in B.
3159  Open the cross-reference dialog whilst in document B, and you can select
3160  the 
3161 \begin_inset Quotes eld
3162 \end_inset
3163
3164 buffer
3165 \begin_inset Quotes erd
3166 \end_inset
3167
3168  to use.
3169 \end_layout
3170
3171 \begin_layout Subsection
3172 Bibliography Lists in all Subdocuments
3173 \end_layout
3174
3175 \begin_layout Standard
3176 \begin_inset Box Frameless
3177 position "t"
3178 hor_pos "c"
3179 has_inner_box 1
3180 inner_pos "t"
3181 use_parbox 0
3182 use_makebox 0
3183 width "100col%"
3184 special "none"
3185 height "1in"
3186 height_special "totalheight"
3187 thickness "0.4pt"
3188 separation "3pt"
3189 shadowsize "4pt"
3190 framecolor "black"
3191 backgroundcolor "none"
3192 status open
3193
3194 \begin_layout Plain Layout
3195 This section also needs updating.
3196  There is now material about this on the wiki, and it could be copied here.
3197 \end_layout
3198
3199 \end_inset
3200
3201
3202 \end_layout
3203
3204 \begin_layout Standard
3205 Copy the bibliography list with all entries to all subdocuments and transform
3206  them to a comment.
3207  This way \SpecialChar LyX
3208  will find the 
3209 \begin_inset Flex Code
3210 status collapsed
3211
3212 \begin_layout Plain Layout
3213 .bib
3214 \end_layout
3215
3216 \end_inset
3217
3218 -files and you can easily insert references without making the bibliography
3219  list visible.
3220 \end_layout
3221
3222 \begin_layout Standard
3223 As the bibliography list is in a comment, \SpecialChar LaTeX
3224  won't use it and the references
3225  will look like this: [?], instead of like this: [1].
3226  One solution is to use the \SpecialChar LaTeX
3227 -package 
3228 \begin_inset Flex Code
3229 status collapsed
3230
3231 \begin_layout Plain Layout
3232 comment
3233 \end_layout
3234
3235 \end_inset
3236
3237  that will only include comments by processing the files separately.
3238  To do this, add in the \SpecialChar LaTeX
3239  preamble of every subdocument the following:
3240 \end_layout
3241
3242 \begin_layout LyX-Code
3243
3244 \backslash
3245 usepackage{comment}
3246 \end_layout
3247
3248 \begin_layout LyX-Code
3249
3250 \backslash
3251 includecomment{comment}
3252 \end_layout
3253
3254 \begin_layout Standard
3255 See also 
3256 \begin_inset Flex URL
3257 status collapsed
3258
3259 \begin_layout Plain Layout
3260
3261 http://wiki.lyx.org/FAQ/Unsorted#toc31
3262 \end_layout
3263
3264 \end_inset
3265
3266 .
3267 \end_layout
3268
3269 \begin_layout Section
3270 \SpecialChar LyX
3271  Archives
3272 \end_layout
3273
3274 \begin_layout Standard
3275 Users sometimes need to be able to 
3276 \begin_inset Quotes eld
3277 \end_inset
3278
3279 bundle
3280 \begin_inset Quotes erd
3281 \end_inset
3282
3283  a \SpecialChar LyX
3284  file together with all the images (and other files) on which it depends,
3285  either for sending to a publisher or for sharing with a co-author.
3286  \SpecialChar LyX
3287  2.0 includes a Python script (
3288 \begin_inset Flex Code
3289 status collapsed
3290
3291 \begin_layout Plain Layout
3292 lyxpak.py
3293 \end_layout
3294
3295 \end_inset
3296
3297 ) that automates this process.
3298  To use it, you must have either the 
3299 \begin_inset Flex Code
3300 status collapsed
3301
3302 \begin_layout Plain Layout
3303 zipfile
3304 \end_layout
3305
3306 \end_inset
3307
3308  or 
3309 \begin_inset Flex Code
3310 status collapsed
3311
3312 \begin_layout Plain Layout
3313 tarfile
3314 \end_layout
3315
3316 \end_inset
3317
3318  python modules installed on your system.
3319  By default, the script prefers the 
3320 \begin_inset Flex Code
3321 status collapsed
3322
3323 \begin_layout Plain Layout
3324 gzip
3325 \end_layout
3326
3327 \end_inset
3328
3329 -compressed 
3330 \begin_inset Flex Code
3331 status collapsed
3332
3333 \begin_layout Plain Layout
3334 tar
3335 \end_layout
3336
3337 \end_inset
3338
3339  format on Unix-like systems and the 
3340 \begin_inset Flex Code
3341 status collapsed
3342
3343 \begin_layout Plain Layout
3344 zip
3345 \end_layout
3346
3347 \end_inset
3348
3349  format on Windows.
3350 \end_layout
3351
3352 \begin_layout Standard
3353 \SpecialChar LyX
3354 's configuration process will set the script up to export a `\SpecialChar LyX
3355  Archive',
3356  and this format will then be available under 
3357 \begin_inset Flex Code
3358 status collapsed
3359
3360 \begin_layout Plain Layout
3361 File\SpecialChar menuseparator
3362 Export
3363 \end_layout
3364
3365 \end_inset
3366
3367 .
3368 \end_layout
3369
3370 \begin_layout Standard
3371 Independently of the platform, the generation of a particular archive format
3372  can be forced by adding either the 
3373 \begin_inset Flex Code
3374 status collapsed
3375
3376 \begin_layout Plain Layout
3377 -t
3378 \end_layout
3379
3380 \end_inset
3381
3382  (for the 
3383 \begin_inset Flex Code
3384 status collapsed
3385
3386 \begin_layout Plain Layout
3387 tar
3388 \end_layout
3389
3390 \end_inset
3391
3392  format) or 
3393 \begin_inset Flex Code
3394 status collapsed
3395
3396 \begin_layout Plain Layout
3397 -z
3398 \end_layout
3399
3400 \end_inset
3401
3402  (for the 
3403 \begin_inset Flex Code
3404 status collapsed
3405
3406 \begin_layout Plain Layout
3407 zip
3408 \end_layout
3409
3410 \end_inset
3411
3412  format) switch to the 
3413 \begin_inset Flex Code
3414 status collapsed
3415
3416 \begin_layout Plain Layout
3417 \SpecialChar LyX
3418 \SpecialChar menuseparator
3419 \SpecialChar LyX
3420  Archive
3421 \end_layout
3422
3423 \end_inset
3424
3425  converter in 
3426 \begin_inset Flex Code
3427 status collapsed
3428
3429 \begin_layout Plain Layout
3430 Tools\SpecialChar menuseparator
3431 Preferences\SpecialChar menuseparator
3432 File Handling\SpecialChar menuseparator
3433 Converters
3434 \end_layout
3435
3436 \end_inset
3437
3438 .
3439  (Make sure you add the switch after the script name, not before it.)
3440 \end_layout
3441
3442 \begin_layout Section
3443 Fancy Headers and Footers
3444 \end_layout
3445
3446 \begin_layout Standard
3447 The default page layout is rather plain; for an 
3448 \begin_inset Flex Code
3449 status collapsed
3450
3451 \begin_layout Plain Layout
3452 article
3453 \end_layout
3454
3455 \end_inset
3456
3457  document class, all you get is a centered page number at the bottom of
3458  the page.
3459  This document uses KOMA-script's book class, so it appears to be a bit
3460  fancier.
3461  But to really put on a show, you need to set the document page style to
3462  
3463 \begin_inset Quotes eld
3464 \end_inset
3465
3466 fancy
3467 \begin_inset Quotes erd
3468 \end_inset
3469
3470 , as mentioned in the 
3471 \emph on
3472 User Guide
3473 \emph default
3474 .
3475  This section describes the \SpecialChar LaTeX
3476  code you need to insert in your \SpecialChar LaTeX
3477  preamble in
3478  order to get the desired effects.
3479 \end_layout
3480
3481 \begin_layout Standard
3482 For more information on fancy headers, see the 
3483 \begin_inset Flex Code
3484 status collapsed
3485
3486 \begin_layout Plain Layout
3487 fancyhdr
3488 \end_layout
3489
3490 \end_inset
3491
3492  package documentation.
3493  (
3494 \begin_inset Flex URL
3495 status collapsed
3496
3497 \begin_layout Plain Layout
3498
3499 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
3500 \end_layout
3501
3502 \end_inset
3503
3504 )
3505 \end_layout
3506
3507 \begin_layout Standard
3508 The page header is divided into three fields, not surprisingly labeled 
3509 \begin_inset Quotes eld
3510 \end_inset
3511
3512 left
3513 \begin_inset Quotes erd
3514 \end_inset
3515
3516
3517 \begin_inset Quotes eld
3518 \end_inset
3519
3520 center
3521 \begin_inset Quotes erd
3522 \end_inset
3523
3524 , and 
3525 \begin_inset Quotes eld
3526 \end_inset
3527
3528 right
3529 \begin_inset Quotes erd
3530 \end_inset
3531
3532 .
3533  The footer is also divided into these three fields.
3534  The \SpecialChar LaTeX
3535  commands to set these fields in the simplest manner are 
3536 \begin_inset Flex Code
3537 status collapsed
3538
3539 \begin_layout Plain Layout
3540
3541 \backslash
3542 lhead
3543 \end_layout
3544
3545 \end_inset
3546
3547
3548 \begin_inset Flex Code
3549 status collapsed
3550
3551 \begin_layout Plain Layout
3552
3553 \backslash
3554 chead
3555 \end_layout
3556
3557 \end_inset
3558
3559
3560 \begin_inset Flex Code
3561 status collapsed
3562
3563 \begin_layout Plain Layout
3564
3565 \backslash
3566 rhead
3567 \end_layout
3568
3569 \end_inset
3570
3571
3572 \begin_inset Flex Code
3573 status collapsed
3574
3575 \begin_layout Plain Layout
3576
3577 \backslash
3578 lfoot
3579 \end_layout
3580
3581 \end_inset
3582
3583 , etc.
3584  Suppose you wish to put your name in the upper left hand corner of each
3585  page.
3586  Simply insert the following command in the preamble: 
3587 \end_layout
3588
3589 \begin_layout Standard
3590
3591 \family typewriter
3592
3593 \backslash
3594 lhead{John Q.
3595  DocWriter}
3596 \end_layout
3597
3598 \begin_layout Standard
3599 You will now see your name in the upper left.
3600  If a field has a default entry that you would like to get rid of (often
3601  the page number appears in the central footer) simply include a command
3602  with a blank argument, e.
3603 \begin_inset space \thinspace{}
3604 \end_inset
3605
3606 g.:
3607 \end_layout
3608
3609 \begin_layout Standard
3610
3611 \family typewriter
3612
3613 \backslash
3614 cfoot{}
3615 \end_layout
3616
3617 \begin_layout Standard
3618 Let's get really fancy: lets put the section number with the word 
3619 \begin_inset Quotes eld
3620 \end_inset
3621
3622 Section
3623 \begin_inset Quotes erd
3624 \end_inset
3625
3626  (e.
3627 \begin_inset space \thinspace{}
3628 \end_inset
3629
3630 g.
3631 \begin_inset space \space{}
3632 \end_inset
3633
3634 Section 3) in the upper left, the page number (e.
3635 \begin_inset space \thinspace{}
3636 \end_inset
3637
3638 g.
3639 \begin_inset space \space{}
3640 \end_inset
3641
3642 Page 4) in the upper right, your name in the lower left, and the date in
3643  the lower right.
3644  The following commands should now appear in the preamble:
3645 \end_layout
3646
3647 \begin_layout Standard
3648
3649 \family typewriter
3650
3651 \backslash
3652 lhead{Section 
3653 \backslash
3654 thesection}
3655 \end_layout
3656
3657 \begin_layout Standard
3658
3659 \family typewriter
3660
3661 \backslash
3662 chead{}
3663 \end_layout
3664
3665 \begin_layout Standard
3666
3667 \family typewriter
3668
3669 \backslash
3670 rhead{Page 
3671 \backslash
3672 thepage}
3673 \end_layout
3674
3675 \begin_layout Standard
3676
3677 \family typewriter
3678
3679 \backslash
3680 lfoot{John Q.
3681  DocWriter}
3682 \end_layout
3683
3684 \begin_layout Standard
3685
3686 \family typewriter
3687
3688 \backslash
3689 cfoot{}
3690 \end_layout
3691
3692 \begin_layout Standard
3693
3694 \family typewriter
3695
3696 \backslash
3697 rfoot{
3698 \backslash
3699 today}
3700 \end_layout
3701
3702 \begin_layout Standard
3703 The commands 
3704 \begin_inset Flex Code
3705 status collapsed
3706
3707 \begin_layout Plain Layout
3708
3709 \backslash
3710 thesection
3711 \end_layout
3712
3713 \end_inset
3714
3715  and 
3716 \begin_inset Flex Code
3717 status collapsed
3718
3719 \begin_layout Plain Layout
3720
3721 \backslash
3722 thepage
3723 \end_layout
3724
3725 \end_inset
3726
3727  access \SpecialChar LaTeX
3728 's section and page counters, and so print out the current section
3729  and page numbers.
3730  
3731 \begin_inset Flex Code
3732 status collapsed
3733
3734 \begin_layout Plain Layout
3735
3736 \backslash
3737 today
3738 \end_layout
3739
3740 \end_inset
3741
3742  simply prints out today's date.
3743 \end_layout
3744
3745 \begin_layout Standard
3746 The thicknesses of the horizontal rules drawn beneath the header and above
3747  the footer can also be modified.
3748  If you don't want one of the rules, set its thickness to 0.
3749  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
3750  Use commands
3751 \family typewriter
3752  
3753 \family default
3754 like 
3755 \begin_inset Flex Code
3756 status collapsed
3757
3758 \begin_layout Plain Layout
3759
3760 \backslash
3761 renewcommand{
3762 \backslash
3763 headrulewidth}{0.4pt}
3764 \end_layout
3765
3766 \end_inset
3767
3768  and 
3769 \begin_inset Flex Code
3770 status collapsed
3771
3772 \begin_layout Plain Layout
3773
3774 \backslash
3775 renewcommand{
3776 \backslash
3777 footrulewidth}{0.4pt}
3778 \end_layout
3779
3780 \end_inset
3781
3782  to set the thicknesses.
3783 \end_layout
3784
3785 \begin_layout Standard
3786 You can switch the header/footer settings on and off for individual pages
3787  using commands like 
3788 \begin_inset Flex Code
3789 status collapsed
3790
3791 \begin_layout Plain Layout
3792
3793 \backslash
3794 thispagestyle{empty}
3795 \end_layout
3796
3797 \end_inset
3798
3799
3800 \begin_inset Flex Code
3801 status collapsed
3802
3803 \begin_layout Plain Layout
3804
3805 \backslash
3806 thispagestyle{plain}
3807 \end_layout
3808
3809 \end_inset
3810
3811 , and 
3812 \begin_inset Flex Code
3813 status collapsed
3814
3815 \begin_layout Plain Layout
3816
3817 \backslash
3818 thispagestyle{fancy}
3819 \end_layout
3820
3821 \end_inset
3822
3823 .
3824  Simply insert them in the text on the page you want changed and mark them
3825  as \SpecialChar TeX
3826  code.
3827  In fact, title pages are marked as plain by default, while following pages
3828  are marked fancy when using the global fancy setting.
3829 \end_layout
3830
3831 \begin_layout Standard
3832 As a final example, it is possible to include an image in the header or
3833  footer.
3834  Suppose you want to put a company logo in the upper lefthand corner.
3835  You might try something like
3836 \end_layout
3837
3838 \begin_layout Standard
3839
3840 \family typewriter
3841
3842 \backslash
3843 lhead{
3844 \backslash
3845 resizebox{1in}{!}{
3846 \backslash
3847 includegraphics{logo.eps}}}
3848 \end_layout
3849
3850 \begin_layout Standard
3851 \noindent
3852 (you may need to preface this with 
3853 \begin_inset Flex Code
3854 status collapsed
3855
3856 \begin_layout Plain Layout
3857 \noindent
3858
3859 \backslash
3860 usepackage{graphics}
3861 \end_layout
3862
3863 \end_inset
3864
3865  if you don't include graphics elsewhere in your document).
3866 \end_layout
3867
3868 \begin_layout Section
3869 Itemize Bullet Selection
3870 \begin_inset CommandInset label
3871 LatexCommand label
3872 name "sec:bullet"
3873
3874 \end_inset
3875
3876
3877 \end_layout
3878
3879 \begin_layout Standard
3880 by
3881 \noun on
3882  Allan Rae
3883 \end_layout
3884
3885 \begin_layout Subsection
3886 Introduction
3887 \end_layout
3888
3889 \begin_layout Standard
3890 \SpecialChar LyX
3891  provides 216 bullet shapes that can be accessed from a simple dialog.
3892  Using this dialog you can easily specify what bullet shape to use at each
3893  level of an itemized list.
3894  These settings are document-wide so you won't be able to specify different
3895  sets of bullets for different paragraphs.
3896 \begin_inset Foot
3897 status collapsed
3898
3899 \begin_layout Plain Layout
3900 Well, actually you can but you'll have to do it by hand.
3901 \end_layout
3902
3903 \end_inset
3904
3905
3906 \end_layout
3907
3908 \begin_layout Subsection
3909 How it looks
3910 \end_layout
3911
3912 \begin_layout Standard
3913 Open the dialog by selecting the 
3914 \begin_inset Flex Noun
3915 status collapsed
3916
3917 \begin_layout Plain Layout
3918 Document\SpecialChar menuseparator
3919 Settings
3920 \end_layout
3921
3922 \end_inset
3923
3924  menu item and then select the 
3925 \begin_inset Flex Noun
3926 status collapsed
3927
3928 \begin_layout Plain Layout
3929 Bullets
3930 \end_layout
3931
3932 \end_inset
3933
3934  tab.
3935 \end_layout
3936
3937 \begin_layout Standard
3938 The dialog provides you with a table of bullet shapes.
3939  A column of buttons on the left of the table provides access to the six
3940  different panels of bullet shapes.
3941  The row of buttons across the top is used to select which bullet depth
3942  you are changing.
3943  A text entry under the table shows the currently selected bullet shape's
3944  \SpecialChar LaTeX
3945  equivalent and this can be edited if desired.
3946  If you do modify the text you will also need to specify any needed packages
3947  in the \SpecialChar LaTeX
3948  preamble.
3949 \end_layout
3950
3951 \begin_layout Standard
3952 The six panels are divided up by the packages they require.
3953  The following table shows the mappings from button name to \SpecialChar LaTeX
3954  package.
3955 \begin_inset Separator parbreak
3956 \end_inset
3957
3958
3959 \end_layout
3960
3961 \begin_layout Standard
3962 \align center
3963 \begin_inset Tabular
3964 <lyxtabular version="3" rows="7" columns="2">
3965 <features tabularvalignment="middle">
3966 <column alignment="center" valignment="top" width="0pt">
3967 <column alignment="center" valignment="top" width="0pt">
3968 <row>
3969 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3970 \begin_inset Text
3971
3972 \begin_layout Plain Layout
3973
3974 \family roman
3975 \series medium
3976 \shape up
3977 \size normal
3978 \emph off
3979 \bar no
3980 \noun off
3981 \color none
3982 Button
3983 \end_layout
3984
3985 \end_inset
3986 </cell>
3987 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3988 \begin_inset Text
3989
3990 \begin_layout Plain Layout
3991
3992 \family roman
3993 \series medium
3994 \shape up
3995 \size normal
3996 \emph off
3997 \bar no
3998 \noun off
3999 \color none
4000 Packages Required
4001 \end_layout
4002
4003 \end_inset
4004 </cell>
4005 </row>
4006 <row>
4007 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4008 \begin_inset Text
4009
4010 \begin_layout Plain Layout
4011
4012 \family sans
4013 \series medium
4014 \shape up
4015 \size normal
4016 \emph off
4017 \bar no
4018 \noun off
4019 \color none
4020 Standard
4021 \end_layout
4022
4023 \end_inset
4024 </cell>
4025 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4026 \begin_inset Text
4027
4028 \begin_layout Plain Layout
4029
4030 \series medium
4031 \shape up
4032 \size normal
4033 \emph off
4034 \bar no
4035 \noun off
4036 \color none
4037 base \SpecialChar LaTeX
4038
4039 \end_layout
4040
4041 \end_inset
4042 </cell>
4043 </row>
4044 <row>
4045 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4046 \begin_inset Text
4047
4048 \begin_layout Plain Layout
4049
4050 \family sans
4051 \series medium
4052 \shape up
4053 \size normal
4054 \emph off
4055 \bar no
4056 \noun off
4057 \color none
4058 Maths
4059 \end_layout
4060
4061 \end_inset
4062 </cell>
4063 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4064 \begin_inset Text
4065
4066 \begin_layout Plain Layout
4067
4068 \family typewriter
4069 \series medium
4070 \shape up
4071 \size normal
4072 \emph off
4073 \bar no
4074 \noun off
4075 \color none
4076 amssymb.sty
4077 \end_layout
4078
4079 \end_inset
4080 </cell>
4081 </row>
4082 <row>
4083 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4084 \begin_inset Text
4085
4086 \begin_layout Plain Layout
4087
4088 \family sans
4089 \series medium
4090 \shape up
4091 \size normal
4092 \emph off
4093 \bar no
4094 \noun off
4095 \color none
4096 Ding1
4097 \end_layout
4098
4099 \end_inset
4100 </cell>
4101 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4102 \begin_inset Text
4103
4104 \begin_layout Plain Layout
4105
4106 \family typewriter
4107 \series medium
4108 \shape up
4109 \size normal
4110 \emph off
4111 \bar no
4112 \noun off
4113 \color none
4114 pifont.sty
4115 \end_layout
4116
4117 \end_inset
4118 </cell>
4119 </row>
4120 <row>
4121 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4122 \begin_inset Text
4123
4124 \begin_layout Plain Layout
4125
4126 \family sans
4127 \series medium
4128 \shape up
4129 \size normal
4130 \emph off
4131 \bar no
4132 \noun off
4133 \color none
4134 Ding2
4135 \end_layout
4136
4137 \end_inset
4138 </cell>
4139 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4140 \begin_inset Text
4141
4142 \begin_layout Plain Layout
4143
4144 \family typewriter
4145 \series medium
4146 \shape up
4147 \size normal
4148 \emph off
4149 \bar no
4150 \noun off
4151 \color none
4152 pifont.sty
4153 \end_layout
4154
4155 \end_inset
4156 </cell>
4157 </row>
4158 <row>
4159 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4160 \begin_inset Text
4161
4162 \begin_layout Plain Layout
4163
4164 \family sans
4165 \series medium
4166 \shape up
4167 \size normal
4168 \emph off
4169 \bar no
4170 \noun off
4171 \color none
4172 Ding3
4173 \end_layout
4174
4175 \end_inset
4176 </cell>
4177 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4178 \begin_inset Text
4179
4180 \begin_layout Plain Layout
4181
4182 \family typewriter
4183 \series medium
4184 \shape up
4185 \size normal
4186 \emph off
4187 \bar no
4188 \noun off
4189 \color none
4190 pifont.sty
4191 \end_layout
4192
4193 \end_inset
4194 </cell>
4195 </row>
4196 <row>
4197 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4198 \begin_inset Text
4199
4200 \begin_layout Plain Layout
4201
4202 \family sans
4203 \series medium
4204 \shape up
4205 \size normal
4206 \emph off
4207 \bar no
4208 \noun off
4209 \color none
4210 Ding4
4211 \end_layout
4212
4213 \end_inset
4214 </cell>
4215 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4216 \begin_inset Text
4217
4218 \begin_layout Plain Layout
4219
4220 \family typewriter
4221 \series medium
4222 \shape up
4223 \size normal
4224 \emph off
4225 \bar no
4226 \noun off
4227 \color none
4228 pifont.sty
4229 \end_layout
4230
4231 \end_inset
4232 </cell>
4233 </row>
4234 </lyxtabular>
4235
4236 \end_inset
4237
4238
4239 \end_layout
4240
4241 \begin_layout Standard
4242 \SpecialChar LyX
4243  doesn't stop you using bullets from packages you don't have.
4244  If you get errors from \SpecialChar LaTeX
4245  when you try to view or print the file, then it
4246  is likely you are missing a package.
4247 \begin_inset Foot
4248 status collapsed
4249
4250 \begin_layout Plain Layout
4251 \SpecialChar LyX
4252  doesn't restrict your use since you may be editing locally and exporting
4253  elsewhere.
4254 \end_layout
4255
4256 \end_inset
4257
4258
4259 \end_layout
4260
4261 \begin_layout Subsection
4262 How to use it
4263 \end_layout
4264
4265 \begin_layout Standard
4266 Select which bullet depth you want to change then select the bullet shape
4267  and size.
4268  Any changes will not be visible in \SpecialChar LyX
4269 , but are visible when viewing the document.
4270 \end_layout
4271
4272 \begin_layout Standard
4273 You can reset a bullet shape to the default simply by clicking your right
4274  mouse button on the appropriate bullet depth button.
4275 \begin_inset Foot
4276 status collapsed
4277
4278 \begin_layout Plain Layout
4279 If you 
4280 \emph on
4281 really
4282 \emph default
4283  want to have multiple sets of paragraphs with different sets of bullets
4284  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
4285  code.
4286  The bullet selection dialog can help though because it provides you with
4287  the \SpecialChar LaTeX
4288  code for a wide range of bullet shapes.
4289  To make your own custom paragraphs you have the following options:
4290 \end_layout
4291
4292 \begin_layout Plain Layout
4293 \begin_inset ERT
4294 status open
4295
4296 \begin_layout Plain Layout
4297
4298
4299 \backslash
4300 let
4301 \backslash
4302 savelabelitemi=
4303 \backslash
4304 labelitemi
4305 \end_layout
4306
4307 \end_inset
4308
4309
4310 \end_layout
4311
4312 \begin_layout Plain Layout
4313 \begin_inset ERT
4314 status open
4315
4316 \begin_layout Plain Layout
4317
4318
4319 \backslash
4320 renewcommand
4321 \backslash
4322 labelitemi[0]{
4323 \backslash
4324 small
4325 \backslash
4326 (
4327 \backslash
4328 sharp
4329 \backslash
4330 )}
4331 \end_layout
4332
4333 \end_inset
4334
4335
4336 \end_layout
4337
4338 \begin_layout Itemize
4339 Use the \SpecialChar LaTeX
4340  command 
4341 \begin_inset Flex Code
4342 status collapsed
4343
4344 \begin_layout Plain Layout
4345
4346 \backslash
4347 renewcommand{}{}
4348 \end_layout
4349
4350 \end_inset
4351
4352  to specify a new bullet shape for a given depth.
4353  You'll also need to save the current bullet shape so you can restore it
4354  again afterwards.
4355  In this itemized list the following \SpecialChar LaTeX
4356  code was used to change the bullet
4357  used for the first depth.
4358 \begin_inset Separator parbreak
4359 \end_inset
4360
4361
4362 \end_layout
4363
4364 \begin_deeper
4365 \begin_layout LyX-Code
4366
4367 \backslash
4368 let
4369 \backslash
4370 savelabelitemi=
4371 \backslash
4372 labelitemi 
4373 \end_layout
4374
4375 \begin_layout LyX-Code
4376
4377 \backslash
4378 renewcommand
4379 \backslash
4380 labelitemi[0]{
4381 \backslash
4382 small
4383 \backslash
4384 (
4385 \backslash
4386 sharp
4387 \backslash
4388 )}
4389 \end_layout
4390
4391 \end_deeper
4392 \begin_layout Itemize
4393 Note that the itemize depth is specified in Roman numerals as part of the
4394  
4395 \family typewriter
4396
4397 \backslash
4398 labelitem
4399 \family default
4400  command.
4401 \end_layout
4402
4403 \begin_layout Itemize
4404 \begin_inset ERT
4405 status open
4406
4407 \begin_layout Plain Layout
4408
4409 [
4410 \backslash
4411 (
4412 \backslash
4413 star
4414 \backslash
4415 )]
4416 \end_layout
4417
4418 \end_inset
4419
4420  Specify each individual entry by starting each item with the bullet shape
4421  enclosed in square brackets and set as 
4422 \begin_inset Flex Noun
4423 status collapsed
4424
4425 \begin_layout Plain Layout
4426 \SpecialChar TeX
4427  Code
4428 \end_layout
4429
4430 \end_inset
4431
4432 .
4433  For example, this item was started with 
4434 \begin_inset Flex Code
4435 status collapsed
4436
4437 \begin_layout Plain Layout
4438 [
4439 \backslash
4440 (
4441 \backslash
4442 star
4443 \backslash
4444 )]
4445 \end_layout
4446
4447 \end_inset
4448
4449 .
4450 \end_layout
4451
4452 \begin_layout Plain Layout
4453 \begin_inset ERT
4454 status open
4455
4456 \begin_layout Plain Layout
4457
4458
4459 \backslash
4460 renewcommand
4461 \backslash
4462 labelitemi[0]{
4463 \backslash
4464 savelabelitemi}
4465 \end_layout
4466
4467 \end_inset
4468
4469
4470 \end_layout
4471
4472 \begin_layout Plain Layout
4473 You'll also need to revert the labelitem back to its previous setting for
4474  the global bullet shape settings to remain in effect.
4475  The way used here was:
4476 \end_layout
4477
4478 \begin_layout LyX-Code
4479
4480 \backslash
4481 renewcommand
4482 \backslash
4483 labelitemi[0]{
4484 \backslash
4485 savelabelitemi}
4486 \end_layout
4487
4488 \end_inset
4489
4490
4491 \end_layout
4492
4493 \begin_layout Chapter
4494 \SpecialChar LyX
4495  and the World Wide Web
4496 \end_layout
4497
4498 \begin_layout Standard
4499 \SpecialChar LyX
4500  has long supported the export of documents to various web-friendly formats,
4501  such as HTML.
4502  Before verson 2.0, however, HTML export was always accomplished by the use
4503  of external converters.
4504 \begin_inset Foot
4505 status collapsed
4506
4507 \begin_layout Plain Layout
4508 For details on the use of external converters with \SpecialChar LyX
4509 , see the 
4510 \emph on
4511 Converters
4512 \emph default
4513  section of the Customization manual.
4514 \end_layout
4515
4516 \end_inset
4517
4518  These fall into two large groups: there are converters that use \SpecialChar LaTeX
4519  as an
4520  intermediate format, such as 
4521 \begin_inset Flex Code
4522 status collapsed
4523
4524 \begin_layout Plain Layout
4525 htlatex
4526 \end_layout
4527
4528 \end_inset
4529
4530
4531 \begin_inset Flex Code
4532 status collapsed
4533
4534 \begin_layout Plain Layout
4535 html2latex
4536 \end_layout
4537
4538 \end_inset
4539
4540 , and 
4541 \begin_inset Flex Code
4542 status collapsed
4543
4544 \begin_layout Plain Layout
4545 plastex
4546 \end_layout
4547
4548 \end_inset
4549
4550 , relying upon \SpecialChar LyX
4551  to produce the \SpecialChar LaTeX
4552 ; and there is a converter that works directly
4553  on \SpecialChar LyX
4554  files, 
4555 \begin_inset Flex Code
4556 status collapsed
4557
4558 \begin_layout Plain Layout
4559 e\SpecialChar LyX
4560 er
4561 \end_layout
4562
4563 \end_inset
4564
4565 .
4566  All of these have different advantages and disadvantages.
4567  
4568 \end_layout
4569
4570 \begin_layout Standard
4571 The \SpecialChar LaTeX
4572 -based converters have the advantage that, in principle, they know everythin
4573 g about the exported document that \SpecialChar LaTeX
4574  does.
4575  Such converters do not care, for example, if a certain block of code was
4576  produced by \SpecialChar LyX
4577  or was Evil Red Text.
4578  These converters know about 
4579 \begin_inset Flex Code
4580 status collapsed
4581
4582 \begin_layout Plain Layout
4583 aux
4584 \end_layout
4585
4586 \end_inset
4587
4588  files, counters, and references, and can often make use of the 
4589 \begin_inset Flex Code
4590 status collapsed
4591
4592 \begin_layout Plain Layout
4593 bbl
4594 \end_layout
4595
4596 \end_inset
4597
4598  files generated by Bib\SpecialChar TeX
4599 .
4600  On the other hand, \SpecialChar LaTeX
4601  is a very hard language to parse—it is sometimes said
4602  that only \SpecialChar TeX
4603  itself understands \SpecialChar TeX
4604 —and \SpecialChar LaTeX
4605 -based converters will often choke on
4606  what seem to be quite simple constructs; complex ones can throw them completely
4607 , and as of this writing, for example, the 
4608 \emph on
4609 Embedded Objects
4610 \emph default
4611  manual will not export with 
4612 \begin_inset Flex Code
4613 status collapsed
4614
4615 \begin_layout Plain Layout
4616 htlatex
4617 \end_layout
4618
4619 \end_inset
4620
4621 , though the others will.
4622  The other issue concerns how math is handled.
4623  These converters typically convert the formulae into little pictures that
4624  are then linked from the HTML document.
4625  Since these are actually generated by \SpecialChar LaTeX
4626 , they are accurate.
4627  But they do not scale well, and just getting them to look as if they are
4628  actually meant to be in your document—so that the font sizes seem to be
4629  roughly the same—can be a challenge.
4630 \end_layout
4631
4632 \begin_layout Standard
4633 Alex Fernandez's 
4634 \begin_inset Flex Code
4635 status collapsed
4636
4637 \begin_layout Plain Layout
4638 e\SpecialChar LyX
4639 er
4640 \end_layout
4641
4642 \end_inset
4643
4644  (
4645 \begin_inset CommandInset href
4646 LatexCommand href
4647 name "http://elyxer.nongnu.org/"
4648 target "http://elyxer.nongnu.org/"
4649
4650 \end_inset
4651
4652 ) solves some of these problems.
4653  In particular, the formulae it produces scale perfectly, since it renders
4654  math using a combination of HTML and CSS rather than converting the formulae
4655  to images.
4656  But even moderately complex formula are rendered less well than with 
4657 \begin_inset Flex Code
4658 status collapsed
4659
4660 \begin_layout Plain Layout
4661 htlatex
4662 \end_layout
4663
4664 \end_inset
4665
4666 ; this reflects the limitations of HTML.
4667 \begin_inset Foot
4668 status collapsed
4669
4670 \begin_layout Plain Layout
4671 That said, 
4672 \begin_inset Flex Code
4673 status collapsed
4674
4675 \begin_layout Plain Layout
4676 e\SpecialChar LyX
4677 er
4678 \end_layout
4679
4680 \end_inset
4681
4682  can also use jsMath and MathJax for equations, but this setting is only
4683  available globally and requires one to have access to a server that runs
4684  the backend.
4685 \end_layout
4686
4687 \end_inset
4688
4689  More importantly (as of version 1.1.1, at least), 
4690 \begin_inset Flex Code
4691 status collapsed
4692
4693 \begin_layout Plain Layout
4694 e\SpecialChar LyX
4695 er
4696 \end_layout
4697
4698 \end_inset
4699
4700  has limited support for math macros and no support for user-defined paragraph
4701  or character styles.
4702  These limitations make 
4703 \begin_inset Flex Code
4704 status collapsed
4705
4706 \begin_layout Plain Layout
4707 e\SpecialChar LyX
4708 er
4709 \end_layout
4710
4711 \end_inset
4712
4713  unsuitable for many of the documents \SpecialChar LyX
4714  users produce.
4715  In principle, of course, these problems could be solved, but the \SpecialChar LyX
4716  developers
4717  have decided to follow a different path and have made \SpecialChar LyX
4718  itself capable of
4719  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
4720 , DocBook, and plaintext.
4721 \end_layout
4722
4723 \begin_layout Standard
4724 As of this writing, XHTML output remains under development and should probably
4725  be regarded as 
4726 \begin_inset Quotes eld
4727 \end_inset
4728
4729 experimental
4730 \begin_inset Quotes erd
4731 \end_inset
4732
4733 .
4734 \begin_inset Foot
4735 status collapsed
4736
4737 \begin_layout Plain Layout
4738 The file 
4739 \begin_inset Flex Code
4740 status collapsed
4741
4742 \begin_layout Plain Layout
4743 development/HTML.notes
4744 \end_layout
4745
4746 \end_inset
4747
4748 , which can be found in the \SpecialChar LyX
4749  source tree or 
4750 \begin_inset CommandInset href
4751 LatexCommand href
4752 name "accessed online"
4753 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
4754
4755 \end_inset
4756
4757 , usually contains up-to-date information about the state of XHTML output.
4758  See also the list of XHTML bugs on 
4759 \begin_inset CommandInset href
4760 LatexCommand href
4761 name "the bug tracker"
4762 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"
4763
4764 \end_inset
4765
4766 .
4767 \end_layout
4768
4769 \end_inset
4770
4771  Still, the developers have chosen this approach because it has several
4772  potential advantages over the other two.
4773 \end_layout
4774
4775 \begin_layout Standard
4776 These advantages are primarily due to the fact that the XHTML output routines,
4777  since they are part of \SpecialChar LyX
4778 , know everything \SpecialChar LyX
4779  knows about the document being
4780  exported.
4781 \begin_inset Foot
4782 status collapsed
4783
4784 \begin_layout Plain Layout
4785 Another advantage is that, since these routines are internal to \SpecialChar LyX
4786 , they are
4787  immune to changes in \SpecialChar LyX
4788 's file format, or to changes in the semantics of
4789  existing insets.
4790 \end_layout
4791
4792 \end_inset
4793
4794  So they know about the table of contents (as displayed in the outline),
4795  about the counters associated with different paragraph styles, and about
4796  user-defined styles.
4797  The XHTML output routines know what \SpecialChar LyX
4798  knows about internationalization,
4799  too, so they will output 
4800 \begin_inset Quotes eld
4801 \end_inset
4802
4803 Chapter 1
4804 \begin_inset Quotes erd
4805 \end_inset
4806
4807  or 
4808 \begin_inset Quotes eld
4809 \end_inset
4810
4811
4812 \lang ngerman
4813 Kapitel
4814 \lang english
4815  1
4816 \begin_inset Quotes erd
4817 \end_inset
4818
4819 , depending upon the language in effect at the time.
4820  
4821 \end_layout
4822
4823 \begin_layout Standard
4824 Quite generally, the output routines know what \SpecialChar LyX
4825  knows about document layout,
4826  that is, about how the document is to be rendered on screen.
4827  We use this information when we output the document as XHTML.
4828  In particular, \SpecialChar LyX
4829  
4830 \emph on
4831 automatically
4832 \emph default
4833  generates CSS style information corresponding to the layout information
4834  it uses to render the document on screen: if section headings are supposed
4835  to be sans-serif and bold as seen in \SpecialChar LyX
4836 , then (by default) they will be sans-seri
4837 f and bold when viewed in a web browser, too.
4838  And this is true not just for pre-defined styles, like Section, but for
4839  any style, including user-defined styles.
4840  Indeed, the XHTML output routines make no distinction between user-defined
4841  paragraph and character styles and \SpecialChar LyX
4842 's own pre-defined styles: in each case,
4843  everything \SpecialChar LyX
4844  knows about the styles is contained in the layout files.
4845  And much the same is true as regards pre-defined textual insets, such as
4846  footnotes, and various custom insets.
4847  
4848 \end_layout
4849
4850 \begin_layout Standard
4851 The result is that XHTML output can be customized and extended in exactly
4852  the same way \SpecialChar LaTeX
4853  output can be customized and extended: through layout files
4854  and modules.
4855  See chapter five of the 
4856 \emph on
4857 Customization 
4858 \emph default
4859 manual for the details.
4860 \end_layout
4861
4862 \begin_layout Standard
4863 The remainder of this chapter contains more detailed information on XHTML
4864  output, its limitations, and ways to work around those limitations.
4865 \end_layout
4866
4867 \begin_layout Section
4868 Math Output in XHTML
4869 \end_layout
4870
4871 \begin_layout Standard
4872 \SpecialChar LyX
4873  offers four choices for how math is rendered.
4874  These have various advantages and disadvantages:
4875 \end_layout
4876
4877 \begin_layout Itemize
4878 MathML
4879 \begin_inset Newline newline
4880 \end_inset
4881
4882 MathML is a dialect of XML designed specifically for mathematics on the
4883  web, and it typically renders very well in browsers that support it.
4884  The disadvantage is that not all browsers support MathML, and support is
4885  not complete even in the Gecko-based browsers, such as Firefox.
4886 \begin_inset Newline newline
4887 \end_inset
4888
4889 If \SpecialChar LyX
4890  is unable to render a formula as MathML—for example, if the formula
4891  uses the 
4892 \begin_inset Flex Code
4893 status collapsed
4894
4895 \begin_layout Plain Layout
4896 xymatrix
4897 \end_layout
4898
4899 \end_inset
4900
4901  package or ERT—then it will instead output the formula as an image.
4902  
4903 \end_layout
4904
4905 \begin_layout Itemize
4906 HTML
4907 \begin_inset Newline newline
4908 \end_inset
4909
4910 As mentioned above, 
4911 \begin_inset Flex Code
4912 status collapsed
4913
4914 \begin_layout Plain Layout
4915 elyxer
4916 \end_layout
4917
4918 \end_inset
4919
4920  outputs math as HTML, styled by CSS.
4921 \begin_inset Foot
4922 status collapsed
4923
4924 \begin_layout Plain Layout
4925 \SpecialChar LyX
4926  has borrowed some of the CSS for its HTML output from 
4927 \begin_inset Flex Code
4928 status collapsed
4929
4930 \begin_layout Plain Layout
4931 elyxer
4932 \end_layout
4933
4934 \end_inset
4935
4936 .
4937 \end_layout
4938
4939 \end_inset
4940
4941  For simple formulae, this can work quite well, though with more complicated
4942  formulae it tends to break down.
4943  Still, this method has the advantage that it is very widely supported and
4944  so it may be appropriate for documents that contain only a little, fairly
4945  simple math.
4946 \begin_inset Newline newline
4947 \end_inset
4948
4949 If Lyx is unable to render a formula as HTML—for example, if the formula
4950  uses the 
4951 \begin_inset Flex Code
4952 status collapsed
4953
4954 \begin_layout Plain Layout
4955 xymatrix
4956 \end_layout
4957
4958 \end_inset
4959
4960  package or ERT—then it will instead output the formula as an image.
4961  
4962 \end_layout
4963
4964 \begin_layout Itemize
4965 Images
4966 \begin_inset Newline newline
4967 \end_inset
4968
4969 Like 
4970 \begin_inset Flex Code
4971 status collapsed
4972
4973 \begin_layout Plain Layout
4974 htlatex
4975 \end_layout
4976
4977 \end_inset
4978
4979 , \SpecialChar LyX
4980  will output formulae as images, the very same images, in fact, that are
4981  used for instant preview.
4982 \begin_inset Foot
4983 status collapsed
4984
4985 \begin_layout Plain Layout
4986 Instant preview does 
4987 \emph on
4988 not 
4989 \emph default
4990 have to be on for images to be output, however.
4991 \end_layout
4992
4993 \end_inset
4994
4995  The advantage to this method is that the images are simply generated by
4996  \SpecialChar LaTeX
4997 , so they are very accurate.
4998  The disadvantage, as mentioned earlier, is that these are bitmapped images,
4999  so they do not scale terribly well, and one cannot copy them, etc.
5000  (As of this writing, there are also problems about equation numbering.
5001  See 
5002 \begin_inset CommandInset href
5003 LatexCommand href
5004 name "bug 6894"
5005 target "http://www.lyx.org/trac/ticket/6894"
5006
5007 \end_inset
5008
5009 .)
5010 \begin_inset Newline newline
5011 \end_inset
5012
5013 The size of the images can be controlled by setting the 
5014 \begin_inset Quotes eld
5015 \end_inset
5016
5017 Math Images Scaling
5018 \begin_inset Quotes erd
5019 \end_inset
5020
5021  parameter under 
5022 \begin_inset Flex Noun
5023 status collapsed
5024
5025 \begin_layout Plain Layout
5026 Document\SpecialChar menuseparator
5027 Settings\SpecialChar menuseparator
5028 Output
5029 \end_layout
5030
5031 \end_inset
5032
5033 .
5034 \begin_inset Foot
5035 status collapsed
5036
5037 \begin_layout Plain Layout
5038 For those who want to know, this controls the resolution of the image in
5039  dots per inch and is based upon a default of 75 dpi.
5040 \end_layout
5041
5042 \end_inset
5043
5044
5045 \begin_inset Newline newline
5046 \end_inset
5047
5048 If \SpecialChar LyX
5049  for some reason fails to create an image for a formula (e.g., if a required
5050  \SpecialChar LaTeX
5051  package is not installed), then it will fall back to outputing the raw
5052  \SpecialChar LaTeX
5053 .
5054 \end_layout
5055
5056 \begin_layout Itemize
5057 \SpecialChar LaTeX
5058
5059 \begin_inset Newline newline
5060 \end_inset
5061
5062 Finally, \SpecialChar LyX
5063  will happily output math as \SpecialChar LaTeX
5064 .
5065  As well as being the output of last resort, this method can be used with
5066  such tools as 
5067 \begin_inset CommandInset href
5068 LatexCommand href
5069 name "jsMath"
5070 target "http://www.math.union.edu/~dpvc/jsMath/"
5071
5072 \end_inset
5073
5074 , which uses JavaScript to render \SpecialChar LaTeX
5075  embedded in HTML documents.
5076  \SpecialChar LyX
5077  wraps the \SpecialChar LaTeX
5078  in either a 
5079 \begin_inset Flex Code
5080 status collapsed
5081
5082 \begin_layout Plain Layout
5083 span
5084 \end_layout
5085
5086 \end_inset
5087
5088  (for inline formulas) or 
5089 \begin_inset Flex Code
5090 status collapsed
5091
5092 \begin_layout Plain Layout
5093 div
5094 \end_layout
5095
5096 \end_inset
5097
5098  (for displayed formulas) with 
5099 \begin_inset Flex Code
5100 status collapsed
5101
5102 \begin_layout Plain Layout
5103 class='math'
5104 \end_layout
5105
5106 \end_inset
5107
5108 , as is required for jsMath.
5109 \end_layout
5110
5111 \begin_layout Standard
5112 One of these output methods must be selected under 
5113 \begin_inset Flex Noun
5114 status collapsed
5115
5116 \begin_layout Plain Layout
5117 Document\SpecialChar menuseparator
5118 Settings\SpecialChar menuseparator
5119 Output
5120 \end_layout
5121
5122 \end_inset
5123
5124 .
5125  By default, \SpecialChar LyX
5126  outputs MathML.
5127  This is a document-wide setting, therefore.
5128 \end_layout
5129
5130 \begin_layout Standard
5131 Eventually, \SpecialChar LyX
5132  will offer the user the option to select an alternate output
5133  method for a particular inset, say, one that isn't being rendered very
5134  well by MathML.
5135 \begin_inset Foot
5136 status collapsed
5137
5138 \begin_layout Plain Layout
5139 That said, since \SpecialChar LyX
5140  falls back to images if the inset contains ERT, then one
5141  can force output as an image by putting some harmless ERT into the math,
5142  for example: 
5143 \begin_inset Formula $a=b\relax$
5144 \end_inset
5145
5146 .
5147 \end_layout
5148
5149 \end_inset
5150
5151
5152 \end_layout
5153
5154 \begin_layout Section
5155 Bibliography and Citations
5156 \end_layout
5157
5158 \begin_layout Standard
5159 XHTML output fully supports bibliographies and citations.
5160  
5161 \end_layout
5162
5163 \begin_layout Standard
5164 Citation labels are generated by the same machinery that generates \SpecialChar LyX
5165 's on-screen
5166  labels, so the labels will look in the output much as they do in \SpecialChar LyX
5167 , though
5168  better.
5169  If you are using numerical citations, then \SpecialChar LyX
5170  will output numerical labels,
5171  such as [1] or [17], rather than simply showing the citation key in square
5172  brackets, as it does on-screen.
5173  If you are using author-year citations, then \SpecialChar LyX
5174  will add lowercase letters
5175  to the years, just as Bib\SpecialChar TeX
5176  does, if it finds more than one citation for
5177  a given author-year combination.
5178  The labels will be printed with the bibliography entries.
5179  Note that there is, at present, no way to customize the appearance of the
5180  labels, for example, to choose between square brackets and parentheses.
5181 \end_layout
5182
5183 \begin_layout Standard
5184 Bibliography output is handled by the same machinery that handles the presentati
5185 on of reference information in the citation dialog, so you will see in the
5186  XHTML output pretty much what you would see if you were to look at a given
5187  entry in the citation dialog.
5188  The formatting can be customized in your layout file or, preferably, in
5189  a module.
5190  See the 
5191 \emph on
5192 Customization
5193 \emph default
5194  manual for the details.
5195 \end_layout
5196
5197 \begin_layout Standard
5198 The main defect at present is that cross-referenced information is printed
5199  with every entry with which it is associated.
5200  So you can see things like this:
5201 \end_layout
5202
5203 \begin_layout Quote
5204 Jason Stanley, 
5205 \begin_inset Quotes eld
5206 \end_inset
5207
5208 Context and Logical Form
5209 \begin_inset Quotes erd
5210 \end_inset
5211
5212 , in 
5213 \emph on
5214 Language in Context: Selected Essays
5215 \emph default
5216  (Oxford: Oxford University Press, 2007), pp.
5217  30–68.
5218 \end_layout
5219
5220 \begin_layout Quote
5221 Jason Stanley, 
5222 \begin_inset Quotes eld
5223 \end_inset
5224
5225 Semantics in Context
5226 \begin_inset Quotes erd
5227 \end_inset
5228
5229 , in 
5230 \emph on
5231 Language in Context: Selected Essays
5232 \emph default
5233  (Oxford: Oxford University Press, 2007), pp.
5234  201–30.
5235 \end_layout
5236
5237 \begin_layout Standard
5238 This should be fixed before long.
5239 \end_layout
5240
5241 \begin_layout Standard
5242 There is no support at present for sectioned bibliographies.
5243  If you have multiple bibliographies, then \SpecialChar LyX
5244  will print the same bibliography
5245  over and over.
5246 \end_layout
5247
5248 \begin_layout Section
5249 Indexes
5250 \end_layout
5251
5252 \begin_layout Standard
5253 \SpecialChar LyX
5254  will happily export indexes as XHTML, but with certain limitations at the
5255  moment.
5256 \end_layout
5257
5258 \begin_layout Standard
5259 Index export will be most reliable when you do not attempt to use the fancy
5260  constructs that are described in the section on indexes in the 
5261 \emph on
5262 User's Guide
5263 \emph default
5264 .
5265 \begin_inset Foot
5266 status collapsed
5267
5268 \begin_layout Plain Layout
5269 The main issue here is that \SpecialChar LyX
5270  itself does not really handle these.
5271  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
5272 .
5273 \end_layout
5274
5275 \end_inset
5276
5277  We'll describe how they are handled using the subsection headings from
5278  that section.
5279 \end_layout
5280
5281 \begin_layout Itemize
5282 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
5283  makes an effort to support these,
5284  but the entries must be separated by 
5285 \begin_inset Quotes eld
5286 \end_inset
5287
5288  ! 
5289 \begin_inset Quotes erd
5290 \end_inset
5291
5292 , that is, there must be spaces around the exclamation point.
5293  This is because it is otherwise too difficult to check for escaped exclamation
5294  points, ones in math, and so forth.
5295 \end_layout
5296
5297 \begin_layout Itemize
5298 Page Ranges: There is no support at all for page ranges, since these make
5299  no sense with XHMTL.
5300  Instead, you will just get two index entries, one at either end.
5301 \end_layout
5302
5303 \begin_layout Itemize
5304 Cross-referencing: There is no support for cross-referencing.
5305  If \SpecialChar LyX
5306  finds an entry containing the 
5307 \begin_inset Quotes eld
5308 \end_inset
5309
5310 |see\SpecialChar ldots
5311
5312 \begin_inset Quotes erd
5313 \end_inset
5314
5315  construct, it is just dropped, and the rest is treated as an ordinary index
5316  entry.
5317 \end_layout
5318
5319 \begin_layout Itemize
5320 Index Entry Order: \SpecialChar LyX
5321  does support attempts to fix the sorting order.
5322  It will take what is before the first `@' it finds and use that for sorting,
5323  taking what follows the first `@' to be the actual entry.
5324  At present, \SpecialChar LyX
5325  does not check for escaped `@', so do not try to index email
5326  addresses.
5327 \end_layout
5328
5329 \begin_layout Itemize
5330 Index Entry Layout: You can format entries by using the text style dialog,
5331  or by using any other method available within \SpecialChar LyX
5332  itself.
5333  There is no support for constructs like: 
5334 \begin_inset Quotes eld
5335 \end_inset
5336
5337 entry|textbf
5338 \begin_inset Quotes erd
5339 \end_inset
5340
5341 .
5342  Indeed, if \SpecialChar LyX
5343  finds a pipe symbol, `|', in an entry, it will delete it and
5344  everything that follows it.
5345 \end_layout
5346
5347 \begin_layout Itemize
5348 Multiple Indexes: There is no support for multiple indexes.
5349  Rather, all index entries will be printed as one large index.
5350  To avoid our printing several versions of the index, we print only the
5351  main index, so make sure you have one.
5352 \end_layout
5353
5354 \begin_layout Section
5355 Nomenclature and Glossary
5356 \end_layout
5357
5358 \begin_layout Standard
5359 There is at present no support for glossaries.
5360  Adding it would be fairly trivial, and welcome.
5361 \end_layout
5362
5363 \begin_layout Chapter
5364 The \SpecialChar LyX
5365  Server
5366 \end_layout
5367
5368 \begin_layout Section
5369 Introduction
5370 \end_layout
5371
5372 \begin_layout Standard
5373 The `\SpecialChar LyX
5374  server' allows other programs to talk to \SpecialChar LyX
5375 , invoke \SpecialChar LyX
5376  commands, and retrieve
5377  information about the \SpecialChar LyX
5378  internal state.
5379  This is only intended for advanced users, but they should find it useful.
5380  It is by writing to the \SpecialChar LyX
5381  server, for example, that bibliography managers,
5382  such as JabRef, are able to 
5383 \begin_inset Quotes eld
5384 \end_inset
5385
5386 push
5387 \begin_inset Quotes erd
5388 \end_inset
5389
5390  citations to \SpecialChar LyX
5391 .
5392 \end_layout
5393
5394 \begin_layout Section
5395 Starting the \SpecialChar LyX
5396  Server
5397 \end_layout
5398
5399 \begin_layout Standard
5400 The \SpecialChar LyX
5401  server works through the use of a pair of named pipes.
5402  These are usually located in 
5403 \begin_inset Flex Code
5404 status collapsed
5405
5406 \begin_layout Plain Layout
5407 UserDir
5408 \end_layout
5409
5410 \end_inset
5411
5412 , (except on Windows, where 
5413 \emph on
5414 local
5415 \emph default
5416  named pipes are special objects located in 
5417 \begin_inset Flex Code
5418 status collapsed
5419
5420 \begin_layout Plain Layout
5421
5422 \backslash
5423
5424 \backslash
5425 .
5426 \backslash
5427 pipe
5428 \end_layout
5429
5430 \end_inset
5431
5432 ) and have the names 
5433 \begin_inset Quotes eld
5434 \end_inset
5435
5436
5437 \begin_inset Flex Code
5438 status collapsed
5439
5440 \begin_layout Plain Layout
5441 lyxpipe.in
5442 \end_layout
5443
5444 \end_inset
5445
5446
5447 \begin_inset Quotes erd
5448 \end_inset
5449
5450  and 
5451 \begin_inset Quotes eld
5452 \end_inset
5453
5454
5455 \begin_inset Flex Code
5456 status collapsed
5457
5458 \begin_layout Plain Layout
5459 lyxpipe.out
5460 \end_layout
5461
5462 \end_inset
5463
5464
5465 \begin_inset Quotes erd
5466 \end_inset
5467
5468 .
5469  External programs write into 
5470 \begin_inset Flex Code
5471 status collapsed
5472
5473 \begin_layout Plain Layout
5474 lyxpipe.in
5475 \end_layout
5476
5477 \end_inset
5478
5479  and read back data from 
5480 \begin_inset Flex Code
5481 status collapsed
5482
5483 \begin_layout Plain Layout
5484 lyxpipe.out
5485 \end_layout
5486
5487 \end_inset
5488
5489 .
5490  The stem of the pipe names can be defined in the 
5491 \begin_inset Flex Noun
5492 status collapsed
5493
5494 \begin_layout Plain Layout
5495 Tools\SpecialChar menuseparator
5496 Preferences
5497 \end_layout
5498
5499 \end_inset
5500
5501  dialog, for example 
5502 \begin_inset Flex Code
5503 status collapsed
5504
5505 \begin_layout Plain Layout
5506 "/home/myhome/lyxpipe"
5507 \end_layout
5508
5509 \end_inset
5510
5511 , or 
5512 \begin_inset Flex Code
5513 status collapsed
5514
5515 \begin_layout Plain Layout
5516 "
5517 \backslash
5518
5519 \backslash
5520 .
5521 \backslash
5522 pipe
5523 \backslash
5524 lyxpipe"
5525 \end_layout
5526
5527 \end_inset
5528
5529  on Windows (where any working path instead of lyxpipe can be used, for
5530  example 
5531 \begin_inset Flex Code
5532 status collapsed
5533
5534 \begin_layout Plain Layout
5535 "
5536 \backslash
5537
5538 \backslash
5539 .
5540 \backslash
5541 pipe
5542 \backslash
5543 my
5544 \backslash
5545 lyx
5546 \backslash
5547 pipe"
5548 \end_layout
5549
5550 \end_inset
5551
5552  would also work).
5553  You 
5554 \emph on
5555 must
5556 \emph default
5557  configure this manually in order for the server to start.
5558 \end_layout
5559
5560 \begin_layout Standard
5561 \SpecialChar LyX
5562  will add the '
5563 \begin_inset Flex Code
5564 status collapsed
5565
5566 \begin_layout Plain Layout
5567 .in
5568 \end_layout
5569
5570 \end_inset
5571
5572 ' and '
5573 \begin_inset Flex Code
5574 status collapsed
5575
5576 \begin_layout Plain Layout
5577 .out
5578 \end_layout
5579
5580 \end_inset
5581
5582 ' to create the pipes.
5583  If one of the pipes already exists, \SpecialChar LyX
5584  will assume that another \SpecialChar LyX
5585  process
5586  is already running and will not start the server.
5587  On POSIX (Unix like) systems, if for some other reason, an unused 
5588 \begin_inset Quotes eld
5589 \end_inset
5590
5591 stale
5592 \begin_inset Quotes erd
5593 \end_inset
5594
5595  pipe is left in existence when \SpecialChar LyX
5596  closes, then \SpecialChar LyX
5597  will try to delete it.
5598  If this fails for some reason, you will need to delete the pipes manually
5599  and then restart \SpecialChar LyX
5600 .
5601  On Windows, pipes are deleted by the OS on program termination or crash,
5602  so 
5603 \begin_inset Quotes eld
5604 \end_inset
5605
5606 stale
5607 \begin_inset Quotes erd
5608 \end_inset
5609
5610  pipes should not be possible.
5611 \end_layout
5612
5613 \begin_layout Standard
5614 To have several \SpecialChar LyX
5615  processes with servers at the same time, you have to use
5616  different configurations, perhaps by using separate user directories, each
5617  with its own 
5618 \begin_inset Flex Code
5619 status collapsed
5620
5621 \begin_layout Plain Layout
5622 preferences
5623 \end_layout
5624
5625 \end_inset
5626
5627  file, for each process.
5628 \end_layout
5629
5630 \begin_layout Standard
5631 If you are developing a client program, you might find it useful to enable
5632  debugging information from the \SpecialChar LyX
5633  server.
5634  Do this by starting \SpecialChar LyX
5635  as 
5636 \begin_inset Flex Code
5637 status collapsed
5638
5639 \begin_layout Plain Layout
5640 lyx -dbg lyxserver
5641 \end_layout
5642
5643 \end_inset
5644
5645 .
5646 \end_layout
5647
5648 \begin_layout Standard
5649 You can find a complete example client written in C++ in the source distribution
5650  as 
5651 \begin_inset Flex Code
5652 status collapsed
5653
5654 \begin_layout Plain Layout
5655 development/lyxserver/server_monitor.cpp
5656 \end_layout
5657
5658 \end_inset
5659
5660 .
5661 \end_layout
5662
5663 \begin_layout Standard
5664 Another useful tool is the command-line based client found in 
5665 \begin_inset Flex Code
5666 status collapsed
5667
5668 \begin_layout Plain Layout
5669 src/client/lyxclient
5670 \end_layout
5671
5672 \end_inset
5673
5674 .
5675 \end_layout
5676
5677 \begin_layout Section
5678 Normal communication
5679 \end_layout
5680
5681 \begin_layout Standard
5682 To issue a \SpecialChar LyX
5683  call, the client writes a line of ASCII text into the input
5684  pipe.
5685  This line has the following format:
5686 \end_layout
5687
5688 \begin_layout Quote
5689 LYXCMD:
5690 \emph on
5691 clientname
5692 \emph default
5693 :
5694 \emph on
5695 function
5696 \emph default
5697 :
5698 \emph on
5699 argument
5700 \end_layout
5701
5702 \begin_layout Description
5703 clientname is a name that the client can choose arbitrarily.
5704  Its only use is that \SpecialChar LyX
5705  will echo it if it sends an answer—so a client can
5706  dispatch results from different requesters.
5707 \end_layout
5708
5709 \begin_layout Description
5710 function is the function you want \SpecialChar LyX
5711  to perform.
5712  It is the same as the commands you'd use in the minibuffer.
5713 \end_layout
5714
5715 \begin_layout Description
5716 argument is an optional argument which is meaningful only to some functions
5717  (for instance, the 
5718 \begin_inset Quotes eld
5719 \end_inset
5720
5721 self-insert
5722 \begin_inset Quotes erd
5723 \end_inset
5724
5725  LFUN will insert the argument as text at the cursor position).
5726 \end_layout
5727
5728 \begin_layout Standard
5729 The answer from \SpecialChar LyX
5730  will arrive in the output pipe and be of the form
5731 \end_layout
5732
5733 \begin_layout Quote
5734 INFO:
5735 \emph on
5736 clientname
5737 \emph default
5738 :
5739 \emph on
5740 function
5741 \emph default
5742 :
5743 \emph on
5744 data
5745 \end_layout
5746
5747 \begin_layout Standard
5748 where 
5749 \emph on
5750 clientname
5751 \emph default
5752  and 
5753 \emph on
5754 function
5755 \emph default
5756  are just echoed from the command request, while 
5757 \emph on
5758 data
5759 \emph default
5760  is more or less useful information filled according to how the command
5761  execution worked out.
5762  Some commands, such as 
5763 \begin_inset Quotes eld
5764 \end_inset
5765
5766 font-state
5767 \begin_inset Quotes erd
5768 \end_inset
5769
5770 , will return information about the internal state of \SpecialChar LyX
5771 , while other will
5772  return an empty data-response.
5773  This means that the command execution went fine.
5774 \end_layout
5775
5776 \begin_layout Standard
5777 In case of errors, the response from \SpecialChar LyX
5778  will have this form
5779 \end_layout
5780
5781 \begin_layout Quote
5782 ERROR:
5783 \emph on
5784 clientname
5785 \emph default
5786 :
5787 \emph on
5788 function
5789 \emph default
5790 :
5791 \emph on
5792 error message
5793 \end_layout
5794
5795 \begin_layout Standard
5796 where the 
5797 \emph on
5798 error message
5799 \emph default
5800  should contain an explanation of why the command failed.
5801 \end_layout
5802
5803 \begin_layout Standard
5804 Examples:
5805 \end_layout
5806
5807 \begin_layout LyX-Code
5808 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
5809 \begin_inset Newline newline
5810 \end_inset
5811
5812 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
5813 \begin_inset Newline newline
5814 \end_inset
5815
5816 read a <~/.lyxpipe.out
5817 \begin_inset Newline newline
5818 \end_inset
5819
5820 echo $a
5821 \end_layout
5822
5823 \begin_layout Subsection
5824 AppleScript (Mac OS X)
5825 \end_layout
5826
5827 \begin_layout Standard
5828 Since \SpecialChar LyX
5829  2.1, \SpecialChar LyX
5830  supports basic interactions with AppleScript for normal communicatio
5831 n through the command run.
5832  This command takes a direct argument (the 
5833 \series bold
5834 function
5835 \series default
5836  to perform) and an optional argument.
5837  It either returns the output of the function or triggers an error with
5838  the error message and code.
5839 \end_layout
5840
5841 \begin_layout Standard
5842 Example:
5843 \end_layout
5844
5845 \begin_layout LyX-Code
5846 tell application "\SpecialChar LyX
5847 "
5848 \end_layout
5849
5850 \begin_layout LyX-Code
5851   try
5852 \end_layout
5853
5854 \begin_layout LyX-Code
5855     -- Stores the current file name into f
5856 \end_layout
5857
5858 \begin_layout LyX-Code
5859     set f to (run "server-get-filename" with argument "")
5860 \end_layout
5861
5862 \begin_layout LyX-Code
5863     on error the error_message number the error_number
5864 \end_layout
5865
5866 \begin_layout LyX-Code
5867       display dialog "Error: " & the error_number & ".
5868  " ¬
5869 \end_layout
5870
5871 \begin_layout LyX-Code
5872               & the error_message buttons {"OK"} default button 1
5873 \end_layout
5874
5875 \begin_layout LyX-Code
5876   end try
5877 \end_layout
5878
5879 \begin_layout LyX-Code
5880 end tell
5881 \end_layout
5882
5883 \begin_layout Section
5884 Notification
5885 \end_layout
5886
5887 \begin_layout Standard
5888 \SpecialChar LyX
5889  can notify clients of events going on asynchronously.
5890  Currently it will only do this if the user binds a key sequence with the
5891  function 
5892 \begin_inset Quotes eld
5893 \end_inset
5894
5895 notify
5896 \begin_inset Quotes erd
5897 \end_inset
5898
5899 .
5900  The format of the string \SpecialChar LyX
5901  sends is as follows:
5902 \end_layout
5903
5904 \begin_layout Quote
5905 \begin_inset Flex Code
5906 status collapsed
5907
5908 \begin_layout Plain Layout
5909 NOTIFY:
5910 \end_layout
5911
5912 \end_inset
5913
5914
5915 \emph on
5916 key-sequence
5917 \end_layout
5918
5919 \begin_layout Standard
5920 where 
5921 \emph on
5922 key-sequence
5923 \emph default
5924  is the printed representation of the key sequence that was actually typed
5925  by the user.
5926 \end_layout
5927
5928 \begin_layout Standard
5929 This mechanism can be used to extend \SpecialChar LyX
5930 's command set and implement macros.
5931  Bind some key sequence to 
5932 \begin_inset Quotes eld
5933 \end_inset
5934
5935 notify
5936 \begin_inset Quotes erd
5937 \end_inset
5938
5939 .
5940  Then start a client that listens on the output pipe, dispatches the command
5941  according to the sequence, and starts a function that may use \SpecialChar LyX
5942  calls and
5943  \SpecialChar LyX
5944  requests to issue a command or a series of commands to \SpecialChar LyX
5945 .
5946 \end_layout
5947
5948 \begin_layout Section
5949 The simple \SpecialChar LyX
5950  Server Protocol
5951 \end_layout
5952
5953 \begin_layout Standard
5954 \SpecialChar LyX
5955  implements a simple protocol that can be used for session management.
5956  All messages are of the form
5957 \end_layout
5958
5959 \begin_layout Quote
5960 LYXSRV:
5961 \emph on
5962 clientname
5963 \emph default
5964 :
5965 \emph on
5966 protocol message
5967 \end_layout
5968
5969 \begin_layout Standard
5970 where 
5971 \emph on
5972 protocol message
5973 \emph default
5974  can be 
5975 \begin_inset Quotes eld
5976 \end_inset
5977
5978 hello
5979 \begin_inset Quotes erd
5980 \end_inset
5981
5982  or 
5983 \begin_inset Quotes eld
5984 \end_inset
5985
5986 bye
5987 \begin_inset Quotes erd
5988 \end_inset
5989
5990 .
5991  If 
5992 \begin_inset Quotes eld
5993 \end_inset
5994
5995 hello
5996 \begin_inset Quotes erd
5997 \end_inset
5998
5999  is received from a client, \SpecialChar LyX
6000  will report back to inform the client that
6001  it's listening to it's messages, while 
6002 \begin_inset Quotes eld
6003 \end_inset
6004
6005 bye
6006 \begin_inset Quotes erd
6007 \end_inset
6008
6009  sent from \SpecialChar LyX
6010  will inform clients that \SpecialChar LyX
6011  is closing.
6012 \end_layout
6013
6014 \begin_layout Section
6015 Reverse DVI/PDF search
6016 \end_layout
6017
6018 \begin_layout Standard
6019 Some DVI/PDF viewers
6020 \begin_inset Foot
6021 status collapsed
6022
6023 \begin_layout Plain Layout
6024 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
6025  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
6026 \end_layout
6027
6028 \end_inset
6029
6030  provide 
6031 \emph on
6032 reverse search
6033 \emph default
6034  facility (also called 
6035 \emph on
6036 inverse search
6037 \emph default
6038 ).
6039  This means that you can tell \SpecialChar LyX
6040  to put the cursor to a specific line in the
6041  document by clicking at the respective position in the DVI/PDF output.
6042  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
6043 .
6044  This is done via the \SpecialChar LyX
6045  server either by using the named pipe (
6046 \emph on
6047 lyxpipe
6048 \emph default
6049 ), or the UNIX domain socket (
6050 \emph on
6051 lyxsocket
6052 \emph default
6053 ) that \SpecialChar LyX
6054  creates in its temporary directory (this is the way the 
6055 \begin_inset Flex Code
6056 status collapsed
6057
6058 \begin_layout Plain Layout
6059 lyxclient
6060 \end_layout
6061
6062 \end_inset
6063
6064  program communicates with \SpecialChar LyX
6065 ).
6066  In some cases, you need a helper script that mediates between the viewer
6067  and \SpecialChar LyX
6068 , in others, the viewer can communicate with \SpecialChar LyX
6069  directly.
6070  This depends on the selected viewer and on your operating system.
6071  The same applies to the way viewers need to be configured and the way the
6072  reverse search is actually performed.
6073  In what follows, we will thus describe how to setup reverse search for
6074  specific viewers.
6075  Before we turn to this, though, we will explain what needs to be done generally
6076  to enable reverse search in the DVI/PDF output.
6077 \end_layout
6078
6079 \begin_layout Subsection
6080 Automatic setup
6081 \begin_inset CommandInset label
6082 LatexCommand label
6083 name "subsec:rev-search"
6084
6085 \end_inset
6086
6087
6088 \end_layout
6089
6090 \begin_layout Standard
6091 In most cases \SpecialChar LyX
6092  will do the work for you by enabling the option 
6093 \begin_inset Flex Noun
6094 status collapsed
6095
6096 \begin_layout Plain Layout
6097 Synchronize with Output
6098 \end_layout
6099
6100 \end_inset
6101
6102  in the menu 
6103 \begin_inset Flex Noun
6104 status collapsed
6105
6106 \begin_layout Plain Layout
6107 Document\SpecialChar menuseparator
6108 Settings\SpecialChar menuseparator
6109 Output
6110 \end_layout
6111
6112 \end_inset
6113
6114 .
6115  In such a case \SpecialChar LyX
6116  will automatically insert the necessary Sync\SpecialChar TeX
6117  macro (for
6118  PDF) or load the srcltx package (for DVI) respectively.
6119  This option can be easily reached also on 
6120 \begin_inset Flex Code
6121 status collapsed
6122
6123 \begin_layout Plain Layout
6124 View/Update
6125 \end_layout
6126
6127 \end_inset
6128
6129  Toolbar.
6130 \end_layout
6131
6132 \begin_layout Standard
6133 If you need a different setting, you can select or input a custom macro
6134  from the drop down box just below 
6135 \begin_inset Flex Noun
6136 status collapsed
6137
6138 \begin_layout Plain Layout
6139 Document\SpecialChar menuseparator
6140 Settings\SpecialChar menuseparator
6141 Output\SpecialChar menuseparator
6142 Synchronize with Output
6143 \end_layout
6144
6145 \end_inset
6146
6147 .
6148 \end_layout
6149
6150 \begin_layout Standard
6151 Note that the method 
6152 \begin_inset Flex Code
6153 status collapsed
6154
6155 \begin_layout Plain Layout
6156
6157 \backslash
6158 synctex=1
6159 \end_layout
6160
6161 \end_inset
6162
6163  enables gzip compression.
6164  If your viewer does not support it, you should instead use 
6165 \begin_inset Flex Code
6166 status collapsed
6167
6168 \begin_layout Plain Layout
6169
6170 \backslash
6171 synctex=-1
6172 \end_layout
6173
6174 \end_inset
6175
6176 .
6177 \end_layout
6178
6179 \begin_layout Standard
6180 Please also note that including the 
6181 \begin_inset Flex Code
6182 status collapsed
6183
6184 \begin_layout Plain Layout
6185 srcltx
6186 \end_layout
6187
6188 \end_inset
6189
6190  package or 
6191 \begin_inset Flex Code
6192 status collapsed
6193
6194 \begin_layout Plain Layout
6195 src-specials
6196 \end_layout
6197
6198 \end_inset
6199
6200  sometimes has an undesired impact on the typesetting.
6201  Thus, you should switch output synchronization off for the final typesetting
6202  if you use the 
6203 \begin_inset Flex Code
6204 status collapsed
6205
6206 \begin_layout Plain Layout
6207 srcltx
6208 \end_layout
6209
6210 \end_inset
6211
6212  package or 
6213 \begin_inset Flex Code
6214 status collapsed
6215
6216 \begin_layout Plain Layout
6217 src-specials
6218 \end_layout
6219
6220 \end_inset
6221
6222 .
6223  
6224 \end_layout
6225
6226 \begin_layout Standard
6227 In case you need some more special settings that are not covered by the
6228  automatic settings, read the next section about how to set up output synchroniz
6229 ation manually.
6230  If the automatic setup suits your needs, you can readily jump to section
6231 \begin_inset space ~
6232 \end_inset
6233
6234
6235 \begin_inset CommandInset ref
6236 LatexCommand ref
6237 reference "subsec:configuring-viewers"
6238
6239 \end_inset
6240
6241 , where the necessary configuration steps in your viewer – needed both with
6242  the automatic and the manual setup – are described.
6243 \end_layout
6244
6245 \begin_layout Subsection
6246 Manual setup
6247 \end_layout
6248
6249 \begin_layout Standard
6250 \SpecialChar LaTeX
6251  provides several different methods for reverse search.
6252  Some are built-in in the 
6253 \begin_inset Flex Code
6254 status collapsed
6255
6256 \begin_layout Plain Layout
6257 latex/pdflatex
6258 \end_layout
6259
6260 \end_inset
6261
6262  program, some are provided by external packages.
6263  Your choice depends on whether your \SpecialChar LaTeX
6264  distribution already provides a given
6265  method (the built-in methods are rather new) and whether your viewer can
6266  cope with it.
6267  The available methods are described in the following.
6268 \end_layout
6269
6270 \begin_layout Subsubsection*
6271 Built-in DVI-search via src-specials (DVI only) 
6272 \end_layout
6273
6274 \begin_layout Standard
6275 This method provides the DVI file with the necessary information for reverse
6276  search.
6277  It is available in \SpecialChar LaTeX
6278  since quite some time (any somewhat recent \SpecialChar LaTeX
6279  distribution
6280  should include it), and it works reliably.
6281  To enable it, change the 
6282 \begin_inset Flex Noun
6283 status collapsed
6284
6285 \begin_layout Plain Layout
6286 La
6287 \family sans
6288 TeX
6289 \family default
6290  (plain)->DVI
6291 \end_layout
6292
6293 \end_inset
6294
6295  or 
6296 \begin_inset Flex Noun
6297 status collapsed
6298
6299 \begin_layout Plain Layout
6300 La
6301 \family sans
6302 TeX
6303 \family default
6304  (plain)->DraftDVI
6305 \end_layout
6306
6307 \end_inset
6308
6309  converter in 
6310 \begin_inset Flex Noun
6311 status collapsed
6312
6313 \begin_layout Plain Layout
6314 Preferences\SpecialChar menuseparator
6315 File Handling\SpecialChar menuseparator
6316 Converters
6317 \end_layout
6318
6319 \end_inset
6320
6321  to 
6322 \begin_inset Flex Code
6323 status collapsed
6324
6325 \begin_layout Plain Layout
6326 latex -src-specials $$i
6327 \end_layout
6328
6329 \end_inset
6330
6331 .
6332  If this doesn't work, check if your \SpecialChar TeX
6333  engine needs different options (the
6334  syntax might differ in some distributions).
6335 \end_layout
6336
6337 \begin_layout Subsubsection*
6338 External Packages (PDFSync and scrltx) 
6339 \end_layout
6340
6341 \begin_layout Standard
6342 The packages 
6343 \emph on
6344 pdfsync
6345 \emph default
6346  and 
6347 \emph on
6348 scrltx
6349 \emph default
6350  provide reverse search facility for PDF output (via pdflatex) and DVI output,
6351  respectively.
6352  In order to enable it, load the packages in the \SpecialChar LyX
6353  preamble: 
6354 \end_layout
6355
6356 \begin_layout Itemize
6357 \begin_inset Flex Code
6358 status collapsed
6359
6360 \begin_layout Plain Layout
6361
6362 \backslash
6363 usepackage{pdfsync}
6364 \end_layout
6365
6366 \end_inset
6367
6368  for reverse PDF search,
6369 \end_layout
6370
6371 \begin_layout Itemize
6372 \begin_inset Flex Code
6373 status collapsed
6374
6375 \begin_layout Plain Layout
6376
6377 \backslash
6378 usepackage[active]{srcltx}
6379 \end_layout
6380
6381 \end_inset
6382
6383  for reverse DVI search.
6384 \end_layout
6385
6386 \begin_layout Standard
6387 If you want to be able to perform both DVI and PDF reverse searches, you
6388  can also insert in the preamble the following lines
6389 \end_layout
6390
6391 \begin_layout LyX-Code
6392
6393 \backslash
6394 usepackage{ifpdf}
6395 \begin_inset Newline newline
6396 \end_inset
6397
6398
6399 \backslash
6400 ifpdf
6401 \begin_inset Newline newline
6402 \end_inset
6403
6404   
6405 \backslash
6406 usepackage{pdfsync}
6407 \begin_inset Newline newline
6408 \end_inset
6409
6410
6411 \backslash
6412 else
6413 \begin_inset Newline newline
6414 \end_inset
6415
6416   
6417 \backslash
6418 usepackage[active]{srcltx}
6419 \begin_inset Newline newline
6420 \end_inset
6421
6422
6423 \backslash
6424 fi
6425 \end_layout
6426
6427 \begin_layout Standard
6428 This way, you can preview the file as either DVI or PDF (pdflatex) and the
6429  right package will be used.
6430 \end_layout
6431
6432 \begin_layout Standard
6433 Note that PDFSync might affect the output layout of your document.
6434  It is therefore advised to disable PDFsync for final documents.
6435 \end_layout
6436
6437 \begin_layout Subsubsection*
6438 Built-in reverse search via Sync\SpecialChar TeX
6439  (DVI and PDF) 
6440 \end_layout
6441
6442 \begin_layout Standard
6443 Recent versions of 
6444 \begin_inset Flex Code
6445 status collapsed
6446
6447 \begin_layout Plain Layout
6448 (pdf)latex
6449 \end_layout
6450
6451 \end_inset
6452
6453  have built-in support for both PDF and DVI reverse search.
6454  This so-called 
6455 \emph on
6456 Sync\SpecialChar TeX
6457
6458 \emph default
6459  facility is basically the result of the integration of the PDFSync package
6460  to the pdftex program and its merge with the 
6461 \emph on
6462 scr-specials
6463 \emph default
6464  approach.
6465  You need at least \SpecialChar TeX
6466 Live 2008 or a recent Mik\SpecialChar TeX
6467  distribution in order to use
6468  it.
6469 \begin_inset Foot
6470 status collapsed
6471
6472 \begin_layout Plain Layout
6473 For some reason, Mik\SpecialChar TeX
6474  does not understand/obey the command \SpecialChar LyX
6475  inserts into
6476  the preamble when you check the "Enable Forward/Reverse Search" button
6477  in the toolbar and does not generate the necessary info.
6478 \end_layout
6479
6480 \begin_layout Plain Layout
6481 The generation of the required info can be forced by changing the converter
6482  "\SpecialChar LaTeX
6483  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
6484  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
6485  the -synctex=1 switch).
6486 \end_layout
6487
6488 \end_inset
6489
6490  Also note that only a few PDF viewers (Okular and Qpdfview on Unix, Skim
6491  on the Mac, SumatraPDF on Windows) already provide Sync\SpecialChar TeX
6492  support.
6493 \end_layout
6494
6495 \begin_layout Standard
6496 To enable Sync\SpecialChar TeX
6497  for DVI output, change the 
6498 \begin_inset Flex Noun
6499 status collapsed
6500
6501 \begin_layout Plain Layout
6502 La
6503 \family sans
6504 TeX
6505 \family default
6506  (plain) -> DVI
6507 \end_layout
6508
6509 \end_inset
6510
6511  or 
6512 \begin_inset Flex Noun
6513 status collapsed
6514
6515 \begin_layout Plain Layout
6516 La
6517 \family sans
6518 TeX
6519 \family default
6520  (plain) -> DraftDVI
6521 \end_layout
6522
6523 \end_inset
6524
6525  converter in 
6526 \begin_inset Flex Noun
6527 status collapsed
6528
6529 \begin_layout Plain Layout
6530 Preferences\SpecialChar menuseparator
6531 File Handling\SpecialChar menuseparator
6532 Converters
6533 \end_layout
6534
6535 \end_inset
6536
6537  to 
6538 \begin_inset Flex Code
6539 status collapsed
6540
6541 \begin_layout Plain Layout
6542 latex -synctex=1 $$i
6543 \end_layout
6544
6545 \end_inset
6546
6547 , and for PDF output, change the 
6548 \begin_inset Flex Noun
6549 status collapsed
6550
6551 \begin_layout Plain Layout
6552 La
6553 \family sans
6554 TeX
6555 \family default
6556  (pdflatex) -> PDF (pdflatex)
6557 \end_layout
6558
6559 \end_inset
6560
6561  or converter to 
6562 \begin_inset Flex Code
6563 status collapsed
6564
6565 \begin_layout Plain Layout
6566 pdflatex -synctex=1 $$i
6567 \end_layout
6568
6569 \end_inset
6570
6571 .
6572  Check the documentation of your viewer whether the viewer needs to be configure
6573 d for the use with Sync\SpecialChar TeX
6574 .
6575 \begin_inset Foot
6576 status collapsed
6577
6578 \begin_layout Plain Layout
6579 Note that the option 
6580 \begin_inset Flex Code
6581 status collapsed
6582
6583 \begin_layout Plain Layout
6584 -synctex=1
6585 \end_layout
6586
6587 \end_inset
6588
6589  option enables gzip compression.
6590  If your viewer does not support it, you should instead use 
6591 \begin_inset Flex Code
6592 status collapsed
6593
6594 \begin_layout Plain Layout
6595 -synctex=-1
6596 \end_layout
6597
6598 \end_inset
6599
6600 .
6601 \end_layout
6602
6603 \end_inset
6604
6605
6606 \end_layout
6607
6608 \begin_layout Subsection
6609 Configuring and using specific viewers
6610 \begin_inset CommandInset label
6611 LatexCommand label
6612 name "subsec:configuring-viewers"
6613
6614 \end_inset
6615
6616
6617 \end_layout
6618
6619 \begin_layout Subsubsection*
6620 Xdvi (all platforms)
6621 \end_layout
6622
6623 \begin_layout Standard
6624 If you use 
6625 \begin_inset Flex Code
6626 status collapsed
6627
6628 \begin_layout Plain Layout
6629 xdvi
6630 \end_layout
6631
6632 \end_inset
6633
6634 , you don't need to do anything else for performing a reverse DVI search,
6635  as \SpecialChar LyX
6636  already provides the necessary hooks for automatically using the 
6637 \begin_inset Flex Code
6638 status collapsed
6639
6640 \begin_layout Plain Layout
6641 lyxclient
6642 \end_layout
6643
6644 \end_inset
6645
6646  program.
6647  Just setup your document as described above (reverse search is triggered
6648  by Ctrl-click or Alt-click on Mac OSX, respectively).
6649 \end_layout
6650
6651 \begin_layout Standard
6652 However, if for whatever reason you want to use the named pipe instead of
6653  the socket for communicating with \SpecialChar LyX
6654 , simply change the DVI viewer in 
6655 \begin_inset Flex Noun
6656 status collapsed
6657
6658 \begin_layout Plain Layout
6659 Preferences\SpecialChar menuseparator
6660 File Handling\SpecialChar menuseparator
6661 File formats
6662 \end_layout
6663
6664 \end_inset
6665
6666  to
6667 \begin_inset Foot
6668 status collapsed
6669
6670 \begin_layout Plain Layout
6671 On Mac OSX you have to use 
6672 \begin_inset Flex Code
6673 status collapsed
6674
6675 \begin_layout Plain Layout
6676 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
6677 \end_layout
6678
6679 \end_inset
6680
6681
6682 \end_layout
6683
6684 \end_inset
6685
6686  
6687 \begin_inset Flex Code
6688 status collapsed
6689
6690 \begin_layout Plain Layout
6691 xdvi -editor "lyxeditor.sh %f %l"
6692 \end_layout
6693
6694 \end_inset
6695
6696 , where 
6697 \begin_inset Flex Code
6698 status collapsed
6699
6700 \begin_layout Plain Layout
6701 lyxeditor.sh
6702 \end_layout
6703
6704 \end_inset
6705
6706  is a suitable script.
6707  For example, a minimal shell script is the following one:
6708 \end_layout
6709
6710 \begin_layout LyX-Code
6711 #!/bin/sh
6712 \begin_inset Newline newline
6713 \end_inset
6714
6715 LYXPIPE="/path/to/lyxpipe"
6716 \begin_inset Newline newline
6717 \end_inset
6718
6719 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
6720 \begin_inset Newline newline
6721 \end_inset
6722
6723 echo "$COMMAND" > "${LYXPIPE}".in || exit
6724 \begin_inset Newline newline
6725 \end_inset
6726
6727 read TMP < "${LYXPIPE}".out || exit
6728 \end_layout
6729
6730 \begin_layout Standard
6731 where 
6732 \begin_inset Flex Code
6733 status collapsed
6734
6735 \begin_layout Plain Layout
6736 /path/to/lyxpipe
6737 \end_layout
6738
6739 \end_inset
6740
6741  is the Ly
6742 \begin_inset ERT
6743 status collapsed
6744
6745 \begin_layout Plain Layout
6746
6747 {}
6748 \end_layout
6749
6750 \end_inset
6751
6752 XServer pipe path specified in 
6753 \begin_inset Flex Noun
6754 status collapsed
6755
6756 \begin_layout Plain Layout
6757 Preferences\SpecialChar menuseparator
6758 Paths
6759 \end_layout
6760
6761 \end_inset
6762
6763 .
6764 \begin_inset Foot
6765 status collapsed
6766
6767 \begin_layout Plain Layout
6768 In the 
6769 \begin_inset Flex Code
6770 status collapsed
6771
6772 \begin_layout Plain Layout
6773 development/tools
6774 \end_layout
6775
6776 \end_inset
6777
6778  folder of a source distribution you can find a 
6779 \begin_inset Flex Code
6780 status collapsed
6781
6782 \begin_layout Plain Layout
6783 lyxeditor
6784 \end_layout
6785
6786 \end_inset
6787
6788  script which is able to locate the 
6789 \emph on
6790 lyxpipe
6791 \emph default
6792  based on your preferences.
6793 \end_layout
6794
6795 \end_inset
6796
6797
6798 \end_layout
6799
6800 \begin_layout Subsubsection*
6801 MacDviX (Mac OSX)
6802 \end_layout
6803
6804 \begin_layout Standard
6805 At the end of 
6806 \begin_inset Flex Code
6807 status collapsed
6808
6809 \begin_layout Plain Layout
6810 /Applications/MacDviX_Folder/calleditor.script
6811 \end_layout
6812
6813 \end_inset
6814
6815 , add the following lines:
6816 \end_layout
6817
6818 \begin_layout LyX-Code
6819 /Applications/Ly
6820 \begin_inset ERT
6821 status collapsed
6822
6823 \begin_layout Plain Layout
6824
6825 {}
6826 \end_layout
6827
6828 \end_inset
6829
6830 X.app/Contents/MacOS/lyxeditor "$2" $1
6831 \begin_inset Newline newline
6832 \end_inset
6833
6834 exit 1
6835 \end_layout
6836
6837 \begin_layout Standard
6838 Modify the lines accordingly if you install \SpecialChar LyX
6839  somewhere else than in the
6840  Applications folder.
6841 \end_layout
6842
6843 \begin_layout Standard
6844 Reverse search is triggered by Alt-click (OPTION-click).
6845 \end_layout
6846
6847 \begin_layout Subsubsection*
6848 Skim (Mac OSX)
6849 \end_layout
6850
6851 \begin_layout Standard
6852 Enter 
6853 \begin_inset Flex Code
6854 status collapsed
6855
6856 \begin_layout Plain Layout
6857 open -a Skim.app $$i
6858 \end_layout
6859
6860 \end_inset
6861
6862  to the viewer setting in 
6863 \begin_inset Flex Noun
6864 status collapsed
6865
6866 \begin_layout Plain Layout
6867 Preferences\SpecialChar menuseparator
6868 File Handling\SpecialChar menuseparator
6869 File formats\SpecialChar menuseparator
6870 PDF (pdflatex)
6871 \end_layout
6872
6873 \end_inset
6874
6875 , and then in 
6876 \begin_inset Flex Noun
6877 status collapsed
6878
6879 \begin_layout Plain Layout
6880 Skim\SpecialChar menuseparator
6881 Preferences\SpecialChar menuseparator
6882 Sync
6883 \end_layout
6884
6885 \end_inset
6886
6887  choose 
6888 \begin_inset Flex Noun
6889 status collapsed
6890
6891 \begin_layout Plain Layout
6892 custom
6893 \end_layout
6894
6895 \end_inset
6896
6897  preset and enter command 
6898 \begin_inset Flex Noun
6899 status collapsed
6900
6901 \begin_layout Plain Layout
6902 /Applications/\SpecialChar LyX
6903 .app/Contents/MacOS/lyxeditor
6904 \end_layout
6905
6906 \end_inset
6907
6908 .
6909 \end_layout
6910
6911 \begin_layout Standard
6912 Reverse search is triggered by COMMAND-SHIFT-click
6913 \end_layout
6914
6915 \begin_layout Subsubsection*
6916 Okular (KDE)
6917 \end_layout
6918
6919 \begin_layout Standard
6920 Go to 
6921 \begin_inset Flex Noun
6922 status collapsed
6923
6924 \begin_layout Plain Layout
6925 Settings\SpecialChar menuseparator
6926 Configure Okular\SpecialChar menuseparator
6927 Editor
6928 \end_layout
6929
6930 \end_inset
6931
6932 , select 
6933 \begin_inset Quotes eld
6934 \end_inset
6935
6936 Custom Text Editor
6937 \begin_inset Quotes erd
6938 \end_inset
6939
6940  and add the command 
6941 \begin_inset Flex Code
6942 status collapsed
6943
6944 \begin_layout Plain Layout
6945 lyxclient -g %f %l
6946 \end_layout
6947
6948 \end_inset
6949
6950 .
6951 \end_layout
6952
6953 \begin_layout Standard
6954 Reverse search is triggered by SHIFT-click.
6955 \end_layout
6956
6957 \begin_layout Subsubsection*
6958 Qpdfview (Unix)
6959 \end_layout
6960
6961 \begin_layout Standard
6962 Qpdfview supports Sync\SpecialChar TeX
6963  since version 0.3.5.
6964  Go to 
6965 \begin_inset Flex Noun
6966 status collapsed
6967
6968 \begin_layout Plain Layout
6969 Edit\SpecialChar menuseparator
6970 Settings\SpecialChar menuseparator
6971 Behavior
6972 \end_layout
6973
6974 \end_inset
6975
6976 , click on the input field of the 
6977 \begin_inset Quotes eld
6978 \end_inset
6979
6980 Source editor
6981 \begin_inset Quotes erd
6982 \end_inset
6983
6984  item and add the command 
6985 \begin_inset Flex Code
6986 status collapsed
6987
6988 \begin_layout Plain Layout
6989 lyxclient -g %1 %2
6990 \end_layout
6991
6992 \end_inset
6993
6994 .
6995 \end_layout
6996
6997 \begin_layout Standard
6998 Reverse search is triggered by double-click.
6999 \end_layout
7000
7001 \begin_layout Subsubsection*
7002 YAP (Windows)
7003 \end_layout
7004
7005 \begin_layout Standard
7006 Launch yap, choose its 
7007 \begin_inset Flex Noun
7008 status collapsed
7009
7010 \begin_layout Plain Layout
7011 View\SpecialChar menuseparator
7012 Options
7013 \end_layout
7014
7015 \end_inset
7016
7017  menu and select the 
7018 \begin_inset Quotes eld
7019 \end_inset
7020
7021 Inverse DVI Search
7022 \begin_inset Quotes erd
7023 \end_inset
7024
7025  tab.
7026  Click on the 
7027 \begin_inset Quotes eld
7028 \end_inset
7029
7030 New\SpecialChar ldots
7031
7032 \begin_inset Quotes erd
7033 \end_inset
7034
7035  button and, in the window that opens, enter 
7036 \begin_inset Quotes eld
7037 \end_inset
7038
7039 \SpecialChar LyX
7040  Editor
7041 \begin_inset Quotes erd
7042 \end_inset
7043
7044  (or any other name you like) in the 
7045 \begin_inset Quotes eld
7046 \end_inset
7047
7048 Name:
7049 \begin_inset Quotes erd
7050 \end_inset
7051
7052  field.
7053  Now click on the button labeled 
7054 \begin_inset Quotes eld
7055 \end_inset
7056
7057 \SpecialChar ldots
7058
7059 \begin_inset Quotes erd
7060 \end_inset
7061
7062  to open a file dialog and navigate to the directory containing the batch
7063  file 
7064 \begin_inset Flex Code
7065 status collapsed
7066
7067 \begin_layout Plain Layout
7068 lyxeditor.bat
7069 \end_layout
7070
7071 \end_inset
7072
7073  (see below).
7074  Select 
7075 \begin_inset Flex Code
7076 status collapsed
7077
7078 \begin_layout Plain Layout
7079 lyxeditor.bat
7080 \end_layout
7081
7082 \end_inset
7083
7084  and then specify the program arguments as 
7085 \begin_inset Flex Code
7086 status collapsed
7087
7088 \begin_layout Plain Layout
7089 %f %l
7090 \end_layout
7091
7092 \end_inset
7093
7094 .
7095  The 
7096 \begin_inset Flex Code
7097 status collapsed
7098
7099 \begin_layout Plain Layout
7100 lyxeditor.bat
7101 \end_layout
7102
7103 \end_inset
7104
7105  wrapper is used for communicating with \SpecialChar LyX
7106  through the 
7107 \emph on
7108 lyxpipe
7109 \emph default
7110  and is as follows:
7111 \end_layout
7112
7113 \begin_layout LyX-Code
7114 @echo off
7115 \begin_inset Newline newline
7116 \end_inset
7117
7118 echo LYXCMD:revdvi:server-goto-file-row:%1 %2> 
7119 \backslash
7120
7121 \backslash
7122 .
7123 \backslash
7124 pipe
7125 \backslash
7126 lyxpipe.in
7127 \begin_inset Newline newline
7128 \end_inset
7129
7130 type 
7131 \backslash
7132
7133 \backslash
7134 .
7135 \backslash
7136 pipe
7137 \backslash
7138 lyxpipe.out
7139 \end_layout
7140
7141 \begin_layout Standard
7142 Make sure that the \SpecialChar LyX
7143 Server pipe path you specified in \SpecialChar LyX
7144  is 
7145 \begin_inset Flex Code
7146 status collapsed
7147
7148 \begin_layout Plain Layout
7149
7150 \backslash
7151
7152 \backslash
7153 .
7154 \backslash
7155 pipe
7156 \backslash
7157 lyxpipe
7158 \end_layout
7159
7160 \end_inset
7161
7162 , otherwise change the 
7163 \begin_inset Flex Code
7164 status collapsed
7165
7166 \begin_layout Plain Layout
7167 lyxeditor.bat
7168 \end_layout
7169
7170 \end_inset
7171
7172  wrapper accordingly.
7173 \end_layout
7174
7175 \begin_layout Standard
7176 In yap, reverse search is triggered by double-click.
7177 \end_layout
7178
7179 \begin_layout Subsubsection*
7180 SumatraPDF (Windows)
7181 \end_layout
7182
7183 \begin_layout Standard
7184 In order to use SumatraPDF for inverse search, enter 
7185 \begin_inset Flex Code
7186 status collapsed
7187
7188 \begin_layout Plain Layout
7189 SumatraPDF -inverse-search "lyxeditor.bat %f %l"
7190 \end_layout
7191
7192 \end_inset
7193
7194  in the viewer setting in 
7195 \begin_inset Flex Noun
7196 status collapsed
7197
7198 \begin_layout Plain Layout
7199 Preferences\SpecialChar menuseparator
7200 File Handling\SpecialChar menuseparator
7201 File formats\SpecialChar menuseparator
7202 PDF (pdflatex)
7203 \end_layout
7204
7205 \end_inset
7206
7207 , where 
7208 \begin_inset Flex Code
7209 status collapsed
7210
7211 \begin_layout Plain Layout
7212 lyxeditor.bat
7213 \end_layout
7214
7215 \end_inset
7216
7217  is the previous wrapper.
7218  If SumatraPDF.exe is not in your command PATH, use its full file name.
7219 \end_layout
7220
7221 \begin_layout Standard
7222 Reverse search is triggered by double-click.
7223 \end_layout
7224
7225 \begin_layout Subsubsection*
7226 YAP (Cygwin)
7227 \end_layout
7228
7229 \begin_layout Standard
7230 First of all, make sure that yap is your default DVI viewer in the Windows
7231  environment, then launch it, choose its 
7232 \begin_inset Flex Noun
7233 status collapsed
7234
7235 \begin_layout Plain Layout
7236 View\SpecialChar menuseparator
7237 Options
7238 \end_layout
7239
7240 \end_inset
7241
7242  menu and select the 
7243 \begin_inset Quotes eld
7244 \end_inset
7245
7246 Inverse DVI Search
7247 \begin_inset Quotes erd
7248 \end_inset
7249
7250  tab.
7251  Click on the 
7252 \begin_inset Quotes eld
7253 \end_inset
7254
7255 New\SpecialChar ldots
7256
7257 \begin_inset Quotes erd
7258 \end_inset
7259
7260  button and, in the window that opens, enter 
7261 \begin_inset Quotes eld
7262 \end_inset
7263
7264 \SpecialChar LyX
7265  Editor
7266 \begin_inset Quotes erd
7267 \end_inset
7268
7269  (or any other name you like) in the 
7270 \begin_inset Quotes eld
7271 \end_inset
7272
7273 Name:
7274 \begin_inset Quotes erd
7275 \end_inset
7276
7277  field.
7278  Now click on the button labeled 
7279 \begin_inset Quotes eld
7280 \end_inset
7281
7282 \SpecialChar ldots
7283
7284 \begin_inset Quotes erd
7285 \end_inset
7286
7287  to open a file dialog and navigate to the directory containing the 
7288 \begin_inset Flex Code
7289 status collapsed
7290
7291 \begin_layout Plain Layout
7292 lyxeditor.exe
7293 \end_layout
7294
7295 \end_inset
7296
7297  program (which is installed by default on Cygwin along with the \SpecialChar LyX
7298  executable).
7299  Select 
7300 \begin_inset Flex Code
7301 status collapsed
7302
7303 \begin_layout Plain Layout
7304 lyxeditor.exe
7305 \end_layout
7306
7307 \end_inset
7308
7309  and then specify the program arguments as 
7310 \begin_inset Flex Code
7311 status collapsed
7312
7313 \begin_layout Plain Layout
7314 -g %f %l
7315 \end_layout
7316
7317 \end_inset
7318
7319 .
7320  In this way, you will be using the 
7321 \emph on
7322 lyxsocket
7323 \emph default
7324  for communicating with \SpecialChar LyX
7325 .
7326  If, for whatever reason, you want to use the 
7327 \emph on
7328 lyxpipe
7329 \emph default
7330 , omit the 
7331 \begin_inset Flex Code
7332 status collapsed
7333
7334 \begin_layout Plain Layout
7335 -g
7336 \end_layout
7337
7338 \end_inset
7339
7340  option and be sure to specify the \SpecialChar LyX
7341 Server pipe path in the \SpecialChar LyX
7342  preferences.
7343 \end_layout
7344
7345 \begin_layout Standard
7346 In yap, reverse search is triggered by double-click.
7347 \end_layout
7348
7349 \begin_layout Subsubsection*
7350 SumatraPDF (Cygwin)
7351 \end_layout
7352
7353 \begin_layout Standard
7354 In order to use SumatraPDF for inverse search, enter 
7355 \begin_inset Flex Code
7356 status collapsed
7357
7358 \begin_layout Plain Layout
7359 SumatraPDF -inverse-search "lyxeditor -g %f %l"
7360 \end_layout
7361
7362 \end_inset
7363
7364  in the viewer setting in 
7365 \begin_inset Flex Noun
7366 status collapsed
7367
7368 \begin_layout Plain Layout
7369 Preferences\SpecialChar menuseparator
7370 File Handling\SpecialChar menuseparator
7371 File formats\SpecialChar menuseparator
7372 PDF (pdflatex)
7373 \end_layout
7374
7375 \end_inset
7376
7377 .
7378  If SumatraPDF.exe is not in your command PATH, use its full posix path.
7379  The 
7380 \begin_inset Flex Code
7381 status collapsed
7382
7383 \begin_layout Plain Layout
7384 -g
7385 \end_layout
7386
7387 \end_inset
7388
7389  enables communication via the 
7390 \emph on
7391 lyxsocket
7392 \emph default
7393 .
7394  Again, omit the 
7395 \begin_inset Flex Code
7396 status collapsed
7397
7398 \begin_layout Plain Layout
7399 -g
7400 \end_layout
7401
7402 \end_inset
7403
7404  option if you want to use the 
7405 \emph on
7406 lyxpipe
7407 \emph default
7408 , and be sure to specify the \SpecialChar LyX
7409 Server pipe path in the \SpecialChar LyX
7410  preferences.
7411 \end_layout
7412
7413 \begin_layout Standard
7414 Reverse search is triggered by double-click.
7415 \end_layout
7416
7417 \begin_layout Section
7418 Forward search
7419 \end_layout
7420
7421 \begin_layout Standard
7422 Forward search is, as the name implies, in a sense the 
7423 \begin_inset Quotes eld
7424 \end_inset
7425
7426 opposite
7427 \begin_inset Quotes erd
7428 \end_inset
7429
7430  of reverse search.
7431  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
7432 .
7433  If forward search is set up (as described in what follows), you can put
7434  the cursor anywhere in your \SpecialChar LyX
7435  document, and hit 
7436 \begin_inset Flex Noun
7437 status collapsed
7438
7439 \begin_layout Plain Layout
7440 Navigate\SpecialChar menuseparator
7441 Forward search
7442 \end_layout
7443
7444 \end_inset
7445
7446  (or select 
7447 \begin_inset Flex Noun
7448 status collapsed
7449
7450 \begin_layout Plain Layout
7451 Forward search
7452 \end_layout
7453
7454 \end_inset
7455
7456  in the context menu via right mouse click), and then the viewer will jump
7457  to that position as well.
7458  This implies, of course, that your viewer supports this function.
7459 \end_layout
7460
7461 \begin_layout Standard
7462 To make forward search possible, you first need to provide the generated
7463  output PDF/DVI file with additional information about the \SpecialChar TeX
7464  sources.
7465  This can be done via the methods described in the section 
7466 \begin_inset CommandInset ref
7467 LatexCommand ref
7468 reference "subsec:rev-search"
7469
7470 \end_inset
7471
7472 .
7473 \end_layout
7474
7475 \begin_layout Standard
7476 Additionally, you need to configure \SpecialChar LyX
7477  for using your viewers in 
7478 \begin_inset Flex Noun
7479 status collapsed
7480
7481 \begin_layout Plain Layout
7482 Tools\SpecialChar menuseparator
7483 Preferences\SpecialChar menuseparator
7484 Output\SpecialChar menuseparator
7485 General
7486 \end_layout
7487
7488 \end_inset
7489
7490 .
7491  We provide a range of tested configurations for some viewers, which you
7492  can select from the drop down list.
7493  If none of these configurations suits you, you have to find out and enter
7494  a suitable configuration yourself.
7495  The definition syntax uses the following placeholders:
7496 \end_layout
7497
7498 \begin_layout Itemize
7499 \noindent
7500 \begin_inset Flex Code
7501 status collapsed
7502
7503 \begin_layout Plain Layout
7504 $$n
7505 \end_layout
7506
7507 \end_inset
7508
7509 : row number
7510 \end_layout
7511
7512 \begin_layout Itemize
7513 \noindent
7514 \begin_inset Flex Code
7515 status collapsed
7516
7517 \begin_layout Plain Layout
7518 $$t
7519 \end_layout
7520
7521 \end_inset
7522
7523 : name of the (temporary) exported .tex file (without path)
7524 \end_layout
7525
7526 \begin_layout Itemize
7527 \noindent
7528 \begin_inset Flex Code
7529 status collapsed
7530
7531 \begin_layout Plain Layout
7532 $$f
7533 \end_layout
7534
7535 \end_inset
7536
7537 : name of the (temporary) exported .tex file (including path)
7538 \end_layout
7539
7540 \begin_layout Itemize
7541 \noindent
7542 \begin_inset Flex Code
7543 status collapsed
7544
7545 \begin_layout Plain Layout
7546 $$o
7547 \end_layout
7548
7549 \end_inset
7550
7551 : name of the exported output file (either dvi or pdf, depending on which
7552  one exists in the temporary directory)
7553 \end_layout
7554
7555 \begin_layout Standard
7556 Note that only some of the viewers provide full forward search functionality,
7557  among them yap, xdvi, okular
7558 \begin_inset Foot
7559 status collapsed
7560
7561 \begin_layout Plain Layout
7562 You might want to set 
7563 \begin_inset Flex Code
7564 status collapsed
7565
7566 \begin_layout Plain Layout
7567 okular –unique
7568 \end_layout
7569
7570 \end_inset
7571
7572  in 
7573 \begin_inset Flex Noun
7574 status collapsed
7575
7576 \begin_layout Plain Layout
7577 Tools\SpecialChar menuseparator
7578 Preferences\SpecialChar menuseparator
7579 File Handling\SpecialChar menuseparator
7580 File
7581 \begin_inset space ~
7582 \end_inset
7583
7584 Formats
7585 \end_layout
7586
7587 \end_inset
7588
7589
7590 \end_layout
7591
7592 \end_inset
7593
7594 , qpdfview and SumatraPDF
7595 \begin_inset Foot
7596 status collapsed
7597
7598 \begin_layout Plain Layout
7599 SumatraPDF can also use DDE commands through the external program CMCDDE
7600  — downloadable from 
7601 \begin_inset CommandInset href
7602 LatexCommand href
7603 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
7604
7605 \end_inset
7606
7607
7608 \end_layout
7609
7610 \end_inset
7611
7612 .
7613  While many of the widespread PDF viewers (most notably Adobe Reader) do
7614  not support forward search at all, some other viewers – e.
7615 \begin_inset space \thinspace{}
7616 \end_inset
7617
7618 g.
7619  evince and xpdf – allow at least to reload the document and jump to a specific
7620  page of the file, so you can at least navigate 
7621 \begin_inset Quotes eld
7622 \end_inset
7623
7624 near
7625 \begin_inset Quotes erd
7626 \end_inset
7627
7628 .
7629  This latter functionality is provided by an external call of synctex (see
7630  the predefined example configurations).
7631  
7632 \end_layout
7633
7634 \begin_layout Standard
7635 Forward search works both with DVI and PDF output.
7636  \SpecialChar LyX
7637  simply checks which preview format you have used before (i.
7638 \begin_inset space \thinspace{}
7639 \end_inset
7640
7641 e., which format is already there in the temporary directory) and chooses
7642  the appropriate configuration for the respective format.
7643 \end_layout
7644
7645 \begin_layout Chapter
7646 Special Document Classes
7647 \end_layout
7648
7649 \begin_layout Section
7650 A&A Paper
7651 \end_layout
7652
7653 \begin_layout Standard
7654 by 
7655 \noun on
7656 Peter Sütterlin
7657 \end_layout
7658
7659 \begin_layout Subsection
7660 Introduction
7661 \end_layout
7662
7663 \begin_layout Standard
7664 This section describes how \SpecialChar LyX
7665  can be used to write articles for submission
7666  to the scientific journal 
7667 \emph on
7668 Astronomy and Astrophysics
7669 \emph default
7670  (
7671 \begin_inset Flex URL
7672 status collapsed
7673
7674 \begin_layout Plain Layout
7675
7676 http://www.edpsciences.fr/aa/
7677 \end_layout
7678
7679 \end_inset
7680
7681 ) using Version 5.01 of the document class 
7682 \family typewriter
7683 aa.cls
7684 \family default
7685 .
7686  This package can be downloaded from the ftp site
7687 \end_layout
7688
7689 \begin_layout Standard
7690 \begin_inset VSpace medskip
7691 \end_inset
7692
7693
7694 \end_layout
7695
7696 \begin_layout Standard
7697 \align center
7698 \begin_inset Flex URL
7699 status collapsed
7700
7701 \begin_layout Plain Layout
7702
7703 ftp://ftp.edpsciences.org/pub/aa/readme.html
7704 \end_layout
7705
7706 \end_inset
7707
7708
7709 \end_layout
7710
7711 \begin_layout Standard
7712 \begin_inset VSpace medskip
7713 \end_inset
7714
7715
7716 \end_layout
7717
7718 \begin_layout Standard
7719 A manual comes together with that package, and this text is not meant to
7720  replace the original manual but is merely a short guide in how to realize
7721  the correct form of your paper.
7722  
7723 \end_layout
7724
7725 \begin_layout Standard
7726 Please note that the publisher of the journal was changed from Springer
7727  to EDP Sciences starting January 1, 2001.
7728  That change involved also some slight changes to the style files, namely
7729  the removal of the thesaurus command.
7730  The \SpecialChar LyX
7731  class aa supports the newest version of these style files, V 5.01.
7732  If you have an older version installed, please upgrade.
7733  For compatibility, the old (version 4) layout has been kept as 
7734 \family sans
7735 article (A&A V4)
7736 \family default
7737 .
7738  Please refer to the comments in 
7739 \family typewriter
7740 \SpecialChar LyX
7741 Dir/layouts/aapaper.layout
7742 \family default
7743 .
7744 \end_layout
7745
7746 \begin_layout Subsection
7747 Getting started
7748 \end_layout
7749
7750 \begin_layout Standard
7751 It is recommended you start from the example template distributed with \SpecialChar LyX
7752 .
7753  If you are not using a template, note the following settings:
7754 \end_layout
7755
7756 \begin_layout Itemize
7757 Select 
7758 \family sans
7759 article (A&A)
7760 \family default
7761  in the 
7762 \family sans
7763 Document\SpecialChar menuseparator
7764 Settings
7765 \family default
7766  dialog (OK, that one was obvious).
7767 \end_layout
7768
7769 \begin_layout Itemize
7770 Don't change the option 
7771 \family sans
7772 Page
7773 \begin_inset space ~
7774 \end_inset
7775
7776 style
7777 \family default
7778 : Leave it set to 
7779 \family sans
7780 default
7781 \family default
7782 .
7783  The whole layout is done by the macros, you shouldn't change anything.
7784 \end_layout
7785
7786 \begin_layout Subsection
7787 The header block
7788 \end_layout
7789
7790 \begin_layout Standard
7791 First thing to enter is the header information.
7792  It consists of seven entries, of which some are optional.
7793  They are
7794 \end_layout
7795
7796 \begin_layout Itemize
7797
7798 \family sans
7799 Title
7800 \family default
7801 : [required] 
7802 \end_layout
7803
7804 \begin_layout Itemize
7805
7806 \family sans
7807 Subtitle
7808 \family default
7809 : [optional] 
7810 \end_layout
7811
7812 \begin_layout Itemize
7813
7814 \family sans
7815 Author
7816 \family default
7817 : [required]
7818 \end_layout
7819
7820 \begin_layout Itemize
7821
7822 \family sans
7823 Address
7824 \family default
7825 : [required]
7826 \end_layout
7827
7828 \begin_layout Itemize
7829
7830 \family sans
7831 Offprints
7832 \family default
7833 : [optional] if more than one author: whom to contact for offprint requests.
7834 \end_layout
7835
7836 \begin_layout Itemize
7837
7838 \family sans
7839 Mail
7840 \family default
7841 : [optional] mail address for contacts.
7842 \end_layout
7843
7844 \begin_layout Itemize
7845
7846 \family sans
7847 Date
7848 \family default
7849 : [required].
7850  Suggested format is 
7851 \family typewriter
7852 Received: <date>; Accepted <date> 
7853 \end_layout
7854
7855 \begin_layout Standard
7856 There is no need to issue the 
7857 \family typewriter
7858
7859 \backslash
7860 maketitle
7861 \family default
7862  command, this is done automatically by \SpecialChar LyX
7863  when the header is finished.
7864  Although the order of the single header entries doesn't matter it is advised
7865  to keep the above sequence, just to get the best optics and meets the layout
7866  of the real document.
7867 \end_layout
7868
7869 \begin_layout Standard
7870 If you want to place footnotes in the header block, e.
7871 \begin_inset space \thinspace{}
7872 \end_inset
7873
7874 g.
7875 \begin_inset space \space{}
7876 \end_inset
7877
7878 to state your present address, just use the standard footnote via the menu
7879  
7880 \family sans
7881 Insert\SpecialChar menuseparator
7882 Footnote.
7883
7884 \family default
7885  \SpecialChar LyX
7886  will automagically use the term 
7887 \family typewriter
7888
7889 \backslash
7890 thanks{}
7891 \family default
7892  in that case.
7893 \end_layout
7894
7895 \begin_layout Standard
7896 In addition to these topics, the macros use three additional \SpecialChar LaTeX
7897  commands that
7898  have no counterpart in \SpecialChar LyX
7899 :
7900 \end_layout
7901
7902 \begin_layout Itemize
7903
7904 \family typewriter
7905
7906 \backslash
7907 and
7908 \family default
7909  to separate different names for more than one author and institute, respectivel
7910 y.
7911 \end_layout
7912
7913 \begin_layout Itemize
7914
7915 \family typewriter
7916
7917 \backslash
7918 inst{<nr>}
7919 \family default
7920 to mark corresponding author/institute pairs.
7921  The institutes are numbered sequentially as they appear in the 
7922 \family sans
7923 Address
7924 \family default
7925  field, so you have to put a marker to each author.
7926 \end_layout
7927
7928 \begin_layout Itemize
7929
7930 \family typewriter
7931
7932 \backslash
7933 email{address}
7934 \family default
7935  to supply an email address for fast contact.
7936 \end_layout
7937
7938 \begin_layout Standard
7939 In all cases, the appropriate command has to be entered in \SpecialChar LyX
7940  and marked as
7941  \SpecialChar LaTeX
7942  code.
7943  See the examples.
7944  
7945 \end_layout
7946
7947 \begin_layout Subsection
7948 The abstract
7949 \end_layout
7950
7951 \begin_layout Standard
7952 The abstract should immediately follow the header block.
7953  With version 5 the abstract environment was changed to a command, and there
7954  is now a resctriction to only one paragraph.
7955  In addition, it should contain an entry with the keywords.
7956  This is not yet implemented for \SpecialChar LyX
7957 , therefore you have to enter the \SpecialChar LaTeX
7958  command
7959  
7960 \family typewriter
7961
7962 \backslash
7963 keywords{}
7964 \family default
7965  by hand and mark it as \SpecialChar LaTeX
7966  code.
7967  Refer to the example paper.
7968 \end_layout
7969
7970 \begin_layout Subsection
7971 Supported environments
7972 \end_layout
7973
7974 \begin_layout Standard
7975 The A&A paper layout supports the following environments for structuring
7976  your text:
7977 \end_layout
7978
7979 \begin_layout Itemize
7980
7981 \family sans
7982 Standard
7983 \end_layout
7984
7985 \begin_layout Itemize
7986
7987 \family sans
7988 Section
7989 \end_layout
7990
7991 \begin_layout Itemize
7992
7993 \family sans
7994 Subsection
7995 \end_layout
7996
7997 \begin_layout Itemize
7998
7999 \family sans
8000 Subsubsection
8001 \end_layout
8002
8003 \begin_layout Itemize
8004
8005 \family sans
8006 Itemize
8007 \end_layout
8008
8009 \begin_layout Itemize
8010
8011 \family sans
8012 Enumerate
8013 \end_layout
8014
8015 \begin_layout Itemize
8016
8017 \family sans
8018 Description
8019 \end_layout
8020
8021 \begin_layout Itemize
8022
8023 \family sans
8024 Caption
8025 \end_layout
8026
8027 \begin_layout Itemize
8028
8029 \family sans
8030 Abstract
8031 \end_layout
8032
8033 \begin_layout Itemize
8034
8035 \family sans
8036 Acknowledgment
8037 \end_layout
8038
8039 \begin_layout Itemize
8040
8041 \family sans
8042 Bibliography
8043 \end_layout
8044
8045 \begin_layout Itemize
8046
8047 \family sans
8048 \SpecialChar LaTeX
8049
8050 \end_layout
8051
8052 \begin_layout Subsection
8053 Commands not supported by \SpecialChar LyX
8054
8055 \end_layout
8056
8057 \begin_layout Standard
8058 Some commands are not yet supported by the 
8059 \family sans
8060 paper (A&A)
8061 \family default
8062  layout for \SpecialChar LyX
8063 .
8064  Some have already been mentioned.
8065  For the sake of completeness, they are listed all together here:
8066 \end_layout
8067
8068 \begin_layout Itemize
8069
8070 \family typewriter
8071
8072 \backslash
8073 and
8074 \end_layout
8075
8076 \begin_layout Itemize
8077
8078 \family typewriter
8079
8080 \backslash
8081 email
8082 \end_layout
8083
8084 \begin_layout Itemize
8085
8086 \family typewriter
8087
8088 \backslash
8089 appendix
8090 \end_layout
8091
8092 \begin_layout Itemize
8093
8094 \family typewriter
8095
8096 \backslash
8097 authorrunning
8098 \end_layout
8099
8100 \begin_layout Itemize
8101
8102 \family typewriter
8103
8104 \backslash
8105 inst{}
8106 \end_layout
8107
8108 \begin_layout Itemize
8109
8110 \family typewriter
8111
8112 \backslash
8113 keywords{}
8114 \end_layout
8115
8116 \begin_layout Itemize
8117
8118 \family typewriter
8119
8120 \backslash
8121 object{}
8122 \end_layout
8123
8124 \begin_layout Itemize
8125
8126 \family typewriter
8127
8128 \backslash
8129 titlerunning{}
8130 \end_layout
8131
8132 \begin_layout Standard
8133 If you want to use any of these commands, you have to enter them yourself.
8134  
8135 \series bold
8136 Do not forget to mark them as \SpecialChar LaTeX
8137  code!
8138 \end_layout
8139
8140 \begin_layout Subsection
8141 Figure and Table Floats
8142 \end_layout
8143
8144 \begin_layout Standard
8145 \SpecialChar LyX
8146  provides support for the necessary float environments 
8147 \family sans
8148 figure, figure*, table
8149 \family default
8150  and 
8151 \family sans
8152 table*
8153 \family default
8154 , therefore we won't tell much about it here.
8155  Refer to the 
8156 \emph on
8157 User's
8158 \begin_inset space ~
8159 \end_inset
8160
8161 Guide
8162 \emph default
8163 .
8164  Just remember that tables should be left-aligned.
8165  For that, select the table and change the alignment in 
8166 \family sans
8167 Edit\SpecialChar menuseparator
8168 Paragraph
8169 \begin_inset space ~
8170 \end_inset
8171
8172 Settings.
8173 \end_layout
8174
8175 \begin_layout Standard
8176 There is only one special thing: the figures with caption besides the figure.
8177  To create such a figure, you have to do the following:
8178 \end_layout
8179
8180 \begin_layout Enumerate
8181 Create a wide figure float: 
8182 \family sans
8183 Insert\SpecialChar menuseparator
8184 Float\SpecialChar menuseparator
8185 Figure
8186 \family default
8187 , then right click in the figure and select 
8188 \family sans
8189 \bar under
8190 S
8191 \bar default
8192 pan
8193 \begin_inset space ~
8194 \end_inset
8195
8196 columns
8197 \family default
8198 .
8199 \end_layout
8200
8201 \begin_layout Enumerate
8202 Enter your caption text.
8203 \end_layout
8204
8205 \begin_layout Enumerate
8206 Press 
8207 \family sans
8208 Return
8209 \family default
8210  to move the cursor above the caption.
8211 \end_layout
8212
8213 \begin_layout Enumerate
8214 Insert your figure
8215 \end_layout
8216
8217 \begin_layout Enumerate
8218 Position the cursor behind the figure and insert a horizontal fill: 
8219 \family sans
8220 Insert\SpecialChar menuseparator
8221 Special
8222 \begin_inset space ~
8223 \end_inset
8224
8225 Character\SpecialChar menuseparator
8226 Horizontal
8227 \begin_inset space ~
8228 \end_inset
8229
8230 Fill
8231 \family default
8232 .
8233 \end_layout
8234
8235 \begin_layout Enumerate
8236 Switch to \SpecialChar LaTeX
8237  mode: 
8238 \family sans
8239 M-c
8240 \begin_inset space ~
8241 \end_inset
8242
8243 t
8244 \family default
8245 .
8246 \end_layout
8247
8248 \begin_layout Enumerate
8249 Enter 
8250 \family typewriter
8251
8252 \backslash
8253 parbox[b]{55mm}{
8254 \family default
8255 .
8256  
8257 \series bold
8258 Do not close the brace!
8259 \end_layout
8260
8261 \begin_layout Enumerate
8262 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
8263  mode and insert
8264  the closing brace: 
8265 \family sans
8266 M-c
8267 \begin_inset space ~
8268 \end_inset
8269
8270 t
8271 \family default
8272  
8273 \family typewriter
8274 }
8275 \family default
8276 .
8277 \end_layout
8278
8279 \begin_layout Standard
8280 Also, refer to the figures in the example paper.
8281 \end_layout
8282
8283 \begin_layout Subsection
8284 Referee layout
8285 \end_layout
8286
8287 \begin_layout Standard
8288 For submission, the paper has to be formated in a special double-spacing
8289  layout.
8290  For this purpose, you have to give the option 
8291 \family typewriter
8292 referee
8293 \family default
8294  to the documentclass.
8295  This must be done using the extra class options field in the 
8296 \family sans
8297 Document\SpecialChar menuseparator
8298 Settings
8299 \family default
8300  dialog.
8301  Just enter the string 
8302 \family typewriter
8303 referee
8304 \family default
8305  there.
8306 \end_layout
8307
8308 \begin_layout Subsection
8309 The example paper
8310 \end_layout
8311
8312 \begin_layout Standard
8313 The 
8314 \family sans
8315 Examples
8316 \family default
8317  directory contains an example paper written with \SpecialChar LyX
8318 .
8319  It is the example paper from the original macro package, translated to
8320  \SpecialChar LyX
8321 .
8322  Use it for inspiration, and compare the original \SpecialChar LaTeX
8323  code with \SpecialChar LyX
8324  way of writing.
8325 \end_layout
8326
8327 \begin_layout Section
8328 AAS\SpecialChar TeX
8329
8330 \end_layout
8331
8332 \begin_layout Standard
8333 by 
8334 \noun on
8335 Mike Ressler
8336 \end_layout
8337
8338 \begin_layout Subsection
8339 Introduction
8340 \end_layout
8341
8342 \begin_layout Standard
8343 AAS\SpecialChar TeX
8344  is a set of macros produced by the American Astronomical Society to
8345  facilitate electronic manuscript submission to the three journals they
8346  publish: the Astrophysical Journal (including the Letters and Supplement),
8347  the Astronomical Journal, and the Publications of the Astronomical Society
8348  of the Pacific.
8349  \SpecialChar LyX
8350  has proven to be an excellent tool for generating these documents, especially
8351  given its equation, citation, and figure handling capabilities.
8352  \SpecialChar LyX
8353  requires version 5.0 (or higher) of these macros; preferably 5.2, which
8354  is the version described here, or higher.
8355  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
8356 2.09 and are fundamentally
8357  incompatible with \SpecialChar LyX
8358 .
8359  The AAS\SpecialChar TeX
8360  package may be downloaded from the AAS\SpecialChar TeX
8361  Web site
8362 \end_layout
8363
8364 \begin_layout Standard
8365 \begin_inset VSpace medskip
8366 \end_inset
8367
8368
8369 \end_layout
8370
8371 \begin_layout Standard
8372 \align center
8373 \begin_inset Flex URL
8374 status collapsed
8375
8376 \begin_layout Plain Layout
8377
8378 https://aas.org/aastex/aastex-downloads
8379 \end_layout
8380
8381 \end_inset
8382
8383
8384 \end_layout
8385
8386 \begin_layout Standard
8387 \begin_inset VSpace medskip
8388 \end_inset
8389
8390
8391 \end_layout
8392
8393 \begin_layout Standard
8394 A complete user guide is contained in that package and you should familiarize
8395  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
8396 .
8397  \SpecialChar LyX
8398  will not reduce the need to figure out all the AAS\SpecialChar TeX
8399  commands, it will only
8400  reduce the drudgery of typing everything in.
8401  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
8402  document conforms
8403  completely to the requirements of the journal to which you are submitting
8404  your paper.
8405 \end_layout
8406
8407 \begin_layout Subsection
8408 Starting a New Paper
8409 \end_layout
8410
8411 \begin_layout Standard
8412 I strongly suggest that you start with the AAS\SpecialChar TeX
8413  template file.
8414  Click on 
8415 \family sans
8416 File\SpecialChar menuseparator
8417 New from
8418 \family default
8419  
8420 \family sans
8421 Template
8422 \family default
8423 , enter the new file name, then choose the 
8424 \family typewriter
8425 aastex.lyx
8426 \family default
8427  template.
8428  This will show the most common fields found in a manuscript.
8429  Simply overwrite the existing text (including the brackets, 
8430 \family typewriter
8431 <>
8432 \family default
8433 ) with the correct information.
8434  Many of the AAS\SpecialChar TeX
8435  commands and environments can be implemented directly in
8436  \SpecialChar LyX
8437 , but some cannot: most noticeably 
8438 \family typewriter
8439
8440 \backslash
8441 altaffilmark
8442 \family default
8443  and 
8444 \family typewriter
8445
8446 \backslash
8447 altaffiltext
8448 \family default
8449 , which should stick out like a sore thumb if you actually just opened the
8450  template file.
8451  For commands such as these, the \SpecialChar LaTeX
8452  code must be entered directly and marked
8453  as such.
8454  Such commands are referred to as \SpecialChar TeX
8455  code, or Evil Red Text.
8456  I tried to minimize the amount of \SpecialChar TeX
8457  code needed in an AAS\SpecialChar TeX
8458  document, but
8459  there is still a bit more required than any of us would like.
8460 \end_layout
8461
8462 \begin_layout Subsection
8463 Finishing Your Paper
8464 \end_layout
8465
8466 \begin_layout Standard
8467 When the paper is finished to your satisfaction and previews/prints correctly,
8468  there are a few 
8469 \begin_inset Quotes eld
8470 \end_inset
8471
8472 postprocessing
8473 \begin_inset Quotes erd
8474 \end_inset
8475
8476  actions which need to be done before you submit it to the journals.
8477  
8478 \end_layout
8479
8480 \begin_layout Enumerate
8481 Export your paper as a \SpecialChar LaTeX
8482  file (
8483 \family sans
8484 File\SpecialChar menuseparator
8485 Export\SpecialChar menuseparator
8486 \SpecialChar LaTeX
8487
8488 \family default
8489 ).
8490  
8491 \end_layout
8492
8493 \begin_layout Enumerate
8494 Edit the resulting 
8495 \family typewriter
8496 .tex
8497 \family default
8498  file with your favorite text editor
8499 \begin_inset Separator parbreak
8500 \end_inset
8501
8502
8503 \end_layout
8504
8505 \begin_deeper
8506 \begin_layout Enumerate
8507 remove the comment lines before the 
8508 \family typewriter
8509
8510 \backslash
8511 documentclass
8512 \family default
8513  command
8514 \end_layout
8515
8516 \begin_layout Enumerate
8517 remove the 
8518 \family typewriter
8519
8520 \backslash
8521 usepackage...{fontenc}
8522 \family default
8523  line if it appears (usually just after 
8524 \family typewriter
8525
8526 \backslash
8527 documentclass
8528 \family default
8529 }; also remove the 
8530 \family typewriter
8531
8532 \backslash
8533 secnumdepth
8534 \family default
8535  line if it appears.
8536 \end_layout
8537
8538 \begin_layout Enumerate
8539 remove everything between (and including) the 
8540 \family typewriter
8541
8542 \backslash
8543 makeatletter
8544 \family default
8545  and 
8546 \family typewriter
8547
8548 \backslash
8549 makeatother
8550 \family default
8551  commands, except for any commands you specifically put into the \SpecialChar LaTeX
8552  preamble
8553  (which should appear immediately after the 
8554 \begin_inset Quotes eld
8555 \end_inset
8556
8557 User specified \SpecialChar LaTeX
8558  commands
8559 \begin_inset Quotes erd
8560 \end_inset
8561
8562  comment in the 
8563 \family typewriter
8564 .tex
8565 \family default
8566  file).
8567 \end_layout
8568
8569 \end_deeper
8570 \begin_layout Enumerate
8571 Run the resulting file through \SpecialChar LaTeX
8572  to make sure it still processes correctly.
8573 \end_layout
8574
8575 \begin_layout Enumerate
8576 Reread the journal requirements to make sure your filenames and formats
8577  are correct.
8578 \end_layout
8579
8580 \begin_layout Enumerate
8581 Submit it.
8582 \end_layout
8583
8584 \begin_layout Subsection
8585 Comments On Specific Commands
8586 \end_layout
8587
8588 \begin_layout Standard
8589 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
8590  commands: the
8591  AAS\SpecialChar TeX
8592  User Guide (
8593 \family typewriter
8594 aasguide.tex
8595 \family default
8596 ) gives a good description of each.
8597  Thus it's probably easiest for me to go down the list as found in the guide
8598  and offer comments where necessary.
8599  So let's begin \SpecialChar ldots
8600
8601 \end_layout
8602
8603 \begin_layout Subsubsection
8604 Things that work as expected
8605 \end_layout
8606
8607 \begin_layout Standard
8608 Because they work as you might expect, I simply list them and the section
8609  they are found in: 
8610 \family typewriter
8611
8612 \backslash
8613 documentclass
8614 \family default
8615  (2.1.1), 
8616 \family typewriter
8617
8618 \backslash
8619 begin{document}
8620 \family default
8621  (2.2), 
8622 \family typewriter
8623
8624 \backslash
8625 title
8626 \family default
8627  (2.3), 
8628 \family typewriter
8629
8630 \backslash
8631 author
8632 \family default
8633  (2.3), 
8634 \family typewriter
8635
8636 \backslash
8637 affil
8638 \family default
8639  (2.3), 
8640 \family typewriter
8641
8642 \backslash
8643 abstract
8644 \family default
8645  (2.4), 
8646 \family typewriter
8647
8648 \backslash
8649 keywords
8650 \family default
8651  (2.5), 
8652 \family typewriter
8653
8654 \backslash
8655 section
8656 \family default
8657  (2.7), 
8658 \family typewriter
8659
8660 \backslash
8661 subsection
8662 \family default
8663  (2.7), 
8664 \family typewriter
8665
8666 \backslash
8667 subsubsection
8668 \family default
8669  (2.7), 
8670 \family typewriter
8671
8672 \backslash
8673 paragraph
8674 \family default
8675  (2.7), 
8676 \family typewriter
8677
8678 \backslash
8679 facility
8680 \family default
8681  (2.10), 
8682 \family typewriter
8683
8684 \backslash
8685 begin{displaymath}
8686 \family default
8687  (2.12), 
8688 \family typewriter
8689
8690 \backslash
8691 begin{equation}
8692 \family default
8693  (2.12), 
8694 \family typewriter
8695
8696 \backslash
8697 begin{eqnarray}
8698 \family default
8699  (2.12), 
8700 \family typewriter
8701
8702 \backslash
8703 begin{mathletters}
8704 \family default
8705  (2.12), 
8706 \family typewriter
8707
8708 \backslash
8709 begin{thebibliography}
8710 \family default
8711  (2.13.1), 
8712 \family typewriter
8713
8714 \backslash
8715 bibitem
8716 \family default
8717  (2.13.2), all the cite commands and their variations (2.13.2), the generic
8718  graphicx figure commands (2.14.1), 
8719 \family typewriter
8720
8721 \backslash
8722 begin{table}
8723 \family default
8724  (2.15.4), 
8725 \family typewriter
8726
8727 \backslash
8728 begin{tabular}
8729 \family default
8730  (2.15.4), 
8731 \family typewriter
8732
8733 \backslash
8734 caption
8735 \family default
8736  (2.15.4), 
8737 \family typewriter
8738
8739 \backslash
8740 label
8741 \family default
8742  (2.15.4, amongst other places), 
8743 \family typewriter
8744
8745 \backslash
8746 tablerefs
8747 \family default
8748  (2.15.5), 
8749 \family typewriter
8750
8751 \backslash
8752 tablecomments
8753 \family default
8754  (2.15.5), 
8755 \family typewriter
8756
8757 \backslash
8758 url
8759 \family default
8760  (2.17.4), 
8761 \family typewriter
8762
8763 \backslash
8764 end{document}
8765 \family default
8766  (2.18).
8767 \end_layout
8768
8769 \begin_layout Standard
8770 The following style options also work correctly: 
8771 \family typewriter
8772 longabstract
8773 \family default
8774  (2.4), 
8775 \family typewriter
8776 preprint
8777 \family default
8778  (3.2.1), 
8779 \family typewriter
8780 preprint2
8781 \family default
8782  (3.2.2), 
8783 \family typewriter
8784 eqsecnum
8785 \family default
8786  (3.3), 
8787 \family typewriter
8788 flushrt
8789 \family default
8790  (3.4).
8791  Simply put them in the 
8792 \family sans
8793 Options
8794 \family default
8795  box in 
8796 \family sans
8797 Layout\SpecialChar menuseparator
8798 Document
8799 \family default
8800 .
8801 \end_layout
8802
8803 \begin_layout Subsubsection
8804 Things that work, but require more comment
8805 \end_layout
8806
8807 \begin_layout Standard
8808 The following items work, but require a little more discussion:
8809 \end_layout
8810
8811 \begin_layout Itemize
8812 These items are reserved for use by the journal editors, but you can put
8813  them into the \SpecialChar LaTeX
8814  preamble if you feel compelled to do so: 
8815 \family typewriter
8816
8817 \backslash
8818 received
8819 \family default
8820
8821 \family typewriter
8822
8823 \backslash
8824 revised
8825 \family default
8826
8827 \family typewriter
8828
8829 \backslash
8830 accepted
8831 \family default
8832
8833 \family typewriter
8834
8835 \backslash
8836 ccc
8837 \family default
8838
8839 \family typewriter
8840
8841 \backslash
8842 cpright
8843 \family default
8844  (all from 2.1.3)
8845 \end_layout
8846
8847 \begin_layout Itemize
8848 These items may be placed in the \SpecialChar LaTeX
8849  preamble, and are included as blanks in
8850  the template file: 
8851 \family typewriter
8852
8853 \backslash
8854 slugcomment
8855 \family default
8856  (2.1.4), 
8857 \family typewriter
8858
8859 \backslash
8860 shorttitle
8861 \family default
8862  (2.1.5), 
8863 \family typewriter
8864
8865 \backslash
8866 shortauthors
8867 \family default
8868  (2.1.5)
8869 \end_layout
8870
8871 \begin_layout Itemize
8872
8873 \family typewriter
8874
8875 \backslash
8876 email
8877 \family default
8878  (2.3) – can only be used 
8879 \begin_inset Quotes eld
8880 \end_inset
8881
8882 standalone
8883 \begin_inset Quotes erd
8884 \end_inset
8885
8886 , not in the middle of a paragraph.
8887  Use \SpecialChar TeX
8888  code if you need to embed it.
8889 \end_layout
8890
8891 \begin_layout Itemize
8892
8893 \family typewriter
8894
8895 \backslash
8896 and
8897 \family default
8898  (2.3) – will have extra {} after it.
8899  This should not cause an error.
8900 \end_layout
8901
8902 \begin_layout Itemize
8903
8904 \family typewriter
8905
8906 \backslash
8907 notetoeditor
8908 \family default
8909  (2.6) – can only be used 
8910 \begin_inset Quotes eld
8911 \end_inset
8912
8913 standalone
8914 \begin_inset Quotes erd
8915 \end_inset
8916
8917 , not in the middle of a paragraph.
8918  Use \SpecialChar TeX
8919  code if you need to embed it.
8920 \end_layout
8921
8922 \begin_layout Itemize
8923
8924 \family typewriter
8925
8926 \backslash
8927 placetable
8928 \family default
8929  (2.8) – can't insert a cross-reference tag, you must type the tag name by
8930  hand
8931 \end_layout
8932
8933 \begin_layout Itemize
8934
8935 \family typewriter
8936
8937 \backslash
8938 placefigure
8939 \family default
8940  (2.8) – same as for 
8941 \family typewriter
8942
8943 \backslash
8944 placetable
8945 \end_layout
8946
8947 \begin_layout Itemize
8948
8949 \family typewriter
8950
8951 \backslash
8952 acknowledgements
8953 \family default
8954  (2.9) – will have extra {} after it.
8955  This should not cause an error.
8956 \end_layout
8957
8958 \begin_layout Itemize
8959
8960 \family typewriter
8961
8962 \backslash
8963 appendix
8964 \family default
8965  (2.11) – will have extra {} after it.
8966  This should not cause an error.
8967 \end_layout
8968
8969 \begin_layout Itemize
8970
8971 \family typewriter
8972
8973 \backslash
8974 figcaption
8975 \family default
8976  (2.14.2) – you can insert an optional filename argument by placing the cursor
8977  at the beginning of the text and selecting 
8978 \family sans
8979 Insert\SpecialChar menuseparator
8980 Short Title
8981 \family default
8982 .
8983  
8984 \begin_inset Quotes eld
8985 \end_inset
8986
8987 Short Title
8988 \begin_inset Quotes erd
8989 \end_inset
8990
8991  inserts an optional argument of the type needed by 
8992 \family typewriter
8993
8994 \backslash
8995 figcaption
8996 \family default
8997 .
8998  Hopefully it will be renamed someday.
8999 \end_layout
9000
9001 \begin_layout Itemize
9002
9003 \family typewriter
9004
9005 \backslash
9006 objectname
9007 \family default
9008  (2.17.1) – same as 
9009 \family typewriter
9010
9011 \backslash
9012 figcaption
9013 \family default
9014  for the catalog ID optional parameter
9015 \end_layout
9016
9017 \begin_layout Itemize
9018
9019 \family typewriter
9020
9021 \backslash
9022 dataset
9023 \family default
9024  (2.17.1) – same as 
9025 \family typewriter
9026
9027 \backslash
9028 figcaption
9029 \family default
9030  for the catalog ID optional parameter
9031 \end_layout
9032
9033 \begin_layout Subsubsection
9034 Things not implemented, use \SpecialChar TeX
9035  code
9036 \end_layout
9037
9038 \begin_layout Standard
9039
9040 \family typewriter
9041
9042 \backslash
9043 altaffilmark
9044 \family default
9045  (2.3), 
9046 \family typewriter
9047
9048 \backslash
9049 altaffiltext
9050 \family default
9051  (2.3), 
9052 \family typewriter
9053
9054 \backslash
9055 eqnum
9056 \family default
9057  (2.12), 
9058 \family typewriter
9059
9060 \backslash
9061 setcounter{equation}
9062 \family default
9063  (2.12), Journal name abbreviations (2.13.4), 
9064 \family typewriter
9065
9066 \backslash
9067 figurenum
9068 \family default
9069  (2.14.1), 
9070 \family typewriter
9071
9072 \backslash
9073 epsscale
9074 \family default
9075  (2.14.1), 
9076 \family typewriter
9077
9078 \backslash
9079 plotone
9080 \family default
9081  (2.14.1), 
9082 \family typewriter
9083
9084 \backslash
9085 plottwo
9086 \family default
9087  (2.14.1), 
9088 \family typewriter
9089
9090 \backslash
9091 tablenum
9092 \family default
9093  (2.15.4), 
9094 \family typewriter
9095
9096 \backslash
9097 tableline
9098 \family default
9099  (2.15.4, insert it as the first element in the lefthand cell after where
9100  you want it.
9101  Don't use any of \SpecialChar LyX
9102 's rules in the table), 
9103 \family typewriter
9104
9105 \backslash
9106 tablenotemark
9107 \family default
9108  (2.15.5), 
9109 \family typewriter
9110
9111 \backslash
9112 tablenotetext
9113 \family default
9114  (2.15.5), much of Misc (2.17, except 
9115 \family typewriter
9116
9117 \backslash
9118 objectname
9119 \family default
9120
9121 \family typewriter
9122
9123 \backslash
9124 dataset
9125 \family default
9126
9127 \family typewriter
9128
9129 \backslash
9130 url
9131 \family default
9132 , and 
9133 \family typewriter
9134
9135 \backslash
9136 email
9137 \family default
9138 ; see above), 
9139 \family typewriter
9140
9141 \backslash
9142 singlespace
9143 \family default
9144  (3.1), 
9145 \family typewriter
9146
9147 \backslash
9148 doublespace
9149 \family default
9150  (3.1), 
9151 \family typewriter
9152
9153 \backslash
9154 onecolumn
9155 \family default
9156  (3.2), 
9157 \family typewriter
9158
9159 \backslash
9160 twocolumn
9161 \family default
9162  (3.2)
9163 \end_layout
9164
9165 \begin_layout Subsubsection
9166 Things that cannot be implemented
9167 \end_layout
9168
9169 \begin_layout Standard
9170 \SpecialChar ldots
9171  at least in any meaningful sort of way, so I suggest ignoring them.
9172  They are the references environment (2.13.3), and the deluxetable environment
9173  (2.15).
9174  If you really, really need to use deluxetable, I suggest editing it in
9175  a separate file with a text editor, then using 
9176 \family sans
9177 Insert\SpecialChar menuseparator
9178 Child
9179 \begin_inset space ~
9180 \end_inset
9181
9182 Document
9183 \family default
9184  to include it in your \SpecialChar LyX
9185  document.
9186  See the 
9187 \family typewriter
9188 aas_sample.lyx
9189 \family default
9190  file to see an example of this.
9191 \end_layout
9192
9193 \begin_layout Subsection
9194 FAQs, Tips, Tricks, and Other Ruminations
9195 \end_layout
9196
9197 \begin_layout Subsubsection
9198 Getting \SpecialChar LyX
9199  and AAS\SpecialChar TeX
9200  to cooperate
9201 \end_layout
9202
9203 \begin_layout Standard
9204 It can be a bit tricky to get \SpecialChar LyX
9205  to recognize a new layout and document class.
9206  When all else fails, do this:
9207 \end_layout
9208
9209 \begin_layout Enumerate
9210 Make certain that \SpecialChar LaTeX
9211  can find AAS\SpecialChar TeX
9212 .
9213  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
9214  distribution into a
9215  directory completely unrelated to \SpecialChar LaTeX
9216  or AAS\SpecialChar TeX
9217  and run \SpecialChar LaTeX
9218  on 
9219 \family typewriter
9220 sample.tex
9221 \family default
9222 .
9223 \end_layout
9224
9225 \begin_layout Enumerate
9226 Make certain that 
9227 \family typewriter
9228 aastex.layout
9229 \family default
9230  appears in \SpecialChar LyX
9231 's 
9232 \family typewriter
9233 layouts
9234 \family default
9235  folder
9236 \end_layout
9237
9238 \begin_layout Enumerate
9239 Rerun 
9240 \family sans
9241 Tools\SpecialChar menuseparator
9242 Reconfigure
9243 \family default
9244  in \SpecialChar LyX
9245 , then restart \SpecialChar LyX
9246 .
9247 \end_layout
9248
9249 \begin_layout Enumerate
9250 Open a regular new file, not from a template.
9251  Does AAS\SpecialChar TeX
9252  appear in the class list in 
9253 \family sans
9254 Document\SpecialChar menuseparator
9255 Settings
9256 \family default
9257 ?
9258 \end_layout
9259
9260 \begin_layout Standard
9261 If you get a warning from an existing AAS\SpecialChar TeX
9262  document about not being able
9263  to find the AAS\SpecialChar TeX
9264  layout or a message about 
9265 \begin_inset Quotes eld
9266 \end_inset
9267
9268 You should not mix title layouts with normal ones
9269 \begin_inset Quotes erd
9270 \end_inset
9271
9272 , things haven't been installed correctly.
9273 \end_layout
9274
9275 \begin_layout Subsubsection
9276 \SpecialChar LaTeX
9277  error processing a table 
9278 \end_layout
9279
9280 \begin_layout Standard
9281 \SpecialChar LyX
9282 , by default, attempts to center the table caption/title.
9283  This seems to produce a bad interaction in AAS\SpecialChar TeX
9284  so you should click somewhere
9285  in the caption/title, then select 
9286 \family sans
9287 Edit\SpecialChar menuseparator
9288 Paragraph
9289 \begin_inset space ~
9290 \end_inset
9291
9292 Settings
9293 \family default
9294 , then set the 
9295 \family sans
9296 Alignment
9297 \family default
9298  to 
9299 \family sans
9300 Block
9301 \family default
9302 .
9303  This took care of it for me.
9304 \end_layout
9305
9306 \begin_layout Subsubsection
9307 References
9308 \end_layout
9309
9310 \begin_layout Standard
9311 A couple of things: 1) I have noticed some funny spacing in the reference
9312  entries in the text.
9313  When you enter the bibliography item data, make sure their is 
9314 \emph on
9315 no
9316 \emph default
9317  space between the last author and the parenthesis setting off the year;
9318  
9319 \emph on
9320 e.
9321 \begin_inset space \thinspace{}
9322 \end_inset
9323
9324 g.
9325 \begin_inset space \space{}
9326 \end_inset
9327
9328
9329 \emph default
9330 type 
9331 \family typewriter
9332 Ressler(1992)
9333 \family default
9334 , not 
9335 \family typewriter
9336 Ressler (1992)
9337 \family default
9338 .
9339  2) Entering the references at all is not obvious.
9340  The easiest thing is to start typing your first reference at the end of
9341  the document, then mark it as type 
9342 \family sans
9343 References
9344 \family default
9345 .
9346  That will put a small gray box in front of what you just typed.
9347  Click on the box to fill in the rest of the information.
9348  For new references, go to the end of an existing reference and press return.
9349  That will create a new line with its own box, etc.
9350 \end_layout
9351
9352 \begin_layout Subsubsection
9353 Including EPS files
9354 \end_layout
9355
9356 \begin_layout Standard
9357 Even though AAS\SpecialChar TeX
9358  provides its own figure commands (
9359 \family typewriter
9360
9361 \backslash
9362 plotone
9363 \family default
9364 , for example), I much prefer \SpecialChar LaTeX
9365 's standard figure commands (with the default
9366  graphicx).
9367  You can insert the 
9368 \family typewriter
9369
9370 \backslash
9371 plotone
9372 \family default
9373 , etc.
9374 \begin_inset space ~
9375 \end_inset
9376
9377 commands as \SpecialChar TeX
9378  code into a Figure Float box if you desire, but I never have
9379  much luck getting the layout right.
9380  With the standard graphics, \SpecialChar LyX
9381  will insert a 
9382 \family typewriter
9383
9384 \backslash
9385 usepackage{graphicx}
9386 \family default
9387  command into the \SpecialChar LaTeX
9388  preamble and handle the figures in the standard \SpecialChar LaTeX2e
9389  way,
9390  interspersing the figures in the text.
9391  I believe ApJ accepts figures exactly this way now; AJ might still use
9392  the 
9393 \begin_inset Quotes eld
9394 \end_inset
9395
9396 stack everything at the end
9397 \begin_inset Quotes erd
9398 \end_inset
9399
9400  technique.
9401 \end_layout
9402
9403 \begin_layout Subsubsection
9404 Things I could have done, but didn't
9405 \end_layout
9406
9407 \begin_layout Standard
9408 There are a few 
9409 \begin_inset Quotes eld
9410 \end_inset
9411
9412 pretty
9413 \begin_inset Quotes erd
9414 \end_inset
9415
9416  things I could have implemented, but chose not to.
9417  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
9418  window,
9419  even though it is double-spaced in the paper manuscript.
9420  Also, I chose not to make separate layouts for the preprint and preprint2
9421  styles.
9422  Since I assume you will spend most of your time in the plain manuscript
9423  mode anyway, I decided not to chew up more disk space with this.
9424  
9425 \end_layout
9426
9427 \begin_layout Subsection
9428 Final Caveat
9429 \end_layout
9430
9431 \begin_layout Standard
9432 Your mileage may vary.
9433  I've now had papers published by both ApJ and AJ that have had 98% of the
9434  effort done in \SpecialChar LyX
9435 ; the last 2% was the \SpecialChar LaTeX
9436  post-processing and a few cleanups.
9437  I have had no trouble with the submission process, and I'm sure the journals
9438  were never aware that there might be a difference.
9439  So, go forth and publish!
9440 \end_layout
9441
9442 \begin_layout Section
9443 AMS \SpecialChar LaTeX
9444
9445 \end_layout
9446
9447 \begin_layout Standard
9448 by 
9449 \noun on
9450 David Johnson
9451 \noun default
9452 ; updated by 
9453 \noun on
9454 Richard Heck
9455 \end_layout
9456
9457 \begin_layout Standard
9458 \begin_inset VSpace bigskip
9459 \end_inset
9460
9461
9462 \end_layout
9463
9464 \begin_layout Standard
9465 \noindent
9466 The AMS \SpecialChar LaTeX
9467  layouts are set up to conform to suggested styles for mathematical
9468  papers to be submitted to American Mathematical Society publications.
9469  The layouts are not tailored to a specific journal, but easily can be.
9470  You should refer to the AMS documentation for specific instructions for
9471  each journal (usually it will entail only changing a single line in the
9472  \SpecialChar TeX
9473  output).
9474  That documentation is available on the Web at 
9475 \begin_inset Flex URL
9476 status open
9477
9478 \begin_layout Plain Layout
9479
9480 http://www.ams.org
9481 \end_layout
9482
9483 \end_inset
9484
9485  or by ftp at 
9486 \begin_inset Flex URL
9487 status open
9488
9489 \begin_layout Plain Layout
9490
9491 ftp://ftp.ams.org/pub/tex/amslatex/
9492 \end_layout
9493
9494 \end_inset
9495
9496 .
9497  These layouts are appropriate, and useful, for any mathematical writing.
9498  
9499 \end_layout
9500
9501 \begin_layout Standard
9502 There are two basic AMS \SpecialChar LaTeX
9503  layouts: 
9504 \end_layout
9505
9506 \begin_layout Itemize
9507 amsart: The standard AMS article format.
9508 \end_layout
9509
9510 \begin_layout Itemize
9511 amsbook: the standard AMS book (really, monograph) format.
9512  
9513 \end_layout
9514
9515 \begin_layout Standard
9516 The layouts themselves contain only the minimum necessary to use the AMS
9517  classes.
9518  They do not, in particular, contain any of the `theorem' environments used
9519  for setting theorems, lemmas, and the like.
9520  These are contained, instead, in the 
9521 \begin_inset Flex Code
9522 status collapsed
9523
9524 \begin_layout Plain Layout
9525 Theorems (AMS)
9526 \end_layout
9527
9528 \end_inset
9529
9530  module, which is loaded by default when you select one of the AMS classes.
9531  (It can also be used with other classes and can be removed, if you would
9532  rather use something else.) Less commonly used environments are in the 
9533 \begin_inset Flex Code
9534 status collapsed
9535
9536 \begin_layout Plain Layout
9537 Theorems (AMS-Extended)
9538 \end_layout
9539
9540 \end_inset
9541
9542  module, which must be loaded manually.
9543 \end_layout
9544
9545 \begin_layout Standard
9546 By default, theorems and the like are numbered consecutively throughout
9547  the document, but this may be modified by loading the module 
9548 \begin_inset Flex Code
9549 status collapsed
9550
9551 \begin_layout Plain Layout
9552 Theorems (Order by Section)
9553 \end_layout
9554
9555 \end_inset
9556
9557  or, if you are using 
9558 \begin_inset Flex Code
9559 status collapsed
9560
9561 \begin_layout Plain Layout
9562 book (AMS)
9563 \end_layout
9564
9565 \end_inset
9566
9567 , the module 
9568 \begin_inset Flex Code
9569 status collapsed
9570
9571 \begin_layout Plain Layout
9572 Theorems (Order by Chapter)
9573 \end_layout
9574
9575 \end_inset
9576
9577 .
9578  These will number the results as 
9579 \begin_inset Formula $n.m$
9580 \end_inset
9581
9582 , where the first number refers to the section (or chapter) and the second
9583  refers to the total number of results so far in that section (or chapter).
9584  Many environments are also available unnumbered.
9585  These are indicated by an asterisk at the end.
9586  If you happen to want 
9587 \emph on
9588 only
9589 \emph default
9590  unnumbered results, the module 
9591 \begin_inset Flex Code
9592 status collapsed
9593
9594 \begin_layout Plain Layout
9595 Theorems (Starred)
9596 \end_layout
9597
9598 \end_inset
9599
9600  provides that option.
9601 \end_layout
9602
9603 \begin_layout Standard
9604 Note that these modules do not 
9605 \emph on
9606 have
9607 \emph default
9608  to be used with the AMS classes.
9609  It is perfectly possible to use the 
9610 \begin_inset Flex Code
9611 status collapsed
9612
9613 \begin_layout Plain Layout
9614 Theorems (AMS)
9615 \end_layout
9616
9617 \end_inset
9618
9619  module, and the others mentioned, with other classes, such as 
9620 \begin_inset Flex Code
9621 status collapsed
9622
9623 \begin_layout Plain Layout
9624 article
9625 \end_layout
9626
9627 \end_inset
9628
9629
9630 \begin_inset Flex Code
9631 status collapsed
9632
9633 \begin_layout Plain Layout
9634 report
9635 \end_layout
9636
9637 \end_inset
9638
9639
9640 \begin_inset Flex Code
9641 status collapsed
9642
9643 \begin_layout Plain Layout
9644 book (KOMA-script)
9645 \end_layout
9646
9647 \end_inset
9648
9649 , and so forth.
9650 \end_layout
9651
9652 \begin_layout Subsection
9653 What these layouts provide
9654 \end_layout
9655
9656 \begin_layout Standard
9657 There is a long list of included environments provided by these layouts.
9658  In AMS-\SpecialChar LaTeX
9659 , there is, in fact, an opportunity to define an unlimited variety
9660  of `theorem' environments.
9661  However, the AMS recommends the environments that are available in \SpecialChar LyX
9662 .
9663  
9664 \end_layout
9665
9666 \begin_layout Standard
9667 The following environments—as well as the standard environments, such as
9668  
9669 \begin_inset Flex Noun
9670 status collapsed
9671
9672 \begin_layout Plain Layout
9673 section
9674 \end_layout
9675
9676 \end_inset
9677
9678
9679 \begin_inset Flex Noun
9680 status collapsed
9681
9682 \begin_layout Plain Layout
9683 bibliography
9684 \end_layout
9685
9686 \end_inset
9687
9688
9689 \begin_inset Flex Noun
9690 status collapsed
9691
9692 \begin_layout Plain Layout
9693 title
9694 \end_layout
9695
9696 \end_inset
9697
9698
9699 \begin_inset Flex Noun
9700 status collapsed
9701
9702 \begin_layout Plain Layout
9703 author
9704 \end_layout
9705
9706 \end_inset
9707
9708 , and 
9709 \begin_inset Flex Noun
9710 status collapsed
9711
9712 \begin_layout Plain Layout
9713 date
9714 \end_layout
9715
9716 \end_inset
9717
9718 —are provided by 
9719 \begin_inset Flex Code
9720 status collapsed
9721
9722 \begin_layout Plain Layout
9723 article (AMS)
9724 \end_layout
9725
9726 \end_inset
9727
9728  and 
9729 \begin_inset Flex Code
9730 status collapsed
9731
9732 \begin_layout Plain Layout
9733 book (AMS)
9734 \end_layout
9735
9736 \end_inset
9737
9738 :
9739 \end_layout
9740
9741 \begin_layout Description
9742 Address This should be the author's permanent address.
9743 \end_layout
9744
9745 \begin_layout Description
9746 Current
9747 \begin_inset space ~
9748 \end_inset
9749
9750 Address This should be the author's temporary address at the time of submission,
9751  if different from the Address.
9752 \end_layout
9753
9754 \begin_layout Description
9755 Email Author's e-mail address
9756 \end_layout
9757
9758 \begin_layout Description
9759 URL Author's Web address, if desired.
9760 \end_layout
9761
9762 \begin_layout Description
9763 Keywords Key words or phrases used to identify specific topics discussed
9764  in the paper.
9765 \end_layout
9766
9767 \begin_layout Description
9768 Subjectclass These refer to the AMS Subject Classifications, published and
9769  described in 
9770 \emph on
9771 Mathematical Reviews
9772 \emph default
9773 .
9774  These are also available online at the AMS cites listed above.
9775 \end_layout
9776
9777 \begin_layout Description
9778 Thanks
9779 \end_layout
9780
9781 \begin_layout Description
9782 Dedicatory
9783 \end_layout
9784
9785 \begin_layout Description
9786 Translator
9787 \end_layout
9788
9789 \begin_layout Standard
9790 The following environments are provided by both the 
9791 \begin_inset Flex Code
9792 status collapsed
9793
9794 \begin_layout Plain Layout
9795 Theorems
9796 \end_layout
9797
9798 \end_inset
9799
9800  and 
9801 \begin_inset Flex Code
9802 status collapsed
9803
9804 \begin_layout Plain Layout
9805 Theorems (AMS)
9806 \end_layout
9807
9808 \end_inset
9809
9810  modules, in the latter case in both starred (unnumbered) and unstarred
9811  (numbered) versions.
9812  These same environments are provided only in the starred versions by the
9813  
9814 \begin_inset Flex Code
9815 status collapsed
9816
9817 \begin_layout Plain Layout
9818 Theorems (Starred)
9819 \end_layout
9820
9821 \end_inset
9822
9823  module:
9824 \end_layout
9825
9826 \begin_layout Theorem
9827 This is typically used for the statements of major results.
9828  
9829 \end_layout
9830
9831 \begin_layout Corollary*
9832 This is used for statements which follow fairly directly from previous statement
9833 s.
9834  Again, these can be major results.
9835  
9836 \end_layout
9837
9838 \begin_layout Lemma
9839 These are smaller results needed to prove other statements.
9840 \end_layout
9841
9842 \begin_layout Proposition
9843 These are less major results which (hopefully) add to the general theory
9844  being discussed.
9845 \end_layout
9846
9847 \begin_layout Conjecture
9848 These are statements provided without justification, which the author does
9849  not know how to prove, but which seem to be true (to the author, at least).
9850 \end_layout
9851
9852 \begin_layout Definition*
9853 Guess what this is for.
9854  The font is different for this environment than for the previous ones.
9855  
9856 \end_layout
9857
9858 \begin_layout Example*
9859 Used for examples illustrating proven results.
9860 \end_layout
9861
9862 \begin_layout Problem
9863 It's not really known what this is for.
9864  You should figure it out.
9865 \end_layout
9866
9867 \begin_layout Exercise*
9868 Write a description for this one.
9869 \end_layout
9870
9871 \begin_layout Remark
9872 This environment is also a type of theorem, usually a lesser sort of observation.
9873 \end_layout
9874
9875 \begin_layout Claim*
9876 Often used in the course of giving a proof of a larger result.
9877 \end_layout
9878
9879 \begin_layout Case
9880 Generally, these are used to break up long arguments, using specific instances
9881  of some condition.
9882  
9883 \end_layout
9884
9885 \begin_layout Case
9886 The numbering scheme for cases is on its own, not together with other numbered
9887  statements.
9888  
9889 \end_layout
9890
9891 \begin_layout Proof
9892 At the end of this environment, a QED symbol (usually a square, but it can
9893  vary with different styles) is placed.
9894  If you want to have other environments within this one—for example, Case
9895  environments—and have the QED symbol appear only after them, then the other
9896  environments need to be nested within the proof environment.
9897  See the section 
9898 \emph on
9899 Nesting Environments
9900 \emph default
9901  of the 
9902 \emph on
9903 User's Guide
9904 \emph default
9905  for information on nesting.
9906 \end_layout
9907
9908 \begin_layout Standard
9909 And these environments are provided by 
9910 \begin_inset Flex Code
9911 status collapsed
9912
9913 \begin_layout Plain Layout
9914 Theorems (AMS-Extended)
9915 \end_layout
9916
9917 \end_inset
9918
9919 :
9920 \end_layout
9921
9922 \begin_layout Criterion*
9923 A required condition.
9924 \end_layout
9925
9926 \begin_layout Algorithm*
9927 A general procedure to be used.
9928 \end_layout
9929
9930 \begin_layout Axiom*
9931 This is a property or statement taken as true within the system being discussed.
9932 \end_layout
9933
9934 \begin_layout Condition*
9935 Sometimes used to state a condition assumed within the present context of
9936  discussion.
9937 \end_layout
9938
9939 \begin_layout Note*
9940 Similar to a Remark.
9941 \end_layout
9942
9943 \begin_layout Notation*
9944 Used for the explanation of, yes, notation.
9945 \end_layout
9946
9947 \begin_layout Summary
9948 Do we really need to tell you? 
9949 \end_layout
9950
9951 \begin_layout Acknowledgement*
9952 Acknowledgement.
9953 \end_layout
9954
9955 \begin_layout Conclusion*
9956 Sometimes used at the end of a long train of argument.
9957 \end_layout
9958
9959 \begin_layout Fact
9960 Used in a way similar to Proposition, though perhaps lower on the scale.
9961 \end_layout
9962
9963 \begin_layout Standard
9964 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
9965  and AMS fonts
9966  packages.
9967  They need to be available on your system in order to use these environments.
9968 \end_layout
9969
9970 \begin_layout Section
9971 AGU journals (
9972 \family sans
9973 aguplus
9974 \family default
9975 )
9976 \end_layout
9977
9978 \begin_layout Standard
9979 by 
9980 \shape smallcaps
9981 Martin Vermeer
9982 \end_layout
9983
9984 \begin_layout Subsection
9985 Description
9986 \end_layout
9987
9988 \begin_layout Standard
9989 These are the layout files for some of the journals of the American Geophysical
9990  Society.
9991  It is assumed that you have both the AGU's own class files and AGUplus
9992  installed (everything to be found at
9993 \begin_inset Flex URL
9994 status collapsed
9995
9996 \begin_layout Plain Layout
9997
9998 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
9999 \end_layout
10000
10001 \end_inset
10002
10003 ).
10004 \end_layout
10005
10006 \begin_layout Subsection
10007 New styles
10008 \end_layout
10009
10010 \begin_layout Standard
10011 Redefined are 
10012 \family sans
10013 Paragraph
10014 \family default
10015
10016 \family sans
10017 Paragraph*
10018 \family default
10019 .
10020  They are still called this in the \SpecialChar LyX
10021  GUI, though their \SpecialChar LaTeX
10022  equivalents in the
10023  AGU classes are 
10024 \family sans
10025 Subsubsubsection
10026 \family default
10027  and 
10028 \family sans
10029 Subsubsubsection*
10030 \family default
10031 .
10032 \end_layout
10033
10034 \begin_layout Standard
10035 Newly defined styles are 
10036 \family sans
10037 Left_Header
10038 \family default
10039
10040 \family sans
10041 Right_Header
10042 \family default
10043
10044 \family sans
10045 Received
10046 \family default
10047
10048 \family sans
10049 Revised
10050 \family default
10051
10052 \family sans
10053 Accepted
10054 \family default
10055
10056 \family sans
10057 CCC
10058 \family default
10059
10060 \family sans
10061 PaperId
10062 \family default
10063
10064 \family sans
10065 AuthorAddr
10066 \family default
10067
10068 \family sans
10069 SlugComment
10070 \family default
10071 .
10072  These are mostly manuscript attributes and defined in the AGU class documentati
10073 on.
10074 \end_layout
10075
10076 \begin_layout Standard
10077 I suspect this is still badly incomplete.
10078 \end_layout
10079
10080 \begin_layout Subsection
10081 New floats
10082 \end_layout
10083
10084 \begin_layout Standard
10085
10086 \family sans
10087 Planotable
10088 \family default
10089  and 
10090 \family sans
10091 Plate
10092 \family default
10093 .
10094  We also have a new 
10095 \family sans
10096 Table_Caption
10097 \family default
10098 .
10099 \end_layout
10100
10101 \begin_layout Subsection
10102 Supported journals
10103 \end_layout
10104
10105 \begin_layout Itemize
10106
10107 \emph on
10108 Journal of Geophysical Research
10109 \emph default
10110
10111 \family typewriter
10112 jgrga.layout
10113 \family default
10114  — Martin Vermeer
10115 \end_layout
10116
10117 \begin_layout Standard
10118 Add your own, it isn't so hard! Look at the 
10119 \family typewriter
10120 jgrga.layout
10121 \family default
10122  example and 
10123 \family typewriter
10124 aguplus.inc
10125 \family default
10126 .
10127 \end_layout
10128
10129 \begin_layout Subsection
10130 Bugs and things to remember
10131 \end_layout
10132
10133 \begin_layout Standard
10134 In order to use the new layouts, you must remember to do the following for
10135  a new document:
10136 \end_layout
10137
10138 \begin_layout Enumerate
10139
10140 \emph on
10141 Turn off babel
10142 \emph default
10143 .
10144  This can be done in the 
10145 \family sans
10146 Layout\SpecialChar menuseparator
10147 Document
10148 \family default
10149  or 
10150 \family sans
10151 Document\SpecialChar menuseparator
10152 Settings
10153 \family default
10154  menu item.
10155  (AGU articles are always in English, right? So 
10156 \emph on
10157 don't
10158 \emph default
10159  choose a language.)
10160 \end_layout
10161
10162 \begin_layout Enumerate
10163 Enter 
10164 \family typewriter
10165 jgrga
10166 \family default
10167  into the document's 
10168 \family sans
10169 Extra Options
10170 \family default
10171  field.
10172  (Yes, this is a bug.)
10173 \end_layout
10174
10175 \begin_layout Enumerate
10176 Make sure you use the 
10177 \family typewriter
10178 agu.bst
10179 \family default
10180  bibliography style, by entering 
10181 \family sans
10182 agu
10183 \family default
10184  into the second field of the Bib\SpecialChar TeX
10185  inset.
10186  None of the standard styles will do.
10187 \end_layout
10188
10189 \begin_layout Section
10190 Broadway
10191 \end_layout
10192
10193 \begin_layout Standard
10194 by 
10195 \shape smallcaps
10196 Garst Reese
10197 \end_layout
10198
10199 \begin_layout Subsection
10200 Introduction
10201 \end_layout
10202
10203 \begin_layout Standard
10204 Broadway is for writing plays.
10205  The format is more decorative than Hollywood, and much less standardized.
10206  This format should be suitable for workshops.
10207 \end_layout
10208
10209 \begin_layout Subsection
10210 Special problems
10211 \end_layout
10212
10213 \begin_layout Standard
10214 The same as in Hollywood.
10215 \end_layout
10216
10217 \begin_layout Subsection
10218 Special features
10219 \end_layout
10220
10221 \begin_layout Standard
10222 Insert the 
10223 \family sans
10224 Speaker
10225 \family default
10226  names as labels then cross-reference the label to insert the name.
10227  The cross-reference dialog will show the current cast of characters.
10228 \end_layout
10229
10230 \begin_layout Subsection
10231 Paper size and Margins
10232 \end_layout
10233
10234 \begin_layout Standard
10235 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10236 \end_layout
10237
10238 \begin_layout Subsection
10239 Environments
10240 \end_layout
10241
10242 \begin_layout Standard
10243 The following environments are available.
10244  You can use broadway.bind to get the bind keys shown at the right.
10245 \end_layout
10246
10247 \begin_layout Itemize
10248
10249 \family sans
10250 Standard
10251 \begin_inset Newline newline
10252 \end_inset
10253
10254
10255 \family default
10256 You should not have to use this, but it is here for anything that does not
10257  fit otherwise.
10258 \end_layout
10259
10260 \begin_layout Itemize
10261
10262 \family sans
10263 Narrative
10264 \begin_inset space \hfill{}
10265 \end_inset
10266
10267 M-z n
10268 \begin_inset Newline newline
10269 \end_inset
10270
10271
10272 \family default
10273 Used to describe stage setting and the action.
10274  First use of speaker names in all CAPs.
10275 \end_layout
10276
10277 \begin_layout Itemize
10278
10279 \family sans
10280 ACT
10281 \begin_inset space \hfill{}
10282 \end_inset
10283
10284 M-z a
10285 \begin_inset Newline newline
10286 \end_inset
10287
10288
10289 \family default
10290 Automatically numbered.
10291  On screen it will be arabic, but will print as Roman.
10292 \end_layout
10293
10294 \begin_layout Itemize
10295
10296 \family sans
10297 ACT*
10298 \begin_inset space \hfill{}
10299 \end_inset
10300
10301 M-z S at
10302 \begin_inset Newline newline
10303 \end_inset
10304
10305
10306 \family default
10307 Subtitle for 
10308 \family sans
10309 ACT.
10310
10311 \family default
10312  It is just centered text.
10313 \end_layout
10314
10315 \begin_layout Itemize
10316
10317 \family sans
10318 SCENE
10319 \begin_inset space \hfill{}
10320 \end_inset
10321
10322 M-z S-S
10323 \begin_inset Newline newline
10324 \end_inset
10325
10326
10327 \family default
10328 Not automatically numbered.
10329  You supply the number.
10330  This is because I couldn't figure out how.
10331 \end_layout
10332
10333 \begin_layout Itemize
10334
10335 \family sans
10336 AT_RISE:
10337 \begin_inset space \hfill{}
10338 \end_inset
10339
10340 M-z S-R
10341 \begin_inset Newline newline
10342 \end_inset
10343
10344
10345 \family default
10346 A special case of Narrative to describe the setting and action as the curtain
10347  rises.
10348 \end_layout
10349
10350 \begin_layout Itemize
10351
10352 \family sans
10353 Speaker
10354 \begin_inset space \hfill{}
10355 \end_inset
10356
10357 M-z s
10358 \begin_inset Newline newline
10359 \end_inset
10360
10361
10362 \family default
10363 The speaker's (actor's) title, centered in all CAPS.
10364 \end_layout
10365
10366 \begin_layout Itemize
10367
10368 \family sans
10369 Parenthetical
10370 \begin_inset space \hfill{}
10371 \end_inset
10372
10373 M-z p
10374 \begin_inset Newline newline
10375 \end_inset
10376
10377
10378 \family default
10379 Instructions to the speaker.
10380  The parentheses are automatically inserted.
10381  The ( will appear on screen, but both will be in the printed play.
10382  This environment is only used within 
10383 \family sans
10384 Dialogue
10385 \family default
10386 .
10387 \end_layout
10388
10389 \begin_layout Itemize
10390
10391 \family sans
10392 Dialogue
10393 \begin_inset space \hfill{}
10394 \end_inset
10395
10396 M-z d
10397 \begin_inset Newline newline
10398 \end_inset
10399
10400
10401 \family default
10402 What the Speaker says.
10403 \end_layout
10404
10405 \begin_layout Itemize
10406
10407 \family sans
10408 CURTAIN
10409 \begin_inset space \hfill{}
10410 \end_inset
10411
10412 M-z S-C
10413 \begin_inset Newline newline
10414 \end_inset
10415
10416
10417 \family default
10418 The curtain comes down.
10419 \end_layout
10420
10421 \begin_layout Itemize
10422
10423 \family sans
10424 Title
10425 \begin_inset space \hfill{}
10426 \end_inset
10427
10428 M-z S-T
10429 \end_layout
10430
10431 \begin_layout Itemize
10432
10433 \family sans
10434 Author
10435 \begin_inset space \hfill{}
10436 \end_inset
10437
10438 M-z S-A
10439 \end_layout
10440
10441 \begin_layout Itemize
10442
10443 \family sans
10444 Right_Address
10445 \begin_inset space \hfill{}
10446 \end_inset
10447
10448 M-z r
10449 \end_layout
10450
10451 \begin_layout Standard
10452 Hello there.
10453 \end_layout
10454
10455 \begin_layout Section
10456 Dinbrief
10457 \end_layout
10458
10459 \begin_layout Standard
10460 The document class 
10461 \family sans
10462 dinbrief
10463 \family default
10464  can be used to type letters according to German conventions.
10465  A template file is included in 
10466 \family typewriter
10467 .../lyx/share/templates
10468 \family default
10469  for you to use as a starting point.
10470 \end_layout
10471
10472 \begin_layout Section
10473 EGS journals (
10474 \family sans
10475 egs
10476 \family default
10477 )
10478 \end_layout
10479
10480 \begin_layout Standard
10481 by 
10482 \shape smallcaps
10483 Martin Vermeer
10484 \end_layout
10485
10486 \begin_layout Subsection
10487 Description
10488 \end_layout
10489
10490 \begin_layout Standard
10491 This is the layout file for the European Geophysical Society journals.
10492  The needed 
10493 \family typewriter
10494 egs.cls
10495 \family default
10496  can be downloaded from the web site of the EGS under 
10497 \begin_inset Flex URL
10498 status collapsed
10499
10500 \begin_layout Plain Layout
10501
10502 www.copernicus.org
10503 \end_layout
10504
10505 \end_inset
10506
10507 .
10508 \end_layout
10509
10510 \begin_layout Subsection
10511 New styles
10512 \end_layout
10513
10514 \begin_layout Standard
10515
10516 \family sans
10517 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
10518  Accepted
10519 \family default
10520
10521 \family sans
10522 Offsets
10523 \family default
10524 .
10525  The current layout file is unfortunately very unmodular and would benefit
10526  from using the various 
10527 \family typewriter
10528 std*.inc
10529 \family default
10530  file inclusions.
10531 \end_layout
10532
10533 \begin_layout Section
10534 Elsevier Journals
10535 \end_layout
10536
10537 \begin_layout Standard
10538 See the \SpecialChar LyX
10539  template file 
10540 \family typewriter
10541 elsarticle.lyx
10542 \family default
10543 .
10544  It contains all infos you need.
10545 \end_layout
10546
10547 \begin_layout Section
10548 Foils [aka 
10549 \family sans
10550 Foil\SpecialChar TeX
10551
10552 \family default
10553 ]
10554 \begin_inset CommandInset label
10555 LatexCommand label
10556 name "sec:foiltex"
10557
10558 \end_inset
10559
10560
10561 \end_layout
10562
10563 \begin_layout Standard
10564 by 
10565 \noun on
10566 Allan Rae
10567 \end_layout
10568
10569 \begin_layout Subsection
10570 Introduction
10571 \end_layout
10572
10573 \begin_layout Standard
10574 This section describes how to use \SpecialChar LyX
10575  to make slides for overhead projectors.
10576  There are two document classes that can do this: the default slides class
10577  and the 
10578 \family sans
10579 Foil\SpecialChar TeX
10580
10581 \family default
10582  slides class.
10583  This section documents the latter.
10584 \end_layout
10585
10586 \begin_layout Standard
10587 I'm going to say this again, nice and clear, so that there's no misunderstanding
10588 :
10589 \end_layout
10590
10591 \begin_layout Standard
10592 \begin_inset VSpace bigskip
10593 \end_inset
10594
10595
10596 \end_layout
10597
10598 \begin_layout Standard
10599 \align center
10600
10601 \size large
10602 This section documents the class 
10603 \begin_inset Quotes eld
10604 \end_inset
10605
10606
10607 \family sans
10608 slides (FoilTeX)
10609 \family default
10610
10611 \begin_inset Quotes erd
10612 \end_inset
10613
10614  
10615 \emph on
10616 only.
10617 \end_layout
10618
10619 \begin_layout Standard
10620 \begin_inset VSpace bigskip
10621 \end_inset
10622
10623
10624 \end_layout
10625
10626 \begin_layout Standard
10627 If you're looking for the documentation for 
10628 \begin_inset Quotes eld
10629 \end_inset
10630
10631
10632 \family sans
10633 slides (default)
10634 \family default
10635
10636 \begin_inset Quotes erd
10637 \end_inset
10638
10639 , check out section
10640 \begin_inset space ~
10641 \end_inset
10642
10643
10644 \begin_inset CommandInset ref
10645 LatexCommand ref
10646 reference "sec:slitex"
10647
10648 \end_inset
10649
10650 .
10651  If your machine doesn't have the 
10652 \family sans
10653 foils
10654 \family default
10655  class [
10656 \begin_inset Quotes eld
10657 \end_inset
10658
10659
10660 \family sans
10661 slides (FoilTeX)
10662 \family default
10663
10664 \begin_inset Quotes erd
10665 \end_inset
10666
10667 ] installed, you'll probably have to use the default 
10668 \family sans
10669 slides
10670 \family default
10671  class, which isn't quite as good as 
10672 \family sans
10673 foils.
10674 \end_layout
10675
10676 \begin_layout Standard
10677 The 
10678 \family sans
10679 foils
10680 \family default
10681  class is designed for use with version 2.1 of the 
10682 \family sans
10683 foils.cls
10684 \family default
10685  \SpecialChar LaTeX
10686  class file which is now an integral part of \SpecialChar LaTeX2e
10687 .
10688 \end_layout
10689
10690 \begin_layout Subsection
10691 Getting Started
10692 \end_layout
10693
10694 \begin_layout Standard
10695 Obviously, to use this document class, you need to select 
10696 \begin_inset Quotes eld
10697 \end_inset
10698
10699
10700 \family sans
10701 slides (FoilTeX)
10702 \family default
10703
10704 \begin_inset Quotes erd
10705 \end_inset
10706
10707  from the 
10708 \family sans
10709 Class
10710 \family default
10711  entry in the 
10712 \family sans
10713 Document
10714 \begin_inset space ~
10715 \end_inset
10716
10717 Layout
10718 \family default
10719  dialog.
10720  There are some settings in the 
10721 \family sans
10722 Document
10723 \begin_inset space ~
10724 \end_inset
10725
10726 Layout
10727 \family default
10728  dialog that you should know about that are specific to this class:
10729 \end_layout
10730
10731 \begin_layout Itemize
10732 Don't change the options 
10733 \family sans
10734 Sides
10735 \family default
10736  and 
10737 \family sans
10738 Columns
10739 \family default
10740  on the 
10741 \family sans
10742 Document
10743 \begin_inset space ~
10744 \end_inset
10745
10746 Layout
10747 \family default
10748  dialog.
10749  They're ignored by the 
10750 \family sans
10751 foils
10752 \family default
10753  class.
10754 \end_layout
10755
10756 \begin_layout Itemize
10757 The default font size is 20
10758 \begin_inset space \thinspace{}
10759 \end_inset
10760
10761 pt with the other options being 17
10762 \begin_inset space \thinspace{}
10763 \end_inset
10764
10765 pt, 25
10766 \begin_inset space \thinspace{}
10767 \end_inset
10768
10769 pt and 30
10770 \begin_inset space \thinspace{}
10771 \end_inset
10772
10773 pt.
10774 \end_layout
10775
10776 \begin_layout Itemize
10777 The default font is 
10778 \family sans
10779 sans
10780 \family default
10781  
10782 \family sans
10783 serif
10784 \family default
10785  but all math equations are still typeset in the usual roman font.
10786 \end_layout
10787
10788 \begin_layout Itemize
10789
10790 \family sans
10791 Foil\SpecialChar TeX
10792
10793 \family default
10794  supports A4 and Letter paper sizes as well as a special size for working
10795  with 35
10796 \begin_inset space \thinspace{}
10797 \end_inset
10798
10799 mm slides.
10800  It doesn't support A5, B5, legal or executive paper sizes.
10801 \end_layout
10802
10803 \begin_layout Itemize
10804 Don't bother changing the 
10805 \family sans
10806 Float Placement
10807 \family default
10808  settings because they are ignored anyway.
10809  All floats appear where they are defined in the text.
10810 \end_layout
10811
10812 \begin_layout Itemize
10813 The 
10814 \family sans
10815 Pagestyle
10816 \family default
10817  setting behaves a bit differently for this class.
10818  
10819 \family sans
10820 Foil\SpecialChar TeX
10821
10822 \family default
10823  provides extensive footer and header capabilities including a user-defined
10824  logo.
10825  See section
10826 \begin_inset space ~
10827 \end_inset
10828
10829
10830 \begin_inset CommandInset ref
10831 LatexCommand ref
10832 reference "sec:foilfoot"
10833
10834 \end_inset
10835
10836  for more details.
10837  The title page is treated differently to all other pages in the document
10838  and is 
10839 \emph on
10840 always
10841 \emph default
10842  unnumbered and 
10843 \emph on
10844 always
10845 \emph default
10846  has the logo centered at the bottom of the page (if one is defined).
10847  The possible page style choices and what they do are as follows:
10848 \begin_inset Separator parbreak
10849 \end_inset
10850
10851
10852 \end_layout
10853
10854 \begin_deeper
10855 \begin_layout Labeling
10856 \labelwidthstring MMMMMMM
10857
10858 \family sans
10859 \series bold
10860 empty
10861 \family default
10862 \series default
10863  The final output contains no page numbers, or other headers or footers
10864  (except footnotes of course).
10865  
10866 \end_layout
10867
10868 \begin_layout Labeling
10869 \labelwidthstring MMMMMMM
10870
10871 \family sans
10872 \series bold
10873 plain
10874 \family default
10875 \series default
10876  The final output contains page numbers centered at the bottom of the page.
10877  No other headings or footers (other than footnotes).
10878 \end_layout
10879
10880 \begin_layout Labeling
10881 \labelwidthstring MMMMMMM
10882
10883 \series bold
10884 foilheadings
10885 \series default
10886  Page numbers in lower right corner.
10887  Additional headers and footers are also shown.
10888  This is also the default.
10889 \end_layout
10890
10891 \begin_layout Labeling
10892 \labelwidthstring MMMMMMM
10893
10894 \series bold
10895 fancy
10896 \series default
10897  Gives you access to the 
10898 \family sans
10899 fancyheadings
10900 \family default
10901  package although its use with 
10902 \family sans
10903 Foil\SpecialChar TeX
10904
10905 \family default
10906  is discouraged by the writer of the 
10907 \family sans
10908 Foil\SpecialChar TeX
10909
10910 \family default
10911  package because of some potential page layout clashes.
10912 \end_layout
10913
10914 \end_deeper
10915 \begin_layout Subsubsection
10916 Extra Options
10917 \end_layout
10918
10919 \begin_layout Standard
10920 The following options may be used in the extra class options in the 
10921 \family sans
10922 Document\SpecialChar menuseparator
10923 Settings
10924 \family default
10925  dialog.
10926 \end_layout
10927
10928 \begin_layout Labeling
10929 \labelwidthstring MMMMMMx
10930
10931 \series bold
10932 35mmSlide
10933 \series default
10934  This sets up the page layout for 7.33
10935 \begin_inset space \thinspace{}
10936 \end_inset
10937
10938 in by 11
10939 \begin_inset space \thinspace{}
10940 \end_inset
10941
10942 in paper, which is about the same aspect ratio as a 35
10943 \begin_inset space \thinspace{}
10944 \end_inset
10945
10946 mm slide, making it a bit easier to work with this medium.
10947 \end_layout
10948
10949 \begin_layout Labeling
10950 \labelwidthstring MMMMMMx
10951
10952 \series bold
10953 headrule
10954 \series default
10955  Places a rule across the page below the header on every page except the
10956  title page.
10957 \end_layout
10958
10959 \begin_layout Labeling
10960 \labelwidthstring MMMMMMx
10961
10962 \series bold
10963 footrule
10964 \series default
10965  Places a rule across the page above the footer on every page except the
10966  title page.
10967 \end_layout
10968
10969 \begin_layout Labeling
10970 \labelwidthstring MMMMMMx
10971
10972 \series bold
10973 dvips
10974 \series default
10975  This is automatically set each time you create a new 
10976 \family sans
10977 foils
10978 \family default
10979  document.
10980  This option tells 
10981 \family sans
10982 Foil\SpecialChar TeX
10983
10984 \family default
10985  to use the dvips driver to rotate those pages that are set as landscape
10986  foils.
10987 \end_layout
10988
10989 \begin_layout Labeling
10990 \labelwidthstring MMMMMMx
10991
10992 \series bold
10993 landscape
10994 \series default
10995  Simply changes the page dimensions to those of a landscape page but doesn't
10996  do any rotation.
10997  Thus if you use this option you need to use an external program to rotate
10998  each page or feed your paper through your printer as landscape.
10999  Note that this option effectively reverses the roles of the 
11000 \family sans
11001 Foilhead
11002 \family default
11003  and 
11004 \family sans
11005 Rotatefoilhead
11006 \family default
11007  environments (don't worry these are described in the next section).
11008 \end_layout
11009
11010 \begin_layout Labeling
11011 \labelwidthstring MMMMMMx
11012
11013 \series bold
11014 leqno
11015 \series default
11016  Equation numbers on the left.
11017 \end_layout
11018
11019 \begin_layout Labeling
11020 \labelwidthstring MMMMMMx
11021
11022 \series bold
11023 fleqn
11024 \series default
11025  Flush-left equations.
11026 \end_layout
11027
11028 \begin_layout Subsection
11029 Supported Environments
11030 \end_layout
11031
11032 \begin_layout Standard
11033 Most of the environments commonly supported in other classes are also supported
11034  by the 
11035 \family sans
11036 foils
11037 \family default
11038  class.
11039  There are several additional environments provided by 
11040 \family sans
11041 Foil\SpecialChar TeX
11042
11043 \family default
11044  as well as a couple added by \SpecialChar LyX
11045 .
11046  The following environments are shared with other classes:
11047 \end_layout
11048
11049 \begin_layout Standard
11050 \begin_inset Flex Multiple Columns
11051 status open
11052
11053 \begin_layout Itemize
11054
11055 \family sans
11056 Standard
11057 \end_layout
11058
11059 \begin_layout Itemize
11060
11061 \family sans
11062 Itemize
11063 \end_layout
11064
11065 \begin_layout Itemize
11066
11067 \family sans
11068 Enumerate
11069 \end_layout
11070
11071 \begin_layout Itemize
11072
11073 \family sans
11074 Description
11075 \end_layout
11076
11077 \begin_layout Itemize
11078
11079 \family sans
11080 List
11081 \end_layout
11082
11083 \begin_layout Itemize
11084
11085 \family sans
11086 \SpecialChar LyX
11087 -Code
11088 \end_layout
11089
11090 \begin_layout Itemize
11091
11092 \family sans
11093 Verse
11094 \end_layout
11095
11096 \begin_layout Itemize
11097
11098 \family sans
11099 Quote
11100 \end_layout
11101
11102 \begin_layout Itemize
11103
11104 \family sans
11105 Quotation
11106 \end_layout
11107
11108 \begin_layout Itemize
11109
11110 \family sans
11111 Title
11112 \end_layout
11113
11114 \begin_layout Itemize
11115
11116 \family sans
11117 Author
11118 \end_layout
11119
11120 \begin_layout Itemize
11121
11122 \family sans
11123 Date
11124 \end_layout
11125
11126 \begin_layout Itemize
11127
11128 \family sans
11129 Abstract
11130 \end_layout
11131
11132 \begin_layout Itemize
11133
11134 \family sans
11135 Bibliography
11136 \end_layout
11137
11138 \begin_layout Itemize
11139
11140 \family sans
11141 Address
11142 \end_layout
11143
11144 \begin_layout Itemize
11145
11146 \family sans
11147 RightAddress
11148 \end_layout
11149
11150 \begin_layout Itemize
11151
11152 \family sans
11153 Caption
11154 \end_layout
11155
11156 \begin_layout Itemize
11157
11158 \family sans
11159 Comment
11160 \end_layout
11161
11162 \end_inset
11163
11164
11165 \end_layout
11166
11167 \begin_layout Standard
11168 That is, all the major environments apart from the sectioning environments.
11169  Since foils are essentially self-contained sections, with a title and body,
11170  
11171 \family sans
11172 Foil\SpecialChar TeX
11173
11174 \family default
11175  provides specific commands for starting new foils and these are:
11176 \end_layout
11177
11178 \begin_layout Itemize
11179
11180 \family sans
11181 Foilhead
11182 \end_layout
11183
11184 \begin_layout Itemize
11185
11186 \family sans
11187 Rotatefoilhead
11188 \end_layout
11189
11190 \begin_layout Standard
11191 \SpecialChar LyX
11192  also provides slightly modified versions of these two environments called:
11193 \end_layout
11194
11195 \begin_layout Itemize
11196
11197 \family sans
11198 ShortFoilhead
11199 \end_layout
11200
11201 \begin_layout Itemize
11202
11203 \family sans
11204 ShortRotatefoilhead
11205 \end_layout
11206
11207 \begin_layout Standard
11208 and the differences will be explained in the next section.
11209 \end_layout
11210
11211 \begin_layout Standard
11212 Since foils are often used in presenting ideas or new theorems and such
11213  
11214 \family sans
11215 Foil\SpecialChar TeX
11216
11217 \family default
11218  also provides a comprehensive box of goodies for presenting them:
11219 \end_layout
11220
11221 \begin_layout Standard
11222 \begin_inset Flex Multiple Columns
11223 status open
11224
11225 \begin_layout Itemize
11226
11227 \family sans
11228 Theorem
11229 \end_layout
11230
11231 \begin_layout Itemize
11232
11233 \family sans
11234 Lemma
11235 \end_layout
11236
11237 \begin_layout Itemize
11238
11239 \family sans
11240 Corollary
11241 \end_layout
11242
11243 \begin_layout Itemize
11244
11245 \family sans
11246 Proposition
11247 \end_layout
11248
11249 \begin_layout Itemize
11250
11251 \family sans
11252 Definition
11253 \end_layout
11254
11255 \begin_layout Itemize
11256
11257 \family sans
11258 Proof
11259 \end_layout
11260
11261 \begin_layout Itemize
11262
11263 \family sans
11264 Theorem*
11265 \end_layout
11266
11267 \begin_layout Itemize
11268
11269 \family sans
11270 Lemma*
11271 \end_layout
11272
11273 \begin_layout Itemize
11274
11275 \family sans
11276 Corollary*
11277 \end_layout
11278
11279 \begin_layout Itemize
11280
11281 \family sans
11282 Proposition*
11283 \end_layout
11284
11285 \begin_layout Itemize
11286
11287 \family sans
11288 Definition*
11289 \end_layout
11290
11291 \end_inset
11292
11293
11294 \end_layout
11295
11296 \begin_layout Standard
11297 The starred versions are unnumbered while the unstarred versions are numbered.
11298  There are also two list environments added by \SpecialChar LyX
11299  and these are:
11300 \end_layout
11301
11302 \begin_layout Itemize
11303
11304 \family sans
11305 TickList
11306 \end_layout
11307
11308 \begin_layout Itemize
11309
11310 \family sans
11311 CrossList
11312 \end_layout
11313
11314 \begin_layout Standard
11315
11316 \family sans
11317 Foil\SpecialChar TeX
11318
11319 \family default
11320  provides some powerful header and footer capabilities that are best set
11321  in the preamble although they may be set at any point in a document.
11322  If you want to change these settings in your document the best place to
11323  do so is at the very top of a foil, i.
11324 \begin_inset space \thinspace{}
11325 \end_inset
11326
11327 e.
11328 \emph on
11329
11330 \begin_inset space \space{}
11331 \end_inset
11332
11333
11334 \emph default
11335 straight after the foilhead.
11336 \end_layout
11337
11338 \begin_layout Standard
11339 For this purpose, the following command styles are provided [
11340 \shape smallcaps
11341 Martin Vermeer
11342 \shape default
11343 ]:
11344 \end_layout
11345
11346 \begin_layout Standard
11347 \begin_inset Flex Multiple Columns
11348 status open
11349
11350 \begin_layout Itemize
11351
11352 \family sans
11353 My
11354 \begin_inset space ~
11355 \end_inset
11356
11357 Logo
11358 \end_layout
11359
11360 \begin_layout Itemize
11361
11362 \family sans
11363 Restriction
11364 \end_layout
11365
11366 \begin_layout Itemize
11367
11368 \family sans
11369 Right
11370 \begin_inset space ~
11371 \end_inset
11372
11373 Footer
11374 \end_layout
11375
11376 \begin_layout Itemize
11377
11378 \family sans
11379 Right
11380 \begin_inset space ~
11381 \end_inset
11382
11383 Header
11384 \end_layout
11385
11386 \begin_layout Itemize
11387
11388 \family sans
11389 Left
11390 \begin_inset space ~
11391 \end_inset
11392
11393 Header
11394 \family default
11395
11396 \begin_inset Separator parbreak
11397 \end_inset
11398
11399
11400 \end_layout
11401
11402 \begin_deeper
11403 \begin_layout Plain Layout
11404 \begin_inset space ~
11405 \end_inset
11406
11407
11408 \end_layout
11409
11410 \end_deeper
11411 \end_inset
11412
11413
11414 \end_layout
11415
11416 \begin_layout Standard
11417 There are also a few commands provided by 
11418 \family sans
11419 Foil\SpecialChar TeX
11420
11421 \family default
11422  that aren't directly supported by \SpecialChar LyX
11423  but I'll tell you what they do and how
11424  to use them in section
11425 \begin_inset space ~
11426 \end_inset
11427
11428
11429 \begin_inset CommandInset ref
11430 LatexCommand ref
11431 reference "sec:unsuppfoils"
11432
11433 \end_inset
11434
11435 .
11436 \end_layout
11437
11438 \begin_layout Subsection
11439 Building a Set of Foils
11440 \end_layout
11441
11442 \begin_layout Standard
11443 This section will give a simple introduction to using the different environments
11444  to build a set of foils.
11445  If you want to see an example set of foils, take a look at the 
11446 \family typewriter
11447 Foils.lyx
11448 \family default
11449  file you find in \SpecialChar LyX
11450 's 
11451 \family typewriter
11452 examples
11453 \family default
11454  folder.
11455 \end_layout
11456
11457 \begin_layout Subsubsection
11458 Give It a Title Page
11459 \end_layout
11460
11461 \begin_layout Standard
11462 Unlike other classes that provide 
11463 \family sans
11464 Title
11465 \family default
11466
11467 \family sans
11468 Author
11469 \family default
11470
11471 \family sans
11472 Date
11473 \family default
11474  and 
11475 \family sans
11476 Abstract
11477 \family default
11478  environments, 
11479 \family sans
11480 foils
11481 \family default
11482  creates the title on a page of its own.
11483  If you leave out the 
11484 \family sans
11485 Date
11486 \family default
11487  environment \SpecialChar LaTeX
11488  will substitute the current date (every time you regenerate
11489  the output).
11490 \end_layout
11491
11492 \begin_layout Subsubsection
11493 Start a New Foil
11494 \end_layout
11495
11496 \begin_layout Standard
11497 As I mentioned earlier, there are four ways of starting a new foil.
11498  For portrait foils you should use 
11499 \family sans
11500 Foilhead
11501 \family default
11502  or 
11503 \family sans
11504 ShortFoilhead.
11505
11506 \family default
11507  The difference between these two environments is the amount of space between
11508  the title of the foil (the foilhead) and the body of the foil.
11509 \end_layout
11510
11511 \begin_layout Standard
11512 Landscape foils are generated using the 
11513 \family sans
11514 Rotatefoilhead
11515 \family default
11516  and 
11517 \family sans
11518 ShortRotatefoilhead
11519 \family default
11520  environments.
11521  Again the only difference is the spacing between foilhead and body.
11522  Both of the short versions have 0.5
11523 \begin_inset space ~
11524 \end_inset
11525
11526 inches less separation between the foilhead and the body.
11527  
11528 \end_layout
11529
11530 \begin_layout Standard
11531 One problem with the support for landscape foils is the requirement that
11532  you have to use the 
11533 \family typewriter
11534 dvips
11535 \family default
11536  driver to generate the PostScript output otherwise the foils won't be rotated.
11537  It is possible to get landscape foils even if you haven't got the 
11538 \family typewriter
11539 dvips
11540 \family default
11541  driver provided you can feed your foils sideways through your printer ;-)
11542 \end_layout
11543
11544 \begin_layout Subsubsection
11545 Theorems, Lemmas, Proofs and more
11546 \end_layout
11547
11548 \begin_layout Standard
11549 Due to a small bug in \SpecialChar LyX
11550  you can't have two of the same type of these environments
11551  directly following each other.
11552  They must be separated by something.
11553  If you try, you will just be extending the previous environment as if you
11554  had merged the two environments together.
11555  So, how do you get around this problem? The simplest option is to insert
11556  some text between the two environments or add a 
11557 \family sans
11558 \SpecialChar LaTeX
11559
11560 \family default
11561  environment between the two with just a 
11562 \begin_inset Quotes eld
11563 \end_inset
11564
11565
11566 \family typewriter
11567 %
11568 \family default
11569
11570 \begin_inset Quotes erd
11571 \end_inset
11572
11573  in it.
11574  This will force \SpecialChar LyX
11575  to produce two separate environments and hence the correct
11576  \SpecialChar LaTeX
11577  output.
11578  An example is provided in the example file included with the \SpecialChar LyX
11579  distribution.
11580  Remember, this problem only occurs if you are trying to place two of the
11581  same type of theorem-like environments one directly after the other.
11582 \end_layout
11583
11584 \begin_layout Subsubsection
11585 Lists
11586 \end_layout
11587
11588 \begin_layout Standard
11589 You get all the commonly supported list styles found in other classes as
11590  well as two new ones.
11591  I'll only describe the new ones here.
11592  If you want to find out more about the other list environments check out
11593  the 
11594 \emph on
11595 User's Guide.
11596
11597 \emph default
11598  If you intend to use itemized lists you might also want to read about the
11599  
11600 \family sans
11601 Itemize
11602 \begin_inset space ~
11603 \end_inset
11604
11605 Bullet
11606 \begin_inset space ~
11607 \end_inset
11608
11609 Selection
11610 \family default
11611  dialog described above in section
11612 \begin_inset space ~
11613 \end_inset
11614
11615
11616 \begin_inset CommandInset ref
11617 LatexCommand ref
11618 reference "sec:bullet"
11619
11620 \end_inset
11621
11622 .
11623 \end_layout
11624
11625 \begin_layout Standard
11626 The two new list styles, 
11627 \family sans
11628 TickList
11629 \family default
11630  and 
11631 \family sans
11632 CrossList
11633 \family default
11634 , are designed to make it easier for you to create lists of do's and don'ts
11635  or right and wrong by providing dedicated environments that use a tick
11636  or a cross as the label of the list.
11637  These lists are in fact dedicated variants of the 
11638 \family sans
11639 Itemize
11640 \family default
11641  environment.
11642  They do however require that you have the 
11643 \family typewriter
11644 psnfss
11645 \family default
11646  packages installed.
11647 \end_layout
11648
11649 \begin_layout Subsubsection
11650 Figures and Tables
11651 \end_layout
11652
11653 \begin_layout Standard
11654
11655 \family sans
11656 Foil\SpecialChar TeX
11657
11658 \family default
11659  redefines the floating tables and figures so that they appear exactly where
11660  they are in the text rather than pushing them to the top of the page or
11661  to some user specified location.
11662  In fact if you change the float placement settings they are simply ignored.
11663 \end_layout
11664
11665 \begin_layout Subsubsection
11666 Page Headers and Footers
11667 \begin_inset CommandInset label
11668 LatexCommand label
11669 name "sec:foilfoot"
11670
11671 \end_inset
11672
11673
11674 \end_layout
11675
11676 \begin_layout Standard
11677
11678 \family sans
11679 My
11680 \begin_inset space ~
11681 \end_inset
11682
11683 Logo
11684 \family default
11685  and 
11686 \family sans
11687 Restriction
11688 \family default
11689  are two commands used to control the left-footer text string.
11690  The first is meant to allow you to include a graphic logo on your foils
11691  and defaults to 
11692 \begin_inset Quotes eld
11693 \end_inset
11694
11695 -Typeset by 
11696 \family sans
11697 Foil\SpecialChar TeX
11698
11699 \family default
11700 -
11701 \begin_inset Quotes erd
11702 \end_inset
11703
11704 .
11705  While the second is meant to provide a classification for the audience,
11706  
11707 \emph on
11708 e.
11709 \begin_inset space \thinspace{}
11710 \end_inset
11711
11712 g.
11713 \emph default
11714
11715 \begin_inset space \space{}
11716 \end_inset
11717
11718 Confidential.
11719  It is empty by default.
11720 \end_layout
11721
11722 \begin_layout Standard
11723 The remaining page corners can be filled by 
11724 \family sans
11725 Right
11726 \begin_inset space ~
11727 \end_inset
11728
11729 Footer
11730 \family default
11731  (which defaults to page numbers), 
11732 \family sans
11733 Right
11734 \begin_inset space ~
11735 \end_inset
11736
11737 Header
11738 \family default
11739  (top right) and 
11740 \family sans
11741 Left
11742 \begin_inset space ~
11743 \end_inset
11744
11745 Header
11746 \family default
11747  (top left).
11748 \end_layout
11749
11750 \begin_layout Subsection
11751 Unsupported 
11752 \family sans
11753 Foil\SpecialChar TeX
11754
11755 \family default
11756  Goodies
11757 \begin_inset CommandInset label
11758 LatexCommand label
11759 name "sec:unsuppfoils"
11760
11761 \end_inset
11762
11763
11764 \end_layout
11765
11766 \begin_layout Standard
11767 All the commands mentioned below need to be set in a 
11768 \family sans
11769 \SpecialChar LaTeX
11770
11771 \family default
11772  environment or as 
11773 \family sans
11774 \SpecialChar TeX
11775
11776 \family default
11777  within another environment.
11778 \end_layout
11779
11780 \begin_layout Subsubsection
11781 Lengths
11782 \end_layout
11783
11784 \begin_layout Standard
11785 All lengths are adjusted using the 
11786 \family typewriter
11787
11788 \backslash
11789 setlength{
11790 \family default
11791 \emph on
11792 lengthname
11793 \family typewriter
11794 \emph default
11795 }{
11796 \family default
11797 \emph on
11798 newlength
11799 \family typewriter
11800 \emph default
11801 }
11802 \family default
11803  command.
11804  Where 
11805 \emph on
11806 lengthname
11807 \emph default
11808  should be replaced by the name given to the length you want to change and
11809  
11810 \emph on
11811 newlength
11812 \emph default
11813  is the length value.
11814  All lengths should be specified in units of length such as inches (
11815 \family typewriter
11816 in
11817 \family default
11818 ), millimeters (
11819 \family typewriter
11820 mm
11821 \family default
11822 ) or points (
11823 \family typewriter
11824 pt
11825 \family default
11826 ) or relative to some document or font-based length such as 
11827 \family typewriter
11828
11829 \backslash
11830 textwidth
11831 \family default
11832 .
11833  
11834 \end_layout
11835
11836 \begin_layout Standard
11837 It's possible to change the spacing between a foilhead and the body of the
11838  foil by adjusting the length specified by 
11839 \family typewriter
11840
11841 \backslash
11842 foilheadskip
11843 \family default
11844 .
11845  For example, to make 
11846 \emph on
11847 all
11848 \emph default
11849  foilheads 0.5
11850 \begin_inset space \space{}
11851 \end_inset
11852
11853 in closer to their bodies put the following in the preamble: 
11854 \family typewriter
11855
11856 \backslash
11857 setlength{
11858 \backslash
11859 foilheadskip}{-0.5in}
11860 \end_layout
11861
11862 \begin_layout Standard
11863 The spacings around floats can be adjusted by setting these lengths:
11864 \end_layout
11865
11866 \begin_layout Labeling
11867 \labelwidthstring MMMMMMMMMMM
11868
11869 \family typewriter
11870
11871 \backslash
11872 abovefloatskip
11873 \family default
11874  Separation between the text and the top of the float
11875 \end_layout
11876
11877 \begin_layout Labeling
11878 \labelwidthstring MMMMMMMMMMM
11879
11880 \family typewriter
11881
11882 \backslash
11883 abovecaptionskip
11884 \family default
11885  Separation between the float and the caption
11886 \end_layout
11887
11888 \begin_layout Labeling
11889 \labelwidthstring MMMMMMMMMMM
11890
11891 \family typewriter
11892
11893 \backslash
11894 belowcaptionskip
11895 \family default
11896  Separation between the caption and the following text
11897 \end_layout
11898
11899 \begin_layout Labeling
11900 \labelwidthstring MMMMMMMMMMM
11901
11902 \family typewriter
11903
11904 \backslash
11905 captionwidth
11906 \family default
11907  You can make the captions narrower than the surrounding text by adjusting
11908  this length.
11909  Best done relative to 
11910 \family typewriter
11911
11912 \backslash
11913 textwidth
11914 \family default
11915 .
11916 \end_layout
11917
11918 \begin_layout Standard
11919 There are also several title page related lengths that you may find useful
11920  if you have a long title or several authors:
11921 \end_layout
11922
11923 \begin_layout Labeling
11924 \labelwidthstring MMMMMMMMMMM
11925
11926 \family typewriter
11927
11928 \backslash
11929 abovetitleskip
11930 \family default
11931  Separation from headers to 
11932 \family sans
11933 Title
11934 \end_layout
11935
11936 \begin_layout Labeling
11937 \labelwidthstring MMMMMMMMMMM
11938
11939 \family typewriter
11940
11941 \backslash
11942 titleauthorskip
11943 \family default
11944  between 
11945 \family sans
11946 Title
11947 \family default
11948  and 
11949 \family sans
11950 Author
11951 \family default
11952  environments
11953 \end_layout
11954
11955 \begin_layout Labeling
11956 \labelwidthstring MMMMMMMMMMM
11957
11958 \family typewriter
11959
11960 \backslash
11961 authorauthorskip
11962 \family default
11963  between multiple 
11964 \family sans
11965 Author
11966 \family default
11967  lines
11968 \end_layout
11969
11970 \begin_layout Labeling
11971 \labelwidthstring MMMMMMMMMMM
11972
11973 \family typewriter
11974
11975 \backslash
11976 authordateskip
11977 \family default
11978  between the 
11979 \family sans
11980 Author
11981 \family default
11982  and the 
11983 \family sans
11984 Date
11985 \end_layout
11986
11987 \begin_layout Labeling
11988 \labelwidthstring MMMMMMMMMMM
11989
11990 \family typewriter
11991
11992 \backslash
11993 dateabstractskip
11994 \family default
11995  between the 
11996 \family sans
11997 Date
11998 \family default
11999  and the 
12000 \family sans
12001 Abstract
12002 \end_layout
12003
12004 \begin_layout Standard
12005 The last length related command affects all the list environments.
12006  If you place 
12007 \family typewriter
12008
12009 \backslash
12010 zerolistvertdimens
12011 \family default
12012  
12013 \emph on
12014 inside
12015 \emph default
12016  a list environment then all the vertical spacing between the list items
12017  is removed.
12018  Note that this is a command not a length so it doesn't require 
12019 \family typewriter
12020
12021 \backslash
12022 setlength
12023 \family default
12024  like the stuff mentioned above.
12025 \end_layout
12026
12027 \begin_layout Subsubsection
12028 Headers and Footers
12029 \end_layout
12030
12031 \begin_layout Standard
12032 The 
12033 \family typewriter
12034
12035 \backslash
12036 LogoOn
12037 \family default
12038  and 
12039 \family typewriter
12040
12041 \backslash
12042 LogoOff
12043 \family default
12044  commands control whether the logo in the 
12045 \family sans
12046 MyLogo
12047 \family default
12048  definition appear on a given page.
12049  If you put 
12050 \family typewriter
12051
12052 \backslash
12053 LogoOff
12054 \family default
12055  in the preamble then none of the foils will have the logo on them.
12056  If you don't want the logo on a particular page place the 
12057 \family typewriter
12058
12059 \backslash
12060 LogoOff
12061 \family default
12062  directly after the foilhead of that page and the 
12063 \family typewriter
12064
12065 \backslash
12066 LogoOn
12067 \family default
12068  directly after the next foilhead.
12069 \end_layout
12070
12071 \begin_layout Standard
12072 If you decide to use the 
12073 \family sans
12074 fancy
12075 \family default
12076  page style setting in the 
12077 \family sans
12078 Document
12079 \begin_inset space ~
12080 \end_inset
12081
12082 Layout
12083 \family default
12084  dialog you should probably add 
12085 \family typewriter
12086
12087 \backslash
12088 let
12089 \backslash
12090 headwidth
12091 \backslash
12092 textwidth
12093 \family default
12094  to your preamble so headers and footers on landscape pages are correctly
12095  placed when rotated.
12096  This is due to some clashes between the page layouts provided by the 
12097 \family sans
12098 fancyheadings
12099 \family default
12100  package and the 
12101 \family sans
12102 foils
12103 \family default
12104  class.
12105 \end_layout
12106
12107 \begin_layout Section
12108 Hollywood (Hollywood spec scripts)
12109 \end_layout
12110
12111 \begin_layout Standard
12112 by 
12113 \shape smallcaps
12114 Garst Reese
12115 \end_layout
12116
12117 \begin_layout Subsection
12118 Introduction
12119 \end_layout
12120
12121 \begin_layout Standard
12122 Getting the format of a Hollywood script right is a 
12123 \begin_inset Quotes eld
12124 \end_inset
12125
12126 rite of passage.
12127 \begin_inset Quotes erd
12128 \end_inset
12129
12130  It is designed to make the readers focus on content and to be easy and
12131  familiar for the actors to read.
12132  Each page of a script should be one minute of film.
12133  Nothing goes in a script that you cannot see or hear on screen.
12134  The courier 12 pt font should be used throughout.
12135  No italics.
12136 \end_layout
12137
12138 \begin_layout Subsection
12139 Special problems
12140 \end_layout
12141
12142 \begin_layout Standard
12143 Speakers' lines should NEVER break in mid-sentence.
12144  If a speaker's lines continue over a page break, repeat the 
12145 \family sans
12146 Speaker
12147 \family default
12148  title followed by (Cont'd).
12149 \end_layout
12150
12151 \begin_layout Subsection
12152 Special features
12153 \end_layout
12154
12155 \begin_layout Standard
12156 Insert the 
12157 \family sans
12158 Speaker
12159 \family default
12160  names as labels then cross-reference the label to insert the name.
12161  The cross-reference dialog will show the current cast of characters.
12162  You can use this to insert the speaker name in narratives also.
12163 \end_layout
12164
12165 \begin_layout Subsection
12166 Paper size and Margins
12167 \end_layout
12168
12169 \begin_layout Standard
12170 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
12171 \end_layout
12172
12173 \begin_layout Subsection
12174 Environments
12175 \end_layout
12176
12177 \begin_layout Standard
12178 The following environments are available.
12179  You can use hollywood.bind to get the bind keys shown at the right.
12180 \end_layout
12181
12182 \begin_layout Itemize
12183
12184 \family sans
12185 Standard
12186 \begin_inset Newline newline
12187 \end_inset
12188
12189
12190 \family default
12191 Used where nothing else works.
12192  Try to avoid it.
12193 \end_layout
12194
12195 \begin_layout Itemize
12196
12197 \family sans
12198 FADE_IN
12199 \family default
12200 :
12201 \begin_inset space \hfill{}
12202 \end_inset
12203
12204
12205 \family sans
12206 M-z S-I
12207 \family default
12208
12209 \begin_inset Newline newline
12210 \end_inset
12211
12212 Usually followed by something like 
12213 \begin_inset Quotes eld
12214 \end_inset
12215
12216 on Sally waking up.
12217 \begin_inset Quotes erd
12218 \end_inset
12219
12220
12221 \end_layout
12222
12223 \begin_layout Itemize
12224
12225 \family sans
12226 INT:
12227 \begin_inset space \hfill{}
12228 \end_inset
12229
12230 M-z i
12231 \begin_inset Newline newline
12232 \end_inset
12233
12234
12235 \family default
12236 Introduces a new INTERIOR camera set-up.
12237  Always followed by DAY or NIGHT, or something similar to define the lighting
12238  required.
12239  Everthing on this line in CAPS.
12240 \end_layout
12241
12242 \begin_layout Itemize
12243
12244 \family sans
12245 EXT:
12246 \begin_inset space \hfill{}
12247 \end_inset
12248
12249 M-z e
12250 \begin_inset Newline newline
12251 \end_inset
12252
12253
12254 \family default
12255 Introduces a new EXTERIOR camera set-up.
12256  Everthing on this line in CAPS.
12257 \end_layout
12258
12259 \begin_layout Itemize
12260
12261 \family sans
12262 Speaker
12263 \begin_inset space \hfill{}
12264 \end_inset
12265
12266 M-z s
12267 \begin_inset Newline newline
12268 \end_inset
12269
12270
12271 \family default
12272 The character speaking.
12273 \end_layout
12274
12275 \begin_layout Itemize
12276
12277 \family sans
12278 Parenthetical
12279 \begin_inset space \hfill{}
12280 \end_inset
12281
12282 M-z p
12283 \begin_inset Newline newline
12284 \end_inset
12285
12286
12287 \family default
12288 Instructions to the speaker.
12289  The () are automatically inserted, but only the ( will show in \SpecialChar LyX
12290 .
12291  Both will be printed.
12292 \end_layout
12293
12294 \begin_layout Itemize
12295
12296 \family sans
12297 Dialogue
12298 \begin_inset space \hfill{}
12299 \end_inset
12300
12301 M-z d
12302 \begin_inset Newline newline
12303 \end_inset
12304
12305
12306 \family default
12307 What the 
12308 \family sans
12309 Speaker
12310 \family default
12311  says.
12312 \end_layout
12313
12314 \begin_layout Itemize
12315
12316 \family sans
12317 Transition
12318 \begin_inset space \hfill{}
12319 \end_inset
12320
12321 M-z t
12322 \begin_inset Newline newline
12323 \end_inset
12324
12325
12326 \family default
12327 Camera movement instruction.
12328  e.
12329 \begin_inset space \thinspace{}
12330 \end_inset
12331
12332 g.
12333 \begin_inset space \space{}
12334 \end_inset
12335
12336 CUT TO:
12337 \end_layout
12338
12339 \begin_layout Itemize
12340
12341 \family sans
12342 FADE OUT:
12343 \begin_inset space \hfill{}
12344 \end_inset
12345
12346 M-z S-I
12347 \end_layout
12348
12349 \begin_layout Itemize
12350
12351 \family sans
12352 Author
12353 \begin_inset space \hfill{}
12354 \end_inset
12355
12356 M-z S-A
12357 \end_layout
12358
12359 \begin_layout Itemize
12360
12361 \family sans
12362 Title
12363 \begin_inset space \hfill{}
12364 \end_inset
12365
12366 M-z S-T
12367 \end_layout
12368
12369 \begin_layout Itemize
12370
12371 \family sans
12372 Right_Address
12373 \begin_inset space \hfill{}
12374 \end_inset
12375
12376 M-z r
12377 \end_layout
12378
12379 \begin_layout Subsection
12380 Script jargon
12381 \end_layout
12382
12383 \begin_layout Itemize
12384 (O.S) — off screen
12385 \end_layout
12386
12387 \begin_layout Itemize
12388 (V.0) — voice over
12389 \end_layout
12390
12391 \begin_layout Itemize
12392 b.
12393 \begin_inset space \thinspace{}
12394 \end_inset
12395
12396 g.
12397  — background
12398 \end_layout
12399
12400 \begin_layout Itemize
12401 C.U.
12402  — close-up
12403 \end_layout
12404
12405 \begin_layout Itemize
12406 PAN — camera movement
12407 \end_layout
12408
12409 \begin_layout Itemize
12410 INSERT — cut to close-up of
12411 \end_layout
12412
12413 \begin_layout Section
12414 ijmpc and ijmpd
12415 \end_layout
12416
12417 \begin_layout Standard
12418 by 
12419 \noun on
12420 Panayotis Papasotiriou
12421 \end_layout
12422
12423 \begin_layout Subsection
12424 Overview
12425 \end_layout
12426
12427 \begin_layout Standard
12428 The ijmpc package is a set of macros that facilitates electronic manuscript
12429  submission to the 
12430 \emph on
12431 International Journal of Modern Physics C
12432 \emph default
12433 .
12434  Similarly, the ijmpd package is for creating manuscripts to be submitted
12435  to the 
12436 \emph on
12437 International Journal of Modern Physics D
12438 \emph default
12439 .
12440  Both journals are published by World Scientific.
12441  The corresponding document classes are named 
12442 \family typewriter
12443 ws-ijmpc.cls
12444 \family default
12445  and 
12446 \family typewriter
12447 ws-ijmpd.cls
12448 \family default
12449 , respectively.
12450  These files, together with instructions for the authors, can be downloaded
12451  from the sites 
12452 \begin_inset Flex URL
12453 status collapsed
12454
12455 \begin_layout Plain Layout
12456
12457 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
12458 \end_layout
12459
12460 \end_inset
12461
12462  and 
12463 \begin_inset Flex URL
12464 status collapsed
12465
12466 \begin_layout Plain Layout
12467
12468 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
12469 \end_layout
12470
12471 \end_inset
12472
12473 .
12474  Both packages are modified versions of the standard 
12475 \begin_inset Quotes eld
12476 \end_inset
12477
12478 article
12479 \begin_inset Quotes erd
12480 \end_inset
12481
12482  package, and they are almost (but not exactly) identical.
12483  Most of their features are supported by \SpecialChar LyX
12484 .
12485  I have used \SpecialChar LyX
12486  successfully to write articles submitted to both journals
12487  without any problem.
12488 \end_layout
12489
12490 \begin_layout Subsection
12491 Writing a paper
12492 \end_layout
12493
12494 \begin_layout Standard
12495 As usual, the easiest way to write a paper is to start with a template.
12496  Click on 
12497 \family sans
12498 File\SpecialChar menuseparator
12499 New from
12500 \family default
12501  
12502 \family sans
12503 \bar under
12504 T
12505 \bar default
12506 emplate
12507 \family default
12508 , then choose the 
12509 \family typewriter
12510 ijmpc.lyx
12511 \family default
12512  or 
12513 \family typewriter
12514 ijmpd.lyx
12515 \family default
12516  template.
12517  This will give an (almost) empty document that includes the most common
12518  fields found in a manuscript.
12519  Simply overwrite the existing text (including the brackets, 
12520 \family typewriter
12521 <>
12522 \family default
12523 ) with your text.
12524  You should keep in mind the following remarks.
12525 \end_layout
12526
12527 \begin_layout Enumerate
12528 \SpecialChar LyX
12529  won't let you change the font size and the page style of the document,
12530  because such modifications are not allowed by both packages.
12531 \end_layout
12532
12533 \begin_layout Enumerate
12534 The language of the document should not be changed.
12535  Before previewing your paper, be sure that the babel package is not used.
12536  To do this, click on 
12537 \family sans
12538 Tools\SpecialChar menuseparator
12539 Preferences
12540 \family default
12541 , select the 
12542 \family sans
12543 Lang Opts
12544 \family default
12545  tab, deselect the 
12546 \family sans
12547 Use babel
12548 \family default
12549  checkbox in the language settings, and click on 
12550 \family sans
12551 Apply
12552 \family default
12553  (or 
12554 \family sans
12555 Save
12556 \family default
12557 , if you wish to make this change permanent).
12558 \end_layout
12559
12560 \begin_layout Enumerate
12561 The 
12562 \begin_inset Quotes eld
12563 \end_inset
12564
12565 Keywords
12566 \begin_inset Quotes erd
12567 \end_inset
12568
12569  style must be used to define keywords.
12570 \end_layout
12571
12572 \begin_layout Enumerate
12573 The ijmpc package provides a style named 
12574 \begin_inset Quotes eld
12575 \end_inset
12576
12577 Classification Codes
12578 \begin_inset Quotes erd
12579 \end_inset
12580
12581 , which can be used to define classification codes, such as PACS numbers.
12582  Note that this facility is not supported by the ijmpd package.
12583 \end_layout
12584
12585 \begin_layout Enumerate
12586 Several new environments are available: 
12587 \begin_inset Quotes eld
12588 \end_inset
12589
12590 Definition
12591 \begin_inset Quotes erd
12592 \end_inset
12593
12594
12595 \begin_inset Quotes eld
12596 \end_inset
12597
12598 Step
12599 \begin_inset Quotes erd
12600 \end_inset
12601
12602
12603 \begin_inset Quotes eld
12604 \end_inset
12605
12606 Example
12607 \begin_inset Quotes erd
12608 \end_inset
12609
12610
12611 \begin_inset Quotes eld
12612 \end_inset
12613
12614 Remark
12615 \begin_inset Quotes erd
12616 \end_inset
12617
12618
12619 \begin_inset Quotes eld
12620 \end_inset
12621
12622 Notation
12623 \begin_inset Quotes erd
12624 \end_inset
12625
12626
12627 \begin_inset Quotes eld
12628 \end_inset
12629
12630 Theorem
12631 \begin_inset Quotes erd
12632 \end_inset
12633
12634
12635 \begin_inset Quotes eld
12636 \end_inset
12637
12638 Proof
12639 \begin_inset Quotes erd
12640 \end_inset
12641
12642
12643 \begin_inset Quotes eld
12644 \end_inset
12645
12646 Corollary
12647 \begin_inset Quotes erd
12648 \end_inset
12649
12650
12651 \begin_inset Quotes eld
12652 \end_inset
12653
12654 Lemma
12655 \begin_inset Quotes erd
12656 \end_inset
12657
12658
12659 \begin_inset Quotes eld
12660 \end_inset
12661
12662 Proposition
12663 \begin_inset Quotes erd
12664 \end_inset
12665
12666
12667 \begin_inset Quotes eld
12668 \end_inset
12669
12670 Prop
12671 \begin_inset Quotes erd
12672 \end_inset
12673
12674
12675 \begin_inset Quotes eld
12676 \end_inset
12677
12678 Question
12679 \begin_inset Quotes erd
12680 \end_inset
12681
12682
12683 \begin_inset Quotes eld
12684 \end_inset
12685
12686 Claim
12687 \begin_inset Quotes erd
12688 \end_inset
12689
12690 , and 
12691 \begin_inset Quotes eld
12692 \end_inset
12693
12694 Conjecture
12695 \begin_inset Quotes erd
12696 \end_inset
12697
12698 .
12699  Their use is more or less obvious.
12700  \SpecialChar LyX
12701  supports all these environments; it will use the proper label, text style,
12702  and numbering scheme for each of them.
12703 \end_layout
12704
12705 \begin_layout Enumerate
12706 Both packages use basic citations; the natbib package should not be used.
12707  In \SpecialChar LyX
12708 , citation references are shown as usual; in the output, citations are
12709  shown as superscripts.
12710  If you want to use a citation as normal text, you should use the 
12711 \family typewriter
12712 refcite
12713 \family default
12714  command, e.
12715 \begin_inset space \thinspace{}
12716 \end_inset
12717
12718 g.
12719 \begin_inset space \space{}
12720 \end_inset
12721
12722
12723 \begin_inset Quotes eld
12724 \end_inset
12725
12726 See Ref.
12727 \begin_inset space \space{}
12728 \end_inset
12729
12730
12731 \family typewriter
12732
12733 \backslash
12734 refcite{key}
12735 \family default
12736
12737 \begin_inset Quotes erd
12738 \end_inset
12739
12740 .
12741 \end_layout
12742
12743 \begin_layout Enumerate
12744 There is no 
12745 \begin_inset Quotes eld
12746 \end_inset
12747
12748 Acknowledgments
12749 \begin_inset Quotes erd
12750 \end_inset
12751
12752  section in both packages.
12753  To put acknowledgments, just use the 
12754 \begin_inset Quotes eld
12755 \end_inset
12756
12757 Section*
12758 \begin_inset Quotes erd
12759 \end_inset
12760
12761  environment.
12762 \end_layout
12763
12764 \begin_layout Enumerate
12765 Appendices may be added to the paper, 
12766 \emph on
12767 after
12768 \emph default
12769  the Acknowledgments and 
12770 \shape italic
12771 before
12772 \shape default
12773  the References.
12774  \SpecialChar LyX
12775  provides a special environment, called 
12776 \begin_inset Quotes eld
12777 \end_inset
12778
12779 Appendices Section
12780 \begin_inset Quotes erd
12781 \end_inset
12782
12783  which marks the beginning of the appendices.
12784  This environment should be left blank; it just sends a \SpecialChar LaTeX
12785  command, but nothing
12786  is really printed.
12787  In \SpecialChar LyX
12788 , the word 
12789 \begin_inset Quotes eld
12790 \end_inset
12791
12792 Appendix
12793 \begin_inset Quotes erd
12794 \end_inset
12795
12796  is printed with blue letters, as a signal that all sections after that
12797  point are appendices.
12798  To write an appendix, use the 
12799 \begin_inset Quotes eld
12800 \end_inset
12801
12802 Appendix
12803 \begin_inset Quotes erd
12804 \end_inset
12805
12806  environment.
12807  \SpecialChar LyX
12808  will number each appendix with capital letters, as required by both journals.
12809  Note that 
12810 \begin_inset Quotes eld
12811 \end_inset
12812
12813 Appendices Section
12814 \begin_inset Quotes erd
12815 \end_inset
12816
12817  
12818 \emph on
12819 must
12820 \emph default
12821  be present before the first appendix; if not, all appendices will be numbered
12822  as normal sections in the output.
12823 \end_layout
12824
12825 \begin_layout Enumerate
12826 The ijmpc and the ijmpd packages use the 
12827 \family typewriter
12828 tbl
12829 \family default
12830  command to implement table captions.
12831  As a result, a table created by \SpecialChar LyX
12832  is printed correctly, but its caption
12833  is ignored.
12834  However, you can use some \SpecialChar TeX
12835  code to overcome this problem, so that captions
12836  are printed as expected.
12837  To do so, create a float table as usual, remove the caption, and replace
12838  it with the \SpecialChar TeX
12839  code 
12840 \family typewriter
12841
12842 \backslash
12843 tbl{
12844 \emph on
12845 your table caption
12846 \emph default
12847 }{
12848 \family default
12849  (sic); you must also the \SpecialChar TeX
12850  code 
12851 \family typewriter
12852 }
12853 \family default
12854  immediately after the tabular material.
12855  Study the example table included in the template files to see how this
12856  trick is implemented.
12857  Alternatively, If you need table captions, you should implement the whole
12858  table float in a 
12859 \family typewriter
12860 .tex
12861 \family default
12862  file, then include this file to the \SpecialChar LyX
12863  document (
12864 \family sans
12865 Insert\SpecialChar menuseparator
12866 File\SpecialChar menuseparator
12867 Child
12868 \begin_inset space ~
12869 \end_inset
12870
12871 Document
12872 \family default
12873 ).
12874  Details on how to create a table float can be found in the files 
12875 \family typewriter
12876 ws-ijmpc.tex
12877 \family default
12878  and 
12879 \family typewriter
12880 ws-ijmpd.tex
12881 \family default
12882 , included in the corresponding packages.
12883 \end_layout
12884
12885 \begin_layout Subsection
12886 Preparing a paper for submission
12887 \end_layout
12888
12889 \begin_layout Standard
12890 Before you submit your paper you must export the \SpecialChar LyX
12891  document as a \SpecialChar LaTeX
12892  file (
12893 \family sans
12894 File\SpecialChar menuseparator
12895 Export\SpecialChar menuseparator
12896 \SpecialChar LaTeX
12897
12898 \family default
12899 )
12900 \begin_inset Foot
12901 status open
12902
12903 \begin_layout Plain Layout
12904 Actually you have the choice between \SpecialChar LaTeX
12905  (plain) and pdflatex.
12906  If you intend to use pdflatex to prepare the paper, you should use the
12907  pdflatex option so that included graphics are converted to PDF format,
12908  ready for use by pdflatex.
12909 \end_layout
12910
12911 \end_inset
12912
12913 , then make the following changes to the resulting 
12914 \family typewriter
12915 .tex
12916 \family default
12917  file.
12918 \end_layout
12919
12920 \begin_layout Enumerate
12921 Remove the comment lines before the 
12922 \family typewriter
12923
12924 \backslash
12925 documentclass
12926 \family default
12927  command.
12928 \end_layout
12929
12930 \begin_layout Enumerate
12931 Remove everything between (and including) the 
12932 \family typewriter
12933
12934 \backslash
12935 makeatletter
12936 \family default
12937  and 
12938 \family typewriter
12939
12940 \backslash
12941 makeatother
12942 \family default
12943  commands, except for any commands you specifically put into the \SpecialChar LaTeX
12944  preamble.
12945 \end_layout
12946
12947 \begin_layout Standard
12948 The modified 
12949 \family typewriter
12950 .tex
12951 \family default
12952  file should be saved and processed through \SpecialChar LaTeX
12953  as many times as necessary.
12954  You may also want to check the resulting 
12955 \family typewriter
12956 .dvi
12957 \family default
12958  document.
12959 \end_layout
12960
12961 \begin_layout Subsection
12962 Use of \SpecialChar TeX
12963  code
12964 \end_layout
12965
12966 \begin_layout Standard
12967 The use of \SpecialChar TeX
12968  code is reduced to two commands, which must be placed at the
12969  top of the document.
12970  If you started writing your paper by using the 
12971 \family typewriter
12972 ijmpc.lyx
12973 \family default
12974  or the 
12975 \family typewriter
12976 ijmpd.lyx
12977 \family default
12978  template, the \SpecialChar TeX
12979  code needed is already in its place; you usually don't need
12980  to delete it.
12981  You may only modify the first \SpecialChar TeX
12982  code to specify the information printed
12983  to the top of odd and even pages (authors' names and short paper's title,
12984  respectively).
12985  This \SpecialChar TeX
12986  code must have the form 
12987 \family typewriter
12988
12989 \backslash
12990 markboth{Authors' Names}{Short Paper's Title}
12991 \family default
12992 .
12993 \end_layout
12994
12995 \begin_layout Section
12996 iopart
12997 \end_layout
12998
12999 \begin_layout Standard
13000 by 
13001 \noun on
13002 Uwe Stöhr
13003 \end_layout
13004
13005 \begin_layout Subsection
13006 Overview
13007 \end_layout
13008
13009 \begin_layout Standard
13010 The iopart package provides a document class to create electronic manuscript
13011  submission to the journals published by the Institute of Physics.
13012  Instructions for the authors how to create a paper using the iopart class
13013  can be downloaded together with the iopart package from the site 
13014 \begin_inset Flex URL
13015 status collapsed
13016
13017 \begin_layout Plain Layout
13018
13019 ftp://ftp.iop.org/pub/journals/latex2e
13020 \end_layout
13021
13022 \end_inset
13023
13024 .
13025 \end_layout
13026
13027 \begin_layout Subsection
13028 Writing a paper
13029 \end_layout
13030
13031 \begin_layout Standard
13032 The easiest way to write a paper is to start with the file 
13033 \emph on
13034 IOP-article.lyx
13035 \emph default
13036  that is available in \SpecialChar LyX
13037 's examples files folder.
13038  Open this file, save it under a new name, and start writing.
13039  The example file explains how to use the special text environments.
13040  Here are the most important advices:
13041 \end_layout
13042
13043 \begin_layout Itemize
13044 To be able to compile your document to a PDF, PS, or DVI, ensure that the
13045  two options 
13046 \family sans
13047 Use AMS math package
13048 \family default
13049  in the document settings under 
13050 \family sans
13051 Math Options
13052 \family default
13053  are not used!
13054 \end_layout
13055
13056 \begin_layout Itemize
13057
13058 \size normal
13059 The title environment defines the kind of your paper.
13060  So use one of the following environments for the title:
13061 \size default
13062
13063 \begin_inset Separator parbreak
13064 \end_inset
13065
13066
13067 \end_layout
13068
13069 \begin_deeper
13070 \begin_layout Itemize
13071
13072 \family sans
13073 \size normal
13074 Title
13075 \family default
13076  for a Paper
13077 \end_layout
13078
13079 \begin_layout Itemize
13080
13081 \family sans
13082 \size normal
13083 Review
13084 \family default
13085  for a Review
13086 \end_layout
13087
13088 \begin_layout Itemize
13089
13090 \family sans
13091 \size normal
13092 Topical
13093 \family default
13094  for a Topical review
13095 \end_layout
13096
13097 \begin_layout Itemize
13098
13099 \family sans
13100 \size normal
13101 Comment
13102 \family default
13103  for a Comment
13104 \end_layout
13105
13106 \begin_layout Itemize
13107
13108 \family sans
13109 \size normal
13110 Note
13111 \family default
13112  for a Note
13113 \end_layout
13114
13115 \begin_layout Itemize
13116
13117 \family sans
13118 \size normal
13119 Paper
13120 \family default
13121  for a Paper (same as Title)
13122 \end_layout
13123
13124 \begin_layout Itemize
13125
13126 \family sans
13127 \size normal
13128 Prelim
13129 \family default
13130  for a Preliminary communication
13131 \end_layout
13132
13133 \begin_layout Itemize
13134
13135 \family sans
13136 \size normal
13137 Rapid
13138 \family default
13139  for a Rapid communication
13140 \end_layout
13141
13142 \begin_layout Itemize
13143
13144 \family sans
13145 \size normal
13146 Letter
13147 \family default
13148  for a Letter to the editor
13149 \end_layout
13150
13151 \end_deeper
13152 \begin_layout Itemize
13153
13154 \size normal
13155 All title environments except of 
13156 \family sans
13157 Letter
13158 \family default
13159  can have an optional short title.
13160 \end_layout
13161
13162 \begin_layout Itemize
13163 There is a general title environment 
13164 \family sans
13165 Article
13166 \family default
13167  which is not directly supported by the \SpecialChar LyX
13168 .
13169  This can be used as \SpecialChar TeX
13170  code when your document doesn't fit into one of the
13171  other title types.
13172 \end_layout
13173
13174 \begin_layout Standard
13175 For more informations like hints for special table and formula formatting,
13176  look at the IOP author guidelines.
13177 \end_layout
13178
13179 \begin_layout Section
13180 Kluwer
13181 \end_layout
13182
13183 \begin_layout Standard
13184 by 
13185 \noun on
13186 Panayotis Papasotiriou
13187 \end_layout
13188
13189 \begin_layout Subsection
13190 Overview
13191 \end_layout
13192
13193 \begin_layout Standard
13194 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
13195  that facilitates electronic manuscript submission to the journals they
13196  publish.
13197  Most known of them (at least in my domain of interest) are 
13198 \emph on
13199 Astrophysics and Space Science
13200 \emph default
13201  and 
13202 \emph on
13203 Solar Physics
13204 \emph default
13205 , but there are many others (see a complete list at 
13206 \begin_inset Flex URL
13207 status open
13208
13209 \begin_layout Plain Layout
13210
13211 http://www.wkap.nl/jrnllist.htm/JRNLHOME
13212 \end_layout
13213
13214 \end_inset
13215
13216 ).
13217  The Kluwer package may be downloaded from the site 
13218 \begin_inset Flex URL
13219 status collapsed
13220
13221 \begin_layout Plain Layout
13222
13223 http://www.wkap.nl/kaphtml.htm/STYLEFILES
13224 \end_layout
13225
13226 \end_inset
13227
13228 .
13229  A complete user guide is contained in that package (but it can also be
13230  downloaded separately).
13231 \end_layout
13232
13233 \begin_layout Standard
13234 \SpecialChar LyX
13235  supports many features of the package but not everything.
13236  However, the \SpecialChar TeX
13237  code needed is reduced to some 
13238 \begin_inset Quotes eld
13239 \end_inset
13240
13241 peculiar
13242 \begin_inset Quotes erd
13243 \end_inset
13244
13245  commands of the package (see
13246 \begin_inset space ~
13247 \end_inset
13248
13249
13250 \begin_inset CommandInset ref
13251 LatexCommand ref
13252 reference "subsec:kluwer_peculiarities"
13253
13254 \end_inset
13255
13256 ).
13257  I have recently used \SpecialChar LyX
13258  to write an article submitted to the 
13259 \emph on
13260 Astrophysics and Space Science
13261 \emph default
13262  without any problem.
13263 \end_layout
13264
13265 \begin_layout Subsection
13266 Writing a paper
13267 \end_layout
13268
13269 \begin_layout Standard
13270 The easiest way to write a paper is to start with the Kluwer template file.
13271  Click on 
13272 \family sans
13273 File\SpecialChar menuseparator
13274 New from
13275 \family default
13276  
13277 \family sans
13278 Template
13279 \family default
13280 , then choose the 
13281 \family typewriter
13282 kluwer.lyx
13283 \family default
13284  template.
13285  This will give an (almost) empty document that includes the most common
13286  fields found in a manuscript and a short description of their use.
13287  As in most templates, simply overwrite the existing text (including the
13288  brackets, 
13289 \family typewriter
13290 <>
13291 \family default
13292 ) with the correct information.
13293 \end_layout
13294
13295 \begin_layout Subsection
13296 Preparing a paper for submission
13297 \end_layout
13298
13299 \begin_layout Standard
13300 As in the AAS\SpecialChar TeX
13301  package, before you submit your paper to a journal you must
13302  
13303 \begin_inset Quotes eld
13304 \end_inset
13305
13306 postprocess
13307 \begin_inset Quotes erd
13308 \end_inset
13309
13310  it as follows.
13311 \end_layout
13312
13313 \begin_layout Enumerate
13314 Export your paper as a \SpecialChar LaTeX
13315  file.
13316  To do this, click on 
13317 \family sans
13318 File\SpecialChar menuseparator
13319 Export\SpecialChar menuseparator
13320 \SpecialChar LaTeX
13321
13322 \family default
13323 .
13324  
13325 \end_layout
13326
13327 \begin_layout Enumerate
13328 Edit the resulting 
13329 \family typewriter
13330 .tex
13331 \family default
13332  file with a text editor and make the following changes
13333 \begin_inset Separator parbreak
13334 \end_inset
13335
13336
13337 \end_layout
13338
13339 \begin_deeper
13340 \begin_layout Enumerate
13341 remove the comment lines before the 
13342 \family typewriter
13343
13344 \backslash
13345 documentclass
13346 \family default
13347  command,
13348 \end_layout
13349
13350 \begin_layout Enumerate
13351 remove everything between (and including) the 
13352 \family typewriter
13353
13354 \backslash
13355 makeatletter
13356 \family default
13357  and 
13358 \family typewriter
13359
13360 \backslash
13361 makeatother
13362 \family default
13363  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13364  preamble.
13365 \end_layout
13366
13367 \begin_layout Standard
13368 Save the resulting 
13369 \family typewriter
13370 .tex
13371 \family default
13372  file.
13373 \end_layout
13374
13375 \end_deeper
13376 \begin_layout Enumerate
13377 Run the 
13378 \family typewriter
13379 .tex
13380 \family default
13381  file through \SpecialChar LaTeX
13382  as many times as necessary (usually up to three).
13383 \end_layout
13384
13385 \begin_layout Enumerate
13386 View the resulting 
13387 \family typewriter
13388 .dvi
13389 \family default
13390  document using, e.
13391 \begin_inset space \thinspace{}
13392 \end_inset
13393
13394 g.
13395 \begin_inset space \space{}
13396 \end_inset
13397
13398
13399 \family sans
13400 xdvi
13401 \family default
13402 , and check if everything is OK (it should, if you didn't make any mistake).
13403 \end_layout
13404
13405 \begin_layout Subsection
13406 \begin_inset Quotes eld
13407 \end_inset
13408
13409 Peculiarities
13410 \begin_inset Quotes erd
13411 \end_inset
13412
13413  of the Kluwer package
13414 \begin_inset CommandInset label
13415 LatexCommand label
13416 name "subsec:kluwer_peculiarities"
13417
13418 \end_inset
13419
13420
13421 \end_layout
13422
13423 \begin_layout Standard
13424 The Kluwer package has the following 
13425 \begin_inset Quotes eld
13426 \end_inset
13427
13428 peculiarities
13429 \begin_inset Quotes erd
13430 \end_inset
13431
13432 .
13433 \end_layout
13434
13435 \begin_layout Enumerate
13436 It is possible to write multiple articles in the same \SpecialChar LaTeX
13437  file
13438 \begin_inset Foot
13439 status collapsed
13440
13441 \begin_layout Plain Layout
13442 I can't imagine any good reason to do this.
13443 \end_layout
13444
13445 \end_inset
13446
13447 .
13448  Each article must be included in the environment 
13449 \begin_inset Quotes eld
13450 \end_inset
13451
13452 article
13453 \begin_inset Quotes erd
13454 \end_inset
13455
13456 .
13457  Unfortunately, this environment cannot be omitted, even if you write just
13458  one article.
13459  Therefore, each article starts with the command 
13460 \family typewriter
13461
13462 \backslash
13463 begin{article}
13464 \family default
13465  and, obviously, ends with the command 
13466 \family typewriter
13467
13468 \backslash
13469 end{article}
13470 \family default
13471 .
13472  Although this can be implemented in \SpecialChar LyX
13473 , I didn't included it, since it looks
13474  ugly and can confuse the novice user.
13475  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
13476  code (the
13477  well-known 
13478 \begin_inset Quotes eld
13479 \end_inset
13480
13481 \SpecialChar TeX
13482  code
13483 \begin_inset Quotes erd
13484 \end_inset
13485
13486 ).
13487 \end_layout
13488
13489 \begin_layout Enumerate
13490 Information given at the beginning of the article (i.
13491 \begin_inset space \thinspace{}
13492 \end_inset
13493
13494 e.
13495 \begin_inset space \space{}
13496 \end_inset
13497
13498 title, subtitle, author, institution, running title, running author, abstract
13499  and keywords) must be included in an environment called 
13500 \begin_inset Quotes eld
13501 \end_inset
13502
13503 opening
13504 \begin_inset Quotes erd
13505 \end_inset
13506
13507 .
13508  This is not implemented in \SpecialChar LyX
13509 , so you must enter title, subtitle etc.
13510 \begin_inset space ~
13511 \end_inset
13512
13513 between two \SpecialChar TeX
13514  code lines (
13515 \family typewriter
13516
13517 \backslash
13518 begin{opening}
13519 \family default
13520  and 
13521 \family typewriter
13522
13523 \backslash
13524 end{opening}
13525 \family default
13526 ).
13527 \end_layout
13528
13529 \begin_layout Enumerate
13530 According to the user manual, the label of each bibliography item must be
13531  written as 
13532 \family typewriter
13533
13534 \backslash
13535 protect
13536 \backslash
13537 citeauthoryear{
13538 \family default
13539 \emph on
13540 author(s)
13541 \family typewriter
13542 \emph default
13543 }{
13544 \family default
13545 \emph on
13546 year
13547 \family typewriter
13548 \emph default
13549 }
13550 \family default
13551 .
13552 \end_layout
13553
13554 \begin_layout Standard
13555 The 
13556 \family typewriter
13557 kluwer.lyx
13558 \family default
13559  template takes care of all these 
13560 \begin_inset Quotes eld
13561 \end_inset
13562
13563 peculiarities
13564 \begin_inset Quotes erd
13565 \end_inset
13566
13567 .
13568  If you start a new paper using this template you don't need to do anything
13569  special.
13570  Just 
13571 \end_layout
13572
13573 \begin_layout Enumerate
13574 don't delete the \SpecialChar TeX
13575  code included in the template, and
13576 \end_layout
13577
13578 \begin_layout Enumerate
13579 copy the example bibliography item included in the template and modify it
13580  as necessary to enter new bibliography items.
13581 \end_layout
13582
13583 \begin_layout Section
13584 Koma-Script
13585 \end_layout
13586
13587 \begin_layout Standard
13588 by 
13589 \noun on
13590 Bernd Rellermeyer
13591 \end_layout
13592
13593 \begin_layout Subsection
13594 Overview
13595 \end_layout
13596
13597 \begin_layout Standard
13598 The \SpecialChar LyX
13599  document classes 
13600 \emph on
13601 article (koma-script)
13602 \emph default
13603
13604 \emph on
13605 report (koma-script)
13606 \emph default
13607
13608 \emph on
13609 book
13610 \emph default
13611  
13612 \emph on
13613 (koma-script)
13614 \emph default
13615 , and 
13616 \emph on
13617 letter
13618 \emph default
13619  
13620 \emph on
13621 (koma-script)
13622 \emph default
13623  correspond to the \SpecialChar LaTeX
13624  document classes 
13625 \family typewriter
13626 scrartcl.cls
13627 \family default
13628
13629 \family typewriter
13630 scrreprt.cls
13631 \family default
13632
13633 \family typewriter
13634 scrbook.cls
13635 \family default
13636 , and 
13637 \family typewriter
13638 scrlettr.cls
13639 \family default
13640 , resp.
13641 \begin_inset space ~
13642 \end_inset
13643
13644 of the Koma-Script family.
13645  They are replacements for the standard document classes 
13646 \family typewriter
13647 article.cls
13648 \family default
13649
13650 \family typewriter
13651 report.cls
13652 \family default
13653
13654 \family typewriter
13655 book.cls
13656 \family default
13657  and 
13658 \family typewriter
13659 letter.cls
13660 \family default
13661 , resp., and fit better to European typography conventions in a number of
13662  points.
13663 \end_layout
13664
13665 \begin_layout Itemize
13666 Standard character size is 11pt in 
13667 \emph on
13668 article (koma-script)
13669 \emph default
13670
13671 \emph on
13672 report (koma-script)
13673 \emph default
13674 , and 
13675 \emph on
13676 book (koma-script)
13677 \emph default
13678 , and 12pt in 
13679 \emph on
13680 letter (koma-script)
13681 \emph default
13682 .
13683 \end_layout
13684
13685 \begin_layout Itemize
13686 Headings, labels of the description environment, and a number of elements
13687  of the 
13688 \emph on
13689 letter (koma-script)
13690 \emph default
13691  document class are set in a bold sans serif font.
13692 \begin_inset Foot
13693 status collapsed
13694
13695 \begin_layout Plain Layout
13696 There is a big difference between the bold sans serif old cm fonts and new
13697  ec fonts, especially in the appearance of headings.
13698  In comparison, the ec bold sans serif fonts look a bit thin.
13699  Here the \SpecialChar LaTeX
13700  package 
13701 \family typewriter
13702 cmsd.sty by
13703 \family default
13704  
13705 \shape smallcaps
13706 Walter Schmidt
13707 \shape default
13708  helps to produce the 
13709 \begin_inset Quotes eld
13710 \end_inset
13711
13712 usual
13713 \begin_inset Quotes erd
13714 \end_inset
13715
13716  appearance when using the ec fonts.
13717 \end_layout
13718
13719 \end_inset
13720
13721  The numbering of chapter headings is made in the same way as the numbering
13722  of section headings, that is without the extra line 
13723 \begin_inset Quotes eld
13724 \end_inset
13725
13726 Chapter\SpecialChar ldots
13727
13728 \begin_inset Quotes erd
13729 \end_inset
13730
13731 .
13732  In addition, the appearance of the headings can be modified by using a
13733  number of options (in \SpecialChar LyX
13734  to be entered in the field 
13735 \family sans
13736 Extra
13737 \begin_inset space ~
13738 \end_inset
13739
13740 Options
13741 \family default
13742  of the dialog 
13743 \family sans
13744 Layout\SpecialChar menuseparator
13745 Document
13746 \family default
13747 ).
13748  
13749 \end_layout
13750
13751 \begin_layout Itemize
13752 The main means in the Koma-Script document classes to design the type area
13753  are the options 
13754 \family sans
13755 BCOR
13756 \family default
13757  and 
13758 \family sans
13759 DIV
13760 \family default
13761  (in \SpecialChar LyX
13762  to be entered in the extra class options field in the dialog 
13763 \family sans
13764 Document\SpecialChar menuseparator
13765 Settings
13766 \family default
13767 ).
13768  They make a clearer modification of page margins possible as do the options
13769  of the dialog 
13770 \family sans
13771 Document\SpecialChar menuseparator
13772 Settings
13773 \family default
13774 .
13775  
13776 \end_layout
13777
13778 \begin_layout Itemize
13779 The \SpecialChar LaTeX
13780  document classes of the Koma-Script family define a number of additional
13781  commands.
13782  Those part of it which makes sense in \SpecialChar LyX
13783  is implemented in corresponding
13784  paragraph types.
13785 \end_layout
13786
13787 \begin_layout Standard
13788 Detailed descriptions of the \SpecialChar LaTeX
13789  document classes of the Koma-Script family
13790  can be found in the Koma-Script documentation 
13791 \emph on
13792 scrguide
13793 \emph default
13794  (German) and 
13795 \emph on
13796 scrguien
13797 \emph default
13798  (English).
13799 \end_layout
13800
13801 \begin_layout Subsection
13802 article (koma-script), report (koma-script), and book (koma-script)
13803 \end_layout
13804
13805 \begin_layout Standard
13806 The document classes 
13807 \emph on
13808 article (koma-script)
13809 \emph default
13810
13811 \emph on
13812 report (koma-script)
13813 \emph default
13814 , and 
13815 \emph on
13816 book
13817 \emph default
13818  
13819 \emph on
13820 (koma-script)
13821 \emph default
13822  are implemented in the layout files 
13823 \family typewriter
13824 scrartcl.layout
13825 \family default
13826
13827 \family typewriter
13828 scrreprt.layout
13829 \family default
13830 , and 
13831 \family typewriter
13832 scrbook.layout
13833 \family default
13834 , resp.
13835  They contain all the paragraph types of the corresponding standard document
13836  classes 
13837 \emph on
13838 article
13839 \emph default
13840
13841 \emph on
13842 report
13843 \emph default
13844 , and 
13845 \emph on
13846 book
13847 \emph default
13848 , resp., partly modified, with the exception of the \SpecialChar LyX
13849  specific 
13850 \family sans
13851 List
13852 \family default
13853 -type, which is replaced by the new 
13854 \family sans
13855 Labeling
13856 \family default
13857 -type having the same functionality.
13858  Beside the 
13859 \family sans
13860 Labeling
13861 \family default
13862 -Type there is a number of new paragraph types added.
13863  They are 
13864 \emph on
13865 not
13866 \emph default
13867  part of 
13868 \emph on
13869 letter (koma-script)
13870 \emph default
13871 .
13872 \end_layout
13873
13874 \begin_layout Itemize
13875
13876 \family sans
13877 Addpart, Addchap
13878 \family default
13879
13880 \family sans
13881 Addsec
13882 \family default
13883 : are equivalents to 
13884 \family sans
13885 Part*, Chapter*
13886 \family default
13887  and 
13888 \family sans
13889 Section*
13890 \family default
13891 , resp., additionally inserting an entry in the table of contents.
13892  
13893 \family sans
13894 Addpart
13895 \family default
13896  and 
13897 \family sans
13898 Addchap
13899 \family default
13900  are not contained in 
13901 \emph on
13902 article (koma-script)
13903 \emph default
13904 .
13905 \end_layout
13906
13907 \begin_layout Itemize
13908
13909 \family sans
13910 Addchap*
13911 \family default
13912
13913 \family sans
13914 Addsec*
13915 \family default
13916 : behave exactly as 
13917 \family sans
13918 Addchap
13919 \family default
13920  and 
13921 \family sans
13922 Addsec
13923 \family default
13924 , resp., additionally clearing running heads.
13925  
13926 \family sans
13927 Addchap*
13928 \family default
13929  is not contained in 
13930 \emph on
13931 article (koma-script)
13932 \emph default
13933 .
13934 \begin_inset Foot
13935 status collapsed
13936
13937 \begin_layout Plain Layout
13938 There is also an 
13939 \family typewriter
13940
13941 \backslash
13942 addpart*
13943 \family default
13944  command in 
13945 \emph on
13946 book (koma-script)
13947 \emph default
13948  and in 
13949 \emph on
13950 report (koma-script)
13951 \emph default
13952 , but since this is identical to 
13953 \family sans
13954 Part*
13955 \family default
13956 , is has not been implemented in \SpecialChar LyX
13957 .
13958 \end_layout
13959
13960 \end_inset
13961
13962
13963 \end_layout
13964
13965 \begin_layout Itemize
13966
13967 \family sans
13968 Minisec
13969 \family default
13970 : generates a heading directly above the following paragraph in the standard
13971  character size without affecting the structure of the document.
13972 \end_layout
13973
13974 \begin_layout Itemize
13975
13976 \family sans
13977 Captionabove
13978 \family default
13979  and 
13980 \family sans
13981 Captionbelow
13982 \family default
13983  are special captions which respect the different space settings needed
13984  for captions placed above or below an element (if you follow strict typographic
13985  rules, you might want to place table captions always above the table).
13986  You can also use the class option 
13987 \family typewriter
13988 tablecaptionsabove
13989 \family default
13990 , which will switch 
13991 \family sans
13992 caption
13993 \family default
13994  to 
13995 \family sans
13996 captionabove
13997 \family default
13998  for tables and 
13999 \family sans
14000 captionbelow
14001 \family default
14002  for figures.
14003  You need at least Koma-Script version 2.8q to use this.
14004 \end_layout
14005
14006 \begin_layout Itemize
14007
14008 \family sans
14009 Dictum
14010 \family default
14011 : can be used to set a bonmot, e.
14012 \begin_inset space \thinspace{}
14013 \end_inset
14014
14015 g.
14016 \begin_inset space \space{}
14017 \end_inset
14018
14019 at the beginning of a chapter.
14020  If you use the optional argument (
14021 \family sans
14022 Insert\SpecialChar menuseparator
14023 Short
14024 \begin_inset space ~
14025 \end_inset
14026
14027 Title
14028 \family default
14029 ), you can insert the dictum's author there.
14030  Dictum and author are separated by a line.
14031  You need at least Koma-Script version 2.8q to use this.
14032  
14033 \family sans
14034 Dictum
14035 \family default
14036  is not contained in 
14037 \emph on
14038 article (koma-script)
14039 \emph default
14040 .
14041 \end_layout
14042
14043 \begin_layout Standard
14044 The following types, together with the standard types 
14045 \family sans
14046 Title
14047 \family default
14048
14049 \family sans
14050 Author
14051 \family default
14052 , and 
14053 \family sans
14054 Date
14055 \family default
14056 , form the title area of the document.
14057  They must be entered ahead of the first 
14058 \begin_inset Quotes eld
14059 \end_inset
14060
14061 ordinary
14062 \begin_inset Quotes erd
14063 \end_inset
14064
14065  paragraph.
14066 \begin_inset Foot
14067 status collapsed
14068
14069 \begin_layout Plain Layout
14070 The corresponding \SpecialChar LaTeX
14071  commands must appear before the 
14072 \family typewriter
14073
14074 \backslash
14075 maketitle
14076 \family default
14077  command.
14078 \end_layout
14079
14080 \end_inset
14081
14082  When such a type is used more than once, the latter usage overwrites the
14083  former one, that means, for every type only the latest usage is valid.
14084  The order of the different types however has, like 
14085 \family sans
14086 Title
14087 \family default
14088
14089 \family sans
14090 Author
14091 \family default
14092 , and 
14093 \family sans
14094 Date
14095 \family default
14096 , no effect on the appearance of the produced document.
14097 \end_layout
14098
14099 \begin_layout Itemize
14100
14101 \family sans
14102 Subject
14103 \family default
14104 : produces a centered paragraph above the ordinary title (
14105 \family sans
14106 Title
14107 \family default
14108
14109 \family sans
14110 Author
14111 \family default
14112
14113 \family sans
14114 Date
14115 \family default
14116 ) for the subject of the document.
14117 \end_layout
14118
14119 \begin_layout Itemize
14120
14121 \family sans
14122 Publishers
14123 \family default
14124 : produces a centered paragraph below the ordinary title (
14125 \family sans
14126 Title
14127 \family default
14128
14129 \family sans
14130 Author
14131 \family default
14132
14133 \family sans
14134 Date
14135 \family default
14136 ) for the publishers' name.
14137 \end_layout
14138
14139 \begin_layout Itemize
14140
14141 \family sans
14142 Dedication
14143 \family default
14144 : in 
14145 \emph on
14146 report (koma-script)
14147 \emph default
14148  and 
14149 \emph on
14150 book (koma-script)
14151 \emph default
14152  produces a centered paragraph on its own page behind the title page, or
14153  in 
14154 \emph on
14155 article (koma-script)
14156 \emph default
14157  produces a centered paragraph below the ordinary title (
14158 \family sans
14159 Title
14160 \family default
14161
14162 \family sans
14163 Author
14164 \family default
14165
14166 \family sans
14167 Date
14168 \family default
14169
14170 \family sans
14171 Publishers
14172 \family default
14173 ) for a dedication.
14174 \end_layout
14175
14176 \begin_layout Itemize
14177
14178 \family sans
14179 Titlehead
14180 \family default
14181 : produces a left aligned paragraph above the ordinary title (
14182 \family sans
14183 Title
14184 \family default
14185
14186 \family sans
14187 Author
14188 \family default
14189
14190 \family sans
14191 Date
14192 \family default
14193
14194 \family sans
14195 Subject
14196 \family default
14197 ) for a document`s head.
14198 \end_layout
14199
14200 \begin_layout Itemize
14201
14202 \family sans
14203 Uppertitleback
14204 \family default
14205 : produces in a double-sided print in 
14206 \emph on
14207 report (koma-script)
14208 \emph default
14209  and 
14210 \emph on
14211 book (koma-script)
14212 \emph default
14213  a left-aligned paragraph at the top of the title page`s back or has no
14214  effect in a single-sided print or in 
14215 \emph on
14216 article (koma-script)
14217 \emph default
14218 .
14219 \end_layout
14220
14221 \begin_layout Itemize
14222
14223 \family sans
14224 Lowertitleback
14225 \family default
14226 : produces in a double-sided print in 
14227 \emph on
14228 report (koma-script)
14229 \emph default
14230  and 
14231 \emph on
14232 book (koma-script)
14233 \emph default
14234  a left-aligned paragraph at the bottom of the title page`s back or has
14235  no effect in a single-sided print or in 
14236 \emph on
14237 article (koma-script)
14238 \emph default
14239 .
14240 \end_layout
14241
14242 \begin_layout Itemize
14243
14244 \family sans
14245 Extratitle
14246 \family default
14247 : produces a special 
14248 \begin_inset Quotes eld
14249 \end_inset
14250
14251 dirty
14252 \begin_inset Quotes erd
14253 \end_inset
14254
14255  page ahead of the actual document containing a paragraph without special
14256  formatting.
14257 \end_layout
14258
14259 \begin_layout Standard
14260 The layout files for the document classes 
14261 \emph on
14262 article (koma-script)
14263 \emph default
14264
14265 \emph on
14266 report (koma-script)
14267 \emph default
14268 , and 
14269 \emph on
14270 book (koma-script)
14271 \emph default
14272  do include the file 
14273 \family typewriter
14274 scrmacros.inc
14275 \family default
14276 .
14277  This is thought of as a place to define your own types.
14278  Copy scrmacros
14279 \family typewriter
14280 .inc
14281 \family default
14282  in your personal layout directory and edit the file!
14283 \end_layout
14284
14285 \begin_layout Subsection
14286 letter (koma-script)
14287 \end_layout
14288
14289 \begin_layout Standard
14290 \noindent
14291 The document class 
14292 \emph on
14293 letter (koma-script)
14294 \emph default
14295  is implemented in the layout file 
14296 \family typewriter
14297 scrlettr.layout
14298 \family default
14299 .
14300  It contains all the paragraph types of the corresponding standard document
14301  class 
14302 \emph on
14303 letter
14304 \emph default
14305 , partly modified, with the exception of the \SpecialChar LyX
14306  specific types 
14307 \family sans
14308 \SpecialChar LyX
14309 -Code
14310 \family default
14311  and 
14312 \family sans
14313 Comment
14314 \family default
14315  and the 
14316 \family sans
14317 List
14318 \family default
14319  type, which is replaced by the new 
14320 \family sans
14321 Labeling
14322 \family default
14323  type.
14324  In addition, it contains, in contrast to the standard document class, the
14325  standard types 
14326 \family sans
14327 \SpecialChar LaTeX
14328
14329 \family default
14330
14331 \family sans
14332 Quotation
14333 \family default
14334
14335 \family sans
14336 Quote
14337 \family default
14338 , and 
14339 \family sans
14340 Verse
14341 \family default
14342 .
14343  Furthermore, there are a number of new letter specific types.
14344 \end_layout
14345
14346 \begin_layout Standard
14347 The appearance of the letter produced by this document class can be controlled
14348  by a number of \SpecialChar LaTeX
14349  commands, which you can put in the \SpecialChar LaTeX
14350  preamble.
14351 \begin_inset Foot
14352 status collapsed
14353
14354 \begin_layout Plain Layout
14355 For example, the standard appearance of the letter`s heading, consisting
14356  of name and address, is quite self-willed.
14357  An 
14358 \begin_inset Quotes eld
14359 \end_inset
14360
14361 ordinary
14362 \begin_inset Quotes erd
14363 \end_inset
14364
14365  heading is produced by the following \SpecialChar LaTeX
14366  commands in the preamble:
14367 \end_layout
14368
14369 \begin_layout LyX-Code
14370
14371 \backslash
14372 firsthead{
14373 \backslash
14374 parbox[b]{
14375 \backslash
14376 textwidth}
14377 \end_layout
14378
14379 \begin_layout LyX-Code
14380   {
14381 \backslash
14382 ignorespaces 
14383 \backslash
14384 fromname
14385 \backslash
14386
14387 \backslash
14388  
14389 \backslash
14390 ignorespaces 
14391 \backslash
14392 fromaddress}} 
14393 \end_layout
14394
14395 \begin_layout LyX-Code
14396
14397 \backslash
14398 nexthead{
14399 \backslash
14400 parbox[b]{
14401 \backslash
14402 textwidth}
14403 \end_layout
14404
14405 \begin_layout LyX-Code
14406   {
14407 \backslash
14408 ignorespaces 
14409 \backslash
14410 fromname 
14411 \backslash
14412 hfill 
14413 \backslash
14414 ignorespaces 
14415 \backslash
14416 pagename
14417 \backslash
14418  
14419 \backslash
14420 thepage}}
14421 \end_layout
14422
14423 \end_inset
14424
14425  A detailed German description of such \SpecialChar LaTeX
14426  commands can be found in the Koma-Script
14427  documentation 
14428 \emph on
14429 scrguide
14430 \emph default
14431 .
14432  With it, the letter's author can produce his personal letter layout.
14433 \end_layout
14434
14435 \begin_layout Standard
14436 The types 
14437 \family sans
14438 Letter
14439 \family default
14440  and 
14441 \family sans
14442 Opening
14443 \family default
14444  define the beginning of the letter and must be used in every letter.
14445  To emphasize them in the \SpecialChar LyX
14446  document class, they are marked with the letter
14447  
14448 \shape italic
14449 L
14450 \shape default
14451  or 
14452 \shape italic
14453 O
14454 \shape default
14455 , resp.
14456 \begin_inset space ~
14457 \end_inset
14458
14459 in the left margin.
14460  It is possible to write any number of letters in one file.
14461  An 
14462 \family sans
14463 Opening
14464 \family default
14465  type produces a new letter using the same addressee and a 
14466 \family sans
14467 Letter
14468 \family default
14469  type produces a new addressee.
14470  The types 
14471 \family sans
14472 Closing
14473 \family default
14474
14475 \family sans
14476 PS
14477 \family default
14478
14479 \family sans
14480 CC
14481 \family default
14482 , and 
14483 \family sans
14484 Encl
14485 \family default
14486  are ordinary paragraph types and can also be used several times in one
14487  and the same letter.
14488 \end_layout
14489
14490 \begin_layout Itemize
14491
14492 \family sans
14493 Letter
14494 \family default
14495 : produces a paragraph for the addressee and implicitly defines the beginning
14496  of the letter.
14497 \end_layout
14498
14499 \begin_layout Itemize
14500
14501 \family sans
14502 Opening
14503 \family default
14504 : produces a paragraph for the form of address and implicitly produces a
14505  new letter.
14506 \end_layout
14507
14508 \begin_layout Itemize
14509
14510 \family sans
14511 Closing
14512 \family default
14513 : produces a paragraph for a close.
14514 \end_layout
14515
14516 \begin_layout Itemize
14517
14518 \family sans
14519 PS
14520 \family default
14521 : produces a paragraph for a postscript.
14522 \end_layout
14523
14524 \begin_layout Itemize
14525
14526 \family sans
14527 CC
14528 \family default
14529 : produces a paragraph for a distribution list.
14530 \end_layout
14531
14532 \begin_layout Itemize
14533
14534 \family sans
14535 Encl
14536 \family default
14537 : produces a paragraph for enclosures.
14538 \end_layout
14539
14540 \begin_layout Standard
14541 The types 
14542 \family sans
14543 Name
14544 \family default
14545
14546 \family sans
14547 Signature
14548 \family default
14549
14550 \family sans
14551 Address
14552 \family default
14553
14554 \family sans
14555 Telephone
14556 \family default
14557
14558 \family sans
14559 Place
14560 \family default
14561
14562 \family sans
14563 Backaddress
14564 \family default
14565
14566 \family sans
14567 Specialmail
14568 \family default
14569
14570 \family sans
14571 Location
14572 \family default
14573
14574 \family sans
14575 Title
14576 \family default
14577 , and 
14578 \family sans
14579 Subject
14580 \family default
14581  are input types provided with a label to enter information, which will
14582  be processed by the document class.
14583 \begin_inset Foot
14584 status open
14585
14586 \begin_layout Plain Layout
14587 It could be seen as a matter of inconsequence, that the types 
14588 \family sans
14589 Letter
14590 \family default
14591  and 
14592 \family sans
14593 Opening
14594 \family default
14595  described above are not such input types as well.
14596  Because of the special meaning of those types, however, I have implemented
14597  them as ordinary paragraph types with a one letter mark in the left margin.
14598  Moreover, it would affect my feeling of symmetry, if the 
14599 \family sans
14600 Opening
14601 \family default
14602  type and the 
14603 \family sans
14604 Closing
14605 \family default
14606  type had such a serious different appearance.
14607 \end_layout
14608
14609 \end_inset
14610
14611  The types must be used ahead of the corresponding 
14612 \family sans
14613 Opening
14614 \family default
14615  type.
14616 \end_layout
14617
14618 \begin_layout Standard
14619 An implementation of these types in a WYSIWYG fashion does not seem to make
14620  sense, because the real appearance of the produced letter does not only
14621  depend on the usage of the particular type, but also on other factors.
14622  For example, a signature entered in the 
14623 \family sans
14624 Signature
14625 \family default
14626  type will in the standard behavior appear in the produced letter only,
14627  when in the same letter also a 
14628 \family sans
14629 Closing
14630 \family default
14631  type is used.
14632  The entered value of the 
14633 \family sans
14634 Telephone
14635 \family default
14636  type will in the standard behavior not appear in the produced letter at
14637  all.
14638  The possibility to design the letter`s heading freely is already indicated
14639  in a footnote above.
14640 \end_layout
14641
14642 \begin_layout Standard
14643 The input types can also be used as empty paragraphs.
14644  This makes sense e.
14645 \begin_inset space \thinspace{}
14646 \end_inset
14647
14648 g.
14649 \begin_inset space \space{}
14650 \end_inset
14651
14652 for the 
14653 \family sans
14654 Signature
14655 \family default
14656  type.
14657  If the 
14658 \family sans
14659 Signature
14660 \family default
14661  type is not used at all, in the standard behavior the value of the 
14662 \family sans
14663 Name
14664 \family default
14665  type is used as signature, whereas if an empty 
14666 \family sans
14667 Signature
14668 \family default
14669  type is used, no signature value is defined.
14670 \end_layout
14671
14672 \begin_layout Standard
14673 By using the input types it is possible to write a letter template, containing
14674  filled input types with your personal dates (name, address, etc.) and empty
14675  input types for other dates you want to enter.
14676 \end_layout
14677
14678 \begin_layout Itemize
14679
14680 \family sans
14681 Name
14682 \family default
14683 : sender's name, in the standard behavior appears as a centered paragraph
14684  in small caps in the letter`s heading.
14685 \end_layout
14686
14687 \begin_layout Itemize
14688
14689 \family sans
14690 Signature
14691 \family default
14692 : sender's signature, in the standard behavior appears below the 
14693 \family sans
14694 Closing
14695 \family default
14696  type.
14697  If no 
14698 \family sans
14699 Signature
14700 \family default
14701  type is used, the value of the 
14702 \family sans
14703 Name
14704 \family default
14705  type appears instead.
14706 \end_layout
14707
14708 \begin_layout Itemize
14709
14710 \family sans
14711 Address
14712 \family default
14713 : sender's address, in the standard behavior appears in a centered paragraph
14714  in the letter`s heading below the sender's name.
14715 \end_layout
14716
14717 \begin_layout Itemize
14718
14719 \family sans
14720 Telephone
14721 \family default
14722 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
14723  variable
14724  
14725 \family typewriter
14726
14727 \backslash
14728 telephonenum
14729 \family default
14730 .
14731 \end_layout
14732
14733 \begin_layout Itemize
14734
14735 \family sans
14736 Place
14737 \family default
14738 : place of the letter`s making.
14739 \end_layout
14740
14741 \begin_layout Itemize
14742
14743 \family sans
14744 Date
14745 \family default
14746 : date of the letter`s making.
14747  
14748 \family sans
14749 Place
14750 \family default
14751  and 
14752 \family sans
14753 Date
14754 \family default
14755 , in the standard behavior, produce the place and the date in a right-aligned
14756  line below the addressee's field.
14757  If an empty 
14758 \family sans
14759 Date
14760 \family default
14761  type is used, neither place nor date appear, independent of the value of
14762  the 
14763 \family sans
14764 Place
14765 \family default
14766  type.
14767  If no 
14768 \family sans
14769 Date
14770 \family default
14771  type is used, the date of the letter `s production is used.
14772 \end_layout
14773
14774 \begin_layout Itemize
14775
14776 \family sans
14777 Backaddress
14778 \family default
14779 : sender`s back address, in the standard behavior appears above the addressee's
14780  field in a small sans serif font.
14781 \end_layout
14782
14783 \begin_layout Itemize
14784
14785 \family sans
14786 Specialmail
14787 \family default
14788 : special mail information, in the standard behavior appears underlined
14789  above the addressee's field below the back address.
14790 \end_layout
14791
14792 \begin_layout Itemize
14793
14794 \family sans
14795 Location
14796 \family default
14797 : additional information, in the standard behavior appears on right side
14798  below the addressee`s field.
14799 \end_layout
14800
14801 \begin_layout Itemize
14802
14803 \family sans
14804 Title
14805 \family default
14806 : the letter's title, in the standard behavior appears in a big, bold, sans
14807  serif font above the subject.
14808 \end_layout
14809
14810 \begin_layout Itemize
14811
14812 \family sans
14813 Subject
14814 \family default
14815 : the letter's subject, in the standard behavior appears in a bold font
14816  above the 
14817 \family sans
14818 Opening
14819 \family default
14820  paragraph.
14821 \end_layout
14822
14823 \begin_layout Standard
14824 The types 
14825 \family sans
14826 Yourref
14827 \family default
14828
14829 \family sans
14830 Yourmail
14831 \family default
14832
14833 \family sans
14834 Myref
14835 \family default
14836
14837 \family sans
14838 Customer
14839 \family default
14840 , and 
14841 \family sans
14842 Invoice
14843 \family default
14844  produce a business letter like line above the 
14845 \family sans
14846 Title
14847 \family default
14848  line containing the fields 
14849 \begin_inset Quotes eld
14850 \end_inset
14851
14852 Your ref.
14853 \begin_inset Quotes erd
14854 \end_inset
14855
14856
14857 \begin_inset Quotes eld
14858 \end_inset
14859
14860 Your letter of
14861 \begin_inset Quotes erd
14862 \end_inset
14863
14864
14865 \begin_inset Quotes eld
14866 \end_inset
14867
14868 Our ref.
14869 \begin_inset Quotes erd
14870 \end_inset
14871
14872
14873 \begin_inset Quotes eld
14874 \end_inset
14875
14876 Customer no.
14877 \begin_inset Quotes erd
14878 \end_inset
14879
14880
14881 \begin_inset Quotes eld
14882 \end_inset
14883
14884 Invoice no.
14885 \begin_inset Quotes erd
14886 \end_inset
14887
14888 , and 
14889 \begin_inset Quotes eld
14890 \end_inset
14891
14892 Date
14893 \begin_inset Quotes erd
14894 \end_inset
14895
14896 .
14897  For the date field, the value of the 
14898 \family sans
14899 Date
14900 \family default
14901  type is used.
14902  If one of these 
14903 \begin_inset Quotes eld
14904 \end_inset
14905
14906 business letter types
14907 \begin_inset Quotes erd
14908 \end_inset
14909
14910  is used, the value of the 
14911 \family sans
14912 Place
14913 \family default
14914  type however does not appear, but only the \SpecialChar LaTeX
14915  variable 
14916 \family typewriter
14917
14918 \backslash
14919 fromplace
14920 \family default
14921  is set.
14922  The ordinary output of place and date in a right-aligned line below the
14923  addressee`s field is suppressed.
14924  The types are implemented as input types provided with a label and must
14925  be used ahead of the corresponding 
14926 \family sans
14927 Opening
14928 \family default
14929  type.
14930 \end_layout
14931
14932 \begin_layout Itemize
14933
14934 \family sans
14935 Yourref
14936 \family default
14937 : Your ref.
14938 \end_layout
14939
14940 \begin_layout Itemize
14941
14942 \family sans
14943 Yourmail
14944 \family default
14945 : Your letter of.
14946 \end_layout
14947
14948 \begin_layout Itemize
14949
14950 \family sans
14951 Myref
14952 \family default
14953 : Our ref.
14954 \end_layout
14955
14956 \begin_layout Itemize
14957
14958 \family sans
14959 Customer
14960 \family default
14961 : Customer no.
14962 \end_layout
14963
14964 \begin_layout Itemize
14965
14966 \family sans
14967 Invoice
14968 \family default
14969 : Invoice no.
14970 \end_layout
14971
14972 \begin_layout Subsection
14973 The new letter class: letter (koma-script v.2)
14974 \end_layout
14975
14976 \begin_layout Standard
14977 by 
14978 \noun on
14979 Jürgen Spitzmüller
14980 \end_layout
14981
14982 \begin_layout Standard
14983 \begin_inset VSpace medskip
14984 \end_inset
14985
14986
14987 \end_layout
14988
14989 \begin_layout Standard
14990 \noindent
14991 Koma-Script version 2.8 has introduced a new letter class 
14992 \family typewriter
14993 scrlttr2
14994 \family default
14995  which supersedes the now unsupported 
14996 \family typewriter
14997 scrlettr
14998 \family default
14999 .
15000  It has — on the \SpecialChar LaTeX
15001  side — a completely new interface and is not compatible
15002  with the old class.
15003  Therefore, \SpecialChar LyX
15004  supports both, though it is recommended you use the new class.
15005 \end_layout
15006
15007 \begin_layout Standard
15008 This class covers the same functionality as 
15009 \emph on
15010 letter (koma-script),
15011 \emph default
15012  and a few more.
15013  The basic items are 
15014 \family sans
15015 Address
15016 \family default
15017  (receiver's address, same as 
15018 \family sans
15019 Letter
15020 \family default
15021  in the old layout), 
15022 \family sans
15023 Opening
15024 \family default
15025 , and 
15026 \family sans
15027 Closing
15028 \family default
15029 .
15030  
15031 \family sans
15032 NextAddress
15033 \family default
15034  will start a new letter (i.
15035 \begin_inset space \thinspace{}
15036 \end_inset
15037
15038 e.
15039 \begin_inset space \space{}
15040 \end_inset
15041
15042 you can write several letters per document).
15043  New elements are sender's 
15044 \family sans
15045 E-Mail
15046 \family default
15047
15048 \family sans
15049 URL
15050 \family default
15051
15052 \family sans
15053 Fax
15054 \family default
15055
15056 \family sans
15057 Bank
15058 \family default
15059  and the possibility to use a 
15060 \family sans
15061 Logo
15062 \family default
15063  (via 
15064 \family sans
15065 Insert\SpecialChar menuseparator
15066 Graphics
15067 \family default
15068 ) in the header.
15069 \end_layout
15070
15071 \begin_layout Standard
15072 The biggest improvement is, though, that the letter's layout is configurable
15073  to meet almost any needs.
15074  This can be done via the preamble or with a special style file (Letter
15075  Class Option, extension 
15076 \family typewriter
15077 *.lco
15078 \family default
15079 ), that will be read in as a class option.
15080 \begin_inset Foot
15081 status collapsed
15082
15083 \begin_layout Plain Layout
15084 The KOMA package comes with some default 
15085 \family typewriter
15086 *.lco
15087 \family default
15088  files.
15089  There is, for instance, a 
15090 \family typewriter
15091 DIN.lco
15092 \family default
15093  file that follows german typesetting rules, or a 
15094 \family typewriter
15095 KOMAold.lco
15096 \family default
15097  that provides the default layout of the old 
15098 \family typewriter
15099 scrlettr
15100 \family default
15101  class.
15102  The latter can be loaded with the class option 
15103 \family typewriter
15104 KOMAold
15105 \family default
15106 , inserted via the 
15107 \family sans
15108 \bar under
15109 L
15110 \bar default
15111 ayout\SpecialChar menuseparator
15112
15113 \bar under
15114 D
15115 \bar default
15116 ocument\SpecialChar menuseparator
15117 Extra Options
15118 \family default
15119  field.
15120 \end_layout
15121
15122 \end_inset
15123
15124  Have a look at the 
15125 \emph on
15126 koma-letter2
15127 \emph default
15128  template that is included in \SpecialChar LyX
15129  for examples.
15130  A detailed description is to be found in the Koma-Script documentation
15131  (
15132 \emph on
15133 scrguide
15134 \emph default
15135 ).
15136 \end_layout
15137
15138 \begin_layout Subsection
15139 Problems
15140 \end_layout
15141
15142 \begin_layout Standard
15143 Visualizing the Koma-Script document classes in \SpecialChar LyX
15144 , the \SpecialChar LyX
15145  internals cause some
15146  problems.
15147 \end_layout
15148
15149 \begin_layout Itemize
15150 The chapter number of a 
15151 \family sans
15152 Chapter
15153 \family default
15154  type appears on a line of its own above the chapter heading instead of
15155  appearing in the same line ahead of it.
15156  The cause for that is the \SpecialChar LyX
15157  internal behavior for the labeltype 
15158 \family sans
15159 Counter_Chapter
15160 \family default
15161  in the layout file.
15162 \end_layout
15163
15164 \begin_layout Itemize
15165 The headings of the types 
15166 \family sans
15167 Addchap
15168 \family default
15169  and 
15170 \family sans
15171 Addsec
15172 \family default
15173  are only put in the 
15174 \begin_inset Quotes eld
15175 \end_inset
15176
15177 true
15178 \begin_inset Quotes erd
15179 \end_inset
15180
15181  \SpecialChar LaTeX
15182  table of contents, but not in the \SpecialChar LyX
15183  table of contents (
15184 \family sans
15185 Document\SpecialChar menuseparator
15186 Table
15187 \begin_inset space ~
15188 \end_inset
15189
15190 of
15191 \begin_inset space ~
15192 \end_inset
15193
15194 Contents
15195 \family default
15196 ).
15197 \end_layout
15198
15199 \begin_layout Itemize
15200 The paragraphs in a 
15201 \emph on
15202 letter
15203 \emph default
15204  document class appear in a skip separation mode, not indented.
15205  This is the standard behavior, no special \SpecialChar LaTeX
15206  commands are needed for that.
15207  But in the 
15208 \family sans
15209 Document\SpecialChar menuseparator
15210 Settings
15211 \family default
15212  dialog the corresponding radio button indicates 
15213 \family sans
15214 Indent
15215 \family default
15216 .
15217  A 
15218 \family sans
15219 Skip
15220 \family default
15221  value always has the effect that extra \SpecialChar LaTeX
15222  commands are inserted in the document
15223  to produce the gap, which is not what is wanted in this case.
15224 \end_layout
15225
15226 \begin_layout Section
15227 Memoir
15228 \end_layout
15229
15230 \begin_layout Standard
15231 By 
15232 \noun on
15233 Jürgen Spitzmüller
15234 \end_layout
15235
15236 \begin_layout Subsection
15237 Overview
15238 \end_layout
15239
15240 \begin_layout Standard
15241 Memoir is a very powerful and constantly evolving class.
15242  It has been designed with regard to fictional and non-fictional literature.
15243  Its aim is to let the user have maximum control over the typesetting of
15244  his document.
15245  Memoir is based on the standard book class, but it can also emulate the
15246  article class (see below).
15247 \end_layout
15248
15249 \begin_layout Standard
15250 Peter Wilson, the developer of Memoir, is known as the author of lots of
15251  useful packages in the \SpecialChar LaTeX
15252  world.
15253  Most of them have been merged with Memoir.
15254  Therefore, it is much easier to layout the table of contents, appendices,
15255  chapter designs and such.
15256  \SpecialChar LyX
15257 , though, does not support all of these goodies natively.
15258  Some of them might be added to forthcoming releases
15259 \begin_inset Foot
15260 status collapsed
15261
15262 \begin_layout Plain Layout
15263 You are invited to send suggestions to 
15264 \begin_inset Flex URL
15265 status collapsed
15266
15267 \begin_layout Plain Layout
15268
15269 lyx-devel@lists.lyx.org
15270 \end_layout
15271
15272 \end_inset
15273
15274 .
15275 \end_layout
15276
15277 \end_inset
15278
15279 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
15280 's framework.
15281  Of course you can still use all features with the help of some native \SpecialChar LaTeX
15282
15283  commands (\SpecialChar TeX
15284  code
15285 \begin_inset Foot
15286 status collapsed
15287
15288 \begin_layout Plain Layout
15289 Cf.
15290 \begin_inset ERT
15291 status collapsed
15292
15293 \begin_layout Plain Layout
15294
15295
15296 \backslash
15297  
15298 \end_layout
15299
15300 \end_inset
15301
15302 section
15303 \begin_inset space ~
15304 \end_inset
15305
15306
15307 \begin_inset CommandInset ref
15308 LatexCommand ref
15309 reference "sec:Inserting-TeX-Code"
15310
15311 \end_inset
15312
15313  for details.
15314 \end_layout
15315
15316 \end_inset
15317
15318 ).
15319  In this section, we can only list those features that are natively supported
15320  by \SpecialChar LyX
15321 .
15322  For detailed descriptions (and for the rest of features) we recommend you
15323  have a look at the detailed manual of the Memoir class
15324 \begin_inset Foot
15325 status collapsed
15326
15327 \begin_layout Plain Layout
15328 Cf.
15329 \begin_inset ERT
15330 status collapsed
15331
15332 \begin_layout Plain Layout
15333
15334
15335 \backslash
15336  
15337 \end_layout
15338
15339 \end_inset
15340
15341
15342 \begin_inset Flex URL
15343 status collapsed
15344
15345 \begin_layout Plain Layout
15346
15347 CTAN:/macros/latex/memoir/memman.pdf
15348 \end_layout
15349
15350 \end_inset
15351
15352 .
15353 \end_layout
15354
15355 \end_inset
15356
15357 , which is not only a user guide for the class, but also both a comprehensive
15358  description on good typesetting and a superb example for good typesetting
15359  itself.
15360 \end_layout
15361
15362 \begin_layout Subsection
15363 Basic features and restrictions
15364 \end_layout
15365
15366 \begin_layout Standard
15367 Memoir supports basically all features of the standard book classes.
15368  There are, however, some differences, as follows:
15369 \end_layout
15370
15371 \begin_layout Description
15372 Font
15373 \begin_inset space ~
15374 \end_inset
15375
15376 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
15377 \end_layout
15378
15379 \begin_layout Description
15380 Page
15381 \begin_inset space ~
15382 \end_inset
15383
15384 style: The fancy page style is not supported, due to a command clash between
15385  Memoir and the fancyhdr package (they both define a command with the same
15386  name, which confuses \SpecialChar LaTeX
15387 ).
15388  Instead, Memoir comes with a number of its own page styles (see 
15389 \family sans
15390 Layout\SpecialChar menuseparator
15391 Document\SpecialChar menuseparator
15392 Page
15393 \begin_inset space ~
15394 \end_inset
15395
15396 Style
15397 \family default
15398 ).
15399  If you want to use these for the chapter pages, you have to use the command
15400  
15401 \family typewriter
15402
15403 \backslash
15404 chapterstyle
15405 \family default
15406  in the main text or in preamble (e.
15407 \begin_inset space \thinspace{}
15408 \end_inset
15409
15410 g.
15411 \begin_inset space \space{}
15412 \end_inset
15413
15414
15415 \family typewriter
15416
15417 \backslash
15418 chapterstyle{companion}
15419 \family default
15420 ).
15421 \end_layout
15422
15423 \begin_layout Description
15424 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
15425  optional argument in the standard classes.
15426  With this, you can specify an alternative version of the title for the
15427  table of contents and the headers (for instance, if the title is too long).
15428  In \SpecialChar LyX
15429 , you can do this via 
15430 \family sans
15431 Insert\SpecialChar menuseparator
15432 Short
15433 \begin_inset space ~
15434 \end_inset
15435
15436 Title
15437 \family default
15438  at the beginning of a chapter/section.
15439  Memoir features a second optional argument and thus separates the table
15440  of contents from the header.
15441  You can define three variants of a title with this: one for the main text,
15442  one for the table of contents, and one for the headers.
15443  Simply insert two optional arguments if you need this feature, the first
15444  one containing the short title for the Table of Contents, the second one
15445  containing an alternative short title for the headers.
15446 \end_layout
15447
15448 \begin_layout Description
15449 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15450  of contents, the list of figures and the list of table start a new page
15451  automatically.
15452  Memoir does not follow this route.
15453  You have to insert a page break yourself, if you want to have one.
15454 \end_layout
15455
15456 \begin_layout Description
15457 Titlepage: For some unknown reason, Memoir uses pagination on the title
15458  page (in the standard classes, title pages are 
15459 \begin_inset Quotes eld
15460 \end_inset
15461
15462 empty
15463 \begin_inset Quotes erd
15464 \end_inset
15465
15466 ).
15467  If you want an empty title page, type 
15468 \family typewriter
15469
15470 \backslash
15471 aliaspagestyle{title}{empty}
15472 \family default
15473  in the preamble.
15474 \end_layout
15475
15476 \begin_layout Description
15477 Article: With the class option 
15478 \emph on
15479 article
15480 \emph default
15481  (to be inserted in 
15482 \family sans
15483 Layout\SpecialChar menuseparator
15484 Document\SpecialChar menuseparator
15485 Extra
15486 \begin_inset space ~
15487 \end_inset
15488
15489 Options
15490 \family default
15491 ), you can emulate article style.
15492  That is, counters (footnotes, figures, tables etc.) will not be reset on
15493  new chapters, chapters don't start a new page (but are—in contrary to 
15494 \begin_inset Quotes eld
15495 \end_inset
15496
15497 real
15498 \begin_inset Quotes erd
15499 \end_inset
15500
15501  article classes—still allowed), parts, though, use their own page, as in
15502  book.
15503 \end_layout
15504
15505 \begin_layout Description
15506 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15507  font commands, which have been used in the old \SpecialChar LaTeX
15508  version 2.09 (e.
15509 \begin_inset space \thinspace{}
15510 \end_inset
15511
15512 g.
15513 \begin_inset space \space{}
15514 \end_inset
15515
15516
15517 \family typewriter
15518
15519 \backslash
15520 rm
15521 \family default
15522
15523 \family typewriter
15524
15525 \backslash
15526 it
15527 \family default
15528 ).
15529  It produces an error and stops \SpecialChar LaTeX
15530  whenever such a command appears.
15531  The class option 
15532 \emph on
15533 oldfontcommands
15534 \emph default
15535  reallows the commands and spits out warnings instead (which does at least
15536  not stop \SpecialChar LaTeX
15537 ).
15538  Since a lot of packages and particularly Bib\SpecialChar TeX
15539  style files are still using
15540  those commands, we have decided to use this option by default.
15541 \end_layout
15542
15543 \begin_layout Subsection
15544 Extra features
15545 \end_layout
15546
15547 \begin_layout Standard
15548 We will only describe the features supported by \SpecialChar LyX
15549  (which is not much currently).
15550  Please consult the Memoir manual
15551 \begin_inset Foot
15552 status collapsed
15553
15554 \begin_layout Plain Layout
15555 Cf.
15556 \begin_inset ERT
15557 status collapsed
15558
15559 \begin_layout Plain Layout
15560
15561
15562 \backslash
15563  
15564 \end_layout
15565
15566 \end_inset
15567
15568
15569 \begin_inset Flex URL
15570 status collapsed
15571
15572 \begin_layout Plain Layout
15573
15574 CTAN:/macros/latex/memoir/memman.pdf
15575 \end_layout
15576
15577 \end_inset
15578
15579 .
15580 \end_layout
15581
15582 \end_inset
15583
15584  for details.
15585 \end_layout
15586
15587 \begin_layout Description
15588 Abstract: You may wonder why an abstract is an extra feature.
15589  Well, it is in book class.
15590  Usually books don't have abstracts.
15591  Memoir, however, has.
15592  You can use it wherever and how often you like.
15593 \end_layout
15594
15595 \begin_layout Description
15596 Chapterprecis: You may know this older typesetting style: The contents of
15597  a chapter are summarized below the title and also in the table of contents
15598  (e.
15599 \begin_inset space \thinspace{}
15600 \end_inset
15601
15602 g.
15603 \begin_inset space \space{}
15604 \end_inset
15605
15606
15607 \emph on
15608 Our hero arrives in Troia; he loses some friends; he finds others
15609 \emph default
15610 ).
15611  Chapterprecis does exactly this.
15612  It is therefore only sensible below a chapter.
15613 \end_layout
15614
15615 \begin_layout Description
15616 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
15617  The epigraph environment provides an elegant way of typesetting such a
15618  motto.
15619  The motto itself (text) and its author (source) are divided by a short
15620  line.
15621  Unfortunately, we have to fool \SpecialChar LyX
15622  a bit here again, since the environment
15623  needs two arguments (text and source).
15624  In this case, we have to use curly brackets (in \SpecialChar TeX
15625  mode) between the two
15626  arguments: 
15627 \emph on
15628 <smart slogan>
15629 \emph default
15630  
15631 \family typewriter
15632 }{
15633 \family default
15634  
15635 \emph on
15636 <author of the slogan>.
15637 \end_layout
15638
15639 \begin_layout Description
15640 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
15641  complex figurative poems).
15642  \SpecialChar LyX
15643  can only support a few of them.
15644  One is poemtitle, which is a centered title for poems, which will also
15645  be added to the table of contents (verse is the standard environment for
15646  poems.
15647  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
15648  code,
15649  because they have to be nested inside regular verse environments, which
15650  is not possible with \SpecialChar LyX
15651 ).
15652 \end_layout
15653
15654 \begin_layout Description
15655 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
15656 \end_layout
15657
15658 \begin_layout Section
15659 Article (mwart), book (mwbk) and report (mwrep)
15660 \begin_inset Argument status
15661 status collapsed
15662
15663 \begin_layout Plain Layout
15664 The 
15665 \family typewriter
15666 mw
15667 \family default
15668  Classes
15669 \end_layout
15670
15671 \end_inset
15672
15673
15674 \end_layout
15675
15676 \begin_layout Standard
15677 by 
15678 \noun on
15679 Tomasz Luczak
15680 \end_layout
15681
15682 \begin_layout Standard
15683 The \SpecialChar LyX
15684  document classes 
15685 \emph on
15686 article (mwart)
15687 \emph default
15688
15689 \emph on
15690 report (mwrep)
15691 \emph default
15692  and 
15693 \emph on
15694 book
15695 \emph default
15696  
15697 \emph on
15698 (mwbk)
15699 \emph default
15700  correspond to the \SpecialChar LaTeX
15701  document classes 
15702 \family typewriter
15703 mwart.cls
15704 \family default
15705
15706 \family typewriter
15707 mwrep.cls
15708 \family default
15709  and 
15710 \family typewriter
15711 mwbk.cls
15712 \family default
15713 , resp.
15714  They are replacements for the standard document classes 
15715 \family typewriter
15716 article.cls
15717 \family default
15718
15719 \family typewriter
15720 report.cls
15721 \family default
15722  and 
15723 \family typewriter
15724 book.cls
15725 \family default
15726 , resp., and fit better to Polish typography conventions in a number of points.
15727  
15728 \end_layout
15729
15730 \begin_layout Standard
15731 Basic differences:
15732 \end_layout
15733
15734 \begin_layout Itemize
15735 Unnumbered titles (with star, e.
15736 \begin_inset space \thinspace{}
15737 \end_inset
15738
15739 g.
15740 \begin_inset space \space{}
15741 \end_inset
15742
15743
15744 \family sans
15745 Section*
15746 \family default
15747 ) are added into table of contents,
15748 \end_layout
15749
15750 \begin_layout Itemize
15751 Additional page styles:
15752 \begin_inset Separator parbreak
15753 \end_inset
15754
15755
15756 \end_layout
15757
15758 \begin_deeper
15759 \begin_layout Description
15760 uheadings header with separated lines,
15761 \end_layout
15762
15763 \begin_layout Description
15764 myheadings custom header, contents headers via commands: 
15765 \family typewriter
15766
15767 \backslash
15768 markright
15769 \family default
15770  and 
15771 \family typewriter
15772
15773 \backslash
15774 markboth
15775 \family default
15776 ,
15777 \end_layout
15778
15779 \begin_layout Description
15780 myuheadings custom header with separated lines,
15781 \end_layout
15782
15783 \begin_layout Description
15784 outer page number is placed on outer side of page
15785 \end_layout
15786
15787 \end_deeper
15788 \begin_layout Itemize
15789 Options 
15790 \begin_inset Separator parbreak
15791 \end_inset
15792
15793
15794 \end_layout
15795
15796 \begin_deeper
15797 \begin_layout Description
15798 rmheadings serif titles — default,
15799 \end_layout
15800
15801 \begin_layout Description
15802 sfheadings sansserif titles,
15803 \end_layout
15804
15805 \begin_layout Description
15806 authortitle on title page first placed is author next title — default,
15807 \end_layout
15808
15809 \begin_layout Description
15810 titleauthor on title page first placed is title next author,
15811 \end_layout
15812
15813 \begin_layout Description
15814 withmarginpar reserve place on page for margins.
15815 \end_layout
15816
15817 \end_deeper
15818 \begin_layout Section
15819 Paper
15820 \end_layout
15821
15822 \begin_layout Standard
15823 The document class 
15824 \family sans
15825 paper
15826 \family default
15827  provides an alternative to the standard 
15828 \family sans
15829 article
15830 \family default
15831  class.
15832  It provides similar functionality, but you might prefer this layout with
15833  sans serif sections, headings, and more.
15834 \end_layout
15835
15836 \begin_layout Section
15837 Rev\SpecialChar TeX
15838 4
15839 \end_layout
15840
15841 \begin_layout Standard
15842 by 
15843 \noun on
15844 Amir Karger
15845 \end_layout
15846
15847 \begin_layout Standard
15848 \begin_inset VSpace bigskip
15849 \end_inset
15850
15851
15852 \end_layout
15853
15854 \begin_layout Standard
15855 \noindent
15856 The 
15857 \family sans
15858 Revtex
15859 \begin_inset space ~
15860 \end_inset
15861
15862 4
15863 \family default
15864  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
15865  4.0 (the 
15866 \begin_inset Formula $\beta$
15867 \end_inset
15868
15869  release of May, 1999) class.
15870 \end_layout
15871
15872 \begin_layout Standard
15873 \SpecialChar LyX
15874  has a 
15875 \family sans
15876 Revtex
15877 \family default
15878  textclass, which works with Rev\SpecialChar TeX
15879  3.1.
15880  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
15881  2.09.
15882  That means that it doesn't interact very well with \SpecialChar LyX
15883 , which requires \SpecialChar LaTeX2e
15884 , although
15885  it has been kludged to work.
15886  Since Rev\SpecialChar TeX
15887  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
15888 , \SpecialChar LyX
15889  with the
15890  
15891 \family sans
15892 Rev\SpecialChar TeX
15893
15894 \begin_inset space ~
15895 \end_inset
15896
15897 4
15898 \family default
15899  textclass should also be pretty easy to use.
15900 \end_layout
15901
15902 \begin_layout Standard
15903 These documents are supposed to be used in 
15904 \emph on
15905 addition
15906 \emph default
15907  to the Rev\SpecialChar TeX
15908  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
15909  macros,
15910  and assume you'll know what to put in the preamble if necessary.
15911 \end_layout
15912
15913 \begin_layout Subsection
15914 Installation
15915 \end_layout
15916
15917 \begin_layout Standard
15918 All you need to do is install Rev\SpecialChar TeX
15919  4, as described in the package's README
15920  file.
15921  The package can be found at The Rev\SpecialChar TeX
15922  4 Web Site 
15923 \begin_inset Flex URL
15924 status collapsed
15925
15926 \begin_layout Plain Layout
15927
15928 http://publish.aps.org/revtex4/
15929 \end_layout
15930
15931 \end_inset
15932
15933 .
15934  Install it somewhere that \SpecialChar LaTeX
15935  can see it.
15936  Test it by trying to \SpecialChar LaTeX
15937  a short Rev\SpecialChar TeX
15938  4 document in some random directory (i.
15939 \begin_inset space \thinspace{}
15940 \end_inset
15941
15942 e.
15943 \begin_inset space \space{}
15944 \end_inset
15945
15946 not the directory where you installed the class file.) Then, if you reconfigure
15947  \SpecialChar LyX
15948 , it will find the class file and let you use the Rev\SpecialChar TeX
15949 4 textclass.
15950 \end_layout
15951
15952 \begin_layout Standard
15953 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
15954  4 document
15955  using 
15956 \family typewriter
15957 tex2lyx
15958 \family default
15959 , or to use the 
15960 \family sans
15961 Revtex
15962 \begin_inset space ~
15963 \end_inset
15964
15965 4
15966 \family default
15967  template, found in the templates directory.
15968 \end_layout
15969
15970 \begin_layout Subsection
15971 Preamble Matter
15972 \end_layout
15973
15974 \begin_layout Standard
15975 Optional arguments to 
15976 \family typewriter
15977
15978 \backslash
15979 documentclass
15980 \family default
15981 , like 
15982 \begin_inset Quotes eld
15983 \end_inset
15984
15985 preprint
15986 \begin_inset Quotes erd
15987 \end_inset
15988
15989  and 
15990 \begin_inset Quotes eld
15991 \end_inset
15992
15993 aps
15994 \begin_inset Quotes erd
15995 \end_inset
15996
15997 , go in the 
15998 \family sans
15999 E
16000 \bar under
16001 x
16002 \bar default
16003 tra
16004 \begin_inset space ~
16005 \end_inset
16006
16007 Options
16008 \family default
16009  field in the 
16010 \family sans
16011 Document
16012 \begin_inset space ~
16013 \end_inset
16014
16015 Layout
16016 \family default
16017  dialog, as usual.
16018  Remember that in Rev\SpecialChar TeX
16019 , at least one optional argument is required! 
16020 \end_layout
16021
16022 \begin_layout Standard
16023 Other preamble matter, like 
16024 \family typewriter
16025
16026 \backslash
16027 draft
16028 \family default
16029  etc.
16030 \begin_inset space ~
16031 \end_inset
16032
16033 goes in the 
16034 \family sans
16035 \SpecialChar LaTeX
16036
16037 \begin_inset space ~
16038 \end_inset
16039
16040 Preamble
16041 \family default
16042  dialog, also as usual.
16043 \end_layout
16044
16045 \begin_layout Subsection
16046 Layouts
16047 \end_layout
16048
16049 \begin_layout Standard
16050 The layouts basically correspond to the commands in Rev\SpecialChar TeX
16051 4.0.
16052  For example, the Email layout corresponds to 
16053 \family typewriter
16054
16055 \backslash
16056 email{}
16057 \family default
16058 .
16059  Note that (at least as of Rev\SpecialChar TeX
16060  4.0 Beta), the 
16061 \family sans
16062 Address
16063 \family default
16064  and 
16065 \family sans
16066 Affiliation
16067 \family default
16068  layouts are exactly equivalent, so you shouldn't need to use both.
16069 \begin_inset Foot
16070 status collapsed
16071
16072 \begin_layout Plain Layout
16073 In case you're curious, both were included so that 
16074 \family typewriter
16075 tex2lyx
16076 \family default
16077  would be able to translate both 
16078 \family typewriter
16079
16080 \backslash
16081 address
16082 \family default
16083  and 
16084 \family typewriter
16085
16086 \backslash
16087 affiliation
16088 \family default
16089 .
16090 \end_layout
16091
16092 \end_inset
16093
16094
16095 \end_layout
16096
16097 \begin_layout Subsection
16098 Important Notes
16099 \end_layout
16100
16101 \begin_layout Standard
16102 There are a couple of important unique aspects of Rev\SpecialChar TeX
16103  4 which might cause
16104  bugs that will be even more confusing in \SpecialChar LyX
16105 .
16106 \end_layout
16107
16108 \begin_layout Standard
16109 In Rev\SpecialChar TeX
16110 , the 
16111 \family typewriter
16112
16113 \backslash
16114 thanks
16115 \family default
16116  command goes 
16117 \emph on
16118 outside
16119 \emph default
16120  the 
16121 \family typewriter
16122
16123 \backslash
16124 author
16125 \family default
16126  command.
16127  The \SpecialChar LyX
16128  equivalent is that there is a separate Thanks layout.
16129  Do 
16130 \emph on
16131 not
16132 \emph default
16133  write footnotes in the 
16134 \family sans
16135 Author
16136 \family default
16137  layout, or weird things may happen.
16138  See the Rev\SpecialChar TeX
16139  4 documentation for more details.
16140 \end_layout
16141
16142 \begin_layout Standard
16143 Also, the 
16144 \family sans
16145 Author
16146 \begin_inset space ~
16147 \end_inset
16148
16149 Email
16150 \family default
16151
16152 \family sans
16153 Author
16154 \begin_inset space ~
16155 \end_inset
16156
16157 URL
16158 \family default
16159 , and 
16160 \family sans
16161 Thanks
16162 \family default
16163  layouts must be placed 
16164 \emph on
16165 in between
16166 \emph default
16167  the 
16168 \family sans
16169 Author
16170 \family default
16171  layout and the corresponding 
16172 \family sans
16173 Address
16174 \family default
16175  (or equivalent 
16176 \family sans
16177 Affiliation
16178 \family default
16179 ) layout.
16180  If you put the 
16181 \family sans
16182 Thanks
16183 \family default
16184  after the 
16185 \family sans
16186 Address
16187 \family default
16188 , the \SpecialChar LaTeX
16189  won't compile.
16190 \end_layout
16191
16192 \begin_layout Subsection
16193 Drawbacks
16194 \end_layout
16195
16196 \begin_layout Standard
16197 The main problem with this layout is that you can't use the optional arguments
16198  to layouts like Email and Title.
16199  (The problem is not unique to this layout; you can't use optional arguments
16200  to the Section layouts either.) This means that after you export that file
16201  to \SpecialChar LaTeX
16202  (which you'll need to do eventually to send it in to APS), you'll need
16203  to edit the \SpecialChar LaTeX
16204  file with a text editor to add the optional arguments to set,
16205  e.
16206 \begin_inset space \thinspace{}
16207 \end_inset
16208
16209 g.
16210 \begin_inset space \space{}
16211 \end_inset
16212
16213 the running title for the page headers.
16214  Lacking these layouts makes the 
16215 \family typewriter
16216
16217 \backslash
16218 altaffiliation
16219 \family default
16220  (and the equivalent 
16221 \family typewriter
16222
16223 \backslash
16224 altaddress
16225 \family default
16226 ) useless, so the corresponding layouts don't exist, and will have to be
16227  added by hand.
16228 \begin_inset Foot
16229 status collapsed
16230
16231 \begin_layout Plain Layout
16232
16233 \emph on
16234 Note from JMarc:
16235 \emph default
16236  actually, \SpecialChar LyX
16237  1.3.0 supports some forms of optional arguments, but this layout
16238  has not been updated yet to take advantage of it.
16239 \end_layout
16240
16241 \end_inset
16242
16243  
16244 \end_layout
16245
16246 \begin_layout Section
16247 Springer Journals (
16248 \family sans
16249 svjour
16250 \family default
16251 )
16252 \end_layout
16253
16254 \begin_layout Standard
16255 by 
16256 \noun on
16257 Martin Vermeer
16258 \end_layout
16259
16260 \begin_layout Subsection
16261 Description
16262 \end_layout
16263
16264 \begin_layout Standard
16265 These are the layout files for some of the journal formats used by Springer
16266  Verlag and listed on 
16267 \begin_inset Flex URL
16268 status collapsed
16269
16270 \begin_layout Plain Layout
16271
16272 http://www.springer.de/author/tex/help-journals.html
16273 \end_layout
16274
16275 \end_inset
16276
16277 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
16278  now!).
16279  It is a modular system: the things common to all journals are implemented
16280  in 
16281 \family typewriter
16282 svjour.inc
16283 \family default
16284 , which journal-specific layout files (such as, e.
16285 \begin_inset space \thinspace{}
16286 \end_inset
16287
16288 g.
16289 \begin_inset space \space{}
16290 \end_inset
16291
16292
16293 \family typewriter
16294 svjog.layout
16295 \family default
16296  for Journal of Geodesy) can include.
16297 \end_layout
16298
16299 \begin_layout Standard
16300 This means that implementing support for any other Springer journal on this
16301  list is as simple as writing your own 
16302 \family typewriter
16303 sv
16304 \family default
16305 <myjournal>
16306 \family typewriter
16307 .layout
16308 \family default
16309  file following the outline given in 
16310 \family typewriter
16311 svjog.layout
16312 \family default
16313 .
16314  
16315 \end_layout
16316
16317 \begin_layout Standard
16318 It is reasonably well tested only for the Journal of Geodesy.
16319  
16320 \family typewriter
16321 svjour
16322 \family default
16323  and 
16324 \family typewriter
16325 svjog
16326 \family default
16327  come with the standard \SpecialChar LyX
16328  distribution.
16329  Install the relevant class file (downloaded from Springer) in a proper
16330  directory, reconfigure \SpecialChar LaTeX
16331  (in the te\SpecialChar TeX
16332  case by running 
16333 \family typewriter
16334 texhash
16335 \family default
16336 , as root if necessary — doesn't \SpecialChar LyX
16337  take care of this?), reconfigure \SpecialChar LyX
16338  and
16339  it should work.
16340 \end_layout
16341
16342 \begin_layout Subsection
16343 New styles
16344 \end_layout
16345
16346 \begin_layout Standard
16347 A large number of theorem-like styles — 
16348 \family sans
16349 Claim, Conjecture,
16350 \family default
16351  
16352 \family sans
16353 \SpecialChar ldots
16354 Theorem
16355 \family default
16356 .
16357 \end_layout
16358
16359 \begin_layout Standard
16360
16361 \family sans
16362 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
16363 _Title, Author_Running, Institute,
16364  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
16365 \family default
16366 .
16367  See the Springer class file documentation for details.
16368 \end_layout
16369
16370 \begin_layout Subsection
16371 Supported journals
16372 \end_layout
16373
16374 \begin_layout Itemize
16375
16376 \emph on
16377 Journal of Geodesy
16378 \emph default
16379
16380 \family typewriter
16381 svjog.layout
16382 \family default
16383  — Martin Vermeer
16384 \end_layout
16385
16386 \begin_layout Itemize
16387
16388 \emph on
16389 Probability Theory and Related Fields
16390 \emph default
16391
16392 \family typewriter
16393 svprobth.layout
16394 \family default
16395  — Jean-Marc Lasgouttes
16396 \end_layout
16397
16398 \begin_layout Standard
16399 Add your own, it isn't so hard!
16400 \end_layout
16401
16402 \begin_layout Subsection
16403 Credits
16404 \end_layout
16405
16406 \begin_layout Standard
16407 These files are partly based on the older 
16408 \family typewriter
16409 ejour2.layout
16410 \family default
16411 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
16412  2.09 style
16413  file from Springer.
16414  All this, and the 
16415 \family typewriter
16416 ejour2
16417 \family default
16418  layout, are now defunct.
16419  Jean-Marc Lasgouttes helped out big in making me find my way around the
16420  \SpecialChar LyX
16421  layout file mechanism.
16422 \end_layout
16423
16424 \begin_layout Subsection
16425 Bugs
16426 \end_layout
16427
16428 \begin_layout Standard
16429 Probably.
16430  But probably less than in the old hacked-\SpecialChar LaTeX
16431  
16432 \family typewriter
16433 ejour2
16434 \family default
16435 .
16436 \end_layout
16437
16438 \begin_layout Standard
16439 Limitations e.
16440 \begin_inset space \thinspace{}
16441 \end_inset
16442
16443 g.: does not display the number for theorem-like layouts, just #.
16444 \end_layout
16445
16446 \begin_layout Section
16447 Slides [aka 
16448 \noun on
16449 Sli\SpecialChar TeX
16450
16451 \noun default
16452 ]
16453 \begin_inset CommandInset label
16454 LatexCommand label
16455 name "sec:slitex"
16456
16457 \end_inset
16458
16459
16460 \end_layout
16461
16462 \begin_layout Standard
16463 by 
16464 \noun on
16465 John Weiss
16466 \noun default
16467  
16468 \end_layout
16469
16470 \begin_layout Subsection
16471 Introduction
16472 \end_layout
16473
16474 \begin_layout Standard
16475 This section describes how to use \SpecialChar LyX
16476  to make slides for overhead projectors.
16477  There are two document classes that can do this: the default slides class
16478  and the 
16479 \family sans
16480 Foil\SpecialChar TeX
16481
16482 \family default
16483  slides class.
16484  This section documents the former.
16485 \end_layout
16486
16487 \begin_layout Standard
16488 I'm going to say this again, nice and clear, so that there's no misunderstanding
16489 :
16490 \end_layout
16491
16492 \begin_layout Standard
16493 \begin_inset VSpace bigskip
16494 \end_inset
16495
16496
16497 \end_layout
16498
16499 \begin_layout Standard
16500 \align center
16501
16502 \size large
16503 This section documents the class 
16504 \begin_inset Quotes eld
16505 \end_inset
16506
16507
16508 \family sans
16509 slides (default)
16510 \family default
16511
16512 \begin_inset Quotes erd
16513 \end_inset
16514
16515  
16516 \emph on
16517 only.
16518 \end_layout
16519
16520 \begin_layout Standard
16521 \begin_inset VSpace bigskip
16522 \end_inset
16523
16524
16525 \end_layout
16526
16527 \begin_layout Standard
16528 If you're looking for the documentation for 
16529 \begin_inset Quotes eld
16530 \end_inset
16531
16532
16533 \family sans
16534 slides (Foil\SpecialChar TeX
16535 )
16536 \family default
16537
16538 \begin_inset Quotes erd
16539 \end_inset
16540
16541 , check out section
16542 \begin_inset space ~
16543 \end_inset
16544
16545
16546 \begin_inset CommandInset ref
16547 LatexCommand ref
16548 reference "sec:foiltex"
16549
16550 \end_inset
16551
16552 .
16553  The 
16554 \family sans
16555 foils
16556 \family default
16557  class [
16558 \begin_inset Quotes eld
16559 \end_inset
16560
16561
16562 \family sans
16563 slides (Foil\SpecialChar TeX
16564 )
16565 \family default
16566
16567 \begin_inset Quotes erd
16568 \end_inset
16569
16570 ] is actually somewhat better than the default 
16571 \family sans
16572 slides
16573 \family default
16574  class,
16575 \begin_inset Foot
16576 status collapsed
16577
16578 \begin_layout Plain Layout
16579 \SpecialChar ldots
16580 or so I've been told repeatedly by its advocates.
16581  Having never used it, I have no idea if this claim is true or not.
16582 \end_layout
16583
16584 \end_inset
16585
16586  which this section documents.
16587 \end_layout
16588
16589 \begin_layout Standard
16590 This class is the \SpecialChar LaTeX2e
16591  improvement of the old 
16592 \noun on
16593 Sli\SpecialChar TeX
16594
16595 \noun default
16596  package.
16597  Every \SpecialChar LaTeX2e
16598  distribution includes this class [which I'll just refer to as 
16599 \begin_inset Quotes eld
16600 \end_inset
16601
16602
16603 \family sans
16604 slides
16605 \family default
16606
16607 \begin_inset Quotes erd
16608 \end_inset
16609
16610  from now on], so you're bound to have it.
16611  As I noted earlier, there are other classes, such as 
16612 \family sans
16613 foils
16614 \family default
16615 , which also produce slides for overhead projectors and do a better job
16616  at it.
16617  However, there are some things which 
16618 \family sans
16619 slides
16620 \family default
16621  can do which the others can't, such as generate overlays.
16622  Read on to learn more!
16623 \end_layout
16624
16625 \begin_layout Subsection
16626 Getting Started
16627 \begin_inset CommandInset label
16628 LatexCommand label
16629 name "sec:slidesetup"
16630
16631 \end_inset
16632
16633
16634 \end_layout
16635
16636 \begin_layout Standard
16637 Obviously, to use this document class, you need to select 
16638 \begin_inset Quotes eld
16639 \end_inset
16640
16641
16642 \family sans
16643 slides (default)
16644 \family default
16645
16646 \begin_inset Quotes erd
16647 \end_inset
16648
16649  from the class list in the 
16650 \family sans
16651 Document\SpecialChar menuseparator
16652 Settings
16653 \family default
16654  dialog.
16655  There are some other special things you should know about this class:
16656 \end_layout
16657
16658 \begin_layout Itemize
16659 Don't bother changing the options 
16660 \family sans
16661 Sides and Columns
16662 \family default
16663 .
16664  They're not supported by the 
16665 \family sans
16666 slides
16667 \family default
16668  class, anyways.
16669 \end_layout
16670
16671 \begin_layout Itemize
16672 The option 
16673 \family sans
16674 Page
16675 \begin_inset space ~
16676 \end_inset
16677
16678 style
16679 \family default
16680  behaves a bit differently for this class.
16681  The possible choices and what they do are as follows:
16682 \begin_inset Separator parbreak
16683 \end_inset
16684
16685
16686 \end_layout
16687
16688 \begin_deeper
16689 \begin_layout Description
16690
16691 \family sans
16692 plain
16693 \family default
16694  The final output contains page numbers in the lower right corner.
16695 \end_layout
16696
16697 \begin_layout Description
16698
16699 \family sans
16700 headings
16701 \family default
16702  Like 
16703 \family sans
16704 plain
16705 \family default
16706 , but also prints out any time markers you've put in.
16707  This is the default.
16708 \end_layout
16709
16710 \begin_layout Description
16711
16712 \family sans
16713 empty
16714 \family default
16715  The final output contains no page numbers, time markers, or alignment markers.
16716 \end_layout
16717
16718 \end_deeper
16719 \begin_layout Itemize
16720 The 
16721 \family sans
16722 slides
16723 \family default
16724  class has an extra option: 
16725 \family typewriter
16726 clock
16727 \family default
16728 .
16729  To use it, put 
16730 \begin_inset Quotes eld
16731 \end_inset
16732
16733
16734 \family typewriter
16735 clock
16736 \family default
16737
16738 \begin_inset Quotes erd
16739 \end_inset
16740
16741  in the extra class options.
16742 \begin_inset Separator parbreak
16743 \end_inset
16744
16745
16746 \end_layout
16747
16748 \begin_deeper
16749 \begin_layout Standard
16750 Using this options allows you to add time markers to 
16751 \family sans
16752 Note
16753 \family default
16754 s.
16755  See section
16756 \begin_inset space ~
16757 \end_inset
16758
16759
16760 \begin_inset CommandInset ref
16761 LatexCommand ref
16762 reference "sec:slideNote"
16763
16764 \end_inset
16765
16766  for more details.
16767 \end_layout
16768
16769 \end_deeper
16770 \begin_layout Standard
16771 You can also use the template file 
16772 \begin_inset Quotes eld
16773 \end_inset
16774
16775
16776 \family typewriter
16777 slides.lyx
16778 \family default
16779
16780 \begin_inset Quotes erd
16781 \end_inset
16782
16783  to automatically set up a document to use the 
16784 \family sans
16785 slides
16786 \family default
16787  class [using 
16788 \family sans
16789 File\SpecialChar menuseparator
16790 New
16791 \begin_inset space ~
16792 \end_inset
16793
16794 from
16795 \begin_inset space ~
16796 \end_inset
16797
16798 Template
16799 \family default
16800  to open your new document].
16801  The template file also contains some examples of the special paragraph
16802  environments used by this class.
16803  I'll describe those next.
16804 \end_layout
16805
16806 \begin_layout Subsection
16807 Paragraph Environments
16808 \end_layout
16809
16810 \begin_layout Subsubsection
16811 Supported Environments
16812 \end_layout
16813
16814 \begin_layout Standard
16815 The first thing you'll notice when you start up a new 
16816 \family sans
16817 slides
16818 \family default
16819  document is the font size and type: it's the equivalent of the size 
16820 \begin_inset Quotes eld
16821 \end_inset
16822
16823
16824 \family sans
16825 Largest
16826 \family default
16827
16828 \begin_inset Quotes erd
16829 \end_inset
16830
16831  in the 
16832 \family sans
16833 Sans
16834 \begin_inset space ~
16835 \end_inset
16836
16837 Serif
16838 \family default
16839  font.
16840  This is also what's used in the output.
16841  Think of this as a 
16842 \begin_inset Quotes eld
16843 \end_inset
16844
16845 visual cue
16846 \begin_inset Quotes erd
16847 \end_inset
16848
16849  to remind you that this is a slide.
16850  Your final slides will use a larger font; ergo, you'll have less space.
16851  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
16852 \end_layout
16853
16854 \begin_layout Standard
16855 The next thing that becomes obvious is the changes to the paragraph environment
16856  pull-down box [at the far-left end of the toolbar].
16857  Most of the paragraph environments you're used to seeing are missing.
16858  There are also five new ones.
16859  That's because the 
16860 \family sans
16861 slides
16862 \family default
16863  class itself only supports certain paragraph environments:
16864 \end_layout
16865
16866 \begin_layout Itemize
16867
16868 \family sans
16869 Standard
16870 \end_layout
16871
16872 \begin_layout Itemize
16873
16874 \family sans
16875 Itemize
16876 \end_layout
16877
16878 \begin_layout Itemize
16879
16880 \family sans
16881 Enumerate
16882 \end_layout
16883
16884 \begin_layout Itemize
16885
16886 \family sans
16887 Description
16888 \end_layout
16889
16890 \begin_layout Itemize
16891
16892 \family sans
16893 List
16894 \end_layout
16895
16896 \begin_layout Itemize
16897
16898 \family sans
16899 Quotation
16900 \end_layout
16901
16902 \begin_layout Itemize
16903
16904 \family sans
16905 Quote
16906 \end_layout
16907
16908 \begin_layout Itemize
16909
16910 \family sans
16911 Verse
16912 \end_layout
16913
16914 \begin_layout Itemize
16915
16916 \family sans
16917 Caption
16918 \end_layout
16919
16920 \begin_layout Itemize
16921
16922 \family sans
16923 \SpecialChar LyX
16924 -Code
16925 \end_layout
16926
16927 \begin_layout Itemize
16928
16929 \family sans
16930 Comment
16931 \end_layout
16932
16933 \begin_layout Standard
16934 All of the other standard environments, including the section-heading environmen
16935 ts, aren't used in the 
16936 \family sans
16937 slides
16938 \family default
16939  class.
16940 \end_layout
16941
16942 \begin_layout Standard
16943 On the other hand, you'll notice the following new environments:
16944 \end_layout
16945
16946 \begin_layout Itemize
16947
16948 \family sans
16949 Slide
16950 \end_layout
16951
16952 \begin_layout Itemize
16953
16954 \family sans
16955 Overlay
16956 \end_layout
16957
16958 \begin_layout Itemize
16959
16960 \family sans
16961 Note
16962 \end_layout
16963
16964 \begin_layout Itemize
16965
16966 \family sans
16967 InvisibleText
16968 \end_layout
16969
16970 \begin_layout Itemize
16971
16972 \family sans
16973 VisibleText
16974 \end_layout
16975
16976 \begin_layout Standard
16977 These five are kind of quirky, due to a 
16978 \begin_inset Quotes eld
16979 \end_inset
16980
16981 feature
16982 \begin_inset Quotes erd
16983 \end_inset
16984
16985  in \SpecialChar LyX
16986 .
16987  You see, \SpecialChar LyX
16988  doesn't permit you to nest any other paragraph environment into
16989  an empty environment.
16990  Now, that's fine and dandy, but it means that you wouldn't be able to start
16991  a slide with anything except plain text.
16992  To deal with this, I've performed a little 
16993 \begin_inset Quotes eld
16994 \end_inset
16995
16996 \SpecialChar LaTeX
16997  magic.
16998 \begin_inset Quotes erd
16999 \end_inset
17000
17001  
17002 \end_layout
17003
17004 \begin_layout Subsubsection
17005 Quirks of the New Environments
17006 \begin_inset CommandInset label
17007 LatexCommand label
17008 name "sec:slideQuirk"
17009
17010 \end_inset
17011
17012
17013 \end_layout
17014
17015 \begin_layout Standard
17016 All five of the new paragraph environments are somewhat quirky due to inherent
17017  limitiations in the current version of \SpecialChar LyX
17018 .
17019  As I just mentioned, \SpecialChar LyX
17020  forbids environments that begin with another environment.
17021  To get around this, the 
17022 \family sans
17023 Slide
17024 \family default
17025  environment isn't a paragraph environment as described in the 
17026 \emph on
17027 User's Guide
17028 \emph default
17029 .
17030  
17031 \end_layout
17032
17033 \begin_layout Standard
17034 You should consider 
17035 \family sans
17036 Slide
17037 \family default
17038
17039 \family sans
17040 Overlay
17041 \family default
17042 , and 
17043 \family sans
17044 Note
17045 \family default
17046  to be 
17047 \begin_inset Quotes eld
17048 \end_inset
17049
17050 pseudo-environments.
17051 \begin_inset Quotes erd
17052 \end_inset
17053
17054  They look like a section heading or a 
17055 \begin_inset Quotes eld
17056 \end_inset
17057
17058
17059 \family sans
17060 Caption
17061 \family default
17062 ,
17063 \begin_inset Quotes erd
17064 \end_inset
17065
17066  but really begin a [and, if necessary, end the previous] paragraph environment.
17067  Likewise, treat 
17068 \family sans
17069 InvisibleText
17070 \family default
17071  and 
17072 \family sans
17073 VisibleText
17074 \family default
17075  as 
17076 \begin_inset Quotes eld
17077 \end_inset
17078
17079 pseudo-commands.
17080 \begin_inset Quotes erd
17081 \end_inset
17082
17083  These two perform some action.
17084 \end_layout
17085
17086 \begin_layout Standard
17087 A common feature of all five environments, 
17088 \family sans
17089 Slide
17090 \family default
17091
17092 \family sans
17093 Overlay
17094 \family default
17095
17096 \family sans
17097 Note
17098 \family default
17099
17100 \family sans
17101 InvisibleText
17102 \family default
17103  and 
17104 \family sans
17105 VisibleText
17106 \family default
17107 , is a rather long-ish label.
17108  The text following this label — ordinarily the contents of the paragraph
17109  environment — is utterly irrelevant for 
17110 \family sans
17111 Slide
17112 \family default
17113
17114 \family sans
17115 Overlay
17116 \family default
17117
17118 \family sans
17119 Note
17120 \family default
17121
17122 \family sans
17123 InvisibleText
17124 \family default
17125  and 
17126 \family sans
17127 VisibleText
17128 \family default
17129 .
17130  \SpecialChar LyX
17131  completely ignores it.
17132  In fact, you can leave these five environments completely empty.
17133  
17134 \end_layout
17135
17136 \begin_layout Standard
17137 While you don't 
17138 \emph on
17139 have
17140 \emph default
17141  to put any text after the rather long-ish label, you might want to.
17142  This could be a short description of the contents of the 
17143 \family sans
17144 Slide
17145 \family default
17146 , for example.
17147  In that case, enter your descriptive comment and hit 
17148 \family sans
17149 Return
17150 \family default
17151  as you normally would.
17152 \end_layout
17153
17154 \begin_layout Standard
17155 If, on the other hand, you don't want to enter any descriptive text, you'll
17156  hit another \SpecialChar LyX
17157  quirk.
17158  \SpecialChar LyX
17159 , like nature, abhors a vacuum, and will not let you start a new paragraph
17160  environment until you put something in the old one.
17161  So, do this:
17162 \end_layout
17163
17164 \begin_layout Itemize
17165 Start entering the text that will 
17166 \emph on
17167 follow
17168 \emph default
17169  the new 
17170 \family sans
17171 Slide
17172 \family default
17173
17174 \family sans
17175 Overlay
17176 \family default
17177
17178 \family sans
17179 Note
17180 \family default
17181
17182 \family sans
17183 InvisibleText
17184 \family default
17185  or 
17186 \family sans
17187 VisibleText
17188 \family default
17189 .
17190  
17191 \end_layout
17192
17193 \begin_layout Itemize
17194 Now move to the beginning of that paragraph.
17195  
17196 \end_layout
17197
17198 \begin_layout Itemize
17199 Next, hit 
17200 \family sans
17201 Return
17202 \family default
17203 .
17204  
17205 \end_layout
17206
17207 \begin_layout Itemize
17208 Finally, change this new, empty paragraph to a 
17209 \family sans
17210 Slide
17211 \family default
17212
17213 \family sans
17214 Overlay
17215 \family default
17216
17217 \family sans
17218 Note
17219 \family default
17220
17221 \family sans
17222 InvisibleText
17223 \family default
17224  or 
17225 \family sans
17226 VisibleText
17227 \family default
17228 .
17229  
17230 \end_layout
17231
17232 \begin_layout Standard
17233 Some future version of \SpecialChar LyX
17234  will, hopefully, resolve this quirkiness\SpecialChar ldots
17235
17236 \end_layout
17237
17238 \begin_layout Subsection
17239 Making a Presentation with 
17240 \family sans
17241 Slide
17242 \family default
17243
17244 \family sans
17245 Overlay
17246 \family default
17247  and 
17248 \family sans
17249 Note
17250 \end_layout
17251
17252 \begin_layout Subsubsection
17253 Using the 
17254 \family sans
17255 Slide
17256 \family default
17257  Environment
17258 \end_layout
17259
17260 \begin_layout Standard
17261 If you're expecting this section to teach you how to actually make a presentatio
17262 n, you'll be sorely disappointed.
17263  Naturally, I'll describe all of the ways the 
17264 \family sans
17265 slides
17266 \family default
17267  class can assist you in preparing the materials for a presentation.
17268  Filling in the contents, however, is up to you.
17269  [Then again, that 
17270 \emph on
17271 is
17272 \emph default
17273  the \SpecialChar LyX
17274  philosophy.]
17275 \end_layout
17276
17277 \begin_layout Standard
17278 Choosing the 
17279 \family sans
17280 Slide
17281 \family default
17282  environment [in the manner described in section
17283 \begin_inset space ~
17284 \end_inset
17285
17286
17287 \begin_inset CommandInset ref
17288 LatexCommand ref
17289 reference "sec:slideQuirk"
17290
17291 \end_inset
17292
17293 ] tells \SpecialChar LyX
17294  to begin a new slide [duh].
17295  The label for this environment/
17296 \begin_inset Quotes erd
17297 \end_inset
17298
17299 pseudo-command
17300 \begin_inset Quotes erd
17301 \end_inset
17302
17303  is an 
17304 \begin_inset Quotes eld
17305 \end_inset
17306
17307 ASCII line,
17308 \begin_inset Quotes erd
17309 \end_inset
17310
17311  in cool blue, followed by the label, 
17312 \begin_inset Quotes eld
17313 \end_inset
17314
17315 NewSlide:
17316 \begin_inset Quotes erd
17317 \end_inset
17318
17319 .
17320  Any text or paragraph environments that follow this one go on the new slide.
17321  It's that simple.
17322 \end_layout
17323
17324 \begin_layout Standard
17325 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
17326
17327  (this can be specified in the 
17328 \family sans
17329 Paragraph Layout
17330 \family default
17331  dialog).
17332  In fact, you'll want to, once you finish entering the contents of one slide.
17333  If you've entered more text than can physically fit on a slide, the extra
17334  overflows onto a new slide.
17335  I don't recommend doing this, however, since the overflow slide won't have
17336  any page number on it.
17337  Furthermore, it may interfere with any 
17338 \family sans
17339 Overlay
17340 \family default
17341  you've made to accompany the oversized 
17342 \family sans
17343 Slide
17344 \family default
17345 .
17346 \end_layout
17347
17348 \begin_layout Standard
17349 The 
17350 \family sans
17351 Overlay
17352 \family default
17353  and 
17354 \family sans
17355 Note
17356 \family default
17357  environments work the same way as the 
17358 \family sans
17359 Slide
17360 \family default
17361  environment.
17362  They both create an 
17363 \begin_inset Quotes eld
17364 \end_inset
17365
17366 ASCII line
17367 \begin_inset Quotes erd
17368 \end_inset
17369
17370  followed by a label [
17371 \begin_inset Quotes eld
17372 \end_inset
17373
17374 NewOverlay:
17375 \begin_inset Quotes erd
17376 \end_inset
17377
17378  and 
17379 \begin_inset Quotes eld
17380 \end_inset
17381
17382 NewNote:
17383 \begin_inset Quotes erd
17384 \end_inset
17385
17386 , respectively].
17387  The color is a stunning magenta instead of blue, and the 
17388 \begin_inset Quotes eld
17389 \end_inset
17390
17391 ASCII line
17392 \begin_inset Quotes erd
17393 \end_inset
17394
17395  will look different, in style and in length.
17396  The label fonts of all three also differ from one another.
17397 \end_layout
17398
17399 \begin_layout Standard
17400 As with a 
17401 \family sans
17402 Slide
17403 \family default
17404 , if the contents of a 
17405 \family sans
17406 Note
17407 \family default
17408  or 
17409 \family sans
17410 Overlay
17411 \family default
17412  exceed the physical size of a slide or sheet of paper, the extra will overflow
17413  onto a new sheet.
17414  Again, you should avoid this.
17415  It defeats the whole purpose of 
17416 \family sans
17417 Note
17418 \family default
17419 s and 
17420 \family sans
17421 Overlay
17422 \family default
17423 s.
17424 \end_layout
17425
17426 \begin_layout Subsubsection
17427 Using 
17428 \family sans
17429 Overlay
17430 \family default
17431  with 
17432 \family sans
17433 Slide
17434 \end_layout
17435
17436 \begin_layout Standard
17437 The idea behind an 
17438 \family sans
17439 Overlay
17440 \family default
17441  is a slide that sits atop another slide.
17442  Perhaps you wish to discuss a figure on the main 
17443 \family sans
17444 Slide
17445 \family default
17446  before displaying the text associated with it.
17447  One way to accomplish this is tape a flap of dark paper over the part of
17448  the 
17449 \family sans
17450 Slide
17451 \family default
17452  you want to display later.
17453  This method fails, however, if you wish to overlap one graph with another,
17454  for example.
17455  You would then have to fumble while speaking to align the two separate,
17456  overlapping 
17457 \family sans
17458 Slide
17459 \family default
17460 s to align the two graphs.
17461  The use of an 
17462 \family sans
17463 Overlay
17464 \family default
17465  environment in both cases makes life much easier.
17466 \end_layout
17467
17468 \begin_layout Standard
17469 Each 
17470 \family sans
17471 Overlay
17472 \family default
17473  receives the page number of its 
17474 \begin_inset Quotes eld
17475 \end_inset
17476
17477 parent
17478 \begin_inset Quotes erd
17479 \end_inset
17480
17481  
17482 \family sans
17483 Slide
17484 \family default
17485 , appended by 
17486 \begin_inset Quotes eld
17487 \end_inset
17488
17489
17490 \family typewriter
17491 -a
17492 \family default
17493
17494 \begin_inset Quotes erd
17495 \end_inset
17496
17497 .
17498 \begin_inset Foot
17499 status collapsed
17500
17501 \begin_layout Plain Layout
17502 Presumably, mutliple 
17503 \family sans
17504 Overlay
17505 \family default
17506 s would have 
17507 \begin_inset Quotes eld
17508 \end_inset
17509
17510
17511 \family typewriter
17512 -a
17513 \family default
17514
17515 \begin_inset Quotes erd
17516 \end_inset
17517
17518
17519 \begin_inset Quotes eld
17520 \end_inset
17521
17522
17523 \family typewriter
17524 -b
17525 \family default
17526
17527 \begin_inset Quotes erd
17528 \end_inset
17529
17530
17531 \begin_inset Quotes eld
17532 \end_inset
17533
17534
17535 \family typewriter
17536 -c
17537 \family default
17538
17539 \begin_inset Quotes erd
17540 \end_inset
17541
17542 , etc.
17543 \begin_inset space ~
17544 \end_inset
17545
17546 appended to the page number of the parent 
17547 \family sans
17548 Slide
17549 \family default
17550 .
17551  
17552 \end_layout
17553
17554 \end_inset
17555
17556  Clearly, you want the contents of both the 
17557 \family sans
17558 Slide
17559 \family default
17560  and the 
17561 \family sans
17562 Overlay
17563 \family default
17564  to each fit on a single physical slide! You should probably consider an
17565  
17566 \family sans
17567 Overlay
17568 \family default
17569  as 
17570 \begin_inset Quotes eld
17571 \end_inset
17572
17573 part of
17574 \begin_inset Quotes erd
17575 \end_inset
17576
17577  a 
17578 \family sans
17579 Slide
17580 \family default
17581 .
17582  Indeed, the \SpecialChar LyX
17583  
17584 \family sans
17585 slides
17586 \family default
17587  class provides a visual cue for this: the label at the start of an 
17588 \family sans
17589 Overlay
17590 \family default
17591  is shorter than that at the start of a 
17592 \family sans
17593 Slide
17594 \family default
17595 .
17596  Lastly, when you generate printable output, you'll find alignment markers
17597  in all four corners of both the 
17598 \family sans
17599 Overlay
17600 \family default
17601  page and its parent 
17602 \family sans
17603 Slide
17604 \family default
17605 .
17606  These will assist you in lining up the two physical slides.
17607 \end_layout
17608
17609 \begin_layout Standard
17610 The major problem in overlaying two slides is aligning the contents of the
17611  two transparencies.
17612  How much space should you leave for that graph on the second slide? Worse
17613  still, what if you want a graph and a sentence on second slide, but there
17614  is text on the main transparency that goes in between them? You could try
17615  and insert vertical space of the right size.
17616  The better way is to use 
17617 \family sans
17618 InvisibleText
17619 \family default
17620  and 
17621 \family sans
17622 VisibleText
17623 \family default
17624 .
17625 \end_layout
17626
17627 \begin_layout Standard
17628 As their names imply, 
17629 \family sans
17630 InvisibleText
17631 \family default
17632  and 
17633 \family sans
17634 VisibleText
17635 \family default
17636  are two command-like paragraph environments that make all subsequent text
17637  invisible and visible, respectively.
17638  Note from section
17639 \begin_inset space ~
17640 \end_inset
17641
17642
17643 \begin_inset CommandInset ref
17644 LatexCommand ref
17645 reference "sec:slideQuirk"
17646
17647 \end_inset
17648
17649  that you don't place anything 
17650 \emph on
17651 into
17652 \emph default
17653  these two environments, however.
17654  When you create an 
17655 \family sans
17656 InvisibleText
17657 \family default
17658 , it inserts a centered, sky-blue label into the page reading 
17659 \begin_inset Quotes eld
17660 \end_inset
17661
17662 <Invisible Text Follows>
17663 \begin_inset Quotes erd
17664 \end_inset
17665
17666 .
17667  For paragraphs following this label, the parts of the 
17668 \family sans
17669 Slide
17670 \family default
17671  [or 
17672 \family sans
17673 Overlay
17674 \family default
17675 ; it doesn't matter which] where they would be contain instead blank space.
17676  
17677 \end_layout
17678
17679 \begin_layout Standard
17680 For 
17681 \family sans
17682 VisibleText
17683 \family default
17684 , the corresponding centered label is 
17685 \begin_inset Quotes eld
17686 \end_inset
17687
17688 <Visible Text Follows>
17689 \begin_inset Quotes erd
17690 \end_inset
17691
17692  in blazing green.
17693  Paragraphs following this label behave normally.
17694  Note that the beginning of a new 
17695 \family sans
17696 Slide
17697 \family default
17698
17699 \family sans
17700 Overlay
17701 \family default
17702 , or 
17703 \family sans
17704 Note
17705 \family default
17706  automatically shuts off an 
17707 \family sans
17708 InvisibleText
17709 \family default
17710 .
17711  It's therefore not necessary to use 
17712 \family sans
17713 VisibleText
17714 \family default
17715  at the end of a 
17716 \family sans
17717 Slide
17718 \family default
17719 .
17720 \end_layout
17721
17722 \begin_layout Standard
17723 By now, it should be obvious how to create overlay transparencies using
17724  the proper combination of 
17725 \family sans
17726 InvisibleText
17727 \family default
17728  and 
17729 \family sans
17730 VisibleText
17731 \family default
17732  on a 
17733 \family sans
17734 Slide
17735 \family default
17736  and 
17737 \family sans
17738 Overlay
17739 \family default
17740 :
17741 \end_layout
17742
17743 \begin_layout Enumerate
17744 Create a 
17745 \family sans
17746 Slide
17747 \family default
17748 , including everything that will appear on it, whether on the main slide
17749  or on the 
17750 \family sans
17751 Overlay
17752 \family default
17753 .
17754 \end_layout
17755
17756 \begin_layout Enumerate
17757 Before each figure or paragraph that will appear only on the 
17758 \family sans
17759 Overlay
17760 \family default
17761 , insert an 
17762 \family sans
17763 InvisibleText
17764 \family default
17765  environment.
17766  If necessary, insert a 
17767 \family sans
17768 VisibleText
17769 \family default
17770  environment after the 
17771 \family sans
17772 Overlay
17773 \family default
17774 -only text.
17775 \end_layout
17776
17777 \begin_layout Enumerate
17778 Start an 
17779 \family sans
17780 Overlay
17781 \family default
17782  immediately following the 
17783 \family sans
17784 Slide
17785 \family default
17786 .
17787 \end_layout
17788
17789 \begin_layout Enumerate
17790 Copy the contents of this 
17791 \family sans
17792 Slide
17793 \family default
17794  into the 
17795 \family sans
17796 Overlay
17797 \family default
17798 .
17799 \end_layout
17800
17801 \begin_layout Enumerate
17802 Within the 
17803 \family sans
17804 Overlay
17805 \family default
17806 , change all of the 
17807 \family sans
17808 InvisibleText
17809 \family default
17810  lines to 
17811 \family sans
17812 VisibleText
17813 \family default
17814  and vice-versa.
17815 \end_layout
17816
17817 \begin_layout Standard
17818 That's it.
17819  You've just made an 
17820 \family sans
17821 Overlay
17822 \family default
17823 .
17824 \end_layout
17825
17826 \begin_layout Standard
17827 There's one problem with the way I've designed the \SpecialChar LyX
17828  
17829 \family sans
17830 slides
17831 \family default
17832  class: you can't make text in the middle of a paragraph invisible, nor
17833  make text in the middle of an invisible paragraph visible again.
17834  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
17835  codes.
17836 \begin_inset Foot
17837 status collapsed
17838
17839 \begin_layout Plain Layout
17840 The commands of interest are: 
17841 \end_layout
17842
17843 \begin_layout Itemize
17844
17845 \family typewriter
17846 {
17847 \backslash
17848 invisible \SpecialChar ldots
17849  }
17850 \end_layout
17851
17852 \begin_layout Itemize
17853
17854 \family typewriter
17855 {
17856 \backslash
17857 visible \SpecialChar ldots
17858  }
17859 \end_layout
17860
17861 \begin_layout Plain Layout
17862 \SpecialChar ldots
17863 and need to be marked as \SpecialChar TeX
17864 .
17865  The text whose 
17866 \begin_inset Quotes eld
17867 \end_inset
17868
17869 visibility
17870 \begin_inset Quotes erd
17871 \end_inset
17872
17873  you wish to change goes in between the brackets [and after the 
17874 \family typewriter
17875
17876 \backslash
17877 invisible
17878 \family default
17879  or 
17880 \family typewriter
17881
17882 \backslash
17883 visible
17884 \family default
17885  command].
17886  If you don't know how to mark text as \SpecialChar TeX
17887 , see the appropriate section of
17888  the 
17889 \emph on
17890 User's Guide
17891 \emph default
17892 .
17893 \end_layout
17894
17895 \end_inset
17896
17897
17898 \end_layout
17899
17900 \begin_layout Subsubsection
17901 Using 
17902 \family sans
17903 Note
17904 \family default
17905  with 
17906 \family sans
17907 Slide
17908 \family default
17909
17910 \begin_inset CommandInset label
17911 LatexCommand label
17912 name "sec:slideNote"
17913
17914 \end_inset
17915
17916
17917 \end_layout
17918
17919 \begin_layout Standard
17920 Like an 
17921 \family sans
17922 Overlay
17923 \family default
17924 , a 
17925 \family sans
17926 Note
17927 \family default
17928  is associated with a 
17929 \begin_inset Quotes eld
17930 \end_inset
17931
17932 parent
17933 \begin_inset Quotes erd
17934 \end_inset
17935
17936  
17937 \family sans
17938 Slide
17939 \family default
17940 .
17941  Here, too, the \SpecialChar LyX
17942  
17943 \family sans
17944 slides
17945 \family default
17946  class provides visual cues.
17947  The label for a 
17948 \family sans
17949 Note
17950 \family default
17951  is shorter than that of a 
17952 \family sans
17953 Slide
17954 \family default
17955  [yet longer than that of an 
17956 \family sans
17957 Overlay
17958 \family default
17959 ] and, like the label of an 
17960 \family sans
17961 Overlay
17962 \family default
17963  is shockingly magenta.
17964  Additionally, the printed 
17965 \family sans
17966 Note
17967 \family default
17968  has the page number of its 
17969 \begin_inset Quotes eld
17970 \end_inset
17971
17972 parent
17973 \begin_inset Quotes erd
17974 \end_inset
17975
17976  
17977 \family sans
17978 Slide
17979 \family default
17980 , appended by 
17981 \begin_inset Quotes eld
17982 \end_inset
17983
17984
17985 \family typewriter
17986 -
17987 \family default
17988 1
17989 \begin_inset Quotes erd
17990 \end_inset
17991
17992
17993 \begin_inset Quotes eld
17994 \end_inset
17995
17996
17997 \family typewriter
17998 -
17999 \family default
18000 2
18001 \begin_inset Quotes erd
18002 \end_inset
18003
18004
18005 \begin_inset Quotes eld
18006 \end_inset
18007
18008
18009 \family typewriter
18010 -
18011 \family default
18012 3
18013 \begin_inset Quotes erd
18014 \end_inset
18015
18016 , etc.
18017  You can have multiple 
18018 \family sans
18019 Note
18020 \family default
18021 s associated with a single 
18022 \family sans
18023 Slide
18024 \family default
18025 , and, as with 
18026 \family sans
18027 Slide
18028 \family default
18029  and 
18030 \family sans
18031 Overlay
18032 \family default
18033 , you'll probably want to break up long 
18034 \family sans
18035 Note
18036 \family default
18037 s so that they fit on a single sheet of paper.
18038 \end_layout
18039
18040 \begin_layout Standard
18041 The purpose of a 
18042 \family sans
18043 Note
18044 \family default
18045  is obvious: it contains anything additional you might want to say about
18046  a 
18047 \family sans
18048 Slide
18049 \family default
18050 .
18051  It could also be used as a sheet of reminders for a particular 
18052 \family sans
18053 Slide
18054 \family default
18055 .
18056  In the case of the latter, you might want to make use of time markers.
18057  Currently, the \SpecialChar LyX
18058  
18059 \family sans
18060 slides
18061 \family default
18062  class has no 
18063 \begin_inset Quotes eld
18064 \end_inset
18065
18066 native
18067 \begin_inset Quotes erd
18068 \end_inset
18069
18070  support for time markers, a 
18071 \noun on
18072 Sli\SpecialChar TeX
18073
18074 \noun default
18075  feature.
18076  So, you'll have to resort to using the \SpecialChar LaTeX
18077  codes.
18078 \end_layout
18079
18080 \begin_layout Standard
18081 To use time markers, you'll need to specify the extra class option 
18082 \begin_inset Quotes eld
18083 \end_inset
18084
18085
18086 \family typewriter
18087 clock
18088 \family default
18089
18090 \begin_inset Quotes erd
18091 \end_inset
18092
18093  [see section
18094 \begin_inset space ~
18095 \end_inset
18096
18097
18098 \begin_inset CommandInset ref
18099 LatexCommand ref
18100 reference "sec:slidesetup"
18101
18102 \end_inset
18103
18104 ].
18105  This option turns on timing marks, which will appear in the lower-left-hand
18106  corner of every 
18107 \family sans
18108 Note
18109 \family default
18110  you generate.
18111  To set what appears in the time marker, you use the \SpecialChar LaTeX
18112  commands 
18113 \begin_inset Quotes eld
18114 \end_inset
18115
18116
18117 \family typewriter
18118
18119 \backslash
18120 settime{}
18121 \family default
18122
18123 \begin_inset Quotes erd
18124 \end_inset
18125
18126  and 
18127 \begin_inset Quotes eld
18128 \end_inset
18129
18130
18131 \family typewriter
18132
18133 \backslash
18134 addtime{}
18135 \family default
18136
18137 \begin_inset Quotes erd
18138 \end_inset
18139
18140 .
18141  The arguments of both commands are time measured in seconds.
18142  
18143 \begin_inset Quotes eld
18144 \end_inset
18145
18146
18147 \family typewriter
18148
18149 \backslash
18150 settime{}
18151 \family default
18152
18153 \begin_inset Quotes erd
18154 \end_inset
18155
18156  sets the time marker to a given time.
18157  
18158 \begin_inset Quotes eld
18159 \end_inset
18160
18161
18162 \family typewriter
18163
18164 \backslash
18165 addtime{}
18166 \family default
18167
18168 \begin_inset Quotes erd
18169 \end_inset
18170
18171  increments the time marker by the specified amount.
18172  Using time markers and 
18173 \family sans
18174 Note
18175 \family default
18176 s in this fashion, you can remind yourself how much time to spend on a particula
18177
18178 \family sans
18179 Slide
18180 \family default
18181 .
18182 \end_layout
18183
18184 \begin_layout Standard
18185 There's one last feature to describe.
18186  Clearly, you'd like to print out all of your 
18187 \family sans
18188 Slide
18189 \family default
18190 s and 
18191 \family sans
18192 Overlay
18193 \family default
18194 s on transparencies while printing all of your 
18195 \family sans
18196 Note
18197 \family default
18198 s on plain paper.
18199  However, a 
18200 \family sans
18201 Note
18202 \family default
18203  
18204 \emph on
18205 must
18206 \emph default
18207  follow the 
18208 \family sans
18209 Slide
18210 \family default
18211  with which it is associated.
18212  What's a person to do?
18213 \end_layout
18214
18215 \begin_layout Standard
18216 Luckily, there are two \SpecialChar LaTeX
18217  commands that allow you to select what to print
18218  out.
18219  Both must be placed into the preamble of your document.
18220  The command 
18221 \begin_inset Quotes eld
18222 \end_inset
18223
18224
18225 \family typewriter
18226
18227 \backslash
18228 onlyslides{
18229 \backslash
18230 slides}
18231 \family default
18232
18233 \begin_inset Quotes erd
18234 \end_inset
18235
18236  will cause the output to contain only the 
18237 \family sans
18238 Slide
18239 \family default
18240 s and 
18241 \family sans
18242 Overlay
18243 \family default
18244 s.
18245  Correspondingly, the command 
18246 \begin_inset Quotes eld
18247 \end_inset
18248
18249
18250 \family typewriter
18251
18252 \backslash
18253 onlynotes{
18254 \backslash
18255 notes}
18256 \family default
18257
18258 \begin_inset Quotes erd
18259 \end_inset
18260
18261  prevents the output of anything but 
18262 \family sans
18263 Note
18264 \family default
18265 s.
18266  I'd advise placing both commands in the preamble and initially comment
18267  both out.
18268  You can then preview your entire presentation as you write.
18269  When you're done writing, you can then uncomment one of the two to select
18270  what you want to print.
18271  I like to uncomment 
18272 \begin_inset Quotes eld
18273 \end_inset
18274
18275
18276 \family typewriter
18277
18278 \backslash
18279 onlyslides{
18280 \backslash
18281 slides}
18282 \family default
18283
18284 \begin_inset Quotes erd
18285 \end_inset
18286
18287  , print to a file with 
18288 \begin_inset Quotes eld
18289 \end_inset
18290
18291
18292 \family typewriter
18293 -slides
18294 \family default
18295
18296 \begin_inset Quotes erd
18297 \end_inset
18298
18299  in its name, comment it back out, then uncomment 
18300 \begin_inset Quotes eld
18301 \end_inset
18302
18303
18304 \family typewriter
18305
18306 \backslash
18307 onlynotes{
18308 \backslash
18309 notes}
18310 \family default
18311
18312 \begin_inset Quotes erd
18313 \end_inset
18314
18315  and print to a 
18316 \begin_inset Quotes eld
18317 \end_inset
18318
18319
18320 \family typewriter
18321 *-notes.ps
18322 \family default
18323
18324 \begin_inset Quotes erd
18325 \end_inset
18326
18327  file.
18328  I can then send either file to a printer, loading transparencies or plain
18329  paper as appropriate.
18330 \end_layout
18331
18332 \begin_layout Standard
18333 You can also provide other arguments to the 
18334 \begin_inset Quotes eld
18335 \end_inset
18336
18337
18338 \family typewriter
18339
18340 \backslash
18341 onlyslides{}
18342 \family default
18343
18344 \begin_inset Quotes erd
18345 \end_inset
18346
18347  and 
18348 \begin_inset Quotes eld
18349 \end_inset
18350
18351
18352 \family typewriter
18353
18354 \backslash
18355 onlynotes{}
18356 \family default
18357
18358 \begin_inset Quotes erd
18359 \end_inset
18360
18361  commands.
18362  See a good \SpecialChar LaTeX
18363  book for details.
18364 \end_layout
18365
18366 \begin_layout Subsection
18367 The 
18368 \family sans
18369 slides
18370 \family default
18371  Class Template File
18372 \end_layout
18373
18374 \begin_layout Standard
18375 I have also provided a template file, 
18376 \begin_inset Quotes eld
18377 \end_inset
18378
18379
18380 \family typewriter
18381 slides.lyx
18382 \family default
18383
18384 \begin_inset Quotes erd
18385 \end_inset
18386
18387 , with the 
18388 \family sans
18389 slides
18390 \family default
18391  class.
18392  To use it, begin your new presentation with 
18393 \family sans
18394 \bar under
18395 F
18396 \bar default
18397 ile\SpecialChar menuseparator
18398 New
18399 \begin_inset space ~
18400 \end_inset
18401
18402 from
18403 \begin_inset space ~
18404 \end_inset
18405
18406
18407 \bar under
18408 T
18409 \bar default
18410 emplate
18411 \family default
18412 .
18413  Your new \SpecialChar LyX
18414  presentation file will contain an example 
18415 \family sans
18416 Slide
18417 \family default
18418  – 
18419 \family sans
18420 Overlay
18421 \family default
18422  – 
18423 \family sans
18424 Note
18425 \family default
18426  triplet.
18427  The 
18428 \family sans
18429 Slide
18430 \family default
18431  and 
18432 \family sans
18433 Overlay
18434 \family default
18435  additionally contain an example of the use of 
18436 \family sans
18437 InvisibleText
18438 \family default
18439  and 
18440 \family sans
18441 VisibleText
18442 \family default
18443 .
18444  Lastly, the preamble will contain:
18445 \end_layout
18446
18447 \begin_layout LyX-Code
18448 % Uncomment to print out only slides and overlays
18449 \end_layout
18450
18451 \begin_layout LyX-Code
18452 %
18453 \end_layout
18454
18455 \begin_layout LyX-Code
18456 %
18457 \backslash
18458 onlyslides{
18459 \backslash
18460 slides}
18461 \begin_inset Newline newline
18462 \end_inset
18463
18464  
18465 \end_layout
18466
18467 \begin_layout LyX-Code
18468 % Uncomment to print out only notes
18469 \end_layout
18470
18471 \begin_layout LyX-Code
18472 %
18473 \end_layout
18474
18475 \begin_layout LyX-Code
18476 %
18477 \backslash
18478 onlynotes{
18479 \backslash
18480 notes}
18481 \end_layout
18482
18483 \begin_layout Standard
18484 One final thing: I created this class to support the \SpecialChar LaTeX2e
18485  
18486 \begin_inset Quotes eld
18487 \end_inset
18488
18489
18490 \noun on
18491 Sli\SpecialChar TeX
18492
18493 \noun default
18494  emulation
18495 \begin_inset Quotes erd
18496 \end_inset
18497
18498  class, one of the built-in \SpecialChar LaTeX2e
18499  classes.
18500  Neither I nor the rest of the \SpecialChar LyX
18501  Team endorse or oppose the use of this built-in
18502  slide class.
18503  It's here if you want it or need it.
18504  There exist other \SpecialChar LaTeX2e
18505  classes for creating presentations, such as the 
18506 \family sans
18507 Foils
18508 \family default
18509  class [see section
18510 \begin_inset space ~
18511 \end_inset
18512
18513
18514 \begin_inset CommandInset ref
18515 LatexCommand ref
18516 reference "sec:foiltex"
18517
18518 \end_inset
18519
18520 ] or the 
18521 \begin_inset Quotes eld
18522 \end_inset
18523
18524
18525 \family typewriter
18526 seminar
18527 \family default
18528
18529 \begin_inset Quotes erd
18530 \end_inset
18531
18532  package [present on some \SpecialChar TeX
18533  distributions].
18534  The latter is not yet supported under \SpecialChar LyX
18535 .
18536 \begin_inset Foot
18537 status collapsed
18538
18539 \begin_layout Plain Layout
18540 Perhaps you can take on the task\SpecialChar ldots
18541
18542 \end_layout
18543
18544 \end_inset
18545
18546  I know nothing about these other classes.
18547  Try them out to see what sort of alternative they provide.
18548 \end_layout
18549
18550 \begin_layout Chapter
18551 \SpecialChar LyX
18552  Features needing Extra Software
18553 \end_layout
18554
18555 \begin_layout Section
18556 Checking \SpecialChar TeX
18557
18558 \end_layout
18559
18560 \begin_layout Standard
18561 by 
18562 \noun on
18563 Asger Alstrup
18564 \end_layout
18565
18566 \begin_layout Subsection
18567 Introduction
18568 \end_layout
18569
18570 \begin_layout Standard
18571 If you have the 
18572 \family typewriter
18573 chktex
18574 \family default
18575  program installed
18576 \begin_inset Foot
18577 status collapsed
18578
18579 \begin_layout Plain Layout
18580
18581 \family typewriter
18582 chktex
18583 \family default
18584  is not yet available when you are using the \SpecialChar LaTeX
18585  distribution MiK\SpecialChar TeX
18586 .
18587 \end_layout
18588
18589 \end_inset
18590
18591 , you'll find in the 
18592 \family sans
18593 Tools
18594 \family default
18595  menu the entry: 
18596 \family sans
18597 Check
18598 \begin_inset space ~
18599 \end_inset
18600
18601 TeX
18602 \family default
18603 .
18604  You can get 
18605 \family typewriter
18606 chktex
18607 \family default
18608  from CTAN,
18609 \begin_inset Newline newline
18610 \end_inset
18611
18612
18613 \begin_inset CommandInset href
18614 LatexCommand href
18615 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
18616
18617 \end_inset
18618
18619 .
18620 \end_layout
18621
18622 \begin_layout Standard
18623 The 
18624 \family sans
18625 Chk\SpecialChar TeX
18626
18627 \family default
18628  package is a program that was written by 
18629 \begin_inset Flex Noun
18630 status collapsed
18631
18632 \begin_layout Plain Layout
18633 Jens T.
18634 \begin_inset space ~
18635 \end_inset
18636
18637 Berger Thielemann
18638 \end_layout
18639
18640 \end_inset
18641
18642  in frustration because some constructs in \SpecialChar LaTeX
18643  are sometimes non-intuitive,
18644  and easy to forget.
18645  The program runs over your \SpecialChar LaTeX
18646  file, checks the integrity of the file, and
18647  flags some common errors.
18648  In other technical words, it is 
18649 \family typewriter
18650 lint
18651 \family default
18652  for \SpecialChar LaTeX
18653 .
18654 \end_layout
18655
18656 \begin_layout Standard
18657 Well, what is a syntax checker doing in \SpecialChar LyX
18658  which is supposed to produce correct
18659  \SpecialChar LaTeX
18660  anyways? The answer is simple: Just as 
18661 \family typewriter
18662 Lint
18663 \family default
18664  not only checks the 
18665 \emph on
18666 syntax
18667 \emph default
18668  of C programs, but also does 
18669 \emph on
18670 semantic
18671 \emph default
18672  checks for type-errors, 
18673 \family sans
18674 Chk\SpecialChar TeX
18675
18676 \family default
18677  catches some common 
18678 \emph on
18679 typographic
18680 \emph default
18681  errors, in addition to the syntactical ones.
18682  Specifically, 
18683 \family sans
18684 Chk\SpecialChar TeX
18685
18686 \family default
18687  is capable of detecting several common errors, such as
18688 \end_layout
18689
18690 \begin_layout Itemize
18691 Ellipsis detection:
18692 \begin_inset Newline newline
18693 \end_inset
18694
18695 Use \SpecialChar ldots
18696  instead of ...
18697 \end_layout
18698
18699 \begin_layout Itemize
18700 No space in front of/after parenthesis:
18701 \begin_inset Newline newline
18702 \end_inset
18703
18704 ( wrong spacing )
18705 \end_layout
18706
18707 \begin_layout Itemize
18708 Enforcement of normal space after common abbreviations:
18709 \begin_inset Newline newline
18710 \end_inset
18711
18712 e.
18713 \begin_inset space \thinspace{}
18714 \end_inset
18715
18716 g.
18717 \begin_inset space \space{}
18718 \end_inset
18719
18720 is too wide spacing.
18721 \end_layout
18722
18723 \begin_layout Itemize
18724 Enforcement of end-of-sentence space when the last sentence ends with a
18725  capital letter:
18726 \begin_inset Newline newline
18727 \end_inset
18728
18729 This is a TEST.
18730  And this is wrong spacing.
18731 \end_layout
18732
18733 \begin_layout Itemize
18734 Space in front of labels and similar commands:
18735 \begin_inset Newline newline
18736 \end_inset
18737
18738 The label should stick right up to the text to avoid falling to a wrong
18739  page.
18740  
18741 \begin_inset CommandInset label
18742 LatexCommand label
18743 name "sec:chktex"
18744
18745 \end_inset
18746
18747  
18748 \begin_inset Foot
18749 status collapsed
18750
18751 \begin_layout Plain Layout
18752 This footnote is in danger of falling off to a wrong page
18753 \end_layout
18754
18755 \end_inset
18756
18757  The label is separated too much.
18758 \end_layout
18759
18760 \begin_layout Itemize
18761 Space in front of references, instead of hard spaces:
18762 \begin_inset Newline newline
18763 \end_inset
18764
18765 If you have bad luck, the text will break right between the referenced text
18766  and reference number, and that's a pity.
18767  See section 
18768 \begin_inset CommandInset ref
18769 LatexCommand ref
18770 reference "sec:chktex"
18771
18772 \end_inset
18773
18774 .
18775 \end_layout
18776
18777 \begin_layout Itemize
18778 Use of 
18779 \begin_inset Quotes eld
18780 \end_inset
18781
18782 x
18783 \begin_inset Quotes erd
18784 \end_inset
18785
18786  instead of 
18787 \begin_inset Formula $\times$
18788 \end_inset
18789
18790  between numbers:
18791 \begin_inset Newline newline
18792 \end_inset
18793
18794 2x2 looks cheap compared to 
18795 \begin_inset Formula $2\times2$
18796 \end_inset
18797
18798 .
18799 \end_layout
18800
18801 \begin_layout Standard
18802 and more \SpecialChar ldots
18803  It is an invaluable tool when you are 
18804 \begin_inset Quotes eld
18805 \end_inset
18806
18807 finishing up
18808 \begin_inset Quotes erd
18809 \end_inset
18810
18811  your document before printing, and you should run it right after the obligatory
18812  spelling check, and before you go fine tuning the typesetting.
18813 \end_layout
18814
18815 \begin_layout Subsection
18816 How to use it
18817 \end_layout
18818
18819 \begin_layout Standard
18820 If you have the program installed, usage is as simple as choosing 
18821 \family sans
18822 Tools\SpecialChar menuseparator
18823 Check
18824 \begin_inset space ~
18825 \end_inset
18826
18827 TeX
18828 \family default
18829 .
18830  This will make \SpecialChar LyX
18831  generate a \SpecialChar LaTeX
18832  file of your document, start 
18833 \family sans
18834 Chk\SpecialChar TeX
18835
18836 \family default
18837  to check it, and then make \SpecialChar LyX
18838  insert 
18839 \begin_inset Quotes eld
18840 \end_inset
18841
18842 error boxes
18843 \begin_inset Quotes erd
18844 \end_inset
18845
18846  with the warnings from 
18847 \family sans
18848 Chk\SpecialChar TeX
18849
18850 \family default
18851 , if there were any.
18852  The warnings will be placed close to the point of the mistake, and you
18853  can quickly find them by using the 
18854 \family sans
18855 Navigate\SpecialChar menuseparator
18856 Error
18857 \family default
18858  menu item, or the shortcut key 
18859 \family sans
18860 C-g
18861 \family default
18862  from the default 
18863 \family typewriter
18864 cua
18865 \family default
18866  bind file.
18867  Open the error boxes by clicking on them with the mouse, or use the shortcut
18868  key 
18869 \family sans
18870 C-i
18871 \family default
18872  from 
18873 \family typewriter
18874 cua
18875 \family default
18876  bindings, or the corresponding 
18877 \family sans
18878 C-o
18879 \family default
18880  for the alternate 
18881 \family typewriter
18882 emacs
18883 \family default
18884  bind file.
18885  Read the warning and correct the mistake, if it is a mistake.
18886  If you have trouble understanding what the warning is about, you can safely
18887  ignore it.
18888  Remember that there is a hidden layer between the document on screen and
18889  the technical details in invoking 
18890 \family sans
18891 Chk\SpecialChar TeX
18892
18893 \family default
18894 , and this gap can make some warnings seem arcane or just plain silly.
18895 \end_layout
18896
18897 \begin_layout Standard
18898 This document is an excellent testing bed for the feature, and it should
18899  provide quite a few warnings for you to fiddle with.
18900  Since computers are only so smart, expect most of the warnings to be false
18901  alarms, though.
18902 \end_layout
18903
18904 \begin_layout Subsection
18905 How to fine tune it
18906 \end_layout
18907
18908 \begin_layout Standard
18909 Sometimes, you'll find that 
18910 \family sans
18911 Chk\SpecialChar TeX
18912
18913 \family default
18914  makes more noise than suits your mood.
18915  Then you can choose not to use it, wait until your mood changes, or try
18916  to customize 
18917 \family sans
18918 Chk\SpecialChar TeX
18919
18920 \family default
18921  to get better along with you.
18922 \end_layout
18923
18924 \begin_layout Standard
18925 Although 
18926 \family sans
18927 Chk\SpecialChar TeX
18928
18929 \family default
18930  
18931 \emph on
18932 is
18933 \emph default
18934  very configurable and extensible, you should not expect to solve all problems
18935  with 
18936 \family sans
18937 Chk\SpecialChar TeX
18938
18939 \family default
18940  in \SpecialChar LyX
18941  this way.
18942  Since \SpecialChar LyX
18943  has to generate a somewhat special \SpecialChar LaTeX
18944  file to be able to match the
18945  line numbers from the 
18946 \family sans
18947 Chk\SpecialChar TeX
18948
18949 \family default
18950  output
18951 \begin_inset Foot
18952 status collapsed
18953
18954 \begin_layout Plain Layout
18955 You can inspect the specific output from 
18956 \family sans
18957 chktex
18958 \family default
18959  by using 
18960 \family sans
18961 Document\SpecialChar menuseparator
18962 \SpecialChar LaTeX
18963
18964 \begin_inset space ~
18965 \end_inset
18966
18967 Log
18968 \family default
18969  right after a 
18970 \family sans
18971 chktex
18972 \family default
18973  run.
18974 \end_layout
18975
18976 \end_inset
18977
18978  to the internal document structure, some of the warnings will not appear
18979  correctly.
18980  There are two things you can do about this:
18981 \end_layout
18982
18983 \begin_layout Itemize
18984 Fine tune the 
18985 \family sans
18986 Chk\SpecialChar TeX
18987
18988 \family default
18989  invocation command line in 
18990 \begin_inset Flex Noun
18991 status collapsed
18992
18993 \begin_layout Plain Layout
18994 Tools\SpecialChar menuseparator
18995 Preferences\SpecialChar menuseparator
18996 Output\SpecialChar menuseparator
18997 LaTeX\SpecialChar menuseparator
18998 CheckTeX command
18999 \end_layout
19000
19001 \end_inset
19002
19003 , or the global 
19004 \family sans
19005 Chk\SpecialChar TeX
19006
19007 \family default
19008  installation configuration file (usually with the file 
19009 \family typewriter
19010 chktexrc
19011 \family default
19012 ).
19013  See below to learn what warnings can be enabled and disabled on the command
19014  line.
19015 \end_layout
19016
19017 \begin_layout Itemize
19018 Export your document as a raw \SpecialChar LaTeX
19019  file using 
19020 \family sans
19021 File\SpecialChar menuseparator
19022 Export\SpecialChar menuseparator
19023 \SpecialChar LaTeX
19024
19025 \family default
19026  and run 
19027 \family typewriter
19028 chktex
19029 \family default
19030  manually on that.
19031  Invoked in this way, it can be a hassle to find the corresponding place
19032  in the document inside \SpecialChar LyX
19033 , but with a little patience, you should be able
19034  to do it.
19035 \end_layout
19036
19037 \begin_layout Standard
19038 Here follows the warning messages that can be enabled and disabled in 
19039 \family sans
19040 Preferences
19041 \family default
19042 .
19043  Use 
19044 \family typewriter
19045 -n#
19046 \family default
19047  to disable a warning, and 
19048 \family typewriter
19049 -w#
19050 \family default
19051  to enable a warning.
19052  The emphasized entries are disabled by default, because the default is
19053  "
19054 \family typewriter
19055 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19056 \family default
19057 ".
19058 \end_layout
19059
19060 \begin_layout Standard
19061 Notice that you should only use the options that enable and disable warnings,
19062  because \SpecialChar LyX
19063  relies on some of the other command line parameters to be set
19064  in a specific way to have a chance to communicate with 
19065 \family typewriter
19066 chktex
19067 \family default
19068 .
19069 \end_layout
19070
19071 \begin_layout Enumerate
19072
19073 \size small
19074 \emph on
19075 Command terminated with space.
19076 \end_layout
19077
19078 \begin_layout Enumerate
19079
19080 \size small
19081 Non-breaking space (
19082 \begin_inset Quotes eld
19083 \end_inset
19084
19085
19086 \family typewriter
19087 ~
19088 \family default
19089
19090 \begin_inset Quotes erd
19091 \end_inset
19092
19093 ) should have been used.
19094 \end_layout
19095
19096 \begin_layout Enumerate
19097
19098 \size small
19099 \emph on
19100 You should enclose the previous parenthesis with 
19101 \begin_inset Quotes eld
19102 \end_inset
19103
19104
19105 \family typewriter
19106 {}
19107 \family default
19108
19109 \begin_inset Quotes erd
19110 \end_inset
19111
19112 .
19113 \end_layout
19114
19115 \begin_layout Enumerate
19116
19117 \size small
19118 Italic correction (
19119 \begin_inset Quotes eld
19120 \end_inset
19121
19122
19123 \family typewriter
19124
19125 \backslash
19126 /
19127 \family default
19128
19129 \begin_inset Quotes erd
19130 \end_inset
19131
19132 ) found in non-italic buffer.
19133 \end_layout
19134
19135 \begin_layout Enumerate
19136
19137 \size small
19138 Italic correction (
19139 \begin_inset Quotes eld
19140 \end_inset
19141
19142
19143 \family typewriter
19144
19145 \backslash
19146 /
19147 \family default
19148
19149 \begin_inset Quotes erd
19150 \end_inset
19151
19152 ) found more than once.
19153 \end_layout
19154
19155 \begin_layout Enumerate
19156
19157 \size small
19158 \emph on
19159 No italic correction (
19160 \begin_inset Quotes eld
19161 \end_inset
19162
19163
19164 \family typewriter
19165
19166 \backslash
19167 /
19168 \family default
19169
19170 \begin_inset Quotes erd
19171 \end_inset
19172
19173 ) found.
19174 \end_layout
19175
19176 \begin_layout Enumerate
19177
19178 \size small
19179 Accent command 
19180 \begin_inset Quotes eld
19181 \end_inset
19182
19183
19184 \family typewriter
19185 cmd
19186 \family default
19187
19188 \begin_inset Quotes erd
19189 \end_inset
19190
19191  needs use of 
19192 \begin_inset Quotes eld
19193 \end_inset
19194
19195
19196 \family typewriter
19197 cmd
19198 \family default
19199
19200 \begin_inset Quotes erd
19201 \end_inset
19202
19203 .
19204 \end_layout
19205
19206 \begin_layout Enumerate
19207
19208 \size small
19209 Wrong length of dash may have been used.
19210 \end_layout
19211
19212 \begin_layout Enumerate
19213
19214 \size small
19215 \emph on
19216 \begin_inset Quotes eld
19217 \end_inset
19218
19219
19220 \family typewriter
19221 %s
19222 \family default
19223
19224 \begin_inset Quotes erd
19225 \end_inset
19226
19227  expected, found 
19228 \begin_inset Quotes eld
19229 \end_inset
19230
19231
19232 \family typewriter
19233 %s
19234 \family default
19235
19236 \begin_inset Quotes erd
19237 \end_inset
19238
19239 .
19240 \end_layout
19241
19242 \begin_layout Enumerate
19243
19244 \size small
19245 Solo 
19246 \begin_inset Quotes eld
19247 \end_inset
19248
19249
19250 \family typewriter
19251 %s
19252 \family default
19253
19254 \begin_inset Quotes erd
19255 \end_inset
19256
19257  found.
19258 \end_layout
19259
19260 \begin_layout Enumerate
19261
19262 \size small
19263 You should use 
19264 \begin_inset Quotes eld
19265 \end_inset
19266
19267
19268 \family typewriter
19269 %s
19270 \family default
19271
19272 \begin_inset Quotes erd
19273 \end_inset
19274
19275  to achieve an ellipsis.
19276 \end_layout
19277
19278 \begin_layout Enumerate
19279
19280 \size small
19281 Inter-word spacing (
19282 \begin_inset Quotes eld
19283 \end_inset
19284
19285
19286 \family typewriter
19287
19288 \backslash
19289
19290 \family default
19291  
19292 \begin_inset Quotes eld
19293 \end_inset
19294
19295 ) should perhaps be used.
19296 \end_layout
19297
19298 \begin_layout Enumerate
19299
19300 \size small
19301 Inter-sentence spacing (
19302 \begin_inset Quotes eld
19303 \end_inset
19304
19305
19306 \family typewriter
19307
19308 \backslash
19309 @
19310 \family default
19311
19312 \begin_inset Quotes erd
19313 \end_inset
19314
19315 ) should perhaps be used.
19316 \end_layout
19317
19318 \begin_layout Enumerate
19319
19320 \size small
19321 Could not find argument for command.
19322 \end_layout
19323
19324 \begin_layout Enumerate
19325
19326 \size small
19327 No match found for 
19328 \begin_inset Quotes eld
19329 \end_inset
19330
19331
19332 \family typewriter
19333 %s
19334 \family default
19335
19336 \begin_inset Quotes erd
19337 \end_inset
19338
19339 .
19340 \end_layout
19341
19342 \begin_layout Enumerate
19343
19344 \size small
19345 Math mode still on at end of \SpecialChar LaTeX
19346  file.
19347 \end_layout
19348
19349 \begin_layout Enumerate
19350
19351 \size small
19352 Number of 
19353 \begin_inset Quotes eld
19354 \end_inset
19355
19356
19357 \family typewriter
19358 char
19359 \family default
19360
19361 \begin_inset Quotes erd
19362 \end_inset
19363
19364  doesn't match the number of 
19365 \begin_inset Quotes eld
19366 \end_inset
19367
19368
19369 \family typewriter
19370 char
19371 \family default
19372
19373 \begin_inset Quotes erd
19374 \end_inset
19375
19376 .
19377 \end_layout
19378
19379 \begin_layout Enumerate
19380
19381 \size small
19382 You should use either 
19383 \family typewriter
19384
19385 \begin_inset Quotes eld
19386 \end_inset
19387
19388
19389 \family default
19390  or 
19391 \family typewriter
19392
19393 \begin_inset Quotes erd
19394 \end_inset
19395
19396
19397 \family default
19398  as an alternative to 
19399 \begin_inset Quotes eld
19400 \end_inset
19401
19402
19403 \family typewriter
19404 "
19405 \family default
19406
19407 \begin_inset Quotes erd
19408 \end_inset
19409
19410 .
19411 \end_layout
19412
19413 \begin_layout Enumerate
19414
19415 \size small
19416 You should use "
19417 \family typewriter
19418 '
19419 \family default
19420 " (ASCII 39) instead of "
19421 \family typewriter
19422 ´
19423 \family default
19424 " (ASCII 180).
19425 \end_layout
19426
19427 \begin_layout Enumerate
19428
19429 \size small
19430 User-specified pattern found.
19431 \end_layout
19432
19433 \begin_layout Enumerate
19434
19435 \size small
19436 This command might not be intended.
19437 \end_layout
19438
19439 \begin_layout Enumerate
19440
19441 \size small
19442 \emph on
19443 Comment displayed.
19444 \end_layout
19445
19446 \begin_layout Enumerate
19447
19448 \size small
19449 Either 
19450 \family typewriter
19451 ''
19452 \backslash
19453 ,'
19454 \family default
19455  or 
19456 \family typewriter
19457 '
19458 \backslash
19459 ,''
19460 \family default
19461  will look better.
19462 \end_layout
19463
19464 \begin_layout Enumerate
19465
19466 \size small
19467 Delete this space to maintain correct page references.
19468 \end_layout
19469
19470 \begin_layout Enumerate
19471
19472 \size small
19473 \emph on
19474 You might wish to put this between a pair of 
19475 \begin_inset Quotes eld
19476 \end_inset
19477
19478
19479 \family typewriter
19480 {}
19481 \family default
19482
19483 \begin_inset Quotes erd
19484 \end_inset
19485
19486 .
19487 \end_layout
19488
19489 \begin_layout Enumerate
19490
19491 \size small
19492 You ought to remove spaces in front of punctuation.
19493 \end_layout
19494
19495 \begin_layout Enumerate
19496
19497 \size small
19498 Could not execute \SpecialChar LaTeX
19499  command.
19500 \end_layout
19501
19502 \begin_layout Enumerate
19503
19504 \size small
19505 Don't use 
19506 \family typewriter
19507
19508 \backslash
19509 /
19510 \family default
19511  in front of small punctuation.
19512 \end_layout
19513
19514 \begin_layout Enumerate
19515
19516 \family typewriter
19517 \size small
19518 $
19519 \backslash
19520 times$
19521 \family default
19522  may look prettier here.
19523 \end_layout
19524
19525 \begin_layout Enumerate
19526
19527 \size small
19528 \emph on
19529 Multiple spaces detected in output.
19530 \end_layout
19531
19532 \begin_layout Enumerate
19533
19534 \size small
19535 This text may be ignored.
19536 \end_layout
19537
19538 \begin_layout Enumerate
19539
19540 \size small
19541 Use 
19542 \family typewriter
19543
19544 \begin_inset Quotes eld
19545 \end_inset
19546
19547
19548 \family default
19549  to begin quotation, not 
19550 \family typewriter
19551 '
19552 \family default
19553 .
19554 \end_layout
19555
19556 \begin_layout Enumerate
19557
19558 \size small
19559 Use 
19560 \family typewriter
19561 '
19562 \family default
19563  to end quotation, not 
19564 \family typewriter
19565
19566 \begin_inset Quotes eld
19567 \end_inset
19568
19569
19570 \family default
19571 .
19572 \end_layout
19573
19574 \begin_layout Enumerate
19575
19576 \size small
19577 Don't mix quotes.
19578 \end_layout
19579
19580 \begin_layout Enumerate
19581
19582 \size small
19583 You should perhaps use 
19584 \begin_inset Quotes eld
19585 \end_inset
19586
19587
19588 \family typewriter
19589 cmd
19590 \family default
19591
19592 \begin_inset Quotes erd
19593 \end_inset
19594
19595  instead.
19596 \end_layout
19597
19598 \begin_layout Enumerate
19599
19600 \size small
19601 You should put a space in front of/after parenthesis.
19602 \end_layout
19603
19604 \begin_layout Enumerate
19605
19606 \size small
19607 You should avoid spaces in front of/after parenthesis.
19608 \end_layout
19609
19610 \begin_layout Enumerate
19611
19612 \size small
19613 \emph on
19614 You should not use punctuation in front of/after quotes.
19615 \end_layout
19616
19617 \begin_layout Enumerate
19618
19619 \size small
19620 Double space found.
19621 \end_layout
19622
19623 \begin_layout Enumerate
19624
19625 \size small
19626 You should put punctuation outside inner/inside display math mode.
19627 \end_layout
19628
19629 \begin_layout Enumerate
19630
19631 \size small
19632 You ought to not use primitive \SpecialChar TeX
19633  in \SpecialChar LaTeX
19634  code.
19635 \end_layout
19636
19637 \begin_layout Enumerate
19638
19639 \size small
19640 You should remove spaces in front of 
19641 \begin_inset Quotes eld
19642 \end_inset
19643
19644
19645 \family typewriter
19646 %s
19647 \family default
19648
19649 \begin_inset Quotes erd
19650 \end_inset
19651
19652
19653 \end_layout
19654
19655 \begin_layout Enumerate
19656
19657 \size small
19658 \begin_inset Quotes eld
19659 \end_inset
19660
19661
19662 \family typewriter
19663 %s
19664 \family default
19665
19666 \begin_inset Quotes erd
19667 \end_inset
19668
19669  is normally not followed by 
19670 \begin_inset Quotes eld
19671 \end_inset
19672
19673
19674 \family typewriter
19675 %c
19676 \family default
19677
19678 \begin_inset Quotes erd
19679 \end_inset
19680
19681 .
19682 \end_layout
19683
19684 \begin_layout Standard
19685 In later versions of \SpecialChar LyX
19686 , we hope to provide a more complete interface to this
19687  tool (and it's smaller cousin 
19688 \family typewriter
19689 lacheck
19690 \family default
19691 ) to exploit the full power of it.
19692  But it's not exactly useless as it is now: go try it on one of your existing
19693  documents of a certain length and be surprised.
19694 \end_layout
19695
19696 \begin_layout Section
19697 Version Control in \SpecialChar LyX
19698
19699 \end_layout
19700
19701 \begin_layout Standard
19702 by
19703 \noun on
19704  Lars Gullik Bjønnes 
19705 \noun default
19706 and 
19707 \noun on
19708 Pavel Sanda
19709 \end_layout
19710
19711 \begin_layout Subsection
19712 Introduction
19713 \end_layout
19714
19715 \begin_layout Standard
19716 \SpecialChar LyX
19717  supports some of the most basic RCS/CVS/SVN/GIT commands.
19718  If you need something a bit more sophisticated you will have to do that
19719  manually in a terminal.
19720 \end_layout
19721
19722 \begin_layout Standard
19723 Also note that CVS support is not as good as subversion support so we advise
19724  using SVN instead.
19725  A good place to start learning Subversion is SVN Book
19726 \begin_inset Foot
19727 status collapsed
19728
19729 \begin_layout Plain Layout
19730 \begin_inset CommandInset href
19731 LatexCommand href
19732 target "http://svnbook.red-bean.com/"
19733
19734 \end_inset
19735
19736
19737 \end_layout
19738
19739 \end_inset
19740
19741 .
19742  In the case of RCS you should read 
19743 \begin_inset Quotes eld
19744 \end_inset
19745
19746 rcsintro
19747 \begin_inset Quotes erd
19748 \end_inset
19749
19750  (a man file, read it with 
19751 \family typewriter
19752 man rcsintro
19753 \family default
19754 ).
19755  This file describes all the basic features of RCS.
19756  You should especially notice the comment about a RCS directory, and the
19757  notion of a master RCS file (the file ending in 
19758 \family typewriter
19759 ,v
19760 \family default
19761 ).
19762 \end_layout
19763
19764 \begin_layout Standard
19765 Before you begin to use the version control features in \SpecialChar LyX
19766 , you should be
19767  familiar with RCS/CVS/SVN/GIT usage.
19768  The implementation in \SpecialChar LyX
19769  assumes a recent version of the GNU RCS or CVS/SVN
19770  package — no guarantees are made for older versions.
19771  Most of the log messages are not currently displayed after operations —
19772  you can check them in the Messages pane if unsure.
19773  Regular users of version control will appreciate VC toolbar, which can
19774  be enabled via 
19775 \family sans
19776 View\SpecialChar menuseparator
19777 Toolbars\SpecialChar menuseparator
19778 Version
19779 \begin_inset space ~
19780 \end_inset
19781
19782 Control
19783 \family default
19784 .
19785 \end_layout
19786
19787 \begin_layout Standard
19788 For introducing your own external commands consult vc-command in the manual
19789  of \SpecialChar LyX
19790  functions.
19791 \end_layout
19792
19793 \begin_layout Standard
19794 It is strongly recommended to store documents in uncompressed format if
19795  using version control (uncheck 
19796 \family sans
19797 Document\SpecialChar menuseparator
19798 Compressed
19799 \family default
19800  if it is checked): Uncompressed LyX documents are text files and therefore
19801  for merging two different versions by version control systems.
19802  Compressed LyX documents are binary files, which cannot be merged by version
19803  control systems.
19804 \end_layout
19805
19806 \begin_layout Subsection
19807 RCS commands in \SpecialChar LyX
19808
19809 \end_layout
19810
19811 \begin_layout Standard
19812 The following sections describe the RCS commands supported by \SpecialChar LyX
19813 .
19814  You can find them in the 
19815 \family sans
19816 File\SpecialChar menuseparator
19817 Version
19818 \begin_inset space ~
19819 \end_inset
19820
19821 Control
19822 \family default
19823  submenu.
19824  \SpecialChar LyX
19825  was tested against RCS 5.7/5.8.
19826 \end_layout
19827
19828 \begin_layout Subsubsection
19829
19830 \family sans
19831 Register
19832 \end_layout
19833
19834 \begin_layout Standard
19835 If your document is not under revision control, this is the only item shown
19836  in the menu.
19837  And if it is under revision control, the 
19838 \family sans
19839 Register
19840 \family default
19841  item is not visible.
19842  
19843 \end_layout
19844
19845 \begin_layout Standard
19846 This command registers your document with RCS (unless you are under the
19847  directory managed by CVS)\SpecialChar endofsentence
19848  You are asked interactively to supply an initial
19849  description of the document.
19850  The document is now set in Read-Only mode and you have to 
19851 \family sans
19852 Check
19853 \begin_inset space ~
19854 \end_inset
19855
19856 Out
19857 \begin_inset space ~
19858 \end_inset
19859
19860 For
19861 \begin_inset space ~
19862 \end_inset
19863
19864 Edit
19865 \family default
19866 , before making any changes to it.
19867  A document under revision control has a 
19868 \begin_inset Quotes eld
19869 \end_inset
19870
19871 [RCS:<version> <locker>]
19872 \begin_inset Quotes erd
19873 \end_inset
19874
19875  item tagged to the filename in the minibuffer.
19876 \end_layout
19877
19878 \begin_layout Standard
19879 RCS command that is run: 
19880 \family typewriter
19881 ci -q -u -i -t-"<initial description>" <file-name>
19882 \end_layout
19883
19884 \begin_layout Standard
19885 Read 
19886 \family typewriter
19887 man ci
19888 \family default
19889  to understand the switches.
19890  
19891 \end_layout
19892
19893 \begin_layout Subsubsection
19894
19895 \family sans
19896 Check In Changes
19897 \end_layout
19898
19899 \begin_layout Standard
19900 When you are finished editing a file, you check in your changes.
19901  When you do this, you are asked for a description of the changes.
19902  This is stored in the history log.
19903  The version number is bumped, your changes are applied to the master RCS
19904  file, the document is unlocked and set to Read-Only mode.
19905 \end_layout
19906
19907 \begin_layout Standard
19908 RCS command: 
19909 \family typewriter
19910 ci -q -u -m"<description>" <file-name>
19911 \end_layout
19912
19913 \begin_layout Subsubsection
19914
19915 \family sans
19916 Check Out For Edit
19917 \end_layout
19918
19919 \begin_layout Standard
19920 By doing this you lock the document so that only you can edit it.
19921  This will also make the document Read-Write only for you.
19922  You will usually continue editing for a while and when you are finished
19923  you check in your changes.
19924  The status line is changed to reflect that you have locked the file.
19925 \end_layout
19926
19927 \begin_layout Standard
19928 RCS command: 
19929 \family typewriter
19930 co -q -l <file-name>
19931 \end_layout
19932
19933 \begin_layout Subsubsection
19934
19935 \family sans
19936 Revert To Repository Version
19937 \end_layout
19938
19939 \begin_layout Standard
19940 This will discard all changes made to the document since the last check
19941  in.
19942  You get a warning before changes are discarded.
19943 \end_layout
19944
19945 \begin_layout Standard
19946 RCS command: 
19947 \family typewriter
19948 co -f -u<version> <file-name>
19949 \end_layout
19950
19951 \begin_layout Subsubsection
19952
19953 \family sans
19954 Copy
19955 \end_layout
19956
19957 \begin_layout Standard
19958 This will create a copy of the current document.
19959  Since RCS does not support copy operations natively, the version history
19960  is not preserved, and the copy is added as a new file.
19961  It requires a clean document without any changes since the last checkin.
19962  You are asked for a file name and a description of the copy operation.
19963  After that the copy is created, both locally and in the repository.
19964  If the parent directories of the copied and original document differ, all
19965  relative paths of included files of the copy are adjusted (like in 
19966 \family sans
19967 File\SpecialChar menuseparator
19968 Save As
19969 \family default
19970 \SpecialChar ldots
19971 ).
19972  Finally, the copy is loaded instead of the original document.
19973 \end_layout
19974
19975 \begin_layout Labeling
19976 \labelwidthstring 00.00.0000
19977 RCS
19978 \begin_inset space ~
19979 \end_inset
19980
19981 commands: 
19982 \begin_inset space ~
19983 \end_inset
19984
19985
19986 \begin_inset Newline newline
19987 \end_inset
19988
19989 Copy 
19990 \begin_inset Flex Code
19991 status collapsed
19992
19993 \begin_layout Plain Layout
19994
19995 \family typewriter
19996 \begin_inset Quotes eld
19997 \end_inset
19998
19999 <file-name>
20000 \begin_inset Quotes erd
20001 \end_inset
20002
20003
20004 \end_layout
20005
20006 \end_inset
20007
20008  to 
20009 \begin_inset Flex Code
20010 status collapsed
20011
20012 \begin_layout Plain Layout
20013
20014 \family typewriter
20015 \begin_inset Quotes eld
20016 \end_inset
20017
20018 <new-file-name>
20019 \begin_inset Quotes erd
20020 \end_inset
20021
20022
20023 \end_layout
20024
20025 \end_inset
20026
20027
20028 \begin_inset Newline newline
20029 \end_inset
20030
20031
20032 \begin_inset Flex Code
20033 status collapsed
20034
20035 \begin_layout Plain Layout
20036 ci -q -u 
20037 \family typewriter
20038 -i 
20039 \begin_inset Quotes eld
20040 \end_inset
20041
20042 <new-file-name>
20043 \begin_inset Quotes erd
20044 \end_inset
20045
20046
20047 \end_layout
20048
20049 \end_inset
20050
20051
20052 \end_layout
20053
20054 \begin_layout Subsubsection
20055
20056 \family sans
20057 Undo Last Checkin
20058 \end_layout
20059
20060 \begin_layout Standard
20061 This makes as if the last check in never happened.
20062  No changes are made to the document loaded into \SpecialChar LyX
20063 , but the last version
20064  is removed from the master RCS file.
20065 \end_layout
20066
20067 \begin_layout Standard
20068 RCS command: 
20069 \family typewriter
20070 rcs -o<version> <file-name>
20071 \end_layout
20072
20073 \begin_layout Subsubsection
20074
20075 \family sans
20076 Show History
20077 \end_layout
20078
20079 \begin_layout Standard
20080 This shows the complete history of the RCS document.
20081  The output of 
20082 \family typewriter
20083 rlog <file-name>
20084 \family default
20085  is shown in a browser.
20086  See 
20087 \family typewriter
20088 man rlog
20089 \family default
20090  for more info.
20091 \end_layout
20092
20093 \begin_layout Subsubsection
20094 Revision info
20095 \end_layout
20096
20097 \begin_layout Standard
20098 \SpecialChar LyX
20099  supports RCS version number, author name, date and time of last commit.
20100  All those are extracted from 
20101 \family typewriter
20102 rlog -r <file-name>
20103 \family default
20104 .
20105  See 
20106 \begin_inset CommandInset ref
20107 LatexCommand ref
20108 reference "subsec:VCS-Revision-Information"
20109
20110 \end_inset
20111
20112  for details.
20113 \end_layout
20114
20115 \begin_layout Subsection
20116 CVS commands in \SpecialChar LyX
20117
20118 \end_layout
20119
20120 \begin_layout Standard
20121 A subset of CVS operations is supported by \SpecialChar LyX
20122 .
20123  You can find the commands in the 
20124 \family sans
20125 File\SpecialChar menuseparator
20126 Version
20127 \begin_inset space ~
20128 \end_inset
20129
20130 Control
20131 \family default
20132  submenu.
20133  The version control system SVN is more powerful, so please use it instead
20134  of CVS if possible.
20135 \end_layout
20136
20137 \begin_layout Subsubsection
20138
20139 \family sans
20140 General CVS usage
20141 \end_layout
20142
20143 \begin_layout Standard
20144 If you start from scratch with CVS you have to create your repository and
20145  checkout the working copy with external tools.
20146  If you're using a client-server setup you may need to login before doing
20147  the first repository checkout.
20148 \end_layout
20149
20150 \begin_layout Standard
20151 If your documents are under revision control and others are using the same
20152  repository problems arise when different changes to the same document at
20153  the same location happen.
20154  Standard CVS repositories don't operate with a file locking mechanism.
20155  This may be surprising, but conflicts only occur if people disagree on
20156  the proper content of the same part of a document.
20157  So, if co-workers are used to communicate regularly, these conflicts occur
20158  rarely.
20159  If they don't communicate they have a fundamental problem anyway.
20160  Nevertheless some people like to work with so called 
20161 \begin_inset Quotes eld
20162 \end_inset
20163
20164 reserved checkouts
20165 \begin_inset Quotes erd
20166 \end_inset
20167
20168 .
20169  If they do so the working copy of all files is readonly when checked out
20170  first and the user starts editing after using a special command to make
20171  the working copy writable.
20172  When the changes are checked in the working copy returns to readonly state.
20173  With \SpecialChar LyX
20174  one has to edit the 
20175 \begin_inset Flex Code
20176 status collapsed
20177
20178 \begin_layout Plain Layout
20179 .cvsrc
20180 \end_layout
20181
20182 \end_inset
20183
20184  file and add the line 
20185 \begin_inset Flex Code
20186 status collapsed
20187
20188 \begin_layout Plain Layout
20189 cvs -r
20190 \end_layout
20191
20192 \end_inset
20193
20194  to work with reserved checkouts.
20195  The benefit is the possibility to see who is using a writable copy of some
20196  document.
20197  It's not guaranteed only one user makes a copy writable.
20198 \end_layout
20199
20200 \begin_layout Standard
20201 \SpecialChar LyX
20202  tries to guess if you're using reserved or non-reserved checkouts.
20203  If your working copy is readonly or it is writable and an additional copy
20204  of your document exists in the CVS/Base sub-directory a reserved otherwise
20205  a non-reserved checkout is assumed.
20206  When a reserved checkout is detected you have to use 
20207 \begin_inset Flex Noun
20208 status collapsed
20209
20210 \begin_layout Plain Layout
20211 Check Out
20212 \end_layout
20213
20214 \end_inset
20215
20216  to make your working copy writable if it's readonly.
20217  After doing so the 
20218 \begin_inset Flex Noun
20219 status collapsed
20220
20221 \begin_layout Plain Layout
20222 Check In
20223 \end_layout
20224
20225 \end_inset
20226
20227  operation is possible and that makes your working copy readonly again after
20228  transferring your changes to the repository.
20229 \end_layout
20230
20231 \begin_layout Standard
20232 More information about CVS can be found here 
20233 \begin_inset Flex URL
20234 status collapsed
20235
20236 \begin_layout Plain Layout
20237
20238 http://www.nongnu.org/cvs
20239 \end_layout
20240
20241 \end_inset
20242
20243  and here 
20244 \begin_inset Flex URL
20245 status collapsed
20246
20247 \begin_layout Plain Layout
20248
20249 http://ximbiot.com/cvs
20250 \end_layout
20251
20252 \end_inset
20253
20254 .
20255 \end_layout
20256
20257 \begin_layout Standard
20258 Read 
20259 \family typewriter
20260 man cvs
20261 \family default
20262  to understand the sub-commands and the switches mentioned below.
20263 \end_layout
20264
20265 \begin_layout Subsubsection
20266
20267 \family sans
20268 Register
20269 \end_layout
20270
20271 \begin_layout Standard
20272 If your document is not under revision control, this is the only item shown
20273  in the menu.
20274  And if it is under revision control, the 
20275 \family sans
20276 \bar under
20277 R
20278 \bar default
20279 egister
20280 \family default
20281  item is not visible.
20282  
20283 \end_layout
20284
20285 \begin_layout Standard
20286 This command registers in CVS your document 
20287 \begin_inset Flex Strong
20288 status collapsed
20289
20290 \begin_layout Plain Layout
20291
20292 \emph on
20293 only
20294 \end_layout
20295
20296 \end_inset
20297
20298  in the case you have already the documents directory under CVS control
20299  (in particular 
20300 \family typewriter
20301 CVS/Entries
20302 \family default
20303  file exists).
20304  This means you have to create or checkout the archive by yourself using
20305  external tools.
20306  (In case you forget that step \SpecialChar LyX
20307  registers the document with RCS.)
20308 \end_layout
20309
20310 \begin_layout Standard
20311 Then you are asked interactively to supply an initial description of the
20312  document.
20313  Don't forget that registered file is not yet checked in.
20314 \end_layout
20315
20316 \begin_layout Standard
20317 CVS command that is run: 
20318 \family typewriter
20319 cvs -q add -m"<entered message>" "<file-name>"
20320 \end_layout
20321
20322 \begin_layout Standard
20323 The term 
20324 \family typewriter
20325 "<file-name>"
20326 \family default
20327  above and for all other CVS commands is an abbreviation for 
20328 \begin_inset Quotes eld
20329 \end_inset
20330
20331 change the current working directory to file location and use the file name
20332  without path component as argument
20333 \begin_inset Quotes erd
20334 \end_inset
20335
20336 .
20337 \end_layout
20338
20339 \begin_layout Subsubsection
20340
20341 \family sans
20342 Check In Changes
20343 \end_layout
20344
20345 \begin_layout Standard
20346 When you are finished editing a file, you commit your changes.
20347  When you do this and you had changed the document, you are asked for a
20348  description of the changes.
20349  After that changes are written to the repository.
20350  In case you didn't change the document and a reserved checkout is detected
20351  the reservation made on 
20352 \begin_inset Flex Noun
20353 status collapsed
20354
20355 \begin_layout Plain Layout
20356 Check Out
20357 \end_layout
20358
20359 \end_inset
20360
20361  is undone.
20362 \end_layout
20363
20364 \begin_layout Labeling
20365 \labelwidthstring 00.00.0000
20366 CVS
20367 \begin_inset space ~
20368 \end_inset
20369
20370 command: 
20371 \begin_inset space ~
20372 \end_inset
20373
20374
20375 \begin_inset Newline newline
20376 \end_inset
20377
20378
20379 \begin_inset Flex Code
20380 status collapsed
20381
20382 \begin_layout Plain Layout
20383 cvs 
20384 \family typewriter
20385 -q commit -m"<description>" "<file-name>"
20386 \end_layout
20387
20388 \end_inset
20389
20390  or
20391 \begin_inset Newline newline
20392 \end_inset
20393
20394
20395 \begin_inset Flex Code
20396 status collapsed
20397
20398 \begin_layout Plain Layout
20399 cvs -q unedit 
20400 \family typewriter
20401 "<file-name>"
20402 \end_layout
20403
20404 \end_inset
20405
20406
20407 \end_layout
20408
20409 \begin_layout Subsubsection
20410
20411 \family sans
20412 Check Out Changes
20413 \end_layout
20414
20415 \begin_layout Standard
20416 When you are sharing a repository with others, you may have to incorporate
20417  their changes into your working copy.
20418 \end_layout
20419
20420 \begin_layout Standard
20421 CVS command: 
20422 \family typewriter
20423 cvs -q update "<file-name>"
20424 \end_layout
20425
20426 \begin_layout Standard
20427 If a readonly checkout is detected the working copy is made writable and
20428  reserved.
20429 \end_layout
20430
20431 \begin_layout Standard
20432 CVS command: 
20433 \family typewriter
20434 cvs -q edit "<file-name>"
20435 \end_layout
20436
20437 \begin_layout Subsubsection
20438
20439 \family sans
20440 Revert To Repository Version
20441 \end_layout
20442
20443 \begin_layout Standard
20444 This will discard all changes made to the document since the last check
20445  in.
20446  You get a warning before changes are discarded.
20447  Firstly the file is deleted, secondly CVS update command is run.
20448 \end_layout
20449
20450 \begin_layout Standard
20451 CVS command: 
20452 \family typewriter
20453 cvs -q update "<file-name>"
20454 \end_layout
20455
20456 \begin_layout Standard
20457 If a reserved checkout is detected and the working copy has no changes only
20458  the reservation is undone.
20459 \end_layout
20460
20461 \begin_layout Standard
20462 CVS command: 
20463 \family typewriter
20464 cvs -q unedit "<file-name>"
20465 \end_layout
20466
20467 \begin_layout Subsubsection
20468
20469 \family sans
20470 Copy
20471 \end_layout
20472
20473 \begin_layout Standard
20474 This will create a copy of the current document.
20475  Since CVS does not support copy operations natively, the version history
20476  is not preserved, and the copy is added as a new file.
20477  It requires a clean document without any changes since the last checkin.
20478  You are asked for a file name and a description of the copy operation.
20479  After that the copy is created, both locally and in the repository.
20480  If the parent directories of the copied and original document differ, all
20481  relative paths of included files of the copy are adjusted (like in 
20482 \family sans
20483 File\SpecialChar menuseparator
20484 Save As
20485 \family default
20486 \SpecialChar ldots
20487 ).
20488  Finally, the copy is loaded instead of the original document.
20489 \end_layout
20490
20491 \begin_layout Labeling
20492 \labelwidthstring 00.00.0000
20493 CVS
20494 \begin_inset space ~
20495 \end_inset
20496
20497 commands: 
20498 \begin_inset space ~
20499 \end_inset
20500
20501
20502 \begin_inset Newline newline
20503 \end_inset
20504
20505 Copy 
20506 \begin_inset Flex Code
20507 status collapsed
20508
20509 \begin_layout Plain Layout
20510
20511 \family typewriter
20512 \begin_inset Quotes eld
20513 \end_inset
20514
20515 <file-name>
20516 \begin_inset Quotes erd
20517 \end_inset
20518
20519
20520 \end_layout
20521
20522 \end_inset
20523
20524  to 
20525 \begin_inset Flex Code
20526 status collapsed
20527
20528 \begin_layout Plain Layout
20529
20530 \family typewriter
20531 \begin_inset Quotes eld
20532 \end_inset
20533
20534 <new-file-name>
20535 \begin_inset Quotes erd
20536 \end_inset
20537
20538
20539 \end_layout
20540
20541 \end_inset
20542
20543
20544 \begin_inset Newline newline
20545 \end_inset
20546
20547
20548 \begin_inset Flex Code
20549 status collapsed
20550
20551 \begin_layout Plain Layout
20552 cvs -q add 
20553 \family typewriter
20554
20555 \begin_inset Quotes eld
20556 \end_inset
20557
20558 <new-file-name>
20559 \begin_inset Quotes erd
20560 \end_inset
20561
20562
20563 \end_layout
20564
20565 \end_inset
20566
20567
20568 \end_layout
20569
20570 \begin_layout Subsubsection
20571
20572 \family sans
20573 Rename
20574 \end_layout
20575
20576 \begin_layout Standard
20577 This will rename the current document.
20578  Since CVS does not support rename operations natively, the version history
20579  is not preserved, the renamed document is added as a new file, and the
20580  original document is deleted.
20581  It requires a clean document without any changes since the last checkin.
20582  You are asked for a file name and a description of the rename operation.
20583  After that the document is renamed, both locally and in the repository.
20584  If the parent directories of the new and old file names differ, all relative
20585  paths of included files are adjusted (like in 
20586 \family sans
20587 File\SpecialChar menuseparator
20588 Save As
20589 \family default
20590 \SpecialChar ldots
20591 ).
20592  Finally, the document is reloaded using the new name.
20593 \end_layout
20594
20595 \begin_layout Labeling
20596 \labelwidthstring 00.00.0000
20597 CVS
20598 \begin_inset space ~
20599 \end_inset
20600
20601 commands: 
20602 \begin_inset space ~
20603 \end_inset
20604
20605
20606 \begin_inset Newline newline
20607 \end_inset
20608
20609 Rename 
20610 \begin_inset Flex Code
20611 status collapsed
20612
20613 \begin_layout Plain Layout
20614
20615 \family typewriter
20616 \begin_inset Quotes eld
20617 \end_inset
20618
20619 <file-name>
20620 \begin_inset Quotes erd
20621 \end_inset
20622
20623
20624 \end_layout
20625
20626 \end_inset
20627
20628  to 
20629 \begin_inset Flex Code
20630 status collapsed
20631
20632 \begin_layout Plain Layout
20633
20634 \family typewriter
20635 \begin_inset Quotes eld
20636 \end_inset
20637
20638 <new-file-name>
20639 \begin_inset Quotes erd
20640 \end_inset
20641
20642
20643 \end_layout
20644
20645 \end_inset
20646
20647
20648 \begin_inset Newline newline
20649 \end_inset
20650
20651
20652 \begin_inset Flex Code
20653 status collapsed
20654
20655 \begin_layout Plain Layout
20656 cvs -q add 
20657 \family typewriter
20658
20659 \begin_inset Quotes eld
20660 \end_inset
20661
20662 <new-file-name>
20663 \begin_inset Quotes erd
20664 \end_inset
20665
20666
20667 \end_layout
20668
20669 \end_inset
20670
20671
20672 \begin_inset Newline newline
20673 \end_inset
20674
20675
20676 \begin_inset Flex Code
20677 status collapsed
20678
20679 \begin_layout Plain Layout
20680 cvs -q remove 
20681 \family typewriter
20682
20683 \begin_inset Quotes eld
20684 \end_inset
20685
20686 <file-name>
20687 \begin_inset Quotes erd
20688 \end_inset
20689
20690
20691 \end_layout
20692
20693 \end_inset
20694
20695
20696 \end_layout
20697
20698 \begin_layout Subsubsection
20699 Update of the local directory checkout from repository
20700 \end_layout
20701
20702 \begin_layout Standard
20703 Once your documents gets more complex, containing sub-documents and pictures,
20704  including external 
20705 \begin_inset Flex Code
20706 status collapsed
20707
20708 \begin_layout Plain Layout
20709 .tex
20710 \end_layout
20711
20712 \end_inset
20713
20714  files and so on using version control becomes more complicated.
20715  \SpecialChar LyX
20716  supports updating the whole tree in which resides the document.
20717  This become especially useful once you cooperate with people which neither
20718  have detailed knowledge about CVS usage nor they have ambition to commit
20719  additional material to the repository.
20720  You have to organize the files structure so that all external files are
20721  in the same directory or subdirectories of the document.
20722  It's good practice anyway to store multipart documents in an extra directory.
20723 \end_layout
20724
20725 \begin_layout Standard
20726 The 
20727 \begin_inset Flex Code
20728 status collapsed
20729
20730 \begin_layout Plain Layout
20731 Update local directory from repository
20732 \end_layout
20733
20734 \end_inset
20735
20736  command updates the whole directory.
20737  If local changes are detected user is warned before update starts.
20738  In case of merge conflicts both versions of the conflicting document parts
20739  are placed in the final document.
20740  You have to review and correct the result of the merge.
20741  You'll find the conflicts enclosed in pairs of 
20742 \begin_inset Flex Code
20743 status collapsed
20744
20745 \begin_layout Plain Layout
20746 <<<<<<<
20747 \end_layout
20748
20749 \end_inset
20750
20751  and 
20752 \begin_inset Flex Code
20753 status collapsed
20754
20755 \begin_layout Plain Layout
20756 >>>>>>>
20757 \end_layout
20758
20759 \end_inset
20760
20761  separated by 
20762 \begin_inset Flex Code
20763 status collapsed
20764
20765 \begin_layout Plain Layout
20766 =======
20767 \end_layout
20768
20769 \end_inset
20770
20771 .
20772  The first part is your version as before the update operation with the
20773  document name prepended.
20774  The second one is the repository version with the version number after
20775  the sequence of 
20776 \begin_inset Flex Code
20777 status collapsed
20778
20779 \begin_layout Plain Layout
20780 >
20781 \end_layout
20782
20783 \end_inset
20784
20785  signs.
20786 \end_layout
20787
20788 \begin_layout Labeling
20789 \labelwidthstring 00.00.0000
20790 CVS
20791 \begin_inset space ~
20792 \end_inset
20793
20794 commands: 
20795 \begin_inset space ~
20796 \end_inset
20797
20798
20799 \begin_inset Newline newline
20800 \end_inset
20801
20802
20803 \begin_inset Flex Code
20804 status collapsed
20805
20806 \begin_layout Plain Layout
20807 cd $path; cvs diff 
20808 \family typewriter
20809 "."
20810 \end_layout
20811
20812 \end_inset
20813
20814  (Ask if changes are detected.)
20815 \begin_inset Newline newline
20816 \end_inset
20817
20818
20819 \begin_inset Flex Code
20820 status collapsed
20821
20822 \begin_layout Plain Layout
20823 cd $path; cvs -q update 
20824 \family typewriter
20825 "."
20826 \end_layout
20827
20828 \end_inset
20829
20830
20831 \end_layout
20832
20833 \begin_layout Standard
20834 where 
20835 \begin_inset Flex Code
20836 status collapsed
20837
20838 \begin_layout Plain Layout
20839 $path
20840 \end_layout
20841
20842 \end_inset
20843
20844  stands for the path to the document.
20845 \end_layout
20846
20847 \begin_layout Subsubsection
20848
20849 \family sans
20850 Show History
20851 \end_layout
20852
20853 \begin_layout Standard
20854 This shows the complete history of the CVS document.
20855  The output of 
20856 \family typewriter
20857 cvs log "<file-name>"
20858 \family default
20859  is shown in a browser.
20860 \end_layout
20861
20862 \begin_layout Subsubsection
20863 Revision info
20864 \end_layout
20865
20866 \begin_layout Standard
20867 \SpecialChar LyX
20868  supports CVS version number, author name, date and time of last commit.
20869  All those are extracted from 
20870 \family typewriter
20871 cvs log -r <file-name>
20872 \family default
20873 .
20874  See 
20875 \begin_inset CommandInset ref
20876 LatexCommand ref
20877 reference "subsec:VCS-Revision-Information"
20878
20879 \end_inset
20880
20881  for details.
20882 \end_layout
20883
20884 \begin_layout Subsection
20885 SVN commands in \SpecialChar LyX
20886
20887 \end_layout
20888
20889 \begin_layout Standard
20890 SVN is now partially supported by \SpecialChar LyX
20891 .
20892  You can find the commands in the 
20893 \family sans
20894 File\SpecialChar menuseparator
20895 Version
20896 \begin_inset space ~
20897 \end_inset
20898
20899 Control
20900 \family default
20901  submenu.
20902  Please note that if you use password protected access to repository via
20903  ssh, you will be asked in terminal window.
20904  \SpecialChar LyX
20905  was tested against SVN 1.5, 1.6, 1.7 and 1.8
20906 \begin_inset Foot
20907 status open
20908
20909 \begin_layout Plain Layout
20910 Most of the commands will work with 1.4 too, see 
20911 \begin_inset CommandInset ref
20912 LatexCommand ref
20913 reference "subsec:SVN-Repo-Update"
20914
20915 \end_inset
20916
20917 .
20918  There seems to be currently unresolved permissions problem under SVN 1.8
20919  with reverting changes when file is locked.
20920 \end_layout
20921
20922 \end_inset
20923
20924
20925 \end_layout
20926
20927 \begin_layout Subsubsection
20928
20929 \family sans
20930 Register
20931 \end_layout
20932
20933 \begin_layout Standard
20934 If your document is not under revision control, this is the only item shown
20935  in the menu.
20936  And if it is under revision control, the 
20937 \family sans
20938 \bar under
20939 R
20940 \bar default
20941 egister
20942 \family default
20943  item is not visible.
20944 \end_layout
20945
20946 \begin_layout Standard
20947 This command registers in SVN your document ONLY in case you have already
20948  the documents directory under SVN control (in particular 
20949 \family typewriter
20950 .svn/entries
20951 \family default
20952  file exists).
20953  This means you have to checkout the archive by yourself.
20954 \end_layout
20955
20956 \begin_layout Standard
20957 Then you are asked interactively to supply an initial description of the
20958  document.
20959  Don't forget that registered file is not yet commited.
20960 \end_layout
20961
20962 \begin_layout Standard
20963 SVN command that is run: 
20964 \family typewriter
20965 svn add -q 
20966 \begin_inset Quotes eld
20967 \end_inset
20968
20969 <file-name>
20970 \begin_inset Quotes erd
20971 \end_inset
20972
20973
20974 \end_layout
20975
20976 \begin_layout Standard
20977 Read 
20978 \family typewriter
20979 man svn
20980 \family default
20981  to understand the switches.
20982 \end_layout
20983
20984 \begin_layout Subsubsection
20985
20986 \family sans
20987 Check In Changes
20988 \end_layout
20989
20990 \begin_layout Standard
20991 When you are finished editing a file, you commit your changes.
20992  When you do this, you are asked for a description of the changes.
20993  After that changes are commited.
20994 \end_layout
20995
20996 \begin_layout Standard
20997 SVN command:
20998 \begin_inset Foot
20999 status collapsed
21000
21001 \begin_layout Plain Layout
21002 In case locking is not enabled.
21003  See Section 
21004 \begin_inset CommandInset ref
21005 LatexCommand ref
21006 reference "subsec:SVN-File-Locking"
21007
21008 \end_inset
21009
21010 .
21011 \end_layout
21012
21013 \end_inset
21014
21015  
21016 \family typewriter
21017 svn commit -q -m"<description>" <file-name>
21018 \end_layout
21019
21020 \begin_layout Subsubsection
21021
21022 \family sans
21023 Check Out For Edit
21024 \end_layout
21025
21026 \begin_layout Standard
21027 Updates the changes of this file from the repository.
21028  Be sure you understand SVN merging and conflicts resolving before using
21029  this function, because all conflicts has to be resolved manually by you!
21030 \end_layout
21031
21032 \begin_layout Standard
21033 SVN command:
21034 \begin_inset Foot
21035 status collapsed
21036
21037 \begin_layout Plain Layout
21038 Ditto.
21039 \end_layout
21040
21041 \end_inset
21042
21043  
21044 \family typewriter
21045 svn update --non-interactive 
21046 \begin_inset Quotes eld
21047 \end_inset
21048
21049 <file-name>
21050 \begin_inset Quotes erd
21051 \end_inset
21052
21053
21054 \end_layout
21055
21056 \begin_layout Subsubsection
21057
21058 \family sans
21059 Revert To Repository Version
21060 \end_layout
21061
21062 \begin_layout Standard
21063 This will discard all changes made to the document since the last check
21064  in.
21065  You get a warning before changes are discarded.
21066 \end_layout
21067
21068 \begin_layout Standard
21069 SVN command: 
21070 \family typewriter
21071 svn revert -q 
21072 \begin_inset Quotes eld
21073 \end_inset
21074
21075 <file-name>
21076 \begin_inset Quotes erd
21077 \end_inset
21078
21079
21080 \end_layout
21081
21082 \begin_layout Subsubsection
21083
21084 \family sans
21085 Copy
21086 \end_layout
21087
21088 \begin_layout Standard
21089 This will create a copy of the current document including the version history.
21090  It requires a clean document without any changes since the last checkin.
21091  You are asked for a file name and a description of the copy operation.
21092  After that the copy is created, both locally and in the repository.
21093  If the parent directories of the copied and original document differ, all
21094  relative paths of included files of the copy are adjusted (like in 
21095 \family sans
21096 File\SpecialChar menuseparator
21097 Save As
21098 \family default
21099 \SpecialChar ldots
21100 ).
21101  Finally, the copy is loaded instead of the original document.
21102 \end_layout
21103
21104 \begin_layout Labeling
21105 \labelwidthstring 00.00.0000
21106 SVN
21107 \begin_inset space ~
21108 \end_inset
21109
21110 commands: 
21111 \begin_inset space ~
21112 \end_inset
21113
21114
21115 \begin_inset Newline newline
21116 \end_inset
21117
21118
21119 \begin_inset Flex Code
21120 status collapsed
21121
21122 \begin_layout Plain Layout
21123 svn copy -q 
21124 \family typewriter
21125
21126 \begin_inset Quotes eld
21127 \end_inset
21128
21129 <file-name>
21130 \begin_inset Quotes erd
21131 \end_inset
21132
21133  
21134 \begin_inset Quotes eld
21135 \end_inset
21136
21137 <new-file-name>
21138 \begin_inset Quotes erd
21139 \end_inset
21140
21141
21142 \end_layout
21143
21144 \end_inset
21145
21146
21147 \begin_inset Newline newline
21148 \end_inset
21149
21150
21151 \begin_inset Flex Code
21152 status collapsed
21153
21154 \begin_layout Plain Layout
21155 svn commit
21156 \end_layout
21157
21158 \end_inset
21159
21160
21161 \end_layout
21162
21163 \begin_layout Subsubsection
21164
21165 \family sans
21166 Rename
21167 \end_layout
21168
21169 \begin_layout Standard
21170 This will rename the current document including the version history.
21171  It requires a clean document without any changes since the last checkin.
21172  You are asked for a file name and a description of the rename operation.
21173  After that the document is renamed, both locally and in the repository.
21174  If the parent directories of the new and old file names differ, all relative
21175  paths of included files are adjusted (like in 
21176 \family sans
21177 File\SpecialChar menuseparator
21178 Save As
21179 \family default
21180 \SpecialChar ldots
21181 ).
21182  Finally, the document is reloaded using the new name.
21183 \end_layout
21184
21185 \begin_layout Labeling
21186 \labelwidthstring 00.00.0000
21187 SVN
21188 \begin_inset space ~
21189 \end_inset
21190
21191 commands: 
21192 \begin_inset space ~
21193 \end_inset
21194
21195
21196 \begin_inset Newline newline
21197 \end_inset
21198
21199
21200 \begin_inset Flex Code
21201 status collapsed
21202
21203 \begin_layout Plain Layout
21204 svn move -q 
21205 \family typewriter
21206
21207 \begin_inset Quotes eld
21208 \end_inset
21209
21210 <file-name>
21211 \begin_inset Quotes erd
21212 \end_inset
21213
21214  
21215 \begin_inset Quotes eld
21216 \end_inset
21217
21218 <new-file-name>
21219 \begin_inset Quotes erd
21220 \end_inset
21221
21222
21223 \end_layout
21224
21225 \end_inset
21226
21227
21228 \begin_inset Newline newline
21229 \end_inset
21230
21231
21232 \begin_inset Flex Code
21233 status collapsed
21234
21235 \begin_layout Plain Layout
21236 svn commit
21237 \end_layout
21238
21239 \end_inset
21240
21241
21242 \end_layout
21243
21244 \begin_layout Subsubsection
21245 \begin_inset CommandInset label
21246 LatexCommand label
21247 name "subsec:SVN-Repo-Update"
21248
21249 \end_inset
21250
21251 Update of the local directory checkout from repository
21252 \begin_inset Foot
21253 status collapsed
21254
21255 \begin_layout Plain Layout
21256 Note that this command will work only with subversion 
21257 \begin_inset Formula $\geqq1.5$
21258 \end_inset
21259
21260
21261 \end_layout
21262
21263 \end_inset
21264
21265
21266 \end_layout
21267
21268 \begin_layout Standard
21269 All the commands above have one shortcomming - they deal with the current
21270  document only.
21271  Once your document contains pictures, includes external 
21272 \begin_inset Flex Code
21273 status collapsed
21274
21275 \begin_layout Plain Layout
21276 .tex
21277 \end_layout
21278
21279 \end_inset
21280
21281  files and so on administration becomes more complicated.
21282  \SpecialChar LyX
21283  now supports updating the whole tree in which resides the document
21284 \begin_inset Foot
21285 status collapsed
21286
21287 \begin_layout Plain Layout
21288 One need to organize the files structure so that all external files are
21289  in the same directory or subdirectories of the document.
21290  
21291 \end_layout
21292
21293 \end_inset
21294
21295 .
21296  This become especially useful once you cooperate with people which neither
21297  know about subversion management nor they have ambition to commit additional
21298  material to the repository.
21299  
21300 \end_layout
21301
21302 \begin_layout Standard
21303 \begin_inset Flex Code
21304 status collapsed
21305
21306 \begin_layout Plain Layout
21307 Update local directory from repository
21308 \end_layout
21309
21310 \end_inset
21311
21312  command updates the whole directory and in case of merge conflicts local
21313  version of the files are left, so no unintended data loss occurs.
21314  If local changes are detected user is warned before update starts.
21315 \end_layout
21316
21317 \begin_layout Labeling
21318 \labelwidthstring 00.00.0000
21319 SVN
21320 \begin_inset space ~
21321 \end_inset
21322
21323 commands: 
21324 \begin_inset space ~
21325 \end_inset
21326
21327
21328 \begin_inset Newline newline
21329 \end_inset
21330
21331
21332 \begin_inset Flex Code
21333 status collapsed
21334
21335 \begin_layout Plain Layout
21336 svn diff $path
21337 \end_layout
21338
21339 \end_inset
21340
21341  (Ask if changes are detected.)
21342 \begin_inset Newline newline
21343 \end_inset
21344
21345
21346 \begin_inset Flex Code
21347 status collapsed
21348
21349 \begin_layout Plain Layout
21350 svn update –accept mine-full $path
21351 \end_layout
21352
21353 \end_inset
21354
21355
21356 \end_layout
21357
21358 \begin_layout Standard
21359 where 
21360 \begin_inset Flex Code
21361 status collapsed
21362
21363 \begin_layout Plain Layout
21364 $path
21365 \end_layout
21366
21367 \end_inset
21368
21369  stands for the path to the document.
21370 \end_layout
21371
21372 \begin_layout Subsubsection
21373
21374 \family sans
21375 Show History
21376 \end_layout
21377
21378 \begin_layout Standard
21379 This shows the complete history of the SVN document.
21380  The output of 
21381 \family typewriter
21382 svn log 
21383 \begin_inset Quotes eld
21384 \end_inset
21385
21386 <file-name>
21387 \begin_inset Quotes erd
21388 \end_inset
21389
21390
21391 \family default
21392  is shown in a browser.
21393 \end_layout
21394
21395 \begin_layout Subsubsection
21396 File Locking
21397 \begin_inset CommandInset label
21398 LatexCommand label
21399 name "subsec:SVN-File-Locking"
21400
21401 \end_inset
21402
21403
21404 \end_layout
21405
21406 \begin_layout Standard
21407 The file exchange through various revision control systems brings the problem
21408  of merge conflicts in case two different users try to edit the same (parts
21409  of) document.
21410  When such a conflict happens it needs manual resolving and one reasonable
21411  alternative is to provide some kind of locking mechanism, which guarantees
21412  that only one user is allowed to edit file at the given time.
21413 \end_layout
21414
21415 \begin_layout Standard
21416 SVN has two such mechanisms to provide mutual exclusivity for file access
21417  - locks and automatic setting of write permissions (see sec.
21418  
21419 \begin_inset CommandInset ref
21420 LatexCommand ref
21421 reference "subsec:Automatical-Locking-Property"
21422
21423 \end_inset
21424
21425 ) based on 
21426 \begin_inset Flex Code
21427 status collapsed
21428
21429 \begin_layout Plain Layout
21430 svn:needs-lock
21431 \end_layout
21432
21433 \end_inset
21434
21435  file svn property
21436 \begin_inset Foot
21437 status open
21438
21439 \begin_layout Plain Layout
21440 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
21441 \end_layout
21442
21443 \end_inset
21444
21445 .
21446  If this property is detected for a given document \SpecialChar LyX
21447  starts to use SVN locks
21448  for document editing automatically and the whole check-in/out mechanism
21449  switches to the same regimen as for RCS.
21450  This in particular means there are two different modes of file use in \SpecialChar LyX
21451 :
21452 \end_layout
21453
21454 \begin_layout Itemize
21455 Unlocked state.
21456  The loaded file is in the read-only mode.
21457  For editing on needs to check-out.
21458  
21459 \emph on
21460 Check-out
21461 \emph default
21462  consists of updating from the repository and gaining write lock.
21463  If the lock is not possible to obtain, we remain in unlocked state.
21464 \end_layout
21465
21466 \begin_layout Itemize
21467 Locked state.
21468  The loaded file is in the 'normal' edit mode.
21469  No other user is allowed to edit the file.
21470  
21471 \emph on
21472 Check-in
21473 \emph default
21474  consists of commiting changes and releasing write-lock.
21475  If no changes have been made to the document, no commit will be produced
21476 \begin_inset Foot
21477 status collapsed
21478
21479 \begin_layout Plain Layout
21480 Don't be puzzled by the fact that you will be asked for commit message anyway.
21481 \end_layout
21482
21483 \end_inset
21484
21485  and only the write-lock will be released.
21486 \end_layout
21487
21488 \begin_layout Standard
21489 SVN commands:
21490 \end_layout
21491
21492 \begin_layout Labeling
21493 \labelwidthstring 00.00.0000
21494 Check-in:
21495 \family typewriter
21496  svn commit -q -m"<description>" "<file-name>"
21497 \begin_inset Newline newline
21498 \end_inset
21499
21500 svn unlock "<file-name>"
21501 \end_layout
21502
21503 \begin_layout Labeling
21504 \labelwidthstring 00.00.0000
21505 Check-out: 
21506 \family typewriter
21507 svn update "<file-name>"
21508 \begin_inset Newline newline
21509 \end_inset
21510
21511 svn lock "<file-name>"
21512 \end_layout
21513
21514 \begin_layout Subsubsection
21515
21516 \family typewriter
21517 \begin_inset CommandInset label
21518 LatexCommand label
21519 name "subsec:Automatical-Locking-Property"
21520
21521 \end_inset
21522
21523
21524 \family default
21525 Automatic Locking Property
21526 \end_layout
21527
21528 \begin_layout Standard
21529 The above mentioned automatic setting of write permissions of the .lyx file
21530  can be set through
21531 \family sans
21532 \bar under
21533  F
21534 \bar default
21535 ile\SpecialChar menuseparator
21536
21537 \bar under
21538 V
21539 \bar default
21540 ersion
21541 \begin_inset space ~
21542 \end_inset
21543
21544 Control\SpecialChar menuseparator
21545
21546 \bar under
21547 T
21548 \bar default
21549 oggle locking property
21550 \family default
21551 .
21552  This command is active only when the file is not locked on the svn server
21553  (i.e.
21554  you need to check-out before proceeding).
21555 \end_layout
21556
21557 \begin_layout Labeling
21558 \labelwidthstring 00.00.0000
21559 SVN
21560 \begin_inset space ~
21561 \end_inset
21562
21563 commands:
21564 \end_layout
21565
21566 \begin_layout Labeling
21567 \labelwidthstring 00.00.0000
21568 Set:
21569 \family typewriter
21570  svn propset svn:needs-lock ON "<file-name>"
21571 \end_layout
21572
21573 \begin_layout Labeling
21574 \labelwidthstring 00.00.0000
21575 Unset: 
21576 \family typewriter
21577 svn propdel svn:needs-lock "<file-name>"
21578 \end_layout
21579
21580 \begin_layout Subsubsection
21581 \begin_inset CommandInset label
21582 LatexCommand label
21583 name "subsec:VCS-Revision-Information"
21584
21585 \end_inset
21586
21587 Revision Information in Documents
21588 \end_layout
21589
21590 \begin_layout Standard
21591 There are more possibilities how to activate revision information in our
21592  document.
21593 \end_layout
21594
21595 \begin_layout Itemize
21596 \SpecialChar LyX
21597  supports directly:
21598 \begin_inset Separator parbreak
21599 \end_inset
21600
21601
21602 \end_layout
21603
21604 \begin_deeper
21605 \begin_layout Itemize
21606 tree revision information (
21607 \begin_inset Flex Code
21608 status collapsed
21609
21610 \begin_layout Plain Layout
21611 vcs-tree-revision
21612 \end_layout
21613
21614 \end_inset
21615
21616 ).
21617  The result is the output of the 
21618 \begin_inset Flex Code
21619 status collapsed
21620
21621 \begin_layout Plain Layout
21622 svnversion
21623 \end_layout
21624
21625 \end_inset
21626
21627  command, the following table gives you an idea, how to read the results.
21628 \end_layout
21629
21630 \begin_layout Standard
21631 \align center
21632 \begin_inset Tabular
21633 <lyxtabular version="3" rows="6" columns="2">
21634 <features tabularvalignment="middle">
21635 <column alignment="center" valignment="top">
21636 <column alignment="center" valignment="top">
21637 <row>
21638 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
21639 \begin_inset Text
21640
21641 \begin_layout Plain Layout
21642 Output
21643 \end_layout
21644
21645 \end_inset
21646 </cell>
21647 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
21648 \begin_inset Text
21649
21650 \begin_layout Plain Layout
21651 Meaning
21652 \end_layout
21653
21654 \end_inset
21655 </cell>
21656 </row>
21657 <row>
21658 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21659 \begin_inset Text
21660
21661 \begin_layout Plain Layout
21662 4123:4168
21663 \end_layout
21664
21665 \end_inset
21666 </cell>
21667 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21668 \begin_inset Text
21669
21670 \begin_layout Plain Layout
21671 mixed revision working copy
21672 \end_layout
21673
21674 \end_inset
21675 </cell>
21676 </row>
21677 <row>
21678 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21679 \begin_inset Text
21680
21681 \begin_layout Plain Layout
21682 4168M
21683 \end_layout
21684
21685 \end_inset
21686 </cell>
21687 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21688 \begin_inset Text
21689
21690 \begin_layout Plain Layout
21691 modified working copy
21692 \end_layout
21693
21694 \end_inset
21695 </cell>
21696 </row>
21697 <row>
21698 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21699 \begin_inset Text
21700
21701 \begin_layout Plain Layout
21702 4123S
21703 \end_layout
21704
21705 \end_inset
21706 </cell>
21707 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21708 \begin_inset Text
21709
21710 \begin_layout Plain Layout
21711 switched working copy
21712 \end_layout
21713
21714 \end_inset
21715 </cell>
21716 </row>
21717 <row>
21718 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
21719 \begin_inset Text
21720
21721 \begin_layout Plain Layout
21722 4123P
21723 \end_layout
21724
21725 \end_inset
21726 </cell>
21727 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21728 \begin_inset Text
21729
21730 \begin_layout Plain Layout
21731 partial working copy, from a sparse checkout
21732 \end_layout
21733
21734 \end_inset
21735 </cell>
21736 </row>
21737 <row>
21738 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
21739 \begin_inset Text
21740
21741 \begin_layout Plain Layout
21742 4123:4168MS
21743 \end_layout
21744
21745 \end_inset
21746 </cell>
21747 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
21748 \begin_inset Text
21749
21750 \begin_layout Plain Layout
21751 mixed revision, modified, switched working copy
21752 \end_layout
21753
21754 \end_inset
21755 </cell>
21756 </row>
21757 </lyxtabular>
21758
21759 \end_inset
21760
21761
21762 \end_layout
21763
21764 \begin_layout Itemize
21765 file revision information.
21766  The result comes from parsing the output of 
21767 \begin_inset Flex Code
21768 status collapsed
21769
21770 \begin_layout Plain Layout
21771 svn
21772 \begin_inset space ~
21773 \end_inset
21774
21775 info
21776 \begin_inset space ~
21777 \end_inset
21778
21779 –xml
21780 \begin_inset space ~
21781 \end_inset
21782
21783 file.lyx
21784 \end_layout
21785
21786 \end_inset
21787
21788 .
21789  Supported flags are:
21790 \begin_inset Separator parbreak
21791 \end_inset
21792
21793
21794 \end_layout
21795
21796 \begin_deeper
21797 \begin_layout Itemize
21798 version number of the last commit (
21799 \begin_inset Flex Code
21800 status collapsed
21801
21802 \begin_layout Plain Layout
21803 vcs-revision
21804 \end_layout
21805
21806 \end_inset
21807
21808 )
21809 \end_layout
21810
21811 \begin_layout Itemize
21812 author of the last commit (
21813 \begin_inset Flex Code
21814 status collapsed
21815
21816 \begin_layout Plain Layout
21817 vcs-author
21818 \end_layout
21819
21820 \end_inset
21821
21822 )
21823 \end_layout
21824
21825 \begin_layout Itemize
21826 date of the last commit (
21827 \begin_inset Flex Code
21828 status collapsed
21829
21830 \begin_layout Plain Layout
21831 vcs-date
21832 \end_layout
21833
21834 \end_inset
21835
21836 )
21837 \end_layout
21838
21839 \begin_layout Itemize
21840 time of the last commit (
21841 \begin_inset Flex Code
21842 status collapsed
21843
21844 \begin_layout Plain Layout
21845 vcs-time
21846 \end_layout
21847
21848 \end_inset
21849
21850 )
21851 \end_layout
21852
21853 \end_deeper
21854 \begin_layout Standard
21855 You can obtain this info via InsetInfo (e.g.
21856  
21857 \begin_inset Flex Code
21858 status collapsed
21859
21860 \begin_layout Plain Layout
21861 info-insert buffer vcs-date
21862 \end_layout
21863
21864 \end_inset
21865
21866 ).
21867  The information will be available only when you have the file stored under
21868  svn managment (i.e.
21869  the 
21870 \begin_inset Flex Code
21871 status collapsed
21872
21873 \begin_layout Plain Layout
21874 .svn
21875 \end_layout
21876
21877 \end_inset
21878
21879  directory is available with your document).
21880 \end_layout
21881
21882 \end_deeper
21883 \begin_layout Itemize
21884 Another—a hacking one—possibility is to use svn keywords
21885 \begin_inset Foot
21886 status collapsed
21887
21888 \begin_layout Plain Layout
21889 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
21890 \end_layout
21891
21892 \end_inset
21893
21894 .
21895  In short – you set file keywords property (e.g.
21896  
21897 \family sans
21898 svn propset svn:keywords 'Rev' file.lyx
21899 \family default
21900 ) and then paste keyword \SpecialChar TeX
21901  code
21902 \begin_inset Foot
21903 status collapsed
21904
21905 \begin_layout Plain Layout
21906 This is an easy way how to ensure that \SpecialChar LyX
21907  won't break the line in the middle
21908  of keyword tag.
21909 \end_layout
21910
21911 \end_inset
21912
21913  tag in your document (e.g.
21914  
21915 \begin_inset ERT
21916 status open
21917
21918 \begin_layout Plain Layout
21919
21920 $Rev$
21921 \end_layout
21922
21923 \end_inset
21924
21925 ).
21926  This way svn client will automatically substitute revision number (e.g.
21927  
21928 \begin_inset ERT
21929 status open
21930
21931 \begin_layout Plain Layout
21932
21933 $Rev: 59 $
21934 \end_layout
21935
21936 \end_inset
21937
21938 ) after each update and commit.
21939  There are more problems with this approach.
21940  Firstly, the '$' character is used in \SpecialChar TeX
21941  world for math equations, so any
21942  occurence of math formula 
21943 \begin_inset Formula $Rev$
21944 \end_inset
21945
21946  become 
21947 \begin_inset Formula $Rev:59$
21948 \end_inset
21949
21950  in your \SpecialChar LyX
21951  document.
21952  Similarly for other keywords like Id, Date, Author, etc.
21953  Secondly svn output is dependent on your locales, so its very easy that
21954  svn would produce some problematic strings once Date is used.
21955  Thirdly you get the whole 'Rev: 59' string in your document instead of
21956  the plain number.
21957  Until subversion implements user's custom keywords it will be hard to use
21958  this approach reliably or let \SpecialChar LyX
21959  to support it directly.
21960 \end_layout
21961
21962 \begin_layout Subsection
21963 SVN and Windows Environment
21964 \end_layout
21965
21966 \begin_layout Quote
21967 My inclination is to say that if the user cannot figure out the command
21968  line operations on their own fairly quickly, they would be well advised
21969  to use TortoiseSVN.
21970  —P.
21971  A.
21972  Rubin
21973 \end_layout
21974
21975 \begin_layout Subsubsection
21976 Preparation
21977 \end_layout
21978
21979 \begin_layout Standard
21980 In addition to installing \SpecialChar LyX
21981 , and having access to a Subversion repository,
21982  the user will need to install the Subversion client program.
21983  A Windows installer for the client program is available from 
21984 \begin_inset CommandInset href
21985 LatexCommand href
21986 name "CollabNet"
21987 target "http://www.collab.net/nonav/downloads/subversion/"
21988
21989 \end_inset
21990
21991 .
21992  The user may also want to install 
21993 \begin_inset CommandInset href
21994 LatexCommand href
21995 name "TortoiseSVN"
21996 target "http://tortoisesvn.tigris.org/"
21997
21998 \end_inset
21999
22000 , which integrates Subversion operations into the context (rightclick) menu
22001  of Windows Explorer.
22002  Operations done outside \SpecialChar LyX
22003  will typically be more convenient using the Explorer
22004  context menu.
22005  Note that TortoiseSVN is not a replacement for the client program, which
22006  is what \SpecialChar LyX
22007  itself will use.
22008 \end_layout
22009
22010 \begin_layout Subsubsection
22011 Bringing a document under Subversion control
22012 \end_layout
22013
22014 \begin_layout Standard
22015 Before a \SpecialChar LyX
22016  document can be brought under version control in Subversion, its
22017  parent directory needs to be under version control.
22018  If the document is being added to a project already in the repository,
22019  this is accomplished by checking the project out to the directory where
22020  the new document will be placed.
22021  If the project itself is not yet under version control (for instance, if
22022  this document starts a new project), the directory must be imported into
22023  the repository.
22024  This is done outside \SpecialChar LyX
22025 .
22026  Both import and checkout are easily accomplished from the Explorer context
22027  menu using TortoiseSVN, or alternatively can be done using the command
22028  line client at a DOS prompt.
22029  The procedure for importing the project using TortoiseSVN is described
22030  below, assuming an existing repository and a new project being started
22031  in 
22032 \family typewriter
22033 C:
22034 \backslash
22035 new project
22036 \family default
22037 .
22038  For information on using the Subversion client program, run 
22039 \family typewriter
22040 svn --help 
22041 \family default
22042 in a DOS shell.
22043 \end_layout
22044
22045 \begin_layout Enumerate
22046 Locate 
22047 \family typewriter
22048 C:
22049 \backslash
22050 new project 
22051 \family default
22052 in Windows Explorer, right click it, and select 
22053 \family sans
22054 TortoiseSVN\SpecialChar menuseparator
22055 Repo-browser
22056 \family default
22057 .
22058  If necessary, adjust the URL for the repository, then click OK.
22059 \end_layout
22060
22061 \begin_layout Enumerate
22062 Right click the level of the repository under which you want to place the
22063  new project folder (typically the top level) and click 
22064 \family sans
22065 Create folder
22066 \family default
22067  Supply a name for the project folder and click OK.
22068  Add a message for the log file if desired, then click OK again.
22069  The new project folder should appear in the repository.
22070  Finally, click OK again to exit the repository browser.
22071 \end_layout
22072
22073 \begin_layout Enumerate
22074 Once again right click 
22075 \family typewriter
22076 C:
22077 \backslash
22078 new project
22079 \family default
22080 , this time selecting SVN Checkout\SpecialChar ldots
22081  Select the URL of the project folder
22082  you just created in the repository, and set the checkout directory to 
22083 \family typewriter
22084 C:
22085 \backslash
22086 new project.
22087
22088 \family default
22089  Click OK.
22090  You will be warned about a non-empty folder; click OK to proceed.
22091  You should now have a 
22092 \family typewriter
22093 .svn
22094 \family default
22095  directory under 
22096 \family typewriter
22097 C:
22098 \backslash
22099 new project.
22100 \end_layout
22101
22102 \begin_layout Enumerate
22103 Create or open your document in \SpecialChar LyX
22104  and click 
22105 \family sans
22106 File\SpecialChar menuseparator
22107 Version
22108 \begin_inset space ~
22109 \end_inset
22110
22111 Control\SpecialChar menuseparator
22112 Register.
22113  
22114 \family default
22115 Add a log message and click OK to commit the document to version control.
22116 \end_layout
22117
22118 \begin_layout Standard
22119 From this point onward, you should have full functionality in the 
22120 \family sans
22121 File\SpecialChar menuseparator
22122 Version
22123 \begin_inset space ~
22124 \end_inset
22125
22126 Control
22127 \family default
22128  menu.
22129  You also have the option of checking the document in and out, viewing its
22130  history, etc.
22131  using the TortoiseSVN context menu in Windows Explorer or the Subversion
22132  client program from a command prompt.
22133 \end_layout
22134
22135 \begin_layout Subsubsection
22136 SSH tunnel used with SVN under Windows
22137 \end_layout
22138
22139 \begin_layout Standard
22140 Compared with Linux setting up an svn client to communicate over ssh under
22141  Windows is a rather troublesome task.
22142  We will at least offer some hints how to setup the client side but prior
22143  knowledge about ssh and the Windows command line is needed, also be prepared
22144  for a great deal of frustration\SpecialChar ldots
22145
22146 \end_layout
22147
22148 \begin_layout Enumerate
22149 Get an svn client for windows, as described in the previous sections.
22150  When it is a fresh install run some svn command (e.g.
22151  
22152 \begin_inset Flex Code
22153 status collapsed
22154
22155 \begin_layout Plain Layout
22156 svn –version
22157 \end_layout
22158
22159 \end_inset
22160
22161 ) to create config files, which you will need to change later on.
22162 \end_layout
22163
22164 \begin_layout Enumerate
22165 Choose an ssh client for Windows.
22166  There are several possibilities, we will use the one from Putty tools
22167 \begin_inset Foot
22168 status collapsed
22169
22170 \begin_layout Plain Layout
22171 \begin_inset Flex URL
22172 status collapsed
22173
22174 \begin_layout Plain Layout
22175
22176 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
22177 \end_layout
22178
22179 \end_inset
22180
22181
22182 \end_layout
22183
22184 \end_inset
22185
22186 .
22187  You will need to set the connection up so that the client doesn't ask for
22188  any password from you.
22189  To keep things easy we will use only keys without any additional password
22190  protection etc.
22191 \begin_inset Separator parbreak
22192 \end_inset
22193
22194
22195 \end_layout
22196
22197 \begin_deeper
22198 \begin_layout Enumerate
22199 Generate keys by 
22200 \begin_inset Flex Code
22201 status collapsed
22202
22203 \begin_layout Plain Layout
22204 puttygen
22205 \end_layout
22206
22207 \end_inset
22208
22209 .
22210  Save your private .ppk key file and put the public one on the server side.
22211  If the SVN server runs on Linux, note that the format of the public key
22212  is not compatible with Linux openssh and you will need to direcly copy-paste
22213  the key from the “
22214 \emph on
22215 Public key for pasting into OpenSSH authorized_keys file
22216 \emph default
22217 :” edit field into the server's 
22218 \begin_inset Flex Code
22219 status collapsed
22220
22221 \begin_layout Plain Layout
22222 ~/.ssh/authorized_keys
22223 \end_layout
22224
22225 \end_inset
22226
22227  / 
22228 \begin_inset Flex Code
22229 status collapsed
22230
22231 \begin_layout Plain Layout
22232 authorized_keys2
22233 \end_layout
22234
22235 \end_inset
22236
22237  file.
22238 \end_layout
22239
22240 \begin_layout Enumerate
22241 Get the Putty's 
22242 \begin_inset Flex Code
22243 status collapsed
22244
22245 \begin_layout Plain Layout
22246 plink
22247 \end_layout
22248
22249 \end_inset
22250
22251 .
22252  In the SVN config file
22253 \begin_inset Foot
22254 status collapsed
22255
22256 \begin_layout Plain Layout
22257 Exact path depends on Windows version, usually somewhere around 
22258 \begin_inset Flex Code
22259 status collapsed
22260
22261 \begin_layout Plain Layout
22262 c:
22263 \backslash
22264 Documents and Settings
22265 \backslash
22266 user
22267 \backslash
22268 Application Data
22269 \backslash
22270 Subversion
22271 \backslash
22272 config
22273 \end_layout
22274
22275 \end_inset
22276
22277  / 
22278 \begin_inset Flex Code
22279 status collapsed
22280
22281 \begin_layout Plain Layout
22282 AppData
22283 \backslash
22284 Roaming
22285 \backslash
22286 Subversion
22287 \end_layout
22288
22289 \end_inset
22290
22291 .
22292 \end_layout
22293
22294 \end_inset
22295
22296 , section [tunnels], setup ssh command, e.g.
22297  
22298 \begin_inset Flex Code
22299 status collapsed
22300
22301 \begin_layout Plain Layout
22302 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
22303 \end_layout
22304
22305 \end_inset
22306
22307 .
22308 \begin_inset Foot
22309 status collapsed
22310
22311 \begin_layout Plain Layout
22312 It will usually take a lot of time to get exact command right and it depends
22313  on many things.
22314  For example do not have some remote server saved as a default session in
22315  Putty etc.
22316  If things fail, try to connect via plink without SVN first.
22317 \end_layout
22318
22319 \end_inset
22320
22321
22322 \end_layout
22323
22324 \end_deeper
22325 \begin_layout Enumerate
22326 Checkout the SVN archive, e.
22327 \begin_inset space \thinspace{}
22328 \end_inset
22329
22330 g.
22331 \begin_inset Newline newline
22332 \end_inset
22333
22334
22335 \begin_inset Flex Code
22336 status collapsed
22337
22338 \begin_layout Plain Layout
22339 svn co svn+ssh://user@server/repository_path
22340 \end_layout
22341
22342 \end_inset
22343
22344 .
22345 \end_layout
22346
22347 \begin_layout Subsubsection
22348 End-of-Line Conversions
22349 \end_layout
22350
22351 \begin_layout Standard
22352 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
22353  will
22354  use different line endings inside the .lyx files.
22355  This is not a problem as far as \SpecialChar LyX
22356  functionality is concerned, but the commit
22357  diffs will be huge and merge-conflicts prone.
22358  Fortunately SVN itself knows
22359 \begin_inset Foot
22360 status collapsed
22361
22362 \begin_layout Plain Layout
22363 \begin_inset Flex URL
22364 status collapsed
22365
22366 \begin_layout Plain Layout
22367
22368 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
22369 \end_layout
22370
22371 \end_inset
22372
22373
22374 \end_layout
22375
22376 \end_inset
22377
22378  how to deal with CR/LF problems when switching .lyx files to the 
22379 \begin_inset Flex Code
22380 status collapsed
22381
22382 \begin_layout Plain Layout
22383 native
22384 \end_layout
22385
22386 \end_inset
22387
22388  mode.
22389 \begin_inset Foot
22390 status collapsed
22391
22392 \begin_layout Plain Layout
22393 For the lazy guys: 
22394 \begin_inset Flex Code
22395 status collapsed
22396
22397 \begin_layout Plain Layout
22398 svn propset svn:eol-style native FILE_NAME
22399 \end_layout
22400
22401 \end_inset
22402
22403
22404 \end_layout
22405
22406 \end_inset
22407
22408
22409 \end_layout
22410
22411 \begin_layout Subsection
22412 GIT commands in \SpecialChar LyX
22413
22414 \end_layout
22415
22416 \begin_layout Standard
22417 A minimal subset of GIT commands is now supported by \SpecialChar LyX
22418 .
22419  You can find the commands in the 
22420 \family sans
22421 File\SpecialChar menuseparator
22422 Version
22423 \begin_inset space ~
22424 \end_inset
22425
22426 Control
22427 \family default
22428  submenu.
22429  Please note that if you use password protected access to repository via
22430  ssh, you will be asked in terminal window.
22431  \SpecialChar LyX
22432  was tested against GIT 1.7.
22433 \begin_inset Foot
22434 status open
22435
22436 \begin_layout Plain Layout
22437 Windows users please note that you need to ensure that git is on the path.
22438  This can be set from within \SpecialChar LyX
22439  at 
22440 \family sans
22441 Tools\SpecialChar menuseparator
22442 Preferences\SpecialChar menuseparator
22443 Paths\SpecialChar menuseparator
22444 PATH prefix
22445 \family default
22446 .
22447 \end_layout
22448
22449 \end_inset
22450
22451
22452 \end_layout
22453
22454 \begin_layout Standard
22455 One big difference of GIT and the other supported version control systems
22456  is the distributed nature of GIT: With traditional version control systems
22457  there is one central server which hosts the repository.
22458  Users commit their changes to the server, and get updates made by other
22459  users from it.
22460  With GIT, users commit to a local repository.
22461  The local repository can be synchronized with one or more remote repositories
22462  using the 
22463 \begin_inset Flex Code
22464 status collapsed
22465
22466 \begin_layout Plain Layout
22467 pull
22468 \end_layout
22469
22470 \end_inset
22471
22472  and 
22473 \begin_inset Flex Code
22474 status collapsed
22475
22476 \begin_layout Plain Layout
22477 push
22478 \end_layout
22479
22480 \end_inset
22481
22482  GIT commands.
22483  \SpecialChar LyX
22484  does not interact in any way with remote GIT repositories.
22485  It works exclusively with the local repository in a very similar way as
22486  with a central CVS or SVN repository.
22487  If you use remote GIT repositories you need to do the 
22488 \begin_inset Flex Code
22489 status collapsed
22490
22491 \begin_layout Plain Layout
22492 pull
22493 \end_layout
22494
22495 \end_inset
22496
22497  and 
22498 \begin_inset Flex Code
22499 status collapsed
22500
22501 \begin_layout Plain Layout
22502 push
22503 \end_layout
22504
22505 \end_inset
22506
22507  operations with your favourite GIT client.
22508 \end_layout
22509
22510 \begin_layout Subsubsection
22511
22512 \family sans
22513 Register
22514 \end_layout
22515
22516 \begin_layout Standard
22517 If your document is not under revision control, this is the only item shown
22518  in the menu.
22519  And if it is under revision control, the 
22520 \family sans
22521 \bar under
22522 R
22523 \bar default
22524 egister
22525 \family default
22526  item is not visible.
22527 \end_layout
22528
22529 \begin_layout Standard
22530 This command registers in GIT your document ONLY in case you have already
22531  the documents directory under GIT control (in particular 
22532 \family typewriter
22533 .git/index
22534 \family default
22535  file exists).
22536  This means you have to checkout the archive by yourself.
22537 \end_layout
22538
22539 \begin_layout Standard
22540 Then you are asked interactively to supply an initial description of the
22541  document.
22542  Don't forget that registered file is not yet commited.
22543 \end_layout
22544
22545 \begin_layout Standard
22546 GIT command that is run: 
22547 \family typewriter
22548 git add 
22549 \begin_inset Quotes eld
22550 \end_inset
22551
22552 <file-name>
22553 \begin_inset Quotes erd
22554 \end_inset
22555
22556
22557 \end_layout
22558
22559 \begin_layout Standard
22560 Read 
22561 \family typewriter
22562 man git
22563 \family default
22564  to understand the switches.
22565 \end_layout
22566
22567 \begin_layout Subsubsection
22568
22569 \family sans
22570 Check In Changes
22571 \end_layout
22572
22573 \begin_layout Standard
22574 When you are finished editing a file, you commit your changes.
22575  When you do this, you are asked for a description of the changes.
22576  After that changes are commited.
22577 \end_layout
22578
22579 \begin_layout Standard
22580 GIT command: 
22581 \family typewriter
22582 git commit -q -m"<description>" <file-name>
22583 \end_layout
22584
22585 \begin_layout Subsubsection
22586
22587 \family sans
22588 Revert To Repository Version
22589 \end_layout
22590
22591 \begin_layout Standard
22592 This will discard all changes made to the document since the last check
22593  in.
22594  You get a warning before changes are discarded.
22595 \end_layout
22596
22597 \begin_layout Standard
22598 GIT command: 
22599 \family typewriter
22600 git checkout -q 
22601 \begin_inset Quotes eld
22602 \end_inset
22603
22604 <file-name>
22605 \begin_inset Quotes erd
22606 \end_inset
22607
22608
22609 \end_layout
22610
22611 \begin_layout Subsubsection
22612
22613 \family sans
22614 Rename
22615 \end_layout
22616
22617 \begin_layout Standard
22618 This will rename the current document including the version history.
22619  It requires a clean document without any changes since the last checkin.
22620  You are asked for a file name and a description of the rename operation.
22621  After that the document is renamed, both locally and in the repository.
22622  If the parent directories of the new and old file names differ, all relative
22623  paths of included files are adjusted (like in 
22624 \family sans
22625 File\SpecialChar menuseparator
22626 Save As
22627 \family default
22628 \SpecialChar ldots
22629 ).
22630  Finally, the document is reloaded using the new name.
22631 \end_layout
22632
22633 \begin_layout Labeling
22634 \labelwidthstring 00.00.0000
22635 GIT
22636 \begin_inset space ~
22637 \end_inset
22638
22639 commands: 
22640 \begin_inset space ~
22641 \end_inset
22642
22643
22644 \begin_inset Newline newline
22645 \end_inset
22646
22647
22648 \begin_inset Flex Code
22649 status collapsed
22650
22651 \begin_layout Plain Layout
22652 git mv 
22653 \family typewriter
22654
22655 \begin_inset Quotes eld
22656 \end_inset
22657
22658 <file-name>
22659 \begin_inset Quotes erd
22660 \end_inset
22661
22662  
22663 \begin_inset Quotes eld
22664 \end_inset
22665
22666 <new-file-name>
22667 \begin_inset Quotes erd
22668 \end_inset
22669
22670
22671 \end_layout
22672
22673 \end_inset
22674
22675
22676 \begin_inset Newline newline
22677 \end_inset
22678
22679
22680 \begin_inset Flex Code
22681 status collapsed
22682
22683 \begin_layout Plain Layout
22684 git commit
22685 \end_layout
22686
22687 \end_inset
22688
22689
22690 \end_layout
22691
22692 \begin_layout Subsubsection
22693
22694 \family sans
22695 Show History
22696 \end_layout
22697
22698 \begin_layout Standard
22699 This shows the complete history of the GIT document.
22700  The output of 
22701 \family typewriter
22702 git log 
22703 \begin_inset Quotes eld
22704 \end_inset
22705
22706 <file-name>
22707 \begin_inset Quotes erd
22708 \end_inset
22709
22710
22711 \family default
22712  is shown in a browser.
22713 \end_layout
22714
22715 \begin_layout Subsubsection
22716 Version Info
22717 \end_layout
22718
22719 \begin_layout Standard
22720 \SpecialChar LyX
22721  supports GIT hash number of the last commit to the file, author name, date
22722  and time of last commit.
22723  All those are extracted from 
22724 \family typewriter
22725 git log -n 1 --pretty=format:%H%n%an%n%ai
22726 \family default
22727 .
22728  Tree version information is obtained via 
22729 \family typewriter
22730 git describe --abbrev --dirty --long
22731 \family default
22732 .
22733  See 
22734 \begin_inset CommandInset ref
22735 LatexCommand ref
22736 reference "subsec:VCS-Revision-Information"
22737
22738 \end_inset
22739
22740  for other details.
22741 \end_layout
22742
22743 \begin_layout Subsection
22744 Further tuning
22745 \end_layout
22746
22747 \begin_layout Standard
22748 With the recent addition of the vc-command function \SpecialChar LyX
22749  power users are allowed
22750  to create their own commands for revision control.
22751 \end_layout
22752
22753 \begin_layout Standard
22754 As an example you can see how two TortoiseSVN commands could be integrated
22755  directly:
22756 \end_layout
22757
22758 \begin_layout Description
22759 Commit: 
22760 \begin_inset Flex Code
22761 status collapsed
22762
22763 \begin_layout Plain Layout
22764 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
22765 \end_layout
22766
22767 \end_inset
22768
22769
22770 \end_layout
22771
22772 \begin_layout Description
22773 Revert: 
22774 \begin_inset Flex Code
22775 status collapsed
22776
22777 \begin_layout Plain Layout
22778 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
22779 \end_layout
22780
22781 \end_inset
22782
22783
22784 \end_layout
22785
22786 \begin_layout Subsection
22787 Version control and Document comparison
22788 \end_layout
22789
22790 \begin_layout Standard
22791 One of the typical uses of version control is to inspect the changes between
22792  revisions, usually by creating 
22793 \begin_inset Flex Code
22794 status collapsed
22795
22796 \begin_layout Plain Layout
22797 diff
22798 \end_layout
22799
22800 \end_inset
22801
22802  dumps.
22803  While this is useful for plain text files, it is much less useful in the
22804  case of \SpecialChar LyX
22805  files, which have more a complicated structure.
22806  Hence we provide binding to the Document comparison feature.
22807  There are two ways of calling this feature - either by direct call of 
22808 \begin_inset Flex Code
22809 status collapsed
22810
22811 \begin_layout Plain Layout
22812 VC_COMPARE
22813 \end_layout
22814
22815 \end_inset
22816
22817  \SpecialChar LyX
22818  function (for details see \SpecialChar LyX
22819  functions manual) or by icon/menu item 
22820 \begin_inset Flex Noun
22821 status collapsed
22822
22823 \begin_layout Plain Layout
22824 Compare with older revision...
22825 \end_layout
22826
22827 \end_inset
22828
22829 .
22830  One can either compare two chosen revisions of the document or he can simply
22831  compare the current version of edited text with older revisions (where
22832  '
22833 \begin_inset Flex Noun
22834 status collapsed
22835
22836 \begin_layout Plain Layout
22837 0
22838 \end_layout
22839
22840 \end_inset
22841
22842 ' revisions back means comparison of the edited file with last commited
22843  revision).
22844  
22845 \end_layout
22846
22847 \begin_layout Standard
22848 This feature is supported for SVN and RCS though due to the more complicated
22849  versioning scheme of RCS there is a constraint – when addressing the revisions
22850  in dialog, numbers always point to the last number in RCS revision number,
22851  i.e.
22852  '35' in '1.2.35'.
22853  We don't currently support GIT addressing of revisions, one can just compare
22854  edited document with its revision X steps backs, where X is addressed as
22855  HEAD~X.
22856 \end_layout
22857
22858 \begin_layout Section
22859 Literate Programming
22860 \end_layout
22861
22862 \begin_layout Standard
22863 Updated by 
22864 \noun on
22865 Kayvan Sylvan 
22866 \noun default
22867 (kayvan@sylvan.com)
22868 \noun on
22869
22870 \noun default
22871 original documentation written by 
22872 \noun on
22873 Edmar Wienskoski Jr.
22874
22875 \noun default
22876  (edmar-w-jr@technologist.com)
22877 \end_layout
22878
22879 \begin_layout Subsection
22880 Introduction
22881 \end_layout
22882
22883 \begin_layout Standard
22884 The main purpose of this documentation is to show you how to use \SpecialChar LyX
22885  for literate
22886  programming, where it is assumed that you are familiar with this programming
22887  technique, and know what 
22888 \begin_inset Quotes eld
22889 \end_inset
22890
22891 tangling
22892 \begin_inset Quotes erd
22893 \end_inset
22894
22895  and 
22896 \begin_inset Quotes eld
22897 \end_inset
22898
22899 weaving
22900 \begin_inset Quotes erd
22901 \end_inset
22902
22903  means.
22904  If that is not the case, please follow the web links provided in the following
22905  sections.
22906  There is a lot of good documentation out there covering old development
22907  history to the latest tools tips.
22908 \end_layout
22909
22910 \begin_layout Standard
22911 It is also assumed that you are familiar with \SpecialChar LyX
22912  itself to a point that you
22913  are comfortable changing your \SpecialChar LyX
22914  preferences, and X resources file.
22915  If that is not the case please refer to other \SpecialChar LyX
22916  documentation to cover your
22917  specific needs.
22918 \end_layout
22919
22920 \begin_layout Subsection
22921 Literate Programming
22922 \end_layout
22923
22924 \begin_layout Standard
22925 From the Literate Programming FAQ: 
22926 \end_layout
22927
22928 \begin_layout Quotation
22929 Literate programming is the combination of documentation and source together
22930  in a fashion suited for reading by human beings.
22931  In fact, literate programs should be enjoyable reading, even inviting!
22932  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
22933  and documentation in a single file.
22934  Literate programming tools then parse the file to produce either readable
22935  documentation or compilable source.
22936  The WEB style of literate programming was created by D.
22937 \begin_inset space \thinspace{}
22938 \end_inset
22939
22940 E.
22941  Knuth during the development of his \SpecialChar TeX
22942  typesetting software.
22943  
22944 \end_layout
22945
22946 \begin_layout Standard
22947 Another excerpt says:
22948 \end_layout
22949
22950 \begin_layout Quotation
22951
22952 \emph on
22953 How is literate programming different from verbose commenting?
22954 \end_layout
22955
22956 \begin_layout Quotation
22957 There are three distinguishing characteristics.
22958  In order of importance, they are: 
22959 \begin_inset Separator parbreak
22960 \end_inset
22961
22962
22963 \end_layout
22964
22965 \begin_deeper
22966 \begin_layout Itemize
22967 flexible order of elaboration 
22968 \end_layout
22969
22970 \begin_layout Itemize
22971 automatic support for browsing 
22972 \end_layout
22973
22974 \begin_layout Itemize
22975 typeset documentation, especially diagrams and mathematics 
22976 \end_layout
22977
22978 \end_deeper
22979 \begin_layout Standard
22980 Now that I sparked your curiosity, take a look in the references.
22981 \end_layout
22982
22983 \begin_layout Subsubsection
22984 References
22985 \end_layout
22986
22987 \begin_layout Standard
22988 The complete Literate Programming FAQ can be found at:
22989 \end_layout
22990
22991 \begin_layout Quote
22992 Literate Programming FAQ 
22993 \begin_inset Flex URL
22994 status collapsed
22995
22996 \begin_layout Plain Layout
22997
22998 http://www.literateprogramming.com/lpfaq.pdf
22999 \end_layout
23000
23001 \end_inset
23002
23003
23004 \end_layout
23005
23006 \begin_layout Standard
23007 The FAQ lists 23 (twenty three!) different literate programming tools.
23008  Where some are specialized or 
23009 \begin_inset Quotes eld
23010 \end_inset
23011
23012 tailored
23013 \begin_inset Quotes erd
23014 \end_inset
23015
23016  for particular programming languages, while other have general scope.
23017  I selected 
23018 \noun on
23019 Noweb
23020 \noun default
23021  for my own use for several reasons:
23022 \end_layout
23023
23024 \begin_layout Itemize
23025 It can generate the documentation either in \SpecialChar LaTeX
23026  or HTML.
23027 \end_layout
23028
23029 \begin_layout Itemize
23030 It has a open architecture, i.
23031 \begin_inset space \thinspace{}
23032 \end_inset
23033
23034 e.
23035 \begin_inset space \space{}
23036 \end_inset
23037
23038 it is easy to plug in new filters and to perform special processing that
23039  you may need.
23040  
23041 \end_layout
23042
23043 \begin_layout Itemize
23044 There is a good selection of filters available already (the HTML is one
23045  of them).
23046 \end_layout
23047
23048 \begin_layout Itemize
23049 It is free.
23050 \end_layout
23051
23052 \begin_layout Standard
23053 The Noweb web page can be found at: 
23054 \end_layout
23055
23056 \begin_layout Quote
23057 Noweb home page 
23058 \begin_inset Flex URL
23059 status collapsed
23060
23061 \begin_layout Plain Layout
23062
23063 http://www.cs.virginia.edu/~nr/noweb/
23064 \end_layout
23065
23066 \end_inset
23067
23068
23069 \end_layout
23070
23071 \begin_layout Standard
23072 Starting from there you can reach many other interesting links and even
23073  some literate program examples.
23074 \end_layout
23075
23076 \begin_layout Subsection
23077 \SpecialChar LyX
23078  and Literate Programming with Noweb
23079 \end_layout
23080
23081 \begin_layout Standard
23082 The \SpecialChar LyX
23083  support for Literate Programming is provided by using the generic \SpecialChar LyX
23084
23085  converters mechanism.
23086  This support is provided in a 
23087 \begin_inset Quotes eld
23088 \end_inset
23089
23090 Noweb independent
23091 \begin_inset Quotes erd
23092 \end_inset
23093
23094  way, i.
23095 \begin_inset space \thinspace{}
23096 \end_inset
23097
23098 e.
23099 \begin_inset space \space{}
23100 \end_inset
23101
23102 you will be able to use this new \SpecialChar LyX
23103  feature with some other literate programming
23104  tool of your choice by just changing your \SpecialChar LyX
23105  preferences.
23106 \end_layout
23107
23108 \begin_layout Subsubsection
23109 Generating documents and code (weaving and tangling)
23110 \end_layout
23111
23112 \begin_layout Paragraph
23113 Using the noweb module
23114 \end_layout
23115
23116 \begin_layout Standard
23117 If you have installed Noweb and \SpecialChar LyX
23118  successfully, whenever you open a new document,
23119  after you have chosen its document class, use the Document->Settings menu
23120  to add the 
23121 \begin_inset Quotes eld
23122 \end_inset
23123
23124 noweb
23125 \begin_inset Quotes erd
23126 \end_inset
23127
23128  module.
23129  If Noweb is correctly installed, when you click on the 
23130 \begin_inset Quotes eld
23131 \end_inset
23132
23133 Modules
23134 \begin_inset Quotes erd
23135 \end_inset
23136
23137  link, you will see the 
23138 \begin_inset Quotes eld
23139 \end_inset
23140
23141 noweb
23142 \begin_inset Quotes erd
23143 \end_inset
23144
23145  module in the available list and you can add it to your document.
23146 \end_layout
23147
23148 \begin_layout Paragraph
23149 Typing code in
23150 \end_layout
23151
23152 \begin_layout Standard
23153 \SpecialChar LyX
23154  enables you to write code with a layout named 
23155 \begin_inset Flex Noun
23156 status collapsed
23157
23158 \begin_layout Plain Layout
23159 Chunk
23160 \end_layout
23161
23162 \end_inset
23163
23164 .
23165  Noweb delimits chunks like this:
23166 \end_layout
23167
23168 \begin_layout LyX-Code
23169 <<My code>>=
23170 \end_layout
23171
23172 \begin_layout LyX-Code
23173   code
23174 \end_layout
23175
23176 \begin_layout LyX-Code
23177   more code
23178 \end_layout
23179
23180 \begin_layout LyX-Code
23181   even more code
23182 \end_layout
23183
23184 \begin_layout LyX-Code
23185   @
23186 \end_layout
23187
23188 \begin_layout Standard
23189 The problem is that whatever is written in between the << and the 
23190 \family typewriter
23191 @
23192 \family default
23193  must be taken literally, i.
23194 \begin_inset space \thinspace{}
23195 \end_inset
23196
23197 e.
23198 \begin_inset space \space{}
23199 \end_inset
23200
23201 \SpecialChar LyX
23202  should be prevented from making any special interpretation of what has
23203  been written.
23204  This is also handled by 
23205 \begin_inset Flex Noun
23206 status collapsed
23207
23208 \begin_layout Plain Layout
23209 Chunk
23210 \end_layout
23211
23212 \end_inset
23213
23214 , that works like a normal paragraph but has a free spacing capability.
23215 \end_layout
23216
23217 \begin_layout Standard
23218 As a special note, you can also use the 
23219 \begin_inset Quotes eld
23220 \end_inset
23221
23222 %def
23223 \begin_inset Quotes erd
23224 \end_inset
23225
23226  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
23227 rence:
23228 \end_layout
23229
23230 \begin_layout LyX-Code
23231 <<My chunk>>=
23232 \end_layout
23233
23234 \begin_layout LyX-Code
23235 def some_function(args):
23236 \end_layout
23237
23238 \begin_layout LyX-Code
23239    "This is the doc string for this function."
23240 \end_layout
23241
23242 \begin_layout LyX-Code
23243    print "My args: ", args
23244 \end_layout
23245
23246 \begin_layout LyX-Code
23247 @ %def some_function
23248 \end_layout
23249
23250 \begin_layout Standard
23251 For an example of this usage and the resulting cross-reference output, look
23252  at the Literate python program in 
23253 \emph on
23254 LIBDIR/examples/listerrors.lyx
23255 \emph default
23256  which should make this all clear.
23257 \end_layout
23258
23259 \begin_layout Paragraph
23260 Generating the documentation
23261 \end_layout
23262
23263 \begin_layout Standard
23264 At this point you already have a new document file with a proper document
23265  class, and with some code and text on it.
23266  How do I print it? The answer is simple, you select 
23267 \family sans
23268 View\SpecialChar menuseparator
23269 DVI,
23270 \family default
23271  etc.
23272  Just like you would do for a plain document.
23273  No special procedure is required.
23274 \end_layout
23275
23276 \begin_layout Standard
23277 To help orientate you, I will now explain what happens inside \SpecialChar LyX
23278 :
23279 \end_layout
23280
23281 \begin_layout Enumerate
23282 When the 
23283 \family sans
23284 Update\SpecialChar menuseparator
23285 DVI
23286 \family default
23287  menu option is chosen, a \SpecialChar LaTeX
23288  file is generated.
23289  
23290 \begin_inset Separator parbreak
23291 \end_inset
23292
23293
23294 \end_layout
23295
23296 \begin_deeper
23297 \begin_layout Standard
23298 If the document is of any literate class the generated file will be named
23299  with an extension name defined by the 
23300 \begin_inset Quotes eld
23301 \end_inset
23302
23303 literate
23304 \begin_inset Quotes erd
23305 \end_inset
23306
23307  format (defined in the Preferences panel), otherwise the file will have
23308  the usual 
23309 \family typewriter
23310 .tex
23311 \family default
23312  extension.
23313 \end_layout
23314
23315 \end_deeper
23316 \begin_layout Enumerate
23317 Note that the only difference so far is in the name of the file, no special
23318  processing is required by \SpecialChar LyX
23319 .
23320  Given that you formatted the code using the 
23321 \begin_inset Flex Noun
23322 status collapsed
23323
23324 \begin_layout Plain Layout
23325 Chunk
23326 \end_layout
23327
23328 \end_inset
23329
23330  layout that, by itself, takes care of the business.
23331 \end_layout
23332
23333 \begin_layout Enumerate
23334 If the document is of any literate class \SpecialChar LyX
23335  will then use the internal \SpecialChar LyX
23336  to
23337  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
23338  converter
23339 \begin_inset Foot
23340 status collapsed
23341
23342 \begin_layout Plain Layout
23343 The converters are defined in the 
23344 \family sans
23345 Tools\SpecialChar menuseparator
23346 Preferences
23347 \family default
23348  panel, under the 
23349 \begin_inset Quotes eld
23350 \end_inset
23351
23352 Conversion
23353 \begin_inset Quotes erd
23354 \end_inset
23355
23356  tab.
23357  See section 
23358 \emph on
23359 Converters
23360 \emph default
23361  of the 
23362 \emph on
23363 Customization
23364 \emph default
23365  manual for general information about converters.
23366 \end_layout
23367
23368 \end_inset
23369
23370  to generate the \SpecialChar LaTeX
23371  file.
23372 \begin_inset Separator parbreak
23373 \end_inset
23374
23375
23376 \end_layout
23377
23378 \begin_deeper
23379 \begin_layout Standard
23380 Otherwise it will just skip this step.
23381 \end_layout
23382
23383 \end_deeper
23384 \begin_layout Enumerate
23385 Finally, \SpecialChar LaTeX
23386  is invoked and the regular post processing continues as in a plain
23387  document.
23388 \end_layout
23389
23390 \begin_layout Standard
23391 Independence from a particular 
23392 \begin_inset Quotes eld
23393 \end_inset
23394
23395 literate tool
23396 \begin_inset Quotes erd
23397 \end_inset
23398
23399  is easily achieved by changing the commands that are run by the various
23400  converters.
23401 \end_layout
23402
23403 \begin_layout Paragraph
23404 Generating the code
23405 \end_layout
23406
23407 \begin_layout Standard
23408 When the build menu option is chosen or the corresponding button in the
23409  toolbar is pressed, a \SpecialChar LaTeX
23410  file is generated just like step 1 above.
23411  Next, \SpecialChar LyX
23412  invokes the 
23413 \family typewriter
23414 Noweb->Program
23415 \family default
23416  converter.
23417  This converter needs to be defined by the user and is not installed by
23418  default, though the Program format is.
23419  This converter (like any other converter) will have two parts:
23420 \end_layout
23421
23422 \begin_layout Enumerate
23423 The converter program itself.
23424  This program performs the conversion from the one format to the other (in
23425  this case, from the Noweb format to the Program pseudo-format).
23426 \end_layout
23427
23428 \begin_layout Enumerate
23429 The error log parser.
23430  This is a program whose sole purpose is to rewrite error messages in a
23431  format that \SpecialChar LyX
23432  understands.
23433  This makes it possible for \SpecialChar LyX
23434  to place error boxes in the right places in
23435  the file buffer.
23436 \end_layout
23437
23438 \begin_layout Standard
23439 The first part, the 
23440 \begin_inset Quotes eld
23441 \end_inset
23442
23443 Converter
23444 \begin_inset Quotes erd
23445 \end_inset
23446
23447  setting, should be set to
23448 \begin_inset Newline newline
23449 \end_inset
23450
23451
23452 \begin_inset Quotes eld
23453 \end_inset
23454
23455
23456 \family typewriter
23457 build-script $$i
23458 \family default
23459  $$r
23460 \begin_inset Quotes erd
23461 \end_inset
23462
23463 .
23464 \begin_inset Newline newline
23465 \end_inset
23466
23467 This basically means that \SpecialChar LyX
23468  will call 
23469 \begin_inset Quotes eld
23470 \end_inset
23471
23472 build-script
23473 \begin_inset Quotes erd
23474 \end_inset
23475
23476  (a program or script) with the name of the Noweb file (normally a file
23477  in the \SpecialChar LyX
23478  temp directory) and the directory path of the original \SpecialChar LyX
23479  file.
23480  
23481 \end_layout
23482
23483 \begin_layout Standard
23484 This is an implementation of 
23485 \begin_inset Quotes eld
23486 \end_inset
23487
23488 build-script
23489 \begin_inset Quotes erd
23490 \end_inset
23491
23492  that you can place in a directory on your path:
23493 \end_layout
23494
23495 \begin_layout Standard
23496 \begin_inset VSpace defskip
23497 \end_inset
23498
23499
23500 \end_layout
23501
23502 \begin_layout Standard
23503 \begin_inset Newpage pagebreak
23504 \end_inset
23505
23506
23507 \end_layout
23508
23509 \begin_layout Standard
23510
23511 \family sans
23512 #!/bin/sh
23513 \end_layout
23514
23515 \begin_layout Standard
23516
23517 \family sans
23518 #
23519 \end_layout
23520
23521 \begin_layout Standard
23522
23523 \family sans
23524 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
23525 \end_layout
23526
23527 \begin_layout Standard
23528 \begin_inset VSpace defskip
23529 \end_inset
23530
23531
23532 \end_layout
23533
23534 \begin_layout Standard
23535 The next part of the converter setting is the 
23536 \begin_inset Quotes eld
23537 \end_inset
23538
23539 Flags
23540 \begin_inset Quotes erd
23541 \end_inset
23542
23543  which is to be set to
23544 \begin_inset Newline newline
23545 \end_inset
23546
23547
23548 \begin_inset Quotes eld
23549 \end_inset
23550
23551
23552 \family typewriter
23553 parselog=$$s/scripts/listerrors
23554 \family default
23555
23556 \begin_inset Quotes erd
23557 \end_inset
23558
23559 .
23560 \begin_inset Newline newline
23561 \end_inset
23562
23563 This will run any errors that are generated by the 
23564 \begin_inset Quotes eld
23565 \end_inset
23566
23567 build-script
23568 \begin_inset Quotes erd
23569 \end_inset
23570
23571  process through the 
23572 \begin_inset Quotes eld
23573 \end_inset
23574
23575 listerrors
23576 \begin_inset Quotes erd
23577 \end_inset
23578
23579  program.
23580 \end_layout
23581
23582 \begin_layout Standard
23583 The build will normally take place in \SpecialChar LyX
23584 's temporary directory, so the files
23585  produced by the conversion will be in that directory.
23586  \SpecialChar LyX
23587  will copy out what it regards as the `main' file, but the 
23588 \family typewriter
23589 Noweb->Program
23590 \family default
23591  conversion may produce several files, and so most of these would then be
23592  deleted when \SpecialChar LyX
23593  was closed.
23594  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
23595  the build-script chunk can place the generated files in that location.
23596 \end_layout
23597
23598 \begin_layout Paragraph
23599 Build instructions in the document
23600 \end_layout
23601
23602 \begin_layout Standard
23603 The last piece of the integration between \SpecialChar LyX
23604  and noweb is the 
23605 \begin_inset Quotes eld
23606 \end_inset
23607
23608 build-script
23609 \begin_inset Quotes erd
23610 \end_inset
23611
23612  chunk.
23613  Generally, the instructions for building your program should be embedded
23614  in a chunk of its own.
23615  The noweb-specific 
23616 \begin_inset Quotes eld
23617 \end_inset
23618
23619 build-script
23620 \begin_inset Quotes erd
23621 \end_inset
23622
23623  above uses the notangle command to look for this chunk (called 
23624 \begin_inset Quotes eld
23625 \end_inset
23626
23627 build-script
23628 \begin_inset Quotes erd
23629 \end_inset
23630
23631 ) and runs its contents through 
23632 \begin_inset Quotes eld
23633 \end_inset
23634
23635 sh
23636 \begin_inset Quotes erd
23637 \end_inset
23638
23639 .
23640 \end_layout
23641
23642 \begin_layout Standard
23643 Typically, such a chunk would look something like this:
23644 \end_layout
23645
23646 \begin_layout LyX-Code
23647 <<build-script>>=
23648 \end_layout
23649
23650 \begin_layout LyX-Code
23651 #!/bin/sh
23652 \begin_inset Newline newline
23653 \end_inset
23654
23655 if [ -z "${NOWEB_SOURCE}" ]
23656 \begin_inset Newline newline
23657 \end_inset
23658
23659 then
23660 \end_layout
23661
23662 \begin_layout LyX-Code
23663 NOWEB_SOURCE=myfile.nw
23664 \begin_inset Newline newline
23665 \end_inset
23666
23667 fi
23668 \begin_inset Newline newline
23669 \end_inset
23670
23671 [...
23672  code to extract files ...
23673  use NOWEB_OUTPUT_DIR here ...]
23674 \begin_inset Newline newline
23675 \end_inset
23676
23677 [...
23678  code to compile files ...]
23679 \begin_inset Newline newline
23680 \end_inset
23681
23682 @
23683 \end_layout
23684
23685 \begin_layout Standard
23686 Look in 
23687 \emph on
23688 LIBDIR/examples/listerrors.lyx
23689 \emph default
23690  or in 
23691 \emph on
23692 LIBDIR/examples/Literate.lyx
23693 \emph default
23694  which implement two versions of the 
23695 \begin_inset Quotes eld
23696 \end_inset
23697
23698 listerrors
23699 \begin_inset Quotes erd
23700 \end_inset
23701
23702  program for some illustrations of how all of these pieces go together or
23703  in 
23704 \emph on
23705 LIBDIR/examples/noweb2lyx.lyx.
23706
23707 \emph default
23708  Interestingly, these three files show off the language-indepence of the
23709  \SpecialChar LyX
23710  literate programming support since they are written in Python, C and Perl
23711  respectively.
23712 \end_layout
23713
23714 \begin_layout Subsubsection
23715 Configuring \SpecialChar LyX
23716
23717 \end_layout
23718
23719 \begin_layout Standard
23720 All the Literate Programming support is configured by the 
23721 \family sans
23722 Tools\SpecialChar menuseparator
23723 Preferences
23724 \family default
23725  panel in the 
23726 \begin_inset Quotes eld
23727 \end_inset
23728
23729 File Handling
23730 \begin_inset Quotes erd
23731 \end_inset
23732
23733  tab.
23734  The important parts are:
23735 \end_layout
23736
23737 \begin_layout Description
23738 the
23739 \begin_inset space ~
23740 \end_inset
23741
23742
23743 \begin_inset Quotes eld
23744 \end_inset
23745
23746 NoWeb
23747 \begin_inset Quotes erd
23748 \end_inset
23749
23750
23751 \begin_inset space ~
23752 \end_inset
23753
23754 format Set up via the File Formats tab, this is where the Noweb-specific
23755  pieces are set up.
23756  The 
23757 \family sans
23758 GUI Name
23759 \family default
23760  is set to 
23761 \family typewriter
23762 NoWeb
23763 \family default
23764 , the file extension is set to 
23765 \family typewriter
23766 .nw
23767 \family default
23768 .
23769  This tells \SpecialChar LyX
23770  to create a file with a 
23771 \family typewriter
23772 .nw
23773 \family default
23774  extension in the first step of the conversion process.
23775 \end_layout
23776
23777 \begin_layout Description
23778 the
23779 \begin_inset space ~
23780 \end_inset
23781
23782
23783 \family sans
23784 Program
23785 \family default
23786
23787 \begin_inset space ~
23788 \end_inset
23789
23790 format This is an empty format whose sole purpose is to be the endpoint
23791  of a conversion (which then allows us to set up a converter for it).
23792 \end_layout
23793
23794 \begin_layout Description
23795
23796 \family sans
23797 NoWeb
23798 \family default
23799 ->
23800 \family sans
23801 \SpecialChar LaTeX
23802
23803 \family default
23804  This converter performs the 
23805 \begin_inset Quotes eld
23806 \end_inset
23807
23808 weaving
23809 \begin_inset Quotes erd
23810 \end_inset
23811
23812  of the literate document.
23813  For Noweb, it is set to 
23814 \begin_inset Quotes eld
23815 \end_inset
23816
23817
23818 \family typewriter
23819 noweave -delay -index $$i > $$o
23820 \family default
23821
23822 \begin_inset Quotes erd
23823 \end_inset
23824
23825
23826 \end_layout
23827
23828 \begin_layout Description
23829
23830 \family sans
23831 NoWeb
23832 \family default
23833 ->
23834 \family sans
23835 Program
23836 \family default
23837  This performs the 
23838 \begin_inset Quotes eld
23839 \end_inset
23840
23841 tangling step
23842 \begin_inset Quotes erd
23843 \end_inset
23844
23845 .
23846  As stated above, the Converter is set to 
23847 \begin_inset Quotes eld
23848 \end_inset
23849
23850
23851 \family typewriter
23852 build-script $$i
23853 \family default
23854  $$r
23855 \begin_inset Quotes erd
23856 \end_inset
23857
23858 , with Flags set to
23859 \begin_inset Newline newline
23860 \end_inset
23861
23862
23863 \begin_inset Quotes eld
23864 \end_inset
23865
23866
23867 \family typewriter
23868 parselog=$$s/scripts/listerrors
23869 \family default
23870
23871 \begin_inset Quotes erd
23872 \end_inset
23873
23874 .
23875 \end_layout
23876
23877 \begin_layout Subsubsection
23878 Debug extensions
23879 \end_layout
23880
23881 \begin_layout Standard
23882 There is also a new function implemented in the \SpecialChar LyX
23883  server, the 
23884 \begin_inset Quotes eld
23885 \end_inset
23886
23887 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
23888  
23889 \end_layout
23890
23891 \begin_layout Standard
23892 When debugging code with ddd/gdb, it is possible to invoke a text editor
23893  at the current execution position with a single key stroke.
23894  The default ddd configuration for that is shift-ctrl-V.
23895  It happens that you can define the editor command line invocation in ddd
23896  by accessing the 
23897 \family sans
23898 Edit\SpecialChar menuseparator
23899 Preferences\SpecialChar menuseparator
23900 Helpers
23901 \family default
23902  dialog and changing the "Edit Sources" entry.
23903 \end_layout
23904
23905 \begin_layout Standard
23906 I take advantage of the newly created \SpecialChar LyX
23907  server function and this ddd feature,
23908  and set 
23909 \begin_inset Quotes eld
23910 \end_inset
23911
23912 Edit Sources
23913 \begin_inset Quotes erd
23914 \end_inset
23915
23916  to:
23917 \end_layout
23918
23919 \begin_layout Standard
23920 \begin_inset VSpace defskip
23921 \end_inset
23922
23923
23924 \end_layout
23925
23926 \begin_layout Standard
23927
23928 \family sans
23929 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
23930 \end_layout
23931
23932 \begin_layout Standard
23933 \begin_inset VSpace defskip
23934 \end_inset
23935
23936
23937 \end_layout
23938
23939 \begin_layout Standard
23940 With this, whenever you are using ddd and find a point in the program that
23941  you want to edit, you just press shift-ctrl-V (in the ddd window), and
23942  ddd will forward this information to \SpecialChar LyX
23943  through the \SpecialChar LyX
23944  server and then the
23945  \SpecialChar LyX
23946  window will show the same file with the cursor at the same position ddd
23947  was pointing to.
23948  No more guessing or long scrolling to locate a point in the program back
23949  from debugging !
23950 \end_layout
23951
23952 \begin_layout Standard
23953 Note however that you must enable the \SpecialChar LyX
23954  server to get this feature working
23955  (it is disabled by default).
23956  You can enable it in 
23957 \family sans
23958 Preferences
23959 \family default
23960  (tabs 
23961 \family sans
23962 Inputs
23963 \family default
23964
23965 \family sans
23966 Paths
23967 \family default
23968 ) by entering in the 
23969 \family sans
23970 \SpecialChar LyX
23971 server pipe
23972 \family default
23973  a path like 
23974 \begin_inset Quotes eld
23975 \end_inset
23976
23977
23978 \family typewriter
23979 /home/<your-home-directory>/.lyx/lyxpipe
23980 \family default
23981
23982 \begin_inset Quotes erd
23983 \end_inset
23984
23985
23986 \end_layout
23987
23988 \begin_layout Standard
23989 Read the \SpecialChar LyX
23990  server documentation in the 
23991 \emph on
23992 Customization Manual
23993 \emph default
23994  for further information.
23995 \end_layout
23996
23997 \begin_layout Subsubsection
23998 Toolbar extensions
23999 \end_layout
24000
24001 \begin_layout Standard
24002 There are six new buttons that can be added to your \SpecialChar LyX
24003  toolbar.
24004  Five of these buttons are short cuts to layout styles: 
24005 \family sans
24006 Standard
24007 \family default
24008
24009 \family sans
24010 Section
24011 \family default
24012
24013 \family sans
24014 \SpecialChar LaTeX
24015
24016 \family default
24017
24018 \family sans
24019 \SpecialChar LyX
24020 -Code
24021 \family default
24022 , and 
24023 \family sans
24024 Chunk
24025 \family default
24026 .
24027  The last one is a short cut to the 
24028 \begin_inset Quotes eld
24029 \end_inset
24030
24031 Build Program
24032 \begin_inset Quotes erd
24033 \end_inset
24034
24035  File menu entry.
24036  
24037 \end_layout
24038
24039 \begin_layout Standard
24040 \SpecialChar LyX
24041  has a range of buttons that are available for tool bar customization.
24042  In my toolbar I like to combine the six short cuts above with two more:
24043  One for 
24044 \family sans
24045 Document
24046 \family default
24047 \SpecialChar menuseparator
24048
24049 \family sans
24050 Update
24051 \family default
24052 \SpecialChar menuseparator
24053
24054 \family sans
24055 DVI
24056 \family default
24057  and the other for 
24058 \family sans
24059 Document\SpecialChar menuseparator
24060 View\SpecialChar menuseparator
24061 DVI
24062 \family default
24063  File menu entries.
24064  Here is how it looks like:
24065 \end_layout
24066
24067 \begin_layout LyX-Code
24068 Toolbar
24069 \end_layout
24070
24071 \begin_layout LyX-Code
24072   Layouts
24073 \end_layout
24074
24075 \begin_layout LyX-Code
24076   Icon "layout Standard"
24077 \end_layout
24078
24079 \begin_layout LyX-Code
24080   Icon "layout Section"
24081 \end_layout
24082
24083 \begin_layout LyX-Code
24084   Icon "layout \SpecialChar LaTeX
24085 "
24086 \end_layout
24087
24088 \begin_layout LyX-Code
24089   Icon "layout \SpecialChar LyX
24090 -Code"
24091 \end_layout
24092
24093 \begin_layout LyX-Code
24094   Icon "layout Chunk"
24095 \end_layout
24096
24097 \begin_layout LyX-Code
24098   Separator
24099 \end_layout
24100
24101 \begin_layout LyX-Code
24102   Icon "buffer-view"
24103 \end_layout
24104
24105 \begin_layout LyX-Code
24106   Icon "buffer-typeset"
24107 \end_layout
24108
24109 \begin_layout LyX-Code
24110   Icon "build-program"
24111 \end_layout
24112
24113 \begin_layout LyX-Code
24114   Separator
24115 \end_layout
24116
24117 \begin_layout LyX-Code
24118 .
24119 \end_layout
24120
24121 \begin_layout LyX-Code
24122 .
24123 \end_layout
24124
24125 \begin_layout LyX-Code
24126 .
24127 \end_layout
24128
24129 \begin_layout LyX-Code
24130 End
24131 \end_layout
24132
24133 \begin_layout Subsubsection
24134 Colors customization
24135 \end_layout
24136
24137 \begin_layout Standard
24138 There are a number of colors in \SpecialChar LyX
24139  that can be customized in 
24140 \family sans
24141 Preferences
24142 \family default
24143 .
24144  One of the things that bothers people is the \SpecialChar LaTeX
24145  font color.
24146  The default color is red, since the chunks uses \SpecialChar LaTeX
24147  font, and there is a lot
24148  of chunks in literate documents, you may get tired of seeing everything
24149  in red.
24150  You can change it by going to the tabs 
24151 \family sans
24152 Look&Feel
24153 \family default
24154
24155 \family sans
24156 Colors.
24157 \end_layout
24158
24159 \begin_layout Standard
24160 The next thing is the visible presence of the newline character in the screen.
24161  You can choose the color of this particular character and make it blend
24162  in the background.
24163  I recommend you choosing a color that is close to the background but not
24164  equal, that way you still can see it is there, but it is not bothering
24165  you anymore.
24166 \end_layout
24167
24168 \begin_layout Subsection
24169 \SpecialChar LyX
24170  and knitr/Sweave
24171 \end_layout
24172
24173 \begin_layout Standard
24174 Support for 
24175 \family sans
24176 knitr
24177 \family default
24178  and 
24179 \family sans
24180 Sweave
24181 \family default
24182  is documented in the 
24183 \emph on
24184 knitr.lyx
24185 \emph default
24186  example file and in the Sweave manual (menu 
24187 \family sans
24188 Help\SpecialChar menuseparator
24189 Specific Manuals
24190 \family default
24191 ).
24192 \end_layout
24193
24194 \begin_layout Chapter
24195 Special features
24196 \end_layout
24197
24198 \begin_layout Standard
24199 You can do everything with \SpecialChar LyX
24200  that you can do with \SpecialChar LaTeX
24201 .
24202  However, \SpecialChar LyX
24203  cannot support every \SpecialChar LaTeX
24204  feature directly.
24205  But you can always use \SpecialChar TeX
24206  Code.
24207  This chapter shows you some more special things you might want to use.
24208  For other special things you can do with figures, tables, floats, boxes
24209  and notes, have a look at the 
24210 \emph on
24211 Embedded
24212 \begin_inset space ~
24213 \end_inset
24214
24215 Objects
24216 \emph default
24217  manual.
24218 \end_layout
24219
24220 \begin_layout Section
24221 Multiple Text Columns
24222 \end_layout
24223
24224 \begin_layout Standard
24225 This feature is independent of the option 
24226 \family sans
24227 Two-column document
24228 \family default
24229  in the document settings under 
24230 \family sans
24231 Text Layout
24232 \family default
24233 .
24234  If you want to have 2
24235 \begin_inset space ~
24236 \end_inset
24237
24238 columns for the whole document, it is recommended to use the 
24239 \family sans
24240 Two-column document
24241 \family default
24242  option.
24243  For all other cases use this feature.
24244 \end_layout
24245
24246 \begin_layout Standard
24247 To use multiple text columns in your document, you have to load the module
24248  
24249 \family sans
24250 Multiple Columns
24251 \family default
24252  (menu 
24253 \family sans
24254 Document\SpecialChar menuseparator
24255 Settings\SpecialChar menuseparator
24256 Modules
24257 \family default
24258 ) and must have the \SpecialChar LaTeX
24259 -package 
24260 \series bold
24261 multicol
24262 \series default
24263  installed.
24264 \end_layout
24265
24266 \begin_layout Standard
24267 Footnotes within multiple columns will be placed at the bottom of the page
24268  and not under each column.
24269  Within the different columns you can use everything, with the limitation
24270  that for floats you need to use the float option 
24271 \family sans
24272 Span columns
24273 \family default
24274 .
24275 \end_layout
24276
24277 \begin_layout Subsection
24278 Basics
24279 \end_layout
24280
24281 \begin_layout Standard
24282 If you want to have 2
24283 \begin_inset space ~
24284 \end_inset
24285
24286 columns in your text, insert a multicolumn inset via the menu 
24287 \family sans
24288 Insert\SpecialChar menuseparator
24289 Custom
24290 \begin_inset space ~
24291 \end_inset
24292
24293 Insets\SpecialChar menuseparator
24294 Multiple
24295 \begin_inset space ~
24296 \end_inset
24297
24298 Columns
24299 \family default
24300  where the columns should start.
24301  Write all text that should be printed in 2
24302 \begin_inset space ~
24303 \end_inset
24304
24305 columns into this inset.
24306 \end_layout
24307
24308 \begin_layout Standard
24309 Here is an example:
24310 \end_layout
24311
24312 \begin_layout Standard
24313 \noindent
24314 \begin_inset Flex Multiple Columns
24315 status open
24316
24317 \begin_layout Plain Layout
24318 \noindent
24319
24320 \series bold
24321 \size small
24322 The Adventure of the Empty House
24323 \series default
24324
24325 \begin_inset Newline newline
24326 \end_inset
24327
24328 by Sir Arthur Conan Doyle
24329 \end_layout
24330
24331 \begin_layout Plain Layout
24332
24333 \size small
24334 It was in the spring of the year 1894 that all London was interested, and
24335  the fashionable world dismayed, by the murder of the Honourable Ronald
24336  Adair under most unusual and inexplicable circumstances.
24337  The public has already learned those particulars of the crime which came
24338  out in the police investigation, but a good deal was suppressed upon that
24339  occasion, since the case for the prosecution was so overwhelmingly strong
24340  that it was not necessary to bring forward all the facts.
24341  Only now, at the end of nearly ten years, am I allowed to supply those
24342  missing links which make up the whole of that remarkable chain.
24343  The crime was of interest in itself, but that interest was as nothing to
24344  me compared to the inconceivable sequel, which afforded me the greatest
24345  shock and surprise of any event in my adventurous life.
24346  Even now, after this long interval, I find myself thrilling as I think
24347  of it, and feeling once more that sudden flood of joy, amazement, and increduli
24348 ty which utterly submerged my mind.
24349  Let me say to that public, which has shown some interest in those glimpses
24350  which I have occasionally given them of the thoughts and actions of a very
24351  remarkable man, that they are not to blame me if I have not shared my knowledge
24352  with them, for I should have considered it my first duty to do so, had
24353  I not been barred by a positive prohibition from his own lips, which was
24354  only withdrawn upon the third of last month.
24355 \end_layout
24356
24357 \end_inset
24358
24359
24360 \end_layout
24361
24362 \begin_layout Standard
24363 To get 3 or more columns, set the cursor into the multicolumn inset and
24364  use the menu 
24365 \family sans
24366 Insert\SpecialChar menuseparator
24367 Number
24368 \begin_inset space ~
24369 \end_inset
24370
24371 of
24372 \begin_inset space ~
24373 \end_inset
24374
24375 Columns
24376 \family default
24377 .
24378  The number of the desired columns is written into that inset (for 3
24379 \begin_inset space ~
24380 \end_inset
24381
24382 columns write 
24383 \begin_inset Quotes eld
24384 \end_inset
24385
24386 3
24387 \begin_inset Quotes erd
24388 \end_inset
24389
24390 ).
24391 \begin_inset Newline newline
24392 \end_inset
24393
24394 Here is an example with 3
24395 \begin_inset space ~
24396 \end_inset
24397
24398 columns:
24399 \end_layout
24400
24401 \begin_layout Standard
24402 \begin_inset Flex Multiple Columns
24403 status open
24404
24405 \begin_layout Plain Layout
24406
24407 \size footnotesize
24408 \begin_inset Argument 1
24409 status open
24410
24411 \begin_layout Plain Layout
24412 3
24413 \end_layout
24414
24415 \end_inset
24416
24417 It can be imagined that my close intimacy with Sherlock Holmes had interested
24418  me deeply in crime, and that after his disappearance I never failed to
24419  read with care the various problems which came before the public.
24420  And I even attempted, more than once, for my own private satisfaction,
24421  to employ his methods in their solution, though with indifferent success.
24422  There was none, however, which appealed to me like this tragedy of Ronald
24423  Adair.
24424  As I read the evidence at the inquest, which led up to a verdict of willful
24425  murder against some person or persons unknown, I realized more clearly
24426  than I had ever done the loss which the community had sustained by the
24427  death of Sherlock Holmes.
24428  There were points about this strange business which would, I was sure,
24429  have specially appealed to him, and the efforts of the police would have
24430  been supplemented, or more probably anticipated, by the trained observation
24431  and the alert mind of the first criminal agent in Europe.
24432  All day, as I drove upon my round, I turned over the case in my mind and
24433  found no explanation which appeared to me to be adequate.
24434  At the risk of telling a twice-told tale, I will recapitulate the facts
24435  as they were known to the public at the conclusion of the inquest.
24436 \end_layout
24437
24438 \end_inset
24439
24440
24441 \end_layout
24442
24443 \begin_layout Standard
24444 You can have up to 10
24445 \begin_inset space ~
24446 \end_inset
24447
24448 columns if you want to, but that might not be very pleasant for the readers
24449  of your document.
24450 \end_layout
24451
24452 \begin_layout Standard
24453 \begin_inset Newpage newpage
24454 \end_inset
24455
24456
24457 \end_layout
24458
24459 \begin_layout Subsection
24460 Columns inside Columns
24461 \end_layout
24462
24463 \begin_layout Standard
24464 You can also have columns inside columns:
24465 \end_layout
24466
24467 \begin_layout Standard
24468 \begin_inset Flex Multiple Columns
24469 status open
24470
24471 \begin_layout Plain Layout
24472
24473 \size footnotesize
24474 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
24475  at that time governor of one of the Australian colonies.
24476  Adair's mother had returned from Australia to undergo the operation for
24477  cataract, and she, her son Ronald, and her daughter Hilda were living together
24478  at 427 Park Lane.
24479 \end_layout
24480
24481 \begin_layout Plain Layout
24482 \begin_inset Flex Multiple Columns
24483 status open
24484
24485 \begin_layout Plain Layout
24486
24487 \size footnotesize
24488 The youth moved in the best society–had, so far as was known, no enemies
24489  and no particular vices.
24490  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
24491  had been broken off by mutual consent some months before, and there was
24492  no sign that it had left any very profound feeling behind it.
24493  For the rest {sic} the man's life moved in a narrow and conventional circle,
24494  for his habits were quiet and his nature unemotional.
24495  Yet it was upon this easy-going young aristocrat that death came, in most
24496  strange and unexpected form, between the hours of ten and eleven-twenty
24497  on the night of March 30, 1894.
24498 \end_layout
24499
24500 \end_inset
24501
24502
24503 \end_layout
24504
24505 \begin_layout Plain Layout
24506
24507 \size footnotesize
24508 Ronald Adair was fond of cards–playing continually, but never for such stakes
24509  as would hurt him.
24510  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
24511  It was shown that, after dinner on the day of his death, he had played
24512  a rubber of whist at the latter club.
24513  He had also played there in the afternoon.
24514
24515 \size default
24516  
24517 \size footnotesize
24518 The evidence of those who had played with him– Mr.
24519  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
24520  and that there was a fairly equal fall of the cards.
24521  Adair might have lost five pounds, but not more.
24522  His fortune was a considerable one, and such a loss could not in any way
24523  affect him.
24524  He had played nearly every day at one club or other, but he was a cautious
24525  player, and usually rose a winner.
24526  It came out in evidence that, in partnership with Colonel Moran, he had
24527  actually won as much as four hundred and twenty pounds in a sitting, some
24528  weeks before, from Godfrey Milner and Lord Balmoral.
24529  So much for his recent history as it came out at the inquest.
24530 \end_layout
24531
24532 \end_inset
24533
24534
24535 \end_layout
24536
24537 \begin_layout Subsection
24538 Advanced Examples
24539 \end_layout
24540
24541 \begin_layout Standard
24542 The examples in this section show some more special features of multiple
24543  columns.
24544 \end_layout
24545
24546 \begin_layout Standard
24547 For more features of multiple columns, have a look at the documentation
24548  of the \SpecialChar LaTeX
24549 -package 
24550 \series bold
24551 multicol
24552 \series default
24553
24554 \begin_inset CommandInset citation
24555 LatexCommand cite
24556 key "multicol"
24557
24558 \end_inset
24559
24560 .
24561 \end_layout
24562
24563 \begin_layout Subsubsection
24564 Preface
24565 \end_layout
24566
24567 \begin_layout Standard
24568 To add a preface text for multiple columns, set the cursor into the multicolumn
24569  inset and use the menu 
24570 \family sans
24571 Insert\SpecialChar menuseparator
24572 Preface
24573 \family default
24574 .
24575  Write your preface text into that inset.
24576 \begin_inset Newline newline
24577 \end_inset
24578
24579 This is an example with some preface text:
24580 \end_layout
24581
24582 \begin_layout Standard
24583 \begin_inset VSpace bigskip
24584 \end_inset
24585
24586
24587 \end_layout
24588
24589 \begin_layout Standard
24590 \begin_inset Flex Multiple Columns
24591 status open
24592
24593 \begin_layout Plain Layout
24594 \begin_inset Argument 2
24595 status open
24596
24597 \begin_layout Plain Layout
24598 And the story continues and continues and continues and continues\SpecialChar ldots
24599
24600 \end_layout
24601
24602 \end_inset
24603
24604
24605 \size small
24606 On the evening of the crime, he returned from the club exactly at ten.
24607  His mother and sister were out spending the evening with a relation.
24608  The servant deposed that she heard him enter the front room on the second
24609  floor, generally used as his sitting-room.
24610  She had lit a fire there, and as it smoked she had opened the window.
24611  No sound was heard from the room until eleven-twenty, the hour of the return
24612  of Lady Maynooth and her daughter.
24613  Desiring to say good-night, she attempted to enter her son's room.
24614  The door was locked on the inside, and no answer could be got to their
24615  cries and knocking.
24616  Help was obtained, and the door forced.
24617  The unfortunate young man was found lying near the table.
24618  His head had been horribly mutilated by an expanding revolver bullet, but
24619  no weapon of any sort was to be found in the room.
24620 \end_layout
24621
24622 \end_inset
24623
24624
24625 \end_layout
24626
24627 \begin_layout Standard
24628 You can also use a section heading as the preface if you use a section command
24629  as \SpecialChar TeX
24630  Code.
24631  For example the command
24632 \end_layout
24633
24634 \begin_layout Standard
24635
24636 \series bold
24637
24638 \backslash
24639 subsection{subsection title}
24640 \end_layout
24641
24642 \begin_layout Standard
24643 creates a subsection.
24644  In this example the preface is a subsubsection:
24645 \end_layout
24646
24647 \begin_layout Standard
24648 \begin_inset Flex Multiple Columns
24649 status open
24650
24651 \begin_layout Plain Layout
24652 \begin_inset Argument 2
24653 status open
24654
24655 \begin_layout Plain Layout
24656 \begin_inset ERT
24657 status collapsed
24658
24659 \begin_layout Plain Layout
24660
24661
24662 \backslash
24663 subsubsection{
24664 \end_layout
24665
24666 \end_inset
24667
24668 This is a subsubsection heading as a preface
24669 \begin_inset ERT
24670 status collapsed
24671
24672 \begin_layout Plain Layout
24673
24674 }
24675 \end_layout
24676
24677 \end_inset
24678
24679
24680 \end_layout
24681
24682 \end_inset
24683
24684
24685 \size small
24686 A minute examination of the circumstances served only to make the case more
24687  complex.
24688  In the first place, no reason could be given why the young man should have
24689  fastened the door upon the inside.
24690  There was the possibility that the murderer had done this, and had afterwards
24691  escaped by the window.
24692  The drop was at least twenty feet, however, and a bed of crocuses in full
24693  bloom lay beneath.
24694  Neither the flowers nor the earth showed any sign of having been disturbed,
24695  nor were there any marks upon the narrow strip of grass which separated
24696  the house from the road.
24697  Apparently, therefore, it was the young man himself who had fastened the
24698  door.
24699  But how did he come by his death? No one could have climbed up to the window
24700  without leaving traces.
24701  Suppose a man had fired through the window, he would indeed be a remarkable
24702  shot who could with a revolver inflict so deadly a wound.
24703  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
24704  a hundred yards of the house.
24705  No one had heard a shot.
24706 \end_layout
24707
24708 \end_inset
24709
24710
24711 \end_layout
24712
24713 \begin_layout Standard
24714 If there is less vertical space than 6
24715 \begin_inset space ~
24716 \end_inset
24717
24718 text lines is left on the page at the beginning of the multiple columns,
24719  a page break will be inserted before the multiple columns.
24720  Depending on the number of lines of the preface text, you might want to
24721  change this space.
24722  This is done by setting the cursor into the mulitcolumn inset behind the
24723  preface (if there is any) and using the menu 
24724 \family sans
24725 Insert\SpecialChar menuseparator
24726 Space
24727 \begin_inset space ~
24728 \end_inset
24729
24730 Before
24731 \begin_inset space ~
24732 \end_inset
24733
24734 Page
24735 \begin_inset space ~
24736 \end_inset
24737
24738 Break
24739 \family default
24740 .
24741  Insert into that inset the amount of space like e.
24742 \begin_inset space \thinspace{}
24743 \end_inset
24744
24745 g.
24746 \begin_inset space \space{}
24747 \end_inset
24748
24749
24750 \begin_inset Quotes eld
24751 \end_inset
24752
24753 5cm
24754 \begin_inset Quotes erd
24755 \end_inset
24756
24757 .
24758 \begin_inset Newline newline
24759 \end_inset
24760
24761 In this example the space is set to 7
24762 \begin_inset space ~
24763 \end_inset
24764
24765 text lines by using 
24766 \begin_inset Quotes eld
24767 \end_inset
24768
24769 7
24770 \backslash
24771 baselineskip
24772 \begin_inset Quotes erd
24773 \end_inset
24774
24775  (where the command 
24776 \series bold
24777
24778 \backslash
24779 baselineskip
24780 \series default
24781  needs to be inserted as \SpecialChar TeX
24782  code):
24783 \end_layout
24784
24785 \begin_layout Standard
24786 \begin_inset Flex Multiple Columns
24787 status open
24788
24789 \begin_layout Plain Layout
24790 \begin_inset Argument 3
24791 status open
24792
24793 \begin_layout Plain Layout
24794 7
24795 \begin_inset ERT
24796 status collapsed
24797
24798 \begin_layout Plain Layout
24799
24800
24801 \backslash
24802 baselineskip
24803 \end_layout
24804
24805 \end_inset
24806
24807
24808 \end_layout
24809
24810 \end_inset
24811
24812
24813 \size small
24814 On the evening of the crime, he returned from the club exactly at ten.
24815  His mother and sister were out spending the evening with a relation.
24816  The servant deposed that she heard him enter the front room on the second
24817  floor, generally used as his sitting-room.
24818  She had lit a fire there, and as it smoked she had opened the window.
24819  No sound was heard from the room until eleven-twenty, the hour of the return
24820  of Lady Maynooth and her daughter.
24821  Desiring to say good-night, she attempted to enter her son's room.
24822  The door was locked on the inside, and no answer could be got to their
24823  cries and knocking.
24824  Help was obtained, and the door forced.
24825  The unfortunate young man was found lying near the table.
24826  His head had been horribly mutilated by an expanding revolver bullet, but
24827  no weapon of any sort was to be found in the room.
24828 \end_layout
24829
24830 \end_inset
24831
24832
24833 \end_layout
24834
24835 \begin_layout Subsubsection
24836 Surrounding Space
24837 \end_layout
24838
24839 \begin_layout Standard
24840 The amount of space before and after multiple columns can be changed by
24841  changing the length 
24842 \series bold
24843
24844 \backslash
24845 multicolsep
24846 \series default
24847 .
24848  For example the command
24849 \end_layout
24850
24851 \begin_layout Standard
24852
24853 \series bold
24854
24855 \backslash
24856 setlength{
24857 \backslash
24858 multicolsep}{3cm}
24859 \end_layout
24860
24861 \begin_layout Standard
24862 in \SpecialChar TeX
24863  Code changes its value to 3
24864 \begin_inset space \thinspace{}
24865 \end_inset
24866
24867 cm.
24868  The change must be made before the multiple columns' start.
24869  The predefined value is 13
24870 \begin_inset space \thinspace{}
24871 \end_inset
24872
24873 pt.
24874 \end_layout
24875
24876 \begin_layout Standard
24877 For this example 
24878 \series bold
24879
24880 \backslash
24881 multicolsep
24882 \series default
24883  was set to 2.5
24884 \begin_inset space \thinspace{}
24885 \end_inset
24886
24887 cm:
24888 \end_layout
24889
24890 \begin_layout Standard
24891 \begin_inset ERT
24892 status open
24893
24894 \begin_layout Plain Layout
24895
24896
24897 \backslash
24898 setlength{
24899 \backslash
24900 multicolsep}{2.5cm}
24901 \end_layout
24902
24903 \end_inset
24904
24905
24906 \end_layout
24907
24908 \begin_layout Standard
24909 \begin_inset Flex Multiple Columns
24910 status open
24911
24912 \begin_layout Plain Layout
24913
24914 \size small
24915 All day I turned these facts over in my mind, endeavouring to hit upon some
24916  theory which could reconcile them all, and to find that line of least resistanc
24917 e which my poor friend had declared to be the starting-point of every investigat
24918 ion.
24919  I confess that I made little progress.
24920  In the evening I strolled across the Park, and found myself about six o'clock
24921  at the Oxford Street end of Park Lane.
24922  A group of loafers upon the pavements, all staring up at a particular window,
24923  directed me to the house which I had come to see.
24924  A tall, thin man with coloured glasses, whom I strongly suspected of being
24925  a plain-clothes detective, was pointing out some theory of his own, while
24926  the others crowded round to listen to what he said.
24927  I got as near him as I could, but his observations seemed to me to be absurd,
24928  so I withdrew again in some disgust.
24929  As I did so I struck against an elderly, deformed man, who had been behind
24930  me, and I knocked down several books which he was carrying.
24931 \end_layout
24932
24933 \end_inset
24934
24935
24936 \end_layout
24937
24938 \begin_layout Standard
24939 \begin_inset Note Greyedout
24940 status open
24941
24942 \begin_layout Plain Layout
24943
24944 \series bold
24945 Note:
24946 \series default
24947  The values you set with 
24948 \series bold
24949
24950 \backslash
24951 setlength
24952 \series default
24953  will be used for all following multiple columns until you change them again.
24954 \end_layout
24955
24956 \end_inset
24957
24958
24959 \end_layout
24960
24961 \begin_layout Standard
24962 \begin_inset ERT
24963 status collapsed
24964
24965 \begin_layout Plain Layout
24966
24967
24968 \backslash
24969 setlength{
24970 \backslash
24971 multicolsep}{13pt}
24972 \end_layout
24973
24974 \end_inset
24975
24976
24977 \begin_inset Note Note
24978 status collapsed
24979
24980 \begin_layout Plain Layout
24981 go back to the default
24982 \end_layout
24983
24984 \end_inset
24985
24986
24987 \end_layout
24988
24989 \begin_layout Standard
24990 \begin_inset Newpage newpage
24991 \end_inset
24992
24993
24994 \end_layout
24995
24996 \begin_layout Subsubsection
24997 Column Breaks
24998 \end_layout
24999
25000 \begin_layout Standard
25001 A column break can be forced by inserting the command 
25002 \series bold
25003
25004 \backslash
25005 columnbreak{}
25006 \series default
25007  as \SpecialChar TeX
25008  Code to that position in the text where the column should be broken.
25009  Note that this leads in most cases to whitespace in the text.
25010 \begin_inset Newline newline
25011 \end_inset
25012
25013 Here is an example:
25014 \end_layout
25015
25016 \begin_layout Standard
25017 \begin_inset Flex Multiple Columns
25018 status open
25019
25020 \begin_layout Plain Layout
25021
25022 \size small
25023 \begin_inset Quotes eld
25024 \end_inset
25025
25026 You're surprised to see me, sir,
25027 \begin_inset Quotes erd
25028 \end_inset
25029
25030  said he, in a strange, croaking voice.
25031 \end_layout
25032
25033 \begin_layout Plain Layout
25034
25035 \size small
25036 I acknowledged that I was.
25037 \end_layout
25038
25039 \begin_layout Plain Layout
25040
25041 \size small
25042 \begin_inset Quotes eld
25043 \end_inset
25044
25045 Well, I've a conscience, sir, and when I chanced to see you go into this
25046  house, as I came hobbling after you, I thought to myself, I'll just step
25047  in and see that kind gentleman, and tell him that if I was a bit gruff
25048  in my manner there was not any harm meant, and that I am much obliged to
25049  him for picking up my books.
25050 \begin_inset Quotes erd
25051 \end_inset
25052
25053
25054 \end_layout
25055
25056 \begin_layout Plain Layout
25057
25058 \size small
25059 \begin_inset Quotes eld
25060 \end_inset
25061
25062 You make too much of a trifle,
25063 \begin_inset Quotes erd
25064 \end_inset
25065
25066  said I.
25067  
25068 \begin_inset Quotes eld
25069 \end_inset
25070
25071 May I ask how you knew who I was?
25072 \begin_inset Quotes erd
25073 \end_inset
25074
25075  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
25076 \begin_inset ERT
25077 status collapsed
25078
25079 \begin_layout Plain Layout
25080
25081
25082 \backslash
25083 columnbreak{}
25084 \end_layout
25085
25086 \end_inset
25087
25088
25089 \end_layout
25090
25091 \begin_layout Plain Layout
25092
25093 \size small
25094 \begin_inset Quotes eld
25095 \end_inset
25096
25097 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25098  you'll find my little bookshop at the corner of Church Street, and very
25099  happy to see you, I am sure.
25100  Maybe you collect yourself, sir.
25101  Here's 
25102 \noun on
25103 British
25104 \begin_inset space ~
25105 \end_inset
25106
25107 Birds
25108 \noun default
25109 , and 
25110 \noun on
25111 Catullus
25112 \noun default
25113 , and 
25114 \noun on
25115 The Holy War
25116 \noun default
25117 –a bargain, every one of them.
25118  With five volumes you could just fill that gap on that second shelf.
25119  It looks untidy, does it not, sir?
25120 \begin_inset Quotes erd
25121 \end_inset
25122
25123
25124 \end_layout
25125
25126 \end_inset
25127
25128
25129 \end_layout
25130
25131 \begin_layout Subsubsection
25132 Column Separation
25133 \end_layout
25134
25135 \begin_layout Standard
25136 The width of the columns is automatically calculated, but you can modify
25137  the space between the columns.
25138  This is done by changing the length 
25139 \series bold
25140
25141 \backslash
25142 columnsep
25143 \series default
25144 .
25145  Its predefined value is 10
25146 \begin_inset space \thinspace{}
25147 \end_inset
25148
25149 pt.
25150  Here is an example where 
25151 \series bold
25152
25153 \backslash
25154 columnsep
25155 \series default
25156  is set to 3
25157 \begin_inset space \thinspace{}
25158 \end_inset
25159
25160 cm:
25161 \end_layout
25162
25163 \begin_layout Standard
25164 \begin_inset ERT
25165 status open
25166
25167 \begin_layout Plain Layout
25168
25169
25170 \backslash
25171 setlength{
25172 \backslash
25173 columnsep}{3cm}
25174 \end_layout
25175
25176 \end_inset
25177
25178
25179 \end_layout
25180
25181 \begin_layout Standard
25182 \begin_inset Flex Multiple Columns
25183 status open
25184
25185 \begin_layout Plain Layout
25186
25187 \size small
25188 My observations of No.
25189 \begin_inset space \space{}
25190 \end_inset
25191
25192 427 Park Lane did little to clear up the problem in which I was interested.
25193  The house was separated from the street by a low wall and railing, the
25194  whole not more than five feet high.
25195  It was perfectly easy, therefore, for anyone to get into the garden, but
25196  the window was entirely inaccessible, since there was no water pipe or
25197  anything which could help the most active man to climb it.
25198  More puzzled than ever, I retraced my steps to Kensington.
25199  I had not been in my study five minutes when the maid entered to say that
25200  a person desired to see me.
25201  To my astonishment it was none other than my strange old book collector,
25202  his sharp, wizened face peering out from a frame of white hair, and his
25203  precious volumes, a dozen of them at least, wedged under his right arm.
25204 \end_layout
25205
25206 \end_inset
25207
25208
25209 \end_layout
25210
25211 \begin_layout Standard
25212 \begin_inset ERT
25213 status collapsed
25214
25215 \begin_layout Plain Layout
25216
25217
25218 \backslash
25219 setlength{
25220 \backslash
25221 columnsep}{10pt}
25222 \end_layout
25223
25224 \end_inset
25225
25226
25227 \begin_inset Note Note
25228 status collapsed
25229
25230 \begin_layout Plain Layout
25231 go back to the default
25232 \end_layout
25233
25234 \end_inset
25235
25236
25237 \end_layout
25238
25239 \begin_layout Subsubsection
25240 Vertical Lines
25241 \end_layout
25242
25243 \begin_layout Standard
25244 Between the columns a rule with a width of the length 
25245 \series bold
25246
25247 \backslash
25248 columnseprule
25249 \series default
25250  is placed.
25251  If this rule width is set to 0
25252 \begin_inset space \thinspace{}
25253 \end_inset
25254
25255 pt (this is the default), the rule is suppressed.
25256  In the following example the rule is 2
25257 \begin_inset space \thinspace{}
25258 \end_inset
25259
25260 pt wide:
25261 \end_layout
25262
25263 \begin_layout Standard
25264 \begin_inset ERT
25265 status open
25266
25267 \begin_layout Plain Layout
25268
25269
25270 \backslash
25271 setlength{
25272 \backslash
25273 columnseprule}{2pt}
25274 \end_layout
25275
25276 \end_inset
25277
25278
25279 \end_layout
25280
25281 \begin_layout Standard
25282 \begin_inset Flex Multiple Columns
25283 status open
25284
25285 \begin_layout Plain Layout
25286
25287 \size small
25288 \begin_inset Quotes eld
25289 \end_inset
25290
25291 You're surprised to see me, sir,
25292 \begin_inset Quotes erd
25293 \end_inset
25294
25295  said he, in a strange, croaking voice.
25296 \end_layout
25297
25298 \begin_layout Plain Layout
25299
25300 \size small
25301 I acknowledged that I was.
25302 \end_layout
25303
25304 \begin_layout Plain Layout
25305
25306 \size small
25307 \begin_inset Quotes eld
25308 \end_inset
25309
25310 Well, I've a conscience, sir, and when I chanced to see you go into this
25311  house, as I came hobbling after you, I thought to myself, I'll just step
25312  in and see that kind gentleman, and tell him that if I was a bit gruff
25313  in my manner there was not any harm meant, and that I am much obliged to
25314  him for picking up my books.
25315 \begin_inset Quotes erd
25316 \end_inset
25317
25318
25319 \end_layout
25320
25321 \begin_layout Plain Layout
25322
25323 \size small
25324 \begin_inset Quotes eld
25325 \end_inset
25326
25327 You make too much of a trifle,
25328 \begin_inset Quotes erd
25329 \end_inset
25330
25331  said I.
25332  
25333 \begin_inset Quotes eld
25334 \end_inset
25335
25336 May I ask how you knew who I was?
25337 \begin_inset Quotes erd
25338 \end_inset
25339
25340
25341 \end_layout
25342
25343 \begin_layout Plain Layout
25344
25345 \size small
25346 \begin_inset Quotes eld
25347 \end_inset
25348
25349 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25350  you'll find my little bookshop at the corner of Church Street, and very
25351  happy to see you, I am sure.
25352  Maybe you collect yourself, sir.
25353  Here's 
25354 \noun on
25355 British
25356 \begin_inset space ~
25357 \end_inset
25358
25359 Birds
25360 \noun default
25361 , and 
25362 \noun on
25363 Catullus
25364 \noun default
25365 , and 
25366 \noun on
25367 The Holy War
25368 \noun default
25369 –a bargain, every one of them.
25370  With five volumes you could just fill that gap on that second shelf.
25371  It looks untidy, does it not, sir?
25372 \begin_inset Quotes erd
25373 \end_inset
25374
25375
25376 \end_layout
25377
25378 \end_inset
25379
25380
25381 \end_layout
25382
25383 \begin_layout Standard
25384 \begin_inset VSpace defskip
25385 \end_inset
25386
25387
25388 \end_layout
25389
25390 \begin_layout Standard
25391 The rule can be colored by redefining the command 
25392 \series bold
25393
25394 \backslash
25395 columnseprulecolor
25396 \series default
25397 .
25398  This is done by inserting the command
25399 \begin_inset Newline newline
25400 \end_inset
25401
25402
25403 \series bold
25404
25405 \backslash
25406 renewcommand{
25407 \backslash
25408 columnseprulecolor}{
25409 \backslash
25410 color{red}}
25411 \series default
25412
25413 \begin_inset Newline newline
25414 \end_inset
25415
25416 as \SpecialChar TeX
25417  Code before the multicolumn inset.
25418  Replace 
25419 \series bold
25420 red
25421 \series default
25422  in this command by a color of your choice.
25423  You can use all pre- and self-defined colors.
25424  See the 
25425 \emph on
25426 EmbeddedObjects
25427 \emph default
25428  manual, section 
25429 \emph on
25430 Colored
25431 \begin_inset space ~
25432 \end_inset
25433
25434 Tables
25435 \emph default
25436  for more information about pre- and self-defined colors.
25437  To go back to the default color insert the command
25438 \begin_inset Newline newline
25439 \end_inset
25440
25441
25442 \series bold
25443
25444 \backslash
25445 renewcommand{
25446 \backslash
25447 columnseprulecolor}{
25448 \backslash
25449 normalcolor}
25450 \series default
25451
25452 \begin_inset Newline newline
25453 \end_inset
25454
25455 Here is the example with a cyan rule and 1
25456 \begin_inset space \thinspace{}
25457 \end_inset
25458
25459 cm column separation:
25460 \end_layout
25461
25462 \begin_layout Standard
25463 \begin_inset ERT
25464 status open
25465
25466 \begin_layout Plain Layout
25467
25468
25469 \backslash
25470 setlength{
25471 \backslash
25472 columnsep}{1cm}
25473 \end_layout
25474
25475 \begin_layout Plain Layout
25476
25477
25478 \backslash
25479 renewcommand{
25480 \backslash
25481 columnseprulecolor}{
25482 \backslash
25483 color{cyan}}
25484 \end_layout
25485
25486 \end_inset
25487
25488
25489 \end_layout
25490
25491 \begin_layout Standard
25492 \begin_inset Flex Multiple Columns
25493 status open
25494
25495 \begin_layout Plain Layout
25496
25497 \size small
25498 \begin_inset Quotes eld
25499 \end_inset
25500
25501 You're surprised to see me, sir,
25502 \begin_inset Quotes erd
25503 \end_inset
25504
25505  said he, in a strange, croaking voice.
25506 \end_layout
25507
25508 \begin_layout Plain Layout
25509
25510 \size small
25511 I acknowledged that I was.
25512 \end_layout
25513
25514 \begin_layout Plain Layout
25515
25516 \size small
25517 \begin_inset Quotes eld
25518 \end_inset
25519
25520 Well, I've a conscience, sir, and when I chanced to see you go into this
25521  house, as I came hobbling after you, I thought to myself, I'll just step
25522  in and see that kind gentleman, and tell him that if I was a bit gruff
25523  in my manner there was not any harm meant, and that I am much obliged to
25524  him for picking up my books.
25525 \begin_inset Quotes erd
25526 \end_inset
25527
25528
25529 \end_layout
25530
25531 \begin_layout Plain Layout
25532
25533 \size small
25534 \begin_inset Quotes eld
25535 \end_inset
25536
25537 You make too much of a trifle,
25538 \begin_inset Quotes erd
25539 \end_inset
25540
25541  said I.
25542  
25543 \begin_inset Quotes eld
25544 \end_inset
25545
25546 May I ask how you knew who I was?
25547 \begin_inset Quotes erd
25548 \end_inset
25549
25550
25551 \end_layout
25552
25553 \begin_layout Plain Layout
25554
25555 \size small
25556 \begin_inset Quotes eld
25557 \end_inset
25558
25559 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25560  you'll find my little bookshop at the corner of Church Street, and very
25561  happy to see you, I am sure.
25562  Maybe you collect yourself, sir.
25563  Here's 
25564 \noun on
25565 British
25566 \begin_inset space ~
25567 \end_inset
25568
25569 Birds
25570 \noun default
25571 , and 
25572 \noun on
25573 Catullus
25574 \noun default
25575 , and 
25576 \noun on
25577 The Holy War
25578 \noun default
25579 –a bargain, every one of them.
25580  With five volumes you could just fill that gap on that second shelf.
25581  It looks untidy, does it not, sir?
25582 \begin_inset Quotes erd
25583 \end_inset
25584
25585
25586 \end_layout
25587
25588 \end_inset
25589
25590
25591 \end_layout
25592
25593 \begin_layout Standard
25594 \begin_inset ERT
25595 status collapsed
25596
25597 \begin_layout Plain Layout
25598
25599
25600 \backslash
25601 setlength{
25602 \backslash
25603 columnseprule}{0pt}
25604 \end_layout
25605
25606 \begin_layout Plain Layout
25607
25608
25609 \backslash
25610 renewcommand{
25611 \backslash
25612 columnseprulecolor}{
25613 \backslash
25614 normalcolor}
25615 \end_layout
25616
25617 \end_inset
25618
25619
25620 \begin_inset Note Note
25621 status collapsed
25622
25623 \begin_layout Plain Layout
25624 go back to the default
25625 \end_layout
25626
25627 \end_inset
25628
25629
25630 \end_layout
25631
25632 \begin_layout Section
25633 Non-standard Paragraph Shapes
25634 \end_layout
25635
25636 \begin_layout Standard
25637 \noindent
25638 \SpecialChar LaTeX
25639  as well as any other text processor uses by default rectangular paragraphs.
25640  For special cases like for example posters, invitation cards or poems you
25641  can modify the paragraph shape to one of your choice.
25642  This can be done by using the \SpecialChar LaTeX
25643 -package 
25644 \series bold
25645 shapepar
25646 \series default
25647  which is loaded by using in the document settings the module 
25648 \family sans
25649 Custom paragraph shapes
25650 \family default
25651 .
25652 \end_layout
25653
25654 \begin_layout Subsection
25655 Predefined shapes
25656 \end_layout
25657
25658 \begin_layout Standard
25659
25660 \series bold
25661 shapepar
25662 \series default
25663  provides the following shapes:
25664 \end_layout
25665
25666 \begin_layout Standard
25667 \begin_inset Tabular
25668 <lyxtabular version="3" rows="13" columns="3">
25669 <features booktabs="true" islongtable="true" longtabularalignment="center">
25670 <column alignment="center" valignment="middle" width="16col%">
25671 <column alignment="center" valignment="middle" width="40col%">
25672 <column alignment="center" valignment="middle" width="35col%">
25673 <row endhead="true">
25674 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25675 \begin_inset Text
25676
25677 \begin_layout Plain Layout
25678 Name
25679 \end_layout
25680
25681 \end_inset
25682 </cell>
25683 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25684 \begin_inset Text
25685
25686 \begin_layout Plain Layout
25687 Description
25688 \end_layout
25689
25690 \end_inset
25691 </cell>
25692 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
25693 \begin_inset Text
25694
25695 \begin_layout Plain Layout
25696 Annotation
25697 \end_layout
25698
25699 \end_inset
25700 </cell>
25701 </row>
25702 <row>
25703 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25704 \begin_inset Text
25705
25706 \begin_layout Plain Layout
25707 CDlabel
25708 \end_layout
25709
25710 \end_inset
25711 </cell>
25712 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25713 \begin_inset Text
25714
25715 \begin_layout Plain Layout
25716 Circle with circular hole (in the size of a CD/DVD)
25717 \end_layout
25718
25719 \end_inset
25720 </cell>
25721 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25722 \begin_inset Text
25723
25724 \begin_layout Plain Layout
25725 Cannot be scaled, take care there is not too much text
25726 \end_layout
25727
25728 \end_inset
25729 </cell>
25730 </row>
25731 <row>
25732 <cell alignment="center" valignment="top" topline="true" usebox="none">
25733 \begin_inset Text
25734
25735 \begin_layout Plain Layout
25736 Circle
25737 \end_layout
25738
25739 \end_inset
25740 </cell>
25741 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25742 \begin_inset Text
25743
25744 \begin_layout Plain Layout
25745 Circle
25746 \end_layout
25747
25748 \end_inset
25749 </cell>
25750 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25751 \begin_inset Text
25752
25753 \begin_layout Plain Layout
25754 Fragile, calculation might fail
25755 \end_layout
25756
25757 \end_inset
25758 </cell>
25759 </row>
25760 <row>
25761 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25762 \begin_inset Text
25763
25764 \begin_layout Plain Layout
25765 Diamond
25766 \end_layout
25767
25768 \end_inset
25769 </cell>
25770 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25771 \begin_inset Text
25772
25773 \begin_layout Plain Layout
25774 Rhomboid (symbolizing a 
25775 \begin_inset Quotes eld
25776 \end_inset
25777
25778 diamond
25779 \begin_inset Quotes erd
25780 \end_inset
25781
25782 )
25783 \end_layout
25784
25785 \end_inset
25786 </cell>
25787 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25788 \begin_inset Text
25789
25790 \begin_layout Plain Layout
25791 -
25792 \end_layout
25793
25794 \end_inset
25795 </cell>
25796 </row>
25797 <row>
25798 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25799 \begin_inset Text
25800
25801 \begin_layout Plain Layout
25802 Heart
25803 \end_layout
25804
25805 \end_inset
25806 </cell>
25807 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25808 \begin_inset Text
25809
25810 \begin_layout Plain Layout
25811 Heart-like shape
25812 \end_layout
25813
25814 \end_inset
25815 </cell>
25816 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25817 \begin_inset Text
25818
25819 \begin_layout Plain Layout
25820 -
25821 \end_layout
25822
25823 \end_inset
25824 </cell>
25825 </row>
25826 <row>
25827 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25828 \begin_inset Text
25829
25830 \begin_layout Plain Layout
25831 Hexagon
25832 \end_layout
25833
25834 \end_inset
25835 </cell>
25836 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25837 \begin_inset Text
25838
25839 \begin_layout Plain Layout
25840 Hexagon
25841 \end_layout
25842
25843 \end_inset
25844 </cell>
25845 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25846 \begin_inset Text
25847
25848 \begin_layout Plain Layout
25849 -
25850 \end_layout
25851
25852 \end_inset
25853 </cell>
25854 </row>
25855 <row>
25856 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25857 \begin_inset Text
25858
25859 \begin_layout Plain Layout
25860 Nut
25861 \end_layout
25862
25863 \end_inset
25864 </cell>
25865 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25866 \begin_inset Text
25867
25868 \begin_layout Plain Layout
25869 Nut for bolt (hexagon with circular hole)
25870 \end_layout
25871
25872 \end_inset
25873 </cell>
25874 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25875 \begin_inset Text
25876
25877 \begin_layout Plain Layout
25878 -
25879 \end_layout
25880
25881 \end_inset
25882 </cell>
25883 </row>
25884 <row>
25885 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25886 \begin_inset Text
25887
25888 \begin_layout Plain Layout
25889 Square
25890 \end_layout
25891
25892 \end_inset
25893 </cell>
25894 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25895 \begin_inset Text
25896
25897 \begin_layout Plain Layout
25898 Square
25899 \end_layout
25900
25901 \end_inset
25902 </cell>
25903 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25904 \begin_inset Text
25905
25906 \begin_layout Plain Layout
25907 -
25908 \end_layout
25909
25910 \end_inset
25911 </cell>
25912 </row>
25913 <row>
25914 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25915 \begin_inset Text
25916
25917 \begin_layout Plain Layout
25918 Star
25919 \end_layout
25920
25921 \end_inset
25922 </cell>
25923 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
25924 \begin_inset Text
25925
25926 \begin_layout Plain Layout
25927 Five-point star
25928 \end_layout
25929
25930 \end_inset
25931 </cell>
25932 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
25933 \begin_inset Text
25934
25935 \begin_layout Plain Layout
25936 -
25937 \end_layout
25938
25939 \end_inset
25940 </cell>
25941 </row>
25942 <row>
25943 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25944 \begin_inset Text
25945
25946 \begin_layout Plain Layout
25947 Candle
25948 \end_layout
25949
25950 \end_inset
25951 </cell>
25952 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25953 \begin_inset Text
25954
25955 \begin_layout Plain Layout
25956 Burning candle
25957 \end_layout
25958
25959 \end_inset
25960 </cell>
25961 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25962 \begin_inset Text
25963
25964 \begin_layout Plain Layout
25965 -
25966 \end_layout
25967
25968 \end_inset
25969 </cell>
25970 </row>
25971 <row>
25972 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25973 \begin_inset Text
25974
25975 \begin_layout Plain Layout
25976 Drop down/up
25977 \end_layout
25978
25979 \end_inset
25980 </cell>
25981 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
25982 \begin_inset Text
25983
25984 \begin_layout Plain Layout
25985 Normal/reversed rain drop
25986 \end_layout
25987
25988 \end_inset
25989 </cell>
25990 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
25991 \begin_inset Text
25992
25993 \begin_layout Plain Layout
25994 Fragile, calculation might fail
25995 \end_layout
25996
25997 \end_inset
25998 </cell>
25999 </row>
26000 <row>
26001 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26002 \begin_inset Text
26003
26004 \begin_layout Plain Layout
26005 \SpecialChar TeX
26006
26007 \end_layout
26008
26009 \end_inset
26010 </cell>
26011 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26012 \begin_inset Text
26013
26014 \begin_layout Plain Layout
26015 The \SpecialChar TeX
26016  logo
26017 \end_layout
26018
26019 \end_inset
26020 </cell>
26021 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26022 \begin_inset Text
26023
26024 \begin_layout Plain Layout
26025 -
26026 \end_layout
26027
26028 \end_inset
26029 </cell>
26030 </row>
26031 <row>
26032 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26033 \begin_inset Text
26034
26035 \begin_layout Plain Layout
26036 Triangle up/down/
26037 \begin_inset Newline newline
26038 \end_inset
26039
26040 left/right
26041 \end_layout
26042
26043 \end_inset
26044 </cell>
26045 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26046 \begin_inset Text
26047
26048 \begin_layout Plain Layout
26049 Triangles in different orientations
26050 \end_layout
26051
26052 \end_inset
26053 </cell>
26054 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26055 \begin_inset Text
26056
26057 \begin_layout Plain Layout
26058 -
26059 \end_layout
26060
26061 \end_inset
26062 </cell>
26063 </row>
26064 </lyxtabular>
26065
26066 \end_inset
26067
26068
26069 \end_layout
26070
26071 \begin_layout Standard
26072 To use a shape for your paragraph, simply select it in \SpecialChar LyX
26073 's pull-down box
26074  for environments in the toolbar.
26075 \end_layout
26076
26077 \begin_layout Standard
26078 \begin_inset Newpage newpage
26079 \end_inset
26080
26081
26082 \end_layout
26083
26084 \begin_layout Standard
26085 Here is an example paragraph in the shape of a nut:
26086 \end_layout
26087
26088 \begin_layout Standard
26089 \begin_inset VSpace bigskip
26090 \end_inset
26091
26092
26093 \end_layout
26094
26095 \begin_layout Nut
26096
26097 \lang latin
26098 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26099  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26100  voluptua.
26101  At vero eos et accusam et justo duo dolores et ea rebum.
26102  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26103  sit amet.
26104  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26105  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26106  voluptua.
26107 \end_layout
26108
26109 \begin_layout Standard
26110 \begin_inset VSpace bigskip
26111 \end_inset
26112
26113
26114 \end_layout
26115
26116 \begin_layout Standard
26117 \begin_inset Note Greyedout
26118 status open
26119
26120 \begin_layout Plain Layout
26121
26122 \series bold
26123 Note
26124 \series default
26125 : shapepar paragraphs cannot run over a page break.
26126 \end_layout
26127
26128 \end_inset
26129
26130
26131 \end_layout
26132
26133 \begin_layout Standard
26134 \begin_inset VSpace bigskip
26135 \end_inset
26136
26137
26138 \end_layout
26139
26140 \begin_layout Standard
26141
26142 \series bold
26143 shapepar
26144 \series default
26145  takes care that the shape will always be preserved, no matter how much
26146  text is in the paragraph.
26147  Therefore the paragraph size changes with the amount of contained text.
26148  This can lead to paragraph sizes exceeding the page margins.
26149  To demonstrate the size scaling, here is the same example paragraph but
26150  with twice as much text:
26151 \end_layout
26152
26153 \begin_layout Standard
26154 \begin_inset Newpage newpage
26155 \end_inset
26156
26157
26158 \end_layout
26159
26160 \begin_layout Nut
26161
26162 \lang latin
26163 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26164  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26165  voluptua.
26166  At vero eos et accusam et justo duo dolores et ea rebum.
26167  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26168  sit amet.
26169  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26170  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26171  voluptua.
26172  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26173  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26174  voluptua.
26175  At vero eos et accusam et justo duo dolores et ea rebum.
26176  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26177  sit amet.
26178  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26179  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26180  voluptua.
26181 \end_layout
26182
26183 \begin_layout Standard
26184 \begin_inset VSpace bigskip
26185 \end_inset
26186
26187
26188 \end_layout
26189
26190 \begin_layout Standard
26191 An exception is the shape 
26192 \family sans
26193 CDlabel
26194 \family default
26195 .
26196  It cannot be scaled because it must fit the size of a CD/DVD.
26197  Therefore the amount of text that fits into the shape is limited.
26198 \begin_inset Newline newline
26199 \end_inset
26200
26201 The 
26202 \family sans
26203 drop
26204 \family default
26205  shapes and the 
26206 \family sans
26207 circle
26208 \family default
26209  shape are fragile, meaning that the calculation of their size can fail,
26210  depending on the amount of text.
26211  You will then get the \SpecialChar LaTeX
26212  error 
26213 \begin_inset Quotes eld
26214 \end_inset
26215
26216 Arithmetic overflow
26217 \begin_inset Quotes erd
26218 \end_inset
26219
26220 .
26221  In this case one can try to remove or add some text; if nothing works one
26222  has to use another shape.
26223 \end_layout
26224
26225 \begin_layout Standard
26226 \begin_inset VSpace bigskip
26227 \end_inset
26228
26229
26230 \end_layout
26231
26232 \begin_layout Standard
26233 For shapes with tips you will maybe see that \SpecialChar LaTeX
26234 's hyphenation routine fails
26235  for text in the tips.
26236  Therefore it is often necessary to add hyphenation points 
26237 \family sans
26238 (
26239 \begin_inset Info
26240 type  "shortcut"
26241 arg   "specialchar-insert hyphenation"
26242 \end_inset
26243
26244
26245 \family default
26246 ) to the corresponding text parts.
26247 \end_layout
26248
26249 \begin_layout Standard
26250 \begin_inset VSpace bigskip
26251 \end_inset
26252
26253
26254 \end_layout
26255
26256 \begin_layout Standard
26257 Shapepar paragraphs are either always centered or placed on the page so
26258  that their left border touches the left page margin.
26259  You can therefore not use the paragraph dialog to align such paragraphs.
26260  A solution is to put the paragraph into a minipage or parbox and align
26261  the box.
26262  The problem is hereby to find the right width for the box.
26263  Because if it is too wide and you center the box, the paragraph is not
26264  centered too because it sticks at the left side of the box.
26265  So you might have to play a bit with the width until it fits.
26266  Here are two heart-shaped paragraphs, the first one is not aligned, the
26267  second one is right-aligned:
26268 \end_layout
26269
26270 \begin_layout Standard
26271 \begin_inset Newpage newpage
26272 \end_inset
26273
26274
26275 \end_layout
26276
26277 \begin_layout Heart
26278 \noindent
26279
26280 \lang latin
26281 Lo\SpecialChar softhyphen
26282 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26283  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26284  voluptua.
26285  At vero eos et accusam et justo duo dolores et ea rebum.
26286  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26287  sit amet.
26288 \end_layout
26289
26290 \begin_layout Standard
26291 \begin_inset VSpace bigskip
26292 \end_inset
26293
26294
26295 \end_layout
26296
26297 \begin_layout Standard
26298 \noindent
26299 \align right
26300 \begin_inset Box Frameless
26301 position "t"
26302 hor_pos "c"
26303 has_inner_box 1
26304 inner_pos "t"
26305 use_parbox 1
26306 use_makebox 0
26307 width "42col%"
26308 special "none"
26309 height "1in"
26310 height_special "totalheight"
26311 thickness "0.4pt"
26312 separation "3pt"
26313 shadowsize "4pt"
26314 framecolor "black"
26315 backgroundcolor "none"
26316 status open
26317
26318 \begin_layout Heart
26319 \noindent
26320
26321 \lang latin
26322 Lo\SpecialChar softhyphen
26323 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26324  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26325  voluptua.
26326  At vero eos et accusam et justo duo dolores et ea rebum.
26327  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26328  sit amet.
26329 \end_layout
26330
26331 \end_inset
26332
26333
26334 \end_layout
26335
26336 \begin_layout Subsection
26337 Custom shapes
26338 \end_layout
26339
26340 \begin_layout Standard
26341 You can define any shape you want.
26342  Doing this manually is a lot of work because every coordinate must be specified.
26343  But there is a way to let the computer calculate the coordinates:
26344 \end_layout
26345
26346 \begin_layout Enumerate
26347 Install the program 
26348 \begin_inset CommandInset href
26349 LatexCommand href
26350 name "Jpgfdraw"
26351 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
26352
26353 \end_inset
26354
26355 .
26356 \end_layout
26357
26358 \begin_layout Enumerate
26359 In 
26360 \family sans
26361 Jpgfdraw
26362 \family default
26363  go to the menu 
26364 \family sans
26365 TeX/LaTeX\SpecialChar menuseparator
26366 Settings\SpecialChar menuseparator
26367 Set Normal Size
26368 \family default
26369  and select the font size you are using in your document.
26370  For example this document uses the size 12
26371 \begin_inset space \thinspace{}
26372 \end_inset
26373
26374 pt.
26375 \end_layout
26376
26377 \begin_layout Enumerate
26378 Draw a shape.
26379 \end_layout
26380
26381 \begin_layout Enumerate
26382 Use the menu 
26383 \family sans
26384 TeX/LaTeX\SpecialChar menuseparator
26385 Shapepar
26386 \family default
26387  to export the shape to coordinates.
26388  In the appearing dialog use either the outline of your shape for the coordinate
26389 s or the path itself.
26390 \begin_inset Foot
26391 status collapsed
26392
26393 \begin_layout Plain Layout
26394 For more information see 
26395 \begin_inset CommandInset href
26396 LatexCommand href
26397 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
26398
26399 \end_inset
26400
26401
26402 \end_layout
26403
26404 \end_inset
26405
26406
26407 \end_layout
26408
26409 \begin_layout Standard
26410 The coordinates are written into a \SpecialChar TeX
26411  file.
26412  To use it for your \SpecialChar LyX
26413  document
26414 \end_layout
26415
26416 \begin_layout Enumerate
26417 Place the cursor before the first character of your paragraph (or into a
26418  new empty one).
26419 \end_layout
26420
26421 \begin_layout Enumerate
26422 Open in \SpecialChar LyX
26423  the menu 
26424 \family sans
26425 Insert\SpecialChar menuseparator
26426 File\SpecialChar menuseparator
26427 Child
26428 \begin_inset space ~
26429 \end_inset
26430
26431 Document
26432 \family default
26433 , select the file and use 
26434 \family sans
26435 Input
26436 \family default
26437  as 
26438 \family sans
26439 Include Type.
26440 \end_layout
26441
26442 \begin_layout Standard
26443 \begin_inset VSpace defskip
26444 \end_inset
26445
26446
26447 \end_layout
26448
26449 \begin_layout Standard
26450 \begin_inset Note Greyedout
26451 status open
26452
26453 \begin_layout Plain Layout
26454
26455 \series bold
26456 Note
26457 \series default
26458 : The changed shape only applies to the current paragraph; everything is
26459  reset to normal for the next paragraph.
26460  Therefore the shape definition file must be input into every paragraph
26461  with the desired shape.
26462 \end_layout
26463
26464 \end_inset
26465
26466
26467 \end_layout
26468
26469 \begin_layout Standard
26470 \begin_inset VSpace bigskip
26471 \end_inset
26472
26473
26474 \end_layout
26475
26476 \begin_layout Standard
26477 Here is an example:
26478 \end_layout
26479
26480 \begin_layout Standard
26481 \begin_inset VSpace bigskip
26482 \end_inset
26483
26484
26485 \end_layout
26486
26487 \begin_layout Standard
26488 \begin_inset CommandInset include
26489 LatexCommand input
26490 filename "SpecialParagraphShape.tex"
26491
26492 \end_inset
26493
26494
26495 \lang latin
26496 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26497  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26498  voluptua.
26499  At vero eos et accusam et justo duo dolores et ea rebum.
26500  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26501  sit amet.
26502  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26503  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26504  voluptua.
26505 \end_layout
26506
26507 \begin_layout Standard
26508 \begin_inset VSpace bigskip
26509 \end_inset
26510
26511
26512 \end_layout
26513
26514 \begin_layout Standard
26515
26516 \series bold
26517 A tip:
26518 \series default
26519  to draw complexer shapes in 
26520 \family sans
26521 Jpgfdraw
26522 \family default
26523  you can draw the shape in a program of your choice and import the resulting
26524  image to 
26525 \family sans
26526 Jpgfdraw
26527 \family default
26528 .
26529  Then you only need to draw a line or spline along the outline of the image.
26530 \end_layout
26531
26532 \begin_layout Standard
26533 \begin_inset VSpace bigskip
26534 \end_inset
26535
26536
26537 \end_layout
26538
26539 \begin_layout Standard
26540 The module 
26541 \family sans
26542 Custom paragraph shapes
26543 \family default
26544  also provides the two commands 
26545 \family sans
26546 shapepar
26547 \family default
26548  and 
26549 \family sans
26550 Shapepar
26551 \family default
26552  which can be used to define custom shapes coordinate by coordinate.
26553 \begin_inset Foot
26554 status collapsed
26555
26556 \begin_layout Plain Layout
26557 These commands are internally used for all shapes described here.
26558 \end_layout
26559
26560 \end_inset
26561
26562  For information how these styles are used and about further customization
26563  possibilities, have a look at the documentation of the package 
26564 \series bold
26565 shapepar
26566 \series default
26567
26568 \begin_inset CommandInset citation
26569 LatexCommand cite
26570 key "shapepar"
26571
26572 \end_inset
26573
26574 .
26575 \end_layout
26576
26577 \begin_layout Bibliography
26578 \begin_inset CommandInset bibitem
26579 LatexCommand bibitem
26580 key "multicol"
26581
26582 \end_inset
26583
26584 Documentation of the \SpecialChar LaTeX
26585 -package 
26586 \begin_inset CommandInset href
26587 LatexCommand href
26588 name "multicol"
26589 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
26590
26591 \end_inset
26592
26593
26594 \end_layout
26595
26596 \begin_layout Bibliography
26597 \begin_inset CommandInset bibitem
26598 LatexCommand bibitem
26599 key "shapepar"
26600
26601 \end_inset
26602
26603 Documentation of the \SpecialChar LaTeX
26604 -package 
26605 \begin_inset CommandInset href
26606 LatexCommand href
26607 name "shapepar"
26608 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"
26609
26610 \end_inset
26611
26612
26613 \end_layout
26614
26615 \end_body
26616 \end_document