]> git.lyx.org Git - lyx.git/blob - lib/doc/Additional.lyx
Additional.lyx: fix more errors and outdates I came across while translating
[lyx.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 Chi
3353 \change_deleted -712698321 1501147443
3354 I
3355 \change_inserted -712698321 1501147443
3356 l
3357 \change_unchanged
3358 d
3359 \begin_inset space ~
3360 \end_inset
3361
3362 Document
3363 \end_layout
3364
3365 \end_inset
3366
3367 .
3368  When you click on this selection a small box is inserted into the file
3369  at the current cursor location.
3370  Clicking on the box raises a dialog which allows you to select the file
3371  to be included, and the method of its inclusion.
3372  
3373 \end_layout
3374
3375 \begin_layout Standard
3376 The file selection box should by now be obvious.
3377  The three inclusion methods are 
3378 \begin_inset Quotes eld
3379 \end_inset
3380
3381 include
3382 \begin_inset Quotes erd
3383 \end_inset
3384
3385
3386 \begin_inset Quotes eld
3387 \end_inset
3388
3389 input
3390 \begin_inset Quotes erd
3391 \end_inset
3392
3393 , and 
3394 \begin_inset Quotes eld
3395 \end_inset
3396
3397 verbatim
3398 \begin_inset Quotes erd
3399 \end_inset
3400
3401 .
3402  The difference between 
3403 \begin_inset Quotes eld
3404 \end_inset
3405
3406 include
3407 \begin_inset Quotes erd
3408 \end_inset
3409
3410  and 
3411 \begin_inset Quotes eld
3412 \end_inset
3413
3414 input
3415 \begin_inset Quotes erd
3416 \end_inset
3417
3418  is really only meaningful to \SpecialChar LaTeX
3419 perts, but the practical difference is that
3420  files that are 
3421 \begin_inset Quotes eld
3422 \end_inset
3423
3424 included
3425 \begin_inset Quotes erd
3426 \end_inset
3427
3428  are typeset beginning on a new page, while files that are 
3429 \begin_inset Quotes eld
3430 \end_inset
3431
3432 inputted
3433 \begin_inset Quotes erd
3434 \end_inset
3435
3436  are typeset starting on the current page.
3437 \end_layout
3438
3439 \begin_layout Standard
3440 Generally, the master file is converted into a full \SpecialChar LaTeX
3441  file before typesetting,
3442  while the included files are converted to \SpecialChar LaTeX
3443  files that do not have all the
3444  preamble information.
3445 \end_layout
3446
3447 \begin_layout Standard
3448
3449 \begin_inset Quotes eld
3450 \end_inset
3451
3452 verbatim
3453 \begin_inset Quotes erd
3454 \end_inset
3455
3456  included file allows you to include a file typeset exactly as it appears
3457  in the file, i.
3458 \begin_inset space \thinspace{}
3459 \end_inset
3460
3461 e.
3462 \begin_inset space \space{}
3463 \end_inset
3464
3465 in 
3466 \begin_inset Flex Code
3467 status collapsed
3468
3469 \begin_layout Plain Layout
3470 verbatim
3471 \end_layout
3472
3473 \end_inset
3474
3475  mode, with the characters set in a fixed-width typewriter font.
3476  Normally, spaces in this file are invisible, though two consecutive spaces
3477  are conserved, unlike \SpecialChar LyX
3478 's normal treatment of spaces.
3479  However, setting the 
3480 \begin_inset Flex Noun
3481 status collapsed
3482
3483 \begin_layout Plain Layout
3484 Mark
3485 \begin_inset space ~
3486 \end_inset
3487
3488 spaces
3489 \begin_inset space ~
3490 \end_inset
3491
3492 in
3493 \begin_inset space ~
3494 \end_inset
3495
3496 output
3497 \end_layout
3498
3499 \end_inset
3500
3501  checkbox typesets a mark to unambiguously define the presence of a space.
3502  
3503 \end_layout
3504
3505 \begin_layout Subsection
3506 Cross-References Between Files
3507 \end_layout
3508
3509 \begin_layout Standard
3510 \begin_inset Box Shadowbox
3511 position "t"
3512 hor_pos "c"
3513 has_inner_box 1
3514 inner_pos "t"
3515 use_parbox 0
3516 use_makebox 0
3517 width "100col%"
3518 special "none"
3519 height "1in"
3520 height_special "totalheight"
3521 thickness "0.4pt"
3522 separation "3pt"
3523 shadowsize "4pt"
3524 framecolor "black"
3525 backgroundcolor "none"
3526 status open
3527
3528 \begin_layout Plain Layout
3529 This section is somewhat out of date.
3530  Need to describe default master documents and how children are opened when
3531  the master is.
3532  [[FIXME]]
3533 \end_layout
3534
3535 \end_inset
3536
3537
3538 \end_layout
3539
3540 \begin_layout Standard
3541 It is possible to set up cross-references between the different files.
3542  First, open all the files in question: let's call them A and B in a two
3543  file example, where B is included in A.
3544  Let's say you insert a label in A, then want to reference it in B.
3545  Open the cross-reference dialog whilst in document B, and you can select
3546  the 
3547 \begin_inset Quotes eld
3548 \end_inset
3549
3550 buffer
3551 \begin_inset Quotes erd
3552 \end_inset
3553
3554  to use.
3555 \end_layout
3556
3557 \begin_layout Subsection
3558 Bibliography Lists in all Subdocuments
3559 \end_layout
3560
3561 \begin_layout Standard
3562 \begin_inset Box Frameless
3563 position "t"
3564 hor_pos "c"
3565 has_inner_box 1
3566 inner_pos "t"
3567 use_parbox 0
3568 use_makebox 0
3569 width "100col%"
3570 special "none"
3571 height "1in"
3572 height_special "totalheight"
3573 thickness "0.4pt"
3574 separation "3pt"
3575 shadowsize "4pt"
3576 framecolor "black"
3577 backgroundcolor "none"
3578 status open
3579
3580 \begin_layout Plain Layout
3581 This section also needs updating.
3582  There is now material about this on the wiki, and it could be copied here.
3583 \end_layout
3584
3585 \end_inset
3586
3587
3588 \end_layout
3589
3590 \begin_layout Standard
3591 Copy the bibliography list with all entries to all subdocuments and transform
3592  them to a comment.
3593  This way \SpecialChar LyX
3594  will find the 
3595 \begin_inset Flex Code
3596 status collapsed
3597
3598 \begin_layout Plain Layout
3599 .bib
3600 \end_layout
3601
3602 \end_inset
3603
3604 -files and you can easily insert references without making the bibliography
3605  list visible.
3606 \end_layout
3607
3608 \begin_layout Standard
3609 As the bibliography list is in a comment, \SpecialChar LaTeX
3610  won't use it and the references
3611  will look like this: [?], instead of like this: [1].
3612  One solution is to use the \SpecialChar LaTeX
3613 -package 
3614 \begin_inset Flex Code
3615 status collapsed
3616
3617 \begin_layout Plain Layout
3618 comment
3619 \end_layout
3620
3621 \end_inset
3622
3623  that will only include comments by processing the files separately.
3624  To do this, add in the \SpecialChar LaTeX
3625  preamble of every subdocument the following:
3626 \end_layout
3627
3628 \begin_layout LyX-Code
3629
3630 \backslash
3631 usepackage{comment}
3632 \end_layout
3633
3634 \begin_layout LyX-Code
3635
3636 \backslash
3637 includecomment{comment}
3638 \end_layout
3639
3640 \begin_layout Standard
3641 See also 
3642 \begin_inset Flex URL
3643 status collapsed
3644
3645 \begin_layout Plain Layout
3646
3647 http://wiki.lyx.org/FAQ/Unsorted#toc31
3648 \end_layout
3649
3650 \end_inset
3651
3652 .
3653 \end_layout
3654
3655 \begin_layout Section
3656 \SpecialChar LyX
3657  Archives
3658 \end_layout
3659
3660 \begin_layout Standard
3661 Users sometimes need to be able to 
3662 \begin_inset Quotes eld
3663 \end_inset
3664
3665 bundle
3666 \begin_inset Quotes erd
3667 \end_inset
3668
3669  a \SpecialChar LyX
3670  file together with all the images (and other files) on which it depends,
3671  either for sending to a publisher or for sharing with a co-author.
3672  \SpecialChar LyX
3673  2.0 includes a Python script (
3674 \begin_inset Flex Code
3675 status collapsed
3676
3677 \begin_layout Plain Layout
3678 lyxpak.py
3679 \end_layout
3680
3681 \end_inset
3682
3683 ) that automates this process.
3684  To use it, you must have either the 
3685 \begin_inset Flex Code
3686 status collapsed
3687
3688 \begin_layout Plain Layout
3689 zipfile
3690 \end_layout
3691
3692 \end_inset
3693
3694  or 
3695 \begin_inset Flex Code
3696 status collapsed
3697
3698 \begin_layout Plain Layout
3699 tarfile
3700 \end_layout
3701
3702 \end_inset
3703
3704  python modules installed on your system.
3705  By default, the script prefers the 
3706 \begin_inset Flex Code
3707 status collapsed
3708
3709 \begin_layout Plain Layout
3710 gzip
3711 \end_layout
3712
3713 \end_inset
3714
3715 -compressed 
3716 \begin_inset Flex Code
3717 status collapsed
3718
3719 \begin_layout Plain Layout
3720 tar
3721 \end_layout
3722
3723 \end_inset
3724
3725  format on Unix-like systems and the 
3726 \begin_inset Flex Code
3727 status collapsed
3728
3729 \begin_layout Plain Layout
3730 zip
3731 \end_layout
3732
3733 \end_inset
3734
3735  format on Windows.
3736 \end_layout
3737
3738 \begin_layout Standard
3739 \SpecialChar LyX
3740 's configuration process will set the script up to export a `\SpecialChar LyX
3741  Archive',
3742  and this format will then be available under 
3743 \begin_inset Flex Code
3744 status collapsed
3745
3746 \begin_layout Plain Layout
3747 File\SpecialChar menuseparator
3748 Export
3749 \end_layout
3750
3751 \end_inset
3752
3753 .
3754 \end_layout
3755
3756 \begin_layout Standard
3757 Independently of the platform, the generation of a particular archive format
3758  can be forced by adding either the 
3759 \begin_inset Flex Code
3760 status collapsed
3761
3762 \begin_layout Plain Layout
3763 -t
3764 \end_layout
3765
3766 \end_inset
3767
3768  (for the 
3769 \begin_inset Flex Code
3770 status collapsed
3771
3772 \begin_layout Plain Layout
3773 tar
3774 \end_layout
3775
3776 \end_inset
3777
3778  format) or 
3779 \begin_inset Flex Code
3780 status collapsed
3781
3782 \begin_layout Plain Layout
3783 -z
3784 \end_layout
3785
3786 \end_inset
3787
3788  (for the 
3789 \begin_inset Flex Code
3790 status collapsed
3791
3792 \begin_layout Plain Layout
3793 zip
3794 \end_layout
3795
3796 \end_inset
3797
3798  format) switch to the 
3799 \begin_inset Flex Code
3800 status collapsed
3801
3802 \begin_layout Plain Layout
3803 \SpecialChar LyX
3804 \SpecialChar menuseparator
3805 \SpecialChar LyX
3806  Archive
3807 \end_layout
3808
3809 \end_inset
3810
3811  converter in 
3812 \begin_inset Flex Code
3813 status collapsed
3814
3815 \begin_layout Plain Layout
3816 Tools\SpecialChar menuseparator
3817 Preferences\SpecialChar menuseparator
3818 File Handling\SpecialChar menuseparator
3819 Converters
3820 \end_layout
3821
3822 \end_inset
3823
3824 .
3825  (Make sure you add the switch after the script name, not before it.)
3826 \end_layout
3827
3828 \begin_layout Section
3829 Fancy Headers and Footers
3830 \end_layout
3831
3832 \begin_layout Standard
3833 The default page layout is rather plain; for an 
3834 \begin_inset Flex Code
3835 status collapsed
3836
3837 \begin_layout Plain Layout
3838 article
3839 \end_layout
3840
3841 \end_inset
3842
3843  document class, all you get is a centered page number at the bottom of
3844  the page.
3845  This document uses KOMA-script's book class, so it appears to be a bit
3846  fancier.
3847  But to really put on a show, you need to set the document page style to
3848  
3849 \begin_inset Quotes eld
3850 \end_inset
3851
3852 fancy
3853 \begin_inset Quotes erd
3854 \end_inset
3855
3856 , as mentioned in the 
3857 \emph on
3858 User Guide
3859 \emph default
3860 .
3861  This section describes the \SpecialChar LaTeX
3862  code you need to insert in your \SpecialChar LaTeX
3863  preamble in
3864  order to get the desired effects.
3865 \end_layout
3866
3867 \begin_layout Standard
3868 For more information on fancy headers, see the 
3869 \begin_inset Flex Code
3870 status collapsed
3871
3872 \begin_layout Plain Layout
3873 fancyhdr
3874 \end_layout
3875
3876 \end_inset
3877
3878  package documentation.
3879  (
3880 \begin_inset Flex URL
3881 status collapsed
3882
3883 \begin_layout Plain Layout
3884
3885 http://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
3886 \end_layout
3887
3888 \end_inset
3889
3890 )
3891 \end_layout
3892
3893 \begin_layout Standard
3894 The page header is divided into three fields, not surprisingly labeled 
3895 \begin_inset Quotes eld
3896 \end_inset
3897
3898 left
3899 \begin_inset Quotes erd
3900 \end_inset
3901
3902
3903 \begin_inset Quotes eld
3904 \end_inset
3905
3906 center
3907 \begin_inset Quotes erd
3908 \end_inset
3909
3910 , and 
3911 \begin_inset Quotes eld
3912 \end_inset
3913
3914 right
3915 \begin_inset Quotes erd
3916 \end_inset
3917
3918 .
3919  The footer is also divided into these three fields.
3920  The \SpecialChar LaTeX
3921  commands to set these fields in the simplest manner are 
3922 \begin_inset Flex Code
3923 status collapsed
3924
3925 \begin_layout Plain Layout
3926
3927 \backslash
3928 lhead
3929 \end_layout
3930
3931 \end_inset
3932
3933
3934 \begin_inset Flex Code
3935 status collapsed
3936
3937 \begin_layout Plain Layout
3938
3939 \backslash
3940 chead
3941 \end_layout
3942
3943 \end_inset
3944
3945
3946 \begin_inset Flex Code
3947 status collapsed
3948
3949 \begin_layout Plain Layout
3950
3951 \backslash
3952 rhead
3953 \end_layout
3954
3955 \end_inset
3956
3957
3958 \begin_inset Flex Code
3959 status collapsed
3960
3961 \begin_layout Plain Layout
3962
3963 \backslash
3964 lfoot
3965 \end_layout
3966
3967 \end_inset
3968
3969 , etc.
3970  Suppose you wish to put your name in the upper left hand corner of each
3971  page.
3972  Simply insert the following command in the preamble: 
3973 \end_layout
3974
3975 \begin_layout Standard
3976
3977 \family typewriter
3978
3979 \backslash
3980 lhead{John Q.
3981  DocWriter}
3982 \end_layout
3983
3984 \begin_layout Standard
3985 You will now see your name in the upper left.
3986  If a field has a default entry that you would like to get rid of (often
3987  the page number appears in the central footer) simply include a command
3988  with a blank argument, e.
3989 \begin_inset space \thinspace{}
3990 \end_inset
3991
3992 g.:
3993 \end_layout
3994
3995 \begin_layout Standard
3996
3997 \family typewriter
3998
3999 \backslash
4000 cfoot{}
4001 \end_layout
4002
4003 \begin_layout Standard
4004 Let's get really fancy: lets put the section number with the word 
4005 \begin_inset Quotes eld
4006 \end_inset
4007
4008 Section
4009 \begin_inset Quotes erd
4010 \end_inset
4011
4012  (e.
4013 \begin_inset space \thinspace{}
4014 \end_inset
4015
4016 g.
4017 \begin_inset space \space{}
4018 \end_inset
4019
4020 Section 3) in the upper left, the page number (e.
4021 \begin_inset space \thinspace{}
4022 \end_inset
4023
4024 g.
4025 \begin_inset space \space{}
4026 \end_inset
4027
4028 Page 4) in the upper right, your name in the lower left, and the date in
4029  the lower right.
4030  The following commands should now appear in the preamble:
4031 \end_layout
4032
4033 \begin_layout Standard
4034
4035 \family typewriter
4036
4037 \backslash
4038 lhead{Section 
4039 \backslash
4040 thesection}
4041 \end_layout
4042
4043 \begin_layout Standard
4044
4045 \family typewriter
4046
4047 \backslash
4048 chead{}
4049 \end_layout
4050
4051 \begin_layout Standard
4052
4053 \family typewriter
4054
4055 \backslash
4056 rhead{Page 
4057 \backslash
4058 thepage}
4059 \end_layout
4060
4061 \begin_layout Standard
4062
4063 \family typewriter
4064
4065 \backslash
4066 lfoot{John Q.
4067  DocWriter}
4068 \end_layout
4069
4070 \begin_layout Standard
4071
4072 \family typewriter
4073
4074 \backslash
4075 cfoot{}
4076 \end_layout
4077
4078 \begin_layout Standard
4079
4080 \family typewriter
4081
4082 \backslash
4083 rfoot{
4084 \backslash
4085 today}
4086 \end_layout
4087
4088 \begin_layout Standard
4089 The commands 
4090 \begin_inset Flex Code
4091 status collapsed
4092
4093 \begin_layout Plain Layout
4094
4095 \backslash
4096 thesection
4097 \end_layout
4098
4099 \end_inset
4100
4101  and 
4102 \begin_inset Flex Code
4103 status collapsed
4104
4105 \begin_layout Plain Layout
4106
4107 \backslash
4108 thepage
4109 \end_layout
4110
4111 \end_inset
4112
4113  access \SpecialChar LaTeX
4114 's section and page counters, and so print out the current section
4115  and page numbers.
4116  
4117 \begin_inset Flex Code
4118 status collapsed
4119
4120 \begin_layout Plain Layout
4121
4122 \backslash
4123 today
4124 \end_layout
4125
4126 \end_inset
4127
4128  simply prints out today's date.
4129 \end_layout
4130
4131 \begin_layout Standard
4132 The thicknesses of the horizontal rules drawn beneath the header and above
4133  the footer can also be modified.
4134  If you don't want one of the rules, set its thickness to 0.
4135  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
4136  Use commands
4137 \family typewriter
4138  
4139 \family default
4140 like 
4141 \begin_inset Flex Code
4142 status collapsed
4143
4144 \begin_layout Plain Layout
4145
4146 \backslash
4147 renewcommand{
4148 \backslash
4149 headrulewidth}{0.4pt}
4150 \end_layout
4151
4152 \end_inset
4153
4154  and 
4155 \begin_inset Flex Code
4156 status collapsed
4157
4158 \begin_layout Plain Layout
4159
4160 \backslash
4161 renewcommand{
4162 \backslash
4163 footrulewidth}{0.4pt}
4164 \end_layout
4165
4166 \end_inset
4167
4168  to set the thicknesses.
4169 \end_layout
4170
4171 \begin_layout Standard
4172 You can switch the header/footer settings on and off for individual pages
4173  using commands like 
4174 \begin_inset Flex Code
4175 status collapsed
4176
4177 \begin_layout Plain Layout
4178
4179 \backslash
4180 thispagestyle{empty}
4181 \end_layout
4182
4183 \end_inset
4184
4185
4186 \begin_inset Flex Code
4187 status collapsed
4188
4189 \begin_layout Plain Layout
4190
4191 \backslash
4192 thispagestyle{plain}
4193 \end_layout
4194
4195 \end_inset
4196
4197 , and 
4198 \begin_inset Flex Code
4199 status collapsed
4200
4201 \begin_layout Plain Layout
4202
4203 \backslash
4204 thispagestyle{fancy}
4205 \end_layout
4206
4207 \end_inset
4208
4209 .
4210  Simply insert them in the text on the page you want changed and mark them
4211  as \SpecialChar TeX
4212  code.
4213  In fact, title pages are marked as plain by default, while following pages
4214  are marked fancy when using the global fancy setting.
4215 \end_layout
4216
4217 \begin_layout Standard
4218 As a final example, it is possible to include an image in the header or
4219  footer.
4220  Suppose you want to put a company logo in the upper lefthand corner.
4221  You might try something like
4222 \end_layout
4223
4224 \begin_layout Standard
4225
4226 \family typewriter
4227
4228 \backslash
4229 lhead{
4230 \backslash
4231 resizebox{1in}{!}{
4232 \backslash
4233 includegraphics{logo.eps}}}
4234 \end_layout
4235
4236 \begin_layout Standard
4237 \noindent
4238 (you may need to preface this with 
4239 \begin_inset Flex Code
4240 status collapsed
4241
4242 \begin_layout Plain Layout
4243 \noindent
4244
4245 \backslash
4246 usepackage{graphics}
4247 \end_layout
4248
4249 \end_inset
4250
4251  if you don't include graphics elsewhere in your document).
4252 \end_layout
4253
4254 \begin_layout Section
4255 Itemize Bullet Selection
4256 \begin_inset CommandInset label
4257 LatexCommand label
4258 name "sec:bullet"
4259
4260 \end_inset
4261
4262
4263 \end_layout
4264
4265 \begin_layout Standard
4266 by
4267 \noun on
4268  Allan Rae
4269 \end_layout
4270
4271 \begin_layout Subsection
4272 Introduction
4273 \end_layout
4274
4275 \begin_layout Standard
4276 \SpecialChar LyX
4277  provides 216 bullet shapes that can be accessed from a simple dialog.
4278  Using this dialog you can easily specify what bullet shape to use at each
4279  level of an itemized list.
4280  These settings are document-wide so you won't be able to specify different
4281  sets of bullets for different paragraphs.
4282 \begin_inset Foot
4283 status collapsed
4284
4285 \begin_layout Plain Layout
4286 Well, actually you can but you'll have to do it by hand.
4287 \end_layout
4288
4289 \end_inset
4290
4291
4292 \end_layout
4293
4294 \begin_layout Subsection
4295 How it looks
4296 \end_layout
4297
4298 \begin_layout Standard
4299 Open the dialog by selecting the 
4300 \begin_inset Flex Noun
4301 status collapsed
4302
4303 \begin_layout Plain Layout
4304 Document\SpecialChar menuseparator
4305 Settings
4306 \end_layout
4307
4308 \end_inset
4309
4310  menu item and then select the 
4311 \begin_inset Flex Noun
4312 status collapsed
4313
4314 \begin_layout Plain Layout
4315 Bullets
4316 \end_layout
4317
4318 \end_inset
4319
4320  tab.
4321 \end_layout
4322
4323 \begin_layout Standard
4324 The dialog provides you with a table of bullet shapes.
4325  A column of buttons on the left of the table provides access to the six
4326  different panels of bullet shapes.
4327  The row of buttons across the top is used to select which bullet depth
4328  you are changing.
4329  A text entry under the table shows the currently selected bullet shape's
4330  \SpecialChar LaTeX
4331  equivalent and this can be edited if desired.
4332  If you do modify the text you will also need to specify any needed packages
4333  in the \SpecialChar LaTeX
4334  preamble.
4335 \end_layout
4336
4337 \begin_layout Standard
4338 The six panels are divided up by the packages they require.
4339  The following table shows the mappings from button name to \SpecialChar LaTeX
4340  package.
4341 \end_layout
4342
4343 \begin_layout Standard
4344 \align center
4345 \begin_inset Tabular
4346 <lyxtabular version="3" rows="7" columns="2">
4347 <features tabularvalignment="middle">
4348 <column alignment="center" valignment="top" width="0pt">
4349 <column alignment="center" valignment="top" width="0pt">
4350 <row>
4351 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4352 \begin_inset Text
4353
4354 \begin_layout Plain Layout
4355
4356 \family roman
4357 \series medium
4358 \shape up
4359 \size normal
4360 \emph off
4361 \bar no
4362 \noun off
4363 \color none
4364 Button
4365 \end_layout
4366
4367 \end_inset
4368 </cell>
4369 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4370 \begin_inset Text
4371
4372 \begin_layout Plain Layout
4373
4374 \family roman
4375 \series medium
4376 \shape up
4377 \size normal
4378 \emph off
4379 \bar no
4380 \noun off
4381 \color none
4382 Packages Required
4383 \end_layout
4384
4385 \end_inset
4386 </cell>
4387 </row>
4388 <row>
4389 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4390 \begin_inset Text
4391
4392 \begin_layout Plain Layout
4393
4394 \family sans
4395 \series medium
4396 \shape up
4397 \size normal
4398 \emph off
4399 \bar no
4400 \noun off
4401 \color none
4402 Standard
4403 \end_layout
4404
4405 \end_inset
4406 </cell>
4407 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4408 \begin_inset Text
4409
4410 \begin_layout Plain Layout
4411
4412 \series medium
4413 \shape up
4414 \size normal
4415 \emph off
4416 \bar no
4417 \noun off
4418 \color none
4419 base \SpecialChar LaTeX
4420
4421 \end_layout
4422
4423 \end_inset
4424 </cell>
4425 </row>
4426 <row>
4427 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4428 \begin_inset Text
4429
4430 \begin_layout Plain Layout
4431
4432 \family sans
4433 \series medium
4434 \shape up
4435 \size normal
4436 \emph off
4437 \bar no
4438 \noun off
4439 \color none
4440 Maths
4441 \end_layout
4442
4443 \end_inset
4444 </cell>
4445 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4446 \begin_inset Text
4447
4448 \begin_layout Plain Layout
4449
4450 \family typewriter
4451 \series medium
4452 \shape up
4453 \size normal
4454 \emph off
4455 \bar no
4456 \noun off
4457 \color none
4458 amssymb.sty
4459 \end_layout
4460
4461 \end_inset
4462 </cell>
4463 </row>
4464 <row>
4465 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4466 \begin_inset Text
4467
4468 \begin_layout Plain Layout
4469
4470 \family sans
4471 \series medium
4472 \shape up
4473 \size normal
4474 \emph off
4475 \bar no
4476 \noun off
4477 \color none
4478 Ding1
4479 \end_layout
4480
4481 \end_inset
4482 </cell>
4483 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4484 \begin_inset Text
4485
4486 \begin_layout Plain Layout
4487
4488 \family typewriter
4489 \series medium
4490 \shape up
4491 \size normal
4492 \emph off
4493 \bar no
4494 \noun off
4495 \color none
4496 pifont.sty
4497 \end_layout
4498
4499 \end_inset
4500 </cell>
4501 </row>
4502 <row>
4503 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4504 \begin_inset Text
4505
4506 \begin_layout Plain Layout
4507
4508 \family sans
4509 \series medium
4510 \shape up
4511 \size normal
4512 \emph off
4513 \bar no
4514 \noun off
4515 \color none
4516 Ding2
4517 \end_layout
4518
4519 \end_inset
4520 </cell>
4521 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4522 \begin_inset Text
4523
4524 \begin_layout Plain Layout
4525
4526 \family typewriter
4527 \series medium
4528 \shape up
4529 \size normal
4530 \emph off
4531 \bar no
4532 \noun off
4533 \color none
4534 pifont.sty
4535 \end_layout
4536
4537 \end_inset
4538 </cell>
4539 </row>
4540 <row>
4541 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4542 \begin_inset Text
4543
4544 \begin_layout Plain Layout
4545
4546 \family sans
4547 \series medium
4548 \shape up
4549 \size normal
4550 \emph off
4551 \bar no
4552 \noun off
4553 \color none
4554 Ding3
4555 \end_layout
4556
4557 \end_inset
4558 </cell>
4559 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4560 \begin_inset Text
4561
4562 \begin_layout Plain Layout
4563
4564 \family typewriter
4565 \series medium
4566 \shape up
4567 \size normal
4568 \emph off
4569 \bar no
4570 \noun off
4571 \color none
4572 pifont.sty
4573 \end_layout
4574
4575 \end_inset
4576 </cell>
4577 </row>
4578 <row>
4579 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4580 \begin_inset Text
4581
4582 \begin_layout Plain Layout
4583
4584 \family sans
4585 \series medium
4586 \shape up
4587 \size normal
4588 \emph off
4589 \bar no
4590 \noun off
4591 \color none
4592 Ding4
4593 \end_layout
4594
4595 \end_inset
4596 </cell>
4597 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4598 \begin_inset Text
4599
4600 \begin_layout Plain Layout
4601
4602 \family typewriter
4603 \series medium
4604 \shape up
4605 \size normal
4606 \emph off
4607 \bar no
4608 \noun off
4609 \color none
4610 pifont.sty
4611 \end_layout
4612
4613 \end_inset
4614 </cell>
4615 </row>
4616 </lyxtabular>
4617
4618 \end_inset
4619
4620
4621 \end_layout
4622
4623 \begin_layout Standard
4624 \SpecialChar LyX
4625  doesn't stop you using bullets from packages you don't have.
4626  If you get errors from \SpecialChar LaTeX
4627  when you try to view or print the file, then it
4628  is likely you are missing a package.
4629 \begin_inset Foot
4630 status collapsed
4631
4632 \begin_layout Plain Layout
4633 \SpecialChar LyX
4634  doesn't restrict your use since you may be editing locally and exporting
4635  elsewhere.
4636 \end_layout
4637
4638 \end_inset
4639
4640
4641 \end_layout
4642
4643 \begin_layout Subsection
4644 How to use it
4645 \end_layout
4646
4647 \begin_layout Standard
4648 Select which bullet depth you want to change then select the bullet shape
4649  and size.
4650  Any changes will not be visible in \SpecialChar LyX
4651 , but are visible when viewing the document.
4652 \end_layout
4653
4654 \begin_layout Standard
4655 You can reset a bullet shape to the default simply by clicking your right
4656  mouse button on the appropriate bullet depth button.
4657 \begin_inset Foot
4658 status open
4659
4660 \begin_layout Plain Layout
4661 If you 
4662 \emph on
4663 really
4664 \emph default
4665  want to have multiple sets of paragraphs with different sets of bullets
4666  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
4667  code.
4668  The bullet selection dialog can help though because it provides you with
4669  the \SpecialChar LaTeX
4670  code for a wide range of bullet shapes.
4671  To make your own custom paragraphs you have the following options:
4672 \end_layout
4673
4674 \begin_layout Plain Layout
4675 \begin_inset ERT
4676 status open
4677
4678 \begin_layout Plain Layout
4679
4680
4681 \backslash
4682 let
4683 \backslash
4684 savelabelitemi=
4685 \backslash
4686 labelitemi
4687 \end_layout
4688
4689 \end_inset
4690
4691
4692 \end_layout
4693
4694 \begin_layout Plain Layout
4695 \begin_inset ERT
4696 status open
4697
4698 \begin_layout Plain Layout
4699
4700
4701 \backslash
4702 renewcommand
4703 \backslash
4704 labelitemi[0]{
4705 \backslash
4706 small
4707 \backslash
4708 (
4709 \backslash
4710 sharp
4711 \backslash
4712 )}
4713 \end_layout
4714
4715 \end_inset
4716
4717
4718 \end_layout
4719
4720 \begin_layout Itemize
4721 Use the \SpecialChar LaTeX
4722  command 
4723 \begin_inset Flex Code
4724 status collapsed
4725
4726 \begin_layout Plain Layout
4727
4728 \backslash
4729 renewcommand{}{}
4730 \end_layout
4731
4732 \end_inset
4733
4734  to specify a new bullet shape for a given depth.
4735  You'll also need to save the current bullet shape so you can restore it
4736  again afterwards.
4737  In this itemized list the following \SpecialChar LaTeX
4738  code was used to change the bullet
4739  used for the first depth.
4740 \end_layout
4741
4742 \begin_deeper
4743 \begin_layout LyX-Code
4744
4745 \backslash
4746 let
4747 \backslash
4748 savelabelitemi=
4749 \backslash
4750 labelitemi 
4751 \end_layout
4752
4753 \begin_layout LyX-Code
4754
4755 \backslash
4756 renewcommand
4757 \backslash
4758 labelitemi[0]{
4759 \backslash
4760 small
4761 \backslash
4762 (
4763 \backslash
4764 sharp
4765 \backslash
4766 )}
4767 \end_layout
4768
4769 \end_deeper
4770 \begin_layout Itemize
4771 Note that the itemize depth is specified in Roman numerals as part of the
4772  
4773 \family typewriter
4774
4775 \backslash
4776 labelitem
4777 \family default
4778  command.
4779 \end_layout
4780
4781 \begin_layout Itemize
4782
4783 \change_deleted -712698321 1501149643
4784 \begin_inset ERT
4785 status open
4786
4787 \begin_layout Plain Layout
4788
4789 \change_deleted -712698321 1501149634
4790
4791 [
4792 \change_unchanged
4793
4794 \backslash
4795 (
4796 \backslash
4797 star
4798 \backslash
4799 )
4800 \change_deleted -712698321 1501149636
4801 ]
4802 \change_unchanged
4803
4804 \end_layout
4805
4806 \end_inset
4807
4808
4809 \change_inserted -712698321 1501149643
4810
4811 \begin_inset Argument item:1
4812 status open
4813
4814 \begin_layout Plain Layout
4815
4816 \change_inserted -712698321 1501149643
4817 \begin_inset ERT
4818 status open
4819
4820 \begin_layout Plain Layout
4821
4822 \change_inserted -712698321 1501149643
4823
4824
4825 \backslash
4826 (
4827 \backslash
4828 star
4829 \backslash
4830 )
4831 \end_layout
4832
4833 \end_inset
4834
4835
4836 \change_unchanged
4837
4838 \end_layout
4839
4840 \end_inset
4841
4842
4843 \change_unchanged
4844  Specify each individual entry by starting each item with the bullet shape
4845  enclosed in 
4846 \change_deleted -712698321 1501149707
4847 square brackets
4848 \change_inserted -712698321 1501149740
4849
4850 \begin_inset Quotes eld
4851 \end_inset
4852
4853 Custom Item
4854 \begin_inset Quotes erd
4855 \end_inset
4856
4857  inset (available at 
4858 \family sans
4859 Insert\SpecialChar menuseparator
4860 Custom Item
4861 \family default
4862 )
4863 \change_unchanged
4864  and set as 
4865 \begin_inset Flex Noun
4866 status collapsed
4867
4868 \begin_layout Plain Layout
4869 \SpecialChar TeX
4870  Code
4871 \end_layout
4872
4873 \end_inset
4874
4875 .
4876  For example, this item was started with 
4877 \begin_inset Flex Code
4878 status collapsed
4879
4880 \begin_layout Plain Layout
4881
4882 \change_deleted -712698321 1501149692
4883 [
4884 \change_unchanged
4885
4886 \backslash
4887 (
4888 \backslash
4889 star
4890 \backslash
4891 )
4892 \change_deleted -712698321 1501149693
4893 ]
4894 \change_unchanged
4895
4896 \end_layout
4897
4898 \end_inset
4899
4900 .
4901 \end_layout
4902
4903 \begin_layout Plain Layout
4904 \begin_inset ERT
4905 status open
4906
4907 \begin_layout Plain Layout
4908
4909
4910 \backslash
4911 renewcommand
4912 \backslash
4913 labelitemi[0]{
4914 \backslash
4915 savelabelitemi}
4916 \end_layout
4917
4918 \end_inset
4919
4920
4921 \end_layout
4922
4923 \begin_layout Plain Layout
4924 You'll also need to revert the labelitem back to its previous setting for
4925  the global bullet shape settings to remain in effect.
4926  The way used here was:
4927 \end_layout
4928
4929 \begin_layout LyX-Code
4930
4931 \backslash
4932 renewcommand
4933 \backslash
4934 labelitemi[0]{
4935 \backslash
4936 savelabelitemi}
4937 \end_layout
4938
4939 \end_inset
4940
4941
4942 \end_layout
4943
4944 \begin_layout Chapter
4945 \SpecialChar LyX
4946  and the World Wide Web
4947 \end_layout
4948
4949 \begin_layout Standard
4950 \SpecialChar LyX
4951  has long supported the export of documents to various web-friendly formats,
4952  such as HTML.
4953  Before vers
4954 \change_inserted -712698321 1501076595
4955 i
4956 \change_unchanged
4957 on 2.0, however, HTML export was always accomplished by the use of external
4958  converters.
4959 \begin_inset Foot
4960 status collapsed
4961
4962 \begin_layout Plain Layout
4963 For details on the use of external converters with \SpecialChar LyX
4964 , see the 
4965 \emph on
4966 Converters
4967 \emph default
4968  section of the Customization manual.
4969 \end_layout
4970
4971 \end_inset
4972
4973  These fall into two large groups: there are converters that use \SpecialChar LaTeX
4974  as an
4975  intermediate format, such as 
4976 \begin_inset Flex Code
4977 status collapsed
4978
4979 \begin_layout Plain Layout
4980 htlatex
4981 \end_layout
4982
4983 \end_inset
4984
4985
4986 \begin_inset Flex Code
4987 status collapsed
4988
4989 \begin_layout Plain Layout
4990 html2latex
4991 \end_layout
4992
4993 \end_inset
4994
4995 , and 
4996 \begin_inset Flex Code
4997 status collapsed
4998
4999 \begin_layout Plain Layout
5000 plastex
5001 \end_layout
5002
5003 \end_inset
5004
5005 , relying upon \SpecialChar LyX
5006  to produce the \SpecialChar LaTeX
5007 ; and there is a converter that works directly
5008  on \SpecialChar LyX
5009  files, 
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  All of these have different advantages and disadvantages.
5022  
5023 \end_layout
5024
5025 \begin_layout Standard
5026 The \SpecialChar LaTeX
5027 -based converters have the advantage that, in principle, they know everythin
5028 g about the exported document that \SpecialChar LaTeX
5029  does.
5030  Such converters do not care, for example, if a certain block of code was
5031  produced by \SpecialChar LyX
5032  or was Evil Red Text.
5033  These converters know about 
5034 \begin_inset Flex Code
5035 status collapsed
5036
5037 \begin_layout Plain Layout
5038 aux
5039 \end_layout
5040
5041 \end_inset
5042
5043  files, counters, and references, and can often make use of the 
5044 \begin_inset Flex Code
5045 status collapsed
5046
5047 \begin_layout Plain Layout
5048 bbl
5049 \end_layout
5050
5051 \end_inset
5052
5053  files generated by Bib\SpecialChar TeX
5054 .
5055  On the other hand, \SpecialChar LaTeX
5056  is a very hard language to parse—it is sometimes said
5057  that only \SpecialChar TeX
5058  itself understands \SpecialChar TeX
5059 —and \SpecialChar LaTeX
5060 -based converters will often choke on
5061  what seem to be quite simple constructs; complex ones can throw them completely
5062 , and as of this writing, for example, the 
5063 \emph on
5064 Embedded Objects
5065 \emph default
5066  manual will not export with 
5067 \begin_inset Flex Code
5068 status collapsed
5069
5070 \begin_layout Plain Layout
5071 htlatex
5072 \end_layout
5073
5074 \end_inset
5075
5076 , though the others will.
5077  The other issue concerns how math is handled.
5078  These converters typically convert the formulae into little pictures that
5079  are then linked from the HTML document.
5080  Since these are actually generated by \SpecialChar LaTeX
5081 , they are accurate.
5082  But they do not scale well, and just getting them to look as if they are
5083  actually meant to be in your document—so that the font sizes seem to be
5084  roughly the same—can be a challenge.
5085 \end_layout
5086
5087 \begin_layout Standard
5088 Alex Fernandez's 
5089 \begin_inset Flex Code
5090 status collapsed
5091
5092 \begin_layout Plain Layout
5093 e\SpecialChar LyX
5094 er
5095 \end_layout
5096
5097 \end_inset
5098
5099  (
5100 \begin_inset CommandInset href
5101 LatexCommand href
5102 name "http://elyxer.nongnu.org/"
5103 target "http://elyxer.nongnu.org/"
5104 literal "false"
5105
5106 \end_inset
5107
5108 ) solves some of these problems.
5109  In particular, the formulae it produces scale perfectly, since it renders
5110  math using a combination of HTML and CSS rather than converting the formulae
5111  to images.
5112  But even moderately complex formula are rendered less well than with 
5113 \begin_inset Flex Code
5114 status collapsed
5115
5116 \begin_layout Plain Layout
5117 htlatex
5118 \end_layout
5119
5120 \end_inset
5121
5122 ; this reflects the limitations of HTML.
5123 \begin_inset Foot
5124 status collapsed
5125
5126 \begin_layout Plain Layout
5127 That said, 
5128 \begin_inset Flex Code
5129 status collapsed
5130
5131 \begin_layout Plain Layout
5132 e\SpecialChar LyX
5133 er
5134 \end_layout
5135
5136 \end_inset
5137
5138  can also use jsMath and MathJax for equations, but this setting is only
5139  available globally and requires one to have access to a server that runs
5140  the backend.
5141 \end_layout
5142
5143 \end_inset
5144
5145  More importantly (as of version 1.1.1, at least), 
5146 \begin_inset Flex Code
5147 status collapsed
5148
5149 \begin_layout Plain Layout
5150 e\SpecialChar LyX
5151 er
5152 \end_layout
5153
5154 \end_inset
5155
5156  has limited support for math macros and no support for user-defined paragraph
5157  or character styles.
5158  These limitations make 
5159 \begin_inset Flex Code
5160 status collapsed
5161
5162 \begin_layout Plain Layout
5163 e\SpecialChar LyX
5164 er
5165 \end_layout
5166
5167 \end_inset
5168
5169  unsuitable for many of the documents \SpecialChar LyX
5170  users produce.
5171  In principle, of course, these problems could be solved, but the \SpecialChar LyX
5172  developers
5173  have decided to follow a different path and have made \SpecialChar LyX
5174  itself capable of
5175  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
5176 , DocBook, and plaintext.
5177 \end_layout
5178
5179 \begin_layout Standard
5180 As of this writing, XHTML output remains under development and should probably
5181  be regarded as 
5182 \begin_inset Quotes eld
5183 \end_inset
5184
5185 experimental
5186 \begin_inset Quotes erd
5187 \end_inset
5188
5189 .
5190 \begin_inset Foot
5191 status collapsed
5192
5193 \begin_layout Plain Layout
5194 The file 
5195 \begin_inset Flex Code
5196 status collapsed
5197
5198 \begin_layout Plain Layout
5199 development/
5200 \change_inserted -712698321 1501078933
5201 HTML/
5202 \change_unchanged
5203 HTML.notes
5204 \end_layout
5205
5206 \end_inset
5207
5208 , which can be found in the \SpecialChar LyX
5209  source tree or 
5210 \begin_inset CommandInset href
5211 LatexCommand href
5212 name "accessed online"
5213 target "http://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
5214 literal "false"
5215
5216 \end_inset
5217
5218 , usually contains up-to-date information about the state of XHTML output.
5219  See also the list of XHTML bugs on 
5220 \begin_inset CommandInset href
5221 LatexCommand href
5222 name "the bug tracker"
5223 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"
5224 literal "false"
5225
5226 \end_inset
5227
5228 .
5229 \end_layout
5230
5231 \end_inset
5232
5233  Still, the developers have chosen this approach because it has several
5234  potential advantages over the other two.
5235 \end_layout
5236
5237 \begin_layout Standard
5238 These advantages are primarily due to the fact that the XHTML output routines,
5239  since they are part of \SpecialChar LyX
5240 , know everything \SpecialChar LyX
5241  knows about the document being
5242  exported.
5243 \begin_inset Foot
5244 status collapsed
5245
5246 \begin_layout Plain Layout
5247 Another advantage is that, since these routines are internal to \SpecialChar LyX
5248 , they are
5249  immune to changes in \SpecialChar LyX
5250 's file format, or to changes in the semantics of
5251  existing insets.
5252 \end_layout
5253
5254 \end_inset
5255
5256  So they know about the table of contents (as displayed in the outline),
5257  about the counters associated with different paragraph styles, and about
5258  user-defined styles.
5259  The XHTML output routines know what \SpecialChar LyX
5260  knows about internationalization,
5261  too, so they will output 
5262 \begin_inset Quotes eld
5263 \end_inset
5264
5265 Chapter 1
5266 \begin_inset Quotes erd
5267 \end_inset
5268
5269  or 
5270 \begin_inset Quotes eld
5271 \end_inset
5272
5273
5274 \lang ngerman
5275 Kapitel
5276 \lang english
5277  1
5278 \begin_inset Quotes erd
5279 \end_inset
5280
5281 , depending upon the language in effect at the time.
5282  
5283 \end_layout
5284
5285 \begin_layout Standard
5286 Quite generally, the output routines know what \SpecialChar LyX
5287  knows about document layout,
5288  that is, about how the document is to be rendered on screen.
5289  We use this information when we output the document as XHTML.
5290  In particular, \SpecialChar LyX
5291  
5292 \emph on
5293 automatically
5294 \emph default
5295  generates CSS style information corresponding to the layout information
5296  it uses to render the document on screen: if section headings are supposed
5297  to be sans-serif and bold as seen in \SpecialChar LyX
5298 , then (by default) they will be sans-seri
5299 f and bold when viewed in a web browser, too.
5300  And this is true not just for pre-defined styles, like Section, but for
5301  any style, including user-defined styles.
5302  Indeed, the XHTML output routines make no distinction between user-defined
5303  paragraph and character styles and \SpecialChar LyX
5304 's own pre-defined styles: in each case,
5305  everything \SpecialChar LyX
5306  knows about the styles is contained in the layout files.
5307  And much the same is true as regards pre-defined textual insets, such as
5308  footnotes, and various custom insets.
5309  
5310 \end_layout
5311
5312 \begin_layout Standard
5313 The result is that XHTML output can be customized and extended in exactly
5314  the same way \SpecialChar LaTeX
5315  output can be customized and extended: through layout files
5316  and modules.
5317  See chapter five of the 
5318 \emph on
5319 Customization 
5320 \emph default
5321 manual for the details.
5322 \end_layout
5323
5324 \begin_layout Standard
5325 The remainder of this chapter contains more detailed information on XHTML
5326  output, its limitations, and ways to work around those limitations.
5327 \end_layout
5328
5329 \begin_layout Section
5330 Math Output in XHTML
5331 \end_layout
5332
5333 \begin_layout Standard
5334 \SpecialChar LyX
5335  offers four choices for how math is rendered.
5336  These have various advantages and disadvantages:
5337 \end_layout
5338
5339 \begin_layout Itemize
5340 MathML
5341 \begin_inset Newline newline
5342 \end_inset
5343
5344 MathML is a dialect of XML designed specifically for mathematics on the
5345  web, and it typically renders very well in browsers that support it.
5346  The disadvantage is that not all browsers support MathML, and support is
5347  not complete even in the Gecko-based browsers, such as Firefox.
5348 \begin_inset Newline newline
5349 \end_inset
5350
5351 If \SpecialChar LyX
5352  is unable to render a formula as MathML—for example, if the formula
5353  uses the 
5354 \begin_inset Flex Code
5355 status collapsed
5356
5357 \begin_layout Plain Layout
5358 xymatrix
5359 \end_layout
5360
5361 \end_inset
5362
5363  package or ERT—then it will instead output the formula as an image.
5364  
5365 \end_layout
5366
5367 \begin_layout Itemize
5368 HTML
5369 \begin_inset Newline newline
5370 \end_inset
5371
5372 As mentioned above, 
5373 \begin_inset Flex Code
5374 status collapsed
5375
5376 \begin_layout Plain Layout
5377 elyxer
5378 \end_layout
5379
5380 \end_inset
5381
5382  outputs math as HTML, styled by CSS.
5383 \begin_inset Foot
5384 status collapsed
5385
5386 \begin_layout Plain Layout
5387 \SpecialChar LyX
5388  has borrowed some of the CSS for its HTML output from 
5389 \begin_inset Flex Code
5390 status collapsed
5391
5392 \begin_layout Plain Layout
5393 elyxer
5394 \end_layout
5395
5396 \end_inset
5397
5398 .
5399 \end_layout
5400
5401 \end_inset
5402
5403  For simple formulae, this can work quite well, though with more complicated
5404  formulae it tends to break down.
5405  Still, this method has the advantage that it is very widely supported and
5406  so it may be appropriate for documents that contain only a little, fairly
5407  simple math.
5408 \begin_inset Newline newline
5409 \end_inset
5410
5411 If Lyx is unable to render a formula as HTML—for example, if the formula
5412  uses the 
5413 \begin_inset Flex Code
5414 status collapsed
5415
5416 \begin_layout Plain Layout
5417 xymatrix
5418 \end_layout
5419
5420 \end_inset
5421
5422  package or ERT—then it will instead output the formula as an image.
5423  
5424 \end_layout
5425
5426 \begin_layout Itemize
5427 Images
5428 \begin_inset Newline newline
5429 \end_inset
5430
5431 Like 
5432 \begin_inset Flex Code
5433 status collapsed
5434
5435 \begin_layout Plain Layout
5436 htlatex
5437 \end_layout
5438
5439 \end_inset
5440
5441 , \SpecialChar LyX
5442  will output formulae as images, the very same images, in fact, that are
5443  used for instant preview.
5444 \begin_inset Foot
5445 status collapsed
5446
5447 \begin_layout Plain Layout
5448 Instant preview does 
5449 \emph on
5450 not 
5451 \emph default
5452 have to be on for images to be output, however.
5453 \end_layout
5454
5455 \end_inset
5456
5457  The advantage to this method is that the images are simply generated by
5458  \SpecialChar LaTeX
5459 , so they are very accurate.
5460  The disadvantage, as mentioned earlier, is that these are bitmapped images,
5461  so they do not scale terribly well, and one cannot copy them, etc.
5462
5463 \change_deleted -712698321 1501075981
5464  (As of this writing, there are also problems about equation numbering.
5465  See 
5466 \begin_inset CommandInset href
5467 LatexCommand href
5468 name "bug 6894"
5469 target "http://www.lyx.org/trac/ticket/6894"
5470 literal "false"
5471
5472 \end_inset
5473
5474 .)
5475 \change_unchanged
5476
5477 \begin_inset Newline newline
5478 \end_inset
5479
5480 The size of the images can be controlled by setting the 
5481 \begin_inset Quotes eld
5482 \end_inset
5483
5484 Math Images Scaling
5485 \begin_inset Quotes erd
5486 \end_inset
5487
5488  parameter under 
5489 \begin_inset Flex Noun
5490 status collapsed
5491
5492 \begin_layout Plain Layout
5493 Document\SpecialChar menuseparator
5494 Settings\SpecialChar menuseparator
5495
5496 \change_deleted -712698321 1501076136
5497 Output
5498 \change_inserted -712698321 1501076137
5499 Formats
5500 \change_unchanged
5501
5502 \end_layout
5503
5504 \end_inset
5505
5506 .
5507 \begin_inset Foot
5508 status collapsed
5509
5510 \begin_layout Plain Layout
5511 For those who want to know, this controls the resolution of the image in
5512  dots per inch and is based upon a default of 75 dpi.
5513 \end_layout
5514
5515 \end_inset
5516
5517
5518 \begin_inset Newline newline
5519 \end_inset
5520
5521 If \SpecialChar LyX
5522  for some reason fails to create an image for a formula (e.g., if a required
5523  \SpecialChar LaTeX
5524  package is not installed), then it will fall back to outputing the raw
5525  \SpecialChar LaTeX
5526 .
5527 \end_layout
5528
5529 \begin_layout Itemize
5530 \SpecialChar LaTeX
5531
5532 \begin_inset Newline newline
5533 \end_inset
5534
5535 Finally, \SpecialChar LyX
5536  will happily output math as \SpecialChar LaTeX
5537 .
5538  As well as being the output of last resort, this method can be used with
5539  such tools as 
5540 \begin_inset CommandInset href
5541 LatexCommand href
5542 name "jsMath"
5543 target "http://www.math.union.edu/~dpvc/jsMath/"
5544 literal "false"
5545
5546 \end_inset
5547
5548 , which uses JavaScript to render \SpecialChar LaTeX
5549  embedded in HTML documents.
5550  \SpecialChar LyX
5551  wraps the \SpecialChar LaTeX
5552  in either a 
5553 \begin_inset Flex Code
5554 status collapsed
5555
5556 \begin_layout Plain Layout
5557 span
5558 \end_layout
5559
5560 \end_inset
5561
5562  (for inline formulas) or 
5563 \begin_inset Flex Code
5564 status collapsed
5565
5566 \begin_layout Plain Layout
5567 div
5568 \end_layout
5569
5570 \end_inset
5571
5572  (for displayed formulas) with 
5573 \begin_inset Flex Code
5574 status collapsed
5575
5576 \begin_layout Plain Layout
5577 class='math'
5578 \end_layout
5579
5580 \end_inset
5581
5582 , as is required for jsMath.
5583 \end_layout
5584
5585 \begin_layout Standard
5586 One of these output methods must be selected under 
5587 \begin_inset Flex Noun
5588 status collapsed
5589
5590 \begin_layout Plain Layout
5591 Document\SpecialChar menuseparator
5592 Settings\SpecialChar menuseparator
5593
5594 \change_deleted -712698321 1501076586
5595 Output
5596 \change_inserted -712698321 1501076587
5597 Formats
5598 \change_unchanged
5599
5600 \end_layout
5601
5602 \end_inset
5603
5604 .
5605  By default, \SpecialChar LyX
5606  outputs MathML.
5607  This is a document-wide setting, therefore.
5608 \end_layout
5609
5610 \begin_layout Standard
5611 Eventually, \SpecialChar LyX
5612  will offer the user the option to select an alternate output
5613  method for a particular inset, say, one that isn't being rendered very
5614  well by MathML.
5615 \begin_inset Foot
5616 status collapsed
5617
5618 \begin_layout Plain Layout
5619 That said, since \SpecialChar LyX
5620  falls back to images if the inset contains ERT, then one
5621  can force output as an image by putting some harmless ERT into the math,
5622  for example: 
5623 \begin_inset Formula $a=b\relax$
5624 \end_inset
5625
5626 .
5627 \end_layout
5628
5629 \end_inset
5630
5631
5632 \end_layout
5633
5634 \begin_layout Section
5635 Bibliography and Citations
5636 \end_layout
5637
5638 \begin_layout Standard
5639 XHTML output fully supports bibliographies and citations.
5640  
5641 \end_layout
5642
5643 \begin_layout Standard
5644 Citation labels are generated by the same machinery that generates \SpecialChar LyX
5645 's on-screen
5646  labels, so the labels will look in the output much as they do in \SpecialChar LyX
5647 , though
5648  better.
5649  If you are using numerical citations, then \SpecialChar LyX
5650  will output numerical labels,
5651  such as [1] or [17], rather than simply showing the citation key in square
5652  brackets, as it does on-screen.
5653  If you are using author-year citations, then \SpecialChar LyX
5654  will add lowercase letters
5655  to the years, just as Bib\SpecialChar TeX
5656  does, if it finds more than one citation for
5657  a given author-year combination.
5658  The labels will be printed with the bibliography entries.
5659  Note that there is, at present, no way to customize the appearance of the
5660  labels, for example, to choose between square brackets and parentheses.
5661 \end_layout
5662
5663 \begin_layout Standard
5664 Bibliography output is handled by the same machinery that handles the presentati
5665 on of reference information in the citation dialog, so you will see in the
5666  XHTML output pretty much what you would see if you were to look at a given
5667  entry in the citation dialog.
5668  The formatting can be customized in your layout file or, preferably, in
5669  a module.
5670  See the 
5671 \emph on
5672 Customization
5673 \emph default
5674  manual for the details.
5675 \end_layout
5676
5677 \begin_layout Standard
5678 The main defect at present is that cross-referenced information is printed
5679  with every entry with which it is associated.
5680  So you can see things like this:
5681 \end_layout
5682
5683 \begin_layout Quote
5684 Jason Stanley, 
5685 \begin_inset Quotes eld
5686 \end_inset
5687
5688 Context and Logical Form
5689 \begin_inset Quotes erd
5690 \end_inset
5691
5692 , in 
5693 \emph on
5694 Language in Context: Selected Essays
5695 \emph default
5696  (Oxford: Oxford University Press, 2007), pp.
5697  30–68.
5698 \end_layout
5699
5700 \begin_layout Quote
5701 Jason Stanley, 
5702 \begin_inset Quotes eld
5703 \end_inset
5704
5705 Semantics in Context
5706 \begin_inset Quotes erd
5707 \end_inset
5708
5709 , in 
5710 \emph on
5711 Language in Context: Selected Essays
5712 \emph default
5713  (Oxford: Oxford University Press, 2007), pp.
5714  201–30.
5715 \end_layout
5716
5717 \begin_layout Standard
5718 This should be fixed before long.
5719 \end_layout
5720
5721 \begin_layout Standard
5722 There is no support at present for sectioned bibliographies.
5723  If you have multiple bibliographies, then \SpecialChar LyX
5724  will print the same bibliography
5725  over and over.
5726 \end_layout
5727
5728 \begin_layout Section
5729 Indexes
5730 \end_layout
5731
5732 \begin_layout Standard
5733 \SpecialChar LyX
5734  will happily export indexes as XHTML, but with certain limitations at the
5735  moment.
5736 \end_layout
5737
5738 \begin_layout Standard
5739 Index export will be most reliable when you do not attempt to use the fancy
5740  constructs that are described in the section on indexes in the 
5741 \emph on
5742 User's Guide
5743 \emph default
5744 .
5745 \begin_inset Foot
5746 status collapsed
5747
5748 \begin_layout Plain Layout
5749 The main issue here is that \SpecialChar LyX
5750  itself does not really handle these.
5751  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
5752 .
5753 \end_layout
5754
5755 \end_inset
5756
5757  We'll describe how they are handled using the subsection headings from
5758  that section.
5759 \end_layout
5760
5761 \begin_layout Itemize
5762 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
5763  makes an effort to support these,
5764  but the entries must be separated by 
5765 \begin_inset Quotes eld
5766 \end_inset
5767
5768  ! 
5769 \begin_inset Quotes erd
5770 \end_inset
5771
5772 , that is, there must be spaces around the exclamation point.
5773  This is because it is otherwise too difficult to check for escaped exclamation
5774  points, ones in math, and so forth.
5775 \end_layout
5776
5777 \begin_layout Itemize
5778 Page Ranges: There is no support at all for page ranges, since these make
5779  no sense with XHMTL.
5780  Instead, you will just get two index entries, one at either end.
5781 \end_layout
5782
5783 \begin_layout Itemize
5784 Cross-referencing: There is no support for cross-referencing.
5785  If \SpecialChar LyX
5786  finds an entry containing the 
5787 \begin_inset Quotes eld
5788 \end_inset
5789
5790 |see\SpecialChar ldots
5791
5792 \begin_inset Quotes erd
5793 \end_inset
5794
5795  construct, it is just dropped, and the rest is treated as an ordinary index
5796  entry.
5797 \end_layout
5798
5799 \begin_layout Itemize
5800 Index Entry Order: \SpecialChar LyX
5801  does support attempts to fix the sorting order.
5802  It will take what is before the first `@' it finds and use that for sorting,
5803  taking what follows the first `@' to be the actual entry.
5804  At present, \SpecialChar LyX
5805  does not check for escaped `@', so do not try to index email
5806  addresses.
5807 \end_layout
5808
5809 \begin_layout Itemize
5810 Index Entry Layout: You can format entries by using the text style dialog,
5811  or by using any other method available within \SpecialChar LyX
5812  itself.
5813  There is no support for constructs like: 
5814 \begin_inset Quotes eld
5815 \end_inset
5816
5817 entry|textbf
5818 \begin_inset Quotes erd
5819 \end_inset
5820
5821 .
5822  Indeed, if \SpecialChar LyX
5823  finds a pipe symbol, `|', in an entry, it will delete it and
5824  everything that follows it.
5825 \end_layout
5826
5827 \begin_layout Itemize
5828 Multiple Indexes: There is no support for multiple indexes.
5829  Rather, all index entries will be printed as one large index.
5830  To avoid our printing several versions of the index, we print only the
5831  main index, so make sure you have one.
5832 \end_layout
5833
5834 \begin_layout Section
5835 Nomenclature and Glossary
5836 \end_layout
5837
5838 \begin_layout Standard
5839 There is at present no support for glossaries.
5840  Adding it would be fairly trivial, and welcome.
5841 \end_layout
5842
5843 \begin_layout Chapter
5844 The \SpecialChar LyX
5845  Server
5846 \end_layout
5847
5848 \begin_layout Section
5849 Introduction
5850 \end_layout
5851
5852 \begin_layout Standard
5853 The `\SpecialChar LyX
5854  server' allows other programs to talk to \SpecialChar LyX
5855 , invoke \SpecialChar LyX
5856  commands, and retrieve
5857  information about the \SpecialChar LyX
5858  internal state.
5859  This is only intended for advanced users, but they should find it useful.
5860  It is by writing to the \SpecialChar LyX
5861  server, for example, that bibliography managers,
5862  such as JabRef, are able to 
5863 \begin_inset Quotes eld
5864 \end_inset
5865
5866 push
5867 \begin_inset Quotes erd
5868 \end_inset
5869
5870  citations to \SpecialChar LyX
5871 .
5872 \end_layout
5873
5874 \begin_layout Section
5875 Starting the \SpecialChar LyX
5876  Server
5877 \end_layout
5878
5879 \begin_layout Standard
5880 The \SpecialChar LyX
5881  server works through the use of a pair of named pipes.
5882  These are usually located in 
5883 \begin_inset Flex Code
5884 status collapsed
5885
5886 \begin_layout Plain Layout
5887 UserDir
5888 \end_layout
5889
5890 \end_inset
5891
5892 , (except on Windows, where 
5893 \emph on
5894 local
5895 \emph default
5896  named pipes are special objects located in 
5897 \begin_inset Flex Code
5898 status collapsed
5899
5900 \begin_layout Plain Layout
5901
5902 \backslash
5903
5904 \backslash
5905 .
5906 \backslash
5907 pipe
5908 \end_layout
5909
5910 \end_inset
5911
5912 ) and have the names 
5913 \begin_inset Quotes eld
5914 \end_inset
5915
5916
5917 \begin_inset Flex Code
5918 status collapsed
5919
5920 \begin_layout Plain Layout
5921 lyxpipe.in
5922 \end_layout
5923
5924 \end_inset
5925
5926
5927 \begin_inset Quotes erd
5928 \end_inset
5929
5930  and 
5931 \begin_inset Quotes eld
5932 \end_inset
5933
5934
5935 \begin_inset Flex Code
5936 status collapsed
5937
5938 \begin_layout Plain Layout
5939 lyxpipe.out
5940 \end_layout
5941
5942 \end_inset
5943
5944
5945 \begin_inset Quotes erd
5946 \end_inset
5947
5948 .
5949  External programs write into 
5950 \begin_inset Flex Code
5951 status collapsed
5952
5953 \begin_layout Plain Layout
5954 lyxpipe.in
5955 \end_layout
5956
5957 \end_inset
5958
5959  and read back data from 
5960 \begin_inset Flex Code
5961 status collapsed
5962
5963 \begin_layout Plain Layout
5964 lyxpipe.out
5965 \end_layout
5966
5967 \end_inset
5968
5969 .
5970  The stem of the pipe names can be defined in the 
5971 \begin_inset Flex Noun
5972 status collapsed
5973
5974 \begin_layout Plain Layout
5975 Tools\SpecialChar menuseparator
5976 Preferences
5977 \end_layout
5978
5979 \end_inset
5980
5981  dialog, for example 
5982 \begin_inset Flex Code
5983 status collapsed
5984
5985 \begin_layout Plain Layout
5986 "/home/myhome/lyxpipe"
5987 \end_layout
5988
5989 \end_inset
5990
5991 , or 
5992 \begin_inset Flex Code
5993 status collapsed
5994
5995 \begin_layout Plain Layout
5996 "
5997 \backslash
5998
5999 \backslash
6000 .
6001 \backslash
6002 pipe
6003 \backslash
6004 lyxpipe"
6005 \end_layout
6006
6007 \end_inset
6008
6009  on Windows (where any working path instead of lyxpipe can be used, for
6010  example 
6011 \begin_inset Flex Code
6012 status collapsed
6013
6014 \begin_layout Plain Layout
6015 "
6016 \backslash
6017
6018 \backslash
6019 .
6020 \backslash
6021 pipe
6022 \backslash
6023 my
6024 \backslash
6025 lyx
6026 \backslash
6027 pipe"
6028 \end_layout
6029
6030 \end_inset
6031
6032  would also work).
6033  You 
6034 \emph on
6035 must
6036 \emph default
6037  configure this manually in order for the server to start.
6038 \end_layout
6039
6040 \begin_layout Standard
6041 \SpecialChar LyX
6042  will add the '
6043 \begin_inset Flex Code
6044 status collapsed
6045
6046 \begin_layout Plain Layout
6047 .in
6048 \end_layout
6049
6050 \end_inset
6051
6052 ' and '
6053 \begin_inset Flex Code
6054 status collapsed
6055
6056 \begin_layout Plain Layout
6057 .out
6058 \end_layout
6059
6060 \end_inset
6061
6062 ' to create the pipes.
6063  If one of the pipes already exists, \SpecialChar LyX
6064  will assume that another \SpecialChar LyX
6065  process
6066  is already running and will not start the server.
6067  On POSIX (Unix like) systems, if for some other reason, an unused 
6068 \begin_inset Quotes eld
6069 \end_inset
6070
6071 stale
6072 \begin_inset Quotes erd
6073 \end_inset
6074
6075  pipe is left in existence when \SpecialChar LyX
6076  closes, then \SpecialChar LyX
6077  will try to delete it.
6078  If this fails for some reason, you will need to delete the pipes manually
6079  and then restart \SpecialChar LyX
6080 .
6081  On Windows, pipes are deleted by the OS on program termination or crash,
6082  so 
6083 \begin_inset Quotes eld
6084 \end_inset
6085
6086 stale
6087 \begin_inset Quotes erd
6088 \end_inset
6089
6090  pipes should not be possible.
6091 \end_layout
6092
6093 \begin_layout Standard
6094 To have several \SpecialChar LyX
6095  processes with servers at the same time, you have to use
6096  different configurations, perhaps by using separate user directories, each
6097  with its own 
6098 \begin_inset Flex Code
6099 status collapsed
6100
6101 \begin_layout Plain Layout
6102 preferences
6103 \end_layout
6104
6105 \end_inset
6106
6107  file, for each process.
6108 \end_layout
6109
6110 \begin_layout Standard
6111 If you are developing a client program, you might find it useful to enable
6112  debugging information from the \SpecialChar LyX
6113  server.
6114  Do this by starting \SpecialChar LyX
6115  as 
6116 \begin_inset Flex Code
6117 status collapsed
6118
6119 \begin_layout Plain Layout
6120 lyx -dbg lyxserver
6121 \end_layout
6122
6123 \end_inset
6124
6125 .
6126 \end_layout
6127
6128 \begin_layout Standard
6129 You can find a complete example client written in C++ in the source distribution
6130  as 
6131 \begin_inset Flex Code
6132 status collapsed
6133
6134 \begin_layout Plain Layout
6135 development/lyxserver/server_monitor.cpp
6136 \end_layout
6137
6138 \end_inset
6139
6140 .
6141 \end_layout
6142
6143 \begin_layout Standard
6144 Another useful tool is the command-line based client found in 
6145 \begin_inset Flex Code
6146 status collapsed
6147
6148 \begin_layout Plain Layout
6149 src/client/lyxclient
6150 \end_layout
6151
6152 \end_inset
6153
6154 .
6155 \end_layout
6156
6157 \begin_layout Section
6158 Normal communication
6159 \end_layout
6160
6161 \begin_layout Standard
6162 To issue a \SpecialChar LyX
6163  call, the client writes a line of ASCII text into the input
6164  pipe.
6165  This line has the following format:
6166 \end_layout
6167
6168 \begin_layout Quote
6169 LYXCMD:
6170 \emph on
6171 clientname
6172 \emph default
6173 :
6174 \emph on
6175 function
6176 \emph default
6177 :
6178 \emph on
6179 argument
6180 \end_layout
6181
6182 \begin_layout Description
6183 clientname is a name that the client can choose arbitrarily.
6184  Its only use is that \SpecialChar LyX
6185  will echo it if it sends an answer—so a client can
6186  dispatch results from different requesters.
6187 \end_layout
6188
6189 \begin_layout Description
6190 function is the function you want \SpecialChar LyX
6191  to perform.
6192  It is the same as the commands you'd use in the minibuffer.
6193 \end_layout
6194
6195 \begin_layout Description
6196 argument is an optional argument which is meaningful only to some functions
6197  (for instance, the 
6198 \begin_inset Quotes eld
6199 \end_inset
6200
6201 self-insert
6202 \begin_inset Quotes erd
6203 \end_inset
6204
6205  LFUN will insert the argument as text at the cursor position).
6206 \end_layout
6207
6208 \begin_layout Standard
6209 The answer from \SpecialChar LyX
6210  will arrive in the output pipe and be of the form
6211 \end_layout
6212
6213 \begin_layout Quote
6214 INFO:
6215 \emph on
6216 clientname
6217 \emph default
6218 :
6219 \emph on
6220 function
6221 \emph default
6222 :
6223 \emph on
6224 data
6225 \end_layout
6226
6227 \begin_layout Standard
6228 where 
6229 \emph on
6230 clientname
6231 \emph default
6232  and 
6233 \emph on
6234 function
6235 \emph default
6236  are just echoed from the command request, while 
6237 \emph on
6238 data
6239 \emph default
6240  is more or less useful information filled according to how the command
6241  execution worked out.
6242  Some commands, such as 
6243 \begin_inset Quotes eld
6244 \end_inset
6245
6246 font-state
6247 \begin_inset Quotes erd
6248 \end_inset
6249
6250 , will return information about the internal state of \SpecialChar LyX
6251 , while other will
6252  return an empty data-response.
6253  This means that the command execution went fine.
6254 \end_layout
6255
6256 \begin_layout Standard
6257 In case of errors, the response from \SpecialChar LyX
6258  will have this form
6259 \end_layout
6260
6261 \begin_layout Quote
6262 ERROR:
6263 \emph on
6264 clientname
6265 \emph default
6266 :
6267 \emph on
6268 function
6269 \emph default
6270 :
6271 \emph on
6272 error message
6273 \end_layout
6274
6275 \begin_layout Standard
6276 where the 
6277 \emph on
6278 error message
6279 \emph default
6280  should contain an explanation of why the command failed.
6281 \end_layout
6282
6283 \begin_layout Standard
6284 Examples:
6285 \end_layout
6286
6287 \begin_layout LyX-Code
6288 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
6289 \begin_inset Newline newline
6290 \end_inset
6291
6292 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
6293 \begin_inset Newline newline
6294 \end_inset
6295
6296 read a <~/.lyxpipe.out
6297 \begin_inset Newline newline
6298 \end_inset
6299
6300 echo $a
6301 \end_layout
6302
6303 \begin_layout Subsection
6304 AppleScript (Mac OS X)
6305 \end_layout
6306
6307 \begin_layout Standard
6308 Since \SpecialChar LyX
6309  2.1, \SpecialChar LyX
6310  supports basic interactions with AppleScript for normal communicatio
6311 n through the command run.
6312  This command takes a direct argument (the 
6313 \series bold
6314 function
6315 \series default
6316  to perform) and an optional argument.
6317  It either returns the output of the function or triggers an error with
6318  the error message and code.
6319 \end_layout
6320
6321 \begin_layout Standard
6322 Example:
6323 \end_layout
6324
6325 \begin_layout LyX-Code
6326 tell application "\SpecialChar LyX
6327 "
6328 \end_layout
6329
6330 \begin_layout LyX-Code
6331   try
6332 \end_layout
6333
6334 \begin_layout LyX-Code
6335     -- Stores the current file name into f
6336 \end_layout
6337
6338 \begin_layout LyX-Code
6339     set f to (run "server-get-filename" with argument "")
6340 \end_layout
6341
6342 \begin_layout LyX-Code
6343     on error the error_message number the error_number
6344 \end_layout
6345
6346 \begin_layout LyX-Code
6347       display dialog "Error: " & the error_number & ".
6348  " ¬
6349 \end_layout
6350
6351 \begin_layout LyX-Code
6352               & the error_message buttons {"OK"} default button 1
6353 \end_layout
6354
6355 \begin_layout LyX-Code
6356   end try
6357 \end_layout
6358
6359 \begin_layout LyX-Code
6360 end tell
6361 \end_layout
6362
6363 \begin_layout Section
6364 Notification
6365 \end_layout
6366
6367 \begin_layout Standard
6368 \SpecialChar LyX
6369  can notify clients of events going on asynchronously.
6370  Currently it will only do this if the user binds a key sequence with the
6371  function 
6372 \begin_inset Quotes eld
6373 \end_inset
6374
6375 notify
6376 \begin_inset Quotes erd
6377 \end_inset
6378
6379 .
6380  The format of the string \SpecialChar LyX
6381  sends is as follows:
6382 \end_layout
6383
6384 \begin_layout Quote
6385 \begin_inset Flex Code
6386 status collapsed
6387
6388 \begin_layout Plain Layout
6389 NOTIFY:
6390 \end_layout
6391
6392 \end_inset
6393
6394
6395 \emph on
6396 key-sequence
6397 \end_layout
6398
6399 \begin_layout Standard
6400 where 
6401 \emph on
6402 key-sequence
6403 \emph default
6404  is the printed representation of the key sequence that was actually typed
6405  by the user.
6406 \end_layout
6407
6408 \begin_layout Standard
6409 This mechanism can be used to extend \SpecialChar LyX
6410 's command set and implement macros.
6411  Bind some key sequence to 
6412 \begin_inset Quotes eld
6413 \end_inset
6414
6415 notify
6416 \begin_inset Quotes erd
6417 \end_inset
6418
6419 .
6420  Then start a client that listens on the output pipe, dispatches the command
6421  according to the sequence, and starts a function that may use \SpecialChar LyX
6422  calls and
6423  \SpecialChar LyX
6424  requests to issue a command or a series of commands to \SpecialChar LyX
6425 .
6426 \end_layout
6427
6428 \begin_layout Section
6429 The simple \SpecialChar LyX
6430  Server Protocol
6431 \end_layout
6432
6433 \begin_layout Standard
6434 \SpecialChar LyX
6435  implements a simple protocol that can be used for session management.
6436  All messages are of the form
6437 \end_layout
6438
6439 \begin_layout Quote
6440 LYXSRV:
6441 \emph on
6442 clientname
6443 \emph default
6444 :
6445 \emph on
6446 protocol message
6447 \end_layout
6448
6449 \begin_layout Standard
6450 where 
6451 \emph on
6452 protocol message
6453 \emph default
6454  can be 
6455 \begin_inset Quotes eld
6456 \end_inset
6457
6458 hello
6459 \begin_inset Quotes erd
6460 \end_inset
6461
6462  or 
6463 \begin_inset Quotes eld
6464 \end_inset
6465
6466 bye
6467 \begin_inset Quotes erd
6468 \end_inset
6469
6470 .
6471  If 
6472 \begin_inset Quotes eld
6473 \end_inset
6474
6475 hello
6476 \begin_inset Quotes erd
6477 \end_inset
6478
6479  is received from a client, \SpecialChar LyX
6480  will report back to inform the client that
6481  it's listening to it's messages, while 
6482 \begin_inset Quotes eld
6483 \end_inset
6484
6485 bye
6486 \begin_inset Quotes erd
6487 \end_inset
6488
6489  sent from \SpecialChar LyX
6490  will inform clients that \SpecialChar LyX
6491  is closing.
6492 \end_layout
6493
6494 \begin_layout Section
6495 Reverse DVI/PDF search
6496 \end_layout
6497
6498 \begin_layout Standard
6499 Some DVI/PDF viewers
6500 \begin_inset Foot
6501 status collapsed
6502
6503 \begin_layout Plain Layout
6504 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
6505  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
6506 \end_layout
6507
6508 \end_inset
6509
6510  provide 
6511 \emph on
6512 reverse search
6513 \emph default
6514  facility (also called 
6515 \emph on
6516 inverse search
6517 \emph default
6518 ).
6519  This means that you can tell \SpecialChar LyX
6520  to put the cursor to a specific line in the
6521  document by clicking at the respective position in the DVI/PDF output.
6522  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
6523 .
6524  This is done via the \SpecialChar LyX
6525  server either by using the named pipe (
6526 \emph on
6527 lyxpipe
6528 \emph default
6529 ), or the UNIX domain socket (
6530 \emph on
6531 lyxsocket
6532 \emph default
6533 ) that \SpecialChar LyX
6534  creates in its temporary directory (this is the way the 
6535 \begin_inset Flex Code
6536 status collapsed
6537
6538 \begin_layout Plain Layout
6539 lyxclient
6540 \end_layout
6541
6542 \end_inset
6543
6544  program communicates with \SpecialChar LyX
6545 ).
6546  In some cases, you need a helper script that mediates between the viewer
6547  and \SpecialChar LyX
6548 , in others, the viewer can communicate with \SpecialChar LyX
6549  directly.
6550  This depends on the selected viewer and on your operating system.
6551  The same applies to the way viewers need to be configured and the way the
6552  reverse search is actually performed.
6553  In what follows, we will thus describe how to setup reverse search for
6554  specific viewers.
6555  Before we turn to this, though, we will explain what needs to be done generally
6556  to enable reverse search in the DVI/PDF output.
6557 \end_layout
6558
6559 \begin_layout Subsection
6560 Automatic setup
6561 \begin_inset CommandInset label
6562 LatexCommand label
6563 name "subsec:rev-search"
6564
6565 \end_inset
6566
6567
6568 \end_layout
6569
6570 \begin_layout Standard
6571 In most cases \SpecialChar LyX
6572  will do the work for you by 
6573 \change_inserted -712698321 1500975045
6574 pressing the following button in the toolbar: 
6575 \begin_inset Info
6576 type  "icon"
6577 arg   "buffer-toggle-output-sync"
6578 \end_inset
6579
6580 .
6581  Alternatively, you can also enable the feature by checking 
6582 \family sans
6583 Synchronize with Output
6584 \family default
6585  in 
6586 \begin_inset Flex Noun
6587 status collapsed
6588
6589 \begin_layout Plain Layout
6590
6591 \change_inserted -712698321 1500975071
6592 Document\SpecialChar menuseparator
6593 Settings\SpecialChar menuseparator
6594 Formats
6595 \end_layout
6596
6597 \end_inset
6598
6599
6600 \change_deleted -712698321 1500974764
6601 enabling the option 
6602 \begin_inset Flex Noun
6603 status collapsed
6604
6605 \begin_layout Plain Layout
6606 Synchronize with Output
6607 \end_layout
6608
6609 \end_inset
6610
6611  in the menu 
6612 \begin_inset Flex Noun
6613 status collapsed
6614
6615 \begin_layout Plain Layout
6616 Document\SpecialChar menuseparator
6617 Settings\SpecialChar menuseparator
6618 Output
6619 \end_layout
6620
6621 \end_inset
6622
6623
6624 \change_unchanged
6625 .
6626  In such a case \SpecialChar LyX
6627  will automatically insert the necessary Sync\SpecialChar TeX
6628  macro (for
6629  PDF) or load the srcltx package (for DVI) respectively.
6630  This option can be easily reached also on 
6631 \begin_inset Flex Code
6632 status collapsed
6633
6634 \begin_layout Plain Layout
6635 View/Update
6636 \end_layout
6637
6638 \end_inset
6639
6640  Toolbar.
6641 \end_layout
6642
6643 \begin_layout Standard
6644 If you need a different setting, you can select or input a custom macro
6645  from the drop down box just below 
6646 \begin_inset Flex Noun
6647 status collapsed
6648
6649 \begin_layout Plain Layout
6650 Document\SpecialChar menuseparator
6651 Settings\SpecialChar menuseparator
6652 Output\SpecialChar menuseparator
6653 Synchronize with Output
6654 \end_layout
6655
6656 \end_inset
6657
6658 .
6659 \end_layout
6660
6661 \begin_layout Standard
6662 Note that the method 
6663 \begin_inset Flex Code
6664 status collapsed
6665
6666 \begin_layout Plain Layout
6667
6668 \backslash
6669 synctex=1
6670 \end_layout
6671
6672 \end_inset
6673
6674  enables gzip compression.
6675  If your viewer does not support it, you should instead use 
6676 \begin_inset Flex Code
6677 status collapsed
6678
6679 \begin_layout Plain Layout
6680
6681 \backslash
6682 synctex=-1
6683 \end_layout
6684
6685 \end_inset
6686
6687 .
6688 \end_layout
6689
6690 \begin_layout Standard
6691 Please also note that including the 
6692 \begin_inset Flex Code
6693 status collapsed
6694
6695 \begin_layout Plain Layout
6696 srcltx
6697 \end_layout
6698
6699 \end_inset
6700
6701  package or 
6702 \begin_inset Flex Code
6703 status collapsed
6704
6705 \begin_layout Plain Layout
6706 src-specials
6707 \end_layout
6708
6709 \end_inset
6710
6711  sometimes has an undesired impact on the typesetting.
6712  Thus, you should switch output synchronization off for the final typesetting
6713  if you use the 
6714 \begin_inset Flex Code
6715 status collapsed
6716
6717 \begin_layout Plain Layout
6718 srcltx
6719 \end_layout
6720
6721 \end_inset
6722
6723  package or 
6724 \begin_inset Flex Code
6725 status collapsed
6726
6727 \begin_layout Plain Layout
6728 src-specials
6729 \end_layout
6730
6731 \end_inset
6732
6733 .
6734  
6735 \end_layout
6736
6737 \begin_layout Standard
6738 In case you need some more special settings that are not covered by the
6739  automatic settings, read the next section about how to set up output synchroniz
6740 ation manually.
6741  If the automatic setup suits your needs, you can readily jump to section
6742 \begin_inset space ~
6743 \end_inset
6744
6745
6746 \begin_inset CommandInset ref
6747 LatexCommand ref
6748 reference "subsec:configuring-viewers"
6749
6750 \end_inset
6751
6752 , where the necessary configuration steps in your viewer – needed both with
6753  the automatic and the manual setup – are described.
6754 \end_layout
6755
6756 \begin_layout Subsection
6757 Manual setup
6758 \end_layout
6759
6760 \begin_layout Standard
6761 \SpecialChar LaTeX
6762  provides several different methods for reverse search.
6763  Some are built-in in the 
6764 \begin_inset Flex Code
6765 status collapsed
6766
6767 \begin_layout Plain Layout
6768 latex/pdflatex
6769 \end_layout
6770
6771 \end_inset
6772
6773  program, some are provided by external packages.
6774  Your choice depends on whether your \SpecialChar LaTeX
6775  distribution already provides a given
6776  method (the built-in methods are rather new) and whether your viewer can
6777  cope with it.
6778  The available methods are described in the following.
6779 \end_layout
6780
6781 \begin_layout Subsubsection*
6782 Built-in DVI-search via src-specials (DVI only) 
6783 \end_layout
6784
6785 \begin_layout Standard
6786 This method provides the DVI file with the necessary information for reverse
6787  search.
6788  It is available in \SpecialChar LaTeX
6789  since quite some time (any somewhat recent \SpecialChar LaTeX
6790  distribution
6791  should include it), and it works reliably.
6792  To enable it, change the 
6793 \begin_inset Flex Noun
6794 status collapsed
6795
6796 \begin_layout Plain Layout
6797 La
6798 \family sans
6799 TeX
6800 \family default
6801  (plain)->DVI
6802 \end_layout
6803
6804 \end_inset
6805
6806  or 
6807 \begin_inset Flex Noun
6808 status collapsed
6809
6810 \begin_layout Plain Layout
6811 La
6812 \family sans
6813 TeX
6814 \family default
6815  (plain)->DraftDVI
6816 \end_layout
6817
6818 \end_inset
6819
6820  converter in 
6821 \begin_inset Flex Noun
6822 status collapsed
6823
6824 \begin_layout Plain Layout
6825 Preferences\SpecialChar menuseparator
6826 File Handling\SpecialChar menuseparator
6827 Converters
6828 \end_layout
6829
6830 \end_inset
6831
6832  to 
6833 \begin_inset Flex Code
6834 status collapsed
6835
6836 \begin_layout Plain Layout
6837 latex -src-specials $$i
6838 \end_layout
6839
6840 \end_inset
6841
6842 .
6843  If this doesn't work, check if your \SpecialChar TeX
6844  engine needs different options (the
6845  syntax might differ in some distributions).
6846 \end_layout
6847
6848 \begin_layout Subsubsection*
6849 External Packages (PDFSync and scrltx) 
6850 \end_layout
6851
6852 \begin_layout Standard
6853 The packages 
6854 \emph on
6855 pdfsync
6856 \emph default
6857  and 
6858 \emph on
6859 scrltx
6860 \emph default
6861  provide reverse search facility for PDF output (via pdflatex) and DVI output,
6862  respectively.
6863  In order to enable it, load the packages in the \SpecialChar LyX
6864  preamble: 
6865 \end_layout
6866
6867 \begin_layout Itemize
6868 \begin_inset Flex Code
6869 status collapsed
6870
6871 \begin_layout Plain Layout
6872
6873 \backslash
6874 usepackage{pdfsync}
6875 \end_layout
6876
6877 \end_inset
6878
6879  for reverse PDF search,
6880 \end_layout
6881
6882 \begin_layout Itemize
6883 \begin_inset Flex Code
6884 status collapsed
6885
6886 \begin_layout Plain Layout
6887
6888 \backslash
6889 usepackage[active]{srcltx}
6890 \end_layout
6891
6892 \end_inset
6893
6894  for reverse DVI search.
6895 \end_layout
6896
6897 \begin_layout Standard
6898 If you want to be able to perform both DVI and PDF reverse searches, you
6899  can also insert in the preamble the following lines
6900 \end_layout
6901
6902 \begin_layout LyX-Code
6903
6904 \backslash
6905 usepackage{ifpdf}
6906 \begin_inset Newline newline
6907 \end_inset
6908
6909
6910 \backslash
6911 ifpdf
6912 \begin_inset Newline newline
6913 \end_inset
6914
6915   
6916 \backslash
6917 usepackage{pdfsync}
6918 \begin_inset Newline newline
6919 \end_inset
6920
6921
6922 \backslash
6923 else
6924 \begin_inset Newline newline
6925 \end_inset
6926
6927   
6928 \backslash
6929 usepackage[active]{srcltx}
6930 \begin_inset Newline newline
6931 \end_inset
6932
6933
6934 \backslash
6935 fi
6936 \end_layout
6937
6938 \begin_layout Standard
6939 This way, you can preview the file as either DVI or PDF (pdflatex) and the
6940  right package will be used.
6941 \end_layout
6942
6943 \begin_layout Standard
6944 Note that PDFSync might affect the output layout of your document.
6945  It is therefore advised to disable PDFsync for final documents.
6946 \end_layout
6947
6948 \begin_layout Subsubsection*
6949 Built-in reverse search via Sync\SpecialChar TeX
6950  (DVI and PDF) 
6951 \end_layout
6952
6953 \begin_layout Standard
6954 Recent versions of 
6955 \begin_inset Flex Code
6956 status collapsed
6957
6958 \begin_layout Plain Layout
6959 (pdf)latex
6960 \end_layout
6961
6962 \end_inset
6963
6964  have built-in support for both PDF and DVI reverse search.
6965  This so-called 
6966 \emph on
6967 Sync\SpecialChar TeX
6968
6969 \emph default
6970  facility is basically the result of the integration of the PDFSync package
6971  to the pdftex program and its merge with the 
6972 \emph on
6973 scr-specials
6974 \emph default
6975  approach.
6976  You need at least \SpecialChar TeX
6977 Live 2008 or a recent Mik\SpecialChar TeX
6978  distribution in order to use
6979  it.
6980 \begin_inset Foot
6981 status collapsed
6982
6983 \begin_layout Plain Layout
6984 For some reason, Mik\SpecialChar TeX
6985  does not understand/obey the command \SpecialChar LyX
6986  inserts into
6987  the preamble when you check the "Enable Forward/Reverse Search" button
6988  in the toolbar and does not generate the necessary info.
6989 \end_layout
6990
6991 \begin_layout Plain Layout
6992 The generation of the required info can be forced by changing the converter
6993  "\SpecialChar LaTeX
6994  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
6995  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
6996  the -synctex=1 switch).
6997 \end_layout
6998
6999 \end_inset
7000
7001  Also note that only a few PDF viewers (
7002 \change_inserted -712698321 1500977288
7003 such as 
7004 \change_unchanged
7005 Okular and Qpdfview on Unix, Skim on the Mac, SumatraPDF on Windows
7006 \change_inserted -712698321 1500977299
7007 ; see the next section for details
7008 \change_unchanged
7009 ) already provide Sync\SpecialChar TeX
7010  support.
7011 \end_layout
7012
7013 \begin_layout Standard
7014 To enable Sync\SpecialChar TeX
7015  for DVI output, change the 
7016 \begin_inset Flex Noun
7017 status collapsed
7018
7019 \begin_layout Plain Layout
7020 La
7021 \family sans
7022 TeX
7023 \family default
7024  (plain) -> DVI
7025 \end_layout
7026
7027 \end_inset
7028
7029  or 
7030 \begin_inset Flex Noun
7031 status collapsed
7032
7033 \begin_layout Plain Layout
7034 La
7035 \family sans
7036 TeX
7037 \family default
7038  (plain) -> DraftDVI
7039 \end_layout
7040
7041 \end_inset
7042
7043  converter in 
7044 \begin_inset Flex Noun
7045 status collapsed
7046
7047 \begin_layout Plain Layout
7048 Preferences\SpecialChar menuseparator
7049 File Handling\SpecialChar menuseparator
7050 Converters
7051 \end_layout
7052
7053 \end_inset
7054
7055  to 
7056 \begin_inset Flex Code
7057 status collapsed
7058
7059 \begin_layout Plain Layout
7060 latex -synctex=1 $$i
7061 \end_layout
7062
7063 \end_inset
7064
7065 , and for PDF output, change the 
7066 \begin_inset Flex Noun
7067 status collapsed
7068
7069 \begin_layout Plain Layout
7070 La
7071 \family sans
7072 TeX
7073 \family default
7074  (pdflatex) -> PDF (pdflatex)
7075 \end_layout
7076
7077 \end_inset
7078
7079  
7080 \change_deleted -712698321 1500977453
7081 or
7082 \change_unchanged
7083  converter to 
7084 \begin_inset Flex Code
7085 status collapsed
7086
7087 \begin_layout Plain Layout
7088 pdflatex -synctex=1 $$i
7089 \end_layout
7090
7091 \end_inset
7092
7093 .
7094  
7095 \change_inserted -712698321 1500977740
7096 Should your viewer not be considered in the following description, or in
7097  case of missing success, please 
7098 \change_deleted -712698321 1500977741
7099 C
7100 \change_inserted -712698321 1500977744
7101 c
7102 \change_unchanged
7103 heck the documentation of your viewer whether the viewer needs to be configured
7104  for the use with Sync\SpecialChar TeX
7105 .
7106 \begin_inset Foot
7107 status collapsed
7108
7109 \begin_layout Plain Layout
7110 Note that the option 
7111 \begin_inset Flex Code
7112 status collapsed
7113
7114 \begin_layout Plain Layout
7115 -synctex=1
7116 \end_layout
7117
7118 \end_inset
7119
7120  option enables gzip compression.
7121  If your viewer does not support it, you should instead use 
7122 \begin_inset Flex Code
7123 status collapsed
7124
7125 \begin_layout Plain Layout
7126 -synctex=-1
7127 \end_layout
7128
7129 \end_inset
7130
7131 .
7132 \end_layout
7133
7134 \end_inset
7135
7136
7137 \end_layout
7138
7139 \begin_layout Subsection
7140 Configuring and using specific viewers
7141 \begin_inset CommandInset label
7142 LatexCommand label
7143 name "subsec:configuring-viewers"
7144
7145 \end_inset
7146
7147
7148 \end_layout
7149
7150 \begin_layout Subsubsection*
7151 Xdvi (all platforms)
7152 \end_layout
7153
7154 \begin_layout Standard
7155 If you use 
7156 \begin_inset Flex Code
7157 status collapsed
7158
7159 \begin_layout Plain Layout
7160 xdvi
7161 \end_layout
7162
7163 \end_inset
7164
7165 , you don't need to do anything else for performing a reverse DVI search,
7166  as \SpecialChar LyX
7167  already provides the necessary hooks for automatically using the 
7168 \begin_inset Flex Code
7169 status collapsed
7170
7171 \begin_layout Plain Layout
7172 lyxclient
7173 \end_layout
7174
7175 \end_inset
7176
7177  program.
7178  Just setup your document as described above (reverse search is triggered
7179  by Ctrl-click or Alt-click on Mac OSX, respectively).
7180 \end_layout
7181
7182 \begin_layout Standard
7183 However, if for whatever reason you want to use the named pipe instead of
7184  the socket for communicating with \SpecialChar LyX
7185 , simply change the DVI viewer in 
7186 \begin_inset Flex Noun
7187 status collapsed
7188
7189 \begin_layout Plain Layout
7190 Preferences\SpecialChar menuseparator
7191 File Handling\SpecialChar menuseparator
7192 File formats
7193 \end_layout
7194
7195 \end_inset
7196
7197  to
7198 \begin_inset Foot
7199 status collapsed
7200
7201 \begin_layout Plain Layout
7202 On Mac OSX you have to use 
7203 \begin_inset Flex Code
7204 status collapsed
7205
7206 \begin_layout Plain Layout
7207 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
7208 \end_layout
7209
7210 \end_inset
7211
7212
7213 \end_layout
7214
7215 \end_inset
7216
7217  
7218 \begin_inset Flex Code
7219 status collapsed
7220
7221 \begin_layout Plain Layout
7222 xdvi -editor "lyxeditor.sh %f %l"
7223 \end_layout
7224
7225 \end_inset
7226
7227 , where 
7228 \begin_inset Flex Code
7229 status collapsed
7230
7231 \begin_layout Plain Layout
7232 lyxeditor.sh
7233 \end_layout
7234
7235 \end_inset
7236
7237  is a suitable script.
7238  For example, a minimal shell script is the following one:
7239 \end_layout
7240
7241 \begin_layout LyX-Code
7242 #!/bin/sh
7243 \begin_inset Newline newline
7244 \end_inset
7245
7246 LYXPIPE="/path/to/lyxpipe"
7247 \begin_inset Newline newline
7248 \end_inset
7249
7250 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
7251 \begin_inset Newline newline
7252 \end_inset
7253
7254 echo "$COMMAND" > "${LYXPIPE}".in || exit
7255 \begin_inset Newline newline
7256 \end_inset
7257
7258 read TMP < "${LYXPIPE}".out || exit
7259 \end_layout
7260
7261 \begin_layout Standard
7262 where 
7263 \begin_inset Flex Code
7264 status collapsed
7265
7266 \begin_layout Plain Layout
7267 /path/to/lyxpipe
7268 \end_layout
7269
7270 \end_inset
7271
7272  is the LyXServer pipe path specified in 
7273 \begin_inset Flex Noun
7274 status collapsed
7275
7276 \begin_layout Plain Layout
7277 Preferences\SpecialChar menuseparator
7278 Paths
7279 \end_layout
7280
7281 \end_inset
7282
7283 .
7284 \begin_inset Foot
7285 status collapsed
7286
7287 \begin_layout Plain Layout
7288 In the 
7289 \begin_inset Flex Code
7290 status collapsed
7291
7292 \begin_layout Plain Layout
7293 development/tools
7294 \end_layout
7295
7296 \end_inset
7297
7298  folder of a source distribution you can find a 
7299 \begin_inset Flex Code
7300 status collapsed
7301
7302 \begin_layout Plain Layout
7303 lyxeditor
7304 \end_layout
7305
7306 \end_inset
7307
7308  script which is able to locate the 
7309 \emph on
7310 lyxpipe
7311 \emph default
7312  based on your preferences.
7313 \end_layout
7314
7315 \end_inset
7316
7317
7318 \end_layout
7319
7320 \begin_layout Subsubsection*
7321 MacDviX (Mac OSX)
7322 \end_layout
7323
7324 \begin_layout Standard
7325 At the end of 
7326 \begin_inset Flex Code
7327 status collapsed
7328
7329 \begin_layout Plain Layout
7330 /Applications/MacDviX_Folder/calleditor.script
7331 \end_layout
7332
7333 \end_inset
7334
7335 , add the following lines:
7336 \end_layout
7337
7338 \begin_layout LyX-Code
7339 /Applications/LyX.app/Contents/MacOS/lyxeditor "$2" $1
7340 \begin_inset Newline newline
7341 \end_inset
7342
7343 exit 1
7344 \end_layout
7345
7346 \begin_layout Standard
7347 Modify the lines accordingly if you install \SpecialChar LyX
7348  somewhere else than in the
7349  Applications folder.
7350 \end_layout
7351
7352 \begin_layout Standard
7353 Reverse search is triggered by Alt-click (OPTION-click).
7354 \end_layout
7355
7356 \begin_layout Subsubsection*
7357 Skim (Mac OSX)
7358 \end_layout
7359
7360 \begin_layout Standard
7361 Enter 
7362 \begin_inset Flex Code
7363 status collapsed
7364
7365 \begin_layout Plain Layout
7366 open -a Skim.app $$i
7367 \end_layout
7368
7369 \end_inset
7370
7371  to the viewer setting in 
7372 \begin_inset Flex Noun
7373 status collapsed
7374
7375 \begin_layout Plain Layout
7376 Preferences\SpecialChar menuseparator
7377 File Handling\SpecialChar menuseparator
7378 File formats\SpecialChar menuseparator
7379 PDF (pdflatex)
7380 \end_layout
7381
7382 \end_inset
7383
7384 , and then in 
7385 \begin_inset Flex Noun
7386 status collapsed
7387
7388 \begin_layout Plain Layout
7389 Skim\SpecialChar menuseparator
7390 Preferences\SpecialChar menuseparator
7391 Sync
7392 \end_layout
7393
7394 \end_inset
7395
7396  choose 
7397 \begin_inset Flex Noun
7398 status collapsed
7399
7400 \begin_layout Plain Layout
7401 custom
7402 \end_layout
7403
7404 \end_inset
7405
7406  preset and enter command 
7407 \begin_inset Flex Noun
7408 status collapsed
7409
7410 \begin_layout Plain Layout
7411 /Applications/\SpecialChar LyX
7412 .app/Contents/MacOS/lyxeditor
7413 \end_layout
7414
7415 \end_inset
7416
7417 .
7418 \end_layout
7419
7420 \begin_layout Standard
7421 Reverse search is triggered by COMMAND-SHIFT-click
7422 \end_layout
7423
7424 \begin_layout Subsubsection*
7425 Evince (GNOME)
7426 \end_layout
7427
7428 \begin_layout Standard
7429 Reverse search with evince does not work out of the box, but it can be achieved
7430  by means of some third party helper scripts.
7431  Please refer to 
7432 \begin_inset CommandInset href
7433 LatexCommand href
7434 target "http://wiki.lyx.org/LyX/SyncTeX"
7435 literal "false"
7436
7437 \end_inset
7438
7439  for details.
7440 \end_layout
7441
7442 \begin_layout Subsubsection*
7443 Okular (KDE)
7444 \end_layout
7445
7446 \begin_layout Standard
7447 Go to 
7448 \begin_inset Flex Noun
7449 status collapsed
7450
7451 \begin_layout Plain Layout
7452 Settings\SpecialChar menuseparator
7453 Configure Okular\SpecialChar menuseparator
7454 Editor
7455 \end_layout
7456
7457 \end_inset
7458
7459
7460 \change_inserted -712698321 1500981642
7461  and
7462 \change_deleted -712698321 1500981641
7463 ,
7464 \change_unchanged
7465  select 
7466 \change_deleted -712698321 1500981634
7467
7468 \begin_inset Quotes eld
7469 \end_inset
7470
7471 Custom Text Editor
7472 \change_inserted -712698321 1500981635
7473 LyX
7474 \change_unchanged
7475
7476 \begin_inset Quotes erd
7477 \end_inset
7478
7479  
7480 \change_inserted -712698321 1500981659
7481 as editor.
7482  This inserts the appropriate 
7483 \change_deleted -712698321 1500981663
7484 and add the 
7485 \change_unchanged
7486 command 
7487 \change_inserted -712698321 1500981665
7488 (
7489 \change_unchanged
7490
7491 \begin_inset Flex Code
7492 status collapsed
7493
7494 \begin_layout Plain Layout
7495 lyxclient -g %f %l
7496 \end_layout
7497
7498 \end_inset
7499
7500
7501 \change_inserted -712698321 1500981668
7502 )
7503 \change_unchanged
7504 .
7505 \end_layout
7506
7507 \begin_layout Standard
7508 Reverse search is triggered by SHIFT-click.
7509 \end_layout
7510
7511 \begin_layout Subsubsection*
7512 Qpdfview (Unix)
7513 \end_layout
7514
7515 \begin_layout Standard
7516 Qpdfview supports Sync\SpecialChar TeX
7517  since version 0.3.5.
7518  Go to 
7519 \begin_inset Flex Noun
7520 status collapsed
7521
7522 \begin_layout Plain Layout
7523 Edit\SpecialChar menuseparator
7524 Settings\SpecialChar menuseparator
7525 Behavior
7526 \end_layout
7527
7528 \end_inset
7529
7530 , click on the input field of the 
7531 \begin_inset Quotes eld
7532 \end_inset
7533
7534 Source editor
7535 \begin_inset Quotes erd
7536 \end_inset
7537
7538  item and add the command 
7539 \begin_inset Flex Code
7540 status collapsed
7541
7542 \begin_layout Plain Layout
7543 lyxclient -g %1 %2
7544 \end_layout
7545
7546 \end_inset
7547
7548 .
7549 \end_layout
7550
7551 \begin_layout Standard
7552 Reverse search is triggered by double-click or, in more recent versions,
7553  by context menu.
7554 \end_layout
7555
7556 \begin_layout Subsubsection*
7557 YAP (Windows)
7558 \end_layout
7559
7560 \begin_layout Standard
7561 Launch yap, choose its 
7562 \begin_inset Flex Noun
7563 status collapsed
7564
7565 \begin_layout Plain Layout
7566 View\SpecialChar menuseparator
7567 Options
7568 \end_layout
7569
7570 \end_inset
7571
7572  menu and select the 
7573 \begin_inset Quotes eld
7574 \end_inset
7575
7576 Inverse DVI Search
7577 \begin_inset Quotes erd
7578 \end_inset
7579
7580  tab.
7581  Click on the 
7582 \begin_inset Quotes eld
7583 \end_inset
7584
7585 New\SpecialChar ldots
7586
7587 \begin_inset Quotes erd
7588 \end_inset
7589
7590  button and, in the window that opens, enter 
7591 \begin_inset Quotes eld
7592 \end_inset
7593
7594 \SpecialChar LyX
7595  Editor
7596 \begin_inset Quotes erd
7597 \end_inset
7598
7599  (or any other name you like) in the 
7600 \begin_inset Quotes eld
7601 \end_inset
7602
7603 Name:
7604 \begin_inset Quotes erd
7605 \end_inset
7606
7607  field.
7608  Now click on the button labeled 
7609 \begin_inset Quotes eld
7610 \end_inset
7611
7612 \SpecialChar ldots
7613
7614 \begin_inset Quotes erd
7615 \end_inset
7616
7617  to open a file dialog and navigate to the directory containing the batch
7618  file 
7619 \begin_inset Flex Code
7620 status collapsed
7621
7622 \begin_layout Plain Layout
7623 lyxeditor.bat
7624 \end_layout
7625
7626 \end_inset
7627
7628  (see below).
7629  Select 
7630 \begin_inset Flex Code
7631 status collapsed
7632
7633 \begin_layout Plain Layout
7634 lyxeditor.bat
7635 \end_layout
7636
7637 \end_inset
7638
7639  and then specify the program arguments as 
7640 \begin_inset Flex Code
7641 status collapsed
7642
7643 \begin_layout Plain Layout
7644 %f %l
7645 \end_layout
7646
7647 \end_inset
7648
7649 .
7650  The 
7651 \begin_inset Flex Code
7652 status collapsed
7653
7654 \begin_layout Plain Layout
7655 lyxeditor.bat
7656 \end_layout
7657
7658 \end_inset
7659
7660  wrapper is used for communicating with \SpecialChar LyX
7661  through the 
7662 \emph on
7663 lyxpipe
7664 \emph default
7665  and is as follows:
7666 \end_layout
7667
7668 \begin_layout LyX-Code
7669 @echo off
7670 \begin_inset Newline newline
7671 \end_inset
7672
7673 echo LYXCMD:revdvi:server-goto-file-row:%~1 %2> 
7674 \backslash
7675
7676 \backslash
7677 .
7678 \backslash
7679 pipe
7680 \backslash
7681 lyxpipe.in
7682 \begin_inset Newline newline
7683 \end_inset
7684
7685 type 
7686 \backslash
7687
7688 \backslash
7689 .
7690 \backslash
7691 pipe
7692 \backslash
7693 lyxpipe.out
7694 \end_layout
7695
7696 \begin_layout Standard
7697 Make sure that the \SpecialChar LyX
7698 Server pipe path you specified in \SpecialChar LyX
7699  is 
7700 \begin_inset Flex Code
7701 status collapsed
7702
7703 \begin_layout Plain Layout
7704
7705 \backslash
7706
7707 \backslash
7708 .
7709 \backslash
7710 pipe
7711 \backslash
7712 lyxpipe
7713 \end_layout
7714
7715 \end_inset
7716
7717 , otherwise change the 
7718 \begin_inset Flex Code
7719 status collapsed
7720
7721 \begin_layout Plain Layout
7722 lyxeditor.bat
7723 \end_layout
7724
7725 \end_inset
7726
7727  wrapper accordingly.
7728 \end_layout
7729
7730 \begin_layout Standard
7731 In yap, reverse search is triggered by double-click.
7732 \end_layout
7733
7734 \begin_layout Subsubsection*
7735 SumatraPDF (Windows)
7736 \end_layout
7737
7738 \begin_layout Standard
7739 In order to use SumatraPDF for inverse search, enter 
7740 \begin_inset Flex Code
7741 status collapsed
7742
7743 \begin_layout Plain Layout
7744 SumatraPDF -inverse-search "lyxeditor.bat "%f" %l"
7745 \end_layout
7746
7747 \end_inset
7748
7749  in the viewer setting in 
7750 \begin_inset Flex Noun
7751 status collapsed
7752
7753 \begin_layout Plain Layout
7754 Preferences\SpecialChar menuseparator
7755 File Handling\SpecialChar menuseparator
7756 File formats\SpecialChar menuseparator
7757 PDF (pdflatex)
7758 \end_layout
7759
7760 \end_inset
7761
7762 , where 
7763 \begin_inset Flex Code
7764 status collapsed
7765
7766 \begin_layout Plain Layout
7767 lyxeditor.bat
7768 \end_layout
7769
7770 \end_inset
7771
7772  is the previous wrapper.
7773  If SumatraPDF.exe is not in your command PATH, use its full file name.
7774 \end_layout
7775
7776 \begin_layout Standard
7777 Reverse search is triggered by double-click.
7778 \end_layout
7779
7780 \begin_layout Subsubsection*
7781 YAP (Cygwin)
7782 \end_layout
7783
7784 \begin_layout Standard
7785 First of all, make sure that yap is your default DVI viewer in the Windows
7786  environment, then launch it, choose its 
7787 \begin_inset Flex Noun
7788 status collapsed
7789
7790 \begin_layout Plain Layout
7791 View\SpecialChar menuseparator
7792 Options
7793 \end_layout
7794
7795 \end_inset
7796
7797  menu and select the 
7798 \begin_inset Quotes eld
7799 \end_inset
7800
7801 Inverse DVI Search
7802 \begin_inset Quotes erd
7803 \end_inset
7804
7805  tab.
7806  Click on the 
7807 \begin_inset Quotes eld
7808 \end_inset
7809
7810 New\SpecialChar ldots
7811
7812 \begin_inset Quotes erd
7813 \end_inset
7814
7815  button and, in the window that opens, enter 
7816 \begin_inset Quotes eld
7817 \end_inset
7818
7819 \SpecialChar LyX
7820  Editor
7821 \begin_inset Quotes erd
7822 \end_inset
7823
7824  (or any other name you like) in the 
7825 \begin_inset Quotes eld
7826 \end_inset
7827
7828 Name:
7829 \begin_inset Quotes erd
7830 \end_inset
7831
7832  field.
7833  Now click on the button labeled 
7834 \begin_inset Quotes eld
7835 \end_inset
7836
7837 \SpecialChar ldots
7838
7839 \begin_inset Quotes erd
7840 \end_inset
7841
7842  to open a file dialog and navigate to the directory containing the 
7843 \begin_inset Flex Code
7844 status collapsed
7845
7846 \begin_layout Plain Layout
7847 lyxeditor.exe
7848 \end_layout
7849
7850 \end_inset
7851
7852  program (which is installed by default on Cygwin along with the \SpecialChar LyX
7853  executable).
7854  Select 
7855 \begin_inset Flex Code
7856 status collapsed
7857
7858 \begin_layout Plain Layout
7859 lyxeditor.exe
7860 \end_layout
7861
7862 \end_inset
7863
7864  and then specify the program arguments as 
7865 \begin_inset Flex Code
7866 status collapsed
7867
7868 \begin_layout Plain Layout
7869 -g %f %l
7870 \end_layout
7871
7872 \end_inset
7873
7874 .
7875  In this way, you will be using the 
7876 \emph on
7877 lyxsocket
7878 \emph default
7879  for communicating with \SpecialChar LyX
7880 .
7881  If, for whatever reason, you want to use the 
7882 \emph on
7883 lyxpipe
7884 \emph default
7885 , omit the 
7886 \begin_inset Flex Code
7887 status collapsed
7888
7889 \begin_layout Plain Layout
7890 -g
7891 \end_layout
7892
7893 \end_inset
7894
7895  option and be sure to specify the \SpecialChar LyX
7896 Server pipe path in the \SpecialChar LyX
7897  preferences.
7898 \end_layout
7899
7900 \begin_layout Standard
7901 In yap, reverse search is triggered by double-click.
7902 \end_layout
7903
7904 \begin_layout Subsubsection*
7905 SumatraPDF (Cygwin)
7906 \end_layout
7907
7908 \begin_layout Standard
7909 In order to use SumatraPDF for inverse search, enter 
7910 \begin_inset Flex Code
7911 status collapsed
7912
7913 \begin_layout Plain Layout
7914 SumatraPDF -inverse-search "lyxeditor -g %f %l"
7915 \end_layout
7916
7917 \end_inset
7918
7919  in the viewer setting in 
7920 \begin_inset Flex Noun
7921 status collapsed
7922
7923 \begin_layout Plain Layout
7924 Preferences\SpecialChar menuseparator
7925 File Handling\SpecialChar menuseparator
7926 File formats\SpecialChar menuseparator
7927 PDF (pdflatex)
7928 \end_layout
7929
7930 \end_inset
7931
7932 .
7933  If SumatraPDF.exe is not in your command PATH, use its full posix path.
7934  The 
7935 \begin_inset Flex Code
7936 status collapsed
7937
7938 \begin_layout Plain Layout
7939 -g
7940 \end_layout
7941
7942 \end_inset
7943
7944  enables communication via the 
7945 \emph on
7946 lyxsocket
7947 \emph default
7948 .
7949  Again, omit the 
7950 \begin_inset Flex Code
7951 status collapsed
7952
7953 \begin_layout Plain Layout
7954 -g
7955 \end_layout
7956
7957 \end_inset
7958
7959  option if you want to use the 
7960 \emph on
7961 lyxpipe
7962 \emph default
7963 , and be sure to specify the \SpecialChar LyX
7964 Server pipe path in the \SpecialChar LyX
7965  preferences.
7966 \end_layout
7967
7968 \begin_layout Standard
7969 Reverse search is triggered by double-click.
7970 \end_layout
7971
7972 \begin_layout Section
7973 Forward search
7974 \end_layout
7975
7976 \begin_layout Standard
7977 Forward search is, as the name implies, in a sense the 
7978 \begin_inset Quotes eld
7979 \end_inset
7980
7981 opposite
7982 \begin_inset Quotes erd
7983 \end_inset
7984
7985  of reverse search.
7986  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
7987 .
7988  If forward search is set up (as described in what follows), you can put
7989  the cursor anywhere in your \SpecialChar LyX
7990  document, and hit 
7991 \begin_inset Flex Noun
7992 status collapsed
7993
7994 \begin_layout Plain Layout
7995 Navigate\SpecialChar menuseparator
7996 Forward search
7997 \end_layout
7998
7999 \end_inset
8000
8001  (or select 
8002 \begin_inset Flex Noun
8003 status collapsed
8004
8005 \begin_layout Plain Layout
8006 Forward search
8007 \end_layout
8008
8009 \end_inset
8010
8011  in the context menu via right mouse click), and then the viewer will jump
8012  to that position as well.
8013  This implies, of course, that your viewer supports this function.
8014 \end_layout
8015
8016 \begin_layout Standard
8017 To make forward search possible, you first need to provide the generated
8018  output PDF/DVI file with additional information about the \SpecialChar TeX
8019  sources.
8020  This can be done via the methods described in the section 
8021 \begin_inset CommandInset ref
8022 LatexCommand ref
8023 reference "subsec:rev-search"
8024
8025 \end_inset
8026
8027 .
8028 \end_layout
8029
8030 \begin_layout Standard
8031 Additionally, you need to configure \SpecialChar LyX
8032  for using your viewers in 
8033 \begin_inset Flex Noun
8034 status collapsed
8035
8036 \begin_layout Plain Layout
8037 Tools\SpecialChar menuseparator
8038 Preferences\SpecialChar menuseparator
8039 Output\SpecialChar menuseparator
8040 General
8041 \end_layout
8042
8043 \end_inset
8044
8045 .
8046  We provide a range of tested configurations for some viewers, which you
8047  can select from the drop down list.
8048  If none of these configurations suits you, you have to find out and enter
8049  a suitable configuration yourself.
8050  The definition syntax uses the following placeholders:
8051 \end_layout
8052
8053 \begin_layout Itemize
8054 \noindent
8055 \begin_inset Flex Code
8056 status collapsed
8057
8058 \begin_layout Plain Layout
8059 $$n
8060 \end_layout
8061
8062 \end_inset
8063
8064 : row number
8065 \end_layout
8066
8067 \begin_layout Itemize
8068 \noindent
8069 \begin_inset Flex Code
8070 status collapsed
8071
8072 \begin_layout Plain Layout
8073 $$t
8074 \end_layout
8075
8076 \end_inset
8077
8078 : name of the (temporary) exported .tex file (without path)
8079 \end_layout
8080
8081 \begin_layout Itemize
8082 \noindent
8083 \begin_inset Flex Code
8084 status collapsed
8085
8086 \begin_layout Plain Layout
8087 $$f
8088 \end_layout
8089
8090 \end_inset
8091
8092 : name of the (temporary) exported .tex file (including path)
8093 \end_layout
8094
8095 \begin_layout Itemize
8096 \noindent
8097 \begin_inset Flex Code
8098 status collapsed
8099
8100 \begin_layout Plain Layout
8101 $$o
8102 \end_layout
8103
8104 \end_inset
8105
8106 : name of the exported output file (either dvi or pdf, depending on which
8107  one exists in the temporary directory)
8108 \end_layout
8109
8110 \begin_layout Standard
8111 Note that only some of the viewers provide full and usable forward search
8112  functionality out of the box, among them yap, xdvi, okular
8113 \begin_inset Foot
8114 status collapsed
8115
8116 \begin_layout Plain Layout
8117 You might want to set 
8118 \begin_inset Flex Code
8119 status collapsed
8120
8121 \begin_layout Plain Layout
8122 okular –unique
8123 \end_layout
8124
8125 \end_inset
8126
8127  in 
8128 \begin_inset Flex Noun
8129 status collapsed
8130
8131 \begin_layout Plain Layout
8132 Tools\SpecialChar menuseparator
8133 Preferences\SpecialChar menuseparator
8134 File Handling\SpecialChar menuseparator
8135 File
8136 \begin_inset space ~
8137 \end_inset
8138
8139 Formats
8140 \end_layout
8141
8142 \end_inset
8143
8144
8145 \end_layout
8146
8147 \end_inset
8148
8149 , qpdfview, and SumatraPDF
8150 \begin_inset Foot
8151 status collapsed
8152
8153 \begin_layout Plain Layout
8154 SumatraPDF can also use DDE commands through the external program CMCDDE
8155  — downloadable from 
8156 \begin_inset CommandInset href
8157 LatexCommand href
8158 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
8159 literal "false"
8160
8161 \end_inset
8162
8163
8164 \end_layout
8165
8166 \end_inset
8167
8168 .
8169  Others, such as evince
8170 \begin_inset Foot
8171 status collapsed
8172
8173 \begin_layout Plain Layout
8174 Forward search with evince can be achieved by means of third party helper
8175  scripts.
8176  Please refer to 
8177 \begin_inset CommandInset href
8178 LatexCommand href
8179 target "http://wiki.lyx.org/LyX/SyncTeX"
8180 literal "false"
8181
8182 \end_inset
8183
8184  for details.
8185 \end_layout
8186
8187 \end_inset
8188
8189 , require some extra tools in order to use forward search.
8190  While many of the widespread PDF viewers (most notably Adobe Reader) do
8191  not support forward search at all, some other viewers – e.
8192 \begin_inset space \thinspace{}
8193 \end_inset
8194
8195 g.
8196  xpdf – allow at least to reload the document and jump to a specific page
8197  of the file, so you can at least navigate 
8198 \begin_inset Quotes eld
8199 \end_inset
8200
8201 near
8202 \begin_inset Quotes erd
8203 \end_inset
8204
8205 .
8206  This latter functionality is provided by an external call of synctex (see
8207  the predefined example configurations).
8208  
8209 \end_layout
8210
8211 \begin_layout Standard
8212 Forward search works both with DVI and PDF output.
8213  \SpecialChar LyX
8214  simply checks which preview format you have used before (i.
8215 \begin_inset space \thinspace{}
8216 \end_inset
8217
8218 e., which format is already there in the temporary directory) and chooses
8219  the appropriate configuration for the respective format.
8220 \end_layout
8221
8222 \begin_layout Chapter
8223 Special Document Classes
8224 \end_layout
8225
8226 \begin_layout Section
8227 A&A Paper
8228 \end_layout
8229
8230 \begin_layout Standard
8231 by 
8232 \noun on
8233 Peter Sütterlin
8234 \end_layout
8235
8236 \begin_layout Subsection
8237 Introduction
8238 \end_layout
8239
8240 \begin_layout Standard
8241 This section describes how \SpecialChar LyX
8242  can be used to write articles for submission
8243  to the scientific journal 
8244 \emph on
8245 Astronomy and Astrophysics
8246 \emph default
8247  (
8248 \begin_inset Flex URL
8249 status collapsed
8250
8251 \begin_layout Plain Layout
8252
8253 http://www.edpsciences.fr/aa/
8254 \end_layout
8255
8256 \end_inset
8257
8258 ) using Version 5.01 of the document class 
8259 \family typewriter
8260 aa.cls
8261 \family default
8262 .
8263  This package can be downloaded from the ftp site
8264 \end_layout
8265
8266 \begin_layout Standard
8267 \begin_inset VSpace medskip
8268 \end_inset
8269
8270
8271 \end_layout
8272
8273 \begin_layout Standard
8274 \align center
8275 \begin_inset Flex URL
8276 status collapsed
8277
8278 \begin_layout Plain Layout
8279
8280 ftp://ftp.edpsciences.org/pub/aa/readme.html
8281 \end_layout
8282
8283 \end_inset
8284
8285
8286 \end_layout
8287
8288 \begin_layout Standard
8289 \begin_inset VSpace medskip
8290 \end_inset
8291
8292
8293 \end_layout
8294
8295 \begin_layout Standard
8296 A manual comes together with that package, and this text is not meant to
8297  replace the original manual but is merely a short guide in how to realize
8298  the correct form of your paper.
8299  
8300 \end_layout
8301
8302 \begin_layout Standard
8303 Please note that the publisher of the journal was changed from Springer
8304  to EDP Sciences starting January 1, 2001.
8305  That change involved also some slight changes to the style files, namely
8306  the removal of the thesaurus command.
8307  The \SpecialChar LyX
8308  class aa supports the newest version of these style files, V 5.01.
8309  If you have an older version installed, please upgrade.
8310  For compatibility, the old (version 4) layout has been kept as 
8311 \family sans
8312 article (A&A V4)
8313 \family default
8314 .
8315  Please refer to the comments in 
8316 \family typewriter
8317 \SpecialChar LyX
8318 Dir/layouts/aapaper.layout
8319 \family default
8320 .
8321 \end_layout
8322
8323 \begin_layout Subsection
8324 Getting started
8325 \end_layout
8326
8327 \begin_layout Standard
8328 It is recommended you start from the example template distributed with \SpecialChar LyX
8329 .
8330  If you are not using a template, note the following settings:
8331 \end_layout
8332
8333 \begin_layout Itemize
8334 Select 
8335 \family sans
8336 article (A&A)
8337 \family default
8338  in the 
8339 \family sans
8340 Document\SpecialChar menuseparator
8341 Settings
8342 \family default
8343  dialog (OK, that one was obvious).
8344 \end_layout
8345
8346 \begin_layout Itemize
8347 Don't change the option 
8348 \family sans
8349 Page
8350 \begin_inset space ~
8351 \end_inset
8352
8353 style
8354 \family default
8355 : Leave it set to 
8356 \family sans
8357 default
8358 \family default
8359 .
8360  The whole layout is done by the macros, you shouldn't change anything.
8361 \end_layout
8362
8363 \begin_layout Subsection
8364 The header block
8365 \end_layout
8366
8367 \begin_layout Standard
8368 First thing to enter is the header information.
8369  It consists of seven entries, of which some are optional.
8370  They are
8371 \end_layout
8372
8373 \begin_layout Itemize
8374
8375 \family sans
8376 Title
8377 \family default
8378 : [required] 
8379 \end_layout
8380
8381 \begin_layout Itemize
8382
8383 \family sans
8384 Subtitle
8385 \family default
8386 : [optional] 
8387 \end_layout
8388
8389 \begin_layout Itemize
8390
8391 \family sans
8392 Author
8393 \family default
8394 : [required]
8395 \end_layout
8396
8397 \begin_layout Itemize
8398
8399 \family sans
8400 Address
8401 \family default
8402 : [required]
8403 \end_layout
8404
8405 \begin_layout Itemize
8406
8407 \family sans
8408 Offprints
8409 \family default
8410 : [optional] if more than one author: whom to contact for offprint requests.
8411 \end_layout
8412
8413 \begin_layout Itemize
8414
8415 \family sans
8416 Mail
8417 \family default
8418 : [optional] mail address for contacts.
8419 \end_layout
8420
8421 \begin_layout Itemize
8422
8423 \family sans
8424 Date
8425 \family default
8426 : [required].
8427  Suggested format is 
8428 \family typewriter
8429 Received: <date>; Accepted <date> 
8430 \end_layout
8431
8432 \begin_layout Standard
8433 There is no need to issue the 
8434 \family typewriter
8435
8436 \backslash
8437 maketitle
8438 \family default
8439  command, this is done automatically by \SpecialChar LyX
8440  when the header is finished.
8441  Although the order of the single header entries doesn't matter it is advised
8442  to keep the above sequence, just to get the best optics and meets the layout
8443  of the real document.
8444 \end_layout
8445
8446 \begin_layout Standard
8447 If you want to place footnotes in the header block, e.
8448 \begin_inset space \thinspace{}
8449 \end_inset
8450
8451 g.
8452 \begin_inset space \space{}
8453 \end_inset
8454
8455 to state your present address, just use the standard footnote via the menu
8456  
8457 \family sans
8458 Insert\SpecialChar menuseparator
8459 Footnote.
8460
8461 \family default
8462  \SpecialChar LyX
8463  will automagically use the term 
8464 \family typewriter
8465
8466 \backslash
8467 thanks{}
8468 \family default
8469  in that case.
8470 \change_inserted -712698321 1501150851
8471
8472 \end_layout
8473
8474 \begin_layout Standard
8475
8476 \change_inserted -712698321 1501150892
8477 Under 
8478 \family sans
8479 Edit\SpecialChar menuseparator
8480 Text Style
8481 \family default
8482 , you'll find two insets which are relevant for the titling:
8483 \end_layout
8484
8485 \begin_layout Itemize
8486
8487 \change_inserted -712698321 1501150936
8488
8489 \family sans
8490 Institute
8491 \family typewriter
8492  
8493 \family default
8494 to mark corresponding author\SpecialChar breakableslash
8495 institute pairs.
8496  The institutes are numbered sequentially as they appear in the 
8497 \family sans
8498 Address
8499 \family default
8500  field, so you have to put a marker to each author.
8501 \end_layout
8502
8503 \begin_layout Itemize
8504
8505 \change_inserted -712698321 1501150947
8506
8507 \family sans
8508 Email
8509 \family default
8510  to supply an email address for fast contact.
8511 \change_unchanged
8512
8513 \end_layout
8514
8515 \begin_layout Standard
8516 In addition to these topics, the macros use
8517 \change_deleted -712698321 1501150958
8518  three
8519 \change_inserted -712698321 1501150961
8520  one
8521 \change_unchanged
8522  additional \SpecialChar LaTeX
8523  command
8524 \change_deleted -712698321 1501150963
8525 s
8526 \change_unchanged
8527  that ha
8528 \change_deleted -712698321 1501150967
8529 ve
8530 \change_inserted -712698321 1501150967
8531 s
8532 \change_unchanged
8533  no counterpart in \SpecialChar LyX
8534 :
8535 \end_layout
8536
8537 \begin_layout Itemize
8538
8539 \family typewriter
8540
8541 \backslash
8542 and
8543 \family default
8544  to separate different names for more than one author and institute, respectivel
8545 y.
8546 \end_layout
8547
8548 \begin_layout Itemize
8549
8550 \change_deleted -712698321 1501150911
8551
8552 \family typewriter
8553
8554 \backslash
8555 inst{<nr>}
8556 \family default
8557 to mark corresponding author/institute pairs.
8558  The institutes are numbered sequentially as they appear in the 
8559 \family sans
8560 Address
8561 \family default
8562  field, so you have to put a marker to each author.
8563 \end_layout
8564
8565 \begin_layout Itemize
8566
8567 \change_deleted -712698321 1501150911
8568
8569 \family typewriter
8570
8571 \backslash
8572 email{address}
8573 \family default
8574  to supply an email address for fast contact.
8575 \change_unchanged
8576
8577 \end_layout
8578
8579 \begin_layout Standard
8580
8581 \change_deleted -712698321 1501150972
8582 In all cases, t
8583 \change_inserted -712698321 1501150972
8584 T
8585 \change_unchanged
8586 he appropriate command has to be entered in \SpecialChar LyX
8587  and marked as \SpecialChar LaTeX
8588  code.
8589  See the examples.
8590  
8591 \end_layout
8592
8593 \begin_layout Subsection
8594 The abstract
8595 \end_layout
8596
8597 \begin_layout Standard
8598 The abstract should immediately follow the header block.
8599  With version 5 the abstract environment was changed to a command, and there
8600  is now a resctriction to only one paragraph.
8601  In addition, it should contain an entry with the keywords.
8602  This is 
8603 \change_deleted -712698321 1501151111
8604 not yet implemented for \SpecialChar LyX
8605 , therefore you have to enter the \SpecialChar LaTeX
8606  command 
8607 \family typewriter
8608
8609 \backslash
8610 keywords{}
8611 \family default
8612  by hand and mark it as \SpecialChar LaTeX
8613  code
8614 \change_inserted -712698321 1501151122
8615 done via the paragraph style 
8616 \family sans
8617 Keywords
8618 \change_unchanged
8619
8620 \family default
8621 .
8622  Refer to the example paper.
8623 \end_layout
8624
8625 \begin_layout Subsection
8626 Supported environments
8627 \end_layout
8628
8629 \begin_layout Standard
8630 The A&A paper layout supports the following environments for structuring
8631  your text:
8632 \end_layout
8633
8634 \begin_layout Itemize
8635
8636 \family sans
8637 Standard
8638 \end_layout
8639
8640 \begin_layout Itemize
8641
8642 \family sans
8643 Section
8644 \end_layout
8645
8646 \begin_layout Itemize
8647
8648 \family sans
8649 Subsection
8650 \end_layout
8651
8652 \begin_layout Itemize
8653
8654 \family sans
8655 Subsubsection
8656 \end_layout
8657
8658 \begin_layout Itemize
8659
8660 \family sans
8661 Itemize
8662 \end_layout
8663
8664 \begin_layout Itemize
8665
8666 \family sans
8667 Enumerate
8668 \end_layout
8669
8670 \begin_layout Itemize
8671
8672 \family sans
8673 Description
8674 \end_layout
8675
8676 \begin_layout Itemize
8677
8678 \family sans
8679 Caption
8680 \end_layout
8681
8682 \begin_layout Itemize
8683
8684 \family sans
8685 Abstract
8686 \end_layout
8687
8688 \begin_layout Itemize
8689
8690 \family sans
8691 Acknowledgment
8692 \end_layout
8693
8694 \begin_layout Itemize
8695
8696 \family sans
8697 Bibliography
8698 \end_layout
8699
8700 \begin_layout Itemize
8701
8702 \family sans
8703 \SpecialChar LaTeX
8704
8705 \end_layout
8706
8707 \begin_layout Subsection
8708 Commands not supported by \SpecialChar LyX
8709
8710 \end_layout
8711
8712 \begin_layout Standard
8713 Some commands are not yet supported by the 
8714 \family sans
8715 paper (A&A)
8716 \family default
8717  layout for \SpecialChar LyX
8718 .
8719  Some have already been mentioned.
8720  For the sake of completeness, they are listed all together here:
8721 \end_layout
8722
8723 \begin_layout Itemize
8724
8725 \family typewriter
8726
8727 \backslash
8728 and
8729 \end_layout
8730
8731 \begin_layout Itemize
8732
8733 \change_deleted -712698321 1501151229
8734
8735 \family typewriter
8736
8737 \backslash
8738 email
8739 \change_unchanged
8740
8741 \end_layout
8742
8743 \begin_layout Itemize
8744
8745 \change_deleted -712698321 1501151308
8746
8747 \family typewriter
8748
8749 \backslash
8750 appendix
8751 \change_unchanged
8752
8753 \end_layout
8754
8755 \begin_layout Itemize
8756
8757 \family typewriter
8758
8759 \backslash
8760 authorrunning
8761 \end_layout
8762
8763 \begin_layout Itemize
8764
8765 \change_deleted -712698321 1501151231
8766
8767 \family typewriter
8768
8769 \backslash
8770 inst{}
8771 \end_layout
8772
8773 \begin_layout Itemize
8774
8775 \change_deleted -712698321 1501151231
8776
8777 \family typewriter
8778
8779 \backslash
8780 keywords{}
8781 \change_unchanged
8782
8783 \end_layout
8784
8785 \begin_layout Itemize
8786
8787 \family typewriter
8788
8789 \backslash
8790 object{}
8791 \end_layout
8792
8793 \begin_layout Itemize
8794
8795 \family typewriter
8796
8797 \backslash
8798 titlerunning{}
8799 \end_layout
8800
8801 \begin_layout Standard
8802 If you want to use any of these commands, you have to enter them yourself.
8803  
8804 \series bold
8805 Do not forget to mark them as \SpecialChar LaTeX
8806  code!
8807 \end_layout
8808
8809 \begin_layout Subsection
8810 Figure and Table Floats
8811 \end_layout
8812
8813 \begin_layout Standard
8814 \SpecialChar LyX
8815  provides support for the necessary float environments 
8816 \family sans
8817 figure, figure*, table
8818 \family default
8819  and 
8820 \family sans
8821 table*
8822 \family default
8823 , therefore we won't tell much about it here.
8824  Refer to the 
8825 \emph on
8826 User's
8827 \begin_inset space ~
8828 \end_inset
8829
8830 Guide
8831 \emph default
8832 .
8833  Just remember that tables should be left-aligned.
8834  For that, select the table and change the alignment in 
8835 \family sans
8836 Edit\SpecialChar menuseparator
8837 Paragraph
8838 \begin_inset space ~
8839 \end_inset
8840
8841 Settings.
8842 \end_layout
8843
8844 \begin_layout Standard
8845 There is only one special thing: the figures with caption besides the figure.
8846  To create such a figure, you have to do the following:
8847 \end_layout
8848
8849 \begin_layout Enumerate
8850 Create a wide figure float: 
8851 \family sans
8852 Insert\SpecialChar menuseparator
8853 Float\SpecialChar menuseparator
8854 Figure
8855 \family default
8856 , then right click in the figure and select 
8857 \family sans
8858 Span
8859 \begin_inset space ~
8860 \end_inset
8861
8862 columns
8863 \family default
8864 .
8865 \end_layout
8866
8867 \begin_layout Enumerate
8868 Enter your caption text.
8869 \end_layout
8870
8871 \begin_layout Enumerate
8872 Press 
8873 \family sans
8874 Return
8875 \family default
8876  to move the cursor above the caption.
8877 \end_layout
8878
8879 \begin_layout Enumerate
8880 Insert your figure
8881 \end_layout
8882
8883 \begin_layout Enumerate
8884 Position the cursor behind the figure and insert a horizontal fill: 
8885 \family sans
8886 Insert\SpecialChar menuseparator
8887 Special
8888 \begin_inset space ~
8889 \end_inset
8890
8891 Character\SpecialChar menuseparator
8892 Horizontal
8893 \begin_inset space ~
8894 \end_inset
8895
8896 Fill
8897 \family default
8898 .
8899 \end_layout
8900
8901 \begin_layout Enumerate
8902 Switch to \SpecialChar LaTeX
8903  mode: 
8904 \family sans
8905 M-c
8906 \begin_inset space ~
8907 \end_inset
8908
8909 t
8910 \family default
8911 .
8912 \end_layout
8913
8914 \begin_layout Enumerate
8915 Enter 
8916 \family typewriter
8917
8918 \backslash
8919 parbox[b]{55mm}{
8920 \family default
8921 .
8922  
8923 \series bold
8924 Do not close the brace!
8925 \end_layout
8926
8927 \begin_layout Enumerate
8928 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
8929  mode and insert
8930  the closing brace: 
8931 \family sans
8932 M-c
8933 \begin_inset space ~
8934 \end_inset
8935
8936 t
8937 \family default
8938  
8939 \family typewriter
8940 }
8941 \family default
8942 .
8943 \end_layout
8944
8945 \begin_layout Standard
8946 Also, refer to the figures in the example paper.
8947 \end_layout
8948
8949 \begin_layout Subsection
8950 Referee layout
8951 \end_layout
8952
8953 \begin_layout Standard
8954 For submission, the paper has to be formated in a special double-spacing
8955  layout.
8956  For this purpose, you have to give the option 
8957 \family typewriter
8958 referee
8959 \family default
8960  to the documentclass.
8961  This must be done using the 
8962 \change_deleted -712698321 1501151486
8963 extra
8964 \change_inserted -712698321 1501151487
8965 custom
8966 \change_unchanged
8967  class options field in the 
8968 \family sans
8969 Document\SpecialChar menuseparator
8970 Settings
8971 \family default
8972  dialog.
8973  Just enter the string 
8974 \family typewriter
8975 referee
8976 \family default
8977  there.
8978 \end_layout
8979
8980 \begin_layout Subsection
8981 The example paper
8982 \end_layout
8983
8984 \begin_layout Standard
8985 The 
8986 \family sans
8987 Examples
8988 \family default
8989  directory contains an example paper written with \SpecialChar LyX
8990 .
8991  It is the example paper from the original macro package, translated to
8992  \SpecialChar LyX
8993 .
8994  Use it for inspiration, and compare the original \SpecialChar LaTeX
8995  code with \SpecialChar LyX
8996  way of writing.
8997 \end_layout
8998
8999 \begin_layout Section
9000 AAS\SpecialChar TeX
9001
9002 \end_layout
9003
9004 \begin_layout Standard
9005 by 
9006 \noun on
9007 Mike Ressler
9008 \end_layout
9009
9010 \begin_layout Subsection
9011 Introduction
9012 \end_layout
9013
9014 \begin_layout Standard
9015 AAS\SpecialChar TeX
9016  is a set of macros produced by the American Astronomical Society to
9017  facilitate electronic manuscript submission to the three journals they
9018  publish: the Astrophysical Journal (including the Letters and Supplement),
9019  the Astronomical Journal, and the Publications of the Astronomical Society
9020  of the Pacific.
9021  \SpecialChar LyX
9022  has proven to be an excellent tool for generating these documents, especially
9023  given its equation, citation, and figure handling capabilities.
9024  \SpecialChar LyX
9025  requires version 5.0 (or higher) of these macros; preferably 
9026 \change_deleted -712698321 1501152764
9027 5.2
9028 \change_inserted -712698321 1501152766
9029 6.0
9030 \change_unchanged
9031 , which is the version described here, or higher.
9032  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
9033 2.09 and are fundamentally
9034  incompatible with \SpecialChar LyX
9035 .
9036  The AAS\SpecialChar TeX
9037  package may be downloaded from the AAS\SpecialChar TeX
9038  Web site
9039 \end_layout
9040
9041 \begin_layout Standard
9042 \begin_inset VSpace medskip
9043 \end_inset
9044
9045
9046 \end_layout
9047
9048 \begin_layout Standard
9049 \align center
9050 \begin_inset Flex URL
9051 status collapsed
9052
9053 \begin_layout Plain Layout
9054
9055 https://aas.org/aastex/aastex-downloads
9056 \end_layout
9057
9058 \end_inset
9059
9060
9061 \end_layout
9062
9063 \begin_layout Standard
9064 \begin_inset VSpace medskip
9065 \end_inset
9066
9067
9068 \end_layout
9069
9070 \begin_layout Standard
9071 A complete user guide is contained in that package and you should familiarize
9072  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
9073 .
9074  \SpecialChar LyX
9075  will not reduce the need to figure out all the AAS\SpecialChar TeX
9076  commands, it will only
9077  reduce the drudgery of typing everything in.
9078  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
9079  document conforms
9080  completely to the requirements of the journal to which you are submitting
9081  your paper.
9082 \end_layout
9083
9084 \begin_layout Subsection
9085 Starting a New Paper
9086 \end_layout
9087
9088 \begin_layout Standard
9089 I strongly suggest that you start with the AAS\SpecialChar TeX
9090  template file.
9091  Click on 
9092 \family sans
9093 File\SpecialChar menuseparator
9094 New from
9095 \family default
9096  
9097 \family sans
9098 Template
9099 \family default
9100 , enter the new file name, then choose the 
9101 \family typewriter
9102 aastex
9103 \change_inserted -712698321 1501152130
9104 6
9105 \change_unchanged
9106 .lyx
9107 \family default
9108  template.
9109  This will show the most common fields found in a manuscript.
9110  Simply overwrite the existing text (including the brackets, 
9111 \family typewriter
9112 <>
9113 \family default
9114 ) with the correct information.
9115  Many of the AAS\SpecialChar TeX
9116  commands and environments can be implemented directly in
9117  \SpecialChar LyX
9118 , but some cannot
9119 \change_deleted -712698321 1501152213
9120 : most noticeably 
9121 \family typewriter
9122
9123 \backslash
9124 altaffilmark
9125 \family default
9126  and 
9127 \family typewriter
9128
9129 \backslash
9130 altaffiltext
9131 \family default
9132 , which should stick out like a sore thumb if you actually just opened the
9133  template file
9134 \change_unchanged
9135 .
9136  For commands such as these, the \SpecialChar LaTeX
9137  code must be entered directly and marked
9138  as such.
9139  Such commands are referred to as \SpecialChar TeX
9140  code, or Evil Red Text.
9141  I tried to minimize the amount of \SpecialChar TeX
9142  code needed in an AAS\SpecialChar TeX
9143  document
9144 \change_deleted -712698321 1501152220
9145 , but there is still a bit more required than any of us would like
9146 \change_unchanged
9147 .
9148 \end_layout
9149
9150 \begin_layout Subsection
9151 Finishing Your Paper
9152 \end_layout
9153
9154 \begin_layout Standard
9155 When the paper is finished to your satisfaction and previews/prints correctly,
9156  there are a few 
9157 \begin_inset Quotes eld
9158 \end_inset
9159
9160 postprocessing
9161 \begin_inset Quotes erd
9162 \end_inset
9163
9164  actions which need to be done before you submit it to the journals.
9165  
9166 \end_layout
9167
9168 \begin_layout Enumerate
9169 Export your paper as a \SpecialChar LaTeX
9170  file (
9171 \family sans
9172 File\SpecialChar menuseparator
9173 Export\SpecialChar menuseparator
9174 \SpecialChar LaTeX
9175
9176 \family default
9177 ).
9178  
9179 \end_layout
9180
9181 \begin_layout Enumerate
9182 Edit the resulting 
9183 \family typewriter
9184 .tex
9185 \family default
9186  file with your favorite text editor
9187 \end_layout
9188
9189 \begin_deeper
9190 \begin_layout Enumerate
9191 remove the comment lines before the 
9192 \family typewriter
9193
9194 \backslash
9195 documentclass
9196 \family default
9197  command
9198 \end_layout
9199
9200 \begin_layout Enumerate
9201 remove the 
9202 \family typewriter
9203
9204 \backslash
9205 usepackage...{fontenc}
9206 \family default
9207  line if it appears (usually just after 
9208 \family typewriter
9209
9210 \backslash
9211 documentclass
9212 \family default
9213 }; also remove the 
9214 \family typewriter
9215
9216 \backslash
9217 secnumdepth
9218 \family default
9219  line if it appears.
9220 \end_layout
9221
9222 \begin_layout Enumerate
9223 remove everything between (and including) the 
9224 \family typewriter
9225
9226 \backslash
9227 makeatletter
9228 \family default
9229  and 
9230 \family typewriter
9231
9232 \backslash
9233 makeatother
9234 \family default
9235  commands, except for any commands you specifically put into the \SpecialChar LaTeX
9236  preamble
9237  (which should appear immediately after the 
9238 \begin_inset Quotes eld
9239 \end_inset
9240
9241 User specified \SpecialChar LaTeX
9242  commands
9243 \begin_inset Quotes erd
9244 \end_inset
9245
9246  comment in the 
9247 \family typewriter
9248 .tex
9249 \family default
9250  file).
9251 \end_layout
9252
9253 \end_deeper
9254 \begin_layout Enumerate
9255 Run the resulting file through \SpecialChar LaTeX
9256  to make sure it still processes correctly.
9257 \end_layout
9258
9259 \begin_layout Enumerate
9260 Reread the journal requirements to make sure your filenames and formats
9261  are correct.
9262 \end_layout
9263
9264 \begin_layout Enumerate
9265 Submit it.
9266 \end_layout
9267
9268 \begin_layout Subsection
9269 Comments On Specific Commands
9270 \end_layout
9271
9272 \begin_layout Standard
9273 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
9274  commands: the
9275  AAS\SpecialChar TeX
9276  User Guide (
9277 \family typewriter
9278 aasguide.tex
9279 \family default
9280 ) gives a good description of each.
9281  Thus it's probably easiest for me to go down the list as found in the guide
9282  and offer comments where necessary.
9283  So let's begin \SpecialChar ldots
9284
9285 \end_layout
9286
9287 \begin_layout Subsubsection
9288 Things that work as expected
9289 \end_layout
9290
9291 \begin_layout Standard
9292 Because they work as you might expect, I simply list them and the section
9293  they are found in: 
9294 \family typewriter
9295
9296 \backslash
9297 documentclass
9298 \family default
9299  (2.1.1), 
9300 \family typewriter
9301
9302 \backslash
9303 begin{document}
9304 \family default
9305  (2.2), 
9306 \family typewriter
9307
9308 \backslash
9309 title
9310 \family default
9311  (2.3), 
9312 \family typewriter
9313
9314 \backslash
9315 author
9316 \family default
9317  (2.3), 
9318 \family typewriter
9319
9320 \backslash
9321 affil
9322 \family default
9323  (2.3), 
9324 \family typewriter
9325
9326 \backslash
9327 abstract
9328 \family default
9329  (2.4), 
9330 \family typewriter
9331
9332 \backslash
9333 keywords
9334 \family default
9335  (2.5), 
9336 \family typewriter
9337
9338 \backslash
9339 section
9340 \family default
9341  (2.7), 
9342 \family typewriter
9343
9344 \backslash
9345 subsection
9346 \family default
9347  (2.7), 
9348 \family typewriter
9349
9350 \backslash
9351 subsubsection
9352 \family default
9353  (2.7), 
9354 \family typewriter
9355
9356 \backslash
9357 paragraph
9358 \family default
9359  (2.7), 
9360 \family typewriter
9361
9362 \backslash
9363 facility
9364 \family default
9365  (2.10), 
9366 \family typewriter
9367
9368 \backslash
9369 begin{displaymath}
9370 \family default
9371  (2.12), 
9372 \family typewriter
9373
9374 \backslash
9375 begin{equation}
9376 \family default
9377  (2.12), 
9378 \family typewriter
9379
9380 \backslash
9381 begin{eqnarray}
9382 \family default
9383  (2.12), 
9384 \family typewriter
9385
9386 \backslash
9387 begin{mathletters}
9388 \family default
9389  (2.12), 
9390 \family typewriter
9391
9392 \backslash
9393 begin{thebibliography}
9394 \family default
9395  (2.13.1), 
9396 \family typewriter
9397
9398 \backslash
9399 bibitem
9400 \family default
9401  (2.13.2), all the cite commands and their variations (2.13.2), the generic
9402  graphicx figure commands (2.14.1), 
9403 \family typewriter
9404
9405 \backslash
9406 begin{table}
9407 \family default
9408  (2.15.4), 
9409 \family typewriter
9410
9411 \backslash
9412 begin{tabular}
9413 \family default
9414  (2.15.4), 
9415 \family typewriter
9416
9417 \backslash
9418 caption
9419 \family default
9420  (2.15.4), 
9421 \family typewriter
9422
9423 \backslash
9424 label
9425 \family default
9426  (2.15.4, amongst other places), 
9427 \family typewriter
9428
9429 \backslash
9430 tablerefs
9431 \family default
9432  (2.15.5), 
9433 \family typewriter
9434
9435 \backslash
9436 tablecomments
9437 \family default
9438  (2.15.5), 
9439 \family typewriter
9440
9441 \backslash
9442 url
9443 \family default
9444  (2.17.4), 
9445 \family typewriter
9446
9447 \backslash
9448 end{document}
9449 \family default
9450  (2.18).
9451 \end_layout
9452
9453 \begin_layout Standard
9454 The following style options also work correctly: 
9455 \family typewriter
9456 longabstract
9457 \family default
9458  (2.4), 
9459 \family typewriter
9460 preprint
9461 \family default
9462  (3.2.1), 
9463 \family typewriter
9464 preprint2
9465 \family default
9466  (3.2.2), 
9467 \family typewriter
9468 eqsecnum
9469 \family default
9470  (3.3), 
9471 \family typewriter
9472 flushrt
9473 \family default
9474  (3.4).
9475  Simply put them in the 
9476 \family sans
9477 Options
9478 \family default
9479  box in 
9480 \family sans
9481 Layout\SpecialChar menuseparator
9482 Document
9483 \family default
9484 .
9485 \end_layout
9486
9487 \begin_layout Subsubsection
9488 Things that work, but require more comment
9489 \end_layout
9490
9491 \begin_layout Standard
9492 The following items work, but require a little more discussion:
9493 \end_layout
9494
9495 \begin_layout Itemize
9496 These items are reserved for use by the journal editors, but you can put
9497  them into the \SpecialChar LaTeX
9498  preamble if you feel compelled to do so: 
9499 \family typewriter
9500
9501 \backslash
9502 received
9503 \family default
9504
9505 \family typewriter
9506
9507 \backslash
9508 revised
9509 \family default
9510
9511 \family typewriter
9512
9513 \backslash
9514 accepted
9515 \family default
9516
9517 \family typewriter
9518
9519 \backslash
9520 ccc
9521 \family default
9522
9523 \family typewriter
9524
9525 \backslash
9526 cpright
9527 \family default
9528  (all from 2.1.3)
9529 \end_layout
9530
9531 \begin_layout Itemize
9532 These items may be placed in the \SpecialChar LaTeX
9533  preamble, and are included as blanks in
9534  the template file: 
9535 \family typewriter
9536
9537 \backslash
9538 slugcomment
9539 \family default
9540  (2.1.4), 
9541 \family typewriter
9542
9543 \backslash
9544 shorttitle
9545 \family default
9546  (2.1.5), 
9547 \family typewriter
9548
9549 \backslash
9550 shortauthors
9551 \family default
9552  (2.1.5)
9553 \end_layout
9554
9555 \begin_layout Itemize
9556
9557 \family typewriter
9558
9559 \backslash
9560 email
9561 \family default
9562  (2.3) – can only be used 
9563 \begin_inset Quotes eld
9564 \end_inset
9565
9566 standalone
9567 \begin_inset Quotes erd
9568 \end_inset
9569
9570 , not in the middle of a paragraph.
9571  Use \SpecialChar TeX
9572  code if you need to embed it.
9573 \end_layout
9574
9575 \begin_layout Itemize
9576
9577 \family typewriter
9578
9579 \backslash
9580 and
9581 \family default
9582  (2.3) – will have extra {} after it.
9583  This should not cause an error.
9584 \end_layout
9585
9586 \begin_layout Itemize
9587
9588 \family typewriter
9589
9590 \backslash
9591 notetoeditor
9592 \family default
9593  (2.6) – can only be used 
9594 \begin_inset Quotes eld
9595 \end_inset
9596
9597 standalone
9598 \begin_inset Quotes erd
9599 \end_inset
9600
9601 , not in the middle of a paragraph.
9602  Use \SpecialChar TeX
9603  code if you need to embed it.
9604 \end_layout
9605
9606 \begin_layout Itemize
9607
9608 \family typewriter
9609
9610 \backslash
9611 placetable
9612 \family default
9613  (2.8) – can't insert a cross-reference tag, you must type the tag name by
9614  hand
9615 \end_layout
9616
9617 \begin_layout Itemize
9618
9619 \family typewriter
9620
9621 \backslash
9622 placefigure
9623 \family default
9624  (2.8) – same as for 
9625 \family typewriter
9626
9627 \backslash
9628 placetable
9629 \end_layout
9630
9631 \begin_layout Itemize
9632
9633 \family typewriter
9634
9635 \backslash
9636 acknowledgements
9637 \family default
9638  (2.9) – will have extra {} after it.
9639  This should not cause an error.
9640 \end_layout
9641
9642 \begin_layout Itemize
9643
9644 \family typewriter
9645
9646 \backslash
9647 appendix
9648 \family default
9649  (2.11) – will have extra {} after it.
9650  This should not cause an error.
9651 \end_layout
9652
9653 \begin_layout Itemize
9654
9655 \family typewriter
9656
9657 \backslash
9658 figcaption
9659 \family default
9660  (2.14.2) – you can insert an optional filename argument by placing the cursor
9661  at the beginning of the text and selecting 
9662 \family sans
9663 Insert\SpecialChar menuseparator
9664 Short Title
9665 \family default
9666 .
9667  
9668 \begin_inset Quotes eld
9669 \end_inset
9670
9671 Short Title
9672 \begin_inset Quotes erd
9673 \end_inset
9674
9675  inserts an optional argument of the type needed by 
9676 \family typewriter
9677
9678 \backslash
9679 figcaption
9680 \family default
9681 .
9682  Hopefully it will be renamed someday.
9683 \end_layout
9684
9685 \begin_layout Itemize
9686
9687 \family typewriter
9688
9689 \backslash
9690 objectname
9691 \family default
9692  (2.17.1) – same as 
9693 \family typewriter
9694
9695 \backslash
9696 figcaption
9697 \family default
9698  for the catalog ID optional parameter
9699 \end_layout
9700
9701 \begin_layout Itemize
9702
9703 \family typewriter
9704
9705 \backslash
9706 dataset
9707 \family default
9708  (2.17.1) – same as 
9709 \family typewriter
9710
9711 \backslash
9712 figcaption
9713 \family default
9714  for the catalog ID optional parameter
9715 \end_layout
9716
9717 \begin_layout Subsubsection
9718 Things not implemented, use \SpecialChar TeX
9719  code
9720 \end_layout
9721
9722 \begin_layout Standard
9723
9724 \change_deleted -712698321 1501152401
9725
9726 \family typewriter
9727
9728 \backslash
9729 altaffilmark
9730 \family default
9731  (2.3), 
9732 \family typewriter
9733
9734 \backslash
9735 altaffiltext
9736 \family default
9737  (2.3), 
9738 \change_unchanged
9739
9740 \family typewriter
9741
9742 \backslash
9743 eqnum
9744 \family default
9745  (2.12), 
9746 \family typewriter
9747
9748 \backslash
9749 setcounter{equation}
9750 \family default
9751  (2.12), Journal name abbreviations (2.13.4), 
9752 \family typewriter
9753
9754 \backslash
9755 figurenum
9756 \family default
9757  (2.14.1), 
9758 \family typewriter
9759
9760 \backslash
9761 epsscale
9762 \family default
9763  (2.14.1), 
9764 \family typewriter
9765
9766 \backslash
9767 plotone
9768 \family default
9769  (2.14.1), 
9770 \family typewriter
9771
9772 \backslash
9773 plottwo
9774 \family default
9775  (2.14.1), 
9776 \family typewriter
9777
9778 \backslash
9779 tablenum
9780 \family default
9781  (2.15.4), 
9782 \family typewriter
9783
9784 \backslash
9785 tableline
9786 \family default
9787  (2.15.4, insert it as the first element in the lefthand cell after where
9788  you want it.
9789  Don't use any of \SpecialChar LyX
9790 's rules in the table), 
9791 \family typewriter
9792
9793 \backslash
9794 tablenotemark
9795 \family default
9796  (2.15.5), 
9797 \family typewriter
9798
9799 \backslash
9800 tablenotetext
9801 \family default
9802  (2.15.5), much of Misc (2.17, except 
9803 \family typewriter
9804
9805 \backslash
9806 objectname
9807 \family default
9808
9809 \family typewriter
9810
9811 \backslash
9812 dataset
9813 \family default
9814
9815 \family typewriter
9816
9817 \backslash
9818 url
9819 \family default
9820 , and 
9821 \family typewriter
9822
9823 \backslash
9824 email
9825 \family default
9826 ; see above), 
9827 \family typewriter
9828
9829 \backslash
9830 singlespace
9831 \family default
9832  (3.1), 
9833 \family typewriter
9834
9835 \backslash
9836 doublespace
9837 \family default
9838  (3.1), 
9839 \family typewriter
9840
9841 \backslash
9842 onecolumn
9843 \family default
9844  (3.2), 
9845 \family typewriter
9846
9847 \backslash
9848 twocolumn
9849 \family default
9850  (3.2)
9851 \end_layout
9852
9853 \begin_layout Subsubsection
9854 Things that cannot be implemented
9855 \end_layout
9856
9857 \begin_layout Standard
9858 \SpecialChar ldots
9859  at least in any meaningful sort of way, so I suggest ignoring them.
9860  They are the references environment (2.13.3), and the deluxetable environment
9861  (2.15).
9862  If you really, really need to use deluxetable, I suggest editing it in
9863  a separate file with a text editor, then using 
9864 \family sans
9865 Insert\SpecialChar menuseparator
9866 Child
9867 \begin_inset space ~
9868 \end_inset
9869
9870 Document
9871 \family default
9872  to include it in your \SpecialChar LyX
9873  document.
9874  See the 
9875 \family typewriter
9876 aas_sample.lyx
9877 \family default
9878  file to see an example of this.
9879 \end_layout
9880
9881 \begin_layout Subsection
9882 FAQs, Tips, Tricks, and Other Ruminations
9883 \end_layout
9884
9885 \begin_layout Subsubsection
9886 Getting \SpecialChar LyX
9887  and AAS\SpecialChar TeX
9888  to cooperate
9889 \end_layout
9890
9891 \begin_layout Standard
9892 It can be a bit tricky to get \SpecialChar LyX
9893  to recognize a new layout and document class.
9894  When all else fails, do this:
9895 \end_layout
9896
9897 \begin_layout Enumerate
9898 Make certain that \SpecialChar LaTeX
9899  can find AAS\SpecialChar TeX
9900 .
9901  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
9902  distribution into a
9903  directory completely unrelated to \SpecialChar LaTeX
9904  or AAS\SpecialChar TeX
9905  and run \SpecialChar LaTeX
9906  on 
9907 \family typewriter
9908 sample.tex
9909 \family default
9910 .
9911 \end_layout
9912
9913 \begin_layout Enumerate
9914 Make certain that 
9915 \family typewriter
9916 aastex.layout
9917 \family default
9918  appears in \SpecialChar LyX
9919 's 
9920 \family typewriter
9921 layouts
9922 \family default
9923  folder
9924 \end_layout
9925
9926 \begin_layout Enumerate
9927 Rerun 
9928 \family sans
9929 Tools\SpecialChar menuseparator
9930 Reconfigure
9931 \family default
9932  in \SpecialChar LyX
9933 , then restart \SpecialChar LyX
9934 .
9935 \end_layout
9936
9937 \begin_layout Enumerate
9938 Open a regular new file, not from a template.
9939  Does AAS\SpecialChar TeX
9940  appear in the class list in 
9941 \family sans
9942 Document\SpecialChar menuseparator
9943 Settings
9944 \family default
9945 ?
9946 \end_layout
9947
9948 \begin_layout Standard
9949 If you get a warning from an existing AAS\SpecialChar TeX
9950  document about not being able
9951  to find the AAS\SpecialChar TeX
9952  layout or a message about 
9953 \begin_inset Quotes eld
9954 \end_inset
9955
9956 You should not mix title layouts with normal ones
9957 \begin_inset Quotes erd
9958 \end_inset
9959
9960 , things haven't been installed correctly.
9961 \end_layout
9962
9963 \begin_layout Subsubsection
9964 \SpecialChar LaTeX
9965  error processing a table 
9966 \end_layout
9967
9968 \begin_layout Standard
9969 \SpecialChar LyX
9970 , by default, attempts to center the table caption/title.
9971  This seems to produce a bad interaction in AAS\SpecialChar TeX
9972  so you should click somewhere
9973  in the caption/title, then select 
9974 \family sans
9975 Edit\SpecialChar menuseparator
9976 Paragraph
9977 \begin_inset space ~
9978 \end_inset
9979
9980 Settings
9981 \family default
9982 , then set the 
9983 \family sans
9984 Alignment
9985 \family default
9986  to 
9987 \family sans
9988 Block
9989 \family default
9990 .
9991  This took care of it for me.
9992 \end_layout
9993
9994 \begin_layout Subsubsection
9995 References
9996 \end_layout
9997
9998 \begin_layout Standard
9999 A couple of things: 1) I have noticed some funny spacing in the reference
10000  entries in the text.
10001  When you enter the bibliography item data, make sure their is 
10002 \emph on
10003 no
10004 \emph default
10005  space between the last author and the parenthesis setting off the year;
10006  
10007 \emph on
10008 e.
10009 \begin_inset space \thinspace{}
10010 \end_inset
10011
10012 g.
10013 \begin_inset space \space{}
10014 \end_inset
10015
10016
10017 \emph default
10018 type 
10019 \family typewriter
10020 Ressler(1992)
10021 \family default
10022 , not 
10023 \family typewriter
10024 Ressler (1992)
10025 \family default
10026 .
10027  2) Entering the references at all is not obvious.
10028  The easiest thing is to start typing your first reference at the end of
10029  the document, then mark it as type 
10030 \family sans
10031 References
10032 \family default
10033 .
10034  That will put a small gray box in front of what you just typed.
10035  Click on the box to fill in the rest of the information.
10036  For new references, go to the end of an existing reference and press return.
10037  That will create a new line with its own box, etc.
10038 \end_layout
10039
10040 \begin_layout Subsubsection
10041 Including EPS files
10042 \end_layout
10043
10044 \begin_layout Standard
10045 Even though AAS\SpecialChar TeX
10046  provides its own figure commands (
10047 \family typewriter
10048
10049 \backslash
10050 plotone
10051 \family default
10052 , for example), I much prefer \SpecialChar LaTeX
10053 's standard figure commands (with the default
10054  graphicx).
10055  You can insert the 
10056 \family typewriter
10057
10058 \backslash
10059 plotone
10060 \family default
10061 , etc.
10062 \begin_inset space ~
10063 \end_inset
10064
10065 commands as \SpecialChar TeX
10066  code into a Figure Float box if you desire, but I never have
10067  much luck getting the layout right.
10068  With the standard graphics, \SpecialChar LyX
10069  will insert a 
10070 \family typewriter
10071
10072 \backslash
10073 usepackage{graphicx}
10074 \family default
10075  command into the \SpecialChar LaTeX
10076  preamble and handle the figures in the standard \SpecialChar LaTeX2e
10077  way,
10078  interspersing the figures in the text.
10079  I believe ApJ accepts figures exactly this way now; AJ might still use
10080  the 
10081 \begin_inset Quotes eld
10082 \end_inset
10083
10084 stack everything at the end
10085 \begin_inset Quotes erd
10086 \end_inset
10087
10088  technique.
10089 \end_layout
10090
10091 \begin_layout Subsubsection
10092 Things I could have done, but didn't
10093 \end_layout
10094
10095 \begin_layout Standard
10096 There are a few 
10097 \begin_inset Quotes eld
10098 \end_inset
10099
10100 pretty
10101 \begin_inset Quotes erd
10102 \end_inset
10103
10104  things I could have implemented, but chose not to.
10105  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
10106  window,
10107  even though it is double-spaced in the paper manuscript.
10108  Also, I chose not to make separate layouts for the preprint and preprint2
10109  styles.
10110  Since I assume you will spend most of your time in the plain manuscript
10111  mode anyway, I decided not to chew up more disk space with this.
10112  
10113 \end_layout
10114
10115 \begin_layout Subsection
10116 Final Caveat
10117 \end_layout
10118
10119 \begin_layout Standard
10120 Your mileage may vary.
10121  I've now had papers published by both ApJ and AJ that have had 98% of the
10122  effort done in \SpecialChar LyX
10123 ; the last 2% was the \SpecialChar LaTeX
10124  post-processing and a few cleanups.
10125  I have had no trouble with the submission process, and I'm sure the journals
10126  were never aware that there might be a difference.
10127  So, go forth and publish!
10128 \end_layout
10129
10130 \begin_layout Section
10131 AMS \SpecialChar LaTeX
10132
10133 \end_layout
10134
10135 \begin_layout Standard
10136 by 
10137 \noun on
10138 David Johnson
10139 \noun default
10140 ; updated by 
10141 \noun on
10142 Richard Heck
10143 \end_layout
10144
10145 \begin_layout Standard
10146 \begin_inset VSpace bigskip
10147 \end_inset
10148
10149
10150 \end_layout
10151
10152 \begin_layout Standard
10153 \noindent
10154 The AMS \SpecialChar LaTeX
10155  layouts are set up to conform to suggested styles for mathematical
10156  papers to be submitted to American Mathematical Society publications.
10157  The layouts are not tailored to a specific journal, but easily can be.
10158  You should refer to the AMS documentation for specific instructions for
10159  each journal (usually it will entail only changing a single line in the
10160  \SpecialChar TeX
10161  output).
10162  That documentation is available on the Web at 
10163 \begin_inset Flex URL
10164 status open
10165
10166 \begin_layout Plain Layout
10167
10168 http://www.ams.org
10169 \end_layout
10170
10171 \end_inset
10172
10173  or by ftp at 
10174 \begin_inset Flex URL
10175 status open
10176
10177 \begin_layout Plain Layout
10178
10179 ftp://ftp.ams.org/pub/tex/amslatex/
10180 \end_layout
10181
10182 \end_inset
10183
10184 .
10185  These layouts are appropriate, and useful, for any mathematical writing.
10186  
10187 \end_layout
10188
10189 \begin_layout Standard
10190 There are two basic AMS \SpecialChar LaTeX
10191  layouts: 
10192 \end_layout
10193
10194 \begin_layout Itemize
10195 amsart: The standard AMS article format.
10196 \end_layout
10197
10198 \begin_layout Itemize
10199 amsbook: the standard AMS book (really, monograph) format.
10200  
10201 \end_layout
10202
10203 \begin_layout Standard
10204 The layouts themselves contain only the minimum necessary to use the AMS
10205  classes.
10206  They do not, in particular, contain any of the `theorem' environments used
10207  for setting theorems, lemmas, and the like.
10208  These are contained, instead, in the 
10209 \begin_inset Flex Code
10210 status collapsed
10211
10212 \begin_layout Plain Layout
10213 Theorems (AMS)
10214 \end_layout
10215
10216 \end_inset
10217
10218  module, which is loaded by default when you select one of the AMS classes.
10219  (It can also be used with other classes and can be removed, if you would
10220  rather use something else.) Less commonly used environments are in the 
10221 \begin_inset Flex Code
10222 status collapsed
10223
10224 \begin_layout Plain Layout
10225 Theorems (AMS-Extended)
10226 \end_layout
10227
10228 \end_inset
10229
10230  module, which must be loaded manually.
10231 \end_layout
10232
10233 \begin_layout Standard
10234 By default, theorems and the like are numbered consecutively throughout
10235  the document, but this may be modified by loading the module 
10236 \begin_inset Flex Code
10237 status collapsed
10238
10239 \begin_layout Plain Layout
10240 Theorems (Order by Section)
10241 \end_layout
10242
10243 \end_inset
10244
10245  or, if you are using 
10246 \begin_inset Flex Code
10247 status collapsed
10248
10249 \begin_layout Plain Layout
10250 book (AMS)
10251 \end_layout
10252
10253 \end_inset
10254
10255 , the module 
10256 \begin_inset Flex Code
10257 status collapsed
10258
10259 \begin_layout Plain Layout
10260 Theorems (Order by Chapter)
10261 \end_layout
10262
10263 \end_inset
10264
10265 .
10266  These will number the results as 
10267 \begin_inset Formula $n.m$
10268 \end_inset
10269
10270 , where the first number refers to the section (or chapter) and the second
10271  refers to the total number of results so far in that section (or chapter).
10272  Many environments are also available unnumbered.
10273  These are indicated by an asterisk at the end.
10274  If you happen to want 
10275 \emph on
10276 only
10277 \emph default
10278  unnumbered results, the module 
10279 \begin_inset Flex Code
10280 status collapsed
10281
10282 \begin_layout Plain Layout
10283 Theorems (Starred)
10284 \end_layout
10285
10286 \end_inset
10287
10288  provides that option.
10289 \end_layout
10290
10291 \begin_layout Standard
10292 Note that these modules do not 
10293 \emph on
10294 have
10295 \emph default
10296  to be used with the AMS classes.
10297  It is perfectly possible to use the 
10298 \begin_inset Flex Code
10299 status collapsed
10300
10301 \begin_layout Plain Layout
10302 Theorems (AMS)
10303 \end_layout
10304
10305 \end_inset
10306
10307  module, and the others mentioned, with other classes, such as 
10308 \begin_inset Flex Code
10309 status collapsed
10310
10311 \begin_layout Plain Layout
10312 article
10313 \end_layout
10314
10315 \end_inset
10316
10317
10318 \begin_inset Flex Code
10319 status collapsed
10320
10321 \begin_layout Plain Layout
10322 report
10323 \end_layout
10324
10325 \end_inset
10326
10327
10328 \begin_inset Flex Code
10329 status collapsed
10330
10331 \begin_layout Plain Layout
10332 book (KOMA-script)
10333 \end_layout
10334
10335 \end_inset
10336
10337 , and so forth.
10338 \end_layout
10339
10340 \begin_layout Subsection
10341 What these layouts provide
10342 \end_layout
10343
10344 \begin_layout Standard
10345 There is a long list of included environments provided by these layouts.
10346  In AMS-\SpecialChar LaTeX
10347 , there is, in fact, an opportunity to define an unlimited variety
10348  of `theorem' environments.
10349  However, the AMS recommends the environments that are available in \SpecialChar LyX
10350 .
10351  
10352 \end_layout
10353
10354 \begin_layout Standard
10355 The following environments—as well as the standard environments, such as
10356  
10357 \begin_inset Flex Noun
10358 status collapsed
10359
10360 \begin_layout Plain Layout
10361 section
10362 \end_layout
10363
10364 \end_inset
10365
10366
10367 \begin_inset Flex Noun
10368 status collapsed
10369
10370 \begin_layout Plain Layout
10371 bibliography
10372 \end_layout
10373
10374 \end_inset
10375
10376
10377 \begin_inset Flex Noun
10378 status collapsed
10379
10380 \begin_layout Plain Layout
10381 title
10382 \end_layout
10383
10384 \end_inset
10385
10386
10387 \begin_inset Flex Noun
10388 status collapsed
10389
10390 \begin_layout Plain Layout
10391 author
10392 \end_layout
10393
10394 \end_inset
10395
10396 , and 
10397 \begin_inset Flex Noun
10398 status collapsed
10399
10400 \begin_layout Plain Layout
10401 date
10402 \end_layout
10403
10404 \end_inset
10405
10406 —are provided by 
10407 \begin_inset Flex Code
10408 status collapsed
10409
10410 \begin_layout Plain Layout
10411 article (AMS)
10412 \end_layout
10413
10414 \end_inset
10415
10416  and 
10417 \begin_inset Flex Code
10418 status collapsed
10419
10420 \begin_layout Plain Layout
10421 book (AMS)
10422 \end_layout
10423
10424 \end_inset
10425
10426 :
10427 \end_layout
10428
10429 \begin_layout Description
10430 Address This should be the author's permanent address.
10431 \end_layout
10432
10433 \begin_layout Description
10434 Current
10435 \begin_inset space ~
10436 \end_inset
10437
10438 Address This should be the author's temporary address at the time of submission,
10439  if different from the Address.
10440 \end_layout
10441
10442 \begin_layout Description
10443 Email Author's e-mail address
10444 \end_layout
10445
10446 \begin_layout Description
10447 URL Author's Web address, if desired.
10448 \end_layout
10449
10450 \begin_layout Description
10451 Keywords Key words or phrases used to identify specific topics discussed
10452  in the paper.
10453 \end_layout
10454
10455 \begin_layout Description
10456 Subjectclass These refer to the AMS Subject Classifications, published and
10457  described in 
10458 \emph on
10459 Mathematical Reviews
10460 \emph default
10461 .
10462  These are also available online at the AMS cites listed above.
10463 \end_layout
10464
10465 \begin_layout Description
10466 Thanks
10467 \end_layout
10468
10469 \begin_layout Description
10470 Dedicatory
10471 \end_layout
10472
10473 \begin_layout Description
10474 Translator
10475 \end_layout
10476
10477 \begin_layout Standard
10478 The following environments are provided by both the 
10479 \begin_inset Flex Code
10480 status collapsed
10481
10482 \begin_layout Plain Layout
10483 Theorems
10484 \end_layout
10485
10486 \end_inset
10487
10488  and 
10489 \begin_inset Flex Code
10490 status collapsed
10491
10492 \begin_layout Plain Layout
10493 Theorems (AMS)
10494 \end_layout
10495
10496 \end_inset
10497
10498  modules, in the latter case in both starred (unnumbered) and unstarred
10499  (numbered) versions.
10500  These same environments are provided only in the starred versions by the
10501  
10502 \begin_inset Flex Code
10503 status collapsed
10504
10505 \begin_layout Plain Layout
10506 Theorems (Starred)
10507 \end_layout
10508
10509 \end_inset
10510
10511  module:
10512 \end_layout
10513
10514 \begin_layout Theorem
10515 This is typically used for the statements of major results.
10516  
10517 \end_layout
10518
10519 \begin_layout Corollary*
10520 This is used for statements which follow fairly directly from previous statement
10521 s.
10522  Again, these can be major results.
10523  
10524 \end_layout
10525
10526 \begin_layout Lemma
10527 These are smaller results needed to prove other statements.
10528 \end_layout
10529
10530 \begin_layout Proposition
10531 These are less major results which (hopefully) add to the general theory
10532  being discussed.
10533 \end_layout
10534
10535 \begin_layout Conjecture
10536 These are statements provided without justification, which the author does
10537  not know how to prove, but which seem to be true (to the author, at least).
10538 \end_layout
10539
10540 \begin_layout Definition*
10541 Guess what this is for.
10542  The font is different for this environment than for the previous ones.
10543  
10544 \end_layout
10545
10546 \begin_layout Example*
10547 Used for examples illustrating proven results.
10548 \end_layout
10549
10550 \begin_layout Problem
10551 It's not really known what this is for.
10552  You should figure it out.
10553 \end_layout
10554
10555 \begin_layout Exercise*
10556 Write a description for this one.
10557 \end_layout
10558
10559 \begin_layout Remark
10560 This environment is also a type of theorem, usually a lesser sort of observation.
10561 \end_layout
10562
10563 \begin_layout Claim*
10564 Often used in the course of giving a proof of a larger result.
10565 \end_layout
10566
10567 \begin_layout Case
10568 Generally, these are used to break up long arguments, using specific instances
10569  of some condition.
10570  
10571 \end_layout
10572
10573 \begin_layout Case
10574 The numbering scheme for cases is on its own, not together with other numbered
10575  statements.
10576  
10577 \end_layout
10578
10579 \begin_layout Proof
10580 At the end of this environment, a QED symbol (usually a square, but it can
10581  vary with different styles) is placed.
10582  If you want to have other environments within this one—for example, Case
10583  environments—and have the QED symbol appear only after them, then the other
10584  environments need to be nested within the proof environment.
10585  See the section 
10586 \emph on
10587 Nesting Environments
10588 \emph default
10589  of the 
10590 \emph on
10591 User's Guide
10592 \emph default
10593  for information on nesting.
10594 \end_layout
10595
10596 \begin_layout Standard
10597 And these environments are provided by 
10598 \begin_inset Flex Code
10599 status collapsed
10600
10601 \begin_layout Plain Layout
10602 Theorems (AMS-Extended)
10603 \end_layout
10604
10605 \end_inset
10606
10607 :
10608 \end_layout
10609
10610 \begin_layout Criterion*
10611 A required condition.
10612 \end_layout
10613
10614 \begin_layout Algorithm*
10615 A general procedure to be used.
10616 \end_layout
10617
10618 \begin_layout Axiom*
10619 This is a property or statement taken as true within the system being discussed.
10620 \end_layout
10621
10622 \begin_layout Condition*
10623 Sometimes used to state a condition assumed within the present context of
10624  discussion.
10625 \end_layout
10626
10627 \begin_layout Note*
10628 Similar to a Remark.
10629 \end_layout
10630
10631 \begin_layout Notation*
10632 Used for the explanation of, yes, notation.
10633 \end_layout
10634
10635 \begin_layout Summary
10636 Do we really need to tell you? 
10637 \end_layout
10638
10639 \begin_layout Acknowledgement*
10640 Acknowledgement.
10641 \end_layout
10642
10643 \begin_layout Conclusion*
10644 Sometimes used at the end of a long train of argument.
10645 \end_layout
10646
10647 \begin_layout Fact
10648 Used in a way similar to Proposition, though perhaps lower on the scale.
10649 \end_layout
10650
10651 \begin_layout Standard
10652 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
10653  and AMS fonts
10654  packages.
10655  They need to be available on your system in order to use these environments.
10656 \end_layout
10657
10658 \begin_layout Section
10659 AGU journals (
10660 \family sans
10661 aguplus
10662 \family default
10663 )
10664 \end_layout
10665
10666 \begin_layout Standard
10667 by 
10668 \shape smallcaps
10669 Martin Vermeer
10670 \end_layout
10671
10672 \begin_layout Subsection
10673 Description
10674 \end_layout
10675
10676 \begin_layout Standard
10677 These are the layout files for some of the journals of the American Geophysical
10678  Society.
10679  It is assumed that you have both the AGU's own class files and AGUplus
10680  installed (everything to be found at
10681 \begin_inset Flex URL
10682 status collapsed
10683
10684 \begin_layout Plain Layout
10685
10686 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
10687 \end_layout
10688
10689 \end_inset
10690
10691 ).
10692 \end_layout
10693
10694 \begin_layout Subsection
10695 New styles
10696 \end_layout
10697
10698 \begin_layout Standard
10699 Redefined are 
10700 \family sans
10701 Paragraph
10702 \family default
10703
10704 \family sans
10705 Paragraph*
10706 \family default
10707 .
10708  They are still called this in the \SpecialChar LyX
10709  GUI, though their \SpecialChar LaTeX
10710  equivalents in the
10711  AGU classes are 
10712 \family sans
10713 Subsubsubsection
10714 \family default
10715  and 
10716 \family sans
10717 Subsubsubsection*
10718 \family default
10719 .
10720 \end_layout
10721
10722 \begin_layout Standard
10723 Newly defined styles are 
10724 \family sans
10725 Left_Header
10726 \family default
10727
10728 \family sans
10729 Right_Header
10730 \family default
10731
10732 \family sans
10733 Received
10734 \family default
10735
10736 \family sans
10737 Revised
10738 \family default
10739
10740 \family sans
10741 Accepted
10742 \family default
10743
10744 \family sans
10745 CCC
10746 \family default
10747
10748 \family sans
10749 PaperId
10750 \family default
10751
10752 \family sans
10753 AuthorAddr
10754 \family default
10755
10756 \family sans
10757 SlugComment
10758 \family default
10759 .
10760  These are mostly manuscript attributes and defined in the AGU class documentati
10761 on.
10762 \end_layout
10763
10764 \begin_layout Standard
10765 I suspect this is still badly incomplete.
10766 \end_layout
10767
10768 \begin_layout Subsection
10769 New floats
10770 \end_layout
10771
10772 \begin_layout Standard
10773
10774 \family sans
10775 Planotable
10776 \family default
10777  and 
10778 \family sans
10779 Plate
10780 \family default
10781 .
10782  We also have a new 
10783 \family sans
10784 Table_Caption
10785 \family default
10786 .
10787 \end_layout
10788
10789 \begin_layout Subsection
10790 Supported journals
10791 \end_layout
10792
10793 \begin_layout Itemize
10794
10795 \emph on
10796 Journal of Geophysical Research
10797 \emph default
10798
10799 \family typewriter
10800 jgrga.layout
10801 \family default
10802  — Martin Vermeer
10803 \end_layout
10804
10805 \begin_layout Standard
10806 Add your own, it isn't so hard! Look at the 
10807 \family typewriter
10808 jgrga.layout
10809 \family default
10810  example and 
10811 \family typewriter
10812 aguplus.inc
10813 \family default
10814 .
10815 \end_layout
10816
10817 \begin_layout Subsection
10818 Bugs and things to remember
10819 \end_layout
10820
10821 \begin_layout Standard
10822 In order to use the new layouts, you must remember to do the following for
10823  a new document:
10824 \end_layout
10825
10826 \begin_layout Enumerate
10827
10828 \emph on
10829 Turn off babel
10830 \emph default
10831 .
10832  This can be done in the 
10833 \family sans
10834 Layout\SpecialChar menuseparator
10835 Document
10836 \family default
10837  or 
10838 \family sans
10839 Document\SpecialChar menuseparator
10840 Settings
10841 \family default
10842  menu item.
10843  (AGU articles are always in English, right? So 
10844 \emph on
10845 don't
10846 \emph default
10847  choose a language.)
10848 \end_layout
10849
10850 \begin_layout Enumerate
10851 Enter 
10852 \family typewriter
10853 jgrga
10854 \family default
10855  into the document's 
10856 \family sans
10857 Extra Options
10858 \family default
10859  field.
10860  (Yes, this is a bug.)
10861 \end_layout
10862
10863 \begin_layout Enumerate
10864 Make sure you use the 
10865 \family typewriter
10866 agu.bst
10867 \family default
10868  bibliography style, by entering 
10869 \family sans
10870 agu
10871 \family default
10872  into the second field of the Bib\SpecialChar TeX
10873  inset.
10874  None of the standard styles will do.
10875 \end_layout
10876
10877 \begin_layout Section
10878 Broadway
10879 \end_layout
10880
10881 \begin_layout Standard
10882 by 
10883 \shape smallcaps
10884 Garst Reese
10885 \end_layout
10886
10887 \begin_layout Subsection
10888 Introduction
10889 \end_layout
10890
10891 \begin_layout Standard
10892 Broadway is for writing plays.
10893  The format is more decorative than Hollywood, and much less standardized.
10894  This format should be suitable for workshops.
10895 \end_layout
10896
10897 \begin_layout Subsection
10898 Special problems
10899 \end_layout
10900
10901 \begin_layout Standard
10902 The same as in Hollywood.
10903 \end_layout
10904
10905 \begin_layout Subsection
10906 Special features
10907 \end_layout
10908
10909 \begin_layout Standard
10910 Insert the 
10911 \family sans
10912 Speaker
10913 \family default
10914  names as labels then cross-reference the label to insert the name.
10915  The cross-reference dialog will show the current cast of characters.
10916 \end_layout
10917
10918 \begin_layout Subsection
10919 Paper size and Margins
10920 \end_layout
10921
10922 \begin_layout Standard
10923 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10924 \end_layout
10925
10926 \begin_layout Subsection
10927 Environments
10928 \end_layout
10929
10930 \begin_layout Standard
10931 The following environments are available.
10932  You can use broadway.bind to get the bind keys shown at the right.
10933 \end_layout
10934
10935 \begin_layout Itemize
10936
10937 \family sans
10938 Standard
10939 \begin_inset Newline newline
10940 \end_inset
10941
10942
10943 \family default
10944 You should not have to use this, but it is here for anything that does not
10945  fit otherwise.
10946 \end_layout
10947
10948 \begin_layout Itemize
10949
10950 \family sans
10951 Narrative
10952 \begin_inset space \hfill{}
10953 \end_inset
10954
10955 M-z n
10956 \begin_inset Newline newline
10957 \end_inset
10958
10959
10960 \family default
10961 Used to describe stage setting and the action.
10962  First use of speaker names in all CAPs.
10963 \end_layout
10964
10965 \begin_layout Itemize
10966
10967 \family sans
10968 ACT
10969 \begin_inset space \hfill{}
10970 \end_inset
10971
10972 M-z a
10973 \begin_inset Newline newline
10974 \end_inset
10975
10976
10977 \family default
10978 Automatically numbered.
10979  On screen it will be arabic, but will print as Roman.
10980 \end_layout
10981
10982 \begin_layout Itemize
10983
10984 \family sans
10985 ACT*
10986 \begin_inset space \hfill{}
10987 \end_inset
10988
10989 M-z S at
10990 \begin_inset Newline newline
10991 \end_inset
10992
10993
10994 \family default
10995 Subtitle for 
10996 \family sans
10997 ACT.
10998
10999 \family default
11000  It is just centered text.
11001 \end_layout
11002
11003 \begin_layout Itemize
11004
11005 \family sans
11006 SCENE
11007 \begin_inset space \hfill{}
11008 \end_inset
11009
11010 M-z S-S
11011 \begin_inset Newline newline
11012 \end_inset
11013
11014
11015 \family default
11016 Not automatically numbered.
11017  You supply the number.
11018  This is because I couldn't figure out how.
11019 \end_layout
11020
11021 \begin_layout Itemize
11022
11023 \family sans
11024 AT_RISE:
11025 \begin_inset space \hfill{}
11026 \end_inset
11027
11028 M-z S-R
11029 \begin_inset Newline newline
11030 \end_inset
11031
11032
11033 \family default
11034 A special case of Narrative to describe the setting and action as the curtain
11035  rises.
11036 \end_layout
11037
11038 \begin_layout Itemize
11039
11040 \family sans
11041 Speaker
11042 \begin_inset space \hfill{}
11043 \end_inset
11044
11045 M-z s
11046 \begin_inset Newline newline
11047 \end_inset
11048
11049
11050 \family default
11051 The speaker's (actor's) title, centered in all CAPS.
11052 \end_layout
11053
11054 \begin_layout Itemize
11055
11056 \family sans
11057 Parenthetical
11058 \begin_inset space \hfill{}
11059 \end_inset
11060
11061 M-z p
11062 \begin_inset Newline newline
11063 \end_inset
11064
11065
11066 \family default
11067 Instructions to the speaker.
11068  The parentheses are automatically inserted.
11069  The ( will appear on screen, but both will be in the printed play.
11070  This environment is only used within 
11071 \family sans
11072 Dialogue
11073 \family default
11074 .
11075 \end_layout
11076
11077 \begin_layout Itemize
11078
11079 \family sans
11080 Dialogue
11081 \begin_inset space \hfill{}
11082 \end_inset
11083
11084 M-z d
11085 \begin_inset Newline newline
11086 \end_inset
11087
11088
11089 \family default
11090 What the Speaker says.
11091 \end_layout
11092
11093 \begin_layout Itemize
11094
11095 \family sans
11096 CURTAIN
11097 \begin_inset space \hfill{}
11098 \end_inset
11099
11100 M-z S-C
11101 \begin_inset Newline newline
11102 \end_inset
11103
11104
11105 \family default
11106 The curtain comes down.
11107 \end_layout
11108
11109 \begin_layout Itemize
11110
11111 \family sans
11112 Title
11113 \begin_inset space \hfill{}
11114 \end_inset
11115
11116 M-z S-T
11117 \end_layout
11118
11119 \begin_layout Itemize
11120
11121 \family sans
11122 Author
11123 \begin_inset space \hfill{}
11124 \end_inset
11125
11126 M-z S-A
11127 \end_layout
11128
11129 \begin_layout Itemize
11130
11131 \family sans
11132 Right_Address
11133 \begin_inset space \hfill{}
11134 \end_inset
11135
11136 M-z r
11137 \end_layout
11138
11139 \begin_layout Standard
11140 Hello there.
11141 \end_layout
11142
11143 \begin_layout Section
11144 Dinbrief
11145 \end_layout
11146
11147 \begin_layout Standard
11148 The document class 
11149 \family sans
11150 dinbrief
11151 \family default
11152  can be used to type letters according to German conventions.
11153  A template file is included in 
11154 \family typewriter
11155 .../lyx/share/templates
11156 \family default
11157  for you to use as a starting point.
11158 \end_layout
11159
11160 \begin_layout Section
11161 EGS journals (
11162 \family sans
11163 egs
11164 \family default
11165 )
11166 \end_layout
11167
11168 \begin_layout Standard
11169 by 
11170 \shape smallcaps
11171 Martin Vermeer
11172 \end_layout
11173
11174 \begin_layout Subsection
11175 Description
11176 \end_layout
11177
11178 \begin_layout Standard
11179 This is the layout file for the European Geophysical Society journals.
11180  The needed 
11181 \family typewriter
11182 egs.cls
11183 \family default
11184  can be downloaded from the web site of the EGS under 
11185 \begin_inset Flex URL
11186 status collapsed
11187
11188 \begin_layout Plain Layout
11189
11190 www.copernicus.org
11191 \end_layout
11192
11193 \end_inset
11194
11195 .
11196 \end_layout
11197
11198 \begin_layout Subsection
11199 New styles
11200 \end_layout
11201
11202 \begin_layout Standard
11203
11204 \family sans
11205 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
11206  Accepted
11207 \family default
11208
11209 \family sans
11210 Offsets
11211 \family default
11212 .
11213  The current layout file is unfortunately very unmodular and would benefit
11214  from using the various 
11215 \family typewriter
11216 std*.inc
11217 \family default
11218  file inclusions.
11219 \end_layout
11220
11221 \begin_layout Section
11222 Elsevier Journals
11223 \end_layout
11224
11225 \begin_layout Standard
11226 See the \SpecialChar LyX
11227  template file 
11228 \family typewriter
11229 elsarticle.lyx
11230 \family default
11231 .
11232  It contains all infos you need.
11233 \end_layout
11234
11235 \begin_layout Section
11236 Foils [aka 
11237 \family sans
11238 Foil\SpecialChar TeX
11239
11240 \family default
11241 ]
11242 \begin_inset CommandInset label
11243 LatexCommand label
11244 name "sec:foiltex"
11245
11246 \end_inset
11247
11248
11249 \end_layout
11250
11251 \begin_layout Standard
11252 by 
11253 \noun on
11254 Allan Rae
11255 \end_layout
11256
11257 \begin_layout Subsection
11258 Introduction
11259 \end_layout
11260
11261 \begin_layout Standard
11262 This section describes how to use \SpecialChar LyX
11263  to make slides for overhead projectors.
11264  There are two document classes that can do this: the default slides class
11265  and the 
11266 \family sans
11267 Foil\SpecialChar TeX
11268
11269 \family default
11270  slides class.
11271  This section documents the latter.
11272 \end_layout
11273
11274 \begin_layout Standard
11275 I'm going to say this again, nice and clear, so that there's no misunderstanding
11276 :
11277 \end_layout
11278
11279 \begin_layout Standard
11280 \begin_inset VSpace bigskip
11281 \end_inset
11282
11283
11284 \end_layout
11285
11286 \begin_layout Standard
11287 \align center
11288
11289 \size large
11290 This section documents the class 
11291 \begin_inset Quotes eld
11292 \end_inset
11293
11294
11295 \family sans
11296 FoilTeX
11297 \family default
11298
11299 \begin_inset Quotes erd
11300 \end_inset
11301
11302  
11303 \emph on
11304 only.
11305 \end_layout
11306
11307 \begin_layout Standard
11308 \begin_inset VSpace bigskip
11309 \end_inset
11310
11311
11312 \end_layout
11313
11314 \begin_layout Standard
11315 If you're looking for the documentation for 
11316 \begin_inset Quotes eld
11317 \end_inset
11318
11319
11320 \family sans
11321 slides (default)
11322 \family default
11323
11324 \begin_inset Quotes erd
11325 \end_inset
11326
11327 , check out section
11328 \begin_inset space ~
11329 \end_inset
11330
11331
11332 \begin_inset CommandInset ref
11333 LatexCommand ref
11334 reference "sec:slitex"
11335
11336 \end_inset
11337
11338 .
11339  If your machine doesn't have the 
11340 \family sans
11341 foils
11342 \family default
11343  class 
11344 \family sans
11345 FoilTeX
11346 \family default
11347  installed, you'll probably have to use the default 
11348 \family sans
11349 slides
11350 \family default
11351  class, which isn't quite as good as 
11352 \family sans
11353 foils.
11354 \end_layout
11355
11356 \begin_layout Standard
11357 The 
11358 \family sans
11359 foils
11360 \family default
11361  class is designed for use with version
11362 \begin_inset space ~
11363 \end_inset
11364
11365 2.1 of the 
11366 \family sans
11367 foils.cls
11368 \family default
11369  \SpecialChar LaTeX
11370  class file which is now an integral part of \SpecialChar LaTeX2e
11371 .
11372 \end_layout
11373
11374 \begin_layout Subsection
11375 Getting Started
11376 \end_layout
11377
11378 \begin_layout Standard
11379 Obviously, to use this document class, you need to select 
11380 \family sans
11381 FoilTeX
11382 \family default
11383  from the 
11384 \family sans
11385 Class
11386 \family default
11387  entry in the 
11388 \family sans
11389 Document
11390 \begin_inset space ~
11391 \end_inset
11392
11393 Layout
11394 \family default
11395  dialog.
11396  There are some settings in the 
11397 \family sans
11398 Document
11399 \begin_inset space ~
11400 \end_inset
11401
11402 Layout
11403 \family default
11404  dialog that you should know about that are specific to this class:
11405 \end_layout
11406
11407 \begin_layout Itemize
11408 Don't change the options 
11409 \family sans
11410 Sides
11411 \family default
11412  and 
11413 \family sans
11414 Columns
11415 \family default
11416  on the 
11417 \family sans
11418 Document
11419 \begin_inset space ~
11420 \end_inset
11421
11422 Layout
11423 \family default
11424  dialog.
11425  They're ignored by the 
11426 \family sans
11427 foils
11428 \family default
11429  class.
11430 \end_layout
11431
11432 \begin_layout Itemize
11433 The default font size is 20
11434 \begin_inset space \thinspace{}
11435 \end_inset
11436
11437 pt with the other options being 17
11438 \begin_inset space \thinspace{}
11439 \end_inset
11440
11441 pt, 25
11442 \begin_inset space \thinspace{}
11443 \end_inset
11444
11445 pt and 30
11446 \begin_inset space \thinspace{}
11447 \end_inset
11448
11449 pt.
11450 \end_layout
11451
11452 \begin_layout Itemize
11453 The default font is 
11454 \family sans
11455 sans
11456 \family default
11457  
11458 \family sans
11459 serif
11460 \family default
11461  but all math equations are still typeset in the usual roman font.
11462 \end_layout
11463
11464 \begin_layout Itemize
11465
11466 \family sans
11467 Foil\SpecialChar TeX
11468
11469 \family default
11470  supports A4 and Letter paper sizes as well as a special size for working
11471  with 35
11472 \begin_inset space \thinspace{}
11473 \end_inset
11474
11475 mm slides.
11476  It doesn't support A5, B5, legal or executive paper sizes.
11477 \end_layout
11478
11479 \begin_layout Itemize
11480 Don't bother changing the 
11481 \family sans
11482 Float Placement
11483 \family default
11484  settings because they are ignored anyway.
11485  All floats appear where they are defined in the text.
11486 \end_layout
11487
11488 \begin_layout Itemize
11489 The 
11490 \family sans
11491 Pagestyle
11492 \family default
11493  setting behaves a bit differently for this class.
11494  
11495 \family sans
11496 Foil\SpecialChar TeX
11497
11498 \family default
11499  provides extensive footer and header capabilities including a user-defined
11500  logo.
11501  See section
11502 \begin_inset space ~
11503 \end_inset
11504
11505
11506 \begin_inset CommandInset ref
11507 LatexCommand ref
11508 reference "sec:foilfoot"
11509
11510 \end_inset
11511
11512  for more details.
11513  The title page is treated differently to all other pages in the document
11514  and is 
11515 \emph on
11516 always
11517 \emph default
11518  unnumbered and 
11519 \emph on
11520 always
11521 \emph default
11522  has the logo centered at the bottom of the page (if one is defined).
11523  The possible page style choices and what they do are as follows:
11524 \end_layout
11525
11526 \begin_deeper
11527 \begin_layout Labeling
11528 \labelwidthstring MMMMMMM
11529
11530 \family sans
11531 \series bold
11532 empty
11533 \family default
11534 \series default
11535  The final output contains no page numbers, or other headers or footers
11536  (except footnotes of course).
11537  
11538 \end_layout
11539
11540 \begin_layout Labeling
11541 \labelwidthstring MMMMMMM
11542
11543 \family sans
11544 \series bold
11545 plain
11546 \family default
11547 \series default
11548  The final output contains page numbers centered at the bottom of the page.
11549  No other headings or footers (other than footnotes).
11550 \end_layout
11551
11552 \begin_layout Labeling
11553 \labelwidthstring MMMMMMM
11554
11555 \series bold
11556 foilheadings
11557 \series default
11558  Page numbers in lower right corner.
11559  Additional headers and footers are also shown.
11560  This is also the default.
11561 \end_layout
11562
11563 \begin_layout Labeling
11564 \labelwidthstring MMMMMMM
11565
11566 \series bold
11567 fancy
11568 \series default
11569  Gives you access to the 
11570 \family sans
11571 fancyheadings
11572 \family default
11573  package although its use with 
11574 \family sans
11575 Foil\SpecialChar TeX
11576
11577 \family default
11578  is discouraged by the writer of the 
11579 \family sans
11580 Foil\SpecialChar TeX
11581
11582 \family default
11583  package because of some potential page layout clashes.
11584 \end_layout
11585
11586 \end_deeper
11587 \begin_layout Subsubsection
11588 Extra Options
11589 \end_layout
11590
11591 \begin_layout Standard
11592 The following options may be used in the extra class options in the 
11593 \family sans
11594 Document\SpecialChar menuseparator
11595 Settings
11596 \family default
11597  dialog.
11598 \end_layout
11599
11600 \begin_layout Labeling
11601 \labelwidthstring MMMMMMx
11602
11603 \series bold
11604 35mmSlide
11605 \series default
11606  This sets up the page layout for 7.33
11607 \begin_inset space \thinspace{}
11608 \end_inset
11609
11610 in by 11
11611 \begin_inset space \thinspace{}
11612 \end_inset
11613
11614 in paper, which is about the same aspect ratio as a 35
11615 \begin_inset space \thinspace{}
11616 \end_inset
11617
11618 mm slide, making it a bit easier to work with this medium.
11619 \end_layout
11620
11621 \begin_layout Labeling
11622 \labelwidthstring MMMMMMx
11623
11624 \series bold
11625 headrule
11626 \series default
11627  Places a rule across the page below the header on every page except the
11628  title page.
11629 \end_layout
11630
11631 \begin_layout Labeling
11632 \labelwidthstring MMMMMMx
11633
11634 \series bold
11635 footrule
11636 \series default
11637  Places a rule across the page above the footer on every page except the
11638  title page.
11639 \end_layout
11640
11641 \begin_layout Labeling
11642 \labelwidthstring MMMMMMx
11643
11644 \series bold
11645 dvips
11646 \series default
11647  This is automatically set each time you create a new 
11648 \family sans
11649 foils
11650 \family default
11651  document.
11652  This option tells 
11653 \family sans
11654 Foil\SpecialChar TeX
11655
11656 \family default
11657  to use the dvips driver to rotate those pages that are set as landscape
11658  foils.
11659 \end_layout
11660
11661 \begin_layout Labeling
11662 \labelwidthstring MMMMMMx
11663
11664 \series bold
11665 landscape
11666 \series default
11667  Simply changes the page dimensions to those of a landscape page but doesn't
11668  do any rotation.
11669  Thus if you use this option you need to use an external program to rotate
11670  each page or feed your paper through your printer as landscape.
11671  Note that this option effectively reverses the roles of the 
11672 \family sans
11673 Foilhead
11674 \family default
11675  and 
11676 \family sans
11677 Rotatefoilhead
11678 \family default
11679  environments (don't worry these are described in the next section).
11680 \end_layout
11681
11682 \begin_layout Labeling
11683 \labelwidthstring MMMMMMx
11684
11685 \series bold
11686 leqno
11687 \series default
11688  Equation numbers on the left.
11689 \end_layout
11690
11691 \begin_layout Labeling
11692 \labelwidthstring MMMMMMx
11693
11694 \series bold
11695 fleqn
11696 \series default
11697  Flush-left equations.
11698 \end_layout
11699
11700 \begin_layout Subsection
11701 Supported Environments
11702 \end_layout
11703
11704 \begin_layout Standard
11705 Most of the environments commonly supported in other classes are also supported
11706  by the 
11707 \family sans
11708 foils
11709 \family default
11710  class.
11711  There are several additional environments provided by 
11712 \family sans
11713 Foil\SpecialChar TeX
11714
11715 \family default
11716  as well as a couple added by \SpecialChar LyX
11717 .
11718  The following environments are shared with other classes:
11719 \end_layout
11720
11721 \begin_layout Standard
11722 \begin_inset Flex Multiple Columns
11723 status open
11724
11725 \begin_layout Itemize
11726
11727 \family sans
11728 Standard
11729 \end_layout
11730
11731 \begin_layout Itemize
11732
11733 \family sans
11734 Itemize
11735 \end_layout
11736
11737 \begin_layout Itemize
11738
11739 \family sans
11740 Enumerate
11741 \end_layout
11742
11743 \begin_layout Itemize
11744
11745 \family sans
11746 Description
11747 \end_layout
11748
11749 \begin_layout Itemize
11750
11751 \family sans
11752 List
11753 \end_layout
11754
11755 \begin_layout Itemize
11756
11757 \family sans
11758 \SpecialChar LyX
11759 -Code
11760 \end_layout
11761
11762 \begin_layout Itemize
11763
11764 \family sans
11765 Verse
11766 \end_layout
11767
11768 \begin_layout Itemize
11769
11770 \family sans
11771 Quote
11772 \end_layout
11773
11774 \begin_layout Itemize
11775
11776 \family sans
11777 Quotation
11778 \end_layout
11779
11780 \begin_layout Itemize
11781
11782 \family sans
11783 Title
11784 \change_deleted -712698321 1501158884
11785
11786 \end_layout
11787
11788 \begin_layout Itemize
11789
11790 \family sans
11791 Author
11792 \end_layout
11793
11794 \begin_layout Itemize
11795
11796 \family sans
11797 Date
11798 \end_layout
11799
11800 \begin_layout Itemize
11801
11802 \family sans
11803 Abstract
11804 \end_layout
11805
11806 \begin_layout Itemize
11807
11808 \family sans
11809 Bibliography
11810 \end_layout
11811
11812 \begin_layout Itemize
11813
11814 \family sans
11815 Address
11816 \end_layout
11817
11818 \begin_layout Itemize
11819
11820 \family sans
11821 RightAddress
11822 \end_layout
11823
11824 \begin_layout Itemize
11825
11826 \change_deleted -712698321 1501158888
11827
11828 \family sans
11829 Caption
11830 \change_unchanged
11831
11832 \end_layout
11833
11834 \begin_layout Itemize
11835
11836 \change_deleted -712698321 1501158891
11837
11838 \family sans
11839 Comment
11840 \change_unchanged
11841
11842 \end_layout
11843
11844 \end_inset
11845
11846
11847 \end_layout
11848
11849 \begin_layout Standard
11850 That is, all the major environments apart from the sectioning environments.
11851  Since foils are essentially self-contained sections, with a title and body,
11852  
11853 \family sans
11854 Foil\SpecialChar TeX
11855
11856 \family default
11857  provides specific commands for starting new foils and these are:
11858 \end_layout
11859
11860 \begin_layout Itemize
11861
11862 \family sans
11863 Foilhead
11864 \end_layout
11865
11866 \begin_layout Itemize
11867
11868 \family sans
11869 Rotatefoilhead
11870 \end_layout
11871
11872 \begin_layout Standard
11873 \SpecialChar LyX
11874  also provides slightly modified versions of these two environments called:
11875 \end_layout
11876
11877 \begin_layout Itemize
11878
11879 \family sans
11880 ShortFoilhead
11881 \end_layout
11882
11883 \begin_layout Itemize
11884
11885 \family sans
11886 ShortRotatefoilhead
11887 \end_layout
11888
11889 \begin_layout Standard
11890 and the differences will be explained in the next section.
11891 \end_layout
11892
11893 \begin_layout Standard
11894 Since foils are often used in presenting ideas or new theorems and such
11895  
11896 \family sans
11897 Foil\SpecialChar TeX
11898
11899 \family default
11900  also provides a comprehensive box of goodies for presenting them:
11901 \end_layout
11902
11903 \begin_layout Standard
11904 \begin_inset Flex Multiple Columns
11905 status open
11906
11907 \begin_layout Itemize
11908
11909 \family sans
11910 Theorem
11911 \end_layout
11912
11913 \begin_layout Itemize
11914
11915 \family sans
11916 Lemma
11917 \end_layout
11918
11919 \begin_layout Itemize
11920
11921 \family sans
11922 Corollary
11923 \end_layout
11924
11925 \begin_layout Itemize
11926
11927 \family sans
11928 Proposition
11929 \end_layout
11930
11931 \begin_layout Itemize
11932
11933 \family sans
11934 Definition
11935 \end_layout
11936
11937 \begin_layout Itemize
11938
11939 \family sans
11940 Proof
11941 \end_layout
11942
11943 \begin_layout Itemize
11944
11945 \family sans
11946 Theorem*
11947 \end_layout
11948
11949 \begin_layout Itemize
11950
11951 \family sans
11952 Lemma*
11953 \end_layout
11954
11955 \begin_layout Itemize
11956
11957 \family sans
11958 Corollary*
11959 \end_layout
11960
11961 \begin_layout Itemize
11962
11963 \family sans
11964 Proposition*
11965 \end_layout
11966
11967 \begin_layout Itemize
11968
11969 \family sans
11970 Definition*
11971 \end_layout
11972
11973 \end_inset
11974
11975
11976 \end_layout
11977
11978 \begin_layout Standard
11979 The starred versions are unnumbered while the unstarred versions are numbered.
11980  There are also two list environments added by \SpecialChar LyX
11981  and these are:
11982 \end_layout
11983
11984 \begin_layout Itemize
11985
11986 \family sans
11987 TickList
11988 \end_layout
11989
11990 \begin_layout Itemize
11991
11992 \family sans
11993 CrossList
11994 \end_layout
11995
11996 \begin_layout Standard
11997
11998 \family sans
11999 Foil\SpecialChar TeX
12000
12001 \family default
12002  provides some powerful header and footer capabilities that are best set
12003  in the preamble although they may be set at any point in a document.
12004  If you want to change these settings in your document the best place to
12005  do so is at the very top of a foil, i.
12006 \begin_inset space \thinspace{}
12007 \end_inset
12008
12009 e.
12010 \emph on
12011
12012 \begin_inset space \space{}
12013 \end_inset
12014
12015
12016 \emph default
12017 straight after the foilhead.
12018 \end_layout
12019
12020 \begin_layout Standard
12021 For this purpose, the following command styles are provided [
12022 \shape smallcaps
12023 Martin Vermeer
12024 \shape default
12025 ]:
12026 \end_layout
12027
12028 \begin_layout Standard
12029 \begin_inset Flex Multiple Columns
12030 status open
12031
12032 \begin_layout Itemize
12033
12034 \family sans
12035 My
12036 \begin_inset space ~
12037 \end_inset
12038
12039 Logo
12040 \end_layout
12041
12042 \begin_layout Itemize
12043
12044 \family sans
12045 Restriction
12046 \end_layout
12047
12048 \begin_layout Itemize
12049
12050 \family sans
12051 Right
12052 \begin_inset space ~
12053 \end_inset
12054
12055 Footer
12056 \end_layout
12057
12058 \begin_layout Itemize
12059
12060 \family sans
12061 Right
12062 \begin_inset space ~
12063 \end_inset
12064
12065 Header
12066 \end_layout
12067
12068 \begin_layout Itemize
12069
12070 \family sans
12071 Left
12072 \begin_inset space ~
12073 \end_inset
12074
12075 Header
12076 \end_layout
12077
12078 \begin_deeper
12079 \begin_layout Plain Layout
12080 \begin_inset space ~
12081 \end_inset
12082
12083
12084 \end_layout
12085
12086 \end_deeper
12087 \end_inset
12088
12089
12090 \end_layout
12091
12092 \begin_layout Standard
12093 There are also a few commands provided by 
12094 \family sans
12095 Foil\SpecialChar TeX
12096
12097 \family default
12098  that aren't directly supported by \SpecialChar LyX
12099  but I'll tell you what they do and how
12100  to use them in section
12101 \begin_inset space ~
12102 \end_inset
12103
12104
12105 \begin_inset CommandInset ref
12106 LatexCommand ref
12107 reference "sec:unsuppfoils"
12108
12109 \end_inset
12110
12111 .
12112 \end_layout
12113
12114 \begin_layout Subsection
12115 Building a Set of Foils
12116 \end_layout
12117
12118 \begin_layout Standard
12119 This section will give a simple introduction to using the different environments
12120  to build a set of foils.
12121  If you want to see an example set of foils, take a look at the 
12122 \family typewriter
12123 Foils.lyx
12124 \family default
12125  file you find in \SpecialChar LyX
12126 's 
12127 \family typewriter
12128 examples
12129 \family default
12130  folder.
12131 \end_layout
12132
12133 \begin_layout Subsubsection
12134 Give It a Title Page
12135 \end_layout
12136
12137 \begin_layout Standard
12138 Unlike other classes that provide 
12139 \family sans
12140 Title
12141 \family default
12142
12143 \family sans
12144 Author
12145 \family default
12146
12147 \family sans
12148 Date
12149 \family default
12150  and 
12151 \family sans
12152 Abstract
12153 \family default
12154  environments, 
12155 \family sans
12156 foils
12157 \family default
12158  creates the title on a page of its own.
12159  If you leave out the 
12160 \family sans
12161 Date
12162 \family default
12163  environment \SpecialChar LaTeX
12164  will substitute the current date (every time you regenerate
12165  the output).
12166 \end_layout
12167
12168 \begin_layout Subsubsection
12169 Start a New Foil
12170 \end_layout
12171
12172 \begin_layout Standard
12173 As I mentioned earlier, there are four ways of starting a new foil.
12174  For portrait foils you should use 
12175 \family sans
12176 Foilhead
12177 \family default
12178  or 
12179 \family sans
12180 ShortFoilhead.
12181
12182 \family default
12183  The difference between these two environments is the amount of space between
12184  the title of the foil (the foilhead) and the body of the foil.
12185 \end_layout
12186
12187 \begin_layout Standard
12188 Landscape foils are generated using the 
12189 \family sans
12190 Rotatefoilhead
12191 \family default
12192  and 
12193 \family sans
12194 ShortRotatefoilhead
12195 \family default
12196  environments.
12197  Again the only difference is the spacing between foilhead and body.
12198  Both of the short versions have 0.5
12199 \begin_inset space ~
12200 \end_inset
12201
12202 inches less separation between the foilhead and the body.
12203  
12204 \end_layout
12205
12206 \begin_layout Standard
12207 One problem with the support for landscape foils is the requirement that
12208  you have to use the 
12209 \family typewriter
12210 dvips
12211 \family default
12212  driver to generate the PostScript output otherwise the foils won't be rotated.
12213  It is possible to get landscape foils even if you haven't got the 
12214 \family typewriter
12215 dvips
12216 \family default
12217  driver provided you can feed your foils sideways through your printer ;-)
12218 \end_layout
12219
12220 \begin_layout Subsubsection
12221 Theorems, Lemmas, Proofs and more
12222 \end_layout
12223
12224 \begin_layout Standard
12225
12226 \change_deleted -712698321 1501160146
12227 Due to a small bug in \SpecialChar LyX
12228  y
12229 \change_inserted -712698321 1501160146
12230 Y
12231 \change_unchanged
12232 ou can't have two of the same type of these environments directly following
12233  each other.
12234  
12235 \change_inserted -712698321 1501160182
12236 If you use a normal paragraph break, 
12237 \change_deleted -712698321 1501160188
12238 They must be separated by something.
12239  If you try
12240 \change_unchanged
12241 , you will just be extending the previous environment as if you had merged
12242  the two environments together.
12243  
12244 \change_deleted -712698321 1501160194
12245 So, how do you get around this problem? The simplest option is to insert
12246  some text between the two environments or add a 
12247 \family sans
12248 \SpecialChar LaTeX
12249
12250 \family default
12251  environment between the two with just a 
12252 \begin_inset Quotes eld
12253 \end_inset
12254
12255
12256 \family typewriter
12257 %
12258 \family default
12259
12260 \begin_inset Quotes erd
12261 \end_inset
12262
12263  in it.
12264  This will force \SpecialChar LyX
12265  to produce two separate environments and hence the correct
12266  \SpecialChar LaTeX
12267  output.
12268  An example is provided in the example file included with the \SpecialChar LyX
12269  distribution.
12270  Remember, this problem only occurs if you are trying to place two of the
12271  same type of theorem-like environments one directly after the other.
12272
12273 \change_inserted -712698321 1501160255
12274  Rather than that, you need to insert a so-called separator.
12275  Please refer to the section entitled 
12276 \emph on
12277 Separate Nestings
12278 \emph default
12279  in the 
12280 \emph on
12281 User's Guide
12282 \emph default
12283 .
12284 \change_unchanged
12285
12286 \end_layout
12287
12288 \begin_layout Subsubsection
12289 Lists
12290 \end_layout
12291
12292 \begin_layout Standard
12293 You get all the commonly supported list styles found in other classes as
12294  well as two new ones.
12295  I'll only describe the new ones here.
12296  If you want to find out more about the other list environments check out
12297  the 
12298 \emph on
12299 User's Guide.
12300
12301 \emph default
12302  If you intend to use itemized lists you might also want to read about the
12303  
12304 \family sans
12305 Itemize
12306 \begin_inset space ~
12307 \end_inset
12308
12309 Bullet
12310 \begin_inset space ~
12311 \end_inset
12312
12313 Selection
12314 \family default
12315  dialog described above in section
12316 \begin_inset space ~
12317 \end_inset
12318
12319
12320 \begin_inset CommandInset ref
12321 LatexCommand ref
12322 reference "sec:bullet"
12323
12324 \end_inset
12325
12326 .
12327 \end_layout
12328
12329 \begin_layout Standard
12330 The two new list styles, 
12331 \family sans
12332 TickList
12333 \family default
12334  and 
12335 \family sans
12336 CrossList
12337 \family default
12338 , are designed to make it easier for you to create lists of do's and don'ts
12339  or right and wrong by providing dedicated environments that use a tick
12340  or a cross as the label of the list.
12341  These lists are in fact dedicated variants of the 
12342 \family sans
12343 Itemize
12344 \family default
12345  environment.
12346  They do however require that you have the 
12347 \family typewriter
12348 psnfss
12349 \family default
12350  packages installed.
12351 \end_layout
12352
12353 \begin_layout Subsubsection
12354 Figures and Tables
12355 \end_layout
12356
12357 \begin_layout Standard
12358
12359 \family sans
12360 Foil\SpecialChar TeX
12361
12362 \family default
12363  redefines the floating tables and figures so that they appear exactly where
12364  they are in the text rather than pushing them to the top of the page or
12365  to some user specified location.
12366  In fact if you change the float placement settings they are simply ignored.
12367 \end_layout
12368
12369 \begin_layout Subsubsection
12370 Page Headers and Footers
12371 \begin_inset CommandInset label
12372 LatexCommand label
12373 name "sec:foilfoot"
12374
12375 \end_inset
12376
12377
12378 \end_layout
12379
12380 \begin_layout Standard
12381
12382 \family sans
12383 My
12384 \begin_inset space ~
12385 \end_inset
12386
12387 Logo
12388 \family default
12389  and 
12390 \family sans
12391 Restriction
12392 \family default
12393  are two commands used to control the left-footer text string.
12394  The first is meant to allow you to include a graphic logo on your foils
12395  and defaults to 
12396 \begin_inset Quotes eld
12397 \end_inset
12398
12399 -Typeset by 
12400 \family sans
12401 Foil\SpecialChar TeX
12402
12403 \family default
12404 -
12405 \begin_inset Quotes erd
12406 \end_inset
12407
12408 .
12409  While the second is meant to provide a classification for the audience,
12410  
12411 \emph on
12412 e.
12413 \begin_inset space \thinspace{}
12414 \end_inset
12415
12416 g.
12417 \emph default
12418
12419 \begin_inset space \space{}
12420 \end_inset
12421
12422 Confidential.
12423  It is empty by default.
12424 \end_layout
12425
12426 \begin_layout Standard
12427 The remaining page corners can be filled by 
12428 \family sans
12429 Right
12430 \begin_inset space ~
12431 \end_inset
12432
12433 Footer
12434 \family default
12435  (which defaults to page numbers), 
12436 \family sans
12437 Right
12438 \begin_inset space ~
12439 \end_inset
12440
12441 Header
12442 \family default
12443  (top right) and 
12444 \family sans
12445 Left
12446 \begin_inset space ~
12447 \end_inset
12448
12449 Header
12450 \family default
12451  (top left).
12452 \end_layout
12453
12454 \begin_layout Subsection
12455 Unsupported 
12456 \family sans
12457 Foil\SpecialChar TeX
12458
12459 \family default
12460  Goodies
12461 \begin_inset CommandInset label
12462 LatexCommand label
12463 name "sec:unsuppfoils"
12464
12465 \end_inset
12466
12467
12468 \end_layout
12469
12470 \begin_layout Standard
12471 All the commands mentioned below need to be set in a 
12472 \family sans
12473 \SpecialChar LaTeX
12474
12475 \family default
12476  environment or as 
12477 \family sans
12478 \SpecialChar TeX
12479
12480 \family default
12481  within another environment.
12482 \end_layout
12483
12484 \begin_layout Subsubsection
12485 Lengths
12486 \end_layout
12487
12488 \begin_layout Standard
12489 All lengths are adjusted using the 
12490 \family typewriter
12491
12492 \backslash
12493 setlength{
12494 \family default
12495 \emph on
12496 lengthname
12497 \family typewriter
12498 \emph default
12499 }{
12500 \family default
12501 \emph on
12502 newlength
12503 \family typewriter
12504 \emph default
12505 }
12506 \family default
12507  command.
12508  Where 
12509 \emph on
12510 lengthname
12511 \emph default
12512  should be replaced by the name given to the length you want to change and
12513  
12514 \emph on
12515 newlength
12516 \emph default
12517  is the length value.
12518  All lengths should be specified in units of length such as inches (
12519 \family typewriter
12520 in
12521 \family default
12522 ), millimeters (
12523 \family typewriter
12524 mm
12525 \family default
12526 ) or points (
12527 \family typewriter
12528 pt
12529 \family default
12530 ) or relative to some document or font-based length such as 
12531 \family typewriter
12532
12533 \backslash
12534 textwidth
12535 \family default
12536 .
12537  
12538 \end_layout
12539
12540 \begin_layout Standard
12541 It's possible to change the spacing between a foilhead and the body of the
12542  foil by adjusting the length specified by 
12543 \family typewriter
12544
12545 \backslash
12546 foilheadskip
12547 \family default
12548 .
12549  For example, to make 
12550 \emph on
12551 all
12552 \emph default
12553  foilheads 0.5
12554 \begin_inset space \space{}
12555 \end_inset
12556
12557 in closer to their bodies put the following in the preamble: 
12558 \family typewriter
12559
12560 \backslash
12561 setlength{
12562 \backslash
12563 foilheadskip}{-0.5in}
12564 \end_layout
12565
12566 \begin_layout Standard
12567 The spacings around floats can be adjusted by setting these lengths:
12568 \end_layout
12569
12570 \begin_layout Labeling
12571 \labelwidthstring MMMMMMMMMMM
12572
12573 \family typewriter
12574
12575 \backslash
12576 abovefloatskip
12577 \family default
12578  Separation between the text and the top of the float
12579 \end_layout
12580
12581 \begin_layout Labeling
12582 \labelwidthstring MMMMMMMMMMM
12583
12584 \family typewriter
12585
12586 \backslash
12587 abovecaptionskip
12588 \family default
12589  Separation between the float and the caption
12590 \end_layout
12591
12592 \begin_layout Labeling
12593 \labelwidthstring MMMMMMMMMMM
12594
12595 \family typewriter
12596
12597 \backslash
12598 belowcaptionskip
12599 \family default
12600  Separation between the caption and the following text
12601 \end_layout
12602
12603 \begin_layout Labeling
12604 \labelwidthstring MMMMMMMMMMM
12605
12606 \family typewriter
12607
12608 \backslash
12609 captionwidth
12610 \family default
12611  You can make the captions narrower than the surrounding text by adjusting
12612  this length.
12613  Best done relative to 
12614 \family typewriter
12615
12616 \backslash
12617 textwidth
12618 \family default
12619 .
12620 \end_layout
12621
12622 \begin_layout Standard
12623 There are also several title page related lengths that you may find useful
12624  if you have a long title or several authors:
12625 \end_layout
12626
12627 \begin_layout Labeling
12628 \labelwidthstring MMMMMMMMMMM
12629
12630 \family typewriter
12631
12632 \backslash
12633 abovetitleskip
12634 \family default
12635  Separation from headers to 
12636 \family sans
12637 Title
12638 \end_layout
12639
12640 \begin_layout Labeling
12641 \labelwidthstring MMMMMMMMMMM
12642
12643 \family typewriter
12644
12645 \backslash
12646 titleauthorskip
12647 \family default
12648  between 
12649 \family sans
12650 Title
12651 \family default
12652  and 
12653 \family sans
12654 Author
12655 \family default
12656  environments
12657 \end_layout
12658
12659 \begin_layout Labeling
12660 \labelwidthstring MMMMMMMMMMM
12661
12662 \family typewriter
12663
12664 \backslash
12665 authorauthorskip
12666 \family default
12667  between multiple 
12668 \family sans
12669 Author
12670 \family default
12671  lines
12672 \end_layout
12673
12674 \begin_layout Labeling
12675 \labelwidthstring MMMMMMMMMMM
12676
12677 \family typewriter
12678
12679 \backslash
12680 authordateskip
12681 \family default
12682  between the 
12683 \family sans
12684 Author
12685 \family default
12686  and the 
12687 \family sans
12688 Date
12689 \end_layout
12690
12691 \begin_layout Labeling
12692 \labelwidthstring MMMMMMMMMMM
12693
12694 \family typewriter
12695
12696 \backslash
12697 dateabstractskip
12698 \family default
12699  between the 
12700 \family sans
12701 Date
12702 \family default
12703  and the 
12704 \family sans
12705 Abstract
12706 \end_layout
12707
12708 \begin_layout Standard
12709 The last length related command affects all the list environments.
12710  If you place 
12711 \family typewriter
12712
12713 \backslash
12714 zerolistvertdimens
12715 \family default
12716  
12717 \emph on
12718 inside
12719 \emph default
12720  a list environment then all the vertical spacing between the list items
12721  is removed.
12722  Note that this is a command not a length so it doesn't require 
12723 \family typewriter
12724
12725 \backslash
12726 setlength
12727 \family default
12728  like the stuff mentioned above.
12729 \end_layout
12730
12731 \begin_layout Subsubsection
12732 Headers and Footers
12733 \end_layout
12734
12735 \begin_layout Standard
12736 The 
12737 \family typewriter
12738
12739 \backslash
12740 LogoOn
12741 \family default
12742  and 
12743 \family typewriter
12744
12745 \backslash
12746 LogoOff
12747 \family default
12748  commands control whether the logo in the 
12749 \family sans
12750 MyLogo
12751 \family default
12752  definition appear on a given page.
12753  If you put 
12754 \family typewriter
12755
12756 \backslash
12757 LogoOff
12758 \family default
12759  in the preamble then none of the foils will have the logo on them.
12760  If you don't want the logo on a particular page place the 
12761 \family typewriter
12762
12763 \backslash
12764 LogoOff
12765 \family default
12766  directly after the foilhead of that page and the 
12767 \family typewriter
12768
12769 \backslash
12770 LogoOn
12771 \family default
12772  directly after the next foilhead.
12773 \end_layout
12774
12775 \begin_layout Standard
12776 If you decide to use the 
12777 \family sans
12778 fancy
12779 \family default
12780  page style setting in the 
12781 \family sans
12782 Document
12783 \begin_inset space ~
12784 \end_inset
12785
12786 Layout
12787 \family default
12788  dialog you should probably add 
12789 \family typewriter
12790
12791 \backslash
12792 let
12793 \backslash
12794 headwidth
12795 \backslash
12796 textwidth
12797 \family default
12798  to your preamble so headers and footers on landscape pages are correctly
12799  placed when rotated.
12800  This is due to some clashes between the page layouts provided by the 
12801 \family sans
12802 fancyheadings
12803 \family default
12804  package and the 
12805 \family sans
12806 foils
12807 \family default
12808  class.
12809 \end_layout
12810
12811 \begin_layout Section
12812 Hollywood (Hollywood spec scripts)
12813 \end_layout
12814
12815 \begin_layout Standard
12816 by 
12817 \shape smallcaps
12818 Garst Reese
12819 \end_layout
12820
12821 \begin_layout Subsection
12822 Introduction
12823 \end_layout
12824
12825 \begin_layout Standard
12826 Getting the format of a Hollywood script right is a 
12827 \begin_inset Quotes eld
12828 \end_inset
12829
12830 rite of passage.
12831 \begin_inset Quotes erd
12832 \end_inset
12833
12834  It is designed to make the readers focus on content and to be easy and
12835  familiar for the actors to read.
12836  Each page of a script should be one minute of film.
12837  Nothing goes in a script that you cannot see or hear on screen.
12838  The courier 12 pt font should be used throughout.
12839  No italics.
12840 \end_layout
12841
12842 \begin_layout Subsection
12843 Special problems
12844 \end_layout
12845
12846 \begin_layout Standard
12847 Speakers' lines should NEVER break in mid-sentence.
12848  If a speaker's lines continue over a page break, repeat the 
12849 \family sans
12850 Speaker
12851 \family default
12852  title followed by (Cont'd).
12853 \end_layout
12854
12855 \begin_layout Subsection
12856 Special features
12857 \end_layout
12858
12859 \begin_layout Standard
12860 Insert the 
12861 \family sans
12862 Speaker
12863 \family default
12864  names as labels then cross-reference the label to insert the name.
12865  The cross-reference dialog will show the current cast of characters.
12866  You can use this to insert the speaker name in narratives also.
12867 \end_layout
12868
12869 \begin_layout Subsection
12870 Paper size and Margins
12871 \end_layout
12872
12873 \begin_layout Standard
12874 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
12875 \end_layout
12876
12877 \begin_layout Subsection
12878 Environments
12879 \end_layout
12880
12881 \begin_layout Standard
12882 The following environments are available.
12883  You can use hollywood.bind to get the bind keys shown at the right.
12884 \end_layout
12885
12886 \begin_layout Itemize
12887
12888 \family sans
12889 Standard
12890 \begin_inset Newline newline
12891 \end_inset
12892
12893
12894 \family default
12895 Used where nothing else works.
12896  Try to avoid it.
12897 \end_layout
12898
12899 \begin_layout Itemize
12900
12901 \family sans
12902 FADE_IN
12903 \family default
12904 :
12905 \begin_inset space \hfill{}
12906 \end_inset
12907
12908
12909 \family sans
12910 M-z S-I
12911 \family default
12912
12913 \begin_inset Newline newline
12914 \end_inset
12915
12916 Usually followed by something like 
12917 \begin_inset Quotes eld
12918 \end_inset
12919
12920 on Sally waking up.
12921 \begin_inset Quotes erd
12922 \end_inset
12923
12924
12925 \end_layout
12926
12927 \begin_layout Itemize
12928
12929 \family sans
12930 INT:
12931 \begin_inset space \hfill{}
12932 \end_inset
12933
12934 M-z i
12935 \begin_inset Newline newline
12936 \end_inset
12937
12938
12939 \family default
12940 Introduces a new INTERIOR camera set-up.
12941  Always followed by DAY or NIGHT, or something similar to define the lighting
12942  required.
12943  Everthing on this line in CAPS.
12944 \end_layout
12945
12946 \begin_layout Itemize
12947
12948 \family sans
12949 EXT:
12950 \begin_inset space \hfill{}
12951 \end_inset
12952
12953 M-z e
12954 \begin_inset Newline newline
12955 \end_inset
12956
12957
12958 \family default
12959 Introduces a new EXTERIOR camera set-up.
12960  Everthing on this line in CAPS.
12961 \end_layout
12962
12963 \begin_layout Itemize
12964
12965 \family sans
12966 Speaker
12967 \begin_inset space \hfill{}
12968 \end_inset
12969
12970 M-z s
12971 \begin_inset Newline newline
12972 \end_inset
12973
12974
12975 \family default
12976 The character speaking.
12977 \end_layout
12978
12979 \begin_layout Itemize
12980
12981 \family sans
12982 Parenthetical
12983 \begin_inset space \hfill{}
12984 \end_inset
12985
12986 M-z p
12987 \begin_inset Newline newline
12988 \end_inset
12989
12990
12991 \family default
12992 Instructions to the speaker.
12993  The () are automatically inserted
12994 \change_deleted -712698321 1501161286
12995 , but only the ( will show in \SpecialChar LyX
12996 .
12997  Both will be printed
12998 \change_unchanged
12999 .
13000 \end_layout
13001
13002 \begin_layout Itemize
13003
13004 \family sans
13005 Dialogue
13006 \begin_inset space \hfill{}
13007 \end_inset
13008
13009 M-z d
13010 \begin_inset Newline newline
13011 \end_inset
13012
13013
13014 \family default
13015 What the 
13016 \family sans
13017 Speaker
13018 \family default
13019  says.
13020 \end_layout
13021
13022 \begin_layout Itemize
13023
13024 \family sans
13025 Transition
13026 \begin_inset space \hfill{}
13027 \end_inset
13028
13029 M-z t
13030 \begin_inset Newline newline
13031 \end_inset
13032
13033
13034 \family default
13035 Camera movement instruction.
13036  e.
13037 \begin_inset space \thinspace{}
13038 \end_inset
13039
13040 g.
13041 \begin_inset space \space{}
13042 \end_inset
13043
13044 CUT TO:
13045 \end_layout
13046
13047 \begin_layout Itemize
13048
13049 \family sans
13050 FADE OUT:
13051 \begin_inset space \hfill{}
13052 \end_inset
13053
13054 M-z S-I
13055 \end_layout
13056
13057 \begin_layout Itemize
13058
13059 \family sans
13060 Author
13061 \begin_inset space \hfill{}
13062 \end_inset
13063
13064 M-z S-A
13065 \end_layout
13066
13067 \begin_layout Itemize
13068
13069 \family sans
13070 Title
13071 \begin_inset space \hfill{}
13072 \end_inset
13073
13074 M-z S-T
13075 \end_layout
13076
13077 \begin_layout Itemize
13078
13079 \family sans
13080 Right_Address
13081 \begin_inset space \hfill{}
13082 \end_inset
13083
13084 M-z r
13085 \end_layout
13086
13087 \begin_layout Subsection
13088 Script jargon
13089 \end_layout
13090
13091 \begin_layout Itemize
13092 (O.S) — off screen
13093 \end_layout
13094
13095 \begin_layout Itemize
13096 (V.0) — voice over
13097 \end_layout
13098
13099 \begin_layout Itemize
13100 b.
13101 \begin_inset space \thinspace{}
13102 \end_inset
13103
13104 g.
13105  — background
13106 \end_layout
13107
13108 \begin_layout Itemize
13109 C.U.
13110  — close-up
13111 \end_layout
13112
13113 \begin_layout Itemize
13114 PAN — camera movement
13115 \end_layout
13116
13117 \begin_layout Itemize
13118 INSERT — cut to close-up of
13119 \end_layout
13120
13121 \begin_layout Section
13122 ijmpc and ijmpd
13123 \end_layout
13124
13125 \begin_layout Standard
13126 by 
13127 \noun on
13128 Panayotis Papasotiriou
13129 \end_layout
13130
13131 \begin_layout Subsection
13132 Overview
13133 \end_layout
13134
13135 \begin_layout Standard
13136 The ijmpc package is a set of macros that facilitates electronic manuscript
13137  submission to the 
13138 \emph on
13139 International Journal of Modern Physics C
13140 \emph default
13141 .
13142  Similarly, the ijmpd package is for creating manuscripts to be submitted
13143  to the 
13144 \emph on
13145 International Journal of Modern Physics D
13146 \emph default
13147 .
13148  Both journals are published by World Scientific.
13149  The corresponding document classes are named 
13150 \family typewriter
13151 ws-ijmpc.cls
13152 \family default
13153  and 
13154 \family typewriter
13155 ws-ijmpd.cls
13156 \family default
13157 , respectively.
13158  These files, together with instructions for the authors, can be downloaded
13159  from the sites 
13160 \begin_inset Flex URL
13161 status collapsed
13162
13163 \begin_layout Plain Layout
13164
13165 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
13166 \end_layout
13167
13168 \end_inset
13169
13170  and 
13171 \begin_inset Flex URL
13172 status collapsed
13173
13174 \begin_layout Plain Layout
13175
13176 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
13177 \end_layout
13178
13179 \end_inset
13180
13181 .
13182  Both packages are modified versions of the standard 
13183 \begin_inset Quotes eld
13184 \end_inset
13185
13186 article
13187 \begin_inset Quotes erd
13188 \end_inset
13189
13190  package, and they are almost (but not exactly) identical.
13191  Most of their features are supported by \SpecialChar LyX
13192 .
13193  I have used \SpecialChar LyX
13194  successfully to write articles submitted to both journals
13195  without any problem.
13196 \end_layout
13197
13198 \begin_layout Subsection
13199 Writing a paper
13200 \end_layout
13201
13202 \begin_layout Standard
13203 As usual, the easiest way to write a paper is to start with a template.
13204  Click on 
13205 \family sans
13206 File\SpecialChar menuseparator
13207 New from
13208 \family default
13209  
13210 \family sans
13211 Template
13212 \family default
13213 , then choose the 
13214 \family typewriter
13215 ijmpc.lyx
13216 \family default
13217  or 
13218 \family typewriter
13219 ijmpd.lyx
13220 \family default
13221  template.
13222  This will give an (almost) empty document that includes the most common
13223  fields found in a manuscript.
13224  Simply overwrite the existing text (including the brackets, 
13225 \family typewriter
13226 <>
13227 \family default
13228 ) with your text.
13229  You should keep in mind the following remarks.
13230 \end_layout
13231
13232 \begin_layout Enumerate
13233 \SpecialChar LyX
13234  won't let you change the font size and the page style of the document,
13235  because such modifications are not allowed by both packages.
13236 \end_layout
13237
13238 \begin_layout Enumerate
13239 The language of the document should not be changed.
13240  Before previewing your paper, be sure that the babel package is not used.
13241  To do this, click on
13242 \change_inserted -712698321 1501082726
13243  
13244 \begin_inset Info
13245 type  "menu"
13246 arg   "dialog-show document"
13247 \end_inset
13248
13249
13250 \change_unchanged
13251  
13252 \change_deleted -712698321 1501082743
13253
13254 \family sans
13255 Tools
13256 \change_unchanged
13257 \SpecialChar menuseparator
13258
13259 \change_deleted -712698321 1501082747
13260 Preferences
13261 \change_inserted -712698321 1501082748
13262 Language
13263 \change_unchanged
13264
13265 \family default
13266
13267 \change_deleted -712698321 1501082762
13268 select the 
13269 \family sans
13270 Lang Opts
13271 \family default
13272  tab, deselect the 
13273 \family sans
13274 Use babel
13275 \family default
13276  checkbox in the language settings, and click on 
13277 \family sans
13278 Apply
13279 \family default
13280  (or 
13281 \family sans
13282 Save
13283 \family default
13284 , if you wish to make this change permanent)
13285 \change_inserted -712698321 1501082770
13286 and select 
13287 \begin_inset Quotes eld
13288 \end_inset
13289
13290 None
13291 \begin_inset Quotes erd
13292 \end_inset
13293
13294  as 
13295 \family sans
13296 Language Package
13297 \change_unchanged
13298
13299 \family default
13300 .
13301 \end_layout
13302
13303 \begin_layout Enumerate
13304 The 
13305 \begin_inset Quotes eld
13306 \end_inset
13307
13308 Keywords
13309 \begin_inset Quotes erd
13310 \end_inset
13311
13312  style must be used to define keywords.
13313 \end_layout
13314
13315 \begin_layout Enumerate
13316 The ijmpc package provides a style named 
13317 \begin_inset Quotes eld
13318 \end_inset
13319
13320 Classification Codes
13321 \begin_inset Quotes erd
13322 \end_inset
13323
13324 , which can be used to define classification codes, such as PACS numbers.
13325  Note that this facility is not supported by the ijmpd package.
13326 \end_layout
13327
13328 \begin_layout Enumerate
13329 Several new environments are available: 
13330 \begin_inset Quotes eld
13331 \end_inset
13332
13333 Definition
13334 \begin_inset Quotes erd
13335 \end_inset
13336
13337
13338 \begin_inset Quotes eld
13339 \end_inset
13340
13341 Step
13342 \begin_inset Quotes erd
13343 \end_inset
13344
13345
13346 \begin_inset Quotes eld
13347 \end_inset
13348
13349 Example
13350 \begin_inset Quotes erd
13351 \end_inset
13352
13353
13354 \begin_inset Quotes eld
13355 \end_inset
13356
13357 Remark
13358 \begin_inset Quotes erd
13359 \end_inset
13360
13361
13362 \begin_inset Quotes eld
13363 \end_inset
13364
13365 Notation
13366 \begin_inset Quotes erd
13367 \end_inset
13368
13369
13370 \begin_inset Quotes eld
13371 \end_inset
13372
13373 Theorem
13374 \begin_inset Quotes erd
13375 \end_inset
13376
13377
13378 \begin_inset Quotes eld
13379 \end_inset
13380
13381 Proof
13382 \begin_inset Quotes erd
13383 \end_inset
13384
13385
13386 \begin_inset Quotes eld
13387 \end_inset
13388
13389 Corollary
13390 \begin_inset Quotes erd
13391 \end_inset
13392
13393
13394 \begin_inset Quotes eld
13395 \end_inset
13396
13397 Lemma
13398 \begin_inset Quotes erd
13399 \end_inset
13400
13401
13402 \begin_inset Quotes eld
13403 \end_inset
13404
13405 Proposition
13406 \begin_inset Quotes erd
13407 \end_inset
13408
13409
13410 \begin_inset Quotes eld
13411 \end_inset
13412
13413 Prop
13414 \begin_inset Quotes erd
13415 \end_inset
13416
13417
13418 \begin_inset Quotes eld
13419 \end_inset
13420
13421 Question
13422 \begin_inset Quotes erd
13423 \end_inset
13424
13425
13426 \begin_inset Quotes eld
13427 \end_inset
13428
13429 Claim
13430 \begin_inset Quotes erd
13431 \end_inset
13432
13433 , and 
13434 \begin_inset Quotes eld
13435 \end_inset
13436
13437 Conjecture
13438 \begin_inset Quotes erd
13439 \end_inset
13440
13441 .
13442  Their use is more or less obvious.
13443  \SpecialChar LyX
13444  supports all these environments; it will use the proper label, text style,
13445  and numbering scheme for each of them.
13446 \end_layout
13447
13448 \begin_layout Enumerate
13449 Both packages use basic citations; the natbib package should not be used.
13450  In \SpecialChar LyX
13451 , citation references are shown as usual; in the output, citations are
13452  shown as superscripts.
13453  If you want to use a citation as normal text, you should use the 
13454 \family typewriter
13455 refcite
13456 \family default
13457  command, e.
13458 \begin_inset space \thinspace{}
13459 \end_inset
13460
13461 g.
13462 \begin_inset space \space{}
13463 \end_inset
13464
13465
13466 \begin_inset Quotes eld
13467 \end_inset
13468
13469 See Ref.
13470 \begin_inset space \space{}
13471 \end_inset
13472
13473
13474 \family typewriter
13475
13476 \backslash
13477 refcite{key}
13478 \family default
13479
13480 \begin_inset Quotes erd
13481 \end_inset
13482
13483 .
13484 \end_layout
13485
13486 \begin_layout Enumerate
13487 There is no 
13488 \begin_inset Quotes eld
13489 \end_inset
13490
13491 Acknowledgments
13492 \begin_inset Quotes erd
13493 \end_inset
13494
13495  section in both packages.
13496  To put acknowledgments, just use the 
13497 \begin_inset Quotes eld
13498 \end_inset
13499
13500 Section*
13501 \begin_inset Quotes erd
13502 \end_inset
13503
13504  environment.
13505 \end_layout
13506
13507 \begin_layout Enumerate
13508 Appendices may be added to the paper, 
13509 \emph on
13510 after
13511 \emph default
13512  the Acknowledgments and 
13513 \shape italic
13514 before
13515 \shape default
13516  the References.
13517  \SpecialChar LyX
13518  provides a special environment, called 
13519 \begin_inset Quotes eld
13520 \end_inset
13521
13522 Appendices Section
13523 \begin_inset Quotes erd
13524 \end_inset
13525
13526  which marks the beginning of the appendices.
13527  This environment should be left blank; it just sends a \SpecialChar LaTeX
13528  command, but nothing
13529  is really printed.
13530  In \SpecialChar LyX
13531 , the word 
13532 \begin_inset Quotes eld
13533 \end_inset
13534
13535 Appendix
13536 \begin_inset Quotes erd
13537 \end_inset
13538
13539  is printed with blue letters, as a signal that all sections after that
13540  point are appendices.
13541  To write an appendix, use the 
13542 \begin_inset Quotes eld
13543 \end_inset
13544
13545 Appendix
13546 \begin_inset Quotes erd
13547 \end_inset
13548
13549  environment.
13550  \SpecialChar LyX
13551  will number each appendix with capital letters, as required by both journals.
13552  Note that 
13553 \begin_inset Quotes eld
13554 \end_inset
13555
13556 Appendices Section
13557 \begin_inset Quotes erd
13558 \end_inset
13559
13560  
13561 \emph on
13562 must
13563 \emph default
13564  be present before the first appendix; if not, all appendices will be numbered
13565  as normal sections in the output.
13566 \end_layout
13567
13568 \begin_layout Enumerate
13569 The ijmpc and the ijmpd packages use the 
13570 \family typewriter
13571 tbl
13572 \family default
13573  command to implement table captions.
13574  As a result, a table created by \SpecialChar LyX
13575  is printed correctly, but its caption
13576  is ignored.
13577  However, you can use some \SpecialChar TeX
13578  code to overcome this problem, so that captions
13579  are printed as expected.
13580  To do so, create a float table as usual, remove the caption, and replace
13581  it with the \SpecialChar TeX
13582  code 
13583 \family typewriter
13584
13585 \backslash
13586 tbl{
13587 \emph on
13588 your table caption
13589 \emph default
13590 }{
13591 \family default
13592  (sic); you must also the \SpecialChar TeX
13593  code 
13594 \family typewriter
13595 }
13596 \family default
13597  immediately after the tabular material.
13598  Study the example table included in the template files to see how this
13599  trick is implemented.
13600  Alternatively, If you need table captions, you should implement the whole
13601  table float in a 
13602 \family typewriter
13603 .tex
13604 \family default
13605  file, then include this file to the \SpecialChar LyX
13606  document (
13607 \family sans
13608 Insert\SpecialChar menuseparator
13609 File\SpecialChar menuseparator
13610 Child
13611 \begin_inset space ~
13612 \end_inset
13613
13614 Document
13615 \family default
13616 ).
13617  Details on how to create a table float can be found in the files 
13618 \family typewriter
13619 ws-ijmpc.tex
13620 \family default
13621  and 
13622 \family typewriter
13623 ws-ijmpd.tex
13624 \family default
13625 , included in the corresponding packages.
13626 \end_layout
13627
13628 \begin_layout Subsection
13629 Preparing a paper for submission
13630 \end_layout
13631
13632 \begin_layout Standard
13633 Before you submit your paper you must export the \SpecialChar LyX
13634  document as a \SpecialChar LaTeX
13635  file (
13636 \family sans
13637 File\SpecialChar menuseparator
13638 Export\SpecialChar menuseparator
13639 \SpecialChar LaTeX
13640
13641 \family default
13642 )
13643 \begin_inset Foot
13644 status open
13645
13646 \begin_layout Plain Layout
13647 Actually you have the choice between \SpecialChar LaTeX
13648  (plain) and pdflatex.
13649  If you intend to use pdflatex to prepare the paper, you should use the
13650  pdflatex option so that included graphics are converted to PDF format,
13651  ready for use by pdflatex.
13652 \end_layout
13653
13654 \end_inset
13655
13656 , then make the following changes to the resulting 
13657 \family typewriter
13658 .tex
13659 \family default
13660  file.
13661 \end_layout
13662
13663 \begin_layout Enumerate
13664 Remove the comment lines before the 
13665 \family typewriter
13666
13667 \backslash
13668 documentclass
13669 \family default
13670  command.
13671 \end_layout
13672
13673 \begin_layout Enumerate
13674 Remove everything between (and including) the 
13675 \family typewriter
13676
13677 \backslash
13678 makeatletter
13679 \family default
13680  and 
13681 \family typewriter
13682
13683 \backslash
13684 makeatother
13685 \family default
13686  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13687  preamble.
13688 \end_layout
13689
13690 \begin_layout Standard
13691 The modified 
13692 \family typewriter
13693 .tex
13694 \family default
13695  file should be saved and processed through \SpecialChar LaTeX
13696  as many times as necessary.
13697  You may also want to check the resulting 
13698 \family typewriter
13699 .dvi
13700 \family default
13701  document.
13702 \end_layout
13703
13704 \begin_layout Subsection
13705
13706 \change_deleted -712698321 1501082212
13707 Use of \SpecialChar TeX
13708  code
13709 \end_layout
13710
13711 \begin_layout Standard
13712
13713 \change_deleted -712698321 1501082212
13714 The use of \SpecialChar TeX
13715  code is reduced to two commands, which must be placed at the
13716  top of the document.
13717  If you started writing your paper by using the 
13718 \family typewriter
13719 ijmpc.lyx
13720 \family default
13721  or the 
13722 \family typewriter
13723 ijmpd.lyx
13724 \family default
13725  template, the \SpecialChar TeX
13726  code needed is already in its place; you usually don't need
13727  to delete it.
13728  You may only modify the first \SpecialChar TeX
13729  code to specify the information printed
13730  to the top of odd and even pages (authors' names and short paper's title,
13731  respectively).
13732  This \SpecialChar TeX
13733  code must have the form 
13734 \family typewriter
13735
13736 \backslash
13737 markboth{Authors' Names}{Short Paper's Title}
13738 \family default
13739 .
13740 \change_unchanged
13741
13742 \end_layout
13743
13744 \begin_layout Section
13745 iopart
13746 \end_layout
13747
13748 \begin_layout Standard
13749 by 
13750 \noun on
13751 Uwe Stöhr
13752 \end_layout
13753
13754 \begin_layout Subsection
13755 Overview
13756 \end_layout
13757
13758 \begin_layout Standard
13759 The iopart package provides a document class to create electronic manuscript
13760  submission to the journals published by the Institute of Physics.
13761  Instructions for the authors how to create a paper using the iopart class
13762  can be downloaded together with the iopart package from the site 
13763 \begin_inset Flex URL
13764 status collapsed
13765
13766 \begin_layout Plain Layout
13767
13768 ftp://ftp.iop.org/pub/journals/latex2e
13769 \end_layout
13770
13771 \end_inset
13772
13773 .
13774 \end_layout
13775
13776 \begin_layout Subsection
13777 Writing a paper
13778 \end_layout
13779
13780 \begin_layout Standard
13781 The easiest way to write a paper is to start with the 
13782 \change_deleted -712698321 1501162201
13783 file
13784 \change_inserted -712698321 1501162202
13785 template
13786 \change_unchanged
13787  
13788 \emph on
13789 IOP-article.lyx
13790 \emph default
13791  that is available 
13792 \change_deleted -712698321 1501162208
13793 in \SpecialChar LyX
13794 's examples files folder
13795 \change_inserted -712698321 1501162222
13796 via 
13797 \family sans
13798 File\SpecialChar menuseparator
13799 New From Template\SpecialChar ldots
13800
13801 \change_deleted -712698321 1501162219
13802
13803 \family default
13804 .
13805
13806 \change_unchanged
13807  
13808 \change_deleted -712698321 1501162234
13809 Open this file, save it under a new name, and start writing.
13810
13811 \change_unchanged
13812  The 
13813 \change_deleted -712698321 1501162238
13814 example file
13815 \change_inserted -712698321 1501162239
13816 template
13817 \change_unchanged
13818  explains how to use the special text environments.
13819  Here are the most important advices:
13820 \end_layout
13821
13822 \begin_layout Itemize
13823 To be able to compile your document to a PDF, PS, or DVI, ensure that the
13824  
13825 \change_deleted -712698321 1501162254
13826 two options 
13827 \family sans
13828 Use AMS math package
13829 \family default
13830  in the document settings under 
13831 \family sans
13832 Math Options
13833 \family default
13834  are not used
13835 \change_inserted -712698321 1501162277
13836 no AMS packages are loaded in 
13837 \family sans
13838 Document\SpecialChar menuseparator
13839 Settings\SpecialChar menuseparator
13840 Math Options
13841 \change_unchanged
13842
13843 \family default
13844 !
13845 \end_layout
13846
13847 \begin_layout Itemize
13848
13849 \size normal
13850 The title environment defines the kind of your paper.
13851  So use one of the following environments for the title:
13852 \end_layout
13853
13854 \begin_deeper
13855 \begin_layout Itemize
13856
13857 \family sans
13858 \size normal
13859 Title
13860 \family default
13861  for a Paper
13862 \end_layout
13863
13864 \begin_layout Itemize
13865
13866 \family sans
13867 \size normal
13868 Review
13869 \family default
13870  for a Review
13871 \end_layout
13872
13873 \begin_layout Itemize
13874
13875 \family sans
13876 \size normal
13877 Topical
13878 \family default
13879  for a Topical review
13880 \end_layout
13881
13882 \begin_layout Itemize
13883
13884 \family sans
13885 \size normal
13886 Comment
13887 \family default
13888  for a Comment
13889 \end_layout
13890
13891 \begin_layout Itemize
13892
13893 \family sans
13894 \size normal
13895 Note
13896 \family default
13897  for a Note
13898 \end_layout
13899
13900 \begin_layout Itemize
13901
13902 \family sans
13903 \size normal
13904 Paper
13905 \family default
13906  for a Paper (same as Title)
13907 \end_layout
13908
13909 \begin_layout Itemize
13910
13911 \family sans
13912 \size normal
13913 Prelim
13914 \family default
13915  for a Preliminary communication
13916 \end_layout
13917
13918 \begin_layout Itemize
13919
13920 \family sans
13921 \size normal
13922 Rapid
13923 \family default
13924  for a Rapid communication
13925 \end_layout
13926
13927 \begin_layout Itemize
13928
13929 \family sans
13930 \size normal
13931 Letter
13932 \family default
13933  for a Letter to the editor
13934 \end_layout
13935
13936 \end_deeper
13937 \begin_layout Itemize
13938
13939 \size normal
13940 All title environments except of 
13941 \family sans
13942 Letter
13943 \family default
13944  can have an optional short title.
13945 \end_layout
13946
13947 \begin_layout Itemize
13948 There is a general title environment 
13949 \family sans
13950 Article
13951 \family default
13952  which is not directly supported by
13953 \change_deleted -712698321 1501162663
13954  the
13955 \change_unchanged
13956  \SpecialChar LyX
13957 .
13958  This can be used as \SpecialChar TeX
13959  code when your document doesn't fit into one of the
13960  other title types.
13961 \end_layout
13962
13963 \begin_layout Standard
13964 For more informations like hints for special table and formula formatting,
13965  look at the IOP author guidelines.
13966 \end_layout
13967
13968 \begin_layout Section
13969 Kluwer
13970 \end_layout
13971
13972 \begin_layout Standard
13973 by 
13974 \noun on
13975 Panayotis Papasotiriou
13976 \end_layout
13977
13978 \begin_layout Subsection
13979 Overview
13980 \end_layout
13981
13982 \begin_layout Standard
13983 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
13984  that facilitates electronic manuscript submission to the journals they
13985  publish.
13986  Most known of them (at least in my domain of interest) are 
13987 \emph on
13988 Astrophysics and Space Science
13989 \emph default
13990  and 
13991 \emph on
13992 Solar Physics
13993 \emph default
13994 , but there are many others (see a complete list at 
13995 \begin_inset Flex URL
13996 status collapsed
13997
13998 \begin_layout Plain Layout
13999
14000 http://www.wkap.nl/jrnllist.htm/JRNLHOME
14001 \end_layout
14002
14003 \end_inset
14004
14005 ).
14006  The Kluwer package may be downloaded from the site 
14007 \begin_inset Flex URL
14008 status collapsed
14009
14010 \begin_layout Plain Layout
14011
14012 http://www.wkap.nl/kaphtml.htm/STYLEFILES
14013 \end_layout
14014
14015 \end_inset
14016
14017 .
14018  A complete user guide is contained in that package (but it can also be
14019  downloaded separately).
14020 \end_layout
14021
14022 \begin_layout Standard
14023 \SpecialChar LyX
14024  supports many features of the package but not everything.
14025  However, the \SpecialChar TeX
14026  code needed is reduced to some 
14027 \begin_inset Quotes eld
14028 \end_inset
14029
14030 peculiar
14031 \begin_inset Quotes erd
14032 \end_inset
14033
14034  commands of the package (see
14035 \begin_inset space ~
14036 \end_inset
14037
14038
14039 \begin_inset CommandInset ref
14040 LatexCommand ref
14041 reference "subsec:kluwer_peculiarities"
14042
14043 \end_inset
14044
14045 ).
14046  I have recently used \SpecialChar LyX
14047  to write an article submitted to the 
14048 \emph on
14049 Astrophysics and Space Science
14050 \emph default
14051  without any problem.
14052 \end_layout
14053
14054 \begin_layout Subsection
14055 Writing a paper
14056 \end_layout
14057
14058 \begin_layout Standard
14059 The easiest way to write a paper is to start with the Kluwer template file.
14060  Click on 
14061 \family sans
14062 File\SpecialChar menuseparator
14063 New from
14064 \family default
14065  
14066 \family sans
14067 Template
14068 \family default
14069 , then choose the 
14070 \family typewriter
14071 kluwer.lyx
14072 \family default
14073  template.
14074  This will give an (almost) empty document that includes the most common
14075  fields found in a manuscript and a short description of their use.
14076  As in most templates, simply overwrite the existing text (including the
14077  brackets, 
14078 \family typewriter
14079 <>
14080 \family default
14081 ) with the correct information.
14082 \end_layout
14083
14084 \begin_layout Subsection
14085 Preparing a paper for submission
14086 \end_layout
14087
14088 \begin_layout Standard
14089 As in the AAS\SpecialChar TeX
14090  package, before you submit your paper to a journal you must
14091  
14092 \begin_inset Quotes eld
14093 \end_inset
14094
14095 postprocess
14096 \begin_inset Quotes erd
14097 \end_inset
14098
14099  it as follows.
14100 \end_layout
14101
14102 \begin_layout Enumerate
14103 Export your paper as a \SpecialChar LaTeX
14104  file.
14105  To do this, click on 
14106 \family sans
14107 File\SpecialChar menuseparator
14108 Export\SpecialChar menuseparator
14109 \SpecialChar LaTeX
14110
14111 \family default
14112 .
14113  
14114 \end_layout
14115
14116 \begin_layout Enumerate
14117 Edit the resulting 
14118 \family typewriter
14119 .tex
14120 \family default
14121  file with a text editor and make the following changes
14122 \end_layout
14123
14124 \begin_deeper
14125 \begin_layout Enumerate
14126 remove the comment lines before the 
14127 \family typewriter
14128
14129 \backslash
14130 documentclass
14131 \family default
14132  command,
14133 \end_layout
14134
14135 \begin_layout Enumerate
14136 remove everything between (and including) the 
14137 \family typewriter
14138
14139 \backslash
14140 makeatletter
14141 \family default
14142  and 
14143 \family typewriter
14144
14145 \backslash
14146 makeatother
14147 \family default
14148  commands, except for any commands you specifically put into the \SpecialChar LaTeX
14149  preamble.
14150 \end_layout
14151
14152 \begin_layout Standard
14153 Save the resulting 
14154 \family typewriter
14155 .tex
14156 \family default
14157  file.
14158 \end_layout
14159
14160 \end_deeper
14161 \begin_layout Enumerate
14162 Run the 
14163 \family typewriter
14164 .tex
14165 \family default
14166  file through \SpecialChar LaTeX
14167  as many times as necessary (usually up to three).
14168 \end_layout
14169
14170 \begin_layout Enumerate
14171 View the resulting 
14172 \family typewriter
14173 .dvi
14174 \family default
14175  document using, e.
14176 \begin_inset space \thinspace{}
14177 \end_inset
14178
14179 g.
14180 \begin_inset space \space{}
14181 \end_inset
14182
14183
14184 \family sans
14185 xdvi
14186 \family default
14187 , and check if everything is OK (it should, if you didn't make any mistake).
14188 \end_layout
14189
14190 \begin_layout Subsection
14191 \begin_inset Quotes eld
14192 \end_inset
14193
14194 Peculiarities
14195 \begin_inset Quotes erd
14196 \end_inset
14197
14198  of the Kluwer package
14199 \begin_inset CommandInset label
14200 LatexCommand label
14201 name "subsec:kluwer_peculiarities"
14202
14203 \end_inset
14204
14205
14206 \end_layout
14207
14208 \begin_layout Standard
14209 The Kluwer package has the following 
14210 \begin_inset Quotes eld
14211 \end_inset
14212
14213 peculiarities
14214 \begin_inset Quotes erd
14215 \end_inset
14216
14217 .
14218 \end_layout
14219
14220 \begin_layout Enumerate
14221 It is possible to write multiple articles in the same \SpecialChar LaTeX
14222  file
14223 \begin_inset Foot
14224 status collapsed
14225
14226 \begin_layout Plain Layout
14227 I can't imagine any good reason to do this.
14228 \end_layout
14229
14230 \end_inset
14231
14232 .
14233  Each article must be included in the environment 
14234 \begin_inset Quotes eld
14235 \end_inset
14236
14237 article
14238 \begin_inset Quotes erd
14239 \end_inset
14240
14241 .
14242  Unfortunately, this environment cannot be omitted, even if you write just
14243  one article.
14244  Therefore, each article starts with the command 
14245 \family typewriter
14246
14247 \backslash
14248 begin{article}
14249 \family default
14250  and, obviously, ends with the command 
14251 \family typewriter
14252
14253 \backslash
14254 end{article}
14255 \family default
14256 .
14257  Although this can be implemented in \SpecialChar LyX
14258 , I didn't included it, since it looks
14259  ugly and can confuse the novice user.
14260  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
14261  code (the
14262  well-known 
14263 \begin_inset Quotes eld
14264 \end_inset
14265
14266 \SpecialChar TeX
14267  code
14268 \begin_inset Quotes erd
14269 \end_inset
14270
14271 ).
14272 \end_layout
14273
14274 \begin_layout Enumerate
14275 Information given at the beginning of the article (i.
14276 \begin_inset space \thinspace{}
14277 \end_inset
14278
14279 e.
14280 \begin_inset space \space{}
14281 \end_inset
14282
14283 title, subtitle, author, institution, running title, running author, abstract
14284  and keywords) must be included in an environment called 
14285 \begin_inset Quotes eld
14286 \end_inset
14287
14288 opening
14289 \begin_inset Quotes erd
14290 \end_inset
14291
14292 .
14293  This is not implemented in \SpecialChar LyX
14294 , so you must enter title, subtitle etc.
14295 \begin_inset space ~
14296 \end_inset
14297
14298 between two \SpecialChar TeX
14299  code lines (
14300 \family typewriter
14301
14302 \backslash
14303 begin{opening}
14304 \family default
14305  and 
14306 \family typewriter
14307
14308 \backslash
14309 end{opening}
14310 \family default
14311 ).
14312 \end_layout
14313
14314 \begin_layout Enumerate
14315 According to the user manual, the label of each bibliography item must be
14316  written as 
14317 \family typewriter
14318
14319 \backslash
14320 protect
14321 \backslash
14322 citeauthoryear{
14323 \family default
14324 \emph on
14325 author(s)
14326 \family typewriter
14327 \emph default
14328 }{
14329 \family default
14330 \emph on
14331 year
14332 \family typewriter
14333 \emph default
14334 }
14335 \family default
14336 .
14337 \end_layout
14338
14339 \begin_layout Standard
14340 The 
14341 \family typewriter
14342 kluwer.lyx
14343 \family default
14344  template takes care of all these 
14345 \begin_inset Quotes eld
14346 \end_inset
14347
14348 peculiarities
14349 \begin_inset Quotes erd
14350 \end_inset
14351
14352 .
14353  If you start a new paper using this template you don't need to do anything
14354  special.
14355  Just 
14356 \end_layout
14357
14358 \begin_layout Enumerate
14359 don't delete the \SpecialChar TeX
14360  code included in the template, and
14361 \end_layout
14362
14363 \begin_layout Enumerate
14364 copy the example bibliography item included in the template and modify it
14365  as necessary to enter new bibliography items.
14366 \end_layout
14367
14368 \begin_layout Section
14369 Koma-Script
14370 \end_layout
14371
14372 \begin_layout Standard
14373 by 
14374 \noun on
14375 Bernd Rellermeyer
14376 \end_layout
14377
14378 \begin_layout Subsection
14379 Overview
14380 \end_layout
14381
14382 \begin_layout Standard
14383 The \SpecialChar LyX
14384  document classes 
14385 \emph on
14386 article (koma-script)
14387 \emph default
14388
14389 \emph on
14390 report (koma-script)
14391 \emph default
14392
14393 \emph on
14394 book
14395 \emph default
14396  
14397 \emph on
14398 (koma-script)
14399 \emph default
14400 , and 
14401 \emph on
14402 letter
14403 \emph default
14404  
14405 \emph on
14406 (koma-script)
14407 \emph default
14408  correspond to the \SpecialChar LaTeX
14409  document classes 
14410 \family typewriter
14411 scrartcl.cls
14412 \family default
14413
14414 \family typewriter
14415 scrreprt.cls
14416 \family default
14417
14418 \family typewriter
14419 scrbook.cls
14420 \family default
14421 , and 
14422 \family typewriter
14423 scrlettr.cls
14424 \family default
14425 , resp.
14426 \begin_inset space ~
14427 \end_inset
14428
14429 of the Koma-Script family.
14430  They are replacements for the standard document classes 
14431 \family typewriter
14432 article.cls
14433 \family default
14434
14435 \family typewriter
14436 report.cls
14437 \family default
14438
14439 \family typewriter
14440 book.cls
14441 \family default
14442  and 
14443 \family typewriter
14444 letter.cls
14445 \family default
14446 , resp., and fit better to European typography conventions in a number of
14447  points.
14448 \end_layout
14449
14450 \begin_layout Itemize
14451 Standard character size is 11pt in 
14452 \emph on
14453 article (koma-script)
14454 \emph default
14455
14456 \emph on
14457 report (koma-script)
14458 \emph default
14459 , and 
14460 \emph on
14461 book (koma-script)
14462 \emph default
14463 , and 12pt in 
14464 \emph on
14465 letter (koma-script)
14466 \emph default
14467 .
14468 \end_layout
14469
14470 \begin_layout Itemize
14471 Headings, labels of the description environment, and a number of elements
14472  of the 
14473 \emph on
14474 letter (koma-script)
14475 \emph default
14476  document class are set in a bold sans serif font.
14477 \begin_inset Foot
14478 status collapsed
14479
14480 \begin_layout Plain Layout
14481 There is a big difference between the bold sans serif old cm fonts and new
14482  ec fonts, especially in the appearance of headings.
14483  In comparison, the ec bold sans serif fonts look a bit thin.
14484  Here the \SpecialChar LaTeX
14485  package 
14486 \family typewriter
14487 cmsd.sty by
14488 \family default
14489  
14490 \shape smallcaps
14491 Walter Schmidt
14492 \shape default
14493  helps to produce the 
14494 \begin_inset Quotes eld
14495 \end_inset
14496
14497 usual
14498 \begin_inset Quotes erd
14499 \end_inset
14500
14501  appearance when using the ec fonts.
14502 \end_layout
14503
14504 \end_inset
14505
14506  The numbering of chapter headings is made in the same way as the numbering
14507  of section headings, that is without the extra line 
14508 \begin_inset Quotes eld
14509 \end_inset
14510
14511 Chapter\SpecialChar ldots
14512
14513 \begin_inset Quotes erd
14514 \end_inset
14515
14516 .
14517  In addition, the appearance of the headings can be modified by using a
14518  number of options (in \SpecialChar LyX
14519  to be entered in the field 
14520 \family sans
14521 Extra
14522 \begin_inset space ~
14523 \end_inset
14524
14525 Options
14526 \family default
14527  of the dialog 
14528 \family sans
14529 Layout\SpecialChar menuseparator
14530 Document
14531 \family default
14532 ).
14533  
14534 \end_layout
14535
14536 \begin_layout Itemize
14537 The main means in the Koma-Script document classes to design the type area
14538  are the options 
14539 \family sans
14540 BCOR
14541 \family default
14542  and 
14543 \family sans
14544 DIV
14545 \family default
14546  (in \SpecialChar LyX
14547  to be entered in the extra class options field in the dialog 
14548 \family sans
14549 Document\SpecialChar menuseparator
14550 Settings
14551 \family default
14552 ).
14553  They make a clearer modification of page margins possible as do the options
14554  of the dialog 
14555 \family sans
14556 Document\SpecialChar menuseparator
14557 Settings
14558 \family default
14559 .
14560  
14561 \end_layout
14562
14563 \begin_layout Itemize
14564 The \SpecialChar LaTeX
14565  document classes of the Koma-Script family define a number of additional
14566  commands.
14567  Those part of it which makes sense in \SpecialChar LyX
14568  is implemented in corresponding
14569  paragraph types.
14570 \end_layout
14571
14572 \begin_layout Standard
14573 Detailed descriptions of the \SpecialChar LaTeX
14574  document classes of the Koma-Script family
14575  can be found in the Koma-Script documentation 
14576 \emph on
14577 scrguide
14578 \emph default
14579  (German) and 
14580 \emph on
14581 scrguien
14582 \emph default
14583  (English).
14584 \end_layout
14585
14586 \begin_layout Subsection
14587 article (koma-script), report (koma-script), and book (koma-script)
14588 \end_layout
14589
14590 \begin_layout Standard
14591 The document classes 
14592 \emph on
14593 article (koma-script)
14594 \emph default
14595
14596 \emph on
14597 report (koma-script)
14598 \emph default
14599 , and 
14600 \emph on
14601 book
14602 \emph default
14603  
14604 \emph on
14605 (koma-script)
14606 \emph default
14607  are implemented in the layout files 
14608 \family typewriter
14609 scrartcl.layout
14610 \family default
14611
14612 \family typewriter
14613 scrreprt.layout
14614 \family default
14615 , and 
14616 \family typewriter
14617 scrbook.layout
14618 \family default
14619 , resp.
14620  They contain all the paragraph types of the corresponding standard document
14621  classes 
14622 \emph on
14623 article
14624 \emph default
14625
14626 \emph on
14627 report
14628 \emph default
14629 , and 
14630 \emph on
14631 book
14632 \emph default
14633 , resp., partly modified, with the exception of the \SpecialChar LyX
14634  specific 
14635 \family sans
14636 List
14637 \family default
14638 -type, which is replaced by the new 
14639 \family sans
14640 Labeling
14641 \family default
14642 -type having the same functionality.
14643  Beside the 
14644 \family sans
14645 Labeling
14646 \family default
14647 -Type there is a number of new paragraph types added.
14648  They are 
14649 \emph on
14650 not
14651 \emph default
14652  part of 
14653 \emph on
14654 letter (koma-script)
14655 \emph default
14656 .
14657 \end_layout
14658
14659 \begin_layout Itemize
14660
14661 \family sans
14662 Addpart, Addchap
14663 \family default
14664
14665 \family sans
14666 Addsec
14667 \family default
14668 : are equivalents to 
14669 \family sans
14670 Part*, Chapter*
14671 \family default
14672  and 
14673 \family sans
14674 Section*
14675 \family default
14676 , resp., additionally inserting an entry in the table of contents.
14677  
14678 \family sans
14679 Addpart
14680 \family default
14681  and 
14682 \family sans
14683 Addchap
14684 \family default
14685  are not contained in 
14686 \emph on
14687 article (koma-script)
14688 \emph default
14689 .
14690 \end_layout
14691
14692 \begin_layout Itemize
14693
14694 \family sans
14695 Addchap*
14696 \family default
14697
14698 \family sans
14699 Addsec*
14700 \family default
14701 : behave exactly as 
14702 \family sans
14703 Addchap
14704 \family default
14705  and 
14706 \family sans
14707 Addsec
14708 \family default
14709 , resp., additionally clearing running heads.
14710  
14711 \family sans
14712 Addchap*
14713 \family default
14714  is not contained in 
14715 \emph on
14716 article (koma-script)
14717 \emph default
14718 .
14719 \begin_inset Foot
14720 status collapsed
14721
14722 \begin_layout Plain Layout
14723 There is also an 
14724 \family typewriter
14725
14726 \backslash
14727 addpart*
14728 \family default
14729  command in 
14730 \emph on
14731 book (koma-script)
14732 \emph default
14733  and in 
14734 \emph on
14735 report (koma-script)
14736 \emph default
14737 , but since this is identical to 
14738 \family sans
14739 Part*
14740 \family default
14741 , is has not been implemented in \SpecialChar LyX
14742 .
14743 \end_layout
14744
14745 \end_inset
14746
14747
14748 \end_layout
14749
14750 \begin_layout Itemize
14751
14752 \family sans
14753 Minisec
14754 \family default
14755 : generates a heading directly above the following paragraph in the standard
14756  character size without affecting the structure of the document.
14757 \end_layout
14758
14759 \begin_layout Itemize
14760
14761 \family sans
14762 Captionabove
14763 \family default
14764  and 
14765 \family sans
14766 Captionbelow
14767 \family default
14768  are special captions which respect the different space settings needed
14769  for captions placed above or below an element (if you follow strict typographic
14770  rules, you might want to place table captions always above the table).
14771  You can also use the class option 
14772 \family typewriter
14773 tablecaptionsabove
14774 \family default
14775 , which will switch 
14776 \family sans
14777 caption
14778 \family default
14779  to 
14780 \family sans
14781 captionabove
14782 \family default
14783  for tables and 
14784 \family sans
14785 captionbelow
14786 \family default
14787  for figures.
14788  You need at least Koma-Script version 2.8q to use this.
14789 \end_layout
14790
14791 \begin_layout Itemize
14792
14793 \family sans
14794 Dictum
14795 \family default
14796 : can be used to set a bonmot, e.
14797 \begin_inset space \thinspace{}
14798 \end_inset
14799
14800 g.
14801 \begin_inset space \space{}
14802 \end_inset
14803
14804 at the beginning of a chapter.
14805  If you use the optional argument (
14806 \family sans
14807 Insert\SpecialChar menuseparator
14808
14809 \change_deleted -712698321 1501163301
14810 Short
14811 \begin_inset space ~
14812 \end_inset
14813
14814 Title
14815 \change_inserted -712698321 1501163306
14816 Dictum
14817 \begin_inset space ~
14818 \end_inset
14819
14820 Author
14821 \change_unchanged
14822
14823 \family default
14824 ), you can insert the dictum's author there.
14825  Dictum and author are separated by a line.
14826  You need at least Koma-Script version 2.8q to use this.
14827  
14828 \family sans
14829 Dictum
14830 \family default
14831  is not contained in 
14832 \emph on
14833 article (koma-script)
14834 \emph default
14835 .
14836 \end_layout
14837
14838 \begin_layout Standard
14839 The following types, together with the standard types 
14840 \family sans
14841 Title
14842 \family default
14843
14844 \family sans
14845 Author
14846 \family default
14847 , and 
14848 \family sans
14849 Date
14850 \family default
14851 , form the title area of the document.
14852  They must be entered ahead of the first 
14853 \begin_inset Quotes eld
14854 \end_inset
14855
14856 ordinary
14857 \begin_inset Quotes erd
14858 \end_inset
14859
14860  paragraph.
14861 \begin_inset Foot
14862 status collapsed
14863
14864 \begin_layout Plain Layout
14865 The corresponding \SpecialChar LaTeX
14866  commands must appear before the 
14867 \family typewriter
14868
14869 \backslash
14870 maketitle
14871 \family default
14872  command.
14873 \end_layout
14874
14875 \end_inset
14876
14877  When such a type is used more than once, the latter usage overwrites the
14878  former one, that means, for every type only the latest usage is valid.
14879  The order of the different types however has, like 
14880 \family sans
14881 Title
14882 \family default
14883
14884 \family sans
14885 Author
14886 \family default
14887 , and 
14888 \family sans
14889 Date
14890 \family default
14891 , no effect on the appearance of the produced document.
14892 \end_layout
14893
14894 \begin_layout Itemize
14895
14896 \family sans
14897 Subject
14898 \family default
14899 : produces a centered paragraph above the ordinary title (
14900 \family sans
14901 Title
14902 \family default
14903
14904 \family sans
14905 Author
14906 \family default
14907
14908 \family sans
14909 Date
14910 \family default
14911 ) for the subject of the document.
14912 \end_layout
14913
14914 \begin_layout Itemize
14915
14916 \family sans
14917 Publishers
14918 \family default
14919 : produces a centered paragraph below the ordinary title (
14920 \family sans
14921 Title
14922 \family default
14923
14924 \family sans
14925 Author
14926 \family default
14927
14928 \family sans
14929 Date
14930 \family default
14931 ) for the publishers' name.
14932 \end_layout
14933
14934 \begin_layout Itemize
14935
14936 \family sans
14937 Dedication
14938 \family default
14939 : in 
14940 \emph on
14941 report (koma-script)
14942 \emph default
14943  and 
14944 \emph on
14945 book (koma-script)
14946 \emph default
14947  produces a centered paragraph on its own page behind the title page, or
14948  in 
14949 \emph on
14950 article (koma-script)
14951 \emph default
14952  produces a centered paragraph below the ordinary title (
14953 \family sans
14954 Title
14955 \family default
14956
14957 \family sans
14958 Author
14959 \family default
14960
14961 \family sans
14962 Date
14963 \family default
14964
14965 \family sans
14966 Publishers
14967 \family default
14968 ) for a dedication.
14969 \end_layout
14970
14971 \begin_layout Itemize
14972
14973 \family sans
14974 Titlehead
14975 \family default
14976 : produces a left aligned paragraph above the ordinary title (
14977 \family sans
14978 Title
14979 \family default
14980
14981 \family sans
14982 Author
14983 \family default
14984
14985 \family sans
14986 Date
14987 \family default
14988
14989 \family sans
14990 Subject
14991 \family default
14992 ) for a document`s head.
14993 \end_layout
14994
14995 \begin_layout Itemize
14996
14997 \family sans
14998 Uppertitleback
14999 \family default
15000 : produces in a double-sided print in 
15001 \emph on
15002 report (koma-script)
15003 \emph default
15004  and 
15005 \emph on
15006 book (koma-script)
15007 \emph default
15008  a left-aligned paragraph at the top of the title page`s back or has no
15009  effect in a single-sided print or in 
15010 \emph on
15011 article (koma-script)
15012 \emph default
15013 .
15014 \end_layout
15015
15016 \begin_layout Itemize
15017
15018 \family sans
15019 Lowertitleback
15020 \family default
15021 : produces in a double-sided print in 
15022 \emph on
15023 report (koma-script)
15024 \emph default
15025  and 
15026 \emph on
15027 book (koma-script)
15028 \emph default
15029  a left-aligned paragraph at the bottom of the title page`s back or has
15030  no effect in a single-sided print or in 
15031 \emph on
15032 article (koma-script)
15033 \emph default
15034 .
15035 \end_layout
15036
15037 \begin_layout Itemize
15038
15039 \family sans
15040 Extratitle
15041 \family default
15042 : produces a special 
15043 \begin_inset Quotes eld
15044 \end_inset
15045
15046 dirty
15047 \begin_inset Quotes erd
15048 \end_inset
15049
15050  page ahead of the actual document containing a paragraph without special
15051  formatting.
15052 \end_layout
15053
15054 \begin_layout Standard
15055 The layout files for the document classes 
15056 \emph on
15057 article (koma-script)
15058 \emph default
15059
15060 \emph on
15061 report (koma-script)
15062 \emph default
15063 , and 
15064 \emph on
15065 book (koma-script)
15066 \emph default
15067  do include the file 
15068 \family typewriter
15069 scrmacros.inc
15070 \family default
15071 .
15072  This is thought of as a place to define your own types.
15073  Copy scrmacros
15074 \family typewriter
15075 .inc
15076 \family default
15077  in your personal layout directory and edit the file!
15078 \end_layout
15079
15080 \begin_layout Subsection
15081 letter (koma-script)
15082 \end_layout
15083
15084 \begin_layout Description
15085
15086 \change_inserted -712698321 1501163945
15087 Note: This section discusses the obsolete 
15088 \family sans
15089 KOMA-Script-Letter (v.
15090 \begin_inset space ~
15091 \end_inset
15092
15093 1)
15094 \family default
15095 , which is not even included anymore in recent KOMA releases.
15096  Please refer to the next section for the current KOMA-Script-Letter class
15097  (v.
15098 \begin_inset space ~
15099 \end_inset
15100
15101 2)!
15102 \end_layout
15103
15104 \begin_layout Standard
15105 \noindent
15106 The document class 
15107 \emph on
15108 letter (koma-script)
15109 \emph default
15110  is implemented in the layout file 
15111 \family typewriter
15112 scrlettr.layout
15113 \family default
15114 .
15115  It contains all the paragraph types of the corresponding standard document
15116  class 
15117 \emph on
15118 letter
15119 \emph default
15120 , partly modified, with the exception of the \SpecialChar LyX
15121  specific types 
15122 \family sans
15123 \SpecialChar LyX
15124 -Code
15125 \family default
15126  and 
15127 \family sans
15128 Comment
15129 \family default
15130  and the 
15131 \family sans
15132 List
15133 \family default
15134  type, which is replaced by the new 
15135 \family sans
15136 Labeling
15137 \family default
15138  type.
15139  In addition, it contains, in contrast to the standard document class, the
15140  standard types 
15141 \family sans
15142 \SpecialChar LaTeX
15143
15144 \family default
15145
15146 \family sans
15147 Quotation
15148 \family default
15149
15150 \family sans
15151 Quote
15152 \family default
15153 , and 
15154 \family sans
15155 Verse
15156 \family default
15157 .
15158  Furthermore, there are a number of new letter specific types.
15159 \end_layout
15160
15161 \begin_layout Standard
15162 The appearance of the letter produced by this document class can be controlled
15163  by a number of \SpecialChar LaTeX
15164  commands, which you can put in the \SpecialChar LaTeX
15165  preamble.
15166 \begin_inset Foot
15167 status collapsed
15168
15169 \begin_layout Plain Layout
15170 For example, the standard appearance of the letter`s heading, consisting
15171  of name and address, is quite self-willed.
15172  An 
15173 \begin_inset Quotes eld
15174 \end_inset
15175
15176 ordinary
15177 \begin_inset Quotes erd
15178 \end_inset
15179
15180  heading is produced by the following \SpecialChar LaTeX
15181  commands in the preamble:
15182 \end_layout
15183
15184 \begin_layout LyX-Code
15185
15186 \backslash
15187 firsthead{
15188 \backslash
15189 parbox[b]{
15190 \backslash
15191 textwidth}
15192 \end_layout
15193
15194 \begin_layout LyX-Code
15195   {
15196 \backslash
15197 ignorespaces 
15198 \backslash
15199 fromname
15200 \backslash
15201
15202 \backslash
15203  
15204 \backslash
15205 ignorespaces 
15206 \backslash
15207 fromaddress}} 
15208 \end_layout
15209
15210 \begin_layout LyX-Code
15211
15212 \backslash
15213 nexthead{
15214 \backslash
15215 parbox[b]{
15216 \backslash
15217 textwidth}
15218 \end_layout
15219
15220 \begin_layout LyX-Code
15221   {
15222 \backslash
15223 ignorespaces 
15224 \backslash
15225 fromname 
15226 \backslash
15227 hfill 
15228 \backslash
15229 ignorespaces 
15230 \backslash
15231 pagename
15232 \backslash
15233  
15234 \backslash
15235 thepage}}
15236 \end_layout
15237
15238 \end_inset
15239
15240  A detailed German description of such \SpecialChar LaTeX
15241  commands can be found in the Koma-Script
15242  documentation 
15243 \emph on
15244 scrguide
15245 \emph default
15246 .
15247  With it, the letter's author can produce his personal letter layout.
15248 \end_layout
15249
15250 \begin_layout Standard
15251 The types 
15252 \family sans
15253 Letter
15254 \family default
15255  and 
15256 \family sans
15257 Opening
15258 \family default
15259  define the beginning of the letter and must be used in every letter.
15260  To emphasize them in the \SpecialChar LyX
15261  document class, they are marked with the letter
15262  
15263 \shape italic
15264 L
15265 \shape default
15266  or 
15267 \shape italic
15268 O
15269 \shape default
15270 , resp.
15271 \begin_inset space ~
15272 \end_inset
15273
15274 in the left margin.
15275  It is possible to write any number of letters in one file.
15276  An 
15277 \family sans
15278 Opening
15279 \family default
15280  type produces a new letter using the same addressee and a 
15281 \family sans
15282 Letter
15283 \family default
15284  type produces a new addressee.
15285  The types 
15286 \family sans
15287 Closing
15288 \family default
15289
15290 \family sans
15291 PS
15292 \family default
15293
15294 \family sans
15295 CC
15296 \family default
15297 , and 
15298 \family sans
15299 Encl
15300 \family default
15301  are ordinary paragraph types and can also be used several times in one
15302  and the same letter.
15303 \end_layout
15304
15305 \begin_layout Itemize
15306
15307 \family sans
15308 Letter
15309 \family default
15310 : produces a paragraph for the addressee and implicitly defines the beginning
15311  of the letter.
15312 \end_layout
15313
15314 \begin_layout Itemize
15315
15316 \family sans
15317 Opening
15318 \family default
15319 : produces a paragraph for the form of address and implicitly produces a
15320  new letter.
15321 \end_layout
15322
15323 \begin_layout Itemize
15324
15325 \family sans
15326 Closing
15327 \family default
15328 : produces a paragraph for a close.
15329 \end_layout
15330
15331 \begin_layout Itemize
15332
15333 \family sans
15334 PS
15335 \family default
15336 : produces a paragraph for a postscript.
15337 \end_layout
15338
15339 \begin_layout Itemize
15340
15341 \family sans
15342 CC
15343 \family default
15344 : produces a paragraph for a distribution list.
15345 \end_layout
15346
15347 \begin_layout Itemize
15348
15349 \family sans
15350 Encl
15351 \family default
15352 : produces a paragraph for enclosures.
15353 \end_layout
15354
15355 \begin_layout Standard
15356 The types 
15357 \family sans
15358 Name
15359 \family default
15360
15361 \family sans
15362 Signature
15363 \family default
15364
15365 \family sans
15366 Address
15367 \family default
15368
15369 \family sans
15370 Telephone
15371 \family default
15372
15373 \family sans
15374 Place
15375 \family default
15376
15377 \family sans
15378 Backaddress
15379 \family default
15380
15381 \family sans
15382 Specialmail
15383 \family default
15384
15385 \family sans
15386 Location
15387 \family default
15388
15389 \family sans
15390 Title
15391 \family default
15392 , and 
15393 \family sans
15394 Subject
15395 \family default
15396  are input types provided with a label to enter information, which will
15397  be processed by the document class.
15398 \begin_inset Foot
15399 status collapsed
15400
15401 \begin_layout Plain Layout
15402 It could be seen as a matter of inconsequence, that the types 
15403 \family sans
15404 Letter
15405 \family default
15406  and 
15407 \family sans
15408 Opening
15409 \family default
15410  described above are not such input types as well.
15411  Because of the special meaning of those types, however, I have implemented
15412  them as ordinary paragraph types with a one letter mark in the left margin.
15413  Moreover, it would affect my feeling of symmetry, if the 
15414 \family sans
15415 Opening
15416 \family default
15417  type and the 
15418 \family sans
15419 Closing
15420 \family default
15421  type had such a serious different appearance.
15422 \end_layout
15423
15424 \end_inset
15425
15426  The types must be used ahead of the corresponding 
15427 \family sans
15428 Opening
15429 \family default
15430  type.
15431 \end_layout
15432
15433 \begin_layout Standard
15434 An implementation of these types in a WYSIWYG fashion does not seem to make
15435  sense, because the real appearance of the produced letter does not only
15436  depend on the usage of the particular type, but also on other factors.
15437  For example, a signature entered in the 
15438 \family sans
15439 Signature
15440 \family default
15441  type will in the standard behavior appear in the produced letter only,
15442  when in the same letter also a 
15443 \family sans
15444 Closing
15445 \family default
15446  type is used.
15447  The entered value of the 
15448 \family sans
15449 Telephone
15450 \family default
15451  type will in the standard behavior not appear in the produced letter at
15452  all.
15453  The possibility to design the letter`s heading freely is already indicated
15454  in a footnote above.
15455 \end_layout
15456
15457 \begin_layout Standard
15458 The input types can also be used as empty paragraphs.
15459  This makes sense e.
15460 \begin_inset space \thinspace{}
15461 \end_inset
15462
15463 g.
15464 \begin_inset space \space{}
15465 \end_inset
15466
15467 for the 
15468 \family sans
15469 Signature
15470 \family default
15471  type.
15472  If the 
15473 \family sans
15474 Signature
15475 \family default
15476  type is not used at all, in the standard behavior the value of the 
15477 \family sans
15478 Name
15479 \family default
15480  type is used as signature, whereas if an empty 
15481 \family sans
15482 Signature
15483 \family default
15484  type is used, no signature value is defined.
15485 \end_layout
15486
15487 \begin_layout Standard
15488 By using the input types it is possible to write a letter template, containing
15489  filled input types with your personal dates (name, address, etc.) and empty
15490  input types for other dates you want to enter.
15491 \end_layout
15492
15493 \begin_layout Itemize
15494
15495 \family sans
15496 Name
15497 \family default
15498 : sender's name, in the standard behavior appears as a centered paragraph
15499  in small caps in the letter`s heading.
15500 \end_layout
15501
15502 \begin_layout Itemize
15503
15504 \family sans
15505 Signature
15506 \family default
15507 : sender's signature, in the standard behavior appears below the 
15508 \family sans
15509 Closing
15510 \family default
15511  type.
15512  If no 
15513 \family sans
15514 Signature
15515 \family default
15516  type is used, the value of the 
15517 \family sans
15518 Name
15519 \family default
15520  type appears instead.
15521 \end_layout
15522
15523 \begin_layout Itemize
15524
15525 \family sans
15526 Address
15527 \family default
15528 : sender's address, in the standard behavior appears in a centered paragraph
15529  in the letter`s heading below the sender's name.
15530 \end_layout
15531
15532 \begin_layout Itemize
15533
15534 \family sans
15535 Telephone
15536 \family default
15537 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
15538  variable
15539  
15540 \family typewriter
15541
15542 \backslash
15543 telephonenum
15544 \family default
15545 .
15546 \end_layout
15547
15548 \begin_layout Itemize
15549
15550 \family sans
15551 Place
15552 \family default
15553 : place of the letter`s making.
15554 \end_layout
15555
15556 \begin_layout Itemize
15557
15558 \family sans
15559 Date
15560 \family default
15561 : date of the letter`s making.
15562  
15563 \family sans
15564 Place
15565 \family default
15566  and 
15567 \family sans
15568 Date
15569 \family default
15570 , in the standard behavior, produce the place and the date in a right-aligned
15571  line below the addressee's field.
15572  If an empty 
15573 \family sans
15574 Date
15575 \family default
15576  type is used, neither place nor date appear, independent of the value of
15577  the 
15578 \family sans
15579 Place
15580 \family default
15581  type.
15582  If no 
15583 \family sans
15584 Date
15585 \family default
15586  type is used, the date of the letter `s production is used.
15587 \end_layout
15588
15589 \begin_layout Itemize
15590
15591 \family sans
15592 Backaddress
15593 \family default
15594 : sender`s back address, in the standard behavior appears above the addressee's
15595  field in a small sans serif font.
15596 \end_layout
15597
15598 \begin_layout Itemize
15599
15600 \family sans
15601 Specialmail
15602 \family default
15603 : special mail information, in the standard behavior appears underlined
15604  above the addressee's field below the back address.
15605 \end_layout
15606
15607 \begin_layout Itemize
15608
15609 \family sans
15610 Location
15611 \family default
15612 : additional information, in the standard behavior appears on right side
15613  below the addressee`s field.
15614 \end_layout
15615
15616 \begin_layout Itemize
15617
15618 \family sans
15619 Title
15620 \family default
15621 : the letter's title, in the standard behavior appears in a big, bold, sans
15622  serif font above the subject.
15623 \end_layout
15624
15625 \begin_layout Itemize
15626
15627 \family sans
15628 Subject
15629 \family default
15630 : the letter's subject, in the standard behavior appears in a bold font
15631  above the 
15632 \family sans
15633 Opening
15634 \family default
15635  paragraph.
15636 \end_layout
15637
15638 \begin_layout Standard
15639 The types 
15640 \family sans
15641 Yourref
15642 \family default
15643
15644 \family sans
15645 Yourmail
15646 \family default
15647
15648 \family sans
15649 Myref
15650 \family default
15651
15652 \family sans
15653 Customer
15654 \family default
15655 , and 
15656 \family sans
15657 Invoice
15658 \family default
15659  produce a business letter like line above the 
15660 \family sans
15661 Title
15662 \family default
15663  line containing the fields 
15664 \begin_inset Quotes eld
15665 \end_inset
15666
15667 Your ref.
15668 \begin_inset Quotes erd
15669 \end_inset
15670
15671
15672 \begin_inset Quotes eld
15673 \end_inset
15674
15675 Your letter of
15676 \begin_inset Quotes erd
15677 \end_inset
15678
15679
15680 \begin_inset Quotes eld
15681 \end_inset
15682
15683 Our ref.
15684 \begin_inset Quotes erd
15685 \end_inset
15686
15687
15688 \begin_inset Quotes eld
15689 \end_inset
15690
15691 Customer no.
15692 \begin_inset Quotes erd
15693 \end_inset
15694
15695
15696 \begin_inset Quotes eld
15697 \end_inset
15698
15699 Invoice no.
15700 \begin_inset Quotes erd
15701 \end_inset
15702
15703 , and 
15704 \begin_inset Quotes eld
15705 \end_inset
15706
15707 Date
15708 \begin_inset Quotes erd
15709 \end_inset
15710
15711 .
15712  For the date field, the value of the 
15713 \family sans
15714 Date
15715 \family default
15716  type is used.
15717  If one of these 
15718 \begin_inset Quotes eld
15719 \end_inset
15720
15721 business letter types
15722 \begin_inset Quotes erd
15723 \end_inset
15724
15725  is used, the value of the 
15726 \family sans
15727 Place
15728 \family default
15729  type however does not appear, but only the \SpecialChar LaTeX
15730  variable 
15731 \family typewriter
15732
15733 \backslash
15734 fromplace
15735 \family default
15736  is set.
15737  The ordinary output of place and date in a right-aligned line below the
15738  addressee`s field is suppressed.
15739  The types are implemented as input types provided with a label and must
15740  be used ahead of the corresponding 
15741 \family sans
15742 Opening
15743 \family default
15744  type.
15745 \end_layout
15746
15747 \begin_layout Itemize
15748
15749 \family sans
15750 Yourref
15751 \family default
15752 : Your ref.
15753 \end_layout
15754
15755 \begin_layout Itemize
15756
15757 \family sans
15758 Yourmail
15759 \family default
15760 : Your letter of.
15761 \end_layout
15762
15763 \begin_layout Itemize
15764
15765 \family sans
15766 Myref
15767 \family default
15768 : Our ref.
15769 \end_layout
15770
15771 \begin_layout Itemize
15772
15773 \family sans
15774 Customer
15775 \family default
15776 : Customer no.
15777 \end_layout
15778
15779 \begin_layout Itemize
15780
15781 \family sans
15782 Invoice
15783 \family default
15784 : Invoice no.
15785 \end_layout
15786
15787 \begin_layout Subsection
15788 The new letter class: letter (koma-script v.2)
15789 \end_layout
15790
15791 \begin_layout Standard
15792 by 
15793 \noun on
15794 Jürgen Spitzmüller
15795 \end_layout
15796
15797 \begin_layout Standard
15798 \begin_inset VSpace medskip
15799 \end_inset
15800
15801
15802 \end_layout
15803
15804 \begin_layout Standard
15805 \noindent
15806 Koma-Script version 2.8 has introduced a new letter class 
15807 \family typewriter
15808 scrlttr2
15809 \family default
15810  which supersedes the now unsupported 
15811 \family typewriter
15812 scrlettr
15813 \family default
15814 .
15815  It has — on the \SpecialChar LaTeX
15816  side — a completely new interface and is not compatible
15817  with the old class.
15818  Therefore, \SpecialChar LyX
15819  supports both, though it is recommended you use the new class.
15820 \end_layout
15821
15822 \begin_layout Standard
15823 This class covers the same functionality as 
15824 \emph on
15825 letter (koma-script),
15826 \emph default
15827  and a few more.
15828  The basic items are 
15829 \family sans
15830 Address
15831 \family default
15832  (receiver's address, same as 
15833 \family sans
15834 Letter
15835 \family default
15836  in the old layout), 
15837 \family sans
15838 Opening
15839 \family default
15840 , and 
15841 \family sans
15842 Closing
15843 \family default
15844 .
15845  
15846 \family sans
15847 NextAddress
15848 \family default
15849  will start a new letter (i.
15850 \begin_inset space \thinspace{}
15851 \end_inset
15852
15853 e.
15854 \begin_inset space \space{}
15855 \end_inset
15856
15857 you can write several letters per document).
15858  New elements are sender's 
15859 \family sans
15860 E-Mail
15861 \family default
15862
15863 \family sans
15864 URL
15865 \family default
15866
15867 \family sans
15868 Fax
15869 \family default
15870
15871 \family sans
15872 Bank
15873 \family default
15874  and the possibility to use a 
15875 \family sans
15876 Logo
15877 \family default
15878  (via 
15879 \family sans
15880 Insert\SpecialChar menuseparator
15881 Graphics
15882 \family default
15883 ) in the header.
15884 \end_layout
15885
15886 \begin_layout Standard
15887 The biggest improvement is, though, that the letter's layout is configurable
15888  to meet almost any needs.
15889  This can be done via the preamble or with a special style file (Letter
15890  Class Option, extension 
15891 \family typewriter
15892 *.lco
15893 \family default
15894 ), that will be read in as a class option.
15895 \begin_inset Foot
15896 status collapsed
15897
15898 \begin_layout Plain Layout
15899 The KOMA package comes with some default 
15900 \family typewriter
15901 *.lco
15902 \family default
15903  files.
15904  There is, for instance, a 
15905 \family typewriter
15906 DIN.lco
15907 \family default
15908  file that follows german typesetting rules, or a 
15909 \family typewriter
15910 KOMAold.lco
15911 \family default
15912  that provides the default layout of the old 
15913 \family typewriter
15914 scrlettr
15915 \family default
15916  class.
15917  The latter can be loaded with the class option 
15918 \family typewriter
15919 KOMAold
15920 \family default
15921 , inserted via the 
15922 \family sans
15923 Layout\SpecialChar menuseparator
15924 Document\SpecialChar menuseparator
15925 Extra Options
15926 \family default
15927  field.
15928 \end_layout
15929
15930 \end_inset
15931
15932  Have a look at the 
15933 \emph on
15934 koma-letter2
15935 \emph default
15936  template that is included in \SpecialChar LyX
15937  for examples.
15938  A detailed description is to be found in the Koma-Script documentation
15939  (
15940 \emph on
15941 scrguide
15942 \emph default
15943 ).
15944 \end_layout
15945
15946 \begin_layout Subsection
15947 Problems
15948 \end_layout
15949
15950 \begin_layout Standard
15951 Visualizing the Koma-Script document classes in \SpecialChar LyX
15952 , the \SpecialChar LyX
15953  internals cause some
15954  problems.
15955 \end_layout
15956
15957 \begin_layout Itemize
15958 The chapter number of a 
15959 \family sans
15960 Chapter
15961 \family default
15962  type appears on a line of its own above the chapter heading instead of
15963  appearing in the same line ahead of it.
15964  The cause for that is the \SpecialChar LyX
15965  internal behavior for the labeltype 
15966 \family sans
15967 Counter_Chapter
15968 \family default
15969  in the layout file.
15970 \end_layout
15971
15972 \begin_layout Itemize
15973 The headings of the types 
15974 \family sans
15975 Addchap
15976 \family default
15977  and 
15978 \family sans
15979 Addsec
15980 \family default
15981  are only put in the 
15982 \begin_inset Quotes eld
15983 \end_inset
15984
15985 true
15986 \begin_inset Quotes erd
15987 \end_inset
15988
15989  \SpecialChar LaTeX
15990  table of contents, but not in the \SpecialChar LyX
15991  table of contents (
15992 \family sans
15993 Document\SpecialChar menuseparator
15994 Table
15995 \begin_inset space ~
15996 \end_inset
15997
15998 of
15999 \begin_inset space ~
16000 \end_inset
16001
16002 Contents
16003 \family default
16004 ).
16005 \end_layout
16006
16007 \begin_layout Itemize
16008 The paragraphs in a 
16009 \emph on
16010 letter
16011 \emph default
16012  document class appear in a skip separation mode, not indented.
16013  This is the standard behavior, no special \SpecialChar LaTeX
16014  commands are needed for that.
16015  But in the 
16016 \family sans
16017 Document\SpecialChar menuseparator
16018 Settings
16019 \family default
16020  dialog the corresponding radio button indicates 
16021 \family sans
16022 Indent
16023 \family default
16024 .
16025  A 
16026 \family sans
16027 Skip
16028 \family default
16029  value always has the effect that extra \SpecialChar LaTeX
16030  commands are inserted in the document
16031  to produce the gap, which is not what is wanted in this case.
16032 \end_layout
16033
16034 \begin_layout Section
16035 Memoir
16036 \end_layout
16037
16038 \begin_layout Standard
16039 By 
16040 \noun on
16041 Jürgen Spitzmüller
16042 \end_layout
16043
16044 \begin_layout Subsection
16045 Overview
16046 \end_layout
16047
16048 \begin_layout Standard
16049 Memoir is a very powerful and constantly evolving class.
16050  It has been designed with regard to fictional and non-fictional literature.
16051  Its aim is to let the user have maximum control over the typesetting of
16052  his document.
16053  Memoir is based on the standard book class, but it can also emulate the
16054  article class (see below).
16055 \end_layout
16056
16057 \begin_layout Standard
16058 Peter Wilson, the developer of Memoir, is known as the author of lots of
16059  useful packages in the \SpecialChar LaTeX
16060  world.
16061  Most of them have been merged with Memoir.
16062  Therefore, it is much easier to layout the table of contents, appendices,
16063  chapter designs and such.
16064  \SpecialChar LyX
16065 , though, does not support all of these goodies natively.
16066  Some of them might be added to forthcoming releases
16067 \begin_inset Foot
16068 status collapsed
16069
16070 \begin_layout Plain Layout
16071 You are invited to send suggestions to 
16072 \begin_inset Flex URL
16073 status collapsed
16074
16075 \begin_layout Plain Layout
16076
16077 lyx-devel@lists.lyx.org
16078 \end_layout
16079
16080 \end_inset
16081
16082 .
16083 \end_layout
16084
16085 \end_inset
16086
16087 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
16088 's framework.
16089  Of course you can still use all features with the help of some native \SpecialChar LaTeX
16090
16091  commands (\SpecialChar TeX
16092  code
16093 \begin_inset Foot
16094 status collapsed
16095
16096 \begin_layout Plain Layout
16097 Cf.
16098 \begin_inset ERT
16099 status collapsed
16100
16101 \begin_layout Plain Layout
16102
16103
16104 \backslash
16105  
16106 \end_layout
16107
16108 \end_inset
16109
16110 section
16111 \begin_inset space ~
16112 \end_inset
16113
16114
16115 \begin_inset CommandInset ref
16116 LatexCommand ref
16117 reference "sec:Inserting-TeX-Code"
16118
16119 \end_inset
16120
16121  for details.
16122 \end_layout
16123
16124 \end_inset
16125
16126 ).
16127  In this section, we can only list those features that are natively supported
16128  by \SpecialChar LyX
16129 .
16130  For detailed descriptions (and for the rest of features) we recommend you
16131  have a look at the detailed manual of the Memoir class
16132 \begin_inset Foot
16133 status collapsed
16134
16135 \begin_layout Plain Layout
16136 Cf.
16137 \begin_inset ERT
16138 status collapsed
16139
16140 \begin_layout Plain Layout
16141
16142
16143 \backslash
16144  
16145 \end_layout
16146
16147 \end_inset
16148
16149
16150 \begin_inset Flex URL
16151 status collapsed
16152
16153 \begin_layout Plain Layout
16154
16155 CTAN:/macros/latex/memoir/memman.pdf
16156 \end_layout
16157
16158 \end_inset
16159
16160 .
16161 \end_layout
16162
16163 \end_inset
16164
16165 , which is not only a user guide for the class, but also both a comprehensive
16166  description on good typesetting and a superb example for good typesetting
16167  itself.
16168 \end_layout
16169
16170 \begin_layout Subsection
16171 Basic features and restrictions
16172 \end_layout
16173
16174 \begin_layout Standard
16175 Memoir supports basically all features of the standard book classes.
16176  There are, however, some differences, as follows:
16177 \end_layout
16178
16179 \begin_layout Description
16180 Font
16181 \begin_inset space ~
16182 \end_inset
16183
16184 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
16185 \end_layout
16186
16187 \begin_layout Description
16188 Page
16189 \begin_inset space ~
16190 \end_inset
16191
16192 style: The fancy page style is not supported, due to a command clash between
16193  Memoir and the fancyhdr package (they both define a command with the same
16194  name, which confuses \SpecialChar LaTeX
16195 ).
16196  Instead, Memoir comes with a number of its own page styles (see 
16197 \change_deleted -712698321 1501165256
16198
16199 \family sans
16200 Layout\SpecialChar menuseparator
16201
16202 \change_unchanged
16203 Document\SpecialChar menuseparator
16204
16205 \change_inserted -712698321 1501165264
16206 Settings\SpecialChar menuseparator
16207
16208 \change_unchanged
16209 Page
16210 \begin_inset space ~
16211 \end_inset
16212
16213 Style
16214 \family default
16215 ).
16216  If you want to use these for the chapter pages, you have to use the command
16217  
16218 \family typewriter
16219
16220 \backslash
16221 chapterstyle
16222 \family default
16223  in the main text or in preamble (e.
16224 \begin_inset space \thinspace{}
16225 \end_inset
16226
16227 g.
16228 \begin_inset space \space{}
16229 \end_inset
16230
16231
16232 \family typewriter
16233
16234 \backslash
16235 chapterstyle{companion}
16236 \family default
16237 ).
16238 \end_layout
16239
16240 \begin_layout Description
16241 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
16242  optional argument in the standard classes.
16243  With this, you can specify an alternative version of the title for the
16244  table of contents and the headers (for instance, if the title is too long).
16245  In \SpecialChar LyX
16246 , you can do this via 
16247 \family sans
16248 Insert\SpecialChar menuseparator
16249 Short
16250 \begin_inset space ~
16251 \end_inset
16252
16253 Title
16254 \family default
16255  at the beginning of a chapter/section.
16256  Memoir features a second optional argument and thus separates the table
16257  of contents from the header.
16258  You can define three variants of a title with this: one for the main text,
16259  one for the table of contents, and one for the headers.
16260  
16261 \change_deleted -712698321 1501165686
16262 Simply insert two optional arguments if you need this feature, the first
16263  one containing the short title for the Table of Contents, the second one
16264  containing an alternative short title for the headers
16265 \change_inserted -712698321 1501165708
16266 \SpecialChar LyX
16267  makes these available in form of specific 
16268 \family sans
16269 Short Title
16270 \family default
16271  variants in the 
16272 \family sans
16273 Insert
16274 \family default
16275  menu
16276 \change_unchanged
16277 .
16278 \end_layout
16279
16280 \begin_layout Description
16281 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
16282  of contents, the list of figures and the list of table start a new page
16283  automatically.
16284  Memoir does not follow this route.
16285  You have to insert a page break yourself, if you want to have one.
16286 \end_layout
16287
16288 \begin_layout Description
16289 Titlepage: For some unknown reason, Memoir uses pagination on the title
16290  page (in the standard classes, title pages are 
16291 \begin_inset Quotes eld
16292 \end_inset
16293
16294 empty
16295 \begin_inset Quotes erd
16296 \end_inset
16297
16298 ).
16299  If you want an empty title page, type 
16300 \family typewriter
16301
16302 \backslash
16303 aliaspagestyle{title}{empty}
16304 \family default
16305  in the preamble.
16306 \end_layout
16307
16308 \begin_layout Description
16309 Article: With the class option 
16310 \emph on
16311 article
16312 \emph default
16313  (to be inserted in 
16314 \change_deleted -712698321 1501165976
16315
16316 \family sans
16317 Layout\SpecialChar menuseparator
16318
16319 \change_unchanged
16320 Document\SpecialChar menuseparator
16321
16322 \change_inserted -712698321 1501165986
16323 Settings\SpecialChar menuseparator
16324 Class Settings\SpecialChar menuseparator
16325
16326 \change_deleted -712698321 1501165988
16327 Extra
16328 \change_inserted -712698321 1501165989
16329 Custom
16330 \change_unchanged
16331
16332 \begin_inset space ~
16333 \end_inset
16334
16335 Options
16336 \family default
16337 ), you can emulate article style.
16338  That is, counters (footnotes, figures, tables etc.) will not be reset on
16339  new chapters, chapters don't start a new page (but are—in contrary to 
16340 \begin_inset Quotes eld
16341 \end_inset
16342
16343 real
16344 \begin_inset Quotes erd
16345 \end_inset
16346
16347  article classes—still allowed), parts, though, use their own page, as in
16348  book.
16349 \end_layout
16350
16351 \begin_layout Description
16352 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
16353  font commands, which have been used in the old \SpecialChar LaTeX
16354  version 2.09 (e.
16355 \begin_inset space \thinspace{}
16356 \end_inset
16357
16358 g.
16359 \begin_inset space \space{}
16360 \end_inset
16361
16362
16363 \family typewriter
16364
16365 \backslash
16366 rm
16367 \family default
16368
16369 \family typewriter
16370
16371 \backslash
16372 it
16373 \family default
16374 ).
16375  It produces an error and stops \SpecialChar LaTeX
16376  whenever such a command appears.
16377  The class option 
16378 \emph on
16379 oldfontcommands
16380 \emph default
16381  reallows the commands and spits out warnings instead (which does at least
16382  not stop \SpecialChar LaTeX
16383 ).
16384  Since a lot of packages and particularly Bib\SpecialChar TeX
16385  style files are still using
16386  those commands, we have decided to use this option by default.
16387 \end_layout
16388
16389 \begin_layout Subsection
16390 Extra features
16391 \end_layout
16392
16393 \begin_layout Standard
16394 We will only describe the features supported by \SpecialChar LyX
16395  (which is not much currently).
16396  Please consult the Memoir manual
16397 \begin_inset Foot
16398 status collapsed
16399
16400 \begin_layout Plain Layout
16401 Cf.
16402 \begin_inset ERT
16403 status collapsed
16404
16405 \begin_layout Plain Layout
16406
16407
16408 \backslash
16409  
16410 \end_layout
16411
16412 \end_inset
16413
16414
16415 \begin_inset Flex URL
16416 status collapsed
16417
16418 \begin_layout Plain Layout
16419
16420 CTAN:/macros/latex/memoir/memman.pdf
16421 \end_layout
16422
16423 \end_inset
16424
16425 .
16426 \end_layout
16427
16428 \end_inset
16429
16430  for details.
16431 \end_layout
16432
16433 \begin_layout Description
16434 Abstract: You may wonder why an abstract is an extra feature.
16435  Well, it is in book class.
16436  Usually books don't have abstracts.
16437  Memoir, however, has.
16438  You can use it wherever and how often you like.
16439 \end_layout
16440
16441 \begin_layout Description
16442 Chapterprecis: You may know this older typesetting style: The contents of
16443  a chapter are summarized below the title and also in the table of contents
16444  (e.
16445 \begin_inset space \thinspace{}
16446 \end_inset
16447
16448 g.
16449 \begin_inset space \space{}
16450 \end_inset
16451
16452
16453 \emph on
16454 Our hero arrives in Troia; he loses some friends; he finds others
16455 \emph default
16456 ).
16457  Chapterprecis does exactly this.
16458  It is therefore only sensible below a chapter.
16459 \end_layout
16460
16461 \begin_layout Description
16462 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
16463  The epigraph environment provides an elegant way of typesetting such a
16464  motto.
16465  The motto itself (text) and its 
16466 \change_inserted -712698321 1501166968
16467 (optional) 
16468 \change_unchanged
16469 author (source) are divided by a short line.
16470  
16471 \change_deleted -712698321 1501166972
16472 Unfortunately, we have to fool \SpecialChar LyX
16473  a bit here again, since the environment
16474  needs two arguments (text and source).
16475  In this case, we have to use curly brackets (in \SpecialChar TeX
16476  mode) between the two
16477  arguments: 
16478 \emph on
16479 <smart slogan>
16480 \emph default
16481  
16482 \family typewriter
16483 }{
16484 \family default
16485  
16486 \emph on
16487 <author of the slogan>
16488 \change_inserted -712698321 1501166996
16489
16490 \emph default
16491 The author (source) can be inserted via 
16492 \family sans
16493 Insert\SpecialChar menuseparator
16494 Epigraph Source
16495 \change_unchanged
16496
16497 \family default
16498 \emph on
16499 .
16500 \end_layout
16501
16502 \begin_layout Description
16503 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
16504  complex figurative poems).
16505  \SpecialChar LyX
16506  can only support a few of them.
16507  One is poemtitle, which is a centered title for poems, which will also
16508  be added to the table of contents (verse is the standard environment for
16509  poems.
16510  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
16511  code,
16512  because they have to be nested inside regular verse environments, which
16513  is not possible with \SpecialChar LyX
16514 ).
16515 \end_layout
16516
16517 \begin_layout Description
16518 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
16519 \end_layout
16520
16521 \begin_layout Section
16522 Article (mwart), book (mwbk) and report (mwrep)
16523 \begin_inset Argument status
16524 status collapsed
16525
16526 \begin_layout Plain Layout
16527 The 
16528 \family typewriter
16529 mw
16530 \family default
16531  Classes
16532 \end_layout
16533
16534 \end_inset
16535
16536
16537 \end_layout
16538
16539 \begin_layout Standard
16540 by 
16541 \noun on
16542 Tomasz Luczak
16543 \end_layout
16544
16545 \begin_layout Standard
16546 The \SpecialChar LyX
16547  document classes 
16548 \emph on
16549 article (mwart)
16550 \emph default
16551
16552 \emph on
16553 report (mwrep)
16554 \emph default
16555  and 
16556 \emph on
16557 book
16558 \emph default
16559  
16560 \emph on
16561 (mwbk)
16562 \emph default
16563  correspond to the \SpecialChar LaTeX
16564  document classes 
16565 \family typewriter
16566 mwart.cls
16567 \family default
16568
16569 \family typewriter
16570 mwrep.cls
16571 \family default
16572  and 
16573 \family typewriter
16574 mwbk.cls
16575 \family default
16576 , resp.
16577  They are replacements for the standard document classes 
16578 \family typewriter
16579 article.cls
16580 \family default
16581
16582 \family typewriter
16583 report.cls
16584 \family default
16585  and 
16586 \family typewriter
16587 book.cls
16588 \family default
16589 , resp., and fit better to Polish typography conventions in a number of points.
16590  
16591 \end_layout
16592
16593 \begin_layout Standard
16594 Basic differences:
16595 \end_layout
16596
16597 \begin_layout Itemize
16598 Unnumbered titles (with star, e.
16599 \begin_inset space \thinspace{}
16600 \end_inset
16601
16602 g.
16603 \begin_inset space \space{}
16604 \end_inset
16605
16606
16607 \family sans
16608 Section*
16609 \family default
16610 ) are added into table of contents,
16611 \end_layout
16612
16613 \begin_layout Itemize
16614 Additional page styles:
16615 \end_layout
16616
16617 \begin_deeper
16618 \begin_layout Description
16619 uheadings header with separated lines,
16620 \end_layout
16621
16622 \begin_layout Description
16623 myheadings custom header, contents headers via commands: 
16624 \family typewriter
16625
16626 \backslash
16627 markright
16628 \family default
16629  and 
16630 \family typewriter
16631
16632 \backslash
16633 markboth
16634 \family default
16635 ,
16636 \end_layout
16637
16638 \begin_layout Description
16639 myuheadings custom header with separated lines,
16640 \end_layout
16641
16642 \begin_layout Description
16643 outer page number is placed on outer side of page
16644 \end_layout
16645
16646 \end_deeper
16647 \begin_layout Itemize
16648 Options 
16649 \end_layout
16650
16651 \begin_deeper
16652 \begin_layout Description
16653 rmheadings serif titles — default,
16654 \end_layout
16655
16656 \begin_layout Description
16657 sfheadings sansserif titles,
16658 \end_layout
16659
16660 \begin_layout Description
16661 authortitle on title page first placed is author next title — default,
16662 \end_layout
16663
16664 \begin_layout Description
16665 titleauthor on title page first placed is title next author,
16666 \end_layout
16667
16668 \begin_layout Description
16669 withmarginpar reserve place on page for margins.
16670 \end_layout
16671
16672 \end_deeper
16673 \begin_layout Section
16674 Paper
16675 \end_layout
16676
16677 \begin_layout Standard
16678 The document class 
16679 \family sans
16680 paper
16681 \family default
16682  provides an alternative to the standard 
16683 \family sans
16684 article
16685 \family default
16686  class.
16687  It provides similar functionality, but you might prefer this layout with
16688  sans serif sections, headings, and more.
16689 \end_layout
16690
16691 \begin_layout Section
16692 Rev\SpecialChar TeX
16693 4
16694 \end_layout
16695
16696 \begin_layout Standard
16697 by 
16698 \noun on
16699 Amir Karger
16700 \end_layout
16701
16702 \begin_layout Standard
16703 \begin_inset VSpace bigskip
16704 \end_inset
16705
16706
16707 \end_layout
16708
16709 \begin_layout Standard
16710 \noindent
16711 The 
16712 \family sans
16713 Revtex
16714 \begin_inset space ~
16715 \end_inset
16716
16717 4
16718 \family default
16719  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
16720  4.0 (the 
16721 \begin_inset Formula $\beta$
16722 \end_inset
16723
16724  release of May, 1999) class.
16725 \end_layout
16726
16727 \begin_layout Standard
16728 \SpecialChar LyX
16729  has a 
16730 \family sans
16731 Revtex
16732 \family default
16733  textclass, which works with Rev\SpecialChar TeX
16734  3.1.
16735  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
16736  2.09.
16737  That means that it doesn't interact very well with \SpecialChar LyX
16738 , which requires \SpecialChar LaTeX2e
16739 , although
16740  it has been kludged to work.
16741  Since Rev\SpecialChar TeX
16742  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
16743 , \SpecialChar LyX
16744  with the
16745  
16746 \family sans
16747 Rev\SpecialChar TeX
16748
16749 \begin_inset space ~
16750 \end_inset
16751
16752 4
16753 \family default
16754  textclass should also be pretty easy to use.
16755 \end_layout
16756
16757 \begin_layout Standard
16758 These documents are supposed to be used in 
16759 \emph on
16760 addition
16761 \emph default
16762  to the Rev\SpecialChar TeX
16763  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
16764  macros,
16765  and assume you'll know what to put in the preamble if necessary.
16766 \end_layout
16767
16768 \begin_layout Subsection
16769 Installation
16770 \end_layout
16771
16772 \begin_layout Standard
16773 All you need to do is install Rev\SpecialChar TeX
16774  4, as described in the package's README
16775  file.
16776  The package can be found at The Rev\SpecialChar TeX
16777  4 Web Site 
16778 \begin_inset Flex URL
16779 status collapsed
16780
16781 \begin_layout Plain Layout
16782
16783 http://publish.aps.org/revtex4/
16784 \end_layout
16785
16786 \end_inset
16787
16788 .
16789  Install it somewhere that \SpecialChar LaTeX
16790  can see it.
16791  Test it by trying to \SpecialChar LaTeX
16792  a short Rev\SpecialChar TeX
16793  4 document in some random directory (i.
16794 \begin_inset space \thinspace{}
16795 \end_inset
16796
16797 e.
16798 \begin_inset space \space{}
16799 \end_inset
16800
16801 not the directory where you installed the class file.) Then, if you reconfigure
16802  \SpecialChar LyX
16803 , it will find the class file and let you use the Rev\SpecialChar TeX
16804 4 textclass.
16805 \end_layout
16806
16807 \begin_layout Standard
16808 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
16809  4 document
16810  using 
16811 \family typewriter
16812 tex2lyx
16813 \family default
16814 , or to use the 
16815 \family sans
16816 Revtex
16817 \begin_inset space ~
16818 \end_inset
16819
16820 4
16821 \family default
16822  template, found in the templates directory.
16823 \end_layout
16824
16825 \begin_layout Subsection
16826 Preamble Matter
16827 \end_layout
16828
16829 \begin_layout Standard
16830 Optional arguments to 
16831 \family typewriter
16832
16833 \backslash
16834 documentclass
16835 \family default
16836 , like 
16837 \begin_inset Quotes eld
16838 \end_inset
16839
16840 preprint
16841 \begin_inset Quotes erd
16842 \end_inset
16843
16844  and 
16845 \begin_inset Quotes eld
16846 \end_inset
16847
16848 aps
16849 \begin_inset Quotes erd
16850 \end_inset
16851
16852 , go in the 
16853 \family sans
16854 Extra
16855 \begin_inset space ~
16856 \end_inset
16857
16858 Options
16859 \family default
16860  field in the 
16861 \family sans
16862 Document
16863 \begin_inset space ~
16864 \end_inset
16865
16866 Layout
16867 \family default
16868  dialog, as usual.
16869  Remember that in Rev\SpecialChar TeX
16870 , at least one optional argument is required! 
16871 \end_layout
16872
16873 \begin_layout Standard
16874 Other preamble matter, like 
16875 \family typewriter
16876
16877 \backslash
16878 draft
16879 \family default
16880  etc.
16881 \begin_inset space ~
16882 \end_inset
16883
16884 goes in the 
16885 \family sans
16886 \SpecialChar LaTeX
16887
16888 \begin_inset space ~
16889 \end_inset
16890
16891 Preamble
16892 \family default
16893  dialog, also as usual.
16894 \end_layout
16895
16896 \begin_layout Subsection
16897 Layouts
16898 \end_layout
16899
16900 \begin_layout Standard
16901 The layouts basically correspond to the commands in Rev\SpecialChar TeX
16902 4.0.
16903  For example, the Email layout corresponds to 
16904 \family typewriter
16905
16906 \backslash
16907 email{}
16908 \family default
16909 .
16910  Note that (at least as of Rev\SpecialChar TeX
16911  4.0 Beta), the 
16912 \family sans
16913 Address
16914 \family default
16915  and 
16916 \family sans
16917 Affiliation
16918 \family default
16919  layouts are exactly equivalent, so you shouldn't need to use both.
16920 \begin_inset Foot
16921 status collapsed
16922
16923 \begin_layout Plain Layout
16924 In case you're curious, both were included so that 
16925 \family typewriter
16926 tex2lyx
16927 \family default
16928  would be able to translate both 
16929 \family typewriter
16930
16931 \backslash
16932 address
16933 \family default
16934  and 
16935 \family typewriter
16936
16937 \backslash
16938 affiliation
16939 \family default
16940 .
16941 \end_layout
16942
16943 \end_inset
16944
16945
16946 \end_layout
16947
16948 \begin_layout Subsection
16949 Important Notes
16950 \end_layout
16951
16952 \begin_layout Standard
16953 There are a couple of important unique aspects of Rev\SpecialChar TeX
16954  4 which might cause
16955  bugs that will be even more confusing in \SpecialChar LyX
16956 .
16957 \end_layout
16958
16959 \begin_layout Standard
16960 In Rev\SpecialChar TeX
16961 , the 
16962 \family typewriter
16963
16964 \backslash
16965 thanks
16966 \family default
16967  command goes 
16968 \emph on
16969 outside
16970 \emph default
16971  the 
16972 \family typewriter
16973
16974 \backslash
16975 author
16976 \family default
16977  command.
16978  The \SpecialChar LyX
16979  equivalent is that there is a separate Thanks layout.
16980  Do 
16981 \emph on
16982 not
16983 \emph default
16984  write footnotes in the 
16985 \family sans
16986 Author
16987 \family default
16988  layout, or weird things may happen.
16989  See the Rev\SpecialChar TeX
16990  4 documentation for more details.
16991 \end_layout
16992
16993 \begin_layout Standard
16994 Also, the 
16995 \family sans
16996 Author
16997 \begin_inset space ~
16998 \end_inset
16999
17000 Email
17001 \family default
17002
17003 \family sans
17004 Author
17005 \begin_inset space ~
17006 \end_inset
17007
17008 URL
17009 \family default
17010 , and 
17011 \family sans
17012 Thanks
17013 \family default
17014  layouts must be placed 
17015 \emph on
17016 in between
17017 \emph default
17018  the 
17019 \family sans
17020 Author
17021 \family default
17022  layout and the corresponding 
17023 \family sans
17024 Address
17025 \family default
17026  (or equivalent 
17027 \family sans
17028 Affiliation
17029 \family default
17030 ) layout.
17031  If you put the 
17032 \family sans
17033 Thanks
17034 \family default
17035  after the 
17036 \family sans
17037 Address
17038 \family default
17039 , the \SpecialChar LaTeX
17040  won't compile.
17041 \end_layout
17042
17043 \begin_layout Subsection
17044
17045 \change_deleted -712698321 1501168252
17046 Drawbacks
17047 \end_layout
17048
17049 \begin_layout Standard
17050
17051 \change_deleted -712698321 1501168252
17052 The main problem with this layout is that you can't use the optional arguments
17053  to layouts like Email and Title.
17054  (The problem is not unique to this layout; you can't use optional arguments
17055  to the Section layouts either.) This means that after you export that file
17056  to \SpecialChar LaTeX
17057  (which you'll need to do eventually to send it in to APS), you'll need
17058  to edit the \SpecialChar LaTeX
17059  file with a text editor to add the optional arguments to set,
17060  e.
17061 \begin_inset space \thinspace{}
17062 \end_inset
17063
17064 g.
17065 \begin_inset space \space{}
17066 \end_inset
17067
17068 the running title for the page headers.
17069  Lacking these layouts makes the 
17070 \family typewriter
17071
17072 \backslash
17073 altaffiliation
17074 \family default
17075  (and the equivalent 
17076 \family typewriter
17077
17078 \backslash
17079 altaddress
17080 \family default
17081 ) useless, so the corresponding layouts don't exist, and will have to be
17082  added by hand.
17083 \begin_inset Foot
17084 status collapsed
17085
17086 \begin_layout Plain Layout
17087
17088 \emph on
17089 Note from JMarc:
17090 \emph default
17091  actually, \SpecialChar LyX
17092  1.3.0 supports some forms of optional arguments, but this layout
17093  has not been updated yet to take advantage of it.
17094 \end_layout
17095
17096 \end_inset
17097
17098  
17099 \change_unchanged
17100
17101 \end_layout
17102
17103 \begin_layout Section
17104 Springer Journals (
17105 \family sans
17106 svjour
17107 \family default
17108 )
17109 \end_layout
17110
17111 \begin_layout Standard
17112 by 
17113 \noun on
17114 Martin Vermeer
17115 \end_layout
17116
17117 \begin_layout Subsection
17118 Description
17119 \end_layout
17120
17121 \begin_layout Standard
17122 These are the layout files for some of the journal formats used by Springer
17123  Verlag and listed on 
17124 \begin_inset Flex URL
17125 status collapsed
17126
17127 \begin_layout Plain Layout
17128
17129 http://www.springer.de/author/tex/help-journals.html
17130 \end_layout
17131
17132 \end_inset
17133
17134 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
17135  now!).
17136  It is a modular system: the things common to all journals are implemented
17137  in 
17138 \family typewriter
17139 svjour.inc
17140 \family default
17141 , which journal-specific layout files (such as, e.
17142 \begin_inset space \thinspace{}
17143 \end_inset
17144
17145 g.
17146 \begin_inset space \space{}
17147 \end_inset
17148
17149
17150 \family typewriter
17151 svjog.layout
17152 \family default
17153  for Journal of Geodesy) can include.
17154 \end_layout
17155
17156 \begin_layout Standard
17157 This means that implementing support for any other Springer journal on this
17158  list is as simple as writing your own 
17159 \family typewriter
17160 sv
17161 \family default
17162 <myjournal>
17163 \family typewriter
17164 .layout
17165 \family default
17166  file following the outline given in 
17167 \family typewriter
17168 svjog.layout
17169 \family default
17170 .
17171  
17172 \end_layout
17173
17174 \begin_layout Standard
17175 It is reasonably well tested only for the Journal of Geodesy.
17176  
17177 \family typewriter
17178 svjour
17179 \family default
17180  and 
17181 \family typewriter
17182 svjog
17183 \family default
17184  come with the standard \SpecialChar LyX
17185  distribution.
17186  Install the relevant class file (downloaded from Springer) in a proper
17187  directory, reconfigure \SpecialChar LaTeX
17188  (in the te\SpecialChar TeX
17189  case by running 
17190 \family typewriter
17191 texhash
17192 \family default
17193 , as root if necessary — doesn't \SpecialChar LyX
17194  take care of this?), reconfigure \SpecialChar LyX
17195  and
17196  it should work.
17197 \end_layout
17198
17199 \begin_layout Subsection
17200 New styles
17201 \end_layout
17202
17203 \begin_layout Standard
17204 A large number of theorem-like styles — 
17205 \family sans
17206 Claim, Conjecture,
17207 \family default
17208  
17209 \family sans
17210 \SpecialChar ldots
17211 Theorem
17212 \family default
17213 .
17214 \end_layout
17215
17216 \begin_layout Standard
17217
17218 \family sans
17219 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
17220 _Title, Author_Running, Institute,
17221  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
17222 \family default
17223 .
17224  See the Springer class file documentation for details.
17225 \end_layout
17226
17227 \begin_layout Subsection
17228 Supported journals
17229 \end_layout
17230
17231 \begin_layout Itemize
17232
17233 \emph on
17234 Journal of Geodesy
17235 \emph default
17236
17237 \family typewriter
17238 svjog.layout
17239 \family default
17240  — Martin Vermeer
17241 \end_layout
17242
17243 \begin_layout Itemize
17244
17245 \emph on
17246 Probability Theory and Related Fields
17247 \emph default
17248
17249 \family typewriter
17250 svprobth.layout
17251 \family default
17252  — Jean-Marc Lasgouttes
17253 \end_layout
17254
17255 \begin_layout Standard
17256 Add your own, it isn't so hard!
17257 \end_layout
17258
17259 \begin_layout Subsection
17260 Credits
17261 \end_layout
17262
17263 \begin_layout Standard
17264 These files are partly based on the older 
17265 \family typewriter
17266 ejour2.layout
17267 \family default
17268 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
17269  2.09 style
17270  file from Springer.
17271  All this, and the 
17272 \family typewriter
17273 ejour2
17274 \family default
17275  layout, are now defunct.
17276  Jean-Marc Lasgouttes helped out big in making me find my way around the
17277  \SpecialChar LyX
17278  layout file mechanism.
17279 \end_layout
17280
17281 \begin_layout Subsection
17282 Bugs
17283 \end_layout
17284
17285 \begin_layout Standard
17286 Probably.
17287  But probably less than in the old hacked-\SpecialChar LaTeX
17288  
17289 \family typewriter
17290 ejour2
17291 \family default
17292 .
17293 \end_layout
17294
17295 \begin_layout Standard
17296
17297 \change_deleted -712698321 1501168901
17298 Limitations e.
17299 \begin_inset space \thinspace{}
17300 \end_inset
17301
17302 g.: does not display the number for theorem-like layouts, just #.
17303 \change_unchanged
17304
17305 \end_layout
17306
17307 \begin_layout Section
17308 Slides [aka 
17309 \noun on
17310 Sli\SpecialChar TeX
17311
17312 \noun default
17313 ]
17314 \begin_inset CommandInset label
17315 LatexCommand label
17316 name "sec:slitex"
17317
17318 \end_inset
17319
17320
17321 \end_layout
17322
17323 \begin_layout Standard
17324 by 
17325 \noun on
17326 John Weiss
17327 \noun default
17328  
17329 \end_layout
17330
17331 \begin_layout Subsection
17332 Introduction
17333 \end_layout
17334
17335 \begin_layout Standard
17336 This section describes how to use \SpecialChar LyX
17337  to make slides for overhead projectors.
17338  There are two document classes that can do this: the default slides class
17339  and the 
17340 \family sans
17341 Foil\SpecialChar TeX
17342
17343 \family default
17344  slides class.
17345  This section documents the former.
17346 \end_layout
17347
17348 \begin_layout Standard
17349 I'm going to say this again, nice and clear, so that there's no misunderstanding
17350 :
17351 \end_layout
17352
17353 \begin_layout Standard
17354 \begin_inset VSpace bigskip
17355 \end_inset
17356
17357
17358 \end_layout
17359
17360 \begin_layout Standard
17361 \align center
17362
17363 \size large
17364 This section documents the class 
17365 \begin_inset Quotes eld
17366 \end_inset
17367
17368
17369 \family sans
17370 slides (default)
17371 \family default
17372
17373 \begin_inset Quotes erd
17374 \end_inset
17375
17376  
17377 \emph on
17378 only.
17379 \end_layout
17380
17381 \begin_layout Standard
17382 \begin_inset VSpace bigskip
17383 \end_inset
17384
17385
17386 \end_layout
17387
17388 \begin_layout Standard
17389 If you're looking for the documentation for 
17390 \begin_inset Quotes eld
17391 \end_inset
17392
17393
17394 \family sans
17395 slides (Foil\SpecialChar TeX
17396 )
17397 \family default
17398
17399 \begin_inset Quotes erd
17400 \end_inset
17401
17402 , check out section
17403 \begin_inset space ~
17404 \end_inset
17405
17406
17407 \begin_inset CommandInset ref
17408 LatexCommand ref
17409 reference "sec:foiltex"
17410
17411 \end_inset
17412
17413 .
17414  The 
17415 \family sans
17416 foils
17417 \family default
17418  class [
17419 \begin_inset Quotes eld
17420 \end_inset
17421
17422
17423 \family sans
17424 slides (Foil\SpecialChar TeX
17425 )
17426 \family default
17427
17428 \begin_inset Quotes erd
17429 \end_inset
17430
17431 ] is actually somewhat better than the default 
17432 \family sans
17433 slides
17434 \family default
17435  class,
17436 \begin_inset Foot
17437 status collapsed
17438
17439 \begin_layout Plain Layout
17440 \SpecialChar ldots
17441 or so I've been told repeatedly by its advocates.
17442  Having never used it, I have no idea if this claim is true or not.
17443 \end_layout
17444
17445 \end_inset
17446
17447  which this section documents.
17448 \end_layout
17449
17450 \begin_layout Standard
17451 This class is the \SpecialChar LaTeX2e
17452  improvement of the old 
17453 \noun on
17454 Sli\SpecialChar TeX
17455
17456 \noun default
17457  package.
17458  Every \SpecialChar LaTeX2e
17459  distribution includes this class [which I'll just refer to as 
17460 \begin_inset Quotes eld
17461 \end_inset
17462
17463
17464 \family sans
17465 slides
17466 \family default
17467
17468 \begin_inset Quotes erd
17469 \end_inset
17470
17471  from now on], so you're bound to have it.
17472  As I noted earlier, there are other classes, such as 
17473 \family sans
17474 foils
17475 \family default
17476 , which also produce slides for overhead projectors and do a better job
17477  at it.
17478  However, there are some things which 
17479 \family sans
17480 slides
17481 \family default
17482  can do which the others can't, such as generate overlays.
17483  Read on to learn more!
17484 \end_layout
17485
17486 \begin_layout Subsection
17487 Getting Started
17488 \begin_inset CommandInset label
17489 LatexCommand label
17490 name "sec:slidesetup"
17491
17492 \end_inset
17493
17494
17495 \end_layout
17496
17497 \begin_layout Standard
17498 Obviously, to use this document class, you need to select 
17499 \begin_inset Quotes eld
17500 \end_inset
17501
17502
17503 \family sans
17504 slides (default)
17505 \family default
17506
17507 \begin_inset Quotes erd
17508 \end_inset
17509
17510  from the class list in the 
17511 \family sans
17512 Document\SpecialChar menuseparator
17513 Settings
17514 \family default
17515  dialog.
17516  There are some other special things you should know about this class:
17517 \end_layout
17518
17519 \begin_layout Itemize
17520 Don't bother changing the options 
17521 \family sans
17522 Sides and Columns
17523 \family default
17524 .
17525  They're not supported by the 
17526 \family sans
17527 slides
17528 \family default
17529  class, anyways.
17530 \end_layout
17531
17532 \begin_layout Itemize
17533 The option 
17534 \family sans
17535 Page
17536 \begin_inset space ~
17537 \end_inset
17538
17539 style
17540 \family default
17541  behaves a bit differently for this class.
17542  The possible choices and what they do are as follows:
17543 \end_layout
17544
17545 \begin_deeper
17546 \begin_layout Description
17547
17548 \family sans
17549 plain
17550 \family default
17551  The final output contains page numbers in the lower right corner.
17552 \end_layout
17553
17554 \begin_layout Description
17555
17556 \family sans
17557 headings
17558 \family default
17559  Like 
17560 \family sans
17561 plain
17562 \family default
17563 , but also prints out any time markers you've put in.
17564  This is the default.
17565 \end_layout
17566
17567 \begin_layout Description
17568
17569 \family sans
17570 empty
17571 \family default
17572  The final output contains no page numbers, time markers, or alignment markers.
17573 \end_layout
17574
17575 \end_deeper
17576 \begin_layout Itemize
17577 The 
17578 \family sans
17579 slides
17580 \family default
17581  class has an extra option: 
17582 \family typewriter
17583 clock
17584 \family default
17585 .
17586  To use it, put 
17587 \begin_inset Quotes eld
17588 \end_inset
17589
17590
17591 \family typewriter
17592 clock
17593 \family default
17594
17595 \begin_inset Quotes erd
17596 \end_inset
17597
17598  in the extra class options.
17599 \end_layout
17600
17601 \begin_deeper
17602 \begin_layout Standard
17603 Using this options allows you to add time markers to 
17604 \family sans
17605 Note
17606 \family default
17607 s.
17608  See section
17609 \begin_inset space ~
17610 \end_inset
17611
17612
17613 \begin_inset CommandInset ref
17614 LatexCommand ref
17615 reference "sec:slideNote"
17616
17617 \end_inset
17618
17619  for more details.
17620 \end_layout
17621
17622 \end_deeper
17623 \begin_layout Standard
17624 You can also use the template file 
17625 \begin_inset Quotes eld
17626 \end_inset
17627
17628
17629 \family typewriter
17630 slides.lyx
17631 \family default
17632
17633 \begin_inset Quotes erd
17634 \end_inset
17635
17636  to automatically set up a document to use the 
17637 \family sans
17638 slides
17639 \family default
17640  class [using 
17641 \family sans
17642 File\SpecialChar menuseparator
17643 New
17644 \begin_inset space ~
17645 \end_inset
17646
17647 from
17648 \begin_inset space ~
17649 \end_inset
17650
17651 Template
17652 \family default
17653  to open your new document].
17654  The template file also contains some examples of the special paragraph
17655  environments used by this class.
17656  I'll describe those next.
17657 \end_layout
17658
17659 \begin_layout Subsection
17660 Paragraph Environments
17661 \end_layout
17662
17663 \begin_layout Subsubsection
17664 Supported Environments
17665 \end_layout
17666
17667 \begin_layout Standard
17668 The first thing you'll notice when you start up a new 
17669 \family sans
17670 slides
17671 \family default
17672  document is the font size and type: it's the equivalent of the size 
17673 \begin_inset Quotes eld
17674 \end_inset
17675
17676
17677 \family sans
17678 Largest
17679 \family default
17680
17681 \begin_inset Quotes erd
17682 \end_inset
17683
17684  in the 
17685 \family sans
17686 Sans
17687 \begin_inset space ~
17688 \end_inset
17689
17690 Serif
17691 \family default
17692  font.
17693  This is also what's used in the output.
17694  Think of this as a 
17695 \begin_inset Quotes eld
17696 \end_inset
17697
17698 visual cue
17699 \begin_inset Quotes erd
17700 \end_inset
17701
17702  to remind you that this is a slide.
17703  Your final slides will use a larger font; ergo, you'll have less space.
17704  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
17705 \end_layout
17706
17707 \begin_layout Standard
17708 The next thing that becomes obvious is the changes to the paragraph environment
17709  pull-down box [at the far-left end of the toolbar].
17710  Most of the paragraph environments you're used to seeing are missing.
17711  There are also five new ones.
17712  That's because the 
17713 \family sans
17714 slides
17715 \family default
17716  class itself only supports certain paragraph environments:
17717 \end_layout
17718
17719 \begin_layout Itemize
17720
17721 \family sans
17722 Standard
17723 \end_layout
17724
17725 \begin_layout Itemize
17726
17727 \family sans
17728 Itemize
17729 \end_layout
17730
17731 \begin_layout Itemize
17732
17733 \family sans
17734 Enumerate
17735 \end_layout
17736
17737 \begin_layout Itemize
17738
17739 \family sans
17740 Description
17741 \end_layout
17742
17743 \begin_layout Itemize
17744
17745 \family sans
17746 List
17747 \end_layout
17748
17749 \begin_layout Itemize
17750
17751 \family sans
17752 Quotation
17753 \end_layout
17754
17755 \begin_layout Itemize
17756
17757 \family sans
17758 Quote
17759 \end_layout
17760
17761 \begin_layout Itemize
17762
17763 \family sans
17764 Verse
17765 \end_layout
17766
17767 \begin_layout Itemize
17768
17769 \family sans
17770 Caption
17771 \end_layout
17772
17773 \begin_layout Itemize
17774
17775 \family sans
17776 \SpecialChar LyX
17777 -Code
17778 \end_layout
17779
17780 \begin_layout Itemize
17781
17782 \change_deleted -712698321 1501169265
17783
17784 \family sans
17785 Comment
17786 \change_unchanged
17787
17788 \end_layout
17789
17790 \begin_layout Standard
17791 All of the other standard environments, including the section-heading environmen
17792 ts, aren't used in the 
17793 \family sans
17794 slides
17795 \family default
17796  class.
17797 \end_layout
17798
17799 \begin_layout Standard
17800 On the other hand, you'll notice the following new environments:
17801 \end_layout
17802
17803 \begin_layout Itemize
17804
17805 \family sans
17806 Slide
17807 \end_layout
17808
17809 \begin_layout Itemize
17810
17811 \family sans
17812 Overlay
17813 \end_layout
17814
17815 \begin_layout Itemize
17816
17817 \family sans
17818 Note
17819 \end_layout
17820
17821 \begin_layout Itemize
17822
17823 \family sans
17824 InvisibleText
17825 \end_layout
17826
17827 \begin_layout Itemize
17828
17829 \family sans
17830 VisibleText
17831 \end_layout
17832
17833 \begin_layout Standard
17834 These five are kind of quirky, due to a 
17835 \begin_inset Quotes eld
17836 \end_inset
17837
17838 feature
17839 \begin_inset Quotes erd
17840 \end_inset
17841
17842  in \SpecialChar LyX
17843 .
17844  You see, \SpecialChar LyX
17845  doesn't permit you to nest any other paragraph environment into
17846  an empty environment.
17847  Now, that's fine and dandy, but it means that you wouldn't be able to start
17848  a slide with anything except plain text.
17849  To deal with this, I've performed a little 
17850 \begin_inset Quotes eld
17851 \end_inset
17852
17853 \SpecialChar LaTeX
17854  magic.
17855 \begin_inset Quotes erd
17856 \end_inset
17857
17858  
17859 \end_layout
17860
17861 \begin_layout Subsubsection
17862 Quirks of the New Environments
17863 \begin_inset CommandInset label
17864 LatexCommand label
17865 name "sec:slideQuirk"
17866
17867 \end_inset
17868
17869
17870 \end_layout
17871
17872 \begin_layout Standard
17873 All five of the new paragraph environments are somewhat quirky due to inherent
17874  limitiations in the current version of \SpecialChar LyX
17875 .
17876  As I just mentioned, \SpecialChar LyX
17877  forbids environments that begin with another environment.
17878  To get around this, the 
17879 \family sans
17880 Slide
17881 \family default
17882  environment isn't a paragraph environment as described in the 
17883 \emph on
17884 User's Guide
17885 \emph default
17886 .
17887  
17888 \end_layout
17889
17890 \begin_layout Standard
17891 You should consider 
17892 \family sans
17893 Slide
17894 \family default
17895
17896 \family sans
17897 Overlay
17898 \family default
17899 , and 
17900 \family sans
17901 Note
17902 \family default
17903  to be 
17904 \begin_inset Quotes eld
17905 \end_inset
17906
17907 pseudo-environments.
17908 \begin_inset Quotes erd
17909 \end_inset
17910
17911  They look like a section heading or a 
17912 \begin_inset Quotes eld
17913 \end_inset
17914
17915
17916 \family sans
17917 Caption
17918 \family default
17919 ,
17920 \begin_inset Quotes erd
17921 \end_inset
17922
17923  but really begin a [and, if necessary, end the previous] paragraph environment.
17924  Likewise, treat 
17925 \family sans
17926 InvisibleText
17927 \family default
17928  and 
17929 \family sans
17930 VisibleText
17931 \family default
17932  as 
17933 \begin_inset Quotes eld
17934 \end_inset
17935
17936 pseudo-commands.
17937 \begin_inset Quotes erd
17938 \end_inset
17939
17940  These two perform some action.
17941 \end_layout
17942
17943 \begin_layout Standard
17944 A common feature of all five environments, 
17945 \family sans
17946 Slide
17947 \family default
17948
17949 \family sans
17950 Overlay
17951 \family default
17952
17953 \family sans
17954 Note
17955 \family default
17956
17957 \family sans
17958 InvisibleText
17959 \family default
17960  and 
17961 \family sans
17962 VisibleText
17963 \family default
17964 , is a rather long-ish label.
17965  The text following this label — ordinarily the contents of the paragraph
17966  environment — is utterly irrelevant for 
17967 \family sans
17968 Slide
17969 \family default
17970
17971 \family sans
17972 Overlay
17973 \family default
17974
17975 \family sans
17976 Note
17977 \family default
17978
17979 \family sans
17980 InvisibleText
17981 \family default
17982  and 
17983 \family sans
17984 VisibleText
17985 \family default
17986 .
17987  \SpecialChar LyX
17988  completely ignores it.
17989  In fact, you can leave these five environments completely empty.
17990  
17991 \end_layout
17992
17993 \begin_layout Standard
17994 While you don't 
17995 \emph on
17996 have
17997 \emph default
17998  to put any text after the rather long-ish label, you might want to.
17999  This could be a short description of the contents of the 
18000 \family sans
18001 Slide
18002 \family default
18003 , for example.
18004  In that case, enter your descriptive comment and hit 
18005 \family sans
18006 Return
18007 \family default
18008  as you normally would.
18009 \end_layout
18010
18011 \begin_layout Standard
18012 If, on the other hand, you don't want to enter any descriptive text, you'll
18013  hit another \SpecialChar LyX
18014  quirk.
18015  \SpecialChar LyX
18016 , like nature, abhors a vacuum, and will not let you start a new paragraph
18017  environment until you put something in the old one.
18018  So, do this:
18019 \end_layout
18020
18021 \begin_layout Itemize
18022 Start entering the text that will 
18023 \emph on
18024 follow
18025 \emph default
18026  the new 
18027 \family sans
18028 Slide
18029 \family default
18030
18031 \family sans
18032 Overlay
18033 \family default
18034
18035 \family sans
18036 Note
18037 \family default
18038
18039 \family sans
18040 InvisibleText
18041 \family default
18042  or 
18043 \family sans
18044 VisibleText
18045 \family default
18046 .
18047  
18048 \end_layout
18049
18050 \begin_layout Itemize
18051 Now move to the beginning of that paragraph.
18052  
18053 \end_layout
18054
18055 \begin_layout Itemize
18056 Next, hit 
18057 \family sans
18058 Return
18059 \family default
18060 .
18061  
18062 \end_layout
18063
18064 \begin_layout Itemize
18065 Finally, change this new, empty paragraph to a 
18066 \family sans
18067 Slide
18068 \family default
18069
18070 \family sans
18071 Overlay
18072 \family default
18073
18074 \family sans
18075 Note
18076 \family default
18077
18078 \family sans
18079 InvisibleText
18080 \family default
18081  or 
18082 \family sans
18083 VisibleText
18084 \family default
18085 .
18086  
18087 \end_layout
18088
18089 \begin_layout Standard
18090 Some future version of \SpecialChar LyX
18091  will, hopefully, resolve this quirkiness\SpecialChar ldots
18092
18093 \end_layout
18094
18095 \begin_layout Subsection
18096 Making a Presentation with 
18097 \family sans
18098 Slide
18099 \family default
18100
18101 \family sans
18102 Overlay
18103 \family default
18104  and 
18105 \family sans
18106 Note
18107 \end_layout
18108
18109 \begin_layout Subsubsection
18110 Using the 
18111 \family sans
18112 Slide
18113 \family default
18114  Environment
18115 \end_layout
18116
18117 \begin_layout Standard
18118 If you're expecting this section to teach you how to actually make a presentatio
18119 n, you'll be sorely disappointed.
18120  Naturally, I'll describe all of the ways the 
18121 \family sans
18122 slides
18123 \family default
18124  class can assist you in preparing the materials for a presentation.
18125  Filling in the contents, however, is up to you.
18126  [Then again, that 
18127 \emph on
18128 is
18129 \emph default
18130  the \SpecialChar LyX
18131  philosophy.]
18132 \end_layout
18133
18134 \begin_layout Standard
18135 Choosing the 
18136 \family sans
18137 Slide
18138 \family default
18139  environment [in the manner described in section
18140 \begin_inset space ~
18141 \end_inset
18142
18143
18144 \begin_inset CommandInset ref
18145 LatexCommand ref
18146 reference "sec:slideQuirk"
18147
18148 \end_inset
18149
18150 ] tells \SpecialChar LyX
18151  to begin a new slide [duh].
18152  The label for this environment/
18153 \begin_inset Quotes erd
18154 \end_inset
18155
18156 pseudo-command
18157 \begin_inset Quotes erd
18158 \end_inset
18159
18160  is an 
18161 \begin_inset Quotes eld
18162 \end_inset
18163
18164 ASCII line,
18165 \begin_inset Quotes erd
18166 \end_inset
18167
18168  in cool blue, followed by the label, 
18169 \begin_inset Quotes eld
18170 \end_inset
18171
18172 NewSlide:
18173 \begin_inset Quotes erd
18174 \end_inset
18175
18176 .
18177  Any text or paragraph environments that follow this one go on the new slide.
18178  It's that simple.
18179 \end_layout
18180
18181 \begin_layout Standard
18182 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
18183
18184  (this can be specified in the 
18185 \family sans
18186 Paragraph Layout
18187 \family default
18188  dialog).
18189  In fact, you'll want to, once you finish entering the contents of one slide.
18190  If you've entered more text than can physically fit on a slide, the extra
18191  overflows onto a new slide.
18192  I don't recommend doing this, however, since the overflow slide won't have
18193  any page number on it.
18194  Furthermore, it may interfere with any 
18195 \family sans
18196 Overlay
18197 \family default
18198  you've made to accompany the oversized 
18199 \family sans
18200 Slide
18201 \family default
18202 .
18203 \end_layout
18204
18205 \begin_layout Standard
18206 The 
18207 \family sans
18208 Overlay
18209 \family default
18210  and 
18211 \family sans
18212 Note
18213 \family default
18214  environments work the same way as the 
18215 \family sans
18216 Slide
18217 \family default
18218  environment.
18219  They both create an 
18220 \begin_inset Quotes eld
18221 \end_inset
18222
18223 ASCII line
18224 \begin_inset Quotes erd
18225 \end_inset
18226
18227  followed by a label [
18228 \begin_inset Quotes eld
18229 \end_inset
18230
18231 NewOverlay:
18232 \begin_inset Quotes erd
18233 \end_inset
18234
18235  and 
18236 \begin_inset Quotes eld
18237 \end_inset
18238
18239 NewNote:
18240 \begin_inset Quotes erd
18241 \end_inset
18242
18243 , respectively].
18244  The color is a stunning magenta instead of blue, and the 
18245 \begin_inset Quotes eld
18246 \end_inset
18247
18248 ASCII line
18249 \begin_inset Quotes erd
18250 \end_inset
18251
18252  will look different, in style and in length.
18253  The label fonts of all three also differ from one another.
18254 \end_layout
18255
18256 \begin_layout Standard
18257 As with a 
18258 \family sans
18259 Slide
18260 \family default
18261 , if the contents of a 
18262 \family sans
18263 Note
18264 \family default
18265  or 
18266 \family sans
18267 Overlay
18268 \family default
18269  exceed the physical size of a slide or sheet of paper, the extra will overflow
18270  onto a new sheet.
18271  Again, you should avoid this.
18272  It defeats the whole purpose of 
18273 \family sans
18274 Note
18275 \family default
18276 s and 
18277 \family sans
18278 Overlay
18279 \family default
18280 s.
18281 \end_layout
18282
18283 \begin_layout Subsubsection
18284 Using 
18285 \family sans
18286 Overlay
18287 \family default
18288  with 
18289 \family sans
18290 Slide
18291 \end_layout
18292
18293 \begin_layout Standard
18294 The idea behind an 
18295 \family sans
18296 Overlay
18297 \family default
18298  is a slide that sits atop another slide.
18299  Perhaps you wish to discuss a figure on the main 
18300 \family sans
18301 Slide
18302 \family default
18303  before displaying the text associated with it.
18304  One way to accomplish this is tape a flap of dark paper over the part of
18305  the 
18306 \family sans
18307 Slide
18308 \family default
18309  you want to display later.
18310  This method fails, however, if you wish to overlap one graph with another,
18311  for example.
18312  You would then have to fumble while speaking to align the two separate,
18313  overlapping 
18314 \family sans
18315 Slide
18316 \family default
18317 s to align the two graphs.
18318  The use of an 
18319 \family sans
18320 Overlay
18321 \family default
18322  environment in both cases makes life much easier.
18323 \end_layout
18324
18325 \begin_layout Standard
18326 Each 
18327 \family sans
18328 Overlay
18329 \family default
18330  receives the page number of its 
18331 \begin_inset Quotes eld
18332 \end_inset
18333
18334 parent
18335 \begin_inset Quotes erd
18336 \end_inset
18337
18338  
18339 \family sans
18340 Slide
18341 \family default
18342 , appended by 
18343 \begin_inset Quotes eld
18344 \end_inset
18345
18346
18347 \family typewriter
18348 -a
18349 \family default
18350
18351 \begin_inset Quotes erd
18352 \end_inset
18353
18354 .
18355 \begin_inset Foot
18356 status collapsed
18357
18358 \begin_layout Plain Layout
18359 Presumably, mutliple 
18360 \family sans
18361 Overlay
18362 \family default
18363 s would have 
18364 \begin_inset Quotes eld
18365 \end_inset
18366
18367
18368 \family typewriter
18369 -a
18370 \family default
18371
18372 \begin_inset Quotes erd
18373 \end_inset
18374
18375
18376 \begin_inset Quotes eld
18377 \end_inset
18378
18379
18380 \family typewriter
18381 -b
18382 \family default
18383
18384 \begin_inset Quotes erd
18385 \end_inset
18386
18387
18388 \begin_inset Quotes eld
18389 \end_inset
18390
18391
18392 \family typewriter
18393 -c
18394 \family default
18395
18396 \begin_inset Quotes erd
18397 \end_inset
18398
18399 , etc.
18400 \begin_inset space ~
18401 \end_inset
18402
18403 appended to the page number of the parent 
18404 \family sans
18405 Slide
18406 \family default
18407 .
18408  
18409 \end_layout
18410
18411 \end_inset
18412
18413  Clearly, you want the contents of both the 
18414 \family sans
18415 Slide
18416 \family default
18417  and the 
18418 \family sans
18419 Overlay
18420 \family default
18421  to each fit on a single physical slide! You should probably consider an
18422  
18423 \family sans
18424 Overlay
18425 \family default
18426  as 
18427 \begin_inset Quotes eld
18428 \end_inset
18429
18430 part of
18431 \begin_inset Quotes erd
18432 \end_inset
18433
18434  a 
18435 \family sans
18436 Slide
18437 \family default
18438 .
18439  Indeed, the \SpecialChar LyX
18440  
18441 \family sans
18442 slides
18443 \family default
18444  class provides a visual cue for this: the label at the start of an 
18445 \family sans
18446 Overlay
18447 \family default
18448  is shorter than that at the start of a 
18449 \family sans
18450 Slide
18451 \family default
18452 .
18453  Lastly, when you generate printable output, you'll find alignment markers
18454  in all four corners of both the 
18455 \family sans
18456 Overlay
18457 \family default
18458  page and its parent 
18459 \family sans
18460 Slide
18461 \family default
18462 .
18463  These will assist you in lining up the two physical slides.
18464 \end_layout
18465
18466 \begin_layout Standard
18467 The major problem in overlaying two slides is aligning the contents of the
18468  two transparencies.
18469  How much space should you leave for that graph on the second slide? Worse
18470  still, what if you want a graph and a sentence on second slide, but there
18471  is text on the main transparency that goes in between them? You could try
18472  and insert vertical space of the right size.
18473  The better way is to use 
18474 \family sans
18475 InvisibleText
18476 \family default
18477  and 
18478 \family sans
18479 VisibleText
18480 \family default
18481 .
18482 \end_layout
18483
18484 \begin_layout Standard
18485 As their names imply, 
18486 \family sans
18487 InvisibleText
18488 \family default
18489  and 
18490 \family sans
18491 VisibleText
18492 \family default
18493  are two command-like paragraph environments that make all subsequent text
18494  invisible and visible, respectively.
18495  Note from section
18496 \begin_inset space ~
18497 \end_inset
18498
18499
18500 \begin_inset CommandInset ref
18501 LatexCommand ref
18502 reference "sec:slideQuirk"
18503
18504 \end_inset
18505
18506  that you don't place anything 
18507 \emph on
18508 into
18509 \emph default
18510  these two environments, however.
18511  When you create an 
18512 \family sans
18513 InvisibleText
18514 \family default
18515 , it inserts a centered, sky-blue label into the page reading 
18516 \begin_inset Quotes eld
18517 \end_inset
18518
18519 <Invisible Text Follows>
18520 \begin_inset Quotes erd
18521 \end_inset
18522
18523 .
18524  For paragraphs following this label, the parts of the 
18525 \family sans
18526 Slide
18527 \family default
18528  [or 
18529 \family sans
18530 Overlay
18531 \family default
18532 ; it doesn't matter which] where they would be contain instead blank space.
18533  
18534 \end_layout
18535
18536 \begin_layout Standard
18537 For 
18538 \family sans
18539 VisibleText
18540 \family default
18541 , the corresponding centered label is 
18542 \begin_inset Quotes eld
18543 \end_inset
18544
18545 <Visible Text Follows>
18546 \begin_inset Quotes erd
18547 \end_inset
18548
18549  in blazing green.
18550  Paragraphs following this label behave normally.
18551  Note that the beginning of a new 
18552 \family sans
18553 Slide
18554 \family default
18555
18556 \family sans
18557 Overlay
18558 \family default
18559 , or 
18560 \family sans
18561 Note
18562 \family default
18563  automatically shuts off an 
18564 \family sans
18565 InvisibleText
18566 \family default
18567 .
18568  It's therefore not necessary to use 
18569 \family sans
18570 VisibleText
18571 \family default
18572  at the end of a 
18573 \family sans
18574 Slide
18575 \family default
18576 .
18577 \end_layout
18578
18579 \begin_layout Standard
18580 By now, it should be obvious how to create overlay transparencies using
18581  the proper combination of 
18582 \family sans
18583 InvisibleText
18584 \family default
18585  and 
18586 \family sans
18587 VisibleText
18588 \family default
18589  on a 
18590 \family sans
18591 Slide
18592 \family default
18593  and 
18594 \family sans
18595 Overlay
18596 \family default
18597 :
18598 \end_layout
18599
18600 \begin_layout Enumerate
18601 Create a 
18602 \family sans
18603 Slide
18604 \family default
18605 , including everything that will appear on it, whether on the main slide
18606  or on the 
18607 \family sans
18608 Overlay
18609 \family default
18610 .
18611 \end_layout
18612
18613 \begin_layout Enumerate
18614 Before each figure or paragraph that will appear only on the 
18615 \family sans
18616 Overlay
18617 \family default
18618 , insert an 
18619 \family sans
18620 InvisibleText
18621 \family default
18622  environment.
18623  If necessary, insert a 
18624 \family sans
18625 VisibleText
18626 \family default
18627  environment after the 
18628 \family sans
18629 Overlay
18630 \family default
18631 -only text.
18632 \end_layout
18633
18634 \begin_layout Enumerate
18635 Start an 
18636 \family sans
18637 Overlay
18638 \family default
18639  immediately following the 
18640 \family sans
18641 Slide
18642 \family default
18643 .
18644 \end_layout
18645
18646 \begin_layout Enumerate
18647 Copy the contents of this 
18648 \family sans
18649 Slide
18650 \family default
18651  into the 
18652 \family sans
18653 Overlay
18654 \family default
18655 .
18656 \end_layout
18657
18658 \begin_layout Enumerate
18659 Within the 
18660 \family sans
18661 Overlay
18662 \family default
18663 , change all of the 
18664 \family sans
18665 InvisibleText
18666 \family default
18667  lines to 
18668 \family sans
18669 VisibleText
18670 \family default
18671  and vice-versa.
18672 \end_layout
18673
18674 \begin_layout Standard
18675 That's it.
18676  You've just made an 
18677 \family sans
18678 Overlay
18679 \family default
18680 .
18681 \end_layout
18682
18683 \begin_layout Standard
18684 There's one problem with the way I've designed the \SpecialChar LyX
18685  
18686 \family sans
18687 slides
18688 \family default
18689  class: you can't make text in the middle of a paragraph invisible, nor
18690  make text in the middle of an invisible paragraph visible again.
18691  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
18692  codes.
18693 \begin_inset Foot
18694 status collapsed
18695
18696 \begin_layout Plain Layout
18697 The commands of interest are: 
18698 \end_layout
18699
18700 \begin_layout Itemize
18701
18702 \family typewriter
18703 {
18704 \backslash
18705 invisible \SpecialChar ldots
18706  }
18707 \end_layout
18708
18709 \begin_layout Itemize
18710
18711 \family typewriter
18712 {
18713 \backslash
18714 visible \SpecialChar ldots
18715  }
18716 \end_layout
18717
18718 \begin_layout Plain Layout
18719 \SpecialChar ldots
18720 and need to be marked as \SpecialChar TeX
18721 .
18722  The text whose 
18723 \begin_inset Quotes eld
18724 \end_inset
18725
18726 visibility
18727 \begin_inset Quotes erd
18728 \end_inset
18729
18730  you wish to change goes in between the brackets [and after the 
18731 \family typewriter
18732
18733 \backslash
18734 invisible
18735 \family default
18736  or 
18737 \family typewriter
18738
18739 \backslash
18740 visible
18741 \family default
18742  command].
18743  If you don't know how to mark text as \SpecialChar TeX
18744 , see the appropriate section of
18745  the 
18746 \emph on
18747 User's Guide
18748 \emph default
18749 .
18750 \end_layout
18751
18752 \end_inset
18753
18754
18755 \end_layout
18756
18757 \begin_layout Subsubsection
18758 Using 
18759 \family sans
18760 Note
18761 \family default
18762  with 
18763 \family sans
18764 Slide
18765 \family default
18766
18767 \begin_inset CommandInset label
18768 LatexCommand label
18769 name "sec:slideNote"
18770
18771 \end_inset
18772
18773
18774 \end_layout
18775
18776 \begin_layout Standard
18777 Like an 
18778 \family sans
18779 Overlay
18780 \family default
18781 , a 
18782 \family sans
18783 Note
18784 \family default
18785  is associated with a 
18786 \begin_inset Quotes eld
18787 \end_inset
18788
18789 parent
18790 \begin_inset Quotes erd
18791 \end_inset
18792
18793  
18794 \family sans
18795 Slide
18796 \family default
18797 .
18798  Here, too, the \SpecialChar LyX
18799  
18800 \family sans
18801 slides
18802 \family default
18803  class provides visual cues.
18804  The label for a 
18805 \family sans
18806 Note
18807 \family default
18808  is shorter than that of a 
18809 \family sans
18810 Slide
18811 \family default
18812  [yet longer than that of an 
18813 \family sans
18814 Overlay
18815 \family default
18816 ] and, like the label of an 
18817 \family sans
18818 Overlay
18819 \family default
18820  is shockingly magenta.
18821  Additionally, the printed 
18822 \family sans
18823 Note
18824 \family default
18825  has the page number of its 
18826 \begin_inset Quotes eld
18827 \end_inset
18828
18829 parent
18830 \begin_inset Quotes erd
18831 \end_inset
18832
18833  
18834 \family sans
18835 Slide
18836 \family default
18837 , appended by 
18838 \begin_inset Quotes eld
18839 \end_inset
18840
18841
18842 \family typewriter
18843 -
18844 \family default
18845 1
18846 \begin_inset Quotes erd
18847 \end_inset
18848
18849
18850 \begin_inset Quotes eld
18851 \end_inset
18852
18853
18854 \family typewriter
18855 -
18856 \family default
18857 2
18858 \begin_inset Quotes erd
18859 \end_inset
18860
18861
18862 \begin_inset Quotes eld
18863 \end_inset
18864
18865
18866 \family typewriter
18867 -
18868 \family default
18869 3
18870 \begin_inset Quotes erd
18871 \end_inset
18872
18873 , etc.
18874  You can have multiple 
18875 \family sans
18876 Note
18877 \family default
18878 s associated with a single 
18879 \family sans
18880 Slide
18881 \family default
18882 , and, as with 
18883 \family sans
18884 Slide
18885 \family default
18886  and 
18887 \family sans
18888 Overlay
18889 \family default
18890 , you'll probably want to break up long 
18891 \family sans
18892 Note
18893 \family default
18894 s so that they fit on a single sheet of paper.
18895 \end_layout
18896
18897 \begin_layout Standard
18898 The purpose of a 
18899 \family sans
18900 Note
18901 \family default
18902  is obvious: it contains anything additional you might want to say about
18903  a 
18904 \family sans
18905 Slide
18906 \family default
18907 .
18908  It could also be used as a sheet of reminders for a particular 
18909 \family sans
18910 Slide
18911 \family default
18912 .
18913  In the case of the latter, you might want to make use of time markers.
18914  Currently, the \SpecialChar LyX
18915  
18916 \family sans
18917 slides
18918 \family default
18919  class has no 
18920 \begin_inset Quotes eld
18921 \end_inset
18922
18923 native
18924 \begin_inset Quotes erd
18925 \end_inset
18926
18927  support for time markers, a 
18928 \noun on
18929 Sli\SpecialChar TeX
18930
18931 \noun default
18932  feature.
18933  So, you'll have to resort to using the \SpecialChar LaTeX
18934  codes.
18935 \end_layout
18936
18937 \begin_layout Standard
18938 To use time markers, you'll need to specify the extra class option 
18939 \begin_inset Quotes eld
18940 \end_inset
18941
18942
18943 \family typewriter
18944 clock
18945 \family default
18946
18947 \begin_inset Quotes erd
18948 \end_inset
18949
18950  [see section
18951 \begin_inset space ~
18952 \end_inset
18953
18954
18955 \begin_inset CommandInset ref
18956 LatexCommand ref
18957 reference "sec:slidesetup"
18958
18959 \end_inset
18960
18961 ].
18962  This option turns on timing marks, which will appear in the lower-left-hand
18963  corner of every 
18964 \family sans
18965 Note
18966 \family default
18967  you generate.
18968  To set what appears in the time marker, you use the \SpecialChar LaTeX
18969  commands 
18970 \begin_inset Quotes eld
18971 \end_inset
18972
18973
18974 \family typewriter
18975
18976 \backslash
18977 settime{}
18978 \family default
18979
18980 \begin_inset Quotes erd
18981 \end_inset
18982
18983  and 
18984 \begin_inset Quotes eld
18985 \end_inset
18986
18987
18988 \family typewriter
18989
18990 \backslash
18991 addtime{}
18992 \family default
18993
18994 \begin_inset Quotes erd
18995 \end_inset
18996
18997 .
18998  The arguments of both commands are time measured in seconds.
18999  
19000 \begin_inset Quotes eld
19001 \end_inset
19002
19003
19004 \family typewriter
19005
19006 \backslash
19007 settime{}
19008 \family default
19009
19010 \begin_inset Quotes erd
19011 \end_inset
19012
19013  sets the time marker to a given time.
19014  
19015 \begin_inset Quotes eld
19016 \end_inset
19017
19018
19019 \family typewriter
19020
19021 \backslash
19022 addtime{}
19023 \family default
19024
19025 \begin_inset Quotes erd
19026 \end_inset
19027
19028  increments the time marker by the specified amount.
19029  Using time markers and 
19030 \family sans
19031 Note
19032 \family default
19033 s in this fashion, you can remind yourself how much time to spend on a particula
19034
19035 \family sans
19036 Slide
19037 \family default
19038 .
19039 \end_layout
19040
19041 \begin_layout Standard
19042 There's one last feature to describe.
19043  Clearly, you'd like to print out all of your 
19044 \family sans
19045 Slide
19046 \family default
19047 s and 
19048 \family sans
19049 Overlay
19050 \family default
19051 s on transparencies while printing all of your 
19052 \family sans
19053 Note
19054 \family default
19055 s on plain paper.
19056  However, a 
19057 \family sans
19058 Note
19059 \family default
19060  
19061 \emph on
19062 must
19063 \emph default
19064  follow the 
19065 \family sans
19066 Slide
19067 \family default
19068  with which it is associated.
19069  What's a person to do?
19070 \end_layout
19071
19072 \begin_layout Standard
19073 Luckily, there are two \SpecialChar LaTeX
19074  commands that allow you to select what to print
19075  out.
19076  Both must be placed into the preamble of your document.
19077  The command 
19078 \begin_inset Quotes eld
19079 \end_inset
19080
19081
19082 \family typewriter
19083
19084 \backslash
19085 onlyslides{
19086 \backslash
19087 slides}
19088 \family default
19089
19090 \begin_inset Quotes erd
19091 \end_inset
19092
19093  will cause the output to contain only the 
19094 \family sans
19095 Slide
19096 \family default
19097 s and 
19098 \family sans
19099 Overlay
19100 \family default
19101 s.
19102  Correspondingly, the command 
19103 \begin_inset Quotes eld
19104 \end_inset
19105
19106
19107 \family typewriter
19108
19109 \backslash
19110 onlynotes{
19111 \backslash
19112 notes}
19113 \family default
19114
19115 \begin_inset Quotes erd
19116 \end_inset
19117
19118  prevents the output of anything but 
19119 \family sans
19120 Note
19121 \family default
19122 s.
19123  I'd advise placing both commands in the preamble and initially comment
19124  both out.
19125  You can then preview your entire presentation as you write.
19126  When you're done writing, you can then uncomment one of the two to select
19127  what you want to print.
19128  I like to uncomment 
19129 \begin_inset Quotes eld
19130 \end_inset
19131
19132
19133 \family typewriter
19134
19135 \backslash
19136 onlyslides{
19137 \backslash
19138 slides}
19139 \family default
19140
19141 \begin_inset Quotes erd
19142 \end_inset
19143
19144  , print to a file with 
19145 \begin_inset Quotes eld
19146 \end_inset
19147
19148
19149 \family typewriter
19150 -slides
19151 \family default
19152
19153 \begin_inset Quotes erd
19154 \end_inset
19155
19156  in its name, comment it back out, then uncomment 
19157 \begin_inset Quotes eld
19158 \end_inset
19159
19160
19161 \family typewriter
19162
19163 \backslash
19164 onlynotes{
19165 \backslash
19166 notes}
19167 \family default
19168
19169 \begin_inset Quotes erd
19170 \end_inset
19171
19172  and print to a 
19173 \begin_inset Quotes eld
19174 \end_inset
19175
19176
19177 \family typewriter
19178 *-notes.ps
19179 \family default
19180
19181 \begin_inset Quotes erd
19182 \end_inset
19183
19184  file.
19185  I can then send either file to a printer, loading transparencies or plain
19186  paper as appropriate.
19187 \end_layout
19188
19189 \begin_layout Standard
19190 You can also provide other arguments to the 
19191 \begin_inset Quotes eld
19192 \end_inset
19193
19194
19195 \family typewriter
19196
19197 \backslash
19198 onlyslides{}
19199 \family default
19200
19201 \begin_inset Quotes erd
19202 \end_inset
19203
19204  and 
19205 \begin_inset Quotes eld
19206 \end_inset
19207
19208
19209 \family typewriter
19210
19211 \backslash
19212 onlynotes{}
19213 \family default
19214
19215 \begin_inset Quotes erd
19216 \end_inset
19217
19218  commands.
19219  See a good \SpecialChar LaTeX
19220  book for details.
19221 \end_layout
19222
19223 \begin_layout Subsection
19224 The 
19225 \family sans
19226 slides
19227 \family default
19228  Class Template File
19229 \end_layout
19230
19231 \begin_layout Standard
19232 I have also provided a template file, 
19233 \begin_inset Quotes eld
19234 \end_inset
19235
19236
19237 \family typewriter
19238 slides.lyx
19239 \family default
19240
19241 \begin_inset Quotes erd
19242 \end_inset
19243
19244 , with the 
19245 \family sans
19246 slides
19247 \family default
19248  class.
19249  To use it, begin your new presentation with 
19250 \family sans
19251 File\SpecialChar menuseparator
19252 New
19253 \begin_inset space ~
19254 \end_inset
19255
19256 from
19257 \begin_inset space ~
19258 \end_inset
19259
19260 Template
19261 \family default
19262 .
19263  Your new \SpecialChar LyX
19264  presentation file will contain an example 
19265 \family sans
19266 Slide
19267 \family default
19268  – 
19269 \family sans
19270 Overlay
19271 \family default
19272  – 
19273 \family sans
19274 Note
19275 \family default
19276  triplet.
19277  The 
19278 \family sans
19279 Slide
19280 \family default
19281  and 
19282 \family sans
19283 Overlay
19284 \family default
19285  additionally contain an example of the use of 
19286 \family sans
19287 InvisibleText
19288 \family default
19289  and 
19290 \family sans
19291 VisibleText
19292 \family default
19293 .
19294  Lastly, the preamble will contain:
19295 \end_layout
19296
19297 \begin_layout LyX-Code
19298 % Uncomment to print out only slides and overlays
19299 \end_layout
19300
19301 \begin_layout LyX-Code
19302 %
19303 \end_layout
19304
19305 \begin_layout LyX-Code
19306 %
19307 \backslash
19308 onlyslides{
19309 \backslash
19310 slides}
19311 \begin_inset Newline newline
19312 \end_inset
19313
19314  
19315 \end_layout
19316
19317 \begin_layout LyX-Code
19318 % Uncomment to print out only notes
19319 \end_layout
19320
19321 \begin_layout LyX-Code
19322 %
19323 \end_layout
19324
19325 \begin_layout LyX-Code
19326 %
19327 \backslash
19328 onlynotes{
19329 \backslash
19330 notes}
19331 \end_layout
19332
19333 \begin_layout Standard
19334 One final thing: I created this class to support the \SpecialChar LaTeX2e
19335  
19336 \begin_inset Quotes eld
19337 \end_inset
19338
19339
19340 \noun on
19341 Sli\SpecialChar TeX
19342
19343 \noun default
19344  emulation
19345 \begin_inset Quotes erd
19346 \end_inset
19347
19348  class, one of the built-in \SpecialChar LaTeX2e
19349  classes.
19350  Neither I nor the rest of the \SpecialChar LyX
19351  Team endorse or oppose the use of this built-in
19352  slide class.
19353  It's here if you want it or need it.
19354  There exist other \SpecialChar LaTeX2e
19355  classes for creating presentations, such as the 
19356 \family sans
19357 Foils
19358 \family default
19359  class [see section
19360 \begin_inset space ~
19361 \end_inset
19362
19363
19364 \begin_inset CommandInset ref
19365 LatexCommand ref
19366 reference "sec:foiltex"
19367
19368 \end_inset
19369
19370 ] or the 
19371 \begin_inset Quotes eld
19372 \end_inset
19373
19374
19375 \family typewriter
19376 seminar
19377 \family default
19378
19379 \begin_inset Quotes erd
19380 \end_inset
19381
19382  package [present on some \SpecialChar TeX
19383  distributions].
19384  The latter is not yet supported under \SpecialChar LyX
19385 .
19386 \begin_inset Foot
19387 status collapsed
19388
19389 \begin_layout Plain Layout
19390 Perhaps you can take on the task\SpecialChar ldots
19391
19392 \end_layout
19393
19394 \end_inset
19395
19396  I know nothing about these other classes.
19397  Try them out to see what sort of alternative they provide.
19398 \end_layout
19399
19400 \begin_layout Chapter
19401 \SpecialChar LyX
19402  Features needing Extra Software
19403 \end_layout
19404
19405 \begin_layout Section
19406 Checking \SpecialChar TeX
19407
19408 \end_layout
19409
19410 \begin_layout Standard
19411 by 
19412 \noun on
19413 Asger Alstrup
19414 \end_layout
19415
19416 \begin_layout Subsection
19417 Introduction
19418 \end_layout
19419
19420 \begin_layout Standard
19421 If you have the 
19422 \family typewriter
19423 chktex
19424 \family default
19425  program installed
19426 \begin_inset Foot
19427 status collapsed
19428
19429 \begin_layout Plain Layout
19430
19431 \family typewriter
19432 chktex
19433 \family default
19434  is not yet available when you are using the \SpecialChar LaTeX
19435  distribution MiK\SpecialChar TeX
19436 .
19437 \end_layout
19438
19439 \end_inset
19440
19441 , you'll find in the 
19442 \family sans
19443 Tools
19444 \family default
19445  menu the entry: 
19446 \family sans
19447 Check
19448 \begin_inset space ~
19449 \end_inset
19450
19451 TeX
19452 \family default
19453 .
19454  You can get 
19455 \family typewriter
19456 chktex
19457 \family default
19458  from CTAN,
19459 \begin_inset Newline newline
19460 \end_inset
19461
19462
19463 \begin_inset CommandInset href
19464 LatexCommand href
19465 target "http://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
19466 literal "false"
19467
19468 \end_inset
19469
19470 .
19471 \end_layout
19472
19473 \begin_layout Standard
19474 The 
19475 \family sans
19476 Chk\SpecialChar TeX
19477
19478 \family default
19479  package is a program that was written by 
19480 \begin_inset Flex Noun
19481 status collapsed
19482
19483 \begin_layout Plain Layout
19484 Jens T.
19485 \begin_inset space ~
19486 \end_inset
19487
19488 Berger Thielemann
19489 \end_layout
19490
19491 \end_inset
19492
19493  in frustration because some constructs in \SpecialChar LaTeX
19494  are sometimes non-intuitive,
19495  and easy to forget.
19496  The program runs over your \SpecialChar LaTeX
19497  file, checks the integrity of the file, and
19498  flags some common errors.
19499  In other technical words, it is 
19500 \family typewriter
19501 lint
19502 \family default
19503  for \SpecialChar LaTeX
19504 .
19505 \end_layout
19506
19507 \begin_layout Standard
19508 Well, what is a syntax checker doing in \SpecialChar LyX
19509  which is supposed to produce correct
19510  \SpecialChar LaTeX
19511  anyways? The answer is simple: Just as 
19512 \family typewriter
19513 Lint
19514 \family default
19515  not only checks the 
19516 \emph on
19517 syntax
19518 \emph default
19519  of C programs, but also does 
19520 \emph on
19521 semantic
19522 \emph default
19523  checks for type-errors, 
19524 \family sans
19525 Chk\SpecialChar TeX
19526
19527 \family default
19528  catches some common 
19529 \emph on
19530 typographic
19531 \emph default
19532  errors, in addition to the syntactical ones.
19533  Specifically, 
19534 \family sans
19535 Chk\SpecialChar TeX
19536
19537 \family default
19538  is capable of detecting several common errors, such as
19539 \end_layout
19540
19541 \begin_layout Itemize
19542 Ellipsis detection:
19543 \begin_inset Newline newline
19544 \end_inset
19545
19546 Use \SpecialChar ldots
19547  instead of ...
19548 \end_layout
19549
19550 \begin_layout Itemize
19551 No space in front of/after parenthesis:
19552 \begin_inset Newline newline
19553 \end_inset
19554
19555 ( wrong spacing )
19556 \end_layout
19557
19558 \begin_layout Itemize
19559 Enforcement of normal space after common abbreviations:
19560 \begin_inset Newline newline
19561 \end_inset
19562
19563 e.
19564 \begin_inset space \thinspace{}
19565 \end_inset
19566
19567 g.
19568 \begin_inset space \space{}
19569 \end_inset
19570
19571 is too wide spacing.
19572 \end_layout
19573
19574 \begin_layout Itemize
19575 Enforcement of end-of-sentence space when the last sentence ends with a
19576  capital letter:
19577 \begin_inset Newline newline
19578 \end_inset
19579
19580 This is a TEST.
19581  And this is wrong spacing.
19582 \end_layout
19583
19584 \begin_layout Itemize
19585 Space in front of labels and similar commands:
19586 \begin_inset Newline newline
19587 \end_inset
19588
19589 The label should stick right up to the text to avoid falling to a wrong
19590  page.
19591  
19592 \begin_inset CommandInset label
19593 LatexCommand label
19594 name "sec:chktex"
19595
19596 \end_inset
19597
19598  
19599 \begin_inset Foot
19600 status collapsed
19601
19602 \begin_layout Plain Layout
19603 This footnote is in danger of falling off to a wrong page
19604 \end_layout
19605
19606 \end_inset
19607
19608  The label is separated too much.
19609 \end_layout
19610
19611 \begin_layout Itemize
19612 Space in front of references, instead of hard spaces:
19613 \begin_inset Newline newline
19614 \end_inset
19615
19616 If you have bad luck, the text will break right between the referenced text
19617  and reference number, and that's a pity.
19618  See section 
19619 \begin_inset CommandInset ref
19620 LatexCommand ref
19621 reference "sec:chktex"
19622
19623 \end_inset
19624
19625 .
19626 \end_layout
19627
19628 \begin_layout Itemize
19629 Use of 
19630 \begin_inset Quotes eld
19631 \end_inset
19632
19633 x
19634 \begin_inset Quotes erd
19635 \end_inset
19636
19637  instead of 
19638 \begin_inset Formula $\times$
19639 \end_inset
19640
19641  between numbers:
19642 \begin_inset Newline newline
19643 \end_inset
19644
19645 2x2 looks cheap compared to 
19646 \begin_inset Formula $2\times2$
19647 \end_inset
19648
19649 .
19650 \end_layout
19651
19652 \begin_layout Standard
19653 and more \SpecialChar ldots
19654  It is an invaluable tool when you are 
19655 \begin_inset Quotes eld
19656 \end_inset
19657
19658 finishing up
19659 \begin_inset Quotes erd
19660 \end_inset
19661
19662  your document before printing, and you should run it right after the obligatory
19663  spelling check, and before you go fine tuning the typesetting.
19664 \end_layout
19665
19666 \begin_layout Subsection
19667 How to use it
19668 \end_layout
19669
19670 \begin_layout Standard
19671 If you have the program installed, usage is as simple as choosing 
19672 \family sans
19673 Tools\SpecialChar menuseparator
19674 Check
19675 \begin_inset space ~
19676 \end_inset
19677
19678 TeX
19679 \family default
19680 .
19681  This will make \SpecialChar LyX
19682  generate a \SpecialChar LaTeX
19683  file of your document, start 
19684 \family sans
19685 Chk\SpecialChar TeX
19686
19687 \family default
19688  to check it, and then make \SpecialChar LyX
19689  insert 
19690 \begin_inset Quotes eld
19691 \end_inset
19692
19693 error boxes
19694 \begin_inset Quotes erd
19695 \end_inset
19696
19697  with the warnings from 
19698 \family sans
19699 Chk\SpecialChar TeX
19700
19701 \family default
19702 , if there were any.
19703  The warnings will be placed close to the point of the mistake, and you
19704  can quickly find them by using the 
19705 \family sans
19706 Navigate\SpecialChar menuseparator
19707 Error
19708 \family default
19709  menu item, or the shortcut key 
19710 \family sans
19711 C-g
19712 \family default
19713  from the default 
19714 \family typewriter
19715 cua
19716 \family default
19717  bind file.
19718  Open the error boxes by clicking on them with the mouse, or use the shortcut
19719  key 
19720 \family sans
19721 C-i
19722 \family default
19723  from 
19724 \family typewriter
19725 cua
19726 \family default
19727  bindings, or the corresponding 
19728 \family sans
19729 C-o
19730 \family default
19731  for the alternate 
19732 \family typewriter
19733 emacs
19734 \family default
19735  bind file.
19736  Read the warning and correct the mistake, if it is a mistake.
19737  If you have trouble understanding what the warning is about, you can safely
19738  ignore it.
19739  Remember that there is a hidden layer between the document on screen and
19740  the technical details in invoking 
19741 \family sans
19742 Chk\SpecialChar TeX
19743
19744 \family default
19745 , and this gap can make some warnings seem arcane or just plain silly.
19746 \end_layout
19747
19748 \begin_layout Standard
19749 This document is an excellent testing bed for the feature, and it should
19750  provide quite a few warnings for you to fiddle with.
19751  Since computers are only so smart, expect most of the warnings to be false
19752  alarms, though.
19753 \end_layout
19754
19755 \begin_layout Subsection
19756 How to fine tune it
19757 \end_layout
19758
19759 \begin_layout Standard
19760 Sometimes, you'll find that 
19761 \family sans
19762 Chk\SpecialChar TeX
19763
19764 \family default
19765  makes more noise than suits your mood.
19766  Then you can choose not to use it, wait until your mood changes, or try
19767  to customize 
19768 \family sans
19769 Chk\SpecialChar TeX
19770
19771 \family default
19772  to get better along with you.
19773 \end_layout
19774
19775 \begin_layout Standard
19776 Although 
19777 \family sans
19778 Chk\SpecialChar TeX
19779
19780 \family default
19781  
19782 \emph on
19783 is
19784 \emph default
19785  very configurable and extensible, you should not expect to solve all problems
19786  with 
19787 \family sans
19788 Chk\SpecialChar TeX
19789
19790 \family default
19791  in \SpecialChar LyX
19792  this way.
19793  Since \SpecialChar LyX
19794  has to generate a somewhat special \SpecialChar LaTeX
19795  file to be able to match the
19796  line numbers from the 
19797 \family sans
19798 Chk\SpecialChar TeX
19799
19800 \family default
19801  output
19802 \begin_inset Foot
19803 status collapsed
19804
19805 \begin_layout Plain Layout
19806 You can inspect the specific output from 
19807 \family sans
19808 chktex
19809 \family default
19810  by using 
19811 \family sans
19812 Document\SpecialChar menuseparator
19813 \SpecialChar LaTeX
19814
19815 \begin_inset space ~
19816 \end_inset
19817
19818 Log
19819 \family default
19820  right after a 
19821 \family sans
19822 chktex
19823 \family default
19824  run.
19825 \end_layout
19826
19827 \end_inset
19828
19829  to the internal document structure, some of the warnings will not appear
19830  correctly.
19831  There are two things you can do about this:
19832 \end_layout
19833
19834 \begin_layout Itemize
19835 Fine tune the 
19836 \family sans
19837 Chk\SpecialChar TeX
19838
19839 \family default
19840  invocation command line in 
19841 \begin_inset Flex Noun
19842 status collapsed
19843
19844 \begin_layout Plain Layout
19845 Tools\SpecialChar menuseparator
19846 Preferences\SpecialChar menuseparator
19847 Output\SpecialChar menuseparator
19848 LaTeX\SpecialChar menuseparator
19849 CheckTeX command
19850 \end_layout
19851
19852 \end_inset
19853
19854 , or the global 
19855 \family sans
19856 Chk\SpecialChar TeX
19857
19858 \family default
19859  installation configuration file (usually with the file 
19860 \family typewriter
19861 chktexrc
19862 \family default
19863 ).
19864  See below to learn what warnings can be enabled and disabled on the command
19865  line.
19866 \end_layout
19867
19868 \begin_layout Itemize
19869 Export your document as a raw \SpecialChar LaTeX
19870  file using 
19871 \family sans
19872 File\SpecialChar menuseparator
19873 Export\SpecialChar menuseparator
19874 \SpecialChar LaTeX
19875
19876 \family default
19877  and run 
19878 \family typewriter
19879 chktex
19880 \family default
19881  manually on that.
19882  Invoked in this way, it can be a hassle to find the corresponding place
19883  in the document inside \SpecialChar LyX
19884 , but with a little patience, you should be able
19885  to do it.
19886 \end_layout
19887
19888 \begin_layout Standard
19889 Here follows the warning messages that can be enabled and disabled in 
19890 \family sans
19891 Preferences
19892 \family default
19893 .
19894  Use 
19895 \family typewriter
19896 -n#
19897 \family default
19898  to disable a warning, and 
19899 \family typewriter
19900 -w#
19901 \family default
19902  to enable a warning.
19903  The emphasized entries are disabled by default, because the default is
19904  "
19905 \family typewriter
19906 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19907 \family default
19908 ".
19909 \end_layout
19910
19911 \begin_layout Standard
19912 Notice that you should only use the options that enable and disable warnings,
19913  because \SpecialChar LyX
19914  relies on some of the other command line parameters to be set
19915  in a specific way to have a chance to communicate with 
19916 \family typewriter
19917 chktex
19918 \family default
19919 .
19920 \end_layout
19921
19922 \begin_layout Enumerate
19923
19924 \size small
19925 \emph on
19926 Command terminated with space.
19927 \end_layout
19928
19929 \begin_layout Enumerate
19930
19931 \size small
19932 Non-breaking space (
19933 \begin_inset Quotes eld
19934 \end_inset
19935
19936
19937 \family typewriter
19938 ~
19939 \family default
19940
19941 \begin_inset Quotes erd
19942 \end_inset
19943
19944 ) should have been used.
19945 \end_layout
19946
19947 \begin_layout Enumerate
19948
19949 \size small
19950 \emph on
19951 You should enclose the previous parenthesis with 
19952 \begin_inset Quotes eld
19953 \end_inset
19954
19955
19956 \family typewriter
19957 {}
19958 \family default
19959
19960 \begin_inset Quotes erd
19961 \end_inset
19962
19963 .
19964 \end_layout
19965
19966 \begin_layout Enumerate
19967
19968 \size small
19969 Italic correction (
19970 \begin_inset Quotes eld
19971 \end_inset
19972
19973
19974 \family typewriter
19975
19976 \backslash
19977 /
19978 \family default
19979
19980 \begin_inset Quotes erd
19981 \end_inset
19982
19983 ) found in non-italic buffer.
19984 \end_layout
19985
19986 \begin_layout Enumerate
19987
19988 \size small
19989 Italic correction (
19990 \begin_inset Quotes eld
19991 \end_inset
19992
19993
19994 \family typewriter
19995
19996 \backslash
19997 /
19998 \family default
19999
20000 \begin_inset Quotes erd
20001 \end_inset
20002
20003 ) found more than once.
20004 \end_layout
20005
20006 \begin_layout Enumerate
20007
20008 \size small
20009 \emph on
20010 No italic correction (
20011 \begin_inset Quotes eld
20012 \end_inset
20013
20014
20015 \family typewriter
20016
20017 \backslash
20018 /
20019 \family default
20020
20021 \begin_inset Quotes erd
20022 \end_inset
20023
20024 ) found.
20025 \end_layout
20026
20027 \begin_layout Enumerate
20028
20029 \size small
20030 Accent command 
20031 \begin_inset Quotes eld
20032 \end_inset
20033
20034
20035 \family typewriter
20036 cmd
20037 \family default
20038
20039 \begin_inset Quotes erd
20040 \end_inset
20041
20042  needs use of 
20043 \begin_inset Quotes eld
20044 \end_inset
20045
20046
20047 \family typewriter
20048 cmd
20049 \family default
20050
20051 \begin_inset Quotes erd
20052 \end_inset
20053
20054 .
20055 \end_layout
20056
20057 \begin_layout Enumerate
20058
20059 \size small
20060 Wrong length of dash may have been used.
20061 \end_layout
20062
20063 \begin_layout Enumerate
20064
20065 \size small
20066 \emph on
20067 \begin_inset Quotes eld
20068 \end_inset
20069
20070
20071 \family typewriter
20072 %s
20073 \family default
20074
20075 \begin_inset Quotes erd
20076 \end_inset
20077
20078  expected, found 
20079 \begin_inset Quotes eld
20080 \end_inset
20081
20082
20083 \family typewriter
20084 %s
20085 \family default
20086
20087 \begin_inset Quotes erd
20088 \end_inset
20089
20090 .
20091 \end_layout
20092
20093 \begin_layout Enumerate
20094
20095 \size small
20096 Solo 
20097 \begin_inset Quotes eld
20098 \end_inset
20099
20100
20101 \family typewriter
20102 %s
20103 \family default
20104
20105 \begin_inset Quotes erd
20106 \end_inset
20107
20108  found.
20109 \end_layout
20110
20111 \begin_layout Enumerate
20112
20113 \size small
20114 You should use 
20115 \begin_inset Quotes eld
20116 \end_inset
20117
20118
20119 \family typewriter
20120 %s
20121 \family default
20122
20123 \begin_inset Quotes erd
20124 \end_inset
20125
20126  to achieve an ellipsis.
20127 \end_layout
20128
20129 \begin_layout Enumerate
20130
20131 \size small
20132 Inter-word spacing (
20133 \begin_inset Quotes eld
20134 \end_inset
20135
20136
20137 \family typewriter
20138
20139 \backslash
20140
20141 \family default
20142  
20143 \begin_inset Quotes eld
20144 \end_inset
20145
20146 ) should perhaps be used.
20147 \end_layout
20148
20149 \begin_layout Enumerate
20150
20151 \size small
20152 Inter-sentence spacing (
20153 \begin_inset Quotes eld
20154 \end_inset
20155
20156
20157 \family typewriter
20158
20159 \backslash
20160 @
20161 \family default
20162
20163 \begin_inset Quotes erd
20164 \end_inset
20165
20166 ) should perhaps be used.
20167 \end_layout
20168
20169 \begin_layout Enumerate
20170
20171 \size small
20172 Could not find argument for command.
20173 \end_layout
20174
20175 \begin_layout Enumerate
20176
20177 \size small
20178 No match found for 
20179 \begin_inset Quotes eld
20180 \end_inset
20181
20182
20183 \family typewriter
20184 %s
20185 \family default
20186
20187 \begin_inset Quotes erd
20188 \end_inset
20189
20190 .
20191 \end_layout
20192
20193 \begin_layout Enumerate
20194
20195 \size small
20196 Math mode still on at end of \SpecialChar LaTeX
20197  file.
20198 \end_layout
20199
20200 \begin_layout Enumerate
20201
20202 \size small
20203 Number of 
20204 \begin_inset Quotes eld
20205 \end_inset
20206
20207
20208 \family typewriter
20209 char
20210 \family default
20211
20212 \begin_inset Quotes erd
20213 \end_inset
20214
20215  doesn't match the number of 
20216 \begin_inset Quotes eld
20217 \end_inset
20218
20219
20220 \family typewriter
20221 char
20222 \family default
20223
20224 \begin_inset Quotes erd
20225 \end_inset
20226
20227 .
20228 \end_layout
20229
20230 \begin_layout Enumerate
20231
20232 \size small
20233 You should use either 
20234 \family typewriter
20235
20236 \begin_inset Quotes eld
20237 \end_inset
20238
20239
20240 \family default
20241  or 
20242 \family typewriter
20243
20244 \begin_inset Quotes erd
20245 \end_inset
20246
20247
20248 \family default
20249  as an alternative to 
20250 \begin_inset Quotes eld
20251 \end_inset
20252
20253
20254 \family typewriter
20255 "
20256 \family default
20257
20258 \begin_inset Quotes erd
20259 \end_inset
20260
20261 .
20262 \end_layout
20263
20264 \begin_layout Enumerate
20265
20266 \size small
20267 You should use "
20268 \family typewriter
20269 '
20270 \family default
20271 " (ASCII 39) instead of "
20272 \family typewriter
20273 ´
20274 \family default
20275 " (ASCII 180).
20276 \end_layout
20277
20278 \begin_layout Enumerate
20279
20280 \size small
20281 User-specified pattern found.
20282 \end_layout
20283
20284 \begin_layout Enumerate
20285
20286 \size small
20287 This command might not be intended.
20288 \end_layout
20289
20290 \begin_layout Enumerate
20291
20292 \size small
20293 \emph on
20294 Comment displayed.
20295 \end_layout
20296
20297 \begin_layout Enumerate
20298
20299 \size small
20300 Either 
20301 \family typewriter
20302 ''
20303 \backslash
20304 ,'
20305 \family default
20306  or 
20307 \family typewriter
20308 '
20309 \backslash
20310 ,''
20311 \family default
20312  will look better.
20313 \end_layout
20314
20315 \begin_layout Enumerate
20316
20317 \size small
20318 Delete this space to maintain correct page references.
20319 \end_layout
20320
20321 \begin_layout Enumerate
20322
20323 \size small
20324 \emph on
20325 You might wish to put this between a pair of 
20326 \begin_inset Quotes eld
20327 \end_inset
20328
20329
20330 \family typewriter
20331 {}
20332 \family default
20333
20334 \begin_inset Quotes erd
20335 \end_inset
20336
20337 .
20338 \end_layout
20339
20340 \begin_layout Enumerate
20341
20342 \size small
20343 You ought to remove spaces in front of punctuation.
20344 \end_layout
20345
20346 \begin_layout Enumerate
20347
20348 \size small
20349 Could not execute \SpecialChar LaTeX
20350  command.
20351 \end_layout
20352
20353 \begin_layout Enumerate
20354
20355 \size small
20356 Don't use 
20357 \family typewriter
20358
20359 \backslash
20360 /
20361 \family default
20362  in front of small punctuation.
20363 \end_layout
20364
20365 \begin_layout Enumerate
20366
20367 \family typewriter
20368 \size small
20369 $
20370 \backslash
20371 times$
20372 \family default
20373  may look prettier here.
20374 \end_layout
20375
20376 \begin_layout Enumerate
20377
20378 \size small
20379 \emph on
20380 Multiple spaces detected in output.
20381 \end_layout
20382
20383 \begin_layout Enumerate
20384
20385 \size small
20386 This text may be ignored.
20387 \end_layout
20388
20389 \begin_layout Enumerate
20390
20391 \size small
20392 Use 
20393 \family typewriter
20394
20395 \begin_inset Quotes eld
20396 \end_inset
20397
20398
20399 \family default
20400  to begin quotation, not 
20401 \family typewriter
20402 '
20403 \family default
20404 .
20405 \end_layout
20406
20407 \begin_layout Enumerate
20408
20409 \size small
20410 Use 
20411 \family typewriter
20412 '
20413 \family default
20414  to end quotation, not 
20415 \family typewriter
20416
20417 \begin_inset Quotes eld
20418 \end_inset
20419
20420
20421 \family default
20422 .
20423 \end_layout
20424
20425 \begin_layout Enumerate
20426
20427 \size small
20428 Don't mix quotes.
20429 \end_layout
20430
20431 \begin_layout Enumerate
20432
20433 \size small
20434 You should perhaps use 
20435 \begin_inset Quotes eld
20436 \end_inset
20437
20438
20439 \family typewriter
20440 cmd
20441 \family default
20442
20443 \begin_inset Quotes erd
20444 \end_inset
20445
20446  instead.
20447 \end_layout
20448
20449 \begin_layout Enumerate
20450
20451 \size small
20452 You should put a space in front of/after parenthesis.
20453 \end_layout
20454
20455 \begin_layout Enumerate
20456
20457 \size small
20458 You should avoid spaces in front of/after parenthesis.
20459 \end_layout
20460
20461 \begin_layout Enumerate
20462
20463 \size small
20464 \emph on
20465 You should not use punctuation in front of/after quotes.
20466 \end_layout
20467
20468 \begin_layout Enumerate
20469
20470 \size small
20471 Double space found.
20472 \end_layout
20473
20474 \begin_layout Enumerate
20475
20476 \size small
20477 You should put punctuation outside inner/inside display math mode.
20478 \end_layout
20479
20480 \begin_layout Enumerate
20481
20482 \size small
20483 You ought to not use primitive \SpecialChar TeX
20484  in \SpecialChar LaTeX
20485  code.
20486 \end_layout
20487
20488 \begin_layout Enumerate
20489
20490 \size small
20491 You should remove spaces in front of 
20492 \begin_inset Quotes eld
20493 \end_inset
20494
20495
20496 \family typewriter
20497 %s
20498 \family default
20499
20500 \begin_inset Quotes erd
20501 \end_inset
20502
20503
20504 \end_layout
20505
20506 \begin_layout Enumerate
20507
20508 \size small
20509 \begin_inset Quotes eld
20510 \end_inset
20511
20512
20513 \family typewriter
20514 %s
20515 \family default
20516
20517 \begin_inset Quotes erd
20518 \end_inset
20519
20520  is normally not followed by 
20521 \begin_inset Quotes eld
20522 \end_inset
20523
20524
20525 \family typewriter
20526 %c
20527 \family default
20528
20529 \begin_inset Quotes erd
20530 \end_inset
20531
20532 .
20533 \end_layout
20534
20535 \begin_layout Standard
20536 In later versions of \SpecialChar LyX
20537 , we hope to provide a more complete interface to this
20538  tool (and it's smaller cousin 
20539 \family typewriter
20540 lacheck
20541 \family default
20542 ) to exploit the full power of it.
20543  But it's not exactly useless as it is now: go try it on one of your existing
20544  documents of a certain length and be surprised.
20545 \end_layout
20546
20547 \begin_layout Section
20548 Version Control in \SpecialChar LyX
20549
20550 \end_layout
20551
20552 \begin_layout Standard
20553 by
20554 \noun on
20555  Lars Gullik Bjønnes 
20556 \noun default
20557 and 
20558 \noun on
20559 Pavel Sanda
20560 \end_layout
20561
20562 \begin_layout Subsection
20563 Introduction
20564 \end_layout
20565
20566 \begin_layout Standard
20567 \SpecialChar LyX
20568  supports some of the most basic RCS/CVS/SVN/GIT commands.
20569  If you need something a bit more sophisticated you will have to do that
20570  manually in a terminal.
20571 \end_layout
20572
20573 \begin_layout Standard
20574 Also note that CVS support is not as good as subversion support so we advise
20575  using SVN instead.
20576  A good place to start learning Subversion is SVN Book
20577 \begin_inset Foot
20578 status collapsed
20579
20580 \begin_layout Plain Layout
20581 \begin_inset CommandInset href
20582 LatexCommand href
20583 target "http://svnbook.red-bean.com/"
20584 literal "false"
20585
20586 \end_inset
20587
20588
20589 \end_layout
20590
20591 \end_inset
20592
20593 .
20594  In the case of RCS you should read 
20595 \begin_inset Quotes eld
20596 \end_inset
20597
20598 rcsintro
20599 \begin_inset Quotes erd
20600 \end_inset
20601
20602  (a man file, read it with 
20603 \family typewriter
20604 man rcsintro
20605 \family default
20606 ).
20607  This file describes all the basic features of RCS.
20608  You should especially notice the comment about a RCS directory, and the
20609  notion of a master RCS file (the file ending in 
20610 \family typewriter
20611 ,v
20612 \family default
20613 ).
20614 \end_layout
20615
20616 \begin_layout Standard
20617 Before you begin to use the version control features in \SpecialChar LyX
20618 , you should be
20619  familiar with RCS/CVS/SVN/GIT usage.
20620  The implementation in \SpecialChar LyX
20621  assumes a recent version of the GNU RCS or CVS/SVN
20622  package — no guarantees are made for older versions.
20623  Most of the log messages are not currently displayed after operations —
20624  you can check them in the Messages pane if unsure.
20625  Regular users of version control will appreciate VC toolbar, which can
20626  be enabled via 
20627 \family sans
20628 View\SpecialChar menuseparator
20629 Toolbars\SpecialChar menuseparator
20630 Version
20631 \begin_inset space ~
20632 \end_inset
20633
20634 Control
20635 \family default
20636 .
20637 \end_layout
20638
20639 \begin_layout Standard
20640 For introducing your own external commands consult vc-command in the manual
20641  of \SpecialChar LyX
20642  functions.
20643 \end_layout
20644
20645 \begin_layout Standard
20646 It is strongly recommended to store documents in uncompressed format if
20647  using version control (uncheck 
20648 \family sans
20649 Document\SpecialChar menuseparator
20650 Compressed
20651 \family default
20652  if it is checked): Uncompressed LyX documents are text files and therefore
20653  for merging two different versions by version control systems.
20654  Compressed LyX documents are binary files, which cannot be merged by version
20655  control systems.
20656 \end_layout
20657
20658 \begin_layout Subsection
20659 RCS commands in \SpecialChar LyX
20660
20661 \end_layout
20662
20663 \begin_layout Standard
20664 The following sections describe the RCS commands supported by \SpecialChar LyX
20665 .
20666  You can find them in the 
20667 \family sans
20668 File\SpecialChar menuseparator
20669 Version
20670 \begin_inset space ~
20671 \end_inset
20672
20673 Control
20674 \family default
20675  submenu.
20676  \SpecialChar LyX
20677  was tested against RCS 5.7/5.8.
20678 \end_layout
20679
20680 \begin_layout Subsubsection
20681
20682 \family sans
20683 Register
20684 \end_layout
20685
20686 \begin_layout Standard
20687 If your document is not under revision control, this is the only item shown
20688  in the menu.
20689  And if it is under revision control, the 
20690 \family sans
20691 Register
20692 \family default
20693  item is not visible.
20694  
20695 \end_layout
20696
20697 \begin_layout Standard
20698 This command registers your document with RCS (unless you are under the
20699  directory managed by CVS)\SpecialChar endofsentence
20700  You are asked interactively to supply an initial
20701  description of the document.
20702  The document is now set in Read-Only mode and you have to 
20703 \family sans
20704 Check
20705 \begin_inset space ~
20706 \end_inset
20707
20708 Out
20709 \begin_inset space ~
20710 \end_inset
20711
20712 For
20713 \begin_inset space ~
20714 \end_inset
20715
20716 Edit
20717 \family default
20718 , before making any changes to it.
20719  A document under revision control has a 
20720 \begin_inset Quotes eld
20721 \end_inset
20722
20723 [RCS:<version> <locker>]
20724 \begin_inset Quotes erd
20725 \end_inset
20726
20727  item tagged to the filename in the minibuffer.
20728 \end_layout
20729
20730 \begin_layout Standard
20731 RCS command that is run: 
20732 \family typewriter
20733 ci -q -u -i -t-"<initial description>" <file-name>
20734 \end_layout
20735
20736 \begin_layout Standard
20737 Read 
20738 \family typewriter
20739 man ci
20740 \family default
20741  to understand the switches.
20742  
20743 \end_layout
20744
20745 \begin_layout Subsubsection
20746
20747 \family sans
20748 Check In Changes
20749 \end_layout
20750
20751 \begin_layout Standard
20752 When you are finished editing a file, you check in your changes.
20753  When you do this, you are asked for a description of the changes.
20754  This is stored in the history log.
20755  The version number is bumped, your changes are applied to the master RCS
20756  file, the document is unlocked and set to Read-Only mode.
20757 \end_layout
20758
20759 \begin_layout Standard
20760 RCS command: 
20761 \family typewriter
20762 ci -q -u -m"<description>" <file-name>
20763 \end_layout
20764
20765 \begin_layout Subsubsection
20766
20767 \family sans
20768 Check Out For Edit
20769 \end_layout
20770
20771 \begin_layout Standard
20772 By doing this you lock the document so that only you can edit it.
20773  This will also make the document Read-Write only for you.
20774  You will usually continue editing for a while and when you are finished
20775  you check in your changes.
20776  The status line is changed to reflect that you have locked the file.
20777 \end_layout
20778
20779 \begin_layout Standard
20780 RCS command: 
20781 \family typewriter
20782 co -q -l <file-name>
20783 \end_layout
20784
20785 \begin_layout Subsubsection
20786
20787 \family sans
20788 Revert To Repository Version
20789 \end_layout
20790
20791 \begin_layout Standard
20792 This will discard all changes made to the document since the last check
20793  in.
20794  You get a warning before changes are discarded.
20795 \end_layout
20796
20797 \begin_layout Standard
20798 RCS command: 
20799 \family typewriter
20800 co -f -u<version> <file-name>
20801 \end_layout
20802
20803 \begin_layout Subsubsection
20804
20805 \family sans
20806 Copy
20807 \end_layout
20808
20809 \begin_layout Standard
20810 This will create a copy of the current document.
20811  Since RCS does not support copy operations natively, the version history
20812  is not preserved, and the copy is added as a new file.
20813  It requires a clean document without any changes since the last checkin.
20814  You are asked for a file name and a description of the copy operation.
20815  After that the copy is created, both locally and in the repository.
20816  If the parent directories of the copied and original document differ, all
20817  relative paths of included files of the copy are adjusted (like in 
20818 \family sans
20819 File\SpecialChar menuseparator
20820 Save As
20821 \family default
20822 \SpecialChar ldots
20823 ).
20824  Finally, the copy is loaded instead of the original document.
20825 \end_layout
20826
20827 \begin_layout Labeling
20828 \labelwidthstring 00.00.0000
20829 RCS
20830 \begin_inset space ~
20831 \end_inset
20832
20833 commands: 
20834 \begin_inset space ~
20835 \end_inset
20836
20837
20838 \begin_inset Newline newline
20839 \end_inset
20840
20841 Copy 
20842 \begin_inset Flex Code
20843 status collapsed
20844
20845 \begin_layout Plain Layout
20846
20847 \family typewriter
20848 \begin_inset Quotes eld
20849 \end_inset
20850
20851 <file-name>
20852 \begin_inset Quotes erd
20853 \end_inset
20854
20855
20856 \end_layout
20857
20858 \end_inset
20859
20860  to 
20861 \begin_inset Flex Code
20862 status collapsed
20863
20864 \begin_layout Plain Layout
20865
20866 \family typewriter
20867 \begin_inset Quotes eld
20868 \end_inset
20869
20870 <new-file-name>
20871 \begin_inset Quotes erd
20872 \end_inset
20873
20874
20875 \end_layout
20876
20877 \end_inset
20878
20879
20880 \begin_inset Newline newline
20881 \end_inset
20882
20883
20884 \begin_inset Flex Code
20885 status collapsed
20886
20887 \begin_layout Plain Layout
20888 ci -q -u 
20889 \family typewriter
20890 -i 
20891 \begin_inset Quotes eld
20892 \end_inset
20893
20894 <new-file-name>
20895 \begin_inset Quotes erd
20896 \end_inset
20897
20898
20899 \end_layout
20900
20901 \end_inset
20902
20903
20904 \end_layout
20905
20906 \begin_layout Subsubsection
20907
20908 \family sans
20909 Undo Last Checkin
20910 \end_layout
20911
20912 \begin_layout Standard
20913 This makes as if the last check in never happened.
20914  No changes are made to the document loaded into \SpecialChar LyX
20915 , but the last version
20916  is removed from the master RCS file.
20917 \end_layout
20918
20919 \begin_layout Standard
20920 RCS command: 
20921 \family typewriter
20922 rcs -o<version> <file-name>
20923 \end_layout
20924
20925 \begin_layout Subsubsection
20926
20927 \family sans
20928 Show History
20929 \end_layout
20930
20931 \begin_layout Standard
20932 This shows the complete history of the RCS document.
20933  The output of 
20934 \family typewriter
20935 rlog <file-name>
20936 \family default
20937  is shown in a browser.
20938  See 
20939 \family typewriter
20940 man rlog
20941 \family default
20942  for more info.
20943 \end_layout
20944
20945 \begin_layout Subsubsection
20946 Revision info
20947 \end_layout
20948
20949 \begin_layout Standard
20950 \SpecialChar LyX
20951  supports RCS version number, author name, date and time of last commit.
20952  All those are extracted from 
20953 \family typewriter
20954 rlog -r <file-name>
20955 \family default
20956 .
20957  See 
20958 \begin_inset CommandInset ref
20959 LatexCommand ref
20960 reference "subsec:VCS-Revision-Information"
20961
20962 \end_inset
20963
20964  for details.
20965 \end_layout
20966
20967 \begin_layout Subsection
20968 CVS commands in \SpecialChar LyX
20969
20970 \end_layout
20971
20972 \begin_layout Standard
20973 A subset of CVS operations is supported by \SpecialChar LyX
20974 .
20975  You can find the commands in the 
20976 \family sans
20977 File\SpecialChar menuseparator
20978 Version
20979 \begin_inset space ~
20980 \end_inset
20981
20982 Control
20983 \family default
20984  submenu.
20985  The version control system SVN is more powerful, so please use it instead
20986  of CVS if possible.
20987 \end_layout
20988
20989 \begin_layout Subsubsection
20990
20991 \family sans
20992 General CVS usage
20993 \end_layout
20994
20995 \begin_layout Standard
20996 If you start from scratch with CVS you have to create your repository and
20997  checkout the working copy with external tools.
20998  If you're using a client-server setup you may need to login before doing
20999  the first repository checkout.
21000 \end_layout
21001
21002 \begin_layout Standard
21003 If your documents are under revision control and others are using the same
21004  repository problems arise when different changes to the same document at
21005  the same location happen.
21006  Standard CVS repositories don't operate with a file locking mechanism.
21007  This may be surprising, but conflicts only occur if people disagree on
21008  the proper content of the same part of a document.
21009  So, if co-workers are used to communicate regularly, these conflicts occur
21010  rarely.
21011  If they don't communicate they have a fundamental problem anyway.
21012  Nevertheless some people like to work with so called 
21013 \begin_inset Quotes eld
21014 \end_inset
21015
21016 reserved checkouts
21017 \begin_inset Quotes erd
21018 \end_inset
21019
21020 .
21021  If they do so the working copy of all files is readonly when checked out
21022  first and the user starts editing after using a special command to make
21023  the working copy writable.
21024  When the changes are checked in the working copy returns to readonly state.
21025  With \SpecialChar LyX
21026  one has to edit the 
21027 \begin_inset Flex Code
21028 status collapsed
21029
21030 \begin_layout Plain Layout
21031 .cvsrc
21032 \end_layout
21033
21034 \end_inset
21035
21036  file and add the line 
21037 \begin_inset Flex Code
21038 status collapsed
21039
21040 \begin_layout Plain Layout
21041 cvs -r
21042 \end_layout
21043
21044 \end_inset
21045
21046  to work with reserved checkouts.
21047  The benefit is the possibility to see who is using a writable copy of some
21048  document.
21049  It's not guaranteed only one user makes a copy writable.
21050 \end_layout
21051
21052 \begin_layout Standard
21053 \SpecialChar LyX
21054  tries to guess if you're using reserved or non-reserved checkouts.
21055  If your working copy is readonly or it is writable and an additional copy
21056  of your document exists in the CVS/Base sub-directory a reserved otherwise
21057  a non-reserved checkout is assumed.
21058  When a reserved checkout is detected you have to use 
21059 \begin_inset Flex Noun
21060 status collapsed
21061
21062 \begin_layout Plain Layout
21063 Check Out
21064 \end_layout
21065
21066 \end_inset
21067
21068  to make your working copy writable if it's readonly.
21069  After doing so the 
21070 \begin_inset Flex Noun
21071 status collapsed
21072
21073 \begin_layout Plain Layout
21074 Check In
21075 \end_layout
21076
21077 \end_inset
21078
21079  operation is possible and that makes your working copy readonly again after
21080  transferring your changes to the repository.
21081 \end_layout
21082
21083 \begin_layout Standard
21084 More information about CVS can be found here 
21085 \begin_inset Flex URL
21086 status collapsed
21087
21088 \begin_layout Plain Layout
21089
21090 http://www.nongnu.org/cvs
21091 \end_layout
21092
21093 \end_inset
21094
21095  and here 
21096 \begin_inset Flex URL
21097 status collapsed
21098
21099 \begin_layout Plain Layout
21100
21101 http://ximbiot.com/cvs
21102 \end_layout
21103
21104 \end_inset
21105
21106 .
21107 \end_layout
21108
21109 \begin_layout Standard
21110 Read 
21111 \family typewriter
21112 man cvs
21113 \family default
21114  to understand the sub-commands and the switches mentioned below.
21115 \end_layout
21116
21117 \begin_layout Subsubsection
21118
21119 \family sans
21120 Register
21121 \end_layout
21122
21123 \begin_layout Standard
21124 If your document is not under revision control, this is the only item shown
21125  in the menu.
21126  And if it is under revision control, the 
21127 \family sans
21128 Register
21129 \family default
21130  item is not visible.
21131  
21132 \end_layout
21133
21134 \begin_layout Standard
21135 This command registers in CVS your document 
21136 \begin_inset Flex Strong
21137 status collapsed
21138
21139 \begin_layout Plain Layout
21140
21141 \emph on
21142 only
21143 \end_layout
21144
21145 \end_inset
21146
21147  in the case you have already the documents directory under CVS control
21148  (in particular 
21149 \family typewriter
21150 CVS/Entries
21151 \family default
21152  file exists).
21153  This means you have to create or checkout the archive by yourself using
21154  external tools.
21155  (In case you forget that step \SpecialChar LyX
21156  registers the document with RCS.)
21157 \end_layout
21158
21159 \begin_layout Standard
21160 Then you are asked interactively to supply an initial description of the
21161  document.
21162  Don't forget that registered file is not yet checked in.
21163 \end_layout
21164
21165 \begin_layout Standard
21166 CVS command that is run: 
21167 \family typewriter
21168 cvs -q add -m"<entered message>" "<file-name>"
21169 \end_layout
21170
21171 \begin_layout Standard
21172 The term 
21173 \family typewriter
21174 "<file-name>"
21175 \family default
21176  above and for all other CVS commands is an abbreviation for 
21177 \begin_inset Quotes eld
21178 \end_inset
21179
21180 change the current working directory to file location and use the file name
21181  without path component as argument
21182 \begin_inset Quotes erd
21183 \end_inset
21184
21185 .
21186 \end_layout
21187
21188 \begin_layout Subsubsection
21189
21190 \family sans
21191 Check In Changes
21192 \end_layout
21193
21194 \begin_layout Standard
21195 When you are finished editing a file, you commit your changes.
21196  When you do this and you had changed the document, you are asked for a
21197  description of the changes.
21198  After that changes are written to the repository.
21199  In case you didn't change the document and a reserved checkout is detected
21200  the reservation made on 
21201 \begin_inset Flex Noun
21202 status collapsed
21203
21204 \begin_layout Plain Layout
21205 Check Out
21206 \end_layout
21207
21208 \end_inset
21209
21210  is undone.
21211 \end_layout
21212
21213 \begin_layout Labeling
21214 \labelwidthstring 00.00.0000
21215 CVS
21216 \begin_inset space ~
21217 \end_inset
21218
21219 command: 
21220 \begin_inset space ~
21221 \end_inset
21222
21223
21224 \begin_inset Newline newline
21225 \end_inset
21226
21227
21228 \begin_inset Flex Code
21229 status collapsed
21230
21231 \begin_layout Plain Layout
21232 cvs 
21233 \family typewriter
21234 -q commit -m"<description>" "<file-name>"
21235 \end_layout
21236
21237 \end_inset
21238
21239  or
21240 \begin_inset Newline newline
21241 \end_inset
21242
21243
21244 \begin_inset Flex Code
21245 status collapsed
21246
21247 \begin_layout Plain Layout
21248 cvs -q unedit 
21249 \family typewriter
21250 "<file-name>"
21251 \end_layout
21252
21253 \end_inset
21254
21255
21256 \end_layout
21257
21258 \begin_layout Subsubsection
21259
21260 \family sans
21261 Check Out Changes
21262 \end_layout
21263
21264 \begin_layout Standard
21265 When you are sharing a repository with others, you may have to incorporate
21266  their changes into your working copy.
21267 \end_layout
21268
21269 \begin_layout Standard
21270 CVS command: 
21271 \family typewriter
21272 cvs -q update "<file-name>"
21273 \end_layout
21274
21275 \begin_layout Standard
21276 If a readonly checkout is detected the working copy is made writable and
21277  reserved.
21278 \end_layout
21279
21280 \begin_layout Standard
21281 CVS command: 
21282 \family typewriter
21283 cvs -q edit "<file-name>"
21284 \end_layout
21285
21286 \begin_layout Subsubsection
21287
21288 \family sans
21289 Revert To Repository Version
21290 \end_layout
21291
21292 \begin_layout Standard
21293 This will discard all changes made to the document since the last check
21294  in.
21295  You get a warning before changes are discarded.
21296  Firstly the file is deleted, secondly CVS update command is run.
21297 \end_layout
21298
21299 \begin_layout Standard
21300 CVS command: 
21301 \family typewriter
21302 cvs -q update "<file-name>"
21303 \end_layout
21304
21305 \begin_layout Standard
21306 If a reserved checkout is detected and the working copy has no changes only
21307  the reservation is undone.
21308 \end_layout
21309
21310 \begin_layout Standard
21311 CVS command: 
21312 \family typewriter
21313 cvs -q unedit "<file-name>"
21314 \end_layout
21315
21316 \begin_layout Subsubsection
21317
21318 \family sans
21319 Copy
21320 \end_layout
21321
21322 \begin_layout Standard
21323 This will create a copy of the current document.
21324  Since CVS does not support copy operations natively, the version history
21325  is not preserved, and the copy is added as a new file.
21326  It requires a clean document without any changes since the last checkin.
21327  You are asked for a file name and a description of the copy operation.
21328  After that the copy is created, both locally and in the repository.
21329  If the parent directories of the copied and original document differ, all
21330  relative paths of included files of the copy are adjusted (like in 
21331 \family sans
21332 File\SpecialChar menuseparator
21333 Save As
21334 \family default
21335 \SpecialChar ldots
21336 ).
21337  Finally, the copy is loaded instead of the original document.
21338 \end_layout
21339
21340 \begin_layout Labeling
21341 \labelwidthstring 00.00.0000
21342 CVS
21343 \begin_inset space ~
21344 \end_inset
21345
21346 commands: 
21347 \begin_inset space ~
21348 \end_inset
21349
21350
21351 \begin_inset Newline newline
21352 \end_inset
21353
21354 Copy 
21355 \begin_inset Flex Code
21356 status collapsed
21357
21358 \begin_layout Plain Layout
21359
21360 \family typewriter
21361 \begin_inset Quotes eld
21362 \end_inset
21363
21364 <file-name>
21365 \begin_inset Quotes erd
21366 \end_inset
21367
21368
21369 \end_layout
21370
21371 \end_inset
21372
21373  to 
21374 \begin_inset Flex Code
21375 status collapsed
21376
21377 \begin_layout Plain Layout
21378
21379 \family typewriter
21380 \begin_inset Quotes eld
21381 \end_inset
21382
21383 <new-file-name>
21384 \begin_inset Quotes erd
21385 \end_inset
21386
21387
21388 \end_layout
21389
21390 \end_inset
21391
21392
21393 \begin_inset Newline newline
21394 \end_inset
21395
21396
21397 \begin_inset Flex Code
21398 status collapsed
21399
21400 \begin_layout Plain Layout
21401 cvs -q add 
21402 \family typewriter
21403
21404 \begin_inset Quotes eld
21405 \end_inset
21406
21407 <new-file-name>
21408 \begin_inset Quotes erd
21409 \end_inset
21410
21411
21412 \end_layout
21413
21414 \end_inset
21415
21416
21417 \end_layout
21418
21419 \begin_layout Subsubsection
21420
21421 \family sans
21422 Rename
21423 \end_layout
21424
21425 \begin_layout Standard
21426 This will rename the current document.
21427  Since CVS does not support rename operations natively, the version history
21428  is not preserved, the renamed document is added as a new file, and the
21429  original document is deleted.
21430  It requires a clean document without any changes since the last checkin.
21431  You are asked for a file name and a description of the rename operation.
21432  After that the document is renamed, both locally and in the repository.
21433  If the parent directories of the new and old file names differ, all relative
21434  paths of included files are adjusted (like in 
21435 \family sans
21436 File\SpecialChar menuseparator
21437 Save As
21438 \family default
21439 \SpecialChar ldots
21440 ).
21441  Finally, the document is reloaded using the new name.
21442 \end_layout
21443
21444 \begin_layout Labeling
21445 \labelwidthstring 00.00.0000
21446 CVS
21447 \begin_inset space ~
21448 \end_inset
21449
21450 commands: 
21451 \begin_inset space ~
21452 \end_inset
21453
21454
21455 \begin_inset Newline newline
21456 \end_inset
21457
21458 Rename 
21459 \begin_inset Flex Code
21460 status collapsed
21461
21462 \begin_layout Plain Layout
21463
21464 \family typewriter
21465 \begin_inset Quotes eld
21466 \end_inset
21467
21468 <file-name>
21469 \begin_inset Quotes erd
21470 \end_inset
21471
21472
21473 \end_layout
21474
21475 \end_inset
21476
21477  to 
21478 \begin_inset Flex Code
21479 status collapsed
21480
21481 \begin_layout Plain Layout
21482
21483 \family typewriter
21484 \begin_inset Quotes eld
21485 \end_inset
21486
21487 <new-file-name>
21488 \begin_inset Quotes erd
21489 \end_inset
21490
21491
21492 \end_layout
21493
21494 \end_inset
21495
21496
21497 \begin_inset Newline newline
21498 \end_inset
21499
21500
21501 \begin_inset Flex Code
21502 status collapsed
21503
21504 \begin_layout Plain Layout
21505 cvs -q add 
21506 \family typewriter
21507
21508 \begin_inset Quotes eld
21509 \end_inset
21510
21511 <new-file-name>
21512 \begin_inset Quotes erd
21513 \end_inset
21514
21515
21516 \end_layout
21517
21518 \end_inset
21519
21520
21521 \begin_inset Newline newline
21522 \end_inset
21523
21524
21525 \begin_inset Flex Code
21526 status collapsed
21527
21528 \begin_layout Plain Layout
21529 cvs -q remove 
21530 \family typewriter
21531
21532 \begin_inset Quotes eld
21533 \end_inset
21534
21535 <file-name>
21536 \begin_inset Quotes erd
21537 \end_inset
21538
21539
21540 \end_layout
21541
21542 \end_inset
21543
21544
21545 \end_layout
21546
21547 \begin_layout Subsubsection
21548 Update of the local directory checkout from repository
21549 \end_layout
21550
21551 \begin_layout Standard
21552 Once your documents gets more complex, containing sub-documents and pictures,
21553  including external 
21554 \begin_inset Flex Code
21555 status collapsed
21556
21557 \begin_layout Plain Layout
21558 .tex
21559 \end_layout
21560
21561 \end_inset
21562
21563  files and so on using version control becomes more complicated.
21564  \SpecialChar LyX
21565  supports updating the whole tree in which resides the document.
21566  This become especially useful once you cooperate with people which neither
21567  have detailed knowledge about CVS usage nor they have ambition to commit
21568  additional material to the repository.
21569  You have to organize the files structure so that all external files are
21570  in the same directory or subdirectories of the document.
21571  It's good practice anyway to store multipart documents in an extra directory.
21572 \end_layout
21573
21574 \begin_layout Standard
21575 The 
21576 \begin_inset Flex Code
21577 status collapsed
21578
21579 \begin_layout Plain Layout
21580 Update local directory from repository
21581 \end_layout
21582
21583 \end_inset
21584
21585  command updates the whole directory.
21586  If local changes are detected user is warned before update starts.
21587  In case of merge conflicts both versions of the conflicting document parts
21588  are placed in the final document.
21589  You have to review and correct the result of the merge.
21590  You'll find the conflicts enclosed in pairs of 
21591 \begin_inset Flex Code
21592 status collapsed
21593
21594 \begin_layout Plain Layout
21595 <<<<<<<
21596 \end_layout
21597
21598 \end_inset
21599
21600  and 
21601 \begin_inset Flex Code
21602 status collapsed
21603
21604 \begin_layout Plain Layout
21605 >>>>>>>
21606 \end_layout
21607
21608 \end_inset
21609
21610  separated by 
21611 \begin_inset Flex Code
21612 status collapsed
21613
21614 \begin_layout Plain Layout
21615 =======
21616 \end_layout
21617
21618 \end_inset
21619
21620 .
21621  The first part is your version as before the update operation with the
21622  document name prepended.
21623  The second one is the repository version with the version number after
21624  the sequence of 
21625 \begin_inset Flex Code
21626 status collapsed
21627
21628 \begin_layout Plain Layout
21629 >
21630 \end_layout
21631
21632 \end_inset
21633
21634  signs.
21635 \end_layout
21636
21637 \begin_layout Labeling
21638 \labelwidthstring 00.00.0000
21639 CVS
21640 \begin_inset space ~
21641 \end_inset
21642
21643 commands: 
21644 \begin_inset space ~
21645 \end_inset
21646
21647
21648 \begin_inset Newline newline
21649 \end_inset
21650
21651
21652 \begin_inset Flex Code
21653 status collapsed
21654
21655 \begin_layout Plain Layout
21656 cd $path; cvs diff 
21657 \family typewriter
21658 "."
21659 \end_layout
21660
21661 \end_inset
21662
21663  (Ask if changes are detected.)
21664 \begin_inset Newline newline
21665 \end_inset
21666
21667
21668 \begin_inset Flex Code
21669 status collapsed
21670
21671 \begin_layout Plain Layout
21672 cd $path; cvs -q update 
21673 \family typewriter
21674 "."
21675 \end_layout
21676
21677 \end_inset
21678
21679
21680 \end_layout
21681
21682 \begin_layout Standard
21683 where 
21684 \begin_inset Flex Code
21685 status collapsed
21686
21687 \begin_layout Plain Layout
21688 $path
21689 \end_layout
21690
21691 \end_inset
21692
21693  stands for the path to the document.
21694 \end_layout
21695
21696 \begin_layout Subsubsection
21697
21698 \family sans
21699 Show History
21700 \end_layout
21701
21702 \begin_layout Standard
21703 This shows the complete history of the CVS document.
21704  The output of 
21705 \family typewriter
21706 cvs log "<file-name>"
21707 \family default
21708  is shown in a browser.
21709 \end_layout
21710
21711 \begin_layout Subsubsection
21712 Revision info
21713 \end_layout
21714
21715 \begin_layout Standard
21716 \SpecialChar LyX
21717  supports CVS version number, author name, date and time of last commit.
21718  All those are extracted from 
21719 \family typewriter
21720 cvs log -r <file-name>
21721 \family default
21722 .
21723  See 
21724 \begin_inset CommandInset ref
21725 LatexCommand ref
21726 reference "subsec:VCS-Revision-Information"
21727
21728 \end_inset
21729
21730  for details.
21731 \end_layout
21732
21733 \begin_layout Subsection
21734 SVN commands in \SpecialChar LyX
21735
21736 \end_layout
21737
21738 \begin_layout Standard
21739 SVN is now partially supported by \SpecialChar LyX
21740 .
21741  You can find the commands in the 
21742 \family sans
21743 File\SpecialChar menuseparator
21744 Version
21745 \begin_inset space ~
21746 \end_inset
21747
21748 Control
21749 \family default
21750  submenu.
21751  Please note that if you use password protected access to repository via
21752  ssh, you will be asked in terminal window.
21753  \SpecialChar LyX
21754  was tested against SVN 1.5, 1.6, 1.7 and 1.8
21755 \begin_inset Foot
21756 status open
21757
21758 \begin_layout Plain Layout
21759 Most of the commands will work with 1.4 too, see 
21760 \begin_inset CommandInset ref
21761 LatexCommand ref
21762 reference "subsec:SVN-Repo-Update"
21763
21764 \end_inset
21765
21766 .
21767  There seems to be currently unresolved permissions problem under SVN 1.8
21768  with reverting changes when file is locked.
21769 \end_layout
21770
21771 \end_inset
21772
21773
21774 \end_layout
21775
21776 \begin_layout Subsubsection
21777
21778 \family sans
21779 Register
21780 \end_layout
21781
21782 \begin_layout Standard
21783 If your document is not under revision control, this is the only item shown
21784  in the menu.
21785  And if it is under revision control, the 
21786 \family sans
21787 Register
21788 \family default
21789  item is not visible.
21790 \end_layout
21791
21792 \begin_layout Standard
21793 This command registers in SVN your document ONLY in case you have already
21794  the documents directory under SVN control (in particular 
21795 \family typewriter
21796 .svn/entries
21797 \family default
21798  file exists).
21799  This means you have to checkout the archive by yourself.
21800 \end_layout
21801
21802 \begin_layout Standard
21803 Then you are asked interactively to supply an initial description of the
21804  document.
21805  Don't forget that registered file is not yet commited.
21806 \end_layout
21807
21808 \begin_layout Standard
21809 SVN command that is run: 
21810 \family typewriter
21811 svn add -q 
21812 \begin_inset Quotes eld
21813 \end_inset
21814
21815 <file-name>
21816 \begin_inset Quotes erd
21817 \end_inset
21818
21819
21820 \end_layout
21821
21822 \begin_layout Standard
21823 Read 
21824 \family typewriter
21825 man svn
21826 \family default
21827  to understand the switches.
21828 \end_layout
21829
21830 \begin_layout Subsubsection
21831
21832 \family sans
21833 Check In Changes
21834 \end_layout
21835
21836 \begin_layout Standard
21837 When you are finished editing a file, you commit your changes.
21838  When you do this, you are asked for a description of the changes.
21839  After that changes are commited.
21840 \end_layout
21841
21842 \begin_layout Standard
21843 SVN command:
21844 \begin_inset Foot
21845 status collapsed
21846
21847 \begin_layout Plain Layout
21848 In case locking is not enabled.
21849  See Section 
21850 \begin_inset CommandInset ref
21851 LatexCommand ref
21852 reference "subsec:SVN-File-Locking"
21853
21854 \end_inset
21855
21856 .
21857 \end_layout
21858
21859 \end_inset
21860
21861  
21862 \family typewriter
21863 svn commit -q -m"<description>" <file-name>
21864 \end_layout
21865
21866 \begin_layout Subsubsection
21867
21868 \family sans
21869 Check Out For Edit
21870 \end_layout
21871
21872 \begin_layout Standard
21873 Updates the changes of this file from the repository.
21874  Be sure you understand SVN merging and conflicts resolving before using
21875  this function, because all conflicts has to be resolved manually by you!
21876 \end_layout
21877
21878 \begin_layout Standard
21879 SVN command:
21880 \begin_inset Foot
21881 status collapsed
21882
21883 \begin_layout Plain Layout
21884 Ditto.
21885 \end_layout
21886
21887 \end_inset
21888
21889  
21890 \family typewriter
21891 svn update --non-interactive 
21892 \begin_inset Quotes eld
21893 \end_inset
21894
21895 <file-name>
21896 \begin_inset Quotes erd
21897 \end_inset
21898
21899
21900 \end_layout
21901
21902 \begin_layout Subsubsection
21903
21904 \family sans
21905 Revert To Repository Version
21906 \end_layout
21907
21908 \begin_layout Standard
21909 This will discard all changes made to the document since the last check
21910  in.
21911  You get a warning before changes are discarded.
21912 \end_layout
21913
21914 \begin_layout Standard
21915 SVN command: 
21916 \family typewriter
21917 svn revert -q 
21918 \begin_inset Quotes eld
21919 \end_inset
21920
21921 <file-name>
21922 \begin_inset Quotes erd
21923 \end_inset
21924
21925
21926 \end_layout
21927
21928 \begin_layout Subsubsection
21929
21930 \family sans
21931 Copy
21932 \end_layout
21933
21934 \begin_layout Standard
21935 This will create a copy of the current document including the version history.
21936  It requires a clean document without any changes since the last checkin.
21937  You are asked for a file name and a description of the copy operation.
21938  After that the copy is created, both locally and in the repository.
21939  If the parent directories of the copied and original document differ, all
21940  relative paths of included files of the copy are adjusted (like in 
21941 \family sans
21942 File\SpecialChar menuseparator
21943 Save As
21944 \family default
21945 \SpecialChar ldots
21946 ).
21947  Finally, the copy is loaded instead of the original document.
21948 \end_layout
21949
21950 \begin_layout Labeling
21951 \labelwidthstring 00.00.0000
21952 SVN
21953 \begin_inset space ~
21954 \end_inset
21955
21956 commands: 
21957 \begin_inset space ~
21958 \end_inset
21959
21960
21961 \begin_inset Newline newline
21962 \end_inset
21963
21964
21965 \begin_inset Flex Code
21966 status collapsed
21967
21968 \begin_layout Plain Layout
21969 svn copy -q 
21970 \family typewriter
21971
21972 \begin_inset Quotes eld
21973 \end_inset
21974
21975 <file-name>
21976 \begin_inset Quotes erd
21977 \end_inset
21978
21979  
21980 \begin_inset Quotes eld
21981 \end_inset
21982
21983 <new-file-name>
21984 \begin_inset Quotes erd
21985 \end_inset
21986
21987
21988 \end_layout
21989
21990 \end_inset
21991
21992
21993 \begin_inset Newline newline
21994 \end_inset
21995
21996
21997 \begin_inset Flex Code
21998 status collapsed
21999
22000 \begin_layout Plain Layout
22001 svn commit
22002 \end_layout
22003
22004 \end_inset
22005
22006
22007 \end_layout
22008
22009 \begin_layout Subsubsection
22010
22011 \family sans
22012 Rename
22013 \end_layout
22014
22015 \begin_layout Standard
22016 This will rename the current document including the version history.
22017  It requires a clean document without any changes since the last checkin.
22018  You are asked for a file name and a description of the rename operation.
22019  After that the document is renamed, both locally and in the repository.
22020  If the parent directories of the new and old file names differ, all relative
22021  paths of included files are adjusted (like in 
22022 \family sans
22023 File\SpecialChar menuseparator
22024 Save As
22025 \family default
22026 \SpecialChar ldots
22027 ).
22028  Finally, the document is reloaded using the new name.
22029 \end_layout
22030
22031 \begin_layout Labeling
22032 \labelwidthstring 00.00.0000
22033 SVN
22034 \begin_inset space ~
22035 \end_inset
22036
22037 commands: 
22038 \begin_inset space ~
22039 \end_inset
22040
22041
22042 \begin_inset Newline newline
22043 \end_inset
22044
22045
22046 \begin_inset Flex Code
22047 status collapsed
22048
22049 \begin_layout Plain Layout
22050 svn move -q 
22051 \family typewriter
22052
22053 \begin_inset Quotes eld
22054 \end_inset
22055
22056 <file-name>
22057 \begin_inset Quotes erd
22058 \end_inset
22059
22060  
22061 \begin_inset Quotes eld
22062 \end_inset
22063
22064 <new-file-name>
22065 \begin_inset Quotes erd
22066 \end_inset
22067
22068
22069 \end_layout
22070
22071 \end_inset
22072
22073
22074 \begin_inset Newline newline
22075 \end_inset
22076
22077
22078 \begin_inset Flex Code
22079 status collapsed
22080
22081 \begin_layout Plain Layout
22082 svn commit
22083 \end_layout
22084
22085 \end_inset
22086
22087
22088 \end_layout
22089
22090 \begin_layout Subsubsection
22091 \begin_inset CommandInset label
22092 LatexCommand label
22093 name "subsec:SVN-Repo-Update"
22094
22095 \end_inset
22096
22097 Update of the local directory checkout from repository
22098 \begin_inset Foot
22099 status collapsed
22100
22101 \begin_layout Plain Layout
22102 Note that this command will work only with subversion 
22103 \begin_inset Formula $\geqq1.5$
22104 \end_inset
22105
22106
22107 \end_layout
22108
22109 \end_inset
22110
22111
22112 \end_layout
22113
22114 \begin_layout Standard
22115 All the commands above have one shortcomming - they deal with the current
22116  document only.
22117  Once your document contains pictures, includes external 
22118 \begin_inset Flex Code
22119 status collapsed
22120
22121 \begin_layout Plain Layout
22122 .tex
22123 \end_layout
22124
22125 \end_inset
22126
22127  files and so on administration becomes more complicated.
22128  \SpecialChar LyX
22129  now supports updating the whole tree in which resides the document
22130 \begin_inset Foot
22131 status collapsed
22132
22133 \begin_layout Plain Layout
22134 One need to organize the files structure so that all external files are
22135  in the same directory or subdirectories of the document.
22136  
22137 \end_layout
22138
22139 \end_inset
22140
22141 .
22142  This become especially useful once you cooperate with people which neither
22143  know about subversion management nor they have ambition to commit additional
22144  material to the repository.
22145  
22146 \end_layout
22147
22148 \begin_layout Standard
22149 \begin_inset Flex Code
22150 status collapsed
22151
22152 \begin_layout Plain Layout
22153 Update local directory from repository
22154 \end_layout
22155
22156 \end_inset
22157
22158  command updates the whole directory and in case of merge conflicts local
22159  version of the files are left, so no unintended data loss occurs.
22160  If local changes are detected user is warned before update starts.
22161 \end_layout
22162
22163 \begin_layout Labeling
22164 \labelwidthstring 00.00.0000
22165 SVN
22166 \begin_inset space ~
22167 \end_inset
22168
22169 commands: 
22170 \begin_inset space ~
22171 \end_inset
22172
22173
22174 \begin_inset Newline newline
22175 \end_inset
22176
22177
22178 \begin_inset Flex Code
22179 status collapsed
22180
22181 \begin_layout Plain Layout
22182 svn diff $path
22183 \end_layout
22184
22185 \end_inset
22186
22187  (Ask if changes are detected.)
22188 \begin_inset Newline newline
22189 \end_inset
22190
22191
22192 \begin_inset Flex Code
22193 status collapsed
22194
22195 \begin_layout Plain Layout
22196 svn update –accept mine-full $path
22197 \end_layout
22198
22199 \end_inset
22200
22201
22202 \end_layout
22203
22204 \begin_layout Standard
22205 where 
22206 \begin_inset Flex Code
22207 status collapsed
22208
22209 \begin_layout Plain Layout
22210 $path
22211 \end_layout
22212
22213 \end_inset
22214
22215  stands for the path to the document.
22216 \end_layout
22217
22218 \begin_layout Subsubsection
22219
22220 \family sans
22221 Show History
22222 \end_layout
22223
22224 \begin_layout Standard
22225 This shows the complete history of the SVN document.
22226  The output of 
22227 \family typewriter
22228 svn log 
22229 \begin_inset Quotes eld
22230 \end_inset
22231
22232 <file-name>
22233 \begin_inset Quotes erd
22234 \end_inset
22235
22236
22237 \family default
22238  is shown in a browser.
22239 \end_layout
22240
22241 \begin_layout Subsubsection
22242 File Locking
22243 \begin_inset CommandInset label
22244 LatexCommand label
22245 name "subsec:SVN-File-Locking"
22246
22247 \end_inset
22248
22249
22250 \end_layout
22251
22252 \begin_layout Standard
22253 The file exchange through various revision control systems brings the problem
22254  of merge conflicts in case two different users try to edit the same (parts
22255  of) document.
22256  When such a conflict happens it needs manual resolving and one reasonable
22257  alternative is to provide some kind of locking mechanism, which guarantees
22258  that only one user is allowed to edit file at the given time.
22259 \end_layout
22260
22261 \begin_layout Standard
22262 SVN has two such mechanisms to provide mutual exclusivity for file access
22263  - locks and automatic setting of write permissions (see sec.
22264  
22265 \begin_inset CommandInset ref
22266 LatexCommand ref
22267 reference "subsec:Automatical-Locking-Property"
22268
22269 \end_inset
22270
22271 ) based on 
22272 \begin_inset Flex Code
22273 status collapsed
22274
22275 \begin_layout Plain Layout
22276 svn:needs-lock
22277 \end_layout
22278
22279 \end_inset
22280
22281  file svn property
22282 \begin_inset Foot
22283 status open
22284
22285 \begin_layout Plain Layout
22286 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
22287 \end_layout
22288
22289 \end_inset
22290
22291 .
22292  If this property is detected for a given document \SpecialChar LyX
22293  starts to use SVN locks
22294  for document editing automatically and the whole check-in/out mechanism
22295  switches to the same regimen as for RCS.
22296  This in particular means there are two different modes of file use in \SpecialChar LyX
22297 :
22298 \end_layout
22299
22300 \begin_layout Itemize
22301 Unlocked state.
22302  The loaded file is in the read-only mode.
22303  For editing on needs to check-out.
22304  
22305 \emph on
22306 Check-out
22307 \emph default
22308  consists of updating from the repository and gaining write lock.
22309  If the lock is not possible to obtain, we remain in unlocked state.
22310 \end_layout
22311
22312 \begin_layout Itemize
22313 Locked state.
22314  The loaded file is in the 'normal' edit mode.
22315  No other user is allowed to edit the file.
22316  
22317 \emph on
22318 Check-in
22319 \emph default
22320  consists of commiting changes and releasing write-lock.
22321  If no changes have been made to the document, no commit will be produced
22322 \begin_inset Foot
22323 status collapsed
22324
22325 \begin_layout Plain Layout
22326 Don't be puzzled by the fact that you will be asked for commit message anyway.
22327 \end_layout
22328
22329 \end_inset
22330
22331  and only the write-lock will be released.
22332 \end_layout
22333
22334 \begin_layout Standard
22335 SVN commands:
22336 \end_layout
22337
22338 \begin_layout Labeling
22339 \labelwidthstring 00.00.0000
22340 Check-in:
22341 \family typewriter
22342  svn commit -q -m"<description>" "<file-name>"
22343 \begin_inset Newline newline
22344 \end_inset
22345
22346 svn unlock "<file-name>"
22347 \end_layout
22348
22349 \begin_layout Labeling
22350 \labelwidthstring 00.00.0000
22351 Check-out: 
22352 \family typewriter
22353 svn update "<file-name>"
22354 \begin_inset Newline newline
22355 \end_inset
22356
22357 svn lock "<file-name>"
22358 \end_layout
22359
22360 \begin_layout Subsubsection
22361
22362 \family typewriter
22363 \begin_inset CommandInset label
22364 LatexCommand label
22365 name "subsec:Automatical-Locking-Property"
22366
22367 \end_inset
22368
22369
22370 \family default
22371 Automatic Locking Property
22372 \end_layout
22373
22374 \begin_layout Standard
22375 The above mentioned automatic setting of write permissions of the .lyx file
22376  can be set through
22377 \family sans
22378  File\SpecialChar menuseparator
22379 Version
22380 \begin_inset space ~
22381 \end_inset
22382
22383 Control\SpecialChar menuseparator
22384 Toggle locking property
22385 \family default
22386 .
22387  This command is active only when the file is not locked on the svn server
22388  (i.e.
22389  you need to check-out before proceeding).
22390 \end_layout
22391
22392 \begin_layout Labeling
22393 \labelwidthstring 00.00.0000
22394 SVN
22395 \begin_inset space ~
22396 \end_inset
22397
22398 commands:
22399 \end_layout
22400
22401 \begin_layout Labeling
22402 \labelwidthstring 00.00.0000
22403 Set:
22404 \family typewriter
22405  svn propset svn:needs-lock ON "<file-name>"
22406 \end_layout
22407
22408 \begin_layout Labeling
22409 \labelwidthstring 00.00.0000
22410 Unset: 
22411 \family typewriter
22412 svn propdel svn:needs-lock "<file-name>"
22413 \end_layout
22414
22415 \begin_layout Subsubsection
22416 \begin_inset CommandInset label
22417 LatexCommand label
22418 name "subsec:VCS-Revision-Information"
22419
22420 \end_inset
22421
22422 Revision Information in Documents
22423 \end_layout
22424
22425 \begin_layout Standard
22426 There are more possibilities how to activate revision information in our
22427  document.
22428 \end_layout
22429
22430 \begin_layout Itemize
22431 \SpecialChar LyX
22432  supports directly:
22433 \end_layout
22434
22435 \begin_deeper
22436 \begin_layout Itemize
22437 tree revision information (
22438 \begin_inset Flex Code
22439 status collapsed
22440
22441 \begin_layout Plain Layout
22442 vcs-tree-revision
22443 \end_layout
22444
22445 \end_inset
22446
22447 ).
22448  The result is the output of the 
22449 \begin_inset Flex Code
22450 status collapsed
22451
22452 \begin_layout Plain Layout
22453 svnversion
22454 \end_layout
22455
22456 \end_inset
22457
22458  command, the following table gives you an idea, how to read the results.
22459 \end_layout
22460
22461 \begin_layout Standard
22462 \align center
22463 \begin_inset Tabular
22464 <lyxtabular version="3" rows="6" columns="2">
22465 <features tabularvalignment="middle">
22466 <column alignment="center" valignment="top">
22467 <column alignment="center" valignment="top">
22468 <row>
22469 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
22470 \begin_inset Text
22471
22472 \begin_layout Plain Layout
22473 Output
22474 \end_layout
22475
22476 \end_inset
22477 </cell>
22478 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
22479 \begin_inset Text
22480
22481 \begin_layout Plain Layout
22482 Meaning
22483 \end_layout
22484
22485 \end_inset
22486 </cell>
22487 </row>
22488 <row>
22489 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22490 \begin_inset Text
22491
22492 \begin_layout Plain Layout
22493 4123:4168
22494 \end_layout
22495
22496 \end_inset
22497 </cell>
22498 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22499 \begin_inset Text
22500
22501 \begin_layout Plain Layout
22502 mixed revision working copy
22503 \end_layout
22504
22505 \end_inset
22506 </cell>
22507 </row>
22508 <row>
22509 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22510 \begin_inset Text
22511
22512 \begin_layout Plain Layout
22513 4168M
22514 \end_layout
22515
22516 \end_inset
22517 </cell>
22518 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22519 \begin_inset Text
22520
22521 \begin_layout Plain Layout
22522 modified working copy
22523 \end_layout
22524
22525 \end_inset
22526 </cell>
22527 </row>
22528 <row>
22529 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22530 \begin_inset Text
22531
22532 \begin_layout Plain Layout
22533 4123S
22534 \end_layout
22535
22536 \end_inset
22537 </cell>
22538 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22539 \begin_inset Text
22540
22541 \begin_layout Plain Layout
22542 switched working copy
22543 \end_layout
22544
22545 \end_inset
22546 </cell>
22547 </row>
22548 <row>
22549 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
22550 \begin_inset Text
22551
22552 \begin_layout Plain Layout
22553 4123P
22554 \end_layout
22555
22556 \end_inset
22557 </cell>
22558 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22559 \begin_inset Text
22560
22561 \begin_layout Plain Layout
22562 partial working copy, from a sparse checkout
22563 \end_layout
22564
22565 \end_inset
22566 </cell>
22567 </row>
22568 <row>
22569 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
22570 \begin_inset Text
22571
22572 \begin_layout Plain Layout
22573 4123:4168MS
22574 \end_layout
22575
22576 \end_inset
22577 </cell>
22578 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
22579 \begin_inset Text
22580
22581 \begin_layout Plain Layout
22582 mixed revision, modified, switched working copy
22583 \end_layout
22584
22585 \end_inset
22586 </cell>
22587 </row>
22588 </lyxtabular>
22589
22590 \end_inset
22591
22592
22593 \end_layout
22594
22595 \begin_layout Itemize
22596 file revision information.
22597  The result comes from parsing the output of 
22598 \begin_inset Flex Code
22599 status collapsed
22600
22601 \begin_layout Plain Layout
22602 svn
22603 \begin_inset space ~
22604 \end_inset
22605
22606 info
22607 \begin_inset space ~
22608 \end_inset
22609
22610 –xml
22611 \begin_inset space ~
22612 \end_inset
22613
22614 file.lyx
22615 \end_layout
22616
22617 \end_inset
22618
22619 .
22620  Supported flags are:
22621 \end_layout
22622
22623 \begin_deeper
22624 \begin_layout Itemize
22625 version number of the last commit (
22626 \begin_inset Flex Code
22627 status collapsed
22628
22629 \begin_layout Plain Layout
22630 vcs-revision
22631 \end_layout
22632
22633 \end_inset
22634
22635 )
22636 \end_layout
22637
22638 \begin_layout Itemize
22639 author of the last commit (
22640 \begin_inset Flex Code
22641 status collapsed
22642
22643 \begin_layout Plain Layout
22644 vcs-author
22645 \end_layout
22646
22647 \end_inset
22648
22649 )
22650 \end_layout
22651
22652 \begin_layout Itemize
22653 date of the last commit (
22654 \begin_inset Flex Code
22655 status collapsed
22656
22657 \begin_layout Plain Layout
22658 vcs-date
22659 \end_layout
22660
22661 \end_inset
22662
22663 )
22664 \end_layout
22665
22666 \begin_layout Itemize
22667 time of the last commit (
22668 \begin_inset Flex Code
22669 status collapsed
22670
22671 \begin_layout Plain Layout
22672 vcs-time
22673 \end_layout
22674
22675 \end_inset
22676
22677 )
22678 \end_layout
22679
22680 \end_deeper
22681 \begin_layout Standard
22682 You can obtain this info via InsetInfo (e.g.
22683  
22684 \begin_inset Flex Code
22685 status collapsed
22686
22687 \begin_layout Plain Layout
22688 info-insert buffer vcs-date
22689 \end_layout
22690
22691 \end_inset
22692
22693 ).
22694  The information will be available only when you have the file stored under
22695  svn managment (i.e.
22696  the 
22697 \begin_inset Flex Code
22698 status collapsed
22699
22700 \begin_layout Plain Layout
22701 .svn
22702 \end_layout
22703
22704 \end_inset
22705
22706  directory is available with your document).
22707 \end_layout
22708
22709 \end_deeper
22710 \begin_layout Itemize
22711 Another—a hacking one—possibility is to use svn keywords
22712 \begin_inset Foot
22713 status collapsed
22714
22715 \begin_layout Plain Layout
22716 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
22717 \end_layout
22718
22719 \end_inset
22720
22721 .
22722  In short – you set file keywords property (e.g.
22723  
22724 \family sans
22725 svn propset svn:keywords 'Rev' file.lyx
22726 \family default
22727 ) and then paste keyword \SpecialChar TeX
22728  code
22729 \begin_inset Foot
22730 status collapsed
22731
22732 \begin_layout Plain Layout
22733 This is an easy way how to ensure that \SpecialChar LyX
22734  won't break the line in the middle
22735  of keyword tag.
22736 \end_layout
22737
22738 \end_inset
22739
22740  tag in your document (e.g.
22741  
22742 \begin_inset ERT
22743 status open
22744
22745 \begin_layout Plain Layout
22746
22747 $Rev$
22748 \end_layout
22749
22750 \end_inset
22751
22752 ).
22753  This way svn client will automatically substitute revision number (e.g.
22754  
22755 \begin_inset ERT
22756 status open
22757
22758 \begin_layout Plain Layout
22759
22760 $Rev: 59 $
22761 \end_layout
22762
22763 \end_inset
22764
22765 ) after each update and commit.
22766  There are more problems with this approach.
22767  Firstly, the '$' character is used in \SpecialChar TeX
22768  world for math equations, so any
22769  occurence of math formula 
22770 \begin_inset Formula $Rev$
22771 \end_inset
22772
22773  become 
22774 \begin_inset Formula $Rev:59$
22775 \end_inset
22776
22777  in your \SpecialChar LyX
22778  document.
22779  Similarly for other keywords like Id, Date, Author, etc.
22780  Secondly svn output is dependent on your locales, so its very easy that
22781  svn would produce some problematic strings once Date is used.
22782  Thirdly you get the whole 'Rev: 59' string in your document instead of
22783  the plain number.
22784  Until subversion implements user's custom keywords it will be hard to use
22785  this approach reliably or let \SpecialChar LyX
22786  to support it directly.
22787 \end_layout
22788
22789 \begin_layout Subsection
22790 SVN and Windows Environment
22791 \end_layout
22792
22793 \begin_layout Quote
22794 My inclination is to say that if the user cannot figure out the command
22795  line operations on their own fairly quickly, they would be well advised
22796  to use TortoiseSVN.
22797  —P.
22798  A.
22799  Rubin
22800 \end_layout
22801
22802 \begin_layout Subsubsection
22803 Preparation
22804 \end_layout
22805
22806 \begin_layout Standard
22807 In addition to installing \SpecialChar LyX
22808 , and having access to a Subversion repository,
22809  the user will need to install the Subversion client program.
22810  A Windows installer for the client program is available from 
22811 \begin_inset CommandInset href
22812 LatexCommand href
22813 name "CollabNet"
22814 target "http://www.collab.net/nonav/downloads/subversion/"
22815 literal "false"
22816
22817 \end_inset
22818
22819 .
22820  The user may also want to install 
22821 \begin_inset CommandInset href
22822 LatexCommand href
22823 name "TortoiseSVN"
22824 target "http://tortoisesvn.tigris.org/"
22825 literal "false"
22826
22827 \end_inset
22828
22829 , which integrates Subversion operations into the context (rightclick) menu
22830  of Windows Explorer.
22831  Operations done outside \SpecialChar LyX
22832  will typically be more convenient using the Explorer
22833  context menu.
22834  Note that TortoiseSVN is not a replacement for the client program, which
22835  is what \SpecialChar LyX
22836  itself will use.
22837 \end_layout
22838
22839 \begin_layout Subsubsection
22840 Bringing a document under Subversion control
22841 \end_layout
22842
22843 \begin_layout Standard
22844 Before a \SpecialChar LyX
22845  document can be brought under version control in Subversion, its
22846  parent directory needs to be under version control.
22847  If the document is being added to a project already in the repository,
22848  this is accomplished by checking the project out to the directory where
22849  the new document will be placed.
22850  If the project itself is not yet under version control (for instance, if
22851  this document starts a new project), the directory must be imported into
22852  the repository.
22853  This is done outside \SpecialChar LyX
22854 .
22855  Both import and checkout are easily accomplished from the Explorer context
22856  menu using TortoiseSVN, or alternatively can be done using the command
22857  line client at a DOS prompt.
22858  The procedure for importing the project using TortoiseSVN is described
22859  below, assuming an existing repository and a new project being started
22860  in 
22861 \family typewriter
22862 C:
22863 \backslash
22864 new project
22865 \family default
22866 .
22867  For information on using the Subversion client program, run 
22868 \family typewriter
22869 svn --help 
22870 \family default
22871 in a DOS shell.
22872 \end_layout
22873
22874 \begin_layout Enumerate
22875 Locate 
22876 \family typewriter
22877 C:
22878 \backslash
22879 new project 
22880 \family default
22881 in Windows Explorer, right click it, and select 
22882 \family sans
22883 TortoiseSVN\SpecialChar menuseparator
22884 Repo-browser
22885 \family default
22886 .
22887  If necessary, adjust the URL for the repository, then click OK.
22888 \end_layout
22889
22890 \begin_layout Enumerate
22891 Right click the level of the repository under which you want to place the
22892  new project folder (typically the top level) and click 
22893 \family sans
22894 Create folder
22895 \family default
22896  Supply a name for the project folder and click OK.
22897  Add a message for the log file if desired, then click OK again.
22898  The new project folder should appear in the repository.
22899  Finally, click OK again to exit the repository browser.
22900 \end_layout
22901
22902 \begin_layout Enumerate
22903 Once again right click 
22904 \family typewriter
22905 C:
22906 \backslash
22907 new project
22908 \family default
22909 , this time selecting SVN Checkout\SpecialChar ldots
22910  Select the URL of the project folder
22911  you just created in the repository, and set the checkout directory to 
22912 \family typewriter
22913 C:
22914 \backslash
22915 new project.
22916
22917 \family default
22918  Click OK.
22919  You will be warned about a non-empty folder; click OK to proceed.
22920  You should now have a 
22921 \family typewriter
22922 .svn
22923 \family default
22924  directory under 
22925 \family typewriter
22926 C:
22927 \backslash
22928 new project.
22929 \end_layout
22930
22931 \begin_layout Enumerate
22932 Create or open your document in \SpecialChar LyX
22933  and click 
22934 \family sans
22935 File\SpecialChar menuseparator
22936 Version
22937 \begin_inset space ~
22938 \end_inset
22939
22940 Control\SpecialChar menuseparator
22941 Register.
22942  
22943 \family default
22944 Add a log message and click OK to commit the document to version control.
22945 \end_layout
22946
22947 \begin_layout Standard
22948 From this point onward, you should have full functionality in the 
22949 \family sans
22950 File\SpecialChar menuseparator
22951 Version
22952 \begin_inset space ~
22953 \end_inset
22954
22955 Control
22956 \family default
22957  menu.
22958  You also have the option of checking the document in and out, viewing its
22959  history, etc.
22960  using the TortoiseSVN context menu in Windows Explorer or the Subversion
22961  client program from a command prompt.
22962 \end_layout
22963
22964 \begin_layout Subsubsection
22965 SSH tunnel used with SVN under Windows
22966 \end_layout
22967
22968 \begin_layout Standard
22969 Compared with Linux setting up an svn client to communicate over ssh under
22970  Windows is a rather troublesome task.
22971  We will at least offer some hints how to setup the client side but prior
22972  knowledge about ssh and the Windows command line is needed, also be prepared
22973  for a great deal of frustration\SpecialChar ldots
22974
22975 \end_layout
22976
22977 \begin_layout Enumerate
22978 Get an svn client for windows, as described in the previous sections.
22979  When it is a fresh install run some svn command (e.g.
22980  
22981 \begin_inset Flex Code
22982 status collapsed
22983
22984 \begin_layout Plain Layout
22985 svn –version
22986 \end_layout
22987
22988 \end_inset
22989
22990 ) to create config files, which you will need to change later on.
22991 \end_layout
22992
22993 \begin_layout Enumerate
22994 Choose an ssh client for Windows.
22995  There are several possibilities, we will use the one from Putty tools
22996 \begin_inset Foot
22997 status collapsed
22998
22999 \begin_layout Plain Layout
23000 \begin_inset Flex URL
23001 status collapsed
23002
23003 \begin_layout Plain Layout
23004
23005 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
23006 \end_layout
23007
23008 \end_inset
23009
23010
23011 \end_layout
23012
23013 \end_inset
23014
23015 .
23016  You will need to set the connection up so that the client doesn't ask for
23017  any password from you.
23018  To keep things easy we will use only keys without any additional password
23019  protection etc.
23020 \end_layout
23021
23022 \begin_deeper
23023 \begin_layout Enumerate
23024 Generate keys by 
23025 \begin_inset Flex Code
23026 status collapsed
23027
23028 \begin_layout Plain Layout
23029 puttygen
23030 \end_layout
23031
23032 \end_inset
23033
23034 .
23035  Save your private .ppk key file and put the public one on the server side.
23036  If the SVN server runs on Linux, note that the format of the public key
23037  is not compatible with Linux openssh and you will need to direcly copy-paste
23038  the key from the “
23039 \emph on
23040 Public key for pasting into OpenSSH authorized_keys file
23041 \emph default
23042 :” edit field into the server's 
23043 \begin_inset Flex Code
23044 status collapsed
23045
23046 \begin_layout Plain Layout
23047 ~/.ssh/authorized_keys
23048 \end_layout
23049
23050 \end_inset
23051
23052  / 
23053 \begin_inset Flex Code
23054 status collapsed
23055
23056 \begin_layout Plain Layout
23057 authorized_keys2
23058 \end_layout
23059
23060 \end_inset
23061
23062  file.
23063 \end_layout
23064
23065 \begin_layout Enumerate
23066 Get the Putty's 
23067 \begin_inset Flex Code
23068 status collapsed
23069
23070 \begin_layout Plain Layout
23071 plink
23072 \end_layout
23073
23074 \end_inset
23075
23076 .
23077  In the SVN config file
23078 \begin_inset Foot
23079 status collapsed
23080
23081 \begin_layout Plain Layout
23082 Exact path depends on Windows version, usually somewhere around 
23083 \begin_inset Flex Code
23084 status collapsed
23085
23086 \begin_layout Plain Layout
23087 c:
23088 \backslash
23089 Documents and Settings
23090 \backslash
23091 user
23092 \backslash
23093 Application Data
23094 \backslash
23095 Subversion
23096 \backslash
23097 config
23098 \end_layout
23099
23100 \end_inset
23101
23102  / 
23103 \begin_inset Flex Code
23104 status collapsed
23105
23106 \begin_layout Plain Layout
23107 AppData
23108 \backslash
23109 Roaming
23110 \backslash
23111 Subversion
23112 \end_layout
23113
23114 \end_inset
23115
23116 .
23117 \end_layout
23118
23119 \end_inset
23120
23121 , section [tunnels], setup ssh command, e.g.
23122  
23123 \begin_inset Flex Code
23124 status collapsed
23125
23126 \begin_layout Plain Layout
23127 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
23128 \end_layout
23129
23130 \end_inset
23131
23132 .
23133 \begin_inset Foot
23134 status collapsed
23135
23136 \begin_layout Plain Layout
23137 It will usually take a lot of time to get exact command right and it depends
23138  on many things.
23139  For example do not have some remote server saved as a default session in
23140  Putty etc.
23141  If things fail, try to connect via plink without SVN first.
23142 \end_layout
23143
23144 \end_inset
23145
23146
23147 \end_layout
23148
23149 \end_deeper
23150 \begin_layout Enumerate
23151 Checkout the SVN archive, e.
23152 \begin_inset space \thinspace{}
23153 \end_inset
23154
23155 g.
23156 \begin_inset Newline newline
23157 \end_inset
23158
23159
23160 \begin_inset Flex Code
23161 status collapsed
23162
23163 \begin_layout Plain Layout
23164 svn co svn+ssh://user@server/repository_path
23165 \end_layout
23166
23167 \end_inset
23168
23169 .
23170 \end_layout
23171
23172 \begin_layout Subsubsection
23173 End-of-Line Conversions
23174 \end_layout
23175
23176 \begin_layout Standard
23177 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
23178  will
23179  use different line endings inside the .lyx files.
23180  This is not a problem as far as \SpecialChar LyX
23181  functionality is concerned, but the commit
23182  diffs will be huge and merge-conflicts prone.
23183  Fortunately SVN itself knows
23184 \begin_inset Foot
23185 status collapsed
23186
23187 \begin_layout Plain Layout
23188 \begin_inset Flex URL
23189 status collapsed
23190
23191 \begin_layout Plain Layout
23192
23193 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
23194 \end_layout
23195
23196 \end_inset
23197
23198
23199 \end_layout
23200
23201 \end_inset
23202
23203  how to deal with CR/LF problems when switching .lyx files to the 
23204 \begin_inset Flex Code
23205 status collapsed
23206
23207 \begin_layout Plain Layout
23208 native
23209 \end_layout
23210
23211 \end_inset
23212
23213  mode.
23214 \begin_inset Foot
23215 status collapsed
23216
23217 \begin_layout Plain Layout
23218 For the lazy guys: 
23219 \begin_inset Flex Code
23220 status collapsed
23221
23222 \begin_layout Plain Layout
23223 svn propset svn:eol-style native FILE_NAME
23224 \end_layout
23225
23226 \end_inset
23227
23228
23229 \end_layout
23230
23231 \end_inset
23232
23233
23234 \end_layout
23235
23236 \begin_layout Subsection
23237 GIT commands in \SpecialChar LyX
23238
23239 \end_layout
23240
23241 \begin_layout Standard
23242 A minimal subset of GIT commands is now supported by \SpecialChar LyX
23243 .
23244  You can find the commands in the 
23245 \family sans
23246 File\SpecialChar menuseparator
23247 Version
23248 \begin_inset space ~
23249 \end_inset
23250
23251 Control
23252 \family default
23253  submenu.
23254  Please note that if you use password protected access to repository via
23255  ssh, you will be asked in terminal window.
23256  \SpecialChar LyX
23257  was tested against GIT 1.7.
23258 \begin_inset Foot
23259 status open
23260
23261 \begin_layout Plain Layout
23262 Windows users please note that you need to ensure that git is on the path.
23263  This can be set from within \SpecialChar LyX
23264  at 
23265 \family sans
23266 Tools\SpecialChar menuseparator
23267 Preferences\SpecialChar menuseparator
23268 Paths\SpecialChar menuseparator
23269 PATH prefix
23270 \family default
23271 .
23272 \end_layout
23273
23274 \end_inset
23275
23276
23277 \end_layout
23278
23279 \begin_layout Standard
23280 One big difference of GIT and the other supported version control systems
23281  is the distributed nature of GIT: With traditional version control systems
23282  there is one central server which hosts the repository.
23283  Users commit their changes to the server, and get updates made by other
23284  users from it.
23285  With GIT, users commit to a local repository.
23286  The local repository can be synchronized with one or more remote repositories
23287  using the 
23288 \begin_inset Flex Code
23289 status collapsed
23290
23291 \begin_layout Plain Layout
23292 pull
23293 \end_layout
23294
23295 \end_inset
23296
23297  and 
23298 \begin_inset Flex Code
23299 status collapsed
23300
23301 \begin_layout Plain Layout
23302 push
23303 \end_layout
23304
23305 \end_inset
23306
23307  GIT commands.
23308  \SpecialChar LyX
23309  does not interact in any way with remote GIT repositories.
23310  It works exclusively with the local repository in a very similar way as
23311  with a central CVS or SVN repository.
23312  If you use remote GIT repositories you need to do the 
23313 \begin_inset Flex Code
23314 status collapsed
23315
23316 \begin_layout Plain Layout
23317 pull
23318 \end_layout
23319
23320 \end_inset
23321
23322  and 
23323 \begin_inset Flex Code
23324 status collapsed
23325
23326 \begin_layout Plain Layout
23327 push
23328 \end_layout
23329
23330 \end_inset
23331
23332  operations with your favourite GIT client.
23333 \end_layout
23334
23335 \begin_layout Subsubsection
23336
23337 \family sans
23338 Register
23339 \end_layout
23340
23341 \begin_layout Standard
23342 If your document is not under revision control, this is the only item shown
23343  in the menu.
23344  And if it is under revision control, the 
23345 \family sans
23346 Register
23347 \family default
23348  item is not visible.
23349 \end_layout
23350
23351 \begin_layout Standard
23352 This command registers in GIT your document ONLY in case you have already
23353  the documents directory under GIT control (in particular 
23354 \family typewriter
23355 .git/index
23356 \family default
23357  file exists).
23358  This means you have to checkout the archive by yourself.
23359 \end_layout
23360
23361 \begin_layout Standard
23362 Then you are asked interactively to supply an initial description of the
23363  document.
23364  Don't forget that registered file is not yet commited.
23365 \end_layout
23366
23367 \begin_layout Standard
23368 GIT command that is run: 
23369 \family typewriter
23370 git add 
23371 \begin_inset Quotes eld
23372 \end_inset
23373
23374 <file-name>
23375 \begin_inset Quotes erd
23376 \end_inset
23377
23378
23379 \end_layout
23380
23381 \begin_layout Standard
23382 Read 
23383 \family typewriter
23384 man git
23385 \family default
23386  to understand the switches.
23387 \end_layout
23388
23389 \begin_layout Subsubsection
23390
23391 \family sans
23392 Check In Changes
23393 \end_layout
23394
23395 \begin_layout Standard
23396 When you are finished editing a file, you commit your changes.
23397  When you do this, you are asked for a description of the changes.
23398  After that changes are commited.
23399 \end_layout
23400
23401 \begin_layout Standard
23402 GIT command: 
23403 \family typewriter
23404 git commit -q -m"<description>" <file-name>
23405 \end_layout
23406
23407 \begin_layout Subsubsection
23408
23409 \family sans
23410 Revert To Repository Version
23411 \end_layout
23412
23413 \begin_layout Standard
23414 This will discard all changes made to the document since the last check
23415  in.
23416  You get a warning before changes are discarded.
23417 \end_layout
23418
23419 \begin_layout Standard
23420 GIT command: 
23421 \family typewriter
23422 git checkout -q 
23423 \begin_inset Quotes eld
23424 \end_inset
23425
23426 <file-name>
23427 \begin_inset Quotes erd
23428 \end_inset
23429
23430
23431 \end_layout
23432
23433 \begin_layout Subsubsection
23434
23435 \family sans
23436 Rename
23437 \end_layout
23438
23439 \begin_layout Standard
23440 This will rename the current document including the version history.
23441  It requires a clean document without any changes since the last checkin.
23442  You are asked for a file name and a description of the rename operation.
23443  After that the document is renamed, both locally and in the repository.
23444  If the parent directories of the new and old file names differ, all relative
23445  paths of included files are adjusted (like in 
23446 \family sans
23447 File\SpecialChar menuseparator
23448 Save As
23449 \family default
23450 \SpecialChar ldots
23451 ).
23452  Finally, the document is reloaded using the new name.
23453 \end_layout
23454
23455 \begin_layout Labeling
23456 \labelwidthstring 00.00.0000
23457 GIT
23458 \begin_inset space ~
23459 \end_inset
23460
23461 commands: 
23462 \begin_inset space ~
23463 \end_inset
23464
23465
23466 \begin_inset Newline newline
23467 \end_inset
23468
23469
23470 \begin_inset Flex Code
23471 status collapsed
23472
23473 \begin_layout Plain Layout
23474 git mv 
23475 \family typewriter
23476
23477 \begin_inset Quotes eld
23478 \end_inset
23479
23480 <file-name>
23481 \begin_inset Quotes erd
23482 \end_inset
23483
23484  
23485 \begin_inset Quotes eld
23486 \end_inset
23487
23488 <new-file-name>
23489 \begin_inset Quotes erd
23490 \end_inset
23491
23492
23493 \end_layout
23494
23495 \end_inset
23496
23497
23498 \begin_inset Newline newline
23499 \end_inset
23500
23501
23502 \begin_inset Flex Code
23503 status collapsed
23504
23505 \begin_layout Plain Layout
23506 git commit
23507 \end_layout
23508
23509 \end_inset
23510
23511
23512 \end_layout
23513
23514 \begin_layout Subsubsection
23515
23516 \family sans
23517 Show History
23518 \end_layout
23519
23520 \begin_layout Standard
23521 This shows the complete history of the GIT document.
23522  The output of 
23523 \family typewriter
23524 git log 
23525 \begin_inset Quotes eld
23526 \end_inset
23527
23528 <file-name>
23529 \begin_inset Quotes erd
23530 \end_inset
23531
23532
23533 \family default
23534  is shown in a browser.
23535 \end_layout
23536
23537 \begin_layout Subsubsection
23538 Version Info
23539 \end_layout
23540
23541 \begin_layout Standard
23542 \SpecialChar LyX
23543  supports GIT hash number of the last commit to the file, author name, date
23544  and time of last commit.
23545  All those are extracted from 
23546 \family typewriter
23547 git log -n 1 --pretty=format:%H%n%an%n%ai
23548 \family default
23549 .
23550  Tree version information is obtained via 
23551 \family typewriter
23552 git describe --abbrev --dirty --long
23553 \family default
23554 .
23555  See 
23556 \begin_inset CommandInset ref
23557 LatexCommand ref
23558 reference "subsec:VCS-Revision-Information"
23559
23560 \end_inset
23561
23562  for other details.
23563 \end_layout
23564
23565 \begin_layout Subsection
23566 Further tuning
23567 \end_layout
23568
23569 \begin_layout Standard
23570 With the recent addition of the vc-command function \SpecialChar LyX
23571  power users are allowed
23572  to create their own commands for revision control.
23573 \end_layout
23574
23575 \begin_layout Standard
23576 As an example you can see how two TortoiseSVN commands could be integrated
23577  directly:
23578 \end_layout
23579
23580 \begin_layout Description
23581 Commit: 
23582 \begin_inset Flex Code
23583 status collapsed
23584
23585 \begin_layout Plain Layout
23586 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
23587 \end_layout
23588
23589 \end_inset
23590
23591
23592 \end_layout
23593
23594 \begin_layout Description
23595 Revert: 
23596 \begin_inset Flex Code
23597 status collapsed
23598
23599 \begin_layout Plain Layout
23600 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
23601 \end_layout
23602
23603 \end_inset
23604
23605
23606 \end_layout
23607
23608 \begin_layout Subsection
23609 Version control and Document comparison
23610 \end_layout
23611
23612 \begin_layout Standard
23613 One of the typical uses of version control is to inspect the changes between
23614  revisions, usually by creating 
23615 \begin_inset Flex Code
23616 status collapsed
23617
23618 \begin_layout Plain Layout
23619 diff
23620 \end_layout
23621
23622 \end_inset
23623
23624  dumps.
23625  While this is useful for plain text files, it is much less useful in the
23626  case of \SpecialChar LyX
23627  files, which have more a complicated structure.
23628  Hence we provide binding to the Document comparison feature.
23629  There are two ways of calling this feature - either by direct call of 
23630 \begin_inset Flex Code
23631 status collapsed
23632
23633 \begin_layout Plain Layout
23634 VC_COMPARE
23635 \end_layout
23636
23637 \end_inset
23638
23639  \SpecialChar LyX
23640  function (for details see \SpecialChar LyX
23641  functions manual) or by icon/menu item 
23642 \begin_inset Flex Noun
23643 status collapsed
23644
23645 \begin_layout Plain Layout
23646 Compare with older revision...
23647 \end_layout
23648
23649 \end_inset
23650
23651 .
23652  One can either compare two chosen revisions of the document or he can simply
23653  compare the current version of edited text with older revisions (where
23654  '
23655 \begin_inset Flex Noun
23656 status collapsed
23657
23658 \begin_layout Plain Layout
23659 0
23660 \end_layout
23661
23662 \end_inset
23663
23664 ' revisions back means comparison of the edited file with last commited
23665  revision).
23666  
23667 \end_layout
23668
23669 \begin_layout Standard
23670 This feature is supported for SVN and RCS though due to the more complicated
23671  versioning scheme of RCS there is a constraint – when addressing the revisions
23672  in dialog, numbers always point to the last number in RCS revision number,
23673  i.e.
23674  '35' in '1.2.35'.
23675  We don't currently support GIT addressing of revisions, one can just compare
23676  edited document with its revision X steps backs, where X is addressed as
23677  HEAD~X.
23678 \end_layout
23679
23680 \begin_layout Section
23681 Literate Programming
23682 \end_layout
23683
23684 \begin_layout Standard
23685 Updated by 
23686 \noun on
23687 Kayvan Sylvan 
23688 \noun default
23689 (kayvan@sylvan.com)
23690 \noun on
23691
23692 \noun default
23693 original documentation written by 
23694 \noun on
23695 Edmar Wienskoski Jr.
23696
23697 \noun default
23698  (edmar-w-jr@technologist.com)
23699 \end_layout
23700
23701 \begin_layout Subsection
23702 Introduction
23703 \end_layout
23704
23705 \begin_layout Standard
23706 The main purpose of this documentation is to show you how to use \SpecialChar LyX
23707  for literate
23708  programming, where it is assumed that you are familiar with this programming
23709  technique, and know what 
23710 \begin_inset Quotes eld
23711 \end_inset
23712
23713 tangling
23714 \begin_inset Quotes erd
23715 \end_inset
23716
23717  and 
23718 \begin_inset Quotes eld
23719 \end_inset
23720
23721 weaving
23722 \begin_inset Quotes erd
23723 \end_inset
23724
23725  means.
23726  If that is not the case, please follow the web links provided in the following
23727  sections.
23728  There is a lot of good documentation out there covering old development
23729  history to the latest tools tips.
23730 \end_layout
23731
23732 \begin_layout Standard
23733 It is also assumed that you are familiar with \SpecialChar LyX
23734  itself to a point that you
23735  are comfortable changing your \SpecialChar LyX
23736  preferences, and X resources file.
23737  If that is not the case please refer to other \SpecialChar LyX
23738  documentation to cover your
23739  specific needs.
23740 \end_layout
23741
23742 \begin_layout Subsection
23743 Literate Programming
23744 \end_layout
23745
23746 \begin_layout Standard
23747 From the Literate Programming FAQ: 
23748 \end_layout
23749
23750 \begin_layout Quotation
23751 Literate programming is the combination of documentation and source together
23752  in a fashion suited for reading by human beings.
23753  In fact, literate programs should be enjoyable reading, even inviting!
23754  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
23755  and documentation in a single file.
23756  Literate programming tools then parse the file to produce either readable
23757  documentation or compilable source.
23758  The WEB style of literate programming was created by D.
23759 \begin_inset space \thinspace{}
23760 \end_inset
23761
23762 E.
23763  Knuth during the development of his \SpecialChar TeX
23764  typesetting software.
23765  
23766 \end_layout
23767
23768 \begin_layout Standard
23769 Another excerpt says:
23770 \end_layout
23771
23772 \begin_layout Quotation
23773
23774 \emph on
23775 How is literate programming different from verbose commenting?
23776 \end_layout
23777
23778 \begin_layout Quotation
23779 There are three distinguishing characteristics.
23780  In order of importance, they are: 
23781 \end_layout
23782
23783 \begin_deeper
23784 \begin_layout Itemize
23785 flexible order of elaboration 
23786 \end_layout
23787
23788 \begin_layout Itemize
23789 automatic support for browsing 
23790 \end_layout
23791
23792 \begin_layout Itemize
23793 typeset documentation, especially diagrams and mathematics 
23794 \end_layout
23795
23796 \end_deeper
23797 \begin_layout Standard
23798 Now that I sparked your curiosity, take a look in the references.
23799 \end_layout
23800
23801 \begin_layout Subsubsection
23802 References
23803 \end_layout
23804
23805 \begin_layout Standard
23806 The complete Literate Programming FAQ can be found at:
23807 \end_layout
23808
23809 \begin_layout Quote
23810 Literate Programming FAQ 
23811 \begin_inset Flex URL
23812 status collapsed
23813
23814 \begin_layout Plain Layout
23815
23816 http://www.literateprogramming.com/lpfaq.pdf
23817 \end_layout
23818
23819 \end_inset
23820
23821
23822 \end_layout
23823
23824 \begin_layout Standard
23825 The FAQ lists 23 (twenty three!) different literate programming tools.
23826  Where some are specialized or 
23827 \begin_inset Quotes eld
23828 \end_inset
23829
23830 tailored
23831 \begin_inset Quotes erd
23832 \end_inset
23833
23834  for particular programming languages, while other have general scope.
23835  I selected 
23836 \noun on
23837 Noweb
23838 \noun default
23839  for my own use for several reasons:
23840 \end_layout
23841
23842 \begin_layout Itemize
23843 It can generate the documentation either in \SpecialChar LaTeX
23844  or HTML.
23845 \end_layout
23846
23847 \begin_layout Itemize
23848 It has a open architecture, i.
23849 \begin_inset space \thinspace{}
23850 \end_inset
23851
23852 e.
23853 \begin_inset space \space{}
23854 \end_inset
23855
23856 it is easy to plug in new filters and to perform special processing that
23857  you may need.
23858  
23859 \end_layout
23860
23861 \begin_layout Itemize
23862 There is a good selection of filters available already (the HTML is one
23863  of them).
23864 \end_layout
23865
23866 \begin_layout Itemize
23867 It is free.
23868 \end_layout
23869
23870 \begin_layout Standard
23871 The Noweb web page can be found at: 
23872 \end_layout
23873
23874 \begin_layout Quote
23875 Noweb home page 
23876 \begin_inset Flex URL
23877 status collapsed
23878
23879 \begin_layout Plain Layout
23880
23881 http://www.cs.virginia.edu/~nr/noweb/
23882 \end_layout
23883
23884 \end_inset
23885
23886
23887 \end_layout
23888
23889 \begin_layout Standard
23890 Starting from there you can reach many other interesting links and even
23891  some literate program examples.
23892 \end_layout
23893
23894 \begin_layout Subsection
23895 \SpecialChar LyX
23896  and Literate Programming with Noweb
23897 \end_layout
23898
23899 \begin_layout Standard
23900 The \SpecialChar LyX
23901  support for Literate Programming is provided by using the generic \SpecialChar LyX
23902
23903  converters mechanism.
23904  This support is provided in a 
23905 \begin_inset Quotes eld
23906 \end_inset
23907
23908 Noweb independent
23909 \begin_inset Quotes erd
23910 \end_inset
23911
23912  way, i.
23913 \begin_inset space \thinspace{}
23914 \end_inset
23915
23916 e.
23917 \begin_inset space \space{}
23918 \end_inset
23919
23920 you will be able to use this new \SpecialChar LyX
23921  feature with some other literate programming
23922  tool of your choice by just changing your \SpecialChar LyX
23923  preferences.
23924 \end_layout
23925
23926 \begin_layout Subsubsection
23927 Generating documents and code (weaving and tangling)
23928 \end_layout
23929
23930 \begin_layout Paragraph
23931 Using the noweb module
23932 \end_layout
23933
23934 \begin_layout Standard
23935 If you have installed Noweb and \SpecialChar LyX
23936  successfully, whenever you open a new document,
23937  after you have chosen its document class, use the Document->Settings menu
23938  to add the 
23939 \begin_inset Quotes eld
23940 \end_inset
23941
23942 noweb
23943 \begin_inset Quotes erd
23944 \end_inset
23945
23946  module.
23947  If Noweb is correctly installed, when you click on the 
23948 \begin_inset Quotes eld
23949 \end_inset
23950
23951 Modules
23952 \begin_inset Quotes erd
23953 \end_inset
23954
23955  link, you will see the 
23956 \begin_inset Quotes eld
23957 \end_inset
23958
23959 noweb
23960 \begin_inset Quotes erd
23961 \end_inset
23962
23963  module in the available list and you can add it to your document.
23964 \end_layout
23965
23966 \begin_layout Paragraph
23967 Typing code in
23968 \end_layout
23969
23970 \begin_layout Standard
23971 \SpecialChar LyX
23972  enables you to write code with a layout named 
23973 \begin_inset Flex Noun
23974 status collapsed
23975
23976 \begin_layout Plain Layout
23977 Chunk
23978 \end_layout
23979
23980 \end_inset
23981
23982 .
23983  Noweb delimits chunks like this:
23984 \end_layout
23985
23986 \begin_layout LyX-Code
23987 <<My code>>=
23988 \end_layout
23989
23990 \begin_layout LyX-Code
23991   code
23992 \end_layout
23993
23994 \begin_layout LyX-Code
23995   more code
23996 \end_layout
23997
23998 \begin_layout LyX-Code
23999   even more code
24000 \end_layout
24001
24002 \begin_layout LyX-Code
24003   @
24004 \end_layout
24005
24006 \begin_layout Standard
24007 The problem is that whatever is written in between the << and the 
24008 \family typewriter
24009 @
24010 \family default
24011  must be taken literally, i.
24012 \begin_inset space \thinspace{}
24013 \end_inset
24014
24015 e.
24016 \begin_inset space \space{}
24017 \end_inset
24018
24019 \SpecialChar LyX
24020  should be prevented from making any special interpretation of what has
24021  been written.
24022  This is also handled by 
24023 \begin_inset Flex Noun
24024 status collapsed
24025
24026 \begin_layout Plain Layout
24027 Chunk
24028 \end_layout
24029
24030 \end_inset
24031
24032 , that works like a normal paragraph but has a free spacing capability.
24033 \end_layout
24034
24035 \begin_layout Standard
24036 As a special note, you can also use the 
24037 \begin_inset Quotes eld
24038 \end_inset
24039
24040 %def
24041 \begin_inset Quotes erd
24042 \end_inset
24043
24044  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
24045 rence:
24046 \end_layout
24047
24048 \begin_layout LyX-Code
24049 <<My chunk>>=
24050 \end_layout
24051
24052 \begin_layout LyX-Code
24053 def some_function(args):
24054 \end_layout
24055
24056 \begin_layout LyX-Code
24057    "This is the doc string for this function."
24058 \end_layout
24059
24060 \begin_layout LyX-Code
24061    print "My args: ", args
24062 \end_layout
24063
24064 \begin_layout LyX-Code
24065 @ %def some_function
24066 \end_layout
24067
24068 \begin_layout Standard
24069 For an example of this usage and the resulting cross-reference output, look
24070  at the Literate python program in 
24071 \emph on
24072 LIBDIR/examples/listerrors.lyx
24073 \emph default
24074  which should make this all clear.
24075 \end_layout
24076
24077 \begin_layout Paragraph
24078 Generating the documentation
24079 \end_layout
24080
24081 \begin_layout Standard
24082 At this point you already have a new document file with a proper document
24083  class, and with some code and text on it.
24084  How do I print it? The answer is simple, you select 
24085 \family sans
24086 View\SpecialChar menuseparator
24087 DVI,
24088 \family default
24089  etc.
24090  Just like you would do for a plain document.
24091  No special procedure is required.
24092 \end_layout
24093
24094 \begin_layout Standard
24095 To help orientate you, I will now explain what happens inside \SpecialChar LyX
24096 :
24097 \end_layout
24098
24099 \begin_layout Enumerate
24100 When the 
24101 \family sans
24102 Update\SpecialChar menuseparator
24103 DVI
24104 \family default
24105  menu option is chosen, a \SpecialChar LaTeX
24106  file is generated.
24107  
24108 \end_layout
24109
24110 \begin_deeper
24111 \begin_layout Standard
24112 If the document is of any literate class the generated file will be named
24113  with an extension name defined by the 
24114 \begin_inset Quotes eld
24115 \end_inset
24116
24117 literate
24118 \begin_inset Quotes erd
24119 \end_inset
24120
24121  format (defined in the Preferences panel), otherwise the file will have
24122  the usual 
24123 \family typewriter
24124 .tex
24125 \family default
24126  extension.
24127 \end_layout
24128
24129 \end_deeper
24130 \begin_layout Enumerate
24131 Note that the only difference so far is in the name of the file, no special
24132  processing is required by \SpecialChar LyX
24133 .
24134  Given that you formatted the code using the 
24135 \begin_inset Flex Noun
24136 status collapsed
24137
24138 \begin_layout Plain Layout
24139 Chunk
24140 \end_layout
24141
24142 \end_inset
24143
24144  layout that, by itself, takes care of the business.
24145 \end_layout
24146
24147 \begin_layout Enumerate
24148 If the document is of any literate class \SpecialChar LyX
24149  will then use the internal \SpecialChar LyX
24150  to
24151  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
24152  converter
24153 \begin_inset Foot
24154 status collapsed
24155
24156 \begin_layout Plain Layout
24157 The converters are defined in the 
24158 \family sans
24159 Tools\SpecialChar menuseparator
24160 Preferences
24161 \family default
24162  panel, under the 
24163 \begin_inset Quotes eld
24164 \end_inset
24165
24166 Conversion
24167 \begin_inset Quotes erd
24168 \end_inset
24169
24170  tab.
24171  See section 
24172 \emph on
24173 Converters
24174 \emph default
24175  of the 
24176 \emph on
24177 Customization
24178 \emph default
24179  manual for general information about converters.
24180 \end_layout
24181
24182 \end_inset
24183
24184  to generate the \SpecialChar LaTeX
24185  file.
24186 \end_layout
24187
24188 \begin_deeper
24189 \begin_layout Standard
24190 Otherwise it will just skip this step.
24191 \end_layout
24192
24193 \end_deeper
24194 \begin_layout Enumerate
24195 Finally, \SpecialChar LaTeX
24196  is invoked and the regular post processing continues as in a plain
24197  document.
24198 \end_layout
24199
24200 \begin_layout Standard
24201 Independence from a particular 
24202 \begin_inset Quotes eld
24203 \end_inset
24204
24205 literate tool
24206 \begin_inset Quotes erd
24207 \end_inset
24208
24209  is easily achieved by changing the commands that are run by the various
24210  converters.
24211 \end_layout
24212
24213 \begin_layout Paragraph
24214 Generating the code
24215 \end_layout
24216
24217 \begin_layout Standard
24218 When the build menu option is chosen or the corresponding button in the
24219  toolbar is pressed, a \SpecialChar LaTeX
24220  file is generated just like step 1 above.
24221  Next, \SpecialChar LyX
24222  invokes the 
24223 \family typewriter
24224 Noweb->Program
24225 \family default
24226  converter.
24227  This converter needs to be defined by the user and is not installed by
24228  default, though the Program format is.
24229  This converter (like any other converter) will have two parts:
24230 \end_layout
24231
24232 \begin_layout Enumerate
24233 The converter program itself.
24234  This program performs the conversion from the one format to the other (in
24235  this case, from the Noweb format to the Program pseudo-format).
24236 \end_layout
24237
24238 \begin_layout Enumerate
24239 The error log parser.
24240  This is a program whose sole purpose is to rewrite error messages in a
24241  format that \SpecialChar LyX
24242  understands.
24243  This makes it possible for \SpecialChar LyX
24244  to place error boxes in the right places in
24245  the file buffer.
24246 \end_layout
24247
24248 \begin_layout Standard
24249 The first part, the 
24250 \begin_inset Quotes eld
24251 \end_inset
24252
24253 Converter
24254 \begin_inset Quotes erd
24255 \end_inset
24256
24257  setting, should be set to
24258 \begin_inset Newline newline
24259 \end_inset
24260
24261
24262 \begin_inset Quotes eld
24263 \end_inset
24264
24265
24266 \family typewriter
24267 build-script $$i
24268 \family default
24269  $$r
24270 \begin_inset Quotes erd
24271 \end_inset
24272
24273 .
24274 \begin_inset Newline newline
24275 \end_inset
24276
24277 This basically means that \SpecialChar LyX
24278  will call 
24279 \begin_inset Quotes eld
24280 \end_inset
24281
24282 build-script
24283 \begin_inset Quotes erd
24284 \end_inset
24285
24286  (a program or script) with the name of the Noweb file (normally a file
24287  in the \SpecialChar LyX
24288  temp directory) and the directory path of the original \SpecialChar LyX
24289  file.
24290  
24291 \end_layout
24292
24293 \begin_layout Standard
24294 This is an implementation of 
24295 \begin_inset Quotes eld
24296 \end_inset
24297
24298 build-script
24299 \begin_inset Quotes erd
24300 \end_inset
24301
24302  that you can place in a directory on your path:
24303 \end_layout
24304
24305 \begin_layout Standard
24306 \begin_inset VSpace defskip
24307 \end_inset
24308
24309
24310 \end_layout
24311
24312 \begin_layout Standard
24313 \begin_inset Newpage pagebreak
24314 \end_inset
24315
24316
24317 \end_layout
24318
24319 \begin_layout Standard
24320
24321 \family sans
24322 #!/bin/sh
24323 \end_layout
24324
24325 \begin_layout Standard
24326
24327 \family sans
24328 #
24329 \end_layout
24330
24331 \begin_layout Standard
24332
24333 \family sans
24334 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
24335 \end_layout
24336
24337 \begin_layout Standard
24338 \begin_inset VSpace defskip
24339 \end_inset
24340
24341
24342 \end_layout
24343
24344 \begin_layout Standard
24345 The next part of the converter setting is the 
24346 \begin_inset Quotes eld
24347 \end_inset
24348
24349 Flags
24350 \begin_inset Quotes erd
24351 \end_inset
24352
24353  which is to be set to
24354 \begin_inset Newline newline
24355 \end_inset
24356
24357
24358 \begin_inset Quotes eld
24359 \end_inset
24360
24361
24362 \family typewriter
24363 parselog=$$s/scripts/listerrors
24364 \family default
24365
24366 \begin_inset Quotes erd
24367 \end_inset
24368
24369 .
24370 \begin_inset Newline newline
24371 \end_inset
24372
24373 This will run any errors that are generated by the 
24374 \begin_inset Quotes eld
24375 \end_inset
24376
24377 build-script
24378 \begin_inset Quotes erd
24379 \end_inset
24380
24381  process through the 
24382 \begin_inset Quotes eld
24383 \end_inset
24384
24385 listerrors
24386 \begin_inset Quotes erd
24387 \end_inset
24388
24389  program.
24390 \end_layout
24391
24392 \begin_layout Standard
24393 The build will normally take place in \SpecialChar LyX
24394 's temporary directory, so the files
24395  produced by the conversion will be in that directory.
24396  \SpecialChar LyX
24397  will copy out what it regards as the `main' file, but the 
24398 \family typewriter
24399 Noweb->Program
24400 \family default
24401  conversion may produce several files, and so most of these would then be
24402  deleted when \SpecialChar LyX
24403  was closed.
24404  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
24405  the build-script chunk can place the generated files in that location.
24406 \end_layout
24407
24408 \begin_layout Paragraph
24409 Build instructions in the document
24410 \end_layout
24411
24412 \begin_layout Standard
24413 The last piece of the integration between \SpecialChar LyX
24414  and noweb is the 
24415 \begin_inset Quotes eld
24416 \end_inset
24417
24418 build-script
24419 \begin_inset Quotes erd
24420 \end_inset
24421
24422  chunk.
24423  Generally, the instructions for building your program should be embedded
24424  in a chunk of its own.
24425  The noweb-specific 
24426 \begin_inset Quotes eld
24427 \end_inset
24428
24429 build-script
24430 \begin_inset Quotes erd
24431 \end_inset
24432
24433  above uses the notangle command to look for this chunk (called 
24434 \begin_inset Quotes eld
24435 \end_inset
24436
24437 build-script
24438 \begin_inset Quotes erd
24439 \end_inset
24440
24441 ) and runs its contents through 
24442 \begin_inset Quotes eld
24443 \end_inset
24444
24445 sh
24446 \begin_inset Quotes erd
24447 \end_inset
24448
24449 .
24450 \end_layout
24451
24452 \begin_layout Standard
24453 Typically, such a chunk would look something like this:
24454 \end_layout
24455
24456 \begin_layout LyX-Code
24457 <<build-script>>=
24458 \end_layout
24459
24460 \begin_layout LyX-Code
24461 #!/bin/sh
24462 \begin_inset Newline newline
24463 \end_inset
24464
24465 if [ -z "${NOWEB_SOURCE}" ]
24466 \begin_inset Newline newline
24467 \end_inset
24468
24469 then
24470 \end_layout
24471
24472 \begin_layout LyX-Code
24473 NOWEB_SOURCE=myfile.nw
24474 \begin_inset Newline newline
24475 \end_inset
24476
24477 fi
24478 \begin_inset Newline newline
24479 \end_inset
24480
24481 [...
24482  code to extract files ...
24483  use NOWEB_OUTPUT_DIR here ...]
24484 \begin_inset Newline newline
24485 \end_inset
24486
24487 [...
24488  code to compile files ...]
24489 \begin_inset Newline newline
24490 \end_inset
24491
24492 @
24493 \end_layout
24494
24495 \begin_layout Standard
24496 Look in 
24497 \emph on
24498 LIBDIR/examples/listerrors.lyx
24499 \emph default
24500  or in 
24501 \emph on
24502 LIBDIR/examples/Literate.lyx
24503 \emph default
24504  which implement two versions of the 
24505 \begin_inset Quotes eld
24506 \end_inset
24507
24508 listerrors
24509 \begin_inset Quotes erd
24510 \end_inset
24511
24512  program for some illustrations of how all of these pieces go together or
24513  in 
24514 \emph on
24515 LIBDIR/examples/noweb2lyx.lyx.
24516
24517 \emph default
24518  Interestingly, these three files show off the language-indepence of the
24519  \SpecialChar LyX
24520  literate programming support since they are written in Python, C and Perl
24521  respectively.
24522 \end_layout
24523
24524 \begin_layout Subsubsection
24525 Configuring \SpecialChar LyX
24526
24527 \end_layout
24528
24529 \begin_layout Standard
24530 All the Literate Programming support is configured by the 
24531 \family sans
24532 Tools\SpecialChar menuseparator
24533 Preferences
24534 \family default
24535  panel in the 
24536 \begin_inset Quotes eld
24537 \end_inset
24538
24539 File Handling
24540 \begin_inset Quotes erd
24541 \end_inset
24542
24543  tab.
24544  The important parts are:
24545 \end_layout
24546
24547 \begin_layout Description
24548 the
24549 \begin_inset space ~
24550 \end_inset
24551
24552
24553 \begin_inset Quotes eld
24554 \end_inset
24555
24556 NoWeb
24557 \begin_inset Quotes erd
24558 \end_inset
24559
24560
24561 \begin_inset space ~
24562 \end_inset
24563
24564 format Set up via the File Formats tab, this is where the Noweb-specific
24565  pieces are set up.
24566  The 
24567 \family sans
24568 GUI Name
24569 \family default
24570  is set to 
24571 \family typewriter
24572 NoWeb
24573 \family default
24574 , the file extension is set to 
24575 \family typewriter
24576 .nw
24577 \family default
24578 .
24579  This tells \SpecialChar LyX
24580  to create a file with a 
24581 \family typewriter
24582 .nw
24583 \family default
24584  extension in the first step of the conversion process.
24585 \end_layout
24586
24587 \begin_layout Description
24588 the
24589 \begin_inset space ~
24590 \end_inset
24591
24592
24593 \family sans
24594 Program
24595 \family default
24596
24597 \begin_inset space ~
24598 \end_inset
24599
24600 format This is an empty format whose sole purpose is to be the endpoint
24601  of a conversion (which then allows us to set up a converter for it).
24602 \end_layout
24603
24604 \begin_layout Description
24605
24606 \family sans
24607 NoWeb
24608 \family default
24609 ->
24610 \family sans
24611 \SpecialChar LaTeX
24612
24613 \family default
24614  This converter performs the 
24615 \begin_inset Quotes eld
24616 \end_inset
24617
24618 weaving
24619 \begin_inset Quotes erd
24620 \end_inset
24621
24622  of the literate document.
24623  For Noweb, it is set to 
24624 \begin_inset Quotes eld
24625 \end_inset
24626
24627
24628 \family typewriter
24629 noweave -delay -index $$i > $$o
24630 \family default
24631
24632 \begin_inset Quotes erd
24633 \end_inset
24634
24635
24636 \end_layout
24637
24638 \begin_layout Description
24639
24640 \family sans
24641 NoWeb
24642 \family default
24643 ->
24644 \family sans
24645 Program
24646 \family default
24647  This performs the 
24648 \begin_inset Quotes eld
24649 \end_inset
24650
24651 tangling step
24652 \begin_inset Quotes erd
24653 \end_inset
24654
24655 .
24656  As stated above, the Converter is set to 
24657 \begin_inset Quotes eld
24658 \end_inset
24659
24660
24661 \family typewriter
24662 build-script $$i
24663 \family default
24664  $$r
24665 \begin_inset Quotes erd
24666 \end_inset
24667
24668 , with Flags set to
24669 \begin_inset Newline newline
24670 \end_inset
24671
24672
24673 \begin_inset Quotes eld
24674 \end_inset
24675
24676
24677 \family typewriter
24678 parselog=$$s/scripts/listerrors
24679 \family default
24680
24681 \begin_inset Quotes erd
24682 \end_inset
24683
24684 .
24685 \end_layout
24686
24687 \begin_layout Subsubsection
24688 Debug extensions
24689 \end_layout
24690
24691 \begin_layout Standard
24692 There is also a new function implemented in the \SpecialChar LyX
24693  server, the 
24694 \begin_inset Quotes eld
24695 \end_inset
24696
24697 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
24698  
24699 \end_layout
24700
24701 \begin_layout Standard
24702 When debugging code with ddd/gdb, it is possible to invoke a text editor
24703  at the current execution position with a single key stroke.
24704  The default ddd configuration for that is shift-ctrl-V.
24705  It happens that you can define the editor command line invocation in ddd
24706  by accessing the 
24707 \family sans
24708 Edit\SpecialChar menuseparator
24709 Preferences\SpecialChar menuseparator
24710 Helpers
24711 \family default
24712  dialog and changing the "Edit Sources" entry.
24713 \end_layout
24714
24715 \begin_layout Standard
24716 I take advantage of the newly created \SpecialChar LyX
24717  server function and this ddd feature,
24718  and set 
24719 \begin_inset Quotes eld
24720 \end_inset
24721
24722 Edit Sources
24723 \begin_inset Quotes erd
24724 \end_inset
24725
24726  to:
24727 \end_layout
24728
24729 \begin_layout Standard
24730 \begin_inset VSpace defskip
24731 \end_inset
24732
24733
24734 \end_layout
24735
24736 \begin_layout Standard
24737
24738 \family sans
24739 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
24740 \end_layout
24741
24742 \begin_layout Standard
24743 \begin_inset VSpace defskip
24744 \end_inset
24745
24746
24747 \end_layout
24748
24749 \begin_layout Standard
24750 With this, whenever you are using ddd and find a point in the program that
24751  you want to edit, you just press shift-ctrl-V (in the ddd window), and
24752  ddd will forward this information to \SpecialChar LyX
24753  through the \SpecialChar LyX
24754  server and then the
24755  \SpecialChar LyX
24756  window will show the same file with the cursor at the same position ddd
24757  was pointing to.
24758  No more guessing or long scrolling to locate a point in the program back
24759  from debugging !
24760 \end_layout
24761
24762 \begin_layout Standard
24763 Note however that you must enable the \SpecialChar LyX
24764  server to get this feature working
24765  (it is disabled by default).
24766  You can enable it in 
24767 \family sans
24768 Preferences
24769 \family default
24770  (tabs 
24771 \family sans
24772 Inputs
24773 \family default
24774
24775 \family sans
24776 Paths
24777 \family default
24778 ) by entering in the 
24779 \family sans
24780 \SpecialChar LyX
24781 server pipe
24782 \family default
24783  a path like 
24784 \begin_inset Quotes eld
24785 \end_inset
24786
24787
24788 \family typewriter
24789 /home/<your-home-directory>/.lyx/lyxpipe
24790 \family default
24791
24792 \begin_inset Quotes erd
24793 \end_inset
24794
24795
24796 \end_layout
24797
24798 \begin_layout Standard
24799 Read the \SpecialChar LyX
24800  server documentation in the 
24801 \emph on
24802 Customization Manual
24803 \emph default
24804  for further information.
24805 \end_layout
24806
24807 \begin_layout Subsubsection
24808 Toolbar extensions
24809 \end_layout
24810
24811 \begin_layout Standard
24812 There are six new buttons that can be added to your \SpecialChar LyX
24813  toolbar.
24814  Five of these buttons are short cuts to layout styles: 
24815 \family sans
24816 Standard
24817 \family default
24818
24819 \family sans
24820 Section
24821 \family default
24822
24823 \family sans
24824 \SpecialChar LaTeX
24825
24826 \family default
24827
24828 \family sans
24829 \SpecialChar LyX
24830 -Code
24831 \family default
24832 , and 
24833 \family sans
24834 Chunk
24835 \family default
24836 .
24837  The last one is a short cut to the 
24838 \begin_inset Quotes eld
24839 \end_inset
24840
24841 Build Program
24842 \begin_inset Quotes erd
24843 \end_inset
24844
24845  File menu entry.
24846  
24847 \end_layout
24848
24849 \begin_layout Standard
24850 \SpecialChar LyX
24851  has a range of buttons that are available for tool bar customization.
24852  In my toolbar I like to combine the six short cuts above with two more:
24853  One for 
24854 \family sans
24855 Document
24856 \family default
24857 \SpecialChar menuseparator
24858
24859 \family sans
24860 Update
24861 \family default
24862 \SpecialChar menuseparator
24863
24864 \family sans
24865 DVI
24866 \family default
24867  and the other for 
24868 \family sans
24869 Document\SpecialChar menuseparator
24870 View\SpecialChar menuseparator
24871 DVI
24872 \family default
24873  File menu entries.
24874  Here is how it looks like:
24875 \end_layout
24876
24877 \begin_layout LyX-Code
24878 Toolbar
24879 \end_layout
24880
24881 \begin_layout LyX-Code
24882   Layouts
24883 \end_layout
24884
24885 \begin_layout LyX-Code
24886   Icon "layout Standard"
24887 \end_layout
24888
24889 \begin_layout LyX-Code
24890   Icon "layout Section"
24891 \end_layout
24892
24893 \begin_layout LyX-Code
24894   Icon "layout \SpecialChar LaTeX
24895 "
24896 \end_layout
24897
24898 \begin_layout LyX-Code
24899   Icon "layout \SpecialChar LyX
24900 -Code"
24901 \end_layout
24902
24903 \begin_layout LyX-Code
24904   Icon "layout Chunk"
24905 \end_layout
24906
24907 \begin_layout LyX-Code
24908   Separator
24909 \end_layout
24910
24911 \begin_layout LyX-Code
24912   Icon "buffer-view"
24913 \end_layout
24914
24915 \begin_layout LyX-Code
24916   Icon "buffer-typeset"
24917 \end_layout
24918
24919 \begin_layout LyX-Code
24920   Icon "build-program"
24921 \end_layout
24922
24923 \begin_layout LyX-Code
24924   Separator
24925 \end_layout
24926
24927 \begin_layout LyX-Code
24928 .
24929 \end_layout
24930
24931 \begin_layout LyX-Code
24932 .
24933 \end_layout
24934
24935 \begin_layout LyX-Code
24936 .
24937 \end_layout
24938
24939 \begin_layout LyX-Code
24940 End
24941 \end_layout
24942
24943 \begin_layout Subsubsection
24944 Colors customization
24945 \end_layout
24946
24947 \begin_layout Standard
24948 There are a number of colors in \SpecialChar LyX
24949  that can be customized in 
24950 \family sans
24951 Preferences
24952 \family default
24953 .
24954  One of the things that bothers people is the \SpecialChar LaTeX
24955  font color.
24956  The default color is red, since the chunks uses \SpecialChar LaTeX
24957  font, and there is a lot
24958  of chunks in literate documents, you may get tired of seeing everything
24959  in red.
24960  You can change it by going to the tabs 
24961 \family sans
24962 Look&Feel
24963 \family default
24964
24965 \family sans
24966 Colors.
24967 \end_layout
24968
24969 \begin_layout Standard
24970 The next thing is the visible presence of the newline character in the screen.
24971  You can choose the color of this particular character and make it blend
24972  in the background.
24973  I recommend you choosing a color that is close to the background but not
24974  equal, that way you still can see it is there, but it is not bothering
24975  you anymore.
24976 \end_layout
24977
24978 \begin_layout Subsection
24979 \SpecialChar LyX
24980  and knitr/Sweave
24981 \end_layout
24982
24983 \begin_layout Standard
24984 Support for 
24985 \family sans
24986 knitr
24987 \family default
24988  and 
24989 \family sans
24990 Sweave
24991 \family default
24992  is documented in the 
24993 \emph on
24994 knitr.lyx
24995 \emph default
24996  example file and in the Sweave manual (menu 
24997 \family sans
24998 Help\SpecialChar menuseparator
24999 Specific Manuals
25000 \family default
25001 ).
25002 \end_layout
25003
25004 \begin_layout Chapter
25005 Special features
25006 \end_layout
25007
25008 \begin_layout Standard
25009 You can do everything with \SpecialChar LyX
25010  that you can do with \SpecialChar LaTeX
25011 .
25012  However, \SpecialChar LyX
25013  cannot support every \SpecialChar LaTeX
25014  feature directly.
25015  But you can always use \SpecialChar TeX
25016  Code.
25017  This chapter shows you some more special things you might want to use.
25018  For other special things you can do with figures, tables, floats, boxes
25019  and notes, have a look at the 
25020 \emph on
25021 Embedded
25022 \begin_inset space ~
25023 \end_inset
25024
25025 Objects
25026 \emph default
25027  manual.
25028 \end_layout
25029
25030 \begin_layout Section
25031 Multiple Text Columns
25032 \end_layout
25033
25034 \begin_layout Standard
25035 This feature is independent of the option 
25036 \family sans
25037 Two-column document
25038 \family default
25039  in the document settings under 
25040 \family sans
25041 Text Layout
25042 \family default
25043 .
25044  If you want to have 2
25045 \begin_inset space ~
25046 \end_inset
25047
25048 columns for the whole document, it is recommended to use the 
25049 \family sans
25050 Two-column document
25051 \family default
25052  option.
25053  For all other cases use this feature.
25054 \end_layout
25055
25056 \begin_layout Standard
25057 To use multiple text columns in your document, you have to load the module
25058  
25059 \family sans
25060 Multiple Columns
25061 \family default
25062  (menu 
25063 \family sans
25064 Document\SpecialChar menuseparator
25065 Settings\SpecialChar menuseparator
25066 Modules
25067 \family default
25068 ) and must have the \SpecialChar LaTeX
25069 -package 
25070 \series bold
25071 multicol
25072 \series default
25073  installed.
25074 \end_layout
25075
25076 \begin_layout Standard
25077 Footnotes within multiple columns will be placed at the bottom of the page
25078  and not under each column.
25079  Within the different columns you can use everything, with the limitation
25080  that for floats you need to use the float option 
25081 \family sans
25082 Span columns
25083 \family default
25084 .
25085 \end_layout
25086
25087 \begin_layout Subsection
25088 Basics
25089 \end_layout
25090
25091 \begin_layout Standard
25092 If you want to have 2
25093 \begin_inset space ~
25094 \end_inset
25095
25096 columns in your text, insert a multicolumn inset via the menu 
25097 \family sans
25098 Insert\SpecialChar menuseparator
25099 Custom
25100 \begin_inset space ~
25101 \end_inset
25102
25103 Insets\SpecialChar menuseparator
25104 Multiple
25105 \begin_inset space ~
25106 \end_inset
25107
25108 Columns
25109 \family default
25110  where the columns should start.
25111  Write all text that should be printed in 2
25112 \begin_inset space ~
25113 \end_inset
25114
25115 columns into this inset.
25116 \end_layout
25117
25118 \begin_layout Standard
25119 Here is an example:
25120 \end_layout
25121
25122 \begin_layout Standard
25123 \noindent
25124 \begin_inset Flex Multiple Columns
25125 status open
25126
25127 \begin_layout Plain Layout
25128 \noindent
25129
25130 \series bold
25131 \size small
25132 The Adventure of the Empty House
25133 \series default
25134
25135 \begin_inset Newline newline
25136 \end_inset
25137
25138 by Sir Arthur Conan Doyle
25139 \end_layout
25140
25141 \begin_layout Plain Layout
25142
25143 \size small
25144 It was in the spring of the year 1894 that all London was interested, and
25145  the fashionable world dismayed, by the murder of the Honourable Ronald
25146  Adair under most unusual and inexplicable circumstances.
25147  The public has already learned those particulars of the crime which came
25148  out in the police investigation, but a good deal was suppressed upon that
25149  occasion, since the case for the prosecution was so overwhelmingly strong
25150  that it was not necessary to bring forward all the facts.
25151  Only now, at the end of nearly ten years, am I allowed to supply those
25152  missing links which make up the whole of that remarkable chain.
25153  The crime was of interest in itself, but that interest was as nothing to
25154  me compared to the inconceivable sequel, which afforded me the greatest
25155  shock and surprise of any event in my adventurous life.
25156  Even now, after this long interval, I find myself thrilling as I think
25157  of it, and feeling once more that sudden flood of joy, amazement, and increduli
25158 ty which utterly submerged my mind.
25159  Let me say to that public, which has shown some interest in those glimpses
25160  which I have occasionally given them of the thoughts and actions of a very
25161  remarkable man, that they are not to blame me if I have not shared my knowledge
25162  with them, for I should have considered it my first duty to do so, had
25163  I not been barred by a positive prohibition from his own lips, which was
25164  only withdrawn upon the third of last month.
25165 \end_layout
25166
25167 \end_inset
25168
25169
25170 \end_layout
25171
25172 \begin_layout Standard
25173 To get 3 or more columns, set the cursor into the multicolumn inset and
25174  use the menu 
25175 \family sans
25176 Insert\SpecialChar menuseparator
25177 Number
25178 \begin_inset space ~
25179 \end_inset
25180
25181 of
25182 \begin_inset space ~
25183 \end_inset
25184
25185 Columns
25186 \family default
25187 .
25188  The number of the desired columns is written into that inset (for 3
25189 \begin_inset space ~
25190 \end_inset
25191
25192 columns write 
25193 \begin_inset Quotes eld
25194 \end_inset
25195
25196 3
25197 \begin_inset Quotes erd
25198 \end_inset
25199
25200 ).
25201 \begin_inset Newline newline
25202 \end_inset
25203
25204 Here is an example with 3
25205 \begin_inset space ~
25206 \end_inset
25207
25208 columns:
25209 \end_layout
25210
25211 \begin_layout Standard
25212 \begin_inset Flex Multiple Columns
25213 status open
25214
25215 \begin_layout Plain Layout
25216
25217 \size footnotesize
25218 \begin_inset Argument 1
25219 status open
25220
25221 \begin_layout Plain Layout
25222 3
25223 \end_layout
25224
25225 \end_inset
25226
25227 It can be imagined that my close intimacy with Sherlock Holmes had interested
25228  me deeply in crime, and that after his disappearance I never failed to
25229  read with care the various problems which came before the public.
25230  And I even attempted, more than once, for my own private satisfaction,
25231  to employ his methods in their solution, though with indifferent success.
25232  There was none, however, which appealed to me like this tragedy of Ronald
25233  Adair.
25234  As I read the evidence at the inquest, which led up to a verdict of willful
25235  murder against some person or persons unknown, I realized more clearly
25236  than I had ever done the loss which the community had sustained by the
25237  death of Sherlock Holmes.
25238  There were points about this strange business which would, I was sure,
25239  have specially appealed to him, and the efforts of the police would have
25240  been supplemented, or more probably anticipated, by the trained observation
25241  and the alert mind of the first criminal agent in Europe.
25242  All day, as I drove upon my round, I turned over the case in my mind and
25243  found no explanation which appeared to me to be adequate.
25244  At the risk of telling a twice-told tale, I will recapitulate the facts
25245  as they were known to the public at the conclusion of the inquest.
25246 \end_layout
25247
25248 \end_inset
25249
25250
25251 \end_layout
25252
25253 \begin_layout Standard
25254 You can have up to 10
25255 \begin_inset space ~
25256 \end_inset
25257
25258 columns if you want to, but that might not be very pleasant for the readers
25259  of your document.
25260 \end_layout
25261
25262 \begin_layout Standard
25263 \begin_inset Newpage newpage
25264 \end_inset
25265
25266
25267 \end_layout
25268
25269 \begin_layout Subsection
25270 Columns inside Columns
25271 \end_layout
25272
25273 \begin_layout Standard
25274 You can also have columns inside columns:
25275 \end_layout
25276
25277 \begin_layout Standard
25278 \begin_inset Flex Multiple Columns
25279 status open
25280
25281 \begin_layout Plain Layout
25282
25283 \size footnotesize
25284 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
25285  at that time governor of one of the Australian colonies.
25286  Adair's mother had returned from Australia to undergo the operation for
25287  cataract, and she, her son Ronald, and her daughter Hilda were living together
25288  at 427 Park Lane.
25289 \end_layout
25290
25291 \begin_layout Plain Layout
25292 \begin_inset Flex Multiple Columns
25293 status open
25294
25295 \begin_layout Plain Layout
25296
25297 \size footnotesize
25298 The youth moved in the best society–had, so far as was known, no enemies
25299  and no particular vices.
25300  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
25301  had been broken off by mutual consent some months before, and there was
25302  no sign that it had left any very profound feeling behind it.
25303  For the rest {sic} the man's life moved in a narrow and conventional circle,
25304  for his habits were quiet and his nature unemotional.
25305  Yet it was upon this easy-going young aristocrat that death came, in most
25306  strange and unexpected form, between the hours of ten and eleven-twenty
25307  on the night of March 30, 1894.
25308 \end_layout
25309
25310 \end_inset
25311
25312
25313 \end_layout
25314
25315 \begin_layout Plain Layout
25316
25317 \size footnotesize
25318 Ronald Adair was fond of cards–playing continually, but never for such stakes
25319  as would hurt him.
25320  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
25321  It was shown that, after dinner on the day of his death, he had played
25322  a rubber of whist at the latter club.
25323  He had also played there in the afternoon.
25324
25325 \size default
25326  
25327 \size footnotesize
25328 The evidence of those who had played with him– Mr.
25329  Murray, Sir John Hardy, and Colonel Moran–showed that the game was whist,
25330  and that there was a fairly equal fall of the cards.
25331  Adair might have lost five pounds, but not more.
25332  His fortune was a considerable one, and such a loss could not in any way
25333  affect him.
25334  He had played nearly every day at one club or other, but he was a cautious
25335  player, and usually rose a winner.
25336  It came out in evidence that, in partnership with Colonel Moran, he had
25337  actually won as much as four hundred and twenty pounds in a sitting, some
25338  weeks before, from Godfrey Milner and Lord Balmoral.
25339  So much for his recent history as it came out at the inquest.
25340 \end_layout
25341
25342 \end_inset
25343
25344
25345 \end_layout
25346
25347 \begin_layout Subsection
25348 Advanced Examples
25349 \end_layout
25350
25351 \begin_layout Standard
25352 The examples in this section show some more special features of multiple
25353  columns.
25354 \end_layout
25355
25356 \begin_layout Standard
25357 For more features of multiple columns, have a look at the documentation
25358  of the \SpecialChar LaTeX
25359 -package 
25360 \series bold
25361 multicol
25362 \series default
25363
25364 \begin_inset CommandInset citation
25365 LatexCommand cite
25366 key "multicol"
25367 literal "true"
25368
25369 \end_inset
25370
25371 .
25372 \end_layout
25373
25374 \begin_layout Subsubsection
25375 Preface
25376 \end_layout
25377
25378 \begin_layout Standard
25379 To add a preface text for multiple columns, set the cursor into the multicolumn
25380  inset and use the menu 
25381 \family sans
25382 Insert\SpecialChar menuseparator
25383 Preface
25384 \family default
25385 .
25386  Write your preface text into that inset.
25387 \begin_inset Newline newline
25388 \end_inset
25389
25390 This is an example with some preface text:
25391 \end_layout
25392
25393 \begin_layout Standard
25394 \begin_inset VSpace bigskip
25395 \end_inset
25396
25397
25398 \end_layout
25399
25400 \begin_layout Standard
25401 \begin_inset Flex Multiple Columns
25402 status open
25403
25404 \begin_layout Plain Layout
25405 \begin_inset Argument 2
25406 status open
25407
25408 \begin_layout Plain Layout
25409 And the story continues and continues and continues and continues\SpecialChar ldots
25410
25411 \end_layout
25412
25413 \end_inset
25414
25415
25416 \size small
25417 On the evening of the crime, he returned from the club exactly at ten.
25418  His mother and sister were out spending the evening with a relation.
25419  The servant deposed that she heard him enter the front room on the second
25420  floor, generally used as his sitting-room.
25421  She had lit a fire there, and as it smoked she had opened the window.
25422  No sound was heard from the room until eleven-twenty, the hour of the return
25423  of Lady Maynooth and her daughter.
25424  Desiring to say good-night, she attempted to enter her son's room.
25425  The door was locked on the inside, and no answer could be got to their
25426  cries and knocking.
25427  Help was obtained, and the door forced.
25428  The unfortunate young man was found lying near the table.
25429  His head had been horribly mutilated by an expanding revolver bullet, but
25430  no weapon of any sort was to be found in the room.
25431 \end_layout
25432
25433 \end_inset
25434
25435
25436 \end_layout
25437
25438 \begin_layout Standard
25439 You can also use a section heading as the preface if you use a section command
25440  as \SpecialChar TeX
25441  Code.
25442  For example the command
25443 \end_layout
25444
25445 \begin_layout Standard
25446
25447 \series bold
25448
25449 \backslash
25450 subsection{subsection title}
25451 \end_layout
25452
25453 \begin_layout Standard
25454 creates a subsection.
25455  In this example the preface is a subsubsection:
25456 \end_layout
25457
25458 \begin_layout Standard
25459 \begin_inset Flex Multiple Columns
25460 status open
25461
25462 \begin_layout Plain Layout
25463 \begin_inset Argument 2
25464 status open
25465
25466 \begin_layout Plain Layout
25467 \begin_inset ERT
25468 status collapsed
25469
25470 \begin_layout Plain Layout
25471
25472
25473 \backslash
25474 subsubsection{
25475 \end_layout
25476
25477 \end_inset
25478
25479 This is a subsubsection heading as a preface
25480 \begin_inset ERT
25481 status collapsed
25482
25483 \begin_layout Plain Layout
25484
25485 }
25486 \end_layout
25487
25488 \end_inset
25489
25490
25491 \end_layout
25492
25493 \end_inset
25494
25495
25496 \size small
25497 A minute examination of the circumstances served only to make the case more
25498  complex.
25499  In the first place, no reason could be given why the young man should have
25500  fastened the door upon the inside.
25501  There was the possibility that the murderer had done this, and had afterwards
25502  escaped by the window.
25503  The drop was at least twenty feet, however, and a bed of crocuses in full
25504  bloom lay beneath.
25505  Neither the flowers nor the earth showed any sign of having been disturbed,
25506  nor were there any marks upon the narrow strip of grass which separated
25507  the house from the road.
25508  Apparently, therefore, it was the young man himself who had fastened the
25509  door.
25510  But how did he come by his death? No one could have climbed up to the window
25511  without leaving traces.
25512  Suppose a man had fired through the window, he would indeed be a remarkable
25513  shot who could with a revolver inflict so deadly a wound.
25514  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
25515  a hundred yards of the house.
25516  No one had heard a shot.
25517 \end_layout
25518
25519 \end_inset
25520
25521
25522 \end_layout
25523
25524 \begin_layout Standard
25525 If there is less vertical space than 6
25526 \begin_inset space ~
25527 \end_inset
25528
25529 text lines is left on the page at the beginning of the multiple columns,
25530  a page break will be inserted before the multiple columns.
25531  Depending on the number of lines of the preface text, you might want to
25532  change this space.
25533  This is done by setting the cursor into the mulitcolumn inset behind the
25534  preface (if there is any) and using the menu 
25535 \family sans
25536 Insert\SpecialChar menuseparator
25537 Space
25538 \begin_inset space ~
25539 \end_inset
25540
25541 Before
25542 \begin_inset space ~
25543 \end_inset
25544
25545 Page
25546 \begin_inset space ~
25547 \end_inset
25548
25549 Break
25550 \family default
25551 .
25552  Insert into that inset the amount of space like e.
25553 \begin_inset space \thinspace{}
25554 \end_inset
25555
25556 g.
25557 \begin_inset space \space{}
25558 \end_inset
25559
25560
25561 \begin_inset Quotes eld
25562 \end_inset
25563
25564 5cm
25565 \begin_inset Quotes erd
25566 \end_inset
25567
25568 .
25569 \begin_inset Newline newline
25570 \end_inset
25571
25572 In this example the space is set to 7
25573 \begin_inset space ~
25574 \end_inset
25575
25576 text lines by using 
25577 \begin_inset Quotes eld
25578 \end_inset
25579
25580 7
25581 \backslash
25582 baselineskip
25583 \begin_inset Quotes erd
25584 \end_inset
25585
25586  (where the command 
25587 \series bold
25588
25589 \backslash
25590 baselineskip
25591 \series default
25592  needs to be inserted as \SpecialChar TeX
25593  code):
25594 \end_layout
25595
25596 \begin_layout Standard
25597 \begin_inset Flex Multiple Columns
25598 status open
25599
25600 \begin_layout Plain Layout
25601 \begin_inset Argument 3
25602 status open
25603
25604 \begin_layout Plain Layout
25605 7
25606 \begin_inset ERT
25607 status collapsed
25608
25609 \begin_layout Plain Layout
25610
25611
25612 \backslash
25613 baselineskip
25614 \end_layout
25615
25616 \end_inset
25617
25618
25619 \end_layout
25620
25621 \end_inset
25622
25623
25624 \size small
25625 On the evening of the crime, he returned from the club exactly at ten.
25626  His mother and sister were out spending the evening with a relation.
25627  The servant deposed that she heard him enter the front room on the second
25628  floor, generally used as his sitting-room.
25629  She had lit a fire there, and as it smoked she had opened the window.
25630  No sound was heard from the room until eleven-twenty, the hour of the return
25631  of Lady Maynooth and her daughter.
25632  Desiring to say good-night, she attempted to enter her son's room.
25633  The door was locked on the inside, and no answer could be got to their
25634  cries and knocking.
25635  Help was obtained, and the door forced.
25636  The unfortunate young man was found lying near the table.
25637  His head had been horribly mutilated by an expanding revolver bullet, but
25638  no weapon of any sort was to be found in the room.
25639 \end_layout
25640
25641 \end_inset
25642
25643
25644 \end_layout
25645
25646 \begin_layout Subsubsection
25647 Surrounding Space
25648 \end_layout
25649
25650 \begin_layout Standard
25651 The amount of space before and after multiple columns can be changed by
25652  changing the length 
25653 \series bold
25654
25655 \backslash
25656 multicolsep
25657 \series default
25658 .
25659  For example the command
25660 \end_layout
25661
25662 \begin_layout Standard
25663
25664 \series bold
25665
25666 \backslash
25667 setlength{
25668 \backslash
25669 multicolsep}{3cm}
25670 \end_layout
25671
25672 \begin_layout Standard
25673 in \SpecialChar TeX
25674  Code changes its value to 3
25675 \begin_inset space \thinspace{}
25676 \end_inset
25677
25678 cm.
25679  The change must be made before the multiple columns' start.
25680  The predefined value is 13
25681 \begin_inset space \thinspace{}
25682 \end_inset
25683
25684 pt.
25685 \end_layout
25686
25687 \begin_layout Standard
25688 For this example 
25689 \series bold
25690
25691 \backslash
25692 multicolsep
25693 \series default
25694  was set to 2.5
25695 \begin_inset space \thinspace{}
25696 \end_inset
25697
25698 cm:
25699 \end_layout
25700
25701 \begin_layout Standard
25702 \begin_inset ERT
25703 status open
25704
25705 \begin_layout Plain Layout
25706
25707
25708 \backslash
25709 setlength{
25710 \backslash
25711 multicolsep}{2.5cm}
25712 \end_layout
25713
25714 \end_inset
25715
25716
25717 \end_layout
25718
25719 \begin_layout Standard
25720 \begin_inset Flex Multiple Columns
25721 status open
25722
25723 \begin_layout Plain Layout
25724
25725 \size small
25726 All day I turned these facts over in my mind, endeavouring to hit upon some
25727  theory which could reconcile them all, and to find that line of least resistanc
25728 e which my poor friend had declared to be the starting-point of every investigat
25729 ion.
25730  I confess that I made little progress.
25731  In the evening I strolled across the Park, and found myself about six o'clock
25732  at the Oxford Street end of Park Lane.
25733  A group of loafers upon the pavements, all staring up at a particular window,
25734  directed me to the house which I had come to see.
25735  A tall, thin man with coloured glasses, whom I strongly suspected of being
25736  a plain-clothes detective, was pointing out some theory of his own, while
25737  the others crowded round to listen to what he said.
25738  I got as near him as I could, but his observations seemed to me to be absurd,
25739  so I withdrew again in some disgust.
25740  As I did so I struck against an elderly, deformed man, who had been behind
25741  me, and I knocked down several books which he was carrying.
25742 \end_layout
25743
25744 \end_inset
25745
25746
25747 \end_layout
25748
25749 \begin_layout Standard
25750 \begin_inset Note Greyedout
25751 status open
25752
25753 \begin_layout Plain Layout
25754
25755 \series bold
25756 Note:
25757 \series default
25758  The values you set with 
25759 \series bold
25760
25761 \backslash
25762 setlength
25763 \series default
25764  will be used for all following multiple columns until you change them again.
25765 \end_layout
25766
25767 \end_inset
25768
25769
25770 \end_layout
25771
25772 \begin_layout Standard
25773 \begin_inset ERT
25774 status collapsed
25775
25776 \begin_layout Plain Layout
25777
25778
25779 \backslash
25780 setlength{
25781 \backslash
25782 multicolsep}{13pt}
25783 \end_layout
25784
25785 \end_inset
25786
25787
25788 \begin_inset Note Note
25789 status collapsed
25790
25791 \begin_layout Plain Layout
25792 go back to the default
25793 \end_layout
25794
25795 \end_inset
25796
25797
25798 \end_layout
25799
25800 \begin_layout Standard
25801 \begin_inset Newpage newpage
25802 \end_inset
25803
25804
25805 \end_layout
25806
25807 \begin_layout Subsubsection
25808 Column Breaks
25809 \end_layout
25810
25811 \begin_layout Standard
25812 A column break can be forced by inserting the command 
25813 \series bold
25814
25815 \backslash
25816 columnbreak{}
25817 \series default
25818  as \SpecialChar TeX
25819  Code to that position in the text where the column should be broken.
25820  Note that this leads in most cases to whitespace in the text.
25821 \begin_inset Newline newline
25822 \end_inset
25823
25824 Here is an example:
25825 \end_layout
25826
25827 \begin_layout Standard
25828 \begin_inset Flex Multiple Columns
25829 status open
25830
25831 \begin_layout Plain Layout
25832
25833 \size small
25834 \begin_inset Quotes eld
25835 \end_inset
25836
25837 You're surprised to see me, sir,
25838 \begin_inset Quotes erd
25839 \end_inset
25840
25841  said he, in a strange, croaking voice.
25842 \end_layout
25843
25844 \begin_layout Plain Layout
25845
25846 \size small
25847 I acknowledged that I was.
25848 \end_layout
25849
25850 \begin_layout Plain Layout
25851
25852 \size small
25853 \begin_inset Quotes eld
25854 \end_inset
25855
25856 Well, I've a conscience, sir, and when I chanced to see you go into this
25857  house, as I came hobbling after you, I thought to myself, I'll just step
25858  in and see that kind gentleman, and tell him that if I was a bit gruff
25859  in my manner there was not any harm meant, and that I am much obliged to
25860  him for picking up my books.
25861 \begin_inset Quotes erd
25862 \end_inset
25863
25864
25865 \end_layout
25866
25867 \begin_layout Plain Layout
25868
25869 \size small
25870 \begin_inset Quotes eld
25871 \end_inset
25872
25873 You make too much of a trifle,
25874 \begin_inset Quotes erd
25875 \end_inset
25876
25877  said I.
25878  
25879 \begin_inset Quotes eld
25880 \end_inset
25881
25882 May I ask how you knew who I was?
25883 \begin_inset Quotes erd
25884 \end_inset
25885
25886  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
25887 \begin_inset ERT
25888 status collapsed
25889
25890 \begin_layout Plain Layout
25891
25892
25893 \backslash
25894 columnbreak{}
25895 \end_layout
25896
25897 \end_inset
25898
25899
25900 \end_layout
25901
25902 \begin_layout Plain Layout
25903
25904 \size small
25905 \begin_inset Quotes eld
25906 \end_inset
25907
25908 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25909  you'll find my little bookshop at the corner of Church Street, and very
25910  happy to see you, I am sure.
25911  Maybe you collect yourself, sir.
25912  Here's 
25913 \noun on
25914 British
25915 \begin_inset space ~
25916 \end_inset
25917
25918 Birds
25919 \noun default
25920 , and 
25921 \noun on
25922 Catullus
25923 \noun default
25924 , and 
25925 \noun on
25926 The Holy War
25927 \noun default
25928 –a bargain, every one of them.
25929  With five volumes you could just fill that gap on that second shelf.
25930  It looks untidy, does it not, sir?
25931 \begin_inset Quotes erd
25932 \end_inset
25933
25934
25935 \end_layout
25936
25937 \end_inset
25938
25939
25940 \end_layout
25941
25942 \begin_layout Subsubsection
25943 Column Separation
25944 \end_layout
25945
25946 \begin_layout Standard
25947 The width of the columns is automatically calculated, but you can modify
25948  the space between the columns.
25949  This is done by changing the length 
25950 \series bold
25951
25952 \backslash
25953 columnsep
25954 \series default
25955 .
25956  Its predefined value is 10
25957 \begin_inset space \thinspace{}
25958 \end_inset
25959
25960 pt.
25961  Here is an example where 
25962 \series bold
25963
25964 \backslash
25965 columnsep
25966 \series default
25967  is set to 3
25968 \begin_inset space \thinspace{}
25969 \end_inset
25970
25971 cm:
25972 \end_layout
25973
25974 \begin_layout Standard
25975 \begin_inset ERT
25976 status open
25977
25978 \begin_layout Plain Layout
25979
25980
25981 \backslash
25982 setlength{
25983 \backslash
25984 columnsep}{3cm}
25985 \end_layout
25986
25987 \end_inset
25988
25989
25990 \end_layout
25991
25992 \begin_layout Standard
25993 \begin_inset Flex Multiple Columns
25994 status open
25995
25996 \begin_layout Plain Layout
25997
25998 \size small
25999 My observations of No.
26000 \begin_inset space \space{}
26001 \end_inset
26002
26003 427 Park Lane did little to clear up the problem in which I was interested.
26004  The house was separated from the street by a low wall and railing, the
26005  whole not more than five feet high.
26006  It was perfectly easy, therefore, for anyone to get into the garden, but
26007  the window was entirely inaccessible, since there was no water pipe or
26008  anything which could help the most active man to climb it.
26009  More puzzled than ever, I retraced my steps to Kensington.
26010  I had not been in my study five minutes when the maid entered to say that
26011  a person desired to see me.
26012  To my astonishment it was none other than my strange old book collector,
26013  his sharp, wizened face peering out from a frame of white hair, and his
26014  precious volumes, a dozen of them at least, wedged under his right arm.
26015 \end_layout
26016
26017 \end_inset
26018
26019
26020 \end_layout
26021
26022 \begin_layout Standard
26023 \begin_inset ERT
26024 status collapsed
26025
26026 \begin_layout Plain Layout
26027
26028
26029 \backslash
26030 setlength{
26031 \backslash
26032 columnsep}{10pt}
26033 \end_layout
26034
26035 \end_inset
26036
26037
26038 \begin_inset Note Note
26039 status collapsed
26040
26041 \begin_layout Plain Layout
26042 go back to the default
26043 \end_layout
26044
26045 \end_inset
26046
26047
26048 \end_layout
26049
26050 \begin_layout Subsubsection
26051 Vertical Lines
26052 \end_layout
26053
26054 \begin_layout Standard
26055 Between the columns a rule with a width of the length 
26056 \series bold
26057
26058 \backslash
26059 columnseprule
26060 \series default
26061  is placed.
26062  If this rule width is set to 0
26063 \begin_inset space \thinspace{}
26064 \end_inset
26065
26066 pt (this is the default), the rule is suppressed.
26067  In the following example the rule is 2
26068 \begin_inset space \thinspace{}
26069 \end_inset
26070
26071 pt wide:
26072 \end_layout
26073
26074 \begin_layout Standard
26075 \begin_inset ERT
26076 status open
26077
26078 \begin_layout Plain Layout
26079
26080
26081 \backslash
26082 setlength{
26083 \backslash
26084 columnseprule}{2pt}
26085 \end_layout
26086
26087 \end_inset
26088
26089
26090 \end_layout
26091
26092 \begin_layout Standard
26093 \begin_inset Flex Multiple Columns
26094 status open
26095
26096 \begin_layout Plain Layout
26097
26098 \size small
26099 \begin_inset Quotes eld
26100 \end_inset
26101
26102 You're surprised to see me, sir,
26103 \begin_inset Quotes erd
26104 \end_inset
26105
26106  said he, in a strange, croaking voice.
26107 \end_layout
26108
26109 \begin_layout Plain Layout
26110
26111 \size small
26112 I acknowledged that I was.
26113 \end_layout
26114
26115 \begin_layout Plain Layout
26116
26117 \size small
26118 \begin_inset Quotes eld
26119 \end_inset
26120
26121 Well, I've a conscience, sir, and when I chanced to see you go into this
26122  house, as I came hobbling after you, I thought to myself, I'll just step
26123  in and see that kind gentleman, and tell him that if I was a bit gruff
26124  in my manner there was not any harm meant, and that I am much obliged to
26125  him for picking up my books.
26126 \begin_inset Quotes erd
26127 \end_inset
26128
26129
26130 \end_layout
26131
26132 \begin_layout Plain Layout
26133
26134 \size small
26135 \begin_inset Quotes eld
26136 \end_inset
26137
26138 You make too much of a trifle,
26139 \begin_inset Quotes erd
26140 \end_inset
26141
26142  said I.
26143  
26144 \begin_inset Quotes eld
26145 \end_inset
26146
26147 May I ask how you knew who I was?
26148 \begin_inset Quotes erd
26149 \end_inset
26150
26151
26152 \end_layout
26153
26154 \begin_layout Plain Layout
26155
26156 \size small
26157 \begin_inset Quotes eld
26158 \end_inset
26159
26160 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
26161  you'll find my little bookshop at the corner of Church Street, and very
26162  happy to see you, I am sure.
26163  Maybe you collect yourself, sir.
26164  Here's 
26165 \noun on
26166 British
26167 \begin_inset space ~
26168 \end_inset
26169
26170 Birds
26171 \noun default
26172 , and 
26173 \noun on
26174 Catullus
26175 \noun default
26176 , and 
26177 \noun on
26178 The Holy War
26179 \noun default
26180 –a bargain, every one of them.
26181  With five volumes you could just fill that gap on that second shelf.
26182  It looks untidy, does it not, sir?
26183 \begin_inset Quotes erd
26184 \end_inset
26185
26186
26187 \end_layout
26188
26189 \end_inset
26190
26191
26192 \end_layout
26193
26194 \begin_layout Standard
26195 \begin_inset VSpace defskip
26196 \end_inset
26197
26198
26199 \end_layout
26200
26201 \begin_layout Standard
26202 The rule can be colored by redefining the command 
26203 \series bold
26204
26205 \backslash
26206 columnseprulecolor
26207 \series default
26208 .
26209  This is done by inserting the command
26210 \begin_inset Newline newline
26211 \end_inset
26212
26213
26214 \series bold
26215
26216 \backslash
26217 renewcommand{
26218 \backslash
26219 columnseprulecolor}{
26220 \backslash
26221 color{red}}
26222 \series default
26223
26224 \begin_inset Newline newline
26225 \end_inset
26226
26227 as \SpecialChar TeX
26228  Code before the multicolumn inset.
26229  Replace 
26230 \series bold
26231 red
26232 \series default
26233  in this command by a color of your choice.
26234  You can use all pre- and self-defined colors.
26235  See the 
26236 \emph on
26237 EmbeddedObjects
26238 \emph default
26239  manual, section 
26240 \emph on
26241 Colored
26242 \begin_inset space ~
26243 \end_inset
26244
26245 Tables
26246 \emph default
26247  for more information about pre- and self-defined colors.
26248  To go back to the default color insert the command
26249 \begin_inset Newline newline
26250 \end_inset
26251
26252
26253 \series bold
26254
26255 \backslash
26256 renewcommand{
26257 \backslash
26258 columnseprulecolor}{
26259 \backslash
26260 normalcolor}
26261 \series default
26262
26263 \begin_inset Newline newline
26264 \end_inset
26265
26266 Here is the example with a cyan rule and 1
26267 \begin_inset space \thinspace{}
26268 \end_inset
26269
26270 cm column separation:
26271 \end_layout
26272
26273 \begin_layout Standard
26274 \begin_inset ERT
26275 status open
26276
26277 \begin_layout Plain Layout
26278
26279
26280 \backslash
26281 setlength{
26282 \backslash
26283 columnsep}{1cm}
26284 \end_layout
26285
26286 \begin_layout Plain Layout
26287
26288
26289 \backslash
26290 renewcommand{
26291 \backslash
26292 columnseprulecolor}{
26293 \backslash
26294 color{cyan}}
26295 \end_layout
26296
26297 \end_inset
26298
26299
26300 \end_layout
26301
26302 \begin_layout Standard
26303 \begin_inset Flex Multiple Columns
26304 status open
26305
26306 \begin_layout Plain Layout
26307
26308 \size small
26309 \begin_inset Quotes eld
26310 \end_inset
26311
26312 You're surprised to see me, sir,
26313 \begin_inset Quotes erd
26314 \end_inset
26315
26316  said he, in a strange, croaking voice.
26317 \end_layout
26318
26319 \begin_layout Plain Layout
26320
26321 \size small
26322 I acknowledged that I was.
26323 \end_layout
26324
26325 \begin_layout Plain Layout
26326
26327 \size small
26328 \begin_inset Quotes eld
26329 \end_inset
26330
26331 Well, I've a conscience, sir, and when I chanced to see you go into this
26332  house, as I came hobbling after you, I thought to myself, I'll just step
26333  in and see that kind gentleman, and tell him that if I was a bit gruff
26334  in my manner there was not any harm meant, and that I am much obliged to
26335  him for picking up my books.
26336 \begin_inset Quotes erd
26337 \end_inset
26338
26339
26340 \end_layout
26341
26342 \begin_layout Plain Layout
26343
26344 \size small
26345 \begin_inset Quotes eld
26346 \end_inset
26347
26348 You make too much of a trifle,
26349 \begin_inset Quotes erd
26350 \end_inset
26351
26352  said I.
26353  
26354 \begin_inset Quotes eld
26355 \end_inset
26356
26357 May I ask how you knew who I was?
26358 \begin_inset Quotes erd
26359 \end_inset
26360
26361
26362 \end_layout
26363
26364 \begin_layout Plain Layout
26365
26366 \size small
26367 \begin_inset Quotes eld
26368 \end_inset
26369
26370 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
26371  you'll find my little bookshop at the corner of Church Street, and very
26372  happy to see you, I am sure.
26373  Maybe you collect yourself, sir.
26374  Here's 
26375 \noun on
26376 British
26377 \begin_inset space ~
26378 \end_inset
26379
26380 Birds
26381 \noun default
26382 , and 
26383 \noun on
26384 Catullus
26385 \noun default
26386 , and 
26387 \noun on
26388 The Holy War
26389 \noun default
26390 –a bargain, every one of them.
26391  With five volumes you could just fill that gap on that second shelf.
26392  It looks untidy, does it not, sir?
26393 \begin_inset Quotes erd
26394 \end_inset
26395
26396
26397 \end_layout
26398
26399 \end_inset
26400
26401
26402 \end_layout
26403
26404 \begin_layout Standard
26405 \begin_inset ERT
26406 status collapsed
26407
26408 \begin_layout Plain Layout
26409
26410
26411 \backslash
26412 setlength{
26413 \backslash
26414 columnseprule}{0pt}
26415 \end_layout
26416
26417 \begin_layout Plain Layout
26418
26419
26420 \backslash
26421 renewcommand{
26422 \backslash
26423 columnseprulecolor}{
26424 \backslash
26425 normalcolor}
26426 \end_layout
26427
26428 \end_inset
26429
26430
26431 \begin_inset Note Note
26432 status collapsed
26433
26434 \begin_layout Plain Layout
26435 go back to the default
26436 \end_layout
26437
26438 \end_inset
26439
26440
26441 \end_layout
26442
26443 \begin_layout Section
26444 Non-standard Paragraph Shapes
26445 \end_layout
26446
26447 \begin_layout Standard
26448 \noindent
26449 \SpecialChar LaTeX
26450  as well as any other text processor uses by default rectangular paragraphs.
26451  For special cases like for example posters, invitation cards or poems you
26452  can modify the paragraph shape to one of your choice.
26453  This can be done by using the \SpecialChar LaTeX
26454 -package 
26455 \series bold
26456 shapepar
26457 \series default
26458  which is loaded by using in the document settings the module 
26459 \family sans
26460 Custom paragraph shapes
26461 \family default
26462 .
26463 \end_layout
26464
26465 \begin_layout Subsection
26466 Predefined shapes
26467 \end_layout
26468
26469 \begin_layout Standard
26470
26471 \series bold
26472 shapepar
26473 \series default
26474  provides the following shapes:
26475 \end_layout
26476
26477 \begin_layout Standard
26478 \begin_inset Tabular
26479 <lyxtabular version="3" rows="13" columns="3">
26480 <features booktabs="true" islongtable="true" longtabularalignment="center">
26481 <column alignment="center" valignment="middle" width="16col%">
26482 <column alignment="center" valignment="middle" width="40col%">
26483 <column alignment="center" valignment="middle" width="35col%">
26484 <row endhead="true">
26485 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26486 \begin_inset Text
26487
26488 \begin_layout Plain Layout
26489 Name
26490 \end_layout
26491
26492 \end_inset
26493 </cell>
26494 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26495 \begin_inset Text
26496
26497 \begin_layout Plain Layout
26498 Description
26499 \end_layout
26500
26501 \end_inset
26502 </cell>
26503 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26504 \begin_inset Text
26505
26506 \begin_layout Plain Layout
26507 Annotation
26508 \end_layout
26509
26510 \end_inset
26511 </cell>
26512 </row>
26513 <row>
26514 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26515 \begin_inset Text
26516
26517 \begin_layout Plain Layout
26518 CDlabel
26519 \end_layout
26520
26521 \end_inset
26522 </cell>
26523 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26524 \begin_inset Text
26525
26526 \begin_layout Plain Layout
26527 Circle with circular hole (in the size of a CD/DVD)
26528 \end_layout
26529
26530 \end_inset
26531 </cell>
26532 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26533 \begin_inset Text
26534
26535 \begin_layout Plain Layout
26536 Cannot be scaled, take care there is not too much text
26537 \end_layout
26538
26539 \end_inset
26540 </cell>
26541 </row>
26542 <row>
26543 <cell alignment="center" valignment="top" topline="true" usebox="none">
26544 \begin_inset Text
26545
26546 \begin_layout Plain Layout
26547 Circle
26548 \end_layout
26549
26550 \end_inset
26551 </cell>
26552 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26553 \begin_inset Text
26554
26555 \begin_layout Plain Layout
26556 Circle
26557 \end_layout
26558
26559 \end_inset
26560 </cell>
26561 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26562 \begin_inset Text
26563
26564 \begin_layout Plain Layout
26565 Fragile, calculation might fail
26566 \end_layout
26567
26568 \end_inset
26569 </cell>
26570 </row>
26571 <row>
26572 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26573 \begin_inset Text
26574
26575 \begin_layout Plain Layout
26576 Diamond
26577 \end_layout
26578
26579 \end_inset
26580 </cell>
26581 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26582 \begin_inset Text
26583
26584 \begin_layout Plain Layout
26585 Rhomboid (symbolizing a 
26586 \begin_inset Quotes eld
26587 \end_inset
26588
26589 diamond
26590 \begin_inset Quotes erd
26591 \end_inset
26592
26593 )
26594 \end_layout
26595
26596 \end_inset
26597 </cell>
26598 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26599 \begin_inset Text
26600
26601 \begin_layout Plain Layout
26602 -
26603 \end_layout
26604
26605 \end_inset
26606 </cell>
26607 </row>
26608 <row>
26609 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26610 \begin_inset Text
26611
26612 \begin_layout Plain Layout
26613 Heart
26614 \end_layout
26615
26616 \end_inset
26617 </cell>
26618 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26619 \begin_inset Text
26620
26621 \begin_layout Plain Layout
26622 Heart-like shape
26623 \end_layout
26624
26625 \end_inset
26626 </cell>
26627 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26628 \begin_inset Text
26629
26630 \begin_layout Plain Layout
26631 -
26632 \end_layout
26633
26634 \end_inset
26635 </cell>
26636 </row>
26637 <row>
26638 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26639 \begin_inset Text
26640
26641 \begin_layout Plain Layout
26642 Hexagon
26643 \end_layout
26644
26645 \end_inset
26646 </cell>
26647 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26648 \begin_inset Text
26649
26650 \begin_layout Plain Layout
26651 Hexagon
26652 \end_layout
26653
26654 \end_inset
26655 </cell>
26656 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26657 \begin_inset Text
26658
26659 \begin_layout Plain Layout
26660 -
26661 \end_layout
26662
26663 \end_inset
26664 </cell>
26665 </row>
26666 <row>
26667 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26668 \begin_inset Text
26669
26670 \begin_layout Plain Layout
26671 Nut
26672 \end_layout
26673
26674 \end_inset
26675 </cell>
26676 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26677 \begin_inset Text
26678
26679 \begin_layout Plain Layout
26680 Nut for bolt (hexagon with circular hole)
26681 \end_layout
26682
26683 \end_inset
26684 </cell>
26685 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26686 \begin_inset Text
26687
26688 \begin_layout Plain Layout
26689 -
26690 \end_layout
26691
26692 \end_inset
26693 </cell>
26694 </row>
26695 <row>
26696 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26697 \begin_inset Text
26698
26699 \begin_layout Plain Layout
26700 Square
26701 \end_layout
26702
26703 \end_inset
26704 </cell>
26705 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26706 \begin_inset Text
26707
26708 \begin_layout Plain Layout
26709 Square
26710 \end_layout
26711
26712 \end_inset
26713 </cell>
26714 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26715 \begin_inset Text
26716
26717 \begin_layout Plain Layout
26718 -
26719 \end_layout
26720
26721 \end_inset
26722 </cell>
26723 </row>
26724 <row>
26725 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26726 \begin_inset Text
26727
26728 \begin_layout Plain Layout
26729 Star
26730 \end_layout
26731
26732 \end_inset
26733 </cell>
26734 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26735 \begin_inset Text
26736
26737 \begin_layout Plain Layout
26738 Five-point star
26739 \end_layout
26740
26741 \end_inset
26742 </cell>
26743 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26744 \begin_inset Text
26745
26746 \begin_layout Plain Layout
26747 -
26748 \end_layout
26749
26750 \end_inset
26751 </cell>
26752 </row>
26753 <row>
26754 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26755 \begin_inset Text
26756
26757 \begin_layout Plain Layout
26758 Candle
26759 \end_layout
26760
26761 \end_inset
26762 </cell>
26763 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26764 \begin_inset Text
26765
26766 \begin_layout Plain Layout
26767 Burning candle
26768 \end_layout
26769
26770 \end_inset
26771 </cell>
26772 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26773 \begin_inset Text
26774
26775 \begin_layout Plain Layout
26776 -
26777 \end_layout
26778
26779 \end_inset
26780 </cell>
26781 </row>
26782 <row>
26783 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26784 \begin_inset Text
26785
26786 \begin_layout Plain Layout
26787 Drop down/up
26788 \end_layout
26789
26790 \end_inset
26791 </cell>
26792 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26793 \begin_inset Text
26794
26795 \begin_layout Plain Layout
26796 Normal/reversed rain drop
26797 \end_layout
26798
26799 \end_inset
26800 </cell>
26801 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26802 \begin_inset Text
26803
26804 \begin_layout Plain Layout
26805 Fragile, calculation might fail
26806 \end_layout
26807
26808 \end_inset
26809 </cell>
26810 </row>
26811 <row>
26812 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26813 \begin_inset Text
26814
26815 \begin_layout Plain Layout
26816 \SpecialChar TeX
26817
26818 \end_layout
26819
26820 \end_inset
26821 </cell>
26822 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
26823 \begin_inset Text
26824
26825 \begin_layout Plain Layout
26826 The \SpecialChar TeX
26827  logo
26828 \end_layout
26829
26830 \end_inset
26831 </cell>
26832 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
26833 \begin_inset Text
26834
26835 \begin_layout Plain Layout
26836 -
26837 \end_layout
26838
26839 \end_inset
26840 </cell>
26841 </row>
26842 <row>
26843 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26844 \begin_inset Text
26845
26846 \begin_layout Plain Layout
26847 Triangle up/down/
26848 \begin_inset Newline newline
26849 \end_inset
26850
26851 left/right
26852 \end_layout
26853
26854 \end_inset
26855 </cell>
26856 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26857 \begin_inset Text
26858
26859 \begin_layout Plain Layout
26860 Triangles in different orientations
26861 \end_layout
26862
26863 \end_inset
26864 </cell>
26865 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26866 \begin_inset Text
26867
26868 \begin_layout Plain Layout
26869 -
26870 \end_layout
26871
26872 \end_inset
26873 </cell>
26874 </row>
26875 </lyxtabular>
26876
26877 \end_inset
26878
26879
26880 \end_layout
26881
26882 \begin_layout Standard
26883 To use a shape for your paragraph, simply select it in \SpecialChar LyX
26884 's pull-down box
26885  for environments in the toolbar.
26886 \end_layout
26887
26888 \begin_layout Standard
26889 \begin_inset Newpage newpage
26890 \end_inset
26891
26892
26893 \end_layout
26894
26895 \begin_layout Standard
26896 Here is an example paragraph in the shape of a nut:
26897 \end_layout
26898
26899 \begin_layout Standard
26900 \begin_inset VSpace bigskip
26901 \end_inset
26902
26903
26904 \end_layout
26905
26906 \begin_layout Nut
26907
26908 \lang latin
26909 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26910  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26911  voluptua.
26912  At vero eos et accusam et justo duo dolores et ea rebum.
26913  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26914  sit amet.
26915  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26916  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26917  voluptua.
26918 \end_layout
26919
26920 \begin_layout Standard
26921 \begin_inset VSpace bigskip
26922 \end_inset
26923
26924
26925 \end_layout
26926
26927 \begin_layout Standard
26928 \begin_inset Note Greyedout
26929 status open
26930
26931 \begin_layout Plain Layout
26932
26933 \series bold
26934 Note
26935 \series default
26936 : shapepar paragraphs cannot run over a page break.
26937 \end_layout
26938
26939 \end_inset
26940
26941
26942 \end_layout
26943
26944 \begin_layout Standard
26945 \begin_inset VSpace bigskip
26946 \end_inset
26947
26948
26949 \end_layout
26950
26951 \begin_layout Standard
26952
26953 \series bold
26954 shapepar
26955 \series default
26956  takes care that the shape will always be preserved, no matter how much
26957  text is in the paragraph.
26958  Therefore the paragraph size changes with the amount of contained text.
26959  This can lead to paragraph sizes exceeding the page margins.
26960  To demonstrate the size scaling, here is the same example paragraph but
26961  with twice as much text:
26962 \end_layout
26963
26964 \begin_layout Standard
26965 \begin_inset Newpage newpage
26966 \end_inset
26967
26968
26969 \end_layout
26970
26971 \begin_layout Nut
26972
26973 \lang latin
26974 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26975  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26976  voluptua.
26977  At vero eos et accusam et justo duo dolores et ea rebum.
26978  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26979  sit amet.
26980  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26981  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26982  voluptua.
26983  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26984  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26985  voluptua.
26986  At vero eos et accusam et justo duo dolores et ea rebum.
26987  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26988  sit amet.
26989  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26990  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26991  voluptua.
26992 \end_layout
26993
26994 \begin_layout Standard
26995 \begin_inset VSpace bigskip
26996 \end_inset
26997
26998
26999 \end_layout
27000
27001 \begin_layout Standard
27002 An exception is the shape 
27003 \family sans
27004 CDlabel
27005 \family default
27006 .
27007  It cannot be scaled because it must fit the size of a CD/DVD.
27008  Therefore the amount of text that fits into the shape is limited.
27009 \begin_inset Newline newline
27010 \end_inset
27011
27012 The 
27013 \family sans
27014 drop
27015 \family default
27016  shapes and the 
27017 \family sans
27018 circle
27019 \family default
27020  shape are fragile, meaning that the calculation of their size can fail,
27021  depending on the amount of text.
27022  You will then get the \SpecialChar LaTeX
27023  error 
27024 \begin_inset Quotes eld
27025 \end_inset
27026
27027 Arithmetic overflow
27028 \begin_inset Quotes erd
27029 \end_inset
27030
27031 .
27032  In this case one can try to remove or add some text; if nothing works one
27033  has to use another shape.
27034 \end_layout
27035
27036 \begin_layout Standard
27037 \begin_inset VSpace bigskip
27038 \end_inset
27039
27040
27041 \end_layout
27042
27043 \begin_layout Standard
27044 For shapes with tips you will maybe see that \SpecialChar LaTeX
27045 's hyphenation routine fails
27046  for text in the tips.
27047  Therefore it is often necessary to add hyphenation points 
27048 \family sans
27049 (
27050 \begin_inset Info
27051 type  "shortcut"
27052 arg   "specialchar-insert hyphenation"
27053 \end_inset
27054
27055
27056 \family default
27057 ) to the corresponding text parts.
27058 \end_layout
27059
27060 \begin_layout Standard
27061 \begin_inset VSpace bigskip
27062 \end_inset
27063
27064
27065 \end_layout
27066
27067 \begin_layout Standard
27068 Shapepar paragraphs are either always centered or placed on the page so
27069  that their left border touches the left page margin.
27070  You can therefore not use the paragraph dialog to align such paragraphs.
27071  A solution is to put the paragraph into a minipage or parbox and align
27072  the box.
27073  The problem is hereby to find the right width for the box.
27074  Because if it is too wide and you center the box, the paragraph is not
27075  centered too because it sticks at the left side of the box.
27076  So you might have to play a bit with the width until it fits.
27077  Here are two heart-shaped paragraphs, the first one is not aligned, the
27078  second one is right-aligned:
27079 \end_layout
27080
27081 \begin_layout Standard
27082 \begin_inset Newpage newpage
27083 \end_inset
27084
27085
27086 \end_layout
27087
27088 \begin_layout Heart
27089 \noindent
27090
27091 \lang latin
27092 Lo\SpecialChar softhyphen
27093 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
27094  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
27095  voluptua.
27096  At vero eos et accusam et justo duo dolores et ea rebum.
27097  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
27098  sit amet.
27099 \end_layout
27100
27101 \begin_layout Standard
27102 \begin_inset VSpace bigskip
27103 \end_inset
27104
27105
27106 \end_layout
27107
27108 \begin_layout Standard
27109 \noindent
27110 \align right
27111 \begin_inset Box Frameless
27112 position "t"
27113 hor_pos "c"
27114 has_inner_box 1
27115 inner_pos "t"
27116 use_parbox 1
27117 use_makebox 0
27118 width "42col%"
27119 special "none"
27120 height "1in"
27121 height_special "totalheight"
27122 thickness "0.4pt"
27123 separation "3pt"
27124 shadowsize "4pt"
27125 framecolor "black"
27126 backgroundcolor "none"
27127 status open
27128
27129 \begin_layout Heart
27130 \noindent
27131
27132 \lang latin
27133 Lo\SpecialChar softhyphen
27134 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
27135  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
27136  voluptua.
27137  At vero eos et accusam et justo duo dolores et ea rebum.
27138  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
27139  sit amet.
27140 \end_layout
27141
27142 \end_inset
27143
27144
27145 \end_layout
27146
27147 \begin_layout Subsection
27148 Custom shapes
27149 \end_layout
27150
27151 \begin_layout Standard
27152 You can define any shape you want.
27153  Doing this manually is a lot of work because every coordinate must be specified.
27154  But there is a way to let the computer calculate the coordinates:
27155 \end_layout
27156
27157 \begin_layout Enumerate
27158 Install the program 
27159 \begin_inset CommandInset href
27160 LatexCommand href
27161 name "Jpgfdraw"
27162 target "http://www.ctan.org/tex-archive/graphics/jpgfdraw"
27163 literal "false"
27164
27165 \end_inset
27166
27167 .
27168 \end_layout
27169
27170 \begin_layout Enumerate
27171 In 
27172 \family sans
27173 Jpgfdraw
27174 \family default
27175  go to the menu 
27176 \family sans
27177 TeX/LaTeX\SpecialChar menuseparator
27178 Settings\SpecialChar menuseparator
27179 Set Normal Size
27180 \family default
27181  and select the font size you are using in your document.
27182  For example this document uses the size 12
27183 \begin_inset space \thinspace{}
27184 \end_inset
27185
27186 pt.
27187 \end_layout
27188
27189 \begin_layout Enumerate
27190 Draw a shape.
27191 \end_layout
27192
27193 \begin_layout Enumerate
27194 Use the menu 
27195 \family sans
27196 TeX/LaTeX\SpecialChar menuseparator
27197 Shapepar
27198 \family default
27199  to export the shape to coordinates.
27200  In the appearing dialog use either the outline of your shape for the coordinate
27201 s or the path itself.
27202 \begin_inset Foot
27203 status collapsed
27204
27205 \begin_layout Plain Layout
27206 For more information see 
27207 \begin_inset CommandInset href
27208 LatexCommand href
27209 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
27210 literal "false"
27211
27212 \end_inset
27213
27214
27215 \end_layout
27216
27217 \end_inset
27218
27219
27220 \end_layout
27221
27222 \begin_layout Standard
27223 The coordinates are written into a \SpecialChar TeX
27224  file.
27225  To use it for your \SpecialChar LyX
27226  document
27227 \end_layout
27228
27229 \begin_layout Enumerate
27230 Place the cursor before the first character of your paragraph (or into a
27231  new empty one).
27232 \end_layout
27233
27234 \begin_layout Enumerate
27235 Open in \SpecialChar LyX
27236  the menu 
27237 \family sans
27238 Insert\SpecialChar menuseparator
27239 File\SpecialChar menuseparator
27240 Child
27241 \begin_inset space ~
27242 \end_inset
27243
27244 Document
27245 \family default
27246 , select the file and use 
27247 \family sans
27248 Input
27249 \family default
27250  as 
27251 \family sans
27252 Include Type.
27253 \end_layout
27254
27255 \begin_layout Standard
27256 \begin_inset VSpace defskip
27257 \end_inset
27258
27259
27260 \end_layout
27261
27262 \begin_layout Standard
27263 \begin_inset Note Greyedout
27264 status open
27265
27266 \begin_layout Plain Layout
27267
27268 \series bold
27269 Note
27270 \series default
27271 : The changed shape only applies to the current paragraph; everything is
27272  reset to normal for the next paragraph.
27273  Therefore the shape definition file must be input into every paragraph
27274  with the desired shape.
27275 \end_layout
27276
27277 \end_inset
27278
27279
27280 \end_layout
27281
27282 \begin_layout Standard
27283 \begin_inset VSpace bigskip
27284 \end_inset
27285
27286
27287 \end_layout
27288
27289 \begin_layout Standard
27290 Here is an example:
27291 \end_layout
27292
27293 \begin_layout Standard
27294 \begin_inset VSpace bigskip
27295 \end_inset
27296
27297
27298 \end_layout
27299
27300 \begin_layout Standard
27301 \begin_inset CommandInset include
27302 LatexCommand input
27303 filename "SpecialParagraphShape.tex"
27304
27305 \end_inset
27306
27307
27308 \lang latin
27309 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
27310  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
27311  voluptua.
27312  At vero eos et accusam et justo duo dolores et ea rebum.
27313  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
27314  sit amet.
27315  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
27316  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
27317  voluptua.
27318 \end_layout
27319
27320 \begin_layout Standard
27321 \begin_inset VSpace bigskip
27322 \end_inset
27323
27324
27325 \end_layout
27326
27327 \begin_layout Standard
27328
27329 \series bold
27330 A tip:
27331 \series default
27332  to draw complexer shapes in 
27333 \family sans
27334 Jpgfdraw
27335 \family default
27336  you can draw the shape in a program of your choice and import the resulting
27337  image to 
27338 \family sans
27339 Jpgfdraw
27340 \family default
27341 .
27342  Then you only need to draw a line or spline along the outline of the image.
27343 \end_layout
27344
27345 \begin_layout Standard
27346 \begin_inset VSpace bigskip
27347 \end_inset
27348
27349
27350 \end_layout
27351
27352 \begin_layout Standard
27353 The module 
27354 \family sans
27355 Custom paragraph shapes
27356 \family default
27357  also provides the two commands 
27358 \family sans
27359 shapepar
27360 \family default
27361  and 
27362 \family sans
27363 Shapepar
27364 \family default
27365  which can be used to define custom shapes coordinate by coordinate.
27366 \begin_inset Foot
27367 status collapsed
27368
27369 \begin_layout Plain Layout
27370 These commands are internally used for all shapes described here.
27371 \end_layout
27372
27373 \end_inset
27374
27375  For information how these styles are used and about further customization
27376  possibilities, have a look at the documentation of the package 
27377 \series bold
27378 shapepar
27379 \series default
27380
27381 \begin_inset CommandInset citation
27382 LatexCommand cite
27383 key "shapepar"
27384 literal "true"
27385
27386 \end_inset
27387
27388 .
27389 \end_layout
27390
27391 \begin_layout Bibliography
27392 \begin_inset CommandInset bibitem
27393 LatexCommand bibitem
27394 key "multicol"
27395 literal "true"
27396
27397 \end_inset
27398
27399 Documentation of the \SpecialChar LaTeX
27400 -package 
27401 \begin_inset CommandInset href
27402 LatexCommand href
27403 name "multicol"
27404 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
27405 literal "false"
27406
27407 \end_inset
27408
27409
27410 \end_layout
27411
27412 \begin_layout Bibliography
27413 \begin_inset CommandInset bibitem
27414 LatexCommand bibitem
27415 key "shapepar"
27416 literal "true"
27417
27418 \end_inset
27419
27420 Documentation of the \SpecialChar LaTeX
27421 -package 
27422 \begin_inset CommandInset href
27423 LatexCommand href
27424 name "shapepar"
27425 target "http://mirrors.ctan.org/macros/latex/contrib/shapepar/shapepar.pdf"
27426 literal "false"
27427
27428 \end_inset
27429
27430
27431 \end_layout
27432
27433 \end_body
27434 \end_document