]> git.lyx.org Git - features.git/blob - lib/doc/Additional.lyx
Rm dup "Float" in "Insert>Float>Figure Wrap Float"
[features.git] / lib / doc / Additional.lyx
1 #LyX 2.4 created this file. For more info see https://www.lyx.org/
2 \lyxformat 609
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 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 no
41 \language english
42 \language_package default
43 \inputencoding utf8
44 \fontencoding auto
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_roman_osf false
53 \font_sans_osf false
54 \font_typewriter_osf false
55 \font_sf_scale 100 100
56 \font_tt_scale 100 100
57 \use_microtype false
58 \use_dash_ligatures true
59 \graphics default
60 \default_output_format pdf2
61 \output_sync 0
62 \bibtex_command default
63 \index_command default
64 \paperfontsize 12
65 \spacing single
66 \use_hyperref true
67 \pdf_title "LyX's Additional Features manual"
68 \pdf_author "LyX Team"
69 \pdf_subject "LyX's additional features documentation"
70 \pdf_keywords "LyX, Documentation, Additional"
71 \pdf_bookmarks true
72 \pdf_bookmarksnumbered true
73 \pdf_bookmarksopen false
74 \pdf_bookmarksopenlevel 1
75 \pdf_breaklinks false
76 \pdf_pdfborder false
77 \pdf_colorlinks true
78 \pdf_backref false
79 \pdf_pdfusetitle false
80 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
81 \papersize a4
82 \use_geometry false
83 \use_package amsmath 1
84 \use_package amssymb 1
85 \use_package cancel 1
86 \use_package esint 1
87 \use_package mathdots 1
88 \use_package mathtools 1
89 \use_package mhchem 1
90 \use_package stackrel 1
91 \use_package stmaryrd 1
92 \use_package undertilde 1
93 \cite_engine basic
94 \cite_engine_type default
95 \biblio_style plain
96 \use_bibtopic false
97 \use_indices false
98 \paperorientation portrait
99 \suppress_date false
100 \justification true
101 \use_refstyle 0
102 \use_minted 0
103 \use_lineno 0
104 \notefontcolor #0000ff
105 \index Index
106 \shortcut idx
107 \color #008000
108 \end_index
109 \secnumdepth 3
110 \tocdepth 3
111 \paragraph_separation indent
112 \paragraph_indentation default
113 \is_math_indent 1
114 \math_indentation default
115 \math_numbering_side default
116 \quotes_style english
117 \dynamic_quotes 0
118 \papercolumns 1
119 \papersides 2
120 \paperpagestyle headings
121 \tablestyle default
122 \tracking_changes true
123 \output_changes false
124 \change_bars false
125 \postpone_fragile_content false
126 \html_math_output 0
127 \html_css_as_file 0
128 \html_be_strict true
129 \docbook_table_output 0
130 \docbook_mathml_prefix 1
131 \author -712698321 "Jürgen Spitzmüller"
132 \author 177693 "x"
133 \author 5863208 "ab"
134 \author 244031559 "Yuriy"
135 \author 630872221 "Jean-Pierre Chrétien" jeanpierre.chretien@free.fr
136 \author 1075283030 "Thibaut"
137 \author 1119979965 "Joel A. Kulesza"
138 \end_header
139
140 \begin_body
141
142 \begin_layout Title
143 Additional \SpecialChar LyX
144  Features
145 \end_layout
146
147 \begin_layout Subtitle
148 Version 2.
149 \change_deleted 630872221 1622909155
150 3
151 \change_inserted 630872221 1622909155
152 4
153 \change_unchanged
154 .x
155 \end_layout
156
157 \begin_layout Author
158 by the \SpecialChar LyX
159  Team
160 \begin_inset Foot
161 status collapsed
162
163 \begin_layout Plain Layout
164 \noindent
165 Principal maintainer of this file is
166 \noun on
167  Richard Kimberly Heck
168 \noun default
169 .
170  If you have comments or error corrections, please send them to the \SpecialChar LyX
171  Documentati
172 on mailing list, 
173 \begin_inset Flex Code
174 status collapsed
175
176 \begin_layout Plain Layout
177 <lyx-docs@lists.lyx.org>
178 \end_layout
179
180 \end_inset
181
182 .
183 \end_layout
184
185 \end_inset
186
187
188 \end_layout
189
190 \begin_layout Standard
191 \begin_inset CommandInset toc
192 LatexCommand tableofcontents
193
194 \end_inset
195
196
197 \end_layout
198
199 \begin_layout Chapter
200 Introduction
201 \end_layout
202
203 \begin_layout Standard
204 This manual is essentially Part II of the 
205 \emph on
206 User's Guide\SpecialChar endofsentence
207
208 \emph default
209  The reason for separating the two documents is simple: the 
210 \emph on
211 User's Guide
212 \emph default
213  is already quite lengthy, and it contains information on all of the basic
214  features one needs to know in order to prepare most documents.
215  However, the \SpecialChar LyX
216  Team has worked to make \SpecialChar LyX
217  extensible through various configuration
218  files and external packages.
219  That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
220  package, you can
221  create a layout file (or module) for it without having to alter \SpecialChar LyX
222  itself.
223  We've already had contributions of several new features this way, and some
224  of them are documented here.
225  There are also some more `advanced' features, such as how to control the
226  presentation of bibliographies and how to work with multi-part documents,
227  that are not covered in the 
228 \emph on
229 User's Guide
230 \emph default
231  and are discussed here.
232 \end_layout
233
234 \begin_layout Standard
235 This manual also documents some special features, like fax support
236 \change_deleted 244031559 1603802929
237 ,
238 \change_inserted 244031559 1603802931
239  and
240 \change_unchanged
241  version control
242 \change_deleted 244031559 1603802954
243 , and SGML support
244 \change_unchanged
245 , which require additional software to work properly.
246  There is also a chapter on \SpecialChar LyX
247 's support for HTML.
248  And lastly, there's a chapter of \SpecialChar LaTeX
249  tools and tips, things you can use to
250  spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
251 .
252  After all, \SpecialChar LyX
253  
254 \emph on
255 is
256 \emph default
257  only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
258  features.
259 \end_layout
260
261 \begin_layout Standard
262 If you haven't read the 
263 \emph on
264 Introduction
265 \emph default
266  yet, you are definitely in the wrong manual.
267  The 
268 \emph on
269 Introduction
270 \emph default
271  is the first place to go, since it describes the notation and format of
272  all of the manuals.
273  You should also be thoroughly familiar with the 
274 \emph on
275 User's Guide
276 \emph default
277  and all of the basic features of \SpecialChar LyX
278  before attempting to read this one.
279 \end_layout
280
281 \begin_layout Standard
282 Since many of the topics in this manual depend heavily on \SpecialChar LyX
283 's interaction
284  with \SpecialChar LaTeX
285 , this first chapter covers the inner workings of \SpecialChar LyX
286  and how to direct
287  \SpecialChar LyX
288  to generate exactly the \SpecialChar LaTeX
289  code you want.
290  It is obviously for more seasoned \SpecialChar LyX
291  users.
292 \end_layout
293
294 \begin_layout Chapter
295 \SpecialChar LyX
296  and \SpecialChar LaTeX
297
298 \end_layout
299
300 \begin_layout Section
301 How \SpecialChar LyX
302  Uses \SpecialChar LaTeX
303
304 \end_layout
305
306 \begin_layout Standard
307 This chapter is for both \SpecialChar TeX
308 -nicians and the \SpecialChar LaTeX
309 -curious.
310  In it, we'll explain how \SpecialChar LyX
311  and \SpecialChar LaTeX
312  work together to produce printable output.
313  This is the only place in any of the manuals where we assume you know something
314  about \SpecialChar LaTeX
315 .
316 \end_layout
317
318 \begin_layout Standard
319 At one time, \SpecialChar LyX
320  was called a 
321 \begin_inset Quotes eld
322 \end_inset
323
324 WYSIWYM frontend to \SpecialChar LaTeX
325 ,
326 \begin_inset Quotes erd
327 \end_inset
328
329  but that's no longer true.
330  There are frontends to \SpecialChar LaTeX
331  out there.
332 \begin_inset Foot
333 status collapsed
334
335 \begin_layout Plain Layout
336 Some familar ones are \SpecialChar TeX
337 maker and kile, on Linux, and \SpecialChar TeX
338 shop, OSX.
339  There are also the \SpecialChar LaTeX
340  modes for vi and emacs, of course.
341 \end_layout
342
343 \end_inset
344
345  These are basically text editors with the ability to run \SpecialChar LaTeX
346  and mark any
347  errors in the file you're editing.
348  Although \SpecialChar LyX
349  
350 \emph on
351 is
352 \emph default
353  an editor, and it 
354 \emph on
355 does
356 \emph default
357  run \SpecialChar LaTeX
358 , and it also indicates errors in the file, it also does much, much
359  more.
360  For one thing, you don't need to know \SpecialChar LaTeX
361  to use \SpecialChar LyX
362  effectively.
363  And \SpecialChar LyX
364  has added its own extensions to \SpecialChar LaTeX
365 .
366  Try the following sometime: select 
367 \begin_inset Flex Noun
368 status collapsed
369
370 \begin_layout Plain Layout
371 Export\SpecialChar menuseparator
372 LaTeX
373 \end_layout
374
375 \end_inset
376
377  from the 
378 \begin_inset Flex Noun
379 status collapsed
380
381 \begin_layout Plain Layout
382 File
383 \end_layout
384
385 \end_inset
386
387  menu (or 
388 \begin_inset Flex Noun
389 status collapsed
390
391 \begin_layout Plain Layout
392 View\SpecialChar menuseparator
393 Source
394 \begin_inset space ~
395 \end_inset
396
397 Pane
398 \end_layout
399
400 \end_inset
401
402 ), then look at the preamble of the resulting 
403 \begin_inset Flex Code
404 status collapsed
405
406 \begin_layout Plain Layout
407 .tex
408 \end_layout
409
410 \end_inset
411
412  file.
413  You'll notice a variety of new macros defined specifically by \SpecialChar LyX
414 .
415  These macros are defined automatically, according to the features you use
416  in the document.
417 \end_layout
418
419 \begin_layout Standard
420 There are several commands that automatically invoke \SpecialChar LaTeX
421 .
422  They are:
423 \end_layout
424
425 \begin_layout Itemize
426 \begin_inset Flex Noun
427 status collapsed
428
429 \begin_layout Plain Layout
430 Document\SpecialChar menuseparator
431 View
432 \end_layout
433
434 \end_inset
435
436
437 \end_layout
438
439 \begin_layout Itemize
440 \begin_inset Flex Noun
441 status collapsed
442
443 \begin_layout Plain Layout
444 Document\SpecialChar menuseparator
445 Update
446 \end_layout
447
448 \end_inset
449
450
451 \end_layout
452
453 \begin_layout Standard
454 They will only invoke \SpecialChar LaTeX
455  if the file has changed since the last time \SpecialChar LaTeX
456  was
457  run.
458  
459 \end_layout
460
461 \begin_layout Standard
462 When \SpecialChar LyX
463  runs \SpecialChar LaTeX
464  on the file you're editing, it performs these steps:
465 \end_layout
466
467 \begin_layout Enumerate
468 Convert the document to \SpecialChar LaTeX
469  and save to a file with the extension 
470 \begin_inset Flex Code
471 status collapsed
472
473 \begin_layout Plain Layout
474 .tex
475 \end_layout
476
477 \end_inset
478
479  in place of 
480 \begin_inset Flex Code
481 status collapsed
482
483 \begin_layout Plain Layout
484 .lyx
485 \end_layout
486
487 \end_inset
488
489 .
490 \end_layout
491
492 \begin_layout Enumerate
493 Run \SpecialChar LaTeX
494  on the 
495 \begin_inset Flex Code
496 status collapsed
497
498 \begin_layout Plain Layout
499 .tex
500 \end_layout
501
502 \end_inset
503
504  file (maybe several times), and run any other commands (such as 
505 \begin_inset Flex Code
506 status collapsed
507
508 \begin_layout Plain Layout
509 bibtex
510 \end_layout
511
512 \end_inset
513
514  or 
515 \begin_inset Flex Code
516 status collapsed
517
518 \begin_layout Plain Layout
519 makeindex
520 \end_layout
521
522 \end_inset
523
524 ) needed to compile the \SpecialChar LaTeX
525  file.
526 \end_layout
527
528 \begin_layout Enumerate
529 If there are any errors, show the error log.
530 \end_layout
531
532 \begin_layout Standard
533 If you have run \SpecialChar LaTeX
534  using 
535 \begin_inset Flex Noun
536 status collapsed
537
538 \begin_layout Plain Layout
539 View\SpecialChar menuseparator
540 DVI
541 \end_layout
542
543 \end_inset
544
545 , \SpecialChar LyX
546  then runs a DVI viewer to display the DVI-file.
547  If you have used 
548 \begin_inset Flex Noun
549 status collapsed
550
551 \begin_layout Plain Layout
552 View\SpecialChar menuseparator
553 PostScript
554 \end_layout
555
556 \end_inset
557
558 , \SpecialChar LyX
559  performs further steps:
560 \end_layout
561
562 \begin_layout Enumerate
563 Run 
564 \begin_inset Flex Code
565 status collapsed
566
567 \begin_layout Plain Layout
568 dvips
569 \end_layout
570
571 \end_inset
572
573  to convert the DVI file to PostScript.
574 \end_layout
575
576 \begin_layout Enumerate
577 Run a PostScript viewer, such as 
578 \begin_inset Flex Code
579 status collapsed
580
581 \begin_layout Plain Layout
582 ghostview
583 \end_layout
584
585 \end_inset
586
587 , to display the PostScript file.
588 \end_layout
589
590 \begin_layout Standard
591 \SpecialChar LyX
592  does similar things when viewing, or exporting, other formats.
593 \end_layout
594
595 \begin_layout Section
596 Translating \SpecialChar LaTeX
597  files into \SpecialChar LyX
598
599 \end_layout
600
601 \begin_layout Standard
602 You can import a \SpecialChar LaTeX
603  file into \SpecialChar LyX
604  by using the 
605 \begin_inset Flex Noun
606 status collapsed
607
608 \begin_layout Plain Layout
609 File\SpecialChar menuseparator
610 Import\SpecialChar menuseparator
611 LaTeX
612 \end_layout
613
614 \end_inset
615
616  command in \SpecialChar LyX
617 .
618  This will call a program named 
619 \begin_inset Flex Code
620 status collapsed
621
622 \begin_layout Plain Layout
623 tex2lyx
624 \end_layout
625
626 \end_inset
627
628  which will create a file 
629 \begin_inset Flex Code
630 status collapsed
631
632 \begin_layout Plain Layout
633 foo.lyx
634 \end_layout
635
636 \end_inset
637
638  from the file 
639 \begin_inset Flex Code
640 status collapsed
641
642 \begin_layout Plain Layout
643 foo.tex
644 \end_layout
645
646 \end_inset
647
648 .
649  \SpecialChar LyX
650  will then open that file.
651 \begin_inset Foot
652 status collapsed
653
654 \begin_layout Plain Layout
655 \begin_inset Flex Code
656 status collapsed
657
658 \begin_layout Plain Layout
659 tex2lyx
660 \end_layout
661
662 \end_inset
663
664  can also be run from the command line, of course.
665 \end_layout
666
667 \end_inset
668
669
670 \end_layout
671
672 \begin_layout Standard
673 \begin_inset Flex Code
674 status collapsed
675
676 \begin_layout Plain Layout
677 tex2lyx
678 \end_layout
679
680 \end_inset
681
682  will translate most legal \SpecialChar LaTeX
683 , but not everything.
684  It will put things it doesn't understand into \SpecialChar TeX
685  code, so after translating
686  a file with 
687 \begin_inset Flex Code
688 status collapsed
689
690 \begin_layout Plain Layout
691 tex2lyx
692 \end_layout
693
694 \end_inset
695
696 , you can look for \SpecialChar TeX
697  code and hand-edit it until it looks right.
698 \end_layout
699
700 \begin_layout Standard
701 If you don't know what \SpecialChar TeX
702  code is, read the next section.
703 \end_layout
704
705 \begin_layout Section
706 \begin_inset CommandInset label
707 LatexCommand label
708 name "sec:Inserting-TeX-Code"
709
710 \end_inset
711
712 Inserting \SpecialChar TeX
713  Code into \SpecialChar LyX
714  Documents 
715 \end_layout
716
717 \begin_layout Standard
718 Anything you can do in \SpecialChar LaTeX
719  you can do in \SpecialChar LyX
720 , for a very simple reason: You can
721  always insert \SpecialChar TeX
722  code into any \SpecialChar LyX
723  document.
724  \SpecialChar LyX
725  cannot, and will never be able to, display every possible \SpecialChar LaTeX
726  construct.
727  If ever you need to insert \SpecialChar LaTeX
728  commands into your \SpecialChar LyX
729  document, you can use the
730  
731 \begin_inset Flex Code
732 status collapsed
733
734 \begin_layout Plain Layout
735 \SpecialChar TeX
736  Code
737 \end_layout
738
739 \end_inset
740
741  box, which you can insert into your document with 
742 \begin_inset Flex Noun
743 status collapsed
744
745 \begin_layout Plain Layout
746 Insert\SpecialChar menuseparator
747
748 \family sans
749 TeX
750 \family default
751  Code
752 \end_layout
753
754 \end_inset
755
756  or the keyboard shortcut 
757 \begin_inset Info
758 type  "shortcut"
759 arg   "ert-insert"
760 \end_inset
761
762 .
763 \end_layout
764
765 \begin_layout Standard
766 Here's an example of inserting \SpecialChar LaTeX
767  commands in a \SpecialChar LyX
768  document.
769  The code looks like this:
770 \end_layout
771
772 \begin_layout LyX-Code
773
774 \backslash
775 begin{tabular}{ll}
776 \begin_inset Newline newline
777 \end_inset
778
779
780 \backslash
781 begin{minipage}{5cm}
782 \begin_inset Newline newline
783 \end_inset
784
785 This is an example of a minipage environment.
786  You 
787 \begin_inset Newline newline
788 \end_inset
789
790 can put nearly everything in it, even (non-floating) 
791 \begin_inset Newline newline
792 \end_inset
793
794 figures and tables.
795  
796 \begin_inset Newline newline
797 \end_inset
798
799
800 \backslash
801 end{minipage}
802 \begin_inset Newline newline
803 \end_inset
804
805 &
806 \begin_inset Newline newline
807 \end_inset
808
809
810 \backslash
811 begin{minipage}{5cm}
812 \begin_inset Newline newline
813 \end_inset
814
815
816 \backslash
817 begin{verbatim}
818 \begin_inset Newline newline
819 \end_inset
820
821
822 \backslash
823 begin{minipage}{5cm}
824 \begin_inset Newline newline
825 \end_inset
826
827 This ...
828  
829 \begin_inset Newline newline
830 \end_inset
831
832
833 \backslash
834 end{minipage}
835 \begin_inset Newline newline
836 \end_inset
837
838
839 \backslash
840 end{verbatim}
841 \begin_inset Newline newline
842 \end_inset
843
844
845 \backslash
846 end{minipage}
847 \begin_inset Newline newline
848 \end_inset
849
850
851 \backslash
852 end{tabular}
853 \end_layout
854
855 \begin_layout LyX-Code
856
857 \end_layout
858
859 \begin_layout Standard
860 The 
861 \begin_inset Flex Code
862 status collapsed
863
864 \begin_layout Plain Layout
865 \SpecialChar TeX
866  Code
867 \end_layout
868
869 \end_inset
870
871  box containing this text is directly after this paragraph.
872  Those of you reading the manual in \SpecialChar LyX
873  will only see the \SpecialChar TeX
874  code inset.
875  Those reading a printed version of the manuals will see the actual results:
876 \begin_inset VSpace bigskip
877 \end_inset
878
879
880 \end_layout
881
882 \begin_layout Standard
883 \begin_inset ERT
884 status open
885
886 \begin_layout Plain Layout
887
888
889 \backslash
890 begin{tabular}{ll}
891 \end_layout
892
893 \begin_layout Plain Layout
894
895
896 \backslash
897 begin{minipage}{5cm}
898 \end_layout
899
900 \begin_layout Plain Layout
901
902 This is an example of a minipage environment.
903  You can put nearly everything in it, even (non-floating) figures and tables.
904  
905 \end_layout
906
907 \begin_layout Plain Layout
908
909
910 \backslash
911 end{minipage}
912 \end_layout
913
914 \begin_layout Plain Layout
915
916 &
917 \end_layout
918
919 \begin_layout Plain Layout
920
921
922 \backslash
923 begin{minipage}{5cm}
924 \end_layout
925
926 \begin_layout Plain Layout
927
928
929 \backslash
930 begin{verbatim}
931 \end_layout
932
933 \begin_layout Plain Layout
934
935
936 \backslash
937 begin{minipage}{5cm}
938 \end_layout
939
940 \begin_layout Plain Layout
941
942 This ...
943  
944 \end_layout
945
946 \begin_layout Plain Layout
947
948
949 \backslash
950 end{minipage}
951 \end_layout
952
953 \begin_layout Plain Layout
954
955
956 \backslash
957 end{verbatim}
958 \end_layout
959
960 \begin_layout Plain Layout
961
962
963 \backslash
964 end{minipage}
965 \end_layout
966
967 \begin_layout Plain Layout
968
969
970 \backslash
971 end{tabular}
972 \end_layout
973
974 \end_inset
975
976
977 \begin_inset VSpace bigskip
978 \end_inset
979
980
981 \end_layout
982
983 \begin_layout Standard
984 In addition to using \SpecialChar TeX
985  code, you can also create a separate file containing
986  some complex \SpecialChar LaTeX
987  structure and then use 
988 \begin_inset Flex Noun
989 status collapsed
990
991 \begin_layout Plain Layout
992 Insert\SpecialChar menuseparator
993 Child
994 \begin_inset space ~
995 \end_inset
996
997 Document
998 \end_layout
999
1000 \end_inset
1001
1002  to include your file (you should select the type 
1003 \begin_inset Flex Code
1004 status collapsed
1005
1006 \begin_layout Plain Layout
1007 Input
1008 \end_layout
1009
1010 \end_inset
1011
1012 ).
1013  We recommend that you only do this if you have a 
1014 \begin_inset Flex Code
1015 status collapsed
1016
1017 \begin_layout Plain Layout
1018 .tex
1019 \end_layout
1020
1021 \end_inset
1022
1023  file which you 
1024 \emph on
1025 know
1026 \emph default
1027  works already.
1028  Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
1029  errors.
1030 \end_layout
1031
1032 \begin_layout Standard
1033 There are a few last points to emphasize:
1034 \end_layout
1035
1036 \begin_layout Itemize
1037 \SpecialChar LyX
1038  
1039 \emph on
1040 does not
1041 \emph default
1042  check if your \SpecialChar LaTeX
1043  code is correct.
1044 \end_layout
1045
1046 \begin_layout Itemize
1047 Beware of reinventing the wheel.
1048 \end_layout
1049
1050 \begin_layout Standard
1051 On that last point, \SpecialChar LyX
1052  does have quite a few features tucked into it, and
1053  more are coming.
1054  Be sure to check the manuals to make sure that \SpecialChar LyX
1055  doesn't have such-and-such
1056  feature before you decide you have to do it by hand.
1057  Moreover, there are numerous \SpecialChar LaTeX
1058  packages out there to do all sorts of things,
1059  from labels to envelopes to fancy multipage tables.
1060  Check out 
1061 \change_inserted 244031559 1603815732
1062
1063 \begin_inset CommandInset href
1064 LatexCommand href
1065 name "CTAN"
1066 target "https://www.ctan.org/"
1067 literal "false"
1068
1069 \end_inset
1070
1071
1072 \change_deleted 244031559 1603815732
1073
1074 \begin_inset CommandInset href
1075 LatexCommand href
1076 name "CTAN"
1077 target "http://www.ctan.org/"
1078 literal "false"
1079
1080 \end_inset
1081
1082
1083 \change_unchanged
1084  for details.
1085 \end_layout
1086
1087 \begin_layout Standard
1088 If you do need to do some wild and fancy things within your document, be
1089  sure to check out a good \SpecialChar LaTeX
1090  book for assistance.
1091  There are a number of them listed in the bibliography of the 
1092 \emph on
1093 User's Guide
1094 \emph default
1095 .
1096 \end_layout
1097
1098 \begin_layout Section
1099 \SpecialChar LyX
1100  and the \SpecialChar LaTeX
1101  Preamble
1102 \end_layout
1103
1104 \begin_layout Subsection
1105 About the \SpecialChar LaTeX
1106  Preamble
1107 \end_layout
1108
1109 \begin_layout Standard
1110 If you already know \SpecialChar LaTeX
1111 , there is no need to explain here what the preamble
1112  is good for.
1113  If you don't, the following will give you some ideas—we recommend again
1114  that you consult a \SpecialChar LaTeX
1115  book for further information.
1116  In any case, you should read the points below, because they explain what
1117  you can do and what you don't need to do in the \SpecialChar LaTeX
1118  preamble of a \SpecialChar LyX
1119  document.
1120 \end_layout
1121
1122 \begin_layout Standard
1123 The \SpecialChar LaTeX
1124  preamble comes at the very beginning of a document, 
1125 \emph on
1126 before
1127 \emph default
1128  the text.
1129  It serves to:
1130 \end_layout
1131
1132 \begin_layout Itemize
1133 Declare the document class.
1134  
1135 \begin_inset Newline newline
1136 \end_inset
1137
1138 \SpecialChar LyX
1139  already does this for you.
1140  If you're a seasoned \SpecialChar LaTeX
1141 -nician, and you have a custom document class you
1142  want to use, check out the 
1143 \emph on
1144 Customization Manual
1145 \emph default
1146  for information on how to make \SpecialChar LyX
1147  interface to it.
1148 \end_layout
1149
1150 \begin_layout Itemize
1151 Declare the usage of packages.
1152  
1153 \begin_inset Newline newline
1154 \end_inset
1155
1156 \SpecialChar LaTeX
1157  packages provide special commands, which are only available within a document
1158  when the package has been declared in the preamble.
1159  In addition to providing special commands, the inclusion of a package can
1160  change the document.
1161  For example, the package 
1162 \begin_inset Flex Code
1163 status collapsed
1164
1165 \begin_layout Plain Layout
1166 indentfirst
1167 \end_layout
1168
1169 \end_inset
1170
1171  forces all paragraphs to be indented.
1172  There are other packages for labels, envelopes, margins, etc.
1173  
1174 \end_layout
1175
1176 \begin_layout Itemize
1177 Set counters, variables, lengths and widths.
1178  
1179 \begin_inset Newline newline
1180 \end_inset
1181
1182 There are several \SpecialChar LaTeX
1183  counters and variables that 
1184 \emph on
1185 must
1186 \emph default
1187  be set globally from within the preamble in order to have the desired effect.
1188  (There are variables that you can set and reset inside the document, too.)
1189  Margins are a good example of something that must be set in the preamble.
1190  Another example is the label format for lists.
1191  You can actually set these just about anywhere, but it's best to do it
1192  just once, inside the preamble.
1193 \end_layout
1194
1195 \begin_layout Itemize
1196 Declare user defined commands (with 
1197 \begin_inset Flex Code
1198 status collapsed
1199
1200 \begin_layout Plain Layout
1201
1202 \backslash
1203 newcommand
1204 \end_layout
1205
1206 \end_inset
1207
1208  or 
1209 \begin_inset Flex Code
1210 status collapsed
1211
1212 \begin_layout Plain Layout
1213
1214 \backslash
1215 renewcommand
1216 \end_layout
1217
1218 \end_inset
1219
1220 ).
1221 \begin_inset Newline newline
1222 \end_inset
1223
1224 These are abbreviations for \SpecialChar LaTeX
1225  commands which appear very often inside a document.
1226  Although the preamble is a good place to declare such commands, they 
1227 \emph on
1228 can
1229 \emph default
1230  be declared anywhere (before they are used for the first time, of course).
1231  This can be useful if there is a lot of raw \SpecialChar LaTeX
1232  code in your document, which
1233  normally should not be the case.
1234 \end_layout
1235
1236 \begin_layout Standard
1237 \SpecialChar LyX
1238  adds its own set of definitions to the preamble of the 
1239 \begin_inset Flex Code
1240 status collapsed
1241
1242 \begin_layout Plain Layout
1243 .tex
1244 \end_layout
1245
1246 \end_inset
1247
1248  file it produces.
1249  This makes \SpecialChar LaTeX
1250  files generated by \SpecialChar LyX
1251  portable.
1252 \end_layout
1253
1254 \begin_layout Subsection
1255 Changing the Preamble
1256 \end_layout
1257
1258 \begin_layout Standard
1259 The commands which \SpecialChar LyX
1260  adds to the preamble of a \SpecialChar LaTeX
1261  file are fixed; you can't
1262  change them without patching \SpecialChar LyX
1263  itself.
1264  You can, however, add your own stuff to the preamble by selecting 
1265 \begin_inset Flex Noun
1266 status collapsed
1267
1268 \begin_layout Plain Layout
1269 \SpecialChar LaTeX
1270
1271 \begin_inset space ~
1272 \end_inset
1273
1274 Preamble
1275 \end_layout
1276
1277 \end_inset
1278
1279  in the 
1280 \begin_inset Flex Noun
1281 status collapsed
1282
1283 \begin_layout Plain Layout
1284 Document\SpecialChar menuseparator
1285 Settings
1286 \end_layout
1287
1288 \end_inset
1289
1290  dialog.
1291  \SpecialChar LyX
1292  adds anything in the 
1293 \begin_inset Flex Noun
1294 status collapsed
1295
1296 \begin_layout Plain Layout
1297 Preamble
1298 \end_layout
1299
1300 \end_inset
1301
1302  dialog to its own built-in preamble.
1303  Before adding your own declarations in the preamble, you should make sure
1304  that \SpecialChar LyX
1305  doesn't already support what you want to do.
1306  (Remember what we said about reinventing the wheel?) Also, 
1307 \emph on
1308 make sure your preamble code is correct
1309 \emph default
1310 .
1311  \SpecialChar LyX
1312  doesn't check it for you.
1313  If there is an error, you're likely to get an error like 
1314 \begin_inset Quotes eld
1315 \end_inset
1316
1317
1318 \begin_inset Flex Code
1319 status collapsed
1320
1321 \begin_layout Plain Layout
1322 Missing 
1323 \backslash
1324 begin{document}
1325 \end_layout
1326
1327 \end_inset
1328
1329
1330 \begin_inset Quotes erd
1331 \end_inset
1332
1333 .
1334  If you see this error, check your preamble.
1335 \end_layout
1336
1337 \begin_layout Subsection
1338 Examples
1339 \end_layout
1340
1341 \begin_layout Standard
1342 Here are some examples of what you can add to a preamble, and what they
1343  do.
1344 \end_layout
1345
1346 \begin_layout Subsubsection
1347 Example #1: Offsets
1348 \end_layout
1349
1350 \begin_layout Standard
1351 There are two variables under \SpecialChar LaTeX
1352  that control page position: 
1353 \begin_inset Flex Code
1354 status collapsed
1355
1356 \begin_layout Plain Layout
1357
1358 \backslash
1359 hoffset
1360 \end_layout
1361
1362 \end_inset
1363
1364  and 
1365 \begin_inset Flex Code
1366 status collapsed
1367
1368 \begin_layout Plain Layout
1369
1370 \backslash
1371 voffset
1372 \end_layout
1373
1374 \end_inset
1375
1376 .
1377  Their names should be self-explanatory.
1378  These variables are useful if you think for a moment about computer labels.
1379  Sometimes, the size of a print medium and the area of the medium that you
1380  can actually print on aren't the same.
1381  This is where 
1382 \begin_inset Flex Code
1383 status collapsed
1384
1385 \begin_layout Plain Layout
1386
1387 \backslash
1388 hoffset
1389 \end_layout
1390
1391 \end_inset
1392
1393  and 
1394 \begin_inset Flex Code
1395 status collapsed
1396
1397 \begin_layout Plain Layout
1398
1399 \backslash
1400 voffset
1401 \end_layout
1402
1403 \end_inset
1404
1405  come in.
1406 \end_layout
1407
1408 \begin_layout Standard
1409 The default values for 
1410 \begin_inset Flex Code
1411 status collapsed
1412
1413 \begin_layout Plain Layout
1414
1415 \backslash
1416 hoffset
1417 \end_layout
1418
1419 \end_inset
1420
1421  and 
1422 \begin_inset Flex Code
1423 status collapsed
1424
1425 \begin_layout Plain Layout
1426
1427 \backslash
1428 voffset
1429 \end_layout
1430
1431 \end_inset
1432
1433  are both 0
1434 \begin_inset space \thinspace{}
1435 \end_inset
1436
1437 points, i.
1438 \begin_inset space \thinspace{}
1439 \end_inset
1440
1441 e.
1442 \begin_inset space \space{}
1443 \end_inset
1444
1445 the page isn't shifted.
1446  Unfortunately, some DVI drivers always seem to shift the page.
1447  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1448  If you're using \SpecialChar LyX
1449  on a system that you don't personally maintain, and your
1450  sysadmin is a doofus, 
1451 \begin_inset Flex Code
1452 status collapsed
1453
1454 \begin_layout Plain Layout
1455
1456 \backslash
1457 hoffset
1458 \end_layout
1459
1460 \end_inset
1461
1462  and 
1463 \begin_inset Flex Code
1464 status collapsed
1465
1466 \begin_layout Plain Layout
1467
1468 \backslash
1469 voffset
1470 \end_layout
1471
1472 \end_inset
1473
1474  can save the day.
1475  Suppose your left and top margins are always 0.5
1476 \begin_inset space \thinspace{}
1477 \end_inset
1478
1479 inches too big.
1480  You can add this to the preamble:
1481 \end_layout
1482
1483 \begin_layout LyX-Code
1484
1485 \backslash
1486 setlength{
1487 \backslash
1488 hoffset}{-0.5 in}
1489 \end_layout
1490
1491 \begin_layout LyX-Code
1492
1493 \backslash
1494 setlength{
1495 \backslash
1496 voffset}{-0.5 in}
1497 \end_layout
1498
1499 \begin_layout Standard
1500 and your margins should now be correct.
1501 \end_layout
1502
1503 \begin_layout Subsubsection
1504 Example #2: Labels
1505 \end_layout
1506
1507 \begin_layout Standard
1508 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1509  There's a rather nice package, available at your nearest CTAN archive,
1510  for printing sheets of labels: 
1511 \begin_inset Flex Code
1512 status collapsed
1513
1514 \begin_layout Plain Layout
1515 labels.sty
1516 \end_layout
1517
1518 \end_inset
1519
1520 .
1521  Now, your system may not have this package installed by default.
1522  We leave that up to you to check.
1523  You'll also want to read the documentation for it; we're not going to do
1524  that for you.
1525  Since this is an example, however, we'll give you an example of how you
1526  use this package.
1527 \end_layout
1528
1529 \begin_layout Standard
1530 First, make sure you're using the 
1531 \begin_inset Flex Code
1532 status collapsed
1533
1534 \begin_layout Plain Layout
1535 article
1536 \end_layout
1537
1538 \end_inset
1539
1540  document class.
1541  Next, you need to put the following in your preamble:
1542 \end_layout
1543
1544 \begin_layout LyX-Code
1545
1546 \backslash
1547 usepackage{labels}
1548 \end_layout
1549
1550 \begin_layout LyX-Code
1551
1552 \backslash
1553 LabelCols=3
1554 \end_layout
1555
1556 \begin_layout LyX-Code
1557
1558 \backslash
1559 LabelRows=7
1560 \end_layout
1561
1562 \begin_layout LyX-Code
1563
1564 \backslash
1565 LeftBorder=8mm
1566 \end_layout
1567
1568 \begin_layout LyX-Code
1569
1570 \backslash
1571 RightBorder=8mm
1572 \end_layout
1573
1574 \begin_layout LyX-Code
1575
1576 \backslash
1577 TopBorder=9mm
1578 \end_layout
1579
1580 \begin_layout LyX-Code
1581
1582 \backslash
1583 BottomBorder=2mm
1584 \end_layout
1585
1586 \begin_layout Standard
1587 This sets things up for Avery label sheets, stock #5360.
1588  You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1589  code, placing
1590  the commands 
1591 \begin_inset Flex Code
1592 status collapsed
1593
1594 \begin_layout Plain Layout
1595
1596 \backslash
1597 begin{labels}
1598 \end_layout
1599
1600 \end_inset
1601
1602  and 
1603 \begin_inset Flex Code
1604 status collapsed
1605
1606 \begin_layout Plain Layout
1607
1608 \backslash
1609 end{labels}
1610 \end_layout
1611
1612 \end_inset
1613
1614  around each label text.
1615  This and other special features of 
1616 \begin_inset Flex Code
1617 status collapsed
1618
1619 \begin_layout Plain Layout
1620 labels.sty
1621 \end_layout
1622
1623 \end_inset
1624
1625  are explained in its documentation.
1626 \end_layout
1627
1628 \begin_layout Standard
1629 Someday, someone may write a \SpecialChar LyX
1630  layout file to support this package directly.
1631  Maybe that someone is you.
1632 \end_layout
1633
1634 \begin_layout Subsubsection
1635 Example #3: Paragraph Indentation
1636 \end_layout
1637
1638 \begin_layout Standard
1639 Americans are trained to indent the first line of 
1640 \emph on
1641 every
1642 \emph default
1643  paragraph.
1644  As with all of their other weird quirks, most Americans will whine and
1645  moan until they can have their way and indent the first line of all paragraphs.
1646  (Yes, we're joking.
1647  (We are?) 
1648 \emph on
1649 Yeah
1650 \emph default
1651 , we are.)
1652 \end_layout
1653
1654 \begin_layout Standard
1655 Of course, this behavior isn't standard typography.
1656  In books, you typically only indent the first line of a paragraph 
1657 \emph on
1658 if
1659 \emph default
1660  it follows another one.
1661  The idea behind indenting the first line of a paragraph is to distinguish
1662  neighboring paragraphs from one another.
1663  If there is no previous paragraph—for example, if it follows a figure or
1664  is the first paragraph in a section—then there is no need for indentation.
1665  
1666 \end_layout
1667
1668 \begin_layout Standard
1669 If you're a typical American (we're still joking!), though, you don't care
1670  about such esoteric things; you want your indentation! Add this to the
1671  preamble:
1672 \end_layout
1673
1674 \begin_layout LyX-Code
1675
1676 \backslash
1677 usepackage{indentfirst}
1678 \end_layout
1679
1680 \begin_layout Standard
1681 If your \SpecialChar TeX
1682  distribution isn't braindead, you'll have this package, and all
1683  of your paragraphs will get the indentation the Founding Fathers intended
1684  they should have.
1685 \end_layout
1686
1687 \begin_layout Subsubsection
1688 Example #4: This Document
1689 \end_layout
1690
1691 \begin_layout Standard
1692 You can also check out the preamble of this document to get an idea of some
1693  of the advanced things you can do.
1694 \end_layout
1695
1696 \begin_layout Section
1697 \SpecialChar LyX
1698  and \SpecialChar LaTeX
1699  Errors
1700 \end_layout
1701
1702 \begin_layout Standard
1703 When \SpecialChar LyX
1704  calls \SpecialChar LaTeX
1705 , it tells \SpecialChar LaTeX
1706  to blithely ignore any errors and keep going.
1707  It then uses the logfile from the \SpecialChar LaTeX
1708  run to do a post-mortem.
1709  After analyzing the logfile, \SpecialChar LyX
1710  displays a dialog listing the errors.
1711  Clicking on any one of them will take you to the position in your \SpecialChar LyX
1712  file
1713  where the error occurred.
1714 \begin_inset Foot
1715 status collapsed
1716
1717 \begin_layout Plain Layout
1718 Well, usually.
1719  Analyzing the logfile is a tough job, and \SpecialChar LyX
1720  doesn't always go to the right
1721  line.
1722  There are also cases where \SpecialChar LaTeX
1723  reports the error on one line, but the actual
1724  error is earlier.
1725  This is not unlike forgetting a closing brace in a program: You'll get
1726  an error, but only later.
1727 \end_layout
1728
1729 \end_inset
1730
1731
1732 \end_layout
1733
1734 \begin_layout Standard
1735 Some folks also like to look at the log file directly: It is available from
1736  
1737 \begin_inset Flex Noun
1738 status collapsed
1739
1740 \begin_layout Plain Layout
1741 Document\SpecialChar menuseparator
1742 LaTeX
1743 \begin_inset space ~
1744 \end_inset
1745
1746 Log
1747 \end_layout
1748
1749 \end_inset
1750
1751 .
1752  There are some fairly common error messages and warnings.
1753  We'll cover those here.
1754  You should look at a good \SpecialChar LaTeX
1755  book for a complete listing.
1756 \end_layout
1757
1758 \begin_layout Itemize
1759 \begin_inset Flex Code
1760 status collapsed
1761
1762 \begin_layout Plain Layout
1763 LaTeX Warning
1764 \end_layout
1765
1766 \end_inset
1767
1768
1769 \begin_inset Newline newline
1770 \end_inset
1771
1772 Anything beginning with these words is a warning message for the purpose
1773  of 
1774 \begin_inset Quotes eld
1775 \end_inset
1776
1777 debugging
1778 \begin_inset Quotes erd
1779 \end_inset
1780
1781  the \SpecialChar LaTeX
1782  code itself.
1783  You'll get messages like this if you added or changed cross-references
1784  or bibliography entries, in which case, \SpecialChar LaTeX
1785  is trying to tell you that you
1786  need to make another run.
1787  You can by-and-large ignore these.
1788 \end_layout
1789
1790 \begin_layout Itemize
1791 \begin_inset Flex Code
1792 status collapsed
1793
1794 \begin_layout Plain Layout
1795 LaTeX Font Warning
1796 \end_layout
1797
1798 \end_inset
1799
1800
1801 \begin_inset Newline newline
1802 \end_inset
1803
1804 Another warning message, this time about fonts which \SpecialChar LaTeX
1805  couldn't find.
1806  The rest of the message will often say something about a replacement font
1807  that \SpecialChar LaTeX
1808  used.
1809  You can safely ignore these, too.
1810 \end_layout
1811
1812 \begin_layout Itemize
1813 \begin_inset Flex Code
1814 status collapsed
1815
1816 \begin_layout Plain Layout
1817 Overfull 
1818 \backslash
1819 hbox
1820 \end_layout
1821
1822 \end_inset
1823
1824
1825 \begin_inset Newline newline
1826 \end_inset
1827
1828 \SpecialChar LaTeX
1829  absolutely 
1830 \emph on
1831 loves
1832 \emph default
1833  to spew these out.
1834  It seems to generate at least one of these messages for just about any
1835  document you write.
1836  They are warnings about lines that were too long and run past the right
1837  margin.
1838  This happens if \SpecialChar LaTeX
1839  does not find a reasonable way to break the lines (notoriously
1840  often with typewriter font, since this does not allow for automatic break
1841  points).
1842  In many cases, this is unnoticeable in the final output.
1843  (It can be just a point or two.) Sometimes, however, the lines run rather
1844  visibly into the margin; something you will not want to have in your final
1845  print.
1846  
1847 \begin_inset Newline newline
1848 \end_inset
1849
1850 There are several global ways to try to minimize the overfull lines.
1851  Clicking 
1852 \family sans
1853 Enable micro-typographic extensions
1854 \family default
1855  in 
1856 \family sans
1857 Document\SpecialChar menuseparator
1858 Settings\SpecialChar menuseparator
1859 Fonts
1860 \family default
1861  might already improve things a lot.
1862  Furthermore, \SpecialChar LaTeX
1863  code such as the following in 
1864 \family sans
1865 Document\SpecialChar menuseparator
1866 Settings\SpecialChar menuseparator
1867 Preamble
1868 \family default
1869  usually reduces the overfull lines drastically (we use this in the preamble
1870  of this document):
1871 \end_layout
1872
1873 \begin_deeper
1874 \begin_layout LyX-Code
1875
1876 \backslash
1877 tolerance 1414
1878 \begin_inset Newline newline
1879 \end_inset
1880
1881
1882 \backslash
1883 hbadness 1414
1884 \begin_inset Newline newline
1885 \end_inset
1886
1887
1888 \backslash
1889 emergencystretch 1.5em
1890 \begin_inset Newline newline
1891 \end_inset
1892
1893
1894 \backslash
1895 hfuzz 0.3pt
1896 \end_layout
1897
1898 \begin_layout Standard
1899 In some cases, however, you eventually have to rewrite the text to get the
1900  line breaking right.
1901 \begin_inset Foot
1902 status collapsed
1903
1904 \begin_layout Plain Layout
1905 For more information, see 
1906 \begin_inset Flex URL
1907 status open
1908
1909 \begin_layout Plain Layout
1910
1911 http://www.tex.ac.uk/FAQ-overfull.html
1912 \end_layout
1913
1914 \end_inset
1915
1916
1917 \end_layout
1918
1919 \end_inset
1920
1921
1922 \end_layout
1923
1924 \begin_layout Standard
1925 In any case, you should check the respective lines, at least for the final
1926  version of your document.
1927  Your eyes will tell you if there's a problem with something that's too
1928  wide.
1929 \begin_inset Foot
1930 status collapsed
1931
1932 \begin_layout Plain Layout
1933 You can also enable the `draft' option in 
1934 \begin_inset Flex Noun
1935 status collapsed
1936
1937 \begin_layout Plain Layout
1938 Document\SpecialChar menuseparator
1939 Settings
1940 \end_layout
1941
1942 \end_inset
1943
1944 , and then \SpecialChar LaTeX
1945  will draw a black box in the margin of lines that are overfull.
1946 \end_layout
1947
1948 \end_inset
1949
1950  
1951 \end_layout
1952
1953 \end_deeper
1954 \begin_layout Itemize
1955 \begin_inset Flex Code
1956 status collapsed
1957
1958 \begin_layout Plain Layout
1959 Underfull 
1960 \backslash
1961 hbox
1962 \end_layout
1963
1964 \end_inset
1965
1966
1967 \begin_inset Newline newline
1968 \end_inset
1969
1970 Not quite as common as its cousin.
1971  This happens again if \SpecialChar LaTeX
1972  does not find a reasonable break point and consequently
1973  generates too loose lines.
1974  As with the overfull lines, you should check if this is a visible problem.
1975 \end_layout
1976
1977 \begin_layout Itemize
1978 \begin_inset Flex Code
1979 status collapsed
1980
1981 \begin_layout Plain Layout
1982 Overfull 
1983 \backslash
1984 vbox
1985 \end_layout
1986
1987 \end_inset
1988
1989  and 
1990 \begin_inset Flex Code
1991 status collapsed
1992
1993 \begin_layout Plain Layout
1994 Underfull 
1995 \backslash
1996 vbox
1997 \end_layout
1998
1999 \end_inset
2000
2001
2002 \begin_inset Newline newline
2003 \end_inset
2004
2005 Warnings about troubles breaking the page.
2006  Once again, just look at the output.
2007  Your eyes will tell you where something has gone wrong.
2008 \end_layout
2009
2010 \begin_layout Itemize
2011 \begin_inset Flex Code
2012 status collapsed
2013
2014 \begin_layout Plain Layout
2015 LaTeX Error: File 
2016 \begin_inset Quotes els
2017 \end_inset
2018
2019 Xxxx
2020 \begin_inset Quotes ers
2021 \end_inset
2022
2023  not found
2024 \end_layout
2025
2026 \end_inset
2027
2028
2029 \begin_inset Newline newline
2030 \end_inset
2031
2032 The file 
2033 \begin_inset Quotes eld
2034 \end_inset
2035
2036 Xxxx
2037 \begin_inset Quotes erd
2038 \end_inset
2039
2040  isn't installed on this system.
2041  This usually appears because some package your document needs isn't installed.
2042  If you didn't touch the preamble or didn't use the 
2043 \begin_inset Flex Code
2044 status collapsed
2045
2046 \begin_layout Plain Layout
2047
2048 \backslash
2049 usepackage{}
2050 \end_layout
2051
2052 \end_inset
2053
2054  command, then one of the packages \SpecialChar LyX
2055  tried to load is missing.
2056  Use 
2057 \begin_inset Flex Noun
2058 status collapsed
2059
2060 \begin_layout Plain Layout
2061 Help\SpecialChar menuseparator
2062 \SpecialChar LaTeX
2063  Configuration
2064 \end_layout
2065
2066 \end_inset
2067
2068  to get a list of packages that \SpecialChar LyX
2069  knows about.
2070  This file is updated whenever you reconfigure \SpecialChar LyX
2071  (using 
2072 \begin_inset Flex Noun
2073 status collapsed
2074
2075 \begin_layout Plain Layout
2076 Tools\SpecialChar menuseparator
2077 Reconfigure
2078 \end_layout
2079
2080 \end_inset
2081
2082 ) and tells you which packages have been detected and what they do.
2083 \begin_inset Newline newline
2084 \end_inset
2085
2086 If you did use the 
2087 \begin_inset Flex Code
2088 status collapsed
2089
2090 \begin_layout Plain Layout
2091
2092 \backslash
2093 usepackage{}
2094 \end_layout
2095
2096 \end_inset
2097
2098  command and the package in question isn't installed, then you'll need to
2099  install it yourself.
2100 \end_layout
2101
2102 \begin_layout Itemize
2103 \begin_inset Flex Code
2104 status collapsed
2105
2106 \begin_layout Plain Layout
2107 LaTeX Error: Unknown option
2108 \end_layout
2109
2110 \end_inset
2111
2112
2113 \begin_inset Newline newline
2114 \end_inset
2115
2116 Error messages beginning with this are trying to tell you that you specified
2117  a bad or undefined option to a package.
2118  Check the package's documentation.
2119 \end_layout
2120
2121 \begin_layout Itemize
2122 \begin_inset Flex Code
2123 status collapsed
2124
2125 \begin_layout Plain Layout
2126 Undefined control sequence
2127 \end_layout
2128
2129 \end_inset
2130
2131
2132 \begin_inset Newline newline
2133 \end_inset
2134
2135 If you've inserted \SpecialChar LaTeX
2136  code into your document, but made a typo, you'll get
2137  one of these.
2138  You may have forgotten to load a package.
2139  In any case, this error message usually means that you used an undefined
2140  command.
2141  
2142 \end_layout
2143
2144 \begin_layout Standard
2145 There are other error and warning messages.
2146  Some are self-explanatory.
2147  These are usually \SpecialChar LaTeX
2148  messages.
2149  Others are downright cryptic.
2150  These are usually \SpecialChar TeX
2151  error messages, and we really have 
2152 \emph on
2153 no clue
2154 \emph default
2155  what they mean or how to decipher them.
2156  No-one does.
2157 \end_layout
2158
2159 \begin_layout Standard
2160 There's a general sequence you should follow if you get error messages:
2161 \end_layout
2162
2163 \begin_layout Enumerate
2164 Look at the \SpecialChar LaTeX
2165  code you inserted for typos.
2166 \end_layout
2167
2168 \begin_layout Enumerate
2169 If there are no typos, check that you used the command(s) correctly.
2170 \end_layout
2171
2172 \begin_layout Enumerate
2173 If you get a bunch of error boxes piled up at the very top of the document—and
2174  especially if you see a 
2175 \begin_inset Quotes eld
2176 \end_inset
2177
2178
2179 \begin_inset Flex Code
2180 status collapsed
2181
2182 \begin_layout Plain Layout
2183 Missing 
2184 \backslash
2185 begin{document}
2186 \end_layout
2187
2188 \end_inset
2189
2190
2191 \begin_inset Quotes erd
2192 \end_inset
2193
2194  error—it means that there are errors in the preamble.
2195  Start debugging your preamble.
2196 \end_layout
2197
2198 \begin_layout Enumerate
2199 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2200  code to the
2201  document, the first suspect is your \SpecialChar LaTeX
2202  distribution itself.
2203  Check for missing packages and install them.
2204 \end_layout
2205
2206 \begin_layout Enumerate
2207 Okay, so there are no missing packages.
2208  Did you use any of the fine-tuning options in \SpecialChar LyX
2209 ? Specifically, did you 
2210 \emph on
2211 misuse
2212 \emph default
2213  any of them, like trying to manually insert lots of 
2214 \begin_inset Flex Code
2215 status collapsed
2216
2217 \begin_layout Plain Layout
2218
2219 \change_deleted 177693 1654669036
2220 Protected
2221 \change_inserted 177693 1654669038
2222 Non-Breaking
2223 \change_unchanged
2224
2225 \begin_inset space ~
2226 \end_inset
2227
2228
2229 \change_deleted 177693 1654669040
2230 Blanks
2231 \change_inserted 177693 1654669041
2232 Spaces
2233 \change_unchanged
2234
2235 \end_layout
2236
2237 \end_inset
2238
2239
2240 \begin_inset Flex Code
2241 status collapsed
2242
2243 \begin_layout Plain Layout
2244 Linebreaks
2245 \end_layout
2246
2247 \end_inset
2248
2249 , or 
2250 \begin_inset Flex Code
2251 status collapsed
2252
2253 \begin_layout Plain Layout
2254 Pagebreaks
2255 \end_layout
2256
2257 \end_inset
2258
2259 ? Did you try to kludge something together with these instead of using the
2260  appropriate paragraph environment?
2261 \end_layout
2262
2263 \begin_layout Enumerate
2264 All right, you didn't use any of the fine-tuning options, you played by
2265  the rules.
2266  Did you try to pull a fancy maneuver? Did you do something funky inside
2267  a table or an equation, like inserting a graphic into a table cell?
2268 \end_layout
2269
2270 \begin_layout Enumerate
2271 Do you have long sections of text where \SpecialChar LaTeX
2272  cannot find a place to break a
2273  line? By default, \SpecialChar LaTeX
2274  is rather strict about how much extra inter-word spacing
2275  it will add in order to break a line.
2276  Preferably, you should rework the paragraph to avoid the problem.
2277 \end_layout
2278
2279 \begin_layout Enumerate
2280 Did you go overboard with the nesting? \SpecialChar LyX
2281  (currently) doesn't check to make
2282  sure you're in the limits for nesting environments.
2283  If you nested a bunch of environments to the 
2284 \begin_inset Formula $17^{\mathrm{th}}$
2285 \end_inset
2286
2287  level, that's the problem.
2288  (The limit in \SpecialChar LaTeX
2289  is five.)
2290 \end_layout
2291
2292 \begin_layout Enumerate
2293 Okay, you didn't get any error messages, but your output looks awful.
2294  If you have a table or figure that's too wide or long for the page, you
2295  need to:
2296 \end_layout
2297
2298 \begin_deeper
2299 \begin_layout Enumerate
2300 rescale the figure so it fits.
2301 \end_layout
2302
2303 \begin_layout Enumerate
2304 trim down the table so it fits.
2305 \end_layout
2306
2307 \end_deeper
2308 \begin_layout Enumerate
2309 If something else is wrong with the output, and you didn't try to pull anything
2310  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2311 \end_layout
2312
2313 \begin_layout Standard
2314 If all this doesn't help—well, then 
2315 \emph on
2316 perhaps
2317 \emph default
2318  you might have found a bug in \SpecialChar LyX
2319 \SpecialChar ldots
2320 .
2321 \end_layout
2322
2323 \begin_layout Chapter
2324 Supplemental Tools
2325 \end_layout
2326
2327 \begin_layout Section
2328 Customizing Bibliographies with Bib\SpecialChar TeX
2329  or Biblatex
2330 \end_layout
2331
2332 \begin_layout Standard
2333 The most basic information about how to use Bib\SpecialChar TeX
2334  or 
2335 \family sans
2336 Biblatex
2337 \family default
2338  with \SpecialChar LyX
2339  is contained in the section 
2340 \emph on
2341 Bibliography databases
2342 \emph default
2343  of the 
2344 \emph on
2345 User's Guide
2346 \emph default
2347 .
2348  The following subsections explain special bibliography features supported
2349  by \SpecialChar LyX
2350 .
2351 \end_layout
2352
2353 \begin_layout Subsection
2354 Alternative Citation Styles
2355 \end_layout
2356
2357 \begin_layout Standard
2358 Standard Bib\SpecialChar TeX
2359  uses numbers (e.
2360 \begin_inset space \thinspace{}
2361 \end_inset
2362
2363 g.
2364 \begin_inset space \space{}
2365 \end_inset
2366
2367
2368 \begin_inset Quotes eld
2369 \end_inset
2370
2371 [12]
2372 \begin_inset Quotes erd
2373 \end_inset
2374
2375 ) to refer to a cited work.
2376  However, in many scientific disciplines, other citation styles are in use.
2377  The most common one is the author-year style (e.
2378 \begin_inset space \thinspace{}
2379 \end_inset
2380
2381 g.
2382 \begin_inset space \space{}
2383 \end_inset
2384
2385
2386 \begin_inset Quotes eld
2387 \end_inset
2388
2389 Knuth 1984a
2390 \begin_inset Quotes erd
2391 \end_inset
2392
2393 ).
2394  \SpecialChar LyX
2395  supports three packages that provide this style, 
2396 \begin_inset Flex Code
2397 status collapsed
2398
2399 \begin_layout Plain Layout
2400 biblatex
2401 \end_layout
2402
2403 \end_inset
2404
2405
2406 \begin_inset Flex Code
2407 status collapsed
2408
2409 \begin_layout Plain Layout
2410 natbib
2411 \end_layout
2412
2413 \end_inset
2414
2415 , and 
2416 \begin_inset Flex Code
2417 status collapsed
2418
2419 \begin_layout Plain Layout
2420 jurabib
2421 \end_layout
2422
2423 \end_inset
2424
2425 .
2426  Each of these packages has their pros and cons, which cannot be listed
2427  in detail.
2428  If you only want to have simple author-year (or author-numerical) style,
2429  or if you want to use one of the countless style files for 
2430 \begin_inset Flex Code
2431 status collapsed
2432
2433 \begin_layout Plain Layout
2434 natbib
2435 \end_layout
2436
2437 \end_inset
2438
2439 , then the established 
2440 \begin_inset Flex Code
2441 status collapsed
2442
2443 \begin_layout Plain Layout
2444 natbib
2445 \end_layout
2446
2447 \end_inset
2448
2449  package is probably your choice.
2450  If you look for specific citation styles common in law studies, you might
2451  consider the 
2452 \begin_inset Flex Code
2453 status collapsed
2454
2455 \begin_layout Plain Layout
2456 jurabib
2457 \end_layout
2458
2459 \end_inset
2460
2461  package.
2462  If you want to have full control over the formatting or look for advanced
2463  features such as ibidem, footnote citations, full title citations, advanced
2464  date formats (such as 400 BC) or full localization to other languages than
2465  English, you should definitely consider 
2466 \begin_inset Flex Code
2467 status collapsed
2468
2469 \begin_layout Plain Layout
2470 biblatex
2471 \end_layout
2472
2473 \end_inset
2474
2475 , which exceeds all other packages in terms of features, but is also quite
2476  heavy and more resource-hungry.
2477 \end_layout
2478
2479 \begin_layout Standard
2480 The handling of these packages in \SpecialChar LyX
2481  is basically the same.
2482  Go to 
2483 \begin_inset Flex Noun
2484 status collapsed
2485
2486 \begin_layout Plain Layout
2487 Document\SpecialChar menuseparator
2488 Settings
2489 \end_layout
2490
2491 \end_inset
2492
2493  and select under 
2494 \begin_inset Flex Noun
2495 status collapsed
2496
2497 \begin_layout Plain Layout
2498 Bibliography
2499 \end_layout
2500
2501 \end_inset
2502
2503  the 
2504 \begin_inset Flex Noun
2505 status collapsed
2506
2507 \begin_layout Plain Layout
2508 Style Format
2509 \end_layout
2510
2511 \end_inset
2512
2513  
2514 \begin_inset Flex Noun
2515 status collapsed
2516
2517 \begin_layout Plain Layout
2518 Basic (BibTeX)
2519 \end_layout
2520
2521 \end_inset
2522
2523
2524 \begin_inset Flex Noun
2525 status collapsed
2526
2527 \begin_layout Plain Layout
2528 Biblatex
2529 \end_layout
2530
2531 \end_inset
2532
2533
2534 \begin_inset Flex Noun
2535 status collapsed
2536
2537 \begin_layout Plain Layout
2538 Biblatex (Natbib mode)
2539 \end_layout
2540
2541 \end_inset
2542
2543
2544 \begin_inset Flex Noun
2545 status collapsed
2546
2547 \begin_layout Plain Layout
2548 Natbib (BibTeX)
2549 \end_layout
2550
2551 \end_inset
2552
2553  or 
2554 \begin_inset Flex Noun
2555 status collapsed
2556
2557 \begin_layout Plain Layout
2558 Jurabib (BibTeX)
2559 \end_layout
2560
2561 \end_inset
2562
2563  (see sec.
2564 \begin_inset space ~
2565 \end_inset
2566
2567 6.5.3 in the User's Guide for more information on these choices).
2568  With all these packages, you will get some extra features in the citation
2569  dialog and you can select the style of the reference (
2570 \begin_inset Quotes eld
2571 \end_inset
2572
2573 Knuth 1984
2574 \begin_inset Quotes erd
2575 \end_inset
2576
2577
2578 \begin_inset Quotes eld
2579 \end_inset
2580
2581 Knuth (1984)
2582 \begin_inset Quotes erd
2583 \end_inset
2584
2585
2586 \begin_inset Quotes eld
2587 \end_inset
2588
2589 Knuth, 1984
2590 \begin_inset Quotes erd
2591 \end_inset
2592
2593
2594 \begin_inset Quotes eld
2595 \end_inset
2596
2597 1984
2598 \begin_inset Quotes erd
2599 \end_inset
2600
2601  etc.).
2602  Note that either package needs specifically designed style files.
2603  They all ship their own, but there are lots of additional style files,
2604  and there is even an interactive style file builder
2605 \begin_inset Foot
2606 status collapsed
2607
2608 \begin_layout Plain Layout
2609 See 
2610 \begin_inset Flex URL
2611 status open
2612
2613 \begin_layout Plain Layout
2614
2615 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2616 \end_layout
2617
2618 \end_inset
2619
2620
2621 \end_layout
2622
2623 \end_inset
2624
2625  for 
2626 \begin_inset Flex Code
2627 status collapsed
2628
2629 \begin_layout Plain Layout
2630 natbib
2631 \end_layout
2632
2633 \end_inset
2634
2635 .
2636 \end_layout
2637
2638 \begin_layout Subsection
2639 Subdivided Bibliographies
2640 \end_layout
2641
2642 \begin_layout Standard
2643 Sometimes you might need to divide your bibliography into several sections.
2644  If you are for instance a historian, the possibility to separate sources
2645  and scientific works is most likely a 
2646 \begin_inset Quotes eld
2647 \end_inset
2648
2649 must have
2650 \begin_inset Quotes erd
2651 \end_inset
2652
2653 .
2654  Unfortunately, Bib\SpecialChar TeX
2655  itself does not allow you to do this.
2656  But with the help of some \SpecialChar LaTeX
2657  packages, Bib\SpecialChar TeX
2658  can be extended to fit your needs.
2659 \end_layout
2660
2661 \begin_layout Standard
2662 \SpecialChar LyX
2663  provides native support for one of these packages, 
2664 \family typewriter
2665 bibtopic
2666 \family default
2667 .
2668 \begin_inset Foot
2669 status collapsed
2670
2671 \begin_layout Plain Layout
2672 Available from 
2673 \begin_inset Flex URL
2674 status open
2675
2676 \begin_layout Plain Layout
2677
2678 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2679 \end_layout
2680
2681 \end_inset
2682
2683
2684 \end_layout
2685
2686 \end_inset
2687
2688  The advantage of this package (compared to other packages such as 
2689 \family typewriter
2690 multibib
2691 \family default
2692 ) is that you don't need to define new citation commands.
2693  Instead, you need to prepare different bibliographic databases which include
2694  the entries for the different sections of the bibliography.
2695  For example: If you want to divide your bibliography into the sections
2696  
2697 \begin_inset Quotes eld
2698 \end_inset
2699
2700 Sources
2701 \begin_inset Quotes erd
2702 \end_inset
2703
2704  and 
2705 \begin_inset Quotes eld
2706 \end_inset
2707
2708 Scientific works
2709 \begin_inset Quotes erd
2710 \end_inset
2711
2712 , you first need to create two bibliographic databases, e.
2713 \begin_inset space \thinspace{}
2714 \end_inset
2715
2716 g.
2717 \begin_inset space \space{}
2718 \end_inset
2719
2720
2721 \begin_inset Flex Code
2722 status collapsed
2723
2724 \begin_layout Plain Layout
2725 sources.bib
2726 \end_layout
2727
2728 \end_inset
2729
2730  and 
2731 \begin_inset Flex Code
2732 status collapsed
2733
2734 \begin_layout Plain Layout
2735 scientific.bib
2736 \end_layout
2737
2738 \end_inset
2739
2740 .
2741  
2742 \end_layout
2743
2744 \begin_layout Standard
2745 Go to 
2746 \begin_inset Flex Noun
2747 status collapsed
2748
2749 \begin_layout Plain Layout
2750 Document\SpecialChar menuseparator
2751 Settings
2752 \end_layout
2753
2754 \end_inset
2755
2756  and check under 
2757 \begin_inset Flex Noun
2758 status collapsed
2759
2760 \begin_layout Plain Layout
2761 Bibliography
2762 \end_layout
2763
2764 \end_inset
2765
2766  the option 
2767 \begin_inset Flex Noun
2768 status collapsed
2769
2770 \begin_layout Plain Layout
2771 Subdivided bibliography
2772 \end_layout
2773
2774 \end_inset
2775
2776 .
2777  Now you can insert multiple Bib\SpecialChar TeX
2778  bibliographies, one for each section of
2779  your bibliography.
2780  Returning to our example: Insert the Bib\SpecialChar TeX
2781  bibliography 
2782 \begin_inset Flex Code
2783 status collapsed
2784
2785 \begin_layout Plain Layout
2786 sources.bib
2787 \end_layout
2788
2789 \end_inset
2790
2791  and a second one for the database 
2792 \begin_inset Flex Code
2793 status collapsed
2794
2795 \begin_layout Plain Layout
2796 scientific.bib
2797 \end_layout
2798
2799 \end_inset
2800
2801 .
2802  You are free to use the same or different styles for each section.
2803  Additionally, you can choose if the bibliography section should contain
2804  
2805 \begin_inset Quotes eld
2806 \end_inset
2807
2808 all cited references
2809 \begin_inset Quotes erd
2810 \end_inset
2811
2812  of the specified database(s) (which is the default), 
2813 \begin_inset Quotes eld
2814 \end_inset
2815
2816 all uncited references
2817 \begin_inset Quotes erd
2818 \end_inset
2819
2820  or even 
2821 \begin_inset Quotes eld
2822 \end_inset
2823
2824 all references
2825 \begin_inset Quotes erd
2826 \end_inset
2827
2828 .
2829  This might be useful if you would like to separate your bibliography into
2830  three sections: 
2831 \begin_inset Quotes eld
2832 \end_inset
2833
2834 Cited sources
2835 \begin_inset Quotes erd
2836 \end_inset
2837
2838
2839 \begin_inset Quotes eld
2840 \end_inset
2841
2842 Uncited sources
2843 \begin_inset Quotes erd
2844 \end_inset
2845
2846 , and 
2847 \begin_inset Quotes eld
2848 \end_inset
2849
2850 Scientific works
2851 \begin_inset Quotes erd
2852 \end_inset
2853
2854 .
2855  The titles for the sections can be added as ordinary sections or subsections.
2856  Since 
2857 \begin_inset Flex Code
2858 status collapsed
2859
2860 \begin_layout Plain Layout
2861 bibtopic
2862 \end_layout
2863
2864 \end_inset
2865
2866  removes the bibliography title, you have to manually re-add that, too (as
2867  a chapter* or section*, for instance).
2868 \end_layout
2869
2870 \begin_layout Standard
2871 With 
2872 \family sans
2873 Biblatex
2874 \family default
2875 , the procedure is a bit different.
2876  Since 
2877 \family typewriter
2878 bibtopic
2879 \family default
2880  does not work with 
2881 \family sans
2882 Biblatex
2883 \family default
2884 , the aforementioned 
2885 \begin_inset Flex Noun
2886 status collapsed
2887
2888 \begin_layout Plain Layout
2889 Subdivided bibliography
2890 \end_layout
2891
2892 \end_inset
2893
2894  option is disabled if you use 
2895 \family sans
2896 Biblatex
2897 \family default
2898 .
2899  However, 
2900 \family sans
2901 Biblatex
2902 \family default
2903  provides its own means to generate subdivided bibliographies.
2904  You can either add keywords to bibliography entries via the 
2905 \begin_inset Flex Code
2906 status collapsed
2907
2908 \begin_layout Plain Layout
2909 keywords
2910 \end_layout
2911
2912 \end_inset
2913
2914  entry option and then filter bibliography sections by keyword (by adding
2915  
2916 \begin_inset Flex Code
2917 status collapsed
2918
2919 \begin_layout Plain Layout
2920 keyword=mykeyword
2921 \end_layout
2922
2923 \end_inset
2924
2925  to the 
2926 \begin_inset Flex Noun
2927 status collapsed
2928
2929 \begin_layout Plain Layout
2930 Options
2931 \end_layout
2932
2933 \end_inset
2934
2935  field of the dialog that opens if you left-click on the 
2936 \begin_inset Flex Noun
2937 status collapsed
2938
2939 \begin_layout Plain Layout
2940 Biblatex Generated Bibliography
2941 \end_layout
2942
2943 \end_inset
2944
2945  button), or you can filter by entry types (such as 
2946 \emph on
2947 book
2948 \emph default
2949  or 
2950 \emph on
2951 article
2952 \emph default
2953 ) by entering e.
2954 \begin_inset space \thinspace{}
2955 \end_inset
2956
2957 g.
2958  
2959 \begin_inset Flex Code
2960 status collapsed
2961
2962 \begin_layout Plain Layout
2963 type=book
2964 \end_layout
2965
2966 \end_inset
2967
2968  or 
2969 \begin_inset Flex Code
2970 status collapsed
2971
2972 \begin_layout Plain Layout
2973 nottype=collection
2974 \end_layout
2975
2976 \end_inset
2977
2978  to the mentioned 
2979 \begin_inset Flex Noun
2980 status collapsed
2981
2982 \begin_layout Plain Layout
2983 Options
2984 \end_layout
2985
2986 \end_inset
2987
2988  field, or you can create so-called 
2989 \begin_inset Quotes eld
2990 \end_inset
2991
2992 Bibliography Categories
2993 \begin_inset Quotes erd
2994 \end_inset
2995
2996  to which you can assign individual entries.
2997  Please refer to the Biblatex manual, section 
2998 \emph on
2999 Subdivided Bibliographies
3000 \emph default
3001 , for details.
3002 \end_layout
3003
3004 \begin_layout Subsection
3005 Multiple Bibliographies
3006 \begin_inset CommandInset label
3007 LatexCommand label
3008 name "subsec:Multiple-Bibliographies"
3009
3010 \end_inset
3011
3012
3013 \end_layout
3014
3015 \begin_layout Standard
3016 Multiple bibliographies, e.
3017 \begin_inset space \thinspace{}
3018 \end_inset
3019
3020 g.
3021 \begin_inset space \space{}
3022 \end_inset
3023
3024 a bibliography for each part, chapter, section, subsection or child (sub-documen
3025 t) of the document, are also supported by \SpecialChar LyX
3026 .
3027  In order to enable it, go to 
3028 \begin_inset Flex Noun
3029 status collapsed
3030
3031 \begin_layout Plain Layout
3032 Document\SpecialChar menuseparator
3033 Settings\SpecialChar menuseparator
3034 Bibliography
3035 \end_layout
3036
3037 \end_inset
3038
3039  and select the relevant unit (e.
3040 \begin_inset space \thinspace{}
3041 \end_inset
3042
3043 g., 
3044 \begin_inset Quotes eld
3045 \end_inset
3046
3047 per section
3048 \begin_inset Quotes erd
3049 \end_inset
3050
3051 ) in the 
3052 \begin_inset Flex Noun
3053 status collapsed
3054
3055 \begin_layout Plain Layout
3056 Multiple Bibliographies
3057 \end_layout
3058
3059 \end_inset
3060
3061  combo box.
3062  Then add a Bib(la)\SpecialChar TeX
3063  bibliography to each unit (e.
3064 \begin_inset space \thinspace{}
3065 \end_inset
3066
3067 g., section) of your document.
3068  In the output, a separate bibliography, containing only the references
3069  done in the current unit is generated.
3070 \end_layout
3071
3072 \begin_layout Standard
3073 If you use Bib\SpecialChar TeX
3074 , either the 
3075 \begin_inset Flex Code
3076 status collapsed
3077
3078 \begin_layout Plain Layout
3079 chapterbib
3080 \end_layout
3081
3082 \end_inset
3083
3084  or the 
3085 \begin_inset Flex Code
3086 status collapsed
3087
3088 \begin_layout Plain Layout
3089 bibtopic
3090 \end_layout
3091
3092 \end_inset
3093
3094  package is used to create multiple bibliographies.
3095  The former package is used if you select 
3096 \begin_inset Quotes eld
3097 \end_inset
3098
3099 per child document
3100 \begin_inset Quotes erd
3101 \end_inset
3102
3103  and do 
3104 \emph on
3105 not
3106 \emph default
3107  check 
3108 \begin_inset Flex Noun
3109 status collapsed
3110
3111 \begin_layout Plain Layout
3112 Sectioned Bibliography
3113 \end_layout
3114
3115 \end_inset
3116
3117 .
3118  In all other cases, 
3119 \begin_inset Flex Code
3120 status collapsed
3121
3122 \begin_layout Plain Layout
3123 bibtopic
3124 \end_layout
3125
3126 \end_inset
3127
3128  is used.
3129 \begin_inset Foot
3130 status collapsed
3131
3132 \begin_layout Plain Layout
3133 An alternative approach, if you are willing to use some 
3134 \begin_inset Flex Noun
3135 status collapsed
3136
3137 \begin_layout Plain Layout
3138 \SpecialChar TeX
3139  Code
3140 \end_layout
3141
3142 \end_inset
3143
3144  (see section
3145 \begin_inset space ~
3146 \end_inset
3147
3148
3149 \begin_inset CommandInset ref
3150 LatexCommand ref
3151 reference "sec:Inserting-TeX-Code"
3152
3153 \end_inset
3154
3155 ), is to use the 
3156 \begin_inset Flex Code
3157 status collapsed
3158
3159 \begin_layout Plain Layout
3160 bibunits
3161 \end_layout
3162
3163 \end_inset
3164
3165  package.
3166 \end_layout
3167
3168 \end_inset
3169
3170  If 
3171 \begin_inset Flex Code
3172 status collapsed
3173
3174 \begin_layout Plain Layout
3175 bibtopic
3176 \end_layout
3177
3178 \end_inset
3179
3180  is used, \SpecialChar LyX
3181  encloses the specified units in 
3182 \begin_inset Flex Code
3183 status collapsed
3184
3185 \begin_layout Plain Layout
3186 bibtopic
3187 \end_layout
3188
3189 \end_inset
3190
3191 's 
3192 \begin_inset Flex Code
3193 status collapsed
3194
3195 \begin_layout Plain Layout
3196
3197 \backslash
3198 begin{btUnit}
3199 \end_layout
3200
3201 \end_inset
3202
3203  and 
3204 \begin_inset Flex Code
3205 status collapsed
3206
3207 \begin_layout Plain Layout
3208
3209 \backslash
3210 end{btUnit}
3211 \end_layout
3212
3213 \end_inset
3214
3215  in order to create the units.
3216  Note that this approach has some limitations.
3217  First, every citation reference has to be inside some 
3218 \begin_inset Flex Code
3219 status collapsed
3220
3221 \begin_layout Plain Layout
3222 btUnit
3223 \end_layout
3224
3225 \end_inset
3226
3227 .
3228  So citations outside a defined unit (e.
3229 \begin_inset space \thinspace{}
3230 \end_inset
3231
3232 g., before the first section if you use 
3233 \begin_inset Quotes eld
3234 \end_inset
3235
3236 by section
3237 \begin_inset Quotes erd
3238 \end_inset
3239
3240 ) will appear as 
3241 \begin_inset Quotes eld
3242 \end_inset
3243
3244 ???
3245 \begin_inset Quotes erd
3246 \end_inset
3247
3248 .
3249  You can also create your own units by entering 
3250 \begin_inset Flex Code
3251 status collapsed
3252
3253 \begin_layout Plain Layout
3254
3255 \backslash
3256 begin{btUnit}
3257 \end_layout
3258
3259 \end_inset
3260
3261  and 
3262 \begin_inset Flex Code
3263 status collapsed
3264
3265 \begin_layout Plain Layout
3266
3267 \backslash
3268 end{btUnit}
3269 \end_layout
3270
3271 \end_inset
3272
3273  as \SpecialChar TeX
3274  code (for instance to work around the mentioned limitation).
3275  Note, though, that 
3276 \begin_inset Flex Code
3277 status collapsed
3278
3279 \begin_layout Plain Layout
3280 btUnit
3281 \end_layout
3282
3283 \end_inset
3284
3285 s cannot be nested.
3286  A second limitation is that 
3287 \begin_inset Flex Code
3288 status collapsed
3289
3290 \begin_layout Plain Layout
3291 bibtopic
3292 \end_layout
3293
3294 \end_inset
3295
3296  always processes all references of a bibliography database, even if they
3297  are not cited.
3298  This can result in odd labels (e.
3299 \begin_inset space \thinspace{}
3300 \end_inset
3301
3302 g.
3303  
3304 \begin_inset Quotes eld
3305 \end_inset
3306
3307 Miller 2014b
3308 \begin_inset Quotes erd
3309 \end_inset
3310
3311  if two works of this author from 2014 are in the database, even if only
3312  one is cited).
3313 \end_layout
3314
3315 \begin_layout Standard
3316 If you use 
3317 \family sans
3318 Biblatex
3319 \family default
3320 , the 
3321 \begin_inset Flex Code
3322 status collapsed
3323
3324 \begin_layout Plain Layout
3325 refsection
3326 \end_layout
3327
3328 \end_inset
3329
3330  option is used instead.
3331  If you need specific units, you can start them with the \SpecialChar TeX
3332  code 
3333 \begin_inset Flex Code
3334 status collapsed
3335
3336 \begin_layout Plain Layout
3337
3338 \backslash
3339 newrefsection
3340 \end_layout
3341
3342 \end_inset
3343
3344  or 
3345 \begin_inset Flex Code
3346 status collapsed
3347
3348 \begin_layout Plain Layout
3349
3350 \backslash
3351 newrefsegment
3352 \end_layout
3353
3354 \end_inset
3355
3356 , respectively.
3357  If you also want to control the end of the unit, use the environment 
3358 \begin_inset Flex Code
3359 status collapsed
3360
3361 \begin_layout Plain Layout
3362
3363 \backslash
3364 begin{refsection}
3365 \end_layout
3366
3367 \end_inset
3368
3369  \SpecialChar ldots
3370  
3371 \begin_inset Flex Code
3372 status collapsed
3373
3374 \begin_layout Plain Layout
3375
3376 \backslash
3377 end{refsection}
3378 \end_layout
3379
3380 \end_inset
3381
3382  instead.
3383  Note, though, that 
3384 \begin_inset Flex Code
3385 status collapsed
3386
3387 \begin_layout Plain Layout
3388 refsection
3389 \end_layout
3390
3391 \end_inset
3392
3393 s cannot be nested.
3394  In addition to the individual bibliography of the current unit, 
3395 \family sans
3396 Biblatex
3397 \family default
3398  also provides an easy way to output all bibliographies, subsequently, at
3399  one place (e.
3400 \begin_inset space \thinspace{}
3401 \end_inset
3402
3403 g., at the end of the document).
3404  Select 
3405 \begin_inset Quotes eld
3406 \end_inset
3407
3408 all reference units
3409 \begin_inset Quotes erd
3410 \end_inset
3411
3412  from the Content combo box of the Bib(la)TeX inset dialog in order to achieve
3413  this.
3414  Please refer to the 
3415 \family sans
3416 Biblatex
3417 \family default
3418  manual for more information on this topic.
3419 \end_layout
3420
3421 \begin_layout Section
3422 Multipart Documents
3423 \end_layout
3424
3425 \begin_layout Subsection
3426 General Operation
3427 \end_layout
3428
3429 \begin_layout Standard
3430 When you are working on a large file with many sections, it is often convenient
3431  to break up the document into several files, or perhaps you have something
3432  where a table may change from time to time, but the preceding text does
3433  not.
3434  In these cases, you should seriously consider using multipart documents.
3435  For example, scientific papers often have five major sections: the introduction
3436 , observations, results, discussion, and conclusion.
3437  Each of these could be its own separate \SpecialChar LyX
3438  file, with one 
3439 \begin_inset Quotes eld
3440 \end_inset
3441
3442 master
3443 \begin_inset Quotes erd
3444 \end_inset
3445
3446  file which contains the title, authors, abstract, references, etc., plus
3447  the five included files.
3448  It is important to note that each of these files is a full \SpecialChar LyX
3449  file which
3450  can be formatted and printed on its own, as well as included in a master
3451  file.
3452  Each of these files must have the same document class, however—don't attempt
3453  to mix book classes with article classes.
3454  You may also include \SpecialChar LaTeX
3455  files; however, these files must not have their own
3456  preamble (i.
3457 \begin_inset space \thinspace{}
3458 \end_inset
3459
3460 e.
3461 \begin_inset space \space{}
3462 \end_inset
3463
3464 everything up to and including the 
3465 \begin_inset Flex Code
3466 status collapsed
3467
3468 \begin_layout Plain Layout
3469
3470 \backslash
3471 begin{document}
3472 \end_layout
3473
3474 \end_inset
3475
3476  line as well as the 
3477 \begin_inset Flex Code
3478 status collapsed
3479
3480 \begin_layout Plain Layout
3481
3482 \backslash
3483 end{document}
3484 \end_layout
3485
3486 \end_inset
3487
3488  line must be deleted) or else errors will be generated when you try to
3489  make a DVI file.
3490 \end_layout
3491
3492 \begin_layout Standard
3493 \SpecialChar LyX
3494  allows you to include files quite easily with 
3495 \begin_inset Flex Noun
3496 status collapsed
3497
3498 \begin_layout Plain Layout
3499 Insert\SpecialChar menuseparator
3500 Child
3501 \begin_inset space ~
3502 \end_inset
3503
3504 Document
3505 \end_layout
3506
3507 \end_inset
3508
3509 .
3510  When you click on this selection a small box is inserted into the file
3511  at the current cursor location.
3512  Clicking on the box raises a dialog which allows you to select the file
3513  to be included, and the method of its inclusion.
3514  
3515 \end_layout
3516
3517 \begin_layout Standard
3518 The file selection box should by now be obvious.
3519  The three inclusion methods are 
3520 \begin_inset Quotes eld
3521 \end_inset
3522
3523 include
3524 \begin_inset Quotes erd
3525 \end_inset
3526
3527
3528 \begin_inset Quotes eld
3529 \end_inset
3530
3531 input
3532 \begin_inset Quotes erd
3533 \end_inset
3534
3535 , and 
3536 \begin_inset Quotes eld
3537 \end_inset
3538
3539 verbatim
3540 \begin_inset Quotes erd
3541 \end_inset
3542
3543 .
3544  The methods 
3545 \begin_inset Quotes eld
3546 \end_inset
3547
3548 include
3549 \begin_inset Quotes erd
3550 \end_inset
3551
3552  and 
3553 \begin_inset Quotes eld
3554 \end_inset
3555
3556 input
3557 \begin_inset Quotes erd
3558 \end_inset
3559
3560  are similar in many ways, but there are also some notable differences:
3561 \end_layout
3562
3563 \begin_layout Enumerate
3564 Files that are 
3565 \begin_inset Quotes eld
3566 \end_inset
3567
3568 included
3569 \begin_inset Quotes erd
3570 \end_inset
3571
3572  are typeset beginning on a new page, while files that are 
3573 \begin_inset Quotes eld
3574 \end_inset
3575
3576 inputted
3577 \begin_inset Quotes erd
3578 \end_inset
3579
3580  are typeset starting on the current page.
3581 \end_layout
3582
3583 \begin_layout Enumerate
3584 \begin_inset Quotes eld
3585 \end_inset
3586
3587 Included
3588 \begin_inset Quotes erd
3589 \end_inset
3590
3591  files cannot themselves 
3592 \begin_inset Quotes eld
3593 \end_inset
3594
3595 include
3596 \begin_inset Quotes erd
3597 \end_inset
3598
3599  further files (
3600 \begin_inset Quotes eld
3601 \end_inset
3602
3603 grandchilds
3604 \begin_inset Quotes erd
3605 \end_inset
3606
3607 ).
3608  With 
3609 \begin_inset Quotes eld
3610 \end_inset
3611
3612 input
3613 \begin_inset Quotes erd
3614 \end_inset
3615
3616 , on the other hand, infinite sub-inputting is possible.
3617 \end_layout
3618
3619 \begin_layout Enumerate
3620 \begin_inset Quotes eld
3621 \end_inset
3622
3623 Include
3624 \begin_inset Quotes erd
3625 \end_inset
3626
3627  allow for the output of only selected 
3628 \begin_inset Quotes eld
3629 \end_inset
3630
3631 included
3632 \begin_inset Quotes erd
3633 \end_inset
3634
3635  files, while maintaining the actual counters (pagination etc.) and references
3636  (please refer to the section 
3637 \emph on
3638 Child
3639 \begin_inset space ~
3640 \end_inset
3641
3642 Documents
3643 \emph default
3644  of the 
3645 \emph on
3646 Embedded
3647 \begin_inset space ~
3648 \end_inset
3649
3650 Objects
3651 \emph default
3652  manual for details).
3653 \end_layout
3654
3655 \begin_layout Standard
3656 Hence, 
3657 \begin_inset Quotes eld
3658 \end_inset
3659
3660 include
3661 \begin_inset Quotes erd
3662 \end_inset
3663
3664  is the preferred method for chapters that are outsourced to child documents,
3665  while 
3666 \begin_inset Quotes eld
3667 \end_inset
3668
3669 input
3670 \begin_inset Quotes erd
3671 \end_inset
3672
3673  is more suitable for arbitrary file inheritance.
3674 \end_layout
3675
3676 \begin_layout Standard
3677
3678 \begin_inset Quotes eld
3679 \end_inset
3680
3681 verbatim
3682 \begin_inset Quotes erd
3683 \end_inset
3684
3685  included file allows you to include a file typeset exactly as it appears
3686  in the file, i.
3687 \begin_inset space \thinspace{}
3688 \end_inset
3689
3690 e.
3691 \begin_inset space \space{}
3692 \end_inset
3693
3694 in 
3695 \begin_inset Flex Code
3696 status collapsed
3697
3698 \begin_layout Plain Layout
3699 verbatim
3700 \end_layout
3701
3702 \end_inset
3703
3704  mode, with the characters set in a fixed-width typewriter font.
3705  Normally, spaces in this file are invisible, though two consecutive spaces
3706  are conserved, unlike \SpecialChar LyX
3707 's normal treatment of spaces.
3708  However, setting the 
3709 \begin_inset Flex Noun
3710 status collapsed
3711
3712 \begin_layout Plain Layout
3713 Mark
3714 \begin_inset space ~
3715 \end_inset
3716
3717 spaces
3718 \begin_inset space ~
3719 \end_inset
3720
3721 in
3722 \begin_inset space ~
3723 \end_inset
3724
3725 output
3726 \end_layout
3727
3728 \end_inset
3729
3730  checkbox typesets a mark to unambiguously define the presence of a space.
3731  
3732 \end_layout
3733
3734 \begin_layout Standard
3735 Generally, the master file is converted into a full \SpecialChar LaTeX
3736  file before typesetting,
3737  while the included files are converted to \SpecialChar LaTeX
3738  files that do not have all the
3739  preamble information.
3740 \end_layout
3741
3742 \begin_layout Subsection
3743 Cross-References Between Files
3744 \end_layout
3745
3746 \begin_layout Standard
3747 \begin_inset Box Shadowbox
3748 position "t"
3749 hor_pos "c"
3750 has_inner_box 1
3751 inner_pos "t"
3752 use_parbox 0
3753 use_makebox 0
3754 width "100col%"
3755 special "none"
3756 height "1in"
3757 height_special "totalheight"
3758 thickness "0.4pt"
3759 separation "3pt"
3760 shadowsize "4pt"
3761 framecolor "black"
3762 backgroundcolor "none"
3763 status open
3764
3765 \begin_layout Plain Layout
3766 This section is somewhat out of date.
3767  Need to describe default master documents and how children are opened when
3768  the master is.
3769  [[FIXME]]
3770 \end_layout
3771
3772 \end_inset
3773
3774
3775 \end_layout
3776
3777 \begin_layout Standard
3778 It is possible to set up cross-references between the different files.
3779  First, open all the files in question: let's call them A and B in a two
3780  file example, where B is included in A.
3781  Let's say you insert a label in A, then want to reference it in B.
3782  Open the cross-reference dialog whilst in document B, and you can select
3783  the 
3784 \begin_inset Quotes eld
3785 \end_inset
3786
3787 buffer
3788 \begin_inset Quotes erd
3789 \end_inset
3790
3791  to use.
3792 \end_layout
3793
3794 \begin_layout Subsection
3795 Bibliography Lists in all Subdocuments
3796 \end_layout
3797
3798 \begin_layout Standard
3799 If you work with child documents, you might want to have only one main bibliogra
3800 phy at the end, but still be able to have a selected bibliography for the
3801  child if you output it on its own.
3802  Here is how to achieve this.
3803 \end_layout
3804
3805 \begin_layout Standard
3806 For the main document, you just insert a bibliography inset at the place
3807  where the main bibliography has to appear (within the master file or within
3808  a child).
3809  If the bibliography inset is in the master file, the references will be
3810  inherited by all children, so they are available in the citation dialog
3811  within each child.
3812 \end_layout
3813
3814 \begin_layout Standard
3815 For child-specific bibliographies, insert bibliography insets within the
3816  child documents, at the place where the bibliography should appear when
3817  the child is compiled separately.
3818  However, the trick is to insert them into a branch (
3819 \family sans
3820 Insert\SpecialChar menuseparator
3821 Branch\SpecialChar menuseparator
3822 Insert New Branch...
3823 \family default
3824 ), e.
3825 \begin_inset space \thinspace{}
3826 \end_inset
3827
3828 g.
3829  called 
3830 \begin_inset Quotes eld
3831 \end_inset
3832
3833 Childonly
3834 \begin_inset Quotes erd
3835 \end_inset
3836
3837 .
3838  Within the children, activate the branch (
3839 \family sans
3840 Document\SpecialChar menuseparator
3841 Settings...\SpecialChar menuseparator
3842 Branches
3843 \family default
3844 ).
3845  Within the master, deactivate the branch (
3846 \family sans
3847 Document\SpecialChar menuseparator
3848 Settings...\SpecialChar menuseparator
3849 Branches
3850 \family default
3851 ).
3852  Now the child's bibliography will be ignored by the master, but considered
3853  by the child.
3854 \end_layout
3855
3856 \begin_layout Standard
3857 If you need multiple bibliographies (e.
3858 \begin_inset space \thinspace{}
3859 \end_inset
3860
3861 g., one per child in the 
3862 \emph on
3863 main document
3864 \emph default
3865 ), please refer to sec.
3866 \begin_inset space ~
3867 \end_inset
3868
3869
3870 \begin_inset CommandInset ref
3871 LatexCommand ref
3872 reference "subsec:Multiple-Bibliographies"
3873
3874 \end_inset
3875
3876 .
3877 \end_layout
3878
3879 \begin_layout Section
3880 \SpecialChar LyX
3881  Archives
3882 \end_layout
3883
3884 \begin_layout Standard
3885 Users sometimes need to be able to 
3886 \begin_inset Quotes eld
3887 \end_inset
3888
3889 bundle
3890 \begin_inset Quotes erd
3891 \end_inset
3892
3893  a \SpecialChar LyX
3894  file together with all the images (and other files) on which it depends,
3895  either for sending to a publisher or for sharing with a co-author.
3896  \SpecialChar LyX
3897  includes a Python script (
3898 \begin_inset Flex Code
3899 status collapsed
3900
3901 \begin_layout Plain Layout
3902 lyxpak.py
3903 \end_layout
3904
3905 \end_inset
3906
3907 ) that automates this process.
3908  To use it, you must have either the 
3909 \begin_inset Flex Code
3910 status collapsed
3911
3912 \begin_layout Plain Layout
3913 zipfile
3914 \end_layout
3915
3916 \end_inset
3917
3918  or 
3919 \begin_inset Flex Code
3920 status collapsed
3921
3922 \begin_layout Plain Layout
3923 tarfile
3924 \end_layout
3925
3926 \end_inset
3927
3928  python modules installed on your system.
3929  By default, the script prefers the 
3930 \begin_inset Flex Code
3931 status collapsed
3932
3933 \begin_layout Plain Layout
3934 gzip
3935 \end_layout
3936
3937 \end_inset
3938
3939 -compressed 
3940 \begin_inset Flex Code
3941 status collapsed
3942
3943 \begin_layout Plain Layout
3944 tar
3945 \end_layout
3946
3947 \end_inset
3948
3949  format on Unix-like systems and the 
3950 \begin_inset Flex Code
3951 status collapsed
3952
3953 \begin_layout Plain Layout
3954 zip
3955 \end_layout
3956
3957 \end_inset
3958
3959  format on Windows.
3960 \end_layout
3961
3962 \begin_layout Standard
3963 \SpecialChar LyX
3964 's configuration process will set the script up to export a `\SpecialChar LyX
3965  Archive',
3966  and this format will then be available under 
3967 \begin_inset Flex Code
3968 status collapsed
3969
3970 \begin_layout Plain Layout
3971 File\SpecialChar menuseparator
3972 Export
3973 \end_layout
3974
3975 \end_inset
3976
3977 .
3978 \end_layout
3979
3980 \begin_layout Standard
3981 Independently of the platform, the generation of a particular archive format
3982  can be forced by adding either the 
3983 \begin_inset Flex Code
3984 status collapsed
3985
3986 \begin_layout Plain Layout
3987 -t
3988 \end_layout
3989
3990 \end_inset
3991
3992  (for the 
3993 \begin_inset Flex Code
3994 status collapsed
3995
3996 \begin_layout Plain Layout
3997 tar
3998 \end_layout
3999
4000 \end_inset
4001
4002  format) or 
4003 \begin_inset Flex Code
4004 status collapsed
4005
4006 \begin_layout Plain Layout
4007 -z
4008 \end_layout
4009
4010 \end_inset
4011
4012  (for the 
4013 \begin_inset Flex Code
4014 status collapsed
4015
4016 \begin_layout Plain Layout
4017 zip
4018 \end_layout
4019
4020 \end_inset
4021
4022  format) switch to the 
4023 \begin_inset Flex Code
4024 status collapsed
4025
4026 \begin_layout Plain Layout
4027 \SpecialChar LyX
4028 \SpecialChar menuseparator
4029 \SpecialChar LyX
4030  Archive
4031 \end_layout
4032
4033 \end_inset
4034
4035  converter in 
4036 \begin_inset Flex Code
4037 status collapsed
4038
4039 \begin_layout Plain Layout
4040 Tools\SpecialChar menuseparator
4041 Preferences\SpecialChar menuseparator
4042 File Handling\SpecialChar menuseparator
4043 Converters
4044 \end_layout
4045
4046 \end_inset
4047
4048 .
4049  (Make sure you add the switch after the script name, not before it.)
4050 \end_layout
4051
4052 \begin_layout Section
4053 Fancy Headers and Footers
4054 \end_layout
4055
4056 \begin_layout Standard
4057 The default page layout is rather plain; for an 
4058 \begin_inset Flex Code
4059 status collapsed
4060
4061 \begin_layout Plain Layout
4062 article
4063 \end_layout
4064
4065 \end_inset
4066
4067  document class, all you get is a centered page number at the bottom of
4068  the page.
4069  This document uses KOMA-script's book class, so it appears to be a bit
4070  fancier.
4071  But to really put on a show, you need to set the document page style to
4072  
4073 \begin_inset Quotes eld
4074 \end_inset
4075
4076 fancy
4077 \begin_inset Quotes erd
4078 \end_inset
4079
4080 , as mentioned in the 
4081 \emph on
4082 User Guide
4083 \emph default
4084 .
4085  This section describes the \SpecialChar LaTeX
4086  code you need to insert in your \SpecialChar LaTeX
4087  preamble in
4088  order to get the desired effects.
4089 \end_layout
4090
4091 \begin_layout Standard
4092 For more information on fancy headers, see the 
4093 \begin_inset Flex Code
4094 status collapsed
4095
4096 \begin_layout Plain Layout
4097 fancyhdr
4098 \end_layout
4099
4100 \end_inset
4101
4102  package documentation.
4103  (
4104 \begin_inset Flex URL
4105 status collapsed
4106
4107 \begin_layout Plain Layout
4108
4109 https://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
4110 \end_layout
4111
4112 \end_inset
4113
4114 )
4115 \end_layout
4116
4117 \begin_layout Standard
4118 The page header is divided into three fields, not surprisingly labeled 
4119 \begin_inset Quotes eld
4120 \end_inset
4121
4122 left
4123 \begin_inset Quotes erd
4124 \end_inset
4125
4126
4127 \begin_inset Quotes eld
4128 \end_inset
4129
4130 center
4131 \begin_inset Quotes erd
4132 \end_inset
4133
4134 , and 
4135 \begin_inset Quotes eld
4136 \end_inset
4137
4138 right
4139 \begin_inset Quotes erd
4140 \end_inset
4141
4142 .
4143  The footer is also divided into these three fields.
4144  The \SpecialChar LaTeX
4145  commands to set these fields in the simplest manner are 
4146 \begin_inset Flex Code
4147 status collapsed
4148
4149 \begin_layout Plain Layout
4150
4151 \backslash
4152 lhead
4153 \end_layout
4154
4155 \end_inset
4156
4157
4158 \begin_inset Flex Code
4159 status collapsed
4160
4161 \begin_layout Plain Layout
4162
4163 \backslash
4164 chead
4165 \end_layout
4166
4167 \end_inset
4168
4169
4170 \begin_inset Flex Code
4171 status collapsed
4172
4173 \begin_layout Plain Layout
4174
4175 \backslash
4176 rhead
4177 \end_layout
4178
4179 \end_inset
4180
4181
4182 \begin_inset Flex Code
4183 status collapsed
4184
4185 \begin_layout Plain Layout
4186
4187 \backslash
4188 lfoot
4189 \end_layout
4190
4191 \end_inset
4192
4193 , etc.
4194  Suppose you wish to put your name in the upper left hand corner of each
4195  page.
4196  Simply insert the following command in the preamble: 
4197 \end_layout
4198
4199 \begin_layout Standard
4200
4201 \family typewriter
4202
4203 \backslash
4204 lhead{John Q.
4205  DocWriter}
4206 \end_layout
4207
4208 \begin_layout Standard
4209 You will now see your name in the upper left.
4210  If a field has a default entry that you would like to get rid of (often
4211  the page number appears in the central footer) simply include a command
4212  with a blank argument, e.
4213 \begin_inset space \thinspace{}
4214 \end_inset
4215
4216 g.:
4217 \end_layout
4218
4219 \begin_layout Standard
4220
4221 \family typewriter
4222
4223 \backslash
4224 cfoot{}
4225 \end_layout
4226
4227 \begin_layout Standard
4228 Let's get really fancy: lets put the section number with the word 
4229 \begin_inset Quotes eld
4230 \end_inset
4231
4232 Section
4233 \begin_inset Quotes erd
4234 \end_inset
4235
4236  (e.
4237 \begin_inset space \thinspace{}
4238 \end_inset
4239
4240 g.
4241 \begin_inset space \space{}
4242 \end_inset
4243
4244 Section 3) in the upper left, the page number (e.
4245 \begin_inset space \thinspace{}
4246 \end_inset
4247
4248 g.
4249 \begin_inset space \space{}
4250 \end_inset
4251
4252 Page 4) in the upper right, your name in the lower left, and the date in
4253  the lower right.
4254  The following commands should now appear in the preamble:
4255 \end_layout
4256
4257 \begin_layout Standard
4258
4259 \family typewriter
4260
4261 \backslash
4262 lhead{Section 
4263 \backslash
4264 thesection}
4265 \end_layout
4266
4267 \begin_layout Standard
4268
4269 \family typewriter
4270
4271 \backslash
4272 chead{}
4273 \end_layout
4274
4275 \begin_layout Standard
4276
4277 \family typewriter
4278
4279 \backslash
4280 rhead{Page 
4281 \backslash
4282 thepage}
4283 \end_layout
4284
4285 \begin_layout Standard
4286
4287 \family typewriter
4288
4289 \backslash
4290 lfoot{John Q.
4291  DocWriter}
4292 \end_layout
4293
4294 \begin_layout Standard
4295
4296 \family typewriter
4297
4298 \backslash
4299 cfoot{}
4300 \end_layout
4301
4302 \begin_layout Standard
4303
4304 \family typewriter
4305
4306 \backslash
4307 rfoot{
4308 \backslash
4309 today}
4310 \end_layout
4311
4312 \begin_layout Standard
4313 The commands 
4314 \begin_inset Flex Code
4315 status collapsed
4316
4317 \begin_layout Plain Layout
4318
4319 \backslash
4320 thesection
4321 \end_layout
4322
4323 \end_inset
4324
4325  and 
4326 \begin_inset Flex Code
4327 status collapsed
4328
4329 \begin_layout Plain Layout
4330
4331 \backslash
4332 thepage
4333 \end_layout
4334
4335 \end_inset
4336
4337  access \SpecialChar LaTeX
4338 's section and page counters, and so print out the current section
4339  and page number.
4340  
4341 \begin_inset Flex Code
4342 status collapsed
4343
4344 \begin_layout Plain Layout
4345
4346 \backslash
4347 today
4348 \end_layout
4349
4350 \end_inset
4351
4352  simply prints out today's date.
4353 \end_layout
4354
4355 \begin_layout Standard
4356 The thicknesses of the horizontal rules drawn beneath the header and above
4357  the footer can also be modified.
4358  If you don't want one of the rules, set its thickness to 0.
4359  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
4360  Use commands
4361 \family typewriter
4362  
4363 \family default
4364 like 
4365 \begin_inset Flex Code
4366 status collapsed
4367
4368 \begin_layout Plain Layout
4369
4370 \backslash
4371 renewcommand{
4372 \backslash
4373 headrulewidth}{0.4pt}
4374 \end_layout
4375
4376 \end_inset
4377
4378  and 
4379 \begin_inset Flex Code
4380 status collapsed
4381
4382 \begin_layout Plain Layout
4383
4384 \backslash
4385 renewcommand{
4386 \backslash
4387 footrulewidth}{0.4pt}
4388 \end_layout
4389
4390 \end_inset
4391
4392  to set the thicknesses.
4393 \end_layout
4394
4395 \begin_layout Standard
4396 You can switch the header/footer settings on and off for individual pages
4397  using commands like 
4398 \begin_inset Flex Code
4399 status collapsed
4400
4401 \begin_layout Plain Layout
4402
4403 \backslash
4404 thispagestyle{empty}
4405 \end_layout
4406
4407 \end_inset
4408
4409
4410 \begin_inset Flex Code
4411 status collapsed
4412
4413 \begin_layout Plain Layout
4414
4415 \backslash
4416 thispagestyle{plain}
4417 \end_layout
4418
4419 \end_inset
4420
4421 , and 
4422 \begin_inset Flex Code
4423 status collapsed
4424
4425 \begin_layout Plain Layout
4426
4427 \backslash
4428 thispagestyle{fancy}
4429 \end_layout
4430
4431 \end_inset
4432
4433 .
4434  Simply insert them in the text on the page you want changed and mark them
4435  as \SpecialChar TeX
4436  code.
4437  In fact, title pages are marked as plain by default, while following pages
4438  are marked fancy when using the global fancy setting.
4439 \end_layout
4440
4441 \begin_layout Standard
4442 As a final example, it is possible to include an image in the header or
4443  footer.
4444  Suppose you want to put a company logo in the upper lefthand corner.
4445  You might try something like
4446 \end_layout
4447
4448 \begin_layout Standard
4449
4450 \family typewriter
4451
4452 \backslash
4453 lhead{
4454 \backslash
4455 resizebox{1in}{!}{
4456 \backslash
4457 includegraphics{logo.eps}}}
4458 \end_layout
4459
4460 \begin_layout Standard
4461 \noindent
4462 (you may need to preface this with 
4463 \begin_inset Flex Code
4464 status collapsed
4465
4466 \begin_layout Plain Layout
4467
4468 \backslash
4469 usepackage{graphics}
4470 \end_layout
4471
4472 \end_inset
4473
4474  if you don't include graphics elsewhere in your document).
4475 \end_layout
4476
4477 \begin_layout Section
4478 Itemize Bullet Selection
4479 \begin_inset CommandInset label
4480 LatexCommand label
4481 name "sec:bullet"
4482
4483 \end_inset
4484
4485
4486 \end_layout
4487
4488 \begin_layout Standard
4489 by
4490 \noun on
4491  Allan Rae
4492 \end_layout
4493
4494 \begin_layout Subsection
4495 Introduction
4496 \end_layout
4497
4498 \begin_layout Standard
4499 \SpecialChar LyX
4500  provides 216 bullet shapes that can be accessed from a simple dialog.
4501  Using this dialog you can easily specify what bullet shape to use at each
4502  level of an itemized list.
4503  These settings are document-wide so you won't be able to specify different
4504  sets of bullets for different paragraphs.
4505 \begin_inset Foot
4506 status collapsed
4507
4508 \begin_layout Plain Layout
4509 Well, actually you can but you'll have to do it by hand.
4510 \end_layout
4511
4512 \end_inset
4513
4514
4515 \end_layout
4516
4517 \begin_layout Subsection
4518 How it looks
4519 \end_layout
4520
4521 \begin_layout Standard
4522 Open the dialog by selecting the 
4523 \begin_inset Flex Noun
4524 status collapsed
4525
4526 \begin_layout Plain Layout
4527 Document\SpecialChar menuseparator
4528 Settings
4529 \end_layout
4530
4531 \end_inset
4532
4533  menu item and then select the 
4534 \begin_inset Flex Noun
4535 status collapsed
4536
4537 \begin_layout Plain Layout
4538 Bullets
4539 \end_layout
4540
4541 \end_inset
4542
4543  tab.
4544 \end_layout
4545
4546 \begin_layout Standard
4547 The dialog provides you with a table of bullet shapes.
4548  A column of buttons on the left of the table provides access to the six
4549  different panels of bullet shapes.
4550  The row of buttons across the top is used to select which bullet depth
4551  you are changing.
4552
4553 \change_deleted 244031559 1603875981
4554  A text entry under the table shows the currently selected bullet shape's
4555  \SpecialChar LaTeX
4556  equivalent and this can be edited if desired.
4557  If you do modify the text you will also need to specify any needed packages
4558  in the \SpecialChar LaTeX
4559  preamble.
4560 \change_unchanged
4561
4562 \end_layout
4563
4564 \begin_layout Standard
4565 The six panels are divided up by the packages they require.
4566  The following table shows the mappings from button name to \SpecialChar LaTeX
4567  package.
4568 \end_layout
4569
4570 \begin_layout Standard
4571 \align center
4572 \begin_inset Tabular
4573 <lyxtabular version="3" rows="7" columns="2">
4574 <features tabularvalignment="middle">
4575 <column alignment="center" valignment="top" width="0pt">
4576 <column alignment="center" valignment="top" width="0pt">
4577 <row>
4578 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4579 \begin_inset Text
4580
4581 \begin_layout Plain Layout
4582
4583 \family roman
4584 \series medium
4585 \shape up
4586 \size normal
4587 \emph off
4588 \bar no
4589 \noun off
4590 \color none
4591 Button
4592 \end_layout
4593
4594 \end_inset
4595 </cell>
4596 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4597 \begin_inset Text
4598
4599 \begin_layout Plain Layout
4600
4601 \family roman
4602 \series medium
4603 \shape up
4604 \size normal
4605 \emph off
4606 \bar no
4607 \noun off
4608 \color none
4609 Packages Required
4610 \end_layout
4611
4612 \end_inset
4613 </cell>
4614 </row>
4615 <row>
4616 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4617 \begin_inset Text
4618
4619 \begin_layout Plain Layout
4620
4621 \family sans
4622 \series medium
4623 \shape up
4624 \size normal
4625 \emph off
4626 \bar no
4627 \noun off
4628 \color none
4629 Standard
4630 \end_layout
4631
4632 \end_inset
4633 </cell>
4634 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4635 \begin_inset Text
4636
4637 \begin_layout Plain Layout
4638
4639 \series medium
4640 \shape up
4641 \size normal
4642 \emph off
4643 \bar no
4644 \noun off
4645 \color none
4646 base \SpecialChar LaTeX
4647
4648 \end_layout
4649
4650 \end_inset
4651 </cell>
4652 </row>
4653 <row>
4654 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4655 \begin_inset Text
4656
4657 \begin_layout Plain Layout
4658
4659 \family sans
4660 \series medium
4661 \shape up
4662 \size normal
4663 \emph off
4664 \bar no
4665 \noun off
4666 \color none
4667 Maths
4668 \end_layout
4669
4670 \end_inset
4671 </cell>
4672 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4673 \begin_inset Text
4674
4675 \begin_layout Plain Layout
4676
4677 \family typewriter
4678 \series medium
4679 \shape up
4680 \size normal
4681 \emph off
4682 \bar no
4683 \noun off
4684 \color none
4685 amssymb.sty
4686 \end_layout
4687
4688 \end_inset
4689 </cell>
4690 </row>
4691 <row>
4692 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4693 \begin_inset Text
4694
4695 \begin_layout Plain Layout
4696
4697 \family sans
4698 \series medium
4699 \shape up
4700 \size normal
4701 \emph off
4702 \bar no
4703 \noun off
4704 \color none
4705 Ding1
4706 \end_layout
4707
4708 \end_inset
4709 </cell>
4710 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4711 \begin_inset Text
4712
4713 \begin_layout Plain Layout
4714
4715 \family typewriter
4716 \series medium
4717 \shape up
4718 \size normal
4719 \emph off
4720 \bar no
4721 \noun off
4722 \color none
4723 pifont.sty
4724 \end_layout
4725
4726 \end_inset
4727 </cell>
4728 </row>
4729 <row>
4730 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4731 \begin_inset Text
4732
4733 \begin_layout Plain Layout
4734
4735 \family sans
4736 \series medium
4737 \shape up
4738 \size normal
4739 \emph off
4740 \bar no
4741 \noun off
4742 \color none
4743 Ding2
4744 \end_layout
4745
4746 \end_inset
4747 </cell>
4748 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4749 \begin_inset Text
4750
4751 \begin_layout Plain Layout
4752
4753 \family typewriter
4754 \series medium
4755 \shape up
4756 \size normal
4757 \emph off
4758 \bar no
4759 \noun off
4760 \color none
4761 pifont.sty
4762 \end_layout
4763
4764 \end_inset
4765 </cell>
4766 </row>
4767 <row>
4768 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4769 \begin_inset Text
4770
4771 \begin_layout Plain Layout
4772
4773 \family sans
4774 \series medium
4775 \shape up
4776 \size normal
4777 \emph off
4778 \bar no
4779 \noun off
4780 \color none
4781 Ding3
4782 \end_layout
4783
4784 \end_inset
4785 </cell>
4786 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4787 \begin_inset Text
4788
4789 \begin_layout Plain Layout
4790
4791 \family typewriter
4792 \series medium
4793 \shape up
4794 \size normal
4795 \emph off
4796 \bar no
4797 \noun off
4798 \color none
4799 pifont.sty
4800 \end_layout
4801
4802 \end_inset
4803 </cell>
4804 </row>
4805 <row>
4806 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4807 \begin_inset Text
4808
4809 \begin_layout Plain Layout
4810
4811 \family sans
4812 \series medium
4813 \shape up
4814 \size normal
4815 \emph off
4816 \bar no
4817 \noun off
4818 \color none
4819 Ding4
4820 \end_layout
4821
4822 \end_inset
4823 </cell>
4824 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4825 \begin_inset Text
4826
4827 \begin_layout Plain Layout
4828
4829 \family typewriter
4830 \series medium
4831 \shape up
4832 \size normal
4833 \emph off
4834 \bar no
4835 \noun off
4836 \color none
4837 pifont.sty
4838 \end_layout
4839
4840 \end_inset
4841 </cell>
4842 </row>
4843 </lyxtabular>
4844
4845 \end_inset
4846
4847
4848 \end_layout
4849
4850 \begin_layout Standard
4851 \SpecialChar LyX
4852  doesn't stop you using bullets from packages you don't have.
4853  If you get errors from \SpecialChar LaTeX
4854  when you try to view or print the file, then it
4855  is likely you are missing a package.
4856 \begin_inset Foot
4857 status collapsed
4858
4859 \begin_layout Plain Layout
4860 \SpecialChar LyX
4861  doesn't restrict your use since you may be editing locally and exporting
4862  elsewhere.
4863 \end_layout
4864
4865 \end_inset
4866
4867
4868 \end_layout
4869
4870 \begin_layout Subsection
4871 How to use it
4872 \end_layout
4873
4874 \begin_layout Standard
4875 Select which bullet depth you want to change then select the bullet shape
4876  and size.
4877  Any changes will not be visible in \SpecialChar LyX
4878 , but are visible when viewing the document.
4879 \end_layout
4880
4881 \begin_layout Standard
4882 You can reset a bullet shape to the default simply by clicking your right
4883  mouse button on the appropriate bullet depth button.
4884 \begin_inset Foot
4885 status open
4886
4887 \begin_layout Plain Layout
4888 If you 
4889 \emph on
4890 really
4891 \emph default
4892  want to have multiple sets of paragraphs with different sets of bullets
4893  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
4894  code.
4895  The bullet selection dialog can help though because it provides you with
4896  the \SpecialChar LaTeX
4897  code for a wide range of bullet shapes.
4898  To make your own custom paragraphs you have the following options:
4899 \end_layout
4900
4901 \begin_layout Plain Layout
4902 \begin_inset ERT
4903 status open
4904
4905 \begin_layout Plain Layout
4906
4907
4908 \backslash
4909 let
4910 \backslash
4911 savelabelitemi=
4912 \backslash
4913 labelitemi
4914 \end_layout
4915
4916 \end_inset
4917
4918
4919 \end_layout
4920
4921 \begin_layout Plain Layout
4922 \begin_inset ERT
4923 status open
4924
4925 \begin_layout Plain Layout
4926
4927
4928 \backslash
4929 renewcommand
4930 \backslash
4931 labelitemi[0]{
4932 \backslash
4933 small
4934 \backslash
4935 (
4936 \backslash
4937 sharp
4938 \backslash
4939 )}
4940 \end_layout
4941
4942 \end_inset
4943
4944
4945 \end_layout
4946
4947 \begin_layout Itemize
4948 Use the \SpecialChar LaTeX
4949  command 
4950 \begin_inset Flex Code
4951 status collapsed
4952
4953 \begin_layout Plain Layout
4954
4955 \backslash
4956 renewcommand{}{}
4957 \end_layout
4958
4959 \end_inset
4960
4961  to specify a new bullet shape for a given depth.
4962  You'll also need to save the current bullet shape so you can restore it
4963  again afterwards.
4964  In this itemized list the following \SpecialChar LaTeX
4965  code was used to change the bullet
4966  used for the first depth.
4967 \end_layout
4968
4969 \begin_deeper
4970 \begin_layout LyX-Code
4971
4972 \backslash
4973 let
4974 \backslash
4975 savelabelitemi=
4976 \backslash
4977 labelitemi 
4978 \end_layout
4979
4980 \begin_layout LyX-Code
4981
4982 \backslash
4983 renewcommand
4984 \backslash
4985 labelitemi[0]{
4986 \backslash
4987 small
4988 \backslash
4989 (
4990 \backslash
4991 sharp
4992 \backslash
4993 )}
4994 \end_layout
4995
4996 \end_deeper
4997 \begin_layout Itemize
4998 Note that the itemize depth is specified in Roman numerals as part of the
4999  
5000 \family typewriter
5001
5002 \backslash
5003 labelitem
5004 \family default
5005  command.
5006 \end_layout
5007
5008 \begin_layout Itemize
5009 \begin_inset Argument item:1
5010 status open
5011
5012 \begin_layout Plain Layout
5013 \begin_inset ERT
5014 status open
5015
5016 \begin_layout Plain Layout
5017
5018
5019 \backslash
5020 (
5021 \backslash
5022 star
5023 \backslash
5024 )
5025 \end_layout
5026
5027 \end_inset
5028
5029
5030 \end_layout
5031
5032 \end_inset
5033
5034  Specify each individual entry by starting each item with the bullet shape
5035  enclosed in a 
5036 \begin_inset Quotes eld
5037 \end_inset
5038
5039 Custom Item
5040 \begin_inset Quotes erd
5041 \end_inset
5042
5043  inset (available at 
5044 \family sans
5045 Insert\SpecialChar menuseparator
5046 Custom Item
5047 \family default
5048 ) and set as 
5049 \begin_inset Flex Noun
5050 status collapsed
5051
5052 \begin_layout Plain Layout
5053 \SpecialChar TeX
5054  Code
5055 \end_layout
5056
5057 \end_inset
5058
5059 .
5060  For example, this item was started with 
5061 \begin_inset Flex Code
5062 status collapsed
5063
5064 \begin_layout Plain Layout
5065
5066 \backslash
5067 (
5068 \backslash
5069 star
5070 \backslash
5071 )
5072 \end_layout
5073
5074 \end_inset
5075
5076 .
5077 \end_layout
5078
5079 \begin_layout Plain Layout
5080 \begin_inset ERT
5081 status open
5082
5083 \begin_layout Plain Layout
5084
5085
5086 \backslash
5087 renewcommand
5088 \backslash
5089 labelitemi[0]{
5090 \backslash
5091 savelabelitemi}
5092 \end_layout
5093
5094 \end_inset
5095
5096
5097 \end_layout
5098
5099 \begin_layout Plain Layout
5100 You'll also need to revert the labelitem back to its previous setting for
5101  the global bullet shape settings to remain in effect.
5102  The way used here was:
5103 \end_layout
5104
5105 \begin_layout LyX-Code
5106
5107 \backslash
5108 renewcommand
5109 \backslash
5110 labelitemi[0]{
5111 \backslash
5112 savelabelitemi}
5113 \end_layout
5114
5115 \end_inset
5116
5117
5118 \end_layout
5119
5120 \begin_layout Chapter
5121 \SpecialChar LyX
5122  and the World Wide Web
5123 \end_layout
5124
5125 \begin_layout Standard
5126 \SpecialChar LyX
5127  has long supported the export of documents to various web-friendly formats,
5128  such as HTML.
5129  Before version 2.0, however, HTML export was always accomplished by the
5130  use of external converters.
5131 \begin_inset Foot
5132 status collapsed
5133
5134 \begin_layout Plain Layout
5135 For details on the use of external converters with \SpecialChar LyX
5136 , see the 
5137 \emph on
5138 Converters
5139 \emph default
5140  section of the Customization manual.
5141 \end_layout
5142
5143 \end_inset
5144
5145  These fall into two large groups: there are converters that use \SpecialChar LaTeX
5146  as an
5147  intermediate format, such as 
5148 \begin_inset Flex Code
5149 status collapsed
5150
5151 \begin_layout Plain Layout
5152 htlatex
5153 \end_layout
5154
5155 \end_inset
5156
5157
5158 \begin_inset Flex Code
5159 status collapsed
5160
5161 \begin_layout Plain Layout
5162 html2latex
5163 \end_layout
5164
5165 \end_inset
5166
5167 , and 
5168 \begin_inset Flex Code
5169 status collapsed
5170
5171 \begin_layout Plain Layout
5172 plastex
5173 \end_layout
5174
5175 \end_inset
5176
5177 , relying upon \SpecialChar LyX
5178  to produce the \SpecialChar LaTeX
5179 ; and there is a converter that works directly
5180  on \SpecialChar LyX
5181  files, 
5182 \begin_inset Flex Code
5183 status collapsed
5184
5185 \begin_layout Plain Layout
5186 e\SpecialChar LyX
5187 er
5188 \end_layout
5189
5190 \end_inset
5191
5192 .
5193  All of these have different advantages and disadvantages.
5194  
5195 \end_layout
5196
5197 \begin_layout Standard
5198 The \SpecialChar LaTeX
5199 -based converters have the advantage that, in principle, they know everythin
5200 g about the exported document that \SpecialChar LaTeX
5201  does.
5202  Such converters do not care, for example, if a certain block of code was
5203  produced by \SpecialChar LyX
5204  or was Evil Red Text.
5205  These converters know about 
5206 \begin_inset Flex Code
5207 status collapsed
5208
5209 \begin_layout Plain Layout
5210 aux
5211 \end_layout
5212
5213 \end_inset
5214
5215  files, counters, and references, and can often make use of the 
5216 \begin_inset Flex Code
5217 status collapsed
5218
5219 \begin_layout Plain Layout
5220 bbl
5221 \end_layout
5222
5223 \end_inset
5224
5225  files generated by Bib\SpecialChar TeX
5226 .
5227  On the other hand, \SpecialChar LaTeX
5228  is a very hard language to parse—it is sometimes said
5229  that only \SpecialChar TeX
5230  itself understands \SpecialChar TeX
5231 —and \SpecialChar LaTeX
5232 -based converters will often choke on
5233  what seem to be quite simple constructs; complex ones can throw them completely
5234 , and as of this writing, for example, the 
5235 \emph on
5236 Embedded Objects
5237 \emph default
5238  manual will not export with 
5239 \begin_inset Flex Code
5240 status collapsed
5241
5242 \begin_layout Plain Layout
5243 htlatex
5244 \end_layout
5245
5246 \end_inset
5247
5248 , though the others will.
5249  The other issue concerns how math is handled.
5250  These converters typically convert the formulae into little pictures that
5251  are then linked from the HTML document.
5252  Since these are actually generated by \SpecialChar LaTeX
5253 , they are accurate.
5254  But they do not scale well, and just getting them to look as if they are
5255  actually meant to be in your document—so that the font sizes seem to be
5256  roughly the same—can be a challenge.
5257 \end_layout
5258
5259 \begin_layout Standard
5260 Alex Fernandez's 
5261 \begin_inset Flex Code
5262 status collapsed
5263
5264 \begin_layout Plain Layout
5265 e\SpecialChar LyX
5266 er
5267 \end_layout
5268
5269 \end_inset
5270
5271  (
5272 \begin_inset CommandInset href
5273 LatexCommand href
5274 name "http://pinchito.es/elyxer/"
5275 target "http://pinchito.es/elyxer/"
5276 literal "false"
5277
5278 \end_inset
5279
5280 ) solves some of these problems.
5281  In particular, the formulae it produces scale perfectly, since it renders
5282  math using a combination of HTML and CSS rather than converting the formulae
5283  to images.
5284  But even moderately complex formula are rendered less well than with 
5285 \begin_inset Flex Code
5286 status collapsed
5287
5288 \begin_layout Plain Layout
5289 htlatex
5290 \end_layout
5291
5292 \end_inset
5293
5294 ; this reflects the limitations of HTML.
5295 \begin_inset Foot
5296 status collapsed
5297
5298 \begin_layout Plain Layout
5299 That said, 
5300 \begin_inset Flex Code
5301 status collapsed
5302
5303 \begin_layout Plain Layout
5304 e\SpecialChar LyX
5305 er
5306 \end_layout
5307
5308 \end_inset
5309
5310  can also use jsMath and MathJax for equations, but this setting is only
5311  available globally and requires one to have access to a server that runs
5312  the backend.
5313 \end_layout
5314
5315 \end_inset
5316
5317  More importantly (as of version 1.1.1, at least), 
5318 \begin_inset Flex Code
5319 status collapsed
5320
5321 \begin_layout Plain Layout
5322 e\SpecialChar LyX
5323 er
5324 \end_layout
5325
5326 \end_inset
5327
5328  has limited support for math macros and no support for user-defined paragraph
5329  or character styles.
5330  These limitations make 
5331 \begin_inset Flex Code
5332 status collapsed
5333
5334 \begin_layout Plain Layout
5335 e\SpecialChar LyX
5336 er
5337 \end_layout
5338
5339 \end_inset
5340
5341  unsuitable for many of the documents \SpecialChar LyX
5342  users produce.
5343  In principle, of course, these problems could be solved, but the \SpecialChar LyX
5344  developers
5345  have decided to follow a different path and have made \SpecialChar LyX
5346  itself capable of
5347  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
5348 , DocBook, and plaintext.
5349 \end_layout
5350
5351 \begin_layout Standard
5352 As of this writing, XHTML output remains under development and should probably
5353  be regarded as 
5354 \begin_inset Quotes eld
5355 \end_inset
5356
5357 experimental
5358 \begin_inset Quotes erd
5359 \end_inset
5360
5361 .
5362 \begin_inset Foot
5363 status collapsed
5364
5365 \begin_layout Plain Layout
5366 The file 
5367 \begin_inset Flex Code
5368 status collapsed
5369
5370 \begin_layout Plain Layout
5371 development/HTML/HTML.notes
5372 \end_layout
5373
5374 \end_inset
5375
5376 , which can be found in the \SpecialChar LyX
5377  source tree or 
5378 \begin_inset CommandInset href
5379 LatexCommand href
5380 name "accessed online"
5381 target "https://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
5382 literal "false"
5383
5384 \end_inset
5385
5386 , usually contains up-to-date information about the state of XHTML output.
5387  See also the list of XHTML bugs on 
5388 \begin_inset CommandInset href
5389 LatexCommand href
5390 name "the bug tracker"
5391 target "https://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"
5392 literal "false"
5393
5394 \end_inset
5395
5396 .
5397 \end_layout
5398
5399 \end_inset
5400
5401  Still, the developers have chosen this approach because it has several
5402  potential advantages over the other two.
5403 \end_layout
5404
5405 \begin_layout Standard
5406 These advantages are primarily due to the fact that the XHTML output routines,
5407  since they are part of \SpecialChar LyX
5408 , know everything \SpecialChar LyX
5409  knows about the document being
5410  exported.
5411 \begin_inset Foot
5412 status collapsed
5413
5414 \begin_layout Plain Layout
5415 Another advantage is that, since these routines are internal to \SpecialChar LyX
5416 , they are
5417  immune to changes in \SpecialChar LyX
5418 's file format, or to changes in the semantics of
5419  existing insets.
5420 \end_layout
5421
5422 \end_inset
5423
5424  So they know about the table of contents (as displayed in the outline),
5425  about the counters associated with different paragraph styles, and about
5426  user-defined styles.
5427  The XHTML output routines know what \SpecialChar LyX
5428  knows about internationalization,
5429  too, so they will output 
5430 \begin_inset Quotes eld
5431 \end_inset
5432
5433 Chapter 1
5434 \begin_inset Quotes erd
5435 \end_inset
5436
5437  or 
5438 \begin_inset Quotes eld
5439 \end_inset
5440
5441
5442 \lang ngerman
5443 Kapitel
5444 \lang english
5445  1
5446 \begin_inset Quotes erd
5447 \end_inset
5448
5449 , depending upon the language in effect at the time.
5450  
5451 \end_layout
5452
5453 \begin_layout Standard
5454 Quite generally, the output routines know what \SpecialChar LyX
5455  knows about document layout,
5456  that is, about how the document is to be rendered on screen.
5457  We use this information when we output the document as XHTML.
5458  In particular, \SpecialChar LyX
5459  
5460 \emph on
5461 automatically
5462 \emph default
5463  generates CSS style information corresponding to the layout information
5464  it uses to render the document on screen: if section headings are supposed
5465  to be sans-serif and bold as seen in \SpecialChar LyX
5466 , then (by default) they will be sans-seri
5467 f and bold when viewed in a web browser, too.
5468  And this is true not just for pre-defined styles, like Section, but for
5469  any style, including user-defined styles.
5470  Indeed, the XHTML output routines make no distinction between user-defined
5471  paragraph and 
5472 \change_deleted 244031559 1603876931
5473 character
5474 \change_inserted 244031559 1603876940
5475 text
5476 \change_unchanged
5477  styles and \SpecialChar LyX
5478 's own pre-defined styles: in each case, everything \SpecialChar LyX
5479  knows about
5480  the styles is contained in the layout files.
5481  And much the same is true as regards pre-defined textual insets, such as
5482  footnotes, and various custom insets.
5483  
5484 \end_layout
5485
5486 \begin_layout Standard
5487 The result is that XHTML output can be customized and extended in exactly
5488  the same way \SpecialChar LaTeX
5489  output can be customized and extended: through layout files
5490  and modules.
5491  See chapter five of the 
5492 \emph on
5493 Customization 
5494 \emph default
5495 manual for the details.
5496 \end_layout
5497
5498 \begin_layout Standard
5499 The remainder of this chapter contains more detailed information on XHTML
5500  output, its limitations, and ways to work around those limitations.
5501 \end_layout
5502
5503 \begin_layout Section
5504 Math Output in XHTML
5505 \end_layout
5506
5507 \begin_layout Standard
5508 \SpecialChar LyX
5509  offers four choices for how math is rendered.
5510  These have various advantages and disadvantages:
5511 \end_layout
5512
5513 \begin_layout Itemize
5514 MathML
5515 \begin_inset Newline newline
5516 \end_inset
5517
5518 MathML is a dialect of XML designed specifically for mathematics on the
5519  web, and it typically renders very well in browsers that support it.
5520  The disadvantage is that not all browsers support MathML, and support is
5521  not complete even in the Gecko-based browsers, such as Firefox.
5522 \begin_inset Newline newline
5523 \end_inset
5524
5525 If \SpecialChar LyX
5526  is unable to render a formula as MathML—for example, if the formula
5527  uses the 
5528 \begin_inset Flex Code
5529 status collapsed
5530
5531 \begin_layout Plain Layout
5532 xymatrix
5533 \end_layout
5534
5535 \end_inset
5536
5537  package or ERT—then it will instead output the formula as an image.
5538  
5539 \end_layout
5540
5541 \begin_layout Itemize
5542 HTML
5543 \begin_inset Newline newline
5544 \end_inset
5545
5546 As mentioned above, 
5547 \begin_inset Flex Code
5548 status collapsed
5549
5550 \begin_layout Plain Layout
5551 elyxer
5552 \end_layout
5553
5554 \end_inset
5555
5556  outputs math as HTML, styled by CSS.
5557 \begin_inset Foot
5558 status collapsed
5559
5560 \begin_layout Plain Layout
5561 \SpecialChar LyX
5562  has borrowed some of the CSS for its HTML output from 
5563 \begin_inset Flex Code
5564 status collapsed
5565
5566 \begin_layout Plain Layout
5567 elyxer
5568 \end_layout
5569
5570 \end_inset
5571
5572 .
5573 \end_layout
5574
5575 \end_inset
5576
5577  For simple formulae, this can work quite well, though with more complicated
5578  formulae it tends to break down.
5579  Still, this method has the advantage that it is very widely supported and
5580  so it may be appropriate for documents that contain only a little, fairly
5581  simple math.
5582 \begin_inset Newline newline
5583 \end_inset
5584
5585 If Lyx is unable to render a formula as HTML—for example, if the formula
5586  uses the 
5587 \begin_inset Flex Code
5588 status collapsed
5589
5590 \begin_layout Plain Layout
5591 xymatrix
5592 \end_layout
5593
5594 \end_inset
5595
5596  package or ERT—then it will instead output the formula as an image.
5597  
5598 \end_layout
5599
5600 \begin_layout Itemize
5601 Images
5602 \begin_inset Newline newline
5603 \end_inset
5604
5605 Like 
5606 \begin_inset Flex Code
5607 status collapsed
5608
5609 \begin_layout Plain Layout
5610 htlatex
5611 \end_layout
5612
5613 \end_inset
5614
5615 , \SpecialChar LyX
5616  will output formulae as images, the very same images, in fact, that are
5617  used for instant preview.
5618 \begin_inset Foot
5619 status collapsed
5620
5621 \begin_layout Plain Layout
5622 Instant preview does 
5623 \emph on
5624 not 
5625 \emph default
5626 have to be on for images to be output, however.
5627 \end_layout
5628
5629 \end_inset
5630
5631  The advantage to this method is that the images are simply generated by
5632  \SpecialChar LaTeX
5633 , so they are very accurate.
5634  The disadvantage, as mentioned earlier, is that these are bitmapped images,
5635  so they do not scale terribly well, and one cannot copy them, etc.
5636 \begin_inset Newline newline
5637 \end_inset
5638
5639 The size of the images can be controlled by setting the 
5640 \begin_inset Quotes eld
5641 \end_inset
5642
5643 Math Images Scaling
5644 \begin_inset Quotes erd
5645 \end_inset
5646
5647  parameter under 
5648 \begin_inset Flex Noun
5649 status collapsed
5650
5651 \begin_layout Plain Layout
5652 Document\SpecialChar menuseparator
5653 Settings\SpecialChar menuseparator
5654 Formats
5655 \end_layout
5656
5657 \end_inset
5658
5659 .
5660 \begin_inset Foot
5661 status collapsed
5662
5663 \begin_layout Plain Layout
5664 For those who want to know, this controls the resolution of the image in
5665  dots per inch and is based upon a default of 75 dpi.
5666 \end_layout
5667
5668 \end_inset
5669
5670
5671 \begin_inset Newline newline
5672 \end_inset
5673
5674 If \SpecialChar LyX
5675  for some reason fails to create an image for a formula (e.g., if a required
5676  \SpecialChar LaTeX
5677  package is not installed), then it will fall back to outputing the raw
5678  \SpecialChar LaTeX
5679 .
5680 \end_layout
5681
5682 \begin_layout Itemize
5683 \SpecialChar LaTeX
5684
5685 \begin_inset Newline newline
5686 \end_inset
5687
5688 Finally, \SpecialChar LyX
5689  will happily output math as \SpecialChar LaTeX
5690 .
5691  As well as being the output of last resort, this method can be used with
5692  such tools as 
5693 \begin_inset CommandInset href
5694 LatexCommand href
5695 name "jsMath"
5696 target "http://www.math.union.edu/~dpvc/jsMath/"
5697 literal "false"
5698
5699 \end_inset
5700
5701 , which uses JavaScript to render \SpecialChar LaTeX
5702  embedded in HTML documents.
5703  \SpecialChar LyX
5704  wraps the \SpecialChar LaTeX
5705  in either a 
5706 \begin_inset Flex Code
5707 status collapsed
5708
5709 \begin_layout Plain Layout
5710 span
5711 \end_layout
5712
5713 \end_inset
5714
5715  (for inline formulas) or 
5716 \begin_inset Flex Code
5717 status collapsed
5718
5719 \begin_layout Plain Layout
5720 div
5721 \end_layout
5722
5723 \end_inset
5724
5725  (for displayed formulas) with 
5726 \begin_inset Flex Code
5727 status collapsed
5728
5729 \begin_layout Plain Layout
5730 class='math'
5731 \end_layout
5732
5733 \end_inset
5734
5735 , as is required for jsMath.
5736 \end_layout
5737
5738 \begin_layout Standard
5739 One of these output methods must be selected under 
5740 \begin_inset Flex Noun
5741 status collapsed
5742
5743 \begin_layout Plain Layout
5744 Document\SpecialChar menuseparator
5745 Settings\SpecialChar menuseparator
5746 Formats
5747 \end_layout
5748
5749 \end_inset
5750
5751 .
5752  By default, \SpecialChar LyX
5753  outputs MathML.
5754  This is a document-wide setting, therefore.
5755 \end_layout
5756
5757 \begin_layout Standard
5758 Eventually, \SpecialChar LyX
5759  will offer the user the option to select an alternate output
5760  method for a particular inset, say, one that isn't being rendered very
5761  well by MathML.
5762 \begin_inset Foot
5763 status collapsed
5764
5765 \begin_layout Plain Layout
5766 That said, since \SpecialChar LyX
5767  falls back to images if the inset contains ERT, then one
5768  can force output as an image by putting some harmless ERT into the math,
5769  for example: 
5770 \begin_inset Formula $a=b\relax$
5771 \end_inset
5772
5773 .
5774 \end_layout
5775
5776 \end_inset
5777
5778
5779 \end_layout
5780
5781 \begin_layout Section
5782 Bibliography and Citations
5783 \end_layout
5784
5785 \begin_layout Standard
5786 XHTML output fully supports bibliographies and citations.
5787  
5788 \end_layout
5789
5790 \begin_layout Standard
5791 Citation labels are generated by the same machinery that generates \SpecialChar LyX
5792 's on-screen
5793  labels, so the labels will look in the output much as they do in \SpecialChar LyX
5794 , though
5795  better.
5796  If you are using numerical citations, then \SpecialChar LyX
5797  will output numerical labels,
5798  such as [1] or [17], rather than simply showing the citation key in square
5799  brackets, as it does on-screen.
5800  If you are using author-year citations, then \SpecialChar LyX
5801  will add lowercase letters
5802  to the years, just as Bib\SpecialChar TeX
5803  does, if it finds more than one citation for
5804  a given author-year combination.
5805  The labels will be printed with the bibliography entries.
5806  Note that there is, at present, no way to customize the appearance of the
5807  labels, for example, to choose between square brackets and parentheses.
5808 \end_layout
5809
5810 \begin_layout Standard
5811 Bibliography output is handled by the same machinery that handles the presentati
5812 on of reference information in the citation dialog, so you will see in the
5813  XHTML output pretty much what you would see if you were to look at a given
5814  entry in the citation dialog.
5815  The formatting can be customized in your layout file or, preferably, in
5816  a module.
5817  See the 
5818 \emph on
5819 Customization
5820 \emph default
5821  manual for the details.
5822 \end_layout
5823
5824 \begin_layout Standard
5825 The main defect at present is that cross-referenced information is printed
5826  with every entry with which it is associated.
5827  So you can see things like this:
5828 \end_layout
5829
5830 \begin_layout Quote
5831 Jason Stanley, 
5832 \begin_inset Quotes eld
5833 \end_inset
5834
5835 Context and Logical Form
5836 \begin_inset Quotes erd
5837 \end_inset
5838
5839 , in 
5840 \emph on
5841 Language in Context: Selected Essays
5842 \emph default
5843  (Oxford: Oxford University Press, 2007), pp.
5844  30–68.
5845 \end_layout
5846
5847 \begin_layout Quote
5848 Jason Stanley, 
5849 \begin_inset Quotes eld
5850 \end_inset
5851
5852 Semantics in Context
5853 \begin_inset Quotes erd
5854 \end_inset
5855
5856 , in 
5857 \emph on
5858 Language in Context: Selected Essays
5859 \emph default
5860  (Oxford: Oxford University Press, 2007), pp.
5861  201–30.
5862 \end_layout
5863
5864 \begin_layout Standard
5865 This should be fixed before long.
5866 \end_layout
5867
5868 \begin_layout Standard
5869 There is no support at present for sectioned bibliographies.
5870  If you have multiple bibliographies, then \SpecialChar LyX
5871  will print the same bibliography
5872  over and over.
5873 \end_layout
5874
5875 \begin_layout Section
5876 Indexes
5877 \end_layout
5878
5879 \begin_layout Standard
5880 \SpecialChar LyX
5881  will happily export indexes as XHTML, but with certain limitations at the
5882  moment.
5883 \end_layout
5884
5885 \begin_layout Standard
5886 Index export will be most reliable when you do not attempt to use the fancy
5887  constructs that are described in the section on indexes in the 
5888 \emph on
5889 User's Guide
5890 \emph default
5891 .
5892 \begin_inset Foot
5893 status collapsed
5894
5895 \begin_layout Plain Layout
5896 The main issue here is that \SpecialChar LyX
5897  itself does not really handle these.
5898  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
5899 .
5900 \end_layout
5901
5902 \end_inset
5903
5904  We'll describe how they are handled using the subsection headings from
5905  that section.
5906 \end_layout
5907
5908 \begin_layout Itemize
5909 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
5910  makes an effort to support these,
5911  but the entries must be separated by 
5912 \begin_inset Quotes eld
5913 \end_inset
5914
5915  ! 
5916 \begin_inset Quotes erd
5917 \end_inset
5918
5919 , that is, there must be spaces around the exclamation point.
5920  This is because it is otherwise too difficult to check for escaped exclamation
5921  points, ones in math, and so forth.
5922 \end_layout
5923
5924 \begin_layout Itemize
5925 Page Ranges: There is no support at all for page ranges, since these make
5926  no sense with XHMTL.
5927  Instead, you will just get two index entries, one at either end.
5928 \end_layout
5929
5930 \begin_layout Itemize
5931 Cross-referencing: There is no support for cross-referencing.
5932  If \SpecialChar LyX
5933  finds an entry containing the 
5934 \begin_inset Quotes eld
5935 \end_inset
5936
5937 |see\SpecialChar ldots
5938
5939 \begin_inset Quotes erd
5940 \end_inset
5941
5942  construct, it is just dropped, and the rest is treated as an ordinary index
5943  entry.
5944 \end_layout
5945
5946 \begin_layout Itemize
5947 Index Entry Order: \SpecialChar LyX
5948  does support attempts to fix the sorting order.
5949  It will take what is before the first `@' it finds and use that for sorting,
5950  taking what follows the first `@' to be the actual entry.
5951  At present, \SpecialChar LyX
5952  does not check for escaped `@', so do not try to index email
5953  addresses.
5954 \end_layout
5955
5956 \begin_layout Itemize
5957 Index Entry Layout: You can format entries by using the text style dialog,
5958  or by using any other method available within \SpecialChar LyX
5959  itself.
5960  There is no support for constructs like: 
5961 \begin_inset Quotes eld
5962 \end_inset
5963
5964 entry|textbf
5965 \begin_inset Quotes erd
5966 \end_inset
5967
5968 .
5969  Indeed, if \SpecialChar LyX
5970  finds a pipe symbol, `|', in an entry, it will delete it and
5971  everything that follows it.
5972 \end_layout
5973
5974 \begin_layout Itemize
5975 Multiple Indexes: There is no support for multiple indexes.
5976  Rather, all index entries will be printed as one large index.
5977  To avoid our printing several versions of the index, we print only the
5978  main index, so make sure you have one.
5979 \end_layout
5980
5981 \begin_layout Section
5982 Nomenclature and Glossary
5983 \end_layout
5984
5985 \begin_layout Standard
5986 There is at present no support for glossaries.
5987  Adding it would be fairly trivial, and welcome.
5988 \end_layout
5989
5990 \begin_layout Chapter
5991
5992 \change_inserted 1075283030 1616534180
5993 DocBook Output
5994 \end_layout
5995
5996 \begin_layout Standard
5997
5998 \change_inserted 1075283030 1616534386
5999 Apart from HTML, \SpecialChar LyX
6000  can generate documents in the DocBook XML vocabulary.
6001  With versions 2.3 and before, only select templates could be used to generate
6002  DocBook documents (only version 4).
6003  Starting with \SpecialChar LyX
6004  2.4, most \SpecialChar LyX
6005  layouts can generate valid DocBook documents (only
6006  version 5).
6007  This feature is built into \SpecialChar LyX
6008  and does not require the use of external tools.
6009 \end_layout
6010
6011 \begin_layout Standard
6012
6013 \change_inserted 1075283030 1616534437
6014 The result is that the DocBook output can be customized and extended in
6015  exactly the same way \SpecialChar LaTeX
6016  output can be customized and extended: through layout
6017  files and modules.
6018  See chapter five of the 
6019 \emph on
6020 Customization 
6021 \emph default
6022 manual for the details.
6023 \end_layout
6024
6025 \begin_layout Standard
6026
6027 \change_inserted 1075283030 1616534475
6028 Most \SpecialChar LyX
6029  features are supported with DocBook, like math output.
6030 \end_layout
6031
6032 \begin_layout Itemize
6033
6034 \change_inserted 1075283030 1616534741
6035 Math output is performed mostly in MathML (the major exception being constructio
6036 ns not supported by \SpecialChar LyX
6037 , i.e.
6038  ERTs).
6039  All formulae are also available in raw \SpecialChar TeX
6040  in the DocBook output for further
6041  processing.
6042 \end_layout
6043
6044 \begin_layout Itemize
6045
6046 \change_inserted 1075283030 1616534852
6047 Bibliographies and citations are implemented, including with an external
6048  BibTeX file.
6049  Bibliography entries are not prerendered when the detailed information
6050  are available, but rather output with the standard DocBook constructs.
6051  The external DocBook processor is expected to handle the rendering of entries.
6052 \end_layout
6053
6054 \begin_layout Itemize
6055
6056 \change_inserted 1075283030 1616534863
6057 Indexes are supported, including multiple indices.
6058  Grouping (with 
6059 \family typewriter
6060 !
6061 \family default
6062 ), page ranges, and cross-references (
6063 \family typewriter
6064 |see
6065 \family default
6066 ) are supported, with the exception of the same symbols escaped.
6067  Entry order (
6068 \family typewriter
6069 @
6070 \family default
6071 ) and layout (
6072 \family typewriter
6073 |mathbf
6074 \family default
6075 ) are not supported.
6076  There is no support for escaping of index entries.
6077 \end_layout
6078
6079 \begin_layout Itemize
6080
6081 \change_inserted 1075283030 1616534884
6082 Glossaries are implemented.
6083 \end_layout
6084
6085 \begin_layout Standard
6086
6087 \change_inserted 1075283030 1616534894
6088 Two major parameters can be set at the document level.
6089 \end_layout
6090
6091 \begin_layout Itemize
6092
6093 \change_inserted 1075283030 1616534948
6094 Format for tables: \SpecialChar LyX
6095  can generate tables either as HTML (default value) or
6096  CALS, depending on the user's requirements.
6097  Most DocBook processors accept both formats.
6098 \end_layout
6099
6100 \begin_layout Itemize
6101
6102 \change_inserted 1075283030 1616535006
6103 MathML prefix: in DocBook, MathML is included within its own name space,
6104  unlike HTML.
6105  The implication is that there must be an indication of the tags belonging
6106  to the MathML standard.
6107  Three choices are offered: 
6108 \end_layout
6109
6110 \begin_deeper
6111 \begin_layout Itemize
6112
6113 \change_inserted 1075283030 1616535044
6114 Inline: the MathML name space is defined for each formula (using the 
6115 \family typewriter
6116 xmlns
6117 \family default
6118  attribute on each formula)
6119 \end_layout
6120
6121 \begin_layout Itemize
6122
6123 \change_inserted 1075283030 1616535090
6124 With the 
6125 \family typewriter
6126 m
6127 \family default
6128  prefix (default): the MathML name space is defined at the document level
6129  (using the 
6130 \family typewriter
6131 xmlns:m
6132 \family default
6133  attribute on the root element).
6134  Each MathML is prefixed with 
6135 \family typewriter
6136 m
6137 \family default
6138 : for instance, 
6139 \family typewriter
6140 m:math
6141 \end_layout
6142
6143 \begin_layout Itemize
6144
6145 \change_inserted 1075283030 1616620405
6146 With the 
6147 \family typewriter
6148 mml
6149 \family default
6150  prefix: similar to the 
6151 \family typewriter
6152 m
6153 \family default
6154  option, but with 
6155 \family typewriter
6156 mml
6157 \end_layout
6158
6159 \begin_layout Standard
6160
6161 \change_inserted 1075283030 1616620470
6162 This option is especially useful if you want \SpecialChar LyX
6163  to match your personal style
6164  or to work with buggy software that only accepts one prefix for MathML.
6165 \change_unchanged
6166
6167 \end_layout
6168
6169 \end_deeper
6170 \begin_layout Chapter
6171 The \SpecialChar LyX
6172  Server
6173 \end_layout
6174
6175 \begin_layout Section
6176 Introduction
6177 \end_layout
6178
6179 \begin_layout Standard
6180 The `\SpecialChar LyX
6181  server' allows other programs to talk to \SpecialChar LyX
6182 , invoke \SpecialChar LyX
6183  commands, and retrieve
6184  information about the \SpecialChar LyX
6185  internal state.
6186  This is only intended for advanced users, but they should find it useful.
6187  It is by writing to the \SpecialChar LyX
6188  server, for example, that bibliography managers,
6189  such as JabRef, are able to 
6190 \begin_inset Quotes eld
6191 \end_inset
6192
6193 push
6194 \begin_inset Quotes erd
6195 \end_inset
6196
6197  citations to \SpecialChar LyX
6198 .
6199 \end_layout
6200
6201 \begin_layout Section
6202 Starting the \SpecialChar LyX
6203  Server
6204 \begin_inset CommandInset label
6205 LatexCommand label
6206 name "sec:Starting-the-Server"
6207
6208 \end_inset
6209
6210
6211 \end_layout
6212
6213 \begin_layout Standard
6214 The \SpecialChar LyX
6215  server works through the use of a pair of named pipes.
6216  These are usually located in 
6217 \begin_inset Flex Code
6218 status collapsed
6219
6220 \begin_layout Plain Layout
6221 UserDir
6222 \end_layout
6223
6224 \end_inset
6225
6226 , (except on Windows, where 
6227 \emph on
6228 local
6229 \emph default
6230  named pipes are special objects located in 
6231 \begin_inset Flex Code
6232 status collapsed
6233
6234 \begin_layout Plain Layout
6235
6236 \backslash
6237
6238 \backslash
6239 .
6240 \backslash
6241 pipe
6242 \end_layout
6243
6244 \end_inset
6245
6246 ) and have the names 
6247 \begin_inset Quotes eld
6248 \end_inset
6249
6250
6251 \begin_inset Flex Code
6252 status collapsed
6253
6254 \begin_layout Plain Layout
6255 lyxpipe.in
6256 \end_layout
6257
6258 \end_inset
6259
6260
6261 \begin_inset Quotes erd
6262 \end_inset
6263
6264  and 
6265 \begin_inset Quotes eld
6266 \end_inset
6267
6268
6269 \begin_inset Flex Code
6270 status collapsed
6271
6272 \begin_layout Plain Layout
6273 lyxpipe.out
6274 \end_layout
6275
6276 \end_inset
6277
6278
6279 \begin_inset Quotes erd
6280 \end_inset
6281
6282 .
6283  External programs write into 
6284 \begin_inset Flex Code
6285 status collapsed
6286
6287 \begin_layout Plain Layout
6288 lyxpipe.in
6289 \end_layout
6290
6291 \end_inset
6292
6293  and read back data from 
6294 \begin_inset Flex Code
6295 status collapsed
6296
6297 \begin_layout Plain Layout
6298 lyxpipe.out
6299 \end_layout
6300
6301 \end_inset
6302
6303 .
6304  The stem of the pipe names can be defined in the 
6305 \begin_inset Flex Noun
6306 status collapsed
6307
6308 \begin_layout Plain Layout
6309 Tools\SpecialChar menuseparator
6310 Preferences
6311 \end_layout
6312
6313 \end_inset
6314
6315  dialog, for example 
6316 \begin_inset Flex Code
6317 status collapsed
6318
6319 \begin_layout Plain Layout
6320 "/home/myhome/lyxpipe"
6321 \end_layout
6322
6323 \end_inset
6324
6325 , or 
6326 \begin_inset Flex Code
6327 status collapsed
6328
6329 \begin_layout Plain Layout
6330 "
6331 \backslash
6332
6333 \backslash
6334 .
6335 \backslash
6336 pipe
6337 \backslash
6338 lyxpipe"
6339 \end_layout
6340
6341 \end_inset
6342
6343  on Windows (where any working path instead of lyxpipe can be used, for
6344  example 
6345 \begin_inset Flex Code
6346 status collapsed
6347
6348 \begin_layout Plain Layout
6349 "
6350 \backslash
6351
6352 \backslash
6353 .
6354 \backslash
6355 pipe
6356 \backslash
6357 my
6358 \backslash
6359 lyx
6360 \backslash
6361 pipe"
6362 \end_layout
6363
6364 \end_inset
6365
6366  would also work).
6367  You 
6368 \emph on
6369 must
6370 \emph default
6371  configure this manually in order for the server to start.
6372 \end_layout
6373
6374 \begin_layout Standard
6375 \SpecialChar LyX
6376  will add the '
6377 \begin_inset Flex Code
6378 status collapsed
6379
6380 \begin_layout Plain Layout
6381 .in
6382 \end_layout
6383
6384 \end_inset
6385
6386 ' and '
6387 \begin_inset Flex Code
6388 status collapsed
6389
6390 \begin_layout Plain Layout
6391 .out
6392 \end_layout
6393
6394 \end_inset
6395
6396 ' to create the pipes.
6397  If one of the pipes already exists, \SpecialChar LyX
6398  will assume that another \SpecialChar LyX
6399  process
6400  is already running and will not start the server.
6401  On POSIX (Unix like) systems, if for some other reason, an unused 
6402 \begin_inset Quotes eld
6403 \end_inset
6404
6405 stale
6406 \begin_inset Quotes erd
6407 \end_inset
6408
6409  pipe is left in existence when \SpecialChar LyX
6410  closes, then \SpecialChar LyX
6411  will try to delete it.
6412  If this fails for some reason, you will need to delete the pipes manually
6413  and then restart \SpecialChar LyX
6414 .
6415  On Windows, pipes are deleted by the OS on program termination or crash,
6416  so 
6417 \begin_inset Quotes eld
6418 \end_inset
6419
6420 stale
6421 \begin_inset Quotes erd
6422 \end_inset
6423
6424  pipes should not be possible.
6425 \end_layout
6426
6427 \begin_layout Standard
6428 To have several \SpecialChar LyX
6429  processes with servers at the same time, you have to use
6430  different configurations, perhaps by using separate user directories, each
6431  with its own 
6432 \begin_inset Flex Code
6433 status collapsed
6434
6435 \begin_layout Plain Layout
6436 preferences
6437 \end_layout
6438
6439 \end_inset
6440
6441  file, for each process.
6442 \end_layout
6443
6444 \begin_layout Standard
6445 If you are developing a client program, you might find it useful to enable
6446  debugging information from the \SpecialChar LyX
6447  server.
6448  Do this by starting \SpecialChar LyX
6449  as 
6450 \begin_inset Flex Code
6451 status collapsed
6452
6453 \begin_layout Plain Layout
6454 lyx -dbg lyxserver
6455 \end_layout
6456
6457 \end_inset
6458
6459 .
6460 \end_layout
6461
6462 \begin_layout Standard
6463 You can find a complete example client written in C++ in the source distribution
6464  as 
6465 \begin_inset Flex Code
6466 status collapsed
6467
6468 \begin_layout Plain Layout
6469 development/lyxserver/server_monitor.cpp
6470 \end_layout
6471
6472 \end_inset
6473
6474 .
6475 \end_layout
6476
6477 \begin_layout Standard
6478 Another useful tool is the command-line based client found in 
6479 \begin_inset Flex Code
6480 status collapsed
6481
6482 \begin_layout Plain Layout
6483 src/client/lyxclient
6484 \end_layout
6485
6486 \end_inset
6487
6488 .
6489 \end_layout
6490
6491 \begin_layout Section
6492 Normal communication
6493 \end_layout
6494
6495 \begin_layout Standard
6496 To issue a \SpecialChar LyX
6497  call, the client writes a line of ASCII text into the input
6498  pipe.
6499  This line has the following format:
6500 \end_layout
6501
6502 \begin_layout Quote
6503 LYXCMD:
6504 \emph on
6505 clientname
6506 \emph default
6507 :
6508 \emph on
6509 function
6510 \emph default
6511 :
6512 \emph on
6513 argument
6514 \end_layout
6515
6516 \begin_layout Description
6517 clientname is a name that the client can choose arbitrarily.
6518  Its only use is that \SpecialChar LyX
6519  will echo it if it sends an answer—so a client can
6520  dispatch results from different requesters.
6521 \end_layout
6522
6523 \begin_layout Description
6524 function is the function you want \SpecialChar LyX
6525  to perform.
6526  It is the same as the commands you'd use in the minibuffer.
6527 \end_layout
6528
6529 \begin_layout Description
6530 argument is an optional argument which is meaningful only to some functions
6531  (for instance, the 
6532 \begin_inset Quotes eld
6533 \end_inset
6534
6535 self-insert
6536 \begin_inset Quotes erd
6537 \end_inset
6538
6539  LFUN will insert the argument as text at the cursor position).
6540 \end_layout
6541
6542 \begin_layout Standard
6543 The answer from \SpecialChar LyX
6544  will arrive in the output pipe and be of the form
6545 \end_layout
6546
6547 \begin_layout Quote
6548 INFO:
6549 \emph on
6550 clientname
6551 \emph default
6552 :
6553 \emph on
6554 function
6555 \emph default
6556 :
6557 \emph on
6558 data
6559 \end_layout
6560
6561 \begin_layout Standard
6562 where 
6563 \emph on
6564 clientname
6565 \emph default
6566  and 
6567 \emph on
6568 function
6569 \emph default
6570  are just echoed from the command request, while 
6571 \emph on
6572 data
6573 \emph default
6574  is more or less useful information filled according to how the command
6575  execution worked out.
6576  Some commands, such as 
6577 \begin_inset Quotes eld
6578 \end_inset
6579
6580 font-state
6581 \begin_inset Quotes erd
6582 \end_inset
6583
6584 , will return information about the internal state of \SpecialChar LyX
6585 , while other will
6586  return an empty data-response.
6587  This means that the command execution went fine.
6588 \end_layout
6589
6590 \begin_layout Standard
6591 In case of errors, the response from \SpecialChar LyX
6592  will have this form
6593 \end_layout
6594
6595 \begin_layout Quote
6596 ERROR:
6597 \emph on
6598 clientname
6599 \emph default
6600 :
6601 \emph on
6602 function
6603 \emph default
6604 :
6605 \emph on
6606 error message
6607 \end_layout
6608
6609 \begin_layout Standard
6610 where the 
6611 \emph on
6612 error message
6613 \emph default
6614  should contain an explanation of why the command failed.
6615 \end_layout
6616
6617 \begin_layout Standard
6618 Examples:
6619 \end_layout
6620
6621 \begin_layout LyX-Code
6622 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
6623 \begin_inset Newline newline
6624 \end_inset
6625
6626 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
6627 \begin_inset Newline newline
6628 \end_inset
6629
6630 read a <~/.lyxpipe.out
6631 \begin_inset Newline newline
6632 \end_inset
6633
6634 echo $a
6635 \end_layout
6636
6637 \begin_layout Subsection
6638 AppleScript (Mac OS X)
6639 \end_layout
6640
6641 \begin_layout Standard
6642 Since \SpecialChar LyX
6643  2.1, \SpecialChar LyX
6644  supports basic interactions with AppleScript for normal communicatio
6645 n through the command run.
6646  This command takes a direct argument (the 
6647 \series bold
6648 function
6649 \series default
6650  to perform) and an optional argument.
6651  It either returns the output of the function or triggers an error with
6652  the error message and code.
6653 \end_layout
6654
6655 \begin_layout Standard
6656 Example:
6657 \end_layout
6658
6659 \begin_layout LyX-Code
6660 tell application "\SpecialChar LyX
6661 "
6662 \end_layout
6663
6664 \begin_layout LyX-Code
6665   try
6666 \end_layout
6667
6668 \begin_layout LyX-Code
6669     -- Stores the current file name into f
6670 \end_layout
6671
6672 \begin_layout LyX-Code
6673     set f to (run "server-get-filename" with argument "")
6674 \end_layout
6675
6676 \begin_layout LyX-Code
6677     on error the error_message number the error_number
6678 \end_layout
6679
6680 \begin_layout LyX-Code
6681       display dialog "Error: " & the error_number & ".
6682  " ¬
6683 \end_layout
6684
6685 \begin_layout LyX-Code
6686               & the error_message buttons {"OK"} default button 1
6687 \end_layout
6688
6689 \begin_layout LyX-Code
6690   end try
6691 \end_layout
6692
6693 \begin_layout LyX-Code
6694 end tell
6695 \end_layout
6696
6697 \begin_layout Section
6698 Notification
6699 \end_layout
6700
6701 \begin_layout Standard
6702 \SpecialChar LyX
6703  can notify clients of events going on asynchronously.
6704  Currently it will only do this if the user binds a key sequence with the
6705  function 
6706 \begin_inset Quotes eld
6707 \end_inset
6708
6709 notify
6710 \begin_inset Quotes erd
6711 \end_inset
6712
6713 .
6714  The format of the string \SpecialChar LyX
6715  sends is as follows:
6716 \end_layout
6717
6718 \begin_layout Quote
6719 \begin_inset Flex Code
6720 status collapsed
6721
6722 \begin_layout Plain Layout
6723 NOTIFY:
6724 \end_layout
6725
6726 \end_inset
6727
6728
6729 \emph on
6730 key-sequence
6731 \end_layout
6732
6733 \begin_layout Standard
6734 where 
6735 \emph on
6736 key-sequence
6737 \emph default
6738  is the printed representation of the key sequence that was actually typed
6739  by the user.
6740 \end_layout
6741
6742 \begin_layout Standard
6743 This mechanism can be used to extend \SpecialChar LyX
6744 's command set and implement macros.
6745  Bind some key sequence to 
6746 \begin_inset Quotes eld
6747 \end_inset
6748
6749 notify
6750 \begin_inset Quotes erd
6751 \end_inset
6752
6753 .
6754  Then start a client that listens on the output pipe, dispatches the command
6755  according to the sequence, and starts a function that may use \SpecialChar LyX
6756  calls and
6757  \SpecialChar LyX
6758  requests to issue a command or a series of commands to \SpecialChar LyX
6759 .
6760 \end_layout
6761
6762 \begin_layout Section
6763 The simple \SpecialChar LyX
6764  Server Protocol
6765 \end_layout
6766
6767 \begin_layout Standard
6768 \SpecialChar LyX
6769  implements a simple protocol that can be used for session management.
6770  All messages are of the form
6771 \end_layout
6772
6773 \begin_layout Quote
6774 LYXSRV:
6775 \emph on
6776 clientname
6777 \emph default
6778 :
6779 \emph on
6780 protocol message
6781 \end_layout
6782
6783 \begin_layout Standard
6784 where 
6785 \emph on
6786 protocol message
6787 \emph default
6788  can be 
6789 \begin_inset Quotes eld
6790 \end_inset
6791
6792 hello
6793 \begin_inset Quotes erd
6794 \end_inset
6795
6796  or 
6797 \begin_inset Quotes eld
6798 \end_inset
6799
6800 bye
6801 \begin_inset Quotes erd
6802 \end_inset
6803
6804 .
6805  If 
6806 \begin_inset Quotes eld
6807 \end_inset
6808
6809 hello
6810 \begin_inset Quotes erd
6811 \end_inset
6812
6813  is received from a client, \SpecialChar LyX
6814  will report back to inform the client that
6815  it's listening to it's messages, while 
6816 \begin_inset Quotes eld
6817 \end_inset
6818
6819 bye
6820 \begin_inset Quotes erd
6821 \end_inset
6822
6823  sent from \SpecialChar LyX
6824  will inform clients that \SpecialChar LyX
6825  is closing.
6826 \end_layout
6827
6828 \begin_layout Section
6829 Reverse DVI/PDF search
6830 \end_layout
6831
6832 \begin_layout Standard
6833 Some DVI/PDF viewers
6834 \begin_inset Foot
6835 status collapsed
6836
6837 \begin_layout Plain Layout
6838 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
6839  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
6840 \end_layout
6841
6842 \end_inset
6843
6844  provide 
6845 \emph on
6846 reverse search
6847 \emph default
6848  facility (also called 
6849 \emph on
6850 inverse search
6851 \emph default
6852 ).
6853  This means that you can tell \SpecialChar LyX
6854  to put the cursor to a specific line in the
6855  document by clicking at the respective position in the DVI/PDF output.
6856  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
6857 .
6858  This is done via the \SpecialChar LyX
6859  server either by using the named pipe (
6860 \emph on
6861 lyxpipe
6862 \emph default
6863 ), or the UNIX domain socket (
6864 \emph on
6865 lyxsocket
6866 \emph default
6867 ) that \SpecialChar LyX
6868  creates in its temporary directory (this is the way the 
6869 \begin_inset Flex Code
6870 status collapsed
6871
6872 \begin_layout Plain Layout
6873 lyxclient
6874 \end_layout
6875
6876 \end_inset
6877
6878  program communicates with \SpecialChar LyX
6879 ).
6880  In some cases, you need a helper script that mediates between the viewer
6881  and \SpecialChar LyX
6882 , in others, the viewer can communicate with \SpecialChar LyX
6883  directly.
6884  This depends on the selected viewer and on your operating system.
6885  The same applies to the way viewers need to be configured and the way the
6886  reverse search is actually performed.
6887  In what follows, we will thus describe how to setup reverse search for
6888  specific viewers.
6889  Before we turn to this, though, we will explain what needs to be done generally
6890  to enable reverse search in the DVI/PDF output.
6891 \end_layout
6892
6893 \begin_layout Subsection
6894 Automatic setup
6895 \begin_inset CommandInset label
6896 LatexCommand label
6897 name "subsec:rev-search"
6898
6899 \end_inset
6900
6901
6902 \end_layout
6903
6904 \begin_layout Standard
6905 In most cases \SpecialChar LyX
6906  will do the work for you by pressing the following button
6907  in the toolbar: 
6908 \begin_inset Info
6909 type  "icon"
6910 arg   "buffer-toggle-output-sync"
6911 \end_inset
6912
6913 .
6914  Alternatively, you can also enable the feature by checking 
6915 \family sans
6916 Synchronize with Output
6917 \family default
6918  in 
6919 \begin_inset Flex Noun
6920 status collapsed
6921
6922 \begin_layout Plain Layout
6923 Document\SpecialChar menuseparator
6924 Settings\SpecialChar menuseparator
6925 Formats
6926 \end_layout
6927
6928 \end_inset
6929
6930 .
6931  In such a case \SpecialChar LyX
6932  will automatically insert the necessary Sync\SpecialChar TeX
6933  macro (for
6934  PDF) or load the srcltx package (for DVI) respectively.
6935  This option can be easily reached also on 
6936 \begin_inset Flex Code
6937 status collapsed
6938
6939 \begin_layout Plain Layout
6940 View/Update
6941 \end_layout
6942
6943 \end_inset
6944
6945  Toolbar.
6946 \end_layout
6947
6948 \begin_layout Standard
6949 If you need a different setting, you can select or input a custom macro
6950  from the drop down box just below 
6951 \begin_inset Flex Noun
6952 status collapsed
6953
6954 \begin_layout Plain Layout
6955 Document\SpecialChar menuseparator
6956 Settings\SpecialChar menuseparator
6957 Output\SpecialChar menuseparator
6958 Synchronize with Output
6959 \end_layout
6960
6961 \end_inset
6962
6963 .
6964 \end_layout
6965
6966 \begin_layout Standard
6967 Note that the method 
6968 \begin_inset Flex Code
6969 status collapsed
6970
6971 \begin_layout Plain Layout
6972
6973 \backslash
6974 synctex=1
6975 \end_layout
6976
6977 \end_inset
6978
6979  enables gzip compression.
6980  If your viewer does not support it, you should instead use 
6981 \begin_inset Flex Code
6982 status collapsed
6983
6984 \begin_layout Plain Layout
6985
6986 \backslash
6987 synctex=-1
6988 \end_layout
6989
6990 \end_inset
6991
6992 .
6993 \end_layout
6994
6995 \begin_layout Standard
6996 Please also note that including the 
6997 \begin_inset Flex Code
6998 status collapsed
6999
7000 \begin_layout Plain Layout
7001 srcltx
7002 \end_layout
7003
7004 \end_inset
7005
7006  package or 
7007 \begin_inset Flex Code
7008 status collapsed
7009
7010 \begin_layout Plain Layout
7011 src-specials
7012 \end_layout
7013
7014 \end_inset
7015
7016  sometimes has an undesired impact on the typesetting.
7017  Thus, you should switch output synchronization off for the final typesetting
7018  if you use the 
7019 \begin_inset Flex Code
7020 status collapsed
7021
7022 \begin_layout Plain Layout
7023 srcltx
7024 \end_layout
7025
7026 \end_inset
7027
7028  package or 
7029 \begin_inset Flex Code
7030 status collapsed
7031
7032 \begin_layout Plain Layout
7033 src-specials
7034 \end_layout
7035
7036 \end_inset
7037
7038 .
7039  
7040 \end_layout
7041
7042 \begin_layout Standard
7043 In case you need some more special settings that are not covered by the
7044  automatic settings, read the next section about how to set up output synchroniz
7045 ation manually.
7046  If the automatic setup suits your needs, you can readily jump to section
7047 \begin_inset space ~
7048 \end_inset
7049
7050
7051 \begin_inset CommandInset ref
7052 LatexCommand ref
7053 reference "subsec:configuring-viewers"
7054
7055 \end_inset
7056
7057 , where the necessary configuration steps in your viewer – needed both with
7058  the automatic and the manual setup – are described.
7059 \end_layout
7060
7061 \begin_layout Subsection
7062 Manual setup
7063 \end_layout
7064
7065 \begin_layout Standard
7066 \SpecialChar LaTeX
7067  provides several different methods for reverse search.
7068  Some are built-in in the 
7069 \begin_inset Flex Code
7070 status collapsed
7071
7072 \begin_layout Plain Layout
7073 latex/pdflatex
7074 \end_layout
7075
7076 \end_inset
7077
7078  program, some are provided by external packages.
7079  Your choice depends on whether your \SpecialChar LaTeX
7080  distribution already provides a given
7081  method (the built-in methods are rather new) and whether your viewer can
7082  cope with it.
7083  The available methods are described in the following.
7084 \end_layout
7085
7086 \begin_layout Subsubsection*
7087 Built-in DVI-search via src-specials (DVI only) 
7088 \end_layout
7089
7090 \begin_layout Standard
7091 This method provides the DVI file with the necessary information for reverse
7092  search.
7093  It is available in \SpecialChar LaTeX
7094  since quite some time (any somewhat recent \SpecialChar LaTeX
7095  distribution
7096  should include it), and it works reliably.
7097  To enable it, change the 
7098 \begin_inset Flex Noun
7099 status collapsed
7100
7101 \begin_layout Plain Layout
7102 La
7103 \family sans
7104 TeX
7105 \family default
7106  (plain)->DVI
7107 \end_layout
7108
7109 \end_inset
7110
7111  or 
7112 \begin_inset Flex Noun
7113 status collapsed
7114
7115 \begin_layout Plain Layout
7116 La
7117 \family sans
7118 TeX
7119 \family default
7120  (plain)->DraftDVI
7121 \end_layout
7122
7123 \end_inset
7124
7125  converter in 
7126 \begin_inset Flex Noun
7127 status collapsed
7128
7129 \begin_layout Plain Layout
7130 Preferences\SpecialChar menuseparator
7131 File Handling\SpecialChar menuseparator
7132 Converters
7133 \end_layout
7134
7135 \end_inset
7136
7137  to 
7138 \begin_inset Flex Code
7139 status collapsed
7140
7141 \begin_layout Plain Layout
7142 latex -src-specials $$i
7143 \end_layout
7144
7145 \end_inset
7146
7147 .
7148  If this doesn't work, check if your \SpecialChar TeX
7149  engine needs different options (the
7150  syntax might differ in some distributions).
7151 \end_layout
7152
7153 \begin_layout Subsubsection*
7154 External Packages (PDFSync and scrltx) 
7155 \end_layout
7156
7157 \begin_layout Standard
7158 The packages 
7159 \emph on
7160 pdfsync
7161 \emph default
7162  and 
7163 \emph on
7164 scrltx
7165 \emph default
7166  provide reverse search facility for PDF output (via pdflatex) and DVI output,
7167  respectively.
7168  In order to enable it, load the packages in the \SpecialChar LyX
7169  preamble: 
7170 \end_layout
7171
7172 \begin_layout Itemize
7173 \begin_inset Flex Code
7174 status collapsed
7175
7176 \begin_layout Plain Layout
7177
7178 \backslash
7179 usepackage{pdfsync}
7180 \end_layout
7181
7182 \end_inset
7183
7184  for reverse PDF search,
7185 \end_layout
7186
7187 \begin_layout Itemize
7188 \begin_inset Flex Code
7189 status collapsed
7190
7191 \begin_layout Plain Layout
7192
7193 \backslash
7194 usepackage[active]{srcltx}
7195 \end_layout
7196
7197 \end_inset
7198
7199  for reverse DVI search.
7200 \end_layout
7201
7202 \begin_layout Standard
7203 If you want to be able to perform both DVI and PDF reverse searches, you
7204  can also insert in the preamble the following lines
7205 \end_layout
7206
7207 \begin_layout LyX-Code
7208
7209 \backslash
7210 usepackage{ifpdf}
7211 \begin_inset Newline newline
7212 \end_inset
7213
7214
7215 \backslash
7216 ifpdf
7217 \begin_inset Newline newline
7218 \end_inset
7219
7220   
7221 \backslash
7222 usepackage{pdfsync}
7223 \begin_inset Newline newline
7224 \end_inset
7225
7226
7227 \backslash
7228 else
7229 \begin_inset Newline newline
7230 \end_inset
7231
7232   
7233 \backslash
7234 usepackage[active]{srcltx}
7235 \begin_inset Newline newline
7236 \end_inset
7237
7238
7239 \backslash
7240 fi
7241 \end_layout
7242
7243 \begin_layout Standard
7244 This way, you can preview the file as either DVI or PDF (pdflatex) and the
7245  right package will be used.
7246 \end_layout
7247
7248 \begin_layout Standard
7249 Note that PDFSync might affect the output layout of your document.
7250  It is therefore advised to disable PDFsync for final documents.
7251 \end_layout
7252
7253 \begin_layout Subsubsection*
7254 Built-in reverse search via Sync\SpecialChar TeX
7255  (DVI and PDF) 
7256 \end_layout
7257
7258 \begin_layout Standard
7259 Recent versions of 
7260 \begin_inset Flex Code
7261 status collapsed
7262
7263 \begin_layout Plain Layout
7264 (pdf)latex
7265 \end_layout
7266
7267 \end_inset
7268
7269  have built-in support for both PDF and DVI reverse search.
7270  This so-called 
7271 \emph on
7272 Sync\SpecialChar TeX
7273
7274 \emph default
7275  facility is basically the result of the integration of the PDFSync package
7276  to the pdftex program and its merge with the 
7277 \emph on
7278 scr-specials
7279 \emph default
7280  approach.
7281  You need at least \SpecialChar TeX
7282 Live 2008 or a recent Mik\SpecialChar TeX
7283  distribution in order to use
7284  it.
7285 \begin_inset Foot
7286 status collapsed
7287
7288 \begin_layout Plain Layout
7289 For some reason, Mik\SpecialChar TeX
7290  does not understand/obey the command \SpecialChar LyX
7291  inserts into
7292  the preamble when you check the "Enable Forward/Reverse Search" button
7293  in the toolbar and does not generate the necessary info.
7294 \end_layout
7295
7296 \begin_layout Plain Layout
7297 The generation of the required info can be forced by changing the converter
7298  "\SpecialChar LaTeX
7299  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
7300  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
7301  the -synctex=1 switch).
7302 \end_layout
7303
7304 \end_inset
7305
7306  Also note that only a few PDF viewers (such as Okular and Qpdfview on Unix,
7307  Skim on the Mac, SumatraPDF on Windows; see the next section for details)
7308  already provide Sync\SpecialChar TeX
7309  support.
7310 \end_layout
7311
7312 \begin_layout Standard
7313 To enable Sync\SpecialChar TeX
7314  for DVI output, change the 
7315 \begin_inset Flex Noun
7316 status collapsed
7317
7318 \begin_layout Plain Layout
7319 La
7320 \family sans
7321 TeX
7322 \family default
7323  (plain) -> DVI
7324 \end_layout
7325
7326 \end_inset
7327
7328  or 
7329 \begin_inset Flex Noun
7330 status collapsed
7331
7332 \begin_layout Plain Layout
7333 La
7334 \family sans
7335 TeX
7336 \family default
7337  (plain) -> DraftDVI
7338 \end_layout
7339
7340 \end_inset
7341
7342  converter in 
7343 \begin_inset Flex Noun
7344 status collapsed
7345
7346 \begin_layout Plain Layout
7347 Preferences\SpecialChar menuseparator
7348 File Handling\SpecialChar menuseparator
7349 Converters
7350 \end_layout
7351
7352 \end_inset
7353
7354  to 
7355 \begin_inset Flex Code
7356 status collapsed
7357
7358 \begin_layout Plain Layout
7359 latex -synctex=1 $$i
7360 \end_layout
7361
7362 \end_inset
7363
7364 , and for PDF output, change the 
7365 \begin_inset Flex Noun
7366 status collapsed
7367
7368 \begin_layout Plain Layout
7369 La
7370 \family sans
7371 TeX
7372 \family default
7373  (pdflatex) -> PDF (pdflatex)
7374 \end_layout
7375
7376 \end_inset
7377
7378  converter to 
7379 \begin_inset Flex Code
7380 status collapsed
7381
7382 \begin_layout Plain Layout
7383 pdflatex -synctex=1 $$i
7384 \end_layout
7385
7386 \end_inset
7387
7388 .
7389  Should your viewer not be considered in the following description, or in
7390  case of missing success, please check the documentation of your viewer
7391  whether the viewer needs to be configured for the use with Sync\SpecialChar TeX
7392 .
7393 \begin_inset Foot
7394 status collapsed
7395
7396 \begin_layout Plain Layout
7397 Note that the option 
7398 \begin_inset Flex Code
7399 status collapsed
7400
7401 \begin_layout Plain Layout
7402 -synctex=1
7403 \end_layout
7404
7405 \end_inset
7406
7407  option enables gzip compression.
7408  If your viewer does not support it, you should instead use 
7409 \begin_inset Flex Code
7410 status collapsed
7411
7412 \begin_layout Plain Layout
7413 -synctex=-1
7414 \end_layout
7415
7416 \end_inset
7417
7418 .
7419 \end_layout
7420
7421 \end_inset
7422
7423
7424 \end_layout
7425
7426 \begin_layout Subsection
7427 Configuring and using specific viewers
7428 \begin_inset CommandInset label
7429 LatexCommand label
7430 name "subsec:configuring-viewers"
7431
7432 \end_inset
7433
7434
7435 \end_layout
7436
7437 \begin_layout Subsubsection*
7438 Xdvi (all platforms)
7439 \end_layout
7440
7441 \begin_layout Standard
7442 If you use 
7443 \begin_inset Flex Code
7444 status collapsed
7445
7446 \begin_layout Plain Layout
7447 xdvi
7448 \end_layout
7449
7450 \end_inset
7451
7452 , you don't need to do anything else for performing a reverse DVI search,
7453  as \SpecialChar LyX
7454  already provides the necessary hooks for automatically using the 
7455 \begin_inset Flex Code
7456 status collapsed
7457
7458 \begin_layout Plain Layout
7459 lyxclient
7460 \end_layout
7461
7462 \end_inset
7463
7464  program.
7465  Just setup your document as described above (reverse search is triggered
7466  by Ctrl-click or Alt-click on Mac OSX, respectively).
7467 \end_layout
7468
7469 \begin_layout Standard
7470 However, if for whatever reason you want to use the named pipe instead of
7471  the socket for communicating with \SpecialChar LyX
7472 , simply change the DVI viewer in 
7473 \begin_inset Flex Noun
7474 status collapsed
7475
7476 \begin_layout Plain Layout
7477 Preferences\SpecialChar menuseparator
7478 File Handling\SpecialChar menuseparator
7479 File formats
7480 \end_layout
7481
7482 \end_inset
7483
7484  to
7485 \begin_inset Foot
7486 status collapsed
7487
7488 \begin_layout Plain Layout
7489 On Mac OSX you have to use 
7490 \begin_inset Flex Code
7491 status collapsed
7492
7493 \begin_layout Plain Layout
7494 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
7495 \end_layout
7496
7497 \end_inset
7498
7499
7500 \end_layout
7501
7502 \end_inset
7503
7504  
7505 \begin_inset Flex Code
7506 status collapsed
7507
7508 \begin_layout Plain Layout
7509 xdvi -editor "lyxeditor.sh %f %l"
7510 \end_layout
7511
7512 \end_inset
7513
7514 , where 
7515 \begin_inset Flex Code
7516 status collapsed
7517
7518 \begin_layout Plain Layout
7519 lyxeditor.sh
7520 \end_layout
7521
7522 \end_inset
7523
7524  is a suitable script.
7525  For example, a minimal shell script is the following one:
7526 \end_layout
7527
7528 \begin_layout LyX-Code
7529 #!/bin/sh
7530 \begin_inset Newline newline
7531 \end_inset
7532
7533 LYXPIPE="/path/to/lyxpipe"
7534 \begin_inset Newline newline
7535 \end_inset
7536
7537 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
7538 \begin_inset Newline newline
7539 \end_inset
7540
7541 echo "$COMMAND" > "${LYXPIPE}".in || exit
7542 \begin_inset Newline newline
7543 \end_inset
7544
7545 read TMP < "${LYXPIPE}".out || exit
7546 \end_layout
7547
7548 \begin_layout Standard
7549 where 
7550 \begin_inset Flex Code
7551 status collapsed
7552
7553 \begin_layout Plain Layout
7554 /path/to/lyxpipe
7555 \end_layout
7556
7557 \end_inset
7558
7559  is the LyXServer pipe path specified in 
7560 \begin_inset Flex Noun
7561 status collapsed
7562
7563 \begin_layout Plain Layout
7564 Preferences\SpecialChar menuseparator
7565 Paths
7566 \end_layout
7567
7568 \end_inset
7569
7570 .
7571 \begin_inset Foot
7572 status collapsed
7573
7574 \begin_layout Plain Layout
7575 In the 
7576 \begin_inset Flex Code
7577 status collapsed
7578
7579 \begin_layout Plain Layout
7580 development/tools
7581 \end_layout
7582
7583 \end_inset
7584
7585  folder of a source distribution you can find a 
7586 \begin_inset Flex Code
7587 status collapsed
7588
7589 \begin_layout Plain Layout
7590 lyxeditor
7591 \end_layout
7592
7593 \end_inset
7594
7595  script which is able to locate the 
7596 \emph on
7597 lyxpipe
7598 \emph default
7599  based on your preferences.
7600 \end_layout
7601
7602 \end_inset
7603
7604
7605 \end_layout
7606
7607 \begin_layout Subsubsection*
7608 MacDviX (Mac OSX)
7609 \end_layout
7610
7611 \begin_layout Standard
7612 At the end of 
7613 \begin_inset Flex Code
7614 status collapsed
7615
7616 \begin_layout Plain Layout
7617 /Applications/MacDviX_Folder/calleditor.script
7618 \end_layout
7619
7620 \end_inset
7621
7622 , add the following lines:
7623 \end_layout
7624
7625 \begin_layout LyX-Code
7626 /Applications/LyX.app/Contents/MacOS/lyxeditor "$2" $1
7627 \begin_inset Newline newline
7628 \end_inset
7629
7630 exit 1
7631 \end_layout
7632
7633 \begin_layout Standard
7634 Modify the lines accordingly if you install \SpecialChar LyX
7635  somewhere else than in the
7636  Applications folder.
7637 \end_layout
7638
7639 \begin_layout Standard
7640 Reverse search is triggered by Alt-click (OPTION-click).
7641 \end_layout
7642
7643 \begin_layout Subsubsection*
7644 Skim (Mac OSX)
7645 \end_layout
7646
7647 \begin_layout Standard
7648 Enter 
7649 \begin_inset Flex Code
7650 status collapsed
7651
7652 \begin_layout Plain Layout
7653 open -a Skim.app $$i
7654 \end_layout
7655
7656 \end_inset
7657
7658  to the viewer setting in 
7659 \begin_inset Flex Noun
7660 status collapsed
7661
7662 \begin_layout Plain Layout
7663 Preferences\SpecialChar menuseparator
7664 File Handling\SpecialChar menuseparator
7665 File formats\SpecialChar menuseparator
7666 PDF (pdflatex)
7667 \end_layout
7668
7669 \end_inset
7670
7671 , and then in 
7672 \begin_inset Flex Noun
7673 status collapsed
7674
7675 \begin_layout Plain Layout
7676 Skim\SpecialChar menuseparator
7677 Preferences\SpecialChar menuseparator
7678 Sync
7679 \end_layout
7680
7681 \end_inset
7682
7683  choose 
7684 \begin_inset Flex Noun
7685 status collapsed
7686
7687 \begin_layout Plain Layout
7688 custom
7689 \end_layout
7690
7691 \end_inset
7692
7693  preset and enter command 
7694 \begin_inset Flex Noun
7695 status collapsed
7696
7697 \begin_layout Plain Layout
7698 /Applications/\SpecialChar LyX
7699 .app/Contents/MacOS/lyxeditor
7700 \end_layout
7701
7702 \end_inset
7703
7704 .
7705 \end_layout
7706
7707 \begin_layout Standard
7708 Reverse search is triggered by COMMAND-SHIFT-click
7709 \end_layout
7710
7711 \begin_layout Subsubsection*
7712 Evince (GNOME)
7713 \end_layout
7714
7715 \begin_layout Standard
7716 Reverse search with evince does not work out of the box, but it can be achieved
7717  by means of some third party helper scripts.
7718  Please refer to 
7719 \begin_inset CommandInset href
7720 LatexCommand href
7721 target "https://wiki.lyx.org/LyX/SyncTeX"
7722 literal "false"
7723
7724 \end_inset
7725
7726  for details.
7727 \end_layout
7728
7729 \begin_layout Subsubsection*
7730 Okular (KDE)
7731 \end_layout
7732
7733 \begin_layout Standard
7734 Go to 
7735 \begin_inset Flex Noun
7736 status collapsed
7737
7738 \begin_layout Plain Layout
7739 Settings\SpecialChar menuseparator
7740 Configure Okular\SpecialChar menuseparator
7741 Editor
7742 \end_layout
7743
7744 \end_inset
7745
7746  and select LyX
7747 \begin_inset Quotes erd
7748 \end_inset
7749
7750  as editor.
7751  This inserts the appropriate command (
7752 \begin_inset Flex Code
7753 status collapsed
7754
7755 \begin_layout Plain Layout
7756 lyxclient -g %f %l
7757 \end_layout
7758
7759 \end_inset
7760
7761 ).
7762 \end_layout
7763
7764 \begin_layout Standard
7765 Reverse search is triggered by SHIFT-click.
7766
7767 \change_inserted -712698321 1578211026
7768  Note that this only works if Okular is in 
7769 \begin_inset Quotes eld
7770 \end_inset
7771
7772 Browse
7773 \begin_inset Quotes erd
7774 \end_inset
7775
7776  mode (i.
7777 \begin_inset space \thinspace{}
7778 \end_inset
7779
7780 e., the hand symbol is clicked).
7781 \change_unchanged
7782
7783 \end_layout
7784
7785 \begin_layout Subsubsection*
7786 Qpdfview (Unix)
7787 \end_layout
7788
7789 \begin_layout Standard
7790 Qpdfview supports Sync\SpecialChar TeX
7791  since version 0.3.5.
7792  Go to 
7793 \begin_inset Flex Noun
7794 status collapsed
7795
7796 \begin_layout Plain Layout
7797 Edit\SpecialChar menuseparator
7798 Settings\SpecialChar menuseparator
7799 Behavior
7800 \end_layout
7801
7802 \end_inset
7803
7804 , click on the input field of the 
7805 \begin_inset Quotes eld
7806 \end_inset
7807
7808 Source editor
7809 \begin_inset Quotes erd
7810 \end_inset
7811
7812  item and add the command 
7813 \begin_inset Flex Code
7814 status collapsed
7815
7816 \begin_layout Plain Layout
7817 lyxclient -g %1 %2
7818 \end_layout
7819
7820 \end_inset
7821
7822 .
7823 \end_layout
7824
7825 \begin_layout Standard
7826 Reverse search is triggered by double-click or, in more recent versions,
7827  by context menu.
7828 \end_layout
7829
7830 \begin_layout Subsubsection*
7831 YAP (Windows)
7832 \end_layout
7833
7834 \begin_layout Standard
7835 Launch yap, choose its 
7836 \begin_inset Flex Noun
7837 status collapsed
7838
7839 \begin_layout Plain Layout
7840 View\SpecialChar menuseparator
7841 Options
7842 \end_layout
7843
7844 \end_inset
7845
7846  menu and select the 
7847 \begin_inset Quotes eld
7848 \end_inset
7849
7850 Inverse DVI Search
7851 \begin_inset Quotes erd
7852 \end_inset
7853
7854  tab.
7855  Click on the 
7856 \begin_inset Quotes eld
7857 \end_inset
7858
7859 New\SpecialChar ldots
7860
7861 \begin_inset Quotes erd
7862 \end_inset
7863
7864  button and, in the window that opens, enter 
7865 \begin_inset Quotes eld
7866 \end_inset
7867
7868 \SpecialChar LyX
7869  Editor
7870 \begin_inset Quotes erd
7871 \end_inset
7872
7873  (or any other name you like) in the 
7874 \begin_inset Quotes eld
7875 \end_inset
7876
7877 Name:
7878 \begin_inset Quotes erd
7879 \end_inset
7880
7881  field.
7882  Now click on the button labeled 
7883 \begin_inset Quotes eld
7884 \end_inset
7885
7886 \SpecialChar ldots
7887
7888 \begin_inset Quotes erd
7889 \end_inset
7890
7891  to open a file dialog and navigate to the directory containing the batch
7892  file 
7893 \begin_inset Flex Code
7894 status collapsed
7895
7896 \begin_layout Plain Layout
7897 lyxeditor.bat
7898 \end_layout
7899
7900 \end_inset
7901
7902  (see below).
7903  Select 
7904 \begin_inset Flex Code
7905 status collapsed
7906
7907 \begin_layout Plain Layout
7908 lyxeditor.bat
7909 \end_layout
7910
7911 \end_inset
7912
7913  and then specify the program arguments as 
7914 \begin_inset Flex Code
7915 status collapsed
7916
7917 \begin_layout Plain Layout
7918 %f %l
7919 \end_layout
7920
7921 \end_inset
7922
7923 .
7924  The 
7925 \begin_inset Flex Code
7926 status collapsed
7927
7928 \begin_layout Plain Layout
7929 lyxeditor.bat
7930 \end_layout
7931
7932 \end_inset
7933
7934  wrapper is used for communicating with \SpecialChar LyX
7935  through the 
7936 \emph on
7937 lyxpipe
7938 \emph default
7939  and is as follows:
7940 \end_layout
7941
7942 \begin_layout LyX-Code
7943 @echo off
7944 \begin_inset Newline newline
7945 \end_inset
7946
7947 echo LYXCMD:revdvi:server-goto-file-row:%~1 %2> 
7948 \backslash
7949
7950 \backslash
7951 .
7952 \backslash
7953 pipe
7954 \backslash
7955 lyxpipe.in
7956 \begin_inset Newline newline
7957 \end_inset
7958
7959 type 
7960 \backslash
7961
7962 \backslash
7963 .
7964 \backslash
7965 pipe
7966 \backslash
7967 lyxpipe.out
7968 \end_layout
7969
7970 \begin_layout Standard
7971 Make sure that the \SpecialChar LyX
7972 Server pipe path you specified in \SpecialChar LyX
7973  is 
7974 \begin_inset Flex Code
7975 status collapsed
7976
7977 \begin_layout Plain Layout
7978
7979 \backslash
7980
7981 \backslash
7982 .
7983 \backslash
7984 pipe
7985 \backslash
7986 lyxpipe
7987 \end_layout
7988
7989 \end_inset
7990
7991 , otherwise change the 
7992 \begin_inset Flex Code
7993 status collapsed
7994
7995 \begin_layout Plain Layout
7996 lyxeditor.bat
7997 \end_layout
7998
7999 \end_inset
8000
8001  wrapper accordingly.
8002 \end_layout
8003
8004 \begin_layout Standard
8005 In yap, reverse search is triggered by double-click.
8006 \end_layout
8007
8008 \begin_layout Subsubsection*
8009 SumatraPDF (Windows)
8010 \end_layout
8011
8012 \begin_layout Standard
8013 In order to use SumatraPDF for inverse search, enter 
8014 \begin_inset Flex Code
8015 status collapsed
8016
8017 \begin_layout Plain Layout
8018 SumatraPDF -inverse-search "lyxeditor.bat "%f" %l"
8019 \end_layout
8020
8021 \end_inset
8022
8023  in the viewer setting in 
8024 \begin_inset Flex Noun
8025 status collapsed
8026
8027 \begin_layout Plain Layout
8028 Preferences\SpecialChar menuseparator
8029 File Handling\SpecialChar menuseparator
8030 File formats\SpecialChar menuseparator
8031 PDF (pdflatex)
8032 \end_layout
8033
8034 \end_inset
8035
8036 , where 
8037 \begin_inset Flex Code
8038 status collapsed
8039
8040 \begin_layout Plain Layout
8041 lyxeditor.bat
8042 \end_layout
8043
8044 \end_inset
8045
8046  is the previous wrapper.
8047  If SumatraPDF.exe is not in your command PATH, use its full file name.
8048 \end_layout
8049
8050 \begin_layout Standard
8051 Reverse search is triggered by double-click.
8052 \end_layout
8053
8054 \begin_layout Subsubsection*
8055 YAP (Cygwin)
8056 \end_layout
8057
8058 \begin_layout Standard
8059 First of all, make sure that yap is your default DVI viewer in the Windows
8060  environment, then launch it, choose its 
8061 \begin_inset Flex Noun
8062 status collapsed
8063
8064 \begin_layout Plain Layout
8065 View\SpecialChar menuseparator
8066 Options
8067 \end_layout
8068
8069 \end_inset
8070
8071  menu and select the 
8072 \begin_inset Quotes eld
8073 \end_inset
8074
8075 Inverse DVI Search
8076 \begin_inset Quotes erd
8077 \end_inset
8078
8079  tab.
8080  Click on the 
8081 \begin_inset Quotes eld
8082 \end_inset
8083
8084 New\SpecialChar ldots
8085
8086 \begin_inset Quotes erd
8087 \end_inset
8088
8089  button and, in the window that opens, enter 
8090 \begin_inset Quotes eld
8091 \end_inset
8092
8093 \SpecialChar LyX
8094  Editor
8095 \begin_inset Quotes erd
8096 \end_inset
8097
8098  (or any other name you like) in the 
8099 \begin_inset Quotes eld
8100 \end_inset
8101
8102 Name:
8103 \begin_inset Quotes erd
8104 \end_inset
8105
8106  field.
8107  Now click on the button labeled 
8108 \begin_inset Quotes eld
8109 \end_inset
8110
8111 \SpecialChar ldots
8112
8113 \begin_inset Quotes erd
8114 \end_inset
8115
8116  to open a file dialog and navigate to the directory containing the 
8117 \begin_inset Flex Code
8118 status collapsed
8119
8120 \begin_layout Plain Layout
8121 lyxeditor.exe
8122 \end_layout
8123
8124 \end_inset
8125
8126  program (which is installed by default on Cygwin along with the \SpecialChar LyX
8127  executable).
8128  Select 
8129 \begin_inset Flex Code
8130 status collapsed
8131
8132 \begin_layout Plain Layout
8133 lyxeditor.exe
8134 \end_layout
8135
8136 \end_inset
8137
8138  and then specify the program arguments as 
8139 \begin_inset Flex Code
8140 status collapsed
8141
8142 \begin_layout Plain Layout
8143 -g %f %l
8144 \end_layout
8145
8146 \end_inset
8147
8148 .
8149  In this way, you will be using the 
8150 \emph on
8151 lyxsocket
8152 \emph default
8153  for communicating with \SpecialChar LyX
8154 .
8155  If, for whatever reason, you want to use the 
8156 \emph on
8157 lyxpipe
8158 \emph default
8159 , omit the 
8160 \begin_inset Flex Code
8161 status collapsed
8162
8163 \begin_layout Plain Layout
8164 -g
8165 \end_layout
8166
8167 \end_inset
8168
8169  option and be sure to specify the \SpecialChar LyX
8170 Server pipe path in the \SpecialChar LyX
8171  preferences.
8172 \end_layout
8173
8174 \begin_layout Standard
8175 In yap, reverse search is triggered by double-click.
8176 \end_layout
8177
8178 \begin_layout Subsubsection*
8179 SumatraPDF (Cygwin)
8180 \end_layout
8181
8182 \begin_layout Standard
8183 In order to use SumatraPDF for inverse search, enter 
8184 \begin_inset Flex Code
8185 status collapsed
8186
8187 \begin_layout Plain Layout
8188 SumatraPDF -inverse-search "lyxeditor -g %f %l"
8189 \end_layout
8190
8191 \end_inset
8192
8193  in the viewer setting in 
8194 \begin_inset Flex Noun
8195 status collapsed
8196
8197 \begin_layout Plain Layout
8198 Preferences\SpecialChar menuseparator
8199 File Handling\SpecialChar menuseparator
8200 File formats\SpecialChar menuseparator
8201 PDF (pdflatex)
8202 \end_layout
8203
8204 \end_inset
8205
8206 .
8207  If SumatraPDF.exe is not in your command PATH, use its full posix path.
8208  The 
8209 \begin_inset Flex Code
8210 status collapsed
8211
8212 \begin_layout Plain Layout
8213 -g
8214 \end_layout
8215
8216 \end_inset
8217
8218  enables communication via the 
8219 \emph on
8220 lyxsocket
8221 \emph default
8222 .
8223  Again, omit the 
8224 \begin_inset Flex Code
8225 status collapsed
8226
8227 \begin_layout Plain Layout
8228 -g
8229 \end_layout
8230
8231 \end_inset
8232
8233  option if you want to use the 
8234 \emph on
8235 lyxpipe
8236 \emph default
8237 , and be sure to specify the \SpecialChar LyX
8238 Server pipe path in the \SpecialChar LyX
8239  preferences.
8240 \end_layout
8241
8242 \begin_layout Standard
8243 Reverse search is triggered by double-click.
8244 \end_layout
8245
8246 \begin_layout Section
8247 Forward search
8248 \end_layout
8249
8250 \begin_layout Standard
8251 Forward search is, as the name implies, in a sense the 
8252 \begin_inset Quotes eld
8253 \end_inset
8254
8255 opposite
8256 \begin_inset Quotes erd
8257 \end_inset
8258
8259  of reverse search.
8260  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
8261 .
8262  If forward search is set up (as described in what follows), you can put
8263  the cursor anywhere in your \SpecialChar LyX
8264  document, and hit 
8265 \begin_inset Flex Noun
8266 status collapsed
8267
8268 \begin_layout Plain Layout
8269 Navigate\SpecialChar menuseparator
8270 Forward search
8271 \end_layout
8272
8273 \end_inset
8274
8275  (or select 
8276 \begin_inset Flex Noun
8277 status collapsed
8278
8279 \begin_layout Plain Layout
8280 Forward search
8281 \end_layout
8282
8283 \end_inset
8284
8285  in the context menu via right mouse click), and then the viewer will jump
8286  to that position as well.
8287  This implies, of course, that your viewer supports this function.
8288 \end_layout
8289
8290 \begin_layout Standard
8291 To make forward search possible, you first need to provide the generated
8292  output PDF/DVI file with additional information about the \SpecialChar TeX
8293  sources.
8294  This can be done via the methods described in the section 
8295 \begin_inset CommandInset ref
8296 LatexCommand ref
8297 reference "subsec:rev-search"
8298
8299 \end_inset
8300
8301 .
8302 \end_layout
8303
8304 \begin_layout Standard
8305 Additionally, you need to configure \SpecialChar LyX
8306  for using your viewers in 
8307 \begin_inset Flex Noun
8308 status collapsed
8309
8310 \begin_layout Plain Layout
8311 Tools\SpecialChar menuseparator
8312 Preferences\SpecialChar menuseparator
8313 Output\SpecialChar menuseparator
8314 General
8315 \end_layout
8316
8317 \end_inset
8318
8319 .
8320  We provide a range of tested configurations for some viewers, which you
8321  can select from the drop down list.
8322  If none of these configurations suits you, you have to find out and enter
8323  a suitable configuration yourself.
8324  The definition syntax uses the following placeholders:
8325 \end_layout
8326
8327 \begin_layout Itemize
8328 \noindent
8329 \begin_inset Flex Code
8330 status collapsed
8331
8332 \begin_layout Plain Layout
8333 $$n
8334 \end_layout
8335
8336 \end_inset
8337
8338 : row number
8339 \end_layout
8340
8341 \begin_layout Itemize
8342 \noindent
8343 \begin_inset Flex Code
8344 status collapsed
8345
8346 \begin_layout Plain Layout
8347 $$t
8348 \end_layout
8349
8350 \end_inset
8351
8352 : name of the (temporary) exported .tex file (without path)
8353 \end_layout
8354
8355 \begin_layout Itemize
8356 \noindent
8357 \begin_inset Flex Code
8358 status collapsed
8359
8360 \begin_layout Plain Layout
8361 $$f
8362 \end_layout
8363
8364 \end_inset
8365
8366 : name of the (temporary) exported .tex file (including path)
8367 \end_layout
8368
8369 \begin_layout Itemize
8370 \noindent
8371 \begin_inset Flex Code
8372 status collapsed
8373
8374 \begin_layout Plain Layout
8375 $$o
8376 \end_layout
8377
8378 \end_inset
8379
8380 : name of the exported output file (either dvi or pdf, depending on which
8381  one exists in the temporary directory)
8382 \end_layout
8383
8384 \begin_layout Standard
8385 Note that only some of the viewers provide full and usable forward search
8386  functionality out of the box, among them yap, xdvi, okular
8387 \begin_inset Foot
8388 status collapsed
8389
8390 \begin_layout Plain Layout
8391 You might want to set 
8392 \begin_inset Flex Code
8393 status collapsed
8394
8395 \begin_layout Plain Layout
8396 okular --unique
8397 \end_layout
8398
8399 \end_inset
8400
8401  in 
8402 \begin_inset Flex Noun
8403 status collapsed
8404
8405 \begin_layout Plain Layout
8406 Tools\SpecialChar menuseparator
8407 Preferences\SpecialChar menuseparator
8408 File Handling\SpecialChar menuseparator
8409 File
8410 \begin_inset space ~
8411 \end_inset
8412
8413 Formats
8414 \end_layout
8415
8416 \end_inset
8417
8418
8419 \end_layout
8420
8421 \end_inset
8422
8423 , qpdfview, and SumatraPDF
8424 \begin_inset Foot
8425 status collapsed
8426
8427 \begin_layout Plain Layout
8428 SumatraPDF can also use DDE commands through the external program CMCDDE
8429  — downloadable from 
8430 \begin_inset CommandInset href
8431 LatexCommand href
8432 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
8433 literal "false"
8434
8435 \end_inset
8436
8437
8438 \end_layout
8439
8440 \end_inset
8441
8442 .
8443  Others, such as evince
8444 \begin_inset Foot
8445 status collapsed
8446
8447 \begin_layout Plain Layout
8448 Forward search with evince can be achieved by means of third party helper
8449  scripts.
8450  Please refer to 
8451 \begin_inset CommandInset href
8452 LatexCommand href
8453 target "https://wiki.lyx.org/LyX/SyncTeX"
8454 literal "false"
8455
8456 \end_inset
8457
8458  for details.
8459 \end_layout
8460
8461 \end_inset
8462
8463 , require some extra tools in order to use forward search.
8464  While many of the widespread PDF viewers (most notably Adobe Reader) do
8465  not support forward search at all, some other viewers – e.
8466 \begin_inset space \thinspace{}
8467 \end_inset
8468
8469 g.
8470  xpdf – allow at least to reload the document and jump to a specific page
8471  of the file, so you can at least navigate 
8472 \begin_inset Quotes eld
8473 \end_inset
8474
8475 near
8476 \begin_inset Quotes erd
8477 \end_inset
8478
8479 .
8480  This latter functionality is provided by an external call of synctex (see
8481  the predefined example configurations).
8482  
8483 \end_layout
8484
8485 \begin_layout Standard
8486 Forward search works both with DVI and PDF output.
8487  \SpecialChar LyX
8488  simply checks which preview format you have used before (i.
8489 \begin_inset space \thinspace{}
8490 \end_inset
8491
8492 e., which format is already there in the temporary directory) and chooses
8493  the appropriate configuration for the respective format.
8494 \end_layout
8495
8496 \begin_layout Chapter
8497 Special Document Classes
8498 \end_layout
8499
8500 \begin_layout Section
8501 A&A Paper
8502 \end_layout
8503
8504 \begin_layout Standard
8505 by 
8506 \noun on
8507 Peter Sütterlin
8508 \end_layout
8509
8510 \begin_layout Subsection
8511 Introduction
8512 \end_layout
8513
8514 \begin_layout Standard
8515 This section describes how \SpecialChar LyX
8516  can be used to write articles for submission
8517  to the scientific journal 
8518 \emph on
8519 Astronomy and Astrophysics
8520 \emph default
8521  (
8522 \begin_inset Flex URL
8523 status collapsed
8524
8525 \begin_layout Plain Layout
8526
8527 https://www.aanda.org/
8528 \end_layout
8529
8530 \end_inset
8531
8532 ) using Version 5.01 of the document class 
8533 \family typewriter
8534 aa.cls
8535 \family default
8536 .
8537  This package can be downloaded from the ftp site
8538 \end_layout
8539
8540 \begin_layout Standard
8541 \begin_inset VSpace medskip
8542 \end_inset
8543
8544
8545 \end_layout
8546
8547 \begin_layout Standard
8548 \align center
8549 \begin_inset Flex URL
8550 status collapsed
8551
8552 \begin_layout Plain Layout
8553
8554 ftp://ftp.edpsciences.org/pub/aa/readme.html
8555 \end_layout
8556
8557 \end_inset
8558
8559
8560 \end_layout
8561
8562 \begin_layout Standard
8563 \begin_inset VSpace medskip
8564 \end_inset
8565
8566
8567 \end_layout
8568
8569 \begin_layout Standard
8570 A manual comes together with that package, and this text is not meant to
8571  replace the original manual but is merely a short guide in how to realize
8572  the correct form of your paper.
8573  
8574 \end_layout
8575
8576 \begin_layout Standard
8577 Please note that the publisher of the journal was changed from Springer
8578  to EDP Sciences starting January 1, 2001.
8579  That change involved also some slight changes to the style files, namely
8580  the removal of the thesaurus command.
8581  The \SpecialChar LyX
8582  class aa supports the newest version of these style files, V 5.01.
8583  If you have an older version installed, please upgrade.
8584  For compatibility, the old (version 4) layout has been kept as 
8585 \family sans
8586 article (A&A V4)
8587 \family default
8588 .
8589  Please refer to the comments in 
8590 \family typewriter
8591 \SpecialChar LyX
8592 Dir/layouts/aapaper.layout
8593 \family default
8594 .
8595 \end_layout
8596
8597 \begin_layout Subsection
8598 Getting started
8599 \end_layout
8600
8601 \begin_layout Standard
8602 It is recommended you start from the example template distributed with \SpecialChar LyX
8603 .
8604  If you are not using a template, note the following settings:
8605 \end_layout
8606
8607 \begin_layout Itemize
8608 Select 
8609 \family sans
8610 article (A&A)
8611 \family default
8612  in the 
8613 \family sans
8614 Document\SpecialChar menuseparator
8615 Settings
8616 \family default
8617  dialog (OK, that one was obvious).
8618 \end_layout
8619
8620 \begin_layout Itemize
8621 Don't change the option 
8622 \family sans
8623 Page
8624 \begin_inset space ~
8625 \end_inset
8626
8627 style
8628 \family default
8629 : Leave it set to 
8630 \family sans
8631 default
8632 \family default
8633 .
8634  The whole layout is done by the macros, you shouldn't change anything.
8635 \end_layout
8636
8637 \begin_layout Subsection
8638 The header block
8639 \end_layout
8640
8641 \begin_layout Standard
8642 First thing to enter is the header information.
8643  It consists of seven entries, of which some are optional.
8644  They are
8645 \end_layout
8646
8647 \begin_layout Itemize
8648
8649 \family sans
8650 Title
8651 \family default
8652 : [required] 
8653 \end_layout
8654
8655 \begin_layout Itemize
8656
8657 \family sans
8658 Subtitle
8659 \family default
8660 : [optional] 
8661 \end_layout
8662
8663 \begin_layout Itemize
8664
8665 \family sans
8666 Author
8667 \family default
8668 : [required]
8669 \end_layout
8670
8671 \begin_layout Itemize
8672
8673 \family sans
8674 Address
8675 \family default
8676 : [required]
8677 \end_layout
8678
8679 \begin_layout Itemize
8680
8681 \family sans
8682 Offprints
8683 \family default
8684 : [optional] if more than one author: whom to contact for offprint requests.
8685 \end_layout
8686
8687 \begin_layout Itemize
8688
8689 \family sans
8690 Mail
8691 \family default
8692 : [optional] mail address for contacts.
8693 \end_layout
8694
8695 \begin_layout Itemize
8696
8697 \family sans
8698 Date
8699 \family default
8700 : [required].
8701  Suggested format is 
8702 \family typewriter
8703 Received: <date>; Accepted <date> 
8704 \end_layout
8705
8706 \begin_layout Standard
8707 There is no need to issue the 
8708 \family typewriter
8709
8710 \backslash
8711 maketitle
8712 \family default
8713  command, this is done automatically by \SpecialChar LyX
8714  when the header is finished.
8715  Although the order of the single header entries doesn't matter it is advised
8716  to keep the above sequence, just to get the best optics and meets the layout
8717  of the real document.
8718 \end_layout
8719
8720 \begin_layout Standard
8721 If you want to place footnotes in the header block, e.
8722 \begin_inset space \thinspace{}
8723 \end_inset
8724
8725 g.
8726 \begin_inset space \space{}
8727 \end_inset
8728
8729 to state your present address, just use the standard footnote via the menu
8730  
8731 \family sans
8732 Insert\SpecialChar menuseparator
8733 Footnote.
8734
8735 \family default
8736  \SpecialChar LyX
8737  will automagically use the term 
8738 \family typewriter
8739
8740 \backslash
8741 thanks{}
8742 \family default
8743  in that case.
8744 \end_layout
8745
8746 \begin_layout Standard
8747 Under 
8748 \family sans
8749 Edit\SpecialChar menuseparator
8750 Text Style
8751 \family default
8752 , you'll find two insets which are relevant for the titling:
8753 \end_layout
8754
8755 \begin_layout Itemize
8756
8757 \family sans
8758 Institute
8759 \family typewriter
8760  
8761 \family default
8762 to mark corresponding author\SpecialChar breakableslash
8763 institute pairs.
8764  The institutes are numbered sequentially as they appear in the 
8765 \family sans
8766 Address
8767 \family default
8768  field, so you have to put a marker to each author.
8769 \end_layout
8770
8771 \begin_layout Itemize
8772
8773 \family sans
8774 Email
8775 \family default
8776  to supply an email address for fast contact.
8777 \end_layout
8778
8779 \begin_layout Standard
8780 In addition to these topics, the macros use one additional \SpecialChar LaTeX
8781  command that
8782  has no counterpart in \SpecialChar LyX
8783 :
8784 \end_layout
8785
8786 \begin_layout Itemize
8787
8788 \family typewriter
8789
8790 \backslash
8791 and
8792 \family default
8793  to separate different names for more than one author and institute, respectivel
8794 y.
8795 \end_layout
8796
8797 \begin_layout Standard
8798 The appropriate command has to be entered in \SpecialChar LyX
8799  and marked as \SpecialChar LaTeX
8800  code.
8801  See the examples.
8802  
8803 \end_layout
8804
8805 \begin_layout Subsection
8806 The abstract
8807 \end_layout
8808
8809 \begin_layout Standard
8810 The abstract should immediately follow the header block.
8811  With version 5 the abstract environment was changed to a command, and there
8812  is now a restriction to only one paragraph.
8813  In addition, it should contain an entry with the keywords.
8814  This is done via the paragraph style 
8815 \family sans
8816 Keywords
8817 \family default
8818 .
8819  Refer to the example paper.
8820 \end_layout
8821
8822 \begin_layout Subsection
8823 Supported environments
8824 \end_layout
8825
8826 \begin_layout Standard
8827 The A&A paper layout supports the following environments for structuring
8828  your text:
8829 \end_layout
8830
8831 \begin_layout Itemize
8832
8833 \family sans
8834 Standard
8835 \end_layout
8836
8837 \begin_layout Itemize
8838
8839 \family sans
8840 Section
8841 \end_layout
8842
8843 \begin_layout Itemize
8844
8845 \family sans
8846 Subsection
8847 \end_layout
8848
8849 \begin_layout Itemize
8850
8851 \family sans
8852 Subsubsection
8853 \end_layout
8854
8855 \begin_layout Itemize
8856
8857 \family sans
8858 Itemize
8859 \end_layout
8860
8861 \begin_layout Itemize
8862
8863 \family sans
8864 Enumerate
8865 \end_layout
8866
8867 \begin_layout Itemize
8868
8869 \family sans
8870 Description
8871 \end_layout
8872
8873 \begin_layout Itemize
8874
8875 \family sans
8876 Caption
8877 \end_layout
8878
8879 \begin_layout Itemize
8880
8881 \family sans
8882 Abstract
8883 \end_layout
8884
8885 \begin_layout Itemize
8886
8887 \family sans
8888 Acknowledgment
8889 \end_layout
8890
8891 \begin_layout Itemize
8892
8893 \family sans
8894 Bibliography
8895 \end_layout
8896
8897 \begin_layout Itemize
8898
8899 \family sans
8900 \SpecialChar LaTeX
8901
8902 \end_layout
8903
8904 \begin_layout Subsection
8905 Commands not supported by \SpecialChar LyX
8906
8907 \end_layout
8908
8909 \begin_layout Standard
8910 Some commands are not yet supported by the 
8911 \family sans
8912 paper (A&A)
8913 \family default
8914  layout for \SpecialChar LyX
8915 .
8916  Some have already been mentioned.
8917  For the sake of completeness, they are listed all together here:
8918 \end_layout
8919
8920 \begin_layout Itemize
8921
8922 \family typewriter
8923
8924 \backslash
8925 and
8926 \end_layout
8927
8928 \begin_layout Itemize
8929
8930 \family typewriter
8931
8932 \backslash
8933 authorrunning
8934 \end_layout
8935
8936 \begin_layout Itemize
8937
8938 \family typewriter
8939
8940 \backslash
8941 object{}
8942 \end_layout
8943
8944 \begin_layout Itemize
8945
8946 \family typewriter
8947
8948 \backslash
8949 titlerunning{}
8950 \end_layout
8951
8952 \begin_layout Standard
8953 If you want to use any of these commands, you have to enter them yourself.
8954  
8955 \series bold
8956 Do not forget to mark them as \SpecialChar LaTeX
8957  code!
8958 \end_layout
8959
8960 \begin_layout Subsection
8961 Figure and Table Floats
8962 \end_layout
8963
8964 \begin_layout Standard
8965 \SpecialChar LyX
8966  provides support for the necessary float environments 
8967 \family sans
8968 figure, figure*, table
8969 \family default
8970  and 
8971 \family sans
8972 table*
8973 \family default
8974 , therefore we won't tell much about it here.
8975  Refer to the 
8976 \emph on
8977 User's
8978 \begin_inset space ~
8979 \end_inset
8980
8981 Guide
8982 \emph default
8983 .
8984  Just remember that tables should be left-aligned.
8985  For that, select the table and change the alignment in 
8986 \family sans
8987 Edit\SpecialChar menuseparator
8988 Paragraph
8989 \begin_inset space ~
8990 \end_inset
8991
8992 Settings.
8993 \end_layout
8994
8995 \begin_layout Standard
8996 There is only one special thing: the figures with caption besides the figure.
8997  To create such a figure, you have to do the following:
8998 \end_layout
8999
9000 \begin_layout Enumerate
9001 Create a wide figure float: 
9002 \family sans
9003 Insert\SpecialChar menuseparator
9004 Float\SpecialChar menuseparator
9005 Figure
9006 \family default
9007 , then right click in the figure and select 
9008 \family sans
9009 Span
9010 \begin_inset space ~
9011 \end_inset
9012
9013 columns
9014 \family default
9015 .
9016 \end_layout
9017
9018 \begin_layout Enumerate
9019 Enter your caption text.
9020 \end_layout
9021
9022 \begin_layout Enumerate
9023 Press 
9024 \family sans
9025 Return
9026 \family default
9027  to move the cursor above the caption.
9028 \end_layout
9029
9030 \begin_layout Enumerate
9031 Insert your figure
9032 \end_layout
9033
9034 \begin_layout Enumerate
9035 Position the cursor behind the figure and insert a horizontal fill: 
9036 \family sans
9037 Insert\SpecialChar menuseparator
9038 Special
9039 \begin_inset space ~
9040 \end_inset
9041
9042 Character\SpecialChar menuseparator
9043 Horizontal
9044 \begin_inset space ~
9045 \end_inset
9046
9047 Fill
9048 \family default
9049 .
9050 \end_layout
9051
9052 \begin_layout Enumerate
9053 Switch to \SpecialChar LaTeX
9054  mode: 
9055 \family sans
9056 M-c
9057 \begin_inset space ~
9058 \end_inset
9059
9060 t
9061 \family default
9062 .
9063 \end_layout
9064
9065 \begin_layout Enumerate
9066 Enter 
9067 \family typewriter
9068
9069 \backslash
9070 parbox[b]{55mm}{
9071 \family default
9072 .
9073  
9074 \series bold
9075 Do not close the brace!
9076 \end_layout
9077
9078 \begin_layout Enumerate
9079 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
9080  mode and insert
9081  the closing brace: 
9082 \family sans
9083 M-c
9084 \begin_inset space ~
9085 \end_inset
9086
9087 t
9088 \family default
9089  
9090 \family typewriter
9091 }
9092 \family default
9093 .
9094 \end_layout
9095
9096 \begin_layout Standard
9097 Also, refer to the figures in the example paper.
9098 \end_layout
9099
9100 \begin_layout Subsection
9101 Referee layout
9102 \end_layout
9103
9104 \begin_layout Standard
9105 For submission, the paper has to be formated in a special double-spacing
9106  layout.
9107  For this purpose, you have to give the option 
9108 \family typewriter
9109 referee
9110 \family default
9111  to the document class.
9112  This must be done using the custom class options field in the 
9113 \family sans
9114 Document\SpecialChar menuseparator
9115 Settings
9116 \family default
9117  dialog.
9118  Just enter the string 
9119 \family typewriter
9120 referee
9121 \family default
9122  there.
9123 \end_layout
9124
9125 \begin_layout Subsection
9126 The example paper
9127 \end_layout
9128
9129 \begin_layout Standard
9130 The 
9131 \family sans
9132 Examples
9133 \family default
9134  directory contains an example paper written with \SpecialChar LyX
9135 .
9136  It is the example paper from the original macro package, translated to
9137  \SpecialChar LyX
9138 .
9139  Use it for inspiration, and compare the original \SpecialChar LaTeX
9140  code with \SpecialChar LyX
9141  way of writing.
9142 \end_layout
9143
9144 \begin_layout Section
9145 AAS\SpecialChar TeX
9146
9147 \end_layout
9148
9149 \begin_layout Standard
9150 by 
9151 \noun on
9152 Mike Ressler
9153 \end_layout
9154
9155 \begin_layout Subsection
9156 Introduction
9157 \end_layout
9158
9159 \begin_layout Standard
9160 AAS\SpecialChar TeX
9161  is a set of macros produced by the American Astronomical Society to
9162  facilitate electronic manuscript submission to the three journals they
9163  publish: the Astrophysical Journal (including the Letters and Supplement),
9164  the Astronomical Journal, and the Publications of the Astronomical Society
9165  of the Pacific.
9166  \SpecialChar LyX
9167  has proven to be an excellent tool for generating these documents, especially
9168  given its equation, citation, and figure handling capabilities.
9169  \SpecialChar LyX
9170  requires version 5.0 (or higher) of these macros; preferably 6.0, which
9171  is the version described here, or higher.
9172  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
9173 2.09 and are fundamentally
9174  incompatible with \SpecialChar LyX
9175 .
9176  The AAS\SpecialChar TeX
9177  package may be downloaded from the AAS\SpecialChar TeX
9178  Web site
9179 \end_layout
9180
9181 \begin_layout Standard
9182 \begin_inset VSpace medskip
9183 \end_inset
9184
9185
9186 \end_layout
9187
9188 \begin_layout Standard
9189 \align center
9190 \begin_inset Flex URL
9191 status collapsed
9192
9193 \begin_layout Plain Layout
9194
9195 https://aas.org/aastex/aastex-downloads
9196 \end_layout
9197
9198 \end_inset
9199
9200
9201 \end_layout
9202
9203 \begin_layout Standard
9204 \begin_inset VSpace medskip
9205 \end_inset
9206
9207
9208 \end_layout
9209
9210 \begin_layout Standard
9211 A complete user guide is contained in that package and you should familiarize
9212  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
9213 .
9214  \SpecialChar LyX
9215  will not reduce the need to figure out all the AAS\SpecialChar TeX
9216  commands, it will only
9217  reduce the drudgery of typing everything in.
9218  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
9219  document conforms
9220  completely to the requirements of the journal to which you are submitting
9221  your paper.
9222 \end_layout
9223
9224 \begin_layout Subsection
9225 Starting a New Paper
9226 \end_layout
9227
9228 \begin_layout Standard
9229 I strongly suggest that you start with the AAS\SpecialChar TeX
9230  template file.
9231  Click on 
9232 \family sans
9233 File\SpecialChar menuseparator
9234 New from
9235 \family default
9236  
9237 \family sans
9238 Template
9239 \family default
9240 , enter the new file name, then choose the 
9241 \family typewriter
9242 aastex6.lyx
9243 \family default
9244  template.
9245  This will show the most common fields found in a manuscript.
9246  Simply overwrite the existing text (including the brackets, 
9247 \family typewriter
9248 <>
9249 \family default
9250 ) with the correct information.
9251  Many of the AAS\SpecialChar TeX
9252  commands and environments can be implemented directly in
9253  \SpecialChar LyX
9254 , but some cannot.
9255  For commands such as these, the \SpecialChar LaTeX
9256  code must be entered directly and marked
9257  as such.
9258  Such commands are referred to as \SpecialChar TeX
9259  code, or Evil Red Text.
9260  I tried to minimize the amount of \SpecialChar TeX
9261  code needed in an AAS\SpecialChar TeX
9262  document.
9263 \end_layout
9264
9265 \begin_layout Subsection
9266 Finishing Your Paper
9267 \end_layout
9268
9269 \begin_layout Standard
9270 When the paper is finished to your satisfaction and previews/prints correctly,
9271  there are a few 
9272 \begin_inset Quotes eld
9273 \end_inset
9274
9275 postprocessing
9276 \begin_inset Quotes erd
9277 \end_inset
9278
9279  actions which need to be done before you submit it to the journals.
9280  
9281 \end_layout
9282
9283 \begin_layout Enumerate
9284 Export your paper as a \SpecialChar LaTeX
9285  file (
9286 \family sans
9287 File\SpecialChar menuseparator
9288 Export\SpecialChar menuseparator
9289 \SpecialChar LaTeX
9290
9291 \family default
9292 ).
9293  
9294 \end_layout
9295
9296 \begin_layout Enumerate
9297 Edit the resulting 
9298 \family typewriter
9299 .tex
9300 \family default
9301  file with your favorite text editor
9302 \end_layout
9303
9304 \begin_deeper
9305 \begin_layout Enumerate
9306 remove the comment lines before the 
9307 \family typewriter
9308
9309 \backslash
9310 documentclass
9311 \family default
9312  command
9313 \end_layout
9314
9315 \begin_layout Enumerate
9316 remove the 
9317 \family typewriter
9318
9319 \backslash
9320 usepackage...{fontenc}
9321 \family default
9322  line if it appears (usually just after 
9323 \family typewriter
9324
9325 \backslash
9326 documentclass
9327 \family default
9328 }; also remove the 
9329 \family typewriter
9330
9331 \backslash
9332 secnumdepth
9333 \family default
9334  line if it appears.
9335 \end_layout
9336
9337 \begin_layout Enumerate
9338 remove everything between (and including) the 
9339 \family typewriter
9340
9341 \backslash
9342 makeatletter
9343 \family default
9344  and 
9345 \family typewriter
9346
9347 \backslash
9348 makeatother
9349 \family default
9350  commands, except for any commands you specifically put into the \SpecialChar LaTeX
9351  preamble
9352  (which should appear immediately after the 
9353 \begin_inset Quotes eld
9354 \end_inset
9355
9356 User specified \SpecialChar LaTeX
9357  commands
9358 \begin_inset Quotes erd
9359 \end_inset
9360
9361  comment in the 
9362 \family typewriter
9363 .tex
9364 \family default
9365  file).
9366 \end_layout
9367
9368 \end_deeper
9369 \begin_layout Enumerate
9370 Run the resulting file through \SpecialChar LaTeX
9371  to make sure it still processes correctly.
9372 \end_layout
9373
9374 \begin_layout Enumerate
9375 Reread the journal requirements to make sure your filenames and formats
9376  are correct.
9377 \end_layout
9378
9379 \begin_layout Enumerate
9380 Submit it.
9381 \end_layout
9382
9383 \begin_layout Subsection
9384 Comments On Specific Commands
9385 \end_layout
9386
9387 \begin_layout Standard
9388 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
9389  commands: the
9390  AAS\SpecialChar TeX
9391  User Guide (
9392 \family typewriter
9393 aasguide.tex
9394 \family default
9395 ) gives a good description of each.
9396  Thus it's probably easiest for me to go down the list as found in the guide
9397  and offer comments where necessary.
9398  So let's begin \SpecialChar ldots
9399
9400 \end_layout
9401
9402 \begin_layout Subsubsection
9403 Things that work as expected
9404 \end_layout
9405
9406 \begin_layout Standard
9407 Because they work as you might expect, I simply list them and the section
9408  they are found in: 
9409 \family typewriter
9410
9411 \backslash
9412 documentclass
9413 \family default
9414  (2.1.1), 
9415 \family typewriter
9416
9417 \backslash
9418 begin{document}
9419 \family default
9420  (2.2), 
9421 \family typewriter
9422
9423 \backslash
9424 title
9425 \family default
9426  (2.3), 
9427 \family typewriter
9428
9429 \backslash
9430 author
9431 \family default
9432  (2.3), 
9433 \family typewriter
9434
9435 \backslash
9436 affil
9437 \family default
9438  (2.3), 
9439 \family typewriter
9440
9441 \backslash
9442 abstract
9443 \family default
9444  (2.4), 
9445 \family typewriter
9446
9447 \backslash
9448 keywords
9449 \family default
9450  (2.5), 
9451 \family typewriter
9452
9453 \backslash
9454 section
9455 \family default
9456  (2.7), 
9457 \family typewriter
9458
9459 \backslash
9460 subsection
9461 \family default
9462  (2.7), 
9463 \family typewriter
9464
9465 \backslash
9466 subsubsection
9467 \family default
9468  (2.7), 
9469 \family typewriter
9470
9471 \backslash
9472 paragraph
9473 \family default
9474  (2.7), 
9475 \family typewriter
9476
9477 \backslash
9478 facility
9479 \family default
9480  (2.10), 
9481 \family typewriter
9482
9483 \backslash
9484 begin{displaymath}
9485 \family default
9486  (2.12), 
9487 \family typewriter
9488
9489 \backslash
9490 begin{equation}
9491 \family default
9492  (2.12), 
9493 \family typewriter
9494
9495 \backslash
9496 begin{eqnarray}
9497 \family default
9498  (2.12), 
9499 \family typewriter
9500
9501 \backslash
9502 begin{mathletters}
9503 \family default
9504  (2.12), 
9505 \family typewriter
9506
9507 \backslash
9508 begin{thebibliography}
9509 \family default
9510  (2.13.1), 
9511 \family typewriter
9512
9513 \backslash
9514 bibitem
9515 \family default
9516  (2.13.2), all the cite commands and their variations (2.13.2), the generic
9517  graphicx figure commands (2.14.1), 
9518 \family typewriter
9519
9520 \backslash
9521 begin{table}
9522 \family default
9523  (2.15.4), 
9524 \family typewriter
9525
9526 \backslash
9527 begin{tabular}
9528 \family default
9529  (2.15.4), 
9530 \family typewriter
9531
9532 \backslash
9533 caption
9534 \family default
9535  (2.15.4), 
9536 \family typewriter
9537
9538 \backslash
9539 label
9540 \family default
9541  (2.15.4, amongst other places), 
9542 \family typewriter
9543
9544 \backslash
9545 tablerefs
9546 \family default
9547  (2.15.5), 
9548 \family typewriter
9549
9550 \backslash
9551 tablecomments
9552 \family default
9553  (2.15.5), 
9554 \family typewriter
9555
9556 \backslash
9557 url
9558 \family default
9559  (2.17.4), 
9560 \family typewriter
9561
9562 \backslash
9563 end{document}
9564 \family default
9565  (2.18).
9566 \end_layout
9567
9568 \begin_layout Standard
9569 The following style options also work correctly: 
9570 \family typewriter
9571 longabstract
9572 \family default
9573  (2.4), 
9574 \family typewriter
9575 preprint
9576 \family default
9577  (3.2.1), 
9578 \family typewriter
9579 preprint2
9580 \family default
9581  (3.2.2), 
9582 \family typewriter
9583 eqsecnum
9584 \family default
9585  (3.3), 
9586 \family typewriter
9587 flushrt
9588 \family default
9589  (3.4).
9590  Simply put them in the 
9591 \family sans
9592 Options
9593 \family default
9594  box in 
9595 \family sans
9596 Layout\SpecialChar menuseparator
9597 Document
9598 \family default
9599 .
9600 \end_layout
9601
9602 \begin_layout Subsubsection
9603 Things that work, but require more comment
9604 \end_layout
9605
9606 \begin_layout Standard
9607 The following items work, but require a little more discussion:
9608 \end_layout
9609
9610 \begin_layout Itemize
9611 These items are reserved for use by the journal editors, but you can put
9612  them into the \SpecialChar LaTeX
9613  preamble if you feel compelled to do so: 
9614 \family typewriter
9615
9616 \backslash
9617 received
9618 \family default
9619
9620 \family typewriter
9621
9622 \backslash
9623 revised
9624 \family default
9625
9626 \family typewriter
9627
9628 \backslash
9629 accepted
9630 \family default
9631
9632 \family typewriter
9633
9634 \backslash
9635 ccc
9636 \family default
9637
9638 \family typewriter
9639
9640 \backslash
9641 cpright
9642 \family default
9643  (all from 2.1.3)
9644 \end_layout
9645
9646 \begin_layout Itemize
9647 These items may be placed in the \SpecialChar LaTeX
9648  preamble, and are included as blanks in
9649  the template file: 
9650 \family typewriter
9651
9652 \backslash
9653 slugcomment
9654 \family default
9655  (2.1.4), 
9656 \family typewriter
9657
9658 \backslash
9659 shorttitle
9660 \family default
9661  (2.1.5), 
9662 \family typewriter
9663
9664 \backslash
9665 shortauthors
9666 \family default
9667  (2.1.5)
9668 \end_layout
9669
9670 \begin_layout Itemize
9671
9672 \family typewriter
9673
9674 \backslash
9675 email
9676 \family default
9677  (2.3) – can only be used 
9678 \begin_inset Quotes eld
9679 \end_inset
9680
9681 standalone
9682 \begin_inset Quotes erd
9683 \end_inset
9684
9685 , not in the middle of a paragraph.
9686  Use \SpecialChar TeX
9687  code if you need to embed it.
9688 \end_layout
9689
9690 \begin_layout Itemize
9691
9692 \family typewriter
9693
9694 \backslash
9695 and
9696 \family default
9697  (2.3) – will have extra {} after it.
9698  This should not cause an error.
9699 \end_layout
9700
9701 \begin_layout Itemize
9702
9703 \family typewriter
9704
9705 \backslash
9706 notetoeditor
9707 \family default
9708  (2.6) – can only be used 
9709 \begin_inset Quotes eld
9710 \end_inset
9711
9712 standalone
9713 \begin_inset Quotes erd
9714 \end_inset
9715
9716 , not in the middle of a paragraph.
9717  Use \SpecialChar TeX
9718  code if you need to embed it.
9719 \end_layout
9720
9721 \begin_layout Itemize
9722
9723 \family typewriter
9724
9725 \backslash
9726 placetable
9727 \family default
9728  (2.8) – can't insert a cross-reference tag, you must type the tag name by
9729  hand
9730 \end_layout
9731
9732 \begin_layout Itemize
9733
9734 \family typewriter
9735
9736 \backslash
9737 placefigure
9738 \family default
9739  (2.8) – same as for 
9740 \family typewriter
9741
9742 \backslash
9743 placetable
9744 \end_layout
9745
9746 \begin_layout Itemize
9747
9748 \family typewriter
9749
9750 \backslash
9751 acknowledgements
9752 \family default
9753  (2.9) – will have extra {} after it.
9754  This should not cause an error.
9755 \end_layout
9756
9757 \begin_layout Itemize
9758
9759 \family typewriter
9760
9761 \backslash
9762 appendix
9763 \family default
9764  (2.11) – will have extra {} after it.
9765  This should not cause an error.
9766 \end_layout
9767
9768 \begin_layout Itemize
9769
9770 \family typewriter
9771
9772 \backslash
9773 figcaption
9774 \family default
9775  (2.14.2) – you can insert an optional filename argument by placing the cursor
9776  at the beginning of the text and selecting 
9777 \family sans
9778 Insert\SpecialChar menuseparator
9779 Short Title
9780 \family default
9781 .
9782  
9783 \begin_inset Quotes eld
9784 \end_inset
9785
9786 Short Title
9787 \begin_inset Quotes erd
9788 \end_inset
9789
9790  inserts an optional argument of the type needed by 
9791 \family typewriter
9792
9793 \backslash
9794 figcaption
9795 \family default
9796 .
9797  Hopefully it will be renamed someday.
9798 \end_layout
9799
9800 \begin_layout Itemize
9801
9802 \family typewriter
9803
9804 \backslash
9805 objectname
9806 \family default
9807  (2.17.1) – same as 
9808 \family typewriter
9809
9810 \backslash
9811 figcaption
9812 \family default
9813  for the catalog ID optional parameter
9814 \end_layout
9815
9816 \begin_layout Itemize
9817
9818 \family typewriter
9819
9820 \backslash
9821 dataset
9822 \family default
9823  (2.17.1) – same as 
9824 \family typewriter
9825
9826 \backslash
9827 figcaption
9828 \family default
9829  for the catalog ID optional parameter
9830 \end_layout
9831
9832 \begin_layout Subsubsection
9833 Things not implemented, use \SpecialChar TeX
9834  code
9835 \end_layout
9836
9837 \begin_layout Standard
9838
9839 \family typewriter
9840
9841 \backslash
9842 eqnum
9843 \family default
9844  (2.12), 
9845 \family typewriter
9846
9847 \backslash
9848 setcounter{equation}
9849 \family default
9850  (2.12), Journal name abbreviations (2.13.4), 
9851 \family typewriter
9852
9853 \backslash
9854 figurenum
9855 \family default
9856  (2.14.1), 
9857 \family typewriter
9858
9859 \backslash
9860 epsscale
9861 \family default
9862  (2.14.1), 
9863 \family typewriter
9864
9865 \backslash
9866 plotone
9867 \family default
9868  (2.14.1), 
9869 \family typewriter
9870
9871 \backslash
9872 plottwo
9873 \family default
9874  (2.14.1), 
9875 \family typewriter
9876
9877 \backslash
9878 tablenum
9879 \family default
9880  (2.15.4), 
9881 \family typewriter
9882
9883 \backslash
9884 tableline
9885 \family default
9886  (2.15.4, insert it as the first element in the lefthand cell after where
9887  you want it.
9888  Don't use any of \SpecialChar LyX
9889 's rules in the table), 
9890 \family typewriter
9891
9892 \backslash
9893 tablenotemark
9894 \family default
9895  (2.15.5), 
9896 \family typewriter
9897
9898 \backslash
9899 tablenotetext
9900 \family default
9901  (2.15.5), much of Misc (2.17, except 
9902 \family typewriter
9903
9904 \backslash
9905 objectname
9906 \family default
9907
9908 \family typewriter
9909
9910 \backslash
9911 dataset
9912 \family default
9913
9914 \family typewriter
9915
9916 \backslash
9917 url
9918 \family default
9919 , and 
9920 \family typewriter
9921
9922 \backslash
9923 email
9924 \family default
9925 ; see above), 
9926 \family typewriter
9927
9928 \backslash
9929 singlespace
9930 \family default
9931  (3.1), 
9932 \family typewriter
9933
9934 \backslash
9935 doublespace
9936 \family default
9937  (3.1), 
9938 \family typewriter
9939
9940 \backslash
9941 onecolumn
9942 \family default
9943  (3.2), 
9944 \family typewriter
9945
9946 \backslash
9947 twocolumn
9948 \family default
9949  (3.2)
9950 \end_layout
9951
9952 \begin_layout Subsubsection
9953 Things that cannot be implemented
9954 \end_layout
9955
9956 \begin_layout Standard
9957 \SpecialChar ldots
9958  at least in any meaningful sort of way, so I suggest ignoring them.
9959  They are the references environment (2.13.3), and the deluxetable environment
9960  (2.15).
9961  If you really, really need to use deluxetable, I suggest editing it in
9962  a separate file with a text editor, then using 
9963 \family sans
9964 Insert\SpecialChar menuseparator
9965 Child
9966 \begin_inset space ~
9967 \end_inset
9968
9969 Document
9970 \family default
9971  to include it in your \SpecialChar LyX
9972  document.
9973  See the 
9974 \family typewriter
9975 aas_sample.lyx
9976 \family default
9977  file to see an example of this.
9978 \end_layout
9979
9980 \begin_layout Subsection
9981 FAQs, Tips, Tricks, and Other Ruminations
9982 \end_layout
9983
9984 \begin_layout Subsubsection
9985 Getting \SpecialChar LyX
9986  and AAS\SpecialChar TeX
9987  to cooperate
9988 \end_layout
9989
9990 \begin_layout Standard
9991 It can be a bit tricky to get \SpecialChar LyX
9992  to recognize a new layout and document class.
9993  When all else fails, do this:
9994 \end_layout
9995
9996 \begin_layout Enumerate
9997 Make certain that \SpecialChar LaTeX
9998  can find AAS\SpecialChar TeX
9999 .
10000  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
10001  distribution into a
10002  directory completely unrelated to \SpecialChar LaTeX
10003  or AAS\SpecialChar TeX
10004  and run \SpecialChar LaTeX
10005  on 
10006 \family typewriter
10007 sample.tex
10008 \family default
10009 .
10010 \end_layout
10011
10012 \begin_layout Enumerate
10013 Make certain that 
10014 \family typewriter
10015 aastex.layout
10016 \family default
10017  appears in \SpecialChar LyX
10018 's 
10019 \family typewriter
10020 layouts
10021 \family default
10022  folder
10023 \end_layout
10024
10025 \begin_layout Enumerate
10026 Rerun 
10027 \family sans
10028 Tools\SpecialChar menuseparator
10029 Reconfigure
10030 \family default
10031  in \SpecialChar LyX
10032 , then restart \SpecialChar LyX
10033 .
10034 \end_layout
10035
10036 \begin_layout Enumerate
10037 Open a regular new file, not from a template.
10038  Does AAS\SpecialChar TeX
10039  appear in the class list in 
10040 \family sans
10041 Document\SpecialChar menuseparator
10042 Settings
10043 \family default
10044 ?
10045 \end_layout
10046
10047 \begin_layout Standard
10048 If you get a warning from an existing AAS\SpecialChar TeX
10049  document about not being able
10050  to find the AAS\SpecialChar TeX
10051  layout or a message about 
10052 \begin_inset Quotes eld
10053 \end_inset
10054
10055 You should not mix title layouts with normal ones
10056 \begin_inset Quotes erd
10057 \end_inset
10058
10059 , things haven't been installed correctly.
10060 \end_layout
10061
10062 \begin_layout Subsubsection
10063 \SpecialChar LaTeX
10064  error processing a table 
10065 \end_layout
10066
10067 \begin_layout Standard
10068 \SpecialChar LyX
10069 , by default, attempts to center the table caption/title.
10070  This seems to produce a bad interaction in AAS\SpecialChar TeX
10071  so you should click somewhere
10072  in the caption/title, then select 
10073 \family sans
10074 Edit\SpecialChar menuseparator
10075 Paragraph
10076 \begin_inset space ~
10077 \end_inset
10078
10079 Settings
10080 \family default
10081 , then set the 
10082 \family sans
10083 Alignment
10084 \family default
10085  to 
10086 \family sans
10087 Block
10088 \family default
10089 .
10090  This took care of it for me.
10091 \end_layout
10092
10093 \begin_layout Subsubsection
10094 References
10095 \end_layout
10096
10097 \begin_layout Standard
10098 A couple of things: 1) I have noticed some funny spacing in the reference
10099  entries in the text.
10100  When you enter the bibliography item data, make sure their is 
10101 \emph on
10102 no
10103 \emph default
10104  space between the last author and the parenthesis setting off the year;
10105  
10106 \emph on
10107 e.
10108 \begin_inset space \thinspace{}
10109 \end_inset
10110
10111 g.
10112 \begin_inset space \space{}
10113 \end_inset
10114
10115
10116 \emph default
10117 type 
10118 \family typewriter
10119 Ressler(1992)
10120 \family default
10121 , not 
10122 \family typewriter
10123 Ressler (1992)
10124 \family default
10125 .
10126  2) Entering the references at all is not obvious.
10127  The easiest thing is to start typing your first reference at the end of
10128  the document, then mark it as type 
10129 \family sans
10130 References
10131 \family default
10132 .
10133  That will put a small gray box in front of what you just typed.
10134  Click on the box to fill in the rest of the information.
10135  For new references, go to the end of an existing reference and press return.
10136  That will create a new line with its own box, etc.
10137 \end_layout
10138
10139 \begin_layout Subsubsection
10140 Including EPS files
10141 \end_layout
10142
10143 \begin_layout Standard
10144 Even though AAS\SpecialChar TeX
10145  provides its own figure commands (
10146 \family typewriter
10147
10148 \backslash
10149 plotone
10150 \family default
10151 , for example), I much prefer \SpecialChar LaTeX
10152 's standard figure commands (with the default
10153  graphicx).
10154  You can insert the 
10155 \family typewriter
10156
10157 \backslash
10158 plotone
10159 \family default
10160 , etc.
10161 \begin_inset space ~
10162 \end_inset
10163
10164 commands as \SpecialChar TeX
10165  code into a Figure Float box if you desire, but I never have
10166  much luck getting the layout right.
10167  With the standard graphics, \SpecialChar LyX
10168  will insert a 
10169 \family typewriter
10170
10171 \backslash
10172 usepackage{graphicx}
10173 \family default
10174  command into the \SpecialChar LaTeX
10175  preamble and handle the figures in the standard \SpecialChar LaTeX2e
10176  way,
10177  interspersing the figures in the text.
10178  I believe ApJ accepts figures exactly this way now; AJ might still use
10179  the 
10180 \begin_inset Quotes eld
10181 \end_inset
10182
10183 stack everything at the end
10184 \begin_inset Quotes erd
10185 \end_inset
10186
10187  technique.
10188 \end_layout
10189
10190 \begin_layout Subsubsection
10191 Things I could have done, but didn't
10192 \end_layout
10193
10194 \begin_layout Standard
10195 There are a few 
10196 \begin_inset Quotes eld
10197 \end_inset
10198
10199 pretty
10200 \begin_inset Quotes erd
10201 \end_inset
10202
10203  things I could have implemented, but chose not to.
10204  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
10205  window,
10206  even though it is double-spaced in the paper manuscript.
10207  Also, I chose not to make separate layouts for the preprint and preprint2
10208  styles.
10209  Since I assume you will spend most of your time in the plain manuscript
10210  mode anyway, I decided not to chew up more disk space with this.
10211  
10212 \end_layout
10213
10214 \begin_layout Subsection
10215 Final Caveat
10216 \end_layout
10217
10218 \begin_layout Standard
10219 Your mileage may vary.
10220  I've now had papers published by both ApJ and AJ that have had 98% of the
10221  effort done in \SpecialChar LyX
10222 ; the last 2% was the \SpecialChar LaTeX
10223  post-processing and a few cleanups.
10224  I have had no trouble with the submission process, and I'm sure the journals
10225  were never aware that there might be a difference.
10226  So, go forth and publish!
10227 \end_layout
10228
10229 \begin_layout Section
10230 AMS \SpecialChar LaTeX
10231
10232 \end_layout
10233
10234 \begin_layout Standard
10235 by 
10236 \noun on
10237 David Johnson
10238 \noun default
10239 ; updated by 
10240 \noun on
10241 Richard Kimberly Heck
10242 \end_layout
10243
10244 \begin_layout Standard
10245 \begin_inset VSpace bigskip
10246 \end_inset
10247
10248
10249 \end_layout
10250
10251 \begin_layout Standard
10252 \noindent
10253 The AMS \SpecialChar LaTeX
10254  layouts are set up to conform to suggested styles for mathematical
10255  papers to be submitted to American Mathematical Society publications.
10256  The layouts are not tailored to a specific journal, but easily can be.
10257  You should refer to the AMS documentation for specific instructions for
10258  each journal (usually it will entail only changing a single line in the
10259  \SpecialChar TeX
10260  output).
10261  That documentation is available on the Web at 
10262 \begin_inset Flex URL
10263 status open
10264
10265 \begin_layout Plain Layout
10266
10267 http://www.ams.org
10268 \end_layout
10269
10270 \end_inset
10271
10272  or by ftp at 
10273 \begin_inset Flex URL
10274 status open
10275
10276 \begin_layout Plain Layout
10277
10278 ftp://ftp.ams.org/pub/tex/amslatex/
10279 \end_layout
10280
10281 \end_inset
10282
10283 .
10284  These layouts are appropriate, and useful, for any mathematical writing.
10285  
10286 \end_layout
10287
10288 \begin_layout Standard
10289 There are two basic AMS \SpecialChar LaTeX
10290  layouts: 
10291 \end_layout
10292
10293 \begin_layout Itemize
10294 amsart: The standard AMS article format.
10295 \end_layout
10296
10297 \begin_layout Itemize
10298 amsbook: the standard AMS book (really, monograph) format.
10299  
10300 \end_layout
10301
10302 \begin_layout Standard
10303 The layouts themselves contain only the minimum necessary to use the AMS
10304  classes.
10305  They do not, in particular, contain any of the `theorem' environments used
10306  for setting theorems, lemmas, and the like.
10307  These are contained, instead, in the 
10308 \begin_inset Flex Code
10309 status collapsed
10310
10311 \begin_layout Plain Layout
10312 Theorems (AMS)
10313 \end_layout
10314
10315 \end_inset
10316
10317  module, which is loaded by default when you select one of the AMS classes.
10318  (It can also be used with other classes and can be removed, if you would
10319  rather use something else.) Less commonly used environments are in the 
10320 \begin_inset Flex Code
10321 status collapsed
10322
10323 \begin_layout Plain Layout
10324 Theorems (AMS-Extended)
10325 \end_layout
10326
10327 \end_inset
10328
10329  module, which must be loaded manually.
10330 \end_layout
10331
10332 \begin_layout Standard
10333 By default, theorems and the like are numbered consecutively throughout
10334  the document, but this may be modified by loading the module 
10335 \begin_inset Flex Code
10336 status collapsed
10337
10338 \begin_layout Plain Layout
10339 Theorems (Order by Section)
10340 \end_layout
10341
10342 \end_inset
10343
10344  or, if you are using 
10345 \begin_inset Flex Code
10346 status collapsed
10347
10348 \begin_layout Plain Layout
10349 book (AMS)
10350 \end_layout
10351
10352 \end_inset
10353
10354 , the module 
10355 \begin_inset Flex Code
10356 status collapsed
10357
10358 \begin_layout Plain Layout
10359 Theorems (Order by Chapter)
10360 \end_layout
10361
10362 \end_inset
10363
10364 .
10365  These will number the results as 
10366 \begin_inset Formula $n.m$
10367 \end_inset
10368
10369 , where the first number refers to the section (or chapter) and the second
10370  refers to the total number of results so far in that section (or chapter).
10371  Many environments are also available unnumbered.
10372  These are indicated by an asterisk at the end.
10373  If you happen to want 
10374 \emph on
10375 only
10376 \emph default
10377  unnumbered results, the module 
10378 \begin_inset Flex Code
10379 status collapsed
10380
10381 \begin_layout Plain Layout
10382 Theorems (Starred)
10383 \end_layout
10384
10385 \end_inset
10386
10387  provides that option.
10388 \end_layout
10389
10390 \begin_layout Standard
10391 Note that these modules do not 
10392 \emph on
10393 have
10394 \emph default
10395  to be used with the AMS classes.
10396  It is perfectly possible to use the 
10397 \begin_inset Flex Code
10398 status collapsed
10399
10400 \begin_layout Plain Layout
10401 Theorems (AMS)
10402 \end_layout
10403
10404 \end_inset
10405
10406  module, and the others mentioned, with other classes, such as 
10407 \begin_inset Flex Code
10408 status collapsed
10409
10410 \begin_layout Plain Layout
10411 article
10412 \end_layout
10413
10414 \end_inset
10415
10416
10417 \begin_inset Flex Code
10418 status collapsed
10419
10420 \begin_layout Plain Layout
10421 report
10422 \end_layout
10423
10424 \end_inset
10425
10426
10427 \begin_inset Flex Code
10428 status collapsed
10429
10430 \begin_layout Plain Layout
10431 book (KOMA-script)
10432 \end_layout
10433
10434 \end_inset
10435
10436 , and so forth.
10437 \end_layout
10438
10439 \begin_layout Subsection
10440 What these layouts provide
10441 \end_layout
10442
10443 \begin_layout Standard
10444 There is a long list of included environments provided by these layouts.
10445  In AMS-\SpecialChar LaTeX
10446 , there is, in fact, an opportunity to define an unlimited variety
10447  of `theorem' environments.
10448  However, the AMS recommends the environments that are available in \SpecialChar LyX
10449 .
10450  
10451 \end_layout
10452
10453 \begin_layout Standard
10454 The following environments—as well as the standard environments, such as
10455  
10456 \begin_inset Flex Noun
10457 status collapsed
10458
10459 \begin_layout Plain Layout
10460 section
10461 \end_layout
10462
10463 \end_inset
10464
10465
10466 \begin_inset Flex Noun
10467 status collapsed
10468
10469 \begin_layout Plain Layout
10470 bibliography
10471 \end_layout
10472
10473 \end_inset
10474
10475
10476 \begin_inset Flex Noun
10477 status collapsed
10478
10479 \begin_layout Plain Layout
10480 title
10481 \end_layout
10482
10483 \end_inset
10484
10485
10486 \begin_inset Flex Noun
10487 status collapsed
10488
10489 \begin_layout Plain Layout
10490 author
10491 \end_layout
10492
10493 \end_inset
10494
10495 , and 
10496 \begin_inset Flex Noun
10497 status collapsed
10498
10499 \begin_layout Plain Layout
10500 date
10501 \end_layout
10502
10503 \end_inset
10504
10505 —are provided by 
10506 \begin_inset Flex Code
10507 status collapsed
10508
10509 \begin_layout Plain Layout
10510 article (AMS)
10511 \end_layout
10512
10513 \end_inset
10514
10515  and 
10516 \begin_inset Flex Code
10517 status collapsed
10518
10519 \begin_layout Plain Layout
10520 book (AMS)
10521 \end_layout
10522
10523 \end_inset
10524
10525 :
10526 \end_layout
10527
10528 \begin_layout Description
10529 Address This should be the author's permanent address.
10530 \end_layout
10531
10532 \begin_layout Description
10533 Current
10534 \begin_inset space ~
10535 \end_inset
10536
10537 Address This should be the author's temporary address at the time of submission,
10538  if different from the Address.
10539 \end_layout
10540
10541 \begin_layout Description
10542 Email Author's e-mail address
10543 \end_layout
10544
10545 \begin_layout Description
10546 URL Author's Web address, if desired.
10547 \end_layout
10548
10549 \begin_layout Description
10550 Keywords Key words or phrases used to identify specific topics discussed
10551  in the paper.
10552 \end_layout
10553
10554 \begin_layout Description
10555 Subjectclass These refer to the AMS Subject Classifications, published and
10556  described in 
10557 \emph on
10558 Mathematical Reviews
10559 \emph default
10560 .
10561  These are also available online at the AMS cites listed above.
10562 \end_layout
10563
10564 \begin_layout Description
10565 Thanks
10566 \end_layout
10567
10568 \begin_layout Description
10569 Dedicatory
10570 \end_layout
10571
10572 \begin_layout Description
10573 Translator
10574 \end_layout
10575
10576 \begin_layout Standard
10577 The following environments are provided by both the 
10578 \begin_inset Flex Code
10579 status collapsed
10580
10581 \begin_layout Plain Layout
10582 Theorems
10583 \end_layout
10584
10585 \end_inset
10586
10587  and 
10588 \begin_inset Flex Code
10589 status collapsed
10590
10591 \begin_layout Plain Layout
10592 Theorems (AMS)
10593 \end_layout
10594
10595 \end_inset
10596
10597  modules, in the latter case in both starred (unnumbered) and unstarred
10598  (numbered) versions.
10599  These same environments are provided only in the starred versions by the
10600  
10601 \begin_inset Flex Code
10602 status collapsed
10603
10604 \begin_layout Plain Layout
10605 Theorems (Starred)
10606 \end_layout
10607
10608 \end_inset
10609
10610  module:
10611 \end_layout
10612
10613 \begin_layout Theorem
10614 This is typically used for the statements of major results.
10615  
10616 \end_layout
10617
10618 \begin_layout Corollary*
10619 This is used for statements which follow fairly directly from previous statement
10620 s.
10621  Again, these can be major results.
10622  
10623 \end_layout
10624
10625 \begin_layout Lemma
10626 These are smaller results needed to prove other statements.
10627 \end_layout
10628
10629 \begin_layout Proposition
10630 These are less major results which (hopefully) add to the general theory
10631  being discussed.
10632 \end_layout
10633
10634 \begin_layout Conjecture
10635 These are statements provided without justification, which the author does
10636  not know how to prove, but which seem to be true (to the author, at least).
10637 \end_layout
10638
10639 \begin_layout Definition*
10640 Guess what this is for.
10641  The font is different for this environment than for the previous ones.
10642  
10643 \end_layout
10644
10645 \begin_layout Example*
10646 Used for examples illustrating proven results.
10647 \end_layout
10648
10649 \begin_layout Problem
10650 It's not really known what this is for.
10651  You should figure it out.
10652 \end_layout
10653
10654 \begin_layout Exercise*
10655 Write a description for this one.
10656 \end_layout
10657
10658 \begin_layout Remark
10659 This environment is also a type of theorem, usually a lesser sort of observation.
10660 \end_layout
10661
10662 \begin_layout Claim*
10663 Often used in the course of giving a proof of a larger result.
10664 \end_layout
10665
10666 \begin_layout Case
10667 Generally, these are used to break up long arguments, using specific instances
10668  of some condition.
10669  
10670 \end_layout
10671
10672 \begin_layout Case
10673 The numbering scheme for cases is on its own, not together with other numbered
10674  statements.
10675  
10676 \end_layout
10677
10678 \begin_layout Proof
10679 At the end of this environment, a QED symbol (usually a square, but it can
10680  vary with different styles) is placed.
10681  If you want to have other environments within this one—for example, Case
10682  environments—and have the QED symbol appear only after them, then the other
10683  environments need to be nested within the proof environment.
10684  See the section 
10685 \emph on
10686 Nesting Environments
10687 \emph default
10688  of the 
10689 \emph on
10690 User's Guide
10691 \emph default
10692  for information on nesting.
10693 \end_layout
10694
10695 \begin_layout Standard
10696 And these environments are provided by 
10697 \begin_inset Flex Code
10698 status collapsed
10699
10700 \begin_layout Plain Layout
10701 Theorems (AMS-Extended)
10702 \end_layout
10703
10704 \end_inset
10705
10706 :
10707 \end_layout
10708
10709 \begin_layout Criterion*
10710 A required condition.
10711 \end_layout
10712
10713 \begin_layout Algorithm*
10714 A general procedure to be used.
10715 \end_layout
10716
10717 \begin_layout Axiom*
10718 This is a property or statement taken as true within the system being discussed.
10719 \end_layout
10720
10721 \begin_layout Condition*
10722 Sometimes used to state a condition assumed within the present context of
10723  discussion.
10724 \end_layout
10725
10726 \begin_layout Note*
10727 Similar to a Remark.
10728 \end_layout
10729
10730 \begin_layout Notation*
10731 Used for the explanation of, yes, notation.
10732 \end_layout
10733
10734 \begin_layout Summary
10735 Do we really need to tell you? 
10736 \end_layout
10737
10738 \begin_layout Acknowledgement*
10739 Acknowledgement.
10740 \end_layout
10741
10742 \begin_layout Conclusion*
10743 Sometimes used at the end of a long train of argument.
10744 \end_layout
10745
10746 \begin_layout Fact
10747 Used in a way similar to Proposition, though perhaps lower on the scale.
10748 \end_layout
10749
10750 \begin_layout Standard
10751 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
10752  and AMS fonts
10753  packages.
10754  They need to be available on your system in order to use these environments.
10755 \end_layout
10756
10757 \begin_layout Section
10758 Broadway
10759 \end_layout
10760
10761 \begin_layout Standard
10762 by 
10763 \shape smallcaps
10764 Garst Reese
10765 \end_layout
10766
10767 \begin_layout Subsection
10768 Introduction
10769 \end_layout
10770
10771 \begin_layout Standard
10772 Broadway is for writing plays.
10773  The format is more decorative than Hollywood, and much less standardized.
10774  This format should be suitable for workshops.
10775 \end_layout
10776
10777 \begin_layout Subsection
10778 Special problems
10779 \end_layout
10780
10781 \begin_layout Standard
10782 The same as in Hollywood.
10783 \end_layout
10784
10785 \begin_layout Subsection
10786 Special features
10787 \end_layout
10788
10789 \begin_layout Standard
10790 Insert the 
10791 \family sans
10792 Speaker
10793 \family default
10794  names as labels then cross-reference the label to insert the name.
10795  The cross-reference dialog will show the current cast of characters.
10796 \end_layout
10797
10798 \begin_layout Subsection
10799 Paper size and Margins
10800 \end_layout
10801
10802 \begin_layout Standard
10803 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10804 \end_layout
10805
10806 \begin_layout Subsection
10807 Environments
10808 \end_layout
10809
10810 \begin_layout Standard
10811 The following environments are available.
10812  You can use broadway.bind to get the bind keys shown at the right.
10813 \end_layout
10814
10815 \begin_layout Itemize
10816
10817 \family sans
10818 Standard
10819 \begin_inset Newline newline
10820 \end_inset
10821
10822
10823 \family default
10824 You should not have to use this, but it is here for anything that does not
10825  fit otherwise.
10826 \end_layout
10827
10828 \begin_layout Itemize
10829
10830 \family sans
10831 Narrative
10832 \begin_inset space \hfill{}
10833 \end_inset
10834
10835 M-z n
10836 \begin_inset Newline newline
10837 \end_inset
10838
10839
10840 \family default
10841 Used to describe stage setting and the action.
10842  First use of speaker names in all CAPs.
10843 \end_layout
10844
10845 \begin_layout Itemize
10846
10847 \family sans
10848 ACT
10849 \begin_inset space \hfill{}
10850 \end_inset
10851
10852 M-z a
10853 \begin_inset Newline newline
10854 \end_inset
10855
10856
10857 \family default
10858 Automatically numbered.
10859  On screen it will be arabic, but will print as Roman.
10860 \end_layout
10861
10862 \begin_layout Itemize
10863
10864 \family sans
10865 ACT*
10866 \begin_inset space \hfill{}
10867 \end_inset
10868
10869 M-z S at
10870 \begin_inset Newline newline
10871 \end_inset
10872
10873
10874 \family default
10875 Subtitle for 
10876 \family sans
10877 ACT.
10878
10879 \family default
10880  It is just centered text.
10881 \end_layout
10882
10883 \begin_layout Itemize
10884
10885 \family sans
10886 SCENE
10887 \begin_inset space \hfill{}
10888 \end_inset
10889
10890 M-z S-S
10891 \begin_inset Newline newline
10892 \end_inset
10893
10894
10895 \family default
10896 Not automatically numbered.
10897  You supply the number.
10898  This is because I couldn't figure out how.
10899 \end_layout
10900
10901 \begin_layout Itemize
10902
10903 \family sans
10904 AT_RISE:
10905 \begin_inset space \hfill{}
10906 \end_inset
10907
10908 M-z S-R
10909 \begin_inset Newline newline
10910 \end_inset
10911
10912
10913 \family default
10914 A special case of Narrative to describe the setting and action as the curtain
10915  rises.
10916 \end_layout
10917
10918 \begin_layout Itemize
10919
10920 \family sans
10921 Speaker
10922 \begin_inset space \hfill{}
10923 \end_inset
10924
10925 M-z s
10926 \begin_inset Newline newline
10927 \end_inset
10928
10929
10930 \family default
10931 The speaker's (actor's) title, centered in all CAPS.
10932 \end_layout
10933
10934 \begin_layout Itemize
10935
10936 \family sans
10937 Parenthetical
10938 \begin_inset space \hfill{}
10939 \end_inset
10940
10941 M-z p
10942 \begin_inset Newline newline
10943 \end_inset
10944
10945
10946 \family default
10947 Instructions to the speaker.
10948  The parentheses are automatically inserted.
10949  The ( will appear on screen, but both will be in the printed play.
10950  This environment is only used within 
10951 \family sans
10952 Dialogue
10953 \family default
10954 .
10955 \end_layout
10956
10957 \begin_layout Itemize
10958
10959 \family sans
10960 Dialogue
10961 \begin_inset space \hfill{}
10962 \end_inset
10963
10964 M-z d
10965 \begin_inset Newline newline
10966 \end_inset
10967
10968
10969 \family default
10970 What the Speaker says.
10971 \end_layout
10972
10973 \begin_layout Itemize
10974
10975 \family sans
10976 CURTAIN
10977 \begin_inset space \hfill{}
10978 \end_inset
10979
10980 M-z S-C
10981 \begin_inset Newline newline
10982 \end_inset
10983
10984
10985 \family default
10986 The curtain comes down.
10987 \end_layout
10988
10989 \begin_layout Itemize
10990
10991 \family sans
10992 Title
10993 \begin_inset space \hfill{}
10994 \end_inset
10995
10996 M-z S-T
10997 \end_layout
10998
10999 \begin_layout Itemize
11000
11001 \family sans
11002 Author
11003 \begin_inset space \hfill{}
11004 \end_inset
11005
11006 M-z S-A
11007 \end_layout
11008
11009 \begin_layout Itemize
11010
11011 \family sans
11012 Right_Address
11013 \begin_inset space \hfill{}
11014 \end_inset
11015
11016 M-z r
11017 \end_layout
11018
11019 \begin_layout Standard
11020 Hello there.
11021 \end_layout
11022
11023 \begin_layout Section
11024 Dinbrief
11025 \end_layout
11026
11027 \begin_layout Standard
11028 The document class 
11029 \family sans
11030 dinbrief
11031 \family default
11032  can be used to type letters according to German conventions.
11033  A template file is included in 
11034 \family typewriter
11035 .../lyx/share/templates
11036 \family default
11037  for you to use as a starting point.
11038 \end_layout
11039
11040 \begin_layout Section
11041 Elsevier Journals
11042 \end_layout
11043
11044 \begin_layout Standard
11045 See the \SpecialChar LyX
11046  template file 
11047 \family typewriter
11048 elsarticle.lyx
11049 \family default
11050 .
11051  It contains all infos you need.
11052 \end_layout
11053
11054 \begin_layout Section
11055 Foils [aka 
11056 \family sans
11057 Foil\SpecialChar TeX
11058
11059 \family default
11060 ]
11061 \begin_inset CommandInset label
11062 LatexCommand label
11063 name "sec:foiltex"
11064
11065 \end_inset
11066
11067
11068 \end_layout
11069
11070 \begin_layout Standard
11071 by 
11072 \noun on
11073 Allan Rae
11074 \end_layout
11075
11076 \begin_layout Subsection
11077 Introduction
11078 \end_layout
11079
11080 \begin_layout Standard
11081 This section describes how to use \SpecialChar LyX
11082  to make slides for overhead projectors.
11083  There are two document classes that can do this: the default slides class
11084  and the 
11085 \family sans
11086 Foil\SpecialChar TeX
11087
11088 \family default
11089  slides class.
11090  This section documents the latter.
11091 \end_layout
11092
11093 \begin_layout Standard
11094 I'm going to say this again, nice and clear, so that there's no misunderstanding
11095 :
11096 \end_layout
11097
11098 \begin_layout Standard
11099 \begin_inset VSpace bigskip
11100 \end_inset
11101
11102
11103 \end_layout
11104
11105 \begin_layout Standard
11106 \align center
11107
11108 \size large
11109 This section documents the class 
11110 \begin_inset Quotes eld
11111 \end_inset
11112
11113
11114 \family sans
11115 FoilTeX
11116 \family default
11117
11118 \begin_inset Quotes erd
11119 \end_inset
11120
11121  
11122 \emph on
11123 only.
11124 \end_layout
11125
11126 \begin_layout Standard
11127 \begin_inset VSpace bigskip
11128 \end_inset
11129
11130
11131 \end_layout
11132
11133 \begin_layout Standard
11134 If you're looking for the documentation for 
11135 \begin_inset Quotes eld
11136 \end_inset
11137
11138
11139 \family sans
11140 slides (default)
11141 \family default
11142
11143 \begin_inset Quotes erd
11144 \end_inset
11145
11146 , check out section
11147 \begin_inset space ~
11148 \end_inset
11149
11150
11151 \begin_inset CommandInset ref
11152 LatexCommand ref
11153 reference "sec:slitex"
11154
11155 \end_inset
11156
11157 .
11158  If your machine doesn't have the 
11159 \family sans
11160 foils
11161 \family default
11162  class 
11163 \family sans
11164 FoilTeX
11165 \family default
11166  installed, you'll probably have to use the default 
11167 \family sans
11168 slides
11169 \family default
11170  class, which isn't quite as good as 
11171 \family sans
11172 foils.
11173 \end_layout
11174
11175 \begin_layout Standard
11176 The 
11177 \family sans
11178 foils
11179 \family default
11180  class is designed for use with version
11181 \begin_inset space ~
11182 \end_inset
11183
11184 2.1 of the 
11185 \family sans
11186 foils.cls
11187 \family default
11188  \SpecialChar LaTeX
11189  class file which is now an integral part of \SpecialChar LaTeX2e
11190 .
11191 \end_layout
11192
11193 \begin_layout Subsection
11194 Getting Started
11195 \end_layout
11196
11197 \begin_layout Standard
11198 Obviously, to use this document class, you need to select 
11199 \family sans
11200 FoilTeX
11201 \family default
11202  from the 
11203 \family sans
11204 Class
11205 \family default
11206  entry in the 
11207 \family sans
11208 Document
11209 \begin_inset space ~
11210 \end_inset
11211
11212 Layout
11213 \family default
11214  dialog.
11215  There are some settings in the 
11216 \family sans
11217 Document
11218 \begin_inset space ~
11219 \end_inset
11220
11221 Layout
11222 \family default
11223  dialog that you should know about that are specific to this class:
11224 \end_layout
11225
11226 \begin_layout Itemize
11227 Don't change the options 
11228 \family sans
11229 Sides
11230 \family default
11231  and 
11232 \family sans
11233 Columns
11234 \family default
11235  on the 
11236 \family sans
11237 Document
11238 \begin_inset space ~
11239 \end_inset
11240
11241 Layout
11242 \family default
11243  dialog.
11244  They're ignored by the 
11245 \family sans
11246 foils
11247 \family default
11248  class.
11249 \end_layout
11250
11251 \begin_layout Itemize
11252 The default font size is 20
11253 \begin_inset space \thinspace{}
11254 \end_inset
11255
11256 pt with the other options being 17
11257 \begin_inset space \thinspace{}
11258 \end_inset
11259
11260 pt, 25
11261 \begin_inset space \thinspace{}
11262 \end_inset
11263
11264 pt and 30
11265 \begin_inset space \thinspace{}
11266 \end_inset
11267
11268 pt.
11269 \end_layout
11270
11271 \begin_layout Itemize
11272 The default font is 
11273 \family sans
11274 sans
11275 \family default
11276  
11277 \family sans
11278 serif
11279 \family default
11280  but all math equations are still typeset in the usual roman font.
11281 \end_layout
11282
11283 \begin_layout Itemize
11284
11285 \family sans
11286 Foil\SpecialChar TeX
11287
11288 \family default
11289  supports A4 and Letter paper sizes as well as a special size for working
11290  with 35
11291 \begin_inset space \thinspace{}
11292 \end_inset
11293
11294 mm slides.
11295  It doesn't support A5, B5, legal or executive paper sizes.
11296 \end_layout
11297
11298 \begin_layout Itemize
11299 Don't bother changing the 
11300 \family sans
11301 Float Placement
11302 \family default
11303  settings because they are ignored anyway.
11304  All floats appear where they are defined in the text.
11305 \end_layout
11306
11307 \begin_layout Itemize
11308 The 
11309 \family sans
11310 Pagestyle
11311 \family default
11312  setting behaves a bit differently for this class.
11313  
11314 \family sans
11315 Foil\SpecialChar TeX
11316
11317 \family default
11318  provides extensive footer and header capabilities including a user-defined
11319  logo.
11320  See section
11321 \begin_inset space ~
11322 \end_inset
11323
11324
11325 \begin_inset CommandInset ref
11326 LatexCommand ref
11327 reference "sec:foilfoot"
11328
11329 \end_inset
11330
11331  for more details.
11332  The title page is treated differently to all other pages in the document
11333  and is 
11334 \emph on
11335 always
11336 \emph default
11337  unnumbered and 
11338 \emph on
11339 always
11340 \emph default
11341  has the logo centered at the bottom of the page (if one is defined).
11342  The possible page style choices and what they do are as follows:
11343 \end_layout
11344
11345 \begin_deeper
11346 \begin_layout Labeling
11347 \labelwidthstring MMMMMMM
11348
11349 \family sans
11350 \series bold
11351 empty
11352 \family default
11353 \series default
11354  The final output contains no page numbers, or other headers or footers
11355  (except footnotes of course).
11356  
11357 \end_layout
11358
11359 \begin_layout Labeling
11360 \labelwidthstring MMMMMMM
11361
11362 \family sans
11363 \series bold
11364 plain
11365 \family default
11366 \series default
11367  The final output contains page numbers centered at the bottom of the page.
11368  No other headings or footers (other than footnotes).
11369 \end_layout
11370
11371 \begin_layout Labeling
11372 \labelwidthstring MMMMMMM
11373
11374 \series bold
11375 foilheadings
11376 \series default
11377  Page numbers in lower right corner.
11378  Additional headers and footers are also shown.
11379  This is also the default.
11380 \end_layout
11381
11382 \begin_layout Labeling
11383 \labelwidthstring MMMMMMM
11384
11385 \series bold
11386 fancy
11387 \series default
11388  Gives you access to the 
11389 \family sans
11390 fancyheadings
11391 \family default
11392  package although its use with 
11393 \family sans
11394 Foil\SpecialChar TeX
11395
11396 \family default
11397  is discouraged by the writer of the 
11398 \family sans
11399 Foil\SpecialChar TeX
11400
11401 \family default
11402  package because of some potential page layout clashes.
11403 \end_layout
11404
11405 \end_deeper
11406 \begin_layout Subsubsection
11407 Extra Options
11408 \end_layout
11409
11410 \begin_layout Standard
11411 The following options may be used in the extra class options in the 
11412 \family sans
11413 Document\SpecialChar menuseparator
11414 Settings
11415 \family default
11416  dialog.
11417 \end_layout
11418
11419 \begin_layout Labeling
11420 \labelwidthstring MMMMMMx
11421
11422 \series bold
11423 35mmSlide
11424 \series default
11425  This sets up the page layout for 7.33
11426 \begin_inset space \thinspace{}
11427 \end_inset
11428
11429 in by 11
11430 \begin_inset space \thinspace{}
11431 \end_inset
11432
11433 in paper, which is about the same aspect ratio as a 35
11434 \begin_inset space \thinspace{}
11435 \end_inset
11436
11437 mm slide, making it a bit easier to work with this medium.
11438 \end_layout
11439
11440 \begin_layout Labeling
11441 \labelwidthstring MMMMMMx
11442
11443 \series bold
11444 headrule
11445 \series default
11446  Places a rule across the page below the header on every page except the
11447  title page.
11448 \end_layout
11449
11450 \begin_layout Labeling
11451 \labelwidthstring MMMMMMx
11452
11453 \series bold
11454 footrule
11455 \series default
11456  Places a rule across the page above the footer on every page except the
11457  title page.
11458 \end_layout
11459
11460 \begin_layout Labeling
11461 \labelwidthstring MMMMMMx
11462
11463 \series bold
11464 dvips
11465 \series default
11466  This is automatically set each time you create a new 
11467 \family sans
11468 foils
11469 \family default
11470  document.
11471  This option tells 
11472 \family sans
11473 Foil\SpecialChar TeX
11474
11475 \family default
11476  to use the dvips driver to rotate those pages that are set as landscape
11477  foils.
11478 \end_layout
11479
11480 \begin_layout Labeling
11481 \labelwidthstring MMMMMMx
11482
11483 \series bold
11484 landscape
11485 \series default
11486  Simply changes the page dimensions to those of a landscape page but doesn't
11487  do any rotation.
11488  Thus if you use this option you need to use an external program to rotate
11489  each page or feed your paper through your printer as landscape.
11490  Note that this option effectively reverses the roles of the 
11491 \family sans
11492 Foilhead
11493 \family default
11494  and 
11495 \family sans
11496 Rotatefoilhead
11497 \family default
11498  environments (don't worry these are described in the next section).
11499 \end_layout
11500
11501 \begin_layout Labeling
11502 \labelwidthstring MMMMMMx
11503
11504 \series bold
11505 leqno
11506 \series default
11507  Equation numbers on the left.
11508 \end_layout
11509
11510 \begin_layout Labeling
11511 \labelwidthstring MMMMMMx
11512
11513 \series bold
11514 fleqn
11515 \series default
11516  Flush-left equations.
11517 \end_layout
11518
11519 \begin_layout Subsection
11520 Supported Environments
11521 \end_layout
11522
11523 \begin_layout Standard
11524 Most of the environments commonly supported in other classes are also supported
11525  by the 
11526 \family sans
11527 foils
11528 \family default
11529  class.
11530  There are several additional environments provided by 
11531 \family sans
11532 Foil\SpecialChar TeX
11533
11534 \family default
11535  as well as a couple added by \SpecialChar LyX
11536 .
11537  The following environments are shared with other classes:
11538 \end_layout
11539
11540 \begin_layout Standard
11541 \begin_inset Flex Multiple Columns
11542 status open
11543
11544 \begin_layout Itemize
11545
11546 \family sans
11547 Standard
11548 \end_layout
11549
11550 \begin_layout Itemize
11551
11552 \family sans
11553 Itemize
11554 \end_layout
11555
11556 \begin_layout Itemize
11557
11558 \family sans
11559 Enumerate
11560 \end_layout
11561
11562 \begin_layout Itemize
11563
11564 \family sans
11565 Description
11566 \end_layout
11567
11568 \begin_layout Itemize
11569
11570 \family sans
11571 List
11572 \end_layout
11573
11574 \begin_layout Itemize
11575
11576 \family sans
11577 \SpecialChar LyX
11578 -Code
11579 \end_layout
11580
11581 \begin_layout Itemize
11582
11583 \family sans
11584 Verse
11585 \end_layout
11586
11587 \begin_layout Itemize
11588
11589 \family sans
11590 Quote
11591 \end_layout
11592
11593 \begin_layout Itemize
11594
11595 \family sans
11596 Quotation
11597 \end_layout
11598
11599 \begin_layout Itemize
11600
11601 \family sans
11602 TitleAuthor
11603 \end_layout
11604
11605 \begin_layout Itemize
11606
11607 \family sans
11608 Date
11609 \end_layout
11610
11611 \begin_layout Itemize
11612
11613 \family sans
11614 Abstract
11615 \end_layout
11616
11617 \begin_layout Itemize
11618
11619 \family sans
11620 Bibliography
11621 \end_layout
11622
11623 \begin_layout Itemize
11624
11625 \family sans
11626 Address
11627 \end_layout
11628
11629 \begin_layout Itemize
11630
11631 \family sans
11632 RightAddress
11633 \end_layout
11634
11635 \end_inset
11636
11637
11638 \end_layout
11639
11640 \begin_layout Standard
11641 That is, all the major environments apart from the sectioning environments.
11642  Since foils are essentially self-contained sections, with a title and body,
11643  
11644 \family sans
11645 Foil\SpecialChar TeX
11646
11647 \family default
11648  provides specific commands for starting new foils and these are:
11649 \end_layout
11650
11651 \begin_layout Itemize
11652
11653 \family sans
11654 Foilhead
11655 \end_layout
11656
11657 \begin_layout Itemize
11658
11659 \family sans
11660 Rotatefoilhead
11661 \end_layout
11662
11663 \begin_layout Standard
11664 \SpecialChar LyX
11665  also provides slightly modified versions of these two environments called:
11666 \end_layout
11667
11668 \begin_layout Itemize
11669
11670 \family sans
11671 ShortFoilhead
11672 \end_layout
11673
11674 \begin_layout Itemize
11675
11676 \family sans
11677 ShortRotatefoilhead
11678 \end_layout
11679
11680 \begin_layout Standard
11681 and the differences will be explained in the next section.
11682 \end_layout
11683
11684 \begin_layout Standard
11685 Since foils are often used in presenting ideas or new theorems and such
11686  
11687 \family sans
11688 Foil\SpecialChar TeX
11689
11690 \family default
11691  also provides a comprehensive box of goodies for presenting them:
11692 \end_layout
11693
11694 \begin_layout Standard
11695 \begin_inset Flex Multiple Columns
11696 status open
11697
11698 \begin_layout Itemize
11699
11700 \family sans
11701 Theorem
11702 \end_layout
11703
11704 \begin_layout Itemize
11705
11706 \family sans
11707 Lemma
11708 \end_layout
11709
11710 \begin_layout Itemize
11711
11712 \family sans
11713 Corollary
11714 \end_layout
11715
11716 \begin_layout Itemize
11717
11718 \family sans
11719 Proposition
11720 \end_layout
11721
11722 \begin_layout Itemize
11723
11724 \family sans
11725 Definition
11726 \end_layout
11727
11728 \begin_layout Itemize
11729
11730 \family sans
11731 Proof
11732 \end_layout
11733
11734 \begin_layout Itemize
11735
11736 \family sans
11737 Theorem*
11738 \end_layout
11739
11740 \begin_layout Itemize
11741
11742 \family sans
11743 Lemma*
11744 \end_layout
11745
11746 \begin_layout Itemize
11747
11748 \family sans
11749 Corollary*
11750 \end_layout
11751
11752 \begin_layout Itemize
11753
11754 \family sans
11755 Proposition*
11756 \end_layout
11757
11758 \begin_layout Itemize
11759
11760 \family sans
11761 Definition*
11762 \end_layout
11763
11764 \end_inset
11765
11766
11767 \end_layout
11768
11769 \begin_layout Standard
11770 The starred versions are unnumbered while the unstarred versions are numbered.
11771  There are also two list environments added by \SpecialChar LyX
11772  and these are:
11773 \end_layout
11774
11775 \begin_layout Itemize
11776
11777 \family sans
11778 TickList
11779 \end_layout
11780
11781 \begin_layout Itemize
11782
11783 \family sans
11784 CrossList
11785 \end_layout
11786
11787 \begin_layout Standard
11788
11789 \family sans
11790 Foil\SpecialChar TeX
11791
11792 \family default
11793  provides some powerful header and footer capabilities that are best set
11794  in the preamble although they may be set at any point in a document.
11795  If you want to change these settings in your document the best place to
11796  do so is at the very top of a foil, i.
11797 \begin_inset space \thinspace{}
11798 \end_inset
11799
11800 e.
11801 \emph on
11802
11803 \begin_inset space \space{}
11804 \end_inset
11805
11806
11807 \emph default
11808 straight after the foilhead.
11809 \end_layout
11810
11811 \begin_layout Standard
11812 For this purpose, the following command styles are provided [
11813 \shape smallcaps
11814 Martin Vermeer
11815 \shape default
11816 ]:
11817 \end_layout
11818
11819 \begin_layout Standard
11820 \begin_inset Flex Multiple Columns
11821 status open
11822
11823 \begin_layout Itemize
11824
11825 \family sans
11826 My
11827 \begin_inset space ~
11828 \end_inset
11829
11830 Logo
11831 \end_layout
11832
11833 \begin_layout Itemize
11834
11835 \family sans
11836 Restriction
11837 \end_layout
11838
11839 \begin_layout Itemize
11840
11841 \family sans
11842 Right
11843 \begin_inset space ~
11844 \end_inset
11845
11846 Footer
11847 \end_layout
11848
11849 \begin_layout Itemize
11850
11851 \family sans
11852 Right
11853 \begin_inset space ~
11854 \end_inset
11855
11856 Header
11857 \end_layout
11858
11859 \begin_layout Itemize
11860
11861 \family sans
11862 Left
11863 \begin_inset space ~
11864 \end_inset
11865
11866 Header
11867 \end_layout
11868
11869 \begin_deeper
11870 \begin_layout Plain Layout
11871 \begin_inset space ~
11872 \end_inset
11873
11874
11875 \end_layout
11876
11877 \end_deeper
11878 \end_inset
11879
11880
11881 \end_layout
11882
11883 \begin_layout Standard
11884 There are also a few commands provided by 
11885 \family sans
11886 Foil\SpecialChar TeX
11887
11888 \family default
11889  that aren't directly supported by \SpecialChar LyX
11890  but I'll tell you what they do and how
11891  to use them in section
11892 \begin_inset space ~
11893 \end_inset
11894
11895
11896 \begin_inset CommandInset ref
11897 LatexCommand ref
11898 reference "sec:unsuppfoils"
11899
11900 \end_inset
11901
11902 .
11903 \end_layout
11904
11905 \begin_layout Subsection
11906 Building a Set of Foils
11907 \end_layout
11908
11909 \begin_layout Standard
11910 This section will give a simple introduction to using the different environments
11911  to build a set of foils.
11912  If you want to see an example set of foils, take a look at the 
11913 \family typewriter
11914 Foils.lyx
11915 \family default
11916  file you find in \SpecialChar LyX
11917 's 
11918 \family typewriter
11919 examples
11920 \family default
11921  folder.
11922 \end_layout
11923
11924 \begin_layout Subsubsection
11925 Give It a Title Page
11926 \end_layout
11927
11928 \begin_layout Standard
11929 Unlike other classes that provide 
11930 \family sans
11931 Title
11932 \family default
11933
11934 \family sans
11935 Author
11936 \family default
11937
11938 \family sans
11939 Date
11940 \family default
11941  and 
11942 \family sans
11943 Abstract
11944 \family default
11945  environments, 
11946 \family sans
11947 foils
11948 \family default
11949  creates the title on a page of its own.
11950  If you leave out the 
11951 \family sans
11952 Date
11953 \family default
11954  environment \SpecialChar LaTeX
11955  will substitute the current date (every time you regenerate
11956  the output).
11957 \end_layout
11958
11959 \begin_layout Subsubsection
11960 Start a New Foil
11961 \end_layout
11962
11963 \begin_layout Standard
11964 As I mentioned earlier, there are four ways of starting a new foil.
11965  For portrait foils you should use 
11966 \family sans
11967 Foilhead
11968 \family default
11969  or 
11970 \family sans
11971 ShortFoilhead.
11972
11973 \family default
11974  The difference between these two environments is the amount of space between
11975  the title of the foil (the foilhead) and the body of the foil.
11976 \end_layout
11977
11978 \begin_layout Standard
11979 Landscape foils are generated using the 
11980 \family sans
11981 Rotatefoilhead
11982 \family default
11983  and 
11984 \family sans
11985 ShortRotatefoilhead
11986 \family default
11987  environments.
11988  Again the only difference is the spacing between foilhead and body.
11989  Both of the short versions have 0.5
11990 \begin_inset space ~
11991 \end_inset
11992
11993 inches less separation between the foilhead and the body.
11994  
11995 \end_layout
11996
11997 \begin_layout Standard
11998 One problem with the support for landscape foils is the requirement that
11999  you have to use the 
12000 \family typewriter
12001 dvips
12002 \family default
12003  driver to generate the PostScript output otherwise the foils won't be rotated.
12004  It is possible to get landscape foils even if you haven't got the 
12005 \family typewriter
12006 dvips
12007 \family default
12008  driver provided you can feed your foils sideways through your printer ;-)
12009 \end_layout
12010
12011 \begin_layout Subsubsection
12012 Theorems, Lemmas, Proofs and more
12013 \end_layout
12014
12015 \begin_layout Standard
12016 You can't have two of the same type of these environments directly following
12017  each other.
12018  If you use a normal paragraph break, , you will just be extending the previous
12019  environment as if you had merged the two environments together.
12020  Rather than that, you need to insert a so-called separator.
12021  Please refer to the section entitled 
12022 \emph on
12023 Separate Nestings
12024 \emph default
12025  in the 
12026 \emph on
12027 User's Guide
12028 \emph default
12029 .
12030 \end_layout
12031
12032 \begin_layout Subsubsection
12033 Lists
12034 \end_layout
12035
12036 \begin_layout Standard
12037 You get all the commonly supported list styles found in other classes as
12038  well as two new ones.
12039  I'll only describe the new ones here.
12040  If you want to find out more about the other list environments check out
12041  the 
12042 \emph on
12043 User's Guide.
12044
12045 \emph default
12046  If you intend to use itemized lists you might also want to read about the
12047  
12048 \family sans
12049 Itemize
12050 \begin_inset space ~
12051 \end_inset
12052
12053 Bullet
12054 \begin_inset space ~
12055 \end_inset
12056
12057 Selection
12058 \family default
12059  dialog described above in section
12060 \begin_inset space ~
12061 \end_inset
12062
12063
12064 \begin_inset CommandInset ref
12065 LatexCommand ref
12066 reference "sec:bullet"
12067
12068 \end_inset
12069
12070 .
12071 \end_layout
12072
12073 \begin_layout Standard
12074 The two new list styles, 
12075 \family sans
12076 TickList
12077 \family default
12078  and 
12079 \family sans
12080 CrossList
12081 \family default
12082 , are designed to make it easier for you to create lists of do's and don'ts
12083  or right and wrong by providing dedicated environments that use a tick
12084  or a cross as the label of the list.
12085  These lists are in fact dedicated variants of the 
12086 \family sans
12087 Itemize
12088 \family default
12089  environment.
12090  They do however require that you have the 
12091 \family typewriter
12092 psnfss
12093 \family default
12094  packages installed.
12095 \end_layout
12096
12097 \begin_layout Subsubsection
12098 Figures and Tables
12099 \end_layout
12100
12101 \begin_layout Standard
12102
12103 \family sans
12104 Foil\SpecialChar TeX
12105
12106 \family default
12107  redefines the floating tables and figures so that they appear exactly where
12108  they are in the text rather than pushing them to the top of the page or
12109  to some user specified location.
12110  In fact if you change the float placement settings they are simply ignored.
12111 \end_layout
12112
12113 \begin_layout Subsubsection
12114 Page Headers and Footers
12115 \begin_inset CommandInset label
12116 LatexCommand label
12117 name "sec:foilfoot"
12118
12119 \end_inset
12120
12121
12122 \end_layout
12123
12124 \begin_layout Standard
12125
12126 \family sans
12127 My
12128 \begin_inset space ~
12129 \end_inset
12130
12131 Logo
12132 \family default
12133  and 
12134 \family sans
12135 Restriction
12136 \family default
12137  are two commands used to control the left-footer text string.
12138  The first is meant to allow you to include a graphic logo on your foils
12139  and defaults to 
12140 \begin_inset Quotes eld
12141 \end_inset
12142
12143 -Typeset by 
12144 \family sans
12145 Foil\SpecialChar TeX
12146
12147 \family default
12148 -
12149 \begin_inset Quotes erd
12150 \end_inset
12151
12152 .
12153  While the second is meant to provide a classification for the audience,
12154  
12155 \emph on
12156 e.
12157 \begin_inset space \thinspace{}
12158 \end_inset
12159
12160 g.
12161 \emph default
12162
12163 \begin_inset space \space{}
12164 \end_inset
12165
12166 Confidential.
12167  It is empty by default.
12168 \end_layout
12169
12170 \begin_layout Standard
12171 The remaining page corners can be filled by 
12172 \family sans
12173 Right
12174 \begin_inset space ~
12175 \end_inset
12176
12177 Footer
12178 \family default
12179  (which defaults to page numbers), 
12180 \family sans
12181 Right
12182 \begin_inset space ~
12183 \end_inset
12184
12185 Header
12186 \family default
12187  (top right) and 
12188 \family sans
12189 Left
12190 \begin_inset space ~
12191 \end_inset
12192
12193 Header
12194 \family default
12195  (top left).
12196 \end_layout
12197
12198 \begin_layout Subsection
12199 Unsupported 
12200 \family sans
12201 Foil\SpecialChar TeX
12202
12203 \family default
12204  Goodies
12205 \begin_inset CommandInset label
12206 LatexCommand label
12207 name "sec:unsuppfoils"
12208
12209 \end_inset
12210
12211
12212 \end_layout
12213
12214 \begin_layout Standard
12215 All the commands mentioned below need to be set in a 
12216 \family sans
12217 \SpecialChar LaTeX
12218
12219 \family default
12220  environment or as 
12221 \family sans
12222 \SpecialChar TeX
12223
12224 \family default
12225  within another environment.
12226 \end_layout
12227
12228 \begin_layout Subsubsection
12229 Lengths
12230 \end_layout
12231
12232 \begin_layout Standard
12233 All lengths are adjusted using the 
12234 \family typewriter
12235
12236 \backslash
12237 setlength{
12238 \family default
12239 \emph on
12240 lengthname
12241 \family typewriter
12242 \emph default
12243 }{
12244 \family default
12245 \emph on
12246 newlength
12247 \family typewriter
12248 \emph default
12249 }
12250 \family default
12251  command.
12252  Where 
12253 \emph on
12254 lengthname
12255 \emph default
12256  should be replaced by the name given to the length you want to change and
12257  
12258 \emph on
12259 newlength
12260 \emph default
12261  is the length value.
12262  All lengths should be specified in units of length such as inches (
12263 \family typewriter
12264 in
12265 \family default
12266 ), millimeters (
12267 \family typewriter
12268 mm
12269 \family default
12270 ) or points (
12271 \family typewriter
12272 pt
12273 \family default
12274 ) or relative to some document or font-based length such as 
12275 \family typewriter
12276
12277 \backslash
12278 textwidth
12279 \family default
12280 .
12281  
12282 \end_layout
12283
12284 \begin_layout Standard
12285 It's possible to change the spacing between a foilhead and the body of the
12286  foil by adjusting the length specified by 
12287 \family typewriter
12288
12289 \backslash
12290 foilheadskip
12291 \family default
12292 .
12293  For example, to make 
12294 \emph on
12295 all
12296 \emph default
12297  foilheads 0.5
12298 \begin_inset space \space{}
12299 \end_inset
12300
12301 in closer to their bodies put the following in the preamble: 
12302 \family typewriter
12303
12304 \backslash
12305 setlength{
12306 \backslash
12307 foilheadskip}{-0.5in}
12308 \end_layout
12309
12310 \begin_layout Standard
12311 The spacings around floats can be adjusted by setting these lengths:
12312 \end_layout
12313
12314 \begin_layout Labeling
12315 \labelwidthstring MMMMMMMMMMM
12316
12317 \family typewriter
12318
12319 \backslash
12320 abovefloatskip
12321 \family default
12322  Separation between the text and the top of the float
12323 \end_layout
12324
12325 \begin_layout Labeling
12326 \labelwidthstring MMMMMMMMMMM
12327
12328 \family typewriter
12329
12330 \backslash
12331 abovecaptionskip
12332 \family default
12333  Separation between the float and the caption
12334 \end_layout
12335
12336 \begin_layout Labeling
12337 \labelwidthstring MMMMMMMMMMM
12338
12339 \family typewriter
12340
12341 \backslash
12342 belowcaptionskip
12343 \family default
12344  Separation between the caption and the following text
12345 \end_layout
12346
12347 \begin_layout Labeling
12348 \labelwidthstring MMMMMMMMMMM
12349
12350 \family typewriter
12351
12352 \backslash
12353 captionwidth
12354 \family default
12355  You can make the captions narrower than the surrounding text by adjusting
12356  this length.
12357  Best done relative to 
12358 \family typewriter
12359
12360 \backslash
12361 textwidth
12362 \family default
12363 .
12364 \end_layout
12365
12366 \begin_layout Standard
12367 There are also several title page related lengths that you may find useful
12368  if you have a long title or several authors:
12369 \end_layout
12370
12371 \begin_layout Labeling
12372 \labelwidthstring MMMMMMMMMMM
12373
12374 \family typewriter
12375
12376 \backslash
12377 abovetitleskip
12378 \family default
12379  Separation from headers to 
12380 \family sans
12381 Title
12382 \end_layout
12383
12384 \begin_layout Labeling
12385 \labelwidthstring MMMMMMMMMMM
12386
12387 \family typewriter
12388
12389 \backslash
12390 titleauthorskip
12391 \family default
12392  between 
12393 \family sans
12394 Title
12395 \family default
12396  and 
12397 \family sans
12398 Author
12399 \family default
12400  environments
12401 \end_layout
12402
12403 \begin_layout Labeling
12404 \labelwidthstring MMMMMMMMMMM
12405
12406 \family typewriter
12407
12408 \backslash
12409 authorauthorskip
12410 \family default
12411  between multiple 
12412 \family sans
12413 Author
12414 \family default
12415  lines
12416 \end_layout
12417
12418 \begin_layout Labeling
12419 \labelwidthstring MMMMMMMMMMM
12420
12421 \family typewriter
12422
12423 \backslash
12424 authordateskip
12425 \family default
12426  between the 
12427 \family sans
12428 Author
12429 \family default
12430  and the 
12431 \family sans
12432 Date
12433 \end_layout
12434
12435 \begin_layout Labeling
12436 \labelwidthstring MMMMMMMMMMM
12437
12438 \family typewriter
12439
12440 \backslash
12441 dateabstractskip
12442 \family default
12443  between the 
12444 \family sans
12445 Date
12446 \family default
12447  and the 
12448 \family sans
12449 Abstract
12450 \end_layout
12451
12452 \begin_layout Standard
12453 The last length related command affects all the list environments.
12454  If you place 
12455 \family typewriter
12456
12457 \backslash
12458 zerolistvertdimens
12459 \family default
12460  
12461 \emph on
12462 inside
12463 \emph default
12464  a list environment then all the vertical spacing between the list items
12465  is removed.
12466  Note that this is a command not a length so it doesn't require 
12467 \family typewriter
12468
12469 \backslash
12470 setlength
12471 \family default
12472  like the stuff mentioned above.
12473 \end_layout
12474
12475 \begin_layout Subsubsection
12476 Headers and Footers
12477 \end_layout
12478
12479 \begin_layout Standard
12480 The 
12481 \family typewriter
12482
12483 \backslash
12484 LogoOn
12485 \family default
12486  and 
12487 \family typewriter
12488
12489 \backslash
12490 LogoOff
12491 \family default
12492  commands control whether the logo in the 
12493 \family sans
12494 MyLogo
12495 \family default
12496  definition appear on a given page.
12497  If you put 
12498 \family typewriter
12499
12500 \backslash
12501 LogoOff
12502 \family default
12503  in the preamble then none of the foils will have the logo on them.
12504  If you don't want the logo on a particular page place the 
12505 \family typewriter
12506
12507 \backslash
12508 LogoOff
12509 \family default
12510  directly after the foilhead of that page and the 
12511 \family typewriter
12512
12513 \backslash
12514 LogoOn
12515 \family default
12516  directly after the next foilhead.
12517 \end_layout
12518
12519 \begin_layout Standard
12520 If you decide to use the 
12521 \family sans
12522 fancy
12523 \family default
12524  page style setting in the 
12525 \family sans
12526 Document
12527 \begin_inset space ~
12528 \end_inset
12529
12530 Layout
12531 \family default
12532  dialog you should probably add 
12533 \family typewriter
12534
12535 \backslash
12536 let
12537 \backslash
12538 headwidth
12539 \backslash
12540 textwidth
12541 \family default
12542  to your preamble so headers and footers on landscape pages are correctly
12543  placed when rotated.
12544  This is due to some clashes between the page layouts provided by the 
12545 \family sans
12546 fancyheadings
12547 \family default
12548  package and the 
12549 \family sans
12550 foils
12551 \family default
12552  class.
12553 \end_layout
12554
12555 \begin_layout Section
12556 Hollywood (Hollywood spec scripts)
12557 \end_layout
12558
12559 \begin_layout Standard
12560 by 
12561 \shape smallcaps
12562 Garst Reese
12563 \end_layout
12564
12565 \begin_layout Subsection
12566 Introduction
12567 \end_layout
12568
12569 \begin_layout Standard
12570 Getting the format of a Hollywood script right is a 
12571 \begin_inset Quotes eld
12572 \end_inset
12573
12574 rite of passage.
12575 \begin_inset Quotes erd
12576 \end_inset
12577
12578  It is designed to make the readers focus on content and to be easy and
12579  familiar for the actors to read.
12580  Each page of a script should be one minute of film.
12581  Nothing goes in a script that you cannot see or hear on screen.
12582  The courier 12 pt font should be used throughout.
12583  No italics.
12584 \end_layout
12585
12586 \begin_layout Subsection
12587 Special problems
12588 \end_layout
12589
12590 \begin_layout Standard
12591 Speakers' lines should NEVER break in mid-sentence.
12592  If a speaker's lines continue over a page break, repeat the 
12593 \family sans
12594 Speaker
12595 \family default
12596  title followed by (Cont'd).
12597 \end_layout
12598
12599 \begin_layout Subsection
12600 Special features
12601 \end_layout
12602
12603 \begin_layout Standard
12604 Insert the 
12605 \family sans
12606 Speaker
12607 \family default
12608  names as labels then cross-reference the label to insert the name.
12609  The cross-reference dialog will show the current cast of characters.
12610  You can use this to insert the speaker name in narratives also.
12611 \end_layout
12612
12613 \begin_layout Subsection
12614 Paper size and Margins
12615 \end_layout
12616
12617 \begin_layout Standard
12618 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
12619 \end_layout
12620
12621 \begin_layout Subsection
12622 Environments
12623 \end_layout
12624
12625 \begin_layout Standard
12626 The following environments are available.
12627  You can use hollywood.bind to get the bind keys shown at the right.
12628 \end_layout
12629
12630 \begin_layout Itemize
12631
12632 \family sans
12633 Standard
12634 \begin_inset Newline newline
12635 \end_inset
12636
12637
12638 \family default
12639 Used where nothing else works.
12640  Try to avoid it.
12641 \end_layout
12642
12643 \begin_layout Itemize
12644
12645 \family sans
12646 FADE_IN
12647 \family default
12648 :
12649 \begin_inset space \hfill{}
12650 \end_inset
12651
12652
12653 \family sans
12654 M-z S-I
12655 \family default
12656
12657 \begin_inset Newline newline
12658 \end_inset
12659
12660 Usually followed by something like 
12661 \begin_inset Quotes eld
12662 \end_inset
12663
12664 on Sally waking up.
12665 \begin_inset Quotes erd
12666 \end_inset
12667
12668
12669 \end_layout
12670
12671 \begin_layout Itemize
12672
12673 \family sans
12674 INT:
12675 \begin_inset space \hfill{}
12676 \end_inset
12677
12678 M-z i
12679 \begin_inset Newline newline
12680 \end_inset
12681
12682
12683 \family default
12684 Introduces a new INTERIOR camera set-up.
12685  Always followed by DAY or NIGHT, or something similar to define the lighting
12686  required.
12687  Everthing on this line in CAPS.
12688 \end_layout
12689
12690 \begin_layout Itemize
12691
12692 \family sans
12693 EXT:
12694 \begin_inset space \hfill{}
12695 \end_inset
12696
12697 M-z e
12698 \begin_inset Newline newline
12699 \end_inset
12700
12701
12702 \family default
12703 Introduces a new EXTERIOR camera set-up.
12704  Everthing on this line in CAPS.
12705 \end_layout
12706
12707 \begin_layout Itemize
12708
12709 \family sans
12710 Speaker
12711 \begin_inset space \hfill{}
12712 \end_inset
12713
12714 M-z s
12715 \begin_inset Newline newline
12716 \end_inset
12717
12718
12719 \family default
12720 The character speaking.
12721 \end_layout
12722
12723 \begin_layout Itemize
12724
12725 \family sans
12726 Parenthetical
12727 \begin_inset space \hfill{}
12728 \end_inset
12729
12730 M-z p
12731 \begin_inset Newline newline
12732 \end_inset
12733
12734
12735 \family default
12736 Instructions to the speaker.
12737  The () are automatically inserted.
12738 \end_layout
12739
12740 \begin_layout Itemize
12741
12742 \family sans
12743 Dialogue
12744 \begin_inset space \hfill{}
12745 \end_inset
12746
12747 M-z d
12748 \begin_inset Newline newline
12749 \end_inset
12750
12751
12752 \family default
12753 What the 
12754 \family sans
12755 Speaker
12756 \family default
12757  says.
12758 \end_layout
12759
12760 \begin_layout Itemize
12761
12762 \family sans
12763 Transition
12764 \begin_inset space \hfill{}
12765 \end_inset
12766
12767 M-z t
12768 \begin_inset Newline newline
12769 \end_inset
12770
12771
12772 \family default
12773 Camera movement instruction.
12774  e.
12775 \begin_inset space \thinspace{}
12776 \end_inset
12777
12778 g.
12779 \begin_inset space \space{}
12780 \end_inset
12781
12782 CUT TO:
12783 \end_layout
12784
12785 \begin_layout Itemize
12786
12787 \family sans
12788 FADE OUT:
12789 \begin_inset space \hfill{}
12790 \end_inset
12791
12792 M-z S-I
12793 \end_layout
12794
12795 \begin_layout Itemize
12796
12797 \family sans
12798 Author
12799 \begin_inset space \hfill{}
12800 \end_inset
12801
12802 M-z S-A
12803 \end_layout
12804
12805 \begin_layout Itemize
12806
12807 \family sans
12808 Title
12809 \begin_inset space \hfill{}
12810 \end_inset
12811
12812 M-z S-T
12813 \end_layout
12814
12815 \begin_layout Itemize
12816
12817 \family sans
12818 Right_Address
12819 \begin_inset space \hfill{}
12820 \end_inset
12821
12822 M-z r
12823 \end_layout
12824
12825 \begin_layout Subsection
12826 Script jargon
12827 \end_layout
12828
12829 \begin_layout Itemize
12830 (O.S) — off screen
12831 \end_layout
12832
12833 \begin_layout Itemize
12834 (V.0) — voice over
12835 \end_layout
12836
12837 \begin_layout Itemize
12838 b.
12839 \begin_inset space \thinspace{}
12840 \end_inset
12841
12842 g.
12843  — background
12844 \end_layout
12845
12846 \begin_layout Itemize
12847 C.U.
12848  — close-up
12849 \end_layout
12850
12851 \begin_layout Itemize
12852 PAN — camera movement
12853 \end_layout
12854
12855 \begin_layout Itemize
12856 INSERT — cut to close-up of
12857 \end_layout
12858
12859 \begin_layout Section
12860 ijmpc and ijmpd
12861 \end_layout
12862
12863 \begin_layout Standard
12864 by 
12865 \noun on
12866 Panayotis Papasotiriou
12867 \end_layout
12868
12869 \begin_layout Subsection
12870 Overview
12871 \end_layout
12872
12873 \begin_layout Standard
12874 The ijmpc package is a set of macros that facilitates electronic manuscript
12875  submission to the 
12876 \emph on
12877 International Journal of Modern Physics C
12878 \emph default
12879 .
12880  Similarly, the ijmpd package is for creating manuscripts to be submitted
12881  to the 
12882 \emph on
12883 International Journal of Modern Physics D
12884 \emph default
12885 .
12886  Both journals are published by World Scientific.
12887  The corresponding document classes are named 
12888 \family typewriter
12889 ws-ijmpc.cls
12890 \family default
12891  and 
12892 \family typewriter
12893 ws-ijmpd.cls
12894 \family default
12895 , respectively.
12896  These files, together with instructions for the authors, can be downloaded
12897  from the sites 
12898 \begin_inset Flex URL
12899 status collapsed
12900
12901 \begin_layout Plain Layout
12902
12903 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
12904 \end_layout
12905
12906 \end_inset
12907
12908  and 
12909 \begin_inset Flex URL
12910 status collapsed
12911
12912 \begin_layout Plain Layout
12913
12914 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
12915 \end_layout
12916
12917 \end_inset
12918
12919 .
12920  Both packages are modified versions of the standard 
12921 \begin_inset Quotes eld
12922 \end_inset
12923
12924 article
12925 \begin_inset Quotes erd
12926 \end_inset
12927
12928  package, and they are almost (but not exactly) identical.
12929  Most of their features are supported by \SpecialChar LyX
12930 .
12931  I have used \SpecialChar LyX
12932  successfully to write articles submitted to both journals
12933  without any problem.
12934 \end_layout
12935
12936 \begin_layout Subsection
12937 Writing a paper
12938 \end_layout
12939
12940 \begin_layout Standard
12941 As usual, the easiest way to write a paper is to start with a template.
12942  Click on 
12943 \family sans
12944 File\SpecialChar menuseparator
12945 New from
12946 \family default
12947  
12948 \family sans
12949 Template
12950 \family default
12951 , then choose the 
12952 \family typewriter
12953 ijmpc.lyx
12954 \family default
12955  or 
12956 \family typewriter
12957 ijmpd.lyx
12958 \family default
12959  template.
12960  This will give an (almost) empty document that includes the most common
12961  fields found in a manuscript.
12962  Simply overwrite the existing text (including the brackets, 
12963 \family typewriter
12964 <>
12965 \family default
12966 ) with your text.
12967  You should keep in mind the following remarks.
12968 \end_layout
12969
12970 \begin_layout Enumerate
12971 \SpecialChar LyX
12972  won't let you change the font size and the page style of the document,
12973  because such modifications are not allowed by both packages.
12974 \end_layout
12975
12976 \begin_layout Enumerate
12977 The language of the document should not be changed.
12978  Before previewing your paper, be sure that the babel package is not used.
12979  To do this, click on 
12980 \begin_inset Info
12981 type  "menu"
12982 arg   "dialog-show document"
12983 \end_inset
12984
12985  
12986 \family sans
12987 \SpecialChar menuseparator
12988 Language
12989 \family default
12990 , and select 
12991 \begin_inset Quotes eld
12992 \end_inset
12993
12994 None
12995 \begin_inset Quotes erd
12996 \end_inset
12997
12998  as 
12999 \family sans
13000 Language Package
13001 \family default
13002 .
13003 \end_layout
13004
13005 \begin_layout Enumerate
13006 The 
13007 \begin_inset Quotes eld
13008 \end_inset
13009
13010 Keywords
13011 \begin_inset Quotes erd
13012 \end_inset
13013
13014  style must be used to define keywords.
13015 \end_layout
13016
13017 \begin_layout Enumerate
13018 The ijmpc package provides a style named 
13019 \begin_inset Quotes eld
13020 \end_inset
13021
13022 Classification Codes
13023 \begin_inset Quotes erd
13024 \end_inset
13025
13026 , which can be used to define classification codes, such as PACS numbers.
13027  Note that this facility is not supported by the ijmpd package.
13028 \end_layout
13029
13030 \begin_layout Enumerate
13031 Several new environments are available: 
13032 \begin_inset Quotes eld
13033 \end_inset
13034
13035 Definition
13036 \begin_inset Quotes erd
13037 \end_inset
13038
13039
13040 \begin_inset Quotes eld
13041 \end_inset
13042
13043 Step
13044 \begin_inset Quotes erd
13045 \end_inset
13046
13047
13048 \begin_inset Quotes eld
13049 \end_inset
13050
13051 Example
13052 \begin_inset Quotes erd
13053 \end_inset
13054
13055
13056 \begin_inset Quotes eld
13057 \end_inset
13058
13059 Remark
13060 \begin_inset Quotes erd
13061 \end_inset
13062
13063
13064 \begin_inset Quotes eld
13065 \end_inset
13066
13067 Notation
13068 \begin_inset Quotes erd
13069 \end_inset
13070
13071
13072 \begin_inset Quotes eld
13073 \end_inset
13074
13075 Theorem
13076 \begin_inset Quotes erd
13077 \end_inset
13078
13079
13080 \begin_inset Quotes eld
13081 \end_inset
13082
13083 Proof
13084 \begin_inset Quotes erd
13085 \end_inset
13086
13087
13088 \begin_inset Quotes eld
13089 \end_inset
13090
13091 Corollary
13092 \begin_inset Quotes erd
13093 \end_inset
13094
13095
13096 \begin_inset Quotes eld
13097 \end_inset
13098
13099 Lemma
13100 \begin_inset Quotes erd
13101 \end_inset
13102
13103
13104 \begin_inset Quotes eld
13105 \end_inset
13106
13107 Proposition
13108 \begin_inset Quotes erd
13109 \end_inset
13110
13111
13112 \begin_inset Quotes eld
13113 \end_inset
13114
13115 Prop
13116 \begin_inset Quotes erd
13117 \end_inset
13118
13119
13120 \begin_inset Quotes eld
13121 \end_inset
13122
13123 Question
13124 \begin_inset Quotes erd
13125 \end_inset
13126
13127
13128 \begin_inset Quotes eld
13129 \end_inset
13130
13131 Claim
13132 \begin_inset Quotes erd
13133 \end_inset
13134
13135 , and 
13136 \begin_inset Quotes eld
13137 \end_inset
13138
13139 Conjecture
13140 \begin_inset Quotes erd
13141 \end_inset
13142
13143 .
13144  Their use is more or less obvious.
13145  \SpecialChar LyX
13146  supports all these environments; it will use the proper label, text style,
13147  and numbering scheme for each of them.
13148 \end_layout
13149
13150 \begin_layout Enumerate
13151 Both packages use basic citations; the natbib package should not be used.
13152  In \SpecialChar LyX
13153 , citation references are shown as usual; in the output, citations are
13154  shown as superscripts.
13155  If you want to use a citation as normal text, you should use the 
13156 \family typewriter
13157 refcite
13158 \family default
13159  command, e.
13160 \begin_inset space \thinspace{}
13161 \end_inset
13162
13163 g.
13164 \begin_inset space \space{}
13165 \end_inset
13166
13167
13168 \begin_inset Quotes eld
13169 \end_inset
13170
13171 See Ref.
13172 \begin_inset space \space{}
13173 \end_inset
13174
13175
13176 \family typewriter
13177
13178 \backslash
13179 refcite{key}
13180 \family default
13181
13182 \begin_inset Quotes erd
13183 \end_inset
13184
13185 .
13186 \end_layout
13187
13188 \begin_layout Enumerate
13189 There is no 
13190 \begin_inset Quotes eld
13191 \end_inset
13192
13193 Acknowledgments
13194 \begin_inset Quotes erd
13195 \end_inset
13196
13197  section in both packages.
13198  To put acknowledgments, just use the 
13199 \begin_inset Quotes eld
13200 \end_inset
13201
13202 Section*
13203 \begin_inset Quotes erd
13204 \end_inset
13205
13206  environment.
13207 \end_layout
13208
13209 \begin_layout Enumerate
13210 Appendices may be added to the paper, 
13211 \emph on
13212 after
13213 \emph default
13214  the Acknowledgments and 
13215 \shape italic
13216 before
13217 \shape default
13218  the References.
13219  \SpecialChar LyX
13220  provides a special environment, called 
13221 \begin_inset Quotes eld
13222 \end_inset
13223
13224 Appendices Section
13225 \begin_inset Quotes erd
13226 \end_inset
13227
13228  which marks the beginning of the appendices.
13229  This environment should be left blank; it just sends a \SpecialChar LaTeX
13230  command, but nothing
13231  is really printed.
13232  In \SpecialChar LyX
13233 , the word 
13234 \begin_inset Quotes eld
13235 \end_inset
13236
13237 Appendix
13238 \begin_inset Quotes erd
13239 \end_inset
13240
13241  is printed with blue letters, as a signal that all sections after that
13242  point are appendices.
13243  To write an appendix, use the 
13244 \begin_inset Quotes eld
13245 \end_inset
13246
13247 Appendix
13248 \begin_inset Quotes erd
13249 \end_inset
13250
13251  environment.
13252  \SpecialChar LyX
13253  will number each appendix with capital letters, as required by both journals.
13254  Note that 
13255 \begin_inset Quotes eld
13256 \end_inset
13257
13258 Appendices Section
13259 \begin_inset Quotes erd
13260 \end_inset
13261
13262  
13263 \emph on
13264 must
13265 \emph default
13266  be present before the first appendix; if not, all appendices will be numbered
13267  as normal sections in the output.
13268 \end_layout
13269
13270 \begin_layout Enumerate
13271 The ijmpc and the ijmpd packages use the 
13272 \family typewriter
13273 tbl
13274 \family default
13275  command to implement table captions.
13276  As a result, a table created by \SpecialChar LyX
13277  is printed correctly, but its caption
13278  is ignored.
13279  However, you can use some \SpecialChar TeX
13280  code to overcome this problem, so that captions
13281  are printed as expected.
13282  To do so, create a float table as usual, remove the caption, and replace
13283  it with the \SpecialChar TeX
13284  code 
13285 \family typewriter
13286
13287 \backslash
13288 tbl{
13289 \emph on
13290 your table caption
13291 \emph default
13292 }{
13293 \family default
13294  (sic); you must also the \SpecialChar TeX
13295  code 
13296 \family typewriter
13297 }
13298 \family default
13299  immediately after the tabular material.
13300  Study the example table included in the template files to see how this
13301  trick is implemented.
13302  Alternatively, If you need table captions, you should implement the whole
13303  table float in a 
13304 \family typewriter
13305 .tex
13306 \family default
13307  file, then include this file to the \SpecialChar LyX
13308  document (
13309 \family sans
13310 Insert\SpecialChar menuseparator
13311 File\SpecialChar menuseparator
13312 Child
13313 \begin_inset space ~
13314 \end_inset
13315
13316 Document
13317 \family default
13318 ).
13319  Details on how to create a table float can be found in the files 
13320 \family typewriter
13321 ws-ijmpc.tex
13322 \family default
13323  and 
13324 \family typewriter
13325 ws-ijmpd.tex
13326 \family default
13327 , included in the corresponding packages.
13328 \end_layout
13329
13330 \begin_layout Subsection
13331 Preparing a paper for submission
13332 \end_layout
13333
13334 \begin_layout Standard
13335 Before you submit your paper you must export the \SpecialChar LyX
13336  document as a \SpecialChar LaTeX
13337  file (
13338 \family sans
13339 File\SpecialChar menuseparator
13340 Export\SpecialChar menuseparator
13341 \SpecialChar LaTeX
13342
13343 \family default
13344 )
13345 \begin_inset Foot
13346 status open
13347
13348 \begin_layout Plain Layout
13349 Actually you have the choice between \SpecialChar LaTeX
13350  (plain) and pdflatex.
13351  If you intend to use pdflatex to prepare the paper, you should use the
13352  pdflatex option so that included graphics are converted to PDF format,
13353  ready for use by pdflatex.
13354 \end_layout
13355
13356 \end_inset
13357
13358 , then make the following changes to the resulting 
13359 \family typewriter
13360 .tex
13361 \family default
13362  file.
13363 \end_layout
13364
13365 \begin_layout Enumerate
13366 Remove the comment lines before the 
13367 \family typewriter
13368
13369 \backslash
13370 documentclass
13371 \family default
13372  command.
13373 \end_layout
13374
13375 \begin_layout Enumerate
13376 Remove everything between (and including) the 
13377 \family typewriter
13378
13379 \backslash
13380 makeatletter
13381 \family default
13382  and 
13383 \family typewriter
13384
13385 \backslash
13386 makeatother
13387 \family default
13388  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13389  preamble.
13390 \end_layout
13391
13392 \begin_layout Standard
13393 The modified 
13394 \family typewriter
13395 .tex
13396 \family default
13397  file should be saved and processed through \SpecialChar LaTeX
13398  as many times as necessary.
13399  You may also want to check the resulting 
13400 \family typewriter
13401 .dvi
13402 \family default
13403  document.
13404 \end_layout
13405
13406 \begin_layout Section
13407 iopart
13408 \end_layout
13409
13410 \begin_layout Standard
13411 by 
13412 \noun on
13413 Uwe Stöhr
13414 \end_layout
13415
13416 \begin_layout Subsection
13417 Overview
13418 \end_layout
13419
13420 \begin_layout Standard
13421 The iopart package provides a document class to create electronic manuscript
13422  submission to the journals published by the Institute of Physics.
13423  Instructions for the authors how to create a paper using the iopart class
13424  can be downloaded together with the iopart package from the site 
13425 \begin_inset Flex URL
13426 status collapsed
13427
13428 \begin_layout Plain Layout
13429
13430 ftp://ftp.iop.org/pub/journals/latex2e
13431 \end_layout
13432
13433 \end_inset
13434
13435 .
13436 \end_layout
13437
13438 \begin_layout Subsection
13439 Writing a paper
13440 \end_layout
13441
13442 \begin_layout Standard
13443 The easiest way to write a paper is to start with the template 
13444 \emph on
13445 IOP-article.lyx
13446 \emph default
13447  that is available via 
13448 \family sans
13449 File\SpecialChar menuseparator
13450 New From Template
13451 \family default
13452  The template explains how to use the special text environments.
13453  Here are the most important advices:
13454 \end_layout
13455
13456 \begin_layout Itemize
13457 To be able to compile your document to a PDF, PS, or DVI, ensure that the
13458  no AMS packages are loaded in 
13459 \family sans
13460 Document\SpecialChar menuseparator
13461 Settings\SpecialChar menuseparator
13462 Math Options
13463 \family default
13464 !
13465 \end_layout
13466
13467 \begin_layout Itemize
13468
13469 \size normal
13470 The title environment defines the kind of your paper.
13471  So use one of the following environments for the title:
13472 \end_layout
13473
13474 \begin_deeper
13475 \begin_layout Itemize
13476
13477 \family sans
13478 \size normal
13479 Title
13480 \family default
13481  for a Paper
13482 \end_layout
13483
13484 \begin_layout Itemize
13485
13486 \family sans
13487 \size normal
13488 Review
13489 \family default
13490  for a Review
13491 \end_layout
13492
13493 \begin_layout Itemize
13494
13495 \family sans
13496 \size normal
13497 Topical
13498 \family default
13499  for a Topical review
13500 \end_layout
13501
13502 \begin_layout Itemize
13503
13504 \family sans
13505 \size normal
13506 Comment
13507 \family default
13508  for a Comment
13509 \end_layout
13510
13511 \begin_layout Itemize
13512
13513 \family sans
13514 \size normal
13515 Note
13516 \family default
13517  for a Note
13518 \end_layout
13519
13520 \begin_layout Itemize
13521
13522 \family sans
13523 \size normal
13524 Paper
13525 \family default
13526  for a Paper (same as Title)
13527 \end_layout
13528
13529 \begin_layout Itemize
13530
13531 \family sans
13532 \size normal
13533 Prelim
13534 \family default
13535  for a Preliminary communication
13536 \end_layout
13537
13538 \begin_layout Itemize
13539
13540 \family sans
13541 \size normal
13542 Rapid
13543 \family default
13544  for a Rapid communication
13545 \end_layout
13546
13547 \begin_layout Itemize
13548
13549 \family sans
13550 \size normal
13551 Letter
13552 \family default
13553  for a Letter to the editor
13554 \end_layout
13555
13556 \end_deeper
13557 \begin_layout Itemize
13558
13559 \size normal
13560 All title environments except of 
13561 \family sans
13562 Letter
13563 \family default
13564  can have an optional short title.
13565 \end_layout
13566
13567 \begin_layout Itemize
13568 There is a general title environment 
13569 \family sans
13570 Article
13571 \family default
13572  which is not directly supported by \SpecialChar LyX
13573 .
13574  This can be used as \SpecialChar TeX
13575  code when your document doesn't fit into one of the
13576  other title types.
13577 \end_layout
13578
13579 \begin_layout Standard
13580 For more informations like hints for special table and formula formatting,
13581  look at the IOP author guidelines.
13582 \end_layout
13583
13584 \begin_layout Section
13585 Kluwer
13586 \end_layout
13587
13588 \begin_layout Standard
13589 by 
13590 \noun on
13591 Panayotis Papasotiriou
13592 \end_layout
13593
13594 \begin_layout Subsection
13595 Overview
13596 \end_layout
13597
13598 \begin_layout Standard
13599 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
13600  that facilitates electronic manuscript submission to the journals they
13601  publish.
13602  Most known of them (at least in my domain of interest) are 
13603 \emph on
13604 Astrophysics and Space Science
13605 \emph default
13606  and 
13607 \emph on
13608 Solar Physics
13609 \emph default
13610 , but there are many others (see a complete list at 
13611 \begin_inset Flex URL
13612 status collapsed
13613
13614 \begin_layout Plain Layout
13615
13616 http://www.wkap.nl/jrnllist.htm/JRNLHOME
13617 \end_layout
13618
13619 \end_inset
13620
13621 ).
13622  The Kluwer package may be downloaded from the site 
13623 \begin_inset Flex URL
13624 status collapsed
13625
13626 \begin_layout Plain Layout
13627
13628 http://www.wkap.nl/kaphtml.htm/STYLEFILES
13629 \end_layout
13630
13631 \end_inset
13632
13633 .
13634  A complete user guide is contained in that package (but it can also be
13635  downloaded separately).
13636 \end_layout
13637
13638 \begin_layout Standard
13639 \SpecialChar LyX
13640  supports many features of the package but not everything.
13641  However, the \SpecialChar TeX
13642  code needed is reduced to some 
13643 \begin_inset Quotes eld
13644 \end_inset
13645
13646 peculiar
13647 \begin_inset Quotes erd
13648 \end_inset
13649
13650  commands of the package (see
13651 \begin_inset space ~
13652 \end_inset
13653
13654
13655 \begin_inset CommandInset ref
13656 LatexCommand ref
13657 reference "subsec:kluwer_peculiarities"
13658
13659 \end_inset
13660
13661 ).
13662  I have recently used \SpecialChar LyX
13663  to write an article submitted to the 
13664 \emph on
13665 Astrophysics and Space Science
13666 \emph default
13667  without any problem.
13668 \end_layout
13669
13670 \begin_layout Subsection
13671 Writing a paper
13672 \end_layout
13673
13674 \begin_layout Standard
13675 The easiest way to write a paper is to start with the Kluwer template file.
13676  Click on 
13677 \family sans
13678 File\SpecialChar menuseparator
13679 New from
13680 \family default
13681  
13682 \family sans
13683 Template
13684 \family default
13685 , then choose the 
13686 \family typewriter
13687 kluwer.lyx
13688 \family default
13689  template.
13690  This will give an (almost) empty document that includes the most common
13691  fields found in a manuscript and a short description of their use.
13692  As in most templates, simply overwrite the existing text (including the
13693  brackets, 
13694 \family typewriter
13695 <>
13696 \family default
13697 ) with the correct information.
13698 \end_layout
13699
13700 \begin_layout Subsection
13701 Preparing a paper for submission
13702 \end_layout
13703
13704 \begin_layout Standard
13705 As in the AAS\SpecialChar TeX
13706  package, before you submit your paper to a journal you must
13707  
13708 \begin_inset Quotes eld
13709 \end_inset
13710
13711 postprocess
13712 \begin_inset Quotes erd
13713 \end_inset
13714
13715  it as follows.
13716 \end_layout
13717
13718 \begin_layout Enumerate
13719 Export your paper as a \SpecialChar LaTeX
13720  file.
13721  To do this, click on 
13722 \family sans
13723 File\SpecialChar menuseparator
13724 Export\SpecialChar menuseparator
13725 \SpecialChar LaTeX
13726
13727 \family default
13728 .
13729  
13730 \end_layout
13731
13732 \begin_layout Enumerate
13733 Edit the resulting 
13734 \family typewriter
13735 .tex
13736 \family default
13737  file with a text editor and make the following changes
13738 \end_layout
13739
13740 \begin_deeper
13741 \begin_layout Enumerate
13742 remove the comment lines before the 
13743 \family typewriter
13744
13745 \backslash
13746 documentclass
13747 \family default
13748  command,
13749 \end_layout
13750
13751 \begin_layout Enumerate
13752 remove everything between (and including) the 
13753 \family typewriter
13754
13755 \backslash
13756 makeatletter
13757 \family default
13758  and 
13759 \family typewriter
13760
13761 \backslash
13762 makeatother
13763 \family default
13764  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13765  preamble.
13766 \end_layout
13767
13768 \begin_layout Standard
13769 Save the resulting 
13770 \family typewriter
13771 .tex
13772 \family default
13773  file.
13774 \end_layout
13775
13776 \end_deeper
13777 \begin_layout Enumerate
13778 Run the 
13779 \family typewriter
13780 .tex
13781 \family default
13782  file through \SpecialChar LaTeX
13783  as many times as necessary (usually up to three).
13784 \end_layout
13785
13786 \begin_layout Enumerate
13787 View the resulting 
13788 \family typewriter
13789 .dvi
13790 \family default
13791  document using, e.
13792 \begin_inset space \thinspace{}
13793 \end_inset
13794
13795 g.
13796 \begin_inset space \space{}
13797 \end_inset
13798
13799
13800 \family sans
13801 xdvi
13802 \family default
13803 , and check if everything is OK (it should, if you didn't make any mistake).
13804 \end_layout
13805
13806 \begin_layout Subsection
13807 \begin_inset Quotes eld
13808 \end_inset
13809
13810 Peculiarities
13811 \begin_inset Quotes erd
13812 \end_inset
13813
13814  of the Kluwer package
13815 \begin_inset CommandInset label
13816 LatexCommand label
13817 name "subsec:kluwer_peculiarities"
13818
13819 \end_inset
13820
13821
13822 \end_layout
13823
13824 \begin_layout Standard
13825 The Kluwer package has the following 
13826 \begin_inset Quotes eld
13827 \end_inset
13828
13829 peculiarities
13830 \begin_inset Quotes erd
13831 \end_inset
13832
13833 .
13834 \end_layout
13835
13836 \begin_layout Enumerate
13837 It is possible to write multiple articles in the same \SpecialChar LaTeX
13838  file
13839 \begin_inset Foot
13840 status collapsed
13841
13842 \begin_layout Plain Layout
13843 I can't imagine any good reason to do this.
13844 \end_layout
13845
13846 \end_inset
13847
13848 .
13849  Each article must be included in the environment 
13850 \begin_inset Quotes eld
13851 \end_inset
13852
13853 article
13854 \begin_inset Quotes erd
13855 \end_inset
13856
13857 .
13858  Unfortunately, this environment cannot be omitted, even if you write just
13859  one article.
13860  Therefore, each article starts with the command 
13861 \family typewriter
13862
13863 \backslash
13864 begin{article}
13865 \family default
13866  and, obviously, ends with the command 
13867 \family typewriter
13868
13869 \backslash
13870 end{article}
13871 \family default
13872 .
13873  Although this can be implemented in \SpecialChar LyX
13874 , I didn't included it, since it looks
13875  ugly and can confuse the novice user.
13876  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
13877  code (the
13878  well-known 
13879 \begin_inset Quotes eld
13880 \end_inset
13881
13882 \SpecialChar TeX
13883  code
13884 \begin_inset Quotes erd
13885 \end_inset
13886
13887 ).
13888 \end_layout
13889
13890 \begin_layout Enumerate
13891 Information given at the beginning of the article (i.
13892 \begin_inset space \thinspace{}
13893 \end_inset
13894
13895 e.
13896 \begin_inset space \space{}
13897 \end_inset
13898
13899 title, subtitle, author, institution, running title, running author, abstract
13900  and keywords) must be included in an environment called 
13901 \begin_inset Quotes eld
13902 \end_inset
13903
13904 opening
13905 \begin_inset Quotes erd
13906 \end_inset
13907
13908 .
13909  This is not implemented in \SpecialChar LyX
13910 , so you must enter title, subtitle etc.
13911 \begin_inset space ~
13912 \end_inset
13913
13914 between two \SpecialChar TeX
13915  code lines (
13916 \family typewriter
13917
13918 \backslash
13919 begin{opening}
13920 \family default
13921  and 
13922 \family typewriter
13923
13924 \backslash
13925 end{opening}
13926 \family default
13927 ).
13928 \end_layout
13929
13930 \begin_layout Enumerate
13931 According to the user manual, the label of each bibliography item must be
13932  written as 
13933 \family typewriter
13934
13935 \backslash
13936 protect
13937 \backslash
13938 citeauthoryear{
13939 \family default
13940 \emph on
13941 author(s)
13942 \family typewriter
13943 \emph default
13944 }{
13945 \family default
13946 \emph on
13947 year
13948 \family typewriter
13949 \emph default
13950 }
13951 \family default
13952 .
13953 \end_layout
13954
13955 \begin_layout Standard
13956 The 
13957 \family typewriter
13958 kluwer.lyx
13959 \family default
13960  template takes care of all these 
13961 \begin_inset Quotes eld
13962 \end_inset
13963
13964 peculiarities
13965 \begin_inset Quotes erd
13966 \end_inset
13967
13968 .
13969  If you start a new paper using this template you don't need to do anything
13970  special.
13971  Just 
13972 \end_layout
13973
13974 \begin_layout Enumerate
13975 don't delete the \SpecialChar TeX
13976  code included in the template, and
13977 \end_layout
13978
13979 \begin_layout Enumerate
13980 copy the example bibliography item included in the template and modify it
13981  as necessary to enter new bibliography items.
13982 \end_layout
13983
13984 \begin_layout Section
13985 Koma-Script
13986 \end_layout
13987
13988 \begin_layout Standard
13989 by 
13990 \noun on
13991 Bernd Rellermeyer
13992 \end_layout
13993
13994 \begin_layout Subsection
13995 Overview
13996 \end_layout
13997
13998 \begin_layout Standard
13999 The \SpecialChar LyX
14000  document classes 
14001 \emph on
14002 article (koma-script)
14003 \emph default
14004
14005 \emph on
14006 report (koma-script)
14007 \emph default
14008
14009 \emph on
14010 book
14011 \emph default
14012  
14013 \emph on
14014 (koma-script)
14015 \emph default
14016 , and 
14017 \emph on
14018 letter
14019 \emph default
14020  
14021 \emph on
14022 (koma-script)
14023 \emph default
14024  correspond to the \SpecialChar LaTeX
14025  document classes 
14026 \family typewriter
14027 scrartcl.cls
14028 \family default
14029
14030 \family typewriter
14031 scrreprt.cls
14032 \family default
14033
14034 \family typewriter
14035 scrbook.cls
14036 \family default
14037 , and 
14038 \family typewriter
14039 scrlettr.cls
14040 \family default
14041 , resp.
14042 \begin_inset space ~
14043 \end_inset
14044
14045 of the Koma-Script family.
14046  They are replacements for the standard document classes 
14047 \family typewriter
14048 article.cls
14049 \family default
14050
14051 \family typewriter
14052 report.cls
14053 \family default
14054
14055 \family typewriter
14056 book.cls
14057 \family default
14058  and 
14059 \family typewriter
14060 letter.cls
14061 \family default
14062 , resp., and fit better to European typography conventions in a number of
14063  points.
14064 \end_layout
14065
14066 \begin_layout Itemize
14067 Standard character size is 11pt in 
14068 \emph on
14069 article (koma-script)
14070 \emph default
14071
14072 \emph on
14073 report (koma-script)
14074 \emph default
14075 , and 
14076 \emph on
14077 book (koma-script)
14078 \emph default
14079 , and 12pt in 
14080 \emph on
14081 letter (koma-script)
14082 \emph default
14083 .
14084 \end_layout
14085
14086 \begin_layout Itemize
14087 Headings, labels of the description environment, and a number of elements
14088  of the 
14089 \emph on
14090 letter (koma-script)
14091 \emph default
14092  document class are set in a bold sans serif font.
14093 \begin_inset Foot
14094 status collapsed
14095
14096 \begin_layout Plain Layout
14097 There is a big difference between the bold sans serif old cm fonts and new
14098  ec fonts, especially in the appearance of headings.
14099  In comparison, the ec bold sans serif fonts look a bit thin.
14100  Here the \SpecialChar LaTeX
14101  package 
14102 \family typewriter
14103 cmsd.sty by
14104 \family default
14105  
14106 \shape smallcaps
14107 Walter Schmidt
14108 \shape default
14109  helps to produce the 
14110 \begin_inset Quotes eld
14111 \end_inset
14112
14113 usual
14114 \begin_inset Quotes erd
14115 \end_inset
14116
14117  appearance when using the ec fonts.
14118 \end_layout
14119
14120 \end_inset
14121
14122  The numbering of chapter headings is made in the same way as the numbering
14123  of section headings, that is without the extra line 
14124 \begin_inset Quotes eld
14125 \end_inset
14126
14127 Chapter\SpecialChar ldots
14128
14129 \begin_inset Quotes erd
14130 \end_inset
14131
14132 .
14133  In addition, the appearance of the headings can be modified by using a
14134  number of options (in \SpecialChar LyX
14135  to be entered in the field 
14136 \family sans
14137 Extra
14138 \begin_inset space ~
14139 \end_inset
14140
14141 Options
14142 \family default
14143  of the dialog 
14144 \family sans
14145 Layout\SpecialChar menuseparator
14146 Document
14147 \family default
14148 ).
14149  
14150 \end_layout
14151
14152 \begin_layout Itemize
14153 The main means in the Koma-Script document classes to design the type area
14154  are the options 
14155 \family sans
14156 BCOR
14157 \family default
14158  and 
14159 \family sans
14160 DIV
14161 \family default
14162  (in \SpecialChar LyX
14163  to be entered in the extra class options field in the dialog 
14164 \family sans
14165 Document\SpecialChar menuseparator
14166 Settings
14167 \family default
14168 ).
14169  They make a clearer modification of page margins possible as do the options
14170  of the dialog 
14171 \family sans
14172 Document\SpecialChar menuseparator
14173 Settings
14174 \family default
14175 .
14176  
14177 \end_layout
14178
14179 \begin_layout Itemize
14180 The \SpecialChar LaTeX
14181  document classes of the Koma-Script family define a number of additional
14182  commands.
14183  Those part of it which makes sense in \SpecialChar LyX
14184  is implemented in corresponding
14185  paragraph types.
14186 \end_layout
14187
14188 \begin_layout Standard
14189 Detailed descriptions of the \SpecialChar LaTeX
14190  document classes of the Koma-Script family
14191  can be found in the Koma-Script documentation 
14192 \emph on
14193 scrguide
14194 \emph default
14195  (German) and 
14196 \emph on
14197 scrguien
14198 \emph default
14199  (English).
14200 \end_layout
14201
14202 \begin_layout Subsection
14203 article (koma-script), report (koma-script), and book (koma-script)
14204 \end_layout
14205
14206 \begin_layout Standard
14207 The document classes 
14208 \emph on
14209 article (koma-script)
14210 \emph default
14211
14212 \emph on
14213 report (koma-script)
14214 \emph default
14215 , and 
14216 \emph on
14217 book
14218 \emph default
14219  
14220 \emph on
14221 (koma-script)
14222 \emph default
14223  are implemented in the layout files 
14224 \family typewriter
14225 scrartcl.layout
14226 \family default
14227
14228 \family typewriter
14229 scrreprt.layout
14230 \family default
14231 , and 
14232 \family typewriter
14233 scrbook.layout
14234 \family default
14235 , resp.
14236  They contain all the paragraph types of the corresponding standard document
14237  classes 
14238 \emph on
14239 article
14240 \emph default
14241
14242 \emph on
14243 report
14244 \emph default
14245 , and 
14246 \emph on
14247 book
14248 \emph default
14249 , resp., partly modified, with the exception of the \SpecialChar LyX
14250  specific 
14251 \family sans
14252 List
14253 \family default
14254 -type, which is replaced by the new 
14255 \family sans
14256 Labeling
14257 \family default
14258 -type having the same functionality.
14259  Beside the 
14260 \family sans
14261 Labeling
14262 \family default
14263 -Type there is a number of new paragraph types added.
14264  They are 
14265 \emph on
14266 not
14267 \emph default
14268  part of 
14269 \emph on
14270 letter (koma-script)
14271 \emph default
14272 .
14273 \end_layout
14274
14275 \begin_layout Itemize
14276
14277 \family sans
14278 Addpart, Addchap
14279 \family default
14280
14281 \family sans
14282 Addsec
14283 \family default
14284 : are equivalents to 
14285 \family sans
14286 Part*, Chapter*
14287 \family default
14288  and 
14289 \family sans
14290 Section*
14291 \family default
14292 , resp., additionally inserting an entry in the table of contents.
14293  
14294 \family sans
14295 Addpart
14296 \family default
14297  and 
14298 \family sans
14299 Addchap
14300 \family default
14301  are not contained in 
14302 \emph on
14303 article (koma-script)
14304 \emph default
14305 .
14306 \end_layout
14307
14308 \begin_layout Itemize
14309
14310 \family sans
14311 Addchap*
14312 \family default
14313
14314 \family sans
14315 Addsec*
14316 \family default
14317 : behave exactly as 
14318 \family sans
14319 Addchap
14320 \family default
14321  and 
14322 \family sans
14323 Addsec
14324 \family default
14325 , resp., additionally clearing running heads.
14326  
14327 \family sans
14328 Addchap*
14329 \family default
14330  is not contained in 
14331 \emph on
14332 article (koma-script)
14333 \emph default
14334 .
14335 \begin_inset Foot
14336 status collapsed
14337
14338 \begin_layout Plain Layout
14339 There is also an 
14340 \family typewriter
14341
14342 \backslash
14343 addpart*
14344 \family default
14345  command in 
14346 \emph on
14347 book (koma-script)
14348 \emph default
14349  and in 
14350 \emph on
14351 report (koma-script)
14352 \emph default
14353 , but since this is identical to 
14354 \family sans
14355 Part*
14356 \family default
14357 , is has not been implemented in \SpecialChar LyX
14358 .
14359 \end_layout
14360
14361 \end_inset
14362
14363
14364 \end_layout
14365
14366 \begin_layout Itemize
14367
14368 \family sans
14369 Minisec
14370 \family default
14371 : generates a heading directly above the following paragraph in the standard
14372  character size without affecting the structure of the document.
14373 \end_layout
14374
14375 \begin_layout Itemize
14376
14377 \family sans
14378 Captionabove
14379 \family default
14380  and 
14381 \family sans
14382 Captionbelow
14383 \family default
14384  are special captions which respect the different space settings needed
14385  for captions placed above or below an element (if you follow strict typographic
14386  rules, you might want to place table captions always above the table).
14387  You can also use the class option 
14388 \family typewriter
14389 tablecaptionsabove
14390 \family default
14391 , which will switch 
14392 \family sans
14393 caption
14394 \family default
14395  to 
14396 \family sans
14397 captionabove
14398 \family default
14399  for tables and 
14400 \family sans
14401 captionbelow
14402 \family default
14403  for figures.
14404  You need at least Koma-Script version 2.8q to use this.
14405 \end_layout
14406
14407 \begin_layout Itemize
14408
14409 \family sans
14410 Dictum
14411 \family default
14412 : can be used to set a bonmot, e.
14413 \begin_inset space \thinspace{}
14414 \end_inset
14415
14416 g.
14417 \begin_inset space \space{}
14418 \end_inset
14419
14420 at the beginning of a chapter.
14421  If you use the optional argument (
14422 \family sans
14423 Insert\SpecialChar menuseparator
14424 Dictum
14425 \begin_inset space ~
14426 \end_inset
14427
14428 Author
14429 \family default
14430 ), you can insert the dictum's author there.
14431  Dictum and author are separated by a line.
14432  You need at least Koma-Script version 2.8q to use this.
14433  
14434 \family sans
14435 Dictum
14436 \family default
14437  is not contained in 
14438 \emph on
14439 article (koma-script)
14440 \emph default
14441 .
14442 \end_layout
14443
14444 \begin_layout Standard
14445 The following types, together with the standard types 
14446 \family sans
14447 Title
14448 \family default
14449
14450 \family sans
14451 Author
14452 \family default
14453 , and 
14454 \family sans
14455 Date
14456 \family default
14457 , form the title area of the document.
14458  They must be entered ahead of the first 
14459 \begin_inset Quotes eld
14460 \end_inset
14461
14462 ordinary
14463 \begin_inset Quotes erd
14464 \end_inset
14465
14466  paragraph.
14467 \begin_inset Foot
14468 status collapsed
14469
14470 \begin_layout Plain Layout
14471 The corresponding \SpecialChar LaTeX
14472  commands must appear before the 
14473 \family typewriter
14474
14475 \backslash
14476 maketitle
14477 \family default
14478  command.
14479 \end_layout
14480
14481 \end_inset
14482
14483  When such a type is used more than once, the latter usage overwrites the
14484  former one, that means, for every type only the latest usage is valid.
14485  The order of the different types however has, like 
14486 \family sans
14487 Title
14488 \family default
14489
14490 \family sans
14491 Author
14492 \family default
14493 , and 
14494 \family sans
14495 Date
14496 \family default
14497 , no effect on the appearance of the produced document.
14498 \end_layout
14499
14500 \begin_layout Itemize
14501
14502 \family sans
14503 Subject
14504 \family default
14505 : produces a centered paragraph above the ordinary title (
14506 \family sans
14507 Title
14508 \family default
14509
14510 \family sans
14511 Author
14512 \family default
14513
14514 \family sans
14515 Date
14516 \family default
14517 ) for the subject of the document.
14518 \end_layout
14519
14520 \begin_layout Itemize
14521
14522 \family sans
14523 Publishers
14524 \family default
14525 : produces a centered paragraph below the ordinary title (
14526 \family sans
14527 Title
14528 \family default
14529
14530 \family sans
14531 Author
14532 \family default
14533
14534 \family sans
14535 Date
14536 \family default
14537 ) for the publishers' name.
14538 \end_layout
14539
14540 \begin_layout Itemize
14541
14542 \family sans
14543 Dedication
14544 \family default
14545 : in 
14546 \emph on
14547 report (koma-script)
14548 \emph default
14549  and 
14550 \emph on
14551 book (koma-script)
14552 \emph default
14553  produces a centered paragraph on its own page behind the title page, or
14554  in 
14555 \emph on
14556 article (koma-script)
14557 \emph default
14558  produces a centered paragraph below the ordinary title (
14559 \family sans
14560 Title
14561 \family default
14562
14563 \family sans
14564 Author
14565 \family default
14566
14567 \family sans
14568 Date
14569 \family default
14570
14571 \family sans
14572 Publishers
14573 \family default
14574 ) for a dedication.
14575 \end_layout
14576
14577 \begin_layout Itemize
14578
14579 \family sans
14580 Titlehead
14581 \family default
14582 : produces a left aligned paragraph above the ordinary title (
14583 \family sans
14584 Title
14585 \family default
14586
14587 \family sans
14588 Author
14589 \family default
14590
14591 \family sans
14592 Date
14593 \family default
14594
14595 \family sans
14596 Subject
14597 \family default
14598 ) for a document`s head.
14599 \end_layout
14600
14601 \begin_layout Itemize
14602
14603 \family sans
14604 Uppertitleback
14605 \family default
14606 : produces in a double-sided print in 
14607 \emph on
14608 report (koma-script)
14609 \emph default
14610  and 
14611 \emph on
14612 book (koma-script)
14613 \emph default
14614  a left-aligned paragraph at the top of the title page`s back or has no
14615  effect in a single-sided print or in 
14616 \emph on
14617 article (koma-script)
14618 \emph default
14619 .
14620 \end_layout
14621
14622 \begin_layout Itemize
14623
14624 \family sans
14625 Lowertitleback
14626 \family default
14627 : produces in a double-sided print in 
14628 \emph on
14629 report (koma-script)
14630 \emph default
14631  and 
14632 \emph on
14633 book (koma-script)
14634 \emph default
14635  a left-aligned paragraph at the bottom of the title page`s back or has
14636  no effect in a single-sided print or in 
14637 \emph on
14638 article (koma-script)
14639 \emph default
14640 .
14641 \end_layout
14642
14643 \begin_layout Itemize
14644
14645 \family sans
14646 Extratitle
14647 \family default
14648 : produces a special 
14649 \begin_inset Quotes eld
14650 \end_inset
14651
14652 dirty
14653 \begin_inset Quotes erd
14654 \end_inset
14655
14656  page ahead of the actual document containing a paragraph without special
14657  formatting.
14658 \end_layout
14659
14660 \begin_layout Standard
14661 The layout files for the document classes 
14662 \emph on
14663 article (koma-script)
14664 \emph default
14665
14666 \emph on
14667 report (koma-script)
14668 \emph default
14669 , and 
14670 \emph on
14671 book (koma-script)
14672 \emph default
14673  do include the file 
14674 \family typewriter
14675 scrmacros.inc
14676 \family default
14677 .
14678  This is thought of as a place to define your own types.
14679  Copy scrmacros
14680 \family typewriter
14681 .inc
14682 \family default
14683  in your personal layout directory and edit the file!
14684 \end_layout
14685
14686 \begin_layout Subsection
14687 letter (koma-script)
14688 \end_layout
14689
14690 \begin_layout Description
14691 Note: This section discusses the obsolete 
14692 \family sans
14693 KOMA-Script-Letter (v.
14694 \begin_inset space ~
14695 \end_inset
14696
14697 1)
14698 \family default
14699 , which is not even included anymore in recent KOMA releases.
14700  Please refer to the next section for the current KOMA-Script-Letter class
14701  (v.
14702 \begin_inset space ~
14703 \end_inset
14704
14705 2)!
14706 \end_layout
14707
14708 \begin_layout Standard
14709 \noindent
14710 The document class 
14711 \emph on
14712 letter (koma-script)
14713 \emph default
14714  is implemented in the layout file 
14715 \family typewriter
14716 scrlettr.layout
14717 \family default
14718 .
14719  It contains all the paragraph types of the corresponding standard document
14720  class 
14721 \emph on
14722 letter
14723 \emph default
14724 , partly modified, with the exception of the \SpecialChar LyX
14725  specific types 
14726 \family sans
14727 \SpecialChar LyX
14728 -Code
14729 \family default
14730  and 
14731 \family sans
14732 Comment
14733 \family default
14734  and the 
14735 \family sans
14736 List
14737 \family default
14738  type, which is replaced by the new 
14739 \family sans
14740 Labeling
14741 \family default
14742  type.
14743  In addition, it contains, in contrast to the standard document class, the
14744  standard types 
14745 \family sans
14746 \SpecialChar LaTeX
14747
14748 \family default
14749
14750 \family sans
14751 Quotation
14752 \family default
14753
14754 \family sans
14755 Quote
14756 \family default
14757 , and 
14758 \family sans
14759 Verse
14760 \family default
14761 .
14762  Furthermore, there are a number of new letter specific types.
14763 \end_layout
14764
14765 \begin_layout Standard
14766 The appearance of the letter produced by this document class can be controlled
14767  by a number of \SpecialChar LaTeX
14768  commands, which you can put in the \SpecialChar LaTeX
14769  preamble.
14770 \begin_inset Foot
14771 status collapsed
14772
14773 \begin_layout Plain Layout
14774 For example, the standard appearance of the letter`s heading, consisting
14775  of name and address, is quite self-willed.
14776  An 
14777 \begin_inset Quotes eld
14778 \end_inset
14779
14780 ordinary
14781 \begin_inset Quotes erd
14782 \end_inset
14783
14784  heading is produced by the following \SpecialChar LaTeX
14785  commands in the preamble:
14786 \end_layout
14787
14788 \begin_layout LyX-Code
14789
14790 \backslash
14791 firsthead{
14792 \backslash
14793 parbox[b]{
14794 \backslash
14795 textwidth}
14796 \end_layout
14797
14798 \begin_layout LyX-Code
14799   {
14800 \backslash
14801 ignorespaces 
14802 \backslash
14803 fromname
14804 \backslash
14805
14806 \backslash
14807  
14808 \backslash
14809 ignorespaces 
14810 \backslash
14811 fromaddress}} 
14812 \end_layout
14813
14814 \begin_layout LyX-Code
14815
14816 \backslash
14817 nexthead{
14818 \backslash
14819 parbox[b]{
14820 \backslash
14821 textwidth}
14822 \end_layout
14823
14824 \begin_layout LyX-Code
14825   {
14826 \backslash
14827 ignorespaces 
14828 \backslash
14829 fromname 
14830 \backslash
14831 hfill 
14832 \backslash
14833 ignorespaces 
14834 \backslash
14835 pagename
14836 \backslash
14837  
14838 \backslash
14839 thepage}}
14840 \end_layout
14841
14842 \end_inset
14843
14844  A detailed German description of such \SpecialChar LaTeX
14845  commands can be found in the Koma-Script
14846  documentation 
14847 \emph on
14848 scrguide
14849 \emph default
14850 .
14851  With it, the letter's author can produce his personal letter layout.
14852 \end_layout
14853
14854 \begin_layout Standard
14855 The types 
14856 \family sans
14857 Letter
14858 \family default
14859  and 
14860 \family sans
14861 Opening
14862 \family default
14863  define the beginning of the letter and must be used in every letter.
14864  To emphasize them in the \SpecialChar LyX
14865  document class, they are marked with the letter
14866  
14867 \shape italic
14868 L
14869 \shape default
14870  or 
14871 \shape italic
14872 O
14873 \shape default
14874 , resp.
14875 \begin_inset space ~
14876 \end_inset
14877
14878 in the left margin.
14879  It is possible to write any number of letters in one file.
14880  An 
14881 \family sans
14882 Opening
14883 \family default
14884  type produces a new letter using the same addressee and a 
14885 \family sans
14886 Letter
14887 \family default
14888  type produces a new addressee.
14889  The types 
14890 \family sans
14891 Closing
14892 \family default
14893
14894 \family sans
14895 PS
14896 \family default
14897
14898 \family sans
14899 CC
14900 \family default
14901 , and 
14902 \family sans
14903 Encl
14904 \family default
14905  are ordinary paragraph types and can also be used several times in one
14906  and the same letter.
14907 \end_layout
14908
14909 \begin_layout Itemize
14910
14911 \family sans
14912 Letter
14913 \family default
14914 : produces a paragraph for the addressee and implicitly defines the beginning
14915  of the letter.
14916 \end_layout
14917
14918 \begin_layout Itemize
14919
14920 \family sans
14921 Opening
14922 \family default
14923 : produces a paragraph for the form of address and implicitly produces a
14924  new letter.
14925 \end_layout
14926
14927 \begin_layout Itemize
14928
14929 \family sans
14930 Closing
14931 \family default
14932 : produces a paragraph for a close.
14933 \end_layout
14934
14935 \begin_layout Itemize
14936
14937 \family sans
14938 PS
14939 \family default
14940 : produces a paragraph for a postscript.
14941 \end_layout
14942
14943 \begin_layout Itemize
14944
14945 \family sans
14946 CC
14947 \family default
14948 : produces a paragraph for a distribution list.
14949 \end_layout
14950
14951 \begin_layout Itemize
14952
14953 \family sans
14954 Encl
14955 \family default
14956 : produces a paragraph for enclosures.
14957 \end_layout
14958
14959 \begin_layout Standard
14960 The types 
14961 \family sans
14962 Name
14963 \family default
14964
14965 \family sans
14966 Signature
14967 \family default
14968
14969 \family sans
14970 Address
14971 \family default
14972
14973 \family sans
14974 Telephone
14975 \family default
14976
14977 \family sans
14978 Place
14979 \family default
14980
14981 \family sans
14982 Backaddress
14983 \family default
14984
14985 \family sans
14986 Specialmail
14987 \family default
14988
14989 \family sans
14990 Location
14991 \family default
14992
14993 \family sans
14994 Title
14995 \family default
14996 , and 
14997 \family sans
14998 Subject
14999 \family default
15000  are input types provided with a label to enter information, which will
15001  be processed by the document class.
15002 \begin_inset Foot
15003 status collapsed
15004
15005 \begin_layout Plain Layout
15006 It could be seen as a matter of inconsequence, that the types 
15007 \family sans
15008 Letter
15009 \family default
15010  and 
15011 \family sans
15012 Opening
15013 \family default
15014  described above are not such input types as well.
15015  Because of the special meaning of those types, however, I have implemented
15016  them as ordinary paragraph types with a one letter mark in the left margin.
15017  Moreover, it would affect my feeling of symmetry, if the 
15018 \family sans
15019 Opening
15020 \family default
15021  type and the 
15022 \family sans
15023 Closing
15024 \family default
15025  type had such a serious different appearance.
15026 \end_layout
15027
15028 \end_inset
15029
15030  The types must be used ahead of the corresponding 
15031 \family sans
15032 Opening
15033 \family default
15034  type.
15035 \end_layout
15036
15037 \begin_layout Standard
15038 An implementation of these types in a WYSIWYG fashion does not seem to make
15039  sense, because the real appearance of the produced letter does not only
15040  depend on the usage of the particular type, but also on other factors.
15041  For example, a signature entered in the 
15042 \family sans
15043 Signature
15044 \family default
15045  type will in the standard behavior appear in the produced letter only,
15046  when in the same letter also a 
15047 \family sans
15048 Closing
15049 \family default
15050  type is used.
15051  The entered value of the 
15052 \family sans
15053 Telephone
15054 \family default
15055  type will in the standard behavior not appear in the produced letter at
15056  all.
15057  The possibility to design the letter`s heading freely is already indicated
15058  in a footnote above.
15059 \end_layout
15060
15061 \begin_layout Standard
15062 The input types can also be used as empty paragraphs.
15063  This makes sense e.
15064 \begin_inset space \thinspace{}
15065 \end_inset
15066
15067 g.
15068 \begin_inset space \space{}
15069 \end_inset
15070
15071 for the 
15072 \family sans
15073 Signature
15074 \family default
15075  type.
15076  If the 
15077 \family sans
15078 Signature
15079 \family default
15080  type is not used at all, in the standard behavior the value of the 
15081 \family sans
15082 Name
15083 \family default
15084  type is used as signature, whereas if an empty 
15085 \family sans
15086 Signature
15087 \family default
15088  type is used, no signature value is defined.
15089 \end_layout
15090
15091 \begin_layout Standard
15092 By using the input types it is possible to write a letter template, containing
15093  filled input types with your personal dates (name, address, etc.) and empty
15094  input types for other dates you want to enter.
15095 \end_layout
15096
15097 \begin_layout Itemize
15098
15099 \family sans
15100 Name
15101 \family default
15102 : sender's name, in the standard behavior appears as a centered paragraph
15103  in small caps in the letter`s heading.
15104 \end_layout
15105
15106 \begin_layout Itemize
15107
15108 \family sans
15109 Signature
15110 \family default
15111 : sender's signature, in the standard behavior appears below the 
15112 \family sans
15113 Closing
15114 \family default
15115  type.
15116  If no 
15117 \family sans
15118 Signature
15119 \family default
15120  type is used, the value of the 
15121 \family sans
15122 Name
15123 \family default
15124  type appears instead.
15125 \end_layout
15126
15127 \begin_layout Itemize
15128
15129 \family sans
15130 Address
15131 \family default
15132 : sender's address, in the standard behavior appears in a centered paragraph
15133  in the letter`s heading below the sender's name.
15134 \end_layout
15135
15136 \begin_layout Itemize
15137
15138 \family sans
15139 Telephone
15140 \family default
15141 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
15142  variable
15143  
15144 \family typewriter
15145
15146 \backslash
15147 telephonenum
15148 \family default
15149 .
15150 \end_layout
15151
15152 \begin_layout Itemize
15153
15154 \family sans
15155 Place
15156 \family default
15157 : place of the letter`s making.
15158 \end_layout
15159
15160 \begin_layout Itemize
15161
15162 \family sans
15163 Date
15164 \family default
15165 : date of the letter`s making.
15166  
15167 \family sans
15168 Place
15169 \family default
15170  and 
15171 \family sans
15172 Date
15173 \family default
15174 , in the standard behavior, produce the place and the date in a right-aligned
15175  line below the addressee's field.
15176  If an empty 
15177 \family sans
15178 Date
15179 \family default
15180  type is used, neither place nor date appear, independent of the value of
15181  the 
15182 \family sans
15183 Place
15184 \family default
15185  type.
15186  If no 
15187 \family sans
15188 Date
15189 \family default
15190  type is used, the date of the letter `s production is used.
15191 \end_layout
15192
15193 \begin_layout Itemize
15194
15195 \family sans
15196 Backaddress
15197 \family default
15198 : sender`s back address, in the standard behavior appears above the addressee's
15199  field in a small sans serif font.
15200 \end_layout
15201
15202 \begin_layout Itemize
15203
15204 \family sans
15205 Specialmail
15206 \family default
15207 : special mail information, in the standard behavior appears underlined
15208  above the addressee's field below the back address.
15209 \end_layout
15210
15211 \begin_layout Itemize
15212
15213 \family sans
15214 Location
15215 \family default
15216 : additional information, in the standard behavior appears on right side
15217  below the addressee`s field.
15218 \end_layout
15219
15220 \begin_layout Itemize
15221
15222 \family sans
15223 Title
15224 \family default
15225 : the letter's title, in the standard behavior appears in a big, bold, sans
15226  serif font above the subject.
15227 \end_layout
15228
15229 \begin_layout Itemize
15230
15231 \family sans
15232 Subject
15233 \family default
15234 : the letter's subject, in the standard behavior appears in a bold font
15235  above the 
15236 \family sans
15237 Opening
15238 \family default
15239  paragraph.
15240 \end_layout
15241
15242 \begin_layout Standard
15243 The types 
15244 \family sans
15245 Yourref
15246 \family default
15247
15248 \family sans
15249 Yourmail
15250 \family default
15251
15252 \family sans
15253 Myref
15254 \family default
15255
15256 \family sans
15257 Customer
15258 \family default
15259 , and 
15260 \family sans
15261 Invoice
15262 \family default
15263  produce a business letter like line above the 
15264 \family sans
15265 Title
15266 \family default
15267  line containing the fields 
15268 \begin_inset Quotes eld
15269 \end_inset
15270
15271 Your ref.
15272 \begin_inset Quotes erd
15273 \end_inset
15274
15275
15276 \begin_inset Quotes eld
15277 \end_inset
15278
15279 Your letter of
15280 \begin_inset Quotes erd
15281 \end_inset
15282
15283
15284 \begin_inset Quotes eld
15285 \end_inset
15286
15287 Our ref.
15288 \begin_inset Quotes erd
15289 \end_inset
15290
15291
15292 \begin_inset Quotes eld
15293 \end_inset
15294
15295 Customer no.
15296 \begin_inset Quotes erd
15297 \end_inset
15298
15299
15300 \begin_inset Quotes eld
15301 \end_inset
15302
15303 Invoice no.
15304 \begin_inset Quotes erd
15305 \end_inset
15306
15307 , and 
15308 \begin_inset Quotes eld
15309 \end_inset
15310
15311 Date
15312 \begin_inset Quotes erd
15313 \end_inset
15314
15315 .
15316  For the date field, the value of the 
15317 \family sans
15318 Date
15319 \family default
15320  type is used.
15321  If one of these 
15322 \begin_inset Quotes eld
15323 \end_inset
15324
15325 business letter types
15326 \begin_inset Quotes erd
15327 \end_inset
15328
15329  is used, the value of the 
15330 \family sans
15331 Place
15332 \family default
15333  type however does not appear, but only the \SpecialChar LaTeX
15334  variable 
15335 \family typewriter
15336
15337 \backslash
15338 fromplace
15339 \family default
15340  is set.
15341  The ordinary output of place and date in a right-aligned line below the
15342  addressee`s field is suppressed.
15343  The types are implemented as input types provided with a label and must
15344  be used ahead of the corresponding 
15345 \family sans
15346 Opening
15347 \family default
15348  type.
15349 \end_layout
15350
15351 \begin_layout Itemize
15352
15353 \family sans
15354 Yourref
15355 \family default
15356 : Your ref.
15357 \end_layout
15358
15359 \begin_layout Itemize
15360
15361 \family sans
15362 Yourmail
15363 \family default
15364 : Your letter of.
15365 \end_layout
15366
15367 \begin_layout Itemize
15368
15369 \family sans
15370 Myref
15371 \family default
15372 : Our ref.
15373 \end_layout
15374
15375 \begin_layout Itemize
15376
15377 \family sans
15378 Customer
15379 \family default
15380 : Customer no.
15381 \end_layout
15382
15383 \begin_layout Itemize
15384
15385 \family sans
15386 Invoice
15387 \family default
15388 : Invoice no.
15389 \end_layout
15390
15391 \begin_layout Subsection
15392 The new letter class: letter (koma-script v.2)
15393 \end_layout
15394
15395 \begin_layout Standard
15396 by 
15397 \noun on
15398 Jürgen Spitzmüller
15399 \end_layout
15400
15401 \begin_layout Standard
15402 \begin_inset VSpace medskip
15403 \end_inset
15404
15405
15406 \end_layout
15407
15408 \begin_layout Standard
15409 \noindent
15410 Koma-Script version 2.8 has introduced a new letter class 
15411 \family typewriter
15412 scrlttr2
15413 \family default
15414  which supersedes the now unsupported 
15415 \family typewriter
15416 scrlettr
15417 \family default
15418 .
15419  It has — on the \SpecialChar LaTeX
15420  side — a completely new interface and is not compatible
15421  with the old class.
15422  Therefore, \SpecialChar LyX
15423  supports both, though it is recommended you use the new class.
15424 \end_layout
15425
15426 \begin_layout Standard
15427 This class covers the same functionality as 
15428 \emph on
15429 letter (koma-script),
15430 \emph default
15431  and a few more.
15432  The basic items are 
15433 \family sans
15434 Address
15435 \family default
15436  (receiver's address, same as 
15437 \family sans
15438 Letter
15439 \family default
15440  in the old layout), 
15441 \family sans
15442 Opening
15443 \family default
15444 , and 
15445 \family sans
15446 Closing
15447 \family default
15448 .
15449  
15450 \family sans
15451 NextAddress
15452 \family default
15453  will start a new letter (i.
15454 \begin_inset space \thinspace{}
15455 \end_inset
15456
15457 e.
15458 \begin_inset space \space{}
15459 \end_inset
15460
15461 you can write several letters per document).
15462  New elements are sender's 
15463 \family sans
15464 E-Mail
15465 \family default
15466
15467 \family sans
15468 URL
15469 \family default
15470
15471 \family sans
15472 Fax
15473 \family default
15474
15475 \family sans
15476 Bank
15477 \family default
15478  and the possibility to use a 
15479 \family sans
15480 Logo
15481 \family default
15482  (via 
15483 \family sans
15484 Insert\SpecialChar menuseparator
15485 Graphics
15486 \family default
15487 ) in the header.
15488 \end_layout
15489
15490 \begin_layout Standard
15491 The biggest improvement is, though, that the letter's layout is configurable
15492  to meet almost any needs.
15493  This can be done via the preamble or with a special style file (Letter
15494  Class Option, extension 
15495 \family typewriter
15496 *.lco
15497 \family default
15498 ), that will be read in as a class option.
15499 \begin_inset Foot
15500 status collapsed
15501
15502 \begin_layout Plain Layout
15503 The KOMA package comes with some default 
15504 \family typewriter
15505 *.lco
15506 \family default
15507  files.
15508  There is, for instance, a 
15509 \family typewriter
15510 DIN.lco
15511 \family default
15512  file that follows german typesetting rules, or a 
15513 \family typewriter
15514 KOMAold.lco
15515 \family default
15516  that provides the default layout of the old 
15517 \family typewriter
15518 scrlettr
15519 \family default
15520  class.
15521  The latter can be loaded with the class option 
15522 \family typewriter
15523 KOMAold
15524 \family default
15525 , inserted via the 
15526 \family sans
15527 Layout\SpecialChar menuseparator
15528 Document\SpecialChar menuseparator
15529 Extra Options
15530 \family default
15531  field.
15532 \end_layout
15533
15534 \end_inset
15535
15536  Have a look at the 
15537 \emph on
15538 koma-letter2
15539 \emph default
15540  template that is included in \SpecialChar LyX
15541  for examples.
15542  A detailed description is to be found in the Koma-Script documentation
15543  (
15544 \emph on
15545 scrguide
15546 \emph default
15547 ).
15548 \end_layout
15549
15550 \begin_layout Subsection
15551 Problems
15552 \end_layout
15553
15554 \begin_layout Standard
15555 Visualizing the Koma-Script document classes in \SpecialChar LyX
15556 , the \SpecialChar LyX
15557  internals cause some
15558  problems.
15559 \end_layout
15560
15561 \begin_layout Itemize
15562 The chapter number of a 
15563 \family sans
15564 Chapter
15565 \family default
15566  type appears on a line of its own above the chapter heading instead of
15567  appearing in the same line ahead of it.
15568  The cause for that is the \SpecialChar LyX
15569  internal behavior for the labeltype 
15570 \family sans
15571 Counter_Chapter
15572 \family default
15573  in the layout file.
15574 \end_layout
15575
15576 \begin_layout Itemize
15577 The headings of the types 
15578 \family sans
15579 Addchap
15580 \family default
15581  and 
15582 \family sans
15583 Addsec
15584 \family default
15585  are only put in the 
15586 \begin_inset Quotes eld
15587 \end_inset
15588
15589 true
15590 \begin_inset Quotes erd
15591 \end_inset
15592
15593  \SpecialChar LaTeX
15594  table of contents, but not in the \SpecialChar LyX
15595  table of contents (
15596 \family sans
15597 Document\SpecialChar menuseparator
15598 Table
15599 \begin_inset space ~
15600 \end_inset
15601
15602 of
15603 \begin_inset space ~
15604 \end_inset
15605
15606 Contents
15607 \family default
15608 ).
15609 \end_layout
15610
15611 \begin_layout Itemize
15612 The paragraphs in a 
15613 \emph on
15614 letter
15615 \emph default
15616  document class appear in a skip separation mode, not indented.
15617  This is the standard behavior, no special \SpecialChar LaTeX
15618  commands are needed for that.
15619  But in the 
15620 \family sans
15621 Document\SpecialChar menuseparator
15622 Settings
15623 \family default
15624  dialog the corresponding radio button indicates 
15625 \family sans
15626 Indent
15627 \family default
15628 .
15629  A 
15630 \family sans
15631 Skip
15632 \family default
15633  value always has the effect that extra \SpecialChar LaTeX
15634  commands are inserted in the document
15635  to produce the gap, which is not what is wanted in this case.
15636 \end_layout
15637
15638 \begin_layout Section
15639 Memoir
15640 \end_layout
15641
15642 \begin_layout Standard
15643 By 
15644 \noun on
15645 Jürgen Spitzmüller
15646 \end_layout
15647
15648 \begin_layout Subsection
15649 Overview
15650 \end_layout
15651
15652 \begin_layout Standard
15653 Memoir is a very powerful and constantly evolving class.
15654  It has been designed with regard to fictional and non-fictional literature.
15655  Its aim is to let the user have maximum control over the typesetting of
15656  his document.
15657  Memoir is based on the standard book class, but it can also emulate the
15658  article class (see below).
15659 \end_layout
15660
15661 \begin_layout Standard
15662 Peter Wilson, the developer of Memoir, is known as the author of lots of
15663  useful packages in the \SpecialChar LaTeX
15664  world.
15665  Most of them have been merged with Memoir.
15666  Therefore, it is much easier to layout the table of contents, appendices,
15667  chapter designs and such.
15668  \SpecialChar LyX
15669 , though, does not support all of these goodies natively.
15670  Some of them might be added to forthcoming releases
15671 \begin_inset Foot
15672 status collapsed
15673
15674 \begin_layout Plain Layout
15675 You are invited to send suggestions to 
15676 \begin_inset Flex URL
15677 status collapsed
15678
15679 \begin_layout Plain Layout
15680
15681 lyx-devel@lists.lyx.org
15682 \end_layout
15683
15684 \end_inset
15685
15686 .
15687 \end_layout
15688
15689 \end_inset
15690
15691 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
15692 's framework.
15693  Of course you can still use all features with the help of some native \SpecialChar LaTeX
15694
15695  commands (\SpecialChar TeX
15696  code
15697 \begin_inset Foot
15698 status collapsed
15699
15700 \begin_layout Plain Layout
15701 Cf.
15702 \begin_inset ERT
15703 status collapsed
15704
15705 \begin_layout Plain Layout
15706
15707
15708 \backslash
15709  
15710 \end_layout
15711
15712 \end_inset
15713
15714 section
15715 \begin_inset space ~
15716 \end_inset
15717
15718
15719 \begin_inset CommandInset ref
15720 LatexCommand ref
15721 reference "sec:Inserting-TeX-Code"
15722
15723 \end_inset
15724
15725  for details.
15726 \end_layout
15727
15728 \end_inset
15729
15730 ).
15731  In this section, we can only list those features that are natively supported
15732  by \SpecialChar LyX
15733 .
15734  For detailed descriptions (and for the rest of features) we recommend you
15735  have a look at the detailed manual of the Memoir class
15736 \begin_inset Foot
15737 status collapsed
15738
15739 \begin_layout Plain Layout
15740 Cf.
15741 \begin_inset ERT
15742 status collapsed
15743
15744 \begin_layout Plain Layout
15745
15746
15747 \backslash
15748  
15749 \end_layout
15750
15751 \end_inset
15752
15753
15754 \begin_inset Flex URL
15755 status collapsed
15756
15757 \begin_layout Plain Layout
15758
15759 CTAN:/macros/latex/memoir/memman.pdf
15760 \end_layout
15761
15762 \end_inset
15763
15764 .
15765 \end_layout
15766
15767 \end_inset
15768
15769 , which is not only a user guide for the class, but also both a comprehensive
15770  description on good typesetting and a superb example for good typesetting
15771  itself.
15772 \end_layout
15773
15774 \begin_layout Subsection
15775 Basic features and restrictions
15776 \end_layout
15777
15778 \begin_layout Standard
15779 Memoir supports basically all features of the standard book classes.
15780  There are, however, some differences, as follows:
15781 \end_layout
15782
15783 \begin_layout Description
15784 Font
15785 \begin_inset space ~
15786 \end_inset
15787
15788 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
15789 \end_layout
15790
15791 \begin_layout Description
15792 Page
15793 \begin_inset space ~
15794 \end_inset
15795
15796 style: The fancy page style is not supported, due to a command clash between
15797  Memoir and the fancyhdr package (they both define a command with the same
15798  name, which confuses \SpecialChar LaTeX
15799 ).
15800  Instead, Memoir comes with a number of its own page styles (see 
15801 \family sans
15802 Document\SpecialChar menuseparator
15803 Settings\SpecialChar menuseparator
15804 Page
15805 \begin_inset space ~
15806 \end_inset
15807
15808 Style
15809 \family default
15810 ).
15811  If you want to use these for the chapter pages, you have to use the command
15812  
15813 \family typewriter
15814
15815 \backslash
15816 chapterstyle
15817 \family default
15818  in the main text or in preamble (e.
15819 \begin_inset space \thinspace{}
15820 \end_inset
15821
15822 g.
15823 \begin_inset space \space{}
15824 \end_inset
15825
15826
15827 \family typewriter
15828
15829 \backslash
15830 chapterstyle{companion}
15831 \family default
15832 ).
15833 \end_layout
15834
15835 \begin_layout Description
15836 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
15837  optional argument in the standard classes.
15838  With this, you can specify an alternative version of the title for the
15839  table of contents and the headers (for instance, if the title is too long).
15840  In \SpecialChar LyX
15841 , you can do this via 
15842 \family sans
15843 Insert\SpecialChar menuseparator
15844 Short
15845 \begin_inset space ~
15846 \end_inset
15847
15848 Title
15849 \family default
15850  at the beginning of a chapter/section.
15851  Memoir features a second optional argument and thus separates the table
15852  of contents from the header.
15853  You can define three variants of a title with this: one for the main text,
15854  one for the table of contents, and one for the headers.
15855  \SpecialChar LyX
15856  makes these available in form of specific 
15857 \family sans
15858 Short Title
15859 \family default
15860  variants in the 
15861 \family sans
15862 Insert
15863 \family default
15864  menu.
15865 \end_layout
15866
15867 \begin_layout Description
15868 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15869  of contents, the list of figures and the list of table start a new page
15870  automatically.
15871  Memoir does not follow this route.
15872  You have to insert a page break yourself, if you want to have one.
15873 \end_layout
15874
15875 \begin_layout Description
15876 Titlepage: For some unknown reason, Memoir uses pagination on the title
15877  page (in the standard classes, title pages are 
15878 \begin_inset Quotes eld
15879 \end_inset
15880
15881 empty
15882 \begin_inset Quotes erd
15883 \end_inset
15884
15885 ).
15886  If you want an empty title page, type 
15887 \family typewriter
15888
15889 \backslash
15890 aliaspagestyle{title}{empty}
15891 \family default
15892  in the preamble.
15893 \end_layout
15894
15895 \begin_layout Description
15896 Article: With the class option 
15897 \emph on
15898 article
15899 \emph default
15900  (to be inserted in 
15901 \family sans
15902 Document\SpecialChar menuseparator
15903 Settings\SpecialChar menuseparator
15904 Class Settings\SpecialChar menuseparator
15905 Custom
15906 \begin_inset space ~
15907 \end_inset
15908
15909 Options
15910 \family default
15911 ), you can emulate article style.
15912  That is, counters (footnotes, figures, tables etc.) will not be reset on
15913  new chapters, chapters don't start a new page (but are—in contrary to 
15914 \begin_inset Quotes eld
15915 \end_inset
15916
15917 real
15918 \begin_inset Quotes erd
15919 \end_inset
15920
15921  article classes—still allowed), parts, though, use their own page, as in
15922  book.
15923 \end_layout
15924
15925 \begin_layout Description
15926 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15927  font commands, which have been used in the old \SpecialChar LaTeX
15928  version 2.09 (e.
15929 \begin_inset space \thinspace{}
15930 \end_inset
15931
15932 g.
15933 \begin_inset space \space{}
15934 \end_inset
15935
15936
15937 \family typewriter
15938
15939 \backslash
15940 rm
15941 \family default
15942
15943 \family typewriter
15944
15945 \backslash
15946 it
15947 \family default
15948 ).
15949  It produces an error and stops \SpecialChar LaTeX
15950  whenever such a command appears.
15951  The class option 
15952 \emph on
15953 oldfontcommands
15954 \emph default
15955  reallows the commands and spits out warnings instead (which does at least
15956  not stop \SpecialChar LaTeX
15957 ).
15958  Since a lot of packages and particularly Bib\SpecialChar TeX
15959  style files are still using
15960  those commands, we have decided to use this option by default.
15961 \end_layout
15962
15963 \begin_layout Subsection
15964 Extra features
15965 \end_layout
15966
15967 \begin_layout Standard
15968 We will only describe the features supported by \SpecialChar LyX
15969  (which is not much currently).
15970  Please consult the Memoir manual
15971 \begin_inset Foot
15972 status collapsed
15973
15974 \begin_layout Plain Layout
15975 Cf.
15976 \begin_inset ERT
15977 status collapsed
15978
15979 \begin_layout Plain Layout
15980
15981
15982 \backslash
15983  
15984 \end_layout
15985
15986 \end_inset
15987
15988
15989 \begin_inset Flex URL
15990 status collapsed
15991
15992 \begin_layout Plain Layout
15993
15994 CTAN:/macros/latex/memoir/memman.pdf
15995 \end_layout
15996
15997 \end_inset
15998
15999 .
16000 \end_layout
16001
16002 \end_inset
16003
16004  for details.
16005 \end_layout
16006
16007 \begin_layout Description
16008 Abstract: You may wonder why an abstract is an extra feature.
16009  Well, it is in book class.
16010  Usually books don't have abstracts.
16011  Memoir, however, has.
16012  You can use it wherever and how often you like.
16013 \end_layout
16014
16015 \begin_layout Description
16016 Chapterprecis: You may know this older typesetting style: The contents of
16017  a chapter are summarized below the title and also in the table of contents
16018  (e.
16019 \begin_inset space \thinspace{}
16020 \end_inset
16021
16022 g.
16023 \begin_inset space \space{}
16024 \end_inset
16025
16026
16027 \emph on
16028 Our hero arrives in Troia; he loses some friends; he finds others
16029 \emph default
16030 ).
16031  Chapterprecis does exactly this.
16032  It is therefore only sensible below a chapter.
16033 \end_layout
16034
16035 \begin_layout Description
16036 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
16037  The epigraph environment provides an elegant way of typesetting such a
16038  motto.
16039  The motto itself (text) and its (optional) author (source) are divided
16040  by a short line.
16041  The author (source) can be inserted via 
16042 \family sans
16043 Insert\SpecialChar menuseparator
16044 Epigraph Source
16045 \family default
16046 \emph on
16047 .
16048 \end_layout
16049
16050 \begin_layout Description
16051 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
16052  complex figurative poems).
16053  \SpecialChar LyX
16054  can only support a few of them.
16055  One is poemtitle, which is a centered title for poems, which will also
16056  be added to the table of contents (verse is the standard environment for
16057  poems.
16058  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
16059  code,
16060  because they have to be nested inside regular verse environments, which
16061  is not possible with \SpecialChar LyX
16062 ).
16063 \end_layout
16064
16065 \begin_layout Description
16066 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
16067 \end_layout
16068
16069 \begin_layout Section
16070 Article (mwart), book (mwbk) and report (mwrep)
16071 \begin_inset Argument status
16072 status collapsed
16073
16074 \begin_layout Plain Layout
16075 The 
16076 \family typewriter
16077 mw
16078 \family default
16079  Classes
16080 \end_layout
16081
16082 \end_inset
16083
16084
16085 \end_layout
16086
16087 \begin_layout Standard
16088 by 
16089 \noun on
16090 Tomasz Luczak
16091 \end_layout
16092
16093 \begin_layout Standard
16094 The \SpecialChar LyX
16095  document classes 
16096 \emph on
16097 article (mwart)
16098 \emph default
16099
16100 \emph on
16101 report (mwrep)
16102 \emph default
16103  and 
16104 \emph on
16105 book
16106 \emph default
16107  
16108 \emph on
16109 (mwbk)
16110 \emph default
16111  correspond to the \SpecialChar LaTeX
16112  document classes 
16113 \family typewriter
16114 mwart.cls
16115 \family default
16116
16117 \family typewriter
16118 mwrep.cls
16119 \family default
16120  and 
16121 \family typewriter
16122 mwbk.cls
16123 \family default
16124 , resp.
16125  They are replacements for the standard document classes 
16126 \family typewriter
16127 article.cls
16128 \family default
16129
16130 \family typewriter
16131 report.cls
16132 \family default
16133  and 
16134 \family typewriter
16135 book.cls
16136 \family default
16137 , resp., and fit better to Polish typography conventions in a number of points.
16138  
16139 \end_layout
16140
16141 \begin_layout Standard
16142 Basic differences:
16143 \end_layout
16144
16145 \begin_layout Itemize
16146 Unnumbered titles (with star, e.
16147 \begin_inset space \thinspace{}
16148 \end_inset
16149
16150 g.
16151 \begin_inset space \space{}
16152 \end_inset
16153
16154
16155 \family sans
16156 Section*
16157 \family default
16158 ) are added into table of contents,
16159 \end_layout
16160
16161 \begin_layout Itemize
16162 Additional page styles:
16163 \end_layout
16164
16165 \begin_deeper
16166 \begin_layout Description
16167 uheadings header with separated lines,
16168 \end_layout
16169
16170 \begin_layout Description
16171 myheadings custom header, contents headers via commands: 
16172 \family typewriter
16173
16174 \backslash
16175 markright
16176 \family default
16177  and 
16178 \family typewriter
16179
16180 \backslash
16181 markboth
16182 \family default
16183 ,
16184 \end_layout
16185
16186 \begin_layout Description
16187 myuheadings custom header with separated lines,
16188 \end_layout
16189
16190 \begin_layout Description
16191 outer page number is placed on outer side of page
16192 \end_layout
16193
16194 \end_deeper
16195 \begin_layout Itemize
16196 Options 
16197 \end_layout
16198
16199 \begin_deeper
16200 \begin_layout Description
16201 rmheadings serif titles — default,
16202 \end_layout
16203
16204 \begin_layout Description
16205 sfheadings sansserif titles,
16206 \end_layout
16207
16208 \begin_layout Description
16209 authortitle on title page first placed is author next title — default,
16210 \end_layout
16211
16212 \begin_layout Description
16213 titleauthor on title page first placed is title next author,
16214 \end_layout
16215
16216 \begin_layout Description
16217 withmarginpar reserve place on page for margins.
16218 \end_layout
16219
16220 \end_deeper
16221 \begin_layout Section
16222 Paper
16223 \end_layout
16224
16225 \begin_layout Standard
16226 The document class 
16227 \family sans
16228 paper
16229 \family default
16230  provides an alternative to the standard 
16231 \family sans
16232 article
16233 \family default
16234  class.
16235  It provides similar functionality, but you might prefer this layout with
16236  sans serif sections, headings, and more.
16237 \end_layout
16238
16239 \begin_layout Section
16240 Rev\SpecialChar TeX
16241 4
16242 \end_layout
16243
16244 \begin_layout Standard
16245 by 
16246 \noun on
16247 Amir Karger
16248 \end_layout
16249
16250 \begin_layout Standard
16251 \begin_inset VSpace bigskip
16252 \end_inset
16253
16254
16255 \end_layout
16256
16257 \begin_layout Standard
16258 \noindent
16259 The 
16260 \family sans
16261 Revtex
16262 \begin_inset space ~
16263 \end_inset
16264
16265 4
16266 \family default
16267  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
16268  4.0 (the 
16269 \begin_inset Formula $\beta$
16270 \end_inset
16271
16272  release of May, 1999) class.
16273 \end_layout
16274
16275 \begin_layout Standard
16276 \SpecialChar LyX
16277  has a 
16278 \family sans
16279 Revtex
16280 \family default
16281  textclass, which works with Rev\SpecialChar TeX
16282  3.1.
16283  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
16284  2.09.
16285  That means that it doesn't interact very well with \SpecialChar LyX
16286 , which requires \SpecialChar LaTeX2e
16287 , although
16288  it has been kludged to work.
16289  Since Rev\SpecialChar TeX
16290  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
16291 , \SpecialChar LyX
16292  with the
16293  
16294 \family sans
16295 Rev\SpecialChar TeX
16296
16297 \begin_inset space ~
16298 \end_inset
16299
16300 4
16301 \family default
16302  textclass should also be pretty easy to use.
16303 \end_layout
16304
16305 \begin_layout Standard
16306 These documents are supposed to be used in 
16307 \emph on
16308 addition
16309 \emph default
16310  to the Rev\SpecialChar TeX
16311  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
16312  macros,
16313  and assume you'll know what to put in the preamble if necessary.
16314 \end_layout
16315
16316 \begin_layout Subsection
16317 Installation
16318 \end_layout
16319
16320 \begin_layout Standard
16321 All you need to do is install Rev\SpecialChar TeX
16322  4, as described in the package's README
16323  file.
16324  The package can be found at The Rev\SpecialChar TeX
16325  4 Web Site 
16326 \begin_inset Flex URL
16327 status collapsed
16328
16329 \begin_layout Plain Layout
16330
16331 http://publish.aps.org/revtex4/
16332 \end_layout
16333
16334 \end_inset
16335
16336 .
16337  Install it somewhere that \SpecialChar LaTeX
16338  can see it.
16339  Test it by trying to \SpecialChar LaTeX
16340  a short Rev\SpecialChar TeX
16341  4 document in some random directory (i.
16342 \begin_inset space \thinspace{}
16343 \end_inset
16344
16345 e.
16346 \begin_inset space \space{}
16347 \end_inset
16348
16349 not the directory where you installed the class file.) Then, if you reconfigure
16350  \SpecialChar LyX
16351 , it will find the class file and let you use the Rev\SpecialChar TeX
16352 4 textclass.
16353 \end_layout
16354
16355 \begin_layout Standard
16356 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
16357  4 document
16358  using 
16359 \family typewriter
16360 tex2lyx
16361 \family default
16362 , or to use the 
16363 \family sans
16364 Revtex
16365 \begin_inset space ~
16366 \end_inset
16367
16368 4
16369 \family default
16370  template, found in the templates directory.
16371 \end_layout
16372
16373 \begin_layout Subsection
16374 Preamble Matter
16375 \end_layout
16376
16377 \begin_layout Standard
16378 Optional arguments to 
16379 \family typewriter
16380
16381 \backslash
16382 documentclass
16383 \family default
16384 , like 
16385 \begin_inset Quotes eld
16386 \end_inset
16387
16388 preprint
16389 \begin_inset Quotes erd
16390 \end_inset
16391
16392  and 
16393 \begin_inset Quotes eld
16394 \end_inset
16395
16396 aps
16397 \begin_inset Quotes erd
16398 \end_inset
16399
16400 , go in the 
16401 \family sans
16402 Extra
16403 \begin_inset space ~
16404 \end_inset
16405
16406 Options
16407 \family default
16408  field in the 
16409 \family sans
16410 Document
16411 \begin_inset space ~
16412 \end_inset
16413
16414 Layout
16415 \family default
16416  dialog, as usual.
16417  Remember that in Rev\SpecialChar TeX
16418 , at least one optional argument is required! 
16419 \end_layout
16420
16421 \begin_layout Standard
16422 Other preamble matter, like 
16423 \family typewriter
16424
16425 \backslash
16426 draft
16427 \family default
16428  etc.
16429 \begin_inset space ~
16430 \end_inset
16431
16432 goes in the 
16433 \family sans
16434 \SpecialChar LaTeX
16435
16436 \begin_inset space ~
16437 \end_inset
16438
16439 Preamble
16440 \family default
16441  dialog, also as usual.
16442 \end_layout
16443
16444 \begin_layout Subsection
16445 Layouts
16446 \end_layout
16447
16448 \begin_layout Standard
16449 The layouts basically correspond to the commands in Rev\SpecialChar TeX
16450 4.0.
16451  For example, the Email layout corresponds to 
16452 \family typewriter
16453
16454 \backslash
16455 email{}
16456 \family default
16457 .
16458  Note that (at least as of Rev\SpecialChar TeX
16459  4.0 Beta), the 
16460 \family sans
16461 Address
16462 \family default
16463  and 
16464 \family sans
16465 Affiliation
16466 \family default
16467  layouts are exactly equivalent, so you shouldn't need to use both.
16468 \begin_inset Foot
16469 status collapsed
16470
16471 \begin_layout Plain Layout
16472 In case you're curious, both were included so that 
16473 \family typewriter
16474 tex2lyx
16475 \family default
16476  would be able to translate both 
16477 \family typewriter
16478
16479 \backslash
16480 address
16481 \family default
16482  and 
16483 \family typewriter
16484
16485 \backslash
16486 affiliation
16487 \family default
16488 .
16489 \end_layout
16490
16491 \end_inset
16492
16493
16494 \end_layout
16495
16496 \begin_layout Subsection
16497 Important Notes
16498 \end_layout
16499
16500 \begin_layout Standard
16501 There are a couple of important unique aspects of Rev\SpecialChar TeX
16502  4 which might cause
16503  bugs that will be even more confusing in \SpecialChar LyX
16504 .
16505 \end_layout
16506
16507 \begin_layout Standard
16508 In Rev\SpecialChar TeX
16509 , the 
16510 \family typewriter
16511
16512 \backslash
16513 thanks
16514 \family default
16515  command goes 
16516 \emph on
16517 outside
16518 \emph default
16519  the 
16520 \family typewriter
16521
16522 \backslash
16523 author
16524 \family default
16525  command.
16526  The \SpecialChar LyX
16527  equivalent is that there is a separate Thanks layout.
16528  Do 
16529 \emph on
16530 not
16531 \emph default
16532  write footnotes in the 
16533 \family sans
16534 Author
16535 \family default
16536  layout, or weird things may happen.
16537  See the Rev\SpecialChar TeX
16538  4 documentation for more details.
16539 \end_layout
16540
16541 \begin_layout Standard
16542 Also, the 
16543 \family sans
16544 Author
16545 \begin_inset space ~
16546 \end_inset
16547
16548 Email
16549 \family default
16550
16551 \family sans
16552 Author
16553 \begin_inset space ~
16554 \end_inset
16555
16556 URL
16557 \family default
16558 , and 
16559 \family sans
16560 Thanks
16561 \family default
16562  layouts must be placed 
16563 \emph on
16564 in between
16565 \emph default
16566  the 
16567 \family sans
16568 Author
16569 \family default
16570  layout and the corresponding 
16571 \family sans
16572 Address
16573 \family default
16574  (or equivalent 
16575 \family sans
16576 Affiliation
16577 \family default
16578 ) layout.
16579  If you put the 
16580 \family sans
16581 Thanks
16582 \family default
16583  after the 
16584 \family sans
16585 Address
16586 \family default
16587 , the \SpecialChar LaTeX
16588  won't compile.
16589 \end_layout
16590
16591 \begin_layout Section
16592 Springer Journals (
16593 \family sans
16594 svjour
16595 \family default
16596 )
16597 \end_layout
16598
16599 \begin_layout Standard
16600 by 
16601 \noun on
16602 Martin Vermeer
16603 \end_layout
16604
16605 \begin_layout Subsection
16606 Description
16607 \end_layout
16608
16609 \begin_layout Standard
16610 These are the layout files for some of the journal formats used by Springer
16611  Verlag and listed on 
16612 \begin_inset Flex URL
16613 status collapsed
16614
16615 \begin_layout Plain Layout
16616
16617 http://www.springer.de/author/tex/help-journals.html
16618 \end_layout
16619
16620 \end_inset
16621
16622 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
16623  now!).
16624  It is a modular system: the things common to all journals are implemented
16625  in 
16626 \family typewriter
16627 svjour.inc
16628 \family default
16629 , which journal-specific layout files (such as, e.
16630 \begin_inset space \thinspace{}
16631 \end_inset
16632
16633 g.
16634 \begin_inset space \space{}
16635 \end_inset
16636
16637
16638 \family typewriter
16639 svjog.layout
16640 \family default
16641  for Journal of Geodesy) can include.
16642 \end_layout
16643
16644 \begin_layout Standard
16645 This means that implementing support for any other Springer journal on this
16646  list is as simple as writing your own 
16647 \family typewriter
16648 sv
16649 \family default
16650 <myjournal>
16651 \family typewriter
16652 .layout
16653 \family default
16654  file following the outline given in 
16655 \family typewriter
16656 svjog.layout
16657 \family default
16658 .
16659  
16660 \end_layout
16661
16662 \begin_layout Standard
16663 It is reasonably well tested only for the Journal of Geodesy.
16664  
16665 \family typewriter
16666 svjour
16667 \family default
16668  and 
16669 \family typewriter
16670 svjog
16671 \family default
16672  come with the standard \SpecialChar LyX
16673  distribution.
16674  Install the relevant class file (downloaded from Springer) in a proper
16675  directory, reconfigure \SpecialChar LaTeX
16676  (in the te\SpecialChar TeX
16677  case by running 
16678 \family typewriter
16679 texhash
16680 \family default
16681 , as root if necessary — doesn't \SpecialChar LyX
16682  take care of this?), reconfigure \SpecialChar LyX
16683  and
16684  it should work.
16685 \end_layout
16686
16687 \begin_layout Subsection
16688 New styles
16689 \end_layout
16690
16691 \begin_layout Standard
16692 A large number of theorem-like styles — 
16693 \family sans
16694 Claim, Conjecture,
16695 \family default
16696  
16697 \family sans
16698 \SpecialChar ldots
16699 Theorem
16700 \family default
16701 .
16702 \end_layout
16703
16704 \begin_layout Standard
16705
16706 \family sans
16707 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
16708 _Title, Author_Running, Institute,
16709  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
16710 \family default
16711 .
16712  See the Springer class file documentation for details.
16713 \end_layout
16714
16715 \begin_layout Subsection
16716 Supported journals
16717 \end_layout
16718
16719 \begin_layout Itemize
16720
16721 \emph on
16722 Journal of Geodesy
16723 \emph default
16724
16725 \family typewriter
16726 svjog.layout
16727 \family default
16728  — Martin Vermeer
16729 \end_layout
16730
16731 \begin_layout Itemize
16732
16733 \emph on
16734 Probability Theory and Related Fields
16735 \emph default
16736
16737 \family typewriter
16738 svprobth.layout
16739 \family default
16740  — Jean-Marc Lasgouttes
16741 \end_layout
16742
16743 \begin_layout Standard
16744 Add your own, it isn't so hard!
16745 \end_layout
16746
16747 \begin_layout Subsection
16748 Credits
16749 \end_layout
16750
16751 \begin_layout Standard
16752 These files are partly based on the older 
16753 \family typewriter
16754 ejour2.layout
16755 \family default
16756 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
16757  2.09 style
16758  file from Springer.
16759  All this, and the 
16760 \family typewriter
16761 ejour2
16762 \family default
16763  layout, are now defunct.
16764  Jean-Marc Lasgouttes helped out big in making me find my way around the
16765  \SpecialChar LyX
16766  layout file mechanism.
16767 \end_layout
16768
16769 \begin_layout Subsection
16770 Bugs
16771 \end_layout
16772
16773 \begin_layout Standard
16774 Probably.
16775  But probably less than in the old hacked-\SpecialChar LaTeX
16776  
16777 \family typewriter
16778 ejour2
16779 \family default
16780 .
16781 \end_layout
16782
16783 \begin_layout Section
16784 Slides [aka 
16785 \noun on
16786 Sli\SpecialChar TeX
16787
16788 \noun default
16789 ]
16790 \begin_inset CommandInset label
16791 LatexCommand label
16792 name "sec:slitex"
16793
16794 \end_inset
16795
16796
16797 \end_layout
16798
16799 \begin_layout Standard
16800 by 
16801 \noun on
16802 John Weiss
16803 \noun default
16804  
16805 \end_layout
16806
16807 \begin_layout Subsection
16808 Introduction
16809 \end_layout
16810
16811 \begin_layout Standard
16812 This section describes how to use \SpecialChar LyX
16813  to make slides for overhead projectors.
16814  There are two document classes that can do this: the default slides class
16815  and the 
16816 \family sans
16817 Foil\SpecialChar TeX
16818
16819 \family default
16820  slides class.
16821  This section documents the former.
16822 \end_layout
16823
16824 \begin_layout Standard
16825 I'm going to say this again, nice and clear, so that there's no misunderstanding
16826 :
16827 \end_layout
16828
16829 \begin_layout Standard
16830 \begin_inset VSpace bigskip
16831 \end_inset
16832
16833
16834 \end_layout
16835
16836 \begin_layout Standard
16837 \align center
16838
16839 \size large
16840 This section documents the class 
16841 \begin_inset Quotes eld
16842 \end_inset
16843
16844
16845 \family sans
16846 slides (default)
16847 \family default
16848
16849 \begin_inset Quotes erd
16850 \end_inset
16851
16852  
16853 \emph on
16854 only.
16855 \end_layout
16856
16857 \begin_layout Standard
16858 \begin_inset VSpace bigskip
16859 \end_inset
16860
16861
16862 \end_layout
16863
16864 \begin_layout Standard
16865 If you're looking for the documentation for 
16866 \begin_inset Quotes eld
16867 \end_inset
16868
16869
16870 \family sans
16871 slides (Foil\SpecialChar TeX
16872 )
16873 \family default
16874
16875 \begin_inset Quotes erd
16876 \end_inset
16877
16878 , check out section
16879 \begin_inset space ~
16880 \end_inset
16881
16882
16883 \begin_inset CommandInset ref
16884 LatexCommand ref
16885 reference "sec:foiltex"
16886
16887 \end_inset
16888
16889 .
16890  The 
16891 \family sans
16892 foils
16893 \family default
16894  class [
16895 \begin_inset Quotes eld
16896 \end_inset
16897
16898
16899 \family sans
16900 slides (Foil\SpecialChar TeX
16901 )
16902 \family default
16903
16904 \begin_inset Quotes erd
16905 \end_inset
16906
16907 ] is actually somewhat better than the default 
16908 \family sans
16909 slides
16910 \family default
16911  class,
16912 \begin_inset Foot
16913 status collapsed
16914
16915 \begin_layout Plain Layout
16916 \SpecialChar ldots
16917 or so I've been told repeatedly by its advocates.
16918  Having never used it, I have no idea if this claim is true or not.
16919 \end_layout
16920
16921 \end_inset
16922
16923  which this section documents.
16924 \end_layout
16925
16926 \begin_layout Standard
16927 This class is the \SpecialChar LaTeX2e
16928  improvement of the old 
16929 \noun on
16930 Sli\SpecialChar TeX
16931
16932 \noun default
16933  package.
16934  Every \SpecialChar LaTeX2e
16935  distribution includes this class [which I'll just refer to as 
16936 \begin_inset Quotes eld
16937 \end_inset
16938
16939
16940 \family sans
16941 slides
16942 \family default
16943
16944 \begin_inset Quotes erd
16945 \end_inset
16946
16947  from now on], so you're bound to have it.
16948  As I noted earlier, there are other classes, such as 
16949 \family sans
16950 foils
16951 \family default
16952 , which also produce slides for overhead projectors and do a better job
16953  at it.
16954  However, there are some things which 
16955 \family sans
16956 slides
16957 \family default
16958  can do which the others can't, such as generate overlays.
16959  Read on to learn more!
16960 \end_layout
16961
16962 \begin_layout Subsection
16963 Getting Started
16964 \begin_inset CommandInset label
16965 LatexCommand label
16966 name "sec:slidesetup"
16967
16968 \end_inset
16969
16970
16971 \end_layout
16972
16973 \begin_layout Standard
16974 Obviously, to use this document class, you need to select 
16975 \begin_inset Quotes eld
16976 \end_inset
16977
16978
16979 \family sans
16980 slides (default)
16981 \family default
16982
16983 \begin_inset Quotes erd
16984 \end_inset
16985
16986  from the class list in the 
16987 \family sans
16988 Document\SpecialChar menuseparator
16989 Settings
16990 \family default
16991  dialog.
16992  There are some other special things you should know about this class:
16993 \end_layout
16994
16995 \begin_layout Itemize
16996 Don't bother changing the options 
16997 \family sans
16998 Sides and Columns
16999 \family default
17000 .
17001  They're not supported by the 
17002 \family sans
17003 slides
17004 \family default
17005  class, anyways.
17006 \end_layout
17007
17008 \begin_layout Itemize
17009 The option 
17010 \family sans
17011 Page
17012 \begin_inset space ~
17013 \end_inset
17014
17015 style
17016 \family default
17017  behaves a bit differently for this class.
17018  The possible choices and what they do are as follows:
17019 \end_layout
17020
17021 \begin_deeper
17022 \begin_layout Description
17023
17024 \family sans
17025 plain
17026 \family default
17027  The final output contains page numbers in the lower right corner.
17028 \end_layout
17029
17030 \begin_layout Description
17031
17032 \family sans
17033 headings
17034 \family default
17035  Like 
17036 \family sans
17037 plain
17038 \family default
17039 , but also prints out any time markers you've put in.
17040  This is the default.
17041 \end_layout
17042
17043 \begin_layout Description
17044
17045 \family sans
17046 empty
17047 \family default
17048  The final output contains no page numbers, time markers, or alignment markers.
17049 \end_layout
17050
17051 \end_deeper
17052 \begin_layout Itemize
17053 The 
17054 \family sans
17055 slides
17056 \family default
17057  class has an extra option: 
17058 \family typewriter
17059 clock
17060 \family default
17061 .
17062  To use it, put 
17063 \begin_inset Quotes eld
17064 \end_inset
17065
17066
17067 \family typewriter
17068 clock
17069 \family default
17070
17071 \begin_inset Quotes erd
17072 \end_inset
17073
17074  in the extra class options.
17075 \end_layout
17076
17077 \begin_deeper
17078 \begin_layout Standard
17079 Using this options allows you to add time markers to 
17080 \family sans
17081 Note
17082 \family default
17083 s.
17084  See section
17085 \begin_inset space ~
17086 \end_inset
17087
17088
17089 \begin_inset CommandInset ref
17090 LatexCommand ref
17091 reference "sec:slideNote"
17092
17093 \end_inset
17094
17095  for more details.
17096 \end_layout
17097
17098 \end_deeper
17099 \begin_layout Standard
17100 You can also use the template file 
17101 \begin_inset Quotes eld
17102 \end_inset
17103
17104
17105 \family typewriter
17106 slides.lyx
17107 \family default
17108
17109 \begin_inset Quotes erd
17110 \end_inset
17111
17112  to automatically set up a document to use the 
17113 \family sans
17114 slides
17115 \family default
17116  class [using 
17117 \family sans
17118 File\SpecialChar menuseparator
17119 New
17120 \begin_inset space ~
17121 \end_inset
17122
17123 from
17124 \begin_inset space ~
17125 \end_inset
17126
17127 Template
17128 \family default
17129  to open your new document].
17130  The template file also contains some examples of the special paragraph
17131  environments used by this class.
17132  I'll describe those next.
17133 \end_layout
17134
17135 \begin_layout Subsection
17136 Paragraph Environments
17137 \end_layout
17138
17139 \begin_layout Subsubsection
17140 Supported Environments
17141 \end_layout
17142
17143 \begin_layout Standard
17144 The first thing you'll notice when you start up a new 
17145 \family sans
17146 slides
17147 \family default
17148  document is the font size and type: it's the equivalent of the size 
17149 \begin_inset Quotes eld
17150 \end_inset
17151
17152
17153 \family sans
17154 Largest
17155 \family default
17156
17157 \begin_inset Quotes erd
17158 \end_inset
17159
17160  in the 
17161 \family sans
17162 Sans
17163 \begin_inset space ~
17164 \end_inset
17165
17166 Serif
17167 \family default
17168  font.
17169  This is also what's used in the output.
17170  Think of this as a 
17171 \begin_inset Quotes eld
17172 \end_inset
17173
17174 visual cue
17175 \begin_inset Quotes erd
17176 \end_inset
17177
17178  to remind you that this is a slide.
17179  Your final slides will use a larger font; ergo, you'll have less space.
17180  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
17181 \end_layout
17182
17183 \begin_layout Standard
17184 The next thing that becomes obvious is the changes to the paragraph environment
17185  pull-down box [at the far-left end of the toolbar].
17186  Most of the paragraph environments you're used to seeing are missing.
17187  There are also five new ones.
17188  That's because the 
17189 \family sans
17190 slides
17191 \family default
17192  class itself only supports certain paragraph environments:
17193 \end_layout
17194
17195 \begin_layout Itemize
17196
17197 \family sans
17198 Standard
17199 \end_layout
17200
17201 \begin_layout Itemize
17202
17203 \family sans
17204 Itemize
17205 \end_layout
17206
17207 \begin_layout Itemize
17208
17209 \family sans
17210 Enumerate
17211 \end_layout
17212
17213 \begin_layout Itemize
17214
17215 \family sans
17216 Description
17217 \end_layout
17218
17219 \begin_layout Itemize
17220
17221 \family sans
17222 List
17223 \end_layout
17224
17225 \begin_layout Itemize
17226
17227 \family sans
17228 Quotation
17229 \end_layout
17230
17231 \begin_layout Itemize
17232
17233 \family sans
17234 Quote
17235 \end_layout
17236
17237 \begin_layout Itemize
17238
17239 \family sans
17240 Verse
17241 \end_layout
17242
17243 \begin_layout Itemize
17244
17245 \family sans
17246 Caption
17247 \end_layout
17248
17249 \begin_layout Itemize
17250
17251 \family sans
17252 \SpecialChar LyX
17253 -Code
17254 \end_layout
17255
17256 \begin_layout Standard
17257 All of the other standard environments, including the section-heading environmen
17258 ts, aren't used in the 
17259 \family sans
17260 slides
17261 \family default
17262  class.
17263 \end_layout
17264
17265 \begin_layout Standard
17266 On the other hand, you'll notice the following new environments:
17267 \end_layout
17268
17269 \begin_layout Itemize
17270
17271 \family sans
17272 Slide
17273 \end_layout
17274
17275 \begin_layout Itemize
17276
17277 \family sans
17278 Overlay
17279 \end_layout
17280
17281 \begin_layout Itemize
17282
17283 \family sans
17284 Note
17285 \end_layout
17286
17287 \begin_layout Itemize
17288
17289 \family sans
17290 InvisibleText
17291 \end_layout
17292
17293 \begin_layout Itemize
17294
17295 \family sans
17296 VisibleText
17297 \end_layout
17298
17299 \begin_layout Standard
17300 These five are kind of quirky, due to a 
17301 \begin_inset Quotes eld
17302 \end_inset
17303
17304 feature
17305 \begin_inset Quotes erd
17306 \end_inset
17307
17308  in \SpecialChar LyX
17309 .
17310  You see, \SpecialChar LyX
17311  doesn't permit you to nest any other paragraph environment into
17312  an empty environment.
17313  Now, that's fine and dandy, but it means that you wouldn't be able to start
17314  a slide with anything except plain text.
17315  To deal with this, I've performed a little 
17316 \begin_inset Quotes eld
17317 \end_inset
17318
17319 \SpecialChar LaTeX
17320  magic.
17321 \begin_inset Quotes erd
17322 \end_inset
17323
17324  
17325 \end_layout
17326
17327 \begin_layout Subsubsection
17328 Quirks of the New Environments
17329 \begin_inset CommandInset label
17330 LatexCommand label
17331 name "sec:slideQuirk"
17332
17333 \end_inset
17334
17335
17336 \end_layout
17337
17338 \begin_layout Standard
17339 All five of the new paragraph environments are somewhat quirky due to inherent
17340  limitiations in the current version of \SpecialChar LyX
17341 .
17342  As I just mentioned, \SpecialChar LyX
17343  forbids environments that begin with another environment.
17344  To get around this, the 
17345 \family sans
17346 Slide
17347 \family default
17348  environment isn't a paragraph environment as described in the 
17349 \emph on
17350 User's Guide
17351 \emph default
17352 .
17353  
17354 \end_layout
17355
17356 \begin_layout Standard
17357 You should consider 
17358 \family sans
17359 Slide
17360 \family default
17361
17362 \family sans
17363 Overlay
17364 \family default
17365 , and 
17366 \family sans
17367 Note
17368 \family default
17369  to be 
17370 \begin_inset Quotes eld
17371 \end_inset
17372
17373 pseudo-environments.
17374 \begin_inset Quotes erd
17375 \end_inset
17376
17377  They look like a section heading or a 
17378 \begin_inset Quotes eld
17379 \end_inset
17380
17381
17382 \family sans
17383 Caption
17384 \family default
17385 ,
17386 \begin_inset Quotes erd
17387 \end_inset
17388
17389  but really begin a [and, if necessary, end the previous] paragraph environment.
17390  Likewise, treat 
17391 \family sans
17392 InvisibleText
17393 \family default
17394  and 
17395 \family sans
17396 VisibleText
17397 \family default
17398  as 
17399 \begin_inset Quotes eld
17400 \end_inset
17401
17402 pseudo-commands.
17403 \begin_inset Quotes erd
17404 \end_inset
17405
17406  These two perform some action.
17407 \end_layout
17408
17409 \begin_layout Standard
17410 A common feature of all five environments, 
17411 \family sans
17412 Slide
17413 \family default
17414
17415 \family sans
17416 Overlay
17417 \family default
17418
17419 \family sans
17420 Note
17421 \family default
17422
17423 \family sans
17424 InvisibleText
17425 \family default
17426  and 
17427 \family sans
17428 VisibleText
17429 \family default
17430 , is a rather long-ish label.
17431  The text following this label — ordinarily the contents of the paragraph
17432  environment — is utterly irrelevant for 
17433 \family sans
17434 Slide
17435 \family default
17436
17437 \family sans
17438 Overlay
17439 \family default
17440
17441 \family sans
17442 Note
17443 \family default
17444
17445 \family sans
17446 InvisibleText
17447 \family default
17448  and 
17449 \family sans
17450 VisibleText
17451 \family default
17452 .
17453  \SpecialChar LyX
17454  completely ignores it.
17455  In fact, you can leave these five environments completely empty.
17456  
17457 \end_layout
17458
17459 \begin_layout Standard
17460 While you don't 
17461 \emph on
17462 have
17463 \emph default
17464  to put any text after the rather long-ish label, you might want to.
17465  This could be a short description of the contents of the 
17466 \family sans
17467 Slide
17468 \family default
17469 , for example.
17470  In that case, enter your descriptive comment and hit 
17471 \family sans
17472 Return
17473 \family default
17474  as you normally would.
17475 \end_layout
17476
17477 \begin_layout Standard
17478 If, on the other hand, you don't want to enter any descriptive text, you'll
17479  hit another \SpecialChar LyX
17480  quirk.
17481  \SpecialChar LyX
17482 , like nature, abhors a vacuum, and will not let you start a new paragraph
17483  environment until you put something in the old one.
17484  So, do this:
17485 \end_layout
17486
17487 \begin_layout Itemize
17488 Start entering the text that will 
17489 \emph on
17490 follow
17491 \emph default
17492  the new 
17493 \family sans
17494 Slide
17495 \family default
17496
17497 \family sans
17498 Overlay
17499 \family default
17500
17501 \family sans
17502 Note
17503 \family default
17504
17505 \family sans
17506 InvisibleText
17507 \family default
17508  or 
17509 \family sans
17510 VisibleText
17511 \family default
17512 .
17513  
17514 \end_layout
17515
17516 \begin_layout Itemize
17517 Now move to the beginning of that paragraph.
17518  
17519 \end_layout
17520
17521 \begin_layout Itemize
17522 Next, hit 
17523 \family sans
17524 Return
17525 \family default
17526 .
17527  
17528 \end_layout
17529
17530 \begin_layout Itemize
17531 Finally, change this new, empty paragraph to a 
17532 \family sans
17533 Slide
17534 \family default
17535
17536 \family sans
17537 Overlay
17538 \family default
17539
17540 \family sans
17541 Note
17542 \family default
17543
17544 \family sans
17545 InvisibleText
17546 \family default
17547  or 
17548 \family sans
17549 VisibleText
17550 \family default
17551 .
17552  
17553 \end_layout
17554
17555 \begin_layout Standard
17556 Some future version of \SpecialChar LyX
17557  will, hopefully, resolve this quirkiness\SpecialChar ldots
17558
17559 \end_layout
17560
17561 \begin_layout Subsection
17562 Making a Presentation with 
17563 \family sans
17564 Slide
17565 \family default
17566
17567 \family sans
17568 Overlay
17569 \family default
17570  and 
17571 \family sans
17572 Note
17573 \end_layout
17574
17575 \begin_layout Subsubsection
17576 Using the 
17577 \family sans
17578 Slide
17579 \family default
17580  Environment
17581 \end_layout
17582
17583 \begin_layout Standard
17584 If you're expecting this section to teach you how to actually make a presentatio
17585 n, you'll be sorely disappointed.
17586  Naturally, I'll describe all of the ways the 
17587 \family sans
17588 slides
17589 \family default
17590  class can assist you in preparing the materials for a presentation.
17591  Filling in the contents, however, is up to you.
17592  [Then again, that 
17593 \emph on
17594 is
17595 \emph default
17596  the \SpecialChar LyX
17597  philosophy.]
17598 \end_layout
17599
17600 \begin_layout Standard
17601 Choosing the 
17602 \family sans
17603 Slide
17604 \family default
17605  environment [in the manner described in section
17606 \begin_inset space ~
17607 \end_inset
17608
17609
17610 \begin_inset CommandInset ref
17611 LatexCommand ref
17612 reference "sec:slideQuirk"
17613
17614 \end_inset
17615
17616 ] tells \SpecialChar LyX
17617  to begin a new slide [duh].
17618  The label for this environment/
17619 \begin_inset Quotes erd
17620 \end_inset
17621
17622 pseudo-command
17623 \begin_inset Quotes erd
17624 \end_inset
17625
17626  is an 
17627 \begin_inset Quotes eld
17628 \end_inset
17629
17630 ASCII line,
17631 \begin_inset Quotes erd
17632 \end_inset
17633
17634  in cool blue, followed by the label, 
17635 \begin_inset Quotes eld
17636 \end_inset
17637
17638 NewSlide:
17639 \begin_inset Quotes erd
17640 \end_inset
17641
17642 .
17643  Any text or paragraph environments that follow this one go on the new slide.
17644  It's that simple.
17645 \end_layout
17646
17647 \begin_layout Standard
17648 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
17649
17650  (this can be specified in the 
17651 \family sans
17652 Paragraph Layout
17653 \family default
17654  dialog).
17655  In fact, you'll want to, once you finish entering the contents of one slide.
17656  If you've entered more text than can physically fit on a slide, the extra
17657  overflows onto a new slide.
17658  I don't recommend doing this, however, since the overflow slide won't have
17659  any page number on it.
17660  Furthermore, it may interfere with any 
17661 \family sans
17662 Overlay
17663 \family default
17664  you've made to accompany the oversized 
17665 \family sans
17666 Slide
17667 \family default
17668 .
17669 \end_layout
17670
17671 \begin_layout Standard
17672 The 
17673 \family sans
17674 Overlay
17675 \family default
17676  and 
17677 \family sans
17678 Note
17679 \family default
17680  environments work the same way as the 
17681 \family sans
17682 Slide
17683 \family default
17684  environment.
17685  They both create an 
17686 \begin_inset Quotes eld
17687 \end_inset
17688
17689 ASCII line
17690 \begin_inset Quotes erd
17691 \end_inset
17692
17693  followed by a label [
17694 \begin_inset Quotes eld
17695 \end_inset
17696
17697 NewOverlay:
17698 \begin_inset Quotes erd
17699 \end_inset
17700
17701  and 
17702 \begin_inset Quotes eld
17703 \end_inset
17704
17705 NewNote:
17706 \begin_inset Quotes erd
17707 \end_inset
17708
17709 , respectively].
17710  The color is a stunning magenta instead of blue, and the 
17711 \begin_inset Quotes eld
17712 \end_inset
17713
17714 ASCII line
17715 \begin_inset Quotes erd
17716 \end_inset
17717
17718  will look different, in style and in length.
17719  The label fonts of all three also differ from one another.
17720 \end_layout
17721
17722 \begin_layout Standard
17723 As with a 
17724 \family sans
17725 Slide
17726 \family default
17727 , if the contents of a 
17728 \family sans
17729 Note
17730 \family default
17731  or 
17732 \family sans
17733 Overlay
17734 \family default
17735  exceed the physical size of a slide or sheet of paper, the extra will overflow
17736  onto a new sheet.
17737  Again, you should avoid this.
17738  It defeats the whole purpose of 
17739 \family sans
17740 Note
17741 \family default
17742 s and 
17743 \family sans
17744 Overlay
17745 \family default
17746 s.
17747 \end_layout
17748
17749 \begin_layout Subsubsection
17750 Using 
17751 \family sans
17752 Overlay
17753 \family default
17754  with 
17755 \family sans
17756 Slide
17757 \end_layout
17758
17759 \begin_layout Standard
17760 The idea behind an 
17761 \family sans
17762 Overlay
17763 \family default
17764  is a slide that sits atop another slide.
17765  Perhaps you wish to discuss a figure on the main 
17766 \family sans
17767 Slide
17768 \family default
17769  before displaying the text associated with it.
17770  One way to accomplish this is tape a flap of dark paper over the part of
17771  the 
17772 \family sans
17773 Slide
17774 \family default
17775  you want to display later.
17776  This method fails, however, if you wish to overlap one graph with another,
17777  for example.
17778  You would then have to fumble while speaking to align the two separate,
17779  overlapping 
17780 \family sans
17781 Slide
17782 \family default
17783 s to align the two graphs.
17784  The use of an 
17785 \family sans
17786 Overlay
17787 \family default
17788  environment in both cases makes life much easier.
17789 \end_layout
17790
17791 \begin_layout Standard
17792 Each 
17793 \family sans
17794 Overlay
17795 \family default
17796  receives the page number of its 
17797 \begin_inset Quotes eld
17798 \end_inset
17799
17800 parent
17801 \begin_inset Quotes erd
17802 \end_inset
17803
17804  
17805 \family sans
17806 Slide
17807 \family default
17808 , appended by 
17809 \begin_inset Quotes eld
17810 \end_inset
17811
17812
17813 \family typewriter
17814 -a
17815 \family default
17816
17817 \begin_inset Quotes erd
17818 \end_inset
17819
17820 .
17821 \begin_inset Foot
17822 status collapsed
17823
17824 \begin_layout Plain Layout
17825 Presumably, mutliple 
17826 \family sans
17827 Overlay
17828 \family default
17829 s would have 
17830 \begin_inset Quotes eld
17831 \end_inset
17832
17833
17834 \family typewriter
17835 -a
17836 \family default
17837
17838 \begin_inset Quotes erd
17839 \end_inset
17840
17841
17842 \begin_inset Quotes eld
17843 \end_inset
17844
17845
17846 \family typewriter
17847 -b
17848 \family default
17849
17850 \begin_inset Quotes erd
17851 \end_inset
17852
17853
17854 \begin_inset Quotes eld
17855 \end_inset
17856
17857
17858 \family typewriter
17859 -c
17860 \family default
17861
17862 \begin_inset Quotes erd
17863 \end_inset
17864
17865 , etc.
17866 \begin_inset space ~
17867 \end_inset
17868
17869 appended to the page number of the parent 
17870 \family sans
17871 Slide
17872 \family default
17873 .
17874  
17875 \end_layout
17876
17877 \end_inset
17878
17879  Clearly, you want the contents of both the 
17880 \family sans
17881 Slide
17882 \family default
17883  and the 
17884 \family sans
17885 Overlay
17886 \family default
17887  to each fit on a single physical slide! You should probably consider an
17888  
17889 \family sans
17890 Overlay
17891 \family default
17892  as 
17893 \begin_inset Quotes eld
17894 \end_inset
17895
17896 part of
17897 \begin_inset Quotes erd
17898 \end_inset
17899
17900  a 
17901 \family sans
17902 Slide
17903 \family default
17904 .
17905  Indeed, the \SpecialChar LyX
17906  
17907 \family sans
17908 slides
17909 \family default
17910  class provides a visual cue for this: the label at the start of an 
17911 \family sans
17912 Overlay
17913 \family default
17914  is shorter than that at the start of a 
17915 \family sans
17916 Slide
17917 \family default
17918 .
17919  Lastly, when you generate printable output, you'll find alignment markers
17920  in all four corners of both the 
17921 \family sans
17922 Overlay
17923 \family default
17924  page and its parent 
17925 \family sans
17926 Slide
17927 \family default
17928 .
17929  These will assist you in lining up the two physical slides.
17930 \end_layout
17931
17932 \begin_layout Standard
17933 The major problem in overlaying two slides is aligning the contents of the
17934  two transparencies.
17935  How much space should you leave for that graph on the second slide? Worse
17936  still, what if you want a graph and a sentence on second slide, but there
17937  is text on the main transparency that goes in between them? You could try
17938  and insert vertical space of the right size.
17939  The better way is to use 
17940 \family sans
17941 InvisibleText
17942 \family default
17943  and 
17944 \family sans
17945 VisibleText
17946 \family default
17947 .
17948 \end_layout
17949
17950 \begin_layout Standard
17951 As their names imply, 
17952 \family sans
17953 InvisibleText
17954 \family default
17955  and 
17956 \family sans
17957 VisibleText
17958 \family default
17959  are two command-like paragraph environments that make all subsequent text
17960  invisible and visible, respectively.
17961  Note from section
17962 \begin_inset space ~
17963 \end_inset
17964
17965
17966 \begin_inset CommandInset ref
17967 LatexCommand ref
17968 reference "sec:slideQuirk"
17969
17970 \end_inset
17971
17972  that you don't place anything 
17973 \emph on
17974 into
17975 \emph default
17976  these two environments, however.
17977  When you create an 
17978 \family sans
17979 InvisibleText
17980 \family default
17981 , it inserts a centered, sky-blue label into the page reading 
17982 \begin_inset Quotes eld
17983 \end_inset
17984
17985 <Invisible Text Follows>
17986 \begin_inset Quotes erd
17987 \end_inset
17988
17989 .
17990  For paragraphs following this label, the parts of the 
17991 \family sans
17992 Slide
17993 \family default
17994  [or 
17995 \family sans
17996 Overlay
17997 \family default
17998 ; it doesn't matter which] where they would be contain instead blank space.
17999  
18000 \end_layout
18001
18002 \begin_layout Standard
18003 For 
18004 \family sans
18005 VisibleText
18006 \family default
18007 , the corresponding centered label is 
18008 \begin_inset Quotes eld
18009 \end_inset
18010
18011 <Visible Text Follows>
18012 \begin_inset Quotes erd
18013 \end_inset
18014
18015  in blazing green.
18016  Paragraphs following this label behave normally.
18017  Note that the beginning of a new 
18018 \family sans
18019 Slide
18020 \family default
18021
18022 \family sans
18023 Overlay
18024 \family default
18025 , or 
18026 \family sans
18027 Note
18028 \family default
18029  automatically shuts off an 
18030 \family sans
18031 InvisibleText
18032 \family default
18033 .
18034  It's therefore not necessary to use 
18035 \family sans
18036 VisibleText
18037 \family default
18038  at the end of a 
18039 \family sans
18040 Slide
18041 \family default
18042 .
18043 \end_layout
18044
18045 \begin_layout Standard
18046 By now, it should be obvious how to create overlay transparencies using
18047  the proper combination of 
18048 \family sans
18049 InvisibleText
18050 \family default
18051  and 
18052 \family sans
18053 VisibleText
18054 \family default
18055  on a 
18056 \family sans
18057 Slide
18058 \family default
18059  and 
18060 \family sans
18061 Overlay
18062 \family default
18063 :
18064 \end_layout
18065
18066 \begin_layout Enumerate
18067 Create a 
18068 \family sans
18069 Slide
18070 \family default
18071 , including everything that will appear on it, whether on the main slide
18072  or on the 
18073 \family sans
18074 Overlay
18075 \family default
18076 .
18077 \end_layout
18078
18079 \begin_layout Enumerate
18080 Before each figure or paragraph that will appear only on the 
18081 \family sans
18082 Overlay
18083 \family default
18084 , insert an 
18085 \family sans
18086 InvisibleText
18087 \family default
18088  environment.
18089  If necessary, insert a 
18090 \family sans
18091 VisibleText
18092 \family default
18093  environment after the 
18094 \family sans
18095 Overlay
18096 \family default
18097 -only text.
18098 \end_layout
18099
18100 \begin_layout Enumerate
18101 Start an 
18102 \family sans
18103 Overlay
18104 \family default
18105  immediately following the 
18106 \family sans
18107 Slide
18108 \family default
18109 .
18110 \end_layout
18111
18112 \begin_layout Enumerate
18113 Copy the contents of this 
18114 \family sans
18115 Slide
18116 \family default
18117  into the 
18118 \family sans
18119 Overlay
18120 \family default
18121 .
18122 \end_layout
18123
18124 \begin_layout Enumerate
18125 Within the 
18126 \family sans
18127 Overlay
18128 \family default
18129 , change all of the 
18130 \family sans
18131 InvisibleText
18132 \family default
18133  lines to 
18134 \family sans
18135 VisibleText
18136 \family default
18137  and vice-versa.
18138 \end_layout
18139
18140 \begin_layout Standard
18141 That's it.
18142  You've just made an 
18143 \family sans
18144 Overlay
18145 \family default
18146 .
18147 \end_layout
18148
18149 \begin_layout Standard
18150 There's one problem with the way I've designed the \SpecialChar LyX
18151  
18152 \family sans
18153 slides
18154 \family default
18155  class: you can't make text in the middle of a paragraph invisible, nor
18156  make text in the middle of an invisible paragraph visible again.
18157  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
18158  codes.
18159 \begin_inset Foot
18160 status collapsed
18161
18162 \begin_layout Plain Layout
18163 The commands of interest are: 
18164 \end_layout
18165
18166 \begin_layout Itemize
18167
18168 \family typewriter
18169 {
18170 \backslash
18171 invisible \SpecialChar ldots
18172  }
18173 \end_layout
18174
18175 \begin_layout Itemize
18176
18177 \family typewriter
18178 {
18179 \backslash
18180 visible \SpecialChar ldots
18181  }
18182 \end_layout
18183
18184 \begin_layout Plain Layout
18185 \SpecialChar ldots
18186 and need to be marked as \SpecialChar TeX
18187 .
18188  The text whose 
18189 \begin_inset Quotes eld
18190 \end_inset
18191
18192 visibility
18193 \begin_inset Quotes erd
18194 \end_inset
18195
18196  you wish to change goes in between the brackets [and after the 
18197 \family typewriter
18198
18199 \backslash
18200 invisible
18201 \family default
18202  or 
18203 \family typewriter
18204
18205 \backslash
18206 visible
18207 \family default
18208  command].
18209  If you don't know how to mark text as \SpecialChar TeX
18210 , see the appropriate section of
18211  the 
18212 \emph on
18213 User's Guide
18214 \emph default
18215 .
18216 \end_layout
18217
18218 \end_inset
18219
18220
18221 \end_layout
18222
18223 \begin_layout Subsubsection
18224 Using 
18225 \family sans
18226 Note
18227 \family default
18228  with 
18229 \family sans
18230 Slide
18231 \family default
18232
18233 \begin_inset CommandInset label
18234 LatexCommand label
18235 name "sec:slideNote"
18236
18237 \end_inset
18238
18239
18240 \end_layout
18241
18242 \begin_layout Standard
18243 Like an 
18244 \family sans
18245 Overlay
18246 \family default
18247 , a 
18248 \family sans
18249 Note
18250 \family default
18251  is associated with a 
18252 \begin_inset Quotes eld
18253 \end_inset
18254
18255 parent
18256 \begin_inset Quotes erd
18257 \end_inset
18258
18259  
18260 \family sans
18261 Slide
18262 \family default
18263 .
18264  Here, too, the \SpecialChar LyX
18265  
18266 \family sans
18267 slides
18268 \family default
18269  class provides visual cues.
18270  The label for a 
18271 \family sans
18272 Note
18273 \family default
18274  is shorter than that of a 
18275 \family sans
18276 Slide
18277 \family default
18278  [yet longer than that of an 
18279 \family sans
18280 Overlay
18281 \family default
18282 ] and, like the label of an 
18283 \family sans
18284 Overlay
18285 \family default
18286  is shockingly magenta.
18287  Additionally, the printed 
18288 \family sans
18289 Note
18290 \family default
18291  has the page number of its 
18292 \begin_inset Quotes eld
18293 \end_inset
18294
18295 parent
18296 \begin_inset Quotes erd
18297 \end_inset
18298
18299  
18300 \family sans
18301 Slide
18302 \family default
18303 , appended by 
18304 \begin_inset Quotes eld
18305 \end_inset
18306
18307
18308 \family typewriter
18309 -
18310 \family default
18311 1
18312 \begin_inset Quotes erd
18313 \end_inset
18314
18315
18316 \begin_inset Quotes eld
18317 \end_inset
18318
18319
18320 \family typewriter
18321 -
18322 \family default
18323 2
18324 \begin_inset Quotes erd
18325 \end_inset
18326
18327
18328 \begin_inset Quotes eld
18329 \end_inset
18330
18331
18332 \family typewriter
18333 -
18334 \family default
18335 3
18336 \begin_inset Quotes erd
18337 \end_inset
18338
18339 , etc.
18340  You can have multiple 
18341 \family sans
18342 Note
18343 \family default
18344 s associated with a single 
18345 \family sans
18346 Slide
18347 \family default
18348 , and, as with 
18349 \family sans
18350 Slide
18351 \family default
18352  and 
18353 \family sans
18354 Overlay
18355 \family default
18356 , you'll probably want to break up long 
18357 \family sans
18358 Note
18359 \family default
18360 s so that they fit on a single sheet of paper.
18361 \end_layout
18362
18363 \begin_layout Standard
18364 The purpose of a 
18365 \family sans
18366 Note
18367 \family default
18368  is obvious: it contains anything additional you might want to say about
18369  a 
18370 \family sans
18371 Slide
18372 \family default
18373 .
18374  It could also be used as a sheet of reminders for a particular 
18375 \family sans
18376 Slide
18377 \family default
18378 .
18379  In the case of the latter, you might want to make use of time markers.
18380  Currently, the \SpecialChar LyX
18381  
18382 \family sans
18383 slides
18384 \family default
18385  class has no 
18386 \begin_inset Quotes eld
18387 \end_inset
18388
18389 native
18390 \begin_inset Quotes erd
18391 \end_inset
18392
18393  support for time markers, a 
18394 \noun on
18395 Sli\SpecialChar TeX
18396
18397 \noun default
18398  feature.
18399  So, you'll have to resort to using the \SpecialChar LaTeX
18400  codes.
18401 \end_layout
18402
18403 \begin_layout Standard
18404 To use time markers, you'll need to specify the extra class option 
18405 \begin_inset Quotes eld
18406 \end_inset
18407
18408
18409 \family typewriter
18410 clock
18411 \family default
18412
18413 \begin_inset Quotes erd
18414 \end_inset
18415
18416  [see section
18417 \begin_inset space ~
18418 \end_inset
18419
18420
18421 \begin_inset CommandInset ref
18422 LatexCommand ref
18423 reference "sec:slidesetup"
18424
18425 \end_inset
18426
18427 ].
18428  This option turns on timing marks, which will appear in the lower-left-hand
18429  corner of every 
18430 \family sans
18431 Note
18432 \family default
18433  you generate.
18434  To set what appears in the time marker, you use the \SpecialChar LaTeX
18435  commands 
18436 \begin_inset Quotes eld
18437 \end_inset
18438
18439
18440 \family typewriter
18441
18442 \backslash
18443 settime{}
18444 \family default
18445
18446 \begin_inset Quotes erd
18447 \end_inset
18448
18449  and 
18450 \begin_inset Quotes eld
18451 \end_inset
18452
18453
18454 \family typewriter
18455
18456 \backslash
18457 addtime{}
18458 \family default
18459
18460 \begin_inset Quotes erd
18461 \end_inset
18462
18463 .
18464  The arguments of both commands are time measured in seconds.
18465  
18466 \begin_inset Quotes eld
18467 \end_inset
18468
18469
18470 \family typewriter
18471
18472 \backslash
18473 settime{}
18474 \family default
18475
18476 \begin_inset Quotes erd
18477 \end_inset
18478
18479  sets the time marker to a given time.
18480  
18481 \begin_inset Quotes eld
18482 \end_inset
18483
18484
18485 \family typewriter
18486
18487 \backslash
18488 addtime{}
18489 \family default
18490
18491 \begin_inset Quotes erd
18492 \end_inset
18493
18494  increments the time marker by the specified amount.
18495  Using time markers and 
18496 \family sans
18497 Note
18498 \family default
18499 s in this fashion, you can remind yourself how much time to spend on a particula
18500
18501 \family sans
18502 Slide
18503 \family default
18504 .
18505 \end_layout
18506
18507 \begin_layout Standard
18508 There's one last feature to describe.
18509  Clearly, you'd like to print out all of your 
18510 \family sans
18511 Slide
18512 \family default
18513 s and 
18514 \family sans
18515 Overlay
18516 \family default
18517 s on transparencies while printing all of your 
18518 \family sans
18519 Note
18520 \family default
18521 s on plain paper.
18522  However, a 
18523 \family sans
18524 Note
18525 \family default
18526  
18527 \emph on
18528 must
18529 \emph default
18530  follow the 
18531 \family sans
18532 Slide
18533 \family default
18534  with which it is associated.
18535  What's a person to do?
18536 \end_layout
18537
18538 \begin_layout Standard
18539 Luckily, there are two \SpecialChar LaTeX
18540  commands that allow you to select what to print
18541  out.
18542  Both must be placed into the preamble of your document.
18543  The command 
18544 \begin_inset Quotes eld
18545 \end_inset
18546
18547
18548 \family typewriter
18549
18550 \backslash
18551 onlyslides{
18552 \backslash
18553 slides}
18554 \family default
18555
18556 \begin_inset Quotes erd
18557 \end_inset
18558
18559  will cause the output to contain only the 
18560 \family sans
18561 Slide
18562 \family default
18563 s and 
18564 \family sans
18565 Overlay
18566 \family default
18567 s.
18568  Correspondingly, the command 
18569 \begin_inset Quotes eld
18570 \end_inset
18571
18572
18573 \family typewriter
18574
18575 \backslash
18576 onlynotes{
18577 \backslash
18578 notes}
18579 \family default
18580
18581 \begin_inset Quotes erd
18582 \end_inset
18583
18584  prevents the output of anything but 
18585 \family sans
18586 Note
18587 \family default
18588 s.
18589  I'd advise placing both commands in the preamble and initially comment
18590  both out.
18591  You can then preview your entire presentation as you write.
18592  When you're done writing, you can then uncomment one of the two to select
18593  what you want to print.
18594  I like to uncomment 
18595 \begin_inset Quotes eld
18596 \end_inset
18597
18598
18599 \family typewriter
18600
18601 \backslash
18602 onlyslides{
18603 \backslash
18604 slides}
18605 \family default
18606
18607 \begin_inset Quotes erd
18608 \end_inset
18609
18610  , print to a file with 
18611 \begin_inset Quotes eld
18612 \end_inset
18613
18614
18615 \family typewriter
18616 -slides
18617 \family default
18618
18619 \begin_inset Quotes erd
18620 \end_inset
18621
18622  in its name, comment it back out, then uncomment 
18623 \begin_inset Quotes eld
18624 \end_inset
18625
18626
18627 \family typewriter
18628
18629 \backslash
18630 onlynotes{
18631 \backslash
18632 notes}
18633 \family default
18634
18635 \begin_inset Quotes erd
18636 \end_inset
18637
18638  and print to a 
18639 \begin_inset Quotes eld
18640 \end_inset
18641
18642
18643 \family typewriter
18644 *-notes.ps
18645 \family default
18646
18647 \begin_inset Quotes erd
18648 \end_inset
18649
18650  file.
18651  I can then send either file to a printer, loading transparencies or plain
18652  paper as appropriate.
18653 \end_layout
18654
18655 \begin_layout Standard
18656 You can also provide other arguments to the 
18657 \begin_inset Quotes eld
18658 \end_inset
18659
18660
18661 \family typewriter
18662
18663 \backslash
18664 onlyslides{}
18665 \family default
18666
18667 \begin_inset Quotes erd
18668 \end_inset
18669
18670  and 
18671 \begin_inset Quotes eld
18672 \end_inset
18673
18674
18675 \family typewriter
18676
18677 \backslash
18678 onlynotes{}
18679 \family default
18680
18681 \begin_inset Quotes erd
18682 \end_inset
18683
18684  commands.
18685  See a good \SpecialChar LaTeX
18686  book for details.
18687 \end_layout
18688
18689 \begin_layout Subsection
18690 The 
18691 \family sans
18692 slides
18693 \family default
18694  Class Template File
18695 \end_layout
18696
18697 \begin_layout Standard
18698 I have also provided a template file, 
18699 \begin_inset Quotes eld
18700 \end_inset
18701
18702
18703 \family typewriter
18704 slides.lyx
18705 \family default
18706
18707 \begin_inset Quotes erd
18708 \end_inset
18709
18710 , with the 
18711 \family sans
18712 slides
18713 \family default
18714  class.
18715  To use it, begin your new presentation with 
18716 \family sans
18717 File\SpecialChar menuseparator
18718 New
18719 \begin_inset space ~
18720 \end_inset
18721
18722 from
18723 \begin_inset space ~
18724 \end_inset
18725
18726 Template
18727 \family default
18728 .
18729  Your new \SpecialChar LyX
18730  presentation file will contain an example 
18731 \family sans
18732 Slide
18733 \family default
18734  – 
18735 \family sans
18736 Overlay
18737 \family default
18738  – 
18739 \family sans
18740 Note
18741 \family default
18742  triplet.
18743  The 
18744 \family sans
18745 Slide
18746 \family default
18747  and 
18748 \family sans
18749 Overlay
18750 \family default
18751  additionally contain an example of the use of 
18752 \family sans
18753 InvisibleText
18754 \family default
18755  and 
18756 \family sans
18757 VisibleText
18758 \family default
18759 .
18760  Lastly, the preamble will contain:
18761 \end_layout
18762
18763 \begin_layout LyX-Code
18764 % Uncomment to print out only slides and overlays
18765 \end_layout
18766
18767 \begin_layout LyX-Code
18768 %
18769 \end_layout
18770
18771 \begin_layout LyX-Code
18772 %
18773 \backslash
18774 onlyslides{
18775 \backslash
18776 slides}
18777 \begin_inset Newline newline
18778 \end_inset
18779
18780  
18781 \end_layout
18782
18783 \begin_layout LyX-Code
18784 % Uncomment to print out only notes
18785 \end_layout
18786
18787 \begin_layout LyX-Code
18788 %
18789 \end_layout
18790
18791 \begin_layout LyX-Code
18792 %
18793 \backslash
18794 onlynotes{
18795 \backslash
18796 notes}
18797 \end_layout
18798
18799 \begin_layout Standard
18800 One final thing: I created this class to support the \SpecialChar LaTeX2e
18801  
18802 \begin_inset Quotes eld
18803 \end_inset
18804
18805
18806 \noun on
18807 Sli\SpecialChar TeX
18808
18809 \noun default
18810  emulation
18811 \begin_inset Quotes erd
18812 \end_inset
18813
18814  class, one of the built-in \SpecialChar LaTeX2e
18815  classes.
18816  Neither I nor the rest of the \SpecialChar LyX
18817  Team endorse or oppose the use of this built-in
18818  slide class.
18819  It's here if you want it or need it.
18820  There exist other \SpecialChar LaTeX2e
18821  classes for creating presentations, such as the 
18822 \family sans
18823 Foils
18824 \family default
18825  class [see section
18826 \begin_inset space ~
18827 \end_inset
18828
18829
18830 \begin_inset CommandInset ref
18831 LatexCommand ref
18832 reference "sec:foiltex"
18833
18834 \end_inset
18835
18836 ] or the 
18837 \begin_inset Quotes eld
18838 \end_inset
18839
18840
18841 \family typewriter
18842 seminar
18843 \family default
18844
18845 \begin_inset Quotes erd
18846 \end_inset
18847
18848  package [present on some \SpecialChar TeX
18849  distributions].
18850  The latter is not yet supported under \SpecialChar LyX
18851 .
18852 \begin_inset Foot
18853 status collapsed
18854
18855 \begin_layout Plain Layout
18856 Perhaps you can take on the task\SpecialChar ldots
18857
18858 \end_layout
18859
18860 \end_inset
18861
18862  I know nothing about these other classes.
18863  Try them out to see what sort of alternative they provide.
18864 \end_layout
18865
18866 \begin_layout Chapter
18867 \SpecialChar LyX
18868  Features needing Extra Software
18869 \end_layout
18870
18871 \begin_layout Section
18872 Checking \SpecialChar TeX
18873
18874 \end_layout
18875
18876 \begin_layout Standard
18877 by 
18878 \noun on
18879 Asger Alstrup
18880 \end_layout
18881
18882 \begin_layout Subsection
18883 Introduction
18884 \end_layout
18885
18886 \begin_layout Standard
18887 If you have the 
18888 \family typewriter
18889 chktex
18890 \family default
18891  program installed
18892 \begin_inset Foot
18893 status collapsed
18894
18895 \begin_layout Plain Layout
18896
18897 \family typewriter
18898 chktex
18899 \family default
18900  is not yet available when you are using the \SpecialChar LaTeX
18901  distribution MiK\SpecialChar TeX
18902 .
18903 \end_layout
18904
18905 \end_inset
18906
18907 , you'll find in the 
18908 \family sans
18909 Tools
18910 \family default
18911  menu the entry: 
18912 \family sans
18913 Check
18914 \begin_inset space ~
18915 \end_inset
18916
18917 TeX
18918 \family default
18919 .
18920  You can get 
18921 \family typewriter
18922 chktex
18923 \family default
18924  from CTAN,
18925 \begin_inset Newline newline
18926 \end_inset
18927
18928
18929 \begin_inset CommandInset href
18930 LatexCommand href
18931 target "https://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
18932 literal "false"
18933
18934 \end_inset
18935
18936 .
18937 \end_layout
18938
18939 \begin_layout Standard
18940 The 
18941 \family sans
18942 Chk\SpecialChar TeX
18943
18944 \family default
18945  package is a program that was written by 
18946 \begin_inset Flex Noun
18947 status collapsed
18948
18949 \begin_layout Plain Layout
18950 Jens T.
18951 \begin_inset space ~
18952 \end_inset
18953
18954 Berger Thielemann
18955 \end_layout
18956
18957 \end_inset
18958
18959  in frustration because some constructs in \SpecialChar LaTeX
18960  are sometimes non-intuitive,
18961  and easy to forget.
18962  The program runs over your \SpecialChar LaTeX
18963  file, checks the integrity of the file, and
18964  flags some common errors.
18965  In other technical words, it is 
18966 \family typewriter
18967 lint
18968 \family default
18969  for \SpecialChar LaTeX
18970 .
18971 \end_layout
18972
18973 \begin_layout Standard
18974 Well, what is a syntax checker doing in \SpecialChar LyX
18975  which is supposed to produce correct
18976  \SpecialChar LaTeX
18977  anyways? The answer is simple: Just as 
18978 \family typewriter
18979 Lint
18980 \family default
18981  not only checks the 
18982 \emph on
18983 syntax
18984 \emph default
18985  of C programs, but also does 
18986 \emph on
18987 semantic
18988 \emph default
18989  checks for type-errors, 
18990 \family sans
18991 Chk\SpecialChar TeX
18992
18993 \family default
18994  catches some common 
18995 \emph on
18996 typographic
18997 \emph default
18998  errors, in addition to the syntactical ones.
18999  Specifically, 
19000 \family sans
19001 Chk\SpecialChar TeX
19002
19003 \family default
19004  is capable of detecting several common errors, such as
19005 \end_layout
19006
19007 \begin_layout Itemize
19008 Ellipsis detection:
19009 \begin_inset Newline newline
19010 \end_inset
19011
19012 Use \SpecialChar ldots
19013  instead of ...
19014 \end_layout
19015
19016 \begin_layout Itemize
19017 No space in front of/after parenthesis:
19018 \begin_inset Newline newline
19019 \end_inset
19020
19021 ( wrong spacing )
19022 \end_layout
19023
19024 \begin_layout Itemize
19025 Enforcement of normal space after common abbreviations:
19026 \begin_inset Newline newline
19027 \end_inset
19028
19029 e.
19030 \begin_inset space \thinspace{}
19031 \end_inset
19032
19033 g.
19034 \begin_inset space \space{}
19035 \end_inset
19036
19037 is too wide spacing.
19038 \end_layout
19039
19040 \begin_layout Itemize
19041 Enforcement of end-of-sentence space when the last sentence ends with a
19042  capital letter:
19043 \begin_inset Newline newline
19044 \end_inset
19045
19046 This is a TEST.
19047  And this is wrong spacing.
19048 \end_layout
19049
19050 \begin_layout Itemize
19051 Space in front of labels and similar commands:
19052 \begin_inset Newline newline
19053 \end_inset
19054
19055 The label should stick right up to the text to avoid falling to a wrong
19056  page.
19057  
19058 \begin_inset CommandInset label
19059 LatexCommand label
19060 name "sec:chktex"
19061
19062 \end_inset
19063
19064  
19065 \begin_inset Foot
19066 status collapsed
19067
19068 \begin_layout Plain Layout
19069 This footnote is in danger of falling off to a wrong page
19070 \end_layout
19071
19072 \end_inset
19073
19074  The label is separated too much.
19075 \end_layout
19076
19077 \begin_layout Itemize
19078 Space in front of references, instead of hard spaces:
19079 \begin_inset Newline newline
19080 \end_inset
19081
19082 If you have bad luck, the text will break right between the referenced text
19083  and reference number, and that's a pity.
19084  See section 
19085 \begin_inset CommandInset ref
19086 LatexCommand ref
19087 reference "sec:chktex"
19088
19089 \end_inset
19090
19091 .
19092 \end_layout
19093
19094 \begin_layout Itemize
19095 Use of 
19096 \begin_inset Quotes eld
19097 \end_inset
19098
19099 x
19100 \begin_inset Quotes erd
19101 \end_inset
19102
19103  instead of 
19104 \begin_inset Formula $\times$
19105 \end_inset
19106
19107  between numbers:
19108 \begin_inset Newline newline
19109 \end_inset
19110
19111 2x2 looks cheap compared to 
19112 \begin_inset Formula $2\times2$
19113 \end_inset
19114
19115 .
19116 \end_layout
19117
19118 \begin_layout Standard
19119 and more \SpecialChar ldots
19120  It is an invaluable tool when you are 
19121 \begin_inset Quotes eld
19122 \end_inset
19123
19124 finishing up
19125 \begin_inset Quotes erd
19126 \end_inset
19127
19128  your document before printing, and you should run it right after the obligatory
19129  spelling check, and before you go fine tuning the typesetting.
19130 \end_layout
19131
19132 \begin_layout Subsection
19133 How to use it
19134 \end_layout
19135
19136 \begin_layout Standard
19137 If you have the program installed, usage is as simple as choosing 
19138 \family sans
19139 Tools\SpecialChar menuseparator
19140 Check
19141 \begin_inset space ~
19142 \end_inset
19143
19144 TeX
19145 \family default
19146 .
19147  This will make \SpecialChar LyX
19148  generate a \SpecialChar LaTeX
19149  file of your document, start 
19150 \family sans
19151 Chk\SpecialChar TeX
19152
19153 \family default
19154  to check it, and then make \SpecialChar LyX
19155  insert 
19156 \begin_inset Quotes eld
19157 \end_inset
19158
19159 error boxes
19160 \begin_inset Quotes erd
19161 \end_inset
19162
19163  with the warnings from 
19164 \family sans
19165 Chk\SpecialChar TeX
19166
19167 \family default
19168 , if there were any.
19169  The warnings will be placed close to the point of the mistake, and you
19170  can quickly find them by using the 
19171 \family sans
19172 Navigate\SpecialChar menuseparator
19173 Error
19174 \family default
19175  menu item, or the shortcut key 
19176 \family sans
19177 C-g
19178 \family default
19179  from the default 
19180 \family typewriter
19181 cua
19182 \family default
19183  bind file.
19184  Open the error boxes by clicking on them with the mouse, or use the shortcut
19185  key 
19186 \family sans
19187 C-i
19188 \family default
19189  from 
19190 \family typewriter
19191 cua
19192 \family default
19193  bindings, or the corresponding 
19194 \family sans
19195 C-o
19196 \family default
19197  for the alternate 
19198 \family typewriter
19199 emacs
19200 \family default
19201  bind file.
19202  Read the warning and correct the mistake, if it is a mistake.
19203  If you have trouble understanding what the warning is about, you can safely
19204  ignore it.
19205  Remember that there is a hidden layer between the document on screen and
19206  the technical details in invoking 
19207 \family sans
19208 Chk\SpecialChar TeX
19209
19210 \family default
19211 , and this gap can make some warnings seem arcane or just plain silly.
19212 \end_layout
19213
19214 \begin_layout Standard
19215 This document is an excellent testing bed for the feature, and it should
19216  provide quite a few warnings for you to fiddle with.
19217  Since computers are only so smart, expect most of the warnings to be false
19218  alarms, though.
19219 \end_layout
19220
19221 \begin_layout Subsection
19222 How to fine tune it
19223 \end_layout
19224
19225 \begin_layout Standard
19226 Sometimes, you'll find that 
19227 \family sans
19228 Chk\SpecialChar TeX
19229
19230 \family default
19231  makes more noise than suits your mood.
19232  Then you can choose not to use it, wait until your mood changes, or try
19233  to customize 
19234 \family sans
19235 Chk\SpecialChar TeX
19236
19237 \family default
19238  to get better along with you.
19239 \end_layout
19240
19241 \begin_layout Standard
19242 Although 
19243 \family sans
19244 Chk\SpecialChar TeX
19245
19246 \family default
19247  
19248 \emph on
19249 is
19250 \emph default
19251  very configurable and extensible, you should not expect to solve all problems
19252  with 
19253 \family sans
19254 Chk\SpecialChar TeX
19255
19256 \family default
19257  in \SpecialChar LyX
19258  this way.
19259  Since \SpecialChar LyX
19260  has to generate a somewhat special \SpecialChar LaTeX
19261  file to be able to match the
19262  line numbers from the 
19263 \family sans
19264 Chk\SpecialChar TeX
19265
19266 \family default
19267  output
19268 \begin_inset Foot
19269 status collapsed
19270
19271 \begin_layout Plain Layout
19272 You can inspect the specific output from 
19273 \family sans
19274 chktex
19275 \family default
19276  by using 
19277 \family sans
19278 Document\SpecialChar menuseparator
19279 \SpecialChar LaTeX
19280
19281 \begin_inset space ~
19282 \end_inset
19283
19284 Log
19285 \family default
19286  right after a 
19287 \family sans
19288 chktex
19289 \family default
19290  run.
19291 \end_layout
19292
19293 \end_inset
19294
19295  to the internal document structure, some of the warnings will not appear
19296  correctly.
19297  There are two things you can do about this:
19298 \end_layout
19299
19300 \begin_layout Itemize
19301 Fine tune the 
19302 \family sans
19303 Chk\SpecialChar TeX
19304
19305 \family default
19306  invocation command line in 
19307 \begin_inset Flex Noun
19308 status collapsed
19309
19310 \begin_layout Plain Layout
19311 Tools\SpecialChar menuseparator
19312 Preferences\SpecialChar menuseparator
19313 Output\SpecialChar menuseparator
19314 LaTeX\SpecialChar menuseparator
19315 CheckTeX command
19316 \end_layout
19317
19318 \end_inset
19319
19320 , or the global 
19321 \family sans
19322 Chk\SpecialChar TeX
19323
19324 \family default
19325  installation configuration file (usually with the file 
19326 \family typewriter
19327 chktexrc
19328 \family default
19329 ).
19330  See below to learn what warnings can be enabled and disabled on the command
19331  line.
19332 \end_layout
19333
19334 \begin_layout Itemize
19335 Export your document as a raw \SpecialChar LaTeX
19336  file using 
19337 \family sans
19338 File\SpecialChar menuseparator
19339 Export\SpecialChar menuseparator
19340 \SpecialChar LaTeX
19341
19342 \family default
19343  and run 
19344 \family typewriter
19345 chktex
19346 \family default
19347  manually on that.
19348  Invoked in this way, it can be a hassle to find the corresponding place
19349  in the document inside \SpecialChar LyX
19350 , but with a little patience, you should be able
19351  to do it.
19352 \end_layout
19353
19354 \begin_layout Standard
19355 Here follows the warning messages that can be enabled and disabled in 
19356 \family sans
19357 Preferences
19358 \family default
19359 .
19360  Use 
19361 \family typewriter
19362 -n#
19363 \family default
19364  to disable a warning, and 
19365 \family typewriter
19366 -w#
19367 \family default
19368  to enable a warning.
19369  The emphasized entries are disabled by default, because the default is
19370  "
19371 \family typewriter
19372 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19373 \family default
19374 ".
19375 \end_layout
19376
19377 \begin_layout Standard
19378 Notice that you should only use the options that enable and disable warnings,
19379  because \SpecialChar LyX
19380  relies on some of the other command line parameters to be set
19381  in a specific way to have a chance to communicate with 
19382 \family typewriter
19383 chktex
19384 \family default
19385 .
19386 \end_layout
19387
19388 \begin_layout Enumerate
19389
19390 \size small
19391 \emph on
19392 Command terminated with space.
19393 \end_layout
19394
19395 \begin_layout Enumerate
19396
19397 \size small
19398 Non-breaking space (
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 ) should have been used.
19411 \end_layout
19412
19413 \begin_layout Enumerate
19414
19415 \size small
19416 \emph on
19417 You should enclose the previous parenthesis with 
19418 \begin_inset Quotes eld
19419 \end_inset
19420
19421
19422 \family typewriter
19423 {}
19424 \family default
19425
19426 \begin_inset Quotes erd
19427 \end_inset
19428
19429 .
19430 \end_layout
19431
19432 \begin_layout Enumerate
19433
19434 \size small
19435 Italic correction (
19436 \begin_inset Quotes eld
19437 \end_inset
19438
19439
19440 \family typewriter
19441
19442 \backslash
19443 /
19444 \family default
19445
19446 \begin_inset Quotes erd
19447 \end_inset
19448
19449 ) found in non-italic buffer.
19450 \end_layout
19451
19452 \begin_layout Enumerate
19453
19454 \size small
19455 Italic correction (
19456 \begin_inset Quotes eld
19457 \end_inset
19458
19459
19460 \family typewriter
19461
19462 \backslash
19463 /
19464 \family default
19465
19466 \begin_inset Quotes erd
19467 \end_inset
19468
19469 ) found more than once.
19470 \end_layout
19471
19472 \begin_layout Enumerate
19473
19474 \size small
19475 \emph on
19476 No italic correction (
19477 \begin_inset Quotes eld
19478 \end_inset
19479
19480
19481 \family typewriter
19482
19483 \backslash
19484 /
19485 \family default
19486
19487 \begin_inset Quotes erd
19488 \end_inset
19489
19490 ) found.
19491 \end_layout
19492
19493 \begin_layout Enumerate
19494
19495 \size small
19496 Accent command 
19497 \begin_inset Quotes eld
19498 \end_inset
19499
19500
19501 \family typewriter
19502 cmd
19503 \family default
19504
19505 \begin_inset Quotes erd
19506 \end_inset
19507
19508  needs use of 
19509 \begin_inset Quotes eld
19510 \end_inset
19511
19512
19513 \family typewriter
19514 cmd
19515 \family default
19516
19517 \begin_inset Quotes erd
19518 \end_inset
19519
19520 .
19521 \end_layout
19522
19523 \begin_layout Enumerate
19524
19525 \size small
19526 Wrong length of dash may have been used.
19527 \end_layout
19528
19529 \begin_layout Enumerate
19530
19531 \size small
19532 \emph on
19533 \begin_inset Quotes eld
19534 \end_inset
19535
19536
19537 \family typewriter
19538 %s
19539 \family default
19540
19541 \begin_inset Quotes erd
19542 \end_inset
19543
19544  expected, found 
19545 \begin_inset Quotes eld
19546 \end_inset
19547
19548
19549 \family typewriter
19550 %s
19551 \family default
19552
19553 \begin_inset Quotes erd
19554 \end_inset
19555
19556 .
19557 \end_layout
19558
19559 \begin_layout Enumerate
19560
19561 \size small
19562 Solo 
19563 \begin_inset Quotes eld
19564 \end_inset
19565
19566
19567 \family typewriter
19568 %s
19569 \family default
19570
19571 \begin_inset Quotes erd
19572 \end_inset
19573
19574  found.
19575 \end_layout
19576
19577 \begin_layout Enumerate
19578
19579 \size small
19580 You should use 
19581 \begin_inset Quotes eld
19582 \end_inset
19583
19584
19585 \family typewriter
19586 %s
19587 \family default
19588
19589 \begin_inset Quotes erd
19590 \end_inset
19591
19592  to achieve an ellipsis.
19593 \end_layout
19594
19595 \begin_layout Enumerate
19596
19597 \size small
19598 Inter-word spacing (
19599 \begin_inset Quotes eld
19600 \end_inset
19601
19602
19603 \family typewriter
19604
19605 \backslash
19606
19607 \family default
19608  
19609 \begin_inset Quotes eld
19610 \end_inset
19611
19612 ) should perhaps be used.
19613 \end_layout
19614
19615 \begin_layout Enumerate
19616
19617 \size small
19618 Inter-sentence spacing (
19619 \begin_inset Quotes eld
19620 \end_inset
19621
19622
19623 \family typewriter
19624
19625 \backslash
19626 @
19627 \family default
19628
19629 \begin_inset Quotes erd
19630 \end_inset
19631
19632 ) should perhaps be used.
19633 \end_layout
19634
19635 \begin_layout Enumerate
19636
19637 \size small
19638 Could not find argument for command.
19639 \end_layout
19640
19641 \begin_layout Enumerate
19642
19643 \size small
19644 No match found for 
19645 \begin_inset Quotes eld
19646 \end_inset
19647
19648
19649 \family typewriter
19650 %s
19651 \family default
19652
19653 \begin_inset Quotes erd
19654 \end_inset
19655
19656 .
19657 \end_layout
19658
19659 \begin_layout Enumerate
19660
19661 \size small
19662 Math mode still on at end of \SpecialChar LaTeX
19663  file.
19664 \end_layout
19665
19666 \begin_layout Enumerate
19667
19668 \size small
19669 Number of 
19670 \begin_inset Quotes eld
19671 \end_inset
19672
19673
19674 \family typewriter
19675 char
19676 \family default
19677
19678 \begin_inset Quotes erd
19679 \end_inset
19680
19681  doesn't match the number of 
19682 \begin_inset Quotes eld
19683 \end_inset
19684
19685
19686 \family typewriter
19687 char
19688 \family default
19689
19690 \begin_inset Quotes erd
19691 \end_inset
19692
19693 .
19694 \end_layout
19695
19696 \begin_layout Enumerate
19697
19698 \size small
19699 You should use either 
19700 \family typewriter
19701
19702 \begin_inset Quotes eld
19703 \end_inset
19704
19705
19706 \family default
19707  or 
19708 \family typewriter
19709
19710 \begin_inset Quotes erd
19711 \end_inset
19712
19713
19714 \family default
19715  as an alternative to 
19716 \begin_inset Quotes eld
19717 \end_inset
19718
19719
19720 \family typewriter
19721 "
19722 \family default
19723
19724 \begin_inset Quotes erd
19725 \end_inset
19726
19727 .
19728 \end_layout
19729
19730 \begin_layout Enumerate
19731
19732 \size small
19733 You should use "
19734 \family typewriter
19735 '
19736 \family default
19737 " (ASCII 39) instead of "
19738 \family typewriter
19739 ´
19740 \family default
19741 " (ASCII 180).
19742 \end_layout
19743
19744 \begin_layout Enumerate
19745
19746 \size small
19747 User-specified pattern found.
19748 \end_layout
19749
19750 \begin_layout Enumerate
19751
19752 \size small
19753 This command might not be intended.
19754 \end_layout
19755
19756 \begin_layout Enumerate
19757
19758 \size small
19759 \emph on
19760 Comment displayed.
19761 \end_layout
19762
19763 \begin_layout Enumerate
19764
19765 \size small
19766 Either 
19767 \family typewriter
19768 ''
19769 \backslash
19770 ,'
19771 \family default
19772  or 
19773 \family typewriter
19774 '
19775 \backslash
19776 ,''
19777 \family default
19778  will look better.
19779 \end_layout
19780
19781 \begin_layout Enumerate
19782
19783 \size small
19784 Delete this space to maintain correct page references.
19785 \end_layout
19786
19787 \begin_layout Enumerate
19788
19789 \size small
19790 \emph on
19791 You might wish to put this between a pair of 
19792 \begin_inset Quotes eld
19793 \end_inset
19794
19795
19796 \family typewriter
19797 {}
19798 \family default
19799
19800 \begin_inset Quotes erd
19801 \end_inset
19802
19803 .
19804 \end_layout
19805
19806 \begin_layout Enumerate
19807
19808 \size small
19809 You ought to remove spaces in front of punctuation.
19810 \end_layout
19811
19812 \begin_layout Enumerate
19813
19814 \size small
19815 Could not execute \SpecialChar LaTeX
19816  command.
19817 \end_layout
19818
19819 \begin_layout Enumerate
19820
19821 \size small
19822 Don't use 
19823 \family typewriter
19824
19825 \backslash
19826 /
19827 \family default
19828  in front of small punctuation.
19829 \end_layout
19830
19831 \begin_layout Enumerate
19832
19833 \family typewriter
19834 \size small
19835 $
19836 \backslash
19837 times$
19838 \family default
19839  may look prettier here.
19840 \end_layout
19841
19842 \begin_layout Enumerate
19843
19844 \size small
19845 \emph on
19846 Multiple spaces detected in output.
19847 \end_layout
19848
19849 \begin_layout Enumerate
19850
19851 \size small
19852 This text may be ignored.
19853 \end_layout
19854
19855 \begin_layout Enumerate
19856
19857 \size small
19858 Use 
19859 \family typewriter
19860
19861 \begin_inset Quotes eld
19862 \end_inset
19863
19864
19865 \family default
19866  to begin quotation, not 
19867 \family typewriter
19868 '
19869 \family default
19870 .
19871 \end_layout
19872
19873 \begin_layout Enumerate
19874
19875 \size small
19876 Use 
19877 \family typewriter
19878 '
19879 \family default
19880  to end quotation, not 
19881 \family typewriter
19882
19883 \begin_inset Quotes eld
19884 \end_inset
19885
19886
19887 \family default
19888 .
19889 \end_layout
19890
19891 \begin_layout Enumerate
19892
19893 \size small
19894 Don't mix quotes.
19895 \end_layout
19896
19897 \begin_layout Enumerate
19898
19899 \size small
19900 You should perhaps use 
19901 \begin_inset Quotes eld
19902 \end_inset
19903
19904
19905 \family typewriter
19906 cmd
19907 \family default
19908
19909 \begin_inset Quotes erd
19910 \end_inset
19911
19912  instead.
19913 \end_layout
19914
19915 \begin_layout Enumerate
19916
19917 \size small
19918 You should put a space in front of/after parenthesis.
19919 \end_layout
19920
19921 \begin_layout Enumerate
19922
19923 \size small
19924 You should avoid spaces in front of/after parenthesis.
19925 \end_layout
19926
19927 \begin_layout Enumerate
19928
19929 \size small
19930 \emph on
19931 You should not use punctuation in front of/after quotes.
19932 \end_layout
19933
19934 \begin_layout Enumerate
19935
19936 \size small
19937 Double space found.
19938 \end_layout
19939
19940 \begin_layout Enumerate
19941
19942 \size small
19943 You should put punctuation outside inner/inside display math mode.
19944 \end_layout
19945
19946 \begin_layout Enumerate
19947
19948 \size small
19949 You ought to not use primitive \SpecialChar TeX
19950  in \SpecialChar LaTeX
19951  code.
19952 \end_layout
19953
19954 \begin_layout Enumerate
19955
19956 \size small
19957 You should remove spaces in front of 
19958 \begin_inset Quotes eld
19959 \end_inset
19960
19961
19962 \family typewriter
19963 %s
19964 \family default
19965
19966 \begin_inset Quotes erd
19967 \end_inset
19968
19969
19970 \end_layout
19971
19972 \begin_layout Enumerate
19973
19974 \size small
19975 \begin_inset Quotes eld
19976 \end_inset
19977
19978
19979 \family typewriter
19980 %s
19981 \family default
19982
19983 \begin_inset Quotes erd
19984 \end_inset
19985
19986  is normally not followed by 
19987 \begin_inset Quotes eld
19988 \end_inset
19989
19990
19991 \family typewriter
19992 %c
19993 \family default
19994
19995 \begin_inset Quotes erd
19996 \end_inset
19997
19998 .
19999 \end_layout
20000
20001 \begin_layout Standard
20002 In later versions of \SpecialChar LyX
20003 , we hope to provide a more complete interface to this
20004  tool (and it's smaller cousin 
20005 \family typewriter
20006 lacheck
20007 \family default
20008 ) to exploit the full power of it.
20009  But it's not exactly useless as it is now: go try it on one of your existing
20010  documents of a certain length and be surprised.
20011 \end_layout
20012
20013 \begin_layout Section
20014 Version Control in \SpecialChar LyX
20015
20016 \end_layout
20017
20018 \begin_layout Standard
20019 by
20020 \noun on
20021  Lars Gullik Bjønnes 
20022 \noun default
20023 and 
20024 \noun on
20025 Pavel Sanda
20026 \end_layout
20027
20028 \begin_layout Subsection
20029 Introduction
20030 \end_layout
20031
20032 \begin_layout Standard
20033 \SpecialChar LyX
20034  supports some of the most basic RCS/CVS/SVN/GIT commands.
20035  If you need something a bit more sophisticated you will have to do that
20036  manually in a terminal.
20037 \end_layout
20038
20039 \begin_layout Standard
20040 Also note that CVS support is not as good as subversion support, so we advise
20041  using SVN instead.
20042  A good place to start learning Subversion is the SVN Book
20043 \begin_inset Foot
20044 status collapsed
20045
20046 \begin_layout Plain Layout
20047 \begin_inset CommandInset href
20048 LatexCommand href
20049 target "http://svnbook.red-bean.com/"
20050 literal "false"
20051
20052 \end_inset
20053
20054
20055 \end_layout
20056
20057 \end_inset
20058
20059 .
20060  In the case of RCS you should read 
20061 \begin_inset Quotes eld
20062 \end_inset
20063
20064 rcsintro
20065 \begin_inset Quotes erd
20066 \end_inset
20067
20068  (a man file, read it with 
20069 \family typewriter
20070 man rcsintro
20071 \family default
20072 ).
20073  This file describes all the basic features of RCS.
20074  You should especially notice the comment about a RCS directory, and the
20075  notion of a master RCS file (the file ending in 
20076 \family typewriter
20077 ,v
20078 \family default
20079 ).
20080 \end_layout
20081
20082 \begin_layout Standard
20083 Before you begin to use the version control features in \SpecialChar LyX
20084 , you should be
20085  familiar with RCS/CVS/SVN/GIT usage.
20086  The implementation in \SpecialChar LyX
20087  assumes a recent version of the GNU RCS or CVS/SVN
20088  package — no guarantees are made for older versions.
20089  Most of the log messages are not currently displayed after operations —
20090  you can check them in the Messages pane if you are unsure.
20091  Regular users of version control will appreciate the VC toolbar, which
20092  can be enabled via 
20093 \family sans
20094 View\SpecialChar menuseparator
20095 Toolbars\SpecialChar menuseparator
20096 Version
20097 \begin_inset space ~
20098 \end_inset
20099
20100 Control
20101 \family default
20102 .
20103 \end_layout
20104
20105 \begin_layout Standard
20106 For introducing your own external commands consult 
20107 \begin_inset Flex Code
20108 status collapsed
20109
20110 \begin_layout Plain Layout
20111 vc-command
20112 \end_layout
20113
20114 \end_inset
20115
20116  in the manual 
20117 \emph on
20118 \SpecialChar LyX
20119  Functions
20120 \emph default
20121 .
20122 \end_layout
20123
20124 \begin_layout Standard
20125 It is strongly recommended to store documents in uncompressed format if
20126  using version control (uncheck 
20127 \family sans
20128 Document\SpecialChar menuseparator
20129 Compressed
20130 \family default
20131  if it is checked): Uncompressed LyX documents are text files and therefore
20132  for merging two different versions by version control systems.
20133  Compressed LyX documents are binary files, which cannot be merged by version
20134  control systems.
20135 \end_layout
20136
20137 \begin_layout Subsection
20138 RCS commands in \SpecialChar LyX
20139
20140 \end_layout
20141
20142 \begin_layout Standard
20143 The following sections describe the RCS commands supported by \SpecialChar LyX
20144 .
20145  You can find them in the 
20146 \family sans
20147 File\SpecialChar menuseparator
20148 Version
20149 \begin_inset space ~
20150 \end_inset
20151
20152 Control
20153 \family default
20154  submenu.
20155  \SpecialChar LyX
20156  was tested against RCS 5.7/5.8.
20157 \end_layout
20158
20159 \begin_layout Subsubsection
20160
20161 \family sans
20162 Register
20163 \end_layout
20164
20165 \begin_layout Standard
20166 If your document is not under revision control, this is the only item shown
20167  in the menu.
20168  And if it is under revision control, the 
20169 \family sans
20170 Register
20171 \family default
20172  item is not visible.
20173  
20174 \end_layout
20175
20176 \begin_layout Standard
20177 This command registers your document with RCS (unless you are under the
20178  directory managed by CVS)\SpecialChar endofsentence
20179  You are asked interactively to supply an initial
20180  description of the document.
20181  The document is now set in Read-Only mode and you have to 
20182 \family sans
20183 Check
20184 \begin_inset space ~
20185 \end_inset
20186
20187 Out
20188 \begin_inset space ~
20189 \end_inset
20190
20191 For
20192 \begin_inset space ~
20193 \end_inset
20194
20195 Edit
20196 \family default
20197 , before making any changes to it.
20198  A document under revision control has a 
20199 \begin_inset Quotes eld
20200 \end_inset
20201
20202 [RCS:<version> <locker>]
20203 \begin_inset Quotes erd
20204 \end_inset
20205
20206  item tagged to the filename in the minibuffer.
20207 \end_layout
20208
20209 \begin_layout Standard
20210 RCS command that is run:
20211 \end_layout
20212
20213 \begin_layout LyX-Code
20214
20215 \family typewriter
20216 ci -q -u -i -t-"<initial description>" <file-name>
20217 \end_layout
20218
20219 \begin_layout Standard
20220 Read 
20221 \family typewriter
20222 man ci
20223 \family default
20224  to understand the switches.
20225  
20226 \end_layout
20227
20228 \begin_layout Subsubsection
20229
20230 \family sans
20231 Check In Changes
20232 \end_layout
20233
20234 \begin_layout Standard
20235 When you are finished editing a file, you check in your changes.
20236  When you do this, you are asked for a description of the changes.
20237  This is stored in the history log.
20238  The version number is bumped, your changes are applied to the master RCS
20239  file, the document is unlocked and set to Read-Only mode.
20240 \end_layout
20241
20242 \begin_layout Itemize
20243 RCS command: 
20244 \family typewriter
20245 ci -q -u -m"<description>" <file-name>
20246 \end_layout
20247
20248 \begin_layout Subsubsection
20249
20250 \family sans
20251 Check Out For Edit
20252 \end_layout
20253
20254 \begin_layout Standard
20255 By doing this you lock the document so that only you can edit it.
20256  This will also make the document Read-Write only for you.
20257  You will usually continue editing for a while and when you are finished
20258  you check in your changes.
20259  The status line is changed to reflect that you have locked the file.
20260 \end_layout
20261
20262 \begin_layout Itemize
20263 RCS command: 
20264 \family typewriter
20265 co -q -l <file-name>
20266 \end_layout
20267
20268 \begin_layout Subsubsection
20269
20270 \family sans
20271 Revert To Repository Version
20272 \end_layout
20273
20274 \begin_layout Standard
20275 This will discard all changes made to the document since the last check
20276  in.
20277  You get a warning before changes are discarded.
20278 \end_layout
20279
20280 \begin_layout Itemize
20281 RCS command: 
20282 \family typewriter
20283 co -f -u<version> <file-name>
20284 \end_layout
20285
20286 \begin_layout Subsubsection
20287
20288 \family sans
20289 Copy
20290 \end_layout
20291
20292 \begin_layout Standard
20293 This will create a copy of the current document.
20294  Since RCS does not support copy operations natively, the version history
20295  is not preserved, and the copy is added as a new file.
20296  It requires a clean document without any changes since the last checkin.
20297  You are asked for a file name and a description of the copy operation.
20298  After that the copy is created, both locally and in the repository.
20299  If the parent directories of the copied and original document differ, all
20300  relative paths of included files of the copy are adjusted (like in 
20301 \family sans
20302 File\SpecialChar menuseparator
20303 Save As
20304 \family default
20305 \SpecialChar ldots
20306 ).
20307  Finally, the copy is loaded instead of the original document.
20308 \end_layout
20309
20310 \begin_layout Labeling
20311 \labelwidthstring 00.00.0000
20312 RCS
20313 \begin_inset space ~
20314 \end_inset
20315
20316 commands: 
20317 \begin_inset space ~
20318 \end_inset
20319
20320
20321 \begin_inset Newline newline
20322 \end_inset
20323
20324 Copy 
20325 \begin_inset Flex Code
20326 status collapsed
20327
20328 \begin_layout Plain Layout
20329
20330 \family typewriter
20331 \begin_inset Quotes qld
20332 \end_inset
20333
20334 <file-name>
20335 \begin_inset Quotes qld
20336 \end_inset
20337
20338
20339 \end_layout
20340
20341 \end_inset
20342
20343  to 
20344 \begin_inset Flex Code
20345 status collapsed
20346
20347 \begin_layout Plain Layout
20348
20349 \family typewriter
20350 \begin_inset Quotes qld
20351 \end_inset
20352
20353 <new-file-name>
20354 \begin_inset Quotes qld
20355 \end_inset
20356
20357
20358 \end_layout
20359
20360 \end_inset
20361
20362
20363 \begin_inset Newline newline
20364 \end_inset
20365
20366
20367 \begin_inset Flex Code
20368 status collapsed
20369
20370 \begin_layout Plain Layout
20371 ci -q -u 
20372 \family typewriter
20373 -i 
20374 \begin_inset Quotes qld
20375 \end_inset
20376
20377 <new-file-name>
20378 \begin_inset Quotes qld
20379 \end_inset
20380
20381
20382 \end_layout
20383
20384 \end_inset
20385
20386
20387 \end_layout
20388
20389 \begin_layout Subsubsection
20390
20391 \family sans
20392 Undo Last Checkin
20393 \end_layout
20394
20395 \begin_layout Standard
20396 This makes as if the last check in never happened.
20397  No changes are made to the document loaded into \SpecialChar LyX
20398 , but the last version
20399  is removed from the master RCS file.
20400 \end_layout
20401
20402 \begin_layout Itemize
20403 RCS command: 
20404 \family typewriter
20405 rcs -o<version> <file-name>
20406 \end_layout
20407
20408 \begin_layout Subsubsection
20409
20410 \family sans
20411 Show History
20412 \end_layout
20413
20414 \begin_layout Standard
20415 This shows the complete history of the RCS document.
20416  The output of 
20417 \family typewriter
20418 rlog <file-name>
20419 \family default
20420  is shown in a browser.
20421  See 
20422 \family typewriter
20423 man rlog
20424 \family default
20425  for more info.
20426 \end_layout
20427
20428 \begin_layout Subsubsection
20429 Revision info
20430 \end_layout
20431
20432 \begin_layout Standard
20433 \SpecialChar LyX
20434  supports RCS version number, author name, date and time of last commit.
20435  All those are extracted from 
20436 \family typewriter
20437 rlog -r <file-name>
20438 \family default
20439 .
20440  See 
20441 \begin_inset CommandInset ref
20442 LatexCommand ref
20443 reference "subsec:VCS-Revision-Information"
20444
20445 \end_inset
20446
20447  for details.
20448 \end_layout
20449
20450 \begin_layout Subsection
20451 CVS commands in \SpecialChar LyX
20452
20453 \end_layout
20454
20455 \begin_layout Standard
20456 A subset of CVS operations is supported by \SpecialChar LyX
20457 .
20458  You can find the commands in the 
20459 \family sans
20460 File\SpecialChar menuseparator
20461 Version
20462 \begin_inset space ~
20463 \end_inset
20464
20465 Control
20466 \family default
20467  submenu.
20468  The version control system SVN is more powerful, so please use it instead
20469  of CVS if possible.
20470 \end_layout
20471
20472 \begin_layout Subsubsection
20473
20474 \family sans
20475 General CVS usage
20476 \end_layout
20477
20478 \begin_layout Standard
20479 If you start from scratch with CVS you have to create your repository and
20480  checkout the working copy with external tools.
20481  If you're using a client-server setup you may need to login before doing
20482  the first repository checkout.
20483 \end_layout
20484
20485 \begin_layout Standard
20486 If your documents are under revision control and others are using the same
20487  repository problems arise when different changes to the same document at
20488  the same location happen.
20489  Standard CVS repositories don't operate with a file locking mechanism.
20490  This may be surprising, but conflicts only occur if people disagree on
20491  the proper content of the same part of a document.
20492  So, if co-workers are used to communicate regularly, these conflicts occur
20493  rarely.
20494  If they don't communicate they have a fundamental problem anyway.
20495  Nevertheless some people like to work with so called 
20496 \begin_inset Quotes eld
20497 \end_inset
20498
20499 reserved checkouts
20500 \begin_inset Quotes erd
20501 \end_inset
20502
20503 .
20504  If they do so the working copy of all files is readonly when checked out
20505  first and the user starts editing after using a special command to make
20506  the working copy writable.
20507  When the changes are checked in the working copy returns to readonly state.
20508  With \SpecialChar LyX
20509  one has to edit the 
20510 \begin_inset Flex Code
20511 status collapsed
20512
20513 \begin_layout Plain Layout
20514 .cvsrc
20515 \end_layout
20516
20517 \end_inset
20518
20519  file and add the line 
20520 \begin_inset Flex Code
20521 status collapsed
20522
20523 \begin_layout Plain Layout
20524 cvs -r
20525 \end_layout
20526
20527 \end_inset
20528
20529  to work with reserved checkouts.
20530  The benefit is the possibility to see who is using a writable copy of some
20531  document.
20532  It's not guaranteed only one user makes a copy writable.
20533 \end_layout
20534
20535 \begin_layout Standard
20536 \SpecialChar LyX
20537  tries to guess if you're using reserved or non-reserved checkouts.
20538  If your working copy is readonly or it is writable and an additional copy
20539  of your document exists in the CVS/Base sub-directory a reserved otherwise
20540  a non-reserved checkout is assumed.
20541  When a reserved checkout is detected you have to use 
20542 \begin_inset Flex Noun
20543 status collapsed
20544
20545 \begin_layout Plain Layout
20546 Check Out
20547 \end_layout
20548
20549 \end_inset
20550
20551  to make your working copy writable if it's readonly.
20552  After doing so the 
20553 \begin_inset Flex Noun
20554 status collapsed
20555
20556 \begin_layout Plain Layout
20557 Check In
20558 \end_layout
20559
20560 \end_inset
20561
20562  operation is possible and that makes your working copy readonly again after
20563  transferring your changes to the repository.
20564 \end_layout
20565
20566 \begin_layout Standard
20567 More information about CVS can be found here 
20568 \begin_inset Flex URL
20569 status collapsed
20570
20571 \begin_layout Plain Layout
20572
20573 http://www.nongnu.org/cvs
20574 \end_layout
20575
20576 \end_inset
20577
20578  and here 
20579 \begin_inset Flex URL
20580 status collapsed
20581
20582 \begin_layout Plain Layout
20583
20584 http://ximbiot.com/cvs
20585 \end_layout
20586
20587 \end_inset
20588
20589 .
20590 \end_layout
20591
20592 \begin_layout Standard
20593 Read 
20594 \family typewriter
20595 man cvs
20596 \family default
20597  to understand the sub-commands and the switches mentioned below.
20598 \end_layout
20599
20600 \begin_layout Subsubsection
20601
20602 \family sans
20603 Register
20604 \end_layout
20605
20606 \begin_layout Standard
20607 If your document is not under revision control, this is the only item shown
20608  in the menu.
20609  And if it is under revision control, the 
20610 \family sans
20611 Register
20612 \family default
20613  item is not visible.
20614  
20615 \end_layout
20616
20617 \begin_layout Standard
20618 This command registers in CVS your document 
20619 \begin_inset Flex Strong
20620 status collapsed
20621
20622 \begin_layout Plain Layout
20623
20624 \emph on
20625 only
20626 \end_layout
20627
20628 \end_inset
20629
20630  in the case you have already the documents directory under CVS control
20631  (in particular 
20632 \family typewriter
20633 CVS/Entries
20634 \family default
20635  file exists).
20636  This means you have to create or checkout the archive by yourself using
20637  external tools.
20638  (In case you forget that step \SpecialChar LyX
20639  registers the document with RCS.)
20640 \end_layout
20641
20642 \begin_layout Standard
20643 Then you are asked interactively to supply an initial description of the
20644  document.
20645  Don't forget that registered file is not yet checked in.
20646 \end_layout
20647
20648 \begin_layout Standard
20649 CVS command that is run: 
20650 \family typewriter
20651 cvs -q add -m"<entered message>" "<file-name>"
20652 \end_layout
20653
20654 \begin_layout Standard
20655 The term 
20656 \family typewriter
20657 "<file-name>"
20658 \family default
20659  above and for all other CVS commands is an abbreviation for 
20660 \begin_inset Quotes eld
20661 \end_inset
20662
20663 change the current working directory to file location and use the file name
20664  without path component as argument
20665 \begin_inset Quotes erd
20666 \end_inset
20667
20668 .
20669 \end_layout
20670
20671 \begin_layout Subsubsection
20672
20673 \family sans
20674 Check In Changes
20675 \end_layout
20676
20677 \begin_layout Standard
20678 When you are finished editing a file, you commit your changes.
20679  When you do this and you had changed the document, you are asked for a
20680  description of the changes.
20681  After that changes are written to the repository.
20682  In case you didn't change the document and a reserved checkout is detected
20683  the reservation made on 
20684 \begin_inset Flex Noun
20685 status collapsed
20686
20687 \begin_layout Plain Layout
20688 Check Out
20689 \end_layout
20690
20691 \end_inset
20692
20693  is undone.
20694 \end_layout
20695
20696 \begin_layout Labeling
20697 \labelwidthstring 00.00.0000
20698 CVS
20699 \begin_inset space ~
20700 \end_inset
20701
20702 command: 
20703 \begin_inset space ~
20704 \end_inset
20705
20706
20707 \begin_inset Newline newline
20708 \end_inset
20709
20710
20711 \begin_inset Flex Code
20712 status collapsed
20713
20714 \begin_layout Plain Layout
20715 cvs 
20716 \family typewriter
20717 -q commit -m"<description>" "<file-name>"
20718 \end_layout
20719
20720 \end_inset
20721
20722  or
20723 \begin_inset Newline newline
20724 \end_inset
20725
20726
20727 \begin_inset Flex Code
20728 status collapsed
20729
20730 \begin_layout Plain Layout
20731 cvs -q unedit 
20732 \family typewriter
20733 "<file-name>"
20734 \end_layout
20735
20736 \end_inset
20737
20738
20739 \end_layout
20740
20741 \begin_layout Subsubsection
20742
20743 \family sans
20744 Check Out Changes
20745 \end_layout
20746
20747 \begin_layout Standard
20748 When you are sharing a repository with others, you may have to incorporate
20749  their changes into your working copy.
20750 \end_layout
20751
20752 \begin_layout Standard
20753 CVS command: 
20754 \family typewriter
20755 cvs -q update "<file-name>"
20756 \end_layout
20757
20758 \begin_layout Standard
20759 If a readonly checkout is detected the working copy is made writable and
20760  reserved.
20761 \end_layout
20762
20763 \begin_layout Standard
20764 CVS command: 
20765 \family typewriter
20766 cvs -q edit "<file-name>"
20767 \end_layout
20768
20769 \begin_layout Subsubsection
20770
20771 \family sans
20772 Revert To Repository Version
20773 \end_layout
20774
20775 \begin_layout Standard
20776 This will discard all changes made to the document since the last check
20777  in.
20778  You get a warning before changes are discarded.
20779  Firstly the file is deleted, secondly CVS update command is run.
20780 \end_layout
20781
20782 \begin_layout Standard
20783 CVS command: 
20784 \family typewriter
20785 cvs -q update "<file-name>"
20786 \end_layout
20787
20788 \begin_layout Standard
20789 If a reserved checkout is detected and the working copy has no changes only
20790  the reservation is undone.
20791 \end_layout
20792
20793 \begin_layout Standard
20794 CVS command: 
20795 \family typewriter
20796 cvs -q unedit "<file-name>"
20797 \end_layout
20798
20799 \begin_layout Subsubsection
20800
20801 \family sans
20802 Copy
20803 \end_layout
20804
20805 \begin_layout Standard
20806 This will create a copy of the current document.
20807  Since CVS does not support copy operations natively, the version history
20808  is not preserved, and the copy is added as a new file.
20809  It requires a clean document without any changes since the last checkin.
20810  You are asked for a file name and a description of the copy operation.
20811  After that the copy is created, both locally and in the repository.
20812  If the parent directories of the copied and original document differ, all
20813  relative paths of included files of the copy are adjusted (like in 
20814 \family sans
20815 File\SpecialChar menuseparator
20816 Save As
20817 \family default
20818 \SpecialChar ldots
20819 ).
20820  Finally, the copy is loaded instead of the original document.
20821 \end_layout
20822
20823 \begin_layout Labeling
20824 \labelwidthstring 00.00.0000
20825 CVS
20826 \begin_inset space ~
20827 \end_inset
20828
20829 commands: 
20830 \begin_inset space ~
20831 \end_inset
20832
20833
20834 \begin_inset Newline newline
20835 \end_inset
20836
20837 Copy 
20838 \begin_inset Flex Code
20839 status collapsed
20840
20841 \begin_layout Plain Layout
20842 "<file-name>"
20843 \end_layout
20844
20845 \end_inset
20846
20847  to 
20848 \begin_inset Flex Code
20849 status collapsed
20850
20851 \begin_layout Plain Layout
20852 "<new-file-name>"
20853 \end_layout
20854
20855 \end_inset
20856
20857
20858 \begin_inset Newline newline
20859 \end_inset
20860
20861
20862 \begin_inset Flex Code
20863 status collapsed
20864
20865 \begin_layout Plain Layout
20866 cvs -q add "<new-file-name>"
20867 \end_layout
20868
20869 \end_inset
20870
20871
20872 \end_layout
20873
20874 \begin_layout Subsubsection
20875
20876 \family sans
20877 Rename
20878 \end_layout
20879
20880 \begin_layout Standard
20881 This will rename the current document.
20882  Since CVS does not support rename operations natively, the version history
20883  is not preserved, the renamed document is added as a new file, and the
20884  original document is deleted.
20885  It requires a clean document without any changes since the last checkin.
20886  You are asked for a file name and a description of the rename operation.
20887  After that the document is renamed, both locally and in the repository.
20888  If the parent directories of the new and old file names differ, all relative
20889  paths of included files are adjusted (like in 
20890 \family sans
20891 File\SpecialChar menuseparator
20892 Save As
20893 \family default
20894 \SpecialChar ldots
20895 ).
20896  Finally, the document is reloaded using the new name.
20897 \end_layout
20898
20899 \begin_layout Labeling
20900 \labelwidthstring 00.00.0000
20901 CVS
20902 \begin_inset space ~
20903 \end_inset
20904
20905 commands: 
20906 \begin_inset space ~
20907 \end_inset
20908
20909
20910 \begin_inset Newline newline
20911 \end_inset
20912
20913 Rename 
20914 \begin_inset Flex Code
20915 status collapsed
20916
20917 \begin_layout Plain Layout
20918 "<file-name>"
20919 \end_layout
20920
20921 \end_inset
20922
20923  to 
20924 \begin_inset Flex Code
20925 status collapsed
20926
20927 \begin_layout Plain Layout
20928 "<new-file-name>"
20929 \end_layout
20930
20931 \end_inset
20932
20933
20934 \begin_inset Newline newline
20935 \end_inset
20936
20937
20938 \begin_inset Flex Code
20939 status collapsed
20940
20941 \begin_layout Plain Layout
20942 cvs -q add "<new-file-name>"
20943 \end_layout
20944
20945 \end_inset
20946
20947
20948 \begin_inset Newline newline
20949 \end_inset
20950
20951
20952 \begin_inset Flex Code
20953 status collapsed
20954
20955 \begin_layout Plain Layout
20956 cvs -q remove "<file-name>"
20957 \end_layout
20958
20959 \end_inset
20960
20961
20962 \end_layout
20963
20964 \begin_layout Subsubsection
20965 Update of the local directory checkout from repository
20966 \end_layout
20967
20968 \begin_layout Standard
20969 Once your documents gets more complex, containing sub-documents and pictures,
20970  including external 
20971 \begin_inset Flex Code
20972 status collapsed
20973
20974 \begin_layout Plain Layout
20975 .tex
20976 \end_layout
20977
20978 \end_inset
20979
20980  files and so on using version control becomes more complicated.
20981  \SpecialChar LyX
20982  supports updating the whole tree in which resides the document.
20983  This become especially useful once you cooperate with people which neither
20984  have detailed knowledge about CVS usage nor they have ambition to commit
20985  additional material to the repository.
20986  You have to organize the files structure so that all external files are
20987  in the same directory or subdirectories of the document.
20988  It's good practice anyway to store multipart documents in an extra directory.
20989 \end_layout
20990
20991 \begin_layout Standard
20992 The 
20993 \begin_inset Flex Code
20994 status collapsed
20995
20996 \begin_layout Plain Layout
20997 Update local directory from repository
20998 \end_layout
20999
21000 \end_inset
21001
21002  command updates the whole directory.
21003  If local changes are detected user is warned before update starts.
21004  In case of merge conflicts both versions of the conflicting document parts
21005  are placed in the final document.
21006  You have to review and correct the result of the merge.
21007  You'll find the conflicts enclosed in pairs of 
21008 \begin_inset Flex Code
21009 status collapsed
21010
21011 \begin_layout Plain Layout
21012 <<<<<<<
21013 \end_layout
21014
21015 \end_inset
21016
21017  and 
21018 \begin_inset Flex Code
21019 status collapsed
21020
21021 \begin_layout Plain Layout
21022 >>>>>>>
21023 \end_layout
21024
21025 \end_inset
21026
21027  separated by 
21028 \begin_inset Flex Code
21029 status collapsed
21030
21031 \begin_layout Plain Layout
21032 =======
21033 \end_layout
21034
21035 \end_inset
21036
21037 .
21038  The first part is your version as before the update operation with the
21039  document name prepended.
21040  The second one is the repository version with the version number after
21041  the sequence of 
21042 \begin_inset Flex Code
21043 status collapsed
21044
21045 \begin_layout Plain Layout
21046 >
21047 \end_layout
21048
21049 \end_inset
21050
21051  signs.
21052 \end_layout
21053
21054 \begin_layout Labeling
21055 \labelwidthstring 00.00.0000
21056 CVS
21057 \begin_inset space ~
21058 \end_inset
21059
21060 commands: 
21061 \begin_inset space ~
21062 \end_inset
21063
21064
21065 \begin_inset Newline newline
21066 \end_inset
21067
21068
21069 \begin_inset Flex Code
21070 status collapsed
21071
21072 \begin_layout Plain Layout
21073 cd $path; cvs diff 
21074 \family typewriter
21075 "."
21076 \end_layout
21077
21078 \end_inset
21079
21080  (Ask if changes are detected.)
21081 \begin_inset Newline newline
21082 \end_inset
21083
21084
21085 \begin_inset Flex Code
21086 status collapsed
21087
21088 \begin_layout Plain Layout
21089 cd $path; cvs -q update 
21090 \family typewriter
21091 "."
21092 \end_layout
21093
21094 \end_inset
21095
21096
21097 \end_layout
21098
21099 \begin_layout Standard
21100 where 
21101 \begin_inset Flex Code
21102 status collapsed
21103
21104 \begin_layout Plain Layout
21105 $path
21106 \end_layout
21107
21108 \end_inset
21109
21110  stands for the path to the document.
21111 \end_layout
21112
21113 \begin_layout Subsubsection
21114
21115 \family sans
21116 Show History
21117 \end_layout
21118
21119 \begin_layout Standard
21120 This shows the complete history of the CVS document.
21121  The output of 
21122 \family typewriter
21123 cvs log "<file-name>"
21124 \family default
21125  is shown in a browser.
21126 \end_layout
21127
21128 \begin_layout Subsubsection
21129 Revision info
21130 \end_layout
21131
21132 \begin_layout Standard
21133 \SpecialChar LyX
21134  supports CVS version number, author name, date and time of last commit.
21135  All those are extracted from 
21136 \family typewriter
21137 cvs log -r <file-name>
21138 \family default
21139 .
21140  See 
21141 \begin_inset CommandInset ref
21142 LatexCommand ref
21143 reference "subsec:VCS-Revision-Information"
21144
21145 \end_inset
21146
21147  for details.
21148 \end_layout
21149
21150 \begin_layout Subsection
21151 SVN commands in \SpecialChar LyX
21152
21153 \end_layout
21154
21155 \begin_layout Standard
21156 SVN is now partially supported by \SpecialChar LyX
21157 .
21158  You can find the commands in the 
21159 \family sans
21160 File\SpecialChar menuseparator
21161 Version
21162 \begin_inset space ~
21163 \end_inset
21164
21165 Control
21166 \family default
21167  submenu.
21168  Please note that if you use password protected access to repository via
21169  ssh, you will be asked in terminal window.
21170  \SpecialChar LyX
21171  was tested against SVN 1.5, 1.6, 1.7 and 1.8
21172 \begin_inset Foot
21173 status collapsed
21174
21175 \begin_layout Plain Layout
21176 Most of the commands will work with 1.4 too, see 
21177 \begin_inset CommandInset ref
21178 LatexCommand ref
21179 reference "subsec:SVN-Repo-Update"
21180
21181 \end_inset
21182
21183 .
21184  There seems to be currently unresolved permissions problem under SVN 1.8
21185  with reverting changes when file is locked.
21186 \end_layout
21187
21188 \end_inset
21189
21190
21191 \end_layout
21192
21193 \begin_layout Subsubsection
21194
21195 \family sans
21196 Register
21197 \end_layout
21198
21199 \begin_layout Standard
21200 If your document is not under revision control, this is the only item shown
21201  in the menu.
21202  And if it is under revision control, the 
21203 \family sans
21204 Register
21205 \family default
21206  item is not visible.
21207 \end_layout
21208
21209 \begin_layout Standard
21210 This command registers in SVN your document ONLY in case you have already
21211  the documents directory under SVN control (in particular 
21212 \family typewriter
21213 .svn/entries
21214 \family default
21215  file exists).
21216  This means you have to checkout the archive by yourself.
21217 \end_layout
21218
21219 \begin_layout Standard
21220 Then you are asked interactively to supply an initial description of the
21221  document.
21222  Don't forget that registered file is not yet commited.
21223 \end_layout
21224
21225 \begin_layout Standard
21226 SVN command that is run: 
21227 \family typewriter
21228 svn add -q 
21229 \begin_inset Quotes qld
21230 \end_inset
21231
21232 <file-name>
21233 \begin_inset Quotes qld
21234 \end_inset
21235
21236
21237 \end_layout
21238
21239 \begin_layout Standard
21240 Read 
21241 \family typewriter
21242 man svn
21243 \family default
21244  to understand the switches.
21245 \end_layout
21246
21247 \begin_layout Subsubsection
21248
21249 \family sans
21250 Check In Changes
21251 \end_layout
21252
21253 \begin_layout Standard
21254 When you are finished editing a file, you commit your changes.
21255  When you do this, you are asked for a description of the changes.
21256  After that changes are commited.
21257 \end_layout
21258
21259 \begin_layout Standard
21260 SVN command:
21261 \begin_inset Foot
21262 status collapsed
21263
21264 \begin_layout Plain Layout
21265 In case locking is not enabled.
21266  See Section 
21267 \begin_inset CommandInset ref
21268 LatexCommand ref
21269 reference "subsec:SVN-File-Locking"
21270
21271 \end_inset
21272
21273 .
21274 \end_layout
21275
21276 \end_inset
21277
21278  
21279 \family typewriter
21280 svn commit -q -m"<description>" <file-name>
21281 \end_layout
21282
21283 \begin_layout Subsubsection
21284
21285 \family sans
21286 Check Out For Edit
21287 \end_layout
21288
21289 \begin_layout Standard
21290 Updates the changes of this file from the repository.
21291  Be sure you understand SVN merging and conflicts resolving before using
21292  this function, because all conflicts has to be resolved manually by you!
21293 \end_layout
21294
21295 \begin_layout Standard
21296 SVN command:
21297 \begin_inset Foot
21298 status collapsed
21299
21300 \begin_layout Plain Layout
21301 Ditto.
21302 \end_layout
21303
21304 \end_inset
21305
21306  
21307 \family typewriter
21308 svn update --non-interactive 
21309 \begin_inset Quotes qld
21310 \end_inset
21311
21312 <file-name>
21313 \begin_inset Quotes qld
21314 \end_inset
21315
21316
21317 \end_layout
21318
21319 \begin_layout Subsubsection
21320
21321 \family sans
21322 Revert To Repository Version
21323 \end_layout
21324
21325 \begin_layout Standard
21326 This will discard all changes made to the document since the last check
21327  in.
21328  You get a warning before changes are discarded.
21329 \end_layout
21330
21331 \begin_layout Standard
21332 SVN command: 
21333 \family typewriter
21334 svn revert -q 
21335 \begin_inset Quotes qld
21336 \end_inset
21337
21338 <file-name>
21339 \begin_inset Quotes qld
21340 \end_inset
21341
21342
21343 \end_layout
21344
21345 \begin_layout Subsubsection
21346
21347 \family sans
21348 Copy
21349 \end_layout
21350
21351 \begin_layout Standard
21352 This will create a copy of the current document including the version history.
21353  It requires a clean document without any changes since the last checkin.
21354  You are asked for a file name and a description of the copy operation.
21355  After that the copy is created, both locally and in the repository.
21356  If the parent directories of the copied and original document differ, all
21357  relative paths of included files of the copy are adjusted (like in 
21358 \family sans
21359 File\SpecialChar menuseparator
21360 Save As
21361 \family default
21362 \SpecialChar ldots
21363 ).
21364  Finally, the copy is loaded instead of the original document.
21365 \end_layout
21366
21367 \begin_layout Labeling
21368 \labelwidthstring 00.00.0000
21369 SVN
21370 \begin_inset space ~
21371 \end_inset
21372
21373 commands: 
21374 \begin_inset space ~
21375 \end_inset
21376
21377
21378 \begin_inset Newline newline
21379 \end_inset
21380
21381
21382 \begin_inset Flex Code
21383 status collapsed
21384
21385 \begin_layout Plain Layout
21386 svn copy -q 
21387 \family typewriter
21388
21389 \begin_inset Quotes qld
21390 \end_inset
21391
21392 <file-name>
21393 \begin_inset Quotes qld
21394 \end_inset
21395
21396  
21397 \begin_inset Quotes qld
21398 \end_inset
21399
21400 <new-file-name>
21401 \begin_inset Quotes qld
21402 \end_inset
21403
21404
21405 \end_layout
21406
21407 \end_inset
21408
21409
21410 \begin_inset Newline newline
21411 \end_inset
21412
21413
21414 \begin_inset Flex Code
21415 status collapsed
21416
21417 \begin_layout Plain Layout
21418 svn commit
21419 \end_layout
21420
21421 \end_inset
21422
21423
21424 \end_layout
21425
21426 \begin_layout Subsubsection
21427
21428 \family sans
21429 Rename
21430 \end_layout
21431
21432 \begin_layout Standard
21433 This will rename the current document including the version history.
21434  It requires a clean document without any changes since the last checkin.
21435  You are asked for a file name and a description of the rename operation.
21436  After that the document is renamed, both locally and in the repository.
21437  If the parent directories of the new and old file names differ, all relative
21438  paths of included files are adjusted (like in 
21439 \family sans
21440 File\SpecialChar menuseparator
21441 Save As
21442 \family default
21443 \SpecialChar ldots
21444 ).
21445  Finally, the document is reloaded using the new name.
21446 \end_layout
21447
21448 \begin_layout Labeling
21449 \labelwidthstring 00.00.0000
21450 SVN
21451 \begin_inset space ~
21452 \end_inset
21453
21454 commands: 
21455 \begin_inset space ~
21456 \end_inset
21457
21458
21459 \begin_inset Newline newline
21460 \end_inset
21461
21462
21463 \begin_inset Flex Code
21464 status collapsed
21465
21466 \begin_layout Plain Layout
21467 svn move -q 
21468 \family typewriter
21469
21470 \begin_inset Quotes qld
21471 \end_inset
21472
21473 <file-name>
21474 \begin_inset Quotes qld
21475 \end_inset
21476
21477  
21478 \begin_inset Quotes qld
21479 \end_inset
21480
21481 <new-file-name>
21482 \begin_inset Quotes qld
21483 \end_inset
21484
21485
21486 \end_layout
21487
21488 \end_inset
21489
21490
21491 \begin_inset Newline newline
21492 \end_inset
21493
21494
21495 \begin_inset Flex Code
21496 status collapsed
21497
21498 \begin_layout Plain Layout
21499 svn commit
21500 \end_layout
21501
21502 \end_inset
21503
21504
21505 \end_layout
21506
21507 \begin_layout Subsubsection
21508 \begin_inset CommandInset label
21509 LatexCommand label
21510 name "subsec:SVN-Repo-Update"
21511
21512 \end_inset
21513
21514 Update of the local directory checkout from repository
21515 \begin_inset Foot
21516 status collapsed
21517
21518 \begin_layout Plain Layout
21519 Note that this command will work only with subversion 
21520 \begin_inset Formula $\geqq1.5$
21521 \end_inset
21522
21523
21524 \end_layout
21525
21526 \end_inset
21527
21528
21529 \end_layout
21530
21531 \begin_layout Standard
21532 All the commands above have one shortcoming – they deal with the current
21533  document only.
21534  Once your document contains pictures, includes external 
21535 \begin_inset Flex Code
21536 status collapsed
21537
21538 \begin_layout Plain Layout
21539 .tex
21540 \end_layout
21541
21542 \end_inset
21543
21544  files and so on administration becomes more complicated.
21545  \SpecialChar LyX
21546  now supports updating the whole tree in which resides the document
21547 \begin_inset Foot
21548 status collapsed
21549
21550 \begin_layout Plain Layout
21551 One need to organize the files structure so that all external files are
21552  in the same directory or subdirectories of the document.
21553  
21554 \end_layout
21555
21556 \end_inset
21557
21558 .
21559  This become especially useful once you cooperate with people which neither
21560  know about subversion management nor they have ambition to commit additional
21561  material to the repository.
21562  
21563 \end_layout
21564
21565 \begin_layout Standard
21566 \begin_inset Flex Code
21567 status collapsed
21568
21569 \begin_layout Plain Layout
21570 Update local directory from repository
21571 \end_layout
21572
21573 \end_inset
21574
21575  command updates the whole directory and in case of merge conflicts local
21576  version of the files are left, so no unintended data loss occurs.
21577  If local changes are detected user is warned before update starts.
21578 \end_layout
21579
21580 \begin_layout Labeling
21581 \labelwidthstring 00.00.0000
21582 SVN
21583 \begin_inset space ~
21584 \end_inset
21585
21586 commands: 
21587 \begin_inset space ~
21588 \end_inset
21589
21590
21591 \begin_inset Newline newline
21592 \end_inset
21593
21594
21595 \begin_inset Flex Code
21596 status collapsed
21597
21598 \begin_layout Plain Layout
21599 svn diff $path
21600 \end_layout
21601
21602 \end_inset
21603
21604  (Ask if changes are detected.)
21605 \begin_inset Newline newline
21606 \end_inset
21607
21608
21609 \begin_inset Flex Code
21610 status collapsed
21611
21612 \begin_layout Plain Layout
21613 svn update --accept mine-full $path
21614 \end_layout
21615
21616 \end_inset
21617
21618
21619 \end_layout
21620
21621 \begin_layout Standard
21622 where 
21623 \begin_inset Flex Code
21624 status collapsed
21625
21626 \begin_layout Plain Layout
21627 $path
21628 \end_layout
21629
21630 \end_inset
21631
21632  stands for the path to the document.
21633 \end_layout
21634
21635 \begin_layout Subsubsection
21636
21637 \family sans
21638 Show History
21639 \end_layout
21640
21641 \begin_layout Standard
21642 This shows the complete history of the SVN document.
21643  The output of 
21644 \family typewriter
21645 svn log 
21646 \begin_inset Quotes qld
21647 \end_inset
21648
21649 <file-name>
21650 \begin_inset Quotes qld
21651 \end_inset
21652
21653
21654 \family default
21655  is shown in a browser.
21656 \end_layout
21657
21658 \begin_layout Subsubsection
21659 File Locking
21660 \begin_inset CommandInset label
21661 LatexCommand label
21662 name "subsec:SVN-File-Locking"
21663
21664 \end_inset
21665
21666
21667 \end_layout
21668
21669 \begin_layout Standard
21670 The file exchange through various revision control systems brings the problem
21671  of merge conflicts in case two different users try to edit the same (parts
21672  of) document.
21673  When such a conflict happens it needs manual resolving and one reasonable
21674  alternative is to provide some kind of locking mechanism, which guarantees
21675  that only one user is allowed to edit file at the given time.
21676 \end_layout
21677
21678 \begin_layout Standard
21679 SVN has two such mechanisms to provide mutual exclusivity for file access
21680  – locks and automatic setting of write permissions (see sec.
21681  
21682 \begin_inset CommandInset ref
21683 LatexCommand ref
21684 reference "subsec:Automatical-Locking-Property"
21685
21686 \end_inset
21687
21688 ) based on 
21689 \begin_inset Flex Code
21690 status collapsed
21691
21692 \begin_layout Plain Layout
21693 svn:needs-lock
21694 \end_layout
21695
21696 \end_inset
21697
21698  file svn property
21699 \begin_inset Foot
21700 status collapsed
21701
21702 \begin_layout Plain Layout
21703 \begin_inset Flex URL
21704 status open
21705
21706 \begin_layout Plain Layout
21707
21708 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
21709 \end_layout
21710
21711 \end_inset
21712
21713
21714 \end_layout
21715
21716 \end_inset
21717
21718 .
21719  If this property is detected for a given document \SpecialChar LyX
21720  starts to use SVN locks
21721  for document editing automatically and the whole check-in/out mechanism
21722  switches to the same regimen as for RCS.
21723  This in particular means there are two different modes of file use in \SpecialChar LyX
21724 :
21725 \end_layout
21726
21727 \begin_layout Itemize
21728 Unlocked state.
21729  The loaded file is in the read-only mode.
21730  For editing on needs to check-out.
21731  
21732 \emph on
21733 Check-out
21734 \emph default
21735  consists of updating from the repository and gaining write lock.
21736  If the lock is not possible to obtain, we remain in unlocked state.
21737 \end_layout
21738
21739 \begin_layout Itemize
21740 Locked state.
21741  The loaded file is in the 
21742 \begin_inset Quotes els
21743 \end_inset
21744
21745 normal
21746 \begin_inset Quotes ers
21747 \end_inset
21748
21749  edit mode.
21750  No other user is allowed to edit the file.
21751  
21752 \emph on
21753 Check-in
21754 \emph default
21755  consists of commiting changes and releasing write-lock.
21756  If no changes have been made to the document, no commit will be produced
21757 \begin_inset Foot
21758 status collapsed
21759
21760 \begin_layout Plain Layout
21761 Don't be puzzled by the fact that you will be asked for commit message anyway.
21762 \end_layout
21763
21764 \end_inset
21765
21766  and only the write-lock will be released.
21767 \end_layout
21768
21769 \begin_layout Standard
21770 SVN commands:
21771 \end_layout
21772
21773 \begin_layout Labeling
21774 \labelwidthstring 00.00.0000
21775 Check-in:
21776 \family typewriter
21777  svn commit -q -m"<description>" "<file-name>"
21778 \begin_inset Newline newline
21779 \end_inset
21780
21781 svn unlock "<file-name>"
21782 \end_layout
21783
21784 \begin_layout Labeling
21785 \labelwidthstring 00.00.0000
21786 Check-out: 
21787 \family typewriter
21788 svn update "<file-name>"
21789 \begin_inset Newline newline
21790 \end_inset
21791
21792 svn lock "<file-name>"
21793 \end_layout
21794
21795 \begin_layout Subsubsection
21796
21797 \family typewriter
21798 \begin_inset CommandInset label
21799 LatexCommand label
21800 name "subsec:Automatical-Locking-Property"
21801
21802 \end_inset
21803
21804
21805 \family default
21806 Automatic Locking Property
21807 \end_layout
21808
21809 \begin_layout Standard
21810 The above mentioned automatic setting of write permissions of the .lyx file
21811  can be set through
21812 \family sans
21813  File\SpecialChar menuseparator
21814 Version
21815 \begin_inset space ~
21816 \end_inset
21817
21818 Control\SpecialChar menuseparator
21819 Use Locking Property
21820 \family default
21821 .
21822  This command is active only when the file is not locked on the svn server
21823  (i.e.
21824  you need to check-out before proceeding).
21825 \end_layout
21826
21827 \begin_layout Labeling
21828 \labelwidthstring 00.00.0000
21829 SVN
21830 \begin_inset space ~
21831 \end_inset
21832
21833 commands:
21834 \end_layout
21835
21836 \begin_layout Labeling
21837 \labelwidthstring 00.00.0000
21838 Set:
21839 \family typewriter
21840  svn propset svn:needs-lock ON "<file-name>"
21841 \end_layout
21842
21843 \begin_layout Labeling
21844 \labelwidthstring 00.00.0000
21845 Unset: 
21846 \family typewriter
21847 svn propdel svn:needs-lock "<file-name>"
21848 \end_layout
21849
21850 \begin_layout Subsubsection
21851 \begin_inset CommandInset label
21852 LatexCommand label
21853 name "subsec:VCS-Revision-Information"
21854
21855 \end_inset
21856
21857 Revision Information in Documents
21858 \end_layout
21859
21860 \begin_layout Standard
21861 There are more possibilities how to activate revision information in our
21862  document.
21863 \end_layout
21864
21865 \begin_layout Itemize
21866 \SpecialChar LyX
21867  supports directly:
21868 \end_layout
21869
21870 \begin_deeper
21871 \begin_layout Itemize
21872 tree revision information (
21873 \begin_inset Flex Code
21874 status collapsed
21875
21876 \begin_layout Plain Layout
21877 vcs-tree-revision
21878 \end_layout
21879
21880 \end_inset
21881
21882 ).
21883  The result is the output of the 
21884 \begin_inset Flex Code
21885 status collapsed
21886
21887 \begin_layout Plain Layout
21888 svnversion
21889 \end_layout
21890
21891 \end_inset
21892
21893  command, the following table gives you an idea, how to read the results.
21894 \end_layout
21895
21896 \begin_layout Standard
21897 \align center
21898 \begin_inset Tabular
21899 <lyxtabular version="3" rows="6" columns="2">
21900 <features tabularvalignment="middle">
21901 <column alignment="left" valignment="top">
21902 <column alignment="left" valignment="top">
21903 <row>
21904 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
21905 \begin_inset Text
21906
21907 \begin_layout Plain Layout
21908
21909 \series bold
21910 Output
21911 \end_layout
21912
21913 \end_inset
21914 </cell>
21915 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
21916 \begin_inset Text
21917
21918 \begin_layout Plain Layout
21919
21920 \series bold
21921 Meaning
21922 \end_layout
21923
21924 \end_inset
21925 </cell>
21926 </row>
21927 <row>
21928 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
21929 \begin_inset Text
21930
21931 \begin_layout Plain Layout
21932 4123:4168
21933 \end_layout
21934
21935 \end_inset
21936 </cell>
21937 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21938 \begin_inset Text
21939
21940 \begin_layout Plain Layout
21941 mixed revision working copy
21942 \end_layout
21943
21944 \end_inset
21945 </cell>
21946 </row>
21947 <row>
21948 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
21949 \begin_inset Text
21950
21951 \begin_layout Plain Layout
21952 4168M
21953 \end_layout
21954
21955 \end_inset
21956 </cell>
21957 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21958 \begin_inset Text
21959
21960 \begin_layout Plain Layout
21961 modified working copy
21962 \end_layout
21963
21964 \end_inset
21965 </cell>
21966 </row>
21967 <row>
21968 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
21969 \begin_inset Text
21970
21971 \begin_layout Plain Layout
21972 4123S
21973 \end_layout
21974
21975 \end_inset
21976 </cell>
21977 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21978 \begin_inset Text
21979
21980 \begin_layout Plain Layout
21981 switched working copy
21982 \end_layout
21983
21984 \end_inset
21985 </cell>
21986 </row>
21987 <row>
21988 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
21989 \begin_inset Text
21990
21991 \begin_layout Plain Layout
21992 4123P
21993 \end_layout
21994
21995 \end_inset
21996 </cell>
21997 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
21998 \begin_inset Text
21999
22000 \begin_layout Plain Layout
22001 partial working copy, from a sparse checkout
22002 \end_layout
22003
22004 \end_inset
22005 </cell>
22006 </row>
22007 <row>
22008 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
22009 \begin_inset Text
22010
22011 \begin_layout Plain Layout
22012 4123:4168MS
22013 \end_layout
22014
22015 \end_inset
22016 </cell>
22017 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
22018 \begin_inset Text
22019
22020 \begin_layout Plain Layout
22021 mixed revision, modified, switched working copy
22022 \end_layout
22023
22024 \end_inset
22025 </cell>
22026 </row>
22027 </lyxtabular>
22028
22029 \end_inset
22030
22031
22032 \end_layout
22033
22034 \begin_layout Itemize
22035 file revision information.
22036  The result comes from parsing the output of 
22037 \begin_inset Flex Code
22038 status collapsed
22039
22040 \begin_layout Plain Layout
22041 svn
22042 \begin_inset space ~
22043 \end_inset
22044
22045 info
22046 \begin_inset space ~
22047 \end_inset
22048
22049 --xml
22050 \begin_inset space ~
22051 \end_inset
22052
22053 file.lyx
22054 \end_layout
22055
22056 \end_inset
22057
22058 .
22059  Supported flags are:
22060 \end_layout
22061
22062 \begin_deeper
22063 \begin_layout Itemize
22064 version number of the last commit (
22065 \begin_inset Flex Code
22066 status collapsed
22067
22068 \begin_layout Plain Layout
22069 vcs-revision
22070 \end_layout
22071
22072 \end_inset
22073
22074 )
22075 \end_layout
22076
22077 \begin_layout Itemize
22078 author of the last commit (
22079 \begin_inset Flex Code
22080 status collapsed
22081
22082 \begin_layout Plain Layout
22083 vcs-author
22084 \end_layout
22085
22086 \end_inset
22087
22088 )
22089 \end_layout
22090
22091 \begin_layout Itemize
22092 date of the last commit (
22093 \begin_inset Flex Code
22094 status collapsed
22095
22096 \begin_layout Plain Layout
22097 vcs-date
22098 \end_layout
22099
22100 \end_inset
22101
22102 )
22103 \end_layout
22104
22105 \begin_layout Itemize
22106 time of the last commit (
22107 \begin_inset Flex Code
22108 status collapsed
22109
22110 \begin_layout Plain Layout
22111 vcs-time
22112 \end_layout
22113
22114 \end_inset
22115
22116 )
22117 \end_layout
22118
22119 \end_deeper
22120 \begin_layout Standard
22121 You can obtain this info via InsetInfo (
22122 \change_inserted 5863208 1564400022
22123
22124 \lang american
22125 Insert\SpecialChar menuseparator
22126 Field\SpecialChar menuseparator
22127 Version Control Revision
22128 \change_deleted 5863208 1564399852
22129
22130 \lang english
22131 e.g.
22132  
22133 \begin_inset Flex Code
22134 status collapsed
22135
22136 \begin_layout Plain Layout
22137 info-insert buffer vcs-date
22138 \end_layout
22139
22140 \end_inset
22141
22142
22143 \change_unchanged
22144 ).
22145  The information will be available only when you have the file stored under
22146  svn managment (i.e.
22147  the 
22148 \begin_inset Flex Code
22149 status collapsed
22150
22151 \begin_layout Plain Layout
22152 .svn
22153 \end_layout
22154
22155 \end_inset
22156
22157  directory is available with your document).
22158 \end_layout
22159
22160 \end_deeper
22161 \begin_layout Itemize
22162 Another—a hacking one—possibility is to use svn keywords
22163 \begin_inset Foot
22164 status collapsed
22165
22166 \begin_layout Plain Layout
22167 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
22168 \end_layout
22169
22170 \end_inset
22171
22172 .
22173  In short – you set file keywords property (e.g.
22174  
22175 \family sans
22176 svn propset svn:keywords 'Rev' file.lyx
22177 \family default
22178 ) and then paste keyword \SpecialChar TeX
22179  code
22180 \begin_inset Foot
22181 status collapsed
22182
22183 \begin_layout Plain Layout
22184 This is an easy way how to ensure that \SpecialChar LyX
22185  won't break the line in the middle
22186  of keyword tag.
22187 \end_layout
22188
22189 \end_inset
22190
22191  tag in your document (e.g.
22192  
22193 \begin_inset Flex Code
22194 status collapsed
22195
22196 \begin_layout Plain Layout
22197 $Rev$
22198 \end_layout
22199
22200 \end_inset
22201
22202 ).
22203  This way svn client will automatically substitute revision number (e.g.
22204  
22205 \begin_inset Flex Code
22206 status collapsed
22207
22208 \begin_layout Plain Layout
22209 $Rev: 59 $
22210 \end_layout
22211
22212 \end_inset
22213
22214 ) after each update and commit.
22215  There are more problems with this approach.
22216  Firstly, the '$' character is used in \SpecialChar TeX
22217  world for math equations, so any
22218  occurence of math formula 
22219 \begin_inset Formula $Rev$
22220 \end_inset
22221
22222  become 
22223 \begin_inset Formula $Rev:59$
22224 \end_inset
22225
22226  in your \SpecialChar LyX
22227  document.
22228  Similarly for other keywords like Id, Date, Author, etc.
22229  Secondly svn output is dependent on your locales, so its very easy that
22230  svn would produce some problematic strings once Date is used.
22231  Thirdly you get the whole 'Rev: 59' string in your document instead of
22232  the plain number.
22233  Until subversion implements user's custom keywords it will be hard to use
22234  this approach reliably or let \SpecialChar LyX
22235  to support it directly.
22236 \end_layout
22237
22238 \begin_layout Subsection
22239 SVN and Windows Environment
22240 \end_layout
22241
22242 \begin_layout Quote
22243 My inclination is to say that if the user cannot figure out the command
22244  line operations on their own fairly quickly, they would be well advised
22245  to use TortoiseSVN.
22246  —P.
22247  A.
22248  Rubin
22249 \end_layout
22250
22251 \begin_layout Subsubsection
22252 Preparation
22253 \end_layout
22254
22255 \begin_layout Standard
22256 In addition to installing \SpecialChar LyX
22257 , and having access to a Subversion repository,
22258  the user will need to install the Subversion client program.
22259  A Windows installer for the client program is available from 
22260 \begin_inset CommandInset href
22261 LatexCommand href
22262 name "CollabNet"
22263 target "http://www.collab.net/nonav/downloads/subversion/"
22264 literal "false"
22265
22266 \end_inset
22267
22268 .
22269  The user may also want to install 
22270 \begin_inset CommandInset href
22271 LatexCommand href
22272 name "TortoiseSVN"
22273 target "http://tortoisesvn.tigris.org/"
22274 literal "false"
22275
22276 \end_inset
22277
22278 , which integrates Subversion operations into the context (rightclick) menu
22279  of Windows Explorer.
22280  Operations done outside \SpecialChar LyX
22281  will typically be more convenient using the Explorer
22282  context menu.
22283  Note that TortoiseSVN is not a replacement for the client program, which
22284  is what \SpecialChar LyX
22285  itself will use.
22286 \end_layout
22287
22288 \begin_layout Subsubsection
22289 Bringing a document under Subversion control
22290 \end_layout
22291
22292 \begin_layout Standard
22293 Before a \SpecialChar LyX
22294  document can be brought under version control in Subversion, its
22295  parent directory needs to be under version control.
22296  If the document is being added to a project already in the repository,
22297  this is accomplished by checking the project out to the directory where
22298  the new document will be placed.
22299  If the project itself is not yet under version control (for instance, if
22300  this document starts a new project), the directory must be imported into
22301  the repository.
22302  This is done outside \SpecialChar LyX
22303 .
22304  Both import and checkout are easily accomplished from the Explorer context
22305  menu using TortoiseSVN, or alternatively can be done using the command
22306  line client at a DOS prompt.
22307  The procedure for importing the project using TortoiseSVN is described
22308  below, assuming an existing repository and a new project being started
22309  in 
22310 \family typewriter
22311 C:
22312 \backslash
22313 new project
22314 \family default
22315 .
22316  For information on using the Subversion client program, run 
22317 \family typewriter
22318 svn --help 
22319 \family default
22320 in a DOS shell.
22321 \end_layout
22322
22323 \begin_layout Enumerate
22324 Locate 
22325 \family typewriter
22326 C:
22327 \backslash
22328 new project 
22329 \family default
22330 in Windows Explorer, right click it, and select 
22331 \family sans
22332 TortoiseSVN\SpecialChar menuseparator
22333 Repo-browser
22334 \family default
22335 .
22336  If necessary, adjust the URL for the repository, then click OK.
22337 \end_layout
22338
22339 \begin_layout Enumerate
22340 Right click the level of the repository under which you want to place the
22341  new project folder (typically the top level) and click 
22342 \family sans
22343 Create folder
22344 \family default
22345  Supply a name for the project folder and click OK.
22346  Add a message for the log file if desired, then click OK again.
22347  The new project folder should appear in the repository.
22348  Finally, click OK again to exit the repository browser.
22349 \end_layout
22350
22351 \begin_layout Enumerate
22352 Once again right click 
22353 \family typewriter
22354 C:
22355 \backslash
22356 new project
22357 \family default
22358 , this time selecting SVN Checkout\SpecialChar ldots
22359  Select the URL of the project folder
22360  you just created in the repository, and set the checkout directory to 
22361 \family typewriter
22362 C:
22363 \backslash
22364 new project.
22365
22366 \family default
22367  Click OK.
22368  You will be warned about a non-empty folder; click OK to proceed.
22369  You should now have a 
22370 \family typewriter
22371 .svn
22372 \family default
22373  directory under 
22374 \family typewriter
22375 C:
22376 \backslash
22377 new project.
22378 \end_layout
22379
22380 \begin_layout Enumerate
22381 Create or open your document in \SpecialChar LyX
22382  and click 
22383 \family sans
22384 File\SpecialChar menuseparator
22385 Version
22386 \begin_inset space ~
22387 \end_inset
22388
22389 Control\SpecialChar menuseparator
22390 Register.
22391  
22392 \family default
22393 Add a log message and click OK to commit the document to version control.
22394 \end_layout
22395
22396 \begin_layout Standard
22397 From this point onward, you should have full functionality in the 
22398 \family sans
22399 File\SpecialChar menuseparator
22400 Version
22401 \begin_inset space ~
22402 \end_inset
22403
22404 Control
22405 \family default
22406  menu.
22407  You also have the option of checking the document in and out, viewing its
22408  history, etc.
22409  using the TortoiseSVN context menu in Windows Explorer or the Subversion
22410  client program from a command prompt.
22411 \end_layout
22412
22413 \begin_layout Subsubsection
22414 SSH tunnel used with SVN under Windows
22415 \end_layout
22416
22417 \begin_layout Standard
22418 Compared with Linux setting up an svn client to communicate over ssh under
22419  Windows is a rather troublesome task.
22420  We will at least offer some hints how to setup the client side but prior
22421  knowledge about ssh and the Windows command line is needed, also be prepared
22422  for a great deal of frustration\SpecialChar ldots
22423
22424 \end_layout
22425
22426 \begin_layout Enumerate
22427 Get an svn client for windows, as described in the previous sections.
22428  When it is a fresh install run some svn command (e.g.
22429  
22430 \begin_inset Flex Code
22431 status collapsed
22432
22433 \begin_layout Plain Layout
22434 svn --version
22435 \end_layout
22436
22437 \end_inset
22438
22439 ) to create config files, which you will need to change later on.
22440 \end_layout
22441
22442 \begin_layout Enumerate
22443 Choose an ssh client for Windows.
22444  There are several possibilities, we will use the one from Putty tools
22445 \begin_inset Foot
22446 status collapsed
22447
22448 \begin_layout Plain Layout
22449 \begin_inset Flex URL
22450 status collapsed
22451
22452 \begin_layout Plain Layout
22453
22454 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
22455 \end_layout
22456
22457 \end_inset
22458
22459
22460 \end_layout
22461
22462 \end_inset
22463
22464 .
22465  You will need to set the connection up so that the client doesn't ask for
22466  any password from you.
22467  To keep things easy we will use only keys without any additional password
22468  protection etc.
22469 \end_layout
22470
22471 \begin_deeper
22472 \begin_layout Enumerate
22473 Generate keys by 
22474 \begin_inset Flex Code
22475 status collapsed
22476
22477 \begin_layout Plain Layout
22478 puttygen
22479 \end_layout
22480
22481 \end_inset
22482
22483 .
22484  Save your private .ppk key file and put the public one on the server side.
22485  If the SVN server runs on Linux, note that the format of the public key
22486  is not compatible with Linux openssh and you will need to direcly copy-paste
22487  the key from the 
22488 \begin_inset Quotes eld
22489 \end_inset
22490
22491
22492 \emph on
22493 Public key for pasting into OpenSSH authorized_keys file
22494 \emph default
22495 :
22496 \begin_inset Quotes erd
22497 \end_inset
22498
22499  edit field into the server's 
22500 \begin_inset Flex Code
22501 status collapsed
22502
22503 \begin_layout Plain Layout
22504 ~/.ssh/authorized_keys
22505 \end_layout
22506
22507 \end_inset
22508
22509  / 
22510 \begin_inset Flex Code
22511 status collapsed
22512
22513 \begin_layout Plain Layout
22514 authorized_keys2
22515 \end_layout
22516
22517 \end_inset
22518
22519  file.
22520 \end_layout
22521
22522 \begin_layout Enumerate
22523 Get the Putty's 
22524 \begin_inset Flex Code
22525 status collapsed
22526
22527 \begin_layout Plain Layout
22528 plink
22529 \end_layout
22530
22531 \end_inset
22532
22533 .
22534  In the SVN config file
22535 \begin_inset Foot
22536 status collapsed
22537
22538 \begin_layout Plain Layout
22539 Exact path depends on Windows version, usually somewhere around 
22540 \begin_inset Flex Code
22541 status collapsed
22542
22543 \begin_layout Plain Layout
22544 c:
22545 \backslash
22546 Documents and Settings
22547 \backslash
22548 user
22549 \backslash
22550 Application Data
22551 \backslash
22552 Subversion
22553 \backslash
22554 config
22555 \end_layout
22556
22557 \end_inset
22558
22559  / 
22560 \begin_inset Flex Code
22561 status collapsed
22562
22563 \begin_layout Plain Layout
22564 AppData
22565 \backslash
22566 Roaming
22567 \backslash
22568 Subversion
22569 \end_layout
22570
22571 \end_inset
22572
22573 .
22574 \end_layout
22575
22576 \end_inset
22577
22578 , section [tunnels], setup ssh command, e.g.
22579  
22580 \begin_inset Flex Code
22581 status collapsed
22582
22583 \begin_layout Plain Layout
22584 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
22585 \end_layout
22586
22587 \end_inset
22588
22589 .
22590 \begin_inset Foot
22591 status collapsed
22592
22593 \begin_layout Plain Layout
22594 It will usually take a lot of time to get exact command right and it depends
22595  on many things.
22596  For example do not have some remote server saved as a default session in
22597  Putty etc.
22598  If things fail, try to connect via plink without SVN first.
22599 \end_layout
22600
22601 \end_inset
22602
22603
22604 \end_layout
22605
22606 \end_deeper
22607 \begin_layout Enumerate
22608 Checkout the SVN archive, e.
22609 \begin_inset space \thinspace{}
22610 \end_inset
22611
22612 g.
22613 \begin_inset Newline newline
22614 \end_inset
22615
22616
22617 \begin_inset Flex Code
22618 status collapsed
22619
22620 \begin_layout Plain Layout
22621 svn co svn+ssh://user@server/repository_path
22622 \end_layout
22623
22624 \end_inset
22625
22626 .
22627 \end_layout
22628
22629 \begin_layout Subsubsection
22630 End-of-Line Conversions
22631 \end_layout
22632
22633 \begin_layout Standard
22634 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
22635  will
22636  use different line endings inside the .lyx files.
22637  This is not a problem as far as \SpecialChar LyX
22638  functionality is concerned, but the commit
22639  diffs will be huge and merge-conflicts prone.
22640  Fortunately SVN itself knows
22641 \begin_inset Foot
22642 status collapsed
22643
22644 \begin_layout Plain Layout
22645 \begin_inset Flex URL
22646 status collapsed
22647
22648 \begin_layout Plain Layout
22649
22650 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
22651 \end_layout
22652
22653 \end_inset
22654
22655
22656 \end_layout
22657
22658 \end_inset
22659
22660  how to deal with CR/LF problems when switching .lyx files to the 
22661 \begin_inset Flex Code
22662 status collapsed
22663
22664 \begin_layout Plain Layout
22665 native
22666 \end_layout
22667
22668 \end_inset
22669
22670  mode.
22671 \begin_inset Foot
22672 status collapsed
22673
22674 \begin_layout Plain Layout
22675 For the lazy guys: 
22676 \begin_inset Flex Code
22677 status collapsed
22678
22679 \begin_layout Plain Layout
22680 svn propset svn:eol-style native FILE_NAME
22681 \end_layout
22682
22683 \end_inset
22684
22685
22686 \end_layout
22687
22688 \end_inset
22689
22690
22691 \end_layout
22692
22693 \begin_layout Subsection
22694 GIT commands in \SpecialChar LyX
22695
22696 \end_layout
22697
22698 \begin_layout Standard
22699 A minimal subset of GIT commands is now supported by \SpecialChar LyX
22700 .
22701  You can find the commands in the 
22702 \family sans
22703 File\SpecialChar menuseparator
22704 Version
22705 \begin_inset space ~
22706 \end_inset
22707
22708 Control
22709 \family default
22710  submenu.
22711  Please note that if you use password protected access to repository via
22712  ssh, you will be asked in terminal window.
22713  \SpecialChar LyX
22714  was tested against GIT 1.7.
22715 \begin_inset Foot
22716 status collapsed
22717
22718 \begin_layout Plain Layout
22719 Windows users please note that you need to ensure that git is on the path.
22720  This can be set from within \SpecialChar LyX
22721  at 
22722 \family sans
22723 Tools\SpecialChar menuseparator
22724 Preferences\SpecialChar menuseparator
22725 Paths\SpecialChar menuseparator
22726 PATH prefix
22727 \family default
22728 .
22729 \end_layout
22730
22731 \end_inset
22732
22733
22734 \end_layout
22735
22736 \begin_layout Standard
22737 One big difference of GIT and the other supported version control systems
22738  is the distributed nature of GIT: With traditional version control systems
22739  there is one central server which hosts the repository.
22740  Users commit their changes to the server, and get updates made by other
22741  users from it.
22742  With GIT, users commit to a local repository.
22743  The local repository can be synchronized with one or more remote repositories
22744  using the 
22745 \begin_inset Flex Code
22746 status collapsed
22747
22748 \begin_layout Plain Layout
22749 pull
22750 \end_layout
22751
22752 \end_inset
22753
22754  and 
22755 \begin_inset Flex Code
22756 status collapsed
22757
22758 \begin_layout Plain Layout
22759 push
22760 \end_layout
22761
22762 \end_inset
22763
22764  GIT commands.
22765  \SpecialChar LyX
22766  does not interact in any way with remote GIT repositories.
22767  It works exclusively with the local repository in a very similar way as
22768  with a central CVS or SVN repository.
22769  If you use remote GIT repositories you need to do the 
22770 \begin_inset Flex Code
22771 status collapsed
22772
22773 \begin_layout Plain Layout
22774 pull
22775 \end_layout
22776
22777 \end_inset
22778
22779  and 
22780 \begin_inset Flex Code
22781 status collapsed
22782
22783 \begin_layout Plain Layout
22784 push
22785 \end_layout
22786
22787 \end_inset
22788
22789  operations with your favourite GIT client.
22790 \end_layout
22791
22792 \begin_layout Subsubsection
22793
22794 \family sans
22795 Register
22796 \end_layout
22797
22798 \begin_layout Standard
22799 If your document is not under revision control, this is the only item shown
22800  in the menu.
22801  And if it is under revision control, the 
22802 \family sans
22803 Register
22804 \family default
22805  item is not visible.
22806 \end_layout
22807
22808 \begin_layout Standard
22809 This command registers in GIT your document ONLY in case you have already
22810  the documents directory under GIT control (in particular 
22811 \family typewriter
22812 .git/index
22813 \family default
22814  file exists).
22815  This means you have to checkout the archive by yourself.
22816 \end_layout
22817
22818 \begin_layout Standard
22819 Then you are asked interactively to supply an initial description of the
22820  document.
22821  Don't forget that registered file is not yet committed.
22822 \end_layout
22823
22824 \begin_layout Standard
22825 GIT command that is run: 
22826 \family typewriter
22827 git add 
22828 \begin_inset Quotes qld
22829 \end_inset
22830
22831 <file-name>
22832 \begin_inset Quotes qld
22833 \end_inset
22834
22835
22836 \end_layout
22837
22838 \begin_layout Standard
22839 Read 
22840 \family typewriter
22841 man git
22842 \family default
22843  to understand the switches.
22844 \end_layout
22845
22846 \begin_layout Subsubsection
22847
22848 \family sans
22849 Check In Changes
22850 \end_layout
22851
22852 \begin_layout Standard
22853 When you are finished editing a file, you commit your changes.
22854  When you do this, you are asked for a description of the changes.
22855  After that changes are committed.
22856 \end_layout
22857
22858 \begin_layout Standard
22859 GIT command: 
22860 \family typewriter
22861 git commit -q -m"<description>" <file-name>
22862 \end_layout
22863
22864 \begin_layout Subsubsection
22865
22866 \family sans
22867 Revert To Repository Version
22868 \end_layout
22869
22870 \begin_layout Standard
22871 This will discard all changes made to the document since the last check
22872  in.
22873  You get a warning before changes are discarded.
22874 \end_layout
22875
22876 \begin_layout Standard
22877 GIT command: 
22878 \family typewriter
22879 git checkout -q 
22880 \begin_inset Quotes qld
22881 \end_inset
22882
22883 <file-name>
22884 \begin_inset Quotes qld
22885 \end_inset
22886
22887
22888 \end_layout
22889
22890 \begin_layout Subsubsection
22891
22892 \family sans
22893 Rename
22894 \end_layout
22895
22896 \begin_layout Standard
22897 This will rename the current document including the version history.
22898  It requires a clean document without any changes since the last checkin.
22899  You are asked for a file name and a description of the rename operation.
22900  After that the document is renamed, both locally and in the repository.
22901  If the parent directories of the new and old file names differ, all relative
22902  paths of included files are adjusted (like in 
22903 \family sans
22904 File\SpecialChar menuseparator
22905 Save As
22906 \family default
22907 \SpecialChar ldots
22908 ).
22909  Finally, the document is reloaded using the new name.
22910 \end_layout
22911
22912 \begin_layout Labeling
22913 \labelwidthstring 00.00.0000
22914 GIT
22915 \begin_inset space ~
22916 \end_inset
22917
22918 commands: 
22919 \begin_inset space ~
22920 \end_inset
22921
22922
22923 \begin_inset Newline newline
22924 \end_inset
22925
22926
22927 \begin_inset Flex Code
22928 status collapsed
22929
22930 \begin_layout Plain Layout
22931 git mv 
22932 \family typewriter
22933
22934 \begin_inset Quotes qld
22935 \end_inset
22936
22937 <file-name>
22938 \begin_inset Quotes qld
22939 \end_inset
22940
22941  
22942 \begin_inset Quotes qld
22943 \end_inset
22944
22945 <new-file-name>
22946 \begin_inset Quotes qld
22947 \end_inset
22948
22949
22950 \end_layout
22951
22952 \end_inset
22953
22954
22955 \begin_inset Newline newline
22956 \end_inset
22957
22958
22959 \begin_inset Flex Code
22960 status collapsed
22961
22962 \begin_layout Plain Layout
22963 git commit
22964 \end_layout
22965
22966 \end_inset
22967
22968
22969 \end_layout
22970
22971 \begin_layout Subsubsection
22972
22973 \family sans
22974 Show History
22975 \end_layout
22976
22977 \begin_layout Standard
22978 This shows the complete history of the GIT document.
22979  The output of 
22980 \family typewriter
22981 git log 
22982 \begin_inset Quotes qld
22983 \end_inset
22984
22985 <file-name>
22986 \begin_inset Quotes qld
22987 \end_inset
22988
22989
22990 \family default
22991  is shown in a browser.
22992 \end_layout
22993
22994 \begin_layout Subsubsection
22995 Version Info
22996 \end_layout
22997
22998 \begin_layout Standard
22999 \SpecialChar LyX
23000  supports GIT hash number of the last commit to the file, 
23001 \change_inserted 1119979965 1564297456
23002 its abbreviated form, 
23003 \change_unchanged
23004 author name, date and time of last commit.
23005  All those are extracted from 
23006 \family typewriter
23007 git log -n 1 --pretty=format:%H%n
23008 \change_inserted 1119979965 1564297427
23009 %h%n
23010 \change_unchanged
23011 %an%n%ai
23012 \family default
23013 .
23014  Tree version information is obtained via 
23015 \family typewriter
23016 git describe --abbrev --dirty --long
23017 \family default
23018 .
23019  See 
23020 \begin_inset CommandInset ref
23021 LatexCommand ref
23022 reference "subsec:VCS-Revision-Information"
23023
23024 \end_inset
23025
23026  for other details.
23027 \end_layout
23028
23029 \begin_layout Subsection
23030 Further tuning
23031 \end_layout
23032
23033 \begin_layout Standard
23034 With the recent addition of the 
23035 \begin_inset Flex Code
23036 status collapsed
23037
23038 \begin_layout Plain Layout
23039 vc-command
23040 \end_layout
23041
23042 \end_inset
23043
23044  function \SpecialChar LyX
23045  power users are allowed to create their own commands for revision
23046  control.
23047 \end_layout
23048
23049 \begin_layout Standard
23050 As an example you can see how two TortoiseSVN commands could be integrated
23051  directly:
23052 \end_layout
23053
23054 \begin_layout Description
23055 Commit: 
23056 \begin_inset Flex Code
23057 status collapsed
23058
23059 \begin_layout Plain Layout
23060 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
23061 \end_layout
23062
23063 \end_inset
23064
23065
23066 \end_layout
23067
23068 \begin_layout Description
23069 Revert: 
23070 \begin_inset Flex Code
23071 status collapsed
23072
23073 \begin_layout Plain Layout
23074 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
23075 \end_layout
23076
23077 \end_inset
23078
23079
23080 \end_layout
23081
23082 \begin_layout Subsection
23083 Version control and Document comparison
23084 \end_layout
23085
23086 \begin_layout Standard
23087 One of the typical uses of version control is to inspect the changes between
23088  revisions, usually by creating 
23089 \begin_inset Flex Code
23090 status collapsed
23091
23092 \begin_layout Plain Layout
23093 diff
23094 \end_layout
23095
23096 \end_inset
23097
23098  dumps.
23099  While this is useful for plain text files, it is much less useful in the
23100  case of \SpecialChar LyX
23101  files, which have more a complicated structure.
23102  Hence we provide binding to the Document comparison feature.
23103  There are two ways of calling this feature – either by direct call of 
23104 \begin_inset Flex Code
23105 status collapsed
23106
23107 \begin_layout Plain Layout
23108 vc-compare
23109 \end_layout
23110
23111 \end_inset
23112
23113  \SpecialChar LyX
23114  function (for details see \SpecialChar LyX
23115  functions manual) or by the toolbar icon 
23116 \begin_inset Info
23117 type  "icon"
23118 arg   "vc-compare"
23119 \end_inset
23120
23121  or the menu item 
23122 \begin_inset Info
23123 type  "menu"
23124 arg   "vc-compare"
23125 \end_inset
23126
23127 , respectively.
23128  One can either compare two chosen revisions of the document or he can simply
23129  compare the current version of edited text with older revisions (where
23130  '
23131 \begin_inset Flex Noun
23132 status collapsed
23133
23134 \begin_layout Plain Layout
23135 0
23136 \end_layout
23137
23138 \end_inset
23139
23140 ' revisions back means comparison of the edited file with last commited
23141  revision).
23142  
23143 \end_layout
23144
23145 \begin_layout Standard
23146 This feature is supported for SVN and RCS though due to the more complicated
23147  versioning scheme of RCS there is a constraint – when addressing the revisions
23148  in dialog, numbers always point to the last number in RCS revision number,
23149  i.e.
23150  '35' in '1.2.35'.
23151  We don't currently support GIT addressing of revisions, one can just compare
23152  edited document with its revision X steps backs, where X is addressed as
23153  
23154 \begin_inset Flex Code
23155 status collapsed
23156
23157 \begin_layout Plain Layout
23158 HEAD~X
23159 \end_layout
23160
23161 \end_inset
23162
23163 .
23164 \end_layout
23165
23166 \begin_layout Section
23167 Literate Programming
23168 \end_layout
23169
23170 \begin_layout Standard
23171 Updated by 
23172 \noun on
23173 Kayvan Sylvan 
23174 \noun default
23175 (kayvan@sylvan.com)
23176 \noun on
23177
23178 \noun default
23179 original documentation written by 
23180 \noun on
23181 Edmar Wienskoski Jr.
23182
23183 \noun default
23184  (edmar-w-jr@technologist.com)
23185 \end_layout
23186
23187 \begin_layout Subsection
23188 Introduction
23189 \end_layout
23190
23191 \begin_layout Standard
23192 The main purpose of this documentation is to show you how to use \SpecialChar LyX
23193  for literate
23194  programming, where it is assumed that you are familiar with this programming
23195  technique, and know what 
23196 \begin_inset Quotes eld
23197 \end_inset
23198
23199 tangling
23200 \begin_inset Quotes erd
23201 \end_inset
23202
23203  and 
23204 \begin_inset Quotes eld
23205 \end_inset
23206
23207 weaving
23208 \begin_inset Quotes erd
23209 \end_inset
23210
23211  means.
23212  If that is not the case, please follow the web links provided in the following
23213  sections.
23214  There is a lot of good documentation out there covering old development
23215  history to the latest tools tips.
23216 \end_layout
23217
23218 \begin_layout Standard
23219 It is also assumed that you are familiar with \SpecialChar LyX
23220  itself to a point that you
23221  are comfortable changing your \SpecialChar LyX
23222  preferences, and X resources file.
23223  If that is not the case please refer to other \SpecialChar LyX
23224  documentation to cover your
23225  specific needs.
23226 \end_layout
23227
23228 \begin_layout Subsection
23229 Literate Programming
23230 \end_layout
23231
23232 \begin_layout Standard
23233 From the Literate Programming FAQ: 
23234 \end_layout
23235
23236 \begin_layout Quotation
23237 Literate programming is the combination of documentation and source together
23238  in a fashion suited for reading by human beings.
23239  In fact, literate programs should be enjoyable reading, even inviting!
23240  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
23241  and documentation in a single file.
23242  Literate programming tools then parse the file to produce either readable
23243  documentation or compilable source.
23244  The WEB style of literate programming was created by D.
23245 \begin_inset space \thinspace{}
23246 \end_inset
23247
23248 E.
23249  Knuth during the development of his \SpecialChar TeX
23250  typesetting software.
23251  
23252 \end_layout
23253
23254 \begin_layout Standard
23255 Another excerpt says:
23256 \end_layout
23257
23258 \begin_layout Quotation
23259
23260 \emph on
23261 How is literate programming different from verbose commenting?
23262 \end_layout
23263
23264 \begin_layout Quotation
23265 There are three distinguishing characteristics.
23266  In order of importance, they are: 
23267 \end_layout
23268
23269 \begin_deeper
23270 \begin_layout Itemize
23271 flexible order of elaboration 
23272 \end_layout
23273
23274 \begin_layout Itemize
23275 automatic support for browsing 
23276 \end_layout
23277
23278 \begin_layout Itemize
23279 typeset documentation, especially diagrams and mathematics 
23280 \end_layout
23281
23282 \end_deeper
23283 \begin_layout Standard
23284 Now that I sparked your curiosity, take a look in the references.
23285 \end_layout
23286
23287 \begin_layout Subsubsection
23288 References
23289 \end_layout
23290
23291 \begin_layout Standard
23292 The complete Literate Programming FAQ can be found at:
23293 \end_layout
23294
23295 \begin_layout Quote
23296 Literate Programming FAQ 
23297 \begin_inset Flex URL
23298 status open
23299
23300 \begin_layout Plain Layout
23301
23302 http://www.literateprogramming.com/lpfaq.pdf
23303 \end_layout
23304
23305 \end_inset
23306
23307
23308 \end_layout
23309
23310 \begin_layout Standard
23311 The FAQ lists 23 (twenty three!) different literate programming tools.
23312  Where some are specialized or 
23313 \begin_inset Quotes eld
23314 \end_inset
23315
23316 tailored
23317 \begin_inset Quotes erd
23318 \end_inset
23319
23320  for particular programming languages, while other have general scope.
23321  I selected 
23322 \noun on
23323 Noweb
23324 \noun default
23325  for my own use for several reasons:
23326 \end_layout
23327
23328 \begin_layout Itemize
23329 It can generate the documentation either in \SpecialChar LaTeX
23330  or HTML.
23331 \end_layout
23332
23333 \begin_layout Itemize
23334 It has a open architecture, i.
23335 \begin_inset space \thinspace{}
23336 \end_inset
23337
23338 e.
23339 \begin_inset space \space{}
23340 \end_inset
23341
23342 it is easy to plug in new filters
23343 \begin_inset Foot
23344 status collapsed
23345
23346 \begin_layout Plain Layout
23347
23348 \emph on
23349 Filters 
23350 \emph default
23351 are programs that read a given data stream and output a manipulated data
23352  stream.
23353  That way, a WEB file (consisting of literate code) can be turned into a
23354  file consisting only of C program code or \SpecialChar LaTeX
23355  code.
23356 \end_layout
23357
23358 \end_inset
23359
23360  and to perform special processing that you may need.
23361  
23362 \end_layout
23363
23364 \begin_layout Itemize
23365 There is a good selection of filters available already (the HTML is one
23366  of them).
23367 \end_layout
23368
23369 \begin_layout Itemize
23370 It is free.
23371 \end_layout
23372
23373 \begin_layout Standard
23374 The Noweb web page can be found at: 
23375 \end_layout
23376
23377 \begin_layout Quote
23378 Noweb home page 
23379 \begin_inset Flex URL
23380 status collapsed
23381
23382 \begin_layout Plain Layout
23383
23384 https://www.cs.tufts.edu/~nr/noweb/
23385 \end_layout
23386
23387 \end_inset
23388
23389
23390 \end_layout
23391
23392 \begin_layout Standard
23393 Starting from there you can reach many other interesting links and even
23394  some literate program examples.
23395 \end_layout
23396
23397 \begin_layout Subsection
23398 \SpecialChar LyX
23399  and Literate Programming with Noweb
23400 \end_layout
23401
23402 \begin_layout Standard
23403 The \SpecialChar LyX
23404  support for Literate Programming is provided by using the generic \SpecialChar LyX
23405
23406  converters mechanism.
23407  This support is provided in a 
23408 \begin_inset Quotes eld
23409 \end_inset
23410
23411 Noweb independent
23412 \begin_inset Quotes erd
23413 \end_inset
23414
23415  way, i.
23416 \begin_inset space \thinspace{}
23417 \end_inset
23418
23419 e.
23420 \begin_inset space \space{}
23421 \end_inset
23422
23423 you will be able to use this new \SpecialChar LyX
23424  feature with some other literate programming
23425  tool of your choice by just changing your \SpecialChar LyX
23426  preferences.
23427 \end_layout
23428
23429 \begin_layout Subsubsection
23430 Generating documents and code (weaving and tangling)
23431 \end_layout
23432
23433 \begin_layout Paragraph
23434 Using the noweb module
23435 \end_layout
23436
23437 \begin_layout Standard
23438 If you have installed Noweb and \SpecialChar LyX
23439  successfully, whenever you open a new document,
23440  after you have chosen its document class, use the 
23441 \family sans
23442 Document\SpecialChar menuseparator
23443 Settings
23444 \family default
23445  menu to add the 
23446 \begin_inset Quotes eld
23447 \end_inset
23448
23449 noweb
23450 \begin_inset Quotes erd
23451 \end_inset
23452
23453  module.
23454  If Noweb is correctly installed, when you click on the 
23455 \begin_inset Quotes eld
23456 \end_inset
23457
23458 Modules
23459 \begin_inset Quotes erd
23460 \end_inset
23461
23462  link, you will see the 
23463 \begin_inset Quotes eld
23464 \end_inset
23465
23466 noweb
23467 \begin_inset Quotes erd
23468 \end_inset
23469
23470  module in the available list and you can add it to your document.
23471 \end_layout
23472
23473 \begin_layout Paragraph
23474 Typing code in
23475 \end_layout
23476
23477 \begin_layout Standard
23478 \SpecialChar LyX
23479  enables you to write code with a custom inset named 
23480 \begin_inset Flex Noun
23481 status collapsed
23482
23483 \begin_layout Plain Layout
23484 Chunk
23485 \end_layout
23486
23487 \end_inset
23488
23489 .
23490  Noweb delimits chunks like this:
23491 \end_layout
23492
23493 \begin_layout LyX-Code
23494 <<My code>>=
23495 \end_layout
23496
23497 \begin_layout LyX-Code
23498   code
23499 \end_layout
23500
23501 \begin_layout LyX-Code
23502   more code
23503 \end_layout
23504
23505 \begin_layout LyX-Code
23506   even more code
23507 \end_layout
23508
23509 \begin_layout LyX-Code
23510   @
23511 \end_layout
23512
23513 \begin_layout Standard
23514 The problem is that whatever is written in between the << and the 
23515 \family typewriter
23516 @
23517 \family default
23518  must be taken literally, i.
23519 \begin_inset space \thinspace{}
23520 \end_inset
23521
23522 e.
23523 \begin_inset space \space{}
23524 \end_inset
23525
23526 \SpecialChar LyX
23527  should be prevented from making any special interpretation of what has
23528  been written.
23529  This is also handled by 
23530 \begin_inset Flex Noun
23531 status collapsed
23532
23533 \begin_layout Plain Layout
23534 Chunk
23535 \end_layout
23536
23537 \end_inset
23538
23539 , that works like a normal text inset but has a free spacing capability.
23540 \end_layout
23541
23542 \begin_layout Standard
23543 As a special note, you can also use the 
23544 \begin_inset Quotes eld
23545 \end_inset
23546
23547 %def
23548 \begin_inset Quotes erd
23549 \end_inset
23550
23551  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
23552 rence:
23553 \end_layout
23554
23555 \begin_layout LyX-Code
23556 <<My chunk>>=
23557 \end_layout
23558
23559 \begin_layout LyX-Code
23560 def some_function(args):
23561 \end_layout
23562
23563 \begin_layout LyX-Code
23564    "This is the doc string for this function."
23565 \end_layout
23566
23567 \begin_layout LyX-Code
23568    print "My args: ", args
23569 \end_layout
23570
23571 \begin_layout LyX-Code
23572 @ %def some_function
23573 \end_layout
23574
23575 \begin_layout Standard
23576 For an example of this usage and the resulting cross-reference output, look
23577  at the Literate python program in 
23578 \emph on
23579 LIBDIR/examples/listerrors.lyx
23580 \emph default
23581  which should make this all clear.
23582 \end_layout
23583
23584 \begin_layout Paragraph
23585 Generating the documentation
23586 \end_layout
23587
23588 \begin_layout Standard
23589 At this point you already have a new document file with a proper document
23590  class, and with some code and text on it.
23591  How do I print it? The answer is simple, you select 
23592 \family sans
23593 View\SpecialChar menuseparator
23594 DVI,
23595 \family default
23596  etc.
23597  Just like you would do for a plain document.
23598  No special procedure is required.
23599 \end_layout
23600
23601 \begin_layout Standard
23602 To help orientate you, I will now explain what happens inside \SpecialChar LyX
23603 :
23604 \end_layout
23605
23606 \begin_layout Enumerate
23607 When the 
23608 \family sans
23609 Update\SpecialChar menuseparator
23610 DVI
23611 \family default
23612  menu option is chosen, a \SpecialChar LaTeX
23613  file is generated.
23614  
23615 \end_layout
23616
23617 \begin_deeper
23618 \begin_layout Standard
23619 If the document is of any literate class the generated file will be named
23620  with an extension name defined by the 
23621 \begin_inset Quotes eld
23622 \end_inset
23623
23624 literate
23625 \begin_inset Quotes erd
23626 \end_inset
23627
23628  format (defined in the Preferences panel), otherwise the file will have
23629  the usual 
23630 \family typewriter
23631 .tex
23632 \family default
23633  extension.
23634 \end_layout
23635
23636 \end_deeper
23637 \begin_layout Enumerate
23638 Note that the only difference so far is in the name of the file, no special
23639  processing is required by \SpecialChar LyX
23640 .
23641  Given that you formatted the code using the 
23642 \begin_inset Flex Noun
23643 status collapsed
23644
23645 \begin_layout Plain Layout
23646 Chunk
23647 \end_layout
23648
23649 \end_inset
23650
23651  inset that, by itself, takes care of the business.
23652 \end_layout
23653
23654 \begin_layout Enumerate
23655 If the document is of any literate class \SpecialChar LyX
23656  will then use the internal \SpecialChar LyX
23657  to
23658  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
23659  converter
23660 \begin_inset Foot
23661 status collapsed
23662
23663 \begin_layout Plain Layout
23664 The converters are defined in the 
23665 \family sans
23666 Tools\SpecialChar menuseparator
23667 Preferences
23668 \family default
23669  panel, under the 
23670 \begin_inset Quotes eld
23671 \end_inset
23672
23673 Conversion
23674 \begin_inset Quotes erd
23675 \end_inset
23676
23677  tab.
23678  See section 
23679 \emph on
23680 Converters
23681 \emph default
23682  of the 
23683 \emph on
23684 Customization
23685 \emph default
23686  manual for general information about converters.
23687 \end_layout
23688
23689 \end_inset
23690
23691  to generate the \SpecialChar LaTeX
23692  file.
23693 \end_layout
23694
23695 \begin_deeper
23696 \begin_layout Standard
23697 Otherwise it will just skip this step.
23698 \end_layout
23699
23700 \end_deeper
23701 \begin_layout Enumerate
23702 Finally, \SpecialChar LaTeX
23703  is invoked and the regular post processing continues as in a plain
23704  document.
23705 \end_layout
23706
23707 \begin_layout Standard
23708 Independence from a particular 
23709 \begin_inset Quotes eld
23710 \end_inset
23711
23712 literate tool
23713 \begin_inset Quotes erd
23714 \end_inset
23715
23716  is easily achieved by changing the commands that are run by the various
23717  converters.
23718 \end_layout
23719
23720 \begin_layout Paragraph
23721 Generating the code
23722 \end_layout
23723
23724 \begin_layout Standard
23725 When the build menu option is chosen or the corresponding button in the
23726  toolbar is pressed, a \SpecialChar LaTeX
23727  file is generated just like step 1 above.
23728  Next, \SpecialChar LyX
23729  invokes the 
23730 \family typewriter
23731 Noweb->Program
23732 \family default
23733  converter.
23734  This converter needs to be defined by the user and is not installed by
23735  default, though the Program format is.
23736  This converter (like any other converter) will have two parts:
23737 \end_layout
23738
23739 \begin_layout Enumerate
23740 The converter program itself.
23741  This program performs the conversion from the one format to the other (in
23742  this case, from the Noweb format to the Program pseudo-format).
23743 \end_layout
23744
23745 \begin_layout Enumerate
23746 The error log parser.
23747  This is a program whose sole purpose is to rewrite error messages in a
23748  format that \SpecialChar LyX
23749  understands.
23750  This makes it possible for \SpecialChar LyX
23751  to place error boxes in the right places in
23752  the file buffer.
23753 \end_layout
23754
23755 \begin_layout Standard
23756 The first part, the 
23757 \begin_inset Quotes eld
23758 \end_inset
23759
23760 Converter
23761 \begin_inset Quotes erd
23762 \end_inset
23763
23764  setting, should be set to
23765 \end_layout
23766
23767 \begin_layout LyX-Code
23768
23769 \family typewriter
23770 build-script $$i
23771 \family default
23772  $$r
23773 \end_layout
23774
23775 \begin_layout Standard
23776 This basically means that \SpecialChar LyX
23777  will call 
23778 \begin_inset Quotes eld
23779 \end_inset
23780
23781 build-script
23782 \begin_inset Quotes erd
23783 \end_inset
23784
23785  (a program or script) with the name of the Noweb file (normally a file
23786  in the \SpecialChar LyX
23787  temp directory) and the directory path of the original \SpecialChar LyX
23788  file.
23789  
23790 \end_layout
23791
23792 \begin_layout Standard
23793 This is an implementation of 
23794 \begin_inset Quotes eld
23795 \end_inset
23796
23797 build-script
23798 \begin_inset Quotes erd
23799 \end_inset
23800
23801  that you can place in a directory on your path:
23802 \end_layout
23803
23804 \begin_layout LyX-Code
23805
23806 \family sans
23807 #!/bin/sh
23808 \end_layout
23809
23810 \begin_layout LyX-Code
23811
23812 \family sans
23813 #
23814 \end_layout
23815
23816 \begin_layout LyX-Code
23817
23818 \family sans
23819 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
23820 \end_layout
23821
23822 \begin_layout Standard
23823 The next part of the converter setting is the 
23824 \begin_inset Quotes eld
23825 \end_inset
23826
23827 Flags
23828 \begin_inset Quotes erd
23829 \end_inset
23830
23831  which is to be set to
23832 \end_layout
23833
23834 \begin_layout LyX-Code
23835
23836 \family typewriter
23837 parselog=$$s/scripts/listerrors
23838 \end_layout
23839
23840 \begin_layout Standard
23841 This will run any errors that are generated by the 
23842 \begin_inset Quotes eld
23843 \end_inset
23844
23845 build-script
23846 \begin_inset Quotes erd
23847 \end_inset
23848
23849  process through the 
23850 \begin_inset Quotes eld
23851 \end_inset
23852
23853 listerrors
23854 \begin_inset Quotes erd
23855 \end_inset
23856
23857  program.
23858 \end_layout
23859
23860 \begin_layout Standard
23861 The build will normally take place in \SpecialChar LyX
23862 's temporary directory, so the files
23863  produced by the conversion will be in that directory.
23864  \SpecialChar LyX
23865  will copy out what it regards as the `main' file, but the 
23866 \family typewriter
23867 Noweb->Program
23868 \family default
23869  conversion may produce several files, and so most of these would then be
23870  deleted when \SpecialChar LyX
23871  was closed.
23872  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
23873  the build-script chunk can place the generated files in that location.
23874 \end_layout
23875
23876 \begin_layout Paragraph
23877 Build instructions in the document
23878 \end_layout
23879
23880 \begin_layout Standard
23881 The last piece of the integration between \SpecialChar LyX
23882  and noweb is the 
23883 \begin_inset Quotes eld
23884 \end_inset
23885
23886 build-script
23887 \begin_inset Quotes erd
23888 \end_inset
23889
23890  chunk.
23891  Generally, the instructions for building your program should be embedded
23892  in a chunk of its own.
23893  The noweb-specific 
23894 \begin_inset Quotes eld
23895 \end_inset
23896
23897 build-script
23898 \begin_inset Quotes erd
23899 \end_inset
23900
23901  above uses the notangle command to look for this chunk (called 
23902 \begin_inset Quotes eld
23903 \end_inset
23904
23905 build-script
23906 \begin_inset Quotes erd
23907 \end_inset
23908
23909 ) and runs its contents through 
23910 \begin_inset Quotes eld
23911 \end_inset
23912
23913 sh
23914 \begin_inset Quotes erd
23915 \end_inset
23916
23917 .
23918 \end_layout
23919
23920 \begin_layout Standard
23921 Typically, such a chunk would look something like this:
23922 \end_layout
23923
23924 \begin_layout LyX-Code
23925 <<build-script>>=
23926 \end_layout
23927
23928 \begin_layout LyX-Code
23929 #!/bin/sh
23930 \begin_inset Newline newline
23931 \end_inset
23932
23933 if [ -z "${NOWEB_SOURCE}" ]
23934 \begin_inset Newline newline
23935 \end_inset
23936
23937 then
23938 \end_layout
23939
23940 \begin_layout LyX-Code
23941 NOWEB_SOURCE=myfile.nw
23942 \begin_inset Newline newline
23943 \end_inset
23944
23945 fi
23946 \begin_inset Newline newline
23947 \end_inset
23948
23949 [...
23950  code to extract files ...
23951  use NOWEB_OUTPUT_DIR here ...]
23952 \begin_inset Newline newline
23953 \end_inset
23954
23955 [...
23956  code to compile files ...]
23957 \begin_inset Newline newline
23958 \end_inset
23959
23960 @
23961 \end_layout
23962
23963 \begin_layout Standard
23964 Look in 
23965 \emph on
23966 LIBDIR/examples/listerrors.lyx
23967 \emph default
23968  or in 
23969 \emph on
23970 LIBDIR/examples/Literate.lyx
23971 \emph default
23972  which implement two versions of the 
23973 \begin_inset Quotes eld
23974 \end_inset
23975
23976 listerrors
23977 \begin_inset Quotes erd
23978 \end_inset
23979
23980  program for some illustrations of how all of these pieces go together or
23981  in 
23982 \emph on
23983 LIBDIR/examples/noweb2lyx.lyx.
23984
23985 \emph default
23986  Interestingly, these three files show off the language-indepence of the
23987  \SpecialChar LyX
23988  literate programming support since they are written in Python, C and Perl
23989  respectively.
23990 \end_layout
23991
23992 \begin_layout Subsubsection
23993 Configuring \SpecialChar LyX
23994
23995 \end_layout
23996
23997 \begin_layout Standard
23998 All the Literate Programming support is configured by the 
23999 \family sans
24000 Tools\SpecialChar menuseparator
24001 Preferences
24002 \family default
24003  panel in the 
24004 \begin_inset Quotes eld
24005 \end_inset
24006
24007 File Handling
24008 \begin_inset Quotes erd
24009 \end_inset
24010
24011  tab.
24012  The important parts are:
24013 \end_layout
24014
24015 \begin_layout Description
24016 the
24017 \begin_inset space ~
24018 \end_inset
24019
24020
24021 \begin_inset Quotes eld
24022 \end_inset
24023
24024 NoWeb
24025 \begin_inset Quotes erd
24026 \end_inset
24027
24028
24029 \begin_inset space ~
24030 \end_inset
24031
24032 format Set up via the File Formats tab, this is where the Noweb-specific
24033  pieces are set up.
24034  The 
24035 \family sans
24036 GUI Name
24037 \family default
24038  is set to 
24039 \family typewriter
24040 NoWeb
24041 \family default
24042 , the file extension is set to 
24043 \family typewriter
24044 .nw
24045 \family default
24046 .
24047  This tells \SpecialChar LyX
24048  to create a file with a 
24049 \family typewriter
24050 .nw
24051 \family default
24052  extension in the first step of the conversion process.
24053 \end_layout
24054
24055 \begin_layout Description
24056 the
24057 \begin_inset space ~
24058 \end_inset
24059
24060
24061 \family sans
24062 Program
24063 \family default
24064
24065 \begin_inset space ~
24066 \end_inset
24067
24068 format This is an empty format whose sole purpose is to be the endpoint
24069  of a conversion (which then allows us to set up a converter for it).
24070 \end_layout
24071
24072 \begin_layout Description
24073
24074 \family sans
24075 NoWeb
24076 \family default
24077 ->
24078 \family sans
24079 \SpecialChar LaTeX
24080
24081 \family default
24082  This converter performs the 
24083 \begin_inset Quotes eld
24084 \end_inset
24085
24086 weaving
24087 \begin_inset Quotes erd
24088 \end_inset
24089
24090  of the literate document.
24091  For Noweb, it is set to 
24092 \begin_inset Quotes eld
24093 \end_inset
24094
24095
24096 \family typewriter
24097 noweave -delay -index $$i > $$o
24098 \family default
24099
24100 \begin_inset Quotes erd
24101 \end_inset
24102
24103
24104 \end_layout
24105
24106 \begin_layout Description
24107
24108 \family sans
24109 NoWeb
24110 \family default
24111 ->
24112 \family sans
24113 Program
24114 \family default
24115  This performs the 
24116 \begin_inset Quotes eld
24117 \end_inset
24118
24119 tangling step
24120 \begin_inset Quotes erd
24121 \end_inset
24122
24123 .
24124  As stated above, the Converter is set to 
24125 \begin_inset Quotes eld
24126 \end_inset
24127
24128
24129 \family typewriter
24130 build-script $$i
24131 \family default
24132  $$r
24133 \begin_inset Quotes erd
24134 \end_inset
24135
24136 , with Flags set to
24137 \begin_inset Newline newline
24138 \end_inset
24139
24140
24141 \begin_inset Quotes eld
24142 \end_inset
24143
24144
24145 \family typewriter
24146 parselog=$$s/scripts/listerrors
24147 \family default
24148
24149 \begin_inset Quotes erd
24150 \end_inset
24151
24152 .
24153 \end_layout
24154
24155 \begin_layout Subsubsection
24156 Debug extensions
24157 \end_layout
24158
24159 \begin_layout Standard
24160 There is also a new function implemented in the \SpecialChar LyX
24161  server, the 
24162 \begin_inset Quotes eld
24163 \end_inset
24164
24165 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
24166  
24167 \end_layout
24168
24169 \begin_layout Standard
24170 When debugging code with ddd/gdb, it is possible to invoke a text editor
24171  at the current execution position with a single key stroke.
24172  The default ddd configuration for that is shift-ctrl-V.
24173  It happens that you can define the editor command line invocation in ddd
24174  by accessing the 
24175 \family sans
24176 Edit\SpecialChar menuseparator
24177 Preferences\SpecialChar menuseparator
24178 Helpers
24179 \family default
24180  dialog and changing the "Edit Sources" entry.
24181 \end_layout
24182
24183 \begin_layout Standard
24184 I take advantage of the newly created \SpecialChar LyX
24185  server function and this ddd feature,
24186  and set 
24187 \begin_inset Quotes eld
24188 \end_inset
24189
24190 Edit Sources
24191 \begin_inset Quotes erd
24192 \end_inset
24193
24194  to:
24195 \end_layout
24196
24197 \begin_layout LyX-Code
24198 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
24199 \end_layout
24200
24201 \begin_layout Standard
24202 With this, whenever you are using ddd and find a point in the program that
24203  you want to edit, you just press shift-ctrl-V (in the ddd window), and
24204  ddd will forward this information to \SpecialChar LyX
24205  through the \SpecialChar LyX
24206  server and then the
24207  \SpecialChar LyX
24208  window will show the same file with the cursor at the same position ddd
24209  was pointing to.
24210  No more guessing or long scrolling to locate a point in the program back
24211  from debugging !
24212 \end_layout
24213
24214 \begin_layout Standard
24215 Note however that you must enable the \SpecialChar LyX
24216  server to get this feature working
24217  (it is disabled by default).
24218  Sec.
24219 \begin_inset space ~
24220 \end_inset
24221
24222
24223 \begin_inset CommandInset ref
24224 LatexCommand ref
24225 reference "sec:Starting-the-Server"
24226
24227 \end_inset
24228
24229  explains how to do that.
24230 \end_layout
24231
24232 \begin_layout Subsubsection
24233 Toolbar extensions
24234 \end_layout
24235
24236 \begin_layout Standard
24237 There are six new buttons that can be added to your \SpecialChar LyX
24238  toolbar.
24239  Four of these buttons are short cuts to layout styles: 
24240 \family sans
24241 Standard
24242 \family default
24243
24244 \family sans
24245 Section
24246 \family default
24247
24248 \family sans
24249 \SpecialChar LaTeX
24250
24251 \family default
24252 , and 
24253 \family sans
24254 \SpecialChar LyX
24255 -Code
24256 \family default
24257 , one for the custom inset 
24258 \family sans
24259 Chunk
24260 \family default
24261 .
24262  The last one is a short cut to the 
24263 \begin_inset Quotes eld
24264 \end_inset
24265
24266 Build Program
24267 \begin_inset Quotes erd
24268 \end_inset
24269
24270  File menu entry.
24271  
24272 \end_layout
24273
24274 \begin_layout Standard
24275 \SpecialChar LyX
24276  has a range of buttons that are available for tool bar customization.
24277  In my toolbar I like to combine the six short cuts above with two more:
24278  One for 
24279 \family sans
24280 Document
24281 \family default
24282 \SpecialChar menuseparator
24283
24284 \family sans
24285 Update
24286 \family default
24287 \SpecialChar menuseparator
24288
24289 \family sans
24290 DVI
24291 \family default
24292  and the other for 
24293 \family sans
24294 Document\SpecialChar menuseparator
24295 View\SpecialChar menuseparator
24296 DVI
24297 \family default
24298  File menu entries.
24299  Here is how it looks like:
24300 \end_layout
24301
24302 \begin_layout LyX-Code
24303 Toolbar
24304 \end_layout
24305
24306 \begin_layout LyX-Code
24307   Layouts
24308 \end_layout
24309
24310 \begin_layout LyX-Code
24311   Icon "layout Standard"
24312 \end_layout
24313
24314 \begin_layout LyX-Code
24315   Icon "layout Section"
24316 \end_layout
24317
24318 \begin_layout LyX-Code
24319   Icon "layout \SpecialChar LaTeX
24320 "
24321 \end_layout
24322
24323 \begin_layout LyX-Code
24324   Icon "layout \SpecialChar LyX
24325 -Code"
24326 \end_layout
24327
24328 \begin_layout LyX-Code
24329   Icon "flex.insert Chunk"
24330 \end_layout
24331
24332 \begin_layout LyX-Code
24333   Separator
24334 \end_layout
24335
24336 \begin_layout LyX-Code
24337   Icon "buffer-view"
24338 \end_layout
24339
24340 \begin_layout LyX-Code
24341   Icon "buffer-typeset"
24342 \end_layout
24343
24344 \begin_layout LyX-Code
24345   Icon "build-program"
24346 \end_layout
24347
24348 \begin_layout LyX-Code
24349   Separator
24350 \end_layout
24351
24352 \begin_layout LyX-Code
24353 .
24354 \end_layout
24355
24356 \begin_layout LyX-Code
24357 .
24358 \end_layout
24359
24360 \begin_layout LyX-Code
24361 .
24362 \end_layout
24363
24364 \begin_layout LyX-Code
24365 End
24366 \end_layout
24367
24368 \begin_layout Subsubsection
24369 Colors customization
24370 \end_layout
24371
24372 \begin_layout Standard
24373 There are a number of colors in \SpecialChar LyX
24374  that can be customized in 
24375 \family sans
24376 Preferences
24377 \family default
24378 .
24379  One of the things that bothers people is the \SpecialChar LaTeX
24380  font color.
24381  The default color is red, since the chunks uses \SpecialChar LaTeX
24382  font, and there is a lot
24383  of chunks in literate documents, you may get tired of seeing everything
24384  in red.
24385  You can change it by going to the tabs 
24386 \family sans
24387 Look&Feel
24388 \family default
24389
24390 \family sans
24391 Colors.
24392 \end_layout
24393
24394 \begin_layout Standard
24395 The next thing is the visible presence of the newline character in the screen.
24396  You can choose the color of this particular character and make it blend
24397  in the background.
24398  I recommend you choosing a color that is close to the background but not
24399  equal, that way you still can see it is there, but it is not bothering
24400  you anymore.
24401 \end_layout
24402
24403 \begin_layout Subsection
24404 \SpecialChar LyX
24405  and knitr/Sweave
24406 \end_layout
24407
24408 \begin_layout Standard
24409 Support for 
24410 \family sans
24411 knitr
24412 \family default
24413  and 
24414 \family sans
24415 Sweave
24416 \family default
24417  is documented in the 
24418 \emph on
24419 knitr.lyx
24420 \emph default
24421  example file and in the Sweave manual (menu 
24422 \family sans
24423 Help\SpecialChar menuseparator
24424 Specific Manuals
24425 \family default
24426 ).
24427 \end_layout
24428
24429 \begin_layout Chapter
24430 Special features
24431 \end_layout
24432
24433 \begin_layout Standard
24434 You can do everything with \SpecialChar LyX
24435  that you can do with \SpecialChar LaTeX
24436 .
24437  However, \SpecialChar LyX
24438  cannot support every \SpecialChar LaTeX
24439  feature directly.
24440  But you can always use \SpecialChar TeX
24441  Code.
24442  This chapter shows you some more special things you might want to use.
24443  For other special things you can do with figures, tables, floats, boxes
24444  and notes, have a look at the 
24445 \emph on
24446 Embedded
24447 \begin_inset space ~
24448 \end_inset
24449
24450 Objects
24451 \emph default
24452  manual.
24453 \end_layout
24454
24455 \begin_layout Section
24456 Multiple Text Columns
24457 \end_layout
24458
24459 \begin_layout Standard
24460 This feature is independent of the option 
24461 \family sans
24462 Two-column document
24463 \family default
24464  in the document settings under 
24465 \family sans
24466 Text Layout
24467 \family default
24468 .
24469  If you want to have 2
24470 \begin_inset space ~
24471 \end_inset
24472
24473 columns for the whole document, it is recommended to use the 
24474 \family sans
24475 Two-column document
24476 \family default
24477  option.
24478  For all other cases use this feature.
24479 \end_layout
24480
24481 \begin_layout Standard
24482 To use multiple text columns in your document, you have to load the module
24483  
24484 \family sans
24485 Multiple Columns
24486 \family default
24487  (menu 
24488 \family sans
24489 Document\SpecialChar menuseparator
24490 Settings\SpecialChar menuseparator
24491 Modules
24492 \family default
24493 ) and must have the \SpecialChar LaTeX
24494 -package 
24495 \begin_inset Flex Code
24496 status collapsed
24497
24498 \begin_layout Plain Layout
24499 multicol
24500 \end_layout
24501
24502 \end_inset
24503
24504  installed.
24505 \end_layout
24506
24507 \begin_layout Standard
24508 Footnotes within multiple columns will be placed at the bottom of the page
24509  and not under each column.
24510  Within the different columns you can use everything, with the limitation
24511  that for floats you need to use the float option 
24512 \family sans
24513 Span columns
24514 \family default
24515 .
24516 \end_layout
24517
24518 \begin_layout Subsection
24519 Basics
24520 \end_layout
24521
24522 \begin_layout Standard
24523 If you want to have 2
24524 \begin_inset space ~
24525 \end_inset
24526
24527 columns in your text, insert a multicolumn inset via the menu 
24528 \family sans
24529 Insert\SpecialChar menuseparator
24530 Custom
24531 \begin_inset space ~
24532 \end_inset
24533
24534 Insets\SpecialChar menuseparator
24535 Multiple
24536 \begin_inset space ~
24537 \end_inset
24538
24539 Columns
24540 \family default
24541  where the columns should start.
24542  Write all text that should be printed in 2
24543 \begin_inset space ~
24544 \end_inset
24545
24546 columns into this inset.
24547 \end_layout
24548
24549 \begin_layout Standard
24550 Here is an example:
24551 \end_layout
24552
24553 \begin_layout Standard
24554 \noindent
24555 \begin_inset Flex Multiple Columns
24556 status open
24557
24558 \begin_layout Plain Layout
24559 \noindent
24560
24561 \series bold
24562 \size small
24563 The Adventure of the Empty House
24564 \series default
24565
24566 \begin_inset Newline newline
24567 \end_inset
24568
24569 by Sir Arthur Conan Doyle
24570 \end_layout
24571
24572 \begin_layout Plain Layout
24573
24574 \size small
24575 It was in the spring of the year 1894 that all London was interested, and
24576  the fashionable world dismayed, by the murder of the Honourable Ronald
24577  Adair under most unusual and inexplicable circumstances.
24578  The public has already learned those particulars of the crime which came
24579  out in the police investigation, but a good deal was suppressed upon that
24580  occasion, since the case for the prosecution was so overwhelmingly strong
24581  that it was not necessary to bring forward all the facts.
24582  Only now, at the end of nearly ten years, am I allowed to supply those
24583  missing links which make up the whole of that remarkable chain.
24584  The crime was of interest in itself, but that interest was as nothing to
24585  me compared to the inconceivable sequel, which afforded me the greatest
24586  shock and surprise of any event in my adventurous life.
24587  Even now, after this long interval, I find myself thrilling as I think
24588  of it, and feeling once more that sudden flood of joy, amazement, and increduli
24589 ty which utterly submerged my mind.
24590  Let me say to that public, which has shown some interest in those glimpses
24591  which I have occasionally given them of the thoughts and actions of a very
24592  remarkable man, that they are not to blame me if I have not shared my knowledge
24593  with them, for I should have considered it my first duty to do so, had
24594  I not been barred by a positive prohibition from his own lips, which was
24595  only withdrawn upon the third of last month.
24596 \end_layout
24597
24598 \end_inset
24599
24600
24601 \end_layout
24602
24603 \begin_layout Standard
24604 To get 3 or more columns, set the cursor into the multicolumn inset and
24605  use the menu 
24606 \family sans
24607 Insert\SpecialChar menuseparator
24608 Number
24609 \begin_inset space ~
24610 \end_inset
24611
24612 of
24613 \begin_inset space ~
24614 \end_inset
24615
24616 Columns
24617 \family default
24618 .
24619  The number of the desired columns is written into that inset (for 3
24620 \begin_inset space ~
24621 \end_inset
24622
24623 columns write 
24624 \begin_inset Quotes eld
24625 \end_inset
24626
24627 3
24628 \begin_inset Quotes erd
24629 \end_inset
24630
24631 ).
24632 \begin_inset Newline newline
24633 \end_inset
24634
24635 Here is an example with 3
24636 \begin_inset space ~
24637 \end_inset
24638
24639 columns:
24640 \end_layout
24641
24642 \begin_layout Standard
24643 \begin_inset Flex Multiple Columns
24644 status open
24645
24646 \begin_layout Plain Layout
24647
24648 \size footnotesize
24649 \begin_inset Argument 1
24650 status open
24651
24652 \begin_layout Plain Layout
24653
24654 3
24655 \end_layout
24656
24657 \end_inset
24658
24659 It can be imagined that my close intimacy with Sherlock Holmes had interested
24660  me deeply in crime, and that after his disappearance I never failed to
24661  read with care the various problems which came before the public.
24662  And I even attempted, more than once, for my own private satisfaction,
24663  to employ his methods in their solution, though with indifferent success.
24664  There was none, however, which appealed to me like this tragedy of Ronald
24665  Adair.
24666  As I read the evidence at the inquest, which led up to a verdict of willful
24667  murder against some person or persons unknown, I realized more clearly
24668  than I had ever done the loss which the community had sustained by the
24669  death of Sherlock Holmes.
24670  There were points about this strange business which would, I was sure,
24671  have specially appealed to him, and the efforts of the police would have
24672  been supplemented, or more probably anticipated, by the trained observation
24673  and the alert mind of the first criminal agent in Europe.
24674  All day, as I drove upon my round, I turned over the case in my mind and
24675  found no explanation which appeared to me to be adequate.
24676  At the risk of telling a twice-told tale, I will recapitulate the facts
24677  as they were known to the public at the conclusion of the inquest.
24678 \end_layout
24679
24680 \end_inset
24681
24682
24683 \end_layout
24684
24685 \begin_layout Standard
24686 You can have up to 10
24687 \begin_inset space ~
24688 \end_inset
24689
24690 columns if you want to, but that might not be very pleasant for the readers
24691  of your document.
24692 \end_layout
24693
24694 \begin_layout Standard
24695 \begin_inset Newpage newpage
24696 \end_inset
24697
24698
24699 \end_layout
24700
24701 \begin_layout Subsection
24702 Columns inside Columns
24703 \end_layout
24704
24705 \begin_layout Standard
24706 You can also have columns inside columns:
24707 \end_layout
24708
24709 \begin_layout Standard
24710 \begin_inset Flex Multiple Columns
24711 status open
24712
24713 \begin_layout Plain Layout
24714
24715 \size footnotesize
24716 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
24717  at that time governor of one of the Australian colonies.
24718  Adair's mother had returned from Australia to undergo the operation for
24719  cataract, and she, her son Ronald, and her daughter Hilda were living together
24720  at 427 Park Lane.
24721 \end_layout
24722
24723 \begin_layout Plain Layout
24724 \begin_inset Flex Multiple Columns
24725 status open
24726
24727 \begin_layout Plain Layout
24728
24729 \size footnotesize
24730 The youth moved in the best society
24731 \begin_inset space ~
24732 \end_inset
24733
24734 – had, so far as was known, no enemies and no particular vices.
24735  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
24736  had been broken off by mutual consent some months before, and there was
24737  no sign that it had left any very profound feeling behind it.
24738  For the rest {sic} the man's life moved in a narrow and conventional circle,
24739  for his habits were quiet and his nature unemotional.
24740  Yet it was upon this easy-going young aristocrat that death came, in most
24741  strange and unexpected form, between the hours of ten and eleven-twenty
24742  on the night of March 30, 1894.
24743 \end_layout
24744
24745 \end_inset
24746
24747
24748 \end_layout
24749
24750 \begin_layout Plain Layout
24751
24752 \size footnotesize
24753 Ronald Adair was fond of cards
24754 \begin_inset space ~
24755 \end_inset
24756
24757 – playing continually, but never for such stakes as would hurt him.
24758  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
24759  It was shown that, after dinner on the day of his death, he had played
24760  a rubber of whist at the latter club.
24761  He had also played there in the afternoon.
24762
24763 \size default
24764  
24765 \size footnotesize
24766 The evidence of those who had played with him
24767 \begin_inset space ~
24768 \end_inset
24769
24770 – Mr.
24771  Murray, Sir John Hardy, and Colonel Moran
24772 \begin_inset space ~
24773 \end_inset
24774
24775 – showed that the game was whist, and that there was a fairly equal fall
24776  of the cards.
24777  Adair might have lost five pounds, but not more.
24778  His fortune was a considerable one, and such a loss could not in any way
24779  affect him.
24780  He had played nearly every day at one club or other, but he was a cautious
24781  player, and usually rose a winner.
24782  It came out in evidence that, in partnership with Colonel Moran, he had
24783  actually won as much as four hundred and twenty pounds in a sitting, some
24784  weeks before, from Godfrey Milner and Lord Balmoral.
24785  So much for his recent history as it came out at the inquest.
24786 \end_layout
24787
24788 \end_inset
24789
24790
24791 \end_layout
24792
24793 \begin_layout Subsection
24794 Advanced Examples
24795 \end_layout
24796
24797 \begin_layout Standard
24798 The examples in this section show some more special features of multiple
24799  columns.
24800 \end_layout
24801
24802 \begin_layout Standard
24803 For more features of multiple columns, have a look at the 
24804 \begin_inset CommandInset href
24805 LatexCommand href
24806 name "documentation"
24807 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
24808 literal "false"
24809
24810 \end_inset
24811
24812  of the \SpecialChar LaTeX
24813 -package 
24814 \begin_inset Flex Code
24815 status collapsed
24816
24817 \begin_layout Plain Layout
24818 multicol
24819 \end_layout
24820
24821 \end_inset
24822
24823 .
24824 \end_layout
24825
24826 \begin_layout Subsubsection
24827 Preface
24828 \end_layout
24829
24830 \begin_layout Standard
24831 To add a preface text for multiple columns, set the cursor into the multicolumn
24832  inset and use the menu 
24833 \family sans
24834 Insert\SpecialChar menuseparator
24835 Preface
24836 \family default
24837 .
24838  Write your preface text into that inset.
24839 \begin_inset Newline newline
24840 \end_inset
24841
24842 This is an example with some preface text:
24843 \end_layout
24844
24845 \begin_layout Standard
24846 \begin_inset VSpace bigskip
24847 \end_inset
24848
24849
24850 \end_layout
24851
24852 \begin_layout Standard
24853 \begin_inset Flex Multiple Columns
24854 status open
24855
24856 \begin_layout Plain Layout
24857 \begin_inset Argument 2
24858 status open
24859
24860 \begin_layout Plain Layout
24861 And the story continues and continues and continues and continues\SpecialChar ldots
24862
24863 \end_layout
24864
24865 \end_inset
24866
24867
24868 \size small
24869 On the evening of the crime, he returned from the club exactly at ten.
24870  His mother and sister were out spending the evening with a relation.
24871  The servant deposed that she heard him enter the front room on the second
24872  floor, generally used as his sitting-room.
24873  She had lit a fire there, and as it smoked she had opened the window.
24874  No sound was heard from the room until eleven-twenty, the hour of the return
24875  of Lady Maynooth and her daughter.
24876  Desiring to say good-night, she attempted to enter her son's room.
24877  The door was locked on the inside, and no answer could be got to their
24878  cries and knocking.
24879  Help was obtained, and the door forced.
24880  The unfortunate young man was found lying near the table.
24881  His head had been horribly mutilated by an expanding revolver bullet, but
24882  no weapon of any sort was to be found in the room.
24883 \end_layout
24884
24885 \end_inset
24886
24887
24888 \end_layout
24889
24890 \begin_layout Standard
24891 You can also use a section heading as the preface if you use a section command
24892  as \SpecialChar TeX
24893  Code.
24894  For example the command
24895 \end_layout
24896
24897 \begin_layout LyX-Code
24898
24899 \backslash
24900 subsection{subsection title}
24901 \end_layout
24902
24903 \begin_layout Standard
24904 creates a subsection.
24905  In this example the preface is a subsubsection:
24906 \end_layout
24907
24908 \begin_layout Standard
24909 \begin_inset Flex Multiple Columns
24910 status open
24911
24912 \begin_layout Plain Layout
24913 \begin_inset Argument 2
24914 status open
24915
24916 \begin_layout Plain Layout
24917 \begin_inset ERT
24918 status collapsed
24919
24920 \begin_layout Plain Layout
24921
24922
24923 \backslash
24924 subsubsection{
24925 \end_layout
24926
24927 \end_inset
24928
24929 This is a subsubsection heading as a preface
24930 \begin_inset ERT
24931 status collapsed
24932
24933 \begin_layout Plain Layout
24934
24935 }
24936 \end_layout
24937
24938 \end_inset
24939
24940
24941 \end_layout
24942
24943 \end_inset
24944
24945
24946 \size small
24947 A minute examination of the circumstances served only to make the case more
24948  complex.
24949  In the first place, no reason could be given why the young man should have
24950  fastened the door upon the inside.
24951  There was the possibility that the murderer had done this, and had afterwards
24952  escaped by the window.
24953  The drop was at least twenty feet, however, and a bed of crocuses in full
24954  bloom lay beneath.
24955  Neither the flowers nor the earth showed any sign of having been disturbed,
24956  nor were there any marks upon the narrow strip of grass which separated
24957  the house from the road.
24958  Apparently, therefore, it was the young man himself who had fastened the
24959  door.
24960  But how did he come by his death? No one could have climbed up to the window
24961  without leaving traces.
24962  Suppose a man had fired through the window, he would indeed be a remarkable
24963  shot who could with a revolver inflict so deadly a wound.
24964  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
24965  a hundred yards of the house.
24966  No one had heard a shot.
24967 \end_layout
24968
24969 \end_inset
24970
24971
24972 \end_layout
24973
24974 \begin_layout Standard
24975 If there is less vertical space than 6
24976 \begin_inset space ~
24977 \end_inset
24978
24979 text lines is left on the page at the beginning of the multiple columns,
24980  a page break will be inserted before the multiple columns.
24981  Depending on the number of lines of the preface text, you might want to
24982  change this space.
24983  This is done by setting the cursor into the mulitcolumn inset behind the
24984  preface (if there is any) and using the menu 
24985 \family sans
24986 Insert\SpecialChar menuseparator
24987 Space
24988 \begin_inset space ~
24989 \end_inset
24990
24991 Before
24992 \begin_inset space ~
24993 \end_inset
24994
24995 Page
24996 \begin_inset space ~
24997 \end_inset
24998
24999 Break
25000 \family default
25001 .
25002  Insert into that inset the amount of space like e.
25003 \begin_inset space \thinspace{}
25004 \end_inset
25005
25006 g.
25007 \begin_inset space \space{}
25008 \end_inset
25009
25010
25011 \begin_inset Quotes eld
25012 \end_inset
25013
25014 5cm
25015 \begin_inset Quotes erd
25016 \end_inset
25017
25018 .
25019 \begin_inset Newline newline
25020 \end_inset
25021
25022 In this example the space is set to 7
25023 \begin_inset space ~
25024 \end_inset
25025
25026 text lines by using 
25027 \begin_inset Flex Code
25028 status collapsed
25029
25030 \begin_layout Plain Layout
25031 7
25032 \backslash
25033 baselineskip
25034 \end_layout
25035
25036 \end_inset
25037
25038  (where the command 
25039 \begin_inset Flex Code
25040 status collapsed
25041
25042 \begin_layout Plain Layout
25043
25044 \backslash
25045 baselineskip
25046 \end_layout
25047
25048 \end_inset
25049
25050  needs to be inserted as \SpecialChar TeX
25051  code):
25052 \end_layout
25053
25054 \begin_layout Standard
25055 \begin_inset Flex Multiple Columns
25056 status open
25057
25058 \begin_layout Plain Layout
25059 \begin_inset Argument 3
25060 status open
25061
25062 \begin_layout Plain Layout
25063 7
25064 \begin_inset ERT
25065 status collapsed
25066
25067 \begin_layout Plain Layout
25068
25069
25070 \backslash
25071 baselineskip
25072 \end_layout
25073
25074 \end_inset
25075
25076
25077 \end_layout
25078
25079 \end_inset
25080
25081
25082 \size small
25083 On the evening of the crime, he returned from the club exactly at ten.
25084  His mother and sister were out spending the evening with a relation.
25085  The servant deposed that she heard him enter the front room on the second
25086  floor, generally used as his sitting-room.
25087  She had lit a fire there, and as it smoked she had opened the window.
25088  No sound was heard from the room until eleven-twenty, the hour of the return
25089  of Lady Maynooth and her daughter.
25090  Desiring to say good-night, she attempted to enter her son's room.
25091  The door was locked on the inside, and no answer could be got to their
25092  cries and knocking.
25093  Help was obtained, and the door forced.
25094  The unfortunate young man was found lying near the table.
25095  His head had been horribly mutilated by an expanding revolver bullet, but
25096  no weapon of any sort was to be found in the room.
25097 \end_layout
25098
25099 \end_inset
25100
25101
25102 \end_layout
25103
25104 \begin_layout Subsubsection
25105 Surrounding Space
25106 \end_layout
25107
25108 \begin_layout Standard
25109 The amount of space before and after multiple columns can be changed by
25110  changing the length 
25111 \begin_inset Flex Code
25112 status collapsed
25113
25114 \begin_layout Plain Layout
25115
25116 \backslash
25117 multicolsep
25118 \end_layout
25119
25120 \end_inset
25121
25122 .
25123  For example the command
25124 \end_layout
25125
25126 \begin_layout LyX-Code
25127
25128 \backslash
25129 setlength{
25130 \backslash
25131 multicolsep}{3cm}
25132 \end_layout
25133
25134 \begin_layout Standard
25135 in \SpecialChar TeX
25136  Code changes its value to 3
25137 \begin_inset space \thinspace{}
25138 \end_inset
25139
25140 cm.
25141  The change must be made before the multiple columns' start.
25142  The predefined value is 13
25143 \begin_inset space \thinspace{}
25144 \end_inset
25145
25146 pt.
25147 \end_layout
25148
25149 \begin_layout Standard
25150 For this example 
25151 \begin_inset Flex Code
25152 status collapsed
25153
25154 \begin_layout Plain Layout
25155
25156 \backslash
25157 multicolsep
25158 \end_layout
25159
25160 \end_inset
25161
25162  was set to 2.5
25163 \begin_inset space \thinspace{}
25164 \end_inset
25165
25166 cm:
25167 \end_layout
25168
25169 \begin_layout Standard
25170 \begin_inset ERT
25171 status open
25172
25173 \begin_layout Plain Layout
25174
25175
25176 \backslash
25177 setlength{
25178 \backslash
25179 multicolsep}{2.5cm}
25180 \end_layout
25181
25182 \end_inset
25183
25184
25185 \end_layout
25186
25187 \begin_layout Standard
25188 \begin_inset Flex Multiple Columns
25189 status open
25190
25191 \begin_layout Plain Layout
25192
25193 \size small
25194 All day I turned these facts over in my mind, endeavouring to hit upon some
25195  theory which could reconcile them all, and to find that line of least resistanc
25196 e which my poor friend had declared to be the starting-point of every investigat
25197 ion.
25198  I confess that I made little progress.
25199  In the evening I strolled across the Park, and found myself about six o'clock
25200  at the Oxford Street end of Park Lane.
25201  A group of loafers upon the pavements, all staring up at a particular window,
25202  directed me to the house which I had come to see.
25203  A tall, thin man with coloured glasses, whom I strongly suspected of being
25204  a plain-clothes detective, was pointing out some theory of his own, while
25205  the others crowded round to listen to what he said.
25206  I got as near him as I could, but his observations seemed to me to be absurd,
25207  so I withdrew again in some disgust.
25208  As I did so I struck against an elderly, deformed man, who had been behind
25209  me, and I knocked down several books which he was carrying.
25210 \end_layout
25211
25212 \end_inset
25213
25214
25215 \end_layout
25216
25217 \begin_layout Standard
25218 \begin_inset Note Greyedout
25219 status open
25220
25221 \begin_layout Plain Layout
25222
25223 \series bold
25224 Note:
25225 \series default
25226  The values you set with 
25227 \begin_inset Flex Code
25228 status collapsed
25229
25230 \begin_layout Plain Layout
25231
25232 \backslash
25233 setlength
25234 \end_layout
25235
25236 \end_inset
25237
25238  will be used for all following multiple columns until you change them again.
25239 \end_layout
25240
25241 \end_inset
25242
25243
25244 \end_layout
25245
25246 \begin_layout Standard
25247 \begin_inset ERT
25248 status collapsed
25249
25250 \begin_layout Plain Layout
25251
25252
25253 \backslash
25254 setlength{
25255 \backslash
25256 multicolsep}{13pt}
25257 \end_layout
25258
25259 \end_inset
25260
25261
25262 \begin_inset Note Note
25263 status collapsed
25264
25265 \begin_layout Plain Layout
25266 go back to the default
25267 \end_layout
25268
25269 \end_inset
25270
25271
25272 \end_layout
25273
25274 \begin_layout Standard
25275 \begin_inset Newpage newpage
25276 \end_inset
25277
25278
25279 \end_layout
25280
25281 \begin_layout Subsubsection
25282 Column Breaks
25283 \end_layout
25284
25285 \begin_layout Standard
25286 A column break can be forced by inserting the command 
25287 \begin_inset Flex Code
25288 status collapsed
25289
25290 \begin_layout Plain Layout
25291
25292 \backslash
25293 columnbreak{}
25294 \end_layout
25295
25296 \end_inset
25297
25298  as \SpecialChar TeX
25299  Code to that position in the text where the column should be broken.
25300  Note that this leads in most cases to whitespace in the text.
25301 \begin_inset Newline newline
25302 \end_inset
25303
25304 Here is an example:
25305 \end_layout
25306
25307 \begin_layout Standard
25308 \begin_inset Flex Multiple Columns
25309 status open
25310
25311 \begin_layout Plain Layout
25312
25313 \size small
25314 \begin_inset Quotes eld
25315 \end_inset
25316
25317 You're surprised to see me, sir,
25318 \begin_inset Quotes erd
25319 \end_inset
25320
25321  said he, in a strange, croaking voice.
25322 \end_layout
25323
25324 \begin_layout Plain Layout
25325
25326 \size small
25327 I acknowledged that I was.
25328 \end_layout
25329
25330 \begin_layout Plain Layout
25331
25332 \size small
25333 \begin_inset Quotes eld
25334 \end_inset
25335
25336 Well, I've a conscience, sir, and when I chanced to see you go into this
25337  house, as I came hobbling after you, I thought to myself, I'll just step
25338  in and see that kind gentleman, and tell him that if I was a bit gruff
25339  in my manner there was not any harm meant, and that I am much obliged to
25340  him for picking up my books.
25341 \begin_inset Quotes erd
25342 \end_inset
25343
25344
25345 \end_layout
25346
25347 \begin_layout Plain Layout
25348
25349 \size small
25350 \begin_inset Quotes eld
25351 \end_inset
25352
25353 You make too much of a trifle,
25354 \begin_inset Quotes erd
25355 \end_inset
25356
25357  said I.
25358  
25359 \begin_inset Quotes eld
25360 \end_inset
25361
25362 May I ask how you knew who I was?
25363 \begin_inset Quotes erd
25364 \end_inset
25365
25366  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
25367 \begin_inset ERT
25368 status collapsed
25369
25370 \begin_layout Plain Layout
25371
25372
25373 \backslash
25374 columnbreak{}
25375 \end_layout
25376
25377 \end_inset
25378
25379
25380 \end_layout
25381
25382 \begin_layout Plain Layout
25383
25384 \size small
25385 \begin_inset Quotes eld
25386 \end_inset
25387
25388 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25389  you'll find my little bookshop at the corner of Church Street, and very
25390  happy to see you, I am sure.
25391  Maybe you collect yourself, sir.
25392  Here's 
25393 \noun on
25394 British
25395 \begin_inset space ~
25396 \end_inset
25397
25398 Birds
25399 \noun default
25400 , and 
25401 \noun on
25402 Catullus
25403 \noun default
25404 , and 
25405 \noun on
25406 The Holy War
25407 \noun default
25408
25409 \begin_inset space ~
25410 \end_inset
25411
25412 – a bargain, every one of them.
25413  With five volumes you could just fill that gap on that second shelf.
25414  It looks untidy, does it not, sir?
25415 \begin_inset Quotes erd
25416 \end_inset
25417
25418
25419 \end_layout
25420
25421 \end_inset
25422
25423
25424 \end_layout
25425
25426 \begin_layout Subsubsection
25427 Column Separation
25428 \end_layout
25429
25430 \begin_layout Standard
25431 The width of the columns is automatically calculated, but you can modify
25432  the space between the columns.
25433  This is done by changing the length 
25434 \begin_inset Flex Code
25435 status collapsed
25436
25437 \begin_layout Plain Layout
25438
25439 \backslash
25440 columnsep
25441 \end_layout
25442
25443 \end_inset
25444
25445 .
25446  Its predefined value is 10
25447 \begin_inset space \thinspace{}
25448 \end_inset
25449
25450 pt.
25451  Here is an example where 
25452 \begin_inset Flex Code
25453 status collapsed
25454
25455 \begin_layout Plain Layout
25456
25457 \backslash
25458 columnsep
25459 \end_layout
25460
25461 \end_inset
25462
25463  is set to 3
25464 \begin_inset space \thinspace{}
25465 \end_inset
25466
25467 cm:
25468 \end_layout
25469
25470 \begin_layout Standard
25471 \begin_inset ERT
25472 status open
25473
25474 \begin_layout Plain Layout
25475
25476
25477 \backslash
25478 setlength{
25479 \backslash
25480 columnsep}{3cm}
25481 \end_layout
25482
25483 \end_inset
25484
25485
25486 \end_layout
25487
25488 \begin_layout Standard
25489 \begin_inset Flex Multiple Columns
25490 status open
25491
25492 \begin_layout Plain Layout
25493
25494 \size small
25495 My observations of No.
25496 \begin_inset space \space{}
25497 \end_inset
25498
25499 427 Park Lane did little to clear up the problem in which I was interested.
25500  The house was separated from the street by a low wall and railing, the
25501  whole not more than five feet high.
25502  It was perfectly easy, therefore, for anyone to get into the garden, but
25503  the window was entirely inaccessible, since there was no water pipe or
25504  anything which could help the most active man to climb it.
25505  More puzzled than ever, I retraced my steps to Kensington.
25506  I had not been in my study five minutes when the maid entered to say that
25507  a person desired to see me.
25508  To my astonishment it was none other than my strange old book collector,
25509  his sharp, wizened face peering out from a frame of white hair, and his
25510  precious volumes, a dozen of them at least, wedged under his right arm.
25511 \end_layout
25512
25513 \end_inset
25514
25515
25516 \end_layout
25517
25518 \begin_layout Standard
25519 \begin_inset ERT
25520 status collapsed
25521
25522 \begin_layout Plain Layout
25523
25524
25525 \backslash
25526 setlength{
25527 \backslash
25528 columnsep}{10pt}
25529 \end_layout
25530
25531 \end_inset
25532
25533
25534 \begin_inset Note Note
25535 status collapsed
25536
25537 \begin_layout Plain Layout
25538 go back to the default
25539 \end_layout
25540
25541 \end_inset
25542
25543
25544 \end_layout
25545
25546 \begin_layout Subsubsection
25547 Vertical Lines
25548 \end_layout
25549
25550 \begin_layout Standard
25551 Between the columns a rule with a width of the length 
25552 \begin_inset Flex Code
25553 status collapsed
25554
25555 \begin_layout Plain Layout
25556
25557 \backslash
25558 columnseprule
25559 \end_layout
25560
25561 \end_inset
25562
25563  is placed.
25564  If this rule width is set to 0
25565 \begin_inset space \thinspace{}
25566 \end_inset
25567
25568 pt (this is the default), the rule is suppressed.
25569  In the following example the rule is 2
25570 \begin_inset space \thinspace{}
25571 \end_inset
25572
25573 pt wide:
25574 \end_layout
25575
25576 \begin_layout Standard
25577 \begin_inset ERT
25578 status open
25579
25580 \begin_layout Plain Layout
25581
25582
25583 \backslash
25584 setlength{
25585 \backslash
25586 columnseprule}{2pt}
25587 \end_layout
25588
25589 \end_inset
25590
25591
25592 \end_layout
25593
25594 \begin_layout Standard
25595 \begin_inset Flex Multiple Columns
25596 status open
25597
25598 \begin_layout Plain Layout
25599
25600 \size small
25601 \begin_inset Quotes eld
25602 \end_inset
25603
25604 You're surprised to see me, sir,
25605 \begin_inset Quotes erd
25606 \end_inset
25607
25608  said he, in a strange, croaking voice.
25609 \end_layout
25610
25611 \begin_layout Plain Layout
25612
25613 \size small
25614 I acknowledged that I was.
25615 \end_layout
25616
25617 \begin_layout Plain Layout
25618
25619 \size small
25620 \begin_inset Quotes eld
25621 \end_inset
25622
25623 Well, I've a conscience, sir, and when I chanced to see you go into this
25624  house, as I came hobbling after you, I thought to myself, I'll just step
25625  in and see that kind gentleman, and tell him that if I was a bit gruff
25626  in my manner there was not any harm meant, and that I am much obliged to
25627  him for picking up my books.
25628 \begin_inset Quotes erd
25629 \end_inset
25630
25631
25632 \end_layout
25633
25634 \begin_layout Plain Layout
25635
25636 \size small
25637 \begin_inset Quotes eld
25638 \end_inset
25639
25640 You make too much of a trifle,
25641 \begin_inset Quotes erd
25642 \end_inset
25643
25644  said I.
25645  
25646 \begin_inset Quotes eld
25647 \end_inset
25648
25649 May I ask how you knew who I was?
25650 \begin_inset Quotes erd
25651 \end_inset
25652
25653
25654 \end_layout
25655
25656 \begin_layout Plain Layout
25657
25658 \size small
25659 \begin_inset Quotes eld
25660 \end_inset
25661
25662 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25663  you'll find my little bookshop at the corner of Church Street, and very
25664  happy to see you, I am sure.
25665  Maybe you collect yourself, sir.
25666  Here's 
25667 \noun on
25668 British
25669 \begin_inset space ~
25670 \end_inset
25671
25672 Birds
25673 \noun default
25674 , and 
25675 \noun on
25676 Catullus
25677 \noun default
25678 , and 
25679 \noun on
25680 The Holy War
25681 \noun default
25682
25683 \begin_inset space ~
25684 \end_inset
25685
25686 – a bargain, every one of them.
25687  With five volumes you could just fill that gap on that second shelf.
25688  It looks untidy, does it not, sir?
25689 \begin_inset Quotes erd
25690 \end_inset
25691
25692
25693 \end_layout
25694
25695 \end_inset
25696
25697
25698 \end_layout
25699
25700 \begin_layout Standard
25701 \begin_inset VSpace defskip
25702 \end_inset
25703
25704
25705 \end_layout
25706
25707 \begin_layout Standard
25708 The rule can be colored by redefining the command 
25709 \begin_inset Flex Code
25710 status collapsed
25711
25712 \begin_layout Plain Layout
25713
25714 \backslash
25715 columnseprulecolor
25716 \end_layout
25717
25718 \end_inset
25719
25720 .
25721  This is done by inserting the command
25722 \end_layout
25723
25724 \begin_layout LyX-Code
25725
25726 \backslash
25727 renewcommand{
25728 \backslash
25729 columnseprulecolor}{
25730 \backslash
25731 color{red}}
25732 \end_layout
25733
25734 \begin_layout Standard
25735 as \SpecialChar TeX
25736  Code before the multicolumn inset.
25737  Replace 
25738 \begin_inset Flex Code
25739 status collapsed
25740
25741 \begin_layout Plain Layout
25742 red
25743 \end_layout
25744
25745 \end_inset
25746
25747  in this command by a color of your choice.
25748  You can use all pre- and self-defined colors.
25749  See the 
25750 \emph on
25751 EmbeddedObjects
25752 \emph default
25753  manual, section 
25754 \emph on
25755 Colored
25756 \begin_inset space ~
25757 \end_inset
25758
25759 Tables
25760 \emph default
25761  for more information about pre- and self-defined colors.
25762  To go back to the default color insert the command
25763 \end_layout
25764
25765 \begin_layout LyX-Code
25766
25767 \backslash
25768 renewcommand{
25769 \backslash
25770 columnseprulecolor}{
25771 \backslash
25772 normalcolor}
25773 \end_layout
25774
25775 \begin_layout Standard
25776 Here is the example with a cyan rule and 1
25777 \begin_inset space \thinspace{}
25778 \end_inset
25779
25780 cm column separation:
25781 \end_layout
25782
25783 \begin_layout Standard
25784 \begin_inset ERT
25785 status open
25786
25787 \begin_layout Plain Layout
25788
25789
25790 \backslash
25791 setlength{
25792 \backslash
25793 columnsep}{1cm}
25794 \end_layout
25795
25796 \begin_layout Plain Layout
25797
25798
25799 \backslash
25800 renewcommand{
25801 \backslash
25802 columnseprulecolor}{
25803 \backslash
25804 color{cyan}}
25805 \end_layout
25806
25807 \end_inset
25808
25809
25810 \end_layout
25811
25812 \begin_layout Standard
25813 \begin_inset Flex Multiple Columns
25814 status open
25815
25816 \begin_layout Plain Layout
25817
25818 \size small
25819 \begin_inset Quotes eld
25820 \end_inset
25821
25822 You're surprised to see me, sir,
25823 \begin_inset Quotes erd
25824 \end_inset
25825
25826  said he, in a strange, croaking voice.
25827 \end_layout
25828
25829 \begin_layout Plain Layout
25830
25831 \size small
25832 I acknowledged that I was.
25833 \end_layout
25834
25835 \begin_layout Plain Layout
25836
25837 \size small
25838 \begin_inset Quotes eld
25839 \end_inset
25840
25841 Well, I've a conscience, sir, and when I chanced to see you go into this
25842  house, as I came hobbling after you, I thought to myself, I'll just step
25843  in and see that kind gentleman, and tell him that if I was a bit gruff
25844  in my manner there was not any harm meant, and that I am much obliged to
25845  him for picking up my books.
25846 \begin_inset Quotes erd
25847 \end_inset
25848
25849
25850 \end_layout
25851
25852 \begin_layout Plain Layout
25853
25854 \size small
25855 \begin_inset Quotes eld
25856 \end_inset
25857
25858 You make too much of a trifle,
25859 \begin_inset Quotes erd
25860 \end_inset
25861
25862  said I.
25863  
25864 \begin_inset Quotes eld
25865 \end_inset
25866
25867 May I ask how you knew who I was?
25868 \begin_inset Quotes erd
25869 \end_inset
25870
25871
25872 \end_layout
25873
25874 \begin_layout Plain Layout
25875
25876 \size small
25877 \begin_inset Quotes eld
25878 \end_inset
25879
25880 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25881  you'll find my little bookshop at the corner of Church Street, and very
25882  happy to see you, I am sure.
25883  Maybe you collect yourself, sir.
25884  Here's 
25885 \noun on
25886 British
25887 \begin_inset space ~
25888 \end_inset
25889
25890 Birds
25891 \noun default
25892 , and 
25893 \noun on
25894 Catullus
25895 \noun default
25896 , and 
25897 \noun on
25898 The Holy War
25899 \noun default
25900
25901 \begin_inset space ~
25902 \end_inset
25903
25904 – a bargain, every one of them.
25905  With five volumes you could just fill that gap on that second shelf.
25906  It looks untidy, does it not, sir?
25907 \begin_inset Quotes erd
25908 \end_inset
25909
25910
25911 \end_layout
25912
25913 \end_inset
25914
25915
25916 \end_layout
25917
25918 \begin_layout Standard
25919 \begin_inset ERT
25920 status collapsed
25921
25922 \begin_layout Plain Layout
25923
25924
25925 \backslash
25926 setlength{
25927 \backslash
25928 columnseprule}{0pt}
25929 \end_layout
25930
25931 \begin_layout Plain Layout
25932
25933
25934 \backslash
25935 renewcommand{
25936 \backslash
25937 columnseprulecolor}{
25938 \backslash
25939 normalcolor}
25940 \end_layout
25941
25942 \end_inset
25943
25944
25945 \begin_inset Note Note
25946 status collapsed
25947
25948 \begin_layout Plain Layout
25949 go back to the default
25950 \end_layout
25951
25952 \end_inset
25953
25954
25955 \end_layout
25956
25957 \begin_layout Section
25958 Non-standard Paragraph Shapes
25959 \end_layout
25960
25961 \begin_layout Standard
25962 \noindent
25963 \SpecialChar LaTeX
25964  as well as any other text processor uses by default rectangular paragraphs.
25965  For special cases like for example posters, invitation cards or poems you
25966  can modify the paragraph shape to one of your choice.
25967  This can be done by using the \SpecialChar LaTeX
25968 -package 
25969 \begin_inset Flex Code
25970 status collapsed
25971
25972 \begin_layout Plain Layout
25973 shapepar
25974 \end_layout
25975
25976 \end_inset
25977
25978  which is loaded by using in the document settings the module 
25979 \family sans
25980 Custom paragraph shapes
25981 \family default
25982 .
25983 \end_layout
25984
25985 \begin_layout Subsection
25986 Predefined shapes
25987 \end_layout
25988
25989 \begin_layout Standard
25990
25991 \series bold
25992 shapepar
25993 \series default
25994  provides the following shapes:
25995 \end_layout
25996
25997 \begin_layout Standard
25998 \begin_inset Tabular
25999 <lyxtabular version="3" rows="13" columns="3">
26000 <features booktabs="true" islongtable="true" longtabularalignment="center">
26001 <column alignment="left" valignment="middle" width="16col%">
26002 <column alignment="left" valignment="middle" width="40col%">
26003 <column alignment="left" valignment="middle" width="35col%">
26004 <row endhead="true">
26005 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26006 \begin_inset Text
26007
26008 \begin_layout Plain Layout
26009
26010 \series bold
26011 \size small
26012 Name
26013 \end_layout
26014
26015 \end_inset
26016 </cell>
26017 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26018 \begin_inset Text
26019
26020 \begin_layout Plain Layout
26021
26022 \series bold
26023 \size small
26024 Description
26025 \end_layout
26026
26027 \end_inset
26028 </cell>
26029 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26030 \begin_inset Text
26031
26032 \begin_layout Plain Layout
26033
26034 \series bold
26035 \size small
26036 Annotation
26037 \end_layout
26038
26039 \end_inset
26040 </cell>
26041 </row>
26042 <row interlinespace="default">
26043 <cell alignment="left" valignment="top" usebox="none">
26044 \begin_inset Text
26045
26046 \begin_layout Plain Layout
26047
26048 \size small
26049 CDlabel
26050 \end_layout
26051
26052 \end_inset
26053 </cell>
26054 <cell alignment="left" valignment="top" usebox="none">
26055 \begin_inset Text
26056
26057 \begin_layout Plain Layout
26058
26059 \size small
26060 Circle with circular hole (in the size of a CD/DVD)
26061 \end_layout
26062
26063 \end_inset
26064 </cell>
26065 <cell alignment="left" valignment="top" usebox="none">
26066 \begin_inset Text
26067
26068 \begin_layout Plain Layout
26069
26070 \size small
26071 Cannot be scaled, take care there is not too much text
26072 \end_layout
26073
26074 \end_inset
26075 </cell>
26076 </row>
26077 <row interlinespace="default">
26078 <cell alignment="left" valignment="top" usebox="none">
26079 \begin_inset Text
26080
26081 \begin_layout Plain Layout
26082
26083 \size small
26084 Circle
26085 \end_layout
26086
26087 \end_inset
26088 </cell>
26089 <cell alignment="left" valignment="top" usebox="none">
26090 \begin_inset Text
26091
26092 \begin_layout Plain Layout
26093
26094 \size small
26095 Circle
26096 \end_layout
26097
26098 \end_inset
26099 </cell>
26100 <cell alignment="left" valignment="top" usebox="none">
26101 \begin_inset Text
26102
26103 \begin_layout Plain Layout
26104
26105 \size small
26106 Fragile, calculation might fail
26107 \end_layout
26108
26109 \end_inset
26110 </cell>
26111 </row>
26112 <row interlinespace="default">
26113 <cell alignment="left" valignment="top" usebox="none">
26114 \begin_inset Text
26115
26116 \begin_layout Plain Layout
26117
26118 \size small
26119 Diamond
26120 \end_layout
26121
26122 \end_inset
26123 </cell>
26124 <cell alignment="left" valignment="top" usebox="none">
26125 \begin_inset Text
26126
26127 \begin_layout Plain Layout
26128
26129 \size small
26130 Rhomboid (symbolizing a 
26131 \begin_inset Quotes eld
26132 \end_inset
26133
26134 diamond
26135 \begin_inset Quotes erd
26136 \end_inset
26137
26138 )
26139 \end_layout
26140
26141 \end_inset
26142 </cell>
26143 <cell alignment="left" valignment="top" usebox="none">
26144 \begin_inset Text
26145
26146 \begin_layout Plain Layout
26147
26148 \size small
26149 -
26150 \end_layout
26151
26152 \end_inset
26153 </cell>
26154 </row>
26155 <row interlinespace="default">
26156 <cell alignment="left" valignment="top" usebox="none">
26157 \begin_inset Text
26158
26159 \begin_layout Plain Layout
26160
26161 \size small
26162 Heart
26163 \end_layout
26164
26165 \end_inset
26166 </cell>
26167 <cell alignment="left" valignment="top" usebox="none">
26168 \begin_inset Text
26169
26170 \begin_layout Plain Layout
26171
26172 \size small
26173 Heart-like shape
26174 \end_layout
26175
26176 \end_inset
26177 </cell>
26178 <cell alignment="left" valignment="top" usebox="none">
26179 \begin_inset Text
26180
26181 \begin_layout Plain Layout
26182
26183 \size small
26184 -
26185 \end_layout
26186
26187 \end_inset
26188 </cell>
26189 </row>
26190 <row interlinespace="default">
26191 <cell alignment="left" valignment="top" usebox="none">
26192 \begin_inset Text
26193
26194 \begin_layout Plain Layout
26195
26196 \size small
26197 Hexagon
26198 \end_layout
26199
26200 \end_inset
26201 </cell>
26202 <cell alignment="left" valignment="top" usebox="none">
26203 \begin_inset Text
26204
26205 \begin_layout Plain Layout
26206
26207 \size small
26208 Hexagon
26209 \end_layout
26210
26211 \end_inset
26212 </cell>
26213 <cell alignment="left" valignment="top" usebox="none">
26214 \begin_inset Text
26215
26216 \begin_layout Plain Layout
26217
26218 \size small
26219 -
26220 \end_layout
26221
26222 \end_inset
26223 </cell>
26224 </row>
26225 <row interlinespace="default">
26226 <cell alignment="left" valignment="top" usebox="none">
26227 \begin_inset Text
26228
26229 \begin_layout Plain Layout
26230
26231 \size small
26232 Nut
26233 \end_layout
26234
26235 \end_inset
26236 </cell>
26237 <cell alignment="left" valignment="top" usebox="none">
26238 \begin_inset Text
26239
26240 \begin_layout Plain Layout
26241
26242 \size small
26243 Nut for bolt (hexagon with circular hole)
26244 \end_layout
26245
26246 \end_inset
26247 </cell>
26248 <cell alignment="left" valignment="top" usebox="none">
26249 \begin_inset Text
26250
26251 \begin_layout Plain Layout
26252
26253 \size small
26254 -
26255 \end_layout
26256
26257 \end_inset
26258 </cell>
26259 </row>
26260 <row interlinespace="default">
26261 <cell alignment="left" valignment="top" usebox="none">
26262 \begin_inset Text
26263
26264 \begin_layout Plain Layout
26265
26266 \size small
26267 Square
26268 \end_layout
26269
26270 \end_inset
26271 </cell>
26272 <cell alignment="left" valignment="top" usebox="none">
26273 \begin_inset Text
26274
26275 \begin_layout Plain Layout
26276
26277 \size small
26278 Square
26279 \end_layout
26280
26281 \end_inset
26282 </cell>
26283 <cell alignment="left" valignment="top" usebox="none">
26284 \begin_inset Text
26285
26286 \begin_layout Plain Layout
26287
26288 \size small
26289 -
26290 \end_layout
26291
26292 \end_inset
26293 </cell>
26294 </row>
26295 <row interlinespace="default">
26296 <cell alignment="left" valignment="top" usebox="none">
26297 \begin_inset Text
26298
26299 \begin_layout Plain Layout
26300
26301 \size small
26302 Star
26303 \end_layout
26304
26305 \end_inset
26306 </cell>
26307 <cell alignment="left" valignment="top" usebox="none">
26308 \begin_inset Text
26309
26310 \begin_layout Plain Layout
26311
26312 \size small
26313 Five-point star
26314 \end_layout
26315
26316 \end_inset
26317 </cell>
26318 <cell alignment="left" valignment="top" usebox="none">
26319 \begin_inset Text
26320
26321 \begin_layout Plain Layout
26322
26323 \size small
26324 -
26325 \end_layout
26326
26327 \end_inset
26328 </cell>
26329 </row>
26330 <row interlinespace="default">
26331 <cell alignment="left" valignment="top" usebox="none">
26332 \begin_inset Text
26333
26334 \begin_layout Plain Layout
26335
26336 \size small
26337 Candle
26338 \end_layout
26339
26340 \end_inset
26341 </cell>
26342 <cell alignment="left" valignment="top" usebox="none">
26343 \begin_inset Text
26344
26345 \begin_layout Plain Layout
26346
26347 \size small
26348 Burning candle
26349 \end_layout
26350
26351 \end_inset
26352 </cell>
26353 <cell alignment="left" valignment="top" usebox="none">
26354 \begin_inset Text
26355
26356 \begin_layout Plain Layout
26357
26358 \size small
26359 -
26360 \end_layout
26361
26362 \end_inset
26363 </cell>
26364 </row>
26365 <row interlinespace="default">
26366 <cell alignment="left" valignment="top" usebox="none">
26367 \begin_inset Text
26368
26369 \begin_layout Plain Layout
26370
26371 \size small
26372 Drop down/up
26373 \end_layout
26374
26375 \end_inset
26376 </cell>
26377 <cell alignment="left" valignment="top" usebox="none">
26378 \begin_inset Text
26379
26380 \begin_layout Plain Layout
26381
26382 \size small
26383 Normal/reversed rain drop
26384 \end_layout
26385
26386 \end_inset
26387 </cell>
26388 <cell alignment="left" valignment="top" usebox="none">
26389 \begin_inset Text
26390
26391 \begin_layout Plain Layout
26392
26393 \size small
26394 Fragile, calculation might fail
26395 \end_layout
26396
26397 \end_inset
26398 </cell>
26399 </row>
26400 <row interlinespace="default">
26401 <cell alignment="left" valignment="top" usebox="none">
26402 \begin_inset Text
26403
26404 \begin_layout Plain Layout
26405
26406 \size small
26407 \SpecialChar TeX
26408
26409 \end_layout
26410
26411 \end_inset
26412 </cell>
26413 <cell alignment="left" valignment="top" usebox="none">
26414 \begin_inset Text
26415
26416 \begin_layout Plain Layout
26417
26418 \size small
26419 The \SpecialChar TeX
26420  logo
26421 \end_layout
26422
26423 \end_inset
26424 </cell>
26425 <cell alignment="left" valignment="top" usebox="none">
26426 \begin_inset Text
26427
26428 \begin_layout Plain Layout
26429
26430 \size small
26431 -
26432 \end_layout
26433
26434 \end_inset
26435 </cell>
26436 </row>
26437 <row interlinespace="default">
26438 <cell alignment="left" valignment="top" bottomline="true" usebox="none">
26439 \begin_inset Text
26440
26441 \begin_layout Plain Layout
26442
26443 \size small
26444 Triangle up/down/
26445 \begin_inset Newline newline
26446 \end_inset
26447
26448 left/right
26449 \end_layout
26450
26451 \end_inset
26452 </cell>
26453 <cell alignment="left" valignment="top" bottomline="true" usebox="none">
26454 \begin_inset Text
26455
26456 \begin_layout Plain Layout
26457
26458 \size small
26459 Triangles in different orientations
26460 \end_layout
26461
26462 \end_inset
26463 </cell>
26464 <cell alignment="left" valignment="top" bottomline="true" usebox="none">
26465 \begin_inset Text
26466
26467 \begin_layout Plain Layout
26468
26469 \size small
26470 -
26471 \end_layout
26472
26473 \end_inset
26474 </cell>
26475 </row>
26476 </lyxtabular>
26477
26478 \end_inset
26479
26480
26481 \end_layout
26482
26483 \begin_layout Standard
26484 To use a shape for your paragraph, simply select it in \SpecialChar LyX
26485 's pull-down box
26486  for environments in the toolbar.
26487 \end_layout
26488
26489 \begin_layout Standard
26490 \begin_inset Newpage newpage
26491 \end_inset
26492
26493
26494 \end_layout
26495
26496 \begin_layout Standard
26497 Here is an example paragraph in the shape of a nut:
26498 \end_layout
26499
26500 \begin_layout Standard
26501 \begin_inset VSpace bigskip
26502 \end_inset
26503
26504
26505 \end_layout
26506
26507 \begin_layout Nut
26508
26509 \lang latin
26510 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26511  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26512  voluptua.
26513  At vero eos et accusam et justo duo dolores et ea rebum.
26514  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26515  sit amet.
26516  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26517  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26518  voluptua.
26519 \end_layout
26520
26521 \begin_layout Standard
26522 \begin_inset VSpace bigskip
26523 \end_inset
26524
26525
26526 \end_layout
26527
26528 \begin_layout Standard
26529 \begin_inset Note Greyedout
26530 status open
26531
26532 \begin_layout Plain Layout
26533
26534 \series bold
26535 Note
26536 \series default
26537
26538 \family sans
26539 shapepar
26540 \family default
26541  paragraphs cannot run over a page break.
26542 \end_layout
26543
26544 \end_inset
26545
26546
26547 \end_layout
26548
26549 \begin_layout Standard
26550 \begin_inset VSpace bigskip
26551 \end_inset
26552
26553
26554 \end_layout
26555
26556 \begin_layout Standard
26557 The package 
26558 \begin_inset Flex Code
26559 status collapsed
26560
26561 \begin_layout Plain Layout
26562 shapepar
26563 \end_layout
26564
26565 \end_inset
26566
26567  takes care that the shape will always be preserved, no matter how much
26568  text is in the paragraph.
26569  Therefore the paragraph size changes with the amount of contained text.
26570  This can lead to paragraph sizes exceeding the page margins.
26571  To demonstrate the size scaling, here is the same example paragraph but
26572  with twice as much text:
26573 \end_layout
26574
26575 \begin_layout Standard
26576 \begin_inset Newpage newpage
26577 \end_inset
26578
26579
26580 \end_layout
26581
26582 \begin_layout Nut
26583
26584 \lang latin
26585 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26586  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26587  voluptua.
26588  At vero eos et accusam et justo duo dolores et ea rebum.
26589  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26590  sit amet.
26591  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26592  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26593  voluptua.
26594  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26595  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26596  voluptua.
26597  At vero eos et accusam et justo duo dolores et ea rebum.
26598  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26599  sit amet.
26600  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26601  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26602  voluptua.
26603 \end_layout
26604
26605 \begin_layout Standard
26606 \begin_inset VSpace bigskip
26607 \end_inset
26608
26609
26610 \end_layout
26611
26612 \begin_layout Standard
26613 An exception is the shape 
26614 \family sans
26615 CDlabel
26616 \family default
26617 .
26618  It cannot be scaled because it must fit the size of a CD/DVD.
26619  Therefore the amount of text that fits into the shape is limited.
26620 \begin_inset Newline newline
26621 \end_inset
26622
26623 The 
26624 \family sans
26625 drop
26626 \family default
26627  shapes and the 
26628 \family sans
26629 circle
26630 \family default
26631  shape are fragile, meaning that the calculation of their size can fail,
26632  depending on the amount of text.
26633  You will then get the \SpecialChar LaTeX
26634  error 
26635 \begin_inset Quotes eld
26636 \end_inset
26637
26638 Arithmetic overflow
26639 \begin_inset Quotes erd
26640 \end_inset
26641
26642 .
26643  In this case one can try to remove or add some text; if nothing works one
26644  has to use another shape.
26645 \end_layout
26646
26647 \begin_layout Standard
26648 \begin_inset VSpace bigskip
26649 \end_inset
26650
26651
26652 \end_layout
26653
26654 \begin_layout Standard
26655 For shapes with tips you will maybe see that \SpecialChar LaTeX
26656 's hyphenation routine fails
26657  for text in the tips.
26658  Therefore it is often necessary to add hyphenation points 
26659 \family sans
26660 (
26661 \begin_inset Info
26662 type  "shortcut"
26663 arg   "specialchar-insert hyphenation"
26664 \end_inset
26665
26666
26667 \family default
26668 ) to the corresponding text parts.
26669 \end_layout
26670
26671 \begin_layout Standard
26672 \begin_inset VSpace bigskip
26673 \end_inset
26674
26675
26676 \end_layout
26677
26678 \begin_layout Standard
26679 Shapepar paragraphs are either always centered or placed on the page so
26680  that their left border touches the left page margin.
26681  You can therefore not use the paragraph dialog to align such paragraphs.
26682  A solution is to put the paragraph into a minipage or parbox and align
26683  the box.
26684  The problem is hereby to find the right width for the box.
26685  Because if it is too wide and you center the box, the paragraph is not
26686  centered too because it sticks at the left side of the box.
26687  So you might have to play a bit with the width until it fits.
26688  Here are two heart-shaped paragraphs, the first one is not aligned, the
26689  second one is right-aligned:
26690 \end_layout
26691
26692 \begin_layout Standard
26693 \begin_inset Newpage newpage
26694 \end_inset
26695
26696
26697 \end_layout
26698
26699 \begin_layout Heart
26700 \noindent
26701
26702 \lang latin
26703 Lo\SpecialChar softhyphen
26704 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26705  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26706  voluptua.
26707  At vero eos et accusam et justo duo dolores et ea rebum.
26708  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26709  sit amet.
26710 \end_layout
26711
26712 \begin_layout Standard
26713 \begin_inset VSpace bigskip
26714 \end_inset
26715
26716
26717 \end_layout
26718
26719 \begin_layout Standard
26720 \noindent
26721 \align right
26722 \begin_inset Box Frameless
26723 position "t"
26724 hor_pos "c"
26725 has_inner_box 1
26726 inner_pos "t"
26727 use_parbox 1
26728 use_makebox 0
26729 width "42col%"
26730 special "none"
26731 height "1in"
26732 height_special "totalheight"
26733 thickness "0.4pt"
26734 separation "3pt"
26735 shadowsize "4pt"
26736 framecolor "black"
26737 backgroundcolor "none"
26738 status open
26739
26740 \begin_layout Heart
26741 \noindent
26742
26743 \lang latin
26744 Lo\SpecialChar softhyphen
26745 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26746  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26747  voluptua.
26748  At vero eos et accusam et justo duo dolores et ea rebum.
26749  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26750  sit amet.
26751 \end_layout
26752
26753 \end_inset
26754
26755
26756 \end_layout
26757
26758 \begin_layout Subsection
26759 Custom shapes
26760 \end_layout
26761
26762 \begin_layout Standard
26763 You can define any shape you want.
26764  Doing this manually is a lot of work because every coordinate must be specified.
26765  But there is a way to let the computer calculate the coordinates:
26766 \end_layout
26767
26768 \begin_layout Enumerate
26769 Install the program 
26770 \begin_inset CommandInset href
26771 LatexCommand href
26772 name "Jpgfdraw"
26773 target "https://www.ctan.org/tex-archive/graphics/jpgfdraw"
26774 literal "false"
26775
26776 \end_inset
26777
26778 .
26779 \end_layout
26780
26781 \begin_layout Enumerate
26782 In 
26783 \family sans
26784 Jpgfdraw
26785 \family default
26786  go to the menu 
26787 \family sans
26788 TeX/LaTeX\SpecialChar menuseparator
26789 Settings\SpecialChar menuseparator
26790 Set Normal Size
26791 \family default
26792  and select the font size you are using in your document.
26793  For example this document uses the size 12
26794 \begin_inset space \thinspace{}
26795 \end_inset
26796
26797 pt.
26798 \end_layout
26799
26800 \begin_layout Enumerate
26801 Draw a shape.
26802 \end_layout
26803
26804 \begin_layout Enumerate
26805 Use the menu 
26806 \family sans
26807 TeX/LaTeX\SpecialChar menuseparator
26808 Shapepar
26809 \family default
26810  to export the shape to coordinates.
26811  In the appearing dialog use either the outline of your shape for the coordinate
26812 s or the path itself.
26813 \begin_inset Foot
26814 status collapsed
26815
26816 \begin_layout Plain Layout
26817 For more information see 
26818 \begin_inset CommandInset href
26819 LatexCommand href
26820 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
26821 literal "false"
26822
26823 \end_inset
26824
26825
26826 \end_layout
26827
26828 \end_inset
26829
26830
26831 \end_layout
26832
26833 \begin_layout Standard
26834 The coordinates are written into a \SpecialChar TeX
26835  file.
26836  To use it for your \SpecialChar LyX
26837  document
26838 \end_layout
26839
26840 \begin_layout Enumerate
26841 Place the cursor before the first character of your paragraph (or into a
26842  new empty one).
26843 \end_layout
26844
26845 \begin_layout Enumerate
26846 Open in \SpecialChar LyX
26847  the menu 
26848 \family sans
26849 Insert\SpecialChar menuseparator
26850 File\SpecialChar menuseparator
26851 Child
26852 \begin_inset space ~
26853 \end_inset
26854
26855 Document
26856 \family default
26857 , select the file and use 
26858 \family sans
26859 Input
26860 \family default
26861  as 
26862 \family sans
26863 Include Type.
26864 \end_layout
26865
26866 \begin_layout Standard
26867 \begin_inset VSpace defskip
26868 \end_inset
26869
26870
26871 \end_layout
26872
26873 \begin_layout Standard
26874 \begin_inset Note Greyedout
26875 status open
26876
26877 \begin_layout Plain Layout
26878
26879 \series bold
26880 Note
26881 \series default
26882 : The changed shape only applies to the current paragraph; everything is
26883  reset to normal for the next paragraph.
26884  Therefore the shape definition file must be input into every paragraph
26885  with the desired shape.
26886 \end_layout
26887
26888 \end_inset
26889
26890
26891 \end_layout
26892
26893 \begin_layout Standard
26894 \begin_inset VSpace bigskip
26895 \end_inset
26896
26897
26898 \end_layout
26899
26900 \begin_layout Standard
26901 Here is an example:
26902 \end_layout
26903
26904 \begin_layout Standard
26905 \begin_inset VSpace bigskip
26906 \end_inset
26907
26908
26909 \end_layout
26910
26911 \begin_layout Standard
26912 \begin_inset CommandInset include
26913 LatexCommand input
26914 filename "SpecialParagraphShape.tex"
26915 literal "true"
26916
26917 \end_inset
26918
26919
26920 \lang latin
26921 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26922  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26923  voluptua.
26924  At vero eos et accusam et justo duo dolores et ea rebum.
26925  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26926  sit amet.
26927  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26928  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26929  voluptua.
26930 \end_layout
26931
26932 \begin_layout Standard
26933 \begin_inset VSpace bigskip
26934 \end_inset
26935
26936
26937 \end_layout
26938
26939 \begin_layout Standard
26940
26941 \series bold
26942 A tip:
26943 \series default
26944  to draw complexer shapes in 
26945 \family sans
26946 Jpgfdraw
26947 \family default
26948  you can draw the shape in a program of your choice and import the resulting
26949  image to 
26950 \family sans
26951 Jpgfdraw
26952 \family default
26953 .
26954  Then you only need to draw a line or spline along the outline of the image.
26955 \end_layout
26956
26957 \begin_layout Standard
26958 \begin_inset VSpace bigskip
26959 \end_inset
26960
26961
26962 \end_layout
26963
26964 \begin_layout Standard
26965 The module 
26966 \family sans
26967 Custom paragraph shapes
26968 \family default
26969  also provides the two commands 
26970 \family sans
26971 shapepar
26972 \family default
26973  and 
26974 \family sans
26975 Shapepar
26976 \family default
26977  which can be used to define custom shapes coordinate by coordinate.
26978 \begin_inset Foot
26979 status collapsed
26980
26981 \begin_layout Plain Layout
26982 These commands are internally used for all shapes described here.
26983 \end_layout
26984
26985 \end_inset
26986
26987  For information how these styles are used and about further customization
26988  possibilities, have a look at the 
26989 \begin_inset CommandInset href
26990 LatexCommand href
26991 name "documentation"
26992 target "https://www.ctan.org/tex-archive/macros/latex/contrib/shapepar/shapepar.pdf"
26993 literal "false"
26994
26995 \end_inset
26996
26997  of the package 
26998 \begin_inset Flex Code
26999 status collapsed
27000
27001 \begin_layout Plain Layout
27002 shapepar
27003 \end_layout
27004
27005 \end_inset
27006
27007 .
27008 \end_layout
27009
27010 \end_body
27011 \end_document