]> git.lyx.org Git - features.git/blob - lib/doc/Additional.lyx
105a9f80a1de1fc6495306c2aa2d807004ca0d8e
[features.git] / lib / doc / Additional.lyx
1 #LyX 2.3 created this file. For more info see http://www.lyx.org/
2 \lyxformat 544
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 false
41 \language english
42 \language_package default
43 \inputencoding auto
44 \fontencoding global
45 \font_roman "lmodern" "default"
46 \font_sans "lmss" "default"
47 \font_typewriter "lmtt" "default"
48 \font_math "auto" "auto"
49 \font_default_family default
50 \use_non_tex_fonts false
51 \font_sc false
52 \font_osf false
53 \font_sf_scale 100 100
54 \font_tt_scale 100 100
55 \use_microtype false
56 \use_dash_ligatures true
57 \graphics default
58 \default_output_format pdf2
59 \output_sync 0
60 \bibtex_command default
61 \index_command default
62 \paperfontsize 12
63 \spacing single
64 \use_hyperref true
65 \pdf_title "LyX's Additional Features manual"
66 \pdf_author "LyX Team"
67 \pdf_subject "LyX's additional features documentation"
68 \pdf_keywords "LyX, Documentation, Additional"
69 \pdf_bookmarks true
70 \pdf_bookmarksnumbered true
71 \pdf_bookmarksopen false
72 \pdf_bookmarksopenlevel 1
73 \pdf_breaklinks false
74 \pdf_pdfborder false
75 \pdf_colorlinks true
76 \pdf_backref false
77 \pdf_pdfusetitle false
78 \pdf_quoted_options "linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue, pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false"
79 \papersize a4paper
80 \use_geometry false
81 \use_package amsmath 1
82 \use_package amssymb 1
83 \use_package cancel 0
84 \use_package esint 0
85 \use_package mathdots 1
86 \use_package mathtools 0
87 \use_package mhchem 1
88 \use_package stackrel 0
89 \use_package stmaryrd 0
90 \use_package undertilde 0
91 \cite_engine basic
92 \cite_engine_type default
93 \biblio_style plain
94 \use_bibtopic false
95 \use_indices false
96 \paperorientation portrait
97 \suppress_date false
98 \justification true
99 \use_refstyle 0
100 \use_minted 0
101 \notefontcolor #0000ff
102 \index Index
103 \shortcut idx
104 \color #008000
105 \end_index
106 \secnumdepth 3
107 \tocdepth 3
108 \paragraph_separation indent
109 \paragraph_indentation default
110 \is_math_indent 1
111 \math_indentation default
112 \math_numbering_side default
113 \quotes_style english
114 \dynamic_quotes 0
115 \papercolumns 1
116 \papersides 2
117 \paperpagestyle headings
118 \tracking_changes true
119 \output_changes false
120 \html_math_output 0
121 \html_css_as_file 0
122 \html_be_strict true
123 \author -712698321 "Jürgen Spitzmüller"
124 \end_header
125
126 \begin_body
127
128 \begin_layout Title
129 Additional \SpecialChar LyX
130  Features
131 \end_layout
132
133 \begin_layout Subtitle
134 Version 2.3.x
135 \end_layout
136
137 \begin_layout Author
138 by the \SpecialChar LyX
139  Team
140 \begin_inset Foot
141 status collapsed
142
143 \begin_layout Plain Layout
144 \noindent
145 Principal maintainer of this file is
146 \noun on
147  Richard Heck
148 \noun default
149 .
150  If you have comments or error corrections, please send them to the \SpecialChar LyX
151  Documentati
152 on mailing list, 
153 \begin_inset Flex Code
154 status collapsed
155
156 \begin_layout Plain Layout
157 \noindent
158 <lyx-docs@lists.lyx.org>
159 \end_layout
160
161 \end_inset
162
163 .
164 \end_layout
165
166 \end_inset
167
168
169 \end_layout
170
171 \begin_layout Standard
172 \begin_inset CommandInset toc
173 LatexCommand tableofcontents
174
175 \end_inset
176
177
178 \end_layout
179
180 \begin_layout Chapter
181 Introduction
182 \end_layout
183
184 \begin_layout Standard
185 This manual is essentially Part II of the 
186 \emph on
187 User's Guide\SpecialChar endofsentence
188
189 \emph default
190  The reason for separating the two documents is simple: the 
191 \emph on
192 User's Guide
193 \emph default
194  is already quite lengthy, and it contains information on all of the basic
195  features one needs to know in order to prepare most documents.
196  However, the \SpecialChar LyX
197  Team has worked to make \SpecialChar LyX
198  extensible through various configuration
199  files and external packages.
200  That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
201  package, you can
202  create a layout file (or module) for it without having to alter \SpecialChar LyX
203  itself.
204  We've already had contributions of several new features this way, and some
205  of them are documented here.
206  There are also some more `advanced' features, such as how to control the
207  presentation of bibliographies and how to work with multi-part documents,
208  that are not covered in the 
209 \emph on
210 User's Guide
211 \emph default
212  and are discussed here.
213 \end_layout
214
215 \begin_layout Standard
216 This manual also documents some special features, like fax support, version
217  control, and SGML support, which require additional software to work properly.
218  There is also a chapter on \SpecialChar LyX
219 's support for HTML.
220  And lastly, there's a chapter of \SpecialChar LaTeX
221  tools and tips, things you can use to
222  spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
223 .
224  After all, \SpecialChar LyX
225  
226 \emph on
227 is
228 \emph default
229  only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
230  features.
231 \end_layout
232
233 \begin_layout Standard
234 If you haven't read the 
235 \emph on
236 Introduction
237 \emph default
238  yet, you are definitely in the wrong manual.
239  The 
240 \emph on
241 Introduction
242 \emph default
243  is the first place to go, since it describes the notation and format of
244  all of the manuals.
245  You should also be thoroughly familiar with the 
246 \emph on
247 User's Guide
248 \emph default
249  and all of the basic features of \SpecialChar LyX
250  before attempting to read this one.
251 \end_layout
252
253 \begin_layout Standard
254 Since many of the topics in this manual depend heavily on \SpecialChar LyX
255 's interaction
256  with \SpecialChar LaTeX
257 , this first chapter covers the inner workings of \SpecialChar LyX
258  and how to direct
259  \SpecialChar LyX
260  to generate exactly the \SpecialChar LaTeX
261  code you want.
262  It is obviously for more seasoned \SpecialChar LyX
263  users.
264 \end_layout
265
266 \begin_layout Chapter
267 \SpecialChar LyX
268  and \SpecialChar LaTeX
269
270 \end_layout
271
272 \begin_layout Section
273 How \SpecialChar LyX
274  Uses \SpecialChar LaTeX
275
276 \end_layout
277
278 \begin_layout Standard
279 This chapter is for both \SpecialChar TeX
280 -nicians and the \SpecialChar LaTeX
281 -curious.
282  In it, we'll explain how \SpecialChar LyX
283  and \SpecialChar LaTeX
284  work together to produce printable output.
285  This is the only place in any of the manuals where we assume you know something
286  about \SpecialChar LaTeX
287 .
288 \end_layout
289
290 \begin_layout Standard
291 At one time, \SpecialChar LyX
292  was called a 
293 \begin_inset Quotes eld
294 \end_inset
295
296 WYSIWYM frontend to \SpecialChar LaTeX
297 ,
298 \begin_inset Quotes erd
299 \end_inset
300
301  but that's no longer true.
302  There are frontends to \SpecialChar LaTeX
303  out there.
304 \begin_inset Foot
305 status collapsed
306
307 \begin_layout Plain Layout
308 Some familar ones are \SpecialChar TeX
309 maker and kile, on Linux, and \SpecialChar TeX
310 shop, OSX.
311  There are also the \SpecialChar LaTeX
312  modes for vi and emacs, of course.
313 \end_layout
314
315 \end_inset
316
317  These are basically text editors with the ability to run \SpecialChar LaTeX
318  and mark any
319  errors in the file you're editing.
320  Although \SpecialChar LyX
321  
322 \emph on
323 is
324 \emph default
325  an editor, and it 
326 \emph on
327 does
328 \emph default
329  run \SpecialChar LaTeX
330 , and it also indicates errors in the file, it also does much, much
331  more.
332  For one thing, you don't need to know \SpecialChar LaTeX
333  to use \SpecialChar LyX
334  effectively.
335  And \SpecialChar LyX
336  has added its own extensions to \SpecialChar LaTeX
337 .
338  Try the following sometime: select 
339 \begin_inset Flex Noun
340 status collapsed
341
342 \begin_layout Plain Layout
343 Export\SpecialChar menuseparator
344 LaTeX
345 \end_layout
346
347 \end_inset
348
349  from the 
350 \begin_inset Flex Noun
351 status collapsed
352
353 \begin_layout Plain Layout
354 File
355 \end_layout
356
357 \end_inset
358
359  menu (or 
360 \begin_inset Flex Noun
361 status collapsed
362
363 \begin_layout Plain Layout
364 View\SpecialChar menuseparator
365 Source
366 \begin_inset space ~
367 \end_inset
368
369 Pane
370 \end_layout
371
372 \end_inset
373
374 ), then look at the preamble of the resulting 
375 \begin_inset Flex Code
376 status collapsed
377
378 \begin_layout Plain Layout
379 .tex
380 \end_layout
381
382 \end_inset
383
384  file.
385  You'll notice a variety of new macros defined specifically by \SpecialChar LyX
386 .
387  These macros are defined automatically, according to the features you use
388  in the document.
389 \end_layout
390
391 \begin_layout Standard
392 There are several commands that automatically invoke \SpecialChar LaTeX
393 .
394  They are:
395 \end_layout
396
397 \begin_layout Itemize
398 \begin_inset Flex Noun
399 status collapsed
400
401 \begin_layout Plain Layout
402 Document\SpecialChar menuseparator
403 View
404 \end_layout
405
406 \end_inset
407
408
409 \end_layout
410
411 \begin_layout Itemize
412 \begin_inset Flex Noun
413 status collapsed
414
415 \begin_layout Plain Layout
416 Document\SpecialChar menuseparator
417 Update
418 \end_layout
419
420 \end_inset
421
422
423 \end_layout
424
425 \begin_layout Standard
426 They will only invoke \SpecialChar LaTeX
427  if the file has changed since the last time \SpecialChar LaTeX
428  was
429  run.
430  
431 \end_layout
432
433 \begin_layout Standard
434 When \SpecialChar LyX
435  runs \SpecialChar LaTeX
436  on the file you're editing, it performs these steps:
437 \end_layout
438
439 \begin_layout Enumerate
440 Convert the document to \SpecialChar LaTeX
441  and save to a file with the extension 
442 \begin_inset Flex Code
443 status collapsed
444
445 \begin_layout Plain Layout
446 .tex
447 \end_layout
448
449 \end_inset
450
451  in place of 
452 \begin_inset Flex Code
453 status collapsed
454
455 \begin_layout Plain Layout
456 .lyx
457 \end_layout
458
459 \end_inset
460
461 .
462 \end_layout
463
464 \begin_layout Enumerate
465 Run \SpecialChar LaTeX
466  on the 
467 \begin_inset Flex Code
468 status collapsed
469
470 \begin_layout Plain Layout
471 .tex
472 \end_layout
473
474 \end_inset
475
476  file (maybe several times), and run any other commands (such as 
477 \begin_inset Flex Code
478 status collapsed
479
480 \begin_layout Plain Layout
481 bibtex
482 \end_layout
483
484 \end_inset
485
486  or 
487 \begin_inset Flex Code
488 status collapsed
489
490 \begin_layout Plain Layout
491 makeindex
492 \end_layout
493
494 \end_inset
495
496 ) needed to compile the \SpecialChar LaTeX
497  file.
498 \end_layout
499
500 \begin_layout Enumerate
501 If there are any errors, show the error log.
502 \end_layout
503
504 \begin_layout Standard
505 If you have run \SpecialChar LaTeX
506  using 
507 \begin_inset Flex Noun
508 status collapsed
509
510 \begin_layout Plain Layout
511 View\SpecialChar menuseparator
512 DVI
513 \end_layout
514
515 \end_inset
516
517 , \SpecialChar LyX
518  then runs a DVI viewer to display the DVI-file.
519  If you have used 
520 \begin_inset Flex Noun
521 status collapsed
522
523 \begin_layout Plain Layout
524 View\SpecialChar menuseparator
525 PostScript
526 \end_layout
527
528 \end_inset
529
530 , \SpecialChar LyX
531  performs further steps:
532 \end_layout
533
534 \begin_layout Itemize
535 Run 
536 \begin_inset Flex Code
537 status collapsed
538
539 \begin_layout Plain Layout
540 dvips
541 \end_layout
542
543 \end_inset
544
545  to convert the DVI file to PostScript.
546 \end_layout
547
548 \begin_layout Itemize
549 Run a PostScript viewer, such as 
550 \begin_inset Flex Code
551 status collapsed
552
553 \begin_layout Plain Layout
554 ghostview
555 \end_layout
556
557 \end_inset
558
559 , to display the PostScript file.
560 \end_layout
561
562 \begin_layout Standard
563 \SpecialChar LyX
564  does similar things when viewing, or exporting, other formats.
565 \end_layout
566
567 \begin_layout Section
568 Translating \SpecialChar LaTeX
569  files into \SpecialChar LyX
570
571 \end_layout
572
573 \begin_layout Standard
574 You can import a \SpecialChar LaTeX
575  file into \SpecialChar LyX
576  by using the 
577 \begin_inset Flex Noun
578 status collapsed
579
580 \begin_layout Plain Layout
581 File\SpecialChar menuseparator
582 Import\SpecialChar menuseparator
583 LaTeX
584 \end_layout
585
586 \end_inset
587
588  command in \SpecialChar LyX
589 .
590  This will call a program named 
591 \begin_inset Flex Code
592 status collapsed
593
594 \begin_layout Plain Layout
595 tex2lyx
596 \end_layout
597
598 \end_inset
599
600  which will create a file 
601 \begin_inset Flex Code
602 status collapsed
603
604 \begin_layout Plain Layout
605 foo.lyx
606 \end_layout
607
608 \end_inset
609
610  from the file 
611 \begin_inset Flex Code
612 status collapsed
613
614 \begin_layout Plain Layout
615 foo.tex
616 \end_layout
617
618 \end_inset
619
620 .
621  \SpecialChar LyX
622  will then open that file.
623 \begin_inset Foot
624 status collapsed
625
626 \begin_layout Plain Layout
627 \begin_inset Flex Code
628 status collapsed
629
630 \begin_layout Plain Layout
631 tex2lyx
632 \end_layout
633
634 \end_inset
635
636  can also be run from the command line, of course.
637 \end_layout
638
639 \end_inset
640
641
642 \end_layout
643
644 \begin_layout Standard
645 \begin_inset Flex Code
646 status collapsed
647
648 \begin_layout Plain Layout
649 tex2lyx
650 \end_layout
651
652 \end_inset
653
654  will translate most legal \SpecialChar LaTeX
655 , but not everything.
656  It will put things it doesn't understand into \SpecialChar TeX
657  code, so after translating
658  a file with 
659 \begin_inset Flex Code
660 status collapsed
661
662 \begin_layout Plain Layout
663 tex2lyx
664 \end_layout
665
666 \end_inset
667
668 , you can look for \SpecialChar TeX
669  code and hand-edit it until it looks right.
670 \end_layout
671
672 \begin_layout Standard
673 If you don't know what \SpecialChar TeX
674  code is, read the next section.
675 \end_layout
676
677 \begin_layout Section
678 \begin_inset CommandInset label
679 LatexCommand label
680 name "sec:Inserting-TeX-Code"
681
682 \end_inset
683
684 Inserting \SpecialChar TeX
685  Code into \SpecialChar LyX
686  Documents 
687 \end_layout
688
689 \begin_layout Standard
690 Anything you can do in \SpecialChar LaTeX
691  you can do in \SpecialChar LyX
692 , for a very simple reason: You can
693  always insert \SpecialChar TeX
694  code into any \SpecialChar LyX
695  document.
696  \SpecialChar LyX
697  cannot, and will never be able to, display every possible \SpecialChar LaTeX
698  construct.
699  If ever you need to insert \SpecialChar LaTeX
700  commands into your \SpecialChar LyX
701  document, you can use the
702  
703 \begin_inset Flex Code
704 status collapsed
705
706 \begin_layout Plain Layout
707 \SpecialChar TeX
708  Code
709 \end_layout
710
711 \end_inset
712
713  box, which you can insert into your document with 
714 \begin_inset Flex Noun
715 status collapsed
716
717 \begin_layout Plain Layout
718 Insert\SpecialChar menuseparator
719
720 \family sans
721 TeX
722 \family default
723  Code
724 \end_layout
725
726 \end_inset
727
728  or the keyboard shortcut 
729 \begin_inset Info
730 type  "shortcut"
731 arg   "ert-insert"
732 \end_inset
733
734 .
735 \end_layout
736
737 \begin_layout Standard
738 Here's an example of inserting \SpecialChar LaTeX
739  commands in a \SpecialChar LyX
740  document.
741  The code looks like this:
742 \end_layout
743
744 \begin_layout LyX-Code
745
746 \backslash
747 begin{tabular}{ll}
748 \begin_inset Newline newline
749 \end_inset
750
751
752 \backslash
753 begin{minipage}{5cm}
754 \begin_inset Newline newline
755 \end_inset
756
757 This is an example of a minipage environment.
758  You 
759 \begin_inset Newline newline
760 \end_inset
761
762 can put nearly everything in it, even (non-floating) 
763 \begin_inset Newline newline
764 \end_inset
765
766 figures and tables.
767  
768 \begin_inset Newline newline
769 \end_inset
770
771
772 \backslash
773 end{minipage}
774 \begin_inset Newline newline
775 \end_inset
776
777 &
778 \begin_inset Newline newline
779 \end_inset
780
781
782 \backslash
783 begin{minipage}{5cm}
784 \begin_inset Newline newline
785 \end_inset
786
787
788 \backslash
789 begin{verbatim}
790 \begin_inset Newline newline
791 \end_inset
792
793
794 \backslash
795 begin{minipage}{5cm}
796 \begin_inset Newline newline
797 \end_inset
798
799 This ...
800  
801 \begin_inset Newline newline
802 \end_inset
803
804
805 \backslash
806 end{minipage}
807 \begin_inset Newline newline
808 \end_inset
809
810
811 \backslash
812 end{verbatim}
813 \begin_inset Newline newline
814 \end_inset
815
816
817 \backslash
818 end{minipage}
819 \begin_inset Newline newline
820 \end_inset
821
822
823 \backslash
824 end{tabular}
825 \end_layout
826
827 \begin_layout LyX-Code
828
829 \end_layout
830
831 \begin_layout Standard
832 The 
833 \begin_inset Flex Code
834 status collapsed
835
836 \begin_layout Plain Layout
837 \SpecialChar TeX
838  Code
839 \end_layout
840
841 \end_inset
842
843  box containing this text is directly after this paragraph.
844  Those of you reading the manual in \SpecialChar LyX
845  will only see the \SpecialChar TeX
846  code inset.
847  Those reading a printed version of the manuals will see the actual results:
848 \begin_inset VSpace bigskip
849 \end_inset
850
851
852 \end_layout
853
854 \begin_layout Standard
855 \begin_inset ERT
856 status open
857
858 \begin_layout Plain Layout
859
860
861 \backslash
862 begin{tabular}{ll}
863 \end_layout
864
865 \begin_layout Plain Layout
866
867
868 \backslash
869 begin{minipage}{5cm}
870 \end_layout
871
872 \begin_layout Plain Layout
873
874 This is an example of a minipage environment.
875  You can put nearly everything in it, even (non-floating) figures and tables.
876  
877 \end_layout
878
879 \begin_layout Plain Layout
880
881
882 \backslash
883 end{minipage}
884 \end_layout
885
886 \begin_layout Plain Layout
887
888 &
889 \end_layout
890
891 \begin_layout Plain Layout
892
893
894 \backslash
895 begin{minipage}{5cm}
896 \end_layout
897
898 \begin_layout Plain Layout
899
900
901 \backslash
902 begin{verbatim}
903 \end_layout
904
905 \begin_layout Plain Layout
906
907
908 \backslash
909 begin{minipage}{5cm}
910 \end_layout
911
912 \begin_layout Plain Layout
913
914 This ...
915  
916 \end_layout
917
918 \begin_layout Plain Layout
919
920
921 \backslash
922 end{minipage}
923 \end_layout
924
925 \begin_layout Plain Layout
926
927
928 \backslash
929 end{verbatim}
930 \end_layout
931
932 \begin_layout Plain Layout
933
934
935 \backslash
936 end{minipage}
937 \end_layout
938
939 \begin_layout Plain Layout
940
941
942 \backslash
943 end{tabular}
944 \end_layout
945
946 \end_inset
947
948
949 \begin_inset VSpace bigskip
950 \end_inset
951
952
953 \end_layout
954
955 \begin_layout Standard
956 In addition to using \SpecialChar TeX
957  code, you can also create a separate file containing
958  some complex \SpecialChar LaTeX
959  structure and then use 
960 \begin_inset Flex Noun
961 status collapsed
962
963 \begin_layout Plain Layout
964 Insert\SpecialChar menuseparator
965 Child
966 \begin_inset space ~
967 \end_inset
968
969 Document
970 \end_layout
971
972 \end_inset
973
974  to include your file (you should select the type 
975 \begin_inset Flex Code
976 status collapsed
977
978 \begin_layout Plain Layout
979 Input
980 \end_layout
981
982 \end_inset
983
984 ).
985  We recommend that you only do this if you have a 
986 \begin_inset Flex Code
987 status collapsed
988
989 \begin_layout Plain Layout
990 .tex
991 \end_layout
992
993 \end_inset
994
995  file which you 
996 \emph on
997 know
998 \emph default
999  works already.
1000  Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
1001  errors.
1002 \end_layout
1003
1004 \begin_layout Standard
1005 There are a few last points to emphasize:
1006 \end_layout
1007
1008 \begin_layout Itemize
1009 \SpecialChar LyX
1010  
1011 \emph on
1012 does not
1013 \emph default
1014  check if your \SpecialChar LaTeX
1015  code is correct.
1016 \end_layout
1017
1018 \begin_layout Itemize
1019 Beware of reinventing the wheel.
1020 \end_layout
1021
1022 \begin_layout Standard
1023 On that last point, \SpecialChar LyX
1024  does have quite a few features tucked into it, and
1025  more are coming.
1026  Be sure to check the manuals to make sure that \SpecialChar LyX
1027  doesn't have such-and-such
1028  feature before you decide you have to do it by hand.
1029  Moreover, there are numerous \SpecialChar LaTeX
1030  packages out there to do all sorts of things,
1031  from labels to envelopes to fancy multipage tables.
1032  Check out 
1033 \begin_inset CommandInset href
1034 LatexCommand href
1035 name "CTAN"
1036 target "http://www.ctan.org/"
1037 literal "false"
1038
1039 \end_inset
1040
1041  for details.
1042 \end_layout
1043
1044 \begin_layout Standard
1045 If you do need to do some wild and fancy things within your document, be
1046  sure to check out a good \SpecialChar LaTeX
1047  book for assistance.
1048  There are a number of them listed in the bibliography of the 
1049 \emph on
1050 User's Guide
1051 \emph default
1052 .
1053 \end_layout
1054
1055 \begin_layout Section
1056 \SpecialChar LyX
1057  and the \SpecialChar LaTeX
1058  Preamble
1059 \end_layout
1060
1061 \begin_layout Subsection
1062 About the \SpecialChar LaTeX
1063  Preamble
1064 \end_layout
1065
1066 \begin_layout Standard
1067 If you already know \SpecialChar LaTeX
1068 , there is no need to explain here what the preamble
1069  is good for.
1070  If you don't, the following will give you some ideas—we recommend again
1071  that you consult a \SpecialChar LaTeX
1072  book for further information.
1073  In any case, you should read the points below, because they explain what
1074  you can do and what you don't need to do in the \SpecialChar LaTeX
1075  preamble of a \SpecialChar LyX
1076  document.
1077 \end_layout
1078
1079 \begin_layout Standard
1080 The \SpecialChar LaTeX
1081  preamble comes at the very beginning of a document, 
1082 \emph on
1083 before
1084 \emph default
1085  the text.
1086  It serves to:
1087 \end_layout
1088
1089 \begin_layout Itemize
1090 Declare the document class.
1091  
1092 \begin_inset Newline newline
1093 \end_inset
1094
1095 \SpecialChar LyX
1096  already does this for you.
1097  If you're a seasoned \SpecialChar LaTeX
1098 -nician, and you have a custom document class you
1099  want to use, check out the 
1100 \emph on
1101 Customization Manual
1102 \emph default
1103  for information on how to make \SpecialChar LyX
1104  interface to it.
1105 \end_layout
1106
1107 \begin_layout Itemize
1108 Declare the usage of packages.
1109  
1110 \begin_inset Newline newline
1111 \end_inset
1112
1113 \SpecialChar LaTeX
1114  packages provide special commands, which are only available within a document
1115  when the package has been declared in the preamble.
1116  In addition to providing special commands, the inclusion of a package can
1117  change the document.
1118  For example, the package 
1119 \begin_inset Flex Code
1120 status collapsed
1121
1122 \begin_layout Plain Layout
1123 indentfirst
1124 \end_layout
1125
1126 \end_inset
1127
1128  forces all paragraphs to be indented.
1129  There are other packages for labels, envelopes, margins, etc.
1130  
1131 \end_layout
1132
1133 \begin_layout Itemize
1134 Set counters, variables, lengths and widths.
1135  
1136 \begin_inset Newline newline
1137 \end_inset
1138
1139 There are several \SpecialChar LaTeX
1140  counters and variables that 
1141 \emph on
1142 must
1143 \emph default
1144  be set globally from within the preamble in order to have the desired effect.
1145  (There are variables that you can set and reset inside the document, too.)
1146  Margins are a good example of something that must be set in the preamble.
1147  Another example is the label format for lists.
1148  You can actually set these just about anywhere, but it's best to do it
1149  just once, inside the preamble.
1150 \end_layout
1151
1152 \begin_layout Itemize
1153 Declare user defined commands (with 
1154 \begin_inset Flex Code
1155 status collapsed
1156
1157 \begin_layout Plain Layout
1158
1159 \backslash
1160 newcommand
1161 \end_layout
1162
1163 \end_inset
1164
1165  or 
1166 \begin_inset Flex Code
1167 status collapsed
1168
1169 \begin_layout Plain Layout
1170
1171 \backslash
1172 renewcommand
1173 \end_layout
1174
1175 \end_inset
1176
1177 ).
1178 \begin_inset Newline newline
1179 \end_inset
1180
1181 These are abbreviations for \SpecialChar LaTeX
1182  commands which appear very often inside a document.
1183  Although the preamble is a good place to declare such commands, they 
1184 \emph on
1185 can
1186 \emph default
1187  be declared anywhere (before they are used for the first time, of course).
1188  This can be useful if there is a lot of raw \SpecialChar LaTeX
1189  code in your document, which
1190  normally should not be the case.
1191 \end_layout
1192
1193 \begin_layout Standard
1194 \SpecialChar LyX
1195  adds its own set of definitions to the preamble of the 
1196 \begin_inset Flex Code
1197 status collapsed
1198
1199 \begin_layout Plain Layout
1200 .tex
1201 \end_layout
1202
1203 \end_inset
1204
1205  file it produces.
1206  This makes \SpecialChar LaTeX
1207  files generated by \SpecialChar LyX
1208  portable.
1209 \end_layout
1210
1211 \begin_layout Subsection
1212 Changing the Preamble
1213 \end_layout
1214
1215 \begin_layout Standard
1216 The commands which \SpecialChar LyX
1217  adds to the preamble of a \SpecialChar LaTeX
1218  file are fixed; you can't
1219  change them without patching \SpecialChar LyX
1220  itself.
1221  You can, however, add your own stuff to the preamble by selecting 
1222 \begin_inset Flex Noun
1223 status collapsed
1224
1225 \begin_layout Plain Layout
1226 \SpecialChar LaTeX
1227
1228 \begin_inset space ~
1229 \end_inset
1230
1231 Preamble
1232 \end_layout
1233
1234 \end_inset
1235
1236  in the 
1237 \begin_inset Flex Noun
1238 status collapsed
1239
1240 \begin_layout Plain Layout
1241 Document\SpecialChar menuseparator
1242 Settings
1243 \end_layout
1244
1245 \end_inset
1246
1247  dialog.
1248  \SpecialChar LyX
1249  adds anything in the 
1250 \begin_inset Flex Noun
1251 status collapsed
1252
1253 \begin_layout Plain Layout
1254 Preamble
1255 \end_layout
1256
1257 \end_inset
1258
1259  dialog to its own built-in preamble.
1260  Before adding your own declarations in the preamble, you should make sure
1261  that \SpecialChar LyX
1262  doesn't already support what you want to do.
1263  (Remember what we said about reinventing the wheel?) Also, 
1264 \emph on
1265 make sure your preamble code is correct
1266 \emph default
1267 .
1268  \SpecialChar LyX
1269  doesn't check it for you.
1270  If there is an error, you're likely to get an error like 
1271 \begin_inset Quotes eld
1272 \end_inset
1273
1274
1275 \begin_inset Flex Code
1276 status collapsed
1277
1278 \begin_layout Plain Layout
1279 Missing 
1280 \backslash
1281 begin{document}
1282 \end_layout
1283
1284 \end_inset
1285
1286
1287 \begin_inset Quotes erd
1288 \end_inset
1289
1290 .
1291  If you see this error, check your preamble.
1292 \end_layout
1293
1294 \begin_layout Subsection
1295 Examples
1296 \end_layout
1297
1298 \begin_layout Standard
1299 Here are some examples of what you can add to a preamble, and what they
1300  do.
1301 \end_layout
1302
1303 \begin_layout Subsubsection
1304 Example #1: Offsets
1305 \end_layout
1306
1307 \begin_layout Standard
1308 There are two variables under \SpecialChar LaTeX
1309  that control page position: 
1310 \begin_inset Flex Code
1311 status collapsed
1312
1313 \begin_layout Plain Layout
1314
1315 \backslash
1316 hoffset
1317 \end_layout
1318
1319 \end_inset
1320
1321  and 
1322 \begin_inset Flex Code
1323 status collapsed
1324
1325 \begin_layout Plain Layout
1326
1327 \backslash
1328 voffset
1329 \end_layout
1330
1331 \end_inset
1332
1333 .
1334  Their names should be self-explanatory.
1335  These variables are useful if you think for a moment about computer labels.
1336  Sometimes, the size of a print medium and the area of the medium that you
1337  can actually print on aren't the same.
1338  This is where 
1339 \begin_inset Flex Code
1340 status collapsed
1341
1342 \begin_layout Plain Layout
1343
1344 \backslash
1345 hoffset
1346 \end_layout
1347
1348 \end_inset
1349
1350  and 
1351 \begin_inset Flex Code
1352 status collapsed
1353
1354 \begin_layout Plain Layout
1355
1356 \backslash
1357 voffset
1358 \end_layout
1359
1360 \end_inset
1361
1362  come in.
1363 \end_layout
1364
1365 \begin_layout Standard
1366 The default values for 
1367 \begin_inset Flex Code
1368 status collapsed
1369
1370 \begin_layout Plain Layout
1371
1372 \backslash
1373 hoffset
1374 \end_layout
1375
1376 \end_inset
1377
1378  and 
1379 \begin_inset Flex Code
1380 status collapsed
1381
1382 \begin_layout Plain Layout
1383
1384 \backslash
1385 voffset
1386 \end_layout
1387
1388 \end_inset
1389
1390  are both 0
1391 \begin_inset space \thinspace{}
1392 \end_inset
1393
1394 points, i.
1395 \begin_inset space \thinspace{}
1396 \end_inset
1397
1398 e.
1399 \begin_inset space \space{}
1400 \end_inset
1401
1402 the page isn't shifted.
1403  Unfortunately, some DVI drivers always seem to shift the page.
1404  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1405  If you're using \SpecialChar LyX
1406  on a system that you don't personally maintain, and your
1407  sysadmin is a doofus, 
1408 \begin_inset Flex Code
1409 status collapsed
1410
1411 \begin_layout Plain Layout
1412
1413 \backslash
1414 hoffset
1415 \end_layout
1416
1417 \end_inset
1418
1419  and 
1420 \begin_inset Flex Code
1421 status collapsed
1422
1423 \begin_layout Plain Layout
1424
1425 \backslash
1426 voffset
1427 \end_layout
1428
1429 \end_inset
1430
1431  can save the day.
1432  Suppose your left and top margins are always 0.5
1433 \begin_inset space \thinspace{}
1434 \end_inset
1435
1436 inches too big.
1437  You can add this to the preamble:
1438 \end_layout
1439
1440 \begin_layout LyX-Code
1441
1442 \backslash
1443 setlength{
1444 \backslash
1445 hoffset}{-0.5 in}
1446 \end_layout
1447
1448 \begin_layout LyX-Code
1449
1450 \backslash
1451 setlength{
1452 \backslash
1453 voffset}{-0.5 in}
1454 \end_layout
1455
1456 \begin_layout Standard
1457 and your margins should now be correct.
1458 \end_layout
1459
1460 \begin_layout Subsubsection
1461 Example #2: Labels
1462 \end_layout
1463
1464 \begin_layout Standard
1465 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1466  There's a rather nice package, available at your nearest CTAN archive,
1467  for printing sheets of labels: 
1468 \begin_inset Flex Code
1469 status collapsed
1470
1471 \begin_layout Plain Layout
1472 labels.sty
1473 \end_layout
1474
1475 \end_inset
1476
1477 .
1478  Now, your system may not have this package installed by default.
1479  We leave that up to you to check.
1480  You'll also want to read the documentation for it; we're not going to do
1481  that for you.
1482  Since this is an example, however, we'll give you an example of how you
1483  use this package.
1484 \end_layout
1485
1486 \begin_layout Standard
1487 First, make sure you're using the 
1488 \begin_inset Flex Code
1489 status collapsed
1490
1491 \begin_layout Plain Layout
1492 article
1493 \end_layout
1494
1495 \end_inset
1496
1497  document class.
1498  Next, you need to put the following in your preamble:
1499 \end_layout
1500
1501 \begin_layout LyX-Code
1502
1503 \backslash
1504 usepackage{labels}
1505 \end_layout
1506
1507 \begin_layout LyX-Code
1508
1509 \backslash
1510 LabelCols=3
1511 \end_layout
1512
1513 \begin_layout LyX-Code
1514
1515 \backslash
1516 LabelRows=7
1517 \end_layout
1518
1519 \begin_layout LyX-Code
1520
1521 \backslash
1522 LeftBorder=8mm
1523 \end_layout
1524
1525 \begin_layout LyX-Code
1526
1527 \backslash
1528 RightBorder=8mm
1529 \end_layout
1530
1531 \begin_layout LyX-Code
1532
1533 \backslash
1534 TopBorder=9mm
1535 \end_layout
1536
1537 \begin_layout LyX-Code
1538
1539 \backslash
1540 BottomBorder=2mm
1541 \end_layout
1542
1543 \begin_layout Standard
1544 This sets things up for Avery label sheets, stock #5360.
1545  You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1546  code, placing
1547  the commands 
1548 \begin_inset Flex Code
1549 status collapsed
1550
1551 \begin_layout Plain Layout
1552
1553 \backslash
1554 begin{labels}
1555 \end_layout
1556
1557 \end_inset
1558
1559  and 
1560 \begin_inset Flex Code
1561 status collapsed
1562
1563 \begin_layout Plain Layout
1564
1565 \backslash
1566 end{labels}
1567 \end_layout
1568
1569 \end_inset
1570
1571  around each label text.
1572  This and other special features of 
1573 \begin_inset Flex Code
1574 status collapsed
1575
1576 \begin_layout Plain Layout
1577 labels.sty
1578 \end_layout
1579
1580 \end_inset
1581
1582  are explained in its documentation.
1583 \end_layout
1584
1585 \begin_layout Standard
1586 Someday, someone may write a \SpecialChar LyX
1587  layout file to support this package directly.
1588  Maybe that someone is you.
1589 \end_layout
1590
1591 \begin_layout Subsubsection
1592 Example #3: Paragraph Indentation
1593 \end_layout
1594
1595 \begin_layout Standard
1596 Americans are trained to indent the first line of 
1597 \emph on
1598 every
1599 \emph default
1600  paragraph.
1601  As with all of their other weird quirks, most Americans will whine and
1602  moan until they can have their way and indent the first line of all paragraphs.
1603  (Yes, we're joking.
1604  (We are?) 
1605 \emph on
1606 Yeah
1607 \emph default
1608 , we are.)
1609 \end_layout
1610
1611 \begin_layout Standard
1612 Of course, this behavior isn't standard typography.
1613  In books, you typically only indent the first line of a paragraph 
1614 \emph on
1615 if
1616 \emph default
1617  it follows another one.
1618  The idea behind indenting the first line of a paragraph is to distinguish
1619  neighboring paragraphs from one another.
1620  If there is no previous paragraph—for example, if it follows a figure or
1621  is the first paragraph in a section—then there is no need for indentation.
1622  
1623 \end_layout
1624
1625 \begin_layout Standard
1626 If you're a typical American (we're still joking!), though, you don't care
1627  about such esoteric things; you want your indentation! Add this to the
1628  preamble:
1629 \end_layout
1630
1631 \begin_layout LyX-Code
1632
1633 \backslash
1634 usepackage{indentfirst}
1635 \end_layout
1636
1637 \begin_layout Standard
1638 If your \SpecialChar TeX
1639  distribution isn't braindead, you'll have this package, and all
1640  of your paragraphs will get the indentation the Founding Fathers intended
1641  they should have.
1642 \end_layout
1643
1644 \begin_layout Subsubsection
1645 Example #4: This Document
1646 \end_layout
1647
1648 \begin_layout Standard
1649 You can also check out the preamble of this document to get an idea of some
1650  of the advanced things you can do.
1651 \end_layout
1652
1653 \begin_layout Section
1654 \SpecialChar LyX
1655  and \SpecialChar LaTeX
1656  Errors
1657 \end_layout
1658
1659 \begin_layout Standard
1660 When \SpecialChar LyX
1661  calls \SpecialChar LaTeX
1662 , it tells \SpecialChar LaTeX
1663  to blithely ignore any errors and keep going.
1664  It then uses the logfile from the \SpecialChar LaTeX
1665  run to do a post-mortem.
1666  After analyzing the logfile, \SpecialChar LyX
1667  displays a dialog listing the errors.
1668  Clicking on any one of them will take you to the position in your \SpecialChar LyX
1669  file
1670  where the error occurred.
1671 \begin_inset Foot
1672 status collapsed
1673
1674 \begin_layout Plain Layout
1675 Well, usually.
1676  Analyzing the logfile is a tough job, and \SpecialChar LyX
1677  doesn't always go to the right
1678  line.
1679  There are also cases where \SpecialChar LaTeX
1680  reports the error on one line, but the actual
1681  error is earlier.
1682  This is not unlike forgetting a closing brace in a program: You'll get
1683  an error, but only later.
1684 \end_layout
1685
1686 \end_inset
1687
1688
1689 \end_layout
1690
1691 \begin_layout Standard
1692 Some folks also like to look at the log file directly: It is available from
1693  
1694 \begin_inset Flex Noun
1695 status collapsed
1696
1697 \begin_layout Plain Layout
1698 Document\SpecialChar menuseparator
1699 LaTeX
1700 \begin_inset space ~
1701 \end_inset
1702
1703 Log
1704 \end_layout
1705
1706 \end_inset
1707
1708 .
1709  There are some fairly common error messages and warnings.
1710  We'll cover those here.
1711  You should look at a good \SpecialChar LaTeX
1712  book for a complete listing.
1713 \end_layout
1714
1715 \begin_layout Itemize
1716 \begin_inset Flex Code
1717 status collapsed
1718
1719 \begin_layout Plain Layout
1720 LaTeX Warning
1721 \end_layout
1722
1723 \end_inset
1724
1725
1726 \begin_inset Newline newline
1727 \end_inset
1728
1729 Anything beginning with these words is a warning message for the purpose
1730  of 
1731 \begin_inset Quotes eld
1732 \end_inset
1733
1734 debugging
1735 \begin_inset Quotes erd
1736 \end_inset
1737
1738  the \SpecialChar LaTeX
1739  code itself.
1740  You'll get messages like this if you added or changed cross-references
1741  or bibliography entries, in which case, \SpecialChar LaTeX
1742  is trying to tell you that you
1743  need to make another run.
1744  You can by-and-large ignore these.
1745 \end_layout
1746
1747 \begin_layout Itemize
1748 \begin_inset Flex Code
1749 status collapsed
1750
1751 \begin_layout Plain Layout
1752 LaTeX Font Warning
1753 \end_layout
1754
1755 \end_inset
1756
1757
1758 \begin_inset Newline newline
1759 \end_inset
1760
1761 Another warning message, this time about fonts which \SpecialChar LaTeX
1762  couldn't find.
1763  The rest of the message will often say something about a replacement font
1764  that \SpecialChar LaTeX
1765  used.
1766  You can safely ignore these, too.
1767 \end_layout
1768
1769 \begin_layout Itemize
1770 \begin_inset Flex Code
1771 status collapsed
1772
1773 \begin_layout Plain Layout
1774 Overfull 
1775 \backslash
1776 hbox
1777 \end_layout
1778
1779 \end_inset
1780
1781
1782 \begin_inset Newline newline
1783 \end_inset
1784
1785 \SpecialChar LaTeX
1786  absolutely 
1787 \emph on
1788 loves
1789 \emph default
1790  to spew these out.
1791  They are warnings about lines that were too long and run past the right
1792  margin.
1793  Almost always, this is unnoticeable in the final output.
1794  (It can be just a point or two.) Or, only one or two characters extend past
1795  the margin.
1796  \SpecialChar LaTeX
1797  seems to generate at least one of these messages for just about any document
1798  you write.
1799 \begin_inset Newline newline
1800 \end_inset
1801
1802 You can ignore these messages.
1803  Your eyes will tell you if there's a problem with something that's too
1804  wide; just look at the output.
1805 \begin_inset Foot
1806 status collapsed
1807
1808 \begin_layout Plain Layout
1809 You can also enable the `draft' option in 
1810 \begin_inset Flex Noun
1811 status collapsed
1812
1813 \begin_layout Plain Layout
1814 Document\SpecialChar menuseparator
1815 Settings
1816 \end_layout
1817
1818 \end_inset
1819
1820 , and then \SpecialChar LaTeX
1821  will draw a black box in the margin of lines that are overfull.
1822 \end_layout
1823
1824 \end_inset
1825
1826
1827 \end_layout
1828
1829 \begin_layout Itemize
1830 \begin_inset Flex Code
1831 status collapsed
1832
1833 \begin_layout Plain Layout
1834 Underfull 
1835 \backslash
1836 hbox
1837 \end_layout
1838
1839 \end_inset
1840
1841
1842 \begin_inset Newline newline
1843 \end_inset
1844
1845 Not quite as common as its cousin.
1846  \SpecialChar LaTeX
1847  seems to like to print lines that are a bit too wide as opposed to ones
1848  that are a bit too narrow.
1849  We have no idea why.
1850 \end_layout
1851
1852 \begin_layout Itemize
1853 \begin_inset Flex Code
1854 status collapsed
1855
1856 \begin_layout Plain Layout
1857 Overfull 
1858 \backslash
1859 vbox
1860 \end_layout
1861
1862 \end_inset
1863
1864  and 
1865 \begin_inset Flex Code
1866 status collapsed
1867
1868 \begin_layout Plain Layout
1869 Underfull 
1870 \backslash
1871 vbox
1872 \end_layout
1873
1874 \end_inset
1875
1876
1877 \begin_inset Newline newline
1878 \end_inset
1879
1880 Warnings about troubles breaking the page.
1881  Once again, just look at the output.
1882  Your eyes will tell you where something has gone wrong.
1883 \end_layout
1884
1885 \begin_layout Itemize
1886 \begin_inset Flex Code
1887 status collapsed
1888
1889 \begin_layout Plain Layout
1890 LaTeX Error: File 
1891 \begin_inset Quotes els
1892 \end_inset
1893
1894 Xxxx
1895 \begin_inset Quotes ers
1896 \end_inset
1897
1898  not found
1899 \end_layout
1900
1901 \end_inset
1902
1903
1904 \begin_inset Newline newline
1905 \end_inset
1906
1907 The file 
1908 \begin_inset Quotes eld
1909 \end_inset
1910
1911 Xxxx
1912 \begin_inset Quotes erd
1913 \end_inset
1914
1915  isn't installed on this system.
1916  This usually appears because some package your document needs isn't installed.
1917  If you didn't touch the preamble or didn't use the 
1918 \begin_inset Flex Code
1919 status collapsed
1920
1921 \begin_layout Plain Layout
1922
1923 \backslash
1924 usepackage{}
1925 \end_layout
1926
1927 \end_inset
1928
1929  command, then one of the packages \SpecialChar LyX
1930  tried to load is missing.
1931  Use 
1932 \begin_inset Flex Noun
1933 status collapsed
1934
1935 \begin_layout Plain Layout
1936 Help\SpecialChar menuseparator
1937 \SpecialChar LaTeX
1938  Configuration
1939 \end_layout
1940
1941 \end_inset
1942
1943  to get a list of packages that \SpecialChar LyX
1944  knows about.
1945  This file is updated whenever you reconfigure \SpecialChar LyX
1946  (using 
1947 \begin_inset Flex Noun
1948 status collapsed
1949
1950 \begin_layout Plain Layout
1951 Tools\SpecialChar menuseparator
1952 Reconfigure
1953 \end_layout
1954
1955 \end_inset
1956
1957 ) and tells you which packages have been detected and what they do.
1958 \begin_inset Newline newline
1959 \end_inset
1960
1961 If you did use the 
1962 \begin_inset Flex Code
1963 status collapsed
1964
1965 \begin_layout Plain Layout
1966
1967 \backslash
1968 usepackage{}
1969 \end_layout
1970
1971 \end_inset
1972
1973  command and the package in question isn't installed, then you'll need to
1974  install it yourself.
1975 \end_layout
1976
1977 \begin_layout Itemize
1978 \begin_inset Flex Code
1979 status collapsed
1980
1981 \begin_layout Plain Layout
1982 LaTeX Error: Unknown option
1983 \end_layout
1984
1985 \end_inset
1986
1987
1988 \begin_inset Newline newline
1989 \end_inset
1990
1991 Error messages beginning with this are trying to tell you that you specified
1992  a bad or undefined option to a package.
1993  Check the package's documentation.
1994 \end_layout
1995
1996 \begin_layout Itemize
1997 \begin_inset Flex Code
1998 status collapsed
1999
2000 \begin_layout Plain Layout
2001 Undefined control sequence
2002 \end_layout
2003
2004 \end_inset
2005
2006
2007 \begin_inset Newline newline
2008 \end_inset
2009
2010 If you've inserted \SpecialChar LaTeX
2011  code into your document, but made a typo, you'll get
2012  one of these.
2013  You may have forgotten to load a package.
2014  In any case, this error message usually means that you used an undefined
2015  command.
2016  
2017 \end_layout
2018
2019 \begin_layout Standard
2020 There are other error and warning messages.
2021  Some are self-explanatory.
2022  These are usually \SpecialChar LaTeX
2023  messages.
2024  Others are downright cryptic.
2025  These are usually \SpecialChar TeX
2026  error messages, and we really have 
2027 \emph on
2028 no clue
2029 \emph default
2030  what they mean or how to decipher them.
2031  No-one does.
2032 \end_layout
2033
2034 \begin_layout Standard
2035 There's a general sequence you should follow if you get error messages:
2036 \end_layout
2037
2038 \begin_layout Enumerate
2039 Look at the \SpecialChar LaTeX
2040  code you inserted for typos.
2041 \end_layout
2042
2043 \begin_layout Enumerate
2044 If there are no typos, check that you used the command(s) correctly.
2045 \end_layout
2046
2047 \begin_layout Enumerate
2048 If you get a bunch of error boxes piled up at the very top of the document—and
2049  especially if you see a 
2050 \begin_inset Quotes eld
2051 \end_inset
2052
2053
2054 \begin_inset Flex Code
2055 status collapsed
2056
2057 \begin_layout Plain Layout
2058 Missing 
2059 \backslash
2060 begin{document}
2061 \end_layout
2062
2063 \end_inset
2064
2065
2066 \begin_inset Quotes erd
2067 \end_inset
2068
2069  error—it means that there are errors in the preamble.
2070  Start debugging your preamble.
2071 \end_layout
2072
2073 \begin_layout Enumerate
2074 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2075  code to the
2076  document, the first suspect is your \SpecialChar LaTeX
2077  distribution itself.
2078  Check for missing packages and install them.
2079 \end_layout
2080
2081 \begin_layout Enumerate
2082 Okay, so there are no missing packages.
2083  Did you use any of the fine-tuning options in \SpecialChar LyX
2084 ? Specifically, did you 
2085 \emph on
2086 misuse
2087 \emph default
2088  any of them, like trying to manually insert lots of 
2089 \begin_inset Flex Code
2090 status collapsed
2091
2092 \begin_layout Plain Layout
2093 Protected
2094 \begin_inset space ~
2095 \end_inset
2096
2097 Blanks
2098 \end_layout
2099
2100 \end_inset
2101
2102
2103 \begin_inset Flex Code
2104 status collapsed
2105
2106 \begin_layout Plain Layout
2107 Linebreaks
2108 \end_layout
2109
2110 \end_inset
2111
2112 , or 
2113 \begin_inset Flex Code
2114 status collapsed
2115
2116 \begin_layout Plain Layout
2117 Pagebreaks
2118 \end_layout
2119
2120 \end_inset
2121
2122 ? Did you try to kludge something together with these instead of using the
2123  appropriate paragraph environment?
2124 \end_layout
2125
2126 \begin_layout Enumerate
2127 All right, you didn't use any of the fine-tuning options, you played by
2128  the rules.
2129  Did you try to pull a fancy maneuver? Did you do something funky inside
2130  a table or an equation, like inserting a graphic into a table cell?
2131 \end_layout
2132
2133 \begin_layout Enumerate
2134 Do you have long sections of text where \SpecialChar LaTeX
2135  cannot find a place to break a
2136  line? By default, \SpecialChar LaTeX
2137  is rather strict about how much extra inter-word spacing
2138  it will add in order to break a line.
2139  Preferably, you should rework the paragraph to avoid the problem.
2140 \end_layout
2141
2142 \begin_layout Enumerate
2143 Did you go overboard with the nesting? \SpecialChar LyX
2144  (currently) doesn't check to make
2145  sure you're in the limits for nesting environments.
2146  If you nested a bunch of environments to the 
2147 \begin_inset Formula $17^{\mathrm{th}}$
2148 \end_inset
2149
2150  level, that's the problem.
2151  (The limit in \SpecialChar LaTeX
2152  is five.)
2153 \end_layout
2154
2155 \begin_layout Enumerate
2156 Okay, you didn't get any error messages, but your output looks awful.
2157  If you have a table or figure that's too wide or long for the page, you
2158  need to:
2159 \end_layout
2160
2161 \begin_deeper
2162 \begin_layout Enumerate
2163 rescale the figure so it fits.
2164 \end_layout
2165
2166 \begin_layout Enumerate
2167 trim down the table so it fits.
2168 \end_layout
2169
2170 \end_deeper
2171 \begin_layout Enumerate
2172 If something else is wrong with the output, and you didn't try to pull anything
2173  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2174 \end_layout
2175
2176 \begin_layout Standard
2177 If all this doesn't help—well, then 
2178 \emph on
2179 perhaps
2180 \emph default
2181  you might have found a bug in \SpecialChar LyX
2182 \SpecialChar ldots
2183 .
2184 \end_layout
2185
2186 \begin_layout Chapter
2187 Supplemental Tools
2188 \end_layout
2189
2190 \begin_layout Section
2191 Customizing Bibliographies with Bib\SpecialChar TeX
2192  or Biblatex
2193 \end_layout
2194
2195 \begin_layout Standard
2196 The most basic information about how to use Bib\SpecialChar TeX
2197  or 
2198 \family sans
2199 Biblatex
2200 \family default
2201  with \SpecialChar LyX
2202  is contained in the section 
2203 \emph on
2204 Bibliography databases
2205 \emph default
2206  of the 
2207 \emph on
2208 User's Guide
2209 \emph default
2210 .
2211  The following subsections explain special bibliography features supported
2212  by \SpecialChar LyX
2213 .
2214 \end_layout
2215
2216 \begin_layout Subsection
2217 Alternative Citation Styles
2218 \end_layout
2219
2220 \begin_layout Standard
2221 Standard Bib\SpecialChar TeX
2222  uses numbers (e.
2223 \begin_inset space \thinspace{}
2224 \end_inset
2225
2226 g.
2227 \begin_inset space \space{}
2228 \end_inset
2229
2230
2231 \begin_inset Quotes eld
2232 \end_inset
2233
2234 [12]
2235 \begin_inset Quotes erd
2236 \end_inset
2237
2238 ) to refer to a cited work.
2239  However, in many scientific disciplines, other citation styles are in use.
2240  The most common one is the author-year style (e.
2241 \begin_inset space \thinspace{}
2242 \end_inset
2243
2244 g.
2245 \begin_inset space \space{}
2246 \end_inset
2247
2248
2249 \begin_inset Quotes eld
2250 \end_inset
2251
2252 Knuth 1984a
2253 \begin_inset Quotes erd
2254 \end_inset
2255
2256 ).
2257  \SpecialChar LyX
2258  supports three packages that provide this style, 
2259 \begin_inset Flex Code
2260 status collapsed
2261
2262 \begin_layout Plain Layout
2263 biblatex
2264 \end_layout
2265
2266 \end_inset
2267
2268
2269 \begin_inset Flex Code
2270 status collapsed
2271
2272 \begin_layout Plain Layout
2273 natbib
2274 \end_layout
2275
2276 \end_inset
2277
2278 , and 
2279 \begin_inset Flex Code
2280 status collapsed
2281
2282 \begin_layout Plain Layout
2283 jurabib
2284 \end_layout
2285
2286 \end_inset
2287
2288 .
2289  Each of these packages has their pros and cons, which cannot be listed
2290  in detail.
2291  If you only want to have simple author-year (or author-numerical) style,
2292  or if you want to use one of the countless style files for 
2293 \begin_inset Flex Code
2294 status collapsed
2295
2296 \begin_layout Plain Layout
2297 natbib
2298 \end_layout
2299
2300 \end_inset
2301
2302 , then the established 
2303 \begin_inset Flex Code
2304 status collapsed
2305
2306 \begin_layout Plain Layout
2307 natbib
2308 \end_layout
2309
2310 \end_inset
2311
2312  package is probably your choice.
2313  If you look for specific citation styles common in law studies, you might
2314  consider the 
2315 \begin_inset Flex Code
2316 status collapsed
2317
2318 \begin_layout Plain Layout
2319 jurabib
2320 \end_layout
2321
2322 \end_inset
2323
2324  package.
2325  If you want to have full control over the formatting or look for advanced
2326  features such as ibidem, footnote citations, full title citations, advanced
2327  date formats (such as 400 BC) or full localization to other languages than
2328  English, you should definitely consider 
2329 \begin_inset Flex Code
2330 status collapsed
2331
2332 \begin_layout Plain Layout
2333 biblatex
2334 \end_layout
2335
2336 \end_inset
2337
2338 , which exceeds all other packages in terms of features, but is also quite
2339  heavy and more resource-hungry.
2340 \end_layout
2341
2342 \begin_layout Standard
2343 The handling of these packages in \SpecialChar LyX
2344  is basically the same.
2345  Go to 
2346 \begin_inset Flex Noun
2347 status collapsed
2348
2349 \begin_layout Plain Layout
2350 Document\SpecialChar menuseparator
2351 Settings
2352 \end_layout
2353
2354 \end_inset
2355
2356  and select under 
2357 \begin_inset Flex Noun
2358 status collapsed
2359
2360 \begin_layout Plain Layout
2361 Bibliography
2362 \end_layout
2363
2364 \end_inset
2365
2366  the 
2367 \begin_inset Flex Noun
2368 status collapsed
2369
2370 \begin_layout Plain Layout
2371 Style Format
2372 \end_layout
2373
2374 \end_inset
2375
2376  
2377 \begin_inset Flex Noun
2378 status collapsed
2379
2380 \begin_layout Plain Layout
2381 Biblatex
2382 \end_layout
2383
2384 \end_inset
2385
2386
2387 \begin_inset Flex Noun
2388 status collapsed
2389
2390 \begin_layout Plain Layout
2391 Biblatex (Natbib mode)
2392 \end_layout
2393
2394 \end_inset
2395
2396
2397 \begin_inset Flex Noun
2398 status collapsed
2399
2400 \begin_layout Plain Layout
2401 Natbib (BibTeX)
2402 \end_layout
2403
2404 \end_inset
2405
2406  or 
2407 \begin_inset Flex Noun
2408 status collapsed
2409
2410 \begin_layout Plain Layout
2411 Jurabib (BibTeX)
2412 \end_layout
2413
2414 \end_inset
2415
2416  (see sec.
2417 \begin_inset space ~
2418 \end_inset
2419
2420 6.5.3 in the User's Guide for more information on these choices).
2421  With all these packages, you will get some extra features in the citation
2422  dialog and you can select the style of the reference (
2423 \begin_inset Quotes eld
2424 \end_inset
2425
2426 Knuth 1984
2427 \begin_inset Quotes erd
2428 \end_inset
2429
2430
2431 \begin_inset Quotes eld
2432 \end_inset
2433
2434 Knuth (1984)
2435 \begin_inset Quotes erd
2436 \end_inset
2437
2438
2439 \begin_inset Quotes eld
2440 \end_inset
2441
2442 Knuth, 1984
2443 \begin_inset Quotes erd
2444 \end_inset
2445
2446
2447 \begin_inset Quotes eld
2448 \end_inset
2449
2450 1984
2451 \begin_inset Quotes erd
2452 \end_inset
2453
2454  etc.).
2455  Note that either package needs specifically designed style files.
2456  They all ship their own, but there are lots of additional style files,
2457  and there is even an interactive style file builder
2458 \begin_inset Foot
2459 status collapsed
2460
2461 \begin_layout Plain Layout
2462 See 
2463 \begin_inset Flex URL
2464 status open
2465
2466 \begin_layout Plain Layout
2467
2468 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2469 \end_layout
2470
2471 \end_inset
2472
2473
2474 \end_layout
2475
2476 \end_inset
2477
2478  for 
2479 \begin_inset Flex Code
2480 status collapsed
2481
2482 \begin_layout Plain Layout
2483 natbib
2484 \end_layout
2485
2486 \end_inset
2487
2488 .
2489 \end_layout
2490
2491 \begin_layout Subsection
2492 Subdivided Bibliographies
2493 \end_layout
2494
2495 \begin_layout Standard
2496 Sometimes you might need to divide your bibliography into several sections.
2497  If you are for instance a historian, the possibility to separate sources
2498  and scientific works is most likely a 
2499 \begin_inset Quotes eld
2500 \end_inset
2501
2502 must have
2503 \begin_inset Quotes erd
2504 \end_inset
2505
2506 .
2507  Unfortunately, Bib\SpecialChar TeX
2508  itself does not allow you to do this.
2509  But with the help of some \SpecialChar LaTeX
2510  packages, Bib\SpecialChar TeX
2511  can be extended to fit your needs.
2512 \end_layout
2513
2514 \begin_layout Standard
2515 \SpecialChar LyX
2516  provides native support for one of these packages, 
2517 \family typewriter
2518 bibtopic
2519 \family default
2520 .
2521 \begin_inset Foot
2522 status collapsed
2523
2524 \begin_layout Plain Layout
2525 Available from 
2526 \begin_inset Flex URL
2527 status open
2528
2529 \begin_layout Plain Layout
2530
2531 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2532 \end_layout
2533
2534 \end_inset
2535
2536
2537 \end_layout
2538
2539 \end_inset
2540
2541  The advantage of this package (compared to other packages such as 
2542 \family typewriter
2543 multibib
2544 \family default
2545 ) is that you don't need to define new citation commands.
2546  Instead, you need to prepare different bibliographic databases which include
2547  the entries for the different sections of the bibliography.
2548  For example: If you want to divide your bibliography into the sections
2549  
2550 \begin_inset Quotes eld
2551 \end_inset
2552
2553 Sources
2554 \begin_inset Quotes erd
2555 \end_inset
2556
2557  and 
2558 \begin_inset Quotes eld
2559 \end_inset
2560
2561 Scientific works
2562 \begin_inset Quotes erd
2563 \end_inset
2564
2565 , you first need to create two bibliographic databases, e.
2566 \begin_inset space \thinspace{}
2567 \end_inset
2568
2569 g.
2570 \begin_inset space \space{}
2571 \end_inset
2572
2573
2574 \begin_inset Flex Code
2575 status collapsed
2576
2577 \begin_layout Plain Layout
2578 sources.bib
2579 \end_layout
2580
2581 \end_inset
2582
2583  and 
2584 \begin_inset Flex Code
2585 status collapsed
2586
2587 \begin_layout Plain Layout
2588 scientific.bib
2589 \end_layout
2590
2591 \end_inset
2592
2593 .
2594  
2595 \end_layout
2596
2597 \begin_layout Standard
2598 Go to 
2599 \begin_inset Flex Noun
2600 status collapsed
2601
2602 \begin_layout Plain Layout
2603 Document\SpecialChar menuseparator
2604 Settings
2605 \end_layout
2606
2607 \end_inset
2608
2609  and check under 
2610 \begin_inset Flex Noun
2611 status collapsed
2612
2613 \begin_layout Plain Layout
2614 Bibliography
2615 \end_layout
2616
2617 \end_inset
2618
2619  the option 
2620 \begin_inset Flex Noun
2621 status collapsed
2622
2623 \begin_layout Plain Layout
2624 Subdivided bibliography
2625 \end_layout
2626
2627 \end_inset
2628
2629 .
2630  Now you can insert multiple Bib\SpecialChar TeX
2631  bibliographies, one for each section of
2632  your bibliography.
2633  Returning to our example: Insert the Bib\SpecialChar TeX
2634  bibliography 
2635 \begin_inset Flex Code
2636 status collapsed
2637
2638 \begin_layout Plain Layout
2639 sources.bib
2640 \end_layout
2641
2642 \end_inset
2643
2644  and a second one for the database 
2645 \begin_inset Flex Code
2646 status collapsed
2647
2648 \begin_layout Plain Layout
2649 scientific.bib
2650 \end_layout
2651
2652 \end_inset
2653
2654 .
2655  You are free to use the same or different styles for each section.
2656  Additionally, you can choose if the bibliography section should contain
2657  
2658 \begin_inset Quotes eld
2659 \end_inset
2660
2661 all cited references
2662 \begin_inset Quotes erd
2663 \end_inset
2664
2665  of the specified database(s) (which is the default), 
2666 \begin_inset Quotes eld
2667 \end_inset
2668
2669 all uncited references
2670 \begin_inset Quotes erd
2671 \end_inset
2672
2673  or even 
2674 \begin_inset Quotes eld
2675 \end_inset
2676
2677 all references
2678 \begin_inset Quotes erd
2679 \end_inset
2680
2681 .
2682  This might be useful if you would like to separate your bibliography into
2683  three sections: 
2684 \begin_inset Quotes eld
2685 \end_inset
2686
2687 Cited sources
2688 \begin_inset Quotes erd
2689 \end_inset
2690
2691
2692 \begin_inset Quotes eld
2693 \end_inset
2694
2695 Uncited sources
2696 \begin_inset Quotes erd
2697 \end_inset
2698
2699 , and 
2700 \begin_inset Quotes eld
2701 \end_inset
2702
2703 Scientific works
2704 \begin_inset Quotes erd
2705 \end_inset
2706
2707 .
2708  The titles for the sections can be added as ordinary sections or subsections.
2709  Since 
2710 \begin_inset Flex Code
2711 status collapsed
2712
2713 \begin_layout Plain Layout
2714 bibtopic
2715 \end_layout
2716
2717 \end_inset
2718
2719  removes the bibliography title, you have to manually re-add that, too (as
2720  a chapter* or section*, for instance).
2721 \end_layout
2722
2723 \begin_layout Standard
2724 With 
2725 \family sans
2726 Biblatex
2727 \family default
2728 , the procedure is a bit different.
2729  Since 
2730 \family typewriter
2731 bibtopic
2732 \family default
2733  does not work with 
2734 \family sans
2735 Biblatex
2736 \family default
2737 , the aforementioned 
2738 \begin_inset Flex Noun
2739 status collapsed
2740
2741 \begin_layout Plain Layout
2742 Subdivided bibliography
2743 \end_layout
2744
2745 \end_inset
2746
2747  option is disabled if you use 
2748 \family sans
2749 Biblatex
2750 \family default
2751 .
2752  However, 
2753 \family sans
2754 Biblatex
2755 \family default
2756  provides its own means to generate subdivided bibliographies.
2757  You can either add keywords to bibliography entries via the 
2758 \begin_inset Flex Code
2759 status collapsed
2760
2761 \begin_layout Plain Layout
2762 keywords
2763 \end_layout
2764
2765 \end_inset
2766
2767  entry option and then filter bibliography sections by keyword (by adding
2768  
2769 \begin_inset Flex Code
2770 status collapsed
2771
2772 \begin_layout Plain Layout
2773 keyword=mykeyword
2774 \end_layout
2775
2776 \end_inset
2777
2778  to the 
2779 \begin_inset Flex Noun
2780 status collapsed
2781
2782 \begin_layout Plain Layout
2783 Options
2784 \end_layout
2785
2786 \end_inset
2787
2788  field of the dialog that opens if you right-click on the 
2789 \begin_inset Flex Noun
2790 status collapsed
2791
2792 \begin_layout Plain Layout
2793 Biblatex Generated Bibliography
2794 \end_layout
2795
2796 \end_inset
2797
2798  button), or you can filter by entry types (such as 
2799 \emph on
2800 book
2801 \emph default
2802  or 
2803 \emph on
2804 article
2805 \emph default
2806 ) by entering e.
2807 \begin_inset space \thinspace{}
2808 \end_inset
2809
2810 g.
2811  
2812 \begin_inset Flex Code
2813 status collapsed
2814
2815 \begin_layout Plain Layout
2816 type=book
2817 \end_layout
2818
2819 \end_inset
2820
2821  or 
2822 \begin_inset Flex Code
2823 status collapsed
2824
2825 \begin_layout Plain Layout
2826 nottype=collection
2827 \end_layout
2828
2829 \end_inset
2830
2831  to the mentioned 
2832 \begin_inset Flex Noun
2833 status collapsed
2834
2835 \begin_layout Plain Layout
2836 Options
2837 \end_layout
2838
2839 \end_inset
2840
2841  field, or you can create so-called 
2842 \begin_inset Quotes eld
2843 \end_inset
2844
2845 Bibliography Categories
2846 \begin_inset Quotes erd
2847 \end_inset
2848
2849  to which you can assign individual entries.
2850  Please refer to the Biblatex manual, section 
2851 \emph on
2852 Subdivided Bibliographies
2853 \emph default
2854 , for details.
2855 \end_layout
2856
2857 \begin_layout Subsection
2858 Multiple Bibliographies
2859 \end_layout
2860
2861 \begin_layout Standard
2862 Multiple bibliographies, e.
2863 \begin_inset space \thinspace{}
2864 \end_inset
2865
2866 g.
2867 \begin_inset space \space{}
2868 \end_inset
2869
2870 a bibliography for each part, chapter, section, subsection or child (sub-documen
2871 t) of the document, are also supported by \SpecialChar LyX
2872 .
2873  In order to enable it, go to 
2874 \begin_inset Flex Noun
2875 status collapsed
2876
2877 \begin_layout Plain Layout
2878 Document\SpecialChar menuseparator
2879 Settings\SpecialChar menuseparator
2880 Bibliography
2881 \end_layout
2882
2883 \end_inset
2884
2885  and select the relevant unit (e.
2886 \begin_inset space \thinspace{}
2887 \end_inset
2888
2889 g., 
2890 \begin_inset Quotes eld
2891 \end_inset
2892
2893 per section
2894 \begin_inset Quotes erd
2895 \end_inset
2896
2897 ) in the 
2898 \begin_inset Flex Noun
2899 status collapsed
2900
2901 \begin_layout Plain Layout
2902 Multiple Bibliographies
2903 \end_layout
2904
2905 \end_inset
2906
2907  combo box.
2908  Then add a Bib(la)\SpecialChar TeX
2909  bibliography to each unit (e.
2910 \begin_inset space \thinspace{}
2911 \end_inset
2912
2913 g., section) of your document.
2914  In the output, a separate bibliography, containing only the references
2915  done in the current unit is generated.
2916 \end_layout
2917
2918 \begin_layout Standard
2919 If you use Bib\SpecialChar TeX
2920 , either the 
2921 \begin_inset Flex Code
2922 status collapsed
2923
2924 \begin_layout Plain Layout
2925 chapterbib
2926 \end_layout
2927
2928 \end_inset
2929
2930  o
2931 \change_deleted -712698321 1501067466
2932 f
2933 \change_inserted -712698321 1501067466
2934 r
2935 \change_unchanged
2936  the 
2937 \begin_inset Flex Code
2938 status collapsed
2939
2940 \begin_layout Plain Layout
2941 bibtopic
2942 \end_layout
2943
2944 \end_inset
2945
2946  package is used to create multiple bibliographies.
2947  The former package is used if you select 
2948 \begin_inset Quotes eld
2949 \end_inset
2950
2951 per child document
2952 \begin_inset Quotes erd
2953 \end_inset
2954
2955  and do 
2956 \emph on
2957 not
2958 \emph default
2959  check 
2960 \begin_inset Flex Noun
2961 status collapsed
2962
2963 \begin_layout Plain Layout
2964 Sectioned Bibliography
2965 \end_layout
2966
2967 \end_inset
2968
2969 .
2970  In all other cases, 
2971 \begin_inset Flex Code
2972 status collapsed
2973
2974 \begin_layout Plain Layout
2975 bibtopic
2976 \end_layout
2977
2978 \end_inset
2979
2980  is used.
2981 \begin_inset Foot
2982 status collapsed
2983
2984 \begin_layout Plain Layout
2985 An alternative approach, if you are willing to use some 
2986 \begin_inset Flex Noun
2987 status collapsed
2988
2989 \begin_layout Plain Layout
2990 \SpecialChar TeX
2991  Code
2992 \end_layout
2993
2994 \end_inset
2995
2996  (see section
2997 \begin_inset space ~
2998 \end_inset
2999
3000
3001 \begin_inset CommandInset ref
3002 LatexCommand ref
3003 reference "sec:Inserting-TeX-Code"
3004
3005 \end_inset
3006
3007 ), is to use the 
3008 \begin_inset Flex Code
3009 status collapsed
3010
3011 \begin_layout Plain Layout
3012 bibunits
3013 \end_layout
3014
3015 \end_inset
3016
3017  package.
3018 \end_layout
3019
3020 \end_inset
3021
3022  If 
3023 \begin_inset Flex Code
3024 status collapsed
3025
3026 \begin_layout Plain Layout
3027 bibtopic
3028 \end_layout
3029
3030 \end_inset
3031
3032  is used, \SpecialChar LyX
3033  encloses the specified units in 
3034 \begin_inset Flex Code
3035 status collapsed
3036
3037 \begin_layout Plain Layout
3038 bibtopic
3039 \end_layout
3040
3041 \end_inset
3042
3043 's 
3044 \begin_inset Flex Code
3045 status collapsed
3046
3047 \begin_layout Plain Layout
3048
3049 \backslash
3050 begin{btUnit}
3051 \end_layout
3052
3053 \end_inset
3054
3055  and 
3056 \begin_inset Flex Code
3057 status collapsed
3058
3059 \begin_layout Plain Layout
3060
3061 \backslash
3062 end{btUnit}
3063 \end_layout
3064
3065 \end_inset
3066
3067  in order to create the units.
3068  Note that this approach has some limitations.
3069  First, every citation reference has to be inside some 
3070 \begin_inset Flex Code
3071 status collapsed
3072
3073 \begin_layout Plain Layout
3074 btUnit
3075 \end_layout
3076
3077 \end_inset
3078
3079 .
3080  So citations outside a defined unit (e.
3081 \begin_inset space \thinspace{}
3082 \end_inset
3083
3084 g., before the first section if you use 
3085 \begin_inset Quotes eld
3086 \end_inset
3087
3088 by section
3089 \begin_inset Quotes erd
3090 \end_inset
3091
3092 ) will appear as 
3093 \begin_inset Quotes eld
3094 \end_inset
3095
3096 ???
3097 \begin_inset Quotes erd
3098 \end_inset
3099
3100 .
3101  You can also create your own units by entering 
3102 \begin_inset Flex Code
3103 status collapsed
3104
3105 \begin_layout Plain Layout
3106
3107 \backslash
3108 begin{btUnit}
3109 \end_layout
3110
3111 \end_inset
3112
3113  and 
3114 \begin_inset Flex Code
3115 status collapsed
3116
3117 \begin_layout Plain Layout
3118
3119 \backslash
3120 end{btUnit}
3121 \end_layout
3122
3123 \end_inset
3124
3125  as \SpecialChar TeX
3126  code (for instance to work around the mentioned limitation).
3127  Note, though, that 
3128 \begin_inset Flex Code
3129 status collapsed
3130
3131 \begin_layout Plain Layout
3132 btUnit
3133 \end_layout
3134
3135 \end_inset
3136
3137 s cannot be nested.
3138  A second limitation is that 
3139 \begin_inset Flex Code
3140 status collapsed
3141
3142 \begin_layout Plain Layout
3143 bibtopic
3144 \end_layout
3145
3146 \end_inset
3147
3148  always processes all references of a bibliography database, even if they
3149  are not cited.
3150  This can result in odd labels (e.
3151 \begin_inset space \thinspace{}
3152 \end_inset
3153
3154 g.
3155  
3156 \begin_inset Quotes eld
3157 \end_inset
3158
3159 Miller 2014b
3160 \begin_inset Quotes erd
3161 \end_inset
3162
3163  if two works of this author from 2014 are in the database, even if only
3164  one is cited).
3165 \end_layout
3166
3167 \begin_layout Standard
3168 If you use 
3169 \family sans
3170 Biblatex
3171 \family default
3172 , the 
3173 \begin_inset Flex Code
3174 status collapsed
3175
3176 \begin_layout Plain Layout
3177 refsection
3178 \end_layout
3179
3180 \end_inset
3181
3182  option is used instead.
3183  If you need specific units, you can start them with the \SpecialChar TeX
3184  code 
3185 \begin_inset Flex Code
3186 status collapsed
3187
3188 \begin_layout Plain Layout
3189
3190 \backslash
3191 newrefsection
3192 \end_layout
3193
3194 \end_inset
3195
3196  or 
3197 \begin_inset Flex Code
3198 status collapsed
3199
3200 \begin_layout Plain Layout
3201
3202 \backslash
3203 newrefsegment
3204 \end_layout
3205
3206 \end_inset
3207
3208 , respectively.
3209  If you also want to control the end of the unit, use the environment 
3210 \begin_inset Flex Code
3211 status collapsed
3212
3213 \begin_layout Plain Layout
3214
3215 \backslash
3216 begin{refsection}
3217 \end_layout
3218
3219 \end_inset
3220
3221  \SpecialChar ldots
3222  
3223 \begin_inset Flex Code
3224 status collapsed
3225
3226 \begin_layout Plain Layout
3227
3228 \backslash
3229 end{refsection}
3230 \end_layout
3231
3232 \end_inset
3233
3234  instead.
3235  Note, though, that 
3236 \begin_inset Flex Code
3237 status collapsed
3238
3239 \begin_layout Plain Layout
3240 refsection
3241 \end_layout
3242
3243 \end_inset
3244
3245 s cannot be nested.
3246  In addition to the individual bibliography of the current unit, 
3247 \family sans
3248 Biblatex
3249 \family default
3250  also provides an easy way to output all bibliographies, subsequently, at
3251  one place (e.
3252 \begin_inset space \thinspace{}
3253 \end_inset
3254
3255 g., at the end of the document).
3256  Select 
3257 \begin_inset Quotes eld
3258 \end_inset
3259
3260 all reference units
3261 \begin_inset Quotes erd
3262 \end_inset
3263
3264  from the Content combo box of the Bib(la)TeX inset dialog in order to achieve
3265  this.
3266  Please refer to the 
3267 \family sans
3268 Biblatex
3269 \family default
3270  manual for more information on this topic.
3271 \end_layout
3272
3273 \begin_layout Section
3274 Multipart Documents
3275 \end_layout
3276
3277 \begin_layout Subsection
3278 General Operation
3279 \end_layout
3280
3281 \begin_layout Standard
3282 When you are working on a large file with many sections, it is often convenient
3283  to break up the document into several files, or perhaps you have something
3284  where a table may change from time to time, but the preceding text does
3285  not.
3286  In these cases, you should seriously consider using multipart documents.
3287  For example, scientific papers often have five major sections: the introduction
3288 , observations, results, discussion, and conclusion.
3289  Each of these could be its own separate \SpecialChar LyX
3290  file, with one 
3291 \begin_inset Quotes eld
3292 \end_inset
3293
3294 master
3295 \begin_inset Quotes erd
3296 \end_inset
3297
3298  file which contains the title, authors, abstract, references, etc., plus
3299  the five included files.
3300  It is important to note that each of these files is a full \SpecialChar LyX
3301  file which
3302  can be formatted and printed on its own, as well as included in a master
3303  file.
3304  Each of these files must have the same document class, however—don't attempt
3305  to mix book classes with article classes.
3306  You may also include \SpecialChar LaTeX
3307  files; however, these files must not have their own
3308  preamble (i.
3309 \begin_inset space \thinspace{}
3310 \end_inset
3311
3312 e.
3313 \begin_inset space \space{}
3314 \end_inset
3315
3316 everything up to and including the 
3317 \begin_inset Flex Code
3318 status collapsed
3319
3320 \begin_layout Plain Layout
3321
3322 \backslash
3323 begin{document}
3324 \end_layout
3325
3326 \end_inset
3327
3328  line as well as the 
3329 \begin_inset Flex Code
3330 status collapsed
3331
3332 \begin_layout Plain Layout
3333
3334 \backslash
3335 end{document}
3336 \end_layout
3337
3338 \end_inset
3339
3340  line must be deleted) or else errors will be generated when you try to
3341  make a DVI file.
3342 \end_layout
3343
3344 \begin_layout Standard
3345 \SpecialChar LyX
3346  allows you to include files quite easily with 
3347 \begin_inset Flex Noun
3348 status collapsed
3349
3350 \begin_layout Plain Layout
3351 Insert\SpecialChar menuseparator
3352 ChiId
3353 \begin_inset space ~
3354 \end_inset
3355
3356 Document
3357 \end_layout
3358
3359 \end_inset
3360
3361 .
3362  When you click on this selection a small box is inserted into the file
3363  at the current cursor location.
3364  Clicking on the box raises a dialog which allows you to select the file
3365  to be included, and the method of its inclusion.
3366  
3367 \end_layout
3368
3369 \begin_layout Standard
3370 The file selection box should by now be obvious.
3371  The three inclusion methods are 
3372 \begin_inset Quotes eld
3373 \end_inset
3374
3375 include
3376 \begin_inset Quotes erd
3377 \end_inset
3378
3379
3380 \begin_inset Quotes eld
3381 \end_inset
3382
3383 input
3384 \begin_inset Quotes erd
3385 \end_inset
3386
3387 , and 
3388 \begin_inset Quotes eld
3389 \end_inset
3390
3391 verbatim
3392 \begin_inset Quotes erd
3393 \end_inset
3394
3395 .
3396  The difference between 
3397 \begin_inset Quotes eld
3398 \end_inset
3399
3400 include
3401 \begin_inset Quotes erd
3402 \end_inset
3403
3404  and 
3405 \begin_inset Quotes eld
3406 \end_inset
3407
3408 input
3409 \begin_inset Quotes erd
3410 \end_inset
3411
3412  is really only meaningful to \SpecialChar LaTeX
3413 perts, but the practical difference is that
3414  files that are 
3415 \begin_inset Quotes eld
3416 \end_inset
3417
3418 included
3419 \begin_inset Quotes erd
3420 \end_inset
3421
3422  are typeset beginning on a new page, while files that are 
3423 \begin_inset Quotes eld
3424 \end_inset
3425
3426 inputted
3427 \begin_inset Quotes erd
3428 \end_inset
3429
3430  are typeset starting on the current page.
3431 \end_layout
3432
3433 \begin_layout Standard
3434 Generally, the master file is converted into a full \SpecialChar LaTeX
3435  file before typesetting,
3436  while the included files are converted to \SpecialChar LaTeX
3437  files that do not have all the
3438  preamble information.
3439 \end_layout
3440
3441 \begin_layout Standard
3442
3443 \begin_inset Quotes eld
3444 \end_inset
3445
3446 verbatim
3447 \begin_inset Quotes erd
3448 \end_inset
3449
3450  included file allows you to include a file typeset exactly as it appears
3451  in the file, i.
3452 \begin_inset space \thinspace{}
3453 \end_inset
3454
3455 e.
3456 \begin_inset space \space{}
3457 \end_inset
3458
3459 in 
3460 \begin_inset Flex Code
3461 status collapsed
3462
3463 \begin_layout Plain Layout
3464 verbatim
3465 \end_layout
3466
3467 \end_inset
3468
3469  mode, with the characters set in a fixed-width typewriter font.
3470  Normally, spaces in this file are invisible, though two consecutive spaces
3471  are conserved, unlike \SpecialChar LyX
3472 's normal treatment of spaces.
3473  However, setting the 
3474 \begin_inset Flex Noun
3475 status collapsed
3476
3477 \begin_layout Plain Layout
3478 Mark
3479 \begin_inset space ~
3480 \end_inset
3481
3482 spaces
3483 \begin_inset space ~
3484 \end_inset
3485
3486 in
3487 \begin_inset space ~
3488 \end_inset
3489
3490 output
3491 \end_layout
3492
3493 \end_inset
3494
3495  checkbox typesets a mark to unambiguously define the presence of a space.
3496  
3497 \end_layout
3498
3499 \begin_layout Subsection
3500 Cross-References Between Files
3501 \end_layout
3502
3503 \begin_layout Standard
3504 \begin_inset Box Shadowbox
3505 position "t"
3506 hor_pos "c"
3507 has_inner_box 1
3508 inner_pos "t"
3509 use_parbox 0
3510 use_makebox 0
3511 width "100col%"
3512 special "none"
3513 height "1in"
3514 height_special "totalheight"
3515 thickness "0.4pt"
3516 separation "3pt"
3517 shadowsize "4pt"
3518 framecolor "black"
3519 backgroundcolor "none"
3520 status open
3521
3522 \begin_layout Plain Layout
3523 This section is somewhat out of date.
3524  Need to describe default master documents and how children are opened when
3525  the master is.
3526  [[FIXME]]
3527 \end_layout
3528
3529 \end_inset
3530
3531
3532 \end_layout
3533
3534 \begin_layout Standard
3535 It is possible to set up cross-references between the different files.
3536  First, open all the files in question: let's call them A and B in a two
3537  file example, where B is included in A.
3538  Let's say you insert a label in A, then want to reference it in B.
3539  Open the cross-reference dialog whilst in document B, and you can select
3540  the 
3541 \begin_inset Quotes eld
3542 \end_inset
3543
3544 buffer
3545 \begin_inset Quotes erd
3546 \end_inset
3547
3548  to use.
3549 \end_layout
3550
3551 \begin_layout Subsection
3552 Bibliography Lists in all Subdocuments
3553 \end_layout
3554
3555 \begin_layout Standard
3556 \begin_inset Box Frameless
3557 position "t"
3558 hor_pos "c"
3559 has_inner_box 1
3560 inner_pos "t"
3561 use_parbox 0
3562 use_makebox 0
3563 width "100col%"
3564 special "none"
3565 height "1in"
3566 height_special "totalheight"
3567 thickness "0.4pt"
3568 separation "3pt"
3569 shadowsize "4pt"
3570 framecolor "black"
3571 backgroundcolor "none"
3572 status open
3573
3574 \begin_layout Plain Layout
3575 This section also needs updating.
3576  There is now material about this on the wiki, and it could be copied here.
3577 \end_layout
3578
3579 \end_inset
3580
3581
3582 \end_layout
3583
3584 \begin_layout Standard
3585 Copy the bibliography list with all entries to all subdocuments and transform
3586  them to a comment.
3587  This way \SpecialChar LyX
3588  will find the 
3589 \begin_inset Flex Code
3590 status collapsed
3591
3592 \begin_layout Plain Layout
3593 .bib
3594 \end_layout
3595
3596 \end_inset
3597
3598 -files and you can easily insert references without making the bibliography
3599  list visible.
3600 \end_layout
3601
3602 \begin_layout Standard
3603 As the bibliography list is in a comment, \SpecialChar LaTeX
3604  won't use it and the references
3605  will look like this: [?], instead of like this: [1].
3606  One solution is to use the \SpecialChar LaTeX
3607 -package 
3608 \begin_inset Flex Code
3609 status collapsed
3610
3611 \begin_layout Plain Layout
3612 comment
3613 \end_layout
3614
3615 \end_inset
3616
3617  that will only include comments by processing the files separately.
3618  To do this, add in the \SpecialChar LaTeX
3619  preamble of every subdocument the following:
3620 \end_layout
3621
3622 \begin_layout LyX-Code
3623
3624 \backslash
3625 usepackage{comment}
3626 \end_layout
3627
3628 \begin_layout LyX-Code
3629
3630 \backslash
3631 includecomment{comment}
3632 \end_layout
3633
3634 \begin_layout Standard
3635 See also 
3636 \begin_inset Flex URL
3637 status collapsed
3638
3639 \begin_layout Plain Layout
3640
3641 http://wiki.lyx.org/FAQ/Unsorted#toc31
3642 \end_layout
3643
3644 \end_inset
3645
3646 .
3647 \end_layout
3648
3649 \begin_layout Section
3650 \SpecialChar LyX
3651  Archives
3652 \end_layout
3653
3654 \begin_layout Standard
3655 Users sometimes need to be able to 
3656 \begin_inset Quotes eld
3657 \end_inset
3658
3659 bundle
3660 \begin_inset Quotes erd
3661 \end_inset
3662
3663  a \SpecialChar LyX
3664  file together with all the images (and other files) on which it depends,
3665  either for sending to a publisher or for sharing with a co-author.
3666  \SpecialChar LyX
3667  2.0 includes a Python script (
3668 \begin_inset Flex Code
3669 status collapsed
3670
3671 \begin_layout Plain Layout
3672 lyxpak.py
3673 \end_layout
3674
3675 \end_inset
3676
3677 ) that automates this process.
3678  To use it, you must have either the 
3679 \begin_inset Flex Code
3680 status collapsed
3681
3682 \begin_layout Plain Layout
3683 zipfile
3684 \end_layout
3685
3686 \end_inset
3687
3688  or 
3689 \begin_inset Flex Code
3690 status collapsed
3691
3692 \begin_layout Plain Layout
3693 tarfile
3694 \end_layout
3695
3696 \end_inset
3697
3698  python modules installed on your system.
3699  By default, the script prefers the 
3700 \begin_inset Flex Code
3701 status collapsed
3702
3703 \begin_layout Plain Layout
3704 gzip
3705 \end_layout
3706
3707 \end_inset
3708
3709 -compressed 
3710 \begin_inset Flex Code
3711 status collapsed
3712
3713 \begin_layout Plain Layout
3714 tar
3715 \end_layout
3716
3717 \end_inset
3718
3719  format on Unix-like systems and the 
3720 \begin_inset Flex Code
3721 status collapsed
3722
3723 \begin_layout Plain Layout
3724 zip
3725 \end_layout
3726
3727 \end_inset
3728
3729  format on Windows.
3730 \end_layout
3731
3732 \begin_layout Standard
3733 \SpecialChar LyX
3734 's configuration process will set the script up to export a `\SpecialChar LyX
3735  Archive',
3736  and this format will then be available under 
3737 \begin_inset Flex Code
3738 status collapsed
3739
3740 \begin_layout Plain Layout
3741 File\SpecialChar menuseparator
3742 Export
3743 \end_layout
3744
3745 \end_inset
3746
3747 .
3748 \end_layout
3749
3750 \begin_layout Standard
3751 Independently of the platform, the generation of a particular archive format
3752  can be forced by adding either the 
3753 \begin_inset Flex Code
3754 status collapsed
3755
3756 \begin_layout Plain Layout
3757 -t
3758 \end_layout
3759
3760 \end_inset
3761
3762  (for the 
3763 \begin_inset Flex Code
3764 status collapsed
3765
3766 \begin_layout Plain Layout
3767 tar
3768 \end_layout
3769
3770 \end_inset
3771
3772  format) or 
3773 \begin_inset Flex Code
3774 status collapsed
3775
3776 \begin_layout Plain Layout
3777 -z
3778 \end_layout
3779
3780 \end_inset
3781
3782  (for the 
3783 \begin_inset Flex Code
3784 status collapsed
3785
3786 \begin_layout Plain Layout
3787 zip
3788 \end_layout
3789
3790 \end_inset
3791
3792  format) switch to the 
3793 \begin_inset Flex Code
3794 status collapsed
3795
3796 \begin_layout Plain Layout
3797 \SpecialChar LyX
3798 \SpecialChar menuseparator
3799 \SpecialChar LyX
3800  Archive
3801 \end_layout
3802
3803 \end_inset
3804
3805  converter in 
3806 \begin_inset Flex Code
3807 status collapsed
3808
3809 \begin_layout Plain Layout
3810 Tools\SpecialChar menuseparator
3811 Preferences\SpecialChar menuseparator
3812 File Handling\SpecialChar menuseparator
3813 Converters
3814 \end_layout
3815
3816 \end_inset
3817
3818 .
3819  (Make sure you add the switch after the script name, not before it.)
3820 \end_layout
3821
3822 \begin_layout Section
3823 Fancy Headers and Footers
3824 \end_layout
3825
3826 \begin_layout Standard
3827 The default page layout is rather plain; for an 
3828 \begin_inset Flex Code
3829 status collapsed
3830
3831 \begin_layout Plain Layout
3832 article
3833 \end_layout
3834
3835 \end_inset
3836
3837  document class, all you get is a centered page number at the bottom of
3838  the page.
3839  This document uses KOMA-script's book class, so it appears to be a bit
3840  fancier.
3841  But to really put on a show, you need to set the document page style to
3842  
3843 \begin_inset Quotes eld
3844 \end_inset
3845
3846 fancy
3847 \begin_inset Quotes erd
3848 \end_inset
3849
3850 , as mentioned in the 
3851 \emph on
3852 User Guide
3853 \emph default
3854 .
3855  This section describes the \SpecialChar LaTeX
3856  code you need to insert in your \SpecialChar LaTeX
3857  preamble in
3858  order to get the desired effects.
3859 \end_layout
3860
3861 \begin_layout Standard
3862 For more information on fancy headers, see the 
3863 \begin_inset Flex Code
3864 status collapsed
3865
3866 \begin_layout Plain Layout
3867 fancyhdr
3868 \end_layout
3869
3870 \end_inset
3871
3872  package documentation.
3873  (
3874 \begin_inset Flex URL
3875 status collapsed
3876
3877 \begin_layout Plain Layout
3878
3879 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
3880 \end_layout
3881
3882 \end_inset
3883
3884 )
3885 \end_layout
3886
3887 \begin_layout Standard
3888 The page header is divided into three fields, not surprisingly labeled 
3889 \begin_inset Quotes eld
3890 \end_inset
3891
3892 left
3893 \begin_inset Quotes erd
3894 \end_inset
3895
3896
3897 \begin_inset Quotes eld
3898 \end_inset
3899
3900 center
3901 \begin_inset Quotes erd
3902 \end_inset
3903
3904 , and 
3905 \begin_inset Quotes eld
3906 \end_inset
3907
3908 right
3909 \begin_inset Quotes erd
3910 \end_inset
3911
3912 .
3913  The footer is also divided into these three fields.
3914  The \SpecialChar LaTeX
3915  commands to set these fields in the simplest manner are 
3916 \begin_inset Flex Code
3917 status collapsed
3918
3919 \begin_layout Plain Layout
3920
3921 \backslash
3922 lhead
3923 \end_layout
3924
3925 \end_inset
3926
3927
3928 \begin_inset Flex Code
3929 status collapsed
3930
3931 \begin_layout Plain Layout
3932
3933 \backslash
3934 chead
3935 \end_layout
3936
3937 \end_inset
3938
3939
3940 \begin_inset Flex Code
3941 status collapsed
3942
3943 \begin_layout Plain Layout
3944
3945 \backslash
3946 rhead
3947 \end_layout
3948
3949 \end_inset
3950
3951
3952 \begin_inset Flex Code
3953 status collapsed
3954
3955 \begin_layout Plain Layout
3956
3957 \backslash
3958 lfoot
3959 \end_layout
3960
3961 \end_inset
3962
3963 , etc.
3964  Suppose you wish to put your name in the upper left hand corner of each
3965  page.
3966  Simply insert the following command in the preamble: 
3967 \end_layout
3968
3969 \begin_layout Standard
3970
3971 \family typewriter
3972
3973 \backslash
3974 lhead{John Q.
3975  DocWriter}
3976 \end_layout
3977
3978 \begin_layout Standard
3979 You will now see your name in the upper left.
3980  If a field has a default entry that you would like to get rid of (often
3981  the page number appears in the central footer) simply include a command
3982  with a blank argument, e.
3983 \begin_inset space \thinspace{}
3984 \end_inset
3985
3986 g.:
3987 \end_layout
3988
3989 \begin_layout Standard
3990
3991 \family typewriter
3992
3993 \backslash
3994 cfoot{}
3995 \end_layout
3996
3997 \begin_layout Standard
3998 Let's get really fancy: lets put the section number with the word 
3999 \begin_inset Quotes eld
4000 \end_inset
4001
4002 Section
4003 \begin_inset Quotes erd
4004 \end_inset
4005
4006  (e.
4007 \begin_inset space \thinspace{}
4008 \end_inset
4009
4010 g.
4011 \begin_inset space \space{}
4012 \end_inset
4013
4014 Section 3) in the upper left, the page number (e.
4015 \begin_inset space \thinspace{}
4016 \end_inset
4017
4018 g.
4019 \begin_inset space \space{}
4020 \end_inset
4021
4022 Page 4) in the upper right, your name in the lower left, and the date in
4023  the lower right.
4024  The following commands should now appear in the preamble:
4025 \end_layout
4026
4027 \begin_layout Standard
4028
4029 \family typewriter
4030
4031 \backslash
4032 lhead{Section 
4033 \backslash
4034 thesection}
4035 \end_layout
4036
4037 \begin_layout Standard
4038
4039 \family typewriter
4040
4041 \backslash
4042 chead{}
4043 \end_layout
4044
4045 \begin_layout Standard
4046
4047 \family typewriter
4048
4049 \backslash
4050 rhead{Page 
4051 \backslash
4052 thepage}
4053 \end_layout
4054
4055 \begin_layout Standard
4056
4057 \family typewriter
4058
4059 \backslash
4060 lfoot{John Q.
4061  DocWriter}
4062 \end_layout
4063
4064 \begin_layout Standard
4065
4066 \family typewriter
4067
4068 \backslash
4069 cfoot{}
4070 \end_layout
4071
4072 \begin_layout Standard
4073
4074 \family typewriter
4075
4076 \backslash
4077 rfoot{
4078 \backslash
4079 today}
4080 \end_layout
4081
4082 \begin_layout Standard
4083 The commands 
4084 \begin_inset Flex Code
4085 status collapsed
4086
4087 \begin_layout Plain Layout
4088
4089 \backslash
4090 thesection
4091 \end_layout
4092
4093 \end_inset
4094
4095  and 
4096 \begin_inset Flex Code
4097 status collapsed
4098
4099 \begin_layout Plain Layout
4100
4101 \backslash
4102 thepage
4103 \end_layout
4104
4105 \end_inset
4106
4107  access \SpecialChar LaTeX
4108 's section and page counters, and so print out the current section
4109  and page numbers.
4110  
4111 \begin_inset Flex Code
4112 status collapsed
4113
4114 \begin_layout Plain Layout
4115
4116 \backslash
4117 today
4118 \end_layout
4119
4120 \end_inset
4121
4122  simply prints out today's date.
4123 \end_layout
4124
4125 \begin_layout Standard
4126 The thicknesses of the horizontal rules drawn beneath the header and above
4127  the footer can also be modified.
4128  If you don't want one of the rules, set its thickness to 0.
4129  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
4130  Use commands
4131 \family typewriter
4132  
4133 \family default
4134 like 
4135 \begin_inset Flex Code
4136 status collapsed
4137
4138 \begin_layout Plain Layout
4139
4140 \backslash
4141 renewcommand{
4142 \backslash
4143 headrulewidth}{0.4pt}
4144 \end_layout
4145
4146 \end_inset
4147
4148  and 
4149 \begin_inset Flex Code
4150 status collapsed
4151
4152 \begin_layout Plain Layout
4153
4154 \backslash
4155 renewcommand{
4156 \backslash
4157 footrulewidth}{0.4pt}
4158 \end_layout
4159
4160 \end_inset
4161
4162  to set the thicknesses.
4163 \end_layout
4164
4165 \begin_layout Standard
4166 You can switch the header/footer settings on and off for individual pages
4167  using commands like 
4168 \begin_inset Flex Code
4169 status collapsed
4170
4171 \begin_layout Plain Layout
4172
4173 \backslash
4174 thispagestyle{empty}
4175 \end_layout
4176
4177 \end_inset
4178
4179
4180 \begin_inset Flex Code
4181 status collapsed
4182
4183 \begin_layout Plain Layout
4184
4185 \backslash
4186 thispagestyle{plain}
4187 \end_layout
4188
4189 \end_inset
4190
4191 , and 
4192 \begin_inset Flex Code
4193 status collapsed
4194
4195 \begin_layout Plain Layout
4196
4197 \backslash
4198 thispagestyle{fancy}
4199 \end_layout
4200
4201 \end_inset
4202
4203 .
4204  Simply insert them in the text on the page you want changed and mark them
4205  as \SpecialChar TeX
4206  code.
4207  In fact, title pages are marked as plain by default, while following pages
4208  are marked fancy when using the global fancy setting.
4209 \end_layout
4210
4211 \begin_layout Standard
4212 As a final example, it is possible to include an image in the header or
4213  footer.
4214  Suppose you want to put a company logo in the upper lefthand corner.
4215  You might try something like
4216 \end_layout
4217
4218 \begin_layout Standard
4219
4220 \family typewriter
4221
4222 \backslash
4223 lhead{
4224 \backslash
4225 resizebox{1in}{!}{
4226 \backslash
4227 includegraphics{logo.eps}}}
4228 \end_layout
4229
4230 \begin_layout Standard
4231 \noindent
4232 (you may need to preface this with 
4233 \begin_inset Flex Code
4234 status collapsed
4235
4236 \begin_layout Plain Layout
4237 \noindent
4238
4239 \backslash
4240 usepackage{graphics}
4241 \end_layout
4242
4243 \end_inset
4244
4245  if you don't include graphics elsewhere in your document).
4246 \end_layout
4247
4248 \begin_layout Section
4249 Itemize Bullet Selection
4250 \begin_inset CommandInset label
4251 LatexCommand label
4252 name "sec:bullet"
4253
4254 \end_inset
4255
4256
4257 \end_layout
4258
4259 \begin_layout Standard
4260 by
4261 \noun on
4262  Allan Rae
4263 \end_layout
4264
4265 \begin_layout Subsection
4266 Introduction
4267 \end_layout
4268
4269 \begin_layout Standard
4270 \SpecialChar LyX
4271  provides 216 bullet shapes that can be accessed from a simple dialog.
4272  Using this dialog you can easily specify what bullet shape to use at each
4273  level of an itemized list.
4274  These settings are document-wide so you won't be able to specify different
4275  sets of bullets for different paragraphs.
4276 \begin_inset Foot
4277 status collapsed
4278
4279 \begin_layout Plain Layout
4280 Well, actually you can but you'll have to do it by hand.
4281 \end_layout
4282
4283 \end_inset
4284
4285
4286 \end_layout
4287
4288 \begin_layout Subsection
4289 How it looks
4290 \end_layout
4291
4292 \begin_layout Standard
4293 Open the dialog by selecting the 
4294 \begin_inset Flex Noun
4295 status collapsed
4296
4297 \begin_layout Plain Layout
4298 Document\SpecialChar menuseparator
4299 Settings
4300 \end_layout
4301
4302 \end_inset
4303
4304  menu item and then select the 
4305 \begin_inset Flex Noun
4306 status collapsed
4307
4308 \begin_layout Plain Layout
4309 Bullets
4310 \end_layout
4311
4312 \end_inset
4313
4314  tab.
4315 \end_layout
4316
4317 \begin_layout Standard
4318 The dialog provides you with a table of bullet shapes.
4319  A column of buttons on the left of the table provides access to the six
4320  different panels of bullet shapes.
4321  The row of buttons across the top is used to select which bullet depth
4322  you are changing.
4323  A text entry under the table shows the currently selected bullet shape's
4324  \SpecialChar LaTeX
4325  equivalent and this can be edited if desired.
4326  If you do modify the text you will also need to specify any needed packages
4327  in the \SpecialChar LaTeX
4328  preamble.
4329 \end_layout
4330
4331 \begin_layout Standard
4332 The six panels are divided up by the packages they require.
4333  The following table shows the mappings from button name to \SpecialChar LaTeX
4334  package.
4335 \end_layout
4336
4337 \begin_layout Standard
4338 \align center
4339 \begin_inset Tabular
4340 <lyxtabular version="3" rows="7" columns="2">
4341 <features tabularvalignment="middle">
4342 <column alignment="center" valignment="top" width="0pt">
4343 <column alignment="center" valignment="top" width="0pt">
4344 <row>
4345 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4346 \begin_inset Text
4347
4348 \begin_layout Plain Layout
4349
4350 \family roman
4351 \series medium
4352 \shape up
4353 \size normal
4354 \emph off
4355 \bar no
4356 \noun off
4357 \color none
4358 Button
4359 \end_layout
4360
4361 \end_inset
4362 </cell>
4363 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4364 \begin_inset Text
4365
4366 \begin_layout Plain Layout
4367
4368 \family roman
4369 \series medium
4370 \shape up
4371 \size normal
4372 \emph off
4373 \bar no
4374 \noun off
4375 \color none
4376 Packages Required
4377 \end_layout
4378
4379 \end_inset
4380 </cell>
4381 </row>
4382 <row>
4383 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4384 \begin_inset Text
4385
4386 \begin_layout Plain Layout
4387
4388 \family sans
4389 \series medium
4390 \shape up
4391 \size normal
4392 \emph off
4393 \bar no
4394 \noun off
4395 \color none
4396 Standard
4397 \end_layout
4398
4399 \end_inset
4400 </cell>
4401 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4402 \begin_inset Text
4403
4404 \begin_layout Plain Layout
4405
4406 \series medium
4407 \shape up
4408 \size normal
4409 \emph off
4410 \bar no
4411 \noun off
4412 \color none
4413 base \SpecialChar LaTeX
4414
4415 \end_layout
4416
4417 \end_inset
4418 </cell>
4419 </row>
4420 <row>
4421 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4422 \begin_inset Text
4423
4424 \begin_layout Plain Layout
4425
4426 \family sans
4427 \series medium
4428 \shape up
4429 \size normal
4430 \emph off
4431 \bar no
4432 \noun off
4433 \color none
4434 Maths
4435 \end_layout
4436
4437 \end_inset
4438 </cell>
4439 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4440 \begin_inset Text
4441
4442 \begin_layout Plain Layout
4443
4444 \family typewriter
4445 \series medium
4446 \shape up
4447 \size normal
4448 \emph off
4449 \bar no
4450 \noun off
4451 \color none
4452 amssymb.sty
4453 \end_layout
4454
4455 \end_inset
4456 </cell>
4457 </row>
4458 <row>
4459 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4460 \begin_inset Text
4461
4462 \begin_layout Plain Layout
4463
4464 \family sans
4465 \series medium
4466 \shape up
4467 \size normal
4468 \emph off
4469 \bar no
4470 \noun off
4471 \color none
4472 Ding1
4473 \end_layout
4474
4475 \end_inset
4476 </cell>
4477 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4478 \begin_inset Text
4479
4480 \begin_layout Plain Layout
4481
4482 \family typewriter
4483 \series medium
4484 \shape up
4485 \size normal
4486 \emph off
4487 \bar no
4488 \noun off
4489 \color none
4490 pifont.sty
4491 \end_layout
4492
4493 \end_inset
4494 </cell>
4495 </row>
4496 <row>
4497 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4498 \begin_inset Text
4499
4500 \begin_layout Plain Layout
4501
4502 \family sans
4503 \series medium
4504 \shape up
4505 \size normal
4506 \emph off
4507 \bar no
4508 \noun off
4509 \color none
4510 Ding2
4511 \end_layout
4512
4513 \end_inset
4514 </cell>
4515 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4516 \begin_inset Text
4517
4518 \begin_layout Plain Layout
4519
4520 \family typewriter
4521 \series medium
4522 \shape up
4523 \size normal
4524 \emph off
4525 \bar no
4526 \noun off
4527 \color none
4528 pifont.sty
4529 \end_layout
4530
4531 \end_inset
4532 </cell>
4533 </row>
4534 <row>
4535 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4536 \begin_inset Text
4537
4538 \begin_layout Plain Layout
4539
4540 \family sans
4541 \series medium
4542 \shape up
4543 \size normal
4544 \emph off
4545 \bar no
4546 \noun off
4547 \color none
4548 Ding3
4549 \end_layout
4550
4551 \end_inset
4552 </cell>
4553 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4554 \begin_inset Text
4555
4556 \begin_layout Plain Layout
4557
4558 \family typewriter
4559 \series medium
4560 \shape up
4561 \size normal
4562 \emph off
4563 \bar no
4564 \noun off
4565 \color none
4566 pifont.sty
4567 \end_layout
4568
4569 \end_inset
4570 </cell>
4571 </row>
4572 <row>
4573 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4574 \begin_inset Text
4575
4576 \begin_layout Plain Layout
4577
4578 \family sans
4579 \series medium
4580 \shape up
4581 \size normal
4582 \emph off
4583 \bar no
4584 \noun off
4585 \color none
4586 Ding4
4587 \end_layout
4588
4589 \end_inset
4590 </cell>
4591 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4592 \begin_inset Text
4593
4594 \begin_layout Plain Layout
4595
4596 \family typewriter
4597 \series medium
4598 \shape up
4599 \size normal
4600 \emph off
4601 \bar no
4602 \noun off
4603 \color none
4604 pifont.sty
4605 \end_layout
4606
4607 \end_inset
4608 </cell>
4609 </row>
4610 </lyxtabular>
4611
4612 \end_inset
4613
4614
4615 \end_layout
4616
4617 \begin_layout Standard
4618 \SpecialChar LyX
4619  doesn't stop you using bullets from packages you don't have.
4620  If you get errors from \SpecialChar LaTeX
4621  when you try to view or print the file, then it
4622  is likely you are missing a package.
4623 \begin_inset Foot
4624 status collapsed
4625
4626 \begin_layout Plain Layout
4627 \SpecialChar LyX
4628  doesn't restrict your use since you may be editing locally and exporting
4629  elsewhere.
4630 \end_layout
4631
4632 \end_inset
4633
4634
4635 \end_layout
4636
4637 \begin_layout Subsection
4638 How to use it
4639 \end_layout
4640
4641 \begin_layout Standard
4642 Select which bullet depth you want to change then select the bullet shape
4643  and size.
4644  Any changes will not be visible in \SpecialChar LyX
4645 , but are visible when viewing the document.
4646 \end_layout
4647
4648 \begin_layout Standard
4649 You can reset a bullet shape to the default simply by clicking your right
4650  mouse button on the appropriate bullet depth button.
4651 \begin_inset Foot
4652 status collapsed
4653
4654 \begin_layout Plain Layout
4655 If you 
4656 \emph on
4657 really
4658 \emph default
4659  want to have multiple sets of paragraphs with different sets of bullets
4660  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
4661  code.
4662  The bullet selection dialog can help though because it provides you with
4663  the \SpecialChar LaTeX
4664  code for a wide range of bullet shapes.
4665  To make your own custom paragraphs you have the following options:
4666 \end_layout
4667
4668 \begin_layout Plain Layout
4669 \begin_inset ERT
4670 status open
4671
4672 \begin_layout Plain Layout
4673
4674
4675 \backslash
4676 let
4677 \backslash
4678 savelabelitemi=
4679 \backslash
4680 labelitemi
4681 \end_layout
4682
4683 \end_inset
4684
4685
4686 \end_layout
4687
4688 \begin_layout Plain Layout
4689 \begin_inset ERT
4690 status open
4691
4692 \begin_layout Plain Layout
4693
4694
4695 \backslash
4696 renewcommand
4697 \backslash
4698 labelitemi[0]{
4699 \backslash
4700 small
4701 \backslash
4702 (
4703 \backslash
4704 sharp
4705 \backslash
4706 )}
4707 \end_layout
4708
4709 \end_inset
4710
4711
4712 \end_layout
4713
4714 \begin_layout Itemize
4715 Use the \SpecialChar LaTeX
4716  command 
4717 \begin_inset Flex Code
4718 status collapsed
4719
4720 \begin_layout Plain Layout
4721
4722 \backslash
4723 renewcommand{}{}
4724 \end_layout
4725
4726 \end_inset
4727
4728  to specify a new bullet shape for a given depth.
4729  You'll also need to save the current bullet shape so you can restore it
4730  again afterwards.
4731  In this itemized list the following \SpecialChar LaTeX
4732  code was used to change the bullet
4733  used for the first depth.
4734 \end_layout
4735
4736 \begin_deeper
4737 \begin_layout LyX-Code
4738
4739 \backslash
4740 let
4741 \backslash
4742 savelabelitemi=
4743 \backslash
4744 labelitemi 
4745 \end_layout
4746
4747 \begin_layout LyX-Code
4748
4749 \backslash
4750 renewcommand
4751 \backslash
4752 labelitemi[0]{
4753 \backslash
4754 small
4755 \backslash
4756 (
4757 \backslash
4758 sharp
4759 \backslash
4760 )}
4761 \end_layout
4762
4763 \end_deeper
4764 \begin_layout Itemize
4765 Note that the itemize depth is specified in Roman numerals as part of the
4766  
4767 \family typewriter
4768
4769 \backslash
4770 labelitem
4771 \family default
4772  command.
4773 \end_layout
4774
4775 \begin_layout Itemize
4776 \begin_inset ERT
4777 status open
4778
4779 \begin_layout Plain Layout
4780
4781 [
4782 \backslash
4783 (
4784 \backslash
4785 star
4786 \backslash
4787 )]
4788 \end_layout
4789
4790 \end_inset
4791
4792  Specify each individual entry by starting each item with the bullet shape
4793  enclosed in square brackets and set as 
4794 \begin_inset Flex Noun
4795 status collapsed
4796
4797 \begin_layout Plain Layout
4798 \SpecialChar TeX
4799  Code
4800 \end_layout
4801
4802 \end_inset
4803
4804 .
4805  For example, this item was started with 
4806 \begin_inset Flex Code
4807 status collapsed
4808
4809 \begin_layout Plain Layout
4810 [
4811 \backslash
4812 (
4813 \backslash
4814 star
4815 \backslash
4816 )]
4817 \end_layout
4818
4819 \end_inset
4820
4821 .
4822 \end_layout
4823
4824 \begin_layout Plain Layout
4825 \begin_inset ERT
4826 status open
4827
4828 \begin_layout Plain Layout
4829
4830
4831 \backslash
4832 renewcommand
4833 \backslash
4834 labelitemi[0]{
4835 \backslash
4836 savelabelitemi}
4837 \end_layout
4838
4839 \end_inset
4840
4841
4842 \end_layout
4843
4844 \begin_layout Plain Layout
4845 You'll also need to revert the labelitem back to its previous setting for
4846  the global bullet shape settings to remain in effect.
4847  The way used here was:
4848 \end_layout
4849
4850 \begin_layout LyX-Code
4851
4852 \backslash
4853 renewcommand
4854 \backslash
4855 labelitemi[0]{
4856 \backslash
4857 savelabelitemi}
4858 \end_layout
4859
4860 \end_inset
4861
4862
4863 \end_layout
4864
4865 \begin_layout Chapter
4866 \SpecialChar LyX
4867  and the World Wide Web
4868 \end_layout
4869
4870 \begin_layout Standard
4871 \SpecialChar LyX
4872  has long supported the export of documents to various web-friendly formats,
4873  such as HTML.
4874  Before vers
4875 \change_inserted -712698321 1501076595
4876 i
4877 \change_unchanged
4878 on 2.0, however, HTML export was always accomplished by the use of external
4879  converters.
4880 \begin_inset Foot
4881 status collapsed
4882
4883 \begin_layout Plain Layout
4884 For details on the use of external converters with \SpecialChar LyX
4885 , see the 
4886 \emph on
4887 Converters
4888 \emph default
4889  section of the Customization manual.
4890 \end_layout
4891
4892 \end_inset
4893
4894  These fall into two large groups: there are converters that use \SpecialChar LaTeX
4895  as an
4896  intermediate format, such as 
4897 \begin_inset Flex Code
4898 status collapsed
4899
4900 \begin_layout Plain Layout
4901 htlatex
4902 \end_layout
4903
4904 \end_inset
4905
4906
4907 \begin_inset Flex Code
4908 status collapsed
4909
4910 \begin_layout Plain Layout
4911 html2latex
4912 \end_layout
4913
4914 \end_inset
4915
4916 , and 
4917 \begin_inset Flex Code
4918 status collapsed
4919
4920 \begin_layout Plain Layout
4921 plastex
4922 \end_layout
4923
4924 \end_inset
4925
4926 , relying upon \SpecialChar LyX
4927  to produce the \SpecialChar LaTeX
4928 ; and there is a converter that works directly
4929  on \SpecialChar LyX
4930  files, 
4931 \begin_inset Flex Code
4932 status collapsed
4933
4934 \begin_layout Plain Layout
4935 e\SpecialChar LyX
4936 er
4937 \end_layout
4938
4939 \end_inset
4940
4941 .
4942  All of these have different advantages and disadvantages.
4943  
4944 \end_layout
4945
4946 \begin_layout Standard
4947 The \SpecialChar LaTeX
4948 -based converters have the advantage that, in principle, they know everythin
4949 g about the exported document that \SpecialChar LaTeX
4950  does.
4951  Such converters do not care, for example, if a certain block of code was
4952  produced by \SpecialChar LyX
4953  or was Evil Red Text.
4954  These converters know about 
4955 \begin_inset Flex Code
4956 status collapsed
4957
4958 \begin_layout Plain Layout
4959 aux
4960 \end_layout
4961
4962 \end_inset
4963
4964  files, counters, and references, and can often make use of the 
4965 \begin_inset Flex Code
4966 status collapsed
4967
4968 \begin_layout Plain Layout
4969 bbl
4970 \end_layout
4971
4972 \end_inset
4973
4974  files generated by Bib\SpecialChar TeX
4975 .
4976  On the other hand, \SpecialChar LaTeX
4977  is a very hard language to parse—it is sometimes said
4978  that only \SpecialChar TeX
4979  itself understands \SpecialChar TeX
4980 —and \SpecialChar LaTeX
4981 -based converters will often choke on
4982  what seem to be quite simple constructs; complex ones can throw them completely
4983 , and as of this writing, for example, the 
4984 \emph on
4985 Embedded Objects
4986 \emph default
4987  manual will not export with 
4988 \begin_inset Flex Code
4989 status collapsed
4990
4991 \begin_layout Plain Layout
4992 htlatex
4993 \end_layout
4994
4995 \end_inset
4996
4997 , though the others will.
4998  The other issue concerns how math is handled.
4999  These converters typically convert the formulae into little pictures that
5000  are then linked from the HTML document.
5001  Since these are actually generated by \SpecialChar LaTeX
5002 , they are accurate.
5003  But they do not scale well, and just getting them to look as if they are
5004  actually meant to be in your document—so that the font sizes seem to be
5005  roughly the same—can be a challenge.
5006 \end_layout
5007
5008 \begin_layout Standard
5009 Alex Fernandez's 
5010 \begin_inset Flex Code
5011 status collapsed
5012
5013 \begin_layout Plain Layout
5014 e\SpecialChar LyX
5015 er
5016 \end_layout
5017
5018 \end_inset
5019
5020  (
5021 \begin_inset CommandInset href
5022 LatexCommand href
5023 name "http://elyxer.nongnu.org/"
5024 target "http://elyxer.nongnu.org/"
5025 literal "false"
5026
5027 \end_inset
5028
5029 ) solves some of these problems.
5030  In particular, the formulae it produces scale perfectly, since it renders
5031  math using a combination of HTML and CSS rather than converting the formulae
5032  to images.
5033  But even moderately complex formula are rendered less well than with 
5034 \begin_inset Flex Code
5035 status collapsed
5036
5037 \begin_layout Plain Layout
5038 htlatex
5039 \end_layout
5040
5041 \end_inset
5042
5043 ; this reflects the limitations of HTML.
5044 \begin_inset Foot
5045 status collapsed
5046
5047 \begin_layout Plain Layout
5048 That said, 
5049 \begin_inset Flex Code
5050 status collapsed
5051
5052 \begin_layout Plain Layout
5053 e\SpecialChar LyX
5054 er
5055 \end_layout
5056
5057 \end_inset
5058
5059  can also use jsMath and MathJax for equations, but this setting is only
5060  available globally and requires one to have access to a server that runs
5061  the backend.
5062 \end_layout
5063
5064 \end_inset
5065
5066  More importantly (as of version 1.1.1, at least), 
5067 \begin_inset Flex Code
5068 status collapsed
5069
5070 \begin_layout Plain Layout
5071 e\SpecialChar LyX
5072 er
5073 \end_layout
5074
5075 \end_inset
5076
5077  has limited support for math macros and no support for user-defined paragraph
5078  or character styles.
5079  These limitations make 
5080 \begin_inset Flex Code
5081 status collapsed
5082
5083 \begin_layout Plain Layout
5084 e\SpecialChar LyX
5085 er
5086 \end_layout
5087
5088 \end_inset
5089
5090  unsuitable for many of the documents \SpecialChar LyX
5091  users produce.
5092  In principle, of course, these problems could be solved, but the \SpecialChar LyX
5093  developers
5094  have decided to follow a different path and have made \SpecialChar LyX
5095  itself capable of
5096  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
5097 , DocBook, and plaintext.
5098 \end_layout
5099
5100 \begin_layout Standard
5101 As of this writing, XHTML output remains under development and should probably
5102  be regarded as 
5103 \begin_inset Quotes eld
5104 \end_inset
5105
5106 experimental
5107 \begin_inset Quotes erd
5108 \end_inset
5109
5110 .
5111 \begin_inset Foot
5112 status collapsed
5113
5114 \begin_layout Plain Layout
5115 The file 
5116 \begin_inset Flex Code
5117 status collapsed
5118
5119 \begin_layout Plain Layout
5120 development/
5121 \change_inserted -712698321 1501078933
5122 HTML/
5123 \change_unchanged
5124 HTML.notes
5125 \end_layout
5126
5127 \end_inset
5128
5129 , which can be found in the \SpecialChar LyX
5130  source tree or 
5131 \begin_inset CommandInset href
5132 LatexCommand href
5133 name "accessed online"
5134 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
5135 literal "false"
5136
5137 \end_inset
5138
5139 , usually contains up-to-date information about the state of XHTML output.
5140  See also the list of XHTML bugs on 
5141 \begin_inset CommandInset href
5142 LatexCommand href
5143 name "the bug tracker"
5144 target "http://www.lyx.org/trac/query?status=reopened&status=assigned&status=new&max=0&component=xhtml+export&order=id&col=id&col=summary&col=reporter&col=keywords&keywords=%21%7Efixedintrunk&desc=1"
5145 literal "false"
5146
5147 \end_inset
5148
5149 .
5150 \end_layout
5151
5152 \end_inset
5153
5154  Still, the developers have chosen this approach because it has several
5155  potential advantages over the other two.
5156 \end_layout
5157
5158 \begin_layout Standard
5159 These advantages are primarily due to the fact that the XHTML output routines,
5160  since they are part of \SpecialChar LyX
5161 , know everything \SpecialChar LyX
5162  knows about the document being
5163  exported.
5164 \begin_inset Foot
5165 status collapsed
5166
5167 \begin_layout Plain Layout
5168 Another advantage is that, since these routines are internal to \SpecialChar LyX
5169 , they are
5170  immune to changes in \SpecialChar LyX
5171 's file format, or to changes in the semantics of
5172  existing insets.
5173 \end_layout
5174
5175 \end_inset
5176
5177  So they know about the table of contents (as displayed in the outline),
5178  about the counters associated with different paragraph styles, and about
5179  user-defined styles.
5180  The XHTML output routines know what \SpecialChar LyX
5181  knows about internationalization,
5182  too, so they will output 
5183 \begin_inset Quotes eld
5184 \end_inset
5185
5186 Chapter 1
5187 \begin_inset Quotes erd
5188 \end_inset
5189
5190  or 
5191 \begin_inset Quotes eld
5192 \end_inset
5193
5194
5195 \lang ngerman
5196 Kapitel
5197 \lang english
5198  1
5199 \begin_inset Quotes erd
5200 \end_inset
5201
5202 , depending upon the language in effect at the time.
5203  
5204 \end_layout
5205
5206 \begin_layout Standard
5207 Quite generally, the output routines know what \SpecialChar LyX
5208  knows about document layout,
5209  that is, about how the document is to be rendered on screen.
5210  We use this information when we output the document as XHTML.
5211  In particular, \SpecialChar LyX
5212  
5213 \emph on
5214 automatically
5215 \emph default
5216  generates CSS style information corresponding to the layout information
5217  it uses to render the document on screen: if section headings are supposed
5218  to be sans-serif and bold as seen in \SpecialChar LyX
5219 , then (by default) they will be sans-seri
5220 f and bold when viewed in a web browser, too.
5221  And this is true not just for pre-defined styles, like Section, but for
5222  any style, including user-defined styles.
5223  Indeed, the XHTML output routines make no distinction between user-defined
5224  paragraph and character styles and \SpecialChar LyX
5225 's own pre-defined styles: in each case,
5226  everything \SpecialChar LyX
5227  knows about the styles is contained in the layout files.
5228  And much the same is true as regards pre-defined textual insets, such as
5229  footnotes, and various custom insets.
5230  
5231 \end_layout
5232
5233 \begin_layout Standard
5234 The result is that XHTML output can be customized and extended in exactly
5235  the same way \SpecialChar LaTeX
5236  output can be customized and extended: through layout files
5237  and modules.
5238  See chapter five of the 
5239 \emph on
5240 Customization 
5241 \emph default
5242 manual for the details.
5243 \end_layout
5244
5245 \begin_layout Standard
5246 The remainder of this chapter contains more detailed information on XHTML
5247  output, its limitations, and ways to work around those limitations.
5248 \end_layout
5249
5250 \begin_layout Section
5251 Math Output in XHTML
5252 \end_layout
5253
5254 \begin_layout Standard
5255 \SpecialChar LyX
5256  offers four choices for how math is rendered.
5257  These have various advantages and disadvantages:
5258 \end_layout
5259
5260 \begin_layout Itemize
5261 MathML
5262 \begin_inset Newline newline
5263 \end_inset
5264
5265 MathML is a dialect of XML designed specifically for mathematics on the
5266  web, and it typically renders very well in browsers that support it.
5267  The disadvantage is that not all browsers support MathML, and support is
5268  not complete even in the Gecko-based browsers, such as Firefox.
5269 \begin_inset Newline newline
5270 \end_inset
5271
5272 If \SpecialChar LyX
5273  is unable to render a formula as MathML—for example, if the formula
5274  uses the 
5275 \begin_inset Flex Code
5276 status collapsed
5277
5278 \begin_layout Plain Layout
5279 xymatrix
5280 \end_layout
5281
5282 \end_inset
5283
5284  package or ERT—then it will instead output the formula as an image.
5285  
5286 \end_layout
5287
5288 \begin_layout Itemize
5289 HTML
5290 \begin_inset Newline newline
5291 \end_inset
5292
5293 As mentioned above, 
5294 \begin_inset Flex Code
5295 status collapsed
5296
5297 \begin_layout Plain Layout
5298 elyxer
5299 \end_layout
5300
5301 \end_inset
5302
5303  outputs math as HTML, styled by CSS.
5304 \begin_inset Foot
5305 status collapsed
5306
5307 \begin_layout Plain Layout
5308 \SpecialChar LyX
5309  has borrowed some of the CSS for its HTML output from 
5310 \begin_inset Flex Code
5311 status collapsed
5312
5313 \begin_layout Plain Layout
5314 elyxer
5315 \end_layout
5316
5317 \end_inset
5318
5319 .
5320 \end_layout
5321
5322 \end_inset
5323
5324  For simple formulae, this can work quite well, though with more complicated
5325  formulae it tends to break down.
5326  Still, this method has the advantage that it is very widely supported and
5327  so it may be appropriate for documents that contain only a little, fairly
5328  simple math.
5329 \begin_inset Newline newline
5330 \end_inset
5331
5332 If Lyx is unable to render a formula as HTML—for example, if the formula
5333  uses the 
5334 \begin_inset Flex Code
5335 status collapsed
5336
5337 \begin_layout Plain Layout
5338 xymatrix
5339 \end_layout
5340
5341 \end_inset
5342
5343  package or ERT—then it will instead output the formula as an image.
5344  
5345 \end_layout
5346
5347 \begin_layout Itemize
5348 Images
5349 \begin_inset Newline newline
5350 \end_inset
5351
5352 Like 
5353 \begin_inset Flex Code
5354 status collapsed
5355
5356 \begin_layout Plain Layout
5357 htlatex
5358 \end_layout
5359
5360 \end_inset
5361
5362 , \SpecialChar LyX
5363  will output formulae as images, the very same images, in fact, that are
5364  used for instant preview.
5365 \begin_inset Foot
5366 status collapsed
5367
5368 \begin_layout Plain Layout
5369 Instant preview does 
5370 \emph on
5371 not 
5372 \emph default
5373 have to be on for images to be output, however.
5374 \end_layout
5375
5376 \end_inset
5377
5378  The advantage to this method is that the images are simply generated by
5379  \SpecialChar LaTeX
5380 , so they are very accurate.
5381  The disadvantage, as mentioned earlier, is that these are bitmapped images,
5382  so they do not scale terribly well, and one cannot copy them, etc.
5383
5384 \change_deleted -712698321 1501075981
5385  (As of this writing, there are also problems about equation numbering.
5386  See 
5387 \begin_inset CommandInset href
5388 LatexCommand href
5389 name "bug 6894"
5390 target "http://www.lyx.org/trac/ticket/6894"
5391 literal "false"
5392
5393 \end_inset
5394
5395 .)
5396 \change_unchanged
5397
5398 \begin_inset Newline newline
5399 \end_inset
5400
5401 The size of the images can be controlled by setting the 
5402 \begin_inset Quotes eld
5403 \end_inset
5404
5405 Math Images Scaling
5406 \begin_inset Quotes erd
5407 \end_inset
5408
5409  parameter under 
5410 \begin_inset Flex Noun
5411 status collapsed
5412
5413 \begin_layout Plain Layout
5414 Document\SpecialChar menuseparator
5415 Settings\SpecialChar menuseparator
5416
5417 \change_deleted -712698321 1501076136
5418 Output
5419 \change_inserted -712698321 1501076137
5420 Formats
5421 \change_unchanged
5422
5423 \end_layout
5424
5425 \end_inset
5426
5427 .
5428 \begin_inset Foot
5429 status collapsed
5430
5431 \begin_layout Plain Layout
5432 For those who want to know, this controls the resolution of the image in
5433  dots per inch and is based upon a default of 75 dpi.
5434 \end_layout
5435
5436 \end_inset
5437
5438
5439 \begin_inset Newline newline
5440 \end_inset
5441
5442 If \SpecialChar LyX
5443  for some reason fails to create an image for a formula (e.g., if a required
5444  \SpecialChar LaTeX
5445  package is not installed), then it will fall back to outputing the raw
5446  \SpecialChar LaTeX
5447 .
5448 \end_layout
5449
5450 \begin_layout Itemize
5451 \SpecialChar LaTeX
5452
5453 \begin_inset Newline newline
5454 \end_inset
5455
5456 Finally, \SpecialChar LyX
5457  will happily output math as \SpecialChar LaTeX
5458 .
5459  As well as being the output of last resort, this method can be used with
5460  such tools as 
5461 \begin_inset CommandInset href
5462 LatexCommand href
5463 name "jsMath"
5464 target "http://www.math.union.edu/~dpvc/jsMath/"
5465 literal "false"
5466
5467 \end_inset
5468
5469 , which uses JavaScript to render \SpecialChar LaTeX
5470  embedded in HTML documents.
5471  \SpecialChar LyX
5472  wraps the \SpecialChar LaTeX
5473  in either a 
5474 \begin_inset Flex Code
5475 status collapsed
5476
5477 \begin_layout Plain Layout
5478 span
5479 \end_layout
5480
5481 \end_inset
5482
5483  (for inline formulas) or 
5484 \begin_inset Flex Code
5485 status collapsed
5486
5487 \begin_layout Plain Layout
5488 div
5489 \end_layout
5490
5491 \end_inset
5492
5493  (for displayed formulas) with 
5494 \begin_inset Flex Code
5495 status collapsed
5496
5497 \begin_layout Plain Layout
5498 class='math'
5499 \end_layout
5500
5501 \end_inset
5502
5503 , as is required for jsMath.
5504 \end_layout
5505
5506 \begin_layout Standard
5507 One of these output methods must be selected under 
5508 \begin_inset Flex Noun
5509 status collapsed
5510
5511 \begin_layout Plain Layout
5512 Document\SpecialChar menuseparator
5513 Settings\SpecialChar menuseparator
5514
5515 \change_deleted -712698321 1501076586
5516 Output
5517 \change_inserted -712698321 1501076587
5518 Formats
5519 \change_unchanged
5520
5521 \end_layout
5522
5523 \end_inset
5524
5525 .
5526  By default, \SpecialChar LyX
5527  outputs MathML.
5528  This is a document-wide setting, therefore.
5529 \end_layout
5530
5531 \begin_layout Standard
5532 Eventually, \SpecialChar LyX
5533  will offer the user the option to select an alternate output
5534  method for a particular inset, say, one that isn't being rendered very
5535  well by MathML.
5536 \begin_inset Foot
5537 status collapsed
5538
5539 \begin_layout Plain Layout
5540 That said, since \SpecialChar LyX
5541  falls back to images if the inset contains ERT, then one
5542  can force output as an image by putting some harmless ERT into the math,
5543  for example: 
5544 \begin_inset Formula $a=b\relax$
5545 \end_inset
5546
5547 .
5548 \end_layout
5549
5550 \end_inset
5551
5552
5553 \end_layout
5554
5555 \begin_layout Section
5556 Bibliography and Citations
5557 \end_layout
5558
5559 \begin_layout Standard
5560 XHTML output fully supports bibliographies and citations.
5561  
5562 \end_layout
5563
5564 \begin_layout Standard
5565 Citation labels are generated by the same machinery that generates \SpecialChar LyX
5566 's on-screen
5567  labels, so the labels will look in the output much as they do in \SpecialChar LyX
5568 , though
5569  better.
5570  If you are using numerical citations, then \SpecialChar LyX
5571  will output numerical labels,
5572  such as [1] or [17], rather than simply showing the citation key in square
5573  brackets, as it does on-screen.
5574  If you are using author-year citations, then \SpecialChar LyX
5575  will add lowercase letters
5576  to the years, just as Bib\SpecialChar TeX
5577  does, if it finds more than one citation for
5578  a given author-year combination.
5579  The labels will be printed with the bibliography entries.
5580  Note that there is, at present, no way to customize the appearance of the
5581  labels, for example, to choose between square brackets and parentheses.
5582 \end_layout
5583
5584 \begin_layout Standard
5585 Bibliography output is handled by the same machinery that handles the presentati
5586 on of reference information in the citation dialog, so you will see in the
5587  XHTML output pretty much what you would see if you were to look at a given
5588  entry in the citation dialog.
5589  The formatting can be customized in your layout file or, preferably, in
5590  a module.
5591  See the 
5592 \emph on
5593 Customization
5594 \emph default
5595  manual for the details.
5596 \end_layout
5597
5598 \begin_layout Standard
5599 The main defect at present is that cross-referenced information is printed
5600  with every entry with which it is associated.
5601  So you can see things like this:
5602 \end_layout
5603
5604 \begin_layout Quote
5605 Jason Stanley, 
5606 \begin_inset Quotes eld
5607 \end_inset
5608
5609 Context and Logical Form
5610 \begin_inset Quotes erd
5611 \end_inset
5612
5613 , in 
5614 \emph on
5615 Language in Context: Selected Essays
5616 \emph default
5617  (Oxford: Oxford University Press, 2007), pp.
5618  30–68.
5619 \end_layout
5620
5621 \begin_layout Quote
5622 Jason Stanley, 
5623 \begin_inset Quotes eld
5624 \end_inset
5625
5626 Semantics in Context
5627 \begin_inset Quotes erd
5628 \end_inset
5629
5630 , in 
5631 \emph on
5632 Language in Context: Selected Essays
5633 \emph default
5634  (Oxford: Oxford University Press, 2007), pp.
5635  201–30.
5636 \end_layout
5637
5638 \begin_layout Standard
5639 This should be fixed before long.
5640 \end_layout
5641
5642 \begin_layout Standard
5643 There is no support at present for sectioned bibliographies.
5644  If you have multiple bibliographies, then \SpecialChar LyX
5645  will print the same bibliography
5646  over and over.
5647 \end_layout
5648
5649 \begin_layout Section
5650 Indexes
5651 \end_layout
5652
5653 \begin_layout Standard
5654 \SpecialChar LyX
5655  will happily export indexes as XHTML, but with certain limitations at the
5656  moment.
5657 \end_layout
5658
5659 \begin_layout Standard
5660 Index export will be most reliable when you do not attempt to use the fancy
5661  constructs that are described in the section on indexes in the 
5662 \emph on
5663 User's Guide
5664 \emph default
5665 .
5666 \begin_inset Foot
5667 status collapsed
5668
5669 \begin_layout Plain Layout
5670 The main issue here is that \SpecialChar LyX
5671  itself does not really handle these.
5672  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
5673 .
5674 \end_layout
5675
5676 \end_inset
5677
5678  We'll describe how they are handled using the subsection headings from
5679  that section.
5680 \end_layout
5681
5682 \begin_layout Itemize
5683 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
5684  makes an effort to support these,
5685  but the entries must be separated by 
5686 \begin_inset Quotes eld
5687 \end_inset
5688
5689  ! 
5690 \begin_inset Quotes erd
5691 \end_inset
5692
5693 , that is, there must be spaces around the exclamation point.
5694  This is because it is otherwise too difficult to check for escaped exclamation
5695  points, ones in math, and so forth.
5696 \end_layout
5697
5698 \begin_layout Itemize
5699 Page Ranges: There is no support at all for page ranges, since these make
5700  no sense with XHMTL.
5701  Instead, you will just get two index entries, one at either end.
5702 \end_layout
5703
5704 \begin_layout Itemize
5705 Cross-referencing: There is no support for cross-referencing.
5706  If \SpecialChar LyX
5707  finds an entry containing the 
5708 \begin_inset Quotes eld
5709 \end_inset
5710
5711 |see\SpecialChar ldots
5712
5713 \begin_inset Quotes erd
5714 \end_inset
5715
5716  construct, it is just dropped, and the rest is treated as an ordinary index
5717  entry.
5718 \end_layout
5719
5720 \begin_layout Itemize
5721 Index Entry Order: \SpecialChar LyX
5722  does support attempts to fix the sorting order.
5723  It will take what is before the first `@' it finds and use that for sorting,
5724  taking what follows the first `@' to be the actual entry.
5725  At present, \SpecialChar LyX
5726  does not check for escaped `@', so do not try to index email
5727  addresses.
5728 \end_layout
5729
5730 \begin_layout Itemize
5731 Index Entry Layout: You can format entries by using the text style dialog,
5732  or by using any other method available within \SpecialChar LyX
5733  itself.
5734  There is no support for constructs like: 
5735 \begin_inset Quotes eld
5736 \end_inset
5737
5738 entry|textbf
5739 \begin_inset Quotes erd
5740 \end_inset
5741
5742 .
5743  Indeed, if \SpecialChar LyX
5744  finds a pipe symbol, `|', in an entry, it will delete it and
5745  everything that follows it.
5746 \end_layout
5747
5748 \begin_layout Itemize
5749 Multiple Indexes: There is no support for multiple indexes.
5750  Rather, all index entries will be printed as one large index.
5751  To avoid our printing several versions of the index, we print only the
5752  main index, so make sure you have one.
5753 \end_layout
5754
5755 \begin_layout Section
5756 Nomenclature and Glossary
5757 \end_layout
5758
5759 \begin_layout Standard
5760 There is at present no support for glossaries.
5761  Adding it would be fairly trivial, and welcome.
5762 \end_layout
5763
5764 \begin_layout Chapter
5765 The \SpecialChar LyX
5766  Server
5767 \end_layout
5768
5769 \begin_layout Section
5770 Introduction
5771 \end_layout
5772
5773 \begin_layout Standard
5774 The `\SpecialChar LyX
5775  server' allows other programs to talk to \SpecialChar LyX
5776 , invoke \SpecialChar LyX
5777  commands, and retrieve
5778  information about the \SpecialChar LyX
5779  internal state.
5780  This is only intended for advanced users, but they should find it useful.
5781  It is by writing to the \SpecialChar LyX
5782  server, for example, that bibliography managers,
5783  such as JabRef, are able to 
5784 \begin_inset Quotes eld
5785 \end_inset
5786
5787 push
5788 \begin_inset Quotes erd
5789 \end_inset
5790
5791  citations to \SpecialChar LyX
5792 .
5793 \end_layout
5794
5795 \begin_layout Section
5796 Starting the \SpecialChar LyX
5797  Server
5798 \end_layout
5799
5800 \begin_layout Standard
5801 The \SpecialChar LyX
5802  server works through the use of a pair of named pipes.
5803  These are usually located in 
5804 \begin_inset Flex Code
5805 status collapsed
5806
5807 \begin_layout Plain Layout
5808 UserDir
5809 \end_layout
5810
5811 \end_inset
5812
5813 , (except on Windows, where 
5814 \emph on
5815 local
5816 \emph default
5817  named pipes are special objects located in 
5818 \begin_inset Flex Code
5819 status collapsed
5820
5821 \begin_layout Plain Layout
5822
5823 \backslash
5824
5825 \backslash
5826 .
5827 \backslash
5828 pipe
5829 \end_layout
5830
5831 \end_inset
5832
5833 ) and have the names 
5834 \begin_inset Quotes eld
5835 \end_inset
5836
5837
5838 \begin_inset Flex Code
5839 status collapsed
5840
5841 \begin_layout Plain Layout
5842 lyxpipe.in
5843 \end_layout
5844
5845 \end_inset
5846
5847
5848 \begin_inset Quotes erd
5849 \end_inset
5850
5851  and 
5852 \begin_inset Quotes eld
5853 \end_inset
5854
5855
5856 \begin_inset Flex Code
5857 status collapsed
5858
5859 \begin_layout Plain Layout
5860 lyxpipe.out
5861 \end_layout
5862
5863 \end_inset
5864
5865
5866 \begin_inset Quotes erd
5867 \end_inset
5868
5869 .
5870  External programs write into 
5871 \begin_inset Flex Code
5872 status collapsed
5873
5874 \begin_layout Plain Layout
5875 lyxpipe.in
5876 \end_layout
5877
5878 \end_inset
5879
5880  and read back data from 
5881 \begin_inset Flex Code
5882 status collapsed
5883
5884 \begin_layout Plain Layout
5885 lyxpipe.out
5886 \end_layout
5887
5888 \end_inset
5889
5890 .
5891  The stem of the pipe names can be defined in the 
5892 \begin_inset Flex Noun
5893 status collapsed
5894
5895 \begin_layout Plain Layout
5896 Tools\SpecialChar menuseparator
5897 Preferences
5898 \end_layout
5899
5900 \end_inset
5901
5902  dialog, for example 
5903 \begin_inset Flex Code
5904 status collapsed
5905
5906 \begin_layout Plain Layout
5907 "/home/myhome/lyxpipe"
5908 \end_layout
5909
5910 \end_inset
5911
5912 , or 
5913 \begin_inset Flex Code
5914 status collapsed
5915
5916 \begin_layout Plain Layout
5917 "
5918 \backslash
5919
5920 \backslash
5921 .
5922 \backslash
5923 pipe
5924 \backslash
5925 lyxpipe"
5926 \end_layout
5927
5928 \end_inset
5929
5930  on Windows (where any working path instead of lyxpipe can be used, for
5931  example 
5932 \begin_inset Flex Code
5933 status collapsed
5934
5935 \begin_layout Plain Layout
5936 "
5937 \backslash
5938
5939 \backslash
5940 .
5941 \backslash
5942 pipe
5943 \backslash
5944 my
5945 \backslash
5946 lyx
5947 \backslash
5948 pipe"
5949 \end_layout
5950
5951 \end_inset
5952
5953  would also work).
5954  You 
5955 \emph on
5956 must
5957 \emph default
5958  configure this manually in order for the server to start.
5959 \end_layout
5960
5961 \begin_layout Standard
5962 \SpecialChar LyX
5963  will add the '
5964 \begin_inset Flex Code
5965 status collapsed
5966
5967 \begin_layout Plain Layout
5968 .in
5969 \end_layout
5970
5971 \end_inset
5972
5973 ' and '
5974 \begin_inset Flex Code
5975 status collapsed
5976
5977 \begin_layout Plain Layout
5978 .out
5979 \end_layout
5980
5981 \end_inset
5982
5983 ' to create the pipes.
5984  If one of the pipes already exists, \SpecialChar LyX
5985  will assume that another \SpecialChar LyX
5986  process
5987  is already running and will not start the server.
5988  On POSIX (Unix like) systems, if for some other reason, an unused 
5989 \begin_inset Quotes eld
5990 \end_inset
5991
5992 stale
5993 \begin_inset Quotes erd
5994 \end_inset
5995
5996  pipe is left in existence when \SpecialChar LyX
5997  closes, then \SpecialChar LyX
5998  will try to delete it.
5999  If this fails for some reason, you will need to delete the pipes manually
6000  and then restart \SpecialChar LyX
6001 .
6002  On Windows, pipes are deleted by the OS on program termination or crash,
6003  so 
6004 \begin_inset Quotes eld
6005 \end_inset
6006
6007 stale
6008 \begin_inset Quotes erd
6009 \end_inset
6010
6011  pipes should not be possible.
6012 \end_layout
6013
6014 \begin_layout Standard
6015 To have several \SpecialChar LyX
6016  processes with servers at the same time, you have to use
6017  different configurations, perhaps by using separate user directories, each
6018  with its own 
6019 \begin_inset Flex Code
6020 status collapsed
6021
6022 \begin_layout Plain Layout
6023 preferences
6024 \end_layout
6025
6026 \end_inset
6027
6028  file, for each process.
6029 \end_layout
6030
6031 \begin_layout Standard
6032 If you are developing a client program, you might find it useful to enable
6033  debugging information from the \SpecialChar LyX
6034  server.
6035  Do this by starting \SpecialChar LyX
6036  as 
6037 \begin_inset Flex Code
6038 status collapsed
6039
6040 \begin_layout Plain Layout
6041 lyx -dbg lyxserver
6042 \end_layout
6043
6044 \end_inset
6045
6046 .
6047 \end_layout
6048
6049 \begin_layout Standard
6050 You can find a complete example client written in C++ in the source distribution
6051  as 
6052 \begin_inset Flex Code
6053 status collapsed
6054
6055 \begin_layout Plain Layout
6056 development/lyxserver/server_monitor.cpp
6057 \end_layout
6058
6059 \end_inset
6060
6061 .
6062 \end_layout
6063
6064 \begin_layout Standard
6065 Another useful tool is the command-line based client found in 
6066 \begin_inset Flex Code
6067 status collapsed
6068
6069 \begin_layout Plain Layout
6070 src/client/lyxclient
6071 \end_layout
6072
6073 \end_inset
6074
6075 .
6076 \end_layout
6077
6078 \begin_layout Section
6079 Normal communication
6080 \end_layout
6081
6082 \begin_layout Standard
6083 To issue a \SpecialChar LyX
6084  call, the client writes a line of ASCII text into the input
6085  pipe.
6086  This line has the following format:
6087 \end_layout
6088
6089 \begin_layout Quote
6090 LYXCMD:
6091 \emph on
6092 clientname
6093 \emph default
6094 :
6095 \emph on
6096 function
6097 \emph default
6098 :
6099 \emph on
6100 argument
6101 \end_layout
6102
6103 \begin_layout Description
6104 clientname is a name that the client can choose arbitrarily.
6105  Its only use is that \SpecialChar LyX
6106  will echo it if it sends an answer—so a client can
6107  dispatch results from different requesters.
6108 \end_layout
6109
6110 \begin_layout Description
6111 function is the function you want \SpecialChar LyX
6112  to perform.
6113  It is the same as the commands you'd use in the minibuffer.
6114 \end_layout
6115
6116 \begin_layout Description
6117 argument is an optional argument which is meaningful only to some functions
6118  (for instance, the 
6119 \begin_inset Quotes eld
6120 \end_inset
6121
6122 self-insert
6123 \begin_inset Quotes erd
6124 \end_inset
6125
6126  LFUN will insert the argument as text at the cursor position).
6127 \end_layout
6128
6129 \begin_layout Standard
6130 The answer from \SpecialChar LyX
6131  will arrive in the output pipe and be of the form
6132 \end_layout
6133
6134 \begin_layout Quote
6135 INFO:
6136 \emph on
6137 clientname
6138 \emph default
6139 :
6140 \emph on
6141 function
6142 \emph default
6143 :
6144 \emph on
6145 data
6146 \end_layout
6147
6148 \begin_layout Standard
6149 where 
6150 \emph on
6151 clientname
6152 \emph default
6153  and 
6154 \emph on
6155 function
6156 \emph default
6157  are just echoed from the command request, while 
6158 \emph on
6159 data
6160 \emph default
6161  is more or less useful information filled according to how the command
6162  execution worked out.
6163  Some commands, such as 
6164 \begin_inset Quotes eld
6165 \end_inset
6166
6167 font-state
6168 \begin_inset Quotes erd
6169 \end_inset
6170
6171 , will return information about the internal state of \SpecialChar LyX
6172 , while other will
6173  return an empty data-response.
6174  This means that the command execution went fine.
6175 \end_layout
6176
6177 \begin_layout Standard
6178 In case of errors, the response from \SpecialChar LyX
6179  will have this form
6180 \end_layout
6181
6182 \begin_layout Quote
6183 ERROR:
6184 \emph on
6185 clientname
6186 \emph default
6187 :
6188 \emph on
6189 function
6190 \emph default
6191 :
6192 \emph on
6193 error message
6194 \end_layout
6195
6196 \begin_layout Standard
6197 where the 
6198 \emph on
6199 error message
6200 \emph default
6201  should contain an explanation of why the command failed.
6202 \end_layout
6203
6204 \begin_layout Standard
6205 Examples:
6206 \end_layout
6207
6208 \begin_layout LyX-Code
6209 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
6210 \begin_inset Newline newline
6211 \end_inset
6212
6213 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
6214 \begin_inset Newline newline
6215 \end_inset
6216
6217 read a <~/.lyxpipe.out
6218 \begin_inset Newline newline
6219 \end_inset
6220
6221 echo $a
6222 \end_layout
6223
6224 \begin_layout Subsection
6225 AppleScript (Mac OS X)
6226 \end_layout
6227
6228 \begin_layout Standard
6229 Since \SpecialChar LyX
6230  2.1, \SpecialChar LyX
6231  supports basic interactions with AppleScript for normal communicatio
6232 n through the command run.
6233  This command takes a direct argument (the 
6234 \series bold
6235 function
6236 \series default
6237  to perform) and an optional argument.
6238  It either returns the output of the function or triggers an error with
6239  the error message and code.
6240 \end_layout
6241
6242 \begin_layout Standard
6243 Example:
6244 \end_layout
6245
6246 \begin_layout LyX-Code
6247 tell application "\SpecialChar LyX
6248 "
6249 \end_layout
6250
6251 \begin_layout LyX-Code
6252   try
6253 \end_layout
6254
6255 \begin_layout LyX-Code
6256     -- Stores the current file name into f
6257 \end_layout
6258
6259 \begin_layout LyX-Code
6260     set f to (run "server-get-filename" with argument "")
6261 \end_layout
6262
6263 \begin_layout LyX-Code
6264     on error the error_message number the error_number
6265 \end_layout
6266
6267 \begin_layout LyX-Code
6268       display dialog "Error: " & the error_number & ".
6269  " ¬
6270 \end_layout
6271
6272 \begin_layout LyX-Code
6273               & the error_message buttons {"OK"} default button 1
6274 \end_layout
6275
6276 \begin_layout LyX-Code
6277   end try
6278 \end_layout
6279
6280 \begin_layout LyX-Code
6281 end tell
6282 \end_layout
6283
6284 \begin_layout Section
6285 Notification
6286 \end_layout
6287
6288 \begin_layout Standard
6289 \SpecialChar LyX
6290  can notify clients of events going on asynchronously.
6291  Currently it will only do this if the user binds a key sequence with the
6292  function 
6293 \begin_inset Quotes eld
6294 \end_inset
6295
6296 notify
6297 \begin_inset Quotes erd
6298 \end_inset
6299
6300 .
6301  The format of the string \SpecialChar LyX
6302  sends is as follows:
6303 \end_layout
6304
6305 \begin_layout Quote
6306 \begin_inset Flex Code
6307 status collapsed
6308
6309 \begin_layout Plain Layout
6310 NOTIFY:
6311 \end_layout
6312
6313 \end_inset
6314
6315
6316 \emph on
6317 key-sequence
6318 \end_layout
6319
6320 \begin_layout Standard
6321 where 
6322 \emph on
6323 key-sequence
6324 \emph default
6325  is the printed representation of the key sequence that was actually typed
6326  by the user.
6327 \end_layout
6328
6329 \begin_layout Standard
6330 This mechanism can be used to extend \SpecialChar LyX
6331 's command set and implement macros.
6332  Bind some key sequence to 
6333 \begin_inset Quotes eld
6334 \end_inset
6335
6336 notify
6337 \begin_inset Quotes erd
6338 \end_inset
6339
6340 .
6341  Then start a client that listens on the output pipe, dispatches the command
6342  according to the sequence, and starts a function that may use \SpecialChar LyX
6343  calls and
6344  \SpecialChar LyX
6345  requests to issue a command or a series of commands to \SpecialChar LyX
6346 .
6347 \end_layout
6348
6349 \begin_layout Section
6350 The simple \SpecialChar LyX
6351  Server Protocol
6352 \end_layout
6353
6354 \begin_layout Standard
6355 \SpecialChar LyX
6356  implements a simple protocol that can be used for session management.
6357  All messages are of the form
6358 \end_layout
6359
6360 \begin_layout Quote
6361 LYXSRV:
6362 \emph on
6363 clientname
6364 \emph default
6365 :
6366 \emph on
6367 protocol message
6368 \end_layout
6369
6370 \begin_layout Standard
6371 where 
6372 \emph on
6373 protocol message
6374 \emph default
6375  can be 
6376 \begin_inset Quotes eld
6377 \end_inset
6378
6379 hello
6380 \begin_inset Quotes erd
6381 \end_inset
6382
6383  or 
6384 \begin_inset Quotes eld
6385 \end_inset
6386
6387 bye
6388 \begin_inset Quotes erd
6389 \end_inset
6390
6391 .
6392  If 
6393 \begin_inset Quotes eld
6394 \end_inset
6395
6396 hello
6397 \begin_inset Quotes erd
6398 \end_inset
6399
6400  is received from a client, \SpecialChar LyX
6401  will report back to inform the client that
6402  it's listening to it's messages, while 
6403 \begin_inset Quotes eld
6404 \end_inset
6405
6406 bye
6407 \begin_inset Quotes erd
6408 \end_inset
6409
6410  sent from \SpecialChar LyX
6411  will inform clients that \SpecialChar LyX
6412  is closing.
6413 \end_layout
6414
6415 \begin_layout Section
6416 Reverse DVI/PDF search
6417 \end_layout
6418
6419 \begin_layout Standard
6420 Some DVI/PDF viewers
6421 \begin_inset Foot
6422 status collapsed
6423
6424 \begin_layout Plain Layout
6425 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
6426  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
6427 \end_layout
6428
6429 \end_inset
6430
6431  provide 
6432 \emph on
6433 reverse search
6434 \emph default
6435  facility (also called 
6436 \emph on
6437 inverse search
6438 \emph default
6439 ).
6440  This means that you can tell \SpecialChar LyX
6441  to put the cursor to a specific line in the
6442  document by clicking at the respective position in the DVI/PDF output.
6443  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
6444 .
6445  This is done via the \SpecialChar LyX
6446  server either by using the named pipe (
6447 \emph on
6448 lyxpipe
6449 \emph default
6450 ), or the UNIX domain socket (
6451 \emph on
6452 lyxsocket
6453 \emph default
6454 ) that \SpecialChar LyX
6455  creates in its temporary directory (this is the way the 
6456 \begin_inset Flex Code
6457 status collapsed
6458
6459 \begin_layout Plain Layout
6460 lyxclient
6461 \end_layout
6462
6463 \end_inset
6464
6465  program communicates with \SpecialChar LyX
6466 ).
6467  In some cases, you need a helper script that mediates between the viewer
6468  and \SpecialChar LyX
6469 , in others, the viewer can communicate with \SpecialChar LyX
6470  directly.
6471  This depends on the selected viewer and on your operating system.
6472  The same applies to the way viewers need to be configured and the way the
6473  reverse search is actually performed.
6474  In what follows, we will thus describe how to setup reverse search for
6475  specific viewers.
6476  Before we turn to this, though, we will explain what needs to be done generally
6477  to enable reverse search in the DVI/PDF output.
6478 \end_layout
6479
6480 \begin_layout Subsection
6481 Automatic setup
6482 \begin_inset CommandInset label
6483 LatexCommand label
6484 name "subsec:rev-search"
6485
6486 \end_inset
6487
6488
6489 \end_layout
6490
6491 \begin_layout Standard
6492 In most cases \SpecialChar LyX
6493  will do the work for you by 
6494 \change_inserted -712698321 1500975045
6495 pressing the following button in the toolbar: 
6496 \begin_inset Info
6497 type  "icon"
6498 arg   "buffer-toggle-output-sync"
6499 \end_inset
6500
6501 .
6502  Alternatively, you can also enable the feature by checking 
6503 \family sans
6504 Synchronize with Output
6505 \family default
6506  in 
6507 \begin_inset Flex Noun
6508 status collapsed
6509
6510 \begin_layout Plain Layout
6511
6512 \change_inserted -712698321 1500975071
6513 Document\SpecialChar menuseparator
6514 Settings\SpecialChar menuseparator
6515 Formats
6516 \end_layout
6517
6518 \end_inset
6519
6520
6521 \change_deleted -712698321 1500974764
6522 enabling the option 
6523 \begin_inset Flex Noun
6524 status collapsed
6525
6526 \begin_layout Plain Layout
6527 Synchronize with Output
6528 \end_layout
6529
6530 \end_inset
6531
6532  in the menu 
6533 \begin_inset Flex Noun
6534 status collapsed
6535
6536 \begin_layout Plain Layout
6537 Document\SpecialChar menuseparator
6538 Settings\SpecialChar menuseparator
6539 Output
6540 \end_layout
6541
6542 \end_inset
6543
6544
6545 \change_unchanged
6546 .
6547  In such a case \SpecialChar LyX
6548  will automatically insert the necessary Sync\SpecialChar TeX
6549  macro (for
6550  PDF) or load the srcltx package (for DVI) respectively.
6551  This option can be easily reached also on 
6552 \begin_inset Flex Code
6553 status collapsed
6554
6555 \begin_layout Plain Layout
6556 View/Update
6557 \end_layout
6558
6559 \end_inset
6560
6561  Toolbar.
6562 \end_layout
6563
6564 \begin_layout Standard
6565 If you need a different setting, you can select or input a custom macro
6566  from the drop down box just below 
6567 \begin_inset Flex Noun
6568 status collapsed
6569
6570 \begin_layout Plain Layout
6571 Document\SpecialChar menuseparator
6572 Settings\SpecialChar menuseparator
6573 Output\SpecialChar menuseparator
6574 Synchronize with Output
6575 \end_layout
6576
6577 \end_inset
6578
6579 .
6580 \end_layout
6581
6582 \begin_layout Standard
6583 Note that the method 
6584 \begin_inset Flex Code
6585 status collapsed
6586
6587 \begin_layout Plain Layout
6588
6589 \backslash
6590 synctex=1
6591 \end_layout
6592
6593 \end_inset
6594
6595  enables gzip compression.
6596  If your viewer does not support it, you should instead use 
6597 \begin_inset Flex Code
6598 status collapsed
6599
6600 \begin_layout Plain Layout
6601
6602 \backslash
6603 synctex=-1
6604 \end_layout
6605
6606 \end_inset
6607
6608 .
6609 \end_layout
6610
6611 \begin_layout Standard
6612 Please also note that including the 
6613 \begin_inset Flex Code
6614 status collapsed
6615
6616 \begin_layout Plain Layout
6617 srcltx
6618 \end_layout
6619
6620 \end_inset
6621
6622  package or 
6623 \begin_inset Flex Code
6624 status collapsed
6625
6626 \begin_layout Plain Layout
6627 src-specials
6628 \end_layout
6629
6630 \end_inset
6631
6632  sometimes has an undesired impact on the typesetting.
6633  Thus, you should switch output synchronization off for the final typesetting
6634  if you use the 
6635 \begin_inset Flex Code
6636 status collapsed
6637
6638 \begin_layout Plain Layout
6639 srcltx
6640 \end_layout
6641
6642 \end_inset
6643
6644  package or 
6645 \begin_inset Flex Code
6646 status collapsed
6647
6648 \begin_layout Plain Layout
6649 src-specials
6650 \end_layout
6651
6652 \end_inset
6653
6654 .
6655  
6656 \end_layout
6657
6658 \begin_layout Standard
6659 In case you need some more special settings that are not covered by the
6660  automatic settings, read the next section about how to set up output synchroniz
6661 ation manually.
6662  If the automatic setup suits your needs, you can readily jump to section
6663 \begin_inset space ~
6664 \end_inset
6665
6666
6667 \begin_inset CommandInset ref
6668 LatexCommand ref
6669 reference "subsec:configuring-viewers"
6670
6671 \end_inset
6672
6673 , where the necessary configuration steps in your viewer – needed both with
6674  the automatic and the manual setup – are described.
6675 \end_layout
6676
6677 \begin_layout Subsection
6678 Manual setup
6679 \end_layout
6680
6681 \begin_layout Standard
6682 \SpecialChar LaTeX
6683  provides several different methods for reverse search.
6684  Some are built-in in the 
6685 \begin_inset Flex Code
6686 status collapsed
6687
6688 \begin_layout Plain Layout
6689 latex/pdflatex
6690 \end_layout
6691
6692 \end_inset
6693
6694  program, some are provided by external packages.
6695  Your choice depends on whether your \SpecialChar LaTeX
6696  distribution already provides a given
6697  method (the built-in methods are rather new) and whether your viewer can
6698  cope with it.
6699  The available methods are described in the following.
6700 \end_layout
6701
6702 \begin_layout Subsubsection*
6703 Built-in DVI-search via src-specials (DVI only) 
6704 \end_layout
6705
6706 \begin_layout Standard
6707 This method provides the DVI file with the necessary information for reverse
6708  search.
6709  It is available in \SpecialChar LaTeX
6710  since quite some time (any somewhat recent \SpecialChar LaTeX
6711  distribution
6712  should include it), and it works reliably.
6713  To enable it, change the 
6714 \begin_inset Flex Noun
6715 status collapsed
6716
6717 \begin_layout Plain Layout
6718 La
6719 \family sans
6720 TeX
6721 \family default
6722  (plain)->DVI
6723 \end_layout
6724
6725 \end_inset
6726
6727  or 
6728 \begin_inset Flex Noun
6729 status collapsed
6730
6731 \begin_layout Plain Layout
6732 La
6733 \family sans
6734 TeX
6735 \family default
6736  (plain)->DraftDVI
6737 \end_layout
6738
6739 \end_inset
6740
6741  converter in 
6742 \begin_inset Flex Noun
6743 status collapsed
6744
6745 \begin_layout Plain Layout
6746 Preferences\SpecialChar menuseparator
6747 File Handling\SpecialChar menuseparator
6748 Converters
6749 \end_layout
6750
6751 \end_inset
6752
6753  to 
6754 \begin_inset Flex Code
6755 status collapsed
6756
6757 \begin_layout Plain Layout
6758 latex -src-specials $$i
6759 \end_layout
6760
6761 \end_inset
6762
6763 .
6764  If this doesn't work, check if your \SpecialChar TeX
6765  engine needs different options (the
6766  syntax might differ in some distributions).
6767 \end_layout
6768
6769 \begin_layout Subsubsection*
6770 External Packages (PDFSync and scrltx) 
6771 \end_layout
6772
6773 \begin_layout Standard
6774 The packages 
6775 \emph on
6776 pdfsync
6777 \emph default
6778  and 
6779 \emph on
6780 scrltx
6781 \emph default
6782  provide reverse search facility for PDF output (via pdflatex) and DVI output,
6783  respectively.
6784  In order to enable it, load the packages in the \SpecialChar LyX
6785  preamble: 
6786 \end_layout
6787
6788 \begin_layout Itemize
6789 \begin_inset Flex Code
6790 status collapsed
6791
6792 \begin_layout Plain Layout
6793
6794 \backslash
6795 usepackage{pdfsync}
6796 \end_layout
6797
6798 \end_inset
6799
6800  for reverse PDF search,
6801 \end_layout
6802
6803 \begin_layout Itemize
6804 \begin_inset Flex Code
6805 status collapsed
6806
6807 \begin_layout Plain Layout
6808
6809 \backslash
6810 usepackage[active]{srcltx}
6811 \end_layout
6812
6813 \end_inset
6814
6815  for reverse DVI search.
6816 \end_layout
6817
6818 \begin_layout Standard
6819 If you want to be able to perform both DVI and PDF reverse searches, you
6820  can also insert in the preamble the following lines
6821 \end_layout
6822
6823 \begin_layout LyX-Code
6824
6825 \backslash
6826 usepackage{ifpdf}
6827 \begin_inset Newline newline
6828 \end_inset
6829
6830
6831 \backslash
6832 ifpdf
6833 \begin_inset Newline newline
6834 \end_inset
6835
6836   
6837 \backslash
6838 usepackage{pdfsync}
6839 \begin_inset Newline newline
6840 \end_inset
6841
6842
6843 \backslash
6844 else
6845 \begin_inset Newline newline
6846 \end_inset
6847
6848   
6849 \backslash
6850 usepackage[active]{srcltx}
6851 \begin_inset Newline newline
6852 \end_inset
6853
6854
6855 \backslash
6856 fi
6857 \end_layout
6858
6859 \begin_layout Standard
6860 This way, you can preview the file as either DVI or PDF (pdflatex) and the
6861  right package will be used.
6862 \end_layout
6863
6864 \begin_layout Standard
6865 Note that PDFSync might affect the output layout of your document.
6866  It is therefore advised to disable PDFsync for final documents.
6867 \end_layout
6868
6869 \begin_layout Subsubsection*
6870 Built-in reverse search via Sync\SpecialChar TeX
6871  (DVI and PDF) 
6872 \end_layout
6873
6874 \begin_layout Standard
6875 Recent versions of 
6876 \begin_inset Flex Code
6877 status collapsed
6878
6879 \begin_layout Plain Layout
6880 (pdf)latex
6881 \end_layout
6882
6883 \end_inset
6884
6885  have built-in support for both PDF and DVI reverse search.
6886  This so-called 
6887 \emph on
6888 Sync\SpecialChar TeX
6889
6890 \emph default
6891  facility is basically the result of the integration of the PDFSync package
6892  to the pdftex program and its merge with the 
6893 \emph on
6894 scr-specials
6895 \emph default
6896  approach.
6897  You need at least \SpecialChar TeX
6898 Live 2008 or a recent Mik\SpecialChar TeX
6899  distribution in order to use
6900  it.
6901 \begin_inset Foot
6902 status collapsed
6903
6904 \begin_layout Plain Layout
6905 For some reason, Mik\SpecialChar TeX
6906  does not understand/obey the command \SpecialChar LyX
6907  inserts into
6908  the preamble when you check the "Enable Forward/Reverse Search" button
6909  in the toolbar and does not generate the necessary info.
6910 \end_layout
6911
6912 \begin_layout Plain Layout
6913 The generation of the required info can be forced by changing the converter
6914  "\SpecialChar LaTeX
6915  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
6916  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
6917  the -synctex=1 switch).
6918 \end_layout
6919
6920 \end_inset
6921
6922  Also note that only a few PDF viewers (
6923 \change_inserted -712698321 1500977288
6924 such as 
6925 \change_unchanged
6926 Okular and Qpdfview on Unix, Skim on the Mac, SumatraPDF on Windows
6927 \change_inserted -712698321 1500977299
6928 ; see the next section for details
6929 \change_unchanged
6930 ) already provide Sync\SpecialChar TeX
6931  support.
6932 \end_layout
6933
6934 \begin_layout Standard
6935 To enable Sync\SpecialChar TeX
6936  for DVI output, change the 
6937 \begin_inset Flex Noun
6938 status collapsed
6939
6940 \begin_layout Plain Layout
6941 La
6942 \family sans
6943 TeX
6944 \family default
6945  (plain) -> DVI
6946 \end_layout
6947
6948 \end_inset
6949
6950  or 
6951 \begin_inset Flex Noun
6952 status collapsed
6953
6954 \begin_layout Plain Layout
6955 La
6956 \family sans
6957 TeX
6958 \family default
6959  (plain) -> DraftDVI
6960 \end_layout
6961
6962 \end_inset
6963
6964  converter in 
6965 \begin_inset Flex Noun
6966 status collapsed
6967
6968 \begin_layout Plain Layout
6969 Preferences\SpecialChar menuseparator
6970 File Handling\SpecialChar menuseparator
6971 Converters
6972 \end_layout
6973
6974 \end_inset
6975
6976  to 
6977 \begin_inset Flex Code
6978 status collapsed
6979
6980 \begin_layout Plain Layout
6981 latex -synctex=1 $$i
6982 \end_layout
6983
6984 \end_inset
6985
6986 , and for PDF output, change the 
6987 \begin_inset Flex Noun
6988 status collapsed
6989
6990 \begin_layout Plain Layout
6991 La
6992 \family sans
6993 TeX
6994 \family default
6995  (pdflatex) -> PDF (pdflatex)
6996 \end_layout
6997
6998 \end_inset
6999
7000  
7001 \change_deleted -712698321 1500977453
7002 or
7003 \change_unchanged
7004  converter to 
7005 \begin_inset Flex Code
7006 status collapsed
7007
7008 \begin_layout Plain Layout
7009 pdflatex -synctex=1 $$i
7010 \end_layout
7011
7012 \end_inset
7013
7014 .
7015  
7016 \change_inserted -712698321 1500977740
7017 Should your viewer not be considered in the following description, or in
7018  case of missing success, please 
7019 \change_deleted -712698321 1500977741
7020 C
7021 \change_inserted -712698321 1500977744
7022 c
7023 \change_unchanged
7024 heck the documentation of your viewer whether the viewer needs to be configured
7025  for the use with Sync\SpecialChar TeX
7026 .
7027 \begin_inset Foot
7028 status collapsed
7029
7030 \begin_layout Plain Layout
7031 Note that the option 
7032 \begin_inset Flex Code
7033 status collapsed
7034
7035 \begin_layout Plain Layout
7036 -synctex=1
7037 \end_layout
7038
7039 \end_inset
7040
7041  option enables gzip compression.
7042  If your viewer does not support it, you should instead use 
7043 \begin_inset Flex Code
7044 status collapsed
7045
7046 \begin_layout Plain Layout
7047 -synctex=-1
7048 \end_layout
7049
7050 \end_inset
7051
7052 .
7053 \end_layout
7054
7055 \end_inset
7056
7057
7058 \end_layout
7059
7060 \begin_layout Subsection
7061 Configuring and using specific viewers
7062 \begin_inset CommandInset label
7063 LatexCommand label
7064 name "subsec:configuring-viewers"
7065
7066 \end_inset
7067
7068
7069 \end_layout
7070
7071 \begin_layout Subsubsection*
7072 Xdvi (all platforms)
7073 \end_layout
7074
7075 \begin_layout Standard
7076 If you use 
7077 \begin_inset Flex Code
7078 status collapsed
7079
7080 \begin_layout Plain Layout
7081 xdvi
7082 \end_layout
7083
7084 \end_inset
7085
7086 , you don't need to do anything else for performing a reverse DVI search,
7087  as \SpecialChar LyX
7088  already provides the necessary hooks for automatically using the 
7089 \begin_inset Flex Code
7090 status collapsed
7091
7092 \begin_layout Plain Layout
7093 lyxclient
7094 \end_layout
7095
7096 \end_inset
7097
7098  program.
7099  Just setup your document as described above (reverse search is triggered
7100  by Ctrl-click or Alt-click on Mac OSX, respectively).
7101 \end_layout
7102
7103 \begin_layout Standard
7104 However, if for whatever reason you want to use the named pipe instead of
7105  the socket for communicating with \SpecialChar LyX
7106 , simply change the DVI viewer in 
7107 \begin_inset Flex Noun
7108 status collapsed
7109
7110 \begin_layout Plain Layout
7111 Preferences\SpecialChar menuseparator
7112 File Handling\SpecialChar menuseparator
7113 File formats
7114 \end_layout
7115
7116 \end_inset
7117
7118  to
7119 \begin_inset Foot
7120 status collapsed
7121
7122 \begin_layout Plain Layout
7123 On Mac OSX you have to use 
7124 \begin_inset Flex Code
7125 status collapsed
7126
7127 \begin_layout Plain Layout
7128 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
7129 \end_layout
7130
7131 \end_inset
7132
7133
7134 \end_layout
7135
7136 \end_inset
7137
7138  
7139 \begin_inset Flex Code
7140 status collapsed
7141
7142 \begin_layout Plain Layout
7143 xdvi -editor "lyxeditor.sh %f %l"
7144 \end_layout
7145
7146 \end_inset
7147
7148 , where 
7149 \begin_inset Flex Code
7150 status collapsed
7151
7152 \begin_layout Plain Layout
7153 lyxeditor.sh
7154 \end_layout
7155
7156 \end_inset
7157
7158  is a suitable script.
7159  For example, a minimal shell script is the following one:
7160 \end_layout
7161
7162 \begin_layout LyX-Code
7163 #!/bin/sh
7164 \begin_inset Newline newline
7165 \end_inset
7166
7167 LYXPIPE="/path/to/lyxpipe"
7168 \begin_inset Newline newline
7169 \end_inset
7170
7171 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
7172 \begin_inset Newline newline
7173 \end_inset
7174
7175 echo "$COMMAND" > "${LYXPIPE}".in || exit
7176 \begin_inset Newline newline
7177 \end_inset
7178
7179 read TMP < "${LYXPIPE}".out || exit
7180 \end_layout
7181
7182 \begin_layout Standard
7183 where 
7184 \begin_inset Flex Code
7185 status collapsed
7186
7187 \begin_layout Plain Layout
7188 /path/to/lyxpipe
7189 \end_layout
7190
7191 \end_inset
7192
7193  is the LyXServer pipe path specified in 
7194 \begin_inset Flex Noun
7195 status collapsed
7196
7197 \begin_layout Plain Layout
7198 Preferences\SpecialChar menuseparator
7199 Paths
7200 \end_layout
7201
7202 \end_inset
7203
7204 .
7205 \begin_inset Foot
7206 status collapsed
7207
7208 \begin_layout Plain Layout
7209 In the 
7210 \begin_inset Flex Code
7211 status collapsed
7212
7213 \begin_layout Plain Layout
7214 development/tools
7215 \end_layout
7216
7217 \end_inset
7218
7219  folder of a source distribution you can find a 
7220 \begin_inset Flex Code
7221 status collapsed
7222
7223 \begin_layout Plain Layout
7224 lyxeditor
7225 \end_layout
7226
7227 \end_inset
7228
7229  script which is able to locate the 
7230 \emph on
7231 lyxpipe
7232 \emph default
7233  based on your preferences.
7234 \end_layout
7235
7236 \end_inset
7237
7238
7239 \end_layout
7240
7241 \begin_layout Subsubsection*
7242 MacDviX (Mac OSX)
7243 \end_layout
7244
7245 \begin_layout Standard
7246 At the end of 
7247 \begin_inset Flex Code
7248 status collapsed
7249
7250 \begin_layout Plain Layout
7251 /Applications/MacDviX_Folder/calleditor.script
7252 \end_layout
7253
7254 \end_inset
7255
7256 , add the following lines:
7257 \end_layout
7258
7259 \begin_layout LyX-Code
7260 /Applications/LyX.app/Contents/MacOS/lyxeditor "$2" $1
7261 \begin_inset Newline newline
7262 \end_inset
7263
7264 exit 1
7265 \end_layout
7266
7267 \begin_layout Standard
7268 Modify the lines accordingly if you install \SpecialChar LyX
7269  somewhere else than in the
7270  Applications folder.
7271 \end_layout
7272
7273 \begin_layout Standard
7274 Reverse search is triggered by Alt-click (OPTION-click).
7275 \end_layout
7276
7277 \begin_layout Subsubsection*
7278 Skim (Mac OSX)
7279 \end_layout
7280
7281 \begin_layout Standard
7282 Enter 
7283 \begin_inset Flex Code
7284 status collapsed
7285
7286 \begin_layout Plain Layout
7287 open -a Skim.app $$i
7288 \end_layout
7289
7290 \end_inset
7291
7292  to the viewer setting in 
7293 \begin_inset Flex Noun
7294 status collapsed
7295
7296 \begin_layout Plain Layout
7297 Preferences\SpecialChar menuseparator
7298 File Handling\SpecialChar menuseparator
7299 File formats\SpecialChar menuseparator
7300 PDF (pdflatex)
7301 \end_layout
7302
7303 \end_inset
7304
7305 , and then in 
7306 \begin_inset Flex Noun
7307 status collapsed
7308
7309 \begin_layout Plain Layout
7310 Skim\SpecialChar menuseparator
7311 Preferences\SpecialChar menuseparator
7312 Sync
7313 \end_layout
7314
7315 \end_inset
7316
7317  choose 
7318 \begin_inset Flex Noun
7319 status collapsed
7320
7321 \begin_layout Plain Layout
7322 custom
7323 \end_layout
7324
7325 \end_inset
7326
7327  preset and enter command 
7328 \begin_inset Flex Noun
7329 status collapsed
7330
7331 \begin_layout Plain Layout
7332 /Applications/\SpecialChar LyX
7333 .app/Contents/MacOS/lyxeditor
7334 \end_layout
7335
7336 \end_inset
7337
7338 .
7339 \end_layout
7340
7341 \begin_layout Standard
7342 Reverse search is triggered by COMMAND-SHIFT-click
7343 \end_layout
7344
7345 \begin_layout Subsubsection*
7346 Evince (GNOME)
7347 \end_layout
7348
7349 \begin_layout Standard
7350 Reverse search with evince does not work out of the box, but it can be achieved
7351  by means of some third party helper scripts.
7352  Please refer to 
7353 \begin_inset CommandInset href
7354 LatexCommand href
7355 target "http://wiki.lyx.org/LyX/SyncTeX"
7356 literal "false"
7357
7358 \end_inset
7359
7360  for details.
7361 \end_layout
7362
7363 \begin_layout Subsubsection*
7364 Okular (KDE)
7365 \end_layout
7366
7367 \begin_layout Standard
7368 Go to 
7369 \begin_inset Flex Noun
7370 status collapsed
7371
7372 \begin_layout Plain Layout
7373 Settings\SpecialChar menuseparator
7374 Configure Okular\SpecialChar menuseparator
7375 Editor
7376 \end_layout
7377
7378 \end_inset
7379
7380
7381 \change_inserted -712698321 1500981642
7382  and
7383 \change_deleted -712698321 1500981641
7384 ,
7385 \change_unchanged
7386  select 
7387 \change_deleted -712698321 1500981634
7388
7389 \begin_inset Quotes eld
7390 \end_inset
7391
7392 Custom Text Editor
7393 \change_inserted -712698321 1500981635
7394 LyX
7395 \change_unchanged
7396
7397 \begin_inset Quotes erd
7398 \end_inset
7399
7400  
7401 \change_inserted -712698321 1500981659
7402 as editor.
7403  This inserts the appropriate 
7404 \change_deleted -712698321 1500981663
7405 and add the 
7406 \change_unchanged
7407 command 
7408 \change_inserted -712698321 1500981665
7409 (
7410 \change_unchanged
7411
7412 \begin_inset Flex Code
7413 status collapsed
7414
7415 \begin_layout Plain Layout
7416 lyxclient -g %f %l
7417 \end_layout
7418
7419 \end_inset
7420
7421
7422 \change_inserted -712698321 1500981668
7423 )
7424 \change_unchanged
7425 .
7426 \end_layout
7427
7428 \begin_layout Standard
7429 Reverse search is triggered by SHIFT-click.
7430 \end_layout
7431
7432 \begin_layout Subsubsection*
7433 Qpdfview (Unix)
7434 \end_layout
7435
7436 \begin_layout Standard
7437 Qpdfview supports Sync\SpecialChar TeX
7438  since version 0.3.5.
7439  Go to 
7440 \begin_inset Flex Noun
7441 status collapsed
7442
7443 \begin_layout Plain Layout
7444 Edit\SpecialChar menuseparator
7445 Settings\SpecialChar menuseparator
7446 Behavior
7447 \end_layout
7448
7449 \end_inset
7450
7451 , click on the input field of the 
7452 \begin_inset Quotes eld
7453 \end_inset
7454
7455 Source editor
7456 \begin_inset Quotes erd
7457 \end_inset
7458
7459  item and add the command 
7460 \begin_inset Flex Code
7461 status collapsed
7462
7463 \begin_layout Plain Layout
7464 lyxclient -g %1 %2
7465 \end_layout
7466
7467 \end_inset
7468
7469 .
7470 \end_layout
7471
7472 \begin_layout Standard
7473 Reverse search is triggered by double-click or, in more recent versions,
7474  by context menu.
7475 \end_layout
7476
7477 \begin_layout Subsubsection*
7478 YAP (Windows)
7479 \end_layout
7480
7481 \begin_layout Standard
7482 Launch yap, choose its 
7483 \begin_inset Flex Noun
7484 status collapsed
7485
7486 \begin_layout Plain Layout
7487 View\SpecialChar menuseparator
7488 Options
7489 \end_layout
7490
7491 \end_inset
7492
7493  menu and select the 
7494 \begin_inset Quotes eld
7495 \end_inset
7496
7497 Inverse DVI Search
7498 \begin_inset Quotes erd
7499 \end_inset
7500
7501  tab.
7502  Click on the 
7503 \begin_inset Quotes eld
7504 \end_inset
7505
7506 New\SpecialChar ldots
7507
7508 \begin_inset Quotes erd
7509 \end_inset
7510
7511  button and, in the window that opens, enter 
7512 \begin_inset Quotes eld
7513 \end_inset
7514
7515 \SpecialChar LyX
7516  Editor
7517 \begin_inset Quotes erd
7518 \end_inset
7519
7520  (or any other name you like) in the 
7521 \begin_inset Quotes eld
7522 \end_inset
7523
7524 Name:
7525 \begin_inset Quotes erd
7526 \end_inset
7527
7528  field.
7529  Now click on the button labeled 
7530 \begin_inset Quotes eld
7531 \end_inset
7532
7533 \SpecialChar ldots
7534
7535 \begin_inset Quotes erd
7536 \end_inset
7537
7538  to open a file dialog and navigate to the directory containing the batch
7539  file 
7540 \begin_inset Flex Code
7541 status collapsed
7542
7543 \begin_layout Plain Layout
7544 lyxeditor.bat
7545 \end_layout
7546
7547 \end_inset
7548
7549  (see below).
7550  Select 
7551 \begin_inset Flex Code
7552 status collapsed
7553
7554 \begin_layout Plain Layout
7555 lyxeditor.bat
7556 \end_layout
7557
7558 \end_inset
7559
7560  and then specify the program arguments as 
7561 \begin_inset Flex Code
7562 status collapsed
7563
7564 \begin_layout Plain Layout
7565 %f %l
7566 \end_layout
7567
7568 \end_inset
7569
7570 .
7571  The 
7572 \begin_inset Flex Code
7573 status collapsed
7574
7575 \begin_layout Plain Layout
7576 lyxeditor.bat
7577 \end_layout
7578
7579 \end_inset
7580
7581  wrapper is used for communicating with \SpecialChar LyX
7582  through the 
7583 \emph on
7584 lyxpipe
7585 \emph default
7586  and is as follows:
7587 \end_layout
7588
7589 \begin_layout LyX-Code
7590 @echo off
7591 \begin_inset Newline newline
7592 \end_inset
7593
7594 echo LYXCMD:revdvi:server-goto-file-row:%~1 %2> 
7595 \backslash
7596
7597 \backslash
7598 .
7599 \backslash
7600 pipe
7601 \backslash
7602 lyxpipe.in
7603 \begin_inset Newline newline
7604 \end_inset
7605
7606 type 
7607 \backslash
7608
7609 \backslash
7610 .
7611 \backslash
7612 pipe
7613 \backslash
7614 lyxpipe.out
7615 \end_layout
7616
7617 \begin_layout Standard
7618 Make sure that the \SpecialChar LyX
7619 Server pipe path you specified in \SpecialChar LyX
7620  is 
7621 \begin_inset Flex Code
7622 status collapsed
7623
7624 \begin_layout Plain Layout
7625
7626 \backslash
7627
7628 \backslash
7629 .
7630 \backslash
7631 pipe
7632 \backslash
7633 lyxpipe
7634 \end_layout
7635
7636 \end_inset
7637
7638 , otherwise change the 
7639 \begin_inset Flex Code
7640 status collapsed
7641
7642 \begin_layout Plain Layout
7643 lyxeditor.bat
7644 \end_layout
7645
7646 \end_inset
7647
7648  wrapper accordingly.
7649 \end_layout
7650
7651 \begin_layout Standard
7652 In yap, reverse search is triggered by double-click.
7653 \end_layout
7654
7655 \begin_layout Subsubsection*
7656 SumatraPDF (Windows)
7657 \end_layout
7658
7659 \begin_layout Standard
7660 In order to use SumatraPDF for inverse search, enter 
7661 \begin_inset Flex Code
7662 status collapsed
7663
7664 \begin_layout Plain Layout
7665 SumatraPDF -inverse-search "lyxeditor.bat "%f" %l"
7666 \end_layout
7667
7668 \end_inset
7669
7670  in the viewer setting in 
7671 \begin_inset Flex Noun
7672 status collapsed
7673
7674 \begin_layout Plain Layout
7675 Preferences\SpecialChar menuseparator
7676 File Handling\SpecialChar menuseparator
7677 File formats\SpecialChar menuseparator
7678 PDF (pdflatex)
7679 \end_layout
7680
7681 \end_inset
7682
7683 , where 
7684 \begin_inset Flex Code
7685 status collapsed
7686
7687 \begin_layout Plain Layout
7688 lyxeditor.bat
7689 \end_layout
7690
7691 \end_inset
7692
7693  is the previous wrapper.
7694  If SumatraPDF.exe is not in your command PATH, use its full file name.
7695 \end_layout
7696
7697 \begin_layout Standard
7698 Reverse search is triggered by double-click.
7699 \end_layout
7700
7701 \begin_layout Subsubsection*
7702 YAP (Cygwin)
7703 \end_layout
7704
7705 \begin_layout Standard
7706 First of all, make sure that yap is your default DVI viewer in the Windows
7707  environment, then launch it, choose its 
7708 \begin_inset Flex Noun
7709 status collapsed
7710
7711 \begin_layout Plain Layout
7712 View\SpecialChar menuseparator
7713 Options
7714 \end_layout
7715
7716 \end_inset
7717
7718  menu and select the 
7719 \begin_inset Quotes eld
7720 \end_inset
7721
7722 Inverse DVI Search
7723 \begin_inset Quotes erd
7724 \end_inset
7725
7726  tab.
7727  Click on the 
7728 \begin_inset Quotes eld
7729 \end_inset
7730
7731 New\SpecialChar ldots
7732
7733 \begin_inset Quotes erd
7734 \end_inset
7735
7736  button and, in the window that opens, enter 
7737 \begin_inset Quotes eld
7738 \end_inset
7739
7740 \SpecialChar LyX
7741  Editor
7742 \begin_inset Quotes erd
7743 \end_inset
7744
7745  (or any other name you like) in the 
7746 \begin_inset Quotes eld
7747 \end_inset
7748
7749 Name:
7750 \begin_inset Quotes erd
7751 \end_inset
7752
7753  field.
7754  Now click on the button labeled 
7755 \begin_inset Quotes eld
7756 \end_inset
7757
7758 \SpecialChar ldots
7759
7760 \begin_inset Quotes erd
7761 \end_inset
7762
7763  to open a file dialog and navigate to the directory containing the 
7764 \begin_inset Flex Code
7765 status collapsed
7766
7767 \begin_layout Plain Layout
7768 lyxeditor.exe
7769 \end_layout
7770
7771 \end_inset
7772
7773  program (which is installed by default on Cygwin along with the \SpecialChar LyX
7774  executable).
7775  Select 
7776 \begin_inset Flex Code
7777 status collapsed
7778
7779 \begin_layout Plain Layout
7780 lyxeditor.exe
7781 \end_layout
7782
7783 \end_inset
7784
7785  and then specify the program arguments as 
7786 \begin_inset Flex Code
7787 status collapsed
7788
7789 \begin_layout Plain Layout
7790 -g %f %l
7791 \end_layout
7792
7793 \end_inset
7794
7795 .
7796  In this way, you will be using the 
7797 \emph on
7798 lyxsocket
7799 \emph default
7800  for communicating with \SpecialChar LyX
7801 .
7802  If, for whatever reason, you want to use the 
7803 \emph on
7804 lyxpipe
7805 \emph default
7806 , omit the 
7807 \begin_inset Flex Code
7808 status collapsed
7809
7810 \begin_layout Plain Layout
7811 -g
7812 \end_layout
7813
7814 \end_inset
7815
7816  option and be sure to specify the \SpecialChar LyX
7817 Server pipe path in the \SpecialChar LyX
7818  preferences.
7819 \end_layout
7820
7821 \begin_layout Standard
7822 In yap, reverse search is triggered by double-click.
7823 \end_layout
7824
7825 \begin_layout Subsubsection*
7826 SumatraPDF (Cygwin)
7827 \end_layout
7828
7829 \begin_layout Standard
7830 In order to use SumatraPDF for inverse search, enter 
7831 \begin_inset Flex Code
7832 status collapsed
7833
7834 \begin_layout Plain Layout
7835 SumatraPDF -inverse-search "lyxeditor -g %f %l"
7836 \end_layout
7837
7838 \end_inset
7839
7840  in the viewer setting in 
7841 \begin_inset Flex Noun
7842 status collapsed
7843
7844 \begin_layout Plain Layout
7845 Preferences\SpecialChar menuseparator
7846 File Handling\SpecialChar menuseparator
7847 File formats\SpecialChar menuseparator
7848 PDF (pdflatex)
7849 \end_layout
7850
7851 \end_inset
7852
7853 .
7854  If SumatraPDF.exe is not in your command PATH, use its full posix path.
7855  The 
7856 \begin_inset Flex Code
7857 status collapsed
7858
7859 \begin_layout Plain Layout
7860 -g
7861 \end_layout
7862
7863 \end_inset
7864
7865  enables communication via the 
7866 \emph on
7867 lyxsocket
7868 \emph default
7869 .
7870  Again, omit the 
7871 \begin_inset Flex Code
7872 status collapsed
7873
7874 \begin_layout Plain Layout
7875 -g
7876 \end_layout
7877
7878 \end_inset
7879
7880  option if you want to use the 
7881 \emph on
7882 lyxpipe
7883 \emph default
7884 , and be sure to specify the \SpecialChar LyX
7885 Server pipe path in the \SpecialChar LyX
7886  preferences.
7887 \end_layout
7888
7889 \begin_layout Standard
7890 Reverse search is triggered by double-click.
7891 \end_layout
7892
7893 \begin_layout Section
7894 Forward search
7895 \end_layout
7896
7897 \begin_layout Standard
7898 Forward search is, as the name implies, in a sense the 
7899 \begin_inset Quotes eld
7900 \end_inset
7901
7902 opposite
7903 \begin_inset Quotes erd
7904 \end_inset
7905
7906  of reverse search.
7907  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
7908 .
7909  If forward search is set up (as described in what follows), you can put
7910  the cursor anywhere in your \SpecialChar LyX
7911  document, and hit 
7912 \begin_inset Flex Noun
7913 status collapsed
7914
7915 \begin_layout Plain Layout
7916 Navigate\SpecialChar menuseparator
7917 Forward search
7918 \end_layout
7919
7920 \end_inset
7921
7922  (or select 
7923 \begin_inset Flex Noun
7924 status collapsed
7925
7926 \begin_layout Plain Layout
7927 Forward search
7928 \end_layout
7929
7930 \end_inset
7931
7932  in the context menu via right mouse click), and then the viewer will jump
7933  to that position as well.
7934  This implies, of course, that your viewer supports this function.
7935 \end_layout
7936
7937 \begin_layout Standard
7938 To make forward search possible, you first need to provide the generated
7939  output PDF/DVI file with additional information about the \SpecialChar TeX
7940  sources.
7941  This can be done via the methods described in the section 
7942 \begin_inset CommandInset ref
7943 LatexCommand ref
7944 reference "subsec:rev-search"
7945
7946 \end_inset
7947
7948 .
7949 \end_layout
7950
7951 \begin_layout Standard
7952 Additionally, you need to configure \SpecialChar LyX
7953  for using your viewers in 
7954 \begin_inset Flex Noun
7955 status collapsed
7956
7957 \begin_layout Plain Layout
7958 Tools\SpecialChar menuseparator
7959 Preferences\SpecialChar menuseparator
7960 Output\SpecialChar menuseparator
7961 General
7962 \end_layout
7963
7964 \end_inset
7965
7966 .
7967  We provide a range of tested configurations for some viewers, which you
7968  can select from the drop down list.
7969  If none of these configurations suits you, you have to find out and enter
7970  a suitable configuration yourself.
7971  The definition syntax uses the following placeholders:
7972 \end_layout
7973
7974 \begin_layout Itemize
7975 \noindent
7976 \begin_inset Flex Code
7977 status collapsed
7978
7979 \begin_layout Plain Layout
7980 $$n
7981 \end_layout
7982
7983 \end_inset
7984
7985 : row number
7986 \end_layout
7987
7988 \begin_layout Itemize
7989 \noindent
7990 \begin_inset Flex Code
7991 status collapsed
7992
7993 \begin_layout Plain Layout
7994 $$t
7995 \end_layout
7996
7997 \end_inset
7998
7999 : name of the (temporary) exported .tex file (without path)
8000 \end_layout
8001
8002 \begin_layout Itemize
8003 \noindent
8004 \begin_inset Flex Code
8005 status collapsed
8006
8007 \begin_layout Plain Layout
8008 $$f
8009 \end_layout
8010
8011 \end_inset
8012
8013 : name of the (temporary) exported .tex file (including path)
8014 \end_layout
8015
8016 \begin_layout Itemize
8017 \noindent
8018 \begin_inset Flex Code
8019 status collapsed
8020
8021 \begin_layout Plain Layout
8022 $$o
8023 \end_layout
8024
8025 \end_inset
8026
8027 : name of the exported output file (either dvi or pdf, depending on which
8028  one exists in the temporary directory)
8029 \end_layout
8030
8031 \begin_layout Standard
8032 Note that only some of the viewers provide full and usable forward search
8033  functionality out of the box, among them yap, xdvi, okular
8034 \begin_inset Foot
8035 status collapsed
8036
8037 \begin_layout Plain Layout
8038 You might want to set 
8039 \begin_inset Flex Code
8040 status collapsed
8041
8042 \begin_layout Plain Layout
8043 okular –unique
8044 \end_layout
8045
8046 \end_inset
8047
8048  in 
8049 \begin_inset Flex Noun
8050 status collapsed
8051
8052 \begin_layout Plain Layout
8053 Tools\SpecialChar menuseparator
8054 Preferences\SpecialChar menuseparator
8055 File Handling\SpecialChar menuseparator
8056 File
8057 \begin_inset space ~
8058 \end_inset
8059
8060 Formats
8061 \end_layout
8062
8063 \end_inset
8064
8065
8066 \end_layout
8067
8068 \end_inset
8069
8070 , qpdfview, and SumatraPDF
8071 \begin_inset Foot
8072 status collapsed
8073
8074 \begin_layout Plain Layout
8075 SumatraPDF can also use DDE commands through the external program CMCDDE
8076  — downloadable from 
8077 \begin_inset CommandInset href
8078 LatexCommand href
8079 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
8080 literal "false"
8081
8082 \end_inset
8083
8084
8085 \end_layout
8086
8087 \end_inset
8088
8089 .
8090  Others, such as evince
8091 \begin_inset Foot
8092 status collapsed
8093
8094 \begin_layout Plain Layout
8095 Forward search with evince can be achieved by means of third party helper
8096  scripts.
8097  Please refer to 
8098 \begin_inset CommandInset href
8099 LatexCommand href
8100 target "http://wiki.lyx.org/LyX/SyncTeX"
8101 literal "false"
8102
8103 \end_inset
8104
8105  for details.
8106 \end_layout
8107
8108 \end_inset
8109
8110 , require some extra tools in order to use forward search.
8111  While many of the widespread PDF viewers (most notably Adobe Reader) do
8112  not support forward search at all, some other viewers – e.
8113 \begin_inset space \thinspace{}
8114 \end_inset
8115
8116 g.
8117  xpdf – allow at least to reload the document and jump to a specific page
8118  of the file, so you can at least navigate 
8119 \begin_inset Quotes eld
8120 \end_inset
8121
8122 near
8123 \begin_inset Quotes erd
8124 \end_inset
8125
8126 .
8127  This latter functionality is provided by an external call of synctex (see
8128  the predefined example configurations).
8129  
8130 \end_layout
8131
8132 \begin_layout Standard
8133 Forward search works both with DVI and PDF output.
8134  \SpecialChar LyX
8135  simply checks which preview format you have used before (i.
8136 \begin_inset space \thinspace{}
8137 \end_inset
8138
8139 e., which format is already there in the temporary directory) and chooses
8140  the appropriate configuration for the respective format.
8141 \end_layout
8142
8143 \begin_layout Chapter
8144 Special Document Classes
8145 \end_layout
8146
8147 \begin_layout Section
8148 A&A Paper
8149 \end_layout
8150
8151 \begin_layout Standard
8152 by 
8153 \noun on
8154 Peter Sütterlin
8155 \end_layout
8156
8157 \begin_layout Subsection
8158 Introduction
8159 \end_layout
8160
8161 \begin_layout Standard
8162 This section describes how \SpecialChar LyX
8163  can be used to write articles for submission
8164  to the scientific journal 
8165 \emph on
8166 Astronomy and Astrophysics
8167 \emph default
8168  (
8169 \begin_inset Flex URL
8170 status collapsed
8171
8172 \begin_layout Plain Layout
8173
8174 http://www.edpsciences.fr/aa/
8175 \end_layout
8176
8177 \end_inset
8178
8179 ) using Version 5.01 of the document class 
8180 \family typewriter
8181 aa.cls
8182 \family default
8183 .
8184  This package can be downloaded from the ftp site
8185 \end_layout
8186
8187 \begin_layout Standard
8188 \begin_inset VSpace medskip
8189 \end_inset
8190
8191
8192 \end_layout
8193
8194 \begin_layout Standard
8195 \align center
8196 \begin_inset Flex URL
8197 status collapsed
8198
8199 \begin_layout Plain Layout
8200
8201 ftp://ftp.edpsciences.org/pub/aa/readme.html
8202 \end_layout
8203
8204 \end_inset
8205
8206
8207 \end_layout
8208
8209 \begin_layout Standard
8210 \begin_inset VSpace medskip
8211 \end_inset
8212
8213
8214 \end_layout
8215
8216 \begin_layout Standard
8217 A manual comes together with that package, and this text is not meant to
8218  replace the original manual but is merely a short guide in how to realize
8219  the correct form of your paper.
8220  
8221 \end_layout
8222
8223 \begin_layout Standard
8224 Please note that the publisher of the journal was changed from Springer
8225  to EDP Sciences starting January 1, 2001.
8226  That change involved also some slight changes to the style files, namely
8227  the removal of the thesaurus command.
8228  The \SpecialChar LyX
8229  class aa supports the newest version of these style files, V 5.01.
8230  If you have an older version installed, please upgrade.
8231  For compatibility, the old (version 4) layout has been kept as 
8232 \family sans
8233 article (A&A V4)
8234 \family default
8235 .
8236  Please refer to the comments in 
8237 \family typewriter
8238 \SpecialChar LyX
8239 Dir/layouts/aapaper.layout
8240 \family default
8241 .
8242 \end_layout
8243
8244 \begin_layout Subsection
8245 Getting started
8246 \end_layout
8247
8248 \begin_layout Standard
8249 It is recommended you start from the example template distributed with \SpecialChar LyX
8250 .
8251  If you are not using a template, note the following settings:
8252 \end_layout
8253
8254 \begin_layout Itemize
8255 Select 
8256 \family sans
8257 article (A&A)
8258 \family default
8259  in the 
8260 \family sans
8261 Document\SpecialChar menuseparator
8262 Settings
8263 \family default
8264  dialog (OK, that one was obvious).
8265 \end_layout
8266
8267 \begin_layout Itemize
8268 Don't change the option 
8269 \family sans
8270 Page
8271 \begin_inset space ~
8272 \end_inset
8273
8274 style
8275 \family default
8276 : Leave it set to 
8277 \family sans
8278 default
8279 \family default
8280 .
8281  The whole layout is done by the macros, you shouldn't change anything.
8282 \end_layout
8283
8284 \begin_layout Subsection
8285 The header block
8286 \end_layout
8287
8288 \begin_layout Standard
8289 First thing to enter is the header information.
8290  It consists of seven entries, of which some are optional.
8291  They are
8292 \end_layout
8293
8294 \begin_layout Itemize
8295
8296 \family sans
8297 Title
8298 \family default
8299 : [required] 
8300 \end_layout
8301
8302 \begin_layout Itemize
8303
8304 \family sans
8305 Subtitle
8306 \family default
8307 : [optional] 
8308 \end_layout
8309
8310 \begin_layout Itemize
8311
8312 \family sans
8313 Author
8314 \family default
8315 : [required]
8316 \end_layout
8317
8318 \begin_layout Itemize
8319
8320 \family sans
8321 Address
8322 \family default
8323 : [required]
8324 \end_layout
8325
8326 \begin_layout Itemize
8327
8328 \family sans
8329 Offprints
8330 \family default
8331 : [optional] if more than one author: whom to contact for offprint requests.
8332 \end_layout
8333
8334 \begin_layout Itemize
8335
8336 \family sans
8337 Mail
8338 \family default
8339 : [optional] mail address for contacts.
8340 \end_layout
8341
8342 \begin_layout Itemize
8343
8344 \family sans
8345 Date
8346 \family default
8347 : [required].
8348  Suggested format is 
8349 \family typewriter
8350 Received: <date>; Accepted <date> 
8351 \end_layout
8352
8353 \begin_layout Standard
8354 There is no need to issue the 
8355 \family typewriter
8356
8357 \backslash
8358 maketitle
8359 \family default
8360  command, this is done automatically by \SpecialChar LyX
8361  when the header is finished.
8362  Although the order of the single header entries doesn't matter it is advised
8363  to keep the above sequence, just to get the best optics and meets the layout
8364  of the real document.
8365 \end_layout
8366
8367 \begin_layout Standard
8368 If you want to place footnotes in the header block, e.
8369 \begin_inset space \thinspace{}
8370 \end_inset
8371
8372 g.
8373 \begin_inset space \space{}
8374 \end_inset
8375
8376 to state your present address, just use the standard footnote via the menu
8377  
8378 \family sans
8379 Insert\SpecialChar menuseparator
8380 Footnote.
8381
8382 \family default
8383  \SpecialChar LyX
8384  will automagically use the term 
8385 \family typewriter
8386
8387 \backslash
8388 thanks{}
8389 \family default
8390  in that case.
8391 \end_layout
8392
8393 \begin_layout Standard
8394 In addition to these topics, the macros use three additional \SpecialChar LaTeX
8395  commands that
8396  have no counterpart in \SpecialChar LyX
8397 :
8398 \end_layout
8399
8400 \begin_layout Itemize
8401
8402 \family typewriter
8403
8404 \backslash
8405 and
8406 \family default
8407  to separate different names for more than one author and institute, respectivel
8408 y.
8409 \end_layout
8410
8411 \begin_layout Itemize
8412
8413 \family typewriter
8414
8415 \backslash
8416 inst{<nr>}
8417 \family default
8418 to mark corresponding author/institute pairs.
8419  The institutes are numbered sequentially as they appear in the 
8420 \family sans
8421 Address
8422 \family default
8423  field, so you have to put a marker to each author.
8424 \end_layout
8425
8426 \begin_layout Itemize
8427
8428 \family typewriter
8429
8430 \backslash
8431 email{address}
8432 \family default
8433  to supply an email address for fast contact.
8434 \end_layout
8435
8436 \begin_layout Standard
8437 In all cases, the appropriate command has to be entered in \SpecialChar LyX
8438  and marked as
8439  \SpecialChar LaTeX
8440  code.
8441  See the examples.
8442  
8443 \end_layout
8444
8445 \begin_layout Subsection
8446 The abstract
8447 \end_layout
8448
8449 \begin_layout Standard
8450 The abstract should immediately follow the header block.
8451  With version 5 the abstract environment was changed to a command, and there
8452  is now a resctriction to only one paragraph.
8453  In addition, it should contain an entry with the keywords.
8454  This is not yet implemented for \SpecialChar LyX
8455 , therefore you have to enter the \SpecialChar LaTeX
8456  command
8457  
8458 \family typewriter
8459
8460 \backslash
8461 keywords{}
8462 \family default
8463  by hand and mark it as \SpecialChar LaTeX
8464  code.
8465  Refer to the example paper.
8466 \end_layout
8467
8468 \begin_layout Subsection
8469 Supported environments
8470 \end_layout
8471
8472 \begin_layout Standard
8473 The A&A paper layout supports the following environments for structuring
8474  your text:
8475 \end_layout
8476
8477 \begin_layout Itemize
8478
8479 \family sans
8480 Standard
8481 \end_layout
8482
8483 \begin_layout Itemize
8484
8485 \family sans
8486 Section
8487 \end_layout
8488
8489 \begin_layout Itemize
8490
8491 \family sans
8492 Subsection
8493 \end_layout
8494
8495 \begin_layout Itemize
8496
8497 \family sans
8498 Subsubsection
8499 \end_layout
8500
8501 \begin_layout Itemize
8502
8503 \family sans
8504 Itemize
8505 \end_layout
8506
8507 \begin_layout Itemize
8508
8509 \family sans
8510 Enumerate
8511 \end_layout
8512
8513 \begin_layout Itemize
8514
8515 \family sans
8516 Description
8517 \end_layout
8518
8519 \begin_layout Itemize
8520
8521 \family sans
8522 Caption
8523 \end_layout
8524
8525 \begin_layout Itemize
8526
8527 \family sans
8528 Abstract
8529 \end_layout
8530
8531 \begin_layout Itemize
8532
8533 \family sans
8534 Acknowledgment
8535 \end_layout
8536
8537 \begin_layout Itemize
8538
8539 \family sans
8540 Bibliography
8541 \end_layout
8542
8543 \begin_layout Itemize
8544
8545 \family sans
8546 \SpecialChar LaTeX
8547
8548 \end_layout
8549
8550 \begin_layout Subsection
8551 Commands not supported by \SpecialChar LyX
8552
8553 \end_layout
8554
8555 \begin_layout Standard
8556 Some commands are not yet supported by the 
8557 \family sans
8558 paper (A&A)
8559 \family default
8560  layout for \SpecialChar LyX
8561 .
8562  Some have already been mentioned.
8563  For the sake of completeness, they are listed all together here:
8564 \end_layout
8565
8566 \begin_layout Itemize
8567
8568 \family typewriter
8569
8570 \backslash
8571 and
8572 \end_layout
8573
8574 \begin_layout Itemize
8575
8576 \family typewriter
8577
8578 \backslash
8579 email
8580 \end_layout
8581
8582 \begin_layout Itemize
8583
8584 \family typewriter
8585
8586 \backslash
8587 appendix
8588 \end_layout
8589
8590 \begin_layout Itemize
8591
8592 \family typewriter
8593
8594 \backslash
8595 authorrunning
8596 \end_layout
8597
8598 \begin_layout Itemize
8599
8600 \family typewriter
8601
8602 \backslash
8603 inst{}
8604 \end_layout
8605
8606 \begin_layout Itemize
8607
8608 \family typewriter
8609
8610 \backslash
8611 keywords{}
8612 \end_layout
8613
8614 \begin_layout Itemize
8615
8616 \family typewriter
8617
8618 \backslash
8619 object{}
8620 \end_layout
8621
8622 \begin_layout Itemize
8623
8624 \family typewriter
8625
8626 \backslash
8627 titlerunning{}
8628 \end_layout
8629
8630 \begin_layout Standard
8631 If you want to use any of these commands, you have to enter them yourself.
8632  
8633 \series bold
8634 Do not forget to mark them as \SpecialChar LaTeX
8635  code!
8636 \end_layout
8637
8638 \begin_layout Subsection
8639 Figure and Table Floats
8640 \end_layout
8641
8642 \begin_layout Standard
8643 \SpecialChar LyX
8644  provides support for the necessary float environments 
8645 \family sans
8646 figure, figure*, table
8647 \family default
8648  and 
8649 \family sans
8650 table*
8651 \family default
8652 , therefore we won't tell much about it here.
8653  Refer to the 
8654 \emph on
8655 User's
8656 \begin_inset space ~
8657 \end_inset
8658
8659 Guide
8660 \emph default
8661 .
8662  Just remember that tables should be left-aligned.
8663  For that, select the table and change the alignment in 
8664 \family sans
8665 Edit\SpecialChar menuseparator
8666 Paragraph
8667 \begin_inset space ~
8668 \end_inset
8669
8670 Settings.
8671 \end_layout
8672
8673 \begin_layout Standard
8674 There is only one special thing: the figures with caption besides the figure.
8675  To create such a figure, you have to do the following:
8676 \end_layout
8677
8678 \begin_layout Enumerate
8679 Create a wide figure float: 
8680 \family sans
8681 Insert\SpecialChar menuseparator
8682 Float\SpecialChar menuseparator
8683 Figure
8684 \family default
8685 , then right click in the figure and select 
8686 \family sans
8687 Span
8688 \begin_inset space ~
8689 \end_inset
8690
8691 columns
8692 \family default
8693 .
8694 \end_layout
8695
8696 \begin_layout Enumerate
8697 Enter your caption text.
8698 \end_layout
8699
8700 \begin_layout Enumerate
8701 Press 
8702 \family sans
8703 Return
8704 \family default
8705  to move the cursor above the caption.
8706 \end_layout
8707
8708 \begin_layout Enumerate
8709 Insert your figure
8710 \end_layout
8711
8712 \begin_layout Enumerate
8713 Position the cursor behind the figure and insert a horizontal fill: 
8714 \family sans
8715 Insert\SpecialChar menuseparator
8716 Special
8717 \begin_inset space ~
8718 \end_inset
8719
8720 Character\SpecialChar menuseparator
8721 Horizontal
8722 \begin_inset space ~
8723 \end_inset
8724
8725 Fill
8726 \family default
8727 .
8728 \end_layout
8729
8730 \begin_layout Enumerate
8731 Switch to \SpecialChar LaTeX
8732  mode: 
8733 \family sans
8734 M-c
8735 \begin_inset space ~
8736 \end_inset
8737
8738 t
8739 \family default
8740 .
8741 \end_layout
8742
8743 \begin_layout Enumerate
8744 Enter 
8745 \family typewriter
8746
8747 \backslash
8748 parbox[b]{55mm}{
8749 \family default
8750 .
8751  
8752 \series bold
8753 Do not close the brace!
8754 \end_layout
8755
8756 \begin_layout Enumerate
8757 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
8758  mode and insert
8759  the closing brace: 
8760 \family sans
8761 M-c
8762 \begin_inset space ~
8763 \end_inset
8764
8765 t
8766 \family default
8767  
8768 \family typewriter
8769 }
8770 \family default
8771 .
8772 \end_layout
8773
8774 \begin_layout Standard
8775 Also, refer to the figures in the example paper.
8776 \end_layout
8777
8778 \begin_layout Subsection
8779 Referee layout
8780 \end_layout
8781
8782 \begin_layout Standard
8783 For submission, the paper has to be formated in a special double-spacing
8784  layout.
8785  For this purpose, you have to give the option 
8786 \family typewriter
8787 referee
8788 \family default
8789  to the documentclass.
8790  This must be done using the extra class options field in the 
8791 \family sans
8792 Document\SpecialChar menuseparator
8793 Settings
8794 \family default
8795  dialog.
8796  Just enter the string 
8797 \family typewriter
8798 referee
8799 \family default
8800  there.
8801 \end_layout
8802
8803 \begin_layout Subsection
8804 The example paper
8805 \end_layout
8806
8807 \begin_layout Standard
8808 The 
8809 \family sans
8810 Examples
8811 \family default
8812  directory contains an example paper written with \SpecialChar LyX
8813 .
8814  It is the example paper from the original macro package, translated to
8815  \SpecialChar LyX
8816 .
8817  Use it for inspiration, and compare the original \SpecialChar LaTeX
8818  code with \SpecialChar LyX
8819  way of writing.
8820 \end_layout
8821
8822 \begin_layout Section
8823 AAS\SpecialChar TeX
8824
8825 \end_layout
8826
8827 \begin_layout Standard
8828 by 
8829 \noun on
8830 Mike Ressler
8831 \end_layout
8832
8833 \begin_layout Subsection
8834 Introduction
8835 \end_layout
8836
8837 \begin_layout Standard
8838 AAS\SpecialChar TeX
8839  is a set of macros produced by the American Astronomical Society to
8840  facilitate electronic manuscript submission to the three journals they
8841  publish: the Astrophysical Journal (including the Letters and Supplement),
8842  the Astronomical Journal, and the Publications of the Astronomical Society
8843  of the Pacific.
8844  \SpecialChar LyX
8845  has proven to be an excellent tool for generating these documents, especially
8846  given its equation, citation, and figure handling capabilities.
8847  \SpecialChar LyX
8848  requires version 5.0 (or higher) of these macros; preferably 5.2, which
8849  is the version described here, or higher.
8850  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
8851 2.09 and are fundamentally
8852  incompatible with \SpecialChar LyX
8853 .
8854  The AAS\SpecialChar TeX
8855  package may be downloaded from the AAS\SpecialChar TeX
8856  Web site
8857 \end_layout
8858
8859 \begin_layout Standard
8860 \begin_inset VSpace medskip
8861 \end_inset
8862
8863
8864 \end_layout
8865
8866 \begin_layout Standard
8867 \align center
8868 \begin_inset Flex URL
8869 status collapsed
8870
8871 \begin_layout Plain Layout
8872
8873 https://aas.org/aastex/aastex-downloads
8874 \end_layout
8875
8876 \end_inset
8877
8878
8879 \end_layout
8880
8881 \begin_layout Standard
8882 \begin_inset VSpace medskip
8883 \end_inset
8884
8885
8886 \end_layout
8887
8888 \begin_layout Standard
8889 A complete user guide is contained in that package and you should familiarize
8890  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
8891 .
8892  \SpecialChar LyX
8893  will not reduce the need to figure out all the AAS\SpecialChar TeX
8894  commands, it will only
8895  reduce the drudgery of typing everything in.
8896  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
8897  document conforms
8898  completely to the requirements of the journal to which you are submitting
8899  your paper.
8900 \end_layout
8901
8902 \begin_layout Subsection
8903 Starting a New Paper
8904 \end_layout
8905
8906 \begin_layout Standard
8907 I strongly suggest that you start with the AAS\SpecialChar TeX
8908  template file.
8909  Click on 
8910 \family sans
8911 File\SpecialChar menuseparator
8912 New from
8913 \family default
8914  
8915 \family sans
8916 Template
8917 \family default
8918 , enter the new file name, then choose the 
8919 \family typewriter
8920 aastex.lyx
8921 \family default
8922  template.
8923  This will show the most common fields found in a manuscript.
8924  Simply overwrite the existing text (including the brackets, 
8925 \family typewriter
8926 <>
8927 \family default
8928 ) with the correct information.
8929  Many of the AAS\SpecialChar TeX
8930  commands and environments can be implemented directly in
8931  \SpecialChar LyX
8932 , but some cannot: most noticeably 
8933 \family typewriter
8934
8935 \backslash
8936 altaffilmark
8937 \family default
8938  and 
8939 \family typewriter
8940
8941 \backslash
8942 altaffiltext
8943 \family default
8944 , which should stick out like a sore thumb if you actually just opened the
8945  template file.
8946  For commands such as these, the \SpecialChar LaTeX
8947  code must be entered directly and marked
8948  as such.
8949  Such commands are referred to as \SpecialChar TeX
8950  code, or Evil Red Text.
8951  I tried to minimize the amount of \SpecialChar TeX
8952  code needed in an AAS\SpecialChar TeX
8953  document, but
8954  there is still a bit more required than any of us would like.
8955 \end_layout
8956
8957 \begin_layout Subsection
8958 Finishing Your Paper
8959 \end_layout
8960
8961 \begin_layout Standard
8962 When the paper is finished to your satisfaction and previews/prints correctly,
8963  there are a few 
8964 \begin_inset Quotes eld
8965 \end_inset
8966
8967 postprocessing
8968 \begin_inset Quotes erd
8969 \end_inset
8970
8971  actions which need to be done before you submit it to the journals.
8972  
8973 \end_layout
8974
8975 \begin_layout Enumerate
8976 Export your paper as a \SpecialChar LaTeX
8977  file (
8978 \family sans
8979 File\SpecialChar menuseparator
8980 Export\SpecialChar menuseparator
8981 \SpecialChar LaTeX
8982
8983 \family default
8984 ).
8985  
8986 \end_layout
8987
8988 \begin_layout Enumerate
8989 Edit the resulting 
8990 \family typewriter
8991 .tex
8992 \family default
8993  file with your favorite text editor
8994 \end_layout
8995
8996 \begin_deeper
8997 \begin_layout Enumerate
8998 remove the comment lines before the 
8999 \family typewriter
9000
9001 \backslash
9002 documentclass
9003 \family default
9004  command
9005 \end_layout
9006
9007 \begin_layout Enumerate
9008 remove the 
9009 \family typewriter
9010
9011 \backslash
9012 usepackage...{fontenc}
9013 \family default
9014  line if it appears (usually just after 
9015 \family typewriter
9016
9017 \backslash
9018 documentclass
9019 \family default
9020 }; also remove the 
9021 \family typewriter
9022
9023 \backslash
9024 secnumdepth
9025 \family default
9026  line if it appears.
9027 \end_layout
9028
9029 \begin_layout Enumerate
9030 remove everything between (and including) the 
9031 \family typewriter
9032
9033 \backslash
9034 makeatletter
9035 \family default
9036  and 
9037 \family typewriter
9038
9039 \backslash
9040 makeatother
9041 \family default
9042  commands, except for any commands you specifically put into the \SpecialChar LaTeX
9043  preamble
9044  (which should appear immediately after the 
9045 \begin_inset Quotes eld
9046 \end_inset
9047
9048 User specified \SpecialChar LaTeX
9049  commands
9050 \begin_inset Quotes erd
9051 \end_inset
9052
9053  comment in the 
9054 \family typewriter
9055 .tex
9056 \family default
9057  file).
9058 \end_layout
9059
9060 \end_deeper
9061 \begin_layout Enumerate
9062 Run the resulting file through \SpecialChar LaTeX
9063  to make sure it still processes correctly.
9064 \end_layout
9065
9066 \begin_layout Enumerate
9067 Reread the journal requirements to make sure your filenames and formats
9068  are correct.
9069 \end_layout
9070
9071 \begin_layout Enumerate
9072 Submit it.
9073 \end_layout
9074
9075 \begin_layout Subsection
9076 Comments On Specific Commands
9077 \end_layout
9078
9079 \begin_layout Standard
9080 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
9081  commands: the
9082  AAS\SpecialChar TeX
9083  User Guide (
9084 \family typewriter
9085 aasguide.tex
9086 \family default
9087 ) gives a good description of each.
9088  Thus it's probably easiest for me to go down the list as found in the guide
9089  and offer comments where necessary.
9090  So let's begin \SpecialChar ldots
9091
9092 \end_layout
9093
9094 \begin_layout Subsubsection
9095 Things that work as expected
9096 \end_layout
9097
9098 \begin_layout Standard
9099 Because they work as you might expect, I simply list them and the section
9100  they are found in: 
9101 \family typewriter
9102
9103 \backslash
9104 documentclass
9105 \family default
9106  (2.1.1), 
9107 \family typewriter
9108
9109 \backslash
9110 begin{document}
9111 \family default
9112  (2.2), 
9113 \family typewriter
9114
9115 \backslash
9116 title
9117 \family default
9118  (2.3), 
9119 \family typewriter
9120
9121 \backslash
9122 author
9123 \family default
9124  (2.3), 
9125 \family typewriter
9126
9127 \backslash
9128 affil
9129 \family default
9130  (2.3), 
9131 \family typewriter
9132
9133 \backslash
9134 abstract
9135 \family default
9136  (2.4), 
9137 \family typewriter
9138
9139 \backslash
9140 keywords
9141 \family default
9142  (2.5), 
9143 \family typewriter
9144
9145 \backslash
9146 section
9147 \family default
9148  (2.7), 
9149 \family typewriter
9150
9151 \backslash
9152 subsection
9153 \family default
9154  (2.7), 
9155 \family typewriter
9156
9157 \backslash
9158 subsubsection
9159 \family default
9160  (2.7), 
9161 \family typewriter
9162
9163 \backslash
9164 paragraph
9165 \family default
9166  (2.7), 
9167 \family typewriter
9168
9169 \backslash
9170 facility
9171 \family default
9172  (2.10), 
9173 \family typewriter
9174
9175 \backslash
9176 begin{displaymath}
9177 \family default
9178  (2.12), 
9179 \family typewriter
9180
9181 \backslash
9182 begin{equation}
9183 \family default
9184  (2.12), 
9185 \family typewriter
9186
9187 \backslash
9188 begin{eqnarray}
9189 \family default
9190  (2.12), 
9191 \family typewriter
9192
9193 \backslash
9194 begin{mathletters}
9195 \family default
9196  (2.12), 
9197 \family typewriter
9198
9199 \backslash
9200 begin{thebibliography}
9201 \family default
9202  (2.13.1), 
9203 \family typewriter
9204
9205 \backslash
9206 bibitem
9207 \family default
9208  (2.13.2), all the cite commands and their variations (2.13.2), the generic
9209  graphicx figure commands (2.14.1), 
9210 \family typewriter
9211
9212 \backslash
9213 begin{table}
9214 \family default
9215  (2.15.4), 
9216 \family typewriter
9217
9218 \backslash
9219 begin{tabular}
9220 \family default
9221  (2.15.4), 
9222 \family typewriter
9223
9224 \backslash
9225 caption
9226 \family default
9227  (2.15.4), 
9228 \family typewriter
9229
9230 \backslash
9231 label
9232 \family default
9233  (2.15.4, amongst other places), 
9234 \family typewriter
9235
9236 \backslash
9237 tablerefs
9238 \family default
9239  (2.15.5), 
9240 \family typewriter
9241
9242 \backslash
9243 tablecomments
9244 \family default
9245  (2.15.5), 
9246 \family typewriter
9247
9248 \backslash
9249 url
9250 \family default
9251  (2.17.4), 
9252 \family typewriter
9253
9254 \backslash
9255 end{document}
9256 \family default
9257  (2.18).
9258 \end_layout
9259
9260 \begin_layout Standard
9261 The following style options also work correctly: 
9262 \family typewriter
9263 longabstract
9264 \family default
9265  (2.4), 
9266 \family typewriter
9267 preprint
9268 \family default
9269  (3.2.1), 
9270 \family typewriter
9271 preprint2
9272 \family default
9273  (3.2.2), 
9274 \family typewriter
9275 eqsecnum
9276 \family default
9277  (3.3), 
9278 \family typewriter
9279 flushrt
9280 \family default
9281  (3.4).
9282  Simply put them in the 
9283 \family sans
9284 Options
9285 \family default
9286  box in 
9287 \family sans
9288 Layout\SpecialChar menuseparator
9289 Document
9290 \family default
9291 .
9292 \end_layout
9293
9294 \begin_layout Subsubsection
9295 Things that work, but require more comment
9296 \end_layout
9297
9298 \begin_layout Standard
9299 The following items work, but require a little more discussion:
9300 \end_layout
9301
9302 \begin_layout Itemize
9303 These items are reserved for use by the journal editors, but you can put
9304  them into the \SpecialChar LaTeX
9305  preamble if you feel compelled to do so: 
9306 \family typewriter
9307
9308 \backslash
9309 received
9310 \family default
9311
9312 \family typewriter
9313
9314 \backslash
9315 revised
9316 \family default
9317
9318 \family typewriter
9319
9320 \backslash
9321 accepted
9322 \family default
9323
9324 \family typewriter
9325
9326 \backslash
9327 ccc
9328 \family default
9329
9330 \family typewriter
9331
9332 \backslash
9333 cpright
9334 \family default
9335  (all from 2.1.3)
9336 \end_layout
9337
9338 \begin_layout Itemize
9339 These items may be placed in the \SpecialChar LaTeX
9340  preamble, and are included as blanks in
9341  the template file: 
9342 \family typewriter
9343
9344 \backslash
9345 slugcomment
9346 \family default
9347  (2.1.4), 
9348 \family typewriter
9349
9350 \backslash
9351 shorttitle
9352 \family default
9353  (2.1.5), 
9354 \family typewriter
9355
9356 \backslash
9357 shortauthors
9358 \family default
9359  (2.1.5)
9360 \end_layout
9361
9362 \begin_layout Itemize
9363
9364 \family typewriter
9365
9366 \backslash
9367 email
9368 \family default
9369  (2.3) – can only be used 
9370 \begin_inset Quotes eld
9371 \end_inset
9372
9373 standalone
9374 \begin_inset Quotes erd
9375 \end_inset
9376
9377 , not in the middle of a paragraph.
9378  Use \SpecialChar TeX
9379  code if you need to embed it.
9380 \end_layout
9381
9382 \begin_layout Itemize
9383
9384 \family typewriter
9385
9386 \backslash
9387 and
9388 \family default
9389  (2.3) – will have extra {} after it.
9390  This should not cause an error.
9391 \end_layout
9392
9393 \begin_layout Itemize
9394
9395 \family typewriter
9396
9397 \backslash
9398 notetoeditor
9399 \family default
9400  (2.6) – can only be used 
9401 \begin_inset Quotes eld
9402 \end_inset
9403
9404 standalone
9405 \begin_inset Quotes erd
9406 \end_inset
9407
9408 , not in the middle of a paragraph.
9409  Use \SpecialChar TeX
9410  code if you need to embed it.
9411 \end_layout
9412
9413 \begin_layout Itemize
9414
9415 \family typewriter
9416
9417 \backslash
9418 placetable
9419 \family default
9420  (2.8) – can't insert a cross-reference tag, you must type the tag name by
9421  hand
9422 \end_layout
9423
9424 \begin_layout Itemize
9425
9426 \family typewriter
9427
9428 \backslash
9429 placefigure
9430 \family default
9431  (2.8) – same as for 
9432 \family typewriter
9433
9434 \backslash
9435 placetable
9436 \end_layout
9437
9438 \begin_layout Itemize
9439
9440 \family typewriter
9441
9442 \backslash
9443 acknowledgements
9444 \family default
9445  (2.9) – will have extra {} after it.
9446  This should not cause an error.
9447 \end_layout
9448
9449 \begin_layout Itemize
9450
9451 \family typewriter
9452
9453 \backslash
9454 appendix
9455 \family default
9456  (2.11) – will have extra {} after it.
9457  This should not cause an error.
9458 \end_layout
9459
9460 \begin_layout Itemize
9461
9462 \family typewriter
9463
9464 \backslash
9465 figcaption
9466 \family default
9467  (2.14.2) – you can insert an optional filename argument by placing the cursor
9468  at the beginning of the text and selecting 
9469 \family sans
9470 Insert\SpecialChar menuseparator
9471 Short Title
9472 \family default
9473 .
9474  
9475 \begin_inset Quotes eld
9476 \end_inset
9477
9478 Short Title
9479 \begin_inset Quotes erd
9480 \end_inset
9481
9482  inserts an optional argument of the type needed by 
9483 \family typewriter
9484
9485 \backslash
9486 figcaption
9487 \family default
9488 .
9489  Hopefully it will be renamed someday.
9490 \end_layout
9491
9492 \begin_layout Itemize
9493
9494 \family typewriter
9495
9496 \backslash
9497 objectname
9498 \family default
9499  (2.17.1) – same as 
9500 \family typewriter
9501
9502 \backslash
9503 figcaption
9504 \family default
9505  for the catalog ID optional parameter
9506 \end_layout
9507
9508 \begin_layout Itemize
9509
9510 \family typewriter
9511
9512 \backslash
9513 dataset
9514 \family default
9515  (2.17.1) – same as 
9516 \family typewriter
9517
9518 \backslash
9519 figcaption
9520 \family default
9521  for the catalog ID optional parameter
9522 \end_layout
9523
9524 \begin_layout Subsubsection
9525 Things not implemented, use \SpecialChar TeX
9526  code
9527 \end_layout
9528
9529 \begin_layout Standard
9530
9531 \family typewriter
9532
9533 \backslash
9534 altaffilmark
9535 \family default
9536  (2.3), 
9537 \family typewriter
9538
9539 \backslash
9540 altaffiltext
9541 \family default
9542  (2.3), 
9543 \family typewriter
9544
9545 \backslash
9546 eqnum
9547 \family default
9548  (2.12), 
9549 \family typewriter
9550
9551 \backslash
9552 setcounter{equation}
9553 \family default
9554  (2.12), Journal name abbreviations (2.13.4), 
9555 \family typewriter
9556
9557 \backslash
9558 figurenum
9559 \family default
9560  (2.14.1), 
9561 \family typewriter
9562
9563 \backslash
9564 epsscale
9565 \family default
9566  (2.14.1), 
9567 \family typewriter
9568
9569 \backslash
9570 plotone
9571 \family default
9572  (2.14.1), 
9573 \family typewriter
9574
9575 \backslash
9576 plottwo
9577 \family default
9578  (2.14.1), 
9579 \family typewriter
9580
9581 \backslash
9582 tablenum
9583 \family default
9584  (2.15.4), 
9585 \family typewriter
9586
9587 \backslash
9588 tableline
9589 \family default
9590  (2.15.4, insert it as the first element in the lefthand cell after where
9591  you want it.
9592  Don't use any of \SpecialChar LyX
9593 's rules in the table), 
9594 \family typewriter
9595
9596 \backslash
9597 tablenotemark
9598 \family default
9599  (2.15.5), 
9600 \family typewriter
9601
9602 \backslash
9603 tablenotetext
9604 \family default
9605  (2.15.5), much of Misc (2.17, except 
9606 \family typewriter
9607
9608 \backslash
9609 objectname
9610 \family default
9611
9612 \family typewriter
9613
9614 \backslash
9615 dataset
9616 \family default
9617
9618 \family typewriter
9619
9620 \backslash
9621 url
9622 \family default
9623 , and 
9624 \family typewriter
9625
9626 \backslash
9627 email
9628 \family default
9629 ; see above), 
9630 \family typewriter
9631
9632 \backslash
9633 singlespace
9634 \family default
9635  (3.1), 
9636 \family typewriter
9637
9638 \backslash
9639 doublespace
9640 \family default
9641  (3.1), 
9642 \family typewriter
9643
9644 \backslash
9645 onecolumn
9646 \family default
9647  (3.2), 
9648 \family typewriter
9649
9650 \backslash
9651 twocolumn
9652 \family default
9653  (3.2)
9654 \end_layout
9655
9656 \begin_layout Subsubsection
9657 Things that cannot be implemented
9658 \end_layout
9659
9660 \begin_layout Standard
9661 \SpecialChar ldots
9662  at least in any meaningful sort of way, so I suggest ignoring them.
9663  They are the references environment (2.13.3), and the deluxetable environment
9664  (2.15).
9665  If you really, really need to use deluxetable, I suggest editing it in
9666  a separate file with a text editor, then using 
9667 \family sans
9668 Insert\SpecialChar menuseparator
9669 Child
9670 \begin_inset space ~
9671 \end_inset
9672
9673 Document
9674 \family default
9675  to include it in your \SpecialChar LyX
9676  document.
9677  See the 
9678 \family typewriter
9679 aas_sample.lyx
9680 \family default
9681  file to see an example of this.
9682 \end_layout
9683
9684 \begin_layout Subsection
9685 FAQs, Tips, Tricks, and Other Ruminations
9686 \end_layout
9687
9688 \begin_layout Subsubsection
9689 Getting \SpecialChar LyX
9690  and AAS\SpecialChar TeX
9691  to cooperate
9692 \end_layout
9693
9694 \begin_layout Standard
9695 It can be a bit tricky to get \SpecialChar LyX
9696  to recognize a new layout and document class.
9697  When all else fails, do this:
9698 \end_layout
9699
9700 \begin_layout Enumerate
9701 Make certain that \SpecialChar LaTeX
9702  can find AAS\SpecialChar TeX
9703 .
9704  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
9705  distribution into a
9706  directory completely unrelated to \SpecialChar LaTeX
9707  or AAS\SpecialChar TeX
9708  and run \SpecialChar LaTeX
9709  on 
9710 \family typewriter
9711 sample.tex
9712 \family default
9713 .
9714 \end_layout
9715
9716 \begin_layout Enumerate
9717 Make certain that 
9718 \family typewriter
9719 aastex.layout
9720 \family default
9721  appears in \SpecialChar LyX
9722 's 
9723 \family typewriter
9724 layouts
9725 \family default
9726  folder
9727 \end_layout
9728
9729 \begin_layout Enumerate
9730 Rerun 
9731 \family sans
9732 Tools\SpecialChar menuseparator
9733 Reconfigure
9734 \family default
9735  in \SpecialChar LyX
9736 , then restart \SpecialChar LyX
9737 .
9738 \end_layout
9739
9740 \begin_layout Enumerate
9741 Open a regular new file, not from a template.
9742  Does AAS\SpecialChar TeX
9743  appear in the class list in 
9744 \family sans
9745 Document\SpecialChar menuseparator
9746 Settings
9747 \family default
9748 ?
9749 \end_layout
9750
9751 \begin_layout Standard
9752 If you get a warning from an existing AAS\SpecialChar TeX
9753  document about not being able
9754  to find the AAS\SpecialChar TeX
9755  layout or a message about 
9756 \begin_inset Quotes eld
9757 \end_inset
9758
9759 You should not mix title layouts with normal ones
9760 \begin_inset Quotes erd
9761 \end_inset
9762
9763 , things haven't been installed correctly.
9764 \end_layout
9765
9766 \begin_layout Subsubsection
9767 \SpecialChar LaTeX
9768  error processing a table 
9769 \end_layout
9770
9771 \begin_layout Standard
9772 \SpecialChar LyX
9773 , by default, attempts to center the table caption/title.
9774  This seems to produce a bad interaction in AAS\SpecialChar TeX
9775  so you should click somewhere
9776  in the caption/title, then select 
9777 \family sans
9778 Edit\SpecialChar menuseparator
9779 Paragraph
9780 \begin_inset space ~
9781 \end_inset
9782
9783 Settings
9784 \family default
9785 , then set the 
9786 \family sans
9787 Alignment
9788 \family default
9789  to 
9790 \family sans
9791 Block
9792 \family default
9793 .
9794  This took care of it for me.
9795 \end_layout
9796
9797 \begin_layout Subsubsection
9798 References
9799 \end_layout
9800
9801 \begin_layout Standard
9802 A couple of things: 1) I have noticed some funny spacing in the reference
9803  entries in the text.
9804  When you enter the bibliography item data, make sure their is 
9805 \emph on
9806 no
9807 \emph default
9808  space between the last author and the parenthesis setting off the year;
9809  
9810 \emph on
9811 e.
9812 \begin_inset space \thinspace{}
9813 \end_inset
9814
9815 g.
9816 \begin_inset space \space{}
9817 \end_inset
9818
9819
9820 \emph default
9821 type 
9822 \family typewriter
9823 Ressler(1992)
9824 \family default
9825 , not 
9826 \family typewriter
9827 Ressler (1992)
9828 \family default
9829 .
9830  2) Entering the references at all is not obvious.
9831  The easiest thing is to start typing your first reference at the end of
9832  the document, then mark it as type 
9833 \family sans
9834 References
9835 \family default
9836 .
9837  That will put a small gray box in front of what you just typed.
9838  Click on the box to fill in the rest of the information.
9839  For new references, go to the end of an existing reference and press return.
9840  That will create a new line with its own box, etc.
9841 \end_layout
9842
9843 \begin_layout Subsubsection
9844 Including EPS files
9845 \end_layout
9846
9847 \begin_layout Standard
9848 Even though AAS\SpecialChar TeX
9849  provides its own figure commands (
9850 \family typewriter
9851
9852 \backslash
9853 plotone
9854 \family default
9855 , for example), I much prefer \SpecialChar LaTeX
9856 's standard figure commands (with the default
9857  graphicx).
9858  You can insert the 
9859 \family typewriter
9860
9861 \backslash
9862 plotone
9863 \family default
9864 , etc.
9865 \begin_inset space ~
9866 \end_inset
9867
9868 commands as \SpecialChar TeX
9869  code into a Figure Float box if you desire, but I never have
9870  much luck getting the layout right.
9871  With the standard graphics, \SpecialChar LyX
9872  will insert a 
9873 \family typewriter
9874
9875 \backslash
9876 usepackage{graphicx}
9877 \family default
9878  command into the \SpecialChar LaTeX
9879  preamble and handle the figures in the standard \SpecialChar LaTeX2e
9880  way,
9881  interspersing the figures in the text.
9882  I believe ApJ accepts figures exactly this way now; AJ might still use
9883  the 
9884 \begin_inset Quotes eld
9885 \end_inset
9886
9887 stack everything at the end
9888 \begin_inset Quotes erd
9889 \end_inset
9890
9891  technique.
9892 \end_layout
9893
9894 \begin_layout Subsubsection
9895 Things I could have done, but didn't
9896 \end_layout
9897
9898 \begin_layout Standard
9899 There are a few 
9900 \begin_inset Quotes eld
9901 \end_inset
9902
9903 pretty
9904 \begin_inset Quotes erd
9905 \end_inset
9906
9907  things I could have implemented, but chose not to.
9908  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
9909  window,
9910  even though it is double-spaced in the paper manuscript.
9911  Also, I chose not to make separate layouts for the preprint and preprint2
9912  styles.
9913  Since I assume you will spend most of your time in the plain manuscript
9914  mode anyway, I decided not to chew up more disk space with this.
9915  
9916 \end_layout
9917
9918 \begin_layout Subsection
9919 Final Caveat
9920 \end_layout
9921
9922 \begin_layout Standard
9923 Your mileage may vary.
9924  I've now had papers published by both ApJ and AJ that have had 98% of the
9925  effort done in \SpecialChar LyX
9926 ; the last 2% was the \SpecialChar LaTeX
9927  post-processing and a few cleanups.
9928  I have had no trouble with the submission process, and I'm sure the journals
9929  were never aware that there might be a difference.
9930  So, go forth and publish!
9931 \end_layout
9932
9933 \begin_layout Section
9934 AMS \SpecialChar LaTeX
9935
9936 \end_layout
9937
9938 \begin_layout Standard
9939 by 
9940 \noun on
9941 David Johnson
9942 \noun default
9943 ; updated by 
9944 \noun on
9945 Richard Heck
9946 \end_layout
9947
9948 \begin_layout Standard
9949 \begin_inset VSpace bigskip
9950 \end_inset
9951
9952
9953 \end_layout
9954
9955 \begin_layout Standard
9956 \noindent
9957 The AMS \SpecialChar LaTeX
9958  layouts are set up to conform to suggested styles for mathematical
9959  papers to be submitted to American Mathematical Society publications.
9960  The layouts are not tailored to a specific journal, but easily can be.
9961  You should refer to the AMS documentation for specific instructions for
9962  each journal (usually it will entail only changing a single line in the
9963  \SpecialChar TeX
9964  output).
9965  That documentation is available on the Web at 
9966 \begin_inset Flex URL
9967 status open
9968
9969 \begin_layout Plain Layout
9970
9971 http://www.ams.org
9972 \end_layout
9973
9974 \end_inset
9975
9976  or by ftp at 
9977 \begin_inset Flex URL
9978 status open
9979
9980 \begin_layout Plain Layout
9981
9982 ftp://ftp.ams.org/pub/tex/amslatex/
9983 \end_layout
9984
9985 \end_inset
9986
9987 .
9988  These layouts are appropriate, and useful, for any mathematical writing.
9989  
9990 \end_layout
9991
9992 \begin_layout Standard
9993 There are two basic AMS \SpecialChar LaTeX
9994  layouts: 
9995 \end_layout
9996
9997 \begin_layout Itemize
9998 amsart: The standard AMS article format.
9999 \end_layout
10000
10001 \begin_layout Itemize
10002 amsbook: the standard AMS book (really, monograph) format.
10003  
10004 \end_layout
10005
10006 \begin_layout Standard
10007 The layouts themselves contain only the minimum necessary to use the AMS
10008  classes.
10009  They do not, in particular, contain any of the `theorem' environments used
10010  for setting theorems, lemmas, and the like.
10011  These are contained, instead, in the 
10012 \begin_inset Flex Code
10013 status collapsed
10014
10015 \begin_layout Plain Layout
10016 Theorems (AMS)
10017 \end_layout
10018
10019 \end_inset
10020
10021  module, which is loaded by default when you select one of the AMS classes.
10022  (It can also be used with other classes and can be removed, if you would
10023  rather use something else.) Less commonly used environments are in the 
10024 \begin_inset Flex Code
10025 status collapsed
10026
10027 \begin_layout Plain Layout
10028 Theorems (AMS-Extended)
10029 \end_layout
10030
10031 \end_inset
10032
10033  module, which must be loaded manually.
10034 \end_layout
10035
10036 \begin_layout Standard
10037 By default, theorems and the like are numbered consecutively throughout
10038  the document, but this may be modified by loading the module 
10039 \begin_inset Flex Code
10040 status collapsed
10041
10042 \begin_layout Plain Layout
10043 Theorems (Order by Section)
10044 \end_layout
10045
10046 \end_inset
10047
10048  or, if you are using 
10049 \begin_inset Flex Code
10050 status collapsed
10051
10052 \begin_layout Plain Layout
10053 book (AMS)
10054 \end_layout
10055
10056 \end_inset
10057
10058 , the module 
10059 \begin_inset Flex Code
10060 status collapsed
10061
10062 \begin_layout Plain Layout
10063 Theorems (Order by Chapter)
10064 \end_layout
10065
10066 \end_inset
10067
10068 .
10069  These will number the results as 
10070 \begin_inset Formula $n.m$
10071 \end_inset
10072
10073 , where the first number refers to the section (or chapter) and the second
10074  refers to the total number of results so far in that section (or chapter).
10075  Many environments are also available unnumbered.
10076  These are indicated by an asterisk at the end.
10077  If you happen to want 
10078 \emph on
10079 only
10080 \emph default
10081  unnumbered results, the module 
10082 \begin_inset Flex Code
10083 status collapsed
10084
10085 \begin_layout Plain Layout
10086 Theorems (Starred)
10087 \end_layout
10088
10089 \end_inset
10090
10091  provides that option.
10092 \end_layout
10093
10094 \begin_layout Standard
10095 Note that these modules do not 
10096 \emph on
10097 have
10098 \emph default
10099  to be used with the AMS classes.
10100  It is perfectly possible to use the 
10101 \begin_inset Flex Code
10102 status collapsed
10103
10104 \begin_layout Plain Layout
10105 Theorems (AMS)
10106 \end_layout
10107
10108 \end_inset
10109
10110  module, and the others mentioned, with other classes, such as 
10111 \begin_inset Flex Code
10112 status collapsed
10113
10114 \begin_layout Plain Layout
10115 article
10116 \end_layout
10117
10118 \end_inset
10119
10120
10121 \begin_inset Flex Code
10122 status collapsed
10123
10124 \begin_layout Plain Layout
10125 report
10126 \end_layout
10127
10128 \end_inset
10129
10130
10131 \begin_inset Flex Code
10132 status collapsed
10133
10134 \begin_layout Plain Layout
10135 book (KOMA-script)
10136 \end_layout
10137
10138 \end_inset
10139
10140 , and so forth.
10141 \end_layout
10142
10143 \begin_layout Subsection
10144 What these layouts provide
10145 \end_layout
10146
10147 \begin_layout Standard
10148 There is a long list of included environments provided by these layouts.
10149  In AMS-\SpecialChar LaTeX
10150 , there is, in fact, an opportunity to define an unlimited variety
10151  of `theorem' environments.
10152  However, the AMS recommends the environments that are available in \SpecialChar LyX
10153 .
10154  
10155 \end_layout
10156
10157 \begin_layout Standard
10158 The following environments—as well as the standard environments, such as
10159  
10160 \begin_inset Flex Noun
10161 status collapsed
10162
10163 \begin_layout Plain Layout
10164 section
10165 \end_layout
10166
10167 \end_inset
10168
10169
10170 \begin_inset Flex Noun
10171 status collapsed
10172
10173 \begin_layout Plain Layout
10174 bibliography
10175 \end_layout
10176
10177 \end_inset
10178
10179
10180 \begin_inset Flex Noun
10181 status collapsed
10182
10183 \begin_layout Plain Layout
10184 title
10185 \end_layout
10186
10187 \end_inset
10188
10189
10190 \begin_inset Flex Noun
10191 status collapsed
10192
10193 \begin_layout Plain Layout
10194 author
10195 \end_layout
10196
10197 \end_inset
10198
10199 , and 
10200 \begin_inset Flex Noun
10201 status collapsed
10202
10203 \begin_layout Plain Layout
10204 date
10205 \end_layout
10206
10207 \end_inset
10208
10209 —are provided by 
10210 \begin_inset Flex Code
10211 status collapsed
10212
10213 \begin_layout Plain Layout
10214 article (AMS)
10215 \end_layout
10216
10217 \end_inset
10218
10219  and 
10220 \begin_inset Flex Code
10221 status collapsed
10222
10223 \begin_layout Plain Layout
10224 book (AMS)
10225 \end_layout
10226
10227 \end_inset
10228
10229 :
10230 \end_layout
10231
10232 \begin_layout Description
10233 Address This should be the author's permanent address.
10234 \end_layout
10235
10236 \begin_layout Description
10237 Current
10238 \begin_inset space ~
10239 \end_inset
10240
10241 Address This should be the author's temporary address at the time of submission,
10242  if different from the Address.
10243 \end_layout
10244
10245 \begin_layout Description
10246 Email Author's e-mail address
10247 \end_layout
10248
10249 \begin_layout Description
10250 URL Author's Web address, if desired.
10251 \end_layout
10252
10253 \begin_layout Description
10254 Keywords Key words or phrases used to identify specific topics discussed
10255  in the paper.
10256 \end_layout
10257
10258 \begin_layout Description
10259 Subjectclass These refer to the AMS Subject Classifications, published and
10260  described in 
10261 \emph on
10262 Mathematical Reviews
10263 \emph default
10264 .
10265  These are also available online at the AMS cites listed above.
10266 \end_layout
10267
10268 \begin_layout Description
10269 Thanks
10270 \end_layout
10271
10272 \begin_layout Description
10273 Dedicatory
10274 \end_layout
10275
10276 \begin_layout Description
10277 Translator
10278 \end_layout
10279
10280 \begin_layout Standard
10281 The following environments are provided by both the 
10282 \begin_inset Flex Code
10283 status collapsed
10284
10285 \begin_layout Plain Layout
10286 Theorems
10287 \end_layout
10288
10289 \end_inset
10290
10291  and 
10292 \begin_inset Flex Code
10293 status collapsed
10294
10295 \begin_layout Plain Layout
10296 Theorems (AMS)
10297 \end_layout
10298
10299 \end_inset
10300
10301  modules, in the latter case in both starred (unnumbered) and unstarred
10302  (numbered) versions.
10303  These same environments are provided only in the starred versions by the
10304  
10305 \begin_inset Flex Code
10306 status collapsed
10307
10308 \begin_layout Plain Layout
10309 Theorems (Starred)
10310 \end_layout
10311
10312 \end_inset
10313
10314  module:
10315 \end_layout
10316
10317 \begin_layout Theorem
10318 This is typically used for the statements of major results.
10319  
10320 \end_layout
10321
10322 \begin_layout Corollary*
10323 This is used for statements which follow fairly directly from previous statement
10324 s.
10325  Again, these can be major results.
10326  
10327 \end_layout
10328
10329 \begin_layout Lemma
10330 These are smaller results needed to prove other statements.
10331 \end_layout
10332
10333 \begin_layout Proposition
10334 These are less major results which (hopefully) add to the general theory
10335  being discussed.
10336 \end_layout
10337
10338 \begin_layout Conjecture
10339 These are statements provided without justification, which the author does
10340  not know how to prove, but which seem to be true (to the author, at least).
10341 \end_layout
10342
10343 \begin_layout Definition*
10344 Guess what this is for.
10345  The font is different for this environment than for the previous ones.
10346  
10347 \end_layout
10348
10349 \begin_layout Example*
10350 Used for examples illustrating proven results.
10351 \end_layout
10352
10353 \begin_layout Problem
10354 It's not really known what this is for.
10355  You should figure it out.
10356 \end_layout
10357
10358 \begin_layout Exercise*
10359 Write a description for this one.
10360 \end_layout
10361
10362 \begin_layout Remark
10363 This environment is also a type of theorem, usually a lesser sort of observation.
10364 \end_layout
10365
10366 \begin_layout Claim*
10367 Often used in the course of giving a proof of a larger result.
10368 \end_layout
10369
10370 \begin_layout Case
10371 Generally, these are used to break up long arguments, using specific instances
10372  of some condition.
10373  
10374 \end_layout
10375
10376 \begin_layout Case
10377 The numbering scheme for cases is on its own, not together with other numbered
10378  statements.
10379  
10380 \end_layout
10381
10382 \begin_layout Proof
10383 At the end of this environment, a QED symbol (usually a square, but it can
10384  vary with different styles) is placed.
10385  If you want to have other environments within this one—for example, Case
10386  environments—and have the QED symbol appear only after them, then the other
10387  environments need to be nested within the proof environment.
10388  See the section 
10389 \emph on
10390 Nesting Environments
10391 \emph default
10392  of the 
10393 \emph on
10394 User's Guide
10395 \emph default
10396  for information on nesting.
10397 \end_layout
10398
10399 \begin_layout Standard
10400 And these environments are provided by 
10401 \begin_inset Flex Code
10402 status collapsed
10403
10404 \begin_layout Plain Layout
10405 Theorems (AMS-Extended)
10406 \end_layout
10407
10408 \end_inset
10409
10410 :
10411 \end_layout
10412
10413 \begin_layout Criterion*
10414 A required condition.
10415 \end_layout
10416
10417 \begin_layout Algorithm*
10418 A general procedure to be used.
10419 \end_layout
10420
10421 \begin_layout Axiom*
10422 This is a property or statement taken as true within the system being discussed.
10423 \end_layout
10424
10425 \begin_layout Condition*
10426 Sometimes used to state a condition assumed within the present context of
10427  discussion.
10428 \end_layout
10429
10430 \begin_layout Note*
10431 Similar to a Remark.
10432 \end_layout
10433
10434 \begin_layout Notation*
10435 Used for the explanation of, yes, notation.
10436 \end_layout
10437
10438 \begin_layout Summary
10439 Do we really need to tell you? 
10440 \end_layout
10441
10442 \begin_layout Acknowledgement*
10443 Acknowledgement.
10444 \end_layout
10445
10446 \begin_layout Conclusion*
10447 Sometimes used at the end of a long train of argument.
10448 \end_layout
10449
10450 \begin_layout Fact
10451 Used in a way similar to Proposition, though perhaps lower on the scale.
10452 \end_layout
10453
10454 \begin_layout Standard
10455 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
10456  and AMS fonts
10457  packages.
10458  They need to be available on your system in order to use these environments.
10459 \end_layout
10460
10461 \begin_layout Section
10462 AGU journals (
10463 \family sans
10464 aguplus
10465 \family default
10466 )
10467 \end_layout
10468
10469 \begin_layout Standard
10470 by 
10471 \shape smallcaps
10472 Martin Vermeer
10473 \end_layout
10474
10475 \begin_layout Subsection
10476 Description
10477 \end_layout
10478
10479 \begin_layout Standard
10480 These are the layout files for some of the journals of the American Geophysical
10481  Society.
10482  It is assumed that you have both the AGU's own class files and AGUplus
10483  installed (everything to be found at
10484 \begin_inset Flex URL
10485 status collapsed
10486
10487 \begin_layout Plain Layout
10488
10489 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
10490 \end_layout
10491
10492 \end_inset
10493
10494 ).
10495 \end_layout
10496
10497 \begin_layout Subsection
10498 New styles
10499 \end_layout
10500
10501 \begin_layout Standard
10502 Redefined are 
10503 \family sans
10504 Paragraph
10505 \family default
10506
10507 \family sans
10508 Paragraph*
10509 \family default
10510 .
10511  They are still called this in the \SpecialChar LyX
10512  GUI, though their \SpecialChar LaTeX
10513  equivalents in the
10514  AGU classes are 
10515 \family sans
10516 Subsubsubsection
10517 \family default
10518  and 
10519 \family sans
10520 Subsubsubsection*
10521 \family default
10522 .
10523 \end_layout
10524
10525 \begin_layout Standard
10526 Newly defined styles are 
10527 \family sans
10528 Left_Header
10529 \family default
10530
10531 \family sans
10532 Right_Header
10533 \family default
10534
10535 \family sans
10536 Received
10537 \family default
10538
10539 \family sans
10540 Revised
10541 \family default
10542
10543 \family sans
10544 Accepted
10545 \family default
10546
10547 \family sans
10548 CCC
10549 \family default
10550
10551 \family sans
10552 PaperId
10553 \family default
10554
10555 \family sans
10556 AuthorAddr
10557 \family default
10558
10559 \family sans
10560 SlugComment
10561 \family default
10562 .
10563  These are mostly manuscript attributes and defined in the AGU class documentati
10564 on.
10565 \end_layout
10566
10567 \begin_layout Standard
10568 I suspect this is still badly incomplete.
10569 \end_layout
10570
10571 \begin_layout Subsection
10572 New floats
10573 \end_layout
10574
10575 \begin_layout Standard
10576
10577 \family sans
10578 Planotable
10579 \family default
10580  and 
10581 \family sans
10582 Plate
10583 \family default
10584 .
10585  We also have a new 
10586 \family sans
10587 Table_Caption
10588 \family default
10589 .
10590 \end_layout
10591
10592 \begin_layout Subsection
10593 Supported journals
10594 \end_layout
10595
10596 \begin_layout Itemize
10597
10598 \emph on
10599 Journal of Geophysical Research
10600 \emph default
10601
10602 \family typewriter
10603 jgrga.layout
10604 \family default
10605  — Martin Vermeer
10606 \end_layout
10607
10608 \begin_layout Standard
10609 Add your own, it isn't so hard! Look at the 
10610 \family typewriter
10611 jgrga.layout
10612 \family default
10613  example and 
10614 \family typewriter
10615 aguplus.inc
10616 \family default
10617 .
10618 \end_layout
10619
10620 \begin_layout Subsection
10621 Bugs and things to remember
10622 \end_layout
10623
10624 \begin_layout Standard
10625 In order to use the new layouts, you must remember to do the following for
10626  a new document:
10627 \end_layout
10628
10629 \begin_layout Enumerate
10630
10631 \emph on
10632 Turn off babel
10633 \emph default
10634 .
10635  This can be done in the 
10636 \family sans
10637 Layout\SpecialChar menuseparator
10638 Document
10639 \family default
10640  or 
10641 \family sans
10642 Document\SpecialChar menuseparator
10643 Settings
10644 \family default
10645  menu item.
10646  (AGU articles are always in English, right? So 
10647 \emph on
10648 don't
10649 \emph default
10650  choose a language.)
10651 \end_layout
10652
10653 \begin_layout Enumerate
10654 Enter 
10655 \family typewriter
10656 jgrga
10657 \family default
10658  into the document's 
10659 \family sans
10660 Extra Options
10661 \family default
10662  field.
10663  (Yes, this is a bug.)
10664 \end_layout
10665
10666 \begin_layout Enumerate
10667 Make sure you use the 
10668 \family typewriter
10669 agu.bst
10670 \family default
10671  bibliography style, by entering 
10672 \family sans
10673 agu
10674 \family default
10675  into the second field of the Bib\SpecialChar TeX
10676  inset.
10677  None of the standard styles will do.
10678 \end_layout
10679
10680 \begin_layout Section
10681 Broadway
10682 \end_layout
10683
10684 \begin_layout Standard
10685 by 
10686 \shape smallcaps
10687 Garst Reese
10688 \end_layout
10689
10690 \begin_layout Subsection
10691 Introduction
10692 \end_layout
10693
10694 \begin_layout Standard
10695 Broadway is for writing plays.
10696  The format is more decorative than Hollywood, and much less standardized.
10697  This format should be suitable for workshops.
10698 \end_layout
10699
10700 \begin_layout Subsection
10701 Special problems
10702 \end_layout
10703
10704 \begin_layout Standard
10705 The same as in Hollywood.
10706 \end_layout
10707
10708 \begin_layout Subsection
10709 Special features
10710 \end_layout
10711
10712 \begin_layout Standard
10713 Insert the 
10714 \family sans
10715 Speaker
10716 \family default
10717  names as labels then cross-reference the label to insert the name.
10718  The cross-reference dialog will show the current cast of characters.
10719 \end_layout
10720
10721 \begin_layout Subsection
10722 Paper size and Margins
10723 \end_layout
10724
10725 \begin_layout Standard
10726 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10727 \end_layout
10728
10729 \begin_layout Subsection
10730 Environments
10731 \end_layout
10732
10733 \begin_layout Standard
10734 The following environments are available.
10735  You can use broadway.bind to get the bind keys shown at the right.
10736 \end_layout
10737
10738 \begin_layout Itemize
10739
10740 \family sans
10741 Standard
10742 \begin_inset Newline newline
10743 \end_inset
10744
10745
10746 \family default
10747 You should not have to use this, but it is here for anything that does not
10748  fit otherwise.
10749 \end_layout
10750
10751 \begin_layout Itemize
10752
10753 \family sans
10754 Narrative
10755 \begin_inset space \hfill{}
10756 \end_inset
10757
10758 M-z n
10759 \begin_inset Newline newline
10760 \end_inset
10761
10762
10763 \family default
10764 Used to describe stage setting and the action.
10765  First use of speaker names in all CAPs.
10766 \end_layout
10767
10768 \begin_layout Itemize
10769
10770 \family sans
10771 ACT
10772 \begin_inset space \hfill{}
10773 \end_inset
10774
10775 M-z a
10776 \begin_inset Newline newline
10777 \end_inset
10778
10779
10780 \family default
10781 Automatically numbered.
10782  On screen it will be arabic, but will print as Roman.
10783 \end_layout
10784
10785 \begin_layout Itemize
10786
10787 \family sans
10788 ACT*
10789 \begin_inset space \hfill{}
10790 \end_inset
10791
10792 M-z S at
10793 \begin_inset Newline newline
10794 \end_inset
10795
10796
10797 \family default
10798 Subtitle for 
10799 \family sans
10800 ACT.
10801
10802 \family default
10803  It is just centered text.
10804 \end_layout
10805
10806 \begin_layout Itemize
10807
10808 \family sans
10809 SCENE
10810 \begin_inset space \hfill{}
10811 \end_inset
10812
10813 M-z S-S
10814 \begin_inset Newline newline
10815 \end_inset
10816
10817
10818 \family default
10819 Not automatically numbered.
10820  You supply the number.
10821  This is because I couldn't figure out how.
10822 \end_layout
10823
10824 \begin_layout Itemize
10825
10826 \family sans
10827 AT_RISE:
10828 \begin_inset space \hfill{}
10829 \end_inset
10830
10831 M-z S-R
10832 \begin_inset Newline newline
10833 \end_inset
10834
10835
10836 \family default
10837 A special case of Narrative to describe the setting and action as the curtain
10838  rises.
10839 \end_layout
10840
10841 \begin_layout Itemize
10842
10843 \family sans
10844 Speaker
10845 \begin_inset space \hfill{}
10846 \end_inset
10847
10848 M-z s
10849 \begin_inset Newline newline
10850 \end_inset
10851
10852
10853 \family default
10854 The speaker's (actor's) title, centered in all CAPS.
10855 \end_layout
10856
10857 \begin_layout Itemize
10858
10859 \family sans
10860 Parenthetical
10861 \begin_inset space \hfill{}
10862 \end_inset
10863
10864 M-z p
10865 \begin_inset Newline newline
10866 \end_inset
10867
10868
10869 \family default
10870 Instructions to the speaker.
10871  The parentheses are automatically inserted.
10872  The ( will appear on screen, but both will be in the printed play.
10873  This environment is only used within 
10874 \family sans
10875 Dialogue
10876 \family default
10877 .
10878 \end_layout
10879
10880 \begin_layout Itemize
10881
10882 \family sans
10883 Dialogue
10884 \begin_inset space \hfill{}
10885 \end_inset
10886
10887 M-z d
10888 \begin_inset Newline newline
10889 \end_inset
10890
10891
10892 \family default
10893 What the Speaker says.
10894 \end_layout
10895
10896 \begin_layout Itemize
10897
10898 \family sans
10899 CURTAIN
10900 \begin_inset space \hfill{}
10901 \end_inset
10902
10903 M-z S-C
10904 \begin_inset Newline newline
10905 \end_inset
10906
10907
10908 \family default
10909 The curtain comes down.
10910 \end_layout
10911
10912 \begin_layout Itemize
10913
10914 \family sans
10915 Title
10916 \begin_inset space \hfill{}
10917 \end_inset
10918
10919 M-z S-T
10920 \end_layout
10921
10922 \begin_layout Itemize
10923
10924 \family sans
10925 Author
10926 \begin_inset space \hfill{}
10927 \end_inset
10928
10929 M-z S-A
10930 \end_layout
10931
10932 \begin_layout Itemize
10933
10934 \family sans
10935 Right_Address
10936 \begin_inset space \hfill{}
10937 \end_inset
10938
10939 M-z r
10940 \end_layout
10941
10942 \begin_layout Standard
10943 Hello there.
10944 \end_layout
10945
10946 \begin_layout Section
10947 Dinbrief
10948 \end_layout
10949
10950 \begin_layout Standard
10951 The document class 
10952 \family sans
10953 dinbrief
10954 \family default
10955  can be used to type letters according to German conventions.
10956  A template file is included in 
10957 \family typewriter
10958 .../lyx/share/templates
10959 \family default
10960  for you to use as a starting point.
10961 \end_layout
10962
10963 \begin_layout Section
10964 EGS journals (
10965 \family sans
10966 egs
10967 \family default
10968 )
10969 \end_layout
10970
10971 \begin_layout Standard
10972 by 
10973 \shape smallcaps
10974 Martin Vermeer
10975 \end_layout
10976
10977 \begin_layout Subsection
10978 Description
10979 \end_layout
10980
10981 \begin_layout Standard
10982 This is the layout file for the European Geophysical Society journals.
10983  The needed 
10984 \family typewriter
10985 egs.cls
10986 \family default
10987  can be downloaded from the web site of the EGS under 
10988 \begin_inset Flex URL
10989 status collapsed
10990
10991 \begin_layout Plain Layout
10992
10993 www.copernicus.org
10994 \end_layout
10995
10996 \end_inset
10997
10998 .
10999 \end_layout
11000
11001 \begin_layout Subsection
11002 New styles
11003 \end_layout
11004
11005 \begin_layout Standard
11006
11007 \family sans
11008 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
11009  Accepted
11010 \family default
11011
11012 \family sans
11013 Offsets
11014 \family default
11015 .
11016  The current layout file is unfortunately very unmodular and would benefit
11017  from using the various 
11018 \family typewriter
11019 std*.inc
11020 \family default
11021  file inclusions.
11022 \end_layout
11023
11024 \begin_layout Section
11025 Elsevier Journals
11026 \end_layout
11027
11028 \begin_layout Standard
11029 See the \SpecialChar LyX
11030  template file 
11031 \family typewriter
11032 elsarticle.lyx
11033 \family default
11034 .
11035  It contains all infos you need.
11036 \end_layout
11037
11038 \begin_layout Section
11039 Foils [aka 
11040 \family sans
11041 Foil\SpecialChar TeX
11042
11043 \family default
11044 ]
11045 \begin_inset CommandInset label
11046 LatexCommand label
11047 name "sec:foiltex"
11048
11049 \end_inset
11050
11051
11052 \end_layout
11053
11054 \begin_layout Standard
11055 by 
11056 \noun on
11057 Allan Rae
11058 \end_layout
11059
11060 \begin_layout Subsection
11061 Introduction
11062 \end_layout
11063
11064 \begin_layout Standard
11065 This section describes how to use \SpecialChar LyX
11066  to make slides for overhead projectors.
11067  There are two document classes that can do this: the default slides class
11068  and the 
11069 \family sans
11070 Foil\SpecialChar TeX
11071
11072 \family default
11073  slides class.
11074  This section documents the latter.
11075 \end_layout
11076
11077 \begin_layout Standard
11078 I'm going to say this again, nice and clear, so that there's no misunderstanding
11079 :
11080 \end_layout
11081
11082 \begin_layout Standard
11083 \begin_inset VSpace bigskip
11084 \end_inset
11085
11086
11087 \end_layout
11088
11089 \begin_layout Standard
11090 \align center
11091
11092 \size large
11093 This section documents the class 
11094 \begin_inset Quotes eld
11095 \end_inset
11096
11097
11098 \family sans
11099 FoilTeX
11100 \family default
11101
11102 \begin_inset Quotes erd
11103 \end_inset
11104
11105  
11106 \emph on
11107 only.
11108 \end_layout
11109
11110 \begin_layout Standard
11111 \begin_inset VSpace bigskip
11112 \end_inset
11113
11114
11115 \end_layout
11116
11117 \begin_layout Standard
11118 If you're looking for the documentation for 
11119 \begin_inset Quotes eld
11120 \end_inset
11121
11122
11123 \family sans
11124 slides (default)
11125 \family default
11126
11127 \begin_inset Quotes erd
11128 \end_inset
11129
11130 , check out section
11131 \begin_inset space ~
11132 \end_inset
11133
11134
11135 \begin_inset CommandInset ref
11136 LatexCommand ref
11137 reference "sec:slitex"
11138
11139 \end_inset
11140
11141 .
11142  If your machine doesn't have the 
11143 \family sans
11144 foils
11145 \family default
11146  class 
11147 \family sans
11148 FoilTeX
11149 \family default
11150  installed, you'll probably have to use the default 
11151 \family sans
11152 slides
11153 \family default
11154  class, which isn't quite as good as 
11155 \family sans
11156 foils.
11157 \end_layout
11158
11159 \begin_layout Standard
11160 The 
11161 \family sans
11162 foils
11163 \family default
11164  class is designed for use with version
11165 \begin_inset space ~
11166 \end_inset
11167
11168 2.1 of the 
11169 \family sans
11170 foils.cls
11171 \family default
11172  \SpecialChar LaTeX
11173  class file which is now an integral part of \SpecialChar LaTeX2e
11174 .
11175 \end_layout
11176
11177 \begin_layout Subsection
11178 Getting Started
11179 \end_layout
11180
11181 \begin_layout Standard
11182 Obviously, to use this document class, you need to select 
11183 \family sans
11184 FoilTeX
11185 \family default
11186  from the 
11187 \family sans
11188 Class
11189 \family default
11190  entry in the 
11191 \family sans
11192 Document
11193 \begin_inset space ~
11194 \end_inset
11195
11196 Layout
11197 \family default
11198  dialog.
11199  There are some settings in the 
11200 \family sans
11201 Document
11202 \begin_inset space ~
11203 \end_inset
11204
11205 Layout
11206 \family default
11207  dialog that you should know about that are specific to this class:
11208 \end_layout
11209
11210 \begin_layout Itemize
11211 Don't change the options 
11212 \family sans
11213 Sides
11214 \family default
11215  and 
11216 \family sans
11217 Columns
11218 \family default
11219  on the 
11220 \family sans
11221 Document
11222 \begin_inset space ~
11223 \end_inset
11224
11225 Layout
11226 \family default
11227  dialog.
11228  They're ignored by the 
11229 \family sans
11230 foils
11231 \family default
11232  class.
11233 \end_layout
11234
11235 \begin_layout Itemize
11236 The default font size is 20
11237 \begin_inset space \thinspace{}
11238 \end_inset
11239
11240 pt with the other options being 17
11241 \begin_inset space \thinspace{}
11242 \end_inset
11243
11244 pt, 25
11245 \begin_inset space \thinspace{}
11246 \end_inset
11247
11248 pt and 30
11249 \begin_inset space \thinspace{}
11250 \end_inset
11251
11252 pt.
11253 \end_layout
11254
11255 \begin_layout Itemize
11256 The default font is 
11257 \family sans
11258 sans
11259 \family default
11260  
11261 \family sans
11262 serif
11263 \family default
11264  but all math equations are still typeset in the usual roman font.
11265 \end_layout
11266
11267 \begin_layout Itemize
11268
11269 \family sans
11270 Foil\SpecialChar TeX
11271
11272 \family default
11273  supports A4 and Letter paper sizes as well as a special size for working
11274  with 35
11275 \begin_inset space \thinspace{}
11276 \end_inset
11277
11278 mm slides.
11279  It doesn't support A5, B5, legal or executive paper sizes.
11280 \end_layout
11281
11282 \begin_layout Itemize
11283 Don't bother changing the 
11284 \family sans
11285 Float Placement
11286 \family default
11287  settings because they are ignored anyway.
11288  All floats appear where they are defined in the text.
11289 \end_layout
11290
11291 \begin_layout Itemize
11292 The 
11293 \family sans
11294 Pagestyle
11295 \family default
11296  setting behaves a bit differently for this class.
11297  
11298 \family sans
11299 Foil\SpecialChar TeX
11300
11301 \family default
11302  provides extensive footer and header capabilities including a user-defined
11303  logo.
11304  See section
11305 \begin_inset space ~
11306 \end_inset
11307
11308
11309 \begin_inset CommandInset ref
11310 LatexCommand ref
11311 reference "sec:foilfoot"
11312
11313 \end_inset
11314
11315  for more details.
11316  The title page is treated differently to all other pages in the document
11317  and is 
11318 \emph on
11319 always
11320 \emph default
11321  unnumbered and 
11322 \emph on
11323 always
11324 \emph default
11325  has the logo centered at the bottom of the page (if one is defined).
11326  The possible page style choices and what they do are as follows:
11327 \end_layout
11328
11329 \begin_deeper
11330 \begin_layout Labeling
11331 \labelwidthstring MMMMMMM
11332
11333 \family sans
11334 \series bold
11335 empty
11336 \family default
11337 \series default
11338  The final output contains no page numbers, or other headers or footers
11339  (except footnotes of course).
11340  
11341 \end_layout
11342
11343 \begin_layout Labeling
11344 \labelwidthstring MMMMMMM
11345
11346 \family sans
11347 \series bold
11348 plain
11349 \family default
11350 \series default
11351  The final output contains page numbers centered at the bottom of the page.
11352  No other headings or footers (other than footnotes).
11353 \end_layout
11354
11355 \begin_layout Labeling
11356 \labelwidthstring MMMMMMM
11357
11358 \series bold
11359 foilheadings
11360 \series default
11361  Page numbers in lower right corner.
11362  Additional headers and footers are also shown.
11363  This is also the default.
11364 \end_layout
11365
11366 \begin_layout Labeling
11367 \labelwidthstring MMMMMMM
11368
11369 \series bold
11370 fancy
11371 \series default
11372  Gives you access to the 
11373 \family sans
11374 fancyheadings
11375 \family default
11376  package although its use with 
11377 \family sans
11378 Foil\SpecialChar TeX
11379
11380 \family default
11381  is discouraged by the writer of the 
11382 \family sans
11383 Foil\SpecialChar TeX
11384
11385 \family default
11386  package because of some potential page layout clashes.
11387 \end_layout
11388
11389 \end_deeper
11390 \begin_layout Subsubsection
11391 Extra Options
11392 \end_layout
11393
11394 \begin_layout Standard
11395 The following options may be used in the extra class options in the 
11396 \family sans
11397 Document\SpecialChar menuseparator
11398 Settings
11399 \family default
11400  dialog.
11401 \end_layout
11402
11403 \begin_layout Labeling
11404 \labelwidthstring MMMMMMx
11405
11406 \series bold
11407 35mmSlide
11408 \series default
11409  This sets up the page layout for 7.33
11410 \begin_inset space \thinspace{}
11411 \end_inset
11412
11413 in by 11
11414 \begin_inset space \thinspace{}
11415 \end_inset
11416
11417 in paper, which is about the same aspect ratio as a 35
11418 \begin_inset space \thinspace{}
11419 \end_inset
11420
11421 mm slide, making it a bit easier to work with this medium.
11422 \end_layout
11423
11424 \begin_layout Labeling
11425 \labelwidthstring MMMMMMx
11426
11427 \series bold
11428 headrule
11429 \series default
11430  Places a rule across the page below the header on every page except the
11431  title page.
11432 \end_layout
11433
11434 \begin_layout Labeling
11435 \labelwidthstring MMMMMMx
11436
11437 \series bold
11438 footrule
11439 \series default
11440  Places a rule across the page above the footer on every page except the
11441  title page.
11442 \end_layout
11443
11444 \begin_layout Labeling
11445 \labelwidthstring MMMMMMx
11446
11447 \series bold
11448 dvips
11449 \series default
11450  This is automatically set each time you create a new 
11451 \family sans
11452 foils
11453 \family default
11454  document.
11455  This option tells 
11456 \family sans
11457 Foil\SpecialChar TeX
11458
11459 \family default
11460  to use the dvips driver to rotate those pages that are set as landscape
11461  foils.
11462 \end_layout
11463
11464 \begin_layout Labeling
11465 \labelwidthstring MMMMMMx
11466
11467 \series bold
11468 landscape
11469 \series default
11470  Simply changes the page dimensions to those of a landscape page but doesn't
11471  do any rotation.
11472  Thus if you use this option you need to use an external program to rotate
11473  each page or feed your paper through your printer as landscape.
11474  Note that this option effectively reverses the roles of the 
11475 \family sans
11476 Foilhead
11477 \family default
11478  and 
11479 \family sans
11480 Rotatefoilhead
11481 \family default
11482  environments (don't worry these are described in the next section).
11483 \end_layout
11484
11485 \begin_layout Labeling
11486 \labelwidthstring MMMMMMx
11487
11488 \series bold
11489 leqno
11490 \series default
11491  Equation numbers on the left.
11492 \end_layout
11493
11494 \begin_layout Labeling
11495 \labelwidthstring MMMMMMx
11496
11497 \series bold
11498 fleqn
11499 \series default
11500  Flush-left equations.
11501 \end_layout
11502
11503 \begin_layout Subsection
11504 Supported Environments
11505 \end_layout
11506
11507 \begin_layout Standard
11508 Most of the environments commonly supported in other classes are also supported
11509  by the 
11510 \family sans
11511 foils
11512 \family default
11513  class.
11514  There are several additional environments provided by 
11515 \family sans
11516 Foil\SpecialChar TeX
11517
11518 \family default
11519  as well as a couple added by \SpecialChar LyX
11520 .
11521  The following environments are shared with other classes:
11522 \end_layout
11523
11524 \begin_layout Standard
11525 \begin_inset Flex Multiple Columns
11526 status open
11527
11528 \begin_layout Itemize
11529
11530 \family sans
11531 Standard
11532 \end_layout
11533
11534 \begin_layout Itemize
11535
11536 \family sans
11537 Itemize
11538 \end_layout
11539
11540 \begin_layout Itemize
11541
11542 \family sans
11543 Enumerate
11544 \end_layout
11545
11546 \begin_layout Itemize
11547
11548 \family sans
11549 Description
11550 \end_layout
11551
11552 \begin_layout Itemize
11553
11554 \family sans
11555 List
11556 \end_layout
11557
11558 \begin_layout Itemize
11559
11560 \family sans
11561 \SpecialChar LyX
11562 -Code
11563 \end_layout
11564
11565 \begin_layout Itemize
11566
11567 \family sans
11568 Verse
11569 \end_layout
11570
11571 \begin_layout Itemize
11572
11573 \family sans
11574 Quote
11575 \end_layout
11576
11577 \begin_layout Itemize
11578
11579 \family sans
11580 Quotation
11581 \end_layout
11582
11583 \begin_layout Itemize
11584
11585 \family sans
11586 Title
11587 \end_layout
11588
11589 \begin_layout Itemize
11590
11591 \family sans
11592 Author
11593 \end_layout
11594
11595 \begin_layout Itemize
11596
11597 \family sans
11598 Date
11599 \end_layout
11600
11601 \begin_layout Itemize
11602
11603 \family sans
11604 Abstract
11605 \end_layout
11606
11607 \begin_layout Itemize
11608
11609 \family sans
11610 Bibliography
11611 \end_layout
11612
11613 \begin_layout Itemize
11614
11615 \family sans
11616 Address
11617 \end_layout
11618
11619 \begin_layout Itemize
11620
11621 \family sans
11622 RightAddress
11623 \end_layout
11624
11625 \begin_layout Itemize
11626
11627 \family sans
11628 Caption
11629 \end_layout
11630
11631 \begin_layout Itemize
11632
11633 \family sans
11634 Comment
11635 \end_layout
11636
11637 \end_inset
11638
11639
11640 \end_layout
11641
11642 \begin_layout Standard
11643 That is, all the major environments apart from the sectioning environments.
11644  Since foils are essentially self-contained sections, with a title and body,
11645  
11646 \family sans
11647 Foil\SpecialChar TeX
11648
11649 \family default
11650  provides specific commands for starting new foils and these are:
11651 \end_layout
11652
11653 \begin_layout Itemize
11654
11655 \family sans
11656 Foilhead
11657 \end_layout
11658
11659 \begin_layout Itemize
11660
11661 \family sans
11662 Rotatefoilhead
11663 \end_layout
11664
11665 \begin_layout Standard
11666 \SpecialChar LyX
11667  also provides slightly modified versions of these two environments called:
11668 \end_layout
11669
11670 \begin_layout Itemize
11671
11672 \family sans
11673 ShortFoilhead
11674 \end_layout
11675
11676 \begin_layout Itemize
11677
11678 \family sans
11679 ShortRotatefoilhead
11680 \end_layout
11681
11682 \begin_layout Standard
11683 and the differences will be explained in the next section.
11684 \end_layout
11685
11686 \begin_layout Standard
11687 Since foils are often used in presenting ideas or new theorems and such
11688  
11689 \family sans
11690 Foil\SpecialChar TeX
11691
11692 \family default
11693  also provides a comprehensive box of goodies for presenting them:
11694 \end_layout
11695
11696 \begin_layout Standard
11697 \begin_inset Flex Multiple Columns
11698 status open
11699
11700 \begin_layout Itemize
11701
11702 \family sans
11703 Theorem
11704 \end_layout
11705
11706 \begin_layout Itemize
11707
11708 \family sans
11709 Lemma
11710 \end_layout
11711
11712 \begin_layout Itemize
11713
11714 \family sans
11715 Corollary
11716 \end_layout
11717
11718 \begin_layout Itemize
11719
11720 \family sans
11721 Proposition
11722 \end_layout
11723
11724 \begin_layout Itemize
11725
11726 \family sans
11727 Definition
11728 \end_layout
11729
11730 \begin_layout Itemize
11731
11732 \family sans
11733 Proof
11734 \end_layout
11735
11736 \begin_layout Itemize
11737
11738 \family sans
11739 Theorem*
11740 \end_layout
11741
11742 \begin_layout Itemize
11743
11744 \family sans
11745 Lemma*
11746 \end_layout
11747
11748 \begin_layout Itemize
11749
11750 \family sans
11751 Corollary*
11752 \end_layout
11753
11754 \begin_layout Itemize
11755
11756 \family sans
11757 Proposition*
11758 \end_layout
11759
11760 \begin_layout Itemize
11761
11762 \family sans
11763 Definition*
11764 \end_layout
11765
11766 \end_inset
11767
11768
11769 \end_layout
11770
11771 \begin_layout Standard
11772 The starred versions are unnumbered while the unstarred versions are numbered.
11773  There are also two list environments added by \SpecialChar LyX
11774  and these are:
11775 \end_layout
11776
11777 \begin_layout Itemize
11778
11779 \family sans
11780 TickList
11781 \end_layout
11782
11783 \begin_layout Itemize
11784
11785 \family sans
11786 CrossList
11787 \end_layout
11788
11789 \begin_layout Standard
11790
11791 \family sans
11792 Foil\SpecialChar TeX
11793
11794 \family default
11795  provides some powerful header and footer capabilities that are best set
11796  in the preamble although they may be set at any point in a document.
11797  If you want to change these settings in your document the best place to
11798  do so is at the very top of a foil, i.
11799 \begin_inset space \thinspace{}
11800 \end_inset
11801
11802 e.
11803 \emph on
11804
11805 \begin_inset space \space{}
11806 \end_inset
11807
11808
11809 \emph default
11810 straight after the foilhead.
11811 \end_layout
11812
11813 \begin_layout Standard
11814 For this purpose, the following command styles are provided [
11815 \shape smallcaps
11816 Martin Vermeer
11817 \shape default
11818 ]:
11819 \end_layout
11820
11821 \begin_layout Standard
11822 \begin_inset Flex Multiple Columns
11823 status open
11824
11825 \begin_layout Itemize
11826
11827 \family sans
11828 My
11829 \begin_inset space ~
11830 \end_inset
11831
11832 Logo
11833 \end_layout
11834
11835 \begin_layout Itemize
11836
11837 \family sans
11838 Restriction
11839 \end_layout
11840
11841 \begin_layout Itemize
11842
11843 \family sans
11844 Right
11845 \begin_inset space ~
11846 \end_inset
11847
11848 Footer
11849 \end_layout
11850
11851 \begin_layout Itemize
11852
11853 \family sans
11854 Right
11855 \begin_inset space ~
11856 \end_inset
11857
11858 Header
11859 \end_layout
11860
11861 \begin_layout Itemize
11862
11863 \family sans
11864 Left
11865 \begin_inset space ~
11866 \end_inset
11867
11868 Header
11869 \end_layout
11870
11871 \begin_deeper
11872 \begin_layout Plain Layout
11873 \begin_inset space ~
11874 \end_inset
11875
11876
11877 \end_layout
11878
11879 \end_deeper
11880 \end_inset
11881
11882
11883 \end_layout
11884
11885 \begin_layout Standard
11886 There are also a few commands provided by 
11887 \family sans
11888 Foil\SpecialChar TeX
11889
11890 \family default
11891  that aren't directly supported by \SpecialChar LyX
11892  but I'll tell you what they do and how
11893  to use them in section
11894 \begin_inset space ~
11895 \end_inset
11896
11897
11898 \begin_inset CommandInset ref
11899 LatexCommand ref
11900 reference "sec:unsuppfoils"
11901
11902 \end_inset
11903
11904 .
11905 \end_layout
11906
11907 \begin_layout Subsection
11908 Building a Set of Foils
11909 \end_layout
11910
11911 \begin_layout Standard
11912 This section will give a simple introduction to using the different environments
11913  to build a set of foils.
11914  If you want to see an example set of foils, take a look at the 
11915 \family typewriter
11916 Foils.lyx
11917 \family default
11918  file you find in \SpecialChar LyX
11919 's 
11920 \family typewriter
11921 examples
11922 \family default
11923  folder.
11924 \end_layout
11925
11926 \begin_layout Subsubsection
11927 Give It a Title Page
11928 \end_layout
11929
11930 \begin_layout Standard
11931 Unlike other classes that provide 
11932 \family sans
11933 Title
11934 \family default
11935
11936 \family sans
11937 Author
11938 \family default
11939
11940 \family sans
11941 Date
11942 \family default
11943  and 
11944 \family sans
11945 Abstract
11946 \family default
11947  environments, 
11948 \family sans
11949 foils
11950 \family default
11951  creates the title on a page of its own.
11952  If you leave out the 
11953 \family sans
11954 Date
11955 \family default
11956  environment \SpecialChar LaTeX
11957  will substitute the current date (every time you regenerate
11958  the output).
11959 \end_layout
11960
11961 \begin_layout Subsubsection
11962 Start a New Foil
11963 \end_layout
11964
11965 \begin_layout Standard
11966 As I mentioned earlier, there are four ways of starting a new foil.
11967  For portrait foils you should use 
11968 \family sans
11969 Foilhead
11970 \family default
11971  or 
11972 \family sans
11973 ShortFoilhead.
11974
11975 \family default
11976  The difference between these two environments is the amount of space between
11977  the title of the foil (the foilhead) and the body of the foil.
11978 \end_layout
11979
11980 \begin_layout Standard
11981 Landscape foils are generated using the 
11982 \family sans
11983 Rotatefoilhead
11984 \family default
11985  and 
11986 \family sans
11987 ShortRotatefoilhead
11988 \family default
11989  environments.
11990  Again the only difference is the spacing between foilhead and body.
11991  Both of the short versions have 0.5
11992 \begin_inset space ~
11993 \end_inset
11994
11995 inches less separation between the foilhead and the body.
11996  
11997 \end_layout
11998
11999 \begin_layout Standard
12000 One problem with the support for landscape foils is the requirement that
12001  you have to use the 
12002 \family typewriter
12003 dvips
12004 \family default
12005  driver to generate the PostScript output otherwise the foils won't be rotated.
12006  It is possible to get landscape foils even if you haven't got the 
12007 \family typewriter
12008 dvips
12009 \family default
12010  driver provided you can feed your foils sideways through your printer ;-)
12011 \end_layout
12012
12013 \begin_layout Subsubsection
12014 Theorems, Lemmas, Proofs and more
12015 \end_layout
12016
12017 \begin_layout Standard
12018 Due to a small bug in \SpecialChar LyX
12019  you can't have two of the same type of these environments
12020  directly following each other.
12021  They must be separated by something.
12022  If you try, you will just be extending the previous environment as if you
12023  had merged the two environments together.
12024  So, how do you get around this problem? The simplest option is to insert
12025  some text between the two environments or add a 
12026 \family sans
12027 \SpecialChar LaTeX
12028
12029 \family default
12030  environment between the two with just a 
12031 \begin_inset Quotes eld
12032 \end_inset
12033
12034
12035 \family typewriter
12036 %
12037 \family default
12038
12039 \begin_inset Quotes erd
12040 \end_inset
12041
12042  in it.
12043  This will force \SpecialChar LyX
12044  to produce two separate environments and hence the correct
12045  \SpecialChar LaTeX
12046  output.
12047  An example is provided in the example file included with the \SpecialChar LyX
12048  distribution.
12049  Remember, this problem only occurs if you are trying to place two of the
12050  same type of theorem-like environments one directly after the other.
12051 \end_layout
12052
12053 \begin_layout Subsubsection
12054 Lists
12055 \end_layout
12056
12057 \begin_layout Standard
12058 You get all the commonly supported list styles found in other classes as
12059  well as two new ones.
12060  I'll only describe the new ones here.
12061  If you want to find out more about the other list environments check out
12062  the 
12063 \emph on
12064 User's Guide.
12065
12066 \emph default
12067  If you intend to use itemized lists you might also want to read about the
12068  
12069 \family sans
12070 Itemize
12071 \begin_inset space ~
12072 \end_inset
12073
12074 Bullet
12075 \begin_inset space ~
12076 \end_inset
12077
12078 Selection
12079 \family default
12080  dialog described above in section
12081 \begin_inset space ~
12082 \end_inset
12083
12084
12085 \begin_inset CommandInset ref
12086 LatexCommand ref
12087 reference "sec:bullet"
12088
12089 \end_inset
12090
12091 .
12092 \end_layout
12093
12094 \begin_layout Standard
12095 The two new list styles, 
12096 \family sans
12097 TickList
12098 \family default
12099  and 
12100 \family sans
12101 CrossList
12102 \family default
12103 , are designed to make it easier for you to create lists of do's and don'ts
12104  or right and wrong by providing dedicated environments that use a tick
12105  or a cross as the label of the list.
12106  These lists are in fact dedicated variants of the 
12107 \family sans
12108 Itemize
12109 \family default
12110  environment.
12111  They do however require that you have the 
12112 \family typewriter
12113 psnfss
12114 \family default
12115  packages installed.
12116 \end_layout
12117
12118 \begin_layout Subsubsection
12119 Figures and Tables
12120 \end_layout
12121
12122 \begin_layout Standard
12123
12124 \family sans
12125 Foil\SpecialChar TeX
12126
12127 \family default
12128  redefines the floating tables and figures so that they appear exactly where
12129  they are in the text rather than pushing them to the top of the page or
12130  to some user specified location.
12131  In fact if you change the float placement settings they are simply ignored.
12132 \end_layout
12133
12134 \begin_layout Subsubsection
12135 Page Headers and Footers
12136 \begin_inset CommandInset label
12137 LatexCommand label
12138 name "sec:foilfoot"
12139
12140 \end_inset
12141
12142
12143 \end_layout
12144
12145 \begin_layout Standard
12146
12147 \family sans
12148 My
12149 \begin_inset space ~
12150 \end_inset
12151
12152 Logo
12153 \family default
12154  and 
12155 \family sans
12156 Restriction
12157 \family default
12158  are two commands used to control the left-footer text string.
12159  The first is meant to allow you to include a graphic logo on your foils
12160  and defaults to 
12161 \begin_inset Quotes eld
12162 \end_inset
12163
12164 -Typeset by 
12165 \family sans
12166 Foil\SpecialChar TeX
12167
12168 \family default
12169 -
12170 \begin_inset Quotes erd
12171 \end_inset
12172
12173 .
12174  While the second is meant to provide a classification for the audience,
12175  
12176 \emph on
12177 e.
12178 \begin_inset space \thinspace{}
12179 \end_inset
12180
12181 g.
12182 \emph default
12183
12184 \begin_inset space \space{}
12185 \end_inset
12186
12187 Confidential.
12188  It is empty by default.
12189 \end_layout
12190
12191 \begin_layout Standard
12192 The remaining page corners can be filled by 
12193 \family sans
12194 Right
12195 \begin_inset space ~
12196 \end_inset
12197
12198 Footer
12199 \family default
12200  (which defaults to page numbers), 
12201 \family sans
12202 Right
12203 \begin_inset space ~
12204 \end_inset
12205
12206 Header
12207 \family default
12208  (top right) and 
12209 \family sans
12210 Left
12211 \begin_inset space ~
12212 \end_inset
12213
12214 Header
12215 \family default
12216  (top left).
12217 \end_layout
12218
12219 \begin_layout Subsection
12220 Unsupported 
12221 \family sans
12222 Foil\SpecialChar TeX
12223
12224 \family default
12225  Goodies
12226 \begin_inset CommandInset label
12227 LatexCommand label
12228 name "sec:unsuppfoils"
12229
12230 \end_inset
12231
12232
12233 \end_layout
12234
12235 \begin_layout Standard
12236 All the commands mentioned below need to be set in a 
12237 \family sans
12238 \SpecialChar LaTeX
12239
12240 \family default
12241  environment or as 
12242 \family sans
12243 \SpecialChar TeX
12244
12245 \family default
12246  within another environment.
12247 \end_layout
12248
12249 \begin_layout Subsubsection
12250 Lengths
12251 \end_layout
12252
12253 \begin_layout Standard
12254 All lengths are adjusted using the 
12255 \family typewriter
12256
12257 \backslash
12258 setlength{
12259 \family default
12260 \emph on
12261 lengthname
12262 \family typewriter
12263 \emph default
12264 }{
12265 \family default
12266 \emph on
12267 newlength
12268 \family typewriter
12269 \emph default
12270 }
12271 \family default
12272  command.
12273  Where 
12274 \emph on
12275 lengthname
12276 \emph default
12277  should be replaced by the name given to the length you want to change and
12278  
12279 \emph on
12280 newlength
12281 \emph default
12282  is the length value.
12283  All lengths should be specified in units of length such as inches (
12284 \family typewriter
12285 in
12286 \family default
12287 ), millimeters (
12288 \family typewriter
12289 mm
12290 \family default
12291 ) or points (
12292 \family typewriter
12293 pt
12294 \family default
12295 ) or relative to some document or font-based length such as 
12296 \family typewriter
12297
12298 \backslash
12299 textwidth
12300 \family default
12301 .
12302  
12303 \end_layout
12304
12305 \begin_layout Standard
12306 It's possible to change the spacing between a foilhead and the body of the
12307  foil by adjusting the length specified by 
12308 \family typewriter
12309
12310 \backslash
12311 foilheadskip
12312 \family default
12313 .
12314  For example, to make 
12315 \emph on
12316 all
12317 \emph default
12318  foilheads 0.5
12319 \begin_inset space \space{}
12320 \end_inset
12321
12322 in closer to their bodies put the following in the preamble: 
12323 \family typewriter
12324
12325 \backslash
12326 setlength{
12327 \backslash
12328 foilheadskip}{-0.5in}
12329 \end_layout
12330
12331 \begin_layout Standard
12332 The spacings around floats can be adjusted by setting these lengths:
12333 \end_layout
12334
12335 \begin_layout Labeling
12336 \labelwidthstring MMMMMMMMMMM
12337
12338 \family typewriter
12339
12340 \backslash
12341 abovefloatskip
12342 \family default
12343  Separation between the text and the top of the float
12344 \end_layout
12345
12346 \begin_layout Labeling
12347 \labelwidthstring MMMMMMMMMMM
12348
12349 \family typewriter
12350
12351 \backslash
12352 abovecaptionskip
12353 \family default
12354  Separation between the float and the caption
12355 \end_layout
12356
12357 \begin_layout Labeling
12358 \labelwidthstring MMMMMMMMMMM
12359
12360 \family typewriter
12361
12362 \backslash
12363 belowcaptionskip
12364 \family default
12365  Separation between the caption and the following text
12366 \end_layout
12367
12368 \begin_layout Labeling
12369 \labelwidthstring MMMMMMMMMMM
12370
12371 \family typewriter
12372
12373 \backslash
12374 captionwidth
12375 \family default
12376  You can make the captions narrower than the surrounding text by adjusting
12377  this length.
12378  Best done relative to 
12379 \family typewriter
12380
12381 \backslash
12382 textwidth
12383 \family default
12384 .
12385 \end_layout
12386
12387 \begin_layout Standard
12388 There are also several title page related lengths that you may find useful
12389  if you have a long title or several authors:
12390 \end_layout
12391
12392 \begin_layout Labeling
12393 \labelwidthstring MMMMMMMMMMM
12394
12395 \family typewriter
12396
12397 \backslash
12398 abovetitleskip
12399 \family default
12400  Separation from headers to 
12401 \family sans
12402 Title
12403 \end_layout
12404
12405 \begin_layout Labeling
12406 \labelwidthstring MMMMMMMMMMM
12407
12408 \family typewriter
12409
12410 \backslash
12411 titleauthorskip
12412 \family default
12413  between 
12414 \family sans
12415 Title
12416 \family default
12417  and 
12418 \family sans
12419 Author
12420 \family default
12421  environments
12422 \end_layout
12423
12424 \begin_layout Labeling
12425 \labelwidthstring MMMMMMMMMMM
12426
12427 \family typewriter
12428
12429 \backslash
12430 authorauthorskip
12431 \family default
12432  between multiple 
12433 \family sans
12434 Author
12435 \family default
12436  lines
12437 \end_layout
12438
12439 \begin_layout Labeling
12440 \labelwidthstring MMMMMMMMMMM
12441
12442 \family typewriter
12443
12444 \backslash
12445 authordateskip
12446 \family default
12447  between the 
12448 \family sans
12449 Author
12450 \family default
12451  and the 
12452 \family sans
12453 Date
12454 \end_layout
12455
12456 \begin_layout Labeling
12457 \labelwidthstring MMMMMMMMMMM
12458
12459 \family typewriter
12460
12461 \backslash
12462 dateabstractskip
12463 \family default
12464  between the 
12465 \family sans
12466 Date
12467 \family default
12468  and the 
12469 \family sans
12470 Abstract
12471 \end_layout
12472
12473 \begin_layout Standard
12474 The last length related command affects all the list environments.
12475  If you place 
12476 \family typewriter
12477
12478 \backslash
12479 zerolistvertdimens
12480 \family default
12481  
12482 \emph on
12483 inside
12484 \emph default
12485  a list environment then all the vertical spacing between the list items
12486  is removed.
12487  Note that this is a command not a length so it doesn't require 
12488 \family typewriter
12489
12490 \backslash
12491 setlength
12492 \family default
12493  like the stuff mentioned above.
12494 \end_layout
12495
12496 \begin_layout Subsubsection
12497 Headers and Footers
12498 \end_layout
12499
12500 \begin_layout Standard
12501 The 
12502 \family typewriter
12503
12504 \backslash
12505 LogoOn
12506 \family default
12507  and 
12508 \family typewriter
12509
12510 \backslash
12511 LogoOff
12512 \family default
12513  commands control whether the logo in the 
12514 \family sans
12515 MyLogo
12516 \family default
12517  definition appear on a given page.
12518  If you put 
12519 \family typewriter
12520
12521 \backslash
12522 LogoOff
12523 \family default
12524  in the preamble then none of the foils will have the logo on them.
12525  If you don't want the logo on a particular page place the 
12526 \family typewriter
12527
12528 \backslash
12529 LogoOff
12530 \family default
12531  directly after the foilhead of that page and the 
12532 \family typewriter
12533
12534 \backslash
12535 LogoOn
12536 \family default
12537  directly after the next foilhead.
12538 \end_layout
12539
12540 \begin_layout Standard
12541 If you decide to use the 
12542 \family sans
12543 fancy
12544 \family default
12545  page style setting in the 
12546 \family sans
12547 Document
12548 \begin_inset space ~
12549 \end_inset
12550
12551 Layout
12552 \family default
12553  dialog you should probably add 
12554 \family typewriter
12555
12556 \backslash
12557 let
12558 \backslash
12559 headwidth
12560 \backslash
12561 textwidth
12562 \family default
12563  to your preamble so headers and footers on landscape pages are correctly
12564  placed when rotated.
12565  This is due to some clashes between the page layouts provided by the 
12566 \family sans
12567 fancyheadings
12568 \family default
12569  package and the 
12570 \family sans
12571 foils
12572 \family default
12573  class.
12574 \end_layout
12575
12576 \begin_layout Section
12577 Hollywood (Hollywood spec scripts)
12578 \end_layout
12579
12580 \begin_layout Standard
12581 by 
12582 \shape smallcaps
12583 Garst Reese
12584 \end_layout
12585
12586 \begin_layout Subsection
12587 Introduction
12588 \end_layout
12589
12590 \begin_layout Standard
12591 Getting the format of a Hollywood script right is a 
12592 \begin_inset Quotes eld
12593 \end_inset
12594
12595 rite of passage.
12596 \begin_inset Quotes erd
12597 \end_inset
12598
12599  It is designed to make the readers focus on content and to be easy and
12600  familiar for the actors to read.
12601  Each page of a script should be one minute of film.
12602  Nothing goes in a script that you cannot see or hear on screen.
12603  The courier 12 pt font should be used throughout.
12604  No italics.
12605 \end_layout
12606
12607 \begin_layout Subsection
12608 Special problems
12609 \end_layout
12610
12611 \begin_layout Standard
12612 Speakers' lines should NEVER break in mid-sentence.
12613  If a speaker's lines continue over a page break, repeat the 
12614 \family sans
12615 Speaker
12616 \family default
12617  title followed by (Cont'd).
12618 \end_layout
12619
12620 \begin_layout Subsection
12621 Special features
12622 \end_layout
12623
12624 \begin_layout Standard
12625 Insert the 
12626 \family sans
12627 Speaker
12628 \family default
12629  names as labels then cross-reference the label to insert the name.
12630  The cross-reference dialog will show the current cast of characters.
12631  You can use this to insert the speaker name in narratives also.
12632 \end_layout
12633
12634 \begin_layout Subsection
12635 Paper size and Margins
12636 \end_layout
12637
12638 \begin_layout Standard
12639 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
12640 \end_layout
12641
12642 \begin_layout Subsection
12643 Environments
12644 \end_layout
12645
12646 \begin_layout Standard
12647 The following environments are available.
12648  You can use hollywood.bind to get the bind keys shown at the right.
12649 \end_layout
12650
12651 \begin_layout Itemize
12652
12653 \family sans
12654 Standard
12655 \begin_inset Newline newline
12656 \end_inset
12657
12658
12659 \family default
12660 Used where nothing else works.
12661  Try to avoid it.
12662 \end_layout
12663
12664 \begin_layout Itemize
12665
12666 \family sans
12667 FADE_IN
12668 \family default
12669 :
12670 \begin_inset space \hfill{}
12671 \end_inset
12672
12673
12674 \family sans
12675 M-z S-I
12676 \family default
12677
12678 \begin_inset Newline newline
12679 \end_inset
12680
12681 Usually followed by something like 
12682 \begin_inset Quotes eld
12683 \end_inset
12684
12685 on Sally waking up.
12686 \begin_inset Quotes erd
12687 \end_inset
12688
12689
12690 \end_layout
12691
12692 \begin_layout Itemize
12693
12694 \family sans
12695 INT:
12696 \begin_inset space \hfill{}
12697 \end_inset
12698
12699 M-z i
12700 \begin_inset Newline newline
12701 \end_inset
12702
12703
12704 \family default
12705 Introduces a new INTERIOR camera set-up.
12706  Always followed by DAY or NIGHT, or something similar to define the lighting
12707  required.
12708  Everthing on this line in CAPS.
12709 \end_layout
12710
12711 \begin_layout Itemize
12712
12713 \family sans
12714 EXT:
12715 \begin_inset space \hfill{}
12716 \end_inset
12717
12718 M-z e
12719 \begin_inset Newline newline
12720 \end_inset
12721
12722
12723 \family default
12724 Introduces a new EXTERIOR camera set-up.
12725  Everthing on this line in CAPS.
12726 \end_layout
12727
12728 \begin_layout Itemize
12729
12730 \family sans
12731 Speaker
12732 \begin_inset space \hfill{}
12733 \end_inset
12734
12735 M-z s
12736 \begin_inset Newline newline
12737 \end_inset
12738
12739
12740 \family default
12741 The character speaking.
12742 \end_layout
12743
12744 \begin_layout Itemize
12745
12746 \family sans
12747 Parenthetical
12748 \begin_inset space \hfill{}
12749 \end_inset
12750
12751 M-z p
12752 \begin_inset Newline newline
12753 \end_inset
12754
12755
12756 \family default
12757 Instructions to the speaker.
12758  The () are automatically inserted, but only the ( will show in \SpecialChar LyX
12759 .
12760  Both will be printed.
12761 \end_layout
12762
12763 \begin_layout Itemize
12764
12765 \family sans
12766 Dialogue
12767 \begin_inset space \hfill{}
12768 \end_inset
12769
12770 M-z d
12771 \begin_inset Newline newline
12772 \end_inset
12773
12774
12775 \family default
12776 What the 
12777 \family sans
12778 Speaker
12779 \family default
12780  says.
12781 \end_layout
12782
12783 \begin_layout Itemize
12784
12785 \family sans
12786 Transition
12787 \begin_inset space \hfill{}
12788 \end_inset
12789
12790 M-z t
12791 \begin_inset Newline newline
12792 \end_inset
12793
12794
12795 \family default
12796 Camera movement instruction.
12797  e.
12798 \begin_inset space \thinspace{}
12799 \end_inset
12800
12801 g.
12802 \begin_inset space \space{}
12803 \end_inset
12804
12805 CUT TO:
12806 \end_layout
12807
12808 \begin_layout Itemize
12809
12810 \family sans
12811 FADE OUT:
12812 \begin_inset space \hfill{}
12813 \end_inset
12814
12815 M-z S-I
12816 \end_layout
12817
12818 \begin_layout Itemize
12819
12820 \family sans
12821 Author
12822 \begin_inset space \hfill{}
12823 \end_inset
12824
12825 M-z S-A
12826 \end_layout
12827
12828 \begin_layout Itemize
12829
12830 \family sans
12831 Title
12832 \begin_inset space \hfill{}
12833 \end_inset
12834
12835 M-z S-T
12836 \end_layout
12837
12838 \begin_layout Itemize
12839
12840 \family sans
12841 Right_Address
12842 \begin_inset space \hfill{}
12843 \end_inset
12844
12845 M-z r
12846 \end_layout
12847
12848 \begin_layout Subsection
12849 Script jargon
12850 \end_layout
12851
12852 \begin_layout Itemize
12853 (O.S) — off screen
12854 \end_layout
12855
12856 \begin_layout Itemize
12857 (V.0) — voice over
12858 \end_layout
12859
12860 \begin_layout Itemize
12861 b.
12862 \begin_inset space \thinspace{}
12863 \end_inset
12864
12865 g.
12866  — background
12867 \end_layout
12868
12869 \begin_layout Itemize
12870 C.U.
12871  — close-up
12872 \end_layout
12873
12874 \begin_layout Itemize
12875 PAN — camera movement
12876 \end_layout
12877
12878 \begin_layout Itemize
12879 INSERT — cut to close-up of
12880 \end_layout
12881
12882 \begin_layout Section
12883 ijmpc and ijmpd
12884 \end_layout
12885
12886 \begin_layout Standard
12887 by 
12888 \noun on
12889 Panayotis Papasotiriou
12890 \end_layout
12891
12892 \begin_layout Subsection
12893 Overview
12894 \end_layout
12895
12896 \begin_layout Standard
12897 The ijmpc package is a set of macros that facilitates electronic manuscript
12898  submission to the 
12899 \emph on
12900 International Journal of Modern Physics C
12901 \emph default
12902 .
12903  Similarly, the ijmpd package is for creating manuscripts to be submitted
12904  to the 
12905 \emph on
12906 International Journal of Modern Physics D
12907 \emph default
12908 .
12909  Both journals are published by World Scientific.
12910  The corresponding document classes are named 
12911 \family typewriter
12912 ws-ijmpc.cls
12913 \family default
12914  and 
12915 \family typewriter
12916 ws-ijmpd.cls
12917 \family default
12918 , respectively.
12919  These files, together with instructions for the authors, can be downloaded
12920  from the sites 
12921 \begin_inset Flex URL
12922 status collapsed
12923
12924 \begin_layout Plain Layout
12925
12926 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
12927 \end_layout
12928
12929 \end_inset
12930
12931  and 
12932 \begin_inset Flex URL
12933 status collapsed
12934
12935 \begin_layout Plain Layout
12936
12937 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
12938 \end_layout
12939
12940 \end_inset
12941
12942 .
12943  Both packages are modified versions of the standard 
12944 \begin_inset Quotes eld
12945 \end_inset
12946
12947 article
12948 \begin_inset Quotes erd
12949 \end_inset
12950
12951  package, and they are almost (but not exactly) identical.
12952  Most of their features are supported by \SpecialChar LyX
12953 .
12954  I have used \SpecialChar LyX
12955  successfully to write articles submitted to both journals
12956  without any problem.
12957 \end_layout
12958
12959 \begin_layout Subsection
12960 Writing a paper
12961 \end_layout
12962
12963 \begin_layout Standard
12964 As usual, the easiest way to write a paper is to start with a template.
12965  Click on 
12966 \family sans
12967 File\SpecialChar menuseparator
12968 New from
12969 \family default
12970  
12971 \family sans
12972 Template
12973 \family default
12974 , then choose the 
12975 \family typewriter
12976 ijmpc.lyx
12977 \family default
12978  or 
12979 \family typewriter
12980 ijmpd.lyx
12981 \family default
12982  template.
12983  This will give an (almost) empty document that includes the most common
12984  fields found in a manuscript.
12985  Simply overwrite the existing text (including the brackets, 
12986 \family typewriter
12987 <>
12988 \family default
12989 ) with your text.
12990  You should keep in mind the following remarks.
12991 \end_layout
12992
12993 \begin_layout Enumerate
12994 \SpecialChar LyX
12995  won't let you change the font size and the page style of the document,
12996  because such modifications are not allowed by both packages.
12997 \end_layout
12998
12999 \begin_layout Enumerate
13000 The language of the document should not be changed.
13001  Before previewing your paper, be sure that the babel package is not used.
13002  To do this, click on
13003 \change_inserted -712698321 1501082726
13004  
13005 \begin_inset Info
13006 type  "menu"
13007 arg   "dialog-show document"
13008 \end_inset
13009
13010
13011 \change_unchanged
13012  
13013 \change_deleted -712698321 1501082743
13014
13015 \family sans
13016 Tools
13017 \change_unchanged
13018 \SpecialChar menuseparator
13019
13020 \change_deleted -712698321 1501082747
13021 Preferences
13022 \change_inserted -712698321 1501082748
13023 Language
13024 \change_unchanged
13025
13026 \family default
13027
13028 \change_deleted -712698321 1501082762
13029 select the 
13030 \family sans
13031 Lang Opts
13032 \family default
13033  tab, deselect the 
13034 \family sans
13035 Use babel
13036 \family default
13037  checkbox in the language settings, and click on 
13038 \family sans
13039 Apply
13040 \family default
13041  (or 
13042 \family sans
13043 Save
13044 \family default
13045 , if you wish to make this change permanent)
13046 \change_inserted -712698321 1501082770
13047 and select 
13048 \begin_inset Quotes eld
13049 \end_inset
13050
13051 None
13052 \begin_inset Quotes erd
13053 \end_inset
13054
13055  as 
13056 \family sans
13057 Language Package
13058 \change_unchanged
13059
13060 \family default
13061 .
13062 \end_layout
13063
13064 \begin_layout Enumerate
13065 The 
13066 \begin_inset Quotes eld
13067 \end_inset
13068
13069 Keywords
13070 \begin_inset Quotes erd
13071 \end_inset
13072
13073  style must be used to define keywords.
13074 \end_layout
13075
13076 \begin_layout Enumerate
13077 The ijmpc package provides a style named 
13078 \begin_inset Quotes eld
13079 \end_inset
13080
13081 Classification Codes
13082 \begin_inset Quotes erd
13083 \end_inset
13084
13085 , which can be used to define classification codes, such as PACS numbers.
13086  Note that this facility is not supported by the ijmpd package.
13087 \end_layout
13088
13089 \begin_layout Enumerate
13090 Several new environments are available: 
13091 \begin_inset Quotes eld
13092 \end_inset
13093
13094 Definition
13095 \begin_inset Quotes erd
13096 \end_inset
13097
13098
13099 \begin_inset Quotes eld
13100 \end_inset
13101
13102 Step
13103 \begin_inset Quotes erd
13104 \end_inset
13105
13106
13107 \begin_inset Quotes eld
13108 \end_inset
13109
13110 Example
13111 \begin_inset Quotes erd
13112 \end_inset
13113
13114
13115 \begin_inset Quotes eld
13116 \end_inset
13117
13118 Remark
13119 \begin_inset Quotes erd
13120 \end_inset
13121
13122
13123 \begin_inset Quotes eld
13124 \end_inset
13125
13126 Notation
13127 \begin_inset Quotes erd
13128 \end_inset
13129
13130
13131 \begin_inset Quotes eld
13132 \end_inset
13133
13134 Theorem
13135 \begin_inset Quotes erd
13136 \end_inset
13137
13138
13139 \begin_inset Quotes eld
13140 \end_inset
13141
13142 Proof
13143 \begin_inset Quotes erd
13144 \end_inset
13145
13146
13147 \begin_inset Quotes eld
13148 \end_inset
13149
13150 Corollary
13151 \begin_inset Quotes erd
13152 \end_inset
13153
13154
13155 \begin_inset Quotes eld
13156 \end_inset
13157
13158 Lemma
13159 \begin_inset Quotes erd
13160 \end_inset
13161
13162
13163 \begin_inset Quotes eld
13164 \end_inset
13165
13166 Proposition
13167 \begin_inset Quotes erd
13168 \end_inset
13169
13170
13171 \begin_inset Quotes eld
13172 \end_inset
13173
13174 Prop
13175 \begin_inset Quotes erd
13176 \end_inset
13177
13178
13179 \begin_inset Quotes eld
13180 \end_inset
13181
13182 Question
13183 \begin_inset Quotes erd
13184 \end_inset
13185
13186
13187 \begin_inset Quotes eld
13188 \end_inset
13189
13190 Claim
13191 \begin_inset Quotes erd
13192 \end_inset
13193
13194 , and 
13195 \begin_inset Quotes eld
13196 \end_inset
13197
13198 Conjecture
13199 \begin_inset Quotes erd
13200 \end_inset
13201
13202 .
13203  Their use is more or less obvious.
13204  \SpecialChar LyX
13205  supports all these environments; it will use the proper label, text style,
13206  and numbering scheme for each of them.
13207 \end_layout
13208
13209 \begin_layout Enumerate
13210 Both packages use basic citations; the natbib package should not be used.
13211  In \SpecialChar LyX
13212 , citation references are shown as usual; in the output, citations are
13213  shown as superscripts.
13214  If you want to use a citation as normal text, you should use the 
13215 \family typewriter
13216 refcite
13217 \family default
13218  command, e.
13219 \begin_inset space \thinspace{}
13220 \end_inset
13221
13222 g.
13223 \begin_inset space \space{}
13224 \end_inset
13225
13226
13227 \begin_inset Quotes eld
13228 \end_inset
13229
13230 See Ref.
13231 \begin_inset space \space{}
13232 \end_inset
13233
13234
13235 \family typewriter
13236
13237 \backslash
13238 refcite{key}
13239 \family default
13240
13241 \begin_inset Quotes erd
13242 \end_inset
13243
13244 .
13245 \end_layout
13246
13247 \begin_layout Enumerate
13248 There is no 
13249 \begin_inset Quotes eld
13250 \end_inset
13251
13252 Acknowledgments
13253 \begin_inset Quotes erd
13254 \end_inset
13255
13256  section in both packages.
13257  To put acknowledgments, just use the 
13258 \begin_inset Quotes eld
13259 \end_inset
13260
13261 Section*
13262 \begin_inset Quotes erd
13263 \end_inset
13264
13265  environment.
13266 \end_layout
13267
13268 \begin_layout Enumerate
13269 Appendices may be added to the paper, 
13270 \emph on
13271 after
13272 \emph default
13273  the Acknowledgments and 
13274 \shape italic
13275 before
13276 \shape default
13277  the References.
13278  \SpecialChar LyX
13279  provides a special environment, called 
13280 \begin_inset Quotes eld
13281 \end_inset
13282
13283 Appendices Section
13284 \begin_inset Quotes erd
13285 \end_inset
13286
13287  which marks the beginning of the appendices.
13288  This environment should be left blank; it just sends a \SpecialChar LaTeX
13289  command, but nothing
13290  is really printed.
13291  In \SpecialChar LyX
13292 , the word 
13293 \begin_inset Quotes eld
13294 \end_inset
13295
13296 Appendix
13297 \begin_inset Quotes erd
13298 \end_inset
13299
13300  is printed with blue letters, as a signal that all sections after that
13301  point are appendices.
13302  To write an appendix, use the 
13303 \begin_inset Quotes eld
13304 \end_inset
13305
13306 Appendix
13307 \begin_inset Quotes erd
13308 \end_inset
13309
13310  environment.
13311  \SpecialChar LyX
13312  will number each appendix with capital letters, as required by both journals.
13313  Note that 
13314 \begin_inset Quotes eld
13315 \end_inset
13316
13317 Appendices Section
13318 \begin_inset Quotes erd
13319 \end_inset
13320
13321  
13322 \emph on
13323 must
13324 \emph default
13325  be present before the first appendix; if not, all appendices will be numbered
13326  as normal sections in the output.
13327 \end_layout
13328
13329 \begin_layout Enumerate
13330 The ijmpc and the ijmpd packages use the 
13331 \family typewriter
13332 tbl
13333 \family default
13334  command to implement table captions.
13335  As a result, a table created by \SpecialChar LyX
13336  is printed correctly, but its caption
13337  is ignored.
13338  However, you can use some \SpecialChar TeX
13339  code to overcome this problem, so that captions
13340  are printed as expected.
13341  To do so, create a float table as usual, remove the caption, and replace
13342  it with the \SpecialChar TeX
13343  code 
13344 \family typewriter
13345
13346 \backslash
13347 tbl{
13348 \emph on
13349 your table caption
13350 \emph default
13351 }{
13352 \family default
13353  (sic); you must also the \SpecialChar TeX
13354  code 
13355 \family typewriter
13356 }
13357 \family default
13358  immediately after the tabular material.
13359  Study the example table included in the template files to see how this
13360  trick is implemented.
13361  Alternatively, If you need table captions, you should implement the whole
13362  table float in a 
13363 \family typewriter
13364 .tex
13365 \family default
13366  file, then include this file to the \SpecialChar LyX
13367  document (
13368 \family sans
13369 Insert\SpecialChar menuseparator
13370 File\SpecialChar menuseparator
13371 Child
13372 \begin_inset space ~
13373 \end_inset
13374
13375 Document
13376 \family default
13377 ).
13378  Details on how to create a table float can be found in the files 
13379 \family typewriter
13380 ws-ijmpc.tex
13381 \family default
13382  and 
13383 \family typewriter
13384 ws-ijmpd.tex
13385 \family default
13386 , included in the corresponding packages.
13387 \end_layout
13388
13389 \begin_layout Subsection
13390 Preparing a paper for submission
13391 \end_layout
13392
13393 \begin_layout Standard
13394 Before you submit your paper you must export the \SpecialChar LyX
13395  document as a \SpecialChar LaTeX
13396  file (
13397 \family sans
13398 File\SpecialChar menuseparator
13399 Export\SpecialChar menuseparator
13400 \SpecialChar LaTeX
13401
13402 \family default
13403 )
13404 \begin_inset Foot
13405 status open
13406
13407 \begin_layout Plain Layout
13408 Actually you have the choice between \SpecialChar LaTeX
13409  (plain) and pdflatex.
13410  If you intend to use pdflatex to prepare the paper, you should use the
13411  pdflatex option so that included graphics are converted to PDF format,
13412  ready for use by pdflatex.
13413 \end_layout
13414
13415 \end_inset
13416
13417 , then make the following changes to the resulting 
13418 \family typewriter
13419 .tex
13420 \family default
13421  file.
13422 \end_layout
13423
13424 \begin_layout Enumerate
13425 Remove the comment lines before the 
13426 \family typewriter
13427
13428 \backslash
13429 documentclass
13430 \family default
13431  command.
13432 \end_layout
13433
13434 \begin_layout Enumerate
13435 Remove everything between (and including) the 
13436 \family typewriter
13437
13438 \backslash
13439 makeatletter
13440 \family default
13441  and 
13442 \family typewriter
13443
13444 \backslash
13445 makeatother
13446 \family default
13447  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13448  preamble.
13449 \end_layout
13450
13451 \begin_layout Standard
13452 The modified 
13453 \family typewriter
13454 .tex
13455 \family default
13456  file should be saved and processed through \SpecialChar LaTeX
13457  as many times as necessary.
13458  You may also want to check the resulting 
13459 \family typewriter
13460 .dvi
13461 \family default
13462  document.
13463 \end_layout
13464
13465 \begin_layout Subsection
13466
13467 \change_deleted -712698321 1501082212
13468 Use of \SpecialChar TeX
13469  code
13470 \end_layout
13471
13472 \begin_layout Standard
13473
13474 \change_deleted -712698321 1501082212
13475 The use of \SpecialChar TeX
13476  code is reduced to two commands, which must be placed at the
13477  top of the document.
13478  If you started writing your paper by using the 
13479 \family typewriter
13480 ijmpc.lyx
13481 \family default
13482  or the 
13483 \family typewriter
13484 ijmpd.lyx
13485 \family default
13486  template, the \SpecialChar TeX
13487  code needed is already in its place; you usually don't need
13488  to delete it.
13489  You may only modify the first \SpecialChar TeX
13490  code to specify the information printed
13491  to the top of odd and even pages (authors' names and short paper's title,
13492  respectively).
13493  This \SpecialChar TeX
13494  code must have the form 
13495 \family typewriter
13496
13497 \backslash
13498 markboth{Authors' Names}{Short Paper's Title}
13499 \family default
13500 .
13501 \change_unchanged
13502
13503 \end_layout
13504
13505 \begin_layout Section
13506 iopart
13507 \end_layout
13508
13509 \begin_layout Standard
13510 by 
13511 \noun on
13512 Uwe Stöhr
13513 \end_layout
13514
13515 \begin_layout Subsection
13516 Overview
13517 \end_layout
13518
13519 \begin_layout Standard
13520 The iopart package provides a document class to create electronic manuscript
13521  submission to the journals published by the Institute of Physics.
13522  Instructions for the authors how to create a paper using the iopart class
13523  can be downloaded together with the iopart package from the site 
13524 \begin_inset Flex URL
13525 status collapsed
13526
13527 \begin_layout Plain Layout
13528
13529 ftp://ftp.iop.org/pub/journals/latex2e
13530 \end_layout
13531
13532 \end_inset
13533
13534 .
13535 \end_layout
13536
13537 \begin_layout Subsection
13538 Writing a paper
13539 \end_layout
13540
13541 \begin_layout Standard
13542 The easiest way to write a paper is to start with the file 
13543 \emph on
13544 IOP-article.lyx
13545 \emph default
13546  that is available in \SpecialChar LyX
13547 's examples files folder.
13548  Open this file, save it under a new name, and start writing.
13549  The example file explains how to use the special text environments.
13550  Here are the most important advices:
13551 \end_layout
13552
13553 \begin_layout Itemize
13554 To be able to compile your document to a PDF, PS, or DVI, ensure that the
13555  two options 
13556 \family sans
13557 Use AMS math package
13558 \family default
13559  in the document settings under 
13560 \family sans
13561 Math Options
13562 \family default
13563  are not used!
13564 \end_layout
13565
13566 \begin_layout Itemize
13567
13568 \size normal
13569 The title environment defines the kind of your paper.
13570  So use one of the following environments for the title:
13571 \end_layout
13572
13573 \begin_deeper
13574 \begin_layout Itemize
13575
13576 \family sans
13577 \size normal
13578 Title
13579 \family default
13580  for a Paper
13581 \end_layout
13582
13583 \begin_layout Itemize
13584
13585 \family sans
13586 \size normal
13587 Review
13588 \family default
13589  for a Review
13590 \end_layout
13591
13592 \begin_layout Itemize
13593
13594 \family sans
13595 \size normal
13596 Topical
13597 \family default
13598  for a Topical review
13599 \end_layout
13600
13601 \begin_layout Itemize
13602
13603 \family sans
13604 \size normal
13605 Comment
13606 \family default
13607  for a Comment
13608 \end_layout
13609
13610 \begin_layout Itemize
13611
13612 \family sans
13613 \size normal
13614 Note
13615 \family default
13616  for a Note
13617 \end_layout
13618
13619 \begin_layout Itemize
13620
13621 \family sans
13622 \size normal
13623 Paper
13624 \family default
13625  for a Paper (same as Title)
13626 \end_layout
13627
13628 \begin_layout Itemize
13629
13630 \family sans
13631 \size normal
13632 Prelim
13633 \family default
13634  for a Preliminary communication
13635 \end_layout
13636
13637 \begin_layout Itemize
13638
13639 \family sans
13640 \size normal
13641 Rapid
13642 \family default
13643  for a Rapid communication
13644 \end_layout
13645
13646 \begin_layout Itemize
13647
13648 \family sans
13649 \size normal
13650 Letter
13651 \family default
13652  for a Letter to the editor
13653 \end_layout
13654
13655 \end_deeper
13656 \begin_layout Itemize
13657
13658 \size normal
13659 All title environments except of 
13660 \family sans
13661 Letter
13662 \family default
13663  can have an optional short title.
13664 \end_layout
13665
13666 \begin_layout Itemize
13667 There is a general title environment 
13668 \family sans
13669 Article
13670 \family default
13671  which is not directly supported by the \SpecialChar LyX
13672 .
13673  This can be used as \SpecialChar TeX
13674  code when your document doesn't fit into one of the
13675  other title types.
13676 \end_layout
13677
13678 \begin_layout Standard
13679 For more informations like hints for special table and formula formatting,
13680  look at the IOP author guidelines.
13681 \end_layout
13682
13683 \begin_layout Section
13684 Kluwer
13685 \end_layout
13686
13687 \begin_layout Standard
13688 by 
13689 \noun on
13690 Panayotis Papasotiriou
13691 \end_layout
13692
13693 \begin_layout Subsection
13694 Overview
13695 \end_layout
13696
13697 \begin_layout Standard
13698 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
13699  that facilitates electronic manuscript submission to the journals they
13700  publish.
13701  Most known of them (at least in my domain of interest) are 
13702 \emph on
13703 Astrophysics and Space Science
13704 \emph default
13705  and 
13706 \emph on
13707 Solar Physics
13708 \emph default
13709 , but there are many others (see a complete list at 
13710 \begin_inset Flex URL
13711 status open
13712
13713 \begin_layout Plain Layout
13714
13715 http://www.wkap.nl/jrnllist.htm/JRNLHOME
13716 \end_layout
13717
13718 \end_inset
13719
13720 ).
13721  The Kluwer package may be downloaded from the site 
13722 \begin_inset Flex URL
13723 status collapsed
13724
13725 \begin_layout Plain Layout
13726
13727 http://www.wkap.nl/kaphtml.htm/STYLEFILES
13728 \end_layout
13729
13730 \end_inset
13731
13732 .
13733  A complete user guide is contained in that package (but it can also be
13734  downloaded separately).
13735 \end_layout
13736
13737 \begin_layout Standard
13738 \SpecialChar LyX
13739  supports many features of the package but not everything.
13740  However, the \SpecialChar TeX
13741  code needed is reduced to some 
13742 \begin_inset Quotes eld
13743 \end_inset
13744
13745 peculiar
13746 \begin_inset Quotes erd
13747 \end_inset
13748
13749  commands of the package (see
13750 \begin_inset space ~
13751 \end_inset
13752
13753
13754 \begin_inset CommandInset ref
13755 LatexCommand ref
13756 reference "subsec:kluwer_peculiarities"
13757
13758 \end_inset
13759
13760 ).
13761  I have recently used \SpecialChar LyX
13762  to write an article submitted to the 
13763 \emph on
13764 Astrophysics and Space Science
13765 \emph default
13766  without any problem.
13767 \end_layout
13768
13769 \begin_layout Subsection
13770 Writing a paper
13771 \end_layout
13772
13773 \begin_layout Standard
13774 The easiest way to write a paper is to start with the Kluwer template file.
13775  Click on 
13776 \family sans
13777 File\SpecialChar menuseparator
13778 New from
13779 \family default
13780  
13781 \family sans
13782 Template
13783 \family default
13784 , then choose the 
13785 \family typewriter
13786 kluwer.lyx
13787 \family default
13788  template.
13789  This will give an (almost) empty document that includes the most common
13790  fields found in a manuscript and a short description of their use.
13791  As in most templates, simply overwrite the existing text (including the
13792  brackets, 
13793 \family typewriter
13794 <>
13795 \family default
13796 ) with the correct information.
13797 \end_layout
13798
13799 \begin_layout Subsection
13800 Preparing a paper for submission
13801 \end_layout
13802
13803 \begin_layout Standard
13804 As in the AAS\SpecialChar TeX
13805  package, before you submit your paper to a journal you must
13806  
13807 \begin_inset Quotes eld
13808 \end_inset
13809
13810 postprocess
13811 \begin_inset Quotes erd
13812 \end_inset
13813
13814  it as follows.
13815 \end_layout
13816
13817 \begin_layout Enumerate
13818 Export your paper as a \SpecialChar LaTeX
13819  file.
13820  To do this, click on 
13821 \family sans
13822 File\SpecialChar menuseparator
13823 Export\SpecialChar menuseparator
13824 \SpecialChar LaTeX
13825
13826 \family default
13827 .
13828  
13829 \end_layout
13830
13831 \begin_layout Enumerate
13832 Edit the resulting 
13833 \family typewriter
13834 .tex
13835 \family default
13836  file with a text editor and make the following changes
13837 \end_layout
13838
13839 \begin_deeper
13840 \begin_layout Enumerate
13841 remove the comment lines before the 
13842 \family typewriter
13843
13844 \backslash
13845 documentclass
13846 \family default
13847  command,
13848 \end_layout
13849
13850 \begin_layout Enumerate
13851 remove everything between (and including) the 
13852 \family typewriter
13853
13854 \backslash
13855 makeatletter
13856 \family default
13857  and 
13858 \family typewriter
13859
13860 \backslash
13861 makeatother
13862 \family default
13863  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13864  preamble.
13865 \end_layout
13866
13867 \begin_layout Standard
13868 Save the resulting 
13869 \family typewriter
13870 .tex
13871 \family default
13872  file.
13873 \end_layout
13874
13875 \end_deeper
13876 \begin_layout Enumerate
13877 Run the 
13878 \family typewriter
13879 .tex
13880 \family default
13881  file through \SpecialChar LaTeX
13882  as many times as necessary (usually up to three).
13883 \end_layout
13884
13885 \begin_layout Enumerate
13886 View the resulting 
13887 \family typewriter
13888 .dvi
13889 \family default
13890  document using, e.
13891 \begin_inset space \thinspace{}
13892 \end_inset
13893
13894 g.
13895 \begin_inset space \space{}
13896 \end_inset
13897
13898
13899 \family sans
13900 xdvi
13901 \family default
13902 , and check if everything is OK (it should, if you didn't make any mistake).
13903 \end_layout
13904
13905 \begin_layout Subsection
13906 \begin_inset Quotes eld
13907 \end_inset
13908
13909 Peculiarities
13910 \begin_inset Quotes erd
13911 \end_inset
13912
13913  of the Kluwer package
13914 \begin_inset CommandInset label
13915 LatexCommand label
13916 name "subsec:kluwer_peculiarities"
13917
13918 \end_inset
13919
13920
13921 \end_layout
13922
13923 \begin_layout Standard
13924 The Kluwer package has the following 
13925 \begin_inset Quotes eld
13926 \end_inset
13927
13928 peculiarities
13929 \begin_inset Quotes erd
13930 \end_inset
13931
13932 .
13933 \end_layout
13934
13935 \begin_layout Enumerate
13936 It is possible to write multiple articles in the same \SpecialChar LaTeX
13937  file
13938 \begin_inset Foot
13939 status collapsed
13940
13941 \begin_layout Plain Layout
13942 I can't imagine any good reason to do this.
13943 \end_layout
13944
13945 \end_inset
13946
13947 .
13948  Each article must be included in the environment 
13949 \begin_inset Quotes eld
13950 \end_inset
13951
13952 article
13953 \begin_inset Quotes erd
13954 \end_inset
13955
13956 .
13957  Unfortunately, this environment cannot be omitted, even if you write just
13958  one article.
13959  Therefore, each article starts with the command 
13960 \family typewriter
13961
13962 \backslash
13963 begin{article}
13964 \family default
13965  and, obviously, ends with the command 
13966 \family typewriter
13967
13968 \backslash
13969 end{article}
13970 \family default
13971 .
13972  Although this can be implemented in \SpecialChar LyX
13973 , I didn't included it, since it looks
13974  ugly and can confuse the novice user.
13975  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
13976  code (the
13977  well-known 
13978 \begin_inset Quotes eld
13979 \end_inset
13980
13981 \SpecialChar TeX
13982  code
13983 \begin_inset Quotes erd
13984 \end_inset
13985
13986 ).
13987 \end_layout
13988
13989 \begin_layout Enumerate
13990 Information given at the beginning of the article (i.
13991 \begin_inset space \thinspace{}
13992 \end_inset
13993
13994 e.
13995 \begin_inset space \space{}
13996 \end_inset
13997
13998 title, subtitle, author, institution, running title, running author, abstract
13999  and keywords) must be included in an environment called 
14000 \begin_inset Quotes eld
14001 \end_inset
14002
14003 opening
14004 \begin_inset Quotes erd
14005 \end_inset
14006
14007 .
14008  This is not implemented in \SpecialChar LyX
14009 , so you must enter title, subtitle etc.
14010 \begin_inset space ~
14011 \end_inset
14012
14013 between two \SpecialChar TeX
14014  code lines (
14015 \family typewriter
14016
14017 \backslash
14018 begin{opening}
14019 \family default
14020  and 
14021 \family typewriter
14022
14023 \backslash
14024 end{opening}
14025 \family default
14026 ).
14027 \end_layout
14028
14029 \begin_layout Enumerate
14030 According to the user manual, the label of each bibliography item must be
14031  written as 
14032 \family typewriter
14033
14034 \backslash
14035 protect
14036 \backslash
14037 citeauthoryear{
14038 \family default
14039 \emph on
14040 author(s)
14041 \family typewriter
14042 \emph default
14043 }{
14044 \family default
14045 \emph on
14046 year
14047 \family typewriter
14048 \emph default
14049 }
14050 \family default
14051 .
14052 \end_layout
14053
14054 \begin_layout Standard
14055 The 
14056 \family typewriter
14057 kluwer.lyx
14058 \family default
14059  template takes care of all these 
14060 \begin_inset Quotes eld
14061 \end_inset
14062
14063 peculiarities
14064 \begin_inset Quotes erd
14065 \end_inset
14066
14067 .
14068  If you start a new paper using this template you don't need to do anything
14069  special.
14070  Just 
14071 \end_layout
14072
14073 \begin_layout Enumerate
14074 don't delete the \SpecialChar TeX
14075  code included in the template, and
14076 \end_layout
14077
14078 \begin_layout Enumerate
14079 copy the example bibliography item included in the template and modify it
14080  as necessary to enter new bibliography items.
14081 \end_layout
14082
14083 \begin_layout Section
14084 Koma-Script
14085 \end_layout
14086
14087 \begin_layout Standard
14088 by 
14089 \noun on
14090 Bernd Rellermeyer
14091 \end_layout
14092
14093 \begin_layout Subsection
14094 Overview
14095 \end_layout
14096
14097 \begin_layout Standard
14098 The \SpecialChar LyX
14099  document classes 
14100 \emph on
14101 article (koma-script)
14102 \emph default
14103
14104 \emph on
14105 report (koma-script)
14106 \emph default
14107
14108 \emph on
14109 book
14110 \emph default
14111  
14112 \emph on
14113 (koma-script)
14114 \emph default
14115 , and 
14116 \emph on
14117 letter
14118 \emph default
14119  
14120 \emph on
14121 (koma-script)
14122 \emph default
14123  correspond to the \SpecialChar LaTeX
14124  document classes 
14125 \family typewriter
14126 scrartcl.cls
14127 \family default
14128
14129 \family typewriter
14130 scrreprt.cls
14131 \family default
14132
14133 \family typewriter
14134 scrbook.cls
14135 \family default
14136 , and 
14137 \family typewriter
14138 scrlettr.cls
14139 \family default
14140 , resp.
14141 \begin_inset space ~
14142 \end_inset
14143
14144 of the Koma-Script family.
14145  They are replacements for the standard document classes 
14146 \family typewriter
14147 article.cls
14148 \family default
14149
14150 \family typewriter
14151 report.cls
14152 \family default
14153
14154 \family typewriter
14155 book.cls
14156 \family default
14157  and 
14158 \family typewriter
14159 letter.cls
14160 \family default
14161 , resp., and fit better to European typography conventions in a number of
14162  points.
14163 \end_layout
14164
14165 \begin_layout Itemize
14166 Standard character size is 11pt in 
14167 \emph on
14168 article (koma-script)
14169 \emph default
14170
14171 \emph on
14172 report (koma-script)
14173 \emph default
14174 , and 
14175 \emph on
14176 book (koma-script)
14177 \emph default
14178 , and 12pt in 
14179 \emph on
14180 letter (koma-script)
14181 \emph default
14182 .
14183 \end_layout
14184
14185 \begin_layout Itemize
14186 Headings, labels of the description environment, and a number of elements
14187  of the 
14188 \emph on
14189 letter (koma-script)
14190 \emph default
14191  document class are set in a bold sans serif font.
14192 \begin_inset Foot
14193 status collapsed
14194
14195 \begin_layout Plain Layout
14196 There is a big difference between the bold sans serif old cm fonts and new
14197  ec fonts, especially in the appearance of headings.
14198  In comparison, the ec bold sans serif fonts look a bit thin.
14199  Here the \SpecialChar LaTeX
14200  package 
14201 \family typewriter
14202 cmsd.sty by
14203 \family default
14204  
14205 \shape smallcaps
14206 Walter Schmidt
14207 \shape default
14208  helps to produce the 
14209 \begin_inset Quotes eld
14210 \end_inset
14211
14212 usual
14213 \begin_inset Quotes erd
14214 \end_inset
14215
14216  appearance when using the ec fonts.
14217 \end_layout
14218
14219 \end_inset
14220
14221  The numbering of chapter headings is made in the same way as the numbering
14222  of section headings, that is without the extra line 
14223 \begin_inset Quotes eld
14224 \end_inset
14225
14226 Chapter\SpecialChar ldots
14227
14228 \begin_inset Quotes erd
14229 \end_inset
14230
14231 .
14232  In addition, the appearance of the headings can be modified by using a
14233  number of options (in \SpecialChar LyX
14234  to be entered in the field 
14235 \family sans
14236 Extra
14237 \begin_inset space ~
14238 \end_inset
14239
14240 Options
14241 \family default
14242  of the dialog 
14243 \family sans
14244 Layout\SpecialChar menuseparator
14245 Document
14246 \family default
14247 ).
14248  
14249 \end_layout
14250
14251 \begin_layout Itemize
14252 The main means in the Koma-Script document classes to design the type area
14253  are the options 
14254 \family sans
14255 BCOR
14256 \family default
14257  and 
14258 \family sans
14259 DIV
14260 \family default
14261  (in \SpecialChar LyX
14262  to be entered in the extra class options field in the dialog 
14263 \family sans
14264 Document\SpecialChar menuseparator
14265 Settings
14266 \family default
14267 ).
14268  They make a clearer modification of page margins possible as do the options
14269  of the dialog 
14270 \family sans
14271 Document\SpecialChar menuseparator
14272 Settings
14273 \family default
14274 .
14275  
14276 \end_layout
14277
14278 \begin_layout Itemize
14279 The \SpecialChar LaTeX
14280  document classes of the Koma-Script family define a number of additional
14281  commands.
14282  Those part of it which makes sense in \SpecialChar LyX
14283  is implemented in corresponding
14284  paragraph types.
14285 \end_layout
14286
14287 \begin_layout Standard
14288 Detailed descriptions of the \SpecialChar LaTeX
14289  document classes of the Koma-Script family
14290  can be found in the Koma-Script documentation 
14291 \emph on
14292 scrguide
14293 \emph default
14294  (German) and 
14295 \emph on
14296 scrguien
14297 \emph default
14298  (English).
14299 \end_layout
14300
14301 \begin_layout Subsection
14302 article (koma-script), report (koma-script), and book (koma-script)
14303 \end_layout
14304
14305 \begin_layout Standard
14306 The document classes 
14307 \emph on
14308 article (koma-script)
14309 \emph default
14310
14311 \emph on
14312 report (koma-script)
14313 \emph default
14314 , and 
14315 \emph on
14316 book
14317 \emph default
14318  
14319 \emph on
14320 (koma-script)
14321 \emph default
14322  are implemented in the layout files 
14323 \family typewriter
14324 scrartcl.layout
14325 \family default
14326
14327 \family typewriter
14328 scrreprt.layout
14329 \family default
14330 , and 
14331 \family typewriter
14332 scrbook.layout
14333 \family default
14334 , resp.
14335  They contain all the paragraph types of the corresponding standard document
14336  classes 
14337 \emph on
14338 article
14339 \emph default
14340
14341 \emph on
14342 report
14343 \emph default
14344 , and 
14345 \emph on
14346 book
14347 \emph default
14348 , resp., partly modified, with the exception of the \SpecialChar LyX
14349  specific 
14350 \family sans
14351 List
14352 \family default
14353 -type, which is replaced by the new 
14354 \family sans
14355 Labeling
14356 \family default
14357 -type having the same functionality.
14358  Beside the 
14359 \family sans
14360 Labeling
14361 \family default
14362 -Type there is a number of new paragraph types added.
14363  They are 
14364 \emph on
14365 not
14366 \emph default
14367  part of 
14368 \emph on
14369 letter (koma-script)
14370 \emph default
14371 .
14372 \end_layout
14373
14374 \begin_layout Itemize
14375
14376 \family sans
14377 Addpart, Addchap
14378 \family default
14379
14380 \family sans
14381 Addsec
14382 \family default
14383 : are equivalents to 
14384 \family sans
14385 Part*, Chapter*
14386 \family default
14387  and 
14388 \family sans
14389 Section*
14390 \family default
14391 , resp., additionally inserting an entry in the table of contents.
14392  
14393 \family sans
14394 Addpart
14395 \family default
14396  and 
14397 \family sans
14398 Addchap
14399 \family default
14400  are not contained in 
14401 \emph on
14402 article (koma-script)
14403 \emph default
14404 .
14405 \end_layout
14406
14407 \begin_layout Itemize
14408
14409 \family sans
14410 Addchap*
14411 \family default
14412
14413 \family sans
14414 Addsec*
14415 \family default
14416 : behave exactly as 
14417 \family sans
14418 Addchap
14419 \family default
14420  and 
14421 \family sans
14422 Addsec
14423 \family default
14424 , resp., additionally clearing running heads.
14425  
14426 \family sans
14427 Addchap*
14428 \family default
14429  is not contained in 
14430 \emph on
14431 article (koma-script)
14432 \emph default
14433 .
14434 \begin_inset Foot
14435 status collapsed
14436
14437 \begin_layout Plain Layout
14438 There is also an 
14439 \family typewriter
14440
14441 \backslash
14442 addpart*
14443 \family default
14444  command in 
14445 \emph on
14446 book (koma-script)
14447 \emph default
14448  and in 
14449 \emph on
14450 report (koma-script)
14451 \emph default
14452 , but since this is identical to 
14453 \family sans
14454 Part*
14455 \family default
14456 , is has not been implemented in \SpecialChar LyX
14457 .
14458 \end_layout
14459
14460 \end_inset
14461
14462
14463 \end_layout
14464
14465 \begin_layout Itemize
14466
14467 \family sans
14468 Minisec
14469 \family default
14470 : generates a heading directly above the following paragraph in the standard
14471  character size without affecting the structure of the document.
14472 \end_layout
14473
14474 \begin_layout Itemize
14475
14476 \family sans
14477 Captionabove
14478 \family default
14479  and 
14480 \family sans
14481 Captionbelow
14482 \family default
14483  are special captions which respect the different space settings needed
14484  for captions placed above or below an element (if you follow strict typographic
14485  rules, you might want to place table captions always above the table).
14486  You can also use the class option 
14487 \family typewriter
14488 tablecaptionsabove
14489 \family default
14490 , which will switch 
14491 \family sans
14492 caption
14493 \family default
14494  to 
14495 \family sans
14496 captionabove
14497 \family default
14498  for tables and 
14499 \family sans
14500 captionbelow
14501 \family default
14502  for figures.
14503  You need at least Koma-Script version 2.8q to use this.
14504 \end_layout
14505
14506 \begin_layout Itemize
14507
14508 \family sans
14509 Dictum
14510 \family default
14511 : can be used to set a bonmot, e.
14512 \begin_inset space \thinspace{}
14513 \end_inset
14514
14515 g.
14516 \begin_inset space \space{}
14517 \end_inset
14518
14519 at the beginning of a chapter.
14520  If you use the optional argument (
14521 \family sans
14522 Insert\SpecialChar menuseparator
14523 Short
14524 \begin_inset space ~
14525 \end_inset
14526
14527 Title
14528 \family default
14529 ), you can insert the dictum's author there.
14530  Dictum and author are separated by a line.
14531  You need at least Koma-Script version 2.8q to use this.
14532  
14533 \family sans
14534 Dictum
14535 \family default
14536  is not contained in 
14537 \emph on
14538 article (koma-script)
14539 \emph default
14540 .
14541 \end_layout
14542
14543 \begin_layout Standard
14544 The following types, together with the standard types 
14545 \family sans
14546 Title
14547 \family default
14548
14549 \family sans
14550 Author
14551 \family default
14552 , and 
14553 \family sans
14554 Date
14555 \family default
14556 , form the title area of the document.
14557  They must be entered ahead of the first 
14558 \begin_inset Quotes eld
14559 \end_inset
14560
14561 ordinary
14562 \begin_inset Quotes erd
14563 \end_inset
14564
14565  paragraph.
14566 \begin_inset Foot
14567 status collapsed
14568
14569 \begin_layout Plain Layout
14570 The corresponding \SpecialChar LaTeX
14571  commands must appear before the 
14572 \family typewriter
14573
14574 \backslash
14575 maketitle
14576 \family default
14577  command.
14578 \end_layout
14579
14580 \end_inset
14581
14582  When such a type is used more than once, the latter usage overwrites the
14583  former one, that means, for every type only the latest usage is valid.
14584  The order of the different types however has, like 
14585 \family sans
14586 Title
14587 \family default
14588
14589 \family sans
14590 Author
14591 \family default
14592 , and 
14593 \family sans
14594 Date
14595 \family default
14596 , no effect on the appearance of the produced document.
14597 \end_layout
14598
14599 \begin_layout Itemize
14600
14601 \family sans
14602 Subject
14603 \family default
14604 : produces a centered paragraph above the ordinary title (
14605 \family sans
14606 Title
14607 \family default
14608
14609 \family sans
14610 Author
14611 \family default
14612
14613 \family sans
14614 Date
14615 \family default
14616 ) for the subject of the document.
14617 \end_layout
14618
14619 \begin_layout Itemize
14620
14621 \family sans
14622 Publishers
14623 \family default
14624 : produces a centered paragraph below the ordinary title (
14625 \family sans
14626 Title
14627 \family default
14628
14629 \family sans
14630 Author
14631 \family default
14632
14633 \family sans
14634 Date
14635 \family default
14636 ) for the publishers' name.
14637 \end_layout
14638
14639 \begin_layout Itemize
14640
14641 \family sans
14642 Dedication
14643 \family default
14644 : in 
14645 \emph on
14646 report (koma-script)
14647 \emph default
14648  and 
14649 \emph on
14650 book (koma-script)
14651 \emph default
14652  produces a centered paragraph on its own page behind the title page, or
14653  in 
14654 \emph on
14655 article (koma-script)
14656 \emph default
14657  produces a centered paragraph below the ordinary title (
14658 \family sans
14659 Title
14660 \family default
14661
14662 \family sans
14663 Author
14664 \family default
14665
14666 \family sans
14667 Date
14668 \family default
14669
14670 \family sans
14671 Publishers
14672 \family default
14673 ) for a dedication.
14674 \end_layout
14675
14676 \begin_layout Itemize
14677
14678 \family sans
14679 Titlehead
14680 \family default
14681 : produces a left aligned paragraph above the ordinary title (
14682 \family sans
14683 Title
14684 \family default
14685
14686 \family sans
14687 Author
14688 \family default
14689
14690 \family sans
14691 Date
14692 \family default
14693
14694 \family sans
14695 Subject
14696 \family default
14697 ) for a document`s head.
14698 \end_layout
14699
14700 \begin_layout Itemize
14701
14702 \family sans
14703 Uppertitleback
14704 \family default
14705 : produces in a double-sided print in 
14706 \emph on
14707 report (koma-script)
14708 \emph default
14709  and 
14710 \emph on
14711 book (koma-script)
14712 \emph default
14713  a left-aligned paragraph at the top of the title page`s back or has no
14714  effect in a single-sided print or in 
14715 \emph on
14716 article (koma-script)
14717 \emph default
14718 .
14719 \end_layout
14720
14721 \begin_layout Itemize
14722
14723 \family sans
14724 Lowertitleback
14725 \family default
14726 : produces in a double-sided print in 
14727 \emph on
14728 report (koma-script)
14729 \emph default
14730  and 
14731 \emph on
14732 book (koma-script)
14733 \emph default
14734  a left-aligned paragraph at the bottom of the title page`s back or has
14735  no effect in a single-sided print or in 
14736 \emph on
14737 article (koma-script)
14738 \emph default
14739 .
14740 \end_layout
14741
14742 \begin_layout Itemize
14743
14744 \family sans
14745 Extratitle
14746 \family default
14747 : produces a special 
14748 \begin_inset Quotes eld
14749 \end_inset
14750
14751 dirty
14752 \begin_inset Quotes erd
14753 \end_inset
14754
14755  page ahead of the actual document containing a paragraph without special
14756  formatting.
14757 \end_layout
14758
14759 \begin_layout Standard
14760 The layout files for the document classes 
14761 \emph on
14762 article (koma-script)
14763 \emph default
14764
14765 \emph on
14766 report (koma-script)
14767 \emph default
14768 , and 
14769 \emph on
14770 book (koma-script)
14771 \emph default
14772  do include the file 
14773 \family typewriter
14774 scrmacros.inc
14775 \family default
14776 .
14777  This is thought of as a place to define your own types.
14778  Copy scrmacros
14779 \family typewriter
14780 .inc
14781 \family default
14782  in your personal layout directory and edit the file!
14783 \end_layout
14784
14785 \begin_layout Subsection
14786 letter (koma-script)
14787 \end_layout
14788
14789 \begin_layout Standard
14790 \noindent
14791 The document class 
14792 \emph on
14793 letter (koma-script)
14794 \emph default
14795  is implemented in the layout file 
14796 \family typewriter
14797 scrlettr.layout
14798 \family default
14799 .
14800  It contains all the paragraph types of the corresponding standard document
14801  class 
14802 \emph on
14803 letter
14804 \emph default
14805 , partly modified, with the exception of the \SpecialChar LyX
14806  specific types 
14807 \family sans
14808 \SpecialChar LyX
14809 -Code
14810 \family default
14811  and 
14812 \family sans
14813 Comment
14814 \family default
14815  and the 
14816 \family sans
14817 List
14818 \family default
14819  type, which is replaced by the new 
14820 \family sans
14821 Labeling
14822 \family default
14823  type.
14824  In addition, it contains, in contrast to the standard document class, the
14825  standard types 
14826 \family sans
14827 \SpecialChar LaTeX
14828
14829 \family default
14830
14831 \family sans
14832 Quotation
14833 \family default
14834
14835 \family sans
14836 Quote
14837 \family default
14838 , and 
14839 \family sans
14840 Verse
14841 \family default
14842 .
14843  Furthermore, there are a number of new letter specific types.
14844 \end_layout
14845
14846 \begin_layout Standard
14847 The appearance of the letter produced by this document class can be controlled
14848  by a number of \SpecialChar LaTeX
14849  commands, which you can put in the \SpecialChar LaTeX
14850  preamble.
14851 \begin_inset Foot
14852 status collapsed
14853
14854 \begin_layout Plain Layout
14855 For example, the standard appearance of the letter`s heading, consisting
14856  of name and address, is quite self-willed.
14857  An 
14858 \begin_inset Quotes eld
14859 \end_inset
14860
14861 ordinary
14862 \begin_inset Quotes erd
14863 \end_inset
14864
14865  heading is produced by the following \SpecialChar LaTeX
14866  commands in the preamble:
14867 \end_layout
14868
14869 \begin_layout LyX-Code
14870
14871 \backslash
14872 firsthead{
14873 \backslash
14874 parbox[b]{
14875 \backslash
14876 textwidth}
14877 \end_layout
14878
14879 \begin_layout LyX-Code
14880   {
14881 \backslash
14882 ignorespaces 
14883 \backslash
14884 fromname
14885 \backslash
14886
14887 \backslash
14888  
14889 \backslash
14890 ignorespaces 
14891 \backslash
14892 fromaddress}} 
14893 \end_layout
14894
14895 \begin_layout LyX-Code
14896
14897 \backslash
14898 nexthead{
14899 \backslash
14900 parbox[b]{
14901 \backslash
14902 textwidth}
14903 \end_layout
14904
14905 \begin_layout LyX-Code
14906   {
14907 \backslash
14908 ignorespaces 
14909 \backslash
14910 fromname 
14911 \backslash
14912 hfill 
14913 \backslash
14914 ignorespaces 
14915 \backslash
14916 pagename
14917 \backslash
14918  
14919 \backslash
14920 thepage}}
14921 \end_layout
14922
14923 \end_inset
14924
14925  A detailed German description of such \SpecialChar LaTeX
14926  commands can be found in the Koma-Script
14927  documentation 
14928 \emph on
14929 scrguide
14930 \emph default
14931 .
14932  With it, the letter's author can produce his personal letter layout.
14933 \end_layout
14934
14935 \begin_layout Standard
14936 The types 
14937 \family sans
14938 Letter
14939 \family default
14940  and 
14941 \family sans
14942 Opening
14943 \family default
14944  define the beginning of the letter and must be used in every letter.
14945  To emphasize them in the \SpecialChar LyX
14946  document class, they are marked with the letter
14947  
14948 \shape italic
14949 L
14950 \shape default
14951  or 
14952 \shape italic
14953 O
14954 \shape default
14955 , resp.
14956 \begin_inset space ~
14957 \end_inset
14958
14959 in the left margin.
14960  It is possible to write any number of letters in one file.
14961  An 
14962 \family sans
14963 Opening
14964 \family default
14965  type produces a new letter using the same addressee and a 
14966 \family sans
14967 Letter
14968 \family default
14969  type produces a new addressee.
14970  The types 
14971 \family sans
14972 Closing
14973 \family default
14974
14975 \family sans
14976 PS
14977 \family default
14978
14979 \family sans
14980 CC
14981 \family default
14982 , and 
14983 \family sans
14984 Encl
14985 \family default
14986  are ordinary paragraph types and can also be used several times in one
14987  and the same letter.
14988 \end_layout
14989
14990 \begin_layout Itemize
14991
14992 \family sans
14993 Letter
14994 \family default
14995 : produces a paragraph for the addressee and implicitly defines the beginning
14996  of the letter.
14997 \end_layout
14998
14999 \begin_layout Itemize
15000
15001 \family sans
15002 Opening
15003 \family default
15004 : produces a paragraph for the form of address and implicitly produces a
15005  new letter.
15006 \end_layout
15007
15008 \begin_layout Itemize
15009
15010 \family sans
15011 Closing
15012 \family default
15013 : produces a paragraph for a close.
15014 \end_layout
15015
15016 \begin_layout Itemize
15017
15018 \family sans
15019 PS
15020 \family default
15021 : produces a paragraph for a postscript.
15022 \end_layout
15023
15024 \begin_layout Itemize
15025
15026 \family sans
15027 CC
15028 \family default
15029 : produces a paragraph for a distribution list.
15030 \end_layout
15031
15032 \begin_layout Itemize
15033
15034 \family sans
15035 Encl
15036 \family default
15037 : produces a paragraph for enclosures.
15038 \end_layout
15039
15040 \begin_layout Standard
15041 The types 
15042 \family sans
15043 Name
15044 \family default
15045
15046 \family sans
15047 Signature
15048 \family default
15049
15050 \family sans
15051 Address
15052 \family default
15053
15054 \family sans
15055 Telephone
15056 \family default
15057
15058 \family sans
15059 Place
15060 \family default
15061
15062 \family sans
15063 Backaddress
15064 \family default
15065
15066 \family sans
15067 Specialmail
15068 \family default
15069
15070 \family sans
15071 Location
15072 \family default
15073
15074 \family sans
15075 Title
15076 \family default
15077 , and 
15078 \family sans
15079 Subject
15080 \family default
15081  are input types provided with a label to enter information, which will
15082  be processed by the document class.
15083 \begin_inset Foot
15084 status open
15085
15086 \begin_layout Plain Layout
15087 It could be seen as a matter of inconsequence, that the types 
15088 \family sans
15089 Letter
15090 \family default
15091  and 
15092 \family sans
15093 Opening
15094 \family default
15095  described above are not such input types as well.
15096  Because of the special meaning of those types, however, I have implemented
15097  them as ordinary paragraph types with a one letter mark in the left margin.
15098  Moreover, it would affect my feeling of symmetry, if the 
15099 \family sans
15100 Opening
15101 \family default
15102  type and the 
15103 \family sans
15104 Closing
15105 \family default
15106  type had such a serious different appearance.
15107 \end_layout
15108
15109 \end_inset
15110
15111  The types must be used ahead of the corresponding 
15112 \family sans
15113 Opening
15114 \family default
15115  type.
15116 \end_layout
15117
15118 \begin_layout Standard
15119 An implementation of these types in a WYSIWYG fashion does not seem to make
15120  sense, because the real appearance of the produced letter does not only
15121  depend on the usage of the particular type, but also on other factors.
15122  For example, a signature entered in the 
15123 \family sans
15124 Signature
15125 \family default
15126  type will in the standard behavior appear in the produced letter only,
15127  when in the same letter also a 
15128 \family sans
15129 Closing
15130 \family default
15131  type is used.
15132  The entered value of the 
15133 \family sans
15134 Telephone
15135 \family default
15136  type will in the standard behavior not appear in the produced letter at
15137  all.
15138  The possibility to design the letter`s heading freely is already indicated
15139  in a footnote above.
15140 \end_layout
15141
15142 \begin_layout Standard
15143 The input types can also be used as empty paragraphs.
15144  This makes sense e.
15145 \begin_inset space \thinspace{}
15146 \end_inset
15147
15148 g.
15149 \begin_inset space \space{}
15150 \end_inset
15151
15152 for the 
15153 \family sans
15154 Signature
15155 \family default
15156  type.
15157  If the 
15158 \family sans
15159 Signature
15160 \family default
15161  type is not used at all, in the standard behavior the value of the 
15162 \family sans
15163 Name
15164 \family default
15165  type is used as signature, whereas if an empty 
15166 \family sans
15167 Signature
15168 \family default
15169  type is used, no signature value is defined.
15170 \end_layout
15171
15172 \begin_layout Standard
15173 By using the input types it is possible to write a letter template, containing
15174  filled input types with your personal dates (name, address, etc.) and empty
15175  input types for other dates you want to enter.
15176 \end_layout
15177
15178 \begin_layout Itemize
15179
15180 \family sans
15181 Name
15182 \family default
15183 : sender's name, in the standard behavior appears as a centered paragraph
15184  in small caps in the letter`s heading.
15185 \end_layout
15186
15187 \begin_layout Itemize
15188
15189 \family sans
15190 Signature
15191 \family default
15192 : sender's signature, in the standard behavior appears below the 
15193 \family sans
15194 Closing
15195 \family default
15196  type.
15197  If no 
15198 \family sans
15199 Signature
15200 \family default
15201  type is used, the value of the 
15202 \family sans
15203 Name
15204 \family default
15205  type appears instead.
15206 \end_layout
15207
15208 \begin_layout Itemize
15209
15210 \family sans
15211 Address
15212 \family default
15213 : sender's address, in the standard behavior appears in a centered paragraph
15214  in the letter`s heading below the sender's name.
15215 \end_layout
15216
15217 \begin_layout Itemize
15218
15219 \family sans
15220 Telephone
15221 \family default
15222 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
15223  variable
15224  
15225 \family typewriter
15226
15227 \backslash
15228 telephonenum
15229 \family default
15230 .
15231 \end_layout
15232
15233 \begin_layout Itemize
15234
15235 \family sans
15236 Place
15237 \family default
15238 : place of the letter`s making.
15239 \end_layout
15240
15241 \begin_layout Itemize
15242
15243 \family sans
15244 Date
15245 \family default
15246 : date of the letter`s making.
15247  
15248 \family sans
15249 Place
15250 \family default
15251  and 
15252 \family sans
15253 Date
15254 \family default
15255 , in the standard behavior, produce the place and the date in a right-aligned
15256  line below the addressee's field.
15257  If an empty 
15258 \family sans
15259 Date
15260 \family default
15261  type is used, neither place nor date appear, independent of the value of
15262  the 
15263 \family sans
15264 Place
15265 \family default
15266  type.
15267  If no 
15268 \family sans
15269 Date
15270 \family default
15271  type is used, the date of the letter `s production is used.
15272 \end_layout
15273
15274 \begin_layout Itemize
15275
15276 \family sans
15277 Backaddress
15278 \family default
15279 : sender`s back address, in the standard behavior appears above the addressee's
15280  field in a small sans serif font.
15281 \end_layout
15282
15283 \begin_layout Itemize
15284
15285 \family sans
15286 Specialmail
15287 \family default
15288 : special mail information, in the standard behavior appears underlined
15289  above the addressee's field below the back address.
15290 \end_layout
15291
15292 \begin_layout Itemize
15293
15294 \family sans
15295 Location
15296 \family default
15297 : additional information, in the standard behavior appears on right side
15298  below the addressee`s field.
15299 \end_layout
15300
15301 \begin_layout Itemize
15302
15303 \family sans
15304 Title
15305 \family default
15306 : the letter's title, in the standard behavior appears in a big, bold, sans
15307  serif font above the subject.
15308 \end_layout
15309
15310 \begin_layout Itemize
15311
15312 \family sans
15313 Subject
15314 \family default
15315 : the letter's subject, in the standard behavior appears in a bold font
15316  above the 
15317 \family sans
15318 Opening
15319 \family default
15320  paragraph.
15321 \end_layout
15322
15323 \begin_layout Standard
15324 The types 
15325 \family sans
15326 Yourref
15327 \family default
15328
15329 \family sans
15330 Yourmail
15331 \family default
15332
15333 \family sans
15334 Myref
15335 \family default
15336
15337 \family sans
15338 Customer
15339 \family default
15340 , and 
15341 \family sans
15342 Invoice
15343 \family default
15344  produce a business letter like line above the 
15345 \family sans
15346 Title
15347 \family default
15348  line containing the fields 
15349 \begin_inset Quotes eld
15350 \end_inset
15351
15352 Your ref.
15353 \begin_inset Quotes erd
15354 \end_inset
15355
15356
15357 \begin_inset Quotes eld
15358 \end_inset
15359
15360 Your letter of
15361 \begin_inset Quotes erd
15362 \end_inset
15363
15364
15365 \begin_inset Quotes eld
15366 \end_inset
15367
15368 Our ref.
15369 \begin_inset Quotes erd
15370 \end_inset
15371
15372
15373 \begin_inset Quotes eld
15374 \end_inset
15375
15376 Customer no.
15377 \begin_inset Quotes erd
15378 \end_inset
15379
15380
15381 \begin_inset Quotes eld
15382 \end_inset
15383
15384 Invoice no.
15385 \begin_inset Quotes erd
15386 \end_inset
15387
15388 , and 
15389 \begin_inset Quotes eld
15390 \end_inset
15391
15392 Date
15393 \begin_inset Quotes erd
15394 \end_inset
15395
15396 .
15397  For the date field, the value of the 
15398 \family sans
15399 Date
15400 \family default
15401  type is used.
15402  If one of these 
15403 \begin_inset Quotes eld
15404 \end_inset
15405
15406 business letter types
15407 \begin_inset Quotes erd
15408 \end_inset
15409
15410  is used, the value of the 
15411 \family sans
15412 Place
15413 \family default
15414  type however does not appear, but only the \SpecialChar LaTeX
15415  variable 
15416 \family typewriter
15417
15418 \backslash
15419 fromplace
15420 \family default
15421  is set.
15422  The ordinary output of place and date in a right-aligned line below the
15423  addressee`s field is suppressed.
15424  The types are implemented as input types provided with a label and must
15425  be used ahead of the corresponding 
15426 \family sans
15427 Opening
15428 \family default
15429  type.
15430 \end_layout
15431
15432 \begin_layout Itemize
15433
15434 \family sans
15435 Yourref
15436 \family default
15437 : Your ref.
15438 \end_layout
15439
15440 \begin_layout Itemize
15441
15442 \family sans
15443 Yourmail
15444 \family default
15445 : Your letter of.
15446 \end_layout
15447
15448 \begin_layout Itemize
15449
15450 \family sans
15451 Myref
15452 \family default
15453 : Our ref.
15454 \end_layout
15455
15456 \begin_layout Itemize
15457
15458 \family sans
15459 Customer
15460 \family default
15461 : Customer no.
15462 \end_layout
15463
15464 \begin_layout Itemize
15465
15466 \family sans
15467 Invoice
15468 \family default
15469 : Invoice no.
15470 \end_layout
15471
15472 \begin_layout Subsection
15473 The new letter class: letter (koma-script v.2)
15474 \end_layout
15475
15476 \begin_layout Standard
15477 by 
15478 \noun on
15479 Jürgen Spitzmüller
15480 \end_layout
15481
15482 \begin_layout Standard
15483 \begin_inset VSpace medskip
15484 \end_inset
15485
15486
15487 \end_layout
15488
15489 \begin_layout Standard
15490 \noindent
15491 Koma-Script version 2.8 has introduced a new letter class 
15492 \family typewriter
15493 scrlttr2
15494 \family default
15495  which supersedes the now unsupported 
15496 \family typewriter
15497 scrlettr
15498 \family default
15499 .
15500  It has — on the \SpecialChar LaTeX
15501  side — a completely new interface and is not compatible
15502  with the old class.
15503  Therefore, \SpecialChar LyX
15504  supports both, though it is recommended you use the new class.
15505 \end_layout
15506
15507 \begin_layout Standard
15508 This class covers the same functionality as 
15509 \emph on
15510 letter (koma-script),
15511 \emph default
15512  and a few more.
15513  The basic items are 
15514 \family sans
15515 Address
15516 \family default
15517  (receiver's address, same as 
15518 \family sans
15519 Letter
15520 \family default
15521  in the old layout), 
15522 \family sans
15523 Opening
15524 \family default
15525 , and 
15526 \family sans
15527 Closing
15528 \family default
15529 .
15530  
15531 \family sans
15532 NextAddress
15533 \family default
15534  will start a new letter (i.
15535 \begin_inset space \thinspace{}
15536 \end_inset
15537
15538 e.
15539 \begin_inset space \space{}
15540 \end_inset
15541
15542 you can write several letters per document).
15543  New elements are sender's 
15544 \family sans
15545 E-Mail
15546 \family default
15547
15548 \family sans
15549 URL
15550 \family default
15551
15552 \family sans
15553 Fax
15554 \family default
15555
15556 \family sans
15557 Bank
15558 \family default
15559  and the possibility to use a 
15560 \family sans
15561 Logo
15562 \family default
15563  (via 
15564 \family sans
15565 Insert\SpecialChar menuseparator
15566 Graphics
15567 \family default
15568 ) in the header.
15569 \end_layout
15570
15571 \begin_layout Standard
15572 The biggest improvement is, though, that the letter's layout is configurable
15573  to meet almost any needs.
15574  This can be done via the preamble or with a special style file (Letter
15575  Class Option, extension 
15576 \family typewriter
15577 *.lco
15578 \family default
15579 ), that will be read in as a class option.
15580 \begin_inset Foot
15581 status collapsed
15582
15583 \begin_layout Plain Layout
15584 The KOMA package comes with some default 
15585 \family typewriter
15586 *.lco
15587 \family default
15588  files.
15589  There is, for instance, a 
15590 \family typewriter
15591 DIN.lco
15592 \family default
15593  file that follows german typesetting rules, or a 
15594 \family typewriter
15595 KOMAold.lco
15596 \family default
15597  that provides the default layout of the old 
15598 \family typewriter
15599 scrlettr
15600 \family default
15601  class.
15602  The latter can be loaded with the class option 
15603 \family typewriter
15604 KOMAold
15605 \family default
15606 , inserted via the 
15607 \family sans
15608 Layout\SpecialChar menuseparator
15609 Document\SpecialChar menuseparator
15610 Extra Options
15611 \family default
15612  field.
15613 \end_layout
15614
15615 \end_inset
15616
15617  Have a look at the 
15618 \emph on
15619 koma-letter2
15620 \emph default
15621  template that is included in \SpecialChar LyX
15622  for examples.
15623  A detailed description is to be found in the Koma-Script documentation
15624  (
15625 \emph on
15626 scrguide
15627 \emph default
15628 ).
15629 \end_layout
15630
15631 \begin_layout Subsection
15632 Problems
15633 \end_layout
15634
15635 \begin_layout Standard
15636 Visualizing the Koma-Script document classes in \SpecialChar LyX
15637 , the \SpecialChar LyX
15638  internals cause some
15639  problems.
15640 \end_layout
15641
15642 \begin_layout Itemize
15643 The chapter number of a 
15644 \family sans
15645 Chapter
15646 \family default
15647  type appears on a line of its own above the chapter heading instead of
15648  appearing in the same line ahead of it.
15649  The cause for that is the \SpecialChar LyX
15650  internal behavior for the labeltype 
15651 \family sans
15652 Counter_Chapter
15653 \family default
15654  in the layout file.
15655 \end_layout
15656
15657 \begin_layout Itemize
15658 The headings of the types 
15659 \family sans
15660 Addchap
15661 \family default
15662  and 
15663 \family sans
15664 Addsec
15665 \family default
15666  are only put in the 
15667 \begin_inset Quotes eld
15668 \end_inset
15669
15670 true
15671 \begin_inset Quotes erd
15672 \end_inset
15673
15674  \SpecialChar LaTeX
15675  table of contents, but not in the \SpecialChar LyX
15676  table of contents (
15677 \family sans
15678 Document\SpecialChar menuseparator
15679 Table
15680 \begin_inset space ~
15681 \end_inset
15682
15683 of
15684 \begin_inset space ~
15685 \end_inset
15686
15687 Contents
15688 \family default
15689 ).
15690 \end_layout
15691
15692 \begin_layout Itemize
15693 The paragraphs in a 
15694 \emph on
15695 letter
15696 \emph default
15697  document class appear in a skip separation mode, not indented.
15698  This is the standard behavior, no special \SpecialChar LaTeX
15699  commands are needed for that.
15700  But in the 
15701 \family sans
15702 Document\SpecialChar menuseparator
15703 Settings
15704 \family default
15705  dialog the corresponding radio button indicates 
15706 \family sans
15707 Indent
15708 \family default
15709 .
15710  A 
15711 \family sans
15712 Skip
15713 \family default
15714  value always has the effect that extra \SpecialChar LaTeX
15715  commands are inserted in the document
15716  to produce the gap, which is not what is wanted in this case.
15717 \end_layout
15718
15719 \begin_layout Section
15720 Memoir
15721 \end_layout
15722
15723 \begin_layout Standard
15724 By 
15725 \noun on
15726 Jürgen Spitzmüller
15727 \end_layout
15728
15729 \begin_layout Subsection
15730 Overview
15731 \end_layout
15732
15733 \begin_layout Standard
15734 Memoir is a very powerful and constantly evolving class.
15735  It has been designed with regard to fictional and non-fictional literature.
15736  Its aim is to let the user have maximum control over the typesetting of
15737  his document.
15738  Memoir is based on the standard book class, but it can also emulate the
15739  article class (see below).
15740 \end_layout
15741
15742 \begin_layout Standard
15743 Peter Wilson, the developer of Memoir, is known as the author of lots of
15744  useful packages in the \SpecialChar LaTeX
15745  world.
15746  Most of them have been merged with Memoir.
15747  Therefore, it is much easier to layout the table of contents, appendices,
15748  chapter designs and such.
15749  \SpecialChar LyX
15750 , though, does not support all of these goodies natively.
15751  Some of them might be added to forthcoming releases
15752 \begin_inset Foot
15753 status collapsed
15754
15755 \begin_layout Plain Layout
15756 You are invited to send suggestions to 
15757 \begin_inset Flex URL
15758 status collapsed
15759
15760 \begin_layout Plain Layout
15761
15762 lyx-devel@lists.lyx.org
15763 \end_layout
15764
15765 \end_inset
15766
15767 .
15768 \end_layout
15769
15770 \end_inset
15771
15772 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
15773 's framework.
15774  Of course you can still use all features with the help of some native \SpecialChar LaTeX
15775
15776  commands (\SpecialChar TeX
15777  code
15778 \begin_inset Foot
15779 status collapsed
15780
15781 \begin_layout Plain Layout
15782 Cf.
15783 \begin_inset ERT
15784 status collapsed
15785
15786 \begin_layout Plain Layout
15787
15788
15789 \backslash
15790  
15791 \end_layout
15792
15793 \end_inset
15794
15795 section
15796 \begin_inset space ~
15797 \end_inset
15798
15799
15800 \begin_inset CommandInset ref
15801 LatexCommand ref
15802 reference "sec:Inserting-TeX-Code"
15803
15804 \end_inset
15805
15806  for details.
15807 \end_layout
15808
15809 \end_inset
15810
15811 ).
15812  In this section, we can only list those features that are natively supported
15813  by \SpecialChar LyX
15814 .
15815  For detailed descriptions (and for the rest of features) we recommend you
15816  have a look at the detailed manual of the Memoir class
15817 \begin_inset Foot
15818 status collapsed
15819
15820 \begin_layout Plain Layout
15821 Cf.
15822 \begin_inset ERT
15823 status collapsed
15824
15825 \begin_layout Plain Layout
15826
15827
15828 \backslash
15829  
15830 \end_layout
15831
15832 \end_inset
15833
15834
15835 \begin_inset Flex URL
15836 status collapsed
15837
15838 \begin_layout Plain Layout
15839
15840 CTAN:/macros/latex/memoir/memman.pdf
15841 \end_layout
15842
15843 \end_inset
15844
15845 .
15846 \end_layout
15847
15848 \end_inset
15849
15850 , which is not only a user guide for the class, but also both a comprehensive
15851  description on good typesetting and a superb example for good typesetting
15852  itself.
15853 \end_layout
15854
15855 \begin_layout Subsection
15856 Basic features and restrictions
15857 \end_layout
15858
15859 \begin_layout Standard
15860 Memoir supports basically all features of the standard book classes.
15861  There are, however, some differences, as follows:
15862 \end_layout
15863
15864 \begin_layout Description
15865 Font
15866 \begin_inset space ~
15867 \end_inset
15868
15869 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
15870 \end_layout
15871
15872 \begin_layout Description
15873 Page
15874 \begin_inset space ~
15875 \end_inset
15876
15877 style: The fancy page style is not supported, due to a command clash between
15878  Memoir and the fancyhdr package (they both define a command with the same
15879  name, which confuses \SpecialChar LaTeX
15880 ).
15881  Instead, Memoir comes with a number of its own page styles (see 
15882 \family sans
15883 Layout\SpecialChar menuseparator
15884 Document\SpecialChar menuseparator
15885 Page
15886 \begin_inset space ~
15887 \end_inset
15888
15889 Style
15890 \family default
15891 ).
15892  If you want to use these for the chapter pages, you have to use the command
15893  
15894 \family typewriter
15895
15896 \backslash
15897 chapterstyle
15898 \family default
15899  in the main text or in preamble (e.
15900 \begin_inset space \thinspace{}
15901 \end_inset
15902
15903 g.
15904 \begin_inset space \space{}
15905 \end_inset
15906
15907
15908 \family typewriter
15909
15910 \backslash
15911 chapterstyle{companion}
15912 \family default
15913 ).
15914 \end_layout
15915
15916 \begin_layout Description
15917 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
15918  optional argument in the standard classes.
15919  With this, you can specify an alternative version of the title for the
15920  table of contents and the headers (for instance, if the title is too long).
15921  In \SpecialChar LyX
15922 , you can do this via 
15923 \family sans
15924 Insert\SpecialChar menuseparator
15925 Short
15926 \begin_inset space ~
15927 \end_inset
15928
15929 Title
15930 \family default
15931  at the beginning of a chapter/section.
15932  Memoir features a second optional argument and thus separates the table
15933  of contents from the header.
15934  You can define three variants of a title with this: one for the main text,
15935  one for the table of contents, and one for the headers.
15936  Simply insert two optional arguments if you need this feature, the first
15937  one containing the short title for the Table of Contents, the second one
15938  containing an alternative short title for the headers.
15939 \end_layout
15940
15941 \begin_layout Description
15942 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15943  of contents, the list of figures and the list of table start a new page
15944  automatically.
15945  Memoir does not follow this route.
15946  You have to insert a page break yourself, if you want to have one.
15947 \end_layout
15948
15949 \begin_layout Description
15950 Titlepage: For some unknown reason, Memoir uses pagination on the title
15951  page (in the standard classes, title pages are 
15952 \begin_inset Quotes eld
15953 \end_inset
15954
15955 empty
15956 \begin_inset Quotes erd
15957 \end_inset
15958
15959 ).
15960  If you want an empty title page, type 
15961 \family typewriter
15962
15963 \backslash
15964 aliaspagestyle{title}{empty}
15965 \family default
15966  in the preamble.
15967 \end_layout
15968
15969 \begin_layout Description
15970 Article: With the class option 
15971 \emph on
15972 article
15973 \emph default
15974  (to be inserted in 
15975 \family sans
15976 Layout\SpecialChar menuseparator
15977 Document\SpecialChar menuseparator
15978 Extra
15979 \begin_inset space ~
15980 \end_inset
15981
15982 Options
15983 \family default
15984 ), you can emulate article style.
15985  That is, counters (footnotes, figures, tables etc.) will not be reset on
15986  new chapters, chapters don't start a new page (but are—in contrary to 
15987 \begin_inset Quotes eld
15988 \end_inset
15989
15990 real
15991 \begin_inset Quotes erd
15992 \end_inset
15993
15994  article classes—still allowed), parts, though, use their own page, as in
15995  book.
15996 \end_layout
15997
15998 \begin_layout Description
15999 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
16000  font commands, which have been used in the old \SpecialChar LaTeX
16001  version 2.09 (e.
16002 \begin_inset space \thinspace{}
16003 \end_inset
16004
16005 g.
16006 \begin_inset space \space{}
16007 \end_inset
16008
16009
16010 \family typewriter
16011
16012 \backslash
16013 rm
16014 \family default
16015
16016 \family typewriter
16017
16018 \backslash
16019 it
16020 \family default
16021 ).
16022  It produces an error and stops \SpecialChar LaTeX
16023  whenever such a command appears.
16024  The class option 
16025 \emph on
16026 oldfontcommands
16027 \emph default
16028  reallows the commands and spits out warnings instead (which does at least
16029  not stop \SpecialChar LaTeX
16030 ).
16031  Since a lot of packages and particularly Bib\SpecialChar TeX
16032  style files are still using
16033  those commands, we have decided to use this option by default.
16034 \end_layout
16035
16036 \begin_layout Subsection
16037 Extra features
16038 \end_layout
16039
16040 \begin_layout Standard
16041 We will only describe the features supported by \SpecialChar LyX
16042  (which is not much currently).
16043  Please consult the Memoir manual
16044 \begin_inset Foot
16045 status collapsed
16046
16047 \begin_layout Plain Layout
16048 Cf.
16049 \begin_inset ERT
16050 status collapsed
16051
16052 \begin_layout Plain Layout
16053
16054
16055 \backslash
16056  
16057 \end_layout
16058
16059 \end_inset
16060
16061
16062 \begin_inset Flex URL
16063 status collapsed
16064
16065 \begin_layout Plain Layout
16066
16067 CTAN:/macros/latex/memoir/memman.pdf
16068 \end_layout
16069
16070 \end_inset
16071
16072 .
16073 \end_layout
16074
16075 \end_inset
16076
16077  for details.
16078 \end_layout
16079
16080 \begin_layout Description
16081 Abstract: You may wonder why an abstract is an extra feature.
16082  Well, it is in book class.
16083  Usually books don't have abstracts.
16084  Memoir, however, has.
16085  You can use it wherever and how often you like.
16086 \end_layout
16087
16088 \begin_layout Description
16089 Chapterprecis: You may know this older typesetting style: The contents of
16090  a chapter are summarized below the title and also in the table of contents
16091  (e.
16092 \begin_inset space \thinspace{}
16093 \end_inset
16094
16095 g.
16096 \begin_inset space \space{}
16097 \end_inset
16098
16099
16100 \emph on
16101 Our hero arrives in Troia; he loses some friends; he finds others
16102 \emph default
16103 ).
16104  Chapterprecis does exactly this.
16105  It is therefore only sensible below a chapter.
16106 \end_layout
16107
16108 \begin_layout Description
16109 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
16110  The epigraph environment provides an elegant way of typesetting such a
16111  motto.
16112  The motto itself (text) and its author (source) are divided by a short
16113  line.
16114  Unfortunately, we have to fool \SpecialChar LyX
16115  a bit here again, since the environment
16116  needs two arguments (text and source).
16117  In this case, we have to use curly brackets (in \SpecialChar TeX
16118  mode) between the two
16119  arguments: 
16120 \emph on
16121 <smart slogan>
16122 \emph default
16123  
16124 \family typewriter
16125 }{
16126 \family default
16127  
16128 \emph on
16129 <author of the slogan>.
16130 \end_layout
16131
16132 \begin_layout Description
16133 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
16134  complex figurative poems).
16135  \SpecialChar LyX
16136  can only support a few of them.
16137  One is poemtitle, which is a centered title for poems, which will also
16138  be added to the table of contents (verse is the standard environment for
16139  poems.
16140  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
16141  code,
16142  because they have to be nested inside regular verse environments, which
16143  is not possible with \SpecialChar LyX
16144 ).
16145 \end_layout
16146
16147 \begin_layout Description
16148 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
16149 \end_layout
16150
16151 \begin_layout Section
16152 Article (mwart), book (mwbk) and report (mwrep)
16153 \begin_inset Argument status
16154 status collapsed
16155
16156 \begin_layout Plain Layout
16157 The 
16158 \family typewriter
16159 mw
16160 \family default
16161  Classes
16162 \end_layout
16163
16164 \end_inset
16165
16166
16167 \end_layout
16168
16169 \begin_layout Standard
16170 by 
16171 \noun on
16172 Tomasz Luczak
16173 \end_layout
16174
16175 \begin_layout Standard
16176 The \SpecialChar LyX
16177  document classes 
16178 \emph on
16179 article (mwart)
16180 \emph default
16181
16182 \emph on
16183 report (mwrep)
16184 \emph default
16185  and 
16186 \emph on
16187 book
16188 \emph default
16189  
16190 \emph on
16191 (mwbk)
16192 \emph default
16193  correspond to the \SpecialChar LaTeX
16194  document classes 
16195 \family typewriter
16196 mwart.cls
16197 \family default
16198
16199 \family typewriter
16200 mwrep.cls
16201 \family default
16202  and 
16203 \family typewriter
16204 mwbk.cls
16205 \family default
16206 , resp.
16207  They are replacements for the standard document classes 
16208 \family typewriter
16209 article.cls
16210 \family default
16211
16212 \family typewriter
16213 report.cls
16214 \family default
16215  and 
16216 \family typewriter
16217 book.cls
16218 \family default
16219 , resp., and fit better to Polish typography conventions in a number of points.
16220  
16221 \end_layout
16222
16223 \begin_layout Standard
16224 Basic differences:
16225 \end_layout
16226
16227 \begin_layout Itemize
16228 Unnumbered titles (with star, e.
16229 \begin_inset space \thinspace{}
16230 \end_inset
16231
16232 g.
16233 \begin_inset space \space{}
16234 \end_inset
16235
16236
16237 \family sans
16238 Section*
16239 \family default
16240 ) are added into table of contents,
16241 \end_layout
16242
16243 \begin_layout Itemize
16244 Additional page styles:
16245 \end_layout
16246
16247 \begin_deeper
16248 \begin_layout Description
16249 uheadings header with separated lines,
16250 \end_layout
16251
16252 \begin_layout Description
16253 myheadings custom header, contents headers via commands: 
16254 \family typewriter
16255
16256 \backslash
16257 markright
16258 \family default
16259  and 
16260 \family typewriter
16261
16262 \backslash
16263 markboth
16264 \family default
16265 ,
16266 \end_layout
16267
16268 \begin_layout Description
16269 myuheadings custom header with separated lines,
16270 \end_layout
16271
16272 \begin_layout Description
16273 outer page number is placed on outer side of page
16274 \end_layout
16275
16276 \end_deeper
16277 \begin_layout Itemize
16278 Options 
16279 \end_layout
16280
16281 \begin_deeper
16282 \begin_layout Description
16283 rmheadings serif titles — default,
16284 \end_layout
16285
16286 \begin_layout Description
16287 sfheadings sansserif titles,
16288 \end_layout
16289
16290 \begin_layout Description
16291 authortitle on title page first placed is author next title — default,
16292 \end_layout
16293
16294 \begin_layout Description
16295 titleauthor on title page first placed is title next author,
16296 \end_layout
16297
16298 \begin_layout Description
16299 withmarginpar reserve place on page for margins.
16300 \end_layout
16301
16302 \end_deeper
16303 \begin_layout Section
16304 Paper
16305 \end_layout
16306
16307 \begin_layout Standard
16308 The document class 
16309 \family sans
16310 paper
16311 \family default
16312  provides an alternative to the standard 
16313 \family sans
16314 article
16315 \family default
16316  class.
16317  It provides similar functionality, but you might prefer this layout with
16318  sans serif sections, headings, and more.
16319 \end_layout
16320
16321 \begin_layout Section
16322 Rev\SpecialChar TeX
16323 4
16324 \end_layout
16325
16326 \begin_layout Standard
16327 by 
16328 \noun on
16329 Amir Karger
16330 \end_layout
16331
16332 \begin_layout Standard
16333 \begin_inset VSpace bigskip
16334 \end_inset
16335
16336
16337 \end_layout
16338
16339 \begin_layout Standard
16340 \noindent
16341 The 
16342 \family sans
16343 Revtex
16344 \begin_inset space ~
16345 \end_inset
16346
16347 4
16348 \family default
16349  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
16350  4.0 (the 
16351 \begin_inset Formula $\beta$
16352 \end_inset
16353
16354  release of May, 1999) class.
16355 \end_layout
16356
16357 \begin_layout Standard
16358 \SpecialChar LyX
16359  has a 
16360 \family sans
16361 Revtex
16362 \family default
16363  textclass, which works with Rev\SpecialChar TeX
16364  3.1.
16365  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
16366  2.09.
16367  That means that it doesn't interact very well with \SpecialChar LyX
16368 , which requires \SpecialChar LaTeX2e
16369 , although
16370  it has been kludged to work.
16371  Since Rev\SpecialChar TeX
16372  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
16373 , \SpecialChar LyX
16374  with the
16375  
16376 \family sans
16377 Rev\SpecialChar TeX
16378
16379 \begin_inset space ~
16380 \end_inset
16381
16382 4
16383 \family default
16384  textclass should also be pretty easy to use.
16385 \end_layout
16386
16387 \begin_layout Standard
16388 These documents are supposed to be used in 
16389 \emph on
16390 addition
16391 \emph default
16392  to the Rev\SpecialChar TeX
16393  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
16394  macros,
16395  and assume you'll know what to put in the preamble if necessary.
16396 \end_layout
16397
16398 \begin_layout Subsection
16399 Installation
16400 \end_layout
16401
16402 \begin_layout Standard
16403 All you need to do is install Rev\SpecialChar TeX
16404  4, as described in the package's README
16405  file.
16406  The package can be found at The Rev\SpecialChar TeX
16407  4 Web Site 
16408 \begin_inset Flex URL
16409 status collapsed
16410
16411 \begin_layout Plain Layout
16412
16413 http://publish.aps.org/revtex4/
16414 \end_layout
16415
16416 \end_inset
16417
16418 .
16419  Install it somewhere that \SpecialChar LaTeX
16420  can see it.
16421  Test it by trying to \SpecialChar LaTeX
16422  a short Rev\SpecialChar TeX
16423  4 document in some random directory (i.
16424 \begin_inset space \thinspace{}
16425 \end_inset
16426
16427 e.
16428 \begin_inset space \space{}
16429 \end_inset
16430
16431 not the directory where you installed the class file.) Then, if you reconfigure
16432  \SpecialChar LyX
16433 , it will find the class file and let you use the Rev\SpecialChar TeX
16434 4 textclass.
16435 \end_layout
16436
16437 \begin_layout Standard
16438 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
16439  4 document
16440  using 
16441 \family typewriter
16442 tex2lyx
16443 \family default
16444 , or to use the 
16445 \family sans
16446 Revtex
16447 \begin_inset space ~
16448 \end_inset
16449
16450 4
16451 \family default
16452  template, found in the templates directory.
16453 \end_layout
16454
16455 \begin_layout Subsection
16456 Preamble Matter
16457 \end_layout
16458
16459 \begin_layout Standard
16460 Optional arguments to 
16461 \family typewriter
16462
16463 \backslash
16464 documentclass
16465 \family default
16466 , like 
16467 \begin_inset Quotes eld
16468 \end_inset
16469
16470 preprint
16471 \begin_inset Quotes erd
16472 \end_inset
16473
16474  and 
16475 \begin_inset Quotes eld
16476 \end_inset
16477
16478 aps
16479 \begin_inset Quotes erd
16480 \end_inset
16481
16482 , go in the 
16483 \family sans
16484 Extra
16485 \begin_inset space ~
16486 \end_inset
16487
16488 Options
16489 \family default
16490  field in the 
16491 \family sans
16492 Document
16493 \begin_inset space ~
16494 \end_inset
16495
16496 Layout
16497 \family default
16498  dialog, as usual.
16499  Remember that in Rev\SpecialChar TeX
16500 , at least one optional argument is required! 
16501 \end_layout
16502
16503 \begin_layout Standard
16504 Other preamble matter, like 
16505 \family typewriter
16506
16507 \backslash
16508 draft
16509 \family default
16510  etc.
16511 \begin_inset space ~
16512 \end_inset
16513
16514 goes in the 
16515 \family sans
16516 \SpecialChar LaTeX
16517
16518 \begin_inset space ~
16519 \end_inset
16520
16521 Preamble
16522 \family default
16523  dialog, also as usual.
16524 \end_layout
16525
16526 \begin_layout Subsection
16527 Layouts
16528 \end_layout
16529
16530 \begin_layout Standard
16531 The layouts basically correspond to the commands in Rev\SpecialChar TeX
16532 4.0.
16533  For example, the Email layout corresponds to 
16534 \family typewriter
16535
16536 \backslash
16537 email{}
16538 \family default
16539 .
16540  Note that (at least as of Rev\SpecialChar TeX
16541  4.0 Beta), the 
16542 \family sans
16543 Address
16544 \family default
16545  and 
16546 \family sans
16547 Affiliation
16548 \family default
16549  layouts are exactly equivalent, so you shouldn't need to use both.
16550 \begin_inset Foot
16551 status collapsed
16552
16553 \begin_layout Plain Layout
16554 In case you're curious, both were included so that 
16555 \family typewriter
16556 tex2lyx
16557 \family default
16558  would be able to translate both 
16559 \family typewriter
16560
16561 \backslash
16562 address
16563 \family default
16564  and 
16565 \family typewriter
16566
16567 \backslash
16568 affiliation
16569 \family default
16570 .
16571 \end_layout
16572
16573 \end_inset
16574
16575
16576 \end_layout
16577
16578 \begin_layout Subsection
16579 Important Notes
16580 \end_layout
16581
16582 \begin_layout Standard
16583 There are a couple of important unique aspects of Rev\SpecialChar TeX
16584  4 which might cause
16585  bugs that will be even more confusing in \SpecialChar LyX
16586 .
16587 \end_layout
16588
16589 \begin_layout Standard
16590 In Rev\SpecialChar TeX
16591 , the 
16592 \family typewriter
16593
16594 \backslash
16595 thanks
16596 \family default
16597  command goes 
16598 \emph on
16599 outside
16600 \emph default
16601  the 
16602 \family typewriter
16603
16604 \backslash
16605 author
16606 \family default
16607  command.
16608  The \SpecialChar LyX
16609  equivalent is that there is a separate Thanks layout.
16610  Do 
16611 \emph on
16612 not
16613 \emph default
16614  write footnotes in the 
16615 \family sans
16616 Author
16617 \family default
16618  layout, or weird things may happen.
16619  See the Rev\SpecialChar TeX
16620  4 documentation for more details.
16621 \end_layout
16622
16623 \begin_layout Standard
16624 Also, the 
16625 \family sans
16626 Author
16627 \begin_inset space ~
16628 \end_inset
16629
16630 Email
16631 \family default
16632
16633 \family sans
16634 Author
16635 \begin_inset space ~
16636 \end_inset
16637
16638 URL
16639 \family default
16640 , and 
16641 \family sans
16642 Thanks
16643 \family default
16644  layouts must be placed 
16645 \emph on
16646 in between
16647 \emph default
16648  the 
16649 \family sans
16650 Author
16651 \family default
16652  layout and the corresponding 
16653 \family sans
16654 Address
16655 \family default
16656  (or equivalent 
16657 \family sans
16658 Affiliation
16659 \family default
16660 ) layout.
16661  If you put the 
16662 \family sans
16663 Thanks
16664 \family default
16665  after the 
16666 \family sans
16667 Address
16668 \family default
16669 , the \SpecialChar LaTeX
16670  won't compile.
16671 \end_layout
16672
16673 \begin_layout Subsection
16674 Drawbacks
16675 \end_layout
16676
16677 \begin_layout Standard
16678 The main problem with this layout is that you can't use the optional arguments
16679  to layouts like Email and Title.
16680  (The problem is not unique to this layout; you can't use optional arguments
16681  to the Section layouts either.) This means that after you export that file
16682  to \SpecialChar LaTeX
16683  (which you'll need to do eventually to send it in to APS), you'll need
16684  to edit the \SpecialChar LaTeX
16685  file with a text editor to add the optional arguments to set,
16686  e.
16687 \begin_inset space \thinspace{}
16688 \end_inset
16689
16690 g.
16691 \begin_inset space \space{}
16692 \end_inset
16693
16694 the running title for the page headers.
16695  Lacking these layouts makes the 
16696 \family typewriter
16697
16698 \backslash
16699 altaffiliation
16700 \family default
16701  (and the equivalent 
16702 \family typewriter
16703
16704 \backslash
16705 altaddress
16706 \family default
16707 ) useless, so the corresponding layouts don't exist, and will have to be
16708  added by hand.
16709 \begin_inset Foot
16710 status collapsed
16711
16712 \begin_layout Plain Layout
16713
16714 \emph on
16715 Note from JMarc:
16716 \emph default
16717  actually, \SpecialChar LyX
16718  1.3.0 supports some forms of optional arguments, but this layout
16719  has not been updated yet to take advantage of it.
16720 \end_layout
16721
16722 \end_inset
16723
16724  
16725 \end_layout
16726
16727 \begin_layout Section
16728 Springer Journals (
16729 \family sans
16730 svjour
16731 \family default
16732 )
16733 \end_layout
16734
16735 \begin_layout Standard
16736 by 
16737 \noun on
16738 Martin Vermeer
16739 \end_layout
16740
16741 \begin_layout Subsection
16742 Description
16743 \end_layout
16744
16745 \begin_layout Standard
16746 These are the layout files for some of the journal formats used by Springer
16747  Verlag and listed on 
16748 \begin_inset Flex URL
16749 status collapsed
16750
16751 \begin_layout Plain Layout
16752
16753 http://www.springer.de/author/tex/help-journals.html
16754 \end_layout
16755
16756 \end_inset
16757
16758 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
16759  now!).
16760  It is a modular system: the things common to all journals are implemented
16761  in 
16762 \family typewriter
16763 svjour.inc
16764 \family default
16765 , which journal-specific layout files (such as, e.
16766 \begin_inset space \thinspace{}
16767 \end_inset
16768
16769 g.
16770 \begin_inset space \space{}
16771 \end_inset
16772
16773
16774 \family typewriter
16775 svjog.layout
16776 \family default
16777  for Journal of Geodesy) can include.
16778 \end_layout
16779
16780 \begin_layout Standard
16781 This means that implementing support for any other Springer journal on this
16782  list is as simple as writing your own 
16783 \family typewriter
16784 sv
16785 \family default
16786 <myjournal>
16787 \family typewriter
16788 .layout
16789 \family default
16790  file following the outline given in 
16791 \family typewriter
16792 svjog.layout
16793 \family default
16794 .
16795  
16796 \end_layout
16797
16798 \begin_layout Standard
16799 It is reasonably well tested only for the Journal of Geodesy.
16800  
16801 \family typewriter
16802 svjour
16803 \family default
16804  and 
16805 \family typewriter
16806 svjog
16807 \family default
16808  come with the standard \SpecialChar LyX
16809  distribution.
16810  Install the relevant class file (downloaded from Springer) in a proper
16811  directory, reconfigure \SpecialChar LaTeX
16812  (in the te\SpecialChar TeX
16813  case by running 
16814 \family typewriter
16815 texhash
16816 \family default
16817 , as root if necessary — doesn't \SpecialChar LyX
16818  take care of this?), reconfigure \SpecialChar LyX
16819  and
16820  it should work.
16821 \end_layout
16822
16823 \begin_layout Subsection
16824 New styles
16825 \end_layout
16826
16827 \begin_layout Standard
16828 A large number of theorem-like styles — 
16829 \family sans
16830 Claim, Conjecture,
16831 \family default
16832  
16833 \family sans
16834 \SpecialChar ldots
16835 Theorem
16836 \family default
16837 .
16838 \end_layout
16839
16840 \begin_layout Standard
16841
16842 \family sans
16843 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
16844 _Title, Author_Running, Institute,
16845  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
16846 \family default
16847 .
16848  See the Springer class file documentation for details.
16849 \end_layout
16850
16851 \begin_layout Subsection
16852 Supported journals
16853 \end_layout
16854
16855 \begin_layout Itemize
16856
16857 \emph on
16858 Journal of Geodesy
16859 \emph default
16860
16861 \family typewriter
16862 svjog.layout
16863 \family default
16864  — Martin Vermeer
16865 \end_layout
16866
16867 \begin_layout Itemize
16868
16869 \emph on
16870 Probability Theory and Related Fields
16871 \emph default
16872
16873 \family typewriter
16874 svprobth.layout
16875 \family default
16876  — Jean-Marc Lasgouttes
16877 \end_layout
16878
16879 \begin_layout Standard
16880 Add your own, it isn't so hard!
16881 \end_layout
16882
16883 \begin_layout Subsection
16884 Credits
16885 \end_layout
16886
16887 \begin_layout Standard
16888 These files are partly based on the older 
16889 \family typewriter
16890 ejour2.layout
16891 \family default
16892 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
16893  2.09 style
16894  file from Springer.
16895  All this, and the 
16896 \family typewriter
16897 ejour2
16898 \family default
16899  layout, are now defunct.
16900  Jean-Marc Lasgouttes helped out big in making me find my way around the
16901  \SpecialChar LyX
16902  layout file mechanism.
16903 \end_layout
16904
16905 \begin_layout Subsection
16906 Bugs
16907 \end_layout
16908
16909 \begin_layout Standard
16910 Probably.
16911  But probably less than in the old hacked-\SpecialChar LaTeX
16912  
16913 \family typewriter
16914 ejour2
16915 \family default
16916 .
16917 \end_layout
16918
16919 \begin_layout Standard
16920 Limitations e.
16921 \begin_inset space \thinspace{}
16922 \end_inset
16923
16924 g.: does not display the number for theorem-like layouts, just #.
16925 \end_layout
16926
16927 \begin_layout Section
16928 Slides [aka 
16929 \noun on
16930 Sli\SpecialChar TeX
16931
16932 \noun default
16933 ]
16934 \begin_inset CommandInset label
16935 LatexCommand label
16936 name "sec:slitex"
16937
16938 \end_inset
16939
16940
16941 \end_layout
16942
16943 \begin_layout Standard
16944 by 
16945 \noun on
16946 John Weiss
16947 \noun default
16948  
16949 \end_layout
16950
16951 \begin_layout Subsection
16952 Introduction
16953 \end_layout
16954
16955 \begin_layout Standard
16956 This section describes how to use \SpecialChar LyX
16957  to make slides for overhead projectors.
16958  There are two document classes that can do this: the default slides class
16959  and the 
16960 \family sans
16961 Foil\SpecialChar TeX
16962
16963 \family default
16964  slides class.
16965  This section documents the former.
16966 \end_layout
16967
16968 \begin_layout Standard
16969 I'm going to say this again, nice and clear, so that there's no misunderstanding
16970 :
16971 \end_layout
16972
16973 \begin_layout Standard
16974 \begin_inset VSpace bigskip
16975 \end_inset
16976
16977
16978 \end_layout
16979
16980 \begin_layout Standard
16981 \align center
16982
16983 \size large
16984 This section documents the class 
16985 \begin_inset Quotes eld
16986 \end_inset
16987
16988
16989 \family sans
16990 slides (default)
16991 \family default
16992
16993 \begin_inset Quotes erd
16994 \end_inset
16995
16996  
16997 \emph on
16998 only.
16999 \end_layout
17000
17001 \begin_layout Standard
17002 \begin_inset VSpace bigskip
17003 \end_inset
17004
17005
17006 \end_layout
17007
17008 \begin_layout Standard
17009 If you're looking for the documentation for 
17010 \begin_inset Quotes eld
17011 \end_inset
17012
17013
17014 \family sans
17015 slides (Foil\SpecialChar TeX
17016 )
17017 \family default
17018
17019 \begin_inset Quotes erd
17020 \end_inset
17021
17022 , check out section
17023 \begin_inset space ~
17024 \end_inset
17025
17026
17027 \begin_inset CommandInset ref
17028 LatexCommand ref
17029 reference "sec:foiltex"
17030
17031 \end_inset
17032
17033 .
17034  The 
17035 \family sans
17036 foils
17037 \family default
17038  class [
17039 \begin_inset Quotes eld
17040 \end_inset
17041
17042
17043 \family sans
17044 slides (Foil\SpecialChar TeX
17045 )
17046 \family default
17047
17048 \begin_inset Quotes erd
17049 \end_inset
17050
17051 ] is actually somewhat better than the default 
17052 \family sans
17053 slides
17054 \family default
17055  class,
17056 \begin_inset Foot
17057 status collapsed
17058
17059 \begin_layout Plain Layout
17060 \SpecialChar ldots
17061 or so I've been told repeatedly by its advocates.
17062  Having never used it, I have no idea if this claim is true or not.
17063 \end_layout
17064
17065 \end_inset
17066
17067  which this section documents.
17068 \end_layout
17069
17070 \begin_layout Standard
17071 This class is the \SpecialChar LaTeX2e
17072  improvement of the old 
17073 \noun on
17074 Sli\SpecialChar TeX
17075
17076 \noun default
17077  package.
17078  Every \SpecialChar LaTeX2e
17079  distribution includes this class [which I'll just refer to as 
17080 \begin_inset Quotes eld
17081 \end_inset
17082
17083
17084 \family sans
17085 slides
17086 \family default
17087
17088 \begin_inset Quotes erd
17089 \end_inset
17090
17091  from now on], so you're bound to have it.
17092  As I noted earlier, there are other classes, such as 
17093 \family sans
17094 foils
17095 \family default
17096 , which also produce slides for overhead projectors and do a better job
17097  at it.
17098  However, there are some things which 
17099 \family sans
17100 slides
17101 \family default
17102  can do which the others can't, such as generate overlays.
17103  Read on to learn more!
17104 \end_layout
17105
17106 \begin_layout Subsection
17107 Getting Started
17108 \begin_inset CommandInset label
17109 LatexCommand label
17110 name "sec:slidesetup"
17111
17112 \end_inset
17113
17114
17115 \end_layout
17116
17117 \begin_layout Standard
17118 Obviously, to use this document class, you need to select 
17119 \begin_inset Quotes eld
17120 \end_inset
17121
17122
17123 \family sans
17124 slides (default)
17125 \family default
17126
17127 \begin_inset Quotes erd
17128 \end_inset
17129
17130  from the class list in the 
17131 \family sans
17132 Document\SpecialChar menuseparator
17133 Settings
17134 \family default
17135  dialog.
17136  There are some other special things you should know about this class:
17137 \end_layout
17138
17139 \begin_layout Itemize
17140 Don't bother changing the options 
17141 \family sans
17142 Sides and Columns
17143 \family default
17144 .
17145  They're not supported by the 
17146 \family sans
17147 slides
17148 \family default
17149  class, anyways.
17150 \end_layout
17151
17152 \begin_layout Itemize
17153 The option 
17154 \family sans
17155 Page
17156 \begin_inset space ~
17157 \end_inset
17158
17159 style
17160 \family default
17161  behaves a bit differently for this class.
17162  The possible choices and what they do are as follows:
17163 \end_layout
17164
17165 \begin_deeper
17166 \begin_layout Description
17167
17168 \family sans
17169 plain
17170 \family default
17171  The final output contains page numbers in the lower right corner.
17172 \end_layout
17173
17174 \begin_layout Description
17175
17176 \family sans
17177 headings
17178 \family default
17179  Like 
17180 \family sans
17181 plain
17182 \family default
17183 , but also prints out any time markers you've put in.
17184  This is the default.
17185 \end_layout
17186
17187 \begin_layout Description
17188
17189 \family sans
17190 empty
17191 \family default
17192  The final output contains no page numbers, time markers, or alignment markers.
17193 \end_layout
17194
17195 \end_deeper
17196 \begin_layout Itemize
17197 The 
17198 \family sans
17199 slides
17200 \family default
17201  class has an extra option: 
17202 \family typewriter
17203 clock
17204 \family default
17205 .
17206  To use it, put 
17207 \begin_inset Quotes eld
17208 \end_inset
17209
17210
17211 \family typewriter
17212 clock
17213 \family default
17214
17215 \begin_inset Quotes erd
17216 \end_inset
17217
17218  in the extra class options.
17219 \end_layout
17220
17221 \begin_deeper
17222 \begin_layout Standard
17223 Using this options allows you to add time markers to 
17224 \family sans
17225 Note
17226 \family default
17227 s.
17228  See section
17229 \begin_inset space ~
17230 \end_inset
17231
17232
17233 \begin_inset CommandInset ref
17234 LatexCommand ref
17235 reference "sec:slideNote"
17236
17237 \end_inset
17238
17239  for more details.
17240 \end_layout
17241
17242 \end_deeper
17243 \begin_layout Standard
17244 You can also use the template file 
17245 \begin_inset Quotes eld
17246 \end_inset
17247
17248
17249 \family typewriter
17250 slides.lyx
17251 \family default
17252
17253 \begin_inset Quotes erd
17254 \end_inset
17255
17256  to automatically set up a document to use the 
17257 \family sans
17258 slides
17259 \family default
17260  class [using 
17261 \family sans
17262 File\SpecialChar menuseparator
17263 New
17264 \begin_inset space ~
17265 \end_inset
17266
17267 from
17268 \begin_inset space ~
17269 \end_inset
17270
17271 Template
17272 \family default
17273  to open your new document].
17274  The template file also contains some examples of the special paragraph
17275  environments used by this class.
17276  I'll describe those next.
17277 \end_layout
17278
17279 \begin_layout Subsection
17280 Paragraph Environments
17281 \end_layout
17282
17283 \begin_layout Subsubsection
17284 Supported Environments
17285 \end_layout
17286
17287 \begin_layout Standard
17288 The first thing you'll notice when you start up a new 
17289 \family sans
17290 slides
17291 \family default
17292  document is the font size and type: it's the equivalent of the size 
17293 \begin_inset Quotes eld
17294 \end_inset
17295
17296
17297 \family sans
17298 Largest
17299 \family default
17300
17301 \begin_inset Quotes erd
17302 \end_inset
17303
17304  in the 
17305 \family sans
17306 Sans
17307 \begin_inset space ~
17308 \end_inset
17309
17310 Serif
17311 \family default
17312  font.
17313  This is also what's used in the output.
17314  Think of this as a 
17315 \begin_inset Quotes eld
17316 \end_inset
17317
17318 visual cue
17319 \begin_inset Quotes erd
17320 \end_inset
17321
17322  to remind you that this is a slide.
17323  Your final slides will use a larger font; ergo, you'll have less space.
17324  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
17325 \end_layout
17326
17327 \begin_layout Standard
17328 The next thing that becomes obvious is the changes to the paragraph environment
17329  pull-down box [at the far-left end of the toolbar].
17330  Most of the paragraph environments you're used to seeing are missing.
17331  There are also five new ones.
17332  That's because the 
17333 \family sans
17334 slides
17335 \family default
17336  class itself only supports certain paragraph environments:
17337 \end_layout
17338
17339 \begin_layout Itemize
17340
17341 \family sans
17342 Standard
17343 \end_layout
17344
17345 \begin_layout Itemize
17346
17347 \family sans
17348 Itemize
17349 \end_layout
17350
17351 \begin_layout Itemize
17352
17353 \family sans
17354 Enumerate
17355 \end_layout
17356
17357 \begin_layout Itemize
17358
17359 \family sans
17360 Description
17361 \end_layout
17362
17363 \begin_layout Itemize
17364
17365 \family sans
17366 List
17367 \end_layout
17368
17369 \begin_layout Itemize
17370
17371 \family sans
17372 Quotation
17373 \end_layout
17374
17375 \begin_layout Itemize
17376
17377 \family sans
17378 Quote
17379 \end_layout
17380
17381 \begin_layout Itemize
17382
17383 \family sans
17384 Verse
17385 \end_layout
17386
17387 \begin_layout Itemize
17388
17389 \family sans
17390 Caption
17391 \end_layout
17392
17393 \begin_layout Itemize
17394
17395 \family sans
17396 \SpecialChar LyX
17397 -Code
17398 \end_layout
17399
17400 \begin_layout Itemize
17401
17402 \family sans
17403 Comment
17404 \end_layout
17405
17406 \begin_layout Standard
17407 All of the other standard environments, including the section-heading environmen
17408 ts, aren't used in the 
17409 \family sans
17410 slides
17411 \family default
17412  class.
17413 \end_layout
17414
17415 \begin_layout Standard
17416 On the other hand, you'll notice the following new environments:
17417 \end_layout
17418
17419 \begin_layout Itemize
17420
17421 \family sans
17422 Slide
17423 \end_layout
17424
17425 \begin_layout Itemize
17426
17427 \family sans
17428 Overlay
17429 \end_layout
17430
17431 \begin_layout Itemize
17432
17433 \family sans
17434 Note
17435 \end_layout
17436
17437 \begin_layout Itemize
17438
17439 \family sans
17440 InvisibleText
17441 \end_layout
17442
17443 \begin_layout Itemize
17444
17445 \family sans
17446 VisibleText
17447 \end_layout
17448
17449 \begin_layout Standard
17450 These five are kind of quirky, due to a 
17451 \begin_inset Quotes eld
17452 \end_inset
17453
17454 feature
17455 \begin_inset Quotes erd
17456 \end_inset
17457
17458  in \SpecialChar LyX
17459 .
17460  You see, \SpecialChar LyX
17461  doesn't permit you to nest any other paragraph environment into
17462  an empty environment.
17463  Now, that's fine and dandy, but it means that you wouldn't be able to start
17464  a slide with anything except plain text.
17465  To deal with this, I've performed a little 
17466 \begin_inset Quotes eld
17467 \end_inset
17468
17469 \SpecialChar LaTeX
17470  magic.
17471 \begin_inset Quotes erd
17472 \end_inset
17473
17474  
17475 \end_layout
17476
17477 \begin_layout Subsubsection
17478 Quirks of the New Environments
17479 \begin_inset CommandInset label
17480 LatexCommand label
17481 name "sec:slideQuirk"
17482
17483 \end_inset
17484
17485
17486 \end_layout
17487
17488 \begin_layout Standard
17489 All five of the new paragraph environments are somewhat quirky due to inherent
17490  limitiations in the current version of \SpecialChar LyX
17491 .
17492  As I just mentioned, \SpecialChar LyX
17493  forbids environments that begin with another environment.
17494  To get around this, the 
17495 \family sans
17496 Slide
17497 \family default
17498  environment isn't a paragraph environment as described in the 
17499 \emph on
17500 User's Guide
17501 \emph default
17502 .
17503  
17504 \end_layout
17505
17506 \begin_layout Standard
17507 You should consider 
17508 \family sans
17509 Slide
17510 \family default
17511
17512 \family sans
17513 Overlay
17514 \family default
17515 , and 
17516 \family sans
17517 Note
17518 \family default
17519  to be 
17520 \begin_inset Quotes eld
17521 \end_inset
17522
17523 pseudo-environments.
17524 \begin_inset Quotes erd
17525 \end_inset
17526
17527  They look like a section heading or a 
17528 \begin_inset Quotes eld
17529 \end_inset
17530
17531
17532 \family sans
17533 Caption
17534 \family default
17535 ,
17536 \begin_inset Quotes erd
17537 \end_inset
17538
17539  but really begin a [and, if necessary, end the previous] paragraph environment.
17540  Likewise, treat 
17541 \family sans
17542 InvisibleText
17543 \family default
17544  and 
17545 \family sans
17546 VisibleText
17547 \family default
17548  as 
17549 \begin_inset Quotes eld
17550 \end_inset
17551
17552 pseudo-commands.
17553 \begin_inset Quotes erd
17554 \end_inset
17555
17556  These two perform some action.
17557 \end_layout
17558
17559 \begin_layout Standard
17560 A common feature of all five environments, 
17561 \family sans
17562 Slide
17563 \family default
17564
17565 \family sans
17566 Overlay
17567 \family default
17568
17569 \family sans
17570 Note
17571 \family default
17572
17573 \family sans
17574 InvisibleText
17575 \family default
17576  and 
17577 \family sans
17578 VisibleText
17579 \family default
17580 , is a rather long-ish label.
17581  The text following this label — ordinarily the contents of the paragraph
17582  environment — is utterly irrelevant for 
17583 \family sans
17584 Slide
17585 \family default
17586
17587 \family sans
17588 Overlay
17589 \family default
17590
17591 \family sans
17592 Note
17593 \family default
17594
17595 \family sans
17596 InvisibleText
17597 \family default
17598  and 
17599 \family sans
17600 VisibleText
17601 \family default
17602 .
17603  \SpecialChar LyX
17604  completely ignores it.
17605  In fact, you can leave these five environments completely empty.
17606  
17607 \end_layout
17608
17609 \begin_layout Standard
17610 While you don't 
17611 \emph on
17612 have
17613 \emph default
17614  to put any text after the rather long-ish label, you might want to.
17615  This could be a short description of the contents of the 
17616 \family sans
17617 Slide
17618 \family default
17619 , for example.
17620  In that case, enter your descriptive comment and hit 
17621 \family sans
17622 Return
17623 \family default
17624  as you normally would.
17625 \end_layout
17626
17627 \begin_layout Standard
17628 If, on the other hand, you don't want to enter any descriptive text, you'll
17629  hit another \SpecialChar LyX
17630  quirk.
17631  \SpecialChar LyX
17632 , like nature, abhors a vacuum, and will not let you start a new paragraph
17633  environment until you put something in the old one.
17634  So, do this:
17635 \end_layout
17636
17637 \begin_layout Itemize
17638 Start entering the text that will 
17639 \emph on
17640 follow
17641 \emph default
17642  the new 
17643 \family sans
17644 Slide
17645 \family default
17646
17647 \family sans
17648 Overlay
17649 \family default
17650
17651 \family sans
17652 Note
17653 \family default
17654
17655 \family sans
17656 InvisibleText
17657 \family default
17658  or 
17659 \family sans
17660 VisibleText
17661 \family default
17662 .
17663  
17664 \end_layout
17665
17666 \begin_layout Itemize
17667 Now move to the beginning of that paragraph.
17668  
17669 \end_layout
17670
17671 \begin_layout Itemize
17672 Next, hit 
17673 \family sans
17674 Return
17675 \family default
17676 .
17677  
17678 \end_layout
17679
17680 \begin_layout Itemize
17681 Finally, change this new, empty paragraph to a 
17682 \family sans
17683 Slide
17684 \family default
17685
17686 \family sans
17687 Overlay
17688 \family default
17689
17690 \family sans
17691 Note
17692 \family default
17693
17694 \family sans
17695 InvisibleText
17696 \family default
17697  or 
17698 \family sans
17699 VisibleText
17700 \family default
17701 .
17702  
17703 \end_layout
17704
17705 \begin_layout Standard
17706 Some future version of \SpecialChar LyX
17707  will, hopefully, resolve this quirkiness\SpecialChar ldots
17708
17709 \end_layout
17710
17711 \begin_layout Subsection
17712 Making a Presentation with 
17713 \family sans
17714 Slide
17715 \family default
17716
17717 \family sans
17718 Overlay
17719 \family default
17720  and 
17721 \family sans
17722 Note
17723 \end_layout
17724
17725 \begin_layout Subsubsection
17726 Using the 
17727 \family sans
17728 Slide
17729 \family default
17730  Environment
17731 \end_layout
17732
17733 \begin_layout Standard
17734 If you're expecting this section to teach you how to actually make a presentatio
17735 n, you'll be sorely disappointed.
17736  Naturally, I'll describe all of the ways the 
17737 \family sans
17738 slides
17739 \family default
17740  class can assist you in preparing the materials for a presentation.
17741  Filling in the contents, however, is up to you.
17742  [Then again, that 
17743 \emph on
17744 is
17745 \emph default
17746  the \SpecialChar LyX
17747  philosophy.]
17748 \end_layout
17749
17750 \begin_layout Standard
17751 Choosing the 
17752 \family sans
17753 Slide
17754 \family default
17755  environment [in the manner described in section
17756 \begin_inset space ~
17757 \end_inset
17758
17759
17760 \begin_inset CommandInset ref
17761 LatexCommand ref
17762 reference "sec:slideQuirk"
17763
17764 \end_inset
17765
17766 ] tells \SpecialChar LyX
17767  to begin a new slide [duh].
17768  The label for this environment/
17769 \begin_inset Quotes erd
17770 \end_inset
17771
17772 pseudo-command
17773 \begin_inset Quotes erd
17774 \end_inset
17775
17776  is an 
17777 \begin_inset Quotes eld
17778 \end_inset
17779
17780 ASCII line,
17781 \begin_inset Quotes erd
17782 \end_inset
17783
17784  in cool blue, followed by the label, 
17785 \begin_inset Quotes eld
17786 \end_inset
17787
17788 NewSlide:
17789 \begin_inset Quotes erd
17790 \end_inset
17791
17792 .
17793  Any text or paragraph environments that follow this one go on the new slide.
17794  It's that simple.
17795 \end_layout
17796
17797 \begin_layout Standard
17798 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
17799
17800  (this can be specified in the 
17801 \family sans
17802 Paragraph Layout
17803 \family default
17804  dialog).
17805  In fact, you'll want to, once you finish entering the contents of one slide.
17806  If you've entered more text than can physically fit on a slide, the extra
17807  overflows onto a new slide.
17808  I don't recommend doing this, however, since the overflow slide won't have
17809  any page number on it.
17810  Furthermore, it may interfere with any 
17811 \family sans
17812 Overlay
17813 \family default
17814  you've made to accompany the oversized 
17815 \family sans
17816 Slide
17817 \family default
17818 .
17819 \end_layout
17820
17821 \begin_layout Standard
17822 The 
17823 \family sans
17824 Overlay
17825 \family default
17826  and 
17827 \family sans
17828 Note
17829 \family default
17830  environments work the same way as the 
17831 \family sans
17832 Slide
17833 \family default
17834  environment.
17835  They both create an 
17836 \begin_inset Quotes eld
17837 \end_inset
17838
17839 ASCII line
17840 \begin_inset Quotes erd
17841 \end_inset
17842
17843  followed by a label [
17844 \begin_inset Quotes eld
17845 \end_inset
17846
17847 NewOverlay:
17848 \begin_inset Quotes erd
17849 \end_inset
17850
17851  and 
17852 \begin_inset Quotes eld
17853 \end_inset
17854
17855 NewNote:
17856 \begin_inset Quotes erd
17857 \end_inset
17858
17859 , respectively].
17860  The color is a stunning magenta instead of blue, and the 
17861 \begin_inset Quotes eld
17862 \end_inset
17863
17864 ASCII line
17865 \begin_inset Quotes erd
17866 \end_inset
17867
17868  will look different, in style and in length.
17869  The label fonts of all three also differ from one another.
17870 \end_layout
17871
17872 \begin_layout Standard
17873 As with a 
17874 \family sans
17875 Slide
17876 \family default
17877 , if the contents of a 
17878 \family sans
17879 Note
17880 \family default
17881  or 
17882 \family sans
17883 Overlay
17884 \family default
17885  exceed the physical size of a slide or sheet of paper, the extra will overflow
17886  onto a new sheet.
17887  Again, you should avoid this.
17888  It defeats the whole purpose of 
17889 \family sans
17890 Note
17891 \family default
17892 s and 
17893 \family sans
17894 Overlay
17895 \family default
17896 s.
17897 \end_layout
17898
17899 \begin_layout Subsubsection
17900 Using 
17901 \family sans
17902 Overlay
17903 \family default
17904  with 
17905 \family sans
17906 Slide
17907 \end_layout
17908
17909 \begin_layout Standard
17910 The idea behind an 
17911 \family sans
17912 Overlay
17913 \family default
17914  is a slide that sits atop another slide.
17915  Perhaps you wish to discuss a figure on the main 
17916 \family sans
17917 Slide
17918 \family default
17919  before displaying the text associated with it.
17920  One way to accomplish this is tape a flap of dark paper over the part of
17921  the 
17922 \family sans
17923 Slide
17924 \family default
17925  you want to display later.
17926  This method fails, however, if you wish to overlap one graph with another,
17927  for example.
17928  You would then have to fumble while speaking to align the two separate,
17929  overlapping 
17930 \family sans
17931 Slide
17932 \family default
17933 s to align the two graphs.
17934  The use of an 
17935 \family sans
17936 Overlay
17937 \family default
17938  environment in both cases makes life much easier.
17939 \end_layout
17940
17941 \begin_layout Standard
17942 Each 
17943 \family sans
17944 Overlay
17945 \family default
17946  receives the page number of its 
17947 \begin_inset Quotes eld
17948 \end_inset
17949
17950 parent
17951 \begin_inset Quotes erd
17952 \end_inset
17953
17954  
17955 \family sans
17956 Slide
17957 \family default
17958 , appended by 
17959 \begin_inset Quotes eld
17960 \end_inset
17961
17962
17963 \family typewriter
17964 -a
17965 \family default
17966
17967 \begin_inset Quotes erd
17968 \end_inset
17969
17970 .
17971 \begin_inset Foot
17972 status collapsed
17973
17974 \begin_layout Plain Layout
17975 Presumably, mutliple 
17976 \family sans
17977 Overlay
17978 \family default
17979 s would have 
17980 \begin_inset Quotes eld
17981 \end_inset
17982
17983
17984 \family typewriter
17985 -a
17986 \family default
17987
17988 \begin_inset Quotes erd
17989 \end_inset
17990
17991
17992 \begin_inset Quotes eld
17993 \end_inset
17994
17995
17996 \family typewriter
17997 -b
17998 \family default
17999
18000 \begin_inset Quotes erd
18001 \end_inset
18002
18003
18004 \begin_inset Quotes eld
18005 \end_inset
18006
18007
18008 \family typewriter
18009 -c
18010 \family default
18011
18012 \begin_inset Quotes erd
18013 \end_inset
18014
18015 , etc.
18016 \begin_inset space ~
18017 \end_inset
18018
18019 appended to the page number of the parent 
18020 \family sans
18021 Slide
18022 \family default
18023 .
18024  
18025 \end_layout
18026
18027 \end_inset
18028
18029  Clearly, you want the contents of both the 
18030 \family sans
18031 Slide
18032 \family default
18033  and the 
18034 \family sans
18035 Overlay
18036 \family default
18037  to each fit on a single physical slide! You should probably consider an
18038  
18039 \family sans
18040 Overlay
18041 \family default
18042  as 
18043 \begin_inset Quotes eld
18044 \end_inset
18045
18046 part of
18047 \begin_inset Quotes erd
18048 \end_inset
18049
18050  a 
18051 \family sans
18052 Slide
18053 \family default
18054 .
18055  Indeed, the \SpecialChar LyX
18056  
18057 \family sans
18058 slides
18059 \family default
18060  class provides a visual cue for this: the label at the start of an 
18061 \family sans
18062 Overlay
18063 \family default
18064  is shorter than that at the start of a 
18065 \family sans
18066 Slide
18067 \family default
18068 .
18069  Lastly, when you generate printable output, you'll find alignment markers
18070  in all four corners of both the 
18071 \family sans
18072 Overlay
18073 \family default
18074  page and its parent 
18075 \family sans
18076 Slide
18077 \family default
18078 .
18079  These will assist you in lining up the two physical slides.
18080 \end_layout
18081
18082 \begin_layout Standard
18083 The major problem in overlaying two slides is aligning the contents of the
18084  two transparencies.
18085  How much space should you leave for that graph on the second slide? Worse
18086  still, what if you want a graph and a sentence on second slide, but there
18087  is text on the main transparency that goes in between them? You could try
18088  and insert vertical space of the right size.
18089  The better way is to use 
18090 \family sans
18091 InvisibleText
18092 \family default
18093  and 
18094 \family sans
18095 VisibleText
18096 \family default
18097 .
18098 \end_layout
18099
18100 \begin_layout Standard
18101 As their names imply, 
18102 \family sans
18103 InvisibleText
18104 \family default
18105  and 
18106 \family sans
18107 VisibleText
18108 \family default
18109  are two command-like paragraph environments that make all subsequent text
18110  invisible and visible, respectively.
18111  Note from section
18112 \begin_inset space ~
18113 \end_inset
18114
18115
18116 \begin_inset CommandInset ref
18117 LatexCommand ref
18118 reference "sec:slideQuirk"
18119
18120 \end_inset
18121
18122  that you don't place anything 
18123 \emph on
18124 into
18125 \emph default
18126  these two environments, however.
18127  When you create an 
18128 \family sans
18129 InvisibleText
18130 \family default
18131 , it inserts a centered, sky-blue label into the page reading 
18132 \begin_inset Quotes eld
18133 \end_inset
18134
18135 <Invisible Text Follows>
18136 \begin_inset Quotes erd
18137 \end_inset
18138
18139 .
18140  For paragraphs following this label, the parts of the 
18141 \family sans
18142 Slide
18143 \family default
18144  [or 
18145 \family sans
18146 Overlay
18147 \family default
18148 ; it doesn't matter which] where they would be contain instead blank space.
18149  
18150 \end_layout
18151
18152 \begin_layout Standard
18153 For 
18154 \family sans
18155 VisibleText
18156 \family default
18157 , the corresponding centered label is 
18158 \begin_inset Quotes eld
18159 \end_inset
18160
18161 <Visible Text Follows>
18162 \begin_inset Quotes erd
18163 \end_inset
18164
18165  in blazing green.
18166  Paragraphs following this label behave normally.
18167  Note that the beginning of a new 
18168 \family sans
18169 Slide
18170 \family default
18171
18172 \family sans
18173 Overlay
18174 \family default
18175 , or 
18176 \family sans
18177 Note
18178 \family default
18179  automatically shuts off an 
18180 \family sans
18181 InvisibleText
18182 \family default
18183 .
18184  It's therefore not necessary to use 
18185 \family sans
18186 VisibleText
18187 \family default
18188  at the end of a 
18189 \family sans
18190 Slide
18191 \family default
18192 .
18193 \end_layout
18194
18195 \begin_layout Standard
18196 By now, it should be obvious how to create overlay transparencies using
18197  the proper combination of 
18198 \family sans
18199 InvisibleText
18200 \family default
18201  and 
18202 \family sans
18203 VisibleText
18204 \family default
18205  on a 
18206 \family sans
18207 Slide
18208 \family default
18209  and 
18210 \family sans
18211 Overlay
18212 \family default
18213 :
18214 \end_layout
18215
18216 \begin_layout Enumerate
18217 Create a 
18218 \family sans
18219 Slide
18220 \family default
18221 , including everything that will appear on it, whether on the main slide
18222  or on the 
18223 \family sans
18224 Overlay
18225 \family default
18226 .
18227 \end_layout
18228
18229 \begin_layout Enumerate
18230 Before each figure or paragraph that will appear only on the 
18231 \family sans
18232 Overlay
18233 \family default
18234 , insert an 
18235 \family sans
18236 InvisibleText
18237 \family default
18238  environment.
18239  If necessary, insert a 
18240 \family sans
18241 VisibleText
18242 \family default
18243  environment after the 
18244 \family sans
18245 Overlay
18246 \family default
18247 -only text.
18248 \end_layout
18249
18250 \begin_layout Enumerate
18251 Start an 
18252 \family sans
18253 Overlay
18254 \family default
18255  immediately following the 
18256 \family sans
18257 Slide
18258 \family default
18259 .
18260 \end_layout
18261
18262 \begin_layout Enumerate
18263 Copy the contents of this 
18264 \family sans
18265 Slide
18266 \family default
18267  into the 
18268 \family sans
18269 Overlay
18270 \family default
18271 .
18272 \end_layout
18273
18274 \begin_layout Enumerate
18275 Within the 
18276 \family sans
18277 Overlay
18278 \family default
18279 , change all of the 
18280 \family sans
18281 InvisibleText
18282 \family default
18283  lines to 
18284 \family sans
18285 VisibleText
18286 \family default
18287  and vice-versa.
18288 \end_layout
18289
18290 \begin_layout Standard
18291 That's it.
18292  You've just made an 
18293 \family sans
18294 Overlay
18295 \family default
18296 .
18297 \end_layout
18298
18299 \begin_layout Standard
18300 There's one problem with the way I've designed the \SpecialChar LyX
18301  
18302 \family sans
18303 slides
18304 \family default
18305  class: you can't make text in the middle of a paragraph invisible, nor
18306  make text in the middle of an invisible paragraph visible again.
18307  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
18308  codes.
18309 \begin_inset Foot
18310 status collapsed
18311
18312 \begin_layout Plain Layout
18313 The commands of interest are: 
18314 \end_layout
18315
18316 \begin_layout Itemize
18317
18318 \family typewriter
18319 {
18320 \backslash
18321 invisible \SpecialChar ldots
18322  }
18323 \end_layout
18324
18325 \begin_layout Itemize
18326
18327 \family typewriter
18328 {
18329 \backslash
18330 visible \SpecialChar ldots
18331  }
18332 \end_layout
18333
18334 \begin_layout Plain Layout
18335 \SpecialChar ldots
18336 and need to be marked as \SpecialChar TeX
18337 .
18338  The text whose 
18339 \begin_inset Quotes eld
18340 \end_inset
18341
18342 visibility
18343 \begin_inset Quotes erd
18344 \end_inset
18345
18346  you wish to change goes in between the brackets [and after the 
18347 \family typewriter
18348
18349 \backslash
18350 invisible
18351 \family default
18352  or 
18353 \family typewriter
18354
18355 \backslash
18356 visible
18357 \family default
18358  command].
18359  If you don't know how to mark text as \SpecialChar TeX
18360 , see the appropriate section of
18361  the 
18362 \emph on
18363 User's Guide
18364 \emph default
18365 .
18366 \end_layout
18367
18368 \end_inset
18369
18370
18371 \end_layout
18372
18373 \begin_layout Subsubsection
18374 Using 
18375 \family sans
18376 Note
18377 \family default
18378  with 
18379 \family sans
18380 Slide
18381 \family default
18382
18383 \begin_inset CommandInset label
18384 LatexCommand label
18385 name "sec:slideNote"
18386
18387 \end_inset
18388
18389
18390 \end_layout
18391
18392 \begin_layout Standard
18393 Like an 
18394 \family sans
18395 Overlay
18396 \family default
18397 , a 
18398 \family sans
18399 Note
18400 \family default
18401  is associated with a 
18402 \begin_inset Quotes eld
18403 \end_inset
18404
18405 parent
18406 \begin_inset Quotes erd
18407 \end_inset
18408
18409  
18410 \family sans
18411 Slide
18412 \family default
18413 .
18414  Here, too, the \SpecialChar LyX
18415  
18416 \family sans
18417 slides
18418 \family default
18419  class provides visual cues.
18420  The label for a 
18421 \family sans
18422 Note
18423 \family default
18424  is shorter than that of a 
18425 \family sans
18426 Slide
18427 \family default
18428  [yet longer than that of an 
18429 \family sans
18430 Overlay
18431 \family default
18432 ] and, like the label of an 
18433 \family sans
18434 Overlay
18435 \family default
18436  is shockingly magenta.
18437  Additionally, the printed 
18438 \family sans
18439 Note
18440 \family default
18441  has the page number of its 
18442 \begin_inset Quotes eld
18443 \end_inset
18444
18445 parent
18446 \begin_inset Quotes erd
18447 \end_inset
18448
18449  
18450 \family sans
18451 Slide
18452 \family default
18453 , appended by 
18454 \begin_inset Quotes eld
18455 \end_inset
18456
18457
18458 \family typewriter
18459 -
18460 \family default
18461 1
18462 \begin_inset Quotes erd
18463 \end_inset
18464
18465
18466 \begin_inset Quotes eld
18467 \end_inset
18468
18469
18470 \family typewriter
18471 -
18472 \family default
18473 2
18474 \begin_inset Quotes erd
18475 \end_inset
18476
18477
18478 \begin_inset Quotes eld
18479 \end_inset
18480
18481
18482 \family typewriter
18483 -
18484 \family default
18485 3
18486 \begin_inset Quotes erd
18487 \end_inset
18488
18489 , etc.
18490  You can have multiple 
18491 \family sans
18492 Note
18493 \family default
18494 s associated with a single 
18495 \family sans
18496 Slide
18497 \family default
18498 , and, as with 
18499 \family sans
18500 Slide
18501 \family default
18502  and 
18503 \family sans
18504 Overlay
18505 \family default
18506 , you'll probably want to break up long 
18507 \family sans
18508 Note
18509 \family default
18510 s so that they fit on a single sheet of paper.
18511 \end_layout
18512
18513 \begin_layout Standard
18514 The purpose of a 
18515 \family sans
18516 Note
18517 \family default
18518  is obvious: it contains anything additional you might want to say about
18519  a 
18520 \family sans
18521 Slide
18522 \family default
18523 .
18524  It could also be used as a sheet of reminders for a particular 
18525 \family sans
18526 Slide
18527 \family default
18528 .
18529  In the case of the latter, you might want to make use of time markers.
18530  Currently, the \SpecialChar LyX
18531  
18532 \family sans
18533 slides
18534 \family default
18535  class has no 
18536 \begin_inset Quotes eld
18537 \end_inset
18538
18539 native
18540 \begin_inset Quotes erd
18541 \end_inset
18542
18543  support for time markers, a 
18544 \noun on
18545 Sli\SpecialChar TeX
18546
18547 \noun default
18548  feature.
18549  So, you'll have to resort to using the \SpecialChar LaTeX
18550  codes.
18551 \end_layout
18552
18553 \begin_layout Standard
18554 To use time markers, you'll need to specify the extra class option 
18555 \begin_inset Quotes eld
18556 \end_inset
18557
18558
18559 \family typewriter
18560 clock
18561 \family default
18562
18563 \begin_inset Quotes erd
18564 \end_inset
18565
18566  [see section
18567 \begin_inset space ~
18568 \end_inset
18569
18570
18571 \begin_inset CommandInset ref
18572 LatexCommand ref
18573 reference "sec:slidesetup"
18574
18575 \end_inset
18576
18577 ].
18578  This option turns on timing marks, which will appear in the lower-left-hand
18579  corner of every 
18580 \family sans
18581 Note
18582 \family default
18583  you generate.
18584  To set what appears in the time marker, you use the \SpecialChar LaTeX
18585  commands 
18586 \begin_inset Quotes eld
18587 \end_inset
18588
18589
18590 \family typewriter
18591
18592 \backslash
18593 settime{}
18594 \family default
18595
18596 \begin_inset Quotes erd
18597 \end_inset
18598
18599  and 
18600 \begin_inset Quotes eld
18601 \end_inset
18602
18603
18604 \family typewriter
18605
18606 \backslash
18607 addtime{}
18608 \family default
18609
18610 \begin_inset Quotes erd
18611 \end_inset
18612
18613 .
18614  The arguments of both commands are time measured in seconds.
18615  
18616 \begin_inset Quotes eld
18617 \end_inset
18618
18619
18620 \family typewriter
18621
18622 \backslash
18623 settime{}
18624 \family default
18625
18626 \begin_inset Quotes erd
18627 \end_inset
18628
18629  sets the time marker to a given time.
18630  
18631 \begin_inset Quotes eld
18632 \end_inset
18633
18634
18635 \family typewriter
18636
18637 \backslash
18638 addtime{}
18639 \family default
18640
18641 \begin_inset Quotes erd
18642 \end_inset
18643
18644  increments the time marker by the specified amount.
18645  Using time markers and 
18646 \family sans
18647 Note
18648 \family default
18649 s in this fashion, you can remind yourself how much time to spend on a particula
18650
18651 \family sans
18652 Slide
18653 \family default
18654 .
18655 \end_layout
18656
18657 \begin_layout Standard
18658 There's one last feature to describe.
18659  Clearly, you'd like to print out all of your 
18660 \family sans
18661 Slide
18662 \family default
18663 s and 
18664 \family sans
18665 Overlay
18666 \family default
18667 s on transparencies while printing all of your 
18668 \family sans
18669 Note
18670 \family default
18671 s on plain paper.
18672  However, a 
18673 \family sans
18674 Note
18675 \family default
18676  
18677 \emph on
18678 must
18679 \emph default
18680  follow the 
18681 \family sans
18682 Slide
18683 \family default
18684  with which it is associated.
18685  What's a person to do?
18686 \end_layout
18687
18688 \begin_layout Standard
18689 Luckily, there are two \SpecialChar LaTeX
18690  commands that allow you to select what to print
18691  out.
18692  Both must be placed into the preamble of your document.
18693  The command 
18694 \begin_inset Quotes eld
18695 \end_inset
18696
18697
18698 \family typewriter
18699
18700 \backslash
18701 onlyslides{
18702 \backslash
18703 slides}
18704 \family default
18705
18706 \begin_inset Quotes erd
18707 \end_inset
18708
18709  will cause the output to contain only the 
18710 \family sans
18711 Slide
18712 \family default
18713 s and 
18714 \family sans
18715 Overlay
18716 \family default
18717 s.
18718  Correspondingly, the command 
18719 \begin_inset Quotes eld
18720 \end_inset
18721
18722
18723 \family typewriter
18724
18725 \backslash
18726 onlynotes{
18727 \backslash
18728 notes}
18729 \family default
18730
18731 \begin_inset Quotes erd
18732 \end_inset
18733
18734  prevents the output of anything but 
18735 \family sans
18736 Note
18737 \family default
18738 s.
18739  I'd advise placing both commands in the preamble and initially comment
18740  both out.
18741  You can then preview your entire presentation as you write.
18742  When you're done writing, you can then uncomment one of the two to select
18743  what you want to print.
18744  I like to uncomment 
18745 \begin_inset Quotes eld
18746 \end_inset
18747
18748
18749 \family typewriter
18750
18751 \backslash
18752 onlyslides{
18753 \backslash
18754 slides}
18755 \family default
18756
18757 \begin_inset Quotes erd
18758 \end_inset
18759
18760  , print to a file with 
18761 \begin_inset Quotes eld
18762 \end_inset
18763
18764
18765 \family typewriter
18766 -slides
18767 \family default
18768
18769 \begin_inset Quotes erd
18770 \end_inset
18771
18772  in its name, comment it back out, then uncomment 
18773 \begin_inset Quotes eld
18774 \end_inset
18775
18776
18777 \family typewriter
18778
18779 \backslash
18780 onlynotes{
18781 \backslash
18782 notes}
18783 \family default
18784
18785 \begin_inset Quotes erd
18786 \end_inset
18787
18788  and print to a 
18789 \begin_inset Quotes eld
18790 \end_inset
18791
18792
18793 \family typewriter
18794 *-notes.ps
18795 \family default
18796
18797 \begin_inset Quotes erd
18798 \end_inset
18799
18800  file.
18801  I can then send either file to a printer, loading transparencies or plain
18802  paper as appropriate.
18803 \end_layout
18804
18805 \begin_layout Standard
18806 You can also provide other arguments to the 
18807 \begin_inset Quotes eld
18808 \end_inset
18809
18810
18811 \family typewriter
18812
18813 \backslash
18814 onlyslides{}
18815 \family default
18816
18817 \begin_inset Quotes erd
18818 \end_inset
18819
18820  and 
18821 \begin_inset Quotes eld
18822 \end_inset
18823
18824
18825 \family typewriter
18826
18827 \backslash
18828 onlynotes{}
18829 \family default
18830
18831 \begin_inset Quotes erd
18832 \end_inset
18833
18834  commands.
18835  See a good \SpecialChar LaTeX
18836  book for details.
18837 \end_layout
18838
18839 \begin_layout Subsection
18840 The 
18841 \family sans
18842 slides
18843 \family default
18844  Class Template File
18845 \end_layout
18846
18847 \begin_layout Standard
18848 I have also provided a template file, 
18849 \begin_inset Quotes eld
18850 \end_inset
18851
18852
18853 \family typewriter
18854 slides.lyx
18855 \family default
18856
18857 \begin_inset Quotes erd
18858 \end_inset
18859
18860 , with the 
18861 \family sans
18862 slides
18863 \family default
18864  class.
18865  To use it, begin your new presentation with 
18866 \family sans
18867 File\SpecialChar menuseparator
18868 New
18869 \begin_inset space ~
18870 \end_inset
18871
18872 from
18873 \begin_inset space ~
18874 \end_inset
18875
18876 Template
18877 \family default
18878 .
18879  Your new \SpecialChar LyX
18880  presentation file will contain an example 
18881 \family sans
18882 Slide
18883 \family default
18884  – 
18885 \family sans
18886 Overlay
18887 \family default
18888  – 
18889 \family sans
18890 Note
18891 \family default
18892  triplet.
18893  The 
18894 \family sans
18895 Slide
18896 \family default
18897  and 
18898 \family sans
18899 Overlay
18900 \family default
18901  additionally contain an example of the use of 
18902 \family sans
18903 InvisibleText
18904 \family default
18905  and 
18906 \family sans
18907 VisibleText
18908 \family default
18909 .
18910  Lastly, the preamble will contain:
18911 \end_layout
18912
18913 \begin_layout LyX-Code
18914 % Uncomment to print out only slides and overlays
18915 \end_layout
18916
18917 \begin_layout LyX-Code
18918 %
18919 \end_layout
18920
18921 \begin_layout LyX-Code
18922 %
18923 \backslash
18924 onlyslides{
18925 \backslash
18926 slides}
18927 \begin_inset Newline newline
18928 \end_inset
18929
18930  
18931 \end_layout
18932
18933 \begin_layout LyX-Code
18934 % Uncomment to print out only notes
18935 \end_layout
18936
18937 \begin_layout LyX-Code
18938 %
18939 \end_layout
18940
18941 \begin_layout LyX-Code
18942 %
18943 \backslash
18944 onlynotes{
18945 \backslash
18946 notes}
18947 \end_layout
18948
18949 \begin_layout Standard
18950 One final thing: I created this class to support the \SpecialChar LaTeX2e
18951  
18952 \begin_inset Quotes eld
18953 \end_inset
18954
18955
18956 \noun on
18957 Sli\SpecialChar TeX
18958
18959 \noun default
18960  emulation
18961 \begin_inset Quotes erd
18962 \end_inset
18963
18964  class, one of the built-in \SpecialChar LaTeX2e
18965  classes.
18966  Neither I nor the rest of the \SpecialChar LyX
18967  Team endorse or oppose the use of this built-in
18968  slide class.
18969  It's here if you want it or need it.
18970  There exist other \SpecialChar LaTeX2e
18971  classes for creating presentations, such as the 
18972 \family sans
18973 Foils
18974 \family default
18975  class [see section
18976 \begin_inset space ~
18977 \end_inset
18978
18979
18980 \begin_inset CommandInset ref
18981 LatexCommand ref
18982 reference "sec:foiltex"
18983
18984 \end_inset
18985
18986 ] or the 
18987 \begin_inset Quotes eld
18988 \end_inset
18989
18990
18991 \family typewriter
18992 seminar
18993 \family default
18994
18995 \begin_inset Quotes erd
18996 \end_inset
18997
18998  package [present on some \SpecialChar TeX
18999  distributions].
19000  The latter is not yet supported under \SpecialChar LyX
19001 .
19002 \begin_inset Foot
19003 status collapsed
19004
19005 \begin_layout Plain Layout
19006 Perhaps you can take on the task\SpecialChar ldots
19007
19008 \end_layout
19009
19010 \end_inset
19011
19012  I know nothing about these other classes.
19013  Try them out to see what sort of alternative they provide.
19014 \end_layout
19015
19016 \begin_layout Chapter
19017 \SpecialChar LyX
19018  Features needing Extra Software
19019 \end_layout
19020
19021 \begin_layout Section
19022 Checking \SpecialChar TeX
19023
19024 \end_layout
19025
19026 \begin_layout Standard
19027 by 
19028 \noun on
19029 Asger Alstrup
19030 \end_layout
19031
19032 \begin_layout Subsection
19033 Introduction
19034 \end_layout
19035
19036 \begin_layout Standard
19037 If you have the 
19038 \family typewriter
19039 chktex
19040 \family default
19041  program installed
19042 \begin_inset Foot
19043 status collapsed
19044
19045 \begin_layout Plain Layout
19046
19047 \family typewriter
19048 chktex
19049 \family default
19050  is not yet available when you are using the \SpecialChar LaTeX
19051  distribution MiK\SpecialChar TeX
19052 .
19053 \end_layout
19054
19055 \end_inset
19056
19057 , you'll find in the 
19058 \family sans
19059 Tools
19060 \family default
19061  menu the entry: 
19062 \family sans
19063 Check
19064 \begin_inset space ~
19065 \end_inset
19066
19067 TeX
19068 \family default
19069 .
19070  You can get 
19071 \family typewriter
19072 chktex
19073 \family default
19074  from CTAN,
19075 \begin_inset Newline newline
19076 \end_inset
19077
19078
19079 \begin_inset CommandInset href
19080 LatexCommand href
19081 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
19082 literal "false"
19083
19084 \end_inset
19085
19086 .
19087 \end_layout
19088
19089 \begin_layout Standard
19090 The 
19091 \family sans
19092 Chk\SpecialChar TeX
19093
19094 \family default
19095  package is a program that was written by 
19096 \begin_inset Flex Noun
19097 status collapsed
19098
19099 \begin_layout Plain Layout
19100 Jens T.
19101 \begin_inset space ~
19102 \end_inset
19103
19104 Berger Thielemann
19105 \end_layout
19106
19107 \end_inset
19108
19109  in frustration because some constructs in \SpecialChar LaTeX
19110  are sometimes non-intuitive,
19111  and easy to forget.
19112  The program runs over your \SpecialChar LaTeX
19113  file, checks the integrity of the file, and
19114  flags some common errors.
19115  In other technical words, it is 
19116 \family typewriter
19117 lint
19118 \family default
19119  for \SpecialChar LaTeX
19120 .
19121 \end_layout
19122
19123 \begin_layout Standard
19124 Well, what is a syntax checker doing in \SpecialChar LyX
19125  which is supposed to produce correct
19126  \SpecialChar LaTeX
19127  anyways? The answer is simple: Just as 
19128 \family typewriter
19129 Lint
19130 \family default
19131  not only checks the 
19132 \emph on
19133 syntax
19134 \emph default
19135  of C programs, but also does 
19136 \emph on
19137 semantic
19138 \emph default
19139  checks for type-errors, 
19140 \family sans
19141 Chk\SpecialChar TeX
19142
19143 \family default
19144  catches some common 
19145 \emph on
19146 typographic
19147 \emph default
19148  errors, in addition to the syntactical ones.
19149  Specifically, 
19150 \family sans
19151 Chk\SpecialChar TeX
19152
19153 \family default
19154  is capable of detecting several common errors, such as
19155 \end_layout
19156
19157 \begin_layout Itemize
19158 Ellipsis detection:
19159 \begin_inset Newline newline
19160 \end_inset
19161
19162 Use \SpecialChar ldots
19163  instead of ...
19164 \end_layout
19165
19166 \begin_layout Itemize
19167 No space in front of/after parenthesis:
19168 \begin_inset Newline newline
19169 \end_inset
19170
19171 ( wrong spacing )
19172 \end_layout
19173
19174 \begin_layout Itemize
19175 Enforcement of normal space after common abbreviations:
19176 \begin_inset Newline newline
19177 \end_inset
19178
19179 e.
19180 \begin_inset space \thinspace{}
19181 \end_inset
19182
19183 g.
19184 \begin_inset space \space{}
19185 \end_inset
19186
19187 is too wide spacing.
19188 \end_layout
19189
19190 \begin_layout Itemize
19191 Enforcement of end-of-sentence space when the last sentence ends with a
19192  capital letter:
19193 \begin_inset Newline newline
19194 \end_inset
19195
19196 This is a TEST.
19197  And this is wrong spacing.
19198 \end_layout
19199
19200 \begin_layout Itemize
19201 Space in front of labels and similar commands:
19202 \begin_inset Newline newline
19203 \end_inset
19204
19205 The label should stick right up to the text to avoid falling to a wrong
19206  page.
19207  
19208 \begin_inset CommandInset label
19209 LatexCommand label
19210 name "sec:chktex"
19211
19212 \end_inset
19213
19214  
19215 \begin_inset Foot
19216 status collapsed
19217
19218 \begin_layout Plain Layout
19219 This footnote is in danger of falling off to a wrong page
19220 \end_layout
19221
19222 \end_inset
19223
19224  The label is separated too much.
19225 \end_layout
19226
19227 \begin_layout Itemize
19228 Space in front of references, instead of hard spaces:
19229 \begin_inset Newline newline
19230 \end_inset
19231
19232 If you have bad luck, the text will break right between the referenced text
19233  and reference number, and that's a pity.
19234  See section 
19235 \begin_inset CommandInset ref
19236 LatexCommand ref
19237 reference "sec:chktex"
19238
19239 \end_inset
19240
19241 .
19242 \end_layout
19243
19244 \begin_layout Itemize
19245 Use of 
19246 \begin_inset Quotes eld
19247 \end_inset
19248
19249 x
19250 \begin_inset Quotes erd
19251 \end_inset
19252
19253  instead of 
19254 \begin_inset Formula $\times$
19255 \end_inset
19256
19257  between numbers:
19258 \begin_inset Newline newline
19259 \end_inset
19260
19261 2x2 looks cheap compared to 
19262 \begin_inset Formula $2\times2$
19263 \end_inset
19264
19265 .
19266 \end_layout
19267
19268 \begin_layout Standard
19269 and more \SpecialChar ldots
19270  It is an invaluable tool when you are 
19271 \begin_inset Quotes eld
19272 \end_inset
19273
19274 finishing up
19275 \begin_inset Quotes erd
19276 \end_inset
19277
19278  your document before printing, and you should run it right after the obligatory
19279  spelling check, and before you go fine tuning the typesetting.
19280 \end_layout
19281
19282 \begin_layout Subsection
19283 How to use it
19284 \end_layout
19285
19286 \begin_layout Standard
19287 If you have the program installed, usage is as simple as choosing 
19288 \family sans
19289 Tools\SpecialChar menuseparator
19290 Check
19291 \begin_inset space ~
19292 \end_inset
19293
19294 TeX
19295 \family default
19296 .
19297  This will make \SpecialChar LyX
19298  generate a \SpecialChar LaTeX
19299  file of your document, start 
19300 \family sans
19301 Chk\SpecialChar TeX
19302
19303 \family default
19304  to check it, and then make \SpecialChar LyX
19305  insert 
19306 \begin_inset Quotes eld
19307 \end_inset
19308
19309 error boxes
19310 \begin_inset Quotes erd
19311 \end_inset
19312
19313  with the warnings from 
19314 \family sans
19315 Chk\SpecialChar TeX
19316
19317 \family default
19318 , if there were any.
19319  The warnings will be placed close to the point of the mistake, and you
19320  can quickly find them by using the 
19321 \family sans
19322 Navigate\SpecialChar menuseparator
19323 Error
19324 \family default
19325  menu item, or the shortcut key 
19326 \family sans
19327 C-g
19328 \family default
19329  from the default 
19330 \family typewriter
19331 cua
19332 \family default
19333  bind file.
19334  Open the error boxes by clicking on them with the mouse, or use the shortcut
19335  key 
19336 \family sans
19337 C-i
19338 \family default
19339  from 
19340 \family typewriter
19341 cua
19342 \family default
19343  bindings, or the corresponding 
19344 \family sans
19345 C-o
19346 \family default
19347  for the alternate 
19348 \family typewriter
19349 emacs
19350 \family default
19351  bind file.
19352  Read the warning and correct the mistake, if it is a mistake.
19353  If you have trouble understanding what the warning is about, you can safely
19354  ignore it.
19355  Remember that there is a hidden layer between the document on screen and
19356  the technical details in invoking 
19357 \family sans
19358 Chk\SpecialChar TeX
19359
19360 \family default
19361 , and this gap can make some warnings seem arcane or just plain silly.
19362 \end_layout
19363
19364 \begin_layout Standard
19365 This document is an excellent testing bed for the feature, and it should
19366  provide quite a few warnings for you to fiddle with.
19367  Since computers are only so smart, expect most of the warnings to be false
19368  alarms, though.
19369 \end_layout
19370
19371 \begin_layout Subsection
19372 How to fine tune it
19373 \end_layout
19374
19375 \begin_layout Standard
19376 Sometimes, you'll find that 
19377 \family sans
19378 Chk\SpecialChar TeX
19379
19380 \family default
19381  makes more noise than suits your mood.
19382  Then you can choose not to use it, wait until your mood changes, or try
19383  to customize 
19384 \family sans
19385 Chk\SpecialChar TeX
19386
19387 \family default
19388  to get better along with you.
19389 \end_layout
19390
19391 \begin_layout Standard
19392 Although 
19393 \family sans
19394 Chk\SpecialChar TeX
19395
19396 \family default
19397  
19398 \emph on
19399 is
19400 \emph default
19401  very configurable and extensible, you should not expect to solve all problems
19402  with 
19403 \family sans
19404 Chk\SpecialChar TeX
19405
19406 \family default
19407  in \SpecialChar LyX
19408  this way.
19409  Since \SpecialChar LyX
19410  has to generate a somewhat special \SpecialChar LaTeX
19411  file to be able to match the
19412  line numbers from the 
19413 \family sans
19414 Chk\SpecialChar TeX
19415
19416 \family default
19417  output
19418 \begin_inset Foot
19419 status collapsed
19420
19421 \begin_layout Plain Layout
19422 You can inspect the specific output from 
19423 \family sans
19424 chktex
19425 \family default
19426  by using 
19427 \family sans
19428 Document\SpecialChar menuseparator
19429 \SpecialChar LaTeX
19430
19431 \begin_inset space ~
19432 \end_inset
19433
19434 Log
19435 \family default
19436  right after a 
19437 \family sans
19438 chktex
19439 \family default
19440  run.
19441 \end_layout
19442
19443 \end_inset
19444
19445  to the internal document structure, some of the warnings will not appear
19446  correctly.
19447  There are two things you can do about this:
19448 \end_layout
19449
19450 \begin_layout Itemize
19451 Fine tune the 
19452 \family sans
19453 Chk\SpecialChar TeX
19454
19455 \family default
19456  invocation command line in 
19457 \begin_inset Flex Noun
19458 status collapsed
19459
19460 \begin_layout Plain Layout
19461 Tools\SpecialChar menuseparator
19462 Preferences\SpecialChar menuseparator
19463 Output\SpecialChar menuseparator
19464 LaTeX\SpecialChar menuseparator
19465 CheckTeX command
19466 \end_layout
19467
19468 \end_inset
19469
19470 , or the global 
19471 \family sans
19472 Chk\SpecialChar TeX
19473
19474 \family default
19475  installation configuration file (usually with the file 
19476 \family typewriter
19477 chktexrc
19478 \family default
19479 ).
19480  See below to learn what warnings can be enabled and disabled on the command
19481  line.
19482 \end_layout
19483
19484 \begin_layout Itemize
19485 Export your document as a raw \SpecialChar LaTeX
19486  file using 
19487 \family sans
19488 File\SpecialChar menuseparator
19489 Export\SpecialChar menuseparator
19490 \SpecialChar LaTeX
19491
19492 \family default
19493  and run 
19494 \family typewriter
19495 chktex
19496 \family default
19497  manually on that.
19498  Invoked in this way, it can be a hassle to find the corresponding place
19499  in the document inside \SpecialChar LyX
19500 , but with a little patience, you should be able
19501  to do it.
19502 \end_layout
19503
19504 \begin_layout Standard
19505 Here follows the warning messages that can be enabled and disabled in 
19506 \family sans
19507 Preferences
19508 \family default
19509 .
19510  Use 
19511 \family typewriter
19512 -n#
19513 \family default
19514  to disable a warning, and 
19515 \family typewriter
19516 -w#
19517 \family default
19518  to enable a warning.
19519  The emphasized entries are disabled by default, because the default is
19520  "
19521 \family typewriter
19522 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19523 \family default
19524 ".
19525 \end_layout
19526
19527 \begin_layout Standard
19528 Notice that you should only use the options that enable and disable warnings,
19529  because \SpecialChar LyX
19530  relies on some of the other command line parameters to be set
19531  in a specific way to have a chance to communicate with 
19532 \family typewriter
19533 chktex
19534 \family default
19535 .
19536 \end_layout
19537
19538 \begin_layout Enumerate
19539
19540 \size small
19541 \emph on
19542 Command terminated with space.
19543 \end_layout
19544
19545 \begin_layout Enumerate
19546
19547 \size small
19548 Non-breaking space (
19549 \begin_inset Quotes eld
19550 \end_inset
19551
19552
19553 \family typewriter
19554 ~
19555 \family default
19556
19557 \begin_inset Quotes erd
19558 \end_inset
19559
19560 ) should have been used.
19561 \end_layout
19562
19563 \begin_layout Enumerate
19564
19565 \size small
19566 \emph on
19567 You should enclose the previous parenthesis with 
19568 \begin_inset Quotes eld
19569 \end_inset
19570
19571
19572 \family typewriter
19573 {}
19574 \family default
19575
19576 \begin_inset Quotes erd
19577 \end_inset
19578
19579 .
19580 \end_layout
19581
19582 \begin_layout Enumerate
19583
19584 \size small
19585 Italic correction (
19586 \begin_inset Quotes eld
19587 \end_inset
19588
19589
19590 \family typewriter
19591
19592 \backslash
19593 /
19594 \family default
19595
19596 \begin_inset Quotes erd
19597 \end_inset
19598
19599 ) found in non-italic buffer.
19600 \end_layout
19601
19602 \begin_layout Enumerate
19603
19604 \size small
19605 Italic correction (
19606 \begin_inset Quotes eld
19607 \end_inset
19608
19609
19610 \family typewriter
19611
19612 \backslash
19613 /
19614 \family default
19615
19616 \begin_inset Quotes erd
19617 \end_inset
19618
19619 ) found more than once.
19620 \end_layout
19621
19622 \begin_layout Enumerate
19623
19624 \size small
19625 \emph on
19626 No italic correction (
19627 \begin_inset Quotes eld
19628 \end_inset
19629
19630
19631 \family typewriter
19632
19633 \backslash
19634 /
19635 \family default
19636
19637 \begin_inset Quotes erd
19638 \end_inset
19639
19640 ) found.
19641 \end_layout
19642
19643 \begin_layout Enumerate
19644
19645 \size small
19646 Accent command 
19647 \begin_inset Quotes eld
19648 \end_inset
19649
19650
19651 \family typewriter
19652 cmd
19653 \family default
19654
19655 \begin_inset Quotes erd
19656 \end_inset
19657
19658  needs use of 
19659 \begin_inset Quotes eld
19660 \end_inset
19661
19662
19663 \family typewriter
19664 cmd
19665 \family default
19666
19667 \begin_inset Quotes erd
19668 \end_inset
19669
19670 .
19671 \end_layout
19672
19673 \begin_layout Enumerate
19674
19675 \size small
19676 Wrong length of dash may have been used.
19677 \end_layout
19678
19679 \begin_layout Enumerate
19680
19681 \size small
19682 \emph on
19683 \begin_inset Quotes eld
19684 \end_inset
19685
19686
19687 \family typewriter
19688 %s
19689 \family default
19690
19691 \begin_inset Quotes erd
19692 \end_inset
19693
19694  expected, found 
19695 \begin_inset Quotes eld
19696 \end_inset
19697
19698
19699 \family typewriter
19700 %s
19701 \family default
19702
19703 \begin_inset Quotes erd
19704 \end_inset
19705
19706 .
19707 \end_layout
19708
19709 \begin_layout Enumerate
19710
19711 \size small
19712 Solo 
19713 \begin_inset Quotes eld
19714 \end_inset
19715
19716
19717 \family typewriter
19718 %s
19719 \family default
19720
19721 \begin_inset Quotes erd
19722 \end_inset
19723
19724  found.
19725 \end_layout
19726
19727 \begin_layout Enumerate
19728
19729 \size small
19730 You should use 
19731 \begin_inset Quotes eld
19732 \end_inset
19733
19734
19735 \family typewriter
19736 %s
19737 \family default
19738
19739 \begin_inset Quotes erd
19740 \end_inset
19741
19742  to achieve an ellipsis.
19743 \end_layout
19744
19745 \begin_layout Enumerate
19746
19747 \size small
19748 Inter-word spacing (
19749 \begin_inset Quotes eld
19750 \end_inset
19751
19752
19753 \family typewriter
19754
19755 \backslash
19756
19757 \family default
19758  
19759 \begin_inset Quotes eld
19760 \end_inset
19761
19762 ) should perhaps be used.
19763 \end_layout
19764
19765 \begin_layout Enumerate
19766
19767 \size small
19768 Inter-sentence spacing (
19769 \begin_inset Quotes eld
19770 \end_inset
19771
19772
19773 \family typewriter
19774
19775 \backslash
19776 @
19777 \family default
19778
19779 \begin_inset Quotes erd
19780 \end_inset
19781
19782 ) should perhaps be used.
19783 \end_layout
19784
19785 \begin_layout Enumerate
19786
19787 \size small
19788 Could not find argument for command.
19789 \end_layout
19790
19791 \begin_layout Enumerate
19792
19793 \size small
19794 No match found for 
19795 \begin_inset Quotes eld
19796 \end_inset
19797
19798
19799 \family typewriter
19800 %s
19801 \family default
19802
19803 \begin_inset Quotes erd
19804 \end_inset
19805
19806 .
19807 \end_layout
19808
19809 \begin_layout Enumerate
19810
19811 \size small
19812 Math mode still on at end of \SpecialChar LaTeX
19813  file.
19814 \end_layout
19815
19816 \begin_layout Enumerate
19817
19818 \size small
19819 Number of 
19820 \begin_inset Quotes eld
19821 \end_inset
19822
19823
19824 \family typewriter
19825 char
19826 \family default
19827
19828 \begin_inset Quotes erd
19829 \end_inset
19830
19831  doesn't match the number of 
19832 \begin_inset Quotes eld
19833 \end_inset
19834
19835
19836 \family typewriter
19837 char
19838 \family default
19839
19840 \begin_inset Quotes erd
19841 \end_inset
19842
19843 .
19844 \end_layout
19845
19846 \begin_layout Enumerate
19847
19848 \size small
19849 You should use either 
19850 \family typewriter
19851
19852 \begin_inset Quotes eld
19853 \end_inset
19854
19855
19856 \family default
19857  or 
19858 \family typewriter
19859
19860 \begin_inset Quotes erd
19861 \end_inset
19862
19863
19864 \family default
19865  as an alternative to 
19866 \begin_inset Quotes eld
19867 \end_inset
19868
19869
19870 \family typewriter
19871 "
19872 \family default
19873
19874 \begin_inset Quotes erd
19875 \end_inset
19876
19877 .
19878 \end_layout
19879
19880 \begin_layout Enumerate
19881
19882 \size small
19883 You should use "
19884 \family typewriter
19885 '
19886 \family default
19887 " (ASCII 39) instead of "
19888 \family typewriter
19889 ´
19890 \family default
19891 " (ASCII 180).
19892 \end_layout
19893
19894 \begin_layout Enumerate
19895
19896 \size small
19897 User-specified pattern found.
19898 \end_layout
19899
19900 \begin_layout Enumerate
19901
19902 \size small
19903 This command might not be intended.
19904 \end_layout
19905
19906 \begin_layout Enumerate
19907
19908 \size small
19909 \emph on
19910 Comment displayed.
19911 \end_layout
19912
19913 \begin_layout Enumerate
19914
19915 \size small
19916 Either 
19917 \family typewriter
19918 ''
19919 \backslash
19920 ,'
19921 \family default
19922  or 
19923 \family typewriter
19924 '
19925 \backslash
19926 ,''
19927 \family default
19928  will look better.
19929 \end_layout
19930
19931 \begin_layout Enumerate
19932
19933 \size small
19934 Delete this space to maintain correct page references.
19935 \end_layout
19936
19937 \begin_layout Enumerate
19938
19939 \size small
19940 \emph on
19941 You might wish to put this between a pair of 
19942 \begin_inset Quotes eld
19943 \end_inset
19944
19945
19946 \family typewriter
19947 {}
19948 \family default
19949
19950 \begin_inset Quotes erd
19951 \end_inset
19952
19953 .
19954 \end_layout
19955
19956 \begin_layout Enumerate
19957
19958 \size small
19959 You ought to remove spaces in front of punctuation.
19960 \end_layout
19961
19962 \begin_layout Enumerate
19963
19964 \size small
19965 Could not execute \SpecialChar LaTeX
19966  command.
19967 \end_layout
19968
19969 \begin_layout Enumerate
19970
19971 \size small
19972 Don't use 
19973 \family typewriter
19974
19975 \backslash
19976 /
19977 \family default
19978  in front of small punctuation.
19979 \end_layout
19980
19981 \begin_layout Enumerate
19982
19983 \family typewriter
19984 \size small
19985 $
19986 \backslash
19987 times$
19988 \family default
19989  may look prettier here.
19990 \end_layout
19991
19992 \begin_layout Enumerate
19993
19994 \size small
19995 \emph on
19996 Multiple spaces detected in output.
19997 \end_layout
19998
19999 \begin_layout Enumerate
20000
20001 \size small
20002 This text may be ignored.
20003 \end_layout
20004
20005 \begin_layout Enumerate
20006
20007 \size small
20008 Use 
20009 \family typewriter
20010
20011 \begin_inset Quotes eld
20012 \end_inset
20013
20014
20015 \family default
20016  to begin quotation, not 
20017 \family typewriter
20018 '
20019 \family default
20020 .
20021 \end_layout
20022
20023 \begin_layout Enumerate
20024
20025 \size small
20026 Use 
20027 \family typewriter
20028 '
20029 \family default
20030  to end quotation, not 
20031 \family typewriter
20032
20033 \begin_inset Quotes eld
20034 \end_inset
20035
20036
20037 \family default
20038 .
20039 \end_layout
20040
20041 \begin_layout Enumerate
20042
20043 \size small
20044 Don't mix quotes.
20045 \end_layout
20046
20047 \begin_layout Enumerate
20048
20049 \size small
20050 You should perhaps use 
20051 \begin_inset Quotes eld
20052 \end_inset
20053
20054
20055 \family typewriter
20056 cmd
20057 \family default
20058
20059 \begin_inset Quotes erd
20060 \end_inset
20061
20062  instead.
20063 \end_layout
20064
20065 \begin_layout Enumerate
20066
20067 \size small
20068 You should put a space in front of/after parenthesis.
20069 \end_layout
20070
20071 \begin_layout Enumerate
20072
20073 \size small
20074 You should avoid spaces in front of/after parenthesis.
20075 \end_layout
20076
20077 \begin_layout Enumerate
20078
20079 \size small
20080 \emph on
20081 You should not use punctuation in front of/after quotes.
20082 \end_layout
20083
20084 \begin_layout Enumerate
20085
20086 \size small
20087 Double space found.
20088 \end_layout
20089
20090 \begin_layout Enumerate
20091
20092 \size small
20093 You should put punctuation outside inner/inside display math mode.
20094 \end_layout
20095
20096 \begin_layout Enumerate
20097
20098 \size small
20099 You ought to not use primitive \SpecialChar TeX
20100  in \SpecialChar LaTeX
20101  code.
20102 \end_layout
20103
20104 \begin_layout Enumerate
20105
20106 \size small
20107 You should remove spaces in front of 
20108 \begin_inset Quotes eld
20109 \end_inset
20110
20111
20112 \family typewriter
20113 %s
20114 \family default
20115
20116 \begin_inset Quotes erd
20117 \end_inset
20118
20119
20120 \end_layout
20121
20122 \begin_layout Enumerate
20123
20124 \size small
20125 \begin_inset Quotes eld
20126 \end_inset
20127
20128
20129 \family typewriter
20130 %s
20131 \family default
20132
20133 \begin_inset Quotes erd
20134 \end_inset
20135
20136  is normally not followed by 
20137 \begin_inset Quotes eld
20138 \end_inset
20139
20140
20141 \family typewriter
20142 %c
20143 \family default
20144
20145 \begin_inset Quotes erd
20146 \end_inset
20147
20148 .
20149 \end_layout
20150
20151 \begin_layout Standard
20152 In later versions of \SpecialChar LyX
20153 , we hope to provide a more complete interface to this
20154  tool (and it's smaller cousin 
20155 \family typewriter
20156 lacheck
20157 \family default
20158 ) to exploit the full power of it.
20159  But it's not exactly useless as it is now: go try it on one of your existing
20160  documents of a certain length and be surprised.
20161 \end_layout
20162
20163 \begin_layout Section
20164 Version Control in \SpecialChar LyX
20165
20166 \end_layout
20167
20168 \begin_layout Standard
20169 by
20170 \noun on
20171  Lars Gullik Bjønnes 
20172 \noun default
20173 and 
20174 \noun on
20175 Pavel Sanda
20176 \end_layout
20177
20178 \begin_layout Subsection
20179 Introduction
20180 \end_layout
20181
20182 \begin_layout Standard
20183 \SpecialChar LyX
20184  supports some of the most basic RCS/CVS/SVN/GIT commands.
20185  If you need something a bit more sophisticated you will have to do that
20186  manually in a terminal.
20187 \end_layout
20188
20189 \begin_layout Standard
20190 Also note that CVS support is not as good as subversion support so we advise
20191  using SVN instead.
20192  A good place to start learning Subversion is SVN Book
20193 \begin_inset Foot
20194 status collapsed
20195
20196 \begin_layout Plain Layout
20197 \begin_inset CommandInset href
20198 LatexCommand href
20199 target "http://svnbook.red-bean.com/"
20200 literal "false"
20201
20202 \end_inset
20203
20204
20205 \end_layout
20206
20207 \end_inset
20208
20209 .
20210  In the case of RCS you should read 
20211 \begin_inset Quotes eld
20212 \end_inset
20213
20214 rcsintro
20215 \begin_inset Quotes erd
20216 \end_inset
20217
20218  (a man file, read it with 
20219 \family typewriter
20220 man rcsintro
20221 \family default
20222 ).
20223  This file describes all the basic features of RCS.
20224  You should especially notice the comment about a RCS directory, and the
20225  notion of a master RCS file (the file ending in 
20226 \family typewriter
20227 ,v
20228 \family default
20229 ).
20230 \end_layout
20231
20232 \begin_layout Standard
20233 Before you begin to use the version control features in \SpecialChar LyX
20234 , you should be
20235  familiar with RCS/CVS/SVN/GIT usage.
20236  The implementation in \SpecialChar LyX
20237  assumes a recent version of the GNU RCS or CVS/SVN
20238  package — no guarantees are made for older versions.
20239  Most of the log messages are not currently displayed after operations —
20240  you can check them in the Messages pane if unsure.
20241  Regular users of version control will appreciate VC toolbar, which can
20242  be enabled via 
20243 \family sans
20244 View\SpecialChar menuseparator
20245 Toolbars\SpecialChar menuseparator
20246 Version
20247 \begin_inset space ~
20248 \end_inset
20249
20250 Control
20251 \family default
20252 .
20253 \end_layout
20254
20255 \begin_layout Standard
20256 For introducing your own external commands consult vc-command in the manual
20257  of \SpecialChar LyX
20258  functions.
20259 \end_layout
20260
20261 \begin_layout Standard
20262 It is strongly recommended to store documents in uncompressed format if
20263  using version control (uncheck 
20264 \family sans
20265 Document\SpecialChar menuseparator
20266 Compressed
20267 \family default
20268  if it is checked): Uncompressed LyX documents are text files and therefore
20269  for merging two different versions by version control systems.
20270  Compressed LyX documents are binary files, which cannot be merged by version
20271  control systems.
20272 \end_layout
20273
20274 \begin_layout Subsection
20275 RCS commands in \SpecialChar LyX
20276
20277 \end_layout
20278
20279 \begin_layout Standard
20280 The following sections describe the RCS commands supported by \SpecialChar LyX
20281 .
20282  You can find them in the 
20283 \family sans
20284 File\SpecialChar menuseparator
20285 Version
20286 \begin_inset space ~
20287 \end_inset
20288
20289 Control
20290 \family default
20291  submenu.
20292  \SpecialChar LyX
20293  was tested against RCS 5.7/5.8.
20294 \end_layout
20295
20296 \begin_layout Subsubsection
20297
20298 \family sans
20299 Register
20300 \end_layout
20301
20302 \begin_layout Standard
20303 If your document is not under revision control, this is the only item shown
20304  in the menu.
20305  And if it is under revision control, the 
20306 \family sans
20307 Register
20308 \family default
20309  item is not visible.
20310  
20311 \end_layout
20312
20313 \begin_layout Standard
20314 This command registers your document with RCS (unless you are under the
20315  directory managed by CVS)\SpecialChar endofsentence
20316  You are asked interactively to supply an initial
20317  description of the document.
20318  The document is now set in Read-Only mode and you have to 
20319 \family sans
20320 Check
20321 \begin_inset space ~
20322 \end_inset
20323
20324 Out
20325 \begin_inset space ~
20326 \end_inset
20327
20328 For
20329 \begin_inset space ~
20330 \end_inset
20331
20332 Edit
20333 \family default
20334 , before making any changes to it.
20335  A document under revision control has a 
20336 \begin_inset Quotes eld
20337 \end_inset
20338
20339 [RCS:<version> <locker>]
20340 \begin_inset Quotes erd
20341 \end_inset
20342
20343  item tagged to the filename in the minibuffer.
20344 \end_layout
20345
20346 \begin_layout Standard
20347 RCS command that is run: 
20348 \family typewriter
20349 ci -q -u -i -t-"<initial description>" <file-name>
20350 \end_layout
20351
20352 \begin_layout Standard
20353 Read 
20354 \family typewriter
20355 man ci
20356 \family default
20357  to understand the switches.
20358  
20359 \end_layout
20360
20361 \begin_layout Subsubsection
20362
20363 \family sans
20364 Check In Changes
20365 \end_layout
20366
20367 \begin_layout Standard
20368 When you are finished editing a file, you check in your changes.
20369  When you do this, you are asked for a description of the changes.
20370  This is stored in the history log.
20371  The version number is bumped, your changes are applied to the master RCS
20372  file, the document is unlocked and set to Read-Only mode.
20373 \end_layout
20374
20375 \begin_layout Standard
20376 RCS command: 
20377 \family typewriter
20378 ci -q -u -m"<description>" <file-name>
20379 \end_layout
20380
20381 \begin_layout Subsubsection
20382
20383 \family sans
20384 Check Out For Edit
20385 \end_layout
20386
20387 \begin_layout Standard
20388 By doing this you lock the document so that only you can edit it.
20389  This will also make the document Read-Write only for you.
20390  You will usually continue editing for a while and when you are finished
20391  you check in your changes.
20392  The status line is changed to reflect that you have locked the file.
20393 \end_layout
20394
20395 \begin_layout Standard
20396 RCS command: 
20397 \family typewriter
20398 co -q -l <file-name>
20399 \end_layout
20400
20401 \begin_layout Subsubsection
20402
20403 \family sans
20404 Revert To Repository Version
20405 \end_layout
20406
20407 \begin_layout Standard
20408 This will discard all changes made to the document since the last check
20409  in.
20410  You get a warning before changes are discarded.
20411 \end_layout
20412
20413 \begin_layout Standard
20414 RCS command: 
20415 \family typewriter
20416 co -f -u<version> <file-name>
20417 \end_layout
20418
20419 \begin_layout Subsubsection
20420
20421 \family sans
20422 Copy
20423 \end_layout
20424
20425 \begin_layout Standard
20426 This will create a copy of the current document.
20427  Since RCS does not support copy operations natively, the version history
20428  is not preserved, and the copy is added as a new file.
20429  It requires a clean document without any changes since the last checkin.
20430  You are asked for a file name and a description of the copy operation.
20431  After that the copy is created, both locally and in the repository.
20432  If the parent directories of the copied and original document differ, all
20433  relative paths of included files of the copy are adjusted (like in 
20434 \family sans
20435 File\SpecialChar menuseparator
20436 Save As
20437 \family default
20438 \SpecialChar ldots
20439 ).
20440  Finally, the copy is loaded instead of the original document.
20441 \end_layout
20442
20443 \begin_layout Labeling
20444 \labelwidthstring 00.00.0000
20445 RCS
20446 \begin_inset space ~
20447 \end_inset
20448
20449 commands: 
20450 \begin_inset space ~
20451 \end_inset
20452
20453
20454 \begin_inset Newline newline
20455 \end_inset
20456
20457 Copy 
20458 \begin_inset Flex Code
20459 status collapsed
20460
20461 \begin_layout Plain Layout
20462
20463 \family typewriter
20464 \begin_inset Quotes eld
20465 \end_inset
20466
20467 <file-name>
20468 \begin_inset Quotes erd
20469 \end_inset
20470
20471
20472 \end_layout
20473
20474 \end_inset
20475
20476  to 
20477 \begin_inset Flex Code
20478 status collapsed
20479
20480 \begin_layout Plain Layout
20481
20482 \family typewriter
20483 \begin_inset Quotes eld
20484 \end_inset
20485
20486 <new-file-name>
20487 \begin_inset Quotes erd
20488 \end_inset
20489
20490
20491 \end_layout
20492
20493 \end_inset
20494
20495
20496 \begin_inset Newline newline
20497 \end_inset
20498
20499
20500 \begin_inset Flex Code
20501 status collapsed
20502
20503 \begin_layout Plain Layout
20504 ci -q -u 
20505 \family typewriter
20506 -i 
20507 \begin_inset Quotes eld
20508 \end_inset
20509
20510 <new-file-name>
20511 \begin_inset Quotes erd
20512 \end_inset
20513
20514
20515 \end_layout
20516
20517 \end_inset
20518
20519
20520 \end_layout
20521
20522 \begin_layout Subsubsection
20523
20524 \family sans
20525 Undo Last Checkin
20526 \end_layout
20527
20528 \begin_layout Standard
20529 This makes as if the last check in never happened.
20530  No changes are made to the document loaded into \SpecialChar LyX
20531 , but the last version
20532  is removed from the master RCS file.
20533 \end_layout
20534
20535 \begin_layout Standard
20536 RCS command: 
20537 \family typewriter
20538 rcs -o<version> <file-name>
20539 \end_layout
20540
20541 \begin_layout Subsubsection
20542
20543 \family sans
20544 Show History
20545 \end_layout
20546
20547 \begin_layout Standard
20548 This shows the complete history of the RCS document.
20549  The output of 
20550 \family typewriter
20551 rlog <file-name>
20552 \family default
20553  is shown in a browser.
20554  See 
20555 \family typewriter
20556 man rlog
20557 \family default
20558  for more info.
20559 \end_layout
20560
20561 \begin_layout Subsubsection
20562 Revision info
20563 \end_layout
20564
20565 \begin_layout Standard
20566 \SpecialChar LyX
20567  supports RCS version number, author name, date and time of last commit.
20568  All those are extracted from 
20569 \family typewriter
20570 rlog -r <file-name>
20571 \family default
20572 .
20573  See 
20574 \begin_inset CommandInset ref
20575 LatexCommand ref
20576 reference "subsec:VCS-Revision-Information"
20577
20578 \end_inset
20579
20580  for details.
20581 \end_layout
20582
20583 \begin_layout Subsection
20584 CVS commands in \SpecialChar LyX
20585
20586 \end_layout
20587
20588 \begin_layout Standard
20589 A subset of CVS operations is supported by \SpecialChar LyX
20590 .
20591  You can find the commands in the 
20592 \family sans
20593 File\SpecialChar menuseparator
20594 Version
20595 \begin_inset space ~
20596 \end_inset
20597
20598 Control
20599 \family default
20600  submenu.
20601  The version control system SVN is more powerful, so please use it instead
20602  of CVS if possible.
20603 \end_layout
20604
20605 \begin_layout Subsubsection
20606
20607 \family sans
20608 General CVS usage
20609 \end_layout
20610
20611 \begin_layout Standard
20612 If you start from scratch with CVS you have to create your repository and
20613  checkout the working copy with external tools.
20614  If you're using a client-server setup you may need to login before doing
20615  the first repository checkout.
20616 \end_layout
20617
20618 \begin_layout Standard
20619 If your documents are under revision control and others are using the same
20620  repository problems arise when different changes to the same document at
20621  the same location happen.
20622  Standard CVS repositories don't operate with a file locking mechanism.
20623  This may be surprising, but conflicts only occur if people disagree on
20624  the proper content of the same part of a document.
20625  So, if co-workers are used to communicate regularly, these conflicts occur
20626  rarely.
20627  If they don't communicate they have a fundamental problem anyway.
20628  Nevertheless some people like to work with so called 
20629 \begin_inset Quotes eld
20630 \end_inset
20631
20632 reserved checkouts
20633 \begin_inset Quotes erd
20634 \end_inset
20635
20636 .
20637  If they do so the working copy of all files is readonly when checked out
20638  first and the user starts editing after using a special command to make
20639  the working copy writable.
20640  When the changes are checked in the working copy returns to readonly state.
20641  With \SpecialChar LyX
20642  one has to edit the 
20643 \begin_inset Flex Code
20644 status collapsed
20645
20646 \begin_layout Plain Layout
20647 .cvsrc
20648 \end_layout
20649
20650 \end_inset
20651
20652  file and add the line 
20653 \begin_inset Flex Code
20654 status collapsed
20655
20656 \begin_layout Plain Layout
20657 cvs -r
20658 \end_layout
20659
20660 \end_inset
20661
20662  to work with reserved checkouts.
20663  The benefit is the possibility to see who is using a writable copy of some
20664  document.
20665  It's not guaranteed only one user makes a copy writable.
20666 \end_layout
20667
20668 \begin_layout Standard
20669 \SpecialChar LyX
20670  tries to guess if you're using reserved or non-reserved checkouts.
20671  If your working copy is readonly or it is writable and an additional copy
20672  of your document exists in the CVS/Base sub-directory a reserved otherwise
20673  a non-reserved checkout is assumed.
20674  When a reserved checkout is detected you have to use 
20675 \begin_inset Flex Noun
20676 status collapsed
20677
20678 \begin_layout Plain Layout
20679 Check Out
20680 \end_layout
20681
20682 \end_inset
20683
20684  to make your working copy writable if it's readonly.
20685  After doing so the 
20686 \begin_inset Flex Noun
20687 status collapsed
20688
20689 \begin_layout Plain Layout
20690 Check In
20691 \end_layout
20692
20693 \end_inset
20694
20695  operation is possible and that makes your working copy readonly again after
20696  transferring your changes to the repository.
20697 \end_layout
20698
20699 \begin_layout Standard
20700 More information about CVS can be found here 
20701 \begin_inset Flex URL
20702 status collapsed
20703
20704 \begin_layout Plain Layout
20705
20706 http://www.nongnu.org/cvs
20707 \end_layout
20708
20709 \end_inset
20710
20711  and here 
20712 \begin_inset Flex URL
20713 status collapsed
20714
20715 \begin_layout Plain Layout
20716
20717 http://ximbiot.com/cvs
20718 \end_layout
20719
20720 \end_inset
20721
20722 .
20723 \end_layout
20724
20725 \begin_layout Standard
20726 Read 
20727 \family typewriter
20728 man cvs
20729 \family default
20730  to understand the sub-commands and the switches mentioned below.
20731 \end_layout
20732
20733 \begin_layout Subsubsection
20734
20735 \family sans
20736 Register
20737 \end_layout
20738
20739 \begin_layout Standard
20740 If your document is not under revision control, this is the only item shown
20741  in the menu.
20742  And if it is under revision control, the 
20743 \family sans
20744 Register
20745 \family default
20746  item is not visible.
20747  
20748 \end_layout
20749
20750 \begin_layout Standard
20751 This command registers in CVS your document 
20752 \begin_inset Flex Strong
20753 status collapsed
20754
20755 \begin_layout Plain Layout
20756
20757 \emph on
20758 only
20759 \end_layout
20760
20761 \end_inset
20762
20763  in the case you have already the documents directory under CVS control
20764  (in particular 
20765 \family typewriter
20766 CVS/Entries
20767 \family default
20768  file exists).
20769  This means you have to create or checkout the archive by yourself using
20770  external tools.
20771  (In case you forget that step \SpecialChar LyX
20772  registers the document with RCS.)
20773 \end_layout
20774
20775 \begin_layout Standard
20776 Then you are asked interactively to supply an initial description of the
20777  document.
20778  Don't forget that registered file is not yet checked in.
20779 \end_layout
20780
20781 \begin_layout Standard
20782 CVS command that is run: 
20783 \family typewriter
20784 cvs -q add -m"<entered message>" "<file-name>"
20785 \end_layout
20786
20787 \begin_layout Standard
20788 The term 
20789 \family typewriter
20790 "<file-name>"
20791 \family default
20792  above and for all other CVS commands is an abbreviation for 
20793 \begin_inset Quotes eld
20794 \end_inset
20795
20796 change the current working directory to file location and use the file name
20797  without path component as argument
20798 \begin_inset Quotes erd
20799 \end_inset
20800
20801 .
20802 \end_layout
20803
20804 \begin_layout Subsubsection
20805
20806 \family sans
20807 Check In Changes
20808 \end_layout
20809
20810 \begin_layout Standard
20811 When you are finished editing a file, you commit your changes.
20812  When you do this and you had changed the document, you are asked for a
20813  description of the changes.
20814  After that changes are written to the repository.
20815  In case you didn't change the document and a reserved checkout is detected
20816  the reservation made on 
20817 \begin_inset Flex Noun
20818 status collapsed
20819
20820 \begin_layout Plain Layout
20821 Check Out
20822 \end_layout
20823
20824 \end_inset
20825
20826  is undone.
20827 \end_layout
20828
20829 \begin_layout Labeling
20830 \labelwidthstring 00.00.0000
20831 CVS
20832 \begin_inset space ~
20833 \end_inset
20834
20835 command: 
20836 \begin_inset space ~
20837 \end_inset
20838
20839
20840 \begin_inset Newline newline
20841 \end_inset
20842
20843
20844 \begin_inset Flex Code
20845 status collapsed
20846
20847 \begin_layout Plain Layout
20848 cvs 
20849 \family typewriter
20850 -q commit -m"<description>" "<file-name>"
20851 \end_layout
20852
20853 \end_inset
20854
20855  or
20856 \begin_inset Newline newline
20857 \end_inset
20858
20859
20860 \begin_inset Flex Code
20861 status collapsed
20862
20863 \begin_layout Plain Layout
20864 cvs -q unedit 
20865 \family typewriter
20866 "<file-name>"
20867 \end_layout
20868
20869 \end_inset
20870
20871
20872 \end_layout
20873
20874 \begin_layout Subsubsection
20875
20876 \family sans
20877 Check Out Changes
20878 \end_layout
20879
20880 \begin_layout Standard
20881 When you are sharing a repository with others, you may have to incorporate
20882  their changes into your working copy.
20883 \end_layout
20884
20885 \begin_layout Standard
20886 CVS command: 
20887 \family typewriter
20888 cvs -q update "<file-name>"
20889 \end_layout
20890
20891 \begin_layout Standard
20892 If a readonly checkout is detected the working copy is made writable and
20893  reserved.
20894 \end_layout
20895
20896 \begin_layout Standard
20897 CVS command: 
20898 \family typewriter
20899 cvs -q edit "<file-name>"
20900 \end_layout
20901
20902 \begin_layout Subsubsection
20903
20904 \family sans
20905 Revert To Repository Version
20906 \end_layout
20907
20908 \begin_layout Standard
20909 This will discard all changes made to the document since the last check
20910  in.
20911  You get a warning before changes are discarded.
20912  Firstly the file is deleted, secondly CVS update command is run.
20913 \end_layout
20914
20915 \begin_layout Standard
20916 CVS command: 
20917 \family typewriter
20918 cvs -q update "<file-name>"
20919 \end_layout
20920
20921 \begin_layout Standard
20922 If a reserved checkout is detected and the working copy has no changes only
20923  the reservation is undone.
20924 \end_layout
20925
20926 \begin_layout Standard
20927 CVS command: 
20928 \family typewriter
20929 cvs -q unedit "<file-name>"
20930 \end_layout
20931
20932 \begin_layout Subsubsection
20933
20934 \family sans
20935 Copy
20936 \end_layout
20937
20938 \begin_layout Standard
20939 This will create a copy of the current document.
20940  Since CVS does not support copy operations natively, the version history
20941  is not preserved, and the copy is added as a new file.
20942  It requires a clean document without any changes since the last checkin.
20943  You are asked for a file name and a description of the copy operation.
20944  After that the copy is created, both locally and in the repository.
20945  If the parent directories of the copied and original document differ, all
20946  relative paths of included files of the copy are adjusted (like in 
20947 \family sans
20948 File\SpecialChar menuseparator
20949 Save As
20950 \family default
20951 \SpecialChar ldots
20952 ).
20953  Finally, the copy is loaded instead of the original document.
20954 \end_layout
20955
20956 \begin_layout Labeling
20957 \labelwidthstring 00.00.0000
20958 CVS
20959 \begin_inset space ~
20960 \end_inset
20961
20962 commands: 
20963 \begin_inset space ~
20964 \end_inset
20965
20966
20967 \begin_inset Newline newline
20968 \end_inset
20969
20970 Copy 
20971 \begin_inset Flex Code
20972 status collapsed
20973
20974 \begin_layout Plain Layout
20975
20976 \family typewriter
20977 \begin_inset Quotes eld
20978 \end_inset
20979
20980 <file-name>
20981 \begin_inset Quotes erd
20982 \end_inset
20983
20984
20985 \end_layout
20986
20987 \end_inset
20988
20989  to 
20990 \begin_inset Flex Code
20991 status collapsed
20992
20993 \begin_layout Plain Layout
20994
20995 \family typewriter
20996 \begin_inset Quotes eld
20997 \end_inset
20998
20999 <new-file-name>
21000 \begin_inset Quotes erd
21001 \end_inset
21002
21003
21004 \end_layout
21005
21006 \end_inset
21007
21008
21009 \begin_inset Newline newline
21010 \end_inset
21011
21012
21013 \begin_inset Flex Code
21014 status collapsed
21015
21016 \begin_layout Plain Layout
21017 cvs -q add 
21018 \family typewriter
21019
21020 \begin_inset Quotes eld
21021 \end_inset
21022
21023 <new-file-name>
21024 \begin_inset Quotes erd
21025 \end_inset
21026
21027
21028 \end_layout
21029
21030 \end_inset
21031
21032
21033 \end_layout
21034
21035 \begin_layout Subsubsection
21036
21037 \family sans
21038 Rename
21039 \end_layout
21040
21041 \begin_layout Standard
21042 This will rename the current document.
21043  Since CVS does not support rename operations natively, the version history
21044  is not preserved, the renamed document is added as a new file, and the
21045  original document is deleted.
21046  It requires a clean document without any changes since the last checkin.
21047  You are asked for a file name and a description of the rename operation.
21048  After that the document is renamed, both locally and in the repository.
21049  If the parent directories of the new and old file names differ, all relative
21050  paths of included files are adjusted (like in 
21051 \family sans
21052 File\SpecialChar menuseparator
21053 Save As
21054 \family default
21055 \SpecialChar ldots
21056 ).
21057  Finally, the document is reloaded using the new name.
21058 \end_layout
21059
21060 \begin_layout Labeling
21061 \labelwidthstring 00.00.0000
21062 CVS
21063 \begin_inset space ~
21064 \end_inset
21065
21066 commands: 
21067 \begin_inset space ~
21068 \end_inset
21069
21070
21071 \begin_inset Newline newline
21072 \end_inset
21073
21074 Rename 
21075 \begin_inset Flex Code
21076 status collapsed
21077
21078 \begin_layout Plain Layout
21079
21080 \family typewriter
21081 \begin_inset Quotes eld
21082 \end_inset
21083
21084 <file-name>
21085 \begin_inset Quotes erd
21086 \end_inset
21087
21088
21089 \end_layout
21090
21091 \end_inset
21092
21093  to 
21094 \begin_inset Flex Code
21095 status collapsed
21096
21097 \begin_layout Plain Layout
21098
21099 \family typewriter
21100 \begin_inset Quotes eld
21101 \end_inset
21102
21103 <new-file-name>
21104 \begin_inset Quotes erd
21105 \end_inset
21106
21107
21108 \end_layout
21109
21110 \end_inset
21111
21112
21113 \begin_inset Newline newline
21114 \end_inset
21115
21116
21117 \begin_inset Flex Code
21118 status collapsed
21119
21120 \begin_layout Plain Layout
21121 cvs -q add 
21122 \family typewriter
21123
21124 \begin_inset Quotes eld
21125 \end_inset
21126
21127 <new-file-name>
21128 \begin_inset Quotes erd
21129 \end_inset
21130
21131
21132 \end_layout
21133
21134 \end_inset
21135
21136
21137 \begin_inset Newline newline
21138 \end_inset
21139
21140
21141 \begin_inset Flex Code
21142 status collapsed
21143
21144 \begin_layout Plain Layout
21145 cvs -q remove 
21146 \family typewriter
21147
21148 \begin_inset Quotes eld
21149 \end_inset
21150
21151 <file-name>
21152 \begin_inset Quotes erd
21153 \end_inset
21154
21155
21156 \end_layout
21157
21158 \end_inset
21159
21160
21161 \end_layout
21162
21163 \begin_layout Subsubsection
21164 Update of the local directory checkout from repository
21165 \end_layout
21166
21167 \begin_layout Standard
21168 Once your documents gets more complex, containing sub-documents and pictures,
21169  including external 
21170 \begin_inset Flex Code
21171 status collapsed
21172
21173 \begin_layout Plain Layout
21174 .tex
21175 \end_layout
21176
21177 \end_inset
21178
21179  files and so on using version control becomes more complicated.
21180  \SpecialChar LyX
21181  supports updating the whole tree in which resides the document.
21182  This become especially useful once you cooperate with people which neither
21183  have detailed knowledge about CVS usage nor they have ambition to commit
21184  additional material to the repository.
21185  You have to organize the files structure so that all external files are
21186  in the same directory or subdirectories of the document.
21187  It's good practice anyway to store multipart documents in an extra directory.
21188 \end_layout
21189
21190 \begin_layout Standard
21191 The 
21192 \begin_inset Flex Code
21193 status collapsed
21194
21195 \begin_layout Plain Layout
21196 Update local directory from repository
21197 \end_layout
21198
21199 \end_inset
21200
21201  command updates the whole directory.
21202  If local changes are detected user is warned before update starts.
21203  In case of merge conflicts both versions of the conflicting document parts
21204  are placed in the final document.
21205  You have to review and correct the result of the merge.
21206  You'll find the conflicts enclosed in pairs of 
21207 \begin_inset Flex Code
21208 status collapsed
21209
21210 \begin_layout Plain Layout
21211 <<<<<<<
21212 \end_layout
21213
21214 \end_inset
21215
21216  and 
21217 \begin_inset Flex Code
21218 status collapsed
21219
21220 \begin_layout Plain Layout
21221 >>>>>>>
21222 \end_layout
21223
21224 \end_inset
21225
21226  separated by 
21227 \begin_inset Flex Code
21228 status collapsed
21229
21230 \begin_layout Plain Layout
21231 =======
21232 \end_layout
21233
21234 \end_inset
21235
21236 .
21237  The first part is your version as before the update operation with the
21238  document name prepended.
21239  The second one is the repository version with the version number after
21240  the sequence of 
21241 \begin_inset Flex Code
21242 status collapsed
21243
21244 \begin_layout Plain Layout
21245 >
21246 \end_layout
21247
21248 \end_inset
21249
21250  signs.
21251 \end_layout
21252
21253 \begin_layout Labeling
21254 \labelwidthstring 00.00.0000
21255 CVS
21256 \begin_inset space ~
21257 \end_inset
21258
21259 commands: 
21260 \begin_inset space ~
21261 \end_inset
21262
21263
21264 \begin_inset Newline newline
21265 \end_inset
21266
21267
21268 \begin_inset Flex Code
21269 status collapsed
21270
21271 \begin_layout Plain Layout
21272 cd $path; cvs diff 
21273 \family typewriter
21274 "."
21275 \end_layout
21276
21277 \end_inset
21278
21279  (Ask if changes are detected.)
21280 \begin_inset Newline newline
21281 \end_inset
21282
21283
21284 \begin_inset Flex Code
21285 status collapsed
21286
21287 \begin_layout Plain Layout
21288 cd $path; cvs -q update 
21289 \family typewriter
21290 "."
21291 \end_layout
21292
21293 \end_inset
21294
21295
21296 \end_layout
21297
21298 \begin_layout Standard
21299 where 
21300 \begin_inset Flex Code
21301 status collapsed
21302
21303 \begin_layout Plain Layout
21304 $path
21305 \end_layout
21306
21307 \end_inset
21308
21309  stands for the path to the document.
21310 \end_layout
21311
21312 \begin_layout Subsubsection
21313
21314 \family sans
21315 Show History
21316 \end_layout
21317
21318 \begin_layout Standard
21319 This shows the complete history of the CVS document.
21320  The output of 
21321 \family typewriter
21322 cvs log "<file-name>"
21323 \family default
21324  is shown in a browser.
21325 \end_layout
21326
21327 \begin_layout Subsubsection
21328 Revision info
21329 \end_layout
21330
21331 \begin_layout Standard
21332 \SpecialChar LyX
21333  supports CVS version number, author name, date and time of last commit.
21334  All those are extracted from 
21335 \family typewriter
21336 cvs log -r <file-name>
21337 \family default
21338 .
21339  See 
21340 \begin_inset CommandInset ref
21341 LatexCommand ref
21342 reference "subsec:VCS-Revision-Information"
21343
21344 \end_inset
21345
21346  for details.
21347 \end_layout
21348
21349 \begin_layout Subsection
21350 SVN commands in \SpecialChar LyX
21351
21352 \end_layout
21353
21354 \begin_layout Standard
21355 SVN is now partially supported by \SpecialChar LyX
21356 .
21357  You can find the commands in the 
21358 \family sans
21359 File\SpecialChar menuseparator
21360 Version
21361 \begin_inset space ~
21362 \end_inset
21363
21364 Control
21365 \family default
21366  submenu.
21367  Please note that if you use password protected access to repository via
21368  ssh, you will be asked in terminal window.
21369  \SpecialChar LyX
21370  was tested against SVN 1.5, 1.6, 1.7 and 1.8
21371 \begin_inset Foot
21372 status open
21373
21374 \begin_layout Plain Layout
21375 Most of the commands will work with 1.4 too, see 
21376 \begin_inset CommandInset ref
21377 LatexCommand ref
21378 reference "subsec:SVN-Repo-Update"
21379
21380 \end_inset
21381
21382 .
21383  There seems to be currently unresolved permissions problem under SVN 1.8
21384  with reverting changes when file is locked.
21385 \end_layout
21386
21387 \end_inset
21388
21389
21390 \end_layout
21391
21392 \begin_layout Subsubsection
21393
21394 \family sans
21395 Register
21396 \end_layout
21397
21398 \begin_layout Standard
21399 If your document is not under revision control, this is the only item shown
21400  in the menu.
21401  And if it is under revision control, the 
21402 \family sans
21403 Register
21404 \family default
21405  item is not visible.
21406 \end_layout
21407
21408 \begin_layout Standard
21409 This command registers in SVN your document ONLY in case you have already
21410  the documents directory under SVN control (in particular 
21411 \family typewriter
21412 .svn/entries
21413 \family default
21414  file exists).
21415  This means you have to checkout the archive by yourself.
21416 \end_layout
21417
21418 \begin_layout Standard
21419 Then you are asked interactively to supply an initial description of the
21420  document.
21421  Don't forget that registered file is not yet commited.
21422 \end_layout
21423
21424 \begin_layout Standard
21425 SVN command that is run: 
21426 \family typewriter
21427 svn add -q 
21428 \begin_inset Quotes eld
21429 \end_inset
21430
21431 <file-name>
21432 \begin_inset Quotes erd
21433 \end_inset
21434
21435
21436 \end_layout
21437
21438 \begin_layout Standard
21439 Read 
21440 \family typewriter
21441 man svn
21442 \family default
21443  to understand the switches.
21444 \end_layout
21445
21446 \begin_layout Subsubsection
21447
21448 \family sans
21449 Check In Changes
21450 \end_layout
21451
21452 \begin_layout Standard
21453 When you are finished editing a file, you commit your changes.
21454  When you do this, you are asked for a description of the changes.
21455  After that changes are commited.
21456 \end_layout
21457
21458 \begin_layout Standard
21459 SVN command:
21460 \begin_inset Foot
21461 status collapsed
21462
21463 \begin_layout Plain Layout
21464 In case locking is not enabled.
21465  See Section 
21466 \begin_inset CommandInset ref
21467 LatexCommand ref
21468 reference "subsec:SVN-File-Locking"
21469
21470 \end_inset
21471
21472 .
21473 \end_layout
21474
21475 \end_inset
21476
21477  
21478 \family typewriter
21479 svn commit -q -m"<description>" <file-name>
21480 \end_layout
21481
21482 \begin_layout Subsubsection
21483
21484 \family sans
21485 Check Out For Edit
21486 \end_layout
21487
21488 \begin_layout Standard
21489 Updates the changes of this file from the repository.
21490  Be sure you understand SVN merging and conflicts resolving before using
21491  this function, because all conflicts has to be resolved manually by you!
21492 \end_layout
21493
21494 \begin_layout Standard
21495 SVN command:
21496 \begin_inset Foot
21497 status collapsed
21498
21499 \begin_layout Plain Layout
21500 Ditto.
21501 \end_layout
21502
21503 \end_inset
21504
21505  
21506 \family typewriter
21507 svn update --non-interactive 
21508 \begin_inset Quotes eld
21509 \end_inset
21510
21511 <file-name>
21512 \begin_inset Quotes erd
21513 \end_inset
21514
21515
21516 \end_layout
21517
21518 \begin_layout Subsubsection
21519
21520 \family sans
21521 Revert To Repository Version
21522 \end_layout
21523
21524 \begin_layout Standard
21525 This will discard all changes made to the document since the last check
21526  in.
21527  You get a warning before changes are discarded.
21528 \end_layout
21529
21530 \begin_layout Standard
21531 SVN command: 
21532 \family typewriter
21533 svn revert -q 
21534 \begin_inset Quotes eld
21535 \end_inset
21536
21537 <file-name>
21538 \begin_inset Quotes erd
21539 \end_inset
21540
21541
21542 \end_layout
21543
21544 \begin_layout Subsubsection
21545
21546 \family sans
21547 Copy
21548 \end_layout
21549
21550 \begin_layout Standard
21551 This will create a copy of the current document including the version history.
21552  It requires a clean document without any changes since the last checkin.
21553  You are asked for a file name and a description of the copy operation.
21554  After that the copy is created, both locally and in the repository.
21555  If the parent directories of the copied and original document differ, all
21556  relative paths of included files of the copy are adjusted (like in 
21557 \family sans
21558 File\SpecialChar menuseparator
21559 Save As
21560 \family default
21561 \SpecialChar ldots
21562 ).
21563  Finally, the copy is loaded instead of the original document.
21564 \end_layout
21565
21566 \begin_layout Labeling
21567 \labelwidthstring 00.00.0000
21568 SVN
21569 \begin_inset space ~
21570 \end_inset
21571
21572 commands: 
21573 \begin_inset space ~
21574 \end_inset
21575
21576
21577 \begin_inset Newline newline
21578 \end_inset
21579
21580
21581 \begin_inset Flex Code
21582 status collapsed
21583
21584 \begin_layout Plain Layout
21585 svn copy -q 
21586 \family typewriter
21587
21588 \begin_inset Quotes eld
21589 \end_inset
21590
21591 <file-name>
21592 \begin_inset Quotes erd
21593 \end_inset
21594
21595  
21596 \begin_inset Quotes eld
21597 \end_inset
21598
21599 <new-file-name>
21600 \begin_inset Quotes erd
21601 \end_inset
21602
21603
21604 \end_layout
21605
21606 \end_inset
21607
21608
21609 \begin_inset Newline newline
21610 \end_inset
21611
21612
21613 \begin_inset Flex Code
21614 status collapsed
21615
21616 \begin_layout Plain Layout
21617 svn commit
21618 \end_layout
21619
21620 \end_inset
21621
21622
21623 \end_layout
21624
21625 \begin_layout Subsubsection
21626
21627 \family sans
21628 Rename
21629 \end_layout
21630
21631 \begin_layout Standard
21632 This will rename the current document including the version history.
21633  It requires a clean document without any changes since the last checkin.
21634  You are asked for a file name and a description of the rename operation.
21635  After that the document is renamed, both locally and in the repository.
21636  If the parent directories of the new and old file names differ, all relative
21637  paths of included files are adjusted (like in 
21638 \family sans
21639 File\SpecialChar menuseparator
21640 Save As
21641 \family default
21642 \SpecialChar ldots
21643 ).
21644  Finally, the document is reloaded using the new name.
21645 \end_layout
21646
21647 \begin_layout Labeling
21648 \labelwidthstring 00.00.0000
21649 SVN
21650 \begin_inset space ~
21651 \end_inset
21652
21653 commands: 
21654 \begin_inset space ~
21655 \end_inset
21656
21657
21658 \begin_inset Newline newline
21659 \end_inset
21660
21661
21662 \begin_inset Flex Code
21663 status collapsed
21664
21665 \begin_layout Plain Layout
21666 svn move -q 
21667 \family typewriter
21668
21669 \begin_inset Quotes eld
21670 \end_inset
21671
21672 <file-name>
21673 \begin_inset Quotes erd
21674 \end_inset
21675
21676  
21677 \begin_inset Quotes eld
21678 \end_inset
21679
21680 <new-file-name>
21681 \begin_inset Quotes erd
21682 \end_inset
21683
21684
21685 \end_layout
21686
21687 \end_inset
21688
21689
21690 \begin_inset Newline newline
21691 \end_inset
21692
21693
21694 \begin_inset Flex Code
21695 status collapsed
21696
21697 \begin_layout Plain Layout
21698 svn commit
21699 \end_layout
21700
21701 \end_inset
21702
21703
21704 \end_layout
21705
21706 \begin_layout Subsubsection
21707 \begin_inset CommandInset label
21708 LatexCommand label
21709 name "subsec:SVN-Repo-Update"
21710
21711 \end_inset
21712
21713 Update of the local directory checkout from repository
21714 \begin_inset Foot
21715 status collapsed
21716
21717 \begin_layout Plain Layout
21718 Note that this command will work only with subversion 
21719 \begin_inset Formula $\geqq1.5$
21720 \end_inset
21721
21722
21723 \end_layout
21724
21725 \end_inset
21726
21727
21728 \end_layout
21729
21730 \begin_layout Standard
21731 All the commands above have one shortcomming - they deal with the current
21732  document only.
21733  Once your document contains pictures, includes external 
21734 \begin_inset Flex Code
21735 status collapsed
21736
21737 \begin_layout Plain Layout
21738 .tex
21739 \end_layout
21740
21741 \end_inset
21742
21743  files and so on administration becomes more complicated.
21744  \SpecialChar LyX
21745  now supports updating the whole tree in which resides the document
21746 \begin_inset Foot
21747 status collapsed
21748
21749 \begin_layout Plain Layout
21750 One need to organize the files structure so that all external files are
21751  in the same directory or subdirectories of the document.
21752  
21753 \end_layout
21754
21755 \end_inset
21756
21757 .
21758  This become especially useful once you cooperate with people which neither
21759  know about subversion management nor they have ambition to commit additional
21760  material to the repository.
21761  
21762 \end_layout
21763
21764 \begin_layout Standard
21765 \begin_inset Flex Code
21766 status collapsed
21767
21768 \begin_layout Plain Layout
21769 Update local directory from repository
21770 \end_layout
21771
21772 \end_inset
21773
21774  command updates the whole directory and in case of merge conflicts local
21775  version of the files are left, so no unintended data loss occurs.
21776  If local changes are detected user is warned before update starts.
21777 \end_layout
21778
21779 \begin_layout Labeling
21780 \labelwidthstring 00.00.0000
21781 SVN
21782 \begin_inset space ~
21783 \end_inset
21784
21785 commands: 
21786 \begin_inset space ~
21787 \end_inset
21788
21789
21790 \begin_inset Newline newline
21791 \end_inset
21792
21793
21794 \begin_inset Flex Code
21795 status collapsed
21796
21797 \begin_layout Plain Layout
21798 svn diff $path
21799 \end_layout
21800
21801 \end_inset
21802
21803  (Ask if changes are detected.)
21804 \begin_inset Newline newline
21805 \end_inset
21806
21807
21808 \begin_inset Flex Code
21809 status collapsed
21810
21811 \begin_layout Plain Layout
21812 svn update –accept mine-full $path
21813 \end_layout
21814
21815 \end_inset
21816
21817
21818 \end_layout
21819
21820 \begin_layout Standard
21821 where 
21822 \begin_inset Flex Code
21823 status collapsed
21824
21825 \begin_layout Plain Layout
21826 $path
21827 \end_layout
21828
21829 \end_inset
21830
21831  stands for the path to the document.
21832 \end_layout
21833
21834 \begin_layout Subsubsection
21835
21836 \family sans
21837 Show History
21838 \end_layout
21839
21840 \begin_layout Standard
21841 This shows the complete history of the SVN document.
21842  The output of 
21843 \family typewriter
21844 svn log 
21845 \begin_inset Quotes eld
21846 \end_inset
21847
21848 <file-name>
21849 \begin_inset Quotes erd
21850 \end_inset
21851
21852
21853 \family default
21854  is shown in a browser.
21855 \end_layout
21856
21857 \begin_layout Subsubsection
21858 File Locking
21859 \begin_inset CommandInset label
21860 LatexCommand label
21861 name "subsec:SVN-File-Locking"
21862
21863 \end_inset
21864
21865
21866 \end_layout
21867
21868 \begin_layout Standard
21869 The file exchange through various revision control systems brings the problem
21870  of merge conflicts in case two different users try to edit the same (parts
21871  of) document.
21872  When such a conflict happens it needs manual resolving and one reasonable
21873  alternative is to provide some kind of locking mechanism, which guarantees
21874  that only one user is allowed to edit file at the given time.
21875 \end_layout
21876
21877 \begin_layout Standard
21878 SVN has two such mechanisms to provide mutual exclusivity for file access
21879  - locks and automatic setting of write permissions (see sec.
21880  
21881 \begin_inset CommandInset ref
21882 LatexCommand ref
21883 reference "subsec:Automatical-Locking-Property"
21884
21885 \end_inset
21886
21887 ) based on 
21888 \begin_inset Flex Code
21889 status collapsed
21890
21891 \begin_layout Plain Layout
21892 svn:needs-lock
21893 \end_layout
21894
21895 \end_inset
21896
21897  file svn property
21898 \begin_inset Foot
21899 status open
21900
21901 \begin_layout Plain Layout
21902 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
21903 \end_layout
21904
21905 \end_inset
21906
21907 .
21908  If this property is detected for a given document \SpecialChar LyX
21909  starts to use SVN locks
21910  for document editing automatically and the whole check-in/out mechanism
21911  switches to the same regimen as for RCS.
21912  This in particular means there are two different modes of file use in \SpecialChar LyX
21913 :
21914 \end_layout
21915
21916 \begin_layout Itemize
21917 Unlocked state.
21918  The loaded file is in the read-only mode.
21919  For editing on needs to check-out.
21920  
21921 \emph on
21922 Check-out
21923 \emph default
21924  consists of updating from the repository and gaining write lock.
21925  If the lock is not possible to obtain, we remain in unlocked state.
21926 \end_layout
21927
21928 \begin_layout Itemize
21929 Locked state.
21930  The loaded file is in the 'normal' edit mode.
21931  No other user is allowed to edit the file.
21932  
21933 \emph on
21934 Check-in
21935 \emph default
21936  consists of commiting changes and releasing write-lock.
21937  If no changes have been made to the document, no commit will be produced
21938 \begin_inset Foot
21939 status collapsed
21940
21941 \begin_layout Plain Layout
21942 Don't be puzzled by the fact that you will be asked for commit message anyway.
21943 \end_layout
21944
21945 \end_inset
21946
21947  and only the write-lock will be released.
21948 \end_layout
21949
21950 \begin_layout Standard
21951 SVN commands:
21952 \end_layout
21953
21954 \begin_layout Labeling
21955 \labelwidthstring 00.00.0000
21956 Check-in:
21957 \family typewriter
21958  svn commit -q -m"<description>" "<file-name>"
21959 \begin_inset Newline newline
21960 \end_inset
21961
21962 svn unlock "<file-name>"
21963 \end_layout
21964
21965 \begin_layout Labeling
21966 \labelwidthstring 00.00.0000
21967 Check-out: 
21968 \family typewriter
21969 svn update "<file-name>"
21970 \begin_inset Newline newline
21971 \end_inset
21972
21973 svn lock "<file-name>"
21974 \end_layout
21975
21976 \begin_layout Subsubsection
21977
21978 \family typewriter
21979 \begin_inset CommandInset label
21980 LatexCommand label
21981 name "subsec:Automatical-Locking-Property"
21982
21983 \end_inset
21984
21985
21986 \family default
21987 Automatic Locking Property
21988 \end_layout
21989
21990 \begin_layout Standard
21991 The above mentioned automatic setting of write permissions of the .lyx file
21992  can be set through
21993 \family sans
21994  File\SpecialChar menuseparator
21995 Version
21996 \begin_inset space ~
21997 \end_inset
21998
21999 Control\SpecialChar menuseparator
22000 Toggle locking property
22001 \family default
22002 .
22003  This command is active only when the file is not locked on the svn server
22004  (i.e.
22005  you need to check-out before proceeding).
22006 \end_layout
22007
22008 \begin_layout Labeling
22009 \labelwidthstring 00.00.0000
22010 SVN
22011 \begin_inset space ~
22012 \end_inset
22013
22014 commands:
22015 \end_layout
22016
22017 \begin_layout Labeling
22018 \labelwidthstring 00.00.0000
22019 Set:
22020 \family typewriter
22021  svn propset svn:needs-lock ON "<file-name>"
22022 \end_layout
22023
22024 \begin_layout Labeling
22025 \labelwidthstring 00.00.0000
22026 Unset: 
22027 \family typewriter
22028 svn propdel svn:needs-lock "<file-name>"
22029 \end_layout
22030
22031 \begin_layout Subsubsection
22032 \begin_inset CommandInset label
22033 LatexCommand label
22034 name "subsec:VCS-Revision-Information"
22035
22036 \end_inset
22037
22038 Revision Information in Documents
22039 \end_layout
22040
22041 \begin_layout Standard
22042 There are more possibilities how to activate revision information in our
22043  document.
22044 \end_layout
22045
22046 \begin_layout Itemize
22047 \SpecialChar LyX
22048  supports directly:
22049 \end_layout
22050
22051 \begin_deeper
22052 \begin_layout Itemize
22053 tree revision information (
22054 \begin_inset Flex Code
22055 status collapsed
22056
22057 \begin_layout Plain Layout
22058 vcs-tree-revision
22059 \end_layout
22060
22061 \end_inset
22062
22063 ).
22064  The result is the output of the 
22065 \begin_inset Flex Code
22066 status collapsed
22067
22068 \begin_layout Plain Layout
22069 svnversion
22070 \end_layout
22071
22072 \end_inset
22073
22074  command, the following table gives you an idea, how to read the results.
22075 \end_layout
22076
22077 \begin_layout Standard
22078 \align center
22079 \begin_inset Tabular
22080 <lyxtabular version="3" rows="6" columns="2">
22081 <features tabularvalignment="middle">
22082 <column alignment="center" valignment="top">
22083 <column alignment="center" valignment="top">
22084 <row>
22085 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
22086 \begin_inset Text
22087
22088 \begin_layout Plain Layout
22089 Output
22090 \end_layout
22091
22092 \end_inset
22093 </cell>
22094 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
22095 \begin_inset Text
22096
22097 \begin_layout Plain Layout
22098 Meaning
22099 \end_layout
22100
22101 \end_inset
22102 </cell>
22103 </row>
22104 <row>
22105 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22106 \begin_inset Text
22107
22108 \begin_layout Plain Layout
22109 4123:4168
22110 \end_layout
22111
22112 \end_inset
22113 </cell>
22114 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22115 \begin_inset Text
22116
22117 \begin_layout Plain Layout
22118 mixed revision working copy
22119 \end_layout
22120
22121 \end_inset
22122 </cell>
22123 </row>
22124 <row>
22125 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22126 \begin_inset Text
22127
22128 \begin_layout Plain Layout
22129 4168M
22130 \end_layout
22131
22132 \end_inset
22133 </cell>
22134 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22135 \begin_inset Text
22136
22137 \begin_layout Plain Layout
22138 modified working copy
22139 \end_layout
22140
22141 \end_inset
22142 </cell>
22143 </row>
22144 <row>
22145 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22146 \begin_inset Text
22147
22148 \begin_layout Plain Layout
22149 4123S
22150 \end_layout
22151
22152 \end_inset
22153 </cell>
22154 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22155 \begin_inset Text
22156
22157 \begin_layout Plain Layout
22158 switched working copy
22159 \end_layout
22160
22161 \end_inset
22162 </cell>
22163 </row>
22164 <row>
22165 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22166 \begin_inset Text
22167
22168 \begin_layout Plain Layout
22169 4123P
22170 \end_layout
22171
22172 \end_inset
22173 </cell>
22174 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22175 \begin_inset Text
22176
22177 \begin_layout Plain Layout
22178 partial working copy, from a sparse checkout
22179 \end_layout
22180
22181 \end_inset
22182 </cell>
22183 </row>
22184 <row>
22185 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
22186 \begin_inset Text
22187
22188 \begin_layout Plain Layout
22189 4123:4168MS
22190 \end_layout
22191
22192 \end_inset
22193 </cell>
22194 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
22195 \begin_inset Text
22196
22197 \begin_layout Plain Layout
22198 mixed revision, modified, switched working copy
22199 \end_layout
22200
22201 \end_inset
22202 </cell>
22203 </row>
22204 </lyxtabular>
22205
22206 \end_inset
22207
22208
22209 \end_layout
22210
22211 \begin_layout Itemize
22212 file revision information.
22213  The result comes from parsing the output of 
22214 \begin_inset Flex Code
22215 status collapsed
22216
22217 \begin_layout Plain Layout
22218 svn
22219 \begin_inset space ~
22220 \end_inset
22221
22222 info
22223 \begin_inset space ~
22224 \end_inset
22225
22226 –xml
22227 \begin_inset space ~
22228 \end_inset
22229
22230 file.lyx
22231 \end_layout
22232
22233 \end_inset
22234
22235 .
22236  Supported flags are:
22237 \end_layout
22238
22239 \begin_deeper
22240 \begin_layout Itemize
22241 version number of the last commit (
22242 \begin_inset Flex Code
22243 status collapsed
22244
22245 \begin_layout Plain Layout
22246 vcs-revision
22247 \end_layout
22248
22249 \end_inset
22250
22251 )
22252 \end_layout
22253
22254 \begin_layout Itemize
22255 author of the last commit (
22256 \begin_inset Flex Code
22257 status collapsed
22258
22259 \begin_layout Plain Layout
22260 vcs-author
22261 \end_layout
22262
22263 \end_inset
22264
22265 )
22266 \end_layout
22267
22268 \begin_layout Itemize
22269 date of the last commit (
22270 \begin_inset Flex Code
22271 status collapsed
22272
22273 \begin_layout Plain Layout
22274 vcs-date
22275 \end_layout
22276
22277 \end_inset
22278
22279 )
22280 \end_layout
22281
22282 \begin_layout Itemize
22283 time of the last commit (
22284 \begin_inset Flex Code
22285 status collapsed
22286
22287 \begin_layout Plain Layout
22288 vcs-time
22289 \end_layout
22290
22291 \end_inset
22292
22293 )
22294 \end_layout
22295
22296 \end_deeper
22297 \begin_layout Standard
22298 You can obtain this info via InsetInfo (e.g.
22299  
22300 \begin_inset Flex Code
22301 status collapsed
22302
22303 \begin_layout Plain Layout
22304 info-insert buffer vcs-date
22305 \end_layout
22306
22307 \end_inset
22308
22309 ).
22310  The information will be available only when you have the file stored under
22311  svn managment (i.e.
22312  the 
22313 \begin_inset Flex Code
22314 status collapsed
22315
22316 \begin_layout Plain Layout
22317 .svn
22318 \end_layout
22319
22320 \end_inset
22321
22322  directory is available with your document).
22323 \end_layout
22324
22325 \end_deeper
22326 \begin_layout Itemize
22327 Another—a hacking one—possibility is to use svn keywords
22328 \begin_inset Foot
22329 status collapsed
22330
22331 \begin_layout Plain Layout
22332 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
22333 \end_layout
22334
22335 \end_inset
22336
22337 .
22338  In short – you set file keywords property (e.g.
22339  
22340 \family sans
22341 svn propset svn:keywords 'Rev' file.lyx
22342 \family default
22343 ) and then paste keyword \SpecialChar TeX
22344  code
22345 \begin_inset Foot
22346 status collapsed
22347
22348 \begin_layout Plain Layout
22349 This is an easy way how to ensure that \SpecialChar LyX
22350  won't break the line in the middle
22351  of keyword tag.
22352 \end_layout
22353
22354 \end_inset
22355
22356  tag in your document (e.g.
22357  
22358 \begin_inset ERT
22359 status open
22360
22361 \begin_layout Plain Layout
22362
22363 $Rev$
22364 \end_layout
22365
22366 \end_inset
22367
22368 ).
22369  This way svn client will automatically substitute revision number (e.g.
22370  
22371 \begin_inset ERT
22372 status open
22373
22374 \begin_layout Plain Layout
22375
22376 $Rev: 59 $
22377 \end_layout
22378
22379 \end_inset
22380
22381 ) after each update and commit.
22382  There are more problems with this approach.
22383  Firstly, the '$' character is used in \SpecialChar TeX
22384  world for math equations, so any
22385  occurence of math formula 
22386 \begin_inset Formula $Rev$
22387 \end_inset
22388
22389  become 
22390 \begin_inset Formula $Rev:59$
22391 \end_inset
22392
22393  in your \SpecialChar LyX
22394  document.
22395  Similarly for other keywords like Id, Date, Author, etc.
22396  Secondly svn output is dependent on your locales, so its very easy that
22397  svn would produce some problematic strings once Date is used.
22398  Thirdly you get the whole 'Rev: 59' string in your document instead of
22399  the plain number.
22400  Until subversion implements user's custom keywords it will be hard to use
22401  this approach reliably or let \SpecialChar LyX
22402  to support it directly.
22403 \end_layout
22404
22405 \begin_layout Subsection
22406 SVN and Windows Environment
22407 \end_layout
22408
22409 \begin_layout Quote
22410 My inclination is to say that if the user cannot figure out the command
22411  line operations on their own fairly quickly, they would be well advised
22412  to use TortoiseSVN.
22413  —P.
22414  A.
22415  Rubin
22416 \end_layout
22417
22418 \begin_layout Subsubsection
22419 Preparation
22420 \end_layout
22421
22422 \begin_layout Standard
22423 In addition to installing \SpecialChar LyX
22424 , and having access to a Subversion repository,
22425  the user will need to install the Subversion client program.
22426  A Windows installer for the client program is available from 
22427 \begin_inset CommandInset href
22428 LatexCommand href
22429 name "CollabNet"
22430 target "http://www.collab.net/nonav/downloads/subversion/"
22431 literal "false"
22432
22433 \end_inset
22434
22435 .
22436  The user may also want to install 
22437 \begin_inset CommandInset href
22438 LatexCommand href
22439 name "TortoiseSVN"
22440 target "http://tortoisesvn.tigris.org/"
22441 literal "false"
22442
22443 \end_inset
22444
22445 , which integrates Subversion operations into the context (rightclick) menu
22446  of Windows Explorer.
22447  Operations done outside \SpecialChar LyX
22448  will typically be more convenient using the Explorer
22449  context menu.
22450  Note that TortoiseSVN is not a replacement for the client program, which
22451  is what \SpecialChar LyX
22452  itself will use.
22453 \end_layout
22454
22455 \begin_layout Subsubsection
22456 Bringing a document under Subversion control
22457 \end_layout
22458
22459 \begin_layout Standard
22460 Before a \SpecialChar LyX
22461  document can be brought under version control in Subversion, its
22462  parent directory needs to be under version control.
22463  If the document is being added to a project already in the repository,
22464  this is accomplished by checking the project out to the directory where
22465  the new document will be placed.
22466  If the project itself is not yet under version control (for instance, if
22467  this document starts a new project), the directory must be imported into
22468  the repository.
22469  This is done outside \SpecialChar LyX
22470 .
22471  Both import and checkout are easily accomplished from the Explorer context
22472  menu using TortoiseSVN, or alternatively can be done using the command
22473  line client at a DOS prompt.
22474  The procedure for importing the project using TortoiseSVN is described
22475  below, assuming an existing repository and a new project being started
22476  in 
22477 \family typewriter
22478 C:
22479 \backslash
22480 new project
22481 \family default
22482 .
22483  For information on using the Subversion client program, run 
22484 \family typewriter
22485 svn --help 
22486 \family default
22487 in a DOS shell.
22488 \end_layout
22489
22490 \begin_layout Enumerate
22491 Locate 
22492 \family typewriter
22493 C:
22494 \backslash
22495 new project 
22496 \family default
22497 in Windows Explorer, right click it, and select 
22498 \family sans
22499 TortoiseSVN\SpecialChar menuseparator
22500 Repo-browser
22501 \family default
22502 .
22503  If necessary, adjust the URL for the repository, then click OK.
22504 \end_layout
22505
22506 \begin_layout Enumerate
22507 Right click the level of the repository under which you want to place the
22508  new project folder (typically the top level) and click 
22509 \family sans
22510 Create folder
22511 \family default
22512  Supply a name for the project folder and click OK.
22513  Add a message for the log file if desired, then click OK again.
22514  The new project folder should appear in the repository.
22515  Finally, click OK again to exit the repository browser.
22516 \end_layout
22517
22518 \begin_layout Enumerate
22519 Once again right click 
22520 \family typewriter
22521 C:
22522 \backslash
22523 new project
22524 \family default
22525 , this time selecting SVN Checkout\SpecialChar ldots
22526  Select the URL of the project folder
22527  you just created in the repository, and set the checkout directory to 
22528 \family typewriter
22529 C:
22530 \backslash
22531 new project.
22532
22533 \family default
22534  Click OK.
22535  You will be warned about a non-empty folder; click OK to proceed.
22536  You should now have a 
22537 \family typewriter
22538 .svn
22539 \family default
22540  directory under 
22541 \family typewriter
22542 C:
22543 \backslash
22544 new project.
22545 \end_layout
22546
22547 \begin_layout Enumerate
22548 Create or open your document in \SpecialChar LyX
22549  and click 
22550 \family sans
22551 File\SpecialChar menuseparator
22552 Version
22553 \begin_inset space ~
22554 \end_inset
22555
22556 Control\SpecialChar menuseparator
22557 Register.
22558  
22559 \family default
22560 Add a log message and click OK to commit the document to version control.
22561 \end_layout
22562
22563 \begin_layout Standard
22564 From this point onward, you should have full functionality in the 
22565 \family sans
22566 File\SpecialChar menuseparator
22567 Version
22568 \begin_inset space ~
22569 \end_inset
22570
22571 Control
22572 \family default
22573  menu.
22574  You also have the option of checking the document in and out, viewing its
22575  history, etc.
22576  using the TortoiseSVN context menu in Windows Explorer or the Subversion
22577  client program from a command prompt.
22578 \end_layout
22579
22580 \begin_layout Subsubsection
22581 SSH tunnel used with SVN under Windows
22582 \end_layout
22583
22584 \begin_layout Standard
22585 Compared with Linux setting up an svn client to communicate over ssh under
22586  Windows is a rather troublesome task.
22587  We will at least offer some hints how to setup the client side but prior
22588  knowledge about ssh and the Windows command line is needed, also be prepared
22589  for a great deal of frustration\SpecialChar ldots
22590
22591 \end_layout
22592
22593 \begin_layout Enumerate
22594 Get an svn client for windows, as described in the previous sections.
22595  When it is a fresh install run some svn command (e.g.
22596  
22597 \begin_inset Flex Code
22598 status collapsed
22599
22600 \begin_layout Plain Layout
22601 svn –version
22602 \end_layout
22603
22604 \end_inset
22605
22606 ) to create config files, which you will need to change later on.
22607 \end_layout
22608
22609 \begin_layout Enumerate
22610 Choose an ssh client for Windows.
22611  There are several possibilities, we will use the one from Putty tools
22612 \begin_inset Foot
22613 status collapsed
22614
22615 \begin_layout Plain Layout
22616 \begin_inset Flex URL
22617 status collapsed
22618
22619 \begin_layout Plain Layout
22620
22621 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
22622 \end_layout
22623
22624 \end_inset
22625
22626
22627 \end_layout
22628
22629 \end_inset
22630
22631 .
22632  You will need to set the connection up so that the client doesn't ask for
22633  any password from you.
22634  To keep things easy we will use only keys without any additional password
22635  protection etc.
22636 \end_layout
22637
22638 \begin_deeper
22639 \begin_layout Enumerate
22640 Generate keys by 
22641 \begin_inset Flex Code
22642 status collapsed
22643
22644 \begin_layout Plain Layout
22645 puttygen
22646 \end_layout
22647
22648 \end_inset
22649
22650 .
22651  Save your private .ppk key file and put the public one on the server side.
22652  If the SVN server runs on Linux, note that the format of the public key
22653  is not compatible with Linux openssh and you will need to direcly copy-paste
22654  the key from the “
22655 \emph on
22656 Public key for pasting into OpenSSH authorized_keys file
22657 \emph default
22658 :” edit field into the server's 
22659 \begin_inset Flex Code
22660 status collapsed
22661
22662 \begin_layout Plain Layout
22663 ~/.ssh/authorized_keys
22664 \end_layout
22665
22666 \end_inset
22667
22668  / 
22669 \begin_inset Flex Code
22670 status collapsed
22671
22672 \begin_layout Plain Layout
22673 authorized_keys2
22674 \end_layout
22675
22676 \end_inset
22677
22678  file.
22679 \end_layout
22680
22681 \begin_layout Enumerate
22682 Get the Putty's 
22683 \begin_inset Flex Code
22684 status collapsed
22685
22686 \begin_layout Plain Layout
22687 plink
22688 \end_layout
22689
22690 \end_inset
22691
22692 .
22693  In the SVN config file
22694 \begin_inset Foot
22695 status collapsed
22696
22697 \begin_layout Plain Layout
22698 Exact path depends on Windows version, usually somewhere around 
22699 \begin_inset Flex Code
22700 status collapsed
22701
22702 \begin_layout Plain Layout
22703 c:
22704 \backslash
22705 Documents and Settings
22706 \backslash
22707 user
22708 \backslash
22709 Application Data
22710 \backslash
22711 Subversion
22712 \backslash
22713 config
22714 \end_layout
22715
22716 \end_inset
22717
22718  / 
22719 \begin_inset Flex Code
22720 status collapsed
22721
22722 \begin_layout Plain Layout
22723 AppData
22724 \backslash
22725 Roaming
22726 \backslash
22727 Subversion
22728 \end_layout
22729
22730 \end_inset
22731
22732 .
22733 \end_layout
22734
22735 \end_inset
22736
22737 , section [tunnels], setup ssh command, e.g.
22738  
22739 \begin_inset Flex Code
22740 status collapsed
22741
22742 \begin_layout Plain Layout
22743 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
22744 \end_layout
22745
22746 \end_inset
22747
22748 .
22749 \begin_inset Foot
22750 status collapsed
22751
22752 \begin_layout Plain Layout
22753 It will usually take a lot of time to get exact command right and it depends
22754  on many things.
22755  For example do not have some remote server saved as a default session in
22756  Putty etc.
22757  If things fail, try to connect via plink without SVN first.
22758 \end_layout
22759
22760 \end_inset
22761
22762
22763 \end_layout
22764
22765 \end_deeper
22766 \begin_layout Enumerate
22767 Checkout the SVN archive, e.
22768 \begin_inset space \thinspace{}
22769 \end_inset
22770
22771 g.
22772 \begin_inset Newline newline
22773 \end_inset
22774
22775
22776 \begin_inset Flex Code
22777 status collapsed
22778
22779 \begin_layout Plain Layout
22780 svn co svn+ssh://user@server/repository_path
22781 \end_layout
22782
22783 \end_inset
22784
22785 .
22786 \end_layout
22787
22788 \begin_layout Subsubsection
22789 End-of-Line Conversions
22790 \end_layout
22791
22792 \begin_layout Standard
22793 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
22794  will
22795  use different line endings inside the .lyx files.
22796  This is not a problem as far as \SpecialChar LyX
22797  functionality is concerned, but the commit
22798  diffs will be huge and merge-conflicts prone.
22799  Fortunately SVN itself knows
22800 \begin_inset Foot
22801 status collapsed
22802
22803 \begin_layout Plain Layout
22804 \begin_inset Flex URL
22805 status collapsed
22806
22807 \begin_layout Plain Layout
22808
22809 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
22810 \end_layout
22811
22812 \end_inset
22813
22814
22815 \end_layout
22816
22817 \end_inset
22818
22819  how to deal with CR/LF problems when switching .lyx files to the 
22820 \begin_inset Flex Code
22821 status collapsed
22822
22823 \begin_layout Plain Layout
22824 native
22825 \end_layout
22826
22827 \end_inset
22828
22829  mode.
22830 \begin_inset Foot
22831 status collapsed
22832
22833 \begin_layout Plain Layout
22834 For the lazy guys: 
22835 \begin_inset Flex Code
22836 status collapsed
22837
22838 \begin_layout Plain Layout
22839 svn propset svn:eol-style native FILE_NAME
22840 \end_layout
22841
22842 \end_inset
22843
22844
22845 \end_layout
22846
22847 \end_inset
22848
22849
22850 \end_layout
22851
22852 \begin_layout Subsection
22853 GIT commands in \SpecialChar LyX
22854
22855 \end_layout
22856
22857 \begin_layout Standard
22858 A minimal subset of GIT commands is now supported by \SpecialChar LyX
22859 .
22860  You can find the commands in the 
22861 \family sans
22862 File\SpecialChar menuseparator
22863 Version
22864 \begin_inset space ~
22865 \end_inset
22866
22867 Control
22868 \family default
22869  submenu.
22870  Please note that if you use password protected access to repository via
22871  ssh, you will be asked in terminal window.
22872  \SpecialChar LyX
22873  was tested against GIT 1.7.
22874 \begin_inset Foot
22875 status open
22876
22877 \begin_layout Plain Layout
22878 Windows users please note that you need to ensure that git is on the path.
22879  This can be set from within \SpecialChar LyX
22880  at 
22881 \family sans
22882 Tools\SpecialChar menuseparator
22883 Preferences\SpecialChar menuseparator
22884 Paths\SpecialChar menuseparator
22885 PATH prefix
22886 \family default
22887 .
22888 \end_layout
22889
22890 \end_inset
22891
22892
22893 \end_layout
22894
22895 \begin_layout Standard
22896 One big difference of GIT and the other supported version control systems
22897  is the distributed nature of GIT: With traditional version control systems
22898  there is one central server which hosts the repository.
22899  Users commit their changes to the server, and get updates made by other
22900  users from it.
22901  With GIT, users commit to a local repository.
22902  The local repository can be synchronized with one or more remote repositories
22903  using the 
22904 \begin_inset Flex Code
22905 status collapsed
22906
22907 \begin_layout Plain Layout
22908 pull
22909 \end_layout
22910
22911 \end_inset
22912
22913  and 
22914 \begin_inset Flex Code
22915 status collapsed
22916
22917 \begin_layout Plain Layout
22918 push
22919 \end_layout
22920
22921 \end_inset
22922
22923  GIT commands.
22924  \SpecialChar LyX
22925  does not interact in any way with remote GIT repositories.
22926  It works exclusively with the local repository in a very similar way as
22927  with a central CVS or SVN repository.
22928  If you use remote GIT repositories you need to do the 
22929 \begin_inset Flex Code
22930 status collapsed
22931
22932 \begin_layout Plain Layout
22933 pull
22934 \end_layout
22935
22936 \end_inset
22937
22938  and 
22939 \begin_inset Flex Code
22940 status collapsed
22941
22942 \begin_layout Plain Layout
22943 push
22944 \end_layout
22945
22946 \end_inset
22947
22948  operations with your favourite GIT client.
22949 \end_layout
22950
22951 \begin_layout Subsubsection
22952
22953 \family sans
22954 Register
22955 \end_layout
22956
22957 \begin_layout Standard
22958 If your document is not under revision control, this is the only item shown
22959  in the menu.
22960  And if it is under revision control, the 
22961 \family sans
22962 Register
22963 \family default
22964  item is not visible.
22965 \end_layout
22966
22967 \begin_layout Standard
22968 This command registers in GIT your document ONLY in case you have already
22969  the documents directory under GIT control (in particular 
22970 \family typewriter
22971 .git/index
22972 \family default
22973  file exists).
22974  This means you have to checkout the archive by yourself.
22975 \end_layout
22976
22977 \begin_layout Standard
22978 Then you are asked interactively to supply an initial description of the
22979  document.
22980  Don't forget that registered file is not yet commited.
22981 \end_layout
22982
22983 \begin_layout Standard
22984 GIT command that is run: 
22985 \family typewriter
22986 git add 
22987 \begin_inset Quotes eld
22988 \end_inset
22989
22990 <file-name>
22991 \begin_inset Quotes erd
22992 \end_inset
22993
22994
22995 \end_layout
22996
22997 \begin_layout Standard
22998 Read 
22999 \family typewriter
23000 man git
23001 \family default
23002  to understand the switches.
23003 \end_layout
23004
23005 \begin_layout Subsubsection
23006
23007 \family sans
23008 Check In Changes
23009 \end_layout
23010
23011 \begin_layout Standard
23012 When you are finished editing a file, you commit your changes.
23013  When you do this, you are asked for a description of the changes.
23014  After that changes are commited.
23015 \end_layout
23016
23017 \begin_layout Standard
23018 GIT command: 
23019 \family typewriter
23020 git commit -q -m"<description>" <file-name>
23021 \end_layout
23022
23023 \begin_layout Subsubsection
23024
23025 \family sans
23026 Revert To Repository Version
23027 \end_layout
23028
23029 \begin_layout Standard
23030 This will discard all changes made to the document since the last check
23031  in.
23032  You get a warning before changes are discarded.
23033 \end_layout
23034
23035 \begin_layout Standard
23036 GIT command: 
23037 \family typewriter
23038 git checkout -q 
23039 \begin_inset Quotes eld
23040 \end_inset
23041
23042 <file-name>
23043 \begin_inset Quotes erd
23044 \end_inset
23045
23046
23047 \end_layout
23048
23049 \begin_layout Subsubsection
23050
23051 \family sans
23052 Rename
23053 \end_layout
23054
23055 \begin_layout Standard
23056 This will rename the current document including the version history.
23057  It requires a clean document without any changes since the last checkin.
23058  You are asked for a file name and a description of the rename operation.
23059  After that the document is renamed, both locally and in the repository.
23060  If the parent directories of the new and old file names differ, all relative
23061  paths of included files are adjusted (like in 
23062 \family sans
23063 File\SpecialChar menuseparator
23064 Save As
23065 \family default
23066 \SpecialChar ldots
23067 ).
23068  Finally, the document is reloaded using the new name.
23069 \end_layout
23070
23071 \begin_layout Labeling
23072 \labelwidthstring 00.00.0000
23073 GIT
23074 \begin_inset space ~
23075 \end_inset
23076
23077 commands: 
23078 \begin_inset space ~
23079 \end_inset
23080
23081
23082 \begin_inset Newline newline
23083 \end_inset
23084
23085
23086 \begin_inset Flex Code
23087 status collapsed
23088
23089 \begin_layout Plain Layout
23090 git mv 
23091 \family typewriter
23092
23093 \begin_inset Quotes eld
23094 \end_inset
23095
23096 <file-name>
23097 \begin_inset Quotes erd
23098 \end_inset
23099
23100  
23101 \begin_inset Quotes eld
23102 \end_inset
23103
23104 <new-file-name>
23105 \begin_inset Quotes erd
23106 \end_inset
23107
23108
23109 \end_layout
23110
23111 \end_inset
23112
23113
23114 \begin_inset Newline newline
23115 \end_inset
23116
23117
23118 \begin_inset Flex Code
23119 status collapsed
23120
23121 \begin_layout Plain Layout
23122 git commit
23123 \end_layout
23124
23125 \end_inset
23126
23127
23128 \end_layout
23129
23130 \begin_layout Subsubsection
23131
23132 \family sans
23133 Show History
23134 \end_layout
23135
23136 \begin_layout Standard
23137 This shows the complete history of the GIT document.
23138  The output of 
23139 \family typewriter
23140 git log 
23141 \begin_inset Quotes eld
23142 \end_inset
23143
23144 <file-name>
23145 \begin_inset Quotes erd
23146 \end_inset
23147
23148
23149 \family default
23150  is shown in a browser.
23151 \end_layout
23152
23153 \begin_layout Subsubsection
23154 Version Info
23155 \end_layout
23156
23157 \begin_layout Standard
23158 \SpecialChar LyX
23159  supports GIT hash number of the last commit to the file, author name, date
23160  and time of last commit.
23161  All those are extracted from 
23162 \family typewriter
23163 git log -n 1 --pretty=format:%H%n%an%n%ai
23164 \family default
23165 .
23166  Tree version information is obtained via 
23167 \family typewriter
23168 git describe --abbrev --dirty --long
23169 \family default
23170 .
23171  See 
23172 \begin_inset CommandInset ref
23173 LatexCommand ref
23174 reference "subsec:VCS-Revision-Information"
23175
23176 \end_inset
23177
23178  for other details.
23179 \end_layout
23180
23181 \begin_layout Subsection
23182 Further tuning
23183 \end_layout
23184
23185 \begin_layout Standard
23186 With the recent addition of the vc-command function \SpecialChar LyX
23187  power users are allowed
23188  to create their own commands for revision control.
23189 \end_layout
23190
23191 \begin_layout Standard
23192 As an example you can see how two TortoiseSVN commands could be integrated
23193  directly:
23194 \end_layout
23195
23196 \begin_layout Description
23197 Commit: 
23198 \begin_inset Flex Code
23199 status collapsed
23200
23201 \begin_layout Plain Layout
23202 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
23203 \end_layout
23204
23205 \end_inset
23206
23207
23208 \end_layout
23209
23210 \begin_layout Description
23211 Revert: 
23212 \begin_inset Flex Code
23213 status collapsed
23214
23215 \begin_layout Plain Layout
23216 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
23217 \end_layout
23218
23219 \end_inset
23220
23221
23222 \end_layout
23223
23224 \begin_layout Subsection
23225 Version control and Document comparison
23226 \end_layout
23227
23228 \begin_layout Standard
23229 One of the typical uses of version control is to inspect the changes between
23230  revisions, usually by creating 
23231 \begin_inset Flex Code
23232 status collapsed
23233
23234 \begin_layout Plain Layout
23235 diff
23236 \end_layout
23237
23238 \end_inset
23239
23240  dumps.
23241  While this is useful for plain text files, it is much less useful in the
23242  case of \SpecialChar LyX
23243  files, which have more a complicated structure.
23244  Hence we provide binding to the Document comparison feature.
23245  There are two ways of calling this feature - either by direct call of 
23246 \begin_inset Flex Code
23247 status collapsed
23248
23249 \begin_layout Plain Layout
23250 VC_COMPARE
23251 \end_layout
23252
23253 \end_inset
23254
23255  \SpecialChar LyX
23256  function (for details see \SpecialChar LyX
23257  functions manual) or by icon/menu item 
23258 \begin_inset Flex Noun
23259 status collapsed
23260
23261 \begin_layout Plain Layout
23262 Compare with older revision...
23263 \end_layout
23264
23265 \end_inset
23266
23267 .
23268  One can either compare two chosen revisions of the document or he can simply
23269  compare the current version of edited text with older revisions (where
23270  '
23271 \begin_inset Flex Noun
23272 status collapsed
23273
23274 \begin_layout Plain Layout
23275 0
23276 \end_layout
23277
23278 \end_inset
23279
23280 ' revisions back means comparison of the edited file with last commited
23281  revision).
23282  
23283 \end_layout
23284
23285 \begin_layout Standard
23286 This feature is supported for SVN and RCS though due to the more complicated
23287  versioning scheme of RCS there is a constraint – when addressing the revisions
23288  in dialog, numbers always point to the last number in RCS revision number,
23289  i.e.
23290  '35' in '1.2.35'.
23291  We don't currently support GIT addressing of revisions, one can just compare
23292  edited document with its revision X steps backs, where X is addressed as
23293  HEAD~X.
23294 \end_layout
23295
23296 \begin_layout Section
23297 Literate Programming
23298 \end_layout
23299
23300 \begin_layout Standard
23301 Updated by 
23302 \noun on
23303 Kayvan Sylvan 
23304 \noun default
23305 (kayvan@sylvan.com)
23306 \noun on
23307
23308 \noun default
23309 original documentation written by 
23310 \noun on
23311 Edmar Wienskoski Jr.
23312
23313 \noun default
23314  (edmar-w-jr@technologist.com)
23315 \end_layout
23316
23317 \begin_layout Subsection
23318 Introduction
23319 \end_layout
23320
23321 \begin_layout Standard
23322 The main purpose of this documentation is to show you how to use \SpecialChar LyX
23323  for literate
23324  programming, where it is assumed that you are familiar with this programming
23325  technique, and know what 
23326 \begin_inset Quotes eld
23327 \end_inset
23328
23329 tangling
23330 \begin_inset Quotes erd
23331 \end_inset
23332
23333  and 
23334 \begin_inset Quotes eld
23335 \end_inset
23336
23337 weaving
23338 \begin_inset Quotes erd
23339 \end_inset
23340
23341  means.
23342  If that is not the case, please follow the web links provided in the following
23343  sections.
23344  There is a lot of good documentation out there covering old development
23345  history to the latest tools tips.
23346 \end_layout
23347
23348 \begin_layout Standard
23349 It is also assumed that you are familiar with \SpecialChar LyX
23350  itself to a point that you
23351  are comfortable changing your \SpecialChar LyX
23352  preferences, and X resources file.
23353  If that is not the case please refer to other \SpecialChar LyX
23354  documentation to cover your
23355  specific needs.
23356 \end_layout
23357
23358 \begin_layout Subsection
23359 Literate Programming
23360 \end_layout
23361
23362 \begin_layout Standard
23363 From the Literate Programming FAQ: 
23364 \end_layout
23365
23366 \begin_layout Quotation
23367 Literate programming is the combination of documentation and source together
23368  in a fashion suited for reading by human beings.
23369  In fact, literate programs should be enjoyable reading, even inviting!
23370  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
23371  and documentation in a single file.
23372  Literate programming tools then parse the file to produce either readable
23373  documentation or compilable source.
23374  The WEB style of literate programming was created by D.
23375 \begin_inset space \thinspace{}
23376 \end_inset
23377
23378 E.
23379  Knuth during the development of his \SpecialChar TeX
23380  typesetting software.
23381  
23382 \end_layout
23383
23384 \begin_layout Standard
23385 Another excerpt says:
23386 \end_layout
23387
23388 \begin_layout Quotation
23389
23390 \emph on
23391 How is literate programming different from verbose commenting?
23392 \end_layout
23393
23394 \begin_layout Quotation
23395 There are three distinguishing characteristics.
23396  In order of importance, they are: 
23397 \end_layout
23398
23399 \begin_deeper
23400 \begin_layout Itemize
23401 flexible order of elaboration 
23402 \end_layout
23403
23404 \begin_layout Itemize
23405 automatic support for browsing 
23406 \end_layout
23407
23408 \begin_layout Itemize
23409 typeset documentation, especially diagrams and mathematics 
23410 \end_layout
23411
23412 \end_deeper
23413 \begin_layout Standard
23414 Now that I sparked your curiosity, take a look in the references.
23415 \end_layout
23416
23417 \begin_layout Subsubsection
23418 References
23419 \end_layout
23420
23421 \begin_layout Standard
23422 The complete Literate Programming FAQ can be found at:
23423 \end_layout
23424
23425 \begin_layout Quote
23426 Literate Programming FAQ 
23427 \begin_inset Flex URL
23428 status collapsed
23429
23430 \begin_layout Plain Layout
23431
23432 http://www.literateprogramming.com/lpfaq.pdf
23433 \end_layout
23434
23435 \end_inset
23436
23437
23438 \end_layout
23439
23440 \begin_layout Standard
23441 The FAQ lists 23 (twenty three!) different literate programming tools.
23442  Where some are specialized or 
23443 \begin_inset Quotes eld
23444 \end_inset
23445
23446 tailored
23447 \begin_inset Quotes erd
23448 \end_inset
23449
23450  for particular programming languages, while other have general scope.
23451  I selected 
23452 \noun on
23453 Noweb
23454 \noun default
23455  for my own use for several reasons:
23456 \end_layout
23457
23458 \begin_layout Itemize
23459 It can generate the documentation either in \SpecialChar LaTeX
23460  or HTML.
23461 \end_layout
23462
23463 \begin_layout Itemize
23464 It has a open architecture, i.
23465 \begin_inset space \thinspace{}
23466 \end_inset
23467
23468 e.
23469 \begin_inset space \space{}
23470 \end_inset
23471
23472 it is easy to plug in new filters and to perform special processing that
23473  you may need.
23474  
23475 \end_layout
23476
23477 \begin_layout Itemize
23478 There is a good selection of filters available already (the HTML is one
23479  of them).
23480 \end_layout
23481
23482 \begin_layout Itemize
23483 It is free.
23484 \end_layout
23485
23486 \begin_layout Standard
23487 The Noweb web page can be found at: 
23488 \end_layout
23489
23490 \begin_layout Quote
23491 Noweb home page 
23492 \begin_inset Flex URL
23493 status collapsed
23494
23495 \begin_layout Plain Layout
23496
23497 http://www.cs.virginia.edu/~nr/noweb/
23498 \end_layout
23499
23500 \end_inset
23501
23502
23503 \end_layout
23504
23505 \begin_layout Standard
23506 Starting from there you can reach many other interesting links and even
23507  some literate program examples.
23508 \end_layout
23509
23510 \begin_layout Subsection
23511 \SpecialChar LyX
23512  and Literate Programming with Noweb
23513 \end_layout
23514
23515 \begin_layout Standard
23516 The \SpecialChar LyX
23517  support for Literate Programming is provided by using the generic \SpecialChar LyX
23518
23519  converters mechanism.
23520  This support is provided in a 
23521 \begin_inset Quotes eld
23522 \end_inset
23523
23524 Noweb independent
23525 \begin_inset Quotes erd
23526 \end_inset
23527
23528  way, i.
23529 \begin_inset space \thinspace{}
23530 \end_inset
23531
23532 e.
23533 \begin_inset space \space{}
23534 \end_inset
23535
23536 you will be able to use this new \SpecialChar LyX
23537  feature with some other literate programming
23538  tool of your choice by just changing your \SpecialChar LyX
23539  preferences.
23540 \end_layout
23541
23542 \begin_layout Subsubsection
23543 Generating documents and code (weaving and tangling)
23544 \end_layout
23545
23546 \begin_layout Paragraph
23547 Using the noweb module
23548 \end_layout
23549
23550 \begin_layout Standard
23551 If you have installed Noweb and \SpecialChar LyX
23552  successfully, whenever you open a new document,
23553  after you have chosen its document class, use the Document->Settings menu
23554  to add the 
23555 \begin_inset Quotes eld
23556 \end_inset
23557
23558 noweb
23559 \begin_inset Quotes erd
23560 \end_inset
23561
23562  module.
23563  If Noweb is correctly installed, when you click on the 
23564 \begin_inset Quotes eld
23565 \end_inset
23566
23567 Modules
23568 \begin_inset Quotes erd
23569 \end_inset
23570
23571  link, you will see the 
23572 \begin_inset Quotes eld
23573 \end_inset
23574
23575 noweb
23576 \begin_inset Quotes erd
23577 \end_inset
23578
23579  module in the available list and you can add it to your document.
23580 \end_layout
23581
23582 \begin_layout Paragraph
23583 Typing code in
23584 \end_layout
23585
23586 \begin_layout Standard
23587 \SpecialChar LyX
23588  enables you to write code with a layout named 
23589 \begin_inset Flex Noun
23590 status collapsed
23591
23592 \begin_layout Plain Layout
23593 Chunk
23594 \end_layout
23595
23596 \end_inset
23597
23598 .
23599  Noweb delimits chunks like this:
23600 \end_layout
23601
23602 \begin_layout LyX-Code
23603 <<My code>>=
23604 \end_layout
23605
23606 \begin_layout LyX-Code
23607   code
23608 \end_layout
23609
23610 \begin_layout LyX-Code
23611   more code
23612 \end_layout
23613
23614 \begin_layout LyX-Code
23615   even more code
23616 \end_layout
23617
23618 \begin_layout LyX-Code
23619   @
23620 \end_layout
23621
23622 \begin_layout Standard
23623 The problem is that whatever is written in between the << and the 
23624 \family typewriter
23625 @
23626 \family default
23627  must be taken literally, i.
23628 \begin_inset space \thinspace{}
23629 \end_inset
23630
23631 e.
23632 \begin_inset space \space{}
23633 \end_inset
23634
23635 \SpecialChar LyX
23636  should be prevented from making any special interpretation of what has
23637  been written.
23638  This is also handled by 
23639 \begin_inset Flex Noun
23640 status collapsed
23641
23642 \begin_layout Plain Layout
23643 Chunk
23644 \end_layout
23645
23646 \end_inset
23647
23648 , that works like a normal paragraph but has a free spacing capability.
23649 \end_layout
23650
23651 \begin_layout Standard
23652 As a special note, you can also use the 
23653 \begin_inset Quotes eld
23654 \end_inset
23655
23656 %def
23657 \begin_inset Quotes erd
23658 \end_inset
23659
23660  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
23661 rence:
23662 \end_layout
23663
23664 \begin_layout LyX-Code
23665 <<My chunk>>=
23666 \end_layout
23667
23668 \begin_layout LyX-Code
23669 def some_function(args):
23670 \end_layout
23671
23672 \begin_layout LyX-Code
23673    "This is the doc string for this function."
23674 \end_layout
23675
23676 \begin_layout LyX-Code
23677    print "My args: ", args
23678 \end_layout
23679
23680 \begin_layout LyX-Code
23681 @ %def some_function
23682 \end_layout
23683
23684 \begin_layout Standard
23685 For an example of this usage and the resulting cross-reference output, look
23686  at the Literate python program in 
23687 \emph on
23688 LIBDIR/examples/listerrors.lyx
23689 \emph default
23690  which should make this all clear.
23691 \end_layout
23692
23693 \begin_layout Paragraph
23694 Generating the documentation
23695 \end_layout
23696
23697 \begin_layout Standard
23698 At this point you already have a new document file with a proper document
23699  class, and with some code and text on it.
23700  How do I print it? The answer is simple, you select 
23701 \family sans
23702 View\SpecialChar menuseparator
23703 DVI,
23704 \family default
23705  etc.
23706  Just like you would do for a plain document.
23707  No special procedure is required.
23708 \end_layout
23709
23710 \begin_layout Standard
23711 To help orientate you, I will now explain what happens inside \SpecialChar LyX
23712 :
23713 \end_layout
23714
23715 \begin_layout Enumerate
23716 When the 
23717 \family sans
23718 Update\SpecialChar menuseparator
23719 DVI
23720 \family default
23721  menu option is chosen, a \SpecialChar LaTeX
23722  file is generated.
23723  
23724 \end_layout
23725
23726 \begin_deeper
23727 \begin_layout Standard
23728 If the document is of any literate class the generated file will be named
23729  with an extension name defined by the 
23730 \begin_inset Quotes eld
23731 \end_inset
23732
23733 literate
23734 \begin_inset Quotes erd
23735 \end_inset
23736
23737  format (defined in the Preferences panel), otherwise the file will have
23738  the usual 
23739 \family typewriter
23740 .tex
23741 \family default
23742  extension.
23743 \end_layout
23744
23745 \end_deeper
23746 \begin_layout Enumerate
23747 Note that the only difference so far is in the name of the file, no special
23748  processing is required by \SpecialChar LyX
23749 .
23750  Given that you formatted the code using the 
23751 \begin_inset Flex Noun
23752 status collapsed
23753
23754 \begin_layout Plain Layout
23755 Chunk
23756 \end_layout
23757
23758 \end_inset
23759
23760  layout that, by itself, takes care of the business.
23761 \end_layout
23762
23763 \begin_layout Enumerate
23764 If the document is of any literate class \SpecialChar LyX
23765  will then use the internal \SpecialChar LyX
23766  to
23767  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
23768  converter
23769 \begin_inset Foot
23770 status collapsed
23771
23772 \begin_layout Plain Layout
23773 The converters are defined in the 
23774 \family sans
23775 Tools\SpecialChar menuseparator
23776 Preferences
23777 \family default
23778  panel, under the 
23779 \begin_inset Quotes eld
23780 \end_inset
23781
23782 Conversion
23783 \begin_inset Quotes erd
23784 \end_inset
23785
23786  tab.
23787  See section 
23788 \emph on
23789 Converters
23790 \emph default
23791  of the 
23792 \emph on
23793 Customization
23794 \emph default
23795  manual for general information about converters.
23796 \end_layout
23797
23798 \end_inset
23799
23800  to generate the \SpecialChar LaTeX
23801  file.
23802 \end_layout
23803
23804 \begin_deeper
23805 \begin_layout Standard
23806 Otherwise it will just skip this step.
23807 \end_layout
23808
23809 \end_deeper
23810 \begin_layout Enumerate
23811 Finally, \SpecialChar LaTeX
23812  is invoked and the regular post processing continues as in a plain
23813  document.
23814 \end_layout
23815
23816 \begin_layout Standard
23817 Independence from a particular 
23818 \begin_inset Quotes eld
23819 \end_inset
23820
23821 literate tool
23822 \begin_inset Quotes erd
23823 \end_inset
23824
23825  is easily achieved by changing the commands that are run by the various
23826  converters.
23827 \end_layout
23828
23829 \begin_layout Paragraph
23830 Generating the code
23831 \end_layout
23832
23833 \begin_layout Standard
23834 When the build menu option is chosen or the corresponding button in the
23835  toolbar is pressed, a \SpecialChar LaTeX
23836  file is generated just like step 1 above.
23837  Next, \SpecialChar LyX
23838  invokes the 
23839 \family typewriter
23840 Noweb->Program
23841 \family default
23842  converter.
23843  This converter needs to be defined by the user and is not installed by
23844  default, though the Program format is.
23845  This converter (like any other converter) will have two parts:
23846 \end_layout
23847
23848 \begin_layout Enumerate
23849 The converter program itself.
23850  This program performs the conversion from the one format to the other (in
23851  this case, from the Noweb format to the Program pseudo-format).
23852 \end_layout
23853
23854 \begin_layout Enumerate
23855 The error log parser.
23856  This is a program whose sole purpose is to rewrite error messages in a
23857  format that \SpecialChar LyX
23858  understands.
23859  This makes it possible for \SpecialChar LyX
23860  to place error boxes in the right places in
23861  the file buffer.
23862 \end_layout
23863
23864 \begin_layout Standard
23865 The first part, the 
23866 \begin_inset Quotes eld
23867 \end_inset
23868
23869 Converter
23870 \begin_inset Quotes erd
23871 \end_inset
23872
23873  setting, should be set to
23874 \begin_inset Newline newline
23875 \end_inset
23876
23877
23878 \begin_inset Quotes eld
23879 \end_inset
23880
23881
23882 \family typewriter
23883 build-script $$i
23884 \family default
23885  $$r
23886 \begin_inset Quotes erd
23887 \end_inset
23888
23889 .
23890 \begin_inset Newline newline
23891 \end_inset
23892
23893 This basically means that \SpecialChar LyX
23894  will call 
23895 \begin_inset Quotes eld
23896 \end_inset
23897
23898 build-script
23899 \begin_inset Quotes erd
23900 \end_inset
23901
23902  (a program or script) with the name of the Noweb file (normally a file
23903  in the \SpecialChar LyX
23904  temp directory) and the directory path of the original \SpecialChar LyX
23905  file.
23906  
23907 \end_layout
23908
23909 \begin_layout Standard
23910 This is an implementation of 
23911 \begin_inset Quotes eld
23912 \end_inset
23913
23914 build-script
23915 \begin_inset Quotes erd
23916 \end_inset
23917
23918  that you can place in a directory on your path:
23919 \end_layout
23920
23921 \begin_layout Standard
23922 \begin_inset VSpace defskip
23923 \end_inset
23924
23925
23926 \end_layout
23927
23928 \begin_layout Standard
23929 \begin_inset Newpage pagebreak
23930 \end_inset
23931
23932
23933 \end_layout
23934
23935 \begin_layout Standard
23936
23937 \family sans
23938 #!/bin/sh
23939 \end_layout
23940
23941 \begin_layout Standard
23942
23943 \family sans
23944 #
23945 \end_layout
23946
23947 \begin_layout Standard
23948
23949 \family sans
23950 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
23951 \end_layout
23952
23953 \begin_layout Standard
23954 \begin_inset VSpace defskip
23955 \end_inset
23956
23957
23958 \end_layout
23959
23960 \begin_layout Standard
23961 The next part of the converter setting is the 
23962 \begin_inset Quotes eld
23963 \end_inset
23964
23965 Flags
23966 \begin_inset Quotes erd
23967 \end_inset
23968
23969  which is to be set to
23970 \begin_inset Newline newline
23971 \end_inset
23972
23973
23974 \begin_inset Quotes eld
23975 \end_inset
23976
23977
23978 \family typewriter
23979 parselog=$$s/scripts/listerrors
23980 \family default
23981
23982 \begin_inset Quotes erd
23983 \end_inset
23984
23985 .
23986 \begin_inset Newline newline
23987 \end_inset
23988
23989 This will run any errors that are generated by the 
23990 \begin_inset Quotes eld
23991 \end_inset
23992
23993 build-script
23994 \begin_inset Quotes erd
23995 \end_inset
23996
23997  process through the 
23998 \begin_inset Quotes eld
23999 \end_inset
24000
24001 listerrors
24002 \begin_inset Quotes erd
24003 \end_inset
24004
24005  program.
24006 \end_layout
24007
24008 \begin_layout Standard
24009 The build will normally take place in \SpecialChar LyX
24010 's temporary directory, so the files
24011  produced by the conversion will be in that directory.
24012  \SpecialChar LyX
24013  will copy out what it regards as the `main' file, but the 
24014 \family typewriter
24015 Noweb->Program
24016 \family default
24017  conversion may produce several files, and so most of these would then be
24018  deleted when \SpecialChar LyX
24019  was closed.
24020  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
24021  the build-script chunk can place the generated files in that location.
24022 \end_layout
24023
24024 \begin_layout Paragraph
24025 Build instructions in the document
24026 \end_layout
24027
24028 \begin_layout Standard
24029 The last piece of the integration between \SpecialChar LyX
24030  and noweb is the 
24031 \begin_inset Quotes eld
24032 \end_inset
24033
24034 build-script
24035 \begin_inset Quotes erd
24036 \end_inset
24037
24038  chunk.
24039  Generally, the instructions for building your program should be embedded
24040  in a chunk of its own.
24041  The noweb-specific 
24042 \begin_inset Quotes eld
24043 \end_inset
24044
24045 build-script
24046 \begin_inset Quotes erd
24047 \end_inset
24048
24049  above uses the notangle command to look for this chunk (called 
24050 \begin_inset Quotes eld
24051 \end_inset
24052
24053 build-script
24054 \begin_inset Quotes erd
24055 \end_inset
24056
24057 ) and runs its contents through 
24058 \begin_inset Quotes eld
24059 \end_inset
24060
24061 sh
24062 \begin_inset Quotes erd
24063 \end_inset
24064
24065 .
24066 \end_layout
24067
24068 \begin_layout Standard
24069 Typically, such a chunk would look something like this:
24070 \end_layout
24071
24072 \begin_layout LyX-Code
24073 <<build-script>>=
24074 \end_layout
24075
24076 \begin_layout LyX-Code
24077 #!/bin/sh
24078 \begin_inset Newline newline
24079 \end_inset
24080
24081 if [ -z "${NOWEB_SOURCE}" ]
24082 \begin_inset Newline newline
24083 \end_inset
24084
24085 then
24086 \end_layout
24087
24088 \begin_layout LyX-Code
24089 NOWEB_SOURCE=myfile.nw
24090 \begin_inset Newline newline
24091 \end_inset
24092
24093 fi
24094 \begin_inset Newline newline
24095 \end_inset
24096
24097 [...
24098  code to extract files ...
24099  use NOWEB_OUTPUT_DIR here ...]
24100 \begin_inset Newline newline
24101 \end_inset
24102
24103 [...
24104  code to compile files ...]
24105 \begin_inset Newline newline
24106 \end_inset
24107
24108 @
24109 \end_layout
24110
24111 \begin_layout Standard
24112 Look in 
24113 \emph on
24114 LIBDIR/examples/listerrors.lyx
24115 \emph default
24116  or in 
24117 \emph on
24118 LIBDIR/examples/Literate.lyx
24119 \emph default
24120  which implement two versions of the 
24121 \begin_inset Quotes eld
24122 \end_inset
24123
24124 listerrors
24125 \begin_inset Quotes erd
24126 \end_inset
24127
24128  program for some illustrations of how all of these pieces go together or
24129  in 
24130 \emph on
24131 LIBDIR/examples/noweb2lyx.lyx.
24132
24133 \emph default
24134  Interestingly, these three files show off the language-indepence of the
24135  \SpecialChar LyX
24136  literate programming support since they are written in Python, C and Perl
24137  respectively.
24138 \end_layout
24139
24140 \begin_layout Subsubsection
24141 Configuring \SpecialChar LyX
24142
24143 \end_layout
24144
24145 \begin_layout Standard
24146 All the Literate Programming support is configured by the 
24147 \family sans
24148 Tools\SpecialChar menuseparator
24149 Preferences
24150 \family default
24151  panel in the 
24152 \begin_inset Quotes eld
24153 \end_inset
24154
24155 File Handling
24156 \begin_inset Quotes erd
24157 \end_inset
24158
24159  tab.
24160  The important parts are:
24161 \end_layout
24162
24163 \begin_layout Description
24164 the
24165 \begin_inset space ~
24166 \end_inset
24167
24168
24169 \begin_inset Quotes eld
24170 \end_inset
24171
24172 NoWeb
24173 \begin_inset Quotes erd
24174 \end_inset
24175
24176
24177 \begin_inset space ~
24178 \end_inset
24179
24180 format Set up via the File Formats tab, this is where the Noweb-specific
24181  pieces are set up.
24182  The 
24183 \family sans
24184 GUI Name
24185 \family default
24186  is set to 
24187 \family typewriter
24188 NoWeb
24189 \family default
24190 , the file extension is set to 
24191 \family typewriter
24192 .nw
24193 \family default
24194 .
24195  This tells \SpecialChar LyX
24196  to create a file with a 
24197 \family typewriter
24198 .nw
24199 \family default
24200  extension in the first step of the conversion process.
24201 \end_layout
24202
24203 \begin_layout Description
24204 the
24205 \begin_inset space ~
24206 \end_inset
24207
24208
24209 \family sans
24210 Program
24211 \family default
24212
24213 \begin_inset space ~
24214 \end_inset
24215
24216 format This is an empty format whose sole purpose is to be the endpoint
24217  of a conversion (which then allows us to set up a converter for it).
24218 \end_layout
24219
24220 \begin_layout Description
24221
24222 \family sans
24223 NoWeb
24224 \family default
24225 ->
24226 \family sans
24227 \SpecialChar LaTeX
24228
24229 \family default
24230  This converter performs the 
24231 \begin_inset Quotes eld
24232 \end_inset
24233
24234 weaving
24235 \begin_inset Quotes erd
24236 \end_inset
24237
24238  of the literate document.
24239  For Noweb, it is set to 
24240 \begin_inset Quotes eld
24241 \end_inset
24242
24243
24244 \family typewriter
24245 noweave -delay -index $$i > $$o
24246 \family default
24247
24248 \begin_inset Quotes erd
24249 \end_inset
24250
24251
24252 \end_layout
24253
24254 \begin_layout Description
24255
24256 \family sans
24257 NoWeb
24258 \family default
24259 ->
24260 \family sans
24261 Program
24262 \family default
24263  This performs the 
24264 \begin_inset Quotes eld
24265 \end_inset
24266
24267 tangling step
24268 \begin_inset Quotes erd
24269 \end_inset
24270
24271 .
24272  As stated above, the Converter is set to 
24273 \begin_inset Quotes eld
24274 \end_inset
24275
24276
24277 \family typewriter
24278 build-script $$i
24279 \family default
24280  $$r
24281 \begin_inset Quotes erd
24282 \end_inset
24283
24284 , with Flags set to
24285 \begin_inset Newline newline
24286 \end_inset
24287
24288
24289 \begin_inset Quotes eld
24290 \end_inset
24291
24292
24293 \family typewriter
24294 parselog=$$s/scripts/listerrors
24295 \family default
24296
24297 \begin_inset Quotes erd
24298 \end_inset
24299
24300 .
24301 \end_layout
24302
24303 \begin_layout Subsubsection
24304 Debug extensions
24305 \end_layout
24306
24307 \begin_layout Standard
24308 There is also a new function implemented in the \SpecialChar LyX
24309  server, the 
24310 \begin_inset Quotes eld
24311 \end_inset
24312
24313 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
24314  
24315 \end_layout
24316
24317 \begin_layout Standard
24318 When debugging code with ddd/gdb, it is possible to invoke a text editor
24319  at the current execution position with a single key stroke.
24320  The default ddd configuration for that is shift-ctrl-V.
24321  It happens that you can define the editor command line invocation in ddd
24322  by accessing the 
24323 \family sans
24324 Edit\SpecialChar menuseparator
24325 Preferences\SpecialChar menuseparator
24326 Helpers
24327 \family default
24328  dialog and changing the "Edit Sources" entry.
24329 \end_layout
24330
24331 \begin_layout Standard
24332 I take advantage of the newly created \SpecialChar LyX
24333  server function and this ddd feature,
24334  and set 
24335 \begin_inset Quotes eld
24336 \end_inset
24337
24338 Edit Sources
24339 \begin_inset Quotes erd
24340 \end_inset
24341
24342  to:
24343 \end_layout
24344
24345 \begin_layout Standard
24346 \begin_inset VSpace defskip
24347 \end_inset
24348
24349
24350 \end_layout
24351
24352 \begin_layout Standard
24353
24354 \family sans
24355 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
24356 \end_layout
24357
24358 \begin_layout Standard
24359 \begin_inset VSpace defskip
24360 \end_inset
24361
24362
24363 \end_layout
24364
24365 \begin_layout Standard
24366 With this, whenever you are using ddd and find a point in the program that
24367  you want to edit, you just press shift-ctrl-V (in the ddd window), and
24368  ddd will forward this information to \SpecialChar LyX
24369  through the \SpecialChar LyX
24370  server and then the
24371  \SpecialChar LyX
24372  window will show the same file with the cursor at the same position ddd
24373  was pointing to.
24374  No more guessing or long scrolling to locate a point in the program back
24375  from debugging !
24376 \end_layout
24377
24378 \begin_layout Standard
24379 Note however that you must enable the \SpecialChar LyX
24380  server to get this feature working
24381  (it is disabled by default).
24382  You can enable it in 
24383 \family sans
24384 Preferences
24385 \family default
24386  (tabs 
24387 \family sans
24388 Inputs
24389 \family default
24390
24391 \family sans
24392 Paths
24393 \family default
24394 ) by entering in the 
24395 \family sans
24396 \SpecialChar LyX
24397 server pipe
24398 \family default
24399  a path like 
24400 \begin_inset Quotes eld
24401 \end_inset
24402
24403
24404 \family typewriter
24405 /home/<your-home-directory>/.lyx/lyxpipe
24406 \family default
24407
24408 \begin_inset Quotes erd
24409 \end_inset
24410
24411
24412 \end_layout
24413
24414 \begin_layout Standard
24415 Read the \SpecialChar LyX
24416  server documentation in the 
24417 \emph on
24418 Customization Manual
24419 \emph default
24420  for further information.
24421 \end_layout
24422
24423 \begin_layout Subsubsection
24424 Toolbar extensions
24425 \end_layout
24426
24427 \begin_layout Standard
24428 There are six new buttons that can be added to your \SpecialChar LyX
24429  toolbar.
24430  Five of these buttons are short cuts to layout styles: 
24431 \family sans
24432 Standard
24433 \family default
24434
24435 \family sans
24436 Section
24437 \family default
24438
24439 \family sans
24440 \SpecialChar LaTeX
24441
24442 \family default
24443
24444 \family sans
24445 \SpecialChar LyX
24446 -Code
24447 \family default
24448 , and 
24449 \family sans
24450 Chunk
24451 \family default
24452 .
24453  The last one is a short cut to the 
24454 \begin_inset Quotes eld
24455 \end_inset
24456
24457 Build Program
24458 \begin_inset Quotes erd
24459 \end_inset
24460
24461  File menu entry.
24462  
24463 \end_layout
24464
24465 \begin_layout Standard
24466 \SpecialChar LyX
24467  has a range of buttons that are available for tool bar customization.
24468  In my toolbar I like to combine the six short cuts above with two more:
24469  One for 
24470 \family sans
24471 Document
24472 \family default
24473 \SpecialChar menuseparator
24474
24475 \family sans
24476 Update
24477 \family default
24478 \SpecialChar menuseparator
24479
24480 \family sans
24481 DVI
24482 \family default
24483  and the other for 
24484 \family sans
24485 Document\SpecialChar menuseparator
24486 View\SpecialChar menuseparator
24487 DVI
24488 \family default
24489  File menu entries.
24490  Here is how it looks like:
24491 \end_layout
24492
24493 \begin_layout LyX-Code
24494 Toolbar
24495 \end_layout
24496
24497 \begin_layout LyX-Code
24498   Layouts
24499 \end_layout
24500
24501 \begin_layout LyX-Code
24502   Icon "layout Standard"
24503 \end_layout
24504
24505 \begin_layout LyX-Code
24506   Icon "layout Section"
24507 \end_layout
24508
24509 \begin_layout LyX-Code
24510   Icon "layout \SpecialChar LaTeX
24511 "
24512 \end_layout
24513
24514 \begin_layout LyX-Code
24515   Icon "layout \SpecialChar LyX
24516 -Code"
24517 \end_layout
24518
24519 \begin_layout LyX-Code
24520   Icon "layout Chunk"
24521 \end_layout
24522
24523 \begin_layout LyX-Code
24524   Separator
24525 \end_layout
24526
24527 \begin_layout LyX-Code
24528   Icon "buffer-view"
24529 \end_layout
24530
24531 \begin_layout LyX-Code
24532   Icon "buffer-typeset"
24533 \end_layout
24534
24535 \begin_layout LyX-Code
24536   Icon "build-program"
24537 \end_layout
24538
24539 \begin_layout LyX-Code
24540   Separator
24541 \end_layout
24542
24543 \begin_layout LyX-Code
24544 .
24545 \end_layout
24546
24547 \begin_layout LyX-Code
24548 .
24549 \end_layout
24550
24551 \begin_layout LyX-Code
24552 .
24553 \end_layout
24554
24555 \begin_layout LyX-Code
24556 End
24557 \end_layout
24558
24559 \begin_layout Subsubsection
24560 Colors customization
24561 \end_layout
24562
24563 \begin_layout Standard
24564 There are a number of colors in \SpecialChar LyX
24565  that can be customized in 
24566 \family sans
24567 Preferences
24568 \family default
24569 .
24570  One of the things that bothers people is the \SpecialChar LaTeX
24571  font color.
24572  The default color is red, since the chunks uses \SpecialChar LaTeX
24573  font, and there is a lot
24574  of chunks in literate documents, you may get tired of seeing everything
24575  in red.
24576  You can change it by going to the tabs 
24577 \family sans
24578 Look&Feel
24579 \family default
24580
24581 \family sans
24582 Colors.
24583 \end_layout
24584
24585 \begin_layout Standard
24586 The next thing is the visible presence of the newline character in the screen.
24587  You can choose the color of this particular character and make it blend
24588  in the background.
24589  I recommend you choosing a color that is close to the background but not
24590  equal, that way you still can see it is there, but it is not bothering
24591  you anymore.
24592 \end_layout
24593
24594 \begin_layout Subsection
24595 \SpecialChar LyX
24596  and knitr/Sweave
24597 \end_layout
24598
24599 \begin_layout Standard
24600 Support for 
24601 \family sans
24602 knitr
24603 \family default
24604  and 
24605 \family sans
24606 Sweave
24607 \family default
24608  is documented in the 
24609 \emph on
24610 knitr.lyx
24611 \emph default
24612  example file and in the Sweave manual (menu 
24613 \family sans
24614 Help\SpecialChar menuseparator
24615 Specific Manuals
24616 \family default
24617 ).
24618 \end_layout
24619
24620 \begin_layout Chapter
24621 Special features
24622 \end_layout
24623
24624 \begin_layout Standard
24625 You can do everything with \SpecialChar LyX
24626  that you can do with \SpecialChar LaTeX
24627 .
24628  However, \SpecialChar LyX
24629  cannot support every \SpecialChar LaTeX
24630  feature directly.
24631  But you can always use \SpecialChar TeX
24632  Code.
24633  This chapter shows you some more special things you might want to use.
24634  For other special things you can do with figures, tables, floats, boxes
24635  and notes, have a look at the 
24636 \emph on
24637 Embedded
24638 \begin_inset space ~
24639 \end_inset
24640
24641 Objects
24642 \emph default
24643  manual.
24644 \end_layout
24645
24646 \begin_layout Section
24647 Multiple Text Columns
24648 \end_layout
24649
24650 \begin_layout Standard
24651 This feature is independent of the option 
24652 \family sans
24653 Two-column document
24654 \family default
24655  in the document settings under 
24656 \family sans
24657 Text Layout
24658 \family default
24659 .
24660  If you want to have 2
24661 \begin_inset space ~
24662 \end_inset
24663
24664 columns for the whole document, it is recommended to use the 
24665 \family sans
24666 Two-column document
24667 \family default
24668  option.
24669  For all other cases use this feature.
24670 \end_layout
24671
24672 \begin_layout Standard
24673 To use multiple text columns in your document, you have to load the module
24674  
24675 \family sans
24676 Multiple Columns
24677 \family default
24678  (menu 
24679 \family sans
24680 Document\SpecialChar menuseparator
24681 Settings\SpecialChar menuseparator
24682 Modules
24683 \family default
24684 ) and must have the \SpecialChar LaTeX
24685 -package 
24686 \series bold
24687 multicol
24688 \series default
24689  installed.
24690 \end_layout
24691
24692 \begin_layout Standard
24693 Footnotes within multiple columns will be placed at the bottom of the page
24694  and not under each column.
24695  Within the different columns you can use everything, with the limitation
24696  that for floats you need to use the float option 
24697 \family sans
24698 Span columns
24699 \family default
24700 .
24701 \end_layout
24702
24703 \begin_layout Subsection
24704 Basics
24705 \end_layout
24706
24707 \begin_layout Standard
24708 If you want to have 2
24709 \begin_inset space ~
24710 \end_inset
24711
24712 columns in your text, insert a multicolumn inset via the menu 
24713 \family sans
24714 Insert\SpecialChar menuseparator
24715 Custom
24716 \begin_inset space ~
24717 \end_inset
24718
24719 Insets\SpecialChar menuseparator
24720 Multiple
24721 \begin_inset space ~
24722 \end_inset
24723
24724 Columns
24725 \family default
24726  where the columns should start.
24727  Write all text that should be printed in 2
24728 \begin_inset space ~
24729 \end_inset
24730
24731 columns into this inset.
24732 \end_layout
24733
24734 \begin_layout Standard
24735 Here is an example:
24736 \end_layout
24737
24738 \begin_layout Standard
24739 \noindent
24740 \begin_inset Flex Multiple Columns
24741 status open
24742
24743 \begin_layout Plain Layout
24744 \noindent
24745
24746 \series bold
24747 \size small
24748 The Adventure of the Empty House
24749 \series default
24750
24751 \begin_inset Newline newline
24752 \end_inset
24753
24754 by Sir Arthur Conan Doyle
24755 \end_layout
24756
24757 \begin_layout Plain Layout
24758
24759 \size small
24760 It was in the spring of the year 1894 that all London was interested, and
24761  the fashionable world dismayed, by the murder of the Honourable Ronald
24762  Adair under most unusual and inexplicable circumstances.
24763  The public has already learned those particulars of the crime which came
24764  out in the police investigation, but a good deal was suppressed upon that
24765  occasion, since the case for the prosecution was so overwhelmingly strong
24766  that it was not necessary to bring forward all the facts.
24767  Only now, at the end of nearly ten years, am I allowed to supply those
24768  missing links which make up the whole of that remarkable chain.
24769  The crime was of interest in itself, but that interest was as nothing to
24770  me compared to the inconceivable sequel, which afforded me the greatest
24771  shock and surprise of any event in my adventurous life.
24772  Even now, after this long interval, I find myself thrilling as I think
24773  of it, and feeling once more that sudden flood of joy, amazement, and increduli
24774 ty which utterly submerged my mind.
24775  Let me say to that public, which has shown some interest in those glimpses
24776  which I have occasionally given them of the thoughts and actions of a very
24777  remarkable man, that they are not to blame me if I have not shared my knowledge
24778  with them, for I should have considered it my first duty to do so, had
24779  I not been barred by a positive prohibition from his own lips, which was
24780  only withdrawn upon the third of last month.
24781 \end_layout
24782
24783 \end_inset
24784
24785
24786 \end_layout
24787
24788 \begin_layout Standard
24789 To get 3 or more columns, set the cursor into the multicolumn inset and
24790  use the menu 
24791 \family sans
24792 Insert\SpecialChar menuseparator
24793 Number
24794 \begin_inset space ~
24795 \end_inset
24796
24797 of
24798 \begin_inset space ~
24799 \end_inset
24800
24801 Columns
24802 \family default
24803 .
24804  The number of the desired columns is written into that inset (for 3
24805 \begin_inset space ~
24806 \end_inset
24807
24808 columns write 
24809 \begin_inset Quotes eld
24810 \end_inset
24811
24812 3
24813 \begin_inset Quotes erd
24814 \end_inset
24815
24816 ).
24817 \begin_inset Newline newline
24818 \end_inset
24819
24820 Here is an example with 3
24821 \begin_inset space ~
24822 \end_inset
24823
24824 columns:
24825 \end_layout
24826
24827 \begin_layout Standard
24828 \begin_inset Flex Multiple Columns
24829 status open
24830
24831 \begin_layout Plain Layout
24832
24833 \size footnotesize
24834 \begin_inset Argument 1
24835 status open
24836
24837 \begin_layout Plain Layout
24838 3
24839 \end_layout
24840
24841 \end_inset
24842
24843 It can be imagined that my close intimacy with Sherlock Holmes had interested
24844  me deeply in crime, and that after his disappearance I never failed to
24845  read with care the various problems which came before the public.
24846  And I even attempted, more than once, for my own private satisfaction,
24847  to employ his methods in their solution, though with indifferent success.
24848  There was none, however, which appealed to me like this tragedy of Ronald
24849  Adair.
24850  As I read the evidence at the inquest, which led up to a verdict of willful
24851  murder against some person or persons unknown, I realized more clearly
24852  than I had ever done the loss which the community had sustained by the
24853  death of Sherlock Holmes.
24854  There were points about this strange business which would, I was sure,
24855  have specially appealed to him, and the efforts of the police would have
24856  been supplemented, or more probably anticipated, by the trained observation
24857  and the alert mind of the first criminal agent in Europe.
24858  All day, as I drove upon my round, I turned over the case in my mind and
24859  found no explanation which appeared to me to be adequate.
24860  At the risk of telling a twice-told tale, I will recapitulate the facts
24861  as they were known to the public at the conclusion of the inquest.
24862 \end_layout
24863
24864 \end_inset
24865
24866
24867 \end_layout
24868
24869 \begin_layout Standard
24870 You can have up to 10
24871 \begin_inset space ~
24872 \end_inset
24873
24874 columns if you want to, but that might not be very pleasant for the readers
24875  of your document.
24876 \end_layout
24877
24878 \begin_layout Standard
24879 \begin_inset Newpage newpage
24880 \end_inset
24881
24882
24883 \end_layout
24884
24885 \begin_layout Subsection
24886 Columns inside Columns
24887 \end_layout
24888
24889 \begin_layout Standard
24890 You can also have columns inside columns:
24891 \end_layout
24892
24893 \begin_layout Standard
24894 \begin_inset Flex Multiple Columns
24895 status open
24896
24897 \begin_layout Plain Layout
24898
24899 \size footnotesize
24900 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
24901  at that time governor of one of the Australian colonies.
24902  Adair's mother had returned from Australia to undergo the operation for
24903  cataract, and she, her son Ronald, and her daughter Hilda were living together
24904  at 427 Park Lane.
24905 \end_layout
24906
24907 \begin_layout Plain Layout
24908 \begin_inset Flex Multiple Columns
24909 status open
24910
24911 \begin_layout Plain Layout
24912
24913 \size footnotesize
24914 The youth moved in the best society–had, so far as was known, no enemies
24915  and no particular vices.
24916  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
24917  had been broken off by mutual consent some months before, and there was
24918  no sign that it had left any very profound feeling behind it.
24919  For the rest {sic} the man's life moved in a narrow and conventional circle,
24920  for his habits were quiet and his nature unemotional.
24921  Yet it was upon this easy-going young aristocrat that death came, in most
24922  strange and unexpected form, between the hours of ten and eleven-twenty
24923  on the night of March 30, 1894.
24924 \end_layout
24925
24926 \end_inset
24927
24928
24929 \end_layout
24930
24931 \begin_layout Plain Layout
24932
24933 \size footnotesize
24934 Ronald Adair was fond of cards–playing continually, but never for such stakes
24935  as would hurt him.
24936  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
24937  It was shown that, after dinner on the day of his death, he had played
24938  a rubber of whist at the latter club.
24939  He had also played there in the afternoon.
24940
24941 \size default
24942  
24943 \size footnotesize
24944 The evidence of those who had played with him– Mr.
24945  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
24946  and that there was a fairly equal fall of the cards.
24947  Adair might have lost five pounds, but not more.
24948  His fortune was a considerable one, and such a loss could not in any way
24949  affect him.
24950  He had played nearly every day at one club or other, but he was a cautious
24951  player, and usually rose a winner.
24952  It came out in evidence that, in partnership with Colonel Moran, he had
24953  actually won as much as four hundred and twenty pounds in a sitting, some
24954  weeks before, from Godfrey Milner and Lord Balmoral.
24955  So much for his recent history as it came out at the inquest.
24956 \end_layout
24957
24958 \end_inset
24959
24960
24961 \end_layout
24962
24963 \begin_layout Subsection
24964 Advanced Examples
24965 \end_layout
24966
24967 \begin_layout Standard
24968 The examples in this section show some more special features of multiple
24969  columns.
24970 \end_layout
24971
24972 \begin_layout Standard
24973 For more features of multiple columns, have a look at the documentation
24974  of the \SpecialChar LaTeX
24975 -package 
24976 \series bold
24977 multicol
24978 \series default
24979
24980 \begin_inset CommandInset citation
24981 LatexCommand cite
24982 key "multicol"
24983 literal "true"
24984
24985 \end_inset
24986
24987 .
24988 \end_layout
24989
24990 \begin_layout Subsubsection
24991 Preface
24992 \end_layout
24993
24994 \begin_layout Standard
24995 To add a preface text for multiple columns, set the cursor into the multicolumn
24996  inset and use the menu 
24997 \family sans
24998 Insert\SpecialChar menuseparator
24999 Preface
25000 \family default
25001 .
25002  Write your preface text into that inset.
25003 \begin_inset Newline newline
25004 \end_inset
25005
25006 This is an example with some preface text:
25007 \end_layout
25008
25009 \begin_layout Standard
25010 \begin_inset VSpace bigskip
25011 \end_inset
25012
25013
25014 \end_layout
25015
25016 \begin_layout Standard
25017 \begin_inset Flex Multiple Columns
25018 status open
25019
25020 \begin_layout Plain Layout
25021 \begin_inset Argument 2
25022 status open
25023
25024 \begin_layout Plain Layout
25025 And the story continues and continues and continues and continues\SpecialChar ldots
25026
25027 \end_layout
25028
25029 \end_inset
25030
25031
25032 \size small
25033 On the evening of the crime, he returned from the club exactly at ten.
25034  His mother and sister were out spending the evening with a relation.
25035  The servant deposed that she heard him enter the front room on the second
25036  floor, generally used as his sitting-room.
25037  She had lit a fire there, and as it smoked she had opened the window.
25038  No sound was heard from the room until eleven-twenty, the hour of the return
25039  of Lady Maynooth and her daughter.
25040  Desiring to say good-night, she attempted to enter her son's room.
25041  The door was locked on the inside, and no answer could be got to their
25042  cries and knocking.
25043  Help was obtained, and the door forced.
25044  The unfortunate young man was found lying near the table.
25045  His head had been horribly mutilated by an expanding revolver bullet, but
25046  no weapon of any sort was to be found in the room.
25047 \end_layout
25048
25049 \end_inset
25050
25051
25052 \end_layout
25053
25054 \begin_layout Standard
25055 You can also use a section heading as the preface if you use a section command
25056  as \SpecialChar TeX
25057  Code.
25058  For example the command
25059 \end_layout
25060
25061 \begin_layout Standard
25062
25063 \series bold
25064
25065 \backslash
25066 subsection{subsection title}
25067 \end_layout
25068
25069 \begin_layout Standard
25070 creates a subsection.
25071  In this example the preface is a subsubsection:
25072 \end_layout
25073
25074 \begin_layout Standard
25075 \begin_inset Flex Multiple Columns
25076 status open
25077
25078 \begin_layout Plain Layout
25079 \begin_inset Argument 2
25080 status open
25081
25082 \begin_layout Plain Layout
25083 \begin_inset ERT
25084 status collapsed
25085
25086 \begin_layout Plain Layout
25087
25088
25089 \backslash
25090 subsubsection{
25091 \end_layout
25092
25093 \end_inset
25094
25095 This is a subsubsection heading as a preface
25096 \begin_inset ERT
25097 status collapsed
25098
25099 \begin_layout Plain Layout
25100
25101 }
25102 \end_layout
25103
25104 \end_inset
25105
25106
25107 \end_layout
25108
25109 \end_inset
25110
25111
25112 \size small
25113 A minute examination of the circumstances served only to make the case more
25114  complex.
25115  In the first place, no reason could be given why the young man should have
25116  fastened the door upon the inside.
25117  There was the possibility that the murderer had done this, and had afterwards
25118  escaped by the window.
25119  The drop was at least twenty feet, however, and a bed of crocuses in full
25120  bloom lay beneath.
25121  Neither the flowers nor the earth showed any sign of having been disturbed,
25122  nor were there any marks upon the narrow strip of grass which separated
25123  the house from the road.
25124  Apparently, therefore, it was the young man himself who had fastened the
25125  door.
25126  But how did he come by his death? No one could have climbed up to the window
25127  without leaving traces.
25128  Suppose a man had fired through the window, he would indeed be a remarkable
25129  shot who could with a revolver inflict so deadly a wound.
25130  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
25131  a hundred yards of the house.
25132  No one had heard a shot.
25133 \end_layout
25134
25135 \end_inset
25136
25137
25138 \end_layout
25139
25140 \begin_layout Standard
25141 If there is less vertical space than 6
25142 \begin_inset space ~
25143 \end_inset
25144
25145 text lines is left on the page at the beginning of the multiple columns,
25146  a page break will be inserted before the multiple columns.
25147  Depending on the number of lines of the preface text, you might want to
25148  change this space.
25149  This is done by setting the cursor into the mulitcolumn inset behind the
25150  preface (if there is any) and using the menu 
25151 \family sans
25152 Insert\SpecialChar menuseparator
25153 Space
25154 \begin_inset space ~
25155 \end_inset
25156
25157 Before
25158 \begin_inset space ~
25159 \end_inset
25160
25161 Page
25162 \begin_inset space ~
25163 \end_inset
25164
25165 Break
25166 \family default
25167 .
25168  Insert into that inset the amount of space like e.
25169 \begin_inset space \thinspace{}
25170 \end_inset
25171
25172 g.
25173 \begin_inset space \space{}
25174 \end_inset
25175
25176
25177 \begin_inset Quotes eld
25178 \end_inset
25179
25180 5cm
25181 \begin_inset Quotes erd
25182 \end_inset
25183
25184 .
25185 \begin_inset Newline newline
25186 \end_inset
25187
25188 In this example the space is set to 7
25189 \begin_inset space ~
25190 \end_inset
25191
25192 text lines by using 
25193 \begin_inset Quotes eld
25194 \end_inset
25195
25196 7
25197 \backslash
25198 baselineskip
25199 \begin_inset Quotes erd
25200 \end_inset
25201
25202  (where the command 
25203 \series bold
25204
25205 \backslash
25206 baselineskip
25207 \series default
25208  needs to be inserted as \SpecialChar TeX
25209  code):
25210 \end_layout
25211
25212 \begin_layout Standard
25213 \begin_inset Flex Multiple Columns
25214 status open
25215
25216 \begin_layout Plain Layout
25217 \begin_inset Argument 3
25218 status open
25219
25220 \begin_layout Plain Layout
25221 7
25222 \begin_inset ERT
25223 status collapsed
25224
25225 \begin_layout Plain Layout
25226
25227
25228 \backslash
25229 baselineskip
25230 \end_layout
25231
25232 \end_inset
25233
25234
25235 \end_layout
25236
25237 \end_inset
25238
25239
25240 \size small
25241 On the evening of the crime, he returned from the club exactly at ten.
25242  His mother and sister were out spending the evening with a relation.
25243  The servant deposed that she heard him enter the front room on the second
25244  floor, generally used as his sitting-room.
25245  She had lit a fire there, and as it smoked she had opened the window.
25246  No sound was heard from the room until eleven-twenty, the hour of the return
25247  of Lady Maynooth and her daughter.
25248  Desiring to say good-night, she attempted to enter her son's room.
25249  The door was locked on the inside, and no answer could be got to their
25250  cries and knocking.
25251  Help was obtained, and the door forced.
25252  The unfortunate young man was found lying near the table.
25253  His head had been horribly mutilated by an expanding revolver bullet, but
25254  no weapon of any sort was to be found in the room.
25255 \end_layout
25256
25257 \end_inset
25258
25259
25260 \end_layout
25261
25262 \begin_layout Subsubsection
25263 Surrounding Space
25264 \end_layout
25265
25266 \begin_layout Standard
25267 The amount of space before and after multiple columns can be changed by
25268  changing the length 
25269 \series bold
25270
25271 \backslash
25272 multicolsep
25273 \series default
25274 .
25275  For example the command
25276 \end_layout
25277
25278 \begin_layout Standard
25279
25280 \series bold
25281
25282 \backslash
25283 setlength{
25284 \backslash
25285 multicolsep}{3cm}
25286 \end_layout
25287
25288 \begin_layout Standard
25289 in \SpecialChar TeX
25290  Code changes its value to 3
25291 \begin_inset space \thinspace{}
25292 \end_inset
25293
25294 cm.
25295  The change must be made before the multiple columns' start.
25296  The predefined value is 13
25297 \begin_inset space \thinspace{}
25298 \end_inset
25299
25300 pt.
25301 \end_layout
25302
25303 \begin_layout Standard
25304 For this example 
25305 \series bold
25306
25307 \backslash
25308 multicolsep
25309 \series default
25310  was set to 2.5
25311 \begin_inset space \thinspace{}
25312 \end_inset
25313
25314 cm:
25315 \end_layout
25316
25317 \begin_layout Standard
25318 \begin_inset ERT
25319 status open
25320
25321 \begin_layout Plain Layout
25322
25323
25324 \backslash
25325 setlength{
25326 \backslash
25327 multicolsep}{2.5cm}
25328 \end_layout
25329
25330 \end_inset
25331
25332
25333 \end_layout
25334
25335 \begin_layout Standard
25336 \begin_inset Flex Multiple Columns
25337 status open
25338
25339 \begin_layout Plain Layout
25340
25341 \size small
25342 All day I turned these facts over in my mind, endeavouring to hit upon some
25343  theory which could reconcile them all, and to find that line of least resistanc
25344 e which my poor friend had declared to be the starting-point of every investigat
25345 ion.
25346  I confess that I made little progress.
25347  In the evening I strolled across the Park, and found myself about six o'clock
25348  at the Oxford Street end of Park Lane.
25349  A group of loafers upon the pavements, all staring up at a particular window,
25350  directed me to the house which I had come to see.
25351  A tall, thin man with coloured glasses, whom I strongly suspected of being
25352  a plain-clothes detective, was pointing out some theory of his own, while
25353  the others crowded round to listen to what he said.
25354  I got as near him as I could, but his observations seemed to me to be absurd,
25355  so I withdrew again in some disgust.
25356  As I did so I struck against an elderly, deformed man, who had been behind
25357  me, and I knocked down several books which he was carrying.
25358 \end_layout
25359
25360 \end_inset
25361
25362
25363 \end_layout
25364
25365 \begin_layout Standard
25366 \begin_inset Note Greyedout
25367 status open
25368
25369 \begin_layout Plain Layout
25370
25371 \series bold
25372 Note:
25373 \series default
25374  The values you set with 
25375 \series bold
25376
25377 \backslash
25378 setlength
25379 \series default
25380  will be used for all following multiple columns until you change them again.
25381 \end_layout
25382
25383 \end_inset
25384
25385
25386 \end_layout
25387
25388 \begin_layout Standard
25389 \begin_inset ERT
25390 status collapsed
25391
25392 \begin_layout Plain Layout
25393
25394
25395 \backslash
25396 setlength{
25397 \backslash
25398 multicolsep}{13pt}
25399 \end_layout
25400
25401 \end_inset
25402
25403
25404 \begin_inset Note Note
25405 status collapsed
25406
25407 \begin_layout Plain Layout
25408 go back to the default
25409 \end_layout
25410
25411 \end_inset
25412
25413
25414 \end_layout
25415
25416 \begin_layout Standard
25417 \begin_inset Newpage newpage
25418 \end_inset
25419
25420
25421 \end_layout
25422
25423 \begin_layout Subsubsection
25424 Column Breaks
25425 \end_layout
25426
25427 \begin_layout Standard
25428 A column break can be forced by inserting the command 
25429 \series bold
25430
25431 \backslash
25432 columnbreak{}
25433 \series default
25434  as \SpecialChar TeX
25435  Code to that position in the text where the column should be broken.
25436  Note that this leads in most cases to whitespace in the text.
25437 \begin_inset Newline newline
25438 \end_inset
25439
25440 Here is an example:
25441 \end_layout
25442
25443 \begin_layout Standard
25444 \begin_inset Flex Multiple Columns
25445 status open
25446
25447 \begin_layout Plain Layout
25448
25449 \size small
25450 \begin_inset Quotes eld
25451 \end_inset
25452
25453 You're surprised to see me, sir,
25454 \begin_inset Quotes erd
25455 \end_inset
25456
25457  said he, in a strange, croaking voice.
25458 \end_layout
25459
25460 \begin_layout Plain Layout
25461
25462 \size small
25463 I acknowledged that I was.
25464 \end_layout
25465
25466 \begin_layout Plain Layout
25467
25468 \size small
25469 \begin_inset Quotes eld
25470 \end_inset
25471
25472 Well, I've a conscience, sir, and when I chanced to see you go into this
25473  house, as I came hobbling after you, I thought to myself, I'll just step
25474  in and see that kind gentleman, and tell him that if I was a bit gruff
25475  in my manner there was not any harm meant, and that I am much obliged to
25476  him for picking up my books.
25477 \begin_inset Quotes erd
25478 \end_inset
25479
25480
25481 \end_layout
25482
25483 \begin_layout Plain Layout
25484
25485 \size small
25486 \begin_inset Quotes eld
25487 \end_inset
25488
25489 You make too much of a trifle,
25490 \begin_inset Quotes erd
25491 \end_inset
25492
25493  said I.
25494  
25495 \begin_inset Quotes eld
25496 \end_inset
25497
25498 May I ask how you knew who I was?
25499 \begin_inset Quotes erd
25500 \end_inset
25501
25502  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
25503 \begin_inset ERT
25504 status collapsed
25505
25506 \begin_layout Plain Layout
25507
25508
25509 \backslash
25510 columnbreak{}
25511 \end_layout
25512
25513 \end_inset
25514
25515
25516 \end_layout
25517
25518 \begin_layout Plain Layout
25519
25520 \size small
25521 \begin_inset Quotes eld
25522 \end_inset
25523
25524 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25525  you'll find my little bookshop at the corner of Church Street, and very
25526  happy to see you, I am sure.
25527  Maybe you collect yourself, sir.
25528  Here's 
25529 \noun on
25530 British
25531 \begin_inset space ~
25532 \end_inset
25533
25534 Birds
25535 \noun default
25536 , and 
25537 \noun on
25538 Catullus
25539 \noun default
25540 , and 
25541 \noun on
25542 The Holy War
25543 \noun default
25544 –a bargain, every one of them.
25545  With five volumes you could just fill that gap on that second shelf.
25546  It looks untidy, does it not, sir?
25547 \begin_inset Quotes erd
25548 \end_inset
25549
25550
25551 \end_layout
25552
25553 \end_inset
25554
25555
25556 \end_layout
25557
25558 \begin_layout Subsubsection
25559 Column Separation
25560 \end_layout
25561
25562 \begin_layout Standard
25563 The width of the columns is automatically calculated, but you can modify
25564  the space between the columns.
25565  This is done by changing the length 
25566 \series bold
25567
25568 \backslash
25569 columnsep
25570 \series default
25571 .
25572  Its predefined value is 10
25573 \begin_inset space \thinspace{}
25574 \end_inset
25575
25576 pt.
25577  Here is an example where 
25578 \series bold
25579
25580 \backslash
25581 columnsep
25582 \series default
25583  is set to 3
25584 \begin_inset space \thinspace{}
25585 \end_inset
25586
25587 cm:
25588 \end_layout
25589
25590 \begin_layout Standard
25591 \begin_inset ERT
25592 status open
25593
25594 \begin_layout Plain Layout
25595
25596
25597 \backslash
25598 setlength{
25599 \backslash
25600 columnsep}{3cm}
25601 \end_layout
25602
25603 \end_inset
25604
25605
25606 \end_layout
25607
25608 \begin_layout Standard
25609 \begin_inset Flex Multiple Columns
25610 status open
25611
25612 \begin_layout Plain Layout
25613
25614 \size small
25615 My observations of No.
25616 \begin_inset space \space{}
25617 \end_inset
25618
25619 427 Park Lane did little to clear up the problem in which I was interested.
25620  The house was separated from the street by a low wall and railing, the
25621  whole not more than five feet high.
25622  It was perfectly easy, therefore, for anyone to get into the garden, but
25623  the window was entirely inaccessible, since there was no water pipe or
25624  anything which could help the most active man to climb it.
25625  More puzzled than ever, I retraced my steps to Kensington.
25626  I had not been in my study five minutes when the maid entered to say that
25627  a person desired to see me.
25628  To my astonishment it was none other than my strange old book collector,
25629  his sharp, wizened face peering out from a frame of white hair, and his
25630  precious volumes, a dozen of them at least, wedged under his right arm.
25631 \end_layout
25632
25633 \end_inset
25634
25635
25636 \end_layout
25637
25638 \begin_layout Standard
25639 \begin_inset ERT
25640 status collapsed
25641
25642 \begin_layout Plain Layout
25643
25644
25645 \backslash
25646 setlength{
25647 \backslash
25648 columnsep}{10pt}
25649 \end_layout
25650
25651 \end_inset
25652
25653
25654 \begin_inset Note Note
25655 status collapsed
25656
25657 \begin_layout Plain Layout
25658 go back to the default
25659 \end_layout
25660
25661 \end_inset
25662
25663
25664 \end_layout
25665
25666 \begin_layout Subsubsection
25667 Vertical Lines
25668 \end_layout
25669
25670 \begin_layout Standard
25671 Between the columns a rule with a width of the length 
25672 \series bold
25673
25674 \backslash
25675 columnseprule
25676 \series default
25677  is placed.
25678  If this rule width is set to 0
25679 \begin_inset space \thinspace{}
25680 \end_inset
25681
25682 pt (this is the default), the rule is suppressed.
25683  In the following example the rule is 2
25684 \begin_inset space \thinspace{}
25685 \end_inset
25686
25687 pt wide:
25688 \end_layout
25689
25690 \begin_layout Standard
25691 \begin_inset ERT
25692 status open
25693
25694 \begin_layout Plain Layout
25695
25696
25697 \backslash
25698 setlength{
25699 \backslash
25700 columnseprule}{2pt}
25701 \end_layout
25702
25703 \end_inset
25704
25705
25706 \end_layout
25707
25708 \begin_layout Standard
25709 \begin_inset Flex Multiple Columns
25710 status open
25711
25712 \begin_layout Plain Layout
25713
25714 \size small
25715 \begin_inset Quotes eld
25716 \end_inset
25717
25718 You're surprised to see me, sir,
25719 \begin_inset Quotes erd
25720 \end_inset
25721
25722  said he, in a strange, croaking voice.
25723 \end_layout
25724
25725 \begin_layout Plain Layout
25726
25727 \size small
25728 I acknowledged that I was.
25729 \end_layout
25730
25731 \begin_layout Plain Layout
25732
25733 \size small
25734 \begin_inset Quotes eld
25735 \end_inset
25736
25737 Well, I've a conscience, sir, and when I chanced to see you go into this
25738  house, as I came hobbling after you, I thought to myself, I'll just step
25739  in and see that kind gentleman, and tell him that if I was a bit gruff
25740  in my manner there was not any harm meant, and that I am much obliged to
25741  him for picking up my books.
25742 \begin_inset Quotes erd
25743 \end_inset
25744
25745
25746 \end_layout
25747
25748 \begin_layout Plain Layout
25749
25750 \size small
25751 \begin_inset Quotes eld
25752 \end_inset
25753
25754 You make too much of a trifle,
25755 \begin_inset Quotes erd
25756 \end_inset
25757
25758  said I.
25759  
25760 \begin_inset Quotes eld
25761 \end_inset
25762
25763 May I ask how you knew who I was?
25764 \begin_inset Quotes erd
25765 \end_inset
25766
25767
25768 \end_layout
25769
25770 \begin_layout Plain Layout
25771
25772 \size small
25773 \begin_inset Quotes eld
25774 \end_inset
25775
25776 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25777  you'll find my little bookshop at the corner of Church Street, and very
25778  happy to see you, I am sure.
25779  Maybe you collect yourself, sir.
25780  Here's 
25781 \noun on
25782 British
25783 \begin_inset space ~
25784 \end_inset
25785
25786 Birds
25787 \noun default
25788 , and 
25789 \noun on
25790 Catullus
25791 \noun default
25792 , and 
25793 \noun on
25794 The Holy War
25795 \noun default
25796 –a bargain, every one of them.
25797  With five volumes you could just fill that gap on that second shelf.
25798  It looks untidy, does it not, sir?
25799 \begin_inset Quotes erd
25800 \end_inset
25801
25802
25803 \end_layout
25804
25805 \end_inset
25806
25807
25808 \end_layout
25809
25810 \begin_layout Standard
25811 \begin_inset VSpace defskip
25812 \end_inset
25813
25814
25815 \end_layout
25816
25817 \begin_layout Standard
25818 The rule can be colored by redefining the command 
25819 \series bold
25820
25821 \backslash
25822 columnseprulecolor
25823 \series default
25824 .
25825  This is done by inserting the command
25826 \begin_inset Newline newline
25827 \end_inset
25828
25829
25830 \series bold
25831
25832 \backslash
25833 renewcommand{
25834 \backslash
25835 columnseprulecolor}{
25836 \backslash
25837 color{red}}
25838 \series default
25839
25840 \begin_inset Newline newline
25841 \end_inset
25842
25843 as \SpecialChar TeX
25844  Code before the multicolumn inset.
25845  Replace 
25846 \series bold
25847 red
25848 \series default
25849  in this command by a color of your choice.
25850  You can use all pre- and self-defined colors.
25851  See the 
25852 \emph on
25853 EmbeddedObjects
25854 \emph default
25855  manual, section 
25856 \emph on
25857 Colored
25858 \begin_inset space ~
25859 \end_inset
25860
25861 Tables
25862 \emph default
25863  for more information about pre- and self-defined colors.
25864  To go back to the default color insert the command
25865 \begin_inset Newline newline
25866 \end_inset
25867
25868
25869 \series bold
25870
25871 \backslash
25872 renewcommand{
25873 \backslash
25874 columnseprulecolor}{
25875 \backslash
25876 normalcolor}
25877 \series default
25878
25879 \begin_inset Newline newline
25880 \end_inset
25881
25882 Here is the example with a cyan rule and 1
25883 \begin_inset space \thinspace{}
25884 \end_inset
25885
25886 cm column separation:
25887 \end_layout
25888
25889 \begin_layout Standard
25890 \begin_inset ERT
25891 status open
25892
25893 \begin_layout Plain Layout
25894
25895
25896 \backslash
25897 setlength{
25898 \backslash
25899 columnsep}{1cm}
25900 \end_layout
25901
25902 \begin_layout Plain Layout
25903
25904
25905 \backslash
25906 renewcommand{
25907 \backslash
25908 columnseprulecolor}{
25909 \backslash
25910 color{cyan}}
25911 \end_layout
25912
25913 \end_inset
25914
25915
25916 \end_layout
25917
25918 \begin_layout Standard
25919 \begin_inset Flex Multiple Columns
25920 status open
25921
25922 \begin_layout Plain Layout
25923
25924 \size small
25925 \begin_inset Quotes eld
25926 \end_inset
25927
25928 You're surprised to see me, sir,
25929 \begin_inset Quotes erd
25930 \end_inset
25931
25932  said he, in a strange, croaking voice.
25933 \end_layout
25934
25935 \begin_layout Plain Layout
25936
25937 \size small
25938 I acknowledged that I was.
25939 \end_layout
25940
25941 \begin_layout Plain Layout
25942
25943 \size small
25944 \begin_inset Quotes eld
25945 \end_inset
25946
25947 Well, I've a conscience, sir, and when I chanced to see you go into this
25948  house, as I came hobbling after you, I thought to myself, I'll just step
25949  in and see that kind gentleman, and tell him that if I was a bit gruff
25950  in my manner there was not any harm meant, and that I am much obliged to
25951  him for picking up my books.
25952 \begin_inset Quotes erd
25953 \end_inset
25954
25955
25956 \end_layout
25957
25958 \begin_layout Plain Layout
25959
25960 \size small
25961 \begin_inset Quotes eld
25962 \end_inset
25963
25964 You make too much of a trifle,
25965 \begin_inset Quotes erd
25966 \end_inset
25967
25968  said I.
25969  
25970 \begin_inset Quotes eld
25971 \end_inset
25972
25973 May I ask how you knew who I was?
25974 \begin_inset Quotes erd
25975 \end_inset
25976
25977
25978 \end_layout
25979
25980 \begin_layout Plain Layout
25981
25982 \size small
25983 \begin_inset Quotes eld
25984 \end_inset
25985
25986 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25987  you'll find my little bookshop at the corner of Church Street, and very
25988  happy to see you, I am sure.
25989  Maybe you collect yourself, sir.
25990  Here's 
25991 \noun on
25992 British
25993 \begin_inset space ~
25994 \end_inset
25995
25996 Birds
25997 \noun default
25998 , and 
25999 \noun on
26000 Catullus
26001 \noun default
26002 , and 
26003 \noun on
26004 The Holy War
26005 \noun default
26006 –a bargain, every one of them.
26007  With five volumes you could just fill that gap on that second shelf.
26008  It looks untidy, does it not, sir?
26009 \begin_inset Quotes erd
26010 \end_inset
26011
26012
26013 \end_layout
26014
26015 \end_inset
26016
26017
26018 \end_layout
26019
26020 \begin_layout Standard
26021 \begin_inset ERT
26022 status collapsed
26023
26024 \begin_layout Plain Layout
26025
26026
26027 \backslash
26028 setlength{
26029 \backslash
26030 columnseprule}{0pt}
26031 \end_layout
26032
26033 \begin_layout Plain Layout
26034
26035
26036 \backslash
26037 renewcommand{
26038 \backslash
26039 columnseprulecolor}{
26040 \backslash
26041 normalcolor}
26042 \end_layout
26043
26044 \end_inset
26045
26046
26047 \begin_inset Note Note
26048 status collapsed
26049
26050 \begin_layout Plain Layout
26051 go back to the default
26052 \end_layout
26053
26054 \end_inset
26055
26056
26057 \end_layout
26058
26059 \begin_layout Section
26060 Non-standard Paragraph Shapes
26061 \end_layout
26062
26063 \begin_layout Standard
26064 \noindent
26065 \SpecialChar LaTeX
26066  as well as any other text processor uses by default rectangular paragraphs.
26067  For special cases like for example posters, invitation cards or poems you
26068  can modify the paragraph shape to one of your choice.
26069  This can be done by using the \SpecialChar LaTeX
26070 -package 
26071 \series bold
26072 shapepar
26073 \series default
26074  which is loaded by using in the document settings the module 
26075 \family sans
26076 Custom paragraph shapes
26077 \family default
26078 .
26079 \end_layout
26080
26081 \begin_layout Subsection
26082 Predefined shapes
26083 \end_layout
26084
26085 \begin_layout Standard
26086
26087 \series bold
26088 shapepar
26089 \series default
26090  provides the following shapes:
26091 \end_layout
26092
26093 \begin_layout Standard
26094 \begin_inset Tabular
26095 <lyxtabular version="3" rows="13" columns="3">
26096 <features booktabs="true" islongtable="true" longtabularalignment="center">
26097 <column alignment="center" valignment="middle" width="16col%">
26098 <column alignment="center" valignment="middle" width="40col%">
26099 <column alignment="center" valignment="middle" width="35col%">
26100 <row endhead="true">
26101 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26102 \begin_inset Text
26103
26104 \begin_layout Plain Layout
26105 Name
26106 \end_layout
26107
26108 \end_inset
26109 </cell>
26110 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26111 \begin_inset Text
26112
26113 \begin_layout Plain Layout
26114 Description
26115 \end_layout
26116
26117 \end_inset
26118 </cell>
26119 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26120 \begin_inset Text
26121
26122 \begin_layout Plain Layout
26123 Annotation
26124 \end_layout
26125
26126 \end_inset
26127 </cell>
26128 </row>
26129 <row>
26130 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26131 \begin_inset Text
26132
26133 \begin_layout Plain Layout
26134 CDlabel
26135 \end_layout
26136
26137 \end_inset
26138 </cell>
26139 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26140 \begin_inset Text
26141
26142 \begin_layout Plain Layout
26143 Circle with circular hole (in the size of a CD/DVD)
26144 \end_layout
26145
26146 \end_inset
26147 </cell>
26148 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26149 \begin_inset Text
26150
26151 \begin_layout Plain Layout
26152 Cannot be scaled, take care there is not too much text
26153 \end_layout
26154
26155 \end_inset
26156 </cell>
26157 </row>
26158 <row>
26159 <cell alignment="center" valignment="top" topline="true" usebox="none">
26160 \begin_inset Text
26161
26162 \begin_layout Plain Layout
26163 Circle
26164 \end_layout
26165
26166 \end_inset
26167 </cell>
26168 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26169 \begin_inset Text
26170
26171 \begin_layout Plain Layout
26172 Circle
26173 \end_layout
26174
26175 \end_inset
26176 </cell>
26177 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26178 \begin_inset Text
26179
26180 \begin_layout Plain Layout
26181 Fragile, calculation might fail
26182 \end_layout
26183
26184 \end_inset
26185 </cell>
26186 </row>
26187 <row>
26188 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26189 \begin_inset Text
26190
26191 \begin_layout Plain Layout
26192 Diamond
26193 \end_layout
26194
26195 \end_inset
26196 </cell>
26197 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26198 \begin_inset Text
26199
26200 \begin_layout Plain Layout
26201 Rhomboid (symbolizing a 
26202 \begin_inset Quotes eld
26203 \end_inset
26204
26205 diamond
26206 \begin_inset Quotes erd
26207 \end_inset
26208
26209 )
26210 \end_layout
26211
26212 \end_inset
26213 </cell>
26214 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26215 \begin_inset Text
26216
26217 \begin_layout Plain Layout
26218 -
26219 \end_layout
26220
26221 \end_inset
26222 </cell>
26223 </row>
26224 <row>
26225 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26226 \begin_inset Text
26227
26228 \begin_layout Plain Layout
26229 Heart
26230 \end_layout
26231
26232 \end_inset
26233 </cell>
26234 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26235 \begin_inset Text
26236
26237 \begin_layout Plain Layout
26238 Heart-like shape
26239 \end_layout
26240
26241 \end_inset
26242 </cell>
26243 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26244 \begin_inset Text
26245
26246 \begin_layout Plain Layout
26247 -
26248 \end_layout
26249
26250 \end_inset
26251 </cell>
26252 </row>
26253 <row>
26254 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26255 \begin_inset Text
26256
26257 \begin_layout Plain Layout
26258 Hexagon
26259 \end_layout
26260
26261 \end_inset
26262 </cell>
26263 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26264 \begin_inset Text
26265
26266 \begin_layout Plain Layout
26267 Hexagon
26268 \end_layout
26269
26270 \end_inset
26271 </cell>
26272 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26273 \begin_inset Text
26274
26275 \begin_layout Plain Layout
26276 -
26277 \end_layout
26278
26279 \end_inset
26280 </cell>
26281 </row>
26282 <row>
26283 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26284 \begin_inset Text
26285
26286 \begin_layout Plain Layout
26287 Nut
26288 \end_layout
26289
26290 \end_inset
26291 </cell>
26292 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26293 \begin_inset Text
26294
26295 \begin_layout Plain Layout
26296 Nut for bolt (hexagon with circular hole)
26297 \end_layout
26298
26299 \end_inset
26300 </cell>
26301 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26302 \begin_inset Text
26303
26304 \begin_layout Plain Layout
26305 -
26306 \end_layout
26307
26308 \end_inset
26309 </cell>
26310 </row>
26311 <row>
26312 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26313 \begin_inset Text
26314
26315 \begin_layout Plain Layout
26316 Square
26317 \end_layout
26318
26319 \end_inset
26320 </cell>
26321 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26322 \begin_inset Text
26323
26324 \begin_layout Plain Layout
26325 Square
26326 \end_layout
26327
26328 \end_inset
26329 </cell>
26330 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26331 \begin_inset Text
26332
26333 \begin_layout Plain Layout
26334 -
26335 \end_layout
26336
26337 \end_inset
26338 </cell>
26339 </row>
26340 <row>
26341 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26342 \begin_inset Text
26343
26344 \begin_layout Plain Layout
26345 Star
26346 \end_layout
26347
26348 \end_inset
26349 </cell>
26350 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26351 \begin_inset Text
26352
26353 \begin_layout Plain Layout
26354 Five-point star
26355 \end_layout
26356
26357 \end_inset
26358 </cell>
26359 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26360 \begin_inset Text
26361
26362 \begin_layout Plain Layout
26363 -
26364 \end_layout
26365
26366 \end_inset
26367 </cell>
26368 </row>
26369 <row>
26370 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26371 \begin_inset Text
26372
26373 \begin_layout Plain Layout
26374 Candle
26375 \end_layout
26376
26377 \end_inset
26378 </cell>
26379 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26380 \begin_inset Text
26381
26382 \begin_layout Plain Layout
26383 Burning candle
26384 \end_layout
26385
26386 \end_inset
26387 </cell>
26388 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26389 \begin_inset Text
26390
26391 \begin_layout Plain Layout
26392 -
26393 \end_layout
26394
26395 \end_inset
26396 </cell>
26397 </row>
26398 <row>
26399 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26400 \begin_inset Text
26401
26402 \begin_layout Plain Layout
26403 Drop down/up
26404 \end_layout
26405
26406 \end_inset
26407 </cell>
26408 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26409 \begin_inset Text
26410
26411 \begin_layout Plain Layout
26412 Normal/reversed rain drop
26413 \end_layout
26414
26415 \end_inset
26416 </cell>
26417 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26418 \begin_inset Text
26419
26420 \begin_layout Plain Layout
26421 Fragile, calculation might fail
26422 \end_layout
26423
26424 \end_inset
26425 </cell>
26426 </row>
26427 <row>
26428 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26429 \begin_inset Text
26430
26431 \begin_layout Plain Layout
26432 \SpecialChar TeX
26433
26434 \end_layout
26435
26436 \end_inset
26437 </cell>
26438 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26439 \begin_inset Text
26440
26441 \begin_layout Plain Layout
26442 The \SpecialChar TeX
26443  logo
26444 \end_layout
26445
26446 \end_inset
26447 </cell>
26448 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26449 \begin_inset Text
26450
26451 \begin_layout Plain Layout
26452 -
26453 \end_layout
26454
26455 \end_inset
26456 </cell>
26457 </row>
26458 <row>
26459 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26460 \begin_inset Text
26461
26462 \begin_layout Plain Layout
26463 Triangle up/down/
26464 \begin_inset Newline newline
26465 \end_inset
26466
26467 left/right
26468 \end_layout
26469
26470 \end_inset
26471 </cell>
26472 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26473 \begin_inset Text
26474
26475 \begin_layout Plain Layout
26476 Triangles in different orientations
26477 \end_layout
26478
26479 \end_inset
26480 </cell>
26481 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26482 \begin_inset Text
26483
26484 \begin_layout Plain Layout
26485 -
26486 \end_layout
26487
26488 \end_inset
26489 </cell>
26490 </row>
26491 </lyxtabular>
26492
26493 \end_inset
26494
26495
26496 \end_layout
26497
26498 \begin_layout Standard
26499 To use a shape for your paragraph, simply select it in \SpecialChar LyX
26500 's pull-down box
26501  for environments in the toolbar.
26502 \end_layout
26503
26504 \begin_layout Standard
26505 \begin_inset Newpage newpage
26506 \end_inset
26507
26508
26509 \end_layout
26510
26511 \begin_layout Standard
26512 Here is an example paragraph in the shape of a nut:
26513 \end_layout
26514
26515 \begin_layout Standard
26516 \begin_inset VSpace bigskip
26517 \end_inset
26518
26519
26520 \end_layout
26521
26522 \begin_layout Nut
26523
26524 \lang latin
26525 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26526  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26527  voluptua.
26528  At vero eos et accusam et justo duo dolores et ea rebum.
26529  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26530  sit amet.
26531  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26532  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26533  voluptua.
26534 \end_layout
26535
26536 \begin_layout Standard
26537 \begin_inset VSpace bigskip
26538 \end_inset
26539
26540
26541 \end_layout
26542
26543 \begin_layout Standard
26544 \begin_inset Note Greyedout
26545 status open
26546
26547 \begin_layout Plain Layout
26548
26549 \series bold
26550 Note
26551 \series default
26552 : shapepar paragraphs cannot run over a page break.
26553 \end_layout
26554
26555 \end_inset
26556
26557
26558 \end_layout
26559
26560 \begin_layout Standard
26561 \begin_inset VSpace bigskip
26562 \end_inset
26563
26564
26565 \end_layout
26566
26567 \begin_layout Standard
26568
26569 \series bold
26570 shapepar
26571 \series default
26572  takes care that the shape will always be preserved, no matter how much
26573  text is in the paragraph.
26574  Therefore the paragraph size changes with the amount of contained text.
26575  This can lead to paragraph sizes exceeding the page margins.
26576  To demonstrate the size scaling, here is the same example paragraph but
26577  with twice as much text:
26578 \end_layout
26579
26580 \begin_layout Standard
26581 \begin_inset Newpage newpage
26582 \end_inset
26583
26584
26585 \end_layout
26586
26587 \begin_layout Nut
26588
26589 \lang latin
26590 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26591  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26592  voluptua.
26593  At vero eos et accusam et justo duo dolores et ea rebum.
26594  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26595  sit amet.
26596  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26597  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26598  voluptua.
26599  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26600  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26601  voluptua.
26602  At vero eos et accusam et justo duo dolores et ea rebum.
26603  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26604  sit amet.
26605  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26606  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26607  voluptua.
26608 \end_layout
26609
26610 \begin_layout Standard
26611 \begin_inset VSpace bigskip
26612 \end_inset
26613
26614
26615 \end_layout
26616
26617 \begin_layout Standard
26618 An exception is the shape 
26619 \family sans
26620 CDlabel
26621 \family default
26622 .
26623  It cannot be scaled because it must fit the size of a CD/DVD.
26624  Therefore the amount of text that fits into the shape is limited.
26625 \begin_inset Newline newline
26626 \end_inset
26627
26628 The 
26629 \family sans
26630 drop
26631 \family default
26632  shapes and the 
26633 \family sans
26634 circle
26635 \family default
26636  shape are fragile, meaning that the calculation of their size can fail,
26637  depending on the amount of text.
26638  You will then get the \SpecialChar LaTeX
26639  error 
26640 \begin_inset Quotes eld
26641 \end_inset
26642
26643 Arithmetic overflow
26644 \begin_inset Quotes erd
26645 \end_inset
26646
26647 .
26648  In this case one can try to remove or add some text; if nothing works one
26649  has to use another shape.
26650 \end_layout
26651
26652 \begin_layout Standard
26653 \begin_inset VSpace bigskip
26654 \end_inset
26655
26656
26657 \end_layout
26658
26659 \begin_layout Standard
26660 For shapes with tips you will maybe see that \SpecialChar LaTeX
26661 's hyphenation routine fails
26662  for text in the tips.
26663  Therefore it is often necessary to add hyphenation points 
26664 \family sans
26665 (
26666 \begin_inset Info
26667 type  "shortcut"
26668 arg   "specialchar-insert hyphenation"
26669 \end_inset
26670
26671
26672 \family default
26673 ) to the corresponding text parts.
26674 \end_layout
26675
26676 \begin_layout Standard
26677 \begin_inset VSpace bigskip
26678 \end_inset
26679
26680
26681 \end_layout
26682
26683 \begin_layout Standard
26684 Shapepar paragraphs are either always centered or placed on the page so
26685  that their left border touches the left page margin.
26686  You can therefore not use the paragraph dialog to align such paragraphs.
26687  A solution is to put the paragraph into a minipage or parbox and align
26688  the box.
26689  The problem is hereby to find the right width for the box.
26690  Because if it is too wide and you center the box, the paragraph is not
26691  centered too because it sticks at the left side of the box.
26692  So you might have to play a bit with the width until it fits.
26693  Here are two heart-shaped paragraphs, the first one is not aligned, the
26694  second one is right-aligned:
26695 \end_layout
26696
26697 \begin_layout Standard
26698 \begin_inset Newpage newpage
26699 \end_inset
26700
26701
26702 \end_layout
26703
26704 \begin_layout Heart
26705 \noindent
26706
26707 \lang latin
26708 Lo\SpecialChar softhyphen
26709 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26710  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26711  voluptua.
26712  At vero eos et accusam et justo duo dolores et ea rebum.
26713  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26714  sit amet.
26715 \end_layout
26716
26717 \begin_layout Standard
26718 \begin_inset VSpace bigskip
26719 \end_inset
26720
26721
26722 \end_layout
26723
26724 \begin_layout Standard
26725 \noindent
26726 \align right
26727 \begin_inset Box Frameless
26728 position "t"
26729 hor_pos "c"
26730 has_inner_box 1
26731 inner_pos "t"
26732 use_parbox 1
26733 use_makebox 0
26734 width "42col%"
26735 special "none"
26736 height "1in"
26737 height_special "totalheight"
26738 thickness "0.4pt"
26739 separation "3pt"
26740 shadowsize "4pt"
26741 framecolor "black"
26742 backgroundcolor "none"
26743 status open
26744
26745 \begin_layout Heart
26746 \noindent
26747
26748 \lang latin
26749 Lo\SpecialChar softhyphen
26750 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26751  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26752  voluptua.
26753  At vero eos et accusam et justo duo dolores et ea rebum.
26754  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26755  sit amet.
26756 \end_layout
26757
26758 \end_inset
26759
26760
26761 \end_layout
26762
26763 \begin_layout Subsection
26764 Custom shapes
26765 \end_layout
26766
26767 \begin_layout Standard
26768 You can define any shape you want.
26769  Doing this manually is a lot of work because every coordinate must be specified.
26770  But there is a way to let the computer calculate the coordinates:
26771 \end_layout
26772
26773 \begin_layout Enumerate
26774 Install the program 
26775 \begin_inset CommandInset href
26776 LatexCommand href
26777 name "Jpgfdraw"
26778 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
26779 literal "false"
26780
26781 \end_inset
26782
26783 .
26784 \end_layout
26785
26786 \begin_layout Enumerate
26787 In 
26788 \family sans
26789 Jpgfdraw
26790 \family default
26791  go to the menu 
26792 \family sans
26793 TeX/LaTeX\SpecialChar menuseparator
26794 Settings\SpecialChar menuseparator
26795 Set Normal Size
26796 \family default
26797  and select the font size you are using in your document.
26798  For example this document uses the size 12
26799 \begin_inset space \thinspace{}
26800 \end_inset
26801
26802 pt.
26803 \end_layout
26804
26805 \begin_layout Enumerate
26806 Draw a shape.
26807 \end_layout
26808
26809 \begin_layout Enumerate
26810 Use the menu 
26811 \family sans
26812 TeX/LaTeX\SpecialChar menuseparator
26813 Shapepar
26814 \family default
26815  to export the shape to coordinates.
26816  In the appearing dialog use either the outline of your shape for the coordinate
26817 s or the path itself.
26818 \begin_inset Foot
26819 status collapsed
26820
26821 \begin_layout Plain Layout
26822 For more information see 
26823 \begin_inset CommandInset href
26824 LatexCommand href
26825 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
26826 literal "false"
26827
26828 \end_inset
26829
26830
26831 \end_layout
26832
26833 \end_inset
26834
26835
26836 \end_layout
26837
26838 \begin_layout Standard
26839 The coordinates are written into a \SpecialChar TeX
26840  file.
26841  To use it for your \SpecialChar LyX
26842  document
26843 \end_layout
26844
26845 \begin_layout Enumerate
26846 Place the cursor before the first character of your paragraph (or into a
26847  new empty one).
26848 \end_layout
26849
26850 \begin_layout Enumerate
26851 Open in \SpecialChar LyX
26852  the menu 
26853 \family sans
26854 Insert\SpecialChar menuseparator
26855 File\SpecialChar menuseparator
26856 Child
26857 \begin_inset space ~
26858 \end_inset
26859
26860 Document
26861 \family default
26862 , select the file and use 
26863 \family sans
26864 Input
26865 \family default
26866  as 
26867 \family sans
26868 Include Type.
26869 \end_layout
26870
26871 \begin_layout Standard
26872 \begin_inset VSpace defskip
26873 \end_inset
26874
26875
26876 \end_layout
26877
26878 \begin_layout Standard
26879 \begin_inset Note Greyedout
26880 status open
26881
26882 \begin_layout Plain Layout
26883
26884 \series bold
26885 Note
26886 \series default
26887 : The changed shape only applies to the current paragraph; everything is
26888  reset to normal for the next paragraph.
26889  Therefore the shape definition file must be input into every paragraph
26890  with the desired shape.
26891 \end_layout
26892
26893 \end_inset
26894
26895
26896 \end_layout
26897
26898 \begin_layout Standard
26899 \begin_inset VSpace bigskip
26900 \end_inset
26901
26902
26903 \end_layout
26904
26905 \begin_layout Standard
26906 Here is an example:
26907 \end_layout
26908
26909 \begin_layout Standard
26910 \begin_inset VSpace bigskip
26911 \end_inset
26912
26913
26914 \end_layout
26915
26916 \begin_layout Standard
26917 \begin_inset CommandInset include
26918 LatexCommand input
26919 filename "SpecialParagraphShape.tex"
26920
26921 \end_inset
26922
26923
26924 \lang latin
26925 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26926  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26927  voluptua.
26928  At vero eos et accusam et justo duo dolores et ea rebum.
26929  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26930  sit amet.
26931  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26932  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26933  voluptua.
26934 \end_layout
26935
26936 \begin_layout Standard
26937 \begin_inset VSpace bigskip
26938 \end_inset
26939
26940
26941 \end_layout
26942
26943 \begin_layout Standard
26944
26945 \series bold
26946 A tip:
26947 \series default
26948  to draw complexer shapes in 
26949 \family sans
26950 Jpgfdraw
26951 \family default
26952  you can draw the shape in a program of your choice and import the resulting
26953  image to 
26954 \family sans
26955 Jpgfdraw
26956 \family default
26957 .
26958  Then you only need to draw a line or spline along the outline of the image.
26959 \end_layout
26960
26961 \begin_layout Standard
26962 \begin_inset VSpace bigskip
26963 \end_inset
26964
26965
26966 \end_layout
26967
26968 \begin_layout Standard
26969 The module 
26970 \family sans
26971 Custom paragraph shapes
26972 \family default
26973  also provides the two commands 
26974 \family sans
26975 shapepar
26976 \family default
26977  and 
26978 \family sans
26979 Shapepar
26980 \family default
26981  which can be used to define custom shapes coordinate by coordinate.
26982 \begin_inset Foot
26983 status collapsed
26984
26985 \begin_layout Plain Layout
26986 These commands are internally used for all shapes described here.
26987 \end_layout
26988
26989 \end_inset
26990
26991  For information how these styles are used and about further customization
26992  possibilities, have a look at the documentation of the package 
26993 \series bold
26994 shapepar
26995 \series default
26996
26997 \begin_inset CommandInset citation
26998 LatexCommand cite
26999 key "shapepar"
27000 literal "true"
27001
27002 \end_inset
27003
27004 .
27005 \end_layout
27006
27007 \begin_layout Bibliography
27008 \begin_inset CommandInset bibitem
27009 LatexCommand bibitem
27010 key "multicol"
27011 literal "true"
27012
27013 \end_inset
27014
27015 Documentation of the \SpecialChar LaTeX
27016 -package 
27017 \begin_inset CommandInset href
27018 LatexCommand href
27019 name "multicol"
27020 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
27021 literal "false"
27022
27023 \end_inset
27024
27025
27026 \end_layout
27027
27028 \begin_layout Bibliography
27029 \begin_inset CommandInset bibitem
27030 LatexCommand bibitem
27031 key "shapepar"
27032 literal "true"
27033
27034 \end_inset
27035
27036 Documentation of the \SpecialChar LaTeX
27037 -package 
27038 \begin_inset CommandInset href
27039 LatexCommand href
27040 name "shapepar"
27041 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"
27042 literal "false"
27043
27044 \end_inset
27045
27046
27047 \end_layout
27048
27049 \end_body
27050 \end_document